@odoo/o-spreadsheet 18.0.36 → 18.0.38

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 18.0.36
6
- * @date 2025-06-27T09:11:51.920Z
7
- * @hash b8dc998
5
+ * @version 18.0.38
6
+ * @date 2025-07-28T13:29:40.841Z
7
+ * @hash 0f3b11a
8
8
  */
9
9
 
10
10
  import { useEnv, useSubEnv, onWillUnmount, useComponent, status, Component, useRef, onMounted, useEffect, useState, onPatched, onWillPatch, onWillUpdateProps, useExternalListener, onWillStart, xml, useChildSubEnv, markRaw, toRaw } from '@odoo/owl';
@@ -817,6 +817,7 @@ const specialWhiteSpaceSpecialCharacters = [
817
817
  ];
818
818
  const specialWhiteSpaceRegexp = new RegExp(specialWhiteSpaceSpecialCharacters.join("|"), "g");
819
819
  const newLineRegexp = /(\r\n|\r)/g;
820
+ const whiteSpaceCharacters = specialWhiteSpaceSpecialCharacters.concat([" "]);
820
821
  /**
821
822
  * Replace all different newlines characters by \n
822
823
  */
@@ -2660,8 +2661,9 @@ const INITIAL_JS_DAY = DateTime.fromTimestamp(0);
2660
2661
  const DATE_JS_1900_OFFSET = INITIAL_JS_DAY.getTime() - INITIAL_1900_DAY.getTime();
2661
2662
  const mdyDateRegexp = /^\d{1,2}(\/|-|\s)\d{1,2}((\/|-|\s)\d{1,4})?$/;
2662
2663
  const ymdDateRegexp = /^\d{3,4}(\/|-|\s)\d{1,2}(\/|-|\s)\d{1,2}$/;
2663
- const dateSeparatorsRegex = /\/|-|\s/;
2664
- const dateRegexp = /^(\d{1,4})[\/-\s](\d{1,4})([\/-\s](\d{1,4}))?$/;
2664
+ const whiteSpaceChars = whiteSpaceCharacters.join("");
2665
+ const dateSeparatorsRegex = new RegExp(`\/|-|${whiteSpaceCharacters.join("|")}`);
2666
+ const dateRegexp = new RegExp(`^(\\d{1,4})[\/${whiteSpaceChars}\-](\\d{1,4})([\/${whiteSpaceChars}\-](\\d{1,4}))?$`);
2665
2667
  const timeRegexp = /((\d+(:\d+)?(:\d+)?\s*(AM|PM))|(\d+:\d+(:\d+)?))$/;
2666
2668
  /** Convert a value number representing a date, or return undefined if it isn't possible */
