@univerjs-pro/docs-formula 1.0.3 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/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 +9 -9
package/lib/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x34c9f2=_0x9a42;(function(_0x3fd348,_0x4d1222){const _0x426d50=_0x9a42,_0x5d915b=_0x3fd348();while(!![]){try{const _0x493f60=parseInt(_0x426d50(0x23b))/0x1*(-parseInt(_0x426d50(0x1ee))/0x2)+-parseInt(_0x426d50(0x29e))/0x3+-parseInt(_0x426d50(0x1fc))/0x4*(-parseInt(_0x426d50(0x22a))/0x5)+-parseInt(_0x426d50(0x1ea))/0x6*(parseInt(_0x426d50(0x2c0))/0x7)+-parseInt(_0x426d50(0x1f7))/0x8+parseInt(_0x426d50(0x2c5))/0x9+parseInt(_0x426d50(0x22d))/0xa;if(_0x493f60===_0x4d1222)break;else _0x5d915b['push'](_0x5d915b['shift']());}catch(_0x19bf52){_0x5d915b['push'](_0x5d915b['shift']());}}}(_0x35ee,0x5d711));import{FormulaCacheEligibilityService as _0x168d95,FormulaLastValuePersistenceService as _0x442e83,HostExternalReferenceModel as _0x598fe,UniverProFormulaEnginePlugin as _0x4266a3,buildUpsertHostExternalReferenceMutations as _0x64c5d3,collectFormulaExternalReferenceQualifiers as _0x51ffff,getScalarFormulaResultCell as _0x477060,resolveFormulaResultPresentation as _0x44276e,resolveHostFormulaExternalReferences as _0xc8a733,toFormulaLastValue as _0x16967c}from'@univerjs-pro/engine-formula';import{CellValueType as _0xcdd757,CommandType as _0x3d8c4d,CustomRangeType as _0xe8be5b,DataStreamTreeTokenType as _0x1a4e6c,DependentOn as _0x962570,Disposable as _0x49a82f,ICommandService as _0x1fba3b,IConfigService as _0x4eefec,IResourceManagerService as _0x674a1c,IUndoRedoService as _0x6bc219,IUniverInstanceService as _0x35f474,Inject as _0x5c5393,Injector as _0x57c044,JSONX as _0x42e010,Plugin as _0x530da8,TextX as _0x283512,Tools as _0x5e88d9,UniverInstanceType as _0x9cc7bc,generateRandomId as _0x23fed8,getBodySliceForTextXAction as _0x2ffd0f,getCustomRangeInterval as _0x3c5aee,getParagraphContentStartOffset as _0x44d00,getRichTextEditPath as _0x38047f,merge as _0x2e4085,shiftExclusiveRangeOnDelete as _0x4483d1,shiftExclusiveRangeOnInsert as _0x5e2c6d,shiftInclusiveRangeOnDelete as _0x16ca5b,shiftInclusiveRangeOnInsert as _0x2a05e1,touchDependencies as _0x6f29f6}from'@univerjs/core';import{DOC_SELECTION_OPTION_PRESERVE_CARET as _0x291f0f,DocSelectionManagerService as _0x1841de,DocTextResolverService as _0x557df1,RichTextEditingMutation as _0x26272f,UniverDocsPlugin as _0x4c3072}from'@univerjs/docs';import{FormulaResultStatus as _0x51281a,LexerTreeBuilder as _0x2ea0aa,OtherFormulaBizType as _0x20565b,RegisterOtherFormulaService as _0x2bd31f}from'@univerjs/engine-formula';import{Subject as _0x2c9ea2}from'rxjs';import{UniverLicensePlugin as _0x16ebc7}from'@univerjs-pro/license';const y=_0x34c9f2(0x26b),je=0x1,Me=_0x34c9f2(0x25e),Ne='';function b(){return{'schemaVersion':0x1,'formulas':{}};}function x(_0x811692){const _0x34b868=_0x34c9f2;return!_0x811692||typeof _0x811692!=_0x34b868(0x224)||!S(_0x811692,[_0x34b868(0x1f8),_0x34b868(0x214)])||!(_0x34b868(0x1f8)in _0x811692)||_0x811692[_0x34b868(0x1f8)]!==0x1||!(_0x34b868(0x214)in _0x811692)||!_0x811692[_0x34b868(0x214)]||typeof _0x811692[_0x34b868(0x214)]!=_0x34b868(0x224)||Array[_0x34b868(0x2a8)](_0x811692['formulas'])?!0x1:Object[_0x34b868(0x2ad)](_0x811692[_0x34b868(0x214)])[_0x34b868(0x2bb)](([_0xeaf602,_0x440282])=>_0xeaf602[_0x34b868(0x2c1)]>0x0&&Pe(_0x440282));}function Pe(_0xd26335){const _0x28aab0=_0x34c9f2;return!_0xd26335||typeof _0xd26335!=_0x28aab0(0x224)||!S(_0xd26335,['formula',_0x28aab0(0x271),_0x28aab0(0x21f)])||!(_0x28aab0(0x20f)in _0xd26335)||typeof _0xd26335[_0x28aab0(0x20f)]!=_0x28aab0(0x1d5)||!_0xd26335[_0x28aab0(0x20f)][_0x28aab0(0x27c)]()||_0x28aab0(0x271)in _0xd26335&&_0xd26335[_0x28aab0(0x271)]!=null&&(typeof _0xd26335[_0x28aab0(0x271)]!=_0x28aab0(0x224)||!S(_0xd26335[_0x28aab0(0x271)],[_0x28aab0(0x244)])||!(_0x28aab0(0x244)in _0xd26335['numberFormat'])||typeof _0xd26335['numberFormat'][_0x28aab0(0x244)]!=_0x28aab0(0x1d5))?!0x1:!(_0x28aab0(0x21f)in _0xd26335)||_0xd26335[_0x28aab0(0x21f)]==null||Fe(_0xd26335[_0x28aab0(0x21f)]);}function Fe(_0x5062cd){const _0x42133e=_0x34c9f2;return!_0x5062cd||typeof _0x5062cd!=_0x42133e(0x224)||!S(_0x5062cd,['v','t',_0x42133e(0x244)])||!('v'in _0x5062cd)||_0x5062cd['v']!==null&&typeof _0x5062cd['v']!=_0x42133e(0x1d5)&&typeof _0x5062cd['v']!=_0x42133e(0x1dd)&&typeof _0x5062cd['v']!='boolean'||'t'in _0x5062cd&&_0x5062cd['t']!=null&&!Ie(_0x5062cd['t'])?!0x1:!(_0x42133e(0x244)in _0x5062cd)||_0x5062cd[_0x42133e(0x244)]==null||typeof _0x5062cd[_0x42133e(0x244)]==_0x42133e(0x1d5);}function S(_0x58961a,_0x20376b){const _0x2772ea=_0x34c9f2;let _0x15783b=new Set(_0x20376b);return Object[_0x2772ea(0x24a)](_0x58961a)[_0x2772ea(0x2bb)](_0xcd09d7=>_0x15783b[_0x2772ea(0x253)](_0xcd09d7));}function Ie(_0x38487a){const _0x51fa00=_0x34c9f2;return typeof _0x38487a==_0x51fa00(0x1dd)&&Object[_0x51fa00(0x2a5)](_0xcdd757)['includes'](_0x38487a);}const Le=new Set([_0x1a4e6c[_0x34c9f2(0x26e)],_0x1a4e6c['TABLE_START'],_0x1a4e6c[_0x34c9f2(0x266)],_0x1a4e6c['TABLE_CELL_START'],_0x1a4e6c[_0x34c9f2(0x1e1)],_0x1a4e6c['TABLE_ROW_END'],_0x1a4e6c['TABLE_END'],_0x1a4e6c[_0x34c9f2(0x213)],_0x1a4e6c[_0x34c9f2(0x1e5)],_0x1a4e6c[_0x34c9f2(0x1da)],_0x1a4e6c[_0x34c9f2(0x2aa)],_0x1a4e6c[_0x34c9f2(0x205)],_0x1a4e6c[_0x34c9f2(0x288)],_0x1a4e6c[_0x34c9f2(0x23d)]]);var C=class extends Error{constructor(){super('Doc\x20Formula\x20range\x20cannot\x20cross\x20document\x20structure\x20boundaries');}};function Re(_0x4367e2){const _0x14cac0=_0x34c9f2;var _0x1f8799,_0x49d0f5;let _0x597e9c=_0x5e88d9['deepClone'](_0x4367e2[_0x14cac0(0x2a7)]),_0x2d3efb=j(_0x597e9c),{startOffset:_0x42c351,endOffset:_0x2f2aa1}=We(_0x2d3efb,_0x4367e2[_0x14cac0(0x262)],_0x4367e2[_0x14cac0(0x251)]);He(_0x2d3efb,_0x42c351,_0x2f2aa1);let _0x319100=((_0x1f8799=_0x2d3efb[_0x14cac0(0x2b7)])==null?void 0x0:_0x1f8799[_0x14cac0(0x229)](_0x358f49=>{const _0xcc7983=_0x14cac0;if(!w(_0x358f49))return!0x1;let _0x55efdd=_0x3c5aee(_0x358f49);return _0x55efdd[_0xcc7983(0x251)]>_0x42c351&&_0x55efdd['startOffset']<_0x2f2aa1;})[_0x14cac0(0x26d)](_0x4be67c=>_0x4be67c[_0x14cac0(0x212)]))??[];qe(_0x2d3efb,_0x42c351,_0x2f2aa1,''),_0x2d3efb[_0x14cac0(0x2b7)]=[...((_0x49d0f5=_0x2d3efb[_0x14cac0(0x2b7)])==null?void 0x0:_0x49d0f5[_0x14cac0(0x229)](_0x5a712f=>!_0x319100[_0x14cac0(0x279)](_0x5a712f[_0x14cac0(0x212)])&&_0x5a712f['rangeId']!==_0x4367e2[_0x14cac0(0x212)]))??[],Ue(_0x4367e2[_0x14cac0(0x212)],_0x42c351)]['sort']((_0x6ca7f0,_0x4bcd7f)=>_0x6ca7f0[_0x14cac0(0x25c)]-_0x4bcd7f[_0x14cac0(0x25c)]);let _0xf4a77c=E(_0x4367e2[_0x14cac0(0x1d4)]);return _0x319100[_0x14cac0(0x230)](_0x12ef5f=>{delete _0xf4a77c['formulas'][_0x12ef5f];}),_0xf4a77c['formulas'][_0x4367e2['rangeId']]=_0x5e88d9['deepClone'](_0x4367e2[_0x14cac0(0x1ef)]),{'nextDocumentData':_0x597e9c,'nextResource':_0xf4a77c,'cursorOffset':_0x42c351+0x1};}function ze(_0x51d67e){const _0x493497=_0x34c9f2;var _0x13b35f,_0x822e52;let _0x215297=_0x5e88d9['deepClone'](_0x51d67e[_0x493497(0x2a7)]),_0x3933f3=(_0x13b35f=j(_0x215297)[_0x493497(0x2b7)])==null?void 0x0:_0x13b35f[_0x493497(0x206)](_0x24c774=>_0x24c774[_0x493497(0x212)]===_0x51d67e[_0x493497(0x212)]&&w(_0x24c774));if(!_0x3933f3||!((_0x822e52=_0x51d67e['resource'])!=null&&_0x822e52[_0x493497(0x214)][_0x51d67e[_0x493497(0x212)]]))return null;let _0x484aa5=E(_0x51d67e[_0x493497(0x1d4)]);return _0x484aa5[_0x493497(0x214)][_0x51d67e['rangeId']]=_0x5e88d9[_0x493497(0x261)](_0x51d67e[_0x493497(0x1ef)]),{'nextDocumentData':_0x215297,'nextResource':_0x484aa5,'cursorOffset':_0x3933f3[_0x493497(0x285)]+0x1};}function Be(_0x4cd673){const _0x64d2a9=_0x34c9f2;let _0x5ea050=_0x5e88d9['deepClone'](_0x4cd673[_0x64d2a9(0x2a7)]),_0x3afff3=Je(_0x5ea050,_0x4cd673[_0x64d2a9(0x212)],_0x4cd673[_0x64d2a9(0x282)]??'');if(_0x3afff3==null)return null;let _0x398717=E(_0x4cd673['resource']);return delete _0x398717[_0x64d2a9(0x214)][_0x4cd673['rangeId']],{'nextDocumentData':_0x5ea050,'nextResource':_0x398717,'cursorOffset':_0x3afff3};}function Ve(_0x4e3475,_0x10d93a){const _0x48aa78=_0x34c9f2;var _0x4e0665;let _0x300331=_0x5e88d9['deepClone'](_0x4e3475),_0x1b9d3f=_0x300331[_0x48aa78(0x2ab)];if(!_0x1b9d3f)return _0x300331;let _0x4e6966=new Map(_0x10d93a[_0x48aa78(0x26d)](_0x333848=>[_0x333848[_0x48aa78(0x212)],_0x333848[_0x48aa78(0x282)]])),_0x342f78=((_0x4e0665=_0x1b9d3f[_0x48aa78(0x2b7)])==null?void 0x0:_0x4e0665['filter'](_0x850d77=>w(_0x850d77)&&_0x4e6966[_0x48aa78(0x253)](_0x850d77[_0x48aa78(0x212)]))[_0x48aa78(0x26f)]((_0x1d5bba,_0x3fcda6)=>_0x3fcda6[_0x48aa78(0x25c)]-_0x1d5bba[_0x48aa78(0x25c)]))??[];for(let _0x35edd5 of _0x342f78)Je(_0x300331,_0x35edd5[_0x48aa78(0x212)],_0x4e6966[_0x48aa78(0x1ff)](_0x35edd5[_0x48aa78(0x212)])??'');return _0x300331;}function w(_0x7fc17e){const _0x3b9d05=_0x34c9f2;var _0x120ec7;return(_0x7fc17e==null?void 0x0:_0x7fc17e['rangeType'])===_0xe8be5b[_0x3b9d05(0x245)]&&_0x7fc17e[_0x3b9d05(0x28e)]===!0x0&&((_0x120ec7=_0x7fc17e[_0x3b9d05(0x233)])==null?void 0x0:_0x120ec7[_0x3b9d05(0x1e2)])===_0x3b9d05(0x25e);}function T(_0x32ea0d,_0x25a674){const _0x24a3b9=_0x34c9f2;var _0x208f0a;return _0x32ea0d==null||(_0x208f0a=_0x32ea0d[_0x24a3b9(0x2b7)])==null?void 0x0:_0x208f0a[_0x24a3b9(0x206)](_0x1e0af3=>_0x1e0af3[_0x24a3b9(0x212)]===_0x25a674&&w(_0x1e0af3));}function He(_0x49cfb3,_0x7620,_0x46e0a1){const _0x19928e=_0x34c9f2;if(_0x7620===_0x46e0a1){if(Le[_0x19928e(0x253)](_0x49cfb3['dataStream'][_0x7620]))throw new C();return;}for(let _0x10e200=_0x7620;_0x10e200<_0x46e0a1;_0x10e200++)if(_0x49cfb3['dataStream'][_0x10e200]===_0x1a4e6c['PARAGRAPH']||Le[_0x19928e(0x253)](_0x49cfb3[_0x19928e(0x1de)][_0x10e200]))throw new C();}function Ue(_0x21b2c2,_0x4c36dc){const _0x3ca4be=_0x34c9f2;return{'startIndex':_0x4c36dc,'endIndex':_0x4c36dc,'rangeId':_0x21b2c2,'rangeType':_0xe8be5b[_0x3ca4be(0x245)],'wholeEntity':!0x0,'properties':{'kind':Me}};}function E(_0x10e67e){const _0x5ed176=_0x34c9f2;return _0x10e67e?_0x5e88d9[_0x5ed176(0x261)](_0x10e67e):b();}function We(_0xf05af,_0xd903f0,_0x5a7f7e){const _0x288a45=_0x34c9f2;let _0x463342=Ke(_0xf05af),_0x25c77f=_0xd903f0??_0x463342,_0x51d137=_0x5a7f7e??_0x25c77f;return{'startOffset':Ge(Math['min'](_0x25c77f,_0x51d137),_0x463342),'endOffset':Ge(Math[_0x288a45(0x241)](_0x25c77f,_0x51d137),_0x463342)};}function Ge(_0x2b0f63,_0x33eaae){const _0x21bc12=_0x34c9f2;return Math[_0x21bc12(0x241)](0x0,Math[_0x21bc12(0x232)](_0x2b0f63,_0x33eaae));}function Ke(_0x4d72cc){const _0x133c96=_0x34c9f2;return _0x4d72cc[_0x133c96(0x1de)][_0x133c96(0x1ed)](''+_0x1a4e6c[_0x133c96(0x2b3)]+_0x1a4e6c[_0x133c96(0x26e)])?Math['max'](0x0,_0x4d72cc[_0x133c96(0x1de)][_0x133c96(0x2c1)]-0x2):_0x4d72cc[_0x133c96(0x1de)][_0x133c96(0x1ed)](_0x1a4e6c[_0x133c96(0x26e)])?Math['max'](0x0,_0x4d72cc[_0x133c96(0x1de)][_0x133c96(0x2c1)]-0x1):_0x4d72cc['dataStream'][_0x133c96(0x2c1)];}function qe(_0x599212,_0xbeefc4,_0x19a7de,_0x598c4f){_0x19a7de>_0xbeefc4&&Xe(_0x599212,_0xbeefc4,_0x19a7de),Ye(_0x599212,_0xbeefc4,_0x598c4f);}function Je(_0x3875c9,_0x4bfec1,_0x359174){const _0x209b98=_0x34c9f2;var _0x25be50,_0x27c44c;let _0x3c3f09=j(_0x3875c9),_0xf6b51b=(_0x25be50=_0x3c3f09[_0x209b98(0x2b7)])==null?void 0x0:_0x25be50[_0x209b98(0x206)](_0x185825=>_0x185825[_0x209b98(0x212)]===_0x4bfec1&&w(_0x185825));if(!_0xf6b51b)return null;let _0x4f65d0=_0x3c5aee(_0xf6b51b);return qe(_0x3c3f09,_0x4f65d0[_0x209b98(0x262)],_0x4f65d0[_0x209b98(0x251)],_0x359174),_0x3c3f09[_0x209b98(0x2b7)]=(_0x27c44c=_0x3c3f09[_0x209b98(0x2b7)])==null?void 0x0:_0x27c44c[_0x209b98(0x229)](_0x366a58=>_0x366a58[_0x209b98(0x212)]!==_0x4bfec1),_0x4f65d0['startOffset']+_0x359174[_0x209b98(0x2c1)];}function Ye(_0x3093d3,_0x424786,_0x2df869){const _0x5f4dd0=_0x34c9f2;_0x2df869&&(_0x3093d3[_0x5f4dd0(0x1de)]=''+_0x3093d3['dataStream']['slice'](0x0,_0x424786)+_0x2df869+_0x3093d3[_0x5f4dd0(0x1de)][_0x5f4dd0(0x23c)](_0x424786),Ze(_0x3093d3,_0x424786,_0x2df869['length']));}function Xe(_0x765c62,_0x524822,_0x3366d1){const _0x21f5fb=_0x34c9f2;let _0x5bddea=_0x3366d1-_0x524822;_0x765c62['dataStream']=''+_0x765c62[_0x21f5fb(0x1de)]['slice'](0x0,_0x524822)+_0x765c62[_0x21f5fb(0x1de)][_0x21f5fb(0x23c)](_0x3366d1),Qe(_0x765c62,_0x524822,_0x5bddea);}function Ze(_0x406e40,_0x58b2c1,_0x3cc0af){const _0x18c5eb=_0x34c9f2;_0x406e40['paragraphs']=D(_0x406e40[_0x18c5eb(0x27f)],_0x58b2c1,_0x3cc0af),_0x406e40[_0x18c5eb(0x23e)]=D(_0x406e40[_0x18c5eb(0x23e)],_0x58b2c1,_0x3cc0af),_0x406e40[_0x18c5eb(0x27d)]=D(_0x406e40['customBlocks'],_0x58b2c1,_0x3cc0af),_0x406e40[_0x18c5eb(0x20b)]=$e(_0x406e40[_0x18c5eb(0x20b)],_0x58b2c1,_0x3cc0af),_0x406e40[_0x18c5eb(0x221)]=et(_0x406e40[_0x18c5eb(0x221)],_0x58b2c1,_0x3cc0af),_0x406e40['columnGroups']=k(_0x406e40[_0x18c5eb(0x246)],_0x58b2c1,_0x3cc0af),_0x406e40[_0x18c5eb(0x2b7)]=k(_0x406e40[_0x18c5eb(0x2b7)],_0x58b2c1,_0x3cc0af),_0x406e40['customDecorations']=k(_0x406e40[_0x18c5eb(0x2ac)],_0x58b2c1,_0x3cc0af),_0x406e40[_0x18c5eb(0x20c)]=k(_0x406e40[_0x18c5eb(0x20c)],_0x58b2c1,_0x3cc0af);}function Qe(_0x538499,_0x443f2f,_0x2a98e2){const _0x2c1b57=_0x34c9f2;var _0x4456a5,_0x560fd2;_0x538499[_0x2c1b57(0x27f)]=O(_0x538499['paragraphs'],_0x443f2f,_0x2a98e2),_0x538499[_0x2c1b57(0x23e)]=O(_0x538499['sectionBreaks'],_0x443f2f,_0x2a98e2),_0x538499[_0x2c1b57(0x27d)]=O(_0x538499[_0x2c1b57(0x27d)],_0x443f2f,_0x2a98e2),_0x538499[_0x2c1b57(0x20b)]=(_0x4456a5=tt((_0x560fd2=_0x538499[_0x2c1b57(0x20b)])==null?void 0x0:_0x560fd2[_0x2c1b57(0x26d)](_0xbdc334=>({..._0xbdc334,'startIndex':_0xbdc334['st'],'endIndex':_0xbdc334['ed']})),_0x443f2f,_0x2a98e2))==null?void 0x0:_0x4456a5['map'](_0x49762b=>{let {startIndex:_0x44cd3f,endIndex:_0x30d028,..._0x4f1961}=_0x49762b;return{..._0x4f1961,'st':_0x44cd3f,'ed':_0x30d028};}),_0x538499[_0x2c1b57(0x221)]=tt(_0x538499[_0x2c1b57(0x221)],_0x443f2f,_0x2a98e2),_0x538499['columnGroups']=A(_0x538499[_0x2c1b57(0x246)],_0x443f2f,_0x2a98e2),_0x538499[_0x2c1b57(0x2b7)]=A(_0x538499[_0x2c1b57(0x2b7)],_0x443f2f,_0x2a98e2),_0x538499['customDecorations']=A(_0x538499[_0x2c1b57(0x2ac)],_0x443f2f,_0x2a98e2),_0x538499[_0x2c1b57(0x20c)]=A(_0x538499['blockRanges'],_0x443f2f,_0x2a98e2);}function D(_0x3880f9,_0xc03d8e,_0x924146){const _0x4c7631=_0x34c9f2;return _0x3880f9==null?void 0x0:_0x3880f9[_0x4c7631(0x26d)](_0x5a25fc=>_0x5a25fc[_0x4c7631(0x25c)]>=_0xc03d8e?{..._0x5a25fc,'startIndex':_0x5a25fc[_0x4c7631(0x25c)]+_0x924146}:_0x5a25fc);}function O(_0x2b6001,_0x21b2c4,_0x545c3e){const _0x4ab09b=_0x34c9f2;let _0x52bdac=_0x21b2c4+_0x545c3e;return _0x2b6001==null?void 0x0:_0x2b6001[_0x4ab09b(0x26d)](_0x4352b4=>_0x4352b4[_0x4ab09b(0x25c)]>=_0x21b2c4&&_0x4352b4[_0x4ab09b(0x25c)]<_0x52bdac?null:_0x4352b4['startIndex']>=_0x52bdac?{..._0x4352b4,'startIndex':_0x4352b4['startIndex']-_0x545c3e}:_0x4352b4)[_0x4ab09b(0x229)](_0x1a459c=>_0x1a459c!=null);}function $e(_0x4b1b10,_0x16fd65,_0x1511a0){return _0x4b1b10==null?void 0x0:_0x4b1b10['map'](_0x25846d=>_0x25846d['st']>=_0x16fd65?{..._0x25846d,'st':_0x25846d['st']+_0x1511a0,'ed':_0x25846d['ed']+_0x1511a0}:_0x25846d['ed']>_0x16fd65?{..._0x25846d,'ed':_0x25846d['ed']+_0x1511a0}:_0x25846d);}function _0x9a42(_0xf4c610,_0x5919e4){_0xf4c610=_0xf4c610-0x1ce;const _0x35eef1=_0x35ee();let _0x9a4267=_0x35eef1[_0xf4c610];return _0x9a4267;}function k(_0x4a56f3,_0x35e381,_0x4ee161){const _0x3f295a=_0x34c9f2;return _0x4a56f3==null?void 0x0:_0x4a56f3[_0x3f295a(0x26d)](_0x2dc9cf=>_0x2a05e1(_0x2dc9cf,_0x35e381,_0x4ee161));}function et(_0x291657,_0x26c671,_0x1402e7){const _0xc8b6ff=_0x34c9f2;return _0x291657==null?void 0x0:_0x291657[_0xc8b6ff(0x26d)](_0x9112c2=>_0x5e2c6d(_0x9112c2,_0x26c671,_0x1402e7));}function A(_0x528756,_0x4bc962,_0x46dbd2){return _0x528756==null?void 0x0:_0x528756['map'](_0x3c7cdb=>_0x16ca5b(_0x3c7cdb,_0x4bc962,_0x46dbd2))['filter'](_0xb02150=>_0xb02150!=null);}function tt(_0x2ab2ca,_0x1fe1ac,_0x3888da){const _0x34a89a=_0x34c9f2;return _0x2ab2ca==null?void 0x0:_0x2ab2ca[_0x34a89a(0x26d)](_0x58df2a=>_0x4483d1(_0x58df2a,_0x1fe1ac,_0x3888da))[_0x34a89a(0x229)](_0x33d38a=>_0x33d38a!=null);}function j(_0xb4cdcd){const _0x43acd3=_0x34c9f2;if(!_0xb4cdcd[_0x43acd3(0x2ab)])throw Error(_0x43acd3(0x1d7));return _0xb4cdcd[_0x43acd3(0x2ab)];}function M(_0x279f26){'@babel/helpers - typeof';const _0x4831a8=_0x34c9f2;return M=typeof Symbol=='function'&&typeof Symbol[_0x4831a8(0x20e)]==_0x4831a8(0x200)?function(_0x16fce7){return typeof _0x16fce7;}:function(_0x1f3b53){const _0x389e86=_0x4831a8;return _0x1f3b53&&typeof Symbol=='function'&&_0x1f3b53['constructor']===Symbol&&_0x1f3b53!==Symbol[_0x389e86(0x28a)]?'symbol':typeof _0x1f3b53;},M(_0x279f26);}function nt(_0x1f7a0c,_0x75a7e){const _0x44e143=_0x34c9f2;if(M(_0x1f7a0c)!='object'||!_0x1f7a0c)return _0x1f7a0c;var _0x3f359d=_0x1f7a0c[Symbol[_0x44e143(0x21d)]];if(_0x3f359d!==void 0x0){var _0x3cae03=_0x3f359d['call'](_0x1f7a0c,_0x75a7e||_0x44e143(0x25b));if(M(_0x3cae03)!='object')return _0x3cae03;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x75a7e==='string'?String:Number)(_0x1f7a0c);}function rt(_0xfc529a){const _0x3f4ac7=_0x34c9f2;var _0x47906b=nt(_0xfc529a,'string');return M(_0x47906b)==_0x3f4ac7(0x200)?_0x47906b:_0x47906b+'';}function N(_0x116ce8,_0x552aa6,_0x269d6a){const _0x25dcb4=_0x34c9f2;return(_0x552aa6=rt(_0x552aa6))in _0x116ce8?Object[_0x25dcb4(0x207)](_0x116ce8,_0x552aa6,{'value':_0x269d6a,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x116ce8[_0x552aa6]=_0x269d6a,_0x116ce8;}var P=class extends _0x49a82f{constructor(..._0x29f506){const _0x228f14=_0x34c9f2;super(..._0x29f506),N(this,_0x228f14(0x24f),new Map()),N(this,_0x228f14(0x21e),new Map()),N(this,_0x228f14(0x2b5),new Map()),N(this,_0x228f14(0x204),new _0x2c9ea2()),N(this,_0x228f14(0x2ba),this[_0x228f14(0x204)]['asObservable']());}[_0x34c9f2(0x2a3)](_0x50e9d3,_0x53287c){const _0x3159e5=_0x34c9f2;var _0xf98001;let _0x2d30b5=(_0xf98001=this[_0x3159e5(0x24f)][_0x3159e5(0x1ff)](_0x50e9d3))==null?void 0x0:_0xf98001[_0x3159e5(0x214)][_0x53287c];return _0x2d30b5?_0x5e88d9[_0x3159e5(0x261)](_0x2d30b5):void 0x0;}['getFormulas'](_0x357214){const _0x22ec8b=_0x34c9f2;var _0x234184;return _0x5e88d9['deepClone'](((_0x234184=this[_0x22ec8b(0x24f)][_0x22ec8b(0x1ff)](_0x357214))==null?void 0x0:_0x234184['formulas'])??{});}['getResource'](_0x116e08){const _0x2cd050=_0x34c9f2;let _0x250eb8=this[_0x2cd050(0x24f)][_0x2cd050(0x1ff)](_0x116e08);return _0x250eb8?_0x5e88d9[_0x2cd050(0x261)](_0x250eb8):void 0x0;}[_0x34c9f2(0x26a)](_0x5d376c,_0x3fd416,_0x16a52a){const _0x39a52d=_0x34c9f2;return this[_0x39a52d(0x28f)](_0x5d376c,{[_0x3fd416]:_0x16a52a});}[_0x34c9f2(0x295)](_0x1256be,_0x3274c0){const _0x16c6e4=_0x34c9f2;return this[_0x16c6e4(0x2b5)][_0x16c6e4(0x253)](_0x1256be)||!x(_0x3274c0)?!0x1:(this[_0x16c6e4(0x24f)][_0x16c6e4(0x252)](_0x1256be,_0x5e88d9[_0x16c6e4(0x261)](_0x3274c0)),this[_0x16c6e4(0x204)][_0x16c6e4(0x22b)]({'unitId':_0x1256be}),!0x0);}[_0x34c9f2(0x28f)](_0x2f985c,_0x2da324){const _0x257fb4=_0x34c9f2;if(this[_0x257fb4(0x2b5)]['has'](_0x2f985c)||!Object[_0x257fb4(0x24a)](_0x2da324)[_0x257fb4(0x2c1)]||!x({'schemaVersion':0x1,'formulas':_0x2da324}))return!0x1;let _0x20c10a=this[_0x257fb4(0x24f)][_0x257fb4(0x1ff)](_0x2f985c)??b(),_0x355138=_0x5e88d9[_0x257fb4(0x261)](_0x20c10a);return Object['assign'](_0x355138[_0x257fb4(0x214)],_0x5e88d9[_0x257fb4(0x261)](_0x2da324)),this[_0x257fb4(0x24f)][_0x257fb4(0x252)](_0x2f985c,_0x355138),this[_0x257fb4(0x204)][_0x257fb4(0x22b)]({'unitId':_0x2f985c,'rangeIds':Object[_0x257fb4(0x24a)](_0x2da324)}),!0x0;}[_0x34c9f2(0x21a)](_0x5bbdcd,_0x2443ee){const _0x1ff973=_0x34c9f2;if(this[_0x1ff973(0x2b5)][_0x1ff973(0x253)](_0x5bbdcd))return!0x1;let _0x7ca67=this[_0x1ff973(0x24f)][_0x1ff973(0x1ff)](_0x5bbdcd);if(!(_0x7ca67!=null&&_0x7ca67[_0x1ff973(0x214)][_0x2443ee]))return!0x1;let _0x996ad4=_0x5e88d9[_0x1ff973(0x261)](_0x7ca67);return delete _0x996ad4[_0x1ff973(0x214)][_0x2443ee],this[_0x1ff973(0x24f)]['set'](_0x5bbdcd,_0x996ad4),this[_0x1ff973(0x204)][_0x1ff973(0x22b)]({'unitId':_0x5bbdcd,'rangeIds':[_0x2443ee]}),!0x0;}['load'](_0x5074d3,_0x7d6a95){const _0x438ab1=_0x34c9f2;return _0x7d6a95&&typeof _0x7d6a95==_0x438ab1(0x224)&&_0x438ab1(0x1f8)in _0x7d6a95&&_0x7d6a95[_0x438ab1(0x1f8)]!==0x1?(this['_preserveInvalid'](_0x5074d3,_0x7d6a95,_0x438ab1(0x243)),!0x1):x(_0x7d6a95)?(this[_0x438ab1(0x24f)][_0x438ab1(0x252)](_0x5074d3,_0x5e88d9[_0x438ab1(0x261)](_0x7d6a95)),this[_0x438ab1(0x21e)][_0x438ab1(0x287)](_0x5074d3),this[_0x438ab1(0x2b5)][_0x438ab1(0x287)](_0x5074d3),this[_0x438ab1(0x204)][_0x438ab1(0x22b)]({'unitId':_0x5074d3}),!0x0):(this[_0x438ab1(0x24d)](_0x5074d3,_0x7d6a95,_0x438ab1(0x273)),!0x1);}[_0x34c9f2(0x27e)](_0x4640ac){const _0x3f3a59=_0x34c9f2;let _0x586efa=this[_0x3f3a59(0x24f)][_0x3f3a59(0x1ff)](_0x4640ac);return _0x586efa?_0x5e88d9[_0x3f3a59(0x261)](_0x586efa):this[_0x3f3a59(0x21e)][_0x3f3a59(0x253)](_0x4640ac)?_0x5e88d9[_0x3f3a59(0x261)](this[_0x3f3a59(0x21e)][_0x3f3a59(0x1ff)](_0x4640ac)):b();}[_0x34c9f2(0x1d3)](_0x1a6678){const _0x54e3ed=_0x34c9f2;return this[_0x54e3ed(0x2b5)][_0x54e3ed(0x1ff)](_0x1a6678);}[_0x34c9f2(0x2c3)](_0x5f5217){const _0x6793e8=_0x34c9f2;this[_0x6793e8(0x24f)][_0x6793e8(0x287)](_0x5f5217),this[_0x6793e8(0x21e)][_0x6793e8(0x287)](_0x5f5217),this[_0x6793e8(0x2b5)][_0x6793e8(0x287)](_0x5f5217),this['_change$'][_0x6793e8(0x22b)]({'unitId':_0x5f5217});}[_0x34c9f2(0x1d1)](){const _0x5a2c84=_0x34c9f2;this[_0x5a2c84(0x24f)]['clear'](),this['_rawResources'][_0x5a2c84(0x26c)](),this[_0x5a2c84(0x2b5)][_0x5a2c84(0x26c)](),this[_0x5a2c84(0x204)][_0x5a2c84(0x294)](),super[_0x5a2c84(0x1d1)]();}[_0x34c9f2(0x24d)](_0x417c16,_0x188661,_0x5c1ce4){const _0x56b595=_0x34c9f2;this[_0x56b595(0x24f)][_0x56b595(0x287)](_0x417c16),this[_0x56b595(0x21e)][_0x56b595(0x252)](_0x417c16,_0x5e88d9['deepClone'](_0x188661)),this[_0x56b595(0x2b5)]['set'](_0x417c16,_0x5c1ce4),this[_0x56b595(0x204)]['next']({'unitId':_0x417c16});}};let it=function(_0x457909){const _0x55caeb=_0x34c9f2;return _0x457909[_0x55caeb(0x21c)]='empty',_0x457909['PENDING']='pending',_0x457909['SUCCESS']=_0x55caeb(0x217),_0x457909[_0x55caeb(0x250)]=_0x55caeb(0x2c7),_0x457909;}({});function F(_0x3b4f2f,_0x218320){return function(_0x52f7ca,_0x5ee1eb){_0x218320(_0x52f7ca,_0x5ee1eb,_0x3b4f2f);};}function I(_0x7110f2,_0x273d5e,_0x5cc3cf,_0x2688f9){const _0x2829c9=_0x34c9f2;var _0x387439=arguments[_0x2829c9(0x2c1)],_0x5d4902=_0x387439<0x3?_0x273d5e:_0x2688f9===null?_0x2688f9=Object[_0x2829c9(0x1ce)](_0x273d5e,_0x5cc3cf):_0x2688f9,_0x573103;if(typeof Reflect==_0x2829c9(0x224)&&typeof Reflect[_0x2829c9(0x2c4)]=='function')_0x5d4902=Reflect[_0x2829c9(0x2c4)](_0x7110f2,_0x273d5e,_0x5cc3cf,_0x2688f9);else{for(var _0x3c9bb5=_0x7110f2['length']-0x1;_0x3c9bb5>=0x0;_0x3c9bb5--)(_0x573103=_0x7110f2[_0x3c9bb5])&&(_0x5d4902=(_0x387439<0x3?_0x573103(_0x5d4902):_0x387439>0x3?_0x573103(_0x273d5e,_0x5cc3cf,_0x5d4902):_0x573103(_0x273d5e,_0x5cc3cf))||_0x5d4902);}return _0x387439>0x3&&_0x5d4902&&Object[_0x2829c9(0x207)](_0x273d5e,_0x5cc3cf,_0x5d4902),_0x5d4902;}let L=class extends _0x49a82f{constructor(_0x1d9b31,_0x81eb5c,_0x141e68){const _0x580bbf=_0x34c9f2;super(),this['_model']=_0x1d9b31,this[_0x580bbf(0x27b)]=_0x81eb5c,this[_0x580bbf(0x23f)]=_0x141e68,N(this,_0x580bbf(0x1df),new Map()),N(this,_0x580bbf(0x1e9),new Map()),N(this,'_presentationChanged$',new _0x2c9ea2()),N(this,_0x580bbf(0x268),this[_0x580bbf(0x280)][_0x580bbf(0x2b2)]()),this[_0x580bbf(0x249)](this[_0x580bbf(0x27b)][_0x580bbf(0x2bc)][_0x580bbf(0x283)](_0x2743d1=>{const _0x31b610=_0x580bbf;for(let _0x29004a of Object['values'](_0x2743d1))for(let _0x11f271 of Object[_0x31b610(0x2a5)](_0x29004a))_0x11f271['forEach'](_0x38e2d7=>this[_0x31b610(0x1f1)](_0x38e2d7));}));}[_0x34c9f2(0x234)](_0x513a3e){const _0x37c924=_0x34c9f2;var _0x315ae8;let _0x598a60=_0x513a3e[_0x37c924(0x1f2)](),_0x4e3b9e=((_0x315ae8=_0x513a3e[_0x37c924(0x281)]()[_0x37c924(0x2ab)])==null||(_0x315ae8=_0x315ae8[_0x37c924(0x2b7)])==null?void 0x0:_0x315ae8[_0x37c924(0x229)](w))??[],_0x4aa1c2=this['_model'][_0x37c924(0x22e)](_0x598a60),_0x1626ff=new Set();for(let _0x34e59b of _0x4e3b9e){let _0x5a729c=_0x4aa1c2[_0x34e59b[_0x37c924(0x212)]];_0x5a729c&&(_0x1626ff[_0x37c924(0x21b)](R(_0x598a60,_0x34e59b['rangeId'])),this[_0x37c924(0x2a4)]({'unitId':_0x598a60,'rangeId':_0x34e59b[_0x37c924(0x212)]},_0x5a729c));}for(let _0x191d4e of Array[_0x37c924(0x1f4)](this['_registrations'][_0x37c924(0x2a5)]()))_0x191d4e['unitId']===_0x598a60&&!_0x1626ff[_0x37c924(0x253)](R(_0x191d4e['unitId'],_0x191d4e['rangeId']))&&this['unregister'](_0x191d4e);}[_0x34c9f2(0x2a4)](_0x3033f3,_0x1f544b){const _0xdc32c8=_0x34c9f2;let _0x5e8dbe=R(_0x3033f3['unitId'],_0x3033f3[_0xdc32c8(0x212)]),_0x22485b=this[_0xdc32c8(0x1df)][_0xdc32c8(0x1ff)](_0x5e8dbe),_0x57bae9=this[_0xdc32c8(0x23f)][_0xdc32c8(0x277)](_0x3033f3['unitId']);if(_0x22485b&&_0x22485b['config'][_0xdc32c8(0x20f)]===_0x1f544b[_0xdc32c8(0x20f)]&&_0x22485b[_0xdc32c8(0x2bd)]===_0x57bae9){_0x22485b[_0xdc32c8(0x1ef)]=_0x1f544b;let _0x66b01a=_0x22485b['formulaId']?this[_0xdc32c8(0x27b)][_0xdc32c8(0x263)](_0x22485b[_0xdc32c8(0x24b)],_0x22485b[_0xdc32c8(0x24b)],_0x22485b[_0xdc32c8(0x20a)])??void 0x0:void 0x0;_0x22485b[_0xdc32c8(0x2a1)]=_0x66b01a,this[_0xdc32c8(0x254)](_0x5e8dbe,z(_0x1f544b,_0x66b01a));return;}_0x22485b!=null&&_0x22485b[_0xdc32c8(0x20a)]&&this[_0xdc32c8(0x1eb)](_0x22485b);let _0x2ee832={..._0x3033f3,'config':_0x1f544b,'referenceRevision':_0x57bae9,'presentation':z(_0x1f544b,void 0x0)};if(this['_registrations']['set'](_0x5e8dbe,_0x2ee832),!_0x1f544b['formula'][_0xdc32c8(0x27c)]())return;let _0x5a8fbf=this[_0xdc32c8(0x27b)]['registerFormulaWithRange'](_0x3033f3[_0xdc32c8(0x24b)],_0x3033f3[_0xdc32c8(0x24b)],_0x1f544b[_0xdc32c8(0x20f)],void 0x0,{'rangeId':_0x3033f3[_0xdc32c8(0x212)]},_0x20565b[_0xdc32c8(0x239)],_0x3033f3[_0xdc32c8(0x212)]);_0x2ee832[_0xdc32c8(0x20a)]=_0x5a8fbf,this[_0xdc32c8(0x1e9)][_0xdc32c8(0x252)](_0x5a8fbf,_0x5e8dbe);}[_0x34c9f2(0x270)](_0x226e95){const _0x2c27c9=_0x34c9f2;let _0x327668=R(_0x226e95[_0x2c27c9(0x24b)],_0x226e95['rangeId']),_0x3648db=this[_0x2c27c9(0x1df)][_0x2c27c9(0x1ff)](_0x327668);_0x3648db&&(this[_0x2c27c9(0x1eb)](_0x3648db),this[_0x2c27c9(0x1df)][_0x2c27c9(0x287)](_0x327668));}[_0x34c9f2(0x28c)](_0x39c1f2){const _0x14ccf3=_0x34c9f2;for(let _0x19bbe8 of Array[_0x14ccf3(0x1f4)](this[_0x14ccf3(0x1df)]['values']()))_0x19bbe8[_0x14ccf3(0x24b)]===_0x39c1f2&&this[_0x14ccf3(0x270)](_0x19bbe8);}[_0x34c9f2(0x1cf)](_0x2ef0aa){const _0x522896=_0x34c9f2;var _0x1763c0;return(_0x1763c0=this[_0x522896(0x1df)]['get'](R(_0x2ef0aa[_0x522896(0x24b)],_0x2ef0aa['rangeId'])))==null?void 0x0:_0x1763c0[_0x522896(0x29f)];}[_0x34c9f2(0x25a)](_0x1250b3){const _0x52a6d4=_0x34c9f2;let _0x4d246b=this[_0x52a6d4(0x1df)]['get'](R(_0x1250b3['unitId'],_0x1250b3[_0x52a6d4(0x212)]));return _0x4d246b?B(_0x4d246b):void 0x0;}[_0x34c9f2(0x209)](){const _0x33b7a4=_0x34c9f2;return Array[_0x33b7a4(0x1f4)](this[_0x33b7a4(0x1df)][_0x33b7a4(0x2a5)](),_0x5ec8e7=>({'identity':{'unitId':_0x5ec8e7[_0x33b7a4(0x24b)],'rangeId':_0x5ec8e7[_0x33b7a4(0x212)]},'config':_0x5ec8e7[_0x33b7a4(0x1ef)],'referenceRevision':_0x5ec8e7[_0x33b7a4(0x2bd)],..._0x5ec8e7[_0x33b7a4(0x2a1)]?{'liveResult':_0x5ec8e7[_0x33b7a4(0x2a1)]}:null}));}['dispose'](){const _0x494455=_0x34c9f2;for(let _0x5d7551 of this['_registrations'][_0x494455(0x2a5)]())this[_0x494455(0x1eb)](_0x5d7551);this[_0x494455(0x1df)][_0x494455(0x26c)](),this['_formulaKeys']['clear'](),this[_0x494455(0x280)]['complete'](),super[_0x494455(0x1d1)]();}[_0x34c9f2(0x1f1)](_0x425333){const _0x2f3376=_0x34c9f2;let _0x15d9d9=this[_0x2f3376(0x1e9)]['get'](_0x425333[_0x2f3376(0x20a)]),_0xf2fed=_0x15d9d9?this['_registrations'][_0x2f3376(0x1ff)](_0x15d9d9):void 0x0;_0x15d9d9&&_0xf2fed&&(_0xf2fed[_0x2f3376(0x2a1)]=_0x425333,this['_setPresentation'](_0x15d9d9,z(_0xf2fed[_0x2f3376(0x1ef)],_0x425333)));}['_setPresentation'](_0x1cef04,_0x4ea0ba){const _0x1be4bd=_0x34c9f2;var _0x3de0be,_0x5768b2;let _0x339c05=this[_0x1be4bd(0x1df)]['get'](_0x1cef04);if(!_0x339c05||at(_0x339c05[_0x1be4bd(0x29f)],_0x4ea0ba))return;let _0x256739=_0x339c05['presentation'],_0x1b7389=B(_0x339c05);_0x339c05[_0x1be4bd(0x29f)]=_0x4ea0ba,this[_0x1be4bd(0x280)][_0x1be4bd(0x22b)]({'unitId':_0x339c05[_0x1be4bd(0x24b)],'rangeId':_0x339c05[_0x1be4bd(0x212)],'presentation':_0x4ea0ba,'previousPresentation':_0x256739,'result':B(_0x339c05),'previousResult':{..._0x1b7389,..._0x256739,'value':(_0x3de0be=_0x256739[_0x1be4bd(0x236)])==null?void 0x0:_0x3de0be['v'],'valueType':((_0x5768b2=_0x256739[_0x1be4bd(0x236)])==null?void 0x0:_0x5768b2['t'])??void 0x0}});}[_0x34c9f2(0x1eb)](_0x3a2f98){const _0x1a4077=_0x34c9f2;_0x3a2f98['formulaId']&&(this['_registrationService']['deleteFormula'](_0x3a2f98[_0x1a4077(0x24b)],_0x3a2f98['unitId'],[_0x3a2f98['formulaId']]),this[_0x1a4077(0x1e9)][_0x1a4077(0x287)](_0x3a2f98['formulaId']));}};L=I([F(0x0,_0x5c5393(P)),F(0x1,_0x5c5393(_0x2bd31f)),F(0x2,_0x5c5393(_0x598fe))],L);function R(_0x53e74d,_0x16d5d2){return _0x53e74d+'\x00'+_0x16d5d2;}function z(_0x4781b1,_0x476ead){const _0x3ae270=_0x34c9f2;return _0x44276e({'numberFormat':_0x4781b1['numberFormat'],'lastValue':_0x4781b1[_0x3ae270(0x21f)],'result':_0x476ead});}function B(_0x15b0c7){const _0x29c9b9=_0x34c9f2;var _0x566370,_0x471e10,_0x4139fb;let _0x31532b=_0x15b0c7['presentation'],_0x3ed5b6=_0x15b0c7[_0x29c9b9(0x1ef)]['formula']['trim']()?_0x31532b[_0x29c9b9(0x1fd)]||_0x31532b[_0x29c9b9(0x236)]==null?_0x29c9b9(0x2b1):((_0x566370=_0x15b0c7[_0x29c9b9(0x2a1)])==null?void 0x0:_0x566370[_0x29c9b9(0x216)])===_0x51281a['ERROR']?_0x29c9b9(0x2c7):_0x29c9b9(0x217):_0x29c9b9(0x2bf);return{..._0x31532b,'status':_0x3ed5b6,'value':(_0x471e10=_0x31532b['cell'])==null?void 0x0:_0x471e10['v'],'valueType':((_0x4139fb=_0x31532b['cell'])==null?void 0x0:_0x4139fb['t'])??void 0x0};}function at(_0x336c71,_0x1abc89){const _0x2b0358=_0x34c9f2;var _0x2089c1,_0x5f0168,_0x28bf52,_0xaf302a;return _0x336c71[_0x2b0358(0x282)]===_0x1abc89[_0x2b0358(0x282)]&&_0x336c71[_0x2b0358(0x231)]===_0x1abc89[_0x2b0358(0x231)]&&_0x336c71['pattern']===_0x1abc89[_0x2b0358(0x244)]&&_0x336c71[_0x2b0358(0x218)]===_0x1abc89['source']&&_0x336c71[_0x2b0358(0x1fd)]===_0x1abc89[_0x2b0358(0x1fd)]&&((_0x2089c1=_0x336c71[_0x2b0358(0x236)])==null?void 0x0:_0x2089c1['t'])===((_0x5f0168=_0x1abc89[_0x2b0358(0x236)])==null?void 0x0:_0x5f0168['t'])&&Object['is']((_0x28bf52=_0x336c71[_0x2b0358(0x236)])==null?void 0x0:_0x28bf52['v'],(_0xaf302a=_0x1abc89[_0x2b0358(0x236)])==null?void 0x0:_0xaf302a['v']);}const ot={'id':_0x34c9f2(0x203),'type':_0x3d8c4d[_0x34c9f2(0x2b6)],'handler':(_0x3c4786,_0x3e7cd0)=>!(_0x3e7cd0!=null&&_0x3e7cd0['unitId'])||!_0x3e7cd0[_0x34c9f2(0x212)]||!_0x3e7cd0[_0x34c9f2(0x1ef)]?!0x1:_0x3c4786['get'](P)['setFormula'](_0x3e7cd0[_0x34c9f2(0x24b)],_0x3e7cd0[_0x34c9f2(0x212)],_0x3e7cd0[_0x34c9f2(0x1ef)])},st={'id':_0x34c9f2(0x2be),'type':_0x3d8c4d[_0x34c9f2(0x2b6)],'handler':(_0x51b61e,_0x36e172)=>!(_0x36e172!=null&&_0x36e172[_0x34c9f2(0x24b)])||!_0x36e172[_0x34c9f2(0x212)]?!0x1:_0x51b61e[_0x34c9f2(0x1ff)](P)[_0x34c9f2(0x21a)](_0x36e172['unitId'],_0x36e172[_0x34c9f2(0x212)])},V={'id':_0x34c9f2(0x2c6),'type':_0x3d8c4d[_0x34c9f2(0x2b6)],'handler':(_0x420b11,_0x40f4a1)=>!(_0x40f4a1!=null&&_0x40f4a1['unitId'])||!_0x40f4a1['resource']?!0x1:_0x420b11[_0x34c9f2(0x1ff)](P)['setResource'](_0x40f4a1[_0x34c9f2(0x24b)],_0x40f4a1[_0x34c9f2(0x1d4)])},H={'id':_0x34c9f2(0x291),'type':_0x3d8c4d['MUTATION'],'handler':(_0x113afa,_0x305bbe)=>{const _0x24c86d=_0x34c9f2;if(!(_0x305bbe!=null&&_0x305bbe['unitId'])||!_0x305bbe[_0x24c86d(0x276)][_0x24c86d(0x2c1)])return!0x1;let _0x56dbcc=_0x113afa['get'](P),_0x10ea08=_0x113afa[_0x24c86d(0x1ff)](_0x598fe),_0x254226=_0x56dbcc[_0x24c86d(0x284)](_0x305bbe[_0x24c86d(0x24b)]);if(!_0x254226)return!0x1;let _0x546e80=_0x5e88d9[_0x24c86d(0x261)](_0x254226),_0x550af7=!0x1;for(let _0x3f6fb8 of _0x305bbe[_0x24c86d(0x276)]){var _0x39b2be,_0x2538fa,_0x36f142,_0x360341;let _0x14614a=_0x546e80[_0x24c86d(0x214)][_0x3f6fb8['rangeId']];_0x14614a&&_0x14614a[_0x24c86d(0x20f)]===_0x3f6fb8['expectedFormula']&&((_0x39b2be=_0x14614a[_0x24c86d(0x271)])==null?void 0x0:_0x39b2be[_0x24c86d(0x244)])===_0x3f6fb8['expectedNumberFormat']&&_0x10ea08[_0x24c86d(0x277)](_0x305bbe[_0x24c86d(0x24b)])===_0x3f6fb8['expectedReferenceRevision']&&(((_0x2538fa=_0x14614a[_0x24c86d(0x21f)])==null?void 0x0:_0x2538fa['v'])!==_0x3f6fb8[_0x24c86d(0x21f)]['v']||((_0x36f142=_0x14614a[_0x24c86d(0x21f)])==null?void 0x0:_0x36f142['t'])!==_0x3f6fb8[_0x24c86d(0x21f)]['t']||((_0x360341=_0x14614a['lastValue'])==null?void 0x0:_0x360341[_0x24c86d(0x244)])!==_0x3f6fb8[_0x24c86d(0x21f)][_0x24c86d(0x244)])&&(_0x14614a['lastValue']=_0x5e88d9[_0x24c86d(0x261)](_0x3f6fb8[_0x24c86d(0x21f)]),_0x550af7=!0x0);}return!_0x550af7||_0x56dbcc[_0x24c86d(0x295)](_0x305bbe[_0x24c86d(0x24b)],_0x546e80);}},U={'id':_0x34c9f2(0x1fb),'type':_0x3d8c4d['COMMAND'],'handler':(_0x17e9eb,_0x54120e)=>{const _0x51e4d9=_0x34c9f2;if(!(_0x54120e!=null&&_0x54120e[_0x51e4d9(0x20f)]['trim']()))return!0x1;let _0x41b37a=q(_0x17e9eb,_0x54120e[_0x51e4d9(0x24b)],'');if(!_0x41b37a)return!0x1;let _0x4395b7=ft(_0x54120e[_0x51e4d9(0x255)],_0x41b37a[_0x51e4d9(0x2ab)],dt(_0x17e9eb,_0x41b37a[_0x51e4d9(0x24b)]));if(!_0x4395b7)return!0x1;let _0x570138=pt(_0x17e9eb,_0x41b37a['unitId'],_0x54120e['formula'],_0x54120e[_0x51e4d9(0x223)]??[]);if(!_0x570138)return!0x1;let _0x51f5d7=mt(_0x41b37a[_0x51e4d9(0x2ab)],_0x41b37a[_0x51e4d9(0x22c)],_0x41b37a['unitId']),_0x52ed4f=ht({'documentData':_0x41b37a['documentData'],'resource':_0x41b37a[_0x51e4d9(0x1d4)],'rangeId':_0x51f5d7,'config':{'formula':_0x54120e['formula'],..._0x54120e['numberFormat']?{'numberFormat':_0x54120e[_0x51e4d9(0x271)]}:null},'startOffset':_0x4395b7[_0x51e4d9(0x262)],'endOffset':_0x4395b7['endOffset']});if(!_0x52ed4f)return!0x1;let _0x41c52b=_0x64c5d3(_0x17e9eb,_0x41b37a[_0x51e4d9(0x24b)],_0x570138);return!_0x41c52b||!J({'accessor':_0x17e9eb,'document':_0x41b37a['document'],'unitId':_0x41b37a[_0x51e4d9(0x24b)],'trigger':U['id'],'rangeId':_0x51f5d7,'previousResource':_0x41b37a['resource'],'nextResource':_0x52ed4f[_0x51e4d9(0x2c8)],'previousDocumentData':_0x41b37a[_0x51e4d9(0x2a7)],'nextDocumentData':_0x52ed4f[_0x51e4d9(0x247)],'cursorOffset':_0x52ed4f['cursorOffset'],'externalMutations':_0x41c52b})?!0x1:{'rangeId':_0x51f5d7,'startOffset':_0x52ed4f['cursorOffset']-0x1,'endOffset':_0x52ed4f[_0x51e4d9(0x256)]};}},W={'id':_0x34c9f2(0x222),'type':_0x3d8c4d[_0x34c9f2(0x2a0)],'handler':(_0x52be58,_0x444b30)=>{const _0x2b7c6a=_0x34c9f2;if(!(_0x444b30!=null&&_0x444b30['rangeId'])||!_0x444b30[_0x2b7c6a(0x20f)][_0x2b7c6a(0x27c)]())return!0x1;let _0x5bc2ad=q(_0x52be58,_0x444b30[_0x2b7c6a(0x24b)],''),_0x2782ef=_0x5bc2ad==null?void 0x0:_0x5bc2ad[_0x2b7c6a(0x22c)][_0x2b7c6a(0x2a3)](_0x5bc2ad[_0x2b7c6a(0x24b)],_0x444b30[_0x2b7c6a(0x212)]),_0x14c5df=_0x5bc2ad?T(_0x5bc2ad[_0x2b7c6a(0x2a7)][_0x2b7c6a(0x2ab)],_0x444b30[_0x2b7c6a(0x212)]):void 0x0;if(!_0x5bc2ad||!_0x2782ef||!_0x14c5df)return!0x1;let _0x5ddfc0=pt(_0x52be58,_0x5bc2ad['unitId'],_0x444b30[_0x2b7c6a(0x20f)],_0x444b30['externalReferences']??[]);if(!_0x5ddfc0)return!0x1;let _0x1f8c8b=_0x64c5d3(_0x52be58,_0x5bc2ad[_0x2b7c6a(0x24b)],_0x5ddfc0);if(!_0x1f8c8b)return!0x1;let _0x1624c2=Ct(_0x5bc2ad[_0x2b7c6a(0x1d4)]);return _0x1624c2[_0x2b7c6a(0x214)][_0x444b30[_0x2b7c6a(0x212)]]={'formula':_0x444b30[_0x2b7c6a(0x20f)],..._0x444b30[_0x2b7c6a(0x271)]?{'numberFormat':_0x444b30[_0x2b7c6a(0x271)]}:_0x2782ef[_0x2b7c6a(0x271)]?{'numberFormat':_0x2782ef['numberFormat']}:null},J({'accessor':_0x52be58,'document':_0x5bc2ad[_0x2b7c6a(0x289)],'unitId':_0x5bc2ad[_0x2b7c6a(0x24b)],'trigger':W['id'],'rangeId':_0x444b30['rangeId'],'previousResource':_0x5bc2ad[_0x2b7c6a(0x1d4)],'nextResource':_0x1624c2,'cursorOffset':_0x14c5df[_0x2b7c6a(0x285)]+0x1,'externalMutations':_0x1f8c8b});}},G={'id':_0x34c9f2(0x2ae),'type':_0x3d8c4d[_0x34c9f2(0x2a0)],'handler':(_0x484798,_0x40b4e6)=>{const _0x1da246=_0x34c9f2;if(!(_0x40b4e6!=null&&_0x40b4e6['rangeId']))return!0x1;let _0x3b0dea=q(_0x484798,_0x40b4e6[_0x1da246(0x24b)],''),_0x29a759=_0x3b0dea==null?void 0x0:_0x3b0dea[_0x1da246(0x22c)]['getFormula'](_0x3b0dea[_0x1da246(0x24b)],_0x40b4e6[_0x1da246(0x212)]),_0x128c09=_0x3b0dea?T(_0x3b0dea['documentData'][_0x1da246(0x2ab)],_0x40b4e6[_0x1da246(0x212)]):void 0x0;if(!_0x3b0dea||!_0x29a759||!_0x128c09)return!0x1;let _0x50694c=Ct(_0x3b0dea['resource']);return _0x50694c[_0x1da246(0x214)][_0x40b4e6[_0x1da246(0x212)]]={..._0x29a759,..._0x40b4e6[_0x1da246(0x271)]?{'numberFormat':_0x40b4e6[_0x1da246(0x271)]}:null},_0x40b4e6[_0x1da246(0x271)]||delete _0x50694c[_0x1da246(0x214)][_0x40b4e6['rangeId']][_0x1da246(0x271)],J({'accessor':_0x484798,'document':_0x3b0dea[_0x1da246(0x289)],'unitId':_0x3b0dea['unitId'],'trigger':G['id'],'rangeId':_0x40b4e6[_0x1da246(0x212)],'previousResource':_0x3b0dea[_0x1da246(0x1d4)],'nextResource':_0x50694c,'cursorOffset':_0x128c09[_0x1da246(0x285)]+0x1,'externalMutations':{}});}},K={'id':_0x34c9f2(0x1e3),'type':_0x3d8c4d[_0x34c9f2(0x2a0)],'handler':(_0x2a4240,_0x328bf6)=>ut(_0x2a4240,_0x328bf6,'',K['id'])},ct={'id':'docs-formula.command.replace-with-text','type':_0x3d8c4d[_0x34c9f2(0x2a0)],'handler':(_0x2b4a2e,_0x5f51c2)=>ut(_0x2b4a2e,_0x5f51c2,(_0x5f51c2==null?void 0x0:_0x5f51c2['text'])??'',ct['id'])},lt={'id':_0x34c9f2(0x29d),'type':_0x3d8c4d[_0x34c9f2(0x2a0)],'handler':(_0x5a3d76,_0x136fc2)=>{const _0x450364=_0x34c9f2;if(!(_0x136fc2!=null&&_0x136fc2['rangeId']))return!0x1;let _0x4ff79f=q(_0x5a3d76,_0x136fc2[_0x450364(0x24b)],'');if(!_0x4ff79f)return!0x1;let _0x345678=_0x5a3d76[_0x450364(0x1ff)](L)[_0x450364(0x25a)]({'unitId':_0x4ff79f['unitId'],'rangeId':_0x136fc2[_0x450364(0x212)]});return _0x345678?ut(_0x5a3d76,_0x136fc2,_0x345678[_0x450364(0x282)],lt['id']):!0x1;}};function ut(_0x1c7aeb,_0x5ed69c,_0x1572b5,_0xac1785){const _0x1b1302=_0x34c9f2;if(!(_0x5ed69c!=null&&_0x5ed69c[_0x1b1302(0x212)]))return!0x1;let _0x33ae45=q(_0x1c7aeb,_0x5ed69c[_0x1b1302(0x24b)],'');if(!_0x33ae45)return!0x1;let _0x1f6714=Be({'documentData':_0x33ae45[_0x1b1302(0x2a7)],'resource':_0x33ae45[_0x1b1302(0x1d4)],'rangeId':_0x5ed69c[_0x1b1302(0x212)],'text':_0x1572b5});return _0x1f6714?J({'accessor':_0x1c7aeb,'document':_0x33ae45['document'],'unitId':_0x33ae45[_0x1b1302(0x24b)],'trigger':_0xac1785,'rangeId':_0x5ed69c['rangeId'],'previousResource':_0x33ae45['resource'],'nextResource':_0x1f6714['nextResource'],'previousDocumentData':_0x33ae45[_0x1b1302(0x2a7)],'nextDocumentData':_0x1f6714['nextDocumentData'],'cursorOffset':_0x1f6714[_0x1b1302(0x256)],'externalMutations':{}}):!0x1;}function q(_0x2e0241,_0x5b8b2e,_0x721619){const _0x1f5ccf=_0x34c9f2;if(_0x721619)return null;let _0x3c61c9=_0x2e0241[_0x1f5ccf(0x1ff)](_0x35f474),_0x44ec47=(_0x5b8b2e?_0x3c61c9[_0x1f5ccf(0x1e4)](_0x5b8b2e,_0x9cc7bc[_0x1f5ccf(0x259)]):_0x3c61c9[_0x1f5ccf(0x2c2)](_0x9cc7bc['UNIVER_DOC']))??null;if(!_0x44ec47)return null;let _0x3138f5=_0x44ec47[_0x1f5ccf(0x281)](),_0x2a6252=_0x3138f5[_0x1f5ccf(0x2ab)];if(_0x3138f5[_0x1f5ccf(0x226)]||!_0x2a6252)return null;let _0x1ec377=_0x2e0241[_0x1f5ccf(0x1ff)](P);return _0x1ec377['getLoadError'](_0x44ec47[_0x1f5ccf(0x1f2)]())?null:{'document':_0x44ec47,'body':_0x2a6252,'documentData':_0x3138f5,'model':_0x1ec377,'resource':_0x1ec377[_0x1f5ccf(0x284)](_0x44ec47['getUnitId']())??b(),'unitId':_0x44ec47[_0x1f5ccf(0x1f2)]()};}function dt(_0x24d41f,_0x5314c5){const _0x301c83=_0x34c9f2;var _0x57fb6f;return(_0x57fb6f=_0x24d41f[_0x301c83(0x1ff)](_0x1841de)[_0x301c83(0x1d8)]({'subUnitId':_0x5314c5,'unitId':_0x5314c5}))==null?void 0x0:_0x57fb6f[0x0];}function ft(_0x3a81b8,_0x254d1f,_0x5c9e40){const _0x2c569c=_0x34c9f2;if((_0x3a81b8==null?void 0x0:_0x3a81b8['type'])===_0x2c569c(0x286)){var _0x326a5f;let _0x7b68b5=((_0x326a5f=_0x254d1f[_0x2c569c(0x27f)])==null?void 0x0:_0x326a5f[_0x2c569c(0x229)](_0x19a101=>_0x19a101['paragraphId']===_0x3a81b8[_0x2c569c(0x1d0)]))??[];if(_0x7b68b5[_0x2c569c(0x2c1)]!==0x1)return null;let _0x3640fd=_0x7b68b5[0x0],_0x34d96f=_0x44d00(_0x254d1f,_0x3640fd),_0x388779=_0x3640fd[_0x2c569c(0x25c)]-_0x34d96f,_0x4d9aa0=_0x3a81b8[_0x2c569c(0x296)]===_0x2c569c(0x297)?_0x388779:_0x3a81b8[_0x2c569c(0x296)];if(!Number['isInteger'](_0x4d9aa0)||_0x4d9aa0<0x0||_0x4d9aa0>_0x388779)return null;let _0x3543f8=_0x34d96f+_0x4d9aa0;return{'startOffset':_0x3543f8,'endOffset':_0x3543f8};}if((_0x3a81b8==null?void 0x0:_0x3a81b8[_0x2c569c(0x278)])===_0x2c569c(0x210))return!Number[_0x2c569c(0x1fa)](_0x3a81b8[_0x2c569c(0x262)])||!Number[_0x2c569c(0x1fa)](_0x3a81b8[_0x2c569c(0x251)])?null:{'startOffset':Math[_0x2c569c(0x232)](_0x3a81b8[_0x2c569c(0x262)],_0x3a81b8['endOffset']),'endOffset':Math[_0x2c569c(0x241)](_0x3a81b8[_0x2c569c(0x262)],_0x3a81b8[_0x2c569c(0x251)])};let _0x1ef499=(_0x3a81b8==null?void 0x0:_0x3a81b8[_0x2c569c(0x278)])===_0x2c569c(0x272)?_0x3a81b8['selection']:_0x5c9e40;return!_0x1ef499||_0x1ef499[_0x2c569c(0x1f0)]?null:{'startOffset':Math[_0x2c569c(0x232)](_0x1ef499[_0x2c569c(0x262)],_0x1ef499[_0x2c569c(0x251)]),'endOffset':Math['max'](_0x1ef499[_0x2c569c(0x262)],_0x1ef499[_0x2c569c(0x251)])};}function pt(_0x3e6850,_0x5f579d,_0x5ad614,_0x79382){const _0x3e0385=_0x34c9f2;let _0x5036a7=_0x3e6850['get'](_0x2ea0aa),_0x5f10a4=_0x5ad614[_0x3e0385(0x274)]('=')?_0x5ad614[_0x3e0385(0x23c)](0x1):_0x5ad614,_0x195fe0=_0x5036a7[_0x3e0385(0x1db)](_0x5f10a4);if(!_0x195fe0)return null;let _0x503568=_0x3e6850[_0x3e0385(0x1ff)](_0x598fe),_0x409e25=_0xc8a733({'qualifiers':_0x51ffff(_0x195fe0),'explicitReferences':_0x79382??[],'resolveBinding':_0x4f881b=>_0x503568[_0x3e0385(0x25f)](_0x5f579d,_0x4f881b)});return _0x409e25[_0x3e0385(0x216)]===_0x3e0385(0x1f5)?_0x409e25[_0x3e0385(0x227)]:null;}function mt(_0x4b6f34,_0x10a56b,_0x1a7bae){const _0xdf7525=_0x34c9f2;var _0x19c741;let _0x1ee56e=_0x23fed8(0x6);for(;_0x4b6f34!=null&&(_0x19c741=_0x4b6f34[_0xdf7525(0x2b7)])!=null&&_0x19c741[_0xdf7525(0x23a)](_0x1d40d8=>_0x1d40d8['rangeId']===_0x1ee56e)||_0x10a56b['getFormula'](_0x1a7bae,_0x1ee56e);)_0x1ee56e=_0x23fed8(0x6);return _0x1ee56e;}function ht(_0x29c252){try{return Re(_0x29c252);}catch(_0x293e10){if(_0x293e10 instanceof C)return null;throw _0x293e10;}}function gt(_0x43f515){const _0x20ecf7=_0x34c9f2;let _0x4a8589=_0x43f515[_0x20ecf7(0x1e6)]&&_0x43f515[_0x20ecf7(0x247)]?vt(_0x43f515[_0x20ecf7(0x289)],_0x43f515['unitId'],_0x43f515[_0x20ecf7(0x1e6)],_0x43f515['nextDocumentData'],_0x43f515[_0x20ecf7(0x256)],_0x43f515[_0x20ecf7(0x225)]):null;return _0x43f515[_0x20ecf7(0x1e6)]&&_0x43f515[_0x20ecf7(0x247)]&&!_0x4a8589?null:{'documentRedo':_0x4a8589,'resourceRedo':{'id':V['id'],'params':{'unitId':_0x43f515[_0x20ecf7(0x24b)],'resource':_0x43f515[_0x20ecf7(0x2c8)]}},'resourceUndo':{'id':V['id'],'params':{'unitId':_0x43f515[_0x20ecf7(0x24b)],'resource':_0x43f515['previousResource']}}};}function _t(_0x686c56,_0x5cf636,_0x59c45a,_0x2c1feb){const _0x31dc43=_0x34c9f2;_0x2c1feb[_0x31dc43(0x29b)]({'id':_0x686c56[_0x31dc43(0x225)]+':'+_0x686c56[_0x31dc43(0x212)],'unitID':_0x686c56['unitId'],'redoMutations':[..._0x686c56[_0x31dc43(0x248)]['redoMutation']?[_0x686c56[_0x31dc43(0x248)][_0x31dc43(0x215)]]:[],..._0x5cf636[_0x31dc43(0x264)]?[_0x5cf636[_0x31dc43(0x264)]]:[],_0x5cf636[_0x31dc43(0x2a9)]],'undoMutations':[_0x5cf636[_0x31dc43(0x202)],..._0x59c45a?[_0x59c45a]:[],..._0x686c56['externalMutations'][_0x31dc43(0x2a2)]?[_0x686c56[_0x31dc43(0x248)]['undoMutation']]:[]]});}function J(_0x4e1a85){const _0x32a94d=_0x34c9f2;let _0x4f1779=_0x4e1a85['accessor'][_0x32a94d(0x1ff)](_0x1fba3b),_0x6cc367=_0x4e1a85[_0x32a94d(0x267)][_0x32a94d(0x1ff)](_0x6bc219),_0x4f8127=_0x4e1a85[_0x32a94d(0x267)][_0x32a94d(0x1ff)](_0x1841de),_0x83d72b=gt(_0x4e1a85);if(!_0x83d72b)return!0x1;let _0x313e89=!0x1,_0x1ec61d=null,_0x1f2b2f=!0x1;try{if(_0x4e1a85[_0x32a94d(0x248)][_0x32a94d(0x215)]){if(!_0x4f1779[_0x32a94d(0x242)](_0x4e1a85[_0x32a94d(0x248)][_0x32a94d(0x215)]['id'],_0x4e1a85[_0x32a94d(0x248)][_0x32a94d(0x215)][_0x32a94d(0x1f6)]))return!0x1;_0x313e89=!0x0;}if(_0x83d72b[_0x32a94d(0x264)]){let _0xca81f3=_0x4f1779[_0x32a94d(0x242)](_0x83d72b['documentRedo']['id'],_0x83d72b['documentRedo']['params']);if(!_0xca81f3)return bt(_0x4f1779,_0x4e1a85['externalMutations'],_0x313e89),!0x1;_0x1ec61d={'id':_0x26272f['id'],'params':{..._0xca81f3,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'segmentId':''}};}if(!_0x4f1779[_0x32a94d(0x242)](_0x83d72b['resourceRedo']['id'],_0x83d72b[_0x32a94d(0x2a9)][_0x32a94d(0x1f6)]))return yt(_0x4f1779,_0x1ec61d),bt(_0x4f1779,_0x4e1a85[_0x32a94d(0x248)],_0x313e89),!0x1;_0x1f2b2f=!0x0,_t(_0x4e1a85,_0x83d72b,_0x1ec61d,_0x6cc367);}catch(_0x4dccb4){throw _0x1f2b2f&&_0x4f1779['syncExecuteCommand'](_0x83d72b[_0x32a94d(0x202)]['id'],_0x83d72b[_0x32a94d(0x202)][_0x32a94d(0x1f6)]),yt(_0x4f1779,_0x1ec61d),bt(_0x4f1779,_0x4e1a85[_0x32a94d(0x248)],_0x313e89),_0x4dccb4;}return _0x4f8127[_0x32a94d(0x20d)]([{'startOffset':_0x4e1a85[_0x32a94d(0x256)],'endOffset':_0x4e1a85[_0x32a94d(0x256)],'segmentId':''}],{'unitId':_0x4e1a85['unitId'],'subUnitId':_0x4e1a85[_0x32a94d(0x24b)]},!0x1,{[_0x291f0f]:!0x0}),!0x0;}function vt(_0x58e0e5,_0x170e0a,_0x55e688,_0x5f402,_0x346ed0,_0x7647ae){let _0x2124af=xt(_0x55e688,_0x5f402,_0x38047f(_0x58e0e5,''));return _0x2124af?{'id':_0x26272f['id'],'params':{'unitId':_0x170e0a,'actions':_0x2124af,'segmentId':'','textRanges':[{'startOffset':_0x346ed0,'endOffset':_0x346ed0,'collapsed':!0x0,'segmentId':''}],'isEditing':!0x1,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'trigger':_0x7647ae}}:null;}function yt(_0x1a4287,_0x46fa67){const _0x26ab8a=_0x34c9f2;_0x46fa67&&_0x1a4287[_0x26ab8a(0x242)](_0x46fa67['id'],_0x46fa67['params']);}function bt(_0x2680ee,_0x3ae5e9,_0xa7024c){const _0x170c0d=_0x34c9f2;_0xa7024c&&_0x3ae5e9[_0x170c0d(0x2a2)]&&_0x2680ee[_0x170c0d(0x242)](_0x3ae5e9[_0x170c0d(0x2a2)]['id'],_0x3ae5e9['undoMutation'][_0x170c0d(0x1f6)]);}function xt(_0x2b54a6,_0x3cbd5c,_0x4a1590){const _0x51fad9=_0x34c9f2;let _0x2344aa=_0x2b54a6[_0x51fad9(0x2ab)],_0x5dfe35=_0x3cbd5c[_0x51fad9(0x2ab)],_0x20e1e6=St(_0x2344aa==null?void 0x0:_0x2344aa[_0x51fad9(0x1de)],_0x5dfe35==null?void 0x0:_0x5dfe35[_0x51fad9(0x1de)]);if(!_0x20e1e6||!_0x5dfe35)return null;let _0x9074ac=new _0x283512();return _0x9074ac[_0x51fad9(0x299)](_0x20e1e6['start']),_0x20e1e6[_0x51fad9(0x29c)]>0x0&&_0x9074ac[_0x51fad9(0x25d)](_0x20e1e6[_0x51fad9(0x29c)],_0x2ffd0f(_0x5dfe35,_0x20e1e6['start'],_0x20e1e6[_0x51fad9(0x22f)]+_0x20e1e6[_0x51fad9(0x29c)],!0x1)),_0x20e1e6[_0x51fad9(0x208)]>0x0&&_0x9074ac[_0x51fad9(0x287)](_0x20e1e6[_0x51fad9(0x208)]),_0x42e010['getInstance']()[_0x51fad9(0x201)](_0x9074ac['serialize'](),_0x4a1590);}function St(_0x3eb6ce,_0x568f33){const _0x19e2fd=_0x34c9f2;if(_0x3eb6ce==null||_0x568f33==null||_0x3eb6ce===_0x568f33)return null;let _0x69a4e7=0x0;for(;_0x69a4e7<_0x3eb6ce[_0x19e2fd(0x2c1)]&&_0x69a4e7<_0x568f33[_0x19e2fd(0x2c1)]&&_0x3eb6ce[_0x69a4e7]===_0x568f33[_0x69a4e7];)_0x69a4e7+=0x1;let _0x16a404=_0x3eb6ce['length'],_0x590359=_0x568f33[_0x19e2fd(0x2c1)];for(;_0x16a404>_0x69a4e7&&_0x590359>_0x69a4e7&&_0x3eb6ce[_0x16a404-0x1]===_0x568f33[_0x590359-0x1];)--_0x16a404,--_0x590359;return{'start':_0x69a4e7,'deleteLength':_0x16a404-_0x69a4e7,'insertLength':_0x590359-_0x69a4e7};}function Ct(_0xd5a7fd){const _0x3c05b5=_0x34c9f2;return{'schemaVersion':0x1,'formulas':Object['fromEntries'](Object[_0x3c05b5(0x2ad)](_0xd5a7fd[_0x3c05b5(0x214)])[_0x3c05b5(0x26d)](([_0x553824,_0x3cbab0])=>[_0x553824,{..._0x3cbab0,..._0x3cbab0[_0x3c05b5(0x271)]?{'numberFormat':{..._0x3cbab0[_0x3c05b5(0x271)]}}:null,..._0x3cbab0[_0x3c05b5(0x21f)]?{'lastValue':{..._0x3cbab0[_0x3c05b5(0x21f)]}}:null}]))};}let Y=class extends _0x49a82f{constructor(_0x280f00,_0x4820ec,_0xb233fe,_0x331b89){const _0x22723e=_0x34c9f2;super(),this[_0x22723e(0x298)]=_0x280f00,this[_0x22723e(0x2b8)]=_0x4820ec,this['_model']=_0xb233fe,this[_0x22723e(0x27a)]=_0x331b89,N(this,_0x22723e(0x1ec),new Set()),N(this,_0x22723e(0x1e8),!0x1),N(this,'_isDisposed',!0x1),this['_instanceService'][_0x22723e(0x290)](_0x9cc7bc[_0x22723e(0x259)])[_0x22723e(0x230)](_0x1390d4=>this[_0x22723e(0x27a)]['syncUnit'](_0x1390d4)),this[_0x22723e(0x249)](this[_0x22723e(0x1f3)][_0x22723e(0x2ba)][_0x22723e(0x283)](({unitId:_0x22f4a2})=>this[_0x22723e(0x260)](_0x22f4a2))),this[_0x22723e(0x249)](this[_0x22723e(0x298)]['unitAdded$']['subscribe'](({unit:_0x423dd2})=>{const _0x582255=_0x22723e;_0x423dd2[_0x582255(0x278)]===_0x9cc7bc[_0x582255(0x259)]&&this[_0x582255(0x240)](_0x423dd2[_0x582255(0x1f2)]());})),this['disposeWithMe'](this[_0x22723e(0x298)]['unitDisposed$'][_0x22723e(0x283)](_0x359dc6=>{const _0x352a26=_0x22723e;this['_service']['unregisterUnit'](_0x359dc6[_0x352a26(0x1f2)]());})),this['disposeWithMe'](this[_0x22723e(0x2b8)][_0x22723e(0x29a)](_0x2ed073=>{const _0xac8161=_0x22723e;if(_0x2ed073['id']===_0x26272f['id']&&wt(_0x2ed073[_0xac8161(0x1f6)])){let _0x18c9bf=_0x2ed073['params'];_0x18c9bf[_0xac8161(0x1f0)]||this[_0xac8161(0x260)](_0x18c9bf[_0xac8161(0x24b)]);}}));}[_0x34c9f2(0x1d1)](){const _0xc47545=_0x34c9f2;this[_0xc47545(0x292)]=!0x0,super[_0xc47545(0x1d1)]();}[_0x34c9f2(0x240)](_0x392403){const _0x897751=_0x34c9f2;this[_0x897751(0x1ec)][_0x897751(0x21b)](_0x392403),!this[_0x897751(0x1e8)]&&(this[_0x897751(0x1e8)]=!0x0,queueMicrotask(()=>{const _0x3f46f8=_0x897751;if(this['_syncScheduled']=!0x1,this[_0x3f46f8(0x292)])return;let _0x29e46d=Array[_0x3f46f8(0x1f4)](this['_pendingUnitIds']);this[_0x3f46f8(0x1ec)][_0x3f46f8(0x26c)](),_0x29e46d[_0x3f46f8(0x230)](_0x1e6e88=>this[_0x3f46f8(0x260)](_0x1e6e88));}));}['_syncUnit'](_0x2976fc){const _0xdf46c5=_0x34c9f2;let _0x579fbf=this['_instanceService'][_0xdf46c5(0x1e4)](_0x2976fc,_0x9cc7bc[_0xdf46c5(0x259)]);_0x579fbf&&this[_0xdf46c5(0x27a)][_0xdf46c5(0x234)](_0x579fbf);}};Y=I([F(0x0,_0x35f474),F(0x1,_0x1fba3b),F(0x2,_0x5c5393(P)),F(0x3,_0x5c5393(L))],Y);function wt(_0x227a8f){const _0x2d4c3f=_0x34c9f2;return typeof _0x227a8f=='object'&&!!_0x227a8f&&_0x2d4c3f(0x24b)in _0x227a8f&&typeof _0x227a8f[_0x2d4c3f(0x24b)]==_0x2d4c3f(0x1d5)&&(!(_0x2d4c3f(0x1f0)in _0x227a8f)||_0x227a8f[_0x2d4c3f(0x1f0)]===void 0x0||typeof _0x227a8f[_0x2d4c3f(0x1f0)]==_0x2d4c3f(0x1d5));}let X=class extends _0x49a82f{constructor(_0x778ade,_0x1075b2){const _0x43b250=_0x34c9f2;super(),this[_0x43b250(0x1d6)]=_0x778ade,this[_0x43b250(0x219)]=_0x1075b2,this[_0x43b250(0x249)](this['_resourceManagerService']['registerPluginResource']({'pluginName':y,'businesses':[_0x9cc7bc[_0x43b250(0x259)]],'toJson':_0x140ada=>JSON[_0x43b250(0x275)](this[_0x43b250(0x219)][_0x43b250(0x27e)](_0x140ada)),'parseJson':_0x4b7256=>JSON[_0x43b250(0x237)](_0x4b7256),'onLoad':(_0x316212,_0x340225)=>{const _0x343109=_0x43b250;this[_0x343109(0x219)][_0x343109(0x2a6)](_0x316212,_0x340225);},'onUnLoad':_0x3a11de=>this[_0x43b250(0x219)]['removeUnit'](_0x3a11de)}));}};X=I([F(0x0,_0x674a1c),F(0x1,_0x5c5393(P))],X);var Tt='@univerjs-pro/docs-formula',Et=_0x34c9f2(0x1e7);const Dt={};let Z=class extends _0x49a82f{constructor(_0x2472f5,_0xd16fc2,_0x38ee2d){const _0x205c08=_0x34c9f2;super(),this[_0x205c08(0x28b)]=_0x2472f5,this[_0x205c08(0x238)]=_0xd16fc2,this[_0x205c08(0x249)](_0x38ee2d[_0x205c08(0x2a4)]({'resolve':(_0x540fa3,_0x377245)=>{const _0x4400b1=_0x205c08;var _0x532f47;return((_0x532f47=_0x377245['customRanges'])==null?void 0x0:_0x532f47[_0x4400b1(0x229)](w)['map'](_0x1d05ad=>({'startOffset':_0x1d05ad['startIndex'],'endOffset':_0x1d05ad[_0x4400b1(0x285)]+0x1,'text':this[_0x4400b1(0x28d)](_0x540fa3,_0x1d05ad[_0x4400b1(0x212)])})))??[];}})),this[_0x205c08(0x249)](this[_0x205c08(0x238)][_0x205c08(0x268)][_0x205c08(0x283)](({unitId:_0x1161f4})=>{const _0x1b0c8c=_0x205c08;_0x38ee2d[_0x1b0c8c(0x2b9)](_0x1161f4);}));}[_0x34c9f2(0x28d)](_0x23ff72,_0xb5750d){const _0x41a43a=_0x34c9f2;var _0x177ff0;return((_0x177ff0=this[_0x41a43a(0x238)][_0x41a43a(0x25a)]({'unitId':_0x23ff72,'rangeId':_0xb5750d}))==null?void 0x0:_0x177ff0['text'])??'';}[_0x34c9f2(0x211)](_0x18af5b,_0x36a2bb,_0x5ca176){const _0x58d10=_0x34c9f2;var _0x5bf26b;let _0x218d2a=this['_univerInstanceService'][_0x58d10(0x1e4)](_0x18af5b,_0x9cc7bc[_0x58d10(0x259)]),_0x576fb3=_0x218d2a==null?void 0x0:_0x218d2a['getBody']();if(!_0x576fb3)return'';let _0x111d5a=_0x576fb3[_0x58d10(0x1de)][_0x58d10(0x23c)](_0x36a2bb,_0x5ca176),_0x2b1c45=((_0x5bf26b=_0x576fb3['customRanges'])==null?void 0x0:_0x5bf26b[_0x58d10(0x229)](_0x235467=>w(_0x235467)&&_0x235467['startIndex']>=_0x36a2bb&&_0x235467[_0x58d10(0x285)]<_0x5ca176)[_0x58d10(0x26f)]((_0x504d07,_0x553e6e)=>_0x553e6e[_0x58d10(0x25c)]-_0x504d07[_0x58d10(0x25c)]))??[];for(let _0x461f6a of _0x2b1c45){let _0x374092=_0x461f6a['startIndex']-_0x36a2bb,_0x29609b=_0x461f6a[_0x58d10(0x285)]-_0x36a2bb+0x1;_0x111d5a=''+_0x111d5a[_0x58d10(0x23c)](0x0,_0x374092)+this[_0x58d10(0x28d)](_0x18af5b,_0x461f6a['rangeId'])+_0x111d5a[_0x58d10(0x23c)](_0x29609b);}return _0x111d5a;}[_0x34c9f2(0x257)](_0x43c0f8){return Ot(_0x43c0f8);}[_0x34c9f2(0x2b0)](_0x5f4c20,_0x268d63,_0x5f4f4f={}){const _0x55baae=_0x34c9f2;var _0x5908ca;return Ve({'id':_0x5f4c20,'body':_0x268d63,'documentStyle':{}},(((_0x5908ca=_0x268d63[_0x55baae(0x2b7)])==null?void 0x0:_0x5908ca['filter'](w))??[])['map'](_0xd5b6f5=>({'rangeId':_0xd5b6f5[_0x55baae(0x212)],'text':_0x5f4f4f[_0xd5b6f5[_0x55baae(0x212)]]??this[_0x55baae(0x28d)](_0x5f4c20,_0xd5b6f5[_0x55baae(0x212)])})))['body']??{'dataStream':''};}};Z=I([F(0x0,_0x35f474),F(0x1,_0x5c5393(L)),F(0x2,_0x5c5393(_0x557df1))],Z);function Ot(_0x503517){const _0x20a230=_0x34c9f2;var _0x35edca,_0x3bbbaa;let _0x1cbb04=kt(_0x503517),_0x4af208=Ve(_0x503517,(((_0x35edca=_0x503517[_0x20a230(0x2ab)])==null||(_0x35edca=_0x35edca[_0x20a230(0x2b7)])==null?void 0x0:_0x35edca[_0x20a230(0x229)](w))??[])[_0x20a230(0x26d)](_0x289ef1=>({'rangeId':_0x289ef1[_0x20a230(0x212)],'text':At(_0x1cbb04==null?void 0x0:_0x1cbb04[_0x20a230(0x214)][_0x289ef1[_0x20a230(0x212)]])})));return _0x4af208[_0x20a230(0x265)]=(_0x3bbbaa=_0x4af208['resources'])==null?void 0x0:_0x3bbbaa[_0x20a230(0x229)](_0xe5d3ea=>_0xe5d3ea[_0x20a230(0x220)]!==y),_0x4af208;}function kt(_0x40f534){const _0x3d1b75=_0x34c9f2;var _0x1d23c7;let _0x44a313=(_0x1d23c7=_0x40f534[_0x3d1b75(0x265)])==null||(_0x1d23c7=_0x1d23c7['find'](_0x1b4957=>_0x1b4957[_0x3d1b75(0x220)]===_0x3d1b75(0x26b)))==null?void 0x0:_0x1d23c7[_0x3d1b75(0x24c)];if(_0x44a313)try{let _0x396568=JSON[_0x3d1b75(0x237)](_0x44a313);return x(_0x396568)?_0x396568:void 0x0;}catch{return;}}function At(_0x2ac03b){const _0x438b01=_0x34c9f2;return _0x2ac03b?_0x44276e({'lastValue':_0x2ac03b['lastValue'],'numberFormat':_0x2ac03b[_0x438b01(0x271)]})[_0x438b01(0x282)]:'';}let Q=class extends _0x49a82f{constructor(_0x21e517,_0x3a79ff,_0x48ca5b){const _0x607f01=_0x34c9f2;super(),this[_0x607f01(0x238)]=_0x21e517,this[_0x607f01(0x1d2)]=_0x3a79ff,this[_0x607f01(0x249)](_0x48ca5b['registerProvider'](this));}[_0x34c9f2(0x1d9)](_0x5cfc53){const _0x3a073f=_0x34c9f2;let _0x117375=new Map();for(let _0x84fce6 of this['_formulaService']['getRegisteredFormulas']()){var _0x837586;if(!this[_0x3a073f(0x1d2)][_0x3a073f(0x24e)](_0x84fce6[_0x3a073f(0x1ef)][_0x3a073f(0x20f)],_0x84fce6[_0x3a073f(0x2a1)])['eligible'])continue;let _0x3b4d43=_0x477060(_0x84fce6[_0x3a073f(0x2a1)]),_0x28aa71=_0x3b4d43?_0x16967c(_0x3b4d43):null;if(!_0x28aa71||jt(_0x84fce6[_0x3a073f(0x1ef)]['lastValue'],_0x28aa71))continue;let _0x17a49e=_0x117375[_0x3a073f(0x1ff)](_0x84fce6[_0x3a073f(0x228)]['unitId'])??[];_0x17a49e[_0x3a073f(0x2af)]({'rangeId':_0x84fce6[_0x3a073f(0x228)][_0x3a073f(0x212)],'expectedFormula':_0x84fce6[_0x3a073f(0x1ef)]['formula'],'expectedNumberFormat':(_0x837586=_0x84fce6['config'][_0x3a073f(0x271)])==null?void 0x0:_0x837586['pattern'],'expectedReferenceRevision':_0x84fce6[_0x3a073f(0x2bd)],'lastValue':_0x28aa71}),_0x117375[_0x3a073f(0x252)](_0x84fce6[_0x3a073f(0x228)]['unitId'],_0x17a49e);}return Array[_0x3a073f(0x1f4)](_0x117375,([_0x4117f6,_0x5d1d3a])=>({'id':H['id'],'params':{'unitId':_0x4117f6,'updates':_0x5d1d3a}}));}};Q=I([F(0x0,_0x5c5393(L)),F(0x1,_0x5c5393(_0x168d95)),F(0x2,_0x5c5393(_0x442e83))],Q);function jt(_0x47cf81,_0x4b0dad){const _0x2c0178=_0x34c9f2;return(_0x47cf81==null?void 0x0:_0x47cf81['v'])===_0x4b0dad['v']&&(_0x47cf81==null?void 0x0:_0x47cf81['t'])===_0x4b0dad['t']&&(_0x47cf81==null?void 0x0:_0x47cf81[_0x2c0178(0x244)])===_0x4b0dad[_0x2c0178(0x244)];}let $=class extends _0x530da8{constructor(_0x4ed583=Dt,_0x4fad2c,_0x12bee5,_0x303e59){const _0x5a9665=_0x34c9f2;super(),this[_0x5a9665(0x1e0)]=_0x4ed583,this[_0x5a9665(0x258)]=_0x4fad2c,this[_0x5a9665(0x2b8)]=_0x12bee5,this['_configService']=_0x303e59;let {..._0x341519}=_0x2e4085({},Dt,this[_0x5a9665(0x1e0)]);this[_0x5a9665(0x1fe)][_0x5a9665(0x1dc)](_0x5a9665(0x293),_0x341519);}[_0x34c9f2(0x269)](){const _0x46442d=_0x34c9f2;this[_0x46442d(0x258)]['add']([P]),this[_0x46442d(0x258)][_0x46442d(0x21b)]([L]),this[_0x46442d(0x258)]['add']([X]),this['_injector'][_0x46442d(0x21b)]([Y]),this[_0x46442d(0x258)][_0x46442d(0x21b)]([Q]),this[_0x46442d(0x258)][_0x46442d(0x21b)]([Z]),_0x6f29f6(this['_injector'],[[P],[X],[Y],[Q],[Z]]),[ot,st,V,H,U,W,G,K,ct,lt][_0x46442d(0x230)](_0x2ed1ef=>this[_0x46442d(0x249)](this[_0x46442d(0x2b8)][_0x46442d(0x2b4)](_0x2ed1ef)));}};N($,_0x34c9f2(0x1f9),y),N($,'packageName',Tt),N($,_0x34c9f2(0x235),Et),N($,_0x34c9f2(0x278),_0x9cc7bc['UNIVER_DOC']),$=I([_0x962570(_0x16ebc7,_0x4266a3,_0x4c3072),F(0x1,_0x5c5393(_0x57c044)),F(0x2,_0x1fba3b),F(0x3,_0x4eefec)],$);function _0x35ee(){const _0x4f783d=['end','_instanceService','retain','onCommandExecuted','pushUndoRedo','insertLength','docs-formula.command.convert-to-text','870816XWeFIR','presentation','COMMAND','liveResult','undoMutation','getFormula','register','values','load','documentData','isArray','resourceRedo','COLUMN_GROUP_END','body','customDecorations','entries','docs-formula.command.set-number-format','push','degradeBody','pending','asObservable','PARAGRAPH','registerCommand','_loadErrors','MUTATION','customRanges','_commandService','notifyTextChanged','change$','every','formulaResult$','referenceRevision','docs-formula.mutation.remove-formula','empty','4795nPPyms','length','getCurrentUnitOfType','removeUnit','decorate','1669752CIXeqq','docs-formula.mutation.set-resource','error','nextResource','getOwnPropertyDescriptor','getPresentation','paragraphId','dispose','_cacheEligibilityService','getLoadError','resource','string','_resourceManagerService','Document\x20main\x20body\x20is\x20required\x20to\x20insert\x20Doc\x20Formula.','getTextRanges','collectMutations','COLUMN_END','sequenceNodesBuilder','setConfig','number','dataStream','_registrations','_config','TABLE_CELL_END','kind','docs-formula.command.remove','getUnit','COLUMN_START','previousDocumentData','1.0.3','_syncScheduled','_formulaKeys','750djySEq','_deleteRegistration','_pendingUnitIds','endsWith','43006RwjXnG','config','segmentId','_updateFormulaResult','getUnitId','_model','from','resolved','params','2248944klvGRE','schemaVersion','pluginName','isInteger','docs-formula.command.insert','4BXuSrP','stale','_configService','get','symbol','editOp','resourceUndo','docs-formula.mutation.set-formula','_change$','BLOCK_START','find','defineProperty','deleteLength','getRegisteredFormulas','formulaId','textRuns','blockRanges','replaceDocRanges','iterator','formula','range','resolveText','rangeId','COLUMN_GROUP_START','formulas','redoMutation','status','success','source','_docFormulaModel','removeFormula','add','EMPTY','toPrimitive','_rawResources','lastValue','name','tables','docs-formula.command.update','externalReferences','object','trigger','disabled','references','identity','filter','19025QOxAzn','next','model','13449880sXIaBd','getFormulas','start','forEach','color','min','properties','syncUnit','version','cell','parse','_formulaService','DOC','some','23umGGwg','slice','CUSTOM_BLOCK','sectionBreaks','_hostExternalReferenceModel','_queueSync','max','syncExecuteCommand','unsupported-version','pattern','CUSTOM','columnGroups','nextDocumentData','externalMutations','disposeWithMe','keys','unitId','data','_preserveInvalid','assess','_resources','ERROR','endOffset','set','has','_setPresentation','target','cursorOffset','degradeDocumentData','_injector','UNIVER_DOC','getResult','default','startIndex','insert','univer-docs-formula','resolveBinding','_syncUnit','deepClone','startOffset','getFormulaValueSync','documentRedo','resources','TABLE_ROW_START','accessor','presentationChanged$','onStarting','setFormula','DOC_FORMULA_PLUGIN','clear','map','SECTION_BREAK','sort','unregister','numberFormat','selection','invalid-resource','startsWith','stringify','updates','getRevision','type','includes','_service','_registrationService','trim','customBlocks','serialize','paragraphs','_presentationChanged$','getSnapshot','text','subscribe','getResource','endIndex','paragraph','delete','BLOCK_END','document','prototype','_univerInstanceService','unregisterUnit','resolveFormula','wholeEntity','setFormulas','getAllUnitsForType','docs-formula.mutation.set-last-values','_isDisposed','docs-formula.config','complete','setResource','position'];_0x35ee=function(){return _0x4f783d;};return _0x35ee();}export{lt as ConvertDocFormulaToTextCommand,Me as DOC_FORMULA_CUSTOM_RANGE_KIND,Ne as DOC_FORMULA_OBJECT_REPLACEMENT,y as DOC_FORMULA_PLUGIN,je as DOC_FORMULA_SCHEMA_VERSION,Z as DocFormulaDisplayTextService,Y as DocFormulaLifecycleController,P as DocFormulaModel,X as DocFormulaResourceController,it as DocFormulaResultStatus,L as DocFormulaService,U as InsertDocFormulaCommand,C as InvalidDocFormulaInsertRangeError,K as RemoveDocFormulaCommand,st as RemoveDocFormulaMutation,ct as ReplaceDocFormulaWithTextCommand,H as SetDocFormulaLastValuesMutation,ot as SetDocFormulaMutation,G as SetDocFormulaNumberFormatCommand,V as SetDocFormulaResourceMutation,$ as UniverDocsFormulaPlugin,W as UpdateDocFormulaCommand,He as assertSafeDocFormulaInsertRange,Re as buildInsertDocFormulaActions,Be as buildRemoveDocFormulaActions,ze as buildUpdateDocFormulaActions,b as createEmptyDocFormulaResource,Ot as degradeDocFormulaDocumentData,T as findDocFormulaRange,Pe as isDocFormulaConfig,w as isDocFormulaRange,x as isDocFormulaResource,Fe as isFormulaLastValue};
|
|
1
|
+
const _0x18accd=_0x7514;(function(_0x273c35,_0x52e647){const _0x4aa040=_0x7514,_0x43da88=_0x273c35();while(!![]){try{const _0x21cc0c=-parseInt(_0x4aa040(0x1e1))/0x1*(parseInt(_0x4aa040(0x216))/0x2)+parseInt(_0x4aa040(0x24c))/0x3+-parseInt(_0x4aa040(0x1fc))/0x4*(parseInt(_0x4aa040(0x262))/0x5)+parseInt(_0x4aa040(0x243))/0x6*(parseInt(_0x4aa040(0x1c7))/0x7)+-parseInt(_0x4aa040(0x219))/0x8*(-parseInt(_0x4aa040(0x22e))/0x9)+parseInt(_0x4aa040(0x273))/0xa+-parseInt(_0x4aa040(0x256))/0xb*(parseInt(_0x4aa040(0x17b))/0xc);if(_0x21cc0c===_0x52e647)break;else _0x43da88['push'](_0x43da88['shift']());}catch(_0x564810){_0x43da88['push'](_0x43da88['shift']());}}}(_0x5397,0x9962a));import{FormulaCacheEligibilityService as _0x562e65,FormulaLastValuePersistenceService as _0x29a8c7,HostExternalReferenceModel as _0x39d327,UniverProFormulaEnginePlugin as _0x351eb2,buildUpsertHostExternalReferenceMutations as _0x52d94b,collectFormulaExternalReferenceQualifiers as _0x32274e,getScalarFormulaResultCell as _0x1f7dc0,resolveFormulaResultPresentation as _0x3cd2e8,resolveHostFormulaExternalReferences as _0x4ac795,toFormulaLastValue as _0x1d1d0a}from'@univerjs-pro/engine-formula';import{CellValueType as _0x3666f9,CommandType as _0x2c4aaa,CustomRangeType as _0x5034d1,DataStreamTreeTokenType as _0x2170ed,DependentOn as _0x2a626f,Disposable as _0x474e08,ICommandService as _0x222411,IConfigService as _0x2701f4,IResourceManagerService as _0x3b184b,IUndoRedoService as _0x513fde,IUniverInstanceService as _0x478f5d,Inject as _0x2bb8ca,Injector as _0x21727e,JSONX as _0x25fe93,Plugin as _0x2ed24f,TextX as _0x4c112a,Tools as _0x240c37,UniverInstanceType as _0x50d692,generateRandomId as _0x13e167,getBodySliceForTextXAction as _0x4d9adf,getCustomRangeInterval as _0x150f27,getParagraphContentStartOffset as _0x1c8c1a,getRichTextEditPath as _0x27773c,merge as _0x350a4c,shiftExclusiveRangeOnDelete as _0x1f2bf4,shiftExclusiveRangeOnInsert as _0x577f8f,shiftInclusiveRangeOnDelete as _0x594244,shiftInclusiveRangeOnInsert as _0x31a096,touchDependencies as _0x2ca687}from'@univerjs/core';import{DOC_SELECTION_OPTION_PRESERVE_CARET as _0x3ef325,DocSelectionManagerService as _0x32a2c9,DocTextResolverService as _0x329faf,RichTextEditingMutation as _0x2fe09d,UniverDocsPlugin as _0x5b3025}from'@univerjs/docs';import{FormulaResultStatus as _0x1f2db9,LexerTreeBuilder as _0x4914fd,OtherFormulaBizType as _0x2ec085,RegisterOtherFormulaService as _0x1a621d}from'@univerjs/engine-formula';import{Subject as _0x1ec16e}from'rxjs';import{UniverLicensePlugin as _0x3c3fb2}from'@univerjs-pro/license';const y='DOC_FORMULA_PLUGIN',je=0x1,Me=_0x18accd(0x1dd),Ne='';function b(){return{'schemaVersion':0x1,'formulas':{}};}function x(_0x344097){const _0x3c82e6=_0x18accd;return!_0x344097||typeof _0x344097!=_0x3c82e6(0x224)||!S(_0x344097,[_0x3c82e6(0x1b6),_0x3c82e6(0x1b9)])||!(_0x3c82e6(0x1b6)in _0x344097)||_0x344097[_0x3c82e6(0x1b6)]!==0x1||!(_0x3c82e6(0x1b9)in _0x344097)||!_0x344097[_0x3c82e6(0x1b9)]||typeof _0x344097['formulas']!=_0x3c82e6(0x224)||Array['isArray'](_0x344097[_0x3c82e6(0x1b9)])?!0x1:Object[_0x3c82e6(0x1c5)](_0x344097['formulas'])[_0x3c82e6(0x197)](([_0x2ca7ad,_0x288a19])=>_0x2ca7ad[_0x3c82e6(0x230)]>0x0&&Pe(_0x288a19));}function Pe(_0x3f5b06){const _0x5430b8=_0x18accd;return!_0x3f5b06||typeof _0x3f5b06!=_0x5430b8(0x224)||!S(_0x3f5b06,['formula',_0x5430b8(0x255),'lastValue'])||!('formula'in _0x3f5b06)||typeof _0x3f5b06[_0x5430b8(0x193)]!=_0x5430b8(0x218)||!_0x3f5b06[_0x5430b8(0x193)][_0x5430b8(0x272)]()||_0x5430b8(0x255)in _0x3f5b06&&_0x3f5b06[_0x5430b8(0x255)]!=null&&(typeof _0x3f5b06['numberFormat']!=_0x5430b8(0x224)||!S(_0x3f5b06[_0x5430b8(0x255)],[_0x5430b8(0x1f9)])||!(_0x5430b8(0x1f9)in _0x3f5b06[_0x5430b8(0x255)])||typeof _0x3f5b06[_0x5430b8(0x255)][_0x5430b8(0x1f9)]!=_0x5430b8(0x218))?!0x1:!(_0x5430b8(0x191)in _0x3f5b06)||_0x3f5b06[_0x5430b8(0x191)]==null||Fe(_0x3f5b06[_0x5430b8(0x191)]);}function Fe(_0x5eb3da){const _0x3fa065=_0x18accd;return!_0x5eb3da||typeof _0x5eb3da!=_0x3fa065(0x224)||!S(_0x5eb3da,['v','t',_0x3fa065(0x1f9)])||!('v'in _0x5eb3da)||_0x5eb3da['v']!==null&&typeof _0x5eb3da['v']!=_0x3fa065(0x218)&&typeof _0x5eb3da['v']!=_0x3fa065(0x232)&&typeof _0x5eb3da['v']!=_0x3fa065(0x26c)||'t'in _0x5eb3da&&_0x5eb3da['t']!=null&&!Ie(_0x5eb3da['t'])?!0x1:!(_0x3fa065(0x1f9)in _0x5eb3da)||_0x5eb3da['pattern']==null||typeof _0x5eb3da['pattern']==_0x3fa065(0x218);}function S(_0x2169c6,_0x2b70a2){const _0x5c6840=_0x18accd;let _0x2efa87=new Set(_0x2b70a2);return Object[_0x5c6840(0x1c9)](_0x2169c6)[_0x5c6840(0x197)](_0x5d4a45=>_0x2efa87[_0x5c6840(0x1f5)](_0x5d4a45));}function Ie(_0x4d834f){const _0x2e85bd=_0x18accd;return typeof _0x4d834f==_0x2e85bd(0x232)&&Object[_0x2e85bd(0x269)](_0x3666f9)[_0x2e85bd(0x258)](_0x4d834f);}const Le=new Set([_0x2170ed[_0x18accd(0x1b7)],_0x2170ed[_0x18accd(0x174)],_0x2170ed[_0x18accd(0x1c4)],_0x2170ed[_0x18accd(0x1d1)],_0x2170ed['TABLE_CELL_END'],_0x2170ed[_0x18accd(0x206)],_0x2170ed['TABLE_END'],_0x2170ed[_0x18accd(0x1d4)],_0x2170ed[_0x18accd(0x22c)],_0x2170ed[_0x18accd(0x17c)],_0x2170ed[_0x18accd(0x245)],_0x2170ed[_0x18accd(0x19d)],_0x2170ed[_0x18accd(0x214)],_0x2170ed[_0x18accd(0x1ef)]]);var C=class extends Error{constructor(){const _0x15c723=_0x18accd;super(_0x15c723(0x1e5));}};function Re(_0x54cee4){const _0x4a1aa7=_0x18accd;var _0x7803a7,_0x4d47a9;let _0x4ca420=_0x240c37[_0x4a1aa7(0x1a4)](_0x54cee4['documentData']),_0x3b7cb2=j(_0x4ca420),{startOffset:_0x4b9650,endOffset:_0x1e7fa8}=We(_0x3b7cb2,_0x54cee4[_0x4a1aa7(0x23d)],_0x54cee4[_0x4a1aa7(0x200)]);He(_0x3b7cb2,_0x4b9650,_0x1e7fa8);let _0xf41f6b=((_0x7803a7=_0x3b7cb2[_0x4a1aa7(0x1a6)])==null?void 0x0:_0x7803a7['filter'](_0x4463b7=>{const _0x59a358=_0x4a1aa7;if(!w(_0x4463b7))return!0x1;let _0x5bffdb=_0x150f27(_0x4463b7);return _0x5bffdb[_0x59a358(0x200)]>_0x4b9650&&_0x5bffdb[_0x59a358(0x23d)]<_0x1e7fa8;})[_0x4a1aa7(0x1f3)](_0x3f52ba=>_0x3f52ba[_0x4a1aa7(0x251)]))??[];qe(_0x3b7cb2,_0x4b9650,_0x1e7fa8,''),_0x3b7cb2[_0x4a1aa7(0x1a6)]=[...((_0x4d47a9=_0x3b7cb2['customRanges'])==null?void 0x0:_0x4d47a9[_0x4a1aa7(0x252)](_0x5e9681=>!_0xf41f6b[_0x4a1aa7(0x258)](_0x5e9681['rangeId'])&&_0x5e9681[_0x4a1aa7(0x251)]!==_0x54cee4[_0x4a1aa7(0x251)]))??[],Ue(_0x54cee4['rangeId'],_0x4b9650)][_0x4a1aa7(0x1dc)]((_0x200734,_0x2388ab)=>_0x200734[_0x4a1aa7(0x24f)]-_0x2388ab[_0x4a1aa7(0x24f)]);let _0x1261da=E(_0x54cee4[_0x4a1aa7(0x192)]);return _0xf41f6b['forEach'](_0x110c5d=>{const _0x5bf302=_0x4a1aa7;delete _0x1261da[_0x5bf302(0x1b9)][_0x110c5d];}),_0x1261da[_0x4a1aa7(0x1b9)][_0x54cee4[_0x4a1aa7(0x251)]]=_0x240c37['deepClone'](_0x54cee4['config']),{'nextDocumentData':_0x4ca420,'nextResource':_0x1261da,'cursorOffset':_0x4b9650+0x1};}function ze(_0x2a4391){const _0xa6368f=_0x18accd;var _0x39a7ce,_0x250a9d;let _0x20c2cc=_0x240c37[_0xa6368f(0x1a4)](_0x2a4391[_0xa6368f(0x17e)]),_0x4c2a4f=(_0x39a7ce=j(_0x20c2cc)['customRanges'])==null?void 0x0:_0x39a7ce['find'](_0x1f4ce3=>_0x1f4ce3[_0xa6368f(0x251)]===_0x2a4391[_0xa6368f(0x251)]&&w(_0x1f4ce3));if(!_0x4c2a4f||!((_0x250a9d=_0x2a4391['resource'])!=null&&_0x250a9d[_0xa6368f(0x1b9)][_0x2a4391[_0xa6368f(0x251)]]))return null;let _0x3c1b47=E(_0x2a4391[_0xa6368f(0x192)]);return _0x3c1b47[_0xa6368f(0x1b9)][_0x2a4391[_0xa6368f(0x251)]]=_0x240c37['deepClone'](_0x2a4391[_0xa6368f(0x1ba)]),{'nextDocumentData':_0x20c2cc,'nextResource':_0x3c1b47,'cursorOffset':_0x4c2a4f['endIndex']+0x1};}function Be(_0x1cead2){const _0x4ac730=_0x18accd;let _0x195b93=_0x240c37['deepClone'](_0x1cead2['documentData']),_0x3c2a90=Je(_0x195b93,_0x1cead2[_0x4ac730(0x251)],_0x1cead2['text']??'');if(_0x3c2a90==null)return null;let _0x24e595=E(_0x1cead2[_0x4ac730(0x192)]);return delete _0x24e595[_0x4ac730(0x1b9)][_0x1cead2[_0x4ac730(0x251)]],{'nextDocumentData':_0x195b93,'nextResource':_0x24e595,'cursorOffset':_0x3c2a90};}function Ve(_0x53e3f1,_0x395441){const _0x3f424e=_0x18accd;var _0x1119bf;let _0x124bee=_0x240c37['deepClone'](_0x53e3f1),_0x3b4054=_0x124bee[_0x3f424e(0x212)];if(!_0x3b4054)return _0x124bee;let _0x5b2344=new Map(_0x395441[_0x3f424e(0x1f3)](_0xb317c9=>[_0xb317c9[_0x3f424e(0x251)],_0xb317c9['text']])),_0x5abc6e=((_0x1119bf=_0x3b4054[_0x3f424e(0x1a6)])==null?void 0x0:_0x1119bf[_0x3f424e(0x252)](_0x2fc614=>w(_0x2fc614)&&_0x5b2344[_0x3f424e(0x1f5)](_0x2fc614['rangeId']))[_0x3f424e(0x1dc)]((_0x522338,_0x14dfe9)=>_0x14dfe9[_0x3f424e(0x24f)]-_0x522338['startIndex']))??[];for(let _0x5dee21 of _0x5abc6e)Je(_0x124bee,_0x5dee21[_0x3f424e(0x251)],_0x5b2344[_0x3f424e(0x1ab)](_0x5dee21['rangeId'])??'');return _0x124bee;}function w(_0x484d73){const _0x32ab81=_0x18accd;var _0x5c91ac;return(_0x484d73==null?void 0x0:_0x484d73[_0x32ab81(0x176)])===_0x5034d1[_0x32ab81(0x231)]&&_0x484d73[_0x32ab81(0x240)]===!0x0&&((_0x5c91ac=_0x484d73[_0x32ab81(0x20f)])==null?void 0x0:_0x5c91ac[_0x32ab81(0x268)])===_0x32ab81(0x1dd);}function T(_0x56a2d3,_0x3e5208){const _0x30ab57=_0x18accd;var _0x1feebd;return _0x56a2d3==null||(_0x1feebd=_0x56a2d3[_0x30ab57(0x1a6)])==null?void 0x0:_0x1feebd[_0x30ab57(0x20a)](_0x511678=>_0x511678[_0x30ab57(0x251)]===_0x3e5208&&w(_0x511678));}function He(_0x3be2be,_0x1efa2a,_0x7f8b40){const _0x5884a0=_0x18accd;if(_0x1efa2a===_0x7f8b40){if(Le[_0x5884a0(0x1f5)](_0x3be2be['dataStream'][_0x1efa2a]))throw new C();}else{for(let _0x84ed1f=_0x1efa2a;_0x84ed1f<_0x7f8b40;_0x84ed1f++)if(_0x3be2be[_0x5884a0(0x1d2)][_0x84ed1f]===_0x2170ed['PARAGRAPH']||Le[_0x5884a0(0x1f5)](_0x3be2be[_0x5884a0(0x1d2)][_0x84ed1f]))throw new C();}}function Ue(_0xb20bc5,_0x2c5561){const _0x5ccaa9=_0x18accd;return{'startIndex':_0x2c5561,'endIndex':_0x2c5561,'rangeId':_0xb20bc5,'rangeType':_0x5034d1[_0x5ccaa9(0x231)],'wholeEntity':!0x0,'properties':{'kind':Me}};}function E(_0x2e474f){const _0x501889=_0x18accd;return _0x2e474f?_0x240c37[_0x501889(0x1a4)](_0x2e474f):b();}function We(_0x1ae661,_0x58700e,_0x2a8704){const _0x12cdb8=_0x18accd;let _0x363931=Ke(_0x1ae661),_0x142722=_0x58700e??_0x363931,_0x35ed94=_0x2a8704??_0x142722;return{'startOffset':Ge(Math[_0x12cdb8(0x1da)](_0x142722,_0x35ed94),_0x363931),'endOffset':Ge(Math[_0x12cdb8(0x1d6)](_0x142722,_0x35ed94),_0x363931)};}function Ge(_0x58958b,_0x2e2cd4){const _0x315b4e=_0x18accd;return Math[_0x315b4e(0x1d6)](0x0,Math['min'](_0x58958b,_0x2e2cd4));}function Ke(_0x18ce3d){const _0x1222c1=_0x18accd;return _0x18ce3d[_0x1222c1(0x1d2)][_0x1222c1(0x1b3)](''+_0x2170ed[_0x1222c1(0x1fd)]+_0x2170ed[_0x1222c1(0x1b7)])?Math[_0x1222c1(0x1d6)](0x0,_0x18ce3d[_0x1222c1(0x1d2)][_0x1222c1(0x230)]-0x2):_0x18ce3d[_0x1222c1(0x1d2)][_0x1222c1(0x1b3)](_0x2170ed[_0x1222c1(0x1b7)])?Math[_0x1222c1(0x1d6)](0x0,_0x18ce3d['dataStream']['length']-0x1):_0x18ce3d[_0x1222c1(0x1d2)]['length'];}function qe(_0x110ad0,_0x23c137,_0x24a03f,_0x347c6c){_0x24a03f>_0x23c137&&Xe(_0x110ad0,_0x23c137,_0x24a03f),Ye(_0x110ad0,_0x23c137,_0x347c6c);}function Je(_0x2a8b40,_0x433896,_0x45b4d5){const _0x2b04fe=_0x18accd;var _0x325f85,_0x4bd112;let _0x46c205=j(_0x2a8b40),_0x415d15=(_0x325f85=_0x46c205[_0x2b04fe(0x1a6)])==null?void 0x0:_0x325f85[_0x2b04fe(0x20a)](_0x55b043=>_0x55b043['rangeId']===_0x433896&&w(_0x55b043));if(!_0x415d15)return null;let _0x1e8069=_0x150f27(_0x415d15);return qe(_0x46c205,_0x1e8069['startOffset'],_0x1e8069[_0x2b04fe(0x200)],_0x45b4d5),_0x46c205['customRanges']=(_0x4bd112=_0x46c205['customRanges'])==null?void 0x0:_0x4bd112['filter'](_0x162182=>_0x162182[_0x2b04fe(0x251)]!==_0x433896),_0x1e8069[_0x2b04fe(0x23d)]+_0x45b4d5[_0x2b04fe(0x230)];}function Ye(_0x1cafbc,_0x22c125,_0x7db800){const _0xca0d75=_0x18accd;_0x7db800&&(_0x1cafbc[_0xca0d75(0x1d2)]=''+_0x1cafbc[_0xca0d75(0x1d2)][_0xca0d75(0x22a)](0x0,_0x22c125)+_0x7db800+_0x1cafbc['dataStream'][_0xca0d75(0x22a)](_0x22c125),Ze(_0x1cafbc,_0x22c125,_0x7db800[_0xca0d75(0x230)]));}function Xe(_0xdd9274,_0x4e2b9f,_0x4696aa){const _0x5e9033=_0x18accd;let _0x20d945=_0x4696aa-_0x4e2b9f;_0xdd9274[_0x5e9033(0x1d2)]=''+_0xdd9274[_0x5e9033(0x1d2)][_0x5e9033(0x22a)](0x0,_0x4e2b9f)+_0xdd9274[_0x5e9033(0x1d2)][_0x5e9033(0x22a)](_0x4696aa),Qe(_0xdd9274,_0x4e2b9f,_0x20d945);}function Ze(_0x1a1957,_0x19ca08,_0x45af4c){const _0x378a35=_0x18accd;_0x1a1957[_0x378a35(0x18d)]=D(_0x1a1957[_0x378a35(0x18d)],_0x19ca08,_0x45af4c),_0x1a1957[_0x378a35(0x20e)]=D(_0x1a1957[_0x378a35(0x20e)],_0x19ca08,_0x45af4c),_0x1a1957[_0x378a35(0x18c)]=D(_0x1a1957['customBlocks'],_0x19ca08,_0x45af4c),_0x1a1957['textRuns']=$e(_0x1a1957[_0x378a35(0x1e4)],_0x19ca08,_0x45af4c),_0x1a1957[_0x378a35(0x20b)]=et(_0x1a1957['tables'],_0x19ca08,_0x45af4c),_0x1a1957[_0x378a35(0x270)]=k(_0x1a1957[_0x378a35(0x270)],_0x19ca08,_0x45af4c),_0x1a1957[_0x378a35(0x1a6)]=k(_0x1a1957['customRanges'],_0x19ca08,_0x45af4c),_0x1a1957[_0x378a35(0x1cd)]=k(_0x1a1957['customDecorations'],_0x19ca08,_0x45af4c),_0x1a1957['blockRanges']=k(_0x1a1957['blockRanges'],_0x19ca08,_0x45af4c);}function _0x5397(){const _0x2b8957=['formulaId','paragraph','pattern','startsWith','EMPTY','132esgrMo','PARAGRAPH','model','_formulaKeys','endOffset','deleteFormula','trigger','unsupported-version','registerFormulaWithRange','pushUndoRedo','TABLE_ROW_END','range','parse','decorate','find','tables','docs-formula.command.remove','_presentationChanged$','sectionBreaks','properties','insertLength','_hostExternalReferenceModel','body','invalid-resource','BLOCK_END','registerPluginResource','1097396tEbydu','documentRedo','string','8LZBHpj','_deleteRegistration','docs-formula.command.replace-with-text','cell','setFormula','defineProperty','redoMutation','expectedNumberFormat','blockRanges','getBody','disposeWithMe','object','some','_rawResources','_commandService','_univerInstanceService','resourceRedo','slice','replaceDocRanges','COLUMN_START','docs-formula.mutation.set-formula','10342791tomNcH','docs-formula.config','length','CUSTOM','number','function','sequenceNodesBuilder','empty','selection','serialize','_queueSync','isInteger','nextResource','resourceUndo','docs-formula.command.insert','startOffset','symbol','_syncUnit','wholeEntity','getResult','text','1014YJGGnd','color','COLUMN_GROUP_END','externalMutations','liveResult','setResource','setFormulas','cursorOffset','_cacheEligibilityService','450867DfRcBS','UNIVER_DOC','externalReferences','startIndex','type','rangeId','filter','push','document','numberFormat','11ttnRiE','getUnit','includes','resolveText','getFormula','delete','change$','docs-formula.command.set-number-format','assign','default','eligible','getLoadError','73195LmCjnD','resources','updates','_updateFormulaResult','getUnitId','clear','kind','values','getResource','getFormulas','boolean','getRevision','_change$','referenceRevision','columnGroups','resolveFormula','trim','234590MUUdJC','_loadErrors','TABLE_START','identity','rangeType','docs-formula.command.update','nextDocumentData','_configService','version','5380896YrmuEk','COLUMN_END','DOC_FORMULA_PLUGIN','documentData','_model','deleteLength','_service','call','removeFormula','stringify','expectedFormula','dispose','editOp','next','presentation','asObservable','data','customBlocks','paragraphs','status','getTextRanges','MUTATION','lastValue','resource','formula','_setPresentation','getCurrentUnitOfType','accessor','every','unregister','retain','load','_config','forEach','BLOCK_START','references','endIndex','getPresentation','segmentId','unregisterUnit','_isDisposed','deepClone','success','customRanges','_pendingUnitIds','register','ERROR','start','get','_resources','unitId','unitDisposed$','add','resolved','getSnapshot','syncUnit','endsWith','_instanceService','degradeDocumentData','schemaVersion','SECTION_BREAK','syncExecuteCommand','formulas','config','removeUnit','_registrationService','complete','error','_registrations','prototype','target','presentationChanged$','onCommandExecuted','TABLE_ROW_START','entries','resolveBinding','32536JmBRsu','name','keys','getOwnPropertyDescriptor','stale','setConfig','customDecorations','_formulaService','Document\x20main\x20body\x20is\x20required\x20to\x20insert\x20Doc\x20Formula.','PENDING','TABLE_CELL_START','dataStream','subscribe','COLUMN_GROUP_START','set','max','onStarting','SUCCESS','_preserveInvalid','min','iterator','sort','univer-docs-formula','pluginName','params','_docFormulaModel','1PpzLRN','position','_injector','textRuns','Doc\x20Formula\x20range\x20cannot\x20cross\x20document\x20structure\x20boundaries','source','registerCommand','getFormulaValueSync','pending','formulaResult$','_syncScheduled','from','insert','previousDocumentData','CUSTOM_BLOCK','COMMAND','undoMutation','getRegisteredFormulas','map','getInstance','has','getAllUnitsForType'];_0x5397=function(){return _0x2b8957;};return _0x5397();}function Qe(_0x1eddb0,_0x814e3f,_0x51e098){const _0xd7baac=_0x18accd;var _0x3adf4e,_0xe627d5;_0x1eddb0[_0xd7baac(0x18d)]=O(_0x1eddb0['paragraphs'],_0x814e3f,_0x51e098),_0x1eddb0[_0xd7baac(0x20e)]=O(_0x1eddb0[_0xd7baac(0x20e)],_0x814e3f,_0x51e098),_0x1eddb0[_0xd7baac(0x18c)]=O(_0x1eddb0[_0xd7baac(0x18c)],_0x814e3f,_0x51e098),_0x1eddb0['textRuns']=(_0x3adf4e=tt((_0xe627d5=_0x1eddb0['textRuns'])==null?void 0x0:_0xe627d5['map'](_0x414ef8=>({..._0x414ef8,'startIndex':_0x414ef8['st'],'endIndex':_0x414ef8['ed']})),_0x814e3f,_0x51e098))==null?void 0x0:_0x3adf4e[_0xd7baac(0x1f3)](_0x5c77cc=>{let {startIndex:_0x4b55bc,endIndex:_0x552e87,..._0x353b1f}=_0x5c77cc;return{..._0x353b1f,'st':_0x4b55bc,'ed':_0x552e87};}),_0x1eddb0[_0xd7baac(0x20b)]=tt(_0x1eddb0['tables'],_0x814e3f,_0x51e098),_0x1eddb0['columnGroups']=A(_0x1eddb0['columnGroups'],_0x814e3f,_0x51e098),_0x1eddb0['customRanges']=A(_0x1eddb0[_0xd7baac(0x1a6)],_0x814e3f,_0x51e098),_0x1eddb0[_0xd7baac(0x1cd)]=A(_0x1eddb0[_0xd7baac(0x1cd)],_0x814e3f,_0x51e098),_0x1eddb0[_0xd7baac(0x221)]=A(_0x1eddb0[_0xd7baac(0x221)],_0x814e3f,_0x51e098);}function D(_0x2bb4e4,_0x3c3e72,_0x4beb38){const _0x3c4b66=_0x18accd;return _0x2bb4e4==null?void 0x0:_0x2bb4e4[_0x3c4b66(0x1f3)](_0x5ba4a9=>_0x5ba4a9[_0x3c4b66(0x24f)]>=_0x3c3e72?{..._0x5ba4a9,'startIndex':_0x5ba4a9[_0x3c4b66(0x24f)]+_0x4beb38}:_0x5ba4a9);}function O(_0x5dcd7f,_0x2011c0,_0x16deca){const _0x3b5e55=_0x18accd;let _0x599e09=_0x2011c0+_0x16deca;return _0x5dcd7f==null?void 0x0:_0x5dcd7f[_0x3b5e55(0x1f3)](_0x487c1c=>_0x487c1c[_0x3b5e55(0x24f)]>=_0x2011c0&&_0x487c1c[_0x3b5e55(0x24f)]<_0x599e09?null:_0x487c1c['startIndex']>=_0x599e09?{..._0x487c1c,'startIndex':_0x487c1c[_0x3b5e55(0x24f)]-_0x16deca}:_0x487c1c)[_0x3b5e55(0x252)](_0x57267b=>_0x57267b!=null);}function $e(_0x305acd,_0x3e4312,_0x405c18){const _0x5995f8=_0x18accd;return _0x305acd==null?void 0x0:_0x305acd[_0x5995f8(0x1f3)](_0xc71178=>_0xc71178['st']>=_0x3e4312?{..._0xc71178,'st':_0xc71178['st']+_0x405c18,'ed':_0xc71178['ed']+_0x405c18}:_0xc71178['ed']>_0x3e4312?{..._0xc71178,'ed':_0xc71178['ed']+_0x405c18}:_0xc71178);}function k(_0x4e97e1,_0x2c2e32,_0x5ce83c){return _0x4e97e1==null?void 0x0:_0x4e97e1['map'](_0x160fea=>_0x31a096(_0x160fea,_0x2c2e32,_0x5ce83c));}function et(_0x5f5d3e,_0x283588,_0x565763){const _0x299c01=_0x18accd;return _0x5f5d3e==null?void 0x0:_0x5f5d3e[_0x299c01(0x1f3)](_0x1262ba=>_0x577f8f(_0x1262ba,_0x283588,_0x565763));}function A(_0x3469f0,_0x2a3403,_0x34a708){const _0x283fe6=_0x18accd;return _0x3469f0==null?void 0x0:_0x3469f0[_0x283fe6(0x1f3)](_0x5bada8=>_0x594244(_0x5bada8,_0x2a3403,_0x34a708))[_0x283fe6(0x252)](_0x276490=>_0x276490!=null);}function tt(_0x6cd74a,_0x6f48fc,_0x344e9a){const _0xf72a5c=_0x18accd;return _0x6cd74a==null?void 0x0:_0x6cd74a['map'](_0xf7ad2a=>_0x1f2bf4(_0xf7ad2a,_0x6f48fc,_0x344e9a))[_0xf72a5c(0x252)](_0x107c21=>_0x107c21!=null);}function j(_0x30eed3){const _0x35f2df=_0x18accd;if(!_0x30eed3['body'])throw Error(_0x35f2df(0x1cf));return _0x30eed3['body'];}function M(_0xdbd6e4){'@babel/helpers - typeof';const _0x476da2=_0x18accd;return M=typeof Symbol==_0x476da2(0x233)&&typeof Symbol[_0x476da2(0x1db)]==_0x476da2(0x23e)?function(_0x106f38){return typeof _0x106f38;}:function(_0x15d522){const _0x898968=_0x476da2;return _0x15d522&&typeof Symbol==_0x898968(0x233)&&_0x15d522['constructor']===Symbol&&_0x15d522!==Symbol[_0x898968(0x1c0)]?_0x898968(0x23e):typeof _0x15d522;},M(_0xdbd6e4);}function nt(_0x404754,_0x335bbc){const _0x2be563=_0x18accd;if(M(_0x404754)!='object'||!_0x404754)return _0x404754;var _0x2d6f32=_0x404754[Symbol['toPrimitive']];if(_0x2d6f32!==void 0x0){var _0xbe45f3=_0x2d6f32[_0x2be563(0x182)](_0x404754,_0x335bbc||_0x2be563(0x25f));if(M(_0xbe45f3)!='object')return _0xbe45f3;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x335bbc===_0x2be563(0x218)?String:Number)(_0x404754);}function rt(_0x347a2e){const _0x1c34eb=_0x18accd;var _0x1aafee=nt(_0x347a2e,_0x1c34eb(0x218));return M(_0x1aafee)=='symbol'?_0x1aafee:_0x1aafee+'';}function N(_0x290c0b,_0x4219a2,_0x48620b){return(_0x4219a2=rt(_0x4219a2))in _0x290c0b?Object['defineProperty'](_0x290c0b,_0x4219a2,{'value':_0x48620b,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x290c0b[_0x4219a2]=_0x48620b,_0x290c0b;}var P=class extends _0x474e08{constructor(..._0x297f4d){const _0x2b6ca4=_0x18accd;super(..._0x297f4d),N(this,_0x2b6ca4(0x1ac),new Map()),N(this,'_rawResources',new Map()),N(this,_0x2b6ca4(0x173),new Map()),N(this,'_change$',new _0x1ec16e()),N(this,_0x2b6ca4(0x25c),this['_change$'][_0x2b6ca4(0x18a)]());}[_0x18accd(0x25a)](_0x560461,_0x1cf4ed){const _0x29ebf1=_0x18accd;var _0x3fd025;let _0x5429e2=(_0x3fd025=this['_resources'][_0x29ebf1(0x1ab)](_0x560461))==null?void 0x0:_0x3fd025[_0x29ebf1(0x1b9)][_0x1cf4ed];return _0x5429e2?_0x240c37['deepClone'](_0x5429e2):void 0x0;}['getFormulas'](_0x437ed2){const _0x4c3e33=_0x18accd;var _0x2d8c1e;return _0x240c37[_0x4c3e33(0x1a4)](((_0x2d8c1e=this['_resources'][_0x4c3e33(0x1ab)](_0x437ed2))==null?void 0x0:_0x2d8c1e['formulas'])??{});}['getResource'](_0x1fe717){const _0xbfa4ee=_0x18accd;let _0x349b5d=this[_0xbfa4ee(0x1ac)][_0xbfa4ee(0x1ab)](_0x1fe717);return _0x349b5d?_0x240c37[_0xbfa4ee(0x1a4)](_0x349b5d):void 0x0;}[_0x18accd(0x21d)](_0x354d50,_0x21273c,_0x1db87d){const _0x7d6ad4=_0x18accd;return this[_0x7d6ad4(0x249)](_0x354d50,{[_0x21273c]:_0x1db87d});}[_0x18accd(0x248)](_0x42b792,_0x5ec5f7){const _0x4ae753=_0x18accd;return this['_loadErrors']['has'](_0x42b792)||!x(_0x5ec5f7)?!0x1:(this[_0x4ae753(0x1ac)]['set'](_0x42b792,_0x240c37['deepClone'](_0x5ec5f7)),this[_0x4ae753(0x26e)][_0x4ae753(0x188)]({'unitId':_0x42b792}),!0x0);}[_0x18accd(0x249)](_0xa0343b,_0x16ce1d){const _0x2f5142=_0x18accd;if(this[_0x2f5142(0x173)][_0x2f5142(0x1f5)](_0xa0343b)||!Object[_0x2f5142(0x1c9)](_0x16ce1d)[_0x2f5142(0x230)]||!x({'schemaVersion':0x1,'formulas':_0x16ce1d}))return!0x1;let _0x238d2a=this[_0x2f5142(0x1ac)][_0x2f5142(0x1ab)](_0xa0343b)??b(),_0xbfe465=_0x240c37[_0x2f5142(0x1a4)](_0x238d2a);return Object[_0x2f5142(0x25e)](_0xbfe465[_0x2f5142(0x1b9)],_0x240c37['deepClone'](_0x16ce1d)),this[_0x2f5142(0x1ac)][_0x2f5142(0x1d5)](_0xa0343b,_0xbfe465),this[_0x2f5142(0x26e)][_0x2f5142(0x188)]({'unitId':_0xa0343b,'rangeIds':Object[_0x2f5142(0x1c9)](_0x16ce1d)}),!0x0;}[_0x18accd(0x183)](_0x56bd93,_0x5054b7){const _0x1336b3=_0x18accd;if(this[_0x1336b3(0x173)][_0x1336b3(0x1f5)](_0x56bd93))return!0x1;let _0x632cd=this['_resources'][_0x1336b3(0x1ab)](_0x56bd93);if(!(_0x632cd!=null&&_0x632cd['formulas'][_0x5054b7]))return!0x1;let _0x52c554=_0x240c37[_0x1336b3(0x1a4)](_0x632cd);return delete _0x52c554['formulas'][_0x5054b7],this['_resources'][_0x1336b3(0x1d5)](_0x56bd93,_0x52c554),this['_change$'][_0x1336b3(0x188)]({'unitId':_0x56bd93,'rangeIds':[_0x5054b7]}),!0x0;}['load'](_0x3c93e5,_0x1dd4eb){const _0x44cfed=_0x18accd;return _0x1dd4eb&&typeof _0x1dd4eb=='object'&&_0x44cfed(0x1b6)in _0x1dd4eb&&_0x1dd4eb[_0x44cfed(0x1b6)]!==0x1?(this[_0x44cfed(0x1d9)](_0x3c93e5,_0x1dd4eb,_0x44cfed(0x203)),!0x1):x(_0x1dd4eb)?(this[_0x44cfed(0x1ac)][_0x44cfed(0x1d5)](_0x3c93e5,_0x240c37[_0x44cfed(0x1a4)](_0x1dd4eb)),this['_rawResources']['delete'](_0x3c93e5),this[_0x44cfed(0x173)]['delete'](_0x3c93e5),this[_0x44cfed(0x26e)]['next']({'unitId':_0x3c93e5}),!0x0):(this['_preserveInvalid'](_0x3c93e5,_0x1dd4eb,_0x44cfed(0x213)),!0x1);}['serialize'](_0x23ed9a){const _0x5e5110=_0x18accd;let _0x56a937=this[_0x5e5110(0x1ac)][_0x5e5110(0x1ab)](_0x23ed9a);return _0x56a937?_0x240c37[_0x5e5110(0x1a4)](_0x56a937):this[_0x5e5110(0x226)]['has'](_0x23ed9a)?_0x240c37[_0x5e5110(0x1a4)](this[_0x5e5110(0x226)][_0x5e5110(0x1ab)](_0x23ed9a)):b();}[_0x18accd(0x261)](_0x531c9b){const _0x3e3611=_0x18accd;return this[_0x3e3611(0x173)][_0x3e3611(0x1ab)](_0x531c9b);}[_0x18accd(0x1bb)](_0x43ec4b){const _0x5e47e6=_0x18accd;this[_0x5e47e6(0x1ac)][_0x5e47e6(0x25b)](_0x43ec4b),this[_0x5e47e6(0x226)][_0x5e47e6(0x25b)](_0x43ec4b),this['_loadErrors']['delete'](_0x43ec4b),this[_0x5e47e6(0x26e)][_0x5e47e6(0x188)]({'unitId':_0x43ec4b});}[_0x18accd(0x186)](){const _0x125b47=_0x18accd;this[_0x125b47(0x1ac)][_0x125b47(0x267)](),this['_rawResources'][_0x125b47(0x267)](),this[_0x125b47(0x173)][_0x125b47(0x267)](),this[_0x125b47(0x26e)][_0x125b47(0x1bd)](),super['dispose']();}[_0x18accd(0x1d9)](_0x1ffdd6,_0x230dc4,_0x3287a1){const _0x595e8b=_0x18accd;this['_resources']['delete'](_0x1ffdd6),this[_0x595e8b(0x226)][_0x595e8b(0x1d5)](_0x1ffdd6,_0x240c37[_0x595e8b(0x1a4)](_0x230dc4)),this[_0x595e8b(0x173)][_0x595e8b(0x1d5)](_0x1ffdd6,_0x3287a1),this['_change$']['next']({'unitId':_0x1ffdd6});}};let it=function(_0x3db238){const _0x43d3f4=_0x18accd;return _0x3db238[_0x43d3f4(0x1fb)]=_0x43d3f4(0x235),_0x3db238[_0x43d3f4(0x1d0)]=_0x43d3f4(0x1e9),_0x3db238[_0x43d3f4(0x1d8)]=_0x43d3f4(0x1a5),_0x3db238[_0x43d3f4(0x1a9)]=_0x43d3f4(0x1be),_0x3db238;}({});function F(_0x144c97,_0x4a343b){return function(_0x8dd12a,_0x5a5b8d){_0x4a343b(_0x8dd12a,_0x5a5b8d,_0x144c97);};}function I(_0xe6873f,_0x2d73d9,_0x5d5587,_0x5bba90){const _0x2d14c9=_0x18accd;var _0x399f21=arguments[_0x2d14c9(0x230)],_0x2468eb=_0x399f21<0x3?_0x2d73d9:_0x5bba90===null?_0x5bba90=Object[_0x2d14c9(0x1ca)](_0x2d73d9,_0x5d5587):_0x5bba90,_0x3cbae7;if(typeof Reflect==_0x2d14c9(0x224)&&typeof Reflect['decorate']=='function')_0x2468eb=Reflect[_0x2d14c9(0x209)](_0xe6873f,_0x2d73d9,_0x5d5587,_0x5bba90);else{for(var _0x100a5f=_0xe6873f[_0x2d14c9(0x230)]-0x1;_0x100a5f>=0x0;_0x100a5f--)(_0x3cbae7=_0xe6873f[_0x100a5f])&&(_0x2468eb=(_0x399f21<0x3?_0x3cbae7(_0x2468eb):_0x399f21>0x3?_0x3cbae7(_0x2d73d9,_0x5d5587,_0x2468eb):_0x3cbae7(_0x2d73d9,_0x5d5587))||_0x2468eb);}return _0x399f21>0x3&&_0x2468eb&&Object[_0x2d14c9(0x21e)](_0x2d73d9,_0x5d5587,_0x2468eb),_0x2468eb;}let L=class extends _0x474e08{constructor(_0x228b77,_0x46ebfa,_0x34c280){const _0x34263f=_0x18accd;super(),this['_model']=_0x228b77,this[_0x34263f(0x1bc)]=_0x46ebfa,this['_hostExternalReferenceModel']=_0x34c280,N(this,_0x34263f(0x1bf),new Map()),N(this,'_formulaKeys',new Map()),N(this,_0x34263f(0x20d),new _0x1ec16e()),N(this,_0x34263f(0x1c2),this[_0x34263f(0x20d)][_0x34263f(0x18a)]()),this[_0x34263f(0x223)](this[_0x34263f(0x1bc)][_0x34263f(0x1ea)]['subscribe'](_0xa9c5a9=>{const _0x4edb87=_0x34263f;for(let _0x44903d of Object[_0x4edb87(0x269)](_0xa9c5a9))for(let _0x1455a9 of Object[_0x4edb87(0x269)](_0x44903d))_0x1455a9['forEach'](_0x1635ce=>this[_0x4edb87(0x265)](_0x1635ce));}));}['syncUnit'](_0x493679){const _0xcaf973=_0x18accd;var _0x17a5c2;let _0x898cbe=_0x493679['getUnitId'](),_0x39fc89=((_0x17a5c2=_0x493679[_0xcaf973(0x1b1)]()[_0xcaf973(0x212)])==null||(_0x17a5c2=_0x17a5c2[_0xcaf973(0x1a6)])==null?void 0x0:_0x17a5c2[_0xcaf973(0x252)](w))??[],_0x51612f=this[_0xcaf973(0x17f)][_0xcaf973(0x26b)](_0x898cbe),_0x409e41=new Set();for(let _0x574b01 of _0x39fc89){let _0x3e3645=_0x51612f[_0x574b01[_0xcaf973(0x251)]];_0x3e3645&&(_0x409e41[_0xcaf973(0x1af)](R(_0x898cbe,_0x574b01[_0xcaf973(0x251)])),this['register']({'unitId':_0x898cbe,'rangeId':_0x574b01[_0xcaf973(0x251)]},_0x3e3645));}for(let _0xfb8e5e of Array[_0xcaf973(0x1ec)](this[_0xcaf973(0x1bf)][_0xcaf973(0x269)]()))_0xfb8e5e[_0xcaf973(0x1ad)]===_0x898cbe&&!_0x409e41[_0xcaf973(0x1f5)](R(_0xfb8e5e[_0xcaf973(0x1ad)],_0xfb8e5e[_0xcaf973(0x251)]))&&this[_0xcaf973(0x198)](_0xfb8e5e);}[_0x18accd(0x1a8)](_0x59256b,_0x203d10){const _0x50b16d=_0x18accd;let _0x495cf9=R(_0x59256b['unitId'],_0x59256b[_0x50b16d(0x251)]),_0x433eb2=this[_0x50b16d(0x1bf)][_0x50b16d(0x1ab)](_0x495cf9),_0xd6e365=this[_0x50b16d(0x211)][_0x50b16d(0x26d)](_0x59256b[_0x50b16d(0x1ad)]);if(_0x433eb2&&_0x433eb2['config']['formula']===_0x203d10['formula']&&_0x433eb2[_0x50b16d(0x26f)]===_0xd6e365){_0x433eb2['config']=_0x203d10;let _0x330802=_0x433eb2['formulaId']?this[_0x50b16d(0x1bc)][_0x50b16d(0x1e8)](_0x433eb2[_0x50b16d(0x1ad)],_0x433eb2[_0x50b16d(0x1ad)],_0x433eb2[_0x50b16d(0x1f7)])??void 0x0:void 0x0;_0x433eb2[_0x50b16d(0x247)]=_0x330802,this[_0x50b16d(0x194)](_0x495cf9,z(_0x203d10,_0x330802));return;}_0x433eb2!=null&&_0x433eb2[_0x50b16d(0x1f7)]&&this['_deleteRegistration'](_0x433eb2);let _0x74c8fc={..._0x59256b,'config':_0x203d10,'referenceRevision':_0xd6e365,'presentation':z(_0x203d10,void 0x0)};if(this[_0x50b16d(0x1bf)][_0x50b16d(0x1d5)](_0x495cf9,_0x74c8fc),!_0x203d10[_0x50b16d(0x193)]['trim']())return;let _0x90be99=this['_registrationService'][_0x50b16d(0x204)](_0x59256b[_0x50b16d(0x1ad)],_0x59256b[_0x50b16d(0x1ad)],_0x203d10[_0x50b16d(0x193)],void 0x0,{'rangeId':_0x59256b[_0x50b16d(0x251)]},_0x2ec085['DOC'],_0x59256b[_0x50b16d(0x251)]);_0x74c8fc['formulaId']=_0x90be99,this[_0x50b16d(0x1ff)][_0x50b16d(0x1d5)](_0x90be99,_0x495cf9);}[_0x18accd(0x198)](_0x3ce936){const _0x49c7f6=_0x18accd;let _0xd51455=R(_0x3ce936[_0x49c7f6(0x1ad)],_0x3ce936[_0x49c7f6(0x251)]),_0x24ea07=this[_0x49c7f6(0x1bf)]['get'](_0xd51455);_0x24ea07&&(this[_0x49c7f6(0x21a)](_0x24ea07),this[_0x49c7f6(0x1bf)]['delete'](_0xd51455));}[_0x18accd(0x1a2)](_0x369e49){const _0x556cc4=_0x18accd;for(let _0x24a586 of Array['from'](this[_0x556cc4(0x1bf)][_0x556cc4(0x269)]()))_0x24a586[_0x556cc4(0x1ad)]===_0x369e49&&this[_0x556cc4(0x198)](_0x24a586);}[_0x18accd(0x1a0)](_0x5e4d65){const _0x1bb8b5=_0x18accd;var _0x1952e0;return(_0x1952e0=this['_registrations'][_0x1bb8b5(0x1ab)](R(_0x5e4d65['unitId'],_0x5e4d65[_0x1bb8b5(0x251)])))==null?void 0x0:_0x1952e0[_0x1bb8b5(0x189)];}[_0x18accd(0x241)](_0x59975e){const _0x37447b=_0x18accd;let _0x38cc95=this[_0x37447b(0x1bf)][_0x37447b(0x1ab)](R(_0x59975e[_0x37447b(0x1ad)],_0x59975e[_0x37447b(0x251)]));return _0x38cc95?B(_0x38cc95):void 0x0;}['getRegisteredFormulas'](){const _0x1db8e8=_0x18accd;return Array[_0x1db8e8(0x1ec)](this[_0x1db8e8(0x1bf)]['values'](),_0x878ebe=>({'identity':{'unitId':_0x878ebe[_0x1db8e8(0x1ad)],'rangeId':_0x878ebe[_0x1db8e8(0x251)]},'config':_0x878ebe[_0x1db8e8(0x1ba)],'referenceRevision':_0x878ebe['referenceRevision'],..._0x878ebe[_0x1db8e8(0x247)]?{'liveResult':_0x878ebe[_0x1db8e8(0x247)]}:null}));}['dispose'](){const _0x3d7a66=_0x18accd;for(let _0x5371a9 of this[_0x3d7a66(0x1bf)][_0x3d7a66(0x269)]())this[_0x3d7a66(0x21a)](_0x5371a9);this[_0x3d7a66(0x1bf)][_0x3d7a66(0x267)](),this[_0x3d7a66(0x1ff)][_0x3d7a66(0x267)](),this['_presentationChanged$'][_0x3d7a66(0x1bd)](),super[_0x3d7a66(0x186)]();}[_0x18accd(0x265)](_0x41a9f6){const _0x27ac94=_0x18accd;let _0x27fd4b=this['_formulaKeys'][_0x27ac94(0x1ab)](_0x41a9f6[_0x27ac94(0x1f7)]),_0x24c6dd=_0x27fd4b?this['_registrations']['get'](_0x27fd4b):void 0x0;_0x27fd4b&&_0x24c6dd&&(_0x24c6dd[_0x27ac94(0x247)]=_0x41a9f6,this[_0x27ac94(0x194)](_0x27fd4b,z(_0x24c6dd[_0x27ac94(0x1ba)],_0x41a9f6)));}[_0x18accd(0x194)](_0x55ad56,_0x33ff8b){const _0x1e5490=_0x18accd;var _0xed896,_0x1fbe14;let _0x5c92ab=this['_registrations']['get'](_0x55ad56);if(!_0x5c92ab||at(_0x5c92ab['presentation'],_0x33ff8b))return;let _0x5437ee=_0x5c92ab[_0x1e5490(0x189)],_0x201675=B(_0x5c92ab);_0x5c92ab[_0x1e5490(0x189)]=_0x33ff8b,this[_0x1e5490(0x20d)][_0x1e5490(0x188)]({'unitId':_0x5c92ab[_0x1e5490(0x1ad)],'rangeId':_0x5c92ab[_0x1e5490(0x251)],'presentation':_0x33ff8b,'previousPresentation':_0x5437ee,'result':B(_0x5c92ab),'previousResult':{..._0x201675,..._0x5437ee,'value':(_0xed896=_0x5437ee[_0x1e5490(0x21c)])==null?void 0x0:_0xed896['v'],'valueType':((_0x1fbe14=_0x5437ee[_0x1e5490(0x21c)])==null?void 0x0:_0x1fbe14['t'])??void 0x0}});}[_0x18accd(0x21a)](_0x4d96be){const _0x5dd8f0=_0x18accd;_0x4d96be[_0x5dd8f0(0x1f7)]&&(this[_0x5dd8f0(0x1bc)][_0x5dd8f0(0x201)](_0x4d96be['unitId'],_0x4d96be[_0x5dd8f0(0x1ad)],[_0x4d96be['formulaId']]),this[_0x5dd8f0(0x1ff)]['delete'](_0x4d96be['formulaId']));}};L=I([F(0x0,_0x2bb8ca(P)),F(0x1,_0x2bb8ca(_0x1a621d)),F(0x2,_0x2bb8ca(_0x39d327))],L);function R(_0x26b788,_0x3d919e){return _0x26b788+'\x00'+_0x3d919e;}function z(_0x44d3ca,_0x27e098){const _0x30fbf8=_0x18accd;return _0x3cd2e8({'numberFormat':_0x44d3ca[_0x30fbf8(0x255)],'lastValue':_0x44d3ca['lastValue'],'result':_0x27e098});}function B(_0x46e0bf){const _0x3d2927=_0x18accd;var _0x45339c,_0x2cf29c,_0xf4550;let _0x21751a=_0x46e0bf['presentation'],_0x54a4e8=_0x46e0bf[_0x3d2927(0x1ba)][_0x3d2927(0x193)][_0x3d2927(0x272)]()?_0x21751a['stale']||_0x21751a['cell']==null?_0x3d2927(0x1e9):((_0x45339c=_0x46e0bf[_0x3d2927(0x247)])==null?void 0x0:_0x45339c[_0x3d2927(0x18e)])===_0x1f2db9['ERROR']?_0x3d2927(0x1be):_0x3d2927(0x1a5):_0x3d2927(0x235);return{..._0x21751a,'status':_0x54a4e8,'value':(_0x2cf29c=_0x21751a['cell'])==null?void 0x0:_0x2cf29c['v'],'valueType':((_0xf4550=_0x21751a[_0x3d2927(0x21c)])==null?void 0x0:_0xf4550['t'])??void 0x0};}function at(_0x41f5c1,_0x21cfe5){const _0x3dbf03=_0x18accd;var _0x33bef3,_0x285c12,_0x2194cd,_0x500a52;return _0x41f5c1[_0x3dbf03(0x242)]===_0x21cfe5[_0x3dbf03(0x242)]&&_0x41f5c1[_0x3dbf03(0x244)]===_0x21cfe5['color']&&_0x41f5c1['pattern']===_0x21cfe5[_0x3dbf03(0x1f9)]&&_0x41f5c1[_0x3dbf03(0x1e6)]===_0x21cfe5[_0x3dbf03(0x1e6)]&&_0x41f5c1['stale']===_0x21cfe5[_0x3dbf03(0x1cb)]&&((_0x33bef3=_0x41f5c1['cell'])==null?void 0x0:_0x33bef3['t'])===((_0x285c12=_0x21cfe5[_0x3dbf03(0x21c)])==null?void 0x0:_0x285c12['t'])&&Object['is']((_0x2194cd=_0x41f5c1[_0x3dbf03(0x21c)])==null?void 0x0:_0x2194cd['v'],(_0x500a52=_0x21cfe5['cell'])==null?void 0x0:_0x500a52['v']);}const ot={'id':_0x18accd(0x22d),'type':_0x2c4aaa[_0x18accd(0x190)],'handler':(_0x5aca49,_0x56ea38)=>!(_0x56ea38!=null&&_0x56ea38[_0x18accd(0x1ad)])||!_0x56ea38[_0x18accd(0x251)]||!_0x56ea38['config']?!0x1:_0x5aca49['get'](P)[_0x18accd(0x21d)](_0x56ea38[_0x18accd(0x1ad)],_0x56ea38['rangeId'],_0x56ea38[_0x18accd(0x1ba)])},st={'id':'docs-formula.mutation.remove-formula','type':_0x2c4aaa['MUTATION'],'handler':(_0x431e20,_0x3645e9)=>!(_0x3645e9!=null&&_0x3645e9[_0x18accd(0x1ad)])||!_0x3645e9[_0x18accd(0x251)]?!0x1:_0x431e20[_0x18accd(0x1ab)](P)[_0x18accd(0x183)](_0x3645e9[_0x18accd(0x1ad)],_0x3645e9[_0x18accd(0x251)])},V={'id':'docs-formula.mutation.set-resource','type':_0x2c4aaa[_0x18accd(0x190)],'handler':(_0x141e5c,_0x513c53)=>!(_0x513c53!=null&&_0x513c53[_0x18accd(0x1ad)])||!_0x513c53[_0x18accd(0x192)]?!0x1:_0x141e5c[_0x18accd(0x1ab)](P)[_0x18accd(0x248)](_0x513c53[_0x18accd(0x1ad)],_0x513c53[_0x18accd(0x192)])},H={'id':'docs-formula.mutation.set-last-values','type':_0x2c4aaa[_0x18accd(0x190)],'handler':(_0x35ad68,_0x29f30e)=>{const _0x51a4ec=_0x18accd;if(!(_0x29f30e!=null&&_0x29f30e[_0x51a4ec(0x1ad)])||!_0x29f30e[_0x51a4ec(0x264)][_0x51a4ec(0x230)])return!0x1;let _0x497aaf=_0x35ad68['get'](P),_0x1fc407=_0x35ad68[_0x51a4ec(0x1ab)](_0x39d327),_0xa78566=_0x497aaf[_0x51a4ec(0x26a)](_0x29f30e[_0x51a4ec(0x1ad)]);if(!_0xa78566)return!0x1;let _0x2489ca=_0x240c37[_0x51a4ec(0x1a4)](_0xa78566),_0xfa7dec=!0x1;for(let _0x23c22a of _0x29f30e[_0x51a4ec(0x264)]){var _0x4ea899,_0x8c4193,_0x578921,_0x5acd89;let _0x8e4cf1=_0x2489ca[_0x51a4ec(0x1b9)][_0x23c22a[_0x51a4ec(0x251)]];_0x8e4cf1&&_0x8e4cf1[_0x51a4ec(0x193)]===_0x23c22a[_0x51a4ec(0x185)]&&((_0x4ea899=_0x8e4cf1['numberFormat'])==null?void 0x0:_0x4ea899[_0x51a4ec(0x1f9)])===_0x23c22a[_0x51a4ec(0x220)]&&_0x1fc407['getRevision'](_0x29f30e['unitId'])===_0x23c22a['expectedReferenceRevision']&&(((_0x8c4193=_0x8e4cf1[_0x51a4ec(0x191)])==null?void 0x0:_0x8c4193['v'])!==_0x23c22a[_0x51a4ec(0x191)]['v']||((_0x578921=_0x8e4cf1['lastValue'])==null?void 0x0:_0x578921['t'])!==_0x23c22a[_0x51a4ec(0x191)]['t']||((_0x5acd89=_0x8e4cf1[_0x51a4ec(0x191)])==null?void 0x0:_0x5acd89[_0x51a4ec(0x1f9)])!==_0x23c22a[_0x51a4ec(0x191)][_0x51a4ec(0x1f9)])&&(_0x8e4cf1[_0x51a4ec(0x191)]=_0x240c37[_0x51a4ec(0x1a4)](_0x23c22a['lastValue']),_0xfa7dec=!0x0);}return!_0xfa7dec||_0x497aaf['setResource'](_0x29f30e[_0x51a4ec(0x1ad)],_0x2489ca);}},U={'id':_0x18accd(0x23c),'type':_0x2c4aaa[_0x18accd(0x1f0)],'handler':(_0x2909e0,_0xb97ce7)=>{const _0x72a918=_0x18accd;if(!(_0xb97ce7!=null&&_0xb97ce7[_0x72a918(0x193)]['trim']()))return!0x1;let _0x32ec77=q(_0x2909e0,_0xb97ce7[_0x72a918(0x1ad)],'');if(!_0x32ec77)return!0x1;let _0x47b7cd=ft(_0xb97ce7[_0x72a918(0x1c1)],_0x32ec77[_0x72a918(0x212)],dt(_0x2909e0,_0x32ec77[_0x72a918(0x1ad)]));if(!_0x47b7cd)return!0x1;let _0x2defab=pt(_0x2909e0,_0x32ec77[_0x72a918(0x1ad)],_0xb97ce7[_0x72a918(0x193)],_0xb97ce7[_0x72a918(0x24e)]??[]);if(!_0x2defab)return!0x1;let _0x2a883f=mt(_0x32ec77[_0x72a918(0x212)],_0x32ec77['model'],_0x32ec77[_0x72a918(0x1ad)]),_0x4e4fc8=ht({'documentData':_0x32ec77['documentData'],'resource':_0x32ec77[_0x72a918(0x192)],'rangeId':_0x2a883f,'config':{'formula':_0xb97ce7[_0x72a918(0x193)],..._0xb97ce7[_0x72a918(0x255)]?{'numberFormat':_0xb97ce7['numberFormat']}:null},'startOffset':_0x47b7cd[_0x72a918(0x23d)],'endOffset':_0x47b7cd['endOffset']});if(!_0x4e4fc8)return!0x1;let _0x74ee53=_0x52d94b(_0x2909e0,_0x32ec77[_0x72a918(0x1ad)],_0x2defab);return!_0x74ee53||!J({'accessor':_0x2909e0,'document':_0x32ec77[_0x72a918(0x254)],'unitId':_0x32ec77[_0x72a918(0x1ad)],'trigger':U['id'],'rangeId':_0x2a883f,'previousResource':_0x32ec77['resource'],'nextResource':_0x4e4fc8[_0x72a918(0x23a)],'previousDocumentData':_0x32ec77['documentData'],'nextDocumentData':_0x4e4fc8[_0x72a918(0x178)],'cursorOffset':_0x4e4fc8[_0x72a918(0x24a)],'externalMutations':_0x74ee53})?!0x1:{'rangeId':_0x2a883f,'startOffset':_0x4e4fc8[_0x72a918(0x24a)]-0x1,'endOffset':_0x4e4fc8[_0x72a918(0x24a)]};}},W={'id':_0x18accd(0x177),'type':_0x2c4aaa[_0x18accd(0x1f0)],'handler':(_0x1d8218,_0x381f30)=>{const _0x29e015=_0x18accd;if(!(_0x381f30!=null&&_0x381f30[_0x29e015(0x251)])||!_0x381f30[_0x29e015(0x193)]['trim']())return!0x1;let _0x1cdc7e=q(_0x1d8218,_0x381f30[_0x29e015(0x1ad)],''),_0x4e2360=_0x1cdc7e==null?void 0x0:_0x1cdc7e['model'][_0x29e015(0x25a)](_0x1cdc7e[_0x29e015(0x1ad)],_0x381f30['rangeId']),_0x3304ff=_0x1cdc7e?T(_0x1cdc7e[_0x29e015(0x17e)][_0x29e015(0x212)],_0x381f30['rangeId']):void 0x0;if(!_0x1cdc7e||!_0x4e2360||!_0x3304ff)return!0x1;let _0x4289e0=pt(_0x1d8218,_0x1cdc7e[_0x29e015(0x1ad)],_0x381f30['formula'],_0x381f30[_0x29e015(0x24e)]??[]);if(!_0x4289e0)return!0x1;let _0x5ef1cc=_0x52d94b(_0x1d8218,_0x1cdc7e[_0x29e015(0x1ad)],_0x4289e0);if(!_0x5ef1cc)return!0x1;let _0xa88029=Ct(_0x1cdc7e[_0x29e015(0x192)]);return _0xa88029[_0x29e015(0x1b9)][_0x381f30[_0x29e015(0x251)]]={'formula':_0x381f30[_0x29e015(0x193)],..._0x381f30[_0x29e015(0x255)]?{'numberFormat':_0x381f30[_0x29e015(0x255)]}:_0x4e2360[_0x29e015(0x255)]?{'numberFormat':_0x4e2360['numberFormat']}:null},J({'accessor':_0x1d8218,'document':_0x1cdc7e[_0x29e015(0x254)],'unitId':_0x1cdc7e[_0x29e015(0x1ad)],'trigger':W['id'],'rangeId':_0x381f30[_0x29e015(0x251)],'previousResource':_0x1cdc7e[_0x29e015(0x192)],'nextResource':_0xa88029,'cursorOffset':_0x3304ff[_0x29e015(0x19f)]+0x1,'externalMutations':_0x5ef1cc});}},G={'id':_0x18accd(0x25d),'type':_0x2c4aaa[_0x18accd(0x1f0)],'handler':(_0x2ccdad,_0x5cd2bb)=>{const _0x9d8e02=_0x18accd;if(!(_0x5cd2bb!=null&&_0x5cd2bb[_0x9d8e02(0x251)]))return!0x1;let _0x22f0ab=q(_0x2ccdad,_0x5cd2bb['unitId'],''),_0x7c950c=_0x22f0ab==null?void 0x0:_0x22f0ab[_0x9d8e02(0x1fe)][_0x9d8e02(0x25a)](_0x22f0ab[_0x9d8e02(0x1ad)],_0x5cd2bb[_0x9d8e02(0x251)]),_0x7ccf90=_0x22f0ab?T(_0x22f0ab[_0x9d8e02(0x17e)][_0x9d8e02(0x212)],_0x5cd2bb[_0x9d8e02(0x251)]):void 0x0;if(!_0x22f0ab||!_0x7c950c||!_0x7ccf90)return!0x1;let _0x26105a=Ct(_0x22f0ab[_0x9d8e02(0x192)]);return _0x26105a[_0x9d8e02(0x1b9)][_0x5cd2bb[_0x9d8e02(0x251)]]={..._0x7c950c,..._0x5cd2bb[_0x9d8e02(0x255)]?{'numberFormat':_0x5cd2bb[_0x9d8e02(0x255)]}:null},_0x5cd2bb[_0x9d8e02(0x255)]||delete _0x26105a['formulas'][_0x5cd2bb[_0x9d8e02(0x251)]][_0x9d8e02(0x255)],J({'accessor':_0x2ccdad,'document':_0x22f0ab[_0x9d8e02(0x254)],'unitId':_0x22f0ab[_0x9d8e02(0x1ad)],'trigger':G['id'],'rangeId':_0x5cd2bb[_0x9d8e02(0x251)],'previousResource':_0x22f0ab[_0x9d8e02(0x192)],'nextResource':_0x26105a,'cursorOffset':_0x7ccf90[_0x9d8e02(0x19f)]+0x1,'externalMutations':{}});}},K={'id':_0x18accd(0x20c),'type':_0x2c4aaa[_0x18accd(0x1f0)],'handler':(_0x493641,_0x36054a)=>ut(_0x493641,_0x36054a,'',K['id'])},ct={'id':_0x18accd(0x21b),'type':_0x2c4aaa[_0x18accd(0x1f0)],'handler':(_0xddedeb,_0x594bd1)=>ut(_0xddedeb,_0x594bd1,(_0x594bd1==null?void 0x0:_0x594bd1['text'])??'',ct['id'])},lt={'id':'docs-formula.command.convert-to-text','type':_0x2c4aaa['COMMAND'],'handler':(_0x343533,_0xd97716)=>{const _0x670c65=_0x18accd;if(!(_0xd97716!=null&&_0xd97716[_0x670c65(0x251)]))return!0x1;let _0x4d7fdc=q(_0x343533,_0xd97716[_0x670c65(0x1ad)],'');if(!_0x4d7fdc)return!0x1;let _0x52030b=_0x343533[_0x670c65(0x1ab)](L)[_0x670c65(0x241)]({'unitId':_0x4d7fdc[_0x670c65(0x1ad)],'rangeId':_0xd97716['rangeId']});return _0x52030b?ut(_0x343533,_0xd97716,_0x52030b['text'],lt['id']):!0x1;}};function ut(_0x52bd0b,_0x59d1ce,_0xf49d80,_0x1f3930){const _0xb5f590=_0x18accd;if(!(_0x59d1ce!=null&&_0x59d1ce['rangeId']))return!0x1;let _0x3ec354=q(_0x52bd0b,_0x59d1ce[_0xb5f590(0x1ad)],'');if(!_0x3ec354)return!0x1;let _0x43fbee=Be({'documentData':_0x3ec354['documentData'],'resource':_0x3ec354[_0xb5f590(0x192)],'rangeId':_0x59d1ce[_0xb5f590(0x251)],'text':_0xf49d80});return _0x43fbee?J({'accessor':_0x52bd0b,'document':_0x3ec354[_0xb5f590(0x254)],'unitId':_0x3ec354[_0xb5f590(0x1ad)],'trigger':_0x1f3930,'rangeId':_0x59d1ce[_0xb5f590(0x251)],'previousResource':_0x3ec354[_0xb5f590(0x192)],'nextResource':_0x43fbee[_0xb5f590(0x23a)],'previousDocumentData':_0x3ec354[_0xb5f590(0x17e)],'nextDocumentData':_0x43fbee[_0xb5f590(0x178)],'cursorOffset':_0x43fbee[_0xb5f590(0x24a)],'externalMutations':{}}):!0x1;}function q(_0x214c8c,_0x57d408,_0x42eb13){const _0x5b6bd0=_0x18accd;if(_0x42eb13)return null;let _0x3c054a=_0x214c8c[_0x5b6bd0(0x1ab)](_0x478f5d),_0x4e69b=(_0x57d408?_0x3c054a['getUnit'](_0x57d408,_0x50d692[_0x5b6bd0(0x24d)]):_0x3c054a[_0x5b6bd0(0x195)](_0x50d692['UNIVER_DOC']))??null;if(!_0x4e69b)return null;let _0x2350a7=_0x4e69b[_0x5b6bd0(0x1b1)](),_0xa7be59=_0x2350a7[_0x5b6bd0(0x212)];if(_0x2350a7['disabled']||!_0xa7be59)return null;let _0x24e8e1=_0x214c8c['get'](P);return _0x24e8e1[_0x5b6bd0(0x261)](_0x4e69b[_0x5b6bd0(0x266)]())?null:{'document':_0x4e69b,'body':_0xa7be59,'documentData':_0x2350a7,'model':_0x24e8e1,'resource':_0x24e8e1[_0x5b6bd0(0x26a)](_0x4e69b[_0x5b6bd0(0x266)]())??b(),'unitId':_0x4e69b[_0x5b6bd0(0x266)]()};}function dt(_0x3333b1,_0x24070c){const _0x36986a=_0x18accd;var _0x50d3e7;return(_0x50d3e7=_0x3333b1[_0x36986a(0x1ab)](_0x32a2c9)[_0x36986a(0x18f)]({'subUnitId':_0x24070c,'unitId':_0x24070c}))==null?void 0x0:_0x50d3e7[0x0];}function ft(_0x3c11fe,_0x5c8a4b,_0x5280f7){const _0x15085e=_0x18accd;if((_0x3c11fe==null?void 0x0:_0x3c11fe['type'])===_0x15085e(0x1f8)){var _0x3547a2;let _0x3eb268=((_0x3547a2=_0x5c8a4b[_0x15085e(0x18d)])==null?void 0x0:_0x3547a2[_0x15085e(0x252)](_0x1ff9ed=>_0x1ff9ed['paragraphId']===_0x3c11fe['paragraphId']))??[];if(_0x3eb268[_0x15085e(0x230)]!==0x1)return null;let _0x426adc=_0x3eb268[0x0],_0x2729b4=_0x1c8c1a(_0x5c8a4b,_0x426adc),_0x46bf4b=_0x426adc['startIndex']-_0x2729b4,_0x787cbb=_0x3c11fe[_0x15085e(0x1e2)]==='end'?_0x46bf4b:_0x3c11fe['position'];if(!Number[_0x15085e(0x239)](_0x787cbb)||_0x787cbb<0x0||_0x787cbb>_0x46bf4b)return null;let _0x2f19c0=_0x2729b4+_0x787cbb;return{'startOffset':_0x2f19c0,'endOffset':_0x2f19c0};}if((_0x3c11fe==null?void 0x0:_0x3c11fe[_0x15085e(0x250)])===_0x15085e(0x207))return!Number[_0x15085e(0x239)](_0x3c11fe[_0x15085e(0x23d)])||!Number[_0x15085e(0x239)](_0x3c11fe[_0x15085e(0x200)])?null:{'startOffset':Math[_0x15085e(0x1da)](_0x3c11fe[_0x15085e(0x23d)],_0x3c11fe[_0x15085e(0x200)]),'endOffset':Math['max'](_0x3c11fe[_0x15085e(0x23d)],_0x3c11fe[_0x15085e(0x200)])};let _0x485507=(_0x3c11fe==null?void 0x0:_0x3c11fe[_0x15085e(0x250)])===_0x15085e(0x236)?_0x3c11fe[_0x15085e(0x236)]:_0x5280f7;return!_0x485507||_0x485507['segmentId']?null:{'startOffset':Math['min'](_0x485507[_0x15085e(0x23d)],_0x485507['endOffset']),'endOffset':Math['max'](_0x485507[_0x15085e(0x23d)],_0x485507['endOffset'])};}function pt(_0x404c43,_0x18b445,_0x2d2a8f,_0x1183a6){const _0x5852b3=_0x18accd;let _0x5af88c=_0x404c43['get'](_0x4914fd),_0x31e731=_0x2d2a8f[_0x5852b3(0x1fa)]('=')?_0x2d2a8f[_0x5852b3(0x22a)](0x1):_0x2d2a8f,_0x3a2960=_0x5af88c[_0x5852b3(0x234)](_0x31e731);if(!_0x3a2960)return null;let _0x23b2dd=_0x404c43[_0x5852b3(0x1ab)](_0x39d327),_0x55c62c=_0x4ac795({'qualifiers':_0x32274e(_0x3a2960),'explicitReferences':_0x1183a6??[],'resolveBinding':_0x5e1018=>_0x23b2dd[_0x5852b3(0x1c6)](_0x18b445,_0x5e1018)});return _0x55c62c[_0x5852b3(0x18e)]===_0x5852b3(0x1b0)?_0x55c62c[_0x5852b3(0x19e)]:null;}function mt(_0x2dce01,_0x3d0ec2,_0x228151){const _0x5c3253=_0x18accd;var _0x1418fb;let _0x1b07af=_0x13e167(0x6);for(;_0x2dce01!=null&&(_0x1418fb=_0x2dce01[_0x5c3253(0x1a6)])!=null&&_0x1418fb[_0x5c3253(0x225)](_0x459f89=>_0x459f89[_0x5c3253(0x251)]===_0x1b07af)||_0x3d0ec2[_0x5c3253(0x25a)](_0x228151,_0x1b07af);)_0x1b07af=_0x13e167(0x6);return _0x1b07af;}function ht(_0x1236a2){try{return Re(_0x1236a2);}catch(_0x33830a){if(_0x33830a instanceof C)return null;throw _0x33830a;}}function gt(_0x1315c2){const _0x487ee4=_0x18accd;let _0x52265e=_0x1315c2[_0x487ee4(0x1ee)]&&_0x1315c2['nextDocumentData']?vt(_0x1315c2['document'],_0x1315c2[_0x487ee4(0x1ad)],_0x1315c2['previousDocumentData'],_0x1315c2[_0x487ee4(0x178)],_0x1315c2[_0x487ee4(0x24a)],_0x1315c2[_0x487ee4(0x202)]):null;return _0x1315c2[_0x487ee4(0x1ee)]&&_0x1315c2[_0x487ee4(0x178)]&&!_0x52265e?null:{'documentRedo':_0x52265e,'resourceRedo':{'id':V['id'],'params':{'unitId':_0x1315c2[_0x487ee4(0x1ad)],'resource':_0x1315c2['nextResource']}},'resourceUndo':{'id':V['id'],'params':{'unitId':_0x1315c2['unitId'],'resource':_0x1315c2['previousResource']}}};}function _t(_0x13d32d,_0x2af97d,_0x380244,_0x32dad1){const _0x580c41=_0x18accd;_0x32dad1[_0x580c41(0x205)]({'id':_0x13d32d[_0x580c41(0x202)]+':'+_0x13d32d[_0x580c41(0x251)],'unitID':_0x13d32d[_0x580c41(0x1ad)],'redoMutations':[..._0x13d32d[_0x580c41(0x246)][_0x580c41(0x21f)]?[_0x13d32d[_0x580c41(0x246)][_0x580c41(0x21f)]]:[],..._0x2af97d[_0x580c41(0x217)]?[_0x2af97d[_0x580c41(0x217)]]:[],_0x2af97d[_0x580c41(0x229)]],'undoMutations':[_0x2af97d[_0x580c41(0x23b)],..._0x380244?[_0x380244]:[],..._0x13d32d[_0x580c41(0x246)]['undoMutation']?[_0x13d32d['externalMutations'][_0x580c41(0x1f1)]]:[]]});}function J(_0x3fd200){const _0x3c3671=_0x18accd;let _0x4d36ba=_0x3fd200[_0x3c3671(0x196)][_0x3c3671(0x1ab)](_0x222411),_0xb9a5f=_0x3fd200[_0x3c3671(0x196)][_0x3c3671(0x1ab)](_0x513fde),_0x37a637=_0x3fd200[_0x3c3671(0x196)]['get'](_0x32a2c9),_0x4a67a2=gt(_0x3fd200);if(!_0x4a67a2)return!0x1;let _0x275205=!0x1,_0x398a5d=null,_0x3b5a56=!0x1;try{if(_0x3fd200[_0x3c3671(0x246)][_0x3c3671(0x21f)]){if(!_0x4d36ba[_0x3c3671(0x1b8)](_0x3fd200[_0x3c3671(0x246)][_0x3c3671(0x21f)]['id'],_0x3fd200[_0x3c3671(0x246)][_0x3c3671(0x21f)][_0x3c3671(0x1df)]))return!0x1;_0x275205=!0x0;}if(_0x4a67a2[_0x3c3671(0x217)]){let _0x5559de=_0x4d36ba[_0x3c3671(0x1b8)](_0x4a67a2[_0x3c3671(0x217)]['id'],_0x4a67a2[_0x3c3671(0x217)][_0x3c3671(0x1df)]);if(!_0x5559de)return bt(_0x4d36ba,_0x3fd200[_0x3c3671(0x246)],_0x275205),!0x1;_0x398a5d={'id':_0x2fe09d['id'],'params':{..._0x5559de,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'segmentId':''}};}if(!_0x4d36ba['syncExecuteCommand'](_0x4a67a2[_0x3c3671(0x229)]['id'],_0x4a67a2['resourceRedo']['params']))return yt(_0x4d36ba,_0x398a5d),bt(_0x4d36ba,_0x3fd200[_0x3c3671(0x246)],_0x275205),!0x1;_0x3b5a56=!0x0,_t(_0x3fd200,_0x4a67a2,_0x398a5d,_0xb9a5f);}catch(_0xa7bd89){throw _0x3b5a56&&_0x4d36ba[_0x3c3671(0x1b8)](_0x4a67a2[_0x3c3671(0x23b)]['id'],_0x4a67a2['resourceUndo']['params']),yt(_0x4d36ba,_0x398a5d),bt(_0x4d36ba,_0x3fd200[_0x3c3671(0x246)],_0x275205),_0xa7bd89;}return _0x37a637[_0x3c3671(0x22b)]([{'startOffset':_0x3fd200[_0x3c3671(0x24a)],'endOffset':_0x3fd200[_0x3c3671(0x24a)],'segmentId':''}],{'unitId':_0x3fd200['unitId'],'subUnitId':_0x3fd200['unitId']},!0x1,{[_0x3ef325]:!0x0}),!0x0;}function vt(_0x54d06e,_0x18e626,_0x2b7e8e,_0x6d3d69,_0x54ac33,_0x2deb31){let _0x2d0068=xt(_0x2b7e8e,_0x6d3d69,_0x27773c(_0x54d06e,''));return _0x2d0068?{'id':_0x2fe09d['id'],'params':{'unitId':_0x18e626,'actions':_0x2d0068,'segmentId':'','textRanges':[{'startOffset':_0x54ac33,'endOffset':_0x54ac33,'collapsed':!0x0,'segmentId':''}],'isEditing':!0x1,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'trigger':_0x2deb31}}:null;}function yt(_0x3a9c10,_0x127405){const _0x4c2d68=_0x18accd;_0x127405&&_0x3a9c10['syncExecuteCommand'](_0x127405['id'],_0x127405[_0x4c2d68(0x1df)]);}function bt(_0x3db208,_0x33a259,_0x17a015){const _0x1b150e=_0x18accd;_0x17a015&&_0x33a259['undoMutation']&&_0x3db208[_0x1b150e(0x1b8)](_0x33a259[_0x1b150e(0x1f1)]['id'],_0x33a259['undoMutation']['params']);}function xt(_0x4943fd,_0x56c0b0,_0x4115ba){const _0x4a7ab1=_0x18accd;let _0x27060e=_0x4943fd[_0x4a7ab1(0x212)],_0x44f47d=_0x56c0b0['body'],_0xf97d2a=St(_0x27060e==null?void 0x0:_0x27060e[_0x4a7ab1(0x1d2)],_0x44f47d==null?void 0x0:_0x44f47d['dataStream']);if(!_0xf97d2a||!_0x44f47d)return null;let _0x183e46=new _0x4c112a();return _0x183e46[_0x4a7ab1(0x199)](_0xf97d2a['start']),_0xf97d2a[_0x4a7ab1(0x210)]>0x0&&_0x183e46[_0x4a7ab1(0x1ed)](_0xf97d2a[_0x4a7ab1(0x210)],_0x4d9adf(_0x44f47d,_0xf97d2a['start'],_0xf97d2a[_0x4a7ab1(0x1aa)]+_0xf97d2a['insertLength'],!0x1)),_0xf97d2a[_0x4a7ab1(0x180)]>0x0&&_0x183e46['delete'](_0xf97d2a[_0x4a7ab1(0x180)]),_0x25fe93[_0x4a7ab1(0x1f4)]()[_0x4a7ab1(0x187)](_0x183e46[_0x4a7ab1(0x237)](),_0x4115ba);}function St(_0x24849d,_0x238537){const _0x3c75e2=_0x18accd;if(_0x24849d==null||_0x238537==null||_0x24849d===_0x238537)return null;let _0x3103fd=0x0;for(;_0x3103fd<_0x24849d[_0x3c75e2(0x230)]&&_0x3103fd<_0x238537[_0x3c75e2(0x230)]&&_0x24849d[_0x3103fd]===_0x238537[_0x3103fd];)_0x3103fd+=0x1;let _0x5ee6dc=_0x24849d[_0x3c75e2(0x230)],_0x11ab9f=_0x238537[_0x3c75e2(0x230)];for(;_0x5ee6dc>_0x3103fd&&_0x11ab9f>_0x3103fd&&_0x24849d[_0x5ee6dc-0x1]===_0x238537[_0x11ab9f-0x1];)--_0x5ee6dc,--_0x11ab9f;return{'start':_0x3103fd,'deleteLength':_0x5ee6dc-_0x3103fd,'insertLength':_0x11ab9f-_0x3103fd};}function Ct(_0x165f53){const _0x432bdc=_0x18accd;return{'schemaVersion':0x1,'formulas':Object['fromEntries'](Object[_0x432bdc(0x1c5)](_0x165f53[_0x432bdc(0x1b9)])[_0x432bdc(0x1f3)](([_0x28f86d,_0x44656e])=>[_0x28f86d,{..._0x44656e,..._0x44656e[_0x432bdc(0x255)]?{'numberFormat':{..._0x44656e[_0x432bdc(0x255)]}}:null,..._0x44656e[_0x432bdc(0x191)]?{'lastValue':{..._0x44656e[_0x432bdc(0x191)]}}:null}]))};}let Y=class extends _0x474e08{constructor(_0xee1db6,_0x286c47,_0x77250e,_0xab6b21){const _0x51ed8a=_0x18accd;super(),this[_0x51ed8a(0x1b4)]=_0xee1db6,this['_commandService']=_0x286c47,this['_model']=_0x77250e,this[_0x51ed8a(0x181)]=_0xab6b21,N(this,_0x51ed8a(0x1a7),new Set()),N(this,_0x51ed8a(0x1eb),!0x1),N(this,_0x51ed8a(0x1a3),!0x1),this[_0x51ed8a(0x1b4)][_0x51ed8a(0x1f6)](_0x50d692[_0x51ed8a(0x24d)])[_0x51ed8a(0x19c)](_0x5dc60e=>this[_0x51ed8a(0x181)][_0x51ed8a(0x1b2)](_0x5dc60e)),this[_0x51ed8a(0x223)](this[_0x51ed8a(0x17f)][_0x51ed8a(0x25c)][_0x51ed8a(0x1d3)](({unitId:_0x16d7db})=>this[_0x51ed8a(0x23f)](_0x16d7db))),this[_0x51ed8a(0x223)](this[_0x51ed8a(0x1b4)]['unitAdded$'][_0x51ed8a(0x1d3)](({unit:_0x1aea35})=>{const _0x2b7d1b=_0x51ed8a;_0x1aea35[_0x2b7d1b(0x250)]===_0x50d692[_0x2b7d1b(0x24d)]&&this['_queueSync'](_0x1aea35[_0x2b7d1b(0x266)]());})),this[_0x51ed8a(0x223)](this[_0x51ed8a(0x1b4)][_0x51ed8a(0x1ae)][_0x51ed8a(0x1d3)](_0x119909=>{const _0x3bc23c=_0x51ed8a;this['_service'][_0x3bc23c(0x1a2)](_0x119909[_0x3bc23c(0x266)]());})),this[_0x51ed8a(0x223)](this['_commandService'][_0x51ed8a(0x1c3)](_0x50fb88=>{const _0x37f38b=_0x51ed8a;if(_0x50fb88['id']===_0x2fe09d['id']&&wt(_0x50fb88[_0x37f38b(0x1df)])){let _0x123cb6=_0x50fb88[_0x37f38b(0x1df)];_0x123cb6[_0x37f38b(0x1a1)]||this[_0x37f38b(0x23f)](_0x123cb6[_0x37f38b(0x1ad)]);}}));}[_0x18accd(0x186)](){const _0x2bdedc=_0x18accd;this[_0x2bdedc(0x1a3)]=!0x0,super[_0x2bdedc(0x186)]();}[_0x18accd(0x238)](_0x1fbbf7){const _0x378d84=_0x18accd;this['_pendingUnitIds'][_0x378d84(0x1af)](_0x1fbbf7),!this[_0x378d84(0x1eb)]&&(this[_0x378d84(0x1eb)]=!0x0,queueMicrotask(()=>{const _0x2bb039=_0x378d84;if(this[_0x2bb039(0x1eb)]=!0x1,this[_0x2bb039(0x1a3)])return;let _0x4c5875=Array[_0x2bb039(0x1ec)](this[_0x2bb039(0x1a7)]);this[_0x2bb039(0x1a7)][_0x2bb039(0x267)](),_0x4c5875['forEach'](_0x2e8ce7=>this['_syncUnit'](_0x2e8ce7));}));}['_syncUnit'](_0x535414){const _0x598413=_0x18accd;let _0x31e807=this[_0x598413(0x1b4)][_0x598413(0x257)](_0x535414,_0x50d692[_0x598413(0x24d)]);_0x31e807&&this[_0x598413(0x181)]['syncUnit'](_0x31e807);}};Y=I([F(0x0,_0x478f5d),F(0x1,_0x222411),F(0x2,_0x2bb8ca(P)),F(0x3,_0x2bb8ca(L))],Y);function wt(_0x1fcf8e){const _0x554f22=_0x18accd;return typeof _0x1fcf8e==_0x554f22(0x224)&&!!_0x1fcf8e&&'unitId'in _0x1fcf8e&&typeof _0x1fcf8e[_0x554f22(0x1ad)]=='string'&&(!(_0x554f22(0x1a1)in _0x1fcf8e)||_0x1fcf8e[_0x554f22(0x1a1)]===void 0x0||typeof _0x1fcf8e['segmentId']==_0x554f22(0x218));}function _0x7514(_0x5bfad8,_0x5b277d){_0x5bfad8=_0x5bfad8-0x173;const _0x539718=_0x5397();let _0x7514b0=_0x539718[_0x5bfad8];return _0x7514b0;}let X=class extends _0x474e08{constructor(_0x443fc3,_0x410605){const _0x380cd6=_0x18accd;super(),this['_resourceManagerService']=_0x443fc3,this['_docFormulaModel']=_0x410605,this[_0x380cd6(0x223)](this['_resourceManagerService'][_0x380cd6(0x215)]({'pluginName':y,'businesses':[_0x50d692[_0x380cd6(0x24d)]],'toJson':_0x1c7113=>JSON[_0x380cd6(0x184)](this['_docFormulaModel']['serialize'](_0x1c7113)),'parseJson':_0x2435b9=>JSON[_0x380cd6(0x208)](_0x2435b9),'onLoad':(_0x1905dc,_0x501a4a)=>{const _0x517ebd=_0x380cd6;this[_0x517ebd(0x1e0)][_0x517ebd(0x19a)](_0x1905dc,_0x501a4a);},'onUnLoad':_0x4cc5a3=>this[_0x380cd6(0x1e0)][_0x380cd6(0x1bb)](_0x4cc5a3)}));}};X=I([F(0x0,_0x3b184b),F(0x1,_0x2bb8ca(P))],X);var Tt='@univerjs-pro/docs-formula',Et='1.1.0';const Dt={};let Z=class extends _0x474e08{constructor(_0x47ab21,_0x5a4bb3,_0x5efd96){const _0x302647=_0x18accd;super(),this[_0x302647(0x228)]=_0x47ab21,this[_0x302647(0x1ce)]=_0x5a4bb3,this[_0x302647(0x223)](_0x5efd96[_0x302647(0x1a8)]({'resolve':(_0x3f64a7,_0x5291fc)=>{const _0x569bd0=_0x302647;var _0xb3871d;return((_0xb3871d=_0x5291fc[_0x569bd0(0x1a6)])==null?void 0x0:_0xb3871d[_0x569bd0(0x252)](w)[_0x569bd0(0x1f3)](_0x3bbf2a=>({'startOffset':_0x3bbf2a['startIndex'],'endOffset':_0x3bbf2a[_0x569bd0(0x19f)]+0x1,'text':this[_0x569bd0(0x271)](_0x3f64a7,_0x3bbf2a[_0x569bd0(0x251)])})))??[];}})),this[_0x302647(0x223)](this[_0x302647(0x1ce)][_0x302647(0x1c2)]['subscribe'](({unitId:_0x40d711})=>{_0x5efd96['notifyTextChanged'](_0x40d711);}));}[_0x18accd(0x271)](_0x1764c3,_0x4d4bec){const _0x4fb140=_0x18accd;var _0x13ef5a;return((_0x13ef5a=this[_0x4fb140(0x1ce)]['getResult']({'unitId':_0x1764c3,'rangeId':_0x4d4bec}))==null?void 0x0:_0x13ef5a['text'])??'';}[_0x18accd(0x259)](_0x3effef,_0x8a8a6f,_0xd752ed){const _0x1385aa=_0x18accd;var _0xd0c458;let _0x1a1adb=this[_0x1385aa(0x228)][_0x1385aa(0x257)](_0x3effef,_0x50d692[_0x1385aa(0x24d)]),_0x20d992=_0x1a1adb==null?void 0x0:_0x1a1adb[_0x1385aa(0x222)]();if(!_0x20d992)return'';let _0x2f7fae=_0x20d992[_0x1385aa(0x1d2)][_0x1385aa(0x22a)](_0x8a8a6f,_0xd752ed),_0x4e9ae2=((_0xd0c458=_0x20d992[_0x1385aa(0x1a6)])==null?void 0x0:_0xd0c458['filter'](_0x4e46bc=>w(_0x4e46bc)&&_0x4e46bc[_0x1385aa(0x24f)]>=_0x8a8a6f&&_0x4e46bc[_0x1385aa(0x19f)]<_0xd752ed)[_0x1385aa(0x1dc)]((_0x3ccd61,_0x5addfc)=>_0x5addfc[_0x1385aa(0x24f)]-_0x3ccd61['startIndex']))??[];for(let _0x1f51b0 of _0x4e9ae2){let _0x4880ff=_0x1f51b0['startIndex']-_0x8a8a6f,_0xde8e51=_0x1f51b0[_0x1385aa(0x19f)]-_0x8a8a6f+0x1;_0x2f7fae=''+_0x2f7fae['slice'](0x0,_0x4880ff)+this[_0x1385aa(0x271)](_0x3effef,_0x1f51b0[_0x1385aa(0x251)])+_0x2f7fae[_0x1385aa(0x22a)](_0xde8e51);}return _0x2f7fae;}[_0x18accd(0x1b5)](_0x3b2503){return Ot(_0x3b2503);}['degradeBody'](_0x4562d9,_0x8fe63c,_0x399404={}){const _0x57cb6a=_0x18accd;var _0x1b3de1;return Ve({'id':_0x4562d9,'body':_0x8fe63c,'documentStyle':{}},(((_0x1b3de1=_0x8fe63c[_0x57cb6a(0x1a6)])==null?void 0x0:_0x1b3de1[_0x57cb6a(0x252)](w))??[])[_0x57cb6a(0x1f3)](_0x5c3098=>({'rangeId':_0x5c3098[_0x57cb6a(0x251)],'text':_0x399404[_0x5c3098[_0x57cb6a(0x251)]]??this[_0x57cb6a(0x271)](_0x4562d9,_0x5c3098[_0x57cb6a(0x251)])})))[_0x57cb6a(0x212)]??{'dataStream':''};}};Z=I([F(0x0,_0x478f5d),F(0x1,_0x2bb8ca(L)),F(0x2,_0x2bb8ca(_0x329faf))],Z);function Ot(_0x49a637){const _0x4bb4f2=_0x18accd;var _0x5197ed,_0x281917;let _0x589687=kt(_0x49a637),_0x23905e=Ve(_0x49a637,(((_0x5197ed=_0x49a637[_0x4bb4f2(0x212)])==null||(_0x5197ed=_0x5197ed[_0x4bb4f2(0x1a6)])==null?void 0x0:_0x5197ed['filter'](w))??[])[_0x4bb4f2(0x1f3)](_0x1e5546=>({'rangeId':_0x1e5546[_0x4bb4f2(0x251)],'text':At(_0x589687==null?void 0x0:_0x589687[_0x4bb4f2(0x1b9)][_0x1e5546[_0x4bb4f2(0x251)]])})));return _0x23905e[_0x4bb4f2(0x263)]=(_0x281917=_0x23905e[_0x4bb4f2(0x263)])==null?void 0x0:_0x281917[_0x4bb4f2(0x252)](_0x300316=>_0x300316[_0x4bb4f2(0x1c8)]!==y),_0x23905e;}function kt(_0x1d20a0){const _0x358ffc=_0x18accd;var _0x5cffd8;let _0x404e62=(_0x5cffd8=_0x1d20a0['resources'])==null||(_0x5cffd8=_0x5cffd8['find'](_0x2c9d48=>_0x2c9d48['name']===_0x358ffc(0x17d)))==null?void 0x0:_0x5cffd8[_0x358ffc(0x18b)];if(_0x404e62)try{let _0x77e541=JSON['parse'](_0x404e62);return x(_0x77e541)?_0x77e541:void 0x0;}catch{return;}}function At(_0x2eafb1){const _0x5c27e0=_0x18accd;return _0x2eafb1?_0x3cd2e8({'lastValue':_0x2eafb1['lastValue'],'numberFormat':_0x2eafb1[_0x5c27e0(0x255)]})[_0x5c27e0(0x242)]:'';}let Q=class extends _0x474e08{constructor(_0x28b65b,_0x16f87b,_0x14b4e9){const _0x5e1efb=_0x18accd;super(),this[_0x5e1efb(0x1ce)]=_0x28b65b,this['_cacheEligibilityService']=_0x16f87b,this['disposeWithMe'](_0x14b4e9['registerProvider'](this));}['collectMutations'](_0x42246f){const _0x3f7173=_0x18accd;let _0x549a79=new Map();for(let _0x460fe4 of this[_0x3f7173(0x1ce)][_0x3f7173(0x1f2)]()){var _0x31cc08;if(!this[_0x3f7173(0x24b)]['assess'](_0x460fe4[_0x3f7173(0x1ba)][_0x3f7173(0x193)],_0x460fe4['liveResult'])[_0x3f7173(0x260)])continue;let _0x3146c8=_0x1f7dc0(_0x460fe4['liveResult']),_0x3c2063=_0x3146c8?_0x1d1d0a(_0x3146c8):null;if(!_0x3c2063||jt(_0x460fe4[_0x3f7173(0x1ba)]['lastValue'],_0x3c2063))continue;let _0x530b09=_0x549a79[_0x3f7173(0x1ab)](_0x460fe4[_0x3f7173(0x175)][_0x3f7173(0x1ad)])??[];_0x530b09[_0x3f7173(0x253)]({'rangeId':_0x460fe4['identity'][_0x3f7173(0x251)],'expectedFormula':_0x460fe4['config'][_0x3f7173(0x193)],'expectedNumberFormat':(_0x31cc08=_0x460fe4[_0x3f7173(0x1ba)][_0x3f7173(0x255)])==null?void 0x0:_0x31cc08[_0x3f7173(0x1f9)],'expectedReferenceRevision':_0x460fe4[_0x3f7173(0x26f)],'lastValue':_0x3c2063}),_0x549a79['set'](_0x460fe4[_0x3f7173(0x175)][_0x3f7173(0x1ad)],_0x530b09);}return Array[_0x3f7173(0x1ec)](_0x549a79,([_0x46ccfa,_0x3b726b])=>({'id':H['id'],'params':{'unitId':_0x46ccfa,'updates':_0x3b726b}}));}};Q=I([F(0x0,_0x2bb8ca(L)),F(0x1,_0x2bb8ca(_0x562e65)),F(0x2,_0x2bb8ca(_0x29a8c7))],Q);function jt(_0x409a31,_0x4bb678){const _0x263e89=_0x18accd;return(_0x409a31==null?void 0x0:_0x409a31['v'])===_0x4bb678['v']&&(_0x409a31==null?void 0x0:_0x409a31['t'])===_0x4bb678['t']&&(_0x409a31==null?void 0x0:_0x409a31[_0x263e89(0x1f9)])===_0x4bb678[_0x263e89(0x1f9)];}let $=class extends _0x2ed24f{constructor(_0xf0cfa7=Dt,_0x50b363,_0x1d0177,_0x5d89f4){const _0x111037=_0x18accd;super(),this[_0x111037(0x19b)]=_0xf0cfa7,this[_0x111037(0x1e3)]=_0x50b363,this[_0x111037(0x227)]=_0x1d0177,this[_0x111037(0x179)]=_0x5d89f4;let {..._0x2e2ba8}=_0x350a4c({},Dt,this[_0x111037(0x19b)]);this[_0x111037(0x179)][_0x111037(0x1cc)](_0x111037(0x22f),_0x2e2ba8);}[_0x18accd(0x1d7)](){const _0x5a6701=_0x18accd;this['_injector'][_0x5a6701(0x1af)]([P]),this[_0x5a6701(0x1e3)][_0x5a6701(0x1af)]([L]),this['_injector'][_0x5a6701(0x1af)]([X]),this[_0x5a6701(0x1e3)][_0x5a6701(0x1af)]([Y]),this[_0x5a6701(0x1e3)][_0x5a6701(0x1af)]([Q]),this[_0x5a6701(0x1e3)][_0x5a6701(0x1af)]([Z]),_0x2ca687(this['_injector'],[[P],[X],[Y],[Q],[Z]]),[ot,st,V,H,U,W,G,K,ct,lt][_0x5a6701(0x19c)](_0x357689=>this[_0x5a6701(0x223)](this[_0x5a6701(0x227)][_0x5a6701(0x1e7)](_0x357689)));}};N($,_0x18accd(0x1de),y),N($,'packageName',Tt),N($,_0x18accd(0x17a),Et),N($,_0x18accd(0x250),_0x50d692['UNIVER_DOC']),$=I([_0x2a626f(_0x3c3fb2,_0x351eb2,_0x5b3025),F(0x1,_0x2bb8ca(_0x21727e)),F(0x2,_0x222411),F(0x3,_0x2701f4)],$);export{lt as ConvertDocFormulaToTextCommand,Me as DOC_FORMULA_CUSTOM_RANGE_KIND,Ne as DOC_FORMULA_OBJECT_REPLACEMENT,y as DOC_FORMULA_PLUGIN,je as DOC_FORMULA_SCHEMA_VERSION,Z as DocFormulaDisplayTextService,Y as DocFormulaLifecycleController,P as DocFormulaModel,X as DocFormulaResourceController,it as DocFormulaResultStatus,L as DocFormulaService,U as InsertDocFormulaCommand,C as InvalidDocFormulaInsertRangeError,K as RemoveDocFormulaCommand,st as RemoveDocFormulaMutation,ct as ReplaceDocFormulaWithTextCommand,H as SetDocFormulaLastValuesMutation,ot as SetDocFormulaMutation,G as SetDocFormulaNumberFormatCommand,V as SetDocFormulaResourceMutation,$ as UniverDocsFormulaPlugin,W as UpdateDocFormulaCommand,He as assertSafeDocFormulaInsertRange,Re as buildInsertDocFormulaActions,Be as buildRemoveDocFormulaActions,ze as buildUpdateDocFormulaActions,b as createEmptyDocFormulaResource,Ot as degradeDocFormulaDocumentData,T as findDocFormulaRange,Pe as isDocFormulaConfig,w as isDocFormulaRange,x as isDocFormulaResource,Fe as isFormulaLastValue};
|
package/lib/umd/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x4a16be,_0x255019){var _0x6086ec=_0x5993,_0x4c7374=_0x4a16be();while(!![]){try{var _0x5289c7=parseInt(_0x6086ec(0x1c3))/0x1+-parseInt(_0x6086ec(0x1b6))/0x2+parseInt(_0x6086ec(0x1d0))/0x3*(-parseInt(_0x6086ec(0x1ce))/0x4)+parseInt(_0x6086ec(0x1b0))/0x5*(-parseInt(_0x6086ec(0x1ba))/0x6)+parseInt(_0x6086ec(0x19c))/0x7*(-parseInt(_0x6086ec(0x1dc))/0x8)+-parseInt(_0x6086ec(0x182))/0x9*(-parseInt(_0x6086ec(0x1e0))/0xa)+parseInt(_0x6086ec(0x1da))/0xb;if(_0x5289c7===_0x255019)break;else _0x4c7374['push'](_0x4c7374['shift']());}catch(_0x2541d5){_0x4c7374['push'](_0x4c7374['shift']());}}}(_0x43c2,0xda6b8),function(_0x39cc3e,_0x510822){var _0x158378=_0x5993;typeof exports==_0x158378(0x1b9)&&typeof module<'u'?_0x510822(exports,require('@univerjs-pro/docs-formula'),require('@univerjs/core'),require('@univerjs/docs/facade')):typeof define==_0x158378(0x1ad)&&define[_0x158378(0x1a5)]?define([_0x158378(0x1af),_0x158378(0x1d6),_0x158378(0x188),_0x158378(0x19f)],_0x510822):(_0x39cc3e=typeof globalThis<'u'?globalThis:_0x39cc3e||self,_0x510822(_0x39cc3e['UniverProDocsFormulaFacade']={},_0x39cc3e[_0x158378(0x17f)],_0x39cc3e['UniverCore'],_0x39cc3e[_0x158378(0x1ab)]));}(this,function(_0x3450d4,_0x3d42bb,_0xa08dd3,_0x22bf3b){var _0x2a5a97=_0x5993;Object['defineProperty'](_0x3450d4,Symbol[_0x2a5a97(0x198)],{'value':'Module'});function _0x42d631(_0x39fc70,_0x3d8556){return function(_0x1217ec,_0x39b440){_0x3d8556(_0x1217ec,_0x39b440,_0x39fc70);};}function _0x57a263(_0x115801,_0x3215ef,_0x215a5c,_0x34f7e2){var _0x21c2af=_0x2a5a97,_0xb16976=arguments[_0x21c2af(0x1b7)],_0x332a0d=_0xb16976<0x3?_0x3215ef:_0x34f7e2===null?_0x34f7e2=Object['getOwnPropertyDescriptor'](_0x3215ef,_0x215a5c):_0x34f7e2,_0x111817;if(typeof Reflect==_0x21c2af(0x1b9)&&typeof Reflect[_0x21c2af(0x1c2)]=='function')_0x332a0d=Reflect[_0x21c2af(0x1c2)](_0x115801,_0x3215ef,_0x215a5c,_0x34f7e2);else{for(var _0x5ce0f8=_0x115801['length']-0x1;_0x5ce0f8>=0x0;_0x5ce0f8--)(_0x111817=_0x115801[_0x5ce0f8])&&(_0x332a0d=(_0xb16976<0x3?_0x111817(_0x332a0d):_0xb16976>0x3?_0x111817(_0x3215ef,_0x215a5c,_0x332a0d):_0x111817(_0x3215ef,_0x215a5c))||_0x332a0d);}return _0xb16976>0x3&&_0x332a0d&&Object[_0x21c2af(0x196)](_0x3215ef,_0x215a5c,_0x332a0d),_0x332a0d;}let _0x44d8c0=class{constructor(_0x557c94,_0x456443,_0x17ae7d,_0x1b8bf3,_0x4007aa,_0x13162f){var _0x54af9e=_0x2a5a97;this[_0x54af9e(0x1cc)]=_0x557c94,this[_0x54af9e(0x1a0)]=_0x456443,this[_0x54af9e(0x19e)]=_0x17ae7d,this[_0x54af9e(0x197)]=_0x1b8bf3,this[_0x54af9e(0x190)]=_0x4007aa,this[_0x54af9e(0x1cb)]=_0x13162f;}[_0x2a5a97(0x1be)](){var _0x4b3b53=_0x2a5a97;return this[_0x4b3b53(0x1a0)];}[_0x2a5a97(0x1d2)](){var _0x313ce5=_0x2a5a97;let _0x2d362a=this[_0x313ce5(0x19a)]();return _0x2d362a?{'endOffset':_0x2d362a[_0x313ce5(0x1b4)]+0x1,'rangeId':_0x2d362a[_0x313ce5(0x17e)],'startOffset':_0x2d362a[_0x313ce5(0x181)]}:null;}[_0x2a5a97(0x1de)](){var _0x2e0f37=_0x2a5a97,_0x194356;return((_0x194356=this[_0x2e0f37(0x197)]['getFormula'](this[_0x2e0f37(0x1cc)],this[_0x2e0f37(0x1a0)]))==null?void 0x0:_0x194356[_0x2e0f37(0x1ca)])??'';}['getConfig'](){var _0x37fe0d=_0x2a5a97;return this[_0x37fe0d(0x197)][_0x37fe0d(0x1de)](this[_0x37fe0d(0x1cc)],this[_0x37fe0d(0x1a0)])??null;}[_0x2a5a97(0x1b2)](){var _0x393c55=_0x2a5a97;return this[_0x393c55(0x190)][_0x393c55(0x1b2)]({'unitId':this[_0x393c55(0x1cc)],'rangeId':this[_0x393c55(0x1a0)]})??null;}['describe'](){var _0x2065fc=_0x2a5a97;let _0x9a29c5=this[_0x2065fc(0x1d2)](),_0x120089=this[_0x2065fc(0x1db)](),_0x52e6c3=this[_0x2065fc(0x1b2)]();return!_0x9a29c5||!_0x120089||!_0x52e6c3?null:{..._0x9a29c5,'config':_0x120089,'formula':_0x120089['formula'],'result':_0x52e6c3,'type':_0x2065fc(0x1ca)};}[_0x2a5a97(0x1bd)](_0x3a64e4){var _0x52ae65=_0x2a5a97;return this[_0x52ae65(0x19e)][_0x52ae65(0x1cd)](_0x3d42bb[_0x52ae65(0x1a2)]['id'],{'externalReferences':_0x3a64e4['externalReferences'],'formula':_0x3a64e4[_0x52ae65(0x1ca)],'numberFormat':_0x3a64e4['numberFormat'],'rangeId':this['_rangeId'],'unitId':this[_0x52ae65(0x1cc)]});}['setNumberFormat'](_0x3c0bcc){var _0x211806=_0x2a5a97;return this[_0x211806(0x19e)][_0x211806(0x1cd)](_0x3d42bb[_0x211806(0x18e)]['id'],{'numberFormat':_0x3c0bcc,'rangeId':this[_0x211806(0x1a0)],'unitId':this[_0x211806(0x1cc)]});}[_0x2a5a97(0x185)](){var _0x50b398=_0x2a5a97;return this[_0x50b398(0x19e)]['syncExecuteCommand'](_0x3d42bb[_0x50b398(0x199)]['id'],{'rangeId':this[_0x50b398(0x1a0)],'unitId':this[_0x50b398(0x1cc)]});}[_0x2a5a97(0x1d5)](_0x15ac1e){var _0x1caf2b=_0x2a5a97;return this[_0x1caf2b(0x19e)][_0x1caf2b(0x1cd)](_0x3d42bb[_0x1caf2b(0x18d)]['id'],{'rangeId':this['_rangeId'],'text':_0x15ac1e,'unitId':this['_unitId']});}[_0x2a5a97(0x1b5)](){var _0x211009=_0x2a5a97;return this[_0x211009(0x19e)]['syncExecuteCommand'](_0x3d42bb['ConvertDocFormulaToTextCommand']['id'],{'rangeId':this['_rangeId'],'unitId':this[_0x211009(0x1cc)]});}['_getCustomRange'](){var _0x54e0be=_0x2a5a97,_0x347f76;let _0x4b2970=this[_0x54e0be(0x1cb)]['getUnit'](this[_0x54e0be(0x1cc)],_0xa08dd3[_0x54e0be(0x1a8)]['UNIVER_DOC']);return _0x4b2970==null||(_0x347f76=_0x4b2970['getSnapshot']()[_0x54e0be(0x18b)])==null||(_0x347f76=_0x347f76['customRanges'])==null?void 0x0:_0x347f76[_0x54e0be(0x1a1)](_0x277605=>_0x277605[_0x54e0be(0x17e)]===this[_0x54e0be(0x1a0)]&&(0x0,_0x3d42bb[_0x54e0be(0x1c4)])(_0x277605));}};_0x44d8c0=_0x57a263([_0x42d631(0x2,_0xa08dd3[_0x2a5a97(0x1c5)]),_0x42d631(0x3,(0x0,_0xa08dd3[_0x2a5a97(0x1cf)])(_0x3d42bb[_0x2a5a97(0x17b)])),_0x42d631(0x4,(0x0,_0xa08dd3[_0x2a5a97(0x1cf)])(_0x3d42bb[_0x2a5a97(0x1b8)])),_0x42d631(0x5,_0xa08dd3[_0x2a5a97(0x193)])],_0x44d8c0);function _0x56a9f0(_0x2a73b9){'@babel/helpers - typeof';var _0x348b4f=_0x2a5a97;return _0x56a9f0=typeof Symbol==_0x348b4f(0x1ad)&&typeof Symbol[_0x348b4f(0x1d3)]==_0x348b4f(0x18c)?function(_0x5cfac2){return typeof _0x5cfac2;}:function(_0x2dde8c){var _0x11ae24=_0x348b4f;return _0x2dde8c&&typeof Symbol==_0x11ae24(0x1ad)&&_0x2dde8c['constructor']===Symbol&&_0x2dde8c!==Symbol[_0x11ae24(0x1bf)]?_0x11ae24(0x18c):typeof _0x2dde8c;},_0x56a9f0(_0x2a73b9);}function _0x18608b(_0x112691,_0x4dbe19){var _0x20908a=_0x2a5a97;if(_0x56a9f0(_0x112691)!=_0x20908a(0x1b9)||!_0x112691)return _0x112691;var _0x2e0e=_0x112691[Symbol[_0x20908a(0x1b1)]];if(_0x2e0e!==void 0x0){var _0x1d52e0=_0x2e0e[_0x20908a(0x1a6)](_0x112691,_0x4dbe19||_0x20908a(0x1c0));if(_0x56a9f0(_0x1d52e0)!='object')return _0x1d52e0;throw TypeError(_0x20908a(0x1dd));}return(_0x4dbe19===_0x20908a(0x1aa)?String:Number)(_0x112691);}function _0x36fc7e(_0x408472){var _0x311fb7=_0x2a5a97,_0x29d2aa=_0x18608b(_0x408472,'string');return _0x56a9f0(_0x29d2aa)==_0x311fb7(0x18c)?_0x29d2aa:_0x29d2aa+'';}function _0x3df14f(_0x260311,_0x18ab2c,_0x56fded){var _0x4e4cea=_0x2a5a97;return(_0x18ab2c=_0x36fc7e(_0x18ab2c))in _0x260311?Object[_0x4e4cea(0x196)](_0x260311,_0x18ab2c,{'value':_0x56fded,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x260311[_0x18ab2c]=_0x56fded,_0x260311;}var _0x278f09=class extends _0x22bf3b[_0x2a5a97(0x1d4)]{constructor(..._0x1a5890){var _0x100a53=_0x2a5a97;super(..._0x1a5890),_0x3df14f(this,_0x100a53(0x183),void 0x0),_0x3df14f(this,_0x100a53(0x1d9),void 0x0),_0x3df14f(this,'_docsFormulaModel',void 0x0),_0x3df14f(this,_0x100a53(0x19d),void 0x0);}[_0x2a5a97(0x191)](_0x44c8d6){var _0xe6f12f=_0x2a5a97;this[_0xe6f12f(0x183)]=_0x44c8d6[_0xe6f12f(0x1bc)](_0xa08dd3[_0xe6f12f(0x1c5)]),this[_0xe6f12f(0x1d9)]=_0x44c8d6['get'](_0x3d42bb[_0xe6f12f(0x1d7)]),this[_0xe6f12f(0x194)]=_0x44c8d6[_0xe6f12f(0x1bc)](_0x3d42bb['DocFormulaModel']),this[_0xe6f12f(0x19d)]=_0x44c8d6['get'](_0xa08dd3[_0xe6f12f(0x1c1)]);}[_0x2a5a97(0x1b3)](){var _0x275a6a=_0x2a5a97;return this[_0x275a6a(0x1a4)]()[_0x275a6a(0x1ac)](_0x5921af=>this['_createFormula'](_0x5921af['rangeId']));}[_0x2a5a97(0x1de)](_0x12ec9b){var _0x29e7eb=_0x2a5a97;return this['_getCompleteRanges']()[_0x29e7eb(0x186)](_0x194aa2=>_0x194aa2['rangeId']===_0x12ec9b)?this[_0x29e7eb(0x1c9)](_0x12ec9b):null;}[_0x2a5a97(0x1a9)](_0x39eda8){var _0x1f1d80=_0x2a5a97;let _0x36c225=this[_0x1f1d80(0x1a4)]()[_0x1f1d80(0x1a1)](_0x5f1826=>_0x5f1826[_0x1f1d80(0x181)]<=_0x39eda8&&_0x39eda8<=_0x5f1826['endIndex']);return _0x36c225?this[_0x1f1d80(0x1c9)](_0x36c225[_0x1f1d80(0x17e)]):null;}[_0x2a5a97(0x1c6)](){var _0x544a13=_0x2a5a97;let _0xde9fe8=this[_0x544a13(0x19d)][_0x544a13(0x180)](this['id']);if(!_0xde9fe8)throw Error(_0x544a13(0x1c7)+this['id']+_0x544a13(0x1df));return this[_0x544a13(0x1d9)][_0x544a13(0x1a7)](_0xde9fe8);}[_0x2a5a97(0x1d8)](_0x34b15c){var _0x5ce13c=_0x2a5a97;return this[_0x5ce13c(0x195)]({'externalReferences':_0x34b15c['externalReferences'],'formula':_0x34b15c[_0x5ce13c(0x1ca)],'numberFormat':_0x34b15c[_0x5ce13c(0x192)],'target':{'type':_0x5ce13c(0x1d1),'startOffset':_0x34b15c[_0x5ce13c(0x187)],'endOffset':_0x34b15c[_0x5ce13c(0x19b)]},'unitId':this[_0x5ce13c(0x1be)]()});}[_0x2a5a97(0x195)](_0x351d65){var _0x1186d0=_0x2a5a97;let _0x232f42=this[_0x1186d0(0x183)][_0x1186d0(0x1cd)](_0x3d42bb[_0x1186d0(0x1ae)]['id'],_0x351d65);return _0x232f42?this[_0x1186d0(0x1c9)](_0x232f42['rangeId']):null;}[_0x2a5a97(0x1a4)](){var _0x5470da=_0x2a5a97,_0x2a8510;let _0x5674c2=this[_0x5470da(0x194)][_0x5470da(0x1b3)](this[_0x5470da(0x1be)]());return((_0x2a8510=this[_0x5470da(0x18a)]('')['customRanges'])==null?void 0x0:_0x2a8510['filter'](_0x1a672b=>(0x0,_0x3d42bb[_0x5470da(0x1c4)])(_0x1a672b)&&_0x5674c2[_0x1a672b[_0x5470da(0x17e)]]!=null))??[];}[_0x2a5a97(0x1c9)](_0x4b3b2d){var _0x1ca907=_0x2a5a97;return this[_0x1ca907(0x1c8)][_0x1ca907(0x189)](_0x44d8c0,this[_0x1ca907(0x1be)](),_0x4b3b2d);}};_0x22bf3b['FDocument'][_0x2a5a97(0x1a3)](_0x278f09);var _0x707824=class extends _0x22bf3b['FDocumentParagraph']{constructor(..._0x4158a4){super(..._0x4158a4),_0x3df14f(this,'_docsFormulaCommandService',void 0x0);}['_initialize'](_0x8a3f51){var _0x2e630e=_0x2a5a97;this[_0x2e630e(0x183)]=_0x8a3f51[_0x2e630e(0x1bc)](_0xa08dd3[_0x2e630e(0x1c5)]);}[_0x2a5a97(0x1d8)](_0x491b4b,_0x5cdeab,_0x211682={}){var _0x339549=_0x2a5a97;return this[_0x339549(0x195)](_0x491b4b,_0x5cdeab,_0x211682);}[_0x2a5a97(0x1bb)](_0x1e7d45,_0x594c59={}){var _0x4d8a95=_0x2a5a97;return this[_0x4d8a95(0x195)]('end',_0x1e7d45,_0x594c59);}[_0x2a5a97(0x195)](_0x23307f,_0xc5c9c3,_0x6352fe){var _0x48c745=_0x2a5a97;if(this['getSegmentId']())return null;let _0x3c1b0c={'externalReferences':_0x6352fe[_0x48c745(0x17c)],'formula':_0xc5c9c3,'numberFormat':_0x6352fe[_0x48c745(0x192)],'target':{'type':'paragraph','paragraphId':this[_0x48c745(0x1be)](),'position':_0x23307f},'unitId':this[_0x48c745(0x17d)][_0x48c745(0x1be)]()},_0x5109fb=this[_0x48c745(0x183)]['syncExecuteCommand'](_0x3d42bb['InsertDocFormulaCommand']['id'],_0x3c1b0c);return _0x5109fb?this[_0x48c745(0x1c8)]['createInstance'](_0x44d8c0,this[_0x48c745(0x17d)]['getId'](),_0x5109fb[_0x48c745(0x17e)]):null;}};_0x22bf3b['FDocumentParagraph'][_0x2a5a97(0x1a3)](_0x707824);var _0x468a2b=class extends _0x22bf3b[_0x2a5a97(0x18f)]{constructor(..._0xde82dd){var _0x5da032=_0x2a5a97;super(..._0xde82dd),_0x3df14f(this,_0x5da032(0x183),void 0x0);}[_0x2a5a97(0x191)](_0x5c3b12){var _0x25140e=_0x2a5a97;this[_0x25140e(0x183)]=_0x5c3b12[_0x25140e(0x1bc)](_0xa08dd3[_0x25140e(0x1c5)]);}['replaceWithFormula'](_0x2514d7,_0x5df20d={}){var _0x3066f8=_0x2a5a97;let {endOffset:_0x561005,segmentId:_0x561cf4,startOffset:_0x1761f2}=this[_0x3066f8(0x1d2)]();return _0x561cf4?null:this[_0x3066f8(0x195)](_0x1761f2,_0x561005,_0x2514d7,_0x5df20d);}[_0x2a5a97(0x195)](_0x342f71,_0xba273d,_0x6af3f7,_0x1b2bca){var _0xe0fb49=_0x2a5a97;let _0x2baba2={'externalReferences':_0x1b2bca[_0xe0fb49(0x17c)],'formula':_0x6af3f7,'numberFormat':_0x1b2bca[_0xe0fb49(0x192)],'target':{'type':_0xe0fb49(0x1d1),'startOffset':_0x342f71,'endOffset':_0xba273d},'unitId':this[_0xe0fb49(0x17d)][_0xe0fb49(0x1be)]()},_0x2f6a55=this[_0xe0fb49(0x183)][_0xe0fb49(0x1cd)](_0x3d42bb[_0xe0fb49(0x1ae)]['id'],_0x2baba2);return _0x2f6a55?this[_0xe0fb49(0x1c8)]['createInstance'](_0x44d8c0,this[_0xe0fb49(0x17d)][_0xe0fb49(0x1be)](),_0x2f6a55[_0xe0fb49(0x17e)]):null;}};_0x22bf3b[_0x2a5a97(0x18f)]['extend'](_0x468a2b),Object[_0x2a5a97(0x196)](_0x3450d4,_0x2a5a97(0x184),{'enumerable':!0x0,'get':function(){return _0x44d8c0;}});}));function _0x5993(_0x3171f3,_0x1e69f6){_0x3171f3=_0x3171f3-0x17b;var _0x43c203=_0x43c2();var _0x5993cd=_0x43c203[_0x3171f3];return _0x5993cd;}function _0x43c2(){var _0xe3105c=['UpdateDocFormulaCommand','extend','_getCompleteRanges','amd','call','degradeDocumentData','UniverInstanceType','getFormulaAt','string','UniverDocsFacade','map','function','InsertDocFormulaCommand','exports','7555YzLzsB','toPrimitive','getResult','getFormulas','endIndex','convertToText','2685972bAzmzE','length','DocFormulaService','object','2634dxzcmn','appendFormula','get','update','getId','prototype','default','IResourceLoaderService','decorate','826190LEOlXO','isDocFormulaRange','ICommandService','saveFormulaDisplayTextSnapshot','Document\x20','_injector','_createFormula','formula','_univerInstanceService','_unitId','syncExecuteCommand','13956IoqazZ','Inject','654Ngvvvj','range','getRange','iterator','FDocument','replaceWithText','@univerjs-pro/docs-formula','DocFormulaDisplayTextService','insertFormula','_docsFormulaDisplayTextService','48315135wScbKt','getConfig','8zEelyL','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','getFormula','\x20could\x20not\x20be\x20serialized.','2159290SIBpDc','DocFormulaModel','externalReferences','_document','rangeId','UniverProDocsFormula','saveUnit','startIndex','9IEtysH','_docsFormulaCommandService','FDocumentFormula','remove','some','startOffset','@univerjs/core','createInstance','getBody','body','symbol','ReplaceDocFormulaWithTextCommand','SetDocFormulaNumberFormatCommand','FDocumentTextRange','_service','_initialize','numberFormat','IUniverInstanceService','_docsFormulaModel','_insert','defineProperty','_model','toStringTag','RemoveDocFormulaCommand','_getCustomRange','endOffset','12409873wyDfdB','_docsFormulaResourceLoaderService','_commandService','@univerjs/docs/facade','_rangeId','find'];_0x43c2=function(){return _0xe3105c;};return _0x43c2();}
|
|
1
|
+
function _0x5036(){var _0x56ecb5=['update','InsertDocFormulaCommand','toStringTag','function','ConvertDocFormulaToTextCommand','iterator','_document','length','_service','get','body','some','2cGTFmh','_getCustomRange','_docsFormulaCommandService','endIndex','_model','UniverDocsFacade','UniverProDocsFormulaFacade','6MqUiPK','_createFormula','call','constructor','_docsFormulaResourceLoaderService','rangeId','paragraph','default','_rangeId','end','createInstance','14415968KtlIbO','decorate','12131287lRprMl','getSegmentId','UNIVER_DOC','setNumberFormat','convertToText','range','UpdateDocFormulaCommand','getRange','saveFormulaDisplayTextSnapshot','getOwnPropertyDescriptor','getSnapshot','_univerInstanceService','_insert','FDocumentTextRange','@univerjs/docs/facade','exports','degradeDocumentData','getFormulaAt','40018FITZqF','find','\x20could\x20not\x20be\x20serialized.','getBody','FDocumentParagraph','getFormula','_getCompleteRanges','formula','syncExecuteCommand','toPrimitive','describe','insertFormula','UniverProDocsFormula','@univerjs-pro/docs-formula','getId','DocFormulaModel','amd','prototype','customRanges','isDocFormulaRange','@univerjs/core','19400fvBuaJ','UniverInstanceType','defineProperty','DocFormulaService','startIndex','getUnit','endOffset','_injector','ICommandService','_unitId','getResult','_commandService','IUniverInstanceService','9023010MqBtQG','Inject','_docsFormulaDisplayTextService','_initialize','extend','externalReferences','15fVBAUl','symbol','getConfig','numberFormat','801704GecLtL','startOffset','IResourceLoaderService','FDocument','getFormulas','Document\x20','object','222023PxJClV','string','_docsFormulaModel','3865608AXiewY','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.'];_0x5036=function(){return _0x56ecb5;};return _0x5036();}function _0x4cc1(_0x521458,_0x56616f){_0x521458=_0x521458-0x126;var _0x5036a8=_0x5036();var _0x4cc1e9=_0x5036a8[_0x521458];return _0x4cc1e9;}(function(_0x46971e,_0xf9d0c6){var _0x99d68a=_0x4cc1,_0x27dbe3=_0x46971e();while(!![]){try{var _0x5a612a=parseInt(_0x99d68a(0x173))/0x1*(-parseInt(_0x99d68a(0x184))/0x2)+-parseInt(_0x99d68a(0x168))/0x3*(parseInt(_0x99d68a(0x16c))/0x4)+-parseInt(_0x99d68a(0x162))/0x5+parseInt(_0x99d68a(0x18b))/0x6*(-parseInt(_0x99d68a(0x12e))/0x7)+-parseInt(_0x99d68a(0x12c))/0x8+parseInt(_0x99d68a(0x176))/0x9+-parseInt(_0x99d68a(0x155))/0xa*(-parseInt(_0x99d68a(0x140))/0xb);if(_0x5a612a===_0xf9d0c6)break;else _0x27dbe3['push'](_0x27dbe3['shift']());}catch(_0x2b4e5c){_0x27dbe3['push'](_0x27dbe3['shift']());}}}(_0x5036,0xe1730),function(_0x48acad,_0x1ecd98){var _0x2be235=_0x4cc1;typeof exports=='object'&&typeof module<'u'?_0x1ecd98(exports,require('@univerjs-pro/docs-formula'),require('@univerjs/core'),require('@univerjs/docs/facade')):typeof define==_0x2be235(0x17b)&&define[_0x2be235(0x150)]?define([_0x2be235(0x13d),_0x2be235(0x14d),_0x2be235(0x154),_0x2be235(0x13c)],_0x1ecd98):(_0x48acad=typeof globalThis<'u'?globalThis:_0x48acad||self,_0x1ecd98(_0x48acad[_0x2be235(0x18a)]={},_0x48acad[_0x2be235(0x14c)],_0x48acad['UniverCore'],_0x48acad[_0x2be235(0x189)]));}(this,function(_0x3c2de3,_0x3edadc,_0x57386b,_0x8f6320){var _0x1465ed=_0x4cc1;Object[_0x1465ed(0x157)](_0x3c2de3,Symbol[_0x1465ed(0x17a)],{'value':'Module'});function _0x1db012(_0x407d0e,_0x5d1657){return function(_0x5c27cb,_0x572dca){_0x5d1657(_0x5c27cb,_0x572dca,_0x407d0e);};}function _0x35dd4b(_0x263bb8,_0x27ac2f,_0x318387,_0x73db3c){var _0x11c41e=_0x1465ed,_0x486887=arguments[_0x11c41e(0x17f)],_0x555caf=_0x486887<0x3?_0x27ac2f:_0x73db3c===null?_0x73db3c=Object[_0x11c41e(0x137)](_0x27ac2f,_0x318387):_0x73db3c,_0x338be0;if(typeof Reflect==_0x11c41e(0x172)&&typeof Reflect['decorate']=='function')_0x555caf=Reflect[_0x11c41e(0x12d)](_0x263bb8,_0x27ac2f,_0x318387,_0x73db3c);else{for(var _0x153ccf=_0x263bb8[_0x11c41e(0x17f)]-0x1;_0x153ccf>=0x0;_0x153ccf--)(_0x338be0=_0x263bb8[_0x153ccf])&&(_0x555caf=(_0x486887<0x3?_0x338be0(_0x555caf):_0x486887>0x3?_0x338be0(_0x27ac2f,_0x318387,_0x555caf):_0x338be0(_0x27ac2f,_0x318387))||_0x555caf);}return _0x486887>0x3&&_0x555caf&&Object['defineProperty'](_0x27ac2f,_0x318387,_0x555caf),_0x555caf;}let _0x462310=class{constructor(_0x53e266,_0x2aa407,_0x2f0eb5,_0x336565,_0x476c6f,_0x40f7a4){var _0x108e94=_0x1465ed;this[_0x108e94(0x15e)]=_0x53e266,this[_0x108e94(0x129)]=_0x2aa407,this['_commandService']=_0x2f0eb5,this[_0x108e94(0x188)]=_0x336565,this[_0x108e94(0x180)]=_0x476c6f,this[_0x108e94(0x139)]=_0x40f7a4;}['getId'](){var _0x45e940=_0x1465ed;return this[_0x45e940(0x129)];}[_0x1465ed(0x135)](){var _0x1f3afc=_0x1465ed;let _0x599db1=this[_0x1f3afc(0x185)]();return _0x599db1?{'endOffset':_0x599db1[_0x1f3afc(0x187)]+0x1,'rangeId':_0x599db1[_0x1f3afc(0x126)],'startOffset':_0x599db1[_0x1f3afc(0x159)]}:null;}[_0x1465ed(0x145)](){var _0x37eab6=_0x1465ed,_0x55bd49;return((_0x55bd49=this['_model'][_0x37eab6(0x145)](this['_unitId'],this['_rangeId']))==null?void 0x0:_0x55bd49[_0x37eab6(0x147)])??'';}[_0x1465ed(0x16a)](){var _0x652f1c=_0x1465ed;return this[_0x652f1c(0x188)][_0x652f1c(0x145)](this[_0x652f1c(0x15e)],this[_0x652f1c(0x129)])??null;}[_0x1465ed(0x15f)](){var _0x4a6072=_0x1465ed;return this[_0x4a6072(0x180)][_0x4a6072(0x15f)]({'unitId':this[_0x4a6072(0x15e)],'rangeId':this[_0x4a6072(0x129)]})??null;}[_0x1465ed(0x14a)](){var _0x4715f4=_0x1465ed;let _0x5ce48a=this[_0x4715f4(0x135)](),_0x178b29=this['getConfig'](),_0x29cd45=this['getResult']();return!_0x5ce48a||!_0x178b29||!_0x29cd45?null:{..._0x5ce48a,'config':_0x178b29,'formula':_0x178b29[_0x4715f4(0x147)],'result':_0x29cd45,'type':_0x4715f4(0x147)};}[_0x1465ed(0x178)](_0x483283){var _0x380984=_0x1465ed;return this['_commandService']['syncExecuteCommand'](_0x3edadc[_0x380984(0x134)]['id'],{'externalReferences':_0x483283[_0x380984(0x167)],'formula':_0x483283[_0x380984(0x147)],'numberFormat':_0x483283[_0x380984(0x16b)],'rangeId':this[_0x380984(0x129)],'unitId':this[_0x380984(0x15e)]});}[_0x1465ed(0x131)](_0x281bc6){var _0xa6391f=_0x1465ed;return this[_0xa6391f(0x160)][_0xa6391f(0x148)](_0x3edadc['SetDocFormulaNumberFormatCommand']['id'],{'numberFormat':_0x281bc6,'rangeId':this[_0xa6391f(0x129)],'unitId':this[_0xa6391f(0x15e)]});}['remove'](){var _0x5715b5=_0x1465ed;return this[_0x5715b5(0x160)]['syncExecuteCommand'](_0x3edadc['RemoveDocFormulaCommand']['id'],{'rangeId':this[_0x5715b5(0x129)],'unitId':this['_unitId']});}['replaceWithText'](_0x5e958e){var _0x5c82b6=_0x1465ed;return this[_0x5c82b6(0x160)][_0x5c82b6(0x148)](_0x3edadc['ReplaceDocFormulaWithTextCommand']['id'],{'rangeId':this[_0x5c82b6(0x129)],'text':_0x5e958e,'unitId':this['_unitId']});}[_0x1465ed(0x132)](){var _0xa35d9d=_0x1465ed;return this[_0xa35d9d(0x160)][_0xa35d9d(0x148)](_0x3edadc[_0xa35d9d(0x17c)]['id'],{'rangeId':this[_0xa35d9d(0x129)],'unitId':this[_0xa35d9d(0x15e)]});}[_0x1465ed(0x185)](){var _0xb64e65=_0x1465ed,_0x2dfd85;let _0x162cdc=this['_univerInstanceService'][_0xb64e65(0x15a)](this[_0xb64e65(0x15e)],_0x57386b[_0xb64e65(0x156)][_0xb64e65(0x130)]);return _0x162cdc==null||(_0x2dfd85=_0x162cdc[_0xb64e65(0x138)]()[_0xb64e65(0x182)])==null||(_0x2dfd85=_0x2dfd85[_0xb64e65(0x152)])==null?void 0x0:_0x2dfd85['find'](_0x211d7d=>_0x211d7d['rangeId']===this['_rangeId']&&(0x0,_0x3edadc['isDocFormulaRange'])(_0x211d7d));}};_0x462310=_0x35dd4b([_0x1db012(0x2,_0x57386b[_0x1465ed(0x15d)]),_0x1db012(0x3,(0x0,_0x57386b[_0x1465ed(0x163)])(_0x3edadc['DocFormulaModel'])),_0x1db012(0x4,(0x0,_0x57386b['Inject'])(_0x3edadc[_0x1465ed(0x158)])),_0x1db012(0x5,_0x57386b[_0x1465ed(0x161)])],_0x462310);function _0x34cf4b(_0x40ece7){'@babel/helpers - typeof';var _0x38b373=_0x1465ed;return _0x34cf4b=typeof Symbol==_0x38b373(0x17b)&&typeof Symbol[_0x38b373(0x17d)]==_0x38b373(0x169)?function(_0xb8c741){return typeof _0xb8c741;}:function(_0x3ea73b){var _0x384190=_0x38b373;return _0x3ea73b&&typeof Symbol==_0x384190(0x17b)&&_0x3ea73b[_0x384190(0x18e)]===Symbol&&_0x3ea73b!==Symbol[_0x384190(0x151)]?'symbol':typeof _0x3ea73b;},_0x34cf4b(_0x40ece7);}function _0x31f4c8(_0x20278e,_0x251109){var _0x39732e=_0x1465ed;if(_0x34cf4b(_0x20278e)!='object'||!_0x20278e)return _0x20278e;var _0xd0b4f=_0x20278e[Symbol[_0x39732e(0x149)]];if(_0xd0b4f!==void 0x0){var _0x463306=_0xd0b4f[_0x39732e(0x18d)](_0x20278e,_0x251109||_0x39732e(0x128));if(_0x34cf4b(_0x463306)!=_0x39732e(0x172))return _0x463306;throw TypeError(_0x39732e(0x177));}return(_0x251109===_0x39732e(0x174)?String:Number)(_0x20278e);}function _0x31863d(_0x43bf1c){var _0x4255d5=_0x1465ed,_0x29487e=_0x31f4c8(_0x43bf1c,_0x4255d5(0x174));return _0x34cf4b(_0x29487e)=='symbol'?_0x29487e:_0x29487e+'';}function _0x703b4c(_0x5a5bb0,_0x4e1d5c,_0x38e434){var _0x480104=_0x1465ed;return(_0x4e1d5c=_0x31863d(_0x4e1d5c))in _0x5a5bb0?Object[_0x480104(0x157)](_0x5a5bb0,_0x4e1d5c,{'value':_0x38e434,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x5a5bb0[_0x4e1d5c]=_0x38e434,_0x5a5bb0;}var _0x1a1704=class extends _0x8f6320[_0x1465ed(0x16f)]{constructor(..._0x40abee){var _0x310a27=_0x1465ed;super(..._0x40abee),_0x703b4c(this,_0x310a27(0x186),void 0x0),_0x703b4c(this,_0x310a27(0x164),void 0x0),_0x703b4c(this,'_docsFormulaModel',void 0x0),_0x703b4c(this,'_docsFormulaResourceLoaderService',void 0x0);}[_0x1465ed(0x165)](_0x7650fb){var _0x122fa9=_0x1465ed;this[_0x122fa9(0x186)]=_0x7650fb[_0x122fa9(0x181)](_0x57386b[_0x122fa9(0x15d)]),this[_0x122fa9(0x164)]=_0x7650fb[_0x122fa9(0x181)](_0x3edadc['DocFormulaDisplayTextService']),this[_0x122fa9(0x175)]=_0x7650fb['get'](_0x3edadc[_0x122fa9(0x14f)]),this[_0x122fa9(0x18f)]=_0x7650fb[_0x122fa9(0x181)](_0x57386b[_0x122fa9(0x16e)]);}[_0x1465ed(0x170)](){var _0x2ce3a3=_0x1465ed;return this[_0x2ce3a3(0x146)]()['map'](_0x34bd55=>this[_0x2ce3a3(0x18c)](_0x34bd55[_0x2ce3a3(0x126)]));}['getFormula'](_0x19c961){var _0x12cbe7=_0x1465ed;return this[_0x12cbe7(0x146)]()[_0x12cbe7(0x183)](_0x45e298=>_0x45e298[_0x12cbe7(0x126)]===_0x19c961)?this[_0x12cbe7(0x18c)](_0x19c961):null;}[_0x1465ed(0x13f)](_0x499318){var _0x20a95c=_0x1465ed;let _0x21d50c=this['_getCompleteRanges']()[_0x20a95c(0x141)](_0x77e949=>_0x77e949[_0x20a95c(0x159)]<=_0x499318&&_0x499318<=_0x77e949[_0x20a95c(0x187)]);return _0x21d50c?this['_createFormula'](_0x21d50c[_0x20a95c(0x126)]):null;}[_0x1465ed(0x136)](){var _0x592abb=_0x1465ed;let _0x34919a=this[_0x592abb(0x18f)]['saveUnit'](this['id']);if(!_0x34919a)throw Error(_0x592abb(0x171)+this['id']+_0x592abb(0x142));return this['_docsFormulaDisplayTextService'][_0x592abb(0x13e)](_0x34919a);}[_0x1465ed(0x14b)](_0x5b85cc){var _0x403438=_0x1465ed;return this[_0x403438(0x13a)]({'externalReferences':_0x5b85cc['externalReferences'],'formula':_0x5b85cc[_0x403438(0x147)],'numberFormat':_0x5b85cc[_0x403438(0x16b)],'target':{'type':_0x403438(0x133),'startOffset':_0x5b85cc[_0x403438(0x16d)],'endOffset':_0x5b85cc[_0x403438(0x15b)]},'unitId':this[_0x403438(0x14e)]()});}['_insert'](_0x187f0a){var _0x507d8f=_0x1465ed;let _0x257574=this[_0x507d8f(0x186)][_0x507d8f(0x148)](_0x3edadc['InsertDocFormulaCommand']['id'],_0x187f0a);return _0x257574?this['_createFormula'](_0x257574[_0x507d8f(0x126)]):null;}[_0x1465ed(0x146)](){var _0x502539=_0x1465ed,_0x47c649;let _0x498064=this[_0x502539(0x175)]['getFormulas'](this[_0x502539(0x14e)]());return((_0x47c649=this[_0x502539(0x143)]('')[_0x502539(0x152)])==null?void 0x0:_0x47c649['filter'](_0x59d4af=>(0x0,_0x3edadc[_0x502539(0x153)])(_0x59d4af)&&_0x498064[_0x59d4af[_0x502539(0x126)]]!=null))??[];}[_0x1465ed(0x18c)](_0x332d5d){var _0x4c6807=_0x1465ed;return this[_0x4c6807(0x15c)][_0x4c6807(0x12b)](_0x462310,this['getId'](),_0x332d5d);}};_0x8f6320[_0x1465ed(0x16f)]['extend'](_0x1a1704);var _0x3e4674=class extends _0x8f6320[_0x1465ed(0x144)]{constructor(..._0x705ae6){var _0x45c9c1=_0x1465ed;super(..._0x705ae6),_0x703b4c(this,_0x45c9c1(0x186),void 0x0);}[_0x1465ed(0x165)](_0x2c2ce2){var _0x474bd5=_0x1465ed;this[_0x474bd5(0x186)]=_0x2c2ce2[_0x474bd5(0x181)](_0x57386b[_0x474bd5(0x15d)]);}[_0x1465ed(0x14b)](_0x17956a,_0x1baa37,_0x6dd414={}){return this['_insert'](_0x17956a,_0x1baa37,_0x6dd414);}['appendFormula'](_0x54e361,_0x9d88c1={}){var _0xf9cb86=_0x1465ed;return this[_0xf9cb86(0x13a)](_0xf9cb86(0x12a),_0x54e361,_0x9d88c1);}[_0x1465ed(0x13a)](_0x4f20a1,_0x579af7,_0x4affea){var _0x2de05e=_0x1465ed;if(this[_0x2de05e(0x12f)]())return null;let _0x57283e={'externalReferences':_0x4affea[_0x2de05e(0x167)],'formula':_0x579af7,'numberFormat':_0x4affea['numberFormat'],'target':{'type':_0x2de05e(0x127),'paragraphId':this[_0x2de05e(0x14e)](),'position':_0x4f20a1},'unitId':this[_0x2de05e(0x17e)][_0x2de05e(0x14e)]()},_0x2514e9=this[_0x2de05e(0x186)][_0x2de05e(0x148)](_0x3edadc[_0x2de05e(0x179)]['id'],_0x57283e);return _0x2514e9?this[_0x2de05e(0x15c)]['createInstance'](_0x462310,this[_0x2de05e(0x17e)][_0x2de05e(0x14e)](),_0x2514e9[_0x2de05e(0x126)]):null;}};_0x8f6320[_0x1465ed(0x144)][_0x1465ed(0x166)](_0x3e4674);var _0x13bc49=class extends _0x8f6320[_0x1465ed(0x13b)]{constructor(..._0x2381e4){var _0x307217=_0x1465ed;super(..._0x2381e4),_0x703b4c(this,_0x307217(0x186),void 0x0);}[_0x1465ed(0x165)](_0x38c51e){var _0x8b859a=_0x1465ed;this['_docsFormulaCommandService']=_0x38c51e[_0x8b859a(0x181)](_0x57386b[_0x8b859a(0x15d)]);}['replaceWithFormula'](_0x27287e,_0x27cc61={}){var _0x35ef97=_0x1465ed;let {endOffset:_0x116efd,segmentId:_0x5915bc,startOffset:_0x4c0bdb}=this[_0x35ef97(0x135)]();return _0x5915bc?null:this[_0x35ef97(0x13a)](_0x4c0bdb,_0x116efd,_0x27287e,_0x27cc61);}[_0x1465ed(0x13a)](_0x3f933d,_0x2b5047,_0x22f66a,_0x5e0c9c){var _0x1f09e5=_0x1465ed;let _0x246000={'externalReferences':_0x5e0c9c[_0x1f09e5(0x167)],'formula':_0x22f66a,'numberFormat':_0x5e0c9c[_0x1f09e5(0x16b)],'target':{'type':_0x1f09e5(0x133),'startOffset':_0x3f933d,'endOffset':_0x2b5047},'unitId':this[_0x1f09e5(0x17e)][_0x1f09e5(0x14e)]()},_0x126bea=this[_0x1f09e5(0x186)]['syncExecuteCommand'](_0x3edadc['InsertDocFormulaCommand']['id'],_0x246000);return _0x126bea?this[_0x1f09e5(0x15c)][_0x1f09e5(0x12b)](_0x462310,this[_0x1f09e5(0x17e)][_0x1f09e5(0x14e)](),_0x126bea[_0x1f09e5(0x126)]):null;}};_0x8f6320[_0x1465ed(0x13b)][_0x1465ed(0x166)](_0x13bc49),Object[_0x1465ed(0x157)](_0x3c2de3,'FDocumentFormula',{'enumerable':!0x0,'get':function(){return _0x462310;}});}));
|