@univerjs-pro/docs-formula 1.5.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/facade.js +1 -1
- package/lib/cjs/index.js +1 -1
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/facade.js +1 -1
- package/lib/index.js +1 -1
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- package/package.json +8 -8
package/lib/cjs/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x14b8(_0x3328b4,_0x11e9b7){_0x3328b4=_0x3328b4-0x151;const _0x2336ee=_0x2336();let _0x14b850=_0x2336ee[_0x3328b4];return _0x14b850;}const _0x22fd62=_0x14b8;(function(_0x1092cf,_0x54249b){const _0x748e90=_0x14b8,_0x4d5b86=_0x1092cf();while(!![]){try{const _0x291588=-parseInt(_0x748e90(0x1a5))/0x1*(parseInt(_0x748e90(0x158))/0x2)+-parseInt(_0x748e90(0x17d))/0x3+parseInt(_0x748e90(0x181))/0x4+-parseInt(_0x748e90(0x166))/0x5*(parseInt(_0x748e90(0x19f))/0x6)+-parseInt(_0x748e90(0x19e))/0x7*(parseInt(_0x748e90(0x160))/0x8)+parseInt(_0x748e90(0x196))/0x9+parseInt(_0x748e90(0x1b5))/0xa*(parseInt(_0x748e90(0x184))/0xb);if(_0x291588===_0x54249b)break;else _0x4d5b86['push'](_0x4d5b86['shift']());}catch(_0x502c4d){_0x4d5b86['push'](_0x4d5b86['shift']());}}}(_0x2336,0xdd60c),Object[_0x22fd62(0x182)](exports,Symbol[_0x22fd62(0x1a2)],{'value':'Module'}));let e=require('@univerjs-pro/docs-formula'),t=require('@univerjs/core'),n=require('@univerjs/docs/facade');function r(_0x463c85,_0x20b0b9){return function(_0x440cd3,_0x2873ba){_0x20b0b9(_0x440cd3,_0x2873ba,_0x463c85);};}function i(_0x2ec2ca,_0xeafc66,_0xd5317c,_0x1f5b45){const _0x1ab65d=_0x22fd62;var _0x4aa187=arguments[_0x1ab65d(0x17b)],_0x550d87=_0x4aa187<0x3?_0xeafc66:_0x1f5b45===null?_0x1f5b45=Object[_0x1ab65d(0x19c)](_0xeafc66,_0xd5317c):_0x1f5b45,_0x36fb12;if(typeof Reflect==_0x1ab65d(0x1ab)&&typeof Reflect[_0x1ab65d(0x17c)]==_0x1ab65d(0x157))_0x550d87=Reflect[_0x1ab65d(0x17c)](_0x2ec2ca,_0xeafc66,_0xd5317c,_0x1f5b45);else{for(var _0x206832=_0x2ec2ca[_0x1ab65d(0x17b)]-0x1;_0x206832>=0x0;_0x206832--)(_0x36fb12=_0x2ec2ca[_0x206832])&&(_0x550d87=(_0x4aa187<0x3?_0x36fb12(_0x550d87):_0x4aa187>0x3?_0x36fb12(_0xeafc66,_0xd5317c,_0x550d87):_0x36fb12(_0xeafc66,_0xd5317c))||_0x550d87);}return _0x4aa187>0x3&&_0x550d87&&Object['defineProperty'](_0xeafc66,_0xd5317c,_0x550d87),_0x550d87;}let a=class{constructor(_0x42e61d,_0x491ed8,_0x25bdf5,_0x4235cb,_0x71665c,_0xec8242){const _0x37cec4=_0x22fd62;this[_0x37cec4(0x19a)]=_0x42e61d,this[_0x37cec4(0x156)]=_0x491ed8,this['_commandService']=_0x25bdf5,this[_0x37cec4(0x179)]=_0x4235cb,this[_0x37cec4(0x168)]=_0x71665c,this['_univerInstanceService']=_0xec8242;}['getId'](){const _0x2ad7af=_0x22fd62;return this[_0x2ad7af(0x156)];}['getRange'](){const _0xa317dd=_0x22fd62;let _0x2add90=this[_0xa317dd(0x19b)]();return _0x2add90?{'endOffset':_0x2add90[_0xa317dd(0x1b1)]+0x1,'rangeId':_0x2add90[_0xa317dd(0x15c)],'startOffset':_0x2add90[_0xa317dd(0x177)]}:null;}[_0x22fd62(0x15d)](){const _0x51e1cb=_0x22fd62;var _0x3f3b46;return((_0x3f3b46=this[_0x51e1cb(0x179)]['getFormula'](this[_0x51e1cb(0x19a)],this[_0x51e1cb(0x156)]))==null?void 0x0:_0x3f3b46[_0x51e1cb(0x1ac)])??'';}[_0x22fd62(0x178)](){const _0x3ec22c=_0x22fd62;return this[_0x3ec22c(0x179)][_0x3ec22c(0x15d)](this[_0x3ec22c(0x19a)],this[_0x3ec22c(0x156)])??null;}['getResult'](){const _0x57ab24=_0x22fd62;return this['_service'][_0x57ab24(0x1aa)]({'unitId':this[_0x57ab24(0x19a)],'rangeId':this['_rangeId']})??null;}[_0x22fd62(0x18f)](){const _0x3d9380=_0x22fd62;let _0x16032f=this['getRange'](),_0x36fbc6=this[_0x3d9380(0x178)](),_0x28eee0=this[_0x3d9380(0x1aa)]();return!_0x16032f||!_0x36fbc6||!_0x28eee0?null:{..._0x16032f,'config':_0x36fbc6,'formula':_0x36fbc6['formula'],'result':_0x28eee0,'type':_0x3d9380(0x1ac)};}['update'](_0x313e8c){const _0x392623=_0x22fd62;return this['_commandService'][_0x392623(0x16b)](e[_0x392623(0x165)]['id'],{'externalReferences':_0x313e8c['externalReferences'],'formula':_0x313e8c[_0x392623(0x1ac)],'numberFormat':_0x313e8c[_0x392623(0x176)],'rangeId':this[_0x392623(0x156)],'unitId':this[_0x392623(0x19a)]});}[_0x22fd62(0x16d)](_0x1cb7d2){const _0x206bf8=_0x22fd62;return this[_0x206bf8(0x1b6)][_0x206bf8(0x16b)](e[_0x206bf8(0x18d)]['id'],{'numberFormat':_0x1cb7d2,'rangeId':this[_0x206bf8(0x156)],'unitId':this[_0x206bf8(0x19a)]});}[_0x22fd62(0x18b)](){const _0x452c1f=_0x22fd62;return this[_0x452c1f(0x1b6)]['syncExecuteCommand'](e[_0x452c1f(0x18a)]['id'],{'rangeId':this[_0x452c1f(0x156)],'unitId':this[_0x452c1f(0x19a)]});}[_0x22fd62(0x152)](_0x592482){const _0x4e82c1=_0x22fd62;return this[_0x4e82c1(0x1b6)][_0x4e82c1(0x16b)](e[_0x4e82c1(0x194)]['id'],{'rangeId':this['_rangeId'],'text':_0x592482,'unitId':this['_unitId']});}[_0x22fd62(0x1a3)](){const _0x2fae31=_0x22fd62;return this['_commandService']['syncExecuteCommand'](e[_0x2fae31(0x192)]['id'],{'rangeId':this[_0x2fae31(0x156)],'unitId':this[_0x2fae31(0x19a)]});}['_getCustomRange'](){const _0x5ea964=_0x22fd62;var _0x2d7c70;let _0x117abc=this[_0x5ea964(0x185)][_0x5ea964(0x1ae)](this[_0x5ea964(0x19a)],t[_0x5ea964(0x175)][_0x5ea964(0x1b7)]);return _0x117abc==null||(_0x2d7c70=_0x117abc['getSnapshot']()[_0x5ea964(0x16f)])==null||(_0x2d7c70=_0x2d7c70['customRanges'])==null?void 0x0:_0x2d7c70[_0x5ea964(0x1ad)](_0x1ad2f1=>_0x1ad2f1['rangeId']===this[_0x5ea964(0x156)]&&(0x0,e[_0x5ea964(0x1a9)])(_0x1ad2f1));}};a=i([r(0x2,t[_0x22fd62(0x1b4)]),r(0x3,(0x0,t[_0x22fd62(0x154)])(e['DocFormulaModel'])),r(0x4,(0x0,t[_0x22fd62(0x154)])(e[_0x22fd62(0x18e)])),r(0x5,t[_0x22fd62(0x1a1)])],a);function o(_0x507b86){'@babel/helpers - typeof';const _0x32e9bb=_0x22fd62;return o=typeof Symbol==_0x32e9bb(0x157)&&typeof Symbol[_0x32e9bb(0x1a0)]==_0x32e9bb(0x16e)?function(_0x3d82d9){return typeof _0x3d82d9;}:function(_0xb2c22f){const _0x427646=_0x32e9bb;return _0xb2c22f&&typeof Symbol==_0x427646(0x157)&&_0xb2c22f['constructor']===Symbol&&_0xb2c22f!==Symbol[_0x427646(0x172)]?'symbol':typeof _0xb2c22f;},o(_0x507b86);}function s(_0x3ca885,_0x2c9b3d){const _0xdc8060=_0x22fd62;if(o(_0x3ca885)!=_0xdc8060(0x1ab)||!_0x3ca885)return _0x3ca885;var _0x332663;if(typeof Symbol<'u'&&(_0x332663=_0x3ca885[Symbol[_0xdc8060(0x1b0)]])!==void 0x0){var _0x558849=_0x332663[_0xdc8060(0x188)](_0x3ca885,_0x2c9b3d||_0xdc8060(0x170));if(o(_0x558849)!=_0xdc8060(0x1ab))return _0x558849;throw TypeError(_0xdc8060(0x18c));}return(_0x2c9b3d===_0xdc8060(0x193)?String:Number)(_0x3ca885);}function c(_0x48a575){const _0x53e85b=_0x22fd62;var _0x279b10=s(_0x48a575,_0x53e85b(0x193));return o(_0x279b10)==_0x53e85b(0x16e)?_0x279b10:_0x279b10+'';}function l(_0x5259fb,_0x857ebe,_0x1dbe2c){const _0x40b63b=_0x22fd62;return(_0x857ebe=c(_0x857ebe))in _0x5259fb?Object[_0x40b63b(0x182)](_0x5259fb,_0x857ebe,{'value':_0x1dbe2c,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x5259fb[_0x857ebe]=_0x1dbe2c,_0x5259fb;}var u=class extends n[_0x22fd62(0x191)]{constructor(..._0x395399){const _0x5ddb69=_0x22fd62;super(..._0x395399),l(this,'_docsFormulaCommandService',void 0x0),l(this,'_docsFormulaDisplayTextService',void 0x0),l(this,_0x5ddb69(0x199),void 0x0),l(this,_0x5ddb69(0x171),void 0x0);}[_0x22fd62(0x15b)](_0x3d64af){const _0x8d2f31=_0x22fd62;this[_0x8d2f31(0x174)]=_0x3d64af[_0x8d2f31(0x17a)](t[_0x8d2f31(0x1b4)]),this[_0x8d2f31(0x159)]=_0x3d64af[_0x8d2f31(0x17a)](e[_0x8d2f31(0x198)]),this['_docsFormulaModel']=_0x3d64af[_0x8d2f31(0x17a)](e['DocFormulaModel']),this[_0x8d2f31(0x171)]=_0x3d64af[_0x8d2f31(0x17a)](t['IResourceLoaderService']);}[_0x22fd62(0x1a6)](){const _0x1cc794=_0x22fd62;return this[_0x1cc794(0x1af)]()[_0x1cc794(0x15f)](_0x5c57cd=>this[_0x1cc794(0x186)](_0x5c57cd[_0x1cc794(0x15c)]));}[_0x22fd62(0x15d)](_0x17065a){const _0x3678fa=_0x22fd62;return this[_0x3678fa(0x1af)]()[_0x3678fa(0x15a)](_0x37571c=>_0x37571c[_0x3678fa(0x15c)]===_0x17065a)?this['_createFormula'](_0x17065a):null;}[_0x22fd62(0x17f)](_0x35251f){const _0x2881ad=_0x22fd62;let _0x5832b3=this[_0x2881ad(0x1af)]()[_0x2881ad(0x1ad)](_0xbf9abb=>_0xbf9abb[_0x2881ad(0x177)]<=_0x35251f&&_0x35251f<=_0xbf9abb['endIndex']);return _0x5832b3?this['_createFormula'](_0x5832b3[_0x2881ad(0x15c)]):null;}['saveFormulaDisplayTextSnapshot'](){const _0x217f14=_0x22fd62;let _0x4ee98a=this[_0x217f14(0x171)][_0x217f14(0x15e)](this['id']);if(!_0x4ee98a)throw Error(_0x217f14(0x169)+this['id']+_0x217f14(0x161));return this[_0x217f14(0x159)][_0x217f14(0x167)](_0x4ee98a);}[_0x22fd62(0x180)](_0x30816b){const _0x475f3c=_0x22fd62;return this[_0x475f3c(0x1b2)]({'externalReferences':_0x30816b[_0x475f3c(0x189)],'formula':_0x30816b[_0x475f3c(0x1ac)],'numberFormat':_0x30816b[_0x475f3c(0x176)],'target':{'type':_0x475f3c(0x1b3),'startOffset':_0x30816b[_0x475f3c(0x1a8)],'endOffset':_0x30816b[_0x475f3c(0x19d)]},'unitId':this[_0x475f3c(0x151)]()});}['_insert'](_0x3293a7){const _0x51e09f=_0x22fd62;let _0x4d4ca8=this[_0x51e09f(0x174)]['syncExecuteCommand'](e[_0x51e09f(0x164)]['id'],_0x3293a7);return _0x4d4ca8?this[_0x51e09f(0x186)](_0x4d4ca8[_0x51e09f(0x15c)]):null;}[_0x22fd62(0x1af)](){const _0x2410de=_0x22fd62;var _0x4a6586;let _0x40f312=this['_docsFormulaModel'][_0x2410de(0x1a6)](this['getId']());return((_0x4a6586=this['getBody']('')[_0x2410de(0x16c)])==null?void 0x0:_0x4a6586[_0x2410de(0x1a4)](_0x453a24=>(0x0,e[_0x2410de(0x1a9)])(_0x453a24)&&_0x40f312[_0x453a24[_0x2410de(0x15c)]]!=null))??[];}[_0x22fd62(0x186)](_0x2be7ba){const _0x231ddf=_0x22fd62;return this[_0x231ddf(0x190)][_0x231ddf(0x183)](a,this[_0x231ddf(0x151)](),_0x2be7ba);}};n[_0x22fd62(0x191)][_0x22fd62(0x162)](u);var d=class extends n[_0x22fd62(0x17e)]{constructor(..._0x358441){const _0x1c6e6d=_0x22fd62;super(..._0x358441),l(this,_0x1c6e6d(0x174),void 0x0);}[_0x22fd62(0x15b)](_0x165a6c){const _0x56ff04=_0x22fd62;this[_0x56ff04(0x174)]=_0x165a6c[_0x56ff04(0x17a)](t['ICommandService']);}[_0x22fd62(0x180)](_0x47531d,_0xe6c6fb,_0x3775ef={}){const _0x16297a=_0x22fd62;return this[_0x16297a(0x1b2)](_0x47531d,_0xe6c6fb,_0x3775ef);}[_0x22fd62(0x16a)](_0x471fa1,_0x461870={}){const _0x1c03c8=_0x22fd62;return this['_insert'](_0x1c03c8(0x1a7),_0x471fa1,_0x461870);}[_0x22fd62(0x1b2)](_0x26d9ce,_0x4e5c1d,_0x3f7083){const _0x1dc14f=_0x22fd62;if(this[_0x1dc14f(0x173)]())return null;let _0x38fa3a={'externalReferences':_0x3f7083[_0x1dc14f(0x189)],'formula':_0x4e5c1d,'numberFormat':_0x3f7083['numberFormat'],'target':{'type':_0x1dc14f(0x197),'paragraphId':this[_0x1dc14f(0x151)](),'position':_0x26d9ce},'unitId':this[_0x1dc14f(0x195)]['getId']()},_0x2af173=this[_0x1dc14f(0x174)][_0x1dc14f(0x16b)](e['InsertDocFormulaCommand']['id'],_0x38fa3a);return _0x2af173?this['_injector'][_0x1dc14f(0x183)](a,this['_document'][_0x1dc14f(0x151)](),_0x2af173['rangeId']):null;}};n[_0x22fd62(0x17e)][_0x22fd62(0x162)](d);var f=class extends n[_0x22fd62(0x187)]{constructor(..._0x525506){const _0x301352=_0x22fd62;super(..._0x525506),l(this,_0x301352(0x174),void 0x0);}[_0x22fd62(0x15b)](_0x5df22f){const _0x241c31=_0x22fd62;this[_0x241c31(0x174)]=_0x5df22f['get'](t[_0x241c31(0x1b4)]);}[_0x22fd62(0x163)](_0x56336d,_0x2b140b={}){const _0x5c9fa7=_0x22fd62;let {endOffset:_0x2eeb7e,segmentId:_0x5b07c9,startOffset:_0x4df627}=this[_0x5c9fa7(0x153)]();return _0x5b07c9?null:this[_0x5c9fa7(0x1b2)](_0x4df627,_0x2eeb7e,_0x56336d,_0x2b140b);}[_0x22fd62(0x1b2)](_0x14846e,_0x30b1a8,_0x2acd6a,_0x42ea99){const _0x5b766e=_0x22fd62;let _0x4a9c31={'externalReferences':_0x42ea99['externalReferences'],'formula':_0x2acd6a,'numberFormat':_0x42ea99[_0x5b766e(0x176)],'target':{'type':_0x5b766e(0x1b3),'startOffset':_0x14846e,'endOffset':_0x30b1a8},'unitId':this[_0x5b766e(0x195)][_0x5b766e(0x151)]()},_0x467106=this[_0x5b766e(0x174)][_0x5b766e(0x16b)](e[_0x5b766e(0x164)]['id'],_0x4a9c31);return _0x467106?this['_injector'][_0x5b766e(0x183)](a,this[_0x5b766e(0x195)][_0x5b766e(0x151)](),_0x467106[_0x5b766e(0x15c)]):null;}};function _0x2336(){const _0x212138=['syncExecuteCommand','customRanges','setNumberFormat','symbol','body','default','_docsFormulaResourceLoaderService','prototype','getSegmentId','_docsFormulaCommandService','UniverInstanceType','numberFormat','startIndex','getConfig','_model','get','length','decorate','2969121vDFaSE','FDocumentParagraph','getFormulaAt','insertFormula','7247692sNXjVt','defineProperty','createInstance','1793qRHNIQ','_univerInstanceService','_createFormula','FDocumentTextRange','call','externalReferences','RemoveDocFormulaCommand','remove','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','SetDocFormulaNumberFormatCommand','DocFormulaService','describe','_injector','FDocument','ConvertDocFormulaToTextCommand','string','ReplaceDocFormulaWithTextCommand','_document','1708614KRYEeu','paragraph','DocFormulaDisplayTextService','_docsFormulaModel','_unitId','_getCustomRange','getOwnPropertyDescriptor','endOffset','7wrHKxu','6VZSNAc','iterator','IUniverInstanceService','toStringTag','convertToText','filter','2735FUOxxq','getFormulas','end','startOffset','isDocFormulaRange','getResult','object','formula','find','getUnit','_getCompleteRanges','toPrimitive','endIndex','_insert','range','ICommandService','88430uQLBet','_commandService','UNIVER_DOC','getId','replaceWithText','getRange','Inject','FDocumentFormula','_rangeId','function','4JQXROo','_docsFormulaDisplayTextService','some','_initialize','rangeId','getFormula','saveUnit','map','2676480XKoGYf','\x20could\x20not\x20be\x20serialized.','extend','replaceWithFormula','InsertDocFormulaCommand','UpdateDocFormulaCommand','6033385LTVUBA','degradeDocumentData','_service','Document\x20','appendFormula'];_0x2336=function(){return _0x212138;};return _0x2336();}n[_0x22fd62(0x187)][_0x22fd62(0x162)](f),Object['defineProperty'](exports,_0x22fd62(0x155),{'enumerable':!0x0,'get':function(){return a;}});
|
|
1
|
+
const _0x1a02cb=_0x1ba6;(function(_0x2ee12c,_0xfb0cca){const _0xd8d411=_0x1ba6,_0x54184c=_0x2ee12c();while(!![]){try{const _0x3c16c9=parseInt(_0xd8d411(0x1f4))/0x1+parseInt(_0xd8d411(0x1f9))/0x2*(parseInt(_0xd8d411(0x204))/0x3)+parseInt(_0xd8d411(0x212))/0x4+parseInt(_0xd8d411(0x221))/0x5*(-parseInt(_0xd8d411(0x236))/0x6)+parseInt(_0xd8d411(0x1fb))/0x7+-parseInt(_0xd8d411(0x213))/0x8+-parseInt(_0xd8d411(0x1f3))/0x9*(parseInt(_0xd8d411(0x1fd))/0xa);if(_0x3c16c9===_0xfb0cca)break;else _0x54184c['push'](_0x54184c['shift']());}catch(_0x172b75){_0x54184c['push'](_0x54184c['shift']());}}}(_0x5132,0x9c622),Object[_0x1a02cb(0x1ec)](exports,Symbol[_0x1a02cb(0x22b)],{'value':_0x1a02cb(0x241)}));let e=require('@univerjs-pro/docs-formula'),t=require('@univerjs/core'),n=require('@univerjs/docs/facade');function r(_0x2384c3,_0x2c4df2){return function(_0x2eb2ab,_0x239d8c){_0x2c4df2(_0x2eb2ab,_0x239d8c,_0x2384c3);};}function i(_0x4f18ec,_0x1c7f20,_0x10d039,_0x1da1dc){const _0x188c2d=_0x1a02cb;var _0x1fc610=arguments[_0x188c2d(0x1f2)],_0x182e7e=_0x1fc610<0x3?_0x1c7f20:_0x1da1dc===null?_0x1da1dc=Object[_0x188c2d(0x21b)](_0x1c7f20,_0x10d039):_0x1da1dc,_0x287fa3;if(typeof Reflect=='object'&&typeof Reflect[_0x188c2d(0x1f8)]==_0x188c2d(0x247))_0x182e7e=Reflect[_0x188c2d(0x1f8)](_0x4f18ec,_0x1c7f20,_0x10d039,_0x1da1dc);else{for(var _0x7ab561=_0x4f18ec['length']-0x1;_0x7ab561>=0x0;_0x7ab561--)(_0x287fa3=_0x4f18ec[_0x7ab561])&&(_0x182e7e=(_0x1fc610<0x3?_0x287fa3(_0x182e7e):_0x1fc610>0x3?_0x287fa3(_0x1c7f20,_0x10d039,_0x182e7e):_0x287fa3(_0x1c7f20,_0x10d039))||_0x182e7e);}return _0x1fc610>0x3&&_0x182e7e&&Object[_0x188c2d(0x1ec)](_0x1c7f20,_0x10d039,_0x182e7e),_0x182e7e;}let a=class{constructor(_0x5d3138,_0x696f4c,_0x589554,_0x511285,_0x4ad7ff,_0x55a03f){const _0x1e8441=_0x1a02cb;this[_0x1e8441(0x249)]=_0x5d3138,this[_0x1e8441(0x217)]=_0x696f4c,this[_0x1e8441(0x208)]=_0x589554,this[_0x1e8441(0x240)]=_0x511285,this[_0x1e8441(0x1f7)]=_0x4ad7ff,this[_0x1e8441(0x22f)]=_0x55a03f;}['getId'](){const _0x3488cd=_0x1a02cb;return this[_0x3488cd(0x217)];}[_0x1a02cb(0x1eb)](){const _0x1f9ea1=_0x1a02cb;let _0x2bf973=this[_0x1f9ea1(0x21d)]();return _0x2bf973?{'endOffset':_0x2bf973['endIndex']+0x1,'rangeId':_0x2bf973[_0x1f9ea1(0x201)],'startOffset':_0x2bf973[_0x1f9ea1(0x21a)]}:null;}[_0x1a02cb(0x23e)](){const _0x758694=_0x1a02cb;var _0x20641c;return((_0x20641c=this[_0x758694(0x240)][_0x758694(0x23e)](this[_0x758694(0x249)],this['_rangeId']))==null?void 0x0:_0x20641c['formula'])??'';}[_0x1a02cb(0x21e)](){const _0x58106f=_0x1a02cb;return this[_0x58106f(0x240)][_0x58106f(0x23e)](this['_unitId'],this[_0x58106f(0x217)])??null;}[_0x1a02cb(0x21c)](){const _0x4dfceb=_0x1a02cb;return this[_0x4dfceb(0x1f7)][_0x4dfceb(0x21c)]({'unitId':this[_0x4dfceb(0x249)],'rangeId':this[_0x4dfceb(0x217)]})??null;}[_0x1a02cb(0x1ea)](){const _0x24f4e4=_0x1a02cb;let _0x45a6cf=this[_0x24f4e4(0x1eb)](),_0x581996=this[_0x24f4e4(0x21e)](),_0xa3bd01=this[_0x24f4e4(0x21c)]();return!_0x45a6cf||!_0x581996||!_0xa3bd01?null:{..._0x45a6cf,'config':_0x581996,'formula':_0x581996['formula'],'result':_0xa3bd01,'type':_0x24f4e4(0x206)};}[_0x1a02cb(0x214)](_0x52b993){const _0x4bfc6a=_0x1a02cb;return this[_0x4bfc6a(0x208)][_0x4bfc6a(0x245)](e[_0x4bfc6a(0x1ed)]['id'],{'externalReferences':_0x52b993[_0x4bfc6a(0x224)],'formula':_0x52b993['formula'],'numberFormat':_0x52b993[_0x4bfc6a(0x1e9)],'rangeId':this[_0x4bfc6a(0x217)],'unitId':this[_0x4bfc6a(0x249)]});}[_0x1a02cb(0x1e5)](_0x20f692){const _0x54ce5d=_0x1a02cb;return this[_0x54ce5d(0x208)]['syncExecuteCommand'](e[_0x54ce5d(0x223)]['id'],{'numberFormat':_0x20f692,'rangeId':this[_0x54ce5d(0x217)],'unitId':this[_0x54ce5d(0x249)]});}[_0x1a02cb(0x230)](){const _0x3d746a=_0x1a02cb;return this[_0x3d746a(0x208)]['syncExecuteCommand'](e[_0x3d746a(0x242)]['id'],{'rangeId':this[_0x3d746a(0x217)],'unitId':this['_unitId']});}[_0x1a02cb(0x231)](_0x2a3929){const _0x1969f9=_0x1a02cb;return this['_commandService']['syncExecuteCommand'](e[_0x1969f9(0x24b)]['id'],{'rangeId':this['_rangeId'],'text':_0x2a3929,'unitId':this[_0x1969f9(0x249)]});}[_0x1a02cb(0x23a)](){const _0x62a61a=_0x1a02cb;return this[_0x62a61a(0x208)][_0x62a61a(0x245)](e[_0x62a61a(0x202)]['id'],{'rangeId':this[_0x62a61a(0x217)],'unitId':this[_0x62a61a(0x249)]});}[_0x1a02cb(0x21d)](){const _0x2ad560=_0x1a02cb;var _0x106921;let _0x1d0d2a=this[_0x2ad560(0x22f)][_0x2ad560(0x205)](this[_0x2ad560(0x249)],t[_0x2ad560(0x1ee)][_0x2ad560(0x219)]);return _0x1d0d2a==null||(_0x106921=_0x1d0d2a[_0x2ad560(0x243)]()[_0x2ad560(0x234)])==null||(_0x106921=_0x106921[_0x2ad560(0x20a)])==null?void 0x0:_0x106921['find'](_0x3c58c0=>_0x3c58c0[_0x2ad560(0x201)]===this[_0x2ad560(0x217)]&&(0x0,e[_0x2ad560(0x20e)])(_0x3c58c0));}};a=i([r(0x2,t[_0x1a02cb(0x1fa)]),r(0x3,(0x0,t[_0x1a02cb(0x203)])(e[_0x1a02cb(0x1ef)])),r(0x4,(0x0,t[_0x1a02cb(0x203)])(e[_0x1a02cb(0x200)])),r(0x5,t[_0x1a02cb(0x216)])],a);function o(_0x21e8a2){'@babel/helpers - typeof';const _0xb27ea7=_0x1a02cb;return o=typeof Symbol==_0xb27ea7(0x247)&&typeof Symbol[_0xb27ea7(0x1e6)]=='symbol'?function(_0x465ab1){return typeof _0x465ab1;}:function(_0x4b03c1){const _0x2812f9=_0xb27ea7;return _0x4b03c1&&typeof Symbol=='function'&&_0x4b03c1[_0x2812f9(0x20b)]===Symbol&&_0x4b03c1!==Symbol[_0x2812f9(0x1e8)]?'symbol':typeof _0x4b03c1;},o(_0x21e8a2);}function s(_0x22d281,_0x36b43e){const _0x365a34=_0x1a02cb;if(o(_0x22d281)!=_0x365a34(0x225)||!_0x22d281)return _0x22d281;var _0x57f754;if(typeof Symbol<'u'&&(_0x57f754=_0x22d281[Symbol[_0x365a34(0x209)]])!==void 0x0){var _0x3cb851=_0x57f754[_0x365a34(0x232)](_0x22d281,_0x36b43e||_0x365a34(0x222));if(o(_0x3cb851)!=_0x365a34(0x225))return _0x3cb851;throw TypeError(_0x365a34(0x1f1));}return(_0x36b43e===_0x365a34(0x233)?String:Number)(_0x22d281);}function c(_0xba3f6){const _0x307c64=_0x1a02cb;var _0x40f93d=s(_0xba3f6,_0x307c64(0x233));return o(_0x40f93d)=='symbol'?_0x40f93d:_0x40f93d+'';}function l(_0x21e0b0,_0x828249,_0x48827a){const _0x51ee2e=_0x1a02cb;return(_0x828249=c(_0x828249))in _0x21e0b0?Object[_0x51ee2e(0x1ec)](_0x21e0b0,_0x828249,{'value':_0x48827a,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x21e0b0[_0x828249]=_0x48827a,_0x21e0b0;}var u=class extends n['FDocument']{constructor(..._0x53ba3b){const _0x1cfabc=_0x1a02cb;super(..._0x53ba3b),l(this,_0x1cfabc(0x22a),void 0x0),l(this,'_docsFormulaDisplayTextService',void 0x0),l(this,_0x1cfabc(0x218),void 0x0),l(this,_0x1cfabc(0x246),void 0x0);}['_initialize'](_0x1a8104){const _0x576190=_0x1a02cb;this[_0x576190(0x22a)]=_0x1a8104[_0x576190(0x1fc)](t[_0x576190(0x1fa)]),this['_docsFormulaDisplayTextService']=_0x1a8104[_0x576190(0x1fc)](e[_0x576190(0x20c)]),this[_0x576190(0x218)]=_0x1a8104[_0x576190(0x1fc)](e[_0x576190(0x1ef)]),this[_0x576190(0x246)]=_0x1a8104[_0x576190(0x1fc)](t[_0x576190(0x24a)]);}[_0x1a02cb(0x1e7)](){const _0x2c4c20=_0x1a02cb;return this[_0x2c4c20(0x1ff)]()[_0x2c4c20(0x1f5)](_0x5bf35d=>this[_0x2c4c20(0x23c)](_0x5bf35d[_0x2c4c20(0x201)]));}['getFormula'](_0x355f4f){const _0x4aff87=_0x1a02cb;return this[_0x4aff87(0x1ff)]()[_0x4aff87(0x244)](_0x56ecc8=>_0x56ecc8[_0x4aff87(0x201)]===_0x355f4f)?this[_0x4aff87(0x23c)](_0x355f4f):null;}[_0x1a02cb(0x226)](_0x59accc){const _0x2533da=_0x1a02cb;let _0x4d8b7b=this[_0x2533da(0x1ff)]()[_0x2533da(0x21f)](_0x5c73f8=>_0x5c73f8[_0x2533da(0x21a)]<=_0x59accc&&_0x59accc<=_0x5c73f8[_0x2533da(0x227)]);return _0x4d8b7b?this[_0x2533da(0x23c)](_0x4d8b7b['rangeId']):null;}[_0x1a02cb(0x238)](){const _0x3d8378=_0x1a02cb;let _0x15e774=this['_docsFormulaResourceLoaderService']['saveUnit'](this['id']);if(!_0x15e774)throw Error(_0x3d8378(0x22c)+this['id']+_0x3d8378(0x239));return this['_docsFormulaDisplayTextService'][_0x3d8378(0x22d)](_0x15e774);}[_0x1a02cb(0x235)](_0x3ab6fd){const _0xc05bfd=_0x1a02cb;return this[_0xc05bfd(0x23b)]({'externalReferences':_0x3ab6fd[_0xc05bfd(0x224)],'formula':_0x3ab6fd['formula'],'numberFormat':_0x3ab6fd[_0xc05bfd(0x1e9)],'target':{'type':'range','startOffset':_0x3ab6fd[_0xc05bfd(0x20d)],'endOffset':_0x3ab6fd[_0xc05bfd(0x23f)]},'unitId':this[_0xc05bfd(0x248)]()});}[_0x1a02cb(0x23b)](_0x42d5dc){const _0x1a652a=_0x1a02cb;let _0x3e57bf=this[_0x1a652a(0x22a)][_0x1a652a(0x245)](e[_0x1a652a(0x22e)]['id'],_0x42d5dc);return _0x3e57bf?this[_0x1a652a(0x23c)](_0x3e57bf[_0x1a652a(0x201)]):null;}[_0x1a02cb(0x1ff)](){const _0x38005f=_0x1a02cb;var _0x266209;let _0x51e568=this[_0x38005f(0x218)][_0x38005f(0x1e7)](this[_0x38005f(0x248)]());return((_0x266209=this[_0x38005f(0x210)]('')[_0x38005f(0x20a)])==null?void 0x0:_0x266209[_0x38005f(0x215)](_0x4d8c5a=>(0x0,e[_0x38005f(0x20e)])(_0x4d8c5a)&&_0x51e568[_0x4d8c5a[_0x38005f(0x201)]]!=null))??[];}['_createFormula'](_0x38fa05){const _0x214868=_0x1a02cb;return this['_injector'][_0x214868(0x207)](a,this[_0x214868(0x248)](),_0x38fa05);}};n[_0x1a02cb(0x1f0)]['extend'](u);function _0x5132(){const _0x4826d4=['DocFormulaModel','FDocument','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','length','7461ujueey','1111568PrDUIy','map','end','_service','decorate','239354ZEzwpA','ICommandService','1511251XPULCB','get','5020MuGaLi','FDocumentTextRange','_getCompleteRanges','DocFormulaService','rangeId','ConvertDocFormulaToTextCommand','Inject','21eXzrwB','getUnit','formula','createInstance','_commandService','toPrimitive','customRanges','constructor','DocFormulaDisplayTextService','startOffset','isDocFormulaRange','_initialize','getBody','_injector','859284TlkEJz','839696SmUhwr','update','filter','IUniverInstanceService','_rangeId','_docsFormulaModel','UNIVER_DOC','startIndex','getOwnPropertyDescriptor','getResult','_getCustomRange','getConfig','find','paragraph','5jiMunx','default','SetDocFormulaNumberFormatCommand','externalReferences','object','getFormulaAt','endIndex','FDocumentFormula','_document','_docsFormulaCommandService','toStringTag','Document\x20','degradeDocumentData','InsertDocFormulaCommand','_univerInstanceService','remove','replaceWithText','call','string','body','insertFormula','7310130wbDtwH','FDocumentParagraph','saveFormulaDisplayTextSnapshot','\x20could\x20not\x20be\x20serialized.','convertToText','_insert','_createFormula','extend','getFormula','endOffset','_model','Module','RemoveDocFormulaCommand','getSnapshot','some','syncExecuteCommand','_docsFormulaResourceLoaderService','function','getId','_unitId','IResourceLoaderService','ReplaceDocFormulaWithTextCommand','replaceWithFormula','setNumberFormat','iterator','getFormulas','prototype','numberFormat','describe','getRange','defineProperty','UpdateDocFormulaCommand','UniverInstanceType'];_0x5132=function(){return _0x4826d4;};return _0x5132();}function _0x1ba6(_0x2fa8ec,_0x21be57){_0x2fa8ec=_0x2fa8ec-0x1e5;const _0x51327b=_0x5132();let _0x1ba6bc=_0x51327b[_0x2fa8ec];return _0x1ba6bc;}var d=class extends n[_0x1a02cb(0x237)]{constructor(..._0x37ab21){const _0x19e228=_0x1a02cb;super(..._0x37ab21),l(this,_0x19e228(0x22a),void 0x0);}['_initialize'](_0x20e183){const _0x1731cd=_0x1a02cb;this[_0x1731cd(0x22a)]=_0x20e183[_0x1731cd(0x1fc)](t['ICommandService']);}[_0x1a02cb(0x235)](_0x2d5973,_0x37c599,_0x2973ac={}){const _0x30f104=_0x1a02cb;return this[_0x30f104(0x23b)](_0x2d5973,_0x37c599,_0x2973ac);}['appendFormula'](_0x39aaf0,_0x149203={}){const _0x296133=_0x1a02cb;return this[_0x296133(0x23b)](_0x296133(0x1f6),_0x39aaf0,_0x149203);}['_insert'](_0x281c7f,_0x4cd9ed,_0xfebf27){const _0x5473c2=_0x1a02cb;if(this['getSegmentId']())return null;let _0x2b74fe={'externalReferences':_0xfebf27[_0x5473c2(0x224)],'formula':_0x4cd9ed,'numberFormat':_0xfebf27['numberFormat'],'target':{'type':_0x5473c2(0x220),'paragraphId':this[_0x5473c2(0x248)](),'position':_0x281c7f},'unitId':this[_0x5473c2(0x229)][_0x5473c2(0x248)]()},_0x5d6fac=this[_0x5473c2(0x22a)][_0x5473c2(0x245)](e[_0x5473c2(0x22e)]['id'],_0x2b74fe);return _0x5d6fac?this[_0x5473c2(0x211)][_0x5473c2(0x207)](a,this[_0x5473c2(0x229)]['getId'](),_0x5d6fac[_0x5473c2(0x201)]):null;}};n[_0x1a02cb(0x237)]['extend'](d);var f=class extends n[_0x1a02cb(0x1fe)]{constructor(..._0x2b7965){super(..._0x2b7965),l(this,'_docsFormulaCommandService',void 0x0);}[_0x1a02cb(0x20f)](_0x1c20ae){const _0x3f6379=_0x1a02cb;this[_0x3f6379(0x22a)]=_0x1c20ae[_0x3f6379(0x1fc)](t[_0x3f6379(0x1fa)]);}[_0x1a02cb(0x24c)](_0x25ef5b,_0x2fa72e={}){const _0x583c9c=_0x1a02cb;let {endOffset:_0x58d576,segmentId:_0x5a3c0a,startOffset:_0x185380}=this[_0x583c9c(0x1eb)]();return _0x5a3c0a?null:this[_0x583c9c(0x23b)](_0x185380,_0x58d576,_0x25ef5b,_0x2fa72e);}[_0x1a02cb(0x23b)](_0x5402af,_0x5dd817,_0x1c8f7,_0x38bf14){const _0x5dc2e8=_0x1a02cb;let _0x16ff5a={'externalReferences':_0x38bf14[_0x5dc2e8(0x224)],'formula':_0x1c8f7,'numberFormat':_0x38bf14[_0x5dc2e8(0x1e9)],'target':{'type':'range','startOffset':_0x5402af,'endOffset':_0x5dd817},'unitId':this[_0x5dc2e8(0x229)][_0x5dc2e8(0x248)]()},_0x57c209=this['_docsFormulaCommandService'][_0x5dc2e8(0x245)](e[_0x5dc2e8(0x22e)]['id'],_0x16ff5a);return _0x57c209?this['_injector'][_0x5dc2e8(0x207)](a,this[_0x5dc2e8(0x229)][_0x5dc2e8(0x248)](),_0x57c209[_0x5dc2e8(0x201)]):null;}};n[_0x1a02cb(0x1fe)][_0x1a02cb(0x23d)](f),Object[_0x1a02cb(0x1ec)](exports,_0x1a02cb(0x228),{'enumerable':!0x0,'get':function(){return a;}});
|
package/lib/cjs/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x4b9f04=_0x3404;(function(_0x4d9a0b,_0x2174bc){const _0x91f1=_0x3404,_0x17b5b8=_0x4d9a0b();while(!![]){try{const _0x37f929=parseInt(_0x91f1(0x18b))/0x1+-parseInt(_0x91f1(0x23e))/0x2*(-parseInt(_0x91f1(0x22b))/0x3)+-parseInt(_0x91f1(0x234))/0x4*(parseInt(_0x91f1(0x21b))/0x5)+parseInt(_0x91f1(0x21c))/0x6*(-parseInt(_0x91f1(0x17f))/0x7)+parseInt(_0x91f1(0x219))/0x8+parseInt(_0x91f1(0x205))/0x9+parseInt(_0x91f1(0x150))/0xa*(-parseInt(_0x91f1(0x183))/0xb);if(_0x37f929===_0x2174bc)break;else _0x17b5b8['push'](_0x17b5b8['shift']());}catch(_0x5dcd89){_0x17b5b8['push'](_0x17b5b8['shift']());}}}(_0x17d4,0x2f299),Object[_0x4b9f04(0x1a1)](exports,Symbol[_0x4b9f04(0x149)],{'value':'Module'}));let e=require('@univerjs-pro/engine-formula'),t=require('@univerjs/core'),n=require('@univerjs/docs'),r=require('@univerjs/engine-formula'),i=require('rxjs'),a=require('@univerjs-pro/license');const o=_0x4b9f04(0x1f5),s='univer-docs-formula';function c(){return{'formulas':{}};}function l(_0x258f57){const _0x53afc1=_0x4b9f04;return!_0x258f57||typeof _0x258f57!=_0x53afc1(0x1ff)||!(_0x53afc1(0x15c)in _0x258f57)||!_0x258f57['formulas']||typeof _0x258f57[_0x53afc1(0x15c)]!=_0x53afc1(0x1ff)||Array[_0x53afc1(0x14c)](_0x258f57['formulas'])?!0x1:Object[_0x53afc1(0x194)](_0x258f57[_0x53afc1(0x15c)])[_0x53afc1(0x1f7)](([_0x5d727b,_0x6f8c1e])=>_0x5d727b[_0x53afc1(0x16a)]>0x0&&u(_0x6f8c1e));}function u(_0x47377d){const _0xe04e07=_0x4b9f04;return!_0x47377d||typeof _0x47377d!=_0xe04e07(0x1ff)||!f(_0x47377d,['formula',_0xe04e07(0x240),_0xe04e07(0x209)])||!('formula'in _0x47377d)||typeof _0x47377d[_0xe04e07(0x1bd)]!=_0xe04e07(0x1c9)||!_0x47377d[_0xe04e07(0x1bd)][_0xe04e07(0x1b8)]()||_0xe04e07(0x240)in _0x47377d&&_0x47377d[_0xe04e07(0x240)]!=null&&(typeof _0x47377d['numberFormat']!=_0xe04e07(0x1ff)||!f(_0x47377d['numberFormat'],[_0xe04e07(0x1a0)])||!('pattern'in _0x47377d[_0xe04e07(0x240)])||typeof _0x47377d[_0xe04e07(0x240)][_0xe04e07(0x1a0)]!=_0xe04e07(0x1c9))?!0x1:!('lastValue'in _0x47377d)||_0x47377d[_0xe04e07(0x209)]==null||d(_0x47377d[_0xe04e07(0x209)]);}function d(_0x2f0a1f){const _0x17570b=_0x4b9f04;return!_0x2f0a1f||typeof _0x2f0a1f!=_0x17570b(0x1ff)||!f(_0x2f0a1f,['v','t','pattern'])||!('v'in _0x2f0a1f)||_0x2f0a1f['v']!==null&&typeof _0x2f0a1f['v']!=_0x17570b(0x1c9)&&typeof _0x2f0a1f['v']!='number'&&typeof _0x2f0a1f['v']!=_0x17570b(0x1ce)||'t'in _0x2f0a1f&&_0x2f0a1f['t']!=null&&!ee(_0x2f0a1f['t'])?!0x1:!(_0x17570b(0x1a0)in _0x2f0a1f)||_0x2f0a1f[_0x17570b(0x1a0)]==null||typeof _0x2f0a1f[_0x17570b(0x1a0)]==_0x17570b(0x1c9);}function f(_0x1cf300,_0x2b00f4){const _0xffc28a=_0x4b9f04;let _0x45bea4=new Set(_0x2b00f4);return Object['keys'](_0x1cf300)[_0xffc28a(0x1f7)](_0x35771b=>_0x45bea4['has'](_0x35771b));}function ee(_0x4814e3){const _0x1fd78b=_0x4b9f04;return typeof _0x4814e3=='number'&&Object[_0x1fd78b(0x231)](t[_0x1fd78b(0x1d3)])[_0x1fd78b(0x220)](_0x4814e3);}const p=new Set([t[_0x4b9f04(0x191)][_0x4b9f04(0x1d4)],t[_0x4b9f04(0x191)][_0x4b9f04(0x1ea)],t['DataStreamTreeTokenType'][_0x4b9f04(0x18f)],t[_0x4b9f04(0x191)][_0x4b9f04(0x1f3)],t['DataStreamTreeTokenType'][_0x4b9f04(0x1ae)],t[_0x4b9f04(0x191)][_0x4b9f04(0x202)],t[_0x4b9f04(0x191)][_0x4b9f04(0x178)],t[_0x4b9f04(0x191)][_0x4b9f04(0x159)],t[_0x4b9f04(0x191)][_0x4b9f04(0x1fa)],t[_0x4b9f04(0x191)][_0x4b9f04(0x16d)],t[_0x4b9f04(0x191)]['COLUMN_GROUP_END'],t[_0x4b9f04(0x191)][_0x4b9f04(0x14f)],t[_0x4b9f04(0x191)][_0x4b9f04(0x1c1)],t[_0x4b9f04(0x191)]['CUSTOM_BLOCK']]);var m=class extends Error{constructor(){const _0x55322d=_0x4b9f04;super(_0x55322d(0x271));}};function te(_0x171c57){const _0x3d88e4=_0x4b9f04;var _0xda6145,_0xdc09cf;let _0x392fa5=t[_0x3d88e4(0x192)][_0x3d88e4(0x161)](_0x171c57['documentData']),_0x2bf7ee=T(_0x392fa5),{startOffset:_0x96cc88,endOffset:_0x5bc11b}=oe(_0x2bf7ee,_0x171c57[_0x3d88e4(0x1dd)],_0x171c57[_0x3d88e4(0x27b)]);ie(_0x2bf7ee,_0x96cc88,_0x5bc11b);let _0x531d6e=((_0xda6145=_0x2bf7ee[_0x3d88e4(0x18d)])==null?void 0x0:_0xda6145['filter'](_0x57daf1=>{const _0xd4676d=_0x3d88e4;if(!g(_0x57daf1))return!0x1;let _0x19a41b=(0x0,t[_0xd4676d(0x19f)])(_0x57daf1);return _0x19a41b[_0xd4676d(0x27b)]>_0x96cc88&&_0x19a41b[_0xd4676d(0x1dd)]<_0x5bc11b;})['map'](_0x32ed03=>_0x32ed03[_0x3d88e4(0x25f)]))??[];ce(_0x2bf7ee,_0x96cc88,_0x5bc11b,''),_0x2bf7ee[_0x3d88e4(0x18d)]=[...((_0xdc09cf=_0x2bf7ee['customRanges'])==null?void 0x0:_0xdc09cf[_0x3d88e4(0x1c3)](_0x586d2c=>!_0x531d6e[_0x3d88e4(0x220)](_0x586d2c['rangeId'])&&_0x586d2c[_0x3d88e4(0x25f)]!==_0x171c57[_0x3d88e4(0x25f)]))??[],ae(_0x171c57[_0x3d88e4(0x25f)],_0x96cc88)][_0x3d88e4(0x14b)]((_0x5459c5,_0x132c6c)=>_0x5459c5[_0x3d88e4(0x1be)]-_0x132c6c['startIndex']);let _0x28f17a=v(_0x171c57[_0x3d88e4(0x277)]);return _0x531d6e[_0x3d88e4(0x21f)](_0x1fd2a8=>{const _0x246f8c=_0x3d88e4;delete _0x28f17a[_0x246f8c(0x15c)][_0x1fd2a8];}),_0x28f17a[_0x3d88e4(0x15c)][_0x171c57[_0x3d88e4(0x25f)]]=t[_0x3d88e4(0x192)][_0x3d88e4(0x161)](_0x171c57[_0x3d88e4(0x26e)]),{'nextDocumentData':_0x392fa5,'nextResource':_0x28f17a,'cursorOffset':_0x96cc88+0x1};}function ne(_0x42a8ed){const _0xb8a94e=_0x4b9f04;var _0x3524f6,_0x55c0de;let _0x65544c=t[_0xb8a94e(0x192)][_0xb8a94e(0x161)](_0x42a8ed['documentData']),_0x1c086a=(_0x3524f6=T(_0x65544c)['customRanges'])==null?void 0x0:_0x3524f6[_0xb8a94e(0x227)](_0x5cad55=>_0x5cad55[_0xb8a94e(0x25f)]===_0x42a8ed[_0xb8a94e(0x25f)]&&g(_0x5cad55));if(!_0x1c086a||!((_0x55c0de=_0x42a8ed['resource'])!=null&&_0x55c0de[_0xb8a94e(0x15c)][_0x42a8ed['rangeId']]))return null;let _0x3d6687=v(_0x42a8ed['resource']);return _0x3d6687['formulas'][_0x42a8ed['rangeId']]=t['Tools'][_0xb8a94e(0x161)](_0x42a8ed['config']),{'nextDocumentData':_0x65544c,'nextResource':_0x3d6687,'cursorOffset':_0x1c086a[_0xb8a94e(0x181)]+0x1};}function h(_0x3f6fc8){const _0x4cb19f=_0x4b9f04;let _0x439751=t[_0x4cb19f(0x192)][_0x4cb19f(0x161)](_0x3f6fc8['documentData']),_0x92bcdb=le(_0x439751,_0x3f6fc8[_0x4cb19f(0x25f)],_0x3f6fc8[_0x4cb19f(0x186)]??'');if(_0x92bcdb==null)return null;let _0x9f2cd6=v(_0x3f6fc8[_0x4cb19f(0x277)]);return delete _0x9f2cd6[_0x4cb19f(0x15c)][_0x3f6fc8['rangeId']],{'nextDocumentData':_0x439751,'nextResource':_0x9f2cd6,'cursorOffset':_0x92bcdb};}function re(_0x1e8653,_0x14dba8){const _0x18dc64=_0x4b9f04;var _0x1f8c66;let _0x10a11b=t[_0x18dc64(0x192)][_0x18dc64(0x161)](_0x1e8653),_0x2a8147=_0x10a11b[_0x18dc64(0x182)];if(!_0x2a8147)return _0x10a11b;let _0x3e58d8=new Map(_0x14dba8['map'](_0x172e69=>[_0x172e69['rangeId'],_0x172e69['text']])),_0x5504ac=((_0x1f8c66=_0x2a8147['customRanges'])==null?void 0x0:_0x1f8c66['filter'](_0x295883=>g(_0x295883)&&_0x3e58d8[_0x18dc64(0x160)](_0x295883[_0x18dc64(0x25f)]))[_0x18dc64(0x14b)]((_0x1d03d9,_0x3926ad)=>_0x3926ad[_0x18dc64(0x1be)]-_0x1d03d9[_0x18dc64(0x1be)]))??[];for(let _0x4e26d4 of _0x5504ac)le(_0x10a11b,_0x4e26d4[_0x18dc64(0x25f)],_0x3e58d8['get'](_0x4e26d4[_0x18dc64(0x25f)])??'');return _0x10a11b;}function g(_0xa72537){const _0x3bac19=_0x4b9f04;var _0x3004a0;return(_0xa72537==null?void 0x0:_0xa72537[_0x3bac19(0x166)])===t[_0x3bac19(0x239)]['CUSTOM']&&_0xa72537[_0x3bac19(0x1bb)]===!0x0&&((_0x3004a0=_0xa72537[_0x3bac19(0x242)])==null?void 0x0:_0x3004a0[_0x3bac19(0x170)])===_0x3bac19(0x24c);}function _(_0x23fada,_0x350069){const _0x4b516b=_0x4b9f04;var _0x2aba4a;return _0x23fada==null||(_0x2aba4a=_0x23fada[_0x4b516b(0x18d)])==null?void 0x0:_0x2aba4a['find'](_0x1d5493=>_0x1d5493[_0x4b516b(0x25f)]===_0x350069&&g(_0x1d5493));}function ie(_0x1e4cd9,_0x3eaf67,_0x54196c){const _0x50f65e=_0x4b9f04;if(_0x3eaf67===_0x54196c){if(p['has'](_0x1e4cd9['dataStream'][_0x3eaf67]))throw new m();}else{for(let _0x3a3a93=_0x3eaf67;_0x3a3a93<_0x54196c;_0x3a3a93++)if(_0x1e4cd9[_0x50f65e(0x275)][_0x3a3a93]===t[_0x50f65e(0x191)][_0x50f65e(0x265)]||p['has'](_0x1e4cd9[_0x50f65e(0x275)][_0x3a3a93]))throw new m();}}function _0x17d4(){const _0x46e941=['toPrimitive','COMMAND','getFormulaValueSync','getCurrentUnitOfType','_loadErrors','_pendingUnitIds','TABLE_CELL_END','symbol','setResource','updates','getSnapshot','documentRedo','_registrations','cell','UniverInstanceType','_hostExternalReferenceModel','trim','getBodySliceForTextXAction','UNIVER_DOC','wholeEntity','_formulaKeys','formula','startIndex','error','_injector','BLOCK_END','DocTextResolverService','filter','position','sequenceNodesBuilder','load','pending','getPresentation','string','docs-formula.command.remove','startsWith','buildRemoveDocFormulaActions','replaceDocRanges','boolean','shiftExclusiveRangeOnDelete','externalMutations','status','insert','CellValueType','SECTION_BREAK','SUCCESS','getUnit','DocFormulaLifecycleController','asObservable','_syncUnit','resolveFormula','fromEntries','start','startOffset','PENDING','getUnitId','identity','clear','resolveBinding','max','ICommandService','change$','_updateFormulaResult','from','JSONX','docs-formula.mutation.set-formula','TABLE_START','decorate','redoMutation','sectionBreaks','SetDocFormulaNumberFormatCommand','CommandType','expectedFormula','RegisterOtherFormulaService','type','TABLE_CELL_START','Document\x20main\x20body\x20is\x20required\x20to\x20insert\x20Doc\x20Formula.','DOC_FORMULA_PLUGIN','_docFormulaModel','every','buildUpsertHostExternalReferenceMutations','references','COLUMN_START','IResourceManagerService','subscribe','_univerInstanceService','UniverDocsPlugin','object','_resources','resourceUndo','TABLE_ROW_END','packageName','resourceRedo','826128xYqYQk','expectedNumberFormat','model','removeUnit','lastValue','registerProvider','_instanceService','_rawResources','_preserveInvalid','serialize','degradeDocFormulaDocumentData','map','trigger','getLoadError','stale','tables','formulaResult$','ERROR','push','DependentOn','1405632znfJkq','getResource','1045ZznrGo','42DbmXFy','@univerjs-pro/docs-formula','documentData','forEach','includes','assertSafeDocFormulaInsertRange','buildInsertDocFormulaActions','syncExecuteCommand','expectedReferenceRevision','MUTATION','setFormulas','find','_formulaService','unitId','DOC_FORMULA_CUSTOM_RANGE_KIND','444051KKvqKD','set','presentation','isInteger','_resourceManagerService','getResult','values','add','RemoveDocFormulaMutation','1108uAIKQo','parse','IUndoRedoService','IUniverInstanceService','function','CustomRangeType','getRevision','customDecorations','next','_presentationChanged$','2ljvZEt','eligible','numberFormat','min','properties','previousResource','success','InsertDocFormulaCommand','_config','register','externalReferences','target','cursorOffset','docs-formula.mutation.set-resource','univer-docs-formula','SetDocFormulaMutation','EMPTY','getFormula','customBlocks','docs-formula.command.replace-with-text','Disposable','_queueSync','UpdateDocFormulaCommand','_configService','UniverProFormulaEnginePlugin','registerFormulaWithRange','findDocFormulaRange','keys','resources','getAllUnitsForType','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','empty','formulaId','rangeId','disposeWithMe','DocFormulaDisplayTextService','_model','getOwnPropertyDescriptor','syncUnit','PARAGRAPH','blockRanges','liveResult','getRichTextEditPath','onStarting','getTextRanges','FormulaCacheEligibilityService','nextResource','InvalidDocFormulaInsertRangeError','config','_service','_deleteRegistration','Doc\x20Formula\x20range\x20cannot\x20cross\x20document\x20structure\x20boundaries','onCommandExecuted','_registrationService','color','dataStream','removeFormula','resource','registerPluginResource','paragraphs','_commandService','endOffset','RichTextEditingMutation','columnGroups','toStringTag','getScalarFormulaResultCell','sort','isArray','FormulaLastValuePersistenceService','Injector','BLOCK_START','80wGcdks','stringify','name','slice','iterator','HostExternalReferenceModel','collectFormulaExternalReferenceQualifiers','getBody','docs-formula.command.insert','COLUMN_GROUP_START','shiftInclusiveRangeOnInsert','TextX','formulas','resolveFormulaResultPresentation','selection','DOC_FORMULA_OBJECT_REPLACEMENT','has','deepClone','getInstance','delete','textRuns','paragraphId','rangeType','setFormula','params','CUSTOM','length','OtherFormulaBizType','getParagraphContentStartOffset','COLUMN_END','UniverDocsFormulaPlugin','Plugin','kind','complete','editOp','nextDocumentData','unregister','document','assign','assess','TABLE_END','unitAdded$','SetDocFormulaLastValuesMutation','degradeDocumentData','segmentId','FormulaResultStatus','invalid-resource','296723vnnLJJ','_setPresentation','endIndex','body','251042JzHhuF','setConfig','_isDisposed','text','Inject','endsWith','unregisterUnit','notifyTextChanged','314856sXaBRU','accessor','customRanges','RemoveDocFormulaCommand','TABLE_ROW_START','_syncScheduled','DataStreamTreeTokenType','Tools','getFormulas','entries','ReplaceDocFormulaWithTextCommand','_change$','previousDocumentData','referenceRevision','source','getRegisteredFormulas','insertLength','UniverLicensePlugin','dispose','DocSelectionManagerService','getCustomRangeInterval','pattern','defineProperty','get','DOC','DOC_SELECTION_OPTION_PRESERVE_CARET','undoMutation','docs-formula.mutation.set-last-values','merge'];_0x17d4=function(){return _0x46e941;};return _0x17d4();}function ae(_0x5bb7aa,_0x503981){const _0x59e1c6=_0x4b9f04;return{'startIndex':_0x503981,'endIndex':_0x503981,'rangeId':_0x5bb7aa,'rangeType':t[_0x59e1c6(0x239)][_0x59e1c6(0x169)],'wholeEntity':!0x0,'properties':{'kind':s}};}function v(_0x10d2b3){const _0x2ab609=_0x4b9f04;return _0x10d2b3?t[_0x2ab609(0x192)][_0x2ab609(0x161)](_0x10d2b3):c();}function oe(_0x135698,_0x2041f7,_0x42cd85){const _0x47713d=_0x4b9f04;let _0x37b0c4=se(_0x135698),_0x3527b2=_0x2041f7??_0x37b0c4,_0x802398=_0x42cd85??_0x3527b2;return{'startOffset':y(Math[_0x47713d(0x241)](_0x3527b2,_0x802398),_0x37b0c4),'endOffset':y(Math[_0x47713d(0x1e3)](_0x3527b2,_0x802398),_0x37b0c4)};}function y(_0x48d6b3,_0x50fa48){const _0x144489=_0x4b9f04;return Math[_0x144489(0x1e3)](0x0,Math[_0x144489(0x241)](_0x48d6b3,_0x50fa48));}function se(_0x22f9cf){const _0x5f44aa=_0x4b9f04;return _0x22f9cf[_0x5f44aa(0x275)][_0x5f44aa(0x188)](''+t['DataStreamTreeTokenType'][_0x5f44aa(0x265)]+t['DataStreamTreeTokenType'][_0x5f44aa(0x1d4)])?Math[_0x5f44aa(0x1e3)](0x0,_0x22f9cf[_0x5f44aa(0x275)][_0x5f44aa(0x16a)]-0x2):_0x22f9cf[_0x5f44aa(0x275)][_0x5f44aa(0x188)](t['DataStreamTreeTokenType']['SECTION_BREAK'])?Math['max'](0x0,_0x22f9cf[_0x5f44aa(0x275)][_0x5f44aa(0x16a)]-0x1):_0x22f9cf[_0x5f44aa(0x275)]['length'];}function ce(_0x2fe717,_0x5b9fb0,_0x59b346,_0x1ef176){_0x59b346>_0x5b9fb0&&de(_0x2fe717,_0x5b9fb0,_0x59b346),ue(_0x2fe717,_0x5b9fb0,_0x1ef176);}function le(_0x179f23,_0x248268,_0x1b3fca){const _0x4a3893=_0x4b9f04;var _0x2c0f1e,_0x5441b6;let _0x134c84=T(_0x179f23),_0x3ec975=(_0x2c0f1e=_0x134c84[_0x4a3893(0x18d)])==null?void 0x0:_0x2c0f1e['find'](_0x15fe1a=>_0x15fe1a[_0x4a3893(0x25f)]===_0x248268&&g(_0x15fe1a));if(!_0x3ec975)return null;let _0x36003a=(0x0,t[_0x4a3893(0x19f)])(_0x3ec975);return ce(_0x134c84,_0x36003a[_0x4a3893(0x1dd)],_0x36003a['endOffset'],_0x1b3fca),_0x134c84['customRanges']=(_0x5441b6=_0x134c84['customRanges'])==null?void 0x0:_0x5441b6[_0x4a3893(0x1c3)](_0x1772d5=>_0x1772d5[_0x4a3893(0x25f)]!==_0x248268),_0x36003a[_0x4a3893(0x1dd)]+_0x1b3fca[_0x4a3893(0x16a)];}function ue(_0x1e20c8,_0x1528a8,_0x2003f2){const _0x19ce71=_0x4b9f04;_0x2003f2&&(_0x1e20c8[_0x19ce71(0x275)]=''+_0x1e20c8[_0x19ce71(0x275)][_0x19ce71(0x153)](0x0,_0x1528a8)+_0x2003f2+_0x1e20c8['dataStream'][_0x19ce71(0x153)](_0x1528a8),fe(_0x1e20c8,_0x1528a8,_0x2003f2['length']));}function de(_0x554a1c,_0x425e70,_0x1d9259){const _0x5e24b1=_0x4b9f04;let _0x1b2fb3=_0x1d9259-_0x425e70;_0x554a1c[_0x5e24b1(0x275)]=''+_0x554a1c[_0x5e24b1(0x275)][_0x5e24b1(0x153)](0x0,_0x425e70)+_0x554a1c[_0x5e24b1(0x275)][_0x5e24b1(0x153)](_0x1d9259),pe(_0x554a1c,_0x425e70,_0x1b2fb3);}function fe(_0x2fe708,_0x3729f4,_0x426bac){const _0x45187f=_0x4b9f04;_0x2fe708[_0x45187f(0x279)]=b(_0x2fe708[_0x45187f(0x279)],_0x3729f4,_0x426bac),_0x2fe708['sectionBreaks']=b(_0x2fe708['sectionBreaks'],_0x3729f4,_0x426bac),_0x2fe708[_0x45187f(0x250)]=b(_0x2fe708[_0x45187f(0x250)],_0x3729f4,_0x426bac),_0x2fe708[_0x45187f(0x164)]=me(_0x2fe708[_0x45187f(0x164)],_0x3729f4,_0x426bac),_0x2fe708['tables']=he(_0x2fe708['tables'],_0x3729f4,_0x426bac),_0x2fe708[_0x45187f(0x148)]=S(_0x2fe708[_0x45187f(0x148)],_0x3729f4,_0x426bac),_0x2fe708[_0x45187f(0x18d)]=S(_0x2fe708[_0x45187f(0x18d)],_0x3729f4,_0x426bac),_0x2fe708[_0x45187f(0x23b)]=S(_0x2fe708['customDecorations'],_0x3729f4,_0x426bac),_0x2fe708[_0x45187f(0x266)]=S(_0x2fe708['blockRanges'],_0x3729f4,_0x426bac);}function pe(_0x108b94,_0x2c937e,_0x3311c6){const _0x244356=_0x4b9f04;var _0x38e6c3,_0x2963b9;_0x108b94[_0x244356(0x279)]=x(_0x108b94[_0x244356(0x279)],_0x2c937e,_0x3311c6),_0x108b94[_0x244356(0x1ed)]=x(_0x108b94['sectionBreaks'],_0x2c937e,_0x3311c6),_0x108b94[_0x244356(0x250)]=x(_0x108b94[_0x244356(0x250)],_0x2c937e,_0x3311c6),_0x108b94[_0x244356(0x164)]=(_0x38e6c3=w((_0x2963b9=_0x108b94['textRuns'])==null?void 0x0:_0x2963b9[_0x244356(0x210)](_0x2f1c78=>({..._0x2f1c78,'startIndex':_0x2f1c78['st'],'endIndex':_0x2f1c78['ed']})),_0x2c937e,_0x3311c6))==null?void 0x0:_0x38e6c3['map'](_0xc8756=>{let {startIndex:_0xf79755,endIndex:_0x1ba621,..._0x50af6f}=_0xc8756;return{..._0x50af6f,'st':_0xf79755,'ed':_0x1ba621};}),_0x108b94[_0x244356(0x214)]=w(_0x108b94['tables'],_0x2c937e,_0x3311c6),_0x108b94[_0x244356(0x148)]=C(_0x108b94[_0x244356(0x148)],_0x2c937e,_0x3311c6),_0x108b94[_0x244356(0x18d)]=C(_0x108b94['customRanges'],_0x2c937e,_0x3311c6),_0x108b94[_0x244356(0x23b)]=C(_0x108b94[_0x244356(0x23b)],_0x2c937e,_0x3311c6),_0x108b94['blockRanges']=C(_0x108b94[_0x244356(0x266)],_0x2c937e,_0x3311c6);}function b(_0x465167,_0x43b6f8,_0x571306){const _0x1ab714=_0x4b9f04;return _0x465167==null?void 0x0:_0x465167[_0x1ab714(0x210)](_0x589233=>_0x589233['startIndex']>=_0x43b6f8?{..._0x589233,'startIndex':_0x589233[_0x1ab714(0x1be)]+_0x571306}:_0x589233);}function x(_0x523113,_0xd3c2e1,_0x366a40){const _0x252e86=_0x4b9f04;let _0x58cd85=_0xd3c2e1+_0x366a40;return _0x523113==null?void 0x0:_0x523113[_0x252e86(0x210)](_0x366274=>_0x366274['startIndex']>=_0xd3c2e1&&_0x366274[_0x252e86(0x1be)]<_0x58cd85?null:_0x366274[_0x252e86(0x1be)]>=_0x58cd85?{..._0x366274,'startIndex':_0x366274[_0x252e86(0x1be)]-_0x366a40}:_0x366274)['filter'](_0xc0ad35=>_0xc0ad35!=null);}function me(_0x2005e5,_0x1fb804,_0xe7d868){const _0x5cbac0=_0x4b9f04;return _0x2005e5==null?void 0x0:_0x2005e5[_0x5cbac0(0x210)](_0x88d907=>_0x88d907['st']>=_0x1fb804?{..._0x88d907,'st':_0x88d907['st']+_0xe7d868,'ed':_0x88d907['ed']+_0xe7d868}:_0x88d907['ed']>_0x1fb804?{..._0x88d907,'ed':_0x88d907['ed']+_0xe7d868}:_0x88d907);}function S(_0x5b289b,_0x42b074,_0x23cb50){const _0x1c23e6=_0x4b9f04;return _0x5b289b==null?void 0x0:_0x5b289b['map'](_0x54efce=>(0x0,t[_0x1c23e6(0x15a)])(_0x54efce,_0x42b074,_0x23cb50));}function he(_0xc7ead4,_0x1debde,_0x3d9985){const _0x5220d0=_0x4b9f04;return _0xc7ead4==null?void 0x0:_0xc7ead4[_0x5220d0(0x210)](_0x36ccd3=>(0x0,t['shiftExclusiveRangeOnInsert'])(_0x36ccd3,_0x1debde,_0x3d9985));}function C(_0x478903,_0x5bcd0c,_0x5b06bf){const _0x5d7b29=_0x4b9f04;return _0x478903==null?void 0x0:_0x478903[_0x5d7b29(0x210)](_0x43580d=>(0x0,t['shiftInclusiveRangeOnDelete'])(_0x43580d,_0x5bcd0c,_0x5b06bf))[_0x5d7b29(0x1c3)](_0x3499d8=>_0x3499d8!=null);}function w(_0x216499,_0x206350,_0xbd0d8){const _0xc7404b=_0x4b9f04;return _0x216499==null?void 0x0:_0x216499[_0xc7404b(0x210)](_0x54eb34=>(0x0,t[_0xc7404b(0x1cf)])(_0x54eb34,_0x206350,_0xbd0d8))[_0xc7404b(0x1c3)](_0x271855=>_0x271855!=null);}function T(_0x2f37f9){const _0x4e81e6=_0x4b9f04;if(!_0x2f37f9['body'])throw Error(_0x4e81e6(0x1f4));return _0x2f37f9[_0x4e81e6(0x182)];}function E(_0x42faee){'@babel/helpers - typeof';const _0x54c17d=_0x4b9f04;return E=typeof Symbol==_0x54c17d(0x238)&&typeof Symbol[_0x54c17d(0x154)]==_0x54c17d(0x1af)?function(_0x174415){return typeof _0x174415;}:function(_0x4c089f){const _0x56101d=_0x54c17d;return _0x4c089f&&typeof Symbol=='function'&&_0x4c089f['constructor']===Symbol&&_0x4c089f!==Symbol['prototype']?_0x56101d(0x1af):typeof _0x4c089f;},E(_0x42faee);}function ge(_0x492f9f,_0x3034e7){const _0x161473=_0x4b9f04;if(E(_0x492f9f)!=_0x161473(0x1ff)||!_0x492f9f)return _0x492f9f;var _0x5f0013;if(typeof Symbol<'u'&&(_0x5f0013=_0x492f9f[Symbol[_0x161473(0x1a8)]])!==void 0x0){var _0x830d23=_0x5f0013['call'](_0x492f9f,_0x3034e7||'default');if(E(_0x830d23)!=_0x161473(0x1ff))return _0x830d23;throw TypeError(_0x161473(0x25c));}return(_0x3034e7===_0x161473(0x1c9)?String:Number)(_0x492f9f);}function _e(_0x5e7792){const _0x2adb20=_0x4b9f04;var _0x363aa4=ge(_0x5e7792,_0x2adb20(0x1c9));return E(_0x363aa4)==_0x2adb20(0x1af)?_0x363aa4:_0x363aa4+'';}function D(_0x35c511,_0x440ece,_0x272a6a){return(_0x440ece=_e(_0x440ece))in _0x35c511?Object['defineProperty'](_0x35c511,_0x440ece,{'value':_0x272a6a,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x35c511[_0x440ece]=_0x272a6a,_0x35c511;}var O=class extends t[_0x4b9f04(0x252)]{constructor(..._0x4f4887){const _0x4a3f0e=_0x4b9f04;super(..._0x4f4887),D(this,'_resources',new Map()),D(this,'_rawResources',new Map()),D(this,_0x4a3f0e(0x1ac),new Map()),D(this,'_change$',new i['Subject']()),D(this,_0x4a3f0e(0x1e5),this['_change$'][_0x4a3f0e(0x1d8)]());}[_0x4b9f04(0x24f)](_0x359615,_0x3c13bc){const _0x2065b5=_0x4b9f04;var _0xdc6f56;let _0x11a8d7=(_0xdc6f56=this[_0x2065b5(0x200)][_0x2065b5(0x1a2)](_0x359615))==null?void 0x0:_0xdc6f56['formulas'][_0x3c13bc];return _0x11a8d7?t[_0x2065b5(0x192)][_0x2065b5(0x161)](_0x11a8d7):void 0x0;}[_0x4b9f04(0x193)](_0x57a7d7){const _0x52aa5c=_0x4b9f04;var _0x5d2437;return t[_0x52aa5c(0x192)][_0x52aa5c(0x161)](((_0x5d2437=this[_0x52aa5c(0x200)]['get'](_0x57a7d7))==null?void 0x0:_0x5d2437[_0x52aa5c(0x15c)])??{});}[_0x4b9f04(0x21a)](_0xfac344){const _0x52b988=_0x4b9f04;let _0x5b8b9c=this[_0x52b988(0x200)][_0x52b988(0x1a2)](_0xfac344);return _0x5b8b9c?t[_0x52b988(0x192)][_0x52b988(0x161)](_0x5b8b9c):void 0x0;}[_0x4b9f04(0x167)](_0x96fa14,_0x7a2820,_0x47aa6c){return this['setFormulas'](_0x96fa14,{[_0x7a2820]:_0x47aa6c});}[_0x4b9f04(0x1b0)](_0x2c5274,_0x273f55){const _0x2304c7=_0x4b9f04;return this['_loadErrors'][_0x2304c7(0x160)](_0x2c5274)||!l(_0x273f55)?!0x1:(this[_0x2304c7(0x200)][_0x2304c7(0x22c)](_0x2c5274,{'formulas':t[_0x2304c7(0x192)][_0x2304c7(0x161)](_0x273f55[_0x2304c7(0x15c)])}),this[_0x2304c7(0x196)][_0x2304c7(0x23c)]({'unitId':_0x2c5274}),!0x0);}[_0x4b9f04(0x226)](_0x429370,_0x200779){const _0x575d86=_0x4b9f04;if(this[_0x575d86(0x1ac)][_0x575d86(0x160)](_0x429370)||!Object[_0x575d86(0x259)](_0x200779)['length']||!l({'formulas':_0x200779}))return!0x1;let _0x51bd7=this[_0x575d86(0x200)][_0x575d86(0x1a2)](_0x429370)??c(),_0x2ed616=t[_0x575d86(0x192)][_0x575d86(0x161)](_0x51bd7);return Object[_0x575d86(0x176)](_0x2ed616[_0x575d86(0x15c)],t['Tools']['deepClone'](_0x200779)),this[_0x575d86(0x200)][_0x575d86(0x22c)](_0x429370,_0x2ed616),this[_0x575d86(0x196)][_0x575d86(0x23c)]({'unitId':_0x429370,'rangeIds':Object[_0x575d86(0x259)](_0x200779)}),!0x0;}[_0x4b9f04(0x276)](_0x16e39f,_0x212158){const _0x47f2fd=_0x4b9f04;if(this[_0x47f2fd(0x1ac)][_0x47f2fd(0x160)](_0x16e39f))return!0x1;let _0x29cf45=this[_0x47f2fd(0x200)][_0x47f2fd(0x1a2)](_0x16e39f);if(!(_0x29cf45!=null&&_0x29cf45[_0x47f2fd(0x15c)][_0x212158]))return!0x1;let _0x33233c=t['Tools'][_0x47f2fd(0x161)](_0x29cf45);return delete _0x33233c[_0x47f2fd(0x15c)][_0x212158],this['_resources']['set'](_0x16e39f,_0x33233c),this[_0x47f2fd(0x196)]['next']({'unitId':_0x16e39f,'rangeIds':[_0x212158]}),!0x0;}[_0x4b9f04(0x1c6)](_0x27fa56,_0x24867d){const _0x19d805=_0x4b9f04;return l(_0x24867d)?(this[_0x19d805(0x200)][_0x19d805(0x22c)](_0x27fa56,{'formulas':t[_0x19d805(0x192)][_0x19d805(0x161)](_0x24867d[_0x19d805(0x15c)])}),this['_rawResources']['delete'](_0x27fa56),this[_0x19d805(0x1ac)][_0x19d805(0x163)](_0x27fa56),this['_change$']['next']({'unitId':_0x27fa56}),!0x0):(this[_0x19d805(0x20d)](_0x27fa56,_0x24867d,_0x19d805(0x17e)),!0x1);}[_0x4b9f04(0x20e)](_0x2b2402){const _0x284962=_0x4b9f04;let _0x102793=this[_0x284962(0x200)][_0x284962(0x1a2)](_0x2b2402);return _0x102793?t['Tools'][_0x284962(0x161)](_0x102793):this[_0x284962(0x20c)][_0x284962(0x160)](_0x2b2402)?t[_0x284962(0x192)][_0x284962(0x161)](this[_0x284962(0x20c)]['get'](_0x2b2402)):c();}['getLoadError'](_0x52bf9f){const _0x2be50e=_0x4b9f04;return this['_loadErrors'][_0x2be50e(0x1a2)](_0x52bf9f);}[_0x4b9f04(0x208)](_0x2d4b3a){const _0x470d8f=_0x4b9f04;this[_0x470d8f(0x200)]['delete'](_0x2d4b3a),this[_0x470d8f(0x20c)]['delete'](_0x2d4b3a),this['_loadErrors'][_0x470d8f(0x163)](_0x2d4b3a),this['_change$'][_0x470d8f(0x23c)]({'unitId':_0x2d4b3a});}[_0x4b9f04(0x19d)](){const _0x54118a=_0x4b9f04;this[_0x54118a(0x200)]['clear'](),this['_rawResources'][_0x54118a(0x1e1)](),this[_0x54118a(0x1ac)][_0x54118a(0x1e1)](),this[_0x54118a(0x196)]['complete'](),super[_0x54118a(0x19d)]();}['_preserveInvalid'](_0x2ffd33,_0xf83a45,_0x9a2c3){const _0x49a3ad=_0x4b9f04;this[_0x49a3ad(0x200)]['delete'](_0x2ffd33),this[_0x49a3ad(0x20c)][_0x49a3ad(0x22c)](_0x2ffd33,t[_0x49a3ad(0x192)]['deepClone'](_0xf83a45)),this[_0x49a3ad(0x1ac)]['set'](_0x2ffd33,_0x9a2c3),this[_0x49a3ad(0x196)][_0x49a3ad(0x23c)]({'unitId':_0x2ffd33});}};let ve=function(_0x1670ca){const _0xcf4eea=_0x4b9f04;return _0x1670ca[_0xcf4eea(0x24e)]=_0xcf4eea(0x25d),_0x1670ca[_0xcf4eea(0x1de)]='pending',_0x1670ca[_0xcf4eea(0x1d5)]=_0xcf4eea(0x244),_0x1670ca[_0xcf4eea(0x216)]=_0xcf4eea(0x1bf),_0x1670ca;}({});function k(_0x54c02e,_0x25ed9f){return function(_0x1c2db3,_0x5213f1){_0x25ed9f(_0x1c2db3,_0x5213f1,_0x54c02e);};}function A(_0x4ca975,_0x1ea85e,_0x49f1a1,_0x32f0a9){const _0x2048c7=_0x4b9f04;var _0x19f2c7=arguments[_0x2048c7(0x16a)],_0x2da447=_0x19f2c7<0x3?_0x1ea85e:_0x32f0a9===null?_0x32f0a9=Object[_0x2048c7(0x263)](_0x1ea85e,_0x49f1a1):_0x32f0a9,_0x328781;if(typeof Reflect=='object'&&typeof Reflect[_0x2048c7(0x1eb)]==_0x2048c7(0x238))_0x2da447=Reflect[_0x2048c7(0x1eb)](_0x4ca975,_0x1ea85e,_0x49f1a1,_0x32f0a9);else{for(var _0x148a97=_0x4ca975[_0x2048c7(0x16a)]-0x1;_0x148a97>=0x0;_0x148a97--)(_0x328781=_0x4ca975[_0x148a97])&&(_0x2da447=(_0x19f2c7<0x3?_0x328781(_0x2da447):_0x19f2c7>0x3?_0x328781(_0x1ea85e,_0x49f1a1,_0x2da447):_0x328781(_0x1ea85e,_0x49f1a1))||_0x2da447);}return _0x19f2c7>0x3&&_0x2da447&&Object[_0x2048c7(0x1a1)](_0x1ea85e,_0x49f1a1,_0x2da447),_0x2da447;}let j=class extends t[_0x4b9f04(0x252)]{constructor(_0x23a585,_0x40792f,_0x2f5e01){const _0x6fdf3b=_0x4b9f04;super(),this[_0x6fdf3b(0x262)]=_0x23a585,this[_0x6fdf3b(0x273)]=_0x40792f,this[_0x6fdf3b(0x1b7)]=_0x2f5e01,D(this,'_registrations',new Map()),D(this,_0x6fdf3b(0x1bc),new Map()),D(this,_0x6fdf3b(0x23d),new i['Subject']()),D(this,'presentationChanged$',this[_0x6fdf3b(0x23d)]['asObservable']()),this[_0x6fdf3b(0x260)](this[_0x6fdf3b(0x273)][_0x6fdf3b(0x215)]['subscribe'](_0x356131=>{const _0x3c0e7d=_0x6fdf3b;for(let _0x43ca30 of Object[_0x3c0e7d(0x231)](_0x356131))for(let _0x2dec0d of Object['values'](_0x43ca30))_0x2dec0d[_0x3c0e7d(0x21f)](_0x8094b8=>this[_0x3c0e7d(0x1e6)](_0x8094b8));}));}[_0x4b9f04(0x264)](_0x2af3ae){const _0x183183=_0x4b9f04;var _0xe4bc59;let _0x27dbda=_0x2af3ae['getUnitId'](),_0x598be3=((_0xe4bc59=_0x2af3ae['getSnapshot']()[_0x183183(0x182)])==null||(_0xe4bc59=_0xe4bc59['customRanges'])==null?void 0x0:_0xe4bc59[_0x183183(0x1c3)](g))??[],_0x310a1e=this['_model'][_0x183183(0x193)](_0x27dbda),_0x49a26b=new Set();for(let _0x12bd42 of _0x598be3){let _0x9992d=_0x310a1e[_0x12bd42[_0x183183(0x25f)]];_0x9992d&&(_0x49a26b['add'](M(_0x27dbda,_0x12bd42[_0x183183(0x25f)])),this['register']({'unitId':_0x27dbda,'rangeId':_0x12bd42[_0x183183(0x25f)]},_0x9992d));}for(let _0x1e2b24 of Array['from'](this[_0x183183(0x1b4)][_0x183183(0x231)]()))_0x1e2b24['unitId']===_0x27dbda&&!_0x49a26b[_0x183183(0x160)](M(_0x1e2b24[_0x183183(0x229)],_0x1e2b24['rangeId']))&&this[_0x183183(0x174)](_0x1e2b24);}[_0x4b9f04(0x247)](_0x455613,_0x37ae30){const _0x446b2a=_0x4b9f04;let _0x2767aa=M(_0x455613[_0x446b2a(0x229)],_0x455613[_0x446b2a(0x25f)]),_0x42cddd=this[_0x446b2a(0x1b4)][_0x446b2a(0x1a2)](_0x2767aa),_0x66b4e0=this['_hostExternalReferenceModel']['getRevision'](_0x455613[_0x446b2a(0x229)]);if(_0x42cddd&&_0x42cddd[_0x446b2a(0x26e)]['formula']===_0x37ae30[_0x446b2a(0x1bd)]&&_0x42cddd['referenceRevision']===_0x66b4e0){_0x42cddd[_0x446b2a(0x26e)]=_0x37ae30;let _0x9eef01=_0x42cddd[_0x446b2a(0x25e)]?this[_0x446b2a(0x273)][_0x446b2a(0x1aa)](_0x42cddd[_0x446b2a(0x229)],_0x42cddd[_0x446b2a(0x229)],_0x42cddd[_0x446b2a(0x25e)])??void 0x0:void 0x0;_0x42cddd[_0x446b2a(0x267)]=_0x9eef01,this['_setPresentation'](_0x2767aa,N(_0x37ae30,_0x9eef01));return;}_0x42cddd!=null&&_0x42cddd['formulaId']&&this['_deleteRegistration'](_0x42cddd);let _0x2dec2a={..._0x455613,'config':_0x37ae30,'referenceRevision':_0x66b4e0,'presentation':N(_0x37ae30,void 0x0)};if(this[_0x446b2a(0x1b4)][_0x446b2a(0x22c)](_0x2767aa,_0x2dec2a),!_0x37ae30['formula'][_0x446b2a(0x1b8)]())return;let _0x1fce3e=this[_0x446b2a(0x273)][_0x446b2a(0x257)](_0x455613[_0x446b2a(0x229)],_0x455613[_0x446b2a(0x229)],_0x37ae30[_0x446b2a(0x1bd)],void 0x0,{'rangeId':_0x455613[_0x446b2a(0x25f)]},r[_0x446b2a(0x16b)][_0x446b2a(0x1a3)],_0x455613[_0x446b2a(0x25f)]);_0x2dec2a[_0x446b2a(0x25e)]=_0x1fce3e,this[_0x446b2a(0x1bc)][_0x446b2a(0x22c)](_0x1fce3e,_0x2767aa);}['unregister'](_0x984034){const _0x377cab=_0x4b9f04;let _0x29a0f2=M(_0x984034[_0x377cab(0x229)],_0x984034[_0x377cab(0x25f)]),_0x5e4458=this[_0x377cab(0x1b4)][_0x377cab(0x1a2)](_0x29a0f2);_0x5e4458&&(this['_deleteRegistration'](_0x5e4458),this[_0x377cab(0x1b4)]['delete'](_0x29a0f2));}['unregisterUnit'](_0x12164a){const _0x515ffc=_0x4b9f04;for(let _0x19a62b of Array[_0x515ffc(0x1e7)](this['_registrations'][_0x515ffc(0x231)]()))_0x19a62b[_0x515ffc(0x229)]===_0x12164a&&this[_0x515ffc(0x174)](_0x19a62b);}[_0x4b9f04(0x1c8)](_0x1aa98e){const _0xd40a2=_0x4b9f04;var _0x2c22db;return(_0x2c22db=this[_0xd40a2(0x1b4)]['get'](M(_0x1aa98e[_0xd40a2(0x229)],_0x1aa98e[_0xd40a2(0x25f)])))==null?void 0x0:_0x2c22db['presentation'];}['getResult'](_0x28fe86){const _0x3836f0=_0x4b9f04;let _0x8d79f9=this[_0x3836f0(0x1b4)][_0x3836f0(0x1a2)](M(_0x28fe86[_0x3836f0(0x229)],_0x28fe86[_0x3836f0(0x25f)]));return _0x8d79f9?P(_0x8d79f9):void 0x0;}[_0x4b9f04(0x19a)](){const _0x434124=_0x4b9f04;return Array[_0x434124(0x1e7)](this[_0x434124(0x1b4)][_0x434124(0x231)](),_0x35390d=>({'identity':{'unitId':_0x35390d[_0x434124(0x229)],'rangeId':_0x35390d[_0x434124(0x25f)]},'config':_0x35390d['config'],'referenceRevision':_0x35390d[_0x434124(0x198)],..._0x35390d['liveResult']?{'liveResult':_0x35390d[_0x434124(0x267)]}:null}));}[_0x4b9f04(0x19d)](){const _0x336307=_0x4b9f04;for(let _0x5c0e2a of this['_registrations'][_0x336307(0x231)]())this['_deleteRegistration'](_0x5c0e2a);this[_0x336307(0x1b4)][_0x336307(0x1e1)](),this[_0x336307(0x1bc)]['clear'](),this[_0x336307(0x23d)][_0x336307(0x171)](),super[_0x336307(0x19d)]();}['_updateFormulaResult'](_0x3d4a32){const _0x5adcfd=_0x4b9f04;let _0x125632=this[_0x5adcfd(0x1bc)][_0x5adcfd(0x1a2)](_0x3d4a32[_0x5adcfd(0x25e)]),_0x392d46=_0x125632?this[_0x5adcfd(0x1b4)][_0x5adcfd(0x1a2)](_0x125632):void 0x0;_0x125632&&_0x392d46&&(_0x392d46[_0x5adcfd(0x267)]=_0x3d4a32,this[_0x5adcfd(0x180)](_0x125632,N(_0x392d46[_0x5adcfd(0x26e)],_0x3d4a32)));}[_0x4b9f04(0x180)](_0x2147cc,_0x1fc847){const _0x144f2a=_0x4b9f04;var _0x534588,_0x586ada;let _0xe517bd=this[_0x144f2a(0x1b4)]['get'](_0x2147cc);if(!_0xe517bd||ye(_0xe517bd[_0x144f2a(0x22d)],_0x1fc847))return;let _0x21e9ca=_0xe517bd[_0x144f2a(0x22d)],_0x59ccd1=P(_0xe517bd);_0xe517bd[_0x144f2a(0x22d)]=_0x1fc847,this[_0x144f2a(0x23d)][_0x144f2a(0x23c)]({'unitId':_0xe517bd[_0x144f2a(0x229)],'rangeId':_0xe517bd[_0x144f2a(0x25f)],'presentation':_0x1fc847,'previousPresentation':_0x21e9ca,'result':P(_0xe517bd),'previousResult':{..._0x59ccd1,..._0x21e9ca,'value':(_0x534588=_0x21e9ca[_0x144f2a(0x1b5)])==null?void 0x0:_0x534588['v'],'valueType':((_0x586ada=_0x21e9ca['cell'])==null?void 0x0:_0x586ada['t'])??void 0x0}});}[_0x4b9f04(0x270)](_0x830796){const _0x4f56cb=_0x4b9f04;_0x830796[_0x4f56cb(0x25e)]&&(this[_0x4f56cb(0x273)]['deleteFormula'](_0x830796[_0x4f56cb(0x229)],_0x830796[_0x4f56cb(0x229)],[_0x830796[_0x4f56cb(0x25e)]]),this['_formulaKeys']['delete'](_0x830796[_0x4f56cb(0x25e)]));}};j=A([k(0x0,(0x0,t['Inject'])(O)),k(0x1,(0x0,t['Inject'])(r[_0x4b9f04(0x1f1)])),k(0x2,(0x0,t[_0x4b9f04(0x187)])(e[_0x4b9f04(0x155)]))],j);function M(_0x56d6fa,_0x1f26b1){return _0x56d6fa+'\x00'+_0x1f26b1;}function N(_0x44049e,_0x110505){const _0xf533a6=_0x4b9f04;return(0x0,e[_0xf533a6(0x15d)])({'numberFormat':_0x44049e[_0xf533a6(0x240)],'lastValue':_0x44049e['lastValue'],'result':_0x110505});}function P(_0x1333ff){const _0x589c5b=_0x4b9f04;var _0xb5344b,_0x37532d,_0x1cb4b7;let _0x2b14c8=_0x1333ff['presentation'],_0x3f01aa=_0x1333ff[_0x589c5b(0x26e)][_0x589c5b(0x1bd)][_0x589c5b(0x1b8)]()?_0x2b14c8[_0x589c5b(0x213)]||_0x2b14c8[_0x589c5b(0x1b5)]==null?_0x589c5b(0x1c7):((_0xb5344b=_0x1333ff['liveResult'])==null?void 0x0:_0xb5344b[_0x589c5b(0x1d1)])===r[_0x589c5b(0x17d)]['ERROR']?'error':_0x589c5b(0x244):_0x589c5b(0x25d);return{..._0x2b14c8,'status':_0x3f01aa,'value':(_0x37532d=_0x2b14c8[_0x589c5b(0x1b5)])==null?void 0x0:_0x37532d['v'],'valueType':((_0x1cb4b7=_0x2b14c8[_0x589c5b(0x1b5)])==null?void 0x0:_0x1cb4b7['t'])??void 0x0};}function ye(_0x10dd63,_0x339f07){const _0x155063=_0x4b9f04;var _0x52f30c,_0x234330,_0x1c4271,_0x1406da;return _0x10dd63[_0x155063(0x186)]===_0x339f07[_0x155063(0x186)]&&_0x10dd63[_0x155063(0x274)]===_0x339f07[_0x155063(0x274)]&&_0x10dd63[_0x155063(0x1a0)]===_0x339f07['pattern']&&_0x10dd63[_0x155063(0x199)]===_0x339f07['source']&&_0x10dd63['stale']===_0x339f07[_0x155063(0x213)]&&((_0x52f30c=_0x10dd63['cell'])==null?void 0x0:_0x52f30c['t'])===((_0x234330=_0x339f07['cell'])==null?void 0x0:_0x234330['t'])&&Object['is']((_0x1c4271=_0x10dd63['cell'])==null?void 0x0:_0x1c4271['v'],(_0x1406da=_0x339f07[_0x155063(0x1b5)])==null?void 0x0:_0x1406da['v']);}function _0x3404(_0x40387d,_0x1e68e6){_0x40387d=_0x40387d-0x147;const _0x17d407=_0x17d4();let _0x3404b6=_0x17d407[_0x40387d];return _0x3404b6;}const F={'id':_0x4b9f04(0x1e9),'type':t[_0x4b9f04(0x1ef)][_0x4b9f04(0x225)],'handler':(_0x4e9c71,_0x3f3809)=>!(_0x3f3809!=null&&_0x3f3809[_0x4b9f04(0x229)])||!_0x3f3809[_0x4b9f04(0x25f)]||!_0x3f3809['config']?!0x1:_0x4e9c71[_0x4b9f04(0x1a2)](O)[_0x4b9f04(0x167)](_0x3f3809[_0x4b9f04(0x229)],_0x3f3809[_0x4b9f04(0x25f)],_0x3f3809[_0x4b9f04(0x26e)])},I={'id':'docs-formula.mutation.remove-formula','type':t[_0x4b9f04(0x1ef)]['MUTATION'],'handler':(_0x2f8e22,_0x52d641)=>!(_0x52d641!=null&&_0x52d641[_0x4b9f04(0x229)])||!_0x52d641['rangeId']?!0x1:_0x2f8e22['get'](O)[_0x4b9f04(0x276)](_0x52d641[_0x4b9f04(0x229)],_0x52d641[_0x4b9f04(0x25f)])},L={'id':_0x4b9f04(0x24b),'type':t[_0x4b9f04(0x1ef)][_0x4b9f04(0x225)],'handler':(_0x157657,_0x259aa4)=>!(_0x259aa4!=null&&_0x259aa4[_0x4b9f04(0x229)])||!_0x259aa4[_0x4b9f04(0x277)]?!0x1:_0x157657[_0x4b9f04(0x1a2)](O)[_0x4b9f04(0x1b0)](_0x259aa4[_0x4b9f04(0x229)],_0x259aa4[_0x4b9f04(0x277)])},R={'id':_0x4b9f04(0x1a6),'type':t[_0x4b9f04(0x1ef)]['MUTATION'],'handler':(_0x332c97,_0x3bbd68)=>{const _0x316be7=_0x4b9f04;if(!(_0x3bbd68!=null&&_0x3bbd68['unitId'])||!_0x3bbd68[_0x316be7(0x1b1)][_0x316be7(0x16a)])return!0x1;let _0x3b4b8d=_0x332c97[_0x316be7(0x1a2)](O),_0x55849e=_0x332c97[_0x316be7(0x1a2)](e[_0x316be7(0x155)]),_0x5b0352=_0x3b4b8d[_0x316be7(0x21a)](_0x3bbd68['unitId']);if(!_0x5b0352)return!0x1;let _0x49eb6e=t['Tools'][_0x316be7(0x161)](_0x5b0352),_0x2d7509=!0x1;for(let _0x2c7920 of _0x3bbd68[_0x316be7(0x1b1)]){var _0x771d9f,_0x2ba3b3,_0x17835b,_0x2afc78;let _0xab70c2=_0x49eb6e['formulas'][_0x2c7920[_0x316be7(0x25f)]];_0xab70c2&&_0xab70c2['formula']===_0x2c7920[_0x316be7(0x1f0)]&&((_0x771d9f=_0xab70c2[_0x316be7(0x240)])==null?void 0x0:_0x771d9f[_0x316be7(0x1a0)])===_0x2c7920[_0x316be7(0x206)]&&_0x55849e[_0x316be7(0x23a)](_0x3bbd68[_0x316be7(0x229)])===_0x2c7920[_0x316be7(0x224)]&&(((_0x2ba3b3=_0xab70c2['lastValue'])==null?void 0x0:_0x2ba3b3['v'])!==_0x2c7920['lastValue']['v']||((_0x17835b=_0xab70c2[_0x316be7(0x209)])==null?void 0x0:_0x17835b['t'])!==_0x2c7920['lastValue']['t']||((_0x2afc78=_0xab70c2[_0x316be7(0x209)])==null?void 0x0:_0x2afc78[_0x316be7(0x1a0)])!==_0x2c7920[_0x316be7(0x209)][_0x316be7(0x1a0)])&&(_0xab70c2['lastValue']=t['Tools'][_0x316be7(0x161)](_0x2c7920[_0x316be7(0x209)]),_0x2d7509=!0x0);}return!_0x2d7509||_0x3b4b8d[_0x316be7(0x1b0)](_0x3bbd68['unitId'],_0x49eb6e);}},z={'id':_0x4b9f04(0x158),'type':t['CommandType']['COMMAND'],'handler':(_0x32cef4,_0x2e6a73)=>{const _0x2d7bc1=_0x4b9f04;if(!(_0x2e6a73!=null&&_0x2e6a73[_0x2d7bc1(0x1bd)][_0x2d7bc1(0x1b8)]()))return!0x1;let _0x3e6d8c=K(_0x32cef4,_0x2e6a73[_0x2d7bc1(0x229)],'');if(!_0x3e6d8c)return!0x1;let _0x54526f=xe(_0x2e6a73[_0x2d7bc1(0x249)],_0x3e6d8c['body'],be(_0x32cef4,_0x3e6d8c['unitId']));if(!_0x54526f)return!0x1;let _0x3fb60d=Se(_0x32cef4,_0x3e6d8c['unitId'],_0x2e6a73[_0x2d7bc1(0x1bd)],_0x2e6a73[_0x2d7bc1(0x248)]??[]);if(!_0x3fb60d)return!0x1;let _0x114c3e=Ce(_0x3e6d8c['body'],_0x3e6d8c[_0x2d7bc1(0x207)],_0x3e6d8c[_0x2d7bc1(0x229)]),_0x2155e2=we({'documentData':_0x3e6d8c[_0x2d7bc1(0x21e)],'resource':_0x3e6d8c[_0x2d7bc1(0x277)],'rangeId':_0x114c3e,'config':{'formula':_0x2e6a73[_0x2d7bc1(0x1bd)],..._0x2e6a73[_0x2d7bc1(0x240)]?{'numberFormat':_0x2e6a73[_0x2d7bc1(0x240)]}:null},'startOffset':_0x54526f[_0x2d7bc1(0x1dd)],'endOffset':_0x54526f[_0x2d7bc1(0x27b)]});if(!_0x2155e2)return!0x1;let _0x52ba01=(0x0,e[_0x2d7bc1(0x1f8)])(_0x32cef4,_0x3e6d8c[_0x2d7bc1(0x229)],_0x3fb60d);return!_0x52ba01||!q({'accessor':_0x32cef4,'document':_0x3e6d8c[_0x2d7bc1(0x175)],'unitId':_0x3e6d8c[_0x2d7bc1(0x229)],'trigger':z['id'],'rangeId':_0x114c3e,'previousResource':_0x3e6d8c['resource'],'nextResource':_0x2155e2[_0x2d7bc1(0x26c)],'previousDocumentData':_0x3e6d8c[_0x2d7bc1(0x21e)],'nextDocumentData':_0x2155e2[_0x2d7bc1(0x173)],'cursorOffset':_0x2155e2[_0x2d7bc1(0x24a)],'externalMutations':_0x52ba01})?!0x1:{'rangeId':_0x114c3e,'startOffset':_0x2155e2[_0x2d7bc1(0x24a)]-0x1,'endOffset':_0x2155e2[_0x2d7bc1(0x24a)]};}},B={'id':'docs-formula.command.update','type':t[_0x4b9f04(0x1ef)][_0x4b9f04(0x1a9)],'handler':(_0x5ef187,_0x51c876)=>{const _0x37e2ce=_0x4b9f04;if(!(_0x51c876!=null&&_0x51c876[_0x37e2ce(0x25f)])||!_0x51c876[_0x37e2ce(0x1bd)][_0x37e2ce(0x1b8)]())return!0x1;let _0x5ab835=K(_0x5ef187,_0x51c876[_0x37e2ce(0x229)],''),_0x1f7f29=_0x5ab835==null?void 0x0:_0x5ab835[_0x37e2ce(0x207)][_0x37e2ce(0x24f)](_0x5ab835['unitId'],_0x51c876['rangeId']),_0x1054fe=_0x5ab835?_(_0x5ab835[_0x37e2ce(0x21e)][_0x37e2ce(0x182)],_0x51c876[_0x37e2ce(0x25f)]):void 0x0;if(!_0x5ab835||!_0x1f7f29||!_0x1054fe)return!0x1;let _0x355507=Se(_0x5ef187,_0x5ab835[_0x37e2ce(0x229)],_0x51c876[_0x37e2ce(0x1bd)],_0x51c876[_0x37e2ce(0x248)]??[]);if(!_0x355507)return!0x1;let _0x59b14b=(0x0,e[_0x37e2ce(0x1f8)])(_0x5ef187,_0x5ab835[_0x37e2ce(0x229)],_0x355507);if(!_0x59b14b)return!0x1;let _0x143cf0=je(_0x5ab835['resource']);return _0x143cf0[_0x37e2ce(0x15c)][_0x51c876[_0x37e2ce(0x25f)]]={'formula':_0x51c876[_0x37e2ce(0x1bd)],..._0x51c876[_0x37e2ce(0x240)]?{'numberFormat':_0x51c876['numberFormat']}:_0x1f7f29['numberFormat']?{'numberFormat':_0x1f7f29[_0x37e2ce(0x240)]}:null},q({'accessor':_0x5ef187,'document':_0x5ab835[_0x37e2ce(0x175)],'unitId':_0x5ab835[_0x37e2ce(0x229)],'trigger':B['id'],'rangeId':_0x51c876[_0x37e2ce(0x25f)],'previousResource':_0x5ab835['resource'],'nextResource':_0x143cf0,'cursorOffset':_0x1054fe[_0x37e2ce(0x181)]+0x1,'externalMutations':_0x59b14b});}},V={'id':'docs-formula.command.set-number-format','type':t['CommandType']['COMMAND'],'handler':(_0x3c6f1c,_0x59d9c7)=>{const _0x77e472=_0x4b9f04;if(!(_0x59d9c7!=null&&_0x59d9c7[_0x77e472(0x25f)]))return!0x1;let _0x57b631=K(_0x3c6f1c,_0x59d9c7[_0x77e472(0x229)],''),_0x2eec3f=_0x57b631==null?void 0x0:_0x57b631[_0x77e472(0x207)]['getFormula'](_0x57b631[_0x77e472(0x229)],_0x59d9c7[_0x77e472(0x25f)]),_0x4a41a1=_0x57b631?_(_0x57b631[_0x77e472(0x21e)][_0x77e472(0x182)],_0x59d9c7[_0x77e472(0x25f)]):void 0x0;if(!_0x57b631||!_0x2eec3f||!_0x4a41a1)return!0x1;let _0x5da187=je(_0x57b631[_0x77e472(0x277)]);return _0x5da187[_0x77e472(0x15c)][_0x59d9c7[_0x77e472(0x25f)]]={..._0x2eec3f,..._0x59d9c7['numberFormat']?{'numberFormat':_0x59d9c7[_0x77e472(0x240)]}:null},_0x59d9c7['numberFormat']||delete _0x5da187[_0x77e472(0x15c)][_0x59d9c7[_0x77e472(0x25f)]][_0x77e472(0x240)],q({'accessor':_0x3c6f1c,'document':_0x57b631['document'],'unitId':_0x57b631[_0x77e472(0x229)],'trigger':V['id'],'rangeId':_0x59d9c7[_0x77e472(0x25f)],'previousResource':_0x57b631['resource'],'nextResource':_0x5da187,'cursorOffset':_0x4a41a1[_0x77e472(0x181)]+0x1,'externalMutations':{}});}},H={'id':_0x4b9f04(0x1ca),'type':t['CommandType'][_0x4b9f04(0x1a9)],'handler':(_0x31af68,_0x14c20a)=>G(_0x31af68,_0x14c20a,'',H['id'])},U={'id':_0x4b9f04(0x251),'type':t[_0x4b9f04(0x1ef)][_0x4b9f04(0x1a9)],'handler':(_0x31a8cb,_0xe05f8d)=>G(_0x31a8cb,_0xe05f8d,(_0xe05f8d==null?void 0x0:_0xe05f8d[_0x4b9f04(0x186)])??'',U['id'])},W={'id':'docs-formula.command.convert-to-text','type':t[_0x4b9f04(0x1ef)]['COMMAND'],'handler':(_0x30c70d,_0x1e815d)=>{const _0x4ec407=_0x4b9f04;if(!(_0x1e815d!=null&&_0x1e815d[_0x4ec407(0x25f)]))return!0x1;let _0x284af0=K(_0x30c70d,_0x1e815d[_0x4ec407(0x229)],'');if(!_0x284af0)return!0x1;let _0x51b364=_0x30c70d['get'](j)[_0x4ec407(0x230)]({'unitId':_0x284af0[_0x4ec407(0x229)],'rangeId':_0x1e815d['rangeId']});return _0x51b364?G(_0x30c70d,_0x1e815d,_0x51b364[_0x4ec407(0x186)],W['id']):!0x1;}};function G(_0x39ecda,_0x5b1dd2,_0x2709c4,_0x1b265c){const _0x4f75e8=_0x4b9f04;if(!(_0x5b1dd2!=null&&_0x5b1dd2[_0x4f75e8(0x25f)]))return!0x1;let _0x1ca4b1=K(_0x39ecda,_0x5b1dd2[_0x4f75e8(0x229)],'');if(!_0x1ca4b1)return!0x1;let _0x520d60=h({'documentData':_0x1ca4b1[_0x4f75e8(0x21e)],'resource':_0x1ca4b1[_0x4f75e8(0x277)],'rangeId':_0x5b1dd2['rangeId'],'text':_0x2709c4});return _0x520d60?q({'accessor':_0x39ecda,'document':_0x1ca4b1['document'],'unitId':_0x1ca4b1[_0x4f75e8(0x229)],'trigger':_0x1b265c,'rangeId':_0x5b1dd2[_0x4f75e8(0x25f)],'previousResource':_0x1ca4b1[_0x4f75e8(0x277)],'nextResource':_0x520d60[_0x4f75e8(0x26c)],'previousDocumentData':_0x1ca4b1['documentData'],'nextDocumentData':_0x520d60[_0x4f75e8(0x173)],'cursorOffset':_0x520d60[_0x4f75e8(0x24a)],'externalMutations':{}}):!0x1;}function K(_0x6ae8e4,_0x3b7c11,_0x3479f7){const _0x41042a=_0x4b9f04;if(_0x3479f7)return null;let _0xe37420=_0x6ae8e4[_0x41042a(0x1a2)](t['IUniverInstanceService']),_0x4cd1c8=(_0x3b7c11?_0xe37420[_0x41042a(0x1d6)](_0x3b7c11,t['UniverInstanceType'][_0x41042a(0x1ba)]):_0xe37420[_0x41042a(0x1ab)](t[_0x41042a(0x1b6)]['UNIVER_DOC']))??null;if(!_0x4cd1c8)return null;let _0x466173=_0x4cd1c8[_0x41042a(0x1b2)](),_0x5399f7=_0x466173['body'];if(_0x466173['disabled']||!_0x5399f7)return null;let _0x19406b=_0x6ae8e4[_0x41042a(0x1a2)](O);return _0x19406b[_0x41042a(0x212)](_0x4cd1c8[_0x41042a(0x1df)]())?null:{'document':_0x4cd1c8,'body':_0x5399f7,'documentData':_0x466173,'model':_0x19406b,'resource':_0x19406b['getResource'](_0x4cd1c8[_0x41042a(0x1df)]())??c(),'unitId':_0x4cd1c8[_0x41042a(0x1df)]()};}function be(_0x5c624c,_0x577e76){const _0x520ee6=_0x4b9f04;var _0x20c769;return(_0x20c769=_0x5c624c[_0x520ee6(0x1a2)](n[_0x520ee6(0x19e)])[_0x520ee6(0x26a)]({'subUnitId':_0x577e76,'unitId':_0x577e76}))==null?void 0x0:_0x20c769[0x0];}function xe(_0x11640d,_0x5a2597,_0x38ac02){const _0xccfe89=_0x4b9f04;if((_0x11640d==null?void 0x0:_0x11640d[_0xccfe89(0x1f2)])==='paragraph'){var _0x490c5a;let _0x32911a=((_0x490c5a=_0x5a2597[_0xccfe89(0x279)])==null?void 0x0:_0x490c5a[_0xccfe89(0x1c3)](_0x5f23c1=>_0x5f23c1[_0xccfe89(0x165)]===_0x11640d[_0xccfe89(0x165)]))??[];if(_0x32911a[_0xccfe89(0x16a)]!==0x1)return null;let _0x2cafa7=_0x32911a[0x0],_0x5cdb33=(0x0,t[_0xccfe89(0x16c)])(_0x5a2597,_0x2cafa7),_0x7b1891=_0x2cafa7[_0xccfe89(0x1be)]-_0x5cdb33,_0x2261ab=_0x11640d[_0xccfe89(0x1c4)]==='end'?_0x7b1891:_0x11640d['position'];if(!Number[_0xccfe89(0x22e)](_0x2261ab)||_0x2261ab<0x0||_0x2261ab>_0x7b1891)return null;let _0x59c326=_0x5cdb33+_0x2261ab;return{'startOffset':_0x59c326,'endOffset':_0x59c326};}if((_0x11640d==null?void 0x0:_0x11640d[_0xccfe89(0x1f2)])==='range')return!Number['isInteger'](_0x11640d[_0xccfe89(0x1dd)])||!Number[_0xccfe89(0x22e)](_0x11640d[_0xccfe89(0x27b)])?null:{'startOffset':Math['min'](_0x11640d['startOffset'],_0x11640d[_0xccfe89(0x27b)]),'endOffset':Math[_0xccfe89(0x1e3)](_0x11640d['startOffset'],_0x11640d[_0xccfe89(0x27b)])};let _0x1937ff=(_0x11640d==null?void 0x0:_0x11640d[_0xccfe89(0x1f2)])===_0xccfe89(0x15e)?_0x11640d['selection']:_0x38ac02;return!_0x1937ff||_0x1937ff[_0xccfe89(0x17c)]?null:{'startOffset':Math[_0xccfe89(0x241)](_0x1937ff[_0xccfe89(0x1dd)],_0x1937ff['endOffset']),'endOffset':Math[_0xccfe89(0x1e3)](_0x1937ff['startOffset'],_0x1937ff[_0xccfe89(0x27b)])};}function Se(_0x34fb30,_0x3e839e,_0x4c15c5,_0x5cca2f){const _0x58f250=_0x4b9f04;let _0x4cdc40=_0x34fb30[_0x58f250(0x1a2)](r['LexerTreeBuilder']),_0x30377a=_0x4c15c5[_0x58f250(0x1cb)]('=')?_0x4c15c5['slice'](0x1):_0x4c15c5,_0x1defa1=_0x4cdc40[_0x58f250(0x1c5)](_0x30377a);if(!_0x1defa1)return null;let _0x1d983a=_0x34fb30[_0x58f250(0x1a2)](e['HostExternalReferenceModel']),_0x29c41b=(0x0,e['resolveHostFormulaExternalReferences'])({'qualifiers':(0x0,e[_0x58f250(0x156)])(_0x1defa1),'explicitReferences':_0x5cca2f??[],'resolveBinding':_0x3d0265=>_0x1d983a[_0x58f250(0x1e2)](_0x3e839e,_0x3d0265)});return _0x29c41b[_0x58f250(0x1d1)]==='resolved'?_0x29c41b[_0x58f250(0x1f9)]:null;}function Ce(_0x5a747f,_0x3a0f0c,_0x29e591){const _0x20d904=_0x4b9f04;var _0x2473fd;let _0x26091d=(0x0,t['generateRandomId'])(0x6);for(;_0x5a747f!=null&&(_0x2473fd=_0x5a747f['customRanges'])!=null&&_0x2473fd['some'](_0x2d32ce=>_0x2d32ce[_0x20d904(0x25f)]===_0x26091d)||_0x3a0f0c[_0x20d904(0x24f)](_0x29e591,_0x26091d);)_0x26091d=(0x0,t['generateRandomId'])(0x6);return _0x26091d;}function we(_0x54d1ce){try{return te(_0x54d1ce);}catch(_0x29b55b){if(_0x29b55b instanceof m)return null;throw _0x29b55b;}}function Te(_0x582cf1){const _0x45d374=_0x4b9f04;let _0x2f5d03=_0x582cf1['previousDocumentData']&&_0x582cf1['nextDocumentData']?De(_0x582cf1[_0x45d374(0x175)],_0x582cf1[_0x45d374(0x229)],_0x582cf1['previousDocumentData'],_0x582cf1[_0x45d374(0x173)],_0x582cf1[_0x45d374(0x24a)],_0x582cf1[_0x45d374(0x211)]):null;return _0x582cf1[_0x45d374(0x197)]&&_0x582cf1['nextDocumentData']&&!_0x2f5d03?null:{'documentRedo':_0x2f5d03,'resourceRedo':{'id':L['id'],'params':{'unitId':_0x582cf1[_0x45d374(0x229)],'resource':_0x582cf1[_0x45d374(0x26c)]}},'resourceUndo':{'id':L['id'],'params':{'unitId':_0x582cf1[_0x45d374(0x229)],'resource':_0x582cf1[_0x45d374(0x243)]}}};}function Ee(_0x5bc113,_0x44d8b8,_0x274d64,_0x2a744b){const _0x2b6e9e=_0x4b9f04;_0x2a744b['pushUndoRedo']({'id':_0x5bc113[_0x2b6e9e(0x211)]+':'+_0x5bc113['rangeId'],'unitID':_0x5bc113['unitId'],'redoMutations':[..._0x5bc113['externalMutations'][_0x2b6e9e(0x1ec)]?[_0x5bc113[_0x2b6e9e(0x1d0)][_0x2b6e9e(0x1ec)]]:[],..._0x44d8b8[_0x2b6e9e(0x1b3)]?[_0x44d8b8[_0x2b6e9e(0x1b3)]]:[],_0x44d8b8['resourceRedo']],'undoMutations':[_0x44d8b8[_0x2b6e9e(0x201)],..._0x274d64?[_0x274d64]:[],..._0x5bc113[_0x2b6e9e(0x1d0)][_0x2b6e9e(0x1a5)]?[_0x5bc113[_0x2b6e9e(0x1d0)][_0x2b6e9e(0x1a5)]]:[]]});}function q(_0x3257f1){const _0x41054b=_0x4b9f04;let _0x527630=_0x3257f1[_0x41054b(0x18c)][_0x41054b(0x1a2)](t[_0x41054b(0x1e4)]),_0x5f5515=_0x3257f1['accessor'][_0x41054b(0x1a2)](t[_0x41054b(0x236)]),_0x4981a0=_0x3257f1[_0x41054b(0x18c)][_0x41054b(0x1a2)](n[_0x41054b(0x19e)]),_0x23449c=Te(_0x3257f1);if(!_0x23449c)return!0x1;let _0x2e9577=!0x1,_0x1d5217=null,_0x380127=!0x1;try{if(_0x3257f1[_0x41054b(0x1d0)][_0x41054b(0x1ec)]){if(!_0x527630[_0x41054b(0x223)](_0x3257f1[_0x41054b(0x1d0)][_0x41054b(0x1ec)]['id'],_0x3257f1['externalMutations']['redoMutation']['params']))return!0x1;_0x2e9577=!0x0;}if(_0x23449c[_0x41054b(0x1b3)]){let _0x543cd7=_0x527630[_0x41054b(0x223)](_0x23449c[_0x41054b(0x1b3)]['id'],_0x23449c[_0x41054b(0x1b3)][_0x41054b(0x168)]);if(!_0x543cd7)return J(_0x527630,_0x3257f1[_0x41054b(0x1d0)],_0x2e9577),!0x1;_0x1d5217={'id':n['RichTextEditingMutation']['id'],'params':{..._0x543cd7,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'segmentId':''}};}if(!_0x527630[_0x41054b(0x223)](_0x23449c[_0x41054b(0x204)]['id'],_0x23449c['resourceRedo'][_0x41054b(0x168)]))return Oe(_0x527630,_0x1d5217),J(_0x527630,_0x3257f1[_0x41054b(0x1d0)],_0x2e9577),!0x1;_0x380127=!0x0,Ee(_0x3257f1,_0x23449c,_0x1d5217,_0x5f5515);}catch(_0x4e3e8a){throw _0x380127&&_0x527630['syncExecuteCommand'](_0x23449c[_0x41054b(0x201)]['id'],_0x23449c[_0x41054b(0x201)][_0x41054b(0x168)]),Oe(_0x527630,_0x1d5217),J(_0x527630,_0x3257f1[_0x41054b(0x1d0)],_0x2e9577),_0x4e3e8a;}return _0x4981a0[_0x41054b(0x1cd)]([{'startOffset':_0x3257f1[_0x41054b(0x24a)],'endOffset':_0x3257f1[_0x41054b(0x24a)],'segmentId':''}],{'unitId':_0x3257f1['unitId'],'subUnitId':_0x3257f1[_0x41054b(0x229)]},!0x1,{[n[_0x41054b(0x1a4)]]:!0x0}),!0x0;}function De(_0x2ba4d8,_0x3d9a72,_0x211732,_0x2497e5,_0x3e18c5,_0x463f59){const _0x2cc5ce=_0x4b9f04;let _0x3394ea=ke(_0x211732,_0x2497e5,(0x0,t[_0x2cc5ce(0x268)])(_0x2ba4d8,''));return _0x3394ea?{'id':n[_0x2cc5ce(0x147)]['id'],'params':{'unitId':_0x3d9a72,'actions':_0x3394ea,'segmentId':'','textRanges':[{'startOffset':_0x3e18c5,'endOffset':_0x3e18c5,'collapsed':!0x0,'segmentId':''}],'isEditing':!0x1,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'trigger':_0x463f59}}:null;}function Oe(_0x181aa2,_0x506c87){const _0x41b728=_0x4b9f04;_0x506c87&&_0x181aa2[_0x41b728(0x223)](_0x506c87['id'],_0x506c87[_0x41b728(0x168)]);}function J(_0x240026,_0x55ca6f,_0x490bb0){const _0x104ed1=_0x4b9f04;_0x490bb0&&_0x55ca6f[_0x104ed1(0x1a5)]&&_0x240026[_0x104ed1(0x223)](_0x55ca6f[_0x104ed1(0x1a5)]['id'],_0x55ca6f[_0x104ed1(0x1a5)][_0x104ed1(0x168)]);}function ke(_0x37407c,_0x157632,_0x1622bb){const _0x498c0f=_0x4b9f04;let _0x579a24=_0x37407c['body'],_0x5da5d1=_0x157632[_0x498c0f(0x182)],_0x47c72a=Ae(_0x579a24==null?void 0x0:_0x579a24[_0x498c0f(0x275)],_0x5da5d1==null?void 0x0:_0x5da5d1[_0x498c0f(0x275)]);if(!_0x47c72a||!_0x5da5d1)return null;let _0x5f51f0=new t[(_0x498c0f(0x15b))]();return _0x5f51f0['retain'](_0x47c72a[_0x498c0f(0x1dc)]),_0x47c72a[_0x498c0f(0x19b)]>0x0&&_0x5f51f0[_0x498c0f(0x1d2)](_0x47c72a[_0x498c0f(0x19b)],(0x0,t[_0x498c0f(0x1b9)])(_0x5da5d1,_0x47c72a[_0x498c0f(0x1dc)],_0x47c72a[_0x498c0f(0x1dc)]+_0x47c72a[_0x498c0f(0x19b)],!0x1)),_0x47c72a['deleteLength']>0x0&&_0x5f51f0[_0x498c0f(0x163)](_0x47c72a['deleteLength']),t[_0x498c0f(0x1e8)][_0x498c0f(0x162)]()[_0x498c0f(0x172)](_0x5f51f0[_0x498c0f(0x20e)](),_0x1622bb);}function Ae(_0x83ed2e,_0x198a02){const _0x2810c4=_0x4b9f04;if(_0x83ed2e==null||_0x198a02==null||_0x83ed2e===_0x198a02)return null;let _0x13569f=0x0;for(;_0x13569f<_0x83ed2e[_0x2810c4(0x16a)]&&_0x13569f<_0x198a02[_0x2810c4(0x16a)]&&_0x83ed2e[_0x13569f]===_0x198a02[_0x13569f];)_0x13569f+=0x1;let _0x3f0f08=_0x83ed2e[_0x2810c4(0x16a)],_0x59bf98=_0x198a02['length'];for(;_0x3f0f08>_0x13569f&&_0x59bf98>_0x13569f&&_0x83ed2e[_0x3f0f08-0x1]===_0x198a02[_0x59bf98-0x1];)--_0x3f0f08,--_0x59bf98;return{'start':_0x13569f,'deleteLength':_0x3f0f08-_0x13569f,'insertLength':_0x59bf98-_0x13569f};}function je(_0xf05c8c){const _0x14cedd=_0x4b9f04;return{'formulas':Object[_0x14cedd(0x1db)](Object[_0x14cedd(0x194)](_0xf05c8c[_0x14cedd(0x15c)])['map'](([_0x348761,_0x55417e])=>[_0x348761,{..._0x55417e,..._0x55417e[_0x14cedd(0x240)]?{'numberFormat':{..._0x55417e[_0x14cedd(0x240)]}}:null,..._0x55417e[_0x14cedd(0x209)]?{'lastValue':{..._0x55417e[_0x14cedd(0x209)]}}:null}]))};}let Y=class extends t['Disposable']{constructor(_0x4aaaae,_0x4b2cf9,_0x13a365,_0x9a9485){const _0x273298=_0x4b9f04;super(),this[_0x273298(0x20b)]=_0x4aaaae,this[_0x273298(0x27a)]=_0x4b2cf9,this[_0x273298(0x262)]=_0x13a365,this[_0x273298(0x26f)]=_0x9a9485,D(this,_0x273298(0x1ad),new Set()),D(this,_0x273298(0x190),!0x1),D(this,'_isDisposed',!0x1),this[_0x273298(0x20b)][_0x273298(0x25b)](t['UniverInstanceType']['UNIVER_DOC'])['forEach'](_0x16651b=>this[_0x273298(0x26f)][_0x273298(0x264)](_0x16651b)),this[_0x273298(0x260)](this[_0x273298(0x262)][_0x273298(0x1e5)][_0x273298(0x1fc)](({unitId:_0x11245c})=>this[_0x273298(0x1d9)](_0x11245c))),this[_0x273298(0x260)](this[_0x273298(0x20b)][_0x273298(0x179)]['subscribe'](({unit:_0x52203a})=>{const _0x19c2fc=_0x273298;_0x52203a[_0x19c2fc(0x1f2)]===t[_0x19c2fc(0x1b6)][_0x19c2fc(0x1ba)]&&this['_queueSync'](_0x52203a['getUnitId']());})),this[_0x273298(0x260)](this[_0x273298(0x20b)]['unitDisposed$'][_0x273298(0x1fc)](_0x5d4a28=>{const _0x459f06=_0x273298;this[_0x459f06(0x26f)][_0x459f06(0x189)](_0x5d4a28[_0x459f06(0x1df)]());})),this[_0x273298(0x260)](this[_0x273298(0x27a)][_0x273298(0x272)](_0x184d3b=>{const _0x349101=_0x273298;if(_0x184d3b['id']===n[_0x349101(0x147)]['id']&&Me(_0x184d3b[_0x349101(0x168)])){let _0x28029d=_0x184d3b['params'];_0x28029d[_0x349101(0x17c)]||this[_0x349101(0x1d9)](_0x28029d['unitId']);}}));}['dispose'](){const _0x2fde1d=_0x4b9f04;this[_0x2fde1d(0x185)]=!0x0,super[_0x2fde1d(0x19d)]();}[_0x4b9f04(0x253)](_0x7ceffa){const _0x169979=_0x4b9f04;this[_0x169979(0x1ad)][_0x169979(0x232)](_0x7ceffa),this[_0x169979(0x190)]||(this['_syncScheduled']=!0x0,queueMicrotask(()=>{const _0x1a3651=_0x169979;if(this['_syncScheduled']=!0x1,this[_0x1a3651(0x185)])return;let _0x9b9ab0=Array[_0x1a3651(0x1e7)](this[_0x1a3651(0x1ad)]);this['_pendingUnitIds'][_0x1a3651(0x1e1)](),_0x9b9ab0['forEach'](_0x3d9787=>this['_syncUnit'](_0x3d9787));}));}[_0x4b9f04(0x1d9)](_0x4cf32e){const _0x2d6662=_0x4b9f04;let _0x18533d=this[_0x2d6662(0x20b)]['getUnit'](_0x4cf32e,t['UniverInstanceType'][_0x2d6662(0x1ba)]);_0x18533d&&this['_service']['syncUnit'](_0x18533d);}};Y=A([k(0x0,t['IUniverInstanceService']),k(0x1,t[_0x4b9f04(0x1e4)]),k(0x2,(0x0,t[_0x4b9f04(0x187)])(O)),k(0x3,(0x0,t[_0x4b9f04(0x187)])(j))],Y);function Me(_0x552ca8){const _0x4a21ff=_0x4b9f04;return typeof _0x552ca8=='object'&&!!_0x552ca8&&'unitId'in _0x552ca8&&typeof _0x552ca8[_0x4a21ff(0x229)]==_0x4a21ff(0x1c9)&&(!(_0x4a21ff(0x17c)in _0x552ca8)||_0x552ca8['segmentId']===void 0x0||typeof _0x552ca8['segmentId']==_0x4a21ff(0x1c9));}let X=class extends t[_0x4b9f04(0x252)]{constructor(_0x5787b0,_0x4a8541){const _0x1b83c6=_0x4b9f04;super(),this[_0x1b83c6(0x22f)]=_0x5787b0,this[_0x1b83c6(0x1f6)]=_0x4a8541,this['disposeWithMe'](this['_resourceManagerService'][_0x1b83c6(0x278)]({'pluginName':o,'businesses':[t[_0x1b83c6(0x1b6)]['UNIVER_DOC']],'toJson':_0x2a48dc=>JSON[_0x1b83c6(0x151)](this[_0x1b83c6(0x1f6)][_0x1b83c6(0x20e)](_0x2a48dc)),'parseJson':_0x32daf9=>JSON[_0x1b83c6(0x235)](_0x32daf9),'onLoad':(_0x18cc18,_0x509a18)=>{const _0x1f1b07=_0x1b83c6;this[_0x1f1b07(0x1f6)]['load'](_0x18cc18,_0x509a18);},'onUnLoad':_0x44129c=>this[_0x1b83c6(0x1f6)]['removeUnit'](_0x44129c)}));}};X=A([k(0x0,t[_0x4b9f04(0x1fb)]),k(0x1,(0x0,t[_0x4b9f04(0x187)])(O))],X);var Ne=_0x4b9f04(0x21d),Pe='1.5.0';const Fe={};let Z=class extends t[_0x4b9f04(0x252)]{constructor(_0x3283e0,_0x483ea3,_0x533a81){const _0x19b68b=_0x4b9f04;super(),this[_0x19b68b(0x1fd)]=_0x3283e0,this['_formulaService']=_0x483ea3,this[_0x19b68b(0x260)](_0x533a81[_0x19b68b(0x247)]({'resolve':(_0x594e4a,_0x24f7d5)=>{const _0x5ad52a=_0x19b68b;var _0xcfaff8;return((_0xcfaff8=_0x24f7d5[_0x5ad52a(0x18d)])==null?void 0x0:_0xcfaff8[_0x5ad52a(0x1c3)](g)[_0x5ad52a(0x210)](_0x59dcfa=>({'startOffset':_0x59dcfa[_0x5ad52a(0x1be)],'endOffset':_0x59dcfa['endIndex']+0x1,'text':this[_0x5ad52a(0x1da)](_0x594e4a,_0x59dcfa[_0x5ad52a(0x25f)])})))??[];}})),this[_0x19b68b(0x260)](this[_0x19b68b(0x228)]['presentationChanged$'][_0x19b68b(0x1fc)](({unitId:_0x87fc6f})=>{const _0xfca772=_0x19b68b;_0x533a81[_0xfca772(0x18a)](_0x87fc6f);}));}[_0x4b9f04(0x1da)](_0x797a40,_0xdd9698){const _0x2e775e=_0x4b9f04;var _0x40a0b6;return((_0x40a0b6=this[_0x2e775e(0x228)]['getResult']({'unitId':_0x797a40,'rangeId':_0xdd9698}))==null?void 0x0:_0x40a0b6['text'])??'';}['resolveText'](_0x1023d0,_0x25aa65,_0x5df1cd){const _0x18e9b9=_0x4b9f04;var _0x4788cb;let _0x572dc8=this[_0x18e9b9(0x1fd)][_0x18e9b9(0x1d6)](_0x1023d0,t[_0x18e9b9(0x1b6)][_0x18e9b9(0x1ba)]),_0x44237a=_0x572dc8==null?void 0x0:_0x572dc8[_0x18e9b9(0x157)]();if(!_0x44237a)return'';let _0x4d8742=_0x44237a[_0x18e9b9(0x275)][_0x18e9b9(0x153)](_0x25aa65,_0x5df1cd),_0x159df6=((_0x4788cb=_0x44237a[_0x18e9b9(0x18d)])==null?void 0x0:_0x4788cb['filter'](_0x7318e5=>g(_0x7318e5)&&_0x7318e5[_0x18e9b9(0x1be)]>=_0x25aa65&&_0x7318e5[_0x18e9b9(0x181)]<_0x5df1cd)['sort']((_0x3cc9ce,_0x4e9436)=>_0x4e9436[_0x18e9b9(0x1be)]-_0x3cc9ce['startIndex']))??[];for(let _0x41b042 of _0x159df6){let _0x1ff12b=_0x41b042['startIndex']-_0x25aa65,_0x574d69=_0x41b042['endIndex']-_0x25aa65+0x1;_0x4d8742=''+_0x4d8742[_0x18e9b9(0x153)](0x0,_0x1ff12b)+this[_0x18e9b9(0x1da)](_0x1023d0,_0x41b042[_0x18e9b9(0x25f)])+_0x4d8742[_0x18e9b9(0x153)](_0x574d69);}return _0x4d8742;}[_0x4b9f04(0x17b)](_0x5eb1bc){return Ie(_0x5eb1bc);}['degradeBody'](_0x2d0ace,_0x5983f2,_0x12aec3={}){const _0x128f4=_0x4b9f04;var _0x2dca89;return re({'id':_0x2d0ace,'body':_0x5983f2,'documentStyle':{}},(((_0x2dca89=_0x5983f2[_0x128f4(0x18d)])==null?void 0x0:_0x2dca89[_0x128f4(0x1c3)](g))??[])['map'](_0x64ad21=>({'rangeId':_0x64ad21[_0x128f4(0x25f)],'text':_0x12aec3[_0x64ad21['rangeId']]??this[_0x128f4(0x1da)](_0x2d0ace,_0x64ad21['rangeId'])})))[_0x128f4(0x182)]??{'dataStream':''};}};Z=A([k(0x0,t[_0x4b9f04(0x237)]),k(0x1,(0x0,t[_0x4b9f04(0x187)])(j)),k(0x2,(0x0,t['Inject'])(n[_0x4b9f04(0x1c2)]))],Z);function Ie(_0x49f761){const _0x108de7=_0x4b9f04;var _0x29accb,_0x122542;let _0x1bca3e=Le(_0x49f761),_0x20f767=re(_0x49f761,(((_0x29accb=_0x49f761['body'])==null||(_0x29accb=_0x29accb[_0x108de7(0x18d)])==null?void 0x0:_0x29accb['filter'](g))??[])['map'](_0x54e06c=>({'rangeId':_0x54e06c['rangeId'],'text':Re(_0x1bca3e==null?void 0x0:_0x1bca3e['formulas'][_0x54e06c['rangeId']])})));return _0x20f767['resources']=(_0x122542=_0x20f767[_0x108de7(0x25a)])==null?void 0x0:_0x122542['filter'](_0x27d1a1=>_0x27d1a1['name']!==o),_0x20f767;}function Le(_0x1e0a90){const _0xca178c=_0x4b9f04;var _0x39c91e;let _0x3aa704=(_0x39c91e=_0x1e0a90[_0xca178c(0x25a)])==null||(_0x39c91e=_0x39c91e[_0xca178c(0x227)](_0x54a97a=>_0x54a97a[_0xca178c(0x152)]===_0xca178c(0x1f5)))==null?void 0x0:_0x39c91e['data'];if(_0x3aa704)try{let _0x9db9d1=JSON['parse'](_0x3aa704);return l(_0x9db9d1)?_0x9db9d1:void 0x0;}catch{return;}}function Re(_0x1b0a5d){const _0x3032e1=_0x4b9f04;return _0x1b0a5d?(0x0,e[_0x3032e1(0x15d)])({'lastValue':_0x1b0a5d[_0x3032e1(0x209)],'numberFormat':_0x1b0a5d[_0x3032e1(0x240)]})[_0x3032e1(0x186)]:'';}let Q=class extends t[_0x4b9f04(0x252)]{constructor(_0x4623dd,_0xeb2919,_0x988872){const _0x32d3eb=_0x4b9f04;super(),this[_0x32d3eb(0x228)]=_0x4623dd,this['_cacheEligibilityService']=_0xeb2919,this['disposeWithMe'](_0x988872[_0x32d3eb(0x20a)](this));}['collectMutations'](_0x2ac4b1){const _0x5e31cb=_0x4b9f04;let _0x2f0a3b=new Map();for(let _0x196809 of this['_formulaService'][_0x5e31cb(0x19a)]()){var _0x76607;if(!this['_cacheEligibilityService'][_0x5e31cb(0x177)](_0x196809[_0x5e31cb(0x26e)][_0x5e31cb(0x1bd)],_0x196809[_0x5e31cb(0x267)])[_0x5e31cb(0x23f)])continue;let _0x243b6c=(0x0,e[_0x5e31cb(0x14a)])(_0x196809[_0x5e31cb(0x267)]),_0x5db64f=_0x243b6c?(0x0,e['toFormulaLastValue'])(_0x243b6c):null;if(!_0x5db64f||ze(_0x196809['config'][_0x5e31cb(0x209)],_0x5db64f))continue;let _0x30e403=_0x2f0a3b[_0x5e31cb(0x1a2)](_0x196809[_0x5e31cb(0x1e0)][_0x5e31cb(0x229)])??[];_0x30e403[_0x5e31cb(0x217)]({'rangeId':_0x196809[_0x5e31cb(0x1e0)][_0x5e31cb(0x25f)],'expectedFormula':_0x196809[_0x5e31cb(0x26e)][_0x5e31cb(0x1bd)],'expectedNumberFormat':(_0x76607=_0x196809[_0x5e31cb(0x26e)][_0x5e31cb(0x240)])==null?void 0x0:_0x76607[_0x5e31cb(0x1a0)],'expectedReferenceRevision':_0x196809['referenceRevision'],'lastValue':_0x5db64f}),_0x2f0a3b[_0x5e31cb(0x22c)](_0x196809[_0x5e31cb(0x1e0)][_0x5e31cb(0x229)],_0x30e403);}return Array[_0x5e31cb(0x1e7)](_0x2f0a3b,([_0x4edf0b,_0xd52c29])=>({'id':R['id'],'params':{'unitId':_0x4edf0b,'updates':_0xd52c29}}));}};Q=A([k(0x0,(0x0,t[_0x4b9f04(0x187)])(j)),k(0x1,(0x0,t[_0x4b9f04(0x187)])(e[_0x4b9f04(0x26b)])),k(0x2,(0x0,t[_0x4b9f04(0x187)])(e[_0x4b9f04(0x14d)]))],Q);function ze(_0x3f071a,_0x58aa8f){const _0x3f4dbf=_0x4b9f04;return(_0x3f071a==null?void 0x0:_0x3f071a['v'])===_0x58aa8f['v']&&(_0x3f071a==null?void 0x0:_0x3f071a['t'])===_0x58aa8f['t']&&(_0x3f071a==null?void 0x0:_0x3f071a[_0x3f4dbf(0x1a0)])===_0x58aa8f[_0x3f4dbf(0x1a0)];}let $=class extends t[_0x4b9f04(0x16f)]{constructor(_0x2de2e3=Fe,_0x5b435d,_0x24cc5a,_0xfdf2bb){const _0x28f03b=_0x4b9f04;super(),this['_config']=_0x2de2e3,this[_0x28f03b(0x1c0)]=_0x5b435d,this[_0x28f03b(0x27a)]=_0x24cc5a,this[_0x28f03b(0x255)]=_0xfdf2bb;let {..._0xaaa20a}=(0x0,t[_0x28f03b(0x1a7)])({},Fe,this[_0x28f03b(0x246)]);this[_0x28f03b(0x255)][_0x28f03b(0x184)]('docs-formula.config',_0xaaa20a);}[_0x4b9f04(0x269)](){const _0x4544b1=_0x4b9f04;this['_injector']['add']([O]),this[_0x4544b1(0x1c0)]['add']([j]),this[_0x4544b1(0x1c0)][_0x4544b1(0x232)]([X]),this['_injector'][_0x4544b1(0x232)]([Y]),this['_injector']['add']([Q]),this[_0x4544b1(0x1c0)]['add']([Z]),(0x0,t['touchDependencies'])(this[_0x4544b1(0x1c0)],[[O],[X],[Y],[Q],[Z]]),[F,I,L,R,z,B,V,H,U,W][_0x4544b1(0x21f)](_0x4a7751=>this[_0x4544b1(0x260)](this[_0x4544b1(0x27a)]['registerCommand'](_0x4a7751)));}};D($,'pluginName',o),D($,_0x4b9f04(0x203),Ne),D($,'version',Pe),D($,_0x4b9f04(0x1f2),t[_0x4b9f04(0x1b6)][_0x4b9f04(0x1ba)]),$=A([(0x0,t[_0x4b9f04(0x218)])(a[_0x4b9f04(0x19c)],e[_0x4b9f04(0x256)],n[_0x4b9f04(0x1fe)]),k(0x1,(0x0,t[_0x4b9f04(0x187)])(t[_0x4b9f04(0x14e)])),k(0x2,t[_0x4b9f04(0x1e4)]),k(0x3,t['IConfigService'])],$),exports['ConvertDocFormulaToTextCommand']=W,exports[_0x4b9f04(0x22a)]=s,exports[_0x4b9f04(0x15f)]='',exports['DOC_FORMULA_PLUGIN']=o,Object[_0x4b9f04(0x1a1)](exports,_0x4b9f04(0x261),{'enumerable':!0x0,'get':function(){return Z;}}),Object['defineProperty'](exports,_0x4b9f04(0x1d7),{'enumerable':!0x0,'get':function(){return Y;}}),exports['DocFormulaModel']=O,Object[_0x4b9f04(0x1a1)](exports,'DocFormulaResourceController',{'enumerable':!0x0,'get':function(){return X;}}),exports['DocFormulaResultStatus']=ve,Object[_0x4b9f04(0x1a1)](exports,'DocFormulaService',{'enumerable':!0x0,'get':function(){return j;}}),exports[_0x4b9f04(0x245)]=z,exports[_0x4b9f04(0x26d)]=m,exports[_0x4b9f04(0x18e)]=H,exports[_0x4b9f04(0x233)]=I,exports[_0x4b9f04(0x195)]=U,exports[_0x4b9f04(0x17a)]=R,exports[_0x4b9f04(0x24d)]=F,exports[_0x4b9f04(0x1ee)]=V,exports['SetDocFormulaResourceMutation']=L,Object['defineProperty'](exports,_0x4b9f04(0x16e),{'enumerable':!0x0,'get':function(){return $;}}),exports[_0x4b9f04(0x254)]=B,exports[_0x4b9f04(0x221)]=ie,exports[_0x4b9f04(0x222)]=te,exports[_0x4b9f04(0x1cc)]=h,exports['buildUpdateDocFormulaActions']=ne,exports['createEmptyDocFormulaResource']=c,exports[_0x4b9f04(0x20f)]=Ie,exports[_0x4b9f04(0x258)]=_,exports['isDocFormulaConfig']=u,exports['isDocFormulaRange']=g,exports['isDocFormulaResource']=l,exports['isFormulaLastValue']=d;
|
|
1
|
+
const _0x324a21=_0x3d5d;(function(_0x5ba6a1,_0x31c6d1){const _0x30625f=_0x3d5d,_0x16e40d=_0x5ba6a1();while(!![]){try{const _0x3485ca=parseInt(_0x30625f(0x1e1))/0x1+parseInt(_0x30625f(0x14d))/0x2*(-parseInt(_0x30625f(0x16d))/0x3)+parseInt(_0x30625f(0x15a))/0x4*(-parseInt(_0x30625f(0x226))/0x5)+parseInt(_0x30625f(0x231))/0x6+-parseInt(_0x30625f(0x185))/0x7*(parseInt(_0x30625f(0x18e))/0x8)+parseInt(_0x30625f(0x256))/0x9+parseInt(_0x30625f(0x246))/0xa;if(_0x3485ca===_0x31c6d1)break;else _0x16e40d['push'](_0x16e40d['shift']());}catch(_0x1ecc5a){_0x16e40d['push'](_0x16e40d['shift']());}}}(_0x4b6d,0x9c17d),Object['defineProperty'](exports,Symbol[_0x324a21(0x22f)],{'value':'Module'}));let e=require('@univerjs-pro/engine-formula'),t=require('@univerjs/core'),n=require('@univerjs/docs'),r=require('@univerjs/engine-formula'),i=require('rxjs'),a=require('@univerjs-pro/license');const o=_0x324a21(0x189),s=_0x324a21(0x16e);function c(){return{'formulas':{}};}function l(_0x2e167d){const _0xf8218d=_0x324a21;return!_0x2e167d||typeof _0x2e167d!=_0xf8218d(0x1f3)||!(_0xf8218d(0x172)in _0x2e167d)||!_0x2e167d['formulas']||typeof _0x2e167d[_0xf8218d(0x172)]!=_0xf8218d(0x1f3)||Array[_0xf8218d(0x197)](_0x2e167d[_0xf8218d(0x172)])?!0x1:Object[_0xf8218d(0x1dc)](_0x2e167d[_0xf8218d(0x172)])[_0xf8218d(0x1e3)](([_0x2a4b71,_0x55e737])=>_0x2a4b71[_0xf8218d(0x1b2)]>0x0&&u(_0x55e737));}function u(_0x5ebaa0){const _0x4e8a9a=_0x324a21;return!_0x5ebaa0||typeof _0x5ebaa0!=_0x4e8a9a(0x1f3)||!f(_0x5ebaa0,[_0x4e8a9a(0x192),'numberFormat',_0x4e8a9a(0x1f0)])||!('formula'in _0x5ebaa0)||typeof _0x5ebaa0['formula']!='string'||!_0x5ebaa0['formula'][_0x4e8a9a(0x13f)]()||'numberFormat'in _0x5ebaa0&&_0x5ebaa0[_0x4e8a9a(0x16b)]!=null&&(typeof _0x5ebaa0[_0x4e8a9a(0x16b)]!=_0x4e8a9a(0x1f3)||!f(_0x5ebaa0[_0x4e8a9a(0x16b)],[_0x4e8a9a(0x220)])||!(_0x4e8a9a(0x220)in _0x5ebaa0[_0x4e8a9a(0x16b)])||typeof _0x5ebaa0['numberFormat'][_0x4e8a9a(0x220)]!='string')?!0x1:!(_0x4e8a9a(0x1f0)in _0x5ebaa0)||_0x5ebaa0[_0x4e8a9a(0x1f0)]==null||d(_0x5ebaa0['lastValue']);}function d(_0x18244a){const _0x2e2713=_0x324a21;return!_0x18244a||typeof _0x18244a!=_0x2e2713(0x1f3)||!f(_0x18244a,['v','t',_0x2e2713(0x220)])||!('v'in _0x18244a)||_0x18244a['v']!==null&&typeof _0x18244a['v']!=_0x2e2713(0x175)&&typeof _0x18244a['v']!=_0x2e2713(0x130)&&typeof _0x18244a['v']!=_0x2e2713(0x1f4)||'t'in _0x18244a&&_0x18244a['t']!=null&&!ee(_0x18244a['t'])?!0x1:!('pattern'in _0x18244a)||_0x18244a['pattern']==null||typeof _0x18244a['pattern']==_0x2e2713(0x175);}function f(_0x255e26,_0x5b72fe){const _0x88f59b=_0x324a21;let _0x27977a=new Set(_0x5b72fe);return Object[_0x88f59b(0x16f)](_0x255e26)[_0x88f59b(0x1e3)](_0x36bf78=>_0x27977a['has'](_0x36bf78));}function ee(_0x4fd625){const _0xb20dfd=_0x324a21;return typeof _0x4fd625==_0xb20dfd(0x130)&&Object['values'](t['CellValueType'])[_0xb20dfd(0x143)](_0x4fd625);}const p=new Set([t[_0x324a21(0x21b)][_0x324a21(0x235)],t[_0x324a21(0x21b)][_0x324a21(0x16c)],t['DataStreamTreeTokenType'][_0x324a21(0x168)],t[_0x324a21(0x21b)][_0x324a21(0x1d5)],t[_0x324a21(0x21b)][_0x324a21(0x242)],t[_0x324a21(0x21b)]['TABLE_ROW_END'],t[_0x324a21(0x21b)]['TABLE_END'],t['DataStreamTreeTokenType'][_0x324a21(0x258)],t[_0x324a21(0x21b)]['COLUMN_START'],t[_0x324a21(0x21b)]['COLUMN_END'],t['DataStreamTreeTokenType']['COLUMN_GROUP_END'],t[_0x324a21(0x21b)][_0x324a21(0x208)],t[_0x324a21(0x21b)]['BLOCK_END'],t['DataStreamTreeTokenType']['CUSTOM_BLOCK']]);var m=class extends Error{constructor(){const _0x2eea5a=_0x324a21;super(_0x2eea5a(0x1a9));}};function te(_0xdeb0e){const _0x42cb53=_0x324a21;var _0x288187,_0x672744;let _0x11fdf4=t[_0x42cb53(0x158)][_0x42cb53(0x1db)](_0xdeb0e[_0x42cb53(0x200)]),_0x483978=T(_0x11fdf4),{startOffset:_0x1480aa,endOffset:_0x5dfcd6}=oe(_0x483978,_0xdeb0e[_0x42cb53(0x22d)],_0xdeb0e['endOffset']);ie(_0x483978,_0x1480aa,_0x5dfcd6);let _0x4f0709=((_0x288187=_0x483978[_0x42cb53(0x234)])==null?void 0x0:_0x288187[_0x42cb53(0x24b)](_0x1e9208=>{const _0x1bc03d=_0x42cb53;if(!g(_0x1e9208))return!0x1;let _0x4de243=(0x0,t[_0x1bc03d(0x174)])(_0x1e9208);return _0x4de243[_0x1bc03d(0x1d3)]>_0x1480aa&&_0x4de243[_0x1bc03d(0x22d)]<_0x5dfcd6;})[_0x42cb53(0x253)](_0x3f2949=>_0x3f2949[_0x42cb53(0x203)]))??[];ce(_0x483978,_0x1480aa,_0x5dfcd6,''),_0x483978[_0x42cb53(0x234)]=[...((_0x672744=_0x483978[_0x42cb53(0x234)])==null?void 0x0:_0x672744[_0x42cb53(0x24b)](_0x545eaa=>!_0x4f0709[_0x42cb53(0x143)](_0x545eaa[_0x42cb53(0x203)])&&_0x545eaa[_0x42cb53(0x203)]!==_0xdeb0e[_0x42cb53(0x203)]))??[],ae(_0xdeb0e[_0x42cb53(0x203)],_0x1480aa)][_0x42cb53(0x15e)]((_0x4f2dfe,_0x2a2cc6)=>_0x4f2dfe[_0x42cb53(0x190)]-_0x2a2cc6[_0x42cb53(0x190)]);let _0x432af0=v(_0xdeb0e[_0x42cb53(0x176)]);return _0x4f0709[_0x42cb53(0x169)](_0x69d7a8=>{const _0x32dffc=_0x42cb53;delete _0x432af0[_0x32dffc(0x172)][_0x69d7a8];}),_0x432af0[_0x42cb53(0x172)][_0xdeb0e['rangeId']]=t[_0x42cb53(0x158)][_0x42cb53(0x1db)](_0xdeb0e['config']),{'nextDocumentData':_0x11fdf4,'nextResource':_0x432af0,'cursorOffset':_0x1480aa+0x1};}function ne(_0x3a7124){const _0x507b9b=_0x324a21;var _0x1b6217,_0x15af80;let _0x502502=t[_0x507b9b(0x158)]['deepClone'](_0x3a7124['documentData']),_0x3f1b27=(_0x1b6217=T(_0x502502)['customRanges'])==null?void 0x0:_0x1b6217['find'](_0x126d56=>_0x126d56[_0x507b9b(0x203)]===_0x3a7124[_0x507b9b(0x203)]&&g(_0x126d56));if(!_0x3f1b27||!((_0x15af80=_0x3a7124[_0x507b9b(0x176)])!=null&&_0x15af80[_0x507b9b(0x172)][_0x3a7124[_0x507b9b(0x203)]]))return null;let _0x58138=v(_0x3a7124[_0x507b9b(0x176)]);return _0x58138[_0x507b9b(0x172)][_0x3a7124['rangeId']]=t[_0x507b9b(0x158)][_0x507b9b(0x1db)](_0x3a7124[_0x507b9b(0x15b)]),{'nextDocumentData':_0x502502,'nextResource':_0x58138,'cursorOffset':_0x3f1b27[_0x507b9b(0x1f2)]+0x1};}function h(_0x3dcfdd){const _0x3a6a65=_0x324a21;let _0x4b7f52=t[_0x3a6a65(0x158)][_0x3a6a65(0x1db)](_0x3dcfdd['documentData']),_0xc1504c=le(_0x4b7f52,_0x3dcfdd[_0x3a6a65(0x203)],_0x3dcfdd[_0x3a6a65(0x1de)]??'');if(_0xc1504c==null)return null;let _0x3dcc56=v(_0x3dcfdd[_0x3a6a65(0x176)]);return delete _0x3dcc56['formulas'][_0x3dcfdd[_0x3a6a65(0x203)]],{'nextDocumentData':_0x4b7f52,'nextResource':_0x3dcc56,'cursorOffset':_0xc1504c};}function re(_0x16d8d7,_0x231b56){const _0x500769=_0x324a21;var _0x5cd619;let _0x39122d=t[_0x500769(0x158)]['deepClone'](_0x16d8d7),_0x3161b0=_0x39122d[_0x500769(0x1cb)];if(!_0x3161b0)return _0x39122d;let _0x13589d=new Map(_0x231b56[_0x500769(0x253)](_0x437257=>[_0x437257[_0x500769(0x203)],_0x437257[_0x500769(0x1de)]])),_0x5efe7e=((_0x5cd619=_0x3161b0[_0x500769(0x234)])==null?void 0x0:_0x5cd619[_0x500769(0x24b)](_0x5bbfd6=>g(_0x5bbfd6)&&_0x13589d[_0x500769(0x132)](_0x5bbfd6['rangeId']))['sort']((_0x560ea7,_0x1a6e93)=>_0x1a6e93[_0x500769(0x190)]-_0x560ea7[_0x500769(0x190)]))??[];for(let _0x5c86ea of _0x5efe7e)le(_0x39122d,_0x5c86ea[_0x500769(0x203)],_0x13589d[_0x500769(0x239)](_0x5c86ea[_0x500769(0x203)])??'');return _0x39122d;}function g(_0x296353){const _0x2ecc09=_0x324a21;var _0x47428f;return(_0x296353==null?void 0x0:_0x296353[_0x2ecc09(0x22a)])===t['CustomRangeType'][_0x2ecc09(0x18b)]&&_0x296353[_0x2ecc09(0x171)]===!0x0&&((_0x47428f=_0x296353['properties'])==null?void 0x0:_0x47428f[_0x2ecc09(0x233)])===_0x2ecc09(0x16e);}function _(_0x24eaef,_0xe1f73){const _0x1e79ff=_0x324a21;var _0x268385;return _0x24eaef==null||(_0x268385=_0x24eaef[_0x1e79ff(0x234)])==null?void 0x0:_0x268385[_0x1e79ff(0x25c)](_0x1f0536=>_0x1f0536[_0x1e79ff(0x203)]===_0xe1f73&&g(_0x1f0536));}function ie(_0x3d5d3a,_0x5b6b6a,_0x552946){const _0x58d96f=_0x324a21;if(_0x5b6b6a===_0x552946){if(p['has'](_0x3d5d3a[_0x58d96f(0x247)][_0x5b6b6a]))throw new m();}else{for(let _0x190a75=_0x5b6b6a;_0x190a75<_0x552946;_0x190a75++)if(_0x3d5d3a['dataStream'][_0x190a75]===t[_0x58d96f(0x21b)]['PARAGRAPH']||p[_0x58d96f(0x132)](_0x3d5d3a[_0x58d96f(0x247)][_0x190a75]))throw new m();}}function ae(_0x5ac1e2,_0x499f4a){const _0xb3f0ad=_0x324a21;return{'startIndex':_0x499f4a,'endIndex':_0x499f4a,'rangeId':_0x5ac1e2,'rangeType':t[_0xb3f0ad(0x1d4)][_0xb3f0ad(0x18b)],'wholeEntity':!0x0,'properties':{'kind':s}};}function v(_0x5c00d5){const _0x4029dc=_0x324a21;return _0x5c00d5?t[_0x4029dc(0x158)][_0x4029dc(0x1db)](_0x5c00d5):c();}function oe(_0x12ca80,_0x1ec317,_0x3f1a81){const _0x42f6cd=_0x324a21;let _0x4e11c9=se(_0x12ca80),_0xe7c7c6=_0x1ec317??_0x4e11c9,_0x43d500=_0x3f1a81??_0xe7c7c6;return{'startOffset':y(Math['min'](_0xe7c7c6,_0x43d500),_0x4e11c9),'endOffset':y(Math[_0x42f6cd(0x15c)](_0xe7c7c6,_0x43d500),_0x4e11c9)};}function y(_0xdb7dbe,_0x22d87f){const _0x2ace4a=_0x324a21;return Math[_0x2ace4a(0x15c)](0x0,Math[_0x2ace4a(0x17d)](_0xdb7dbe,_0x22d87f));}function se(_0x1369b5){const _0xa254e5=_0x324a21;return _0x1369b5[_0xa254e5(0x247)]['endsWith'](''+t[_0xa254e5(0x21b)][_0xa254e5(0x205)]+t[_0xa254e5(0x21b)][_0xa254e5(0x235)])?Math[_0xa254e5(0x15c)](0x0,_0x1369b5[_0xa254e5(0x247)][_0xa254e5(0x1b2)]-0x2):_0x1369b5['dataStream'][_0xa254e5(0x23a)](t[_0xa254e5(0x21b)][_0xa254e5(0x235)])?Math['max'](0x0,_0x1369b5['dataStream'][_0xa254e5(0x1b2)]-0x1):_0x1369b5[_0xa254e5(0x247)]['length'];}function ce(_0x47f408,_0x3e11cb,_0xf15308,_0x1b168c){_0xf15308>_0x3e11cb&&de(_0x47f408,_0x3e11cb,_0xf15308),ue(_0x47f408,_0x3e11cb,_0x1b168c);}function le(_0x3da358,_0xb7f826,_0x485b69){const _0x4e0ad6=_0x324a21;var _0x43e4bc,_0x1d4e28;let _0x3536ef=T(_0x3da358),_0x3e57be=(_0x43e4bc=_0x3536ef[_0x4e0ad6(0x234)])==null?void 0x0:_0x43e4bc[_0x4e0ad6(0x25c)](_0x22aa6c=>_0x22aa6c['rangeId']===_0xb7f826&&g(_0x22aa6c));if(!_0x3e57be)return null;let _0x897b89=(0x0,t['getCustomRangeInterval'])(_0x3e57be);return ce(_0x3536ef,_0x897b89[_0x4e0ad6(0x22d)],_0x897b89[_0x4e0ad6(0x1d3)],_0x485b69),_0x3536ef[_0x4e0ad6(0x234)]=(_0x1d4e28=_0x3536ef[_0x4e0ad6(0x234)])==null?void 0x0:_0x1d4e28[_0x4e0ad6(0x24b)](_0x5ad5c0=>_0x5ad5c0[_0x4e0ad6(0x203)]!==_0xb7f826),_0x897b89[_0x4e0ad6(0x22d)]+_0x485b69[_0x4e0ad6(0x1b2)];}function ue(_0x39ea90,_0x176f46,_0x8f5d09){const _0x5344d2=_0x324a21;_0x8f5d09&&(_0x39ea90[_0x5344d2(0x247)]=''+_0x39ea90['dataStream']['slice'](0x0,_0x176f46)+_0x8f5d09+_0x39ea90[_0x5344d2(0x247)][_0x5344d2(0x209)](_0x176f46),fe(_0x39ea90,_0x176f46,_0x8f5d09[_0x5344d2(0x1b2)]));}function de(_0x313fc2,_0x4fadee,_0x2a5f88){const _0x4a40db=_0x324a21;let _0x4081d1=_0x2a5f88-_0x4fadee;_0x313fc2[_0x4a40db(0x247)]=''+_0x313fc2[_0x4a40db(0x247)][_0x4a40db(0x209)](0x0,_0x4fadee)+_0x313fc2[_0x4a40db(0x247)][_0x4a40db(0x209)](_0x2a5f88),pe(_0x313fc2,_0x4fadee,_0x4081d1);}function fe(_0x58dcf1,_0x134fe0,_0x295be1){const _0x517a55=_0x324a21;_0x58dcf1[_0x517a55(0x188)]=b(_0x58dcf1[_0x517a55(0x188)],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x198)]=b(_0x58dcf1[_0x517a55(0x198)],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x254)]=b(_0x58dcf1[_0x517a55(0x254)],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x1d2)]=me(_0x58dcf1[_0x517a55(0x1d2)],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x22c)]=he(_0x58dcf1[_0x517a55(0x22c)],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x14f)]=S(_0x58dcf1['columnGroups'],_0x134fe0,_0x295be1),_0x58dcf1['customRanges']=S(_0x58dcf1[_0x517a55(0x234)],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x18c)]=S(_0x58dcf1['customDecorations'],_0x134fe0,_0x295be1),_0x58dcf1[_0x517a55(0x1c9)]=S(_0x58dcf1['blockRanges'],_0x134fe0,_0x295be1);}function pe(_0x5e8fd5,_0x134662,_0x3d2004){const _0x34e200=_0x324a21;var _0x5d6b0a,_0xe5c93d;_0x5e8fd5[_0x34e200(0x188)]=x(_0x5e8fd5[_0x34e200(0x188)],_0x134662,_0x3d2004),_0x5e8fd5['sectionBreaks']=x(_0x5e8fd5[_0x34e200(0x198)],_0x134662,_0x3d2004),_0x5e8fd5[_0x34e200(0x254)]=x(_0x5e8fd5['customBlocks'],_0x134662,_0x3d2004),_0x5e8fd5['textRuns']=(_0x5d6b0a=w((_0xe5c93d=_0x5e8fd5[_0x34e200(0x1d2)])==null?void 0x0:_0xe5c93d['map'](_0x15f2c2=>({..._0x15f2c2,'startIndex':_0x15f2c2['st'],'endIndex':_0x15f2c2['ed']})),_0x134662,_0x3d2004))==null?void 0x0:_0x5d6b0a['map'](_0x10c8ea=>{let {startIndex:_0x56e3e9,endIndex:_0x3306c5,..._0x9a7b05}=_0x10c8ea;return{..._0x9a7b05,'st':_0x56e3e9,'ed':_0x3306c5};}),_0x5e8fd5[_0x34e200(0x22c)]=w(_0x5e8fd5[_0x34e200(0x22c)],_0x134662,_0x3d2004),_0x5e8fd5[_0x34e200(0x14f)]=C(_0x5e8fd5[_0x34e200(0x14f)],_0x134662,_0x3d2004),_0x5e8fd5[_0x34e200(0x234)]=C(_0x5e8fd5['customRanges'],_0x134662,_0x3d2004),_0x5e8fd5['customDecorations']=C(_0x5e8fd5['customDecorations'],_0x134662,_0x3d2004),_0x5e8fd5['blockRanges']=C(_0x5e8fd5[_0x34e200(0x1c9)],_0x134662,_0x3d2004);}function b(_0x50f98f,_0x385d73,_0x24c98e){const _0x4e4b1e=_0x324a21;return _0x50f98f==null?void 0x0:_0x50f98f[_0x4e4b1e(0x253)](_0x281a3c=>_0x281a3c['startIndex']>=_0x385d73?{..._0x281a3c,'startIndex':_0x281a3c['startIndex']+_0x24c98e}:_0x281a3c);}function x(_0x4c2ee2,_0x4e2f86,_0xe5f373){const _0x46cfb0=_0x324a21;let _0x188b3b=_0x4e2f86+_0xe5f373;return _0x4c2ee2==null?void 0x0:_0x4c2ee2['map'](_0x288620=>_0x288620['startIndex']>=_0x4e2f86&&_0x288620[_0x46cfb0(0x190)]<_0x188b3b?null:_0x288620[_0x46cfb0(0x190)]>=_0x188b3b?{..._0x288620,'startIndex':_0x288620[_0x46cfb0(0x190)]-_0xe5f373}:_0x288620)[_0x46cfb0(0x24b)](_0x41d2c7=>_0x41d2c7!=null);}function me(_0x8afe8c,_0x30a025,_0x2785c9){const _0x285352=_0x324a21;return _0x8afe8c==null?void 0x0:_0x8afe8c[_0x285352(0x253)](_0x988f1c=>_0x988f1c['st']>=_0x30a025?{..._0x988f1c,'st':_0x988f1c['st']+_0x2785c9,'ed':_0x988f1c['ed']+_0x2785c9}:_0x988f1c['ed']>_0x30a025?{..._0x988f1c,'ed':_0x988f1c['ed']+_0x2785c9}:_0x988f1c);}function S(_0x46a1c1,_0x303c45,_0x1c8f3e){const _0x766023=_0x324a21;return _0x46a1c1==null?void 0x0:_0x46a1c1[_0x766023(0x253)](_0x42ede1=>(0x0,t[_0x766023(0x223)])(_0x42ede1,_0x303c45,_0x1c8f3e));}function he(_0x47d0d4,_0xe03475,_0x3111f5){const _0x112115=_0x324a21;return _0x47d0d4==null?void 0x0:_0x47d0d4[_0x112115(0x253)](_0x19e131=>(0x0,t['shiftExclusiveRangeOnInsert'])(_0x19e131,_0xe03475,_0x3111f5));}function _0x3d5d(_0x65ade6,_0x2af80f){_0x65ade6=_0x65ade6-0x129;const _0x4b6d04=_0x4b6d();let _0x3d5d38=_0x4b6d04[_0x65ade6];return _0x3d5d38;}function C(_0x2bb81c,_0x5c1f25,_0x4693c0){const _0x14a91f=_0x324a21;return _0x2bb81c==null?void 0x0:_0x2bb81c[_0x14a91f(0x253)](_0xb0e9ef=>(0x0,t[_0x14a91f(0x1a3)])(_0xb0e9ef,_0x5c1f25,_0x4693c0))[_0x14a91f(0x24b)](_0x303d85=>_0x303d85!=null);}function w(_0x24cf3a,_0x8ee356,_0x55c638){const _0x3bb177=_0x324a21;return _0x24cf3a==null?void 0x0:_0x24cf3a['map'](_0x490e8a=>(0x0,t[_0x3bb177(0x170)])(_0x490e8a,_0x8ee356,_0x55c638))[_0x3bb177(0x24b)](_0xa44e3b=>_0xa44e3b!=null);}function T(_0x2037f7){const _0x593d9a=_0x324a21;if(!_0x2037f7[_0x593d9a(0x1cb)])throw Error(_0x593d9a(0x1da));return _0x2037f7[_0x593d9a(0x1cb)];}function E(_0x3ce2b7){'@babel/helpers - typeof';const _0x35b880=_0x324a21;return E=typeof Symbol==_0x35b880(0x215)&&typeof Symbol[_0x35b880(0x1ac)]==_0x35b880(0x1df)?function(_0x1afe85){return typeof _0x1afe85;}:function(_0x296b75){const _0x3f1bb7=_0x35b880;return _0x296b75&&typeof Symbol==_0x3f1bb7(0x215)&&_0x296b75['constructor']===Symbol&&_0x296b75!==Symbol[_0x3f1bb7(0x13d)]?_0x3f1bb7(0x1df):typeof _0x296b75;},E(_0x3ce2b7);}function ge(_0x33cbc5,_0x42505f){const _0x16cdb1=_0x324a21;if(E(_0x33cbc5)!=_0x16cdb1(0x1f3)||!_0x33cbc5)return _0x33cbc5;var _0x149202;if(typeof Symbol<'u'&&(_0x149202=_0x33cbc5[Symbol[_0x16cdb1(0x13c)]])!==void 0x0){var _0xd7ff33=_0x149202[_0x16cdb1(0x1bf)](_0x33cbc5,_0x42505f||_0x16cdb1(0x1f7));if(E(_0xd7ff33)!=_0x16cdb1(0x1f3))return _0xd7ff33;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x42505f===_0x16cdb1(0x175)?String:Number)(_0x33cbc5);}function _e(_0x2f1c41){const _0x2cb71e=_0x324a21;var _0x2dbe7e=ge(_0x2f1c41,_0x2cb71e(0x175));return E(_0x2dbe7e)==_0x2cb71e(0x1df)?_0x2dbe7e:_0x2dbe7e+'';}function D(_0x138028,_0xd4e9f9,_0x460df5){const _0x2f6bcf=_0x324a21;return(_0xd4e9f9=_e(_0xd4e9f9))in _0x138028?Object[_0x2f6bcf(0x1ea)](_0x138028,_0xd4e9f9,{'value':_0x460df5,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x138028[_0xd4e9f9]=_0x460df5,_0x138028;}var O=class extends t[_0x324a21(0x136)]{constructor(..._0x392305){const _0x1f698b=_0x324a21;super(..._0x392305),D(this,_0x1f698b(0x1d8),new Map()),D(this,_0x1f698b(0x13b),new Map()),D(this,'_loadErrors',new Map()),D(this,_0x1f698b(0x160),new i[(_0x1f698b(0x17b))]()),D(this,_0x1f698b(0x25b),this['_change$']['asObservable']());}[_0x324a21(0x1e7)](_0x5c0ffb,_0x191cdb){const _0x1ff018=_0x324a21;var _0x3f31d3;let _0xfde9a6=(_0x3f31d3=this['_resources'][_0x1ff018(0x239)](_0x5c0ffb))==null?void 0x0:_0x3f31d3[_0x1ff018(0x172)][_0x191cdb];return _0xfde9a6?t[_0x1ff018(0x158)]['deepClone'](_0xfde9a6):void 0x0;}[_0x324a21(0x1bd)](_0x13bdb5){const _0x306dfb=_0x324a21;var _0x56351e;return t[_0x306dfb(0x158)][_0x306dfb(0x1db)](((_0x56351e=this[_0x306dfb(0x1d8)][_0x306dfb(0x239)](_0x13bdb5))==null?void 0x0:_0x56351e[_0x306dfb(0x172)])??{});}[_0x324a21(0x21a)](_0x2f2c04){const _0x2147ed=_0x324a21;let _0x33ba29=this['_resources'][_0x2147ed(0x239)](_0x2f2c04);return _0x33ba29?t[_0x2147ed(0x158)][_0x2147ed(0x1db)](_0x33ba29):void 0x0;}['setFormula'](_0x2d7043,_0x4f745d,_0x7538da){const _0xc6c36d=_0x324a21;return this[_0xc6c36d(0x238)](_0x2d7043,{[_0x4f745d]:_0x7538da});}['setResource'](_0x14b949,_0x5ef467){const _0x150471=_0x324a21;return this[_0x150471(0x230)][_0x150471(0x132)](_0x14b949)||!l(_0x5ef467)?!0x1:(this[_0x150471(0x1d8)][_0x150471(0x1b7)](_0x14b949,{'formulas':t['Tools'][_0x150471(0x1db)](_0x5ef467[_0x150471(0x172)])}),this[_0x150471(0x160)][_0x150471(0x1bb)]({'unitId':_0x14b949}),!0x0);}[_0x324a21(0x238)](_0x1ced3e,_0x18df9b){const _0xbb0e75=_0x324a21;if(this[_0xbb0e75(0x230)][_0xbb0e75(0x132)](_0x1ced3e)||!Object[_0xbb0e75(0x16f)](_0x18df9b)[_0xbb0e75(0x1b2)]||!l({'formulas':_0x18df9b}))return!0x1;let _0x1e9fe6=this[_0xbb0e75(0x1d8)][_0xbb0e75(0x239)](_0x1ced3e)??c(),_0x14bd9f=t['Tools'][_0xbb0e75(0x1db)](_0x1e9fe6);return Object[_0xbb0e75(0x15f)](_0x14bd9f[_0xbb0e75(0x172)],t[_0xbb0e75(0x158)]['deepClone'](_0x18df9b)),this['_resources'][_0xbb0e75(0x1b7)](_0x1ced3e,_0x14bd9f),this[_0xbb0e75(0x160)][_0xbb0e75(0x1bb)]({'unitId':_0x1ced3e,'rangeIds':Object[_0xbb0e75(0x16f)](_0x18df9b)}),!0x0;}['removeFormula'](_0x463f4a,_0x5ab6c3){const _0x2c8c06=_0x324a21;if(this[_0x2c8c06(0x230)][_0x2c8c06(0x132)](_0x463f4a))return!0x1;let _0x38908a=this['_resources']['get'](_0x463f4a);if(!(_0x38908a!=null&&_0x38908a[_0x2c8c06(0x172)][_0x5ab6c3]))return!0x1;let _0x3ff2e6=t[_0x2c8c06(0x158)][_0x2c8c06(0x1db)](_0x38908a);return delete _0x3ff2e6[_0x2c8c06(0x172)][_0x5ab6c3],this[_0x2c8c06(0x1d8)][_0x2c8c06(0x1b7)](_0x463f4a,_0x3ff2e6),this[_0x2c8c06(0x160)][_0x2c8c06(0x1bb)]({'unitId':_0x463f4a,'rangeIds':[_0x5ab6c3]}),!0x0;}[_0x324a21(0x1ee)](_0x5bbf8,_0x21d75a){const _0x254ae9=_0x324a21;return l(_0x21d75a)?(this[_0x254ae9(0x1d8)][_0x254ae9(0x1b7)](_0x5bbf8,{'formulas':t['Tools'][_0x254ae9(0x1db)](_0x21d75a[_0x254ae9(0x172)])}),this[_0x254ae9(0x13b)][_0x254ae9(0x1ef)](_0x5bbf8),this[_0x254ae9(0x230)][_0x254ae9(0x1ef)](_0x5bbf8),this[_0x254ae9(0x160)]['next']({'unitId':_0x5bbf8}),!0x0):(this[_0x254ae9(0x259)](_0x5bbf8,_0x21d75a,_0x254ae9(0x14e)),!0x1);}[_0x324a21(0x12f)](_0x518743){const _0x30446a=_0x324a21;let _0xe34040=this[_0x30446a(0x1d8)][_0x30446a(0x239)](_0x518743);return _0xe34040?t[_0x30446a(0x158)][_0x30446a(0x1db)](_0xe34040):this[_0x30446a(0x13b)][_0x30446a(0x132)](_0x518743)?t[_0x30446a(0x158)]['deepClone'](this[_0x30446a(0x13b)][_0x30446a(0x239)](_0x518743)):c();}[_0x324a21(0x141)](_0x1d2ace){const _0x3e05f6=_0x324a21;return this[_0x3e05f6(0x230)][_0x3e05f6(0x239)](_0x1d2ace);}[_0x324a21(0x1d0)](_0x3ec96c){const _0xddaf4c=_0x324a21;this['_resources'][_0xddaf4c(0x1ef)](_0x3ec96c),this[_0xddaf4c(0x13b)][_0xddaf4c(0x1ef)](_0x3ec96c),this['_loadErrors'][_0xddaf4c(0x1ef)](_0x3ec96c),this[_0xddaf4c(0x160)][_0xddaf4c(0x1bb)]({'unitId':_0x3ec96c});}[_0x324a21(0x207)](){const _0x5467a6=_0x324a21;this[_0x5467a6(0x1d8)]['clear'](),this[_0x5467a6(0x13b)][_0x5467a6(0x20e)](),this[_0x5467a6(0x230)][_0x5467a6(0x20e)](),this['_change$'][_0x5467a6(0x1c7)](),super[_0x5467a6(0x207)]();}[_0x324a21(0x259)](_0x4b4883,_0x39dbf5,_0xfc9687){const _0xcb2b78=_0x324a21;this[_0xcb2b78(0x1d8)][_0xcb2b78(0x1ef)](_0x4b4883),this[_0xcb2b78(0x13b)][_0xcb2b78(0x1b7)](_0x4b4883,t[_0xcb2b78(0x158)][_0xcb2b78(0x1db)](_0x39dbf5)),this[_0xcb2b78(0x230)][_0xcb2b78(0x1b7)](_0x4b4883,_0xfc9687),this[_0xcb2b78(0x160)][_0xcb2b78(0x1bb)]({'unitId':_0x4b4883});}};let ve=function(_0xa2abac){const _0x19272a=_0x324a21;return _0xa2abac[_0x19272a(0x1ff)]=_0x19272a(0x24e),_0xa2abac[_0x19272a(0x12e)]=_0x19272a(0x228),_0xa2abac[_0x19272a(0x12b)]=_0x19272a(0x1fb),_0xa2abac[_0x19272a(0x1cf)]=_0x19272a(0x191),_0xa2abac;}({});function k(_0x5a2bf2,_0x57066e){return function(_0x4a7083,_0x14be1b){_0x57066e(_0x4a7083,_0x14be1b,_0x5a2bf2);};}function A(_0x378833,_0x5dfb00,_0x3f4f74,_0x2831de){const _0x2e8701=_0x324a21;var _0x3ce97e=arguments['length'],_0xe5c4b2=_0x3ce97e<0x3?_0x5dfb00:_0x2831de===null?_0x2831de=Object[_0x2e8701(0x155)](_0x5dfb00,_0x3f4f74):_0x2831de,_0x521669;if(typeof Reflect==_0x2e8701(0x1f3)&&typeof Reflect[_0x2e8701(0x236)]==_0x2e8701(0x215))_0xe5c4b2=Reflect[_0x2e8701(0x236)](_0x378833,_0x5dfb00,_0x3f4f74,_0x2831de);else{for(var _0x5f0a7c=_0x378833[_0x2e8701(0x1b2)]-0x1;_0x5f0a7c>=0x0;_0x5f0a7c--)(_0x521669=_0x378833[_0x5f0a7c])&&(_0xe5c4b2=(_0x3ce97e<0x3?_0x521669(_0xe5c4b2):_0x3ce97e>0x3?_0x521669(_0x5dfb00,_0x3f4f74,_0xe5c4b2):_0x521669(_0x5dfb00,_0x3f4f74))||_0xe5c4b2);}return _0x3ce97e>0x3&&_0xe5c4b2&&Object['defineProperty'](_0x5dfb00,_0x3f4f74,_0xe5c4b2),_0xe5c4b2;}let j=class extends t[_0x324a21(0x136)]{constructor(_0x1edb4f,_0x1036ef,_0x1abc90){const _0x26b80b=_0x324a21;super(),this[_0x26b80b(0x19d)]=_0x1edb4f,this[_0x26b80b(0x219)]=_0x1036ef,this[_0x26b80b(0x16a)]=_0x1abc90,D(this,_0x26b80b(0x1e2),new Map()),D(this,'_formulaKeys',new Map()),D(this,_0x26b80b(0x150),new i['Subject']()),D(this,_0x26b80b(0x153),this['_presentationChanged$']['asObservable']()),this['disposeWithMe'](this[_0x26b80b(0x219)]['formulaResult$'][_0x26b80b(0x19b)](_0x4e8fe8=>{const _0x5e117a=_0x26b80b;for(let _0x4bd241 of Object[_0x5e117a(0x1d6)](_0x4e8fe8))for(let _0x154c2b of Object[_0x5e117a(0x1d6)](_0x4bd241))_0x154c2b['forEach'](_0x22e15b=>this['_updateFormulaResult'](_0x22e15b));}));}[_0x324a21(0x152)](_0x3c65d0){const _0x521632=_0x324a21;var _0x994994;let _0xbc371c=_0x3c65d0[_0x521632(0x1a6)](),_0x1bb2c6=((_0x994994=_0x3c65d0[_0x521632(0x1b1)]()[_0x521632(0x1cb)])==null||(_0x994994=_0x994994[_0x521632(0x234)])==null?void 0x0:_0x994994[_0x521632(0x24b)](g))??[],_0x4dc1ad=this[_0x521632(0x19d)][_0x521632(0x1bd)](_0xbc371c),_0x5759f3=new Set();for(let _0x3602e7 of _0x1bb2c6){let _0x9dce8c=_0x4dc1ad[_0x3602e7['rangeId']];_0x9dce8c&&(_0x5759f3[_0x521632(0x237)](M(_0xbc371c,_0x3602e7[_0x521632(0x203)])),this[_0x521632(0x211)]({'unitId':_0xbc371c,'rangeId':_0x3602e7['rangeId']},_0x9dce8c));}for(let _0x31201f of Array[_0x521632(0x24c)](this['_registrations']['values']()))_0x31201f[_0x521632(0x23c)]===_0xbc371c&&!_0x5759f3['has'](M(_0x31201f['unitId'],_0x31201f[_0x521632(0x203)]))&&this[_0x521632(0x17c)](_0x31201f);}[_0x324a21(0x211)](_0x195085,_0x3a228a){const _0x4ed102=_0x324a21;let _0x1f02ce=M(_0x195085['unitId'],_0x195085[_0x4ed102(0x203)]),_0x4201b3=this[_0x4ed102(0x1e2)][_0x4ed102(0x239)](_0x1f02ce),_0x58eb6a=this[_0x4ed102(0x16a)][_0x4ed102(0x196)](_0x195085['unitId']);if(_0x4201b3&&_0x4201b3[_0x4ed102(0x15b)][_0x4ed102(0x192)]===_0x3a228a[_0x4ed102(0x192)]&&_0x4201b3[_0x4ed102(0x229)]===_0x58eb6a){_0x4201b3[_0x4ed102(0x15b)]=_0x3a228a;let _0xf08102=_0x4201b3['formulaId']?this[_0x4ed102(0x219)][_0x4ed102(0x138)](_0x4201b3[_0x4ed102(0x23c)],_0x4201b3[_0x4ed102(0x23c)],_0x4201b3[_0x4ed102(0x1e9)])??void 0x0:void 0x0;_0x4201b3[_0x4ed102(0x202)]=_0xf08102,this['_setPresentation'](_0x1f02ce,N(_0x3a228a,_0xf08102));return;}_0x4201b3!=null&&_0x4201b3[_0x4ed102(0x1e9)]&&this['_deleteRegistration'](_0x4201b3);let _0x56542d={..._0x195085,'config':_0x3a228a,'referenceRevision':_0x58eb6a,'presentation':N(_0x3a228a,void 0x0)};if(this[_0x4ed102(0x1e2)][_0x4ed102(0x1b7)](_0x1f02ce,_0x56542d),!_0x3a228a[_0x4ed102(0x192)][_0x4ed102(0x13f)]())return;let _0x1a9a68=this[_0x4ed102(0x219)]['registerFormulaWithRange'](_0x195085['unitId'],_0x195085[_0x4ed102(0x23c)],_0x3a228a[_0x4ed102(0x192)],void 0x0,{'rangeId':_0x195085[_0x4ed102(0x203)]},r[_0x4ed102(0x1e6)][_0x4ed102(0x21f)],_0x195085[_0x4ed102(0x203)]);_0x56542d[_0x4ed102(0x1e9)]=_0x1a9a68,this[_0x4ed102(0x183)][_0x4ed102(0x1b7)](_0x1a9a68,_0x1f02ce);}['unregister'](_0x22f9ea){const _0x4e6469=_0x324a21;let _0x44e000=M(_0x22f9ea[_0x4e6469(0x23c)],_0x22f9ea['rangeId']),_0x463d63=this[_0x4e6469(0x1e2)][_0x4e6469(0x239)](_0x44e000);_0x463d63&&(this[_0x4e6469(0x163)](_0x463d63),this['_registrations']['delete'](_0x44e000));}[_0x324a21(0x20f)](_0x489852){const _0x5699b2=_0x324a21;for(let _0x193f50 of Array['from'](this[_0x5699b2(0x1e2)][_0x5699b2(0x1d6)]()))_0x193f50['unitId']===_0x489852&&this['unregister'](_0x193f50);}[_0x324a21(0x1bc)](_0x12ef48){const _0x32aa79=_0x324a21;var _0x21e0ed;return(_0x21e0ed=this[_0x32aa79(0x1e2)][_0x32aa79(0x239)](M(_0x12ef48['unitId'],_0x12ef48[_0x32aa79(0x203)])))==null?void 0x0:_0x21e0ed[_0x32aa79(0x1c0)];}['getResult'](_0x528014){const _0x3ba098=_0x324a21;let _0x3d6db8=this['_registrations'][_0x3ba098(0x239)](M(_0x528014[_0x3ba098(0x23c)],_0x528014[_0x3ba098(0x203)]));return _0x3d6db8?P(_0x3d6db8):void 0x0;}[_0x324a21(0x161)](){const _0x45b06c=_0x324a21;return Array[_0x45b06c(0x24c)](this[_0x45b06c(0x1e2)][_0x45b06c(0x1d6)](),_0xeda0f8=>({'identity':{'unitId':_0xeda0f8[_0x45b06c(0x23c)],'rangeId':_0xeda0f8[_0x45b06c(0x203)]},'config':_0xeda0f8['config'],'referenceRevision':_0xeda0f8[_0x45b06c(0x229)],..._0xeda0f8['liveResult']?{'liveResult':_0xeda0f8[_0x45b06c(0x202)]}:null}));}[_0x324a21(0x207)](){const _0x4df891=_0x324a21;for(let _0x3909d4 of this[_0x4df891(0x1e2)][_0x4df891(0x1d6)]())this[_0x4df891(0x163)](_0x3909d4);this[_0x4df891(0x1e2)]['clear'](),this[_0x4df891(0x183)][_0x4df891(0x20e)](),this[_0x4df891(0x150)][_0x4df891(0x1c7)](),super[_0x4df891(0x207)]();}['_updateFormulaResult'](_0x1ac82c){const _0x17150b=_0x324a21;let _0xb54f3e=this[_0x17150b(0x183)][_0x17150b(0x239)](_0x1ac82c[_0x17150b(0x1e9)]),_0xd51501=_0xb54f3e?this[_0x17150b(0x1e2)][_0x17150b(0x239)](_0xb54f3e):void 0x0;_0xb54f3e&&_0xd51501&&(_0xd51501[_0x17150b(0x202)]=_0x1ac82c,this[_0x17150b(0x144)](_0xb54f3e,N(_0xd51501[_0x17150b(0x15b)],_0x1ac82c)));}['_setPresentation'](_0x58754b,_0x420f12){const _0x27949d=_0x324a21;var _0x49434e,_0x3314e5;let _0x208d86=this['_registrations'][_0x27949d(0x239)](_0x58754b);if(!_0x208d86||ye(_0x208d86[_0x27949d(0x1c0)],_0x420f12))return;let _0x1d1ab2=_0x208d86['presentation'],_0x53312d=P(_0x208d86);_0x208d86[_0x27949d(0x1c0)]=_0x420f12,this[_0x27949d(0x150)][_0x27949d(0x1bb)]({'unitId':_0x208d86[_0x27949d(0x23c)],'rangeId':_0x208d86[_0x27949d(0x203)],'presentation':_0x420f12,'previousPresentation':_0x1d1ab2,'result':P(_0x208d86),'previousResult':{..._0x53312d,..._0x1d1ab2,'value':(_0x49434e=_0x1d1ab2[_0x27949d(0x182)])==null?void 0x0:_0x49434e['v'],'valueType':((_0x3314e5=_0x1d1ab2[_0x27949d(0x182)])==null?void 0x0:_0x3314e5['t'])??void 0x0}});}[_0x324a21(0x163)](_0x14ef1b){const _0x2e2e3f=_0x324a21;_0x14ef1b[_0x2e2e3f(0x1e9)]&&(this[_0x2e2e3f(0x219)][_0x2e2e3f(0x1fd)](_0x14ef1b[_0x2e2e3f(0x23c)],_0x14ef1b[_0x2e2e3f(0x23c)],[_0x14ef1b[_0x2e2e3f(0x1e9)]]),this[_0x2e2e3f(0x183)][_0x2e2e3f(0x1ef)](_0x14ef1b['formulaId']));}};j=A([k(0x0,(0x0,t[_0x324a21(0x1ca)])(O)),k(0x1,(0x0,t['Inject'])(r[_0x324a21(0x241)])),k(0x2,(0x0,t['Inject'])(e[_0x324a21(0x212)]))],j);function M(_0x1c9ef3,_0x540cdd){return _0x1c9ef3+'\x00'+_0x540cdd;}function N(_0xab82e8,_0x4aa9c1){const _0x15afd6=_0x324a21;return(0x0,e[_0x15afd6(0x17e)])({'numberFormat':_0xab82e8['numberFormat'],'lastValue':_0xab82e8['lastValue'],'result':_0x4aa9c1});}function P(_0x52408b){const _0x4b2f63=_0x324a21;var _0xf5df18,_0x7efb6d,_0x51dfaf;let _0x42057e=_0x52408b[_0x4b2f63(0x1c0)],_0x25d3ba=_0x52408b[_0x4b2f63(0x15b)]['formula'][_0x4b2f63(0x13f)]()?_0x42057e[_0x4b2f63(0x135)]||_0x42057e[_0x4b2f63(0x182)]==null?_0x4b2f63(0x228):((_0xf5df18=_0x52408b[_0x4b2f63(0x202)])==null?void 0x0:_0xf5df18['status'])===r['FormulaResultStatus'][_0x4b2f63(0x1cf)]?_0x4b2f63(0x191):_0x4b2f63(0x1fb):_0x4b2f63(0x24e);return{..._0x42057e,'status':_0x25d3ba,'value':(_0x7efb6d=_0x42057e[_0x4b2f63(0x182)])==null?void 0x0:_0x7efb6d['v'],'valueType':((_0x51dfaf=_0x42057e[_0x4b2f63(0x182)])==null?void 0x0:_0x51dfaf['t'])??void 0x0};}function ye(_0x4e1599,_0x36ae10){const _0x32757c=_0x324a21;var _0x603325,_0x4d358b,_0x25cbb3,_0x2f2cd5;return _0x4e1599['text']===_0x36ae10[_0x32757c(0x1de)]&&_0x4e1599['color']===_0x36ae10['color']&&_0x4e1599['pattern']===_0x36ae10[_0x32757c(0x220)]&&_0x4e1599[_0x32757c(0x165)]===_0x36ae10[_0x32757c(0x165)]&&_0x4e1599[_0x32757c(0x135)]===_0x36ae10[_0x32757c(0x135)]&&((_0x603325=_0x4e1599['cell'])==null?void 0x0:_0x603325['t'])===((_0x4d358b=_0x36ae10[_0x32757c(0x182)])==null?void 0x0:_0x4d358b['t'])&&Object['is']((_0x25cbb3=_0x4e1599[_0x32757c(0x182)])==null?void 0x0:_0x25cbb3['v'],(_0x2f2cd5=_0x36ae10['cell'])==null?void 0x0:_0x2f2cd5['v']);}const F={'id':'docs-formula.mutation.set-formula','type':t[_0x324a21(0x1af)][_0x324a21(0x244)],'handler':(_0x2d3677,_0x487db2)=>!(_0x487db2!=null&&_0x487db2['unitId'])||!_0x487db2['rangeId']||!_0x487db2['config']?!0x1:_0x2d3677[_0x324a21(0x239)](O)[_0x324a21(0x20b)](_0x487db2['unitId'],_0x487db2[_0x324a21(0x203)],_0x487db2[_0x324a21(0x15b)])},I={'id':_0x324a21(0x13a),'type':t[_0x324a21(0x1af)][_0x324a21(0x244)],'handler':(_0x509dfa,_0x2e18c7)=>!(_0x2e18c7!=null&&_0x2e18c7[_0x324a21(0x23c)])||!_0x2e18c7[_0x324a21(0x203)]?!0x1:_0x509dfa[_0x324a21(0x239)](O)['removeFormula'](_0x2e18c7[_0x324a21(0x23c)],_0x2e18c7[_0x324a21(0x203)])},L={'id':_0x324a21(0x181),'type':t['CommandType'][_0x324a21(0x244)],'handler':(_0xadd8c7,_0x15542b)=>!(_0x15542b!=null&&_0x15542b['unitId'])||!_0x15542b[_0x324a21(0x176)]?!0x1:_0xadd8c7[_0x324a21(0x239)](O)[_0x324a21(0x186)](_0x15542b[_0x324a21(0x23c)],_0x15542b[_0x324a21(0x176)])},R={'id':_0x324a21(0x1ad),'type':t[_0x324a21(0x1af)][_0x324a21(0x244)],'handler':(_0x35e8df,_0x5eb625)=>{const _0x32e94b=_0x324a21;if(!(_0x5eb625!=null&&_0x5eb625[_0x32e94b(0x23c)])||!_0x5eb625[_0x32e94b(0x1ce)][_0x32e94b(0x1b2)])return!0x1;let _0x18e372=_0x35e8df['get'](O),_0x10e93c=_0x35e8df['get'](e[_0x32e94b(0x212)]),_0x2f7da6=_0x18e372[_0x32e94b(0x21a)](_0x5eb625[_0x32e94b(0x23c)]);if(!_0x2f7da6)return!0x1;let _0x2b4e09=t[_0x32e94b(0x158)]['deepClone'](_0x2f7da6),_0x13dbcd=!0x1;for(let _0x45dfea of _0x5eb625['updates']){var _0x12796c,_0x51744c,_0x3b78ed,_0x3ba7d3;let _0x25d5e1=_0x2b4e09[_0x32e94b(0x172)][_0x45dfea[_0x32e94b(0x203)]];_0x25d5e1&&_0x25d5e1[_0x32e94b(0x192)]===_0x45dfea[_0x32e94b(0x23b)]&&((_0x12796c=_0x25d5e1[_0x32e94b(0x16b)])==null?void 0x0:_0x12796c[_0x32e94b(0x220)])===_0x45dfea[_0x32e94b(0x25a)]&&_0x10e93c[_0x32e94b(0x196)](_0x5eb625['unitId'])===_0x45dfea['expectedReferenceRevision']&&(((_0x51744c=_0x25d5e1[_0x32e94b(0x1f0)])==null?void 0x0:_0x51744c['v'])!==_0x45dfea['lastValue']['v']||((_0x3b78ed=_0x25d5e1['lastValue'])==null?void 0x0:_0x3b78ed['t'])!==_0x45dfea[_0x32e94b(0x1f0)]['t']||((_0x3ba7d3=_0x25d5e1[_0x32e94b(0x1f0)])==null?void 0x0:_0x3ba7d3[_0x32e94b(0x220)])!==_0x45dfea[_0x32e94b(0x1f0)][_0x32e94b(0x220)])&&(_0x25d5e1[_0x32e94b(0x1f0)]=t[_0x32e94b(0x158)][_0x32e94b(0x1db)](_0x45dfea[_0x32e94b(0x1f0)]),_0x13dbcd=!0x0);}return!_0x13dbcd||_0x18e372[_0x32e94b(0x186)](_0x5eb625[_0x32e94b(0x23c)],_0x2b4e09);}},z={'id':_0x324a21(0x148),'type':t[_0x324a21(0x1af)][_0x324a21(0x23f)],'handler':(_0x12b36f,_0xd65c4b)=>{const _0x544e2b=_0x324a21;if(!(_0xd65c4b!=null&&_0xd65c4b[_0x544e2b(0x192)][_0x544e2b(0x13f)]()))return!0x1;let _0x423a8f=K(_0x12b36f,_0xd65c4b[_0x544e2b(0x23c)],'');if(!_0x423a8f)return!0x1;let _0x11620e=xe(_0xd65c4b[_0x544e2b(0x1eb)],_0x423a8f[_0x544e2b(0x1cb)],be(_0x12b36f,_0x423a8f[_0x544e2b(0x23c)]));if(!_0x11620e)return!0x1;let _0x106c11=Se(_0x12b36f,_0x423a8f[_0x544e2b(0x23c)],_0xd65c4b['formula'],_0xd65c4b[_0x544e2b(0x194)]??[]);if(!_0x106c11)return!0x1;let _0x597992=Ce(_0x423a8f[_0x544e2b(0x1cb)],_0x423a8f[_0x544e2b(0x149)],_0x423a8f[_0x544e2b(0x23c)]),_0x1ca7d9=we({'documentData':_0x423a8f[_0x544e2b(0x200)],'resource':_0x423a8f[_0x544e2b(0x176)],'rangeId':_0x597992,'config':{'formula':_0xd65c4b[_0x544e2b(0x192)],..._0xd65c4b['numberFormat']?{'numberFormat':_0xd65c4b['numberFormat']}:null},'startOffset':_0x11620e['startOffset'],'endOffset':_0x11620e[_0x544e2b(0x1d3)]});if(!_0x1ca7d9)return!0x1;let _0x59f444=(0x0,e[_0x544e2b(0x19e)])(_0x12b36f,_0x423a8f['unitId'],_0x106c11);return!_0x59f444||!q({'accessor':_0x12b36f,'document':_0x423a8f['document'],'unitId':_0x423a8f[_0x544e2b(0x23c)],'trigger':z['id'],'rangeId':_0x597992,'previousResource':_0x423a8f['resource'],'nextResource':_0x1ca7d9[_0x544e2b(0x1b6)],'previousDocumentData':_0x423a8f[_0x544e2b(0x200)],'nextDocumentData':_0x1ca7d9['nextDocumentData'],'cursorOffset':_0x1ca7d9[_0x544e2b(0x17a)],'externalMutations':_0x59f444})?!0x1:{'rangeId':_0x597992,'startOffset':_0x1ca7d9[_0x544e2b(0x17a)]-0x1,'endOffset':_0x1ca7d9['cursorOffset']};}},B={'id':'docs-formula.command.update','type':t[_0x324a21(0x1af)][_0x324a21(0x23f)],'handler':(_0x45a81a,_0x1bf174)=>{const _0x4bf0d2=_0x324a21;if(!(_0x1bf174!=null&&_0x1bf174[_0x4bf0d2(0x203)])||!_0x1bf174[_0x4bf0d2(0x192)][_0x4bf0d2(0x13f)]())return!0x1;let _0x58fc14=K(_0x45a81a,_0x1bf174[_0x4bf0d2(0x23c)],''),_0x4487ca=_0x58fc14==null?void 0x0:_0x58fc14[_0x4bf0d2(0x149)][_0x4bf0d2(0x1e7)](_0x58fc14[_0x4bf0d2(0x23c)],_0x1bf174[_0x4bf0d2(0x203)]),_0x502b61=_0x58fc14?_(_0x58fc14['documentData'][_0x4bf0d2(0x1cb)],_0x1bf174[_0x4bf0d2(0x203)]):void 0x0;if(!_0x58fc14||!_0x4487ca||!_0x502b61)return!0x1;let _0xa63ea3=Se(_0x45a81a,_0x58fc14[_0x4bf0d2(0x23c)],_0x1bf174['formula'],_0x1bf174[_0x4bf0d2(0x194)]??[]);if(!_0xa63ea3)return!0x1;let _0x4418e3=(0x0,e[_0x4bf0d2(0x19e)])(_0x45a81a,_0x58fc14[_0x4bf0d2(0x23c)],_0xa63ea3);if(!_0x4418e3)return!0x1;let _0x2da5fd=je(_0x58fc14['resource']);return _0x2da5fd[_0x4bf0d2(0x172)][_0x1bf174[_0x4bf0d2(0x203)]]={'formula':_0x1bf174[_0x4bf0d2(0x192)],..._0x1bf174[_0x4bf0d2(0x16b)]?{'numberFormat':_0x1bf174[_0x4bf0d2(0x16b)]}:_0x4487ca[_0x4bf0d2(0x16b)]?{'numberFormat':_0x4487ca[_0x4bf0d2(0x16b)]}:null},q({'accessor':_0x45a81a,'document':_0x58fc14[_0x4bf0d2(0x1c8)],'unitId':_0x58fc14[_0x4bf0d2(0x23c)],'trigger':B['id'],'rangeId':_0x1bf174[_0x4bf0d2(0x203)],'previousResource':_0x58fc14[_0x4bf0d2(0x176)],'nextResource':_0x2da5fd,'cursorOffset':_0x502b61[_0x4bf0d2(0x1f2)]+0x1,'externalMutations':_0x4418e3});}},V={'id':'docs-formula.command.set-number-format','type':t[_0x324a21(0x1af)]['COMMAND'],'handler':(_0x256bff,_0x1b3b92)=>{const _0x2848d9=_0x324a21;if(!(_0x1b3b92!=null&&_0x1b3b92[_0x2848d9(0x203)]))return!0x1;let _0x5d47d2=K(_0x256bff,_0x1b3b92['unitId'],''),_0x28f202=_0x5d47d2==null?void 0x0:_0x5d47d2[_0x2848d9(0x149)]['getFormula'](_0x5d47d2[_0x2848d9(0x23c)],_0x1b3b92['rangeId']),_0x5edbd3=_0x5d47d2?_(_0x5d47d2[_0x2848d9(0x200)][_0x2848d9(0x1cb)],_0x1b3b92[_0x2848d9(0x203)]):void 0x0;if(!_0x5d47d2||!_0x28f202||!_0x5edbd3)return!0x1;let _0x2709f1=je(_0x5d47d2['resource']);return _0x2709f1['formulas'][_0x1b3b92[_0x2848d9(0x203)]]={..._0x28f202,..._0x1b3b92[_0x2848d9(0x16b)]?{'numberFormat':_0x1b3b92[_0x2848d9(0x16b)]}:null},_0x1b3b92[_0x2848d9(0x16b)]||delete _0x2709f1['formulas'][_0x1b3b92[_0x2848d9(0x203)]][_0x2848d9(0x16b)],q({'accessor':_0x256bff,'document':_0x5d47d2[_0x2848d9(0x1c8)],'unitId':_0x5d47d2['unitId'],'trigger':V['id'],'rangeId':_0x1b3b92['rangeId'],'previousResource':_0x5d47d2[_0x2848d9(0x176)],'nextResource':_0x2709f1,'cursorOffset':_0x5edbd3[_0x2848d9(0x1f2)]+0x1,'externalMutations':{}});}},H={'id':_0x324a21(0x213),'type':t[_0x324a21(0x1af)][_0x324a21(0x23f)],'handler':(_0x511dc1,_0x82498f)=>G(_0x511dc1,_0x82498f,'',H['id'])},U={'id':_0x324a21(0x249),'type':t[_0x324a21(0x1af)][_0x324a21(0x23f)],'handler':(_0x1238cb,_0x398c40)=>G(_0x1238cb,_0x398c40,(_0x398c40==null?void 0x0:_0x398c40[_0x324a21(0x1de)])??'',U['id'])},W={'id':_0x324a21(0x1fa),'type':t[_0x324a21(0x1af)][_0x324a21(0x23f)],'handler':(_0x41a22f,_0x50dd8b)=>{const _0x7a9c9f=_0x324a21;if(!(_0x50dd8b!=null&&_0x50dd8b['rangeId']))return!0x1;let _0x285f1f=K(_0x41a22f,_0x50dd8b[_0x7a9c9f(0x23c)],'');if(!_0x285f1f)return!0x1;let _0x71f455=_0x41a22f[_0x7a9c9f(0x239)](j)['getResult']({'unitId':_0x285f1f[_0x7a9c9f(0x23c)],'rangeId':_0x50dd8b[_0x7a9c9f(0x203)]});return _0x71f455?G(_0x41a22f,_0x50dd8b,_0x71f455[_0x7a9c9f(0x1de)],W['id']):!0x1;}};function G(_0x2efaed,_0xe51ae9,_0x32eff4,_0x93e369){const _0xc88434=_0x324a21;if(!(_0xe51ae9!=null&&_0xe51ae9[_0xc88434(0x203)]))return!0x1;let _0x36f386=K(_0x2efaed,_0xe51ae9[_0xc88434(0x23c)],'');if(!_0x36f386)return!0x1;let _0x3720c7=h({'documentData':_0x36f386[_0xc88434(0x200)],'resource':_0x36f386[_0xc88434(0x176)],'rangeId':_0xe51ae9[_0xc88434(0x203)],'text':_0x32eff4});return _0x3720c7?q({'accessor':_0x2efaed,'document':_0x36f386[_0xc88434(0x1c8)],'unitId':_0x36f386['unitId'],'trigger':_0x93e369,'rangeId':_0xe51ae9[_0xc88434(0x203)],'previousResource':_0x36f386['resource'],'nextResource':_0x3720c7[_0xc88434(0x1b6)],'previousDocumentData':_0x36f386[_0xc88434(0x200)],'nextDocumentData':_0x3720c7[_0xc88434(0x1fe)],'cursorOffset':_0x3720c7[_0xc88434(0x17a)],'externalMutations':{}}):!0x1;}function K(_0x1ac87e,_0x3b088b,_0x19ed0e){const _0xea1790=_0x324a21;if(_0x19ed0e)return null;let _0x2ce4ac=_0x1ac87e[_0xea1790(0x239)](t[_0xea1790(0x1b4)]),_0x5c8c8f=(_0x3b088b?_0x2ce4ac[_0xea1790(0x24f)](_0x3b088b,t[_0xea1790(0x206)][_0xea1790(0x245)]):_0x2ce4ac[_0xea1790(0x1a2)](t[_0xea1790(0x206)][_0xea1790(0x245)]))??null;if(!_0x5c8c8f)return null;let _0xa2e016=_0x5c8c8f[_0xea1790(0x1b1)](),_0x5c47cb=_0xa2e016['body'];if(_0xa2e016[_0xea1790(0x1a4)]||!_0x5c47cb)return null;let _0x490a50=_0x1ac87e['get'](O);return _0x490a50[_0xea1790(0x141)](_0x5c8c8f[_0xea1790(0x1a6)]())?null:{'document':_0x5c8c8f,'body':_0x5c47cb,'documentData':_0xa2e016,'model':_0x490a50,'resource':_0x490a50[_0xea1790(0x21a)](_0x5c8c8f[_0xea1790(0x1a6)]())??c(),'unitId':_0x5c8c8f[_0xea1790(0x1a6)]()};}function _0x4b6d(){const _0x572864=['redoMutation','IUndoRedoService','_instanceService','complete','document','blockRanges','Inject','body','findDocFormulaRange','accessor','updates','ERROR','removeUnit','trigger','textRuns','endOffset','CustomRangeType','TABLE_CELL_START','values','_isDisposed','_resources','ReplaceDocFormulaWithTextCommand','Document\x20main\x20body\x20is\x20required\x20to\x20insert\x20Doc\x20Formula.','deepClone','entries','_pendingUnitIds','text','symbol','end','452886pmWNIq','_registrations','every','_formulaService','resources','OtherFormulaBizType','getFormula','_resourceManagerService','formulaId','defineProperty','target','TextX','_syncUnit','load','delete','lastValue','InsertDocFormulaCommand','endIndex','object','boolean','registerProvider','_queueSync','default','ConvertDocFormulaToTextCommand','data','docs-formula.command.convert-to-text','success','push','deleteFormula','nextDocumentData','EMPTY','documentData','DocFormulaModel','liveResult','rangeId','version','PARAGRAPH','UniverInstanceType','dispose','BLOCK_START','slice','DOC_SELECTION_OPTION_PRESERVE_CARET','setFormula','_service','params','clear','unregisterUnit','UniverDocsFormulaPlugin','register','HostExternalReferenceModel','docs-formula.command.remove','registerPluginResource','function','resolveFormula','resolveText','parse','_registrationService','getResource','DataStreamTreeTokenType','range','DocFormulaService','pushUndoRedo','DOC','pattern','getParagraphContentStartOffset','sequenceNodesBuilder','shiftInclusiveRangeOnInsert','ICommandService','setConfig','3436655YUeWyn','getInstance','pending','referenceRevision','rangeType','resourceUndo','tables','startOffset','buildRemoveDocFormulaActions','toStringTag','_loadErrors','5947416dxLTAa','paragraphId','kind','customRanges','SECTION_BREAK','decorate','add','setFormulas','get','endsWith','expectedFormula','unitId','UpdateDocFormulaCommand','Plugin','COMMAND','_configService','RegisterOtherFormulaService','TABLE_CELL_END','fromEntries','MUTATION','UNIVER_DOC','7958960BNXsln','dataStream','degradeDocumentData','docs-formula.command.replace-with-text','SetDocFormulaMutation','filter','from','collectFormulaExternalReferenceQualifiers','empty','getUnit','Injector','replaceDocRanges','resolveHostFormulaExternalReferences','map','customBlocks','position','2007918LEGCqa','SetDocFormulaNumberFormatCommand','COLUMN_GROUP_START','_preserveInvalid','expectedNumberFormat','change$','find','getBody','selection','SUCCESS','buildInsertDocFormulaActions','buildUpdateDocFormulaActions','PENDING','serialize','number','_docFormulaModel','has','merge','name','stale','Disposable','generateRandomId','getFormulaValueSync','insert','docs-formula.mutation.remove-formula','_rawResources','toPrimitive','prototype','editOp','trim','onCommandExecuted','getLoadError','_commandService','includes','_setPresentation','collectMutations','externalMutations','_univerInstanceService','docs-formula.command.insert','model','packageName','unitAdded$','identity','4onMQGl','invalid-resource','columnGroups','_presentationChanged$','RichTextEditingMutation','syncUnit','presentationChanged$','docs-formula.config','getOwnPropertyDescriptor','syncExecuteCommand','_config','Tools','getRichTextEditPath','4ukDeSs','config','max','onStarting','sort','assign','_change$','getRegisteredFormulas','notifyTextChanged','_deleteRegistration','assess','source','LexerTreeBuilder','getScalarFormulaResultCell','TABLE_ROW_START','forEach','_hostExternalReferenceModel','numberFormat','TABLE_START','1328535oIRgRJ','univer-docs-formula','keys','shiftExclusiveRangeOnDelete','wholeEntity','formulas','getResult','getCustomRangeInterval','string','resource','start','DocTextResolverService','DocSelectionManagerService','cursorOffset','Subject','unregister','min','resolveFormulaResultPresentation','_cacheEligibilityService','startsWith','docs-formula.mutation.set-resource','cell','_formulaKeys','getTextRanges','877597zlWUjJ','setResource','RemoveDocFormulaCommand','paragraphs','DOC_FORMULA_PLUGIN','disposeWithMe','CUSTOM','customDecorations','FormulaCacheEligibilityService','16ZjwMPi','degradeBody','startIndex','error','formula','isInteger','externalReferences','_injector','getRevision','isArray','sectionBreaks','segmentId','pluginName','subscribe','degradeDocFormulaDocumentData','_model','buildUpsertHostExternalReferenceMutations','eligible','unitDisposed$','IConfigService','getCurrentUnitOfType','shiftInclusiveRangeOnDelete','disabled','isDocFormulaResource','getUnitId','1.5.1','previousDocumentData','Doc\x20Formula\x20range\x20cannot\x20cross\x20document\x20structure\x20boundaries','resourceRedo','createEmptyDocFormulaResource','iterator','docs-formula.mutation.set-last-values','InvalidDocFormulaInsertRangeError','CommandType','documentRedo','getSnapshot','length','insertLength','IUniverInstanceService','UniverDocsPlugin','nextResource','set','stringify','deleteLength','@univerjs-pro/docs-formula','next','getPresentation','getFormulas','type','call','presentation','SetDocFormulaResourceMutation','_syncScheduled','undoMutation'];_0x4b6d=function(){return _0x572864;};return _0x4b6d();}function be(_0x4103f2,_0x418713){const _0x5f304d=_0x324a21;var _0x708464;return(_0x708464=_0x4103f2[_0x5f304d(0x239)](n['DocSelectionManagerService'])[_0x5f304d(0x184)]({'subUnitId':_0x418713,'unitId':_0x418713}))==null?void 0x0:_0x708464[0x0];}function xe(_0x1e794f,_0x4ead21,_0x405eba){const _0x49e375=_0x324a21;if((_0x1e794f==null?void 0x0:_0x1e794f[_0x49e375(0x1be)])==='paragraph'){var _0x36e586;let _0x537e35=((_0x36e586=_0x4ead21[_0x49e375(0x188)])==null?void 0x0:_0x36e586[_0x49e375(0x24b)](_0x1bfb7a=>_0x1bfb7a[_0x49e375(0x232)]===_0x1e794f[_0x49e375(0x232)]))??[];if(_0x537e35[_0x49e375(0x1b2)]!==0x1)return null;let _0x1fff43=_0x537e35[0x0],_0x27fe93=(0x0,t[_0x49e375(0x221)])(_0x4ead21,_0x1fff43),_0x21a97=_0x1fff43['startIndex']-_0x27fe93,_0x82cf6a=_0x1e794f[_0x49e375(0x255)]===_0x49e375(0x1e0)?_0x21a97:_0x1e794f[_0x49e375(0x255)];if(!Number['isInteger'](_0x82cf6a)||_0x82cf6a<0x0||_0x82cf6a>_0x21a97)return null;let _0x51b1fd=_0x27fe93+_0x82cf6a;return{'startOffset':_0x51b1fd,'endOffset':_0x51b1fd};}if((_0x1e794f==null?void 0x0:_0x1e794f['type'])===_0x49e375(0x21c))return!Number[_0x49e375(0x193)](_0x1e794f[_0x49e375(0x22d)])||!Number[_0x49e375(0x193)](_0x1e794f['endOffset'])?null:{'startOffset':Math['min'](_0x1e794f[_0x49e375(0x22d)],_0x1e794f[_0x49e375(0x1d3)]),'endOffset':Math[_0x49e375(0x15c)](_0x1e794f[_0x49e375(0x22d)],_0x1e794f[_0x49e375(0x1d3)])};let _0x4d8426=(_0x1e794f==null?void 0x0:_0x1e794f[_0x49e375(0x1be)])===_0x49e375(0x12a)?_0x1e794f[_0x49e375(0x12a)]:_0x405eba;return!_0x4d8426||_0x4d8426['segmentId']?null:{'startOffset':Math['min'](_0x4d8426[_0x49e375(0x22d)],_0x4d8426[_0x49e375(0x1d3)]),'endOffset':Math[_0x49e375(0x15c)](_0x4d8426['startOffset'],_0x4d8426[_0x49e375(0x1d3)])};}function Se(_0x39cb97,_0x201341,_0x2f3bb4,_0x32704d){const _0x234f2b=_0x324a21;let _0x54860f=_0x39cb97['get'](r[_0x234f2b(0x166)]),_0x4c7016=_0x2f3bb4[_0x234f2b(0x180)]('=')?_0x2f3bb4[_0x234f2b(0x209)](0x1):_0x2f3bb4,_0x8130fc=_0x54860f[_0x234f2b(0x222)](_0x4c7016);if(!_0x8130fc)return null;let _0x1a1e29=_0x39cb97['get'](e[_0x234f2b(0x212)]),_0x345e93=(0x0,e[_0x234f2b(0x252)])({'qualifiers':(0x0,e[_0x234f2b(0x24d)])(_0x8130fc),'explicitReferences':_0x32704d??[],'resolveBinding':_0x22c552=>_0x1a1e29['resolveBinding'](_0x201341,_0x22c552)});return _0x345e93['status']==='resolved'?_0x345e93['references']:null;}function Ce(_0x89dc6a,_0x52da9b,_0x1723db){const _0x1bc332=_0x324a21;var _0x4aebd2;let _0x9e699e=(0x0,t[_0x1bc332(0x137)])(0x6);for(;_0x89dc6a!=null&&(_0x4aebd2=_0x89dc6a[_0x1bc332(0x234)])!=null&&_0x4aebd2['some'](_0x35bf04=>_0x35bf04[_0x1bc332(0x203)]===_0x9e699e)||_0x52da9b['getFormula'](_0x1723db,_0x9e699e);)_0x9e699e=(0x0,t[_0x1bc332(0x137)])(0x6);return _0x9e699e;}function we(_0x120aa9){try{return te(_0x120aa9);}catch(_0x332ad3){if(_0x332ad3 instanceof m)return null;throw _0x332ad3;}}function Te(_0x6b9c62){const _0x31613b=_0x324a21;let _0x225f29=_0x6b9c62['previousDocumentData']&&_0x6b9c62[_0x31613b(0x1fe)]?De(_0x6b9c62[_0x31613b(0x1c8)],_0x6b9c62[_0x31613b(0x23c)],_0x6b9c62[_0x31613b(0x1a8)],_0x6b9c62[_0x31613b(0x1fe)],_0x6b9c62['cursorOffset'],_0x6b9c62[_0x31613b(0x1d1)]):null;return _0x6b9c62[_0x31613b(0x1a8)]&&_0x6b9c62[_0x31613b(0x1fe)]&&!_0x225f29?null:{'documentRedo':_0x225f29,'resourceRedo':{'id':L['id'],'params':{'unitId':_0x6b9c62['unitId'],'resource':_0x6b9c62[_0x31613b(0x1b6)]}},'resourceUndo':{'id':L['id'],'params':{'unitId':_0x6b9c62[_0x31613b(0x23c)],'resource':_0x6b9c62['previousResource']}}};}function Ee(_0x5d3016,_0xc36122,_0x109432,_0x37e737){const _0x32ebcb=_0x324a21;_0x37e737[_0x32ebcb(0x21e)]({'id':_0x5d3016[_0x32ebcb(0x1d1)]+':'+_0x5d3016[_0x32ebcb(0x203)],'unitID':_0x5d3016[_0x32ebcb(0x23c)],'redoMutations':[..._0x5d3016[_0x32ebcb(0x146)]['redoMutation']?[_0x5d3016['externalMutations']['redoMutation']]:[],..._0xc36122[_0x32ebcb(0x1b0)]?[_0xc36122[_0x32ebcb(0x1b0)]]:[],_0xc36122[_0x32ebcb(0x1aa)]],'undoMutations':[_0xc36122[_0x32ebcb(0x22b)],..._0x109432?[_0x109432]:[],..._0x5d3016['externalMutations'][_0x32ebcb(0x1c3)]?[_0x5d3016[_0x32ebcb(0x146)][_0x32ebcb(0x1c3)]]:[]]});}function q(_0x5b61e8){const _0xd60fb0=_0x324a21;let _0x4cb32b=_0x5b61e8[_0xd60fb0(0x1cd)]['get'](t[_0xd60fb0(0x224)]),_0x495cee=_0x5b61e8[_0xd60fb0(0x1cd)][_0xd60fb0(0x239)](t[_0xd60fb0(0x1c5)]),_0x4963f9=_0x5b61e8[_0xd60fb0(0x1cd)][_0xd60fb0(0x239)](n[_0xd60fb0(0x179)]),_0x49740c=Te(_0x5b61e8);if(!_0x49740c)return!0x1;let _0x75e22f=!0x1,_0x49b6fe=null,_0x831854=!0x1;try{if(_0x5b61e8['externalMutations'][_0xd60fb0(0x1c4)]){if(!_0x4cb32b[_0xd60fb0(0x156)](_0x5b61e8['externalMutations'][_0xd60fb0(0x1c4)]['id'],_0x5b61e8[_0xd60fb0(0x146)]['redoMutation'][_0xd60fb0(0x20d)]))return!0x1;_0x75e22f=!0x0;}if(_0x49740c[_0xd60fb0(0x1b0)]){let _0xacfa11=_0x4cb32b[_0xd60fb0(0x156)](_0x49740c[_0xd60fb0(0x1b0)]['id'],_0x49740c[_0xd60fb0(0x1b0)][_0xd60fb0(0x20d)]);if(!_0xacfa11)return J(_0x4cb32b,_0x5b61e8[_0xd60fb0(0x146)],_0x75e22f),!0x1;_0x49b6fe={'id':n[_0xd60fb0(0x151)]['id'],'params':{..._0xacfa11,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'segmentId':''}};}if(!_0x4cb32b[_0xd60fb0(0x156)](_0x49740c[_0xd60fb0(0x1aa)]['id'],_0x49740c[_0xd60fb0(0x1aa)][_0xd60fb0(0x20d)]))return Oe(_0x4cb32b,_0x49b6fe),J(_0x4cb32b,_0x5b61e8[_0xd60fb0(0x146)],_0x75e22f),!0x1;_0x831854=!0x0,Ee(_0x5b61e8,_0x49740c,_0x49b6fe,_0x495cee);}catch(_0x4bdc4f){throw _0x831854&&_0x4cb32b[_0xd60fb0(0x156)](_0x49740c[_0xd60fb0(0x22b)]['id'],_0x49740c[_0xd60fb0(0x22b)][_0xd60fb0(0x20d)]),Oe(_0x4cb32b,_0x49b6fe),J(_0x4cb32b,_0x5b61e8[_0xd60fb0(0x146)],_0x75e22f),_0x4bdc4f;}return _0x4963f9[_0xd60fb0(0x251)]([{'startOffset':_0x5b61e8[_0xd60fb0(0x17a)],'endOffset':_0x5b61e8['cursorOffset'],'segmentId':''}],{'unitId':_0x5b61e8[_0xd60fb0(0x23c)],'subUnitId':_0x5b61e8[_0xd60fb0(0x23c)]},!0x1,{[n[_0xd60fb0(0x20a)]]:!0x0}),!0x0;}function De(_0x27551f,_0x2a02ce,_0x5bfaa6,_0x2a6c64,_0x324bcd,_0x326f85){const _0x486c30=_0x324a21;let _0x50192c=ke(_0x5bfaa6,_0x2a6c64,(0x0,t[_0x486c30(0x159)])(_0x27551f,''));return _0x50192c?{'id':n[_0x486c30(0x151)]['id'],'params':{'unitId':_0x2a02ce,'actions':_0x50192c,'segmentId':'','textRanges':[{'startOffset':_0x324bcd,'endOffset':_0x324bcd,'collapsed':!0x0,'segmentId':''}],'isEditing':!0x1,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'trigger':_0x326f85}}:null;}function Oe(_0x25bfc6,_0xdf905e){const _0x24e08a=_0x324a21;_0xdf905e&&_0x25bfc6[_0x24e08a(0x156)](_0xdf905e['id'],_0xdf905e[_0x24e08a(0x20d)]);}function J(_0x2a5f12,_0x30aff5,_0x1a5bb9){const _0x41976=_0x324a21;_0x1a5bb9&&_0x30aff5[_0x41976(0x1c3)]&&_0x2a5f12[_0x41976(0x156)](_0x30aff5[_0x41976(0x1c3)]['id'],_0x30aff5['undoMutation'][_0x41976(0x20d)]);}function ke(_0x4bbfcb,_0x371823,_0x32845a){const _0x219069=_0x324a21;let _0x49a28a=_0x4bbfcb[_0x219069(0x1cb)],_0x31105d=_0x371823[_0x219069(0x1cb)],_0x4dc9b6=Ae(_0x49a28a==null?void 0x0:_0x49a28a['dataStream'],_0x31105d==null?void 0x0:_0x31105d[_0x219069(0x247)]);if(!_0x4dc9b6||!_0x31105d)return null;let _0xa3c99e=new t[(_0x219069(0x1ec))]();return _0xa3c99e['retain'](_0x4dc9b6[_0x219069(0x177)]),_0x4dc9b6[_0x219069(0x1b3)]>0x0&&_0xa3c99e[_0x219069(0x139)](_0x4dc9b6[_0x219069(0x1b3)],(0x0,t['getBodySliceForTextXAction'])(_0x31105d,_0x4dc9b6[_0x219069(0x177)],_0x4dc9b6[_0x219069(0x177)]+_0x4dc9b6[_0x219069(0x1b3)],!0x1)),_0x4dc9b6[_0x219069(0x1b9)]>0x0&&_0xa3c99e[_0x219069(0x1ef)](_0x4dc9b6[_0x219069(0x1b9)]),t['JSONX'][_0x219069(0x227)]()[_0x219069(0x13e)](_0xa3c99e[_0x219069(0x12f)](),_0x32845a);}function Ae(_0x50eee6,_0x18105a){const _0x40a2d2=_0x324a21;if(_0x50eee6==null||_0x18105a==null||_0x50eee6===_0x18105a)return null;let _0x42b199=0x0;for(;_0x42b199<_0x50eee6[_0x40a2d2(0x1b2)]&&_0x42b199<_0x18105a[_0x40a2d2(0x1b2)]&&_0x50eee6[_0x42b199]===_0x18105a[_0x42b199];)_0x42b199+=0x1;let _0x13472b=_0x50eee6[_0x40a2d2(0x1b2)],_0x45642b=_0x18105a[_0x40a2d2(0x1b2)];for(;_0x13472b>_0x42b199&&_0x45642b>_0x42b199&&_0x50eee6[_0x13472b-0x1]===_0x18105a[_0x45642b-0x1];)--_0x13472b,--_0x45642b;return{'start':_0x42b199,'deleteLength':_0x13472b-_0x42b199,'insertLength':_0x45642b-_0x42b199};}function je(_0x1e8965){const _0x5091dd=_0x324a21;return{'formulas':Object[_0x5091dd(0x243)](Object[_0x5091dd(0x1dc)](_0x1e8965[_0x5091dd(0x172)])[_0x5091dd(0x253)](([_0x5b6472,_0x2dac84])=>[_0x5b6472,{..._0x2dac84,..._0x2dac84[_0x5091dd(0x16b)]?{'numberFormat':{..._0x2dac84[_0x5091dd(0x16b)]}}:null,..._0x2dac84[_0x5091dd(0x1f0)]?{'lastValue':{..._0x2dac84[_0x5091dd(0x1f0)]}}:null}]))};}let Y=class extends t['Disposable']{constructor(_0x3d32be,_0x143e84,_0x22a6a5,_0x1b0b3e){const _0x124b3a=_0x324a21;super(),this['_instanceService']=_0x3d32be,this[_0x124b3a(0x142)]=_0x143e84,this[_0x124b3a(0x19d)]=_0x22a6a5,this[_0x124b3a(0x20c)]=_0x1b0b3e,D(this,_0x124b3a(0x1dd),new Set()),D(this,_0x124b3a(0x1c2),!0x1),D(this,_0x124b3a(0x1d7),!0x1),this[_0x124b3a(0x1c6)]['getAllUnitsForType'](t['UniverInstanceType']['UNIVER_DOC'])[_0x124b3a(0x169)](_0xaee7d5=>this[_0x124b3a(0x20c)][_0x124b3a(0x152)](_0xaee7d5)),this['disposeWithMe'](this[_0x124b3a(0x19d)]['change$']['subscribe'](({unitId:_0x410f7e})=>this[_0x124b3a(0x1ed)](_0x410f7e))),this[_0x124b3a(0x18a)](this[_0x124b3a(0x1c6)][_0x124b3a(0x14b)][_0x124b3a(0x19b)](({unit:_0x53043e})=>{const _0x595099=_0x124b3a;_0x53043e[_0x595099(0x1be)]===t[_0x595099(0x206)][_0x595099(0x245)]&&this[_0x595099(0x1f6)](_0x53043e[_0x595099(0x1a6)]());})),this[_0x124b3a(0x18a)](this[_0x124b3a(0x1c6)][_0x124b3a(0x1a0)][_0x124b3a(0x19b)](_0x1cdb18=>{const _0x3c421e=_0x124b3a;this[_0x3c421e(0x20c)][_0x3c421e(0x20f)](_0x1cdb18['getUnitId']());})),this[_0x124b3a(0x18a)](this[_0x124b3a(0x142)][_0x124b3a(0x140)](_0x2ebd55=>{const _0x468900=_0x124b3a;if(_0x2ebd55['id']===n['RichTextEditingMutation']['id']&&Me(_0x2ebd55[_0x468900(0x20d)])){let _0x6ce039=_0x2ebd55[_0x468900(0x20d)];_0x6ce039[_0x468900(0x199)]||this[_0x468900(0x1ed)](_0x6ce039[_0x468900(0x23c)]);}}));}['dispose'](){const _0x1902b9=_0x324a21;this[_0x1902b9(0x1d7)]=!0x0,super['dispose']();}[_0x324a21(0x1f6)](_0x594cbd){const _0x2ccbc7=_0x324a21;this[_0x2ccbc7(0x1dd)][_0x2ccbc7(0x237)](_0x594cbd),this[_0x2ccbc7(0x1c2)]||(this[_0x2ccbc7(0x1c2)]=!0x0,queueMicrotask(()=>{const _0x306cae=_0x2ccbc7;if(this[_0x306cae(0x1c2)]=!0x1,this['_isDisposed'])return;let _0x395bfb=Array[_0x306cae(0x24c)](this[_0x306cae(0x1dd)]);this[_0x306cae(0x1dd)][_0x306cae(0x20e)](),_0x395bfb[_0x306cae(0x169)](_0x34f441=>this[_0x306cae(0x1ed)](_0x34f441));}));}[_0x324a21(0x1ed)](_0x438619){const _0x18a9fc=_0x324a21;let _0x4df32c=this['_instanceService'][_0x18a9fc(0x24f)](_0x438619,t[_0x18a9fc(0x206)]['UNIVER_DOC']);_0x4df32c&&this[_0x18a9fc(0x20c)]['syncUnit'](_0x4df32c);}};Y=A([k(0x0,t[_0x324a21(0x1b4)]),k(0x1,t['ICommandService']),k(0x2,(0x0,t['Inject'])(O)),k(0x3,(0x0,t['Inject'])(j))],Y);function Me(_0x570982){const _0x41ce02=_0x324a21;return typeof _0x570982==_0x41ce02(0x1f3)&&!!_0x570982&&_0x41ce02(0x23c)in _0x570982&&typeof _0x570982[_0x41ce02(0x23c)]==_0x41ce02(0x175)&&(!(_0x41ce02(0x199)in _0x570982)||_0x570982[_0x41ce02(0x199)]===void 0x0||typeof _0x570982[_0x41ce02(0x199)]==_0x41ce02(0x175));}let X=class extends t['Disposable']{constructor(_0x5b1dc7,_0x36fc05){const _0x340a07=_0x324a21;super(),this[_0x340a07(0x1e8)]=_0x5b1dc7,this[_0x340a07(0x131)]=_0x36fc05,this[_0x340a07(0x18a)](this[_0x340a07(0x1e8)][_0x340a07(0x214)]({'pluginName':o,'businesses':[t[_0x340a07(0x206)][_0x340a07(0x245)]],'toJson':_0x5ce79b=>JSON[_0x340a07(0x1b8)](this['_docFormulaModel'][_0x340a07(0x12f)](_0x5ce79b)),'parseJson':_0x53ae85=>JSON[_0x340a07(0x218)](_0x53ae85),'onLoad':(_0x1d110c,_0x31feb0)=>{const _0x3bead0=_0x340a07;this[_0x3bead0(0x131)][_0x3bead0(0x1ee)](_0x1d110c,_0x31feb0);},'onUnLoad':_0x16dc6f=>this[_0x340a07(0x131)][_0x340a07(0x1d0)](_0x16dc6f)}));}};X=A([k(0x0,t['IResourceManagerService']),k(0x1,(0x0,t[_0x324a21(0x1ca)])(O))],X);var Ne=_0x324a21(0x1ba),Pe=_0x324a21(0x1a7);const Fe={};let Z=class extends t['Disposable']{constructor(_0x150ef8,_0xab4c54,_0x220a11){const _0x2a7163=_0x324a21;super(),this[_0x2a7163(0x147)]=_0x150ef8,this[_0x2a7163(0x1e4)]=_0xab4c54,this['disposeWithMe'](_0x220a11['register']({'resolve':(_0x2bddfe,_0x1b2957)=>{const _0x121169=_0x2a7163;var _0x561a4b;return((_0x561a4b=_0x1b2957['customRanges'])==null?void 0x0:_0x561a4b[_0x121169(0x24b)](g)[_0x121169(0x253)](_0x3e0b44=>({'startOffset':_0x3e0b44[_0x121169(0x190)],'endOffset':_0x3e0b44[_0x121169(0x1f2)]+0x1,'text':this[_0x121169(0x216)](_0x2bddfe,_0x3e0b44[_0x121169(0x203)])})))??[];}})),this[_0x2a7163(0x18a)](this['_formulaService'][_0x2a7163(0x153)][_0x2a7163(0x19b)](({unitId:_0x2a64b9})=>{const _0x3b4d1f=_0x2a7163;_0x220a11[_0x3b4d1f(0x162)](_0x2a64b9);}));}[_0x324a21(0x216)](_0x4c7eff,_0x24919b){const _0x35da39=_0x324a21;var _0x1cc268;return((_0x1cc268=this[_0x35da39(0x1e4)][_0x35da39(0x173)]({'unitId':_0x4c7eff,'rangeId':_0x24919b}))==null?void 0x0:_0x1cc268[_0x35da39(0x1de)])??'';}[_0x324a21(0x217)](_0x45e871,_0xc53716,_0x3a6b6e){const _0x158bdc=_0x324a21;var _0x53f3f2;let _0x511fe1=this[_0x158bdc(0x147)][_0x158bdc(0x24f)](_0x45e871,t[_0x158bdc(0x206)]['UNIVER_DOC']),_0x45c27d=_0x511fe1==null?void 0x0:_0x511fe1[_0x158bdc(0x129)]();if(!_0x45c27d)return'';let _0x513094=_0x45c27d['dataStream'][_0x158bdc(0x209)](_0xc53716,_0x3a6b6e),_0x15dd9f=((_0x53f3f2=_0x45c27d[_0x158bdc(0x234)])==null?void 0x0:_0x53f3f2['filter'](_0x485c37=>g(_0x485c37)&&_0x485c37[_0x158bdc(0x190)]>=_0xc53716&&_0x485c37['endIndex']<_0x3a6b6e)[_0x158bdc(0x15e)]((_0x329f1b,_0x525329)=>_0x525329[_0x158bdc(0x190)]-_0x329f1b[_0x158bdc(0x190)]))??[];for(let _0x1c4780 of _0x15dd9f){let _0x1655e4=_0x1c4780['startIndex']-_0xc53716,_0x6af0bb=_0x1c4780['endIndex']-_0xc53716+0x1;_0x513094=''+_0x513094[_0x158bdc(0x209)](0x0,_0x1655e4)+this[_0x158bdc(0x216)](_0x45e871,_0x1c4780[_0x158bdc(0x203)])+_0x513094[_0x158bdc(0x209)](_0x6af0bb);}return _0x513094;}[_0x324a21(0x248)](_0x25eb88){return Ie(_0x25eb88);}[_0x324a21(0x18f)](_0x662dc7,_0x571268,_0x4dd9e0={}){const _0x4ca689=_0x324a21;var _0x4a8f5b;return re({'id':_0x662dc7,'body':_0x571268,'documentStyle':{}},(((_0x4a8f5b=_0x571268['customRanges'])==null?void 0x0:_0x4a8f5b[_0x4ca689(0x24b)](g))??[])[_0x4ca689(0x253)](_0x2ef99f=>({'rangeId':_0x2ef99f[_0x4ca689(0x203)],'text':_0x4dd9e0[_0x2ef99f[_0x4ca689(0x203)]]??this['resolveFormula'](_0x662dc7,_0x2ef99f['rangeId'])})))[_0x4ca689(0x1cb)]??{'dataStream':''};}};Z=A([k(0x0,t['IUniverInstanceService']),k(0x1,(0x0,t[_0x324a21(0x1ca)])(j)),k(0x2,(0x0,t[_0x324a21(0x1ca)])(n[_0x324a21(0x178)]))],Z);function Ie(_0x123014){const _0x1e33db=_0x324a21;var _0x3be8a3,_0x7b745a;let _0x3c76fe=Le(_0x123014),_0x3979ff=re(_0x123014,(((_0x3be8a3=_0x123014[_0x1e33db(0x1cb)])==null||(_0x3be8a3=_0x3be8a3[_0x1e33db(0x234)])==null?void 0x0:_0x3be8a3[_0x1e33db(0x24b)](g))??[])[_0x1e33db(0x253)](_0x33e74b=>({'rangeId':_0x33e74b[_0x1e33db(0x203)],'text':Re(_0x3c76fe==null?void 0x0:_0x3c76fe[_0x1e33db(0x172)][_0x33e74b[_0x1e33db(0x203)]])})));return _0x3979ff[_0x1e33db(0x1e5)]=(_0x7b745a=_0x3979ff[_0x1e33db(0x1e5)])==null?void 0x0:_0x7b745a['filter'](_0x23ba74=>_0x23ba74[_0x1e33db(0x134)]!==o),_0x3979ff;}function Le(_0x3aef49){const _0x44f891=_0x324a21;var _0x505a44;let _0x2ef259=(_0x505a44=_0x3aef49[_0x44f891(0x1e5)])==null||(_0x505a44=_0x505a44[_0x44f891(0x25c)](_0x35571e=>_0x35571e['name']===_0x44f891(0x189)))==null?void 0x0:_0x505a44[_0x44f891(0x1f9)];if(_0x2ef259)try{let _0x18c853=JSON[_0x44f891(0x218)](_0x2ef259);return l(_0x18c853)?_0x18c853:void 0x0;}catch{return;}}function Re(_0x1f06c2){const _0x5e68e7=_0x324a21;return _0x1f06c2?(0x0,e[_0x5e68e7(0x17e)])({'lastValue':_0x1f06c2[_0x5e68e7(0x1f0)],'numberFormat':_0x1f06c2['numberFormat']})['text']:'';}let Q=class extends t[_0x324a21(0x136)]{constructor(_0x1c591a,_0x10a274,_0x448fb2){const _0x288d9f=_0x324a21;super(),this[_0x288d9f(0x1e4)]=_0x1c591a,this[_0x288d9f(0x17f)]=_0x10a274,this[_0x288d9f(0x18a)](_0x448fb2[_0x288d9f(0x1f5)](this));}[_0x324a21(0x145)](_0x56ef11){const _0x192e57=_0x324a21;let _0x494cbe=new Map();for(let _0x8cdaa8 of this[_0x192e57(0x1e4)][_0x192e57(0x161)]()){var _0x2ae4f8;if(!this['_cacheEligibilityService'][_0x192e57(0x164)](_0x8cdaa8[_0x192e57(0x15b)]['formula'],_0x8cdaa8[_0x192e57(0x202)])[_0x192e57(0x19f)])continue;let _0x1ea051=(0x0,e[_0x192e57(0x167)])(_0x8cdaa8[_0x192e57(0x202)]),_0x40c219=_0x1ea051?(0x0,e['toFormulaLastValue'])(_0x1ea051):null;if(!_0x40c219||ze(_0x8cdaa8['config'][_0x192e57(0x1f0)],_0x40c219))continue;let _0x1d4336=_0x494cbe['get'](_0x8cdaa8[_0x192e57(0x14c)][_0x192e57(0x23c)])??[];_0x1d4336[_0x192e57(0x1fc)]({'rangeId':_0x8cdaa8[_0x192e57(0x14c)][_0x192e57(0x203)],'expectedFormula':_0x8cdaa8[_0x192e57(0x15b)][_0x192e57(0x192)],'expectedNumberFormat':(_0x2ae4f8=_0x8cdaa8[_0x192e57(0x15b)][_0x192e57(0x16b)])==null?void 0x0:_0x2ae4f8['pattern'],'expectedReferenceRevision':_0x8cdaa8[_0x192e57(0x229)],'lastValue':_0x40c219}),_0x494cbe[_0x192e57(0x1b7)](_0x8cdaa8['identity'][_0x192e57(0x23c)],_0x1d4336);}return Array[_0x192e57(0x24c)](_0x494cbe,([_0x3ff49a,_0x147f6b])=>({'id':R['id'],'params':{'unitId':_0x3ff49a,'updates':_0x147f6b}}));}};Q=A([k(0x0,(0x0,t[_0x324a21(0x1ca)])(j)),k(0x1,(0x0,t['Inject'])(e[_0x324a21(0x18d)])),k(0x2,(0x0,t['Inject'])(e['FormulaLastValuePersistenceService']))],Q);function ze(_0x52569c,_0x4ea10c){const _0x470f44=_0x324a21;return(_0x52569c==null?void 0x0:_0x52569c['v'])===_0x4ea10c['v']&&(_0x52569c==null?void 0x0:_0x52569c['t'])===_0x4ea10c['t']&&(_0x52569c==null?void 0x0:_0x52569c[_0x470f44(0x220)])===_0x4ea10c['pattern'];}let $=class extends t[_0x324a21(0x23e)]{constructor(_0x3a9725=Fe,_0x28f9a4,_0x531121,_0x4dc356){const _0xd01f34=_0x324a21;super(),this[_0xd01f34(0x157)]=_0x3a9725,this[_0xd01f34(0x195)]=_0x28f9a4,this['_commandService']=_0x531121,this[_0xd01f34(0x240)]=_0x4dc356;let {..._0x44923f}=(0x0,t[_0xd01f34(0x133)])({},Fe,this['_config']);this[_0xd01f34(0x240)][_0xd01f34(0x225)](_0xd01f34(0x154),_0x44923f);}[_0x324a21(0x15d)](){const _0x538be2=_0x324a21;this[_0x538be2(0x195)]['add']([O]),this['_injector'][_0x538be2(0x237)]([j]),this[_0x538be2(0x195)][_0x538be2(0x237)]([X]),this[_0x538be2(0x195)]['add']([Y]),this[_0x538be2(0x195)][_0x538be2(0x237)]([Q]),this[_0x538be2(0x195)][_0x538be2(0x237)]([Z]),(0x0,t['touchDependencies'])(this[_0x538be2(0x195)],[[O],[X],[Y],[Q],[Z]]),[F,I,L,R,z,B,V,H,U,W][_0x538be2(0x169)](_0x5c5a38=>this[_0x538be2(0x18a)](this[_0x538be2(0x142)]['registerCommand'](_0x5c5a38)));}};D($,_0x324a21(0x19a),o),D($,_0x324a21(0x14a),Ne),D($,_0x324a21(0x204),Pe),D($,'type',t[_0x324a21(0x206)][_0x324a21(0x245)]),$=A([(0x0,t['DependentOn'])(a['UniverLicensePlugin'],e['UniverProFormulaEnginePlugin'],n[_0x324a21(0x1b5)]),k(0x1,(0x0,t['Inject'])(t[_0x324a21(0x250)])),k(0x2,t[_0x324a21(0x224)]),k(0x3,t[_0x324a21(0x1a1)])],$),exports[_0x324a21(0x1f8)]=W,exports['DOC_FORMULA_CUSTOM_RANGE_KIND']=s,exports['DOC_FORMULA_OBJECT_REPLACEMENT']='',exports[_0x324a21(0x189)]=o,Object[_0x324a21(0x1ea)](exports,'DocFormulaDisplayTextService',{'enumerable':!0x0,'get':function(){return Z;}}),Object[_0x324a21(0x1ea)](exports,'DocFormulaLifecycleController',{'enumerable':!0x0,'get':function(){return Y;}}),exports[_0x324a21(0x201)]=O,Object[_0x324a21(0x1ea)](exports,'DocFormulaResourceController',{'enumerable':!0x0,'get':function(){return X;}}),exports['DocFormulaResultStatus']=ve,Object[_0x324a21(0x1ea)](exports,_0x324a21(0x21d),{'enumerable':!0x0,'get':function(){return j;}}),exports[_0x324a21(0x1f1)]=z,exports[_0x324a21(0x1ae)]=m,exports[_0x324a21(0x187)]=H,exports['RemoveDocFormulaMutation']=I,exports[_0x324a21(0x1d9)]=U,exports['SetDocFormulaLastValuesMutation']=R,exports[_0x324a21(0x24a)]=F,exports[_0x324a21(0x257)]=V,exports[_0x324a21(0x1c1)]=L,Object['defineProperty'](exports,_0x324a21(0x210),{'enumerable':!0x0,'get':function(){return $;}}),exports[_0x324a21(0x23d)]=B,exports['assertSafeDocFormulaInsertRange']=ie,exports[_0x324a21(0x12c)]=te,exports[_0x324a21(0x22e)]=h,exports[_0x324a21(0x12d)]=ne,exports[_0x324a21(0x1ab)]=c,exports[_0x324a21(0x19c)]=Ie,exports[_0x324a21(0x1cc)]=_,exports['isDocFormulaConfig']=u,exports['isDocFormulaRange']=g,exports[_0x324a21(0x1a5)]=l,exports['isFormulaLastValue']=d;
|
package/lib/es/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var _0x4e8d1d=_0xf76d;function _0x3633(){var _0xc53dc7=['_docsFormulaDisplayTextService','customRanges','742016OgXaYr','setNumberFormat','_initialize','prototype','_createFormula','map','update','_getCompleteRanges','getFormulas','iterator','convertToText','_rangeId','get','getRange','_model','replaceWithText','symbol','startOffset','6cuuNFe','string','replaceWithFormula','startIndex','describe','_docsFormulaCommandService','getBody','_commandService','find','length','_insert','96289QLBCZB','createInstance','end','UNIVER_DOC','object','defineProperty','function','rangeId','syncExecuteCommand','3brbyHD','_docsFormulaModel','getSegmentId','degradeDocumentData','body','_univerInstanceService','567278WYaVeo','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','_injector','remove','_getCustomRange','range','extend','toPrimitive','appendFormula','getConfig','some','saveFormulaDisplayTextSnapshot','120635MEFBoL','62657pUpWko','getId','_service','2473560NMdnIY','call','formula','36ZgyRSH','5114950xzafyz','paragraph','numberFormat','getFormulaAt','default','_docsFormulaResourceLoaderService','getSnapshot','_document','insertFormula','endOffset','_unitId','endIndex','Document\x20','externalReferences','getFormula','saveUnit','decorate'];_0x3633=function(){return _0xc53dc7;};return _0x3633();}(function(_0x4b27be,_0x5eae59){var _0x1bd2f8=_0xf76d,_0x31e262=_0x4b27be();while(!![]){try{var _0x5e0f1=-parseInt(_0x1bd2f8(0x164))/0x1+-parseInt(_0x1bd2f8(0x173))/0x2*(-parseInt(_0x1bd2f8(0x16d))/0x3)+parseInt(_0x1bd2f8(0x186))/0x4*(parseInt(_0x1bd2f8(0x17f))/0x5)+-parseInt(_0x1bd2f8(0x159))/0x6*(parseInt(_0x1bd2f8(0x180))/0x7)+parseInt(_0x1bd2f8(0x147))/0x8+parseInt(_0x1bd2f8(0x183))/0x9+-parseInt(_0x1bd2f8(0x187))/0xa;if(_0x5e0f1===_0x5eae59)break;else _0x31e262['push'](_0x31e262['shift']());}catch(_0x3269d8){_0x31e262['push'](_0x31e262['shift']());}}}(_0x3633,0x3d6f7));import{ConvertDocFormulaToTextCommand as _0x3c527c,DocFormulaDisplayTextService as _0x43e9b5,DocFormulaModel as _0x5e08ca,DocFormulaService as _0x421237,InsertDocFormulaCommand as _0x3c045b,RemoveDocFormulaCommand as _0x37e065,ReplaceDocFormulaWithTextCommand as _0x2c2385,SetDocFormulaNumberFormatCommand as _0x492dd2,UpdateDocFormulaCommand as _0x3c604f,isDocFormulaRange as _0x19981d}from'@univerjs-pro/docs-formula';import{ICommandService as _0x549850,IResourceLoaderService as _0x312cab,IUniverInstanceService as _0x207dd1,Inject as _0x23a08b,UniverInstanceType as _0x46a90a}from'@univerjs/core';import{FDocument as _0x1ac644,FDocumentParagraph as _0x44e6e4,FDocumentTextRange as _0x4618e9}from'@univerjs/docs/facade';function v(_0x334af9,_0xad1b93){return function(_0x16c0a9,_0x23d6a7){_0xad1b93(_0x16c0a9,_0x23d6a7,_0x334af9);};}function y(_0x2111c7,_0x24bf90,_0x1ab771,_0x2707c5){var _0x3f40f2=_0xf76d,_0x4c55aa=arguments['length'],_0x19139e=_0x4c55aa<0x3?_0x24bf90:_0x2707c5===null?_0x2707c5=Object['getOwnPropertyDescriptor'](_0x24bf90,_0x1ab771):_0x2707c5,_0x3f17fd;if(typeof Reflect==_0x3f40f2(0x168)&&typeof Reflect[_0x3f40f2(0x144)]==_0x3f40f2(0x16a))_0x19139e=Reflect[_0x3f40f2(0x144)](_0x2111c7,_0x24bf90,_0x1ab771,_0x2707c5);else{for(var _0x34fd4b=_0x2111c7[_0x3f40f2(0x162)]-0x1;_0x34fd4b>=0x0;_0x34fd4b--)(_0x3f17fd=_0x2111c7[_0x34fd4b])&&(_0x19139e=(_0x4c55aa<0x3?_0x3f17fd(_0x19139e):_0x4c55aa>0x3?_0x3f17fd(_0x24bf90,_0x1ab771,_0x19139e):_0x3f17fd(_0x24bf90,_0x1ab771))||_0x19139e);}return _0x4c55aa>0x3&&_0x19139e&&Object[_0x3f40f2(0x169)](_0x24bf90,_0x1ab771,_0x19139e),_0x19139e;}let b=class{constructor(_0xe4cb1,_0x59071d,_0x38b188,_0x25b3e5,_0x1c9ec0,_0x4953d0){var _0x13e345=_0xf76d;this[_0x13e345(0x191)]=_0xe4cb1,this[_0x13e345(0x152)]=_0x59071d,this[_0x13e345(0x160)]=_0x38b188,this['_model']=_0x25b3e5,this[_0x13e345(0x182)]=_0x1c9ec0,this[_0x13e345(0x172)]=_0x4953d0;}[_0x4e8d1d(0x181)](){var _0x46b880=_0x4e8d1d;return this[_0x46b880(0x152)];}['getRange'](){var _0x377138=_0x4e8d1d;let _0x2189c5=this[_0x377138(0x177)]();return _0x2189c5?{'endOffset':_0x2189c5[_0x377138(0x192)]+0x1,'rangeId':_0x2189c5[_0x377138(0x16b)],'startOffset':_0x2189c5[_0x377138(0x15c)]}:null;}[_0x4e8d1d(0x195)](){var _0x3f7d78=_0x4e8d1d,_0x207919;return((_0x207919=this[_0x3f7d78(0x155)][_0x3f7d78(0x195)](this[_0x3f7d78(0x191)],this[_0x3f7d78(0x152)]))==null?void 0x0:_0x207919['formula'])??'';}['getConfig'](){var _0x448d71=_0x4e8d1d;return this[_0x448d71(0x155)][_0x448d71(0x195)](this[_0x448d71(0x191)],this[_0x448d71(0x152)])??null;}['getResult'](){var _0x5f5100=_0x4e8d1d;return this[_0x5f5100(0x182)]['getResult']({'unitId':this[_0x5f5100(0x191)],'rangeId':this[_0x5f5100(0x152)]})??null;}[_0x4e8d1d(0x15d)](){var _0x495312=_0x4e8d1d;let _0xd4cba5=this['getRange'](),_0x435634=this[_0x495312(0x17c)](),_0x340c9a=this['getResult']();return!_0xd4cba5||!_0x435634||!_0x340c9a?null:{..._0xd4cba5,'config':_0x435634,'formula':_0x435634[_0x495312(0x185)],'result':_0x340c9a,'type':_0x495312(0x185)};}[_0x4e8d1d(0x14d)](_0xeced81){var _0x5e87e6=_0x4e8d1d;return this['_commandService'][_0x5e87e6(0x16c)](_0x3c604f['id'],{'externalReferences':_0xeced81[_0x5e87e6(0x194)],'formula':_0xeced81[_0x5e87e6(0x185)],'numberFormat':_0xeced81[_0x5e87e6(0x189)],'rangeId':this[_0x5e87e6(0x152)],'unitId':this[_0x5e87e6(0x191)]});}[_0x4e8d1d(0x148)](_0x22f63d){var _0x337a27=_0x4e8d1d;return this[_0x337a27(0x160)][_0x337a27(0x16c)](_0x492dd2['id'],{'numberFormat':_0x22f63d,'rangeId':this[_0x337a27(0x152)],'unitId':this[_0x337a27(0x191)]});}[_0x4e8d1d(0x176)](){var _0x1d4cdc=_0x4e8d1d;return this[_0x1d4cdc(0x160)][_0x1d4cdc(0x16c)](_0x37e065['id'],{'rangeId':this[_0x1d4cdc(0x152)],'unitId':this[_0x1d4cdc(0x191)]});}[_0x4e8d1d(0x156)](_0x1fe20a){var _0x2f9b08=_0x4e8d1d;return this[_0x2f9b08(0x160)][_0x2f9b08(0x16c)](_0x2c2385['id'],{'rangeId':this[_0x2f9b08(0x152)],'text':_0x1fe20a,'unitId':this[_0x2f9b08(0x191)]});}[_0x4e8d1d(0x151)](){var _0x828606=_0x4e8d1d;return this[_0x828606(0x160)]['syncExecuteCommand'](_0x3c527c['id'],{'rangeId':this['_rangeId'],'unitId':this[_0x828606(0x191)]});}[_0x4e8d1d(0x177)](){var _0x1c7838=_0x4e8d1d,_0x9740a8;let _0x4bee25=this['_univerInstanceService']['getUnit'](this[_0x1c7838(0x191)],_0x46a90a[_0x1c7838(0x167)]);return _0x4bee25==null||(_0x9740a8=_0x4bee25[_0x1c7838(0x18d)]()[_0x1c7838(0x171)])==null||(_0x9740a8=_0x9740a8[_0x1c7838(0x146)])==null?void 0x0:_0x9740a8[_0x1c7838(0x161)](_0x2c4f82=>_0x2c4f82[_0x1c7838(0x16b)]===this[_0x1c7838(0x152)]&&_0x19981d(_0x2c4f82));}};function _0xf76d(_0x2e5ab8,_0x5f5a47){_0x2e5ab8=_0x2e5ab8-0x144;var _0x363350=_0x3633();var _0xf76d62=_0x363350[_0x2e5ab8];return _0xf76d62;}b=y([v(0x2,_0x549850),v(0x3,_0x23a08b(_0x5e08ca)),v(0x4,_0x23a08b(_0x421237)),v(0x5,_0x207dd1)],b);function x(_0x29dbc1){'@babel/helpers - typeof';var _0x18fceb=_0x4e8d1d;return x=typeof Symbol==_0x18fceb(0x16a)&&typeof Symbol[_0x18fceb(0x150)]==_0x18fceb(0x157)?function(_0x191f9b){return typeof _0x191f9b;}:function(_0x197c1f){var _0x1a8856=_0x18fceb;return _0x197c1f&&typeof Symbol==_0x1a8856(0x16a)&&_0x197c1f['constructor']===Symbol&&_0x197c1f!==Symbol[_0x1a8856(0x14a)]?_0x1a8856(0x157):typeof _0x197c1f;},x(_0x29dbc1);}function S(_0x473d74,_0x4fcc0d){var _0x529981=_0x4e8d1d;if(x(_0x473d74)!='object'||!_0x473d74)return _0x473d74;var _0x24c97b;if(typeof Symbol<'u'&&(_0x24c97b=_0x473d74[Symbol[_0x529981(0x17a)]])!==void 0x0){var _0x3392c6=_0x24c97b[_0x529981(0x184)](_0x473d74,_0x4fcc0d||_0x529981(0x18b));if(x(_0x3392c6)!=_0x529981(0x168))return _0x3392c6;throw TypeError(_0x529981(0x174));}return(_0x4fcc0d==='string'?String:Number)(_0x473d74);}function C(_0x1f4030){var _0x5eb068=_0x4e8d1d,_0x507509=S(_0x1f4030,_0x5eb068(0x15a));return x(_0x507509)==_0x5eb068(0x157)?_0x507509:_0x507509+'';}function w(_0x227b8f,_0x594c15,_0x3fc39e){return(_0x594c15=C(_0x594c15))in _0x227b8f?Object['defineProperty'](_0x227b8f,_0x594c15,{'value':_0x3fc39e,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x227b8f[_0x594c15]=_0x3fc39e,_0x227b8f;}var T=class extends _0x1ac644{constructor(..._0x516a2b){var _0x5df59d=_0x4e8d1d;super(..._0x516a2b),w(this,_0x5df59d(0x15e),void 0x0),w(this,_0x5df59d(0x145),void 0x0),w(this,_0x5df59d(0x16e),void 0x0),w(this,'_docsFormulaResourceLoaderService',void 0x0);}[_0x4e8d1d(0x149)](_0x2a9ab1){var _0x5cc953=_0x4e8d1d;this[_0x5cc953(0x15e)]=_0x2a9ab1['get'](_0x549850),this['_docsFormulaDisplayTextService']=_0x2a9ab1['get'](_0x43e9b5),this[_0x5cc953(0x16e)]=_0x2a9ab1[_0x5cc953(0x153)](_0x5e08ca),this[_0x5cc953(0x18c)]=_0x2a9ab1[_0x5cc953(0x153)](_0x312cab);}[_0x4e8d1d(0x14f)](){var _0xfc6774=_0x4e8d1d;return this[_0xfc6774(0x14e)]()[_0xfc6774(0x14c)](_0x208ef7=>this['_createFormula'](_0x208ef7[_0xfc6774(0x16b)]));}[_0x4e8d1d(0x195)](_0x13b033){var _0x57ce81=_0x4e8d1d;return this['_getCompleteRanges']()[_0x57ce81(0x17d)](_0x31bb84=>_0x31bb84[_0x57ce81(0x16b)]===_0x13b033)?this[_0x57ce81(0x14b)](_0x13b033):null;}[_0x4e8d1d(0x18a)](_0x3bbd59){var _0x60af2c=_0x4e8d1d;let _0x396893=this['_getCompleteRanges']()[_0x60af2c(0x161)](_0x196783=>_0x196783[_0x60af2c(0x15c)]<=_0x3bbd59&&_0x3bbd59<=_0x196783[_0x60af2c(0x192)]);return _0x396893?this[_0x60af2c(0x14b)](_0x396893[_0x60af2c(0x16b)]):null;}[_0x4e8d1d(0x17e)](){var _0x565f7a=_0x4e8d1d;let _0x207bca=this['_docsFormulaResourceLoaderService'][_0x565f7a(0x196)](this['id']);if(!_0x207bca)throw Error(_0x565f7a(0x193)+this['id']+'\x20could\x20not\x20be\x20serialized.');return this[_0x565f7a(0x145)][_0x565f7a(0x170)](_0x207bca);}[_0x4e8d1d(0x18f)](_0x391539){var _0x45fdfa=_0x4e8d1d;return this[_0x45fdfa(0x163)]({'externalReferences':_0x391539[_0x45fdfa(0x194)],'formula':_0x391539['formula'],'numberFormat':_0x391539[_0x45fdfa(0x189)],'target':{'type':_0x45fdfa(0x178),'startOffset':_0x391539[_0x45fdfa(0x158)],'endOffset':_0x391539[_0x45fdfa(0x190)]},'unitId':this[_0x45fdfa(0x181)]()});}[_0x4e8d1d(0x163)](_0x2e8b83){var _0x974750=_0x4e8d1d;let _0x5c0316=this[_0x974750(0x15e)]['syncExecuteCommand'](_0x3c045b['id'],_0x2e8b83);return _0x5c0316?this['_createFormula'](_0x5c0316[_0x974750(0x16b)]):null;}[_0x4e8d1d(0x14e)](){var _0x273fd4=_0x4e8d1d,_0xfad6d2;let _0x188bcf=this[_0x273fd4(0x16e)][_0x273fd4(0x14f)](this[_0x273fd4(0x181)]());return((_0xfad6d2=this[_0x273fd4(0x15f)]('')['customRanges'])==null?void 0x0:_0xfad6d2['filter'](_0x526892=>_0x19981d(_0x526892)&&_0x188bcf[_0x526892[_0x273fd4(0x16b)]]!=null))??[];}[_0x4e8d1d(0x14b)](_0x289242){var _0x4ba4ae=_0x4e8d1d;return this[_0x4ba4ae(0x175)]['createInstance'](b,this[_0x4ba4ae(0x181)](),_0x289242);}};_0x1ac644[_0x4e8d1d(0x179)](T);var E=class extends _0x44e6e4{constructor(..._0x5716df){var _0xa2aa34=_0x4e8d1d;super(..._0x5716df),w(this,_0xa2aa34(0x15e),void 0x0);}['_initialize'](_0x1d697f){var _0xcc815b=_0x4e8d1d;this['_docsFormulaCommandService']=_0x1d697f[_0xcc815b(0x153)](_0x549850);}[_0x4e8d1d(0x18f)](_0x2a4f4a,_0x3710d8,_0x1512ff={}){var _0x345d43=_0x4e8d1d;return this[_0x345d43(0x163)](_0x2a4f4a,_0x3710d8,_0x1512ff);}[_0x4e8d1d(0x17b)](_0x4c9c07,_0x26aa01={}){var _0x3e7d9e=_0x4e8d1d;return this[_0x3e7d9e(0x163)](_0x3e7d9e(0x166),_0x4c9c07,_0x26aa01);}[_0x4e8d1d(0x163)](_0x3159dc,_0x4062a2,_0x427c34){var _0x2a3313=_0x4e8d1d;if(this[_0x2a3313(0x16f)]())return null;let _0x3581df={'externalReferences':_0x427c34[_0x2a3313(0x194)],'formula':_0x4062a2,'numberFormat':_0x427c34[_0x2a3313(0x189)],'target':{'type':_0x2a3313(0x188),'paragraphId':this['getId'](),'position':_0x3159dc},'unitId':this[_0x2a3313(0x18e)][_0x2a3313(0x181)]()},_0x8a3f0c=this[_0x2a3313(0x15e)][_0x2a3313(0x16c)](_0x3c045b['id'],_0x3581df);return _0x8a3f0c?this[_0x2a3313(0x175)]['createInstance'](b,this[_0x2a3313(0x18e)][_0x2a3313(0x181)](),_0x8a3f0c[_0x2a3313(0x16b)]):null;}};_0x44e6e4[_0x4e8d1d(0x179)](E);var D=class extends _0x4618e9{constructor(..._0x2797e2){var _0x5c3edf=_0x4e8d1d;super(..._0x2797e2),w(this,_0x5c3edf(0x15e),void 0x0);}[_0x4e8d1d(0x149)](_0x45312a){var _0x5a4e91=_0x4e8d1d;this[_0x5a4e91(0x15e)]=_0x45312a[_0x5a4e91(0x153)](_0x549850);}[_0x4e8d1d(0x15b)](_0x1e5aab,_0x3c65c2={}){var _0x46eed9=_0x4e8d1d;let {endOffset:_0x574388,segmentId:_0x1f9318,startOffset:_0x116856}=this[_0x46eed9(0x154)]();return _0x1f9318?null:this['_insert'](_0x116856,_0x574388,_0x1e5aab,_0x3c65c2);}['_insert'](_0x21d069,_0x5141dd,_0x4604ab,_0x12c9f8){var _0x5626fe=_0x4e8d1d;let _0x3f32b6={'externalReferences':_0x12c9f8[_0x5626fe(0x194)],'formula':_0x4604ab,'numberFormat':_0x12c9f8[_0x5626fe(0x189)],'target':{'type':_0x5626fe(0x178),'startOffset':_0x21d069,'endOffset':_0x5141dd},'unitId':this[_0x5626fe(0x18e)][_0x5626fe(0x181)]()},_0x294159=this['_docsFormulaCommandService'][_0x5626fe(0x16c)](_0x3c045b['id'],_0x3f32b6);return _0x294159?this[_0x5626fe(0x175)][_0x5626fe(0x165)](b,this[_0x5626fe(0x18e)][_0x5626fe(0x181)](),_0x294159['rangeId']):null;}};_0x4618e9[_0x4e8d1d(0x179)](D);export{b as FDocumentFormula};
|
|
1
|
+
var _0x3a803d=_0x4c55;(function(_0xde343c,_0x2641e0){var _0xe311b6=_0x4c55,_0x7a802e=_0xde343c();while(!![]){try{var _0x29f1cf=parseInt(_0xe311b6(0xc9))/0x1+parseInt(_0xe311b6(0xf8))/0x2+-parseInt(_0xe311b6(0xe9))/0x3*(parseInt(_0xe311b6(0xf3))/0x4)+parseInt(_0xe311b6(0xf9))/0x5+parseInt(_0xe311b6(0xff))/0x6*(parseInt(_0xe311b6(0xcc))/0x7)+-parseInt(_0xe311b6(0xdd))/0x8+-parseInt(_0xe311b6(0xe6))/0x9;if(_0x29f1cf===_0x2641e0)break;else _0x7a802e['push'](_0x7a802e['shift']());}catch(_0xd2782c){_0x7a802e['push'](_0x7a802e['shift']());}}}(_0x3fa3,0xc89b3));import{ConvertDocFormulaToTextCommand as _0x4dc3b6,DocFormulaDisplayTextService as _0x44acd2,DocFormulaModel as _0x2217c6,DocFormulaService as _0x124ba9,InsertDocFormulaCommand as _0xcc371d,RemoveDocFormulaCommand as _0x21b7de,ReplaceDocFormulaWithTextCommand as _0x460db1,SetDocFormulaNumberFormatCommand as _0x582fd2,UpdateDocFormulaCommand as _0x59bdaf,isDocFormulaRange as _0x3ee5c9}from'@univerjs-pro/docs-formula';import{ICommandService as _0x29b40b,IResourceLoaderService as _0x3cc1a5,IUniverInstanceService as _0x3fa665,Inject as _0x1e7f0b,UniverInstanceType as _0xd4469a}from'@univerjs/core';import{FDocument as _0x4efe3d,FDocumentParagraph as _0x3ec53d,FDocumentTextRange as _0x5e91bd}from'@univerjs/docs/facade';function v(_0x36da73,_0x50c50b){return function(_0x2548a6,_0x21f6f2){_0x50c50b(_0x2548a6,_0x21f6f2,_0x36da73);};}function y(_0x4b2dd1,_0x300f69,_0x31f854,_0x33fee9){var _0x39cd8a=_0x4c55,_0x5987ad=arguments['length'],_0x86392c=_0x5987ad<0x3?_0x300f69:_0x33fee9===null?_0x33fee9=Object[_0x39cd8a(0x10b)](_0x300f69,_0x31f854):_0x33fee9,_0x2c7b28;if(typeof Reflect==_0x39cd8a(0x102)&&typeof Reflect[_0x39cd8a(0x100)]==_0x39cd8a(0x10e))_0x86392c=Reflect[_0x39cd8a(0x100)](_0x4b2dd1,_0x300f69,_0x31f854,_0x33fee9);else{for(var _0x52ad09=_0x4b2dd1[_0x39cd8a(0x105)]-0x1;_0x52ad09>=0x0;_0x52ad09--)(_0x2c7b28=_0x4b2dd1[_0x52ad09])&&(_0x86392c=(_0x5987ad<0x3?_0x2c7b28(_0x86392c):_0x5987ad>0x3?_0x2c7b28(_0x300f69,_0x31f854,_0x86392c):_0x2c7b28(_0x300f69,_0x31f854))||_0x86392c);}return _0x5987ad>0x3&&_0x86392c&&Object[_0x39cd8a(0xf1)](_0x300f69,_0x31f854,_0x86392c),_0x86392c;}let b=class{constructor(_0x24757e,_0x222f5f,_0x48c42a,_0x12304a,_0x4acc6c,_0x555797){var _0x495f69=_0x4c55;this[_0x495f69(0x109)]=_0x24757e,this['_rangeId']=_0x222f5f,this[_0x495f69(0xf5)]=_0x48c42a,this[_0x495f69(0x110)]=_0x12304a,this[_0x495f69(0xd7)]=_0x4acc6c,this['_univerInstanceService']=_0x555797;}['getId'](){var _0x37752f=_0x4c55;return this[_0x37752f(0x101)];}[_0x3a803d(0x10c)](){var _0x1d88df=_0x3a803d;let _0x214ac9=this[_0x1d88df(0xd3)]();return _0x214ac9?{'endOffset':_0x214ac9[_0x1d88df(0x106)]+0x1,'rangeId':_0x214ac9[_0x1d88df(0xeb)],'startOffset':_0x214ac9[_0x1d88df(0xe5)]}:null;}[_0x3a803d(0xea)](){var _0x4af4cd=_0x3a803d,_0x57693b;return((_0x57693b=this[_0x4af4cd(0x110)][_0x4af4cd(0xea)](this[_0x4af4cd(0x109)],this[_0x4af4cd(0x101)]))==null?void 0x0:_0x57693b['formula'])??'';}[_0x3a803d(0xf6)](){var _0x27f958=_0x3a803d;return this[_0x27f958(0x110)][_0x27f958(0xea)](this[_0x27f958(0x109)],this[_0x27f958(0x101)])??null;}[_0x3a803d(0xc6)](){var _0x347e93=_0x3a803d;return this[_0x347e93(0xd7)][_0x347e93(0xc6)]({'unitId':this['_unitId'],'rangeId':this[_0x347e93(0x101)]})??null;}['describe'](){var _0x4069cb=_0x3a803d;let _0x4f78ca=this[_0x4069cb(0x10c)](),_0x3cb615=this[_0x4069cb(0xf6)](),_0x2074e0=this['getResult']();return!_0x4f78ca||!_0x3cb615||!_0x2074e0?null:{..._0x4f78ca,'config':_0x3cb615,'formula':_0x3cb615['formula'],'result':_0x2074e0,'type':_0x4069cb(0xfc)};}[_0x3a803d(0xda)](_0x138879){var _0x55576a=_0x3a803d;return this[_0x55576a(0xf5)][_0x55576a(0xfa)](_0x59bdaf['id'],{'externalReferences':_0x138879[_0x55576a(0xe8)],'formula':_0x138879['formula'],'numberFormat':_0x138879[_0x55576a(0xed)],'rangeId':this['_rangeId'],'unitId':this[_0x55576a(0x109)]});}[_0x3a803d(0xc8)](_0x2499b0){var _0x3c4162=_0x3a803d;return this['_commandService'][_0x3c4162(0xfa)](_0x582fd2['id'],{'numberFormat':_0x2499b0,'rangeId':this['_rangeId'],'unitId':this['_unitId']});}[_0x3a803d(0xe2)](){var _0x54878c=_0x3a803d;return this['_commandService']['syncExecuteCommand'](_0x21b7de['id'],{'rangeId':this['_rangeId'],'unitId':this[_0x54878c(0x109)]});}['replaceWithText'](_0x49fc5e){var _0x230a71=_0x3a803d;return this['_commandService'][_0x230a71(0xfa)](_0x460db1['id'],{'rangeId':this[_0x230a71(0x101)],'text':_0x49fc5e,'unitId':this['_unitId']});}[_0x3a803d(0xd4)](){var _0x259aed=_0x3a803d;return this[_0x259aed(0xf5)]['syncExecuteCommand'](_0x4dc3b6['id'],{'rangeId':this[_0x259aed(0x101)],'unitId':this['_unitId']});}['_getCustomRange'](){var _0x17fa56=_0x3a803d,_0x1fea2d;let _0x331c67=this[_0x17fa56(0xd2)]['getUnit'](this[_0x17fa56(0x109)],_0xd4469a['UNIVER_DOC']);return _0x331c67==null||(_0x1fea2d=_0x331c67[_0x17fa56(0xce)]()[_0x17fa56(0xc7)])==null||(_0x1fea2d=_0x1fea2d[_0x17fa56(0xd5)])==null?void 0x0:_0x1fea2d['find'](_0x116d7d=>_0x116d7d['rangeId']===this[_0x17fa56(0x101)]&&_0x3ee5c9(_0x116d7d));}};function _0x3fa3(){var _0x364a24=['rangeId','createInstance','numberFormat','_insert','getFormulas','_docsFormulaResourceLoaderService','defineProperty','_docsFormulaModel','4976796KcPZAJ','saveFormulaDisplayTextSnapshot','_commandService','getConfig','getSegmentId','1768600faWCfa','5791790AmTlyN','syncExecuteCommand','map','formula','constructor','filter','6SwuMVl','decorate','_rangeId','object','_docsFormulaDisplayTextService','iterator','length','endIndex','_getCompleteRanges','getFormulaAt','_unitId','extend','getOwnPropertyDescriptor','getRange','insertFormula','function','symbol','_model','getResult','body','setNumberFormat','1262650QEgvhn','_injector','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','9308173JvwJnX','replaceWithFormula','getSnapshot','_document','_initialize','call','_univerInstanceService','_getCustomRange','convertToText','customRanges','get','_service','getId','_createFormula','update','toPrimitive','getBody','147240XmFbad','end','paragraph','saveUnit','some','remove','_docsFormulaCommandService','range','startIndex','22956840NNroqH','find','externalReferences','3mPacuv','getFormula'];_0x3fa3=function(){return _0x364a24;};return _0x3fa3();}b=y([v(0x2,_0x29b40b),v(0x3,_0x1e7f0b(_0x2217c6)),v(0x4,_0x1e7f0b(_0x124ba9)),v(0x5,_0x3fa665)],b);function x(_0x4c1ed2){'@babel/helpers - typeof';var _0x19be8f=_0x3a803d;return x=typeof Symbol==_0x19be8f(0x10e)&&typeof Symbol[_0x19be8f(0x104)]==_0x19be8f(0x10f)?function(_0x57b0d3){return typeof _0x57b0d3;}:function(_0x53e71d){var _0x2d9e60=_0x19be8f;return _0x53e71d&&typeof Symbol==_0x2d9e60(0x10e)&&_0x53e71d[_0x2d9e60(0xfd)]===Symbol&&_0x53e71d!==Symbol['prototype']?_0x2d9e60(0x10f):typeof _0x53e71d;},x(_0x4c1ed2);}function S(_0x4a20cd,_0x1eb92a){var _0x2892c5=_0x3a803d;if(x(_0x4a20cd)!=_0x2892c5(0x102)||!_0x4a20cd)return _0x4a20cd;var _0xd4074c;if(typeof Symbol<'u'&&(_0xd4074c=_0x4a20cd[Symbol[_0x2892c5(0xdb)]])!==void 0x0){var _0x265d26=_0xd4074c[_0x2892c5(0xd1)](_0x4a20cd,_0x1eb92a||'default');if(x(_0x265d26)!='object')return _0x265d26;throw TypeError(_0x2892c5(0xcb));}return(_0x1eb92a==='string'?String:Number)(_0x4a20cd);}function _0x4c55(_0x2f2233,_0x4740b8){_0x2f2233=_0x2f2233-0xc6;var _0x3fa37b=_0x3fa3();var _0x4c5561=_0x3fa37b[_0x2f2233];return _0x4c5561;}function C(_0x3092fb){var _0x1af065=_0x3a803d,_0x515731=S(_0x3092fb,'string');return x(_0x515731)==_0x1af065(0x10f)?_0x515731:_0x515731+'';}function w(_0x3b2482,_0x379d41,_0x21c9c0){var _0x31903b=_0x3a803d;return(_0x379d41=C(_0x379d41))in _0x3b2482?Object[_0x31903b(0xf1)](_0x3b2482,_0x379d41,{'value':_0x21c9c0,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x3b2482[_0x379d41]=_0x21c9c0,_0x3b2482;}var T=class extends _0x4efe3d{constructor(..._0x1ef66a){var _0x180f43=_0x3a803d;super(..._0x1ef66a),w(this,_0x180f43(0xe3),void 0x0),w(this,'_docsFormulaDisplayTextService',void 0x0),w(this,'_docsFormulaModel',void 0x0),w(this,_0x180f43(0xf0),void 0x0);}[_0x3a803d(0xd0)](_0x563508){var _0xb7aad=_0x3a803d;this[_0xb7aad(0xe3)]=_0x563508[_0xb7aad(0xd6)](_0x29b40b),this[_0xb7aad(0x103)]=_0x563508[_0xb7aad(0xd6)](_0x44acd2),this[_0xb7aad(0xf2)]=_0x563508[_0xb7aad(0xd6)](_0x2217c6),this[_0xb7aad(0xf0)]=_0x563508[_0xb7aad(0xd6)](_0x3cc1a5);}[_0x3a803d(0xef)](){var _0x1f7f64=_0x3a803d;return this['_getCompleteRanges']()[_0x1f7f64(0xfb)](_0x31aea4=>this['_createFormula'](_0x31aea4[_0x1f7f64(0xeb)]));}['getFormula'](_0x19b4c4){var _0x26f5b0=_0x3a803d;return this[_0x26f5b0(0x107)]()[_0x26f5b0(0xe1)](_0x988958=>_0x988958[_0x26f5b0(0xeb)]===_0x19b4c4)?this[_0x26f5b0(0xd9)](_0x19b4c4):null;}[_0x3a803d(0x108)](_0x34760c){var _0x52f910=_0x3a803d;let _0x3e0a10=this[_0x52f910(0x107)]()[_0x52f910(0xe7)](_0x390d03=>_0x390d03['startIndex']<=_0x34760c&&_0x34760c<=_0x390d03['endIndex']);return _0x3e0a10?this[_0x52f910(0xd9)](_0x3e0a10['rangeId']):null;}[_0x3a803d(0xf4)](){var _0x1969bc=_0x3a803d;let _0x13c4f1=this[_0x1969bc(0xf0)][_0x1969bc(0xe0)](this['id']);if(!_0x13c4f1)throw Error('Document\x20'+this['id']+'\x20could\x20not\x20be\x20serialized.');return this[_0x1969bc(0x103)]['degradeDocumentData'](_0x13c4f1);}[_0x3a803d(0x10d)](_0x338e17){var _0x1ef60c=_0x3a803d;return this[_0x1ef60c(0xee)]({'externalReferences':_0x338e17[_0x1ef60c(0xe8)],'formula':_0x338e17[_0x1ef60c(0xfc)],'numberFormat':_0x338e17[_0x1ef60c(0xed)],'target':{'type':_0x1ef60c(0xe4),'startOffset':_0x338e17['startOffset'],'endOffset':_0x338e17['endOffset']},'unitId':this[_0x1ef60c(0xd8)]()});}[_0x3a803d(0xee)](_0x3cfe70){var _0x5697be=_0x3a803d;let _0xbae152=this['_docsFormulaCommandService'][_0x5697be(0xfa)](_0xcc371d['id'],_0x3cfe70);return _0xbae152?this[_0x5697be(0xd9)](_0xbae152[_0x5697be(0xeb)]):null;}['_getCompleteRanges'](){var _0x5e9d4b=_0x3a803d,_0x2d10ce;let _0x62f609=this[_0x5e9d4b(0xf2)][_0x5e9d4b(0xef)](this[_0x5e9d4b(0xd8)]());return((_0x2d10ce=this[_0x5e9d4b(0xdc)]('')[_0x5e9d4b(0xd5)])==null?void 0x0:_0x2d10ce[_0x5e9d4b(0xfe)](_0x3cd0e5=>_0x3ee5c9(_0x3cd0e5)&&_0x62f609[_0x3cd0e5[_0x5e9d4b(0xeb)]]!=null))??[];}[_0x3a803d(0xd9)](_0x345772){var _0x36cea7=_0x3a803d;return this[_0x36cea7(0xca)][_0x36cea7(0xec)](b,this[_0x36cea7(0xd8)](),_0x345772);}};_0x4efe3d['extend'](T);var E=class extends _0x3ec53d{constructor(..._0x4be71d){var _0x9e05f9=_0x3a803d;super(..._0x4be71d),w(this,_0x9e05f9(0xe3),void 0x0);}['_initialize'](_0x2b96a7){var _0x22ea2d=_0x3a803d;this[_0x22ea2d(0xe3)]=_0x2b96a7['get'](_0x29b40b);}[_0x3a803d(0x10d)](_0x56bb57,_0xf79444,_0x5bcd73={}){var _0xfcf7d9=_0x3a803d;return this[_0xfcf7d9(0xee)](_0x56bb57,_0xf79444,_0x5bcd73);}['appendFormula'](_0x2e604a,_0x104c68={}){var _0x30d0a9=_0x3a803d;return this[_0x30d0a9(0xee)](_0x30d0a9(0xde),_0x2e604a,_0x104c68);}[_0x3a803d(0xee)](_0x370ae7,_0x19e2ef,_0x2a66ce){var _0x1e2d76=_0x3a803d;if(this[_0x1e2d76(0xf7)]())return null;let _0x3f1996={'externalReferences':_0x2a66ce[_0x1e2d76(0xe8)],'formula':_0x19e2ef,'numberFormat':_0x2a66ce[_0x1e2d76(0xed)],'target':{'type':_0x1e2d76(0xdf),'paragraphId':this['getId'](),'position':_0x370ae7},'unitId':this[_0x1e2d76(0xcf)][_0x1e2d76(0xd8)]()},_0x651e3e=this[_0x1e2d76(0xe3)][_0x1e2d76(0xfa)](_0xcc371d['id'],_0x3f1996);return _0x651e3e?this[_0x1e2d76(0xca)][_0x1e2d76(0xec)](b,this[_0x1e2d76(0xcf)][_0x1e2d76(0xd8)](),_0x651e3e[_0x1e2d76(0xeb)]):null;}};_0x3ec53d['extend'](E);var D=class extends _0x5e91bd{constructor(..._0x12cc1a){var _0xfbc239=_0x3a803d;super(..._0x12cc1a),w(this,_0xfbc239(0xe3),void 0x0);}[_0x3a803d(0xd0)](_0x57924c){var _0x505e43=_0x3a803d;this['_docsFormulaCommandService']=_0x57924c[_0x505e43(0xd6)](_0x29b40b);}[_0x3a803d(0xcd)](_0x413dfb,_0x944afc={}){var _0x51b458=_0x3a803d;let {endOffset:_0x3550be,segmentId:_0x3e5af3,startOffset:_0x45addf}=this[_0x51b458(0x10c)]();return _0x3e5af3?null:this[_0x51b458(0xee)](_0x45addf,_0x3550be,_0x413dfb,_0x944afc);}[_0x3a803d(0xee)](_0x2caa31,_0x50f2e0,_0x56252b,_0x14dd5b){var _0x409bd7=_0x3a803d;let _0x5490e7={'externalReferences':_0x14dd5b[_0x409bd7(0xe8)],'formula':_0x56252b,'numberFormat':_0x14dd5b[_0x409bd7(0xed)],'target':{'type':_0x409bd7(0xe4),'startOffset':_0x2caa31,'endOffset':_0x50f2e0},'unitId':this[_0x409bd7(0xcf)][_0x409bd7(0xd8)]()},_0xa8d631=this[_0x409bd7(0xe3)]['syncExecuteCommand'](_0xcc371d['id'],_0x5490e7);return _0xa8d631?this[_0x409bd7(0xca)][_0x409bd7(0xec)](b,this[_0x409bd7(0xcf)]['getId'](),_0xa8d631[_0x409bd7(0xeb)]):null;}};_0x5e91bd[_0x3a803d(0x10a)](D);export{b as FDocumentFormula};
|