@odoo/o-spreadsheet 19.3.15 → 19.3.16

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.
@@ -2,9 +2,9 @@
2
2
  /**
3
3
  * This file is generated by o-spreadsheet build tools. Do not edit it.
4
4
  * @see https://github.com/odoo/o-spreadsheet
5
- * @version 19.3.15
6
- * @date 2026-08-10T12:32:40.247Z
7
- * @hash 25f760e
5
+ * @version 19.3.16
6
+ * @date 2026-08-12T09:15:31.627Z
7
+ * @hash 464be42
8
8
  */
9
9
 
10
10
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
@@ -4744,6 +4744,9 @@ var FunctionRegistry = class extends Registry {
4744
4744
  }
4745
4745
  };
4746
4746
  const functionRegistry = new FunctionRegistry();
4747
+ /** Formulas using one of these functions are never squished: they are always exported
4748
+ * as a full formula string, and they don't become the base formula of the next cells. */
4749
+ const NonSquishableFunctionRegistry = new Registry();
4747
4750
 
4748
4751
  //#endregion
4749
4752
  //#region src/types/locale.ts
@@ -49864,7 +49867,8 @@ var Squisher = class {
49864
49867
  * The result of this method is:
49865
49868
  * - if the cell is not a formula, returns the content as is and resets the base formula
49866
49869
  * - if the cell is a formula:
49867
- * - if there is no previous formula, or the normalized formula is different from the previous one, resets the base formula to this one and returns the full formula string
49870
+ * - if there is no previous formula, or the normalized formula is different from the previous one or it contains blacklisted functions (see NonSquishableFunctionRegistry),
49871
+ * resets the base formula to this one and returns the full formula string
49868
49872
  * - else, compares the literal values and range dependencies to the previous formula, and for each parameter:
49869
49873
  * - for numbers: returns a relative change (+N or -N) if possible, else the full number or "=" if unchanged
49870
49874
  * - for strings: returns the full string if changed, else "="
@@ -49872,6 +49876,10 @@ var Squisher = class {
49872
49876
  * */
49873
49877
  squish(cell, forSheetId) {
49874
49878
  if (cell.isFormula) {
49879
+ if (NonSquishableFunctionRegistry.getAll().some((functionName) => cell.compiledFormula.usesSymbol(functionName))) {
49880
+ this.resetBaseFormula();
49881
+ return cell.compiledFormula.toFormulaString(this.getters, this.rangeToStringOptions);
49882
+ }
49875
49883
  let numbers = [];
49876
49884
  let strings = [];
49877
49885
  let references = [];
@@ -61237,7 +61245,7 @@ var Session = class extends EventBus {
61237
61245
  }
61238
61246
  message = {
61239
61247
  ...message,
61240
- commands: this.commandSquisher.squish(revision.commands)
61248
+ commands: revision.commands
61241
61249
  };
61242
61250
  }
61243
61251
  if (this.isReplayingInitialRevisions) throw new Error(`Trying to send a new revision while replaying initial revision. This can lead to endless dispatches every time the spreadsheet is open.
@@ -84696,7 +84704,8 @@ const registries = {
84696
84704
  supportedPivotPositionalFormulaRegistry,
84697
84705
  pivotToFunctionValueRegistry,
84698
84706
  migrationStepRegistry,
84699
- chartJsExtensionRegistry
84707
+ chartJsExtensionRegistry,
84708
+ NonSquishableFunctionRegistry
84700
84709
  };
84701
84710
  const helpers = {
84702
84711
  arg,
@@ -84949,6 +84958,6 @@ exports.stores = stores;
84949
84958
  exports.tokenColors = tokenColors;
84950
84959
  exports.tokenize = tokenize;
84951
84960
 
84952
- __info__.version = "19.3.15";
84953
- __info__.date = "2026-08-10T12:32:40.247Z";
84954
- __info__.hash = "25f760e";
84961
+ __info__.version = "19.3.16";
84962
+ __info__.date = "2026-08-12T09:15:31.627Z";
84963
+ __info__.hash = "464be42";
@@ -2,9 +2,9 @@
2
2
  /*
3
3
  * This file is generated by o-spreadsheet build tools. Do not edit it.
4
4
  * @see https://github.com/odoo/o-spreadsheet
5
- * @version 19.3.15
6
- * @date 2026-08-10T12:32:41.948Z
7
- * @hash 25f760e
5
+ * @version 19.3.16
6
+ * @date 2026-08-12T09:15:33.329Z
7
+ * @hash 464be42
8
8
  */
9
9
  :root {
10
10
  --os-gray-100: light-dark(#f9fafb, #1b1d26);
@@ -2,9 +2,9 @@
2
2
  /**
3
3
  * This file is generated by o-spreadsheet build tools. Do not edit it.
4
4
  * @see https://github.com/odoo/o-spreadsheet
5
- * @version 19.3.15
6
- * @date 2026-08-10T12:32:40.247Z
7
- * @hash 25f760e
5
+ * @version 19.3.16
6
+ * @date 2026-08-12T09:15:31.627Z
7
+ * @hash 464be42
8
8
  */
9
9
 
10
10
  import { App, Component, blockDom, markRaw, onMounted, onPatched, onWillPatch, onWillStart, onWillUnmount, onWillUpdateProps, status, toRaw, useChildSubEnv, useComponent, useEffect, useEnv, useExternalListener, useRef, useState, useSubEnv, whenReady, xml } from "@odoo/owl";
@@ -4743,6 +4743,9 @@ var FunctionRegistry = class extends Registry {
4743
4743
  }
4744
4744
  };
4745
4745
  const functionRegistry = new FunctionRegistry();
4746
+ /** Formulas using one of these functions are never squished: they are always exported
4747
+ * as a full formula string, and they don't become the base formula of the next cells. */
4748
+ const NonSquishableFunctionRegistry = new Registry();
4746
4749
 
4747
4750
  //#endregion
4748
4751
  //#region src/types/locale.ts
@@ -49863,7 +49866,8 @@ var Squisher = class {
49863
49866
  * The result of this method is:
49864
49867
  * - if the cell is not a formula, returns the content as is and resets the base formula
49865
49868
  * - if the cell is a formula:
49866
- * - if there is no previous formula, or the normalized formula is different from the previous one, resets the base formula to this one and returns the full formula string
49869
+ * - if there is no previous formula, or the normalized formula is different from the previous one or it contains blacklisted functions (see NonSquishableFunctionRegistry),
49870
+ * resets the base formula to this one and returns the full formula string
49867
49871
  * - else, compares the literal values and range dependencies to the previous formula, and for each parameter:
49868
49872
  * - for numbers: returns a relative change (+N or -N) if possible, else the full number or "=" if unchanged
49869
49873
  * - for strings: returns the full string if changed, else "="
@@ -49871,6 +49875,10 @@ var Squisher = class {
49871
49875
  * */
49872
49876
  squish(cell, forSheetId) {
49873
49877
  if (cell.isFormula) {
49878
+ if (NonSquishableFunctionRegistry.getAll().some((functionName) => cell.compiledFormula.usesSymbol(functionName))) {
49879
+ this.resetBaseFormula();
49880
+ return cell.compiledFormula.toFormulaString(this.getters, this.rangeToStringOptions);
49881
+ }
49874
49882
  let numbers = [];
49875
49883
  let strings = [];
49876
49884
  let references = [];
@@ -61052,7 +61060,7 @@ var Session = class extends EventBus {
61052
61060
  }
61053
61061
  message = {
61054
61062
  ...message,
61055
- commands: this.commandSquisher.squish(revision.commands)
61063
+ commands: revision.commands
61056
61064
  };
61057
61065
  }
61058
61066
  if (this.isReplayingInitialRevisions) throw new Error(`Trying to send a new revision while replaying initial revision. This can lead to endless dispatches every time the spreadsheet is open.
@@ -84511,7 +84519,8 @@ const registries = {
84511
84519
  supportedPivotPositionalFormulaRegistry,
84512
84520
  pivotToFunctionValueRegistry,
84513
84521
  migrationStepRegistry,
84514
- chartJsExtensionRegistry
84522
+ chartJsExtensionRegistry,
84523
+ NonSquishableFunctionRegistry
84515
84524
  };
84516
84525
  const helpers = {
84517
84526
  arg,
@@ -84706,6 +84715,6 @@ const chartHelpers = {
84706
84715
  //#endregion
84707
84716
  export { AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, CellErrorType, ClientDisconnectedError, CommandResult, CompiledFormula, CorePlugin, CoreViewPlugin, DEFAULT_LOCALE, DEFAULT_LOCALES, DispatchResult, EvaluationError, LocalTransportService, Model, PivotRuntimeDefinition, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, SpreadsheetPivotTable, UIPlugin, __info__, addFunction, addRenderingLayer, astToFormula, canExecuteInReadonly, categories, chartHelpers, components, constants, convertAstNodes, coreTypes, createAutocompleteArgumentsProvider, findCellInNewZone, functionCache, getCaretDownSvg, getCaretUpSvg, helpers, hooks, invalidateCFEvaluationCommands, invalidateChartEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, isCoreCommand, isSheetDependent, iterateAstNodes, links, load, lockedSheetAllowedCommands, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
84708
84717
 
84709
- __info__.version = "19.3.15";
84710
- __info__.date = "2026-08-10T12:32:40.247Z";
84711
- __info__.hash = "25f760e";
84718
+ __info__.version = "19.3.16";
84719
+ __info__.date = "2026-08-12T09:15:31.627Z";
84720
+ __info__.hash = "464be42";
@@ -2,9 +2,9 @@
2
2
  /**
3
3
  * This file is generated by o-spreadsheet build tools. Do not edit it.
4
4
  * @see https://github.com/odoo/o-spreadsheet
5
- * @version 19.3.15
6
- * @date 2026-08-10T12:32:40.247Z
7
- * @hash 25f760e
5
+ * @version 19.3.16
6
+ * @date 2026-08-12T09:15:31.627Z
7
+ * @hash 464be42
8
8
  */
9
9
 
10
10
  (function(exports, _odoo_owl) {
@@ -4745,6 +4745,9 @@ stores.inject(MyMetaStore, storeInstance);
4745
4745
  }
4746
4746
  };
4747
4747
  const functionRegistry = new FunctionRegistry();
4748
+ /** Formulas using one of these functions are never squished: they are always exported
4749
+ * as a full formula string, and they don't become the base formula of the next cells. */
4750
+ const NonSquishableFunctionRegistry = new Registry();
4748
4751
 
4749
4752
  //#endregion
4750
4753
  //#region src/types/locale.ts
@@ -49865,7 +49868,8 @@ stores.inject(MyMetaStore, storeInstance);
49865
49868
  * The result of this method is:
49866
49869
  * - if the cell is not a formula, returns the content as is and resets the base formula
49867
49870
  * - if the cell is a formula:
49868
- * - if there is no previous formula, or the normalized formula is different from the previous one, resets the base formula to this one and returns the full formula string
49871
+ * - if there is no previous formula, or the normalized formula is different from the previous one or it contains blacklisted functions (see NonSquishableFunctionRegistry),
49872
+ * resets the base formula to this one and returns the full formula string
49869
49873
  * - else, compares the literal values and range dependencies to the previous formula, and for each parameter:
49870
49874
  * - for numbers: returns a relative change (+N or -N) if possible, else the full number or "=" if unchanged
49871
49875
  * - for strings: returns the full string if changed, else "="
@@ -49873,6 +49877,10 @@ stores.inject(MyMetaStore, storeInstance);
49873
49877
  * */
49874
49878
  squish(cell, forSheetId) {
49875
49879
  if (cell.isFormula) {
49880
+ if (NonSquishableFunctionRegistry.getAll().some((functionName) => cell.compiledFormula.usesSymbol(functionName))) {
49881
+ this.resetBaseFormula();
49882
+ return cell.compiledFormula.toFormulaString(this.getters, this.rangeToStringOptions);
49883
+ }
49876
49884
  let numbers = [];
49877
49885
  let strings = [];
49878
49886
  let references = [];
@@ -61054,7 +61062,7 @@ stores.inject(MyMetaStore, storeInstance);
61054
61062
  }
61055
61063
  message = {
61056
61064
  ...message,
61057
- commands: this.commandSquisher.squish(revision.commands)
61065
+ commands: revision.commands
61058
61066
  };
61059
61067
  }
61060
61068
  if (this.isReplayingInitialRevisions) throw new Error(`Trying to send a new revision while replaying initial revision. This can lead to endless dispatches every time the spreadsheet is open.
@@ -84513,7 +84521,8 @@ stores.inject(MyMetaStore, storeInstance);
84513
84521
  supportedPivotPositionalFormulaRegistry,
84514
84522
  pivotToFunctionValueRegistry,
84515
84523
  migrationStepRegistry,
84516
- chartJsExtensionRegistry
84524
+ chartJsExtensionRegistry,
84525
+ NonSquishableFunctionRegistry
84517
84526
  };
84518
84527
  const helpers = {
84519
84528
  arg,
@@ -84766,8 +84775,8 @@ exports.stores = stores;
84766
84775
  exports.tokenColors = tokenColors;
84767
84776
  exports.tokenize = tokenize;
84768
84777
 
84769
- __info__.version = "19.3.15";
84770
- __info__.date = "2026-08-10T12:32:40.247Z";
84771
- __info__.hash = "25f760e";
84778
+ __info__.version = "19.3.16";
84779
+ __info__.date = "2026-08-12T09:15:31.627Z";
84780
+ __info__.hash = "464be42";
84772
84781
 
84773
84782
  })(this.o_spreadsheet = this.o_spreadsheet || {}, owl);