@odoo/o-spreadsheet 19.3.7 → 19.3.11

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.7
6
- * @date 2026-06-17T08:57:42.174Z
7
- * @hash e061163
5
+ * @version 19.3.11
6
+ * @date 2026-07-13T06:26:28.422Z
7
+ * @hash 35c06d3
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";
@@ -234,7 +234,7 @@ const GRAY_400 = "#ced4da";
234
234
  const GRAY_300 = "#D8DADD";
235
235
  const GRAY_200 = "#E7E9ED";
236
236
  const TEXT_BODY = "#374151";
237
- const TEXT_BODY_MUTED = TEXT_BODY + "C2";
237
+ const TEXT_BODY_MUTED = "#374151C2";
238
238
  const ACTION_COLOR = HIGHLIGHT_COLOR;
239
239
  const CHART_TITLE_FONT_SIZE = 16;
240
240
  const DEFAULT_CHART_COLOR_SCALE = {
@@ -327,9 +327,6 @@ const COLOR_PICKER_DEFAULTS = [
327
327
  ];
328
328
  const DEFAULT_CELL_HEIGHT = 23;
329
329
  const FOOTER_HEIGHT = 2 * 23;
330
- const MENU_SEPARATOR_BORDER_WIDTH = 1;
331
- const MENU_SEPARATOR_PADDING = 5;
332
- const MENU_SEPARATOR_HEIGHT = 1 + 2 * 5;
333
330
  const ZOOM_VALUES = [
334
331
  50,
335
332
  75,
@@ -360,7 +357,7 @@ const DEFAULT_NUMBER_STYLE = {
360
357
  const DEFAULT_VERTICAL_ALIGN = DEFAULT_STYLE.verticalAlign;
361
358
  const DEFAULT_WRAPPING_MODE = DEFAULT_STYLE.wrapping;
362
359
  const DEFAULT_FONT_SIZE = DEFAULT_STYLE.fontSize;
363
- const DEFAULT_FONT = "'Roboto', arial";
360
+ const DEFAULT_FONT = "'Roboto', arial, 'Liberation Sans'";
364
361
  const DEFAULT_BORDER_DESC = {
365
362
  style: "thin",
366
363
  color: "#000000"
@@ -1232,7 +1229,7 @@ function toXC(col, row, rangePart = {
1232
1229
  function recomputeZones(zones, zonesToRemove = []) {
1233
1230
  if (zones.length <= 1 && zonesToRemove.length === 0) return zones;
1234
1231
  const profilesStartingPosition = [0];
1235
- const profiles = new Map([[0, []]]);
1232
+ const profiles = /* @__PURE__ */ new Map([[0, []]]);
1236
1233
  modifyProfiles(profilesStartingPosition, profiles, zones, false);
1237
1234
  modifyProfiles(profilesStartingPosition, profiles, zonesToRemove, true);
1238
1235
  return constructZonesFromProfiles(profilesStartingPosition, profiles);
@@ -3944,12 +3941,10 @@ const getNumberRegex = memoize(function getNumberRegex(locale) {
3944
3941
  const pIntegerAndDecimals = `(?:\\d+(?:${escapeRegExp(locale.thousandsSeparator || "")}\\d{3,})*(?:${decimalSeparator}\\d*)?)`;
3945
3942
  const pOnlyDecimals = `(?:${decimalSeparator}\\d+)`;
3946
3943
  const pNumber = "(?:\\s*" + pIntegerAndDecimals + "|" + pOnlyDecimals + ")(?:(e|E)(?:\\+|-)?(?:[0-9]|[0-9][0-9]|[12][0-9]{2}|30[0-7]))?(?:\\s*%)?";
3947
- const pMinus = "(?:\\s*-)?";
3948
- const pCurrencyFormat = "(?:\\s*[\\$€])?";
3949
3944
  const pNumberExp = "^(?:(?:" + [
3950
- pMinus + pCurrencyFormat + pNumber,
3951
- pMinus + pNumber + pCurrencyFormat,
3952
- pCurrencyFormat + pMinus + pNumber
3945
+ "(?:\\s*-)?(?:\\s*[\\$€])?" + pNumber,
3946
+ "(?:\\s*-)?" + pNumber + "(?:\\s*[\\$€])?",
3947
+ "(?:\\s*[\\$€])?(?:\\s*-)?" + pNumber
3953
3948
  ].join(")|(?:") + "))$";
3954
3949
  return new RegExp(pNumberExp, "i");
3955
3950
  });
@@ -7551,7 +7546,7 @@ function isPositionDependent(cmd) {
7551
7546
  function isZoneDependent(cmd) {
7552
7547
  return "sheetId" in cmd && "zone" in cmd;
7553
7548
  }
7554
- const invalidateEvaluationCommands = new Set([
7549
+ const invalidateEvaluationCommands = /* @__PURE__ */ new Set([
7555
7550
  "RENAME_SHEET",
7556
7551
  "DELETE_SHEET",
7557
7552
  "CREATE_SHEET",
@@ -7573,7 +7568,7 @@ const invalidateEvaluationCommands = new Set([
7573
7568
  "UPDATE_NAMED_RANGE",
7574
7569
  "DELETE_NAMED_RANGE"
7575
7570
  ]);
7576
- const invalidateChartEvaluationCommands = new Set([
7571
+ const invalidateChartEvaluationCommands = /* @__PURE__ */ new Set([
7577
7572
  "EVALUATE_CELLS",
7578
7573
  "EVALUATE_CHARTS",
7579
7574
  "UPDATE_CELL",
@@ -7592,20 +7587,20 @@ const invalidateChartEvaluationCommands = new Set([
7592
7587
  "UNDO",
7593
7588
  "REDO"
7594
7589
  ]);
7595
- const invalidateDependenciesCommands = new Set(["MOVE_RANGES"]);
7596
- const invalidateCFEvaluationCommands = new Set([
7590
+ const invalidateDependenciesCommands = /* @__PURE__ */ new Set(["MOVE_RANGES"]);
7591
+ const invalidateCFEvaluationCommands = /* @__PURE__ */ new Set([
7597
7592
  "EVALUATE_CELLS",
7598
7593
  "ADD_CONDITIONAL_FORMAT",
7599
7594
  "REMOVE_CONDITIONAL_FORMAT",
7600
7595
  "CHANGE_CONDITIONAL_FORMAT_PRIORITY"
7601
7596
  ]);
7602
- const invalidateBordersCommands = new Set([
7597
+ const invalidateBordersCommands = /* @__PURE__ */ new Set([
7603
7598
  "AUTOFILL_CELL",
7604
7599
  "SET_BORDER",
7605
7600
  "SET_ZONE_BORDERS",
7606
7601
  "SET_BORDERS_ON_TARGET"
7607
7602
  ]);
7608
- const invalidSubtotalFormulasCommands = new Set([
7603
+ const invalidSubtotalFormulasCommands = /* @__PURE__ */ new Set([
7609
7604
  "UNHIDE_COLUMNS_ROWS",
7610
7605
  "HIDE_COLUMNS_ROWS",
7611
7606
  "GROUP_HEADERS",
@@ -7619,7 +7614,7 @@ const invalidSubtotalFormulasCommands = new Set([
7619
7614
  "UPDATE_TABLE",
7620
7615
  "UPDATE_FILTER"
7621
7616
  ]);
7622
- const readonlyAllowedCommands = new Set([
7617
+ const readonlyAllowedCommands = /* @__PURE__ */ new Set([
7623
7618
  "START",
7624
7619
  "ACTIVATE_SHEET",
7625
7620
  "COPY",
@@ -7635,7 +7630,7 @@ const readonlyAllowedCommands = new Set([
7635
7630
  "UPDATE_CAROUSEL_ACTIVE_ITEM",
7636
7631
  "UPDATE_PIVOT"
7637
7632
  ]);
7638
- const lockedSheetAllowedCommands = new Set([
7633
+ const lockedSheetAllowedCommands = /* @__PURE__ */ new Set([
7639
7634
  "LOCK_SHEET",
7640
7635
  "UNLOCK_SHEET",
7641
7636
  "MOVE_SHEET",
@@ -7666,7 +7661,7 @@ const lockedSheetAllowedCommands = new Set([
7666
7661
  "SHIFT_VIEWPORT_DOWN",
7667
7662
  "SHIFT_VIEWPORT_UP"
7668
7663
  ]);
7669
- const coreTypes = new Set([
7664
+ const coreTypes = /* @__PURE__ */ new Set([
7670
7665
  "UPDATE_CELL",
7671
7666
  "UPDATE_CELL_POSITION",
7672
7667
  "CLEAR_CELL",
@@ -8300,7 +8295,6 @@ function getCanonicalRepresentation(item) {
8300
8295
  //#region src/helpers/edge_scrolling.ts
8301
8296
  const MAX_DELAY = 140;
8302
8297
  const MIN_DELAY = 20;
8303
- const ACCELERATION = .035;
8304
8298
  /**
8305
8299
  * Decreasing exponential function used to determine the "speed" of edge-scrolling
8306
8300
  * as the timeout delay.
@@ -8308,7 +8302,7 @@ const ACCELERATION = .035;
8308
8302
  * Returns a timeout delay in milliseconds.
8309
8303
  */
8310
8304
  function scrollDelay(value) {
8311
- return 20 + (140 - 20) * Math.exp(-ACCELERATION * (value - 1));
8305
+ return 20 + (140 - 20) * Math.exp(-.035 * (value - 1));
8312
8306
  }
8313
8307
 
8314
8308
  //#endregion
@@ -8711,7 +8705,7 @@ var UuidGenerator = class {
8711
8705
  const cryptoObj = this.getCrypto();
8712
8706
  if (cryptoObj) return "10000000-1000".replace(/[01]/g, (c) => {
8713
8707
  const n = Number(c);
8714
- return (n ^ cryptoObj.getRandomValues(new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
8708
+ return (n ^ cryptoObj.getRandomValues(/* @__PURE__ */ new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
8715
8709
  });
8716
8710
  else return "xxxxxxxx-xxxx".replace(/[xy]/g, function(c) {
8717
8711
  const r = Math.random() * 16 | 0;
@@ -8726,7 +8720,7 @@ var UuidGenerator = class {
8726
8720
  const cryptoObj = this.getCrypto();
8727
8721
  if (cryptoObj) return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => {
8728
8722
  const n = Number(c);
8729
- return (n ^ cryptoObj.getRandomValues(new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
8723
+ return (n ^ cryptoObj.getRandomValues(/* @__PURE__ */ new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
8730
8724
  });
8731
8725
  else return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(c) {
8732
8726
  const r = Math.random() * 16 | 0;
@@ -12748,7 +12742,7 @@ const availableConditionalFormatOperators = new Set(cfOperators);
12748
12742
 
12749
12743
  //#endregion
12750
12744
  //#region src/types/data_validation.ts
12751
- const availableDataValidationOperators = new Set([
12745
+ const availableDataValidationOperators = /* @__PURE__ */ new Set([
12752
12746
  "containsText",
12753
12747
  "notContainsText",
12754
12748
  "isEqualText",
@@ -13342,10 +13336,10 @@ function toNormalizedPivotValue(dimension, groupValue) {
13342
13336
  type: dimension.type
13343
13337
  }));
13344
13338
  if (groupValueString.toLowerCase() === "false") return false;
13345
- return pivotNormalizationValueRegistry.get(dimension.type)(groupValueString, dimension.granularity);
13339
+ return pivotNormalizationValueRegistry.get(dimension.type)(groupValueString, dimension);
13346
13340
  }
13347
- function normalizeDateTime(value, granularity) {
13348
- return pivotTimeAdapter(granularity ?? "month").normalizeFunctionValue(value);
13341
+ function normalizeDateTime(value, dimension) {
13342
+ return pivotTimeAdapter(dimension.granularity ?? "month").normalizeFunctionValue(value);
13349
13343
  }
13350
13344
  function toFunctionPivotValue(value, dimension) {
13351
13345
  if (value === null) return `"null"`;
@@ -14146,7 +14140,7 @@ function filterInvalidCalendarDataPoints(labels, datasets) {
14146
14140
  */
14147
14141
  function filterInvalidHierarchicalPoints(values, hierarchy) {
14148
14142
  const numberOfDataPoints = Math.max(values.length, ...hierarchy.map((dataset) => dataset.data?.length || 0));
14149
- const isEmpty = (value) => value === null || value === "";
14143
+ const isEmpty = (value) => value === void 0 || value === null || value === "";
14150
14144
  const dataPointsIndexes = range(0, numberOfDataPoints).filter((dataPointIndex) => {
14151
14145
  const groups = hierarchy.map((dataset) => dataset.data?.[dataPointIndex]);
14152
14146
  if (isEmpty(groups[0]?.value)) return false;
@@ -15944,6 +15938,59 @@ function getCarouselItemTitle(getters, item) {
15944
15938
  return (chartSubtypeRegistry.getAll().find((c) => c.matcher?.(definition)) || chartSubtypeRegistry.get(definition.type)).displayName;
15945
15939
  }
15946
15940
 
15941
+ //#endregion
15942
+ //#region src/components/helpers/css.ts
15943
+ function getTextDecoration({ strikethrough, underline }) {
15944
+ if (!strikethrough && !underline) return "none";
15945
+ return `${strikethrough ? "line-through" : ""} ${underline ? "underline" : ""}`;
15946
+ }
15947
+ /**
15948
+ * Convert the cell style to CSS properties.
15949
+ */
15950
+ function cellStyleToCss(style) {
15951
+ const attributes = cellTextStyleToCss(style);
15952
+ if (!style) return attributes;
15953
+ if (style.fillColor) attributes["background"] = style.fillColor;
15954
+ return attributes;
15955
+ }
15956
+ /**
15957
+ * Convert the cell text style to CSS properties.
15958
+ */
15959
+ function cellTextStyleToCss(style) {
15960
+ const attributes = {};
15961
+ if (!style) return attributes;
15962
+ if (style.bold) attributes["font-weight"] = "bold";
15963
+ if (style.italic) attributes["font-style"] = "italic";
15964
+ if (style.fontSize) attributes["font-size"] = `${style.fontSize}px`;
15965
+ if (style.strikethrough || style.underline) {
15966
+ let decoration = style.strikethrough ? "line-through" : "";
15967
+ decoration = style.underline ? decoration + " underline" : decoration;
15968
+ attributes["text-decoration"] = decoration;
15969
+ }
15970
+ if (style.textColor) attributes["color"] = style.textColor;
15971
+ return attributes;
15972
+ }
15973
+ /**
15974
+ * Transform CSS properties into a CSS string.
15975
+ */
15976
+ function cssPropertiesToCss(attributes) {
15977
+ let styleStr = "";
15978
+ for (const attName in attributes) {
15979
+ if (!attributes[attName]) continue;
15980
+ styleStr += `${attName}:${attributes[attName]}; `;
15981
+ }
15982
+ return styleStr;
15983
+ }
15984
+ function getElementMargins(el) {
15985
+ const style = window.getComputedStyle(el);
15986
+ return {
15987
+ top: parseInt(style.marginTop, 10) || 0,
15988
+ bottom: parseInt(style.marginBottom, 10) || 0,
15989
+ left: parseInt(style.marginLeft, 10) || 0,
15990
+ right: parseInt(style.marginRight, 10) || 0
15991
+ };
15992
+ }
15993
+
15947
15994
  //#endregion
15948
15995
  //#region src/components/figures/chart/chartJs/zoomable_chart/zoomable_chart_store.ts
15949
15996
  const TREND_LINE_AXES_IDS = ["x1", MOVING_AVERAGE_TREND_LINE_XAXIS_ID];
@@ -16062,9 +16109,7 @@ var ZoomableChartJsComponent = class extends ChartJsComponent {
16062
16109
  this.removeEventListeners();
16063
16110
  }
16064
16111
  get containerStyle() {
16065
- return `
16066
- height:${this.sliceable ? `calc(100% - ${60}px)` : "100%"};
16067
- `;
16112
+ return cssPropertiesToCss({ height: this.sliceable ? `calc(100% - ${60}px)` : "100%" });
16068
16113
  }
16069
16114
  get masterChartContainerStyle() {
16070
16115
  const runtime = this.env.model.getters.getChartRuntime(this.props.chartId);
@@ -16928,59 +16973,6 @@ var FullScreenFigureStore = class extends SpreadsheetStore {
16928
16973
  }
16929
16974
  };
16930
16975
 
16931
- //#endregion
16932
- //#region src/components/helpers/css.ts
16933
- function getTextDecoration({ strikethrough, underline }) {
16934
- if (!strikethrough && !underline) return "none";
16935
- return `${strikethrough ? "line-through" : ""} ${underline ? "underline" : ""}`;
16936
- }
16937
- /**
16938
- * Convert the cell style to CSS properties.
16939
- */
16940
- function cellStyleToCss(style) {
16941
- const attributes = cellTextStyleToCss(style);
16942
- if (!style) return attributes;
16943
- if (style.fillColor) attributes["background"] = style.fillColor;
16944
- return attributes;
16945
- }
16946
- /**
16947
- * Convert the cell text style to CSS properties.
16948
- */
16949
- function cellTextStyleToCss(style) {
16950
- const attributes = {};
16951
- if (!style) return attributes;
16952
- if (style.bold) attributes["font-weight"] = "bold";
16953
- if (style.italic) attributes["font-style"] = "italic";
16954
- if (style.fontSize) attributes["font-size"] = `${style.fontSize}px`;
16955
- if (style.strikethrough || style.underline) {
16956
- let decoration = style.strikethrough ? "line-through" : "";
16957
- decoration = style.underline ? decoration + " underline" : decoration;
16958
- attributes["text-decoration"] = decoration;
16959
- }
16960
- if (style.textColor) attributes["color"] = style.textColor;
16961
- return attributes;
16962
- }
16963
- /**
16964
- * Transform CSS properties into a CSS string.
16965
- */
16966
- function cssPropertiesToCss(attributes) {
16967
- let styleStr = "";
16968
- for (const attName in attributes) {
16969
- if (!attributes[attName]) continue;
16970
- styleStr += `${attName}:${attributes[attName]}; `;
16971
- }
16972
- return styleStr;
16973
- }
16974
- function getElementMargins(el) {
16975
- const style = window.getComputedStyle(el);
16976
- return {
16977
- top: parseInt(style.marginTop, 10) || 0,
16978
- bottom: parseInt(style.marginBottom, 10) || 0,
16979
- left: parseInt(style.marginLeft, 10) || 0,
16980
- right: parseInt(style.marginRight, 10) || 0
16981
- };
16982
- }
16983
-
16984
16976
  //#endregion
16985
16977
  //#region src/stores/DOM_focus_store.ts
16986
16978
  var DOMFocusableElementStore = class {
@@ -18228,11 +18220,11 @@ var FigureComponent = class extends Component {
18228
18220
  getResizerPosition(resizer) {
18229
18221
  const anchorCenteringOffset = (ANCHOR_SIZE - ACTIVE_BORDER_WIDTH) / 2;
18230
18222
  const style = {};
18231
- if (resizer.includes("top")) style.top = `${-anchorCenteringOffset}px`;
18232
- else if (resizer.includes("bottom")) style.bottom = `${-anchorCenteringOffset}px`;
18223
+ if (resizer.includes("top")) style.top = `-3px`;
18224
+ else if (resizer.includes("bottom")) style.bottom = `-3px`;
18233
18225
  else style.bottom = `calc(50% - ${anchorCenteringOffset}px)`;
18234
- if (resizer.includes("left")) style.left = `${-anchorCenteringOffset}px`;
18235
- else if (resizer.includes("right")) style.right = `${-anchorCenteringOffset}px`;
18226
+ if (resizer.includes("left")) style.left = `-3px`;
18227
+ else if (resizer.includes("right")) style.right = `-3px`;
18236
18228
  else style.right = `calc(50% - ${anchorCenteringOffset}px)`;
18237
18229
  return cssPropertiesToCss(style);
18238
18230
  }
@@ -25830,6 +25822,7 @@ function mapParenthesisCode(tokens) {
25830
25822
  function mapParentFunction(tokens) {
25831
25823
  const stack = [];
25832
25824
  let functionStarted = "";
25825
+ let braceDepth = 0;
25833
25826
  function pushTokenToFunctionContext(token) {
25834
25827
  if (stack.length === 0) return;
25835
25828
  const functionContext = stack.at(-1);
@@ -25842,7 +25835,7 @@ function mapParentFunction(tokens) {
25842
25835
  });
25843
25836
  }
25844
25837
  }
25845
- return tokens.map((token, i) => {
25838
+ return tokens.map((token) => {
25846
25839
  if (!["SPACE", "LEFT_PAREN"].includes(token.type)) functionStarted = "";
25847
25840
  switch (token.type) {
25848
25841
  case "SYMBOL":
@@ -25863,8 +25856,16 @@ function mapParentFunction(tokens) {
25863
25856
  stack.pop()?.argsTokens?.flat().forEach(pushTokenToFunctionContext);
25864
25857
  pushTokenToFunctionContext(token);
25865
25858
  break;
25859
+ case "LEFT_BRACE":
25860
+ braceDepth++;
25861
+ pushTokenToFunctionContext(token);
25862
+ break;
25863
+ case "RIGHT_BRACE":
25864
+ braceDepth--;
25865
+ pushTokenToFunctionContext(token);
25866
+ break;
25866
25867
  case "ARG_SEPARATOR":
25867
- if (stack.length) stack[stack.length - 1].argPosition++;
25868
+ if (stack.length && braceDepth === 0) stack[stack.length - 1].argPosition++;
25868
25869
  pushTokenToFunctionContext(token);
25869
25870
  break;
25870
25871
  default:
@@ -27216,10 +27217,7 @@ function startDnd(onPointerMove, onPointerUp) {
27216
27217
  //#endregion
27217
27218
  //#region src/components/color_picker/color_picker.ts
27218
27219
  const ITEM_BORDER_WIDTH = 1;
27219
- const ITEM_EDGE_LENGTH = 18;
27220
- const ITEMS_PER_LINE = 10;
27221
- const MAGNIFIER_EDGE = 16;
27222
- const CONTENT_WIDTH = ITEMS_PER_LINE * (ITEM_EDGE_LENGTH + 2 * ITEM_BORDER_WIDTH) + (ITEMS_PER_LINE - 1) * 2;
27220
+ const CONTENT_WIDTH = 218;
27223
27221
  const INNER_GRADIENT_WIDTH = CONTENT_WIDTH - 2 * ITEM_BORDER_WIDTH;
27224
27222
  const INNER_GRADIENT_HEIGHT = CONTENT_WIDTH - 30 - 2 * ITEM_BORDER_WIDTH;
27225
27223
  var ColorPicker = class extends Component {
@@ -27283,8 +27281,8 @@ var ColorPicker = class extends Component {
27283
27281
  const left = Math.round(INNER_GRADIENT_WIDTH * clip(s / 100, 0, 1));
27284
27282
  const top = Math.round(INNER_GRADIENT_HEIGHT * clip(1 - 2 * l / (200 - s), 0, 1));
27285
27283
  return cssPropertiesToCss({
27286
- left: `${-MAGNIFIER_EDGE / 2 + left}px`,
27287
- top: `${-MAGNIFIER_EDGE / 2 + top}px`,
27284
+ left: `${-16 / 2 + left}px`,
27285
+ top: `${-16 / 2 + top}px`,
27288
27286
  background: hslaToHex(this.state.currentHslaColor)
27289
27287
  });
27290
27288
  }
@@ -32824,9 +32822,12 @@ var SpreadsheetChart = class SpreadsheetChart {
32824
32822
  labelValues: []
32825
32823
  })
32826
32824
  };
32827
- return this.chartTypeBuilder.getRuntime(getters, this.definition, dataExtractors, this.sheetId, { onClick: (event, items, chartJsChart) => {
32828
- return this.dataSourceBuilder.onDataSetClick?.(this.definition.type, chartId, event, items, chartJsChart, getters);
32829
- } });
32825
+ return this.chartTypeBuilder.getRuntime(getters, this.definition, dataExtractors, this.sheetId, {
32826
+ onClick: (event, items, chartJsChart) => {
32827
+ return this.dataSourceBuilder.onDataSetClick?.(this.definition.type, chartId, event, items, chartJsChart, getters);
32828
+ },
32829
+ onHover: (event, items, chartJsChart) => this.dataSourceBuilder.onDataSetHover?.(this.definition.type, chartId, event, items, chartJsChart)
32830
+ });
32830
32831
  }
32831
32832
  static deleteInvalidKeys(definition) {
32832
32833
  definition = { ...definition };
@@ -33033,7 +33034,7 @@ function getChartDatasetValues(getters, dataSets) {
33033
33034
  if (cell) label = cell.formattedValue;
33034
33035
  }
33035
33036
  let data = ds.dataRange ? getData(getters, ds) : [];
33036
- if (data.every((cell) => !cell.value || isTextResult(cell)) && data.filter(isTextResult).length > 1) data = data.map((cell) => cell.value && isErrorResult(cell) ? ONE : EMPTY);
33037
+ if (data.every((cell) => !cell.value || isTextResult(cell)) && data.filter(isTextResult).length > 1) data = data.map((cell) => cell.value && !isErrorResult(cell) ? ONE : EMPTY);
33037
33038
  else if (data.every((cell) => !isNumberResult(cell))) hidden = true;
33038
33039
  datasetValues.push({
33039
33040
  data,
@@ -36023,9 +36024,9 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36023
36024
  allSheetsMatches = [];
36024
36025
  activeSheetMatches = [];
36025
36026
  specificRangeMatches = [];
36027
+ selectedMatchPosition = null;
36026
36028
  currentSearchRegex = null;
36027
36029
  initialShowFormulaState;
36028
- preserveSelectedMatchIndex = false;
36029
36030
  irreplaceableMatchCount = 0;
36030
36031
  isSearchDirty = false;
36031
36032
  shouldFinalizeUpdateSelection = false;
@@ -36147,7 +36148,10 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36147
36148
  */
36148
36149
  _updateSearch(toSearch, searchOptions) {
36149
36150
  this.searchOptions = searchOptions;
36150
- if (toSearch !== this.toSearch) this.selectedMatchIndex = null;
36151
+ if (toSearch !== this.toSearch) {
36152
+ this.selectedMatchIndex = null;
36153
+ this.selectedMatchPosition = null;
36154
+ }
36151
36155
  this.toSearch = toSearch;
36152
36156
  this.currentSearchRegex = getSearchRegex(this.toSearch, this.searchOptions);
36153
36157
  this.refreshSearch({
@@ -36159,8 +36163,14 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36159
36163
  * refresh the matches according to the current search options
36160
36164
  */
36161
36165
  refreshSearch(options) {
36162
- if (!this.preserveSelectedMatchIndex) this.selectedMatchIndex = null;
36163
36166
  this.findMatches();
36167
+ if (this.selectedMatchPosition) if (this.selectedMatchPosition.sheetId !== this.getters.getActiveSheetId()) {
36168
+ this.selectedMatchIndex = null;
36169
+ this.selectedMatchPosition = null;
36170
+ } else {
36171
+ const index = this.searchMatches.findIndex((match) => match.sheetId === this.selectedMatchPosition?.sheetId && match.col === this.selectedMatchPosition?.col && match.row === this.selectedMatchPosition?.row);
36172
+ if (index !== -1) this.selectedMatchIndex = index;
36173
+ }
36164
36174
  this.selectNextCell(0, options);
36165
36175
  }
36166
36176
  getSheetsInSearchOrder() {
@@ -36228,6 +36238,7 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36228
36238
  const matches = this.searchMatches;
36229
36239
  if (!matches.length) {
36230
36240
  this.selectedMatchIndex = null;
36241
+ this.selectedMatchPosition = null;
36231
36242
  return;
36232
36243
  }
36233
36244
  let nextIndex;
@@ -36241,14 +36252,13 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36241
36252
  } else nextIndex = this.selectedMatchIndex + indexChange;
36242
36253
  nextIndex = (nextIndex + matches.length) % matches.length;
36243
36254
  this.selectedMatchIndex = nextIndex;
36255
+ this.selectedMatchPosition = matches[this.selectedMatchIndex];
36244
36256
  const selectedMatch = matches[nextIndex];
36245
36257
  if (options.jumpToMatchSheet && this.getters.getActiveSheetId() !== selectedMatch.sheetId) {
36246
- this.preserveSelectedMatchIndex = true;
36247
36258
  this.model.dispatch("ACTIVATE_SHEET", {
36248
36259
  sheetIdFrom: this.getters.getActiveSheetId(),
36249
36260
  sheetIdTo: selectedMatch.sheetId
36250
36261
  });
36251
- this.preserveSelectedMatchIndex = false;
36252
36262
  this.isSearchDirty = false;
36253
36263
  }
36254
36264
  this.model.selection.getBackToDefault();
@@ -36259,7 +36269,6 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36259
36269
  */
36260
36270
  replace() {
36261
36271
  if (this.selectedMatchIndex === null) return;
36262
- this.preserveSelectedMatchIndex = true;
36263
36272
  this.shouldFinalizeUpdateSelection = true;
36264
36273
  this.model.dispatch("REPLACE_SEARCH", {
36265
36274
  searchString: this.toSearch,
@@ -36267,7 +36276,6 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
36267
36276
  matches: [this.searchMatches[this.selectedMatchIndex]],
36268
36277
  searchOptions: this.searchOptions
36269
36278
  });
36270
- this.preserveSelectedMatchIndex = false;
36271
36279
  }
36272
36280
  /**
36273
36281
  * Apply the replace function to all the matches one time.
@@ -41203,7 +41211,7 @@ var TableStylePreview = class extends Component {
41203
41211
  mode: "pivot",
41204
41212
  numberOfCols: 5,
41205
41213
  numberOfRows: 8,
41206
- mainSubHeaderRows: new Set([props.tableConfig.numberOfHeaders, props.tableConfig.numberOfHeaders + 3])
41214
+ mainSubHeaderRows: /* @__PURE__ */ new Set([props.tableConfig.numberOfHeaders, props.tableConfig.numberOfHeaders + 3])
41207
41215
  };
41208
41216
  drawPreviewTable(ctx, getComputedTableStyle(props.tableConfig, props.tableStyle, tableMetaData), {
41209
41217
  ...tableMetaData,
@@ -44529,9 +44537,12 @@ var CellComposerStore = class extends AbstractComposerStore {
44529
44537
  }
44530
44538
  stopEdition(direction) {
44531
44539
  if (this.canStopEdition()) {
44540
+ const { col, row } = this.currentEditedCell;
44532
44541
  this._stopEdition();
44533
- if (direction) if (this.getters.isSingleCellOrMerge(this.sheetId, this.getters.getSelectedZone())) this.model.selection.moveAnchorCell(direction, 1);
44534
- else moveAnchorWithinSelection(this.getters, this.model.selection, direction);
44542
+ if (direction) if (this.getters.isSingleCellOrMerge(this.sheetId, this.getters.getSelectedZone())) {
44543
+ this.model.selection.selectCell(col, row);
44544
+ this.model.selection.moveAnchorCell(direction, 1);
44545
+ } else moveAnchorWithinSelection(this.getters, this.model.selection, direction);
44535
44546
  return;
44536
44547
  }
44537
44548
  const editedCell = this.currentEditedCell;
@@ -48541,7 +48552,7 @@ var Grid = class extends Component {
48541
48552
  ev.preventDefault();
48542
48553
  const clipboardData = ev.clipboardData;
48543
48554
  if (!clipboardData) return;
48544
- const image = [...clipboardData.files]?.find((file) => AllowedImageMimeTypes.includes(file.type));
48555
+ const image = [...clipboardData.files].find((file) => AllowedImageMimeTypes.includes(file.type));
48545
48556
  const osClipboard = { content: {
48546
48557
  ["text/plain"]: clipboardData?.getData("text/plain"),
48547
48558
  ["text/html"]: clipboardData?.getData("text/html")
@@ -54607,7 +54618,7 @@ function compareIntervals(a, b) {
54607
54618
  //#region src/plugins/ui_core_views/cell_evaluation/zone_set.ts
54608
54619
  var ZoneSet = class ZoneSet {
54609
54620
  profilesStartingPosition = [0];
54610
- profiles = new Map([[0, []]]);
54621
+ profiles = /* @__PURE__ */ new Map([[0, []]]);
54611
54622
  constructor(zones = []) {
54612
54623
  for (const zone of zones) this.add(zone);
54613
54624
  }
@@ -56224,12 +56235,22 @@ var CustomColorsPlugin = class extends CoreViewPlugin {
56224
56235
  handle(cmd) {
56225
56236
  switch (cmd.type) {
56226
56237
  case "START":
56227
- for (const sheetId of this.getters.getSheetIds()) for (const chartId of this.getters.getChartIds(sheetId)) this.tryToAddColors(this.getChartColors(chartId));
56238
+ for (const sheetId of this.getters.getSheetIds()) {
56239
+ for (const chartId of this.getters.getChartIds(sheetId)) this.tryToAddColors(this.getChartColors(chartId));
56240
+ for (const figureId of this.getters.getFigures(sheetId)) this.tryToAddColors(this.getCarouselColors(sheetId, figureId.id));
56241
+ }
56228
56242
  break;
56229
56243
  case "UPDATE_CHART":
56230
56244
  case "CREATE_CHART":
56231
56245
  this.tryToAddColors(this.getChartColors(cmd.chartId));
56232
56246
  break;
56247
+ case "CREATE_CAROUSEL":
56248
+ case "UPDATE_CAROUSEL":
56249
+ this.tryToAddColors(this.getCarouselColors(cmd.sheetId, cmd.figureId));
56250
+ break;
56251
+ case "COLOR_SHEET":
56252
+ if (cmd.color) this.tryToAddColors([cmd.color]);
56253
+ break;
56233
56254
  case "UPDATE_CELL":
56234
56255
  case "ADD_CONDITIONAL_FORMAT":
56235
56256
  case "SET_BORDER":
@@ -56252,8 +56273,12 @@ var CustomColorsPlugin = class extends CoreViewPlugin {
56252
56273
  }
56253
56274
  computeCustomColors() {
56254
56275
  let usedColors = [];
56255
- for (const sheetId of this.getters.getSheetIds()) usedColors = usedColors.concat(this.getColorsFromCells(sheetId), this.getFormattingColors(sheetId), this.getTableColors(sheetId));
56256
- return [...new Set([...usedColors])];
56276
+ for (const sheetId of this.getters.getSheetIds()) usedColors = usedColors.concat(this.getSheetColors(sheetId), this.getColorsFromCells(sheetId), this.getFormattingColors(sheetId), this.getTableColors(sheetId));
56277
+ return [.../* @__PURE__ */ new Set([...usedColors])];
56278
+ }
56279
+ getSheetColors(sheetId) {
56280
+ const sheet = this.getters.getSheet(sheetId);
56281
+ return sheet.color ? [sheet.color] : [];
56257
56282
  }
56258
56283
  getColorsFromCells(sheetId) {
56259
56284
  const cells = Object.values(this.getters.getCells(sheetId));
@@ -56286,6 +56311,11 @@ var CustomColorsPlugin = class extends CoreViewPlugin {
56286
56311
  if (chart === void 0) return [];
56287
56312
  return [...JSON.stringify(chart.getRangeDefinition()).matchAll(chartColorRegex)].map((color) => color[1]);
56288
56313
  }
56314
+ getCarouselColors(sheetId, figureId) {
56315
+ if (this.getters.getFigure(sheetId, figureId)?.tag !== "carousel") return [];
56316
+ const titleColor = this.getters.getCarousel(figureId).title?.color;
56317
+ return titleColor ? [titleColor] : [];
56318
+ }
56289
56319
  getTableColors(sheetId) {
56290
56320
  return this.getters.getTables(sheetId).flatMap((table) => {
56291
56321
  const config = table.config;
@@ -56911,13 +56941,13 @@ var EvaluationConditionalFormatPlugin = class extends CoreViewPlugin {
56911
56941
  const minValue = this.parsePoint(sheetId, range, rule.minimum, "min");
56912
56942
  const midValue = rule.midpoint ? this.parsePoint(sheetId, range, rule.midpoint) : null;
56913
56943
  const maxValue = this.parsePoint(sheetId, range, rule.maximum, "max");
56914
- if (minValue === null || maxValue === null || minValue >= maxValue || midValue && (minValue >= midValue || midValue >= maxValue)) return;
56944
+ if (minValue === null || maxValue === null || minValue >= maxValue || midValue !== null && (minValue >= midValue || midValue >= maxValue)) return;
56915
56945
  const zone = this.getters.getRangeFromSheetXC(sheetId, range).zone;
56916
56946
  const colorThresholds = [{
56917
56947
  value: minValue,
56918
56948
  color: rule.minimum.color
56919
56949
  }];
56920
- if (rule.midpoint && midValue) colorThresholds.push({
56950
+ if (rule.midpoint && midValue !== null) colorThresholds.push({
56921
56951
  value: midValue,
56922
56952
  color: rule.midpoint.color
56923
56953
  });
@@ -59789,7 +59819,7 @@ var TableComputedStylePlugin = class extends UIPlugin {
59789
59819
  };
59790
59820
  }
59791
59821
  };
59792
- const invalidateTableStyleCommandsSet = new Set([
59822
+ const invalidateTableStyleCommandsSet = /* @__PURE__ */ new Set([
59793
59823
  "HIDE_COLUMNS_ROWS",
59794
59824
  "UNHIDE_COLUMNS_ROWS",
59795
59825
  "UNFOLD_HEADER_GROUP",
@@ -64230,11 +64260,23 @@ var GridSelectionPlugin = class extends UIPlugin {
64230
64260
  ctx.strokeStyle = SELECTION_BORDER_COLOR;
64231
64261
  ctx.lineWidth = 1.5 * thinLineWidth;
64232
64262
  for (const zone of zones) {
64263
+ if (!viewports.isZoneVisibleInViewport(sheetId, zone)) continue;
64233
64264
  const { x, y, width, height } = viewports.getVisibleRect(sheetId, zone);
64234
64265
  ctx.globalCompositeOperation = "multiply";
64235
- ctx.fillRect(x, y, width, height);
64236
- ctx.globalCompositeOperation = "source-over";
64237
- ctx.strokeRect(x, y, width, height);
64266
+ const currentLineWidth = ctx.lineWidth;
64267
+ if (height === 0 || width === 0) ctx.lineWidth = 3 * thinLineWidth;
64268
+ if (height === 0 && width === 0) {
64269
+ ctx.beginPath();
64270
+ ctx.arc(x, y, 3, 0, 2 * Math.PI);
64271
+ ctx.fill();
64272
+ ctx.globalCompositeOperation = "source-over";
64273
+ ctx.stroke();
64274
+ } else {
64275
+ ctx.fillRect(x, y, width, height);
64276
+ ctx.globalCompositeOperation = "source-over";
64277
+ ctx.strokeRect(x, y, width, height);
64278
+ }
64279
+ ctx.lineWidth = currentLineWidth;
64238
64280
  }
64239
64281
  ctx.globalCompositeOperation = "source-over";
64240
64282
  const position = renderingContext.activePosition;
@@ -64359,14 +64401,14 @@ var InternalViewport = class {
64359
64401
  adjustPositionX(targetCol) {
64360
64402
  const sheetId = this.sheetId;
64361
64403
  const { start, end } = this.getters.getColDimensions(sheetId, targetCol);
64362
- if (this.offsetX + this.viewportWidth + this.offsetCorrectionX < end) this.offsetX = end - this.viewportWidth;
64404
+ if (this.offsetX + this.viewportWidth + this.offsetCorrectionX < end) this.offsetX = end - this.viewportWidth - this.offsetCorrectionX;
64363
64405
  else if (this.offsetX + this.offsetCorrectionX > start) this.offsetX = start - this.offsetCorrectionX;
64364
64406
  this.adjustViewportZoneX();
64365
64407
  }
64366
64408
  adjustPositionY(targetRow) {
64367
64409
  const sheetId = this.sheetId;
64368
64410
  const { start, end } = this.getters.getRowDimensions(sheetId, targetRow);
64369
- if (this.offsetY + this.viewportHeight + this.offsetCorrectionY < end) this.offsetY = end - this.viewportHeight;
64411
+ if (this.offsetY + this.viewportHeight + this.offsetCorrectionY < end) this.offsetY = end - this.viewportHeight - this.offsetCorrectionY;
64370
64412
  else if (this.offsetY + this.offsetCorrectionY > start) this.offsetY = start - this.offsetCorrectionY;
64371
64413
  this.adjustViewportZoneY();
64372
64414
  }
@@ -64381,6 +64423,9 @@ var InternalViewport = class {
64381
64423
  this.adjustViewportZoneX();
64382
64424
  this.adjustViewportZoneY();
64383
64425
  }
64426
+ isZoneVisible(zone) {
64427
+ return intersection(zone, this) !== void 0;
64428
+ }
64384
64429
  /**
64385
64430
  *
64386
64431
  * Computes the visible coordinates & dimensions of a given zone inside the viewport
@@ -64661,6 +64706,9 @@ var ViewportCollection = class {
64661
64706
  isVisibleInViewport({ sheetId, col, row }) {
64662
64707
  return this.getSubViewports(sheetId).some((pane) => pane.isVisible(col, row));
64663
64708
  }
64709
+ isZoneVisibleInViewport(sheetId, zone) {
64710
+ return this.getSubViewports(sheetId).some((pane) => pane.isZoneVisible(zone));
64711
+ }
64664
64712
  getScrollBarWidth() {
64665
64713
  return 15 / this.zoomLevel;
64666
64714
  }
@@ -67316,7 +67364,7 @@ var BottomBarSheet = class extends Component {
67316
67364
  }
67317
67365
  });
67318
67366
  this.DOMFocusableElementStore = useStore(DOMFocusableElementStore);
67319
- useExternalListener(window, "click", () => this.state.pickerOpened = false);
67367
+ useExternalListener(window, "click", this.onExternalClick.bind(this), { capture: true });
67320
67368
  useEffect((sheetId) => {
67321
67369
  if (this.props.sheetId === sheetId) this.scrollToSheet();
67322
67370
  }, () => [this.env.model.getters.getActiveSheetId()]);
@@ -67335,6 +67383,9 @@ var BottomBarSheet = class extends Component {
67335
67383
  this.env.model.off("command-rejected", this);
67336
67384
  });
67337
67385
  }
67386
+ onExternalClick(ev) {
67387
+ if (!ev.target.closest(".o-color-picker")) this.state.pickerOpened = false;
67388
+ }
67338
67389
  focusInputAndSelectContent() {
67339
67390
  if (!this.state.isEditing || !this.sheetNameRef.el) return;
67340
67391
  this.sheetNameRef.el.focus();
@@ -67438,6 +67489,8 @@ var BottomBarSheet = class extends Component {
67438
67489
  },
67439
67490
  openSheetColorPickerCallback: () => {
67440
67491
  this.state.pickerOpened = true;
67492
+ const sheet = this.env.model.getters.getSheet(this.props.sheetId);
67493
+ this.state.currentPickerColor = sheet.color;
67441
67494
  }
67442
67495
  });
67443
67496
  }
@@ -69187,18 +69240,28 @@ var NamedRangeSelector = class extends Component {
69187
69240
  return;
69188
69241
  }
69189
69242
  const activeSheetId = this.env.model.getters.getActiveSheetId();
69190
- if (activeSheetId !== sheetId) this.env.model.dispatch("ACTIVATE_SHEET", {
69191
- sheetIdFrom: activeSheetId,
69192
- sheetIdTo: sheetId
69193
- });
69194
- this.env.model.selection.selectCell(zone.right, zone.bottom);
69243
+ if (activeSheetId !== sheetId) {
69244
+ if (!this.env.model.getters.getSheet(sheetId).isVisible) {
69245
+ this.env.notifyUser({
69246
+ text: _t("The sheet on which the range is defined is hidden."),
69247
+ type: "info",
69248
+ sticky: false
69249
+ });
69250
+ return;
69251
+ }
69252
+ this.env.model.dispatch("ACTIVATE_SHEET", {
69253
+ sheetIdFrom: activeSheetId,
69254
+ sheetIdTo: sheetId
69255
+ });
69256
+ }
69257
+ this.env.model.selection.selectCell(zone.right, zone.bottom, { allowsHiddenSelection: true });
69195
69258
  this.env.model.selection.selectZone({
69196
69259
  cell: {
69197
69260
  col: zone.left,
69198
69261
  row: zone.top
69199
69262
  },
69200
69263
  zone
69201
- });
69264
+ }, { allowsHiddenSelection: true });
69202
69265
  }
69203
69266
  get selectionKey() {
69204
69267
  return `${this.env.model.getters.getActiveSheetId()}-${zoneToXc(this.selectedZone)}`;
@@ -69473,7 +69536,7 @@ var TableDropdownButton = class extends Component {
69473
69536
  this.closePopover();
69474
69537
  return;
69475
69538
  }
69476
- const pivotId = this.pivotIdInSelection;
69539
+ const pivotId = this.dynamicPivotIdInSelection;
69477
69540
  if (pivotId) {
69478
69541
  this.env.openSidePanel("PivotSidePanel", {
69479
69542
  pivotId,
@@ -69503,7 +69566,7 @@ var TableDropdownButton = class extends Component {
69503
69566
  this.state.popoverProps = void 0;
69504
69567
  }
69505
69568
  get action() {
69506
- if (this.pivotIdInSelection) return {
69569
+ if (this.dynamicPivotIdInSelection) return {
69507
69570
  name: _t("Edit pivot style"),
69508
69571
  icon: "o-spreadsheet-Icon.EDIT_TABLE"
69509
69572
  };
@@ -69522,15 +69585,19 @@ var TableDropdownButton = class extends Component {
69522
69585
  get tableStyles() {
69523
69586
  return this.env.model.getters.getTableStyles();
69524
69587
  }
69525
- get pivotIdInSelection() {
69588
+ get dynamicPivotIdInSelection() {
69526
69589
  const selection = this.env.model.getters.getSelectedZones();
69527
- for (const zone of selection) for (const position of positions(zone)) {
69528
- const sheetId = this.env.model.getters.getActiveSheetId();
69529
- const pivotId = this.env.model.getters.getPivotIdFromPosition({
69530
- sheetId,
69531
- ...position
69532
- });
69533
- if (pivotId) return pivotId;
69590
+ const pivotCellIds = new Set(this.env.model.getters.getCellsWithTrackedFormula("PIVOT"));
69591
+ if (pivotCellIds.size === 0) return;
69592
+ const activeSheetId = this.env.model.getters.getActiveSheetId();
69593
+ for (const zone of selection) for (const position of cellPositions(activeSheetId, zone)) {
69594
+ const mainPosition = this.env.model.getters.getArrayFormulaSpreadingOn(position);
69595
+ if (!mainPosition) continue;
69596
+ const cellId = this.env.model.getters.getCell(mainPosition)?.id;
69597
+ if (cellId && pivotCellIds.has(cellId)) {
69598
+ const pivotId = this.env.model.getters.getPivotIdFromPosition(mainPosition);
69599
+ if (pivotId) return pivotId;
69600
+ }
69534
69601
  }
69535
69602
  }
69536
69603
  get class() {
@@ -71603,7 +71670,7 @@ var SelectionStreamProcessorImpl = class {
71603
71670
  /**
71604
71671
  * Select a single cell as the new anchor.
71605
71672
  */
71606
- selectCell(col, row) {
71673
+ selectCell(col, row, options) {
71607
71674
  const zone = positionToZone({
71608
71675
  col,
71609
71676
  row
@@ -71614,7 +71681,10 @@ var SelectionStreamProcessorImpl = class {
71614
71681
  col,
71615
71682
  row
71616
71683
  }
71617
- }, { scrollIntoView: true });
71684
+ }, {
71685
+ scrollIntoView: true,
71686
+ ...options
71687
+ });
71618
71688
  }
71619
71689
  /**
71620
71690
  * Set the selection to one of the cells adjacent to the current anchor cell.
@@ -71969,15 +72039,21 @@ var SelectionStreamProcessorImpl = class {
71969
72039
  return DispatchResult.Success;
71970
72040
  }
71971
72041
  checkEventAnchorZone(event) {
71972
- return this.checkAnchorZone(event.anchor);
72042
+ return this.checkAnchorZone(event.anchor, event.options);
71973
72043
  }
71974
- checkAnchorZone(anchor) {
72044
+ checkAnchorZone(anchor, options) {
71975
72045
  const { cell, zone } = anchor;
71976
72046
  if (!isInside(cell.col, cell.row, zone)) return "InvalidAnchorZone";
71977
72047
  const { left, right, top, bottom } = zone;
71978
72048
  const sheetId = this.getters.getActiveSheetId();
71979
- const refCol = this.getters.findVisibleHeader(sheetId, "COL", left, right);
71980
- if (this.getters.findVisibleHeader(sheetId, "ROW", top, bottom) === void 0 || refCol === void 0) return "SelectionOutOfBound";
72049
+ if (!options?.allowsHiddenSelection) {
72050
+ const refCol = this.getters.findVisibleHeader(sheetId, "COL", left, right);
72051
+ if (this.getters.findVisibleHeader(sheetId, "ROW", top, bottom) === void 0 || refCol === void 0) return "SelectionOutOfBound";
72052
+ } else {
72053
+ const numberCols = this.getters.getNumberCols(sheetId);
72054
+ const numberRows = this.getters.getNumberRows(sheetId);
72055
+ if (left < 0 || right > numberCols - 1 || top < 0 || bottom > numberRows - 1) return "SelectionOutOfBound";
72056
+ }
71981
72057
  return "Success";
71982
72058
  }
71983
72059
  checkAnchorZoneOrThrow(anchor) {
@@ -72462,11 +72538,11 @@ function addBarChart(chart) {
72462
72538
  <!-- each data marker in the series does not have a different color -->
72463
72539
  <c:varyColors val="0"/>
72464
72540
  ${joinXmlNodes(rightDataSetsNodes)}
72465
- <c:axId val="${catAxId + 1}" />
72466
- <c:axId val="${valAxId + 1}" />
72541
+ <c:axId val="${17781238}" />
72542
+ <c:axId val="${88853994}" />
72467
72543
  </c:barChart>
72468
- ${addAx("b", "c:catAx", catAxId + 1, valAxId + 1, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
72469
- ${addAx("r", "c:valAx", valAxId + 1, catAxId + 1, chart.axesDesign?.y1?.title, chart.fontColor)}
72544
+ ${addAx("b", "c:catAx", 17781238, 88853994, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
72545
+ ${addAx("r", "c:valAx", 88853994, 17781238, chart.axesDesign?.y1?.title, chart.fontColor)}
72470
72546
  ` : ""}`;
72471
72547
  }
72472
72548
  function addComboChart(chart) {
@@ -72718,11 +72794,11 @@ function addLineChart(chart) {
72718
72794
  <c:varyColors val="0"/>
72719
72795
  ${joinXmlNodes(rightDataSetsNodes)}
72720
72796
  ${insertDataLabels({ showValues: chart.showValues })}
72721
- <c:axId val="${catAxId + 1}" />
72722
- <c:axId val="${valAxId + 1}" />
72797
+ <c:axId val="${17781238}" />
72798
+ <c:axId val="${88853994}" />
72723
72799
  </c:lineChart>
72724
- ${addAx("b", "c:catAx", catAxId + 1, valAxId + 1, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
72725
- ${addAx("r", "c:valAx", valAxId + 1, catAxId + 1, chart.axesDesign?.y1?.title, chart.fontColor)}
72800
+ ${addAx("b", "c:catAx", 17781238, 88853994, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
72801
+ ${addAx("r", "c:valAx", 88853994, 17781238, chart.axesDesign?.y1?.title, chart.fontColor)}
72726
72802
  ` : ""}
72727
72803
  `;
72728
72804
  }
@@ -72788,11 +72864,11 @@ function addScatterChart(chart) {
72788
72864
  <c:scatterStyle val="lineMarker"/>
72789
72865
  ${joinXmlNodes(rightDataSetsNodes)}
72790
72866
  ${insertDataLabels({ showValues: chart.showValues })}
72791
- <c:axId val="${catAxId + 1}" />
72792
- <c:axId val="${valAxId + 1}" />
72867
+ <c:axId val="${17781238}" />
72868
+ <c:axId val="${88853994}" />
72793
72869
  </c:scatterChart>
72794
- ${addAx("b", "c:valAx", catAxId + 1, valAxId + 1, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
72795
- ${addAx("r", "c:valAx", valAxId + 1, catAxId + 1, chart.axesDesign?.y1?.title, chart.fontColor)}
72870
+ ${addAx("b", "c:valAx", 17781238, 88853994, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
72871
+ ${addAx("r", "c:valAx", 88853994, 17781238, chart.axesDesign?.y1?.title, chart.fontColor)}
72796
72872
  ` : ""}`;
72797
72873
  }
72798
72874
  function addRadarChart(chart) {
@@ -84470,6 +84546,6 @@ const chartHelpers = {
84470
84546
  //#endregion
84471
84547
  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 };
84472
84548
 
84473
- __info__.version = "19.3.7";
84474
- __info__.date = "2026-06-17T08:57:42.174Z";
84475
- __info__.hash = "e061163";
84549
+ __info__.version = "19.3.11";
84550
+ __info__.date = "2026-07-13T06:26:28.422Z";
84551
+ __info__.hash = "35c06d3";