@odoo/o-spreadsheet 17.0.59 → 17.0.60

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 17.0.59
6
- * @date 2025-04-25T08:04:05.375Z
7
- * @hash eb92388
5
+ * @version 17.0.60
6
+ * @date 2025-05-02T12:28:49.842Z
7
+ * @hash 29510cc
8
8
  */
9
9
 
10
10
  'use strict';
@@ -8791,9 +8791,6 @@ class BarChart extends AbstractChart {
8791
8791
  };
8792
8792
  }
8793
8793
  getDefinitionForExcel() {
8794
- // Excel does not support aggregating labels
8795
- if (this.aggregated)
8796
- return undefined;
8797
8794
  const dataSets = this.dataSets
8798
8795
  .map((ds) => toExcelDataset(this.getters, ds))
8799
8796
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -9370,9 +9367,6 @@ class LineChart extends AbstractChart {
9370
9367
  return new LineChart(definition, this.sheetId, this.getters);
9371
9368
  }
9372
9369
  getDefinitionForExcel() {
9373
- // Excel does not support aggregating labels
9374
- if (this.aggregated)
9375
- return undefined;
9376
9370
  const dataSets = this.dataSets
9377
9371
  .map((ds) => toExcelDataset(this.getters, ds))
9378
9372
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -9678,9 +9672,6 @@ class PieChart extends AbstractChart {
9678
9672
  return new PieChart(definition, sheetId, this.getters);
9679
9673
  }
9680
9674
  getDefinitionForExcel() {
9681
- // Excel does not support aggregating labels
9682
- if (this.aggregated)
9683
- return undefined;
9684
9675
  const dataSets = this.dataSets
9685
9676
  .map((ds) => toExcelDataset(this.getters, ds))
9686
9677
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -28484,18 +28475,28 @@ function useRefListener(ref, ...listener) {
28484
28475
  function useInterval(callback, delay) {
28485
28476
  let intervalId;
28486
28477
  const { setInterval, clearInterval } = window;
28478
+ const pause = () => {
28479
+ clearInterval(intervalId);
28480
+ intervalId = undefined;
28481
+ };
28482
+ const safeCallback = () => {
28483
+ try {
28484
+ callback();
28485
+ }
28486
+ catch (e) {
28487
+ pause();
28488
+ throw e;
28489
+ }
28490
+ };
28487
28491
  owl.useEffect(() => {
28488
- intervalId = setInterval(callback, delay);
28492
+ intervalId = setInterval(safeCallback, delay);
28489
28493
  return () => clearInterval(intervalId);
28490
28494
  }, () => [delay]);
28491
28495
  return {
28492
- pause: () => {
28493
- clearInterval(intervalId);
28494
- intervalId = undefined;
28495
- },
28496
+ pause,
28496
28497
  resume: () => {
28497
28498
  if (intervalId === undefined) {
28498
- intervalId = setInterval(callback, delay);
28499
+ intervalId = setInterval(safeCallback, delay);
28499
28500
  }
28500
28501
  },
28501
28502
  };
@@ -28940,7 +28941,7 @@ css /* scss */ `
28940
28941
  position: absolute;
28941
28942
  top: 0;
28942
28943
  left: ${HEADER_WIDTH}px;
28943
- right: 0;
28944
+ right: ${SCROLLBAR_WIDTH}px;
28944
28945
  height: ${HEADER_HEIGHT}px;
28945
28946
  &.o-dragging {
28946
28947
  cursor: grabbing;
@@ -29115,9 +29116,8 @@ css /* scss */ `
29115
29116
  position: absolute;
29116
29117
  top: ${HEADER_HEIGHT}px;
29117
29118
  left: 0;
29118
- right: 0;
29119
+ bottom: ${SCROLLBAR_WIDTH}px;
29119
29120
  width: ${HEADER_WIDTH}px;
29120
- height: calc(100% - ${HEADER_HEIGHT + SCROLLBAR_WIDTH}px);
29121
29121
  &.o-dragging {
29122
29122
  cursor: grabbing;
29123
29123
  }
@@ -50605,6 +50605,8 @@ class GridSelectionPlugin extends UIPlugin {
50605
50605
  });
50606
50606
  this.selectCell(col, row);
50607
50607
  }
50608
+ const { col, row } = this.gridSelection.anchor.cell;
50609
+ this.moveClient({ sheetId: this.activeSheet.id, col, row });
50608
50610
  }
50609
50611
  /**
50610
50612
  * Ensure selections are not outside sheet boundaries.
@@ -51344,8 +51346,11 @@ class SheetViewPlugin extends UIPlugin {
51344
51346
  }
51345
51347
  case "REMOVE_FILTER_TABLE":
51346
51348
  case "UPDATE_FILTER":
51347
- this.sheetsWithDirtyViewports.add(cmd.sheetId);
51348
- break;
51349
+ case "UNFREEZE_ROWS":
51350
+ case "UNFREEZE_COLUMNS":
51351
+ case "FREEZE_COLUMNS":
51352
+ case "FREEZE_ROWS":
51353
+ case "UNFREEZE_COLUMNS_ROWS":
51349
51354
  case "REMOVE_COLUMNS_ROWS":
51350
51355
  case "RESIZE_COLUMNS_ROWS":
51351
51356
  case "HIDE_COLUMNS_ROWS":
@@ -51358,11 +51363,9 @@ class SheetViewPlugin extends UIPlugin {
51358
51363
  case "FOLD_HEADER_GROUPS_IN_ZONE":
51359
51364
  case "UNFOLD_HEADER_GROUPS_IN_ZONE":
51360
51365
  case "UNFOLD_ALL_HEADER_GROUPS":
51361
- case "FOLD_ALL_HEADER_GROUPS": {
51362
- const sheetId = "sheetId" in cmd ? cmd.sheetId : this.getters.getActiveSheetId();
51363
- this.sheetsWithDirtyViewports.add(sheetId);
51366
+ case "FOLD_ALL_HEADER_GROUPS":
51367
+ this.sheetsWithDirtyViewports.add(cmd.sheetId);
51364
51368
  break;
51365
- }
51366
51369
  case "UPDATE_CELL":
51367
51370
  // update cell content or format can change hidden rows because of data filters
51368
51371
  if ("content" in cmd || "format" in cmd || cmd.style?.fontSize !== undefined) {
@@ -51378,13 +51381,6 @@ class SheetViewPlugin extends UIPlugin {
51378
51381
  case "ACTIVATE_SHEET":
51379
51382
  this.sheetsWithDirtyViewports.add(cmd.sheetIdTo);
51380
51383
  break;
51381
- case "UNFREEZE_ROWS":
51382
- case "UNFREEZE_COLUMNS":
51383
- case "FREEZE_COLUMNS":
51384
- case "FREEZE_ROWS":
51385
- case "UNFREEZE_COLUMNS_ROWS":
51386
- this.resetViewports(this.getters.getActiveSheetId());
51387
- break;
51388
51384
  case "DELETE_SHEET":
51389
51385
  this.sheetsWithDirtyViewports.delete(cmd.sheetId);
51390
51386
  break;
@@ -58256,6 +58252,6 @@ exports.setTranslationMethod = setTranslationMethod;
58256
58252
  exports.tokenize = tokenize;
58257
58253
 
58258
58254
 
58259
- __info__.version = "17.0.59";
58260
- __info__.date = "2025-04-25T08:04:05.375Z";
58261
- __info__.hash = "eb92388";
58255
+ __info__.version = "17.0.60";
58256
+ __info__.date = "2025-05-02T12:28:49.842Z";
58257
+ __info__.hash = "29510cc";
@@ -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 17.0.59
6
- * @date 2025-04-25T08:04:05.375Z
7
- * @hash eb92388
5
+ * @version 17.0.60
6
+ * @date 2025-05-02T12:28:49.842Z
7
+ * @hash 29510cc
8
8
  */
9
9
 
10
10
  import { Component, useRef, onMounted, useEffect, onWillPatch, useState, onWillUpdateProps, onPatched, useComponent, useExternalListener, onWillUnmount, onWillStart, xml, useChildSubEnv, useSubEnv, markRaw } from '@odoo/owl';
@@ -8789,9 +8789,6 @@ class BarChart extends AbstractChart {
8789
8789
  };
8790
8790
  }
8791
8791
  getDefinitionForExcel() {
8792
- // Excel does not support aggregating labels
8793
- if (this.aggregated)
8794
- return undefined;
8795
8792
  const dataSets = this.dataSets
8796
8793
  .map((ds) => toExcelDataset(this.getters, ds))
8797
8794
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -9368,9 +9365,6 @@ class LineChart extends AbstractChart {
9368
9365
  return new LineChart(definition, this.sheetId, this.getters);
9369
9366
  }
9370
9367
  getDefinitionForExcel() {
9371
- // Excel does not support aggregating labels
9372
- if (this.aggregated)
9373
- return undefined;
9374
9368
  const dataSets = this.dataSets
9375
9369
  .map((ds) => toExcelDataset(this.getters, ds))
9376
9370
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -9676,9 +9670,6 @@ class PieChart extends AbstractChart {
9676
9670
  return new PieChart(definition, sheetId, this.getters);
9677
9671
  }
9678
9672
  getDefinitionForExcel() {
9679
- // Excel does not support aggregating labels
9680
- if (this.aggregated)
9681
- return undefined;
9682
9673
  const dataSets = this.dataSets
9683
9674
  .map((ds) => toExcelDataset(this.getters, ds))
9684
9675
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -28482,18 +28473,28 @@ function useRefListener(ref, ...listener) {
28482
28473
  function useInterval(callback, delay) {
28483
28474
  let intervalId;
28484
28475
  const { setInterval, clearInterval } = window;
28476
+ const pause = () => {
28477
+ clearInterval(intervalId);
28478
+ intervalId = undefined;
28479
+ };
28480
+ const safeCallback = () => {
28481
+ try {
28482
+ callback();
28483
+ }
28484
+ catch (e) {
28485
+ pause();
28486
+ throw e;
28487
+ }
28488
+ };
28485
28489
  useEffect(() => {
28486
- intervalId = setInterval(callback, delay);
28490
+ intervalId = setInterval(safeCallback, delay);
28487
28491
  return () => clearInterval(intervalId);
28488
28492
  }, () => [delay]);
28489
28493
  return {
28490
- pause: () => {
28491
- clearInterval(intervalId);
28492
- intervalId = undefined;
28493
- },
28494
+ pause,
28494
28495
  resume: () => {
28495
28496
  if (intervalId === undefined) {
28496
- intervalId = setInterval(callback, delay);
28497
+ intervalId = setInterval(safeCallback, delay);
28497
28498
  }
28498
28499
  },
28499
28500
  };
@@ -28938,7 +28939,7 @@ css /* scss */ `
28938
28939
  position: absolute;
28939
28940
  top: 0;
28940
28941
  left: ${HEADER_WIDTH}px;
28941
- right: 0;
28942
+ right: ${SCROLLBAR_WIDTH}px;
28942
28943
  height: ${HEADER_HEIGHT}px;
28943
28944
  &.o-dragging {
28944
28945
  cursor: grabbing;
@@ -29113,9 +29114,8 @@ css /* scss */ `
29113
29114
  position: absolute;
29114
29115
  top: ${HEADER_HEIGHT}px;
29115
29116
  left: 0;
29116
- right: 0;
29117
+ bottom: ${SCROLLBAR_WIDTH}px;
29117
29118
  width: ${HEADER_WIDTH}px;
29118
- height: calc(100% - ${HEADER_HEIGHT + SCROLLBAR_WIDTH}px);
29119
29119
  &.o-dragging {
29120
29120
  cursor: grabbing;
29121
29121
  }
@@ -50603,6 +50603,8 @@ class GridSelectionPlugin extends UIPlugin {
50603
50603
  });
50604
50604
  this.selectCell(col, row);
50605
50605
  }
50606
+ const { col, row } = this.gridSelection.anchor.cell;
50607
+ this.moveClient({ sheetId: this.activeSheet.id, col, row });
50606
50608
  }
50607
50609
  /**
50608
50610
  * Ensure selections are not outside sheet boundaries.
@@ -51342,8 +51344,11 @@ class SheetViewPlugin extends UIPlugin {
51342
51344
  }
51343
51345
  case "REMOVE_FILTER_TABLE":
51344
51346
  case "UPDATE_FILTER":
51345
- this.sheetsWithDirtyViewports.add(cmd.sheetId);
51346
- break;
51347
+ case "UNFREEZE_ROWS":
51348
+ case "UNFREEZE_COLUMNS":
51349
+ case "FREEZE_COLUMNS":
51350
+ case "FREEZE_ROWS":
51351
+ case "UNFREEZE_COLUMNS_ROWS":
51347
51352
  case "REMOVE_COLUMNS_ROWS":
51348
51353
  case "RESIZE_COLUMNS_ROWS":
51349
51354
  case "HIDE_COLUMNS_ROWS":
@@ -51356,11 +51361,9 @@ class SheetViewPlugin extends UIPlugin {
51356
51361
  case "FOLD_HEADER_GROUPS_IN_ZONE":
51357
51362
  case "UNFOLD_HEADER_GROUPS_IN_ZONE":
51358
51363
  case "UNFOLD_ALL_HEADER_GROUPS":
51359
- case "FOLD_ALL_HEADER_GROUPS": {
51360
- const sheetId = "sheetId" in cmd ? cmd.sheetId : this.getters.getActiveSheetId();
51361
- this.sheetsWithDirtyViewports.add(sheetId);
51364
+ case "FOLD_ALL_HEADER_GROUPS":
51365
+ this.sheetsWithDirtyViewports.add(cmd.sheetId);
51362
51366
  break;
51363
- }
51364
51367
  case "UPDATE_CELL":
51365
51368
  // update cell content or format can change hidden rows because of data filters
51366
51369
  if ("content" in cmd || "format" in cmd || cmd.style?.fontSize !== undefined) {
@@ -51376,13 +51379,6 @@ class SheetViewPlugin extends UIPlugin {
51376
51379
  case "ACTIVATE_SHEET":
51377
51380
  this.sheetsWithDirtyViewports.add(cmd.sheetIdTo);
51378
51381
  break;
51379
- case "UNFREEZE_ROWS":
51380
- case "UNFREEZE_COLUMNS":
51381
- case "FREEZE_COLUMNS":
51382
- case "FREEZE_ROWS":
51383
- case "UNFREEZE_COLUMNS_ROWS":
51384
- this.resetViewports(this.getters.getActiveSheetId());
51385
- break;
51386
51382
  case "DELETE_SHEET":
51387
51383
  this.sheetsWithDirtyViewports.delete(cmd.sheetId);
51388
51384
  break;
@@ -58219,6 +58215,6 @@ const constants = {
58219
58215
  export { AbstractChart, CommandResult, CorePlugin, DispatchResult, EvaluationError, Model, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, UIPlugin, __info__, addFunction, astToFormula, compile, compileTokens, components, constants, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, hooks, invalidateCFEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, iterateAstNodes, links, load, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, tokenize };
58220
58216
 
58221
58217
 
58222
- __info__.version = "17.0.59";
58223
- __info__.date = "2025-04-25T08:04:05.375Z";
58224
- __info__.hash = "eb92388";
58218
+ __info__.version = "17.0.60";
58219
+ __info__.date = "2025-05-02T12:28:49.842Z";
58220
+ __info__.hash = "29510cc";
@@ -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 17.0.59
6
- * @date 2025-04-25T08:04:05.375Z
7
- * @hash eb92388
5
+ * @version 17.0.60
6
+ * @date 2025-05-02T12:28:49.842Z
7
+ * @hash 29510cc
8
8
  */
9
9
 
10
10
  (function (exports, owl) {
@@ -8790,9 +8790,6 @@
8790
8790
  };
8791
8791
  }
8792
8792
  getDefinitionForExcel() {
8793
- // Excel does not support aggregating labels
8794
- if (this.aggregated)
8795
- return undefined;
8796
8793
  const dataSets = this.dataSets
8797
8794
  .map((ds) => toExcelDataset(this.getters, ds))
8798
8795
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -9369,9 +9366,6 @@
9369
9366
  return new LineChart(definition, this.sheetId, this.getters);
9370
9367
  }
9371
9368
  getDefinitionForExcel() {
9372
- // Excel does not support aggregating labels
9373
- if (this.aggregated)
9374
- return undefined;
9375
9369
  const dataSets = this.dataSets
9376
9370
  .map((ds) => toExcelDataset(this.getters, ds))
9377
9371
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -9677,9 +9671,6 @@
9677
9671
  return new PieChart(definition, sheetId, this.getters);
9678
9672
  }
9679
9673
  getDefinitionForExcel() {
9680
- // Excel does not support aggregating labels
9681
- if (this.aggregated)
9682
- return undefined;
9683
9674
  const dataSets = this.dataSets
9684
9675
  .map((ds) => toExcelDataset(this.getters, ds))
9685
9676
  .filter((ds) => ds.range !== "" && ds.range !== INCORRECT_RANGE_STRING);
@@ -28483,18 +28474,28 @@
28483
28474
  function useInterval(callback, delay) {
28484
28475
  let intervalId;
28485
28476
  const { setInterval, clearInterval } = window;
28477
+ const pause = () => {
28478
+ clearInterval(intervalId);
28479
+ intervalId = undefined;
28480
+ };
28481
+ const safeCallback = () => {
28482
+ try {
28483
+ callback();
28484
+ }
28485
+ catch (e) {
28486
+ pause();
28487
+ throw e;
28488
+ }
28489
+ };
28486
28490
  owl.useEffect(() => {
28487
- intervalId = setInterval(callback, delay);
28491
+ intervalId = setInterval(safeCallback, delay);
28488
28492
  return () => clearInterval(intervalId);
28489
28493
  }, () => [delay]);
28490
28494
  return {
28491
- pause: () => {
28492
- clearInterval(intervalId);
28493
- intervalId = undefined;
28494
- },
28495
+ pause,
28495
28496
  resume: () => {
28496
28497
  if (intervalId === undefined) {
28497
- intervalId = setInterval(callback, delay);
28498
+ intervalId = setInterval(safeCallback, delay);
28498
28499
  }
28499
28500
  },
28500
28501
  };
@@ -28939,7 +28940,7 @@
28939
28940
  position: absolute;
28940
28941
  top: 0;
28941
28942
  left: ${HEADER_WIDTH}px;
28942
- right: 0;
28943
+ right: ${SCROLLBAR_WIDTH}px;
28943
28944
  height: ${HEADER_HEIGHT}px;
28944
28945
  &.o-dragging {
28945
28946
  cursor: grabbing;
@@ -29114,9 +29115,8 @@
29114
29115
  position: absolute;
29115
29116
  top: ${HEADER_HEIGHT}px;
29116
29117
  left: 0;
29117
- right: 0;
29118
+ bottom: ${SCROLLBAR_WIDTH}px;
29118
29119
  width: ${HEADER_WIDTH}px;
29119
- height: calc(100% - ${HEADER_HEIGHT + SCROLLBAR_WIDTH}px);
29120
29120
  &.o-dragging {
29121
29121
  cursor: grabbing;
29122
29122
  }
@@ -50604,6 +50604,8 @@
50604
50604
  });
50605
50605
  this.selectCell(col, row);
50606
50606
  }
50607
+ const { col, row } = this.gridSelection.anchor.cell;
50608
+ this.moveClient({ sheetId: this.activeSheet.id, col, row });
50607
50609
  }
50608
50610
  /**
50609
50611
  * Ensure selections are not outside sheet boundaries.
@@ -51343,8 +51345,11 @@
51343
51345
  }
51344
51346
  case "REMOVE_FILTER_TABLE":
51345
51347
  case "UPDATE_FILTER":
51346
- this.sheetsWithDirtyViewports.add(cmd.sheetId);
51347
- break;
51348
+ case "UNFREEZE_ROWS":
51349
+ case "UNFREEZE_COLUMNS":
51350
+ case "FREEZE_COLUMNS":
51351
+ case "FREEZE_ROWS":
51352
+ case "UNFREEZE_COLUMNS_ROWS":
51348
51353
  case "REMOVE_COLUMNS_ROWS":
51349
51354
  case "RESIZE_COLUMNS_ROWS":
51350
51355
  case "HIDE_COLUMNS_ROWS":
@@ -51357,11 +51362,9 @@
51357
51362
  case "FOLD_HEADER_GROUPS_IN_ZONE":
51358
51363
  case "UNFOLD_HEADER_GROUPS_IN_ZONE":
51359
51364
  case "UNFOLD_ALL_HEADER_GROUPS":
51360
- case "FOLD_ALL_HEADER_GROUPS": {
51361
- const sheetId = "sheetId" in cmd ? cmd.sheetId : this.getters.getActiveSheetId();
51362
- this.sheetsWithDirtyViewports.add(sheetId);
51365
+ case "FOLD_ALL_HEADER_GROUPS":
51366
+ this.sheetsWithDirtyViewports.add(cmd.sheetId);
51363
51367
  break;
51364
- }
51365
51368
  case "UPDATE_CELL":
51366
51369
  // update cell content or format can change hidden rows because of data filters
51367
51370
  if ("content" in cmd || "format" in cmd || cmd.style?.fontSize !== undefined) {
@@ -51377,13 +51380,6 @@
51377
51380
  case "ACTIVATE_SHEET":
51378
51381
  this.sheetsWithDirtyViewports.add(cmd.sheetIdTo);
51379
51382
  break;
51380
- case "UNFREEZE_ROWS":
51381
- case "UNFREEZE_COLUMNS":
51382
- case "FREEZE_COLUMNS":
51383
- case "FREEZE_ROWS":
51384
- case "UNFREEZE_COLUMNS_ROWS":
51385
- this.resetViewports(this.getters.getActiveSheetId());
51386
- break;
51387
51383
  case "DELETE_SHEET":
51388
51384
  this.sheetsWithDirtyViewports.delete(cmd.sheetId);
51389
51385
  break;
@@ -58255,9 +58251,9 @@
58255
58251
  exports.tokenize = tokenize;
58256
58252
 
58257
58253
 
58258
- __info__.version = "17.0.59";
58259
- __info__.date = "2025-04-25T08:04:05.375Z";
58260
- __info__.hash = "eb92388";
58254
+ __info__.version = "17.0.60";
58255
+ __info__.date = "2025-05-02T12:28:49.842Z";
58256
+ __info__.hash = "29510cc";
58261
58257
 
58262
58258
 
58263
58259
  })(this.o_spreadsheet = this.o_spreadsheet || {}, owl);