@pioneer-code/pioneer-charts 17.0.1 → 18.0.1
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/esm2022/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.builder.mjs +4 -4
- package/esm2022/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.component.mjs +6 -6
- package/esm2022/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.model.mjs +21 -2
- package/esm2022/lib/bar-chart/bar-horizontal-chart/public_api.mjs +1 -2
- package/esm2022/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.builder.mjs +4 -4
- package/esm2022/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.component.mjs +5 -5
- package/esm2022/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.model.mjs +21 -2
- package/esm2022/lib/bar-chart/bar-vertical-chart/public_api.mjs +1 -2
- package/esm2022/lib/core/axis.builder.mjs +4 -4
- package/esm2022/lib/core/chart.mjs +4 -4
- package/esm2022/lib/core/chart.model.mjs +22 -1
- package/esm2022/lib/core/color.service.mjs +4 -4
- package/esm2022/lib/core/grid.builder.mjs +3 -3
- package/esm2022/lib/core/tooltip.builder.mjs +7 -6
- package/esm2022/lib/core/transition.service.mjs +3 -3
- package/esm2022/lib/line-area-chart/line-area-chart-effects.builders.mjs +4 -4
- package/esm2022/lib/line-area-chart/line-area-chart.builder.mjs +4 -4
- package/esm2022/lib/line-area-chart/line-area-chart.component.mjs +5 -5
- package/esm2022/lib/line-area-chart/line-area-chart.model.mjs +14 -2
- package/esm2022/lib/line-area-chart/public_api.mjs +1 -2
- package/esm2022/lib/pie-chart/pie-chart.builder.mjs +4 -4
- package/esm2022/lib/pie-chart/pie-chart.component.mjs +5 -5
- package/esm2022/lib/pie-chart/pie-chart.model.mjs +8 -2
- package/esm2022/lib/pie-chart/public_api.mjs +1 -2
- package/fesm2022/pioneer-code-pioneer-charts.mjs +128 -121
- package/fesm2022/pioneer-code-pioneer-charts.mjs.map +1 -1
- package/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.builder.d.ts +4 -4
- package/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.component.d.ts +7 -7
- package/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.model.d.ts +9 -9
- package/lib/bar-chart/bar-horizontal-chart/public_api.d.ts +0 -1
- package/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.builder.d.ts +5 -5
- package/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.component.d.ts +5 -5
- package/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.model.d.ts +9 -9
- package/lib/bar-chart/bar-vertical-chart/public_api.d.ts +0 -1
- package/lib/core/chart.d.ts +4 -4
- package/lib/core/chart.model.d.ts +6 -6
- package/lib/core/tooltip.builder.d.ts +2 -2
- package/lib/line-area-chart/line-area-chart-effects.builders.d.ts +2 -2
- package/lib/line-area-chart/line-area-chart.builder.d.ts +4 -4
- package/lib/line-area-chart/line-area-chart.component.d.ts +5 -5
- package/lib/line-area-chart/line-area-chart.model.d.ts +2 -2
- package/lib/line-area-chart/public_api.d.ts +0 -1
- package/lib/pie-chart/pie-chart.builder.d.ts +4 -4
- package/lib/pie-chart/pie-chart.component.d.ts +5 -5
- package/lib/pie-chart/pie-chart.model.d.ts +2 -2
- package/lib/pie-chart/public_api.d.ts +0 -1
- package/package.json +5 -5
- package/scss/{lib/line-area-chart → line-area-chart}/line-area-chart.component.scss +0 -1
- package/themes/pioneer-charts.css +6 -5
- package/themes/pioneer-charts.min.css +1 -3
- package/esm2022/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.module.mjs +0 -20
- package/esm2022/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.module.mjs +0 -20
- package/esm2022/lib/line-area-chart/line-area-chart.module.mjs +0 -24
- package/esm2022/lib/pie-chart/pie-chart.module.mjs +0 -24
- package/lib/bar-chart/bar-horizontal-chart/bar-horizontal-chart.module.d.ts +0 -7
- package/lib/bar-chart/bar-vertical-chart/bar-vertical-chart.module.d.ts +0 -7
- package/lib/line-area-chart/line-area-chart.module.d.ts +0 -8
- package/lib/pie-chart/pie-chart.module.d.ts +0 -8
- package/themes/pioneer-charts.css.map +0 -10
- package/themes/pioneer-charts.min.css.map +0 -10
- /package/scss/{lib/bar-chart → bar-chart}/bar-horizontal-chart/bar-horizontal-chart.component.scss +0 -0
- /package/scss/{lib/bar-chart → bar-chart}/bar-vertical-chart/bar-vertical-chart.component.scss +0 -0
- /package/scss/{lib/core → core}/theme/imports.scss +0 -0
- /package/scss/{lib/pie-chart → pie-chart}/pie-chart.component.scss +0 -0
- /package/scss/{lib/pioneer-charts.scss → pioneer-charts.scss} +0 -0
|
@@ -27,12 +27,12 @@ export class PcacPieChartComponent {
|
|
|
27
27
|
self.buildChart();
|
|
28
28
|
}, 300);
|
|
29
29
|
}
|
|
30
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
31
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
30
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacPieChartComponent, deps: [{ token: i1.PieChartBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
31
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.2", type: PcacPieChartComponent, isStandalone: true, selector: "pcac-pie-chart", inputs: { config: "config" }, outputs: { sliceClicked: "sliceClicked" }, host: { listeners: { "window:resize": "onResize()" } }, viewQueries: [{ propertyName: "chartElm", first: true, predicate: ["chart"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<section class=\"pcac-pie-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-pie-chart svg{width:100%;display:block}.pcac-pie-chart .dot{fill:none;stroke-width:1px}\n"], encapsulation: i0.ViewEncapsulation.None }); }
|
|
32
32
|
}
|
|
33
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
33
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacPieChartComponent, decorators: [{
|
|
34
34
|
type: Component,
|
|
35
|
-
args: [{ selector: 'pcac-pie-chart', encapsulation: ViewEncapsulation.None, template: "<section class=\"pcac-pie-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-pie-chart svg{width:100%;display:block}.pcac-pie-chart .dot{fill:none;stroke-width:1px}\n"] }]
|
|
35
|
+
args: [{ selector: 'pcac-pie-chart', encapsulation: ViewEncapsulation.None, standalone: true, template: "<section class=\"pcac-pie-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-pie-chart svg{width:100%;display:block}.pcac-pie-chart .dot{fill:none;stroke-width:1px}\n"] }]
|
|
36
36
|
}], ctorParameters: () => [{ type: i1.PieChartBuilder }], propDecorators: { config: [{
|
|
37
37
|
type: Input
|
|
38
38
|
}], chartElm: [{
|
|
@@ -44,4 +44,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
|
|
|
44
44
|
type: HostListener,
|
|
45
45
|
args: ['window:resize']
|
|
46
46
|
}] } });
|
|
47
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
47
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGllLWNoYXJ0LmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3Bpb25lZXItY29kZS9waW9uZWVyLWNoYXJ0cy9zcmMvbGliL3BpZS1jaGFydC9waWUtY2hhcnQuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvcGlvbmVlci1jb2RlL3Bpb25lZXItY2hhcn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mlnKTtcbiAgICB9XG4gIH1cblxuICAvKipcbiAgICogT3B0aW5nIGFnYWluc3QgZnJvbUV2ZW50IGR1ZSB0byBpbmNvbXBhdGliaWxpdHkgd2l0aCByeGpzIDUgPT4gNlxuICAgKi9cbiAgQEhvc3RMaXN0ZW5lcignd2luZG93OnJlc2l6ZScpXG4gIG9uUmVzaXplKCkge1xuICAgIGNvbnN0IHNlbGYgPSB0aGlzO1xuICAgIGNsZWFyVGltZW91dCh0aGlzLnJlc2l6ZVdpbmRvd1RpbWVvdXQpO1xuICAgIHRoaXMucmVzaXplV2luZG93VGltZW91dCA9IHNldFRpbWVvdXQoKCkgPT4ge1xuICAgICAgc2VsZi5idWlsZENoYXJ0KCk7XG4gICAgfSwgMzAwKTtcbiAgfVxufVxuIiwiPHNlY3Rpb24gY2xhc3M9XCJwY2FjLXBpZS1jaGFydFwiPlxuICA8c3ZnICNjaGFydD48L3N2Zz5cbjwvc2VjdGlvbj5cblxuIl19
|
|
@@ -1,2 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { PcacChartConfig } from '../core/chart.model';
|
|
2
|
+
export class PcacPieChartConfig extends PcacChartConfig {
|
|
3
|
+
constructor() {
|
|
4
|
+
super(...arguments);
|
|
5
|
+
this.numberOfTicks = 5;
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGllLWNoYXJ0Lm1vZGVsLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvcGlvbmVlci1jb2RlL3Bpb25lZXItY2hhcnRzL3NyYy9saWIvcGllLWNoYXJ0L3BpZS1jaGFydC5tb2RlbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsZUFBZSxFQUFFLE1BQU0scUJBQXFCLENBQUM7QUFFdEQsTUFBTSxPQUFPLGtCQUFtQixTQUFRLGVBQWU7SUFBdkQ7O1FBQ0Usa0JBQWEsR0FBVyxDQUFDLENBQUE7SUFDM0IsQ0FBQztDQUFBIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgUGNhY0NoYXJ0Q29uZmlnIH0gZnJvbSAnLi4vY29yZS9jaGFydC5tb2RlbCc7XG5cbmV4cG9ydCBjbGFzcyBQY2FjUGllQ2hhcnRDb25maWcgZXh0ZW5kcyBQY2FjQ2hhcnRDb25maWcgIHtcbiAgbnVtYmVyT2ZUaWNrczogbnVtYmVyID0gNVxufVxuIl19
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export * from './pie-chart.builder';
|
|
2
2
|
export * from './pie-chart.component';
|
|
3
3
|
export * from './pie-chart.model';
|
|
4
|
-
|
|
5
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljX2FwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3Bpb25lZXItY29kZS9waW9uZWVyLWNoYXJ0cy9zcmMvbGliL3BpZS1jaGFydC9wdWJsaWNfYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGNBQWMscUJBQXFCLENBQUM7QUFDcEMsY0FBYyx1QkFBdUIsQ0FBQztBQUN0QyxjQUFjLG1CQUFtQixDQUFDO0FBQ2xDLGNBQWMsb0JBQW9CLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyJleHBvcnQgKiBmcm9tICcuL3BpZS1jaGFydC5idWlsZGVyJztcbmV4cG9ydCAqIGZyb20gJy4vcGllLWNoYXJ0LmNvbXBvbmVudCc7XG5leHBvcnQgKiBmcm9tICcuL3BpZS1jaGFydC5tb2RlbCc7XG5leHBvcnQgKiBmcm9tICcuL3BpZS1jaGFydC5tb2R1bGUnO1xuIl19
|
|
4
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljX2FwaS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL3Bpb25lZXItY29kZS9waW9uZWVyLWNoYXJ0cy9zcmMvbGliL3BpZS1jaGFydC9wdWJsaWNfYXBpLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGNBQWMscUJBQXFCLENBQUM7QUFDcEMsY0FBYyx1QkFBdUIsQ0FBQztBQUN0QyxjQUFjLG1CQUFtQixDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0ICogZnJvbSAnLi9waWUtY2hhcnQuYnVpbGRlcic7XG5leHBvcnQgKiBmcm9tICcuL3BpZS1jaGFydC5jb21wb25lbnQnO1xuZXhwb3J0ICogZnJvbSAnLi9waWUtY2hhcnQubW9kZWwnO1xuIl19
|
|
@@ -1,17 +1,37 @@
|
|
|
1
1
|
import { axisLeft, axisBottom } from 'd3-axis';
|
|
2
2
|
import { select as select$1 } from 'd3-selection';
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
|
-
import { Injectable, EventEmitter, Component, ViewEncapsulation, Input, ViewChild, Output, HostListener
|
|
4
|
+
import { Injectable, EventEmitter, Component, ViewEncapsulation, Input, ViewChild, Output, HostListener } from '@angular/core';
|
|
5
5
|
import { select, scaleTime } from 'd3';
|
|
6
6
|
import { transition } from 'd3-transition';
|
|
7
7
|
import { scaleLinear, scaleBand } from 'd3-scale';
|
|
8
8
|
import { line, area, arc, pie } from 'd3-shape';
|
|
9
9
|
import { range } from 'd3-array';
|
|
10
10
|
import { Subject } from 'rxjs';
|
|
11
|
-
import { CommonModule } from '@angular/common';
|
|
12
11
|
import { interpolate } from 'd3-interpolate';
|
|
13
12
|
import { color } from 'd3-color';
|
|
14
13
|
|
|
14
|
+
/**
|
|
15
|
+
* Base configuration for all charts.
|
|
16
|
+
* INewChart extends IChart
|
|
17
|
+
*/
|
|
18
|
+
class PcacChartConfig {
|
|
19
|
+
constructor() {
|
|
20
|
+
/**
|
|
21
|
+
* Height in pixels
|
|
22
|
+
*/
|
|
23
|
+
this.height = 200;
|
|
24
|
+
this.data = [];
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
class PcacData {
|
|
28
|
+
constructor() {
|
|
29
|
+
this.key = null;
|
|
30
|
+
this.value = null;
|
|
31
|
+
this.hide = false;
|
|
32
|
+
this.data = [];
|
|
33
|
+
}
|
|
34
|
+
}
|
|
15
35
|
var PcacFormatEnum;
|
|
16
36
|
(function (PcacFormatEnum) {
|
|
17
37
|
PcacFormatEnum["None"] = "none";
|
|
@@ -69,10 +89,10 @@ class PcacAxisBuilder {
|
|
|
69
89
|
.attr('transform', 'translate(0,' + config.height + ')')
|
|
70
90
|
.call(xAxis);
|
|
71
91
|
}
|
|
72
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
73
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
92
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacAxisBuilder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
93
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacAxisBuilder, providedIn: 'root' }); }
|
|
74
94
|
}
|
|
75
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
95
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacAxisBuilder, decorators: [{
|
|
76
96
|
type: Injectable,
|
|
77
97
|
args: [{
|
|
78
98
|
providedIn: 'root',
|
|
@@ -107,10 +127,10 @@ class PcacGridBuilder {
|
|
|
107
127
|
.attr('x2', config.width)
|
|
108
128
|
.attr('class', (_, i) => (i === 0 ? 'pcac-grid-rule-last' : ''));
|
|
109
129
|
}
|
|
110
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
111
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
130
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacGridBuilder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
131
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacGridBuilder, providedIn: 'root' }); }
|
|
112
132
|
}
|
|
113
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
133
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacGridBuilder, decorators: [{
|
|
114
134
|
type: Injectable,
|
|
115
135
|
args: [{
|
|
116
136
|
providedIn: 'root',
|
|
@@ -124,10 +144,10 @@ class PcacTransitionService {
|
|
|
124
144
|
getTransitionDuration() {
|
|
125
145
|
return this.transitionDuration;
|
|
126
146
|
}
|
|
127
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
128
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
147
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacTransitionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
148
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacTransitionService, providedIn: 'root' }); }
|
|
129
149
|
}
|
|
130
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
150
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacTransitionService, decorators: [{
|
|
131
151
|
type: Injectable,
|
|
132
152
|
args: [{
|
|
133
153
|
providedIn: 'root',
|
|
@@ -162,7 +182,7 @@ class PcacTooltipBuilder {
|
|
|
162
182
|
break;
|
|
163
183
|
}
|
|
164
184
|
}
|
|
165
|
-
if (keyFormat) {
|
|
185
|
+
if (key && keyFormat) {
|
|
166
186
|
switch (keyFormat) {
|
|
167
187
|
case PcacFormatEnum.DateTime:
|
|
168
188
|
key = new Date(key).toLocaleDateString('en-US', {
|
|
@@ -176,12 +196,13 @@ class PcacTooltipBuilder {
|
|
|
176
196
|
break;
|
|
177
197
|
}
|
|
178
198
|
}
|
|
179
|
-
|
|
199
|
+
let finalValue = value ? value.toString() : null;
|
|
200
|
+
return key ? key + '</br>' + finalValue : finalValue;
|
|
180
201
|
}
|
|
181
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
182
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
202
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacTooltipBuilder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
203
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacTooltipBuilder, providedIn: 'root' }); }
|
|
183
204
|
}
|
|
184
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
205
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacTooltipBuilder, decorators: [{
|
|
185
206
|
type: Injectable,
|
|
186
207
|
args: [{
|
|
187
208
|
providedIn: 'root',
|
|
@@ -250,10 +271,10 @@ class PcacColorService {
|
|
|
250
271
|
setAlert() {
|
|
251
272
|
return this.alert;
|
|
252
273
|
}
|
|
253
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
254
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
274
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacColorService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
275
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacColorService, providedIn: 'root' }); }
|
|
255
276
|
}
|
|
256
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
277
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacColorService, decorators: [{
|
|
257
278
|
type: Injectable,
|
|
258
279
|
args: [{
|
|
259
280
|
providedIn: 'root',
|
|
@@ -331,10 +352,10 @@ class PcacChart {
|
|
|
331
352
|
this.margin.bottom = this.margin.bottom;
|
|
332
353
|
this.width = this.width - this.margin.left;
|
|
333
354
|
}
|
|
334
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
335
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
355
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacChart, deps: [{ token: PcacAxisBuilder }, { token: PcacGridBuilder }, { token: PcacTransitionService }, { token: PcacTooltipBuilder }, { token: PcacColorService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
356
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacChart, providedIn: 'root' }); }
|
|
336
357
|
}
|
|
337
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
358
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacChart, decorators: [{
|
|
338
359
|
type: Injectable,
|
|
339
360
|
args: [{
|
|
340
361
|
providedIn: 'root',
|
|
@@ -455,10 +476,10 @@ class LineAreaChartEffectsBuilder {
|
|
|
455
476
|
return 'translate(' + mousePos[0] + ',' + pos.y + ')';
|
|
456
477
|
});
|
|
457
478
|
}
|
|
458
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
459
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
479
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: LineAreaChartEffectsBuilder, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
480
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: LineAreaChartEffectsBuilder, providedIn: 'root' }); }
|
|
460
481
|
}
|
|
461
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
482
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: LineAreaChartEffectsBuilder, decorators: [{
|
|
462
483
|
type: Injectable,
|
|
463
484
|
args: [{
|
|
464
485
|
providedIn: 'root',
|
|
@@ -665,10 +686,10 @@ class LineAreaChartBuilder extends PcacChart {
|
|
|
665
686
|
return this.xScale(index);
|
|
666
687
|
}
|
|
667
688
|
}
|
|
668
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
669
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
689
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: LineAreaChartBuilder, deps: [{ token: PcacAxisBuilder }, { token: PcacGridBuilder }, { token: PcacTransitionService }, { token: PcacTooltipBuilder }, { token: PcacColorService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
690
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: LineAreaChartBuilder, providedIn: 'root' }); }
|
|
670
691
|
}
|
|
671
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
692
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: LineAreaChartBuilder, decorators: [{
|
|
672
693
|
type: Injectable,
|
|
673
694
|
args: [{
|
|
674
695
|
providedIn: 'root',
|
|
@@ -703,12 +724,12 @@ class PcacLineAreaChartComponent {
|
|
|
703
724
|
self.buildChart();
|
|
704
725
|
}, 300);
|
|
705
726
|
}
|
|
706
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
707
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
727
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacLineAreaChartComponent, deps: [{ token: LineAreaChartBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
728
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.2", type: PcacLineAreaChartComponent, isStandalone: true, selector: "pcac-line-area-chart", inputs: { config: "config" }, outputs: { dotClicked: "dotClicked" }, host: { listeners: { "window:resize": "onResize()" } }, viewQueries: [{ propertyName: "chartElm", first: true, predicate: ["chart"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<section class=\"pcac-line-area-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-line-area-chart svg{width:100%;display:block}.pcac-line-area-chart .dot{stroke-width:2px}.pcac-line-area-chart .effects-canvas{fill:none}.pcac-line-area-chart .effect-line{stroke:#ced4da;stroke-width:1px;opacity:0}.pcac-line-area-chart .effect-circle{stroke-width:1px;fill:none;opacity:0}.pcac-line-area-chart .effect-text{font-size:11px;font-weight:700;fill:#343a40}\n"], encapsulation: i0.ViewEncapsulation.None }); }
|
|
708
729
|
}
|
|
709
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
730
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacLineAreaChartComponent, decorators: [{
|
|
710
731
|
type: Component,
|
|
711
|
-
args: [{ selector: 'pcac-line-area-chart', encapsulation: ViewEncapsulation.None, template: "<section class=\"pcac-line-area-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-line-area-chart svg{width:100%;display:block
|
|
732
|
+
args: [{ selector: 'pcac-line-area-chart', encapsulation: ViewEncapsulation.None, standalone: true, template: "<section class=\"pcac-line-area-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-line-area-chart svg{width:100%;display:block}.pcac-line-area-chart .dot{stroke-width:2px}.pcac-line-area-chart .effects-canvas{fill:none}.pcac-line-area-chart .effect-line{stroke:#ced4da;stroke-width:1px;opacity:0}.pcac-line-area-chart .effect-circle{stroke-width:1px;fill:none;opacity:0}.pcac-line-area-chart .effect-text{font-size:11px;font-weight:700;fill:#343a40}\n"] }]
|
|
712
733
|
}], ctorParameters: () => [{ type: LineAreaChartBuilder }], propDecorators: { config: [{
|
|
713
734
|
type: Input
|
|
714
735
|
}], chartElm: [{
|
|
@@ -721,25 +742,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
|
|
|
721
742
|
args: ['window:resize']
|
|
722
743
|
}] } });
|
|
723
744
|
|
|
724
|
-
class
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
745
|
+
class PcacLineAreaChartConfig extends PcacChartConfig {
|
|
746
|
+
constructor() {
|
|
747
|
+
super(...arguments);
|
|
748
|
+
this.isArea = false;
|
|
749
|
+
this.enableEffects = true;
|
|
750
|
+
this.numberOfTicks = 5;
|
|
751
|
+
this.hideGrid = false;
|
|
752
|
+
this.hideAxis = false;
|
|
753
|
+
this.yFormat = PcacFormatEnum.None;
|
|
754
|
+
this.xFormat = PcacFormatEnum.None;
|
|
755
|
+
}
|
|
728
756
|
}
|
|
729
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: PcacLineAreaChartModule, decorators: [{
|
|
730
|
-
type: NgModule,
|
|
731
|
-
args: [{
|
|
732
|
-
declarations: [
|
|
733
|
-
PcacLineAreaChartComponent
|
|
734
|
-
],
|
|
735
|
-
imports: [
|
|
736
|
-
CommonModule,
|
|
737
|
-
],
|
|
738
|
-
exports: [
|
|
739
|
-
PcacLineAreaChartComponent
|
|
740
|
-
]
|
|
741
|
-
}]
|
|
742
|
-
}] });
|
|
743
757
|
|
|
744
758
|
class PieChartBuilder extends PcacChart {
|
|
745
759
|
constructor(axisBuilder, gridBuilder, transitionService, tooltipBuilder, colorService) {
|
|
@@ -813,10 +827,10 @@ class PieChartBuilder extends PcacChart {
|
|
|
813
827
|
const i = interpolate({ startAngle: 0, endAngle: 0 }, b);
|
|
814
828
|
return (t) => this.arcShape(i(t)); // TODO: Strongly type
|
|
815
829
|
}
|
|
816
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
817
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
830
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PieChartBuilder, deps: [{ token: PcacAxisBuilder }, { token: PcacGridBuilder }, { token: PcacTransitionService }, { token: PcacTooltipBuilder }, { token: PcacColorService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
831
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PieChartBuilder, providedIn: 'root' }); }
|
|
818
832
|
}
|
|
819
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
833
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PieChartBuilder, decorators: [{
|
|
820
834
|
type: Injectable,
|
|
821
835
|
args: [{
|
|
822
836
|
providedIn: 'root',
|
|
@@ -849,12 +863,12 @@ class PcacPieChartComponent {
|
|
|
849
863
|
self.buildChart();
|
|
850
864
|
}, 300);
|
|
851
865
|
}
|
|
852
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
853
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
866
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacPieChartComponent, deps: [{ token: PieChartBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
867
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.2", type: PcacPieChartComponent, isStandalone: true, selector: "pcac-pie-chart", inputs: { config: "config" }, outputs: { sliceClicked: "sliceClicked" }, host: { listeners: { "window:resize": "onResize()" } }, viewQueries: [{ propertyName: "chartElm", first: true, predicate: ["chart"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<section class=\"pcac-pie-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-pie-chart svg{width:100%;display:block}.pcac-pie-chart .dot{fill:none;stroke-width:1px}\n"], encapsulation: i0.ViewEncapsulation.None }); }
|
|
854
868
|
}
|
|
855
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
869
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacPieChartComponent, decorators: [{
|
|
856
870
|
type: Component,
|
|
857
|
-
args: [{ selector: 'pcac-pie-chart', encapsulation: ViewEncapsulation.None, template: "<section class=\"pcac-pie-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-pie-chart svg{width:100%;display:block}.pcac-pie-chart .dot{fill:none;stroke-width:1px}\n"] }]
|
|
871
|
+
args: [{ selector: 'pcac-pie-chart', encapsulation: ViewEncapsulation.None, standalone: true, template: "<section class=\"pcac-pie-chart\">\n <svg #chart></svg>\n</section>\n\n", styles: [".pcac-pie-chart svg{width:100%;display:block}.pcac-pie-chart .dot{fill:none;stroke-width:1px}\n"] }]
|
|
858
872
|
}], ctorParameters: () => [{ type: PieChartBuilder }], propDecorators: { config: [{
|
|
859
873
|
type: Input
|
|
860
874
|
}], chartElm: [{
|
|
@@ -867,25 +881,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
|
|
|
867
881
|
args: ['window:resize']
|
|
868
882
|
}] } });
|
|
869
883
|
|
|
870
|
-
class
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
884
|
+
class PcacPieChartConfig extends PcacChartConfig {
|
|
885
|
+
constructor() {
|
|
886
|
+
super(...arguments);
|
|
887
|
+
this.numberOfTicks = 5;
|
|
888
|
+
}
|
|
874
889
|
}
|
|
875
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: PcacPieChartModule, decorators: [{
|
|
876
|
-
type: NgModule,
|
|
877
|
-
args: [{
|
|
878
|
-
exports: [
|
|
879
|
-
PcacPieChartComponent
|
|
880
|
-
],
|
|
881
|
-
imports: [
|
|
882
|
-
CommonModule,
|
|
883
|
-
],
|
|
884
|
-
declarations: [
|
|
885
|
-
PcacPieChartComponent
|
|
886
|
-
]
|
|
887
|
-
}]
|
|
888
|
-
}] });
|
|
889
890
|
|
|
890
891
|
class BarHorizontalChartBuilder extends PcacChart {
|
|
891
892
|
constructor(axisBuilder, gridBuilder, transitionService, tooltipBuilder, colorService) {
|
|
@@ -1135,17 +1136,17 @@ class BarHorizontalChartBuilder extends PcacChart {
|
|
|
1135
1136
|
this.tooltipBuilder.hideTooltip();
|
|
1136
1137
|
});
|
|
1137
1138
|
}
|
|
1138
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1139
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1139
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: BarHorizontalChartBuilder, deps: [{ token: PcacAxisBuilder }, { token: PcacGridBuilder }, { token: PcacTransitionService }, { token: PcacTooltipBuilder }, { token: PcacColorService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1140
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: BarHorizontalChartBuilder, providedIn: 'root' }); }
|
|
1140
1141
|
}
|
|
1141
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1142
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: BarHorizontalChartBuilder, decorators: [{
|
|
1142
1143
|
type: Injectable,
|
|
1143
1144
|
args: [{
|
|
1144
1145
|
providedIn: 'root',
|
|
1145
1146
|
}]
|
|
1146
1147
|
}], ctorParameters: () => [{ type: PcacAxisBuilder }, { type: PcacGridBuilder }, { type: PcacTransitionService }, { type: PcacTooltipBuilder }, { type: PcacColorService }] });
|
|
1147
1148
|
|
|
1148
|
-
class
|
|
1149
|
+
class PcacBarHorizontalChartComponent {
|
|
1149
1150
|
constructor(chartBuilder) {
|
|
1150
1151
|
this.chartBuilder = chartBuilder;
|
|
1151
1152
|
this.barClicked = new EventEmitter();
|
|
@@ -1171,12 +1172,12 @@ class PcacBarChartHorizontalComponent {
|
|
|
1171
1172
|
self.buildChart();
|
|
1172
1173
|
}, 300);
|
|
1173
1174
|
}
|
|
1174
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1175
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
1175
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacBarHorizontalChartComponent, deps: [{ token: BarHorizontalChartBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1176
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.2", type: PcacBarHorizontalChartComponent, isStandalone: true, selector: "pcac-bar-horizontal-chart", inputs: { config: "config" }, outputs: { barClicked: "barClicked" }, host: { listeners: { "window:resize": "onResize()" } }, viewQueries: [{ propertyName: "chartElm", first: true, predicate: ["chart"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<section class=\"pcac-bar-horizontal-chart\">\n <svg #chart></svg>\n</section>\n", styles: [".pcac-bar-horizontal-chart{display:block}.pcac-bar-horizontal-chart svg{width:100%;display:block}.pcac-d3-tooltip{position:absolute;text-align:center;font-size:14px;padding:.5rem;pointer-events:none;display:none;background-color:#000000bf;color:#fff;border-radius:5px}\n"], encapsulation: i0.ViewEncapsulation.None }); }
|
|
1176
1177
|
}
|
|
1177
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1178
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacBarHorizontalChartComponent, decorators: [{
|
|
1178
1179
|
type: Component,
|
|
1179
|
-
args: [{ selector: 'pcac-bar-horizontal-chart', encapsulation: ViewEncapsulation.None, template: "<section class=\"pcac-bar-horizontal-chart\">\n <svg #chart></svg>\n</section>\n", styles: [".pcac-bar-horizontal-chart{display:block}.pcac-bar-horizontal-chart svg{width:100%;display:block}.pcac-d3-tooltip{position:absolute;text-align:center;font-size:14px;padding:.5rem;pointer-events:none;display:none;background-color:#000000bf;color:#fff;border-radius:5px}\n"] }]
|
|
1180
|
+
args: [{ selector: 'pcac-bar-horizontal-chart', encapsulation: ViewEncapsulation.None, standalone: true, template: "<section class=\"pcac-bar-horizontal-chart\">\n <svg #chart></svg>\n</section>\n", styles: [".pcac-bar-horizontal-chart{display:block}.pcac-bar-horizontal-chart svg{width:100%;display:block}.pcac-d3-tooltip{position:absolute;text-align:center;font-size:14px;padding:.5rem;pointer-events:none;display:none;background-color:#000000bf;color:#fff;border-radius:5px}\n"] }]
|
|
1180
1181
|
}], ctorParameters: () => [{ type: BarHorizontalChartBuilder }], propDecorators: { config: [{
|
|
1181
1182
|
type: Input
|
|
1182
1183
|
}], chartElm: [{
|
|
@@ -1189,22 +1190,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
|
|
|
1189
1190
|
args: ['window:resize']
|
|
1190
1191
|
}] } });
|
|
1191
1192
|
|
|
1192
|
-
class
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1193
|
+
class PcacBarHorizontalChartConfig extends PcacChartConfig {
|
|
1194
|
+
constructor() {
|
|
1195
|
+
super(...arguments);
|
|
1196
|
+
this.domainMax = 100;
|
|
1197
|
+
this.numberOfTicks = 5;
|
|
1198
|
+
this.isStacked = false;
|
|
1199
|
+
this.thresholds = [];
|
|
1200
|
+
this.tickFormat = PcacFormatEnum.None;
|
|
1201
|
+
this.hideGrid = false;
|
|
1202
|
+
this.hideAxis = false;
|
|
1203
|
+
this.spreadColorsPerGroup = false;
|
|
1204
|
+
this.colorOverride = new PcacBarHorizontalChartColorOverrideConfig();
|
|
1205
|
+
}
|
|
1206
|
+
}
|
|
1207
|
+
class PcacBarHorizontalChartColorOverrideConfig {
|
|
1208
|
+
constructor() {
|
|
1209
|
+
this.colors = [];
|
|
1210
|
+
}
|
|
1196
1211
|
}
|
|
1197
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: PcacBarHorizontalChartModule, decorators: [{
|
|
1198
|
-
type: NgModule,
|
|
1199
|
-
args: [{
|
|
1200
|
-
exports: [
|
|
1201
|
-
PcacBarChartHorizontalComponent
|
|
1202
|
-
],
|
|
1203
|
-
declarations: [
|
|
1204
|
-
PcacBarChartHorizontalComponent
|
|
1205
|
-
]
|
|
1206
|
-
}]
|
|
1207
|
-
}] });
|
|
1208
1212
|
|
|
1209
1213
|
class BarVerticalChartBuilder extends PcacChart {
|
|
1210
1214
|
constructor(axisBuilder, gridBuilder, transitionService, tooltipBuilder, colorService) {
|
|
@@ -1466,10 +1470,10 @@ class BarVerticalChartBuilder extends PcacChart {
|
|
|
1466
1470
|
return '3px';
|
|
1467
1471
|
});
|
|
1468
1472
|
}
|
|
1469
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1470
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1473
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: BarVerticalChartBuilder, deps: [{ token: PcacAxisBuilder }, { token: PcacGridBuilder }, { token: PcacTransitionService }, { token: PcacTooltipBuilder }, { token: PcacColorService }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1474
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: BarVerticalChartBuilder, providedIn: 'root' }); }
|
|
1471
1475
|
}
|
|
1472
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1476
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: BarVerticalChartBuilder, decorators: [{
|
|
1473
1477
|
type: Injectable,
|
|
1474
1478
|
args: [{
|
|
1475
1479
|
providedIn: 'root',
|
|
@@ -1502,12 +1506,12 @@ class PcacBarVerticalChartComponent {
|
|
|
1502
1506
|
self.buildChart();
|
|
1503
1507
|
}, 300);
|
|
1504
1508
|
}
|
|
1505
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1506
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
1509
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacBarVerticalChartComponent, deps: [{ token: BarVerticalChartBuilder }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1510
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.1.2", type: PcacBarVerticalChartComponent, isStandalone: true, selector: "pcac-bar-vertical-chart", inputs: { config: "config" }, outputs: { barClicked: "barClicked" }, host: { listeners: { "window:resize": "onResize()" } }, viewQueries: [{ propertyName: "chartElm", first: true, predicate: ["chart"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<section class=\"pcac-bar-vertical-chart\">\n <svg #chart></svg>\n</section>\n", styles: [".pcac-bar-vertical-chart svg{width:100%;display:block}\n"], encapsulation: i0.ViewEncapsulation.None }); }
|
|
1507
1511
|
}
|
|
1508
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1512
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.1.2", ngImport: i0, type: PcacBarVerticalChartComponent, decorators: [{
|
|
1509
1513
|
type: Component,
|
|
1510
|
-
args: [{ selector: 'pcac-bar-vertical-chart', encapsulation: ViewEncapsulation.None, template: "<section class=\"pcac-bar-vertical-chart\">\n <svg #chart></svg>\n</section>\n", styles: [".pcac-bar-vertical-chart svg{width:100%;display:block}\n"] }]
|
|
1514
|
+
args: [{ selector: 'pcac-bar-vertical-chart', encapsulation: ViewEncapsulation.None, standalone: true, template: "<section class=\"pcac-bar-vertical-chart\">\n <svg #chart></svg>\n</section>\n", styles: [".pcac-bar-vertical-chart svg{width:100%;display:block}\n"] }]
|
|
1511
1515
|
}], ctorParameters: () => [{ type: BarVerticalChartBuilder }], propDecorators: { config: [{
|
|
1512
1516
|
type: Input
|
|
1513
1517
|
}], chartElm: [{
|
|
@@ -1520,22 +1524,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
|
|
|
1520
1524
|
args: ['window:resize']
|
|
1521
1525
|
}] } });
|
|
1522
1526
|
|
|
1523
|
-
class
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
+
class PcacBarVerticalChartConfig extends PcacChartConfig {
|
|
1528
|
+
constructor() {
|
|
1529
|
+
super(...arguments);
|
|
1530
|
+
this.domainMax = 100;
|
|
1531
|
+
this.numberOfTicks = 5;
|
|
1532
|
+
this.isStacked = false;
|
|
1533
|
+
this.thresholds = [];
|
|
1534
|
+
this.tickFormat = PcacFormatEnum.None;
|
|
1535
|
+
this.hideGrid = false;
|
|
1536
|
+
this.hideAxis = false;
|
|
1537
|
+
this.spreadColorsPerGroup = false;
|
|
1538
|
+
this.colorOverride = new PcacBarVerticalChartColorOverrideConfig();
|
|
1539
|
+
}
|
|
1540
|
+
}
|
|
1541
|
+
class PcacBarVerticalChartColorOverrideConfig {
|
|
1542
|
+
constructor() {
|
|
1543
|
+
this.colors = [];
|
|
1544
|
+
}
|
|
1527
1545
|
}
|
|
1528
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImport: i0, type: PcacBarVerticalChartModule, decorators: [{
|
|
1529
|
-
type: NgModule,
|
|
1530
|
-
args: [{
|
|
1531
|
-
exports: [
|
|
1532
|
-
PcacBarVerticalChartComponent
|
|
1533
|
-
],
|
|
1534
|
-
declarations: [
|
|
1535
|
-
PcacBarVerticalChartComponent
|
|
1536
|
-
]
|
|
1537
|
-
}]
|
|
1538
|
-
}] });
|
|
1539
1546
|
|
|
1540
1547
|
/*
|
|
1541
1548
|
* Public API Surface of pioneer-charts
|
|
@@ -1545,5 +1552,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.2", ngImpor
|
|
|
1545
1552
|
* Generated bundle index. Do not edit.
|
|
1546
1553
|
*/
|
|
1547
1554
|
|
|
1548
|
-
export { BarHorizontalChartBuilder, BarVerticalChartBuilder, LineAreaChartBuilder, PcacAxisBuilder,
|
|
1555
|
+
export { BarHorizontalChartBuilder, BarVerticalChartBuilder, LineAreaChartBuilder, PcacAxisBuilder, PcacBarHorizontalChartColorOverrideConfig, PcacBarHorizontalChartComponent, PcacBarHorizontalChartConfig, PcacBarVerticalChartColorOverrideConfig, PcacBarVerticalChartComponent, PcacBarVerticalChartConfig, PcacChart, PcacChartConfig, PcacColorService, PcacData, PcacFormatEnum, PcacGridBuilder, PcacLineAreaChartComponent, PcacLineAreaChartConfig, PcacPieChartComponent, PcacPieChartConfig, PcacTooltipBuilder, PcacTransitionService, PieChartBuilder };
|
|
1549
1556
|
//# sourceMappingURL=pioneer-code-pioneer-charts.mjs.map
|