@univerjs-pro/collaboration-client 1.0.0-beta.0 → 1.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (87) hide show
  1. package/lib/cjs/facade.js +1 -1
  2. package/lib/cjs/index.js +1 -1
  3. package/lib/cjs/locale/ar-SA.js +1 -1
  4. package/lib/cjs/locale/ca-ES.js +1 -1
  5. package/lib/cjs/locale/de-DE.js +1 -1
  6. package/lib/cjs/locale/en-US.js +1 -1
  7. package/lib/cjs/locale/es-ES.js +1 -1
  8. package/lib/cjs/locale/fa-IR.js +1 -1
  9. package/lib/cjs/locale/fr-FR.js +1 -1
  10. package/lib/cjs/locale/id-ID.js +1 -1
  11. package/lib/cjs/locale/it-IT.js +1 -1
  12. package/lib/cjs/locale/ja-JP.js +1 -1
  13. package/lib/cjs/locale/ko-KR.js +1 -1
  14. package/lib/cjs/locale/pl-PL.js +1 -1
  15. package/lib/cjs/locale/pt-BR.js +1 -1
  16. package/lib/cjs/locale/ru-RU.js +1 -1
  17. package/lib/cjs/locale/sk-SK.js +1 -1
  18. package/lib/cjs/locale/vi-VN.js +1 -1
  19. package/lib/cjs/locale/zh-CN.js +1 -1
  20. package/lib/cjs/locale/zh-HK.js +1 -1
  21. package/lib/cjs/locale/zh-TW.js +1 -1
  22. package/lib/es/facade.js +1 -1
  23. package/lib/es/index.js +1 -1
  24. package/lib/es/locale/ar-SA.js +1 -1
  25. package/lib/es/locale/ca-ES.js +1 -1
  26. package/lib/es/locale/de-DE.js +1 -1
  27. package/lib/es/locale/en-US.js +1 -1
  28. package/lib/es/locale/es-ES.js +1 -1
  29. package/lib/es/locale/fa-IR.js +1 -1
  30. package/lib/es/locale/fr-FR.js +1 -1
  31. package/lib/es/locale/id-ID.js +1 -1
  32. package/lib/es/locale/it-IT.js +1 -1
  33. package/lib/es/locale/ja-JP.js +1 -1
  34. package/lib/es/locale/ko-KR.js +1 -1
  35. package/lib/es/locale/pl-PL.js +1 -1
  36. package/lib/es/locale/pt-BR.js +1 -1
  37. package/lib/es/locale/ru-RU.js +1 -1
  38. package/lib/es/locale/sk-SK.js +1 -1
  39. package/lib/es/locale/vi-VN.js +1 -1
  40. package/lib/es/locale/zh-CN.js +1 -1
  41. package/lib/es/locale/zh-HK.js +1 -1
  42. package/lib/es/locale/zh-TW.js +1 -1
  43. package/lib/facade.js +1 -1
  44. package/lib/index.js +1 -1
  45. package/lib/locale/ar-SA.js +1 -1
  46. package/lib/locale/ca-ES.js +1 -1
  47. package/lib/locale/de-DE.js +1 -1
  48. package/lib/locale/en-US.js +1 -1
  49. package/lib/locale/es-ES.js +1 -1
  50. package/lib/locale/fa-IR.js +1 -1
  51. package/lib/locale/fr-FR.js +1 -1
  52. package/lib/locale/id-ID.js +1 -1
  53. package/lib/locale/it-IT.js +1 -1
  54. package/lib/locale/ja-JP.js +1 -1
  55. package/lib/locale/ko-KR.js +1 -1
  56. package/lib/locale/pl-PL.js +1 -1
  57. package/lib/locale/pt-BR.js +1 -1
  58. package/lib/locale/ru-RU.js +1 -1
  59. package/lib/locale/sk-SK.js +1 -1
  60. package/lib/locale/vi-VN.js +1 -1
  61. package/lib/locale/zh-CN.js +1 -1
  62. package/lib/locale/zh-HK.js +1 -1
  63. package/lib/locale/zh-TW.js +1 -1
  64. package/lib/types/facade/f-collaboration.d.ts +14 -0
  65. package/lib/types/services/undoredo/collaborative-undoredo.service.d.ts +2 -2
  66. package/lib/umd/facade.js +1 -1
  67. package/lib/umd/index.js +1 -1
  68. package/lib/umd/locale/ar-SA.js +1 -1
  69. package/lib/umd/locale/ca-ES.js +1 -1
  70. package/lib/umd/locale/de-DE.js +1 -1
  71. package/lib/umd/locale/en-US.js +1 -1
  72. package/lib/umd/locale/es-ES.js +1 -1
  73. package/lib/umd/locale/fa-IR.js +1 -1
  74. package/lib/umd/locale/fr-FR.js +1 -1
  75. package/lib/umd/locale/id-ID.js +1 -1
  76. package/lib/umd/locale/it-IT.js +1 -1
  77. package/lib/umd/locale/ja-JP.js +1 -1
  78. package/lib/umd/locale/ko-KR.js +1 -1
  79. package/lib/umd/locale/pl-PL.js +1 -1
  80. package/lib/umd/locale/pt-BR.js +1 -1
  81. package/lib/umd/locale/ru-RU.js +1 -1
  82. package/lib/umd/locale/sk-SK.js +1 -1
  83. package/lib/umd/locale/vi-VN.js +1 -1
  84. package/lib/umd/locale/zh-CN.js +1 -1
  85. package/lib/umd/locale/zh-HK.js +1 -1
  86. package/lib/umd/locale/zh-TW.js +1 -1
  87. package/package.json +15 -15
@@ -1,6 +1,7 @@
1
1
  import type { FBase as FBaseFacade } from '@univerjs-pro/bases/facade';
