@odoo/o-spreadsheet 18.4.42 → 18.4.46
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.
- package/dist/o_spreadsheet.css +3 -3
- package/dist/o_spreadsheet.esm.js +129 -114
- package/dist/o_spreadsheet.iife.js +129 -114
- package/dist/o_spreadsheet.iife.min.js +213 -213
- package/dist/o_spreadsheet.xml +4 -4
- package/package.json +7 -2
- package/dist/o_spreadsheet.cjs.js +0 -75603
package/dist/o_spreadsheet.css
CHANGED
|
@@ -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.4.
|
|
6
|
-
* @date 2026-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 18.4.46
|
|
6
|
+
* @date 2026-07-01T05:02:58.175Z
|
|
7
|
+
* @hash 26297b3
|
|
8
8
|
*/
|
|
9
9
|
/* Originates from src/components/top_bar/top_bar.scss */
|
|
10
10
|
@media (max-width: 1200px) {
|
|
@@ -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.4.
|
|
6
|
-
* @date 2026-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 18.4.46
|
|
6
|
+
* @date 2026-07-01T05:02:56.676Z
|
|
7
|
+
* @hash 26297b3
|
|
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, xml } from "@odoo/owl";
|
|
@@ -213,7 +213,7 @@ const GRAY_300 = "#D8DADD";
|
|
|
213
213
|
const GRAY_200 = "#E7E9ED";
|
|
214
214
|
const GRAY_100 = "#F9FAFB";
|
|
215
215
|
const TEXT_BODY = "#374151";
|
|
216
|
-
const TEXT_BODY_MUTED =
|
|
216
|
+
const TEXT_BODY_MUTED = "#374151C2";
|
|
217
217
|
const TEXT_HEADING = "#111827";
|
|
218
218
|
const PRIMARY_BUTTON_BG = "#714B67";
|
|
219
219
|
const PRIMARY_BUTTON_HOVER_BG = "#624159";
|
|
@@ -320,9 +320,6 @@ const COLOR_PICKER_DEFAULTS = [
|
|
|
320
320
|
];
|
|
321
321
|
const DEFAULT_CELL_HEIGHT = 23;
|
|
322
322
|
const FOOTER_HEIGHT = 2 * 23;
|
|
323
|
-
const MENU_SEPARATOR_BORDER_WIDTH = 1;
|
|
324
|
-
const MENU_SEPARATOR_PADDING = 5;
|
|
325
|
-
const MENU_SEPARATOR_HEIGHT = 1 + 2 * 5;
|
|
326
323
|
const DEFAULT_STYLE = {
|
|
327
324
|
align: "left",
|
|
328
325
|
verticalAlign: "bottom",
|
|
@@ -342,7 +339,7 @@ const DEFAULT_NUMBER_STYLE = {
|
|
|
342
339
|
const DEFAULT_VERTICAL_ALIGN = DEFAULT_STYLE.verticalAlign;
|
|
343
340
|
const DEFAULT_WRAPPING_MODE = DEFAULT_STYLE.wrapping;
|
|
344
341
|
const DEFAULT_FONT_SIZE = DEFAULT_STYLE.fontSize;
|
|
345
|
-
const DEFAULT_FONT = "'Roboto', arial";
|
|
342
|
+
const DEFAULT_FONT = "'Roboto', arial, 'Liberation Sans'";
|
|
346
343
|
const DEFAULT_BORDER_DESC = {
|
|
347
344
|
style: "thin",
|
|
348
345
|
color: "#000000"
|
|
@@ -1624,7 +1621,7 @@ function isPositionDependent(cmd) {
|
|
|
1624
1621
|
function isZoneDependent(cmd) {
|
|
1625
1622
|
return "sheetId" in cmd && "zone" in cmd;
|
|
1626
1623
|
}
|
|
1627
|
-
const invalidateEvaluationCommands = new Set([
|
|
1624
|
+
const invalidateEvaluationCommands = /* @__PURE__ */ new Set([
|
|
1628
1625
|
"RENAME_SHEET",
|
|
1629
1626
|
"DELETE_SHEET",
|
|
1630
1627
|
"CREATE_SHEET",
|
|
@@ -1643,7 +1640,7 @@ const invalidateEvaluationCommands = new Set([
|
|
|
1643
1640
|
"REMOVE_PIVOT",
|
|
1644
1641
|
"DUPLICATE_PIVOT"
|
|
1645
1642
|
]);
|
|
1646
|
-
const invalidateChartEvaluationCommands = new Set([
|
|
1643
|
+
const invalidateChartEvaluationCommands = /* @__PURE__ */ new Set([
|
|
1647
1644
|
"EVALUATE_CELLS",
|
|
1648
1645
|
"EVALUATE_CHARTS",
|
|
1649
1646
|
"UPDATE_CELL",
|
|
@@ -1662,20 +1659,20 @@ const invalidateChartEvaluationCommands = new Set([
|
|
|
1662
1659
|
"UNDO",
|
|
1663
1660
|
"REDO"
|
|
1664
1661
|
]);
|
|
1665
|
-
const invalidateDependenciesCommands = new Set(["MOVE_RANGES"]);
|
|
1666
|
-
const invalidateCFEvaluationCommands = new Set([
|
|
1662
|
+
const invalidateDependenciesCommands = /* @__PURE__ */ new Set(["MOVE_RANGES"]);
|
|
1663
|
+
const invalidateCFEvaluationCommands = /* @__PURE__ */ new Set([
|
|
1667
1664
|
"EVALUATE_CELLS",
|
|
1668
1665
|
"ADD_CONDITIONAL_FORMAT",
|
|
1669
1666
|
"REMOVE_CONDITIONAL_FORMAT",
|
|
1670
1667
|
"CHANGE_CONDITIONAL_FORMAT_PRIORITY"
|
|
1671
1668
|
]);
|
|
1672
|
-
const invalidateBordersCommands = new Set([
|
|
1669
|
+
const invalidateBordersCommands = /* @__PURE__ */ new Set([
|
|
1673
1670
|
"AUTOFILL_CELL",
|
|
1674
1671
|
"SET_BORDER",
|
|
1675
1672
|
"SET_ZONE_BORDERS",
|
|
1676
1673
|
"SET_BORDERS_ON_TARGET"
|
|
1677
1674
|
]);
|
|
1678
|
-
const readonlyAllowedCommands = new Set([
|
|
1675
|
+
const readonlyAllowedCommands = /* @__PURE__ */ new Set([
|
|
1679
1676
|
"START",
|
|
1680
1677
|
"ACTIVATE_SHEET",
|
|
1681
1678
|
"COPY",
|
|
@@ -1687,7 +1684,7 @@ const readonlyAllowedCommands = new Set([
|
|
|
1687
1684
|
"UPDATE_FILTER",
|
|
1688
1685
|
"UPDATE_CHART"
|
|
1689
1686
|
]);
|
|
1690
|
-
const coreTypes = new Set([
|
|
1687
|
+
const coreTypes = /* @__PURE__ */ new Set([
|
|
1691
1688
|
"UPDATE_CELL",
|
|
1692
1689
|
"UPDATE_CELL_POSITION",
|
|
1693
1690
|
"CLEAR_CELL",
|
|
@@ -1919,7 +1916,7 @@ let CommandResult = /* @__PURE__ */ function(CommandResult) {
|
|
|
1919
1916
|
|
|
1920
1917
|
//#endregion
|
|
1921
1918
|
//#region src/types/conditional_formatting.ts
|
|
1922
|
-
const availableConditionalFormatOperators = new Set([
|
|
1919
|
+
const availableConditionalFormatOperators = /* @__PURE__ */ new Set([
|
|
1923
1920
|
"containsText",
|
|
1924
1921
|
"notContainsText",
|
|
1925
1922
|
"isGreaterThan",
|
|
@@ -1938,7 +1935,7 @@ const availableConditionalFormatOperators = new Set([
|
|
|
1938
1935
|
|
|
1939
1936
|
//#endregion
|
|
1940
1937
|
//#region src/types/data_validation.ts
|
|
1941
|
-
const availableDataValidationOperators = new Set([
|
|
1938
|
+
const availableDataValidationOperators = /* @__PURE__ */ new Set([
|
|
1942
1939
|
"containsText",
|
|
1943
1940
|
"notContainsText",
|
|
1944
1941
|
"isEqualText",
|
|
@@ -2663,12 +2660,10 @@ const getNumberRegex = memoize(function getNumberRegex(locale) {
|
|
|
2663
2660
|
const pIntegerAndDecimals = `(?:\\d+(?:${escapeRegExp(locale.thousandsSeparator || "")}\\d{3,})*(?:${decimalSeparator}\\d*)?)`;
|
|
2664
2661
|
const pOnlyDecimals = `(?:${decimalSeparator}\\d+)`;
|
|
2665
2662
|
const pNumber = "(?:\\s*" + pIntegerAndDecimals + "|" + pOnlyDecimals + ")(?:e(?:\\+|-)?\\d+)?(?:\\s*%)?";
|
|
2666
|
-
const pMinus = "(?:\\s*-)?";
|
|
2667
|
-
const pCurrencyFormat = "(?:\\s*[\\$€])?";
|
|
2668
2663
|
const pNumberExp = "^(?:(?:" + [
|
|
2669
|
-
|
|
2670
|
-
|
|
2671
|
-
|
|
2664
|
+
"(?:\\s*-)?(?:\\s*[\\$€])?" + pNumber,
|
|
2665
|
+
"(?:\\s*-)?" + pNumber + "(?:\\s*[\\$€])?",
|
|
2666
|
+
"(?:\\s*[\\$€])?(?:\\s*-)?" + pNumber
|
|
2672
2667
|
].join(")|(?:") + "))$";
|
|
2673
2668
|
return new RegExp(pNumberExp, "i");
|
|
2674
2669
|
});
|
|
@@ -4579,7 +4574,7 @@ function getDateCriterionFormattedValues(values, locale) {
|
|
|
4579
4574
|
function recomputeZones(zones, zonesToRemove = []) {
|
|
4580
4575
|
if (zones.length <= 1 && zonesToRemove.length === 0) return zones;
|
|
4581
4576
|
const profilesStartingPosition = [0];
|
|
4582
|
-
const profiles = new Map([[0, []]]);
|
|
4577
|
+
const profiles = /* @__PURE__ */ new Map([[0, []]]);
|
|
4583
4578
|
modifyProfiles(profilesStartingPosition, profiles, zones, false);
|
|
4584
4579
|
modifyProfiles(profilesStartingPosition, profiles, zonesToRemove, true);
|
|
4585
4580
|
return constructZonesFromProfiles(profilesStartingPosition, profiles);
|
|
@@ -5318,7 +5313,6 @@ function getCanonicalRepresentation(item) {
|
|
|
5318
5313
|
//#region src/helpers/edge_scrolling.ts
|
|
5319
5314
|
const MAX_DELAY = 140;
|
|
5320
5315
|
const MIN_DELAY = 20;
|
|
5321
|
-
const ACCELERATION = .035;
|
|
5322
5316
|
/**
|
|
5323
5317
|
* Decreasing exponential function used to determine the "speed" of edge-scrolling
|
|
5324
5318
|
* as the timeout delay.
|
|
@@ -5326,7 +5320,7 @@ const ACCELERATION = .035;
|
|
|
5326
5320
|
* Returns a timeout delay in milliseconds.
|
|
5327
5321
|
*/
|
|
5328
5322
|
function scrollDelay(value) {
|
|
5329
|
-
return 20 + (140 - 20) * Math.exp(
|
|
5323
|
+
return 20 + (140 - 20) * Math.exp(-.035 * (value - 1));
|
|
5330
5324
|
}
|
|
5331
5325
|
|
|
5332
5326
|
//#endregion
|
|
@@ -6152,7 +6146,7 @@ var UuidGenerator = class {
|
|
|
6152
6146
|
smallUuid() {
|
|
6153
6147
|
if (window.crypto) return "10000000-1000".replace(/[01]/g, (c) => {
|
|
6154
6148
|
const n = Number(c);
|
|
6155
|
-
return (n ^ crypto.getRandomValues(new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
|
|
6149
|
+
return (n ^ crypto.getRandomValues(/* @__PURE__ */ new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
|
|
6156
6150
|
});
|
|
6157
6151
|
else return "xxxxxxxx-xxxx".replace(/[xy]/g, function(c) {
|
|
6158
6152
|
const r = Math.random() * 16 | 0;
|
|
@@ -6166,7 +6160,7 @@ var UuidGenerator = class {
|
|
|
6166
6160
|
uuidv4() {
|
|
6167
6161
|
if (window.crypto) return "10000000-1000-4000-8000-100000000000".replace(/[018]/g, (c) => {
|
|
6168
6162
|
const n = Number(c);
|
|
6169
|
-
return (n ^ crypto.getRandomValues(new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
|
|
6163
|
+
return (n ^ crypto.getRandomValues(/* @__PURE__ */ new Uint8Array(1))[0] & 15 >> n / 4).toString(16);
|
|
6170
6164
|
});
|
|
6171
6165
|
else return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(c) {
|
|
6172
6166
|
const r = Math.random() * 16 | 0;
|
|
@@ -7610,10 +7604,10 @@ function toNormalizedPivotValue(dimension, groupValue) {
|
|
|
7610
7604
|
type: dimension.type
|
|
7611
7605
|
}));
|
|
7612
7606
|
if (groupValueString.toLowerCase() === "false") return false;
|
|
7613
|
-
return pivotNormalizationValueRegistry.get(dimension.type)(groupValueString, dimension
|
|
7607
|
+
return pivotNormalizationValueRegistry.get(dimension.type)(groupValueString, dimension);
|
|
7614
7608
|
}
|
|
7615
|
-
function normalizeDateTime(value,
|
|
7616
|
-
return pivotTimeAdapter(granularity ?? "month").normalizeFunctionValue(value);
|
|
7609
|
+
function normalizeDateTime(value, dimension) {
|
|
7610
|
+
return pivotTimeAdapter(dimension.granularity ?? "month").normalizeFunctionValue(value);
|
|
7617
7611
|
}
|
|
7618
7612
|
function toFunctionPivotValue(value, dimension) {
|
|
7619
7613
|
if (value === null) return `"null"`;
|
|
@@ -26261,11 +26255,11 @@ var FigureComponent = class extends Component {
|
|
|
26261
26255
|
getResizerPosition(resizer) {
|
|
26262
26256
|
const anchorCenteringOffset = (ANCHOR_SIZE - ACTIVE_BORDER_WIDTH) / 2;
|
|
26263
26257
|
const style = {};
|
|
26264
|
-
if (resizer.includes("top")) style.top =
|
|
26265
|
-
else if (resizer.includes("bottom")) style.bottom =
|
|
26258
|
+
if (resizer.includes("top")) style.top = `-3px`;
|
|
26259
|
+
else if (resizer.includes("bottom")) style.bottom = `-3px`;
|
|
26266
26260
|
else style.bottom = `calc(50% - ${anchorCenteringOffset}px)`;
|
|
26267
|
-
if (resizer.includes("left")) style.left =
|
|
26268
|
-
else if (resizer.includes("right")) style.right =
|
|
26261
|
+
if (resizer.includes("left")) style.left = `-3px`;
|
|
26262
|
+
else if (resizer.includes("right")) style.right = `-3px`;
|
|
26269
26263
|
else style.right = `calc(50% - ${anchorCenteringOffset}px)`;
|
|
26270
26264
|
return cssPropertiesToCss(style);
|
|
26271
26265
|
}
|
|
@@ -29226,11 +29220,10 @@ function startDnd(onPointerMove, onPointerUp) {
|
|
|
29226
29220
|
const LINE_VERTICAL_PADDING = 1;
|
|
29227
29221
|
const PICKER_PADDING = 8;
|
|
29228
29222
|
const ITEM_BORDER_WIDTH = 1;
|
|
29229
|
-
const ITEM_EDGE_LENGTH = 18;
|
|
29230
29223
|
const ITEMS_PER_LINE = 10;
|
|
29231
29224
|
const MAGNIFIER_EDGE = 16;
|
|
29232
29225
|
const ITEM_GAP = 2;
|
|
29233
|
-
const CONTENT_WIDTH =
|
|
29226
|
+
const CONTENT_WIDTH = 218;
|
|
29234
29227
|
const INNER_GRADIENT_WIDTH = CONTENT_WIDTH - 2 * ITEM_BORDER_WIDTH;
|
|
29235
29228
|
const INNER_GRADIENT_HEIGHT = CONTENT_WIDTH - 30 - 2 * ITEM_BORDER_WIDTH;
|
|
29236
29229
|
css`
|
|
@@ -29242,7 +29235,7 @@ css`
|
|
|
29242
29235
|
line-height: 1.2;
|
|
29243
29236
|
overflow-y: auto;
|
|
29244
29237
|
overflow-x: hidden;
|
|
29245
|
-
width: ${
|
|
29238
|
+
width: ${234}px;
|
|
29246
29239
|
|
|
29247
29240
|
.o-color-picker-section-name {
|
|
29248
29241
|
margin: 0px ${ITEM_BORDER_WIDTH}px;
|
|
@@ -29268,8 +29261,8 @@ css`
|
|
|
29268
29261
|
}
|
|
29269
29262
|
}
|
|
29270
29263
|
.o-color-picker-line-item {
|
|
29271
|
-
width: ${
|
|
29272
|
-
height: ${
|
|
29264
|
+
width: ${20}px;
|
|
29265
|
+
height: ${20}px;
|
|
29273
29266
|
margin: 0px;
|
|
29274
29267
|
border-radius: 50px;
|
|
29275
29268
|
border: ${ITEM_BORDER_WIDTH}px solid #666666;
|
|
@@ -29313,13 +29306,13 @@ css`
|
|
|
29313
29306
|
}
|
|
29314
29307
|
|
|
29315
29308
|
.o-custom-selector {
|
|
29316
|
-
padding: ${
|
|
29309
|
+
padding: ${10}px ${PICKER_PADDING}px;
|
|
29317
29310
|
position: relative;
|
|
29318
29311
|
.o-gradient {
|
|
29319
29312
|
margin-bottom: ${MAGNIFIER_EDGE / 2}px;
|
|
29320
29313
|
border: ${ITEM_BORDER_WIDTH}px solid #c0c0c0;
|
|
29321
|
-
width: ${
|
|
29322
|
-
height: ${
|
|
29314
|
+
width: ${218}px;
|
|
29315
|
+
height: ${188}px;
|
|
29323
29316
|
position: relative;
|
|
29324
29317
|
}
|
|
29325
29318
|
|
|
@@ -29457,8 +29450,8 @@ var ColorPicker = class extends Component {
|
|
|
29457
29450
|
const left = Math.round(INNER_GRADIENT_WIDTH * clip(s / 100, 0, 1));
|
|
29458
29451
|
const top = Math.round(INNER_GRADIENT_HEIGHT * clip(1 - 2 * l / (200 - s), 0, 1));
|
|
29459
29452
|
return cssPropertiesToCss({
|
|
29460
|
-
left: `${-
|
|
29461
|
-
top: `${-
|
|
29453
|
+
left: `${-16 / 2 + left}px`,
|
|
29454
|
+
top: `${-16 / 2 + top}px`,
|
|
29462
29455
|
background: hslaToHex(this.state.currentHslaColor)
|
|
29463
29456
|
});
|
|
29464
29457
|
}
|
|
@@ -31640,17 +31633,16 @@ linkMenuRegistry.add("sheet", {
|
|
|
31640
31633
|
|
|
31641
31634
|
//#endregion
|
|
31642
31635
|
//#region src/components/link/link_editor/link_editor.ts
|
|
31643
|
-
const PADDING = 12;
|
|
31644
31636
|
css`
|
|
31645
31637
|
.o-link-editor {
|
|
31646
31638
|
font-size: 13px;
|
|
31647
31639
|
background-color: white;
|
|
31648
31640
|
box-shadow: 0 1px 4px 3px rgba(60, 64, 67, 0.15);
|
|
31649
|
-
padding: ${
|
|
31641
|
+
padding: ${12}px;
|
|
31650
31642
|
display: flex;
|
|
31651
31643
|
flex-direction: column;
|
|
31652
31644
|
border-radius: 4px;
|
|
31653
|
-
width: ${
|
|
31645
|
+
width: ${364}px;
|
|
31654
31646
|
|
|
31655
31647
|
.o-section {
|
|
31656
31648
|
.o-section-title {
|
|
@@ -39673,8 +39665,12 @@ var CellComposerStore = class extends AbstractComposerStore {
|
|
|
39673
39665
|
}
|
|
39674
39666
|
stopEdition(direction) {
|
|
39675
39667
|
if (this.canStopEdition()) {
|
|
39668
|
+
const { col, row } = this.currentEditedCell;
|
|
39676
39669
|
this._stopEdition();
|
|
39677
|
-
if (direction)
|
|
39670
|
+
if (direction) {
|
|
39671
|
+
this.model.selection.selectCell(col, row);
|
|
39672
|
+
this.model.selection.moveAnchorCell(direction, 1);
|
|
39673
|
+
}
|
|
39678
39674
|
return;
|
|
39679
39675
|
}
|
|
39680
39676
|
const editedCell = this.currentEditedCell;
|
|
@@ -47020,9 +47016,9 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47020
47016
|
allSheetsMatches = [];
|
|
47021
47017
|
activeSheetMatches = [];
|
|
47022
47018
|
specificRangeMatches = [];
|
|
47019
|
+
selectedMatchPosition = null;
|
|
47023
47020
|
currentSearchRegex = null;
|
|
47024
47021
|
initialShowFormulaState;
|
|
47025
|
-
preserveSelectedMatchIndex = false;
|
|
47026
47022
|
irreplaceableMatchCount = 0;
|
|
47027
47023
|
isSearchDirty = false;
|
|
47028
47024
|
shouldFinalizeUpdateSelection = false;
|
|
@@ -47144,7 +47140,10 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47144
47140
|
*/
|
|
47145
47141
|
_updateSearch(toSearch, searchOptions) {
|
|
47146
47142
|
this.searchOptions = searchOptions;
|
|
47147
|
-
if (toSearch !== this.toSearch)
|
|
47143
|
+
if (toSearch !== this.toSearch) {
|
|
47144
|
+
this.selectedMatchIndex = null;
|
|
47145
|
+
this.selectedMatchPosition = null;
|
|
47146
|
+
}
|
|
47148
47147
|
this.toSearch = toSearch;
|
|
47149
47148
|
this.currentSearchRegex = getSearchRegex(this.toSearch, this.searchOptions);
|
|
47150
47149
|
this.refreshSearch({
|
|
@@ -47156,8 +47155,14 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47156
47155
|
* refresh the matches according to the current search options
|
|
47157
47156
|
*/
|
|
47158
47157
|
refreshSearch(options) {
|
|
47159
|
-
if (!this.preserveSelectedMatchIndex) this.selectedMatchIndex = null;
|
|
47160
47158
|
this.findMatches();
|
|
47159
|
+
if (this.selectedMatchPosition) if (this.selectedMatchPosition.sheetId !== this.getters.getActiveSheetId()) {
|
|
47160
|
+
this.selectedMatchIndex = null;
|
|
47161
|
+
this.selectedMatchPosition = null;
|
|
47162
|
+
} else {
|
|
47163
|
+
const index = this.searchMatches.findIndex((match) => match.sheetId === this.selectedMatchPosition?.sheetId && match.col === this.selectedMatchPosition?.col && match.row === this.selectedMatchPosition?.row);
|
|
47164
|
+
if (index !== -1) this.selectedMatchIndex = index;
|
|
47165
|
+
}
|
|
47161
47166
|
this.selectNextCell(0, options);
|
|
47162
47167
|
}
|
|
47163
47168
|
getSheetsInSearchOrder() {
|
|
@@ -47225,6 +47230,7 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47225
47230
|
const matches = this.searchMatches;
|
|
47226
47231
|
if (!matches.length) {
|
|
47227
47232
|
this.selectedMatchIndex = null;
|
|
47233
|
+
this.selectedMatchPosition = null;
|
|
47228
47234
|
return;
|
|
47229
47235
|
}
|
|
47230
47236
|
let nextIndex;
|
|
@@ -47238,14 +47244,13 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47238
47244
|
} else nextIndex = this.selectedMatchIndex + indexChange;
|
|
47239
47245
|
nextIndex = (nextIndex + matches.length) % matches.length;
|
|
47240
47246
|
this.selectedMatchIndex = nextIndex;
|
|
47247
|
+
this.selectedMatchPosition = matches[this.selectedMatchIndex];
|
|
47241
47248
|
const selectedMatch = matches[nextIndex];
|
|
47242
47249
|
if (options.jumpToMatchSheet && this.getters.getActiveSheetId() !== selectedMatch.sheetId) {
|
|
47243
|
-
this.preserveSelectedMatchIndex = true;
|
|
47244
47250
|
this.model.dispatch("ACTIVATE_SHEET", {
|
|
47245
47251
|
sheetIdFrom: this.getters.getActiveSheetId(),
|
|
47246
47252
|
sheetIdTo: selectedMatch.sheetId
|
|
47247
47253
|
});
|
|
47248
|
-
this.preserveSelectedMatchIndex = false;
|
|
47249
47254
|
this.isSearchDirty = false;
|
|
47250
47255
|
}
|
|
47251
47256
|
this.model.selection.getBackToDefault();
|
|
@@ -47256,7 +47261,6 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47256
47261
|
*/
|
|
47257
47262
|
replace() {
|
|
47258
47263
|
if (this.selectedMatchIndex === null) return;
|
|
47259
|
-
this.preserveSelectedMatchIndex = true;
|
|
47260
47264
|
this.shouldFinalizeUpdateSelection = true;
|
|
47261
47265
|
this.model.dispatch("REPLACE_SEARCH", {
|
|
47262
47266
|
searchString: this.toSearch,
|
|
@@ -47264,7 +47268,6 @@ var FindAndReplaceStore = class extends SpreadsheetStore {
|
|
|
47264
47268
|
matches: [this.searchMatches[this.selectedMatchIndex]],
|
|
47265
47269
|
searchOptions: this.searchOptions
|
|
47266
47270
|
});
|
|
47267
|
-
this.preserveSelectedMatchIndex = false;
|
|
47268
47271
|
}
|
|
47269
47272
|
/**
|
|
47270
47273
|
* Apply the replace function to all the matches one time.
|
|
@@ -48690,8 +48693,8 @@ var PivotRuntimeDefinition = class {
|
|
|
48690
48693
|
collapsedDomains;
|
|
48691
48694
|
constructor(definition, fields) {
|
|
48692
48695
|
this.measures = definition.measures.map((measure) => createMeasure(fields, measure));
|
|
48693
|
-
this.columns = definition.columns.map((dimension) => createPivotDimension(fields, dimension));
|
|
48694
|
-
this.rows = definition.rows.map((dimension) => createPivotDimension(fields, dimension));
|
|
48696
|
+
this.columns = definition.columns.map((dimension) => this.createPivotDimension(fields, dimension));
|
|
48697
|
+
this.rows = definition.rows.map((dimension) => this.createPivotDimension(fields, dimension));
|
|
48695
48698
|
this.sortedColumn = definition.sortedColumn;
|
|
48696
48699
|
this.collapsedDomains = definition.collapsedDomains;
|
|
48697
48700
|
}
|
|
@@ -48705,6 +48708,40 @@ var PivotRuntimeDefinition = class {
|
|
|
48705
48708
|
if (!measure) throw new EvaluationError(_t("Field %s is not a measure", id));
|
|
48706
48709
|
return measure;
|
|
48707
48710
|
}
|
|
48711
|
+
createPivotDimension(fields, dimension) {
|
|
48712
|
+
const field = fields[dimension.fieldName];
|
|
48713
|
+
const type = field?.type ?? "integer";
|
|
48714
|
+
const granularity = field && isDateOrDatetimeField(field) ? dimension.granularity : void 0;
|
|
48715
|
+
return {
|
|
48716
|
+
/**
|
|
48717
|
+
* Get the display name of the dimension
|
|
48718
|
+
* e.g. "stage_id" -> "Stage", "create_date:month" -> "Create Date"
|
|
48719
|
+
*/
|
|
48720
|
+
displayName: field?.string ?? dimension.fieldName,
|
|
48721
|
+
/**
|
|
48722
|
+
* Get the name of the dimension, as it is stored in the pivot formula
|
|
48723
|
+
* e.g. "stage_id", "create_date:month"
|
|
48724
|
+
*/
|
|
48725
|
+
nameWithGranularity: dimension.fieldName + (granularity ? `:${granularity}` : ""),
|
|
48726
|
+
/**
|
|
48727
|
+
* Get the name of the field of the dimension
|
|
48728
|
+
* e.g. "stage_id" -> "stage_id", "create_date:month" -> "create_date"
|
|
48729
|
+
*/
|
|
48730
|
+
fieldName: dimension.fieldName,
|
|
48731
|
+
/**
|
|
48732
|
+
* Get the aggregate operator of the dimension
|
|
48733
|
+
* e.g. "stage_id" -> undefined, "create_date:month" -> "month"
|
|
48734
|
+
*/
|
|
48735
|
+
granularity,
|
|
48736
|
+
/**
|
|
48737
|
+
* Get the type of the field of the dimension
|
|
48738
|
+
* e.g. "stage_id" -> "many2one", "create_date:month" -> "date"
|
|
48739
|
+
*/
|
|
48740
|
+
type,
|
|
48741
|
+
order: dimension.order,
|
|
48742
|
+
isValid: !!field
|
|
48743
|
+
};
|
|
48744
|
+
}
|
|
48708
48745
|
};
|
|
48709
48746
|
function createMeasure(fields, measure) {
|
|
48710
48747
|
const fieldName = measure.fieldName;
|
|
@@ -48748,40 +48785,6 @@ function createMeasure(fields, measure) {
|
|
|
48748
48785
|
display: measure.display
|
|
48749
48786
|
};
|
|
48750
48787
|
}
|
|
48751
|
-
function createPivotDimension(fields, dimension) {
|
|
48752
|
-
const field = fields[dimension.fieldName];
|
|
48753
|
-
const type = field?.type ?? "integer";
|
|
48754
|
-
const granularity = field && isDateOrDatetimeField(field) ? dimension.granularity : void 0;
|
|
48755
|
-
return {
|
|
48756
|
-
/**
|
|
48757
|
-
* Get the display name of the dimension
|
|
48758
|
-
* e.g. "stage_id" -> "Stage", "create_date:month" -> "Create Date"
|
|
48759
|
-
*/
|
|
48760
|
-
displayName: field?.string ?? dimension.fieldName,
|
|
48761
|
-
/**
|
|
48762
|
-
* Get the name of the dimension, as it is stored in the pivot formula
|
|
48763
|
-
* e.g. "stage_id", "create_date:month"
|
|
48764
|
-
*/
|
|
48765
|
-
nameWithGranularity: dimension.fieldName + (granularity ? `:${granularity}` : ""),
|
|
48766
|
-
/**
|
|
48767
|
-
* Get the name of the field of the dimension
|
|
48768
|
-
* e.g. "stage_id" -> "stage_id", "create_date:month" -> "create_date"
|
|
48769
|
-
*/
|
|
48770
|
-
fieldName: dimension.fieldName,
|
|
48771
|
-
/**
|
|
48772
|
-
* Get the aggregate operator of the dimension
|
|
48773
|
-
* e.g. "stage_id" -> undefined, "create_date:month" -> "month"
|
|
48774
|
-
*/
|
|
48775
|
-
granularity,
|
|
48776
|
-
/**
|
|
48777
|
-
* Get the type of the field of the dimension
|
|
48778
|
-
* e.g. "stage_id" -> "many2one", "create_date:month" -> "date"
|
|
48779
|
-
*/
|
|
48780
|
-
type,
|
|
48781
|
-
order: dimension.order,
|
|
48782
|
-
isValid: !!field
|
|
48783
|
-
};
|
|
48784
|
-
}
|
|
48785
48788
|
|
|
48786
48789
|
//#endregion
|
|
48787
48790
|
//#region src/helpers/pivot/spreadsheet_pivot/runtime_definition_spreadsheet_pivot.ts
|
|
@@ -51898,7 +51901,7 @@ var Grid = class extends Component {
|
|
|
51898
51901
|
ev.preventDefault();
|
|
51899
51902
|
const clipboardData = ev.clipboardData;
|
|
51900
51903
|
if (!clipboardData) return;
|
|
51901
|
-
const image = [...clipboardData.files]
|
|
51904
|
+
const image = [...clipboardData.files].find((file) => AllowedImageMimeTypes.includes(file.type));
|
|
51902
51905
|
const osClipboard = { content: {
|
|
51903
51906
|
["text/plain"]: clipboardData?.getData("text/plain"),
|
|
51904
51907
|
["text/html"]: clipboardData?.getData("text/html")
|
|
@@ -58659,6 +58662,9 @@ var CustomColorsPlugin = class extends CoreViewPlugin {
|
|
|
58659
58662
|
case "CREATE_CHART":
|
|
58660
58663
|
this.tryToAddColors(this.getChartColors(cmd.figureId));
|
|
58661
58664
|
break;
|
|
58665
|
+
case "COLOR_SHEET":
|
|
58666
|
+
if (cmd.color) this.tryToAddColors([cmd.color]);
|
|
58667
|
+
break;
|
|
58662
58668
|
case "UPDATE_CELL":
|
|
58663
58669
|
case "ADD_CONDITIONAL_FORMAT":
|
|
58664
58670
|
case "SET_BORDER":
|
|
@@ -58681,8 +58687,12 @@ var CustomColorsPlugin = class extends CoreViewPlugin {
|
|
|
58681
58687
|
}
|
|
58682
58688
|
computeCustomColors() {
|
|
58683
58689
|
let usedColors = [];
|
|
58684
|
-
for (const sheetId of this.getters.getSheetIds()) usedColors = usedColors.concat(this.getColorsFromCells(sheetId), this.getFormattingColors(sheetId), this.getTableColors(sheetId));
|
|
58685
|
-
return [
|
|
58690
|
+
for (const sheetId of this.getters.getSheetIds()) usedColors = usedColors.concat(this.getSheetColors(sheetId), this.getColorsFromCells(sheetId), this.getFormattingColors(sheetId), this.getTableColors(sheetId));
|
|
58691
|
+
return [.../* @__PURE__ */ new Set([...usedColors])];
|
|
58692
|
+
}
|
|
58693
|
+
getSheetColors(sheetId) {
|
|
58694
|
+
const sheet = this.getters.getSheet(sheetId);
|
|
58695
|
+
return sheet.color ? [sheet.color] : [];
|
|
58686
58696
|
}
|
|
58687
58697
|
getColorsFromCells(sheetId) {
|
|
58688
58698
|
const cells = Object.values(this.getters.getCells(sheetId));
|
|
@@ -59342,7 +59352,7 @@ iconsOnCellRegistry.add("pivot_collapse", (getters, position) => {
|
|
|
59342
59352
|
const definition = getters.getPivotCoreDefinition(pivotId);
|
|
59343
59353
|
const isDashboard = getters.isDashboard();
|
|
59344
59354
|
const fields = pivotCell.dimension === "COL" ? definition.columns : definition.rows;
|
|
59345
|
-
const hasIcon = !isDashboard && pivotCell.domain.length !== fields.length;
|
|
59355
|
+
const hasIcon = !isDashboard && !getters.shouldShowFormulas() && pivotCell.domain.length !== fields.length;
|
|
59346
59356
|
const isCollapsed = (definition.collapsedDomains?.[pivotCell.dimension] ?? []).some((domain) => deepEquals(domain, pivotCell.domain));
|
|
59347
59357
|
const indent = pivotCell.dimension === "ROW" ? (pivotCell.domain.length - 1) * 15 : 0;
|
|
59348
59358
|
return {
|
|
@@ -63653,7 +63663,7 @@ var TableComputedStylePlugin = class extends UIPlugin {
|
|
|
63653
63663
|
};
|
|
63654
63664
|
}
|
|
63655
63665
|
};
|
|
63656
|
-
const invalidateTableStyleCommandsSet = new Set([
|
|
63666
|
+
const invalidateTableStyleCommandsSet = /* @__PURE__ */ new Set([
|
|
63657
63667
|
"HIDE_COLUMNS_ROWS",
|
|
63658
63668
|
"UNHIDE_COLUMNS_ROWS",
|
|
63659
63669
|
"UNFOLD_HEADER_GROUP",
|
|
@@ -65909,14 +65919,14 @@ var InternalViewport = class {
|
|
|
65909
65919
|
adjustPositionX(targetCol) {
|
|
65910
65920
|
const sheetId = this.sheetId;
|
|
65911
65921
|
const { start, end } = this.getters.getColDimensions(sheetId, targetCol);
|
|
65912
|
-
if (this.offsetX + this.viewportWidth + this.offsetCorrectionX < end) this.offsetX = end - this.viewportWidth;
|
|
65922
|
+
if (this.offsetX + this.viewportWidth + this.offsetCorrectionX < end) this.offsetX = end - this.viewportWidth - this.offsetCorrectionX;
|
|
65913
65923
|
else if (this.offsetX + this.offsetCorrectionX > start) this.offsetX = start - this.offsetCorrectionX;
|
|
65914
65924
|
this.adjustViewportZoneX();
|
|
65915
65925
|
}
|
|
65916
65926
|
adjustPositionY(targetRow) {
|
|
65917
65927
|
const sheetId = this.sheetId;
|
|
65918
65928
|
const { start, end } = this.getters.getRowDimensions(sheetId, targetRow);
|
|
65919
|
-
if (this.offsetY + this.viewportHeight + this.offsetCorrectionY < end) this.offsetY = end - this.viewportHeight;
|
|
65929
|
+
if (this.offsetY + this.viewportHeight + this.offsetCorrectionY < end) this.offsetY = end - this.viewportHeight - this.offsetCorrectionY;
|
|
65920
65930
|
else if (this.offsetY + this.offsetCorrectionY > start) this.offsetY = start - this.offsetCorrectionY;
|
|
65921
65931
|
this.adjustViewportZoneY();
|
|
65922
65932
|
}
|
|
@@ -68329,11 +68339,14 @@ var BottomBarSheet = class extends Component {
|
|
|
68329
68339
|
}
|
|
68330
68340
|
});
|
|
68331
68341
|
this.DOMFocusableElementStore = useStore(DOMFocusableElementStore);
|
|
68332
|
-
useExternalListener(window, "click", ()
|
|
68342
|
+
useExternalListener(window, "click", this.onExternalClick.bind(this), { capture: true });
|
|
68333
68343
|
useEffect((sheetId) => {
|
|
68334
68344
|
if (this.props.sheetId === sheetId) this.scrollToSheet();
|
|
68335
68345
|
}, () => [this.env.model.getters.getActiveSheetId()]);
|
|
68336
68346
|
}
|
|
68347
|
+
onExternalClick(ev) {
|
|
68348
|
+
if (!ev.target.closest(".o-color-picker")) this.state.pickerOpened = false;
|
|
68349
|
+
}
|
|
68337
68350
|
focusInputAndSelectContent() {
|
|
68338
68351
|
if (!this.state.isEditing || !this.sheetNameRef.el) return;
|
|
68339
68352
|
this.sheetNameRef.el.focus();
|
|
@@ -68435,6 +68448,8 @@ var BottomBarSheet = class extends Component {
|
|
|
68435
68448
|
},
|
|
68436
68449
|
openSheetColorPickerCallback: () => {
|
|
68437
68450
|
this.state.pickerOpened = true;
|
|
68451
|
+
const sheet = this.env.model.getters.getSheet(this.props.sheetId);
|
|
68452
|
+
this.state.currentPickerColor = sheet.color;
|
|
68438
68453
|
}
|
|
68439
68454
|
});
|
|
68440
68455
|
}
|
|
@@ -72962,11 +72977,11 @@ function addBarChart(chart) {
|
|
|
72962
72977
|
<!-- each data marker in the series does not have a different color -->
|
|
72963
72978
|
<c:varyColors val="0"/>
|
|
72964
72979
|
${joinXmlNodes(rightDataSetsNodes)}
|
|
72965
|
-
<c:axId val="${
|
|
72966
|
-
<c:axId val="${
|
|
72980
|
+
<c:axId val="${17781238}" />
|
|
72981
|
+
<c:axId val="${88853994}" />
|
|
72967
72982
|
</c:barChart>
|
|
72968
|
-
${addAx("b", "c:catAx",
|
|
72969
|
-
${addAx("r", "c:valAx",
|
|
72983
|
+
${addAx("b", "c:catAx", 17781238, 88853994, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
|
|
72984
|
+
${addAx("r", "c:valAx", 88853994, 17781238, chart.axesDesign?.y1?.title, chart.fontColor)}
|
|
72970
72985
|
` : ""}`;
|
|
72971
72986
|
}
|
|
72972
72987
|
function addComboChart(chart) {
|
|
@@ -73124,11 +73139,11 @@ function addLineChart(chart) {
|
|
|
73124
73139
|
<!-- each data marker in the series does not have a different color -->
|
|
73125
73140
|
<c:varyColors val="0"/>
|
|
73126
73141
|
${joinXmlNodes(rightDataSetsNodes)}
|
|
73127
|
-
<c:axId val="${
|
|
73128
|
-
<c:axId val="${
|
|
73142
|
+
<c:axId val="${17781238}" />
|
|
73143
|
+
<c:axId val="${88853994}" />
|
|
73129
73144
|
</c:lineChart>
|
|
73130
|
-
${addAx("b", "c:catAx",
|
|
73131
|
-
${addAx("r", "c:valAx",
|
|
73145
|
+
${addAx("b", "c:catAx", 17781238, 88853994, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
|
|
73146
|
+
${addAx("r", "c:valAx", 88853994, 17781238, chart.axesDesign?.y1?.title, chart.fontColor)}
|
|
73132
73147
|
` : ""}
|
|
73133
73148
|
`;
|
|
73134
73149
|
}
|
|
@@ -73191,11 +73206,11 @@ function addScatterChart(chart) {
|
|
|
73191
73206
|
<c:varyColors val="0"/>
|
|
73192
73207
|
<c:scatterStyle val="lineMarker"/>
|
|
73193
73208
|
${joinXmlNodes(rightDataSetsNodes)}
|
|
73194
|
-
<c:axId val="${
|
|
73195
|
-
<c:axId val="${
|
|
73209
|
+
<c:axId val="${17781238}" />
|
|
73210
|
+
<c:axId val="${88853994}" />
|
|
73196
73211
|
</c:scatterChart>
|
|
73197
|
-
${addAx("b", "c:valAx",
|
|
73198
|
-
${addAx("r", "c:valAx",
|
|
73212
|
+
${addAx("b", "c:valAx", 17781238, 88853994, chart.axesDesign?.x?.title, chart.fontColor, leftDataSetsNodes.length ? 1 : 0)}
|
|
73213
|
+
${addAx("r", "c:valAx", 88853994, 17781238, chart.axesDesign?.y1?.title, chart.fontColor)}
|
|
73199
73214
|
` : ""}`;
|
|
73200
73215
|
}
|
|
73201
73216
|
function addRadarChart(chart) {
|
|
@@ -75364,6 +75379,6 @@ const chartHelpers = {
|
|
|
75364
75379
|
//#endregion
|
|
75365
75380
|
export { AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, CellErrorType, ClientDisconnectedError, CommandResult, CorePlugin, CoreViewPlugin, DispatchResult, EvaluationError, LocalTransportService, 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 };
|
|
75366
75381
|
|
|
75367
|
-
__info__.version = "18.4.
|
|
75368
|
-
__info__.date = "2026-
|
|
75369
|
-
__info__.hash = "
|
|
75382
|
+
__info__.version = "18.4.46";
|
|
75383
|
+
__info__.date = "2026-07-01T05:02:56.676Z";
|
|
75384
|
+
__info__.hash = "26297b3";
|