@odoo/o-spreadsheet 18.3.19 → 18.3.20
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.3.
|
|
6
|
-
* @date 2025-09-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 18.3.20
|
|
6
|
+
* @date 2025-09-11T08:45:37.934Z
|
|
7
|
+
* @hash ef829f4
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
'use strict';
|
|
@@ -7209,7 +7209,7 @@ class ClipboardHandler {
|
|
|
7209
7209
|
this.getters = getters;
|
|
7210
7210
|
this.dispatch = dispatch;
|
|
7211
7211
|
}
|
|
7212
|
-
copy(data, isCutOperation) {
|
|
7212
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
7213
7213
|
return;
|
|
7214
7214
|
}
|
|
7215
7215
|
paste(target, clippedContent, options) { }
|
|
@@ -7228,7 +7228,7 @@ class ClipboardHandler {
|
|
|
7228
7228
|
}
|
|
7229
7229
|
|
|
7230
7230
|
class AbstractCellClipboardHandler extends ClipboardHandler {
|
|
7231
|
-
copy(data) {
|
|
7231
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
7232
7232
|
return;
|
|
7233
7233
|
}
|
|
7234
7234
|
pasteFromCopy(sheetId, target, content, options) {
|
|
@@ -8951,7 +8951,7 @@ class CellClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
8951
8951
|
}
|
|
8952
8952
|
return "Success" /* CommandResult.Success */;
|
|
8953
8953
|
}
|
|
8954
|
-
copy(data) {
|
|
8954
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
8955
8955
|
const sheetId = data.sheetId;
|
|
8956
8956
|
const { clippedZones, rowsIndexes, columnsIndexes } = data;
|
|
8957
8957
|
const clippedCells = [];
|
|
@@ -8964,7 +8964,7 @@ class CellClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
8964
8964
|
const evaluatedCell = this.getters.getEvaluatedCell(position);
|
|
8965
8965
|
const pivotId = this.getters.getPivotIdFromPosition(position);
|
|
8966
8966
|
const spreader = this.getters.getArrayFormulaSpreadingOn(position);
|
|
8967
|
-
if (pivotId && spreader) {
|
|
8967
|
+
if (mode !== "shiftCells" && pivotId && spreader) {
|
|
8968
8968
|
const pivotZone = this.getters.getSpreadZone(spreader);
|
|
8969
8969
|
if ((!deepEquals(spreader, position) || !isCopyingOneCell) &&
|
|
8970
8970
|
pivotZone &&
|
|
@@ -8982,7 +8982,7 @@ class CellClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
8982
8982
|
};
|
|
8983
8983
|
}
|
|
8984
8984
|
}
|
|
8985
|
-
else {
|
|
8985
|
+
else if (mode !== "shiftCells") {
|
|
8986
8986
|
if (spreader && !deepEquals(spreader, position)) {
|
|
8987
8987
|
const isSpreaderCopied = rowsIndexes.includes(spreader.row) && columnsIndexes.includes(spreader.col);
|
|
8988
8988
|
const content = isSpreaderCopied
|
|
@@ -9682,7 +9682,7 @@ class SheetClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
9682
9682
|
}
|
|
9683
9683
|
|
|
9684
9684
|
class TableClipboardHandler extends AbstractCellClipboardHandler {
|
|
9685
|
-
copy(data, isCutOperation) {
|
|
9685
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
9686
9686
|
const sheetId = data.sheetId;
|
|
9687
9687
|
const { rowsIndexes, columnsIndexes, zones } = data;
|
|
9688
9688
|
const copiedTablesIds = new Set();
|
|
@@ -9720,11 +9720,13 @@ class TableClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
9720
9720
|
type: coreTable.type,
|
|
9721
9721
|
};
|
|
9722
9722
|
}
|
|
9723
|
-
|
|
9724
|
-
|
|
9725
|
-
|
|
9726
|
-
|
|
9727
|
-
|
|
9723
|
+
if (mode !== "shiftCells") {
|
|
9724
|
+
tableCellsInRow.push({
|
|
9725
|
+
table: copiedTable,
|
|
9726
|
+
style: this.getTableStyleToCopy(position),
|
|
9727
|
+
isWholeTableCopied: copiedTablesIds.has(table.id),
|
|
9728
|
+
});
|
|
9729
|
+
}
|
|
9728
9730
|
}
|
|
9729
9731
|
}
|
|
9730
9732
|
return {
|
|
@@ -30886,7 +30888,7 @@ const SUPPORTED_HORIZONTAL_ALIGNMENTS = [
|
|
|
30886
30888
|
];
|
|
30887
30889
|
const SUPPORTED_VERTICAL_ALIGNMENTS = ["top", "center", "bottom"];
|
|
30888
30890
|
const SUPPORTED_FONTS = ["Arial"];
|
|
30889
|
-
const SUPPORTED_FILL_PATTERNS = ["solid"];
|
|
30891
|
+
const SUPPORTED_FILL_PATTERNS = ["solid", "none"];
|
|
30890
30892
|
const SUPPORTED_CF_TYPES = [
|
|
30891
30893
|
"expression",
|
|
30892
30894
|
"cellIs",
|
|
@@ -31071,7 +31073,7 @@ const SUBTOTAL_FUNCTION_CONVERSION_MAP = {
|
|
|
31071
31073
|
};
|
|
31072
31074
|
/** Mapping between Excel format indexes (see XLSX_FORMAT_MAP) and some supported formats */
|
|
31073
31075
|
const XLSX_FORMATS_CONVERSION_MAP = {
|
|
31074
|
-
0: "",
|
|
31076
|
+
0: "General",
|
|
31075
31077
|
1: "0",
|
|
31076
31078
|
2: "0.00",
|
|
31077
31079
|
3: "#,#00",
|
|
@@ -31397,11 +31399,11 @@ const XLSX_DATE_FORMAT_REGEX = /^(yy|yyyy|m{1,5}|d{1,4}|h{1,2}|s{1,2}|am\/pm|a\/
|
|
|
31397
31399
|
* Excel format are defined in openXML §18.8.31
|
|
31398
31400
|
*/
|
|
31399
31401
|
function convertXlsxFormat(numFmtId, formats, warningManager) {
|
|
31400
|
-
if (numFmtId === 0) {
|
|
31401
|
-
return undefined;
|
|
31402
|
-
}
|
|
31403
31402
|
// Format is either defined in the imported data, or the formatId is defined in openXML §18.8.30
|
|
31404
31403
|
let format = XLSX_FORMATS_CONVERSION_MAP[numFmtId] || formats.find((f) => f.id === numFmtId)?.format;
|
|
31404
|
+
if (format === "General") {
|
|
31405
|
+
return undefined;
|
|
31406
|
+
}
|
|
31405
31407
|
if (format) {
|
|
31406
31408
|
try {
|
|
31407
31409
|
let convertedFormat = format.replace(/\[(.*)-[A-Z0-9]{3}\]/g, "[$1]"); // remove currency and locale/date system/number system info (ECMA §18.8.31)
|
|
@@ -34246,10 +34248,11 @@ class XlsxSheetExtractor extends XlsxBaseExtractor {
|
|
|
34246
34248
|
});
|
|
34247
34249
|
}
|
|
34248
34250
|
extractRows(worksheet) {
|
|
34251
|
+
const spilledCells = new Set();
|
|
34249
34252
|
return this.mapOnElements({ parent: worksheet, query: "sheetData row" }, (rowElement) => {
|
|
34250
34253
|
return {
|
|
34251
34254
|
index: this.extractAttr(rowElement, "r", { required: true })?.asNum(),
|
|
34252
|
-
cells: this.extractCells(rowElement),
|
|
34255
|
+
cells: this.extractCells(rowElement, spilledCells),
|
|
34253
34256
|
height: this.extractAttr(rowElement, "ht")?.asNum(),
|
|
34254
34257
|
customHeight: this.extractAttr(rowElement, "customHeight")?.asBool(),
|
|
34255
34258
|
hidden: this.extractAttr(rowElement, "hidden")?.asBool(),
|
|
@@ -34259,14 +34262,26 @@ class XlsxSheetExtractor extends XlsxBaseExtractor {
|
|
|
34259
34262
|
};
|
|
34260
34263
|
});
|
|
34261
34264
|
}
|
|
34262
|
-
extractCells(row) {
|
|
34265
|
+
extractCells(row, spilledCells) {
|
|
34263
34266
|
return this.mapOnElements({ parent: row, query: "c" }, (cellElement) => {
|
|
34267
|
+
const xc = this.extractAttr(cellElement, "r", { required: true })?.asString();
|
|
34268
|
+
const formula = this.extractCellFormula(cellElement);
|
|
34269
|
+
if (formula?.ref && formula.sharedIndex === undefined) {
|
|
34270
|
+
const zone = toZone(formula.ref);
|
|
34271
|
+
for (const { col, row } of positions(zone)) {
|
|
34272
|
+
const followerXc = toXC(col, row);
|
|
34273
|
+
if (followerXc !== xc) {
|
|
34274
|
+
spilledCells.add(followerXc);
|
|
34275
|
+
}
|
|
34276
|
+
}
|
|
34277
|
+
}
|
|
34278
|
+
const isSpilled = spilledCells.has(xc);
|
|
34264
34279
|
return {
|
|
34265
|
-
xc
|
|
34280
|
+
xc,
|
|
34266
34281
|
styleIndex: this.extractAttr(cellElement, "s")?.asNum(),
|
|
34267
34282
|
type: CELL_TYPE_CONVERSION_MAP[this.extractAttr(cellElement, "t", { default: "n" })?.asString()],
|
|
34268
|
-
value: this.extractChildTextContent(cellElement, "v"),
|
|
34269
|
-
formula:
|
|
34283
|
+
value: isSpilled ? undefined : this.extractChildTextContent(cellElement, "v") ?? undefined,
|
|
34284
|
+
formula: isSpilled ? undefined : formula,
|
|
34270
34285
|
};
|
|
34271
34286
|
});
|
|
34272
34287
|
}
|
|
@@ -34274,11 +34289,14 @@ class XlsxSheetExtractor extends XlsxBaseExtractor {
|
|
|
34274
34289
|
const formulaElement = this.querySelector(cellElement, "f");
|
|
34275
34290
|
if (!formulaElement)
|
|
34276
34291
|
return undefined;
|
|
34277
|
-
|
|
34278
|
-
|
|
34279
|
-
|
|
34280
|
-
|
|
34281
|
-
|
|
34292
|
+
const content = this.extractTextContent(formulaElement);
|
|
34293
|
+
const sharedIndex = this.extractAttr(formulaElement, "si")?.asNum();
|
|
34294
|
+
const ref = this.extractAttr(formulaElement, "ref")?.asString();
|
|
34295
|
+
// This is the case of spilled cells of array formulas where <f> is empty
|
|
34296
|
+
if ((content === undefined || content.trim() === "") && sharedIndex === undefined) {
|
|
34297
|
+
return undefined;
|
|
34298
|
+
}
|
|
34299
|
+
return { content, sharedIndex, ref };
|
|
34282
34300
|
}
|
|
34283
34301
|
extractHyperLinks(worksheet) {
|
|
34284
34302
|
return this.mapOnElements({ parent: worksheet, query: "hyperlink" }, (linkElement) => {
|
|
@@ -68831,7 +68849,7 @@ class DataCleanupPlugin extends UIPlugin {
|
|
|
68831
68849
|
bottom: rowIndex,
|
|
68832
68850
|
}));
|
|
68833
68851
|
const handler = new CellClipboardHandler(this.getters, this.dispatch);
|
|
68834
|
-
const data = handler.copy(getClipboardDataPositions(sheetId, rowsToKeep));
|
|
68852
|
+
const data = handler.copy(getClipboardDataPositions(sheetId, rowsToKeep), false);
|
|
68835
68853
|
if (!data) {
|
|
68836
68854
|
return;
|
|
68837
68855
|
}
|
|
@@ -70871,12 +70889,12 @@ class ClipboardPlugin extends UIPlugin {
|
|
|
70871
70889
|
}
|
|
70872
70890
|
case "INSERT_CELL": {
|
|
70873
70891
|
const { cut, paste } = this.getInsertCellsTargets(cmd.zone, cmd.shiftDimension);
|
|
70874
|
-
const copiedData = this.copy(cut);
|
|
70892
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70875
70893
|
return this.isPasteAllowed(paste, copiedData, { isCutOperation: true });
|
|
70876
70894
|
}
|
|
70877
70895
|
case "DELETE_CELL": {
|
|
70878
70896
|
const { cut, paste } = this.getDeleteCellsTargets(cmd.zone, cmd.shiftDimension);
|
|
70879
|
-
const copiedData = this.copy(cut);
|
|
70897
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70880
70898
|
return this.isPasteAllowed(paste, copiedData, { isCutOperation: true });
|
|
70881
70899
|
}
|
|
70882
70900
|
}
|
|
@@ -70987,13 +71005,13 @@ class ClipboardPlugin extends UIPlugin {
|
|
|
70987
71005
|
});
|
|
70988
71006
|
break;
|
|
70989
71007
|
}
|
|
70990
|
-
const copiedData = this.copy(cut);
|
|
71008
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70991
71009
|
this.paste(paste, copiedData, { isCutOperation: true });
|
|
70992
71010
|
break;
|
|
70993
71011
|
}
|
|
70994
71012
|
case "INSERT_CELL": {
|
|
70995
71013
|
const { cut, paste } = this.getInsertCellsTargets(cmd.zone, cmd.shiftDimension);
|
|
70996
|
-
const copiedData = this.copy(cut);
|
|
71014
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70997
71015
|
this.paste(paste, copiedData, { isCutOperation: true });
|
|
70998
71016
|
break;
|
|
70999
71017
|
}
|
|
@@ -71108,11 +71126,11 @@ class ClipboardPlugin extends UIPlugin {
|
|
|
71108
71126
|
}
|
|
71109
71127
|
return false;
|
|
71110
71128
|
}
|
|
71111
|
-
copy(zones) {
|
|
71129
|
+
copy(zones, mode = "copyPaste") {
|
|
71112
71130
|
let copiedData = {};
|
|
71113
71131
|
const clipboardData = this.getClipboardData(zones);
|
|
71114
71132
|
for (const { handlerName, handler } of this.selectClipboardHandlers(clipboardData)) {
|
|
71115
|
-
const data = handler.copy(clipboardData, this._isCutOperation);
|
|
71133
|
+
const data = handler.copy(clipboardData, this._isCutOperation, mode);
|
|
71116
71134
|
copiedData[handlerName] = data;
|
|
71117
71135
|
const minimalKeys = ["sheetId", "cells", "zones", "figureId"];
|
|
71118
71136
|
for (const key of minimalKeys) {
|
|
@@ -72063,7 +72081,7 @@ class GridSelectionPlugin extends UIPlugin {
|
|
|
72063
72081
|
];
|
|
72064
72082
|
for (const Handler of clipboardHandlersRegistries.cellHandlers.getAll()) {
|
|
72065
72083
|
const handler = new Handler(this.getters, this.dispatch);
|
|
72066
|
-
const data = handler.copy(getClipboardDataPositions(sheetId, target));
|
|
72084
|
+
const data = handler.copy(getClipboardDataPositions(sheetId, target), false, "shiftCells");
|
|
72067
72085
|
if (!data) {
|
|
72068
72086
|
continue;
|
|
72069
72087
|
}
|
|
@@ -80254,7 +80272,7 @@ class Model extends EventBus {
|
|
|
80254
80272
|
handlers = [];
|
|
80255
80273
|
uiHandlers = [];
|
|
80256
80274
|
coreHandlers = [];
|
|
80257
|
-
constructor(data = {}, config = {}, stateUpdateMessages = [], uuidGenerator = new UuidGenerator(), verboseImport =
|
|
80275
|
+
constructor(data = {}, config = {}, stateUpdateMessages = [], uuidGenerator = new UuidGenerator(), verboseImport = false) {
|
|
80258
80276
|
const start = performance.now();
|
|
80259
80277
|
console.debug("##### Model creation #####");
|
|
80260
80278
|
super();
|
|
@@ -80997,6 +81015,6 @@ exports.tokenColors = tokenColors;
|
|
|
80997
81015
|
exports.tokenize = tokenize;
|
|
80998
81016
|
|
|
80999
81017
|
|
|
81000
|
-
__info__.version = "18.3.
|
|
81001
|
-
__info__.date = "2025-09-
|
|
81002
|
-
__info__.hash = "
|
|
81018
|
+
__info__.version = "18.3.20";
|
|
81019
|
+
__info__.date = "2025-09-11T08:45:37.934Z";
|
|
81020
|
+
__info__.hash = "ef829f4";
|
package/dist/o-spreadsheet.d.ts
CHANGED
|
@@ -2603,6 +2603,7 @@ interface ClipboardOptions {
|
|
|
2603
2603
|
selectTarget?: boolean;
|
|
2604
2604
|
}
|
|
2605
2605
|
type ClipboardPasteOptions = "onlyFormat" | "asValue";
|
|
2606
|
+
type ClipboardCopyOptions = "copyPaste" | "shiftCells";
|
|
2606
2607
|
type ClipboardOperation = "CUT" | "COPY";
|
|
2607
2608
|
type ClipboardCellData = {
|
|
2608
2609
|
sheetId: UID;
|
|
@@ -6622,7 +6623,7 @@ declare class ClipboardHandler<T> {
|
|
|
6622
6623
|
protected getters: Getters;
|
|
6623
6624
|
protected dispatch: CommandDispatcher["dispatch"];
|
|
6624
6625
|
constructor(getters: Getters, dispatch: CommandDispatcher["dispatch"]);
|
|
6625
|
-
copy(data: ClipboardData, isCutOperation: boolean): T | undefined;
|
|
6626
|
+
copy(data: ClipboardData, isCutOperation: boolean, mode?: ClipboardCopyOptions): T | undefined;
|
|
6626
6627
|
paste(target: ClipboardPasteTarget, clippedContent: T, options: ClipboardOptions): void;
|
|
6627
6628
|
isPasteAllowed(sheetId: UID, target: Zone[], content: T, option: ClipboardOptions): CommandResult;
|
|
6628
6629
|
isCutAllowed(data: ClipboardData): CommandResult;
|
|
@@ -6631,7 +6632,7 @@ declare class ClipboardHandler<T> {
|
|
|
6631
6632
|
}
|
|
6632
6633
|
|
|
6633
6634
|
declare class AbstractCellClipboardHandler<T, T1> extends ClipboardHandler<T> {
|
|
6634
|
-
copy(data: ClipboardCellData): T | undefined;
|
|
6635
|
+
copy(data: ClipboardCellData, isCutOperation: boolean, mode?: ClipboardCopyOptions): T | undefined;
|
|
6635
6636
|
pasteFromCopy(sheetId: UID, target: Zone[], content: T1[][], options?: ClipboardOptions): void;
|
|
6636
6637
|
protected pasteZone(sheetId: UID, col: HeaderIndex, row: HeaderIndex, data: T1[][], clipboardOptions?: ClipboardOptions): void;
|
|
6637
6638
|
}
|
|
@@ -12607,4 +12608,4 @@ declare const chartHelpers: {
|
|
|
12607
12608
|
WaterfallChart: typeof WaterfallChart;
|
|
12608
12609
|
};
|
|
12609
12610
|
|
|
12610
|
-
export { AST, ASTFuncall, AboveAverageRule, AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, ActivateNextSheetCommand, ActivatePreviousSheetCommand, ActivateSheetCommand, AdaptSheetName, AddColumnsRowsCommand, AddConditionalFormatCommand, AddDataValidationCommand, AddFunctionDescription, AddMergeCommand, AddPivotCommand, Aggregator, Alias, Align, AlphanumericIncrementModifier, AnchorOffset, AnchorZone, ApplyRangeChange, ApplyRangeChangeResult, Arg, ArgDefinition, ArgType, AutoFillCellCommand, AutofillAutoCommand, AutofillCellData, AutofillCommand, AutofillData, AutofillModifier, AutofillModifierImplementation, AutofillResult, AutofillSelectCommand, AutofillTableCommand, AutoresizeColumnsCommand, AutoresizeRowsCommand, AxesDesign, AxisDesign, AxisType, BeginsWithRule, BooleanCell, Border$1 as Border, BorderData, BorderDescr, BorderPosition, BorderStyle, Box, BoxTextContent, CHART_TYPES, CSSProperties, CancelledReason, Cell, CellErrorType, CellIsRule, CellPosition, CellValue, CellValueType, ChangeType, ChartAxisFormats, ChartCreationContext, ChartDefinition, ChartJSRuntime, ChartRuntime, ChartRuntimeGenerationArgs, ChartStyle, ChartType, ChartWithAxisDefinition, ChartWithDataSetDefinition, CleanClipBoardHighlightCommand, ClearCellCommand, ClearCellsCommand, ClearFormattingCommand, Client, ClientId, ClientJoinedMessage, ClientLeftMessage, ClientMovedMessage, ClientPosition, ClipboardCell, ClipboardCellData, ClipboardData, ClipboardFigureData, ClipboardMIMEType, ClipboardOperation, ClipboardOptions, ClipboardPasteOptions, ClipboardPasteTarget, Cloneable, CollaborationMessage, CollaborativeEvent, CollaborativeEventReceived, CollaborativeEventTypes, Color, ColorScaleMidPointThreshold, ColorScaleRule, ColorScaleThreshold, ColorSheetCommand, Command, CommandDispatcher, CommandHandler, CommandResult, CommandTypes, CommonPivotCoreDefinition, CompiledFormula, ComposerFocusType, ComputeFunction, ComputedTableStyle, ConditionalFormat, ConditionalFormatInternal, ConditionalFormatRule, ConditionalFormatRuleInternal, ConditionalFormattingOperatorValues, ConsecutiveIndexes, ContainsTextRule, CopyCommand, CopyModifier, CopyPasteCellsAboveCommand, CopyPasteCellsOnLeftCommand, CoreCommand, CoreCommandDispatcher, CoreCommandTypes, CoreGetters, CorePlugin, CoreTable, CoreTableType, CoreViewCommand, CoreViewCommandTypes, CoreViewPlugin, CreateChartCommand, CreateFigureCommand, CreateImageOverCommand, CreateRevisionOptions, CreateSheetCommand, CreateTableCommand, CreateTableStyleCommand, Currency, CustomFormulaCriterion, CustomizedDataSet, CutCommand, DEFAULT_LOCALE, DEFAULT_LOCALES, DIRECTION, DOMCoordinates, DOMDimension, DataBarFill, DataBarRule, DataBarRuleInternal, DataSet, DataValidationCriterion, DataValidationCriterionType, DataValidationDateCriterion, DataValidationRule, DataValidationRuleData, DatasetDesign, DatasetValues, DateCriterionValue, DateIncrementModifier, DateIsAfterCriterion, DateIsBeforeCriterion, DateIsBetweenCriterion, DateIsCriterion, DateIsNotBetweenCriterion, DateIsOnOrAfterCriterion, DateIsOnOrBeforeCriterion, DateIsValidCriterion, DebouncedFunction, DeleteCellCommand, DeleteContentCommand, DeleteFigureCommand, DeleteSheetCommand, DeleteUnfilteredContentCommand, Dependencies, Dimension, DimensionTree, DimensionTreeNode, Direction$1 as Direction, DispatchResult, DuplicatePivotCommand, DuplicatePivotInNewSheetCommand, DuplicateSheetCommand, DynamicTable, EdgeScrollInfo, EditTextOptions, EditionMode, EmptyCell, EndsWithRule, EnrichedToken, EnsureRange, ErrorCell, EvalContext, EvaluateCellsCommand, EvaluateChartsCommand, EvaluatedCell, EvaluationError, ExcelChartDataset, ExcelChartDefinition, ExcelChartType, ExcelFigureSize, ExcelFilterData, ExcelHeaderData, ExcelSheetData, ExcelTableData, ExcelWorkbookData, ExpressionRule, Figure, FigureData, FigureInfo, FigureSize, FigureUI, Filter, FilterId, FoldAllHeaderGroupsCommand, FoldHeaderGroupCommand, FoldHeaderGroupsInZoneCommand, Format, FormattedValue, FormulaCell, FormulaModifier, FormulaToExecute, FreezeColumnsCommand, FreezeRowsCommand, FunctionDescription, FunctionRegistry, FunctionResultNumber, FunctionResultObject, GeneratorCell, GenericDefinition, GetSymbolValue, Getters, Granularity, GridClickModifiers, GridRenderingContext, GroupHeadersCommand, HSLA, HeaderData, HeaderDimensions, HeaderGroup, HeaderIndex, HeadersDependentCommand, HideColumnsRowsCommand, HideSheetCommand, Highlight$1 as Highlight, HistoryChange, IconSet, IconSetRule, IconThreshold, Image, Immutable, Increment, IncrementModifier, InformationNotification, InitPivotParams, InsertCellCommand, InsertNewPivotCommand, InsertPivotCommand, InsertPivotWithTableCommand, IsBetweenCriterion, IsCheckboxCriterion, IsEqualCriterion, IsGreaterOrEqualToCriterion, IsGreaterThanCriterion, IsLessOrEqualToCriterion, IsLessThanCriterion, IsNotBetweenCriterion, IsNotEqualCriterion, IsValueInListCriterion, IsValueInRangeCriterion, LabelValues, LayerName, Lazy, Link, LiteralCell, LocalCommand, Locale, LocaleCode, LocaleFormat, LookupCaches, Matrix, Maybe, MenuMouseEvent, Merge, MinimalClipboardData, Model, MoveColumnsRowsCommand, MoveConditionalFormatCommand, MoveRangeCommand, MoveSheetCommand, MoveViewportDownCommand, MoveViewportToCellCommand, MoveViewportUpCommand, NewLocalStateUpdateEvent, NotContainsTextRule, NotificationType, NumberCell, OSClipboardContent, Offset, OperationSequenceNode, OrderedLayers, PaintFormat, PaneDivision, ParsedOSClipboardContent, ParsedOsClipboardContentWithImageData, PasteCommand, PasteFromOSClipboardCommand, Pivot, PivotColRowDomain, PivotCoreDefinition, PivotCoreDimension, PivotCoreMeasure, PivotDimension$1 as PivotDimension, PivotDomain, PivotEmptyCell, PivotField, PivotFields, PivotHeaderCell, PivotMeasure, PivotMeasureDisplay, PivotMeasureDisplayType, PivotMeasureHeaderCell, PivotNode, PivotRuntimeDefinition, PivotSortedColumn, PivotStartPresenceTracking, PivotStopPresenceTracking, PivotTableCell, PivotTableColumn, PivotTableData, PivotTableRow, PivotTimeAdapter, PivotTimeAdapterNotNull, PivotValueCell, Pixel, PixelPosition, Position$1 as Position, PositionDependentCommand, PropsOf, RGBA, Range, RangeAdapter$1 as RangeAdapter, RangeCompiledFormula, RangeData, RangePart, RangeProvider, RangeStringOptions, RangesDependentCommand, Rect, RedoCommand, Ref, ReferenceDenormalizer, RefreshPivotCommand, Registry, RemoteRevisionMessage, RemoteRevisionReceivedEvent, RemoveColumnsRowsCommand, RemoveConditionalFormatCommand, RemoveDataValidationCommand, RemoveDuplicatesCommand, RemoveMergeCommand, RemovePivotCommand, RemoveTableCommand, RemoveTableStyleCommand, RenamePivotCommand, RenameSheetCommand, RepeatPasteCommand, ReplaceSearchCommand, RequestRedoCommand, RequestUndoCommand, ResizeColumnsRowsCommand, ResizeDirection, ResizeTableCommand, ResizeViewportCommand, Revision, RevisionAcknowledgedEvent, RevisionData, RevisionRedone, RevisionRedoneMessage, RevisionUndone, RevisionUndoneMessage, Row, SPREADSHEET_DIMENSIONS, ScrollDirection$1 as ScrollDirection, SelectFigureCommand, Selection, SelectionStep, SetBorderCommand, SetBorderTargetCommand, SetContextualFormatCommand, SetDecimalCommand, SetDecimalStep, SetFormattingCommand, SetGridLinesVisibilityCommand, SetViewportOffsetCommand, SetZoneBordersCommand, Sheet, SheetDOMScrollInfo, SheetData, SheetDependentCommand, SheetEditingCommand, ShowFormulaCommand, ShowSheetCommand, SingleColorRule, SingleColorRules, SnapshotEvent, SortCommand, SortDirection, SortOptions, SplitPivotFormulaCommand, SplitTextIntoColumnsCommand, Spreadsheet, SpreadsheetChildEnv, SpreadsheetPivotCoreDefinition, SpreadsheetPivotTable, StartChangeHighlightCommand, StartCommand, StaticTable, StoreConstructor, StoreParams, Style, SumSelectionCommand, Table, TableBorder, TableConfig, TableData$1 as TableData, TableElementStyle, TableId, TableStyle, TableStyleData, TableStyleTemplateName, TargetDependentCommand, TechnicalName, TextCell, TextContainsCriterion, TextIsCriterion, TextIsEmailCriterion, TextIsLinkCriterion, TextNotContainsCriterion, TextRule, ThresholdType, TimePeriodRule, TitleDesign, Token, Tooltip, Top10Rule, Transformation, TransformationFactory, TransportService, TrendConfiguration, TrendType, TrimWhitespaceCommand, UID, UIPlugin, UnGroupHeadersCommand, UnboundedZone, UndoCommand, UnexpectedRevisionIdEvent, UnfoldAllHeaderGroupsCommand, UnfoldHeaderGroupCommand, UnfoldHeaderGroupsInZoneCommand, UnfreezeColumnsCommand, UnfreezeColumnsRowsCommand, UnfreezeRowsCommand, UnhideColumnsRowsCommand, UpdateCellCommand, UpdateCellData, UpdateCellPositionCommand, UpdateChartCommand, UpdateFigureCommand, UpdateFilterCommand, UpdateLocaleCommand, UpdatePivotCommand, UpdateTableCommand, Validation, VerticalAlign, Viewport, WorkbookData, WorkbookHistory, Wrapping, Zone, ZoneDependentCommand, ZoneDimension, __info__, addFunction, addRenderingLayer, astToFormula, borderStyles, canExecuteInReadonly, chartHelpers, compile, compileTokens, components, constants, containsBlanksRule, containsErrorsRule, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, hooks, invalidateBordersCommands, invalidateCFEvaluationCommands, invalidateChartEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, isCoreCommand, isHeadersDependant, isMatrix, isPositionDependent, isRangeDependant, isSheetDependent, isTargetDependent, isZoneDependent, iterateAstNodes, links, load, notContainsBlanksRule, notContainsErrorsRule, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
|
|
12611
|
+
export { AST, ASTFuncall, AboveAverageRule, AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, ActivateNextSheetCommand, ActivatePreviousSheetCommand, ActivateSheetCommand, AdaptSheetName, AddColumnsRowsCommand, AddConditionalFormatCommand, AddDataValidationCommand, AddFunctionDescription, AddMergeCommand, AddPivotCommand, Aggregator, Alias, Align, AlphanumericIncrementModifier, AnchorOffset, AnchorZone, ApplyRangeChange, ApplyRangeChangeResult, Arg, ArgDefinition, ArgType, AutoFillCellCommand, AutofillAutoCommand, AutofillCellData, AutofillCommand, AutofillData, AutofillModifier, AutofillModifierImplementation, AutofillResult, AutofillSelectCommand, AutofillTableCommand, AutoresizeColumnsCommand, AutoresizeRowsCommand, AxesDesign, AxisDesign, AxisType, BeginsWithRule, BooleanCell, Border$1 as Border, BorderData, BorderDescr, BorderPosition, BorderStyle, Box, BoxTextContent, CHART_TYPES, CSSProperties, CancelledReason, Cell, CellErrorType, CellIsRule, CellPosition, CellValue, CellValueType, ChangeType, ChartAxisFormats, ChartCreationContext, ChartDefinition, ChartJSRuntime, ChartRuntime, ChartRuntimeGenerationArgs, ChartStyle, ChartType, ChartWithAxisDefinition, ChartWithDataSetDefinition, CleanClipBoardHighlightCommand, ClearCellCommand, ClearCellsCommand, ClearFormattingCommand, Client, ClientId, ClientJoinedMessage, ClientLeftMessage, ClientMovedMessage, ClientPosition, ClipboardCell, ClipboardCellData, ClipboardCopyOptions, ClipboardData, ClipboardFigureData, ClipboardMIMEType, ClipboardOperation, ClipboardOptions, ClipboardPasteOptions, ClipboardPasteTarget, Cloneable, CollaborationMessage, CollaborativeEvent, CollaborativeEventReceived, CollaborativeEventTypes, Color, ColorScaleMidPointThreshold, ColorScaleRule, ColorScaleThreshold, ColorSheetCommand, Command, CommandDispatcher, CommandHandler, CommandResult, CommandTypes, CommonPivotCoreDefinition, CompiledFormula, ComposerFocusType, ComputeFunction, ComputedTableStyle, ConditionalFormat, ConditionalFormatInternal, ConditionalFormatRule, ConditionalFormatRuleInternal, ConditionalFormattingOperatorValues, ConsecutiveIndexes, ContainsTextRule, CopyCommand, CopyModifier, CopyPasteCellsAboveCommand, CopyPasteCellsOnLeftCommand, CoreCommand, CoreCommandDispatcher, CoreCommandTypes, CoreGetters, CorePlugin, CoreTable, CoreTableType, CoreViewCommand, CoreViewCommandTypes, CoreViewPlugin, CreateChartCommand, CreateFigureCommand, CreateImageOverCommand, CreateRevisionOptions, CreateSheetCommand, CreateTableCommand, CreateTableStyleCommand, Currency, CustomFormulaCriterion, CustomizedDataSet, CutCommand, DEFAULT_LOCALE, DEFAULT_LOCALES, DIRECTION, DOMCoordinates, DOMDimension, DataBarFill, DataBarRule, DataBarRuleInternal, DataSet, DataValidationCriterion, DataValidationCriterionType, DataValidationDateCriterion, DataValidationRule, DataValidationRuleData, DatasetDesign, DatasetValues, DateCriterionValue, DateIncrementModifier, DateIsAfterCriterion, DateIsBeforeCriterion, DateIsBetweenCriterion, DateIsCriterion, DateIsNotBetweenCriterion, DateIsOnOrAfterCriterion, DateIsOnOrBeforeCriterion, DateIsValidCriterion, DebouncedFunction, DeleteCellCommand, DeleteContentCommand, DeleteFigureCommand, DeleteSheetCommand, DeleteUnfilteredContentCommand, Dependencies, Dimension, DimensionTree, DimensionTreeNode, Direction$1 as Direction, DispatchResult, DuplicatePivotCommand, DuplicatePivotInNewSheetCommand, DuplicateSheetCommand, DynamicTable, EdgeScrollInfo, EditTextOptions, EditionMode, EmptyCell, EndsWithRule, EnrichedToken, EnsureRange, ErrorCell, EvalContext, EvaluateCellsCommand, EvaluateChartsCommand, EvaluatedCell, EvaluationError, ExcelChartDataset, ExcelChartDefinition, ExcelChartType, ExcelFigureSize, ExcelFilterData, ExcelHeaderData, ExcelSheetData, ExcelTableData, ExcelWorkbookData, ExpressionRule, Figure, FigureData, FigureInfo, FigureSize, FigureUI, Filter, FilterId, FoldAllHeaderGroupsCommand, FoldHeaderGroupCommand, FoldHeaderGroupsInZoneCommand, Format, FormattedValue, FormulaCell, FormulaModifier, FormulaToExecute, FreezeColumnsCommand, FreezeRowsCommand, FunctionDescription, FunctionRegistry, FunctionResultNumber, FunctionResultObject, GeneratorCell, GenericDefinition, GetSymbolValue, Getters, Granularity, GridClickModifiers, GridRenderingContext, GroupHeadersCommand, HSLA, HeaderData, HeaderDimensions, HeaderGroup, HeaderIndex, HeadersDependentCommand, HideColumnsRowsCommand, HideSheetCommand, Highlight$1 as Highlight, HistoryChange, IconSet, IconSetRule, IconThreshold, Image, Immutable, Increment, IncrementModifier, InformationNotification, InitPivotParams, InsertCellCommand, InsertNewPivotCommand, InsertPivotCommand, InsertPivotWithTableCommand, IsBetweenCriterion, IsCheckboxCriterion, IsEqualCriterion, IsGreaterOrEqualToCriterion, IsGreaterThanCriterion, IsLessOrEqualToCriterion, IsLessThanCriterion, IsNotBetweenCriterion, IsNotEqualCriterion, IsValueInListCriterion, IsValueInRangeCriterion, LabelValues, LayerName, Lazy, Link, LiteralCell, LocalCommand, Locale, LocaleCode, LocaleFormat, LookupCaches, Matrix, Maybe, MenuMouseEvent, Merge, MinimalClipboardData, Model, MoveColumnsRowsCommand, MoveConditionalFormatCommand, MoveRangeCommand, MoveSheetCommand, MoveViewportDownCommand, MoveViewportToCellCommand, MoveViewportUpCommand, NewLocalStateUpdateEvent, NotContainsTextRule, NotificationType, NumberCell, OSClipboardContent, Offset, OperationSequenceNode, OrderedLayers, PaintFormat, PaneDivision, ParsedOSClipboardContent, ParsedOsClipboardContentWithImageData, PasteCommand, PasteFromOSClipboardCommand, Pivot, PivotColRowDomain, PivotCoreDefinition, PivotCoreDimension, PivotCoreMeasure, PivotDimension$1 as PivotDimension, PivotDomain, PivotEmptyCell, PivotField, PivotFields, PivotHeaderCell, PivotMeasure, PivotMeasureDisplay, PivotMeasureDisplayType, PivotMeasureHeaderCell, PivotNode, PivotRuntimeDefinition, PivotSortedColumn, PivotStartPresenceTracking, PivotStopPresenceTracking, PivotTableCell, PivotTableColumn, PivotTableData, PivotTableRow, PivotTimeAdapter, PivotTimeAdapterNotNull, PivotValueCell, Pixel, PixelPosition, Position$1 as Position, PositionDependentCommand, PropsOf, RGBA, Range, RangeAdapter$1 as RangeAdapter, RangeCompiledFormula, RangeData, RangePart, RangeProvider, RangeStringOptions, RangesDependentCommand, Rect, RedoCommand, Ref, ReferenceDenormalizer, RefreshPivotCommand, Registry, RemoteRevisionMessage, RemoteRevisionReceivedEvent, RemoveColumnsRowsCommand, RemoveConditionalFormatCommand, RemoveDataValidationCommand, RemoveDuplicatesCommand, RemoveMergeCommand, RemovePivotCommand, RemoveTableCommand, RemoveTableStyleCommand, RenamePivotCommand, RenameSheetCommand, RepeatPasteCommand, ReplaceSearchCommand, RequestRedoCommand, RequestUndoCommand, ResizeColumnsRowsCommand, ResizeDirection, ResizeTableCommand, ResizeViewportCommand, Revision, RevisionAcknowledgedEvent, RevisionData, RevisionRedone, RevisionRedoneMessage, RevisionUndone, RevisionUndoneMessage, Row, SPREADSHEET_DIMENSIONS, ScrollDirection$1 as ScrollDirection, SelectFigureCommand, Selection, SelectionStep, SetBorderCommand, SetBorderTargetCommand, SetContextualFormatCommand, SetDecimalCommand, SetDecimalStep, SetFormattingCommand, SetGridLinesVisibilityCommand, SetViewportOffsetCommand, SetZoneBordersCommand, Sheet, SheetDOMScrollInfo, SheetData, SheetDependentCommand, SheetEditingCommand, ShowFormulaCommand, ShowSheetCommand, SingleColorRule, SingleColorRules, SnapshotEvent, SortCommand, SortDirection, SortOptions, SplitPivotFormulaCommand, SplitTextIntoColumnsCommand, Spreadsheet, SpreadsheetChildEnv, SpreadsheetPivotCoreDefinition, SpreadsheetPivotTable, StartChangeHighlightCommand, StartCommand, StaticTable, StoreConstructor, StoreParams, Style, SumSelectionCommand, Table, TableBorder, TableConfig, TableData$1 as TableData, TableElementStyle, TableId, TableStyle, TableStyleData, TableStyleTemplateName, TargetDependentCommand, TechnicalName, TextCell, TextContainsCriterion, TextIsCriterion, TextIsEmailCriterion, TextIsLinkCriterion, TextNotContainsCriterion, TextRule, ThresholdType, TimePeriodRule, TitleDesign, Token, Tooltip, Top10Rule, Transformation, TransformationFactory, TransportService, TrendConfiguration, TrendType, TrimWhitespaceCommand, UID, UIPlugin, UnGroupHeadersCommand, UnboundedZone, UndoCommand, UnexpectedRevisionIdEvent, UnfoldAllHeaderGroupsCommand, UnfoldHeaderGroupCommand, UnfoldHeaderGroupsInZoneCommand, UnfreezeColumnsCommand, UnfreezeColumnsRowsCommand, UnfreezeRowsCommand, UnhideColumnsRowsCommand, UpdateCellCommand, UpdateCellData, UpdateCellPositionCommand, UpdateChartCommand, UpdateFigureCommand, UpdateFilterCommand, UpdateLocaleCommand, UpdatePivotCommand, UpdateTableCommand, Validation, VerticalAlign, Viewport, WorkbookData, WorkbookHistory, Wrapping, Zone, ZoneDependentCommand, ZoneDimension, __info__, addFunction, addRenderingLayer, astToFormula, borderStyles, canExecuteInReadonly, chartHelpers, compile, compileTokens, components, constants, containsBlanksRule, containsErrorsRule, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, hooks, invalidateBordersCommands, invalidateCFEvaluationCommands, invalidateChartEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, isCoreCommand, isHeadersDependant, isMatrix, isPositionDependent, isRangeDependant, isSheetDependent, isTargetDependent, isZoneDependent, iterateAstNodes, links, load, notContainsBlanksRule, notContainsErrorsRule, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
|
|
@@ -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.3.
|
|
6
|
-
* @date 2025-09-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 18.3.20
|
|
6
|
+
* @date 2025-09-11T08:45:37.934Z
|
|
7
|
+
* @hash ef829f4
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
import { useEnv, useSubEnv, onWillUnmount, useComponent, status, Component, useRef, onMounted, useEffect, App, blockDom, useState, onPatched, onWillPatch, onWillUpdateProps, useExternalListener, onWillStart, xml, useChildSubEnv, markRaw, toRaw } from '@odoo/owl';
|
|
@@ -7207,7 +7207,7 @@ class ClipboardHandler {
|
|
|
7207
7207
|
this.getters = getters;
|
|
7208
7208
|
this.dispatch = dispatch;
|
|
7209
7209
|
}
|
|
7210
|
-
copy(data, isCutOperation) {
|
|
7210
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
7211
7211
|
return;
|
|
7212
7212
|
}
|
|
7213
7213
|
paste(target, clippedContent, options) { }
|
|
@@ -7226,7 +7226,7 @@ class ClipboardHandler {
|
|
|
7226
7226
|
}
|
|
7227
7227
|
|
|
7228
7228
|
class AbstractCellClipboardHandler extends ClipboardHandler {
|
|
7229
|
-
copy(data) {
|
|
7229
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
7230
7230
|
return;
|
|
7231
7231
|
}
|
|
7232
7232
|
pasteFromCopy(sheetId, target, content, options) {
|
|
@@ -8949,7 +8949,7 @@ class CellClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
8949
8949
|
}
|
|
8950
8950
|
return "Success" /* CommandResult.Success */;
|
|
8951
8951
|
}
|
|
8952
|
-
copy(data) {
|
|
8952
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
8953
8953
|
const sheetId = data.sheetId;
|
|
8954
8954
|
const { clippedZones, rowsIndexes, columnsIndexes } = data;
|
|
8955
8955
|
const clippedCells = [];
|
|
@@ -8962,7 +8962,7 @@ class CellClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
8962
8962
|
const evaluatedCell = this.getters.getEvaluatedCell(position);
|
|
8963
8963
|
const pivotId = this.getters.getPivotIdFromPosition(position);
|
|
8964
8964
|
const spreader = this.getters.getArrayFormulaSpreadingOn(position);
|
|
8965
|
-
if (pivotId && spreader) {
|
|
8965
|
+
if (mode !== "shiftCells" && pivotId && spreader) {
|
|
8966
8966
|
const pivotZone = this.getters.getSpreadZone(spreader);
|
|
8967
8967
|
if ((!deepEquals(spreader, position) || !isCopyingOneCell) &&
|
|
8968
8968
|
pivotZone &&
|
|
@@ -8980,7 +8980,7 @@ class CellClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
8980
8980
|
};
|
|
8981
8981
|
}
|
|
8982
8982
|
}
|
|
8983
|
-
else {
|
|
8983
|
+
else if (mode !== "shiftCells") {
|
|
8984
8984
|
if (spreader && !deepEquals(spreader, position)) {
|
|
8985
8985
|
const isSpreaderCopied = rowsIndexes.includes(spreader.row) && columnsIndexes.includes(spreader.col);
|
|
8986
8986
|
const content = isSpreaderCopied
|
|
@@ -9680,7 +9680,7 @@ class SheetClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
9680
9680
|
}
|
|
9681
9681
|
|
|
9682
9682
|
class TableClipboardHandler extends AbstractCellClipboardHandler {
|
|
9683
|
-
copy(data, isCutOperation) {
|
|
9683
|
+
copy(data, isCutOperation, mode = "copyPaste") {
|
|
9684
9684
|
const sheetId = data.sheetId;
|
|
9685
9685
|
const { rowsIndexes, columnsIndexes, zones } = data;
|
|
9686
9686
|
const copiedTablesIds = new Set();
|
|
@@ -9718,11 +9718,13 @@ class TableClipboardHandler extends AbstractCellClipboardHandler {
|
|
|
9718
9718
|
type: coreTable.type,
|
|
9719
9719
|
};
|
|
9720
9720
|
}
|
|
9721
|
-
|
|
9722
|
-
|
|
9723
|
-
|
|
9724
|
-
|
|
9725
|
-
|
|
9721
|
+
if (mode !== "shiftCells") {
|
|
9722
|
+
tableCellsInRow.push({
|
|
9723
|
+
table: copiedTable,
|
|
9724
|
+
style: this.getTableStyleToCopy(position),
|
|
9725
|
+
isWholeTableCopied: copiedTablesIds.has(table.id),
|
|
9726
|
+
});
|
|
9727
|
+
}
|
|
9726
9728
|
}
|
|
9727
9729
|
}
|
|
9728
9730
|
return {
|
|
@@ -30884,7 +30886,7 @@ const SUPPORTED_HORIZONTAL_ALIGNMENTS = [
|
|
|
30884
30886
|
];
|
|
30885
30887
|
const SUPPORTED_VERTICAL_ALIGNMENTS = ["top", "center", "bottom"];
|
|
30886
30888
|
const SUPPORTED_FONTS = ["Arial"];
|
|
30887
|
-
const SUPPORTED_FILL_PATTERNS = ["solid"];
|
|
30889
|
+
const SUPPORTED_FILL_PATTERNS = ["solid", "none"];
|
|
30888
30890
|
const SUPPORTED_CF_TYPES = [
|
|
30889
30891
|
"expression",
|
|
30890
30892
|
"cellIs",
|
|
@@ -31069,7 +31071,7 @@ const SUBTOTAL_FUNCTION_CONVERSION_MAP = {
|
|
|
31069
31071
|
};
|
|
31070
31072
|
/** Mapping between Excel format indexes (see XLSX_FORMAT_MAP) and some supported formats */
|
|
31071
31073
|
const XLSX_FORMATS_CONVERSION_MAP = {
|
|
31072
|
-
0: "",
|
|
31074
|
+
0: "General",
|
|
31073
31075
|
1: "0",
|
|
31074
31076
|
2: "0.00",
|
|
31075
31077
|
3: "#,#00",
|
|
@@ -31395,11 +31397,11 @@ const XLSX_DATE_FORMAT_REGEX = /^(yy|yyyy|m{1,5}|d{1,4}|h{1,2}|s{1,2}|am\/pm|a\/
|
|
|
31395
31397
|
* Excel format are defined in openXML §18.8.31
|
|
31396
31398
|
*/
|
|
31397
31399
|
function convertXlsxFormat(numFmtId, formats, warningManager) {
|
|
31398
|
-
if (numFmtId === 0) {
|
|
31399
|
-
return undefined;
|
|
31400
|
-
}
|
|
31401
31400
|
// Format is either defined in the imported data, or the formatId is defined in openXML §18.8.30
|
|
31402
31401
|
let format = XLSX_FORMATS_CONVERSION_MAP[numFmtId] || formats.find((f) => f.id === numFmtId)?.format;
|
|
31402
|
+
if (format === "General") {
|
|
31403
|
+
return undefined;
|
|
31404
|
+
}
|
|
31403
31405
|
if (format) {
|
|
31404
31406
|
try {
|
|
31405
31407
|
let convertedFormat = format.replace(/\[(.*)-[A-Z0-9]{3}\]/g, "[$1]"); // remove currency and locale/date system/number system info (ECMA §18.8.31)
|
|
@@ -34244,10 +34246,11 @@ class XlsxSheetExtractor extends XlsxBaseExtractor {
|
|
|
34244
34246
|
});
|
|
34245
34247
|
}
|
|
34246
34248
|
extractRows(worksheet) {
|
|
34249
|
+
const spilledCells = new Set();
|
|
34247
34250
|
return this.mapOnElements({ parent: worksheet, query: "sheetData row" }, (rowElement) => {
|
|
34248
34251
|
return {
|
|
34249
34252
|
index: this.extractAttr(rowElement, "r", { required: true })?.asNum(),
|
|
34250
|
-
cells: this.extractCells(rowElement),
|
|
34253
|
+
cells: this.extractCells(rowElement, spilledCells),
|
|
34251
34254
|
height: this.extractAttr(rowElement, "ht")?.asNum(),
|
|
34252
34255
|
customHeight: this.extractAttr(rowElement, "customHeight")?.asBool(),
|
|
34253
34256
|
hidden: this.extractAttr(rowElement, "hidden")?.asBool(),
|
|
@@ -34257,14 +34260,26 @@ class XlsxSheetExtractor extends XlsxBaseExtractor {
|
|
|
34257
34260
|
};
|
|
34258
34261
|
});
|
|
34259
34262
|
}
|
|
34260
|
-
extractCells(row) {
|
|
34263
|
+
extractCells(row, spilledCells) {
|
|
34261
34264
|
return this.mapOnElements({ parent: row, query: "c" }, (cellElement) => {
|
|
34265
|
+
const xc = this.extractAttr(cellElement, "r", { required: true })?.asString();
|
|
34266
|
+
const formula = this.extractCellFormula(cellElement);
|
|
34267
|
+
if (formula?.ref && formula.sharedIndex === undefined) {
|
|
34268
|
+
const zone = toZone(formula.ref);
|
|
34269
|
+
for (const { col, row } of positions(zone)) {
|
|
34270
|
+
const followerXc = toXC(col, row);
|
|
34271
|
+
if (followerXc !== xc) {
|
|
34272
|
+
spilledCells.add(followerXc);
|
|
34273
|
+
}
|
|
34274
|
+
}
|
|
34275
|
+
}
|
|
34276
|
+
const isSpilled = spilledCells.has(xc);
|
|
34262
34277
|
return {
|
|
34263
|
-
xc
|
|
34278
|
+
xc,
|
|
34264
34279
|
styleIndex: this.extractAttr(cellElement, "s")?.asNum(),
|
|
34265
34280
|
type: CELL_TYPE_CONVERSION_MAP[this.extractAttr(cellElement, "t", { default: "n" })?.asString()],
|
|
34266
|
-
value: this.extractChildTextContent(cellElement, "v"),
|
|
34267
|
-
formula:
|
|
34281
|
+
value: isSpilled ? undefined : this.extractChildTextContent(cellElement, "v") ?? undefined,
|
|
34282
|
+
formula: isSpilled ? undefined : formula,
|
|
34268
34283
|
};
|
|
34269
34284
|
});
|
|
34270
34285
|
}
|
|
@@ -34272,11 +34287,14 @@ class XlsxSheetExtractor extends XlsxBaseExtractor {
|
|
|
34272
34287
|
const formulaElement = this.querySelector(cellElement, "f");
|
|
34273
34288
|
if (!formulaElement)
|
|
34274
34289
|
return undefined;
|
|
34275
|
-
|
|
34276
|
-
|
|
34277
|
-
|
|
34278
|
-
|
|
34279
|
-
|
|
34290
|
+
const content = this.extractTextContent(formulaElement);
|
|
34291
|
+
const sharedIndex = this.extractAttr(formulaElement, "si")?.asNum();
|
|
34292
|
+
const ref = this.extractAttr(formulaElement, "ref")?.asString();
|
|
34293
|
+
// This is the case of spilled cells of array formulas where <f> is empty
|
|
34294
|
+
if ((content === undefined || content.trim() === "") && sharedIndex === undefined) {
|
|
34295
|
+
return undefined;
|
|
34296
|
+
}
|
|
34297
|
+
return { content, sharedIndex, ref };
|
|
34280
34298
|
}
|
|
34281
34299
|
extractHyperLinks(worksheet) {
|
|
34282
34300
|
return this.mapOnElements({ parent: worksheet, query: "hyperlink" }, (linkElement) => {
|
|
@@ -68829,7 +68847,7 @@ class DataCleanupPlugin extends UIPlugin {
|
|
|
68829
68847
|
bottom: rowIndex,
|
|
68830
68848
|
}));
|
|
68831
68849
|
const handler = new CellClipboardHandler(this.getters, this.dispatch);
|
|
68832
|
-
const data = handler.copy(getClipboardDataPositions(sheetId, rowsToKeep));
|
|
68850
|
+
const data = handler.copy(getClipboardDataPositions(sheetId, rowsToKeep), false);
|
|
68833
68851
|
if (!data) {
|
|
68834
68852
|
return;
|
|
68835
68853
|
}
|
|
@@ -70869,12 +70887,12 @@ class ClipboardPlugin extends UIPlugin {
|
|
|
70869
70887
|
}
|
|
70870
70888
|
case "INSERT_CELL": {
|
|
70871
70889
|
const { cut, paste } = this.getInsertCellsTargets(cmd.zone, cmd.shiftDimension);
|
|
70872
|
-
const copiedData = this.copy(cut);
|
|
70890
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70873
70891
|
return this.isPasteAllowed(paste, copiedData, { isCutOperation: true });
|
|
70874
70892
|
}
|
|
70875
70893
|
case "DELETE_CELL": {
|
|
70876
70894
|
const { cut, paste } = this.getDeleteCellsTargets(cmd.zone, cmd.shiftDimension);
|
|
70877
|
-
const copiedData = this.copy(cut);
|
|
70895
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70878
70896
|
return this.isPasteAllowed(paste, copiedData, { isCutOperation: true });
|
|
70879
70897
|
}
|
|
70880
70898
|
}
|
|
@@ -70985,13 +71003,13 @@ class ClipboardPlugin extends UIPlugin {
|
|
|
70985
71003
|
});
|
|
70986
71004
|
break;
|
|
70987
71005
|
}
|
|
70988
|
-
const copiedData = this.copy(cut);
|
|
71006
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70989
71007
|
this.paste(paste, copiedData, { isCutOperation: true });
|
|
70990
71008
|
break;
|
|
70991
71009
|
}
|
|
70992
71010
|
case "INSERT_CELL": {
|
|
70993
71011
|
const { cut, paste } = this.getInsertCellsTargets(cmd.zone, cmd.shiftDimension);
|
|
70994
|
-
const copiedData = this.copy(cut);
|
|
71012
|
+
const copiedData = this.copy(cut, "shiftCells");
|
|
70995
71013
|
this.paste(paste, copiedData, { isCutOperation: true });
|
|
70996
71014
|
break;
|
|
70997
71015
|
}
|
|
@@ -71106,11 +71124,11 @@ class ClipboardPlugin extends UIPlugin {
|
|
|
71106
71124
|
}
|
|
71107
71125
|
return false;
|
|
71108
71126
|
}
|
|
71109
|
-
copy(zones) {
|
|
71127
|
+
copy(zones, mode = "copyPaste") {
|
|
71110
71128
|
let copiedData = {};
|
|
71111
71129
|
const clipboardData = this.getClipboardData(zones);
|
|
71112
71130
|
for (const { handlerName, handler } of this.selectClipboardHandlers(clipboardData)) {
|
|
71113
|
-
const data = handler.copy(clipboardData, this._isCutOperation);
|
|
71131
|
+
const data = handler.copy(clipboardData, this._isCutOperation, mode);
|
|
71114
71132
|
copiedData[handlerName] = data;
|
|
71115
71133
|
const minimalKeys = ["sheetId", "cells", "zones", "figureId"];
|
|
71116
71134
|
for (const key of minimalKeys) {
|
|
@@ -72061,7 +72079,7 @@ class GridSelectionPlugin extends UIPlugin {
|
|
|
72061
72079
|
];
|
|
72062
72080
|
for (const Handler of clipboardHandlersRegistries.cellHandlers.getAll()) {
|
|
72063
72081
|
const handler = new Handler(this.getters, this.dispatch);
|
|
72064
|
-
const data = handler.copy(getClipboardDataPositions(sheetId, target));
|
|
72082
|
+
const data = handler.copy(getClipboardDataPositions(sheetId, target), false, "shiftCells");
|
|
72065
72083
|
if (!data) {
|
|
72066
72084
|
continue;
|
|
72067
72085
|
}
|
|
@@ -80252,7 +80270,7 @@ class Model extends EventBus {
|
|
|
80252
80270
|
handlers = [];
|
|
80253
80271
|
uiHandlers = [];
|
|
80254
80272
|
coreHandlers = [];
|
|
80255
|
-
constructor(data = {}, config = {}, stateUpdateMessages = [], uuidGenerator = new UuidGenerator(), verboseImport =
|
|
80273
|
+
constructor(data = {}, config = {}, stateUpdateMessages = [], uuidGenerator = new UuidGenerator(), verboseImport = false) {
|
|
80256
80274
|
const start = performance.now();
|
|
80257
80275
|
console.debug("##### Model creation #####");
|
|
80258
80276
|
super();
|
|
@@ -80949,6 +80967,6 @@ const chartHelpers = { ...CHART_HELPERS, ...CHART_RUNTIME_HELPERS };
|
|
|
80949
80967
|
export { AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, CellErrorType, CommandResult, CorePlugin, CoreViewPlugin, DispatchResult, EvaluationError, Model, PivotRuntimeDefinition, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, SpreadsheetPivotTable, UIPlugin, __info__, addFunction, addRenderingLayer, astToFormula, chartHelpers, compile, compileTokens, components, constants, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, hooks, invalidateCFEvaluationCommands, invalidateChartEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, iterateAstNodes, links, load, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
|
|
80950
80968
|
|
|
80951
80969
|
|
|
80952
|
-
__info__.version = "18.3.
|
|
80953
|
-
__info__.date = "2025-09-
|
|
80954
|
-
__info__.hash = "
|
|
80970
|
+
__info__.version = "18.3.20";
|
|
80971
|
+
__info__.date = "2025-09-11T08:45:37.934Z";
|
|
80972
|
+
__info__.hash = "ef829f4";
|