2
2
  import type { FBoard } from '@univerjs-pro/boards/facade';
3
3
  import type { ILogContext } from '@univerjs-pro/collaboration';
4
+ import type { FPdf } from '@univerjs-pro/pdfs/facade';
4
5
  import type { FPresentation } from '@univerjs-pro/slides/facade';
5
6
  import type { IDisposable } from '@univerjs/core';
6
7
  import type { FDocument } from '@univerjs/docs/facade';
@@ -34,6 +35,7 @@ export declare class FCollaboration extends FBase {
34
35
  getPresentation: (id: string) => FPresentation | null;
35
36
  getBase: (id: string) => FBaseFacade | null;
36
37
  getBoard: (id: string) => FBoard | null;
38
+ getPdf: (id: string) => FPdf | null;
37
39
  }, _injector: Injector, _univerInstanceService: IUniverInstanceService, _snapshotService: SnapshotService, _collaborationController: CollaborationController);
38
40
  /**
39
41
  * Load a Univer Sheet from the server with a unit ID.
@@ -95,6 +97,18 @@ export declare class FCollaboration extends FBase {
95
97
  * ```
96
98
  */
97
99
  loadBoardAsync(unitId: string, context?: ILogContext): Promise<FBoard | null>;
100
+ /**
101
+ * Load a Univer PDF from the server with a unit ID.
102
+ * @param {string} unitId ID of the Univer PDF that you would like to load.
103
+ * @param {ILogContext} [context] Optional context.
104
+ * @returns {Promise<FPdf | null>} The {@link FPdf} or null if ID cannot be associated with a Univer PDF.
105
+ * @example
106
+ * ```typescript
107
+ * const collaboration = univerAPI.getCollaboration();
108
+ * const pdf = await collaboration.loadPdfAsync('your-unit-id');
109
+ * ```
110
+ */
111
+ loadPdfAsync(unitId: string, context?: ILogContext): Promise<FPdf | null>;
98
112
  /**
99
113
  * Subscribe collaborators of a Univer file.
100
114
  *
@@ -1,7 +1,7 @@
1
1
  import type { IChangeset } from '@univerjs-pro/collaboration';
2
2
  import type { IUndoRedoService } from '@univerjs/core';
3
3
  import { ITransformService } from '@univerjs-pro/collaboration';
4
- import { ICommandService, IContextService, ILogService, IUniverInstanceService, LocalUndoRedoService } from '@univerjs/core';
4
+ import { ICommandService, IConfigService, IContextService, ILogService, IUniverInstanceService, LocalUndoRedoService } from '@univerjs/core';
5
5
  /**
6
6
  * `LocalUndoRedoService` cannot transform mutations in the undo redo stack under collaboration conditions.
7
7
  */
