@univerjs/engine-formula 0.10.4 → 0.10.5

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/es/index.js CHANGED
@@ -3827,7 +3827,7 @@ function Ul(i, a) {
3827
3827
  }
3828
3828
  return i.precision -= e, a;
3829
3829
  }
3830
- var Ve = /* @__PURE__ */ function() {
3830
+ var Ve = /* @__PURE__ */ (function() {
3831
3831
  function i(t, r, n) {
3832
3832
  var s, o = 0, u = t.length;
3833
3833
  for (t = t.slice(); u--; )
@@ -3887,7 +3887,7 @@ var Ve = /* @__PURE__ */ function() {
3887
3887
  }
3888
3888
  return b;
3889
3889
  };
3890
- }();
3890
+ })();
3891
3891
  function J(i, a, e, t) {
3892
3892
  var r, n, s, o, u, c, l, f, h, d = i.constructor;
3893
3893
  e: if (a != null) {
package/lib/index.js CHANGED
@@ -3827,7 +3827,7 @@ function Ul(i, a) {
3827
3827
  }
3828
3828
  return i.precision -= e, a;
3829
3829
  }
3830
- var Ve = /* @__PURE__ */ function() {
3830
+ var Ve = /* @__PURE__ */ (function() {
3831
3831
  function i(t, r, n) {
3832
3832
  var s, o = 0, u = t.length;
3833
3833
  for (t = t.slice(); u--; )
@@ -3887,7 +3887,7 @@ var Ve = /* @__PURE__ */ function() {
3887
3887
  }
3888
3888
  return b;
3889
3889
  };
3890
- }();
3890
+ })();
3891
3891
  function J(i, a, e, t) {
3892
3892
  var r, n, s, o, u, c, l, f, h, d = i.constructor;
3893
3893
  e: if (a != null) {
package/lib/umd/facade.js CHANGED
@@ -1 +1 @@
1
- (function(r,o){typeof exports=="object"&&typeof module<"u"?o(exports,require("@univerjs/core/facade"),require("@univerjs/core"),require("@univerjs/engine-formula"),require("rxjs")):typeof define=="function"&&define.amd?define(["exports","@univerjs/core/facade","@univerjs/core","@univerjs/engine-formula","rxjs"],o):(r=typeof globalThis<"u"?globalThis:r||self,o(r.UniverEngineFormulaFacade={},r.UniverCoreFacade,r.UniverCore,r.UniverEngineFormula,r.rxjs))})(this,function(r,o,u,a,s){"use strict";var f=Object.getOwnPropertyDescriptor,v=(c,e,t,i)=>{for(var n=i>1?void 0:i?f(e,t):e,d=c.length-1,m;d>=0;d--)(m=c[d])&&(n=m(n)||n);return n},l=(c,e)=>(t,i)=>e(t,i,c);r.FFormula=class extends o.FBase{constructor(e,t,i,n){super(),this._commandService=e,this._injector=t,this._lexerTreeBuilder=i,this._configService=n,this._initialize()}_initialize(){}get lexerTreeBuilder(){return this._lexerTreeBuilder}moveFormulaRefOffset(e,t,i,n){return this._lexerTreeBuilder.moveFormulaRefOffset(e,t,i,n)}sequenceNodesBuilder(e){return this._lexerTreeBuilder.sequenceNodesBuilder(e)||[]}executeCalculation(){this._commandService.executeCommand(a.SetFormulaCalculationStartMutation.id,{commands:[],forceCalculation:!0},{onlyLocal:!0})}stopCalculation(){this._commandService.executeCommand(a.SetFormulaCalculationStopMutation.id,{})}calculationStart(e){return this._commandService.onCommandExecuted(t=>{if(t.id===a.SetFormulaCalculationStartMutation.id){const i=t.params;e(i.forceCalculation)}})}calculationEnd(e){return this._commandService.onCommandExecuted(t=>{if(t.id!==a.SetFormulaCalculationNotificationMutation.id)return;const i=t.params;i.functionsExecutedState!==void 0&&e(i.functionsExecutedState)})}whenComputingCompleteAsync(e){const t=this._injector.get(a.GlobalComputingStatusService);return t.computingStatus?Promise.resolve(!0):s.firstValueFrom(s.race(t.computingStatus$.pipe(s.filter(i=>i)),s.timer(e!=null?e:3e4).pipe(s.map(()=>!1))))}onCalculationEnd(){return new Promise((e,t)=>{const i=setTimeout(()=>{t(new Error("Calculation end timeout"))},3e4),n=this.calculationEnd(()=>{clearTimeout(i),n.dispose(),e()})})}calculationProcessing(e){return this._commandService.onCommandExecuted(t=>{if(t.id!==a.SetFormulaCalculationNotificationMutation.id)return;const i=t.params;i.stageInfo!==void 0&&e(i.stageInfo)})}setMaxIteration(e){this._configService.setConfig(a.ENGINE_FORMULA_CYCLE_REFERENCE_COUNT,e)}},r.FFormula=v([l(0,u.Inject(u.ICommandService)),l(1,u.Inject(u.Injector)),l(2,u.Inject(a.LexerTreeBuilder)),l(3,u.IConfigService)],r.FFormula);class C extends o.FUniver{getFormula(){return this._injector.createInstance(r.FFormula)}}o.FUniver.extend(C),Object.defineProperty(r,Symbol.toStringTag,{value:"Module"})});
1
+ (function(r,o){typeof exports=="object"&&typeof module<"u"?o(exports,require("@univerjs/core/facade"),require("@univerjs/core"),require("@univerjs/engine-formula"),require("rxjs")):typeof define=="function"&&define.amd?define(["exports","@univerjs/core/facade","@univerjs/core","@univerjs/engine-formula","rxjs"],o):(r=typeof globalThis<"u"?globalThis:r||self,o(r.UniverEngineFormulaFacade={},r.UniverCoreFacade,r.UniverCore,r.UniverEngineFormula,r.rxjs))})(this,(function(r,o,u,a,s){"use strict";var f=Object.getOwnPropertyDescriptor,v=(c,e,t,i)=>{for(var n=i>1?void 0:i?f(e,t):e,d=c.length-1,m;d>=0;d--)(m=c[d])&&(n=m(n)||n);return n},l=(c,e)=>(t,i)=>e(t,i,c);r.FFormula=class extends o.FBase{constructor(e,t,i,n){super(),this._commandService=e,this._injector=t,this._lexerTreeBuilder=i,this._configService=n,this._initialize()}_initialize(){}get lexerTreeBuilder(){return this._lexerTreeBuilder}moveFormulaRefOffset(e,t,i,n){return this._lexerTreeBuilder.moveFormulaRefOffset(e,t,i,n)}sequenceNodesBuilder(e){return this._lexerTreeBuilder.sequenceNodesBuilder(e)||[]}executeCalculation(){this._commandService.executeCommand(a.SetFormulaCalculationStartMutation.id,{commands:[],forceCalculation:!0},{onlyLocal:!0})}stopCalculation(){this._commandService.executeCommand(a.SetFormulaCalculationStopMutation.id,{})}calculationStart(e){return this._commandService.onCommandExecuted(t=>{if(t.id===a.SetFormulaCalculationStartMutation.id){const i=t.params;e(i.forceCalculation)}})}calculationEnd(e){return this._commandService.onCommandExecuted(t=>{if(t.id!==a.SetFormulaCalculationNotificationMutation.id)return;const i=t.params;i.functionsExecutedState!==void 0&&e(i.functionsExecutedState)})}whenComputingCompleteAsync(e){const t=this._injector.get(a.GlobalComputingStatusService);return t.computingStatus?Promise.resolve(!0):s.firstValueFrom(s.race(t.computingStatus$.pipe(s.filter(i=>i)),s.timer(e!=null?e:3e4).pipe(s.map(()=>!1))))}onCalculationEnd(){return new Promise((e,t)=>{const i=setTimeout(()=>{t(new Error("Calculation end timeout"))},3e4),n=this.calculationEnd(()=>{clearTimeout(i),n.dispose(),e()})})}calculationProcessing(e){return this._commandService.onCommandExecuted(t=>{if(t.id!==a.SetFormulaCalculationNotificationMutation.id)return;const i=t.params;i.stageInfo!==void 0&&e(i.stageInfo)})}setMaxIteration(e){this._configService.setConfig(a.ENGINE_FORMULA_CYCLE_REFERENCE_COUNT,e)}},r.FFormula=v([l(0,u.Inject(u.ICommandService)),l(1,u.Inject(u.Injector)),l(2,u.Inject(a.LexerTreeBuilder)),l(3,u.IConfigService)],r.FFormula);class C extends o.FUniver{getFormula(){return this._injector.createInstance(r.FFormula)}}o.FUniver.extend(C),Object.defineProperty(r,Symbol.toStringTag,{value:"Module"})}));