@hpcc-js/chart 2.86.0 → 3.2.0
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/index.js +323 -11790
- package/dist/index.js.map +7 -1
- package/package.json +32 -36
- package/src/Area.ts +1 -1
- package/src/Axis.ts +91 -60
- package/src/Bar.ts +1 -1
- package/src/Bubble.ts +18 -13
- package/src/BubbleXY.ts +1 -1
- package/src/Bullet.ts +21 -11
- package/src/Column.ts +13 -13
- package/src/Contour.ts +1 -1
- package/src/D3Cloud.ts +13 -13
- package/src/Gantt.ts +1 -1
- package/src/Gauge.ts +30 -28
- package/src/HalfPie.ts +1 -1
- package/src/Heat.ts +1 -1
- package/src/HexBin.ts +16 -11
- package/src/Line.ts +1 -1
- package/src/Pie.ts +31 -27
- package/src/QuarterPie.ts +1 -1
- package/src/Radar.ts +15 -15
- package/src/RadialBar.ts +18 -13
- package/src/Scatter.ts +36 -25
- package/src/StatChart.ts +11 -3
- package/src/Step.ts +1 -1
- package/src/WordCloud.ts +56 -51
- package/src/XYAxis.ts +4 -4
- package/src/__package__.ts +2 -2
- package/src/index.ts +27 -27
- package/types/Area.d.ts +1 -2
- package/types/Axis.d.ts +69 -120
- package/types/Bar.d.ts +1 -2
- package/types/Bubble.d.ts +13 -16
- package/types/BubbleXY.d.ts +1 -2
- package/types/Bullet.d.ts +13 -7
- package/types/Column.d.ts +9 -10
- package/types/Contour.d.ts +1 -2
- package/types/D3Cloud.d.ts +0 -1
- package/types/Gantt.d.ts +1 -2
- package/types/Gauge.d.ts +19 -11
- package/types/HalfPie.d.ts +1 -2
- package/types/Heat.d.ts +1 -2
- package/types/HexBin.d.ts +13 -18
- package/types/Line.d.ts +1 -2
- package/types/Pie.d.ts +23 -35
- package/types/QuarterPie.d.ts +1 -2
- package/types/QuartileCandlestick.d.ts +0 -1
- package/types/Radar.d.ts +10 -11
- package/types/RadialBar.d.ts +10 -11
- package/types/Scatter.d.ts +29 -51
- package/types/StatChart.d.ts +3 -3
- package/types/Step.d.ts +1 -2
- package/types/Summary.d.ts +0 -1
- package/types/SummaryC.d.ts +0 -1
- package/types/WordCloud.d.ts +50 -110
- package/types/XYAxis.d.ts +3 -4
- package/types/__package__.d.ts +2 -3
- package/types/index.d.ts +27 -28
- package/dist/index.es6.js +0 -11759
- package/dist/index.es6.js.map +0 -1
- package/dist/index.min.js +0 -2
- package/dist/index.min.js.map +0 -1
- package/types/Area.d.ts.map +0 -1
- package/types/Axis.d.ts.map +0 -1
- package/types/Bar.d.ts.map +0 -1
- package/types/Bubble.d.ts.map +0 -1
- package/types/BubbleXY.d.ts.map +0 -1
- package/types/Bullet.d.ts.map +0 -1
- package/types/Column.d.ts.map +0 -1
- package/types/Contour.d.ts.map +0 -1
- package/types/D3Cloud.d.ts.map +0 -1
- package/types/Gantt.d.ts.map +0 -1
- package/types/Gauge.d.ts.map +0 -1
- package/types/HalfPie.d.ts.map +0 -1
- package/types/Heat.d.ts.map +0 -1
- package/types/HexBin.d.ts.map +0 -1
- package/types/Line.d.ts.map +0 -1
- package/types/Pie.d.ts.map +0 -1
- package/types/QuarterPie.d.ts.map +0 -1
- package/types/QuartileCandlestick.d.ts.map +0 -1
- package/types/Radar.d.ts.map +0 -1
- package/types/RadialBar.d.ts.map +0 -1
- package/types/Scatter.d.ts.map +0 -1
- package/types/StatChart.d.ts.map +0 -1
- package/types/Step.d.ts.map +0 -1
- package/types/Summary.d.ts.map +0 -1
- package/types/SummaryC.d.ts.map +0 -1
- package/types/WordCloud.d.ts.map +0 -1
- package/types/XYAxis.d.ts.map +0 -1
- package/types/__package__.d.ts.map +0 -1
- package/types/__tests__/heat.d.ts +0 -10
- package/types/__tests__/heat.d.ts.map +0 -1
- package/types/__tests__/index.d.ts +0 -2
- package/types/__tests__/index.d.ts.map +0 -1
- package/types/__tests__/pie.d.ts +0 -5
- package/types/__tests__/pie.d.ts.map +0 -1
- package/types/__tests__/stat.d.ts +0 -5
- package/types/__tests__/stat.d.ts.map +0 -1
- package/types/__tests__/test3.d.ts +0 -9
- package/types/__tests__/test3.d.ts.map +0 -1
- package/types/index.d.ts.map +0 -1
- package/types/test.d.ts +0 -10
- package/types/test.d.ts.map +0 -1
- package/types-3.4/Area.d.ts +0 -5
- package/types-3.4/Axis.d.ts +0 -180
- package/types-3.4/Bar.d.ts +0 -5
- package/types-3.4/Bubble.d.ts +0 -32
- package/types-3.4/BubbleXY.d.ts +0 -6
- package/types-3.4/Bullet.d.ts +0 -19
- package/types-3.4/Column.d.ts +0 -70
- package/types-3.4/Contour.d.ts +0 -30
- package/types-3.4/D3Cloud.d.ts +0 -2
- package/types-3.4/Gantt.d.ts +0 -5
- package/types-3.4/Gauge.d.ts +0 -47
- package/types-3.4/HalfPie.d.ts +0 -7
- package/types-3.4/Heat.d.ts +0 -32
- package/types-3.4/HexBin.d.ts +0 -34
- package/types-3.4/Line.d.ts +0 -6
- package/types-3.4/Pie.d.ts +0 -95
- package/types-3.4/QuarterPie.d.ts +0 -12
- package/types-3.4/QuartileCandlestick.d.ts +0 -57
- package/types-3.4/Radar.d.ts +0 -47
- package/types-3.4/RadialBar.d.ts +0 -44
- package/types-3.4/Scatter.d.ts +0 -80
- package/types-3.4/StatChart.d.ts +0 -70
- package/types-3.4/Step.d.ts +0 -5
- package/types-3.4/Summary.d.ts +0 -105
- package/types-3.4/SummaryC.d.ts +0 -69
- package/types-3.4/WordCloud.d.ts +0 -130
- package/types-3.4/XYAxis.d.ts +0 -181
- package/types-3.4/__package__.d.ts +0 -4
- package/types-3.4/__tests__/heat.d.ts +0 -10
- package/types-3.4/__tests__/index.d.ts +0 -2
- package/types-3.4/__tests__/pie.d.ts +0 -5
- package/types-3.4/__tests__/stat.d.ts +0 -5
- package/types-3.4/__tests__/test3.d.ts +0 -9
- package/types-3.4/index.d.ts +0 -28
- package/types-3.4/test.d.ts +0 -10
package/src/HexBin.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { I2DAggrChart, ITooltip } from "@hpcc-js/api";
|
|
|
2
2
|
import { InputField } from "@hpcc-js/common";
|
|
3
3
|
import { extent as d3Extent, max as d3Max, min as d3Min } from "d3-array";
|
|
4
4
|
import { hexbin as d3HexBin } from "d3-hexbin";
|
|
5
|
-
import { XYAxis } from "./XYAxis";
|
|
5
|
+
import { XYAxis } from "./XYAxis.ts";
|
|
6
6
|
|
|
7
7
|
import "../src/HexBin.css";
|
|
8
8
|
|
|
@@ -118,21 +118,26 @@ export class HexBin extends XYAxis {
|
|
|
118
118
|
dblclick(row: object[], column, selected) {
|
|
119
119
|
// console.log("Click: " + JSON.stringify(row) + ", " + column + ", " + selected);
|
|
120
120
|
}
|
|
121
|
+
}
|
|
122
|
+
HexBin.prototype._class += " chart_HexBin";
|
|
123
|
+
HexBin.prototype.implements(I2DAggrChart.prototype);
|
|
124
|
+
HexBin.prototype.implements(ITooltip.prototype);
|
|
121
125
|
|
|
126
|
+
export interface HexBin {
|
|
122
127
|
// ITooltip
|
|
123
128
|
tooltip;
|
|
124
|
-
tooltipHTML
|
|
125
|
-
tooltipFormat
|
|
126
|
-
tooltipValueFormat
|
|
127
|
-
tooltipValueFormat_default
|
|
129
|
+
tooltipHTML(_): string;
|
|
130
|
+
tooltipFormat(_): string;
|
|
131
|
+
tooltipValueFormat(_): string;
|
|
132
|
+
tooltipValueFormat_default(_): string;
|
|
128
133
|
|
|
129
|
-
paletteID
|
|
130
|
-
|
|
131
|
-
|
|
134
|
+
paletteID(): string;
|
|
135
|
+
paletteID(_: string): this;
|
|
136
|
+
useClonedPalette(): boolean;
|
|
137
|
+
useClonedPalette(_: boolean): this;
|
|
138
|
+
binSize(): number;
|
|
139
|
+
binSize(_: number): this;
|
|
132
140
|
}
|
|
133
|
-
HexBin.prototype._class += " chart_HexBin";
|
|
134
|
-
HexBin.prototype.implements(I2DAggrChart.prototype);
|
|
135
|
-
HexBin.prototype.implements(ITooltip.prototype);
|
|
136
141
|
|
|
137
142
|
HexBin.prototype.publish("paletteID", "Blues", "set", "Color palette for this widget", HexBin.prototype._palette.switch(), { tags: ["Basic", "Shared"] });
|
|
138
143
|
HexBin.prototype.publish("useClonedPalette", false, "boolean", "Enable or disable using a cloned palette", null, { tags: ["Intermediate", "Shared"] });
|
package/src/Line.ts
CHANGED
package/src/Pie.ts
CHANGED
|
@@ -437,38 +437,12 @@ export class Pie extends SVGWidget {
|
|
|
437
437
|
})
|
|
438
438
|
;
|
|
439
439
|
}
|
|
440
|
-
|
|
441
|
-
paletteID: (_?: string) => string | Pie;
|
|
442
|
-
useClonedPalette: (_?: boolean) => boolean | Pie;
|
|
443
|
-
outerText: (_?: boolean) => boolean | Pie;
|
|
444
|
-
innerRadius: { (): number; (_: number): Pie; };
|
|
445
|
-
innerRadius_exists: () => boolean;
|
|
446
|
-
|
|
447
|
-
// I2DChart
|
|
448
|
-
_palette;
|
|
449
|
-
fillColor: (row: any[], column: string, value: number) => string;
|
|
450
|
-
textColor: (row: any[], column: string, value: number) => string;
|
|
451
|
-
click: (row, column, selected) => void;
|
|
452
|
-
dblclick: (row, column, selected) => void;
|
|
453
|
-
|
|
454
|
-
// ITooltip
|
|
455
|
-
tooltip;
|
|
456
|
-
tooltipHTML: (_) => string;
|
|
457
|
-
tooltipFormat: (_) => string;
|
|
458
|
-
tooltipStyle: () => "default" | "none" | "series-table";
|
|
459
|
-
tooltipTick: { (): boolean; (_: boolean): Pie; };
|
|
460
|
-
tooltipTick_default: { (): boolean; (_: boolean): Pie; };
|
|
461
|
-
tooltipOffset: { (): number; (_: number): Pie; };
|
|
462
|
-
tooltipOffset_default: { (): number; (_: number): Pie; };
|
|
463
|
-
|
|
464
|
-
// SimpleSelectionMixin
|
|
465
|
-
_selection: Utility.SimpleSelection;
|
|
466
440
|
}
|
|
467
|
-
|
|
468
441
|
Pie.prototype._class += " chart_Pie";
|
|
469
442
|
Pie.prototype.implements(I2DChart.prototype);
|
|
470
443
|
Pie.prototype.implements(ITooltip.prototype);
|
|
471
444
|
Pie.prototype.mixin(Utility.SimpleSelectionMixin);
|
|
445
|
+
|
|
472
446
|
export interface Pie {
|
|
473
447
|
showSeriesValue(): boolean;
|
|
474
448
|
showSeriesValue(_: boolean): this;
|
|
@@ -488,6 +462,36 @@ export interface Pie {
|
|
|
488
462
|
showLabels(_: boolean): this;
|
|
489
463
|
sortDataByValue(): "none" | "ascending" | "descending";
|
|
490
464
|
sortDataByValue(_: "none" | "ascending" | "descending"): this;
|
|
465
|
+
|
|
466
|
+
paletteID(_?: string): string | Pie;
|
|
467
|
+
useClonedPalette(_?: boolean): boolean | Pie;
|
|
468
|
+
outerText(_?: boolean): boolean | Pie;
|
|
469
|
+
innerRadius(): number;
|
|
470
|
+
innerRadius_exists(): boolean;
|
|
471
|
+
|
|
472
|
+
// I2DChart
|
|
473
|
+
_palette;
|
|
474
|
+
fillColor(row: any[], column: string, value: number): string;
|
|
475
|
+
textColor(row: any[], column: string, value: number): string;
|
|
476
|
+
click(row, column, selected): void;
|
|
477
|
+
dblclick(row, column, selected): void;
|
|
478
|
+
|
|
479
|
+
// ITooltip
|
|
480
|
+
tooltip;
|
|
481
|
+
tooltipHTML(_): string;
|
|
482
|
+
tooltipFormat(_): string;
|
|
483
|
+
tooltipStyle(): "default" | "none" | "series-table";
|
|
484
|
+
tooltipTick(): boolean;
|
|
485
|
+
tooltipTick(_: boolean): Pie;
|
|
486
|
+
tooltipTick_default(): boolean;
|
|
487
|
+
tooltipTick_default(_: boolean): Pie;
|
|
488
|
+
tooltipOffset(): number;
|
|
489
|
+
tooltipOffset(_: number): Pie;
|
|
490
|
+
tooltipOffset_default(): number;
|
|
491
|
+
tooltipOffset_default(_: number): Pie;
|
|
492
|
+
|
|
493
|
+
// SimpleSelectionMixin
|
|
494
|
+
_selection: Utility.SimpleSelection;
|
|
491
495
|
}
|
|
492
496
|
Pie.prototype.publish("showLabels", true, "boolean", "If true, wedge labels will display");
|
|
493
497
|
Pie.prototype.publish("showSeriesValue", false, "boolean", "Append data series value next to label", null, { disable: w => !w.showLabels() });
|
package/src/QuarterPie.ts
CHANGED
package/src/Radar.ts
CHANGED
|
@@ -282,21 +282,6 @@ export class Radar extends SVGWidget {
|
|
|
282
282
|
}
|
|
283
283
|
return inside;
|
|
284
284
|
}
|
|
285
|
-
|
|
286
|
-
// INDChart
|
|
287
|
-
_palette;
|
|
288
|
-
fillColor: (row, column, value) => string;
|
|
289
|
-
strokeColor: (row, column, value) => string;
|
|
290
|
-
textColor: (row, column, value) => string;
|
|
291
|
-
click: (row, column, selected) => void;
|
|
292
|
-
dblclick: (row, column, selected) => void;
|
|
293
|
-
|
|
294
|
-
// ITooltip
|
|
295
|
-
tooltip;
|
|
296
|
-
tooltipHTML: (_) => string;
|
|
297
|
-
tooltipFormat: (_) => string;
|
|
298
|
-
|
|
299
|
-
_selection;
|
|
300
285
|
}
|
|
301
286
|
Radar.prototype._class += " chart_Radar";
|
|
302
287
|
Radar.prototype.implements(INDChart.prototype);
|
|
@@ -324,6 +309,21 @@ export interface Radar {
|
|
|
324
309
|
pointShape(_: string): this;
|
|
325
310
|
pointSize(): number;
|
|
326
311
|
pointSize(_: number): this;
|
|
312
|
+
|
|
313
|
+
// INDChart
|
|
314
|
+
_palette;
|
|
315
|
+
fillColor(row, column, value): string;
|
|
316
|
+
strokeColor(row, column, value): string;
|
|
317
|
+
textColor(row, column, value): string;
|
|
318
|
+
click(row, column, selected): void;
|
|
319
|
+
dblclick(row, column, selected): void;
|
|
320
|
+
|
|
321
|
+
// ITooltip
|
|
322
|
+
tooltip;
|
|
323
|
+
tooltipHTML(_): string;
|
|
324
|
+
tooltipFormat(_): string;
|
|
325
|
+
|
|
326
|
+
_selection;
|
|
327
327
|
}
|
|
328
328
|
|
|
329
329
|
Radar.prototype.publish("paletteID", "default", "set", "Color palette for this widget", Radar.prototype._palette.switch());
|
package/src/RadialBar.ts
CHANGED
|
@@ -168,24 +168,12 @@ export class RadialBar extends SVGWidget {
|
|
|
168
168
|
return degrees * Math.PI / 180;
|
|
169
169
|
}
|
|
170
170
|
|
|
171
|
-
// INDChart
|
|
172
|
-
_palette;
|
|
173
|
-
fillColor: (row, column, value) => string;
|
|
174
|
-
strokeColor: (row, column, value) => string;
|
|
175
|
-
textColor: (row, column, value) => string;
|
|
176
|
-
click: (row, column, selected) => void;
|
|
177
|
-
dblclick: (row, column, selected) => void;
|
|
178
|
-
|
|
179
|
-
// ITooltip
|
|
180
|
-
tooltip;
|
|
181
|
-
tooltipHTML: (_) => string;
|
|
182
|
-
tooltipFormat: (_) => string;
|
|
183
|
-
_selection;
|
|
184
171
|
}
|
|
185
172
|
RadialBar.prototype._class += " chart_RadialBar";
|
|
186
173
|
RadialBar.prototype.implements(INDChart.prototype);
|
|
187
174
|
RadialBar.prototype.implements(ITooltip.prototype);
|
|
188
175
|
RadialBar.prototype.mixin(Utility.SimpleSelectionMixin);
|
|
176
|
+
|
|
189
177
|
export interface RadialBar {
|
|
190
178
|
paletteID(): string;
|
|
191
179
|
paletteID(_: string): this;
|
|
@@ -202,7 +190,24 @@ export interface RadialBar {
|
|
|
202
190
|
transitionDelay(_: number): this;
|
|
203
191
|
transitionDuration(): number;
|
|
204
192
|
transitionDuration(_: number): this;
|
|
193
|
+
|
|
194
|
+
// INDChart
|
|
195
|
+
_palette;
|
|
196
|
+
fillColor(row, column, value): string;
|
|
197
|
+
strokeColor(row, column, value): string;
|
|
198
|
+
textColor(row, column, value): string;
|
|
199
|
+
click(row, column, selected): void;
|
|
200
|
+
dblclick(row, column, selected): void;
|
|
201
|
+
|
|
202
|
+
// ITooltip
|
|
203
|
+
tooltip;
|
|
204
|
+
tooltipHTML(_): string;
|
|
205
|
+
tooltipFormat(_): string;
|
|
206
|
+
|
|
207
|
+
// SimpleSelectionMixin
|
|
208
|
+
_selection;
|
|
205
209
|
}
|
|
210
|
+
|
|
206
211
|
RadialBar.prototype.publish("paletteID", "default", "set", "Color palette for this widget", RadialBar.prototype._palette.switch());
|
|
207
212
|
RadialBar.prototype.publish("tickCount", 10, "number", "Number of ticks to display");
|
|
208
213
|
RadialBar.prototype.publish("domainPadding", 0.25, "number", "Padding between chart edge and container edge (0..1)");
|
package/src/Scatter.ts
CHANGED
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
curveMonotoneX as d3CurveMonotoneX, curveNatural as d3CurveNatural, curveStep as d3CurveStep, curveStepAfter as d3CurveStepAfter, curveStepBefore as d3CurveStepBefore,
|
|
10
10
|
line as d3Line
|
|
11
11
|
} from "d3-shape";
|
|
12
|
-
import { XYAxis } from "./XYAxis";
|
|
12
|
+
import { XYAxis } from "./XYAxis.ts";
|
|
13
13
|
|
|
14
14
|
import "../src/Scatter.css";
|
|
15
15
|
|
|
@@ -321,35 +321,13 @@ export class Scatter extends XYAxis {
|
|
|
321
321
|
exit(domNode, element) {
|
|
322
322
|
super.exit(domNode, element);
|
|
323
323
|
}
|
|
324
|
-
|
|
325
|
-
paletteID: { (): string; (_: string): Scatter; };
|
|
326
|
-
useClonedPalette: { (): boolean; (_: boolean): Scatter; };
|
|
327
|
-
pointSizeScale: { (): string; (_: string): Scatter; };
|
|
328
|
-
pointShape: { (): string; (_: string): Scatter; };
|
|
329
|
-
pointSize: { (): number; (_: number): Scatter; };
|
|
330
|
-
interpolate: { (): string; (_: string): Scatter; };
|
|
331
|
-
interpolate_default: { (): string; (_: string): Scatter; };
|
|
332
|
-
interpolateFill: { (): boolean; (_: boolean): Scatter; };
|
|
333
|
-
interpolateFill_default: { (): boolean; (_: boolean): Scatter; };
|
|
334
|
-
interpolateFillOpacity: { (): number; (_: number): Scatter; };
|
|
335
|
-
|
|
336
|
-
// INDChart
|
|
337
|
-
_palette;
|
|
338
|
-
fillColor: (row, column, value, origRow) => string;
|
|
339
|
-
strokeColor: (row, column, value, origRow) => string;
|
|
340
|
-
textColor: (row, column, value, origRow) => string;
|
|
341
|
-
dblclick: (row, column, selected) => void;
|
|
342
|
-
|
|
343
|
-
// ITooltip
|
|
344
|
-
tooltip;
|
|
345
|
-
tooltipHTML: (_) => string;
|
|
346
|
-
tooltipFormat: (_) => string;
|
|
347
|
-
tooltipStyle: () => "default" | "none" | "series-table";
|
|
348
324
|
}
|
|
349
325
|
Scatter.prototype._class += " chart_Scatter";
|
|
350
326
|
Scatter.prototype.implements(INDChart.prototype);
|
|
351
327
|
Scatter.prototype.implements(ITooltip.prototype);
|
|
328
|
+
|
|
352
329
|
export interface Scatter {
|
|
330
|
+
|
|
353
331
|
valueAnchor(): string;
|
|
354
332
|
valueAnchor(_: string): this;
|
|
355
333
|
valueBaseline(): string;
|
|
@@ -360,6 +338,39 @@ export interface Scatter {
|
|
|
360
338
|
pointDarken(_: boolean): this;
|
|
361
339
|
interpolateDarken(): boolean;
|
|
362
340
|
interpolateDarken(_: boolean): this;
|
|
341
|
+
|
|
342
|
+
paletteID(): string;
|
|
343
|
+
paletteID(_: string): this;
|
|
344
|
+
useClonedPalette(): boolean;
|
|
345
|
+
useClonedPalette(_: boolean): this;
|
|
346
|
+
pointSizeScale(): string;
|
|
347
|
+
pointSizeScale(_: string): this;
|
|
348
|
+
pointShape(): string;
|
|
349
|
+
pointShape(_: string): this;
|
|
350
|
+
pointSize(): number;
|
|
351
|
+
pointSize(_: number): this;
|
|
352
|
+
interpolate(): string;
|
|
353
|
+
interpolate(_: string): this;
|
|
354
|
+
interpolate_default(): string;
|
|
355
|
+
interpolate_default(_: string): this;
|
|
356
|
+
interpolateFill(): boolean;
|
|
357
|
+
interpolateFill(_: boolean): this;
|
|
358
|
+
interpolateFill_default(): boolean;
|
|
359
|
+
interpolateFill_default(_: boolean): this;
|
|
360
|
+
interpolateFillOpacity(): number;
|
|
361
|
+
interpolateFillOpacity(_: number): this;
|
|
362
|
+
|
|
363
|
+
// INDChart
|
|
364
|
+
fillColor(row, column, value, origRow): string;
|
|
365
|
+
strokeColor(row, column, value, origRow): string;
|
|
366
|
+
textColor(row, column, value, origRow): string;
|
|
367
|
+
dblclick(row, column, selected): void;
|
|
368
|
+
|
|
369
|
+
// ITooltip
|
|
370
|
+
tooltip;
|
|
371
|
+
tooltipHTML(_): string;
|
|
372
|
+
tooltipFormat(_): string;
|
|
373
|
+
tooltipStyle(): "default" | "none" | "series-table";
|
|
363
374
|
}
|
|
364
375
|
Scatter.prototype.publish("paletteID", "default", "set", "Color palette for this widget", Scatter.prototype._palette.switch(), { tags: ["Basic", "Shared"] });
|
|
365
376
|
Scatter.prototype.publish("pointSizeScale", "linear", "set", "pointSizeScale", ["linear", "pow", "log", "sqrt"]);
|
package/src/StatChart.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { format as d3Format, HTMLWidget, Palette } from "@hpcc-js/common";
|
|
2
|
-
import { QuartileCandlestick } from "./QuartileCandlestick";
|
|
3
|
-
import { Scatter } from "./Scatter";
|
|
2
|
+
import { QuartileCandlestick } from "./QuartileCandlestick.ts";
|
|
3
|
+
import { Scatter } from "./Scatter.ts";
|
|
4
4
|
|
|
5
5
|
const rainbow = Palette.rainbow("Blues");
|
|
6
6
|
const palette = Palette.ordinal("Quartile", [rainbow(100, 0, 100), rainbow(50, 0, 100), rainbow(50, 0, 100), rainbow(75, 0, 100)]);
|
|
@@ -221,8 +221,16 @@ export class StatChart extends HTMLWidget {
|
|
|
221
221
|
this.updateScatter();
|
|
222
222
|
this.updateCandle();
|
|
223
223
|
}
|
|
224
|
+
|
|
225
|
+
exit(domNode, element) {
|
|
226
|
+
this._bellCurve.target(null);
|
|
227
|
+
this._candle.target(null);
|
|
228
|
+
this._selectElement.remove();
|
|
229
|
+
|
|
230
|
+
super.exit(domNode, element);
|
|
231
|
+
}
|
|
224
232
|
}
|
|
225
|
-
StatChart.prototype._class += "
|
|
233
|
+
StatChart.prototype._class += " chart_StatChart";
|
|
226
234
|
|
|
227
235
|
export interface StatChart {
|
|
228
236
|
view(): StatChartView;
|
package/src/Step.ts
CHANGED
package/src/WordCloud.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { I2DChart, ITooltip } from "@hpcc-js/api";
|
|
|
2
2
|
import { d3Event, InputField, SVGWidget, Utility, zoom as d3Zoom } from "@hpcc-js/common";
|
|
3
3
|
import { extent as d3Extent } from "d3-array";
|
|
4
4
|
import { scaleLinear as d3ScaleLinear, scaleLog as d3ScaleLog, scalePow as d3ScalePow, scaleSqrt as d3ScaleSqrt } from "d3-scale";
|
|
5
|
-
import { d3Cloud } from "./D3Cloud";
|
|
5
|
+
import { d3Cloud } from "./D3Cloud.ts";
|
|
6
6
|
|
|
7
7
|
import "../src/WordCloud.css";
|
|
8
8
|
|
|
@@ -184,67 +184,72 @@ export class WordCloud extends SVGWidget {
|
|
|
184
184
|
this._prevZoom = scale;
|
|
185
185
|
}
|
|
186
186
|
}
|
|
187
|
+
}
|
|
188
|
+
WordCloud.prototype._class += " chart_WordCloud";
|
|
189
|
+
WordCloud.prototype.implements(I2DChart.prototype);
|
|
190
|
+
WordCloud.prototype.implements(ITooltip.prototype);
|
|
191
|
+
WordCloud.prototype.mixin(Utility.SimpleSelectionMixin);
|
|
187
192
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
193
|
+
export interface WordCloud {
|
|
194
|
+
|
|
195
|
+
paletteID(): string;
|
|
196
|
+
paletteID(_: string): this;
|
|
197
|
+
useClonedPalette(): boolean;
|
|
198
|
+
useClonedPalette(_: boolean): this;
|
|
199
|
+
fontFamily(): string;
|
|
200
|
+
fontFamily(_: string): this;
|
|
201
|
+
fontSizeFrom(): number;
|
|
202
|
+
fontSizeFrom(_: number): this;
|
|
203
|
+
fontSizeTo(): number;
|
|
204
|
+
fontSizeTo(_: number): this;
|
|
205
|
+
angleFrom(): number;
|
|
206
|
+
angleFrom(_: number): this;
|
|
207
|
+
angleTo(): number;
|
|
208
|
+
angleTo(_: number): this;
|
|
209
|
+
angleCount(): number;
|
|
210
|
+
angleCount(_: number): this;
|
|
211
|
+
padding(): number;
|
|
212
|
+
padding(_: number): this;
|
|
213
|
+
scaleMode(): string;
|
|
214
|
+
scaleMode(_: string): this;
|
|
215
|
+
spiral(): string;
|
|
216
|
+
spiral(_: string): this;
|
|
217
|
+
offsetX(): number;
|
|
218
|
+
offsetX(_: number): this;
|
|
219
|
+
offsetY(): number;
|
|
220
|
+
offsetY(_: number): this;
|
|
221
|
+
zoom(): number;
|
|
222
|
+
zoom(_: number): this;
|
|
223
|
+
zoom_exists(): boolean;
|
|
216
224
|
|
|
217
225
|
// I2DChart
|
|
218
226
|
_palette;
|
|
219
|
-
click
|
|
220
|
-
dblclick
|
|
227
|
+
click(row, column, selected): void;
|
|
228
|
+
dblclick(row, column, selected): void;
|
|
221
229
|
|
|
222
230
|
// ITooltip ---
|
|
223
231
|
tooltip;
|
|
224
|
-
tooltipHTML
|
|
225
|
-
tooltipFormat
|
|
226
|
-
tooltipStyle
|
|
227
|
-
|
|
228
|
-
tooltipValueFormat
|
|
229
|
-
|
|
230
|
-
tooltipSeriesColor
|
|
231
|
-
|
|
232
|
-
tooltipLabelColor
|
|
233
|
-
|
|
234
|
-
tooltipValueColor
|
|
235
|
-
|
|
236
|
-
tooltipTick
|
|
237
|
-
|
|
238
|
-
tooltipOffset
|
|
239
|
-
|
|
232
|
+
tooltipHTML(_?): any;
|
|
233
|
+
tooltipFormat(opts): any;
|
|
234
|
+
tooltipStyle(): string;
|
|
235
|
+
tooltipStyle(_: string): this;
|
|
236
|
+
tooltipValueFormat(): string;
|
|
237
|
+
tooltipValueFormat(_: string): this;
|
|
238
|
+
tooltipSeriesColor(): string;
|
|
239
|
+
tooltipSeriesColor(_: string): this;
|
|
240
|
+
tooltipLabelColor(): string;
|
|
241
|
+
tooltipLabelColor(_: string): this;
|
|
242
|
+
tooltipValueColor(): string;
|
|
243
|
+
tooltipValueColor(_: string): this;
|
|
244
|
+
tooltipTick(): boolean;
|
|
245
|
+
tooltipTick(_: boolean): this;
|
|
246
|
+
tooltipOffset(): number;
|
|
247
|
+
tooltipOffset(_: number): this;
|
|
248
|
+
tooltipOffset_exists(): boolean;
|
|
240
249
|
|
|
241
250
|
// SimpleSelectionMixin
|
|
242
251
|
_selection: Utility.SimpleSelection;
|
|
243
252
|
}
|
|
244
|
-
WordCloud.prototype._class += " chart_WordCloud";
|
|
245
|
-
WordCloud.prototype.implements(I2DChart.prototype);
|
|
246
|
-
WordCloud.prototype.implements(ITooltip.prototype);
|
|
247
|
-
WordCloud.prototype.mixin(Utility.SimpleSelectionMixin);
|
|
248
253
|
|
|
249
254
|
WordCloud.prototype.publish("paletteID", "default", "set", "Color palette for this widget", WordCloud.prototype._palette.switch(), { tags: ["Basic", "Shared"] });
|
|
250
255
|
WordCloud.prototype.publish("useClonedPalette", false, "boolean", "Enable or disable using a cloned palette", null, { tags: ["Intermediate", "Shared"] });
|
package/src/XYAxis.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { d3Event, select as d3Select, SVGWidget, Utility } from "@hpcc-js/common
|
|
|
2
2
|
import { max as d3Max, min as d3Min } from "d3-array";
|
|
3
3
|
import { brush as d3Brush, brushSelection as d3BrushSelection, brushX as d3BrushX, brushY as d3BrushY } from "d3-brush";
|
|
4
4
|
import { hsl as d3Hsl } from "d3-color";
|
|
5
|
-
import { Axis } from "./Axis";
|
|
5
|
+
import { Axis } from "./Axis.ts";
|
|
6
6
|
|
|
7
7
|
import "../src/XYAxis.css";
|
|
8
8
|
|
|
@@ -16,7 +16,6 @@ export class XYAxis extends SVGWidget {
|
|
|
16
16
|
protected yBrush;
|
|
17
17
|
protected margin;
|
|
18
18
|
protected focusChart: XYAxis;
|
|
19
|
-
_palette;
|
|
20
19
|
|
|
21
20
|
constructor() {
|
|
22
21
|
super();
|
|
@@ -219,7 +218,7 @@ export class XYAxis extends SVGWidget {
|
|
|
219
218
|
const isHorizontal = this.orientation() === "horizontal";
|
|
220
219
|
const handleTypes = this.use2dSelection() ? [] : isHorizontal ? [{ type: "w" }, { type: "e" }] : [{ type: "n" }, { type: "s" }];
|
|
221
220
|
const handlePath = this.svgBrush.selectAll(".handle--custom").data(handleTypes);
|
|
222
|
-
const s = d3Event()
|
|
221
|
+
const s = d3Event()?.selection;
|
|
223
222
|
if (s == null) {
|
|
224
223
|
handlePath.attr("display", "none");
|
|
225
224
|
} else if (isHorizontal) {
|
|
@@ -571,7 +570,7 @@ export class XYAxis extends SVGWidget {
|
|
|
571
570
|
return masterColumns.indexOf(column);
|
|
572
571
|
}
|
|
573
572
|
|
|
574
|
-
layerData(host
|
|
573
|
+
layerData(host?: XYAxis): any[][] {
|
|
575
574
|
if (arguments.length === 1) {
|
|
576
575
|
const indices = this.layerColumnIndices(host);
|
|
577
576
|
return host.data().map(row => {
|
|
@@ -659,6 +658,7 @@ XYAxis.prototype._class += " chart_XYAxis";
|
|
|
659
658
|
XYAxis.prototype.mixin(Utility.SimpleSelectionMixin);
|
|
660
659
|
|
|
661
660
|
export interface XYAxis {
|
|
661
|
+
_palette;
|
|
662
662
|
orientation(): "horizontal" | "vertical";
|
|
663
663
|
orientation(_: "horizontal" | "vertical"): this;
|
|
664
664
|
orientation_default(_: string);
|
package/src/__package__.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
export const PKG_NAME = "@hpcc-js/chart";
|
|
2
|
-
export const PKG_VERSION = "2.
|
|
3
|
-
export const BUILD_VERSION = "2.
|
|
2
|
+
export const PKG_VERSION = "3.2.0";
|
|
3
|
+
export const BUILD_VERSION = "3.2.0";
|
package/src/index.ts
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
export * from "./__package__";
|
|
2
|
-
export * from "./Area";
|
|
3
|
-
export * from "./Axis";
|
|
4
|
-
export * from "./Bar";
|
|
5
|
-
export * from "./Bubble";
|
|
6
|
-
export * from "./BubbleXY";
|
|
7
|
-
export * from "./Bullet";
|
|
8
|
-
export * from "./Column";
|
|
9
|
-
export * from "./Contour";
|
|
10
|
-
export * from "./Gantt";
|
|
11
|
-
export * from "./Gauge";
|
|
12
|
-
export * from "./HalfPie";
|
|
13
|
-
export * from "./Heat";
|
|
14
|
-
export * from "./HexBin";
|
|
15
|
-
export * from "./Line";
|
|
16
|
-
export * from "./Pie";
|
|
17
|
-
export * from "./QuarterPie";
|
|
18
|
-
export * from "./QuartileCandlestick";
|
|
19
|
-
export * from "./Radar";
|
|
20
|
-
export * from "./RadialBar";
|
|
21
|
-
export * from "./Scatter";
|
|
22
|
-
export * from "./StatChart";
|
|
23
|
-
export * from "./Step";
|
|
24
|
-
export * from "./Summary";
|
|
25
|
-
export * from "./SummaryC";
|
|
26
|
-
export * from "./WordCloud";
|
|
27
|
-
export * from "./XYAxis";
|
|
1
|
+
export * from "./__package__.ts";
|
|
2
|
+
export * from "./Area.ts";
|
|
3
|
+
export * from "./Axis.ts";
|
|
4
|
+
export * from "./Bar.ts";
|
|
5
|
+
export * from "./Bubble.ts";
|
|
6
|
+
export * from "./BubbleXY.ts";
|
|
7
|
+
export * from "./Bullet.ts";
|
|
8
|
+
export * from "./Column.ts";
|
|
9
|
+
export * from "./Contour.ts";
|
|
10
|
+
export * from "./Gantt.ts";
|
|
11
|
+
export * from "./Gauge.ts";
|
|
12
|
+
export * from "./HalfPie.ts";
|
|
13
|
+
export * from "./Heat.ts";
|
|
14
|
+
export * from "./HexBin.ts";
|
|
15
|
+
export * from "./Line.ts";
|
|
16
|
+
export * from "./Pie.ts";
|
|
17
|
+
export * from "./QuarterPie.ts";
|
|
18
|
+
export * from "./QuartileCandlestick.ts";
|
|
19
|
+
export * from "./Radar.ts";
|
|
20
|
+
export * from "./RadialBar.ts";
|
|
21
|
+
export * from "./Scatter.ts";
|
|
22
|
+
export * from "./StatChart.ts";
|
|
23
|
+
export * from "./Step.ts";
|
|
24
|
+
export * from "./Summary.ts";
|
|
25
|
+
export * from "./SummaryC.ts";
|
|
26
|
+
export * from "./WordCloud.ts";
|
|
27
|
+
export * from "./XYAxis.ts";
|
package/types/Area.d.ts
CHANGED