@skdx/angular-charts 0.34.0 → 0.35.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/README.md +9 -1
- package/fesm2022/skdx-angular-charts-area.mjs +25 -3
- package/fesm2022/skdx-angular-charts-area.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-bar.mjs +25 -3
- package/fesm2022/skdx-angular-charts-bar.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-boxplot.mjs +62 -6
- package/fesm2022/skdx-angular-charts-boxplot.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-bubble.mjs +119 -0
- package/fesm2022/skdx-angular-charts-bubble.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-bullet.mjs +110 -0
- package/fesm2022/skdx-angular-charts-bullet.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-bump.mjs +113 -0
- package/fesm2022/skdx-angular-charts-bump.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-candlestick.mjs +40 -5
- package/fesm2022/skdx-angular-charts-candlestick.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-chord.mjs +49 -10
- package/fesm2022/skdx-angular-charts-chord.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-circle-packing.mjs +107 -0
- package/fesm2022/skdx-angular-charts-circle-packing.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-combo.mjs +82 -0
- package/fesm2022/skdx-angular-charts-combo.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-dumbbell.mjs +116 -0
- package/fesm2022/skdx-angular-charts-dumbbell.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-funnel.mjs +39 -5
- package/fesm2022/skdx-angular-charts-funnel.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-gantt.mjs +47 -6
- package/fesm2022/skdx-angular-charts-gantt.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-gauge.mjs +134 -0
- package/fesm2022/skdx-angular-charts-gauge.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-heatmap.mjs +63 -5
- package/fesm2022/skdx-angular-charts-heatmap.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-histogram.mjs +134 -0
- package/fesm2022/skdx-angular-charts-histogram.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-icicle.mjs +119 -0
- package/fesm2022/skdx-angular-charts-icicle.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-internal.mjs +9286 -2473
- package/fesm2022/skdx-angular-charts-internal.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-line.mjs +25 -3
- package/fesm2022/skdx-angular-charts-line.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-linear-gauge.mjs +119 -0
- package/fesm2022/skdx-angular-charts-linear-gauge.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-map.mjs +51 -5
- package/fesm2022/skdx-angular-charts-map.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-marimekko.mjs +103 -0
- package/fesm2022/skdx-angular-charts-marimekko.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-network.mjs +113 -0
- package/fesm2022/skdx-angular-charts-network.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-organization.mjs +111 -0
- package/fesm2022/skdx-angular-charts-organization.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-parallel.mjs +105 -0
- package/fesm2022/skdx-angular-charts-parallel.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-pareto.mjs +123 -0
- package/fesm2022/skdx-angular-charts-pareto.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-pie.mjs +47 -5
- package/fesm2022/skdx-angular-charts-pie.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-polar-area.mjs +118 -0
- package/fesm2022/skdx-angular-charts-polar-area.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-radar.mjs +61 -10
- package/fesm2022/skdx-angular-charts-radar.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-radial.mjs +25 -3
- package/fesm2022/skdx-angular-charts-radial.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-range.mjs +133 -0
- package/fesm2022/skdx-angular-charts-range.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-sankey.mjs +67 -6
- package/fesm2022/skdx-angular-charts-sankey.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-scatter.mjs +42 -5
- package/fesm2022/skdx-angular-charts-scatter.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-sparkline.mjs +39 -5
- package/fesm2022/skdx-angular-charts-sparkline.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-sunburst.mjs +74 -6
- package/fesm2022/skdx-angular-charts-sunburst.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-swarm.mjs +101 -0
- package/fesm2022/skdx-angular-charts-swarm.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-timeline.mjs +98 -0
- package/fesm2022/skdx-angular-charts-timeline.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-tree.mjs +118 -0
- package/fesm2022/skdx-angular-charts-tree.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-treemap.mjs +63 -6
- package/fesm2022/skdx-angular-charts-treemap.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts-waffle.mjs +113 -0
- package/fesm2022/skdx-angular-charts-waffle.mjs.map +1 -0
- package/fesm2022/skdx-angular-charts-waterfall.mjs +62 -6
- package/fesm2022/skdx-angular-charts-waterfall.mjs.map +1 -1
- package/fesm2022/skdx-angular-charts.mjs +22 -1
- package/fesm2022/skdx-angular-charts.mjs.map +1 -1
- package/package.json +87 -3
- package/types/skdx-angular-charts-boxplot.d.ts +18 -3
- package/types/skdx-angular-charts-bubble.d.ts +27 -0
- package/types/skdx-angular-charts-bullet.d.ts +24 -0
- package/types/skdx-angular-charts-bump.d.ts +25 -0
- package/types/skdx-angular-charts-candlestick.d.ts +7 -2
- package/types/skdx-angular-charts-chord.d.ts +11 -4
- package/types/skdx-angular-charts-circle-packing.d.ts +23 -0
- package/types/skdx-angular-charts-combo.d.ts +12 -0
- package/types/skdx-angular-charts-dumbbell.d.ts +26 -0
- package/types/skdx-angular-charts-funnel.d.ts +7 -1
- package/types/skdx-angular-charts-gantt.d.ts +9 -2
- package/types/skdx-angular-charts-gauge.d.ts +36 -0
- package/types/skdx-angular-charts-heatmap.d.ts +20 -2
- package/types/skdx-angular-charts-histogram.d.ts +34 -0
- package/types/skdx-angular-charts-icicle.d.ts +29 -0
- package/types/skdx-angular-charts-internal.d.ts +1952 -89
- package/types/skdx-angular-charts-linear-gauge.d.ts +29 -0
- package/types/skdx-angular-charts-map.d.ts +14 -2
- package/types/skdx-angular-charts-marimekko.d.ts +21 -0
- package/types/skdx-angular-charts-network.d.ts +25 -0
- package/types/skdx-angular-charts-organization.d.ts +25 -0
- package/types/skdx-angular-charts-parallel.d.ts +25 -0
- package/types/skdx-angular-charts-pareto.d.ts +27 -0
- package/types/skdx-angular-charts-pie.d.ts +11 -1
- package/types/skdx-angular-charts-polar-area.d.ts +28 -0
- package/types/skdx-angular-charts-radar.d.ts +20 -5
- package/types/skdx-angular-charts-range.d.ts +29 -0
- package/types/skdx-angular-charts-sankey.d.ts +20 -2
- package/types/skdx-angular-charts-scatter.d.ts +9 -2
- package/types/skdx-angular-charts-sparkline.d.ts +8 -2
- package/types/skdx-angular-charts-sunburst.d.ts +23 -2
- package/types/skdx-angular-charts-swarm.d.ts +19 -0
- package/types/skdx-angular-charts-timeline.d.ts +18 -0
- package/types/skdx-angular-charts-tree.d.ts +28 -0
- package/types/skdx-angular-charts-treemap.d.ts +18 -2
- package/types/skdx-angular-charts-waffle.d.ts +25 -0
- package/types/skdx-angular-charts-waterfall.d.ts +17 -3
- package/types/skdx-angular-charts.d.ts +22 -1
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { SkdxSizedBase, layoutSwarmPlot, SkdxChartRootComponent } from '@skdx/angular-charts/internal';
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright (c) 2026 SkandaDX
|
|
7
|
+
* This file is part of the SkandaDX organization.
|
|
8
|
+
* Licensed under the MIT License. See LICENSE in the repository root.
|
|
9
|
+
*/
|
|
10
|
+
/** A beeswarm: every observation as a dot, spread sideways so none overlap. */
|
|
11
|
+
class SkdxSwarmPlotComponent extends SkdxSizedBase {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
/** One swarm per series, over its raw samples. */
|
|
15
|
+
this.series = input.required(/* @ts-ignore */
|
|
16
|
+
...(ngDevMode ? [{ debugName: "series" }] : /* istanbul ignore next */ []));
|
|
17
|
+
this.orientation = input(/* @ts-ignore */
|
|
18
|
+
...(ngDevMode ? [undefined, { debugName: "orientation" }] : /* istanbul ignore next */ []));
|
|
19
|
+
/** Dot radius in pixels. */
|
|
20
|
+
this.markerSize = input(/* @ts-ignore */
|
|
21
|
+
...(ngDevMode ? [undefined, { debugName: "markerSize" }] : /* istanbul ignore next */ []));
|
|
22
|
+
this.yAxis = input(/* @ts-ignore */
|
|
23
|
+
...(ngDevMode ? [undefined, { debugName: "yAxis" }] : /* istanbul ignore next */ []));
|
|
24
|
+
this.references = input(/* @ts-ignore */
|
|
25
|
+
...(ngDevMode ? [undefined, { debugName: "references" }] : /* istanbul ignore next */ []));
|
|
26
|
+
this.layout = computed(() => layoutSwarmPlot({
|
|
27
|
+
...this.sized(),
|
|
28
|
+
series: this.series(),
|
|
29
|
+
orientation: this.orientation(),
|
|
30
|
+
markerSize: this.markerSize(),
|
|
31
|
+
yAxis: this.yAxis(),
|
|
32
|
+
references: this.references(),
|
|
33
|
+
}), /* @ts-ignore */
|
|
34
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
35
|
+
}
|
|
36
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxSwarmPlotComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
37
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: SkdxSwarmPlotComponent, isStandalone: true, selector: "skdx-swarm-plot", inputs: { series: { classPropertyName: "series", publicName: "series", isSignal: true, isRequired: true, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, markerSize: { classPropertyName: "markerSize", publicName: "markerSize", isSignal: true, isRequired: false, transformFunction: null }, yAxis: { classPropertyName: "yAxis", publicName: "yAxis", isSignal: true, isRequired: false, transformFunction: null }, references: { classPropertyName: "references", publicName: "references", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
38
|
+
<skdx-chart-root
|
|
39
|
+
[layout]="layout()"
|
|
40
|
+
[options]="options()"
|
|
41
|
+
kind="swarm"
|
|
42
|
+
[label]="label() ?? 'Swarm plot'"
|
|
43
|
+
[zoomable]="zoomable()"
|
|
44
|
+
[selectionMode]="selectionMode()"
|
|
45
|
+
[editable]="editable()"
|
|
46
|
+
[syncId]="syncId()"
|
|
47
|
+
[crosshair]="syncedCrosshair()"
|
|
48
|
+
[responsive]="!!responsive()"
|
|
49
|
+
(itemClick)="itemClick.emit($event)"
|
|
50
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
51
|
+
(taskChange)="taskChange.emit($event)"
|
|
52
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
53
|
+
(zoomChange)="zoom.set($event)"
|
|
54
|
+
(viewChange)="view.set($event)"
|
|
55
|
+
(selectedChange)="selected.set($event)"
|
|
56
|
+
(highlightedChange)="highlighted.set($event)"
|
|
57
|
+
(syncChange)="sync($event)"
|
|
58
|
+
(measured)="measuredWidth.set($event)"
|
|
59
|
+
></skdx-chart-root>
|
|
60
|
+
`, isInline: true, dependencies: [{ kind: "component", type: SkdxChartRootComponent, selector: "skdx-chart-root", inputs: ["layout", "options", "kind", "label", "zoomable", "selectionMode", "editable", "syncId", "crosshair", "responsive"], outputs: ["itemClick", "hiddenSeriesChange", "zoomChange", "viewChange", "selectedChange", "highlightedChange", "dataIssue", "taskChange", "syncChange", "measured"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
61
|
+
}
|
|
62
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxSwarmPlotComponent, decorators: [{
|
|
63
|
+
type: Component,
|
|
64
|
+
args: [{
|
|
65
|
+
selector: 'skdx-swarm-plot',
|
|
66
|
+
standalone: true,
|
|
67
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
68
|
+
imports: [SkdxChartRootComponent],
|
|
69
|
+
template: `
|
|
70
|
+
<skdx-chart-root
|
|
71
|
+
[layout]="layout()"
|
|
72
|
+
[options]="options()"
|
|
73
|
+
kind="swarm"
|
|
74
|
+
[label]="label() ?? 'Swarm plot'"
|
|
75
|
+
[zoomable]="zoomable()"
|
|
76
|
+
[selectionMode]="selectionMode()"
|
|
77
|
+
[editable]="editable()"
|
|
78
|
+
[syncId]="syncId()"
|
|
79
|
+
[crosshair]="syncedCrosshair()"
|
|
80
|
+
[responsive]="!!responsive()"
|
|
81
|
+
(itemClick)="itemClick.emit($event)"
|
|
82
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
83
|
+
(taskChange)="taskChange.emit($event)"
|
|
84
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
85
|
+
(zoomChange)="zoom.set($event)"
|
|
86
|
+
(viewChange)="view.set($event)"
|
|
87
|
+
(selectedChange)="selected.set($event)"
|
|
88
|
+
(highlightedChange)="highlighted.set($event)"
|
|
89
|
+
(syncChange)="sync($event)"
|
|
90
|
+
(measured)="measuredWidth.set($event)"
|
|
91
|
+
></skdx-chart-root>
|
|
92
|
+
`,
|
|
93
|
+
}]
|
|
94
|
+
}], propDecorators: { series: [{ type: i0.Input, args: [{ isSignal: true, alias: "series", required: true }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], markerSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "markerSize", required: false }] }], yAxis: [{ type: i0.Input, args: [{ isSignal: true, alias: "yAxis", required: false }] }], references: [{ type: i0.Input, args: [{ isSignal: true, alias: "references", required: false }] }] } });
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Generated bundle index. Do not edit.
|
|
98
|
+
*/
|
|
99
|
+
|
|
100
|
+
export { SkdxSwarmPlotComponent };
|
|
101
|
+
//# sourceMappingURL=skdx-angular-charts-swarm.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skdx-angular-charts-swarm.mjs","sources":["../../src/swarm/index.ts","../../src/swarm/skdx-angular-charts-swarm.ts"],"sourcesContent":["/*\n * Copyright (c) 2026 SkandaDX\n * This file is part of the SkandaDX organization.\n * Licensed under the MIT License. See LICENSE in the repository root.\n */\n\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\n\nimport {\n layoutSwarmPlot,\n SkdxChartRootComponent,\n SkdxSizedBase,\n type AxisOptions,\n type Reference,\n type Series,\n} from '@skdx/angular-charts/internal';\n\n/** A beeswarm: every observation as a dot, spread sideways so none overlap. */\n@Component({\n selector: 'skdx-swarm-plot',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [SkdxChartRootComponent],\n template: `\n <skdx-chart-root\n [layout]=\"layout()\"\n [options]=\"options()\"\n kind=\"swarm\"\n [label]=\"label() ?? 'Swarm plot'\"\n [zoomable]=\"zoomable()\"\n [selectionMode]=\"selectionMode()\"\n [editable]=\"editable()\"\n [syncId]=\"syncId()\"\n [crosshair]=\"syncedCrosshair()\"\n [responsive]=\"!!responsive()\"\n (itemClick)=\"itemClick.emit($event)\"\n (dataIssue)=\"dataIssue.emit($event)\"\n (taskChange)=\"taskChange.emit($event)\"\n (hiddenSeriesChange)=\"toggle($event)\"\n (zoomChange)=\"zoom.set($event)\"\n (viewChange)=\"view.set($event)\"\n (selectedChange)=\"selected.set($event)\"\n (highlightedChange)=\"highlighted.set($event)\"\n (syncChange)=\"sync($event)\"\n (measured)=\"measuredWidth.set($event)\"\n ></skdx-chart-root>\n `,\n})\nexport class SkdxSwarmPlotComponent extends SkdxSizedBase {\n /** One swarm per series, over its raw samples. */\n readonly series = input.required<Series[]>();\n readonly orientation = input<'vertical' | 'horizontal'>();\n /** Dot radius in pixels. */\n readonly markerSize = input<number>();\n readonly yAxis = input<AxisOptions>();\n readonly references = input<Reference[]>();\n\n protected readonly layout = computed(() =>\n layoutSwarmPlot({\n ...this.sized(),\n series: this.series(),\n orientation: this.orientation(),\n markerSize: this.markerSize(),\n yAxis: this.yAxis(),\n references: this.references(),\n }),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAAA;;;;AAIG;AAaH;AA+BM,MAAO,sBAAuB,SAAQ,aAAa,CAAA;AA9BzD,IAAA,WAAA,GAAA;;;QAgCW,IAAA,CAAA,MAAM,GAAG,KAAK,CAAC,QAAQ;mFAAY;AACnC,QAAA,IAAA,CAAA,WAAW,GAAG,KAAK;mGAA6B;;AAEhD,QAAA,IAAA,CAAA,UAAU,GAAG,KAAK;kGAAU;AAC5B,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK;6FAAe;AAC5B,QAAA,IAAA,CAAA,UAAU,GAAG,KAAK;kGAAe;AAEvB,QAAA,IAAA,CAAA,MAAM,GAAG,QAAQ,CAAC,MACnC,eAAe,CAAC;YACd,GAAG,IAAI,CAAC,KAAK,EAAE;AACf,YAAA,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE;AACrB,YAAA,WAAW,EAAE,IAAI,CAAC,WAAW,EAAE;AAC/B,YAAA,UAAU,EAAE,IAAI,CAAC,UAAU,EAAE;AAC7B,YAAA,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE;AACnB,Y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AAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAxBS,sBAAsB,EAAA,QAAA,EAAA,iBAAA,EAAA,MAAA,EAAA,CAAA,QAAA,EAAA,SAAA,EAAA,MAAA,EAAA,OAAA,EAAA,UAAA,EAAA,eAAA,EAAA,UAAA,EAAA,QAAA,EAAA,WAAA,EAAA,YAAA,CAAA,EAAA,OAAA,EAAA,CAAA,WAAA,EAAA,oBAAA,EAAA,YAAA,EAAA,YAAA,EAAA,gBAAA,EAAA,mBAAA,EAAA,WAAA,EAAA,YAAA,EAAA,YAAA,EAAA,UAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;2FA0BrB,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBA9BlC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,iBAAiB;AAC3B,oBAAA,UAAU,EAAE,IAAI;oBAChB,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,OAAO,EAAE,CAAC,sBAAsB,CAAC;AACjC,oBAAA,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;AAuBT,EAAA,CAAA;AACF,iBAAA;;;AC/CD;;AAEG;;"}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { SkdxSizedBase, layoutTimelineChart, SkdxChartRootComponent } from '@skdx/angular-charts/internal';
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright (c) 2026 SkandaDX
|
|
7
|
+
* This file is part of the SkandaDX organization.
|
|
8
|
+
* Licensed under the MIT License. See LICENSE in the repository root.
|
|
9
|
+
*/
|
|
10
|
+
/** Point-in-time events on a time axis, in lanes with staggered labels, or as a vertical list. */
|
|
11
|
+
class SkdxTimelineChartComponent extends SkdxSizedBase {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
this.events = input.required(/* @ts-ignore */
|
|
15
|
+
...(ngDevMode ? [{ debugName: "events" }] : /* istanbul ignore next */ []));
|
|
16
|
+
this.orientation = input(/* @ts-ignore */
|
|
17
|
+
...(ngDevMode ? [undefined, { debugName: "orientation" }] : /* istanbul ignore next */ []));
|
|
18
|
+
/** How dates are written. */
|
|
19
|
+
this.xAxis = input(/* @ts-ignore */
|
|
20
|
+
...(ngDevMode ? [undefined, { debugName: "xAxis" }] : /* istanbul ignore next */ []));
|
|
21
|
+
/** Write event labels. */
|
|
22
|
+
this.labels = input(true, /* @ts-ignore */
|
|
23
|
+
...(ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []));
|
|
24
|
+
this.layout = computed(() => layoutTimelineChart({
|
|
25
|
+
...this.sized(),
|
|
26
|
+
events: this.events(),
|
|
27
|
+
orientation: this.orientation(),
|
|
28
|
+
xAxis: this.xAxis(),
|
|
29
|
+
labels: this.labels(),
|
|
30
|
+
}), /* @ts-ignore */
|
|
31
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
32
|
+
}
|
|
33
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxTimelineChartComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
34
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: SkdxTimelineChartComponent, isStandalone: true, selector: "skdx-timeline-chart", inputs: { events: { classPropertyName: "events", publicName: "events", isSignal: true, isRequired: true, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, xAxis: { classPropertyName: "xAxis", publicName: "xAxis", isSignal: true, isRequired: false, transformFunction: null }, labels: { classPropertyName: "labels", publicName: "labels", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
35
|
+
<skdx-chart-root
|
|
36
|
+
[layout]="layout()"
|
|
37
|
+
[options]="options()"
|
|
38
|
+
kind="timeline"
|
|
39
|
+
[label]="label() ?? 'Timeline chart'"
|
|
40
|
+
[zoomable]="zoomable()"
|
|
41
|
+
[selectionMode]="selectionMode()"
|
|
42
|
+
[editable]="editable()"
|
|
43
|
+
[syncId]="syncId()"
|
|
44
|
+
[crosshair]="syncedCrosshair()"
|
|
45
|
+
[responsive]="!!responsive()"
|
|
46
|
+
(itemClick)="itemClick.emit($event)"
|
|
47
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
48
|
+
(taskChange)="taskChange.emit($event)"
|
|
49
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
50
|
+
(zoomChange)="zoom.set($event)"
|
|
51
|
+
(viewChange)="view.set($event)"
|
|
52
|
+
(selectedChange)="selected.set($event)"
|
|
53
|
+
(highlightedChange)="highlighted.set($event)"
|
|
54
|
+
(syncChange)="sync($event)"
|
|
55
|
+
(measured)="measuredWidth.set($event)"
|
|
56
|
+
></skdx-chart-root>
|
|
57
|
+
`, isInline: true, dependencies: [{ kind: "component", type: SkdxChartRootComponent, selector: "skdx-chart-root", inputs: ["layout", "options", "kind", "label", "zoomable", "selectionMode", "editable", "syncId", "crosshair", "responsive"], outputs: ["itemClick", "hiddenSeriesChange", "zoomChange", "viewChange", "selectedChange", "highlightedChange", "dataIssue", "taskChange", "syncChange", "measured"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
58
|
+
}
|
|
59
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxTimelineChartComponent, decorators: [{
|
|
60
|
+
type: Component,
|
|
61
|
+
args: [{
|
|
62
|
+
selector: 'skdx-timeline-chart',
|
|
63
|
+
standalone: true,
|
|
64
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
65
|
+
imports: [SkdxChartRootComponent],
|
|
66
|
+
template: `
|
|
67
|
+
<skdx-chart-root
|
|
68
|
+
[layout]="layout()"
|
|
69
|
+
[options]="options()"
|
|
70
|
+
kind="timeline"
|
|
71
|
+
[label]="label() ?? 'Timeline chart'"
|
|
72
|
+
[zoomable]="zoomable()"
|
|
73
|
+
[selectionMode]="selectionMode()"
|
|
74
|
+
[editable]="editable()"
|
|
75
|
+
[syncId]="syncId()"
|
|
76
|
+
[crosshair]="syncedCrosshair()"
|
|
77
|
+
[responsive]="!!responsive()"
|
|
78
|
+
(itemClick)="itemClick.emit($event)"
|
|
79
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
80
|
+
(taskChange)="taskChange.emit($event)"
|
|
81
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
82
|
+
(zoomChange)="zoom.set($event)"
|
|
83
|
+
(viewChange)="view.set($event)"
|
|
84
|
+
(selectedChange)="selected.set($event)"
|
|
85
|
+
(highlightedChange)="highlighted.set($event)"
|
|
86
|
+
(syncChange)="sync($event)"
|
|
87
|
+
(measured)="measuredWidth.set($event)"
|
|
88
|
+
></skdx-chart-root>
|
|
89
|
+
`,
|
|
90
|
+
}]
|
|
91
|
+
}], propDecorators: { events: [{ type: i0.Input, args: [{ isSignal: true, alias: "events", required: true }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], xAxis: [{ type: i0.Input, args: [{ isSignal: true, alias: "xAxis", required: false }] }], labels: [{ type: i0.Input, args: [{ isSignal: true, alias: "labels", required: false }] }] } });
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Generated bundle index. Do not edit.
|
|
95
|
+
*/
|
|
96
|
+
|
|
97
|
+
export { SkdxTimelineChartComponent };
|
|
98
|
+
//# sourceMappingURL=skdx-angular-charts-timeline.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skdx-angular-charts-timeline.mjs","sources":["../../src/timeline/index.ts","../../src/timeline/skdx-angular-charts-timeline.ts"],"sourcesContent":["/*\n * Copyright (c) 2026 SkandaDX\n * This file is part of the SkandaDX organization.\n * Licensed under the MIT License. See LICENSE in the repository root.\n */\n\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\n\nimport {\n layoutTimelineChart,\n SkdxChartRootComponent,\n SkdxSizedBase,\n type AxisOptions,\n type TimelineEvent,\n} from '@skdx/angular-charts/internal';\n\n/** Point-in-time events on a time axis, in lanes with staggered labels, or as a vertical list. */\n@Component({\n selector: 'skdx-timeline-chart',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [SkdxChartRootComponent],\n template: `\n <skdx-chart-root\n [layout]=\"layout()\"\n [options]=\"options()\"\n kind=\"timeline\"\n [label]=\"label() ?? 'Timeline chart'\"\n [zoomable]=\"zoomable()\"\n [selectionMode]=\"selectionMode()\"\n [editable]=\"editable()\"\n [syncId]=\"syncId()\"\n [crosshair]=\"syncedCrosshair()\"\n [responsive]=\"!!responsive()\"\n (itemClick)=\"itemClick.emit($event)\"\n (dataIssue)=\"dataIssue.emit($event)\"\n (taskChange)=\"taskChange.emit($event)\"\n (hiddenSeriesChange)=\"toggle($event)\"\n (zoomChange)=\"zoom.set($event)\"\n (viewChange)=\"view.set($event)\"\n (selectedChange)=\"selected.set($event)\"\n (highlightedChange)=\"highlighted.set($event)\"\n (syncChange)=\"sync($event)\"\n (measured)=\"measuredWidth.set($event)\"\n ></skdx-chart-root>\n `,\n})\nexport class SkdxTimelineChartComponent extends SkdxSizedBase {\n readonly events = input.required<TimelineEvent[]>();\n readonly orientation = input<'horizontal' | 'vertical'>();\n /** How dates are written. */\n readonly xAxis = input<Pick<AxisOptions, 'format' | 'label'>>();\n /** Write event labels. */\n readonly labels = input(true);\n\n protected readonly layout = computed(() =>\n layoutTimelineChart({\n ...this.sized(),\n events: this.events(),\n orientation: this.orientation(),\n xAxis: this.xAxis(),\n labels: this.labels(),\n }),\n );\n}\n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,oBAAA,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;AAuBT,EAAA,CAAA;AACF,iBAAA;;;AC9CD;;AAEG;;"}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { SkdxSizedBase, layoutTreeChart, SkdxChartRootComponent } from '@skdx/angular-charts/internal';
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright (c) 2026 SkandaDX
|
|
7
|
+
* This file is part of the SkandaDX organization.
|
|
8
|
+
* Licensed under the MIT License. See LICENSE in the repository root.
|
|
9
|
+
*/
|
|
10
|
+
/** A node-link tree: one dot or box per node with links to its children, top-down or left-right. */
|
|
11
|
+
class SkdxTreeChartComponent extends SkdxSizedBase {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
this.data = input.required(/* @ts-ignore */
|
|
15
|
+
...(ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []));
|
|
16
|
+
/** Root at the top, or at the left. */
|
|
17
|
+
this.orientation = input(/* @ts-ignore */
|
|
18
|
+
...(ngDevMode ? [undefined, { debugName: "orientation" }] : /* istanbul ignore next */ []));
|
|
19
|
+
/** Dots with labels beside them, or boxes holding the name. */
|
|
20
|
+
this.nodeShape = input(/* @ts-ignore */
|
|
21
|
+
...(ngDevMode ? [undefined, { debugName: "nodeShape" }] : /* istanbul ignore next */ []));
|
|
22
|
+
this.linkStyle = input(/* @ts-ignore */
|
|
23
|
+
...(ngDevMode ? [undefined, { debugName: "linkStyle" }] : /* istanbul ignore next */ []));
|
|
24
|
+
/** Id (or name) of the node shown as the root. */
|
|
25
|
+
this.rootId = input(/* @ts-ignore */
|
|
26
|
+
...(ngDevMode ? [undefined, { debugName: "rootId" }] : /* istanbul ignore next */ []));
|
|
27
|
+
/** Nodes whose children are hidden. */
|
|
28
|
+
this.collapsed = input(/* @ts-ignore */
|
|
29
|
+
...(ngDevMode ? [undefined, { debugName: "collapsed" }] : /* istanbul ignore next */ []));
|
|
30
|
+
/** Deepest level drawn. */
|
|
31
|
+
this.maxDepth = input(/* @ts-ignore */
|
|
32
|
+
...(ngDevMode ? [undefined, { debugName: "maxDepth" }] : /* istanbul ignore next */ []));
|
|
33
|
+
/** Write node names. */
|
|
34
|
+
this.labels = input(true, /* @ts-ignore */
|
|
35
|
+
...(ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []));
|
|
36
|
+
/** Dot radius, or box height, in pixels. */
|
|
37
|
+
this.nodeSize = input(/* @ts-ignore */
|
|
38
|
+
...(ngDevMode ? [undefined, { debugName: "nodeSize" }] : /* istanbul ignore next */ []));
|
|
39
|
+
this.layout = computed(() => layoutTreeChart({
|
|
40
|
+
...this.sized(),
|
|
41
|
+
data: this.data(),
|
|
42
|
+
orientation: this.orientation(),
|
|
43
|
+
nodeShape: this.nodeShape(),
|
|
44
|
+
linkStyle: this.linkStyle(),
|
|
45
|
+
rootId: this.rootId(),
|
|
46
|
+
collapsed: this.collapsed(),
|
|
47
|
+
maxDepth: this.maxDepth(),
|
|
48
|
+
labels: this.labels(),
|
|
49
|
+
nodeSize: this.nodeSize(),
|
|
50
|
+
}), /* @ts-ignore */
|
|
51
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
52
|
+
}
|
|
53
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxTreeChartComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
54
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: SkdxTreeChartComponent, isStandalone: true, selector: "skdx-tree-chart", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, nodeShape: { classPropertyName: "nodeShape", publicName: "nodeShape", isSignal: true, isRequired: false, transformFunction: null }, linkStyle: { classPropertyName: "linkStyle", publicName: "linkStyle", isSignal: true, isRequired: false, transformFunction: null }, rootId: { classPropertyName: "rootId", publicName: "rootId", isSignal: true, isRequired: false, transformFunction: null }, collapsed: { classPropertyName: "collapsed", publicName: "collapsed", isSignal: true, isRequired: false, transformFunction: null }, maxDepth: { classPropertyName: "maxDepth", publicName: "maxDepth", isSignal: true, isRequired: false, transformFunction: null }, labels: { classPropertyName: "labels", publicName: "labels", isSignal: true, isRequired: false, transformFunction: null }, nodeSize: { classPropertyName: "nodeSize", publicName: "nodeSize", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
55
|
+
<skdx-chart-root
|
|
56
|
+
[layout]="layout()"
|
|
57
|
+
[options]="options()"
|
|
58
|
+
kind="tree"
|
|
59
|
+
[label]="label() ?? 'Tree chart'"
|
|
60
|
+
[zoomable]="zoomable()"
|
|
61
|
+
[selectionMode]="selectionMode()"
|
|
62
|
+
[editable]="editable()"
|
|
63
|
+
[syncId]="syncId()"
|
|
64
|
+
[crosshair]="syncedCrosshair()"
|
|
65
|
+
[responsive]="!!responsive()"
|
|
66
|
+
(itemClick)="itemClick.emit($event)"
|
|
67
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
68
|
+
(taskChange)="taskChange.emit($event)"
|
|
69
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
70
|
+
(zoomChange)="zoom.set($event)"
|
|
71
|
+
(viewChange)="view.set($event)"
|
|
72
|
+
(selectedChange)="selected.set($event)"
|
|
73
|
+
(highlightedChange)="highlighted.set($event)"
|
|
74
|
+
(syncChange)="sync($event)"
|
|
75
|
+
(measured)="measuredWidth.set($event)"
|
|
76
|
+
></skdx-chart-root>
|
|
77
|
+
`, isInline: true, dependencies: [{ kind: "component", type: SkdxChartRootComponent, selector: "skdx-chart-root", inputs: ["layout", "options", "kind", "label", "zoomable", "selectionMode", "editable", "syncId", "crosshair", "responsive"], outputs: ["itemClick", "hiddenSeriesChange", "zoomChange", "viewChange", "selectedChange", "highlightedChange", "dataIssue", "taskChange", "syncChange", "measured"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
78
|
+
}
|
|
79
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxTreeChartComponent, decorators: [{
|
|
80
|
+
type: Component,
|
|
81
|
+
args: [{
|
|
82
|
+
selector: 'skdx-tree-chart',
|
|
83
|
+
standalone: true,
|
|
84
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
85
|
+
imports: [SkdxChartRootComponent],
|
|
86
|
+
template: `
|
|
87
|
+
<skdx-chart-root
|
|
88
|
+
[layout]="layout()"
|
|
89
|
+
[options]="options()"
|
|
90
|
+
kind="tree"
|
|
91
|
+
[label]="label() ?? 'Tree chart'"
|
|
92
|
+
[zoomable]="zoomable()"
|
|
93
|
+
[selectionMode]="selectionMode()"
|
|
94
|
+
[editable]="editable()"
|
|
95
|
+
[syncId]="syncId()"
|
|
96
|
+
[crosshair]="syncedCrosshair()"
|
|
97
|
+
[responsive]="!!responsive()"
|
|
98
|
+
(itemClick)="itemClick.emit($event)"
|
|
99
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
100
|
+
(taskChange)="taskChange.emit($event)"
|
|
101
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
102
|
+
(zoomChange)="zoom.set($event)"
|
|
103
|
+
(viewChange)="view.set($event)"
|
|
104
|
+
(selectedChange)="selected.set($event)"
|
|
105
|
+
(highlightedChange)="highlighted.set($event)"
|
|
106
|
+
(syncChange)="sync($event)"
|
|
107
|
+
(measured)="measuredWidth.set($event)"
|
|
108
|
+
></skdx-chart-root>
|
|
109
|
+
`,
|
|
110
|
+
}]
|
|
111
|
+
}], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: true }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], nodeShape: [{ type: i0.Input, args: [{ isSignal: true, alias: "nodeShape", required: false }] }], linkStyle: [{ type: i0.Input, args: [{ isSignal: true, alias: "linkStyle", required: false }] }], rootId: [{ type: i0.Input, args: [{ isSignal: true, alias: "rootId", required: false }] }], collapsed: [{ type: i0.Input, args: [{ isSignal: true, alias: "collapsed", required: false }] }], maxDepth: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxDepth", required: false }] }], labels: [{ type: i0.Input, args: [{ isSignal: true, alias: "labels", required: false }] }], nodeSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "nodeSize", required: false }] }] } });
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Generated bundle index. Do not edit.
|
|
115
|
+
*/
|
|
116
|
+
|
|
117
|
+
export { SkdxTreeChartComponent };
|
|
118
|
+
//# sourceMappingURL=skdx-angular-charts-tree.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skdx-angular-charts-tree.mjs","sources":["../../src/tree/index.ts","../../src/tree/skdx-angular-charts-tree.ts"],"sourcesContent":["/*\n * Copyright (c) 2026 SkandaDX\n * This file is part of the SkandaDX organization.\n * Licensed under the MIT License. See LICENSE in the repository root.\n */\n\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\n\nimport {\n layoutTreeChart,\n SkdxChartRootComponent,\n SkdxSizedBase,\n type ChartItemId,\n type TreeNode,\n} from '@skdx/angular-charts/internal';\n\n/** A node-link tree: one dot or box per node with links to its children, top-down or left-right. */\n@Component({\n selector: 'skdx-tree-chart',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [SkdxChartRootComponent],\n template: `\n <skdx-chart-root\n [layout]=\"layout()\"\n [options]=\"options()\"\n kind=\"tree\"\n [label]=\"label() ?? 'Tree chart'\"\n [zoomable]=\"zoomable()\"\n [selectionMode]=\"selectionMode()\"\n [editable]=\"editable()\"\n [syncId]=\"syncId()\"\n [crosshair]=\"syncedCrosshair()\"\n [responsive]=\"!!responsive()\"\n (itemClick)=\"itemClick.emit($event)\"\n (dataIssue)=\"dataIssue.emit($event)\"\n (taskChange)=\"taskChange.emit($event)\"\n (hiddenSeriesChange)=\"toggle($event)\"\n (zoomChange)=\"zoom.set($event)\"\n (viewChange)=\"view.set($event)\"\n (selectedChange)=\"selected.set($event)\"\n (highlightedChange)=\"highlighted.set($event)\"\n (syncChange)=\"sync($event)\"\n (measured)=\"measuredWidth.set($event)\"\n ></skdx-chart-root>\n `,\n})\nexport class SkdxTreeChartComponent extends SkdxSizedBase {\n readonly data = input.required<TreeNode[]>();\n /** Root at the top, or at the left. */\n readonly orientation = input<'vertical' | 'horizontal'>();\n /** Dots with labels beside them, or boxes holding the name. */\n readonly nodeShape = input<'circle' | 'box'>();\n readonly linkStyle = input<'curve' | 'elbow' | 'straight'>();\n /** Id (or name) of the node shown as the root. */\n readonly rootId = input<ChartItemId>();\n /** Nodes whose children are hidden. */\n readonly collapsed = input<ChartItemId[]>();\n /** Deepest level drawn. */\n readonly maxDepth = input<number>();\n /** Write node names. */\n readonly labels = input(true);\n /** Dot radius, or box height, in pixels. */\n readonly nodeSize = input<number>();\n\n protected readonly layout = computed(() =>\n layoutTreeChart({\n ...this.sized(),\n data: this.data(),\n orientation: this.orientation(),\n nodeShape: this.nodeShape(),\n linkStyle: this.linkStyle(),\n rootId: this.rootId(),\n collapsed: this.collapsed(),\n maxDepth: this.maxDepth(),\n labels: this.labels(),\n nodeSize: this.nodeSize(),\n }),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAAA;;;;AAIG;AAYH;AA+BM,MAAO,sBAAuB,SAAQ,aAAa,CAAA;AA9BzD,IAAA,WAAA,GAAA;;QA+BW,IAAA,CAAA,IAAI,GAAG,KAAK,CAAC,QAAQ;iFAAc;;AAEnC,QAAA,IAAA,CAAA,WAAW,GAAG,KAAK;mGAA6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] : /* istanbul ignore next */ []));
|
|
16
|
-
|
|
16
|
+
/** Id (or name) of the node shown as the whole chart: controlled drill-down. */
|
|
17
|
+
this.rootId = input(/* @ts-ignore */
|
|
18
|
+
...(ngDevMode ? [undefined, { debugName: "rootId" }] : /* istanbul ignore next */ []));
|
|
19
|
+
/** Write the path to `rootId` above the tiles. */
|
|
20
|
+
this.breadcrumbs = input(false, /* @ts-ignore */
|
|
21
|
+
...(ngDevMode ? [{ debugName: "breadcrumbs" }] : /* istanbul ignore next */ []));
|
|
22
|
+
/** Deepest level tiled. */
|
|
23
|
+
this.maxDepth = input(/* @ts-ignore */
|
|
24
|
+
...(ngDevMode ? [undefined, { debugName: "maxDepth" }] : /* istanbul ignore next */ []));
|
|
25
|
+
/** Tile order inside a branch. */
|
|
26
|
+
this.sort = input(/* @ts-ignore */
|
|
27
|
+
...(ngDevMode ? [undefined, { debugName: "sort" }] : /* istanbul ignore next */ []));
|
|
28
|
+
/** Inset of children inside their branch, in pixels. */
|
|
29
|
+
this.padding = input(/* @ts-ignore */
|
|
30
|
+
...(ngDevMode ? [undefined, { debugName: "padding" }] : /* istanbul ignore next */ []));
|
|
31
|
+
/** Tiling algorithm. */
|
|
32
|
+
this.tiling = input(/* @ts-ignore */
|
|
33
|
+
...(ngDevMode ? [undefined, { debugName: "tiling" }] : /* istanbul ignore next */ []));
|
|
34
|
+
/** Colors leaves by their value. */
|
|
35
|
+
this.colorScale = input(/* @ts-ignore */
|
|
36
|
+
...(ngDevMode ? [undefined, { debugName: "colorScale" }] : /* istanbul ignore next */ []));
|
|
37
|
+
/** Write leaf names on tiles wide enough. */
|
|
38
|
+
this.labels = input(true, /* @ts-ignore */
|
|
39
|
+
...(ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []));
|
|
40
|
+
this.layout = computed(() => layoutTreemap({
|
|
41
|
+
...this.sized(),
|
|
42
|
+
data: this.data(),
|
|
43
|
+
rootId: this.rootId(),
|
|
44
|
+
breadcrumbs: this.breadcrumbs(),
|
|
45
|
+
maxDepth: this.maxDepth(),
|
|
46
|
+
sort: this.sort(),
|
|
47
|
+
padding: this.padding(),
|
|
48
|
+
tiling: this.tiling(),
|
|
49
|
+
colorScale: this.colorScale(),
|
|
50
|
+
labels: this.labels(),
|
|
51
|
+
}), /* @ts-ignore */
|
|
17
52
|
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
18
53
|
}
|
|
19
54
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxTreemapComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
20
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: SkdxTreemapComponent, isStandalone: true, selector: "skdx-treemap", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
55
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: SkdxTreemapComponent, isStandalone: true, selector: "skdx-treemap", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, rootId: { classPropertyName: "rootId", publicName: "rootId", isSignal: true, isRequired: false, transformFunction: null }, breadcrumbs: { classPropertyName: "breadcrumbs", publicName: "breadcrumbs", isSignal: true, isRequired: false, transformFunction: null }, maxDepth: { classPropertyName: "maxDepth", publicName: "maxDepth", isSignal: true, isRequired: false, transformFunction: null }, sort: { classPropertyName: "sort", publicName: "sort", isSignal: true, isRequired: false, transformFunction: null }, padding: { classPropertyName: "padding", publicName: "padding", isSignal: true, isRequired: false, transformFunction: null }, tiling: { classPropertyName: "tiling", publicName: "tiling", isSignal: true, isRequired: false, transformFunction: null }, colorScale: { classPropertyName: "colorScale", publicName: "colorScale", isSignal: true, isRequired: false, transformFunction: null }, labels: { classPropertyName: "labels", publicName: "labels", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
21
56
|
<skdx-chart-root
|
|
22
57
|
[layout]="layout()"
|
|
58
|
+
[options]="options()"
|
|
23
59
|
kind="treemap"
|
|
24
60
|
[label]="label() ?? 'Treemap'"
|
|
25
61
|
[zoomable]="zoomable()"
|
|
26
|
-
[
|
|
62
|
+
[selectionMode]="selectionMode()"
|
|
63
|
+
[editable]="editable()"
|
|
64
|
+
[syncId]="syncId()"
|
|
65
|
+
[crosshair]="syncedCrosshair()"
|
|
66
|
+
[responsive]="!!responsive()"
|
|
27
67
|
(itemClick)="itemClick.emit($event)"
|
|
68
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
69
|
+
(taskChange)="taskChange.emit($event)"
|
|
28
70
|
(hiddenSeriesChange)="toggle($event)"
|
|
29
71
|
(zoomChange)="zoom.set($event)"
|
|
72
|
+
(viewChange)="view.set($event)"
|
|
73
|
+
(selectedChange)="selected.set($event)"
|
|
74
|
+
(highlightedChange)="highlighted.set($event)"
|
|
75
|
+
(syncChange)="sync($event)"
|
|
30
76
|
(measured)="measuredWidth.set($event)"
|
|
31
77
|
></skdx-chart-root>
|
|
32
|
-
`, isInline: true, dependencies: [{ kind: "component", type: SkdxChartRootComponent, selector: "skdx-chart-root", inputs: ["layout", "kind", "label", "zoomable", "responsive"], outputs: ["itemClick", "hiddenSeriesChange", "zoomChange", "measured"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
78
|
+
`, isInline: true, dependencies: [{ kind: "component", type: SkdxChartRootComponent, selector: "skdx-chart-root", inputs: ["layout", "options", "kind", "label", "zoomable", "selectionMode", "editable", "syncId", "crosshair", "responsive"], outputs: ["itemClick", "hiddenSeriesChange", "zoomChange", "viewChange", "selectedChange", "highlightedChange", "dataIssue", "taskChange", "syncChange", "measured"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
33
79
|
}
|
|
34
80
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxTreemapComponent, decorators: [{
|
|
35
81
|
type: Component,
|
|
@@ -41,18 +87,29 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
|
|
|
41
87
|
template: `
|
|
42
88
|
<skdx-chart-root
|
|
43
89
|
[layout]="layout()"
|
|
90
|
+
[options]="options()"
|
|
44
91
|
kind="treemap"
|
|
45
92
|
[label]="label() ?? 'Treemap'"
|
|
46
93
|
[zoomable]="zoomable()"
|
|
47
|
-
[
|
|
94
|
+
[selectionMode]="selectionMode()"
|
|
95
|
+
[editable]="editable()"
|
|
96
|
+
[syncId]="syncId()"
|
|
97
|
+
[crosshair]="syncedCrosshair()"
|
|
98
|
+
[responsive]="!!responsive()"
|
|
48
99
|
(itemClick)="itemClick.emit($event)"
|
|
100
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
101
|
+
(taskChange)="taskChange.emit($event)"
|
|
49
102
|
(hiddenSeriesChange)="toggle($event)"
|
|
50
103
|
(zoomChange)="zoom.set($event)"
|
|
104
|
+
(viewChange)="view.set($event)"
|
|
105
|
+
(selectedChange)="selected.set($event)"
|
|
106
|
+
(highlightedChange)="highlighted.set($event)"
|
|
107
|
+
(syncChange)="sync($event)"
|
|
51
108
|
(measured)="measuredWidth.set($event)"
|
|
52
109
|
></skdx-chart-root>
|
|
53
110
|
`,
|
|
54
111
|
}]
|
|
55
|
-
}], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: true }] }] } });
|
|
112
|
+
}], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: true }] }], rootId: [{ type: i0.Input, args: [{ isSignal: true, alias: "rootId", required: false }] }], breadcrumbs: [{ type: i0.Input, args: [{ isSignal: true, alias: "breadcrumbs", required: false }] }], maxDepth: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxDepth", required: false }] }], sort: [{ type: i0.Input, args: [{ isSignal: true, alias: "sort", required: false }] }], padding: [{ type: i0.Input, args: [{ isSignal: true, alias: "padding", required: false }] }], tiling: [{ type: i0.Input, args: [{ isSignal: true, alias: "tiling", required: false }] }], colorScale: [{ type: i0.Input, args: [{ isSignal: true, alias: "colorScale", required: false }] }], labels: [{ type: i0.Input, args: [{ isSignal: true, alias: "labels", required: false }] }] } });
|
|
56
113
|
|
|
57
114
|
/**
|
|
58
115
|
* Generated bundle index. Do not edit.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"skdx-angular-charts-treemap.mjs","sources":["../../src/treemap/index.ts","../../src/treemap/skdx-angular-charts-treemap.ts"],"sourcesContent":["/*\n * Copyright (c) 2026 SkandaDX\n * This file is part of the SkandaDX organization.\n * Licensed under the MIT License. See LICENSE in the repository root.\n */\n\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\n\nimport {\n layoutTreemap,\n SkdxChartRootComponent,\n SkdxSizedBase,\n type TreeNode,\n} from '@skdx/angular-charts/internal';\n\n/** Squarified tiles by value; branches are outlined and their children tiled inside. */\n@Component({\n selector: 'skdx-treemap',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [SkdxChartRootComponent],\n template: `\n <skdx-chart-root\n [layout]=\"layout()\"\n kind=\"treemap\"\n [label]=\"label() ?? 'Treemap'\"\n [zoomable]=\"zoomable()\"\n [responsive]=\"responsive()\"\n (itemClick)=\"itemClick.emit($event)\"\n (hiddenSeriesChange)=\"toggle($event)\"\n (zoomChange)=\"zoom.set($event)\"\n (measured)=\"measuredWidth.set($event)\"\n ></skdx-chart-root>\n `,\n})\nexport class SkdxTreemapComponent extends SkdxSizedBase {\n readonly data = input.required<TreeNode[]>();\n\n protected readonly layout = computed(()
|
|
1
|
+
{"version":3,"file":"skdx-angular-charts-treemap.mjs","sources":["../../src/treemap/index.ts","../../src/treemap/skdx-angular-charts-treemap.ts"],"sourcesContent":["/*\n * Copyright (c) 2026 SkandaDX\n * This file is part of the SkandaDX organization.\n * Licensed under the MIT License. See LICENSE in the repository root.\n */\n\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\n\nimport {\n layoutTreemap,\n SkdxChartRootComponent,\n SkdxSizedBase,\n type ChartItemId,\n type ColorScale,\n type TreeNode,\n} from '@skdx/angular-charts/internal';\n\n/** Squarified tiles by value; branches are outlined and their children tiled inside. */\n@Component({\n selector: 'skdx-treemap',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [SkdxChartRootComponent],\n template: `\n <skdx-chart-root\n [layout]=\"layout()\"\n [options]=\"options()\"\n kind=\"treemap\"\n [label]=\"label() ?? 'Treemap'\"\n [zoomable]=\"zoomable()\"\n [selectionMode]=\"selectionMode()\"\n [editable]=\"editable()\"\n [syncId]=\"syncId()\"\n [crosshair]=\"syncedCrosshair()\"\n [responsive]=\"!!responsive()\"\n (itemClick)=\"itemClick.emit($event)\"\n (dataIssue)=\"dataIssue.emit($event)\"\n (taskChange)=\"taskChange.emit($event)\"\n (hiddenSeriesChange)=\"toggle($event)\"\n (zoomChange)=\"zoom.set($event)\"\n (viewChange)=\"view.set($event)\"\n (selectedChange)=\"selected.set($event)\"\n (highlightedChange)=\"highlighted.set($event)\"\n (syncChange)=\"sync($event)\"\n (measured)=\"measuredWidth.set($event)\"\n ></skdx-chart-root>\n `,\n})\nexport class SkdxTreemapComponent extends SkdxSizedBase {\n readonly data = input.required<TreeNode[]>();\n /** Id (or name) of the node shown as the whole chart: controlled drill-down. */\n readonly rootId = input<ChartItemId>();\n /** Write the path to `rootId` above the tiles. */\n readonly breadcrumbs = input(false);\n /** Deepest level tiled. */\n readonly maxDepth = input<number>();\n /** Tile order inside a branch. */\n readonly sort = input<'asc' | 'desc' | 'none'>();\n /** Inset of children inside their branch, in pixels. */\n readonly padding = input<number>();\n /** Tiling algorithm. */\n readonly tiling = input<'squarify' | 'slice' | 'dice' | 'sliceDice'>();\n /** Colors leaves by their value. */\n readonly colorScale = input<ColorScale>();\n /** Write leaf names on tiles wide enough. */\n readonly labels = input(true);\n\n protected readonly layout = computed(() =>\n layoutTreemap({\n ...this.sized(),\n data: this.data(),\n rootId: this.rootId(),\n breadcrumbs: this.breadcrumbs(),\n maxDepth: this.maxDepth(),\n sort: this.sort(),\n padding: this.padding(),\n tiling: this.tiling(),\n colorScale: this.colorScale(),\n labels: this.labels(),\n }),\n );\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAAA;;;;AAIG;AAaH;AA+BM,MAAO,oBAAqB,SAAQ,aAAa,CAAA;AA9BvD,IAAA,WAAA,GAAA;;QA+BW,IAAA,CAAA,IAAI,GAAG,KAAK,CAAC,QAAQ;iFAAc;;AAEnC,QAAA,IAAA,CAAA,MAAM,GAAG,KAAK;8FAAe;;QAE7B,IAAA,CAAA,WAAW,GAAG,KAAK,CAAC,KAAK;wFAAC;;AAE1B,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK;gGAAU;;AAE1B,QAAA,IAAA,CAAA,IAAI,GAAG,KAAK;4FAA2B;;AAEvC,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK;+FAAU;;AAEzB,QAAA,IAAA,CAAA,MAAM,GAAG,KAAK;8FAA+C;;AAE7D,QAAA,IAAA,CAAA,UAAU,GAAG,KAAK;kGAAc;;QAEhC,IAAA,CAAA,MAAM,GAAG,KAAK,CAAC,IAAI;mFAAC;AAEV,QAAA,IAAA,CAAA,MAAM,GAAG,QAAQ,CAAC,MACnC,aAAa,CAAC;YACZ,GAAG,IAAI,CAAC,KAAK,EAAE;AACf,YAAA,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE;AACjB,YAAA,MAAM,EAAE,IAAI,CAAC,MAAM,EAAE;AACrB,YAAA,WAAW,EAAE,IAAI,CAAC,WAAW,EAAE;AAC/B,YAAA,QAAQ,EAAE,IAAI,CAAC,QAAQ,EAAE;AACzB,YAAA,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE;AACjB,YAAA,OAAO,EAA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,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBA9BhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,cAAc;AACxB,oBAAA,UAAU,EAAE,IAAI;oBAChB,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,OAAO,EAAE,CAAC,sBAAsB,CAAC;AACjC,oBAAA,QAAQ,EAAE;;;;;;;;;;;;;;;;;;;;;;;AAuBT,EAAA,CAAA;AACF,iBAAA;;;AC/CD;;AAEG;;"}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
3
|
+
import { SkdxSizedBase, layoutWaffleChart, SkdxChartRootComponent } from '@skdx/angular-charts/internal';
|
|
4
|
+
|
|
5
|
+
/*
|
|
6
|
+
* Copyright (c) 2026 SkandaDX
|
|
7
|
+
* This file is part of the SkandaDX organization.
|
|
8
|
+
* Licensed under the MIT License. See LICENSE in the repository root.
|
|
9
|
+
*/
|
|
10
|
+
/** A grid of cells, each standing for a share of the total, colored by datum. */
|
|
11
|
+
class SkdxWaffleChartComponent extends SkdxSizedBase {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
this.data = input.required(/* @ts-ignore */
|
|
15
|
+
...(ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []));
|
|
16
|
+
/** What the whole grid stands for. */
|
|
17
|
+
this.total = input(/* @ts-ignore */
|
|
18
|
+
...(ngDevMode ? [undefined, { debugName: "total" }] : /* istanbul ignore next */ []));
|
|
19
|
+
this.rows = input(/* @ts-ignore */
|
|
20
|
+
...(ngDevMode ? [undefined, { debugName: "rows" }] : /* istanbul ignore next */ []));
|
|
21
|
+
this.columns = input(/* @ts-ignore */
|
|
22
|
+
...(ngDevMode ? [undefined, { debugName: "columns" }] : /* istanbul ignore next */ []));
|
|
23
|
+
/** Fill direction. */
|
|
24
|
+
this.orientation = input(/* @ts-ignore */
|
|
25
|
+
...(ngDevMode ? [undefined, { debugName: "orientation" }] : /* istanbul ignore next */ []));
|
|
26
|
+
/** Gap between cells in pixels. */
|
|
27
|
+
this.cellGap = input(/* @ts-ignore */
|
|
28
|
+
...(ngDevMode ? [undefined, { debugName: "cellGap" }] : /* istanbul ignore next */ []));
|
|
29
|
+
/** Cell corner radius in pixels. */
|
|
30
|
+
this.cellRadius = input(/* @ts-ignore */
|
|
31
|
+
...(ngDevMode ? [undefined, { debugName: "cellRadius" }] : /* istanbul ignore next */ []));
|
|
32
|
+
/** Write each datum's share after its name in the legend. */
|
|
33
|
+
this.labels = input(false, /* @ts-ignore */
|
|
34
|
+
...(ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []));
|
|
35
|
+
this.layout = computed(() => layoutWaffleChart({
|
|
36
|
+
...this.sized(),
|
|
37
|
+
data: this.data(),
|
|
38
|
+
total: this.total(),
|
|
39
|
+
rows: this.rows(),
|
|
40
|
+
columns: this.columns(),
|
|
41
|
+
orientation: this.orientation(),
|
|
42
|
+
cellGap: this.cellGap(),
|
|
43
|
+
cellRadius: this.cellRadius(),
|
|
44
|
+
labels: this.labels(),
|
|
45
|
+
}), /* @ts-ignore */
|
|
46
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
47
|
+
}
|
|
48
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxWaffleChartComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
49
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: SkdxWaffleChartComponent, isStandalone: true, selector: "skdx-waffle-chart", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: true, transformFunction: null }, total: { classPropertyName: "total", publicName: "total", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, columns: { classPropertyName: "columns", publicName: "columns", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, cellGap: { classPropertyName: "cellGap", publicName: "cellGap", isSignal: true, isRequired: false, transformFunction: null }, cellRadius: { classPropertyName: "cellRadius", publicName: "cellRadius", isSignal: true, isRequired: false, transformFunction: null }, labels: { classPropertyName: "labels", publicName: "labels", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: `
|
|
50
|
+
<skdx-chart-root
|
|
51
|
+
[layout]="layout()"
|
|
52
|
+
[options]="options()"
|
|
53
|
+
kind="waffle"
|
|
54
|
+
[label]="label() ?? 'Waffle chart'"
|
|
55
|
+
[zoomable]="zoomable()"
|
|
56
|
+
[selectionMode]="selectionMode()"
|
|
57
|
+
[editable]="editable()"
|
|
58
|
+
[syncId]="syncId()"
|
|
59
|
+
[crosshair]="syncedCrosshair()"
|
|
60
|
+
[responsive]="!!responsive()"
|
|
61
|
+
(itemClick)="itemClick.emit($event)"
|
|
62
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
63
|
+
(taskChange)="taskChange.emit($event)"
|
|
64
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
65
|
+
(zoomChange)="zoom.set($event)"
|
|
66
|
+
(viewChange)="view.set($event)"
|
|
67
|
+
(selectedChange)="selected.set($event)"
|
|
68
|
+
(highlightedChange)="highlighted.set($event)"
|
|
69
|
+
(syncChange)="sync($event)"
|
|
70
|
+
(measured)="measuredWidth.set($event)"
|
|
71
|
+
></skdx-chart-root>
|
|
72
|
+
`, isInline: true, dependencies: [{ kind: "component", type: SkdxChartRootComponent, selector: "skdx-chart-root", inputs: ["layout", "options", "kind", "label", "zoomable", "selectionMode", "editable", "syncId", "crosshair", "responsive"], outputs: ["itemClick", "hiddenSeriesChange", "zoomChange", "viewChange", "selectedChange", "highlightedChange", "dataIssue", "taskChange", "syncChange", "measured"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
73
|
+
}
|
|
74
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: SkdxWaffleChartComponent, decorators: [{
|
|
75
|
+
type: Component,
|
|
76
|
+
args: [{
|
|
77
|
+
selector: 'skdx-waffle-chart',
|
|
78
|
+
standalone: true,
|
|
79
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
80
|
+
imports: [SkdxChartRootComponent],
|
|
81
|
+
template: `
|
|
82
|
+
<skdx-chart-root
|
|
83
|
+
[layout]="layout()"
|
|
84
|
+
[options]="options()"
|
|
85
|
+
kind="waffle"
|
|
86
|
+
[label]="label() ?? 'Waffle chart'"
|
|
87
|
+
[zoomable]="zoomable()"
|
|
88
|
+
[selectionMode]="selectionMode()"
|
|
89
|
+
[editable]="editable()"
|
|
90
|
+
[syncId]="syncId()"
|
|
91
|
+
[crosshair]="syncedCrosshair()"
|
|
92
|
+
[responsive]="!!responsive()"
|
|
93
|
+
(itemClick)="itemClick.emit($event)"
|
|
94
|
+
(dataIssue)="dataIssue.emit($event)"
|
|
95
|
+
(taskChange)="taskChange.emit($event)"
|
|
96
|
+
(hiddenSeriesChange)="toggle($event)"
|
|
97
|
+
(zoomChange)="zoom.set($event)"
|
|
98
|
+
(viewChange)="view.set($event)"
|
|
99
|
+
(selectedChange)="selected.set($event)"
|
|
100
|
+
(highlightedChange)="highlighted.set($event)"
|
|
101
|
+
(syncChange)="sync($event)"
|
|
102
|
+
(measured)="measuredWidth.set($event)"
|
|
103
|
+
></skdx-chart-root>
|
|
104
|
+
`,
|
|
105
|
+
}]
|
|
106
|
+
}], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: true }] }], total: [{ type: i0.Input, args: [{ isSignal: true, alias: "total", required: false }] }], rows: [{ type: i0.Input, args: [{ isSignal: true, alias: "rows", required: false }] }], columns: [{ type: i0.Input, args: [{ isSignal: true, alias: "columns", required: false }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], cellGap: [{ type: i0.Input, args: [{ isSignal: true, alias: "cellGap", required: false }] }], cellRadius: [{ type: i0.Input, args: [{ isSignal: true, alias: "cellRadius", required: false }] }], labels: [{ type: i0.Input, args: [{ isSignal: true, alias: "labels", required: false }] }] } });
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* Generated bundle index. Do not edit.
|
|
110
|
+
*/
|
|
111
|
+
|
|
112
|
+
export { SkdxWaffleChartComponent };
|
|
113
|
+
//# sourceMappingURL=skdx-angular-charts-waffle.mjs.map
|