@univerjs-pro/docs-formula 1.5.0 → 1.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/facade.js +1 -1
- package/lib/cjs/index.js +1 -1
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/facade.js +1 -1
- package/lib/index.js +1 -1
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- package/package.json +8 -8
package/lib/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const _0x3a7f13=_0x53b8;(function(_0x9328e1,_0x131692){const _0x1e12e8=_0x53b8,_0x5c827a=_0x9328e1();while(!![]){try{const _0x31ada3=-parseInt(_0x1e12e8(0x187))/0x1*(-parseInt(_0x1e12e8(0x1c3))/0x2)+parseInt(_0x1e12e8(0x22d))/0x3+parseInt(_0x1e12e8(0x196))/0x4*(-parseInt(_0x1e12e8(0x1e3))/0x5)+parseInt(_0x1e12e8(0x1c8))/0x6*(-parseInt(_0x1e12e8(0x263))/0x7)+parseInt(_0x1e12e8(0x1f2))/0x8*(-parseInt(_0x1e12e8(0x26b))/0x9)+-parseInt(_0x1e12e8(0x24c))/0xa*(-parseInt(_0x1e12e8(0x19b))/0xb)+parseInt(_0x1e12e8(0x1b8))/0xc;if(_0x31ada3===_0x131692)break;else _0x5c827a['push'](_0x5c827a['shift']());}catch(_0x2dfca3){_0x5c827a['push'](_0x5c827a['shift']());}}}(_0x52b2,0x5549a));import{FormulaCacheEligibilityService as _0x13ac3a,FormulaLastValuePersistenceService as _0x416b1f,HostExternalReferenceModel as _0xceeb38,UniverProFormulaEnginePlugin as _0x513513,buildUpsertHostExternalReferenceMutations as _0x3b0f43,collectFormulaExternalReferenceQualifiers as _0x48d68a,getScalarFormulaResultCell as _0x3ee924,resolveFormulaResultPresentation as _0x12221e,resolveHostFormulaExternalReferences as _0x5d5293,toFormulaLastValue as _0x5a1b13}from'@univerjs-pro/engine-formula';import{CellValueType as _0x320583,CommandType as _0x16d163,CustomRangeType as _0x38abe7,DataStreamTreeTokenType as _0x3c59f5,DependentOn as _0x37da81,Disposable as _0x533030,ICommandService as _0x9a0954,IConfigService as _0x4226f8,IResourceManagerService as _0x164b3f,IUndoRedoService as _0x16e8d6,IUniverInstanceService as _0x2629d5,Inject as _0x5d6038,Injector as _0x2a8248,JSONX as _0x5e930b,Plugin as _0x26195d,TextX as _0x556769,Tools as _0x5a1e4f,UniverInstanceType as _0x4aa394,generateRandomId as _0x32ab18,getBodySliceForTextXAction as _0x282876,getCustomRangeInterval as _0x4f97d4,getParagraphContentStartOffset as _0x19d939,getRichTextEditPath as _0x410a7f,merge as _0x4e3800,shiftExclusiveRangeOnDelete as _0x422036,shiftExclusiveRangeOnInsert as _0x514d4f,shiftInclusiveRangeOnDelete as _0x433aa0,shiftInclusiveRangeOnInsert as _0x4b4cb7,touchDependencies as _0xddcf97}from'@univerjs/core';import{DOC_SELECTION_OPTION_PRESERVE_CARET as _0x5393de,DocSelectionManagerService as _0x3d26b2,DocTextResolverService as _0x2459b3,RichTextEditingMutation as _0xd26f03,UniverDocsPlugin as _0x46761e}from'@univerjs/docs';import{FormulaResultStatus as _0x2c8d51,LexerTreeBuilder as _0x9fae86,OtherFormulaBizType as _0x2b96ca,RegisterOtherFormulaService as _0x16b5f1}from'@univerjs/engine-formula';import{Subject as _0x52ee64}from'rxjs';import{UniverLicensePlugin as _0x3344bd}from'@univerjs-pro/license';const y=_0x3a7f13(0x232),je=_0x3a7f13(0x1b3),Me='';function b(){return{'formulas':{}};}function x(_0x468856){const _0x21a001=_0x3a7f13;return!_0x468856||typeof _0x468856!='object'||!(_0x21a001(0x264)in _0x468856)||!_0x468856['formulas']||typeof _0x468856[_0x21a001(0x264)]!='object'||Array['isArray'](_0x468856[_0x21a001(0x264)])?!0x1:Object[_0x21a001(0x249)](_0x468856[_0x21a001(0x264)])[_0x21a001(0x186)](([_0x5bc57c,_0x5bb470])=>_0x5bc57c[_0x21a001(0x218)]>0x0&&Ne(_0x5bb470));}function _0x53b8(_0x2201e4,_0x55d4b0){_0x2201e4=_0x2201e4-0x180;const _0x52b22e=_0x52b2();let _0x53b8d2=_0x52b22e[_0x2201e4];return _0x53b8d2;}function Ne(_0x3b9f52){const _0x1751a0=_0x3a7f13;return!_0x3b9f52||typeof _0x3b9f52!='object'||!S(_0x3b9f52,[_0x1751a0(0x24d),_0x1751a0(0x230),_0x1751a0(0x1ff)])||!('formula'in _0x3b9f52)||typeof _0x3b9f52['formula']!='string'||!_0x3b9f52[_0x1751a0(0x24d)]['trim']()||_0x1751a0(0x230)in _0x3b9f52&&_0x3b9f52['numberFormat']!=null&&(typeof _0x3b9f52['numberFormat']!='object'||!S(_0x3b9f52[_0x1751a0(0x230)],[_0x1751a0(0x229)])||!(_0x1751a0(0x229)in _0x3b9f52[_0x1751a0(0x230)])||typeof _0x3b9f52[_0x1751a0(0x230)][_0x1751a0(0x229)]!='string')?!0x1:!('lastValue'in _0x3b9f52)||_0x3b9f52[_0x1751a0(0x1ff)]==null||Pe(_0x3b9f52[_0x1751a0(0x1ff)]);}function Pe(_0x2df729){const _0x43ed20=_0x3a7f13;return!_0x2df729||typeof _0x2df729!=_0x43ed20(0x247)||!S(_0x2df729,['v','t',_0x43ed20(0x229)])||!('v'in _0x2df729)||_0x2df729['v']!==null&&typeof _0x2df729['v']!=_0x43ed20(0x25f)&&typeof _0x2df729['v']!='number'&&typeof _0x2df729['v']!=_0x43ed20(0x1a2)||'t'in _0x2df729&&_0x2df729['t']!=null&&!Fe(_0x2df729['t'])?!0x1:!(_0x43ed20(0x229)in _0x2df729)||_0x2df729[_0x43ed20(0x229)]==null||typeof _0x2df729[_0x43ed20(0x229)]==_0x43ed20(0x25f);}function S(_0x4f7174,_0x249d11){const _0x22d68f=_0x3a7f13;let _0x5076cd=new Set(_0x249d11);return Object[_0x22d68f(0x241)](_0x4f7174)['every'](_0x1b71e1=>_0x5076cd[_0x22d68f(0x260)](_0x1b71e1));}function Fe(_0x25cf79){const _0x3c817f=_0x3a7f13;return typeof _0x25cf79=='number'&&Object['values'](_0x320583)[_0x3c817f(0x21f)](_0x25cf79);}const Ie=new Set([_0x3c59f5[_0x3a7f13(0x1d5)],_0x3c59f5[_0x3a7f13(0x1dd)],_0x3c59f5[_0x3a7f13(0x22c)],_0x3c59f5[_0x3a7f13(0x1ec)],_0x3c59f5[_0x3a7f13(0x279)],_0x3c59f5[_0x3a7f13(0x246)],_0x3c59f5[_0x3a7f13(0x185)],_0x3c59f5[_0x3a7f13(0x1ba)],_0x3c59f5['COLUMN_START'],_0x3c59f5[_0x3a7f13(0x18b)],_0x3c59f5[_0x3a7f13(0x1bb)],_0x3c59f5[_0x3a7f13(0x1c2)],_0x3c59f5[_0x3a7f13(0x1fa)],_0x3c59f5['CUSTOM_BLOCK']]);var C=class extends Error{constructor(){super('Doc\x20Formula\x20range\x20cannot\x20cross\x20document\x20structure\x20boundaries');}};function Le(_0x3cff8b){const _0x178960=_0x3a7f13;var _0x4f1467,_0x3c367c;let _0x3ffeab=_0x5a1e4f[_0x178960(0x201)](_0x3cff8b[_0x178960(0x1c6)]),_0x2c9849=O(_0x3ffeab),{startOffset:_0x5842c4,endOffset:_0x2617a6}=We(_0x2c9849,_0x3cff8b[_0x178960(0x23e)],_0x3cff8b[_0x178960(0x21d)]);Ve(_0x2c9849,_0x5842c4,_0x2617a6);let _0x23bc8c=((_0x4f1467=_0x2c9849['customRanges'])==null?void 0x0:_0x4f1467['filter'](_0x31d1ca=>{const _0x3a3cb6=_0x178960;if(!w(_0x31d1ca))return!0x1;let _0x576375=_0x4f97d4(_0x31d1ca);return _0x576375[_0x3a3cb6(0x21d)]>_0x5842c4&&_0x576375[_0x3a3cb6(0x23e)]<_0x2617a6;})[_0x178960(0x266)](_0x1af40c=>_0x1af40c[_0x178960(0x23f)]))??[];qe(_0x2c9849,_0x5842c4,_0x2617a6,''),_0x2c9849[_0x178960(0x182)]=[...((_0x3c367c=_0x2c9849[_0x178960(0x182)])==null?void 0x0:_0x3c367c[_0x178960(0x280)](_0x2d4851=>!_0x23bc8c['includes'](_0x2d4851['rangeId'])&&_0x2d4851['rangeId']!==_0x3cff8b[_0x178960(0x23f)]))??[],He(_0x3cff8b[_0x178960(0x23f)],_0x5842c4)][_0x178960(0x20e)]((_0x26a2ab,_0x3d3052)=>_0x26a2ab['startIndex']-_0x3d3052[_0x178960(0x254)]);let _0x251d51=Ue(_0x3cff8b[_0x178960(0x1a5)]);return _0x23bc8c['forEach'](_0x52de0e=>{delete _0x251d51['formulas'][_0x52de0e];}),_0x251d51[_0x178960(0x264)][_0x3cff8b['rangeId']]=_0x5a1e4f['deepClone'](_0x3cff8b[_0x178960(0x270)]),{'nextDocumentData':_0x3ffeab,'nextResource':_0x251d51,'cursorOffset':_0x5842c4+0x1};}function Re(_0x9e9209){const _0x66310b=_0x3a7f13;var _0x2c6cd7,_0x5bf3d5;let _0x5d9611=_0x5a1e4f['deepClone'](_0x9e9209[_0x66310b(0x1c6)]),_0x5d175e=(_0x2c6cd7=O(_0x5d9611)['customRanges'])==null?void 0x0:_0x2c6cd7[_0x66310b(0x19d)](_0x5adfc2=>_0x5adfc2[_0x66310b(0x23f)]===_0x9e9209[_0x66310b(0x23f)]&&w(_0x5adfc2));if(!_0x5d175e||!((_0x5bf3d5=_0x9e9209[_0x66310b(0x1a5)])!=null&&_0x5bf3d5[_0x66310b(0x264)][_0x9e9209[_0x66310b(0x23f)]]))return null;let _0x3f9a1d=Ue(_0x9e9209['resource']);return _0x3f9a1d[_0x66310b(0x264)][_0x9e9209[_0x66310b(0x23f)]]=_0x5a1e4f[_0x66310b(0x201)](_0x9e9209[_0x66310b(0x270)]),{'nextDocumentData':_0x5d9611,'nextResource':_0x3f9a1d,'cursorOffset':_0x5d175e[_0x66310b(0x221)]+0x1};}function ze(_0x8008f9){const _0x5ab265=_0x3a7f13;let _0x5e6d1c=_0x5a1e4f[_0x5ab265(0x201)](_0x8008f9[_0x5ab265(0x1c6)]),_0x5a7e08=Je(_0x5e6d1c,_0x8008f9[_0x5ab265(0x23f)],_0x8008f9['text']??'');if(_0x5a7e08==null)return null;let _0x2f32cc=Ue(_0x8008f9[_0x5ab265(0x1a5)]);return delete _0x2f32cc['formulas'][_0x8008f9[_0x5ab265(0x23f)]],{'nextDocumentData':_0x5e6d1c,'nextResource':_0x2f32cc,'cursorOffset':_0x5a7e08};}function Be(_0x112710,_0x28abb6){const _0x447d65=_0x3a7f13;var _0x3ef21c;let _0x5dfc4a=_0x5a1e4f[_0x447d65(0x201)](_0x112710),_0x4268a4=_0x5dfc4a[_0x447d65(0x1b4)];if(!_0x4268a4)return _0x5dfc4a;let _0x134355=new Map(_0x28abb6[_0x447d65(0x266)](_0x40f755=>[_0x40f755['rangeId'],_0x40f755[_0x447d65(0x192)]])),_0x171177=((_0x3ef21c=_0x4268a4[_0x447d65(0x182)])==null?void 0x0:_0x3ef21c[_0x447d65(0x280)](_0x4445a2=>w(_0x4445a2)&&_0x134355[_0x447d65(0x260)](_0x4445a2['rangeId']))[_0x447d65(0x20e)]((_0x26c3ff,_0x219773)=>_0x219773[_0x447d65(0x254)]-_0x26c3ff['startIndex']))??[];for(let _0x229a8a of _0x171177)Je(_0x5dfc4a,_0x229a8a[_0x447d65(0x23f)],_0x134355[_0x447d65(0x1b1)](_0x229a8a[_0x447d65(0x23f)])??'');return _0x5dfc4a;}function w(_0x3fc54e){const _0x4d30ae=_0x3a7f13;var _0x394916;return(_0x3fc54e==null?void 0x0:_0x3fc54e[_0x4d30ae(0x213)])===_0x38abe7[_0x4d30ae(0x1cc)]&&_0x3fc54e[_0x4d30ae(0x20d)]===!0x0&&((_0x394916=_0x3fc54e[_0x4d30ae(0x1a0)])==null?void 0x0:_0x394916['kind'])===_0x4d30ae(0x1b3);}function T(_0x2361f6,_0x5a3446){const _0x328429=_0x3a7f13;var _0x5e8934;return _0x2361f6==null||(_0x5e8934=_0x2361f6[_0x328429(0x182)])==null?void 0x0:_0x5e8934[_0x328429(0x19d)](_0x552181=>_0x552181[_0x328429(0x23f)]===_0x5a3446&&w(_0x552181));}function Ve(_0x3dcf85,_0x315322,_0x1cc193){const _0x1a283c=_0x3a7f13;if(_0x315322===_0x1cc193){if(Ie[_0x1a283c(0x260)](_0x3dcf85['dataStream'][_0x315322]))throw new C();}else{for(let _0x2e763c=_0x315322;_0x2e763c<_0x1cc193;_0x2e763c++)if(_0x3dcf85[_0x1a283c(0x1f4)][_0x2e763c]===_0x3c59f5[_0x1a283c(0x18c)]||Ie[_0x1a283c(0x260)](_0x3dcf85['dataStream'][_0x2e763c]))throw new C();}}function He(_0x5c2062,_0xe42fc7){return{'startIndex':_0xe42fc7,'endIndex':_0xe42fc7,'rangeId':_0x5c2062,'rangeType':_0x38abe7['CUSTOM'],'wholeEntity':!0x0,'properties':{'kind':je}};}function Ue(_0x37ebe4){const _0x53b378=_0x3a7f13;return _0x37ebe4?_0x5a1e4f[_0x53b378(0x201)](_0x37ebe4):b();}function We(_0x19cd40,_0xe0eefd,_0x5bd9f9){const _0xcc8a8a=_0x3a7f13;let _0x17ca85=Ke(_0x19cd40),_0xd8f963=_0xe0eefd??_0x17ca85,_0x17ee48=_0x5bd9f9??_0xd8f963;return{'startOffset':Ge(Math[_0xcc8a8a(0x211)](_0xd8f963,_0x17ee48),_0x17ca85),'endOffset':Ge(Math[_0xcc8a8a(0x222)](_0xd8f963,_0x17ee48),_0x17ca85)};}function Ge(_0x375055,_0x4718fa){const _0x31e305=_0x3a7f13;return Math[_0x31e305(0x222)](0x0,Math[_0x31e305(0x211)](_0x375055,_0x4718fa));}function Ke(_0xed0bce){const _0x1abdcc=_0x3a7f13;return _0xed0bce['dataStream'][_0x1abdcc(0x27a)](''+_0x3c59f5[_0x1abdcc(0x18c)]+_0x3c59f5[_0x1abdcc(0x1d5)])?Math['max'](0x0,_0xed0bce[_0x1abdcc(0x1f4)]['length']-0x2):_0xed0bce[_0x1abdcc(0x1f4)][_0x1abdcc(0x27a)](_0x3c59f5[_0x1abdcc(0x1d5)])?Math[_0x1abdcc(0x222)](0x0,_0xed0bce[_0x1abdcc(0x1f4)][_0x1abdcc(0x218)]-0x1):_0xed0bce['dataStream'][_0x1abdcc(0x218)];}function qe(_0x5cc2e5,_0x5271f2,_0x101cf0,_0x5079dc){_0x101cf0>_0x5271f2&&Xe(_0x5cc2e5,_0x5271f2,_0x101cf0),Ye(_0x5cc2e5,_0x5271f2,_0x5079dc);}function Je(_0x2694db,_0x20623e,_0x20552e){const _0x49e854=_0x3a7f13;var _0x37d030,_0x5a301e;let _0x519733=O(_0x2694db),_0x2d86a1=(_0x37d030=_0x519733[_0x49e854(0x182)])==null?void 0x0:_0x37d030[_0x49e854(0x19d)](_0x3c66de=>_0x3c66de[_0x49e854(0x23f)]===_0x20623e&&w(_0x3c66de));if(!_0x2d86a1)return null;let _0x124735=_0x4f97d4(_0x2d86a1);return qe(_0x519733,_0x124735[_0x49e854(0x23e)],_0x124735[_0x49e854(0x21d)],_0x20552e),_0x519733[_0x49e854(0x182)]=(_0x5a301e=_0x519733[_0x49e854(0x182)])==null?void 0x0:_0x5a301e[_0x49e854(0x280)](_0x93718f=>_0x93718f[_0x49e854(0x23f)]!==_0x20623e),_0x124735['startOffset']+_0x20552e[_0x49e854(0x218)];}function Ye(_0x215332,_0x1f4b18,_0x1ddf31){const _0x26c1d5=_0x3a7f13;_0x1ddf31&&(_0x215332[_0x26c1d5(0x1f4)]=''+_0x215332[_0x26c1d5(0x1f4)][_0x26c1d5(0x1f7)](0x0,_0x1f4b18)+_0x1ddf31+_0x215332[_0x26c1d5(0x1f4)][_0x26c1d5(0x1f7)](_0x1f4b18),Ze(_0x215332,_0x1f4b18,_0x1ddf31[_0x26c1d5(0x218)]));}function Xe(_0x23d4ee,_0x314c40,_0xff27ca){const _0x5216d9=_0x3a7f13;let _0x5ca488=_0xff27ca-_0x314c40;_0x23d4ee[_0x5216d9(0x1f4)]=''+_0x23d4ee[_0x5216d9(0x1f4)]['slice'](0x0,_0x314c40)+_0x23d4ee[_0x5216d9(0x1f4)][_0x5216d9(0x1f7)](_0xff27ca),Qe(_0x23d4ee,_0x314c40,_0x5ca488);}function Ze(_0x494cea,_0x2a682d,_0x1fff30){const _0x5a88d3=_0x3a7f13;_0x494cea[_0x5a88d3(0x23b)]=$e(_0x494cea[_0x5a88d3(0x23b)],_0x2a682d,_0x1fff30),_0x494cea[_0x5a88d3(0x188)]=$e(_0x494cea[_0x5a88d3(0x188)],_0x2a682d,_0x1fff30),_0x494cea[_0x5a88d3(0x281)]=$e(_0x494cea[_0x5a88d3(0x281)],_0x2a682d,_0x1fff30),_0x494cea['textRuns']=tt(_0x494cea[_0x5a88d3(0x267)],_0x2a682d,_0x1fff30),_0x494cea['tables']=nt(_0x494cea['tables'],_0x2a682d,_0x1fff30),_0x494cea[_0x5a88d3(0x1fb)]=E(_0x494cea[_0x5a88d3(0x1fb)],_0x2a682d,_0x1fff30),_0x494cea[_0x5a88d3(0x182)]=E(_0x494cea[_0x5a88d3(0x182)],_0x2a682d,_0x1fff30),_0x494cea['customDecorations']=E(_0x494cea[_0x5a88d3(0x21c)],_0x2a682d,_0x1fff30),_0x494cea['blockRanges']=E(_0x494cea['blockRanges'],_0x2a682d,_0x1fff30);}function Qe(_0x1c32c3,_0x4c0acc,_0x533786){const _0x4eee09=_0x3a7f13;var _0x2413c7,_0x39b461;_0x1c32c3[_0x4eee09(0x23b)]=et(_0x1c32c3['paragraphs'],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x188)]=et(_0x1c32c3[_0x4eee09(0x188)],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x281)]=et(_0x1c32c3[_0x4eee09(0x281)],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x267)]=(_0x2413c7=rt((_0x39b461=_0x1c32c3[_0x4eee09(0x267)])==null?void 0x0:_0x39b461[_0x4eee09(0x266)](_0x167081=>({..._0x167081,'startIndex':_0x167081['st'],'endIndex':_0x167081['ed']})),_0x4c0acc,_0x533786))==null?void 0x0:_0x2413c7[_0x4eee09(0x266)](_0x36fa90=>{let {startIndex:_0x150cbe,endIndex:_0x5c92c7,..._0x535f04}=_0x36fa90;return{..._0x535f04,'st':_0x150cbe,'ed':_0x5c92c7};}),_0x1c32c3[_0x4eee09(0x243)]=rt(_0x1c32c3[_0x4eee09(0x243)],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x1fb)]=D(_0x1c32c3[_0x4eee09(0x1fb)],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x182)]=D(_0x1c32c3[_0x4eee09(0x182)],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x21c)]=D(_0x1c32c3[_0x4eee09(0x21c)],_0x4c0acc,_0x533786),_0x1c32c3[_0x4eee09(0x1e4)]=D(_0x1c32c3[_0x4eee09(0x1e4)],_0x4c0acc,_0x533786);}function $e(_0xf83adb,_0x110626,_0x593862){const _0xb96096=_0x3a7f13;return _0xf83adb==null?void 0x0:_0xf83adb[_0xb96096(0x266)](_0x3bc5ce=>_0x3bc5ce[_0xb96096(0x254)]>=_0x110626?{..._0x3bc5ce,'startIndex':_0x3bc5ce[_0xb96096(0x254)]+_0x593862}:_0x3bc5ce);}function et(_0x45acd5,_0x39370c,_0x152a8f){const _0x156842=_0x3a7f13;let _0x49ec48=_0x39370c+_0x152a8f;return _0x45acd5==null?void 0x0:_0x45acd5['map'](_0x18e184=>_0x18e184['startIndex']>=_0x39370c&&_0x18e184[_0x156842(0x254)]<_0x49ec48?null:_0x18e184['startIndex']>=_0x49ec48?{..._0x18e184,'startIndex':_0x18e184[_0x156842(0x254)]-_0x152a8f}:_0x18e184)[_0x156842(0x280)](_0x3f34eb=>_0x3f34eb!=null);}function tt(_0x43e6c0,_0x5831a6,_0x55b2f1){const _0x5876cc=_0x3a7f13;return _0x43e6c0==null?void 0x0:_0x43e6c0[_0x5876cc(0x266)](_0x120e3b=>_0x120e3b['st']>=_0x5831a6?{..._0x120e3b,'st':_0x120e3b['st']+_0x55b2f1,'ed':_0x120e3b['ed']+_0x55b2f1}:_0x120e3b['ed']>_0x5831a6?{..._0x120e3b,'ed':_0x120e3b['ed']+_0x55b2f1}:_0x120e3b);}function E(_0x175ab9,_0x5c4fbd,_0x26c0f2){const _0x99762b=_0x3a7f13;return _0x175ab9==null?void 0x0:_0x175ab9[_0x99762b(0x266)](_0x4a7d94=>_0x4b4cb7(_0x4a7d94,_0x5c4fbd,_0x26c0f2));}function nt(_0x24643c,_0x398c06,_0x1728e8){const _0x42ed0a=_0x3a7f13;return _0x24643c==null?void 0x0:_0x24643c[_0x42ed0a(0x266)](_0x4956e1=>_0x514d4f(_0x4956e1,_0x398c06,_0x1728e8));}function D(_0x4d60be,_0x5ae3f2,_0x4bbc37){const _0x457a57=_0x3a7f13;return _0x4d60be==null?void 0x0:_0x4d60be[_0x457a57(0x266)](_0x547e2b=>_0x433aa0(_0x547e2b,_0x5ae3f2,_0x4bbc37))[_0x457a57(0x280)](_0x5e4d29=>_0x5e4d29!=null);}function rt(_0x21f9ba,_0x2322e7,_0x14a817){return _0x21f9ba==null?void 0x0:_0x21f9ba['map'](_0x21536f=>_0x422036(_0x21536f,_0x2322e7,_0x14a817))['filter'](_0x542859=>_0x542859!=null);}function O(_0x1059ad){const _0x20addd=_0x3a7f13;if(!_0x1059ad['body'])throw Error(_0x20addd(0x1f9));return _0x1059ad['body'];}function k(_0x1fbdd5){'@babel/helpers - typeof';const _0x337872=_0x3a7f13;return k=typeof Symbol==_0x337872(0x271)&&typeof Symbol['iterator']=='symbol'?function(_0x372c70){return typeof _0x372c70;}:function(_0x36bf6a){const _0x500d43=_0x337872;return _0x36bf6a&&typeof Symbol==_0x500d43(0x271)&&_0x36bf6a[_0x500d43(0x23c)]===Symbol&&_0x36bf6a!==Symbol['prototype']?'symbol':typeof _0x36bf6a;},k(_0x1fbdd5);}function it(_0x5e1b3c,_0x12ec0e){const _0x1cb036=_0x3a7f13;if(k(_0x5e1b3c)!=_0x1cb036(0x247)||!_0x5e1b3c)return _0x5e1b3c;var _0x1fec30;if(typeof Symbol<'u'&&(_0x1fec30=_0x5e1b3c[Symbol[_0x1cb036(0x18e)]])!==void 0x0){var _0x7cfe0a=_0x1fec30['call'](_0x5e1b3c,_0x12ec0e||_0x1cb036(0x1f1));if(k(_0x7cfe0a)!=_0x1cb036(0x247))return _0x7cfe0a;throw TypeError('@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.');}return(_0x12ec0e===_0x1cb036(0x25f)?String:Number)(_0x5e1b3c);}function at(_0x1862cb){const _0x3125bb=_0x3a7f13;var _0x59373b=it(_0x1862cb,'string');return k(_0x59373b)==_0x3125bb(0x1fd)?_0x59373b:_0x59373b+'';}function A(_0x563bcb,_0x1e8ede,_0x280132){const _0x1cc6d6=_0x3a7f13;return(_0x1e8ede=at(_0x1e8ede))in _0x563bcb?Object[_0x1cc6d6(0x24f)](_0x563bcb,_0x1e8ede,{'value':_0x280132,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x563bcb[_0x1e8ede]=_0x280132,_0x563bcb;}var j=class extends _0x533030{constructor(..._0x10f52f){const _0x34b0c3=_0x3a7f13;super(..._0x10f52f),A(this,_0x34b0c3(0x1e8),new Map()),A(this,_0x34b0c3(0x216),new Map()),A(this,_0x34b0c3(0x235),new Map()),A(this,'_change$',new _0x52ee64()),A(this,_0x34b0c3(0x282),this[_0x34b0c3(0x245)][_0x34b0c3(0x200)]());}[_0x3a7f13(0x238)](_0x389a59,_0x4d0067){const _0x431714=_0x3a7f13;var _0x31c8ac;let _0x319ab7=(_0x31c8ac=this['_resources']['get'](_0x389a59))==null?void 0x0:_0x31c8ac['formulas'][_0x4d0067];return _0x319ab7?_0x5a1e4f[_0x431714(0x201)](_0x319ab7):void 0x0;}[_0x3a7f13(0x1c5)](_0x24562c){const _0x2ab601=_0x3a7f13;var _0x5114a3;return _0x5a1e4f[_0x2ab601(0x201)](((_0x5114a3=this[_0x2ab601(0x1e8)][_0x2ab601(0x1b1)](_0x24562c))==null?void 0x0:_0x5114a3['formulas'])??{});}[_0x3a7f13(0x239)](_0x2e6aff){const _0x1491e0=_0x3a7f13;let _0x372fd5=this[_0x1491e0(0x1e8)][_0x1491e0(0x1b1)](_0x2e6aff);return _0x372fd5?_0x5a1e4f[_0x1491e0(0x201)](_0x372fd5):void 0x0;}[_0x3a7f13(0x209)](_0x14dd5a,_0x133fef,_0x4f28fb){const _0x398aaa=_0x3a7f13;return this[_0x398aaa(0x1cf)](_0x14dd5a,{[_0x133fef]:_0x4f28fb});}[_0x3a7f13(0x226)](_0x6bf61e,_0x276d51){const _0x29f65a=_0x3a7f13;return this[_0x29f65a(0x235)]['has'](_0x6bf61e)||!x(_0x276d51)?!0x1:(this[_0x29f65a(0x1e8)][_0x29f65a(0x22f)](_0x6bf61e,{'formulas':_0x5a1e4f[_0x29f65a(0x201)](_0x276d51[_0x29f65a(0x264)])}),this[_0x29f65a(0x245)][_0x29f65a(0x27f)]({'unitId':_0x6bf61e}),!0x0);}[_0x3a7f13(0x1cf)](_0x5551fa,_0x1fbb64){const _0x34225b=_0x3a7f13;if(this['_loadErrors'][_0x34225b(0x260)](_0x5551fa)||!Object[_0x34225b(0x241)](_0x1fbb64)[_0x34225b(0x218)]||!x({'formulas':_0x1fbb64}))return!0x1;let _0x159bf1=this[_0x34225b(0x1e8)][_0x34225b(0x1b1)](_0x5551fa)??b(),_0x17bae8=_0x5a1e4f[_0x34225b(0x201)](_0x159bf1);return Object[_0x34225b(0x1da)](_0x17bae8['formulas'],_0x5a1e4f['deepClone'](_0x1fbb64)),this['_resources'][_0x34225b(0x22f)](_0x5551fa,_0x17bae8),this['_change$'][_0x34225b(0x27f)]({'unitId':_0x5551fa,'rangeIds':Object['keys'](_0x1fbb64)}),!0x0;}[_0x3a7f13(0x1f0)](_0xdb9045,_0x238171){const _0x423364=_0x3a7f13;if(this[_0x423364(0x235)]['has'](_0xdb9045))return!0x1;let _0x2f6dc9=this['_resources'][_0x423364(0x1b1)](_0xdb9045);if(!(_0x2f6dc9!=null&&_0x2f6dc9[_0x423364(0x264)][_0x238171]))return!0x1;let _0x260950=_0x5a1e4f[_0x423364(0x201)](_0x2f6dc9);return delete _0x260950[_0x423364(0x264)][_0x238171],this[_0x423364(0x1e8)]['set'](_0xdb9045,_0x260950),this[_0x423364(0x245)][_0x423364(0x27f)]({'unitId':_0xdb9045,'rangeIds':[_0x238171]}),!0x0;}[_0x3a7f13(0x283)](_0x559ebc,_0x1faafb){const _0x6bc25a=_0x3a7f13;return x(_0x1faafb)?(this[_0x6bc25a(0x1e8)][_0x6bc25a(0x22f)](_0x559ebc,{'formulas':_0x5a1e4f[_0x6bc25a(0x201)](_0x1faafb[_0x6bc25a(0x264)])}),this[_0x6bc25a(0x216)][_0x6bc25a(0x25c)](_0x559ebc),this['_loadErrors']['delete'](_0x559ebc),this[_0x6bc25a(0x245)]['next']({'unitId':_0x559ebc}),!0x0):(this['_preserveInvalid'](_0x559ebc,_0x1faafb,_0x6bc25a(0x223)),!0x1);}[_0x3a7f13(0x27e)](_0x213760){const _0x4ffc23=_0x3a7f13;let _0x1792e7=this[_0x4ffc23(0x1e8)]['get'](_0x213760);return _0x1792e7?_0x5a1e4f[_0x4ffc23(0x201)](_0x1792e7):this[_0x4ffc23(0x216)][_0x4ffc23(0x260)](_0x213760)?_0x5a1e4f[_0x4ffc23(0x201)](this[_0x4ffc23(0x216)][_0x4ffc23(0x1b1)](_0x213760)):b();}[_0x3a7f13(0x251)](_0x7f0ce7){const _0x58b5dd=_0x3a7f13;return this['_loadErrors'][_0x58b5dd(0x1b1)](_0x7f0ce7);}['removeUnit'](_0xeba3c8){const _0xce816a=_0x3a7f13;this[_0xce816a(0x1e8)]['delete'](_0xeba3c8),this[_0xce816a(0x216)][_0xce816a(0x25c)](_0xeba3c8),this[_0xce816a(0x235)][_0xce816a(0x25c)](_0xeba3c8),this[_0xce816a(0x245)][_0xce816a(0x27f)]({'unitId':_0xeba3c8});}['dispose'](){const _0x4ccb4d=_0x3a7f13;this['_resources'][_0x4ccb4d(0x220)](),this[_0x4ccb4d(0x216)]['clear'](),this['_loadErrors']['clear'](),this['_change$']['complete'](),super['dispose']();}[_0x3a7f13(0x1e2)](_0x3806d9,_0x11a1e0,_0x702353){const _0x38318c=_0x3a7f13;this[_0x38318c(0x1e8)][_0x38318c(0x25c)](_0x3806d9),this['_rawResources']['set'](_0x3806d9,_0x5a1e4f[_0x38318c(0x201)](_0x11a1e0)),this[_0x38318c(0x235)][_0x38318c(0x22f)](_0x3806d9,_0x702353),this[_0x38318c(0x245)]['next']({'unitId':_0x3806d9});}};let ot=function(_0x1fd8bb){const _0xee6cd8=_0x3a7f13;return _0x1fd8bb[_0xee6cd8(0x1dc)]=_0xee6cd8(0x269),_0x1fd8bb[_0xee6cd8(0x219)]=_0xee6cd8(0x203),_0x1fd8bb[_0xee6cd8(0x1c1)]=_0xee6cd8(0x1f3),_0x1fd8bb['ERROR']=_0xee6cd8(0x227),_0x1fd8bb;}({});function M(_0x4ca6b7,_0x5b1915){return function(_0x1ccec8,_0x148296){_0x5b1915(_0x1ccec8,_0x148296,_0x4ca6b7);};}function N(_0x1596fb,_0x5f0660,_0x3fbf81,_0x2901f2){const _0x31b3bb=_0x3a7f13;var _0x5a10cb=arguments[_0x31b3bb(0x218)],_0x1a8278=_0x5a10cb<0x3?_0x5f0660:_0x2901f2===null?_0x2901f2=Object['getOwnPropertyDescriptor'](_0x5f0660,_0x3fbf81):_0x2901f2,_0x315626;if(typeof Reflect==_0x31b3bb(0x247)&&typeof Reflect[_0x31b3bb(0x252)]==_0x31b3bb(0x271))_0x1a8278=Reflect[_0x31b3bb(0x252)](_0x1596fb,_0x5f0660,_0x3fbf81,_0x2901f2);else{for(var _0x43c37c=_0x1596fb[_0x31b3bb(0x218)]-0x1;_0x43c37c>=0x0;_0x43c37c--)(_0x315626=_0x1596fb[_0x43c37c])&&(_0x1a8278=(_0x5a10cb<0x3?_0x315626(_0x1a8278):_0x5a10cb>0x3?_0x315626(_0x5f0660,_0x3fbf81,_0x1a8278):_0x315626(_0x5f0660,_0x3fbf81))||_0x1a8278);}return _0x5a10cb>0x3&&_0x1a8278&&Object['defineProperty'](_0x5f0660,_0x3fbf81,_0x1a8278),_0x1a8278;}let P=class extends _0x533030{constructor(_0x1c3223,_0x19aa41,_0x39ad8c){const _0x4ae415=_0x3a7f13;super(),this['_model']=_0x1c3223,this[_0x4ae415(0x25d)]=_0x19aa41,this[_0x4ae415(0x199)]=_0x39ad8c,A(this,_0x4ae415(0x1d8),new Map()),A(this,'_formulaKeys',new Map()),A(this,_0x4ae415(0x1c0),new _0x52ee64()),A(this,_0x4ae415(0x197),this['_presentationChanged$'][_0x4ae415(0x200)]()),this[_0x4ae415(0x25a)](this[_0x4ae415(0x25d)]['formulaResult$'][_0x4ae415(0x1b0)](_0x59a15d=>{const _0x49c3e8=_0x4ae415;for(let _0x14c843 of Object['values'](_0x59a15d))for(let _0x412c7e of Object['values'](_0x14c843))_0x412c7e['forEach'](_0x589992=>this[_0x49c3e8(0x1e5)](_0x589992));}));}[_0x3a7f13(0x184)](_0x47c11f){const _0x10006c=_0x3a7f13;var _0x56ccfc;let _0x5b6070=_0x47c11f['getUnitId'](),_0x19f1f7=((_0x56ccfc=_0x47c11f[_0x10006c(0x1d2)]()['body'])==null||(_0x56ccfc=_0x56ccfc['customRanges'])==null?void 0x0:_0x56ccfc['filter'](w))??[],_0x2fdb00=this[_0x10006c(0x1f8)]['getFormulas'](_0x5b6070),_0x1331e6=new Set();for(let _0x213788 of _0x19f1f7){let _0x421708=_0x2fdb00[_0x213788[_0x10006c(0x23f)]];_0x421708&&(_0x1331e6[_0x10006c(0x1e0)](F(_0x5b6070,_0x213788[_0x10006c(0x23f)])),this['register']({'unitId':_0x5b6070,'rangeId':_0x213788['rangeId']},_0x421708));}for(let _0xf60416 of Array['from'](this['_registrations'][_0x10006c(0x1ea)]()))_0xf60416[_0x10006c(0x206)]===_0x5b6070&&!_0x1331e6[_0x10006c(0x260)](F(_0xf60416[_0x10006c(0x206)],_0xf60416[_0x10006c(0x23f)]))&&this['unregister'](_0xf60416);}['register'](_0x1a3460,_0x3d52f6){const _0x16bb10=_0x3a7f13;let _0x52e69b=F(_0x1a3460['unitId'],_0x1a3460[_0x16bb10(0x23f)]),_0x23e986=this['_registrations']['get'](_0x52e69b),_0x5f58c3=this['_hostExternalReferenceModel'][_0x16bb10(0x210)](_0x1a3460['unitId']);if(_0x23e986&&_0x23e986[_0x16bb10(0x270)][_0x16bb10(0x24d)]===_0x3d52f6[_0x16bb10(0x24d)]&&_0x23e986[_0x16bb10(0x1e7)]===_0x5f58c3){_0x23e986['config']=_0x3d52f6;let _0x41b795=_0x23e986[_0x16bb10(0x274)]?this[_0x16bb10(0x25d)][_0x16bb10(0x208)](_0x23e986['unitId'],_0x23e986['unitId'],_0x23e986[_0x16bb10(0x274)])??void 0x0:void 0x0;_0x23e986[_0x16bb10(0x1a3)]=_0x41b795,this[_0x16bb10(0x214)](_0x52e69b,st(_0x3d52f6,_0x41b795));return;}_0x23e986!=null&&_0x23e986[_0x16bb10(0x274)]&&this['_deleteRegistration'](_0x23e986);let _0x254961={..._0x1a3460,'config':_0x3d52f6,'referenceRevision':_0x5f58c3,'presentation':st(_0x3d52f6,void 0x0)};if(this[_0x16bb10(0x1d8)][_0x16bb10(0x22f)](_0x52e69b,_0x254961),!_0x3d52f6['formula'][_0x16bb10(0x1d7)]())return;let _0xb6d969=this['_registrationService'][_0x16bb10(0x26f)](_0x1a3460[_0x16bb10(0x206)],_0x1a3460[_0x16bb10(0x206)],_0x3d52f6['formula'],void 0x0,{'rangeId':_0x1a3460['rangeId']},_0x2b96ca[_0x16bb10(0x193)],_0x1a3460['rangeId']);_0x254961['formulaId']=_0xb6d969,this[_0x16bb10(0x27c)][_0x16bb10(0x22f)](_0xb6d969,_0x52e69b);}[_0x3a7f13(0x26a)](_0x4fadaf){const _0x5ad03a=_0x3a7f13;let _0x4413a0=F(_0x4fadaf[_0x5ad03a(0x206)],_0x4fadaf['rangeId']),_0x1b99d2=this[_0x5ad03a(0x1d8)]['get'](_0x4413a0);_0x1b99d2&&(this['_deleteRegistration'](_0x1b99d2),this['_registrations'][_0x5ad03a(0x25c)](_0x4413a0));}[_0x3a7f13(0x231)](_0x82cc37){const _0x2f037f=_0x3a7f13;for(let _0x1fe814 of Array[_0x2f037f(0x1d0)](this['_registrations'][_0x2f037f(0x1ea)]()))_0x1fe814[_0x2f037f(0x206)]===_0x82cc37&&this[_0x2f037f(0x26a)](_0x1fe814);}[_0x3a7f13(0x1df)](_0xbf4167){const _0x4c8692=_0x3a7f13;var _0x3e1ff7;return(_0x3e1ff7=this[_0x4c8692(0x1d8)]['get'](F(_0xbf4167[_0x4c8692(0x206)],_0xbf4167[_0x4c8692(0x23f)])))==null?void 0x0:_0x3e1ff7[_0x4c8692(0x225)];}[_0x3a7f13(0x244)](_0x595b1f){const _0x31d06e=_0x3a7f13;let _0x2a4b4b=this[_0x31d06e(0x1d8)][_0x31d06e(0x1b1)](F(_0x595b1f[_0x31d06e(0x206)],_0x595b1f[_0x31d06e(0x23f)]));return _0x2a4b4b?I(_0x2a4b4b):void 0x0;}[_0x3a7f13(0x255)](){const _0x1f8ed2=_0x3a7f13;return Array[_0x1f8ed2(0x1d0)](this[_0x1f8ed2(0x1d8)][_0x1f8ed2(0x1ea)](),_0x4e837e=>({'identity':{'unitId':_0x4e837e[_0x1f8ed2(0x206)],'rangeId':_0x4e837e[_0x1f8ed2(0x23f)]},'config':_0x4e837e[_0x1f8ed2(0x270)],'referenceRevision':_0x4e837e[_0x1f8ed2(0x1e7)],..._0x4e837e[_0x1f8ed2(0x1a3)]?{'liveResult':_0x4e837e[_0x1f8ed2(0x1a3)]}:null}));}[_0x3a7f13(0x1eb)](){const _0x109a97=_0x3a7f13;for(let _0x1d5f72 of this[_0x109a97(0x1d8)][_0x109a97(0x1ea)]())this[_0x109a97(0x261)](_0x1d5f72);this[_0x109a97(0x1d8)][_0x109a97(0x220)](),this[_0x109a97(0x27c)][_0x109a97(0x220)](),this[_0x109a97(0x1c0)][_0x109a97(0x19f)](),super[_0x109a97(0x1eb)]();}[_0x3a7f13(0x1e5)](_0x10f5ce){const _0x412a05=_0x3a7f13;let _0x5d6f3c=this['_formulaKeys'][_0x412a05(0x1b1)](_0x10f5ce[_0x412a05(0x274)]),_0x80fa5b=_0x5d6f3c?this[_0x412a05(0x1d8)][_0x412a05(0x1b1)](_0x5d6f3c):void 0x0;_0x5d6f3c&&_0x80fa5b&&(_0x80fa5b[_0x412a05(0x1a3)]=_0x10f5ce,this['_setPresentation'](_0x5d6f3c,st(_0x80fa5b[_0x412a05(0x270)],_0x10f5ce)));}[_0x3a7f13(0x214)](_0x3b1900,_0x2cc545){const _0x40dcd5=_0x3a7f13;var _0x33de5f,_0x20a68a;let _0x5c6da4=this[_0x40dcd5(0x1d8)][_0x40dcd5(0x1b1)](_0x3b1900);if(!_0x5c6da4||ct(_0x5c6da4['presentation'],_0x2cc545))return;let _0x160b0f=_0x5c6da4[_0x40dcd5(0x225)],_0x2b2520=I(_0x5c6da4);_0x5c6da4['presentation']=_0x2cc545,this[_0x40dcd5(0x1c0)][_0x40dcd5(0x27f)]({'unitId':_0x5c6da4[_0x40dcd5(0x206)],'rangeId':_0x5c6da4['rangeId'],'presentation':_0x2cc545,'previousPresentation':_0x160b0f,'result':I(_0x5c6da4),'previousResult':{..._0x2b2520,..._0x160b0f,'value':(_0x33de5f=_0x160b0f[_0x40dcd5(0x276)])==null?void 0x0:_0x33de5f['v'],'valueType':((_0x20a68a=_0x160b0f['cell'])==null?void 0x0:_0x20a68a['t'])??void 0x0}});}[_0x3a7f13(0x261)](_0xb7799e){const _0x7851e8=_0x3a7f13;_0xb7799e[_0x7851e8(0x274)]&&(this[_0x7851e8(0x25d)][_0x7851e8(0x248)](_0xb7799e['unitId'],_0xb7799e[_0x7851e8(0x206)],[_0xb7799e['formulaId']]),this[_0x7851e8(0x27c)][_0x7851e8(0x25c)](_0xb7799e[_0x7851e8(0x274)]));}};P=N([M(0x0,_0x5d6038(j)),M(0x1,_0x5d6038(_0x16b5f1)),M(0x2,_0x5d6038(_0xceeb38))],P);function F(_0x3bb3c6,_0x2e77eb){return _0x3bb3c6+'\x00'+_0x2e77eb;}function st(_0x5b4328,_0x321f1d){const _0x1fadda=_0x3a7f13;return _0x12221e({'numberFormat':_0x5b4328[_0x1fadda(0x230)],'lastValue':_0x5b4328[_0x1fadda(0x1ff)],'result':_0x321f1d});}function I(_0x244496){const _0x1cc26a=_0x3a7f13;var _0x110964,_0x344aae,_0x1c2e37;let _0x274407=_0x244496[_0x1cc26a(0x225)],_0x3a544e=_0x244496[_0x1cc26a(0x270)]['formula'][_0x1cc26a(0x1d7)]()?_0x274407['stale']||_0x274407[_0x1cc26a(0x276)]==null?_0x1cc26a(0x203):((_0x110964=_0x244496[_0x1cc26a(0x1a3)])==null?void 0x0:_0x110964['status'])===_0x2c8d51[_0x1cc26a(0x1b2)]?'error':_0x1cc26a(0x1f3):'empty';return{..._0x274407,'status':_0x3a544e,'value':(_0x344aae=_0x274407['cell'])==null?void 0x0:_0x344aae['v'],'valueType':((_0x1c2e37=_0x274407['cell'])==null?void 0x0:_0x1c2e37['t'])??void 0x0};}function ct(_0x43daef,_0x43594d){const _0x302905=_0x3a7f13;var _0x55679b,_0x30c3c9,_0x170459,_0x562ddd;return _0x43daef[_0x302905(0x192)]===_0x43594d[_0x302905(0x192)]&&_0x43daef[_0x302905(0x1b5)]===_0x43594d['color']&&_0x43daef[_0x302905(0x229)]===_0x43594d[_0x302905(0x229)]&&_0x43daef[_0x302905(0x224)]===_0x43594d['source']&&_0x43daef[_0x302905(0x19c)]===_0x43594d[_0x302905(0x19c)]&&((_0x55679b=_0x43daef['cell'])==null?void 0x0:_0x55679b['t'])===((_0x30c3c9=_0x43594d[_0x302905(0x276)])==null?void 0x0:_0x30c3c9['t'])&&Object['is']((_0x170459=_0x43daef[_0x302905(0x276)])==null?void 0x0:_0x170459['v'],(_0x562ddd=_0x43594d[_0x302905(0x276)])==null?void 0x0:_0x562ddd['v']);}const lt={'id':'docs-formula.mutation.set-formula','type':_0x16d163['MUTATION'],'handler':(_0x2ca9f2,_0x2e209d)=>!(_0x2e209d!=null&&_0x2e209d[_0x3a7f13(0x206)])||!_0x2e209d['rangeId']||!_0x2e209d[_0x3a7f13(0x270)]?!0x1:_0x2ca9f2[_0x3a7f13(0x1b1)](j)[_0x3a7f13(0x209)](_0x2e209d[_0x3a7f13(0x206)],_0x2e209d[_0x3a7f13(0x23f)],_0x2e209d['config'])},ut={'id':_0x3a7f13(0x259),'type':_0x16d163[_0x3a7f13(0x1a9)],'handler':(_0x5d840b,_0x3d969e)=>!(_0x3d969e!=null&&_0x3d969e['unitId'])||!_0x3d969e[_0x3a7f13(0x23f)]?!0x1:_0x5d840b[_0x3a7f13(0x1b1)](j)['removeFormula'](_0x3d969e[_0x3a7f13(0x206)],_0x3d969e[_0x3a7f13(0x23f)])},L={'id':_0x3a7f13(0x23a),'type':_0x16d163[_0x3a7f13(0x1a9)],'handler':(_0x61cf5a,_0x195145)=>!(_0x195145!=null&&_0x195145[_0x3a7f13(0x206)])||!_0x195145[_0x3a7f13(0x1a5)]?!0x1:_0x61cf5a['get'](j)[_0x3a7f13(0x226)](_0x195145[_0x3a7f13(0x206)],_0x195145[_0x3a7f13(0x1a5)])},R={'id':_0x3a7f13(0x1bc),'type':_0x16d163[_0x3a7f13(0x1a9)],'handler':(_0x39cf48,_0x53e433)=>{const _0x384ae3=_0x3a7f13;if(!(_0x53e433!=null&&_0x53e433[_0x384ae3(0x206)])||!_0x53e433[_0x384ae3(0x1a1)][_0x384ae3(0x218)])return!0x1;let _0x116d59=_0x39cf48[_0x384ae3(0x1b1)](j),_0x364837=_0x39cf48[_0x384ae3(0x1b1)](_0xceeb38),_0x1567cd=_0x116d59[_0x384ae3(0x239)](_0x53e433[_0x384ae3(0x206)]);if(!_0x1567cd)return!0x1;let _0x42f6d9=_0x5a1e4f[_0x384ae3(0x201)](_0x1567cd),_0x3a806c=!0x1;for(let _0x43365e of _0x53e433[_0x384ae3(0x1a1)]){var _0x290f58,_0x4904e1,_0x52f376,_0x248539;let _0x5bf630=_0x42f6d9[_0x384ae3(0x264)][_0x43365e['rangeId']];_0x5bf630&&_0x5bf630[_0x384ae3(0x24d)]===_0x43365e[_0x384ae3(0x25e)]&&((_0x290f58=_0x5bf630[_0x384ae3(0x230)])==null?void 0x0:_0x290f58[_0x384ae3(0x229)])===_0x43365e[_0x384ae3(0x265)]&&_0x364837[_0x384ae3(0x210)](_0x53e433[_0x384ae3(0x206)])===_0x43365e['expectedReferenceRevision']&&(((_0x4904e1=_0x5bf630[_0x384ae3(0x1ff)])==null?void 0x0:_0x4904e1['v'])!==_0x43365e['lastValue']['v']||((_0x52f376=_0x5bf630[_0x384ae3(0x1ff)])==null?void 0x0:_0x52f376['t'])!==_0x43365e[_0x384ae3(0x1ff)]['t']||((_0x248539=_0x5bf630[_0x384ae3(0x1ff)])==null?void 0x0:_0x248539[_0x384ae3(0x229)])!==_0x43365e[_0x384ae3(0x1ff)][_0x384ae3(0x229)])&&(_0x5bf630[_0x384ae3(0x1ff)]=_0x5a1e4f[_0x384ae3(0x201)](_0x43365e[_0x384ae3(0x1ff)]),_0x3a806c=!0x0);}return!_0x3a806c||_0x116d59['setResource'](_0x53e433[_0x384ae3(0x206)],_0x42f6d9);}},z={'id':_0x3a7f13(0x1bd),'type':_0x16d163[_0x3a7f13(0x1c4)],'handler':(_0x28c526,_0x1ea680)=>{const _0x2d4ec7=_0x3a7f13;if(!(_0x1ea680!=null&&_0x1ea680[_0x2d4ec7(0x24d)][_0x2d4ec7(0x1d7)]()))return!0x1;let _0x45232e=K(_0x28c526,_0x1ea680[_0x2d4ec7(0x206)],'');if(!_0x45232e)return!0x1;let _0x42d844=ft(_0x1ea680[_0x2d4ec7(0x181)],_0x45232e[_0x2d4ec7(0x1b4)],dt(_0x28c526,_0x45232e[_0x2d4ec7(0x206)]));if(!_0x42d844)return!0x1;let _0x167a52=pt(_0x28c526,_0x45232e['unitId'],_0x1ea680['formula'],_0x1ea680[_0x2d4ec7(0x204)]??[]);if(!_0x167a52)return!0x1;let _0x3af86e=mt(_0x45232e[_0x2d4ec7(0x1b4)],_0x45232e['model'],_0x45232e['unitId']),_0x342ecc=ht({'documentData':_0x45232e[_0x2d4ec7(0x1c6)],'resource':_0x45232e[_0x2d4ec7(0x1a5)],'rangeId':_0x3af86e,'config':{'formula':_0x1ea680['formula'],..._0x1ea680[_0x2d4ec7(0x230)]?{'numberFormat':_0x1ea680[_0x2d4ec7(0x230)]}:null},'startOffset':_0x42d844[_0x2d4ec7(0x23e)],'endOffset':_0x42d844['endOffset']});if(!_0x342ecc)return!0x1;let _0x5a255e=_0x3b0f43(_0x28c526,_0x45232e[_0x2d4ec7(0x206)],_0x167a52);return!_0x5a255e||!q({'accessor':_0x28c526,'document':_0x45232e[_0x2d4ec7(0x272)],'unitId':_0x45232e[_0x2d4ec7(0x206)],'trigger':z['id'],'rangeId':_0x3af86e,'previousResource':_0x45232e['resource'],'nextResource':_0x342ecc[_0x2d4ec7(0x22e)],'previousDocumentData':_0x45232e['documentData'],'nextDocumentData':_0x342ecc[_0x2d4ec7(0x180)],'cursorOffset':_0x342ecc[_0x2d4ec7(0x1aa)],'externalMutations':_0x5a255e})?!0x1:{'rangeId':_0x3af86e,'startOffset':_0x342ecc[_0x2d4ec7(0x1aa)]-0x1,'endOffset':_0x342ecc['cursorOffset']};}},B={'id':_0x3a7f13(0x1b7),'type':_0x16d163[_0x3a7f13(0x1c4)],'handler':(_0x4e34cb,_0x5adb8c)=>{const _0x27d748=_0x3a7f13;if(!(_0x5adb8c!=null&&_0x5adb8c[_0x27d748(0x23f)])||!_0x5adb8c['formula'][_0x27d748(0x1d7)]())return!0x1;let _0x23cccd=K(_0x4e34cb,_0x5adb8c[_0x27d748(0x206)],''),_0x58a798=_0x23cccd==null?void 0x0:_0x23cccd[_0x27d748(0x194)]['getFormula'](_0x23cccd[_0x27d748(0x206)],_0x5adb8c['rangeId']),_0xf6b006=_0x23cccd?T(_0x23cccd[_0x27d748(0x1c6)][_0x27d748(0x1b4)],_0x5adb8c[_0x27d748(0x23f)]):void 0x0;if(!_0x23cccd||!_0x58a798||!_0xf6b006)return!0x1;let _0x4a70b4=pt(_0x4e34cb,_0x23cccd[_0x27d748(0x206)],_0x5adb8c[_0x27d748(0x24d)],_0x5adb8c[_0x27d748(0x204)]??[]);if(!_0x4a70b4)return!0x1;let _0x3a835c=_0x3b0f43(_0x4e34cb,_0x23cccd[_0x27d748(0x206)],_0x4a70b4);if(!_0x3a835c)return!0x1;let _0x367c04=St(_0x23cccd[_0x27d748(0x1a5)]);return _0x367c04[_0x27d748(0x264)][_0x5adb8c[_0x27d748(0x23f)]]={'formula':_0x5adb8c[_0x27d748(0x24d)],..._0x5adb8c[_0x27d748(0x230)]?{'numberFormat':_0x5adb8c['numberFormat']}:_0x58a798[_0x27d748(0x230)]?{'numberFormat':_0x58a798[_0x27d748(0x230)]}:null},q({'accessor':_0x4e34cb,'document':_0x23cccd['document'],'unitId':_0x23cccd[_0x27d748(0x206)],'trigger':B['id'],'rangeId':_0x5adb8c['rangeId'],'previousResource':_0x23cccd[_0x27d748(0x1a5)],'nextResource':_0x367c04,'cursorOffset':_0xf6b006[_0x27d748(0x221)]+0x1,'externalMutations':_0x3a835c});}},V={'id':_0x3a7f13(0x1e9),'type':_0x16d163[_0x3a7f13(0x1c4)],'handler':(_0x337305,_0xc63fe1)=>{const _0x1f1371=_0x3a7f13;if(!(_0xc63fe1!=null&&_0xc63fe1['rangeId']))return!0x1;let _0x1bf27d=K(_0x337305,_0xc63fe1[_0x1f1371(0x206)],''),_0x47f81d=_0x1bf27d==null?void 0x0:_0x1bf27d[_0x1f1371(0x194)][_0x1f1371(0x238)](_0x1bf27d[_0x1f1371(0x206)],_0xc63fe1['rangeId']),_0x227120=_0x1bf27d?T(_0x1bf27d[_0x1f1371(0x1c6)][_0x1f1371(0x1b4)],_0xc63fe1[_0x1f1371(0x23f)]):void 0x0;if(!_0x1bf27d||!_0x47f81d||!_0x227120)return!0x1;let _0x5bc900=St(_0x1bf27d['resource']);return _0x5bc900[_0x1f1371(0x264)][_0xc63fe1[_0x1f1371(0x23f)]]={..._0x47f81d,..._0xc63fe1['numberFormat']?{'numberFormat':_0xc63fe1[_0x1f1371(0x230)]}:null},_0xc63fe1[_0x1f1371(0x230)]||delete _0x5bc900[_0x1f1371(0x264)][_0xc63fe1['rangeId']][_0x1f1371(0x230)],q({'accessor':_0x337305,'document':_0x1bf27d[_0x1f1371(0x272)],'unitId':_0x1bf27d['unitId'],'trigger':V['id'],'rangeId':_0xc63fe1[_0x1f1371(0x23f)],'previousResource':_0x1bf27d['resource'],'nextResource':_0x5bc900,'cursorOffset':_0x227120['endIndex']+0x1,'externalMutations':{}});}},H={'id':_0x3a7f13(0x22a),'type':_0x16d163[_0x3a7f13(0x1c4)],'handler':(_0x2dda94,_0x8fbc3b)=>G(_0x2dda94,_0x8fbc3b,'',H['id'])},U={'id':_0x3a7f13(0x212),'type':_0x16d163['COMMAND'],'handler':(_0x258b86,_0x251b4d)=>G(_0x258b86,_0x251b4d,(_0x251b4d==null?void 0x0:_0x251b4d[_0x3a7f13(0x192)])??'',U['id'])},W={'id':'docs-formula.command.convert-to-text','type':_0x16d163[_0x3a7f13(0x1c4)],'handler':(_0x72e575,_0x4cacbd)=>{const _0x5cdc72=_0x3a7f13;if(!(_0x4cacbd!=null&&_0x4cacbd[_0x5cdc72(0x23f)]))return!0x1;let _0x5b76a1=K(_0x72e575,_0x4cacbd[_0x5cdc72(0x206)],'');if(!_0x5b76a1)return!0x1;let _0x4e8698=_0x72e575['get'](P)[_0x5cdc72(0x244)]({'unitId':_0x5b76a1[_0x5cdc72(0x206)],'rangeId':_0x4cacbd[_0x5cdc72(0x23f)]});return _0x4e8698?G(_0x72e575,_0x4cacbd,_0x4e8698[_0x5cdc72(0x192)],W['id']):!0x1;}};function G(_0x45b525,_0x17e3e2,_0x3696ad,_0x2b91a8){const _0x54c800=_0x3a7f13;if(!(_0x17e3e2!=null&&_0x17e3e2[_0x54c800(0x23f)]))return!0x1;let _0x17fee3=K(_0x45b525,_0x17e3e2['unitId'],'');if(!_0x17fee3)return!0x1;let _0x18ed3d=ze({'documentData':_0x17fee3[_0x54c800(0x1c6)],'resource':_0x17fee3[_0x54c800(0x1a5)],'rangeId':_0x17e3e2['rangeId'],'text':_0x3696ad});return _0x18ed3d?q({'accessor':_0x45b525,'document':_0x17fee3['document'],'unitId':_0x17fee3[_0x54c800(0x206)],'trigger':_0x2b91a8,'rangeId':_0x17e3e2[_0x54c800(0x23f)],'previousResource':_0x17fee3[_0x54c800(0x1a5)],'nextResource':_0x18ed3d['nextResource'],'previousDocumentData':_0x17fee3[_0x54c800(0x1c6)],'nextDocumentData':_0x18ed3d[_0x54c800(0x180)],'cursorOffset':_0x18ed3d['cursorOffset'],'externalMutations':{}}):!0x1;}function K(_0x28f982,_0x2afc0e,_0x431aae){const _0x2b2b92=_0x3a7f13;if(_0x431aae)return null;let _0xbc0da2=_0x28f982['get'](_0x2629d5),_0x3055ed=(_0x2afc0e?_0xbc0da2[_0x2b2b92(0x1cb)](_0x2afc0e,_0x4aa394['UNIVER_DOC']):_0xbc0da2[_0x2b2b92(0x268)](_0x4aa394['UNIVER_DOC']))??null;if(!_0x3055ed)return null;let _0x11e464=_0x3055ed[_0x2b2b92(0x1d2)](),_0xd5a113=_0x11e464[_0x2b2b92(0x1b4)];if(_0x11e464[_0x2b2b92(0x1ac)]||!_0xd5a113)return null;let _0x4ed736=_0x28f982[_0x2b2b92(0x1b1)](j);return _0x4ed736[_0x2b2b92(0x251)](_0x3055ed[_0x2b2b92(0x1e6)]())?null:{'document':_0x3055ed,'body':_0xd5a113,'documentData':_0x11e464,'model':_0x4ed736,'resource':_0x4ed736['getResource'](_0x3055ed[_0x2b2b92(0x1e6)]())??b(),'unitId':_0x3055ed[_0x2b2b92(0x1e6)]()};}function dt(_0x405bac,_0xc1fa0e){const _0x1f9151=_0x3a7f13;var _0x5d71d5;return(_0x5d71d5=_0x405bac['get'](_0x3d26b2)[_0x1f9151(0x22b)]({'subUnitId':_0xc1fa0e,'unitId':_0xc1fa0e}))==null?void 0x0:_0x5d71d5[0x0];}function ft(_0x4e8538,_0xdf932e,_0x4902b3){const _0x522e23=_0x3a7f13;if((_0x4e8538==null?void 0x0:_0x4e8538[_0x522e23(0x256)])===_0x522e23(0x1ce)){var _0x53c8e9;let _0xa68ad5=((_0x53c8e9=_0xdf932e['paragraphs'])==null?void 0x0:_0x53c8e9[_0x522e23(0x280)](_0x30def1=>_0x30def1[_0x522e23(0x236)]===_0x4e8538[_0x522e23(0x236)]))??[];if(_0xa68ad5['length']!==0x1)return null;let _0x85c1fe=_0xa68ad5[0x0],_0xfbba6f=_0x19d939(_0xdf932e,_0x85c1fe),_0xe74219=_0x85c1fe['startIndex']-_0xfbba6f,_0x4138b6=_0x4e8538[_0x522e23(0x1b6)]===_0x522e23(0x20f)?_0xe74219:_0x4e8538[_0x522e23(0x1b6)];if(!Number[_0x522e23(0x240)](_0x4138b6)||_0x4138b6<0x0||_0x4138b6>_0xe74219)return null;let _0x5617c1=_0xfbba6f+_0x4138b6;return{'startOffset':_0x5617c1,'endOffset':_0x5617c1};}if((_0x4e8538==null?void 0x0:_0x4e8538[_0x522e23(0x256)])===_0x522e23(0x18d))return!Number[_0x522e23(0x240)](_0x4e8538[_0x522e23(0x23e)])||!Number['isInteger'](_0x4e8538[_0x522e23(0x21d)])?null:{'startOffset':Math[_0x522e23(0x211)](_0x4e8538[_0x522e23(0x23e)],_0x4e8538[_0x522e23(0x21d)]),'endOffset':Math['max'](_0x4e8538['startOffset'],_0x4e8538['endOffset'])};let _0x4f17d3=(_0x4e8538==null?void 0x0:_0x4e8538[_0x522e23(0x256)])==='selection'?_0x4e8538[_0x522e23(0x21a)]:_0x4902b3;return!_0x4f17d3||_0x4f17d3[_0x522e23(0x1fe)]?null:{'startOffset':Math[_0x522e23(0x211)](_0x4f17d3[_0x522e23(0x23e)],_0x4f17d3[_0x522e23(0x21d)]),'endOffset':Math[_0x522e23(0x222)](_0x4f17d3[_0x522e23(0x23e)],_0x4f17d3[_0x522e23(0x21d)])};}function pt(_0x156d4f,_0x5300a4,_0x314260,_0x2ed2b4){const _0x1e44a3=_0x3a7f13;let _0x1a5a24=_0x156d4f[_0x1e44a3(0x1b1)](_0x9fae86),_0x531966=_0x314260['startsWith']('=')?_0x314260['slice'](0x1):_0x314260,_0x56d72a=_0x1a5a24[_0x1e44a3(0x205)](_0x531966);if(!_0x56d72a)return null;let _0x5a84ba=_0x156d4f[_0x1e44a3(0x1b1)](_0xceeb38),_0x2e6c7a=_0x5d5293({'qualifiers':_0x48d68a(_0x56d72a),'explicitReferences':_0x2ed2b4??[],'resolveBinding':_0x2bea7a=>_0x5a84ba[_0x1e44a3(0x278)](_0x5300a4,_0x2bea7a)});return _0x2e6c7a['status']===_0x1e44a3(0x26c)?_0x2e6c7a[_0x1e44a3(0x1a8)]:null;}function mt(_0x515a1f,_0x542e13,_0x3ea200){const _0x336295=_0x3a7f13;var _0x26ff3b;let _0x55c654=_0x32ab18(0x6);for(;_0x515a1f!=null&&(_0x26ff3b=_0x515a1f[_0x336295(0x182)])!=null&&_0x26ff3b[_0x336295(0x1ee)](_0x5d939d=>_0x5d939d[_0x336295(0x23f)]===_0x55c654)||_0x542e13[_0x336295(0x238)](_0x3ea200,_0x55c654);)_0x55c654=_0x32ab18(0x6);return _0x55c654;}function ht(_0x4564f1){try{return Le(_0x4564f1);}catch(_0x3db6eb){if(_0x3db6eb instanceof C)return null;throw _0x3db6eb;}}function gt(_0x117061){const _0x4eb578=_0x3a7f13;let _0x485311=_0x117061['previousDocumentData']&&_0x117061[_0x4eb578(0x180)]?vt(_0x117061['document'],_0x117061['unitId'],_0x117061['previousDocumentData'],_0x117061[_0x4eb578(0x180)],_0x117061['cursorOffset'],_0x117061['trigger']):null;return _0x117061[_0x4eb578(0x1a6)]&&_0x117061[_0x4eb578(0x180)]&&!_0x485311?null:{'documentRedo':_0x485311,'resourceRedo':{'id':L['id'],'params':{'unitId':_0x117061[_0x4eb578(0x206)],'resource':_0x117061[_0x4eb578(0x22e)]}},'resourceUndo':{'id':L['id'],'params':{'unitId':_0x117061[_0x4eb578(0x206)],'resource':_0x117061['previousResource']}}};}function _0x52b2(){const _0x30d63c=['params','SECTION_BREAK','push','trim','_registrations','degradeDocumentData','assign','getInstance','EMPTY','TABLE_START','registerPluginResource','getPresentation','add','_instanceService','_preserveInvalid','165ALWzCP','blockRanges','_updateFormulaResult','getUnitId','referenceRevision','_resources','docs-formula.command.set-number-format','values','dispose','TABLE_CELL_START','1.5.0','some','degradeBody','removeFormula','default','80FgbGBK','success','dataStream','forEach','registerProvider','slice','_model','Document\x20main\x20body\x20is\x20required\x20to\x20insert\x20Doc\x20Formula.','BLOCK_END','columnGroups','documentRedo','symbol','segmentId','lastValue','asObservable','deepClone','resources','pending','externalReferences','sequenceNodesBuilder','unitId','insertLength','getFormulaValueSync','setFormula','_commandService','trigger','identity','wholeEntity','sort','end','getRevision','min','docs-formula.command.replace-with-text','rangeType','_setPresentation','name','_rawResources','notifyTextChanged','length','PENDING','selection','resourceUndo','customDecorations','endOffset','unitDisposed$','includes','clear','endIndex','max','invalid-resource','source','presentation','setResource','error','_resourceManagerService','pattern','docs-formula.command.remove','getTextRanges','TABLE_ROW_START','563001LcmOIV','nextResource','set','numberFormat','unregisterUnit','DOC_FORMULA_PLUGIN','pluginName','resolveFormula','_loadErrors','paragraphId','@univerjs-pro/docs-formula','getFormula','getResource','docs-formula.mutation.set-resource','paragraphs','constructor','parse','startOffset','rangeId','isInteger','keys','externalMutations','tables','getResult','_change$','TABLE_ROW_END','object','deleteFormula','entries','_config','_queueSync','2837630TmjOji','formula','docs-formula.config','defineProperty','deleteLength','getLoadError','decorate','_syncUnit','startIndex','getRegisteredFormulas','type','_injector','_service','docs-formula.mutation.remove-formula','disposeWithMe','resourceRedo','delete','_registrationService','expectedFormula','string','has','_deleteRegistration','data','154kDYsyE','formulas','expectedNumberFormat','map','textRuns','getCurrentUnitOfType','empty','unregister','446031mfmjEB','resolved','_isDisposed','unitAdded$','registerFormulaWithRange','config','function','document','packageName','formulaId','_docFormulaModel','cell','setConfig','resolveBinding','TABLE_CELL_END','endsWith','stringify','_formulaKeys','_configService','serialize','next','filter','customBlocks','change$','load','nextDocumentData','target','customRanges','fromEntries','syncUnit','TABLE_END','every','370BUhnqR','sectionBreaks','version','getAllUnitsForType','COLUMN_END','PARAGRAPH','range','toPrimitive','start','UNIVER_DOC','accessor','text','DOC','model','register','72748ticsoS','presentationChanged$','getBody','_hostExternalReferenceModel','undoMutation','11XOCcEg','stale','find','insert','complete','properties','updates','boolean','liveResult','_formulaService','resource','previousDocumentData','_cacheEligibilityService','references','MUTATION','cursorOffset','redoMutation','disabled','registerCommand','syncExecuteCommand','pushUndoRedo','subscribe','get','ERROR','univer-docs-formula','body','color','position','docs-formula.command.update','6899604zhXAbo','onStarting','COLUMN_GROUP_START','COLUMN_GROUP_END','docs-formula.mutation.set-last-values','docs-formula.command.insert','_pendingUnitIds','editOp','_presentationChanged$','SUCCESS','BLOCK_START','3236nCsbXX','COMMAND','getFormulas','documentData','assess','54534fZstZX','resolveText','_univerInstanceService','getUnit','CUSTOM','collectMutations','paragraph','setFormulas','from','retain','getSnapshot','_syncScheduled'];_0x52b2=function(){return _0x30d63c;};return _0x52b2();}function _t(_0x431627,_0x30f6d3,_0x336e2f,_0x401707){const _0x894fcf=_0x3a7f13;_0x401707[_0x894fcf(0x1af)]({'id':_0x431627[_0x894fcf(0x20b)]+':'+_0x431627[_0x894fcf(0x23f)],'unitID':_0x431627['unitId'],'redoMutations':[..._0x431627[_0x894fcf(0x242)][_0x894fcf(0x1ab)]?[_0x431627[_0x894fcf(0x242)][_0x894fcf(0x1ab)]]:[],..._0x30f6d3[_0x894fcf(0x1fc)]?[_0x30f6d3[_0x894fcf(0x1fc)]]:[],_0x30f6d3[_0x894fcf(0x25b)]],'undoMutations':[_0x30f6d3['resourceUndo'],..._0x336e2f?[_0x336e2f]:[],..._0x431627[_0x894fcf(0x242)][_0x894fcf(0x19a)]?[_0x431627['externalMutations'][_0x894fcf(0x19a)]]:[]]});}function q(_0x3bd7cd){const _0x36aa96=_0x3a7f13;let _0x256ad9=_0x3bd7cd['accessor'][_0x36aa96(0x1b1)](_0x9a0954),_0x455749=_0x3bd7cd[_0x36aa96(0x191)]['get'](_0x16e8d6),_0x57df78=_0x3bd7cd['accessor'][_0x36aa96(0x1b1)](_0x3d26b2),_0x8c6220=gt(_0x3bd7cd);if(!_0x8c6220)return!0x1;let _0x5cf53f=!0x1,_0x5069f3=null,_0x59afb0=!0x1;try{if(_0x3bd7cd[_0x36aa96(0x242)][_0x36aa96(0x1ab)]){if(!_0x256ad9[_0x36aa96(0x1ae)](_0x3bd7cd['externalMutations'][_0x36aa96(0x1ab)]['id'],_0x3bd7cd[_0x36aa96(0x242)][_0x36aa96(0x1ab)][_0x36aa96(0x1d4)]))return!0x1;_0x5cf53f=!0x0;}if(_0x8c6220['documentRedo']){let _0x3bf014=_0x256ad9[_0x36aa96(0x1ae)](_0x8c6220[_0x36aa96(0x1fc)]['id'],_0x8c6220[_0x36aa96(0x1fc)][_0x36aa96(0x1d4)]);if(!_0x3bf014)return J(_0x256ad9,_0x3bd7cd[_0x36aa96(0x242)],_0x5cf53f),!0x1;_0x5069f3={'id':_0xd26f03['id'],'params':{..._0x3bf014,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'segmentId':''}};}if(!_0x256ad9['syncExecuteCommand'](_0x8c6220[_0x36aa96(0x25b)]['id'],_0x8c6220[_0x36aa96(0x25b)][_0x36aa96(0x1d4)]))return yt(_0x256ad9,_0x5069f3),J(_0x256ad9,_0x3bd7cd[_0x36aa96(0x242)],_0x5cf53f),!0x1;_0x59afb0=!0x0,_t(_0x3bd7cd,_0x8c6220,_0x5069f3,_0x455749);}catch(_0x39dd4b){throw _0x59afb0&&_0x256ad9[_0x36aa96(0x1ae)](_0x8c6220[_0x36aa96(0x21b)]['id'],_0x8c6220[_0x36aa96(0x21b)][_0x36aa96(0x1d4)]),yt(_0x256ad9,_0x5069f3),J(_0x256ad9,_0x3bd7cd[_0x36aa96(0x242)],_0x5cf53f),_0x39dd4b;}return _0x57df78['replaceDocRanges']([{'startOffset':_0x3bd7cd[_0x36aa96(0x1aa)],'endOffset':_0x3bd7cd[_0x36aa96(0x1aa)],'segmentId':''}],{'unitId':_0x3bd7cd[_0x36aa96(0x206)],'subUnitId':_0x3bd7cd[_0x36aa96(0x206)]},!0x1,{[_0x5393de]:!0x0}),!0x0;}function vt(_0x2ec114,_0x12cde7,_0x4ddc10,_0x18d255,_0x3c7af9,_0x196c3d){let _0x352fd4=bt(_0x4ddc10,_0x18d255,_0x410a7f(_0x2ec114,''));return _0x352fd4?{'id':_0xd26f03['id'],'params':{'unitId':_0x12cde7,'actions':_0x352fd4,'segmentId':'','textRanges':[{'startOffset':_0x3c7af9,'endOffset':_0x3c7af9,'collapsed':!0x0,'segmentId':''}],'isEditing':!0x1,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'trigger':_0x196c3d}}:null;}function yt(_0x1fe23f,_0x58b3e1){const _0x5451d2=_0x3a7f13;_0x58b3e1&&_0x1fe23f[_0x5451d2(0x1ae)](_0x58b3e1['id'],_0x58b3e1['params']);}function J(_0x4a41c5,_0x1d20a0,_0x1f9c7f){const _0x2542bb=_0x3a7f13;_0x1f9c7f&&_0x1d20a0[_0x2542bb(0x19a)]&&_0x4a41c5[_0x2542bb(0x1ae)](_0x1d20a0['undoMutation']['id'],_0x1d20a0['undoMutation'][_0x2542bb(0x1d4)]);}function bt(_0x4d0b83,_0x15197b,_0x22ccc4){const _0x13ebd3=_0x3a7f13;let _0x11e4ae=_0x4d0b83[_0x13ebd3(0x1b4)],_0xecd30b=_0x15197b[_0x13ebd3(0x1b4)],_0x42bc2a=xt(_0x11e4ae==null?void 0x0:_0x11e4ae['dataStream'],_0xecd30b==null?void 0x0:_0xecd30b[_0x13ebd3(0x1f4)]);if(!_0x42bc2a||!_0xecd30b)return null;let _0x177fcb=new _0x556769();return _0x177fcb[_0x13ebd3(0x1d1)](_0x42bc2a[_0x13ebd3(0x18f)]),_0x42bc2a[_0x13ebd3(0x207)]>0x0&&_0x177fcb[_0x13ebd3(0x19e)](_0x42bc2a[_0x13ebd3(0x207)],_0x282876(_0xecd30b,_0x42bc2a['start'],_0x42bc2a['start']+_0x42bc2a[_0x13ebd3(0x207)],!0x1)),_0x42bc2a['deleteLength']>0x0&&_0x177fcb[_0x13ebd3(0x25c)](_0x42bc2a[_0x13ebd3(0x250)]),_0x5e930b[_0x13ebd3(0x1db)]()[_0x13ebd3(0x1bf)](_0x177fcb[_0x13ebd3(0x27e)](),_0x22ccc4);}function xt(_0x329017,_0x11208b){const _0x51bfe4=_0x3a7f13;if(_0x329017==null||_0x11208b==null||_0x329017===_0x11208b)return null;let _0x34df1a=0x0;for(;_0x34df1a<_0x329017['length']&&_0x34df1a<_0x11208b[_0x51bfe4(0x218)]&&_0x329017[_0x34df1a]===_0x11208b[_0x34df1a];)_0x34df1a+=0x1;let _0x4b47b9=_0x329017[_0x51bfe4(0x218)],_0x1b1f56=_0x11208b[_0x51bfe4(0x218)];for(;_0x4b47b9>_0x34df1a&&_0x1b1f56>_0x34df1a&&_0x329017[_0x4b47b9-0x1]===_0x11208b[_0x1b1f56-0x1];)--_0x4b47b9,--_0x1b1f56;return{'start':_0x34df1a,'deleteLength':_0x4b47b9-_0x34df1a,'insertLength':_0x1b1f56-_0x34df1a};}function St(_0x1c4e9f){const _0x31d240=_0x3a7f13;return{'formulas':Object[_0x31d240(0x183)](Object[_0x31d240(0x249)](_0x1c4e9f[_0x31d240(0x264)])[_0x31d240(0x266)](([_0x3cf782,_0x2e71d6])=>[_0x3cf782,{..._0x2e71d6,..._0x2e71d6[_0x31d240(0x230)]?{'numberFormat':{..._0x2e71d6[_0x31d240(0x230)]}}:null,..._0x2e71d6[_0x31d240(0x1ff)]?{'lastValue':{..._0x2e71d6[_0x31d240(0x1ff)]}}:null}]))};}let Y=class extends _0x533030{constructor(_0x26bee7,_0x41c06f,_0x6f9606,_0x36d6af){const _0xcca16b=_0x3a7f13;super(),this[_0xcca16b(0x1e1)]=_0x26bee7,this[_0xcca16b(0x20a)]=_0x41c06f,this[_0xcca16b(0x1f8)]=_0x6f9606,this[_0xcca16b(0x258)]=_0x36d6af,A(this,_0xcca16b(0x1be),new Set()),A(this,_0xcca16b(0x1d3),!0x1),A(this,_0xcca16b(0x26d),!0x1),this['_instanceService'][_0xcca16b(0x18a)](_0x4aa394['UNIVER_DOC'])[_0xcca16b(0x1f5)](_0x5da29b=>this[_0xcca16b(0x258)][_0xcca16b(0x184)](_0x5da29b)),this['disposeWithMe'](this[_0xcca16b(0x1f8)][_0xcca16b(0x282)][_0xcca16b(0x1b0)](({unitId:_0x1c7c1a})=>this['_syncUnit'](_0x1c7c1a))),this['disposeWithMe'](this[_0xcca16b(0x1e1)][_0xcca16b(0x26e)][_0xcca16b(0x1b0)](({unit:_0x2c442a})=>{const _0xc8e41f=_0xcca16b;_0x2c442a[_0xc8e41f(0x256)]===_0x4aa394[_0xc8e41f(0x190)]&&this[_0xc8e41f(0x24b)](_0x2c442a[_0xc8e41f(0x1e6)]());})),this[_0xcca16b(0x25a)](this['_instanceService'][_0xcca16b(0x21e)][_0xcca16b(0x1b0)](_0x3e6f8a=>{const _0xa9cf35=_0xcca16b;this[_0xa9cf35(0x258)][_0xa9cf35(0x231)](_0x3e6f8a['getUnitId']());})),this[_0xcca16b(0x25a)](this[_0xcca16b(0x20a)]['onCommandExecuted'](_0x301cf4=>{const _0x4f3d0e=_0xcca16b;if(_0x301cf4['id']===_0xd26f03['id']&&Ct(_0x301cf4[_0x4f3d0e(0x1d4)])){let _0x570046=_0x301cf4['params'];_0x570046[_0x4f3d0e(0x1fe)]||this[_0x4f3d0e(0x253)](_0x570046[_0x4f3d0e(0x206)]);}}));}[_0x3a7f13(0x1eb)](){const _0x19f2b4=_0x3a7f13;this['_isDisposed']=!0x0,super[_0x19f2b4(0x1eb)]();}['_queueSync'](_0x17afe2){const _0x4620df=_0x3a7f13;this[_0x4620df(0x1be)][_0x4620df(0x1e0)](_0x17afe2),this['_syncScheduled']||(this[_0x4620df(0x1d3)]=!0x0,queueMicrotask(()=>{const _0x30007d=_0x4620df;if(this['_syncScheduled']=!0x1,this[_0x30007d(0x26d)])return;let _0x929ec8=Array[_0x30007d(0x1d0)](this['_pendingUnitIds']);this[_0x30007d(0x1be)][_0x30007d(0x220)](),_0x929ec8[_0x30007d(0x1f5)](_0x3687cb=>this[_0x30007d(0x253)](_0x3687cb));}));}[_0x3a7f13(0x253)](_0x3a9813){const _0x5c1636=_0x3a7f13;let _0x286405=this[_0x5c1636(0x1e1)][_0x5c1636(0x1cb)](_0x3a9813,_0x4aa394['UNIVER_DOC']);_0x286405&&this[_0x5c1636(0x258)][_0x5c1636(0x184)](_0x286405);}};Y=N([M(0x0,_0x2629d5),M(0x1,_0x9a0954),M(0x2,_0x5d6038(j)),M(0x3,_0x5d6038(P))],Y);function Ct(_0x4a9f91){const _0x3df4d5=_0x3a7f13;return typeof _0x4a9f91==_0x3df4d5(0x247)&&!!_0x4a9f91&&'unitId'in _0x4a9f91&&typeof _0x4a9f91[_0x3df4d5(0x206)]==_0x3df4d5(0x25f)&&(!(_0x3df4d5(0x1fe)in _0x4a9f91)||_0x4a9f91[_0x3df4d5(0x1fe)]===void 0x0||typeof _0x4a9f91[_0x3df4d5(0x1fe)]==_0x3df4d5(0x25f));}let X=class extends _0x533030{constructor(_0x1ad25e,_0x47c758){const _0x5924f3=_0x3a7f13;super(),this[_0x5924f3(0x228)]=_0x1ad25e,this[_0x5924f3(0x275)]=_0x47c758,this[_0x5924f3(0x25a)](this['_resourceManagerService'][_0x5924f3(0x1de)]({'pluginName':y,'businesses':[_0x4aa394['UNIVER_DOC']],'toJson':_0x11ce79=>JSON[_0x5924f3(0x27b)](this[_0x5924f3(0x275)][_0x5924f3(0x27e)](_0x11ce79)),'parseJson':_0x5e42cb=>JSON[_0x5924f3(0x23d)](_0x5e42cb),'onLoad':(_0x70f3d0,_0x58efcd)=>{const _0x40de33=_0x5924f3;this[_0x40de33(0x275)][_0x40de33(0x283)](_0x70f3d0,_0x58efcd);},'onUnLoad':_0x1fe4e8=>this[_0x5924f3(0x275)]['removeUnit'](_0x1fe4e8)}));}};X=N([M(0x0,_0x164b3f),M(0x1,_0x5d6038(j))],X);var wt=_0x3a7f13(0x237),Tt=_0x3a7f13(0x1ed);const Et={};let Z=class extends _0x533030{constructor(_0xd158c5,_0x266105,_0x20383e){const _0x43b0cf=_0x3a7f13;super(),this[_0x43b0cf(0x1ca)]=_0xd158c5,this[_0x43b0cf(0x1a4)]=_0x266105,this[_0x43b0cf(0x25a)](_0x20383e[_0x43b0cf(0x195)]({'resolve':(_0xacd81d,_0x1d5d9d)=>{const _0x5b2e18=_0x43b0cf;var _0x504e8c;return((_0x504e8c=_0x1d5d9d[_0x5b2e18(0x182)])==null?void 0x0:_0x504e8c[_0x5b2e18(0x280)](w)[_0x5b2e18(0x266)](_0x3f5902=>({'startOffset':_0x3f5902[_0x5b2e18(0x254)],'endOffset':_0x3f5902[_0x5b2e18(0x221)]+0x1,'text':this['resolveFormula'](_0xacd81d,_0x3f5902[_0x5b2e18(0x23f)])})))??[];}})),this[_0x43b0cf(0x25a)](this[_0x43b0cf(0x1a4)]['presentationChanged$'][_0x43b0cf(0x1b0)](({unitId:_0x46eac9})=>{const _0x5c55b9=_0x43b0cf;_0x20383e[_0x5c55b9(0x217)](_0x46eac9);}));}[_0x3a7f13(0x234)](_0x3b91ad,_0x8c6a1c){const _0xe57e5c=_0x3a7f13;var _0x474428;return((_0x474428=this['_formulaService'][_0xe57e5c(0x244)]({'unitId':_0x3b91ad,'rangeId':_0x8c6a1c}))==null?void 0x0:_0x474428[_0xe57e5c(0x192)])??'';}[_0x3a7f13(0x1c9)](_0x54cad1,_0x2c003f,_0x307e62){const _0xf2a59d=_0x3a7f13;var _0x231baa;let _0x241966=this[_0xf2a59d(0x1ca)][_0xf2a59d(0x1cb)](_0x54cad1,_0x4aa394[_0xf2a59d(0x190)]),_0x712023=_0x241966==null?void 0x0:_0x241966[_0xf2a59d(0x198)]();if(!_0x712023)return'';let _0x1576f4=_0x712023['dataStream'][_0xf2a59d(0x1f7)](_0x2c003f,_0x307e62),_0x38849c=((_0x231baa=_0x712023[_0xf2a59d(0x182)])==null?void 0x0:_0x231baa[_0xf2a59d(0x280)](_0x499359=>w(_0x499359)&&_0x499359[_0xf2a59d(0x254)]>=_0x2c003f&&_0x499359['endIndex']<_0x307e62)['sort']((_0x35cf0e,_0x3e7b35)=>_0x3e7b35['startIndex']-_0x35cf0e[_0xf2a59d(0x254)]))??[];for(let _0x4323d5 of _0x38849c){let _0x172811=_0x4323d5[_0xf2a59d(0x254)]-_0x2c003f,_0xf51724=_0x4323d5[_0xf2a59d(0x221)]-_0x2c003f+0x1;_0x1576f4=''+_0x1576f4[_0xf2a59d(0x1f7)](0x0,_0x172811)+this[_0xf2a59d(0x234)](_0x54cad1,_0x4323d5[_0xf2a59d(0x23f)])+_0x1576f4[_0xf2a59d(0x1f7)](_0xf51724);}return _0x1576f4;}[_0x3a7f13(0x1d9)](_0x4a1ebe){return Dt(_0x4a1ebe);}[_0x3a7f13(0x1ef)](_0x49eed3,_0x45e9dd,_0x634093={}){const _0x2a6d37=_0x3a7f13;var _0x4e27b1;return Be({'id':_0x49eed3,'body':_0x45e9dd,'documentStyle':{}},(((_0x4e27b1=_0x45e9dd[_0x2a6d37(0x182)])==null?void 0x0:_0x4e27b1[_0x2a6d37(0x280)](w))??[])['map'](_0x1a0977=>({'rangeId':_0x1a0977['rangeId'],'text':_0x634093[_0x1a0977['rangeId']]??this[_0x2a6d37(0x234)](_0x49eed3,_0x1a0977[_0x2a6d37(0x23f)])})))[_0x2a6d37(0x1b4)]??{'dataStream':''};}};Z=N([M(0x0,_0x2629d5),M(0x1,_0x5d6038(P)),M(0x2,_0x5d6038(_0x2459b3))],Z);function Dt(_0x426647){const _0x18efad=_0x3a7f13;var _0x4ee8a6,_0x3de727;let _0x2a7704=Ot(_0x426647),_0x19d859=Be(_0x426647,(((_0x4ee8a6=_0x426647[_0x18efad(0x1b4)])==null||(_0x4ee8a6=_0x4ee8a6[_0x18efad(0x182)])==null?void 0x0:_0x4ee8a6['filter'](w))??[])[_0x18efad(0x266)](_0x2cecf1=>({'rangeId':_0x2cecf1['rangeId'],'text':kt(_0x2a7704==null?void 0x0:_0x2a7704[_0x18efad(0x264)][_0x2cecf1[_0x18efad(0x23f)]])})));return _0x19d859[_0x18efad(0x202)]=(_0x3de727=_0x19d859[_0x18efad(0x202)])==null?void 0x0:_0x3de727[_0x18efad(0x280)](_0x4689d2=>_0x4689d2[_0x18efad(0x215)]!==y),_0x19d859;}function Ot(_0x5c2187){const _0x4a282b=_0x3a7f13;var _0x2734a3;let _0x322ed5=(_0x2734a3=_0x5c2187[_0x4a282b(0x202)])==null||(_0x2734a3=_0x2734a3[_0x4a282b(0x19d)](_0x4c22ff=>_0x4c22ff[_0x4a282b(0x215)]===_0x4a282b(0x232)))==null?void 0x0:_0x2734a3[_0x4a282b(0x262)];if(_0x322ed5)try{let _0x5da19e=JSON[_0x4a282b(0x23d)](_0x322ed5);return x(_0x5da19e)?_0x5da19e:void 0x0;}catch{return;}}function kt(_0x13f512){const _0xc3c338=_0x3a7f13;return _0x13f512?_0x12221e({'lastValue':_0x13f512['lastValue'],'numberFormat':_0x13f512[_0xc3c338(0x230)]})[_0xc3c338(0x192)]:'';}let Q=class extends _0x533030{constructor(_0x67af32,_0x1ce97c,_0x26a5a0){const _0x1776a3=_0x3a7f13;super(),this[_0x1776a3(0x1a4)]=_0x67af32,this['_cacheEligibilityService']=_0x1ce97c,this[_0x1776a3(0x25a)](_0x26a5a0[_0x1776a3(0x1f6)](this));}[_0x3a7f13(0x1cd)](_0x71c7a3){const _0x15fd12=_0x3a7f13;let _0x5d2570=new Map();for(let _0x2c6b50 of this[_0x15fd12(0x1a4)]['getRegisteredFormulas']()){var _0x47912c;if(!this[_0x15fd12(0x1a7)][_0x15fd12(0x1c7)](_0x2c6b50['config'][_0x15fd12(0x24d)],_0x2c6b50[_0x15fd12(0x1a3)])['eligible'])continue;let _0x30e212=_0x3ee924(_0x2c6b50[_0x15fd12(0x1a3)]),_0x49e9f1=_0x30e212?_0x5a1b13(_0x30e212):null;if(!_0x49e9f1||At(_0x2c6b50[_0x15fd12(0x270)][_0x15fd12(0x1ff)],_0x49e9f1))continue;let _0xdbfeb8=_0x5d2570['get'](_0x2c6b50[_0x15fd12(0x20c)][_0x15fd12(0x206)])??[];_0xdbfeb8[_0x15fd12(0x1d6)]({'rangeId':_0x2c6b50[_0x15fd12(0x20c)][_0x15fd12(0x23f)],'expectedFormula':_0x2c6b50['config'][_0x15fd12(0x24d)],'expectedNumberFormat':(_0x47912c=_0x2c6b50[_0x15fd12(0x270)][_0x15fd12(0x230)])==null?void 0x0:_0x47912c[_0x15fd12(0x229)],'expectedReferenceRevision':_0x2c6b50[_0x15fd12(0x1e7)],'lastValue':_0x49e9f1}),_0x5d2570[_0x15fd12(0x22f)](_0x2c6b50[_0x15fd12(0x20c)][_0x15fd12(0x206)],_0xdbfeb8);}return Array[_0x15fd12(0x1d0)](_0x5d2570,([_0x96eb3e,_0x24f314])=>({'id':R['id'],'params':{'unitId':_0x96eb3e,'updates':_0x24f314}}));}};Q=N([M(0x0,_0x5d6038(P)),M(0x1,_0x5d6038(_0x13ac3a)),M(0x2,_0x5d6038(_0x416b1f))],Q);function At(_0xf0585,_0x5d1307){const _0xa18be=_0x3a7f13;return(_0xf0585==null?void 0x0:_0xf0585['v'])===_0x5d1307['v']&&(_0xf0585==null?void 0x0:_0xf0585['t'])===_0x5d1307['t']&&(_0xf0585==null?void 0x0:_0xf0585['pattern'])===_0x5d1307[_0xa18be(0x229)];}let $=class extends _0x26195d{constructor(_0x4f157c=Et,_0x17dac8,_0x2d617f,_0x4fe1d9){const _0x31b2c5=_0x3a7f13;super(),this[_0x31b2c5(0x24a)]=_0x4f157c,this['_injector']=_0x17dac8,this['_commandService']=_0x2d617f,this['_configService']=_0x4fe1d9;let {..._0x43a95a}=_0x4e3800({},Et,this[_0x31b2c5(0x24a)]);this[_0x31b2c5(0x27d)][_0x31b2c5(0x277)](_0x31b2c5(0x24e),_0x43a95a);}[_0x3a7f13(0x1b9)](){const _0x5218fd=_0x3a7f13;this[_0x5218fd(0x257)][_0x5218fd(0x1e0)]([j]),this[_0x5218fd(0x257)][_0x5218fd(0x1e0)]([P]),this[_0x5218fd(0x257)][_0x5218fd(0x1e0)]([X]),this[_0x5218fd(0x257)]['add']([Y]),this[_0x5218fd(0x257)][_0x5218fd(0x1e0)]([Q]),this[_0x5218fd(0x257)][_0x5218fd(0x1e0)]([Z]),_0xddcf97(this[_0x5218fd(0x257)],[[j],[X],[Y],[Q],[Z]]),[lt,ut,L,R,z,B,V,H,U,W]['forEach'](_0x399fbb=>this[_0x5218fd(0x25a)](this[_0x5218fd(0x20a)][_0x5218fd(0x1ad)](_0x399fbb)));}};A($,_0x3a7f13(0x233),y),A($,_0x3a7f13(0x273),wt),A($,_0x3a7f13(0x189),Tt),A($,_0x3a7f13(0x256),_0x4aa394[_0x3a7f13(0x190)]),$=N([_0x37da81(_0x3344bd,_0x513513,_0x46761e),M(0x1,_0x5d6038(_0x2a8248)),M(0x2,_0x9a0954),M(0x3,_0x4226f8)],$);export{W as ConvertDocFormulaToTextCommand,je as DOC_FORMULA_CUSTOM_RANGE_KIND,Me as DOC_FORMULA_OBJECT_REPLACEMENT,y as DOC_FORMULA_PLUGIN,Z as DocFormulaDisplayTextService,Y as DocFormulaLifecycleController,j as DocFormulaModel,X as DocFormulaResourceController,ot as DocFormulaResultStatus,P as DocFormulaService,z as InsertDocFormulaCommand,C as InvalidDocFormulaInsertRangeError,H as RemoveDocFormulaCommand,ut as RemoveDocFormulaMutation,U as ReplaceDocFormulaWithTextCommand,R as SetDocFormulaLastValuesMutation,lt as SetDocFormulaMutation,V as SetDocFormulaNumberFormatCommand,L as SetDocFormulaResourceMutation,$ as UniverDocsFormulaPlugin,B as UpdateDocFormulaCommand,Ve as assertSafeDocFormulaInsertRange,Le as buildInsertDocFormulaActions,ze as buildRemoveDocFormulaActions,Re as buildUpdateDocFormulaActions,b as createEmptyDocFormulaResource,Dt as degradeDocFormulaDocumentData,T as findDocFormulaRange,Ne as isDocFormulaConfig,w as isDocFormulaRange,x as isDocFormulaResource,Pe as isFormulaLastValue};
|
|
1
|
+
const _0xb81d4c=_0x43e1;(function(_0x287216,_0x47b045){const _0xd3e7f0=_0x43e1,_0x557293=_0x287216();while(!![]){try{const _0x436cc8=parseInt(_0xd3e7f0(0x1ce))/0x1+parseInt(_0xd3e7f0(0x1d5))/0x2+-parseInt(_0xd3e7f0(0x1a4))/0x3*(-parseInt(_0xd3e7f0(0x17e))/0x4)+parseInt(_0xd3e7f0(0x1ee))/0x5+-parseInt(_0xd3e7f0(0x1b6))/0x6+parseInt(_0xd3e7f0(0x203))/0x7+parseInt(_0xd3e7f0(0x226))/0x8*(-parseInt(_0xd3e7f0(0x181))/0x9);if(_0x436cc8===_0x47b045)break;else _0x557293['push'](_0x557293['shift']());}catch(_0x3f6d10){_0x557293['push'](_0x557293['shift']());}}}(_0x3d4a,0x97885));import{FormulaCacheEligibilityService as _0x5bfff4,FormulaLastValuePersistenceService as _0x21c0ca,HostExternalReferenceModel as _0x2be22c,UniverProFormulaEnginePlugin as _0x3c9e4a,buildUpsertHostExternalReferenceMutations as _0x5f5499,collectFormulaExternalReferenceQualifiers as _0x1bd1bb,getScalarFormulaResultCell as _0xfa1663,resolveFormulaResultPresentation as _0x157ca0,resolveHostFormulaExternalReferences as _0x1fc472,toFormulaLastValue as _0x4884df}from'@univerjs-pro/engine-formula';import{CellValueType as _0x1d3a7a,CommandType as _0x599208,CustomRangeType as _0x4e4035,DataStreamTreeTokenType as _0x4bf61f,DependentOn as _0x415d13,Disposable as _0xf99196,ICommandService as _0x41ce44,IConfigService as _0x212f05,IResourceManagerService as _0x85b6e7,IUndoRedoService as _0x5273cf,IUniverInstanceService as _0x1616da,Inject as _0x3abf00,Injector as _0x38221f,JSONX as _0x5b1be5,Plugin as _0x4cfe43,TextX as _0x7ff3ce,Tools as _0x541130,UniverInstanceType as _0x19d9b2,generateRandomId as _0x5d3298,getBodySliceForTextXAction as _0x312eb6,getCustomRangeInterval as _0x128c46,getParagraphContentStartOffset as _0x13c716,getRichTextEditPath as _0x197963,merge as _0x57fe01,shiftExclusiveRangeOnDelete as _0x463586,shiftExclusiveRangeOnInsert as _0x190d1a,shiftInclusiveRangeOnDelete as _0x4ab3ac,shiftInclusiveRangeOnInsert as _0x21d172,touchDependencies as _0x59a954}from'@univerjs/core';import{DOC_SELECTION_OPTION_PRESERVE_CARET as _0x507f67,DocSelectionManagerService as _0x3e1e9b,DocTextResolverService as _0x5a38c7,RichTextEditingMutation as _0x3ff622,UniverDocsPlugin as _0x59ac81}from'@univerjs/docs';import{FormulaResultStatus as _0xd61d8b,LexerTreeBuilder as _0x276a14,OtherFormulaBizType as _0x5593a7,RegisterOtherFormulaService as _0x3b74c8}from'@univerjs/engine-formula';import{Subject as _0x45c46f}from'rxjs';import{UniverLicensePlugin as _0x46999f}from'@univerjs-pro/license';const y='DOC_FORMULA_PLUGIN',je='univer-docs-formula',Me='';function b(){return{'formulas':{}};}function x(_0x5b91c6){const _0x56550d=_0x43e1;return!_0x5b91c6||typeof _0x5b91c6!=_0x56550d(0x234)||!(_0x56550d(0x18d)in _0x5b91c6)||!_0x5b91c6[_0x56550d(0x18d)]||typeof _0x5b91c6[_0x56550d(0x18d)]!='object'||Array[_0x56550d(0x215)](_0x5b91c6[_0x56550d(0x18d)])?!0x1:Object[_0x56550d(0x18e)](_0x5b91c6['formulas'])['every'](([_0x32e913,_0x11d7ae])=>_0x32e913[_0x56550d(0x1f2)]>0x0&&Ne(_0x11d7ae));}function Ne(_0x270303){const _0xf52ab0=_0x43e1;return!_0x270303||typeof _0x270303!=_0xf52ab0(0x234)||!S(_0x270303,[_0xf52ab0(0x1f0),_0xf52ab0(0x19e),_0xf52ab0(0x1ed)])||!(_0xf52ab0(0x1f0)in _0x270303)||typeof _0x270303[_0xf52ab0(0x1f0)]!=_0xf52ab0(0x1fc)||!_0x270303['formula']['trim']()||_0xf52ab0(0x19e)in _0x270303&&_0x270303[_0xf52ab0(0x19e)]!=null&&(typeof _0x270303[_0xf52ab0(0x19e)]!=_0xf52ab0(0x234)||!S(_0x270303['numberFormat'],['pattern'])||!(_0xf52ab0(0x168)in _0x270303[_0xf52ab0(0x19e)])||typeof _0x270303['numberFormat'][_0xf52ab0(0x168)]!='string')?!0x1:!(_0xf52ab0(0x1ed)in _0x270303)||_0x270303[_0xf52ab0(0x1ed)]==null||Pe(_0x270303[_0xf52ab0(0x1ed)]);}function Pe(_0x182fd1){const _0x60b7aa=_0x43e1;return!_0x182fd1||typeof _0x182fd1!=_0x60b7aa(0x234)||!S(_0x182fd1,['v','t',_0x60b7aa(0x168)])||!('v'in _0x182fd1)||_0x182fd1['v']!==null&&typeof _0x182fd1['v']!=_0x60b7aa(0x1fc)&&typeof _0x182fd1['v']!=_0x60b7aa(0x1eb)&&typeof _0x182fd1['v']!=_0x60b7aa(0x1b0)||'t'in _0x182fd1&&_0x182fd1['t']!=null&&!Fe(_0x182fd1['t'])?!0x1:!(_0x60b7aa(0x168)in _0x182fd1)||_0x182fd1['pattern']==null||typeof _0x182fd1[_0x60b7aa(0x168)]=='string';}function S(_0x47a6b8,_0x42f8ba){const _0x4c2983=_0x43e1;let _0x580b3c=new Set(_0x42f8ba);return Object[_0x4c2983(0x1a6)](_0x47a6b8)[_0x4c2983(0x175)](_0x398190=>_0x580b3c[_0x4c2983(0x22f)](_0x398190));}function Fe(_0x1c887c){const _0x2d31dd=_0x43e1;return typeof _0x1c887c==_0x2d31dd(0x1eb)&&Object['values'](_0x1d3a7a)[_0x2d31dd(0x222)](_0x1c887c);}const Ie=new Set([_0x4bf61f['SECTION_BREAK'],_0x4bf61f[_0xb81d4c(0x216)],_0x4bf61f['TABLE_ROW_START'],_0x4bf61f[_0xb81d4c(0x19c)],_0x4bf61f[_0xb81d4c(0x1e9)],_0x4bf61f[_0xb81d4c(0x1ef)],_0x4bf61f[_0xb81d4c(0x238)],_0x4bf61f['COLUMN_GROUP_START'],_0x4bf61f[_0xb81d4c(0x1f4)],_0x4bf61f[_0xb81d4c(0x251)],_0x4bf61f[_0xb81d4c(0x1e1)],_0x4bf61f['BLOCK_START'],_0x4bf61f['BLOCK_END'],_0x4bf61f[_0xb81d4c(0x1b4)]]);var C=class extends Error{constructor(){const _0x3619f5=_0xb81d4c;super(_0x3619f5(0x209));}};function Le(_0x45ed8f){const _0x2ee9bc=_0xb81d4c;var _0x5788d1,_0x227bf7;let _0x2b2b46=_0x541130[_0x2ee9bc(0x211)](_0x45ed8f[_0x2ee9bc(0x1ba)]),_0x5d5f37=O(_0x2b2b46),{startOffset:_0x57ace2,endOffset:_0x3aaf2c}=We(_0x5d5f37,_0x45ed8f[_0x2ee9bc(0x1b9)],_0x45ed8f['endOffset']);Ve(_0x5d5f37,_0x57ace2,_0x3aaf2c);let _0x20aa1f=((_0x5788d1=_0x5d5f37[_0x2ee9bc(0x1c4)])==null?void 0x0:_0x5788d1['filter'](_0xd8bdcb=>{const _0x18863e=_0x2ee9bc;if(!w(_0xd8bdcb))return!0x1;let _0x8a560d=_0x128c46(_0xd8bdcb);return _0x8a560d[_0x18863e(0x253)]>_0x57ace2&&_0x8a560d[_0x18863e(0x1b9)]<_0x3aaf2c;})[_0x2ee9bc(0x259)](_0x3e9489=>_0x3e9489[_0x2ee9bc(0x1dd)]))??[];qe(_0x5d5f37,_0x57ace2,_0x3aaf2c,''),_0x5d5f37[_0x2ee9bc(0x1c4)]=[...((_0x227bf7=_0x5d5f37[_0x2ee9bc(0x1c4)])==null?void 0x0:_0x227bf7[_0x2ee9bc(0x21d)](_0x850227=>!_0x20aa1f[_0x2ee9bc(0x222)](_0x850227[_0x2ee9bc(0x1dd)])&&_0x850227[_0x2ee9bc(0x1dd)]!==_0x45ed8f[_0x2ee9bc(0x1dd)]))??[],He(_0x45ed8f[_0x2ee9bc(0x1dd)],_0x57ace2)][_0x2ee9bc(0x18f)]((_0xfb2d83,_0x4c6306)=>_0xfb2d83['startIndex']-_0x4c6306[_0x2ee9bc(0x23b)]);let _0x6334ce=Ue(_0x45ed8f[_0x2ee9bc(0x1e3)]);return _0x20aa1f[_0x2ee9bc(0x171)](_0x389326=>{delete _0x6334ce['formulas'][_0x389326];}),_0x6334ce[_0x2ee9bc(0x18d)][_0x45ed8f[_0x2ee9bc(0x1dd)]]=_0x541130['deepClone'](_0x45ed8f['config']),{'nextDocumentData':_0x2b2b46,'nextResource':_0x6334ce,'cursorOffset':_0x57ace2+0x1};}function Re(_0x243588){const _0x40287f=_0xb81d4c;var _0x1b2074,_0x4d03e4;let _0x36999c=_0x541130['deepClone'](_0x243588[_0x40287f(0x1ba)]),_0x261e50=(_0x1b2074=O(_0x36999c)['customRanges'])==null?void 0x0:_0x1b2074[_0x40287f(0x1bb)](_0x1dd6ed=>_0x1dd6ed[_0x40287f(0x1dd)]===_0x243588[_0x40287f(0x1dd)]&&w(_0x1dd6ed));if(!_0x261e50||!((_0x4d03e4=_0x243588['resource'])!=null&&_0x4d03e4[_0x40287f(0x18d)][_0x243588[_0x40287f(0x1dd)]]))return null;let _0xbfbc05=Ue(_0x243588[_0x40287f(0x1e3)]);return _0xbfbc05[_0x40287f(0x18d)][_0x243588[_0x40287f(0x1dd)]]=_0x541130[_0x40287f(0x211)](_0x243588[_0x40287f(0x1c1)]),{'nextDocumentData':_0x36999c,'nextResource':_0xbfbc05,'cursorOffset':_0x261e50[_0x40287f(0x218)]+0x1};}function ze(_0x375611){const _0xc9000f=_0xb81d4c;let _0x24067b=_0x541130[_0xc9000f(0x211)](_0x375611[_0xc9000f(0x1ba)]),_0x5e9e0c=Je(_0x24067b,_0x375611[_0xc9000f(0x1dd)],_0x375611[_0xc9000f(0x24e)]??'');if(_0x5e9e0c==null)return null;let _0x2e0b14=Ue(_0x375611[_0xc9000f(0x1e3)]);return delete _0x2e0b14['formulas'][_0x375611[_0xc9000f(0x1dd)]],{'nextDocumentData':_0x24067b,'nextResource':_0x2e0b14,'cursorOffset':_0x5e9e0c};}function _0x3d4a(){const _0x337d9c=['blockRanges','customRanges','degradeDocumentData','slice','body','next','_injector','getAllUnitsForType','dataStream','getRegisteredFormulas','docs-formula.mutation.set-resource','833049UHbRqv','getOwnPropertyDescriptor','removeFormula','docs-formula.mutation.set-last-values','docs-formula.command.remove','add','resolveText','1038854TMBjdi','document','getBody','prototype','getFormula','sequenceNodesBuilder','getResource','externalMutations','rangeId','paragraphs','_service','_formulaKeys','COLUMN_GROUP_END','_queueSync','resource','selection','getSnapshot','_registrationService','UNIVER_DOC','degradeBody','TABLE_CELL_END','resourceRedo','number','nextResource','lastValue','2486270CpEqQK','TABLE_ROW_END','formula','docs-formula.command.convert-to-text','length','getInstance','COLUMN_START','replaceDocRanges','_setPresentation','unregister','docs-formula.mutation.remove-formula','function','_cacheEligibilityService','paragraph','string','editOp','params','_deleteRegistration','nextDocumentData','disabled','get','8270633EWhgXj','subscribe','end','start','delete','clear','Doc\x20Formula\x20range\x20cannot\x20cross\x20document\x20structure\x20boundaries','cell','getLoadError','EMPTY','tables','setFormulas','expectedNumberFormat','previousResource','deepClone','deleteFormula','getPresentation','values','isArray','TABLE_START','DOC','endIndex','_formulaService','notifyTextChanged','max','collectMutations','filter','documentRedo','dispose','textRuns','_preserveInvalid','includes','_change$','undoMutation','success','9307072nvFKFx','getResult','_registrations','expectedReferenceRevision','getUnitId','color','PENDING','trigger','_configService','has','model','onCommandExecuted','set','toPrimitive','object','resourceUndo','registerPluginResource','COMMAND','TABLE_END','_presentationChanged$','defineProperty','startIndex','presentation','_commandService','wholeEntity','docs-formula.config','complete','removeUnit','_updateFormulaResult','registerFormulaWithRange','columnGroups','customDecorations','startsWith','PARAGRAPH','expectedFormula','CUSTOM','liveResult','unitAdded$','target','trim','text','unitDisposed$','onStarting','COLUMN_END','stale','endOffset','_docFormulaModel','MUTATION','segmentId','registerProvider','getRevision','map','_loadErrors','empty','resolveFormula','syncExecuteCommand','_isDisposed','DOC_FORMULA_PLUGIN','SUCCESS','_instanceService','assess','pattern','packageName','previousDocumentData','kind','unregisterUnit','resolveBinding','disposeWithMe','status','invalid-resource','forEach','_resourceManagerService','cursorOffset','formulaResult$','every','externalReferences','insertLength','type','getTextRanges','docs-formula.mutation.set-formula','position','error','getUnit','20ffScPR','symbol','retain','18bLJhgZ','syncUnit','assign','formulaId','serialize','_univerInstanceService','properties','insert','_config','pluginName','push','presentationChanged$','formulas','entries','sort','references','_hostExternalReferenceModel','Document\x20main\x20body\x20is\x20required\x20to\x20insert\x20Doc\x20Formula.','source','sectionBreaks','register','1.5.1','isInteger','SECTION_BREAK','data','name','resolved','TABLE_CELL_START','setConfig','numberFormat','registerCommand','referenceRevision','unitId','_syncScheduled','accessor','529350EQsRqz','pending','keys','from','customBlocks','resources','min','stringify','change$','_syncUnit','parse','docs-formula.command.insert','boolean','_model','setResource','redoMutation','CUSTOM_BLOCK','paragraphId','5796324VnKJHt','_rawResources','asObservable','startOffset','documentData','find','load','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','endsWith','iterator','identity','config','_resources'];_0x3d4a=function(){return _0x337d9c;};return _0x3d4a();}function Be(_0x5c55df,_0x49eed3){const _0x38b5da=_0xb81d4c;var _0x349626;let _0x42ed82=_0x541130[_0x38b5da(0x211)](_0x5c55df),_0xee2c13=_0x42ed82[_0x38b5da(0x1c7)];if(!_0xee2c13)return _0x42ed82;let _0x9ab5df=new Map(_0x49eed3[_0x38b5da(0x259)](_0x45c857=>[_0x45c857[_0x38b5da(0x1dd)],_0x45c857[_0x38b5da(0x24e)]])),_0x4e1093=((_0x349626=_0xee2c13['customRanges'])==null?void 0x0:_0x349626[_0x38b5da(0x21d)](_0x1d3152=>w(_0x1d3152)&&_0x9ab5df[_0x38b5da(0x22f)](_0x1d3152['rangeId']))['sort']((_0x6bb730,_0x1472d1)=>_0x1472d1[_0x38b5da(0x23b)]-_0x6bb730[_0x38b5da(0x23b)]))??[];for(let _0xe1f924 of _0x4e1093)Je(_0x42ed82,_0xe1f924[_0x38b5da(0x1dd)],_0x9ab5df[_0x38b5da(0x202)](_0xe1f924['rangeId'])??'');return _0x42ed82;}function w(_0x3757ce){const _0x825f04=_0xb81d4c;var _0x44e4e5;return(_0x3757ce==null?void 0x0:_0x3757ce['rangeType'])===_0x4e4035[_0x825f04(0x249)]&&_0x3757ce[_0x825f04(0x23e)]===!0x0&&((_0x44e4e5=_0x3757ce[_0x825f04(0x187)])==null?void 0x0:_0x44e4e5[_0x825f04(0x16b)])==='univer-docs-formula';}function T(_0x39d642,_0x299675){const _0x369be2=_0xb81d4c;var _0x4fd87d;return _0x39d642==null||(_0x4fd87d=_0x39d642[_0x369be2(0x1c4)])==null?void 0x0:_0x4fd87d[_0x369be2(0x1bb)](_0x4eb271=>_0x4eb271[_0x369be2(0x1dd)]===_0x299675&&w(_0x4eb271));}function Ve(_0x2109ad,_0x3209ca,_0x2de806){const _0x4a07a5=_0xb81d4c;if(_0x3209ca===_0x2de806){if(Ie[_0x4a07a5(0x22f)](_0x2109ad['dataStream'][_0x3209ca]))throw new C();}else{for(let _0x1de862=_0x3209ca;_0x1de862<_0x2de806;_0x1de862++)if(_0x2109ad['dataStream'][_0x1de862]===_0x4bf61f[_0x4a07a5(0x247)]||Ie[_0x4a07a5(0x22f)](_0x2109ad[_0x4a07a5(0x1cb)][_0x1de862]))throw new C();}}function He(_0x490723,_0x41cf50){const _0x59da89=_0xb81d4c;return{'startIndex':_0x41cf50,'endIndex':_0x41cf50,'rangeId':_0x490723,'rangeType':_0x4e4035[_0x59da89(0x249)],'wholeEntity':!0x0,'properties':{'kind':je}};}function Ue(_0x2e2184){const _0x4c1576=_0xb81d4c;return _0x2e2184?_0x541130[_0x4c1576(0x211)](_0x2e2184):b();}function We(_0x27ce4f,_0x3179a5,_0x3aa9ab){const _0x1cc2aa=_0xb81d4c;let _0x46ea58=Ke(_0x27ce4f),_0x134f5b=_0x3179a5??_0x46ea58,_0x104fea=_0x3aa9ab??_0x134f5b;return{'startOffset':Ge(Math[_0x1cc2aa(0x1aa)](_0x134f5b,_0x104fea),_0x46ea58),'endOffset':Ge(Math[_0x1cc2aa(0x21b)](_0x134f5b,_0x104fea),_0x46ea58)};}function Ge(_0x16ca31,_0x4cbf61){const _0xb057b9=_0xb81d4c;return Math[_0xb057b9(0x21b)](0x0,Math['min'](_0x16ca31,_0x4cbf61));}function Ke(_0x161d6d){const _0x1db2d0=_0xb81d4c;return _0x161d6d[_0x1db2d0(0x1cb)][_0x1db2d0(0x1be)](''+_0x4bf61f[_0x1db2d0(0x247)]+_0x4bf61f['SECTION_BREAK'])?Math[_0x1db2d0(0x21b)](0x0,_0x161d6d[_0x1db2d0(0x1cb)][_0x1db2d0(0x1f2)]-0x2):_0x161d6d[_0x1db2d0(0x1cb)][_0x1db2d0(0x1be)](_0x4bf61f[_0x1db2d0(0x198)])?Math[_0x1db2d0(0x21b)](0x0,_0x161d6d['dataStream']['length']-0x1):_0x161d6d['dataStream'][_0x1db2d0(0x1f2)];}function qe(_0xa328aa,_0x4d1020,_0x30bac2,_0x39139d){_0x30bac2>_0x4d1020&&Xe(_0xa328aa,_0x4d1020,_0x30bac2),Ye(_0xa328aa,_0x4d1020,_0x39139d);}function Je(_0x134655,_0x416f06,_0x4a85db){const _0x5d070b=_0xb81d4c;var _0xe0c63e,_0x5334e6;let _0x358ef7=O(_0x134655),_0x35e499=(_0xe0c63e=_0x358ef7[_0x5d070b(0x1c4)])==null?void 0x0:_0xe0c63e[_0x5d070b(0x1bb)](_0x1aa972=>_0x1aa972[_0x5d070b(0x1dd)]===_0x416f06&&w(_0x1aa972));if(!_0x35e499)return null;let _0x37da4d=_0x128c46(_0x35e499);return qe(_0x358ef7,_0x37da4d[_0x5d070b(0x1b9)],_0x37da4d['endOffset'],_0x4a85db),_0x358ef7[_0x5d070b(0x1c4)]=(_0x5334e6=_0x358ef7[_0x5d070b(0x1c4)])==null?void 0x0:_0x5334e6['filter'](_0x111b5e=>_0x111b5e['rangeId']!==_0x416f06),_0x37da4d[_0x5d070b(0x1b9)]+_0x4a85db[_0x5d070b(0x1f2)];}function Ye(_0x505bb9,_0x3a4161,_0x278a91){const _0x443dd7=_0xb81d4c;_0x278a91&&(_0x505bb9['dataStream']=''+_0x505bb9['dataStream']['slice'](0x0,_0x3a4161)+_0x278a91+_0x505bb9[_0x443dd7(0x1cb)][_0x443dd7(0x1c6)](_0x3a4161),Ze(_0x505bb9,_0x3a4161,_0x278a91[_0x443dd7(0x1f2)]));}function Xe(_0x738ddd,_0x15963b,_0x2d1fb1){const _0x31610b=_0xb81d4c;let _0x5c12dd=_0x2d1fb1-_0x15963b;_0x738ddd['dataStream']=''+_0x738ddd[_0x31610b(0x1cb)]['slice'](0x0,_0x15963b)+_0x738ddd[_0x31610b(0x1cb)][_0x31610b(0x1c6)](_0x2d1fb1),Qe(_0x738ddd,_0x15963b,_0x5c12dd);}function Ze(_0x315792,_0x599bfe,_0x2596f0){const _0x336321=_0xb81d4c;_0x315792['paragraphs']=$e(_0x315792[_0x336321(0x1de)],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x194)]=$e(_0x315792[_0x336321(0x194)],_0x599bfe,_0x2596f0),_0x315792['customBlocks']=$e(_0x315792[_0x336321(0x1a8)],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x220)]=tt(_0x315792[_0x336321(0x220)],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x20d)]=nt(_0x315792[_0x336321(0x20d)],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x244)]=E(_0x315792[_0x336321(0x244)],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x1c4)]=E(_0x315792['customRanges'],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x245)]=E(_0x315792[_0x336321(0x245)],_0x599bfe,_0x2596f0),_0x315792[_0x336321(0x1c3)]=E(_0x315792['blockRanges'],_0x599bfe,_0x2596f0);}function Qe(_0x435349,_0x22f04c,_0x302aed){const _0x47806b=_0xb81d4c;var _0x512d60,_0x4c5d81;_0x435349[_0x47806b(0x1de)]=et(_0x435349['paragraphs'],_0x22f04c,_0x302aed),_0x435349[_0x47806b(0x194)]=et(_0x435349['sectionBreaks'],_0x22f04c,_0x302aed),_0x435349[_0x47806b(0x1a8)]=et(_0x435349['customBlocks'],_0x22f04c,_0x302aed),_0x435349[_0x47806b(0x220)]=(_0x512d60=rt((_0x4c5d81=_0x435349[_0x47806b(0x220)])==null?void 0x0:_0x4c5d81[_0x47806b(0x259)](_0x1284f9=>({..._0x1284f9,'startIndex':_0x1284f9['st'],'endIndex':_0x1284f9['ed']})),_0x22f04c,_0x302aed))==null?void 0x0:_0x512d60[_0x47806b(0x259)](_0x3953f7=>{let {startIndex:_0x16bdaa,endIndex:_0x4740da,..._0x3ed05c}=_0x3953f7;return{..._0x3ed05c,'st':_0x16bdaa,'ed':_0x4740da};}),_0x435349[_0x47806b(0x20d)]=rt(_0x435349[_0x47806b(0x20d)],_0x22f04c,_0x302aed),_0x435349[_0x47806b(0x244)]=D(_0x435349['columnGroups'],_0x22f04c,_0x302aed),_0x435349[_0x47806b(0x1c4)]=D(_0x435349[_0x47806b(0x1c4)],_0x22f04c,_0x302aed),_0x435349[_0x47806b(0x245)]=D(_0x435349['customDecorations'],_0x22f04c,_0x302aed),_0x435349['blockRanges']=D(_0x435349[_0x47806b(0x1c3)],_0x22f04c,_0x302aed);}function $e(_0x1c0d9e,_0x357c9e,_0xb6cd01){const _0x594658=_0xb81d4c;return _0x1c0d9e==null?void 0x0:_0x1c0d9e[_0x594658(0x259)](_0x2b1e62=>_0x2b1e62['startIndex']>=_0x357c9e?{..._0x2b1e62,'startIndex':_0x2b1e62['startIndex']+_0xb6cd01}:_0x2b1e62);}function et(_0x35c7ca,_0x4f3954,_0x19dd5f){const _0x484e0c=_0xb81d4c;let _0x2d4610=_0x4f3954+_0x19dd5f;return _0x35c7ca==null?void 0x0:_0x35c7ca[_0x484e0c(0x259)](_0x462a3b=>_0x462a3b[_0x484e0c(0x23b)]>=_0x4f3954&&_0x462a3b[_0x484e0c(0x23b)]<_0x2d4610?null:_0x462a3b[_0x484e0c(0x23b)]>=_0x2d4610?{..._0x462a3b,'startIndex':_0x462a3b[_0x484e0c(0x23b)]-_0x19dd5f}:_0x462a3b)[_0x484e0c(0x21d)](_0x32ff70=>_0x32ff70!=null);}function tt(_0xede946,_0x5ad772,_0x519a4a){return _0xede946==null?void 0x0:_0xede946['map'](_0x408d6f=>_0x408d6f['st']>=_0x5ad772?{..._0x408d6f,'st':_0x408d6f['st']+_0x519a4a,'ed':_0x408d6f['ed']+_0x519a4a}:_0x408d6f['ed']>_0x5ad772?{..._0x408d6f,'ed':_0x408d6f['ed']+_0x519a4a}:_0x408d6f);}function E(_0x3a7734,_0x2bde18,_0x480011){const _0x477aa4=_0xb81d4c;return _0x3a7734==null?void 0x0:_0x3a7734[_0x477aa4(0x259)](_0x549af3=>_0x21d172(_0x549af3,_0x2bde18,_0x480011));}function nt(_0x4c63cb,_0x4fb8,_0x236e1b){const _0x20ba95=_0xb81d4c;return _0x4c63cb==null?void 0x0:_0x4c63cb[_0x20ba95(0x259)](_0x38f569=>_0x190d1a(_0x38f569,_0x4fb8,_0x236e1b));}function D(_0x5e162c,_0x57bc7a,_0xa07f8d){const _0x20bb09=_0xb81d4c;return _0x5e162c==null?void 0x0:_0x5e162c['map'](_0x4e4111=>_0x4ab3ac(_0x4e4111,_0x57bc7a,_0xa07f8d))[_0x20bb09(0x21d)](_0x5a9d75=>_0x5a9d75!=null);}function rt(_0x2957d5,_0x4231ba,_0x5e0141){const _0x38e6b1=_0xb81d4c;return _0x2957d5==null?void 0x0:_0x2957d5[_0x38e6b1(0x259)](_0x2c24a5=>_0x463586(_0x2c24a5,_0x4231ba,_0x5e0141))[_0x38e6b1(0x21d)](_0xe282a=>_0xe282a!=null);}function O(_0x3fb3f4){const _0x49b8d6=_0xb81d4c;if(!_0x3fb3f4[_0x49b8d6(0x1c7)])throw Error(_0x49b8d6(0x192));return _0x3fb3f4[_0x49b8d6(0x1c7)];}function k(_0x49d5ba){'@babel/helpers - typeof';const _0x569560=_0xb81d4c;return k=typeof Symbol==_0x569560(0x1f9)&&typeof Symbol[_0x569560(0x1bf)]==_0x569560(0x17f)?function(_0x4f3f0d){return typeof _0x4f3f0d;}:function(_0x57823b){const _0x888a46=_0x569560;return _0x57823b&&typeof Symbol=='function'&&_0x57823b['constructor']===Symbol&&_0x57823b!==Symbol[_0x888a46(0x1d8)]?_0x888a46(0x17f):typeof _0x57823b;},k(_0x49d5ba);}function it(_0x2786f5,_0x258a9e){const _0x53ec01=_0xb81d4c;if(k(_0x2786f5)!=_0x53ec01(0x234)||!_0x2786f5)return _0x2786f5;var _0xe56c7e;if(typeof Symbol<'u'&&(_0xe56c7e=_0x2786f5[Symbol[_0x53ec01(0x233)]])!==void 0x0){var _0x55369e=_0xe56c7e['call'](_0x2786f5,_0x258a9e||'default');if(k(_0x55369e)!=_0x53ec01(0x234))return _0x55369e;throw TypeError(_0x53ec01(0x1bd));}return(_0x258a9e===_0x53ec01(0x1fc)?String:Number)(_0x2786f5);}function at(_0x6a4a1a){const _0x58d84d=_0xb81d4c;var _0xa1395=it(_0x6a4a1a,_0x58d84d(0x1fc));return k(_0xa1395)==_0x58d84d(0x17f)?_0xa1395:_0xa1395+'';}function A(_0x2e633d,_0x137df1,_0x1da17a){const _0x53a73e=_0xb81d4c;return(_0x137df1=at(_0x137df1))in _0x2e633d?Object[_0x53a73e(0x23a)](_0x2e633d,_0x137df1,{'value':_0x1da17a,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x2e633d[_0x137df1]=_0x1da17a,_0x2e633d;}var j=class extends _0xf99196{constructor(..._0x199dd4){const _0x5e8a35=_0xb81d4c;super(..._0x199dd4),A(this,_0x5e8a35(0x1c2),new Map()),A(this,_0x5e8a35(0x1b7),new Map()),A(this,'_loadErrors',new Map()),A(this,_0x5e8a35(0x223),new _0x45c46f()),A(this,_0x5e8a35(0x1ac),this[_0x5e8a35(0x223)][_0x5e8a35(0x1b8)]());}[_0xb81d4c(0x1d9)](_0x5a8645,_0xd5e0f6){const _0x435d9c=_0xb81d4c;var _0x36d223;let _0x290c31=(_0x36d223=this[_0x435d9c(0x1c2)][_0x435d9c(0x202)](_0x5a8645))==null?void 0x0:_0x36d223[_0x435d9c(0x18d)][_0xd5e0f6];return _0x290c31?_0x541130[_0x435d9c(0x211)](_0x290c31):void 0x0;}['getFormulas'](_0x556c20){const _0x31b166=_0xb81d4c;var _0x49dbae;return _0x541130[_0x31b166(0x211)](((_0x49dbae=this[_0x31b166(0x1c2)]['get'](_0x556c20))==null?void 0x0:_0x49dbae['formulas'])??{});}[_0xb81d4c(0x1db)](_0x38513f){const _0x4a52a0=_0xb81d4c;let _0x1929ab=this[_0x4a52a0(0x1c2)][_0x4a52a0(0x202)](_0x38513f);return _0x1929ab?_0x541130['deepClone'](_0x1929ab):void 0x0;}['setFormula'](_0x42b353,_0x4907ed,_0x1f8281){const _0x2aadfc=_0xb81d4c;return this[_0x2aadfc(0x20e)](_0x42b353,{[_0x4907ed]:_0x1f8281});}[_0xb81d4c(0x1b2)](_0x19cbe6,_0x243e2b){const _0x344b05=_0xb81d4c;return this[_0x344b05(0x25a)][_0x344b05(0x22f)](_0x19cbe6)||!x(_0x243e2b)?!0x1:(this[_0x344b05(0x1c2)][_0x344b05(0x232)](_0x19cbe6,{'formulas':_0x541130['deepClone'](_0x243e2b[_0x344b05(0x18d)])}),this[_0x344b05(0x223)][_0x344b05(0x1c8)]({'unitId':_0x19cbe6}),!0x0);}['setFormulas'](_0x29a05c,_0x58d572){const _0xc06b82=_0xb81d4c;if(this[_0xc06b82(0x25a)]['has'](_0x29a05c)||!Object['keys'](_0x58d572)[_0xc06b82(0x1f2)]||!x({'formulas':_0x58d572}))return!0x1;let _0x6807e4=this[_0xc06b82(0x1c2)][_0xc06b82(0x202)](_0x29a05c)??b(),_0x1ee37c=_0x541130[_0xc06b82(0x211)](_0x6807e4);return Object[_0xc06b82(0x183)](_0x1ee37c[_0xc06b82(0x18d)],_0x541130[_0xc06b82(0x211)](_0x58d572)),this[_0xc06b82(0x1c2)][_0xc06b82(0x232)](_0x29a05c,_0x1ee37c),this[_0xc06b82(0x223)]['next']({'unitId':_0x29a05c,'rangeIds':Object[_0xc06b82(0x1a6)](_0x58d572)}),!0x0;}[_0xb81d4c(0x1d0)](_0x2592e2,_0xe20e11){const _0x4b0976=_0xb81d4c;if(this[_0x4b0976(0x25a)][_0x4b0976(0x22f)](_0x2592e2))return!0x1;let _0x20a284=this['_resources']['get'](_0x2592e2);if(!(_0x20a284!=null&&_0x20a284[_0x4b0976(0x18d)][_0xe20e11]))return!0x1;let _0x2fc32a=_0x541130[_0x4b0976(0x211)](_0x20a284);return delete _0x2fc32a[_0x4b0976(0x18d)][_0xe20e11],this[_0x4b0976(0x1c2)]['set'](_0x2592e2,_0x2fc32a),this['_change$'][_0x4b0976(0x1c8)]({'unitId':_0x2592e2,'rangeIds':[_0xe20e11]}),!0x0;}[_0xb81d4c(0x1bc)](_0x373bea,_0x2aa023){const _0xa9ca41=_0xb81d4c;return x(_0x2aa023)?(this[_0xa9ca41(0x1c2)][_0xa9ca41(0x232)](_0x373bea,{'formulas':_0x541130['deepClone'](_0x2aa023[_0xa9ca41(0x18d)])}),this['_rawResources'][_0xa9ca41(0x207)](_0x373bea),this[_0xa9ca41(0x25a)][_0xa9ca41(0x207)](_0x373bea),this[_0xa9ca41(0x223)][_0xa9ca41(0x1c8)]({'unitId':_0x373bea}),!0x0):(this[_0xa9ca41(0x221)](_0x373bea,_0x2aa023,_0xa9ca41(0x170)),!0x1);}['serialize'](_0x1a4ff4){const _0x39ede2=_0xb81d4c;let _0x674110=this[_0x39ede2(0x1c2)][_0x39ede2(0x202)](_0x1a4ff4);return _0x674110?_0x541130[_0x39ede2(0x211)](_0x674110):this[_0x39ede2(0x1b7)][_0x39ede2(0x22f)](_0x1a4ff4)?_0x541130[_0x39ede2(0x211)](this[_0x39ede2(0x1b7)][_0x39ede2(0x202)](_0x1a4ff4)):b();}[_0xb81d4c(0x20b)](_0xcd0641){const _0x1546d8=_0xb81d4c;return this[_0x1546d8(0x25a)]['get'](_0xcd0641);}[_0xb81d4c(0x241)](_0x1484a4){const _0x37ada4=_0xb81d4c;this[_0x37ada4(0x1c2)][_0x37ada4(0x207)](_0x1484a4),this[_0x37ada4(0x1b7)][_0x37ada4(0x207)](_0x1484a4),this[_0x37ada4(0x25a)][_0x37ada4(0x207)](_0x1484a4),this[_0x37ada4(0x223)][_0x37ada4(0x1c8)]({'unitId':_0x1484a4});}['dispose'](){const _0x3d6541=_0xb81d4c;this[_0x3d6541(0x1c2)][_0x3d6541(0x208)](),this[_0x3d6541(0x1b7)][_0x3d6541(0x208)](),this[_0x3d6541(0x25a)][_0x3d6541(0x208)](),this['_change$'][_0x3d6541(0x240)](),super[_0x3d6541(0x21f)]();}['_preserveInvalid'](_0x2b188f,_0x2b41ea,_0x289765){const _0x4cbce1=_0xb81d4c;this[_0x4cbce1(0x1c2)][_0x4cbce1(0x207)](_0x2b188f),this[_0x4cbce1(0x1b7)][_0x4cbce1(0x232)](_0x2b188f,_0x541130[_0x4cbce1(0x211)](_0x2b41ea)),this[_0x4cbce1(0x25a)][_0x4cbce1(0x232)](_0x2b188f,_0x289765),this['_change$'][_0x4cbce1(0x1c8)]({'unitId':_0x2b188f});}};let ot=function(_0x1e79df){const _0x57ce53=_0xb81d4c;return _0x1e79df[_0x57ce53(0x20c)]='empty',_0x1e79df[_0x57ce53(0x22c)]='pending',_0x1e79df[_0x57ce53(0x165)]=_0x57ce53(0x225),_0x1e79df['ERROR']=_0x57ce53(0x17c),_0x1e79df;}({});function M(_0x483d95,_0x11c4c2){return function(_0x10bef2,_0x5b66b9){_0x11c4c2(_0x10bef2,_0x5b66b9,_0x483d95);};}function N(_0x1b1c2d,_0x5c1815,_0x227afb,_0x3d816b){const _0x53728d=_0xb81d4c;var _0x3ed342=arguments[_0x53728d(0x1f2)],_0x11b751=_0x3ed342<0x3?_0x5c1815:_0x3d816b===null?_0x3d816b=Object[_0x53728d(0x1cf)](_0x5c1815,_0x227afb):_0x3d816b,_0x1fd928;if(typeof Reflect==_0x53728d(0x234)&&typeof Reflect['decorate']==_0x53728d(0x1f9))_0x11b751=Reflect['decorate'](_0x1b1c2d,_0x5c1815,_0x227afb,_0x3d816b);else{for(var _0xbe674d=_0x1b1c2d[_0x53728d(0x1f2)]-0x1;_0xbe674d>=0x0;_0xbe674d--)(_0x1fd928=_0x1b1c2d[_0xbe674d])&&(_0x11b751=(_0x3ed342<0x3?_0x1fd928(_0x11b751):_0x3ed342>0x3?_0x1fd928(_0x5c1815,_0x227afb,_0x11b751):_0x1fd928(_0x5c1815,_0x227afb))||_0x11b751);}return _0x3ed342>0x3&&_0x11b751&&Object[_0x53728d(0x23a)](_0x5c1815,_0x227afb,_0x11b751),_0x11b751;}let P=class extends _0xf99196{constructor(_0x53a403,_0x3c79e3,_0x26bf7f){const _0x5e24ef=_0xb81d4c;super(),this[_0x5e24ef(0x1b1)]=_0x53a403,this[_0x5e24ef(0x1e6)]=_0x3c79e3,this[_0x5e24ef(0x191)]=_0x26bf7f,A(this,_0x5e24ef(0x228),new Map()),A(this,_0x5e24ef(0x1e0),new Map()),A(this,_0x5e24ef(0x239),new _0x45c46f()),A(this,'presentationChanged$',this[_0x5e24ef(0x239)]['asObservable']()),this[_0x5e24ef(0x16e)](this[_0x5e24ef(0x1e6)][_0x5e24ef(0x174)][_0x5e24ef(0x204)](_0x4ebe76=>{const _0x508896=_0x5e24ef;for(let _0x278a36 of Object['values'](_0x4ebe76))for(let _0x558980 of Object[_0x508896(0x214)](_0x278a36))_0x558980[_0x508896(0x171)](_0x5479eb=>this['_updateFormulaResult'](_0x5479eb));}));}['syncUnit'](_0x45a940){const _0x533696=_0xb81d4c;var _0x54cab7;let _0x349a33=_0x45a940[_0x533696(0x22a)](),_0x19f1f3=((_0x54cab7=_0x45a940[_0x533696(0x1e5)]()['body'])==null||(_0x54cab7=_0x54cab7[_0x533696(0x1c4)])==null?void 0x0:_0x54cab7['filter'](w))??[],_0x310f8c=this[_0x533696(0x1b1)]['getFormulas'](_0x349a33),_0x10f5b6=new Set();for(let _0xa85a8f of _0x19f1f3){let _0x14648a=_0x310f8c[_0xa85a8f[_0x533696(0x1dd)]];_0x14648a&&(_0x10f5b6['add'](F(_0x349a33,_0xa85a8f[_0x533696(0x1dd)])),this[_0x533696(0x195)]({'unitId':_0x349a33,'rangeId':_0xa85a8f[_0x533696(0x1dd)]},_0x14648a));}for(let _0x3ed150 of Array['from'](this['_registrations']['values']()))_0x3ed150[_0x533696(0x1a1)]===_0x349a33&&!_0x10f5b6[_0x533696(0x22f)](F(_0x3ed150[_0x533696(0x1a1)],_0x3ed150[_0x533696(0x1dd)]))&&this[_0x533696(0x1f7)](_0x3ed150);}[_0xb81d4c(0x195)](_0x221098,_0x442d54){const _0x3e8559=_0xb81d4c;let _0x1b5499=F(_0x221098[_0x3e8559(0x1a1)],_0x221098['rangeId']),_0x4d9aa1=this[_0x3e8559(0x228)][_0x3e8559(0x202)](_0x1b5499),_0x35b757=this[_0x3e8559(0x191)][_0x3e8559(0x258)](_0x221098[_0x3e8559(0x1a1)]);if(_0x4d9aa1&&_0x4d9aa1[_0x3e8559(0x1c1)][_0x3e8559(0x1f0)]===_0x442d54[_0x3e8559(0x1f0)]&&_0x4d9aa1['referenceRevision']===_0x35b757){_0x4d9aa1['config']=_0x442d54;let _0x5f0606=_0x4d9aa1[_0x3e8559(0x184)]?this[_0x3e8559(0x1e6)]['getFormulaValueSync'](_0x4d9aa1[_0x3e8559(0x1a1)],_0x4d9aa1['unitId'],_0x4d9aa1[_0x3e8559(0x184)])??void 0x0:void 0x0;_0x4d9aa1['liveResult']=_0x5f0606,this[_0x3e8559(0x1f6)](_0x1b5499,st(_0x442d54,_0x5f0606));return;}_0x4d9aa1!=null&&_0x4d9aa1['formulaId']&&this['_deleteRegistration'](_0x4d9aa1);let _0x212fb6={..._0x221098,'config':_0x442d54,'referenceRevision':_0x35b757,'presentation':st(_0x442d54,void 0x0)};if(this[_0x3e8559(0x228)][_0x3e8559(0x232)](_0x1b5499,_0x212fb6),!_0x442d54[_0x3e8559(0x1f0)][_0x3e8559(0x24d)]())return;let _0x312f01=this['_registrationService'][_0x3e8559(0x243)](_0x221098[_0x3e8559(0x1a1)],_0x221098[_0x3e8559(0x1a1)],_0x442d54[_0x3e8559(0x1f0)],void 0x0,{'rangeId':_0x221098[_0x3e8559(0x1dd)]},_0x5593a7[_0x3e8559(0x217)],_0x221098[_0x3e8559(0x1dd)]);_0x212fb6[_0x3e8559(0x184)]=_0x312f01,this[_0x3e8559(0x1e0)][_0x3e8559(0x232)](_0x312f01,_0x1b5499);}[_0xb81d4c(0x1f7)](_0x18c02d){const _0x4129de=_0xb81d4c;let _0x47e2af=F(_0x18c02d[_0x4129de(0x1a1)],_0x18c02d[_0x4129de(0x1dd)]),_0x4792c2=this[_0x4129de(0x228)][_0x4129de(0x202)](_0x47e2af);_0x4792c2&&(this[_0x4129de(0x1ff)](_0x4792c2),this[_0x4129de(0x228)][_0x4129de(0x207)](_0x47e2af));}[_0xb81d4c(0x16c)](_0x488548){const _0x406cf8=_0xb81d4c;for(let _0x5dd8ed of Array[_0x406cf8(0x1a7)](this[_0x406cf8(0x228)][_0x406cf8(0x214)]()))_0x5dd8ed[_0x406cf8(0x1a1)]===_0x488548&&this['unregister'](_0x5dd8ed);}[_0xb81d4c(0x213)](_0x570e32){const _0x4b000d=_0xb81d4c;var _0x33ee7d;return(_0x33ee7d=this[_0x4b000d(0x228)][_0x4b000d(0x202)](F(_0x570e32[_0x4b000d(0x1a1)],_0x570e32[_0x4b000d(0x1dd)])))==null?void 0x0:_0x33ee7d[_0x4b000d(0x23c)];}[_0xb81d4c(0x227)](_0x44078b){const _0x21e32f=_0xb81d4c;let _0x33639f=this[_0x21e32f(0x228)]['get'](F(_0x44078b[_0x21e32f(0x1a1)],_0x44078b['rangeId']));return _0x33639f?I(_0x33639f):void 0x0;}['getRegisteredFormulas'](){const _0x573795=_0xb81d4c;return Array['from'](this[_0x573795(0x228)][_0x573795(0x214)](),_0x406a3e=>({'identity':{'unitId':_0x406a3e['unitId'],'rangeId':_0x406a3e['rangeId']},'config':_0x406a3e[_0x573795(0x1c1)],'referenceRevision':_0x406a3e[_0x573795(0x1a0)],..._0x406a3e[_0x573795(0x24a)]?{'liveResult':_0x406a3e['liveResult']}:null}));}[_0xb81d4c(0x21f)](){const _0x1b2b09=_0xb81d4c;for(let _0x352099 of this['_registrations']['values']())this['_deleteRegistration'](_0x352099);this[_0x1b2b09(0x228)]['clear'](),this[_0x1b2b09(0x1e0)][_0x1b2b09(0x208)](),this[_0x1b2b09(0x239)]['complete'](),super[_0x1b2b09(0x21f)]();}[_0xb81d4c(0x242)](_0x665f40){const _0x147fb7=_0xb81d4c;let _0x56db0c=this[_0x147fb7(0x1e0)][_0x147fb7(0x202)](_0x665f40[_0x147fb7(0x184)]),_0x412b97=_0x56db0c?this[_0x147fb7(0x228)][_0x147fb7(0x202)](_0x56db0c):void 0x0;_0x56db0c&&_0x412b97&&(_0x412b97[_0x147fb7(0x24a)]=_0x665f40,this[_0x147fb7(0x1f6)](_0x56db0c,st(_0x412b97[_0x147fb7(0x1c1)],_0x665f40)));}['_setPresentation'](_0x26cc11,_0x385169){const _0x270d6d=_0xb81d4c;var _0x23bfd0,_0x129b0b;let _0x598434=this[_0x270d6d(0x228)][_0x270d6d(0x202)](_0x26cc11);if(!_0x598434||ct(_0x598434[_0x270d6d(0x23c)],_0x385169))return;let _0x378708=_0x598434[_0x270d6d(0x23c)],_0x477f7a=I(_0x598434);_0x598434[_0x270d6d(0x23c)]=_0x385169,this[_0x270d6d(0x239)][_0x270d6d(0x1c8)]({'unitId':_0x598434[_0x270d6d(0x1a1)],'rangeId':_0x598434[_0x270d6d(0x1dd)],'presentation':_0x385169,'previousPresentation':_0x378708,'result':I(_0x598434),'previousResult':{..._0x477f7a,..._0x378708,'value':(_0x23bfd0=_0x378708[_0x270d6d(0x20a)])==null?void 0x0:_0x23bfd0['v'],'valueType':((_0x129b0b=_0x378708['cell'])==null?void 0x0:_0x129b0b['t'])??void 0x0}});}[_0xb81d4c(0x1ff)](_0x3c4204){const _0x2e9203=_0xb81d4c;_0x3c4204[_0x2e9203(0x184)]&&(this['_registrationService'][_0x2e9203(0x212)](_0x3c4204[_0x2e9203(0x1a1)],_0x3c4204[_0x2e9203(0x1a1)],[_0x3c4204[_0x2e9203(0x184)]]),this['_formulaKeys'][_0x2e9203(0x207)](_0x3c4204[_0x2e9203(0x184)]));}};P=N([M(0x0,_0x3abf00(j)),M(0x1,_0x3abf00(_0x3b74c8)),M(0x2,_0x3abf00(_0x2be22c))],P);function F(_0x1a5cae,_0x7d250){return _0x1a5cae+'\x00'+_0x7d250;}function st(_0x31402a,_0xcfc749){const _0x3fbbf0=_0xb81d4c;return _0x157ca0({'numberFormat':_0x31402a[_0x3fbbf0(0x19e)],'lastValue':_0x31402a[_0x3fbbf0(0x1ed)],'result':_0xcfc749});}function I(_0x31b3a2){const _0x271cf5=_0xb81d4c;var _0x57ebaf,_0x508093,_0x5674b9;let _0x126091=_0x31b3a2[_0x271cf5(0x23c)],_0x2de832=_0x31b3a2[_0x271cf5(0x1c1)][_0x271cf5(0x1f0)][_0x271cf5(0x24d)]()?_0x126091['stale']||_0x126091[_0x271cf5(0x20a)]==null?_0x271cf5(0x1a5):((_0x57ebaf=_0x31b3a2[_0x271cf5(0x24a)])==null?void 0x0:_0x57ebaf[_0x271cf5(0x16f)])===_0xd61d8b['ERROR']?'error':_0x271cf5(0x225):_0x271cf5(0x25b);return{..._0x126091,'status':_0x2de832,'value':(_0x508093=_0x126091[_0x271cf5(0x20a)])==null?void 0x0:_0x508093['v'],'valueType':((_0x5674b9=_0x126091[_0x271cf5(0x20a)])==null?void 0x0:_0x5674b9['t'])??void 0x0};}function ct(_0x2bb7a7,_0x455e94){const _0x116f58=_0xb81d4c;var _0x1cd48d,_0x3112c5,_0x1ad937,_0x16f10b;return _0x2bb7a7[_0x116f58(0x24e)]===_0x455e94[_0x116f58(0x24e)]&&_0x2bb7a7[_0x116f58(0x22b)]===_0x455e94[_0x116f58(0x22b)]&&_0x2bb7a7['pattern']===_0x455e94['pattern']&&_0x2bb7a7[_0x116f58(0x193)]===_0x455e94[_0x116f58(0x193)]&&_0x2bb7a7[_0x116f58(0x252)]===_0x455e94['stale']&&((_0x1cd48d=_0x2bb7a7[_0x116f58(0x20a)])==null?void 0x0:_0x1cd48d['t'])===((_0x3112c5=_0x455e94[_0x116f58(0x20a)])==null?void 0x0:_0x3112c5['t'])&&Object['is']((_0x1ad937=_0x2bb7a7[_0x116f58(0x20a)])==null?void 0x0:_0x1ad937['v'],(_0x16f10b=_0x455e94[_0x116f58(0x20a)])==null?void 0x0:_0x16f10b['v']);}const lt={'id':_0xb81d4c(0x17a),'type':_0x599208[_0xb81d4c(0x255)],'handler':(_0x2d7335,_0x4f8636)=>!(_0x4f8636!=null&&_0x4f8636['unitId'])||!_0x4f8636[_0xb81d4c(0x1dd)]||!_0x4f8636[_0xb81d4c(0x1c1)]?!0x1:_0x2d7335[_0xb81d4c(0x202)](j)['setFormula'](_0x4f8636['unitId'],_0x4f8636[_0xb81d4c(0x1dd)],_0x4f8636['config'])},ut={'id':_0xb81d4c(0x1f8),'type':_0x599208['MUTATION'],'handler':(_0x153242,_0x5c3073)=>!(_0x5c3073!=null&&_0x5c3073[_0xb81d4c(0x1a1)])||!_0x5c3073['rangeId']?!0x1:_0x153242[_0xb81d4c(0x202)](j)[_0xb81d4c(0x1d0)](_0x5c3073[_0xb81d4c(0x1a1)],_0x5c3073[_0xb81d4c(0x1dd)])},L={'id':_0xb81d4c(0x1cd),'type':_0x599208[_0xb81d4c(0x255)],'handler':(_0x3b672b,_0x1db447)=>!(_0x1db447!=null&&_0x1db447[_0xb81d4c(0x1a1)])||!_0x1db447[_0xb81d4c(0x1e3)]?!0x1:_0x3b672b['get'](j)[_0xb81d4c(0x1b2)](_0x1db447[_0xb81d4c(0x1a1)],_0x1db447['resource'])},R={'id':_0xb81d4c(0x1d1),'type':_0x599208['MUTATION'],'handler':(_0x17f836,_0x43ebe7)=>{const _0x3fa37c=_0xb81d4c;if(!(_0x43ebe7!=null&&_0x43ebe7['unitId'])||!_0x43ebe7['updates'][_0x3fa37c(0x1f2)])return!0x1;let _0x5bc5a1=_0x17f836[_0x3fa37c(0x202)](j),_0x3f0f0a=_0x17f836[_0x3fa37c(0x202)](_0x2be22c),_0x3978f9=_0x5bc5a1[_0x3fa37c(0x1db)](_0x43ebe7[_0x3fa37c(0x1a1)]);if(!_0x3978f9)return!0x1;let _0x3bdff3=_0x541130[_0x3fa37c(0x211)](_0x3978f9),_0x3d7541=!0x1;for(let _0x446995 of _0x43ebe7['updates']){var _0x587c3f,_0x2ec82a,_0x4c477a,_0x38e441;let _0x110b6a=_0x3bdff3[_0x3fa37c(0x18d)][_0x446995[_0x3fa37c(0x1dd)]];_0x110b6a&&_0x110b6a[_0x3fa37c(0x1f0)]===_0x446995[_0x3fa37c(0x248)]&&((_0x587c3f=_0x110b6a[_0x3fa37c(0x19e)])==null?void 0x0:_0x587c3f[_0x3fa37c(0x168)])===_0x446995[_0x3fa37c(0x20f)]&&_0x3f0f0a[_0x3fa37c(0x258)](_0x43ebe7[_0x3fa37c(0x1a1)])===_0x446995[_0x3fa37c(0x229)]&&(((_0x2ec82a=_0x110b6a[_0x3fa37c(0x1ed)])==null?void 0x0:_0x2ec82a['v'])!==_0x446995['lastValue']['v']||((_0x4c477a=_0x110b6a[_0x3fa37c(0x1ed)])==null?void 0x0:_0x4c477a['t'])!==_0x446995[_0x3fa37c(0x1ed)]['t']||((_0x38e441=_0x110b6a['lastValue'])==null?void 0x0:_0x38e441[_0x3fa37c(0x168)])!==_0x446995[_0x3fa37c(0x1ed)][_0x3fa37c(0x168)])&&(_0x110b6a[_0x3fa37c(0x1ed)]=_0x541130[_0x3fa37c(0x211)](_0x446995['lastValue']),_0x3d7541=!0x0);}return!_0x3d7541||_0x5bc5a1[_0x3fa37c(0x1b2)](_0x43ebe7[_0x3fa37c(0x1a1)],_0x3bdff3);}},z={'id':_0xb81d4c(0x1af),'type':_0x599208[_0xb81d4c(0x237)],'handler':(_0x1094f5,_0x5b3ba8)=>{const _0x3951eb=_0xb81d4c;if(!(_0x5b3ba8!=null&&_0x5b3ba8[_0x3951eb(0x1f0)][_0x3951eb(0x24d)]()))return!0x1;let _0x9220f6=K(_0x1094f5,_0x5b3ba8[_0x3951eb(0x1a1)],'');if(!_0x9220f6)return!0x1;let _0x46f302=ft(_0x5b3ba8[_0x3951eb(0x24c)],_0x9220f6[_0x3951eb(0x1c7)],dt(_0x1094f5,_0x9220f6[_0x3951eb(0x1a1)]));if(!_0x46f302)return!0x1;let _0x433bd6=pt(_0x1094f5,_0x9220f6[_0x3951eb(0x1a1)],_0x5b3ba8[_0x3951eb(0x1f0)],_0x5b3ba8[_0x3951eb(0x176)]??[]);if(!_0x433bd6)return!0x1;let _0xd5f0f=mt(_0x9220f6[_0x3951eb(0x1c7)],_0x9220f6[_0x3951eb(0x230)],_0x9220f6[_0x3951eb(0x1a1)]),_0x22f9bb=ht({'documentData':_0x9220f6[_0x3951eb(0x1ba)],'resource':_0x9220f6[_0x3951eb(0x1e3)],'rangeId':_0xd5f0f,'config':{'formula':_0x5b3ba8['formula'],..._0x5b3ba8[_0x3951eb(0x19e)]?{'numberFormat':_0x5b3ba8[_0x3951eb(0x19e)]}:null},'startOffset':_0x46f302[_0x3951eb(0x1b9)],'endOffset':_0x46f302['endOffset']});if(!_0x22f9bb)return!0x1;let _0x54df7f=_0x5f5499(_0x1094f5,_0x9220f6['unitId'],_0x433bd6);return!_0x54df7f||!q({'accessor':_0x1094f5,'document':_0x9220f6[_0x3951eb(0x1d6)],'unitId':_0x9220f6['unitId'],'trigger':z['id'],'rangeId':_0xd5f0f,'previousResource':_0x9220f6[_0x3951eb(0x1e3)],'nextResource':_0x22f9bb[_0x3951eb(0x1ec)],'previousDocumentData':_0x9220f6['documentData'],'nextDocumentData':_0x22f9bb[_0x3951eb(0x200)],'cursorOffset':_0x22f9bb[_0x3951eb(0x173)],'externalMutations':_0x54df7f})?!0x1:{'rangeId':_0xd5f0f,'startOffset':_0x22f9bb['cursorOffset']-0x1,'endOffset':_0x22f9bb[_0x3951eb(0x173)]};}},B={'id':'docs-formula.command.update','type':_0x599208[_0xb81d4c(0x237)],'handler':(_0x6de73,_0x41ef41)=>{const _0x44f417=_0xb81d4c;if(!(_0x41ef41!=null&&_0x41ef41[_0x44f417(0x1dd)])||!_0x41ef41[_0x44f417(0x1f0)][_0x44f417(0x24d)]())return!0x1;let _0xab7eb=K(_0x6de73,_0x41ef41[_0x44f417(0x1a1)],''),_0x34569a=_0xab7eb==null?void 0x0:_0xab7eb['model']['getFormula'](_0xab7eb[_0x44f417(0x1a1)],_0x41ef41[_0x44f417(0x1dd)]),_0x55c09f=_0xab7eb?T(_0xab7eb[_0x44f417(0x1ba)][_0x44f417(0x1c7)],_0x41ef41[_0x44f417(0x1dd)]):void 0x0;if(!_0xab7eb||!_0x34569a||!_0x55c09f)return!0x1;let _0x2ceccc=pt(_0x6de73,_0xab7eb[_0x44f417(0x1a1)],_0x41ef41['formula'],_0x41ef41['externalReferences']??[]);if(!_0x2ceccc)return!0x1;let _0x2d8d91=_0x5f5499(_0x6de73,_0xab7eb[_0x44f417(0x1a1)],_0x2ceccc);if(!_0x2d8d91)return!0x1;let _0x477b8d=St(_0xab7eb[_0x44f417(0x1e3)]);return _0x477b8d[_0x44f417(0x18d)][_0x41ef41[_0x44f417(0x1dd)]]={'formula':_0x41ef41['formula'],..._0x41ef41[_0x44f417(0x19e)]?{'numberFormat':_0x41ef41[_0x44f417(0x19e)]}:_0x34569a['numberFormat']?{'numberFormat':_0x34569a['numberFormat']}:null},q({'accessor':_0x6de73,'document':_0xab7eb['document'],'unitId':_0xab7eb[_0x44f417(0x1a1)],'trigger':B['id'],'rangeId':_0x41ef41['rangeId'],'previousResource':_0xab7eb[_0x44f417(0x1e3)],'nextResource':_0x477b8d,'cursorOffset':_0x55c09f[_0x44f417(0x218)]+0x1,'externalMutations':_0x2d8d91});}},V={'id':'docs-formula.command.set-number-format','type':_0x599208[_0xb81d4c(0x237)],'handler':(_0x220b6e,_0x1e5374)=>{const _0x4016bf=_0xb81d4c;if(!(_0x1e5374!=null&&_0x1e5374[_0x4016bf(0x1dd)]))return!0x1;let _0x2bcae1=K(_0x220b6e,_0x1e5374[_0x4016bf(0x1a1)],''),_0x428977=_0x2bcae1==null?void 0x0:_0x2bcae1[_0x4016bf(0x230)][_0x4016bf(0x1d9)](_0x2bcae1[_0x4016bf(0x1a1)],_0x1e5374[_0x4016bf(0x1dd)]),_0x3a4079=_0x2bcae1?T(_0x2bcae1[_0x4016bf(0x1ba)][_0x4016bf(0x1c7)],_0x1e5374[_0x4016bf(0x1dd)]):void 0x0;if(!_0x2bcae1||!_0x428977||!_0x3a4079)return!0x1;let _0x143eb7=St(_0x2bcae1[_0x4016bf(0x1e3)]);return _0x143eb7[_0x4016bf(0x18d)][_0x1e5374[_0x4016bf(0x1dd)]]={..._0x428977,..._0x1e5374[_0x4016bf(0x19e)]?{'numberFormat':_0x1e5374[_0x4016bf(0x19e)]}:null},_0x1e5374[_0x4016bf(0x19e)]||delete _0x143eb7[_0x4016bf(0x18d)][_0x1e5374[_0x4016bf(0x1dd)]][_0x4016bf(0x19e)],q({'accessor':_0x220b6e,'document':_0x2bcae1[_0x4016bf(0x1d6)],'unitId':_0x2bcae1[_0x4016bf(0x1a1)],'trigger':V['id'],'rangeId':_0x1e5374[_0x4016bf(0x1dd)],'previousResource':_0x2bcae1[_0x4016bf(0x1e3)],'nextResource':_0x143eb7,'cursorOffset':_0x3a4079[_0x4016bf(0x218)]+0x1,'externalMutations':{}});}},H={'id':_0xb81d4c(0x1d2),'type':_0x599208[_0xb81d4c(0x237)],'handler':(_0x29ac9a,_0x589338)=>G(_0x29ac9a,_0x589338,'',H['id'])},U={'id':'docs-formula.command.replace-with-text','type':_0x599208[_0xb81d4c(0x237)],'handler':(_0x3d550d,_0x3f60a5)=>G(_0x3d550d,_0x3f60a5,(_0x3f60a5==null?void 0x0:_0x3f60a5[_0xb81d4c(0x24e)])??'',U['id'])},W={'id':_0xb81d4c(0x1f1),'type':_0x599208[_0xb81d4c(0x237)],'handler':(_0x4a7557,_0x599aba)=>{const _0x58e830=_0xb81d4c;if(!(_0x599aba!=null&&_0x599aba[_0x58e830(0x1dd)]))return!0x1;let _0x473bc8=K(_0x4a7557,_0x599aba[_0x58e830(0x1a1)],'');if(!_0x473bc8)return!0x1;let _0x32bf70=_0x4a7557[_0x58e830(0x202)](P)[_0x58e830(0x227)]({'unitId':_0x473bc8['unitId'],'rangeId':_0x599aba[_0x58e830(0x1dd)]});return _0x32bf70?G(_0x4a7557,_0x599aba,_0x32bf70[_0x58e830(0x24e)],W['id']):!0x1;}};function G(_0x43e2ec,_0x54b02d,_0x527baa,_0x1b8b90){const _0x50eb7b=_0xb81d4c;if(!(_0x54b02d!=null&&_0x54b02d[_0x50eb7b(0x1dd)]))return!0x1;let _0x4ee9b3=K(_0x43e2ec,_0x54b02d[_0x50eb7b(0x1a1)],'');if(!_0x4ee9b3)return!0x1;let _0x231770=ze({'documentData':_0x4ee9b3[_0x50eb7b(0x1ba)],'resource':_0x4ee9b3[_0x50eb7b(0x1e3)],'rangeId':_0x54b02d[_0x50eb7b(0x1dd)],'text':_0x527baa});return _0x231770?q({'accessor':_0x43e2ec,'document':_0x4ee9b3[_0x50eb7b(0x1d6)],'unitId':_0x4ee9b3[_0x50eb7b(0x1a1)],'trigger':_0x1b8b90,'rangeId':_0x54b02d[_0x50eb7b(0x1dd)],'previousResource':_0x4ee9b3['resource'],'nextResource':_0x231770[_0x50eb7b(0x1ec)],'previousDocumentData':_0x4ee9b3[_0x50eb7b(0x1ba)],'nextDocumentData':_0x231770[_0x50eb7b(0x200)],'cursorOffset':_0x231770[_0x50eb7b(0x173)],'externalMutations':{}}):!0x1;}function K(_0x32e53e,_0xb502f3,_0x1388b6){const _0x3a0124=_0xb81d4c;if(_0x1388b6)return null;let _0x18ac5f=_0x32e53e[_0x3a0124(0x202)](_0x1616da),_0x2c75ea=(_0xb502f3?_0x18ac5f[_0x3a0124(0x17d)](_0xb502f3,_0x19d9b2[_0x3a0124(0x1e7)]):_0x18ac5f['getCurrentUnitOfType'](_0x19d9b2['UNIVER_DOC']))??null;if(!_0x2c75ea)return null;let _0x33de2a=_0x2c75ea[_0x3a0124(0x1e5)](),_0x32978c=_0x33de2a['body'];if(_0x33de2a[_0x3a0124(0x201)]||!_0x32978c)return null;let _0x2acddf=_0x32e53e[_0x3a0124(0x202)](j);return _0x2acddf[_0x3a0124(0x20b)](_0x2c75ea[_0x3a0124(0x22a)]())?null:{'document':_0x2c75ea,'body':_0x32978c,'documentData':_0x33de2a,'model':_0x2acddf,'resource':_0x2acddf[_0x3a0124(0x1db)](_0x2c75ea[_0x3a0124(0x22a)]())??b(),'unitId':_0x2c75ea[_0x3a0124(0x22a)]()};}function dt(_0x4bb60a,_0x8ebef4){const _0x2f5d8b=_0xb81d4c;var _0x26dbe2;return(_0x26dbe2=_0x4bb60a[_0x2f5d8b(0x202)](_0x3e1e9b)[_0x2f5d8b(0x179)]({'subUnitId':_0x8ebef4,'unitId':_0x8ebef4}))==null?void 0x0:_0x26dbe2[0x0];}function ft(_0x2b9bff,_0x20e555,_0x333c11){const _0x2ef887=_0xb81d4c;if((_0x2b9bff==null?void 0x0:_0x2b9bff[_0x2ef887(0x178)])===_0x2ef887(0x1fb)){var _0x4d2b6c;let _0x4feb8d=((_0x4d2b6c=_0x20e555[_0x2ef887(0x1de)])==null?void 0x0:_0x4d2b6c['filter'](_0x273f5b=>_0x273f5b[_0x2ef887(0x1b5)]===_0x2b9bff[_0x2ef887(0x1b5)]))??[];if(_0x4feb8d['length']!==0x1)return null;let _0x59505c=_0x4feb8d[0x0],_0x1f63f8=_0x13c716(_0x20e555,_0x59505c),_0x509174=_0x59505c['startIndex']-_0x1f63f8,_0xbdf274=_0x2b9bff[_0x2ef887(0x17b)]===_0x2ef887(0x205)?_0x509174:_0x2b9bff[_0x2ef887(0x17b)];if(!Number[_0x2ef887(0x197)](_0xbdf274)||_0xbdf274<0x0||_0xbdf274>_0x509174)return null;let _0x2e5e44=_0x1f63f8+_0xbdf274;return{'startOffset':_0x2e5e44,'endOffset':_0x2e5e44};}if((_0x2b9bff==null?void 0x0:_0x2b9bff[_0x2ef887(0x178)])==='range')return!Number[_0x2ef887(0x197)](_0x2b9bff[_0x2ef887(0x1b9)])||!Number[_0x2ef887(0x197)](_0x2b9bff[_0x2ef887(0x253)])?null:{'startOffset':Math[_0x2ef887(0x1aa)](_0x2b9bff[_0x2ef887(0x1b9)],_0x2b9bff[_0x2ef887(0x253)]),'endOffset':Math['max'](_0x2b9bff[_0x2ef887(0x1b9)],_0x2b9bff['endOffset'])};let _0x35133e=(_0x2b9bff==null?void 0x0:_0x2b9bff['type'])===_0x2ef887(0x1e4)?_0x2b9bff[_0x2ef887(0x1e4)]:_0x333c11;return!_0x35133e||_0x35133e[_0x2ef887(0x256)]?null:{'startOffset':Math[_0x2ef887(0x1aa)](_0x35133e[_0x2ef887(0x1b9)],_0x35133e['endOffset']),'endOffset':Math['max'](_0x35133e[_0x2ef887(0x1b9)],_0x35133e[_0x2ef887(0x253)])};}function pt(_0xaa7eb1,_0x433895,_0x3774ff,_0x5e0386){const _0x2d59df=_0xb81d4c;let _0x49bc2e=_0xaa7eb1['get'](_0x276a14),_0x233cf7=_0x3774ff[_0x2d59df(0x246)]('=')?_0x3774ff['slice'](0x1):_0x3774ff,_0x529c02=_0x49bc2e[_0x2d59df(0x1da)](_0x233cf7);if(!_0x529c02)return null;let _0xcba271=_0xaa7eb1[_0x2d59df(0x202)](_0x2be22c),_0xb07ebf=_0x1fc472({'qualifiers':_0x1bd1bb(_0x529c02),'explicitReferences':_0x5e0386??[],'resolveBinding':_0x19f523=>_0xcba271[_0x2d59df(0x16d)](_0x433895,_0x19f523)});return _0xb07ebf[_0x2d59df(0x16f)]===_0x2d59df(0x19b)?_0xb07ebf[_0x2d59df(0x190)]:null;}function mt(_0x20eb7f,_0x4c0947,_0x42ad43){const _0x20fd64=_0xb81d4c;var _0x7ad084;let _0x138a90=_0x5d3298(0x6);for(;_0x20eb7f!=null&&(_0x7ad084=_0x20eb7f['customRanges'])!=null&&_0x7ad084['some'](_0x5671b4=>_0x5671b4[_0x20fd64(0x1dd)]===_0x138a90)||_0x4c0947[_0x20fd64(0x1d9)](_0x42ad43,_0x138a90);)_0x138a90=_0x5d3298(0x6);return _0x138a90;}function ht(_0x31bc57){try{return Le(_0x31bc57);}catch(_0x4d477c){if(_0x4d477c instanceof C)return null;throw _0x4d477c;}}function gt(_0xaa4a08){const _0x180734=_0xb81d4c;let _0x227f62=_0xaa4a08[_0x180734(0x16a)]&&_0xaa4a08[_0x180734(0x200)]?vt(_0xaa4a08[_0x180734(0x1d6)],_0xaa4a08[_0x180734(0x1a1)],_0xaa4a08['previousDocumentData'],_0xaa4a08['nextDocumentData'],_0xaa4a08['cursorOffset'],_0xaa4a08[_0x180734(0x22d)]):null;return _0xaa4a08[_0x180734(0x16a)]&&_0xaa4a08[_0x180734(0x200)]&&!_0x227f62?null:{'documentRedo':_0x227f62,'resourceRedo':{'id':L['id'],'params':{'unitId':_0xaa4a08['unitId'],'resource':_0xaa4a08['nextResource']}},'resourceUndo':{'id':L['id'],'params':{'unitId':_0xaa4a08['unitId'],'resource':_0xaa4a08[_0x180734(0x210)]}}};}function _t(_0x2125ee,_0xeb1641,_0x2c64d2,_0x4d0128){const _0x245032=_0xb81d4c;_0x4d0128['pushUndoRedo']({'id':_0x2125ee[_0x245032(0x22d)]+':'+_0x2125ee['rangeId'],'unitID':_0x2125ee['unitId'],'redoMutations':[..._0x2125ee['externalMutations'][_0x245032(0x1b3)]?[_0x2125ee[_0x245032(0x1dc)][_0x245032(0x1b3)]]:[],..._0xeb1641[_0x245032(0x21e)]?[_0xeb1641['documentRedo']]:[],_0xeb1641[_0x245032(0x1ea)]],'undoMutations':[_0xeb1641[_0x245032(0x235)],..._0x2c64d2?[_0x2c64d2]:[],..._0x2125ee[_0x245032(0x1dc)]['undoMutation']?[_0x2125ee[_0x245032(0x1dc)]['undoMutation']]:[]]});}function q(_0x41ea6f){const _0x5bcade=_0xb81d4c;let _0x437d28=_0x41ea6f[_0x5bcade(0x1a3)][_0x5bcade(0x202)](_0x41ce44),_0x213c04=_0x41ea6f['accessor'][_0x5bcade(0x202)](_0x5273cf),_0x12c581=_0x41ea6f[_0x5bcade(0x1a3)]['get'](_0x3e1e9b),_0xeffec4=gt(_0x41ea6f);if(!_0xeffec4)return!0x1;let _0x43c927=!0x1,_0x217c2a=null,_0x25b60d=!0x1;try{if(_0x41ea6f[_0x5bcade(0x1dc)][_0x5bcade(0x1b3)]){if(!_0x437d28['syncExecuteCommand'](_0x41ea6f['externalMutations'][_0x5bcade(0x1b3)]['id'],_0x41ea6f[_0x5bcade(0x1dc)][_0x5bcade(0x1b3)][_0x5bcade(0x1fe)]))return!0x1;_0x43c927=!0x0;}if(_0xeffec4['documentRedo']){let _0x2b6d28=_0x437d28[_0x5bcade(0x162)](_0xeffec4[_0x5bcade(0x21e)]['id'],_0xeffec4[_0x5bcade(0x21e)][_0x5bcade(0x1fe)]);if(!_0x2b6d28)return J(_0x437d28,_0x41ea6f[_0x5bcade(0x1dc)],_0x43c927),!0x1;_0x217c2a={'id':_0x3ff622['id'],'params':{..._0x2b6d28,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'segmentId':''}};}if(!_0x437d28[_0x5bcade(0x162)](_0xeffec4[_0x5bcade(0x1ea)]['id'],_0xeffec4[_0x5bcade(0x1ea)][_0x5bcade(0x1fe)]))return yt(_0x437d28,_0x217c2a),J(_0x437d28,_0x41ea6f['externalMutations'],_0x43c927),!0x1;_0x25b60d=!0x0,_t(_0x41ea6f,_0xeffec4,_0x217c2a,_0x213c04);}catch(_0x4c527c){throw _0x25b60d&&_0x437d28[_0x5bcade(0x162)](_0xeffec4[_0x5bcade(0x235)]['id'],_0xeffec4[_0x5bcade(0x235)][_0x5bcade(0x1fe)]),yt(_0x437d28,_0x217c2a),J(_0x437d28,_0x41ea6f[_0x5bcade(0x1dc)],_0x43c927),_0x4c527c;}return _0x12c581[_0x5bcade(0x1f5)]([{'startOffset':_0x41ea6f[_0x5bcade(0x173)],'endOffset':_0x41ea6f['cursorOffset'],'segmentId':''}],{'unitId':_0x41ea6f[_0x5bcade(0x1a1)],'subUnitId':_0x41ea6f[_0x5bcade(0x1a1)]},!0x1,{[_0x507f67]:!0x0}),!0x0;}function vt(_0x4178dc,_0x595ebb,_0x2c72dd,_0x5e0dcb,_0x3026c5,_0x3aeb31){let _0x50468b=bt(_0x2c72dd,_0x5e0dcb,_0x197963(_0x4178dc,''));return _0x50468b?{'id':_0x3ff622['id'],'params':{'unitId':_0x595ebb,'actions':_0x50468b,'segmentId':'','textRanges':[{'startOffset':_0x3026c5,'endOffset':_0x3026c5,'collapsed':!0x0,'segmentId':''}],'isEditing':!0x1,'noHistory':!0x0,'noNeedSetTextRange':!0x0,'trigger':_0x3aeb31}}:null;}function yt(_0x4c8cd5,_0x58cb31){const _0x3ba71a=_0xb81d4c;_0x58cb31&&_0x4c8cd5[_0x3ba71a(0x162)](_0x58cb31['id'],_0x58cb31[_0x3ba71a(0x1fe)]);}function J(_0x1e1c3e,_0x90ee72,_0x37cd79){const _0x424323=_0xb81d4c;_0x37cd79&&_0x90ee72['undoMutation']&&_0x1e1c3e[_0x424323(0x162)](_0x90ee72[_0x424323(0x224)]['id'],_0x90ee72[_0x424323(0x224)][_0x424323(0x1fe)]);}function bt(_0x52a999,_0x2f59b3,_0x120365){const _0x39924e=_0xb81d4c;let _0x2441bc=_0x52a999[_0x39924e(0x1c7)],_0x2db7f3=_0x2f59b3['body'],_0x4fa2cf=xt(_0x2441bc==null?void 0x0:_0x2441bc[_0x39924e(0x1cb)],_0x2db7f3==null?void 0x0:_0x2db7f3[_0x39924e(0x1cb)]);if(!_0x4fa2cf||!_0x2db7f3)return null;let _0xd58b1a=new _0x7ff3ce();return _0xd58b1a[_0x39924e(0x180)](_0x4fa2cf[_0x39924e(0x206)]),_0x4fa2cf[_0x39924e(0x177)]>0x0&&_0xd58b1a[_0x39924e(0x188)](_0x4fa2cf[_0x39924e(0x177)],_0x312eb6(_0x2db7f3,_0x4fa2cf[_0x39924e(0x206)],_0x4fa2cf[_0x39924e(0x206)]+_0x4fa2cf['insertLength'],!0x1)),_0x4fa2cf['deleteLength']>0x0&&_0xd58b1a[_0x39924e(0x207)](_0x4fa2cf['deleteLength']),_0x5b1be5[_0x39924e(0x1f3)]()[_0x39924e(0x1fd)](_0xd58b1a[_0x39924e(0x185)](),_0x120365);}function xt(_0xafd00e,_0x3c0d71){const _0x251ee8=_0xb81d4c;if(_0xafd00e==null||_0x3c0d71==null||_0xafd00e===_0x3c0d71)return null;let _0x8f1c1d=0x0;for(;_0x8f1c1d<_0xafd00e[_0x251ee8(0x1f2)]&&_0x8f1c1d<_0x3c0d71['length']&&_0xafd00e[_0x8f1c1d]===_0x3c0d71[_0x8f1c1d];)_0x8f1c1d+=0x1;let _0x5b59bb=_0xafd00e[_0x251ee8(0x1f2)],_0xf85c47=_0x3c0d71[_0x251ee8(0x1f2)];for(;_0x5b59bb>_0x8f1c1d&&_0xf85c47>_0x8f1c1d&&_0xafd00e[_0x5b59bb-0x1]===_0x3c0d71[_0xf85c47-0x1];)--_0x5b59bb,--_0xf85c47;return{'start':_0x8f1c1d,'deleteLength':_0x5b59bb-_0x8f1c1d,'insertLength':_0xf85c47-_0x8f1c1d};}function _0x43e1(_0x1d453b,_0x3f404c){_0x1d453b=_0x1d453b-0x161;const _0x3d4ac1=_0x3d4a();let _0x43e1c8=_0x3d4ac1[_0x1d453b];return _0x43e1c8;}function St(_0x1e5356){const _0xe85b52=_0xb81d4c;return{'formulas':Object['fromEntries'](Object[_0xe85b52(0x18e)](_0x1e5356[_0xe85b52(0x18d)])[_0xe85b52(0x259)](([_0x5785f3,_0x1368a8])=>[_0x5785f3,{..._0x1368a8,..._0x1368a8[_0xe85b52(0x19e)]?{'numberFormat':{..._0x1368a8[_0xe85b52(0x19e)]}}:null,..._0x1368a8[_0xe85b52(0x1ed)]?{'lastValue':{..._0x1368a8['lastValue']}}:null}]))};}let Y=class extends _0xf99196{constructor(_0x21f5ab,_0x3a53e4,_0x29fc29,_0x3ce3da){const _0x4ace72=_0xb81d4c;super(),this[_0x4ace72(0x166)]=_0x21f5ab,this['_commandService']=_0x3a53e4,this[_0x4ace72(0x1b1)]=_0x29fc29,this[_0x4ace72(0x1df)]=_0x3ce3da,A(this,'_pendingUnitIds',new Set()),A(this,_0x4ace72(0x1a2),!0x1),A(this,_0x4ace72(0x163),!0x1),this[_0x4ace72(0x166)][_0x4ace72(0x1ca)](_0x19d9b2[_0x4ace72(0x1e7)])[_0x4ace72(0x171)](_0x50f8e3=>this[_0x4ace72(0x1df)][_0x4ace72(0x182)](_0x50f8e3)),this[_0x4ace72(0x16e)](this[_0x4ace72(0x1b1)][_0x4ace72(0x1ac)][_0x4ace72(0x204)](({unitId:_0x4a9667})=>this[_0x4ace72(0x1ad)](_0x4a9667))),this[_0x4ace72(0x16e)](this[_0x4ace72(0x166)][_0x4ace72(0x24b)][_0x4ace72(0x204)](({unit:_0x82e290})=>{const _0x4b7ddd=_0x4ace72;_0x82e290[_0x4b7ddd(0x178)]===_0x19d9b2[_0x4b7ddd(0x1e7)]&&this[_0x4b7ddd(0x1e2)](_0x82e290[_0x4b7ddd(0x22a)]());})),this[_0x4ace72(0x16e)](this[_0x4ace72(0x166)][_0x4ace72(0x24f)][_0x4ace72(0x204)](_0x883489=>{const _0x4f143e=_0x4ace72;this[_0x4f143e(0x1df)]['unregisterUnit'](_0x883489[_0x4f143e(0x22a)]());})),this[_0x4ace72(0x16e)](this[_0x4ace72(0x23d)][_0x4ace72(0x231)](_0x98b949=>{const _0x35fc93=_0x4ace72;if(_0x98b949['id']===_0x3ff622['id']&&Ct(_0x98b949[_0x35fc93(0x1fe)])){let _0x374fcf=_0x98b949[_0x35fc93(0x1fe)];_0x374fcf[_0x35fc93(0x256)]||this[_0x35fc93(0x1ad)](_0x374fcf[_0x35fc93(0x1a1)]);}}));}[_0xb81d4c(0x21f)](){const _0x52d1b7=_0xb81d4c;this[_0x52d1b7(0x163)]=!0x0,super['dispose']();}[_0xb81d4c(0x1e2)](_0x5cff1f){const _0x10f508=_0xb81d4c;this['_pendingUnitIds'][_0x10f508(0x1d3)](_0x5cff1f),this[_0x10f508(0x1a2)]||(this['_syncScheduled']=!0x0,queueMicrotask(()=>{const _0x54a297=_0x10f508;if(this['_syncScheduled']=!0x1,this[_0x54a297(0x163)])return;let _0x250e54=Array[_0x54a297(0x1a7)](this['_pendingUnitIds']);this['_pendingUnitIds'][_0x54a297(0x208)](),_0x250e54['forEach'](_0x45c2d0=>this['_syncUnit'](_0x45c2d0));}));}['_syncUnit'](_0x2682af){const _0x202a3f=_0xb81d4c;let _0x8514d7=this[_0x202a3f(0x166)]['getUnit'](_0x2682af,_0x19d9b2['UNIVER_DOC']);_0x8514d7&&this[_0x202a3f(0x1df)][_0x202a3f(0x182)](_0x8514d7);}};Y=N([M(0x0,_0x1616da),M(0x1,_0x41ce44),M(0x2,_0x3abf00(j)),M(0x3,_0x3abf00(P))],Y);function Ct(_0x13dd71){const _0x5e65a1=_0xb81d4c;return typeof _0x13dd71==_0x5e65a1(0x234)&&!!_0x13dd71&&'unitId'in _0x13dd71&&typeof _0x13dd71['unitId']==_0x5e65a1(0x1fc)&&(!(_0x5e65a1(0x256)in _0x13dd71)||_0x13dd71[_0x5e65a1(0x256)]===void 0x0||typeof _0x13dd71[_0x5e65a1(0x256)]==_0x5e65a1(0x1fc));}let X=class extends _0xf99196{constructor(_0x1e3aa9,_0x1685e1){const _0x108c41=_0xb81d4c;super(),this[_0x108c41(0x172)]=_0x1e3aa9,this[_0x108c41(0x254)]=_0x1685e1,this[_0x108c41(0x16e)](this[_0x108c41(0x172)][_0x108c41(0x236)]({'pluginName':y,'businesses':[_0x19d9b2['UNIVER_DOC']],'toJson':_0x42accb=>JSON[_0x108c41(0x1ab)](this['_docFormulaModel']['serialize'](_0x42accb)),'parseJson':_0x32ce26=>JSON[_0x108c41(0x1ae)](_0x32ce26),'onLoad':(_0x4eef6,_0x40d82b)=>{const _0x518ddb=_0x108c41;this[_0x518ddb(0x254)][_0x518ddb(0x1bc)](_0x4eef6,_0x40d82b);},'onUnLoad':_0x351220=>this[_0x108c41(0x254)][_0x108c41(0x241)](_0x351220)}));}};X=N([M(0x0,_0x85b6e7),M(0x1,_0x3abf00(j))],X);var wt='@univerjs-pro/docs-formula',Tt=_0xb81d4c(0x196);const Et={};let Z=class extends _0xf99196{constructor(_0x5bc09d,_0x1ebd7c,_0x95644e){const _0x2e883d=_0xb81d4c;super(),this[_0x2e883d(0x186)]=_0x5bc09d,this['_formulaService']=_0x1ebd7c,this[_0x2e883d(0x16e)](_0x95644e[_0x2e883d(0x195)]({'resolve':(_0x3231ac,_0x477fe9)=>{const _0x11c9c7=_0x2e883d;var _0x3cee8e;return((_0x3cee8e=_0x477fe9[_0x11c9c7(0x1c4)])==null?void 0x0:_0x3cee8e[_0x11c9c7(0x21d)](w)[_0x11c9c7(0x259)](_0x51c626=>({'startOffset':_0x51c626['startIndex'],'endOffset':_0x51c626[_0x11c9c7(0x218)]+0x1,'text':this['resolveFormula'](_0x3231ac,_0x51c626[_0x11c9c7(0x1dd)])})))??[];}})),this[_0x2e883d(0x16e)](this[_0x2e883d(0x219)][_0x2e883d(0x18c)][_0x2e883d(0x204)](({unitId:_0x3ed933})=>{const _0xa55c5d=_0x2e883d;_0x95644e[_0xa55c5d(0x21a)](_0x3ed933);}));}[_0xb81d4c(0x161)](_0x40966f,_0x439f2d){const _0x415ee4=_0xb81d4c;var _0x4778dc;return((_0x4778dc=this[_0x415ee4(0x219)][_0x415ee4(0x227)]({'unitId':_0x40966f,'rangeId':_0x439f2d}))==null?void 0x0:_0x4778dc[_0x415ee4(0x24e)])??'';}[_0xb81d4c(0x1d4)](_0x394249,_0x5413cc,_0x34a0ff){const _0x2e2e9a=_0xb81d4c;var _0x199d8a;let _0x57b282=this['_univerInstanceService'][_0x2e2e9a(0x17d)](_0x394249,_0x19d9b2[_0x2e2e9a(0x1e7)]),_0x3cc96e=_0x57b282==null?void 0x0:_0x57b282[_0x2e2e9a(0x1d7)]();if(!_0x3cc96e)return'';let _0x225777=_0x3cc96e[_0x2e2e9a(0x1cb)][_0x2e2e9a(0x1c6)](_0x5413cc,_0x34a0ff),_0x3dc6a5=((_0x199d8a=_0x3cc96e[_0x2e2e9a(0x1c4)])==null?void 0x0:_0x199d8a[_0x2e2e9a(0x21d)](_0xa98203=>w(_0xa98203)&&_0xa98203[_0x2e2e9a(0x23b)]>=_0x5413cc&&_0xa98203[_0x2e2e9a(0x218)]<_0x34a0ff)[_0x2e2e9a(0x18f)]((_0x4041d4,_0x10de0e)=>_0x10de0e[_0x2e2e9a(0x23b)]-_0x4041d4[_0x2e2e9a(0x23b)]))??[];for(let _0x4fc340 of _0x3dc6a5){let _0x5af6c8=_0x4fc340[_0x2e2e9a(0x23b)]-_0x5413cc,_0x1a9bc0=_0x4fc340['endIndex']-_0x5413cc+0x1;_0x225777=''+_0x225777[_0x2e2e9a(0x1c6)](0x0,_0x5af6c8)+this[_0x2e2e9a(0x161)](_0x394249,_0x4fc340['rangeId'])+_0x225777[_0x2e2e9a(0x1c6)](_0x1a9bc0);}return _0x225777;}[_0xb81d4c(0x1c5)](_0x17f789){return Dt(_0x17f789);}[_0xb81d4c(0x1e8)](_0x3b24af,_0x35dd14,_0x1e014f={}){const _0x2320e5=_0xb81d4c;var _0x239e75;return Be({'id':_0x3b24af,'body':_0x35dd14,'documentStyle':{}},(((_0x239e75=_0x35dd14['customRanges'])==null?void 0x0:_0x239e75[_0x2320e5(0x21d)](w))??[])[_0x2320e5(0x259)](_0x1305ea=>({'rangeId':_0x1305ea[_0x2320e5(0x1dd)],'text':_0x1e014f[_0x1305ea['rangeId']]??this[_0x2320e5(0x161)](_0x3b24af,_0x1305ea['rangeId'])})))[_0x2320e5(0x1c7)]??{'dataStream':''};}};Z=N([M(0x0,_0x1616da),M(0x1,_0x3abf00(P)),M(0x2,_0x3abf00(_0x5a38c7))],Z);function Dt(_0x5a268e){const _0x201547=_0xb81d4c;var _0x4303e3,_0x40490a;let _0x5a7219=Ot(_0x5a268e),_0x522474=Be(_0x5a268e,(((_0x4303e3=_0x5a268e[_0x201547(0x1c7)])==null||(_0x4303e3=_0x4303e3[_0x201547(0x1c4)])==null?void 0x0:_0x4303e3[_0x201547(0x21d)](w))??[])[_0x201547(0x259)](_0x224d40=>({'rangeId':_0x224d40[_0x201547(0x1dd)],'text':kt(_0x5a7219==null?void 0x0:_0x5a7219['formulas'][_0x224d40['rangeId']])})));return _0x522474[_0x201547(0x1a9)]=(_0x40490a=_0x522474[_0x201547(0x1a9)])==null?void 0x0:_0x40490a[_0x201547(0x21d)](_0x26675e=>_0x26675e[_0x201547(0x19a)]!==y),_0x522474;}function Ot(_0x577a6c){const _0x3468dd=_0xb81d4c;var _0x2c1450;let _0x59c4c5=(_0x2c1450=_0x577a6c[_0x3468dd(0x1a9)])==null||(_0x2c1450=_0x2c1450['find'](_0xedaa2e=>_0xedaa2e[_0x3468dd(0x19a)]===_0x3468dd(0x164)))==null?void 0x0:_0x2c1450[_0x3468dd(0x199)];if(_0x59c4c5)try{let _0x56a1a4=JSON['parse'](_0x59c4c5);return x(_0x56a1a4)?_0x56a1a4:void 0x0;}catch{return;}}function kt(_0x401f70){const _0x84940d=_0xb81d4c;return _0x401f70?_0x157ca0({'lastValue':_0x401f70[_0x84940d(0x1ed)],'numberFormat':_0x401f70[_0x84940d(0x19e)]})[_0x84940d(0x24e)]:'';}let Q=class extends _0xf99196{constructor(_0x2433e0,_0x5cb1a0,_0x122ca0){const _0x91d1ce=_0xb81d4c;super(),this['_formulaService']=_0x2433e0,this[_0x91d1ce(0x1fa)]=_0x5cb1a0,this[_0x91d1ce(0x16e)](_0x122ca0[_0x91d1ce(0x257)](this));}[_0xb81d4c(0x21c)](_0x14c541){const _0x5dc97c=_0xb81d4c;let _0x5e47ad=new Map();for(let _0x4f0119 of this[_0x5dc97c(0x219)][_0x5dc97c(0x1cc)]()){var _0x11494a;if(!this[_0x5dc97c(0x1fa)][_0x5dc97c(0x167)](_0x4f0119[_0x5dc97c(0x1c1)][_0x5dc97c(0x1f0)],_0x4f0119[_0x5dc97c(0x24a)])['eligible'])continue;let _0x20f099=_0xfa1663(_0x4f0119[_0x5dc97c(0x24a)]),_0xb65aec=_0x20f099?_0x4884df(_0x20f099):null;if(!_0xb65aec||At(_0x4f0119['config'][_0x5dc97c(0x1ed)],_0xb65aec))continue;let _0x59d293=_0x5e47ad['get'](_0x4f0119['identity'][_0x5dc97c(0x1a1)])??[];_0x59d293[_0x5dc97c(0x18b)]({'rangeId':_0x4f0119[_0x5dc97c(0x1c0)][_0x5dc97c(0x1dd)],'expectedFormula':_0x4f0119[_0x5dc97c(0x1c1)][_0x5dc97c(0x1f0)],'expectedNumberFormat':(_0x11494a=_0x4f0119['config'][_0x5dc97c(0x19e)])==null?void 0x0:_0x11494a[_0x5dc97c(0x168)],'expectedReferenceRevision':_0x4f0119[_0x5dc97c(0x1a0)],'lastValue':_0xb65aec}),_0x5e47ad['set'](_0x4f0119[_0x5dc97c(0x1c0)][_0x5dc97c(0x1a1)],_0x59d293);}return Array[_0x5dc97c(0x1a7)](_0x5e47ad,([_0x582a94,_0x61e498])=>({'id':R['id'],'params':{'unitId':_0x582a94,'updates':_0x61e498}}));}};Q=N([M(0x0,_0x3abf00(P)),M(0x1,_0x3abf00(_0x5bfff4)),M(0x2,_0x3abf00(_0x21c0ca))],Q);function At(_0x40955e,_0x39d32a){const _0x254e8c=_0xb81d4c;return(_0x40955e==null?void 0x0:_0x40955e['v'])===_0x39d32a['v']&&(_0x40955e==null?void 0x0:_0x40955e['t'])===_0x39d32a['t']&&(_0x40955e==null?void 0x0:_0x40955e[_0x254e8c(0x168)])===_0x39d32a[_0x254e8c(0x168)];}let $=class extends _0x4cfe43{constructor(_0xa8a5a3=Et,_0x12c8bb,_0x1933e7,_0x3aa101){const _0x42078c=_0xb81d4c;super(),this[_0x42078c(0x189)]=_0xa8a5a3,this[_0x42078c(0x1c9)]=_0x12c8bb,this[_0x42078c(0x23d)]=_0x1933e7,this[_0x42078c(0x22e)]=_0x3aa101;let {..._0x8a0417}=_0x57fe01({},Et,this[_0x42078c(0x189)]);this[_0x42078c(0x22e)][_0x42078c(0x19d)](_0x42078c(0x23f),_0x8a0417);}[_0xb81d4c(0x250)](){const _0x4a1151=_0xb81d4c;this[_0x4a1151(0x1c9)][_0x4a1151(0x1d3)]([j]),this['_injector'][_0x4a1151(0x1d3)]([P]),this[_0x4a1151(0x1c9)][_0x4a1151(0x1d3)]([X]),this[_0x4a1151(0x1c9)][_0x4a1151(0x1d3)]([Y]),this[_0x4a1151(0x1c9)][_0x4a1151(0x1d3)]([Q]),this[_0x4a1151(0x1c9)][_0x4a1151(0x1d3)]([Z]),_0x59a954(this[_0x4a1151(0x1c9)],[[j],[X],[Y],[Q],[Z]]),[lt,ut,L,R,z,B,V,H,U,W][_0x4a1151(0x171)](_0x334343=>this['disposeWithMe'](this[_0x4a1151(0x23d)][_0x4a1151(0x19f)](_0x334343)));}};A($,_0xb81d4c(0x18a),y),A($,_0xb81d4c(0x169),wt),A($,'version',Tt),A($,_0xb81d4c(0x178),_0x19d9b2[_0xb81d4c(0x1e7)]),$=N([_0x415d13(_0x46999f,_0x3c9e4a,_0x59ac81),M(0x1,_0x3abf00(_0x38221f)),M(0x2,_0x41ce44),M(0x3,_0x212f05)],$);export{W as ConvertDocFormulaToTextCommand,je as DOC_FORMULA_CUSTOM_RANGE_KIND,Me as DOC_FORMULA_OBJECT_REPLACEMENT,y as DOC_FORMULA_PLUGIN,Z as DocFormulaDisplayTextService,Y as DocFormulaLifecycleController,j as DocFormulaModel,X as DocFormulaResourceController,ot as DocFormulaResultStatus,P as DocFormulaService,z as InsertDocFormulaCommand,C as InvalidDocFormulaInsertRangeError,H as RemoveDocFormulaCommand,ut as RemoveDocFormulaMutation,U as ReplaceDocFormulaWithTextCommand,R as SetDocFormulaLastValuesMutation,lt as SetDocFormulaMutation,V as SetDocFormulaNumberFormatCommand,L as SetDocFormulaResourceMutation,$ as UniverDocsFormulaPlugin,B as UpdateDocFormulaCommand,Ve as assertSafeDocFormulaInsertRange,Le as buildInsertDocFormulaActions,ze as buildRemoveDocFormulaActions,Re as buildUpdateDocFormulaActions,b as createEmptyDocFormulaResource,Dt as degradeDocFormulaDocumentData,T as findDocFormulaRange,Ne as isDocFormulaConfig,w as isDocFormulaRange,x as isDocFormulaResource,Pe as isFormulaLastValue};
|
package/lib/umd/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x9d65(_0xeadeea,_0x2b10f3){_0xeadeea=_0xeadeea-0x19b;var _0x174b7d=_0x174b();var _0x9d6541=_0x174b7d[_0xeadeea];return _0x9d6541;}(function(_0x68b65a,_0x362da4){var _0x3f82e1=_0x9d65,_0x373ebc=_0x68b65a();while(!![]){try{var _0x3a685c=parseInt(_0x3f82e1(0x1f0))/0x1*(-parseInt(_0x3f82e1(0x1b2))/0x2)+-parseInt(_0x3f82e1(0x1e9))/0x3+parseInt(_0x3f82e1(0x1a4))/0x4*(-parseInt(_0x3f82e1(0x1d9))/0x5)+-parseInt(_0x3f82e1(0x1c8))/0x6*(parseInt(_0x3f82e1(0x1ce))/0x7)+-parseInt(_0x3f82e1(0x1ad))/0x8+-parseInt(_0x3f82e1(0x1ef))/0x9*(parseInt(_0x3f82e1(0x19e))/0xa)+parseInt(_0x3f82e1(0x1b1))/0xb;if(_0x3a685c===_0x362da4)break;else _0x373ebc['push'](_0x373ebc['shift']());}catch(_0x57b9c6){_0x373ebc['push'](_0x373ebc['shift']());}}}(_0x174b,0x94c59),function(_0x1de50f,_0x1b3f1e){var _0x5a9603=_0x9d65;typeof exports=='object'&&typeof module<'u'?_0x1b3f1e(exports,require('@univerjs-pro/docs-formula'),require('@univerjs/core'),require('@univerjs/docs/facade')):typeof define==_0x5a9603(0x1bd)&&define[_0x5a9603(0x1a8)]?define([_0x5a9603(0x1a2),'@univerjs-pro/docs-formula',_0x5a9603(0x1de),_0x5a9603(0x1c6)],_0x1b3f1e):(_0x1de50f=typeof globalThis<'u'?globalThis:_0x1de50f||self,_0x1b3f1e(_0x1de50f[_0x5a9603(0x1c7)]={},_0x1de50f['UniverProDocsFormula'],_0x1de50f['UniverCore'],_0x1de50f[_0x5a9603(0x1d2)]));}(this,function(_0x43838a,_0xf14625,_0x1977d8,_0x56ce29){var _0x58ab09=_0x9d65;Object[_0x58ab09(0x1a1)](_0x43838a,Symbol['toStringTag'],{'value':_0x58ab09(0x1a6)});function _0x177acf(_0x44c110,_0x2e1e21){return function(_0x44f224,_0x24ec64){_0x2e1e21(_0x44f224,_0x24ec64,_0x44c110);};}function _0x266900(_0x2ba033,_0x25caf2,_0x5ca426,_0x98986d){var _0x1a4d1a=_0x58ab09,_0x1da20f=arguments[_0x1a4d1a(0x1e4)],_0x1fc5a1=_0x1da20f<0x3?_0x25caf2:_0x98986d===null?_0x98986d=Object[_0x1a4d1a(0x1af)](_0x25caf2,_0x5ca426):_0x98986d,_0x26327d;if(typeof Reflect==_0x1a4d1a(0x1ab)&&typeof Reflect[_0x1a4d1a(0x1f5)]=='function')_0x1fc5a1=Reflect['decorate'](_0x2ba033,_0x25caf2,_0x5ca426,_0x98986d);else{for(var _0x2ba453=_0x2ba033[_0x1a4d1a(0x1e4)]-0x1;_0x2ba453>=0x0;_0x2ba453--)(_0x26327d=_0x2ba033[_0x2ba453])&&(_0x1fc5a1=(_0x1da20f<0x3?_0x26327d(_0x1fc5a1):_0x1da20f>0x3?_0x26327d(_0x25caf2,_0x5ca426,_0x1fc5a1):_0x26327d(_0x25caf2,_0x5ca426))||_0x1fc5a1);}return _0x1da20f>0x3&&_0x1fc5a1&&Object[_0x1a4d1a(0x1a1)](_0x25caf2,_0x5ca426,_0x1fc5a1),_0x1fc5a1;}let _0x4943ed=class{constructor(_0x448ac9,_0x364440,_0x5cbe1f,_0x5d38de,_0x2d24c1,_0x8b86ca){var _0x247212=_0x58ab09;this[_0x247212(0x1aa)]=_0x448ac9,this['_rangeId']=_0x364440,this[_0x247212(0x1e0)]=_0x5cbe1f,this[_0x247212(0x1d6)]=_0x5d38de,this[_0x247212(0x1e5)]=_0x2d24c1,this['_univerInstanceService']=_0x8b86ca;}['getId'](){return this['_rangeId'];}[_0x58ab09(0x1cd)](){var _0x232de2=_0x58ab09;let _0x588447=this[_0x232de2(0x1c9)]();return _0x588447?{'endOffset':_0x588447[_0x232de2(0x1fd)]+0x1,'rangeId':_0x588447[_0x232de2(0x1ea)],'startOffset':_0x588447['startIndex']}:null;}[_0x58ab09(0x1ac)](){var _0x2f0460=_0x58ab09,_0x656ea5;return((_0x656ea5=this['_model'][_0x2f0460(0x1ac)](this['_unitId'],this[_0x2f0460(0x1f1)]))==null?void 0x0:_0x656ea5['formula'])??'';}[_0x58ab09(0x1c3)](){var _0x5b6d24=_0x58ab09;return this['_model'][_0x5b6d24(0x1ac)](this['_unitId'],this[_0x5b6d24(0x1f1)])??null;}['getResult'](){var _0x1e923c=_0x58ab09;return this['_service'][_0x1e923c(0x1a0)]({'unitId':this[_0x1e923c(0x1aa)],'rangeId':this[_0x1e923c(0x1f1)]})??null;}[_0x58ab09(0x1b9)](){var _0x89808f=_0x58ab09;let _0x2d2d9c=this[_0x89808f(0x1cd)](),_0x339efc=this['getConfig'](),_0x143b26=this[_0x89808f(0x1a0)]();return!_0x2d2d9c||!_0x339efc||!_0x143b26?null:{..._0x2d2d9c,'config':_0x339efc,'formula':_0x339efc[_0x89808f(0x1a5)],'result':_0x143b26,'type':_0x89808f(0x1a5)};}[_0x58ab09(0x1cf)](_0x2f486b){var _0x5f4cbb=_0x58ab09;return this[_0x5f4cbb(0x1e0)][_0x5f4cbb(0x1f2)](_0xf14625[_0x5f4cbb(0x1b3)]['id'],{'externalReferences':_0x2f486b[_0x5f4cbb(0x1ca)],'formula':_0x2f486b[_0x5f4cbb(0x1a5)],'numberFormat':_0x2f486b[_0x5f4cbb(0x19c)],'rangeId':this[_0x5f4cbb(0x1f1)],'unitId':this[_0x5f4cbb(0x1aa)]});}[_0x58ab09(0x1b0)](_0x29fd19){var _0x24edb0=_0x58ab09;return this[_0x24edb0(0x1e0)]['syncExecuteCommand'](_0xf14625[_0x24edb0(0x19f)]['id'],{'numberFormat':_0x29fd19,'rangeId':this[_0x24edb0(0x1f1)],'unitId':this['_unitId']});}[_0x58ab09(0x1cc)](){var _0x46f3a3=_0x58ab09;return this[_0x46f3a3(0x1e0)]['syncExecuteCommand'](_0xf14625[_0x46f3a3(0x1df)]['id'],{'rangeId':this[_0x46f3a3(0x1f1)],'unitId':this[_0x46f3a3(0x1aa)]});}[_0x58ab09(0x1dd)](_0x409be4){var _0x1322bc=_0x58ab09;return this[_0x1322bc(0x1e0)][_0x1322bc(0x1f2)](_0xf14625[_0x1322bc(0x1f8)]['id'],{'rangeId':this[_0x1322bc(0x1f1)],'text':_0x409be4,'unitId':this['_unitId']});}[_0x58ab09(0x1f3)](){var _0x52c855=_0x58ab09;return this['_commandService'][_0x52c855(0x1f2)](_0xf14625[_0x52c855(0x1e1)]['id'],{'rangeId':this[_0x52c855(0x1f1)],'unitId':this[_0x52c855(0x1aa)]});}['_getCustomRange'](){var _0x18b694=_0x58ab09,_0x2a58ec;let _0x3747e4=this[_0x18b694(0x1be)][_0x18b694(0x1dc)](this[_0x18b694(0x1aa)],_0x1977d8[_0x18b694(0x1ec)]['UNIVER_DOC']);return _0x3747e4==null||(_0x2a58ec=_0x3747e4[_0x18b694(0x1fa)]()[_0x18b694(0x1c2)])==null||(_0x2a58ec=_0x2a58ec[_0x18b694(0x1ee)])==null?void 0x0:_0x2a58ec['find'](_0x2fa301=>_0x2fa301[_0x18b694(0x1ea)]===this[_0x18b694(0x1f1)]&&(0x0,_0xf14625[_0x18b694(0x1d0)])(_0x2fa301));}};_0x4943ed=_0x266900([_0x177acf(0x2,_0x1977d8['ICommandService']),_0x177acf(0x3,(0x0,_0x1977d8[_0x58ab09(0x1c1)])(_0xf14625['DocFormulaModel'])),_0x177acf(0x4,(0x0,_0x1977d8[_0x58ab09(0x1c1)])(_0xf14625['DocFormulaService'])),_0x177acf(0x5,_0x1977d8[_0x58ab09(0x1d4)])],_0x4943ed);function _0x4cdd18(_0x4b1b87){'@babel/helpers - typeof';var _0x1df1d1=_0x58ab09;return _0x4cdd18=typeof Symbol=='function'&&typeof Symbol[_0x1df1d1(0x1e2)]=='symbol'?function(_0x9bd9fa){return typeof _0x9bd9fa;}:function(_0x365d24){var _0x39b6e0=_0x1df1d1;return _0x365d24&&typeof Symbol==_0x39b6e0(0x1bd)&&_0x365d24[_0x39b6e0(0x1a3)]===Symbol&&_0x365d24!==Symbol[_0x39b6e0(0x1ed)]?_0x39b6e0(0x1d1):typeof _0x365d24;},_0x4cdd18(_0x4b1b87);}function _0x1c8abb(_0x15e9aa,_0x1c7d29){var _0x3f73f7=_0x58ab09;if(_0x4cdd18(_0x15e9aa)!='object'||!_0x15e9aa)return _0x15e9aa;var _0x2e9f06;if(typeof Symbol<'u'&&(_0x2e9f06=_0x15e9aa[Symbol[_0x3f73f7(0x1b7)]])!==void 0x0){var _0x505f4b=_0x2e9f06[_0x3f73f7(0x201)](_0x15e9aa,_0x1c7d29||_0x3f73f7(0x1d5));if(_0x4cdd18(_0x505f4b)!='object')return _0x505f4b;throw TypeError(_0x3f73f7(0x202));}return(_0x1c7d29==='string'?String:Number)(_0x15e9aa);}function _0x55d951(_0x166512){var _0x4b0910=_0x58ab09,_0x509e5a=_0x1c8abb(_0x166512,_0x4b0910(0x1bc));return _0x4cdd18(_0x509e5a)==_0x4b0910(0x1d1)?_0x509e5a:_0x509e5a+'';}function _0x9ea2c9(_0x347ded,_0x2cc58b,_0x207136){var _0x71ed1b=_0x58ab09;return(_0x2cc58b=_0x55d951(_0x2cc58b))in _0x347ded?Object[_0x71ed1b(0x1a1)](_0x347ded,_0x2cc58b,{'value':_0x207136,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x347ded[_0x2cc58b]=_0x207136,_0x347ded;}var _0x3726fe=class extends _0x56ce29[_0x58ab09(0x1e3)]{constructor(..._0x3c1fef){var _0x169453=_0x58ab09;super(..._0x3c1fef),_0x9ea2c9(this,_0x169453(0x1a9),void 0x0),_0x9ea2c9(this,_0x169453(0x1d7),void 0x0),_0x9ea2c9(this,_0x169453(0x1b6),void 0x0),_0x9ea2c9(this,_0x169453(0x1a7),void 0x0);}[_0x58ab09(0x1f7)](_0x5de2b0){var _0x584302=_0x58ab09;this['_docsFormulaCommandService']=_0x5de2b0[_0x584302(0x1bf)](_0x1977d8[_0x584302(0x1b8)]),this['_docsFormulaDisplayTextService']=_0x5de2b0[_0x584302(0x1bf)](_0xf14625[_0x584302(0x1e6)]),this[_0x584302(0x1b6)]=_0x5de2b0[_0x584302(0x1bf)](_0xf14625['DocFormulaModel']),this['_docsFormulaResourceLoaderService']=_0x5de2b0['get'](_0x1977d8[_0x584302(0x1d8)]);}[_0x58ab09(0x1f4)](){var _0x47a875=_0x58ab09;return this['_getCompleteRanges']()[_0x47a875(0x1b5)](_0x408793=>this[_0x47a875(0x1c0)](_0x408793['rangeId']));}[_0x58ab09(0x1ac)](_0x54b23d){var _0x14e8ba=_0x58ab09;return this[_0x14e8ba(0x203)]()[_0x14e8ba(0x1fc)](_0x2f2df0=>_0x2f2df0[_0x14e8ba(0x1ea)]===_0x54b23d)?this[_0x14e8ba(0x1c0)](_0x54b23d):null;}[_0x58ab09(0x1cb)](_0x2f5c55){var _0x597bd7=_0x58ab09;let _0x500431=this[_0x597bd7(0x203)]()[_0x597bd7(0x1ff)](_0x343f82=>_0x343f82[_0x597bd7(0x1e8)]<=_0x2f5c55&&_0x2f5c55<=_0x343f82[_0x597bd7(0x1fd)]);return _0x500431?this[_0x597bd7(0x1c0)](_0x500431[_0x597bd7(0x1ea)]):null;}['saveFormulaDisplayTextSnapshot'](){var _0x2d99e0=_0x58ab09;let _0x229b27=this[_0x2d99e0(0x1a7)][_0x2d99e0(0x1f9)](this['id']);if(!_0x229b27)throw Error('Document\x20'+this['id']+'\x20could\x20not\x20be\x20serialized.');return this['_docsFormulaDisplayTextService'][_0x2d99e0(0x19b)](_0x229b27);}['insertFormula'](_0x33781f){var _0x3b227f=_0x58ab09;return this[_0x3b227f(0x1fe)]({'externalReferences':_0x33781f[_0x3b227f(0x1ca)],'formula':_0x33781f[_0x3b227f(0x1a5)],'numberFormat':_0x33781f['numberFormat'],'target':{'type':'range','startOffset':_0x33781f['startOffset'],'endOffset':_0x33781f[_0x3b227f(0x1fb)]},'unitId':this[_0x3b227f(0x1f6)]()});}[_0x58ab09(0x1fe)](_0x3518b7){var _0x36b9d8=_0x58ab09;let _0x1f077c=this[_0x36b9d8(0x1a9)][_0x36b9d8(0x1f2)](_0xf14625['InsertDocFormulaCommand']['id'],_0x3518b7);return _0x1f077c?this[_0x36b9d8(0x1c0)](_0x1f077c[_0x36b9d8(0x1ea)]):null;}[_0x58ab09(0x203)](){var _0x116515=_0x58ab09,_0x3a81aa;let _0xeac36f=this[_0x116515(0x1b6)][_0x116515(0x1f4)](this[_0x116515(0x1f6)]());return((_0x3a81aa=this[_0x116515(0x200)]('')[_0x116515(0x1ee)])==null?void 0x0:_0x3a81aa[_0x116515(0x1eb)](_0x2430a3=>(0x0,_0xf14625['isDocFormulaRange'])(_0x2430a3)&&_0xeac36f[_0x2430a3[_0x116515(0x1ea)]]!=null))??[];}[_0x58ab09(0x1c0)](_0x18a1fe){var _0x2b676e=_0x58ab09;return this[_0x2b676e(0x1e7)]['createInstance'](_0x4943ed,this[_0x2b676e(0x1f6)](),_0x18a1fe);}};_0x56ce29[_0x58ab09(0x1e3)]['extend'](_0x3726fe);var _0x5c3320=class extends _0x56ce29['FDocumentParagraph']{constructor(..._0x56fdbe){var _0x4ae171=_0x58ab09;super(..._0x56fdbe),_0x9ea2c9(this,_0x4ae171(0x1a9),void 0x0);}[_0x58ab09(0x1f7)](_0x4e143c){var _0x394d09=_0x58ab09;this[_0x394d09(0x1a9)]=_0x4e143c['get'](_0x1977d8[_0x394d09(0x1b8)]);}[_0x58ab09(0x1da)](_0x4ad246,_0x2ae563,_0x12bf7f={}){var _0x2c9fc4=_0x58ab09;return this[_0x2c9fc4(0x1fe)](_0x4ad246,_0x2ae563,_0x12bf7f);}['appendFormula'](_0x22269f,_0x37a436={}){var _0x1a2e47=_0x58ab09;return this['_insert'](_0x1a2e47(0x1ae),_0x22269f,_0x37a436);}[_0x58ab09(0x1fe)](_0x2290c2,_0xd1971,_0x26d530){var _0x2173be=_0x58ab09;if(this['getSegmentId']())return null;let _0x10f2aa={'externalReferences':_0x26d530[_0x2173be(0x1ca)],'formula':_0xd1971,'numberFormat':_0x26d530[_0x2173be(0x19c)],'target':{'type':'paragraph','paragraphId':this['getId'](),'position':_0x2290c2},'unitId':this[_0x2173be(0x1bb)][_0x2173be(0x1f6)]()},_0xf4c5c3=this[_0x2173be(0x1a9)][_0x2173be(0x1f2)](_0xf14625[_0x2173be(0x1c5)]['id'],_0x10f2aa);return _0xf4c5c3?this[_0x2173be(0x1e7)]['createInstance'](_0x4943ed,this[_0x2173be(0x1bb)][_0x2173be(0x1f6)](),_0xf4c5c3[_0x2173be(0x1ea)]):null;}};_0x56ce29[_0x58ab09(0x1c4)][_0x58ab09(0x1b4)](_0x5c3320);var _0x4b6d01=class extends _0x56ce29[_0x58ab09(0x1db)]{constructor(..._0x25873c){var _0x5337de=_0x58ab09;super(..._0x25873c),_0x9ea2c9(this,_0x5337de(0x1a9),void 0x0);}[_0x58ab09(0x1f7)](_0xa3218){var _0xdfb257=_0x58ab09;this[_0xdfb257(0x1a9)]=_0xa3218['get'](_0x1977d8[_0xdfb257(0x1b8)]);}[_0x58ab09(0x1ba)](_0x20c1af,_0x2ec1a1={}){var _0x332f2f=_0x58ab09;let {endOffset:_0x451dd4,segmentId:_0x28c14a,startOffset:_0x434a12}=this['getRange']();return _0x28c14a?null:this[_0x332f2f(0x1fe)](_0x434a12,_0x451dd4,_0x20c1af,_0x2ec1a1);}[_0x58ab09(0x1fe)](_0x202737,_0x29f64f,_0x2575fe,_0x50e5dd){var _0x10d5b2=_0x58ab09;let _0x3e7ed2={'externalReferences':_0x50e5dd[_0x10d5b2(0x1ca)],'formula':_0x2575fe,'numberFormat':_0x50e5dd[_0x10d5b2(0x19c)],'target':{'type':'range','startOffset':_0x202737,'endOffset':_0x29f64f},'unitId':this[_0x10d5b2(0x1bb)][_0x10d5b2(0x1f6)]()},_0x2cb70d=this['_docsFormulaCommandService'][_0x10d5b2(0x1f2)](_0xf14625[_0x10d5b2(0x1c5)]['id'],_0x3e7ed2);return _0x2cb70d?this[_0x10d5b2(0x1e7)][_0x10d5b2(0x19d)](_0x4943ed,this[_0x10d5b2(0x1bb)][_0x10d5b2(0x1f6)](),_0x2cb70d[_0x10d5b2(0x1ea)]):null;}};_0x56ce29[_0x58ab09(0x1db)]['extend'](_0x4b6d01),Object[_0x58ab09(0x1a1)](_0x43838a,_0x58ab09(0x1d3),{'enumerable':!0x0,'get':function(){return _0x4943ed;}});}));function _0x174b(){var _0x1188c2=['_docsFormulaResourceLoaderService','amd','_docsFormulaCommandService','_unitId','object','getFormula','128000HoxtPn','end','getOwnPropertyDescriptor','setNumberFormat','49812323jJRKdi','2306qfIURT','UpdateDocFormulaCommand','extend','map','_docsFormulaModel','toPrimitive','ICommandService','describe','replaceWithFormula','_document','string','function','_univerInstanceService','get','_createFormula','Inject','body','getConfig','FDocumentParagraph','InsertDocFormulaCommand','@univerjs/docs/facade','UniverProDocsFormulaFacade','6hOLiYU','_getCustomRange','externalReferences','getFormulaAt','remove','getRange','5743213wPNwZv','update','isDocFormulaRange','symbol','UniverDocsFacade','FDocumentFormula','IUniverInstanceService','default','_model','_docsFormulaDisplayTextService','IResourceLoaderService','367295hNKSvL','insertFormula','FDocumentTextRange','getUnit','replaceWithText','@univerjs/core','RemoveDocFormulaCommand','_commandService','ConvertDocFormulaToTextCommand','iterator','FDocument','length','_service','DocFormulaDisplayTextService','_injector','startIndex','3482415ngExLC','rangeId','filter','UniverInstanceType','prototype','customRanges','808497jVilNS','746LaMxRg','_rangeId','syncExecuteCommand','convertToText','getFormulas','decorate','getId','_initialize','ReplaceDocFormulaWithTextCommand','saveUnit','getSnapshot','endOffset','some','endIndex','_insert','find','getBody','call','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','_getCompleteRanges','degradeDocumentData','numberFormat','createInstance','110mPliOQ','SetDocFormulaNumberFormatCommand','getResult','defineProperty','exports','constructor','4RpUkxW','formula','Module'];_0x174b=function(){return _0x1188c2;};return _0x174b();}
|
|
1
|
+
function _0x1a45(_0x262dec,_0x3668b9){_0x262dec=_0x262dec-0x89;var _0x675d45=_0x675d();var _0x1a45ad=_0x675d45[_0x262dec];return _0x1a45ad;}function _0x675d(){var _0xe8c955=['_document','defineProperty','_docsFormulaDisplayTextService','syncExecuteCommand','_initialize','16BzBKyH','body','getFormulaAt','UniverInstanceType','get','string','DocFormulaDisplayTextService','102330cpAJHM','getSnapshot','59735PdCUQm','_injector','SetDocFormulaNumberFormatCommand','_createFormula','@univerjs/core','ConvertDocFormulaToTextCommand','getOwnPropertyDescriptor','_unitId','symbol','FDocument','_getCompleteRanges','amd','1505126TFzpZj','describe','getRange','object','UniverProDocsFormula','2zPDXhd','InsertDocFormulaCommand','DocFormulaModel','UpdateDocFormulaCommand','6104PYidLR','228677QXmMbi','saveUnit','getId','appendFormula','startIndex','143gzwuxR','length','_model','remove','Inject','getUnit','Module','FDocumentFormula','default','_insert','UniverDocsFacade','replaceWithText','FDocumentParagraph','decorate','IResourceLoaderService','replaceWithFormula','@@toPrimitive\x20must\x20return\x20a\x20primitive\x20value.','FDocumentTextRange','range','357gDEEBg','toPrimitive','getConfig','iterator','_service','IUniverInstanceService','getFormula','_docsFormulaCommandService','convertToText','12PfaCyg','insertFormula','numberFormat','endOffset','createInstance','\x20could\x20not\x20be\x20serialized.','externalReferences','endIndex','rangeId','_docsFormulaResourceLoaderService','@univerjs-pro/docs-formula','map','some','_docsFormulaModel','find','formula','function','isDocFormulaRange','getSegmentId','filter','setNumberFormat','getResult','11107733xvgqSD','_rangeId','_univerInstanceService','673362inwhLx','customRanges','_getCustomRange','extend','_commandService','RemoveDocFormulaCommand','42pyNAuB','DocFormulaService','ICommandService','@univerjs/docs/facade'];_0x675d=function(){return _0xe8c955;};return _0x675d();}(function(_0x12a7d0,_0x108a2d){var _0x56c20b=_0x1a45,_0x21196e=_0x12a7d0();while(!![]){try{var _0x5288d5=-parseInt(_0x56c20b(0xe0))/0x1*(parseInt(_0x56c20b(0xdb))/0x2)+-parseInt(_0x56c20b(0x90))/0x3*(parseInt(_0x56c20b(0xdf))/0x4)+-parseInt(_0x56c20b(0xca))/0x5*(parseInt(_0x56c20b(0xb8))/0x6)+-parseInt(_0x56c20b(0xd6))/0x7+parseInt(_0x56c20b(0xc1))/0x8*(parseInt(_0x56c20b(0xb2))/0x9)+-parseInt(_0x56c20b(0xc8))/0xa*(parseInt(_0x56c20b(0xe5))/0xb)+parseInt(_0x56c20b(0x99))/0xc*(parseInt(_0x56c20b(0xaf))/0xd);if(_0x5288d5===_0x108a2d)break;else _0x21196e['push'](_0x21196e['shift']());}catch(_0x3b135d){_0x21196e['push'](_0x21196e['shift']());}}}(_0x675d,0x27952),function(_0x681579,_0x39aa66){var _0x522443=_0x1a45;typeof exports=='object'&&typeof module<'u'?_0x39aa66(exports,require('@univerjs-pro/docs-formula'),require('@univerjs/core'),require('@univerjs/docs/facade')):typeof define=='function'&&define[_0x522443(0xd5)]?define(['exports',_0x522443(0xa3),_0x522443(0xce),_0x522443(0xbb)],_0x39aa66):(_0x681579=typeof globalThis<'u'?globalThis:_0x681579||self,_0x39aa66(_0x681579['UniverProDocsFormulaFacade']={},_0x681579[_0x522443(0xda)],_0x681579['UniverCore'],_0x681579[_0x522443(0xef)]));}(this,function(_0xe157df,_0x5f3330,_0x334c14,_0x2dbc04){var _0xb43a8=_0x1a45;Object[_0xb43a8(0xbd)](_0xe157df,Symbol['toStringTag'],{'value':_0xb43a8(0xeb)});function _0x1ade55(_0x4f7643,_0x520929){return function(_0x2994ab,_0x417cd7){_0x520929(_0x2994ab,_0x417cd7,_0x4f7643);};}function _0x2b138d(_0x210a12,_0x5dc95a,_0x394010,_0x1d09ee){var _0x4d6739=_0xb43a8,_0x49fa24=arguments[_0x4d6739(0xe6)],_0x18fb3b=_0x49fa24<0x3?_0x5dc95a:_0x1d09ee===null?_0x1d09ee=Object[_0x4d6739(0xd0)](_0x5dc95a,_0x394010):_0x1d09ee,_0x5598a2;if(typeof Reflect=='object'&&typeof Reflect[_0x4d6739(0x8a)]==_0x4d6739(0xa9))_0x18fb3b=Reflect[_0x4d6739(0x8a)](_0x210a12,_0x5dc95a,_0x394010,_0x1d09ee);else{for(var _0x6b88=_0x210a12[_0x4d6739(0xe6)]-0x1;_0x6b88>=0x0;_0x6b88--)(_0x5598a2=_0x210a12[_0x6b88])&&(_0x18fb3b=(_0x49fa24<0x3?_0x5598a2(_0x18fb3b):_0x49fa24>0x3?_0x5598a2(_0x5dc95a,_0x394010,_0x18fb3b):_0x5598a2(_0x5dc95a,_0x394010))||_0x18fb3b);}return _0x49fa24>0x3&&_0x18fb3b&&Object[_0x4d6739(0xbd)](_0x5dc95a,_0x394010,_0x18fb3b),_0x18fb3b;}let _0x2e9911=class{constructor(_0x34e407,_0x19497a,_0x3fa634,_0xd04f1b,_0x491e93,_0x7fc52f){var _0x3fb78a=_0xb43a8;this[_0x3fb78a(0xd1)]=_0x34e407,this[_0x3fb78a(0xb0)]=_0x19497a,this[_0x3fb78a(0xb6)]=_0x3fa634,this[_0x3fb78a(0xe7)]=_0xd04f1b,this[_0x3fb78a(0x94)]=_0x491e93,this[_0x3fb78a(0xb1)]=_0x7fc52f;}[_0xb43a8(0xe2)](){var _0x243505=_0xb43a8;return this[_0x243505(0xb0)];}['getRange'](){let _0x2584fb=this['_getCustomRange']();return _0x2584fb?{'endOffset':_0x2584fb['endIndex']+0x1,'rangeId':_0x2584fb['rangeId'],'startOffset':_0x2584fb['startIndex']}:null;}[_0xb43a8(0x96)](){var _0x19a758=_0xb43a8,_0x4995fd;return((_0x4995fd=this[_0x19a758(0xe7)][_0x19a758(0x96)](this['_unitId'],this[_0x19a758(0xb0)]))==null?void 0x0:_0x4995fd['formula'])??'';}[_0xb43a8(0x92)](){var _0x9c37e=_0xb43a8;return this['_model'][_0x9c37e(0x96)](this[_0x9c37e(0xd1)],this[_0x9c37e(0xb0)])??null;}[_0xb43a8(0xae)](){var _0x3dfb4f=_0xb43a8;return this[_0x3dfb4f(0x94)][_0x3dfb4f(0xae)]({'unitId':this['_unitId'],'rangeId':this[_0x3dfb4f(0xb0)]})??null;}[_0xb43a8(0xd7)](){var _0x15d096=_0xb43a8;let _0x5e0c58=this['getRange'](),_0x308982=this[_0x15d096(0x92)](),_0x57cbcd=this[_0x15d096(0xae)]();return!_0x5e0c58||!_0x308982||!_0x57cbcd?null:{..._0x5e0c58,'config':_0x308982,'formula':_0x308982['formula'],'result':_0x57cbcd,'type':_0x15d096(0xa8)};}['update'](_0x276d2a){var _0x522124=_0xb43a8;return this[_0x522124(0xb6)][_0x522124(0xbf)](_0x5f3330[_0x522124(0xde)]['id'],{'externalReferences':_0x276d2a[_0x522124(0x9f)],'formula':_0x276d2a[_0x522124(0xa8)],'numberFormat':_0x276d2a[_0x522124(0x9b)],'rangeId':this['_rangeId'],'unitId':this[_0x522124(0xd1)]});}[_0xb43a8(0xad)](_0x357320){var _0x14258c=_0xb43a8;return this[_0x14258c(0xb6)][_0x14258c(0xbf)](_0x5f3330[_0x14258c(0xcc)]['id'],{'numberFormat':_0x357320,'rangeId':this[_0x14258c(0xb0)],'unitId':this[_0x14258c(0xd1)]});}[_0xb43a8(0xe8)](){var _0x1f48dc=_0xb43a8;return this[_0x1f48dc(0xb6)][_0x1f48dc(0xbf)](_0x5f3330[_0x1f48dc(0xb7)]['id'],{'rangeId':this[_0x1f48dc(0xb0)],'unitId':this['_unitId']});}[_0xb43a8(0xf0)](_0x346c54){var _0x25e6f6=_0xb43a8;return this[_0x25e6f6(0xb6)][_0x25e6f6(0xbf)](_0x5f3330['ReplaceDocFormulaWithTextCommand']['id'],{'rangeId':this[_0x25e6f6(0xb0)],'text':_0x346c54,'unitId':this[_0x25e6f6(0xd1)]});}[_0xb43a8(0x98)](){var _0x35d4ae=_0xb43a8;return this[_0x35d4ae(0xb6)][_0x35d4ae(0xbf)](_0x5f3330[_0x35d4ae(0xcf)]['id'],{'rangeId':this[_0x35d4ae(0xb0)],'unitId':this[_0x35d4ae(0xd1)]});}[_0xb43a8(0xb4)](){var _0x1a038f=_0xb43a8,_0x94f837;let _0x25c797=this[_0x1a038f(0xb1)][_0x1a038f(0xea)](this['_unitId'],_0x334c14[_0x1a038f(0xc4)]['UNIVER_DOC']);return _0x25c797==null||(_0x94f837=_0x25c797[_0x1a038f(0xc9)]()[_0x1a038f(0xc2)])==null||(_0x94f837=_0x94f837['customRanges'])==null?void 0x0:_0x94f837['find'](_0x23026d=>_0x23026d[_0x1a038f(0xa1)]===this['_rangeId']&&(0x0,_0x5f3330['isDocFormulaRange'])(_0x23026d));}};_0x2e9911=_0x2b138d([_0x1ade55(0x2,_0x334c14[_0xb43a8(0xba)]),_0x1ade55(0x3,(0x0,_0x334c14[_0xb43a8(0xe9)])(_0x5f3330[_0xb43a8(0xdd)])),_0x1ade55(0x4,(0x0,_0x334c14[_0xb43a8(0xe9)])(_0x5f3330[_0xb43a8(0xb9)])),_0x1ade55(0x5,_0x334c14[_0xb43a8(0x95)])],_0x2e9911);function _0x457216(_0x34df49){'@babel/helpers - typeof';var _0x3b2dbc=_0xb43a8;return _0x457216=typeof Symbol==_0x3b2dbc(0xa9)&&typeof Symbol[_0x3b2dbc(0x93)]=='symbol'?function(_0x4a8664){return typeof _0x4a8664;}:function(_0xb59963){var _0x36fbaf=_0x3b2dbc;return _0xb59963&&typeof Symbol=='function'&&_0xb59963['constructor']===Symbol&&_0xb59963!==Symbol['prototype']?_0x36fbaf(0xd2):typeof _0xb59963;},_0x457216(_0x34df49);}function _0x33382d(_0x25d40d,_0x3481fd){var _0x3260cf=_0xb43a8;if(_0x457216(_0x25d40d)!=_0x3260cf(0xd9)||!_0x25d40d)return _0x25d40d;var _0x52240b;if(typeof Symbol<'u'&&(_0x52240b=_0x25d40d[Symbol[_0x3260cf(0x91)]])!==void 0x0){var _0x58fc5e=_0x52240b['call'](_0x25d40d,_0x3481fd||_0x3260cf(0xed));if(_0x457216(_0x58fc5e)!=_0x3260cf(0xd9))return _0x58fc5e;throw TypeError(_0x3260cf(0x8d));}return(_0x3481fd===_0x3260cf(0xc6)?String:Number)(_0x25d40d);}function _0x5c1624(_0xeecdcf){var _0xdedab4=_0xb43a8,_0x46ebf1=_0x33382d(_0xeecdcf,_0xdedab4(0xc6));return _0x457216(_0x46ebf1)==_0xdedab4(0xd2)?_0x46ebf1:_0x46ebf1+'';}function _0x36bed2(_0x77035c,_0x479c57,_0x3c00a6){var _0x23232c=_0xb43a8;return(_0x479c57=_0x5c1624(_0x479c57))in _0x77035c?Object[_0x23232c(0xbd)](_0x77035c,_0x479c57,{'value':_0x3c00a6,'enumerable':!0x0,'configurable':!0x0,'writable':!0x0}):_0x77035c[_0x479c57]=_0x3c00a6,_0x77035c;}var _0x15f93a=class extends _0x2dbc04['FDocument']{constructor(..._0x207c61){var _0x25e481=_0xb43a8;super(..._0x207c61),_0x36bed2(this,_0x25e481(0x97),void 0x0),_0x36bed2(this,_0x25e481(0xbe),void 0x0),_0x36bed2(this,_0x25e481(0xa6),void 0x0),_0x36bed2(this,_0x25e481(0xa2),void 0x0);}['_initialize'](_0x5f54c9){var _0x58f8cd=_0xb43a8;this[_0x58f8cd(0x97)]=_0x5f54c9[_0x58f8cd(0xc5)](_0x334c14[_0x58f8cd(0xba)]),this[_0x58f8cd(0xbe)]=_0x5f54c9[_0x58f8cd(0xc5)](_0x5f3330[_0x58f8cd(0xc7)]),this[_0x58f8cd(0xa6)]=_0x5f54c9[_0x58f8cd(0xc5)](_0x5f3330[_0x58f8cd(0xdd)]),this[_0x58f8cd(0xa2)]=_0x5f54c9['get'](_0x334c14[_0x58f8cd(0x8b)]);}['getFormulas'](){var _0x5111ca=_0xb43a8;return this[_0x5111ca(0xd4)]()[_0x5111ca(0xa4)](_0x44d6cc=>this[_0x5111ca(0xcd)](_0x44d6cc[_0x5111ca(0xa1)]));}['getFormula'](_0x287563){var _0x357b72=_0xb43a8;return this[_0x357b72(0xd4)]()[_0x357b72(0xa5)](_0x5bbdcb=>_0x5bbdcb[_0x357b72(0xa1)]===_0x287563)?this[_0x357b72(0xcd)](_0x287563):null;}[_0xb43a8(0xc3)](_0x162205){var _0x42bc2b=_0xb43a8;let _0x363c6d=this[_0x42bc2b(0xd4)]()[_0x42bc2b(0xa7)](_0x4b6d42=>_0x4b6d42[_0x42bc2b(0xe4)]<=_0x162205&&_0x162205<=_0x4b6d42[_0x42bc2b(0xa0)]);return _0x363c6d?this[_0x42bc2b(0xcd)](_0x363c6d[_0x42bc2b(0xa1)]):null;}['saveFormulaDisplayTextSnapshot'](){var _0x1b8d7d=_0xb43a8;let _0x3db0f7=this[_0x1b8d7d(0xa2)][_0x1b8d7d(0xe1)](this['id']);if(!_0x3db0f7)throw Error('Document\x20'+this['id']+_0x1b8d7d(0x9e));return this[_0x1b8d7d(0xbe)]['degradeDocumentData'](_0x3db0f7);}[_0xb43a8(0x9a)](_0x1ae567){var _0x56ffb1=_0xb43a8;return this[_0x56ffb1(0xee)]({'externalReferences':_0x1ae567['externalReferences'],'formula':_0x1ae567[_0x56ffb1(0xa8)],'numberFormat':_0x1ae567[_0x56ffb1(0x9b)],'target':{'type':_0x56ffb1(0x8f),'startOffset':_0x1ae567['startOffset'],'endOffset':_0x1ae567[_0x56ffb1(0x9c)]},'unitId':this['getId']()});}['_insert'](_0x399813){var _0x2f3c71=_0xb43a8;let _0x52174c=this[_0x2f3c71(0x97)][_0x2f3c71(0xbf)](_0x5f3330[_0x2f3c71(0xdc)]['id'],_0x399813);return _0x52174c?this[_0x2f3c71(0xcd)](_0x52174c['rangeId']):null;}[_0xb43a8(0xd4)](){var _0x2b310c=_0xb43a8,_0x53d74b;let _0x3452a7=this['_docsFormulaModel']['getFormulas'](this[_0x2b310c(0xe2)]());return((_0x53d74b=this['getBody']('')[_0x2b310c(0xb3)])==null?void 0x0:_0x53d74b[_0x2b310c(0xac)](_0x3b183a=>(0x0,_0x5f3330[_0x2b310c(0xaa)])(_0x3b183a)&&_0x3452a7[_0x3b183a['rangeId']]!=null))??[];}[_0xb43a8(0xcd)](_0x2cc982){var _0x14172b=_0xb43a8;return this[_0x14172b(0xcb)][_0x14172b(0x9d)](_0x2e9911,this['getId'](),_0x2cc982);}};_0x2dbc04[_0xb43a8(0xd3)][_0xb43a8(0xb5)](_0x15f93a);var _0x7738d8=class extends _0x2dbc04[_0xb43a8(0x89)]{constructor(..._0x53a6e6){var _0x22f9c9=_0xb43a8;super(..._0x53a6e6),_0x36bed2(this,_0x22f9c9(0x97),void 0x0);}[_0xb43a8(0xc0)](_0x23289b){var _0x4df461=_0xb43a8;this[_0x4df461(0x97)]=_0x23289b[_0x4df461(0xc5)](_0x334c14[_0x4df461(0xba)]);}[_0xb43a8(0x9a)](_0x3f7d6b,_0x2b08d2,_0x93b881={}){var _0x11a8cb=_0xb43a8;return this[_0x11a8cb(0xee)](_0x3f7d6b,_0x2b08d2,_0x93b881);}[_0xb43a8(0xe3)](_0x357108,_0x196440={}){return this['_insert']('end',_0x357108,_0x196440);}[_0xb43a8(0xee)](_0x3046c7,_0x549945,_0x20a952){var _0x4c7983=_0xb43a8;if(this[_0x4c7983(0xab)]())return null;let _0x364ab9={'externalReferences':_0x20a952[_0x4c7983(0x9f)],'formula':_0x549945,'numberFormat':_0x20a952[_0x4c7983(0x9b)],'target':{'type':'paragraph','paragraphId':this[_0x4c7983(0xe2)](),'position':_0x3046c7},'unitId':this[_0x4c7983(0xbc)][_0x4c7983(0xe2)]()},_0x4aa95d=this[_0x4c7983(0x97)]['syncExecuteCommand'](_0x5f3330[_0x4c7983(0xdc)]['id'],_0x364ab9);return _0x4aa95d?this[_0x4c7983(0xcb)][_0x4c7983(0x9d)](_0x2e9911,this['_document'][_0x4c7983(0xe2)](),_0x4aa95d['rangeId']):null;}};_0x2dbc04[_0xb43a8(0x89)][_0xb43a8(0xb5)](_0x7738d8);var _0x400a36=class extends _0x2dbc04['FDocumentTextRange']{constructor(..._0x1b3b5c){var _0xb53303=_0xb43a8;super(..._0x1b3b5c),_0x36bed2(this,_0xb53303(0x97),void 0x0);}['_initialize'](_0x562169){var _0x22c375=_0xb43a8;this['_docsFormulaCommandService']=_0x562169[_0x22c375(0xc5)](_0x334c14['ICommandService']);}[_0xb43a8(0x8c)](_0x207fac,_0x3ac173={}){var _0x7c2ffa=_0xb43a8;let {endOffset:_0x23f786,segmentId:_0x4e78b9,startOffset:_0x574b73}=this[_0x7c2ffa(0xd8)]();return _0x4e78b9?null:this[_0x7c2ffa(0xee)](_0x574b73,_0x23f786,_0x207fac,_0x3ac173);}[_0xb43a8(0xee)](_0x4634a3,_0x118c38,_0x3ff066,_0x428f33){var _0x40eaef=_0xb43a8;let _0xf06810={'externalReferences':_0x428f33[_0x40eaef(0x9f)],'formula':_0x3ff066,'numberFormat':_0x428f33[_0x40eaef(0x9b)],'target':{'type':_0x40eaef(0x8f),'startOffset':_0x4634a3,'endOffset':_0x118c38},'unitId':this[_0x40eaef(0xbc)][_0x40eaef(0xe2)]()},_0x56be2d=this['_docsFormulaCommandService'][_0x40eaef(0xbf)](_0x5f3330[_0x40eaef(0xdc)]['id'],_0xf06810);return _0x56be2d?this['_injector'][_0x40eaef(0x9d)](_0x2e9911,this[_0x40eaef(0xbc)][_0x40eaef(0xe2)](),_0x56be2d[_0x40eaef(0xa1)]):null;}};_0x2dbc04[_0xb43a8(0x8e)][_0xb43a8(0xb5)](_0x400a36),Object[_0xb43a8(0xbd)](_0xe157df,_0xb43a8(0xec),{'enumerable':!0x0,'get':function(){return _0x2e9911;}});}));
|