@vaadin/charts 24.8.0-alpha9 → 25.0.0-alpha2
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/package.json +9 -12
- package/src/vaadin-chart-mixin.js +12 -5
- package/src/vaadin-chart-series-mixin.d.ts +0 -4
- package/src/vaadin-chart-series-mixin.js +0 -3
- package/src/vaadin-chart-series.js +3 -2
- package/src/vaadin-chart.js +25 -20
- package/web-types.json +2 -2
- package/web-types.lit.json +2 -2
- package/src/vaadin-lit-chart-series.d.ts +0 -11
- package/src/vaadin-lit-chart-series.js +0 -33
- package/src/vaadin-lit-chart.d.ts +0 -11
- package/src/vaadin-lit-chart.js +0 -61
- package/theme/lumo/vaadin-lit-chart.d.ts +0 -2
- package/theme/lumo/vaadin-lit-chart.js +0 -2
- package/theme/material/vaadin-chart-styles.d.ts +0 -6
- package/theme/material/vaadin-chart-styles.js +0 -97
- package/theme/material/vaadin-chart.d.ts +0 -2
- package/theme/material/vaadin-chart.js +0 -2
- package/theme/material/vaadin-lit-chart.d.ts +0 -2
- package/theme/material/vaadin-lit-chart.js +0 -2
- package/vaadin-lit-chart-series.d.ts +0 -1
- package/vaadin-lit-chart-series.js +0 -1
- package/vaadin-lit-chart.d.ts +0 -1
- package/vaadin-lit-chart.js +0 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/charts",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "25.0.0-alpha2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -31,23 +31,20 @@
|
|
|
31
31
|
"Vaadin",
|
|
32
32
|
"vaadin-charts",
|
|
33
33
|
"web-components",
|
|
34
|
-
"web-component"
|
|
35
|
-
"polymer"
|
|
34
|
+
"web-component"
|
|
36
35
|
],
|
|
37
36
|
"dependencies": {
|
|
38
37
|
"@open-wc/dedupe-mixin": "^1.3.0",
|
|
39
|
-
"@
|
|
40
|
-
"@vaadin/
|
|
41
|
-
"@vaadin/vaadin-
|
|
42
|
-
"@vaadin/vaadin-material-styles": "24.8.0-alpha9",
|
|
43
|
-
"@vaadin/vaadin-themable-mixin": "24.8.0-alpha9",
|
|
38
|
+
"@vaadin/component-base": "25.0.0-alpha2",
|
|
39
|
+
"@vaadin/vaadin-lumo-styles": "25.0.0-alpha2",
|
|
40
|
+
"@vaadin/vaadin-themable-mixin": "25.0.0-alpha2",
|
|
44
41
|
"highcharts": "9.2.2",
|
|
45
42
|
"lit": "^3.0.0"
|
|
46
43
|
},
|
|
47
44
|
"devDependencies": {
|
|
48
|
-
"@vaadin/chai-plugins": "
|
|
49
|
-
"@vaadin/test-runner-commands": "
|
|
50
|
-
"@vaadin/testing-helpers": "^
|
|
45
|
+
"@vaadin/chai-plugins": "25.0.0-alpha2",
|
|
46
|
+
"@vaadin/test-runner-commands": "25.0.0-alpha2",
|
|
47
|
+
"@vaadin/testing-helpers": "^2.0.0",
|
|
51
48
|
"sinon": "^18.0.0"
|
|
52
49
|
},
|
|
53
50
|
"cvdlName": "vaadin-chart",
|
|
@@ -55,5 +52,5 @@
|
|
|
55
52
|
"web-types.json",
|
|
56
53
|
"web-types.lit.json"
|
|
57
54
|
],
|
|
58
|
-
"gitHead": "
|
|
55
|
+
"gitHead": "67ffcd5355cf21ce1b5039c598525109fc4c164b"
|
|
59
56
|
}
|
|
@@ -28,12 +28,11 @@ import 'highcharts/es-modules/masters/modules/xrange.src.js';
|
|
|
28
28
|
import 'highcharts/es-modules/masters/modules/bullet.src.js';
|
|
29
29
|
import 'highcharts/es-modules/masters/modules/gantt.src.js';
|
|
30
30
|
import 'highcharts/es-modules/masters/modules/draggable-points.src.js';
|
|
31
|
-
import { FlattenedNodesObserver } from '@polymer/polymer/lib/utils/flattened-nodes-observer.js';
|
|
32
|
-
import { beforeNextRender } from '@polymer/polymer/lib/utils/render-status.js';
|
|
33
31
|
import Pointer from 'highcharts/es-modules/Core/Pointer.js';
|
|
34
32
|
import Highcharts from 'highcharts/es-modules/masters/highstock.src.js';
|
|
35
33
|
import { get } from '@vaadin/component-base/src/path-utils.js';
|
|
36
34
|
import { ResizeMixin } from '@vaadin/component-base/src/resize-mixin.js';
|
|
35
|
+
import { SlotObserver } from '@vaadin/component-base/src/slot-observer.js';
|
|
37
36
|
import { deepMerge, inflateFunctions } from './helpers.js';
|
|
38
37
|
|
|
39
38
|
['exportChart', 'exportChartLocal', 'getSVG'].forEach((methodName) => {
|
|
@@ -753,7 +752,7 @@ export const ChartMixin = (superClass) =>
|
|
|
753
752
|
connectedCallback() {
|
|
754
753
|
super.connectedCallback();
|
|
755
754
|
this.__updateStyles();
|
|
756
|
-
|
|
755
|
+
queueMicrotask(() => {
|
|
757
756
|
// Detect if the chart had already been initialized. This might happen in
|
|
758
757
|
// environments where the chart is lazily attached (e.g Grid).
|
|
759
758
|
if (this.configuration) {
|
|
@@ -803,7 +802,7 @@ export const ChartMixin = (superClass) =>
|
|
|
803
802
|
|
|
804
803
|
/** @private */
|
|
805
804
|
__addChildObserver() {
|
|
806
|
-
this._childObserver = new
|
|
805
|
+
this._childObserver = new SlotObserver(this.$.slot, (info) => {
|
|
807
806
|
this.__addSeries(info.addedNodes.filter(this.__filterSeriesNodes));
|
|
808
807
|
this.__removeSeries(info.removedNodes.filter(this.__filterSeriesNodes));
|
|
809
808
|
this.__cleanupAfterSeriesRemoved(info.removedNodes.filter(this.__filterSeriesNodes));
|
|
@@ -1048,7 +1047,7 @@ export const ChartMixin = (superClass) =>
|
|
|
1048
1047
|
inflateFunctions(configCopy);
|
|
1049
1048
|
this._jsonConfigurationBuffer = this.__makeConfigurationBuffer(this._jsonConfigurationBuffer, configCopy);
|
|
1050
1049
|
|
|
1051
|
-
|
|
1050
|
+
queueMicrotask(() => {
|
|
1052
1051
|
if (!this.configuration || !this._jsonConfigurationBuffer) {
|
|
1053
1052
|
return;
|
|
1054
1053
|
}
|
|
@@ -1208,10 +1207,18 @@ export const ChartMixin = (superClass) =>
|
|
|
1208
1207
|
if (!self.tempBodyStyle) {
|
|
1209
1208
|
let effectiveCss = '';
|
|
1210
1209
|
|
|
1210
|
+
// PolymerElement uses `<style>` tags for adding styles
|
|
1211
1211
|
[...self.shadowRoot.querySelectorAll('style')].forEach((style) => {
|
|
1212
1212
|
effectiveCss += style.textContent;
|
|
1213
1213
|
});
|
|
1214
1214
|
|
|
1215
|
+
// LitElement uses `adoptedStyleSheets` for adding styles
|
|
1216
|
+
if (self.shadowRoot.adoptedStyleSheets) {
|
|
1217
|
+
self.shadowRoot.adoptedStyleSheets.forEach((sheet) => {
|
|
1218
|
+
effectiveCss += [...sheet.cssRules].map((rule) => rule.cssText).join('\n');
|
|
1219
|
+
});
|
|
1220
|
+
}
|
|
1221
|
+
|
|
1215
1222
|
// Strip off host selectors that target individual instances
|
|
1216
1223
|
effectiveCss = effectiveCss.replace(/:host\(.+?\)/gu, (match) => {
|
|
1217
1224
|
const selector = match.substr(6, match.length - 7);
|
|
@@ -48,10 +48,6 @@ export declare class ChartSeriesMixinClass {
|
|
|
48
48
|
* - An array of objects, each one describing one point `[ {x: x0, y: y0, name: 'Point0', color: '#FF0000'}, {...}, ...]`
|
|
49
49
|
*
|
|
50
50
|
* See more in [API Site](https://api.highcharts.com/highcharts/series)
|
|
51
|
-
*
|
|
52
|
-
* Note that you should always use [Polymer API](https://www.polymer-project.org/2.0/docs/devguide/model-data#array-mutation)
|
|
53
|
-
* to mutate the values array in order to make the component aware of the
|
|
54
|
-
* change and be able to synchronize it.
|
|
55
51
|
*/
|
|
56
52
|
values: ChartSeriesValues | null;
|
|
57
53
|
|
|
@@ -26,9 +26,6 @@ export const ChartSeriesMixin = (superClass) =>
|
|
|
26
26
|
*
|
|
27
27
|
* See more in [API Site](https://api.highcharts.com/highcharts/series)
|
|
28
28
|
*
|
|
29
|
-
* Note that you should always use [Polymer API](https://www.polymer-project.org/2.0/docs/devguide/model-data#array-mutation)
|
|
30
|
-
* to mutate the values array in order to make the component aware of the
|
|
31
|
-
* change and be able to synchronize it.
|
|
32
29
|
* @type {ChartSeriesValues}
|
|
33
30
|
*/
|
|
34
31
|
values: {
|
|
@@ -8,8 +8,9 @@
|
|
|
8
8
|
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
9
|
* license.
|
|
10
10
|
*/
|
|
11
|
-
import {
|
|
11
|
+
import { LitElement } from 'lit';
|
|
12
12
|
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
13
|
+
import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
|
|
13
14
|
import { ChartSeriesMixin } from './vaadin-chart-series-mixin.js';
|
|
14
15
|
|
|
15
16
|
/**
|
|
@@ -59,7 +60,7 @@ import { ChartSeriesMixin } from './vaadin-chart-series-mixin.js';
|
|
|
59
60
|
* @extends HTMLElement
|
|
60
61
|
* @mixes ChartSeriesMixin
|
|
61
62
|
*/
|
|
62
|
-
class ChartSeries extends ChartSeriesMixin(
|
|
63
|
+
class ChartSeries extends ChartSeriesMixin(PolylitMixin(LitElement)) {
|
|
63
64
|
static get is() {
|
|
64
65
|
return 'vaadin-chart-series';
|
|
65
66
|
}
|
package/src/vaadin-chart.js
CHANGED
|
@@ -9,9 +9,10 @@
|
|
|
9
9
|
* license.
|
|
10
10
|
*/
|
|
11
11
|
import './vaadin-chart-series.js';
|
|
12
|
-
import { html,
|
|
12
|
+
import { css, html, LitElement } from 'lit';
|
|
13
13
|
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
14
14
|
import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
|
|
15
|
+
import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
|
|
15
16
|
import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
16
17
|
import { ChartMixin } from './vaadin-chart-mixin.js';
|
|
17
18
|
|
|
@@ -179,25 +180,7 @@ import { ChartMixin } from './vaadin-chart-mixin.js';
|
|
|
179
180
|
* @mixes ThemableMixin
|
|
180
181
|
* @mixes ElementMixin
|
|
181
182
|
*/
|
|
182
|
-
class Chart extends ChartMixin(ThemableMixin(ElementMixin(
|
|
183
|
-
static get template() {
|
|
184
|
-
return html`
|
|
185
|
-
<style>
|
|
186
|
-
:host {
|
|
187
|
-
display: block;
|
|
188
|
-
width: 100%;
|
|
189
|
-
overflow: hidden;
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
:host([hidden]) {
|
|
193
|
-
display: none !important;
|
|
194
|
-
}
|
|
195
|
-
</style>
|
|
196
|
-
<div id="chart"></div>
|
|
197
|
-
<slot id="slot"></slot>
|
|
198
|
-
`;
|
|
199
|
-
}
|
|
200
|
-
|
|
183
|
+
class Chart extends ChartMixin(ThemableMixin(ElementMixin(PolylitMixin(LitElement)))) {
|
|
201
184
|
static get is() {
|
|
202
185
|
return 'vaadin-chart';
|
|
203
186
|
}
|
|
@@ -205,6 +188,28 @@ class Chart extends ChartMixin(ThemableMixin(ElementMixin(PolymerElement))) {
|
|
|
205
188
|
static get cvdlName() {
|
|
206
189
|
return 'vaadin-chart';
|
|
207
190
|
}
|
|
191
|
+
|
|
192
|
+
static get styles() {
|
|
193
|
+
return css`
|
|
194
|
+
:host {
|
|
195
|
+
display: block;
|
|
196
|
+
width: 100%;
|
|
197
|
+
overflow: hidden;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
:host([hidden]) {
|
|
201
|
+
display: none !important;
|
|
202
|
+
}
|
|
203
|
+
`;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
/** @protected */
|
|
207
|
+
render() {
|
|
208
|
+
return html`
|
|
209
|
+
<div id="chart"></div>
|
|
210
|
+
<slot id="slot"></slot>
|
|
211
|
+
`;
|
|
212
|
+
}
|
|
208
213
|
}
|
|
209
214
|
|
|
210
215
|
defineCustomElement(Chart);
|
package/web-types.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/charts",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "25.0.0-alpha2",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"contributions": {
|
|
7
7
|
"html": {
|
|
@@ -119,7 +119,7 @@
|
|
|
119
119
|
"properties": [
|
|
120
120
|
{
|
|
121
121
|
"name": "values",
|
|
122
|
-
"description": "An array of data used by the series.\nFormat depends on the chart type and can be:\n - An array of numerical values `[y0, y1, y2, y3,...]`\n - An array of arrays with 2 values (`x`, `y`) `[ [x0, y0], [x1, y1], [x2, y2], ... ]`\n - An array of objects, each one describing one point `[ {x: x0, y: y0, name: 'Point0', color: '#FF0000'}, {...}, ...]`\n\n See more in [API Site](https://api.highcharts.com/highcharts/series)
|
|
122
|
+
"description": "An array of data used by the series.\nFormat depends on the chart type and can be:\n - An array of numerical values `[y0, y1, y2, y3,...]`\n - An array of arrays with 2 values (`x`, `y`) `[ [x0, y0], [x1, y1], [x2, y2], ... ]`\n - An array of objects, each one describing one point `[ {x: x0, y: y0, name: 'Point0', color: '#FF0000'}, {...}, ...]`\n\n See more in [API Site](https://api.highcharts.com/highcharts/series)",
|
|
123
123
|
"value": {
|
|
124
124
|
"type": [
|
|
125
125
|
"ChartSeriesValues"
|
package/web-types.lit.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/charts",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "25.0.0-alpha2",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"framework": "lit",
|
|
7
7
|
"framework-config": {
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"attributes": [
|
|
22
22
|
{
|
|
23
23
|
"name": ".values",
|
|
24
|
-
"description": "An array of data used by the series.\nFormat depends on the chart type and can be:\n - An array of numerical values `[y0, y1, y2, y3,...]`\n - An array of arrays with 2 values (`x`, `y`) `[ [x0, y0], [x1, y1], [x2, y2], ... ]`\n - An array of objects, each one describing one point `[ {x: x0, y: y0, name: 'Point0', color: '#FF0000'}, {...}, ...]`\n\n See more in [API Site](https://api.highcharts.com/highcharts/series)
|
|
24
|
+
"description": "An array of data used by the series.\nFormat depends on the chart type and can be:\n - An array of numerical values `[y0, y1, y2, y3,...]`\n - An array of arrays with 2 values (`x`, `y`) `[ [x0, y0], [x1, y1], [x2, y2], ... ]`\n - An array of objects, each one describing one point `[ {x: x0, y: y0, name: 'Point0', color: '#FF0000'}, {...}, ...]`\n\n See more in [API Site](https://api.highcharts.com/highcharts/series)",
|
|
25
25
|
"value": {
|
|
26
26
|
"kind": "expression"
|
|
27
27
|
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
export * from './vaadin-chart-series.js';
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import './vaadin-lit-chart.js';
|
|
12
|
-
import { LitElement } from 'lit';
|
|
13
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
14
|
-
import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
|
|
15
|
-
import { ChartSeriesMixin } from './vaadin-chart-series-mixin.js';
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* LitElement based version of `<vaadin-chart-series>` web component.
|
|
19
|
-
*
|
|
20
|
-
* ## Disclaimer
|
|
21
|
-
*
|
|
22
|
-
* This component is an experiment and not yet a part of Vaadin platform.
|
|
23
|
-
* There is no ETA regarding specific Vaadin version where it'll land.
|
|
24
|
-
*/
|
|
25
|
-
class ChartSeries extends ChartSeriesMixin(PolylitMixin(LitElement)) {
|
|
26
|
-
static get is() {
|
|
27
|
-
return 'vaadin-chart-series';
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
defineCustomElement(ChartSeries);
|
|
32
|
-
|
|
33
|
-
export { ChartSeries };
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
export * from './vaadin-chart.js';
|
package/src/vaadin-lit-chart.js
DELETED
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import './vaadin-lit-chart-series.js';
|
|
12
|
-
import { css, html, LitElement } from 'lit';
|
|
13
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
14
|
-
import { ElementMixin } from '@vaadin/component-base/src/element-mixin.js';
|
|
15
|
-
import { PolylitMixin } from '@vaadin/component-base/src/polylit-mixin.js';
|
|
16
|
-
import { ThemableMixin } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
17
|
-
import { ChartMixin } from './vaadin-chart-mixin.js';
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* LitElement based version of `<vaadin-chart>` web component.
|
|
21
|
-
*
|
|
22
|
-
* ## Disclaimer
|
|
23
|
-
*
|
|
24
|
-
* This component is an experiment and not yet a part of Vaadin platform.
|
|
25
|
-
* There is no ETA regarding specific Vaadin version where it'll land.
|
|
26
|
-
*/
|
|
27
|
-
class Chart extends ChartMixin(ThemableMixin(ElementMixin(PolylitMixin(LitElement)))) {
|
|
28
|
-
static get styles() {
|
|
29
|
-
return css`
|
|
30
|
-
:host {
|
|
31
|
-
display: block;
|
|
32
|
-
width: 100%;
|
|
33
|
-
overflow: hidden;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
:host([hidden]) {
|
|
37
|
-
display: none !important;
|
|
38
|
-
}
|
|
39
|
-
`;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
/** @protected */
|
|
43
|
-
render() {
|
|
44
|
-
return html`
|
|
45
|
-
<div id="chart"></div>
|
|
46
|
-
<slot id="slot"></slot>
|
|
47
|
-
`;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
static get is() {
|
|
51
|
-
return 'vaadin-chart';
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
static get cvdlName() {
|
|
55
|
-
return 'vaadin-chart';
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
defineCustomElement(Chart);
|
|
60
|
-
|
|
61
|
-
export { Chart };
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import '../vaadin-chart-base-theme.js';
|
|
2
|
-
import '@vaadin/vaadin-material-styles/color.js';
|
|
3
|
-
import '@vaadin/vaadin-material-styles/typography.js';
|
|
4
|
-
declare const chartColors: import("lit").CSSResult;
|
|
5
|
-
declare const chartTheme: import("lit").CSSResult;
|
|
6
|
-
export { chartColors, chartTheme };
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
import '../vaadin-chart-base-theme.js';
|
|
2
|
-
import '@vaadin/vaadin-material-styles/color.js';
|
|
3
|
-
import '@vaadin/vaadin-material-styles/typography.js';
|
|
4
|
-
import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/register-styles.js';
|
|
5
|
-
|
|
6
|
-
const chartColors = css`
|
|
7
|
-
:host {
|
|
8
|
-
--vaadin-charts-color-0: #6200ee;
|
|
9
|
-
--vaadin-charts-color-1: #2fa69a;
|
|
10
|
-
--vaadin-charts-color-2: #ec611f;
|
|
11
|
-
--vaadin-charts-color-3: #fec02f;
|
|
12
|
-
--vaadin-charts-color-4: #ff4193;
|
|
13
|
-
--vaadin-charts-color-5: #007dee;
|
|
14
|
-
--vaadin-charts-color-6: #b064fc;
|
|
15
|
-
--vaadin-charts-color-7: #0c5d56;
|
|
16
|
-
--vaadin-charts-color-8: #42c6ff;
|
|
17
|
-
--vaadin-charts-color-9: #b00020;
|
|
18
|
-
--vaadin-charts-color-positive: var(--vaadin-charts-color-1, #2fa69a);
|
|
19
|
-
--vaadin-charts-color-negative: var(--vaadin-charts-color-9, #b00020);
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
:host([theme~='gradient']) {
|
|
23
|
-
--vaadin-charts-color-0: #6200ee;
|
|
24
|
-
--vaadin-charts-color-1: #6962e8;
|
|
25
|
-
--vaadin-charts-color-2: #619fe1;
|
|
26
|
-
--vaadin-charts-color-3: #2fbfd3;
|
|
27
|
-
--vaadin-charts-color-4: #03dac6;
|
|
28
|
-
--vaadin-charts-color-5: #5bd091;
|
|
29
|
-
--vaadin-charts-color-6: #acc65e;
|
|
30
|
-
--vaadin-charts-color-7: #ffbc2b;
|
|
31
|
-
--vaadin-charts-color-8: #fe9940;
|
|
32
|
-
--vaadin-charts-color-9: #fd695e;
|
|
33
|
-
--vaadin-charts-color-positive: var(--vaadin-charts-color-6);
|
|
34
|
-
--vaadin-charts-color-negative: var(--vaadin-charts-color-9);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
:host([theme~='monotone']) {
|
|
38
|
-
--vaadin-charts-color-0: #6200ee;
|
|
39
|
-
--vaadin-charts-color-1: #7f39fb;
|
|
40
|
-
--vaadin-charts-color-2: #985eff;
|
|
41
|
-
--vaadin-charts-color-3: #bb86fc;
|
|
42
|
-
--vaadin-charts-color-4: #dbb2ff;
|
|
43
|
-
--vaadin-charts-color-5: #ecddfd;
|
|
44
|
-
--vaadin-charts-color-6: #9fe3eb;
|
|
45
|
-
--vaadin-charts-color-7: #03dac6;
|
|
46
|
-
--vaadin-charts-color-8: #00c4b4;
|
|
47
|
-
--vaadin-charts-color-9: #01a299;
|
|
48
|
-
--vaadin-charts-color-positive: var(--vaadin-charts-color-8);
|
|
49
|
-
--vaadin-charts-color-negative: var(--vaadin-charts-color-0);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
:host([theme~='classic']) {
|
|
53
|
-
--vaadin-charts-color-0: #7cb5ec;
|
|
54
|
-
--vaadin-charts-color-1: #434348;
|
|
55
|
-
--vaadin-charts-color-2: #90ed7d;
|
|
56
|
-
--vaadin-charts-color-3: #f7a35c;
|
|
57
|
-
--vaadin-charts-color-4: #8085e9;
|
|
58
|
-
--vaadin-charts-color-5: #f15c80;
|
|
59
|
-
--vaadin-charts-color-6: #e4d354;
|
|
60
|
-
--vaadin-charts-color-7: #2b908f;
|
|
61
|
-
--vaadin-charts-color-8: #f45b5b;
|
|
62
|
-
--vaadin-charts-color-9: #91e8e1;
|
|
63
|
-
}
|
|
64
|
-
`;
|
|
65
|
-
|
|
66
|
-
const chartTheme = css`
|
|
67
|
-
:host {
|
|
68
|
-
--vaadin-charts-background: var(--material-background-color);
|
|
69
|
-
--vaadin-charts-title-label: var(--material-body-text-color);
|
|
70
|
-
--vaadin-charts-axis-title: var(--material-secondary-text-color);
|
|
71
|
-
--vaadin-charts-axis-label: var(--material-secondary-text-color);
|
|
72
|
-
--vaadin-charts-data-label: var(--material-body-text-color);
|
|
73
|
-
--vaadin-charts-secondary-label: var(--material-secondary-text-color);
|
|
74
|
-
--vaadin-charts-axis-line: var(--vaadin-charts-contrast-5pct);
|
|
75
|
-
--vaadin-charts-grid-line: var(--vaadin-charts-contrast-10pct);
|
|
76
|
-
--vaadin-charts-disabled-label: var(--material-disabled-text-color);
|
|
77
|
-
--vaadin-charts-contrast: var(--material-body-text-color);
|
|
78
|
-
--vaadin-charts-contrast-5pct: var(--material-secondary-background-color);
|
|
79
|
-
--vaadin-charts-contrast-10pct: var(--material-divider-color);
|
|
80
|
-
--vaadin-charts-contrast-20pct: var(--material-disabled-color);
|
|
81
|
-
--vaadin-charts-contrast-60pct: var(--material-secondary-text-color);
|
|
82
|
-
--vaadin-charts-tooltip-background: var(--material-background-color);
|
|
83
|
-
--vaadin-charts-tooltip-border-color: var(--material-background-color);
|
|
84
|
-
--vaadin-charts-button-label: var(--material-primary-color);
|
|
85
|
-
--vaadin-charts-button-background: var(--material-background-color);
|
|
86
|
-
--vaadin-charts-button-hover-background: var(--material-secondary-background-color);
|
|
87
|
-
--vaadin-charts-button-active-label: var(--material-primary-contrast-color);
|
|
88
|
-
--vaadin-charts-button-active-background: var(--material-primary-color);
|
|
89
|
-
--vaadin-charts-xaxis-line-width: 0;
|
|
90
|
-
--vaadin-charts-tooltip-background-opacity: 1;
|
|
91
|
-
font-family: var(--material-font-family);
|
|
92
|
-
}
|
|
93
|
-
`;
|
|
94
|
-
|
|
95
|
-
registerStyles('vaadin-chart', [chartColors, chartTheme], { moduleId: 'material-chart' });
|
|
96
|
-
|
|
97
|
-
export { chartColors, chartTheme };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './vaadin-chart-series.js';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './src/vaadin-lit-chart-series.js';
|
package/vaadin-lit-chart.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './vaadin-chart.js';
|
package/vaadin-lit-chart.js
DELETED