@odoo/o-spreadsheet 19.1.27 → 19.1.29

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.1.27
6
- * @date 2026-07-13T06:25:27.934Z
7
- * @hash 6eb95de
5
+ * @version 19.1.29
6
+ * @date 2026-07-23T07:39:45.650Z
7
+ * @hash c880860
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.1.27
6
- * @date 2026-07-13T06:25:26.922Z
7
- * @hash 6eb95de
5
+ * @version 19.1.29
6
+ * @date 2026-07-23T07:39:44.019Z
7
+ * @hash c880860
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";
@@ -40804,7 +40804,8 @@ var Autofill = class extends Component {
40804
40804
  const { x, y } = this.state.handler ? this.state.position : this.props.position;
40805
40805
  return cssPropertiesToCss({
40806
40806
  top: `${y}px`,
40807
- left: `${x}px`
40807
+ left: `${x}px`,
40808
+ visibility: this.props.isVisible ? "visible" : "hidden"
40808
40809
  });
40809
40810
  }
40810
40811
  get styleNextValue() {
@@ -41225,7 +41226,7 @@ var CellComposerStore = class extends AbstractComposerStore {
41225
41226
  this._cancelEdition();
41226
41227
  this.resetContent();
41227
41228
  }
41228
- if (cmd.sheetIdFrom !== cmd.sheetIdTo) {
41229
+ if (this.model.selection.isListening(this) && cmd.sheetIdFrom !== cmd.sheetIdTo) {
41229
41230
  const activePosition = this.getters.getActivePosition();
41230
41231
  const { col, row } = this.getters.getNextVisibleCellPosition({
41231
41232
  sheetId: cmd.sheetIdTo,
@@ -47072,7 +47073,7 @@ var ScorecardChartConfigPanel = class extends Component {
47072
47073
  return !!this.state.keyValueDispatchResult?.isCancelledBecause("InvalidScorecardKeyValue");
47073
47074
  }
47074
47075
  get isBaselineInvalid() {
47075
- return !!this.state.keyValueDispatchResult?.isCancelledBecause("InvalidScorecardBaseline");
47076
+ return !!this.state.baselineDispatchResult?.isCancelledBecause("InvalidScorecardBaseline");
47076
47077
  }
47077
47078
  onKeyValueRangeChanged(ranges) {
47078
47079
  this.keyValue = ranges[0];
@@ -61242,6 +61243,8 @@ var PivotUIPlugin = class extends CoreViewPlugin {
61242
61243
  pivots = {};
61243
61244
  unusedPivotsInFormulas;
61244
61245
  custom;
61246
+ pivotPositionCache = new PositionMap();
61247
+ shouldInvalidateCache = false;
61245
61248
  constructor(config) {
61246
61249
  super(config);
61247
61250
  this.custom = config.custom;
@@ -61252,7 +61255,11 @@ var PivotUIPlugin = class extends CoreViewPlugin {
61252
61255
  }
61253
61256
  }
61254
61257
  handle(cmd) {
61255
- if (invalidateEvaluationCommands.has(cmd.type)) for (const pivotId of this.getters.getPivotIds()) this.setupPivot(pivotId, { recreate: true });
61258
+ if (invalidateEvaluationCommands.has(cmd.type)) {
61259
+ this.shouldInvalidateCache = true;
61260
+ for (const pivotId of this.getters.getPivotIds()) this.setupPivot(pivotId, { recreate: true });
61261
+ }
61262
+ if (cmd.type === "UPDATE_CELL") this.shouldInvalidateCache = true;
61256
61263
  switch (cmd.type) {
61257
61264
  case "REFRESH_PIVOT":
61258
61265
  this.refreshPivot(cmd.id);
@@ -61292,6 +61299,12 @@ var PivotUIPlugin = class extends CoreViewPlugin {
61292
61299
  break;
61293
61300
  }
61294
61301
  }
61302
+ finalize() {
61303
+ if (this.shouldInvalidateCache) {
61304
+ this.pivotPositionCache = new PositionMap();
61305
+ this.shouldInvalidateCache = false;
61306
+ }
61307
+ }
61295
61308
  /**
61296
61309
  * Get the id of the first pivot in the formula at the given position. Returns undefined if there
61297
61310
  * is no pivot at this position
@@ -61303,9 +61316,14 @@ var PivotUIPlugin = class extends CoreViewPlugin {
61303
61316
  * Get all of the ids of the pivot present in the formula at the given position.
61304
61317
  */
61305
61318
  getPivotIdsFromPosition(position) {
61306
- const cell = this.getters.getCorrespondingFormulaCell(position);
61307
- if (cell && cell.isFormula) return this.getPivotIdsFromFormula(position.sheetId, cell.compiledFormula);
61308
- return [];
61319
+ if (!this.pivotPositionCache.has(position)) {
61320
+ const cell = this.getters.getCorrespondingFormulaCell(position);
61321
+ if (cell && cell.isFormula) {
61322
+ const pivotIds = this.getPivotIdsFromFormula(position.sheetId, cell.compiledFormula);
61323
+ this.pivotPositionCache.set(position, pivotIds);
61324
+ }
61325
+ }
61326
+ return this.pivotPositionCache.get(position) || [];
61309
61327
  }
61310
61328
  getPivotIdsFromFormula(sheetId, formula) {
61311
61329
  return this.getPivotFunctions(sheetId, formula.tokens).map((pivotFunction) => {
@@ -64482,8 +64500,8 @@ var HeaderVisibilityUIPlugin = class extends UIPlugin {
64482
64500
  getNextVisibleCellPosition({ sheetId, col, row }) {
64483
64501
  return {
64484
64502
  sheetId,
64485
- col: this.findVisibleHeader(sheetId, "COL", col, this.getters.getNumberCols(sheetId) - 1),
64486
- row: this.findVisibleHeader(sheetId, "ROW", row, this.getters.getNumberRows(sheetId) - 1)
64503
+ col: this.findVisibleHeader(sheetId, "COL", col, this.getters.getNumberCols(sheetId) - 1) || this.findVisibleHeader(sheetId, "COL", col, 0) || 0,
64504
+ row: this.findVisibleHeader(sheetId, "ROW", row, this.getters.getNumberRows(sheetId) - 1) || this.findVisibleHeader(sheetId, "ROW", row, 0) || 0
64487
64505
  };
64488
64506
  }
64489
64507
  /**
@@ -78981,7 +78999,8 @@ const helpers = {
78981
78999
  numberToJsDate,
78982
79000
  DateTime,
78983
79001
  parseFormat,
78984
- isFormula
79002
+ isFormula,
79003
+ PositionMap
78985
79004
  };
78986
79005
  const links = {
78987
79006
  isMarkdownLink,
@@ -79099,6 +79118,6 @@ const chartHelpers = {
79099
79118
  //#endregion
79100
79119
  export { AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, CellErrorType, ClientDisconnectedError, CommandResult, CorePlugin, CoreViewPlugin, DEFAULT_LOCALE, DEFAULT_LOCALES, DispatchResult, EvaluationError, LocalTransportService, Model, PivotRuntimeDefinition, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, SpreadsheetPivotTable, UIPlugin, __info__, addFunction, addRenderingLayer, astToFormula, categories, chartHelpers, components, constants, convertAstNodes, coreTypes, createAutocompleteArgumentsProvider, findCellInNewZone, functionCache, getCaretDownSvg, getCaretUpSvg, helpers, hooks, invalidateCFEvaluationCommands, invalidateChartEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, iterateAstNodes, links, load, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
79101
79120
 
79102
- __info__.version = "19.1.27";
79103
- __info__.date = "2026-07-13T06:25:26.922Z";
79104
- __info__.hash = "6eb95de";
79121
+ __info__.version = "19.1.29";
79122
+ __info__.date = "2026-07-23T07:39:44.019Z";
79123
+ __info__.hash = "c880860";
@@ -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.1.27
6
- * @date 2026-07-13T06:25:26.922Z
7
- * @hash 6eb95de
5
+ * @version 19.1.29
6
+ * @date 2026-07-23T07:39:44.019Z
7
+ * @hash c880860
8
8
  */
9
9
 
10
10
  (function(exports, _odoo_owl) {
@@ -40806,7 +40806,8 @@ stores.inject(MyMetaStore, storeInstance);
40806
40806
  const { x, y } = this.state.handler ? this.state.position : this.props.position;
40807
40807
  return cssPropertiesToCss({
40808
40808
  top: `${y}px`,
40809
- left: `${x}px`
40809
+ left: `${x}px`,
40810
+ visibility: this.props.isVisible ? "visible" : "hidden"
40810
40811
  });
40811
40812
  }
40812
40813
  get styleNextValue() {
@@ -41227,7 +41228,7 @@ stores.inject(MyMetaStore, storeInstance);
41227
41228
  this._cancelEdition();
41228
41229
  this.resetContent();
41229
41230
  }
41230
- if (cmd.sheetIdFrom !== cmd.sheetIdTo) {
41231
+ if (this.model.selection.isListening(this) && cmd.sheetIdFrom !== cmd.sheetIdTo) {
41231
41232
  const activePosition = this.getters.getActivePosition();
41232
41233
  const { col, row } = this.getters.getNextVisibleCellPosition({
41233
41234
  sheetId: cmd.sheetIdTo,
@@ -47074,7 +47075,7 @@ stores.inject(MyMetaStore, storeInstance);
47074
47075
  return !!this.state.keyValueDispatchResult?.isCancelledBecause("InvalidScorecardKeyValue");
47075
47076
  }
47076
47077
  get isBaselineInvalid() {
47077
- return !!this.state.keyValueDispatchResult?.isCancelledBecause("InvalidScorecardBaseline");
47078
+ return !!this.state.baselineDispatchResult?.isCancelledBecause("InvalidScorecardBaseline");
47078
47079
  }
47079
47080
  onKeyValueRangeChanged(ranges) {
47080
47081
  this.keyValue = ranges[0];
@@ -61244,6 +61245,8 @@ stores.inject(MyMetaStore, storeInstance);
61244
61245
  pivots = {};
61245
61246
  unusedPivotsInFormulas;
61246
61247
  custom;
61248
+ pivotPositionCache = new PositionMap();
61249
+ shouldInvalidateCache = false;
61247
61250
  constructor(config) {
61248
61251
  super(config);
61249
61252
  this.custom = config.custom;
@@ -61254,7 +61257,11 @@ stores.inject(MyMetaStore, storeInstance);
61254
61257
  }
61255
61258
  }
61256
61259
  handle(cmd) {
61257
- if (invalidateEvaluationCommands.has(cmd.type)) for (const pivotId of this.getters.getPivotIds()) this.setupPivot(pivotId, { recreate: true });
61260
+ if (invalidateEvaluationCommands.has(cmd.type)) {
61261
+ this.shouldInvalidateCache = true;
61262
+ for (const pivotId of this.getters.getPivotIds()) this.setupPivot(pivotId, { recreate: true });
61263
+ }
61264
+ if (cmd.type === "UPDATE_CELL") this.shouldInvalidateCache = true;
61258
61265
  switch (cmd.type) {
61259
61266
  case "REFRESH_PIVOT":
61260
61267
  this.refreshPivot(cmd.id);
@@ -61294,6 +61301,12 @@ stores.inject(MyMetaStore, storeInstance);
61294
61301
  break;
61295
61302
  }
61296
61303
  }
61304
+ finalize() {
61305
+ if (this.shouldInvalidateCache) {
61306
+ this.pivotPositionCache = new PositionMap();
61307
+ this.shouldInvalidateCache = false;
61308
+ }
61309
+ }
61297
61310
  /**
61298
61311
  * Get the id of the first pivot in the formula at the given position. Returns undefined if there
61299
61312
  * is no pivot at this position
@@ -61305,9 +61318,14 @@ stores.inject(MyMetaStore, storeInstance);
61305
61318
  * Get all of the ids of the pivot present in the formula at the given position.
61306
61319
  */
61307
61320
  getPivotIdsFromPosition(position) {
61308
- const cell = this.getters.getCorrespondingFormulaCell(position);
61309
- if (cell && cell.isFormula) return this.getPivotIdsFromFormula(position.sheetId, cell.compiledFormula);
61310
- return [];
61321
+ if (!this.pivotPositionCache.has(position)) {
61322
+ const cell = this.getters.getCorrespondingFormulaCell(position);
61323
+ if (cell && cell.isFormula) {
61324
+ const pivotIds = this.getPivotIdsFromFormula(position.sheetId, cell.compiledFormula);
61325
+ this.pivotPositionCache.set(position, pivotIds);
61326
+ }
61327
+ }
61328
+ return this.pivotPositionCache.get(position) || [];
61311
61329
  }
61312
61330
  getPivotIdsFromFormula(sheetId, formula) {
61313
61331
  return this.getPivotFunctions(sheetId, formula.tokens).map((pivotFunction) => {
@@ -64484,8 +64502,8 @@ stores.inject(MyMetaStore, storeInstance);
64484
64502
  getNextVisibleCellPosition({ sheetId, col, row }) {
64485
64503
  return {
64486
64504
  sheetId,
64487
- col: this.findVisibleHeader(sheetId, "COL", col, this.getters.getNumberCols(sheetId) - 1),
64488
- row: this.findVisibleHeader(sheetId, "ROW", row, this.getters.getNumberRows(sheetId) - 1)
64505
+ col: this.findVisibleHeader(sheetId, "COL", col, this.getters.getNumberCols(sheetId) - 1) || this.findVisibleHeader(sheetId, "COL", col, 0) || 0,
64506
+ row: this.findVisibleHeader(sheetId, "ROW", row, this.getters.getNumberRows(sheetId) - 1) || this.findVisibleHeader(sheetId, "ROW", row, 0) || 0
64489
64507
  };
64490
64508
  }
64491
64509
  /**
@@ -78983,7 +79001,8 @@ stores.inject(MyMetaStore, storeInstance);
78983
79001
  numberToJsDate,
78984
79002
  DateTime,
78985
79003
  parseFormat,
78986
- isFormula
79004
+ isFormula,
79005
+ PositionMap
78987
79006
  };
78988
79007
  const links = {
78989
79008
  isMarkdownLink,
@@ -79154,8 +79173,8 @@ exports.stores = stores;
79154
79173
  exports.tokenColors = tokenColors;
79155
79174
  exports.tokenize = tokenize;
79156
79175
 
79157
- __info__.version = "19.1.27";
79158
- __info__.date = "2026-07-13T06:25:26.922Z";
79159
- __info__.hash = "6eb95de";
79176
+ __info__.version = "19.1.29";
79177
+ __info__.date = "2026-07-23T07:39:44.019Z";
79178
+ __info__.hash = "c880860";
79160
79179
 
79161
79180
  })(this.o_spreadsheet = this.o_spreadsheet || {}, owl);