@odoo/o-spreadsheet 16.0.22 → 16.0.23

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.
@@ -3951,13 +3951,16 @@ class Popover extends owl.Component {
3951
3951
  super(...arguments);
3952
3952
  this.spreadsheetPosition = useSpreadsheetPosition();
3953
3953
  }
3954
+ get maxHeight() {
3955
+ return Math.max(0, this.viewportDimension.height - BOTTOMBAR_HEIGHT - SCROLLBAR_WIDTH$1);
3956
+ }
3954
3957
  get style() {
3955
3958
  // the props's position is expressed relative to the "body" element
3956
3959
  // but we teleport the element in ".o-spreadsheet" to keep everything
3957
3960
  // within our control and to avoid leaking into external DOM
3958
3961
  const horizontalPosition = `left:${this.horizontalPosition() - this.spreadsheetPosition.x}`;
3959
3962
  const verticalPosition = `top:${this.verticalPosition() - this.spreadsheetPosition.y}`;
3960
- const maxHeight = Math.max(0, this.viewportDimension.height - BOTTOMBAR_HEIGHT - SCROLLBAR_WIDTH$1);
3963
+ const maxHeight = this.maxHeight;
3961
3964
  const height = `max-height:${maxHeight}`;
3962
3965
  const shadow = maxHeight !== 0 ? "box-shadow: 1px 2px 5px 2px rgb(51 51 51 / 15%);" : "";
3963
3966
  return `
@@ -3981,7 +3984,7 @@ class Popover extends owl.Component {
3981
3984
  }
3982
3985
  get shouldRenderBottom() {
3983
3986
  const { y } = this.props.position;
3984
- return (y + this.props.childHeight <
3987
+ return (y + Math.min(this.props.childHeight, this.maxHeight) <
3985
3988
  this.viewportDimension.height + (this.env.isDashboard() ? 0 : TOPBAR_HEIGHT));
3986
3989
  }
3987
3990
  horizontalPosition() {
@@ -7688,7 +7691,7 @@ function createGaugeChartRuntime(chart, getters) {
7688
7691
  });
7689
7692
  return {
7690
7693
  chartJsConfig: config,
7691
- background: getters.getBackgroundOfSingleCellChart(chart.background, dataRange),
7694
+ background: getters.getStyleOfSingleCellChart(chart.background, dataRange).background,
7692
7695
  };
7693
7696
  }
7694
7697
 
@@ -8362,7 +8365,7 @@ function createScorecardChartRuntime(chart, getters) {
8362
8365
  const baselineZone = chart.baseline.zone;
8363
8366
  baselineCell = getters.getCell(chart.baseline.sheetId, baselineZone.left, baselineZone.top);
8364
8367
  }
8365
- const background = getters.getBackgroundOfSingleCellChart(chart.background, chart.keyValue);
8368
+ const { background, fontColor } = getters.getStyleOfSingleCellChart(chart.background, chart.keyValue);
8366
8369
  return {
8367
8370
  title: _t(chart.title),
8368
8371
  keyValue: formattedKeyValue || keyValue,
@@ -8370,7 +8373,7 @@ function createScorecardChartRuntime(chart, getters) {
8370
8373
  baselineArrow: getBaselineArrowDirection(baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.evaluated, keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.evaluated, chart.baselineMode),
8371
8374
  baselineColor: getBaselineColor(baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.evaluated, chart.baselineMode, keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.evaluated, chart.baselineColorUp, chart.baselineColorDown),
8372
8375
  baselineDescr: chart.baselineDescr ? _t(chart.baselineDescr) : "",
8373
- fontColor: chartFontColor(background),
8376
+ fontColor,
8374
8377
  background,
8375
8378
  baselineStyle: chart.baselineMode !== "percentage" ? baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.style : undefined,
8376
8379
  keyValueStyle: keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.style,
@@ -28849,6 +28852,13 @@ class FiltersPlugin extends CorePlugin {
28849
28852
  }
28850
28853
  onDeleteColumnsRows(cmd) {
28851
28854
  for (const table of this.getFilterTables(cmd.sheetId)) {
28855
+ // Remove the filter tables whose data filter headers are in the removed rows.
28856
+ if (cmd.dimension === "ROW" && cmd.elements.includes(table.zone.top)) {
28857
+ const tables = { ...this.tables[cmd.sheetId] };
28858
+ delete tables[table.id];
28859
+ this.history.update("tables", cmd.sheetId, tables);
28860
+ continue;
28861
+ }
28852
28862
  const zone = reduceZoneOnDeletion(table.zone, cmd.dimension === "COL" ? "left" : "top", cmd.elements);
28853
28863
  if (!zone) {
28854
28864
  const tables = { ...this.tables[cmd.sheetId] };
@@ -32754,27 +32764,29 @@ class EvaluationChartPlugin extends UIPlugin {
32754
32764
  return this.charts[figureId];
32755
32765
  }
32756
32766
  /**
32757
- * Get the background color of a chart based on the color of the first cell of the main range
32758
- * of the chart. In order of priority, it will return :
32759
- *
32760
- * - the chart background color if one is defined
32761
- * - the fill color of the cell if one is defined
32762
- * - the fill color of the cell from conditional formats if one is defined
32763
- * - the default chart color if no other color is defined
32767
+ * Get the background and textColor of a chart based on the color of the first cell of the main range of the chart.
32764
32768
  */
32765
- getBackgroundOfSingleCellChart(chartBackground, mainRange) {
32769
+ getStyleOfSingleCellChart(chartBackground, mainRange) {
32766
32770
  if (chartBackground)
32767
- return chartBackground;
32771
+ return { background: chartBackground, fontColor: chartFontColor(chartBackground) };
32768
32772
  if (!mainRange) {
32769
- return BACKGROUND_CHART_COLOR;
32773
+ return {
32774
+ background: BACKGROUND_CHART_COLOR,
32775
+ fontColor: chartFontColor(BACKGROUND_CHART_COLOR),
32776
+ };
32770
32777
  }
32771
32778
  const col = mainRange.zone.left;
32772
32779
  const row = mainRange.zone.top;
32773
- const style = this.getters.getCellComputedStyle(mainRange.sheetId, col, row);
32774
- return style.fillColor || BACKGROUND_CHART_COLOR;
32780
+ const sheetId = mainRange.sheetId;
32781
+ const style = this.getters.getCellComputedStyle(sheetId, col, row);
32782
+ const background = style.fillColor || BACKGROUND_CHART_COLOR;
32783
+ return {
32784
+ background,
32785
+ fontColor: style.textColor || chartFontColor(background),
32786
+ };
32775
32787
  }
32776
32788
  }
32777
- EvaluationChartPlugin.getters = ["getChartRuntime", "getBackgroundOfSingleCellChart"];
32789
+ EvaluationChartPlugin.getters = ["getChartRuntime", "getStyleOfSingleCellChart"];
32778
32790
 
32779
32791
  // -----------------------------------------------------------------------------
32780
32792
  // Constants
@@ -33202,6 +33214,8 @@ class FilterEvaluationPlugin extends UIPlugin {
33202
33214
  break;
33203
33215
  case "HIDE_COLUMNS_ROWS":
33204
33216
  case "UNHIDE_COLUMNS_ROWS":
33217
+ case "ADD_COLUMNS_ROWS":
33218
+ case "REMOVE_COLUMNS_ROWS":
33205
33219
  this.updateHiddenRows();
33206
33220
  break;
33207
33221
  case "UPDATE_FILTER":
@@ -42997,6 +43011,6 @@ exports.setTranslationMethod = setTranslationMethod;
42997
43011
  exports.tokenize = tokenize;
42998
43012
 
42999
43013
 
43000
- __info__.version = '16.0.22';
43001
- __info__.date = '2023-10-19T14:18:55.223Z';
43002
- __info__.hash = '7f76b56';
43014
+ __info__.version = '16.0.23';
43015
+ __info__.date = '2023-11-02T09:31:21.669Z';
43016
+ __info__.hash = '06ef793';
@@ -3893,22 +3893,20 @@ declare class EvaluationPlugin extends UIPlugin {
3893
3893
  private getCompilationParameters;
3894
3894
  }
3895
3895
 
3896
+ interface EvaluationChartStyle {
3897
+ background: Color;
3898
+ fontColor: Color;
3899
+ }
3896
3900
  declare class EvaluationChartPlugin extends UIPlugin {
3897
- static getters: readonly ["getChartRuntime", "getBackgroundOfSingleCellChart"];
3901
+ static getters: readonly ["getChartRuntime", "getStyleOfSingleCellChart"];
3898
3902
  readonly charts: Record<UID, ChartRuntime | undefined>;
3899
3903
  private createRuntimeChart;
3900
3904
  handle(cmd: Command): void;
3901
3905
  getChartRuntime(figureId: UID): ChartRuntime;
3902
3906
  /**
3903
- * Get the background color of a chart based on the color of the first cell of the main range
3904
- * of the chart. In order of priority, it will return :
3905
- *
3906
- * - the chart background color if one is defined
3907
- * - the fill color of the cell if one is defined
3908
- * - the fill color of the cell from conditional formats if one is defined
3909
- * - the default chart color if no other color is defined
3907
+ * Get the background and textColor of a chart based on the color of the first cell of the main range of the chart.
3910
3908
  */
3911
- getBackgroundOfSingleCellChart(chartBackground: Color | undefined, mainRange: Range | undefined): Color;
3909
+ getStyleOfSingleCellChart(chartBackground: Color | undefined, mainRange: Range | undefined): EvaluationChartStyle;
3912
3910
  }
3913
3911
 
3914
3912
  declare class EvaluationConditionalFormatPlugin extends UIPlugin {
@@ -5251,6 +5249,7 @@ declare class Popover extends Component<Props$p, SpreadsheetChildEnv> {
5251
5249
  zIndex: ComponentsImportance;
5252
5250
  };
5253
5251
  private spreadsheetPosition;
5252
+ get maxHeight(): number;
5254
5253
  get style(): string;
5255
5254
  private get viewportDimension();
5256
5255
  private get shouldRenderRight();
@@ -3947,13 +3947,16 @@ class Popover extends Component {
3947
3947
  super(...arguments);
3948
3948
  this.spreadsheetPosition = useSpreadsheetPosition();
3949
3949
  }
3950
+ get maxHeight() {
3951
+ return Math.max(0, this.viewportDimension.height - BOTTOMBAR_HEIGHT - SCROLLBAR_WIDTH$1);
3952
+ }
3950
3953
  get style() {
3951
3954
  // the props's position is expressed relative to the "body" element
3952
3955
  // but we teleport the element in ".o-spreadsheet" to keep everything
3953
3956
  // within our control and to avoid leaking into external DOM
3954
3957
  const horizontalPosition = `left:${this.horizontalPosition() - this.spreadsheetPosition.x}`;
3955
3958
  const verticalPosition = `top:${this.verticalPosition() - this.spreadsheetPosition.y}`;
3956
- const maxHeight = Math.max(0, this.viewportDimension.height - BOTTOMBAR_HEIGHT - SCROLLBAR_WIDTH$1);
3959
+ const maxHeight = this.maxHeight;
3957
3960
  const height = `max-height:${maxHeight}`;
3958
3961
  const shadow = maxHeight !== 0 ? "box-shadow: 1px 2px 5px 2px rgb(51 51 51 / 15%);" : "";
3959
3962
  return `
@@ -3977,7 +3980,7 @@ class Popover extends Component {
3977
3980
  }
3978
3981
  get shouldRenderBottom() {
3979
3982
  const { y } = this.props.position;
3980
- return (y + this.props.childHeight <
3983
+ return (y + Math.min(this.props.childHeight, this.maxHeight) <
3981
3984
  this.viewportDimension.height + (this.env.isDashboard() ? 0 : TOPBAR_HEIGHT));
3982
3985
  }
3983
3986
  horizontalPosition() {
@@ -7684,7 +7687,7 @@ function createGaugeChartRuntime(chart, getters) {
7684
7687
  });
7685
7688
  return {
7686
7689
  chartJsConfig: config,
7687
- background: getters.getBackgroundOfSingleCellChart(chart.background, dataRange),
7690
+ background: getters.getStyleOfSingleCellChart(chart.background, dataRange).background,
7688
7691
  };
7689
7692
  }
7690
7693
 
@@ -8358,7 +8361,7 @@ function createScorecardChartRuntime(chart, getters) {
8358
8361
  const baselineZone = chart.baseline.zone;
8359
8362
  baselineCell = getters.getCell(chart.baseline.sheetId, baselineZone.left, baselineZone.top);
8360
8363
  }
8361
- const background = getters.getBackgroundOfSingleCellChart(chart.background, chart.keyValue);
8364
+ const { background, fontColor } = getters.getStyleOfSingleCellChart(chart.background, chart.keyValue);
8362
8365
  return {
8363
8366
  title: _t(chart.title),
8364
8367
  keyValue: formattedKeyValue || keyValue,
@@ -8366,7 +8369,7 @@ function createScorecardChartRuntime(chart, getters) {
8366
8369
  baselineArrow: getBaselineArrowDirection(baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.evaluated, keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.evaluated, chart.baselineMode),
8367
8370
  baselineColor: getBaselineColor(baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.evaluated, chart.baselineMode, keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.evaluated, chart.baselineColorUp, chart.baselineColorDown),
8368
8371
  baselineDescr: chart.baselineDescr ? _t(chart.baselineDescr) : "",
8369
- fontColor: chartFontColor(background),
8372
+ fontColor,
8370
8373
  background,
8371
8374
  baselineStyle: chart.baselineMode !== "percentage" ? baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.style : undefined,
8372
8375
  keyValueStyle: keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.style,
@@ -28845,6 +28848,13 @@ class FiltersPlugin extends CorePlugin {
28845
28848
  }
28846
28849
  onDeleteColumnsRows(cmd) {
28847
28850
  for (const table of this.getFilterTables(cmd.sheetId)) {
28851
+ // Remove the filter tables whose data filter headers are in the removed rows.
28852
+ if (cmd.dimension === "ROW" && cmd.elements.includes(table.zone.top)) {
28853
+ const tables = { ...this.tables[cmd.sheetId] };
28854
+ delete tables[table.id];
28855
+ this.history.update("tables", cmd.sheetId, tables);
28856
+ continue;
28857
+ }
28848
28858
  const zone = reduceZoneOnDeletion(table.zone, cmd.dimension === "COL" ? "left" : "top", cmd.elements);
28849
28859
  if (!zone) {
28850
28860
  const tables = { ...this.tables[cmd.sheetId] };
@@ -32750,27 +32760,29 @@ class EvaluationChartPlugin extends UIPlugin {
32750
32760
  return this.charts[figureId];
32751
32761
  }
32752
32762
  /**
32753
- * Get the background color of a chart based on the color of the first cell of the main range
32754
- * of the chart. In order of priority, it will return :
32755
- *
32756
- * - the chart background color if one is defined
32757
- * - the fill color of the cell if one is defined
32758
- * - the fill color of the cell from conditional formats if one is defined
32759
- * - the default chart color if no other color is defined
32763
+ * Get the background and textColor of a chart based on the color of the first cell of the main range of the chart.
32760
32764
  */
32761
- getBackgroundOfSingleCellChart(chartBackground, mainRange) {
32765
+ getStyleOfSingleCellChart(chartBackground, mainRange) {
32762
32766
  if (chartBackground)
32763
- return chartBackground;
32767
+ return { background: chartBackground, fontColor: chartFontColor(chartBackground) };
32764
32768
  if (!mainRange) {
32765
- return BACKGROUND_CHART_COLOR;
32769
+ return {
32770
+ background: BACKGROUND_CHART_COLOR,
32771
+ fontColor: chartFontColor(BACKGROUND_CHART_COLOR),
32772
+ };
32766
32773
  }
32767
32774
  const col = mainRange.zone.left;
32768
32775
  const row = mainRange.zone.top;
32769
- const style = this.getters.getCellComputedStyle(mainRange.sheetId, col, row);
32770
- return style.fillColor || BACKGROUND_CHART_COLOR;
32776
+ const sheetId = mainRange.sheetId;
32777
+ const style = this.getters.getCellComputedStyle(sheetId, col, row);
32778
+ const background = style.fillColor || BACKGROUND_CHART_COLOR;
32779
+ return {
32780
+ background,
32781
+ fontColor: style.textColor || chartFontColor(background),
32782
+ };
32771
32783
  }
32772
32784
  }
32773
- EvaluationChartPlugin.getters = ["getChartRuntime", "getBackgroundOfSingleCellChart"];
32785
+ EvaluationChartPlugin.getters = ["getChartRuntime", "getStyleOfSingleCellChart"];
32774
32786
 
32775
32787
  // -----------------------------------------------------------------------------
32776
32788
  // Constants
@@ -33198,6 +33210,8 @@ class FilterEvaluationPlugin extends UIPlugin {
33198
33210
  break;
33199
33211
  case "HIDE_COLUMNS_ROWS":
33200
33212
  case "UNHIDE_COLUMNS_ROWS":
33213
+ case "ADD_COLUMNS_ROWS":
33214
+ case "REMOVE_COLUMNS_ROWS":
33201
33215
  this.updateHiddenRows();
33202
33216
  break;
33203
33217
  case "UPDATE_FILTER":
@@ -42965,6 +42979,6 @@ function addFunction(functionName, functionDescription) {
42965
42979
  export { AbstractChart, CommandResult, CorePlugin, DATETIME_FORMAT, DispatchResult, EvaluationError, Model, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, UIPlugin, __info__, addFunction, astToFormula, cellTypes, compile, components, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, invalidateEvaluationCommands, load, parse, readonlyAllowedCommands, registries, setTranslationMethod, tokenize };
42966
42980
 
42967
42981
 
42968
- __info__.version = '16.0.22';
42969
- __info__.date = '2023-10-19T14:18:55.223Z';
42970
- __info__.hash = '7f76b56';
42982
+ __info__.version = '16.0.23';
42983
+ __info__.date = '2023-11-02T09:31:21.669Z';
42984
+ __info__.hash = '06ef793';
@@ -3948,13 +3948,16 @@
3948
3948
  super(...arguments);
3949
3949
  this.spreadsheetPosition = useSpreadsheetPosition();
3950
3950
  }
3951
+ get maxHeight() {
3952
+ return Math.max(0, this.viewportDimension.height - BOTTOMBAR_HEIGHT - SCROLLBAR_WIDTH$1);
3953
+ }
3951
3954
  get style() {
3952
3955
  // the props's position is expressed relative to the "body" element
3953
3956
  // but we teleport the element in ".o-spreadsheet" to keep everything
3954
3957
  // within our control and to avoid leaking into external DOM
3955
3958
  const horizontalPosition = `left:${this.horizontalPosition() - this.spreadsheetPosition.x}`;
3956
3959
  const verticalPosition = `top:${this.verticalPosition() - this.spreadsheetPosition.y}`;
3957
- const maxHeight = Math.max(0, this.viewportDimension.height - BOTTOMBAR_HEIGHT - SCROLLBAR_WIDTH$1);
3960
+ const maxHeight = this.maxHeight;
3958
3961
  const height = `max-height:${maxHeight}`;
3959
3962
  const shadow = maxHeight !== 0 ? "box-shadow: 1px 2px 5px 2px rgb(51 51 51 / 15%);" : "";
3960
3963
  return `
@@ -3978,7 +3981,7 @@
3978
3981
  }
3979
3982
  get shouldRenderBottom() {
3980
3983
  const { y } = this.props.position;
3981
- return (y + this.props.childHeight <
3984
+ return (y + Math.min(this.props.childHeight, this.maxHeight) <
3982
3985
  this.viewportDimension.height + (this.env.isDashboard() ? 0 : TOPBAR_HEIGHT));
3983
3986
  }
3984
3987
  horizontalPosition() {
@@ -7685,7 +7688,7 @@
7685
7688
  });
7686
7689
  return {
7687
7690
  chartJsConfig: config,
7688
- background: getters.getBackgroundOfSingleCellChart(chart.background, dataRange),
7691
+ background: getters.getStyleOfSingleCellChart(chart.background, dataRange).background,
7689
7692
  };
7690
7693
  }
7691
7694
 
@@ -8359,7 +8362,7 @@
8359
8362
  const baselineZone = chart.baseline.zone;
8360
8363
  baselineCell = getters.getCell(chart.baseline.sheetId, baselineZone.left, baselineZone.top);
8361
8364
  }
8362
- const background = getters.getBackgroundOfSingleCellChart(chart.background, chart.keyValue);
8365
+ const { background, fontColor } = getters.getStyleOfSingleCellChart(chart.background, chart.keyValue);
8363
8366
  return {
8364
8367
  title: _t(chart.title),
8365
8368
  keyValue: formattedKeyValue || keyValue,
@@ -8367,7 +8370,7 @@
8367
8370
  baselineArrow: getBaselineArrowDirection(baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.evaluated, keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.evaluated, chart.baselineMode),
8368
8371
  baselineColor: getBaselineColor(baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.evaluated, chart.baselineMode, keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.evaluated, chart.baselineColorUp, chart.baselineColorDown),
8369
8372
  baselineDescr: chart.baselineDescr ? _t(chart.baselineDescr) : "",
8370
- fontColor: chartFontColor(background),
8373
+ fontColor,
8371
8374
  background,
8372
8375
  baselineStyle: chart.baselineMode !== "percentage" ? baselineCell === null || baselineCell === void 0 ? void 0 : baselineCell.style : undefined,
8373
8376
  keyValueStyle: keyValueCell === null || keyValueCell === void 0 ? void 0 : keyValueCell.style,
@@ -28846,6 +28849,13 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
28846
28849
  }
28847
28850
  onDeleteColumnsRows(cmd) {
28848
28851
  for (const table of this.getFilterTables(cmd.sheetId)) {
28852
+ // Remove the filter tables whose data filter headers are in the removed rows.
28853
+ if (cmd.dimension === "ROW" && cmd.elements.includes(table.zone.top)) {
28854
+ const tables = { ...this.tables[cmd.sheetId] };
28855
+ delete tables[table.id];
28856
+ this.history.update("tables", cmd.sheetId, tables);
28857
+ continue;
28858
+ }
28849
28859
  const zone = reduceZoneOnDeletion(table.zone, cmd.dimension === "COL" ? "left" : "top", cmd.elements);
28850
28860
  if (!zone) {
28851
28861
  const tables = { ...this.tables[cmd.sheetId] };
@@ -32751,27 +32761,29 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
32751
32761
  return this.charts[figureId];
32752
32762
  }
32753
32763
  /**
32754
- * Get the background color of a chart based on the color of the first cell of the main range
32755
- * of the chart. In order of priority, it will return :
32756
- *
32757
- * - the chart background color if one is defined
32758
- * - the fill color of the cell if one is defined
32759
- * - the fill color of the cell from conditional formats if one is defined
32760
- * - the default chart color if no other color is defined
32764
+ * Get the background and textColor of a chart based on the color of the first cell of the main range of the chart.
32761
32765
  */
32762
- getBackgroundOfSingleCellChart(chartBackground, mainRange) {
32766
+ getStyleOfSingleCellChart(chartBackground, mainRange) {
32763
32767
  if (chartBackground)
32764
- return chartBackground;
32768
+ return { background: chartBackground, fontColor: chartFontColor(chartBackground) };
32765
32769
  if (!mainRange) {
32766
- return BACKGROUND_CHART_COLOR;
32770
+ return {
32771
+ background: BACKGROUND_CHART_COLOR,
32772
+ fontColor: chartFontColor(BACKGROUND_CHART_COLOR),
32773
+ };
32767
32774
  }
32768
32775
  const col = mainRange.zone.left;
32769
32776
  const row = mainRange.zone.top;
32770
- const style = this.getters.getCellComputedStyle(mainRange.sheetId, col, row);
32771
- return style.fillColor || BACKGROUND_CHART_COLOR;
32777
+ const sheetId = mainRange.sheetId;
32778
+ const style = this.getters.getCellComputedStyle(sheetId, col, row);
32779
+ const background = style.fillColor || BACKGROUND_CHART_COLOR;
32780
+ return {
32781
+ background,
32782
+ fontColor: style.textColor || chartFontColor(background),
32783
+ };
32772
32784
  }
32773
32785
  }
32774
- EvaluationChartPlugin.getters = ["getChartRuntime", "getBackgroundOfSingleCellChart"];
32786
+ EvaluationChartPlugin.getters = ["getChartRuntime", "getStyleOfSingleCellChart"];
32775
32787
 
32776
32788
  // -----------------------------------------------------------------------------
32777
32789
  // Constants
@@ -33199,6 +33211,8 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
33199
33211
  break;
33200
33212
  case "HIDE_COLUMNS_ROWS":
33201
33213
  case "UNHIDE_COLUMNS_ROWS":
33214
+ case "ADD_COLUMNS_ROWS":
33215
+ case "REMOVE_COLUMNS_ROWS":
33202
33216
  this.updateHiddenRows();
33203
33217
  break;
33204
33218
  case "UPDATE_FILTER":
@@ -42996,9 +43010,9 @@ day_count_convention (number, default=${DEFAULT_DAY_COUNT_CONVENTION} ) ${_lt("A
42996
43010
  Object.defineProperty(exports, '__esModule', { value: true });
42997
43011
 
42998
43012
 
42999
- __info__.version = '16.0.22';
43000
- __info__.date = '2023-10-19T14:18:55.223Z';
43001
- __info__.hash = '7f76b56';
43013
+ __info__.version = '16.0.23';
43014
+ __info__.date = '2023-11-02T09:31:21.669Z';
43015
+ __info__.hash = '06ef793';
43002
43016
 
43003
43017
 
43004
43018
  })(this.o_spreadsheet = this.o_spreadsheet || {}, owl);