@univerjs-pro/shape-thread-comment 1.3.1 → 1.5.0
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/README.md +11 -11
- 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/types/element-comment.d.ts +16 -0
- package/lib/types/facade/index.d.ts +1 -5
- package/lib/types/index.d.ts +2 -0
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- package/package.json +10 -14
- package/lib/types/facade/element-comment.d.ts +0 -15
- package/lib/types/facade/f-doc-chart.d.ts +0 -52
- package/lib/types/facade/f-doc-image.d.ts +0 -52
- package/lib/types/facade/f-sheet-chart.d.ts +0 -52
- package/lib/types/facade/f-sheet-image.d.ts +0 -52
package/README.md
CHANGED
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
[](https://npmjs.com/package/@univerjs-pro/shape-thread-comment)
|
|
5
5
|
[](https://npmjs.com/package/@univerjs-pro/shape-thread-comment)
|
|
6
6
|
|
|
7
|
-
`@univerjs-pro/shape-thread-comment` provides
|
|
7
|
+
`@univerjs-pro/shape-thread-comment` provides generic Shape comment Facade methods and host-independent helpers for floating-element comments.
|
|
8
8
|
|
|
9
9
|
## Package Overview
|
|
10
10
|
|
|
11
|
-
| Package | UMD global | CSS | Locales | Facade entry |
|
|
12
|
-
| --- | --- | :---: | :---: | :---: |
|
|
13
|
-
| `@univerjs-pro/shape-thread-comment` | `UniverProShapeThreadComment` | No | No | Yes |
|
|
11
|
+
| Package | UMD global | CSS | Locales | Facade entry | Worker entry |
|
|
12
|
+
| --- | --- | :---: | :---: | :---: | :---: |
|
|
13
|
+
| `@univerjs-pro/shape-thread-comment` | `UniverProShapeThreadComment` | No | No | Yes | No |
|
|
14
14
|
|
|
15
15
|
## Installation
|
|
16
16
|
|
|
@@ -20,27 +20,27 @@ pnpm add @univerjs-pro/shape-thread-comment
|
|
|
20
20
|
npm install @univerjs-pro/shape-thread-comment
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
Keep all `@univerjs/*` and `@univerjs-pro/*` packages on the same version.
|
|
24
|
-
|
|
25
23
|
## Usage
|
|
26
24
|
|
|
25
|
+
Start with the [integration setup](https://docs.univer.ai/) for your document type, including its required plugins, styles, and locale resources. The snippet below assumes that setup is complete.
|
|
26
|
+
|
|
27
27
|
Register `UniverShapeThreadCommentPlugin` with the Univer thread comment plugin.
|
|
28
28
|
|
|
29
|
-
Import the Facade entry to add `createCommentAsync`, `getComments`, and `listCommentsAsync` to
|
|
29
|
+
Import the Facade entry to add `createCommentAsync`, `getComments`, and `listCommentsAsync` to `FShape`.
|
|
30
30
|
|
|
31
31
|
```ts
|
|
32
32
|
import '@univerjs-pro/shape-thread-comment/facade';
|
|
33
33
|
|
|
34
|
-
const
|
|
35
|
-
await
|
|
34
|
+
const shape = univerAPI.getActivePresentation()?.getSlideByIndex(0)?.getShapes()[0];
|
|
35
|
+
await shape?.createCommentAsync('Align this shape.', { id: 'review-shape-1' });
|
|
36
36
|
```
|
|
37
37
|
|
|
38
38
|
## Integration Notes
|
|
39
39
|
|
|
40
|
-
- Keep all `@univerjs/*` and `@univerjs-pro/*` packages on the same version.
|
|
41
40
|
- Import `@univerjs-pro/shape-thread-comment/facade` when using the package through Univer Facade APIs.
|
|
42
41
|
|
|
43
42
|
## Resources
|
|
44
43
|
|
|
45
|
-
- [Documentation](https://docs.univer.ai
|
|
44
|
+
- [Documentation](https://docs.univer.ai)
|
|
46
45
|
- [NPM package](https://npmjs.com/package/@univerjs-pro/shape-thread-comment)
|
|
46
|
+
- [GitHub repository](https://github.com/dream-num/univer-pro)
|
package/lib/cjs/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const _0x1c663f=_0xf51f;(function(_0x32769d,_0x129c54){const _0x35abc4=_0xf51f,_0x26a4de=_0x32769d();while(!![]){try{const _0x48fb81=-parseInt(_0x35abc4(0x1f7))/0x1*(-parseInt(_0x35abc4(0x1e6))/0x2)+parseInt(_0x35abc4(0x1f4))/0x3*(parseInt(_0x35abc4(0x1de))/0x4)+-parseInt(_0x35abc4(0x1d3))/0x5+-parseInt(_0x35abc4(0x1f3))/0x6+-parseInt(_0x35abc4(0x1f5))/0x7+parseInt(_0x35abc4(0x1e7))/0x8+parseInt(_0x35abc4(0x1ea))/0x9;if(_0x48fb81===_0x129c54)break;else _0x26a4de['push'](_0x26a4de['shift']());}catch(_0x4d555c){_0x26a4de['push'](_0x26a4de['shift']());}}}(_0x4a78,0x18f5d),Object[_0x1c663f(0x1fa)](exports,Symbol[_0x1c663f(0x1f2)],{'value':_0x1c663f(0x1eb)}));var e=Object[_0x1c663f(0x1f1)],t=Object[_0x1c663f(0x1fa)],n=Object[_0x1c663f(0x1f8)],r=Object['getOwnPropertyNames'],i=Object[_0x1c663f(0x1e1)],a=Object['prototype'][_0x1c663f(0x1d5)],o=(_0x18fd66,_0x19f6d5,_0x2f38fa,_0x414c4e)=>{const _0x40709c=_0x1c663f;if(_0x19f6d5&&typeof _0x19f6d5==_0x40709c(0x1f6)||typeof _0x19f6d5==_0x40709c(0x1d4)){for(var _0x581dff=r(_0x19f6d5),_0xbce738=0x0,_0xed13=_0x581dff[_0x40709c(0x1fb)],_0x23a343;_0xbce738<_0xed13;_0xbce738++)_0x23a343=_0x581dff[_0xbce738],!a[_0x40709c(0x1e8)](_0x18fd66,_0x23a343)&&_0x23a343!==_0x2f38fa&&t(_0x18fd66,_0x23a343,{'get':(_0x28d5e1=>_0x19f6d5[_0x28d5e1])['bind'](null,_0x23a343),'enumerable':!(_0x414c4e=n(_0x19f6d5,_0x23a343))||_0x414c4e['enumerable']});}return _0x18fd66;},s=(_0x23c526,_0x144e45,_0x2c52ea)=>(_0x2c52ea=_0x23c526==null?{}:e(i(_0x23c526)),o(_0x144e45||!_0x23c526||!_0x23c526[_0x1c663f(0x1da)]||!a['call'](_0x23c526,_0x1c663f(0x1f9))?t(_0x2c52ea,_0x1c663f(0x1f9),{'value':_0x23c526,'enumerable':!0x0}):_0x2c52ea,_0x23c526));let c=require('@univerjs-pro/engine-shape/facade'),l=require('@univerjs/core'),u=require('@univerjs/thread-comment');function _0xf51f(_0xce491b,_0x71d7a5){_0xce491b=_0xce491b-0x1d1;const _0x4a7800=_0x4a78();let _0xf51fb5=_0x4a7800[_0xce491b];return _0xf51fb5;}u=s(u);function _0x4a78(){const _0x240383=['toStringTag','735246TMToaG','4437PgtSlE','837781vEebwG','object','623udoGEa','getOwnPropertyDescriptor','default','defineProperty','length','UNIVER_DOC','ThreadCommentFacadeService','unitId','ThreadCommentAnchorKind','UniverInstanceType','getComments','885025yLaPpP','function','hasOwnProperty','kind','shapeId','FShape','hostType','__esModule','filter','UNIVER_BOARD','Unsupported\x20Shape\x20host\x20type:\x20','44aWkCxm','_shapeRef','DOC_DRAWING','getPrototypeOf','UNIVER_SLIDE','FShapeThreadCommentMixin','listCommentsAsync','get','370MMFxYC','795680orjlBY','call','_getThreadCommentService','2614338pKCEKq','Module','subUnitId','anchor','SHEET_DRAWING','elementId','createCommentAsync','create'];_0x4a78=function(){return _0x240383;};return _0x4a78();}const d=new WeakMap();function f(_0x29a0c5){const _0x299fff=_0x1c663f;switch(_0x29a0c5){case l[_0x299fff(0x1d1)]['UNIVER_SHEET']:return u[_0x299fff(0x1ff)][_0x299fff(0x1ee)];case l['UniverInstanceType'][_0x299fff(0x1fc)]:return u[_0x299fff(0x1ff)][_0x299fff(0x1e0)];case l[_0x299fff(0x1d1)][_0x299fff(0x1e2)]:return u[_0x299fff(0x1ff)]['SLIDE_ELEMENT'];case l[_0x299fff(0x1d1)][_0x299fff(0x1dc)]:return u[_0x299fff(0x1ff)]['BOARD_ELEMENT'];default:throw Error(_0x299fff(0x1dd)+_0x29a0c5);}}var p=class extends c[_0x1c663f(0x1d8)]{[_0x1c663f(0x1e9)](){const _0x2e1e20=_0x1c663f;let _0x59359f=d[_0x2e1e20(0x1e5)](this);if(_0x59359f)return _0x59359f;let _0x2ccb34=this['_injector'][_0x2e1e20(0x1e5)](u[_0x2e1e20(0x1fd)]);return d['set'](this,_0x2ccb34),_0x2ccb34;}[_0x1c663f(0x1f0)](_0x22684c,_0x213de9={}){const _0x4dc587=_0x1c663f;return this['_getThreadCommentService']()[_0x4dc587(0x1f0)]({..._0x213de9,'unitId':this[_0x4dc587(0x1df)][_0x4dc587(0x1fe)],'subUnitId':this[_0x4dc587(0x1df)]['subUnitId'],'anchor':{'kind':f(this[_0x4dc587(0x1df)][_0x4dc587(0x1d9)]),'elementId':this[_0x4dc587(0x1df)][_0x4dc587(0x1d7)],'pageId':this[_0x4dc587(0x1df)][_0x4dc587(0x1ec)]},'content':_0x22684c});}[_0x1c663f(0x1d2)](){const _0x7d5d0b=_0x1c663f;let _0x33c89a=f(this['_shapeRef'][_0x7d5d0b(0x1d9)]);return this[_0x7d5d0b(0x1e9)]()[_0x7d5d0b(0x1d2)]({'unitIds':[this[_0x7d5d0b(0x1df)][_0x7d5d0b(0x1fe)]],'subUnitIds':[this[_0x7d5d0b(0x1df)][_0x7d5d0b(0x1ec)]],'anchorKinds':[_0x33c89a]})[_0x7d5d0b(0x1db)](_0x526f66=>{const _0x3f81f4=_0x7d5d0b;var _0x361050;return((_0x361050=_0x526f66['anchor'])==null?void 0x0:_0x361050[_0x3f81f4(0x1d6)])===_0x33c89a&&'elementId'in _0x526f66[_0x3f81f4(0x1ed)]&&_0x526f66['anchor'][_0x3f81f4(0x1ef)]===this[_0x3f81f4(0x1df)][_0x3f81f4(0x1d7)];});}async['listCommentsAsync'](){const _0x790540=_0x1c663f;let _0x5b3905=f(this[_0x790540(0x1df)]['hostType']);return(await this[_0x790540(0x1e9)]()[_0x790540(0x1e4)]({'unitIds':[this[_0x790540(0x1df)][_0x790540(0x1fe)]],'subUnitIds':[this[_0x790540(0x1df)]['subUnitId']],'anchorKinds':[_0x5b3905]}))[_0x790540(0x1db)](_0x593305=>{const _0x512530=_0x790540;var _0x1b2669;return((_0x1b2669=_0x593305[_0x512530(0x1ed)])==null?void 0x0:_0x1b2669[_0x512530(0x1d6)])===_0x5b3905&&_0x512530(0x1ef)in _0x593305[_0x512530(0x1ed)]&&_0x593305[_0x512530(0x1ed)][_0x512530(0x1ef)]===this[_0x512530(0x1df)]['shapeId'];});}};c[_0x1c663f(0x1d8)]['extend'](p),exports[_0x1c663f(0x1e3)]=p;
|
package/lib/cjs/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var _0x483f88=_0x1892;(function(_0x1ce49e,_0x4bf6c5){var _0x33fe6c=_0x1892,_0x209781=_0x1ce49e();while(!![]){try{var _0x10c7b2=-parseInt(_0x33fe6c(0xf3))/0x1*(-parseInt(_0x33fe6c(0x112))/0x2)+-parseInt(_0x33fe6c(0xed))/0x3+-parseInt(_0x33fe6c(0xf8))/0x4*(-parseInt(_0x33fe6c(0x107))/0x5)+parseInt(_0x33fe6c(0xe3))/0x6+-parseInt(_0x33fe6c(0xf1))/0x7+-parseInt(_0x33fe6c(0xee))/0x8*(-parseInt(_0x33fe6c(0xe6))/0x9)+parseInt(_0x33fe6c(0x116))/0xa*(parseInt(_0x33fe6c(0x10c))/0xb);if(_0x10c7b2===_0x4bf6c5)break;else _0x209781['push'](_0x209781['shift']());}catch(_0x119ada){_0x209781['push'](_0x209781['shift']());}}}(_0x2e4b,0xb605b),Object['defineProperty'](exports,Symbol['toStringTag'],{'value':_0x483f88(0xff)}));let e=require('@univerjs/thread-comment'),t=require('@univerjs-pro/license'),n=require('@univerjs/core');const r=_0x483f88(0x103),i={};function a(_0x463972){var _0x24f340=_0x483f88;return _0x463972['get'](e[_0x24f340(0x113)]);}function o(_0x46ad90,_0x269efc,_0x541454,_0x2d6e66){var _0x1d92cd=_0x483f88;return _0x46ad90[_0x1d92cd(0x117)]({..._0x2d6e66,'unitId':_0x269efc[_0x1d92cd(0x108)],'subUnitId':_0x269efc['subUnitId'],'anchor':{'kind':_0x269efc[_0x1d92cd(0xf0)],'pageId':_0x269efc[_0x1d92cd(0x111)],'elementId':_0x269efc['elementId']},'content':_0x541454});}function s(_0x18527c,_0xd9ea7a){var _0x412341=_0x483f88;return _0x18527c[_0x412341(0x109)]({'unitIds':[_0xd9ea7a['unitId']],'subUnitIds':[_0xd9ea7a['subUnitId']],'anchorKinds':[_0xd9ea7a[_0x412341(0xf0)]]})[_0x412341(0x10d)](_0x8f97a2=>{var _0x195284=_0x412341,_0x20372d;return((_0x20372d=_0x8f97a2['anchor'])==null?void 0x0:_0x20372d['kind'])===_0xd9ea7a['kind']&&_0x195284(0x10b)in _0x8f97a2['anchor']&&_0x8f97a2[_0x195284(0xf2)]['elementId']===_0xd9ea7a[_0x195284(0x10b)];});}function _0x1892(_0x58d726,_0xfdbe3c){_0x58d726=_0x58d726-0xdf;var _0x2e4b7e=_0x2e4b();var _0x1892a5=_0x2e4b7e[_0x58d726];return _0x1892a5;}async function c(_0x5c5113,_0x5c3f7e){var _0x5647fa=_0x483f88;return(await _0x5c5113[_0x5647fa(0xec)]({'unitIds':[_0x5c3f7e[_0x5647fa(0x108)]],'subUnitIds':[_0x5c3f7e[_0x5647fa(0x111)]],'anchorKinds':[_0x5c3f7e['kind']]}))[_0x5647fa(0x10d)](_0x297f34=>{var _0x1300a6=_0x5647fa,_0x22099f;return((_0x22099f=_0x297f34[_0x1300a6(0xf2)])==null?void 0x0:_0x22099f['kind'])===_0x5c3f7e[_0x1300a6(0xf0)]&&_0x1300a6(0x10b)in _0x297f34['anchor']&&_0x297f34[_0x1300a6(0xf2)]['elementId']===_0x5c3f7e[_0x1300a6(0x10b)];});}var l=_0x483f88(0xfe),u=_0x483f88(0x100);function d(_0x225189,_0x457802){return function(_0x16edd7,_0x493caf){_0x457802(_0x16edd7,_0x493caf,_0x225189);};}function f(_0x10902d,_0x54a7ea,_0xc8ffc3,_0x2805b8){var _0xc83f0d=_0x483f88,_0x379224=arguments['length'],_0x2fb219=_0x379224<0x3?_0x54a7ea:_0x2805b8===null?_0x2805b8=Object[_0xc83f0d(0x102)](_0x54a7ea,_0xc8ffc3):_0x2805b8,_0x267fe5;if(typeof Reflect==_0xc83f0d(0xe2)&&typeof Reflect[_0xc83f0d(0x10a)]==_0xc83f0d(0x110))_0x2fb219=Reflect['decorate'](_0x10902d,_0x54a7ea,_0xc8ffc3,_0x2805b8);else{for(var _0x4f1946=_0x10902d[_0xc83f0d(0xe4)]-0x1;_0x4f1946>=0x0;_0x4f1946--)(_0x267fe5=_0x10902d[_0x4f1946])&&(_0x2fb219=(_0x379224<0x3?_0x267fe5(_0x2fb219):_0x379224>0x3?_0x267fe5(_0x54a7ea,_0xc8ffc3,_0x2fb219):_0x267fe5(_0x54a7ea,_0xc8ffc3))||_0x2fb219);}return _0x379224>0x3&&_0x2fb219&&Object[_0xc83f0d(0xfb)](_0x54a7ea,_0xc8ffc3,_0x2fb219),_0x2fb219;}function p(_0x94b510){'@babel/helpers - typeof';var _0x149238=_0x483f88;return p=typeof Symbol=='function'&&typeof Symbol[_0x149238(0xfa)]==_0x149238(0x101)?function(_0x57023b){return typeof _0x57023b;}:function(_0x1888ef){var _0x3c0694=_0x149238;return _0x1888ef&&typeof Symbol==_0x3c0694(0x110)&&_0x1888ef['constructor']===Symbol&&_0x1888ef!==Symbol['prototype']?_0x3c0694(0x101):typeof _0x1888ef;},p(_0x94b510);}function _0x2e4b(){var _0x43ec80=['Injector','_config','10pErbOV','createCommentAsync','Plugin','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','call','object','3793164KdEjNZ','length','getThreadCommentService','9jVblxn','_configService','UniverInstanceType','packageName','setConfig','IConfigService','listCommentsAsync','3166839KiOENM','312280TPHlya','string','kind','2388505QZwjdx','anchor','20869HTaieZ','UniverThreadCommentPlugin','createFloatingElementCommentAsync','_injector','UNIVER_SHAPE_THREAD_COMMENT_PLUGIN','1156DdCcPB','getFloatingElementComments','iterator','defineProperty','type','UniverLicensePlugin','@univerjs-pro/shape-thread-comment','Module','1.5.0','symbol','getOwnPropertyDescriptor','shape-thread-comment.config','UNIVER_UNKNOWN','merge','pluginName','1705iaeAuC','unitId','getComments','decorate','elementId','8900650PjlWtp','filter','UniverShapeThreadCommentPlugin','DependentOn','function','subUnitId','54iBvXFU','ThreadCommentFacadeService'];_0x2e4b=function(){return _0x43ec80;};return _0x2e4b();}function m(_0x1a1216,_0x536959){var _0x39beb3=_0x483f88;if(p(_0x1a1216)!='object'||!_0x1a1216)return _0x1a1216;var _0x35e9c0;if(typeof Symbol<'u'&&(_0x35e9c0=_0x1a1216[Symbol['toPrimitive']])!==void 0x0){var _0x58146e=_0x35e9c0[_0x39beb3(0xe1)](_0x1a1216,_0x536959||'default');if(p(_0x58146e)!=_0x39beb3(0xe2))return _0x58146e;throw TypeError(_0x39beb3(0xe0));}return(_0x536959===_0x39beb3(0xef)?String:Number)(_0x1a1216);}function h(_0x23587f){var _0x48dc74=_0x483f88,_0xbe08b7=m(_0x23587f,_0x48dc74(0xef));return p(_0xbe08b7)==_0x48dc74(0x101)?_0xbe08b7:_0xbe08b7+'';}function g(_0xdb3482,_0x6d2663,_0x3807a1){var _0x254288=_0x483f88;return(_0x6d2663=h(_0x6d2663))in _0xdb3482?Object[_0x254288(0xfb)](_0xdb3482,_0x6d2663,{'value':_0x3807a1,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0xdb3482[_0x6d2663]=_0x3807a1,_0xdb3482;}let _=class extends n[_0x483f88(0xdf)]{constructor(_0x4b4373=i,_0x14b71c,_0x4b12fd){var _0x164b71=_0x483f88;super(),this[_0x164b71(0x115)]=_0x4b4373,this[_0x164b71(0xf6)]=_0x14b71c,this[_0x164b71(0xe7)]=_0x4b12fd;let {..._0x1d9e46}=(0x0,n[_0x164b71(0x105)])({},i,this[_0x164b71(0x115)]);this[_0x164b71(0xe7)][_0x164b71(0xea)](r,_0x1d9e46);}};g(_,_0x483f88(0x106),_0x483f88(0xf7)),g(_,_0x483f88(0xe9),l),g(_,'version',u),g(_,_0x483f88(0xfc),n[_0x483f88(0xe8)][_0x483f88(0x104)]),_=f([(0x0,n[_0x483f88(0x10f)])(t[_0x483f88(0xfd)],e[_0x483f88(0xf4)]),d(0x1,(0x0,n['Inject'])(n[_0x483f88(0x114)])),d(0x2,n[_0x483f88(0xeb)])],_),exports['SHAPE_THREAD_COMMENT_PLUGIN_CONFIG_KEY']=r,Object['defineProperty'](exports,_0x483f88(0x10e),{'enumerable':!0x0,'get':function(){return _;}}),exports[_0x483f88(0xf5)]=o,exports[_0x483f88(0xf9)]=s,exports[_0x483f88(0xe5)]=a,exports['listFloatingElementCommentsAsync']=c;
|
package/lib/es/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const _0x47ca30=_0x28ef;function _0x565b(){const _0x3ebc5a=['shapeId','BOARD_ELEMENT','8351728zDzfKS','hostType','196034upbYET','SLIDE_ELEMENT','_getThreadCommentService','ThreadCommentAnchorKind','871708joYjow','275040EZOIib','elementId','Unsupported\x20Shape\x20host\x20type:\x20','_shapeRef','160ROXaaf','174060SrHvFZ','set','DOC_DRAWING','getComments','UNIVER_SHEET','896CUSQKm','ThreadCommentFacadeService','get','anchor','UNIVER_DOC','3PcMTLW','listCommentsAsync','_injector','UNIVER_SLIDE','UNIVER_BOARD','subUnitId','10560hakjXk','1xhmauu','createCommentAsync','extend','filter','1829944Ehjsxf','kind','unitId'];_0x565b=function(){return _0x3ebc5a;};return _0x565b();}function _0x28ef(_0x4bd3e4,_0x51d658){_0x4bd3e4=_0x4bd3e4-0x148;const _0x565b95=_0x565b();let _0x28ef74=_0x565b95[_0x4bd3e4];return _0x28ef74;}(function(_0xb27163,_0x1de7f1){const _0x1ea361=_0x28ef,_0xe722dc=_0xb27163();while(!![]){try{const _0x4d026e=parseInt(_0x1ea361(0x159))/0x1*(-parseInt(_0x1ea361(0x164))/0x2)+-parseInt(_0x1ea361(0x152))/0x3*(parseInt(_0x1ea361(0x168))/0x4)+parseInt(_0x1ea361(0x169))/0x5+parseInt(_0x1ea361(0x158))/0x6*(-parseInt(_0x1ea361(0x14d))/0x7)+parseInt(_0x1ea361(0x15d))/0x8+-parseInt(_0x1ea361(0x148))/0x9*(parseInt(_0x1ea361(0x16d))/0xa)+parseInt(_0x1ea361(0x162))/0xb;if(_0x4d026e===_0x1de7f1)break;else _0xe722dc['push'](_0xe722dc['shift']());}catch(_0xcb12e3){_0xe722dc['push'](_0xe722dc['shift']());}}}(_0x565b,0x2ef4f));import{FShape as _0x12d471}from'@univerjs-pro/engine-shape/facade';import{UniverInstanceType as _0x1fc657}from'@univerjs/core';import*as _0x13b6d2 from'@univerjs/thread-comment';const r=new WeakMap();function i(_0x1bfbb8){const _0x551571=_0x28ef;switch(_0x1bfbb8){case _0x1fc657[_0x551571(0x14c)]:return _0x13b6d2[_0x551571(0x167)]['SHEET_DRAWING'];case _0x1fc657[_0x551571(0x151)]:return _0x13b6d2['ThreadCommentAnchorKind'][_0x551571(0x14a)];case _0x1fc657[_0x551571(0x155)]:return _0x13b6d2[_0x551571(0x167)][_0x551571(0x165)];case _0x1fc657[_0x551571(0x156)]:return _0x13b6d2[_0x551571(0x167)][_0x551571(0x161)];default:throw Error(_0x551571(0x16b)+_0x1bfbb8);}}var a=class extends _0x12d471{[_0x47ca30(0x166)](){const _0x4d7b1f=_0x47ca30;let _0x38b6e0=r['get'](this);if(_0x38b6e0)return _0x38b6e0;let _0x17229a=this[_0x4d7b1f(0x154)][_0x4d7b1f(0x14f)](_0x13b6d2[_0x4d7b1f(0x14e)]);return r[_0x4d7b1f(0x149)](this,_0x17229a),_0x17229a;}[_0x47ca30(0x15a)](_0x42bdc9,_0x367849={}){const _0x397e99=_0x47ca30;return this[_0x397e99(0x166)]()[_0x397e99(0x15a)]({..._0x367849,'unitId':this[_0x397e99(0x16c)][_0x397e99(0x15f)],'subUnitId':this[_0x397e99(0x16c)]['subUnitId'],'anchor':{'kind':i(this[_0x397e99(0x16c)][_0x397e99(0x163)]),'elementId':this['_shapeRef'][_0x397e99(0x160)],'pageId':this[_0x397e99(0x16c)][_0x397e99(0x157)]},'content':_0x42bdc9});}[_0x47ca30(0x14b)](){const _0x5a32f6=_0x47ca30;let _0x5e4641=i(this[_0x5a32f6(0x16c)][_0x5a32f6(0x163)]);return this[_0x5a32f6(0x166)]()[_0x5a32f6(0x14b)]({'unitIds':[this[_0x5a32f6(0x16c)][_0x5a32f6(0x15f)]],'subUnitIds':[this['_shapeRef'][_0x5a32f6(0x157)]],'anchorKinds':[_0x5e4641]})[_0x5a32f6(0x15c)](_0x23e1db=>{const _0x9aadfb=_0x5a32f6;var _0x2ffe91;return((_0x2ffe91=_0x23e1db[_0x9aadfb(0x150)])==null?void 0x0:_0x2ffe91['kind'])===_0x5e4641&&_0x9aadfb(0x16a)in _0x23e1db[_0x9aadfb(0x150)]&&_0x23e1db[_0x9aadfb(0x150)][_0x9aadfb(0x16a)]===this[_0x9aadfb(0x16c)][_0x9aadfb(0x160)];});}async[_0x47ca30(0x153)](){const _0x181dea=_0x47ca30;let _0x1d7be9=i(this['_shapeRef']['hostType']);return(await this['_getThreadCommentService']()[_0x181dea(0x153)]({'unitIds':[this[_0x181dea(0x16c)]['unitId']],'subUnitIds':[this[_0x181dea(0x16c)][_0x181dea(0x157)]],'anchorKinds':[_0x1d7be9]}))['filter'](_0x1e5a06=>{const _0x3e0d9a=_0x181dea;var _0xe25926;return((_0xe25926=_0x1e5a06['anchor'])==null?void 0x0:_0xe25926[_0x3e0d9a(0x15e)])===_0x1d7be9&&'elementId'in _0x1e5a06['anchor']&&_0x1e5a06[_0x3e0d9a(0x150)][_0x3e0d9a(0x16a)]===this[_0x3e0d9a(0x16c)][_0x3e0d9a(0x160)];});}};_0x12d471[_0x47ca30(0x15b)](a);export{a as FShapeThreadCommentMixin};
|
package/lib/es/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
function _0x1d05(){var _0x22b030=['function','decorate','25955kLHUMl','version','2421475hrxMkf','defineProperty','769545JHWMuu','constructor','_config','getComments','shape-thread-comment.config','elementId','get','pluginName','kind','@univerjs-pro/shape-thread-comment','object','subUnitId','_configService','1494hRoVdj','string','unitId','_injector','242349baoXFV','UNIVER_UNKNOWN','18351369rwgjFl','anchor','prototype','length','packageName','filter','toPrimitive','createCommentAsync','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','1738418kZoCzC','default','call','10EGerQT','setConfig','6389160XHVoOP','24dRxeML','symbol','listCommentsAsync'];_0x1d05=function(){return _0x22b030;};return _0x1d05();}var _0x111d97=_0x2b09;(function(_0x4ec228,_0x45498f){var _0x3f4606=_0x2b09,_0x1dfd53=_0x4ec228();while(!![]){try{var _0x39ad4c=-parseInt(_0x3f4606(0xd4))/0x1+parseInt(_0x3f4606(0xc5))/0x2+parseInt(_0x3f4606(0xe5))/0x3+-parseInt(_0x3f4606(0xca))/0x4+-parseInt(_0x3f4606(0xd0))/0x5*(-parseInt(_0x3f4606(0xe1))/0x6)+-parseInt(_0x3f4606(0xd2))/0x7*(parseInt(_0x3f4606(0xcb))/0x8)+-parseInt(_0x3f4606(0xe7))/0x9*(-parseInt(_0x3f4606(0xc8))/0xa);if(_0x39ad4c===_0x45498f)break;else _0x1dfd53['push'](_0x1dfd53['shift']());}catch(_0x401e38){_0x1dfd53['push'](_0x1dfd53['shift']());}}}(_0x1d05,0xd61b6));import{ThreadCommentFacadeService as _0x3290b4,UniverThreadCommentPlugin as _0x270182}from'@univerjs/thread-comment';import{UniverLicensePlugin as _0x54d45a}from'@univerjs-pro/license';import{DependentOn as _0x4a24d5,IConfigService as _0x43e82d,Inject as _0x10159e,Injector as _0x1fdaf5,Plugin as _0x57a561,UniverInstanceType as _0x24be8c,merge as _0x3c86cc}from'@univerjs/core';const u=_0x111d97(0xd8),d={};function f(_0x334ce7){var _0x2f2aa7=_0x111d97;return _0x334ce7[_0x2f2aa7(0xda)](_0x3290b4);}function p(_0x25e93d,_0x46715f,_0x155691,_0x4e0042){var _0x117148=_0x111d97;return _0x25e93d[_0x117148(0xc3)]({..._0x4e0042,'unitId':_0x46715f[_0x117148(0xe3)],'subUnitId':_0x46715f['subUnitId'],'anchor':{'kind':_0x46715f[_0x117148(0xdc)],'pageId':_0x46715f[_0x117148(0xdf)],'elementId':_0x46715f[_0x117148(0xd9)]},'content':_0x155691});}function m(_0x22eab9,_0x127d15){var _0x1509f4=_0x111d97;return _0x22eab9[_0x1509f4(0xd7)]({'unitIds':[_0x127d15[_0x1509f4(0xe3)]],'subUnitIds':[_0x127d15[_0x1509f4(0xdf)]],'anchorKinds':[_0x127d15[_0x1509f4(0xdc)]]})[_0x1509f4(0xc1)](_0x1a9207=>{var _0x4d017d=_0x1509f4,_0x3a570d;return((_0x3a570d=_0x1a9207[_0x4d017d(0xbd)])==null?void 0x0:_0x3a570d[_0x4d017d(0xdc)])===_0x127d15[_0x4d017d(0xdc)]&&_0x4d017d(0xd9)in _0x1a9207[_0x4d017d(0xbd)]&&_0x1a9207[_0x4d017d(0xbd)][_0x4d017d(0xd9)]===_0x127d15[_0x4d017d(0xd9)];});}async function h(_0x3c75b1,_0x271b9d){var _0x2536bd=_0x111d97;return(await _0x3c75b1[_0x2536bd(0xcd)]({'unitIds':[_0x271b9d['unitId']],'subUnitIds':[_0x271b9d['subUnitId']],'anchorKinds':[_0x271b9d[_0x2536bd(0xdc)]]}))[_0x2536bd(0xc1)](_0x4932a3=>{var _0x44a31b=_0x2536bd,_0x4ca7f4;return((_0x4ca7f4=_0x4932a3['anchor'])==null?void 0x0:_0x4ca7f4[_0x44a31b(0xdc)])===_0x271b9d[_0x44a31b(0xdc)]&&_0x44a31b(0xd9)in _0x4932a3[_0x44a31b(0xbd)]&&_0x4932a3[_0x44a31b(0xbd)][_0x44a31b(0xd9)]===_0x271b9d[_0x44a31b(0xd9)];});}var g=_0x111d97(0xdd),_='1.5.0';function v(_0x88956,_0x4ff289){return function(_0x4f93da,_0x54932b){_0x4ff289(_0x4f93da,_0x54932b,_0x88956);};}function y(_0xaf43b,_0x1db2a1,_0x5c17c3,_0x3141fd){var _0x4a4bd8=_0x111d97,_0x55da82=arguments['length'],_0xa58f0e=_0x55da82<0x3?_0x1db2a1:_0x3141fd===null?_0x3141fd=Object['getOwnPropertyDescriptor'](_0x1db2a1,_0x5c17c3):_0x3141fd,_0x261e95;if(typeof Reflect=='object'&&typeof Reflect[_0x4a4bd8(0xcf)]==_0x4a4bd8(0xce))_0xa58f0e=Reflect[_0x4a4bd8(0xcf)](_0xaf43b,_0x1db2a1,_0x5c17c3,_0x3141fd);else{for(var _0x33e88f=_0xaf43b[_0x4a4bd8(0xbf)]-0x1;_0x33e88f>=0x0;_0x33e88f--)(_0x261e95=_0xaf43b[_0x33e88f])&&(_0xa58f0e=(_0x55da82<0x3?_0x261e95(_0xa58f0e):_0x55da82>0x3?_0x261e95(_0x1db2a1,_0x5c17c3,_0xa58f0e):_0x261e95(_0x1db2a1,_0x5c17c3))||_0xa58f0e);}return _0x55da82>0x3&&_0xa58f0e&&Object[_0x4a4bd8(0xd3)](_0x1db2a1,_0x5c17c3,_0xa58f0e),_0xa58f0e;}function b(_0x396913){'@babel/helpers - typeof';var _0x55736d=_0x111d97;return b=typeof Symbol=='function'&&typeof Symbol['iterator']==_0x55736d(0xcc)?function(_0x1e77b4){return typeof _0x1e77b4;}:function(_0x3228a3){var _0x5c3052=_0x55736d;return _0x3228a3&&typeof Symbol==_0x5c3052(0xce)&&_0x3228a3[_0x5c3052(0xd5)]===Symbol&&_0x3228a3!==Symbol[_0x5c3052(0xbe)]?_0x5c3052(0xcc):typeof _0x3228a3;},b(_0x396913);}function x(_0x5781b5,_0x302a17){var _0x2a79fe=_0x111d97;if(b(_0x5781b5)!=_0x2a79fe(0xde)||!_0x5781b5)return _0x5781b5;var _0x27a5cf;if(typeof Symbol<'u'&&(_0x27a5cf=_0x5781b5[Symbol[_0x2a79fe(0xc2)]])!==void 0x0){var _0x493a62=_0x27a5cf[_0x2a79fe(0xc7)](_0x5781b5,_0x302a17||_0x2a79fe(0xc6));if(b(_0x493a62)!=_0x2a79fe(0xde))return _0x493a62;throw TypeError(_0x2a79fe(0xc4));}return(_0x302a17===_0x2a79fe(0xe2)?String:Number)(_0x5781b5);}function S(_0x1feb79){var _0x561750=_0x111d97,_0x47227f=x(_0x1feb79,_0x561750(0xe2));return b(_0x47227f)=='symbol'?_0x47227f:_0x47227f+'';}function C(_0x34a0d7,_0x28abdb,_0x47a618){var _0x370098=_0x111d97;return(_0x28abdb=S(_0x28abdb))in _0x34a0d7?Object[_0x370098(0xd3)](_0x34a0d7,_0x28abdb,{'value':_0x47a618,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x34a0d7[_0x28abdb]=_0x47a618,_0x34a0d7;}function _0x2b09(_0x209dbc,_0xe76e34){_0x209dbc=_0x209dbc-0xbd;var _0x1d0553=_0x1d05();var _0x2b090d=_0x1d0553[_0x209dbc];return _0x2b090d;}let w=class extends _0x57a561{constructor(_0x1cd3cc=d,_0xe37258,_0x3066e6){var _0x546303=_0x111d97;super(),this[_0x546303(0xd6)]=_0x1cd3cc,this[_0x546303(0xe4)]=_0xe37258,this['_configService']=_0x3066e6;let {..._0x249443}=_0x3c86cc({},d,this['_config']);this[_0x546303(0xe0)][_0x546303(0xc9)](u,_0x249443);}};C(w,_0x111d97(0xdb),'UNIVER_SHAPE_THREAD_COMMENT_PLUGIN'),C(w,_0x111d97(0xc0),g),C(w,_0x111d97(0xd1),_),C(w,'type',_0x24be8c[_0x111d97(0xe6)]),w=y([_0x4a24d5(_0x54d45a,_0x270182),v(0x1,_0x10159e(_0x1fdaf5)),v(0x2,_0x43e82d)],w);export{u as SHAPE_THREAD_COMMENT_PLUGIN_CONFIG_KEY,w as UniverShapeThreadCommentPlugin,p as createFloatingElementCommentAsync,m as getFloatingElementComments,f as getThreadCommentService,h as listFloatingElementCommentsAsync};
|
package/lib/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const _0x47ca30=_0x28ef;function _0x565b(){const _0x3ebc5a=['shapeId','BOARD_ELEMENT','8351728zDzfKS','hostType','196034upbYET','SLIDE_ELEMENT','_getThreadCommentService','ThreadCommentAnchorKind','871708joYjow','275040EZOIib','elementId','Unsupported\x20Shape\x20host\x20type:\x20','_shapeRef','160ROXaaf','174060SrHvFZ','set','DOC_DRAWING','getComments','UNIVER_SHEET','896CUSQKm','ThreadCommentFacadeService','get','anchor','UNIVER_DOC','3PcMTLW','listCommentsAsync','_injector','UNIVER_SLIDE','UNIVER_BOARD','subUnitId','10560hakjXk','1xhmauu','createCommentAsync','extend','filter','1829944Ehjsxf','kind','unitId'];_0x565b=function(){return _0x3ebc5a;};return _0x565b();}function _0x28ef(_0x4bd3e4,_0x51d658){_0x4bd3e4=_0x4bd3e4-0x148;const _0x565b95=_0x565b();let _0x28ef74=_0x565b95[_0x4bd3e4];return _0x28ef74;}(function(_0xb27163,_0x1de7f1){const _0x1ea361=_0x28ef,_0xe722dc=_0xb27163();while(!![]){try{const _0x4d026e=parseInt(_0x1ea361(0x159))/0x1*(-parseInt(_0x1ea361(0x164))/0x2)+-parseInt(_0x1ea361(0x152))/0x3*(parseInt(_0x1ea361(0x168))/0x4)+parseInt(_0x1ea361(0x169))/0x5+parseInt(_0x1ea361(0x158))/0x6*(-parseInt(_0x1ea361(0x14d))/0x7)+parseInt(_0x1ea361(0x15d))/0x8+-parseInt(_0x1ea361(0x148))/0x9*(parseInt(_0x1ea361(0x16d))/0xa)+parseInt(_0x1ea361(0x162))/0xb;if(_0x4d026e===_0x1de7f1)break;else _0xe722dc['push'](_0xe722dc['shift']());}catch(_0xcb12e3){_0xe722dc['push'](_0xe722dc['shift']());}}}(_0x565b,0x2ef4f));import{FShape as _0x12d471}from'@univerjs-pro/engine-shape/facade';import{UniverInstanceType as _0x1fc657}from'@univerjs/core';import*as _0x13b6d2 from'@univerjs/thread-comment';const r=new WeakMap();function i(_0x1bfbb8){const _0x551571=_0x28ef;switch(_0x1bfbb8){case _0x1fc657[_0x551571(0x14c)]:return _0x13b6d2[_0x551571(0x167)]['SHEET_DRAWING'];case _0x1fc657[_0x551571(0x151)]:return _0x13b6d2['ThreadCommentAnchorKind'][_0x551571(0x14a)];case _0x1fc657[_0x551571(0x155)]:return _0x13b6d2[_0x551571(0x167)][_0x551571(0x165)];case _0x1fc657[_0x551571(0x156)]:return _0x13b6d2[_0x551571(0x167)][_0x551571(0x161)];default:throw Error(_0x551571(0x16b)+_0x1bfbb8);}}var a=class extends _0x12d471{[_0x47ca30(0x166)](){const _0x4d7b1f=_0x47ca30;let _0x38b6e0=r['get'](this);if(_0x38b6e0)return _0x38b6e0;let _0x17229a=this[_0x4d7b1f(0x154)][_0x4d7b1f(0x14f)](_0x13b6d2[_0x4d7b1f(0x14e)]);return r[_0x4d7b1f(0x149)](this,_0x17229a),_0x17229a;}[_0x47ca30(0x15a)](_0x42bdc9,_0x367849={}){const _0x397e99=_0x47ca30;return this[_0x397e99(0x166)]()[_0x397e99(0x15a)]({..._0x367849,'unitId':this[_0x397e99(0x16c)][_0x397e99(0x15f)],'subUnitId':this[_0x397e99(0x16c)]['subUnitId'],'anchor':{'kind':i(this[_0x397e99(0x16c)][_0x397e99(0x163)]),'elementId':this['_shapeRef'][_0x397e99(0x160)],'pageId':this[_0x397e99(0x16c)][_0x397e99(0x157)]},'content':_0x42bdc9});}[_0x47ca30(0x14b)](){const _0x5a32f6=_0x47ca30;let _0x5e4641=i(this[_0x5a32f6(0x16c)][_0x5a32f6(0x163)]);return this[_0x5a32f6(0x166)]()[_0x5a32f6(0x14b)]({'unitIds':[this[_0x5a32f6(0x16c)][_0x5a32f6(0x15f)]],'subUnitIds':[this['_shapeRef'][_0x5a32f6(0x157)]],'anchorKinds':[_0x5e4641]})[_0x5a32f6(0x15c)](_0x23e1db=>{const _0x9aadfb=_0x5a32f6;var _0x2ffe91;return((_0x2ffe91=_0x23e1db[_0x9aadfb(0x150)])==null?void 0x0:_0x2ffe91['kind'])===_0x5e4641&&_0x9aadfb(0x16a)in _0x23e1db[_0x9aadfb(0x150)]&&_0x23e1db[_0x9aadfb(0x150)][_0x9aadfb(0x16a)]===this[_0x9aadfb(0x16c)][_0x9aadfb(0x160)];});}async[_0x47ca30(0x153)](){const _0x181dea=_0x47ca30;let _0x1d7be9=i(this['_shapeRef']['hostType']);return(await this['_getThreadCommentService']()[_0x181dea(0x153)]({'unitIds':[this[_0x181dea(0x16c)]['unitId']],'subUnitIds':[this[_0x181dea(0x16c)][_0x181dea(0x157)]],'anchorKinds':[_0x1d7be9]}))['filter'](_0x1e5a06=>{const _0x3e0d9a=_0x181dea;var _0xe25926;return((_0xe25926=_0x1e5a06['anchor'])==null?void 0x0:_0xe25926[_0x3e0d9a(0x15e)])===_0x1d7be9&&'elementId'in _0x1e5a06['anchor']&&_0x1e5a06[_0x3e0d9a(0x150)][_0x3e0d9a(0x16a)]===this[_0x3e0d9a(0x16c)][_0x3e0d9a(0x160)];});}};_0x12d471[_0x47ca30(0x15b)](a);export{a as FShapeThreadCommentMixin};
|
package/lib/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
function _0x1d05(){var _0x22b030=['function','decorate','25955kLHUMl','version','2421475hrxMkf','defineProperty','769545JHWMuu','constructor','_config','getComments','shape-thread-comment.config','elementId','get','pluginName','kind','@univerjs-pro/shape-thread-comment','object','subUnitId','_configService','1494hRoVdj','string','unitId','_injector','242349baoXFV','UNIVER_UNKNOWN','18351369rwgjFl','anchor','prototype','length','packageName','filter','toPrimitive','createCommentAsync','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','1738418kZoCzC','default','call','10EGerQT','setConfig','6389160XHVoOP','24dRxeML','symbol','listCommentsAsync'];_0x1d05=function(){return _0x22b030;};return _0x1d05();}var _0x111d97=_0x2b09;(function(_0x4ec228,_0x45498f){var _0x3f4606=_0x2b09,_0x1dfd53=_0x4ec228();while(!![]){try{var _0x39ad4c=-parseInt(_0x3f4606(0xd4))/0x1+parseInt(_0x3f4606(0xc5))/0x2+parseInt(_0x3f4606(0xe5))/0x3+-parseInt(_0x3f4606(0xca))/0x4+-parseInt(_0x3f4606(0xd0))/0x5*(-parseInt(_0x3f4606(0xe1))/0x6)+-parseInt(_0x3f4606(0xd2))/0x7*(parseInt(_0x3f4606(0xcb))/0x8)+-parseInt(_0x3f4606(0xe7))/0x9*(-parseInt(_0x3f4606(0xc8))/0xa);if(_0x39ad4c===_0x45498f)break;else _0x1dfd53['push'](_0x1dfd53['shift']());}catch(_0x401e38){_0x1dfd53['push'](_0x1dfd53['shift']());}}}(_0x1d05,0xd61b6));import{ThreadCommentFacadeService as _0x3290b4,UniverThreadCommentPlugin as _0x270182}from'@univerjs/thread-comment';import{UniverLicensePlugin as _0x54d45a}from'@univerjs-pro/license';import{DependentOn as _0x4a24d5,IConfigService as _0x43e82d,Inject as _0x10159e,Injector as _0x1fdaf5,Plugin as _0x57a561,UniverInstanceType as _0x24be8c,merge as _0x3c86cc}from'@univerjs/core';const u=_0x111d97(0xd8),d={};function f(_0x334ce7){var _0x2f2aa7=_0x111d97;return _0x334ce7[_0x2f2aa7(0xda)](_0x3290b4);}function p(_0x25e93d,_0x46715f,_0x155691,_0x4e0042){var _0x117148=_0x111d97;return _0x25e93d[_0x117148(0xc3)]({..._0x4e0042,'unitId':_0x46715f[_0x117148(0xe3)],'subUnitId':_0x46715f['subUnitId'],'anchor':{'kind':_0x46715f[_0x117148(0xdc)],'pageId':_0x46715f[_0x117148(0xdf)],'elementId':_0x46715f[_0x117148(0xd9)]},'content':_0x155691});}function m(_0x22eab9,_0x127d15){var _0x1509f4=_0x111d97;return _0x22eab9[_0x1509f4(0xd7)]({'unitIds':[_0x127d15[_0x1509f4(0xe3)]],'subUnitIds':[_0x127d15[_0x1509f4(0xdf)]],'anchorKinds':[_0x127d15[_0x1509f4(0xdc)]]})[_0x1509f4(0xc1)](_0x1a9207=>{var _0x4d017d=_0x1509f4,_0x3a570d;return((_0x3a570d=_0x1a9207[_0x4d017d(0xbd)])==null?void 0x0:_0x3a570d[_0x4d017d(0xdc)])===_0x127d15[_0x4d017d(0xdc)]&&_0x4d017d(0xd9)in _0x1a9207[_0x4d017d(0xbd)]&&_0x1a9207[_0x4d017d(0xbd)][_0x4d017d(0xd9)]===_0x127d15[_0x4d017d(0xd9)];});}async function h(_0x3c75b1,_0x271b9d){var _0x2536bd=_0x111d97;return(await _0x3c75b1[_0x2536bd(0xcd)]({'unitIds':[_0x271b9d['unitId']],'subUnitIds':[_0x271b9d['subUnitId']],'anchorKinds':[_0x271b9d[_0x2536bd(0xdc)]]}))[_0x2536bd(0xc1)](_0x4932a3=>{var _0x44a31b=_0x2536bd,_0x4ca7f4;return((_0x4ca7f4=_0x4932a3['anchor'])==null?void 0x0:_0x4ca7f4[_0x44a31b(0xdc)])===_0x271b9d[_0x44a31b(0xdc)]&&_0x44a31b(0xd9)in _0x4932a3[_0x44a31b(0xbd)]&&_0x4932a3[_0x44a31b(0xbd)][_0x44a31b(0xd9)]===_0x271b9d[_0x44a31b(0xd9)];});}var g=_0x111d97(0xdd),_='1.5.0';function v(_0x88956,_0x4ff289){return function(_0x4f93da,_0x54932b){_0x4ff289(_0x4f93da,_0x54932b,_0x88956);};}function y(_0xaf43b,_0x1db2a1,_0x5c17c3,_0x3141fd){var _0x4a4bd8=_0x111d97,_0x55da82=arguments['length'],_0xa58f0e=_0x55da82<0x3?_0x1db2a1:_0x3141fd===null?_0x3141fd=Object['getOwnPropertyDescriptor'](_0x1db2a1,_0x5c17c3):_0x3141fd,_0x261e95;if(typeof Reflect=='object'&&typeof Reflect[_0x4a4bd8(0xcf)]==_0x4a4bd8(0xce))_0xa58f0e=Reflect[_0x4a4bd8(0xcf)](_0xaf43b,_0x1db2a1,_0x5c17c3,_0x3141fd);else{for(var _0x33e88f=_0xaf43b[_0x4a4bd8(0xbf)]-0x1;_0x33e88f>=0x0;_0x33e88f--)(_0x261e95=_0xaf43b[_0x33e88f])&&(_0xa58f0e=(_0x55da82<0x3?_0x261e95(_0xa58f0e):_0x55da82>0x3?_0x261e95(_0x1db2a1,_0x5c17c3,_0xa58f0e):_0x261e95(_0x1db2a1,_0x5c17c3))||_0xa58f0e);}return _0x55da82>0x3&&_0xa58f0e&&Object[_0x4a4bd8(0xd3)](_0x1db2a1,_0x5c17c3,_0xa58f0e),_0xa58f0e;}function b(_0x396913){'@babel/helpers - typeof';var _0x55736d=_0x111d97;return b=typeof Symbol=='function'&&typeof Symbol['iterator']==_0x55736d(0xcc)?function(_0x1e77b4){return typeof _0x1e77b4;}:function(_0x3228a3){var _0x5c3052=_0x55736d;return _0x3228a3&&typeof Symbol==_0x5c3052(0xce)&&_0x3228a3[_0x5c3052(0xd5)]===Symbol&&_0x3228a3!==Symbol[_0x5c3052(0xbe)]?_0x5c3052(0xcc):typeof _0x3228a3;},b(_0x396913);}function x(_0x5781b5,_0x302a17){var _0x2a79fe=_0x111d97;if(b(_0x5781b5)!=_0x2a79fe(0xde)||!_0x5781b5)return _0x5781b5;var _0x27a5cf;if(typeof Symbol<'u'&&(_0x27a5cf=_0x5781b5[Symbol[_0x2a79fe(0xc2)]])!==void 0x0){var _0x493a62=_0x27a5cf[_0x2a79fe(0xc7)](_0x5781b5,_0x302a17||_0x2a79fe(0xc6));if(b(_0x493a62)!=_0x2a79fe(0xde))return _0x493a62;throw TypeError(_0x2a79fe(0xc4));}return(_0x302a17===_0x2a79fe(0xe2)?String:Number)(_0x5781b5);}function S(_0x1feb79){var _0x561750=_0x111d97,_0x47227f=x(_0x1feb79,_0x561750(0xe2));return b(_0x47227f)=='symbol'?_0x47227f:_0x47227f+'';}function C(_0x34a0d7,_0x28abdb,_0x47a618){var _0x370098=_0x111d97;return(_0x28abdb=S(_0x28abdb))in _0x34a0d7?Object[_0x370098(0xd3)](_0x34a0d7,_0x28abdb,{'value':_0x47a618,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x34a0d7[_0x28abdb]=_0x47a618,_0x34a0d7;}function _0x2b09(_0x209dbc,_0xe76e34){_0x209dbc=_0x209dbc-0xbd;var _0x1d0553=_0x1d05();var _0x2b090d=_0x1d0553[_0x209dbc];return _0x2b090d;}let w=class extends _0x57a561{constructor(_0x1cd3cc=d,_0xe37258,_0x3066e6){var _0x546303=_0x111d97;super(),this[_0x546303(0xd6)]=_0x1cd3cc,this[_0x546303(0xe4)]=_0xe37258,this['_configService']=_0x3066e6;let {..._0x249443}=_0x3c86cc({},d,this['_config']);this[_0x546303(0xe0)][_0x546303(0xc9)](u,_0x249443);}};C(w,_0x111d97(0xdb),'UNIVER_SHAPE_THREAD_COMMENT_PLUGIN'),C(w,_0x111d97(0xc0),g),C(w,_0x111d97(0xd1),_),C(w,'type',_0x24be8c[_0x111d97(0xe6)]),w=y([_0x4a24d5(_0x54d45a,_0x270182),v(0x1,_0x10159e(_0x1fdaf5)),v(0x2,_0x43e82d)],w);export{u as SHAPE_THREAD_COMMENT_PLUGIN_CONFIG_KEY,w as UniverShapeThreadCommentPlugin,p as createFloatingElementCommentAsync,m as getFloatingElementComments,f as getThreadCommentService,h as listFloatingElementCommentsAsync};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { Injector } from '@univerjs/core';
|
|
2
|
+
import type { ICreateThreadCommentOptions, IFacadeThreadCommentInfo, IThreadCommentElementAnchor, ThreadCommentContent } from '@univerjs/thread-comment';
|
|
3
|
+
import { ThreadCommentFacadeService } from '@univerjs/thread-comment';
|
|
4
|
+
type ThreadCommentService = Pick<ThreadCommentFacadeService, 'createCommentAsync' | 'getComments' | 'listCommentsAsync'>;
|
|
5
|
+
export declare function getThreadCommentService(injector: Injector): ThreadCommentFacadeService;
|
|
6
|
+
export type IFloatingElementCommentCreateOptions = Omit<ICreateThreadCommentOptions, 'unitId' | 'subUnitId' | 'anchor' | 'content'>;
|
|
7
|
+
export interface IFloatingElementCommentTarget {
|
|
8
|
+
unitId: string;
|
|
9
|
+
subUnitId: string;
|
|
10
|
+
elementId: string;
|
|
11
|
+
kind: IThreadCommentElementAnchor['kind'];
|
|
12
|
+
}
|
|
13
|
+
export declare function createFloatingElementCommentAsync(service: ThreadCommentService, target: IFloatingElementCommentTarget, content: ThreadCommentContent, options: IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
14
|
+
export declare function getFloatingElementComments(service: ThreadCommentService, target: IFloatingElementCommentTarget): IFacadeThreadCommentInfo[];
|
|
15
|
+
export declare function listFloatingElementCommentsAsync(service: ThreadCommentService, target: IFloatingElementCommentTarget): Promise<IFacadeThreadCommentInfo[]>;
|
|
16
|
+
export {};
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
export {
|
|
2
|
-
export { FDocumentChartThreadCommentMixin, type IFDocumentChartThreadCommentMixin } from './f-doc-chart';
|
|
3
|
-
export { FDocumentImageThreadCommentMixin, type IFDocumentImageThreadCommentMixin } from './f-doc-image';
|
|
1
|
+
export type { IFloatingElementCommentCreateOptions, IFloatingElementCommentTarget } from '../element-comment';
|
|
4
2
|
export type { IFShapeThreadCommentMixin, IShapeCommentCreateOptions } from './f-shape';
|
|
5
3
|
export { FShapeThreadCommentMixin } from './f-shape';
|
|
6
|
-
export { FSheetChartThreadCommentMixin, type IFSheetChartThreadCommentMixin } from './f-sheet-chart';
|
|
7
|
-
export { FSheetImageThreadCommentMixin, type IFSheetImageThreadCommentMixin } from './f-sheet-image';
|
package/lib/types/index.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
1
|
export { SHAPE_THREAD_COMMENT_PLUGIN_CONFIG_KEY } from './config/config';
|
|
2
2
|
export type { IUniverShapeThreadCommentConfig } from './config/config';
|
|
3
|
+
export type { IFloatingElementCommentCreateOptions, IFloatingElementCommentTarget } from './element-comment';
|
|
4
|
+
export { createFloatingElementCommentAsync, getFloatingElementComments, getThreadCommentService, listFloatingElementCommentsAsync, } from './element-comment';
|
|
3
5
|
export { UniverShapeThreadCommentPlugin } from './plugin';
|
package/lib/umd/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x35f3db,_0x3fe12a){var _0x32b653=_0x3054,_0x45e6d3=_0x35f3db();while(!![]){try{var _0x2d55bb=-parseInt(_0x32b653(0xae))/0x1+parseInt(_0x32b653(0xad))/0x2*(-parseInt(_0x32b653(0xc5))/0x3)+parseInt(_0x32b653(0x9e))/0x4+parseInt(_0x32b653(0xa5))/0x5+-parseInt(_0x32b653(0xb4))/0x6*(parseInt(_0x32b653(0xcb))/0x7)+-parseInt(_0x32b653(0xd6))/0x8*(-parseInt(_0x32b653(0xd2))/0x9)+parseInt(_0x32b653(0x95))/0xa*(parseInt(_0x32b653(0xc7))/0xb);if(_0x2d55bb===_0x3fe12a)break;else _0x45e6d3['push'](_0x45e6d3['shift']());}catch(_0xc57ed9){_0x45e6d3['push'](_0x45e6d3['shift']());}}}(_0x5d2a,0x8f07e),function(_0x18cf50,_0x52b5fc){var _0x48857a=_0x3054;typeof exports==_0x48857a(0xb6)&&typeof module<'u'?_0x52b5fc(exports,require('@univerjs-pro/docs-chart/facade'),require('@univerjs/thread-comment'),require('@univerjs/docs-drawing/facade'),require('@univerjs-pro/engine-shape/facade'),require('@univerjs/core'),require('@univerjs-pro/sheets-chart/facade'),require('@univerjs/sheets-drawing/facade')):typeof define==_0x48857a(0xd7)&&define['amd']?define([_0x48857a(0xca),'@univerjs-pro/docs-chart/facade',_0x48857a(0xcd),_0x48857a(0x8c),_0x48857a(0xcf),_0x48857a(0xb7),'@univerjs-pro/sheets-chart/facade','@univerjs/sheets-drawing/facade'],_0x52b5fc):(_0x18cf50=typeof globalThis<'u'?globalThis:_0x18cf50||self,_0x52b5fc(_0x18cf50['UniverProShapeThreadCommentFacade']={},_0x18cf50[_0x48857a(0xb2)],_0x18cf50[_0x48857a(0x99)],_0x18cf50[_0x48857a(0xc4)],_0x18cf50[_0x48857a(0xac)],_0x18cf50[_0x48857a(0x9c)],_0x18cf50[_0x48857a(0x96)],_0x18cf50[_0x48857a(0xce)]));}(this,function(_0x4fd66b,_0x3e66cd,_0x2cf618,_0x34fe4d,_0x5b2330,_0x72173,_0x1540da,_0x4371f4){var _0x4572a6=_0x3054;Object[_0x4572a6(0xb0)](_0x4fd66b,Symbol[_0x4572a6(0x98)],{'value':_0x4572a6(0x90)});var _0x598e95=Object[_0x4572a6(0xbf)],_0x229110=Object[_0x4572a6(0xb0)],_0x5c44df=Object[_0x4572a6(0x8b)],_0xe31871=Object[_0x4572a6(0x8f)],_0x10f142=Object[_0x4572a6(0xbc)],_0x515b84=Object[_0x4572a6(0xd4)]['hasOwnProperty'],_0xa4d574=(_0x5bd3ae,_0x4a6ebc,_0x46c26d,_0x11b5bb)=>{var _0x289da5=_0x4572a6;if(_0x4a6ebc&&typeof _0x4a6ebc==_0x289da5(0xb6)||typeof _0x4a6ebc==_0x289da5(0xd7)){for(var _0x2afb9b=_0xe31871(_0x4a6ebc),_0x2c3965=0x0,_0x31ca16=_0x2afb9b[_0x289da5(0xa6)],_0x59abe6;_0x2c3965<_0x31ca16;_0x2c3965++)_0x59abe6=_0x2afb9b[_0x2c3965],!_0x515b84[_0x289da5(0xaa)](_0x5bd3ae,_0x59abe6)&&_0x59abe6!==_0x46c26d&&_0x229110(_0x5bd3ae,_0x59abe6,{'get':(_0x1073df=>_0x4a6ebc[_0x1073df])['bind'](null,_0x59abe6),'enumerable':!(_0x11b5bb=_0x5c44df(_0x4a6ebc,_0x59abe6))||_0x11b5bb['enumerable']});}return _0x5bd3ae;};_0x2cf618=((_0x1e194d,_0x41c0e3,_0x418ae0)=>(_0x418ae0=_0x1e194d==null?{}:_0x598e95(_0x10f142(_0x1e194d)),_0xa4d574(_0x41c0e3||!_0x1e194d||!_0x1e194d[_0x4572a6(0xd0)]||!_0x515b84[_0x4572a6(0xaa)](_0x1e194d,_0x4572a6(0x9f))?_0x229110(_0x418ae0,'default',{'value':_0x1e194d,'enumerable':!0x0}):_0x418ae0,_0x1e194d)))(_0x2cf618);let _0x1b42d8=new WeakMap();function _0x33d8b0(_0x566f5d){var _0x21b21b=_0x4572a6;let _0x6a0cda=_0x1b42d8[_0x21b21b(0xa7)](_0x566f5d);if(_0x6a0cda)return _0x6a0cda;let _0x33b8fd=_0x566f5d[_0x21b21b(0xa7)](_0x2cf618[_0x21b21b(0x91)]);return _0x1b42d8[_0x21b21b(0x8e)](_0x566f5d,_0x33b8fd),_0x33b8fd;}function _0x4b74ea(_0x1c5039,_0x15f068,_0x31502c,_0x104ad9){var _0x4c65b4=_0x4572a6;return _0x1c5039[_0x4c65b4(0xab)]({..._0x104ad9,'unitId':_0x15f068[_0x4c65b4(0xbe)],'subUnitId':_0x15f068[_0x4c65b4(0xc3)],'anchor':{'kind':_0x15f068[_0x4c65b4(0xa4)],'pageId':_0x15f068[_0x4c65b4(0xc3)],'elementId':_0x15f068[_0x4c65b4(0xa8)]},'content':_0x31502c});}function _0x118bb4(_0x53a1b1,_0x2fb64a){var _0x28922c=_0x4572a6;return _0x53a1b1[_0x28922c(0x8d)]({'unitIds':[_0x2fb64a[_0x28922c(0xbe)]],'subUnitIds':[_0x2fb64a['subUnitId']],'anchorKinds':[_0x2fb64a['kind']]})[_0x28922c(0x97)](_0x20cee5=>{var _0x5604c1=_0x28922c,_0x35df79;return((_0x35df79=_0x20cee5[_0x5604c1(0x92)])==null?void 0x0:_0x35df79['kind'])===_0x2fb64a[_0x5604c1(0xa4)]&&'elementId'in _0x20cee5[_0x5604c1(0x92)]&&_0x20cee5[_0x5604c1(0x92)]['elementId']===_0x2fb64a[_0x5604c1(0xa8)];});}async function _0x46e08a(_0x559c17,_0x4fe838){var _0x5bc042=_0x4572a6;return(await _0x559c17[_0x5bc042(0xa1)]({'unitIds':[_0x4fe838[_0x5bc042(0xbe)]],'subUnitIds':[_0x4fe838['subUnitId']],'anchorKinds':[_0x4fe838[_0x5bc042(0xa4)]]}))[_0x5bc042(0x97)](_0xd8806c=>{var _0x48d849=_0x5bc042,_0x48e94b;return((_0x48e94b=_0xd8806c[_0x48d849(0x92)])==null?void 0x0:_0x48e94b[_0x48d849(0xa4)])===_0x4fe838[_0x48d849(0xa4)]&&_0x48d849(0xa8)in _0xd8806c[_0x48d849(0x92)]&&_0xd8806c[_0x48d849(0x92)]['elementId']===_0x4fe838[_0x48d849(0xa8)];});}var _0x32f95f=class extends _0x3e66cd[_0x4572a6(0xbb)]{['createCommentAsync'](_0x261c09,_0x1f9a75={}){var _0x49b19f=_0x4572a6;return _0x4b74ea(_0x33d8b0(this[_0x49b19f(0xa0)]),this[_0x49b19f(0xa2)](),_0x261c09,_0x1f9a75);}[_0x4572a6(0x8d)](){var _0xf696cb=_0x4572a6;return _0x118bb4(_0x33d8b0(this[_0xf696cb(0xa0)]),this[_0xf696cb(0xa2)]());}[_0x4572a6(0xa1)](){var _0x36de1c=_0x4572a6;return _0x46e08a(_0x33d8b0(this[_0x36de1c(0xa0)]),this['_commentTarget']());}[_0x4572a6(0xa2)](){var _0x3486ec=_0x4572a6;return{'unitId':this['unitId'],'subUnitId':this[_0x3486ec(0xbe)],'elementId':this['getDrawingId'](),'kind':_0x2cf618['ThreadCommentAnchorKind'][_0x3486ec(0x9d)]};}};_0x3e66cd[_0x4572a6(0xbb)][_0x4572a6(0xb3)](_0x32f95f);var _0x19ebd6=class extends _0x34fe4d['FDocumentImage']{[_0x4572a6(0xab)](_0x2154aa,_0x499233={}){var _0x7eea8e=_0x4572a6;return _0x4b74ea(_0x33d8b0(this[_0x7eea8e(0xa0)]),this[_0x7eea8e(0xa2)](),_0x2154aa,_0x499233);}[_0x4572a6(0x8d)](){var _0x33b9bb=_0x4572a6;return _0x118bb4(_0x33d8b0(this[_0x33b9bb(0xa0)]),this[_0x33b9bb(0xa2)]());}[_0x4572a6(0xa1)](){var _0x3936af=_0x4572a6;return _0x46e08a(_0x33d8b0(this[_0x3936af(0xa0)]),this[_0x3936af(0xa2)]());}['_commentTarget'](){var _0x4db24e=_0x4572a6;return{'unitId':this[_0x4db24e(0xc0)](),'subUnitId':this[_0x4db24e(0xc0)](),'elementId':this[_0x4db24e(0x94)](),'kind':_0x2cf618[_0x4db24e(0xb8)][_0x4db24e(0x9d)]};}};_0x34fe4d[_0x4572a6(0x9b)][_0x4572a6(0xb3)](_0x19ebd6);let _0x2258e4=new WeakMap();function _0x19b141(_0x2898b2){var _0x32f774=_0x4572a6;switch(_0x2898b2){case _0x72173[_0x32f774(0xcc)][_0x32f774(0xb9)]:return _0x2cf618['ThreadCommentAnchorKind'][_0x32f774(0xc9)];case _0x72173[_0x32f774(0xcc)][_0x32f774(0xbd)]:return _0x2cf618[_0x32f774(0xb8)][_0x32f774(0x9d)];case _0x72173['UniverInstanceType'][_0x32f774(0xaf)]:return _0x2cf618[_0x32f774(0xb8)][_0x32f774(0xd3)];case _0x72173[_0x32f774(0xcc)]['UNIVER_BOARD']:return _0x2cf618[_0x32f774(0xb8)][_0x32f774(0xc2)];default:throw Error(_0x32f774(0x93)+_0x2898b2);}}var _0x33fc2d=class extends _0x5b2330[_0x4572a6(0xba)]{[_0x4572a6(0xc6)](){var _0xf1d665=_0x4572a6;let _0x5efa16=_0x2258e4[_0xf1d665(0xa7)](this);if(_0x5efa16)return _0x5efa16;let _0xe91c98=this[_0xf1d665(0xa0)]['get'](_0x2cf618[_0xf1d665(0x91)]);return _0x2258e4[_0xf1d665(0x8e)](this,_0xe91c98),_0xe91c98;}[_0x4572a6(0xab)](_0x4529b3,_0x112786={}){var _0x284c06=_0x4572a6;return this['_getThreadCommentService']()[_0x284c06(0xab)]({..._0x112786,'unitId':this[_0x284c06(0xc1)][_0x284c06(0xbe)],'subUnitId':this['_shapeRef'][_0x284c06(0xc3)],'anchor':{'kind':_0x19b141(this['_shapeRef']['hostType']),'elementId':this[_0x284c06(0xc1)]['shapeId'],'pageId':this[_0x284c06(0xc1)]['subUnitId']},'content':_0x4529b3});}['getComments'](){var _0x365928=_0x4572a6;let _0x4672b8=_0x19b141(this[_0x365928(0xc1)][_0x365928(0x8a)]);return this[_0x365928(0xc6)]()[_0x365928(0x8d)]({'unitIds':[this[_0x365928(0xc1)]['unitId']],'subUnitIds':[this[_0x365928(0xc1)][_0x365928(0xc3)]],'anchorKinds':[_0x4672b8]})[_0x365928(0x97)](_0x105486=>{var _0x5d72f2=_0x365928,_0xd96454;return((_0xd96454=_0x105486[_0x5d72f2(0x92)])==null?void 0x0:_0xd96454['kind'])===_0x4672b8&&_0x5d72f2(0xa8)in _0x105486[_0x5d72f2(0x92)]&&_0x105486[_0x5d72f2(0x92)][_0x5d72f2(0xa8)]===this[_0x5d72f2(0xc1)][_0x5d72f2(0x9a)];});}async[_0x4572a6(0xa1)](){var _0x1e1f85=_0x4572a6;let _0x9af002=_0x19b141(this[_0x1e1f85(0xc1)][_0x1e1f85(0x8a)]);return(await this[_0x1e1f85(0xc6)]()[_0x1e1f85(0xa1)]({'unitIds':[this[_0x1e1f85(0xc1)][_0x1e1f85(0xbe)]],'subUnitIds':[this['_shapeRef'][_0x1e1f85(0xc3)]],'anchorKinds':[_0x9af002]}))[_0x1e1f85(0x97)](_0x251451=>{var _0xefecca=_0x1e1f85,_0xe6513c;return((_0xe6513c=_0x251451[_0xefecca(0x92)])==null?void 0x0:_0xe6513c[_0xefecca(0xa4)])===_0x9af002&&_0xefecca(0xa8)in _0x251451[_0xefecca(0x92)]&&_0x251451[_0xefecca(0x92)][_0xefecca(0xa8)]===this[_0xefecca(0xc1)][_0xefecca(0x9a)];});}};_0x5b2330[_0x4572a6(0xba)][_0x4572a6(0xb3)](_0x33fc2d);var _0x207265=class extends _0x1540da[_0x4572a6(0xd5)]{[_0x4572a6(0xab)](_0x330b10,_0x14d3a7={}){var _0x501b9c=_0x4572a6;return _0x4b74ea(_0x33d8b0(this['_injector']),this[_0x501b9c(0xa2)](),_0x330b10,_0x14d3a7);}[_0x4572a6(0x8d)](){var _0x2fcea0=_0x4572a6;return _0x118bb4(_0x33d8b0(this[_0x2fcea0(0xa0)]),this[_0x2fcea0(0xa2)]());}[_0x4572a6(0xa1)](){var _0x13f531=_0x4572a6;return _0x46e08a(_0x33d8b0(this[_0x13f531(0xa0)]),this[_0x13f531(0xa2)]());}['_commentTarget'](){var _0x58d788=_0x4572a6;return{'unitId':this[_0x58d788(0xbe)],'subUnitId':this[_0x58d788(0xc3)],'elementId':this[_0x58d788(0xa3)],'kind':_0x2cf618[_0x58d788(0xb8)][_0x58d788(0xc9)]};}};_0x1540da[_0x4572a6(0xd5)][_0x4572a6(0xb3)](_0x207265);var _0x4d9f9e=class extends _0x4371f4[_0x4572a6(0xb1)]{['createCommentAsync'](_0x525ec2,_0x550579={}){var _0x3d831a=_0x4572a6;return _0x4b74ea(_0x33d8b0(this['_injector']),this[_0x3d831a(0xa2)](),_0x525ec2,_0x550579);}[_0x4572a6(0x8d)](){var _0x4f841d=_0x4572a6;return _0x118bb4(_0x33d8b0(this[_0x4f841d(0xa0)]),this[_0x4f841d(0xa2)]());}[_0x4572a6(0xa1)](){var _0x3d1e66=_0x4572a6;return _0x46e08a(_0x33d8b0(this[_0x3d1e66(0xa0)]),this[_0x3d1e66(0xa2)]());}[_0x4572a6(0xa2)](){var _0x4c1106=_0x4572a6;return{'unitId':this['getUnitId'](),'subUnitId':this['getSubUnitId'](),'elementId':this[_0x4c1106(0x94)](),'kind':_0x2cf618[_0x4c1106(0xb8)][_0x4c1106(0xc9)]};}};_0x4371f4['FOverGridImage']['extend'](_0x4d9f9e),_0x4fd66b[_0x4572a6(0xa9)]=_0x32f95f,_0x4fd66b[_0x4572a6(0xc8)]=_0x19ebd6,_0x4fd66b['FShapeThreadCommentMixin']=_0x33fc2d,_0x4fd66b[_0x4572a6(0xb5)]=_0x207265,_0x4fd66b[_0x4572a6(0xd1)]=_0x4d9f9e;}));function _0x3054(_0x1d57d9,_0x17a7d5){_0x1d57d9=_0x1d57d9-0x8a;var _0x5d2a4b=_0x5d2a();var _0x305480=_0x5d2a4b[_0x1d57d9];return _0x305480;}function _0x5d2a(){var _0x181cc9=['kind','734200aTAARq','length','get','elementId','FDocumentChartThreadCommentMixin','call','createCommentAsync','UniverProEngineShapeFacade','2pgThhH','709242OmRXIH','UNIVER_SLIDE','defineProperty','FOverGridImage','UniverProDocsChartFacade','extend','258soGhrH','FSheetChartThreadCommentMixin','object','@univerjs/core','ThreadCommentAnchorKind','UNIVER_SHEET','FShape','FDocumentChart','getPrototypeOf','UNIVER_DOC','unitId','create','getUnitId','_shapeRef','BOARD_ELEMENT','subUnitId','UniverDocsDrawingFacade','2615223DQPSYx','_getThreadCommentService','3410DFCibb','FDocumentImageThreadCommentMixin','SHEET_DRAWING','exports','182651JqrxaC','UniverInstanceType','@univerjs/thread-comment','UniverSheetsDrawingFacade','@univerjs-pro/engine-shape/facade','__esModule','FSheetImageThreadCommentMixin','131130dYAYGs','SLIDE_ELEMENT','prototype','FSheetChart','496tMUNWk','function','hostType','getOwnPropertyDescriptor','@univerjs/docs-drawing/facade','getComments','set','getOwnPropertyNames','Module','ThreadCommentFacadeService','anchor','Unsupported\x20Shape\x20host\x20type:\x20','getId','40130JaQitV','UniverProSheetsChartFacade','filter','toStringTag','UniverThreadComment','shapeId','FDocumentImage','UniverCore','DOC_DRAWING','3978504nQDDJo','default','_injector','listCommentsAsync','_commentTarget','chartId'];_0x5d2a=function(){return _0x181cc9;};return _0x5d2a();}
|
|
1
|
+
(function(_0x5217e8,_0x1c1c6e){const _0x4cbbfa=_0x29c4,_0x1dd18c=_0x5217e8();while(!![]){try{const _0x2c7d21=parseInt(_0x4cbbfa(0x1b7))/0x1+-parseInt(_0x4cbbfa(0x191))/0x2+-parseInt(_0x4cbbfa(0x198))/0x3*(parseInt(_0x4cbbfa(0x1b9))/0x4)+-parseInt(_0x4cbbfa(0x184))/0x5+parseInt(_0x4cbbfa(0x1bc))/0x6*(-parseInt(_0x4cbbfa(0x192))/0x7)+parseInt(_0x4cbbfa(0x1ae))/0x8*(parseInt(_0x4cbbfa(0x1b8))/0x9)+parseInt(_0x4cbbfa(0x1ab))/0xa*(parseInt(_0x4cbbfa(0x1a8))/0xb);if(_0x2c7d21===_0x1c1c6e)break;else _0x1dd18c['push'](_0x1dd18c['shift']());}catch(_0x1f792b){_0x1dd18c['push'](_0x1dd18c['shift']());}}}(_0x951f,0xab84b),function(_0xbaf569,_0x198e7e){const _0x2d99d8=_0x29c4;typeof exports==_0x2d99d8(0x1a0)&&typeof module<'u'?_0x198e7e(exports,require('@univerjs-pro/engine-shape/facade'),require('@univerjs/core'),require('@univerjs/thread-comment')):typeof define==_0x2d99d8(0x1a6)&&define[_0x2d99d8(0x195)]?define([_0x2d99d8(0x1a9),_0x2d99d8(0x196),'@univerjs/core',_0x2d99d8(0x19b)],_0x198e7e):(_0xbaf569=typeof globalThis<'u'?globalThis:_0xbaf569||self,_0x198e7e(_0xbaf569[_0x2d99d8(0x1a2)]={},_0xbaf569[_0x2d99d8(0x18a)],_0xbaf569['UniverCore'],_0xbaf569[_0x2d99d8(0x194)]));}(this,function(_0x1d48fc,_0x37c0eb,_0x5aa170,_0x68dad){const _0x3415c7=_0x29c4;Object[_0x3415c7(0x1a3)](_0x1d48fc,Symbol['toStringTag'],{'value':_0x3415c7(0x1bb)});var _0x10f3ea=Object[_0x3415c7(0x188)],_0x3bb19e=Object[_0x3415c7(0x1a3)],_0x4f00ae=Object['getOwnPropertyDescriptor'],_0x116385=Object[_0x3415c7(0x193)],_0x5dd619=Object['getPrototypeOf'],_0x143c6c=Object[_0x3415c7(0x1a1)][_0x3415c7(0x1ad)],_0x2ff4b9=(_0x15f1d6,_0x52ece5,_0x4f55b3,_0x2fb974)=>{const _0x15b65e=_0x3415c7;if(_0x52ece5&&typeof _0x52ece5=='object'||typeof _0x52ece5=='function'){for(var _0x2752ee=_0x116385(_0x52ece5),_0x5baa19=0x0,_0x53a2e2=_0x2752ee['length'],_0x2fbcf1;_0x5baa19<_0x53a2e2;_0x5baa19++)_0x2fbcf1=_0x2752ee[_0x5baa19],!_0x143c6c[_0x15b65e(0x18d)](_0x15f1d6,_0x2fbcf1)&&_0x2fbcf1!==_0x4f55b3&&_0x3bb19e(_0x15f1d6,_0x2fbcf1,{'get':(_0x18c37f=>_0x52ece5[_0x18c37f])[_0x15b65e(0x1a4)](null,_0x2fbcf1),'enumerable':!(_0x2fb974=_0x4f00ae(_0x52ece5,_0x2fbcf1))||_0x2fb974[_0x15b65e(0x19a)]});}return _0x15f1d6;};_0x68dad=((_0x2cf621,_0x2c14fe,_0x5d2549)=>(_0x5d2549=_0x2cf621==null?{}:_0x10f3ea(_0x5dd619(_0x2cf621)),_0x2ff4b9(_0x2c14fe||!_0x2cf621||!_0x2cf621['__esModule']||!_0x143c6c[_0x3415c7(0x18d)](_0x2cf621,_0x3415c7(0x1b0))?_0x3bb19e(_0x5d2549,_0x3415c7(0x1b0),{'value':_0x2cf621,'enumerable':!0x0}):_0x5d2549,_0x2cf621)))(_0x68dad);let _0x50c99c=new WeakMap();function _0x1d07e7(_0xd234cc){const _0x4ec4e6=_0x3415c7;switch(_0xd234cc){case _0x5aa170[_0x4ec4e6(0x1aa)][_0x4ec4e6(0x189)]:return _0x68dad['ThreadCommentAnchorKind'][_0x4ec4e6(0x1bd)];case _0x5aa170[_0x4ec4e6(0x1aa)][_0x4ec4e6(0x1a5)]:return _0x68dad[_0x4ec4e6(0x19d)][_0x4ec4e6(0x1b4)];case _0x5aa170[_0x4ec4e6(0x1aa)][_0x4ec4e6(0x18b)]:return _0x68dad[_0x4ec4e6(0x19d)][_0x4ec4e6(0x18c)];case _0x5aa170[_0x4ec4e6(0x1aa)][_0x4ec4e6(0x185)]:return _0x68dad[_0x4ec4e6(0x19d)]['BOARD_ELEMENT'];default:throw Error(_0x4ec4e6(0x1ac)+_0xd234cc);}}var _0x2acc77=class extends _0x37c0eb['FShape']{[_0x3415c7(0x190)](){const _0x3db9bb=_0x3415c7;let _0x217103=_0x50c99c[_0x3db9bb(0x1b5)](this);if(_0x217103)return _0x217103;let _0x4bb4e7=this[_0x3db9bb(0x1b1)][_0x3db9bb(0x1b5)](_0x68dad['ThreadCommentFacadeService']);return _0x50c99c[_0x3db9bb(0x18f)](this,_0x4bb4e7),_0x4bb4e7;}[_0x3415c7(0x19e)](_0x25bb40,_0x32577a={}){const _0x162e9b=_0x3415c7;return this['_getThreadCommentService']()[_0x162e9b(0x19e)]({..._0x32577a,'unitId':this[_0x162e9b(0x186)][_0x162e9b(0x1b6)],'subUnitId':this['_shapeRef']['subUnitId'],'anchor':{'kind':_0x1d07e7(this['_shapeRef'][_0x162e9b(0x18e)]),'elementId':this[_0x162e9b(0x186)][_0x162e9b(0x1b3)],'pageId':this[_0x162e9b(0x186)][_0x162e9b(0x199)]},'content':_0x25bb40});}[_0x3415c7(0x1ba)](){const _0x1092c1=_0x3415c7;let _0x223484=_0x1d07e7(this['_shapeRef'][_0x1092c1(0x18e)]);return this[_0x1092c1(0x190)]()[_0x1092c1(0x1ba)]({'unitIds':[this['_shapeRef'][_0x1092c1(0x1b6)]],'subUnitIds':[this[_0x1092c1(0x186)]['subUnitId']],'anchorKinds':[_0x223484]})[_0x1092c1(0x1a7)](_0xa67d67=>{const _0x1a48e5=_0x1092c1;var _0x460e43;return((_0x460e43=_0xa67d67['anchor'])==null?void 0x0:_0x460e43[_0x1a48e5(0x1b2)])===_0x223484&&_0x1a48e5(0x197)in _0xa67d67['anchor']&&_0xa67d67['anchor'][_0x1a48e5(0x197)]===this[_0x1a48e5(0x186)]['shapeId'];});}async[_0x3415c7(0x19f)](){const _0x2e6433=_0x3415c7;let _0x2fee79=_0x1d07e7(this[_0x2e6433(0x186)][_0x2e6433(0x18e)]);return(await this[_0x2e6433(0x190)]()[_0x2e6433(0x19f)]({'unitIds':[this[_0x2e6433(0x186)][_0x2e6433(0x1b6)]],'subUnitIds':[this[_0x2e6433(0x186)][_0x2e6433(0x199)]],'anchorKinds':[_0x2fee79]}))[_0x2e6433(0x1a7)](_0x3aa5c3=>{const _0x4d750f=_0x2e6433;var _0x223c67;return((_0x223c67=_0x3aa5c3[_0x4d750f(0x187)])==null?void 0x0:_0x223c67['kind'])===_0x2fee79&&_0x4d750f(0x197)in _0x3aa5c3[_0x4d750f(0x187)]&&_0x3aa5c3[_0x4d750f(0x187)][_0x4d750f(0x197)]===this[_0x4d750f(0x186)][_0x4d750f(0x1b3)];});}};_0x37c0eb[_0x3415c7(0x1af)][_0x3415c7(0x19c)](_0x2acc77),_0x1d48fc['FShapeThreadCommentMixin']=_0x2acc77;}));function _0x29c4(_0x45b8f5,_0x1ad970){_0x45b8f5=_0x45b8f5-0x184;const _0x951f39=_0x951f();let _0x29c4b2=_0x951f39[_0x45b8f5];return _0x29c4b2;}function _0x951f(){const _0x194846=['UNIVER_SHEET','UniverProEngineShapeFacade','UNIVER_SLIDE','SLIDE_ELEMENT','call','hostType','set','_getThreadCommentService','2607960VSMdzE','7qBrEmO','getOwnPropertyNames','UniverThreadComment','amd','@univerjs-pro/engine-shape/facade','elementId','7332dRjHUL','subUnitId','enumerable','@univerjs/thread-comment','extend','ThreadCommentAnchorKind','createCommentAsync','listCommentsAsync','object','prototype','UniverProShapeThreadCommentFacade','defineProperty','bind','UNIVER_DOC','function','filter','433939USWCZg','exports','UniverInstanceType','530xNcYtx','Unsupported\x20Shape\x20host\x20type:\x20','hasOwnProperty','424nAfvoA','FShape','default','_injector','kind','shapeId','DOC_DRAWING','get','unitId','1083465sxjVFK','193383rGdeRA','340HHnifw','getComments','Module','6293844qqXfgb','SHEET_DRAWING','5249200VDCJSq','UNIVER_BOARD','_shapeRef','anchor','create'];_0x951f=function(){return _0x194846;};return _0x951f();}
|
package/lib/umd/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function
|
|
1
|
+
function _0x54ce(_0x579bd0,_0x517cbc){_0x579bd0=_0x579bd0-0x79;var _0x9335f6=_0x9335();var _0x54ce84=_0x9335f6[_0x579bd0];return _0x54ce84;}function _0x9335(){var _0xfe3d45=['UniverProShapeThreadComment','pluginName','1429488CfwzNW','UniverInstanceType','UniverProLicense','length','4RAjvUL','function','getThreadCommentService','listFloatingElementCommentsAsync','string','1.5.0','2006670RAulab','ThreadCommentFacadeService','UniverShapeThreadCommentPlugin','iterator','toStringTag','7190117bHBAyi','@univerjs-pro/license','_configService','defineProperty','1LQFYOt','9nmQwkP','getFloatingElementComments','648638nzqFmV','elementId','type','merge','UniverThreadCommentPlugin','symbol','_config','518798dnYhCr','unitId','subUnitId','decorate','UniverCore','filter','amd','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','shape-thread-comment.config','SHAPE_THREAD_COMMENT_PLUGIN_CONFIG_KEY','call','setConfig','kind','anchor','8PDaUJq','object','UniverLicensePlugin','createFloatingElementCommentAsync','listCommentsAsync','1500315miIlze','Module','get','@univerjs/core','Plugin','_injector','packageName','@univerjs-pro/shape-thread-comment','IConfigService','constructor','exports','390717RJJmjZ','getComments'];_0x9335=function(){return _0xfe3d45;};return _0x9335();}(function(_0x84eb6e,_0xc93ab1){var _0x143a74=_0x54ce,_0x1dc148=_0x84eb6e();while(!![]){try{var _0x560afa=parseInt(_0x143a74(0xaa))/0x1*(parseInt(_0x143a74(0xad))/0x2)+-parseInt(_0x143a74(0x93))/0x3*(-parseInt(_0x143a74(0x9b))/0x4)+-parseInt(_0x143a74(0x88))/0x5+-parseInt(_0x143a74(0x97))/0x6+-parseInt(_0x143a74(0xb4))/0x7*(parseInt(_0x143a74(0x83))/0x8)+parseInt(_0x143a74(0xab))/0x9*(-parseInt(_0x143a74(0xa1))/0xa)+parseInt(_0x143a74(0xa6))/0xb;if(_0x560afa===_0xc93ab1)break;else _0x1dc148['push'](_0x1dc148['shift']());}catch(_0x2eda04){_0x1dc148['push'](_0x1dc148['shift']());}}}(_0x9335,0x480c9),function(_0x41a7e0,_0x3280e0){var _0x125606=_0x54ce;typeof exports=='object'&&typeof module<'u'?_0x3280e0(exports,require('@univerjs/thread-comment'),require('@univerjs-pro/license'),require('@univerjs/core')):typeof define=='function'&&define[_0x125606(0x7b)]?define([_0x125606(0x92),'@univerjs/thread-comment',_0x125606(0xa7),_0x125606(0x8b)],_0x3280e0):(_0x41a7e0=typeof globalThis<'u'?globalThis:_0x41a7e0||self,_0x3280e0(_0x41a7e0[_0x125606(0x95)]={},_0x41a7e0['UniverThreadComment'],_0x41a7e0[_0x125606(0x99)],_0x41a7e0[_0x125606(0x79)]));}(this,function(_0x370646,_0x26f7a3,_0x4b41e0,_0x5816c1){var _0x3a6ecf=_0x54ce;Object[_0x3a6ecf(0xa9)](_0x370646,Symbol[_0x3a6ecf(0xa5)],{'value':_0x3a6ecf(0x89)});let _0x371094=_0x3a6ecf(0x7d),_0x4723a5={};function _0x407da9(_0x22a721){var _0x22806e=_0x3a6ecf;return _0x22a721[_0x22806e(0x8a)](_0x26f7a3[_0x22806e(0xa2)]);}function _0x416e98(_0x40ae07,_0x29febc,_0x5244a4,_0x31d1d9){var _0xe93919=_0x3a6ecf;return _0x40ae07['createCommentAsync']({..._0x31d1d9,'unitId':_0x29febc[_0xe93919(0xb5)],'subUnitId':_0x29febc['subUnitId'],'anchor':{'kind':_0x29febc[_0xe93919(0x81)],'pageId':_0x29febc['subUnitId'],'elementId':_0x29febc['elementId']},'content':_0x5244a4});}function _0x27c831(_0x2fd9c6,_0x11f428){var _0x176c74=_0x3a6ecf;return _0x2fd9c6[_0x176c74(0x94)]({'unitIds':[_0x11f428[_0x176c74(0xb5)]],'subUnitIds':[_0x11f428[_0x176c74(0xb6)]],'anchorKinds':[_0x11f428[_0x176c74(0x81)]]})[_0x176c74(0x7a)](_0x3285c7=>{var _0x1fa23f=_0x176c74,_0x204aef;return((_0x204aef=_0x3285c7[_0x1fa23f(0x82)])==null?void 0x0:_0x204aef[_0x1fa23f(0x81)])===_0x11f428[_0x1fa23f(0x81)]&&_0x1fa23f(0xae)in _0x3285c7[_0x1fa23f(0x82)]&&_0x3285c7['anchor'][_0x1fa23f(0xae)]===_0x11f428['elementId'];});}async function _0x337102(_0x11c31a,_0x3d1da8){var _0x51b06c=_0x3a6ecf;return(await _0x11c31a[_0x51b06c(0x87)]({'unitIds':[_0x3d1da8[_0x51b06c(0xb5)]],'subUnitIds':[_0x3d1da8[_0x51b06c(0xb6)]],'anchorKinds':[_0x3d1da8[_0x51b06c(0x81)]]}))[_0x51b06c(0x7a)](_0x1b7a29=>{var _0x2b971f=_0x51b06c,_0x18e5a1;return((_0x18e5a1=_0x1b7a29[_0x2b971f(0x82)])==null?void 0x0:_0x18e5a1[_0x2b971f(0x81)])===_0x3d1da8[_0x2b971f(0x81)]&&_0x2b971f(0xae)in _0x1b7a29[_0x2b971f(0x82)]&&_0x1b7a29[_0x2b971f(0x82)][_0x2b971f(0xae)]===_0x3d1da8[_0x2b971f(0xae)];});}var _0x5db38f=_0x3a6ecf(0x8f),_0x1c231b=_0x3a6ecf(0xa0);function _0x515f99(_0x3150c6,_0x1bf9b8){return function(_0x2999aa,_0x316f90){_0x1bf9b8(_0x2999aa,_0x316f90,_0x3150c6);};}function _0xfe1c46(_0x458597,_0x1990e2,_0x1da8b7,_0x2683a4){var _0x9b4790=_0x3a6ecf,_0x5a1fe0=arguments[_0x9b4790(0x9a)],_0x46e5c5=_0x5a1fe0<0x3?_0x1990e2:_0x2683a4===null?_0x2683a4=Object['getOwnPropertyDescriptor'](_0x1990e2,_0x1da8b7):_0x2683a4,_0x34ed5c;if(typeof Reflect==_0x9b4790(0x84)&&typeof Reflect[_0x9b4790(0xb7)]=='function')_0x46e5c5=Reflect[_0x9b4790(0xb7)](_0x458597,_0x1990e2,_0x1da8b7,_0x2683a4);else{for(var _0x25eb88=_0x458597[_0x9b4790(0x9a)]-0x1;_0x25eb88>=0x0;_0x25eb88--)(_0x34ed5c=_0x458597[_0x25eb88])&&(_0x46e5c5=(_0x5a1fe0<0x3?_0x34ed5c(_0x46e5c5):_0x5a1fe0>0x3?_0x34ed5c(_0x1990e2,_0x1da8b7,_0x46e5c5):_0x34ed5c(_0x1990e2,_0x1da8b7))||_0x46e5c5);}return _0x5a1fe0>0x3&&_0x46e5c5&&Object[_0x9b4790(0xa9)](_0x1990e2,_0x1da8b7,_0x46e5c5),_0x46e5c5;}function _0x18ae37(_0x14b0e7){'@babel/helpers - typeof';var _0x52d12c=_0x3a6ecf;return _0x18ae37=typeof Symbol==_0x52d12c(0x9c)&&typeof Symbol[_0x52d12c(0xa4)]==_0x52d12c(0xb2)?function(_0x4c531a){return typeof _0x4c531a;}:function(_0x3a3f1c){var _0x1e7264=_0x52d12c;return _0x3a3f1c&&typeof Symbol==_0x1e7264(0x9c)&&_0x3a3f1c[_0x1e7264(0x91)]===Symbol&&_0x3a3f1c!==Symbol['prototype']?'symbol':typeof _0x3a3f1c;},_0x18ae37(_0x14b0e7);}function _0x58e6e9(_0x5c6769,_0x20ee94){var _0x26aba5=_0x3a6ecf;if(_0x18ae37(_0x5c6769)!='object'||!_0x5c6769)return _0x5c6769;var _0x4e90b6;if(typeof Symbol<'u'&&(_0x4e90b6=_0x5c6769[Symbol['toPrimitive']])!==void 0x0){var _0x36ae83=_0x4e90b6[_0x26aba5(0x7f)](_0x5c6769,_0x20ee94||'default');if(_0x18ae37(_0x36ae83)!=_0x26aba5(0x84))return _0x36ae83;throw TypeError(_0x26aba5(0x7c));}return(_0x20ee94==='string'?String:Number)(_0x5c6769);}function _0x314aaf(_0x58d4f4){var _0x2c5dd3=_0x3a6ecf,_0x445cc5=_0x58e6e9(_0x58d4f4,_0x2c5dd3(0x9f));return _0x18ae37(_0x445cc5)==_0x2c5dd3(0xb2)?_0x445cc5:_0x445cc5+'';}function _0x3a04fa(_0x266e98,_0x5131ca,_0x4daf5a){return(_0x5131ca=_0x314aaf(_0x5131ca))in _0x266e98?Object['defineProperty'](_0x266e98,_0x5131ca,{'value':_0x4daf5a,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x266e98[_0x5131ca]=_0x4daf5a,_0x266e98;}let _0x19c389=class extends _0x5816c1[_0x3a6ecf(0x8c)]{constructor(_0x21c5ce=_0x4723a5,_0x5d5b02,_0x5112dc){var _0x40e423=_0x3a6ecf;super(),this['_config']=_0x21c5ce,this[_0x40e423(0x8d)]=_0x5d5b02,this[_0x40e423(0xa8)]=_0x5112dc;let {..._0xadafec}=(0x0,_0x5816c1[_0x40e423(0xb0)])({},_0x4723a5,this[_0x40e423(0xb3)]);this[_0x40e423(0xa8)][_0x40e423(0x80)](_0x371094,_0xadafec);}};_0x3a04fa(_0x19c389,_0x3a6ecf(0x96),'UNIVER_SHAPE_THREAD_COMMENT_PLUGIN'),_0x3a04fa(_0x19c389,_0x3a6ecf(0x8e),_0x5db38f),_0x3a04fa(_0x19c389,'version',_0x1c231b),_0x3a04fa(_0x19c389,_0x3a6ecf(0xaf),_0x5816c1[_0x3a6ecf(0x98)]['UNIVER_UNKNOWN']),_0x19c389=_0xfe1c46([(0x0,_0x5816c1['DependentOn'])(_0x4b41e0[_0x3a6ecf(0x85)],_0x26f7a3[_0x3a6ecf(0xb1)]),_0x515f99(0x1,(0x0,_0x5816c1['Inject'])(_0x5816c1['Injector'])),_0x515f99(0x2,_0x5816c1[_0x3a6ecf(0x90)])],_0x19c389),_0x370646[_0x3a6ecf(0x7e)]=_0x371094,Object[_0x3a6ecf(0xa9)](_0x370646,_0x3a6ecf(0xa3),{'enumerable':!0x0,'get':function(){return _0x19c389;}}),_0x370646[_0x3a6ecf(0x86)]=_0x416e98,_0x370646[_0x3a6ecf(0xac)]=_0x27c831,_0x370646[_0x3a6ecf(0x9d)]=_0x407da9,_0x370646[_0x3a6ecf(0x9e)]=_0x337102;}));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@univerjs-pro/shape-thread-comment",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Thread comment integration for Univer Shapes.",
|
|
6
6
|
"author": "DreamNum Co., Ltd. <developer@univer.ai>",
|
|
@@ -41,25 +41,21 @@
|
|
|
41
41
|
"lib"
|
|
42
42
|
],
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@univerjs-pro/
|
|
45
|
-
"@univerjs-pro/
|
|
46
|
-
"@univerjs
|
|
47
|
-
"@univerjs
|
|
48
|
-
"@univerjs/core": "1.3.1",
|
|
49
|
-
"@univerjs/docs-drawing": "1.3.1",
|
|
50
|
-
"@univerjs/sheets-drawing": "1.3.1",
|
|
51
|
-
"@univerjs/thread-comment": "1.3.1"
|
|
44
|
+
"@univerjs-pro/engine-shape": "1.5.0",
|
|
45
|
+
"@univerjs-pro/license": "1.5.0",
|
|
46
|
+
"@univerjs/core": "1.5.0",
|
|
47
|
+
"@univerjs/thread-comment": "1.5.0"
|
|
52
48
|
},
|
|
53
49
|
"devDependencies": {
|
|
54
|
-
"@univerjs-infra/shared": "1.
|
|
55
|
-
"
|
|
56
|
-
"vitest": "^5.0
|
|
50
|
+
"@univerjs-infra/shared": "1.5.0",
|
|
51
|
+
"tsrs": "0.23.0-ts7.1.0-beta",
|
|
52
|
+
"vitest": "^5.1.0"
|
|
57
53
|
},
|
|
58
54
|
"scripts": {
|
|
59
55
|
"test": "vitest run",
|
|
60
|
-
"typecheck": "
|
|
56
|
+
"typecheck": "tsrs --noEmit",
|
|
61
57
|
"build:bundle": "univer-cli build",
|
|
62
|
-
"build:types": "
|
|
58
|
+
"build:types": "tsrs -p tsconfig.node.json",
|
|
63
59
|
"build": "pnpm run build:bundle && pnpm run build:types"
|
|
64
60
|
},
|
|
65
61
|
"module": "./lib/es/index.js"
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { Injector } from '@univerjs/core';
|
|
2
|
-
import * as ThreadComment from '@univerjs/thread-comment';
|
|
3
|
-
type ThreadCommentService = Pick<ThreadComment.ThreadCommentFacadeService, 'createCommentAsync' | 'getComments' | 'listCommentsAsync'>;
|
|
4
|
-
export declare function getThreadCommentService(injector: Injector): ThreadComment.ThreadCommentFacadeService;
|
|
5
|
-
export type IFloatingElementCommentCreateOptions = Omit<ThreadComment.ICreateThreadCommentOptions, 'unitId' | 'subUnitId' | 'anchor' | 'content'>;
|
|
6
|
-
export interface IFloatingElementCommentTarget {
|
|
7
|
-
unitId: string;
|
|
8
|
-
subUnitId: string;
|
|
9
|
-
elementId: string;
|
|
10
|
-
kind: ThreadComment.IThreadCommentElementAnchor['kind'];
|
|
11
|
-
}
|
|
12
|
-
export declare function createFloatingElementCommentAsync(service: ThreadCommentService, target: IFloatingElementCommentTarget, content: ThreadComment.ThreadCommentContent, options: IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
13
|
-
export declare function getFloatingElementComments(service: ThreadCommentService, target: IFloatingElementCommentTarget): ThreadComment.IFacadeThreadCommentInfo[];
|
|
14
|
-
export declare function listFloatingElementCommentsAsync(service: ThreadCommentService, target: IFloatingElementCommentTarget): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
15
|
-
export {};
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { FDocumentChart } from '@univerjs-pro/docs-chart/facade';
|
|
2
|
-
import * as ThreadComment from '@univerjs/thread-comment';
|
|
3
|
-
import * as ElementComment from './element-comment';
|
|
4
|
-
export interface IFDocumentChartThreadCommentMixin {
|
|
5
|
-
/**
|
|
6
|
-
* Creates a comment anchored to this document chart.
|
|
7
|
-
* @param content Plain text or a Univer document body for rich comment content.
|
|
8
|
-
* @param options Optional stable IDs, author, attachments, and creation time.
|
|
9
|
-
* @returns `true` when the create command succeeds; otherwise, `false`.
|
|
10
|
-
* @throws {TypeError} If the content is empty.
|
|
11
|
-
* @example
|
|
12
|
-
* ```ts
|
|
13
|
-
* const chart = univerAPI.getActiveDocument()?.getCharts()[0];
|
|
14
|
-
* await chart?.createCommentAsync('Verify the chart source.');
|
|
15
|
-
* ```
|
|
16
|
-
*/
|
|
17
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
18
|
-
/**
|
|
19
|
-
* Returns locally loaded comments anchored to this chart's drawing ID.
|
|
20
|
-
* @returns Matching comment threads in the current document.
|
|
21
|
-
* @example
|
|
22
|
-
* ```ts
|
|
23
|
-
* const chart = univerAPI.getActiveDocument()?.getCharts()[0];
|
|
24
|
-
* console.log(chart?.getComments().length ?? 0);
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
28
|
-
/**
|
|
29
|
-
* Synchronizes known threads and returns comments anchored to this chart's drawing ID.
|
|
30
|
-
* @returns A promise resolving to matching synchronized comment threads.
|
|
31
|
-
* @example
|
|
32
|
-
* ```ts
|
|
33
|
-
* const chart = univerAPI.getActiveDocument()?.getCharts()[0];
|
|
34
|
-
* const comments = chart ? await chart.listCommentsAsync() : [];
|
|
35
|
-
* console.log(comments.length);
|
|
36
|
-
* ```
|
|
37
|
-
*/
|
|
38
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
39
|
-
}
|
|
40
|
-
export declare class FDocumentChartThreadCommentMixin extends FDocumentChart implements IFDocumentChartThreadCommentMixin {
|
|
41
|
-
/** @inheritdoc */
|
|
42
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
43
|
-
/** @inheritdoc */
|
|
44
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
45
|
-
/** @inheritdoc */
|
|
46
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
47
|
-
private _commentTarget;
|
|
48
|
-
}
|
|
49
|
-
declare module '@univerjs-pro/docs-chart/facade' {
|
|
50
|
-
interface FDocumentChart extends IFDocumentChartThreadCommentMixin {
|
|
51
|
-
}
|
|
52
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { FDocumentImage } from '@univerjs/docs-drawing/facade';
|
|
2
|
-
import * as ThreadComment from '@univerjs/thread-comment';
|
|
3
|
-
import * as ElementComment from './element-comment';
|
|
4
|
-
export interface IFDocumentImageThreadCommentMixin {
|
|
5
|
-
/**
|
|
6
|
-
* Creates a comment anchored to this document image.
|
|
7
|
-
* @param content Plain text or a Univer document body for rich comment content.
|
|
8
|
-
* @param options Optional stable IDs, author, attachments, and creation time.
|
|
9
|
-
* @returns `true` when the create command succeeds; otherwise, `false`.
|
|
10
|
-
* @throws {TypeError} If the content is empty.
|
|
11
|
-
* @example
|
|
12
|
-
* ```ts
|
|
13
|
-
* const image = univerAPI.getActiveDocument()?.getImages()[0];
|
|
14
|
-
* await image?.createCommentAsync('Add alternative text.');
|
|
15
|
-
* ```
|
|
16
|
-
*/
|
|
17
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
18
|
-
/**
|
|
19
|
-
* Returns locally loaded comments anchored to this image's drawing ID.
|
|
20
|
-
* @returns Matching comment threads in the current document.
|
|
21
|
-
* @example
|
|
22
|
-
* ```ts
|
|
23
|
-
* const image = univerAPI.getActiveDocument()?.getImages()[0];
|
|
24
|
-
* console.log(image?.getComments().length ?? 0);
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
28
|
-
/**
|
|
29
|
-
* Synchronizes known threads and returns comments anchored to this image's drawing ID.
|
|
30
|
-
* @returns A promise resolving to matching synchronized comment threads.
|
|
31
|
-
* @example
|
|
32
|
-
* ```ts
|
|
33
|
-
* const image = univerAPI.getActiveDocument()?.getImages()[0];
|
|
34
|
-
* const comments = image ? await image.listCommentsAsync() : [];
|
|
35
|
-
* console.log(comments.length);
|
|
36
|
-
* ```
|
|
37
|
-
*/
|
|
38
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
39
|
-
}
|
|
40
|
-
export declare class FDocumentImageThreadCommentMixin extends FDocumentImage implements IFDocumentImageThreadCommentMixin {
|
|
41
|
-
/** @inheritdoc */
|
|
42
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
43
|
-
/** @inheritdoc */
|
|
44
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
45
|
-
/** @inheritdoc */
|
|
46
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
47
|
-
private _commentTarget;
|
|
48
|
-
}
|
|
49
|
-
declare module '@univerjs/docs-drawing/facade' {
|
|
50
|
-
interface FDocumentImage extends IFDocumentImageThreadCommentMixin {
|
|
51
|
-
}
|
|
52
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { FSheetChart } from '@univerjs-pro/sheets-chart/facade';
|
|
2
|
-
import * as ThreadComment from '@univerjs/thread-comment';
|
|
3
|
-
import * as ElementComment from './element-comment';
|
|
4
|
-
export interface IFSheetChartThreadCommentMixin {
|
|
5
|
-
/**
|
|
6
|
-
* Creates a comment anchored to this Sheet chart.
|
|
7
|
-
* @param content Plain text or a Univer document body for rich comment content.
|
|
8
|
-
* @param options Optional stable IDs, author, attachments, and creation time.
|
|
9
|
-
* @returns `true` when the create command succeeds; otherwise, `false`.
|
|
10
|
-
* @throws {TypeError} If the content is empty.
|
|
11
|
-
* @example
|
|
12
|
-
* ```ts
|
|
13
|
-
* const chart = univerAPI.getActiveWorkbook()?.getActiveSheet()?.getCharts()[0];
|
|
14
|
-
* await chart?.createCommentAsync('Verify the source range.');
|
|
15
|
-
* ```
|
|
16
|
-
*/
|
|
17
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
18
|
-
/**
|
|
19
|
-
* Returns locally loaded comments anchored to this chart's stable ID.
|
|
20
|
-
* @returns Matching comment threads in the current worksheet.
|
|
21
|
-
* @example
|
|
22
|
-
* ```ts
|
|
23
|
-
* const chart = univerAPI.getActiveWorkbook()?.getActiveSheet()?.getCharts()[0];
|
|
24
|
-
* console.log(chart?.getComments().length ?? 0);
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
28
|
-
/**
|
|
29
|
-
* Synchronizes known threads and returns comments anchored to this chart's stable ID.
|
|
30
|
-
* @returns A promise resolving to matching synchronized comment threads.
|
|
31
|
-
* @example
|
|
32
|
-
* ```ts
|
|
33
|
-
* const chart = univerAPI.getActiveWorkbook()?.getActiveSheet()?.getCharts()[0];
|
|
34
|
-
* const comments = chart ? await chart.listCommentsAsync() : [];
|
|
35
|
-
* console.log(comments.length);
|
|
36
|
-
* ```
|
|
37
|
-
*/
|
|
38
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
39
|
-
}
|
|
40
|
-
export declare class FSheetChartThreadCommentMixin extends FSheetChart implements IFSheetChartThreadCommentMixin {
|
|
41
|
-
/** @inheritdoc */
|
|
42
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
43
|
-
/** @inheritdoc */
|
|
44
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
45
|
-
/** @inheritdoc */
|
|
46
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
47
|
-
private _commentTarget;
|
|
48
|
-
}
|
|
49
|
-
declare module '@univerjs-pro/sheets-chart/facade' {
|
|
50
|
-
interface FSheetChart extends IFSheetChartThreadCommentMixin {
|
|
51
|
-
}
|
|
52
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { FOverGridImage } from '@univerjs/sheets-drawing/facade';
|
|
2
|
-
import * as ThreadComment from '@univerjs/thread-comment';
|
|
3
|
-
import * as ElementComment from './element-comment';
|
|
4
|
-
export interface IFSheetImageThreadCommentMixin {
|
|
5
|
-
/**
|
|
6
|
-
* Creates a comment anchored to this over-grid image.
|
|
7
|
-
* @param content Plain text or a Univer document body for rich comment content.
|
|
8
|
-
* @param options Optional stable IDs, author, attachments, and creation time.
|
|
9
|
-
* @returns `true` when the create command succeeds; otherwise, `false`.
|
|
10
|
-
* @throws {TypeError} If the content is empty.
|
|
11
|
-
* @example
|
|
12
|
-
* ```ts
|
|
13
|
-
* const image = univerAPI.getActiveWorkbook()?.getActiveSheet()?.getImages()[0];
|
|
14
|
-
* await image?.createCommentAsync('Replace this image.');
|
|
15
|
-
* ```
|
|
16
|
-
*/
|
|
17
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
18
|
-
/**
|
|
19
|
-
* Returns locally loaded comments anchored to this image's drawing ID.
|
|
20
|
-
* @returns Matching comment threads in the current worksheet.
|
|
21
|
-
* @example
|
|
22
|
-
* ```ts
|
|
23
|
-
* const image = univerAPI.getActiveWorkbook()?.getActiveSheet()?.getImages()[0];
|
|
24
|
-
* console.log(image?.getComments().length ?? 0);
|
|
25
|
-
* ```
|
|
26
|
-
*/
|
|
27
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
28
|
-
/**
|
|
29
|
-
* Synchronizes known threads and returns comments anchored to this image's drawing ID.
|
|
30
|
-
* @returns A promise resolving to matching synchronized comment threads.
|
|
31
|
-
* @example
|
|
32
|
-
* ```ts
|
|
33
|
-
* const image = univerAPI.getActiveWorkbook()?.getActiveSheet()?.getImages()[0];
|
|
34
|
-
* const comments = image ? await image.listCommentsAsync() : [];
|
|
35
|
-
* console.log(comments.length);
|
|
36
|
-
* ```
|
|
37
|
-
*/
|
|
38
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
39
|
-
}
|
|
40
|
-
export declare class FSheetImageThreadCommentMixin extends FOverGridImage implements IFSheetImageThreadCommentMixin {
|
|
41
|
-
/** @inheritdoc */
|
|
42
|
-
createCommentAsync(content: ThreadComment.ThreadCommentContent, options?: ElementComment.IFloatingElementCommentCreateOptions): Promise<boolean>;
|
|
43
|
-
/** @inheritdoc */
|
|
44
|
-
getComments(): ThreadComment.IFacadeThreadCommentInfo[];
|
|
45
|
-
/** @inheritdoc */
|
|
46
|
-
listCommentsAsync(): Promise<ThreadComment.IFacadeThreadCommentInfo[]>;
|
|
47
|
-
private _commentTarget;
|
|
48
|
-
}
|
|
49
|
-
declare module '@univerjs/sheets-drawing/facade' {
|
|
50
|
-
interface FOverGridImage extends IFSheetImageThreadCommentMixin {
|
|
51
|
-
}
|
|
52
|
-
}
|