@odoo/o-spreadsheet 19.4.10 → 19.4.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/o_spreadsheet.cjs +303 -279
- package/dist/o_spreadsheet.css +6 -6
- package/dist/o_spreadsheet.esm.js +303 -279
- package/dist/o_spreadsheet.iife.js +303 -279
- package/dist/o_spreadsheet.min.iife.js +255 -255
- package/dist/o_spreadsheet.xml +6 -6
- package/dist/types/constants.d.ts +1 -0
- package/dist/types/helpers/text_helper.d.ts +4 -0
- package/dist/types/plugins/core/carousel.d.ts +1 -1
- package/package.json +1 -1
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* This file is generated by o-spreadsheet build tools. Do not edit it.
|
|
4
4
|
* @see https://github.com/odoo/o-spreadsheet
|
|
5
|
-
* @version 19.4.
|
|
6
|
-
* @date 2026-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 19.4.11
|
|
6
|
+
* @date 2026-09-04T07:50:39.272Z
|
|
7
|
+
* @hash 7660254
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
(function(exports, _odoo_owl) {
|
|
@@ -447,6 +447,7 @@ _odoo_owl = __toESM(_odoo_owl, 1);
|
|
|
447
447
|
const COMPOSER_ASSISTANT_COLOR = "light-dark(#9B359B, #B972A6)";
|
|
448
448
|
const COLOR_TRANSPARENT = "#00000000";
|
|
449
449
|
const TABLE_HOVER_BACKGROUND_COLOR = "#017E8414";
|
|
450
|
+
const DEFAULT_CHART_BACKGROUND_COLOR = "#FFFFFF";
|
|
450
451
|
const CHART_WATERFALL_POSITIVE_COLOR = "#4EA7F2";
|
|
451
452
|
const CHART_WATERFALL_NEGATIVE_COLOR = "#EA6175";
|
|
452
453
|
const CHART_WATERFALL_SUBTOTAL_COLOR = "#AAAAAA";
|
|
@@ -8994,6 +8995,259 @@ set(value) {
|
|
|
8994
8995
|
}
|
|
8995
8996
|
};
|
|
8996
8997
|
|
|
8998
|
+
//#endregion
|
|
8999
|
+
//#region src/xlsx/constants.ts
|
|
9000
|
+
/** In XLSX color format (no #) */
|
|
9001
|
+
const AUTO_COLOR = "000000";
|
|
9002
|
+
const XLSX_ICONSET_MAP = {
|
|
9003
|
+
arrows: "3Arrows",
|
|
9004
|
+
smiley: "3Symbols",
|
|
9005
|
+
dots: "3TrafficLights1"
|
|
9006
|
+
};
|
|
9007
|
+
const NAMESPACE = {
|
|
9008
|
+
styleSheet: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9009
|
+
sst: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9010
|
+
Relationships: "http://schemas.openxmlformats.org/package/2006/relationships",
|
|
9011
|
+
Types: "http://schemas.openxmlformats.org/package/2006/content-types",
|
|
9012
|
+
worksheet: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9013
|
+
workbook: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9014
|
+
drawing: "http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing",
|
|
9015
|
+
table: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9016
|
+
revision: "http://schemas.microsoft.com/office/spreadsheetml/2014/revision",
|
|
9017
|
+
revision3: "http://schemas.microsoft.com/office/spreadsheetml/2016/revision3",
|
|
9018
|
+
markupCompatibility: "http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
9019
|
+
};
|
|
9020
|
+
const DRAWING_NS_A = "http://schemas.openxmlformats.org/drawingml/2006/main";
|
|
9021
|
+
const DRAWING_NS_C = "http://schemas.openxmlformats.org/drawingml/2006/chart";
|
|
9022
|
+
const CONTENT_TYPES = {
|
|
9023
|
+
workbook: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml",
|
|
9024
|
+
macroEnabledWorkbook: "application/vnd.ms-excel.sheet.macroEnabled.main+xml",
|
|
9025
|
+
templateWorkbook: "application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml",
|
|
9026
|
+
macroEnabledTemplateWorkbook: "application/vnd.ms-excel.template.macroEnabled.main+xml",
|
|
9027
|
+
excelAddInWorkbook: "application/vnd.ms-excel.addin.macroEnabled.main+xml",
|
|
9028
|
+
sheet: "application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml",
|
|
9029
|
+
metadata: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheetMetadata+xml",
|
|
9030
|
+
sharedStrings: "application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml",
|
|
9031
|
+
styles: "application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml",
|
|
9032
|
+
drawing: "application/vnd.openxmlformats-officedocument.drawing+xml",
|
|
9033
|
+
chart: "application/vnd.openxmlformats-officedocument.drawingml.chart+xml",
|
|
9034
|
+
themes: "application/vnd.openxmlformats-officedocument.theme+xml",
|
|
9035
|
+
table: "application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml",
|
|
9036
|
+
pivot: "application/vnd.openxmlformats-officedocument.spreadsheetml.pivotTable+xml",
|
|
9037
|
+
externalLink: "application/vnd.openxmlformats-officedocument.spreadsheetml.externalLink+xml"
|
|
9038
|
+
};
|
|
9039
|
+
const XLSX_RELATION_TYPE = {
|
|
9040
|
+
document: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
|
|
9041
|
+
sheet: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",
|
|
9042
|
+
metadata: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sheetMetadata",
|
|
9043
|
+
sharedStrings: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",
|
|
9044
|
+
styles: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",
|
|
9045
|
+
drawing: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",
|
|
9046
|
+
chart: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart",
|
|
9047
|
+
theme: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",
|
|
9048
|
+
table: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/table",
|
|
9049
|
+
hyperlink: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",
|
|
9050
|
+
image: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image"
|
|
9051
|
+
};
|
|
9052
|
+
const ARRAY_FORMULA_URI = "bdbb8cdc-fa1e-496e-a857-3c3f30c029c3";
|
|
9053
|
+
const RELATIONSHIP_NSR = "http://schemas.openxmlformats.org/officeDocument/2006/relationships";
|
|
9054
|
+
const HEIGHT_FACTOR = .75;
|
|
9055
|
+
/**
|
|
9056
|
+
* Excel says its default column width is 8.43 characters (64px)
|
|
9057
|
+
* which makes WIDTH_FACTOR = 0.1317, but it doesn't work well
|
|
9058
|
+
* 0.143 is a value from dev's experiments.
|
|
9059
|
+
*/
|
|
9060
|
+
const WIDTH_FACTOR = .143;
|
|
9061
|
+
/** unit : maximum number of characters a column can hold at the standard font size. What. */
|
|
9062
|
+
const EXCEL_DEFAULT_COL_WIDTH = 8.43;
|
|
9063
|
+
/** unit : points */
|
|
9064
|
+
const EXCEL_DEFAULT_ROW_HEIGHT = 12.75;
|
|
9065
|
+
const FORCE_DEFAULT_ARGS_FUNCTIONS = {
|
|
9066
|
+
FLOOR: [{
|
|
9067
|
+
type: "NUMBER",
|
|
9068
|
+
value: 1
|
|
9069
|
+
}],
|
|
9070
|
+
CEILING: [{
|
|
9071
|
+
type: "NUMBER",
|
|
9072
|
+
value: 1
|
|
9073
|
+
}],
|
|
9074
|
+
ROUND: [{
|
|
9075
|
+
type: "NUMBER",
|
|
9076
|
+
value: 0
|
|
9077
|
+
}],
|
|
9078
|
+
ROUNDUP: [{
|
|
9079
|
+
type: "NUMBER",
|
|
9080
|
+
value: 0
|
|
9081
|
+
}],
|
|
9082
|
+
ROUNDDOWN: [{
|
|
9083
|
+
type: "NUMBER",
|
|
9084
|
+
value: 0
|
|
9085
|
+
}],
|
|
9086
|
+
IFERROR: [{
|
|
9087
|
+
type: "NUMBER",
|
|
9088
|
+
value: 0
|
|
9089
|
+
}]
|
|
9090
|
+
};
|
|
9091
|
+
/**
|
|
9092
|
+
* This list contains all "future" functions that are not compatible with older versions of Excel
|
|
9093
|
+
* For more information, see https://docs.microsoft.com/en-us/openspecs/office_standards/ms-xlsx/5d1b6d44-6fc1-4ecd-8fef-0b27406cc2bf
|
|
9094
|
+
*/
|
|
9095
|
+
const NON_RETROCOMPATIBLE_FUNCTIONS = [
|
|
9096
|
+
"ACOT",
|
|
9097
|
+
"ACOTH",
|
|
9098
|
+
"AGGREGATE",
|
|
9099
|
+
"ARABIC",
|
|
9100
|
+
"BASE",
|
|
9101
|
+
"BETA.DIST",
|
|
9102
|
+
"BETA.INV",
|
|
9103
|
+
"BINOM.DIST",
|
|
9104
|
+
"BINOM.DIST.RANGE",
|
|
9105
|
+
"BINOM.INV",
|
|
9106
|
+
"BITAND",
|
|
9107
|
+
"BITLSHIFT",
|
|
9108
|
+
"BITOR",
|
|
9109
|
+
"BITRSHIFT",
|
|
9110
|
+
"BITXOR",
|
|
9111
|
+
"BYCOL",
|
|
9112
|
+
"BYROW",
|
|
9113
|
+
"CEILING.MATH",
|
|
9114
|
+
"CEILING.PRECISE",
|
|
9115
|
+
"CHISQ.DIST",
|
|
9116
|
+
"CHISQ.DIST.RT",
|
|
9117
|
+
"CHISQ.INV",
|
|
9118
|
+
"CHISQ.INV.RT",
|
|
9119
|
+
"CHISQ.TEST",
|
|
9120
|
+
"CHOOSECOLS",
|
|
9121
|
+
"CHOOSEROWS",
|
|
9122
|
+
"COMBINA",
|
|
9123
|
+
"CONCAT",
|
|
9124
|
+
"CONFIDENCE.NORM",
|
|
9125
|
+
"CONFIDENCE.T",
|
|
9126
|
+
"COT",
|
|
9127
|
+
"COTH",
|
|
9128
|
+
"COVARIANCE.P",
|
|
9129
|
+
"COVARIANCE.S",
|
|
9130
|
+
"CSC",
|
|
9131
|
+
"CSCH",
|
|
9132
|
+
"DAYS",
|
|
9133
|
+
"DECIMAL",
|
|
9134
|
+
"DROP",
|
|
9135
|
+
"ERF.PRECISE",
|
|
9136
|
+
"ERFC.PRECISE",
|
|
9137
|
+
"EXPAND",
|
|
9138
|
+
"EXPON.DIST",
|
|
9139
|
+
"F.DIST",
|
|
9140
|
+
"F.DIST.RT",
|
|
9141
|
+
"F.INV",
|
|
9142
|
+
"F.INV.RT",
|
|
9143
|
+
"F.TEST",
|
|
9144
|
+
"FIELDVALUE",
|
|
9145
|
+
"FILTERXML",
|
|
9146
|
+
"FLOOR.MATH",
|
|
9147
|
+
"FLOOR.PRECISE",
|
|
9148
|
+
"FORECAST.ETS",
|
|
9149
|
+
"FORECAST.ETS.CONFINT",
|
|
9150
|
+
"FORECAST.ETS.SEASONALITY",
|
|
9151
|
+
"FORECAST.ETS.STAT",
|
|
9152
|
+
"FORECAST.LINEAR",
|
|
9153
|
+
"FORMULATEXT",
|
|
9154
|
+
"GAMMA",
|
|
9155
|
+
"GAMMA.DIST",
|
|
9156
|
+
"GAMMA.INV",
|
|
9157
|
+
"GAMMALN.PRECISE",
|
|
9158
|
+
"GAUSS",
|
|
9159
|
+
"HSTACK",
|
|
9160
|
+
"HYPGEOM.DIST",
|
|
9161
|
+
"IFNA",
|
|
9162
|
+
"IFS",
|
|
9163
|
+
"IMCOSH",
|
|
9164
|
+
"IMCOT",
|
|
9165
|
+
"IMCSC",
|
|
9166
|
+
"IMCSCH",
|
|
9167
|
+
"IMSEC",
|
|
9168
|
+
"IMSECH",
|
|
9169
|
+
"IMSINH",
|
|
9170
|
+
"IMTAN",
|
|
9171
|
+
"ISFORMULA",
|
|
9172
|
+
"ISOMITTED",
|
|
9173
|
+
"ISOWEEKNUM",
|
|
9174
|
+
"LAMBDA",
|
|
9175
|
+
"LET",
|
|
9176
|
+
"LOGNORM.DIST",
|
|
9177
|
+
"LOGNORM.INV",
|
|
9178
|
+
"MAKEARRAY",
|
|
9179
|
+
"MAP",
|
|
9180
|
+
"MAXIFS",
|
|
9181
|
+
"MINIFS",
|
|
9182
|
+
"MODE.MULT",
|
|
9183
|
+
"MODE.SNGL",
|
|
9184
|
+
"MUNIT",
|
|
9185
|
+
"NEGBINOM.DIST",
|
|
9186
|
+
"NORM.DIST",
|
|
9187
|
+
"NORM.INV",
|
|
9188
|
+
"NORM.S.DIST",
|
|
9189
|
+
"NORM.S.INV",
|
|
9190
|
+
"NUMBERVALUE",
|
|
9191
|
+
"PDURATION",
|
|
9192
|
+
"PERCENTILE.EXC",
|
|
9193
|
+
"PERCENTILE.INC",
|
|
9194
|
+
"PERCENTRANK.EXC",
|
|
9195
|
+
"PERCENTRANK.INC",
|
|
9196
|
+
"PERMUTATIONA",
|
|
9197
|
+
"PHI",
|
|
9198
|
+
"POISSON.DIST",
|
|
9199
|
+
"PQSOURCE",
|
|
9200
|
+
"PYTHON_STR",
|
|
9201
|
+
"PYTHON_TYPE",
|
|
9202
|
+
"PYTHON_TYPENAME",
|
|
9203
|
+
"QUARTILE.EXC",
|
|
9204
|
+
"QUARTILE.INC",
|
|
9205
|
+
"QUERYSTRING",
|
|
9206
|
+
"RANDARRAY",
|
|
9207
|
+
"RANK.AVG",
|
|
9208
|
+
"RANK.EQ",
|
|
9209
|
+
"REDUCE",
|
|
9210
|
+
"RRI",
|
|
9211
|
+
"SCAN",
|
|
9212
|
+
"SEC",
|
|
9213
|
+
"SECH",
|
|
9214
|
+
"SEQUENCE",
|
|
9215
|
+
"SHEET",
|
|
9216
|
+
"SHEETS",
|
|
9217
|
+
"SKEW.P",
|
|
9218
|
+
"SORTBY",
|
|
9219
|
+
"STDEV.P",
|
|
9220
|
+
"STDEV.S",
|
|
9221
|
+
"SWITCH",
|
|
9222
|
+
"T.DIST",
|
|
9223
|
+
"T.DIST.2T",
|
|
9224
|
+
"T.DIST.RT",
|
|
9225
|
+
"T.INV",
|
|
9226
|
+
"T.INV.2T",
|
|
9227
|
+
"T.TEST",
|
|
9228
|
+
"TAKE",
|
|
9229
|
+
"TEXTAFTER",
|
|
9230
|
+
"TEXTBEFORE",
|
|
9231
|
+
"TEXTJOIN",
|
|
9232
|
+
"TEXTSPLIT",
|
|
9233
|
+
"TOCOL",
|
|
9234
|
+
"TOROW",
|
|
9235
|
+
"UNICHAR",
|
|
9236
|
+
"UNICODE",
|
|
9237
|
+
"UNIQUE",
|
|
9238
|
+
"VAR.P",
|
|
9239
|
+
"VAR.S",
|
|
9240
|
+
"VSTACK",
|
|
9241
|
+
"WEBSERVICE",
|
|
9242
|
+
"WEIBULL.DIST",
|
|
9243
|
+
"WRAPCOLS",
|
|
9244
|
+
"WRAPROWS",
|
|
9245
|
+
"XLOOKUP",
|
|
9246
|
+
"XOR",
|
|
9247
|
+
"Z.TEST"
|
|
9248
|
+
];
|
|
9249
|
+
const CONTENT_TYPES_FILE = "[Content_Types].xml";
|
|
9250
|
+
|
|
8997
9251
|
//#endregion
|
|
8998
9252
|
//#region src/helpers/color.ts
|
|
8999
9253
|
const RBA_REGEX = /rgba?\(|\s+|\)/gi;
|
|
@@ -9695,259 +9949,6 @@ set(value) {
|
|
|
9695
9949
|
return r << 16 | g << 8 | b;
|
|
9696
9950
|
}
|
|
9697
9951
|
|
|
9698
|
-
//#endregion
|
|
9699
|
-
//#region src/xlsx/constants.ts
|
|
9700
|
-
/** In XLSX color format (no #) */
|
|
9701
|
-
const AUTO_COLOR = "000000";
|
|
9702
|
-
const XLSX_ICONSET_MAP = {
|
|
9703
|
-
arrows: "3Arrows",
|
|
9704
|
-
smiley: "3Symbols",
|
|
9705
|
-
dots: "3TrafficLights1"
|
|
9706
|
-
};
|
|
9707
|
-
const NAMESPACE = {
|
|
9708
|
-
styleSheet: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9709
|
-
sst: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9710
|
-
Relationships: "http://schemas.openxmlformats.org/package/2006/relationships",
|
|
9711
|
-
Types: "http://schemas.openxmlformats.org/package/2006/content-types",
|
|
9712
|
-
worksheet: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9713
|
-
workbook: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9714
|
-
drawing: "http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing",
|
|
9715
|
-
table: "http://schemas.openxmlformats.org/spreadsheetml/2006/main",
|
|
9716
|
-
revision: "http://schemas.microsoft.com/office/spreadsheetml/2014/revision",
|
|
9717
|
-
revision3: "http://schemas.microsoft.com/office/spreadsheetml/2016/revision3",
|
|
9718
|
-
markupCompatibility: "http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
9719
|
-
};
|
|
9720
|
-
const DRAWING_NS_A = "http://schemas.openxmlformats.org/drawingml/2006/main";
|
|
9721
|
-
const DRAWING_NS_C = "http://schemas.openxmlformats.org/drawingml/2006/chart";
|
|
9722
|
-
const CONTENT_TYPES = {
|
|
9723
|
-
workbook: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml",
|
|
9724
|
-
macroEnabledWorkbook: "application/vnd.ms-excel.sheet.macroEnabled.main+xml",
|
|
9725
|
-
templateWorkbook: "application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml",
|
|
9726
|
-
macroEnabledTemplateWorkbook: "application/vnd.ms-excel.template.macroEnabled.main+xml",
|
|
9727
|
-
excelAddInWorkbook: "application/vnd.ms-excel.addin.macroEnabled.main+xml",
|
|
9728
|
-
sheet: "application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml",
|
|
9729
|
-
metadata: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheetMetadata+xml",
|
|
9730
|
-
sharedStrings: "application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml",
|
|
9731
|
-
styles: "application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml",
|
|
9732
|
-
drawing: "application/vnd.openxmlformats-officedocument.drawing+xml",
|
|
9733
|
-
chart: "application/vnd.openxmlformats-officedocument.drawingml.chart+xml",
|
|
9734
|
-
themes: "application/vnd.openxmlformats-officedocument.theme+xml",
|
|
9735
|
-
table: "application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml",
|
|
9736
|
-
pivot: "application/vnd.openxmlformats-officedocument.spreadsheetml.pivotTable+xml",
|
|
9737
|
-
externalLink: "application/vnd.openxmlformats-officedocument.spreadsheetml.externalLink+xml"
|
|
9738
|
-
};
|
|
9739
|
-
const XLSX_RELATION_TYPE = {
|
|
9740
|
-
document: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",
|
|
9741
|
-
sheet: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",
|
|
9742
|
-
metadata: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sheetMetadata",
|
|
9743
|
-
sharedStrings: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",
|
|
9744
|
-
styles: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",
|
|
9745
|
-
drawing: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",
|
|
9746
|
-
chart: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/chart",
|
|
9747
|
-
theme: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",
|
|
9748
|
-
table: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/table",
|
|
9749
|
-
hyperlink: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",
|
|
9750
|
-
image: "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image"
|
|
9751
|
-
};
|
|
9752
|
-
const ARRAY_FORMULA_URI = "bdbb8cdc-fa1e-496e-a857-3c3f30c029c3";
|
|
9753
|
-
const RELATIONSHIP_NSR = "http://schemas.openxmlformats.org/officeDocument/2006/relationships";
|
|
9754
|
-
const HEIGHT_FACTOR = .75;
|
|
9755
|
-
/**
|
|
9756
|
-
* Excel says its default column width is 8.43 characters (64px)
|
|
9757
|
-
* which makes WIDTH_FACTOR = 0.1317, but it doesn't work well
|
|
9758
|
-
* 0.143 is a value from dev's experiments.
|
|
9759
|
-
*/
|
|
9760
|
-
const WIDTH_FACTOR = .143;
|
|
9761
|
-
/** unit : maximum number of characters a column can hold at the standard font size. What. */
|
|
9762
|
-
const EXCEL_DEFAULT_COL_WIDTH = 8.43;
|
|
9763
|
-
/** unit : points */
|
|
9764
|
-
const EXCEL_DEFAULT_ROW_HEIGHT = 12.75;
|
|
9765
|
-
const FORCE_DEFAULT_ARGS_FUNCTIONS = {
|
|
9766
|
-
FLOOR: [{
|
|
9767
|
-
type: "NUMBER",
|
|
9768
|
-
value: 1
|
|
9769
|
-
}],
|
|
9770
|
-
CEILING: [{
|
|
9771
|
-
type: "NUMBER",
|
|
9772
|
-
value: 1
|
|
9773
|
-
}],
|
|
9774
|
-
ROUND: [{
|
|
9775
|
-
type: "NUMBER",
|
|
9776
|
-
value: 0
|
|
9777
|
-
}],
|
|
9778
|
-
ROUNDUP: [{
|
|
9779
|
-
type: "NUMBER",
|
|
9780
|
-
value: 0
|
|
9781
|
-
}],
|
|
9782
|
-
ROUNDDOWN: [{
|
|
9783
|
-
type: "NUMBER",
|
|
9784
|
-
value: 0
|
|
9785
|
-
}],
|
|
9786
|
-
IFERROR: [{
|
|
9787
|
-
type: "NUMBER",
|
|
9788
|
-
value: 0
|
|
9789
|
-
}]
|
|
9790
|
-
};
|
|
9791
|
-
/**
|
|
9792
|
-
* This list contains all "future" functions that are not compatible with older versions of Excel
|
|
9793
|
-
* For more information, see https://docs.microsoft.com/en-us/openspecs/office_standards/ms-xlsx/5d1b6d44-6fc1-4ecd-8fef-0b27406cc2bf
|
|
9794
|
-
*/
|
|
9795
|
-
const NON_RETROCOMPATIBLE_FUNCTIONS = [
|
|
9796
|
-
"ACOT",
|
|
9797
|
-
"ACOTH",
|
|
9798
|
-
"AGGREGATE",
|
|
9799
|
-
"ARABIC",
|
|
9800
|
-
"BASE",
|
|
9801
|
-
"BETA.DIST",
|
|
9802
|
-
"BETA.INV",
|
|
9803
|
-
"BINOM.DIST",
|
|
9804
|
-
"BINOM.DIST.RANGE",
|
|
9805
|
-
"BINOM.INV",
|
|
9806
|
-
"BITAND",
|
|
9807
|
-
"BITLSHIFT",
|
|
9808
|
-
"BITOR",
|
|
9809
|
-
"BITRSHIFT",
|
|
9810
|
-
"BITXOR",
|
|
9811
|
-
"BYCOL",
|
|
9812
|
-
"BYROW",
|
|
9813
|
-
"CEILING.MATH",
|
|
9814
|
-
"CEILING.PRECISE",
|
|
9815
|
-
"CHISQ.DIST",
|
|
9816
|
-
"CHISQ.DIST.RT",
|
|
9817
|
-
"CHISQ.INV",
|
|
9818
|
-
"CHISQ.INV.RT",
|
|
9819
|
-
"CHISQ.TEST",
|
|
9820
|
-
"CHOOSECOLS",
|
|
9821
|
-
"CHOOSEROWS",
|
|
9822
|
-
"COMBINA",
|
|
9823
|
-
"CONCAT",
|
|
9824
|
-
"CONFIDENCE.NORM",
|
|
9825
|
-
"CONFIDENCE.T",
|
|
9826
|
-
"COT",
|
|
9827
|
-
"COTH",
|
|
9828
|
-
"COVARIANCE.P",
|
|
9829
|
-
"COVARIANCE.S",
|
|
9830
|
-
"CSC",
|
|
9831
|
-
"CSCH",
|
|
9832
|
-
"DAYS",
|
|
9833
|
-
"DECIMAL",
|
|
9834
|
-
"DROP",
|
|
9835
|
-
"ERF.PRECISE",
|
|
9836
|
-
"ERFC.PRECISE",
|
|
9837
|
-
"EXPAND",
|
|
9838
|
-
"EXPON.DIST",
|
|
9839
|
-
"F.DIST",
|
|
9840
|
-
"F.DIST.RT",
|
|
9841
|
-
"F.INV",
|
|
9842
|
-
"F.INV.RT",
|
|
9843
|
-
"F.TEST",
|
|
9844
|
-
"FIELDVALUE",
|
|
9845
|
-
"FILTERXML",
|
|
9846
|
-
"FLOOR.MATH",
|
|
9847
|
-
"FLOOR.PRECISE",
|
|
9848
|
-
"FORECAST.ETS",
|
|
9849
|
-
"FORECAST.ETS.CONFINT",
|
|
9850
|
-
"FORECAST.ETS.SEASONALITY",
|
|
9851
|
-
"FORECAST.ETS.STAT",
|
|
9852
|
-
"FORECAST.LINEAR",
|
|
9853
|
-
"FORMULATEXT",
|
|
9854
|
-
"GAMMA",
|
|
9855
|
-
"GAMMA.DIST",
|
|
9856
|
-
"GAMMA.INV",
|
|
9857
|
-
"GAMMALN.PRECISE",
|
|
9858
|
-
"GAUSS",
|
|
9859
|
-
"HSTACK",
|
|
9860
|
-
"HYPGEOM.DIST",
|
|
9861
|
-
"IFNA",
|
|
9862
|
-
"IFS",
|
|
9863
|
-
"IMCOSH",
|
|
9864
|
-
"IMCOT",
|
|
9865
|
-
"IMCSC",
|
|
9866
|
-
"IMCSCH",
|
|
9867
|
-
"IMSEC",
|
|
9868
|
-
"IMSECH",
|
|
9869
|
-
"IMSINH",
|
|
9870
|
-
"IMTAN",
|
|
9871
|
-
"ISFORMULA",
|
|
9872
|
-
"ISOMITTED",
|
|
9873
|
-
"ISOWEEKNUM",
|
|
9874
|
-
"LAMBDA",
|
|
9875
|
-
"LET",
|
|
9876
|
-
"LOGNORM.DIST",
|
|
9877
|
-
"LOGNORM.INV",
|
|
9878
|
-
"MAKEARRAY",
|
|
9879
|
-
"MAP",
|
|
9880
|
-
"MAXIFS",
|
|
9881
|
-
"MINIFS",
|
|
9882
|
-
"MODE.MULT",
|
|
9883
|
-
"MODE.SNGL",
|
|
9884
|
-
"MUNIT",
|
|
9885
|
-
"NEGBINOM.DIST",
|
|
9886
|
-
"NORM.DIST",
|
|
9887
|
-
"NORM.INV",
|
|
9888
|
-
"NORM.S.DIST",
|
|
9889
|
-
"NORM.S.INV",
|
|
9890
|
-
"NUMBERVALUE",
|
|
9891
|
-
"PDURATION",
|
|
9892
|
-
"PERCENTILE.EXC",
|
|
9893
|
-
"PERCENTILE.INC",
|
|
9894
|
-
"PERCENTRANK.EXC",
|
|
9895
|
-
"PERCENTRANK.INC",
|
|
9896
|
-
"PERMUTATIONA",
|
|
9897
|
-
"PHI",
|
|
9898
|
-
"POISSON.DIST",
|
|
9899
|
-
"PQSOURCE",
|
|
9900
|
-
"PYTHON_STR",
|
|
9901
|
-
"PYTHON_TYPE",
|
|
9902
|
-
"PYTHON_TYPENAME",
|
|
9903
|
-
"QUARTILE.EXC",
|
|
9904
|
-
"QUARTILE.INC",
|
|
9905
|
-
"QUERYSTRING",
|
|
9906
|
-
"RANDARRAY",
|
|
9907
|
-
"RANK.AVG",
|
|
9908
|
-
"RANK.EQ",
|
|
9909
|
-
"REDUCE",
|
|
9910
|
-
"RRI",
|
|
9911
|
-
"SCAN",
|
|
9912
|
-
"SEC",
|
|
9913
|
-
"SECH",
|
|
9914
|
-
"SEQUENCE",
|
|
9915
|
-
"SHEET",
|
|
9916
|
-
"SHEETS",
|
|
9917
|
-
"SKEW.P",
|
|
9918
|
-
"SORTBY",
|
|
9919
|
-
"STDEV.P",
|
|
9920
|
-
"STDEV.S",
|
|
9921
|
-
"SWITCH",
|
|
9922
|
-
"T.DIST",
|
|
9923
|
-
"T.DIST.2T",
|
|
9924
|
-
"T.DIST.RT",
|
|
9925
|
-
"T.INV",
|
|
9926
|
-
"T.INV.2T",
|
|
9927
|
-
"T.TEST",
|
|
9928
|
-
"TAKE",
|
|
9929
|
-
"TEXTAFTER",
|
|
9930
|
-
"TEXTBEFORE",
|
|
9931
|
-
"TEXTJOIN",
|
|
9932
|
-
"TEXTSPLIT",
|
|
9933
|
-
"TOCOL",
|
|
9934
|
-
"TOROW",
|
|
9935
|
-
"UNICHAR",
|
|
9936
|
-
"UNICODE",
|
|
9937
|
-
"UNIQUE",
|
|
9938
|
-
"VAR.P",
|
|
9939
|
-
"VAR.S",
|
|
9940
|
-
"VSTACK",
|
|
9941
|
-
"WEBSERVICE",
|
|
9942
|
-
"WEIBULL.DIST",
|
|
9943
|
-
"WRAPCOLS",
|
|
9944
|
-
"WRAPROWS",
|
|
9945
|
-
"XLOOKUP",
|
|
9946
|
-
"XOR",
|
|
9947
|
-
"Z.TEST"
|
|
9948
|
-
];
|
|
9949
|
-
const CONTENT_TYPES_FILE = "[Content_Types].xml";
|
|
9950
|
-
|
|
9951
9952
|
//#endregion
|
|
9952
9953
|
//#region src/helpers/figures/charts/chart_common.ts
|
|
9953
9954
|
const TREND_LINE_XAXIS_ID = "x1";
|
|
@@ -10213,10 +10214,10 @@ set(value) {
|
|
|
10213
10214
|
drawLineOrBarOrRadarChartValues(chart, options, ctx);
|
|
10214
10215
|
break;
|
|
10215
10216
|
case "bar":
|
|
10216
|
-
options.horizontal ? drawHorizontalBarChartValues(chart, options, ctx) : drawLineOrBarOrRadarChartValues(chart, options, ctx);
|
|
10217
|
+
options.horizontal ? drawHorizontalBarChartValues(chart, options, ctx, { offsetFromAxisOrigin: true }) : drawLineOrBarOrRadarChartValues(chart, options, ctx);
|
|
10217
10218
|
break;
|
|
10218
10219
|
case "pyramid":
|
|
10219
|
-
drawHorizontalBarChartValues(chart, options, ctx);
|
|
10220
|
+
drawHorizontalBarChartValues(chart, options, ctx, { offsetFromAxisOrigin: true });
|
|
10220
10221
|
break;
|
|
10221
10222
|
case "calendar":
|
|
10222
10223
|
drawBarChartValues(chart, options, ctx);
|
|
@@ -10225,7 +10226,7 @@ set(value) {
|
|
|
10225
10226
|
drawBubbleChartValues(chart, options, ctx);
|
|
10226
10227
|
break;
|
|
10227
10228
|
case "funnel":
|
|
10228
|
-
drawHorizontalBarChartValues(chart, options, ctx);
|
|
10229
|
+
drawHorizontalBarChartValues(chart, options, ctx, { offsetFromAxisOrigin: false });
|
|
10229
10230
|
break;
|
|
10230
10231
|
}
|
|
10231
10232
|
ctx.restore();
|
|
@@ -10300,23 +10301,33 @@ set(value) {
|
|
|
10300
10301
|
const yMax = chart.chartArea.bottom;
|
|
10301
10302
|
const yMin = chart.chartArea.top;
|
|
10302
10303
|
const textsPositions = {};
|
|
10304
|
+
const canDrawTextInsideBubble = (chartElement, textSize) => {
|
|
10305
|
+
const radius = chartElement.options.radius ?? globalThis.Chart?.defaults.elements.point.radius ?? 3;
|
|
10306
|
+
return textSize.height < radius * 2;
|
|
10307
|
+
};
|
|
10303
10308
|
for (const dataset of chart._metasets) for (let i = 0; i < dataset._parsed.length; i++) {
|
|
10304
10309
|
const value = dataset._parsed[i].y;
|
|
10305
10310
|
if (isNaN(value)) continue;
|
|
10311
|
+
const valueToDisplay = options.callback(Number(value), dataset, i);
|
|
10306
10312
|
const point = dataset.data[i];
|
|
10307
10313
|
const xPosition = point.x;
|
|
10308
10314
|
let yPosition = Math.max(Math.min(point.y, yMax), yMin);
|
|
10315
|
+
const textSize = getTextDimensions(valueToDisplay, ctx);
|
|
10316
|
+
if (!canDrawTextInsideBubble(point, textSize)) yPosition = value < 0 ? point.y + 10 : point.y - 10;
|
|
10309
10317
|
if (!textsPositions[xPosition]) textsPositions[xPosition] = [];
|
|
10310
10318
|
for (const otherPosition of textsPositions[xPosition] || []) if (Math.abs(otherPosition - yPosition) < MINIMAL_VERTICAL_DISTANCE) yPosition = otherPosition + MINIMAL_VERTICAL_DISTANCE * (value < 0 ? 1 : -1);
|
|
10311
10319
|
textsPositions[xPosition].push(yPosition);
|
|
10312
|
-
|
|
10313
|
-
|
|
10314
|
-
|
|
10315
|
-
|
|
10316
|
-
|
|
10320
|
+
if (canDrawTextInsideBubble(point, textSize)) {
|
|
10321
|
+
ctx.strokeStyle = point.options.backgroundColor;
|
|
10322
|
+
ctx.fillStyle = options.background(Number(value), dataset, i) || "#ffffff";
|
|
10323
|
+
} else {
|
|
10324
|
+
ctx.strokeStyle = options.background(Number(value), dataset, i) || "#ffffff";
|
|
10325
|
+
ctx.fillStyle = point.options.backgroundColor;
|
|
10326
|
+
}
|
|
10327
|
+
drawTextWithBackground(valueToDisplay, xPosition, yPosition, ctx);
|
|
10317
10328
|
}
|
|
10318
10329
|
}
|
|
10319
|
-
function drawHorizontalBarChartValues(chart, options, ctx) {
|
|
10330
|
+
function drawHorizontalBarChartValues(chart, options, ctx, args) {
|
|
10320
10331
|
const textsPositions = {};
|
|
10321
10332
|
for (const dataset of chart._metasets) {
|
|
10322
10333
|
if (isTrendLineAxis(dataset.xAxisID) || isLineOverlayOnBarChart(options, dataset)) continue;
|
|
@@ -10331,7 +10342,7 @@ set(value) {
|
|
|
10331
10342
|
const distanceFromAxisOrigin = Math.abs(point.x - xZeroLine);
|
|
10332
10343
|
const PADDING = 3;
|
|
10333
10344
|
let xPosition;
|
|
10334
|
-
if (distanceFromAxisOrigin < textWidth) xPosition = value < 0 ? xZeroLine - textWidth / 2 - PADDING : xZeroLine + textWidth / 2 + PADDING;
|
|
10345
|
+
if (args.offsetFromAxisOrigin && distanceFromAxisOrigin < textWidth) xPosition = value < 0 ? xZeroLine - textWidth / 2 - PADDING : xZeroLine + textWidth / 2 + PADDING;
|
|
10335
10346
|
else xPosition = value < 0 ? point.x + point.width / 2 : point.x - point.width / 2;
|
|
10336
10347
|
if (!textsPositions[yPosition]) textsPositions[yPosition] = [];
|
|
10337
10348
|
for (const otherPosition of textsPositions[yPosition]) if (Math.abs(otherPosition - xPosition) < textWidth) xPosition = value < 0 ? otherPosition - textWidth - PADDING : otherPosition + textWidth + PADDING;
|
|
@@ -10366,6 +10377,9 @@ set(value) {
|
|
|
10366
10377
|
drawTextWithBackground(displayValue, x, y, ctx);
|
|
10367
10378
|
}
|
|
10368
10379
|
}
|
|
10380
|
+
function getTextDimensions(text, ctx) {
|
|
10381
|
+
return computeCachedTextDimension(ctx, text, computeTextFont({ fontSize: globalThis.Chart?.defaults.font.size ?? 12 }, "px"));
|
|
10382
|
+
}
|
|
10369
10383
|
|
|
10370
10384
|
//#endregion
|
|
10371
10385
|
//#region src/types/chart/tree_map_chart.ts
|
|
@@ -31292,9 +31306,10 @@ set(value) {
|
|
|
31292
31306
|
compositionActive = false;
|
|
31293
31307
|
spreadsheetRect = useSpreadsheetRect();
|
|
31294
31308
|
lastHoveredTokenIndex = void 0;
|
|
31295
|
-
debouncedHover = debounce((tokenIndex, hoveredRect) => {
|
|
31309
|
+
debouncedHover = debounce((tokenIndex, composerContent, hoveredRect) => {
|
|
31296
31310
|
const selection = this.contentHelper.getCurrentSelection();
|
|
31297
|
-
|
|
31311
|
+
const currentContent = this.props.composerStore.currentContent;
|
|
31312
|
+
if (selection.start !== selection.end || currentContent !== composerContent) return;
|
|
31298
31313
|
const currentHoveredContext = this.props.composerStore.hoveredTokens;
|
|
31299
31314
|
this.props.composerStore.hoverToken(tokenIndex);
|
|
31300
31315
|
if (!deepEquals(currentHoveredContext, this.props.composerStore.hoveredTokens)) this.composerState.hoveredRect = hoveredRect;
|
|
@@ -31614,7 +31629,8 @@ set(value) {
|
|
|
31614
31629
|
onTokenHover(tokenIndex, hoveredRect) {
|
|
31615
31630
|
if (this.lastHoveredTokenIndex !== tokenIndex) {
|
|
31616
31631
|
this.lastHoveredTokenIndex = tokenIndex;
|
|
31617
|
-
this.
|
|
31632
|
+
const composerContent = this.props.composerStore.currentContent;
|
|
31633
|
+
this.debouncedHover(tokenIndex, composerContent, hoveredRect);
|
|
31618
31634
|
}
|
|
31619
31635
|
}
|
|
31620
31636
|
/**
|
|
@@ -41270,7 +41286,13 @@ set(value) {
|
|
|
41270
41286
|
}
|
|
41271
41287
|
onSelectionChanged(ranges) {
|
|
41272
41288
|
this.state.rangeHasChanged = true;
|
|
41273
|
-
|
|
41289
|
+
if (ranges.length === 0) {
|
|
41290
|
+
this.state.range = void 0;
|
|
41291
|
+
return;
|
|
41292
|
+
}
|
|
41293
|
+
const sheetId = this.env.model.getters.getActiveSheetId();
|
|
41294
|
+
const range = this.env.model.getters.getRangeFromSheetXC(sheetId, ranges[0]);
|
|
41295
|
+
this.state.range = this.env.model.getters.getRangeString(range, "forceSheetReference", { useBoundedReference: true });
|
|
41274
41296
|
}
|
|
41275
41297
|
onSelectionConfirmed() {
|
|
41276
41298
|
if (this.state.range) {
|
|
@@ -51029,6 +51051,7 @@ set(value) {
|
|
|
51029
51051
|
return "Success";
|
|
51030
51052
|
case "UPDATE_CAROUSEL":
|
|
51031
51053
|
if (!this.carousels[cmd.sheetId]?.[cmd.figureId]) return "InvalidFigureId";
|
|
51054
|
+
for (const item of cmd.definition.items) if (item.type === "chart" && !this.getters.getChart(item.chartId)) return "ChartDoesNotExist";
|
|
51032
51055
|
return "Success";
|
|
51033
51056
|
}
|
|
51034
51057
|
return "Success";
|
|
@@ -56556,6 +56579,7 @@ set(value) {
|
|
|
56556
56579
|
}
|
|
56557
56580
|
getCellsDependingOn(ranges, visited = new RangeSet()) {
|
|
56558
56581
|
visited = visited.copy();
|
|
56582
|
+
let initialRangesToRemove = visited.copy();
|
|
56559
56583
|
const queue = Array.from(ranges).reverse();
|
|
56560
56584
|
while (queue.length > 0) {
|
|
56561
56585
|
const range = queue.pop();
|
|
@@ -56571,8 +56595,9 @@ set(value) {
|
|
|
56571
56595
|
for (const interval of overlappingIntervals) impactedRanges.add(interval.dependents);
|
|
56572
56596
|
}
|
|
56573
56597
|
queue.push(...impactedRanges.difference(visited));
|
|
56598
|
+
initialRangesToRemove = initialRangesToRemove.difference(impactedRanges);
|
|
56574
56599
|
}
|
|
56575
|
-
for (const range of
|
|
56600
|
+
for (const range of initialRangesToRemove) visited.delete(range);
|
|
56576
56601
|
return visited;
|
|
56577
56602
|
}
|
|
56578
56603
|
getOrCreateIntervalTree(sheetId, col) {
|
|
@@ -70248,7 +70273,7 @@ set(value) {
|
|
|
70248
70273
|
if (!this.getters.isDashboard()) {
|
|
70249
70274
|
ctx.strokeStyle = GRAY_400;
|
|
70250
70275
|
ctx.lineWidth = 1;
|
|
70251
|
-
ctx.strokeRect(x, y, figure.width, figure.height);
|
|
70276
|
+
ctx.strokeRect(x + .5, y + .5, figure.width - 1, figure.height - 1);
|
|
70252
70277
|
}
|
|
70253
70278
|
}
|
|
70254
70279
|
}
|
|
@@ -79128,14 +79153,13 @@ set(value) {
|
|
|
79128
79153
|
},
|
|
79129
79154
|
getDefinitionForExcel(getters, definition, { dataSets, labelRange }) {
|
|
79130
79155
|
if (definition.dataSource.type !== "range") return;
|
|
79131
|
-
const
|
|
79132
|
-
const { dataSetsValues } = chartData;
|
|
79156
|
+
const { dataSetsValues } = getPyramidChartData(definition, getChartData(getters, definition.dataSource), getters);
|
|
79133
79157
|
const maxValue = Math.max(...dataSetsValues.map((dataSet) => Math.max(...dataSet.data.map((cell) => isNumberResult(cell) ? Math.abs(cell.value) : -Infinity))));
|
|
79134
79158
|
return {
|
|
79135
79159
|
...definition,
|
|
79136
79160
|
horizontal: true,
|
|
79137
|
-
backgroundColor: toXlsxHexColor(
|
|
79138
|
-
fontColor: toXlsxHexColor(chartFontColor(
|
|
79161
|
+
backgroundColor: toXlsxHexColor(definition.background || "#FFFFFF"),
|
|
79162
|
+
fontColor: toXlsxHexColor(chartFontColor(definition.background)),
|
|
79139
79163
|
dataSets,
|
|
79140
79164
|
labelRange,
|
|
79141
79165
|
verticalAxis: getDefinedAxis(definition),
|
|
@@ -87790,8 +87814,8 @@ exports.stores = stores;
|
|
|
87790
87814
|
exports.tokenColors = tokenColors;
|
|
87791
87815
|
exports.tokenize = tokenize;
|
|
87792
87816
|
|
|
87793
|
-
__info__.version = "19.4.
|
|
87794
|
-
__info__.date = "2026-
|
|
87795
|
-
__info__.hash = "
|
|
87817
|
+
__info__.version = "19.4.11";
|
|
87818
|
+
__info__.date = "2026-09-04T07:50:39.272Z";
|
|
87819
|
+
__info__.hash = "7660254";
|
|
87796
87820
|
|
|
87797
87821
|
})(this.o_spreadsheet = this.o_spreadsheet || {}, owl);
|