@odoo/o-spreadsheet 17.4.11 → 17.4.12
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.js +20 -16
- package/dist/o-spreadsheet.d.ts +10 -0
- package/dist/o-spreadsheet.esm.js +20 -16
- package/dist/o-spreadsheet.iife.js +20 -16
- package/dist/o-spreadsheet.iife.min.js +337 -337
- package/dist/o_spreadsheet.xml +11 -7
- 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 17.4.
|
|
6
|
-
* @date 2024-11-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 17.4.12
|
|
6
|
+
* @date 2024-11-13T15:06:56.109Z
|
|
7
|
+
* @hash 5cde4be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
'use strict';
|
|
@@ -23489,11 +23489,14 @@ function getDefaultChartJsRuntime(chart, labels, fontColor, { format, locale, tr
|
|
|
23489
23489
|
function getChartLabelFormat(getters, range) {
|
|
23490
23490
|
if (!range)
|
|
23491
23491
|
return undefined;
|
|
23492
|
-
|
|
23493
|
-
|
|
23494
|
-
col:
|
|
23495
|
-
|
|
23496
|
-
|
|
23492
|
+
const { sheetId, zone: { left, top, bottom }, } = range;
|
|
23493
|
+
for (let row = top; row <= bottom; row++) {
|
|
23494
|
+
const format = getters.getEvaluatedCell({ sheetId, col: left, row }).format;
|
|
23495
|
+
if (format) {
|
|
23496
|
+
return format;
|
|
23497
|
+
}
|
|
23498
|
+
}
|
|
23499
|
+
return undefined;
|
|
23497
23500
|
}
|
|
23498
23501
|
function getChartLabelValues(getters, dataSets, labelRange) {
|
|
23499
23502
|
let labels = { values: [], formattedValues: [] };
|
|
@@ -24032,11 +24035,7 @@ function canBeDateChart(labelRange, getters) {
|
|
|
24032
24035
|
if (!labelRange || !canBeLinearChart(labelRange, getters)) {
|
|
24033
24036
|
return false;
|
|
24034
24037
|
}
|
|
24035
|
-
const labelFormat = getters
|
|
24036
|
-
sheetId: labelRange.sheetId,
|
|
24037
|
-
col: labelRange.zone.left,
|
|
24038
|
-
row: labelRange.zone.top,
|
|
24039
|
-
}).format;
|
|
24038
|
+
const labelFormat = getChartLabelFormat(getters, labelRange);
|
|
24040
24039
|
return Boolean(labelFormat && timeFormatLuxonCompatible.test(labelFormat));
|
|
24041
24040
|
}
|
|
24042
24041
|
function canBeLinearChart(labelRange, getters) {
|
|
@@ -32069,6 +32068,7 @@ class ColorPicker extends owl.Component {
|
|
|
32069
32068
|
currentColor: { type: String, optional: true },
|
|
32070
32069
|
maxHeight: { type: Number, optional: true },
|
|
32071
32070
|
anchorRect: Object,
|
|
32071
|
+
disableNoColor: { type: Boolean, optional: true },
|
|
32072
32072
|
};
|
|
32073
32073
|
static defaultProps = { currentColor: "" };
|
|
32074
32074
|
static components = { Popover };
|
|
@@ -32294,6 +32294,7 @@ class RoundColorPicker extends owl.Component {
|
|
|
32294
32294
|
currentColor: { type: String, optional: true },
|
|
32295
32295
|
title: { type: String, optional: true },
|
|
32296
32296
|
onColorPicked: Function,
|
|
32297
|
+
disableNoColor: { type: Boolean, optional: true },
|
|
32297
32298
|
};
|
|
32298
32299
|
colorPickerButtonRef = owl.useRef("colorPickerButton");
|
|
32299
32300
|
state;
|
|
@@ -34355,6 +34356,9 @@ class ConditionalFormattingEditor extends owl.Component {
|
|
|
34355
34356
|
}
|
|
34356
34357
|
}
|
|
34357
34358
|
setColorScaleColor(target, color) {
|
|
34359
|
+
if (!isColorValid(color)) {
|
|
34360
|
+
return;
|
|
34361
|
+
}
|
|
34358
34362
|
const point = this.state.rules.colorScale[target];
|
|
34359
34363
|
if (point) {
|
|
34360
34364
|
point.color = Number.parseInt(color.substr(1), 16);
|
|
@@ -68678,6 +68682,6 @@ exports.tokenColors = tokenColors;
|
|
|
68678
68682
|
exports.tokenize = tokenize;
|
|
68679
68683
|
|
|
68680
68684
|
|
|
68681
|
-
__info__.version = "17.4.
|
|
68682
|
-
__info__.date = "2024-11-
|
|
68683
|
-
__info__.hash = "
|
|
68685
|
+
__info__.version = "17.4.12";
|
|
68686
|
+
__info__.date = "2024-11-13T15:06:56.109Z";
|
|
68687
|
+
__info__.hash = "5cde4be";
|
package/dist/o-spreadsheet.d.ts
CHANGED
|
@@ -6887,6 +6887,7 @@ interface ColorPickerProps {
|
|
|
6887
6887
|
maxHeight?: Pixel;
|
|
6888
6888
|
onColorPicked: (color: Color) => void;
|
|
6889
6889
|
currentColor: Color;
|
|
6890
|
+
disableNoColor?: boolean;
|
|
6890
6891
|
}
|
|
6891
6892
|
declare class ColorPicker extends Component<ColorPickerProps, SpreadsheetChildEnv> {
|
|
6892
6893
|
static template: string;
|
|
@@ -6901,6 +6902,10 @@ declare class ColorPicker extends Component<ColorPickerProps, SpreadsheetChildEn
|
|
|
6901
6902
|
optional: boolean;
|
|
6902
6903
|
};
|
|
6903
6904
|
anchorRect: ObjectConstructor;
|
|
6905
|
+
disableNoColor: {
|
|
6906
|
+
type: BooleanConstructor;
|
|
6907
|
+
optional: boolean;
|
|
6908
|
+
};
|
|
6904
6909
|
};
|
|
6905
6910
|
static defaultProps: {
|
|
6906
6911
|
currentColor: string;
|
|
@@ -6984,6 +6989,7 @@ interface Props$U {
|
|
|
6984
6989
|
currentColor?: string;
|
|
6985
6990
|
onColorPicked: (color: string) => void;
|
|
6986
6991
|
title?: string;
|
|
6992
|
+
disableNoColor?: boolean;
|
|
6987
6993
|
}
|
|
6988
6994
|
declare class RoundColorPicker extends Component<Props$U, SpreadsheetChildEnv> {
|
|
6989
6995
|
static template: string;
|
|
@@ -7002,6 +7008,10 @@ declare class RoundColorPicker extends Component<Props$U, SpreadsheetChildEnv> {
|
|
|
7002
7008
|
optional: boolean;
|
|
7003
7009
|
};
|
|
7004
7010
|
onColorPicked: FunctionConstructor;
|
|
7011
|
+
disableNoColor: {
|
|
7012
|
+
type: BooleanConstructor;
|
|
7013
|
+
optional: boolean;
|
|
7014
|
+
};
|
|
7005
7015
|
};
|
|
7006
7016
|
colorPickerButtonRef: {
|
|
7007
7017
|
el: HTMLElement | null;
|
|
@@ -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 17.4.
|
|
6
|
-
* @date 2024-11-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 17.4.12
|
|
6
|
+
* @date 2024-11-13T15:06:56.109Z
|
|
7
|
+
* @hash 5cde4be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
import { useEnv, useSubEnv, onWillUnmount, useComponent, status, Component, useRef, onMounted, useEffect, useState, onPatched, onWillPatch, onWillUpdateProps, useExternalListener, onWillStart, xml, useChildSubEnv, markRaw, toRaw } from '@odoo/owl';
|
|
@@ -23487,11 +23487,14 @@ function getDefaultChartJsRuntime(chart, labels, fontColor, { format, locale, tr
|
|
|
23487
23487
|
function getChartLabelFormat(getters, range) {
|
|
23488
23488
|
if (!range)
|
|
23489
23489
|
return undefined;
|
|
23490
|
-
|
|
23491
|
-
|
|
23492
|
-
col:
|
|
23493
|
-
|
|
23494
|
-
|
|
23490
|
+
const { sheetId, zone: { left, top, bottom }, } = range;
|
|
23491
|
+
for (let row = top; row <= bottom; row++) {
|
|
23492
|
+
const format = getters.getEvaluatedCell({ sheetId, col: left, row }).format;
|
|
23493
|
+
if (format) {
|
|
23494
|
+
return format;
|
|
23495
|
+
}
|
|
23496
|
+
}
|
|
23497
|
+
return undefined;
|
|
23495
23498
|
}
|
|
23496
23499
|
function getChartLabelValues(getters, dataSets, labelRange) {
|
|
23497
23500
|
let labels = { values: [], formattedValues: [] };
|
|
@@ -24030,11 +24033,7 @@ function canBeDateChart(labelRange, getters) {
|
|
|
24030
24033
|
if (!labelRange || !canBeLinearChart(labelRange, getters)) {
|
|
24031
24034
|
return false;
|
|
24032
24035
|
}
|
|
24033
|
-
const labelFormat = getters
|
|
24034
|
-
sheetId: labelRange.sheetId,
|
|
24035
|
-
col: labelRange.zone.left,
|
|
24036
|
-
row: labelRange.zone.top,
|
|
24037
|
-
}).format;
|
|
24036
|
+
const labelFormat = getChartLabelFormat(getters, labelRange);
|
|
24038
24037
|
return Boolean(labelFormat && timeFormatLuxonCompatible.test(labelFormat));
|
|
24039
24038
|
}
|
|
24040
24039
|
function canBeLinearChart(labelRange, getters) {
|
|
@@ -32067,6 +32066,7 @@ class ColorPicker extends Component {
|
|
|
32067
32066
|
currentColor: { type: String, optional: true },
|
|
32068
32067
|
maxHeight: { type: Number, optional: true },
|
|
32069
32068
|
anchorRect: Object,
|
|
32069
|
+
disableNoColor: { type: Boolean, optional: true },
|
|
32070
32070
|
};
|
|
32071
32071
|
static defaultProps = { currentColor: "" };
|
|
32072
32072
|
static components = { Popover };
|
|
@@ -32292,6 +32292,7 @@ class RoundColorPicker extends Component {
|
|
|
32292
32292
|
currentColor: { type: String, optional: true },
|
|
32293
32293
|
title: { type: String, optional: true },
|
|
32294
32294
|
onColorPicked: Function,
|
|
32295
|
+
disableNoColor: { type: Boolean, optional: true },
|
|
32295
32296
|
};
|
|
32296
32297
|
colorPickerButtonRef = useRef("colorPickerButton");
|
|
32297
32298
|
state;
|
|
@@ -34353,6 +34354,9 @@ class ConditionalFormattingEditor extends Component {
|
|
|
34353
34354
|
}
|
|
34354
34355
|
}
|
|
34355
34356
|
setColorScaleColor(target, color) {
|
|
34357
|
+
if (!isColorValid(color)) {
|
|
34358
|
+
return;
|
|
34359
|
+
}
|
|
34356
34360
|
const point = this.state.rules.colorScale[target];
|
|
34357
34361
|
if (point) {
|
|
34358
34362
|
point.color = Number.parseInt(color.substr(1), 16);
|
|
@@ -68633,6 +68637,6 @@ const constants = {
|
|
|
68633
68637
|
export { AbstractCellClipboardHandler, AbstractChart, AbstractFigureClipboardHandler, CellErrorType, CommandResult, CorePlugin, DispatchResult, EvaluationError, Model, PivotRuntimeDefinition, Registry, Revision, SPREADSHEET_DIMENSIONS, Spreadsheet, SpreadsheetPivotTable, UIPlugin, __info__, addFunction, addRenderingLayer, astToFormula, compile, compileTokens, components, constants, convertAstNodes, coreTypes, findCellInNewZone, functionCache, helpers, hooks, invalidateCFEvaluationCommands, invalidateDependenciesCommands, invalidateEvaluationCommands, iterateAstNodes, links, load, parse, parseTokens, readonlyAllowedCommands, registries, setDefaultSheetViewSize, setTranslationMethod, stores, tokenColors, tokenize };
|
|
68634
68638
|
|
|
68635
68639
|
|
|
68636
|
-
__info__.version = "17.4.
|
|
68637
|
-
__info__.date = "2024-11-
|
|
68638
|
-
__info__.hash = "
|
|
68640
|
+
__info__.version = "17.4.12";
|
|
68641
|
+
__info__.date = "2024-11-13T15:06:56.109Z";
|
|
68642
|
+
__info__.hash = "5cde4be";
|
|
@@ -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 17.4.
|
|
6
|
-
* @date 2024-11-
|
|
7
|
-
* @hash
|
|
5
|
+
* @version 17.4.12
|
|
6
|
+
* @date 2024-11-13T15:06:56.109Z
|
|
7
|
+
* @hash 5cde4be
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
10
|
(function (exports, owl) {
|
|
@@ -23488,11 +23488,14 @@ stores.inject(MyMetaStore, storeInstance);
|
|
|
23488
23488
|
function getChartLabelFormat(getters, range) {
|
|
23489
23489
|
if (!range)
|
|
23490
23490
|
return undefined;
|
|
23491
|
-
|
|
23492
|
-
|
|
23493
|
-
col:
|
|
23494
|
-
|
|
23495
|
-
|
|
23491
|
+
const { sheetId, zone: { left, top, bottom }, } = range;
|
|
23492
|
+
for (let row = top; row <= bottom; row++) {
|
|
23493
|
+
const format = getters.getEvaluatedCell({ sheetId, col: left, row }).format;
|
|
23494
|
+
if (format) {
|
|
23495
|
+
return format;
|
|
23496
|
+
}
|
|
23497
|
+
}
|
|
23498
|
+
return undefined;
|
|
23496
23499
|
}
|
|
23497
23500
|
function getChartLabelValues(getters, dataSets, labelRange) {
|
|
23498
23501
|
let labels = { values: [], formattedValues: [] };
|
|
@@ -24031,11 +24034,7 @@ stores.inject(MyMetaStore, storeInstance);
|
|
|
24031
24034
|
if (!labelRange || !canBeLinearChart(labelRange, getters)) {
|
|
24032
24035
|
return false;
|
|
24033
24036
|
}
|
|
24034
|
-
const labelFormat = getters
|
|
24035
|
-
sheetId: labelRange.sheetId,
|
|
24036
|
-
col: labelRange.zone.left,
|
|
24037
|
-
row: labelRange.zone.top,
|
|
24038
|
-
}).format;
|
|
24037
|
+
const labelFormat = getChartLabelFormat(getters, labelRange);
|
|
24039
24038
|
return Boolean(labelFormat && timeFormatLuxonCompatible.test(labelFormat));
|
|
24040
24039
|
}
|
|
24041
24040
|
function canBeLinearChart(labelRange, getters) {
|
|
@@ -32068,6 +32067,7 @@ stores.inject(MyMetaStore, storeInstance);
|
|
|
32068
32067
|
currentColor: { type: String, optional: true },
|
|
32069
32068
|
maxHeight: { type: Number, optional: true },
|
|
32070
32069
|
anchorRect: Object,
|
|
32070
|
+
disableNoColor: { type: Boolean, optional: true },
|
|
32071
32071
|
};
|
|
32072
32072
|
static defaultProps = { currentColor: "" };
|
|
32073
32073
|
static components = { Popover };
|
|
@@ -32293,6 +32293,7 @@ stores.inject(MyMetaStore, storeInstance);
|
|
|
32293
32293
|
currentColor: { type: String, optional: true },
|
|
32294
32294
|
title: { type: String, optional: true },
|
|
32295
32295
|
onColorPicked: Function,
|
|
32296
|
+
disableNoColor: { type: Boolean, optional: true },
|
|
32296
32297
|
};
|
|
32297
32298
|
colorPickerButtonRef = owl.useRef("colorPickerButton");
|
|
32298
32299
|
state;
|
|
@@ -34354,6 +34355,9 @@ stores.inject(MyMetaStore, storeInstance);
|
|
|
34354
34355
|
}
|
|
34355
34356
|
}
|
|
34356
34357
|
setColorScaleColor(target, color) {
|
|
34358
|
+
if (!isColorValid(color)) {
|
|
34359
|
+
return;
|
|
34360
|
+
}
|
|
34357
34361
|
const point = this.state.rules.colorScale[target];
|
|
34358
34362
|
if (point) {
|
|
34359
34363
|
point.color = Number.parseInt(color.substr(1), 16);
|
|
@@ -68677,9 +68681,9 @@ stores.inject(MyMetaStore, storeInstance);
|
|
|
68677
68681
|
exports.tokenize = tokenize;
|
|
68678
68682
|
|
|
68679
68683
|
|
|
68680
|
-
__info__.version = "17.4.
|
|
68681
|
-
__info__.date = "2024-11-
|
|
68682
|
-
__info__.hash = "
|
|
68684
|
+
__info__.version = "17.4.12";
|
|
68685
|
+
__info__.date = "2024-11-13T15:06:56.109Z";
|
|
68686
|
+
__info__.hash = "5cde4be";
|
|
68683
68687
|
|
|
68684
68688
|
|
|
68685
68689
|
})(this.o_spreadsheet = this.o_spreadsheet || {}, owl);
|