@odoo/o-spreadsheet 15.0.26 → 15.0.28
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.
|
@@ -7457,7 +7457,7 @@ function parseExpression(tokens, bp) {
|
|
|
7457
7457
|
*/
|
|
7458
7458
|
function parse(str) {
|
|
7459
7459
|
const tokens = tokenize(str).filter((x) => x.type !== "SPACE");
|
|
7460
|
-
if (tokens[0].type === "OPERATOR" && tokens[0].value === "=") {
|
|
7460
|
+
if (tokens[0] && tokens[0].type === "OPERATOR" && tokens[0].value === "=") {
|
|
7461
7461
|
tokens.splice(0, 1);
|
|
7462
7462
|
}
|
|
7463
7463
|
const result = parseExpression(tokens, 0);
|
|
@@ -24926,35 +24926,27 @@ function addFormula(cell) {
|
|
|
24926
24926
|
const isExported = tokens
|
|
24927
24927
|
.filter((tk) => tk.type === "FUNCTION")
|
|
24928
24928
|
.every((tk) => functions[tk.value.toUpperCase()].isExported);
|
|
24929
|
+
const type = getCellType(cell.value);
|
|
24929
24930
|
if (isExported) {
|
|
24930
|
-
let cycle = escapeXml ``;
|
|
24931
24931
|
const XlsxFormula = adaptFormulaToExcel(formula);
|
|
24932
|
-
// hack for cycles : if we don't set a value (be it 0 or #VALUE!), it will appear as invisible on excel,
|
|
24933
|
-
// Making it very hard for the client to find where the recursion is.
|
|
24934
|
-
if (cell.value === "#CYCLE") {
|
|
24935
|
-
attrs.push(["t", "str"]);
|
|
24936
|
-
cycle = escapeXml /*xml*/ `<v>${cell.value}</v>`;
|
|
24937
|
-
}
|
|
24938
24932
|
node = escapeXml /*xml*/ `
|
|
24939
24933
|
<f>
|
|
24940
24934
|
${XlsxFormula}
|
|
24941
24935
|
</f>
|
|
24942
|
-
${
|
|
24936
|
+
${escapeXml /*xml*/ `<v>${cell.value}</v>`}
|
|
24943
24937
|
`;
|
|
24938
|
+
attrs.push(["t", type]);
|
|
24944
24939
|
return { attrs, node };
|
|
24945
24940
|
}
|
|
24946
24941
|
else {
|
|
24947
|
-
// Shouldn't we always output the value then ?
|
|
24948
|
-
const value = cell.value;
|
|
24949
24942
|
// If the cell contains a non-exported formula and that is evaluates to
|
|
24950
24943
|
// nothing* ,we don't export it.
|
|
24951
24944
|
// * non-falsy value are relevant and so are 0 and FALSE, which only leaves
|
|
24952
24945
|
// the empty string.
|
|
24953
|
-
if (value === "")
|
|
24946
|
+
if (cell.value === "")
|
|
24954
24947
|
return undefined;
|
|
24955
|
-
const type = getCellType(value);
|
|
24956
24948
|
attrs.push(["t", type]);
|
|
24957
|
-
node = escapeXml /*xml*/ `<v>${value}</v>`;
|
|
24949
|
+
node = escapeXml /*xml*/ `<v>${cell.value}</v>`;
|
|
24958
24950
|
return { attrs, node };
|
|
24959
24951
|
}
|
|
24960
24952
|
}
|
|
@@ -31579,6 +31571,6 @@ exports.registries = registries;
|
|
|
31579
31571
|
exports.setTranslationMethod = setTranslationMethod;
|
|
31580
31572
|
|
|
31581
31573
|
|
|
31582
|
-
__info__.version = '15.0.
|
|
31583
|
-
__info__.date = '2024-
|
|
31584
|
-
__info__.hash = '
|
|
31574
|
+
__info__.version = '15.0.28';
|
|
31575
|
+
__info__.date = '2024-09-05T09:27:39.727Z';
|
|
31576
|
+
__info__.hash = '0f4c167';
|
|
@@ -7434,7 +7434,7 @@ function parseExpression(tokens, bp) {
|
|
|
7434
7434
|
*/
|
|
7435
7435
|
function parse(str) {
|
|
7436
7436
|
const tokens = tokenize(str).filter((x) => x.type !== "SPACE");
|
|
7437
|
-
if (tokens[0].type === "OPERATOR" && tokens[0].value === "=") {
|
|
7437
|
+
if (tokens[0] && tokens[0].type === "OPERATOR" && tokens[0].value === "=") {
|
|
7438
7438
|
tokens.splice(0, 1);
|
|
7439
7439
|
}
|
|
7440
7440
|
const result = parseExpression(tokens, 0);
|
|
@@ -24903,35 +24903,27 @@ function addFormula(cell) {
|
|
|
24903
24903
|
const isExported = tokens
|
|
24904
24904
|
.filter((tk) => tk.type === "FUNCTION")
|
|
24905
24905
|
.every((tk) => functions[tk.value.toUpperCase()].isExported);
|
|
24906
|
+
const type = getCellType(cell.value);
|
|
24906
24907
|
if (isExported) {
|
|
24907
|
-
let cycle = escapeXml ``;
|
|
24908
24908
|
const XlsxFormula = adaptFormulaToExcel(formula);
|
|
24909
|
-
// hack for cycles : if we don't set a value (be it 0 or #VALUE!), it will appear as invisible on excel,
|
|
24910
|
-
// Making it very hard for the client to find where the recursion is.
|
|
24911
|
-
if (cell.value === "#CYCLE") {
|
|
24912
|
-
attrs.push(["t", "str"]);
|
|
24913
|
-
cycle = escapeXml /*xml*/ `<v>${cell.value}</v>`;
|
|
24914
|
-
}
|
|
24915
24909
|
node = escapeXml /*xml*/ `
|
|
24916
24910
|
<f>
|
|
24917
24911
|
${XlsxFormula}
|
|
24918
24912
|
</f>
|
|
24919
|
-
${
|
|
24913
|
+
${escapeXml /*xml*/ `<v>${cell.value}</v>`}
|
|
24920
24914
|
`;
|
|
24915
|
+
attrs.push(["t", type]);
|
|
24921
24916
|
return { attrs, node };
|
|
24922
24917
|
}
|
|
24923
24918
|
else {
|
|
24924
|
-
// Shouldn't we always output the value then ?
|
|
24925
|
-
const value = cell.value;
|
|
24926
24919
|
// If the cell contains a non-exported formula and that is evaluates to
|
|
24927
24920
|
// nothing* ,we don't export it.
|
|
24928
24921
|
// * non-falsy value are relevant and so are 0 and FALSE, which only leaves
|
|
24929
24922
|
// the empty string.
|
|
24930
|
-
if (value === "")
|
|
24923
|
+
if (cell.value === "")
|
|
24931
24924
|
return undefined;
|
|
24932
|
-
const type = getCellType(value);
|
|
24933
24925
|
attrs.push(["t", type]);
|
|
24934
|
-
node = escapeXml /*xml*/ `<v>${value}</v>`;
|
|
24926
|
+
node = escapeXml /*xml*/ `<v>${cell.value}</v>`;
|
|
24935
24927
|
return { attrs, node };
|
|
24936
24928
|
}
|
|
24937
24929
|
}
|
|
@@ -31534,6 +31526,6 @@ const helpers = {
|
|
|
31534
31526
|
export { CommandResult, CorePlugin, DATETIME_FORMAT, DataSource, DispatchResult, Model, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, UIPlugin, DEBUG as __DEBUG__, __info__, astToFormula, cellTypes, convertAstNodes, coreTypes, functionCache, helpers, invalidateEvaluationCommands, normalize, parse, readonlyAllowedCommands, registries, setTranslationMethod };
|
|
31535
31527
|
|
|
31536
31528
|
|
|
31537
|
-
__info__.version = '15.0.
|
|
31538
|
-
__info__.date = '2024-
|
|
31539
|
-
__info__.hash = '
|
|
31529
|
+
__info__.version = '15.0.28';
|
|
31530
|
+
__info__.date = '2024-09-05T09:27:39.727Z';
|
|
31531
|
+
__info__.hash = '0f4c167';
|
|
@@ -7454,7 +7454,7 @@
|
|
|
7454
7454
|
*/
|
|
7455
7455
|
function parse(str) {
|
|
7456
7456
|
const tokens = tokenize(str).filter((x) => x.type !== "SPACE");
|
|
7457
|
-
if (tokens[0].type === "OPERATOR" && tokens[0].value === "=") {
|
|
7457
|
+
if (tokens[0] && tokens[0].type === "OPERATOR" && tokens[0].value === "=") {
|
|
7458
7458
|
tokens.splice(0, 1);
|
|
7459
7459
|
}
|
|
7460
7460
|
const result = parseExpression(tokens, 0);
|
|
@@ -24923,35 +24923,27 @@
|
|
|
24923
24923
|
const isExported = tokens
|
|
24924
24924
|
.filter((tk) => tk.type === "FUNCTION")
|
|
24925
24925
|
.every((tk) => functions[tk.value.toUpperCase()].isExported);
|
|
24926
|
+
const type = getCellType(cell.value);
|
|
24926
24927
|
if (isExported) {
|
|
24927
|
-
let cycle = escapeXml ``;
|
|
24928
24928
|
const XlsxFormula = adaptFormulaToExcel(formula);
|
|
24929
|
-
// hack for cycles : if we don't set a value (be it 0 or #VALUE!), it will appear as invisible on excel,
|
|
24930
|
-
// Making it very hard for the client to find where the recursion is.
|
|
24931
|
-
if (cell.value === "#CYCLE") {
|
|
24932
|
-
attrs.push(["t", "str"]);
|
|
24933
|
-
cycle = escapeXml /*xml*/ `<v>${cell.value}</v>`;
|
|
24934
|
-
}
|
|
24935
24929
|
node = escapeXml /*xml*/ `
|
|
24936
24930
|
<f>
|
|
24937
24931
|
${XlsxFormula}
|
|
24938
24932
|
</f>
|
|
24939
|
-
${
|
|
24933
|
+
${escapeXml /*xml*/ `<v>${cell.value}</v>`}
|
|
24940
24934
|
`;
|
|
24935
|
+
attrs.push(["t", type]);
|
|
24941
24936
|
return { attrs, node };
|
|
24942
24937
|
}
|
|
24943
24938
|
else {
|
|
24944
|
-
// Shouldn't we always output the value then ?
|
|
24945
|
-
const value = cell.value;
|
|
24946
24939
|
// If the cell contains a non-exported formula and that is evaluates to
|
|
24947
24940
|
// nothing* ,we don't export it.
|
|
24948
24941
|
// * non-falsy value are relevant and so are 0 and FALSE, which only leaves
|
|
24949
24942
|
// the empty string.
|
|
24950
|
-
if (value === "")
|
|
24943
|
+
if (cell.value === "")
|
|
24951
24944
|
return undefined;
|
|
24952
|
-
const type = getCellType(value);
|
|
24953
24945
|
attrs.push(["t", type]);
|
|
24954
|
-
node = escapeXml /*xml*/ `<v>${value}</v>`;
|
|
24946
|
+
node = escapeXml /*xml*/ `<v>${cell.value}</v>`;
|
|
24955
24947
|
return { attrs, node };
|
|
24956
24948
|
}
|
|
24957
24949
|
}
|
|
@@ -31578,9 +31570,9 @@
|
|
|
31578
31570
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
31579
31571
|
|
|
31580
31572
|
|
|
31581
|
-
__info__.version = '15.0.
|
|
31582
|
-
__info__.date = '2024-
|
|
31583
|
-
__info__.hash = '
|
|
31573
|
+
__info__.version = '15.0.28';
|
|
31574
|
+
__info__.date = '2024-09-05T09:27:39.727Z';
|
|
31575
|
+
__info__.hash = '0f4c167';
|
|
31584
31576
|
|
|
31585
31577
|
|
|
31586
31578
|
})(this.o_spreadsheet = this.o_spreadsheet || {}, owl);
|