@agorapulse/ui-charts 20.1.17 → 20.1.19
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.
|
Binary file
|
|
@@ -1,101 +1,9 @@
|
|
|
1
|
-
import * as Highcharts from 'highcharts';
|
|
2
|
-
import { numberFormat, setOptions, dateFormat, Chart } from 'highcharts';
|
|
3
1
|
import * as i0 from '@angular/core';
|
|
4
2
|
import { inject, DestroyRef, ElementRef, input, signal, afterNextRender, effect, Directive, ChangeDetectionStrategy, Component, output } from '@angular/core';
|
|
3
|
+
import { setOptions, Chart, numberFormat } from 'highcharts';
|
|
5
4
|
import { isPlainObject, cloneDeep, round } from 'es-toolkit';
|
|
6
5
|
import { mapChart } from 'highcharts/highmaps';
|
|
7
6
|
|
|
8
|
-
function borderRadiusPlugin(H) {
|
|
9
|
-
const runtime = H;
|
|
10
|
-
if (runtime.borderRadiusPlugininitialized)
|
|
11
|
-
return;
|
|
12
|
-
runtime.borderRadiusPlugininitialized = true;
|
|
13
|
-
H.wrap(runtime.seriesTypes.column.prototype, 'translate', function (proceed) {
|
|
14
|
-
const { topMargin = 0, bottomMargin = 0, borderRadiusTopLeft, borderRadiusTopRight, borderRadiusBottomLeft, borderRadiusBottomRight, } = this.options;
|
|
15
|
-
proceed.call(this);
|
|
16
|
-
if (!this.points)
|
|
17
|
-
return;
|
|
18
|
-
if (!borderRadiusTopLeft && !borderRadiusTopRight && !borderRadiusBottomLeft && !borderRadiusBottomRight)
|
|
19
|
-
return;
|
|
20
|
-
this.points.forEach(point => roundPoint(point, H, {
|
|
21
|
-
topMargin,
|
|
22
|
-
bottomMargin,
|
|
23
|
-
topLeft: borderRadiusTopLeft,
|
|
24
|
-
topRight: borderRadiusTopRight,
|
|
25
|
-
bottomLeft: borderRadiusBottomLeft,
|
|
26
|
-
bottomRight: borderRadiusBottomRight,
|
|
27
|
-
}));
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
function pickRadius(value, index) {
|
|
31
|
-
if (Array.isArray(value))
|
|
32
|
-
return value[index] ?? 0;
|
|
33
|
-
return value ?? 0;
|
|
34
|
-
}
|
|
35
|
-
function roundPoint(point, H, config) {
|
|
36
|
-
const { width: w, height: h, x, y } = point.shapeArgs;
|
|
37
|
-
const maxR = Math.min(w, h) / 2;
|
|
38
|
-
const clamp = (radius) => (radius > maxR ? maxR : radius);
|
|
39
|
-
const radiusTopLeft = clamp(H.relativeLength(pickRadius(config.topLeft, point.index), w));
|
|
40
|
-
const radiusTopRight = clamp(H.relativeLength(pickRadius(config.topRight, point.index), w));
|
|
41
|
-
const radiusBottomRight = clamp(H.relativeLength(pickRadius(config.bottomRight, point.index), w));
|
|
42
|
-
const radiusBottomLeft = clamp(H.relativeLength(pickRadius(config.bottomLeft, point.index), w));
|
|
43
|
-
point.dlBox = point.shapeArgs;
|
|
44
|
-
point.shapeType = 'path';
|
|
45
|
-
point.shapeArgs = {
|
|
46
|
-
width: w,
|
|
47
|
-
height: h,
|
|
48
|
-
x,
|
|
49
|
-
y,
|
|
50
|
-
d: [
|
|
51
|
-
'M',
|
|
52
|
-
x + radiusTopLeft,
|
|
53
|
-
y + config.topMargin,
|
|
54
|
-
'L',
|
|
55
|
-
x + w - radiusTopRight,
|
|
56
|
-
y + config.topMargin,
|
|
57
|
-
'C',
|
|
58
|
-
x + w - radiusTopRight / 2,
|
|
59
|
-
y,
|
|
60
|
-
x + w,
|
|
61
|
-
y + radiusTopRight / 2,
|
|
62
|
-
x + w,
|
|
63
|
-
y + radiusTopRight,
|
|
64
|
-
'L',
|
|
65
|
-
x + w,
|
|
66
|
-
y + h - radiusBottomRight,
|
|
67
|
-
'C',
|
|
68
|
-
x + w,
|
|
69
|
-
y + h - radiusBottomRight / 2,
|
|
70
|
-
x + w - radiusBottomRight / 2,
|
|
71
|
-
y + h,
|
|
72
|
-
x + w - radiusBottomRight,
|
|
73
|
-
y + h + config.bottomMargin,
|
|
74
|
-
'L',
|
|
75
|
-
x + radiusBottomLeft,
|
|
76
|
-
y + h + config.bottomMargin,
|
|
77
|
-
'C',
|
|
78
|
-
x + radiusBottomLeft / 2,
|
|
79
|
-
y + h,
|
|
80
|
-
x,
|
|
81
|
-
y + h - radiusBottomLeft / 2,
|
|
82
|
-
x,
|
|
83
|
-
y + h - radiusBottomLeft,
|
|
84
|
-
'L',
|
|
85
|
-
x,
|
|
86
|
-
y + radiusTopLeft,
|
|
87
|
-
'C',
|
|
88
|
-
x,
|
|
89
|
-
y + radiusTopLeft / 2,
|
|
90
|
-
x + radiusTopLeft / 2,
|
|
91
|
-
y,
|
|
92
|
-
x + radiusTopLeft,
|
|
93
|
-
y,
|
|
94
|
-
'Z',
|
|
95
|
-
],
|
|
96
|
-
};
|
|
97
|
-
}
|
|
98
|
-
|
|
99
7
|
var ChartColor;
|
|
100
8
|
(function (ChartColor) {
|
|
101
9
|
ChartColor[ChartColor["Grey"] = 0] = "Grey";
|
|
@@ -163,8 +71,48 @@ class ChartColors {
|
|
|
163
71
|
};
|
|
164
72
|
static RED_COLORS = {
|
|
165
73
|
'80': '#F17171',
|
|
166
|
-
'
|
|
74
|
+
'100': '#E81313',
|
|
75
|
+
'150': '#D80505',
|
|
167
76
|
};
|
|
77
|
+
/**
|
|
78
|
+
* Categorical data palette — 10 distinct hues used to tell apart networks, profiles, or metrics in the same chart.
|
|
79
|
+
* Order is fixed and assigned by position (1st category → DATA_COLORS[0]).
|
|
80
|
+
* For more than 10 categories the palette wraps; the legend is the source of truth.
|
|
81
|
+
*/
|
|
82
|
+
static DATA_COLORS = [
|
|
83
|
+
'#12AABA', // data-cyan-100
|
|
84
|
+
'#D98800', // data-sun-100
|
|
85
|
+
'#CC2878', // data-peony-100
|
|
86
|
+
'#42B85A', // data-lime-100
|
|
87
|
+
'#8A62CC', // data-iris-10
|
|
88
|
+
'#CC5040', // data-cherry-100
|
|
89
|
+
'#3A92E8', // data-sky-100
|
|
90
|
+
'#DC6A30', // data-tangerine-100
|
|
91
|
+
'#12A87A', // data-emerald-100
|
|
92
|
+
'#4A6ACC', // data-navy-100
|
|
93
|
+
];
|
|
94
|
+
/**
|
|
95
|
+
* Sentiment palette — fixed mapping from sentiment to brand colors.
|
|
96
|
+
* Used by sentiment widgets only; not part of the categorical data palette.
|
|
97
|
+
*/
|
|
98
|
+
static SENTIMENT_COLORS = {
|
|
99
|
+
positive: '#45B854', // green-100
|
|
100
|
+
neutral: '#858FA1', // grey-60
|
|
101
|
+
negative: '#E81313', // red-100
|
|
102
|
+
};
|
|
103
|
+
/**
|
|
104
|
+
* Heatmap / world-map palette — single shade (data-navy / data-marine) at 5 fixed opacity levels.
|
|
105
|
+
* Listed in ascending intensity (20% → 100%).
|
|
106
|
+
*/
|
|
107
|
+
static HEATMAP_BASE_RGB = [74, 106, 204];
|
|
108
|
+
static HEATMAP_OPACITIES = [0.2, 0.4, 0.6, 0.8, 1];
|
|
109
|
+
static HEATMAP_COLORS = [
|
|
110
|
+
'rgba(74, 106, 204, 0.2)',
|
|
111
|
+
'rgba(74, 106, 204, 0.4)',
|
|
112
|
+
'rgba(74, 106, 204, 0.6)',
|
|
113
|
+
'rgba(74, 106, 204, 0.8)',
|
|
114
|
+
'rgba(74, 106, 204, 1)',
|
|
115
|
+
];
|
|
168
116
|
static SOFT_RED_COLORS = {
|
|
169
117
|
100: '#ff5353',
|
|
170
118
|
85: '#ff6d6d',
|
|
@@ -190,6 +138,21 @@ class ChartColors {
|
|
|
190
138
|
return this.GREY_COLORS;
|
|
191
139
|
}
|
|
192
140
|
}
|
|
141
|
+
/**
|
|
142
|
+
* Returns the categorical data color at the given 0-based position.
|
|
143
|
+
* Wraps modulo `DATA_COLORS.length` (10) so position 10 reuses position 0.
|
|
144
|
+
*/
|
|
145
|
+
static getDataColor(position) {
|
|
146
|
+
const palette = ChartColors.DATA_COLORS;
|
|
147
|
+
return palette[((position % palette.length) + palette.length) % palette.length];
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Returns the first `count` data colors from the categorical palette.
|
|
151
|
+
* Wraps after 10 positions.
|
|
152
|
+
*/
|
|
153
|
+
static getDataColors(count) {
|
|
154
|
+
return Array.from({ length: Math.max(count, 0) }, (_, index) => ChartColors.getDataColor(index));
|
|
155
|
+
}
|
|
193
156
|
static getColors(seriesCount, color) {
|
|
194
157
|
const colors = this.getChartColors(color);
|
|
195
158
|
switch (seriesCount) {
|
|
@@ -211,7 +174,7 @@ class ChartColors {
|
|
|
211
174
|
|
|
212
175
|
class AbstractChartComponent {
|
|
213
176
|
destroyRef = inject(DestroyRef);
|
|
214
|
-
/** Highcharts renders into the
|
|
177
|
+
/** Highcharts renders into the host element directly. */
|
|
215
178
|
hostElement = inject(ElementRef).nativeElement;
|
|
216
179
|
chartOptions = input({}, ...(ngDevMode ? [{ debugName: "chartOptions" }] : []));
|
|
217
180
|
color = input(ChartColor.ElectricBlue, ...(ngDevMode ? [{ debugName: "color" }] : []));
|
|
@@ -226,8 +189,7 @@ class AbstractChartComponent {
|
|
|
226
189
|
this.resizeObserver.observe(this.hostElement);
|
|
227
190
|
this.viewReady.set(true);
|
|
228
191
|
});
|
|
229
|
-
// Eager init
|
|
230
|
-
// default width and the ResizeObserver below reflows when the container later grows.
|
|
192
|
+
// Eager init on view-ready; ResizeObserver reflows as the container grows.
|
|
231
193
|
effect(() => {
|
|
232
194
|
if (!this.viewReady())
|
|
233
195
|
return;
|
|
@@ -258,48 +220,19 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImpo
|
|
|
258
220
|
type: Directive
|
|
259
221
|
}], ctorParameters: () => [], propDecorators: { chartOptions: [{ type: i0.Input, args: [{ isSignal: true, alias: "chartOptions", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], labelDateFormat: [{ type: i0.Input, args: [{ isSignal: true, alias: "labelDateFormat", required: false }] }], locale: [{ type: i0.Input, args: [{ isSignal: true, alias: "locale", required: false }] }] } });
|
|
260
222
|
|
|
261
|
-
/**
|
|
262
|
-
* Builds Highcharts locale options (lang + tooltip date formats) from a locale string.
|
|
263
|
-
* Uses the browser's Intl API to generate translated month/weekday names and number formatting rules.
|
|
264
|
-
*/
|
|
223
|
+
/** `lang.locale` drives Intl-based weekday/month/number formatting; we only override the tooltip date order. */
|
|
265
224
|
function buildHighchartsLocaleOptions(locale) {
|
|
266
|
-
const
|
|
225
|
+
const dayFormat = locale === 'en' ? '%A, %b %e, %Y' : '%A %e %b %Y';
|
|
267
226
|
return {
|
|
268
|
-
lang: {
|
|
269
|
-
decimalPoint,
|
|
270
|
-
thousandsSep,
|
|
271
|
-
weekdays: buildWeekdays(locale),
|
|
272
|
-
shortMonths: buildShortMonths(locale),
|
|
273
|
-
},
|
|
227
|
+
lang: { locale },
|
|
274
228
|
tooltip: {
|
|
275
229
|
dateTimeLabelFormats: {
|
|
276
|
-
day:
|
|
277
|
-
week:
|
|
230
|
+
day: dayFormat,
|
|
231
|
+
week: dayFormat,
|
|
278
232
|
},
|
|
279
233
|
},
|
|
280
234
|
};
|
|
281
235
|
}
|
|
282
|
-
function buildNumberSeparators(locale) {
|
|
283
|
-
const parts = new Intl.NumberFormat(locale).formatToParts(12345.6);
|
|
284
|
-
const decimalPoint = parts.find(p => p.type === 'decimal')?.value ?? '.';
|
|
285
|
-
const thousandsSep = parts.find(p => p.type === 'group')?.value ?? ',';
|
|
286
|
-
return { decimalPoint, thousandsSep };
|
|
287
|
-
}
|
|
288
|
-
function buildWeekdays(locale) {
|
|
289
|
-
const formatter = new Intl.DateTimeFormat(locale, { weekday: 'long' });
|
|
290
|
-
// Jan 4, 1970 is a Sunday
|
|
291
|
-
return Array.from({ length: 7 }, (_, i) => {
|
|
292
|
-
const name = formatter.format(new Date(1970, 0, 4 + i));
|
|
293
|
-
return name.charAt(0).toUpperCase() + name.slice(1);
|
|
294
|
-
});
|
|
295
|
-
}
|
|
296
|
-
function buildShortMonths(locale) {
|
|
297
|
-
const formatter = new Intl.DateTimeFormat(locale, { month: 'short' });
|
|
298
|
-
return Array.from({ length: 12 }, (_, i) => {
|
|
299
|
-
const name = formatter.format(new Date(2000, i, 1));
|
|
300
|
-
return name.charAt(0).toUpperCase() + name.slice(1);
|
|
301
|
-
});
|
|
302
|
-
}
|
|
303
236
|
|
|
304
237
|
const FONT_FAMILY = "Averta, 'Open Sans', Helvetica, sans-serif";
|
|
305
238
|
const LABEL_FONT_SIZE = '12px';
|
|
@@ -396,9 +329,7 @@ class ChartOptions {
|
|
|
396
329
|
gridLineWidth: 1,
|
|
397
330
|
title: { text: undefined },
|
|
398
331
|
labels: {
|
|
399
|
-
|
|
400
|
-
return typeof this.value === 'string' ? this.value : numberFormat(this.value, -1);
|
|
401
|
-
},
|
|
332
|
+
// Highcharts auto-formats per `lang.locale`.
|
|
402
333
|
style: {
|
|
403
334
|
color: ChartColors.GREY_COLORS[85],
|
|
404
335
|
fontSize: LABEL_FONT_SIZE,
|
|
@@ -412,15 +343,7 @@ class ChartOptions {
|
|
|
412
343
|
return mergeDeep(mergeDeep(ChartOptions.DEFAULT_OPTIONS, localeOptions), options);
|
|
413
344
|
}
|
|
414
345
|
static configure(series, options, color, labelDateFormat) {
|
|
415
|
-
options.xAxis = mergeDeep({
|
|
416
|
-
labels: {
|
|
417
|
-
formatter() {
|
|
418
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
419
|
-
// @ts-ignore highcharts callback context types `value` as string | number
|
|
420
|
-
return dateFormat(labelDateFormat ?? '%m/%d', this.value);
|
|
421
|
-
},
|
|
422
|
-
},
|
|
423
|
-
}, options.xAxis);
|
|
346
|
+
options.xAxis = mergeDeep({ labels: { format: `{value:${labelDateFormat ?? '%m/%d'}}` } }, options.xAxis);
|
|
424
347
|
if (series?.length) {
|
|
425
348
|
options.series = series;
|
|
426
349
|
if (options.legend) {
|
|
@@ -429,84 +352,8 @@ class ChartOptions {
|
|
|
429
352
|
options.colors = ChartColors.getColors(series.length, color);
|
|
430
353
|
}
|
|
431
354
|
}
|
|
432
|
-
static redrawWithHighestEdgesRounded(chart) {
|
|
433
|
-
chart.series.forEach((serie, index, all) => {
|
|
434
|
-
ChartOptions.roundHighestSerie(all, serie.options, index);
|
|
435
|
-
});
|
|
436
|
-
chart.redraw(true);
|
|
437
|
-
}
|
|
438
|
-
static roundHighestSerie(series, serie, serieIndex) {
|
|
439
|
-
if (!serie.data)
|
|
440
|
-
return;
|
|
441
|
-
const roundedTopMap = [];
|
|
442
|
-
const roundedBottomMap = [];
|
|
443
|
-
serie.data.forEach((point, columnIndex) => {
|
|
444
|
-
const pointValue = getPointValue(point);
|
|
445
|
-
const pointX = getPointX(point);
|
|
446
|
-
const isNegative = pointValue !== null && pointValue < 0;
|
|
447
|
-
if (isNegative) {
|
|
448
|
-
// Negative bars go downward: the visual tip is the physical bottom.
|
|
449
|
-
// Round bottom corners only on the bottommost segment of the negative stack.
|
|
450
|
-
const isBottommost = series.slice(serieIndex + 1).every(other => {
|
|
451
|
-
if (!other.visible)
|
|
452
|
-
return true;
|
|
453
|
-
const otherPoint = findPointAtAbscissa(other.options.data, pointX, columnIndex);
|
|
454
|
-
if (otherPoint === undefined)
|
|
455
|
-
return true;
|
|
456
|
-
const val = getPointValue(otherPoint);
|
|
457
|
-
return val === null || val >= 0;
|
|
458
|
-
});
|
|
459
|
-
roundedTopMap[columnIndex] = 0;
|
|
460
|
-
roundedBottomMap[columnIndex] = isBottommost ? 100 : 0;
|
|
461
|
-
}
|
|
462
|
-
else {
|
|
463
|
-
// Positive bars go upward: the visual tip is the physical top.
|
|
464
|
-
// Round top corners only on the topmost segment of the positive stack.
|
|
465
|
-
const isTopmost = series.slice(0, serieIndex).every(other => {
|
|
466
|
-
if (!other.visible)
|
|
467
|
-
return true;
|
|
468
|
-
const otherPoint = findPointAtAbscissa(other.options.data, pointX, columnIndex);
|
|
469
|
-
return otherPoint === undefined || getPointValue(otherPoint) === 0;
|
|
470
|
-
});
|
|
471
|
-
roundedTopMap[columnIndex] = isTopmost ? 100 : 0;
|
|
472
|
-
roundedBottomMap[columnIndex] = 0;
|
|
473
|
-
}
|
|
474
|
-
});
|
|
475
|
-
serie.borderRadiusTopLeft = roundedTopMap;
|
|
476
|
-
serie.borderRadiusTopRight = roundedTopMap;
|
|
477
|
-
serie.borderRadiusBottomLeft = roundedBottomMap;
|
|
478
|
-
serie.borderRadiusBottomRight = roundedBottomMap;
|
|
479
|
-
}
|
|
480
355
|
}
|
|
481
|
-
|
|
482
|
-
if (Array.isArray(point))
|
|
483
|
-
return point[0];
|
|
484
|
-
if (point && typeof point === 'object')
|
|
485
|
-
return point.x ?? null;
|
|
486
|
-
return null;
|
|
487
|
-
}
|
|
488
|
-
function getPointValue(point) {
|
|
489
|
-
if (typeof point === 'number')
|
|
490
|
-
return point;
|
|
491
|
-
if (Array.isArray(point))
|
|
492
|
-
return point[1];
|
|
493
|
-
if (point && typeof point === 'object')
|
|
494
|
-
return point.y ?? null;
|
|
495
|
-
return null;
|
|
496
|
-
}
|
|
497
|
-
function findPointAtAbscissa(data, x, fallbackIndex) {
|
|
498
|
-
if (!data)
|
|
499
|
-
return undefined;
|
|
500
|
-
if (x !== null) {
|
|
501
|
-
return data.find(p => getPointX(p) === x);
|
|
502
|
-
}
|
|
503
|
-
return data[fallbackIndex];
|
|
504
|
-
}
|
|
505
|
-
/**
|
|
506
|
-
* Deep-merges `source` onto a clone of `target` without mutating either, with one deliberate
|
|
507
|
-
* deviation from `es-toolkit`'s `toMerged`: arrays are treated as opaque values (replaced wholesale)
|
|
508
|
-
* rather than element-merged, which matches how Highcharts options are intended to be overridden.
|
|
509
|
-
*/
|
|
356
|
+
/** Deep-merge clone (immutable). Arrays are replaced wholesale, not element-merged like `es-toolkit`'s `toMerged`. */
|
|
510
357
|
function mergeDeep(target, source) {
|
|
511
358
|
if (!isPlainObject(target) || !isPlainObject(source)) {
|
|
512
359
|
return target;
|
|
@@ -529,19 +376,13 @@ class ChartBarOptions extends ChartOptions {
|
|
|
529
376
|
const bar = {
|
|
530
377
|
maxPointWidth: 20,
|
|
531
378
|
};
|
|
532
|
-
if (stacked
|
|
379
|
+
if (stacked || opposite) {
|
|
380
|
+
// `opposite` = diverging left/right bars (one series flipped to negative).
|
|
533
381
|
bar.stacking = 'normal';
|
|
534
|
-
bar.
|
|
535
|
-
hide() {
|
|
536
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
537
|
-
},
|
|
538
|
-
show() {
|
|
539
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
540
|
-
},
|
|
541
|
-
};
|
|
382
|
+
bar.borderRadius = { radius: '50%', scope: 'stack', where: 'end' };
|
|
542
383
|
}
|
|
543
384
|
else {
|
|
544
|
-
bar.borderRadius =
|
|
385
|
+
bar.borderRadius = '50%';
|
|
545
386
|
}
|
|
546
387
|
const defaultBarOptions = {
|
|
547
388
|
chart: {
|
|
@@ -578,37 +419,28 @@ class ChartBarOptions extends ChartOptions {
|
|
|
578
419
|
bar,
|
|
579
420
|
series: {
|
|
580
421
|
borderWidth: 0,
|
|
581
|
-
}
|
|
422
|
+
},
|
|
582
423
|
},
|
|
583
424
|
};
|
|
584
425
|
return super.build(mergeDeep(defaultBarOptions, options), locale);
|
|
585
426
|
}
|
|
586
427
|
static configureBar(series, categories, options, opposite, color, labelDateFormat) {
|
|
587
428
|
ChartOptions.configure(series, options, color, labelDateFormat);
|
|
588
|
-
if (categories
|
|
429
|
+
if (categories?.length) {
|
|
589
430
|
options.xAxis.categories = categories;
|
|
590
431
|
}
|
|
591
432
|
if (opposite && series.length === 2) {
|
|
592
433
|
const negativeSerie = series[0];
|
|
593
|
-
|
|
594
|
-
negativeSerie.borderRadiusBottomRight = 100;
|
|
595
|
-
negativeSerie.borderRadiusTopLeft = 0;
|
|
596
|
-
negativeSerie.borderRadiusTopRight = 0;
|
|
434
|
+
// Flip the first series negative so it stacks left of zero.
|
|
597
435
|
negativeSerie.data = negativeSerie.data?.map((point) => {
|
|
598
436
|
if (point && isNaN(point)) {
|
|
599
|
-
return {
|
|
600
|
-
...point,
|
|
601
|
-
y: -Math.abs(point.y),
|
|
602
|
-
};
|
|
437
|
+
return { ...point, y: -Math.abs(point.y) };
|
|
603
438
|
}
|
|
604
|
-
|
|
439
|
+
if (!isNaN(point)) {
|
|
605
440
|
return -Math.abs(point);
|
|
606
441
|
}
|
|
607
442
|
return point;
|
|
608
443
|
});
|
|
609
|
-
if (options.plotOptions?.series) {
|
|
610
|
-
options.plotOptions.series.stacking = 'normal';
|
|
611
|
-
}
|
|
612
444
|
const yAxisLabels = options.yAxis.labels;
|
|
613
445
|
if (yAxisLabels) {
|
|
614
446
|
yAxisLabels.formatter = function () {
|
|
@@ -617,7 +449,7 @@ class ChartBarOptions extends ChartOptions {
|
|
|
617
449
|
}
|
|
618
450
|
if (options.tooltip) {
|
|
619
451
|
options.tooltip.pointFormatter = function () {
|
|
620
|
-
return `<div style="font-size: 14px; color: #344563; margin: 6px 8px 0 8px;"><span style="color:${this.color};"
|
|
452
|
+
return `<div style="font-size: 14px; color: #344563; margin: 6px 8px 0 8px;"><span style="color:${this.color};">●</span> ${this.series.name}: <b>${Math.abs(this.y ?? 0) + '%'}</b></div>`;
|
|
621
453
|
};
|
|
622
454
|
}
|
|
623
455
|
}
|
|
@@ -633,9 +465,6 @@ class ChartBarComponent extends AbstractChartComponent {
|
|
|
633
465
|
const options = ChartBarOptions.buildBars(this.chartOptions(), this.stacked(), this.opposite(), this.locale());
|
|
634
466
|
ChartBarOptions.configureBar(this.series(), this.categories(), options, this.opposite(), this.color(), this.labelDateFormat());
|
|
635
467
|
this.chart = new Chart(this.hostElement, options);
|
|
636
|
-
if (this.stacked() && !this.opposite()) {
|
|
637
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
638
|
-
}
|
|
639
468
|
}
|
|
640
469
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: ChartBarComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
641
470
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.18", type: ChartBarComponent, isStandalone: true, selector: "ap-chart-bar", inputs: { categories: { classPropertyName: "categories", publicName: "categories", isSignal: true, isRequired: false, transformFunction: null }, opposite: { classPropertyName: "opposite", publicName: "opposite", isSignal: true, isRequired: false, transformFunction: null }, stacked: { classPropertyName: "stacked", publicName: "stacked", isSignal: true, isRequired: false, transformFunction: null }, series: { classPropertyName: "series", publicName: "series", isSignal: true, isRequired: false, transformFunction: null } }, host: { styleAttribute: "display: block" }, usesInheritance: true, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
@@ -656,20 +485,11 @@ class ChartColumnOptions extends ChartOptions {
|
|
|
656
485
|
borderWidth: 0,
|
|
657
486
|
crisp: false,
|
|
658
487
|
maxPointWidth: 20,
|
|
488
|
+
// Round only the value-side end; `scope: 'stack'` keeps middle segments square.
|
|
489
|
+
borderRadius: stacked ? { radius: '50%', scope: 'stack', where: 'end' } : '50%',
|
|
659
490
|
};
|
|
660
491
|
if (stacked) {
|
|
661
492
|
column.stacking = 'normal';
|
|
662
|
-
column.events = {
|
|
663
|
-
hide() {
|
|
664
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
665
|
-
},
|
|
666
|
-
show() {
|
|
667
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
668
|
-
},
|
|
669
|
-
};
|
|
670
|
-
}
|
|
671
|
-
else {
|
|
672
|
-
column.borderRadius = 100;
|
|
673
493
|
}
|
|
674
494
|
const defaultColumnOptions = {
|
|
675
495
|
chart: {
|
|
@@ -698,9 +518,6 @@ class ChartColumnComponent extends AbstractChartComponent {
|
|
|
698
518
|
const options = ChartColumnOptions.buildColumn(this.chartOptions(), this.stacked(), this.locale());
|
|
699
519
|
ChartColumnOptions.configure(this.series(), options, this.color(), this.labelDateFormat());
|
|
700
520
|
this.chart = new Chart(this.hostElement, options);
|
|
701
|
-
if (this.stacked()) {
|
|
702
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
703
|
-
}
|
|
704
521
|
this.chartInitialized.emit(this.chart);
|
|
705
522
|
}
|
|
706
523
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: ChartColumnComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -725,7 +542,6 @@ const HEATMAP_CONSTANTS = {
|
|
|
725
542
|
TOOLTIP_FONT_SIZE: '14px',
|
|
726
543
|
LEGEND_SYMBOL_WIDTH: 300,
|
|
727
544
|
LEGEND_SYMBOL_HEIGHT: 10,
|
|
728
|
-
TICK_INTERVAL: 3,
|
|
729
545
|
DEFAULT_TICK_AMOUNT: 6,
|
|
730
546
|
DEFAULT_MAX_VALUE: 3,
|
|
731
547
|
MIN_VALUE: 0,
|
|
@@ -779,92 +595,58 @@ class ChartHeatmapOptions extends ChartOptions {
|
|
|
779
595
|
pointFormat: `<div style="border-bottom: 1px solid ${ChartColors.GREY_COLORS[10]}; padding: 0 8px 7px">` +
|
|
780
596
|
`<span style="font-size: ${HEATMAP_CONSTANTS.HEADER_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[60]}">{point.tooltipHeaderLabel}</span></div>` +
|
|
781
597
|
`<div style="font-size: ${HEATMAP_CONSTANTS.TOOLTIP_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[100]}; margin: 6px 8px 0 8px;">` +
|
|
782
|
-
`<span style="color:{point.color}"
|
|
598
|
+
`<span style="color:{point.color}">●</span> {series.name}: <b>{point.value}{point.unit}</b></div>`,
|
|
783
599
|
},
|
|
784
600
|
xAxis: {
|
|
785
|
-
labels: {
|
|
786
|
-
formatter: this.createXAxisFormatter(),
|
|
787
|
-
},
|
|
788
601
|
lineWidth: 1,
|
|
789
602
|
tickWidth: 0,
|
|
790
603
|
visible: true,
|
|
791
604
|
},
|
|
792
605
|
yAxis: {
|
|
793
606
|
lineWidth: 0,
|
|
794
|
-
labels: {
|
|
795
|
-
step: 3,
|
|
796
|
-
},
|
|
607
|
+
labels: { step: 3 },
|
|
797
608
|
reversed: true,
|
|
798
609
|
visible: true,
|
|
799
610
|
},
|
|
800
611
|
};
|
|
801
612
|
return super.build(mergeDeep(defaultHeatmapOptions, options), locale);
|
|
802
613
|
}
|
|
803
|
-
static createColorAxisFormatter(leastLabel, mostLabel) {
|
|
804
|
-
return function () {
|
|
805
|
-
if (this.value === this.axis.min) {
|
|
806
|
-
return leastLabel;
|
|
807
|
-
}
|
|
808
|
-
if (this.value === this.axis.max) {
|
|
809
|
-
return mostLabel;
|
|
810
|
-
}
|
|
811
|
-
return '';
|
|
812
|
-
};
|
|
813
|
-
}
|
|
814
|
-
static createXAxisFormatter() {
|
|
815
|
-
return function () {
|
|
816
|
-
return this.value.toString();
|
|
817
|
-
};
|
|
818
|
-
}
|
|
819
614
|
static configureHeatmap(categoriesX, categoriesY, series, options, color, leastLabel, mostLabel, labelDateFormat) {
|
|
820
615
|
super.configure(series, options, color, labelDateFormat);
|
|
821
|
-
this.setAxisCategories(options, categoriesX, categoriesY);
|
|
822
|
-
const points = series[0].data;
|
|
823
|
-
const maxValue = points.reduce((max, point) => Math.max(max, point.value), 0) || HEATMAP_CONSTANTS.DEFAULT_MAX_VALUE;
|
|
824
|
-
this.configureColorAxis(options, color, maxValue, leastLabel, mostLabel);
|
|
825
|
-
this.configureLegend(options);
|
|
826
|
-
}
|
|
827
|
-
static setAxisCategories(options, categoriesX, categoriesY) {
|
|
828
616
|
if (categoriesX?.length) {
|
|
829
617
|
options.xAxis.categories = categoriesX;
|
|
830
618
|
}
|
|
831
619
|
if (categoriesY?.length) {
|
|
832
620
|
options.yAxis.categories = categoriesY;
|
|
833
621
|
}
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
const tickPositions = this.buildTickPositions(maxValue);
|
|
622
|
+
const data = (series[0].data ?? []);
|
|
623
|
+
const maxValue = data.reduce((max, point) => Math.max(max, point.value ?? 0), 0) || HEATMAP_CONSTANTS.DEFAULT_MAX_VALUE;
|
|
837
624
|
const labelsEnabled = !!(leastLabel && mostLabel);
|
|
625
|
+
// `tickAmount` spreads ticks evenly between min and max.
|
|
838
626
|
options.colorAxis = {
|
|
839
|
-
...(options.colorAxis
|
|
627
|
+
...(options.colorAxis ?? {}),
|
|
840
628
|
visible: labelsEnabled,
|
|
841
629
|
min: HEATMAP_CONSTANTS.MIN_VALUE,
|
|
842
|
-
max:
|
|
843
|
-
|
|
630
|
+
max: maxValue,
|
|
631
|
+
tickAmount: HEATMAP_CONSTANTS.DEFAULT_TICK_AMOUNT,
|
|
844
632
|
maxColor: ChartColors.getChartColors(color)[100],
|
|
845
633
|
};
|
|
846
634
|
if (labelsEnabled) {
|
|
847
635
|
options.colorAxis.labels = {
|
|
848
|
-
...(options.colorAxis?.labels
|
|
849
|
-
formatter:
|
|
636
|
+
...(options.colorAxis?.labels ?? {}),
|
|
637
|
+
formatter: createColorAxisFormatter(leastLabel, mostLabel),
|
|
850
638
|
};
|
|
851
639
|
}
|
|
852
640
|
}
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
// We subtract 1 from tickAmount so that the last tick is exactly at maxValue
|
|
863
|
-
const step = maxValue / (tickAmount - 1);
|
|
864
|
-
// Generate an array of positions for the ticks
|
|
865
|
-
// Each position is calculated as i * step and rounded to 2 decimal places
|
|
866
|
-
return Array.from({ length: tickAmount }, (_, i) => parseFloat((i * step).toFixed(2)));
|
|
867
|
-
}
|
|
641
|
+
}
|
|
642
|
+
function createColorAxisFormatter(leastLabel, mostLabel) {
|
|
643
|
+
return function () {
|
|
644
|
+
if (this.value === this.axis.min)
|
|
645
|
+
return leastLabel;
|
|
646
|
+
if (this.value === this.axis.max)
|
|
647
|
+
return mostLabel;
|
|
648
|
+
return '';
|
|
649
|
+
};
|
|
868
650
|
}
|
|
869
651
|
|
|
870
652
|
class ChartHeatmapComponent extends AbstractChartComponent {
|
|
@@ -907,20 +689,13 @@ class ChartMixedOptions extends ChartOptions {
|
|
|
907
689
|
radius: singleDayEnabled ? 5 : 2,
|
|
908
690
|
symbol: 'circle',
|
|
909
691
|
},
|
|
910
|
-
lineWidth: 4
|
|
692
|
+
lineWidth: 4,
|
|
911
693
|
},
|
|
912
694
|
column: {
|
|
913
695
|
stacking: 'normal',
|
|
914
696
|
borderWidth: 0,
|
|
915
697
|
maxPointWidth: 20,
|
|
916
|
-
|
|
917
|
-
hide() {
|
|
918
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
919
|
-
},
|
|
920
|
-
show() {
|
|
921
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
922
|
-
},
|
|
923
|
-
},
|
|
698
|
+
borderRadius: { radius: '50%', scope: 'stack', where: 'end' },
|
|
924
699
|
},
|
|
925
700
|
},
|
|
926
701
|
xAxis: {
|
|
@@ -940,7 +715,6 @@ class ChartMixedComponent extends AbstractChartComponent {
|
|
|
940
715
|
const options = ChartMixedOptions.buildMixed(this.chartOptions(), singleDayEnabled, this.locale());
|
|
941
716
|
ChartMixedOptions.configure(series, options, this.color(), this.labelDateFormat());
|
|
942
717
|
this.chart = new Chart(this.hostElement, options);
|
|
943
|
-
ChartOptions.redrawWithHighestEdgesRounded(this.chart);
|
|
944
718
|
}
|
|
945
719
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: ChartMixedComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
946
720
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.18", type: ChartMixedComponent, isStandalone: true, selector: "ap-chart-mixed", inputs: { series: { classPropertyName: "series", publicName: "series", isSignal: true, isRequired: false, transformFunction: null } }, host: { styleAttribute: "display: block" }, usesInheritance: true, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
@@ -956,7 +730,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImpo
|
|
|
956
730
|
}], propDecorators: { series: [{ type: i0.Input, args: [{ isSignal: true, alias: "series", required: false }] }] } });
|
|
957
731
|
|
|
958
732
|
const NAME_MAX_LENGTH = 30;
|
|
959
|
-
// Hebrew, Arabic,
|
|
733
|
+
// RTL scripts (Hebrew, Arabic, …).
|
|
960
734
|
const RIGHT_TO_LEFT_CHARACTERS = /[\p{Script=Arabic}\p{Script=Hebrew}\p{Script=Syriac}\p{Script=Thaana}\p{Script=Nko}\p{Script=Samaritan}\p{Script=Mandaic}]/u;
|
|
961
735
|
const RIGHT_TO_LEFT_EMBEDDING_CHARACTER = '';
|
|
962
736
|
class ChartPieOptions extends ChartOptions {
|
|
@@ -998,9 +772,7 @@ class ChartPieOptions extends ChartOptions {
|
|
|
998
772
|
return;
|
|
999
773
|
}
|
|
1000
774
|
options.colors = colors;
|
|
1001
|
-
//
|
|
1002
|
-
// wholesale. Otherwise we rely on Highcharts' default `states.inactive.opacity` (0.2)
|
|
1003
|
-
// to fade non-hovered slices — see https://api.highcharts.com/highcharts/plotOptions.pie.states.inactive
|
|
775
|
+
// Otherwise we rely on Highcharts' default `states.inactive.opacity` to fade non-hovered slices.
|
|
1004
776
|
if (!mouseEventEnabled) {
|
|
1005
777
|
options.plotOptions ??= {};
|
|
1006
778
|
options.plotOptions.pie ??= {};
|
|
@@ -1120,11 +892,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImpo
|
|
|
1120
892
|
}]
|
|
1121
893
|
}], propDecorators: { series: [{ type: i0.Input, args: [{ isSignal: true, alias: "series", required: false }] }], chartInitialized: [{ type: i0.Output, args: ["chartInitialized"] }] } });
|
|
1122
894
|
|
|
1123
|
-
borderRadiusPlugin(Highcharts);
|
|
1124
|
-
|
|
1125
895
|
/**
|
|
1126
896
|
* Generated bundle index. Do not edit.
|
|
1127
897
|
*/
|
|
1128
898
|
|
|
1129
|
-
export { AbstractChartComponent, ChartBarComponent, ChartColor, ChartColors, ChartColumnComponent, ChartHeatmapComponent, ChartMixedComponent, ChartOptions, ChartPieComponent, ChartSplineComponent,
|
|
899
|
+
export { AbstractChartComponent, ChartBarComponent, ChartColor, ChartColors, ChartColumnComponent, ChartHeatmapComponent, ChartMixedComponent, ChartOptions, ChartPieComponent, ChartSplineComponent, mergeDeep };
|
|
1130
900
|
//# sourceMappingURL=agorapulse-ui-charts.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agorapulse-ui-charts.mjs","sources":["../../../libs/ui-charts/src/lib/highcharts-border-radius-plugin.ts","../../../libs/ui-charts/src/lib/chart-colors.ts","../../../libs/ui-charts/src/lib/abstract-chart.component.ts","../../../libs/ui-charts/src/lib/chart-locale.ts","../../../libs/ui-charts/src/lib/chart-options.ts","../../../libs/ui-charts/src/lib/chart-bar/chart-bar-options.model.ts","../../../libs/ui-charts/src/lib/chart-bar/chart-bar.component.ts","../../../libs/ui-charts/src/lib/chart-column/chart-column-options.model.ts","../../../libs/ui-charts/src/lib/chart-column/chart-column.component.ts","../../../libs/ui-charts/src/lib/chart-heatmap/chart-heatmap-options.model.ts","../../../libs/ui-charts/src/lib/chart-heatmap/chart-heatmap.component.ts","../../../libs/ui-charts/src/lib/chart-mixed/chart-mixed-options.model.ts","../../../libs/ui-charts/src/lib/chart-mixed/chart-mixed.component.ts","../../../libs/ui-charts/src/lib/chart-pie/chart-pie-options.model.ts","../../../libs/ui-charts/src/lib/chart-pie/chart-pie.component.ts","../../../libs/ui-charts/src/lib/chart-spline/chart-spline-options.model.ts","../../../libs/ui-charts/src/lib/chart-spline/chart-spline.component.ts","../../../libs/ui-charts/index.ts","../../../libs/ui-charts/agorapulse-ui-charts.ts"],"sourcesContent":["import type Highcharts from 'highcharts';\n\ntype HighchartsRuntime = typeof Highcharts & {\n borderRadiusPlugininitialized?: boolean;\n seriesTypes: { column: { prototype: object } };\n};\n\ntype RadiusInput = number | number[] | undefined;\n\ninterface ColumnPoint {\n index: number;\n shapeArgs: { width: number; height: number; x: number; y: number; d?: unknown[] };\n dlBox: unknown;\n shapeType: string;\n}\n\ninterface ColumnSeries {\n options: {\n topMargin?: number;\n bottomMargin?: number;\n borderRadiusTopLeft?: RadiusInput;\n borderRadiusTopRight?: RadiusInput;\n borderRadiusBottomLeft?: RadiusInput;\n borderRadiusBottomRight?: RadiusInput;\n };\n points?: ColumnPoint[];\n}\n\nexport function borderRadiusPlugin(H: typeof Highcharts): void {\n const runtime = H as HighchartsRuntime;\n if (runtime.borderRadiusPlugininitialized) return;\n runtime.borderRadiusPlugininitialized = true;\n\n H.wrap(runtime.seriesTypes.column.prototype, 'translate', function (this: ColumnSeries, proceed: () => void) {\n const {\n topMargin = 0,\n bottomMargin = 0,\n borderRadiusTopLeft,\n borderRadiusTopRight,\n borderRadiusBottomLeft,\n borderRadiusBottomRight,\n } = this.options;\n\n proceed.call(this);\n\n if (!this.points) return;\n if (!borderRadiusTopLeft && !borderRadiusTopRight && !borderRadiusBottomLeft && !borderRadiusBottomRight) return;\n\n this.points.forEach(point =>\n roundPoint(point, H, {\n topMargin,\n bottomMargin,\n topLeft: borderRadiusTopLeft,\n topRight: borderRadiusTopRight,\n bottomLeft: borderRadiusBottomLeft,\n bottomRight: borderRadiusBottomRight,\n })\n );\n });\n}\n\ninterface RoundPointConfig {\n topMargin: number;\n bottomMargin: number;\n topLeft: RadiusInput;\n topRight: RadiusInput;\n bottomLeft: RadiusInput;\n bottomRight: RadiusInput;\n}\n\nfunction pickRadius(value: RadiusInput, index: number): number {\n if (Array.isArray(value)) return value[index] ?? 0;\n return value ?? 0;\n}\n\nfunction roundPoint(point: ColumnPoint, H: typeof Highcharts, config: RoundPointConfig): void {\n const { width: w, height: h, x, y } = point.shapeArgs;\n const maxR = Math.min(w, h) / 2;\n\n const clamp = (radius: number) => (radius > maxR ? maxR : radius);\n const radiusTopLeft = clamp(H.relativeLength(pickRadius(config.topLeft, point.index), w));\n const radiusTopRight = clamp(H.relativeLength(pickRadius(config.topRight, point.index), w));\n const radiusBottomRight = clamp(H.relativeLength(pickRadius(config.bottomRight, point.index), w));\n const radiusBottomLeft = clamp(H.relativeLength(pickRadius(config.bottomLeft, point.index), w));\n\n point.dlBox = point.shapeArgs;\n point.shapeType = 'path';\n point.shapeArgs = {\n width: w,\n height: h,\n x,\n y,\n d: [\n 'M',\n x + radiusTopLeft,\n y + config.topMargin,\n 'L',\n x + w - radiusTopRight,\n y + config.topMargin,\n 'C',\n x + w - radiusTopRight / 2,\n y,\n x + w,\n y + radiusTopRight / 2,\n x + w,\n y + radiusTopRight,\n 'L',\n x + w,\n y + h - radiusBottomRight,\n 'C',\n x + w,\n y + h - radiusBottomRight / 2,\n x + w - radiusBottomRight / 2,\n y + h,\n x + w - radiusBottomRight,\n y + h + config.bottomMargin,\n 'L',\n x + radiusBottomLeft,\n y + h + config.bottomMargin,\n 'C',\n x + radiusBottomLeft / 2,\n y + h,\n x,\n y + h - radiusBottomLeft / 2,\n x,\n y + h - radiusBottomLeft,\n 'L',\n x,\n y + radiusTopLeft,\n 'C',\n x,\n y + radiusTopLeft / 2,\n x + radiusTopLeft / 2,\n y,\n x + radiusTopLeft,\n y,\n 'Z',\n ],\n };\n}\n","export enum ChartColor {\n Grey,\n Orange,\n SoftBlue,\n ElectricBlue,\n Purple,\n Green,\n}\n\nexport class ChartColors {\n static readonly SOFT_BLUE_COLORS = {\n '10': '#EFF5FC',\n '20': '#DFEDFA',\n '40': '#C0DBF4',\n '60': '#A0C8EF',\n '85': '#78B1E8',\n '100': '#61A4E4',\n '150': '#2873BA',\n };\n static readonly ELECTRIC_BLUE_COLORS = {\n '10': '#e8f4ff',\n '20': '#d1e8ff',\n '40': '#a2d1ff',\n '60': '#74bbfe',\n '85': '#3a9efe',\n '100': '#178dfe',\n '150': '#0e72d6',\n };\n static readonly ORANGE_COLORS = {\n '10': '#FFEFE9',\n '20': '#FFE1D4',\n '40': '#FFC2A8',\n '60': '#FFA47D',\n '85': '#FF7E46',\n '100': '#FF6726',\n '150': '#C83E07',\n };\n static readonly GREEN_COLORS = {\n '10': '#ECF7ED',\n '20': '#DAF1DD',\n '40': '#B5E3BB',\n '60': '#8FD498',\n '85': '#61C26D',\n '100': '#45B854',\n '150': '#0F821D',\n };\n static readonly PURPLE_COLORS = {\n '10': '#EFEDF8',\n '20': '#E0DDF2',\n '40': '#C1BBE6',\n '60': '#A398D9',\n '85': '#7C6DC9',\n '100': '#6554C0',\n '150': '#3C2C95',\n };\n static readonly GREY_COLORS = {\n '5': '#F5F5F7',\n '10': '#EAECEF',\n '20': '#D6DAE0',\n '40': '#AEB5C1',\n '60': '#858FA1',\n '85': '#5D6A82',\n '100': '#344563',\n '150': '#212E44',\n };\n\n static readonly RED_COLORS = {\n '80': '#F17171',\n '150': '#D80505'\n };\n\n static readonly SOFT_RED_COLORS = {\n 100: '#ff5353',\n 85: '#ff6d6d',\n 60: '#ff9898',\n 10: '#fff9f9',\n };\n\n static readonly BLACK_COLOR: string = '#000000';\n static readonly LIMIT_COLOR: string = '#E81313';\n static readonly WHITE_COLOR: string = '#FFFFFF';\n\n static getChartColors(color: ChartColor | undefined): { [shade: string]: string } {\n switch (color) {\n case ChartColor.Orange:\n return this.ORANGE_COLORS;\n case ChartColor.SoftBlue:\n return this.SOFT_BLUE_COLORS;\n case ChartColor.ElectricBlue:\n return this.ELECTRIC_BLUE_COLORS;\n case ChartColor.Purple:\n return this.PURPLE_COLORS;\n case ChartColor.Green:\n return this.GREEN_COLORS;\n default:\n return this.GREY_COLORS;\n }\n }\n\n static getColors(seriesCount: number, color: ChartColor | undefined): string[] {\n const colors = this.getChartColors(color);\n switch (seriesCount) {\n case 1:\n return [colors[100]];\n case 2:\n return [colors[40], colors[100]];\n case 3:\n return [colors[20], colors[60], colors[100]];\n case 4:\n return [colors[20], colors[40], colors[60], colors[100]];\n case 5:\n return [colors[20], colors[40], colors[60], colors[100], colors[150]];\n default:\n return [colors[20], colors[40], colors[60], colors[85], colors[100], colors[150]];\n }\n }\n}\n","import { afterNextRender, DestroyRef, Directive, effect, ElementRef, inject, input, Signal, signal } from '@angular/core';\nimport { Chart, Options } from 'highcharts';\nimport { ChartColor } from './chart-colors';\n\n@Directive()\nexport abstract class AbstractChartComponent {\n private readonly destroyRef = inject(DestroyRef);\n\n /** Highcharts renders into the component's host element directly — no inner template ref needed. */\n protected readonly hostElement = inject<ElementRef<HTMLElement>>(ElementRef).nativeElement;\n\n readonly chartOptions = input<Options>({});\n readonly color = input<ChartColor>(ChartColor.ElectricBlue);\n readonly labelDateFormat = input<string>('%m/%d');\n readonly locale = input<string>('en');\n\n protected chart?: Chart;\n private readonly viewReady = signal(false);\n private resizeObserver?: ResizeObserver;\n\n /** Each subclass exposes its typed series input here so the base can react to it. */\n protected abstract readonly series: Signal<readonly unknown[]>;\n\n constructor() {\n afterNextRender(() => {\n this.resizeObserver = new ResizeObserver(() => this.onResize());\n this.resizeObserver.observe(this.hostElement);\n this.viewReady.set(true);\n });\n\n // Eager init once the view is ready: Highcharts handles 0-width containers via its\n // default width and the ResizeObserver below reflows when the container later grows.\n effect(() => {\n if (!this.viewReady()) return;\n this.rebuild();\n });\n\n this.destroyRef.onDestroy(() => {\n this.resizeObserver?.disconnect();\n this.chart?.destroy();\n });\n }\n\n protected abstract initChart(): void;\n\n private onResize(): void {\n if (this.chart) {\n this.chart.reflow();\n } else if (this.hostElement.clientWidth > 0 && this.series().length) {\n this.rebuild();\n }\n }\n\n private rebuild(): void {\n this.chart?.destroy();\n this.chart = undefined;\n this.initChart();\n }\n}\n","import { Options } from 'highcharts';\n\n/**\n * Builds Highcharts locale options (lang + tooltip date formats) from a locale string.\n * Uses the browser's Intl API to generate translated month/weekday names and number formatting rules.\n */\nexport function buildHighchartsLocaleOptions(locale: string): Options {\n const { decimalPoint, thousandsSep } = buildNumberSeparators(locale);\n\n return {\n lang: {\n decimalPoint,\n thousandsSep,\n weekdays: buildWeekdays(locale),\n shortMonths: buildShortMonths(locale),\n },\n tooltip: {\n dateTimeLabelFormats: {\n day: locale === 'en' ? '%A, %b %e, %Y' : '%A %e %b %Y',\n week: locale === 'en' ? '%A, %b %e, %Y' : '%A %e %b %Y',\n },\n },\n };\n}\n\nfunction buildNumberSeparators(locale: string): { decimalPoint: string; thousandsSep: string } {\n const parts = new Intl.NumberFormat(locale).formatToParts(12345.6);\n const decimalPoint = parts.find(p => p.type === 'decimal')?.value ?? '.';\n const thousandsSep = parts.find(p => p.type === 'group')?.value ?? ',';\n return { decimalPoint, thousandsSep };\n}\n\nfunction buildWeekdays(locale: string): string[] {\n const formatter = new Intl.DateTimeFormat(locale, { weekday: 'long' });\n // Jan 4, 1970 is a Sunday\n return Array.from({ length: 7 }, (_, i) => {\n const name = formatter.format(new Date(1970, 0, 4 + i));\n return name.charAt(0).toUpperCase() + name.slice(1);\n });\n}\n\nfunction buildShortMonths(locale: string): string[] {\n const formatter = new Intl.DateTimeFormat(locale, { month: 'short' });\n return Array.from({ length: 12 }, (_, i) => {\n const name = formatter.format(new Date(2000, i, 1));\n return name.charAt(0).toUpperCase() + name.slice(1);\n });\n}","import { cloneDeep, isPlainObject } from 'es-toolkit';\nimport { Chart, dateFormat, numberFormat, Options, Series, SeriesOptionsType, setOptions } from 'highcharts';\nimport { ChartColor, ChartColors } from './chart-colors';\nimport { buildHighchartsLocaleOptions } from './chart-locale';\nimport { SeriesRoundedColumnOptions } from './highchart-series.model';\n\nconst FONT_FAMILY = \"Averta, 'Open Sans', Helvetica, sans-serif\";\nconst LABEL_FONT_SIZE = '12px';\n\nexport class ChartOptions {\n static readonly DEFAULT_DATE_FORMAT = '%A, %b %e, %Y';\n\n static readonly DEFAULT_OPTIONS: Options = {\n chart: {\n spacingRight: 20,\n zooming: {\n type: 'xy',\n resetButton: {\n theme: {\n fill: ChartColors.WHITE_COLOR,\n r: 4,\n style: {\n color: ChartColors.GREY_COLORS[100],\n fontSize: LABEL_FONT_SIZE,\n },\n states: {\n hover: { fill: ChartColors.GREY_COLORS[5] },\n },\n },\n },\n },\n panning: { enabled: true },\n panKey: 'shift',\n style: { fontFamily: FONT_FAMILY },\n },\n colorAxis: {\n labels: { style: { color: ChartColors.GREY_COLORS[60] } },\n },\n credits: { enabled: false },\n legend: {\n borderWidth: 0,\n itemStyle: {\n color: ChartColors.GREY_COLORS[60],\n fontSize: '14px',\n fontWeight: 'normal',\n },\n itemHoverStyle: {\n color: ChartColors.GREY_COLORS[100],\n fontWeight: 'bold',\n },\n },\n plotOptions: {\n series: {\n states: {\n hover: { brightness: 0 },\n },\n connectNulls: true,\n },\n },\n navigation: {\n buttonOptions: { y: 0 },\n },\n title: { text: undefined },\n tooltip: {\n backgroundColor: ChartColors.WHITE_COLOR,\n borderRadius: 4,\n borderWidth: 0,\n dateTimeLabelFormats: {},\n shadow: {\n color: ChartColors.BLACK_COLOR,\n offsetX: 0,\n offsetY: 2,\n opacity: 0.02,\n width: 6,\n },\n split: false,\n shared: true,\n useHTML: true,\n headerFormat:\n `<div style=\"border-bottom: 1px solid ${ChartColors.GREY_COLORS[10]}; padding: 0 8px 7px\">` +\n `<div style=\"white-space: wrap; font-size: ${LABEL_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[60]}\">{point.key}</div></div>`,\n pointFormat:\n `<div style=\"font-size: 14px; color: ${ChartColors.GREY_COLORS[100]}; margin: 6px 8px 0 8px;\">` +\n '<span style=\"color:{point.color}\">●</span> {series.name}: <b>{point.y}</b> {point.custom.details}</div>',\n },\n xAxis: {\n gridLineColor: ChartColors.GREY_COLORS[10],\n lineColor: ChartColors.GREY_COLORS[10],\n tickColor: ChartColors.GREY_COLORS[10],\n gridLineWidth: 1,\n title: { text: null },\n labels: {\n style: {\n color: ChartColors.GREY_COLORS[85],\n fontSize: LABEL_FONT_SIZE,\n },\n },\n },\n yAxis: {\n allowDecimals: false,\n gridLineColor: ChartColors.GREY_COLORS[10],\n lineColor: ChartColors.GREY_COLORS[10],\n gridLineWidth: 1,\n title: { text: undefined },\n labels: {\n formatter() {\n return typeof this.value === 'string' ? this.value : numberFormat(this.value, -1);\n },\n style: {\n color: ChartColors.GREY_COLORS[85],\n fontSize: LABEL_FONT_SIZE,\n },\n },\n },\n };\n\n static build(options: Options, locale: string): Options {\n const localeOptions = buildHighchartsLocaleOptions(locale);\n setOptions({ lang: localeOptions.lang });\n return mergeDeep(mergeDeep(ChartOptions.DEFAULT_OPTIONS, localeOptions), options);\n }\n\n static configure(series: SeriesOptionsType[], options: Options, color: ChartColor | undefined, labelDateFormat?: string): void {\n options.xAxis = mergeDeep(\n {\n labels: {\n formatter(): string {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore highcharts callback context types `value` as string | number\n return dateFormat(labelDateFormat ?? '%m/%d', this.value);\n },\n },\n },\n options.xAxis\n );\n if (series?.length) {\n options.series = series;\n if (options.legend) {\n options.legend.enabled = options.legend.enabled ?? series.length >= 2;\n }\n options.colors = ChartColors.getColors(series.length, color);\n }\n }\n\n static redrawWithHighestEdgesRounded(chart: Chart): void {\n chart.series.forEach((serie, index, all) => {\n ChartOptions.roundHighestSerie(all, serie.options as SeriesRoundedColumnOptions, index);\n });\n chart.redraw(true);\n }\n\n static roundHighestSerie(series: Series[], serie: SeriesRoundedColumnOptions, serieIndex: number): void {\n if (!serie.data) return;\n\n const roundedTopMap: number[] = [];\n const roundedBottomMap: number[] = [];\n\n serie.data.forEach((point, columnIndex) => {\n const pointValue = getPointValue(point);\n const pointX = getPointX(point);\n const isNegative = pointValue !== null && pointValue < 0;\n\n if (isNegative) {\n // Negative bars go downward: the visual tip is the physical bottom.\n // Round bottom corners only on the bottommost segment of the negative stack.\n const isBottommost = series.slice(serieIndex + 1).every(other => {\n if (!other.visible) return true;\n const otherPoint = findPointAtAbscissa((other.options as SeriesRoundedColumnOptions).data, pointX, columnIndex);\n if (otherPoint === undefined) return true;\n const val = getPointValue(otherPoint);\n return val === null || val >= 0;\n });\n roundedTopMap[columnIndex] = 0;\n roundedBottomMap[columnIndex] = isBottommost ? 100 : 0;\n } else {\n // Positive bars go upward: the visual tip is the physical top.\n // Round top corners only on the topmost segment of the positive stack.\n const isTopmost = series.slice(0, serieIndex).every(other => {\n if (!other.visible) return true;\n const otherPoint = findPointAtAbscissa((other.options as SeriesRoundedColumnOptions).data, pointX, columnIndex);\n return otherPoint === undefined || getPointValue(otherPoint) === 0;\n });\n roundedTopMap[columnIndex] = isTopmost ? 100 : 0;\n roundedBottomMap[columnIndex] = 0;\n }\n });\n\n serie.borderRadiusTopLeft = roundedTopMap;\n serie.borderRadiusTopRight = roundedTopMap;\n serie.borderRadiusBottomLeft = roundedBottomMap;\n serie.borderRadiusBottomRight = roundedBottomMap;\n }\n}\n\nfunction getPointX(point: unknown): number | null {\n if (Array.isArray(point)) return point[0] as number;\n if (point && typeof point === 'object') return (point as { x?: number }).x ?? null;\n return null;\n}\n\nfunction getPointValue(point: unknown): number | null {\n if (typeof point === 'number') return point;\n if (Array.isArray(point)) return point[1] as number;\n if (point && typeof point === 'object') return (point as { y?: number }).y ?? null;\n return null;\n}\n\nfunction findPointAtAbscissa(data: unknown[] | undefined, x: number | null, fallbackIndex: number): unknown {\n if (!data) return undefined;\n if (x !== null) {\n return data.find(p => getPointX(p) === x);\n }\n return data[fallbackIndex];\n}\n\n/**\n * Deep-merges `source` onto a clone of `target` without mutating either, with one deliberate\n * deviation from `es-toolkit`'s `toMerged`: arrays are treated as opaque values (replaced wholesale)\n * rather than element-merged, which matches how Highcharts options are intended to be overridden.\n */\nexport function mergeDeep(target: any, source: any): any {\n if (!isPlainObject(target) || !isPlainObject(source)) {\n return target;\n }\n const output = cloneDeep(target) as Record<string, unknown>;\n for (const key of Object.keys(source)) {\n const sourceValue = source[key];\n if (isPlainObject(sourceValue)) {\n output[key] = key in target ? mergeDeep(target[key], sourceValue) : cloneDeep(sourceValue);\n } else {\n output[key] = sourceValue;\n }\n }\n return output;\n}\n","import { Options, PlotBarOptions, SeriesBarOptions, XAxisOptions, YAxisOptions } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\nimport { ChartColor } from './../chart-colors';\nimport { SeriesRoundedBarOptions } from './../highchart-series.model';\n\nexport class ChartBarOptions extends ChartOptions {\n static buildBars(options: Options, stacked: boolean, opposite: boolean, locale: string): Options {\n const bar: PlotBarOptions = {\n maxPointWidth: 20,\n }\n if (stacked && !opposite) {\n bar.stacking = 'normal';\n bar.events = {\n hide(): void {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n },\n show(): void {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n },\n };\n } else {\n bar.borderRadius = 100;\n }\n\n const defaultBarOptions: Options = {\n chart: {\n type: 'bar',\n },\n legend: {\n symbolHeight: 10,\n },\n xAxis: {\n categories: undefined,\n gridLineWidth: 0,\n lineWidth: 0,\n reversed: false,\n tickWidth: 0,\n labels: {\n align: 'center',\n formatter(): string {\n if (this.value && this.value.toString().length > 16) {\n return this.value.toString().substring(0, 15) + '...';\n }\n return this.value.toString();\n },\n style: {\n width: 100,\n },\n },\n type: 'category',\n },\n yAxis: {\n type: 'linear',\n minTickInterval: 1,\n },\n plotOptions: {\n bar,\n series: {\n borderWidth: 0,\n }\n },\n };\n return super.build(mergeDeep(defaultBarOptions, options), locale);\n }\n\n static configureBar(\n series: SeriesBarOptions[],\n categories: string[],\n options: Options,\n opposite: boolean,\n color: ChartColor,\n labelDateFormat?: string\n ): void {\n ChartOptions.configure(series, options, color, labelDateFormat);\n if (categories && categories.length) {\n (options.xAxis as XAxisOptions).categories = categories;\n }\n if (opposite && series.length === 2) {\n const negativeSerie = series[0] as SeriesRoundedBarOptions;\n negativeSerie.borderRadiusBottomLeft = 100;\n negativeSerie.borderRadiusBottomRight = 100;\n negativeSerie.borderRadiusTopLeft = 0;\n negativeSerie.borderRadiusTopRight = 0;\n negativeSerie.data = negativeSerie.data?.map((point: any) => {\n if (point && isNaN(point)) {\n return {\n ...point,\n y: -Math.abs(point.y),\n };\n } else if (!isNaN(point)) {\n return -Math.abs(point);\n }\n return point;\n });\n if (options.plotOptions?.series) {\n options.plotOptions.series.stacking = 'normal';\n }\n const yAxisLabels = (options.yAxis as YAxisOptions).labels;\n if (yAxisLabels) {\n yAxisLabels.formatter = function (): string {\n return Math.abs(+this.value) + '%';\n };\n }\n if (options.tooltip) {\n options.tooltip.pointFormatter = function (): string {\n return `<div style=\"font-size: 14px; color: #344563; margin: 6px 8px 0 8px;\"><span style=\"color:${\n this.color\n };\">\\u25CF</span> ${this.series.name}: <b>${Math.abs(this.y ?? 0) + '%'}</b></div>`;\n };\n }\n }\n }\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { Chart, SeriesBarOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartOptions } from '../chart-options';\nimport { ChartBarOptions } from './chart-bar-options.model';\n\n@Component({\n selector: 'ap-chart-bar',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartBarComponent extends AbstractChartComponent {\n readonly categories = input<string[]>([]);\n readonly opposite = input(false);\n readonly stacked = input(false);\n readonly series = input<SeriesBarOptions[]>([]);\n\n initChart(): void {\n const options = ChartBarOptions.buildBars(this.chartOptions(), this.stacked(), this.opposite(), this.locale());\n ChartBarOptions.configureBar(this.series(), this.categories(), options, this.opposite(), this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n if (this.stacked() && !this.opposite()) {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n }\n }\n}\n","import { Options, PlotColumnOptions } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nexport class ChartColumnOptions extends ChartOptions {\n static buildColumn(options: Options, stacked: boolean, locale: string): Options {\n const column: PlotColumnOptions = {\n borderWidth: 0,\n crisp: false,\n maxPointWidth: 20,\n };\n if (stacked) {\n column.stacking = 'normal';\n column.events = {\n hide(): void {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n },\n show(): void {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n },\n };\n } else {\n column.borderRadius = 100;\n }\n\n const defaultColumnOptions: Options = {\n chart: {\n type: 'column',\n },\n legend: {\n symbolHeight: 10,\n },\n plotOptions: {\n column,\n },\n xAxis: {\n type: 'datetime',\n minTickInterval: 1,\n },\n };\n return super.build(mergeDeep(defaultColumnOptions, options), locale);\n }\n}\n","import { ChangeDetectionStrategy, Component, input, output } from '@angular/core';\nimport { Chart, SeriesColumnOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartOptions } from '../chart-options';\nimport { ChartColumnOptions } from './chart-column-options.model';\n\n@Component({\n selector: 'ap-chart-column',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartColumnComponent extends AbstractChartComponent {\n readonly stacked = input(false);\n readonly series = input<SeriesColumnOptions[]>([]);\n\n readonly chartInitialized = output<Chart>();\n\n initChart(): void {\n const options = ChartColumnOptions.buildColumn(this.chartOptions(), this.stacked(), this.locale());\n ChartColumnOptions.configure(this.series(), options, this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n if (this.stacked()) {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n }\n this.chartInitialized.emit(this.chart);\n }\n}\n","import type {\n AxisLabelsFormatterCallbackFunction,\n ColorAxisOptions,\n Options,\n SeriesLineOptions,\n SeriesOptionsType,\n XAxisOptions,\n YAxisOptions,\n} from 'highcharts';\nimport { ChartColor, ChartColors } from '../chart-colors';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nconst HEATMAP_CONSTANTS = {\n CHART_HEIGHT: 680,\n GRID_LINE_WIDTH: 2,\n BORDER_WIDTH: 1,\n FONT_SIZE: '13px',\n HEADER_FONT_SIZE: '12px',\n TOOLTIP_FONT_SIZE: '14px',\n LEGEND_SYMBOL_WIDTH: 300,\n LEGEND_SYMBOL_HEIGHT: 10,\n TICK_INTERVAL: 3,\n DEFAULT_TICK_AMOUNT: 6,\n DEFAULT_MAX_VALUE: 3,\n MIN_VALUE: 0,\n FONT_WEIGHT: 'normal',\n} as const;\n\nconst COLORS = {\n WHITE: '#FFFFFF',\n GRID_LINE: 'white',\n NULL_COLOR: 'white',\n DEFAULT_FONT_COLOR: '#858FA1',\n} as const;\n\nexport class ChartHeatmapOptions extends ChartOptions {\n static override build(options: Options, locale: string): Options {\n const defaultHeatmapOptions: Options = {\n chart: {\n type: 'heatmap',\n height: HEATMAP_CONSTANTS.CHART_HEIGHT,\n },\n colorAxis: {\n allowDecimals: false,\n gridLineWidth: HEATMAP_CONSTANTS.GRID_LINE_WIDTH,\n gridLineColor: COLORS.GRID_LINE,\n min: HEATMAP_CONSTANTS.MIN_VALUE,\n minColor: COLORS.WHITE,\n labels: {\n style: {\n fontWeight: HEATMAP_CONSTANTS.FONT_WEIGHT,\n fontSize: HEATMAP_CONSTANTS.FONT_SIZE,\n color: COLORS.DEFAULT_FONT_COLOR,\n },\n overflow: 'allow',\n },\n },\n legend: {\n enabled: true,\n layout: 'horizontal',\n align: 'center',\n verticalAlign: 'bottom',\n symbolWidth: HEATMAP_CONSTANTS.LEGEND_SYMBOL_WIDTH,\n symbolHeight: HEATMAP_CONSTANTS.LEGEND_SYMBOL_HEIGHT,\n },\n plotOptions: {\n heatmap: {\n borderColor: ChartColors.GREY_COLORS[10],\n borderWidth: HEATMAP_CONSTANTS.BORDER_WIDTH,\n nullColor: COLORS.NULL_COLOR,\n },\n },\n tooltip: {\n headerFormat: '',\n pointFormat:\n `<div style=\"border-bottom: 1px solid ${ChartColors.GREY_COLORS[10]}; padding: 0 8px 7px\">` +\n `<span style=\"font-size: ${HEATMAP_CONSTANTS.HEADER_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[60]}\">{point.tooltipHeaderLabel}</span></div>` +\n `<div style=\"font-size: ${HEATMAP_CONSTANTS.TOOLTIP_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[100]}; margin: 6px 8px 0 8px;\">` +\n `<span style=\"color:{point.color}\">\\u25CF</span> {series.name}: <b>{point.value}{point.unit}</b></div>`,\n },\n xAxis: {\n labels: {\n formatter: this.createXAxisFormatter(),\n },\n lineWidth: 1,\n tickWidth: 0,\n visible: true,\n },\n yAxis: {\n lineWidth: 0,\n labels: {\n step: 3,\n },\n reversed: true,\n visible: true,\n },\n };\n return super.build(mergeDeep(defaultHeatmapOptions, options), locale);\n }\n\n private static createColorAxisFormatter(leastLabel: string, mostLabel: string): AxisLabelsFormatterCallbackFunction {\n return function () {\n if (this.value === this.axis.min) {\n return leastLabel;\n }\n if (this.value === this.axis.max) {\n return mostLabel;\n }\n return '';\n };\n }\n\n private static createXAxisFormatter(): AxisLabelsFormatterCallbackFunction {\n return function () {\n return this.value.toString();\n };\n }\n\n static configureHeatmap(\n categoriesX: string[],\n categoriesY: string[],\n series: SeriesOptionsType[],\n options: Options,\n color: ChartColor,\n leastLabel?: string,\n mostLabel?: string,\n labelDateFormat?: string\n ): void {\n super.configure(series, options, color, labelDateFormat);\n\n this.setAxisCategories(options, categoriesX, categoriesY);\n\n const points = (series[0] as SeriesLineOptions).data as { x: number; y: number; value: number }[];\n const maxValue = points.reduce((max, point) => Math.max(max, point.value), 0) || HEATMAP_CONSTANTS.DEFAULT_MAX_VALUE;\n\n this.configureColorAxis(options, color, maxValue, leastLabel, mostLabel);\n\n this.configureLegend(options);\n }\n\n private static setAxisCategories(options: Options, categoriesX: string[], categoriesY: string[]): void {\n if (categoriesX?.length) {\n (options.xAxis as XAxisOptions).categories = categoriesX;\n }\n if (categoriesY?.length) {\n (options.yAxis as YAxisOptions).categories = categoriesY;\n }\n }\n\n private static configureColorAxis(\n options: Options,\n color: ChartColor,\n maxValue: number,\n leastLabel?: string,\n mostLabel?: string\n ): void {\n const tickPositions = this.buildTickPositions(maxValue);\n const labelsEnabled = !!(leastLabel && mostLabel);\n\n options.colorAxis = {\n ...(options.colorAxis || {}),\n visible: labelsEnabled,\n min: HEATMAP_CONSTANTS.MIN_VALUE,\n max: HEATMAP_CONSTANTS.DEFAULT_MAX_VALUE,\n tickPositions,\n maxColor: ChartColors.getChartColors(color)[100],\n };\n\n if (labelsEnabled) {\n options.colorAxis.labels = {\n ...((options.colorAxis as ColorAxisOptions)?.labels || {}),\n formatter: this.createColorAxisFormatter(leastLabel, mostLabel),\n };\n }\n }\n\n private static configureLegend(options: Options): void {\n options.legend = {\n ...options.legend,\n enabled: true,\n };\n }\n\n private static buildTickPositions(maxValue: number): number[] {\n const tickAmount = HEATMAP_CONSTANTS.DEFAULT_TICK_AMOUNT;\n\n // Calculate the step between each tick\n // We subtract 1 from tickAmount so that the last tick is exactly at maxValue\n const step = maxValue / (tickAmount - 1);\n\n // Generate an array of positions for the ticks\n // Each position is calculated as i * step and rounded to 2 decimal places\n return Array.from({ length: tickAmount }, (_, i) => parseFloat((i * step).toFixed(2)));\n }\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { SeriesHeatmapOptions } from 'highcharts';\nimport { mapChart } from 'highcharts/highmaps';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartHeatmapOptions } from './chart-heatmap-options.model';\n\ntype LegendLabels = { least: string; most: string };\n\n@Component({\n selector: 'ap-chart-heatmap',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartHeatmapComponent extends AbstractChartComponent {\n readonly categoriesX = input<string[]>([]);\n readonly categoriesY = input<string[]>([]);\n readonly series = input<SeriesHeatmapOptions[]>([]);\n readonly legendLabels = input<LegendLabels>();\n\n protected initChart(): void {\n const labels = this.legendLabels();\n const options = ChartHeatmapOptions.build(this.chartOptions(), this.locale());\n ChartHeatmapOptions.configureHeatmap(\n this.categoriesX(),\n this.categoriesY(),\n this.series(),\n options,\n this.color(),\n labels?.least,\n labels?.most,\n this.labelDateFormat()\n );\n this.chart = mapChart(this.hostElement, options);\n }\n}\n","import { Options } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nexport class ChartMixedOptions extends ChartOptions {\n static buildMixed(options: Options, singleDayEnabled: boolean, locale: string): Options {\n const defaultOptions: Options = {\n chart: {\n type: 'column',\n },\n legend: {\n symbolHeight: 10,\n },\n plotOptions: {\n series: {\n marker: {\n enabled: singleDayEnabled,\n radius: singleDayEnabled ? 5 : 2,\n symbol: 'circle',\n },\n lineWidth: 4\n },\n column: {\n stacking: 'normal',\n borderWidth: 0,\n maxPointWidth: 20,\n events: {\n hide(): void {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n },\n show(): void {\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n },\n },\n },\n },\n xAxis: {\n type: 'datetime',\n },\n };\n return super.build(mergeDeep(defaultOptions, options), locale);\n }\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { Chart, SeriesOptionsType, SeriesSplineOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartOptions } from '../chart-options';\nimport { ChartMixedOptions } from './chart-mixed-options.model';\n\n@Component({\n selector: 'ap-chart-mixed',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartMixedComponent extends AbstractChartComponent {\n readonly series = input<SeriesOptionsType[]>([]);\n\n protected initChart(): void {\n const series = this.series();\n const splineSeries = series.find(serie => serie.type === 'spline') as SeriesSplineOptions | undefined;\n const singleDayEnabled = splineSeries?.data?.length === 1;\n const options = ChartMixedOptions.buildMixed(this.chartOptions(), singleDayEnabled, this.locale());\n ChartMixedOptions.configure(series, options, this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n ChartOptions.redrawWithHighestEdgesRounded(this.chart);\n }\n}\n","import { round } from 'es-toolkit';\nimport { numberFormat, Options, SeriesPieOptions } from 'highcharts';\nimport { ChartColors } from '../chart-colors';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nconst NAME_MAX_LENGTH = 30;\n// Hebrew, Arabic, and other RTL scripts\nconst RIGHT_TO_LEFT_CHARACTERS =\n /[\\p{Script=Arabic}\\p{Script=Hebrew}\\p{Script=Syriac}\\p{Script=Thaana}\\p{Script=Nko}\\p{Script=Samaritan}\\p{Script=Mandaic}]/u;\nconst RIGHT_TO_LEFT_EMBEDDING_CHARACTER = '';\n\nexport class ChartPieOptions extends ChartOptions {\n static buildPie(options: Options, innerLabels: boolean, metricFormat: 'percentage' | 'value', locale: string): Options {\n const defaultPieOptions: Options = {\n chart: {\n type: 'pie',\n plotBackgroundColor: undefined,\n plotBorderWidth: undefined,\n plotShadow: false,\n },\n plotOptions: {\n pie: {\n dataLabels: {\n distance: innerLabels ? -40 : 30,\n useHTML: true,\n },\n innerSize: '50%',\n },\n series: {\n allowPointSelect: !innerLabels,\n dataLabels: innerLabels ? buildInnerLabels(metricFormat) : buildOuterLabels(metricFormat),\n showInLegend: innerLabels,\n },\n },\n tooltip: {\n outside: true,\n },\n legend: innerLabels ? { symbolHeight: 10, enabled: true } : {},\n };\n return super.build(mergeDeep(defaultPieOptions, options), locale);\n }\n\n static configurePie(\n series: SeriesPieOptions[],\n options: Options,\n colors: string[],\n labelDateFormat: string,\n innerLabels: boolean,\n mouseEventEnabled = true\n ): void {\n super.configure(series, options, undefined, labelDateFormat);\n if (innerLabels && options.legend) {\n options.legend.enabled = true;\n }\n if (!series?.[0]) {\n return;\n }\n options.colors = colors;\n // When mouse interaction is disabled (e.g. half-donut summary), turn off hover/tooltip\n // wholesale. Otherwise we rely on Highcharts' default `states.inactive.opacity` (0.2)\n // to fade non-hovered slices — see https://api.highcharts.com/highcharts/plotOptions.pie.states.inactive\n if (!mouseEventEnabled) {\n options.plotOptions ??= {};\n options.plotOptions.pie ??= {};\n options.plotOptions.pie.enableMouseTracking = false;\n }\n }\n}\n\nfunction buildInnerLabels(metricFormat: 'percentage' | 'value') {\n return {\n format: metricFormat === 'percentage' ? '{point.percentage:.1f}%' : '{point.y}',\n style: {\n fontSize: '16px',\n color: 'white',\n textOutline: '0',\n },\n };\n}\n\nfunction buildOuterLabels(metricFormat: 'percentage' | 'value') {\n return {\n formatter(this: { name: string; percentage?: number; y?: number | null }): string {\n const truncatedName = this.name.length > NAME_MAX_LENGTH ? this.name.substring(0, NAME_MAX_LENGTH) + '...' : this.name;\n const displayValue =\n metricFormat === 'percentage' ? numberFormat(round(this.percentage ?? 0, 1), -1) + '%' : numberFormat(this.y ?? 0, -1);\n const prefix = RIGHT_TO_LEFT_CHARACTERS.test(this.name.charAt(0)) ? RIGHT_TO_LEFT_EMBEDDING_CHARACTER : '';\n return prefix + truncatedName + ': ' + displayValue;\n },\n style: {\n fontSize: '12px',\n color: ChartColors.GREY_COLORS[60],\n },\n };\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { Chart, SeriesPieOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartColors } from '../chart-colors';\nimport { ChartPieOptions } from './chart-pie-options.model';\n\n@Component({\n selector: 'ap-chart-pie',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartPieComponent extends AbstractChartComponent {\n readonly innerLabels = input(false);\n readonly mouseEventEnabled = input(true);\n readonly series = input<SeriesPieOptions[]>([]);\n readonly colors = input<string[]>();\n readonly metricFormat = input<'percentage' | 'value'>('percentage');\n\n protected initChart(): void {\n const series = this.series();\n const innerLabels = this.innerLabels();\n const dataAvailable = !!series[0]?.data?.length;\n const options = ChartPieOptions.buildPie(this.chartOptions(), innerLabels, this.metricFormat(), this.locale());\n\n const effectiveSeries: SeriesPieOptions[] = dataAvailable\n ? series\n : [\n {\n type: 'pie',\n data: [{ y: 1, dataLabels: { enabled: false } }],\n enableMouseTracking: false,\n },\n ];\n\n const effectiveColors = !dataAvailable\n ? [ChartColors.GREY_COLORS[10]]\n : (this.colors() ?? ChartColors.getColors(series[0]?.data?.length ?? 0, this.color()));\n\n ChartPieOptions.configurePie(\n effectiveSeries,\n options,\n effectiveColors,\n this.labelDateFormat(),\n innerLabels,\n this.mouseEventEnabled()\n );\n this.chart = new Chart(this.hostElement, options);\n }\n}\n","import { Options } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nexport class ChartSplineOptions extends ChartOptions {\n static buildSpline(options: Options, singleDayEnabled: boolean, locale: string): Options {\n const defaultSplineOptions: Options = {\n chart: {\n type: 'spline',\n },\n plotOptions: {\n series: {\n marker: {\n enabled: singleDayEnabled,\n radius: singleDayEnabled ? 5 : 2,\n symbol: 'circle',\n },\n lineWidth: 4\n },\n },\n xAxis: {\n type: 'datetime',\n },\n };\n return super.build(mergeDeep(defaultSplineOptions, options), locale);\n }\n}\n","import { ChangeDetectionStrategy, Component, input, output } from '@angular/core';\nimport { Chart, SeriesSplineOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartSplineOptions } from './chart-spline-options.model';\n\n@Component({\n selector: 'ap-chart-spline',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartSplineComponent extends AbstractChartComponent {\n readonly series = input<SeriesSplineOptions[]>([]);\n\n readonly chartInitialized = output<Chart>();\n\n protected initChart(): void {\n const series = this.series();\n const singleDayEnabled = series[0]?.data?.length === 1;\n const options = ChartSplineOptions.buildSpline(this.chartOptions(), singleDayEnabled, this.locale());\n ChartSplineOptions.configure(series, options, this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n this.chartInitialized.emit(this.chart);\n }\n}\n","import * as Highcharts from 'highcharts';\nimport { borderRadiusPlugin } from './src/lib/highcharts-border-radius-plugin';\nborderRadiusPlugin(Highcharts);\n\nexport { AbstractChartComponent } from './src/lib/abstract-chart.component';\nexport { ChartBarComponent } from './src/lib/chart-bar/chart-bar.component';\nexport { ChartColor, ChartColors } from './src/lib/chart-colors';\nexport { ChartColumnComponent } from './src/lib/chart-column/chart-column.component';\nexport { ChartHeatmapComponent } from './src/lib/chart-heatmap/chart-heatmap.component';\nexport { ChartMixedComponent } from './src/lib/chart-mixed/chart-mixed.component';\nexport { ChartOptions, mergeDeep } from './src/lib/chart-options';\nexport { ChartPieComponent } from './src/lib/chart-pie/chart-pie.component';\nexport { ChartSplineComponent } from './src/lib/chart-spline/chart-spline.component';\n\nexport { borderRadiusPlugin } from './src/lib/highcharts-border-radius-plugin';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AA4BM,SAAU,kBAAkB,CAAC,CAAoB,EAAA;IACnD,MAAM,OAAO,GAAG,CAAsB;IACtC,IAAI,OAAO,CAAC,6BAA6B;QAAE;AAC3C,IAAA,OAAO,CAAC,6BAA6B,GAAG,IAAI;AAE5C,IAAA,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,MAAM,CAAC,SAAS,EAAE,WAAW,EAAE,UAA8B,OAAmB,EAAA;QACvG,MAAM,EACF,SAAS,GAAG,CAAC,EACb,YAAY,GAAG,CAAC,EAChB,mBAAmB,EACnB,oBAAoB,EACpB,sBAAsB,EACtB,uBAAuB,GAC1B,GAAG,IAAI,CAAC,OAAO;AAEhB,QAAA,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC;QAElB,IAAI,CAAC,IAAI,CAAC,MAAM;YAAE;QAClB,IAAI,CAAC,mBAAmB,IAAI,CAAC,oBAAoB,IAAI,CAAC,sBAAsB,IAAI,CAAC,uBAAuB;YAAE;AAE1G,QAAA,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,IACrB,UAAU,CAAC,KAAK,EAAE,CAAC,EAAE;YACjB,SAAS;YACT,YAAY;AACZ,YAAA,OAAO,EAAE,mBAAmB;AAC5B,YAAA,QAAQ,EAAE,oBAAoB;AAC9B,YAAA,UAAU,EAAE,sBAAsB;AAClC,YAAA,WAAW,EAAE,uBAAuB;AACvC,SAAA,CAAC,CACL;A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AAA,EAAA,IAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAIH,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBANhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,iBAAiB;AAC3B,oBAAA,QAAQ,EAAE,EAAE;AACZ,oBAAA,IAAI,EAAE,EAAE,KAAK,EAAE,gBAAgB,EAAE;oBACjC,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAClD,iBAAA;;;ACRD,kBAAkB,CAAC,UAAU,CAAC;;ACF9B;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"agorapulse-ui-charts.mjs","sources":["../../../libs/ui-charts/src/lib/chart-colors.ts","../../../libs/ui-charts/src/lib/abstract-chart.component.ts","../../../libs/ui-charts/src/lib/chart-locale.ts","../../../libs/ui-charts/src/lib/chart-options.ts","../../../libs/ui-charts/src/lib/chart-bar/chart-bar-options.model.ts","../../../libs/ui-charts/src/lib/chart-bar/chart-bar.component.ts","../../../libs/ui-charts/src/lib/chart-column/chart-column-options.model.ts","../../../libs/ui-charts/src/lib/chart-column/chart-column.component.ts","../../../libs/ui-charts/src/lib/chart-heatmap/chart-heatmap-options.model.ts","../../../libs/ui-charts/src/lib/chart-heatmap/chart-heatmap.component.ts","../../../libs/ui-charts/src/lib/chart-mixed/chart-mixed-options.model.ts","../../../libs/ui-charts/src/lib/chart-mixed/chart-mixed.component.ts","../../../libs/ui-charts/src/lib/chart-pie/chart-pie-options.model.ts","../../../libs/ui-charts/src/lib/chart-pie/chart-pie.component.ts","../../../libs/ui-charts/src/lib/chart-spline/chart-spline-options.model.ts","../../../libs/ui-charts/src/lib/chart-spline/chart-spline.component.ts","../../../libs/ui-charts/agorapulse-ui-charts.ts"],"sourcesContent":["export enum ChartColor {\n Grey,\n Orange,\n SoftBlue,\n ElectricBlue,\n Purple,\n Green,\n}\n\nexport class ChartColors {\n static readonly SOFT_BLUE_COLORS = {\n '10': '#EFF5FC',\n '20': '#DFEDFA',\n '40': '#C0DBF4',\n '60': '#A0C8EF',\n '85': '#78B1E8',\n '100': '#61A4E4',\n '150': '#2873BA',\n };\n static readonly ELECTRIC_BLUE_COLORS = {\n '10': '#e8f4ff',\n '20': '#d1e8ff',\n '40': '#a2d1ff',\n '60': '#74bbfe',\n '85': '#3a9efe',\n '100': '#178dfe',\n '150': '#0e72d6',\n };\n static readonly ORANGE_COLORS = {\n '10': '#FFEFE9',\n '20': '#FFE1D4',\n '40': '#FFC2A8',\n '60': '#FFA47D',\n '85': '#FF7E46',\n '100': '#FF6726',\n '150': '#C83E07',\n };\n static readonly GREEN_COLORS = {\n '10': '#ECF7ED',\n '20': '#DAF1DD',\n '40': '#B5E3BB',\n '60': '#8FD498',\n '85': '#61C26D',\n '100': '#45B854',\n '150': '#0F821D',\n };\n static readonly PURPLE_COLORS = {\n '10': '#EFEDF8',\n '20': '#E0DDF2',\n '40': '#C1BBE6',\n '60': '#A398D9',\n '85': '#7C6DC9',\n '100': '#6554C0',\n '150': '#3C2C95',\n };\n static readonly GREY_COLORS = {\n '5': '#F5F5F7',\n '10': '#EAECEF',\n '20': '#D6DAE0',\n '40': '#AEB5C1',\n '60': '#858FA1',\n '85': '#5D6A82',\n '100': '#344563',\n '150': '#212E44',\n };\n\n static readonly RED_COLORS = {\n '80': '#F17171',\n '100': '#E81313',\n '150': '#D80505',\n };\n\n /**\n * Categorical data palette — 10 distinct hues used to tell apart networks, profiles, or metrics in the same chart.\n * Order is fixed and assigned by position (1st category → DATA_COLORS[0]).\n * For more than 10 categories the palette wraps; the legend is the source of truth.\n */\n static readonly DATA_COLORS = [\n '#12AABA', // data-cyan-100\n '#D98800', // data-sun-100\n '#CC2878', // data-peony-100\n '#42B85A', // data-lime-100\n '#8A62CC', // data-iris-10\n '#CC5040', // data-cherry-100\n '#3A92E8', // data-sky-100\n '#DC6A30', // data-tangerine-100\n '#12A87A', // data-emerald-100\n '#4A6ACC', // data-navy-100\n ];\n\n /**\n * Sentiment palette — fixed mapping from sentiment to brand colors.\n * Used by sentiment widgets only; not part of the categorical data palette.\n */\n static readonly SENTIMENT_COLORS = {\n positive: '#45B854', // green-100\n neutral: '#858FA1', // grey-60\n negative: '#E81313', // red-100\n };\n\n /**\n * Heatmap / world-map palette — single shade (data-navy / data-marine) at 5 fixed opacity levels.\n * Listed in ascending intensity (20% → 100%).\n */\n static readonly HEATMAP_BASE_RGB: readonly [number, number, number] = [74, 106, 204];\n static readonly HEATMAP_OPACITIES: readonly number[] = [0.2, 0.4, 0.6, 0.8, 1];\n static readonly HEATMAP_COLORS: readonly string[] = [\n 'rgba(74, 106, 204, 0.2)',\n 'rgba(74, 106, 204, 0.4)',\n 'rgba(74, 106, 204, 0.6)',\n 'rgba(74, 106, 204, 0.8)',\n 'rgba(74, 106, 204, 1)',\n ];\n\n static readonly SOFT_RED_COLORS = {\n 100: '#ff5353',\n 85: '#ff6d6d',\n 60: '#ff9898',\n 10: '#fff9f9',\n };\n\n static readonly BLACK_COLOR: string = '#000000';\n static readonly LIMIT_COLOR: string = '#E81313';\n static readonly WHITE_COLOR: string = '#FFFFFF';\n\n static getChartColors(color: ChartColor | undefined): { [shade: string]: string } {\n switch (color) {\n case ChartColor.Orange:\n return this.ORANGE_COLORS;\n case ChartColor.SoftBlue:\n return this.SOFT_BLUE_COLORS;\n case ChartColor.ElectricBlue:\n return this.ELECTRIC_BLUE_COLORS;\n case ChartColor.Purple:\n return this.PURPLE_COLORS;\n case ChartColor.Green:\n return this.GREEN_COLORS;\n default:\n return this.GREY_COLORS;\n }\n }\n\n /**\n * Returns the categorical data color at the given 0-based position.\n * Wraps modulo `DATA_COLORS.length` (10) so position 10 reuses position 0.\n */\n static getDataColor(position: number): string {\n const palette = ChartColors.DATA_COLORS;\n return palette[((position % palette.length) + palette.length) % palette.length];\n }\n\n /**\n * Returns the first `count` data colors from the categorical palette.\n * Wraps after 10 positions.\n */\n static getDataColors(count: number): string[] {\n return Array.from({ length: Math.max(count, 0) }, (_, index) => ChartColors.getDataColor(index));\n }\n\n static getColors(seriesCount: number, color: ChartColor | undefined): string[] {\n const colors = this.getChartColors(color);\n switch (seriesCount) {\n case 1:\n return [colors[100]];\n case 2:\n return [colors[40], colors[100]];\n case 3:\n return [colors[20], colors[60], colors[100]];\n case 4:\n return [colors[20], colors[40], colors[60], colors[100]];\n case 5:\n return [colors[20], colors[40], colors[60], colors[100], colors[150]];\n default:\n return [colors[20], colors[40], colors[60], colors[85], colors[100], colors[150]];\n }\n }\n}\n","import { afterNextRender, DestroyRef, Directive, effect, ElementRef, inject, input, Signal, signal } from '@angular/core';\nimport { Chart, Options } from 'highcharts';\nimport { ChartColor } from './chart-colors';\n\n@Directive()\nexport abstract class AbstractChartComponent {\n private readonly destroyRef = inject(DestroyRef);\n\n /** Highcharts renders into the host element directly. */\n protected readonly hostElement = inject<ElementRef<HTMLElement>>(ElementRef).nativeElement;\n\n readonly chartOptions = input<Options>({});\n readonly color = input<ChartColor>(ChartColor.ElectricBlue);\n readonly labelDateFormat = input<string>('%m/%d');\n readonly locale = input<string>('en');\n\n protected chart?: Chart;\n private readonly viewReady = signal(false);\n private resizeObserver?: ResizeObserver;\n\n /** Subclasses expose their typed series input so the base can observe it. */\n protected abstract readonly series: Signal<readonly unknown[]>;\n\n constructor() {\n afterNextRender(() => {\n this.resizeObserver = new ResizeObserver(() => this.onResize());\n this.resizeObserver.observe(this.hostElement);\n this.viewReady.set(true);\n });\n\n // Eager init on view-ready; ResizeObserver reflows as the container grows.\n effect(() => {\n if (!this.viewReady()) return;\n this.rebuild();\n });\n\n this.destroyRef.onDestroy(() => {\n this.resizeObserver?.disconnect();\n this.chart?.destroy();\n });\n }\n\n protected abstract initChart(): void;\n\n private onResize(): void {\n if (this.chart) {\n this.chart.reflow();\n } else if (this.hostElement.clientWidth > 0 && this.series().length) {\n this.rebuild();\n }\n }\n\n private rebuild(): void {\n this.chart?.destroy();\n this.chart = undefined;\n this.initChart();\n }\n}\n","import { Options } from 'highcharts';\n\n/** `lang.locale` drives Intl-based weekday/month/number formatting; we only override the tooltip date order. */\nexport function buildHighchartsLocaleOptions(locale: string): Options {\n const dayFormat = locale === 'en' ? '%A, %b %e, %Y' : '%A %e %b %Y';\n return {\n lang: { locale },\n tooltip: {\n dateTimeLabelFormats: {\n day: dayFormat,\n week: dayFormat,\n },\n },\n };\n}\n","import { cloneDeep, isPlainObject } from 'es-toolkit';\nimport { Options, SeriesOptionsType, setOptions } from 'highcharts';\nimport { ChartColor, ChartColors } from './chart-colors';\nimport { buildHighchartsLocaleOptions } from './chart-locale';\n\nconst FONT_FAMILY = \"Averta, 'Open Sans', Helvetica, sans-serif\";\nconst LABEL_FONT_SIZE = '12px';\n\nexport class ChartOptions {\n static readonly DEFAULT_DATE_FORMAT = '%A, %b %e, %Y';\n\n static readonly DEFAULT_OPTIONS: Options = {\n chart: {\n spacingRight: 20,\n zooming: {\n type: 'xy',\n resetButton: {\n theme: {\n fill: ChartColors.WHITE_COLOR,\n r: 4,\n style: {\n color: ChartColors.GREY_COLORS[100],\n fontSize: LABEL_FONT_SIZE,\n },\n states: {\n hover: { fill: ChartColors.GREY_COLORS[5] },\n },\n },\n },\n },\n panning: { enabled: true },\n panKey: 'shift',\n style: { fontFamily: FONT_FAMILY },\n },\n colorAxis: {\n labels: { style: { color: ChartColors.GREY_COLORS[60] } },\n },\n credits: { enabled: false },\n legend: {\n borderWidth: 0,\n itemStyle: {\n color: ChartColors.GREY_COLORS[60],\n fontSize: '14px',\n fontWeight: 'normal',\n },\n itemHoverStyle: {\n color: ChartColors.GREY_COLORS[100],\n fontWeight: 'bold',\n },\n },\n plotOptions: {\n series: {\n states: {\n hover: { brightness: 0 },\n },\n connectNulls: true,\n },\n },\n navigation: {\n buttonOptions: { y: 0 },\n },\n title: { text: undefined },\n tooltip: {\n backgroundColor: ChartColors.WHITE_COLOR,\n borderRadius: 4,\n borderWidth: 0,\n dateTimeLabelFormats: {},\n shadow: {\n color: ChartColors.BLACK_COLOR,\n offsetX: 0,\n offsetY: 2,\n opacity: 0.02,\n width: 6,\n },\n split: false,\n shared: true,\n useHTML: true,\n headerFormat:\n `<div style=\"border-bottom: 1px solid ${ChartColors.GREY_COLORS[10]}; padding: 0 8px 7px\">` +\n `<div style=\"white-space: wrap; font-size: ${LABEL_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[60]}\">{point.key}</div></div>`,\n pointFormat:\n `<div style=\"font-size: 14px; color: ${ChartColors.GREY_COLORS[100]}; margin: 6px 8px 0 8px;\">` +\n '<span style=\"color:{point.color}\">●</span> {series.name}: <b>{point.y}</b> {point.custom.details}</div>',\n },\n xAxis: {\n gridLineColor: ChartColors.GREY_COLORS[10],\n lineColor: ChartColors.GREY_COLORS[10],\n tickColor: ChartColors.GREY_COLORS[10],\n gridLineWidth: 1,\n title: { text: null },\n labels: {\n style: {\n color: ChartColors.GREY_COLORS[85],\n fontSize: LABEL_FONT_SIZE,\n },\n },\n },\n yAxis: {\n allowDecimals: false,\n gridLineColor: ChartColors.GREY_COLORS[10],\n lineColor: ChartColors.GREY_COLORS[10],\n gridLineWidth: 1,\n title: { text: undefined },\n labels: {\n // Highcharts auto-formats per `lang.locale`.\n style: {\n color: ChartColors.GREY_COLORS[85],\n fontSize: LABEL_FONT_SIZE,\n },\n },\n },\n };\n\n static build(options: Options, locale: string): Options {\n const localeOptions = buildHighchartsLocaleOptions(locale);\n setOptions({ lang: localeOptions.lang });\n return mergeDeep(mergeDeep(ChartOptions.DEFAULT_OPTIONS, localeOptions), options);\n }\n\n static configure(series: SeriesOptionsType[], options: Options, color: ChartColor | undefined, labelDateFormat?: string): void {\n options.xAxis = mergeDeep({ labels: { format: `{value:${labelDateFormat ?? '%m/%d'}}` } }, options.xAxis);\n if (series?.length) {\n options.series = series;\n if (options.legend) {\n options.legend.enabled = options.legend.enabled ?? series.length >= 2;\n }\n options.colors = ChartColors.getColors(series.length, color);\n }\n }\n}\n\n/** Deep-merge clone (immutable). Arrays are replaced wholesale, not element-merged like `es-toolkit`'s `toMerged`. */\nexport function mergeDeep(target: any, source: any): any {\n if (!isPlainObject(target) || !isPlainObject(source)) {\n return target;\n }\n const output = cloneDeep(target) as Record<string, unknown>;\n for (const key of Object.keys(source)) {\n const sourceValue = source[key];\n if (isPlainObject(sourceValue)) {\n output[key] = key in target ? mergeDeep(target[key], sourceValue) : cloneDeep(sourceValue);\n } else {\n output[key] = sourceValue;\n }\n }\n return output;\n}\n","import { Options, PlotBarOptions, SeriesBarOptions, XAxisOptions, YAxisOptions } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\nimport { ChartColor } from './../chart-colors';\n\nexport class ChartBarOptions extends ChartOptions {\n static buildBars(options: Options, stacked: boolean, opposite: boolean, locale: string): Options {\n const bar: PlotBarOptions = {\n maxPointWidth: 20,\n };\n if (stacked || opposite) {\n // `opposite` = diverging left/right bars (one series flipped to negative).\n bar.stacking = 'normal';\n bar.borderRadius = { radius: '50%', scope: 'stack', where: 'end' };\n } else {\n bar.borderRadius = '50%';\n }\n\n const defaultBarOptions: Options = {\n chart: {\n type: 'bar',\n },\n legend: {\n symbolHeight: 10,\n },\n xAxis: {\n categories: undefined,\n gridLineWidth: 0,\n lineWidth: 0,\n reversed: false,\n tickWidth: 0,\n labels: {\n align: 'center',\n formatter(): string {\n if (this.value && this.value.toString().length > 16) {\n return this.value.toString().substring(0, 15) + '...';\n }\n return this.value.toString();\n },\n style: {\n width: 100,\n },\n },\n type: 'category',\n },\n yAxis: {\n type: 'linear',\n minTickInterval: 1,\n },\n plotOptions: {\n bar,\n series: {\n borderWidth: 0,\n },\n },\n };\n return super.build(mergeDeep(defaultBarOptions, options), locale);\n }\n\n static configureBar(\n series: SeriesBarOptions[],\n categories: string[],\n options: Options,\n opposite: boolean,\n color: ChartColor,\n labelDateFormat?: string\n ): void {\n ChartOptions.configure(series, options, color, labelDateFormat);\n if (categories?.length) {\n (options.xAxis as XAxisOptions).categories = categories;\n }\n if (opposite && series.length === 2) {\n const negativeSerie = series[0];\n // Flip the first series negative so it stacks left of zero.\n negativeSerie.data = negativeSerie.data?.map((point: any) => {\n if (point && isNaN(point)) {\n return { ...point, y: -Math.abs(point.y) };\n }\n if (!isNaN(point)) {\n return -Math.abs(point);\n }\n return point;\n });\n const yAxisLabels = (options.yAxis as YAxisOptions).labels;\n if (yAxisLabels) {\n yAxisLabels.formatter = function (): string {\n return Math.abs(+this.value) + '%';\n };\n }\n if (options.tooltip) {\n options.tooltip.pointFormatter = function (): string {\n return `<div style=\"font-size: 14px; color: #344563; margin: 6px 8px 0 8px;\"><span style=\"color:${\n this.color\n };\">●</span> ${this.series.name}: <b>${Math.abs(this.y ?? 0) + '%'}</b></div>`;\n };\n }\n }\n }\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { Chart, SeriesBarOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartBarOptions } from './chart-bar-options.model';\n\n@Component({\n selector: 'ap-chart-bar',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartBarComponent extends AbstractChartComponent {\n readonly categories = input<string[]>([]);\n readonly opposite = input(false);\n readonly stacked = input(false);\n readonly series = input<SeriesBarOptions[]>([]);\n\n initChart(): void {\n const options = ChartBarOptions.buildBars(this.chartOptions(), this.stacked(), this.opposite(), this.locale());\n ChartBarOptions.configureBar(\n this.series(),\n this.categories(),\n options,\n this.opposite(),\n this.color(),\n this.labelDateFormat()\n );\n this.chart = new Chart(this.hostElement, options);\n }\n}\n","import { Options, PlotColumnOptions } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nexport class ChartColumnOptions extends ChartOptions {\n static buildColumn(options: Options, stacked: boolean, locale: string): Options {\n const column: PlotColumnOptions = {\n borderWidth: 0,\n crisp: false,\n maxPointWidth: 20,\n // Round only the value-side end; `scope: 'stack'` keeps middle segments square.\n borderRadius: stacked ? { radius: '50%', scope: 'stack', where: 'end' } : '50%',\n };\n if (stacked) {\n column.stacking = 'normal';\n }\n\n const defaultColumnOptions: Options = {\n chart: {\n type: 'column',\n },\n legend: {\n symbolHeight: 10,\n },\n plotOptions: {\n column,\n },\n xAxis: {\n type: 'datetime',\n minTickInterval: 1,\n },\n };\n return super.build(mergeDeep(defaultColumnOptions, options), locale);\n }\n}\n","import { ChangeDetectionStrategy, Component, input, output } from '@angular/core';\nimport { Chart, SeriesColumnOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartColumnOptions } from './chart-column-options.model';\n\n@Component({\n selector: 'ap-chart-column',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartColumnComponent extends AbstractChartComponent {\n readonly stacked = input(false);\n readonly series = input<SeriesColumnOptions[]>([]);\n\n readonly chartInitialized = output<Chart>();\n\n initChart(): void {\n const options = ChartColumnOptions.buildColumn(this.chartOptions(), this.stacked(), this.locale());\n ChartColumnOptions.configure(this.series(), options, this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n this.chartInitialized.emit(this.chart);\n }\n}\n","import type {\n AxisLabelsFormatterCallbackFunction,\n ColorAxisOptions,\n Options,\n PointOptionsObject,\n SeriesHeatmapOptions,\n SeriesOptionsType,\n XAxisOptions,\n YAxisOptions,\n} from 'highcharts';\nimport { ChartColor, ChartColors } from '../chart-colors';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nconst HEATMAP_CONSTANTS = {\n CHART_HEIGHT: 680,\n GRID_LINE_WIDTH: 2,\n BORDER_WIDTH: 1,\n FONT_SIZE: '13px',\n HEADER_FONT_SIZE: '12px',\n TOOLTIP_FONT_SIZE: '14px',\n LEGEND_SYMBOL_WIDTH: 300,\n LEGEND_SYMBOL_HEIGHT: 10,\n DEFAULT_TICK_AMOUNT: 6,\n DEFAULT_MAX_VALUE: 3,\n MIN_VALUE: 0,\n FONT_WEIGHT: 'normal',\n} as const;\n\nconst COLORS = {\n WHITE: '#FFFFFF',\n GRID_LINE: 'white',\n NULL_COLOR: 'white',\n DEFAULT_FONT_COLOR: '#858FA1',\n} as const;\n\nexport class ChartHeatmapOptions extends ChartOptions {\n static override build(options: Options, locale: string): Options {\n const defaultHeatmapOptions: Options = {\n chart: {\n type: 'heatmap',\n height: HEATMAP_CONSTANTS.CHART_HEIGHT,\n },\n colorAxis: {\n allowDecimals: false,\n gridLineWidth: HEATMAP_CONSTANTS.GRID_LINE_WIDTH,\n gridLineColor: COLORS.GRID_LINE,\n min: HEATMAP_CONSTANTS.MIN_VALUE,\n minColor: COLORS.WHITE,\n labels: {\n style: {\n fontWeight: HEATMAP_CONSTANTS.FONT_WEIGHT,\n fontSize: HEATMAP_CONSTANTS.FONT_SIZE,\n color: COLORS.DEFAULT_FONT_COLOR,\n },\n overflow: 'allow',\n },\n },\n legend: {\n enabled: true,\n layout: 'horizontal',\n align: 'center',\n verticalAlign: 'bottom',\n symbolWidth: HEATMAP_CONSTANTS.LEGEND_SYMBOL_WIDTH,\n symbolHeight: HEATMAP_CONSTANTS.LEGEND_SYMBOL_HEIGHT,\n },\n plotOptions: {\n heatmap: {\n borderColor: ChartColors.GREY_COLORS[10],\n borderWidth: HEATMAP_CONSTANTS.BORDER_WIDTH,\n nullColor: COLORS.NULL_COLOR,\n },\n },\n tooltip: {\n headerFormat: '',\n pointFormat:\n `<div style=\"border-bottom: 1px solid ${ChartColors.GREY_COLORS[10]}; padding: 0 8px 7px\">` +\n `<span style=\"font-size: ${HEATMAP_CONSTANTS.HEADER_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[60]}\">{point.tooltipHeaderLabel}</span></div>` +\n `<div style=\"font-size: ${HEATMAP_CONSTANTS.TOOLTIP_FONT_SIZE}; color: ${ChartColors.GREY_COLORS[100]}; margin: 6px 8px 0 8px;\">` +\n `<span style=\"color:{point.color}\">●</span> {series.name}: <b>{point.value}{point.unit}</b></div>`,\n },\n xAxis: {\n lineWidth: 1,\n tickWidth: 0,\n visible: true,\n },\n yAxis: {\n lineWidth: 0,\n labels: { step: 3 },\n reversed: true,\n visible: true,\n },\n };\n return super.build(mergeDeep(defaultHeatmapOptions, options), locale);\n }\n\n static configureHeatmap(\n categoriesX: string[],\n categoriesY: string[],\n series: SeriesOptionsType[],\n options: Options,\n color: ChartColor,\n leastLabel?: string,\n mostLabel?: string,\n labelDateFormat?: string\n ): void {\n super.configure(series, options, color, labelDateFormat);\n\n if (categoriesX?.length) {\n (options.xAxis as XAxisOptions).categories = categoriesX;\n }\n if (categoriesY?.length) {\n (options.yAxis as YAxisOptions).categories = categoriesY;\n }\n\n const data = ((series[0] as SeriesHeatmapOptions).data ?? []) as PointOptionsObject[];\n const maxValue = data.reduce((max, point) => Math.max(max, point.value ?? 0), 0) || HEATMAP_CONSTANTS.DEFAULT_MAX_VALUE;\n const labelsEnabled = !!(leastLabel && mostLabel);\n\n // `tickAmount` spreads ticks evenly between min and max.\n options.colorAxis = {\n ...(options.colorAxis ?? {}),\n visible: labelsEnabled,\n min: HEATMAP_CONSTANTS.MIN_VALUE,\n max: maxValue,\n tickAmount: HEATMAP_CONSTANTS.DEFAULT_TICK_AMOUNT,\n maxColor: ChartColors.getChartColors(color)[100],\n };\n\n if (labelsEnabled) {\n options.colorAxis.labels = {\n ...((options.colorAxis as ColorAxisOptions)?.labels ?? {}),\n formatter: createColorAxisFormatter(leastLabel, mostLabel),\n };\n }\n }\n}\n\nfunction createColorAxisFormatter(leastLabel: string, mostLabel: string): AxisLabelsFormatterCallbackFunction {\n return function () {\n if (this.value === this.axis.min) return leastLabel;\n if (this.value === this.axis.max) return mostLabel;\n return '';\n };\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { SeriesHeatmapOptions } from 'highcharts';\nimport { mapChart } from 'highcharts/highmaps';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartHeatmapOptions } from './chart-heatmap-options.model';\n\ntype LegendLabels = { least: string; most: string };\n\n@Component({\n selector: 'ap-chart-heatmap',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartHeatmapComponent extends AbstractChartComponent {\n readonly categoriesX = input<string[]>([]);\n readonly categoriesY = input<string[]>([]);\n readonly series = input<SeriesHeatmapOptions[]>([]);\n readonly legendLabels = input<LegendLabels>();\n\n protected initChart(): void {\n const labels = this.legendLabels();\n const options = ChartHeatmapOptions.build(this.chartOptions(), this.locale());\n ChartHeatmapOptions.configureHeatmap(\n this.categoriesX(),\n this.categoriesY(),\n this.series(),\n options,\n this.color(),\n labels?.least,\n labels?.most,\n this.labelDateFormat()\n );\n this.chart = mapChart(this.hostElement, options);\n }\n}\n","import { Options } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nexport class ChartMixedOptions extends ChartOptions {\n static buildMixed(options: Options, singleDayEnabled: boolean, locale: string): Options {\n const defaultOptions: Options = {\n chart: {\n type: 'column',\n },\n legend: {\n symbolHeight: 10,\n },\n plotOptions: {\n series: {\n marker: {\n enabled: singleDayEnabled,\n radius: singleDayEnabled ? 5 : 2,\n symbol: 'circle',\n },\n lineWidth: 4,\n },\n column: {\n stacking: 'normal',\n borderWidth: 0,\n maxPointWidth: 20,\n borderRadius: { radius: '50%', scope: 'stack', where: 'end' },\n },\n },\n xAxis: {\n type: 'datetime',\n },\n };\n return super.build(mergeDeep(defaultOptions, options), locale);\n }\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { Chart, SeriesOptionsType, SeriesSplineOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartMixedOptions } from './chart-mixed-options.model';\n\n@Component({\n selector: 'ap-chart-mixed',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartMixedComponent extends AbstractChartComponent {\n readonly series = input<SeriesOptionsType[]>([]);\n\n protected initChart(): void {\n const series = this.series();\n const splineSeries = series.find(serie => serie.type === 'spline') as SeriesSplineOptions | undefined;\n const singleDayEnabled = splineSeries?.data?.length === 1;\n const options = ChartMixedOptions.buildMixed(this.chartOptions(), singleDayEnabled, this.locale());\n ChartMixedOptions.configure(series, options, this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n }\n}\n","import { round } from 'es-toolkit';\nimport { numberFormat, Options, SeriesPieOptions } from 'highcharts';\nimport { ChartColors } from '../chart-colors';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nconst NAME_MAX_LENGTH = 30;\n// RTL scripts (Hebrew, Arabic, …).\nconst RIGHT_TO_LEFT_CHARACTERS =\n /[\\p{Script=Arabic}\\p{Script=Hebrew}\\p{Script=Syriac}\\p{Script=Thaana}\\p{Script=Nko}\\p{Script=Samaritan}\\p{Script=Mandaic}]/u;\nconst RIGHT_TO_LEFT_EMBEDDING_CHARACTER = '';\n\nexport class ChartPieOptions extends ChartOptions {\n static buildPie(options: Options, innerLabels: boolean, metricFormat: 'percentage' | 'value', locale: string): Options {\n const defaultPieOptions: Options = {\n chart: {\n type: 'pie',\n plotBackgroundColor: undefined,\n plotBorderWidth: undefined,\n plotShadow: false,\n },\n plotOptions: {\n pie: {\n dataLabels: {\n distance: innerLabels ? -40 : 30,\n useHTML: true,\n },\n innerSize: '50%',\n },\n series: {\n allowPointSelect: !innerLabels,\n dataLabels: innerLabels ? buildInnerLabels(metricFormat) : buildOuterLabels(metricFormat),\n showInLegend: innerLabels,\n },\n },\n tooltip: {\n outside: true,\n },\n legend: innerLabels ? { symbolHeight: 10, enabled: true } : {},\n };\n return super.build(mergeDeep(defaultPieOptions, options), locale);\n }\n\n static configurePie(\n series: SeriesPieOptions[],\n options: Options,\n colors: string[],\n labelDateFormat: string,\n innerLabels: boolean,\n mouseEventEnabled = true\n ): void {\n super.configure(series, options, undefined, labelDateFormat);\n if (innerLabels && options.legend) {\n options.legend.enabled = true;\n }\n if (!series?.[0]) {\n return;\n }\n options.colors = colors;\n // Otherwise we rely on Highcharts' default `states.inactive.opacity` to fade non-hovered slices.\n if (!mouseEventEnabled) {\n options.plotOptions ??= {};\n options.plotOptions.pie ??= {};\n options.plotOptions.pie.enableMouseTracking = false;\n }\n }\n}\n\nfunction buildInnerLabels(metricFormat: 'percentage' | 'value') {\n return {\n format: metricFormat === 'percentage' ? '{point.percentage:.1f}%' : '{point.y}',\n style: {\n fontSize: '16px',\n color: 'white',\n textOutline: '0',\n },\n };\n}\n\nfunction buildOuterLabels(metricFormat: 'percentage' | 'value') {\n return {\n formatter(this: { name: string; percentage?: number; y?: number | null }): string {\n const truncatedName = this.name.length > NAME_MAX_LENGTH ? this.name.substring(0, NAME_MAX_LENGTH) + '...' : this.name;\n const displayValue =\n metricFormat === 'percentage' ? numberFormat(round(this.percentage ?? 0, 1), -1) + '%' : numberFormat(this.y ?? 0, -1);\n const prefix = RIGHT_TO_LEFT_CHARACTERS.test(this.name.charAt(0)) ? RIGHT_TO_LEFT_EMBEDDING_CHARACTER : '';\n return prefix + truncatedName + ': ' + displayValue;\n },\n style: {\n fontSize: '12px',\n color: ChartColors.GREY_COLORS[60],\n },\n };\n}\n","import { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { Chart, SeriesPieOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartColors } from '../chart-colors';\nimport { ChartPieOptions } from './chart-pie-options.model';\n\n@Component({\n selector: 'ap-chart-pie',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartPieComponent extends AbstractChartComponent {\n readonly innerLabels = input(false);\n readonly mouseEventEnabled = input(true);\n readonly series = input<SeriesPieOptions[]>([]);\n readonly colors = input<string[]>();\n readonly metricFormat = input<'percentage' | 'value'>('percentage');\n\n protected initChart(): void {\n const series = this.series();\n const innerLabels = this.innerLabels();\n const dataAvailable = !!series[0]?.data?.length;\n const options = ChartPieOptions.buildPie(this.chartOptions(), innerLabels, this.metricFormat(), this.locale());\n\n const effectiveSeries: SeriesPieOptions[] = dataAvailable\n ? series\n : [\n {\n type: 'pie',\n data: [{ y: 1, dataLabels: { enabled: false } }],\n enableMouseTracking: false,\n },\n ];\n\n const effectiveColors = !dataAvailable\n ? [ChartColors.GREY_COLORS[10]]\n : (this.colors() ?? ChartColors.getColors(series[0]?.data?.length ?? 0, this.color()));\n\n ChartPieOptions.configurePie(\n effectiveSeries,\n options,\n effectiveColors,\n this.labelDateFormat(),\n innerLabels,\n this.mouseEventEnabled()\n );\n this.chart = new Chart(this.hostElement, options);\n }\n}\n","import { Options } from 'highcharts';\nimport { ChartOptions, mergeDeep } from '../chart-options';\n\nexport class ChartSplineOptions extends ChartOptions {\n static buildSpline(options: Options, singleDayEnabled: boolean, locale: string): Options {\n const defaultSplineOptions: Options = {\n chart: {\n type: 'spline',\n },\n plotOptions: {\n series: {\n marker: {\n enabled: singleDayEnabled,\n radius: singleDayEnabled ? 5 : 2,\n symbol: 'circle',\n },\n lineWidth: 4\n },\n },\n xAxis: {\n type: 'datetime',\n },\n };\n return super.build(mergeDeep(defaultSplineOptions, options), locale);\n }\n}\n","import { ChangeDetectionStrategy, Component, input, output } from '@angular/core';\nimport { Chart, SeriesSplineOptions } from 'highcharts';\nimport { AbstractChartComponent } from '../abstract-chart.component';\nimport { ChartSplineOptions } from './chart-spline-options.model';\n\n@Component({\n selector: 'ap-chart-spline',\n template: '',\n host: { style: 'display: block' },\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ChartSplineComponent extends AbstractChartComponent {\n readonly series = input<SeriesSplineOptions[]>([]);\n\n readonly chartInitialized = output<Chart>();\n\n protected initChart(): void {\n const series = this.series();\n const singleDayEnabled = series[0]?.data?.length === 1;\n const options = ChartSplineOptions.buildSpline(this.chartOptions(), singleDayEnabled, this.locale());\n ChartSplineOptions.configure(series, options, this.color(), this.labelDateFormat());\n this.chart = new Chart(this.hostElement, options);\n this.chartInitialized.emit(this.chart);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nex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AA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;4FAIH,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBANhC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,iBAAiB;AAC3B,oBAAA,QAAQ,EAAE,EAAE;AACZ,oBAAA,IAAI,EAAE,EAAE,KAAK,EAAE,gBAAgB,EAAE;oBACjC,eAAe,EAAE,uBAAuB,CAAC,MAAM;AAClD,iBAAA;;;ACVD;;AAEG;;;;"}
|
package/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _angular_core from '@angular/core';
|
|
2
2
|
import { Signal } from '@angular/core';
|
|
3
|
-
import
|
|
3
|
+
import { Options, Chart, SeriesBarOptions, SeriesColumnOptions, SeriesHeatmapOptions, SeriesOptionsType, SeriesPieOptions, SeriesSplineOptions } from 'highcharts';
|
|
4
4
|
|
|
5
5
|
declare enum ChartColor {
|
|
6
6
|
Grey = 0,
|
|
@@ -68,8 +68,31 @@ declare class ChartColors {
|
|
|
68
68
|
};
|
|
69
69
|
static readonly RED_COLORS: {
|
|
70
70
|
'80': string;
|
|
71
|
+
'100': string;
|
|
71
72
|
'150': string;
|
|
72
73
|
};
|
|
74
|
+
/**
|
|
75
|
+
* Categorical data palette — 10 distinct hues used to tell apart networks, profiles, or metrics in the same chart.
|
|
76
|
+
* Order is fixed and assigned by position (1st category → DATA_COLORS[0]).
|
|
77
|
+
* For more than 10 categories the palette wraps; the legend is the source of truth.
|
|
78
|
+
*/
|
|
79
|
+
static readonly DATA_COLORS: string[];
|
|
80
|
+
/**
|
|
81
|
+
* Sentiment palette — fixed mapping from sentiment to brand colors.
|
|
82
|
+
* Used by sentiment widgets only; not part of the categorical data palette.
|
|
83
|
+
*/
|
|
84
|
+
static readonly SENTIMENT_COLORS: {
|
|
85
|
+
positive: string;
|
|
86
|
+
neutral: string;
|
|
87
|
+
negative: string;
|
|
88
|
+
};
|
|
89
|
+
/**
|
|
90
|
+
* Heatmap / world-map palette — single shade (data-navy / data-marine) at 5 fixed opacity levels.
|
|
91
|
+
* Listed in ascending intensity (20% → 100%).
|
|
92
|
+
*/
|
|
93
|
+
static readonly HEATMAP_BASE_RGB: readonly [number, number, number];
|
|
94
|
+
static readonly HEATMAP_OPACITIES: readonly number[];
|
|
95
|
+
static readonly HEATMAP_COLORS: readonly string[];
|
|
73
96
|
static readonly SOFT_RED_COLORS: {
|
|
74
97
|
100: string;
|
|
75
98
|
85: string;
|
|
@@ -82,12 +105,22 @@ declare class ChartColors {
|
|
|
82
105
|
static getChartColors(color: ChartColor | undefined): {
|
|
83
106
|
[shade: string]: string;
|
|
84
107
|
};
|
|
108
|
+
/**
|
|
109
|
+
* Returns the categorical data color at the given 0-based position.
|
|
110
|
+
* Wraps modulo `DATA_COLORS.length` (10) so position 10 reuses position 0.
|
|
111
|
+
*/
|
|
112
|
+
static getDataColor(position: number): string;
|
|
113
|
+
/**
|
|
114
|
+
* Returns the first `count` data colors from the categorical palette.
|
|
115
|
+
* Wraps after 10 positions.
|
|
116
|
+
*/
|
|
117
|
+
static getDataColors(count: number): string[];
|
|
85
118
|
static getColors(seriesCount: number, color: ChartColor | undefined): string[];
|
|
86
119
|
}
|
|
87
120
|
|
|
88
121
|
declare abstract class AbstractChartComponent {
|
|
89
122
|
private readonly destroyRef;
|
|
90
|
-
/** Highcharts renders into the
|
|
123
|
+
/** Highcharts renders into the host element directly. */
|
|
91
124
|
protected readonly hostElement: HTMLElement;
|
|
92
125
|
readonly chartOptions: _angular_core.InputSignal<Options>;
|
|
93
126
|
readonly color: _angular_core.InputSignal<ChartColor>;
|
|
@@ -96,7 +129,7 @@ declare abstract class AbstractChartComponent {
|
|
|
96
129
|
protected chart?: Chart;
|
|
97
130
|
private readonly viewReady;
|
|
98
131
|
private resizeObserver?;
|
|
99
|
-
/**
|
|
132
|
+
/** Subclasses expose their typed series input so the base can observe it. */
|
|
100
133
|
protected abstract readonly series: Signal<readonly unknown[]>;
|
|
101
134
|
constructor();
|
|
102
135
|
protected abstract initChart(): void;
|
|
@@ -146,27 +179,13 @@ declare class ChartMixedComponent extends AbstractChartComponent {
|
|
|
146
179
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChartMixedComponent, "ap-chart-mixed", never, { "series": { "alias": "series"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
147
180
|
}
|
|
148
181
|
|
|
149
|
-
interface SeriesRoundedColumnOptions extends SeriesColumnOptions {
|
|
150
|
-
borderRadiusBottomLeft?: number | number[];
|
|
151
|
-
borderRadiusBottomRight?: number | number[];
|
|
152
|
-
borderRadiusTopLeft?: number | number[];
|
|
153
|
-
borderRadiusTopRight?: number | number[];
|
|
154
|
-
type: 'column';
|
|
155
|
-
}
|
|
156
|
-
|
|
157
182
|
declare class ChartOptions {
|
|
158
183
|
static readonly DEFAULT_DATE_FORMAT = "%A, %b %e, %Y";
|
|
159
184
|
static readonly DEFAULT_OPTIONS: Options;
|
|
160
185
|
static build(options: Options, locale: string): Options;
|
|
161
186
|
static configure(series: SeriesOptionsType[], options: Options, color: ChartColor | undefined, labelDateFormat?: string): void;
|
|
162
|
-
static redrawWithHighestEdgesRounded(chart: Chart): void;
|
|
163
|
-
static roundHighestSerie(series: Series[], serie: SeriesRoundedColumnOptions, serieIndex: number): void;
|
|
164
187
|
}
|
|
165
|
-
/**
|
|
166
|
-
* Deep-merges `source` onto a clone of `target` without mutating either, with one deliberate
|
|
167
|
-
* deviation from `es-toolkit`'s `toMerged`: arrays are treated as opaque values (replaced wholesale)
|
|
168
|
-
* rather than element-merged, which matches how Highcharts options are intended to be overridden.
|
|
169
|
-
*/
|
|
188
|
+
/** Deep-merge clone (immutable). Arrays are replaced wholesale, not element-merged like `es-toolkit`'s `toMerged`. */
|
|
170
189
|
declare function mergeDeep(target: any, source: any): any;
|
|
171
190
|
|
|
172
191
|
declare class ChartPieComponent extends AbstractChartComponent {
|
|
@@ -188,6 +207,4 @@ declare class ChartSplineComponent extends AbstractChartComponent {
|
|
|
188
207
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChartSplineComponent, "ap-chart-spline", never, { "series": { "alias": "series"; "required": false; "isSignal": true; }; }, { "chartInitialized": "chartInitialized"; }, never, never, true, never>;
|
|
189
208
|
}
|
|
190
209
|
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
export { AbstractChartComponent, ChartBarComponent, ChartColor, ChartColors, ChartColumnComponent, ChartHeatmapComponent, ChartMixedComponent, ChartOptions, ChartPieComponent, ChartSplineComponent, borderRadiusPlugin, mergeDeep };
|
|
210
|
+
export { AbstractChartComponent, ChartBarComponent, ChartColor, ChartColors, ChartColumnComponent, ChartHeatmapComponent, ChartMixedComponent, ChartOptions, ChartPieComponent, ChartSplineComponent, mergeDeep };
|
package/package.json
CHANGED
|
Binary file
|