2667
2669
  function valueToDateNumber(value, locale) {
@@ -6364,6 +6366,8 @@ function splitWordToSpecificWidth(ctx, word, width, style) {
6364
6366
  function splitTextToWidth(ctx, text, style, width) {
6365
6367
  if (!style)
6366
6368
  style = {};
6369
+ if (isMarkdownLink(text))
6370
+ text = parseMarkdownLink(text).label;
6367
6371
  const brokenText = [];
6368
6372
  // Checking if text contains NEWLINE before split makes it very slightly slower if text contains it,
6369
6373
  // but 5-10x faster if it doesn't
@@ -8317,6 +8321,10 @@ function toNormalizedPivotValue(dimension, groupValue) {
8317
8321
  if (groupValue === null || groupValue === "null") {
8318
8322
  return null;
8319
8323
  }
8324
+ const extractedGroupValue = typeof groupValue === "object" ? groupValue.value : groupValue;
8325
+ if (isEvaluationError(extractedGroupValue)) {
8326
+ return extractedGroupValue;
8327
+ }
8320
8328
  const groupValueString = typeof groupValue === "boolean"
8321
8329
  ? toString(groupValue).toLocaleLowerCase()
8322
8330
  : toString(groupValue);
@@ -12964,38 +12972,111 @@ function convertPivotTableConfig(pivotTable) {
12964
12972
  * In all the sheets, replace the table-only references in the formula cells with standard references.
12965
12973
  */
12966
12974
  function convertTableFormulaReferences(convertedSheets, xlsxSheets) {
12975
+ let deconstructedSheets = null;
12967
12976
  for (let tableSheet of convertedSheets) {
12968
12977
  const tables = xlsxSheets.find((s) => isSheetNameEqual(s.sheetName, tableSheet.name)).tables;
12978
+ if (!tables || tables.length === 0) {
12979
+ continue;
12980
+ }
12981
+ // Only deconstruct sheets if we are sure there are tables to process
12982
+ if (!deconstructedSheets) {
12983
+ deconstructedSheets = deconstructSheets(convertedSheets);
12984
+ }
12969
12985
  for (let table of tables) {
12970
- const tabRef = table.name + "[";
12971
- for (let sheet of convertedSheets) {
12972
- for (let xc in sheet.cells) {
12973
- const cell = sheet.cells[xc];
12974
- if (cell && cell.content && cell.content.startsWith("=")) {
12975
- let refIndex;
12976
- while ((refIndex = cell.content.indexOf(tabRef)) !== -1) {
12977
- let endIndex = refIndex + tabRef.length;
12978
- let openBrackets = 1;
12979
- while (openBrackets > 0 && endIndex < cell.content.length) {
12980
- if (cell.content[endIndex] === "[") {
12981
- openBrackets++;
12982
- }
12983
- else if (cell.content[endIndex] === "]") {
12984
- openBrackets--;
12985
- }
12986
- endIndex++;
12987
- }
12988
- let reference = cell.content.slice(refIndex + tabRef.length, endIndex - 1);
12989
- const sheetPrefix = tableSheet.id === sheet.id ? "" : tableSheet.name + "!";
12990
- const convertedRef = convertTableReference(sheetPrefix, reference, table, xc);
12991
- cell.content =
12992
- cell.content.slice(0, refIndex) + convertedRef + cell.content.slice(endIndex);
12986
+ for (let sheetId in deconstructedSheets) {
12987
+ const sheet = convertedSheets.find((s) => s.id === sheetId);
12988
+ for (let xc in deconstructedSheets[sheetId]) {
12989
+ const deconstructedCell = deconstructedSheets[sheetId][xc];
12990
+ for (let i = deconstructedCell.length - 3; i >= 0; i -= 2) {
12991
+ const possibleTable = deconstructedSheets[sheetId][xc][i];
12992
+ if (!possibleTable.endsWith(table.name)) {
12993
+ continue;
12993
12994
  }
12995
+ const possibleRef = deconstructedSheets[sheetId][xc][i + 1];
12996
+ const sheetPrefix = tableSheet.id === sheet.id ? "" : tableSheet.name + "!";
12997
+ const convertedRef = convertTableReference(sheetPrefix, possibleRef, table, xc);
12998
+ deconstructedSheets[sheetId][xc][i + 2] =
12999
+ possibleTable.slice(0, possibleTable.indexOf(table.name)) +
13000
+ convertedRef +
13001
+ deconstructedSheets[sheetId][xc][i + 2];
13002
+ deconstructedSheets[sheetId][xc].splice(i, 2);
12994
13003
  }
12995
13004
  }
12996
13005
  }
12997
13006
  }
12998
13007
  }
13008
+ if (!deconstructedSheets) {
13009
+ return;
13010
+ }
13011
+ for (let sheetId in deconstructedSheets) {
13012
+ const sheet = convertedSheets.find((s) => s.id === sheetId);
13013
+ for (let xc in deconstructedSheets[sheetId]) {
13014
+ const deconstructedCell = deconstructedSheets[sheetId][xc];
13015
+ if (deconstructedCell.length === 1) {
13016
+ sheet.cells[xc].content = deconstructedCell[0];
13017
+ continue;
13018
+ }
13019
+ let newContent = "";
13020
+ for (let i = 0; i < deconstructedCell.length; i += 2) {
13021
+ newContent += deconstructedCell[i] + "[" + deconstructedCell[i + 1] + "]";
13022
+ }
13023
+ newContent += deconstructedCell[deconstructedCell.length - 1];
13024
+ sheet.cells[xc].content = newContent;
13025
+ }
13026
+ }
13027
+ }
13028
+ /**
13029
+ * Deconstruct the content of the cells in the sheets to extract possible table references.
13030
+ * Example from "=AVERAGE(Table1[colName1])-AVERAGE(Table2[colName2])":
13031
+ * return --> ["=AVERAGE(Table1", "colName1", ")-AVERAGE(Table2", "colName2", ")"]
13032
+ */
13033
+ function deconstructSheets(convertedSheets) {
13034
+ const deconstructedSheets = {};
13035
+ for (let sheet of convertedSheets) {
13036
+ for (let xc in sheet.cells) {
13037
+ const cellContent = sheet.cells[xc]?.content;
13038
+ if (!cellContent || !cellContent.startsWith("=")) {
13039
+ continue;
13040
+ }
13041
+ const startIndex = cellContent.indexOf("[");
13042
+ if (startIndex === -1) {
13043
+ continue;
13044
+ }
13045
+ const deconstructedCell = [];
13046
+ let possibleTable = cellContent.slice(0, startIndex);
13047
+ let possibleRef = "";
13048
+ let openBrackets = 1;
13049
+ let mainPossibleTableIndex = 0;
13050
+ let mainOpenBracketIndex = startIndex;
13051
+ for (let index = startIndex + 1; index < cellContent.length; index++) {
13052
+ if (cellContent[index] === "[") {
13053
+ if (openBrackets === 0) {
13054
+ possibleTable = cellContent.slice(mainPossibleTableIndex, index);
13055
+ mainOpenBracketIndex = index;
13056
+ }
13057
+ openBrackets++;
13058
+ continue;
13059
+ }
13060
+ if (cellContent[index] === "]") {
13061
+ openBrackets--;
13062
+ if (openBrackets === 0) {
13063
+ possibleRef = cellContent.slice(mainOpenBracketIndex + 1, index);
13064
+ deconstructedCell.push(possibleTable);
13065
+ deconstructedCell.push(possibleRef);
13066
+ mainPossibleTableIndex = index + 1;
13067
+ }
13068
+ }
13069
+ }
13070
+ if (deconstructedCell.length) {
13071
+ if (!deconstructedSheets[sheet.id]) {
13072
+ deconstructedSheets[sheet.id] = {};
13073
+ }
13074
+ deconstructedCell.push(cellContent.slice(mainPossibleTableIndex));
13075
+ deconstructedSheets[sheet.id][xc] = [...deconstructedCell];
13076
+ }
13077
+ }
13078
+ }
13079
+ return deconstructedSheets;
12999
13080
  }
13000
13081
  /**
13001
13082
  * Convert table-specific references in formulas into standard references. A table reference is composed of columns names,
@@ -17294,6 +17375,7 @@ const autoCompleteProviders = new Registry();
17294
17375
 
17295
17376
  autoCompleteProviders.add("dataValidation", {
17296
17377
  displayAllOnInitialContent: true,
17378
+ canBeToggled: false,
17297
17379
  getProposals(tokenAtCursor, content) {
17298
17380
  if (content.startsWith("=")) {
17299
17381
  return [];
@@ -24949,11 +25031,17 @@ const COLUMN = {
24949
25031
  if (isEvaluationError(cellReference?.value)) {
24950
25032
  return cellReference;
24951
25033
  }
24952
- const column = cellReference === undefined
24953
- ? this.__originCellPosition?.col
24954
- : toZone(cellReference.value).left;
24955
- assert(() => column !== undefined, "In this context, the function [[FUNCTION_NAME]] needs to have a cell or range in parameter.");
24956
- return column + 1;
25034
+ if (cellReference === undefined) {
25035
+ assert(() => this.__originCellPosition?.col !== undefined, "In this context, the function [[FUNCTION_NAME]] needs to have a cell or range in parameter.");
25036
+ return this.__originCellPosition.col + 1;
25037
+ }
25038
+ const zone = this.getters.getRangeFromSheetXC(this.getters.getActiveSheetId(), cellReference.value).zone;
25039
+ if (zone.left === zone.right) {
25040
+ return zone.left + 1;
25041
+ }
25042
+ return generateMatrix(zone.right - zone.left + 1, 1, (col, row) => ({
25043
+ value: zone.left + col + 1,
25044
+ }));
24957
25045
  },
24958
25046
  isExported: true,
24959
25047
  };
@@ -25172,11 +25260,17 @@ const ROW = {
25172
25260
  if (isEvaluationError(cellReference?.value)) {
25173
25261
  return cellReference;
25174
25262
  }
25175
- const row = cellReference === undefined
25176
- ? this.__originCellPosition?.row
25177
- : toZone(cellReference.value).top;
25178
- assert(() => row !== undefined, "In this context, the function [[FUNCTION_NAME]] needs to have a cell or range in parameter.");
25179
- return row + 1;
25263
+ if (cellReference === undefined) {
25264
+ assert(() => this.__originCellPosition?.row !== undefined, "In this context, the function [[FUNCTION_NAME]] needs to have a cell or range in parameter.");
25265
+ return this.__originCellPosition.row + 1;
25266
+ }
25267
+ const zone = this.getters.getRangeFromSheetXC(this.getters.getActiveSheetId(), cellReference.value).zone;
25268
+ if (zone.top === zone.bottom) {
25269
+ return zone.top + 1;
25270
+ }
25271
+ return generateMatrix(1, zone.bottom - zone.top + 1, (col, row) => ({
25272
+ value: zone.top + row + 1,
25273
+ }));
25180
25274
  },
25181
25275
  isExported: true,
25182
25276
  };
@@ -27832,9 +27926,13 @@ class Composer extends Component {
27832
27926
  }
27833
27927
  }
27834
27928
  closeAssistant() {
27929
+ if (!this.canBeToggled)
27930
+ return;
27835
27931
  this.assistant.forcedClosed = true;
27836
27932
  }
27837
27933
  openAssistant() {
27934
+ if (!this.canBeToggled)
27935
+ return;
27838
27936
  this.assistant.forcedClosed = false;
27839
27937
  }
27840
27938
  onWheel(event) {
@@ -27844,6 +27942,9 @@ class Composer extends Component {
27844
27942
  event.stopPropagation();
27845
27943
  }
27846
27944
  }
27945
+ get canBeToggled() {
27946
+ return this.autoCompleteState.provider?.canBeToggled ?? true;
27947
+ }
27847
27948
  // ---------------------------------------------------------------------------
27848
27949
  // Private
27849
27950
  // ---------------------------------------------------------------------------
@@ -28026,7 +28127,7 @@ class Composer extends Component {
28026
28127
  }
28027
28128
  }
28028
28129
  autoComplete(value) {
28029
- if (!value || this.assistant.forcedClosed) {
28130
+ if (!value || (this.assistant.forcedClosed && this.canBeToggled)) {
28030
28131
  return;
28031
28132
  }
28032
28133
  this.autoCompleteState.provider?.selectProposal(value);
@@ -39598,6 +39699,7 @@ class AbstractComposerStore extends SpreadsheetStore {
39598
39699
  proposals,
39599
39700
  selectProposal: provider.selectProposal,
39600
39701
  autoSelectFirstProposal: provider.autoSelectFirstProposal ?? false,
39702
+ canBeToggled: provider.canBeToggled,
39601
39703
  };
39602
39704
  }
39603
39705
  if (exactMatch && this._currentContent !== this.initialContent) {
@@ -39620,6 +39722,7 @@ class AbstractComposerStore extends SpreadsheetStore {
39620
39722
  proposals,
39621
39723
  selectProposal: provider.selectProposal,
39622
39724
  autoSelectFirstProposal: provider.autoSelectFirstProposal ?? false,
39725
+ canBeToggled: provider.canBeToggled,
39623
39726
  };
39624
39727
  }
39625
39728
  }
@@ -44566,10 +44669,7 @@ class SpreadsheetPivot {
44566
44669
  if (finalCell.value === null) {
44567
44670
  return { value: _t("(Undefined)") };
44568
44671
  }
44569
- return {
44570
- value: finalCell.value,
44571
- format: finalCell.format,
44572
- };
44672
+ return finalCell;
44573
44673
  }
44574
44674
  getPivotCellValueAndFormat(measureId, domain) {
44575
44675
  const dataEntries = this.filterDataEntriesFromDomain(this.dataEntries, domain);
@@ -44662,9 +44762,15 @@ class SpreadsheetPivot {
44662
44762
  return domain.reduce((current, acc) => this.filterDataEntriesFromDomainNode(current, acc), dataEntries);
44663
44763
  }
44664
44764
  filterDataEntriesFromDomainNode(dataEntries, domain) {
44665
- const { field, value } = domain;
44765
+ const { field, value, type } = domain;
44666
44766
  const { nameWithGranularity } = this.getDimension(field);
44667
- return dataEntries.filter((entry) => entry[nameWithGranularity]?.value === value);
44767
+ return dataEntries.filter((entry) => {
44768
+ const cellValue = entry[nameWithGranularity]?.value;
44769
+ if (type === "char") {
44770
+ return String(cellValue) === String(value);
44771
+ }
44772
+ return cellValue === value;
44773
+ });
44668
44774
  }
44669
44775
  getDimension(nameWithGranularity) {
44670
44776
  return this.definition.getDimension(nameWithGranularity);
@@ -44800,7 +44906,6 @@ pivotRegistry.add("SPREADSHEET", {
44800
44906
  ui: SpreadsheetPivot,
44801
44907
  definition: SpreadsheetPivotRuntimeDefinition,
44802
44908
  externalData: false,
44803
- onIterationEndEvaluation: (pivot) => pivot.markAsDirtyForEvaluation(),
44804
44909
  dateGranularities: [...dateGranularities],
44805
44910
  datetimeGranularities: [...dateGranularities, "hour_number", "minute_number", "second_number"],
44806
44911
  isMeasureCandidate: (field) => !["datetime", "boolean"].includes(field.type),
@@ -47140,6 +47245,11 @@ class GridComposer extends Component {
47140
47245
  rect = this.defaultRect;
47141
47246
  isEditing = false;
47142
47247
  isCellReferenceVisible = false;
47248
+ currentEditedCell = {
47249
+ col: 0,
47250
+ row: 0,
47251
+ sheetId: this.env.model.getters.getActiveSheetId(),
47252
+ };
47143
47253
  composerStore;
47144
47254
  composerFocusStore;
47145
47255
  composerInterface;
@@ -47169,7 +47279,7 @@ class GridComposer extends Component {
47169
47279
  return this.isCellReferenceVisible;
47170
47280
  }
47171
47281
  get cellReference() {
47172
- const { col, row, sheetId } = this.composerStore.currentEditedCell;
47282
+ const { col, row, sheetId } = this.currentEditedCell;
47173
47283
  const prefixSheet = sheetId !== this.env.model.getters.getActiveSheetId();
47174
47284
  return getFullReference(prefixSheet ? this.env.model.getters.getSheetName(sheetId) : undefined, toXC(col, row));
47175
47285
  }
@@ -47262,12 +47372,17 @@ class GridComposer extends Component {
47262
47372
  if (!isEditing && this.composerFocusStore.activeComposer !== this.composerInterface) {
47263
47373
  this.composerFocusStore.focusComposer(this.composerInterface, { focusMode: "inactive" });
47264
47374
  }
47375
+ let shouldRecomputeRect = isEditing && !deepEquals(this.currentEditedCell, this.composerStore.currentEditedCell);
47265
47376
  if (this.isEditing !== isEditing) {
47266
47377
  this.isEditing = isEditing;
47267
47378
  if (!isEditing) {
47268
47379
  this.rect = this.defaultRect;
47269
47380
  return;
47270
47381
  }
47382
+ this.currentEditedCell = this.composerStore.currentEditedCell;
47383
+ shouldRecomputeRect = true;
47384
+ }
47385
+ if (shouldRecomputeRect) {
47271
47386
  const position = this.env.model.getters.getActivePosition();
47272
47387
  const zone = this.env.model.getters.expandZone(position.sheetId, positionToZone(position));
47273
47388
  this.rect = this.env.model.getters.getVisibleRect(zone);
@@ -57471,7 +57586,7 @@ const onIterationEndEvaluationRegistry = new Registry();
57471
57586
  onIterationEndEvaluationRegistry.add("pivots", (getters) => {
57472
57587
  for (const pivotId of getters.getPivotIds()) {
57473
57588
  const pivot = getters.getPivot(pivotId);
57474
- pivotRegistry.get(pivot.type).onIterationEndEvaluation(pivot);
57589
+ pivot.markAsDirtyForEvaluation?.();
57475
57590
  }
57476
57591
  });
57477
57592
 
@@ -60334,6 +60449,23 @@ class HeaderSizeUIPlugin extends UIPlugin {
60334
60449
  static getters = ["getRowSize", "getHeaderSize"];
60335
60450
  tallestCellInRow = {};
60336
60451
  ctx = document.createElement("canvas").getContext("2d");
60452
+ beforeHandle(cmd) {
60453
+ switch (cmd.type) {
60454
+ // Ensure rows are updated before "UPDATE_CELL" is dispatched from cell plugin.
60455
+ // "UPDATE_CELL" uses the Sheet core plugin to access row data.
60456
+ // If "ADD_COLUMNS_ROWS" has not been processed yet by header_sizes_ui,
60457
+ // size updates may apply to incorrect (pre-insert) rows.
60458
+ case "ADD_COLUMNS_ROWS":
60459
+ if (cmd.dimension === "COL") {
60460
+ return;
60461
+ }
60462
+ const addIndex = getAddHeaderStartIndex(cmd.position, cmd.base);
60463
+ const newCells = Array(cmd.quantity).fill(undefined);
60464
+ const newTallestCells = insertItemsAtIndex(this.tallestCellInRow[cmd.sheetId], newCells, addIndex);
60465
+ this.history.update("tallestCellInRow", cmd.sheetId, newTallestCells);
60466
+ break;
60467
+ }
60468
+ }
60337
60469
  handle(cmd) {
60338
60470
  switch (cmd.type) {
60339
60471
  case "START":
@@ -60363,16 +60495,6 @@ class HeaderSizeUIPlugin extends UIPlugin {
60363
60495
  this.history.update("tallestCellInRow", cmd.sheetId, tallestCells);
60364
60496
  break;
60365
60497
  }
60366
- case "ADD_COLUMNS_ROWS": {
60367
- if (cmd.dimension === "COL") {
60368
- return;
60369
- }
60370
- const addIndex = getAddHeaderStartIndex(cmd.position, cmd.base);
60371
- const newCells = Array(cmd.quantity).fill(undefined);
60372
- const newTallestCells = insertItemsAtIndex(this.tallestCellInRow[cmd.sheetId], newCells, addIndex);
60373
- this.history.update("tallestCellInRow", cmd.sheetId, newTallestCells);
60374
- break;
60375
- }
60376
60498
  case "RESIZE_COLUMNS_ROWS":
60377
60499
  {
60378
60500
  const sheetId = cmd.sheetId;
@@ -60508,13 +60630,13 @@ function withPivotPresentationLayer (PivotClass) {
60508
60630
  super(custom, params);
60509
60631
  this.getters = params.getters;
60510
60632
  }
60511
- init(params) {
60633
+ markAsDirtyForEvaluation() {
60512
60634
  this.cache = {};
60513
60635
  this.rankAsc = {};
60514
60636
  this.rankDesc = {};
60515
60637
  this.runningTotal = {};
60516
60638
  this.runningTotalInPercent = {};
60517
- super.init(params);
60639
+ super.markAsDirtyForEvaluation?.();
60518
60640
  }
60519
60641
  getPivotCellValueAndFormat(measureName, domain) {
60520
60642
  return this.getMeasureDisplayValue(measureName, domain);
@@ -60639,7 +60761,7 @@ function withPivotPresentationLayer (PivotClass) {
60639
60761
  return this.getSubTreeMatchingDomain(node.children, domain, domainLevel + 1);
60640
60762
  }
60641
60763
  }
60642
- return tree;
60764
+ return [];
60643
60765
  }
60644
60766
  treeToLeafDomains(tree, parentDomain = []) {
60645
60767
  const domains = [];
@@ -66061,6 +66183,14 @@ class GridSelectionPlugin extends UIPlugin {
66061
66183
  const isBasedBefore = cmd.base < start;
66062
66184
  const deltaCol = isBasedBefore && isCol ? thickness : 0;
66063
66185
  const deltaRow = isBasedBefore && !isCol ? thickness : 0;
66186
+ const toRemove = isBasedBefore ? cmd.elements.map((el) => el + thickness) : cmd.elements;
66187
+ const originalSize = Object.fromEntries(toRemove.map((element) => {
66188
+ const size = isCol
66189
+ ? this.getters.getColSize(cmd.sheetId, element)
66190
+ : this.getters.getUserRowSize(cmd.sheetId, element);
66191
+ const isDefaultCol = isCol && size === DEFAULT_CELL_WIDTH;
66192
+ return [element, isDefaultCol || size === undefined ? null : size];
66193
+ }));
66064
66194
  const target = [
66065
66195
  {
66066
66196
  left: isCol ? start + deltaCol : 0,
@@ -66091,14 +66221,12 @@ class GridSelectionPlugin extends UIPlugin {
66091
66221
  const col = selection.left;
66092
66222
  const row = selection.top;
66093
66223
  this.setSelectionMixin({ zone: selection, cell: { col, row } }, [selection]);
66094
- const toRemove = isBasedBefore ? cmd.elements.map((el) => el + thickness) : cmd.elements;
66095
66224
  let currentIndex = isBasedBefore ? cmd.base : cmd.base + 1;
66096
66225
  for (const element of toRemove) {
66097
- const size = this.getters.getHeaderSize(cmd.sheetId, cmd.dimension, element);
66098
66226
  this.dispatch("RESIZE_COLUMNS_ROWS", {
66099
66227
  dimension: cmd.dimension,
66100
66228
  sheetId: cmd.sheetId,
66101
- size,
66229
+ size: originalSize[element],
66102
66230
  elements: [currentIndex],
66103
66231
  });
66104
66232
  currentIndex += 1;
@@ -67810,14 +67938,12 @@ class BottomBarSheet extends Component {
67810
67938
  this.editionState = "initializing";
67811
67939
  }
67812
67940
  stopEdition() {
67813
- const input = this.sheetNameRef.el;
67814
- if (!this.state.isEditing || !input)
67941
+ if (!this.state.isEditing || !this.sheetNameRef.el)
67815
67942
  return;
67816
67943
  this.state.isEditing = false;
67817
67944
  this.editionState = "initializing";
67818
- input.blur();
67945
+ this.sheetNameRef.el.blur();
67819
67946
  const inputValue = this.getInputContent() || "";
67820
- input.innerText = inputValue;
67821
67947
  interactiveRenameSheet(this.env, this.props.sheetId, inputValue, () => this.startEdition());
67822
67948
  }
67823
67949
  cancelEdition() {
@@ -74469,6 +74595,6 @@ const constants = {
74469
74595
  export { AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, CellErrorType, CommandResult, CorePlugin, DispatchResult, EvaluationError, Model, PivotRuntimeDefinition, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, SpreadsheetPivotTable, UIPlugin, __info__, addFunction, addRenderingLayer, astToFormula, compile, compileTokens, components, constants, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, hooks, invalidateCFEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, iterateAstNodes, links, load, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
74470
74596
 
74471
74597
 
74472
- __info__.version = "18.0.36";
74473
- __info__.date = "2025-06-27T09:11:51.920Z";
74474
- __info__.hash = "b8dc998";
74598
+ __info__.version = "18.0.38";
74599
+ __info__.date = "2025-07-28T13:29:40.841Z";
74600
+ __info__.hash = "0f3b11a";