@deephaven/chart 0.5.2-beta.0 → 0.6.1-fixed-deps.2
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/Chart.d.ts +16 -37
- package/dist/Chart.d.ts.map +1 -1
- package/dist/Chart.js +419 -454
- package/dist/Chart.js.map +1 -1
- package/dist/ChartModel.js +121 -156
- package/dist/ChartModel.js.map +1 -1
- package/dist/ChartModelFactory.js +51 -99
- package/dist/ChartModelFactory.js.map +1 -1
- package/dist/ChartTestUtils.js +76 -113
- package/dist/ChartTestUtils.js.map +1 -1
- package/dist/ChartTheme.js.map +1 -1
- package/dist/ChartUtils.js +1083 -1169
- package/dist/ChartUtils.js.map +1 -1
- package/dist/FigureChartModel.js +447 -566
- package/dist/FigureChartModel.js.map +1 -1
- package/dist/MockChartModel.js +176 -226
- package/dist/MockChartModel.js.map +1 -1
- package/dist/index.js +6 -6
- package/dist/index.js.map +1 -1
- package/dist/plotly/Plot.js +1 -1
- package/dist/plotly/Plot.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +18 -39
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ChartModelFactory.js"],"names":["dh","ChartUtils","FigureChartModel","ChartModelFactory","settings","table","copy","then","tableCopy","applyCustomColumns","customColumns","applyFilter","filter","applySort","sort","plot","Figure","create","makeFigureSettings","figure"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/ChartModelFactory.js"],"names":["dh","ChartUtils","FigureChartModel","ChartModelFactory","makeModelFromSettings","settings","table","copy","then","tableCopy","applyCustomColumns","customColumns","applyFilter","filter","applySort","sort","plot","Figure","create","makeFigureSettings","figure","makeModel"],"mappings":";;;;AAAA,OAAOA,EAAP,MAAe,uBAAf;OACOC,U;OACAC,gB;;AAEP,MAAMC,iBAAN,CAAwB;AACtB;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACoC,SAArBC,qBAAqB,CAACC,QAAD,EAAWC,KAAX,EAAkB;AAAA;AAClD;AACA;AACA;AACA;AACA,aAAOA,KAAK,CAACC,IAAN,GAAaC,IAAb,CAAkBC,SAAS,IAAI;AACpCA,QAAAA,SAAS,CAACC,kBAAV,CAA6BJ,KAAK,CAACK,aAAnC;AACAF,QAAAA,SAAS,CAACG,WAAV,CAAsBN,KAAK,CAACO,MAA5B;AACAJ,QAAAA,SAAS,CAACK,SAAV,CAAoBR,KAAK,CAACS,IAA1B;AAEA,eAAOf,EAAE,CAACgB,IAAH,CAAQC,MAAR,CAAeC,MAAf,CACLjB,UAAU,CAACkB,kBAAX,CAA8Bd,QAA9B,EAAwCI,SAAxC,CADK,EAELD,IAFK,CAEAY,MAAM,IAAI,IAAIlB,gBAAJ,CAAqBkB,MAArB,EAA6Bf,QAA7B,CAFV,CAAP;AAGD,OARM,CAAP;AALkD;AAcnD;AAED;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACwB,SAATgB,SAAS,CAAChB,QAAD,EAAWe,MAAX,EAAmB;AAAA;AACvC,aAAO,IAAIlB,gBAAJ,CAAqBkB,MAArB,EAA6Bf,QAA7B,CAAP;AADuC;AAExC;;AA7CqB;;AAgDxB,eAAeF,iBAAf","sourcesContent":["import dh from '@deephaven/jsapi-shim';\nimport ChartUtils from './ChartUtils';\nimport FigureChartModel from './FigureChartModel';\n\nclass ChartModelFactory {\n /**\n * Creates a model from the settings provided.\n * Tries to create a Figure in the API with it.\n * @param {Object} settings The chart builder settings\n * @param {boolean} settings.isLinked Whether the newly created chart should stay linked with the original table, update when filters are updated\n * @param {string[]} settings.series The column names to use for creating the series of this chart\n * @param {string} settings.sourcePanelId The panel ID the chart was created from\n * @param {string} settings.type Chart builder type, from ChartBuilder.types\n * @param {string} settings.xAxis The column name to use for the x-axis\n * @param {string[]} settings.hiddenSeries Array of hidden series names\n * @param {dh.Table} table The table to build the model for\n * @returns {Promise<FigureChartModel>} The FigureChartModel representing the figure\n */\n static async makeModelFromSettings(settings, table) {\n // Copy the table first and then re-apply the filters from the original table\n // When we add table linking we'll want to listen to the original table and update\n // the copied table with any changes that occur.\n // The table gets owned by the Figure that gets created, which closes the table\n return table.copy().then(tableCopy => {\n tableCopy.applyCustomColumns(table.customColumns);\n tableCopy.applyFilter(table.filter);\n tableCopy.applySort(table.sort);\n\n return dh.plot.Figure.create(\n ChartUtils.makeFigureSettings(settings, tableCopy)\n ).then(figure => new FigureChartModel(figure, settings));\n });\n }\n\n /**\n * Creates a model from the settings provided.\n * Tries to create a Figure in the API with it.\n * @param {Object} settings The chart builder settings\n * @param {boolean} settings.isLinked Whether the newly created chart should stay linked with the original table, update when filters are updated\n * @param {string[]} settings.series The column names to use for creating the series of this chart\n * @param {string} settings.sourcePanelId The panel ID the chart was created from\n * @param {string} settings.type Chart builder type, from ChartBuilder.types\n * @param {string} settings.xAxis The column name to use for the x-axis\n * @param {string[]} settings.hiddenSeries Array of hidden series names\n * @param {dh.Figure} figure The figure to build the model for\n * @returns {Promise<FigureChartModel>} The FigureChartModel representing the figure\n */\n static async makeModel(settings, figure) {\n return new FigureChartModel(figure, settings);\n }\n}\n\nexport default ChartModelFactory;\n"],"file":"ChartModelFactory.js"}
|
package/dist/ChartTestUtils.js
CHANGED
|
@@ -1,127 +1,90 @@
|
|
|
1
|
-
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
2
|
-
|
|
3
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
4
|
-
|
|
5
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
6
|
-
|
|
7
1
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
8
2
|
|
|
9
3
|
import dh from '@deephaven/jsapi-shim';
|
|
10
4
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
5
|
+
class ChartTestUtils {
|
|
6
|
+
static makeAxis() {
|
|
7
|
+
var {
|
|
8
|
+
label = 'Axis',
|
|
9
|
+
type = dh.plot.AxisType.X,
|
|
10
|
+
position = dh.plot.AxisPosition.BOTTOM,
|
|
11
|
+
formatType = dh.Axis.FORMAT_TYPE_NUMBER,
|
|
12
|
+
formatPattern = '###,###0.00',
|
|
13
|
+
log = false
|
|
14
|
+
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
15
|
+
return new dh.Axis({
|
|
16
|
+
label,
|
|
17
|
+
type,
|
|
18
|
+
position,
|
|
19
|
+
formatType,
|
|
20
|
+
formatPattern,
|
|
21
|
+
log
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
static makeDefaultAxes() {
|
|
26
|
+
return [ChartTestUtils.makeAxis({
|
|
27
|
+
label: ChartTestUtils.DEFAULT_X_TITLE,
|
|
28
|
+
type: dh.plot.AxisType.X
|
|
29
|
+
}), ChartTestUtils.makeAxis({
|
|
30
|
+
label: ChartTestUtils.DEFAULT_Y_TITLE,
|
|
31
|
+
type: dh.plot.AxisType.Y
|
|
32
|
+
})];
|
|
14
33
|
}
|
|
15
34
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
position = _ref$position === void 0 ? dh.plot.AxisPosition.BOTTOM : _ref$position,
|
|
26
|
-
_ref$formatType = _ref.formatType,
|
|
27
|
-
formatType = _ref$formatType === void 0 ? dh.Axis.FORMAT_TYPE_NUMBER : _ref$formatType,
|
|
28
|
-
_ref$formatPattern = _ref.formatPattern,
|
|
29
|
-
formatPattern = _ref$formatPattern === void 0 ? '###,###0.00' : _ref$formatPattern,
|
|
30
|
-
_ref$log = _ref.log,
|
|
31
|
-
log = _ref$log === void 0 ? false : _ref$log;
|
|
35
|
+
static makeSource(_ref) {
|
|
36
|
+
var {
|
|
37
|
+
axis = ChartTestUtils.makeAxis()
|
|
38
|
+
} = _ref;
|
|
39
|
+
return new dh.SeriesDataSource({
|
|
40
|
+
axis,
|
|
41
|
+
type: axis.type
|
|
42
|
+
});
|
|
43
|
+
}
|
|
32
44
|
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
log: log
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
}, {
|
|
43
|
-
key: "makeDefaultAxes",
|
|
44
|
-
value: function makeDefaultAxes() {
|
|
45
|
-
return [ChartTestUtils.makeAxis({
|
|
46
|
-
label: ChartTestUtils.DEFAULT_X_TITLE,
|
|
47
|
-
type: dh.plot.AxisType.X
|
|
48
|
-
}), ChartTestUtils.makeAxis({
|
|
49
|
-
label: ChartTestUtils.DEFAULT_Y_TITLE,
|
|
50
|
-
type: dh.plot.AxisType.Y
|
|
51
|
-
})];
|
|
52
|
-
}
|
|
53
|
-
}, {
|
|
54
|
-
key: "makeSource",
|
|
55
|
-
value: function makeSource(_ref2) {
|
|
56
|
-
var _ref2$axis = _ref2.axis,
|
|
57
|
-
axis = _ref2$axis === void 0 ? ChartTestUtils.makeAxis() : _ref2$axis;
|
|
58
|
-
return new dh.SeriesDataSource({
|
|
59
|
-
axis: axis,
|
|
60
|
-
type: axis.type
|
|
61
|
-
});
|
|
62
|
-
}
|
|
63
|
-
}, {
|
|
64
|
-
key: "makeDefaultSources",
|
|
65
|
-
value: function makeDefaultSources() {
|
|
66
|
-
var axes = ChartTestUtils.makeDefaultAxes();
|
|
67
|
-
return axes.map(function (axis) {
|
|
68
|
-
return ChartTestUtils.makeSource({
|
|
69
|
-
axis: axis
|
|
70
|
-
});
|
|
71
|
-
});
|
|
72
|
-
}
|
|
73
|
-
}, {
|
|
74
|
-
key: "makeSeries",
|
|
75
|
-
value: function makeSeries() {
|
|
76
|
-
var _ref3 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
77
|
-
_ref3$name = _ref3.name,
|
|
78
|
-
name = _ref3$name === void 0 ? ChartTestUtils.DEFAULT_SERIES_NAME : _ref3$name,
|
|
79
|
-
_ref3$plotStyle = _ref3.plotStyle,
|
|
80
|
-
plotStyle = _ref3$plotStyle === void 0 ? dh.plot.SeriesPlotStyle.SCATTER : _ref3$plotStyle,
|
|
81
|
-
_ref3$sources = _ref3.sources,
|
|
82
|
-
sources = _ref3$sources === void 0 ? ChartTestUtils.makeDefaultSources() : _ref3$sources,
|
|
83
|
-
_ref3$lineColor = _ref3.lineColor,
|
|
84
|
-
lineColor = _ref3$lineColor === void 0 ? null : _ref3$lineColor,
|
|
85
|
-
_ref3$shapeColor = _ref3.shapeColor,
|
|
86
|
-
shapeColor = _ref3$shapeColor === void 0 ? null : _ref3$shapeColor;
|
|
45
|
+
static makeDefaultSources() {
|
|
46
|
+
var axes = ChartTestUtils.makeDefaultAxes();
|
|
47
|
+
return axes.map(axis => ChartTestUtils.makeSource({
|
|
48
|
+
axis
|
|
49
|
+
}));
|
|
50
|
+
}
|
|
87
51
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
_ref4$axes = _ref4.axes,
|
|
99
|
-
axes = _ref4$axes === void 0 ? ChartTestUtils.makeDefaultAxes() : _ref4$axes;
|
|
52
|
+
static makeSeries() {
|
|
53
|
+
var {
|
|
54
|
+
name = ChartTestUtils.DEFAULT_SERIES_NAME,
|
|
55
|
+
plotStyle = dh.plot.SeriesPlotStyle.SCATTER,
|
|
56
|
+
sources = ChartTestUtils.makeDefaultSources(),
|
|
57
|
+
lineColor = null,
|
|
58
|
+
shapeColor = null
|
|
59
|
+
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
60
|
+
return new dh.Series(name, plotStyle, sources, lineColor, shapeColor);
|
|
61
|
+
}
|
|
100
62
|
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
_ref5$charts = _ref5.charts,
|
|
114
|
-
charts = _ref5$charts === void 0 ? [ChartTestUtils.makeChart()] : _ref5$charts;
|
|
63
|
+
static makeChart() {
|
|
64
|
+
var {
|
|
65
|
+
title = ChartTestUtils.DEFAULT_CHART_TITLE,
|
|
66
|
+
series = [ChartTestUtils.makeSeries()],
|
|
67
|
+
axes = ChartTestUtils.makeDefaultAxes()
|
|
68
|
+
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
69
|
+
return new dh.Chart({
|
|
70
|
+
title,
|
|
71
|
+
series,
|
|
72
|
+
axes
|
|
73
|
+
});
|
|
74
|
+
}
|
|
115
75
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
}
|
|
121
|
-
|
|
76
|
+
static makeFigure() {
|
|
77
|
+
var {
|
|
78
|
+
title = 'Figure',
|
|
79
|
+
charts = [ChartTestUtils.makeChart()]
|
|
80
|
+
} = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
81
|
+
return new dh.plot.Figure({
|
|
82
|
+
title,
|
|
83
|
+
charts
|
|
84
|
+
});
|
|
85
|
+
}
|
|
122
86
|
|
|
123
|
-
|
|
124
|
-
}();
|
|
87
|
+
}
|
|
125
88
|
|
|
126
89
|
_defineProperty(ChartTestUtils, "DEFAULT_CHART_TITLE", 'Chart Title');
|
|
127
90
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ChartTestUtils.js"],"names":["dh","ChartTestUtils","label","type","plot","AxisType","X","position","AxisPosition","BOTTOM","formatType","Axis","FORMAT_TYPE_NUMBER","formatPattern","log","
|
|
1
|
+
{"version":3,"sources":["../src/ChartTestUtils.js"],"names":["dh","ChartTestUtils","makeAxis","label","type","plot","AxisType","X","position","AxisPosition","BOTTOM","formatType","Axis","FORMAT_TYPE_NUMBER","formatPattern","log","makeDefaultAxes","DEFAULT_X_TITLE","DEFAULT_Y_TITLE","Y","makeSource","axis","SeriesDataSource","makeDefaultSources","axes","map","makeSeries","name","DEFAULT_SERIES_NAME","plotStyle","SeriesPlotStyle","SCATTER","sources","lineColor","shapeColor","Series","makeChart","title","DEFAULT_CHART_TITLE","series","Chart","makeFigure","charts","Figure"],"mappings":"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","sourcesContent":["import dh from '@deephaven/jsapi-shim';\n\nclass ChartTestUtils {\n static DEFAULT_CHART_TITLE = 'Chart Title';\n\n static DEFAULT_X_TITLE = 'X Axis';\n\n static DEFAULT_Y_TITLE = 'Y Axis';\n\n static DEFAULT_SERIES_NAME = 'MySeries';\n\n static makeAxis({\n label = 'Axis',\n type = dh.plot.AxisType.X,\n position = dh.plot.AxisPosition.BOTTOM,\n formatType = dh.Axis.FORMAT_TYPE_NUMBER,\n formatPattern = '###,###0.00',\n log = false,\n } = {}) {\n return new dh.Axis({\n label,\n type,\n position,\n formatType,\n formatPattern,\n log,\n });\n }\n\n static makeDefaultAxes() {\n return [\n ChartTestUtils.makeAxis({\n label: ChartTestUtils.DEFAULT_X_TITLE,\n type: dh.plot.AxisType.X,\n }),\n ChartTestUtils.makeAxis({\n label: ChartTestUtils.DEFAULT_Y_TITLE,\n type: dh.plot.AxisType.Y,\n }),\n ];\n }\n\n static makeSource({ axis = ChartTestUtils.makeAxis() }) {\n return new dh.SeriesDataSource({ axis, type: axis.type });\n }\n\n static makeDefaultSources() {\n const axes = ChartTestUtils.makeDefaultAxes();\n return axes.map(axis => ChartTestUtils.makeSource({ axis }));\n }\n\n static makeSeries({\n name = ChartTestUtils.DEFAULT_SERIES_NAME,\n plotStyle = dh.plot.SeriesPlotStyle.SCATTER,\n sources = ChartTestUtils.makeDefaultSources(),\n lineColor = null,\n shapeColor = null,\n } = {}) {\n return new dh.Series(name, plotStyle, sources, lineColor, shapeColor);\n }\n\n static makeChart({\n title = ChartTestUtils.DEFAULT_CHART_TITLE,\n series = [ChartTestUtils.makeSeries()],\n axes = ChartTestUtils.makeDefaultAxes(),\n } = {}) {\n return new dh.Chart({ title, series, axes });\n }\n\n static makeFigure({\n title = 'Figure',\n charts = [ChartTestUtils.makeChart()],\n } = {}) {\n return new dh.plot.Figure({ title, charts });\n }\n}\n\nexport default ChartTestUtils;\n"],"file":"ChartTestUtils.js"}
|
package/dist/ChartTheme.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ChartTheme.js"],"names":["ChartTheme","Object","freeze","paper_bgcolor","plot_bgcolor","title_color","colorway","gridcolor","linecolor","zerolinecolor","activecolor","rangebgcolor","area_color","trend_color","line_color","error_band_line_color","error_band_fill_color","ohlc_increasing","ohlc_decreasing"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/ChartTheme.js"],"names":["ChartTheme","Object","freeze","paper_bgcolor","plot_bgcolor","title_color","colorway","gridcolor","linecolor","zerolinecolor","activecolor","rangebgcolor","area_color","trend_color","line_color","error_band_line_color","error_band_fill_color","ohlc_increasing","ohlc_decreasing"],"mappings":"OAAOA,U;AAEP,eAAeC,MAAM,CAACC,MAAP,CAAc;AAC3BC,EAAAA,aAAa,EAAEH,UAAU,CAAC,eAAD,CADE;AAE3BI,EAAAA,YAAY,EAAEJ,UAAU,CAAC,cAAD,CAFG;AAG3BK,EAAAA,WAAW,EAAEL,UAAU,CAAC,aAAD,CAHI;AAI3BM,EAAAA,QAAQ,EAAEN,UAAU,CAACM,QAJM;AAK3BC,EAAAA,SAAS,EAAEP,UAAU,CAACO,SALK;AAM3BC,EAAAA,SAAS,EAAER,UAAU,CAACQ,SANK;AAO3BC,EAAAA,aAAa,EAAET,UAAU,CAACS,aAPC;AAQ3BC,EAAAA,WAAW,EAAEV,UAAU,CAACU,WARG;AAS3BC,EAAAA,YAAY,EAAEX,UAAU,CAACW,YATE;AAU3BC,EAAAA,UAAU,EAAEZ,UAAU,CAAC,YAAD,CAVK;AAW3Ba,EAAAA,WAAW,EAAEb,UAAU,CAAC,aAAD,CAXI;AAY3Bc,EAAAA,UAAU,EAAEd,UAAU,CAAC,YAAD,CAZK;AAa3Be,EAAAA,qBAAqB,EAAEf,UAAU,CAAC,uBAAD,CAbN;AAc3BgB,EAAAA,qBAAqB,EAAEhB,UAAU,CAAC,uBAAD,CAdN;AAe3BiB,EAAAA,eAAe,EAAEjB,UAAU,CAAC,iBAAD,CAfA;AAgB3BkB,EAAAA,eAAe,EAAElB,UAAU,CAAC,iBAAD;AAhBA,CAAd,CAAf","sourcesContent":["import ChartTheme from './ChartTheme.module.scss';\n\nexport default Object.freeze({\n paper_bgcolor: ChartTheme['paper-bgcolor'],\n plot_bgcolor: ChartTheme['plot-bgcolor'],\n title_color: ChartTheme['title-color'],\n colorway: ChartTheme.colorway,\n gridcolor: ChartTheme.gridcolor,\n linecolor: ChartTheme.linecolor,\n zerolinecolor: ChartTheme.zerolinecolor,\n activecolor: ChartTheme.activecolor,\n rangebgcolor: ChartTheme.rangebgcolor,\n area_color: ChartTheme['area-color'],\n trend_color: ChartTheme['trend-color'],\n line_color: ChartTheme['line-color'],\n error_band_line_color: ChartTheme['error-band-line-color'],\n error_band_fill_color: ChartTheme['error-band-fill-color'],\n ohlc_increasing: ChartTheme['ohlc-increasing'],\n ohlc_decreasing: ChartTheme['ohlc-decreasing'],\n});\n"],"file":"ChartTheme.js"}
|