@univerjs-pro/live-share 0.12.3-nightly.202512060617 → 0.12.4-experimental.20251208-c4b8a44
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/facade.js +1 -1
- package/lib/cjs/index.js +1 -1
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/facade.js +1 -1
- package/lib/index.js +1 -1
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- package/package.json +11 -11
package/lib/cjs/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const
|
|
1
|
+
'use strict';const _0x5954cb=_0x5529;function _0x5529(_0x27412d,_0x437834){_0x27412d=_0x27412d-0xa4;const _0x41651b=_0x4165();let _0x552988=_0x41651b[_0x27412d];return _0x552988;}(function(_0x359223,_0x3d75f4){const _0x16bcf5=_0x5529,_0x3acb96=_0x359223();while(!![]){try{const _0x3aa163=-parseInt(_0x16bcf5(0xb0))/0x1+parseInt(_0x16bcf5(0xac))/0x2+parseInt(_0x16bcf5(0xbc))/0x3+-parseInt(_0x16bcf5(0xbb))/0x4+parseInt(_0x16bcf5(0xb6))/0x5*(-parseInt(_0x16bcf5(0xce))/0x6)+-parseInt(_0x16bcf5(0xcc))/0x7*(-parseInt(_0x16bcf5(0xc2))/0x8)+parseInt(_0x16bcf5(0xc8))/0x9*(parseInt(_0x16bcf5(0xb4))/0xa);if(_0x3aa163===_0x3d75f4)break;else _0x3acb96['push'](_0x3acb96['shift']());}catch(_0x194a50){_0x3acb96['push'](_0x3acb96['shift']());}}}(_0x4165,0x245db));function _0x4165(){const _0x1029f1=['_initialize','79606tBuAtY','SetWorksheetActiveOperation','getId','LiveShareController','260993eDHhln','IRenderManagerService','No\x20active\x20workbook\x20found.','startPresenting','10JkzhEq','No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.','128795ynsaBf','SetScrollOperation','LiveShareStatus','tryStartPresenting','_commandService','38260nsKHqt','448473iBQrWU','FUniver','IDLE','startColumn','getLiveShareStatus','getStatus','3576ofPyzx','getActiveWorkbook','syncExecuteCommand','getSheetId','_injector','startRow','2142927XtYCaP','PRESENTING','LiveShareStatusEnum','stopFollowing','3507eRgIvt','get','54INkYxz','startFollowing','getLiveShareCoordinatorSync','getUnitId','extend','FEnum','getActiveSheet','stopPresenting','FRange','executeCommand'];_0x4165=function(){return _0x1029f1;};return _0x4165();}const n=require('@univerjs-pro/live-share'),g=require('@univerjs/engine-render'),u=require('@univerjs/sheets'),f=require('@univerjs/sheets-ui'),d=require('@univerjs/sheets/facade'),a=require('@univerjs/core/facade');class w extends d[_0x5954cb(0xa9)]{[_0x5954cb(0xab)](_0x8784cd,_0x286554,_0x1ec71e,_0x19ff49,_0x167bc5){const _0x4e1ed6=_0x5954cb,_0x9a37fb=_0x8784cd[_0x4e1ed6(0xcd)](n[_0x4e1ed6(0xaf)]),_0x418f92=_0x8784cd[_0x4e1ed6(0xcd)](g[_0x4e1ed6(0xb1)]),_0x29123e=_0x286554[_0x4e1ed6(0xa4)](),_0x5445bc=_0x286554[_0x4e1ed6(0xa7)](),_0x537f3a=_0x9a37fb[_0x4e1ed6(0xd0)](_0x29123e);(_0x537f3a==null?void 0x0:_0x537f3a[_0x4e1ed6(0xc1)]())!==n['LiveShareStatus'][_0x4e1ed6(0xc9)]||(_0x1ec71e[_0x4e1ed6(0xc5)]()!==_0x5445bc[_0x4e1ed6(0xc5)]()&&this[_0x4e1ed6(0xba)][_0x4e1ed6(0xaa)](u[_0x4e1ed6(0xad)]['id'],{'unitId':_0x29123e,'subUnitId':_0x1ec71e[_0x4e1ed6(0xc5)]()}),!_0x418f92['getRenderById'](_0x29123e))||_0x167bc5[_0x4e1ed6(0xc4)](f[_0x4e1ed6(0xb7)]['id'],{'unitId':_0x286554[_0x4e1ed6(0xa4)](),'sheetId':_0x1ec71e['getSheetId'](),'sheetViewStartRow':_0x19ff49[_0x4e1ed6(0xc7)],'sheetViewStartColumn':_0x19ff49[_0x4e1ed6(0xbf)],'offsetX':0x0,'offsetY':0x0,'screenRatioX':-0x1/0x3,'screenRatioY':-0x1/0x3,'duration':0x12c});}}d[_0x5954cb(0xa9)][_0x5954cb(0xa5)](w);class C extends a['FUniver']{[_0x5954cb(0xc0)](){const _0x2712e3=_0x5954cb;var _0x47e964,_0x487fa4;const _0x455c45=this[_0x2712e3(0xc6)]['get'](n[_0x2712e3(0xaf)]),_0x2e5b85=(_0x47e964=this['getActiveWorkbook']())==null?void 0x0:_0x47e964[_0x2712e3(0xae)]();if(!_0x2e5b85)throw new Error(_0x2712e3(0xb2));const _0x4a9293=_0x455c45[_0x2712e3(0xd0)](_0x2e5b85);return(_0x487fa4=_0x4a9293==null?void 0x0:_0x4a9293[_0x2712e3(0xc1)]())!=null?_0x487fa4:n[_0x2712e3(0xb8)][_0x2712e3(0xbe)];}[_0x5954cb(0xcf)](){const _0xb874df=_0x5954cb;var _0x5643b4;const _0x43066b=this[_0xb874df(0xc6)]['get'](n['LiveShareController']),_0x3d198b=(_0x5643b4=this['getActiveWorkbook']())==null?void 0x0:_0x5643b4[_0xb874df(0xae)]();if(!_0x3d198b)throw new Error(_0xb874df(0xb2));const _0x3a632b=_0x43066b['getLiveShareCoordinatorSync'](_0x3d198b);if(!_0x3a632b)throw new Error(_0xb874df(0xb5));_0x3a632b[_0xb874df(0xcf)]();}['stopFollowing'](){const _0x4fdf54=_0x5954cb;var _0x2ec2cc;const _0x43cac9=this[_0x4fdf54(0xc6)][_0x4fdf54(0xcd)](n[_0x4fdf54(0xaf)]),_0x5bd410=(_0x2ec2cc=this[_0x4fdf54(0xc3)]())==null?void 0x0:_0x2ec2cc['getId']();if(!_0x5bd410)throw new Error('No\x20active\x20workbook\x20found.');const _0x1e1005=_0x43cac9[_0x4fdf54(0xd0)](_0x5bd410);if(!_0x1e1005)throw new Error(_0x4fdf54(0xb5));_0x1e1005[_0x4fdf54(0xcb)]();}[_0x5954cb(0xb3)](){const _0x4efc53=_0x5954cb;var _0x9c65c;const _0x390ad5=this[_0x4efc53(0xc6)]['get'](n[_0x4efc53(0xaf)]),_0x3e218e=(_0x9c65c=this['getActiveWorkbook']())==null?void 0x0:_0x9c65c[_0x4efc53(0xae)]();if(!_0x3e218e)throw new Error(_0x4efc53(0xb2));const _0x5d9f86=_0x390ad5[_0x4efc53(0xd0)](_0x3e218e);if(!_0x5d9f86)throw new Error(_0x4efc53(0xb5));_0x5d9f86[_0x4efc53(0xb9)]();}[_0x5954cb(0xa8)](){const _0x13a097=_0x5954cb;var _0x3b7801;const _0x3abdb9=this[_0x13a097(0xc6)]['get'](n[_0x13a097(0xaf)]),_0x1cfc93=(_0x3b7801=this[_0x13a097(0xc3)]())==null?void 0x0:_0x3b7801[_0x13a097(0xae)]();if(!_0x1cfc93)throw new Error(_0x13a097(0xb2));const _0x54febc=_0x3abdb9[_0x13a097(0xd0)](_0x1cfc93);if(!_0x54febc)throw new Error('No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.');_0x54febc[_0x13a097(0xa8)]();}}a[_0x5954cb(0xbd)][_0x5954cb(0xa5)](C);class L extends a[_0x5954cb(0xa6)]{get[_0x5954cb(0xca)](){const _0x343b99=_0x5954cb;return n[_0x343b99(0xb8)];}}a[_0x5954cb(0xa6)]['extend'](L);
|
package/lib/cjs/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const _0x276616=_0x5eb0;(function(_0x4f37d2,_0x2994bd){const _0xc9cf13=_0x5eb0,_0x59ea2f=_0x4f37d2();while(!![]){try{const _0x3ab88d=-parseInt(_0xc9cf13(0x119))/0x1+parseInt(_0xc9cf13(0x13d))/0x2+parseInt(_0xc9cf13(0x1bf))/0x3*(-parseInt(_0xc9cf13(0x139))/0x4)+-parseInt(_0xc9cf13(0x1ae))/0x5*(parseInt(_0xc9cf13(0x17e))/0x6)+-parseInt(_0xc9cf13(0x17b))/0x7*(-parseInt(_0xc9cf13(0x19d))/0x8)+-parseInt(_0xc9cf13(0x1a3))/0x9+-parseInt(_0xc9cf13(0x155))/0xa;if(_0x3ab88d===_0x2994bd)break;else _0x59ea2f['push'](_0x59ea2f['shift']());}catch(_0x2a5e81){_0x59ea2f['push'](_0x59ea2f['shift']());}}}(_0x7d5a,0xc85c3));var T=Object[_0x276616(0x1cf)],U=(_0x51264c,_0x43096f,_0x56a977)=>_0x43096f in _0x51264c?T(_0x51264c,_0x43096f,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x56a977}):_0x51264c[_0x43096f]=_0x56a977,_=(_0x30156a,_0x11d4a7,_0x1f110d)=>U(_0x30156a,typeof _0x11d4a7!=_0x276616(0x18a)?_0x11d4a7+'':_0x11d4a7,_0x1f110d);Object['defineProperty'](exports,Symbol['toStringTag'],{'value':_0x276616(0x1c2)});const o=require('@univerjs/core'),p=require('@univerjs/ui'),l=require('react/jsx-runtime'),f=require('@univerjs/design'),v=require('react'),d=require('@univerjs-pro/collaboration'),b=require('@univerjs-pro/collaboration-client'),C=require('@univerjs/sheets'),O=require('rxjs'),I=require('rxjs/operators'),D=require('@univerjs/sheets-ui');function x({ref:_0x20eed6,..._0x274cdd}){const _0xc4043a=_0x276616,{icon:_0x54d23c,id:_0x30a17a,className:_0x282f15,extend:_0x5b4f95,..._0x26856a}=_0x274cdd,_0x5e7d74=(_0xc4043a(0x146)+_0x30a17a+'\x20'+(_0x282f15||''))[_0xc4043a(0x129)](),_0x30327d=v[_0xc4043a(0x19b)]('_'+H());return j(_0x54d23c,''+_0x30a17a,{'defIds':_0x54d23c[_0xc4043a(0x113)],'idSuffix':_0x30327d[_0xc4043a(0x145)]},{'ref':_0x20eed6,'className':_0x5e7d74,..._0x26856a},_0x5b4f95);}function j(_0x33f75b,_0x11fd27,_0x49e4c1,_0x3d977d,_0x4b11c6){const _0x5321ab=_0x276616;return v[_0x5321ab(0x115)](_0x33f75b[_0x5321ab(0x197)],{'key':_0x11fd27,...y(_0x33f75b,_0x49e4c1,_0x4b11c6),..._0x3d977d},(F(_0x33f75b,_0x49e4c1)[_0x5321ab(0x12d)]||[])[_0x5321ab(0x1c5)]((_0x1508d3,_0x5e8f6f)=>j(_0x1508d3,_0x11fd27+'-'+_0x33f75b[_0x5321ab(0x197)]+'-'+_0x5e8f6f,_0x49e4c1,void 0x0,_0x4b11c6)));}function y(_0x34e7d4,_0x9ef990,_0x48cd34){const _0x4c4992=_0x276616,_0x3e05aa={..._0x34e7d4[_0x4c4992(0x188)]};_0x48cd34!=null&&_0x48cd34['colorChannel1']&&_0x3e05aa[_0x4c4992(0x187)]===_0x4c4992(0x138)&&(_0x3e05aa[_0x4c4992(0x187)]=_0x48cd34[_0x4c4992(0x138)]),_0x34e7d4[_0x4c4992(0x197)]===_0x4c4992(0x123)&&_0x3e05aa['id']&&(_0x3e05aa['id']=_0x3e05aa['id']+_0x9ef990[_0x4c4992(0x108)]),Object['entries'](_0x3e05aa)[_0x4c4992(0x1c8)](([_0x50cde8,_0x576fad])=>{const _0x2830ba=_0x4c4992;_0x50cde8===_0x2830ba(0x123)&&typeof _0x576fad==_0x2830ba(0x172)&&(_0x3e05aa[_0x50cde8]=_0x576fad[_0x2830ba(0x184)](/url\(#(.*)\)/,'url(#$1'+_0x9ef990[_0x2830ba(0x108)]+')'));});const {defIds:_0x5b6481}=_0x9ef990;return!_0x5b6481||_0x5b6481[_0x4c4992(0x16a)]===0x0||(_0x34e7d4[_0x4c4992(0x197)]===_0x4c4992(0x117)&&_0x3e05aa[_0x4c4992(0x183)]&&(_0x3e05aa[_0x4c4992(0x183)]=_0x3e05aa[_0x4c4992(0x183)]+_0x9ef990[_0x4c4992(0x108)]),Object[_0x4c4992(0x1a8)](_0x3e05aa)[_0x4c4992(0x1c8)](([_0x90cf6f,_0x3b9f40])=>{const _0x501b86=_0x4c4992;typeof _0x3b9f40==_0x501b86(0x172)&&(_0x3e05aa[_0x90cf6f]=_0x3b9f40[_0x501b86(0x184)](/url\(#(.*)\)/,_0x501b86(0x147)+_0x9ef990['idSuffix']+')'));})),_0x3e05aa;}function _0x7d5a(){const _0x23baf8=['_status','SessionStatus','You\x27are\x20offline.','offline','1188171sguYCG','Subject','HEADER_MENU','Module','useDependency','find','map','_init','_configService','forEach','UNIVER_LIVE_SHARE_PLUGIN','_handleOnline','getUnitId','getTypeOfUnitAdded$','displayName','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','defineProperty','_config','getCurrentTypeOfUnit$','M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','Injector','_collabSessionService','clear','presenter','override','idSuffix','IConfigService','NEW_CHANGESETS','_status$','dispose$','then','stopPresenting','parseProtocolChangeset','svg','touchDependencies','SetScrollOperation','defIds','tryStartPresenting','createElement','_handleTerminate','use','registerInitialStateReporter','257182RLyzIg','registerSharedOperation','LiveShareCoordinator','dispose','stringify','_injector','_mountLiveShare','SetWorksheetActiveOperation','UniverLiveSharePlugin','BuiltInUIPart','mask','pipe','UniverIcon','event$','BehaviorSubject','presenting','trim','has','toDisposable','getOwnPropertyDescriptor','children','values','createInstance','unitId','stopFollowing','getStatus','following','_startLiveShareCoordinator','getTypeOfUnitDisposed$','clsx','InsertSheetMutation','colorChannel1','4MPKrzD','toString','disposeWithMe','substring','1986222EAHGeW','useObservable','init','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','PRESENTING','shouldShareOperation','getMemberID','reverse','current','univerjs-icon\x20univerjs-icon-','url(#$1','_entities','Start\x20following','_stopPresenting','Fragment','NOT_FOLLOWING','forwardRef','currentColor','univer-size-4','http://www.w3.org/2000/svg','params','memberID','Stop\x20presenting','_handleNewHost','796280KTdqzo','set','from','onCommandExecuted','idle','_fetchOperations','setConfig','_univerInstanceService','_startPresenting','_sharedOperations','getLiveShareCoordinator','_collabSession','delete','div','Button','none','_presenter','You\x27re\x20not\x20following\x20the\x20presenter','text','OPERATION','mutations','length','IUniverInstanceService','jsxs','DisposableCollection','LIVESHARE_FETCH_OPERATIONS','SAME_OPERATION_SHARE_INTERVAL','univer-mb-3\x20univer-w-full\x20univer-text-sm','getValue','string','OFFLINE','send','registerDependencies','LiveShareIcon','LIVESHARE_OPERATION','IDLE','CollaborationEvent','ONLINE','10950163AWmvNU','pluginName','defs','130776jMXivt','includes','1em','_liveShareService','live-share.config','xlink:href','replace','executeCommand','get','fill','attrs','Inject','symbol','path','CollaborationSessionService','jsx','next','Disposable','assign','_startFollowing','mergeOverrideWithDependencies','LIVESHARE_REQUEST_HOST','connectInjector','unsubscribe','sessionStatus$','tag','_handleOffline','LiveShareController','UniverInstanceType','useRef','live-share-icon','8HUDjkJ','takeUntil','requireSession','_beIdle','evenodd','data','2365326laQLyG','throttleTime','_commandDisposable','_stopFollowing','_unitID','entries','DesktopLiveShareController','asObservable','status$','add','LiveShareStatus','170IcgPZu','Start','UNIVER_SHEET','operations','CommandType','getLiveShareCoordinatorSync','RxDisposable','_commandService','not-following','subscribe','_reporters','ICommandService','useState'];_0x7d5a=function(){return _0x23baf8;};return _0x7d5a();}function F(_0x1fbc39,_0x3fcafe){const _0x5712bd=_0x276616;var _0x2587de;const {defIds:_0x2a722a}=_0x3fcafe;return!_0x2a722a||_0x2a722a[_0x5712bd(0x16a)]===0x0?_0x1fbc39:_0x1fbc39[_0x5712bd(0x197)]===_0x5712bd(0x17d)&&((_0x2587de=_0x1fbc39[_0x5712bd(0x12d)])!=null&&_0x2587de[_0x5712bd(0x16a)])?{..._0x1fbc39,'children':_0x1fbc39[_0x5712bd(0x12d)]['map'](_0x72d15a=>typeof _0x72d15a[_0x5712bd(0x188)]['id']=='string'&&_0x2a722a&&_0x2a722a[_0x5712bd(0x17f)](_0x72d15a[_0x5712bd(0x188)]['id'])?{..._0x72d15a,'attrs':{..._0x72d15a[_0x5712bd(0x188)],'id':_0x72d15a[_0x5712bd(0x188)]['id']+_0x3fcafe[_0x5712bd(0x108)]}}:_0x72d15a)}:_0x1fbc39;}function H(){const _0xac838a=_0x276616;return Math['random']()[_0xac838a(0x13a)](0x24)[_0xac838a(0x13c)](0x2,0x8);}x[_0x276616(0x1cd)]=_0x276616(0x125);const V={'tag':_0x276616(0x110),'attrs':{'xmlns':_0x276616(0x150),'fill':_0x276616(0x164),'viewBox':'0\x200\x2017\x2017','width':_0x276616(0x180),'height':_0x276616(0x180)},'children':[{'tag':_0x276616(0x18b),'attrs':{'fill':_0x276616(0x14e),'d':_0x276616(0x1ce)}},{'tag':_0x276616(0x18b),'attrs':{'fill':_0x276616(0x14e),'d':_0x276616(0x102),'fillRule':'evenodd','clipRule':_0x276616(0x1a1)}}]},R=v[_0x276616(0x14d)](function(_0x5d3f2c,_0x2a7f5e){const _0x57e303=_0x276616;return v[_0x57e303(0x115)](x,Object[_0x57e303(0x190)]({},_0x5d3f2c,{'id':_0x57e303(0x19c),'ref':_0x2a7f5e,'icon':V}));});R[_0x276616(0x1cd)]=_0x276616(0x176);class E extends o['Disposable']{constructor(){const _0x38952e=_0x276616;super(...arguments),_(this,'_sharedOperations',new Set()),_(this,_0x38952e(0x1b8),new Set());}['registerSharedOperation'](_0x3c5740){const _0x234d08=_0x276616;return this['_sharedOperations'][_0x234d08(0x1ac)](_0x3c5740),o['toDisposable'](()=>this[_0x234d08(0x15e)][_0x234d08(0x161)](_0x3c5740));}[_0x276616(0x118)](_0x2c4288){const _0x2b6637=_0x276616;return this[_0x2b6637(0x1b8)][_0x2b6637(0x1ac)](_0x2c4288),o['toDisposable'](()=>this[_0x2b6637(0x1b8)]['delete'](_0x2c4288));}[_0x276616(0x142)](_0x3ee055){const _0xf757d=_0x276616;return this[_0xf757d(0x15e)][_0xf757d(0x12a)](_0x3ee055);}['getInitialStates'](_0x3a85c7){const _0x2bd8e2=_0x276616;return Array[_0x2bd8e2(0x157)](this[_0x2bd8e2(0x1b8)])[_0x2bd8e2(0x1c5)](_0x2ef2a4=>_0x2ef2a4(_0x3a85c7));}}var M=Object[_0x276616(0x12c)],P=(_0x2919dc,_0x520474,_0x8b2085,_0x25ea23)=>{const _0x2c9cd5=_0x276616;for(var _0x431a9b=_0x25ea23>0x1?void 0x0:_0x25ea23?M(_0x520474,_0x8b2085):_0x520474,_0x5c504e=_0x2919dc[_0x2c9cd5(0x16a)]-0x1,_0xcf7e60;_0x5c504e>=0x0;_0x5c504e--)(_0xcf7e60=_0x2919dc[_0x5c504e])&&(_0x431a9b=_0xcf7e60(_0x431a9b)||_0x431a9b);return _0x431a9b;},S=(_0x20a838,_0x48e678)=>(_0x2cf2c7,_0x42ac1c)=>_0x48e678(_0x2cf2c7,_0x42ac1c,_0x20a838);exports[_0x276616(0x199)]=class extends o[_0x276616(0x1b4)]{constructor(_0x49eb28,_0x13ebd6,_0x2db66e){const _0x146546=_0x276616;super(),_(this,_0x146546(0x148),new Map()),(this['_univerInstanceService']=_0x49eb28,this['_injector']=_0x13ebd6,this[_0x146546(0x104)]=_0x2db66e,this[_0x146546(0x1c6)]());}async[_0x276616(0x15f)](_0x353363){const _0x5b98fa=_0x276616;return this[_0x5b98fa(0x148)][_0x5b98fa(0x12a)](_0x353363)||await this[_0x5b98fa(0x134)](_0x353363),this[_0x5b98fa(0x148)]['get'](_0x353363);}[_0x276616(0x1b3)](_0xb60053){var _0x52d76b;return(_0x52d76b=this['_entities']['get'](_0xb60053))!=null?_0x52d76b:null;}[_0x276616(0x1c6)](){const _0x11fc04=_0x276616;this['_univerInstanceService'][_0x11fc04(0x1cc)](o[_0x11fc04(0x19a)][_0x11fc04(0x1b0)])[_0x11fc04(0x124)](I[_0x11fc04(0x19e)](this[_0x11fc04(0x10c)]))[_0x11fc04(0x1b7)](async _0x2b5919=>{const _0x10d330=_0x11fc04,_0x41ea5d=_0x2b5919[_0x10d330(0x1cb)]();this[_0x10d330(0x148)][_0x10d330(0x12a)](_0x41ea5d)||this[_0x10d330(0x134)](_0x41ea5d);}),this[_0x11fc04(0x15c)][_0x11fc04(0x135)](o[_0x11fc04(0x19a)][_0x11fc04(0x1b0)])[_0x11fc04(0x124)](I[_0x11fc04(0x19e)](this['dispose$']))[_0x11fc04(0x1b7)](_0x541a21=>{const _0x217942=_0x11fc04,_0x35c2b8=_0x541a21['getUnitId'](),_0x447661=this[_0x217942(0x148)]['get'](_0x35c2b8);_0x447661==null||_0x447661[_0x217942(0x11c)]();});}async[_0x276616(0x134)](_0x440312){const _0x598f60=_0x276616,_0x1042e7=await this['_collabSessionService'][_0x598f60(0x19f)](_0x440312),_0x4a6c3a=this[_0x598f60(0x11e)][_0x598f60(0x12f)](exports[_0x598f60(0x11b)],_0x440312,_0x1042e7);return _0x4a6c3a['init'](),this[_0x598f60(0x148)][_0x598f60(0x156)](_0x440312,_0x4a6c3a),_0x4a6c3a;}},exports[_0x276616(0x199)]=P([S(0x0,o['IUniverInstanceService']),S(0x1,o[_0x276616(0x189)](o[_0x276616(0x103)])),S(0x2,o['Inject'](b[_0x276616(0x18c)]))],exports[_0x276616(0x199)]);var u=(_0x24165b=>(_0x24165b['OFFLINE']=_0x276616(0x1be),_0x24165b[_0x276616(0x178)]=_0x276616(0x159),_0x24165b['FOLLOWING']=_0x276616(0x133),_0x24165b[_0x276616(0x14c)]=_0x276616(0x1b6),_0x24165b[_0x276616(0x141)]=_0x276616(0x128),_0x24165b))(u||{});const k=_0x276616(0x16f),q=0xc8;exports[_0x276616(0x11b)]=class extends o['RxDisposable']{constructor(_0x486d3b,_0x495540,_0xc57f27,_0x58bdca,_0x32e3a7){const _0x51f240=_0x276616;super(),_(this,_0x51f240(0x10b),new O[(_0x51f240(0x127))](_0x51f240(0x159))),_(this,_0x51f240(0x1ab),this[_0x51f240(0x10b)][_0x51f240(0x1aa)]()),_(this,_0x51f240(0x1c6),!0x1),_(this,_0x51f240(0x1a5),null),_(this,'_presenter',null),(this[_0x51f240(0x1a7)]=_0x486d3b,this[_0x51f240(0x160)]=_0x495540,this[_0x51f240(0x1c7)]=_0xc57f27,this[_0x51f240(0x181)]=_0x58bdca,this['_commandService']=_0x32e3a7);}get['_status'](){const _0x3839fe=_0x276616;return this['_status$'][_0x3839fe(0x171)]();}['dispose'](){const _0x1dbd9b=_0x276616;var _0x3d3cd3;(_0x3d3cd3=this['_commandDisposable'])==null||_0x3d3cd3['dispose'](),this[_0x1dbd9b(0x10b)]['next']('idle'),this[_0x1dbd9b(0x10b)]['complete']();}[_0x276616(0x132)](){return this['_status'];}[_0x276616(0x13f)](){const _0x25b988=_0x276616;this['_init']||(this['_init']=!0x0,this[_0x25b988(0x160)][_0x25b988(0x196)][_0x25b988(0x124)](I[_0x25b988(0x19e)](this['dispose$']))['subscribe'](_0x593d6b=>{const _0x465790=_0x25b988;switch(_0x593d6b){case b[_0x465790(0x1bc)]['OFFLINE']:this[_0x465790(0x198)]();break;case b['SessionStatus'][_0x465790(0x17a)]:this[_0x465790(0x1ca)]();break;}}),this['_collabSession'][_0x25b988(0x126)][_0x25b988(0x124)](I[_0x25b988(0x19e)](this[_0x25b988(0x10c)]))['subscribe'](_0x31ad6f=>{const _0x4cf534=_0x25b988,{eventID:_0x5231bf}=_0x31ad6f;switch(_0x5231bf){case d['CollaborationEvent']['LIVESHARE_NEW_HOST']:this[_0x4cf534(0x154)](_0x31ad6f);break;case d['CollaborationEvent']['LIVESHARE_OPERATION']:this['_handleOperation'](_0x31ad6f);break;case d['CollaborationEvent']['LIVESHARE_TERMINATE']:this[_0x4cf534(0x116)]();break;case d[_0x4cf534(0x179)][_0x4cf534(0x10a)]:this['_handleNewChangeSets'](_0x31ad6f);break;}}));}[_0x276616(0x114)](){const _0x106307=_0x276616;this[_0x106307(0x160)][_0x106307(0x174)]({'eventID':d[_0x106307(0x179)][_0x106307(0x193)],'data':{'unitID':this[_0x106307(0x1a7)],'userID':this[_0x106307(0x160)][_0x106307(0x143)]()}},this['_unitID']);}[_0x276616(0x10e)](){const _0x319544=_0x276616;this['_status']===_0x319544(0x128)&&(this[_0x319544(0x10b)][_0x319544(0x18e)](_0x319544(0x159)),this[_0x319544(0x160)][_0x319544(0x174)]({'eventID':d[_0x319544(0x179)]['LIVESHARE_TERMINATE'],'data':{'unitID':this['_unitID']}},this[_0x319544(0x1a7)]));}['startFollowing'](){const _0x512c95=_0x276616;this[_0x512c95(0x1bb)]==='not-following'&&(this[_0x512c95(0x10b)][_0x512c95(0x18e)](_0x512c95(0x133)),this[_0x512c95(0x191)]());}['stopFollowing'](){const _0x3e4d9f=_0x276616;this[_0x3e4d9f(0x1bb)]==='following'&&this[_0x3e4d9f(0x1a6)]();}[_0x276616(0x154)](_0x30c7ac){const _0x6b5db1=_0x276616,{presenter:_0x148e0f}=_0x30c7ac[_0x6b5db1(0x1a2)],_0x37153b=this['_collabSession']['getMemberID']();this[_0x6b5db1(0x165)]=_0x148e0f,_0x148e0f===_0x37153b?(this[_0x6b5db1(0x1a6)](),this[_0x6b5db1(0x15d)]()):this[_0x6b5db1(0x1bb)]!==_0x6b5db1(0x1b6)&&(this[_0x6b5db1(0x14a)](),this[_0x6b5db1(0x191)]());}[_0x276616(0x15a)](){const _0x390a39=_0x276616,_0x3b2a65={'eventID':d[_0x390a39(0x179)][_0x390a39(0x16e)]};this[_0x390a39(0x160)]['send'](_0x3b2a65,this[_0x390a39(0x1a7)]);}['_handleTerminate'](){const _0x5375b2=_0x276616;this['_presenter']=null,this[_0x5375b2(0x1bb)]!==_0x5375b2(0x128)&&this[_0x5375b2(0x1a0)]();}['_handleNewChangeSets'](_0x53f07c){const _0x1099da=_0x276616;if(this[_0x1099da(0x1bb)]===_0x1099da(0x133)&&this[_0x1099da(0x165)]===_0x53f07c['data'][_0x1099da(0x152)]){const _0x2326d7=d[_0x1099da(0x10f)](_0x53f07c[_0x1099da(0x1a2)])[_0x1099da(0x169)][_0x1099da(0x144)]()[_0x1099da(0x1c4)](_0x4f6e6f=>_0x4f6e6f['id']===C[_0x1099da(0x137)]['id']);if(_0x2326d7){const _0x26ec61=_0x2326d7[_0x1099da(0x151)][_0x1099da(0x130)],_0x4e14f4=_0x2326d7[_0x1099da(0x151)]['sheet']['id'];setTimeout(()=>{const _0x71740a=_0x1099da;this[_0x71740a(0x1b5)][_0x71740a(0x185)](C[_0x71740a(0x120)]['id'],{'unitId':_0x26ec61,'subUnitId':_0x4e14f4},{'fromCollab':!0x0});});}}}[_0x276616(0x15d)](){const _0x35998b=_0x276616;this['_status$'][_0x35998b(0x18e)](_0x35998b(0x128));const _0x3917c6=new Map(),_0x4de7e1=this['_commandDisposable']=new o[(_0x35998b(0x16d))]();_0x4de7e1[_0x35998b(0x1ac)](o[_0x35998b(0x12b)](()=>{const _0x284f12=_0x35998b;_0x3917c6[_0x284f12(0x1c8)](_0xa77083=>_0xa77083['complete']()),_0x3917c6[_0x284f12(0x105)]();})),_0x4de7e1[_0x35998b(0x1ac)](this['_commandService'][_0x35998b(0x158)](_0x1c4c86=>{const _0x17f393=_0x35998b;var _0x461ffe;if(_0x1c4c86['type']!==o[_0x17f393(0x1b2)][_0x17f393(0x168)]||!this[_0x17f393(0x181)][_0x17f393(0x142)](_0x1c4c86['id']))return;const {id:_0x46756b}=_0x1c4c86;let _0x52e3d7;_0x3917c6[_0x17f393(0x12a)](_0x46756b)?_0x52e3d7=_0x3917c6[_0x17f393(0x186)](_0x46756b):(_0x52e3d7=new O[(_0x17f393(0x1c0))](),_0x3917c6['set'](_0x46756b,_0x52e3d7),_0x52e3d7[_0x17f393(0x124)](I[_0x17f393(0x1a4)]((_0x461ffe=this[_0x17f393(0x1c7)]['getConfig'](k))!=null?_0x461ffe:q,void 0x0,{'trailing':!0x0,'leading':!0x0}))['subscribe'](_0x5da34d=>{const _0x462413=_0x17f393;this[_0x462413(0x160)]['send']({'eventID':d[_0x462413(0x179)][_0x462413(0x177)],'data':{'unitID':this[_0x462413(0x1a7)],'operations':{[_0x5da34d['id']]:{'id':_0x5da34d['id'],'params':JSON[_0x462413(0x11d)](_0x5da34d[_0x462413(0x151)])}}}},this[_0x462413(0x1a7)]);})),_0x52e3d7['next'](_0x1c4c86);})),this['_liveShareService']['getInitialStates'](this[_0x35998b(0x1a7)])[_0x35998b(0x1c8)](_0x2c6307=>this['_collabSession'][_0x35998b(0x174)]({'eventID':d[_0x35998b(0x179)]['LIVESHARE_OPERATION'],'data':{'unitID':this['_unitID'],'operations':{[_0x2c6307['id']]:{'id':_0x2c6307['id'],'params':JSON[_0x35998b(0x11d)](_0x2c6307[_0x35998b(0x151)])}}}},this[_0x35998b(0x1a7)]));}[_0x276616(0x14a)](){const _0x2bfaad=_0x276616;var _0xfe0489;this[_0x2bfaad(0x10b)][_0x2bfaad(0x18e)]('idle'),(_0xfe0489=this[_0x2bfaad(0x1a5)])==null||_0xfe0489[_0x2bfaad(0x11c)](),this[_0x2bfaad(0x1a5)]=null;}[_0x276616(0x191)](){const _0x55b992=_0x276616;var _0x1c635d;(_0x1c635d=this[_0x55b992(0x1a5)])==null||_0x1c635d[_0x55b992(0x11c)](),this[_0x55b992(0x10b)][_0x55b992(0x18e)]('following');}[_0x276616(0x1a0)](){const _0x3c925f=_0x276616;var _0x3f6fe7;this['_status$'][_0x3c925f(0x18e)]('idle'),(_0x3f6fe7=this[_0x3c925f(0x1a5)])==null||_0x3f6fe7[_0x3c925f(0x11c)](),this[_0x3c925f(0x1a5)]=null;}['_stopFollowing'](){const _0x4b1091=_0x276616;var _0x353175;this[_0x4b1091(0x10b)][_0x4b1091(0x18e)](_0x4b1091(0x1b6)),(_0x353175=this[_0x4b1091(0x1a5)])==null||_0x353175['dispose']();}['_handleOperation'](_0x1d03fc){const _0x280e17=_0x276616;if([_0x280e17(0x128),'not-following',_0x280e17(0x1be)][_0x280e17(0x17f)](this[_0x280e17(0x1bb)])||!_0x1d03fc[_0x280e17(0x1a2)][_0x280e17(0x106)]||_0x1d03fc[_0x280e17(0x1a2)][_0x280e17(0x106)]===this[_0x280e17(0x160)][_0x280e17(0x143)]())return;this[_0x280e17(0x1bb)]===_0x280e17(0x159)&&this[_0x280e17(0x191)]();const _0x459e5e=_0x1d03fc['data'][_0x280e17(0x1b1)];Object[_0x280e17(0x12e)](_0x459e5e)[_0x280e17(0x1c8)](_0x2512b4=>{const _0x1f7ca1=_0x280e17;this[_0x1f7ca1(0x1b5)][_0x1f7ca1(0x185)](_0x2512b4['id'],_0x2512b4[_0x1f7ca1(0x151)]?JSON['parse'](_0x2512b4['params']):null,{'fromCollab':!0x0});});}[_0x276616(0x198)](){const _0x23725d=_0x276616;var _0x45ecc8;this[_0x23725d(0x10b)][_0x23725d(0x18e)](_0x23725d(0x1be)),(_0x45ecc8=this[_0x23725d(0x1a5)])==null||_0x45ecc8[_0x23725d(0x11c)]();}[_0x276616(0x1ca)](){const _0x37f493=_0x276616;this[_0x37f493(0x10b)][_0x37f493(0x18e)](_0x37f493(0x159)),this[_0x37f493(0x15a)]();}},exports['LiveShareCoordinator']=P([S(0x2,o[_0x276616(0x109)]),S(0x3,o[_0x276616(0x189)](E)),S(0x4,o[_0x276616(0x1b9)])],exports[_0x276616(0x11b)]);function $(){const _0x566224=_0x276616,_0x5d8732=p['useDependency'](exports[_0x566224(0x199)]),_0x2b982a=p[_0x566224(0x1c3)](o[_0x566224(0x16b)]),_0x3c4577=p[_0x566224(0x13e)](()=>_0x2b982a[_0x566224(0x101)](o[_0x566224(0x19a)][_0x566224(0x1b0)]),void 0x0,!0x1,[]),[_0x4295fb,_0x3580f7]=v[_0x566224(0x1ba)](null),[_0x4c7684,_0x397592]=v[_0x566224(0x1ba)](u['IDLE']),_0x33a533=v[_0x566224(0x19b)](null);return v['useEffect'](()=>(_0x3c4577&&_0x5d8732[_0x566224(0x15f)](_0x3c4577[_0x566224(0x1cb)]())[_0x566224(0x10d)](_0x3a1d2d=>{const _0xc0a777=_0x566224;_0x3580f7(_0x3a1d2d),_0x33a533[_0xc0a777(0x145)]=_0x3a1d2d['status$']['subscribe'](_0x5b16a0=>{_0x397592(_0x5b16a0);});}),()=>{const _0x446d3a=_0x566224;var _0x36fa37;(_0x36fa37=_0x33a533[_0x446d3a(0x145)])==null||_0x36fa37[_0x446d3a(0x195)](),_0x33a533['current']=null;}),[_0x3c4577,_0x5d8732]),_0x4295fb?l[_0x566224(0x18d)](f['Dropdown'],{'align':'end','disabled':_0x4c7684===u[_0x566224(0x173)],'className':_0x566224(0x140),'overlay':l['jsx'](W,{'status':_0x4c7684,'coordinator':_0x4295fb}),'children':l[_0x566224(0x18d)]('button',{'className':f[_0x566224(0x136)]('univer-border-none\x20univer-text-gray-600\x20univer-outline-none',{'univer-cursor-not-allowed':_0x4c7684===u['OFFLINE'],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x4c7684!==u[_0x566224(0x173)]}),'type':'button','children':l[_0x566224(0x18d)](R,{'className':_0x566224(0x14f)})})}):null;}function W(_0x3ceb2d){const _0x25510b=_0x276616,{status:_0x365b00,coordinator:_0x2b6062}=_0x3ceb2d;switch(_0x365b00){case u[_0x25510b(0x178)]:return l['jsx'](G,{'coordinator':_0x2b6062});case u['FOLLOWING']:return l['jsx'](B,{'coordinator':_0x2b6062});case u[_0x25510b(0x14c)]:return l[_0x25510b(0x18d)](Y,{'coordinator':_0x2b6062});case u[_0x25510b(0x173)]:return l[_0x25510b(0x18d)](J,{});case u[_0x25510b(0x141)]:return l[_0x25510b(0x18d)](Z,{'coordinator':_0x2b6062});default:return null;}}function G(_0x16f3ad){const _0x3b1250=_0x276616,{coordinator:_0x323a66}=_0x16f3ad;return l[_0x3b1250(0x16c)](l['Fragment'],{'children':[l['jsx'](_0x3b1250(0x162),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':'Present\x20this\x20document'}),l[_0x3b1250(0x18d)](f[_0x3b1250(0x163)],{'onClick':()=>_0x323a66[_0x3b1250(0x114)](),'children':_0x3b1250(0x1af)})]});}function B(_0x387fc0){const _0x1e5cee=_0x276616,{coordinator:_0x137bfb}=_0x387fc0;return l[_0x1e5cee(0x16c)](l['Fragment'],{'children':[l[_0x1e5cee(0x18d)](_0x1e5cee(0x162),{'className':_0x1e5cee(0x170),'children':'You\x27re\x20following\x20the\x20presenter'}),l[_0x1e5cee(0x18d)](f[_0x1e5cee(0x163)],{'onClick':()=>_0x137bfb[_0x1e5cee(0x131)](),'children':'Stop\x20following'})]});}function Y(_0x53170c){const _0x1c7957=_0x276616,{coordinator:_0x55ef48}=_0x53170c;return l['jsxs'](l['Fragment'],{'children':[l[_0x1c7957(0x18d)]('div',{'className':_0x1c7957(0x170),'children':_0x1c7957(0x166)}),l['jsx'](f['Button'],{'variant':_0x1c7957(0x167),'onClick':()=>_0x55ef48['startFollowing'](),'children':_0x1c7957(0x149)})]});}function Z(_0x38d8f4){const _0x56d5f1=_0x276616,{coordinator:_0x333a55}=_0x38d8f4;return l['jsxs'](l[_0x56d5f1(0x14b)],{'children':[l[_0x56d5f1(0x18d)](_0x56d5f1(0x162),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':'You\x27re\x20presenting\x20the\x20document'}),l[_0x56d5f1(0x18d)](f[_0x56d5f1(0x163)],{'variant':'default','onClick':()=>_0x333a55[_0x56d5f1(0x10e)](),'children':_0x56d5f1(0x153)})]});}function J(){const _0x3ebbf9=_0x276616;return l['jsx'](l['Fragment'],{'children':_0x3ebbf9(0x1bd)});}var K=Object[_0x276616(0x12c)],z=(_0x3778c6,_0x4899bc,_0xa2d317,_0x4b786b)=>{const _0x437475=_0x276616;for(var _0x382d64=_0x4b786b>0x1?void 0x0:_0x4b786b?K(_0x4899bc,_0xa2d317):_0x4899bc,_0x1723bc=_0x3778c6[_0x437475(0x16a)]-0x1,_0xd3cc56;_0x1723bc>=0x0;_0x1723bc--)(_0xd3cc56=_0x3778c6[_0x1723bc])&&(_0x382d64=_0xd3cc56(_0x382d64)||_0x382d64);return _0x382d64;},L=(_0x38792b,_0x34378c)=>(_0x13f9d6,_0x4fa3d4)=>_0x34378c(_0x13f9d6,_0x4fa3d4,_0x38792b);exports[_0x276616(0x1a9)]=class extends o['Disposable']{constructor(_0x1bacc8,_0x69095d){const _0x3b6315=_0x276616;super(),this[_0x3b6315(0x11e)]=_0x1bacc8,this['_uiPartsService']=_0x69095d,this[_0x3b6315(0x11f)]();}[_0x276616(0x11f)](){const _0x34dbe0=_0x276616;this[_0x34dbe0(0x13b)](this['_uiPartsService']['registerComponent'](p[_0x34dbe0(0x122)][_0x34dbe0(0x1c1)],()=>p[_0x34dbe0(0x194)]($,this['_injector'])));}},exports[_0x276616(0x1a9)]=z([L(0x0,o['Inject'](o['Injector'])),L(0x1,p['IUIPartsService'])],exports[_0x276616(0x1a9)]);const Q=_0x276616(0x182),w={};var X=Object['getOwnPropertyDescriptor'],ee=(_0x1f1645,_0x44ae54,_0x4ddcaa,_0x1f1707)=>{const _0x300398=_0x276616;for(var _0x280cc4=_0x1f1707>0x1?void 0x0:_0x1f1707?X(_0x44ae54,_0x4ddcaa):_0x44ae54,_0x19f8c8=_0x1f1645[_0x300398(0x16a)]-0x1,_0xeb998;_0x19f8c8>=0x0;_0x19f8c8--)(_0xeb998=_0x1f1645[_0x19f8c8])&&(_0x280cc4=_0xeb998(_0x280cc4)||_0x280cc4);return _0x280cc4;},te=(_0x4601e7,_0x11b0bf)=>(_0x339764,_0x2d3bdd)=>_0x11b0bf(_0x339764,_0x2d3bdd,_0x4601e7);let m=class extends o[_0x276616(0x18f)]{constructor(_0x2a2bcc){const _0x2af609=_0x276616;super(),this[_0x2af609(0x181)]=_0x2a2bcc,this[_0x2af609(0x1c6)]();}[_0x276616(0x1c6)](){const _0x59b38f=_0x276616;[D['SetZoomRatioOperation']['id'],D[_0x59b38f(0x112)]['id'],C[_0x59b38f(0x120)]['id']][_0x59b38f(0x1c8)](_0x44016d=>{const _0xe90e99=_0x59b38f;this[_0xe90e99(0x13b)](this[_0xe90e99(0x181)][_0xe90e99(0x11a)](_0x44016d));});}};m=ee([te(0x0,o['Inject'](E))],m);var ie=Object[_0x276616(0x1cf)],se=Object[_0x276616(0x12c)],ne=(_0x5f35cc,_0x240a08,_0x18744d)=>_0x240a08 in _0x5f35cc?ie(_0x5f35cc,_0x240a08,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x18744d}):_0x5f35cc[_0x240a08]=_0x18744d,re=(_0x599d51,_0x13cc91,_0x20748c,_0x382c15)=>{const _0x5a71c5=_0x276616;for(var _0x29e8ea=_0x382c15>0x1?void 0x0:_0x382c15?se(_0x13cc91,_0x20748c):_0x13cc91,_0x2ee40b=_0x599d51[_0x5a71c5(0x16a)]-0x1,_0x1ee238;_0x2ee40b>=0x0;_0x2ee40b--)(_0x1ee238=_0x599d51[_0x2ee40b])&&(_0x29e8ea=_0x1ee238(_0x29e8ea)||_0x29e8ea);return _0x29e8ea;},N=(_0x3abbd3,_0x4a8933)=>(_0x48ce1d,_0x45bb0a)=>_0x4a8933(_0x48ce1d,_0x45bb0a,_0x3abbd3),A=(_0x5b9640,_0x445979,_0x52cee9)=>ne(_0x5b9640,typeof _0x445979!='symbol'?_0x445979+'':_0x445979,_0x52cee9);function _0x5eb0(_0x395016,_0x5d9f91){_0x395016=_0x395016-0x101;const _0x7d5a47=_0x7d5a();let _0x5eb0ba=_0x7d5a47[_0x395016];return _0x5eb0ba;}const oe=_0x276616(0x1c9);exports['UniverLiveSharePlugin']=class extends o['Plugin']{constructor(_0x4e9e36=w,_0x6a9d87,_0x49c98c){const _0x564cd2=_0x276616;super(),this['_config']=_0x4e9e36,this[_0x564cd2(0x11e)]=_0x6a9d87,this[_0x564cd2(0x1c7)]=_0x49c98c;const {..._0x4388b7}=o['merge']({},w,this[_0x564cd2(0x1d0)]);this[_0x564cd2(0x1c7)][_0x564cd2(0x15b)](Q,_0x4388b7);}['onStarting'](){const _0x9e4c9a=_0x276616;o[_0x9e4c9a(0x175)](this[_0x9e4c9a(0x11e)],o[_0x9e4c9a(0x192)]([[E],[exports[_0x9e4c9a(0x199)]],[m],[exports[_0x9e4c9a(0x1a9)]]],this[_0x9e4c9a(0x1d0)][_0x9e4c9a(0x107)])),o[_0x9e4c9a(0x111)](this['_injector'],[[m]]);}['onRendered'](){const _0x141d64=_0x276616;o['touchDependencies'](this[_0x141d64(0x11e)],[[exports[_0x141d64(0x1a9)]]]);}},A(exports[_0x276616(0x121)],'type',o[_0x276616(0x19a)]['UNIVER_UNKNOWN']),A(exports[_0x276616(0x121)],_0x276616(0x17c),oe),exports[_0x276616(0x121)]=re([o['DependentOn'](b['UniverCollaborationClientPlugin']),N(0x1,o[_0x276616(0x189)](o['Injector'])),N(0x2,o[_0x276616(0x109)])],exports['UniverLiveSharePlugin']),exports['LiveShare']=$,exports['LiveShareService']=E,exports[_0x276616(0x1ad)]=u;
|
|
1
|
+
'use strict';const _0x27a659=_0x5063;(function(_0x25842b,_0x3aa104){const _0xe9edf1=_0x5063,_0x39c090=_0x25842b();while(!![]){try{const _0x445052=-parseInt(_0xe9edf1(0x1e0))/0x1+-parseInt(_0xe9edf1(0x1b1))/0x2+-parseInt(_0xe9edf1(0x1a9))/0x3*(-parseInt(_0xe9edf1(0x15a))/0x4)+parseInt(_0xe9edf1(0x191))/0x5*(-parseInt(_0xe9edf1(0x1f0))/0x6)+-parseInt(_0xe9edf1(0x18c))/0x7*(-parseInt(_0xe9edf1(0x1c0))/0x8)+-parseInt(_0xe9edf1(0x15f))/0x9+parseInt(_0xe9edf1(0x16e))/0xa;if(_0x445052===_0x3aa104)break;else _0x39c090['push'](_0x39c090['shift']());}catch(_0x4b6f52){_0x39c090['push'](_0x39c090['shift']());}}}(_0x1fc6,0x2a102));var T=Object['defineProperty'],U=(_0x13837b,_0x58ce81,_0x42add7)=>_0x58ce81 in _0x13837b?T(_0x13837b,_0x58ce81,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x42add7}):_0x13837b[_0x58ce81]=_0x42add7,_=(_0x33f611,_0x48cef1,_0x450939)=>U(_0x33f611,typeof _0x48cef1!=_0x27a659(0x19c)?_0x48cef1+'':_0x48cef1,_0x450939);Object['defineProperty'](exports,Symbol['toStringTag'],{'value':'Module'});const o=require('@univerjs/core'),p=require('@univerjs/ui'),l=require('react/jsx-runtime'),f=require('@univerjs/design'),v=require('react'),d=require('@univerjs-pro/collaboration'),b=require('@univerjs-pro/collaboration-client'),C=require('@univerjs/sheets'),O=require('rxjs'),I=require('rxjs/operators'),D=require('@univerjs/sheets-ui');function x({ref:_0x2fb0b6,..._0x3b05b3}){const _0x3dfe27=_0x27a659,{icon:_0x228bc6,id:_0x4c7317,className:_0x1ef958,extend:_0x39e9c7,..._0x5bffcc}=_0x3b05b3,_0x4fe64c=(_0x3dfe27(0x148)+_0x4c7317+'\x20'+(_0x1ef958||''))[_0x3dfe27(0x19a)](),_0xd70413=v[_0x3dfe27(0x214)]('_'+H());return j(_0x228bc6,''+_0x4c7317,{'defIds':_0x228bc6[_0x3dfe27(0x208)],'idSuffix':_0xd70413[_0x3dfe27(0x160)]},{'ref':_0x2fb0b6,'className':_0x4fe64c,..._0x5bffcc},_0x39e9c7);}function j(_0x43ace6,_0xa2d5ee,_0x1ccf0f,_0x434f3b,_0x5b07f4){const _0x255e31=_0x27a659;return v[_0x255e31(0x20e)](_0x43ace6[_0x255e31(0x171)],{'key':_0xa2d5ee,...y(_0x43ace6,_0x1ccf0f,_0x5b07f4),..._0x434f3b},(F(_0x43ace6,_0x1ccf0f)[_0x255e31(0x1fa)]||[])[_0x255e31(0x1ee)]((_0x487940,_0x59eb54)=>j(_0x487940,_0xa2d5ee+'-'+_0x43ace6[_0x255e31(0x171)]+'-'+_0x59eb54,_0x1ccf0f,void 0x0,_0x5b07f4)));}function y(_0x2eacde,_0xf4d992,_0x469ddd){const _0x3ee4e3=_0x27a659,_0x3192f2={..._0x2eacde[_0x3ee4e3(0x1e3)]};_0x469ddd!=null&&_0x469ddd[_0x3ee4e3(0x1be)]&&_0x3192f2[_0x3ee4e3(0x159)]===_0x3ee4e3(0x1be)&&(_0x3192f2['fill']=_0x469ddd[_0x3ee4e3(0x1be)]),_0x2eacde[_0x3ee4e3(0x171)]===_0x3ee4e3(0x1b5)&&_0x3192f2['id']&&(_0x3192f2['id']=_0x3192f2['id']+_0xf4d992[_0x3ee4e3(0x1b6)]),Object[_0x3ee4e3(0x172)](_0x3192f2)['forEach'](([_0x13e2fb,_0xe41bcd])=>{const _0x4b5453=_0x3ee4e3;_0x13e2fb===_0x4b5453(0x1b5)&&typeof _0xe41bcd=='string'&&(_0x3192f2[_0x13e2fb]=_0xe41bcd['replace'](/url\(#(.*)\)/,_0x4b5453(0x163)+_0xf4d992['idSuffix']+')'));});const {defIds:_0xb1a8a3}=_0xf4d992;return!_0xb1a8a3||_0xb1a8a3['length']===0x0||(_0x2eacde[_0x3ee4e3(0x171)]===_0x3ee4e3(0x1df)&&_0x3192f2['xlink:href']&&(_0x3192f2[_0x3ee4e3(0x188)]=_0x3192f2[_0x3ee4e3(0x188)]+_0xf4d992[_0x3ee4e3(0x1b6)]),Object['entries'](_0x3192f2)[_0x3ee4e3(0x17b)](([_0xa81291,_0x2578a4])=>{const _0x20f025=_0x3ee4e3;typeof _0x2578a4=='string'&&(_0x3192f2[_0xa81291]=_0x2578a4[_0x20f025(0x19e)](/url\(#(.*)\)/,_0x20f025(0x163)+_0xf4d992[_0x20f025(0x1b6)]+')'));})),_0x3192f2;}function F(_0x228383,_0x1b4874){const _0xb1d0c8=_0x27a659;var _0x4a6409;const {defIds:_0x21582e}=_0x1b4874;return!_0x21582e||_0x21582e[_0xb1d0c8(0x196)]===0x0?_0x228383:_0x228383[_0xb1d0c8(0x171)]===_0xb1d0c8(0x1c5)&&((_0x4a6409=_0x228383[_0xb1d0c8(0x1fa)])!=null&&_0x4a6409[_0xb1d0c8(0x196)])?{..._0x228383,'children':_0x228383[_0xb1d0c8(0x1fa)][_0xb1d0c8(0x1ee)](_0x47ebb0=>typeof _0x47ebb0['attrs']['id']==_0xb1d0c8(0x17a)&&_0x21582e&&_0x21582e['includes'](_0x47ebb0[_0xb1d0c8(0x1e3)]['id'])?{..._0x47ebb0,'attrs':{..._0x47ebb0[_0xb1d0c8(0x1e3)],'id':_0x47ebb0[_0xb1d0c8(0x1e3)]['id']+_0x1b4874[_0xb1d0c8(0x1b6)]}}:_0x47ebb0)}:_0x228383;}function H(){const _0x4aeef2=_0x27a659;return Math[_0x4aeef2(0x1e2)]()[_0x4aeef2(0x18f)](0x24)['substring'](0x2,0x8);}x[_0x27a659(0x165)]=_0x27a659(0x20d);const V={'tag':_0x27a659(0x1ef),'attrs':{'xmlns':_0x27a659(0x1f8),'fill':_0x27a659(0x1a5),'viewBox':_0x27a659(0x14b),'width':_0x27a659(0x217),'height':'1em'},'children':[{'tag':_0x27a659(0x174),'attrs':{'fill':'currentColor','d':_0x27a659(0x213)}},{'tag':_0x27a659(0x174),'attrs':{'fill':_0x27a659(0x1ba),'d':'M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','fillRule':_0x27a659(0x1ea),'clipRule':_0x27a659(0x1ea)}}]},R=v[_0x27a659(0x1ae)](function(_0xa10058,_0x4de63b){const _0x4c63fc=_0x27a659;return v['createElement'](x,Object[_0x4c63fc(0x193)]({},_0xa10058,{'id':_0x4c63fc(0x1c4),'ref':_0x4de63b,'icon':V}));});R[_0x27a659(0x165)]=_0x27a659(0x178);class E extends o[_0x27a659(0x19f)]{constructor(){const _0x11727e=_0x27a659;super(...arguments),_(this,_0x11727e(0x200),new Set()),_(this,'_reporters',new Set());}[_0x27a659(0x185)](_0x31d648){const _0x2236ad=_0x27a659;return this['_sharedOperations'][_0x2236ad(0x179)](_0x31d648),o[_0x2236ad(0x1d1)](()=>this['_sharedOperations'][_0x2236ad(0x16b)](_0x31d648));}[_0x27a659(0x16c)](_0x5d7d78){const _0x5416b3=_0x27a659;return this[_0x5416b3(0x14d)][_0x5416b3(0x179)](_0x5d7d78),o[_0x5416b3(0x1d1)](()=>this[_0x5416b3(0x14d)][_0x5416b3(0x16b)](_0x5d7d78));}[_0x27a659(0x1ed)](_0x341508){const _0x208a24=_0x27a659;return this[_0x208a24(0x200)][_0x208a24(0x16a)](_0x341508);}['getInitialStates'](_0x573caf){const _0x3edb77=_0x27a659;return Array['from'](this[_0x3edb77(0x14d)])[_0x3edb77(0x1ee)](_0x172c49=>_0x172c49(_0x573caf));}}var M=Object['getOwnPropertyDescriptor'],P=(_0x3a50ae,_0x3fc2b0,_0x3f7e82,_0x12bcba)=>{for(var _0x213d95=_0x12bcba>0x1?void 0x0:_0x12bcba?M(_0x3fc2b0,_0x3f7e82):_0x3fc2b0,_0x22ed2d=_0x3a50ae['length']-0x1,_0x21036b;_0x22ed2d>=0x0;_0x22ed2d--)(_0x21036b=_0x3a50ae[_0x22ed2d])&&(_0x213d95=_0x21036b(_0x213d95)||_0x213d95);return _0x213d95;},S=(_0x5da627,_0x3ea071)=>(_0x54852a,_0xd8417)=>_0x3ea071(_0x54852a,_0xd8417,_0x5da627);function _0x5063(_0x2caf26,_0x4fe090){_0x2caf26=_0x2caf26-0x148;const _0x1fc6d4=_0x1fc6();let _0x5063c2=_0x1fc6d4[_0x2caf26];return _0x5063c2;}exports['LiveShareController']=class extends o[_0x27a659(0x154)]{constructor(_0x3fd419,_0x228dd1,_0x274ce9){const _0x245b6f=_0x27a659;super(),_(this,_0x245b6f(0x167),new Map()),(this['_univerInstanceService']=_0x3fd419,this[_0x245b6f(0x150)]=_0x228dd1,this[_0x245b6f(0x198)]=_0x274ce9,this[_0x245b6f(0x1bc)]());}async[_0x27a659(0x16d)](_0x438f52){const _0x291f03=_0x27a659;return this[_0x291f03(0x167)]['has'](_0x438f52)||await this['_startLiveShareCoordinator'](_0x438f52),this[_0x291f03(0x167)][_0x291f03(0x162)](_0x438f52);}['getLiveShareCoordinatorSync'](_0x209279){const _0x154d91=_0x27a659;var _0x440f94;return(_0x440f94=this[_0x154d91(0x167)]['get'](_0x209279))!=null?_0x440f94:null;}[_0x27a659(0x1bc)](){const _0x2ed358=_0x27a659;this[_0x2ed358(0x155)][_0x2ed358(0x158)](o[_0x2ed358(0x14a)][_0x2ed358(0x1cc)])['pipe'](I[_0x2ed358(0x215)](this[_0x2ed358(0x206)]))[_0x2ed358(0x1e9)](async _0x3ceb75=>{const _0x46096b=_0x2ed358,_0x2bda13=_0x3ceb75[_0x46096b(0x1d7)]();this[_0x46096b(0x167)][_0x46096b(0x16a)](_0x2bda13)||this[_0x46096b(0x1fe)](_0x2bda13);}),this[_0x2ed358(0x155)][_0x2ed358(0x194)](o['UniverInstanceType'][_0x2ed358(0x1cc)])[_0x2ed358(0x1a8)](I[_0x2ed358(0x215)](this[_0x2ed358(0x206)]))[_0x2ed358(0x1e9)](_0x30e332=>{const _0x31215e=_0x2ed358,_0x85e6e0=_0x30e332[_0x31215e(0x1d7)](),_0x3b5ad3=this[_0x31215e(0x167)]['get'](_0x85e6e0);_0x3b5ad3==null||_0x3b5ad3[_0x31215e(0x18b)]();});}async['_startLiveShareCoordinator'](_0x31390c){const _0x3cfc05=_0x27a659,_0x188907=await this[_0x3cfc05(0x198)]['requireSession'](_0x31390c),_0x216baa=this[_0x3cfc05(0x150)]['createInstance'](exports[_0x3cfc05(0x218)],_0x31390c,_0x188907);return _0x216baa['init'](),this['_entities'][_0x3cfc05(0x211)](_0x31390c,_0x216baa),_0x216baa;}},exports[_0x27a659(0x181)]=P([S(0x0,o['IUniverInstanceService']),S(0x1,o[_0x27a659(0x1aa)](o[_0x27a659(0x1d0)])),S(0x2,o[_0x27a659(0x1aa)](b[_0x27a659(0x1f7)]))],exports[_0x27a659(0x181)]);var u=(_0xa6e20c=>(_0xa6e20c[_0x27a659(0x1c8)]='offline',_0xa6e20c['IDLE']=_0x27a659(0x15b),_0xa6e20c[_0x27a659(0x197)]='following',_0xa6e20c[_0x27a659(0x1b8)]=_0x27a659(0x168),_0xa6e20c[_0x27a659(0x199)]='presenting',_0xa6e20c))(u||{});const k=_0x27a659(0x1c3),q=0xc8;exports[_0x27a659(0x218)]=class extends o['RxDisposable']{constructor(_0x1354e8,_0x192301,_0xf3ca14,_0x5a0931,_0x212f12){const _0x3514b4=_0x27a659;super(),_(this,_0x3514b4(0x1c7),new O[(_0x3514b4(0x1e4))](_0x3514b4(0x15b))),_(this,'status$',this[_0x3514b4(0x1c7)][_0x3514b4(0x205)]()),_(this,'_init',!0x1),_(this,'_commandDisposable',null),_(this,'_presenter',null),(this['_unitID']=_0x1354e8,this[_0x3514b4(0x1a3)]=_0x192301,this[_0x3514b4(0x1ce)]=_0xf3ca14,this['_liveShareService']=_0x5a0931,this['_commandService']=_0x212f12);}get[_0x27a659(0x14f)](){const _0x3822f0=_0x27a659;return this[_0x3822f0(0x1c7)][_0x3822f0(0x157)]();}['dispose'](){const _0x5197a2=_0x27a659;var _0x1393f9;(_0x1393f9=this[_0x5197a2(0x173)])==null||_0x1393f9['dispose'](),this[_0x5197a2(0x1c7)][_0x5197a2(0x1c2)](_0x5197a2(0x15b)),this[_0x5197a2(0x1c7)][_0x5197a2(0x14e)]();}[_0x27a659(0x204)](){return this['_status'];}[_0x27a659(0x186)](){const _0x426df3=_0x27a659;this[_0x426df3(0x1bc)]||(this['_init']=!0x0,this[_0x426df3(0x1a3)][_0x426df3(0x1f9)][_0x426df3(0x1a8)](I['takeUntil'](this[_0x426df3(0x206)]))[_0x426df3(0x1e9)](_0x349549=>{const _0x5a7a58=_0x426df3;switch(_0x349549){case b[_0x5a7a58(0x1db)][_0x5a7a58(0x1c8)]:this['_handleOffline']();break;case b[_0x5a7a58(0x1db)]['ONLINE']:this[_0x5a7a58(0x18a)]();break;}}),this[_0x426df3(0x1a3)][_0x426df3(0x1fc)][_0x426df3(0x1a8)](I[_0x426df3(0x215)](this[_0x426df3(0x206)]))[_0x426df3(0x1e9)](_0x14f63c=>{const _0x3b1b18=_0x426df3,{eventID:_0x2845d3}=_0x14f63c;switch(_0x2845d3){case d[_0x3b1b18(0x176)][_0x3b1b18(0x1af)]:this[_0x3b1b18(0x1f6)](_0x14f63c);break;case d[_0x3b1b18(0x176)][_0x3b1b18(0x1e6)]:this[_0x3b1b18(0x201)](_0x14f63c);break;case d['CollaborationEvent'][_0x3b1b18(0x17f)]:this[_0x3b1b18(0x187)]();break;case d[_0x3b1b18(0x176)][_0x3b1b18(0x1b3)]:this[_0x3b1b18(0x1ad)](_0x14f63c);break;}}));}['tryStartPresenting'](){const _0x138bae=_0x27a659;this[_0x138bae(0x1a3)][_0x138bae(0x161)]({'eventID':d[_0x138bae(0x176)]['LIVESHARE_REQUEST_HOST'],'data':{'unitID':this[_0x138bae(0x17d)],'userID':this[_0x138bae(0x1a3)][_0x138bae(0x189)]()}},this[_0x138bae(0x17d)]);}['stopPresenting'](){const _0x827171=_0x27a659;this[_0x827171(0x14f)]===_0x827171(0x1bd)&&(this[_0x827171(0x1c7)][_0x827171(0x1c2)]('idle'),this[_0x827171(0x1a3)][_0x827171(0x161)]({'eventID':d['CollaborationEvent']['LIVESHARE_TERMINATE'],'data':{'unitID':this[_0x827171(0x17d)]}},this[_0x827171(0x17d)]));}[_0x27a659(0x1ac)](){const _0x5ee5c4=_0x27a659;this[_0x5ee5c4(0x14f)]===_0x5ee5c4(0x168)&&(this[_0x5ee5c4(0x1c7)][_0x5ee5c4(0x1c2)](_0x5ee5c4(0x1d6)),this[_0x5ee5c4(0x1dd)]());}['stopFollowing'](){const _0x5bc09d=_0x27a659;this[_0x5bc09d(0x14f)]==='following'&&this[_0x5bc09d(0x1c1)]();}[_0x27a659(0x1f6)](_0x55c49f){const _0x14af93=_0x27a659,{presenter:_0x51faaf}=_0x55c49f[_0x14af93(0x1ca)],_0x1e86d5=this['_collabSession'][_0x14af93(0x189)]();this[_0x14af93(0x1c9)]=_0x51faaf,_0x51faaf===_0x1e86d5?(this[_0x14af93(0x1c1)](),this[_0x14af93(0x1da)]()):this[_0x14af93(0x14f)]!==_0x14af93(0x168)&&(this[_0x14af93(0x210)](),this[_0x14af93(0x1dd)]());}[_0x27a659(0x1b7)](){const _0xcbe2a6=_0x27a659,_0x4f227d={'eventID':d[_0xcbe2a6(0x176)]['LIVESHARE_FETCH_OPERATIONS']};this['_collabSession']['send'](_0x4f227d,this[_0xcbe2a6(0x17d)]);}[_0x27a659(0x187)](){const _0x45022a=_0x27a659;this[_0x45022a(0x1c9)]=null,this[_0x45022a(0x14f)]!=='presenting'&&this[_0x45022a(0x1eb)]();}['_handleNewChangeSets'](_0x11fa1a){const _0x2f76e2=_0x27a659;if(this[_0x2f76e2(0x14f)]===_0x2f76e2(0x1d6)&&this['_presenter']===_0x11fa1a[_0x2f76e2(0x1ca)]['memberID']){const _0x3aead0=d[_0x2f76e2(0x1b4)](_0x11fa1a[_0x2f76e2(0x1ca)])['mutations'][_0x2f76e2(0x1d5)]()[_0x2f76e2(0x175)](_0x37474e=>_0x37474e['id']===C['InsertSheetMutation']['id']);if(_0x3aead0){const _0x295b35=_0x3aead0[_0x2f76e2(0x183)][_0x2f76e2(0x152)],_0x1bbab3=_0x3aead0['params'][_0x2f76e2(0x17c)]['id'];setTimeout(()=>{const _0x594124=_0x2f76e2;this[_0x594124(0x15c)][_0x594124(0x1e1)](C[_0x594124(0x166)]['id'],{'unitId':_0x295b35,'subUnitId':_0x1bbab3},{'fromCollab':!0x0});});}}}[_0x27a659(0x1da)](){const _0x4bba7e=_0x27a659;this['_status$']['next'](_0x4bba7e(0x1bd));const _0x31f4bf=new Map(),_0x29cf2c=this[_0x4bba7e(0x173)]=new o[(_0x4bba7e(0x1b0))]();_0x29cf2c[_0x4bba7e(0x179)](o[_0x4bba7e(0x1d1)](()=>{const _0x43924d=_0x4bba7e;_0x31f4bf[_0x43924d(0x17b)](_0x7ee812=>_0x7ee812['complete']()),_0x31f4bf[_0x43924d(0x177)]();})),_0x29cf2c[_0x4bba7e(0x179)](this[_0x4bba7e(0x15c)]['onCommandExecuted'](_0x2e792c=>{const _0x3ab56e=_0x4bba7e;var _0x3d4352;if(_0x2e792c[_0x3ab56e(0x203)]!==o[_0x3ab56e(0x1cb)][_0x3ab56e(0x1d2)]||!this['_liveShareService'][_0x3ab56e(0x1ed)](_0x2e792c['id']))return;const {id:_0x1139dc}=_0x2e792c;let _0x60b91e;_0x31f4bf['has'](_0x1139dc)?_0x60b91e=_0x31f4bf[_0x3ab56e(0x162)](_0x1139dc):(_0x60b91e=new O[(_0x3ab56e(0x1b9))](),_0x31f4bf[_0x3ab56e(0x211)](_0x1139dc,_0x60b91e),_0x60b91e[_0x3ab56e(0x1a8)](I[_0x3ab56e(0x16f)]((_0x3d4352=this[_0x3ab56e(0x1ce)][_0x3ab56e(0x1e5)](k))!=null?_0x3d4352:q,void 0x0,{'trailing':!0x0,'leading':!0x0}))[_0x3ab56e(0x1e9)](_0x3005b2=>{const _0xdc0dd3=_0x3ab56e;this['_collabSession']['send']({'eventID':d[_0xdc0dd3(0x176)][_0xdc0dd3(0x1e6)],'data':{'unitID':this[_0xdc0dd3(0x17d)],'operations':{[_0x3005b2['id']]:{'id':_0x3005b2['id'],'params':JSON[_0xdc0dd3(0x190)](_0x3005b2[_0xdc0dd3(0x183)])}}}},this[_0xdc0dd3(0x17d)]);})),_0x60b91e['next'](_0x2e792c);})),this[_0x4bba7e(0x1c6)][_0x4bba7e(0x19b)](this[_0x4bba7e(0x17d)])[_0x4bba7e(0x17b)](_0x57f590=>this[_0x4bba7e(0x1a3)][_0x4bba7e(0x161)]({'eventID':d[_0x4bba7e(0x176)]['LIVESHARE_OPERATION'],'data':{'unitID':this[_0x4bba7e(0x17d)],'operations':{[_0x57f590['id']]:{'id':_0x57f590['id'],'params':JSON[_0x4bba7e(0x190)](_0x57f590[_0x4bba7e(0x183)])}}}},this[_0x4bba7e(0x17d)]));}['_stopPresenting'](){const _0x17672=_0x27a659;var _0x641df4;this[_0x17672(0x1c7)][_0x17672(0x1c2)](_0x17672(0x15b)),(_0x641df4=this[_0x17672(0x173)])==null||_0x641df4[_0x17672(0x18b)](),this[_0x17672(0x173)]=null;}['_startFollowing'](){const _0xa3e11e=_0x27a659;var _0x35527b;(_0x35527b=this[_0xa3e11e(0x173)])==null||_0x35527b['dispose'](),this[_0xa3e11e(0x1c7)][_0xa3e11e(0x1c2)]('following');}['_beIdle'](){const _0x4852d1=_0x27a659;var _0x1fe3f8;this[_0x4852d1(0x1c7)][_0x4852d1(0x1c2)]('idle'),(_0x1fe3f8=this['_commandDisposable'])==null||_0x1fe3f8[_0x4852d1(0x18b)](),this[_0x4852d1(0x173)]=null;}['_stopFollowing'](){const _0x37a7b1=_0x27a659;var _0x5aa099;this[_0x37a7b1(0x1c7)][_0x37a7b1(0x1c2)](_0x37a7b1(0x168)),(_0x5aa099=this['_commandDisposable'])==null||_0x5aa099[_0x37a7b1(0x18b)]();}[_0x27a659(0x201)](_0x53dd85){const _0x53b0bf=_0x27a659;if([_0x53b0bf(0x1bd),_0x53b0bf(0x168),_0x53b0bf(0x1f3)][_0x53b0bf(0x1fd)](this['_status'])||!_0x53dd85['data'][_0x53b0bf(0x20f)]||_0x53dd85[_0x53b0bf(0x1ca)][_0x53b0bf(0x20f)]===this['_collabSession'][_0x53b0bf(0x189)]())return;this['_status']===_0x53b0bf(0x15b)&&this[_0x53b0bf(0x1dd)]();const _0x4d490c=_0x53dd85[_0x53b0bf(0x1ca)]['operations'];Object['values'](_0x4d490c)[_0x53b0bf(0x17b)](_0xb050ae=>{const _0x168910=_0x53b0bf;this[_0x168910(0x15c)]['executeCommand'](_0xb050ae['id'],_0xb050ae['params']?JSON[_0x168910(0x20c)](_0xb050ae[_0x168910(0x183)]):null,{'fromCollab':!0x0});});}[_0x27a659(0x20a)](){const _0x25c156=_0x27a659;var _0x18ac8d;this[_0x25c156(0x1c7)]['next'](_0x25c156(0x1f3)),(_0x18ac8d=this[_0x25c156(0x173)])==null||_0x18ac8d[_0x25c156(0x18b)]();}[_0x27a659(0x18a)](){const _0x248d71=_0x27a659;this[_0x248d71(0x1c7)][_0x248d71(0x1c2)]('idle'),this[_0x248d71(0x1b7)]();}},exports['LiveShareCoordinator']=P([S(0x2,o[_0x27a659(0x1a1)]),S(0x3,o[_0x27a659(0x1aa)](E)),S(0x4,o[_0x27a659(0x1ff)])],exports['LiveShareCoordinator']);function $(){const _0x2cd295=_0x27a659,_0x28a554=p[_0x2cd295(0x1cf)](exports[_0x2cd295(0x181)]),_0x4d4f59=p[_0x2cd295(0x1cf)](o[_0x2cd295(0x1d9)]),_0x2a9e08=p['useObservable'](()=>_0x4d4f59[_0x2cd295(0x180)](o['UniverInstanceType'][_0x2cd295(0x1cc)]),void 0x0,!0x1,[]),[_0x201507,_0x2f0833]=v[_0x2cd295(0x1cd)](null),[_0x27600a,_0x230cd1]=v[_0x2cd295(0x1cd)](u[_0x2cd295(0x1d8)]),_0xb1895f=v[_0x2cd295(0x214)](null);return v[_0x2cd295(0x1fb)](()=>(_0x2a9e08&&_0x28a554[_0x2cd295(0x16d)](_0x2a9e08['getUnitId']())['then'](_0x158f07=>{const _0x26d7a8=_0x2cd295;_0x2f0833(_0x158f07),_0xb1895f[_0x26d7a8(0x160)]=_0x158f07[_0x26d7a8(0x219)][_0x26d7a8(0x1e9)](_0x455c9a=>{_0x230cd1(_0x455c9a);});}),()=>{const _0x19285d=_0x2cd295;var _0x1879f3;(_0x1879f3=_0xb1895f['current'])==null||_0x1879f3[_0x19285d(0x1d3)](),_0xb1895f[_0x19285d(0x160)]=null;}),[_0x2a9e08,_0x28a554]),_0x201507?l[_0x2cd295(0x170)](f['Dropdown'],{'align':_0x2cd295(0x18d),'disabled':_0x27600a===u[_0x2cd295(0x1c8)],'className':_0x2cd295(0x1a4),'overlay':l[_0x2cd295(0x170)](W,{'status':_0x27600a,'coordinator':_0x201507}),'children':l['jsx'](_0x2cd295(0x207),{'className':f['clsx']('univer-border-none\x20univer-text-gray-600\x20univer-outline-none',{'univer-cursor-not-allowed':_0x27600a===u[_0x2cd295(0x1c8)],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x27600a!==u['OFFLINE']}),'type':'button','children':l[_0x2cd295(0x170)](R,{'className':_0x2cd295(0x192)})})}):null;}function W(_0xc095c5){const _0x4187f7=_0x27a659,{status:_0x8234cd,coordinator:_0x361bb8}=_0xc095c5;switch(_0x8234cd){case u[_0x4187f7(0x1d8)]:return l[_0x4187f7(0x170)](G,{'coordinator':_0x361bb8});case u[_0x4187f7(0x197)]:return l[_0x4187f7(0x170)](B,{'coordinator':_0x361bb8});case u[_0x4187f7(0x1b8)]:return l[_0x4187f7(0x170)](Y,{'coordinator':_0x361bb8});case u[_0x4187f7(0x1c8)]:return l[_0x4187f7(0x170)](J,{});case u[_0x4187f7(0x199)]:return l[_0x4187f7(0x170)](Z,{'coordinator':_0x361bb8});default:return null;}}function G(_0x2d2097){const _0x5790d5=_0x27a659,{coordinator:_0x3aec91}=_0x2d2097;return l['jsxs'](l['Fragment'],{'children':[l[_0x5790d5(0x170)](_0x5790d5(0x164),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x5790d5(0x149)}),l['jsx'](f[_0x5790d5(0x1a7)],{'onClick':()=>_0x3aec91[_0x5790d5(0x151)](),'children':_0x5790d5(0x1f2)})]});}function B(_0x112252){const _0xdff972=_0x27a659,{coordinator:_0x58a6ea}=_0x112252;return l[_0xdff972(0x1a2)](l[_0xdff972(0x195)],{'children':[l[_0xdff972(0x170)](_0xdff972(0x164),{'className':_0xdff972(0x1bf),'children':_0xdff972(0x1b2)}),l['jsx'](f[_0xdff972(0x1a7)],{'onClick':()=>_0x58a6ea['stopFollowing'](),'children':_0xdff972(0x1f4)})]});}function Y(_0x177ec9){const _0x399258=_0x27a659,{coordinator:_0x88adb1}=_0x177ec9;return l[_0x399258(0x1a2)](l[_0x399258(0x195)],{'children':[l[_0x399258(0x170)]('div',{'className':_0x399258(0x1bf),'children':_0x399258(0x17e)}),l[_0x399258(0x170)](f[_0x399258(0x1a7)],{'variant':'text','onClick':()=>_0x88adb1[_0x399258(0x1ac)](),'children':'Start\x20following'})]});}function Z(_0x3a3164){const _0x15ec2a=_0x27a659,{coordinator:_0x29c93a}=_0x3a3164;return l[_0x15ec2a(0x1a2)](l[_0x15ec2a(0x195)],{'children':[l[_0x15ec2a(0x170)](_0x15ec2a(0x164),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x15ec2a(0x169)}),l['jsx'](f[_0x15ec2a(0x1a7)],{'variant':_0x15ec2a(0x156),'onClick':()=>_0x29c93a['stopPresenting'](),'children':_0x15ec2a(0x209)})]});}function J(){const _0x10ef9d=_0x27a659;return l[_0x10ef9d(0x170)](l[_0x10ef9d(0x195)],{'children':'You\x27are\x20offline.'});}var K=Object[_0x27a659(0x182)],z=(_0x1d8fb9,_0x48a849,_0xa011e2,_0x21d416)=>{const _0xe9ef9a=_0x27a659;for(var _0x5b6a2b=_0x21d416>0x1?void 0x0:_0x21d416?K(_0x48a849,_0xa011e2):_0x48a849,_0x38441d=_0x1d8fb9[_0xe9ef9a(0x196)]-0x1,_0x2d7656;_0x38441d>=0x0;_0x38441d--)(_0x2d7656=_0x1d8fb9[_0x38441d])&&(_0x5b6a2b=_0x2d7656(_0x5b6a2b)||_0x5b6a2b);return _0x5b6a2b;},L=(_0x1d5f06,_0x5e1c7a)=>(_0x538e32,_0x3baa03)=>_0x5e1c7a(_0x538e32,_0x3baa03,_0x1d5f06);exports[_0x27a659(0x216)]=class extends o[_0x27a659(0x19f)]{constructor(_0x29da6b,_0x2ab656){const _0x52fb4c=_0x27a659;super(),this[_0x52fb4c(0x150)]=_0x29da6b,this[_0x52fb4c(0x153)]=_0x2ab656,this[_0x52fb4c(0x15e)]();}[_0x27a659(0x15e)](){const _0x2d425e=_0x27a659;this[_0x2d425e(0x1a6)](this['_uiPartsService'][_0x2d425e(0x19d)](p['BuiltInUIPart'][_0x2d425e(0x1e7)],()=>p['connectInjector']($,this[_0x2d425e(0x150)])));}},exports[_0x27a659(0x216)]=z([L(0x0,o[_0x27a659(0x1aa)](o[_0x27a659(0x1d0)])),L(0x1,p['IUIPartsService'])],exports[_0x27a659(0x216)]);const Q='live-share.config',w={};var X=Object[_0x27a659(0x182)],ee=(_0x371532,_0x5beec9,_0xebdf11,_0x2d133e)=>{const _0xb90683=_0x27a659;for(var _0xaeb4d2=_0x2d133e>0x1?void 0x0:_0x2d133e?X(_0x5beec9,_0xebdf11):_0x5beec9,_0x4667c3=_0x371532[_0xb90683(0x196)]-0x1,_0x289836;_0x4667c3>=0x0;_0x4667c3--)(_0x289836=_0x371532[_0x4667c3])&&(_0xaeb4d2=_0x289836(_0xaeb4d2)||_0xaeb4d2);return _0xaeb4d2;},te=(_0x3e3b94,_0x4552a6)=>(_0x17d524,_0x48e8d3)=>_0x4552a6(_0x17d524,_0x48e8d3,_0x3e3b94);function _0x1fc6(){const _0x56fdac=['getUnitId','IDLE','IUniverInstanceService','_startPresenting','SessionStatus','LiveShareService','_startFollowing','UniverLiveSharePlugin','use','94170bfSeIh','executeCommand','random','attrs','BehaviorSubject','getConfig','LIVESHARE_OPERATION','HEADER_MENU','onStarting','subscribe','evenodd','_beIdle','pluginName','shouldShareOperation','map','svg','865002cfBtjG','_config','Start','offline','Stop\x20following','DependentOn','_handleNewHost','CollaborationSessionService','http://www.w3.org/2000/svg','sessionStatus$','children','useEffect','event$','includes','_startLiveShareCoordinator','ICommandService','_sharedOperations','_handleOperation','defineProperty','type','getStatus','asObservable','dispose$','button','defIds','Stop\x20presenting','_handleOffline','LiveShare','parse','UniverIcon','createElement','presenter','_stopPresenting','set','touchDependencies','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','useRef','takeUntil','DesktopLiveShareController','1em','LiveShareCoordinator','status$','univerjs-icon\x20univerjs-icon-','Present\x20this\x20document','UniverInstanceType','0\x200\x2017\x2017','UniverCollaborationClientPlugin','_reporters','complete','_status','_injector','tryStartPresenting','unitId','_uiPartsService','RxDisposable','_univerInstanceService','default','getValue','getTypeOfUnitAdded$','fill','1362524KUsbTi','idle','_commandService','override','_mountLiveShare','500265ynlwSR','current','send','get','url(#$1','div','displayName','SetWorksheetActiveOperation','_entities','not-following','You\x27re\x20presenting\x20the\x20document','has','delete','registerInitialStateReporter','getLiveShareCoordinator','769990ySsMeU','throttleTime','jsx','tag','entries','_commandDisposable','path','find','CollaborationEvent','clear','LiveShareIcon','add','string','forEach','sheet','_unitID','You\x27re\x20not\x20following\x20the\x20presenter','LIVESHARE_TERMINATE','getCurrentTypeOfUnit$','LiveShareController','getOwnPropertyDescriptor','params','onRendered','registerSharedOperation','init','_handleTerminate','xlink:href','getMemberID','_handleOnline','dispose','108283OsnpnM','end','merge','toString','stringify','5kneAiP','univer-size-4','assign','getTypeOfUnitDisposed$','Fragment','length','FOLLOWING','_collabSessionService','PRESENTING','trim','getInitialStates','symbol','registerComponent','replace','Disposable','SetZoomRatioOperation','IConfigService','jsxs','_collabSession','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','none','disposeWithMe','Button','pipe','3YSeCxZ','Inject','UNIVER_LIVE_SHARE_PLUGIN','startFollowing','_handleNewChangeSets','forwardRef','LIVESHARE_NEW_HOST','DisposableCollection','335968iixnqB','You\x27re\x20following\x20the\x20presenter','NEW_CHANGESETS','parseProtocolChangeset','mask','idSuffix','_fetchOperations','NOT_FOLLOWING','Subject','currentColor','setConfig','_init','presenting','colorChannel1','univer-mb-3\x20univer-w-full\x20univer-text-sm','112ivYRPa','_stopFollowing','next','SAME_OPERATION_SHARE_INTERVAL','live-share-icon','defs','_liveShareService','_status$','OFFLINE','_presenter','data','CommandType','UNIVER_SHEET','useState','_configService','useDependency','Injector','toDisposable','OPERATION','unsubscribe','mergeOverrideWithDependencies','reverse','following'];_0x1fc6=function(){return _0x56fdac;};return _0x1fc6();}let m=class extends o[_0x27a659(0x19f)]{constructor(_0x443e09){const _0x2fa4f3=_0x27a659;super(),this[_0x2fa4f3(0x1c6)]=_0x443e09,this[_0x2fa4f3(0x1bc)]();}[_0x27a659(0x1bc)](){const _0xbd04f8=_0x27a659;[D[_0xbd04f8(0x1a0)]['id'],D['SetScrollOperation']['id'],C[_0xbd04f8(0x166)]['id']][_0xbd04f8(0x17b)](_0x4d5252=>{const _0x54ae0d=_0xbd04f8;this[_0x54ae0d(0x1a6)](this[_0x54ae0d(0x1c6)][_0x54ae0d(0x185)](_0x4d5252));});}};m=ee([te(0x0,o[_0x27a659(0x1aa)](E))],m);var ie=Object[_0x27a659(0x202)],se=Object[_0x27a659(0x182)],ne=(_0x18107d,_0x1ae42e,_0x5269aa)=>_0x1ae42e in _0x18107d?ie(_0x18107d,_0x1ae42e,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x5269aa}):_0x18107d[_0x1ae42e]=_0x5269aa,re=(_0x2fc9fa,_0x4598d4,_0x581596,_0x1efbc4)=>{const _0x53752b=_0x27a659;for(var _0x4b07d9=_0x1efbc4>0x1?void 0x0:_0x1efbc4?se(_0x4598d4,_0x581596):_0x4598d4,_0x83656c=_0x2fc9fa[_0x53752b(0x196)]-0x1,_0x52c9b6;_0x83656c>=0x0;_0x83656c--)(_0x52c9b6=_0x2fc9fa[_0x83656c])&&(_0x4b07d9=_0x52c9b6(_0x4b07d9)||_0x4b07d9);return _0x4b07d9;},N=(_0x2de363,_0x2fbcca)=>(_0x23b29b,_0x3d6449)=>_0x2fbcca(_0x23b29b,_0x3d6449,_0x2de363),A=(_0x168177,_0x3a25cc,_0x31a9a3)=>ne(_0x168177,typeof _0x3a25cc!='symbol'?_0x3a25cc+'':_0x3a25cc,_0x31a9a3);const oe=_0x27a659(0x1ab);exports[_0x27a659(0x1de)]=class extends o['Plugin']{constructor(_0x4f25af=w,_0x1431f6,_0x32c77c){const _0x28b7e5=_0x27a659;super(),this[_0x28b7e5(0x1f1)]=_0x4f25af,this[_0x28b7e5(0x150)]=_0x1431f6,this['_configService']=_0x32c77c;const {..._0x54670b}=o[_0x28b7e5(0x18e)]({},w,this['_config']);this['_configService'][_0x28b7e5(0x1bb)](Q,_0x54670b);}[_0x27a659(0x1e8)](){const _0xa0a435=_0x27a659;o['registerDependencies'](this[_0xa0a435(0x150)],o[_0xa0a435(0x1d4)]([[E],[exports[_0xa0a435(0x181)]],[m],[exports[_0xa0a435(0x216)]]],this['_config'][_0xa0a435(0x15d)])),o[_0xa0a435(0x212)](this[_0xa0a435(0x150)],[[m]]);}[_0x27a659(0x184)](){const _0x4b5504=_0x27a659;o[_0x4b5504(0x212)](this[_0x4b5504(0x150)],[[exports[_0x4b5504(0x216)]]]);}},A(exports[_0x27a659(0x1de)],_0x27a659(0x203),o['UniverInstanceType']['UNIVER_UNKNOWN']),A(exports[_0x27a659(0x1de)],_0x27a659(0x1ec),oe),exports['UniverLiveSharePlugin']=re([o[_0x27a659(0x1f5)](b[_0x27a659(0x14c)]),N(0x1,o[_0x27a659(0x1aa)](o[_0x27a659(0x1d0)])),N(0x2,o[_0x27a659(0x1a1)])],exports[_0x27a659(0x1de)]),exports[_0x27a659(0x20b)]=$,exports[_0x27a659(0x1dc)]=E,exports['LiveShareStatus']=u;
|
package/lib/es/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const _0x2561c3=_0x639e;function _0x639e(_0x26429c,_0x5f5b79){_0x26429c=_0x26429c-0xcc;const _0x17e9a0=_0x17e9();let _0x639ef=_0x17e9a0[_0x26429c];return _0x639ef;}(function(_0x122c71,_0x4438d4){const _0x4c5884=_0x639e,_0x47910b=_0x122c71();while(!![]){try{const _0x2c6626=-parseInt(_0x4c5884(0xd2))/0x1+-parseInt(_0x4c5884(0xd3))/0x2+parseInt(_0x4c5884(0xe6))/0x3*(-parseInt(_0x4c5884(0xe3))/0x4)+-parseInt(_0x4c5884(0xda))/0x5*(parseInt(_0x4c5884(0xdc))/0x6)+parseInt(_0x4c5884(0xcd))/0x7+-parseInt(_0x4c5884(0xeb))/0x8*(parseInt(_0x4c5884(0xd1))/0x9)+-parseInt(_0x4c5884(0xce))/0xa*(-parseInt(_0x4c5884(0xd9))/0xb);if(_0x2c6626===_0x4438d4)break;else _0x47910b['push'](_0x47910b['shift']());}catch(_0x245698){_0x47910b['push'](_0x47910b['shift']());}}}(_0x17e9,0x2e84b));import{LiveShareController as _0x204761,LiveShareStatus as _0x5af292}from'@univerjs-pro/live-share';import{IRenderManagerService as _0x585a07}from'@univerjs/engine-render';import{SetWorksheetActiveOperation as _0xabbfd8}from'@univerjs/sheets';import{SetScrollOperation as _0x2dfe55}from'@univerjs/sheets-ui';import{FRange as _0x426e48}from'@univerjs/sheets/facade';import{FUniver as _0x29f894,FEnum as _0x444374}from'@univerjs/core/facade';class I extends _0x426e48{[_0x2561c3(0xdd)](_0x3056de,_0x5b0d90,_0x35a303,_0x52bbd4,_0x51f56c){const _0x5b3b59=_0x2561c3,_0x59bb58=_0x3056de[_0x5b3b59(0xe5)](_0x204761),_0x1e4fd5=_0x3056de[_0x5b3b59(0xe5)](_0x585a07),_0x549598=_0x5b0d90['getUnitId'](),_0x3ff9f1=_0x5b0d90[_0x5b3b59(0xe4)](),_0x108e77=_0x59bb58[_0x5b3b59(0xcc)](_0x549598);(_0x108e77==null?void 0x0:_0x108e77[_0x5b3b59(0xd6)]())!==_0x5af292['PRESENTING']||(_0x35a303[_0x5b3b59(0xd4)]()!==_0x3ff9f1[_0x5b3b59(0xd4)]()&&this[_0x5b3b59(0xdf)][_0x5b3b59(0xe9)](_0xabbfd8['id'],{'unitId':_0x549598,'subUnitId':_0x35a303['getSheetId']()}),!_0x1e4fd5['getRenderById'](_0x549598))||_0x51f56c['syncExecuteCommand'](_0x2dfe55['id'],{'unitId':_0x5b0d90[_0x5b3b59(0xe7)](),'sheetId':_0x35a303['getSheetId'](),'sheetViewStartRow':_0x52bbd4['startRow'],'sheetViewStartColumn':_0x52bbd4[_0x5b3b59(0xd5)],'offsetX':0x0,'offsetY':0x0,'screenRatioX':-0x1/0x3,'screenRatioY':-0x1/0x3,'duration':0x12c});}}_0x426e48[_0x2561c3(0xe8)](I);class m extends _0x29f894{['getLiveShareStatus'](){const _0x5775fa=_0x2561c3;var _0x4803a2,_0x453d4;const _0x3dca3c=this[_0x5775fa(0xe0)][_0x5775fa(0xe5)](_0x204761),_0x5308c1=(_0x4803a2=this[_0x5775fa(0xdb)]())==null?void 0x0:_0x4803a2[_0x5775fa(0xea)]();if(!_0x5308c1)throw new Error(_0x5775fa(0xe1));const _0x4a1981=_0x3dca3c[_0x5775fa(0xcc)](_0x5308c1);return(_0x453d4=_0x4a1981==null?void 0x0:_0x4a1981[_0x5775fa(0xd6)]())!=null?_0x453d4:_0x5af292[_0x5775fa(0xd0)];}[_0x2561c3(0xe2)](){const _0x56ac37=_0x2561c3;var _0x2a1a51;const _0x5f2911=this[_0x56ac37(0xe0)][_0x56ac37(0xe5)](_0x204761),_0x2e43f9=(_0x2a1a51=this[_0x56ac37(0xdb)]())==null?void 0x0:_0x2a1a51['getId']();if(!_0x2e43f9)throw new Error(_0x56ac37(0xe1));const _0xea5ea8=_0x5f2911[_0x56ac37(0xcc)](_0x2e43f9);if(!_0xea5ea8)throw new Error('No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.');_0xea5ea8['startFollowing']();}[_0x2561c3(0xcf)](){const _0x160ab0=_0x2561c3;var _0xd4633f;const _0x11ee3b=this['_injector'][_0x160ab0(0xe5)](_0x204761),_0x2ba408=(_0xd4633f=this['getActiveWorkbook']())==null?void 0x0:_0xd4633f['getId']();if(!_0x2ba408)throw new Error(_0x160ab0(0xe1));const _0x54d5e8=_0x11ee3b['getLiveShareCoordinatorSync'](_0x2ba408);if(!_0x54d5e8)throw new Error(_0x160ab0(0xec));_0x54d5e8[_0x160ab0(0xcf)]();}[_0x2561c3(0xd8)](){const _0x1bda36=_0x2561c3;var _0x1d7986;const _0x4e127e=this[_0x1bda36(0xe0)]['get'](_0x204761),_0x1355be=(_0x1d7986=this['getActiveWorkbook']())==null?void 0x0:_0x1d7986[_0x1bda36(0xea)]();if(!_0x1355be)throw new Error(_0x1bda36(0xe1));const _0x474541=_0x4e127e['getLiveShareCoordinatorSync'](_0x1355be);if(!_0x474541)throw new Error(_0x1bda36(0xec));_0x474541[_0x1bda36(0xde)]();}[_0x2561c3(0xd7)](){const _0x53d076=_0x2561c3;var _0x2808d5;const _0x5d4a44=this[_0x53d076(0xe0)][_0x53d076(0xe5)](_0x204761),_0xa867df=(_0x2808d5=this[_0x53d076(0xdb)]())==null?void 0x0:_0x2808d5[_0x53d076(0xea)]();if(!_0xa867df)throw new Error('No\x20active\x20workbook\x20found.');const _0x2b9413=_0x5d4a44[_0x53d076(0xcc)](_0xa867df);if(!_0x2b9413)throw new Error('No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.');_0x2b9413[_0x53d076(0xd7)]();}}_0x29f894[_0x2561c3(0xe8)](m);class C extends _0x444374{get['LiveShareStatusEnum'](){return _0x5af292;}}_0x444374['extend'](C);function _0x17e9(){const _0x5314ef=['getUnitId','extend','executeCommand','getId','838232doQIbC','No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.','getLiveShareCoordinatorSync','300496eITPyP','10wYnpJY','stopFollowing','IDLE','18gGFVyC','279858hDoivd','145270EROWIB','getSheetId','startColumn','getStatus','stopPresenting','startPresenting','13822765YKUMZH','5XYfgdU','getActiveWorkbook','1540038FCejAP','_initialize','tryStartPresenting','_commandService','_injector','No\x20active\x20workbook\x20found.','startFollowing','1312cPXXWC','getActiveSheet','get','2655mRrCPP'];_0x17e9=function(){return _0x5314ef;};return _0x17e9();}
|
package/lib/es/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0xf02626=_0x49a3;(function(_0x5331b5,_0x52e9fb){const _0x5438da=_0x49a3,_0x1b6945=_0x5331b5();while(!![]){try{const _0x39df04=-parseInt(_0x5438da(0x1a3))/0x1*(-parseInt(_0x5438da(0x17f))/0x2)+-parseInt(_0x5438da(0x133))/0x3*(parseInt(_0x5438da(0x121))/0x4)+-parseInt(_0x5438da(0x13f))/0x5+parseInt(_0x5438da(0x1b8))/0x6*(-parseInt(_0x5438da(0x141))/0x7)+-parseInt(_0x5438da(0x159))/0x8*(parseInt(_0x5438da(0x17c))/0x9)+-parseInt(_0x5438da(0x13e))/0xa+parseInt(_0x5438da(0x126))/0xb;if(_0x39df04===_0x52e9fb)break;else _0x1b6945['push'](_0x1b6945['shift']());}catch(_0x3cfe13){_0x1b6945['push'](_0x1b6945['shift']());}}}(_0x3d06,0xa7477));var J=Object[_0xf02626(0x19c)],K=(_0x5ae237,_0x29cd28,_0x1e5d46)=>_0x29cd28 in _0x5ae237?J(_0x5ae237,_0x29cd28,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x1e5d46}):_0x5ae237[_0x29cd28]=_0x1e5d46,u=(_0x2615bb,_0x50aec8,_0x21469a)=>K(_0x2615bb,typeof _0x50aec8!=_0xf02626(0x18f)?_0x50aec8+'':_0x50aec8,_0x21469a);import{Disposable as _0x5bdbec,toDisposable as _0x5dd282,IUniverInstanceService as _0x246214,Inject as _0x13dd86,Injector as _0x5b65f0,IConfigService as _0x5c1fc8,ICommandService as _0x1549da,RxDisposable as _0x443063,UniverInstanceType as _0x57e1a6,DisposableCollection as _0xd84b84,CommandType as _0x13511b,DependentOn as _0x3a182e,Plugin as _0x586d52,merge as _0x12b34e,registerDependencies as _0x2186bd,mergeOverrideWithDependencies as _0x29be9b,touchDependencies as _0x31d787}from'@univerjs/core';import{useDependency as _0x4e3e8c,useObservable as _0x262950,IUIPartsService as _0x28a6d1,BuiltInUIPart as _0x50c32d,connectInjector as _0x11eeaf}from'@univerjs/ui';import{jsx as _0x3f1572,jsxs as _0x10f9f1,Fragment as _0x561b68}from'react/jsx-runtime';import{Dropdown as _0x49c23a,clsx as _0x37a6a0,Button as _0x1555cd}from'@univerjs/design';import{useRef as _0x922483,createElement as _0x2b29b6,forwardRef as _0x50463f,useState as _0x430a47,useEffect as _0x4a4b6f}from'react';import{CollaborationEvent as _0x41b597,parseProtocolChangeset as _0x1061ca}from'@univerjs-pro/collaboration';import{CollaborationSessionService as _0x374a90,SessionStatus as _0x1c448e,UniverCollaborationClientPlugin as _0x400e7c}from'@univerjs-pro/collaboration-client';import{InsertSheetMutation as _0x2abf81,SetWorksheetActiveOperation as _0x218042}from'@univerjs/sheets';import{BehaviorSubject as _0x26b77b,Subject as _0x5a754c}from'rxjs';import{takeUntil as _0x461f78,throttleTime as _0x471303}from'rxjs/operators';import{SetZoomRatioOperation as _0x5b6fb4,SetScrollOperation as _0x54eb58}from'@univerjs/sheets-ui';function k({ref:_0x45d44c,..._0x431046}){const _0x311fa5=_0xf02626,{icon:_0x5c5c05,id:_0x33ae4a,className:_0x443872,extend:_0x1606c0,..._0x12d90a}=_0x431046,_0x20e022=(_0x311fa5(0x154)+_0x33ae4a+'\x20'+(_0x443872||''))[_0x311fa5(0x1a8)](),_0x1f4950=_0x922483('_'+Oe());return G(_0x5c5c05,''+_0x33ae4a,{'defIds':_0x5c5c05['defIds'],'idSuffix':_0x1f4950[_0x311fa5(0x1ba)]},{'ref':_0x45d44c,'className':_0x20e022,..._0x12d90a},_0x1606c0);}function G(_0x1dbecf,_0x3a8b92,_0x4e6a23,_0x16ea80,_0x36b1bf){const _0x50e375=_0xf02626;return _0x2b29b6(_0x1dbecf[_0x50e375(0x1b6)],{'key':_0x3a8b92,...be(_0x1dbecf,_0x4e6a23,_0x36b1bf),..._0x16ea80},(Ee(_0x1dbecf,_0x4e6a23)[_0x50e375(0x146)]||[])[_0x50e375(0x181)]((_0x24911d,_0x4b43a2)=>G(_0x24911d,_0x3a8b92+'-'+_0x1dbecf[_0x50e375(0x1b6)]+'-'+_0x4b43a2,_0x4e6a23,void 0x0,_0x36b1bf)));}function be(_0x133a49,_0x300770,_0x292fe8){const _0x456b02=_0xf02626,_0x3266a8={..._0x133a49[_0x456b02(0x164)]};_0x292fe8!=null&&_0x292fe8['colorChannel1']&&_0x3266a8[_0x456b02(0x199)]==='colorChannel1'&&(_0x3266a8[_0x456b02(0x199)]=_0x292fe8[_0x456b02(0x1ad)]),_0x133a49[_0x456b02(0x1b6)]==='mask'&&_0x3266a8['id']&&(_0x3266a8['id']=_0x3266a8['id']+_0x300770[_0x456b02(0x17e)]),Object['entries'](_0x3266a8)['forEach'](([_0x51a95d,_0x41d3fc])=>{const _0xe87a3a=_0x456b02;_0x51a95d===_0xe87a3a(0x19b)&&typeof _0x41d3fc==_0xe87a3a(0x19a)&&(_0x3266a8[_0x51a95d]=_0x41d3fc[_0xe87a3a(0x162)](/url\(#(.*)\)/,_0xe87a3a(0x178)+_0x300770[_0xe87a3a(0x17e)]+')'));});const {defIds:_0x1f9156}=_0x300770;return!_0x1f9156||_0x1f9156[_0x456b02(0x193)]===0x0||(_0x133a49['tag']===_0x456b02(0x152)&&_0x3266a8[_0x456b02(0x171)]&&(_0x3266a8[_0x456b02(0x171)]=_0x3266a8[_0x456b02(0x171)]+_0x300770[_0x456b02(0x17e)]),Object[_0x456b02(0x139)](_0x3266a8)[_0x456b02(0x197)](([_0x4a9000,_0x5377c9])=>{const _0x32d52a=_0x456b02;typeof _0x5377c9==_0x32d52a(0x19a)&&(_0x3266a8[_0x4a9000]=_0x5377c9['replace'](/url\(#(.*)\)/,_0x32d52a(0x178)+_0x300770[_0x32d52a(0x17e)]+')'));})),_0x3266a8;}function Ee(_0x5a80d,_0x43d5cd){const _0x3107af=_0xf02626;var _0x3dcc55;const {defIds:_0x46967b}=_0x43d5cd;return!_0x46967b||_0x46967b[_0x3107af(0x193)]===0x0?_0x5a80d:_0x5a80d[_0x3107af(0x1b6)]===_0x3107af(0x18b)&&((_0x3dcc55=_0x5a80d[_0x3107af(0x146)])!=null&&_0x3dcc55['length'])?{..._0x5a80d,'children':_0x5a80d[_0x3107af(0x146)]['map'](_0x237538=>typeof _0x237538[_0x3107af(0x164)]['id']==_0x3107af(0x19a)&&_0x46967b&&_0x46967b['includes'](_0x237538[_0x3107af(0x164)]['id'])?{..._0x237538,'attrs':{..._0x237538[_0x3107af(0x164)],'id':_0x237538[_0x3107af(0x164)]['id']+_0x43d5cd[_0x3107af(0x17e)]}}:_0x237538)}:_0x5a80d;}function Oe(){const _0x1bf817=_0xf02626;return Math[_0x1bf817(0x1a9)]()[_0x1bf817(0x16c)](0x24)['substring'](0x2,0x8);}k[_0xf02626(0x140)]=_0xf02626(0x142);const we={'tag':_0xf02626(0x179),'attrs':{'xmlns':_0xf02626(0x148),'fill':_0xf02626(0x14a),'viewBox':_0xf02626(0x153),'width':_0xf02626(0x12a),'height':'1em'},'children':[{'tag':_0xf02626(0x128),'attrs':{'fill':_0xf02626(0x119),'d':_0xf02626(0x137)}},{'tag':'path','attrs':{'fill':_0xf02626(0x119),'d':'M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','fillRule':'evenodd','clipRule':_0xf02626(0x10f)}}]},W=_0x50463f(function(_0x4e555a,_0x50af5d){const _0x20c472=_0xf02626;return _0x2b29b6(k,Object[_0x20c472(0x1ab)]({},_0x4e555a,{'id':_0x20c472(0x1a6),'ref':_0x50af5d,'icon':we}));});function _0x3d06(){const _0x14053c=['_collabSession','_handleOffline','Present\x20this\x20document','stopFollowing','_collabSessionService','sessionStatus$','defs','live-share.config','You\x27re\x20presenting\x20the\x20document','presenter','symbol','_startPresenting','idle','onStarting','length','_config','unsubscribe','_beIdle','forEach','_stopFollowing','fill','string','mask','defineProperty','stringify','get','getInitialStates','createInstance','sheet','getUnitId','615577PSTsWq','not-following','offline','live-share-icon','OPERATION','trim','random','_startLiveShareCoordinator','assign','LIVESHARE_OPERATION','colorChannel1','univer-size-4','_liveShareService','executeCommand','div','text','add','_status','You\x27re\x20not\x20following\x20the\x20presenter','tag','default','9930OggFyi','reverse','current','getLiveShareCoordinatorSync','PRESENTING','evenodd','event$','onCommandExecuted','UNIVER_SHEET','_handleOnline','_uiPartsService','_unitID','registerSharedOperation','dispose','_handleNewHost','currentColor','subscribe','OFFLINE','_reporters','set','_status$','UNIVER_UNKNOWN','_fetchOperations','74524wcwGef','univer-mb-3\x20univer-w-full\x20univer-text-sm','disposeWithMe','dispose$','getCurrentTypeOfUnit$','16373324bTqYAQ','univer-border-none\x20univer-text-gray-600\x20univer-outline-none','path','tryStartPresenting','1em','from','registerInitialStateReporter','pipe','ONLINE','LIVESHARE_NEW_HOST','params','status$','type','39RhzziQ','init','getConfig','_handleNewChangeSets','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','parse','entries','SAME_OPERATION_SHARE_INTERVAL','_injector','FOLLOWING','button','846610yaNAnk','4034360ORMdVM','displayName','7kOLEdu','UniverIcon','getOwnPropertyDescriptor','LIVESHARE_FETCH_OPERATIONS','send','children','has','http://www.w3.org/2000/svg','shouldShareOperation','none','_handleTerminate','getMemberID','NOT_FOLLOWING','presenting','following','getLiveShareCoordinator','Stop\x20presenting','use','0\x200\x2017\x2017','univerjs-icon\x20univerjs-icon-','pluginName','_commandDisposable','_commandService','end','14048ffhAMu','next','_init','startFollowing','_stopPresenting','then','NEW_CHANGESETS','find','LIVESHARE_TERMINATE','replace','operations','attrs','requireSession','getTypeOfUnitAdded$','override','_startFollowing','Stop\x20following','data','getStatus','toString','stopPresenting','_presenter','includes','onRendered','xlink:href','_configService','getTypeOfUnitDisposed$','_mountLiveShare','Start\x20following','clear','memberID','url(#$1','svg','_univerInstanceService','_entities','4608WzNYdl','complete','idSuffix','4mqiFwe','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','map','_sharedOperations','unitId','IDLE'];_0x3d06=function(){return _0x14053c;};return _0x3d06();}W['displayName']='LiveShareIcon';class L extends _0x5bdbec{constructor(){const _0x2ff16a=_0xf02626;super(...arguments),u(this,_0x2ff16a(0x182),new Set()),u(this,_0x2ff16a(0x11c),new Set());}[_0xf02626(0x116)](_0x35d38d){const _0x4d8fcb=_0xf02626;return this[_0x4d8fcb(0x182)][_0x4d8fcb(0x1b3)](_0x35d38d),_0x5dd282(()=>this['_sharedOperations']['delete'](_0x35d38d));}[_0xf02626(0x12c)](_0x11b68c){const _0x1121d6=_0xf02626;return this['_reporters'][_0x1121d6(0x1b3)](_0x11b68c),_0x5dd282(()=>this[_0x1121d6(0x11c)]['delete'](_0x11b68c));}[_0xf02626(0x149)](_0x204eb8){const _0xee7915=_0xf02626;return this[_0xee7915(0x182)]['has'](_0x204eb8);}[_0xf02626(0x19f)](_0x167c9b){const _0x53156c=_0xf02626;return Array[_0x53156c(0x12b)](this[_0x53156c(0x11c)])['map'](_0x479681=>_0x479681(_0x167c9b));}}var Ne=Object[_0xf02626(0x143)],Y=(_0x5b521b,_0x1bdfd9,_0xad5fcb,_0x17bf4a)=>{const _0x3beed3=_0xf02626;for(var _0x49c3d3=_0x17bf4a>0x1?void 0x0:_0x17bf4a?Ne(_0x1bdfd9,_0xad5fcb):_0x1bdfd9,_0x4a3bae=_0x5b521b[_0x3beed3(0x193)]-0x1,_0x43efd8;_0x4a3bae>=0x0;_0x4a3bae--)(_0x43efd8=_0x5b521b[_0x4a3bae])&&(_0x49c3d3=_0x43efd8(_0x49c3d3)||_0x49c3d3);return _0x49c3d3;},_=(_0x4a9e82,_0x27f1e2)=>(_0x14a2b2,_0x528b69)=>_0x27f1e2(_0x14a2b2,_0x528b69,_0x4a9e82);let S=class extends _0x443063{constructor(_0xc53126,_0x483ead,_0x235aff){const _0x4a8dd8=_0xf02626;super(),u(this,_0x4a8dd8(0x17b),new Map()),(this[_0x4a8dd8(0x17a)]=_0xc53126,this['_injector']=_0x483ead,this[_0x4a8dd8(0x189)]=_0x235aff,this[_0x4a8dd8(0x15b)]());}async[_0xf02626(0x150)](_0x3208e4){const _0x51fb65=_0xf02626;return this[_0x51fb65(0x17b)][_0x51fb65(0x147)](_0x3208e4)||await this[_0x51fb65(0x1aa)](_0x3208e4),this[_0x51fb65(0x17b)][_0x51fb65(0x19e)](_0x3208e4);}[_0xf02626(0x10d)](_0x1939e2){const _0x19b3e0=_0xf02626;var _0x46ce0c;return(_0x46ce0c=this['_entities'][_0x19b3e0(0x19e)](_0x1939e2))!=null?_0x46ce0c:null;}[_0xf02626(0x15b)](){const _0x4d3ace=_0xf02626;this['_univerInstanceService'][_0x4d3ace(0x166)](_0x57e1a6[_0x4d3ace(0x112)])[_0x4d3ace(0x12d)](_0x461f78(this[_0x4d3ace(0x124)]))[_0x4d3ace(0x11a)](async _0xbd6c95=>{const _0x4039dc=_0x4d3ace,_0x561176=_0xbd6c95[_0x4039dc(0x1a2)]();this[_0x4039dc(0x17b)][_0x4039dc(0x147)](_0x561176)||this[_0x4039dc(0x1aa)](_0x561176);}),this[_0x4d3ace(0x17a)][_0x4d3ace(0x173)](_0x57e1a6['UNIVER_SHEET'])[_0x4d3ace(0x12d)](_0x461f78(this['dispose$']))[_0x4d3ace(0x11a)](_0x1ff344=>{const _0x314ae9=_0x4d3ace,_0x5b2922=_0x1ff344[_0x314ae9(0x1a2)](),_0x217dca=this[_0x314ae9(0x17b)][_0x314ae9(0x19e)](_0x5b2922);_0x217dca==null||_0x217dca['dispose']();});}async[_0xf02626(0x1aa)](_0x133e6b){const _0x43a699=_0xf02626,_0x54f095=await this[_0x43a699(0x189)][_0x43a699(0x165)](_0x133e6b),_0xa92cf6=this[_0x43a699(0x13b)][_0x43a699(0x1a0)](N,_0x133e6b,_0x54f095);return _0xa92cf6['init'](),this[_0x43a699(0x17b)]['set'](_0x133e6b,_0xa92cf6),_0xa92cf6;}};S=Y([_(0x0,_0x246214),_(0x1,_0x13dd86(_0x5b65f0)),_(0x2,_0x13dd86(_0x374a90))],S);var c=(_0x14c111=>(_0x14c111[_0xf02626(0x11b)]=_0xf02626(0x1a5),_0x14c111[_0xf02626(0x184)]='idle',_0x14c111[_0xf02626(0x13c)]=_0xf02626(0x14f),_0x14c111['NOT_FOLLOWING']=_0xf02626(0x1a4),_0x14c111[_0xf02626(0x10e)]=_0xf02626(0x14e),_0x14c111))(c||{});const Ce=_0xf02626(0x13a),De=0xc8;let N=class extends _0x443063{constructor(_0x3fa637,_0x3ddbee,_0x58c38e,_0x5192fc,_0x5b802d){const _0x2cc365=_0xf02626;super(),u(this,_0x2cc365(0x11e),new _0x26b77b('idle')),u(this,_0x2cc365(0x131),this[_0x2cc365(0x11e)]['asObservable']()),u(this,_0x2cc365(0x15b),!0x1),u(this,_0x2cc365(0x156),null),u(this,_0x2cc365(0x16e),null),(this[_0x2cc365(0x115)]=_0x3fa637,this[_0x2cc365(0x185)]=_0x3ddbee,this[_0x2cc365(0x172)]=_0x58c38e,this[_0x2cc365(0x1af)]=_0x5192fc,this[_0x2cc365(0x157)]=_0x5b802d);}get[_0xf02626(0x1b4)](){const _0x5820f9=_0xf02626;return this[_0x5820f9(0x11e)]['getValue']();}[_0xf02626(0x117)](){const _0x590d48=_0xf02626;var _0x5baa3b;(_0x5baa3b=this[_0x590d48(0x156)])==null||_0x5baa3b[_0x590d48(0x117)](),this[_0x590d48(0x11e)][_0x590d48(0x15a)](_0x590d48(0x191)),this[_0x590d48(0x11e)][_0x590d48(0x17d)]();}[_0xf02626(0x16b)](){const _0x107eb2=_0xf02626;return this[_0x107eb2(0x1b4)];}[_0xf02626(0x134)](){const _0x3187b9=_0xf02626;this[_0x3187b9(0x15b)]||(this[_0x3187b9(0x15b)]=!0x0,this['_collabSession'][_0x3187b9(0x18a)][_0x3187b9(0x12d)](_0x461f78(this[_0x3187b9(0x124)]))[_0x3187b9(0x11a)](_0xbf4875=>{const _0x44cd72=_0x3187b9;switch(_0xbf4875){case _0x1c448e[_0x44cd72(0x11b)]:this[_0x44cd72(0x186)]();break;case _0x1c448e[_0x44cd72(0x12e)]:this[_0x44cd72(0x113)]();break;}}),this[_0x3187b9(0x185)][_0x3187b9(0x110)]['pipe'](_0x461f78(this['dispose$']))['subscribe'](_0x236c21=>{const _0x583246=_0x3187b9,{eventID:_0x2c7084}=_0x236c21;switch(_0x2c7084){case _0x41b597[_0x583246(0x12f)]:this[_0x583246(0x118)](_0x236c21);break;case _0x41b597['LIVESHARE_OPERATION']:this['_handleOperation'](_0x236c21);break;case _0x41b597[_0x583246(0x161)]:this['_handleTerminate']();break;case _0x41b597[_0x583246(0x15f)]:this[_0x583246(0x136)](_0x236c21);break;}}));}[_0xf02626(0x129)](){const _0x4b6c31=_0xf02626;this[_0x4b6c31(0x185)]['send']({'eventID':_0x41b597['LIVESHARE_REQUEST_HOST'],'data':{'unitID':this[_0x4b6c31(0x115)],'userID':this[_0x4b6c31(0x185)]['getMemberID']()}},this[_0x4b6c31(0x115)]);}[_0xf02626(0x16d)](){const _0x4d942e=_0xf02626;this[_0x4d942e(0x1b4)]===_0x4d942e(0x14e)&&(this[_0x4d942e(0x11e)][_0x4d942e(0x15a)](_0x4d942e(0x191)),this[_0x4d942e(0x185)][_0x4d942e(0x145)]({'eventID':_0x41b597[_0x4d942e(0x161)],'data':{'unitID':this[_0x4d942e(0x115)]}},this[_0x4d942e(0x115)]));}[_0xf02626(0x15c)](){const _0x496c3e=_0xf02626;this[_0x496c3e(0x1b4)]==='not-following'&&(this[_0x496c3e(0x11e)][_0x496c3e(0x15a)](_0x496c3e(0x14f)),this[_0x496c3e(0x168)]());}[_0xf02626(0x188)](){const _0x5e5cea=_0xf02626;this['_status']===_0x5e5cea(0x14f)&&this[_0x5e5cea(0x198)]();}[_0xf02626(0x118)](_0x357d9d){const _0x568dfc=_0xf02626,{presenter:_0x3fa8fb}=_0x357d9d['data'],_0x3ca1e4=this['_collabSession'][_0x568dfc(0x14c)]();this[_0x568dfc(0x16e)]=_0x3fa8fb,_0x3fa8fb===_0x3ca1e4?(this[_0x568dfc(0x198)](),this[_0x568dfc(0x190)]()):this[_0x568dfc(0x1b4)]!==_0x568dfc(0x1a4)&&(this[_0x568dfc(0x15d)](),this[_0x568dfc(0x168)]());}[_0xf02626(0x120)](){const _0x25c34e=_0xf02626,_0x2578f7={'eventID':_0x41b597[_0x25c34e(0x144)]};this['_collabSession']['send'](_0x2578f7,this[_0x25c34e(0x115)]);}[_0xf02626(0x14b)](){const _0x345f75=_0xf02626;this[_0x345f75(0x16e)]=null,this[_0x345f75(0x1b4)]!=='presenting'&&this[_0x345f75(0x196)]();}['_handleNewChangeSets'](_0x46197e){const _0x148a21=_0xf02626;if(this[_0x148a21(0x1b4)]===_0x148a21(0x14f)&&this[_0x148a21(0x16e)]===_0x46197e[_0x148a21(0x16a)][_0x148a21(0x177)]){const _0x5b050f=_0x1061ca(_0x46197e[_0x148a21(0x16a)])['mutations'][_0x148a21(0x1b9)]()[_0x148a21(0x160)](_0x3cf610=>_0x3cf610['id']===_0x2abf81['id']);if(_0x5b050f){const _0x69a22d=_0x5b050f[_0x148a21(0x130)][_0x148a21(0x183)],_0xd951ea=_0x5b050f[_0x148a21(0x130)][_0x148a21(0x1a1)]['id'];setTimeout(()=>{const _0x5b0a20=_0x148a21;this[_0x5b0a20(0x157)][_0x5b0a20(0x1b0)](_0x218042['id'],{'unitId':_0x69a22d,'subUnitId':_0xd951ea},{'fromCollab':!0x0});});}}}[_0xf02626(0x190)](){const _0x3f8a70=_0xf02626;this[_0x3f8a70(0x11e)][_0x3f8a70(0x15a)]('presenting');const _0x373ffc=new Map(),_0x2bd11f=this['_commandDisposable']=new _0xd84b84();_0x2bd11f[_0x3f8a70(0x1b3)](_0x5dd282(()=>{const _0x544f17=_0x3f8a70;_0x373ffc[_0x544f17(0x197)](_0x293094=>_0x293094[_0x544f17(0x17d)]()),_0x373ffc[_0x544f17(0x176)]();})),_0x2bd11f[_0x3f8a70(0x1b3)](this['_commandService'][_0x3f8a70(0x111)](_0x2ca7a7=>{const _0xde89c=_0x3f8a70;var _0x1d950c;if(_0x2ca7a7[_0xde89c(0x132)]!==_0x13511b[_0xde89c(0x1a7)]||!this[_0xde89c(0x1af)][_0xde89c(0x149)](_0x2ca7a7['id']))return;const {id:_0x872d9c}=_0x2ca7a7;let _0x3f240f;_0x373ffc[_0xde89c(0x147)](_0x872d9c)?_0x3f240f=_0x373ffc[_0xde89c(0x19e)](_0x872d9c):(_0x3f240f=new _0x5a754c(),_0x373ffc[_0xde89c(0x11d)](_0x872d9c,_0x3f240f),_0x3f240f[_0xde89c(0x12d)](_0x471303((_0x1d950c=this[_0xde89c(0x172)][_0xde89c(0x135)](Ce))!=null?_0x1d950c:De,void 0x0,{'trailing':!0x0,'leading':!0x0}))[_0xde89c(0x11a)](_0x19d28c=>{const _0x4e2489=_0xde89c;this[_0x4e2489(0x185)][_0x4e2489(0x145)]({'eventID':_0x41b597[_0x4e2489(0x1ac)],'data':{'unitID':this[_0x4e2489(0x115)],'operations':{[_0x19d28c['id']]:{'id':_0x19d28c['id'],'params':JSON['stringify'](_0x19d28c['params'])}}}},this[_0x4e2489(0x115)]);})),_0x3f240f['next'](_0x2ca7a7);})),this['_liveShareService']['getInitialStates'](this[_0x3f8a70(0x115)])['forEach'](_0x507eca=>this[_0x3f8a70(0x185)][_0x3f8a70(0x145)]({'eventID':_0x41b597['LIVESHARE_OPERATION'],'data':{'unitID':this[_0x3f8a70(0x115)],'operations':{[_0x507eca['id']]:{'id':_0x507eca['id'],'params':JSON[_0x3f8a70(0x19d)](_0x507eca[_0x3f8a70(0x130)])}}}},this['_unitID']));}[_0xf02626(0x15d)](){const _0x3bdc00=_0xf02626;var _0x353052;this[_0x3bdc00(0x11e)][_0x3bdc00(0x15a)](_0x3bdc00(0x191)),(_0x353052=this['_commandDisposable'])==null||_0x353052['dispose'](),this[_0x3bdc00(0x156)]=null;}[_0xf02626(0x168)](){const _0x50423e=_0xf02626;var _0x22875c;(_0x22875c=this[_0x50423e(0x156)])==null||_0x22875c[_0x50423e(0x117)](),this[_0x50423e(0x11e)][_0x50423e(0x15a)](_0x50423e(0x14f));}['_beIdle'](){const _0x2326f7=_0xf02626;var _0x4d3b8f;this[_0x2326f7(0x11e)][_0x2326f7(0x15a)](_0x2326f7(0x191)),(_0x4d3b8f=this[_0x2326f7(0x156)])==null||_0x4d3b8f[_0x2326f7(0x117)](),this[_0x2326f7(0x156)]=null;}[_0xf02626(0x198)](){const _0x5471e2=_0xf02626;var _0x43265e;this[_0x5471e2(0x11e)]['next'](_0x5471e2(0x1a4)),(_0x43265e=this[_0x5471e2(0x156)])==null||_0x43265e[_0x5471e2(0x117)]();}['_handleOperation'](_0x224d63){const _0x5a8190=_0xf02626;if([_0x5a8190(0x14e),'not-following','offline'][_0x5a8190(0x16f)](this[_0x5a8190(0x1b4)])||!_0x224d63[_0x5a8190(0x16a)][_0x5a8190(0x18e)]||_0x224d63[_0x5a8190(0x16a)]['presenter']===this[_0x5a8190(0x185)][_0x5a8190(0x14c)]())return;this['_status']===_0x5a8190(0x191)&&this[_0x5a8190(0x168)]();const _0x5ed6e6=_0x224d63[_0x5a8190(0x16a)][_0x5a8190(0x163)];Object['values'](_0x5ed6e6)[_0x5a8190(0x197)](_0x31cd1e=>{const _0x57204c=_0x5a8190;this[_0x57204c(0x157)][_0x57204c(0x1b0)](_0x31cd1e['id'],_0x31cd1e[_0x57204c(0x130)]?JSON[_0x57204c(0x138)](_0x31cd1e[_0x57204c(0x130)]):null,{'fromCollab':!0x0});});}[_0xf02626(0x186)](){const _0x3520bb=_0xf02626;var _0x14ca7b;this[_0x3520bb(0x11e)][_0x3520bb(0x15a)](_0x3520bb(0x1a5)),(_0x14ca7b=this['_commandDisposable'])==null||_0x14ca7b['dispose']();}[_0xf02626(0x113)](){const _0x59b3d2=_0xf02626;this[_0x59b3d2(0x11e)][_0x59b3d2(0x15a)]('idle'),this[_0x59b3d2(0x120)]();}};N=Y([_(0x2,_0x5c1fc8),_(0x3,_0x13dd86(L)),_(0x4,_0x1549da)],N);function Le(){const _0x1f2369=_0xf02626,_0x569ebc=_0x4e3e8c(S),_0x5ee06f=_0x4e3e8c(_0x246214),_0x420c04=_0x262950(()=>_0x5ee06f[_0x1f2369(0x125)](_0x57e1a6[_0x1f2369(0x112)]),void 0x0,!0x1,[]),[_0x2eabc6,_0x5c84c4]=_0x430a47(null),[_0x238d1c,_0x224e16]=_0x430a47(c['IDLE']),_0x582f08=_0x922483(null);return _0x4a4b6f(()=>(_0x420c04&&_0x569ebc[_0x1f2369(0x150)](_0x420c04[_0x1f2369(0x1a2)]())[_0x1f2369(0x15e)](_0x35b1a7=>{const _0x18398d=_0x1f2369;_0x5c84c4(_0x35b1a7),_0x582f08[_0x18398d(0x1ba)]=_0x35b1a7[_0x18398d(0x131)]['subscribe'](_0x59d285=>{_0x224e16(_0x59d285);});}),()=>{const _0x1c2cf3=_0x1f2369;var _0x291bd3;(_0x291bd3=_0x582f08['current'])==null||_0x291bd3[_0x1c2cf3(0x195)](),_0x582f08[_0x1c2cf3(0x1ba)]=null;}),[_0x420c04,_0x569ebc]),_0x2eabc6?_0x3f1572(_0x49c23a,{'align':_0x1f2369(0x158),'disabled':_0x238d1c===c[_0x1f2369(0x11b)],'className':_0x1f2369(0x180),'overlay':_0x3f1572(Re,{'status':_0x238d1c,'coordinator':_0x2eabc6}),'children':_0x3f1572(_0x1f2369(0x13d),{'className':_0x37a6a0(_0x1f2369(0x127),{'univer-cursor-not-allowed':_0x238d1c===c[_0x1f2369(0x11b)],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x238d1c!==c[_0x1f2369(0x11b)]}),'type':_0x1f2369(0x13d),'children':_0x3f1572(W,{'className':_0x1f2369(0x1ae)})})}):null;}function Re(_0x25b16b){const _0x2954de=_0xf02626,{status:_0x12e09e,coordinator:_0x3cfffd}=_0x25b16b;switch(_0x12e09e){case c[_0x2954de(0x184)]:return _0x3f1572($e,{'coordinator':_0x3cfffd});case c['FOLLOWING']:return _0x3f1572(xe,{'coordinator':_0x3cfffd});case c[_0x2954de(0x14d)]:return _0x3f1572(Pe,{'coordinator':_0x3cfffd});case c['OFFLINE']:return _0x3f1572(Te,{});case c['PRESENTING']:return _0x3f1572(Ae,{'coordinator':_0x3cfffd});default:return null;}}function $e(_0x28b641){const _0x17d842=_0xf02626,{coordinator:_0x3ef61c}=_0x28b641;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572('div',{'className':_0x17d842(0x122),'children':_0x17d842(0x187)}),_0x3f1572(_0x1555cd,{'onClick':()=>_0x3ef61c['tryStartPresenting'](),'children':'Start'})]});}function xe(_0x1db4e6){const _0x9aeece=_0xf02626,{coordinator:_0x21561b}=_0x1db4e6;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572(_0x9aeece(0x1b1),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':'You\x27re\x20following\x20the\x20presenter'}),_0x3f1572(_0x1555cd,{'onClick':()=>_0x21561b[_0x9aeece(0x188)](),'children':_0x9aeece(0x169)})]});}function Pe(_0x644145){const _0x49b868=_0xf02626,{coordinator:_0x5d21a9}=_0x644145;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572(_0x49b868(0x1b1),{'className':_0x49b868(0x122),'children':_0x49b868(0x1b5)}),_0x3f1572(_0x1555cd,{'variant':_0x49b868(0x1b2),'onClick':()=>_0x5d21a9[_0x49b868(0x15c)](),'children':_0x49b868(0x175)})]});}function Ae(_0x4eda88){const _0x7481f5=_0xf02626,{coordinator:_0x574693}=_0x4eda88;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572(_0x7481f5(0x1b1),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x7481f5(0x18d)}),_0x3f1572(_0x1555cd,{'variant':_0x7481f5(0x1b7),'onClick':()=>_0x574693[_0x7481f5(0x16d)](),'children':_0x7481f5(0x151)})]});}function Te(){return _0x3f1572(_0x561b68,{'children':'You\x27are\x20offline.'});}var Fe=Object[_0xf02626(0x143)],He=(_0x96b58c,_0x144ee2,_0x507d0b,_0x222271)=>{const _0xefecaf=_0xf02626;for(var _0x13fcad=_0x222271>0x1?void 0x0:_0x222271?Fe(_0x144ee2,_0x507d0b):_0x144ee2,_0x42d52c=_0x96b58c[_0xefecaf(0x193)]-0x1,_0x5f0019;_0x42d52c>=0x0;_0x42d52c--)(_0x5f0019=_0x96b58c[_0x42d52c])&&(_0x13fcad=_0x5f0019(_0x13fcad)||_0x13fcad);return _0x13fcad;},A=(_0x5642f2,_0x3d613d)=>(_0x31fffb,_0x4e944a)=>_0x3d613d(_0x31fffb,_0x4e944a,_0x5642f2);let m=class extends _0x5bdbec{constructor(_0x38c48e,_0xcedf1f){const _0x3f32ff=_0xf02626;super(),this[_0x3f32ff(0x13b)]=_0x38c48e,this[_0x3f32ff(0x114)]=_0xcedf1f,this[_0x3f32ff(0x174)]();}[_0xf02626(0x174)](){const _0x55dd1f=_0xf02626;this[_0x55dd1f(0x123)](this[_0x55dd1f(0x114)]['registerComponent'](_0x50c32d['HEADER_MENU'],()=>_0x11eeaf(Le,this[_0x55dd1f(0x13b)])));}};m=He([A(0x0,_0x13dd86(_0x5b65f0)),A(0x1,_0x28a6d1)],m);const ye=_0xf02626(0x18c),T={};var Ue=Object['getOwnPropertyDescriptor'],Ve=(_0x535922,_0x1e5212,_0x4e0c0d,_0x470e7d)=>{const _0x607782=_0xf02626;for(var _0x2f847e=_0x470e7d>0x1?void 0x0:_0x470e7d?Ue(_0x1e5212,_0x4e0c0d):_0x1e5212,_0x3a3d52=_0x535922[_0x607782(0x193)]-0x1,_0x4f8e2f;_0x3a3d52>=0x0;_0x3a3d52--)(_0x4f8e2f=_0x535922[_0x3a3d52])&&(_0x2f847e=_0x4f8e2f(_0x2f847e)||_0x2f847e);return _0x2f847e;},je=(_0x1004d2,_0x4c201b)=>(_0x376686,_0x2034c4)=>_0x4c201b(_0x376686,_0x2034c4,_0x1004d2);let I=class extends _0x5bdbec{constructor(_0x851793){const _0x3619bd=_0xf02626;super(),this[_0x3619bd(0x1af)]=_0x851793,this['_init']();}[_0xf02626(0x15b)](){[_0x5b6fb4['id'],_0x54eb58['id'],_0x218042['id']]['forEach'](_0x1c96f7=>{const _0x47a757=_0x49a3;this[_0x47a757(0x123)](this[_0x47a757(0x1af)][_0x47a757(0x116)](_0x1c96f7));});}};I=Ve([je(0x0,_0x13dd86(L))],I);var Me=Object[_0xf02626(0x19c)],ke=Object[_0xf02626(0x143)],Ge=(_0x48fbcc,_0x131495,_0x50e9bb)=>_0x131495 in _0x48fbcc?Me(_0x48fbcc,_0x131495,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x50e9bb}):_0x48fbcc[_0x131495]=_0x50e9bb,We=(_0x5e6c7c,_0x3fd39f,_0x5f3d48,_0x38183a)=>{const _0x170050=_0xf02626;for(var _0x2f772b=_0x38183a>0x1?void 0x0:_0x38183a?ke(_0x3fd39f,_0x5f3d48):_0x3fd39f,_0x1e7745=_0x5e6c7c[_0x170050(0x193)]-0x1,_0x293523;_0x1e7745>=0x0;_0x1e7745--)(_0x293523=_0x5e6c7c[_0x1e7745])&&(_0x2f772b=_0x293523(_0x2f772b)||_0x2f772b);return _0x2f772b;},F=(_0x218a51,_0x1a8e03)=>(_0x22d847,_0x242c8a)=>_0x1a8e03(_0x22d847,_0x242c8a,_0x218a51),B=(_0x181145,_0x5f28e6,_0x38ec45)=>Ge(_0x181145,typeof _0x5f28e6!=_0xf02626(0x18f)?_0x5f28e6+'':_0x5f28e6,_0x38ec45);function _0x49a3(_0x311e8d,_0x1d2c9f){_0x311e8d=_0x311e8d-0x10d;const _0x3d0625=_0x3d06();let _0x49a302=_0x3d0625[_0x311e8d];return _0x49a302;}const Ye='UNIVER_LIVE_SHARE_PLUGIN';let b=class extends _0x586d52{constructor(_0x9e3f14=T,_0x24bc5f,_0x349d0d){const _0x5d3475=_0xf02626;super(),this[_0x5d3475(0x194)]=_0x9e3f14,this[_0x5d3475(0x13b)]=_0x24bc5f,this[_0x5d3475(0x172)]=_0x349d0d;const {..._0x205667}=_0x12b34e({},T,this[_0x5d3475(0x194)]);this[_0x5d3475(0x172)]['setConfig'](ye,_0x205667);}[_0xf02626(0x192)](){const _0x417a59=_0xf02626;_0x2186bd(this[_0x417a59(0x13b)],_0x29be9b([[L],[S],[I],[m]],this[_0x417a59(0x194)][_0x417a59(0x167)])),_0x31d787(this['_injector'],[[I]]);}[_0xf02626(0x170)](){const _0x2f8e46=_0xf02626;_0x31d787(this[_0x2f8e46(0x13b)],[[m]]);}};B(b,_0xf02626(0x132),_0x57e1a6[_0xf02626(0x11f)]),B(b,_0xf02626(0x155),Ye),b=We([_0x3a182e(_0x400e7c),F(0x1,_0x13dd86(_0x5b65f0)),F(0x2,_0x5c1fc8)],b);export{m as DesktopLiveShareController,Le as LiveShare,S as LiveShareController,N as LiveShareCoordinator,L as LiveShareService,c as LiveShareStatus,b as UniverLiveSharePlugin};
|
|
1
|
+
const _0x5a9157=_0x4e14;(function(_0x56d1de,_0x1be11f){const _0x3232cd=_0x4e14,_0x1af3f2=_0x56d1de();while(!![]){try{const _0x19c600=parseInt(_0x3232cd(0x191))/0x1+-parseInt(_0x3232cd(0x166))/0x2+parseInt(_0x3232cd(0x130))/0x3+parseInt(_0x3232cd(0x1a9))/0x4+parseInt(_0x3232cd(0x14d))/0x5+parseInt(_0x3232cd(0x161))/0x6+-parseInt(_0x3232cd(0x16b))/0x7;if(_0x19c600===_0x1be11f)break;else _0x1af3f2['push'](_0x1af3f2['shift']());}catch(_0x56f5ba){_0x1af3f2['push'](_0x1af3f2['shift']());}}}(_0x54c7,0xb3ce5));function _0x4e14(_0x50138c,_0x45307e){_0x50138c=_0x50138c-0x115;const _0x54c7ce=_0x54c7();let _0x4e14ac=_0x54c7ce[_0x50138c];return _0x4e14ac;}var J=Object[_0x5a9157(0x136)],K=(_0x4672aa,_0x1de778,_0x12c834)=>_0x1de778 in _0x4672aa?J(_0x4672aa,_0x1de778,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x12c834}):_0x4672aa[_0x1de778]=_0x12c834,u=(_0x3616d7,_0x5d1470,_0x5456b0)=>K(_0x3616d7,typeof _0x5d1470!=_0x5a9157(0x194)?_0x5d1470+'':_0x5d1470,_0x5456b0);import{Disposable as _0xa28d62,toDisposable as _0x3e6459,IUniverInstanceService as _0x2bf8ed,Inject as _0x5890f3,Injector as _0x2ac967,IConfigService as _0x2ccd3e,ICommandService as _0x8f3e9,RxDisposable as _0x1cce5c,UniverInstanceType as _0x118916,DisposableCollection as _0x5315c9,CommandType as _0x55dc24,DependentOn as _0x2c9f12,Plugin as _0x446406,merge as _0x230b34,registerDependencies as _0x3ca90e,mergeOverrideWithDependencies as _0x1d22c6,touchDependencies as _0xa89abb}from'@univerjs/core';import{useDependency as _0x14fb74,useObservable as _0x25b804,IUIPartsService as _0x4b3e7b,BuiltInUIPart as _0x3df1ce,connectInjector as _0x360939}from'@univerjs/ui';import{jsx as _0xe9d27a,jsxs as _0x1044b3,Fragment as _0x21e76d}from'react/jsx-runtime';import{Dropdown as _0x1d5dcc,clsx as _0x26827b,Button as _0x43cbc8}from'@univerjs/design';import{useRef as _0x3a8f3b,createElement as _0x445d41,forwardRef as _0x3a591f,useState as _0x5ab416,useEffect as _0x34456e}from'react';import{CollaborationEvent as _0xb6d82,parseProtocolChangeset as _0x448a4b}from'@univerjs-pro/collaboration';import{CollaborationSessionService as _0x270da6,SessionStatus as _0x1f086f,UniverCollaborationClientPlugin as _0x270228}from'@univerjs-pro/collaboration-client';import{InsertSheetMutation as _0x1a8b78,SetWorksheetActiveOperation as _0x4ff82e}from'@univerjs/sheets';import{BehaviorSubject as _0x4812e4,Subject as _0x4797b2}from'rxjs';import{takeUntil as _0x5bc01a,throttleTime as _0x1e0766}from'rxjs/operators';import{SetZoomRatioOperation as _0x1f21c4,SetScrollOperation as _0x447fe5}from'@univerjs/sheets-ui';function k({ref:_0x4aafb6,..._0x34a9d5}){const _0x2fa30d=_0x5a9157,{icon:_0x10eab9,id:_0x3dc31d,className:_0x26f72d,extend:_0x195ada,..._0x1ea6ed}=_0x34a9d5,_0x264f64=(_0x2fa30d(0x11f)+_0x3dc31d+'\x20'+(_0x26f72d||''))[_0x2fa30d(0x13b)](),_0x543818=_0x3a8f3b('_'+Oe());return G(_0x10eab9,''+_0x3dc31d,{'defIds':_0x10eab9[_0x2fa30d(0x190)],'idSuffix':_0x543818[_0x2fa30d(0x17b)]},{'ref':_0x4aafb6,'className':_0x264f64,..._0x1ea6ed},_0x195ada);}function G(_0x5223e4,_0x4d5a88,_0xc614ca,_0x7e6615,_0x2c9f7e){const _0x47cd5e=_0x5a9157;return _0x445d41(_0x5223e4['tag'],{'key':_0x4d5a88,...be(_0x5223e4,_0xc614ca,_0x2c9f7e),..._0x7e6615},(Ee(_0x5223e4,_0xc614ca)[_0x47cd5e(0x125)]||[])[_0x47cd5e(0x11c)]((_0x409539,_0x18da96)=>G(_0x409539,_0x4d5a88+'-'+_0x5223e4[_0x47cd5e(0x12c)]+'-'+_0x18da96,_0xc614ca,void 0x0,_0x2c9f7e)));}function be(_0x27d574,_0x3a9068,_0x50d3bf){const _0x4524b0=_0x5a9157,_0x387e5f={..._0x27d574[_0x4524b0(0x184)]};_0x50d3bf!=null&&_0x50d3bf[_0x4524b0(0x152)]&&_0x387e5f['fill']===_0x4524b0(0x152)&&(_0x387e5f['fill']=_0x50d3bf[_0x4524b0(0x152)]),_0x27d574[_0x4524b0(0x12c)]===_0x4524b0(0x1b5)&&_0x387e5f['id']&&(_0x387e5f['id']=_0x387e5f['id']+_0x3a9068[_0x4524b0(0x175)]),Object['entries'](_0x387e5f)[_0x4524b0(0x183)](([_0xbb34fb,_0x214116])=>{const _0x424387=_0x4524b0;_0xbb34fb==='mask'&&typeof _0x214116==_0x424387(0x18b)&&(_0x387e5f[_0xbb34fb]=_0x214116['replace'](/url\(#(.*)\)/,_0x424387(0x18f)+_0x3a9068[_0x424387(0x175)]+')'));});const {defIds:_0x43c136}=_0x3a9068;return!_0x43c136||_0x43c136[_0x4524b0(0x18d)]===0x0||(_0x27d574['tag']==='use'&&_0x387e5f['xlink:href']&&(_0x387e5f[_0x4524b0(0x199)]=_0x387e5f[_0x4524b0(0x199)]+_0x3a9068[_0x4524b0(0x175)]),Object[_0x4524b0(0x121)](_0x387e5f)['forEach'](([_0x4e4ed0,_0xa2838b])=>{const _0x3d9828=_0x4524b0;typeof _0xa2838b==_0x3d9828(0x18b)&&(_0x387e5f[_0x4e4ed0]=_0xa2838b['replace'](/url\(#(.*)\)/,'url(#$1'+_0x3a9068[_0x3d9828(0x175)]+')'));})),_0x387e5f;}function Ee(_0x2db2ec,_0x222fe7){const _0x53553e=_0x5a9157;var _0x210d98;const {defIds:_0x39dcfb}=_0x222fe7;return!_0x39dcfb||_0x39dcfb['length']===0x0?_0x2db2ec:_0x2db2ec[_0x53553e(0x12c)]==='defs'&&((_0x210d98=_0x2db2ec['children'])!=null&&_0x210d98[_0x53553e(0x18d)])?{..._0x2db2ec,'children':_0x2db2ec[_0x53553e(0x125)][_0x53553e(0x11c)](_0x424c08=>typeof _0x424c08[_0x53553e(0x184)]['id']==_0x53553e(0x18b)&&_0x39dcfb&&_0x39dcfb['includes'](_0x424c08[_0x53553e(0x184)]['id'])?{..._0x424c08,'attrs':{..._0x424c08['attrs'],'id':_0x424c08['attrs']['id']+_0x222fe7[_0x53553e(0x175)]}}:_0x424c08)}:_0x2db2ec;}function Oe(){const _0x675a0b=_0x5a9157;return Math['random']()[_0x675a0b(0x1a6)](0x24)['substring'](0x2,0x8);}k[_0x5a9157(0x18a)]='UniverIcon';const we={'tag':_0x5a9157(0x187),'attrs':{'xmlns':'http://www.w3.org/2000/svg','fill':_0x5a9157(0x145),'viewBox':_0x5a9157(0x173),'width':_0x5a9157(0x1b3),'height':'1em'},'children':[{'tag':'path','attrs':{'fill':_0x5a9157(0x132),'d':_0x5a9157(0x159)}},{'tag':_0x5a9157(0x12d),'attrs':{'fill':_0x5a9157(0x132),'d':_0x5a9157(0x17c),'fillRule':_0x5a9157(0x1ae),'clipRule':_0x5a9157(0x1ae)}}]},W=_0x3a591f(function(_0x9266ec,_0x26acce){const _0x563837=_0x5a9157;return _0x445d41(k,Object['assign']({},_0x9266ec,{'id':_0x563837(0x1a2),'ref':_0x26acce,'icon':we}));});W[_0x5a9157(0x18a)]=_0x5a9157(0x188);class L extends _0xa28d62{constructor(){const _0x1c1033=_0x5a9157;super(...arguments),u(this,_0x1c1033(0x189),new Set()),u(this,'_reporters',new Set());}[_0x5a9157(0x19f)](_0x3a6d42){const _0x1a8668=_0x5a9157;return this[_0x1a8668(0x189)][_0x1a8668(0x16e)](_0x3a6d42),_0x3e6459(()=>this[_0x1a8668(0x189)][_0x1a8668(0x12e)](_0x3a6d42));}['registerInitialStateReporter'](_0x14f19b){const _0x430a19=_0x5a9157;return this[_0x430a19(0x157)][_0x430a19(0x16e)](_0x14f19b),_0x3e6459(()=>this['_reporters'][_0x430a19(0x12e)](_0x14f19b));}[_0x5a9157(0x168)](_0x16d14b){const _0x28ffee=_0x5a9157;return this[_0x28ffee(0x189)]['has'](_0x16d14b);}[_0x5a9157(0x13c)](_0x4b9d74){const _0x4b079f=_0x5a9157;return Array[_0x4b079f(0x16a)](this[_0x4b079f(0x157)])[_0x4b079f(0x11c)](_0x65bfbd=>_0x65bfbd(_0x4b9d74));}}var Ne=Object[_0x5a9157(0x162)],Y=(_0x37b0e3,_0x5a90ae,_0x3eae1e,_0x3c7894)=>{const _0x1411cf=_0x5a9157;for(var _0x43b1a6=_0x3c7894>0x1?void 0x0:_0x3c7894?Ne(_0x5a90ae,_0x3eae1e):_0x5a90ae,_0x29854b=_0x37b0e3[_0x1411cf(0x18d)]-0x1,_0x4e45ce;_0x29854b>=0x0;_0x29854b--)(_0x4e45ce=_0x37b0e3[_0x29854b])&&(_0x43b1a6=_0x4e45ce(_0x43b1a6)||_0x43b1a6);return _0x43b1a6;},_=(_0xa33a29,_0x53098a)=>(_0x3f79a9,_0x36dda4)=>_0x53098a(_0x3f79a9,_0x36dda4,_0xa33a29);function _0x54c7(){const _0x39b7d5=['attrs','unsubscribe','_handleNewHost','svg','LiveShareIcon','_sharedOperations','displayName','string','setConfig','length','stopFollowing','url(#$1','defIds','217525LzCWYs','disposeWithMe','tryStartPresenting','symbol','PRESENTING','find','Present\x20this\x20document','onRendered','xlink:href','dispose$','getConfig','ONLINE','_handleOffline','has','registerSharedOperation','_handleOperation','stringify','live-share-icon','getLiveShareCoordinatorSync','_collabSession','UNIVER_UNKNOWN','toString','getMemberID','getCurrentTypeOfUnit$','467616fUPsvU','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','_uiPartsService','_univerInstanceService','pluginName','evenodd','_commandDisposable','sheet','_fetchOperations','registerComponent','1em','NEW_CHANGESETS','mask','status$','_mountLiveShare','_startPresenting','end','override','_startLiveShareCoordinator','asObservable','startFollowing','getValue','send','map','getTypeOfUnitAdded$','_beIdle','univerjs-icon\x20univerjs-icon-','not-following','entries','univer-size-4','You\x27are\x20offline.','get','children','Start\x20following','complete','values','You\x27re\x20not\x20following\x20the\x20presenter','IDLE','createInstance','tag','path','delete','_init','3653502BOwAta','getUnitId','currentColor','_collabSessionService','Stop\x20presenting','_stopFollowing','defineProperty','unitId','Start','_injector','_stopPresenting','trim','getInitialStates','button','params','_commandService','You\x27re\x20following\x20the\x20presenter','_entities','reverse','UNIVER_SHEET','_handleOnline','none','executeCommand','_liveShareService','LIVESHARE_OPERATION','_handleTerminate','FOLLOWING','_status$','getLiveShareCoordinator','1846640ldcwVj','_config','requireSession','OFFLINE','_configService','colorChannel1','default','subscribe','You\x27re\x20presenting\x20the\x20document','_unitID','_reporters','LIVESHARE_TERMINATE','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','then','dispose','OPERATION','memberID','next','idle','getStatus','3389754vyajxw','getOwnPropertyDescriptor','_startFollowing','following','LIVESHARE_FETCH_OPERATIONS','1052856QySCGt','getTypeOfUnitDisposed$','shouldShareOperation','data','from','8565459AAFyas','mutations','set','add','clear','stopPresenting','HEADER_MENU','text','0\x200\x2017\x2017','presenting','idSuffix','LIVESHARE_REQUEST_HOST','Stop\x20following','NOT_FOLLOWING','_presenter','univer-mb-3\x20univer-w-full\x20univer-text-sm','current','M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','UNIVER_LIVE_SHARE_PLUGIN','pipe','offline','init','_handleNewChangeSets','_status','forEach'];_0x54c7=function(){return _0x39b7d5;};return _0x54c7();}let S=class extends _0x1cce5c{constructor(_0x315b6e,_0x304d1b,_0x3ba4b9){const _0x501fca=_0x5a9157;super(),u(this,_0x501fca(0x141),new Map()),(this['_univerInstanceService']=_0x315b6e,this[_0x501fca(0x139)]=_0x304d1b,this[_0x501fca(0x133)]=_0x3ba4b9,this['_init']());}async[_0x5a9157(0x14c)](_0x5b02c6){const _0x7784dc=_0x5a9157;return this['_entities']['has'](_0x5b02c6)||await this['_startLiveShareCoordinator'](_0x5b02c6),this[_0x7784dc(0x141)][_0x7784dc(0x124)](_0x5b02c6);}[_0x5a9157(0x1a3)](_0x268da4){const _0x426ceb=_0x5a9157;var _0xcfdf9d;return(_0xcfdf9d=this['_entities'][_0x426ceb(0x124)](_0x268da4))!=null?_0xcfdf9d:null;}['_init'](){const _0x55a05c=_0x5a9157;this['_univerInstanceService'][_0x55a05c(0x11d)](_0x118916[_0x55a05c(0x143)])[_0x55a05c(0x17e)](_0x5bc01a(this['dispose$']))[_0x55a05c(0x154)](async _0x57c2a7=>{const _0x2622f1=_0x55a05c,_0x3e6ddc=_0x57c2a7[_0x2622f1(0x131)]();this['_entities'][_0x2622f1(0x19e)](_0x3e6ddc)||this[_0x2622f1(0x117)](_0x3e6ddc);}),this[_0x55a05c(0x1ac)][_0x55a05c(0x167)](_0x118916[_0x55a05c(0x143)])['pipe'](_0x5bc01a(this[_0x55a05c(0x19a)]))[_0x55a05c(0x154)](_0x331c33=>{const _0x9104fd=_0x55a05c,_0x287175=_0x331c33['getUnitId'](),_0x48eb15=this[_0x9104fd(0x141)][_0x9104fd(0x124)](_0x287175);_0x48eb15==null||_0x48eb15['dispose']();});}async[_0x5a9157(0x117)](_0x274525){const _0x4c5ae2=_0x5a9157,_0x13c343=await this['_collabSessionService'][_0x4c5ae2(0x14f)](_0x274525),_0x5dcc38=this[_0x4c5ae2(0x139)][_0x4c5ae2(0x12b)](N,_0x274525,_0x13c343);return _0x5dcc38[_0x4c5ae2(0x180)](),this['_entities'][_0x4c5ae2(0x16d)](_0x274525,_0x5dcc38),_0x5dcc38;}};S=Y([_(0x0,_0x2bf8ed),_(0x1,_0x5890f3(_0x2ac967)),_(0x2,_0x5890f3(_0x270da6))],S);var c=(_0x3dd772=>(_0x3dd772[_0x5a9157(0x150)]=_0x5a9157(0x17f),_0x3dd772[_0x5a9157(0x12a)]=_0x5a9157(0x15f),_0x3dd772['FOLLOWING']=_0x5a9157(0x164),_0x3dd772[_0x5a9157(0x178)]=_0x5a9157(0x120),_0x3dd772['PRESENTING']=_0x5a9157(0x174),_0x3dd772))(c||{});const Ce='SAME_OPERATION_SHARE_INTERVAL',De=0xc8;let N=class extends _0x1cce5c{constructor(_0xb205f3,_0x145752,_0x10357b,_0x3da1b7,_0x3c2a71){const _0x11a0a2=_0x5a9157;super(),u(this,'_status$',new _0x4812e4(_0x11a0a2(0x15f))),u(this,_0x11a0a2(0x1b6),this[_0x11a0a2(0x14b)][_0x11a0a2(0x118)]()),u(this,_0x11a0a2(0x12f),!0x1),u(this,'_commandDisposable',null),u(this,_0x11a0a2(0x179),null),(this[_0x11a0a2(0x156)]=_0xb205f3,this[_0x11a0a2(0x1a4)]=_0x145752,this['_configService']=_0x10357b,this['_liveShareService']=_0x3da1b7,this[_0x11a0a2(0x13f)]=_0x3c2a71);}get[_0x5a9157(0x182)](){const _0x590aa9=_0x5a9157;return this['_status$'][_0x590aa9(0x11a)]();}[_0x5a9157(0x15b)](){const _0x1b17eb=_0x5a9157;var _0x419afe;(_0x419afe=this['_commandDisposable'])==null||_0x419afe[_0x1b17eb(0x15b)](),this['_status$'][_0x1b17eb(0x15e)](_0x1b17eb(0x15f)),this[_0x1b17eb(0x14b)][_0x1b17eb(0x127)]();}[_0x5a9157(0x160)](){const _0x2a4fc6=_0x5a9157;return this[_0x2a4fc6(0x182)];}[_0x5a9157(0x180)](){const _0x24d726=_0x5a9157;this[_0x24d726(0x12f)]||(this[_0x24d726(0x12f)]=!0x0,this['_collabSession']['sessionStatus$'][_0x24d726(0x17e)](_0x5bc01a(this[_0x24d726(0x19a)]))['subscribe'](_0x516d76=>{const _0x5bc4aa=_0x24d726;switch(_0x516d76){case _0x1f086f[_0x5bc4aa(0x150)]:this[_0x5bc4aa(0x19d)]();break;case _0x1f086f[_0x5bc4aa(0x19c)]:this[_0x5bc4aa(0x144)]();break;}}),this['_collabSession']['event$']['pipe'](_0x5bc01a(this['dispose$']))[_0x24d726(0x154)](_0x3abf42=>{const _0x35f5a9=_0x24d726,{eventID:_0x155f0d}=_0x3abf42;switch(_0x155f0d){case _0xb6d82['LIVESHARE_NEW_HOST']:this[_0x35f5a9(0x186)](_0x3abf42);break;case _0xb6d82[_0x35f5a9(0x148)]:this[_0x35f5a9(0x1a0)](_0x3abf42);break;case _0xb6d82[_0x35f5a9(0x158)]:this[_0x35f5a9(0x149)]();break;case _0xb6d82[_0x35f5a9(0x1b4)]:this[_0x35f5a9(0x181)](_0x3abf42);break;}}));}['tryStartPresenting'](){const _0x4c0715=_0x5a9157;this['_collabSession'][_0x4c0715(0x11b)]({'eventID':_0xb6d82[_0x4c0715(0x176)],'data':{'unitID':this['_unitID'],'userID':this[_0x4c0715(0x1a4)][_0x4c0715(0x1a7)]()}},this[_0x4c0715(0x156)]);}[_0x5a9157(0x170)](){const _0x350fc6=_0x5a9157;this[_0x350fc6(0x182)]==='presenting'&&(this[_0x350fc6(0x14b)]['next'](_0x350fc6(0x15f)),this[_0x350fc6(0x1a4)][_0x350fc6(0x11b)]({'eventID':_0xb6d82[_0x350fc6(0x158)],'data':{'unitID':this[_0x350fc6(0x156)]}},this[_0x350fc6(0x156)]));}['startFollowing'](){const _0x98e65=_0x5a9157;this[_0x98e65(0x182)]===_0x98e65(0x120)&&(this['_status$'][_0x98e65(0x15e)](_0x98e65(0x164)),this[_0x98e65(0x163)]());}['stopFollowing'](){const _0x2d5c57=_0x5a9157;this['_status']===_0x2d5c57(0x164)&&this[_0x2d5c57(0x135)]();}[_0x5a9157(0x186)](_0x1c646f){const _0x19fecd=_0x5a9157,{presenter:_0x4a340c}=_0x1c646f[_0x19fecd(0x169)],_0x52a714=this[_0x19fecd(0x1a4)][_0x19fecd(0x1a7)]();this[_0x19fecd(0x179)]=_0x4a340c,_0x4a340c===_0x52a714?(this[_0x19fecd(0x135)](),this[_0x19fecd(0x1b8)]()):this['_status']!==_0x19fecd(0x120)&&(this[_0x19fecd(0x13a)](),this[_0x19fecd(0x163)]());}['_fetchOperations'](){const _0x177e9a=_0x5a9157,_0xc199c3={'eventID':_0xb6d82[_0x177e9a(0x165)]};this[_0x177e9a(0x1a4)][_0x177e9a(0x11b)](_0xc199c3,this[_0x177e9a(0x156)]);}[_0x5a9157(0x149)](){const _0x1e3f06=_0x5a9157;this['_presenter']=null,this['_status']!=='presenting'&&this[_0x1e3f06(0x11e)]();}[_0x5a9157(0x181)](_0x36b89e){const _0x193e4d=_0x5a9157;if(this[_0x193e4d(0x182)]===_0x193e4d(0x164)&&this[_0x193e4d(0x179)]===_0x36b89e[_0x193e4d(0x169)][_0x193e4d(0x15d)]){const _0x540c5e=_0x448a4b(_0x36b89e[_0x193e4d(0x169)])[_0x193e4d(0x16c)][_0x193e4d(0x142)]()[_0x193e4d(0x196)](_0x45d7bf=>_0x45d7bf['id']===_0x1a8b78['id']);if(_0x540c5e){const _0x4dd3b6=_0x540c5e[_0x193e4d(0x13e)][_0x193e4d(0x137)],_0x1ac1b9=_0x540c5e['params'][_0x193e4d(0x1b0)]['id'];setTimeout(()=>{const _0xee294a=_0x193e4d;this['_commandService'][_0xee294a(0x146)](_0x4ff82e['id'],{'unitId':_0x4dd3b6,'subUnitId':_0x1ac1b9},{'fromCollab':!0x0});});}}}['_startPresenting'](){const _0x2fcc17=_0x5a9157;this[_0x2fcc17(0x14b)]['next']('presenting');const _0xf2a2fc=new Map(),_0x44940d=this[_0x2fcc17(0x1af)]=new _0x5315c9();_0x44940d[_0x2fcc17(0x16e)](_0x3e6459(()=>{const _0x53be83=_0x2fcc17;_0xf2a2fc[_0x53be83(0x183)](_0x367a3b=>_0x367a3b[_0x53be83(0x127)]()),_0xf2a2fc[_0x53be83(0x16f)]();})),_0x44940d[_0x2fcc17(0x16e)](this[_0x2fcc17(0x13f)]['onCommandExecuted'](_0x5bea74=>{const _0x462bee=_0x2fcc17;var _0x52d583;if(_0x5bea74['type']!==_0x55dc24[_0x462bee(0x15c)]||!this['_liveShareService'][_0x462bee(0x168)](_0x5bea74['id']))return;const {id:_0xb9e8ff}=_0x5bea74;let _0x372092;_0xf2a2fc[_0x462bee(0x19e)](_0xb9e8ff)?_0x372092=_0xf2a2fc[_0x462bee(0x124)](_0xb9e8ff):(_0x372092=new _0x4797b2(),_0xf2a2fc['set'](_0xb9e8ff,_0x372092),_0x372092[_0x462bee(0x17e)](_0x1e0766((_0x52d583=this[_0x462bee(0x151)][_0x462bee(0x19b)](Ce))!=null?_0x52d583:De,void 0x0,{'trailing':!0x0,'leading':!0x0}))['subscribe'](_0x2d940a=>{const _0x2e3533=_0x462bee;this[_0x2e3533(0x1a4)][_0x2e3533(0x11b)]({'eventID':_0xb6d82[_0x2e3533(0x148)],'data':{'unitID':this[_0x2e3533(0x156)],'operations':{[_0x2d940a['id']]:{'id':_0x2d940a['id'],'params':JSON[_0x2e3533(0x1a1)](_0x2d940a[_0x2e3533(0x13e)])}}}},this[_0x2e3533(0x156)]);})),_0x372092['next'](_0x5bea74);})),this[_0x2fcc17(0x147)][_0x2fcc17(0x13c)](this['_unitID'])[_0x2fcc17(0x183)](_0x7bda83=>this[_0x2fcc17(0x1a4)]['send']({'eventID':_0xb6d82[_0x2fcc17(0x148)],'data':{'unitID':this[_0x2fcc17(0x156)],'operations':{[_0x7bda83['id']]:{'id':_0x7bda83['id'],'params':JSON[_0x2fcc17(0x1a1)](_0x7bda83[_0x2fcc17(0x13e)])}}}},this[_0x2fcc17(0x156)]));}[_0x5a9157(0x13a)](){const _0x2e424e=_0x5a9157;var _0x4d1b4f;this[_0x2e424e(0x14b)][_0x2e424e(0x15e)](_0x2e424e(0x15f)),(_0x4d1b4f=this[_0x2e424e(0x1af)])==null||_0x4d1b4f[_0x2e424e(0x15b)](),this['_commandDisposable']=null;}[_0x5a9157(0x163)](){const _0x2bf1fb=_0x5a9157;var _0x27743f;(_0x27743f=this[_0x2bf1fb(0x1af)])==null||_0x27743f[_0x2bf1fb(0x15b)](),this[_0x2bf1fb(0x14b)][_0x2bf1fb(0x15e)](_0x2bf1fb(0x164));}[_0x5a9157(0x11e)](){const _0x2f179d=_0x5a9157;var _0x292e3d;this[_0x2f179d(0x14b)][_0x2f179d(0x15e)](_0x2f179d(0x15f)),(_0x292e3d=this[_0x2f179d(0x1af)])==null||_0x292e3d[_0x2f179d(0x15b)](),this[_0x2f179d(0x1af)]=null;}['_stopFollowing'](){const _0x4d74f4=_0x5a9157;var _0x5a5b28;this[_0x4d74f4(0x14b)]['next']('not-following'),(_0x5a5b28=this['_commandDisposable'])==null||_0x5a5b28['dispose']();}[_0x5a9157(0x1a0)](_0x3d307d){const _0x2213ae=_0x5a9157;if([_0x2213ae(0x174),'not-following',_0x2213ae(0x17f)]['includes'](this[_0x2213ae(0x182)])||!_0x3d307d[_0x2213ae(0x169)]['presenter']||_0x3d307d['data']['presenter']===this[_0x2213ae(0x1a4)][_0x2213ae(0x1a7)]())return;this[_0x2213ae(0x182)]===_0x2213ae(0x15f)&&this['_startFollowing']();const _0x2e8e55=_0x3d307d[_0x2213ae(0x169)]['operations'];Object[_0x2213ae(0x128)](_0x2e8e55)['forEach'](_0x2fffe2=>{const _0x1e2da0=_0x2213ae;this[_0x1e2da0(0x13f)][_0x1e2da0(0x146)](_0x2fffe2['id'],_0x2fffe2[_0x1e2da0(0x13e)]?JSON['parse'](_0x2fffe2['params']):null,{'fromCollab':!0x0});});}['_handleOffline'](){const _0x5b4b85=_0x5a9157;var _0x4085e0;this['_status$'][_0x5b4b85(0x15e)](_0x5b4b85(0x17f)),(_0x4085e0=this[_0x5b4b85(0x1af)])==null||_0x4085e0[_0x5b4b85(0x15b)]();}[_0x5a9157(0x144)](){const _0xc3ec29=_0x5a9157;this[_0xc3ec29(0x14b)][_0xc3ec29(0x15e)](_0xc3ec29(0x15f)),this[_0xc3ec29(0x1b1)]();}};N=Y([_(0x2,_0x2ccd3e),_(0x3,_0x5890f3(L)),_(0x4,_0x8f3e9)],N);function Le(){const _0x87951d=_0x5a9157,_0x164387=_0x14fb74(S),_0x527671=_0x14fb74(_0x2bf8ed),_0x462115=_0x25b804(()=>_0x527671[_0x87951d(0x1a8)](_0x118916['UNIVER_SHEET']),void 0x0,!0x1,[]),[_0x5233cb,_0x38fdee]=_0x5ab416(null),[_0x2043e4,_0x267a6e]=_0x5ab416(c['IDLE']),_0x4d1cae=_0x3a8f3b(null);return _0x34456e(()=>(_0x462115&&_0x164387['getLiveShareCoordinator'](_0x462115['getUnitId']())[_0x87951d(0x15a)](_0x354ae1=>{const _0x5a6f76=_0x87951d;_0x38fdee(_0x354ae1),_0x4d1cae[_0x5a6f76(0x17b)]=_0x354ae1[_0x5a6f76(0x1b6)][_0x5a6f76(0x154)](_0x3caaac=>{_0x267a6e(_0x3caaac);});}),()=>{const _0x2c52bb=_0x87951d;var _0x77fa80;(_0x77fa80=_0x4d1cae[_0x2c52bb(0x17b)])==null||_0x77fa80[_0x2c52bb(0x185)](),_0x4d1cae['current']=null;}),[_0x462115,_0x164387]),_0x5233cb?_0xe9d27a(_0x1d5dcc,{'align':_0x87951d(0x115),'disabled':_0x2043e4===c['OFFLINE'],'className':_0x87951d(0x1aa),'overlay':_0xe9d27a(Re,{'status':_0x2043e4,'coordinator':_0x5233cb}),'children':_0xe9d27a(_0x87951d(0x13d),{'className':_0x26827b('univer-border-none\x20univer-text-gray-600\x20univer-outline-none',{'univer-cursor-not-allowed':_0x2043e4===c[_0x87951d(0x150)],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x2043e4!==c['OFFLINE']}),'type':_0x87951d(0x13d),'children':_0xe9d27a(W,{'className':_0x87951d(0x122)})})}):null;}function Re(_0x25aabb){const _0xc61288=_0x5a9157,{status:_0xb36f22,coordinator:_0x4f0364}=_0x25aabb;switch(_0xb36f22){case c[_0xc61288(0x12a)]:return _0xe9d27a($e,{'coordinator':_0x4f0364});case c[_0xc61288(0x14a)]:return _0xe9d27a(xe,{'coordinator':_0x4f0364});case c[_0xc61288(0x178)]:return _0xe9d27a(Pe,{'coordinator':_0x4f0364});case c[_0xc61288(0x150)]:return _0xe9d27a(Te,{});case c[_0xc61288(0x195)]:return _0xe9d27a(Ae,{'coordinator':_0x4f0364});default:return null;}}function $e(_0x138a99){const _0x1fcc54=_0x5a9157,{coordinator:_0xe4e224}=_0x138a99;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x1fcc54(0x197)}),_0xe9d27a(_0x43cbc8,{'onClick':()=>_0xe4e224[_0x1fcc54(0x193)](),'children':_0x1fcc54(0x138)})]});}function xe(_0xf8d35a){const _0x8632b9=_0x5a9157,{coordinator:_0x4e338a}=_0xf8d35a;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':_0x8632b9(0x17a),'children':_0x8632b9(0x140)}),_0xe9d27a(_0x43cbc8,{'onClick':()=>_0x4e338a[_0x8632b9(0x18e)](),'children':_0x8632b9(0x177)})]});}function Pe(_0xca9462){const _0x14c1ab=_0x5a9157,{coordinator:_0x253fb9}=_0xca9462;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':_0x14c1ab(0x17a),'children':_0x14c1ab(0x129)}),_0xe9d27a(_0x43cbc8,{'variant':_0x14c1ab(0x172),'onClick':()=>_0x253fb9[_0x14c1ab(0x119)](),'children':_0x14c1ab(0x126)})]});}function Ae(_0x1b67b1){const _0x14432f=_0x5a9157,{coordinator:_0x21cc66}=_0x1b67b1;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':_0x14432f(0x17a),'children':_0x14432f(0x155)}),_0xe9d27a(_0x43cbc8,{'variant':_0x14432f(0x153),'onClick':()=>_0x21cc66[_0x14432f(0x170)](),'children':_0x14432f(0x134)})]});}function Te(){const _0x27306e=_0x5a9157;return _0xe9d27a(_0x21e76d,{'children':_0x27306e(0x123)});}var Fe=Object[_0x5a9157(0x162)],He=(_0x680c97,_0x572487,_0x3190e6,_0x778131)=>{for(var _0x5de778=_0x778131>0x1?void 0x0:_0x778131?Fe(_0x572487,_0x3190e6):_0x572487,_0x38b7e5=_0x680c97['length']-0x1,_0x45b85c;_0x38b7e5>=0x0;_0x38b7e5--)(_0x45b85c=_0x680c97[_0x38b7e5])&&(_0x5de778=_0x45b85c(_0x5de778)||_0x5de778);return _0x5de778;},A=(_0x1c08f4,_0x269771)=>(_0x11bdcd,_0x5f11f9)=>_0x269771(_0x11bdcd,_0x5f11f9,_0x1c08f4);let m=class extends _0xa28d62{constructor(_0x4e63bf,_0x33ce12){const _0x3f3c5b=_0x5a9157;super(),this[_0x3f3c5b(0x139)]=_0x4e63bf,this[_0x3f3c5b(0x1ab)]=_0x33ce12,this[_0x3f3c5b(0x1b7)]();}['_mountLiveShare'](){const _0x59c071=_0x5a9157;this[_0x59c071(0x192)](this[_0x59c071(0x1ab)][_0x59c071(0x1b2)](_0x3df1ce[_0x59c071(0x171)],()=>_0x360939(Le,this[_0x59c071(0x139)])));}};m=He([A(0x0,_0x5890f3(_0x2ac967)),A(0x1,_0x4b3e7b)],m);const ye='live-share.config',T={};var Ue=Object['getOwnPropertyDescriptor'],Ve=(_0x58121e,_0xe4291d,_0x278131,_0x54e350)=>{const _0x52190f=_0x5a9157;for(var _0x5868df=_0x54e350>0x1?void 0x0:_0x54e350?Ue(_0xe4291d,_0x278131):_0xe4291d,_0x5c0c07=_0x58121e[_0x52190f(0x18d)]-0x1,_0x51bd8c;_0x5c0c07>=0x0;_0x5c0c07--)(_0x51bd8c=_0x58121e[_0x5c0c07])&&(_0x5868df=_0x51bd8c(_0x5868df)||_0x5868df);return _0x5868df;},je=(_0x5922ab,_0x1a4687)=>(_0x4deae9,_0x52beb5)=>_0x1a4687(_0x4deae9,_0x52beb5,_0x5922ab);let I=class extends _0xa28d62{constructor(_0x1e4d9c){const _0x5d3252=_0x5a9157;super(),this[_0x5d3252(0x147)]=_0x1e4d9c,this[_0x5d3252(0x12f)]();}['_init'](){const _0x2d1dbb=_0x5a9157;[_0x1f21c4['id'],_0x447fe5['id'],_0x4ff82e['id']][_0x2d1dbb(0x183)](_0x558ce7=>{const _0xaaf13e=_0x2d1dbb;this[_0xaaf13e(0x192)](this[_0xaaf13e(0x147)]['registerSharedOperation'](_0x558ce7));});}};I=Ve([je(0x0,_0x5890f3(L))],I);var Me=Object[_0x5a9157(0x136)],ke=Object[_0x5a9157(0x162)],Ge=(_0x2538d1,_0x252d75,_0xd3309f)=>_0x252d75 in _0x2538d1?Me(_0x2538d1,_0x252d75,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0xd3309f}):_0x2538d1[_0x252d75]=_0xd3309f,We=(_0x4752a5,_0x520908,_0x2c7a48,_0x1ce47c)=>{const _0xdf8090=_0x5a9157;for(var _0x4daee4=_0x1ce47c>0x1?void 0x0:_0x1ce47c?ke(_0x520908,_0x2c7a48):_0x520908,_0x2172ca=_0x4752a5[_0xdf8090(0x18d)]-0x1,_0x1376a9;_0x2172ca>=0x0;_0x2172ca--)(_0x1376a9=_0x4752a5[_0x2172ca])&&(_0x4daee4=_0x1376a9(_0x4daee4)||_0x4daee4);return _0x4daee4;},F=(_0x44eeb0,_0xe537e3)=>(_0x5c8c85,_0x1585d5)=>_0xe537e3(_0x5c8c85,_0x1585d5,_0x44eeb0),B=(_0x5db21f,_0x4e46c8,_0x5e04e6)=>Ge(_0x5db21f,typeof _0x4e46c8!=_0x5a9157(0x194)?_0x4e46c8+'':_0x4e46c8,_0x5e04e6);const Ye=_0x5a9157(0x17d);let b=class extends _0x446406{constructor(_0x25cfd7=T,_0x5a0473,_0x2754a2){const _0xb2ab96=_0x5a9157;super(),this['_config']=_0x25cfd7,this[_0xb2ab96(0x139)]=_0x5a0473,this[_0xb2ab96(0x151)]=_0x2754a2;const {..._0x78e952}=_0x230b34({},T,this[_0xb2ab96(0x14e)]);this[_0xb2ab96(0x151)][_0xb2ab96(0x18c)](ye,_0x78e952);}['onStarting'](){const _0x4e70cb=_0x5a9157;_0x3ca90e(this[_0x4e70cb(0x139)],_0x1d22c6([[L],[S],[I],[m]],this[_0x4e70cb(0x14e)][_0x4e70cb(0x116)])),_0xa89abb(this[_0x4e70cb(0x139)],[[I]]);}[_0x5a9157(0x198)](){const _0x4ce401=_0x5a9157;_0xa89abb(this[_0x4ce401(0x139)],[[m]]);}};B(b,'type',_0x118916[_0x5a9157(0x1a5)]),B(b,_0x5a9157(0x1ad),Ye),b=We([_0x2c9f12(_0x270228),F(0x1,_0x5890f3(_0x2ac967)),F(0x2,_0x2ccd3e)],b);export{m as DesktopLiveShareController,Le as LiveShare,S as LiveShareController,N as LiveShareCoordinator,L as LiveShareService,c as LiveShareStatus,b as UniverLiveSharePlugin};
|
package/lib/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const _0x2561c3=_0x639e;function _0x639e(_0x26429c,_0x5f5b79){_0x26429c=_0x26429c-0xcc;const _0x17e9a0=_0x17e9();let _0x639ef=_0x17e9a0[_0x26429c];return _0x639ef;}(function(_0x122c71,_0x4438d4){const _0x4c5884=_0x639e,_0x47910b=_0x122c71();while(!![]){try{const _0x2c6626=-parseInt(_0x4c5884(0xd2))/0x1+-parseInt(_0x4c5884(0xd3))/0x2+parseInt(_0x4c5884(0xe6))/0x3*(-parseInt(_0x4c5884(0xe3))/0x4)+-parseInt(_0x4c5884(0xda))/0x5*(parseInt(_0x4c5884(0xdc))/0x6)+parseInt(_0x4c5884(0xcd))/0x7+-parseInt(_0x4c5884(0xeb))/0x8*(parseInt(_0x4c5884(0xd1))/0x9)+-parseInt(_0x4c5884(0xce))/0xa*(-parseInt(_0x4c5884(0xd9))/0xb);if(_0x2c6626===_0x4438d4)break;else _0x47910b['push'](_0x47910b['shift']());}catch(_0x245698){_0x47910b['push'](_0x47910b['shift']());}}}(_0x17e9,0x2e84b));import{LiveShareController as _0x204761,LiveShareStatus as _0x5af292}from'@univerjs-pro/live-share';import{IRenderManagerService as _0x585a07}from'@univerjs/engine-render';import{SetWorksheetActiveOperation as _0xabbfd8}from'@univerjs/sheets';import{SetScrollOperation as _0x2dfe55}from'@univerjs/sheets-ui';import{FRange as _0x426e48}from'@univerjs/sheets/facade';import{FUniver as _0x29f894,FEnum as _0x444374}from'@univerjs/core/facade';class I extends _0x426e48{[_0x2561c3(0xdd)](_0x3056de,_0x5b0d90,_0x35a303,_0x52bbd4,_0x51f56c){const _0x5b3b59=_0x2561c3,_0x59bb58=_0x3056de[_0x5b3b59(0xe5)](_0x204761),_0x1e4fd5=_0x3056de[_0x5b3b59(0xe5)](_0x585a07),_0x549598=_0x5b0d90['getUnitId'](),_0x3ff9f1=_0x5b0d90[_0x5b3b59(0xe4)](),_0x108e77=_0x59bb58[_0x5b3b59(0xcc)](_0x549598);(_0x108e77==null?void 0x0:_0x108e77[_0x5b3b59(0xd6)]())!==_0x5af292['PRESENTING']||(_0x35a303[_0x5b3b59(0xd4)]()!==_0x3ff9f1[_0x5b3b59(0xd4)]()&&this[_0x5b3b59(0xdf)][_0x5b3b59(0xe9)](_0xabbfd8['id'],{'unitId':_0x549598,'subUnitId':_0x35a303['getSheetId']()}),!_0x1e4fd5['getRenderById'](_0x549598))||_0x51f56c['syncExecuteCommand'](_0x2dfe55['id'],{'unitId':_0x5b0d90[_0x5b3b59(0xe7)](),'sheetId':_0x35a303['getSheetId'](),'sheetViewStartRow':_0x52bbd4['startRow'],'sheetViewStartColumn':_0x52bbd4[_0x5b3b59(0xd5)],'offsetX':0x0,'offsetY':0x0,'screenRatioX':-0x1/0x3,'screenRatioY':-0x1/0x3,'duration':0x12c});}}_0x426e48[_0x2561c3(0xe8)](I);class m extends _0x29f894{['getLiveShareStatus'](){const _0x5775fa=_0x2561c3;var _0x4803a2,_0x453d4;const _0x3dca3c=this[_0x5775fa(0xe0)][_0x5775fa(0xe5)](_0x204761),_0x5308c1=(_0x4803a2=this[_0x5775fa(0xdb)]())==null?void 0x0:_0x4803a2[_0x5775fa(0xea)]();if(!_0x5308c1)throw new Error(_0x5775fa(0xe1));const _0x4a1981=_0x3dca3c[_0x5775fa(0xcc)](_0x5308c1);return(_0x453d4=_0x4a1981==null?void 0x0:_0x4a1981[_0x5775fa(0xd6)]())!=null?_0x453d4:_0x5af292[_0x5775fa(0xd0)];}[_0x2561c3(0xe2)](){const _0x56ac37=_0x2561c3;var _0x2a1a51;const _0x5f2911=this[_0x56ac37(0xe0)][_0x56ac37(0xe5)](_0x204761),_0x2e43f9=(_0x2a1a51=this[_0x56ac37(0xdb)]())==null?void 0x0:_0x2a1a51['getId']();if(!_0x2e43f9)throw new Error(_0x56ac37(0xe1));const _0xea5ea8=_0x5f2911[_0x56ac37(0xcc)](_0x2e43f9);if(!_0xea5ea8)throw new Error('No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.');_0xea5ea8['startFollowing']();}[_0x2561c3(0xcf)](){const _0x160ab0=_0x2561c3;var _0xd4633f;const _0x11ee3b=this['_injector'][_0x160ab0(0xe5)](_0x204761),_0x2ba408=(_0xd4633f=this['getActiveWorkbook']())==null?void 0x0:_0xd4633f['getId']();if(!_0x2ba408)throw new Error(_0x160ab0(0xe1));const _0x54d5e8=_0x11ee3b['getLiveShareCoordinatorSync'](_0x2ba408);if(!_0x54d5e8)throw new Error(_0x160ab0(0xec));_0x54d5e8[_0x160ab0(0xcf)]();}[_0x2561c3(0xd8)](){const _0x1bda36=_0x2561c3;var _0x1d7986;const _0x4e127e=this[_0x1bda36(0xe0)]['get'](_0x204761),_0x1355be=(_0x1d7986=this['getActiveWorkbook']())==null?void 0x0:_0x1d7986[_0x1bda36(0xea)]();if(!_0x1355be)throw new Error(_0x1bda36(0xe1));const _0x474541=_0x4e127e['getLiveShareCoordinatorSync'](_0x1355be);if(!_0x474541)throw new Error(_0x1bda36(0xec));_0x474541[_0x1bda36(0xde)]();}[_0x2561c3(0xd7)](){const _0x53d076=_0x2561c3;var _0x2808d5;const _0x5d4a44=this[_0x53d076(0xe0)][_0x53d076(0xe5)](_0x204761),_0xa867df=(_0x2808d5=this[_0x53d076(0xdb)]())==null?void 0x0:_0x2808d5[_0x53d076(0xea)]();if(!_0xa867df)throw new Error('No\x20active\x20workbook\x20found.');const _0x2b9413=_0x5d4a44[_0x53d076(0xcc)](_0xa867df);if(!_0x2b9413)throw new Error('No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.');_0x2b9413[_0x53d076(0xd7)]();}}_0x29f894[_0x2561c3(0xe8)](m);class C extends _0x444374{get['LiveShareStatusEnum'](){return _0x5af292;}}_0x444374['extend'](C);function _0x17e9(){const _0x5314ef=['getUnitId','extend','executeCommand','getId','838232doQIbC','No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.','getLiveShareCoordinatorSync','300496eITPyP','10wYnpJY','stopFollowing','IDLE','18gGFVyC','279858hDoivd','145270EROWIB','getSheetId','startColumn','getStatus','stopPresenting','startPresenting','13822765YKUMZH','5XYfgdU','getActiveWorkbook','1540038FCejAP','_initialize','tryStartPresenting','_commandService','_injector','No\x20active\x20workbook\x20found.','startFollowing','1312cPXXWC','getActiveSheet','get','2655mRrCPP'];_0x17e9=function(){return _0x5314ef;};return _0x17e9();}
|
package/lib/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0xf02626=_0x49a3;(function(_0x5331b5,_0x52e9fb){const _0x5438da=_0x49a3,_0x1b6945=_0x5331b5();while(!![]){try{const _0x39df04=-parseInt(_0x5438da(0x1a3))/0x1*(-parseInt(_0x5438da(0x17f))/0x2)+-parseInt(_0x5438da(0x133))/0x3*(parseInt(_0x5438da(0x121))/0x4)+-parseInt(_0x5438da(0x13f))/0x5+parseInt(_0x5438da(0x1b8))/0x6*(-parseInt(_0x5438da(0x141))/0x7)+-parseInt(_0x5438da(0x159))/0x8*(parseInt(_0x5438da(0x17c))/0x9)+-parseInt(_0x5438da(0x13e))/0xa+parseInt(_0x5438da(0x126))/0xb;if(_0x39df04===_0x52e9fb)break;else _0x1b6945['push'](_0x1b6945['shift']());}catch(_0x3cfe13){_0x1b6945['push'](_0x1b6945['shift']());}}}(_0x3d06,0xa7477));var J=Object[_0xf02626(0x19c)],K=(_0x5ae237,_0x29cd28,_0x1e5d46)=>_0x29cd28 in _0x5ae237?J(_0x5ae237,_0x29cd28,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x1e5d46}):_0x5ae237[_0x29cd28]=_0x1e5d46,u=(_0x2615bb,_0x50aec8,_0x21469a)=>K(_0x2615bb,typeof _0x50aec8!=_0xf02626(0x18f)?_0x50aec8+'':_0x50aec8,_0x21469a);import{Disposable as _0x5bdbec,toDisposable as _0x5dd282,IUniverInstanceService as _0x246214,Inject as _0x13dd86,Injector as _0x5b65f0,IConfigService as _0x5c1fc8,ICommandService as _0x1549da,RxDisposable as _0x443063,UniverInstanceType as _0x57e1a6,DisposableCollection as _0xd84b84,CommandType as _0x13511b,DependentOn as _0x3a182e,Plugin as _0x586d52,merge as _0x12b34e,registerDependencies as _0x2186bd,mergeOverrideWithDependencies as _0x29be9b,touchDependencies as _0x31d787}from'@univerjs/core';import{useDependency as _0x4e3e8c,useObservable as _0x262950,IUIPartsService as _0x28a6d1,BuiltInUIPart as _0x50c32d,connectInjector as _0x11eeaf}from'@univerjs/ui';import{jsx as _0x3f1572,jsxs as _0x10f9f1,Fragment as _0x561b68}from'react/jsx-runtime';import{Dropdown as _0x49c23a,clsx as _0x37a6a0,Button as _0x1555cd}from'@univerjs/design';import{useRef as _0x922483,createElement as _0x2b29b6,forwardRef as _0x50463f,useState as _0x430a47,useEffect as _0x4a4b6f}from'react';import{CollaborationEvent as _0x41b597,parseProtocolChangeset as _0x1061ca}from'@univerjs-pro/collaboration';import{CollaborationSessionService as _0x374a90,SessionStatus as _0x1c448e,UniverCollaborationClientPlugin as _0x400e7c}from'@univerjs-pro/collaboration-client';import{InsertSheetMutation as _0x2abf81,SetWorksheetActiveOperation as _0x218042}from'@univerjs/sheets';import{BehaviorSubject as _0x26b77b,Subject as _0x5a754c}from'rxjs';import{takeUntil as _0x461f78,throttleTime as _0x471303}from'rxjs/operators';import{SetZoomRatioOperation as _0x5b6fb4,SetScrollOperation as _0x54eb58}from'@univerjs/sheets-ui';function k({ref:_0x45d44c,..._0x431046}){const _0x311fa5=_0xf02626,{icon:_0x5c5c05,id:_0x33ae4a,className:_0x443872,extend:_0x1606c0,..._0x12d90a}=_0x431046,_0x20e022=(_0x311fa5(0x154)+_0x33ae4a+'\x20'+(_0x443872||''))[_0x311fa5(0x1a8)](),_0x1f4950=_0x922483('_'+Oe());return G(_0x5c5c05,''+_0x33ae4a,{'defIds':_0x5c5c05['defIds'],'idSuffix':_0x1f4950[_0x311fa5(0x1ba)]},{'ref':_0x45d44c,'className':_0x20e022,..._0x12d90a},_0x1606c0);}function G(_0x1dbecf,_0x3a8b92,_0x4e6a23,_0x16ea80,_0x36b1bf){const _0x50e375=_0xf02626;return _0x2b29b6(_0x1dbecf[_0x50e375(0x1b6)],{'key':_0x3a8b92,...be(_0x1dbecf,_0x4e6a23,_0x36b1bf),..._0x16ea80},(Ee(_0x1dbecf,_0x4e6a23)[_0x50e375(0x146)]||[])[_0x50e375(0x181)]((_0x24911d,_0x4b43a2)=>G(_0x24911d,_0x3a8b92+'-'+_0x1dbecf[_0x50e375(0x1b6)]+'-'+_0x4b43a2,_0x4e6a23,void 0x0,_0x36b1bf)));}function be(_0x133a49,_0x300770,_0x292fe8){const _0x456b02=_0xf02626,_0x3266a8={..._0x133a49[_0x456b02(0x164)]};_0x292fe8!=null&&_0x292fe8['colorChannel1']&&_0x3266a8[_0x456b02(0x199)]==='colorChannel1'&&(_0x3266a8[_0x456b02(0x199)]=_0x292fe8[_0x456b02(0x1ad)]),_0x133a49[_0x456b02(0x1b6)]==='mask'&&_0x3266a8['id']&&(_0x3266a8['id']=_0x3266a8['id']+_0x300770[_0x456b02(0x17e)]),Object['entries'](_0x3266a8)['forEach'](([_0x51a95d,_0x41d3fc])=>{const _0xe87a3a=_0x456b02;_0x51a95d===_0xe87a3a(0x19b)&&typeof _0x41d3fc==_0xe87a3a(0x19a)&&(_0x3266a8[_0x51a95d]=_0x41d3fc[_0xe87a3a(0x162)](/url\(#(.*)\)/,_0xe87a3a(0x178)+_0x300770[_0xe87a3a(0x17e)]+')'));});const {defIds:_0x1f9156}=_0x300770;return!_0x1f9156||_0x1f9156[_0x456b02(0x193)]===0x0||(_0x133a49['tag']===_0x456b02(0x152)&&_0x3266a8[_0x456b02(0x171)]&&(_0x3266a8[_0x456b02(0x171)]=_0x3266a8[_0x456b02(0x171)]+_0x300770[_0x456b02(0x17e)]),Object[_0x456b02(0x139)](_0x3266a8)[_0x456b02(0x197)](([_0x4a9000,_0x5377c9])=>{const _0x32d52a=_0x456b02;typeof _0x5377c9==_0x32d52a(0x19a)&&(_0x3266a8[_0x4a9000]=_0x5377c9['replace'](/url\(#(.*)\)/,_0x32d52a(0x178)+_0x300770[_0x32d52a(0x17e)]+')'));})),_0x3266a8;}function Ee(_0x5a80d,_0x43d5cd){const _0x3107af=_0xf02626;var _0x3dcc55;const {defIds:_0x46967b}=_0x43d5cd;return!_0x46967b||_0x46967b[_0x3107af(0x193)]===0x0?_0x5a80d:_0x5a80d[_0x3107af(0x1b6)]===_0x3107af(0x18b)&&((_0x3dcc55=_0x5a80d[_0x3107af(0x146)])!=null&&_0x3dcc55['length'])?{..._0x5a80d,'children':_0x5a80d[_0x3107af(0x146)]['map'](_0x237538=>typeof _0x237538[_0x3107af(0x164)]['id']==_0x3107af(0x19a)&&_0x46967b&&_0x46967b['includes'](_0x237538[_0x3107af(0x164)]['id'])?{..._0x237538,'attrs':{..._0x237538[_0x3107af(0x164)],'id':_0x237538[_0x3107af(0x164)]['id']+_0x43d5cd[_0x3107af(0x17e)]}}:_0x237538)}:_0x5a80d;}function Oe(){const _0x1bf817=_0xf02626;return Math[_0x1bf817(0x1a9)]()[_0x1bf817(0x16c)](0x24)['substring'](0x2,0x8);}k[_0xf02626(0x140)]=_0xf02626(0x142);const we={'tag':_0xf02626(0x179),'attrs':{'xmlns':_0xf02626(0x148),'fill':_0xf02626(0x14a),'viewBox':_0xf02626(0x153),'width':_0xf02626(0x12a),'height':'1em'},'children':[{'tag':_0xf02626(0x128),'attrs':{'fill':_0xf02626(0x119),'d':_0xf02626(0x137)}},{'tag':'path','attrs':{'fill':_0xf02626(0x119),'d':'M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','fillRule':'evenodd','clipRule':_0xf02626(0x10f)}}]},W=_0x50463f(function(_0x4e555a,_0x50af5d){const _0x20c472=_0xf02626;return _0x2b29b6(k,Object[_0x20c472(0x1ab)]({},_0x4e555a,{'id':_0x20c472(0x1a6),'ref':_0x50af5d,'icon':we}));});function _0x3d06(){const _0x14053c=['_collabSession','_handleOffline','Present\x20this\x20document','stopFollowing','_collabSessionService','sessionStatus$','defs','live-share.config','You\x27re\x20presenting\x20the\x20document','presenter','symbol','_startPresenting','idle','onStarting','length','_config','unsubscribe','_beIdle','forEach','_stopFollowing','fill','string','mask','defineProperty','stringify','get','getInitialStates','createInstance','sheet','getUnitId','615577PSTsWq','not-following','offline','live-share-icon','OPERATION','trim','random','_startLiveShareCoordinator','assign','LIVESHARE_OPERATION','colorChannel1','univer-size-4','_liveShareService','executeCommand','div','text','add','_status','You\x27re\x20not\x20following\x20the\x20presenter','tag','default','9930OggFyi','reverse','current','getLiveShareCoordinatorSync','PRESENTING','evenodd','event$','onCommandExecuted','UNIVER_SHEET','_handleOnline','_uiPartsService','_unitID','registerSharedOperation','dispose','_handleNewHost','currentColor','subscribe','OFFLINE','_reporters','set','_status$','UNIVER_UNKNOWN','_fetchOperations','74524wcwGef','univer-mb-3\x20univer-w-full\x20univer-text-sm','disposeWithMe','dispose$','getCurrentTypeOfUnit$','16373324bTqYAQ','univer-border-none\x20univer-text-gray-600\x20univer-outline-none','path','tryStartPresenting','1em','from','registerInitialStateReporter','pipe','ONLINE','LIVESHARE_NEW_HOST','params','status$','type','39RhzziQ','init','getConfig','_handleNewChangeSets','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','parse','entries','SAME_OPERATION_SHARE_INTERVAL','_injector','FOLLOWING','button','846610yaNAnk','4034360ORMdVM','displayName','7kOLEdu','UniverIcon','getOwnPropertyDescriptor','LIVESHARE_FETCH_OPERATIONS','send','children','has','http://www.w3.org/2000/svg','shouldShareOperation','none','_handleTerminate','getMemberID','NOT_FOLLOWING','presenting','following','getLiveShareCoordinator','Stop\x20presenting','use','0\x200\x2017\x2017','univerjs-icon\x20univerjs-icon-','pluginName','_commandDisposable','_commandService','end','14048ffhAMu','next','_init','startFollowing','_stopPresenting','then','NEW_CHANGESETS','find','LIVESHARE_TERMINATE','replace','operations','attrs','requireSession','getTypeOfUnitAdded$','override','_startFollowing','Stop\x20following','data','getStatus','toString','stopPresenting','_presenter','includes','onRendered','xlink:href','_configService','getTypeOfUnitDisposed$','_mountLiveShare','Start\x20following','clear','memberID','url(#$1','svg','_univerInstanceService','_entities','4608WzNYdl','complete','idSuffix','4mqiFwe','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','map','_sharedOperations','unitId','IDLE'];_0x3d06=function(){return _0x14053c;};return _0x3d06();}W['displayName']='LiveShareIcon';class L extends _0x5bdbec{constructor(){const _0x2ff16a=_0xf02626;super(...arguments),u(this,_0x2ff16a(0x182),new Set()),u(this,_0x2ff16a(0x11c),new Set());}[_0xf02626(0x116)](_0x35d38d){const _0x4d8fcb=_0xf02626;return this[_0x4d8fcb(0x182)][_0x4d8fcb(0x1b3)](_0x35d38d),_0x5dd282(()=>this['_sharedOperations']['delete'](_0x35d38d));}[_0xf02626(0x12c)](_0x11b68c){const _0x1121d6=_0xf02626;return this['_reporters'][_0x1121d6(0x1b3)](_0x11b68c),_0x5dd282(()=>this[_0x1121d6(0x11c)]['delete'](_0x11b68c));}[_0xf02626(0x149)](_0x204eb8){const _0xee7915=_0xf02626;return this[_0xee7915(0x182)]['has'](_0x204eb8);}[_0xf02626(0x19f)](_0x167c9b){const _0x53156c=_0xf02626;return Array[_0x53156c(0x12b)](this[_0x53156c(0x11c)])['map'](_0x479681=>_0x479681(_0x167c9b));}}var Ne=Object[_0xf02626(0x143)],Y=(_0x5b521b,_0x1bdfd9,_0xad5fcb,_0x17bf4a)=>{const _0x3beed3=_0xf02626;for(var _0x49c3d3=_0x17bf4a>0x1?void 0x0:_0x17bf4a?Ne(_0x1bdfd9,_0xad5fcb):_0x1bdfd9,_0x4a3bae=_0x5b521b[_0x3beed3(0x193)]-0x1,_0x43efd8;_0x4a3bae>=0x0;_0x4a3bae--)(_0x43efd8=_0x5b521b[_0x4a3bae])&&(_0x49c3d3=_0x43efd8(_0x49c3d3)||_0x49c3d3);return _0x49c3d3;},_=(_0x4a9e82,_0x27f1e2)=>(_0x14a2b2,_0x528b69)=>_0x27f1e2(_0x14a2b2,_0x528b69,_0x4a9e82);let S=class extends _0x443063{constructor(_0xc53126,_0x483ead,_0x235aff){const _0x4a8dd8=_0xf02626;super(),u(this,_0x4a8dd8(0x17b),new Map()),(this[_0x4a8dd8(0x17a)]=_0xc53126,this['_injector']=_0x483ead,this[_0x4a8dd8(0x189)]=_0x235aff,this[_0x4a8dd8(0x15b)]());}async[_0xf02626(0x150)](_0x3208e4){const _0x51fb65=_0xf02626;return this[_0x51fb65(0x17b)][_0x51fb65(0x147)](_0x3208e4)||await this[_0x51fb65(0x1aa)](_0x3208e4),this[_0x51fb65(0x17b)][_0x51fb65(0x19e)](_0x3208e4);}[_0xf02626(0x10d)](_0x1939e2){const _0x19b3e0=_0xf02626;var _0x46ce0c;return(_0x46ce0c=this['_entities'][_0x19b3e0(0x19e)](_0x1939e2))!=null?_0x46ce0c:null;}[_0xf02626(0x15b)](){const _0x4d3ace=_0xf02626;this['_univerInstanceService'][_0x4d3ace(0x166)](_0x57e1a6[_0x4d3ace(0x112)])[_0x4d3ace(0x12d)](_0x461f78(this[_0x4d3ace(0x124)]))[_0x4d3ace(0x11a)](async _0xbd6c95=>{const _0x4039dc=_0x4d3ace,_0x561176=_0xbd6c95[_0x4039dc(0x1a2)]();this[_0x4039dc(0x17b)][_0x4039dc(0x147)](_0x561176)||this[_0x4039dc(0x1aa)](_0x561176);}),this[_0x4d3ace(0x17a)][_0x4d3ace(0x173)](_0x57e1a6['UNIVER_SHEET'])[_0x4d3ace(0x12d)](_0x461f78(this['dispose$']))[_0x4d3ace(0x11a)](_0x1ff344=>{const _0x314ae9=_0x4d3ace,_0x5b2922=_0x1ff344[_0x314ae9(0x1a2)](),_0x217dca=this[_0x314ae9(0x17b)][_0x314ae9(0x19e)](_0x5b2922);_0x217dca==null||_0x217dca['dispose']();});}async[_0xf02626(0x1aa)](_0x133e6b){const _0x43a699=_0xf02626,_0x54f095=await this[_0x43a699(0x189)][_0x43a699(0x165)](_0x133e6b),_0xa92cf6=this[_0x43a699(0x13b)][_0x43a699(0x1a0)](N,_0x133e6b,_0x54f095);return _0xa92cf6['init'](),this[_0x43a699(0x17b)]['set'](_0x133e6b,_0xa92cf6),_0xa92cf6;}};S=Y([_(0x0,_0x246214),_(0x1,_0x13dd86(_0x5b65f0)),_(0x2,_0x13dd86(_0x374a90))],S);var c=(_0x14c111=>(_0x14c111[_0xf02626(0x11b)]=_0xf02626(0x1a5),_0x14c111[_0xf02626(0x184)]='idle',_0x14c111[_0xf02626(0x13c)]=_0xf02626(0x14f),_0x14c111['NOT_FOLLOWING']=_0xf02626(0x1a4),_0x14c111[_0xf02626(0x10e)]=_0xf02626(0x14e),_0x14c111))(c||{});const Ce=_0xf02626(0x13a),De=0xc8;let N=class extends _0x443063{constructor(_0x3fa637,_0x3ddbee,_0x58c38e,_0x5192fc,_0x5b802d){const _0x2cc365=_0xf02626;super(),u(this,_0x2cc365(0x11e),new _0x26b77b('idle')),u(this,_0x2cc365(0x131),this[_0x2cc365(0x11e)]['asObservable']()),u(this,_0x2cc365(0x15b),!0x1),u(this,_0x2cc365(0x156),null),u(this,_0x2cc365(0x16e),null),(this[_0x2cc365(0x115)]=_0x3fa637,this[_0x2cc365(0x185)]=_0x3ddbee,this[_0x2cc365(0x172)]=_0x58c38e,this[_0x2cc365(0x1af)]=_0x5192fc,this[_0x2cc365(0x157)]=_0x5b802d);}get[_0xf02626(0x1b4)](){const _0x5820f9=_0xf02626;return this[_0x5820f9(0x11e)]['getValue']();}[_0xf02626(0x117)](){const _0x590d48=_0xf02626;var _0x5baa3b;(_0x5baa3b=this[_0x590d48(0x156)])==null||_0x5baa3b[_0x590d48(0x117)](),this[_0x590d48(0x11e)][_0x590d48(0x15a)](_0x590d48(0x191)),this[_0x590d48(0x11e)][_0x590d48(0x17d)]();}[_0xf02626(0x16b)](){const _0x107eb2=_0xf02626;return this[_0x107eb2(0x1b4)];}[_0xf02626(0x134)](){const _0x3187b9=_0xf02626;this[_0x3187b9(0x15b)]||(this[_0x3187b9(0x15b)]=!0x0,this['_collabSession'][_0x3187b9(0x18a)][_0x3187b9(0x12d)](_0x461f78(this[_0x3187b9(0x124)]))[_0x3187b9(0x11a)](_0xbf4875=>{const _0x44cd72=_0x3187b9;switch(_0xbf4875){case _0x1c448e[_0x44cd72(0x11b)]:this[_0x44cd72(0x186)]();break;case _0x1c448e[_0x44cd72(0x12e)]:this[_0x44cd72(0x113)]();break;}}),this[_0x3187b9(0x185)][_0x3187b9(0x110)]['pipe'](_0x461f78(this['dispose$']))['subscribe'](_0x236c21=>{const _0x583246=_0x3187b9,{eventID:_0x2c7084}=_0x236c21;switch(_0x2c7084){case _0x41b597[_0x583246(0x12f)]:this[_0x583246(0x118)](_0x236c21);break;case _0x41b597['LIVESHARE_OPERATION']:this['_handleOperation'](_0x236c21);break;case _0x41b597[_0x583246(0x161)]:this['_handleTerminate']();break;case _0x41b597[_0x583246(0x15f)]:this[_0x583246(0x136)](_0x236c21);break;}}));}[_0xf02626(0x129)](){const _0x4b6c31=_0xf02626;this[_0x4b6c31(0x185)]['send']({'eventID':_0x41b597['LIVESHARE_REQUEST_HOST'],'data':{'unitID':this[_0x4b6c31(0x115)],'userID':this[_0x4b6c31(0x185)]['getMemberID']()}},this[_0x4b6c31(0x115)]);}[_0xf02626(0x16d)](){const _0x4d942e=_0xf02626;this[_0x4d942e(0x1b4)]===_0x4d942e(0x14e)&&(this[_0x4d942e(0x11e)][_0x4d942e(0x15a)](_0x4d942e(0x191)),this[_0x4d942e(0x185)][_0x4d942e(0x145)]({'eventID':_0x41b597[_0x4d942e(0x161)],'data':{'unitID':this[_0x4d942e(0x115)]}},this[_0x4d942e(0x115)]));}[_0xf02626(0x15c)](){const _0x496c3e=_0xf02626;this[_0x496c3e(0x1b4)]==='not-following'&&(this[_0x496c3e(0x11e)][_0x496c3e(0x15a)](_0x496c3e(0x14f)),this[_0x496c3e(0x168)]());}[_0xf02626(0x188)](){const _0x5e5cea=_0xf02626;this['_status']===_0x5e5cea(0x14f)&&this[_0x5e5cea(0x198)]();}[_0xf02626(0x118)](_0x357d9d){const _0x568dfc=_0xf02626,{presenter:_0x3fa8fb}=_0x357d9d['data'],_0x3ca1e4=this['_collabSession'][_0x568dfc(0x14c)]();this[_0x568dfc(0x16e)]=_0x3fa8fb,_0x3fa8fb===_0x3ca1e4?(this[_0x568dfc(0x198)](),this[_0x568dfc(0x190)]()):this[_0x568dfc(0x1b4)]!==_0x568dfc(0x1a4)&&(this[_0x568dfc(0x15d)](),this[_0x568dfc(0x168)]());}[_0xf02626(0x120)](){const _0x25c34e=_0xf02626,_0x2578f7={'eventID':_0x41b597[_0x25c34e(0x144)]};this['_collabSession']['send'](_0x2578f7,this[_0x25c34e(0x115)]);}[_0xf02626(0x14b)](){const _0x345f75=_0xf02626;this[_0x345f75(0x16e)]=null,this[_0x345f75(0x1b4)]!=='presenting'&&this[_0x345f75(0x196)]();}['_handleNewChangeSets'](_0x46197e){const _0x148a21=_0xf02626;if(this[_0x148a21(0x1b4)]===_0x148a21(0x14f)&&this[_0x148a21(0x16e)]===_0x46197e[_0x148a21(0x16a)][_0x148a21(0x177)]){const _0x5b050f=_0x1061ca(_0x46197e[_0x148a21(0x16a)])['mutations'][_0x148a21(0x1b9)]()[_0x148a21(0x160)](_0x3cf610=>_0x3cf610['id']===_0x2abf81['id']);if(_0x5b050f){const _0x69a22d=_0x5b050f[_0x148a21(0x130)][_0x148a21(0x183)],_0xd951ea=_0x5b050f[_0x148a21(0x130)][_0x148a21(0x1a1)]['id'];setTimeout(()=>{const _0x5b0a20=_0x148a21;this[_0x5b0a20(0x157)][_0x5b0a20(0x1b0)](_0x218042['id'],{'unitId':_0x69a22d,'subUnitId':_0xd951ea},{'fromCollab':!0x0});});}}}[_0xf02626(0x190)](){const _0x3f8a70=_0xf02626;this[_0x3f8a70(0x11e)][_0x3f8a70(0x15a)]('presenting');const _0x373ffc=new Map(),_0x2bd11f=this['_commandDisposable']=new _0xd84b84();_0x2bd11f[_0x3f8a70(0x1b3)](_0x5dd282(()=>{const _0x544f17=_0x3f8a70;_0x373ffc[_0x544f17(0x197)](_0x293094=>_0x293094[_0x544f17(0x17d)]()),_0x373ffc[_0x544f17(0x176)]();})),_0x2bd11f[_0x3f8a70(0x1b3)](this['_commandService'][_0x3f8a70(0x111)](_0x2ca7a7=>{const _0xde89c=_0x3f8a70;var _0x1d950c;if(_0x2ca7a7[_0xde89c(0x132)]!==_0x13511b[_0xde89c(0x1a7)]||!this[_0xde89c(0x1af)][_0xde89c(0x149)](_0x2ca7a7['id']))return;const {id:_0x872d9c}=_0x2ca7a7;let _0x3f240f;_0x373ffc[_0xde89c(0x147)](_0x872d9c)?_0x3f240f=_0x373ffc[_0xde89c(0x19e)](_0x872d9c):(_0x3f240f=new _0x5a754c(),_0x373ffc[_0xde89c(0x11d)](_0x872d9c,_0x3f240f),_0x3f240f[_0xde89c(0x12d)](_0x471303((_0x1d950c=this[_0xde89c(0x172)][_0xde89c(0x135)](Ce))!=null?_0x1d950c:De,void 0x0,{'trailing':!0x0,'leading':!0x0}))[_0xde89c(0x11a)](_0x19d28c=>{const _0x4e2489=_0xde89c;this[_0x4e2489(0x185)][_0x4e2489(0x145)]({'eventID':_0x41b597[_0x4e2489(0x1ac)],'data':{'unitID':this[_0x4e2489(0x115)],'operations':{[_0x19d28c['id']]:{'id':_0x19d28c['id'],'params':JSON['stringify'](_0x19d28c['params'])}}}},this[_0x4e2489(0x115)]);})),_0x3f240f['next'](_0x2ca7a7);})),this['_liveShareService']['getInitialStates'](this[_0x3f8a70(0x115)])['forEach'](_0x507eca=>this[_0x3f8a70(0x185)][_0x3f8a70(0x145)]({'eventID':_0x41b597['LIVESHARE_OPERATION'],'data':{'unitID':this[_0x3f8a70(0x115)],'operations':{[_0x507eca['id']]:{'id':_0x507eca['id'],'params':JSON[_0x3f8a70(0x19d)](_0x507eca[_0x3f8a70(0x130)])}}}},this['_unitID']));}[_0xf02626(0x15d)](){const _0x3bdc00=_0xf02626;var _0x353052;this[_0x3bdc00(0x11e)][_0x3bdc00(0x15a)](_0x3bdc00(0x191)),(_0x353052=this['_commandDisposable'])==null||_0x353052['dispose'](),this[_0x3bdc00(0x156)]=null;}[_0xf02626(0x168)](){const _0x50423e=_0xf02626;var _0x22875c;(_0x22875c=this[_0x50423e(0x156)])==null||_0x22875c[_0x50423e(0x117)](),this[_0x50423e(0x11e)][_0x50423e(0x15a)](_0x50423e(0x14f));}['_beIdle'](){const _0x2326f7=_0xf02626;var _0x4d3b8f;this[_0x2326f7(0x11e)][_0x2326f7(0x15a)](_0x2326f7(0x191)),(_0x4d3b8f=this[_0x2326f7(0x156)])==null||_0x4d3b8f[_0x2326f7(0x117)](),this[_0x2326f7(0x156)]=null;}[_0xf02626(0x198)](){const _0x5471e2=_0xf02626;var _0x43265e;this[_0x5471e2(0x11e)]['next'](_0x5471e2(0x1a4)),(_0x43265e=this[_0x5471e2(0x156)])==null||_0x43265e[_0x5471e2(0x117)]();}['_handleOperation'](_0x224d63){const _0x5a8190=_0xf02626;if([_0x5a8190(0x14e),'not-following','offline'][_0x5a8190(0x16f)](this[_0x5a8190(0x1b4)])||!_0x224d63[_0x5a8190(0x16a)][_0x5a8190(0x18e)]||_0x224d63[_0x5a8190(0x16a)]['presenter']===this[_0x5a8190(0x185)][_0x5a8190(0x14c)]())return;this['_status']===_0x5a8190(0x191)&&this[_0x5a8190(0x168)]();const _0x5ed6e6=_0x224d63[_0x5a8190(0x16a)][_0x5a8190(0x163)];Object['values'](_0x5ed6e6)[_0x5a8190(0x197)](_0x31cd1e=>{const _0x57204c=_0x5a8190;this[_0x57204c(0x157)][_0x57204c(0x1b0)](_0x31cd1e['id'],_0x31cd1e[_0x57204c(0x130)]?JSON[_0x57204c(0x138)](_0x31cd1e[_0x57204c(0x130)]):null,{'fromCollab':!0x0});});}[_0xf02626(0x186)](){const _0x3520bb=_0xf02626;var _0x14ca7b;this[_0x3520bb(0x11e)][_0x3520bb(0x15a)](_0x3520bb(0x1a5)),(_0x14ca7b=this['_commandDisposable'])==null||_0x14ca7b['dispose']();}[_0xf02626(0x113)](){const _0x59b3d2=_0xf02626;this[_0x59b3d2(0x11e)][_0x59b3d2(0x15a)]('idle'),this[_0x59b3d2(0x120)]();}};N=Y([_(0x2,_0x5c1fc8),_(0x3,_0x13dd86(L)),_(0x4,_0x1549da)],N);function Le(){const _0x1f2369=_0xf02626,_0x569ebc=_0x4e3e8c(S),_0x5ee06f=_0x4e3e8c(_0x246214),_0x420c04=_0x262950(()=>_0x5ee06f[_0x1f2369(0x125)](_0x57e1a6[_0x1f2369(0x112)]),void 0x0,!0x1,[]),[_0x2eabc6,_0x5c84c4]=_0x430a47(null),[_0x238d1c,_0x224e16]=_0x430a47(c['IDLE']),_0x582f08=_0x922483(null);return _0x4a4b6f(()=>(_0x420c04&&_0x569ebc[_0x1f2369(0x150)](_0x420c04[_0x1f2369(0x1a2)]())[_0x1f2369(0x15e)](_0x35b1a7=>{const _0x18398d=_0x1f2369;_0x5c84c4(_0x35b1a7),_0x582f08[_0x18398d(0x1ba)]=_0x35b1a7[_0x18398d(0x131)]['subscribe'](_0x59d285=>{_0x224e16(_0x59d285);});}),()=>{const _0x1c2cf3=_0x1f2369;var _0x291bd3;(_0x291bd3=_0x582f08['current'])==null||_0x291bd3[_0x1c2cf3(0x195)](),_0x582f08[_0x1c2cf3(0x1ba)]=null;}),[_0x420c04,_0x569ebc]),_0x2eabc6?_0x3f1572(_0x49c23a,{'align':_0x1f2369(0x158),'disabled':_0x238d1c===c[_0x1f2369(0x11b)],'className':_0x1f2369(0x180),'overlay':_0x3f1572(Re,{'status':_0x238d1c,'coordinator':_0x2eabc6}),'children':_0x3f1572(_0x1f2369(0x13d),{'className':_0x37a6a0(_0x1f2369(0x127),{'univer-cursor-not-allowed':_0x238d1c===c[_0x1f2369(0x11b)],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x238d1c!==c[_0x1f2369(0x11b)]}),'type':_0x1f2369(0x13d),'children':_0x3f1572(W,{'className':_0x1f2369(0x1ae)})})}):null;}function Re(_0x25b16b){const _0x2954de=_0xf02626,{status:_0x12e09e,coordinator:_0x3cfffd}=_0x25b16b;switch(_0x12e09e){case c[_0x2954de(0x184)]:return _0x3f1572($e,{'coordinator':_0x3cfffd});case c['FOLLOWING']:return _0x3f1572(xe,{'coordinator':_0x3cfffd});case c[_0x2954de(0x14d)]:return _0x3f1572(Pe,{'coordinator':_0x3cfffd});case c['OFFLINE']:return _0x3f1572(Te,{});case c['PRESENTING']:return _0x3f1572(Ae,{'coordinator':_0x3cfffd});default:return null;}}function $e(_0x28b641){const _0x17d842=_0xf02626,{coordinator:_0x3ef61c}=_0x28b641;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572('div',{'className':_0x17d842(0x122),'children':_0x17d842(0x187)}),_0x3f1572(_0x1555cd,{'onClick':()=>_0x3ef61c['tryStartPresenting'](),'children':'Start'})]});}function xe(_0x1db4e6){const _0x9aeece=_0xf02626,{coordinator:_0x21561b}=_0x1db4e6;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572(_0x9aeece(0x1b1),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':'You\x27re\x20following\x20the\x20presenter'}),_0x3f1572(_0x1555cd,{'onClick':()=>_0x21561b[_0x9aeece(0x188)](),'children':_0x9aeece(0x169)})]});}function Pe(_0x644145){const _0x49b868=_0xf02626,{coordinator:_0x5d21a9}=_0x644145;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572(_0x49b868(0x1b1),{'className':_0x49b868(0x122),'children':_0x49b868(0x1b5)}),_0x3f1572(_0x1555cd,{'variant':_0x49b868(0x1b2),'onClick':()=>_0x5d21a9[_0x49b868(0x15c)](),'children':_0x49b868(0x175)})]});}function Ae(_0x4eda88){const _0x7481f5=_0xf02626,{coordinator:_0x574693}=_0x4eda88;return _0x10f9f1(_0x561b68,{'children':[_0x3f1572(_0x7481f5(0x1b1),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x7481f5(0x18d)}),_0x3f1572(_0x1555cd,{'variant':_0x7481f5(0x1b7),'onClick':()=>_0x574693[_0x7481f5(0x16d)](),'children':_0x7481f5(0x151)})]});}function Te(){return _0x3f1572(_0x561b68,{'children':'You\x27are\x20offline.'});}var Fe=Object[_0xf02626(0x143)],He=(_0x96b58c,_0x144ee2,_0x507d0b,_0x222271)=>{const _0xefecaf=_0xf02626;for(var _0x13fcad=_0x222271>0x1?void 0x0:_0x222271?Fe(_0x144ee2,_0x507d0b):_0x144ee2,_0x42d52c=_0x96b58c[_0xefecaf(0x193)]-0x1,_0x5f0019;_0x42d52c>=0x0;_0x42d52c--)(_0x5f0019=_0x96b58c[_0x42d52c])&&(_0x13fcad=_0x5f0019(_0x13fcad)||_0x13fcad);return _0x13fcad;},A=(_0x5642f2,_0x3d613d)=>(_0x31fffb,_0x4e944a)=>_0x3d613d(_0x31fffb,_0x4e944a,_0x5642f2);let m=class extends _0x5bdbec{constructor(_0x38c48e,_0xcedf1f){const _0x3f32ff=_0xf02626;super(),this[_0x3f32ff(0x13b)]=_0x38c48e,this[_0x3f32ff(0x114)]=_0xcedf1f,this[_0x3f32ff(0x174)]();}[_0xf02626(0x174)](){const _0x55dd1f=_0xf02626;this[_0x55dd1f(0x123)](this[_0x55dd1f(0x114)]['registerComponent'](_0x50c32d['HEADER_MENU'],()=>_0x11eeaf(Le,this[_0x55dd1f(0x13b)])));}};m=He([A(0x0,_0x13dd86(_0x5b65f0)),A(0x1,_0x28a6d1)],m);const ye=_0xf02626(0x18c),T={};var Ue=Object['getOwnPropertyDescriptor'],Ve=(_0x535922,_0x1e5212,_0x4e0c0d,_0x470e7d)=>{const _0x607782=_0xf02626;for(var _0x2f847e=_0x470e7d>0x1?void 0x0:_0x470e7d?Ue(_0x1e5212,_0x4e0c0d):_0x1e5212,_0x3a3d52=_0x535922[_0x607782(0x193)]-0x1,_0x4f8e2f;_0x3a3d52>=0x0;_0x3a3d52--)(_0x4f8e2f=_0x535922[_0x3a3d52])&&(_0x2f847e=_0x4f8e2f(_0x2f847e)||_0x2f847e);return _0x2f847e;},je=(_0x1004d2,_0x4c201b)=>(_0x376686,_0x2034c4)=>_0x4c201b(_0x376686,_0x2034c4,_0x1004d2);let I=class extends _0x5bdbec{constructor(_0x851793){const _0x3619bd=_0xf02626;super(),this[_0x3619bd(0x1af)]=_0x851793,this['_init']();}[_0xf02626(0x15b)](){[_0x5b6fb4['id'],_0x54eb58['id'],_0x218042['id']]['forEach'](_0x1c96f7=>{const _0x47a757=_0x49a3;this[_0x47a757(0x123)](this[_0x47a757(0x1af)][_0x47a757(0x116)](_0x1c96f7));});}};I=Ve([je(0x0,_0x13dd86(L))],I);var Me=Object[_0xf02626(0x19c)],ke=Object[_0xf02626(0x143)],Ge=(_0x48fbcc,_0x131495,_0x50e9bb)=>_0x131495 in _0x48fbcc?Me(_0x48fbcc,_0x131495,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x50e9bb}):_0x48fbcc[_0x131495]=_0x50e9bb,We=(_0x5e6c7c,_0x3fd39f,_0x5f3d48,_0x38183a)=>{const _0x170050=_0xf02626;for(var _0x2f772b=_0x38183a>0x1?void 0x0:_0x38183a?ke(_0x3fd39f,_0x5f3d48):_0x3fd39f,_0x1e7745=_0x5e6c7c[_0x170050(0x193)]-0x1,_0x293523;_0x1e7745>=0x0;_0x1e7745--)(_0x293523=_0x5e6c7c[_0x1e7745])&&(_0x2f772b=_0x293523(_0x2f772b)||_0x2f772b);return _0x2f772b;},F=(_0x218a51,_0x1a8e03)=>(_0x22d847,_0x242c8a)=>_0x1a8e03(_0x22d847,_0x242c8a,_0x218a51),B=(_0x181145,_0x5f28e6,_0x38ec45)=>Ge(_0x181145,typeof _0x5f28e6!=_0xf02626(0x18f)?_0x5f28e6+'':_0x5f28e6,_0x38ec45);function _0x49a3(_0x311e8d,_0x1d2c9f){_0x311e8d=_0x311e8d-0x10d;const _0x3d0625=_0x3d06();let _0x49a302=_0x3d0625[_0x311e8d];return _0x49a302;}const Ye='UNIVER_LIVE_SHARE_PLUGIN';let b=class extends _0x586d52{constructor(_0x9e3f14=T,_0x24bc5f,_0x349d0d){const _0x5d3475=_0xf02626;super(),this[_0x5d3475(0x194)]=_0x9e3f14,this[_0x5d3475(0x13b)]=_0x24bc5f,this[_0x5d3475(0x172)]=_0x349d0d;const {..._0x205667}=_0x12b34e({},T,this[_0x5d3475(0x194)]);this[_0x5d3475(0x172)]['setConfig'](ye,_0x205667);}[_0xf02626(0x192)](){const _0x417a59=_0xf02626;_0x2186bd(this[_0x417a59(0x13b)],_0x29be9b([[L],[S],[I],[m]],this[_0x417a59(0x194)][_0x417a59(0x167)])),_0x31d787(this['_injector'],[[I]]);}[_0xf02626(0x170)](){const _0x2f8e46=_0xf02626;_0x31d787(this[_0x2f8e46(0x13b)],[[m]]);}};B(b,_0xf02626(0x132),_0x57e1a6[_0xf02626(0x11f)]),B(b,_0xf02626(0x155),Ye),b=We([_0x3a182e(_0x400e7c),F(0x1,_0x13dd86(_0x5b65f0)),F(0x2,_0x5c1fc8)],b);export{m as DesktopLiveShareController,Le as LiveShare,S as LiveShareController,N as LiveShareCoordinator,L as LiveShareService,c as LiveShareStatus,b as UniverLiveSharePlugin};
|
|
1
|
+
const _0x5a9157=_0x4e14;(function(_0x56d1de,_0x1be11f){const _0x3232cd=_0x4e14,_0x1af3f2=_0x56d1de();while(!![]){try{const _0x19c600=parseInt(_0x3232cd(0x191))/0x1+-parseInt(_0x3232cd(0x166))/0x2+parseInt(_0x3232cd(0x130))/0x3+parseInt(_0x3232cd(0x1a9))/0x4+parseInt(_0x3232cd(0x14d))/0x5+parseInt(_0x3232cd(0x161))/0x6+-parseInt(_0x3232cd(0x16b))/0x7;if(_0x19c600===_0x1be11f)break;else _0x1af3f2['push'](_0x1af3f2['shift']());}catch(_0x56f5ba){_0x1af3f2['push'](_0x1af3f2['shift']());}}}(_0x54c7,0xb3ce5));function _0x4e14(_0x50138c,_0x45307e){_0x50138c=_0x50138c-0x115;const _0x54c7ce=_0x54c7();let _0x4e14ac=_0x54c7ce[_0x50138c];return _0x4e14ac;}var J=Object[_0x5a9157(0x136)],K=(_0x4672aa,_0x1de778,_0x12c834)=>_0x1de778 in _0x4672aa?J(_0x4672aa,_0x1de778,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x12c834}):_0x4672aa[_0x1de778]=_0x12c834,u=(_0x3616d7,_0x5d1470,_0x5456b0)=>K(_0x3616d7,typeof _0x5d1470!=_0x5a9157(0x194)?_0x5d1470+'':_0x5d1470,_0x5456b0);import{Disposable as _0xa28d62,toDisposable as _0x3e6459,IUniverInstanceService as _0x2bf8ed,Inject as _0x5890f3,Injector as _0x2ac967,IConfigService as _0x2ccd3e,ICommandService as _0x8f3e9,RxDisposable as _0x1cce5c,UniverInstanceType as _0x118916,DisposableCollection as _0x5315c9,CommandType as _0x55dc24,DependentOn as _0x2c9f12,Plugin as _0x446406,merge as _0x230b34,registerDependencies as _0x3ca90e,mergeOverrideWithDependencies as _0x1d22c6,touchDependencies as _0xa89abb}from'@univerjs/core';import{useDependency as _0x14fb74,useObservable as _0x25b804,IUIPartsService as _0x4b3e7b,BuiltInUIPart as _0x3df1ce,connectInjector as _0x360939}from'@univerjs/ui';import{jsx as _0xe9d27a,jsxs as _0x1044b3,Fragment as _0x21e76d}from'react/jsx-runtime';import{Dropdown as _0x1d5dcc,clsx as _0x26827b,Button as _0x43cbc8}from'@univerjs/design';import{useRef as _0x3a8f3b,createElement as _0x445d41,forwardRef as _0x3a591f,useState as _0x5ab416,useEffect as _0x34456e}from'react';import{CollaborationEvent as _0xb6d82,parseProtocolChangeset as _0x448a4b}from'@univerjs-pro/collaboration';import{CollaborationSessionService as _0x270da6,SessionStatus as _0x1f086f,UniverCollaborationClientPlugin as _0x270228}from'@univerjs-pro/collaboration-client';import{InsertSheetMutation as _0x1a8b78,SetWorksheetActiveOperation as _0x4ff82e}from'@univerjs/sheets';import{BehaviorSubject as _0x4812e4,Subject as _0x4797b2}from'rxjs';import{takeUntil as _0x5bc01a,throttleTime as _0x1e0766}from'rxjs/operators';import{SetZoomRatioOperation as _0x1f21c4,SetScrollOperation as _0x447fe5}from'@univerjs/sheets-ui';function k({ref:_0x4aafb6,..._0x34a9d5}){const _0x2fa30d=_0x5a9157,{icon:_0x10eab9,id:_0x3dc31d,className:_0x26f72d,extend:_0x195ada,..._0x1ea6ed}=_0x34a9d5,_0x264f64=(_0x2fa30d(0x11f)+_0x3dc31d+'\x20'+(_0x26f72d||''))[_0x2fa30d(0x13b)](),_0x543818=_0x3a8f3b('_'+Oe());return G(_0x10eab9,''+_0x3dc31d,{'defIds':_0x10eab9[_0x2fa30d(0x190)],'idSuffix':_0x543818[_0x2fa30d(0x17b)]},{'ref':_0x4aafb6,'className':_0x264f64,..._0x1ea6ed},_0x195ada);}function G(_0x5223e4,_0x4d5a88,_0xc614ca,_0x7e6615,_0x2c9f7e){const _0x47cd5e=_0x5a9157;return _0x445d41(_0x5223e4['tag'],{'key':_0x4d5a88,...be(_0x5223e4,_0xc614ca,_0x2c9f7e),..._0x7e6615},(Ee(_0x5223e4,_0xc614ca)[_0x47cd5e(0x125)]||[])[_0x47cd5e(0x11c)]((_0x409539,_0x18da96)=>G(_0x409539,_0x4d5a88+'-'+_0x5223e4[_0x47cd5e(0x12c)]+'-'+_0x18da96,_0xc614ca,void 0x0,_0x2c9f7e)));}function be(_0x27d574,_0x3a9068,_0x50d3bf){const _0x4524b0=_0x5a9157,_0x387e5f={..._0x27d574[_0x4524b0(0x184)]};_0x50d3bf!=null&&_0x50d3bf[_0x4524b0(0x152)]&&_0x387e5f['fill']===_0x4524b0(0x152)&&(_0x387e5f['fill']=_0x50d3bf[_0x4524b0(0x152)]),_0x27d574[_0x4524b0(0x12c)]===_0x4524b0(0x1b5)&&_0x387e5f['id']&&(_0x387e5f['id']=_0x387e5f['id']+_0x3a9068[_0x4524b0(0x175)]),Object['entries'](_0x387e5f)[_0x4524b0(0x183)](([_0xbb34fb,_0x214116])=>{const _0x424387=_0x4524b0;_0xbb34fb==='mask'&&typeof _0x214116==_0x424387(0x18b)&&(_0x387e5f[_0xbb34fb]=_0x214116['replace'](/url\(#(.*)\)/,_0x424387(0x18f)+_0x3a9068[_0x424387(0x175)]+')'));});const {defIds:_0x43c136}=_0x3a9068;return!_0x43c136||_0x43c136[_0x4524b0(0x18d)]===0x0||(_0x27d574['tag']==='use'&&_0x387e5f['xlink:href']&&(_0x387e5f[_0x4524b0(0x199)]=_0x387e5f[_0x4524b0(0x199)]+_0x3a9068[_0x4524b0(0x175)]),Object[_0x4524b0(0x121)](_0x387e5f)['forEach'](([_0x4e4ed0,_0xa2838b])=>{const _0x3d9828=_0x4524b0;typeof _0xa2838b==_0x3d9828(0x18b)&&(_0x387e5f[_0x4e4ed0]=_0xa2838b['replace'](/url\(#(.*)\)/,'url(#$1'+_0x3a9068[_0x3d9828(0x175)]+')'));})),_0x387e5f;}function Ee(_0x2db2ec,_0x222fe7){const _0x53553e=_0x5a9157;var _0x210d98;const {defIds:_0x39dcfb}=_0x222fe7;return!_0x39dcfb||_0x39dcfb['length']===0x0?_0x2db2ec:_0x2db2ec[_0x53553e(0x12c)]==='defs'&&((_0x210d98=_0x2db2ec['children'])!=null&&_0x210d98[_0x53553e(0x18d)])?{..._0x2db2ec,'children':_0x2db2ec[_0x53553e(0x125)][_0x53553e(0x11c)](_0x424c08=>typeof _0x424c08[_0x53553e(0x184)]['id']==_0x53553e(0x18b)&&_0x39dcfb&&_0x39dcfb['includes'](_0x424c08[_0x53553e(0x184)]['id'])?{..._0x424c08,'attrs':{..._0x424c08['attrs'],'id':_0x424c08['attrs']['id']+_0x222fe7[_0x53553e(0x175)]}}:_0x424c08)}:_0x2db2ec;}function Oe(){const _0x675a0b=_0x5a9157;return Math['random']()[_0x675a0b(0x1a6)](0x24)['substring'](0x2,0x8);}k[_0x5a9157(0x18a)]='UniverIcon';const we={'tag':_0x5a9157(0x187),'attrs':{'xmlns':'http://www.w3.org/2000/svg','fill':_0x5a9157(0x145),'viewBox':_0x5a9157(0x173),'width':_0x5a9157(0x1b3),'height':'1em'},'children':[{'tag':'path','attrs':{'fill':_0x5a9157(0x132),'d':_0x5a9157(0x159)}},{'tag':_0x5a9157(0x12d),'attrs':{'fill':_0x5a9157(0x132),'d':_0x5a9157(0x17c),'fillRule':_0x5a9157(0x1ae),'clipRule':_0x5a9157(0x1ae)}}]},W=_0x3a591f(function(_0x9266ec,_0x26acce){const _0x563837=_0x5a9157;return _0x445d41(k,Object['assign']({},_0x9266ec,{'id':_0x563837(0x1a2),'ref':_0x26acce,'icon':we}));});W[_0x5a9157(0x18a)]=_0x5a9157(0x188);class L extends _0xa28d62{constructor(){const _0x1c1033=_0x5a9157;super(...arguments),u(this,_0x1c1033(0x189),new Set()),u(this,'_reporters',new Set());}[_0x5a9157(0x19f)](_0x3a6d42){const _0x1a8668=_0x5a9157;return this[_0x1a8668(0x189)][_0x1a8668(0x16e)](_0x3a6d42),_0x3e6459(()=>this[_0x1a8668(0x189)][_0x1a8668(0x12e)](_0x3a6d42));}['registerInitialStateReporter'](_0x14f19b){const _0x430a19=_0x5a9157;return this[_0x430a19(0x157)][_0x430a19(0x16e)](_0x14f19b),_0x3e6459(()=>this['_reporters'][_0x430a19(0x12e)](_0x14f19b));}[_0x5a9157(0x168)](_0x16d14b){const _0x28ffee=_0x5a9157;return this[_0x28ffee(0x189)]['has'](_0x16d14b);}[_0x5a9157(0x13c)](_0x4b9d74){const _0x4b079f=_0x5a9157;return Array[_0x4b079f(0x16a)](this[_0x4b079f(0x157)])[_0x4b079f(0x11c)](_0x65bfbd=>_0x65bfbd(_0x4b9d74));}}var Ne=Object[_0x5a9157(0x162)],Y=(_0x37b0e3,_0x5a90ae,_0x3eae1e,_0x3c7894)=>{const _0x1411cf=_0x5a9157;for(var _0x43b1a6=_0x3c7894>0x1?void 0x0:_0x3c7894?Ne(_0x5a90ae,_0x3eae1e):_0x5a90ae,_0x29854b=_0x37b0e3[_0x1411cf(0x18d)]-0x1,_0x4e45ce;_0x29854b>=0x0;_0x29854b--)(_0x4e45ce=_0x37b0e3[_0x29854b])&&(_0x43b1a6=_0x4e45ce(_0x43b1a6)||_0x43b1a6);return _0x43b1a6;},_=(_0xa33a29,_0x53098a)=>(_0x3f79a9,_0x36dda4)=>_0x53098a(_0x3f79a9,_0x36dda4,_0xa33a29);function _0x54c7(){const _0x39b7d5=['attrs','unsubscribe','_handleNewHost','svg','LiveShareIcon','_sharedOperations','displayName','string','setConfig','length','stopFollowing','url(#$1','defIds','217525LzCWYs','disposeWithMe','tryStartPresenting','symbol','PRESENTING','find','Present\x20this\x20document','onRendered','xlink:href','dispose$','getConfig','ONLINE','_handleOffline','has','registerSharedOperation','_handleOperation','stringify','live-share-icon','getLiveShareCoordinatorSync','_collabSession','UNIVER_UNKNOWN','toString','getMemberID','getCurrentTypeOfUnit$','467616fUPsvU','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','_uiPartsService','_univerInstanceService','pluginName','evenodd','_commandDisposable','sheet','_fetchOperations','registerComponent','1em','NEW_CHANGESETS','mask','status$','_mountLiveShare','_startPresenting','end','override','_startLiveShareCoordinator','asObservable','startFollowing','getValue','send','map','getTypeOfUnitAdded$','_beIdle','univerjs-icon\x20univerjs-icon-','not-following','entries','univer-size-4','You\x27are\x20offline.','get','children','Start\x20following','complete','values','You\x27re\x20not\x20following\x20the\x20presenter','IDLE','createInstance','tag','path','delete','_init','3653502BOwAta','getUnitId','currentColor','_collabSessionService','Stop\x20presenting','_stopFollowing','defineProperty','unitId','Start','_injector','_stopPresenting','trim','getInitialStates','button','params','_commandService','You\x27re\x20following\x20the\x20presenter','_entities','reverse','UNIVER_SHEET','_handleOnline','none','executeCommand','_liveShareService','LIVESHARE_OPERATION','_handleTerminate','FOLLOWING','_status$','getLiveShareCoordinator','1846640ldcwVj','_config','requireSession','OFFLINE','_configService','colorChannel1','default','subscribe','You\x27re\x20presenting\x20the\x20document','_unitID','_reporters','LIVESHARE_TERMINATE','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','then','dispose','OPERATION','memberID','next','idle','getStatus','3389754vyajxw','getOwnPropertyDescriptor','_startFollowing','following','LIVESHARE_FETCH_OPERATIONS','1052856QySCGt','getTypeOfUnitDisposed$','shouldShareOperation','data','from','8565459AAFyas','mutations','set','add','clear','stopPresenting','HEADER_MENU','text','0\x200\x2017\x2017','presenting','idSuffix','LIVESHARE_REQUEST_HOST','Stop\x20following','NOT_FOLLOWING','_presenter','univer-mb-3\x20univer-w-full\x20univer-text-sm','current','M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','UNIVER_LIVE_SHARE_PLUGIN','pipe','offline','init','_handleNewChangeSets','_status','forEach'];_0x54c7=function(){return _0x39b7d5;};return _0x54c7();}let S=class extends _0x1cce5c{constructor(_0x315b6e,_0x304d1b,_0x3ba4b9){const _0x501fca=_0x5a9157;super(),u(this,_0x501fca(0x141),new Map()),(this['_univerInstanceService']=_0x315b6e,this[_0x501fca(0x139)]=_0x304d1b,this[_0x501fca(0x133)]=_0x3ba4b9,this['_init']());}async[_0x5a9157(0x14c)](_0x5b02c6){const _0x7784dc=_0x5a9157;return this['_entities']['has'](_0x5b02c6)||await this['_startLiveShareCoordinator'](_0x5b02c6),this[_0x7784dc(0x141)][_0x7784dc(0x124)](_0x5b02c6);}[_0x5a9157(0x1a3)](_0x268da4){const _0x426ceb=_0x5a9157;var _0xcfdf9d;return(_0xcfdf9d=this['_entities'][_0x426ceb(0x124)](_0x268da4))!=null?_0xcfdf9d:null;}['_init'](){const _0x55a05c=_0x5a9157;this['_univerInstanceService'][_0x55a05c(0x11d)](_0x118916[_0x55a05c(0x143)])[_0x55a05c(0x17e)](_0x5bc01a(this['dispose$']))[_0x55a05c(0x154)](async _0x57c2a7=>{const _0x2622f1=_0x55a05c,_0x3e6ddc=_0x57c2a7[_0x2622f1(0x131)]();this['_entities'][_0x2622f1(0x19e)](_0x3e6ddc)||this[_0x2622f1(0x117)](_0x3e6ddc);}),this[_0x55a05c(0x1ac)][_0x55a05c(0x167)](_0x118916[_0x55a05c(0x143)])['pipe'](_0x5bc01a(this[_0x55a05c(0x19a)]))[_0x55a05c(0x154)](_0x331c33=>{const _0x9104fd=_0x55a05c,_0x287175=_0x331c33['getUnitId'](),_0x48eb15=this[_0x9104fd(0x141)][_0x9104fd(0x124)](_0x287175);_0x48eb15==null||_0x48eb15['dispose']();});}async[_0x5a9157(0x117)](_0x274525){const _0x4c5ae2=_0x5a9157,_0x13c343=await this['_collabSessionService'][_0x4c5ae2(0x14f)](_0x274525),_0x5dcc38=this[_0x4c5ae2(0x139)][_0x4c5ae2(0x12b)](N,_0x274525,_0x13c343);return _0x5dcc38[_0x4c5ae2(0x180)](),this['_entities'][_0x4c5ae2(0x16d)](_0x274525,_0x5dcc38),_0x5dcc38;}};S=Y([_(0x0,_0x2bf8ed),_(0x1,_0x5890f3(_0x2ac967)),_(0x2,_0x5890f3(_0x270da6))],S);var c=(_0x3dd772=>(_0x3dd772[_0x5a9157(0x150)]=_0x5a9157(0x17f),_0x3dd772[_0x5a9157(0x12a)]=_0x5a9157(0x15f),_0x3dd772['FOLLOWING']=_0x5a9157(0x164),_0x3dd772[_0x5a9157(0x178)]=_0x5a9157(0x120),_0x3dd772['PRESENTING']=_0x5a9157(0x174),_0x3dd772))(c||{});const Ce='SAME_OPERATION_SHARE_INTERVAL',De=0xc8;let N=class extends _0x1cce5c{constructor(_0xb205f3,_0x145752,_0x10357b,_0x3da1b7,_0x3c2a71){const _0x11a0a2=_0x5a9157;super(),u(this,'_status$',new _0x4812e4(_0x11a0a2(0x15f))),u(this,_0x11a0a2(0x1b6),this[_0x11a0a2(0x14b)][_0x11a0a2(0x118)]()),u(this,_0x11a0a2(0x12f),!0x1),u(this,'_commandDisposable',null),u(this,_0x11a0a2(0x179),null),(this[_0x11a0a2(0x156)]=_0xb205f3,this[_0x11a0a2(0x1a4)]=_0x145752,this['_configService']=_0x10357b,this['_liveShareService']=_0x3da1b7,this[_0x11a0a2(0x13f)]=_0x3c2a71);}get[_0x5a9157(0x182)](){const _0x590aa9=_0x5a9157;return this['_status$'][_0x590aa9(0x11a)]();}[_0x5a9157(0x15b)](){const _0x1b17eb=_0x5a9157;var _0x419afe;(_0x419afe=this['_commandDisposable'])==null||_0x419afe[_0x1b17eb(0x15b)](),this['_status$'][_0x1b17eb(0x15e)](_0x1b17eb(0x15f)),this[_0x1b17eb(0x14b)][_0x1b17eb(0x127)]();}[_0x5a9157(0x160)](){const _0x2a4fc6=_0x5a9157;return this[_0x2a4fc6(0x182)];}[_0x5a9157(0x180)](){const _0x24d726=_0x5a9157;this[_0x24d726(0x12f)]||(this[_0x24d726(0x12f)]=!0x0,this['_collabSession']['sessionStatus$'][_0x24d726(0x17e)](_0x5bc01a(this[_0x24d726(0x19a)]))['subscribe'](_0x516d76=>{const _0x5bc4aa=_0x24d726;switch(_0x516d76){case _0x1f086f[_0x5bc4aa(0x150)]:this[_0x5bc4aa(0x19d)]();break;case _0x1f086f[_0x5bc4aa(0x19c)]:this[_0x5bc4aa(0x144)]();break;}}),this['_collabSession']['event$']['pipe'](_0x5bc01a(this['dispose$']))[_0x24d726(0x154)](_0x3abf42=>{const _0x35f5a9=_0x24d726,{eventID:_0x155f0d}=_0x3abf42;switch(_0x155f0d){case _0xb6d82['LIVESHARE_NEW_HOST']:this[_0x35f5a9(0x186)](_0x3abf42);break;case _0xb6d82[_0x35f5a9(0x148)]:this[_0x35f5a9(0x1a0)](_0x3abf42);break;case _0xb6d82[_0x35f5a9(0x158)]:this[_0x35f5a9(0x149)]();break;case _0xb6d82[_0x35f5a9(0x1b4)]:this[_0x35f5a9(0x181)](_0x3abf42);break;}}));}['tryStartPresenting'](){const _0x4c0715=_0x5a9157;this['_collabSession'][_0x4c0715(0x11b)]({'eventID':_0xb6d82[_0x4c0715(0x176)],'data':{'unitID':this['_unitID'],'userID':this[_0x4c0715(0x1a4)][_0x4c0715(0x1a7)]()}},this[_0x4c0715(0x156)]);}[_0x5a9157(0x170)](){const _0x350fc6=_0x5a9157;this[_0x350fc6(0x182)]==='presenting'&&(this[_0x350fc6(0x14b)]['next'](_0x350fc6(0x15f)),this[_0x350fc6(0x1a4)][_0x350fc6(0x11b)]({'eventID':_0xb6d82[_0x350fc6(0x158)],'data':{'unitID':this[_0x350fc6(0x156)]}},this[_0x350fc6(0x156)]));}['startFollowing'](){const _0x98e65=_0x5a9157;this[_0x98e65(0x182)]===_0x98e65(0x120)&&(this['_status$'][_0x98e65(0x15e)](_0x98e65(0x164)),this[_0x98e65(0x163)]());}['stopFollowing'](){const _0x2d5c57=_0x5a9157;this['_status']===_0x2d5c57(0x164)&&this[_0x2d5c57(0x135)]();}[_0x5a9157(0x186)](_0x1c646f){const _0x19fecd=_0x5a9157,{presenter:_0x4a340c}=_0x1c646f[_0x19fecd(0x169)],_0x52a714=this[_0x19fecd(0x1a4)][_0x19fecd(0x1a7)]();this[_0x19fecd(0x179)]=_0x4a340c,_0x4a340c===_0x52a714?(this[_0x19fecd(0x135)](),this[_0x19fecd(0x1b8)]()):this['_status']!==_0x19fecd(0x120)&&(this[_0x19fecd(0x13a)](),this[_0x19fecd(0x163)]());}['_fetchOperations'](){const _0x177e9a=_0x5a9157,_0xc199c3={'eventID':_0xb6d82[_0x177e9a(0x165)]};this[_0x177e9a(0x1a4)][_0x177e9a(0x11b)](_0xc199c3,this[_0x177e9a(0x156)]);}[_0x5a9157(0x149)](){const _0x1e3f06=_0x5a9157;this['_presenter']=null,this['_status']!=='presenting'&&this[_0x1e3f06(0x11e)]();}[_0x5a9157(0x181)](_0x36b89e){const _0x193e4d=_0x5a9157;if(this[_0x193e4d(0x182)]===_0x193e4d(0x164)&&this[_0x193e4d(0x179)]===_0x36b89e[_0x193e4d(0x169)][_0x193e4d(0x15d)]){const _0x540c5e=_0x448a4b(_0x36b89e[_0x193e4d(0x169)])[_0x193e4d(0x16c)][_0x193e4d(0x142)]()[_0x193e4d(0x196)](_0x45d7bf=>_0x45d7bf['id']===_0x1a8b78['id']);if(_0x540c5e){const _0x4dd3b6=_0x540c5e[_0x193e4d(0x13e)][_0x193e4d(0x137)],_0x1ac1b9=_0x540c5e['params'][_0x193e4d(0x1b0)]['id'];setTimeout(()=>{const _0xee294a=_0x193e4d;this['_commandService'][_0xee294a(0x146)](_0x4ff82e['id'],{'unitId':_0x4dd3b6,'subUnitId':_0x1ac1b9},{'fromCollab':!0x0});});}}}['_startPresenting'](){const _0x2fcc17=_0x5a9157;this[_0x2fcc17(0x14b)]['next']('presenting');const _0xf2a2fc=new Map(),_0x44940d=this[_0x2fcc17(0x1af)]=new _0x5315c9();_0x44940d[_0x2fcc17(0x16e)](_0x3e6459(()=>{const _0x53be83=_0x2fcc17;_0xf2a2fc[_0x53be83(0x183)](_0x367a3b=>_0x367a3b[_0x53be83(0x127)]()),_0xf2a2fc[_0x53be83(0x16f)]();})),_0x44940d[_0x2fcc17(0x16e)](this[_0x2fcc17(0x13f)]['onCommandExecuted'](_0x5bea74=>{const _0x462bee=_0x2fcc17;var _0x52d583;if(_0x5bea74['type']!==_0x55dc24[_0x462bee(0x15c)]||!this['_liveShareService'][_0x462bee(0x168)](_0x5bea74['id']))return;const {id:_0xb9e8ff}=_0x5bea74;let _0x372092;_0xf2a2fc[_0x462bee(0x19e)](_0xb9e8ff)?_0x372092=_0xf2a2fc[_0x462bee(0x124)](_0xb9e8ff):(_0x372092=new _0x4797b2(),_0xf2a2fc['set'](_0xb9e8ff,_0x372092),_0x372092[_0x462bee(0x17e)](_0x1e0766((_0x52d583=this[_0x462bee(0x151)][_0x462bee(0x19b)](Ce))!=null?_0x52d583:De,void 0x0,{'trailing':!0x0,'leading':!0x0}))['subscribe'](_0x2d940a=>{const _0x2e3533=_0x462bee;this[_0x2e3533(0x1a4)][_0x2e3533(0x11b)]({'eventID':_0xb6d82[_0x2e3533(0x148)],'data':{'unitID':this[_0x2e3533(0x156)],'operations':{[_0x2d940a['id']]:{'id':_0x2d940a['id'],'params':JSON[_0x2e3533(0x1a1)](_0x2d940a[_0x2e3533(0x13e)])}}}},this[_0x2e3533(0x156)]);})),_0x372092['next'](_0x5bea74);})),this[_0x2fcc17(0x147)][_0x2fcc17(0x13c)](this['_unitID'])[_0x2fcc17(0x183)](_0x7bda83=>this[_0x2fcc17(0x1a4)]['send']({'eventID':_0xb6d82[_0x2fcc17(0x148)],'data':{'unitID':this[_0x2fcc17(0x156)],'operations':{[_0x7bda83['id']]:{'id':_0x7bda83['id'],'params':JSON[_0x2fcc17(0x1a1)](_0x7bda83[_0x2fcc17(0x13e)])}}}},this[_0x2fcc17(0x156)]));}[_0x5a9157(0x13a)](){const _0x2e424e=_0x5a9157;var _0x4d1b4f;this[_0x2e424e(0x14b)][_0x2e424e(0x15e)](_0x2e424e(0x15f)),(_0x4d1b4f=this[_0x2e424e(0x1af)])==null||_0x4d1b4f[_0x2e424e(0x15b)](),this['_commandDisposable']=null;}[_0x5a9157(0x163)](){const _0x2bf1fb=_0x5a9157;var _0x27743f;(_0x27743f=this[_0x2bf1fb(0x1af)])==null||_0x27743f[_0x2bf1fb(0x15b)](),this[_0x2bf1fb(0x14b)][_0x2bf1fb(0x15e)](_0x2bf1fb(0x164));}[_0x5a9157(0x11e)](){const _0x2f179d=_0x5a9157;var _0x292e3d;this[_0x2f179d(0x14b)][_0x2f179d(0x15e)](_0x2f179d(0x15f)),(_0x292e3d=this[_0x2f179d(0x1af)])==null||_0x292e3d[_0x2f179d(0x15b)](),this[_0x2f179d(0x1af)]=null;}['_stopFollowing'](){const _0x4d74f4=_0x5a9157;var _0x5a5b28;this[_0x4d74f4(0x14b)]['next']('not-following'),(_0x5a5b28=this['_commandDisposable'])==null||_0x5a5b28['dispose']();}[_0x5a9157(0x1a0)](_0x3d307d){const _0x2213ae=_0x5a9157;if([_0x2213ae(0x174),'not-following',_0x2213ae(0x17f)]['includes'](this[_0x2213ae(0x182)])||!_0x3d307d[_0x2213ae(0x169)]['presenter']||_0x3d307d['data']['presenter']===this[_0x2213ae(0x1a4)][_0x2213ae(0x1a7)]())return;this[_0x2213ae(0x182)]===_0x2213ae(0x15f)&&this['_startFollowing']();const _0x2e8e55=_0x3d307d[_0x2213ae(0x169)]['operations'];Object[_0x2213ae(0x128)](_0x2e8e55)['forEach'](_0x2fffe2=>{const _0x1e2da0=_0x2213ae;this[_0x1e2da0(0x13f)][_0x1e2da0(0x146)](_0x2fffe2['id'],_0x2fffe2[_0x1e2da0(0x13e)]?JSON['parse'](_0x2fffe2['params']):null,{'fromCollab':!0x0});});}['_handleOffline'](){const _0x5b4b85=_0x5a9157;var _0x4085e0;this['_status$'][_0x5b4b85(0x15e)](_0x5b4b85(0x17f)),(_0x4085e0=this[_0x5b4b85(0x1af)])==null||_0x4085e0[_0x5b4b85(0x15b)]();}[_0x5a9157(0x144)](){const _0xc3ec29=_0x5a9157;this[_0xc3ec29(0x14b)][_0xc3ec29(0x15e)](_0xc3ec29(0x15f)),this[_0xc3ec29(0x1b1)]();}};N=Y([_(0x2,_0x2ccd3e),_(0x3,_0x5890f3(L)),_(0x4,_0x8f3e9)],N);function Le(){const _0x87951d=_0x5a9157,_0x164387=_0x14fb74(S),_0x527671=_0x14fb74(_0x2bf8ed),_0x462115=_0x25b804(()=>_0x527671[_0x87951d(0x1a8)](_0x118916['UNIVER_SHEET']),void 0x0,!0x1,[]),[_0x5233cb,_0x38fdee]=_0x5ab416(null),[_0x2043e4,_0x267a6e]=_0x5ab416(c['IDLE']),_0x4d1cae=_0x3a8f3b(null);return _0x34456e(()=>(_0x462115&&_0x164387['getLiveShareCoordinator'](_0x462115['getUnitId']())[_0x87951d(0x15a)](_0x354ae1=>{const _0x5a6f76=_0x87951d;_0x38fdee(_0x354ae1),_0x4d1cae[_0x5a6f76(0x17b)]=_0x354ae1[_0x5a6f76(0x1b6)][_0x5a6f76(0x154)](_0x3caaac=>{_0x267a6e(_0x3caaac);});}),()=>{const _0x2c52bb=_0x87951d;var _0x77fa80;(_0x77fa80=_0x4d1cae[_0x2c52bb(0x17b)])==null||_0x77fa80[_0x2c52bb(0x185)](),_0x4d1cae['current']=null;}),[_0x462115,_0x164387]),_0x5233cb?_0xe9d27a(_0x1d5dcc,{'align':_0x87951d(0x115),'disabled':_0x2043e4===c['OFFLINE'],'className':_0x87951d(0x1aa),'overlay':_0xe9d27a(Re,{'status':_0x2043e4,'coordinator':_0x5233cb}),'children':_0xe9d27a(_0x87951d(0x13d),{'className':_0x26827b('univer-border-none\x20univer-text-gray-600\x20univer-outline-none',{'univer-cursor-not-allowed':_0x2043e4===c[_0x87951d(0x150)],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x2043e4!==c['OFFLINE']}),'type':_0x87951d(0x13d),'children':_0xe9d27a(W,{'className':_0x87951d(0x122)})})}):null;}function Re(_0x25aabb){const _0xc61288=_0x5a9157,{status:_0xb36f22,coordinator:_0x4f0364}=_0x25aabb;switch(_0xb36f22){case c[_0xc61288(0x12a)]:return _0xe9d27a($e,{'coordinator':_0x4f0364});case c[_0xc61288(0x14a)]:return _0xe9d27a(xe,{'coordinator':_0x4f0364});case c[_0xc61288(0x178)]:return _0xe9d27a(Pe,{'coordinator':_0x4f0364});case c[_0xc61288(0x150)]:return _0xe9d27a(Te,{});case c[_0xc61288(0x195)]:return _0xe9d27a(Ae,{'coordinator':_0x4f0364});default:return null;}}function $e(_0x138a99){const _0x1fcc54=_0x5a9157,{coordinator:_0xe4e224}=_0x138a99;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x1fcc54(0x197)}),_0xe9d27a(_0x43cbc8,{'onClick':()=>_0xe4e224[_0x1fcc54(0x193)](),'children':_0x1fcc54(0x138)})]});}function xe(_0xf8d35a){const _0x8632b9=_0x5a9157,{coordinator:_0x4e338a}=_0xf8d35a;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':_0x8632b9(0x17a),'children':_0x8632b9(0x140)}),_0xe9d27a(_0x43cbc8,{'onClick':()=>_0x4e338a[_0x8632b9(0x18e)](),'children':_0x8632b9(0x177)})]});}function Pe(_0xca9462){const _0x14c1ab=_0x5a9157,{coordinator:_0x253fb9}=_0xca9462;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':_0x14c1ab(0x17a),'children':_0x14c1ab(0x129)}),_0xe9d27a(_0x43cbc8,{'variant':_0x14c1ab(0x172),'onClick':()=>_0x253fb9[_0x14c1ab(0x119)](),'children':_0x14c1ab(0x126)})]});}function Ae(_0x1b67b1){const _0x14432f=_0x5a9157,{coordinator:_0x21cc66}=_0x1b67b1;return _0x1044b3(_0x21e76d,{'children':[_0xe9d27a('div',{'className':_0x14432f(0x17a),'children':_0x14432f(0x155)}),_0xe9d27a(_0x43cbc8,{'variant':_0x14432f(0x153),'onClick':()=>_0x21cc66[_0x14432f(0x170)](),'children':_0x14432f(0x134)})]});}function Te(){const _0x27306e=_0x5a9157;return _0xe9d27a(_0x21e76d,{'children':_0x27306e(0x123)});}var Fe=Object[_0x5a9157(0x162)],He=(_0x680c97,_0x572487,_0x3190e6,_0x778131)=>{for(var _0x5de778=_0x778131>0x1?void 0x0:_0x778131?Fe(_0x572487,_0x3190e6):_0x572487,_0x38b7e5=_0x680c97['length']-0x1,_0x45b85c;_0x38b7e5>=0x0;_0x38b7e5--)(_0x45b85c=_0x680c97[_0x38b7e5])&&(_0x5de778=_0x45b85c(_0x5de778)||_0x5de778);return _0x5de778;},A=(_0x1c08f4,_0x269771)=>(_0x11bdcd,_0x5f11f9)=>_0x269771(_0x11bdcd,_0x5f11f9,_0x1c08f4);let m=class extends _0xa28d62{constructor(_0x4e63bf,_0x33ce12){const _0x3f3c5b=_0x5a9157;super(),this[_0x3f3c5b(0x139)]=_0x4e63bf,this[_0x3f3c5b(0x1ab)]=_0x33ce12,this[_0x3f3c5b(0x1b7)]();}['_mountLiveShare'](){const _0x59c071=_0x5a9157;this[_0x59c071(0x192)](this[_0x59c071(0x1ab)][_0x59c071(0x1b2)](_0x3df1ce[_0x59c071(0x171)],()=>_0x360939(Le,this[_0x59c071(0x139)])));}};m=He([A(0x0,_0x5890f3(_0x2ac967)),A(0x1,_0x4b3e7b)],m);const ye='live-share.config',T={};var Ue=Object['getOwnPropertyDescriptor'],Ve=(_0x58121e,_0xe4291d,_0x278131,_0x54e350)=>{const _0x52190f=_0x5a9157;for(var _0x5868df=_0x54e350>0x1?void 0x0:_0x54e350?Ue(_0xe4291d,_0x278131):_0xe4291d,_0x5c0c07=_0x58121e[_0x52190f(0x18d)]-0x1,_0x51bd8c;_0x5c0c07>=0x0;_0x5c0c07--)(_0x51bd8c=_0x58121e[_0x5c0c07])&&(_0x5868df=_0x51bd8c(_0x5868df)||_0x5868df);return _0x5868df;},je=(_0x5922ab,_0x1a4687)=>(_0x4deae9,_0x52beb5)=>_0x1a4687(_0x4deae9,_0x52beb5,_0x5922ab);let I=class extends _0xa28d62{constructor(_0x1e4d9c){const _0x5d3252=_0x5a9157;super(),this[_0x5d3252(0x147)]=_0x1e4d9c,this[_0x5d3252(0x12f)]();}['_init'](){const _0x2d1dbb=_0x5a9157;[_0x1f21c4['id'],_0x447fe5['id'],_0x4ff82e['id']][_0x2d1dbb(0x183)](_0x558ce7=>{const _0xaaf13e=_0x2d1dbb;this[_0xaaf13e(0x192)](this[_0xaaf13e(0x147)]['registerSharedOperation'](_0x558ce7));});}};I=Ve([je(0x0,_0x5890f3(L))],I);var Me=Object[_0x5a9157(0x136)],ke=Object[_0x5a9157(0x162)],Ge=(_0x2538d1,_0x252d75,_0xd3309f)=>_0x252d75 in _0x2538d1?Me(_0x2538d1,_0x252d75,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0xd3309f}):_0x2538d1[_0x252d75]=_0xd3309f,We=(_0x4752a5,_0x520908,_0x2c7a48,_0x1ce47c)=>{const _0xdf8090=_0x5a9157;for(var _0x4daee4=_0x1ce47c>0x1?void 0x0:_0x1ce47c?ke(_0x520908,_0x2c7a48):_0x520908,_0x2172ca=_0x4752a5[_0xdf8090(0x18d)]-0x1,_0x1376a9;_0x2172ca>=0x0;_0x2172ca--)(_0x1376a9=_0x4752a5[_0x2172ca])&&(_0x4daee4=_0x1376a9(_0x4daee4)||_0x4daee4);return _0x4daee4;},F=(_0x44eeb0,_0xe537e3)=>(_0x5c8c85,_0x1585d5)=>_0xe537e3(_0x5c8c85,_0x1585d5,_0x44eeb0),B=(_0x5db21f,_0x4e46c8,_0x5e04e6)=>Ge(_0x5db21f,typeof _0x4e46c8!=_0x5a9157(0x194)?_0x4e46c8+'':_0x4e46c8,_0x5e04e6);const Ye=_0x5a9157(0x17d);let b=class extends _0x446406{constructor(_0x25cfd7=T,_0x5a0473,_0x2754a2){const _0xb2ab96=_0x5a9157;super(),this['_config']=_0x25cfd7,this[_0xb2ab96(0x139)]=_0x5a0473,this[_0xb2ab96(0x151)]=_0x2754a2;const {..._0x78e952}=_0x230b34({},T,this[_0xb2ab96(0x14e)]);this[_0xb2ab96(0x151)][_0xb2ab96(0x18c)](ye,_0x78e952);}['onStarting'](){const _0x4e70cb=_0x5a9157;_0x3ca90e(this[_0x4e70cb(0x139)],_0x1d22c6([[L],[S],[I],[m]],this[_0x4e70cb(0x14e)][_0x4e70cb(0x116)])),_0xa89abb(this[_0x4e70cb(0x139)],[[I]]);}[_0x5a9157(0x198)](){const _0x4ce401=_0x5a9157;_0xa89abb(this[_0x4ce401(0x139)],[[m]]);}};B(b,'type',_0x118916[_0x5a9157(0x1a5)]),B(b,_0x5a9157(0x1ad),Ye),b=We([_0x2c9f12(_0x270228),F(0x1,_0x5890f3(_0x2ac967)),F(0x2,_0x2ccd3e)],b);export{m as DesktopLiveShareController,Le as LiveShare,S as LiveShareController,N as LiveShareCoordinator,L as LiveShareService,c as LiveShareStatus,b as UniverLiveSharePlugin};
|
package/lib/umd/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function _0x178d(){const _0x1cdeac=['1635431YiFJVn','78020AEvzFN','stopFollowing','_initialize','UniverEngineRender','amd','@univerjs/sheets-ui','83160WsfxvT','getId','2686999SRcsjT','getUnitId','getStatus','_injector','stopPresenting','3530SlAMCu','LiveShareStatus','IDLE','getActiveWorkbook','PRESENTING','UniverSheetsUi','function','startPresenting','getLiveShareCoordinatorSync','FEnum','3SdLrjY','UniverSheetsFacade','11639680HfJQla','FUniver','extend','UniverCoreFacade','SetScrollOperation','LiveShareController','@univerjs/engine-render','FRange','object','No\x20active\x20workbook\x20found.','get','No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.','1715348EWKjba','tryStartPresenting','UniverProLiveShare','syncExecuteCommand','174pyOTYq','1396174lVxWsy','@univerjs/sheets/facade','getSheetId','getRenderById','SetWorksheetActiveOperation','startRow','LiveShareStatusEnum','getActiveSheet'];_0x178d=function(){return _0x1cdeac;};return _0x178d();}function _0x1ed8(_0x55258e,_0x355928){_0x55258e=_0x55258e-0x90;const _0x178d50=_0x178d();let _0x1ed85f=_0x178d50[_0x55258e];return _0x1ed85f;}(function(_0x5b8384,_0x48cd57){const _0xe68ead=_0x1ed8,_0x3fd4d2=_0x5b8384();while(!![]){try{const _0xc744dd=parseInt(_0xe68ead(0x99))/0x1+-parseInt(_0xe68ead(0x91))/0x2*(-parseInt(_0xe68ead(0xb1))/0x3)+-parseInt(_0xe68ead(0xbf))/0x4+parseInt(_0xe68ead(0x9a))/0x5*(parseInt(_0xe68ead(0x90))/0x6)+parseInt(_0xe68ead(0xa2))/0x7+parseInt(_0xe68ead(0xb3))/0x8+parseInt(_0xe68ead(0xa0))/0x9*(-parseInt(_0xe68ead(0xa7))/0xa);if(_0xc744dd===_0x48cd57)break;else _0x3fd4d2['push'](_0x3fd4d2['shift']());}catch(_0x3479d3){_0x3fd4d2['push'](_0x3fd4d2['shift']());}}}(_0x178d,0xe4196),function(_0x15fd89,_0x2f0a7b){const _0x12eb19=_0x1ed8;typeof exports==_0x12eb19(0xbb)&&typeof module<'u'?_0x2f0a7b(require('@univerjs-pro/live-share'),require('@univerjs/engine-render'),require('@univerjs/sheets'),require('@univerjs/sheets-ui'),require('@univerjs/sheets/facade'),require('@univerjs/core/facade')):typeof define==_0x12eb19(0xad)&&define[_0x12eb19(0x9e)]?define(['@univerjs-pro/live-share',_0x12eb19(0xb9),'@univerjs/sheets',_0x12eb19(0x9f),_0x12eb19(0x92),'@univerjs/core/facade'],_0x2f0a7b):(_0x15fd89=typeof globalThis<'u'?globalThis:_0x15fd89||self,_0x2f0a7b(_0x15fd89[_0x12eb19(0xc1)],_0x15fd89[_0x12eb19(0x9d)],_0x15fd89['UniverSheets'],_0x15fd89[_0x12eb19(0xac)],_0x15fd89[_0x12eb19(0xb2)],_0x15fd89[_0x12eb19(0xb6)]));}(this,function(_0x222fc4,_0x11d06d,_0x1ff1d3,_0x4fb08c,_0x4ccd75,_0x39bf9d){'use strict';const _0x154172=_0x1ed8;class _0x22dc6a extends _0x4ccd75[_0x154172(0xba)]{[_0x154172(0x9c)](_0x2d2a10,_0x508a11,_0x343910,_0x58885e,_0xb4fc0f){const _0x376912=_0x154172,_0xd886f6=_0x2d2a10[_0x376912(0xbd)](_0x222fc4[_0x376912(0xb8)]),_0x3be418=_0x2d2a10[_0x376912(0xbd)](_0x11d06d['IRenderManagerService']),_0x45d861=_0x508a11[_0x376912(0xa3)](),_0x496a79=_0x508a11[_0x376912(0x98)](),_0xb5c44e=_0xd886f6[_0x376912(0xaf)](_0x45d861);(_0xb5c44e==null?void 0x0:_0xb5c44e['getStatus']())!==_0x222fc4[_0x376912(0xa8)][_0x376912(0xab)]||(_0x343910['getSheetId']()!==_0x496a79[_0x376912(0x93)]()&&this['_commandService']['executeCommand'](_0x1ff1d3[_0x376912(0x95)]['id'],{'unitId':_0x45d861,'subUnitId':_0x343910[_0x376912(0x93)]()}),!_0x3be418[_0x376912(0x94)](_0x45d861))||_0xb4fc0f[_0x376912(0xc2)](_0x4fb08c[_0x376912(0xb7)]['id'],{'unitId':_0x508a11[_0x376912(0xa3)](),'sheetId':_0x343910[_0x376912(0x93)](),'sheetViewStartRow':_0x58885e[_0x376912(0x96)],'sheetViewStartColumn':_0x58885e['startColumn'],'offsetX':0x0,'offsetY':0x0,'screenRatioX':-0x1/0x3,'screenRatioY':-0x1/0x3,'duration':0x12c});}}_0x4ccd75[_0x154172(0xba)][_0x154172(0xb5)](_0x22dc6a);class _0x533a66 extends _0x39bf9d['FUniver']{['getLiveShareStatus'](){const _0x45c320=_0x154172;var _0x2266a6,_0x2396e5;const _0x197974=this[_0x45c320(0xa5)][_0x45c320(0xbd)](_0x222fc4[_0x45c320(0xb8)]),_0x14d7d8=(_0x2266a6=this['getActiveWorkbook']())==null?void 0x0:_0x2266a6[_0x45c320(0xa1)]();if(!_0x14d7d8)throw new Error(_0x45c320(0xbc));const _0x5b5756=_0x197974[_0x45c320(0xaf)](_0x14d7d8);return(_0x2396e5=_0x5b5756==null?void 0x0:_0x5b5756[_0x45c320(0xa4)]())!=null?_0x2396e5:_0x222fc4['LiveShareStatus'][_0x45c320(0xa9)];}['startFollowing'](){const _0x5da2da=_0x154172;var _0x58d55d;const _0x140de9=this[_0x5da2da(0xa5)][_0x5da2da(0xbd)](_0x222fc4[_0x5da2da(0xb8)]),_0x27e481=(_0x58d55d=this['getActiveWorkbook']())==null?void 0x0:_0x58d55d[_0x5da2da(0xa1)]();if(!_0x27e481)throw new Error(_0x5da2da(0xbc));const _0x4b02ee=_0x140de9['getLiveShareCoordinatorSync'](_0x27e481);if(!_0x4b02ee)throw new Error('No\x20LiveShareCoordinator\x20found\x20for\x20the\x20active\x20workbook.');_0x4b02ee['startFollowing']();}[_0x154172(0x9b)](){const _0x40f2c1=_0x154172;var _0x271b99;const _0x1dedfb=this[_0x40f2c1(0xa5)][_0x40f2c1(0xbd)](_0x222fc4[_0x40f2c1(0xb8)]),_0x41b7b9=(_0x271b99=this[_0x40f2c1(0xaa)]())==null?void 0x0:_0x271b99[_0x40f2c1(0xa1)]();if(!_0x41b7b9)throw new Error(_0x40f2c1(0xbc));const _0x259315=_0x1dedfb[_0x40f2c1(0xaf)](_0x41b7b9);if(!_0x259315)throw new Error(_0x40f2c1(0xbe));_0x259315[_0x40f2c1(0x9b)]();}[_0x154172(0xae)](){const _0x2565ee=_0x154172;var _0x277ddf;const _0x5269d5=this[_0x2565ee(0xa5)][_0x2565ee(0xbd)](_0x222fc4['LiveShareController']),_0x412aed=(_0x277ddf=this['getActiveWorkbook']())==null?void 0x0:_0x277ddf[_0x2565ee(0xa1)]();if(!_0x412aed)throw new Error(_0x2565ee(0xbc));const _0x47f1cf=_0x5269d5[_0x2565ee(0xaf)](_0x412aed);if(!_0x47f1cf)throw new Error(_0x2565ee(0xbe));_0x47f1cf[_0x2565ee(0xc0)]();}[_0x154172(0xa6)](){const _0x494da6=_0x154172;var _0x14bd84;const _0x72ee5e=this['_injector']['get'](_0x222fc4[_0x494da6(0xb8)]),_0x43be8b=(_0x14bd84=this[_0x494da6(0xaa)]())==null?void 0x0:_0x14bd84[_0x494da6(0xa1)]();if(!_0x43be8b)throw new Error(_0x494da6(0xbc));const _0x5f5140=_0x72ee5e['getLiveShareCoordinatorSync'](_0x43be8b);if(!_0x5f5140)throw new Error(_0x494da6(0xbe));_0x5f5140[_0x494da6(0xa6)]();}}_0x39bf9d[_0x154172(0xb4)][_0x154172(0xb5)](_0x533a66);class _0x5640fd extends _0x39bf9d[_0x154172(0xb0)]{get[_0x154172(0x97)](){const _0x2f6a85=_0x154172;return _0x222fc4[_0x2f6a85(0xa8)];}}_0x39bf9d['FEnum']['extend'](_0x5640fd);}));
|
package/lib/umd/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x2592(_0x522808,_0x56a664){_0x522808=_0x522808-0x1dc;const _0x20aae3=_0x20aa();let _0x2592e2=_0x20aae3[_0x522808];return _0x2592e2;}function _0x20aa(){const _0x2eba7b=['LIVESHARE_OPERATION','parse','idSuffix','defIds','M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','SetZoomRatioOperation','getTypeOfUnitAdded$','InsertSheetMutation','registerDependencies','params','Fragment','subscribe','includes','type','IUniverInstanceService','LiveShareController','button','_collabSession','get','currentColor','has','_status','assign','LiveShareIcon','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','LiveShareStatus','_entities','registerInitialStateReporter','You\x27re\x20following\x20the\x20presenter','forEach','getMemberID','stopPresenting','useState','1474189lWMQES','none','_handleNewHost','getUnitId','_commandDisposable','_collabSessionService','0\x200\x2017\x2017','OPERATION','shouldShareOperation','url(#$1','UNIVER_SHEET','use','toStringTag','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','UNIVER_LIVE_SHARE_PLUGIN','_config','toDisposable','3rPkZnG','_startLiveShareCoordinator','memberID','react','init','stopFollowing','fill','199090dGpVZZ','end','jsx','BehaviorSubject','Dropdown','React','UniverSheetsUi','pipe','children','LIVESHARE_TERMINATE','jsxs','dispose$','rxjs/operators','override','UniverIcon','setConfig','parseProtocolChangeset','_handleOperation','Stop\x20following','_handleNewChangeSets','_configService','CollaborationEvent','Start\x20following','disposeWithMe','Button','live-share-icon','UniverInstanceType','_uiPartsService','registerComponent','set','339736CpopiK','_beIdle','onRendered','replace','presenting','IConfigService','amd','operations','RxDisposable','dispose','You\x27re\x20not\x20following\x20the\x20presenter','length','following','onStarting','idle','OFFLINE','HEADER_MENU','xlink:href','from','_status$','mask','exports','data','_presenter','live-share.config','Disposable','getConfig','sheet','univer-size-4','startFollowing','@univerjs/sheets','text','getStatus','unsubscribe','getLiveShareCoordinatorSync','react/jsx-runtime','_commandService','not-following','div','add','default','NOT_FOLLOWING','Injector','evenodd','SetScrollOperation','status$','complete','forwardRef','UniverProCollaboration','5853414IAOPAw','delete','4968420dhxYdN','path','trim','registerSharedOperation','Inject','DependentOn','map','UniverLiveSharePlugin','useObservable','clear','string','_sharedOperations','current','@univerjs/core','UniverCollaborationClientPlugin','105sTGopY','@univerjs/design','1em','colorChannel1','_stopFollowing','rxjs','Stop\x20presenting','executeCommand','tag','getCurrentTypeOfUnit$','_univerInstanceService','_mountLiveShare','http://www.w3.org/2000/svg','onCommandExecuted','defineProperty','_startFollowing','_handleTerminate','asObservable','_handleOnline','2773104dzKgaT','getOwnPropertyDescriptor','touchDependencies','stringify','_init','UniverProLiveShare','DisposableCollection','toString','takeUntil','send','mergeOverrideWithDependencies','createElement','then','defs','SetWorksheetActiveOperation','entries','IDLE','UniverSheets','FOLLOWING','displayName','You\x27re\x20presenting\x20the\x20document','BuiltInUIPart','LIVESHARE_FETCH_OPERATIONS','@univerjs-pro/collaboration-client','_injector','CollaborationSessionService','_reporters','LIVESHARE_NEW_HOST','_unitID','presenter','DesktopLiveShareController','LiveShareCoordinator','attrs','offline','_handleOffline','ONLINE','LiveShareService','19948959zdVnew','univer-mb-3\x20univer-w-full\x20univer-text-sm','symbol','@univerjs-pro/collaboration','Start','unitId','find','_stopPresenting','svg','_startPresenting','clsx','createInstance','next','merge','_fetchOperations','SessionStatus','_liveShareService','getValue'];_0x20aa=function(){return _0x2eba7b;};return _0x20aa();}(function(_0x4fb74e,_0x2c6a7d){const _0x47d417=_0x2592,_0x549642=_0x4fb74e();while(!![]){try{const _0x51482c=-parseInt(_0x47d417(0x23a))/0x1+parseInt(_0x47d417(0x252))/0x2*(parseInt(_0x47d417(0x24b))/0x3)+-parseInt(_0x47d417(0x1e2))/0x4+parseInt(_0x47d417(0x2a3))/0x5+-parseInt(_0x47d417(0x2a1))/0x6+-parseInt(_0x47d417(0x2b2))/0x7*(-parseInt(_0x47d417(0x270))/0x8)+parseInt(_0x47d417(0x207))/0x9;if(_0x51482c===_0x2c6a7d)break;else _0x549642['push'](_0x549642['shift']());}catch(_0x584d46){_0x549642['push'](_0x549642['shift']());}}}(_0x20aa,0xc43a7),function(_0x309f0d,_0x24724c){const _0xf93b34=_0x2592;typeof exports=='object'&&typeof module<'u'?_0x24724c(exports,require('@univerjs/core'),require('@univerjs/ui'),require('react/jsx-runtime'),require('@univerjs/design'),require('react'),require('@univerjs-pro/collaboration'),require('@univerjs-pro/collaboration-client'),require('@univerjs/sheets'),require('rxjs'),require('rxjs/operators'),require('@univerjs/sheets-ui')):typeof define=='function'&&define[_0xf93b34(0x276)]?define([_0xf93b34(0x285),_0xf93b34(0x2b0),'@univerjs/ui',_0xf93b34(0x293),_0xf93b34(0x2b3),_0xf93b34(0x24e),_0xf93b34(0x20a),_0xf93b34(0x1f9),_0xf93b34(0x28e),_0xf93b34(0x2b7),_0xf93b34(0x25e),'@univerjs/sheets-ui'],_0x24724c):(_0x309f0d=typeof globalThis<'u'?globalThis:_0x309f0d||self,_0x24724c(_0x309f0d[_0xf93b34(0x1e7)]={},_0x309f0d['UniverCore'],_0x309f0d['UniverUi'],_0x309f0d[_0xf93b34(0x257)],_0x309f0d['UniverDesign'],_0x309f0d[_0xf93b34(0x257)],_0x309f0d[_0xf93b34(0x2a0)],_0x309f0d['UniverProCollaborationClient'],_0x309f0d[_0xf93b34(0x1f3)],_0x309f0d[_0xf93b34(0x2b7)],_0x309f0d[_0xf93b34(0x2b7)]['operators'],_0x309f0d[_0xf93b34(0x258)]));}(this,function(_0x219a3f,_0x40790f,_0x3ef861,_0x3ecb81,_0x49fd3f,_0x39f6be,_0x2b554d,_0x4e4830,_0x37f478,_0xd1ada7,_0x529592,_0x486c38){'use strict';const _0x198c54=_0x2592;var _0x43ce59=Object[_0x198c54(0x1dd)],_0x354d89=(_0x31073c,_0x8f204e,_0x1a4a0f)=>_0x8f204e in _0x31073c?_0x43ce59(_0x31073c,_0x8f204e,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x1a4a0f}):_0x31073c[_0x8f204e]=_0x1a4a0f,_0x5f2bc9=(_0x965430,_0xf817dc,_0x533c0a)=>_0x354d89(_0x965430,typeof _0xf817dc!=_0x198c54(0x209)?_0xf817dc+'':_0xf817dc,_0x533c0a);function _0x524017({ref:_0x976cd8,..._0x203abc}){const _0x5f2f40=_0x198c54,{icon:_0x39aca5,id:_0x212203,className:_0x5e3665,extend:_0x5d5a9e,..._0x1a8358}=_0x203abc,_0xf6d5bb=('univerjs-icon\x20univerjs-icon-'+_0x212203+'\x20'+(_0x5e3665||''))[_0x5f2f40(0x2a5)](),_0x575ee7=_0x39f6be['useRef']('_'+_0x3720e2());return _0x6656b4(_0x39aca5,''+_0x212203,{'defIds':_0x39aca5[_0x5f2f40(0x21c)],'idSuffix':_0x575ee7[_0x5f2f40(0x2af)]},{'ref':_0x976cd8,'className':_0xf6d5bb,..._0x1a8358},_0x5d5a9e);}function _0x6656b4(_0x7d6510,_0x3ed633,_0x880c3a,_0x3d34d8,_0x54c7df){const _0x37cfd8=_0x198c54;return _0x39f6be['createElement'](_0x7d6510[_0x37cfd8(0x2ba)],{'key':_0x3ed633,..._0x231505(_0x7d6510,_0x880c3a,_0x54c7df),..._0x3d34d8},(_0x5c3864(_0x7d6510,_0x880c3a)[_0x37cfd8(0x25a)]||[])[_0x37cfd8(0x2a9)]((_0x2e0fd1,_0x3f2543)=>_0x6656b4(_0x2e0fd1,_0x3ed633+'-'+_0x7d6510[_0x37cfd8(0x2ba)]+'-'+_0x3f2543,_0x880c3a,void 0x0,_0x54c7df)));}function _0x231505(_0x13511c,_0x588424,_0x134348){const _0x2e0704=_0x198c54,_0x1949cc={..._0x13511c[_0x2e0704(0x202)]};_0x134348!=null&&_0x134348[_0x2e0704(0x2b5)]&&_0x1949cc[_0x2e0704(0x251)]==='colorChannel1'&&(_0x1949cc[_0x2e0704(0x251)]=_0x134348[_0x2e0704(0x2b5)]),_0x13511c['tag']===_0x2e0704(0x284)&&_0x1949cc['id']&&(_0x1949cc['id']=_0x1949cc['id']+_0x588424['idSuffix']),Object[_0x2e0704(0x1f1)](_0x1949cc)[_0x2e0704(0x236)](([_0x1b9b82,_0x3c37e5])=>{const _0xcbf35d=_0x2e0704;_0x1b9b82===_0xcbf35d(0x284)&&typeof _0x3c37e5==_0xcbf35d(0x2ad)&&(_0x1949cc[_0x1b9b82]=_0x3c37e5[_0xcbf35d(0x273)](/url\(#(.*)\)/,_0xcbf35d(0x243)+_0x588424[_0xcbf35d(0x21b)]+')'));});const {defIds:_0x2c9b39}=_0x588424;return!_0x2c9b39||_0x2c9b39[_0x2e0704(0x27b)]===0x0||(_0x13511c['tag']===_0x2e0704(0x245)&&_0x1949cc[_0x2e0704(0x281)]&&(_0x1949cc[_0x2e0704(0x281)]=_0x1949cc[_0x2e0704(0x281)]+_0x588424[_0x2e0704(0x21b)]),Object[_0x2e0704(0x1f1)](_0x1949cc)['forEach'](([_0x20f83a,_0x429521])=>{const _0x253126=_0x2e0704;typeof _0x429521==_0x253126(0x2ad)&&(_0x1949cc[_0x20f83a]=_0x429521[_0x253126(0x273)](/url\(#(.*)\)/,_0x253126(0x243)+_0x588424['idSuffix']+')'));})),_0x1949cc;}function _0x5c3864(_0x31e4d9,_0x6dd9b){const _0x1fc81b=_0x198c54;var _0x39babd;const {defIds:_0x5de7bb}=_0x6dd9b;return!_0x5de7bb||_0x5de7bb[_0x1fc81b(0x27b)]===0x0?_0x31e4d9:_0x31e4d9['tag']===_0x1fc81b(0x1ef)&&((_0x39babd=_0x31e4d9[_0x1fc81b(0x25a)])!=null&&_0x39babd[_0x1fc81b(0x27b)])?{..._0x31e4d9,'children':_0x31e4d9[_0x1fc81b(0x25a)][_0x1fc81b(0x2a9)](_0x12f537=>typeof _0x12f537[_0x1fc81b(0x202)]['id']=='string'&&_0x5de7bb&&_0x5de7bb[_0x1fc81b(0x225)](_0x12f537[_0x1fc81b(0x202)]['id'])?{..._0x12f537,'attrs':{..._0x12f537[_0x1fc81b(0x202)],'id':_0x12f537[_0x1fc81b(0x202)]['id']+_0x6dd9b[_0x1fc81b(0x21b)]}}:_0x12f537)}:_0x31e4d9;}function _0x3720e2(){const _0x1967bb=_0x198c54;return Math['random']()[_0x1967bb(0x1e9)](0x24)['substring'](0x2,0x8);}_0x524017[_0x198c54(0x1f5)]=_0x198c54(0x260);const _0x854dd1={'tag':_0x198c54(0x20f),'attrs':{'xmlns':_0x198c54(0x2be),'fill':_0x198c54(0x23b),'viewBox':_0x198c54(0x240),'width':_0x198c54(0x2b4),'height':'1em'},'children':[{'tag':_0x198c54(0x2a4),'attrs':{'fill':_0x198c54(0x22c),'d':_0x198c54(0x231)}},{'tag':_0x198c54(0x2a4),'attrs':{'fill':'currentColor','d':_0x198c54(0x21d),'fillRule':_0x198c54(0x29b),'clipRule':'evenodd'}}]},_0x5b6f8f=_0x39f6be[_0x198c54(0x29f)](function(_0x5622ca,_0x314f4d){const _0x21a35c=_0x198c54;return _0x39f6be[_0x21a35c(0x1ed)](_0x524017,Object[_0x21a35c(0x22f)]({},_0x5622ca,{'id':_0x21a35c(0x26b),'ref':_0x314f4d,'icon':_0x854dd1}));});_0x5b6f8f[_0x198c54(0x1f5)]=_0x198c54(0x230);class _0x3f94ee extends _0x40790f['Disposable']{constructor(){const _0x41a0b2=_0x198c54;super(...arguments),_0x5f2bc9(this,_0x41a0b2(0x2ae),new Set()),_0x5f2bc9(this,_0x41a0b2(0x1fc),new Set());}[_0x198c54(0x2a6)](_0x58daca){const _0x4e3c68=_0x198c54;return this[_0x4e3c68(0x2ae)][_0x4e3c68(0x297)](_0x58daca),_0x40790f['toDisposable'](()=>this['_sharedOperations'][_0x4e3c68(0x2a2)](_0x58daca));}[_0x198c54(0x234)](_0x1925a9){const _0x329c9b=_0x198c54;return this[_0x329c9b(0x1fc)]['add'](_0x1925a9),_0x40790f['toDisposable'](()=>this[_0x329c9b(0x1fc)][_0x329c9b(0x2a2)](_0x1925a9));}[_0x198c54(0x242)](_0x12c4ec){const _0x10b331=_0x198c54;return this[_0x10b331(0x2ae)][_0x10b331(0x22d)](_0x12c4ec);}['getInitialStates'](_0x231d55){const _0x1e1297=_0x198c54;return Array[_0x1e1297(0x282)](this[_0x1e1297(0x1fc)])[_0x1e1297(0x2a9)](_0x1332ce=>_0x1332ce(_0x231d55));}}var _0x22ed5a=Object[_0x198c54(0x1e3)],_0x5e15f8=(_0x490c8a,_0x3e8292,_0x4cd231,_0x33920a)=>{for(var _0xad1de8=_0x33920a>0x1?void 0x0:_0x33920a?_0x22ed5a(_0x3e8292,_0x4cd231):_0x3e8292,_0x53dcee=_0x490c8a['length']-0x1,_0x47c2f1;_0x53dcee>=0x0;_0x53dcee--)(_0x47c2f1=_0x490c8a[_0x53dcee])&&(_0xad1de8=_0x47c2f1(_0xad1de8)||_0xad1de8);return _0xad1de8;},_0x68fa75=(_0x2ab88f,_0x30d12d)=>(_0x46a450,_0x3fd667)=>_0x30d12d(_0x46a450,_0x3fd667,_0x2ab88f);_0x219a3f[_0x198c54(0x228)]=class extends _0x40790f[_0x198c54(0x278)]{constructor(_0x3826ec,_0x2e7097,_0x462bbd){const _0x527d3d=_0x198c54;super(),_0x5f2bc9(this,'_entities',new Map()),(this['_univerInstanceService']=_0x3826ec,this[_0x527d3d(0x1fa)]=_0x2e7097,this[_0x527d3d(0x23f)]=_0x462bbd,this[_0x527d3d(0x1e6)]());}async['getLiveShareCoordinator'](_0x144dde){const _0x450030=_0x198c54;return this['_entities'][_0x450030(0x22d)](_0x144dde)||await this[_0x450030(0x24c)](_0x144dde),this[_0x450030(0x233)][_0x450030(0x22b)](_0x144dde);}[_0x198c54(0x292)](_0x42d79d){const _0x2f5602=_0x198c54;var _0x68c607;return(_0x68c607=this['_entities'][_0x2f5602(0x22b)](_0x42d79d))!=null?_0x68c607:null;}[_0x198c54(0x1e6)](){const _0xbd181c=_0x198c54;this[_0xbd181c(0x2bc)][_0xbd181c(0x21f)](_0x40790f[_0xbd181c(0x26c)][_0xbd181c(0x244)])[_0xbd181c(0x259)](_0x529592[_0xbd181c(0x1ea)](this['dispose$']))['subscribe'](async _0x1ac3dc=>{const _0x2cf771=_0xbd181c,_0x43f5e0=_0x1ac3dc[_0x2cf771(0x23d)]();this[_0x2cf771(0x233)][_0x2cf771(0x22d)](_0x43f5e0)||this[_0x2cf771(0x24c)](_0x43f5e0);}),this[_0xbd181c(0x2bc)]['getTypeOfUnitDisposed$'](_0x40790f[_0xbd181c(0x26c)]['UNIVER_SHEET'])[_0xbd181c(0x259)](_0x529592['takeUntil'](this[_0xbd181c(0x25d)]))[_0xbd181c(0x224)](_0x2bcba2=>{const _0x402929=_0xbd181c,_0x50f337=_0x2bcba2[_0x402929(0x23d)](),_0x323b16=this[_0x402929(0x233)]['get'](_0x50f337);_0x323b16==null||_0x323b16[_0x402929(0x279)]();});}async[_0x198c54(0x24c)](_0x25f771){const _0x4a3c6e=_0x198c54,_0xfa644b=await this[_0x4a3c6e(0x23f)]['requireSession'](_0x25f771),_0x5ae528=this[_0x4a3c6e(0x1fa)][_0x4a3c6e(0x212)](_0x219a3f[_0x4a3c6e(0x201)],_0x25f771,_0xfa644b);return _0x5ae528[_0x4a3c6e(0x24f)](),this['_entities'][_0x4a3c6e(0x26f)](_0x25f771,_0x5ae528),_0x5ae528;}},_0x219a3f[_0x198c54(0x228)]=_0x5e15f8([_0x68fa75(0x0,_0x40790f[_0x198c54(0x227)]),_0x68fa75(0x1,_0x40790f[_0x198c54(0x2a7)](_0x40790f['Injector'])),_0x68fa75(0x2,_0x40790f[_0x198c54(0x2a7)](_0x4e4830[_0x198c54(0x1fb)]))],_0x219a3f[_0x198c54(0x228)]);var _0x33922d=(_0x4ac361=>(_0x4ac361['OFFLINE']=_0x198c54(0x203),_0x4ac361[_0x198c54(0x1f2)]=_0x198c54(0x27e),_0x4ac361[_0x198c54(0x1f4)]='following',_0x4ac361[_0x198c54(0x299)]=_0x198c54(0x295),_0x4ac361['PRESENTING']=_0x198c54(0x274),_0x4ac361))(_0x33922d||{});const _0x57f8f8='SAME_OPERATION_SHARE_INTERVAL',_0x100476=0xc8;_0x219a3f[_0x198c54(0x201)]=class extends _0x40790f[_0x198c54(0x278)]{constructor(_0x23ddeb,_0x2a7f82,_0x589d54,_0x5c493d,_0x111a5e){const _0x5e3b65=_0x198c54;super(),_0x5f2bc9(this,_0x5e3b65(0x283),new _0xd1ada7[(_0x5e3b65(0x255))](_0x5e3b65(0x27e))),_0x5f2bc9(this,_0x5e3b65(0x29d),this[_0x5e3b65(0x283)][_0x5e3b65(0x1e0)]()),_0x5f2bc9(this,'_init',!0x1),_0x5f2bc9(this,_0x5e3b65(0x23e),null),_0x5f2bc9(this,_0x5e3b65(0x287),null),(this[_0x5e3b65(0x1fe)]=_0x23ddeb,this[_0x5e3b65(0x22a)]=_0x2a7f82,this[_0x5e3b65(0x266)]=_0x589d54,this[_0x5e3b65(0x217)]=_0x5c493d,this[_0x5e3b65(0x294)]=_0x111a5e);}get[_0x198c54(0x22e)](){const _0x41867e=_0x198c54;return this[_0x41867e(0x283)][_0x41867e(0x218)]();}[_0x198c54(0x279)](){const _0x2765ff=_0x198c54;var _0x3f7bf4;(_0x3f7bf4=this[_0x2765ff(0x23e)])==null||_0x3f7bf4[_0x2765ff(0x279)](),this[_0x2765ff(0x283)]['next'](_0x2765ff(0x27e)),this[_0x2765ff(0x283)][_0x2765ff(0x29e)]();}[_0x198c54(0x290)](){return this['_status'];}[_0x198c54(0x24f)](){const _0x5118a0=_0x198c54;this['_init']||(this[_0x5118a0(0x1e6)]=!0x0,this[_0x5118a0(0x22a)]['sessionStatus$'][_0x5118a0(0x259)](_0x529592[_0x5118a0(0x1ea)](this[_0x5118a0(0x25d)]))[_0x5118a0(0x224)](_0x4b5394=>{const _0x219a12=_0x5118a0;switch(_0x4b5394){case _0x4e4830[_0x219a12(0x216)]['OFFLINE']:this[_0x219a12(0x204)]();break;case _0x4e4830[_0x219a12(0x216)][_0x219a12(0x205)]:this[_0x219a12(0x1e1)]();break;}}),this[_0x5118a0(0x22a)]['event$'][_0x5118a0(0x259)](_0x529592[_0x5118a0(0x1ea)](this[_0x5118a0(0x25d)]))[_0x5118a0(0x224)](_0x2893d5=>{const _0x5d3d11=_0x5118a0,{eventID:_0xf3796f}=_0x2893d5;switch(_0xf3796f){case _0x2b554d['CollaborationEvent'][_0x5d3d11(0x1fd)]:this[_0x5d3d11(0x23c)](_0x2893d5);break;case _0x2b554d['CollaborationEvent'][_0x5d3d11(0x219)]:this['_handleOperation'](_0x2893d5);break;case _0x2b554d[_0x5d3d11(0x267)][_0x5d3d11(0x25b)]:this[_0x5d3d11(0x1df)]();break;case _0x2b554d[_0x5d3d11(0x267)]['NEW_CHANGESETS']:this[_0x5d3d11(0x265)](_0x2893d5);break;}}));}['tryStartPresenting'](){const _0xb36847=_0x198c54;this[_0xb36847(0x22a)][_0xb36847(0x1eb)]({'eventID':_0x2b554d[_0xb36847(0x267)]['LIVESHARE_REQUEST_HOST'],'data':{'unitID':this[_0xb36847(0x1fe)],'userID':this['_collabSession'][_0xb36847(0x237)]()}},this[_0xb36847(0x1fe)]);}['stopPresenting'](){const _0x2e05c5=_0x198c54;this[_0x2e05c5(0x22e)]===_0x2e05c5(0x274)&&(this[_0x2e05c5(0x283)][_0x2e05c5(0x213)](_0x2e05c5(0x27e)),this[_0x2e05c5(0x22a)][_0x2e05c5(0x1eb)]({'eventID':_0x2b554d[_0x2e05c5(0x267)][_0x2e05c5(0x25b)],'data':{'unitID':this['_unitID']}},this[_0x2e05c5(0x1fe)]));}[_0x198c54(0x28d)](){const _0x35013e=_0x198c54;this['_status']==='not-following'&&(this['_status$'][_0x35013e(0x213)]('following'),this[_0x35013e(0x1de)]());}[_0x198c54(0x250)](){const _0x458471=_0x198c54;this[_0x458471(0x22e)]===_0x458471(0x27c)&&this[_0x458471(0x2b6)]();}[_0x198c54(0x23c)](_0x26412c){const _0x223e7b=_0x198c54,{presenter:_0x190ba7}=_0x26412c[_0x223e7b(0x286)],_0x3d5ceb=this[_0x223e7b(0x22a)][_0x223e7b(0x237)]();this['_presenter']=_0x190ba7,_0x190ba7===_0x3d5ceb?(this[_0x223e7b(0x2b6)](),this[_0x223e7b(0x210)]()):this[_0x223e7b(0x22e)]!==_0x223e7b(0x295)&&(this[_0x223e7b(0x20e)](),this[_0x223e7b(0x1de)]());}['_fetchOperations'](){const _0x315391=_0x198c54,_0x444a3d={'eventID':_0x2b554d[_0x315391(0x267)][_0x315391(0x1f8)]};this['_collabSession'][_0x315391(0x1eb)](_0x444a3d,this[_0x315391(0x1fe)]);}[_0x198c54(0x1df)](){const _0x54c03b=_0x198c54;this['_presenter']=null,this['_status']!==_0x54c03b(0x274)&&this['_beIdle']();}[_0x198c54(0x265)](_0x24d877){const _0x43505f=_0x198c54;if(this['_status']==='following'&&this['_presenter']===_0x24d877['data'][_0x43505f(0x24d)]){const _0x52afda=_0x2b554d[_0x43505f(0x262)](_0x24d877[_0x43505f(0x286)])['mutations']['reverse']()[_0x43505f(0x20d)](_0x4c78ce=>_0x4c78ce['id']===_0x37f478[_0x43505f(0x220)]['id']);if(_0x52afda){const _0x339b96=_0x52afda[_0x43505f(0x222)][_0x43505f(0x20c)],_0x178d40=_0x52afda[_0x43505f(0x222)][_0x43505f(0x28b)]['id'];setTimeout(()=>{const _0x50debe=_0x43505f;this[_0x50debe(0x294)][_0x50debe(0x2b9)](_0x37f478['SetWorksheetActiveOperation']['id'],{'unitId':_0x339b96,'subUnitId':_0x178d40},{'fromCollab':!0x0});});}}}[_0x198c54(0x210)](){const _0x299c78=_0x198c54;this[_0x299c78(0x283)][_0x299c78(0x213)](_0x299c78(0x274));const _0x59085d=new Map(),_0x641ca2=this['_commandDisposable']=new _0x40790f[(_0x299c78(0x1e8))]();_0x641ca2['add'](_0x40790f[_0x299c78(0x24a)](()=>{const _0x254c49=_0x299c78;_0x59085d['forEach'](_0x244935=>_0x244935['complete']()),_0x59085d[_0x254c49(0x2ac)]();})),_0x641ca2[_0x299c78(0x297)](this[_0x299c78(0x294)][_0x299c78(0x1dc)](_0x590070=>{const _0x5dcb8d=_0x299c78;var _0x1dac49;if(_0x590070[_0x5dcb8d(0x226)]!==_0x40790f['CommandType'][_0x5dcb8d(0x241)]||!this[_0x5dcb8d(0x217)][_0x5dcb8d(0x242)](_0x590070['id']))return;const {id:_0xb4aec9}=_0x590070;let _0x14e3b7;_0x59085d[_0x5dcb8d(0x22d)](_0xb4aec9)?_0x14e3b7=_0x59085d[_0x5dcb8d(0x22b)](_0xb4aec9):(_0x14e3b7=new _0xd1ada7['Subject'](),_0x59085d[_0x5dcb8d(0x26f)](_0xb4aec9,_0x14e3b7),_0x14e3b7['pipe'](_0x529592['throttleTime']((_0x1dac49=this[_0x5dcb8d(0x266)][_0x5dcb8d(0x28a)](_0x57f8f8))!=null?_0x1dac49:_0x100476,void 0x0,{'trailing':!0x0,'leading':!0x0}))[_0x5dcb8d(0x224)](_0x79539a=>{const _0x5c4a38=_0x5dcb8d;this[_0x5c4a38(0x22a)][_0x5c4a38(0x1eb)]({'eventID':_0x2b554d[_0x5c4a38(0x267)][_0x5c4a38(0x219)],'data':{'unitID':this['_unitID'],'operations':{[_0x79539a['id']]:{'id':_0x79539a['id'],'params':JSON['stringify'](_0x79539a[_0x5c4a38(0x222)])}}}},this[_0x5c4a38(0x1fe)]);})),_0x14e3b7['next'](_0x590070);})),this[_0x299c78(0x217)]['getInitialStates'](this[_0x299c78(0x1fe)])[_0x299c78(0x236)](_0x3030fa=>this[_0x299c78(0x22a)][_0x299c78(0x1eb)]({'eventID':_0x2b554d[_0x299c78(0x267)]['LIVESHARE_OPERATION'],'data':{'unitID':this[_0x299c78(0x1fe)],'operations':{[_0x3030fa['id']]:{'id':_0x3030fa['id'],'params':JSON[_0x299c78(0x1e5)](_0x3030fa['params'])}}}},this['_unitID']));}[_0x198c54(0x20e)](){const _0xf8d8ea=_0x198c54;var _0x370861;this['_status$']['next'](_0xf8d8ea(0x27e)),(_0x370861=this['_commandDisposable'])==null||_0x370861[_0xf8d8ea(0x279)](),this[_0xf8d8ea(0x23e)]=null;}[_0x198c54(0x1de)](){const _0x2fa1e0=_0x198c54;var _0xa437aa;(_0xa437aa=this['_commandDisposable'])==null||_0xa437aa['dispose'](),this[_0x2fa1e0(0x283)][_0x2fa1e0(0x213)](_0x2fa1e0(0x27c));}[_0x198c54(0x271)](){const _0x1766cc=_0x198c54;var _0x4de27d;this[_0x1766cc(0x283)][_0x1766cc(0x213)]('idle'),(_0x4de27d=this[_0x1766cc(0x23e)])==null||_0x4de27d[_0x1766cc(0x279)](),this[_0x1766cc(0x23e)]=null;}[_0x198c54(0x2b6)](){const _0x201b56=_0x198c54;var _0x1403ac;this[_0x201b56(0x283)]['next'](_0x201b56(0x295)),(_0x1403ac=this[_0x201b56(0x23e)])==null||_0x1403ac[_0x201b56(0x279)]();}[_0x198c54(0x263)](_0x5281e1){const _0x1672e0=_0x198c54;if(['presenting','not-following',_0x1672e0(0x203)][_0x1672e0(0x225)](this[_0x1672e0(0x22e)])||!_0x5281e1[_0x1672e0(0x286)][_0x1672e0(0x1ff)]||_0x5281e1['data'][_0x1672e0(0x1ff)]===this[_0x1672e0(0x22a)]['getMemberID']())return;this[_0x1672e0(0x22e)]===_0x1672e0(0x27e)&&this[_0x1672e0(0x1de)]();const _0x35bbbd=_0x5281e1[_0x1672e0(0x286)][_0x1672e0(0x277)];Object['values'](_0x35bbbd)[_0x1672e0(0x236)](_0x31b782=>{const _0x8d5bcf=_0x1672e0;this[_0x8d5bcf(0x294)][_0x8d5bcf(0x2b9)](_0x31b782['id'],_0x31b782[_0x8d5bcf(0x222)]?JSON[_0x8d5bcf(0x21a)](_0x31b782[_0x8d5bcf(0x222)]):null,{'fromCollab':!0x0});});}[_0x198c54(0x204)](){const _0x3b137f=_0x198c54;var _0x4b8bae;this['_status$']['next']('offline'),(_0x4b8bae=this[_0x3b137f(0x23e)])==null||_0x4b8bae[_0x3b137f(0x279)]();}['_handleOnline'](){const _0x1b7037=_0x198c54;this['_status$'][_0x1b7037(0x213)](_0x1b7037(0x27e)),this[_0x1b7037(0x215)]();}},_0x219a3f[_0x198c54(0x201)]=_0x5e15f8([_0x68fa75(0x2,_0x40790f['IConfigService']),_0x68fa75(0x3,_0x40790f['Inject'](_0x3f94ee)),_0x68fa75(0x4,_0x40790f['ICommandService'])],_0x219a3f[_0x198c54(0x201)]);function _0x19a099(){const _0x11e00c=_0x198c54,_0x19d73a=_0x3ef861['useDependency'](_0x219a3f[_0x11e00c(0x228)]),_0x1da5af=_0x3ef861['useDependency'](_0x40790f[_0x11e00c(0x227)]),_0x4bd4d9=_0x3ef861[_0x11e00c(0x2ab)](()=>_0x1da5af[_0x11e00c(0x2bb)](_0x40790f[_0x11e00c(0x26c)][_0x11e00c(0x244)]),void 0x0,!0x1,[]),[_0x3077d7,_0x39c720]=_0x39f6be[_0x11e00c(0x239)](null),[_0x2044b7,_0x207958]=_0x39f6be['useState'](_0x33922d[_0x11e00c(0x1f2)]),_0x19f741=_0x39f6be['useRef'](null);return _0x39f6be['useEffect'](()=>(_0x4bd4d9&&_0x19d73a['getLiveShareCoordinator'](_0x4bd4d9[_0x11e00c(0x23d)]())[_0x11e00c(0x1ee)](_0x263c17=>{const _0x21182b=_0x11e00c;_0x39c720(_0x263c17),_0x19f741[_0x21182b(0x2af)]=_0x263c17[_0x21182b(0x29d)][_0x21182b(0x224)](_0x2ac303=>{_0x207958(_0x2ac303);});}),()=>{const _0x58555b=_0x11e00c;var _0x1cbb16;(_0x1cbb16=_0x19f741['current'])==null||_0x1cbb16[_0x58555b(0x291)](),_0x19f741['current']=null;}),[_0x4bd4d9,_0x19d73a]),_0x3077d7?_0x3ecb81[_0x11e00c(0x254)](_0x49fd3f[_0x11e00c(0x256)],{'align':_0x11e00c(0x253),'disabled':_0x2044b7===_0x33922d[_0x11e00c(0x27f)],'className':_0x11e00c(0x247),'overlay':_0x3ecb81['jsx'](_0x19e6ef,{'status':_0x2044b7,'coordinator':_0x3077d7}),'children':_0x3ecb81[_0x11e00c(0x254)](_0x11e00c(0x229),{'className':_0x49fd3f[_0x11e00c(0x211)]('univer-border-none\x20univer-text-gray-600\x20univer-outline-none',{'univer-cursor-not-allowed':_0x2044b7===_0x33922d[_0x11e00c(0x27f)],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0x2044b7!==_0x33922d['OFFLINE']}),'type':'button','children':_0x3ecb81[_0x11e00c(0x254)](_0x5b6f8f,{'className':_0x11e00c(0x28c)})})}):null;}function _0x19e6ef(_0x5330c3){const _0x41239f=_0x198c54,{status:_0x71be2b,coordinator:_0x32f1f1}=_0x5330c3;switch(_0x71be2b){case _0x33922d[_0x41239f(0x1f2)]:return _0x3ecb81[_0x41239f(0x254)](_0x34bc18,{'coordinator':_0x32f1f1});case _0x33922d[_0x41239f(0x1f4)]:return _0x3ecb81[_0x41239f(0x254)](_0x448354,{'coordinator':_0x32f1f1});case _0x33922d[_0x41239f(0x299)]:return _0x3ecb81['jsx'](_0x24735e,{'coordinator':_0x32f1f1});case _0x33922d['OFFLINE']:return _0x3ecb81[_0x41239f(0x254)](_0x59f1af,{});case _0x33922d['PRESENTING']:return _0x3ecb81[_0x41239f(0x254)](_0x4d8326,{'coordinator':_0x32f1f1});default:return null;}}function _0x34bc18(_0x40f896){const _0x26fbb9=_0x198c54,{coordinator:_0xf6c2b8}=_0x40f896;return _0x3ecb81['jsxs'](_0x3ecb81[_0x26fbb9(0x223)],{'children':[_0x3ecb81[_0x26fbb9(0x254)](_0x26fbb9(0x296),{'className':_0x26fbb9(0x208),'children':'Present\x20this\x20document'}),_0x3ecb81['jsx'](_0x49fd3f[_0x26fbb9(0x26a)],{'onClick':()=>_0xf6c2b8['tryStartPresenting'](),'children':_0x26fbb9(0x20b)})]});}function _0x448354(_0x2e86f2){const _0x321e6a=_0x198c54,{coordinator:_0x558e8a}=_0x2e86f2;return _0x3ecb81[_0x321e6a(0x25c)](_0x3ecb81[_0x321e6a(0x223)],{'children':[_0x3ecb81[_0x321e6a(0x254)](_0x321e6a(0x296),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':_0x321e6a(0x235)}),_0x3ecb81[_0x321e6a(0x254)](_0x49fd3f[_0x321e6a(0x26a)],{'onClick':()=>_0x558e8a[_0x321e6a(0x250)](),'children':_0x321e6a(0x264)})]});}function _0x24735e(_0x8e77c8){const _0x3e080d=_0x198c54,{coordinator:_0x4c2391}=_0x8e77c8;return _0x3ecb81['jsxs'](_0x3ecb81[_0x3e080d(0x223)],{'children':[_0x3ecb81[_0x3e080d(0x254)](_0x3e080d(0x296),{'className':_0x3e080d(0x208),'children':_0x3e080d(0x27a)}),_0x3ecb81['jsx'](_0x49fd3f['Button'],{'variant':_0x3e080d(0x28f),'onClick':()=>_0x4c2391['startFollowing'](),'children':_0x3e080d(0x268)})]});}function _0x4d8326(_0x105ab7){const _0x2e9fb5=_0x198c54,{coordinator:_0x7237d9}=_0x105ab7;return _0x3ecb81['jsxs'](_0x3ecb81[_0x2e9fb5(0x223)],{'children':[_0x3ecb81[_0x2e9fb5(0x254)](_0x2e9fb5(0x296),{'className':_0x2e9fb5(0x208),'children':_0x2e9fb5(0x1f6)}),_0x3ecb81[_0x2e9fb5(0x254)](_0x49fd3f[_0x2e9fb5(0x26a)],{'variant':_0x2e9fb5(0x298),'onClick':()=>_0x7237d9[_0x2e9fb5(0x238)](),'children':_0x2e9fb5(0x2b8)})]});}function _0x59f1af(){return _0x3ecb81['jsx'](_0x3ecb81['Fragment'],{'children':'You\x27are\x20offline.'});}var _0x94151f=Object['getOwnPropertyDescriptor'],_0x45446a=(_0x1892c9,_0x16231a,_0x1948f1,_0x278995)=>{const _0x1599ce=_0x198c54;for(var _0x14abef=_0x278995>0x1?void 0x0:_0x278995?_0x94151f(_0x16231a,_0x1948f1):_0x16231a,_0x3f9998=_0x1892c9[_0x1599ce(0x27b)]-0x1,_0x1bc865;_0x3f9998>=0x0;_0x3f9998--)(_0x1bc865=_0x1892c9[_0x3f9998])&&(_0x14abef=_0x1bc865(_0x14abef)||_0x14abef);return _0x14abef;},_0x4abf52=(_0x5bb96a,_0x951178)=>(_0x4e0165,_0xb1ee15)=>_0x951178(_0x4e0165,_0xb1ee15,_0x5bb96a);_0x219a3f[_0x198c54(0x200)]=class extends _0x40790f[_0x198c54(0x289)]{constructor(_0x45eb1b,_0x1ebfca){const _0x4b1700=_0x198c54;super(),this[_0x4b1700(0x1fa)]=_0x45eb1b,this[_0x4b1700(0x26d)]=_0x1ebfca,this['_mountLiveShare']();}[_0x198c54(0x2bd)](){const _0x168879=_0x198c54;this[_0x168879(0x269)](this['_uiPartsService'][_0x168879(0x26e)](_0x3ef861[_0x168879(0x1f7)][_0x168879(0x280)],()=>_0x3ef861['connectInjector'](_0x19a099,this[_0x168879(0x1fa)])));}},_0x219a3f['DesktopLiveShareController']=_0x45446a([_0x4abf52(0x0,_0x40790f[_0x198c54(0x2a7)](_0x40790f['Injector'])),_0x4abf52(0x1,_0x3ef861['IUIPartsService'])],_0x219a3f['DesktopLiveShareController']);const _0x4f2c29=_0x198c54(0x288),_0x45721b={};var _0x5d673b=Object['getOwnPropertyDescriptor'],_0x2089f4=(_0x1f7f06,_0x362f51,_0xac201e,_0x3ab5ef)=>{const _0x1f4566=_0x198c54;for(var _0x255a61=_0x3ab5ef>0x1?void 0x0:_0x3ab5ef?_0x5d673b(_0x362f51,_0xac201e):_0x362f51,_0x4bbbeb=_0x1f7f06[_0x1f4566(0x27b)]-0x1,_0x8ef130;_0x4bbbeb>=0x0;_0x4bbbeb--)(_0x8ef130=_0x1f7f06[_0x4bbbeb])&&(_0x255a61=_0x8ef130(_0x255a61)||_0x255a61);return _0x255a61;},_0x442d84=(_0x21dbe3,_0x212866)=>(_0x4efa4f,_0x43e934)=>_0x212866(_0x4efa4f,_0x43e934,_0x21dbe3);let _0x51cb9a=class extends _0x40790f[_0x198c54(0x289)]{constructor(_0x145878){const _0xa1b69c=_0x198c54;super(),this[_0xa1b69c(0x217)]=_0x145878,this[_0xa1b69c(0x1e6)]();}[_0x198c54(0x1e6)](){const _0x33a25b=_0x198c54;[_0x486c38[_0x33a25b(0x21e)]['id'],_0x486c38[_0x33a25b(0x29c)]['id'],_0x37f478[_0x33a25b(0x1f0)]['id']]['forEach'](_0x1af59b=>{const _0x5ad2a5=_0x33a25b;this[_0x5ad2a5(0x269)](this['_liveShareService'][_0x5ad2a5(0x2a6)](_0x1af59b));});}};_0x51cb9a=_0x2089f4([_0x442d84(0x0,_0x40790f['Inject'](_0x3f94ee))],_0x51cb9a);var _0x3cdbfa=Object['defineProperty'],_0x111c33=Object[_0x198c54(0x1e3)],_0xde1712=(_0x232320,_0x326b5b,_0xa33d3f)=>_0x326b5b in _0x232320?_0x3cdbfa(_0x232320,_0x326b5b,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0xa33d3f}):_0x232320[_0x326b5b]=_0xa33d3f,_0x119389=(_0x5983fa,_0xf6b71e,_0x156195,_0x525203)=>{const _0x27bdcb=_0x198c54;for(var _0x592592=_0x525203>0x1?void 0x0:_0x525203?_0x111c33(_0xf6b71e,_0x156195):_0xf6b71e,_0x2c4289=_0x5983fa[_0x27bdcb(0x27b)]-0x1,_0x5c3c59;_0x2c4289>=0x0;_0x2c4289--)(_0x5c3c59=_0x5983fa[_0x2c4289])&&(_0x592592=_0x5c3c59(_0x592592)||_0x592592);return _0x592592;},_0x29a959=(_0x516198,_0x5b45e6)=>(_0x405d0a,_0x4bec9b)=>_0x5b45e6(_0x405d0a,_0x4bec9b,_0x516198),_0x1482e5=(_0x21bfbd,_0x25fa2e,_0x5e9155)=>_0xde1712(_0x21bfbd,typeof _0x25fa2e!=_0x198c54(0x209)?_0x25fa2e+'':_0x25fa2e,_0x5e9155);const _0x44f926=_0x198c54(0x248);_0x219a3f['UniverLiveSharePlugin']=class extends _0x40790f['Plugin']{constructor(_0x182ed0=_0x45721b,_0x1eeabc,_0xeeef0a){const _0x2c478b=_0x198c54;super(),this[_0x2c478b(0x249)]=_0x182ed0,this[_0x2c478b(0x1fa)]=_0x1eeabc,this[_0x2c478b(0x266)]=_0xeeef0a;const {..._0x334b88}=_0x40790f[_0x2c478b(0x214)]({},_0x45721b,this[_0x2c478b(0x249)]);this[_0x2c478b(0x266)][_0x2c478b(0x261)](_0x4f2c29,_0x334b88);}[_0x198c54(0x27d)](){const _0x18c5dc=_0x198c54;_0x40790f[_0x18c5dc(0x221)](this[_0x18c5dc(0x1fa)],_0x40790f[_0x18c5dc(0x1ec)]([[_0x3f94ee],[_0x219a3f['LiveShareController']],[_0x51cb9a],[_0x219a3f[_0x18c5dc(0x200)]]],this[_0x18c5dc(0x249)][_0x18c5dc(0x25f)])),_0x40790f[_0x18c5dc(0x1e4)](this[_0x18c5dc(0x1fa)],[[_0x51cb9a]]);}[_0x198c54(0x272)](){const _0x2e214c=_0x198c54;_0x40790f[_0x2e214c(0x1e4)](this[_0x2e214c(0x1fa)],[[_0x219a3f['DesktopLiveShareController']]]);}},_0x1482e5(_0x219a3f[_0x198c54(0x2aa)],_0x198c54(0x226),_0x40790f[_0x198c54(0x26c)]['UNIVER_UNKNOWN']),_0x1482e5(_0x219a3f['UniverLiveSharePlugin'],'pluginName',_0x44f926),_0x219a3f[_0x198c54(0x2aa)]=_0x119389([_0x40790f[_0x198c54(0x2a8)](_0x4e4830[_0x198c54(0x2b1)]),_0x29a959(0x1,_0x40790f['Inject'](_0x40790f[_0x198c54(0x29a)])),_0x29a959(0x2,_0x40790f[_0x198c54(0x275)])],_0x219a3f[_0x198c54(0x2aa)]),_0x219a3f['LiveShare']=_0x19a099,_0x219a3f[_0x198c54(0x206)]=_0x3f94ee,_0x219a3f[_0x198c54(0x232)]=_0x33922d,Object[_0x198c54(0x1dd)](_0x219a3f,Symbol[_0x198c54(0x246)],{'value':'Module'});}));
|
|
1
|
+
function _0x673f(){const _0x13eaa5=['UniverLiveSharePlugin','LIVESHARE_FETCH_OPERATIONS','LiveShareService','createInstance','colorChannel1','object','forwardRef','@univerjs/design','getStatus','Start','get','@univerjs-pro/collaboration','svg','operations','react','Stop\x20presenting','_liveShareService','DisposableCollection','has','disposeWithMe','react/jsx-runtime','sessionStatus$','amd','getUnitId','sheet','substring','touchDependencies','Inject','pipe','UniverCore','override','add','tryStartPresenting','delete','find','UniverCollaborationClientPlugin','defs','merge','_startPresenting','Injector','replace','clear','DesktopLiveShareController','_sharedOperations','_configService','_handleOnline','Plugin','toDisposable','send','startFollowing','univer-mb-3\x20univer-w-full\x20univer-text-sm','UniverDesign','_status','getLiveShareCoordinator','dispose$','ICommandService','30KoVQLe','useState','data','dispose','registerDependencies','_commandService','NOT_FOLLOWING','_handleNewHost','LIVESHARE_NEW_HOST','subscribe','parseProtocolChangeset','then','2cAKzGv','_univerInstanceService','idSuffix','_startFollowing','UNIVER_SHEET','onStarting','Dropdown','BuiltInUIPart','LIVESHARE_TERMINATE','currentColor','_stopPresenting','You\x27are\x20offline.','asObservable','M9.20459\x204.90474C9.20459\x204.64763\x209.35535\x204.54174\x209.54053\x204.68737L11.2643\x206.04046C11.4495\x206.18609\x2011.4495\x206.42299\x2011.2643\x206.56789L9.55334\x207.90706C9.36755\x208.05269\x209.20386\x207.90499\x209.20386\x207.68969V6.96785H8.94446C8.19543\x206.96785\x206.72595\x207.28347\x206.37646\x207.89174C6.30786\x208.00322\x206.23572\x207.97884\x206.23572\x207.89174C6.25073\x206.80828\x208.0918\x205.58895\x209.17383\x205.58895H9.20459V4.90474Z','onCommandExecuted','univer-box-border\x20univer-min-w-60\x20univer-bg-gray-900\x20univer-px-4\x20univer-py-3\x20univer-text-gray-900\x20dark:!univer-bg-white\x20dark:!univer-text-white','NEW_CHANGESETS','operators','set','BehaviorSubject','LIVESHARE_OPERATION','React','@univerjs-pro/collaboration-client','Start\x20following','useDependency','map','_fetchOperations','symbol','next','jsx','SetZoomRatioOperation','getMemberID','rxjs','getOwnPropertyDescriptor','registerSharedOperation','InsertSheetMutation','13030190HMJwVy','getTypeOfUnitDisposed$','CollaborationEvent','Fragment','FOLLOWING','_collabSession','Disposable','exports','OPERATION','55028cIfWFV','IUIPartsService','createElement','@univerjs/sheets-ui','http://www.w3.org/2000/svg','_status$','none','random','takeUntil','CommandType','IConfigService','_uiPartsService','div','PRESENTING','tag','type','use','LiveShare','UniverIcon','attrs','LiveShareIcon','params','7648971PBlBhx','current','IDLE','url(#$1','stopFollowing','mask','from','stopPresenting','Subject','getCurrentTypeOfUnit$','offline','pluginName','displayName','values','assign','univer-size-4','executeCommand','xlink:href','_handleNewChangeSets','forEach','6xKfSEz','_entities','mergeOverrideWithDependencies','LiveShareCoordinator','CollaborationSessionService','_presenter','SAME_OPERATION_SHARE_INTERVAL','IUniverInstanceService','end','idle','_handleOffline','children','_init','path','live-share.config','Module','LiveShareController','_collabSessionService','_startLiveShareCoordinator','shouldShareOperation','M1.98682\x202.73096C1.98682\x202.17867\x202.43457\x201.73096\x202.98682\x201.73096H14.9868C15.5391\x201.73096\x2015.9868\x202.17867\x2015.9868\x202.73096V9.90105C15.9868\x2010.4533\x2015.5391\x2010.901\x2014.9868\x2010.901H9.62183V13.5577H12.9868C13.3375\x2013.5577\x2013.6218\x2013.842\x2013.6218\x2014.1927C13.6218\x2014.5434\x2013.3375\x2014.8277\x2012.9868\x2014.8277H4.98682C4.63611\x2014.8277\x204.35181\x2014.5434\x204.35181\x2014.1927C4.35181\x2013.842\x204.63611\x2013.5577\x204.98682\x2013.5577H8.35181V10.901H2.98682C2.43457\x2010.901\x201.98682\x2010.4533\x201.98682\x209.90105V2.73096ZM3.25684\x209.63106V3.00095H14.7168V9.63106H3.25684Z','4545264VsVaRe','You\x27re\x20not\x20following\x20the\x20presenter','complete','_beIdle','1em','univer-border-none\x20univer-text-gray-600\x20univer-outline-none','entries','univerjs-icon\x20univerjs-icon-','registerInitialStateReporter','_reporters','stringify','_commandDisposable','following','evenodd','rxjs/operators','default','_handleOperation','reverse','useObservable','presenter','UniverProCollaboration','not-following','presenting','Stop\x20following','defineProperty','string','9uIjhGN','getConfig','status$','requireSession','RxDisposable','209381vFfTFK','getLiveShareCoordinatorSync','0\x200\x2017\x2017','_mountLiveShare','event$','Button','1764185bAOIZJ','unitId','jsxs','UNIVER_LIVE_SHARE_PLUGIN','113022TTbAig','UniverProCollaborationClient','fill','_injector','OFFLINE','_handleTerminate','getInitialStates','_unitID','_config','UniverUi','UniverInstanceType','trim','useRef','connectInjector','length','button','_stopFollowing'];_0x673f=function(){return _0x13eaa5;};return _0x673f();}function _0x21b7(_0x11f6f8,_0x223ff3){_0x11f6f8=_0x11f6f8-0x168;const _0x673f3e=_0x673f();let _0x21b723=_0x673f3e[_0x11f6f8];return _0x21b723;}(function(_0x433616,_0x2fff7f){const _0x4f4255=_0x21b7,_0x50449d=_0x433616();while(!![]){try{const _0x12a3e2=-parseInt(_0x4f4255(0x17e))/0x1*(-parseInt(_0x4f4255(0x1dd))/0x2)+parseInt(_0x4f4255(0x1d1))/0x3*(parseInt(_0x4f4255(0x20a))/0x4)+-parseInt(_0x4f4255(0x184))/0x5*(-parseInt(_0x4f4255(0x234))/0x6)+-parseInt(_0x4f4255(0x188))/0x7+-parseInt(_0x4f4255(0x249))/0x8+-parseInt(_0x4f4255(0x179))/0x9*(-parseInt(_0x4f4255(0x201))/0xa)+-parseInt(_0x4f4255(0x220))/0xb;if(_0x12a3e2===_0x2fff7f)break;else _0x50449d['push'](_0x50449d['shift']());}catch(_0x5233c5){_0x50449d['push'](_0x50449d['shift']());}}}(_0x673f,0xb08c6),function(_0x438697,_0x37d823){const _0x1473bf=_0x21b7;typeof exports==_0x1473bf(0x19e)&&typeof module<'u'?_0x37d823(exports,require('@univerjs/core'),require('@univerjs/ui'),require('react/jsx-runtime'),require('@univerjs/design'),require('react'),require('@univerjs-pro/collaboration'),require('@univerjs-pro/collaboration-client'),require('@univerjs/sheets'),require('rxjs'),require('rxjs/operators'),require('@univerjs/sheets-ui')):typeof define=='function'&&define[_0x1473bf(0x1af)]?define([_0x1473bf(0x208),'@univerjs/core','@univerjs/ui',_0x1473bf(0x1ad),_0x1473bf(0x1a0),_0x1473bf(0x1a7),_0x1473bf(0x1a4),_0x1473bf(0x1f3),'@univerjs/sheets','rxjs',_0x1473bf(0x16d),_0x1473bf(0x20d)],_0x37d823):(_0x438697=typeof globalThis<'u'?globalThis:_0x438697||self,_0x37d823(_0x438697['UniverProLiveShare']={},_0x438697[_0x1473bf(0x1b6)],_0x438697[_0x1473bf(0x191)],_0x438697[_0x1473bf(0x1f2)],_0x438697[_0x1473bf(0x1cc)],_0x438697[_0x1473bf(0x1f2)],_0x438697[_0x1473bf(0x173)],_0x438697[_0x1473bf(0x189)],_0x438697['UniverSheets'],_0x438697[_0x1473bf(0x1fd)],_0x438697[_0x1473bf(0x1fd)][_0x1473bf(0x1ee)],_0x438697['UniverSheetsUi']));}(this,function(_0x4c092c,_0x2e2e2a,_0x502c89,_0x4dd2ba,_0x4846d0,_0x341c10,_0x4955c8,_0x47aa63,_0x46e7a5,_0x3efe4a,_0x534fd5,_0x1b842f){'use strict';const _0x21162f=_0x21b7;var _0x11832b=Object[_0x21162f(0x177)],_0x1a3013=(_0x2f296c,_0x3fbfc3,_0x9b2161)=>_0x3fbfc3 in _0x2f296c?_0x11832b(_0x2f296c,_0x3fbfc3,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x9b2161}):_0x2f296c[_0x3fbfc3]=_0x9b2161,_0x312f7a=(_0x5c69b7,_0x4a66e0,_0x1d7149)=>_0x1a3013(_0x5c69b7,typeof _0x4a66e0!=_0x21162f(0x1f8)?_0x4a66e0+'':_0x4a66e0,_0x1d7149);function _0x1cae13({ref:_0x2c148d,..._0x403e39}){const _0x5ed60b=_0x21162f,{icon:_0x4db2fe,id:_0xff1e83,className:_0x49f45d,extend:_0x2b141f,..._0x522be2}=_0x403e39,_0x47d2a0=(_0x5ed60b(0x250)+_0xff1e83+'\x20'+(_0x49f45d||''))[_0x5ed60b(0x193)](),_0x361b30=_0x341c10['useRef']('_'+_0x2bf7d7());return _0x3e67c0(_0x4db2fe,''+_0xff1e83,{'defIds':_0x4db2fe['defIds'],'idSuffix':_0x361b30[_0x5ed60b(0x221)]},{'ref':_0x2c148d,'className':_0x47d2a0,..._0x522be2},_0x2b141f);}function _0x3e67c0(_0x5ddd22,_0x164774,_0x3533c9,_0x211f4c,_0x3fb6ce){const _0x18393c=_0x21162f;return _0x341c10[_0x18393c(0x20c)](_0x5ddd22[_0x18393c(0x218)],{'key':_0x164774,..._0x5232e8(_0x5ddd22,_0x3533c9,_0x3fb6ce),..._0x211f4c},(_0x3e959c(_0x5ddd22,_0x3533c9)[_0x18393c(0x23f)]||[])['map']((_0x1cef31,_0xca5c53)=>_0x3e67c0(_0x1cef31,_0x164774+'-'+_0x5ddd22[_0x18393c(0x218)]+'-'+_0xca5c53,_0x3533c9,void 0x0,_0x3fb6ce)));}function _0x5232e8(_0x47fb27,_0x2881ad,_0x204147){const _0x4189b1=_0x21162f,_0x192f6b={..._0x47fb27[_0x4189b1(0x21d)]};_0x204147!=null&&_0x204147['colorChannel1']&&_0x192f6b[_0x4189b1(0x18a)]===_0x4189b1(0x19d)&&(_0x192f6b[_0x4189b1(0x18a)]=_0x204147[_0x4189b1(0x19d)]),_0x47fb27['tag']==='mask'&&_0x192f6b['id']&&(_0x192f6b['id']=_0x192f6b['id']+_0x2881ad[_0x4189b1(0x1df)]),Object[_0x4189b1(0x24f)](_0x192f6b)[_0x4189b1(0x233)](([_0x47b30a,_0x3c148a])=>{const _0x48aace=_0x4189b1;_0x47b30a===_0x48aace(0x225)&&typeof _0x3c148a=='string'&&(_0x192f6b[_0x47b30a]=_0x3c148a[_0x48aace(0x1c1)](/url\(#(.*)\)/,_0x48aace(0x223)+_0x2881ad[_0x48aace(0x1df)]+')'));});const {defIds:_0x17a51b}=_0x2881ad;return!_0x17a51b||_0x17a51b[_0x4189b1(0x196)]===0x0||(_0x47fb27[_0x4189b1(0x218)]===_0x4189b1(0x21a)&&_0x192f6b[_0x4189b1(0x231)]&&(_0x192f6b['xlink:href']=_0x192f6b['xlink:href']+_0x2881ad[_0x4189b1(0x1df)]),Object[_0x4189b1(0x24f)](_0x192f6b)[_0x4189b1(0x233)](([_0x33c8c0,_0x1fb42f])=>{const _0x2bbc51=_0x4189b1;typeof _0x1fb42f=='string'&&(_0x192f6b[_0x33c8c0]=_0x1fb42f[_0x2bbc51(0x1c1)](/url\(#(.*)\)/,_0x2bbc51(0x223)+_0x2881ad[_0x2bbc51(0x1df)]+')'));})),_0x192f6b;}function _0x3e959c(_0xbfe05c,_0x377447){const _0x4a6d28=_0x21162f;var _0x2bf849;const {defIds:_0x5e8401}=_0x377447;return!_0x5e8401||_0x5e8401[_0x4a6d28(0x196)]===0x0?_0xbfe05c:_0xbfe05c['tag']===_0x4a6d28(0x1bd)&&((_0x2bf849=_0xbfe05c[_0x4a6d28(0x23f)])!=null&&_0x2bf849['length'])?{..._0xbfe05c,'children':_0xbfe05c[_0x4a6d28(0x23f)][_0x4a6d28(0x1f6)](_0x5bf6f5=>typeof _0x5bf6f5[_0x4a6d28(0x21d)]['id']==_0x4a6d28(0x178)&&_0x5e8401&&_0x5e8401['includes'](_0x5bf6f5[_0x4a6d28(0x21d)]['id'])?{..._0x5bf6f5,'attrs':{..._0x5bf6f5[_0x4a6d28(0x21d)],'id':_0x5bf6f5['attrs']['id']+_0x377447[_0x4a6d28(0x1df)]}}:_0x5bf6f5)}:_0xbfe05c;}function _0x2bf7d7(){const _0x992517=_0x21162f;return Math[_0x992517(0x211)]()['toString'](0x24)[_0x992517(0x1b2)](0x2,0x8);}_0x1cae13['displayName']=_0x21162f(0x21c);const _0x1a490b={'tag':_0x21162f(0x1a5),'attrs':{'xmlns':_0x21162f(0x20e),'fill':_0x21162f(0x210),'viewBox':_0x21162f(0x180),'width':_0x21162f(0x24d),'height':_0x21162f(0x24d)},'children':[{'tag':'path','attrs':{'fill':'currentColor','d':_0x21162f(0x1ea)}},{'tag':_0x21162f(0x241),'attrs':{'fill':_0x21162f(0x1e6),'d':_0x21162f(0x248),'fillRule':_0x21162f(0x16c),'clipRule':'evenodd'}}]},_0x258bab=_0x341c10[_0x21162f(0x19f)](function(_0x94df1,_0x78fb31){const _0x362cf0=_0x21162f;return _0x341c10[_0x362cf0(0x20c)](_0x1cae13,Object[_0x362cf0(0x22e)]({},_0x94df1,{'id':'live-share-icon','ref':_0x78fb31,'icon':_0x1a490b}));});_0x258bab[_0x21162f(0x22c)]=_0x21162f(0x21e);class _0x1398e7 extends _0x2e2e2a[_0x21162f(0x207)]{constructor(){const _0x4aca56=_0x21162f;super(...arguments),_0x312f7a(this,_0x4aca56(0x1c4),new Set()),_0x312f7a(this,_0x4aca56(0x168),new Set());}[_0x21162f(0x1ff)](_0x51dd36){const _0x2269fd=_0x21162f;return this[_0x2269fd(0x1c4)][_0x2269fd(0x1b8)](_0x51dd36),_0x2e2e2a[_0x2269fd(0x1c8)](()=>this[_0x2269fd(0x1c4)][_0x2269fd(0x1ba)](_0x51dd36));}[_0x21162f(0x251)](_0x114588){const _0x4b9d7d=_0x21162f;return this['_reporters']['add'](_0x114588),_0x2e2e2a[_0x4b9d7d(0x1c8)](()=>this['_reporters']['delete'](_0x114588));}[_0x21162f(0x247)](_0xf78186){const _0x24fcdd=_0x21162f;return this[_0x24fcdd(0x1c4)][_0x24fcdd(0x1ab)](_0xf78186);}['getInitialStates'](_0x3229aa){const _0x4f5386=_0x21162f;return Array[_0x4f5386(0x226)](this[_0x4f5386(0x168)])['map'](_0xd2aada=>_0xd2aada(_0x3229aa));}}var _0x2daf1f=Object[_0x21162f(0x1fe)],_0x555952=(_0x55a0a5,_0x3ded10,_0x11af96,_0x2782cf)=>{const _0x45fdb6=_0x21162f;for(var _0x518955=_0x2782cf>0x1?void 0x0:_0x2782cf?_0x2daf1f(_0x3ded10,_0x11af96):_0x3ded10,_0x5deb24=_0x55a0a5[_0x45fdb6(0x196)]-0x1,_0x28590d;_0x5deb24>=0x0;_0x5deb24--)(_0x28590d=_0x55a0a5[_0x5deb24])&&(_0x518955=_0x28590d(_0x518955)||_0x518955);return _0x518955;},_0x3e201c=(_0x1ec2c3,_0x49fc68)=>(_0x2b9b36,_0x17f842)=>_0x49fc68(_0x2b9b36,_0x17f842,_0x1ec2c3);_0x4c092c[_0x21162f(0x244)]=class extends _0x2e2e2a['RxDisposable']{constructor(_0x25ee6e,_0x20783e,_0xc05f4e){const _0x40ec18=_0x21162f;super(),_0x312f7a(this,_0x40ec18(0x235),new Map()),(this[_0x40ec18(0x1de)]=_0x25ee6e,this[_0x40ec18(0x18b)]=_0x20783e,this[_0x40ec18(0x245)]=_0xc05f4e,this[_0x40ec18(0x240)]());}async[_0x21162f(0x1ce)](_0x3481c4){const _0x405855=_0x21162f;return this[_0x405855(0x235)][_0x405855(0x1ab)](_0x3481c4)||await this['_startLiveShareCoordinator'](_0x3481c4),this['_entities'][_0x405855(0x1a3)](_0x3481c4);}[_0x21162f(0x17f)](_0x2a0cd9){const _0x23a1a5=_0x21162f;var _0x19347b;return(_0x19347b=this['_entities'][_0x23a1a5(0x1a3)](_0x2a0cd9))!=null?_0x19347b:null;}[_0x21162f(0x240)](){const _0x49017d=_0x21162f;this[_0x49017d(0x1de)]['getTypeOfUnitAdded$'](_0x2e2e2a[_0x49017d(0x192)]['UNIVER_SHEET'])[_0x49017d(0x1b5)](_0x534fd5['takeUntil'](this[_0x49017d(0x1cf)]))[_0x49017d(0x1da)](async _0x59830d=>{const _0x3b1af5=_0x49017d,_0x2e20b9=_0x59830d[_0x3b1af5(0x1b0)]();this[_0x3b1af5(0x235)]['has'](_0x2e20b9)||this[_0x3b1af5(0x246)](_0x2e20b9);}),this[_0x49017d(0x1de)][_0x49017d(0x202)](_0x2e2e2a[_0x49017d(0x192)][_0x49017d(0x1e1)])[_0x49017d(0x1b5)](_0x534fd5[_0x49017d(0x212)](this[_0x49017d(0x1cf)]))['subscribe'](_0x5629e6=>{const _0x408d8b=_0x49017d,_0x22b920=_0x5629e6['getUnitId'](),_0x5c2667=this['_entities'][_0x408d8b(0x1a3)](_0x22b920);_0x5c2667==null||_0x5c2667[_0x408d8b(0x1d4)]();});}async[_0x21162f(0x246)](_0x51f0bc){const _0x89a6cc=_0x21162f,_0x1f3a67=await this[_0x89a6cc(0x245)][_0x89a6cc(0x17c)](_0x51f0bc),_0x1ce7fa=this[_0x89a6cc(0x18b)][_0x89a6cc(0x19c)](_0x4c092c[_0x89a6cc(0x237)],_0x51f0bc,_0x1f3a67);return _0x1ce7fa['init'](),this[_0x89a6cc(0x235)][_0x89a6cc(0x1ef)](_0x51f0bc,_0x1ce7fa),_0x1ce7fa;}},_0x4c092c[_0x21162f(0x244)]=_0x555952([_0x3e201c(0x0,_0x2e2e2a[_0x21162f(0x23b)]),_0x3e201c(0x1,_0x2e2e2a[_0x21162f(0x1b4)](_0x2e2e2a['Injector'])),_0x3e201c(0x2,_0x2e2e2a['Inject'](_0x47aa63[_0x21162f(0x238)]))],_0x4c092c['LiveShareController']);var _0x33f89a=(_0x5e2986=>(_0x5e2986[_0x21162f(0x18c)]=_0x21162f(0x22a),_0x5e2986[_0x21162f(0x222)]=_0x21162f(0x23d),_0x5e2986[_0x21162f(0x205)]=_0x21162f(0x16b),_0x5e2986[_0x21162f(0x1d7)]=_0x21162f(0x174),_0x5e2986[_0x21162f(0x217)]='presenting',_0x5e2986))(_0x33f89a||{});const _0x298f5c=_0x21162f(0x23a),_0x33c563=0xc8;_0x4c092c[_0x21162f(0x237)]=class extends _0x2e2e2a[_0x21162f(0x17d)]{constructor(_0x500471,_0xcae1ac,_0x44d80e,_0x4fd3d9,_0x54f937){const _0x28f7ff=_0x21162f;super(),_0x312f7a(this,_0x28f7ff(0x20f),new _0x3efe4a[(_0x28f7ff(0x1f0))]('idle')),_0x312f7a(this,_0x28f7ff(0x17b),this['_status$'][_0x28f7ff(0x1e9)]()),_0x312f7a(this,_0x28f7ff(0x240),!0x1),_0x312f7a(this,_0x28f7ff(0x16a),null),_0x312f7a(this,'_presenter',null),(this['_unitID']=_0x500471,this[_0x28f7ff(0x206)]=_0xcae1ac,this[_0x28f7ff(0x1c5)]=_0x44d80e,this[_0x28f7ff(0x1a9)]=_0x4fd3d9,this[_0x28f7ff(0x1d6)]=_0x54f937);}get[_0x21162f(0x1cd)](){const _0x27cb77=_0x21162f;return this[_0x27cb77(0x20f)]['getValue']();}[_0x21162f(0x1d4)](){const _0x17523a=_0x21162f;var _0x43ab2e;(_0x43ab2e=this['_commandDisposable'])==null||_0x43ab2e['dispose'](),this[_0x17523a(0x20f)][_0x17523a(0x1f9)](_0x17523a(0x23d)),this[_0x17523a(0x20f)][_0x17523a(0x24b)]();}[_0x21162f(0x1a1)](){return this['_status'];}['init'](){const _0x258a51=_0x21162f;this['_init']||(this[_0x258a51(0x240)]=!0x0,this[_0x258a51(0x206)][_0x258a51(0x1ae)]['pipe'](_0x534fd5[_0x258a51(0x212)](this[_0x258a51(0x1cf)]))[_0x258a51(0x1da)](_0x1a856e=>{const _0x4fbb22=_0x258a51;switch(_0x1a856e){case _0x47aa63['SessionStatus']['OFFLINE']:this['_handleOffline']();break;case _0x47aa63['SessionStatus']['ONLINE']:this[_0x4fbb22(0x1c6)]();break;}}),this[_0x258a51(0x206)][_0x258a51(0x182)][_0x258a51(0x1b5)](_0x534fd5[_0x258a51(0x212)](this['dispose$']))[_0x258a51(0x1da)](_0x498dd1=>{const _0x4a05fb=_0x258a51,{eventID:_0x27c922}=_0x498dd1;switch(_0x27c922){case _0x4955c8[_0x4a05fb(0x203)][_0x4a05fb(0x1d9)]:this[_0x4a05fb(0x1d8)](_0x498dd1);break;case _0x4955c8[_0x4a05fb(0x203)][_0x4a05fb(0x1f1)]:this[_0x4a05fb(0x16f)](_0x498dd1);break;case _0x4955c8['CollaborationEvent']['LIVESHARE_TERMINATE']:this[_0x4a05fb(0x18d)]();break;case _0x4955c8['CollaborationEvent'][_0x4a05fb(0x1ed)]:this[_0x4a05fb(0x232)](_0x498dd1);break;}}));}[_0x21162f(0x1b9)](){const _0x226a3a=_0x21162f;this[_0x226a3a(0x206)][_0x226a3a(0x1c9)]({'eventID':_0x4955c8['CollaborationEvent']['LIVESHARE_REQUEST_HOST'],'data':{'unitID':this[_0x226a3a(0x18f)],'userID':this[_0x226a3a(0x206)][_0x226a3a(0x1fc)]()}},this[_0x226a3a(0x18f)]);}[_0x21162f(0x227)](){const _0x5d1168=_0x21162f;this[_0x5d1168(0x1cd)]===_0x5d1168(0x175)&&(this[_0x5d1168(0x20f)][_0x5d1168(0x1f9)](_0x5d1168(0x23d)),this['_collabSession']['send']({'eventID':_0x4955c8[_0x5d1168(0x203)][_0x5d1168(0x1e5)],'data':{'unitID':this[_0x5d1168(0x18f)]}},this[_0x5d1168(0x18f)]));}['startFollowing'](){const _0x14271e=_0x21162f;this[_0x14271e(0x1cd)]==='not-following'&&(this[_0x14271e(0x20f)][_0x14271e(0x1f9)](_0x14271e(0x16b)),this[_0x14271e(0x1e0)]());}[_0x21162f(0x224)](){const _0x20a8de=_0x21162f;this['_status']===_0x20a8de(0x16b)&&this[_0x20a8de(0x198)]();}[_0x21162f(0x1d8)](_0x3d11fd){const _0x54a1c9=_0x21162f,{presenter:_0x3b5291}=_0x3d11fd[_0x54a1c9(0x1d3)],_0x11e24f=this[_0x54a1c9(0x206)][_0x54a1c9(0x1fc)]();this[_0x54a1c9(0x239)]=_0x3b5291,_0x3b5291===_0x11e24f?(this[_0x54a1c9(0x198)](),this[_0x54a1c9(0x1bf)]()):this[_0x54a1c9(0x1cd)]!==_0x54a1c9(0x174)&&(this[_0x54a1c9(0x1e7)](),this['_startFollowing']());}[_0x21162f(0x1f7)](){const _0x1e2071=_0x21162f,_0x3f48a1={'eventID':_0x4955c8['CollaborationEvent'][_0x1e2071(0x19a)]};this[_0x1e2071(0x206)]['send'](_0x3f48a1,this[_0x1e2071(0x18f)]);}['_handleTerminate'](){const _0x37acf4=_0x21162f;this['_presenter']=null,this[_0x37acf4(0x1cd)]!==_0x37acf4(0x175)&&this[_0x37acf4(0x24c)]();}[_0x21162f(0x232)](_0x2d84a1){const _0x146ba1=_0x21162f;if(this[_0x146ba1(0x1cd)]==='following'&&this['_presenter']===_0x2d84a1['data']['memberID']){const _0x232d46=_0x4955c8[_0x146ba1(0x1db)](_0x2d84a1[_0x146ba1(0x1d3)])['mutations'][_0x146ba1(0x170)]()[_0x146ba1(0x1bb)](_0x14c4df=>_0x14c4df['id']===_0x46e7a5[_0x146ba1(0x200)]['id']);if(_0x232d46){const _0x17569b=_0x232d46[_0x146ba1(0x21f)][_0x146ba1(0x185)],_0x4440fa=_0x232d46[_0x146ba1(0x21f)][_0x146ba1(0x1b1)]['id'];setTimeout(()=>{const _0x383f98=_0x146ba1;this['_commandService'][_0x383f98(0x230)](_0x46e7a5['SetWorksheetActiveOperation']['id'],{'unitId':_0x17569b,'subUnitId':_0x4440fa},{'fromCollab':!0x0});});}}}['_startPresenting'](){const _0xbf6bab=_0x21162f;this[_0xbf6bab(0x20f)]['next']('presenting');const _0x60e3f6=new Map(),_0x32634d=this[_0xbf6bab(0x16a)]=new _0x2e2e2a[(_0xbf6bab(0x1aa))]();_0x32634d[_0xbf6bab(0x1b8)](_0x2e2e2a[_0xbf6bab(0x1c8)](()=>{const _0x5a1476=_0xbf6bab;_0x60e3f6[_0x5a1476(0x233)](_0x100bbf=>_0x100bbf[_0x5a1476(0x24b)]()),_0x60e3f6[_0x5a1476(0x1c2)]();})),_0x32634d['add'](this[_0xbf6bab(0x1d6)][_0xbf6bab(0x1eb)](_0x5ae05d=>{const _0x59f320=_0xbf6bab;var _0x555e3e;if(_0x5ae05d['type']!==_0x2e2e2a[_0x59f320(0x213)][_0x59f320(0x209)]||!this[_0x59f320(0x1a9)]['shouldShareOperation'](_0x5ae05d['id']))return;const {id:_0x316366}=_0x5ae05d;let _0x4b352e;_0x60e3f6[_0x59f320(0x1ab)](_0x316366)?_0x4b352e=_0x60e3f6['get'](_0x316366):(_0x4b352e=new _0x3efe4a[(_0x59f320(0x228))](),_0x60e3f6['set'](_0x316366,_0x4b352e),_0x4b352e[_0x59f320(0x1b5)](_0x534fd5['throttleTime']((_0x555e3e=this[_0x59f320(0x1c5)][_0x59f320(0x17a)](_0x298f5c))!=null?_0x555e3e:_0x33c563,void 0x0,{'trailing':!0x0,'leading':!0x0}))[_0x59f320(0x1da)](_0x406c0f=>{const _0x3e0b47=_0x59f320;this[_0x3e0b47(0x206)][_0x3e0b47(0x1c9)]({'eventID':_0x4955c8[_0x3e0b47(0x203)][_0x3e0b47(0x1f1)],'data':{'unitID':this[_0x3e0b47(0x18f)],'operations':{[_0x406c0f['id']]:{'id':_0x406c0f['id'],'params':JSON[_0x3e0b47(0x169)](_0x406c0f[_0x3e0b47(0x21f)])}}}},this[_0x3e0b47(0x18f)]);})),_0x4b352e[_0x59f320(0x1f9)](_0x5ae05d);})),this[_0xbf6bab(0x1a9)][_0xbf6bab(0x18e)](this[_0xbf6bab(0x18f)])[_0xbf6bab(0x233)](_0x87d723=>this[_0xbf6bab(0x206)][_0xbf6bab(0x1c9)]({'eventID':_0x4955c8[_0xbf6bab(0x203)][_0xbf6bab(0x1f1)],'data':{'unitID':this[_0xbf6bab(0x18f)],'operations':{[_0x87d723['id']]:{'id':_0x87d723['id'],'params':JSON[_0xbf6bab(0x169)](_0x87d723[_0xbf6bab(0x21f)])}}}},this[_0xbf6bab(0x18f)]));}[_0x21162f(0x1e7)](){const _0x588f2d=_0x21162f;var _0x32a8cd;this[_0x588f2d(0x20f)][_0x588f2d(0x1f9)](_0x588f2d(0x23d)),(_0x32a8cd=this[_0x588f2d(0x16a)])==null||_0x32a8cd[_0x588f2d(0x1d4)](),this['_commandDisposable']=null;}[_0x21162f(0x1e0)](){const _0x5170f2=_0x21162f;var _0x588726;(_0x588726=this['_commandDisposable'])==null||_0x588726['dispose'](),this[_0x5170f2(0x20f)][_0x5170f2(0x1f9)](_0x5170f2(0x16b));}[_0x21162f(0x24c)](){const _0x5ac5e4=_0x21162f;var _0x37d885;this['_status$'][_0x5ac5e4(0x1f9)](_0x5ac5e4(0x23d)),(_0x37d885=this[_0x5ac5e4(0x16a)])==null||_0x37d885[_0x5ac5e4(0x1d4)](),this[_0x5ac5e4(0x16a)]=null;}[_0x21162f(0x198)](){const _0x35e413=_0x21162f;var _0x28b59f;this[_0x35e413(0x20f)][_0x35e413(0x1f9)](_0x35e413(0x174)),(_0x28b59f=this[_0x35e413(0x16a)])==null||_0x28b59f[_0x35e413(0x1d4)]();}[_0x21162f(0x16f)](_0x257948){const _0x5b9079=_0x21162f;if([_0x5b9079(0x175),'not-following',_0x5b9079(0x22a)]['includes'](this[_0x5b9079(0x1cd)])||!_0x257948[_0x5b9079(0x1d3)][_0x5b9079(0x172)]||_0x257948[_0x5b9079(0x1d3)]['presenter']===this[_0x5b9079(0x206)][_0x5b9079(0x1fc)]())return;this[_0x5b9079(0x1cd)]===_0x5b9079(0x23d)&&this['_startFollowing']();const _0x1afa8a=_0x257948[_0x5b9079(0x1d3)][_0x5b9079(0x1a6)];Object[_0x5b9079(0x22d)](_0x1afa8a)[_0x5b9079(0x233)](_0x269472=>{const _0x5f3080=_0x5b9079;this[_0x5f3080(0x1d6)][_0x5f3080(0x230)](_0x269472['id'],_0x269472['params']?JSON['parse'](_0x269472[_0x5f3080(0x21f)]):null,{'fromCollab':!0x0});});}[_0x21162f(0x23e)](){const _0x2f4fb8=_0x21162f;var _0x2dbd05;this['_status$'][_0x2f4fb8(0x1f9)](_0x2f4fb8(0x22a)),(_0x2dbd05=this[_0x2f4fb8(0x16a)])==null||_0x2dbd05['dispose']();}[_0x21162f(0x1c6)](){const _0x1e92c3=_0x21162f;this[_0x1e92c3(0x20f)][_0x1e92c3(0x1f9)](_0x1e92c3(0x23d)),this[_0x1e92c3(0x1f7)]();}},_0x4c092c[_0x21162f(0x237)]=_0x555952([_0x3e201c(0x2,_0x2e2e2a[_0x21162f(0x214)]),_0x3e201c(0x3,_0x2e2e2a['Inject'](_0x1398e7)),_0x3e201c(0x4,_0x2e2e2a[_0x21162f(0x1d0)])],_0x4c092c[_0x21162f(0x237)]);function _0x444d64(){const _0x25e53=_0x21162f,_0x35ebc9=_0x502c89['useDependency'](_0x4c092c[_0x25e53(0x244)]),_0x26da3d=_0x502c89[_0x25e53(0x1f5)](_0x2e2e2a['IUniverInstanceService']),_0x164bed=_0x502c89[_0x25e53(0x171)](()=>_0x26da3d[_0x25e53(0x229)](_0x2e2e2a['UniverInstanceType'][_0x25e53(0x1e1)]),void 0x0,!0x1,[]),[_0x556b1e,_0x5d7db8]=_0x341c10['useState'](null),[_0xc51d35,_0x2db41e]=_0x341c10[_0x25e53(0x1d2)](_0x33f89a[_0x25e53(0x222)]),_0x1a37eb=_0x341c10[_0x25e53(0x194)](null);return _0x341c10['useEffect'](()=>(_0x164bed&&_0x35ebc9[_0x25e53(0x1ce)](_0x164bed[_0x25e53(0x1b0)]())[_0x25e53(0x1dc)](_0x12b4d3=>{const _0x59826c=_0x25e53;_0x5d7db8(_0x12b4d3),_0x1a37eb['current']=_0x12b4d3[_0x59826c(0x17b)]['subscribe'](_0x9a1bf4=>{_0x2db41e(_0x9a1bf4);});}),()=>{const _0x52c0f6=_0x25e53;var _0x374bf0;(_0x374bf0=_0x1a37eb['current'])==null||_0x374bf0['unsubscribe'](),_0x1a37eb[_0x52c0f6(0x221)]=null;}),[_0x164bed,_0x35ebc9]),_0x556b1e?_0x4dd2ba[_0x25e53(0x1fa)](_0x4846d0[_0x25e53(0x1e3)],{'align':_0x25e53(0x23c),'disabled':_0xc51d35===_0x33f89a[_0x25e53(0x18c)],'className':_0x25e53(0x1ec),'overlay':_0x4dd2ba[_0x25e53(0x1fa)](_0x429767,{'status':_0xc51d35,'coordinator':_0x556b1e}),'children':_0x4dd2ba['jsx'](_0x25e53(0x197),{'className':_0x4846d0['clsx'](_0x25e53(0x24e),{'univer-cursor-not-allowed':_0xc51d35===_0x33f89a['OFFLINE'],'univer-cursor-pointer\x20hover:univer-bg-gray-400':_0xc51d35!==_0x33f89a[_0x25e53(0x18c)]}),'type':'button','children':_0x4dd2ba[_0x25e53(0x1fa)](_0x258bab,{'className':_0x25e53(0x22f)})})}):null;}function _0x429767(_0x3729a9){const _0x41de90=_0x21162f,{status:_0x2717b0,coordinator:_0x10bd41}=_0x3729a9;switch(_0x2717b0){case _0x33f89a[_0x41de90(0x222)]:return _0x4dd2ba['jsx'](_0x10f7f3,{'coordinator':_0x10bd41});case _0x33f89a['FOLLOWING']:return _0x4dd2ba[_0x41de90(0x1fa)](_0x52eeaa,{'coordinator':_0x10bd41});case _0x33f89a[_0x41de90(0x1d7)]:return _0x4dd2ba['jsx'](_0x3aeed7,{'coordinator':_0x10bd41});case _0x33f89a[_0x41de90(0x18c)]:return _0x4dd2ba[_0x41de90(0x1fa)](_0x1f1b2,{});case _0x33f89a[_0x41de90(0x217)]:return _0x4dd2ba[_0x41de90(0x1fa)](_0x23c6e0,{'coordinator':_0x10bd41});default:return null;}}function _0x10f7f3(_0x1cc0e9){const _0x379d9a=_0x21162f,{coordinator:_0x129e0d}=_0x1cc0e9;return _0x4dd2ba[_0x379d9a(0x186)](_0x4dd2ba[_0x379d9a(0x204)],{'children':[_0x4dd2ba[_0x379d9a(0x1fa)](_0x379d9a(0x216),{'className':_0x379d9a(0x1cb),'children':'Present\x20this\x20document'}),_0x4dd2ba[_0x379d9a(0x1fa)](_0x4846d0[_0x379d9a(0x183)],{'onClick':()=>_0x129e0d['tryStartPresenting'](),'children':_0x379d9a(0x1a2)})]});}function _0x52eeaa(_0x3f3d33){const _0x457213=_0x21162f,{coordinator:_0x233d1b}=_0x3f3d33;return _0x4dd2ba[_0x457213(0x186)](_0x4dd2ba[_0x457213(0x204)],{'children':[_0x4dd2ba['jsx'](_0x457213(0x216),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':'You\x27re\x20following\x20the\x20presenter'}),_0x4dd2ba[_0x457213(0x1fa)](_0x4846d0[_0x457213(0x183)],{'onClick':()=>_0x233d1b[_0x457213(0x224)](),'children':_0x457213(0x176)})]});}function _0x3aeed7(_0x85f9b){const _0x330855=_0x21162f,{coordinator:_0x4f4bef}=_0x85f9b;return _0x4dd2ba['jsxs'](_0x4dd2ba[_0x330855(0x204)],{'children':[_0x4dd2ba[_0x330855(0x1fa)](_0x330855(0x216),{'className':_0x330855(0x1cb),'children':_0x330855(0x24a)}),_0x4dd2ba['jsx'](_0x4846d0[_0x330855(0x183)],{'variant':'text','onClick':()=>_0x4f4bef[_0x330855(0x1ca)](),'children':_0x330855(0x1f4)})]});}function _0x23c6e0(_0x215175){const _0x1919ca=_0x21162f,{coordinator:_0x5976b6}=_0x215175;return _0x4dd2ba['jsxs'](_0x4dd2ba['Fragment'],{'children':[_0x4dd2ba['jsx'](_0x1919ca(0x216),{'className':'univer-mb-3\x20univer-w-full\x20univer-text-sm','children':'You\x27re\x20presenting\x20the\x20document'}),_0x4dd2ba[_0x1919ca(0x1fa)](_0x4846d0[_0x1919ca(0x183)],{'variant':_0x1919ca(0x16e),'onClick':()=>_0x5976b6[_0x1919ca(0x227)](),'children':_0x1919ca(0x1a8)})]});}function _0x1f1b2(){const _0x3c525e=_0x21162f;return _0x4dd2ba[_0x3c525e(0x1fa)](_0x4dd2ba['Fragment'],{'children':_0x3c525e(0x1e8)});}var _0x470695=Object[_0x21162f(0x1fe)],_0x25e421=(_0x5bc8cf,_0x4cf7f5,_0x15b71a,_0xbcbf8d)=>{const _0x32dcdb=_0x21162f;for(var _0x396d76=_0xbcbf8d>0x1?void 0x0:_0xbcbf8d?_0x470695(_0x4cf7f5,_0x15b71a):_0x4cf7f5,_0x4c2f5d=_0x5bc8cf[_0x32dcdb(0x196)]-0x1,_0x5d5ecf;_0x4c2f5d>=0x0;_0x4c2f5d--)(_0x5d5ecf=_0x5bc8cf[_0x4c2f5d])&&(_0x396d76=_0x5d5ecf(_0x396d76)||_0x396d76);return _0x396d76;},_0x544488=(_0x3262a6,_0x4cf09c)=>(_0x4e211b,_0x554a7b)=>_0x4cf09c(_0x4e211b,_0x554a7b,_0x3262a6);_0x4c092c[_0x21162f(0x1c3)]=class extends _0x2e2e2a['Disposable']{constructor(_0x1a9817,_0x428c5e){const _0xee00b0=_0x21162f;super(),this[_0xee00b0(0x18b)]=_0x1a9817,this[_0xee00b0(0x215)]=_0x428c5e,this[_0xee00b0(0x181)]();}[_0x21162f(0x181)](){const _0x1a0a19=_0x21162f;this['disposeWithMe'](this['_uiPartsService']['registerComponent'](_0x502c89[_0x1a0a19(0x1e4)]['HEADER_MENU'],()=>_0x502c89[_0x1a0a19(0x195)](_0x444d64,this[_0x1a0a19(0x18b)])));}},_0x4c092c[_0x21162f(0x1c3)]=_0x25e421([_0x544488(0x0,_0x2e2e2a[_0x21162f(0x1b4)](_0x2e2e2a[_0x21162f(0x1c0)])),_0x544488(0x1,_0x502c89[_0x21162f(0x20b)])],_0x4c092c[_0x21162f(0x1c3)]);const _0x39c17a=_0x21162f(0x242),_0x334c40={};var _0x51f803=Object[_0x21162f(0x1fe)],_0x444d1d=(_0x40383a,_0x2a26a9,_0x4e7db7,_0x4dc353)=>{const _0x2ac081=_0x21162f;for(var _0x5b2e01=_0x4dc353>0x1?void 0x0:_0x4dc353?_0x51f803(_0x2a26a9,_0x4e7db7):_0x2a26a9,_0x1743c0=_0x40383a[_0x2ac081(0x196)]-0x1,_0x3f9cba;_0x1743c0>=0x0;_0x1743c0--)(_0x3f9cba=_0x40383a[_0x1743c0])&&(_0x5b2e01=_0x3f9cba(_0x5b2e01)||_0x5b2e01);return _0x5b2e01;},_0x8d9692=(_0x516ad8,_0x39df3e)=>(_0x2b42c0,_0x59b384)=>_0x39df3e(_0x2b42c0,_0x59b384,_0x516ad8);let _0x2b42a7=class extends _0x2e2e2a[_0x21162f(0x207)]{constructor(_0x2a6edb){const _0x52f1c2=_0x21162f;super(),this[_0x52f1c2(0x1a9)]=_0x2a6edb,this['_init']();}[_0x21162f(0x240)](){const _0xaa0d2e=_0x21162f;[_0x1b842f[_0xaa0d2e(0x1fb)]['id'],_0x1b842f['SetScrollOperation']['id'],_0x46e7a5['SetWorksheetActiveOperation']['id']][_0xaa0d2e(0x233)](_0x5848f5=>{const _0x5a7ec8=_0xaa0d2e;this[_0x5a7ec8(0x1ac)](this[_0x5a7ec8(0x1a9)][_0x5a7ec8(0x1ff)](_0x5848f5));});}};_0x2b42a7=_0x444d1d([_0x8d9692(0x0,_0x2e2e2a[_0x21162f(0x1b4)](_0x1398e7))],_0x2b42a7);var _0x3b9230=Object[_0x21162f(0x177)],_0x1ecff6=Object['getOwnPropertyDescriptor'],_0x10febe=(_0x1a03d7,_0x2088d5,_0x2e57d8)=>_0x2088d5 in _0x1a03d7?_0x3b9230(_0x1a03d7,_0x2088d5,{'enumerable':!0x0,'configurable':!0x0,'writable':!0x0,'value':_0x2e57d8}):_0x1a03d7[_0x2088d5]=_0x2e57d8,_0x5a585d=(_0x176b48,_0x1fae57,_0xceca94,_0x41aa29)=>{const _0x5ce54f=_0x21162f;for(var _0x29fd49=_0x41aa29>0x1?void 0x0:_0x41aa29?_0x1ecff6(_0x1fae57,_0xceca94):_0x1fae57,_0x37cf38=_0x176b48[_0x5ce54f(0x196)]-0x1,_0x1362d8;_0x37cf38>=0x0;_0x37cf38--)(_0x1362d8=_0x176b48[_0x37cf38])&&(_0x29fd49=_0x1362d8(_0x29fd49)||_0x29fd49);return _0x29fd49;},_0x53b8c0=(_0x5915dc,_0x2b2f84)=>(_0x3044f4,_0x3bbf02)=>_0x2b2f84(_0x3044f4,_0x3bbf02,_0x5915dc),_0x1e0dd1=(_0x9b63a4,_0x3d2404,_0x5cb17d)=>_0x10febe(_0x9b63a4,typeof _0x3d2404!=_0x21162f(0x1f8)?_0x3d2404+'':_0x3d2404,_0x5cb17d);const _0x1ef154=_0x21162f(0x187);_0x4c092c['UniverLiveSharePlugin']=class extends _0x2e2e2a[_0x21162f(0x1c7)]{constructor(_0x2f3b9b=_0x334c40,_0x2d0683,_0x3240ee){const _0x358f61=_0x21162f;super(),this[_0x358f61(0x190)]=_0x2f3b9b,this[_0x358f61(0x18b)]=_0x2d0683,this[_0x358f61(0x1c5)]=_0x3240ee;const {..._0x547ed6}=_0x2e2e2a[_0x358f61(0x1be)]({},_0x334c40,this['_config']);this['_configService']['setConfig'](_0x39c17a,_0x547ed6);}[_0x21162f(0x1e2)](){const _0x3f9533=_0x21162f;_0x2e2e2a[_0x3f9533(0x1d5)](this['_injector'],_0x2e2e2a[_0x3f9533(0x236)]([[_0x1398e7],[_0x4c092c[_0x3f9533(0x244)]],[_0x2b42a7],[_0x4c092c[_0x3f9533(0x1c3)]]],this[_0x3f9533(0x190)][_0x3f9533(0x1b7)])),_0x2e2e2a[_0x3f9533(0x1b3)](this[_0x3f9533(0x18b)],[[_0x2b42a7]]);}['onRendered'](){const _0x127d87=_0x21162f;_0x2e2e2a['touchDependencies'](this['_injector'],[[_0x4c092c[_0x127d87(0x1c3)]]]);}},_0x1e0dd1(_0x4c092c[_0x21162f(0x199)],_0x21162f(0x219),_0x2e2e2a[_0x21162f(0x192)]['UNIVER_UNKNOWN']),_0x1e0dd1(_0x4c092c[_0x21162f(0x199)],_0x21162f(0x22b),_0x1ef154),_0x4c092c['UniverLiveSharePlugin']=_0x5a585d([_0x2e2e2a['DependentOn'](_0x47aa63[_0x21162f(0x1bc)]),_0x53b8c0(0x1,_0x2e2e2a[_0x21162f(0x1b4)](_0x2e2e2a['Injector'])),_0x53b8c0(0x2,_0x2e2e2a[_0x21162f(0x214)])],_0x4c092c['UniverLiveSharePlugin']),_0x4c092c[_0x21162f(0x21b)]=_0x444d64,_0x4c092c[_0x21162f(0x19b)]=_0x1398e7,_0x4c092c['LiveShareStatus']=_0x33f89a,Object[_0x21162f(0x177)](_0x4c092c,Symbol['toStringTag'],{'value':_0x21162f(0x243)});}));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@univerjs-pro/live-share",
|
|
3
|
-
"version": "0.12.
|
|
3
|
+
"version": "0.12.4-experimental.20251208-c4b8a44",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "UniverSheet normal ui-plugin-sheets",
|
|
6
6
|
"author": "DreamNum <developer@univer.ai>",
|
|
@@ -57,14 +57,14 @@
|
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
59
|
"@univerjs/icons": "^1.0.2",
|
|
60
|
-
"@univerjs-pro/collaboration
|
|
61
|
-
"@univerjs/
|
|
62
|
-
"@univerjs
|
|
63
|
-
"@univerjs/
|
|
64
|
-
"@univerjs/
|
|
65
|
-
"@univerjs/
|
|
66
|
-
"@univerjs/
|
|
67
|
-
"@univerjs/
|
|
60
|
+
"@univerjs-pro/collaboration": "0.12.4-experimental.20251208-c4b8a44",
|
|
61
|
+
"@univerjs-pro/collaboration-client": "0.12.4-experimental.20251208-c4b8a44",
|
|
62
|
+
"@univerjs/core": "0.12.4-experimental.20251208-c4b8a44",
|
|
63
|
+
"@univerjs/design": "0.12.4-experimental.20251208-c4b8a44",
|
|
64
|
+
"@univerjs/engine-render": "0.12.4-experimental.20251208-c4b8a44",
|
|
65
|
+
"@univerjs/sheets-ui": "0.12.4-experimental.20251208-c4b8a44",
|
|
66
|
+
"@univerjs/ui": "0.12.4-experimental.20251208-c4b8a44",
|
|
67
|
+
"@univerjs/sheets": "0.12.4-experimental.20251208-c4b8a44"
|
|
68
68
|
},
|
|
69
69
|
"devDependencies": {
|
|
70
70
|
"postcss": "^8.5.6",
|
|
@@ -74,8 +74,8 @@
|
|
|
74
74
|
"typescript": "^5.9.3",
|
|
75
75
|
"vite": "^7.2.6",
|
|
76
76
|
"vitest": "^4.0.15",
|
|
77
|
-
"@univerjs/
|
|
78
|
-
"@univerjs
|
|
77
|
+
"@univerjs-infra/shared": "0.12.4",
|
|
78
|
+
"@univerjs/protocol": "0.1.47"
|
|
79
79
|
},
|
|
80
80
|
"scripts": {
|
|
81
81
|
"test": "vitest run",
|