@@ -11,7 +11,7 @@ export interface ICollaborativeUndoRedoService extends IUndoRedoService {
11
11
  export declare class CollaborativeUndoRedoService extends LocalUndoRedoService implements ICollaborativeUndoRedoService {
12
12
  private readonly _transformService;
13
13
  private readonly _logService;
14
- constructor(_currentUniverSheet: IUniverInstanceService, _commandService: ICommandService, _contextService: IContextService, _transformService: ITransformService, _logService: ILogService);
14
+ constructor(_currentUniverSheet: IUniverInstanceService, _commandService: ICommandService, _contextService: IContextService, _configService: IConfigService, _transformService: ITransformService, _logService: ILogService);
15
15
  transformUndoRedo(unitID: string, changesets: IChangeset): void;
16
16
  private _clearUndo;
17
17
  private _clearRedo;
package/lib/umd/facade.js CHANGED
@@ -1 +1 @@
1
- function _0x51f1(_0x428df8,_0x4a71c3){_0x428df8=_0x428df8-0x110;const _0xb3f346=_0xb3f3();let _0x51f1d4=_0xb3f346[_0x428df8];return _0x51f1d4;}(function(_0x261889,_0x5271bb){const _0x1ef0ea=_0x51f1,_0x10f931=_0x261889();while(!![]){try{const _0x13a1a5=parseInt(_0x1ef0ea(0x154))/0x1*(-parseInt(_0x1ef0ea(0x122))/0x2)+parseInt(_0x1ef0ea(0x168))/0x3+parseInt(_0x1ef0ea(0x15c))/0x4*(-parseInt(_0x1ef0ea(0x138))/0x5)+parseInt(_0x1ef0ea(0x115))/0x6+parseInt(_0x1ef0ea(0x130))/0x7+-parseInt(_0x1ef0ea(0x159))/0x8+parseInt(_0x1ef0ea(0x136))/0x9;if(_0x13a1a5===_0x5271bb)break;else _0x10f931['push'](_0x10f931['shift']());}catch(_0x38cc1e){_0x10f931['push'](_0x10f931['shift']());}}}(_0xb3f3,0x2e26a),function(_0x5d8111,_0x24b5ae){const _0x5d1113=_0x51f1;typeof exports=='object'&&typeof module<'u'?_0x24b5ae(exports,require('@univerjs-pro/collaboration-client'),require('@univerjs/core/facade'),require('@univerjs/core'),require('@univerjs-pro/collaboration'),require('rxjs')):typeof define==_0x5d1113(0x169)&&define[_0x5d1113(0x132)]?define([_0x5d1113(0x140),_0x5d1113(0x13c),_0x5d1113(0x139),_0x5d1113(0x14b),_0x5d1113(0x16e),'rxjs'],_0x24b5ae):(_0x5d8111=typeof globalThis<'u'?globalThis:_0x5d8111||self,_0x24b5ae(_0x5d8111[_0x5d1113(0x14c)]={},_0x5d8111['UniverProCollaborationClient'],_0x5d8111['UniverCoreFacade'],_0x5d8111[_0x5d1113(0x150)],_0x5d8111['UniverProCollaboration'],_0x5d8111[_0x5d1113(0x13b)]));}(this,function(_0x522e94,_0xdda150,_0x4f7f51,_0x423b42,_0x5934e5,_0x29f433){const _0x3bf646=_0x51f1;Object[_0x3bf646(0x160)](_0x522e94,Symbol['toStringTag'],{'value':_0x3bf646(0x163)});var _0x487f2f=class extends _0x4f7f51[_0x3bf646(0x110)]{get[_0x3bf646(0x16f)](){const _0xb979c8=_0x3bf646;return _0xdda150[_0xb979c8(0x16f)];}};_0x4f7f51[_0x3bf646(0x110)][_0x3bf646(0x117)](_0x487f2f);var _0x51b9fb=class extends _0x4f7f51[_0x3bf646(0x162)]{get['CollaborationStatusChanged'](){const _0xf4d7e0=_0x3bf646;return _0xf4d7e0(0x112);}};_0x4f7f51[_0x3bf646(0x162)][_0x3bf646(0x117)](_0x51b9fb);function _0x47a05f(_0x5a13d9,_0x55d0bc){return function(_0x2efdbd,_0x1ab8af){_0x55d0bc(_0x2efdbd,_0x1ab8af,_0x5a13d9);};}function _0x3a9dd8(_0x3c8730,_0x1d7ffb,_0x40a554,_0x5c6e85){const _0x691bfa=_0x3bf646;var _0x1bc063=arguments[_0x691bfa(0x113)],_0x56a92f=_0x1bc063<0x3?_0x1d7ffb:_0x5c6e85===null?_0x5c6e85=Object['getOwnPropertyDescriptor'](_0x1d7ffb,_0x40a554):_0x5c6e85,_0x173f34;if(typeof Reflect==_0x691bfa(0x16d)&&typeof Reflect['decorate']=='function')_0x56a92f=Reflect['decorate'](_0x3c8730,_0x1d7ffb,_0x40a554,_0x5c6e85);else{for(var _0x13de7e=_0x3c8730[_0x691bfa(0x113)]-0x1;_0x13de7e>=0x0;_0x13de7e--)(_0x173f34=_0x3c8730[_0x13de7e])&&(_0x56a92f=(_0x1bc063<0x3?_0x173f34(_0x56a92f):_0x1bc063>0x3?_0x173f34(_0x1d7ffb,_0x40a554,_0x56a92f):_0x173f34(_0x1d7ffb,_0x40a554))||_0x56a92f);}return _0x1bc063>0x3&&_0x56a92f&&Object[_0x691bfa(0x160)](_0x1d7ffb,_0x40a554,_0x56a92f),_0x56a92f;}let _0x5ca87b=class extends _0x4f7f51[_0x3bf646(0x15a)]{constructor(_0x1e018c,_0x55d7b9,_0x23ebf1,_0x29d35a,_0x29d176){const _0x44e959=_0x3bf646;super(),this[_0x44e959(0x12d)]=_0x1e018c,this[_0x44e959(0x111)]=_0x55d7b9,this[_0x44e959(0x118)]=_0x23ebf1,this[_0x44e959(0x158)]=_0x29d35a,this['_collaborationController']=_0x29d176;}async[_0x3bf646(0x14d)](_0x53c2a3,_0x4b7f75){const _0x3266c4=_0x3bf646;return await this[_0x3266c4(0x158)][_0x3266c4(0x13d)](_0x53c2a3,0x0,_0x4b7f75)?(await this[_0x3266c4(0x129)][_0x3266c4(0x147)](_0x53c2a3),this[_0x3266c4(0x12d)][_0x3266c4(0x116)](_0x53c2a3)):null;}async[_0x3bf646(0x15f)](_0x2f275e,_0x2ff08a){const _0x2cc2b2=_0x3bf646;return await this[_0x2cc2b2(0x158)]['loadDoc'](_0x2f275e,0x0,_0x2ff08a)?(await this[_0x2cc2b2(0x129)][_0x2cc2b2(0x147)](_0x2f275e),this['_handler'][_0x2cc2b2(0x151)](_0x2f275e)):null;}async[_0x3bf646(0x121)](_0x112861,_0x39aec5){const _0x533769=_0x3bf646;return await this[_0x533769(0x158)][_0x533769(0x114)](_0x112861,0x0,_0x39aec5)?(await this[_0x533769(0x129)][_0x533769(0x147)](_0x112861),this['_handler'][_0x533769(0x12f)](_0x112861)):null;}async[_0x3bf646(0x13a)](_0x1ef4d3,_0xfc36b0){const _0x442b91=_0x3bf646;return await this[_0x442b91(0x158)][_0x442b91(0x16c)](_0x1ef4d3,0x0,_0xfc36b0)?(await this[_0x442b91(0x129)]['readyForCollab'](_0x1ef4d3),this['_handler'][_0x442b91(0x11e)](_0x1ef4d3)):null;}async[_0x3bf646(0x167)](_0x246c1e,_0x16a889){const _0xe1230a=_0x3bf646;return await this[_0xe1230a(0x158)][_0xe1230a(0x164)](_0x246c1e,0x0,_0x16a889)?(await this[_0xe1230a(0x129)][_0xe1230a(0x147)](_0x246c1e),this[_0xe1230a(0x12d)][_0xe1230a(0x170)](_0x246c1e)):null;}[_0x3bf646(0x146)](_0x38af7f,_0x20a319){const _0x2194c9=_0x3bf646;return(0x0,_0x423b42['toDisposable'])(this[_0x2194c9(0x111)][_0x2194c9(0x142)](_0xdda150[_0x2194c9(0x161)])[_0x2194c9(0x11c)](_0x38af7f)[_0x2194c9(0x14f)]((0x0,_0x29f433[_0x2194c9(0x137)])(_0x272dbf=>_0x272dbf['members$']))['subscribe'](_0x674f26=>_0x20a319(Array[_0x2194c9(0x128)](_0x674f26['values']()))));}[_0x3bf646(0x12a)](_0x2733a5){const _0x21435f=_0x3bf646;let _0xdbf358=this['_resolveUnitId'](_0x2733a5);if(!_0xdbf358)return _0xdda150[_0x21435f(0x16f)][_0x21435f(0x133)];let _0x2a10e5=this['_collaborationController'][_0x21435f(0x12e)](_0xdbf358);return(_0x2a10e5==null?void 0x0:_0x2a10e5['state'][_0x21435f(0x156)])??_0xdda150[_0x21435f(0x16f)][_0x21435f(0x133)];}['flush'](_0xe8f36b,_0x21b4c6={}){const _0x5c9914=_0x3bf646;let _0x12ebd6=this[_0x5c9914(0x15b)](_0xe8f36b);if(!_0x12ebd6)return Promise['reject'](Error('[FCollaboration]:\x20Cannot\x20flush\x20because\x20no\x20unit\x20is\x20focused\x20or\x20specified.'));let _0x37ebc2=this['_collaborationController'][_0x5c9914(0x12e)](_0x12ebd6);if(!_0x37ebc2)return Promise[_0x5c9914(0x16a)](Error('[FCollaboration]:\x20Unit\x20\x22'+_0x12ebd6+_0x5c9914(0x127)));let _0x825376=_0x37ebc2['state']['status'];if(_0x825376===_0xdda150[_0x5c9914(0x16f)][_0x5c9914(0x171)])return Promise[_0x5c9914(0x11a)]();let _0x45ddbd=_0x3695d0(_0x12ebd6,_0x825376);if(_0x45ddbd)return Promise[_0x5c9914(0x16a)](_0x45ddbd);let _0x42473e=_0x21b4c6[_0x5c9914(0x14a)]??0x7530;return new Promise((_0x56128a,_0x21eb95)=>{const _0x2d2450=_0x5c9914;let _0x22fbc1=!0x1,_0x24827c=null,_0x5d291f=setTimeout(()=>{const _0x3994cf=_0x51f1;_0x22fbc1=!0x0,_0x24827c==null||_0x24827c[_0x3994cf(0x152)](),_0x21eb95(Error(_0x3994cf(0x125)+_0x12ebd6+_0x3994cf(0x123)+_0x42473e+_0x3994cf(0x15e)));},_0x42473e),_0x57603f=()=>{const _0x4f4a94=_0x51f1;_0x22fbc1=!0x0,clearTimeout(_0x5d291f),_0x24827c==null||_0x24827c[_0x4f4a94(0x152)]();};_0x24827c=_0x37ebc2[_0x2d2450(0x131)][_0x2d2450(0x149)](_0x35fc08=>{const _0x3b6e0e=_0x2d2450;if(_0x22fbc1)return;if(_0x35fc08===_0xdda150[_0x3b6e0e(0x16f)]['SYNCED']){_0x57603f(),_0x56128a();return;}let _0x12b13b=_0x3695d0(_0x12ebd6,_0x35fc08);_0x12b13b&&(_0x57603f(),_0x21eb95(_0x12b13b));});});}['_resolveUnitId'](_0x2066a){const _0x58ba82=_0x3bf646;var _0x1e34f6;return _0x2066a||((_0x1e34f6=this[_0x58ba82(0x118)][_0x58ba82(0x120)]())==null?void 0x0:_0x1e34f6[_0x58ba82(0x157)]());}};_0x5ca87b=_0x3a9dd8([_0x47a05f(0x1,(0x0,_0x423b42['Inject'])(_0x423b42[_0x3bf646(0x13e)])),_0x47a05f(0x2,_0x423b42[_0x3bf646(0x16b)]),_0x47a05f(0x3,(0x0,_0x423b42[_0x3bf646(0x153)])(_0x5934e5['SnapshotService'])),_0x47a05f(0x4,(0x0,_0x423b42[_0x3bf646(0x153)])(_0xdda150[_0x3bf646(0x11f)]))],_0x5ca87b);function _0x3695d0(_0x4e5311,_0x14b208){const _0x56d2a5=_0x3bf646;return _0x14b208===_0xdda150[_0x56d2a5(0x16f)]['CONFLICT']||_0x14b208===_0xdda150[_0x56d2a5(0x16f)][_0x56d2a5(0x133)]?Error(_0x56d2a5(0x166)+_0x4e5311+_0x56d2a5(0x144)+_0x14b208+'.'):null;}var _0x338055=class extends _0x4f7f51[_0x3bf646(0x141)]{[_0x3bf646(0x135)](_0x4c00da){const _0x2ea161=_0x3bf646;let _0x530ad6=_0x4c00da[_0x2ea161(0x142)](_0xdda150[_0x2ea161(0x11f)]);this[_0x2ea161(0x155)](this[_0x2ea161(0x124)](this[_0x2ea161(0x13f)]['CollaborationStatusChanged'],()=>{const _0x483831=_0x2ea161;let _0x15d3bb=new _0x423b42[(_0x483831(0x126))](),_0x48e4e6=_0x530ad6[_0x483831(0x119)]['subscribe'](_0x49084e=>{const _0x3436a8=_0x483831;let _0x46c182=_0x49084e[_0x3436a8(0x131)][_0x3436a8(0x149)](_0x2212d2=>{const _0x51c901=_0x3436a8;let _0x1db387={'unitId':_0x49084e[_0x51c901(0x12b)],'status':_0x2212d2};this['fireEvent'](this['Event'][_0x51c901(0x112)],_0x1db387);});_0x15d3bb[_0x3436a8(0x165)]((0x0,_0x423b42[_0x3436a8(0x148)])(_0x46c182));});return _0x15d3bb[_0x483831(0x165)]((0x0,_0x423b42[_0x483831(0x148)])(_0x48e4e6)),_0x15d3bb;}));}[_0x3bf646(0x134)](){const _0x514543=_0x3bf646;return this['_injector'][_0x514543(0x11b)](_0x5ca87b,{'getWorkbook':_0x18b5f1=>this['getWorkbook'](_0x18b5f1),'getDocument':_0x4f4d57=>this[_0x514543(0x151)](_0x4f4d57),'getPresentation':_0x479c73=>this[_0x514543(0x11e)](_0x479c73),'getBase':_0x17920d=>this['getBase'](_0x17920d),'getBoard':_0x39db1f=>this[_0x514543(0x170)](_0x39db1f)});}[_0x3bf646(0x145)](_0x85367f,_0x46cd68,_0x5dc1ac){const _0x10ffd5=_0x3bf646;return this[_0x10ffd5(0x111)][_0x10ffd5(0x142)](_0xdda150[_0x10ffd5(0x11d)])[_0x10ffd5(0x14e)](_0x85367f,_0x46cd68,_0x5dc1ac);}[_0x3bf646(0x15d)](_0x19ed24,_0x1add6e,_0x2fc247){const _0x2c352d=_0x3bf646;return this['_injector'][_0x2c352d(0x142)](_0xdda150[_0x2c352d(0x11d)])[_0x2c352d(0x143)](_0x19ed24,_0x1add6e,_0x2fc247);}};_0x4f7f51[_0x3bf646(0x141)][_0x3bf646(0x117)](_0x338055),Object[_0x3bf646(0x160)](_0x522e94,_0x3bf646(0x12c),{'enumerable':!0x0,'get':function(){return _0x5ca87b;}});}));function _0xb3f3(){const _0x1e61cf=['UniverProCollaborationClientFacade','loadSheetAsync','loadUnit','pipe','UniverCore','getDocument','unsubscribe','Inject','1kRIvCe','disposeWithMe','status','getUnitId','_snapshotService','1902016gKRVun','FBase','_resolveUnitId','16THPyCl','loadServerUnitOfRevision','ms.','loadDocAsync','defineProperty','MemberService','FEventName','Module','loadBoard','add','[FCollaboration]:\x20Cannot\x20flush\x20unit\x20\x22','loadBoardAsync','569901pVfZBD','function','reject','IUniverInstanceService','loadSlide','object','@univerjs-pro/collaboration','CollaborationStatus','getBoard','SYNCED','FEnum','_injector','CollaborationStatusChanged','length','loadBase','2208408PKXKTF','getWorkbook','extend','_univerInstanceService','entityInit$','resolve','createInstance','waitForRoom$','DataLoaderService','getPresentation','CollaborationController','getFocusedUnit','loadBaseAsync','709942mSrJod','\x22\x20after\x20','registerEventHandler','[FCollaboration]:\x20Timed\x20out\x20flushing\x20unit\x20\x22','DisposableCollection','\x22\x20is\x20not\x20in\x20collaboration\x20mode.','from','_collaborationController','getCollaborationStatus','unitID','FCollaboration','_handler','getCollabEntity','getBase','1329923oMkKGv','status$','amd','NOT_COLLAB','getCollaboration','_initialize','3034341HmOGNx','switchMap','379270ZShTBr','@univerjs/core/facade','loadSlideAsync','rxjs','@univerjs-pro/collaboration-client','loadSheet','Injector','Event','exports','FUniver','get','loadUnitOfRevision','\x22\x20while\x20collaboration\x20status\x20is\x20','loadServerUnit','subscribeCollaborators','readyForCollab','toDisposable','subscribe','timeout','@univerjs/core'];_0xb3f3=function(){return _0x1e61cf;};return _0xb3f3();}
1
+ function _0x44c4(){const _0x4acdd8=['SYNCED','_univerInstanceService','FEventName','fireEvent','object','@univerjs/core','11573973pYYmyy','status','waitForRoom$','state','FCollaboration','getOwnPropertyDescriptor','UniverCore','NOT_COLLAB','[FCollaboration]:\x20Timed\x20out\x20flushing\x20unit\x20\x22','319395nNOyvW','getWorkbook','DataLoaderService','loadSheetAsync','34892CEfJbK','90Xxxynj','extend','_injector','_snapshotService','decorate','528464FYkfKB','_resolveUnitId','CollaborationController','rxjs','loadBase','loadBoard','[FCollaboration]:\x20Cannot\x20flush\x20because\x20no\x20unit\x20is\x20focused\x20or\x20specified.','Module','toStringTag','subscribe','getPresentation','Event','SnapshotService','length','unitID','4026872LpFvdW','loadUnitOfRevision','loadSlideAsync','FBase','timeout','subscribeCollaborators','@univerjs/core/facade','_initialize','add','loadPdfAsync','UniverProCollaborationClient','4iHpTao','CollaborationStatusChanged','[FCollaboration]:\x20Cannot\x20flush\x20unit\x20\x22','entityInit$','getUnitId','values','get','loadBoardAsync','FEnum','getBoard','resolve','getCollabEntity','FUniver','loadBaseAsync','IUniverInstanceService','amd','_handler','function','3YGoTrp','readyForCollab','ms.','CONFLICT','loadUnit','loadPdf','getFocusedUnit','\x22\x20is\x20not\x20in\x20collaboration\x20mode.','defineProperty','createInstance','_collaborationController','unsubscribe','@univerjs-pro/collaboration','CollaborationStatus','Injector','getPdf','status$','1411376udKRjZ','UniverCoreFacade','loadServerUnit','loadSlide','toDisposable','getBase','disposeWithMe','loadDocAsync','3107202fluQoZ','flush','850trdVtF','getDocument','from','Inject','reject'];_0x44c4=function(){return _0x4acdd8;};return _0x44c4();}function _0x490d(_0x3c41b3,_0x307081){_0x3c41b3=_0x3c41b3-0x9b;const _0x44c462=_0x44c4();let _0x490d0a=_0x44c462[_0x3c41b3];return _0x490d0a;}(function(_0x530a36,_0x5b9aee){const _0x558676=_0x490d,_0x31bbcb=_0x530a36();while(!![]){try{const _0x2219b5=-parseInt(_0x558676(0xad))/0x1*(-parseInt(_0x558676(0xf8))/0x2)+-parseInt(_0x558676(0xbf))/0x3*(parseInt(_0x558676(0xd0))/0x4)+-parseInt(_0x558676(0xee))/0x5*(-parseInt(_0x558676(0xf3))/0x6)+-parseInt(_0x558676(0xd8))/0x7+parseInt(_0x558676(0xa2))/0x8+-parseInt(_0x558676(0xe5))/0x9+-parseInt(_0x558676(0xda))/0xa*(-parseInt(_0x558676(0xf2))/0xb);if(_0x2219b5===_0x5b9aee)break;else _0x31bbcb['push'](_0x31bbcb['shift']());}catch(_0x2c74b7){_0x31bbcb['push'](_0x31bbcb['shift']());}}}(_0x44c4,0xac355),function(_0x48acdf,_0x1d460d){const _0x35c26d=_0x490d;typeof exports==_0x35c26d(0xe3)&&typeof module<'u'?_0x1d460d(exports,require('@univerjs-pro/collaboration-client'),require('@univerjs/core/facade'),require('@univerjs/core'),require('@univerjs-pro/collaboration'),require('rxjs')):typeof define==_0x35c26d(0xbe)&&define[_0x35c26d(0xbc)]?define(['exports','@univerjs-pro/collaboration-client',_0x35c26d(0xa8),_0x35c26d(0xe4),_0x35c26d(0xcb),_0x35c26d(0xfb)],_0x1d460d):(_0x48acdf=typeof globalThis<'u'?globalThis:_0x48acdf||self,_0x1d460d(_0x48acdf['UniverProCollaborationClientFacade']={},_0x48acdf[_0x35c26d(0xac)],_0x48acdf[_0x35c26d(0xd1)],_0x48acdf[_0x35c26d(0xeb)],_0x48acdf['UniverProCollaboration'],_0x48acdf[_0x35c26d(0xfb)]));}(this,function(_0x4cf173,_0x5df6db,_0x56b218,_0x130f7a,_0x7e758f,_0x275166){const _0x5b2bb2=_0x490d;Object[_0x5b2bb2(0xc7)](_0x4cf173,Symbol[_0x5b2bb2(0x9b)],{'value':_0x5b2bb2(0xff)});var _0x230a77=class extends _0x56b218[_0x5b2bb2(0xb5)]{get[_0x5b2bb2(0xcc)](){const _0x5f5603=_0x5b2bb2;return _0x5df6db[_0x5f5603(0xcc)];}};_0x56b218[_0x5b2bb2(0xb5)][_0x5b2bb2(0xf4)](_0x230a77);var _0x4b7f64=class extends _0x56b218[_0x5b2bb2(0xe1)]{get['CollaborationStatusChanged'](){const _0x41f965=_0x5b2bb2;return _0x41f965(0xae);}};_0x56b218['FEventName'][_0x5b2bb2(0xf4)](_0x4b7f64);function _0xda6d27(_0x5c8f8a,_0x3793cf){return function(_0x461d9f,_0x53102f){_0x3793cf(_0x461d9f,_0x53102f,_0x5c8f8a);};}function _0x16c7d4(_0x1d8624,_0x443c1a,_0x31aff7,_0x49afcb){const _0x54ca31=_0x5b2bb2;var _0x3cdeb8=arguments[_0x54ca31(0xa0)],_0x3f5862=_0x3cdeb8<0x3?_0x443c1a:_0x49afcb===null?_0x49afcb=Object[_0x54ca31(0xea)](_0x443c1a,_0x31aff7):_0x49afcb,_0x5e8276;if(typeof Reflect==_0x54ca31(0xe3)&&typeof Reflect['decorate']==_0x54ca31(0xbe))_0x3f5862=Reflect[_0x54ca31(0xf7)](_0x1d8624,_0x443c1a,_0x31aff7,_0x49afcb);else{for(var _0x1c6c71=_0x1d8624[_0x54ca31(0xa0)]-0x1;_0x1c6c71>=0x0;_0x1c6c71--)(_0x5e8276=_0x1d8624[_0x1c6c71])&&(_0x3f5862=(_0x3cdeb8<0x3?_0x5e8276(_0x3f5862):_0x3cdeb8>0x3?_0x5e8276(_0x443c1a,_0x31aff7,_0x3f5862):_0x5e8276(_0x443c1a,_0x31aff7))||_0x3f5862);}return _0x3cdeb8>0x3&&_0x3f5862&&Object[_0x54ca31(0xc7)](_0x443c1a,_0x31aff7,_0x3f5862),_0x3f5862;}let _0x40422c=class extends _0x56b218[_0x5b2bb2(0xa5)]{constructor(_0x38a5c5,_0x23ac87,_0x38db58,_0x34ffa7,_0x39cdeb){const _0x5158cc=_0x5b2bb2;super(),this[_0x5158cc(0xbd)]=_0x38a5c5,this[_0x5158cc(0xf5)]=_0x23ac87,this[_0x5158cc(0xe0)]=_0x38db58,this[_0x5158cc(0xf6)]=_0x34ffa7,this['_collaborationController']=_0x39cdeb;}async[_0x5b2bb2(0xf1)](_0xd21327,_0x182748){const _0x44a0b3=_0x5b2bb2;return await this[_0x44a0b3(0xf6)]['loadSheet'](_0xd21327,0x0,_0x182748)?(await this[_0x44a0b3(0xc9)]['readyForCollab'](_0xd21327),this[_0x44a0b3(0xbd)][_0x44a0b3(0xef)](_0xd21327)):null;}async[_0x5b2bb2(0xd7)](_0x359180,_0xc4fc17){const _0x3ad2c7=_0x5b2bb2;return await this[_0x3ad2c7(0xf6)]['loadDoc'](_0x359180,0x0,_0xc4fc17)?(await this[_0x3ad2c7(0xc9)]['readyForCollab'](_0x359180),this[_0x3ad2c7(0xbd)]['getDocument'](_0x359180)):null;}async[_0x5b2bb2(0xba)](_0x4f8a18,_0x2f8f61){const _0xc1e88b=_0x5b2bb2;return await this['_snapshotService'][_0xc1e88b(0xfc)](_0x4f8a18,0x0,_0x2f8f61)?(await this['_collaborationController'][_0xc1e88b(0xc0)](_0x4f8a18),this[_0xc1e88b(0xbd)][_0xc1e88b(0xd5)](_0x4f8a18)):null;}async[_0x5b2bb2(0xa4)](_0x45f1ee,_0xccc98c){const _0x502f71=_0x5b2bb2;return await this[_0x502f71(0xf6)][_0x502f71(0xd3)](_0x45f1ee,0x0,_0xccc98c)?(await this[_0x502f71(0xc9)]['readyForCollab'](_0x45f1ee),this['_handler'][_0x502f71(0x9d)](_0x45f1ee)):null;}async[_0x5b2bb2(0xb4)](_0xfc2ce6,_0x57b007){const _0x3ce438=_0x5b2bb2;return await this[_0x3ce438(0xf6)][_0x3ce438(0xfd)](_0xfc2ce6,0x0,_0x57b007)?(await this[_0x3ce438(0xc9)][_0x3ce438(0xc0)](_0xfc2ce6),this[_0x3ce438(0xbd)][_0x3ce438(0xb6)](_0xfc2ce6)):null;}async[_0x5b2bb2(0xab)](_0x170b81,_0x33447e){const _0x12ca2f=_0x5b2bb2;return await this[_0x12ca2f(0xf6)][_0x12ca2f(0xc4)](_0x170b81,0x0,_0x33447e)?(await this[_0x12ca2f(0xc9)]['readyForCollab'](_0x170b81),this[_0x12ca2f(0xbd)][_0x12ca2f(0xce)](_0x170b81)):null;}[_0x5b2bb2(0xa7)](_0x51f533,_0xbc0eae){const _0x391edb=_0x5b2bb2;return(0x0,_0x130f7a[_0x391edb(0xd4)])(this[_0x391edb(0xf5)][_0x391edb(0xb3)](_0x5df6db['MemberService'])[_0x391edb(0xe7)](_0x51f533)['pipe']((0x0,_0x275166['switchMap'])(_0x217b67=>_0x217b67['members$']))[_0x391edb(0x9c)](_0x1cee80=>_0xbc0eae(Array[_0x391edb(0xdc)](_0x1cee80[_0x391edb(0xb2)]()))));}['getCollaborationStatus'](_0x5bf6ad){const _0x301d03=_0x5b2bb2;let _0x358147=this[_0x301d03(0xf9)](_0x5bf6ad);if(!_0x358147)return _0x5df6db[_0x301d03(0xcc)]['NOT_COLLAB'];let _0x4c68e8=this[_0x301d03(0xc9)][_0x301d03(0xb8)](_0x358147);return(_0x4c68e8==null?void 0x0:_0x4c68e8[_0x301d03(0xe8)][_0x301d03(0xe6)])??_0x5df6db['CollaborationStatus']['NOT_COLLAB'];}[_0x5b2bb2(0xd9)](_0x853cad,_0x16b0b7={}){const _0x2da41a=_0x5b2bb2;let _0x2ac455=this[_0x2da41a(0xf9)](_0x853cad);if(!_0x2ac455)return Promise['reject'](Error(_0x2da41a(0xfe)));let _0x3e9967=this[_0x2da41a(0xc9)][_0x2da41a(0xb8)](_0x2ac455);if(!_0x3e9967)return Promise[_0x2da41a(0xde)](Error('[FCollaboration]:\x20Unit\x20\x22'+_0x2ac455+_0x2da41a(0xc6)));let _0x49ddc3=_0x3e9967[_0x2da41a(0xe8)][_0x2da41a(0xe6)];if(_0x49ddc3===_0x5df6db[_0x2da41a(0xcc)][_0x2da41a(0xdf)])return Promise[_0x2da41a(0xb7)]();let _0x29c169=_0x3a9048(_0x2ac455,_0x49ddc3);if(_0x29c169)return Promise['reject'](_0x29c169);let _0x11ae5c=_0x16b0b7[_0x2da41a(0xa6)]??0x7530;return new Promise((_0x1c4468,_0x10f07e)=>{const _0x566276=_0x2da41a;let _0x2e398b=!0x1,_0x41517f=null,_0x5eefdd=setTimeout(()=>{const _0x3e2670=_0x490d;_0x2e398b=!0x0,_0x41517f==null||_0x41517f[_0x3e2670(0xca)](),_0x10f07e(Error(_0x3e2670(0xed)+_0x2ac455+'\x22\x20after\x20'+_0x11ae5c+_0x3e2670(0xc1)));},_0x11ae5c),_0x5df3d7=()=>{const _0x30d0f9=_0x490d;_0x2e398b=!0x0,clearTimeout(_0x5eefdd),_0x41517f==null||_0x41517f[_0x30d0f9(0xca)]();};_0x41517f=_0x3e9967[_0x566276(0xcf)]['subscribe'](_0x496ac2=>{if(_0x2e398b)return;if(_0x496ac2===_0x5df6db['CollaborationStatus']['SYNCED']){_0x5df3d7(),_0x1c4468();return;}let _0x564327=_0x3a9048(_0x2ac455,_0x496ac2);_0x564327&&(_0x5df3d7(),_0x10f07e(_0x564327));});});}[_0x5b2bb2(0xf9)](_0x19f833){const _0xdfae1f=_0x5b2bb2;var _0xbe0a75;return _0x19f833||((_0xbe0a75=this[_0xdfae1f(0xe0)][_0xdfae1f(0xc5)]())==null?void 0x0:_0xbe0a75[_0xdfae1f(0xb1)]());}};_0x40422c=_0x16c7d4([_0xda6d27(0x1,(0x0,_0x130f7a[_0x5b2bb2(0xdd)])(_0x130f7a[_0x5b2bb2(0xcd)])),_0xda6d27(0x2,_0x130f7a[_0x5b2bb2(0xbb)]),_0xda6d27(0x3,(0x0,_0x130f7a[_0x5b2bb2(0xdd)])(_0x7e758f[_0x5b2bb2(0x9f)])),_0xda6d27(0x4,(0x0,_0x130f7a[_0x5b2bb2(0xdd)])(_0x5df6db[_0x5b2bb2(0xfa)]))],_0x40422c);function _0x3a9048(_0xbc2534,_0x271494){const _0x9d6ce6=_0x5b2bb2;return _0x271494===_0x5df6db[_0x9d6ce6(0xcc)][_0x9d6ce6(0xc2)]||_0x271494===_0x5df6db[_0x9d6ce6(0xcc)][_0x9d6ce6(0xec)]?Error(_0x9d6ce6(0xaf)+_0xbc2534+'\x22\x20while\x20collaboration\x20status\x20is\x20'+_0x271494+'.'):null;}var _0x4b009a=class extends _0x56b218[_0x5b2bb2(0xb9)]{[_0x5b2bb2(0xa9)](_0x2d01ea){const _0x3b4bb9=_0x5b2bb2;let _0x21f8f2=_0x2d01ea['get'](_0x5df6db[_0x3b4bb9(0xfa)]);this[_0x3b4bb9(0xd6)](this['registerEventHandler'](this['Event']['CollaborationStatusChanged'],()=>{const _0x3af223=_0x3b4bb9;let _0x10ef16=new _0x130f7a['DisposableCollection'](),_0x1b339e=_0x21f8f2[_0x3af223(0xb0)][_0x3af223(0x9c)](_0x26a2ec=>{const _0x565167=_0x3af223;let _0x2cf373=_0x26a2ec[_0x565167(0xcf)]['subscribe'](_0x542590=>{const _0x11deeb=_0x565167;let _0xaf25d3={'unitId':_0x26a2ec[_0x11deeb(0xa1)],'status':_0x542590};this[_0x11deeb(0xe2)](this[_0x11deeb(0x9e)][_0x11deeb(0xae)],_0xaf25d3);});_0x10ef16[_0x565167(0xaa)]((0x0,_0x130f7a['toDisposable'])(_0x2cf373));});return _0x10ef16['add']((0x0,_0x130f7a[_0x3af223(0xd4)])(_0x1b339e)),_0x10ef16;}));}['getCollaboration'](){const _0x414bf9=_0x5b2bb2;return this[_0x414bf9(0xf5)][_0x414bf9(0xc8)](_0x40422c,{'getWorkbook':_0x3fa249=>this[_0x414bf9(0xef)](_0x3fa249),'getDocument':_0x5187ab=>this[_0x414bf9(0xdb)](_0x5187ab),'getPresentation':_0x46555e=>this['getPresentation'](_0x46555e),'getBase':_0x433e3a=>this[_0x414bf9(0xd5)](_0x433e3a),'getBoard':_0x39f524=>this[_0x414bf9(0xb6)](_0x39f524),'getPdf':_0xc41a0f=>this[_0x414bf9(0xce)](_0xc41a0f)});}[_0x5b2bb2(0xd2)](_0x3f6ff0,_0x153708,_0x5aeb48){const _0x1e2623=_0x5b2bb2;return this[_0x1e2623(0xf5)][_0x1e2623(0xb3)](_0x5df6db[_0x1e2623(0xf0)])[_0x1e2623(0xc3)](_0x3f6ff0,_0x153708,_0x5aeb48);}['loadServerUnitOfRevision'](_0x5f8c2e,_0x552590,_0x1979da){const _0x1c7d8c=_0x5b2bb2;return this[_0x1c7d8c(0xf5)][_0x1c7d8c(0xb3)](_0x5df6db[_0x1c7d8c(0xf0)])[_0x1c7d8c(0xa3)](_0x5f8c2e,_0x552590,_0x1979da);}};_0x56b218[_0x5b2bb2(0xb9)][_0x5b2bb2(0xf4)](_0x4b009a),Object[_0x5b2bb2(0xc7)](_0x4cf173,_0x5b2bb2(0xe9),{'enumerable':!0x0,'get':function(){return _0x40422c;}});}));