@acorex/charts 19.14.1 → 19.14.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bar-chart/lib/bar-chart.component.d.ts +5 -5
- package/bar-chart/lib/bar-chart.config.d.ts +5 -5
- package/bar-chart/lib/bar-chart.type.d.ts +7 -6
- package/donut-chart/lib/donut-chart.component.d.ts +9 -9
- package/donut-chart/lib/donut-chart.config.d.ts +5 -5
- package/donut-chart/lib/donut-chart.type.d.ts +8 -5
- package/fesm2022/acorex-charts-bar-chart.mjs +30 -16
- package/fesm2022/acorex-charts-bar-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-chart-tooltip.mjs +3 -3
- package/fesm2022/acorex-charts-donut-chart.mjs +52 -62
- package/fesm2022/acorex-charts-donut-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-gauge-chart.mjs +4 -4
- package/fesm2022/acorex-charts-gauge-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-hierarchy-chart.mjs +56 -6
- package/fesm2022/acorex-charts-hierarchy-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-line-chart.mjs +41 -25
- package/fesm2022/acorex-charts-line-chart.mjs.map +1 -1
- package/gauge-chart/lib/gauge-chart.component.d.ts +3 -3
- package/gauge-chart/lib/gauge-chart.config.d.ts +5 -5
- package/gauge-chart/lib/gauge-chart.type.d.ts +5 -4
- package/hierarchy-chart/lib/hierarchy-chart.component.d.ts +6 -2
- package/hierarchy-chart/lib/hierarchy-chart.type.d.ts +2 -2
- package/line-chart/lib/line-chart.component.d.ts +3 -3
- package/line-chart/lib/line-chart.type.d.ts +4 -2
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import { NXComponent } from '@acorex/cdk/common';
|
|
1
2
|
import { AXChartTooltipData } from '@acorex/charts/chart-tooltip';
|
|
2
|
-
import { NXComponent } from '@acorex/components/common';
|
|
3
3
|
import { OnDestroy } from '@angular/core';
|
|
4
|
-
import { AXBarChartClickEvent,
|
|
4
|
+
import { AXBarChartClickEvent, AXBarChartData, AXBarChartOption } from './bar-chart.type';
|
|
5
5
|
import * as i0 from "@angular/core";
|
|
6
6
|
export declare const AXBarChartColors: {
|
|
7
7
|
defaultColors: string[];
|
|
@@ -13,9 +13,9 @@ export declare const AXBarChartColors: {
|
|
|
13
13
|
*/
|
|
14
14
|
export declare class AXBarChartComponent extends NXComponent implements OnDestroy {
|
|
15
15
|
/** Chart data input */
|
|
16
|
-
data: import("@angular/core").InputSignal<
|
|
16
|
+
data: import("@angular/core").InputSignal<AXBarChartData[]>;
|
|
17
17
|
/** Chart options input */
|
|
18
|
-
options: import("@angular/core").InputSignal<
|
|
18
|
+
options: import("@angular/core").InputSignal<AXBarChartOption>;
|
|
19
19
|
/** Emitted when a bar is clicked */
|
|
20
20
|
barClick: import("@angular/core").OutputEmitterRef<AXBarChartClickEvent>;
|
|
21
21
|
private readonly chartContainerEl;
|
|
@@ -55,7 +55,7 @@ export declare class AXBarChartComponent extends NXComponent implements OnDestro
|
|
|
55
55
|
barWidth?: number;
|
|
56
56
|
cornerRadius?: number;
|
|
57
57
|
animationDuration?: number;
|
|
58
|
-
animationEasing?: "
|
|
58
|
+
animationEasing?: import("@acorex/cdk/common").AXAnimationEasing;
|
|
59
59
|
}>;
|
|
60
60
|
constructor();
|
|
61
61
|
ngOnDestroy(): void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { InjectionToken } from '@angular/core';
|
|
2
|
-
import {
|
|
3
|
-
export declare const AXBarChartDefaultConfig:
|
|
4
|
-
export declare const AX_BAR_CHART_CONFIG: InjectionToken<
|
|
5
|
-
export type PartialBarChartConfig = Partial<
|
|
6
|
-
export declare function barChartConfig(config?: PartialBarChartConfig):
|
|
2
|
+
import { AXBarChartOption } from './bar-chart.type';
|
|
3
|
+
export declare const AXBarChartDefaultConfig: AXBarChartOption;
|
|
4
|
+
export declare const AX_BAR_CHART_CONFIG: InjectionToken<AXBarChartOption>;
|
|
5
|
+
export type PartialBarChartConfig = Partial<AXBarChartOption>;
|
|
6
|
+
export declare function barChartConfig(config?: PartialBarChartConfig): AXBarChartOption;
|
|
@@ -1,18 +1,19 @@
|
|
|
1
|
-
import { NXNativeEvent } from '@acorex/
|
|
1
|
+
import { AXAnimationEasing, NXNativeEvent } from '@acorex/cdk/common';
|
|
2
2
|
/**
|
|
3
3
|
* Bar chart data item interface
|
|
4
4
|
*/
|
|
5
|
-
export interface
|
|
5
|
+
export interface AXBarChartData {
|
|
6
6
|
id: string;
|
|
7
7
|
label: string;
|
|
8
8
|
value: number;
|
|
9
|
+
tooltipLabel?: string;
|
|
9
10
|
color?: string;
|
|
10
11
|
}
|
|
11
12
|
/**
|
|
12
13
|
* Bar chart click event interface
|
|
13
14
|
*/
|
|
14
15
|
export interface AXBarChartClickEvent {
|
|
15
|
-
item:
|
|
16
|
+
item: AXBarChartData;
|
|
16
17
|
event: NXNativeEvent;
|
|
17
18
|
}
|
|
18
19
|
/**
|
|
@@ -30,7 +31,7 @@ export interface AXBarChartClickEvent {
|
|
|
30
31
|
* - `--ax-comp-bar-chart-bg-color`: Background color for the chart.
|
|
31
32
|
* Default: `--ax-sys-color-lightest-surface`
|
|
32
33
|
*/
|
|
33
|
-
export interface
|
|
34
|
+
export interface AXBarChartOption {
|
|
34
35
|
width?: number;
|
|
35
36
|
height?: number;
|
|
36
37
|
showXAxis?: boolean;
|
|
@@ -43,10 +44,10 @@ export interface AXPBarChartOption {
|
|
|
43
44
|
barWidth?: number;
|
|
44
45
|
cornerRadius?: number;
|
|
45
46
|
animationDuration?: number;
|
|
46
|
-
animationEasing?:
|
|
47
|
+
animationEasing?: AXAnimationEasing;
|
|
47
48
|
}
|
|
48
49
|
/**
|
|
49
50
|
* Bar chart data type returned by getValue()
|
|
50
51
|
* Represents an array of bar chart data items
|
|
51
52
|
*/
|
|
52
|
-
export type
|
|
53
|
+
export type AXBarChartValue = AXBarChartData[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { AXChartTooltipData } from '@acorex/charts/chart-tooltip';
|
|
2
2
|
import { OnDestroy } from '@angular/core';
|
|
3
|
-
import {
|
|
3
|
+
import { AXDonutChartData, AXDonutChartOption, AXDonutChartValue } from './donut-chart.type';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export declare const AXDonutChartColors: {
|
|
6
6
|
defaultColors: string[];
|
|
@@ -13,15 +13,15 @@ export declare const AXDonutChartColors: {
|
|
|
13
13
|
export declare class AXDonutChartComponent implements OnDestroy {
|
|
14
14
|
private cdr;
|
|
15
15
|
/** Chart data input */
|
|
16
|
-
data: import("@angular/core").InputSignal<
|
|
16
|
+
data: import("@angular/core").InputSignal<AXDonutChartValue>;
|
|
17
17
|
/** Chart options input */
|
|
18
|
-
options: import("@angular/core").InputSignal<
|
|
18
|
+
options: import("@angular/core").InputSignal<AXDonutChartOption>;
|
|
19
19
|
/** Emitted when a segment is clicked */
|
|
20
|
-
segmentClick: import("@angular/core").OutputEmitterRef<
|
|
20
|
+
segmentClick: import("@angular/core").OutputEmitterRef<AXDonutChartData>;
|
|
21
21
|
/** Emitted when a segment has mouse hover
|
|
22
22
|
* Can be used by external elements to highlight this segment
|
|
23
23
|
*/
|
|
24
|
-
segmentHover: import("@angular/core").OutputEmitterRef<
|
|
24
|
+
segmentHover: import("@angular/core").OutputEmitterRef<AXDonutChartData>;
|
|
25
25
|
private readonly chartContainerEl;
|
|
26
26
|
protected d3: typeof import('d3');
|
|
27
27
|
private svg;
|
|
@@ -47,9 +47,9 @@ export declare class AXDonutChartComponent implements OnDestroy {
|
|
|
47
47
|
donutWidth?: number;
|
|
48
48
|
cornerRadius?: number;
|
|
49
49
|
animationDuration?: number;
|
|
50
|
-
animationEasing?: "
|
|
50
|
+
animationEasing?: import("@acorex/cdk/common").AXAnimationEasing;
|
|
51
51
|
}>;
|
|
52
|
-
protected chartDataArray: import("@angular/core").Signal<
|
|
52
|
+
protected chartDataArray: import("@angular/core").Signal<AXDonutChartData[]>;
|
|
53
53
|
protected getColor(index: number): string;
|
|
54
54
|
protected isSegmentHidden(id: string): boolean;
|
|
55
55
|
constructor();
|
|
@@ -69,7 +69,7 @@ export declare class AXDonutChartComponent implements OnDestroy {
|
|
|
69
69
|
* Loads D3.js dynamically
|
|
70
70
|
*/
|
|
71
71
|
protected loadD3(): Promise<void>;
|
|
72
|
-
protected onSegmentClick(item:
|
|
72
|
+
protected onSegmentClick(item: AXDonutChartData): void;
|
|
73
73
|
/**
|
|
74
74
|
* Creates the donut chart
|
|
75
75
|
*/
|
|
@@ -113,7 +113,7 @@ export declare class AXDonutChartComponent implements OnDestroy {
|
|
|
113
113
|
/**
|
|
114
114
|
* Handle hover effects on a segment
|
|
115
115
|
*/
|
|
116
|
-
private
|
|
116
|
+
private handleSliceHover;
|
|
117
117
|
/**
|
|
118
118
|
* Handles mouse leave from segments
|
|
119
119
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { InjectionToken } from '@angular/core';
|
|
2
|
-
import {
|
|
3
|
-
export declare const AXDonutChartDefaultConfig:
|
|
4
|
-
export declare const AX_DONUT_CHART_CONFIG: InjectionToken<
|
|
5
|
-
export type PartialDonutChartConfig = Partial<
|
|
6
|
-
export declare function donutChartConfig(config?: PartialDonutChartConfig):
|
|
2
|
+
import { AXDonutChartOption } from './donut-chart.type';
|
|
3
|
+
export declare const AXDonutChartDefaultConfig: AXDonutChartOption;
|
|
4
|
+
export declare const AX_DONUT_CHART_CONFIG: InjectionToken<AXDonutChartOption>;
|
|
5
|
+
export type PartialDonutChartConfig = Partial<AXDonutChartOption>;
|
|
6
|
+
export declare function donutChartConfig(config?: PartialDonutChartConfig): AXDonutChartOption;
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
+
import { AXAnimationEasing } from '@acorex/cdk/common';
|
|
1
2
|
/**
|
|
2
3
|
* Represents a single segment in the donut chart
|
|
3
4
|
*/
|
|
4
|
-
export interface
|
|
5
|
+
export interface AXDonutChartData {
|
|
5
6
|
id: string;
|
|
6
|
-
name: string;
|
|
7
7
|
value: number;
|
|
8
|
+
color?: string;
|
|
9
|
+
tooltipLabel?: string;
|
|
10
|
+
label?: string;
|
|
8
11
|
}
|
|
9
12
|
/**
|
|
10
13
|
* Configuration options for the donut chart
|
|
@@ -31,7 +34,7 @@ export interface AXPDonutChartData {
|
|
|
31
34
|
* }
|
|
32
35
|
* ```
|
|
33
36
|
*/
|
|
34
|
-
export interface
|
|
37
|
+
export interface AXDonutChartOption {
|
|
35
38
|
/**
|
|
36
39
|
* Width of the chart in pixels
|
|
37
40
|
* If not provided, will use container width
|
|
@@ -73,10 +76,10 @@ export interface AXPDonutChartOption {
|
|
|
73
76
|
* Type of easing function for animations
|
|
74
77
|
* Default: 'cubic-out'
|
|
75
78
|
*/
|
|
76
|
-
animationEasing?:
|
|
79
|
+
animationEasing?: AXAnimationEasing;
|
|
77
80
|
}
|
|
78
81
|
/**
|
|
79
82
|
* Data structure provided to the chart component
|
|
80
83
|
* Can be an array of AXPDonutChartData directly
|
|
81
84
|
*/
|
|
82
|
-
export type
|
|
85
|
+
export type AXDonutChartValue = AXDonutChartData[];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { NXComponent } from '@acorex/cdk/common';
|
|
1
2
|
import { AXChartTooltipComponent } from '@acorex/charts/chart-tooltip';
|
|
2
|
-
import { NXComponent } from '@acorex/components/common';
|
|
3
3
|
import { CommonModule } from '@angular/common';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
5
|
import { InjectionToken, inject, input, output, viewChild, signal, computed, afterNextRender, effect, ChangeDetectionStrategy, ViewEncapsulation, Component } from '@angular/core';
|
|
@@ -500,7 +500,7 @@ class AXBarChartComponent extends NXComponent {
|
|
|
500
500
|
const total = this.data().reduce((sum, item) => sum + item.value, 0);
|
|
501
501
|
const percentage = total > 0 ? ((datum.value / total) * 100).toFixed(1) : '0';
|
|
502
502
|
this._tooltipData.set({
|
|
503
|
-
title: datum.label,
|
|
503
|
+
title: datum.tooltipLabel || datum.label,
|
|
504
504
|
value: datum.value.toString(),
|
|
505
505
|
percentage: `${percentage}%`,
|
|
506
506
|
color: color,
|
|
@@ -543,38 +543,52 @@ class AXBarChartComponent extends NXComponent {
|
|
|
543
543
|
* Shows a message when no data is available
|
|
544
544
|
*/
|
|
545
545
|
showNoDataMessage(containerElement) {
|
|
546
|
+
// Clear existing contents first
|
|
547
|
+
this.d3.select(containerElement).selectAll('*').remove();
|
|
546
548
|
const messageContainer = this.d3
|
|
547
549
|
.select(containerElement)
|
|
548
550
|
.append('div')
|
|
549
551
|
.attr('class', 'ax-bar-chart-no-data-message')
|
|
550
|
-
.style('
|
|
551
|
-
.style('
|
|
552
|
-
.style('
|
|
553
|
-
.style('
|
|
554
|
-
.style('align-items', 'center')
|
|
555
|
-
.style('justify-content', 'center')
|
|
552
|
+
.style('position', 'absolute')
|
|
553
|
+
.style('left', '50%')
|
|
554
|
+
.style('top', '50%')
|
|
555
|
+
.style('transform', 'translate(-50%, -50%)')
|
|
556
556
|
.style('text-align', 'center')
|
|
557
|
-
.style('background-color', 'rgb(var(--ax-comp-bar-chart-bg-color))')
|
|
557
|
+
.style('background-color', 'rgb(var(--ax-comp-bar-chart-bg-color))')
|
|
558
|
+
.style('padding', '1.5rem')
|
|
559
|
+
.style('border-radius', '0.5rem')
|
|
560
|
+
.style('box-shadow', '0 2px 12px rgba(0, 0, 0, 0.08)')
|
|
561
|
+
.style('width', '80%')
|
|
562
|
+
.style('max-width', '300px');
|
|
558
563
|
// Add an icon
|
|
559
564
|
messageContainer
|
|
560
565
|
.append('div')
|
|
561
566
|
.attr('class', 'ax-bar-chart-no-data-icon')
|
|
562
|
-
.style('
|
|
563
|
-
.
|
|
567
|
+
.style('opacity', '0.6')
|
|
568
|
+
.style('margin-bottom', '0.75rem')
|
|
569
|
+
.html('<i class="fa-light fa-chart-column fa-2x"></i>');
|
|
564
570
|
// Add text message
|
|
565
571
|
messageContainer
|
|
566
572
|
.append('div')
|
|
567
573
|
.attr('class', 'ax-bar-chart-no-data-text')
|
|
568
|
-
.style('font-size', '
|
|
574
|
+
.style('font-size', '1rem')
|
|
569
575
|
.style('font-weight', '600')
|
|
576
|
+
.style('margin-bottom', '0.5rem')
|
|
570
577
|
.text('No data available');
|
|
578
|
+
// Add help text
|
|
579
|
+
messageContainer
|
|
580
|
+
.append('div')
|
|
581
|
+
.attr('class', 'ax-bar-chart-no-data-help')
|
|
582
|
+
.style('font-size', '0.8rem')
|
|
583
|
+
.style('opacity', '0.6')
|
|
584
|
+
.text('Please provide data to display the chart');
|
|
571
585
|
}
|
|
572
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
573
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.
|
|
586
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: AXBarChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
587
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "19.2.11", type: AXBarChartComponent, isStandalone: true, selector: "ax-bar-chart", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { barClick: "barClick" }, viewQueries: [{ propertyName: "chartContainerEl", first: true, predicate: ["chartContainer"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-bar-chart\" #chartContainer>\n <!-- Shared tooltip component -->\n <ax-chart-tooltip\n [visible]=\"tooltipVisible()\"\n [position]=\"tooltipPosition()\"\n [data]=\"tooltipData()\"\n [showPercentage]=\"true\"\n ></ax-chart-tooltip>\n</div>\n", styles: ["ax-bar-chart{display:block;width:100%;height:100%;min-height:200px;--ax-comp-bar-chart-axis-label-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-labels-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-data-labels-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-grid-lines-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-bg-color: var(--ax-sys-color-lightest-surface)}ax-bar-chart .ax-bar-chart{width:100%;height:100%;position:relative;display:flex;align-items:center;justify-content:center;border-radius:.5rem;overflow:hidden;color:rgb(var(--ax-sys-color-on-lightest-surface));background-color:rgb(var(--ax-comp-bar-chart-bg-color))}ax-bar-chart .ax-bar-chart svg{width:100%;height:100%;max-width:100%;max-height:100%;overflow:visible}ax-bar-chart .ax-bar-chart-no-data-message{position:absolute;text-align:center;transform:translate(-50%,-50%);background-color:rgb(var(--ax-comp-bar-chart-bg-color));padding:1.5rem;border-radius:.5rem;box-shadow:0 2px 12px #00000014;width:80%;max-width:300px}ax-bar-chart .ax-bar-chart-no-data-message .ax-bar-chart-no-data-icon{opacity:.6;margin-bottom:.75rem}ax-bar-chart .ax-bar-chart-no-data-message .ax-bar-chart-no-data-text{font-size:1rem;font-weight:600;margin-bottom:.5rem}ax-bar-chart .ax-bar-chart-no-data-message .ax-bar-chart-no-data-help{font-size:.8rem;opacity:.6}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: AXChartTooltipComponent, selector: "ax-chart-tooltip", inputs: ["data", "position", "visible", "showPercentage", "style"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
574
588
|
}
|
|
575
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
589
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: AXBarChartComponent, decorators: [{
|
|
576
590
|
type: Component,
|
|
577
|
-
args: [{ selector: 'ax-bar-chart', encapsulation: ViewEncapsulation.None, imports: [CommonModule, AXChartTooltipComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"ax-bar-chart\" #chartContainer>\n <!-- Shared tooltip component -->\n <ax-chart-tooltip\n [visible]=\"tooltipVisible()\"\n [position]=\"tooltipPosition()\"\n [data]=\"tooltipData()\"\n [showPercentage]=\"true\"\n ></ax-chart-tooltip>\n</div>\n", styles: ["ax-bar-chart{display:block;width:100%;height:100%;min-height:200px;--ax-comp-bar-chart-axis-label-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-labels-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-data-labels-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-grid-lines-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-bg-color: var(--ax-sys-color-lightest-surface)}.ax-bar-chart{width:100%;height:100%;position:relative;display:flex;align-items:center;justify-content:center;border-radius:.5rem;overflow:hidden;color:rgb(var(--ax-sys-color-on-lightest-surface));background-color:rgb(var(--ax-comp-bar-chart-bg-color))}.ax-bar-chart svg{width:100%;height:100%;max-width:100%;max-height:100%;overflow:visible}.ax-bar-chart-no-data-message{
|
|
591
|
+
args: [{ selector: 'ax-bar-chart', encapsulation: ViewEncapsulation.None, imports: [CommonModule, AXChartTooltipComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"ax-bar-chart\" #chartContainer>\n <!-- Shared tooltip component -->\n <ax-chart-tooltip\n [visible]=\"tooltipVisible()\"\n [position]=\"tooltipPosition()\"\n [data]=\"tooltipData()\"\n [showPercentage]=\"true\"\n ></ax-chart-tooltip>\n</div>\n", styles: ["ax-bar-chart{display:block;width:100%;height:100%;min-height:200px;--ax-comp-bar-chart-axis-label-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-labels-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-data-labels-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-grid-lines-color: var(--ax-sys-color-on-lightest-surface);--ax-comp-bar-chart-bg-color: var(--ax-sys-color-lightest-surface)}ax-bar-chart .ax-bar-chart{width:100%;height:100%;position:relative;display:flex;align-items:center;justify-content:center;border-radius:.5rem;overflow:hidden;color:rgb(var(--ax-sys-color-on-lightest-surface));background-color:rgb(var(--ax-comp-bar-chart-bg-color))}ax-bar-chart .ax-bar-chart svg{width:100%;height:100%;max-width:100%;max-height:100%;overflow:visible}ax-bar-chart .ax-bar-chart-no-data-message{position:absolute;text-align:center;transform:translate(-50%,-50%);background-color:rgb(var(--ax-comp-bar-chart-bg-color));padding:1.5rem;border-radius:.5rem;box-shadow:0 2px 12px #00000014;width:80%;max-width:300px}ax-bar-chart .ax-bar-chart-no-data-message .ax-bar-chart-no-data-icon{opacity:.6;margin-bottom:.75rem}ax-bar-chart .ax-bar-chart-no-data-message .ax-bar-chart-no-data-text{font-size:1rem;font-weight:600;margin-bottom:.5rem}ax-bar-chart .ax-bar-chart-no-data-message .ax-bar-chart-no-data-help{font-size:.8rem;opacity:.6}\n"] }]
|
|
578
592
|
}], ctorParameters: () => [] });
|
|
579
593
|
|
|
580
594
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-charts-bar-chart.mjs","sources":["../../../../packages/charts/bar-chart/src/lib/bar-chart.config.ts","../../../../packages/charts/bar-chart/src/lib/bar-chart.component.ts","../../../../packages/charts/bar-chart/src/lib/bar-chart.component.html","../../../../packages/charts/bar-chart/src/acorex-charts-bar-chart.ts"],"sourcesContent":["import { AX_GLOBAL_CONFIG } from '@acorex/core/config';\nimport { InjectionToken, inject } from '@angular/core';\nimport { set } from 'lodash-es';\nimport { AXPBarChartOption } from './bar-chart.type';\n\nexport const AXBarChartDefaultConfig: AXPBarChartOption = {\n showXAxis: true,\n showYAxis: true,\n showGrid: true,\n showDataLabels: true,\n showTooltip: true,\n barWidth: 80,\n cornerRadius: 4,\n animationDuration: 800,\n animationEasing: 'cubic-out',\n};\n\nexport const AX_BAR_CHART_CONFIG = new InjectionToken<AXPBarChartOption>('AX_BAR_CHART_CONFIG', {\n providedIn: 'root',\n factory: () => {\n const global = inject(AX_GLOBAL_CONFIG);\n set(global, 'chart.barChart', AXBarChartDefaultConfig);\n return AXBarChartDefaultConfig;\n },\n});\n\nexport type PartialBarChartConfig = Partial<AXPBarChartOption>;\n\nexport function barChartConfig(config: PartialBarChartConfig = {}): AXPBarChartOption {\n const result = {\n ...AXBarChartDefaultConfig,\n ...config,\n };\n return result;\n}\n","import { AXChartTooltipComponent, AXChartTooltipData } from '@acorex/charts/chart-tooltip';\nimport { NXComponent } from '@acorex/components/common';\nimport { CommonModule } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n OnDestroy,\n ViewEncapsulation,\n afterNextRender,\n computed,\n effect,\n inject,\n input,\n output,\n signal,\n viewChild,\n} from '@angular/core';\nimport { AX_BAR_CHART_CONFIG } from './bar-chart.config';\nimport { AXBarChartClickEvent, AXPBarChartData, AXPBarChartOption } from './bar-chart.type';\n\nexport const AXBarChartColors = {\n // Modern color palette suitable for data visualization\n defaultColors: [\n '#4361ee', // Blue\n '#3a0ca3', // Purple\n '#7209b7', // Violet\n '#f72585', // Pink\n '#4cc9f0', // Light Blue\n '#4895ef', // Sky Blue\n '#560bad', // Deep Purple\n '#f15bb5', // Light Pink\n '#00bbf9', // Cyan\n '#00f5d4', // Teal\n ],\n\n // Get a color from the palette by index with wraparound\n getColor: (index: number, customPalette?: string[]): string => {\n const palette = customPalette || AXBarChartColors.defaultColors;\n return palette[index % palette.length];\n },\n};\n\n/**\n * Bar Chart Component\n * Renders data as vertical bars with interactive hover effects and animations\n */\n@Component({\n selector: 'ax-bar-chart',\n templateUrl: './bar-chart.component.html',\n styleUrls: ['./bar-chart.component.scss'],\n encapsulation: ViewEncapsulation.None,\n imports: [CommonModule, AXChartTooltipComponent],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class AXBarChartComponent extends NXComponent implements OnDestroy {\n // Inputs\n /** Chart data input */\n data = input<AXPBarChartData[]>([]);\n\n /** Chart options input */\n options = input<AXPBarChartOption>({});\n\n // Outputs\n /** Emitted when a bar is clicked */\n barClick = output<AXBarChartClickEvent>();\n\n // Chart container reference\n private readonly chartContainerEl = viewChild.required<ElementRef<HTMLDivElement>>('chartContainer');\n\n // D3 reference - loaded asynchronously\n protected d3!: typeof import('d3');\n\n // Chart elements\n private svg!: any;\n private chart!: any;\n private xScale!: any;\n private yScale!: any;\n private xAxis!: any;\n private yAxis!: any;\n\n // Chart dimensions\n private width!: number;\n private height!: number;\n private margin = { top: 20, right: 20, bottom: 30, left: 40 };\n\n // Animation state\n private _initialAnimationComplete = signal(false);\n\n // Tooltip state\n private _tooltipVisible = signal(false);\n private _tooltipPosition = signal({ x: 0, y: 0 });\n private _tooltipData = signal<AXChartTooltipData>({\n title: '',\n value: '0',\n percentage: '0%',\n color: '',\n });\n\n // Signals for component state\n private _initialized = signal(false);\n private _rendered = signal(false);\n\n // Tooltip accessors\n protected tooltipVisible = this._tooltipVisible.asReadonly();\n protected tooltipPosition = this._tooltipPosition.asReadonly();\n protected tooltipData = this._tooltipData.asReadonly();\n\n // Inject configuration\n private configToken = inject(AX_BAR_CHART_CONFIG);\n\n // Configuration with defaults\n protected effectiveOptions = computed(() => {\n return {\n ...this.configToken,\n ...this.options(),\n };\n });\n\n constructor() {\n super();\n // Dynamically load D3 and initialize the chart when the component is ready\n afterNextRender(() => {\n this._initialized.set(true);\n this.loadD3();\n // Create chart after D3 is loaded and container is available\n if (this.d3 && this.chartContainerEl()) {\n this.createChart();\n this._rendered.set(true);\n }\n });\n\n // Watch for changes to redraw the chart\n effect(() => {\n // Access inputs to track them\n this.data();\n this.effectiveOptions();\n\n // Only update if already rendered\n if (this._rendered()) {\n this.updateChart();\n }\n });\n }\n\n ngOnDestroy(): void {\n this.cleanupChart();\n }\n\n /**\n * Loads D3.js dynamically\n */\n protected async loadD3(): Promise<void> {\n try {\n this.d3 = await import('d3');\n // If container is ready, create chart\n if (this._initialized() && this.chartContainerEl()) {\n this.createChart();\n this._rendered.set(true);\n }\n } catch (error) {\n console.error('Failed to load D3.js:', error);\n }\n }\n\n /**\n * Creates the bar chart SVG and renders all elements\n */\n protected createChart(): void {\n if (!this.d3 || !this.chartContainerEl()?.nativeElement) return;\n\n const containerElement = this.chartContainerEl().nativeElement;\n const data = this.data() || [];\n\n // Clear existing chart\n this.d3.select(containerElement).selectAll('svg').remove();\n\n // Early return if no data\n if (!data.length) {\n this.showNoDataMessage(containerElement);\n return;\n }\n\n // Get options and setup dimensions\n const chartOptions = this.effectiveOptions();\n this.setupDimensions(containerElement, chartOptions);\n\n // Create scales and axes\n this.setupScales(data);\n this.createAxes(chartOptions);\n\n // Render the bars\n this.renderBars(data);\n }\n\n /**\n * Updates the chart when inputs change\n */\n protected updateChart(): void {\n this.createChart();\n }\n\n /**\n * Cleans up chart resources\n */\n protected cleanupChart(): void {\n if (this.svg) {\n this.d3?.select(this.chartContainerEl()?.nativeElement).selectAll('svg').remove();\n this.svg = null;\n this.chart = null;\n }\n this._tooltipVisible.set(false);\n }\n\n /**\n * Sets up chart dimensions and creates SVG with responsive attributes\n */\n private setupDimensions(containerElement: HTMLElement, options: AXPBarChartOption): void {\n // Calculate margins based on options\n this.calculateMargins(options);\n\n // Get container dimensions\n const containerWidth = containerElement.clientWidth;\n const containerHeight = containerElement.clientHeight;\n\n // If options specify width and height, use those, otherwise default to container size\n const minDim = Math.min(200, containerWidth, containerHeight); // Ensure reasonable minimum\n\n if (options.width && options.height) {\n // Explicit dimensions provided\n this.width = options.width - this.margin.left - this.margin.right;\n this.height = options.height - this.margin.top - this.margin.bottom;\n } else {\n // Responsive dimensions\n this.width = Math.max(containerWidth, minDim) - this.margin.left - this.margin.right;\n this.height = Math.max(containerHeight, minDim) - this.margin.top - this.margin.bottom;\n }\n\n // Create responsive SVG that scales with its container\n const svg = this.d3\n .select(containerElement)\n .append('svg')\n .attr('width', '100%')\n .attr('height', '100%')\n .attr(\n 'viewBox',\n `0 0 ${this.width + this.margin.left + this.margin.right} ${this.height + this.margin.top + this.margin.bottom}`,\n )\n .attr('preserveAspectRatio', 'xMidYMid meet');\n\n this.svg = svg;\n\n // Create chart group with margins\n this.chart = this.svg.append('g').attr('transform', `translate(${this.margin.left},${this.margin.top})`);\n }\n\n /**\n * Calculates chart margins based on options\n */\n private calculateMargins(options: AXPBarChartOption): void {\n // Start with default margins\n this.margin = {\n top: 20,\n right: 20,\n bottom: 30,\n left: 40,\n };\n\n // Adjust margins if axis labels are present\n if (options.xAxisLabel) {\n const xLabelLength = options.xAxisLabel.length;\n const extraBottomMargin = Math.min(20, Math.max(10, xLabelLength * 0.8));\n this.margin.bottom = Math.max(this.margin.bottom, 30 + extraBottomMargin);\n }\n\n if (options.yAxisLabel) {\n const yLabelLength = options.yAxisLabel.length;\n const extraLeftMargin = Math.min(20, Math.max(10, yLabelLength * 0.8));\n this.margin.left = Math.max(this.margin.left, 40 + extraLeftMargin);\n }\n\n // Ensure minimum margins for axes\n if (options.showXAxis !== false) {\n this.margin.bottom = Math.max(this.margin.bottom, 35);\n }\n\n if (options.showYAxis !== false) {\n this.margin.left = Math.max(this.margin.left, 45);\n }\n }\n\n /**\n * Creates x and y scales for the chart\n */\n private setupScales(data: AXPBarChartData[]): void {\n // Get the bar width percentage (default 80%)\n const barWidthPercent = this.effectiveOptions().barWidth ?? 60 / 100;\n // Calculate padding based on barWidth (inverse relationship)\n const padding = Math.max(0.1, 1 - barWidthPercent);\n\n // Create x scale (band scale for categorical data)\n this.xScale = this.d3\n .scaleBand()\n .domain(data.map((d) => d.label))\n .range([0, this.width])\n .padding(padding);\n\n // Create y scale (linear scale for values)\n this.yScale = this.d3\n .scaleLinear()\n .domain([0, this.d3.max(data, (d) => d.value) || 0])\n .nice()\n .range([this.height, 0]);\n }\n\n /**\n * Creates x and y axes with grid lines\n */\n private createAxes(options: AXPBarChartOption): void {\n // Only create axes if they are enabled in options\n const showXAxis = options.showXAxis !== false;\n const showYAxis = options.showYAxis !== false;\n const showGrid = options.showGrid !== false;\n\n // Create a group for all axes\n const axesGroup = this.chart.append('g').attr('class', 'ax-bar-chart-axes');\n\n if (showXAxis) {\n // Create X axis\n this.xAxis = axesGroup\n .append('g')\n .attr('class', 'ax-bar-chart-axis-x')\n .attr('transform', `translate(0,${this.height})`)\n .call(this.d3.axisBottom(this.xScale));\n\n // Style the axis text\n this.xAxis\n .selectAll('text')\n .style('font-size', '11px')\n .style('font-weight', '400')\n .style('fill', 'rgba(var(--ax-comp-bar-chart-labels-color), 0.7)');\n\n // Style all lines in the x-axis (path, ticks)\n this.xAxis.selectAll('line, path').style('stroke', 'rgb(var(--ax-comp-bar-chart-grid-lines-color))');\n\n // Add X axis label if provided\n if (options.xAxisLabel) {\n const labelY = this.height + this.margin.bottom * 0.65;\n\n axesGroup\n .append('text')\n .attr('class', 'ax-bar-chart-axis-label ax-x-axis-label')\n .attr('text-anchor', 'middle')\n .attr('dominant-baseline', 'middle')\n .attr('x', this.width / 2)\n .attr('y', labelY)\n .style('font-size', '13px')\n .style('font-weight', '500')\n .style('fill', 'rgb(var(--ax-comp-bar-chart-axis-label-color))')\n .text(options.xAxisLabel);\n }\n }\n\n if (showYAxis) {\n // Create Y axis\n this.yAxis = axesGroup.append('g').attr('class', 'ax-bar-chart-axis-y').call(this.d3.axisLeft(this.yScale));\n\n // Style the axis text\n this.yAxis\n .selectAll('text')\n .style('font-size', '11px')\n .style('font-weight', '400')\n .style('fill', 'rgba(var(--ax-comp-bar-chart-labels-color), 0.7)');\n\n // Style all lines in the y-axis (path, ticks)\n this.yAxis.selectAll('line, path').style('stroke', 'rgb(var(--ax-comp-bar-chart-grid-lines-color))');\n\n // Add Y axis label if provided\n if (options.yAxisLabel) {\n const labelX = -this.height / 2;\n const labelY = -this.margin.left * 0.65;\n\n axesGroup\n .append('text')\n .attr('class', 'ax-bar-chart-axis-label ax-y-axis-label')\n .attr('text-anchor', 'middle')\n .attr('dominant-baseline', 'middle')\n .attr('transform', 'rotate(-90)')\n .attr('x', labelX)\n .attr('y', labelY)\n .style('font-size', '13px')\n .style('font-weight', '500')\n .style('fill', 'rgb(var(--ax-comp-bar-chart-axis-label-color))')\n .text(options.yAxisLabel);\n }\n }\n\n if (showGrid) {\n // Add horizontal grid lines\n this.chart\n .append('g')\n .attr('class', 'ax-bar-chart-grid')\n .call(\n this.d3\n .axisLeft(this.yScale)\n .tickSize(-this.width)\n .tickFormat(() => ''),\n )\n .selectAll('line')\n .style('stroke', 'rgb(var(--ax-comp-bar-chart-grid-lines-color))')\n .style('stroke-opacity', 0.2);\n\n // Remove unneeded elements from grid\n this.chart.select('.ax-bar-chart-grid').selectAll('path, text').remove();\n }\n }\n\n /**\n * Renders the bars with animations\n */\n private renderBars(data: AXPBarChartData[]): void {\n // Reset animation state\n this._initialAnimationComplete.set(false);\n\n // Get corner radius from options\n const radius = this.effectiveOptions().cornerRadius;\n\n // Get animation options\n const animationDuration = this.effectiveOptions().animationDuration;\n const animationEasing = this.getEasingFunction(this.effectiveOptions().animationEasing);\n\n // Create a container for all bars\n const barsContainer = this.chart.append('g').attr('class', 'ax-bar-chart-bars-container');\n\n // Create groups for each bar to handle transformations\n const barGroups = barsContainer\n .selectAll('.ax-bar-chart-bar-group')\n .data(data)\n .enter()\n .append('g')\n .style('cursor', 'pointer')\n .attr('class', 'ax-bar-chart-bar-group');\n\n // Add bars inside groups\n const bars = barGroups\n .append('rect')\n .attr('class', 'ax-bar-chart-bar')\n .attr('x', (d: AXPBarChartData) => this.xScale(d.label))\n .attr('width', this.xScale.bandwidth())\n .attr('y', this.height) // Start from bottom for animation\n .attr('height', 0) // Start with height 0 for animation\n .attr('rx', radius) // Rounded corners\n .attr('ry', radius) // Rounded corners\n .attr('fill', (d: AXPBarChartData, i: number) => d.color || AXBarChartColors.getColor(i));\n\n // Add data labels if they're enabled\n if (this.effectiveOptions().showDataLabels !== false) {\n barGroups\n .append('text')\n .attr('class', 'ax-bar-chart-data-label')\n .attr('text-anchor', 'middle')\n .attr('x', (d: AXPBarChartData) => this.xScale(d.label) + this.xScale.bandwidth() / 2)\n .attr('y', this.height) // Start from bottom for animation\n .style('font-size', 'clamp(8px, 2vmin, 12px)')\n .style('font-weight', '500')\n .style('fill', 'rgb(var(--ax-comp-bar-chart-data-labels-color))')\n .style('opacity', 0) // Start invisible for animation\n .text((d: AXPBarChartData) => d.value);\n\n // Animate data labels\n barGroups\n .selectAll('.ax-bar-chart-data-label')\n .transition()\n .duration(animationDuration)\n .delay((d: AXPBarChartData, i: number) => i * 50 + 100) // Slightly delayed after bar animation\n .attr('y', (d: AXPBarChartData) => this.yScale(d.value) - 8) // Position above bar\n .style('opacity', 1)\n .ease(animationEasing);\n }\n\n // Set up event handlers on each group\n barGroups\n .on('mouseenter', (event: MouseEvent, d: AXPBarChartData) => {\n // Only apply hover effects if initial animation is complete\n if (!this._initialAnimationComplete()) return;\n\n const barEl = this.d3.select(event.currentTarget).select('rect');\n\n // Standard hover effect - darken the bar slightly and add a subtle shadow\n barEl.transition().duration(150).style('filter', 'brightness(0.7) drop-shadow(0 0 2px rgba(0,0,0,0.1))');\n\n this.handleBarHover(event, d);\n })\n .on('mousemove', (event: MouseEvent) => {\n // Only update tooltip if initial animation is complete\n if (this._initialAnimationComplete()) {\n this.updateTooltipPosition(event);\n }\n })\n .on('mouseleave', (event: MouseEvent, d: AXPBarChartData) => {\n // Only apply hover effects if initial animation is complete\n if (!this._initialAnimationComplete()) return;\n\n const barEl = this.d3.select(event.currentTarget).select('rect');\n\n // Remove hover effect\n barEl.transition().duration(150).style('filter', null);\n\n this._tooltipVisible.set(false);\n })\n .on('click', (event: MouseEvent, d: AXPBarChartData) => {\n // Only trigger click events if initial animation is complete\n if (this._initialAnimationComplete()) {\n this.handleBarClick(event, d);\n }\n });\n\n // Add animation\n bars\n .transition()\n .duration(animationDuration)\n .delay((d: AXPBarChartData, i: number) => i * 50) // Stagger each bar animation\n .attr('y', (d: AXPBarChartData) => this.yScale(d.value))\n .attr('height', (d: AXPBarChartData) => this.height - this.yScale(d.value))\n .ease(animationEasing) // Use the configured easing function\n .end() // Wait for all animations to complete\n .then(() => {\n // Mark animation as complete to enable hover effects\n this._initialAnimationComplete.set(true);\n });\n }\n\n /**\n * Gets the appropriate D3 easing function based on the option string\n */\n private getEasingFunction(easing?: string): any {\n switch (easing) {\n case 'linear':\n return this.d3.easeLinear;\n case 'ease':\n return this.d3.easePolyInOut;\n case 'ease-in':\n return this.d3.easePolyIn;\n case 'ease-out':\n return this.d3.easePolyOut;\n case 'ease-in-out':\n return this.d3.easePolyInOut;\n case 'cubic':\n return this.d3.easeCubic;\n case 'cubic-in':\n return this.d3.easeCubicIn;\n case 'cubic-out':\n return this.d3.easeCubicOut;\n case 'cubic-in-out':\n return this.d3.easeCubicInOut;\n default:\n return this.d3.easeCubicOut; // Default easing\n }\n }\n\n /**\n * Handles bar hover event and shows tooltip\n */\n private handleBarHover(event: MouseEvent, datum: AXPBarChartData): void {\n if (this.effectiveOptions().showTooltip !== false) {\n const index = this.data().findIndex((item) => item.id === datum.id);\n const color = datum.color || AXBarChartColors.getColor(index);\n\n // Calculate percentage of total\n const total = this.data().reduce((sum, item) => sum + item.value, 0);\n const percentage = total > 0 ? ((datum.value / total) * 100).toFixed(1) : '0';\n\n this._tooltipData.set({\n title: datum.label,\n value: datum.value.toString(),\n percentage: `${percentage}%`,\n color: color,\n });\n\n this.updateTooltipPosition(event);\n this._tooltipVisible.set(true);\n }\n }\n\n /**\n * Updates tooltip position based on mouse coordinates\n */\n private updateTooltipPosition(event: MouseEvent): void {\n const container = this.chartContainerEl().nativeElement.getBoundingClientRect();\n const tooltipEl = this.chartContainerEl().nativeElement.querySelector('.chart-tooltip');\n\n if (!tooltipEl) {\n const x = event.clientX - container.left;\n const y = event.clientY - container.top;\n this._tooltipPosition.set({ x, y });\n return;\n }\n\n const tooltipRect = tooltipEl.getBoundingClientRect();\n let x = event.clientX - container.left;\n const y = event.clientY - container.top;\n\n // Adjust position if near the right edge\n if (x + tooltipRect.width + 10 > container.width) {\n x = x - tooltipRect.width - 10;\n } else {\n x = x + 10;\n }\n\n this._tooltipPosition.set({ x, y });\n }\n\n /**\n * Handles bar click event\n */\n private handleBarClick(event: MouseEvent, datum: AXPBarChartData): void {\n this.barClick.emit({ item: datum, event: { nativeEvent: event, sender: this } });\n }\n\n /**\n * Shows a message when no data is available\n */\n private showNoDataMessage(containerElement: HTMLElement): void {\n const messageContainer = this.d3\n .select(containerElement)\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-message')\n .style('width', '100%')\n .style('height', '100%')\n .style('display', 'flex')\n .style('flex-direction', 'column')\n .style('align-items', 'center')\n .style('justify-content', 'center')\n .style('text-align', 'center')\n .style('background-color', 'rgb(var(--ax-comp-bar-chart-bg-color))');\n\n // Add an icon\n messageContainer\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-icon')\n .style('margin-bottom', '10px')\n .html('<i class=\"fa-light fa-chart-bar fa-2x\"></i>');\n\n // Add text message\n messageContainer\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-text')\n .style('font-size', '16px')\n .style('font-weight', '600')\n .text('No data available');\n }\n}\n","<div class=\"ax-bar-chart\" #chartContainer>\n <!-- Shared tooltip component -->\n <ax-chart-tooltip\n [visible]=\"tooltipVisible()\"\n [position]=\"tooltipPosition()\"\n [data]=\"tooltipData()\"\n [showPercentage]=\"true\"\n ></ax-chart-tooltip>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAKa,MAAA,uBAAuB,GAAsB;AACxD,IAAA,SAAS,EAAE,IAAI;AACf,IAAA,SAAS,EAAE,IAAI;AACf,IAAA,QAAQ,EAAE,IAAI;AACd,IAAA,cAAc,EAAE,IAAI;AACpB,IAAA,WAAW,EAAE,IAAI;AACjB,IAAA,QAAQ,EAAE,EAAE;AACZ,IAAA,YAAY,EAAE,CAAC;AACf,IAAA,iBAAiB,EAAE,GAAG;AACtB,IAAA,eAAe,EAAE,WAAW;;MAGjB,mBAAmB,GAAG,IAAI,cAAc,C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AAA,EAAA;;;AErDjD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"acorex-charts-bar-chart.mjs","sources":["../../../../packages/charts/bar-chart/src/lib/bar-chart.config.ts","../../../../packages/charts/bar-chart/src/lib/bar-chart.component.ts","../../../../packages/charts/bar-chart/src/lib/bar-chart.component.html","../../../../packages/charts/bar-chart/src/acorex-charts-bar-chart.ts"],"sourcesContent":["import { AX_GLOBAL_CONFIG } from '@acorex/core/config';\nimport { InjectionToken, inject } from '@angular/core';\nimport { set } from 'lodash-es';\nimport { AXBarChartOption } from './bar-chart.type';\n\nexport const AXBarChartDefaultConfig: AXBarChartOption = {\n showXAxis: true,\n showYAxis: true,\n showGrid: true,\n showDataLabels: true,\n showTooltip: true,\n barWidth: 80,\n cornerRadius: 4,\n animationDuration: 800,\n animationEasing: 'cubic-out',\n};\n\nexport const AX_BAR_CHART_CONFIG = new InjectionToken<AXBarChartOption>('AX_BAR_CHART_CONFIG', {\n providedIn: 'root',\n factory: () => {\n const global = inject(AX_GLOBAL_CONFIG);\n set(global, 'chart.barChart', AXBarChartDefaultConfig);\n return AXBarChartDefaultConfig;\n },\n});\n\nexport type PartialBarChartConfig = Partial<AXBarChartOption>;\n\nexport function barChartConfig(config: PartialBarChartConfig = {}): AXBarChartOption {\n const result = {\n ...AXBarChartDefaultConfig,\n ...config,\n };\n return result;\n}\n","import { NXComponent } from '@acorex/cdk/common';\nimport { AXChartTooltipComponent, AXChartTooltipData } from '@acorex/charts/chart-tooltip';\nimport { CommonModule } from '@angular/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n computed,\n effect,\n ElementRef,\n inject,\n input,\n OnDestroy,\n output,\n signal,\n viewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AX_BAR_CHART_CONFIG } from './bar-chart.config';\nimport { AXBarChartClickEvent, AXBarChartData, AXBarChartOption } from './bar-chart.type';\n\nexport const AXBarChartColors = {\n // Modern color palette suitable for data visualization\n defaultColors: [\n '#4361ee', // Blue\n '#3a0ca3', // Purple\n '#7209b7', // Violet\n '#f72585', // Pink\n '#4cc9f0', // Light Blue\n '#4895ef', // Sky Blue\n '#560bad', // Deep Purple\n '#f15bb5', // Light Pink\n '#00bbf9', // Cyan\n '#00f5d4', // Teal\n ],\n\n // Get a color from the palette by index with wraparound\n getColor: (index: number, customPalette?: string[]): string => {\n const palette = customPalette || AXBarChartColors.defaultColors;\n return palette[index % palette.length];\n },\n};\n\n/**\n * Bar Chart Component\n * Renders data as vertical bars with interactive hover effects and animations\n */\n@Component({\n selector: 'ax-bar-chart',\n templateUrl: './bar-chart.component.html',\n styleUrls: ['./bar-chart.component.scss'],\n encapsulation: ViewEncapsulation.None,\n imports: [CommonModule, AXChartTooltipComponent],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class AXBarChartComponent extends NXComponent implements OnDestroy {\n // Inputs\n /** Chart data input */\n data = input<AXBarChartData[]>([]);\n\n /** Chart options input */\n options = input<AXBarChartOption>({});\n\n // Outputs\n /** Emitted when a bar is clicked */\n barClick = output<AXBarChartClickEvent>();\n\n // Chart container reference\n private readonly chartContainerEl = viewChild.required<ElementRef<HTMLDivElement>>('chartContainer');\n\n // D3 reference - loaded asynchronously\n protected d3!: typeof import('d3');\n\n // Chart elements\n private svg!: any;\n private chart!: any;\n private xScale!: any;\n private yScale!: any;\n private xAxis!: any;\n private yAxis!: any;\n\n // Chart dimensions\n private width!: number;\n private height!: number;\n private margin = { top: 20, right: 20, bottom: 30, left: 40 };\n\n // Animation state\n private _initialAnimationComplete = signal(false);\n\n // Tooltip state\n private _tooltipVisible = signal(false);\n private _tooltipPosition = signal({ x: 0, y: 0 });\n private _tooltipData = signal<AXChartTooltipData>({\n title: '',\n value: '0',\n percentage: '0%',\n color: '',\n });\n\n // Signals for component state\n private _initialized = signal(false);\n private _rendered = signal(false);\n\n // Tooltip accessors\n protected tooltipVisible = this._tooltipVisible.asReadonly();\n protected tooltipPosition = this._tooltipPosition.asReadonly();\n protected tooltipData = this._tooltipData.asReadonly();\n\n // Inject configuration\n private configToken = inject(AX_BAR_CHART_CONFIG);\n\n // Configuration with defaults\n protected effectiveOptions = computed(() => {\n return {\n ...this.configToken,\n ...this.options(),\n };\n });\n\n constructor() {\n super();\n // Dynamically load D3 and initialize the chart when the component is ready\n afterNextRender(() => {\n this._initialized.set(true);\n this.loadD3();\n // Create chart after D3 is loaded and container is available\n if (this.d3 && this.chartContainerEl()) {\n this.createChart();\n this._rendered.set(true);\n }\n });\n\n // Watch for changes to redraw the chart\n effect(() => {\n // Access inputs to track them\n this.data();\n this.effectiveOptions();\n\n // Only update if already rendered\n if (this._rendered()) {\n this.updateChart();\n }\n });\n }\n\n ngOnDestroy(): void {\n this.cleanupChart();\n }\n\n /**\n * Loads D3.js dynamically\n */\n protected async loadD3(): Promise<void> {\n try {\n this.d3 = await import('d3');\n // If container is ready, create chart\n if (this._initialized() && this.chartContainerEl()) {\n this.createChart();\n this._rendered.set(true);\n }\n } catch (error) {\n console.error('Failed to load D3.js:', error);\n }\n }\n\n /**\n * Creates the bar chart SVG and renders all elements\n */\n protected createChart(): void {\n if (!this.d3 || !this.chartContainerEl()?.nativeElement) return;\n\n const containerElement = this.chartContainerEl().nativeElement;\n const data = this.data() || [];\n\n // Clear existing chart\n this.d3.select(containerElement).selectAll('svg').remove();\n\n // Early return if no data\n if (!data.length) {\n this.showNoDataMessage(containerElement);\n return;\n }\n\n // Get options and setup dimensions\n const chartOptions = this.effectiveOptions();\n this.setupDimensions(containerElement, chartOptions);\n\n // Create scales and axes\n this.setupScales(data);\n this.createAxes(chartOptions);\n\n // Render the bars\n this.renderBars(data);\n }\n\n /**\n * Updates the chart when inputs change\n */\n protected updateChart(): void {\n this.createChart();\n }\n\n /**\n * Cleans up chart resources\n */\n protected cleanupChart(): void {\n if (this.svg) {\n this.d3?.select(this.chartContainerEl()?.nativeElement).selectAll('svg').remove();\n this.svg = null;\n this.chart = null;\n }\n this._tooltipVisible.set(false);\n }\n\n /**\n * Sets up chart dimensions and creates SVG with responsive attributes\n */\n private setupDimensions(containerElement: HTMLElement, options: AXBarChartOption): void {\n // Calculate margins based on options\n this.calculateMargins(options);\n\n // Get container dimensions\n const containerWidth = containerElement.clientWidth;\n const containerHeight = containerElement.clientHeight;\n\n // If options specify width and height, use those, otherwise default to container size\n const minDim = Math.min(200, containerWidth, containerHeight); // Ensure reasonable minimum\n\n if (options.width && options.height) {\n // Explicit dimensions provided\n this.width = options.width - this.margin.left - this.margin.right;\n this.height = options.height - this.margin.top - this.margin.bottom;\n } else {\n // Responsive dimensions\n this.width = Math.max(containerWidth, minDim) - this.margin.left - this.margin.right;\n this.height = Math.max(containerHeight, minDim) - this.margin.top - this.margin.bottom;\n }\n\n // Create responsive SVG that scales with its container\n const svg = this.d3\n .select(containerElement)\n .append('svg')\n .attr('width', '100%')\n .attr('height', '100%')\n .attr(\n 'viewBox',\n `0 0 ${this.width + this.margin.left + this.margin.right} ${this.height + this.margin.top + this.margin.bottom}`,\n )\n .attr('preserveAspectRatio', 'xMidYMid meet');\n\n this.svg = svg;\n\n // Create chart group with margins\n this.chart = this.svg.append('g').attr('transform', `translate(${this.margin.left},${this.margin.top})`);\n }\n\n /**\n * Calculates chart margins based on options\n */\n private calculateMargins(options: AXBarChartOption): void {\n // Start with default margins\n this.margin = {\n top: 20,\n right: 20,\n bottom: 30,\n left: 40,\n };\n\n // Adjust margins if axis labels are present\n if (options.xAxisLabel) {\n const xLabelLength = options.xAxisLabel.length;\n const extraBottomMargin = Math.min(20, Math.max(10, xLabelLength * 0.8));\n this.margin.bottom = Math.max(this.margin.bottom, 30 + extraBottomMargin);\n }\n\n if (options.yAxisLabel) {\n const yLabelLength = options.yAxisLabel.length;\n const extraLeftMargin = Math.min(20, Math.max(10, yLabelLength * 0.8));\n this.margin.left = Math.max(this.margin.left, 40 + extraLeftMargin);\n }\n\n // Ensure minimum margins for axes\n if (options.showXAxis !== false) {\n this.margin.bottom = Math.max(this.margin.bottom, 35);\n }\n\n if (options.showYAxis !== false) {\n this.margin.left = Math.max(this.margin.left, 45);\n }\n }\n\n /**\n * Creates x and y scales for the chart\n */\n private setupScales(data: AXBarChartData[]): void {\n // Get the bar width percentage (default 80%)\n const barWidthPercent = this.effectiveOptions().barWidth ?? 60 / 100;\n // Calculate padding based on barWidth (inverse relationship)\n const padding = Math.max(0.1, 1 - barWidthPercent);\n\n // Create x scale (band scale for categorical data)\n this.xScale = this.d3\n .scaleBand()\n .domain(data.map((d) => d.label))\n .range([0, this.width])\n .padding(padding);\n\n // Create y scale (linear scale for values)\n this.yScale = this.d3\n .scaleLinear()\n .domain([0, this.d3.max(data, (d) => d.value) || 0])\n .nice()\n .range([this.height, 0]);\n }\n\n /**\n * Creates x and y axes with grid lines\n */\n private createAxes(options: AXBarChartOption): void {\n // Only create axes if they are enabled in options\n const showXAxis = options.showXAxis !== false;\n const showYAxis = options.showYAxis !== false;\n const showGrid = options.showGrid !== false;\n\n // Create a group for all axes\n const axesGroup = this.chart.append('g').attr('class', 'ax-bar-chart-axes');\n\n if (showXAxis) {\n // Create X axis\n this.xAxis = axesGroup\n .append('g')\n .attr('class', 'ax-bar-chart-axis-x')\n .attr('transform', `translate(0,${this.height})`)\n .call(this.d3.axisBottom(this.xScale));\n\n // Style the axis text\n this.xAxis\n .selectAll('text')\n .style('font-size', '11px')\n .style('font-weight', '400')\n .style('fill', 'rgba(var(--ax-comp-bar-chart-labels-color), 0.7)');\n\n // Style all lines in the x-axis (path, ticks)\n this.xAxis.selectAll('line, path').style('stroke', 'rgb(var(--ax-comp-bar-chart-grid-lines-color))');\n\n // Add X axis label if provided\n if (options.xAxisLabel) {\n const labelY = this.height + this.margin.bottom * 0.65;\n\n axesGroup\n .append('text')\n .attr('class', 'ax-bar-chart-axis-label ax-x-axis-label')\n .attr('text-anchor', 'middle')\n .attr('dominant-baseline', 'middle')\n .attr('x', this.width / 2)\n .attr('y', labelY)\n .style('font-size', '13px')\n .style('font-weight', '500')\n .style('fill', 'rgb(var(--ax-comp-bar-chart-axis-label-color))')\n .text(options.xAxisLabel);\n }\n }\n\n if (showYAxis) {\n // Create Y axis\n this.yAxis = axesGroup.append('g').attr('class', 'ax-bar-chart-axis-y').call(this.d3.axisLeft(this.yScale));\n\n // Style the axis text\n this.yAxis\n .selectAll('text')\n .style('font-size', '11px')\n .style('font-weight', '400')\n .style('fill', 'rgba(var(--ax-comp-bar-chart-labels-color), 0.7)');\n\n // Style all lines in the y-axis (path, ticks)\n this.yAxis.selectAll('line, path').style('stroke', 'rgb(var(--ax-comp-bar-chart-grid-lines-color))');\n\n // Add Y axis label if provided\n if (options.yAxisLabel) {\n const labelX = -this.height / 2;\n const labelY = -this.margin.left * 0.65;\n\n axesGroup\n .append('text')\n .attr('class', 'ax-bar-chart-axis-label ax-y-axis-label')\n .attr('text-anchor', 'middle')\n .attr('dominant-baseline', 'middle')\n .attr('transform', 'rotate(-90)')\n .attr('x', labelX)\n .attr('y', labelY)\n .style('font-size', '13px')\n .style('font-weight', '500')\n .style('fill', 'rgb(var(--ax-comp-bar-chart-axis-label-color))')\n .text(options.yAxisLabel);\n }\n }\n\n if (showGrid) {\n // Add horizontal grid lines\n this.chart\n .append('g')\n .attr('class', 'ax-bar-chart-grid')\n .call(\n this.d3\n .axisLeft(this.yScale)\n .tickSize(-this.width)\n .tickFormat(() => ''),\n )\n .selectAll('line')\n .style('stroke', 'rgb(var(--ax-comp-bar-chart-grid-lines-color))')\n .style('stroke-opacity', 0.2);\n\n // Remove unneeded elements from grid\n this.chart.select('.ax-bar-chart-grid').selectAll('path, text').remove();\n }\n }\n\n /**\n * Renders the bars with animations\n */\n private renderBars(data: AXBarChartData[]): void {\n // Reset animation state\n this._initialAnimationComplete.set(false);\n\n // Get corner radius from options\n const radius = this.effectiveOptions().cornerRadius;\n\n // Get animation options\n const animationDuration = this.effectiveOptions().animationDuration;\n const animationEasing = this.getEasingFunction(this.effectiveOptions().animationEasing);\n\n // Create a container for all bars\n const barsContainer = this.chart.append('g').attr('class', 'ax-bar-chart-bars-container');\n\n // Create groups for each bar to handle transformations\n const barGroups = barsContainer\n .selectAll('.ax-bar-chart-bar-group')\n .data(data)\n .enter()\n .append('g')\n .style('cursor', 'pointer')\n .attr('class', 'ax-bar-chart-bar-group');\n\n // Add bars inside groups\n const bars = barGroups\n .append('rect')\n .attr('class', 'ax-bar-chart-bar')\n .attr('x', (d: AXBarChartData) => this.xScale(d.label))\n .attr('width', this.xScale.bandwidth())\n .attr('y', this.height) // Start from bottom for animation\n .attr('height', 0) // Start with height 0 for animation\n .attr('rx', radius) // Rounded corners\n .attr('ry', radius) // Rounded corners\n .attr('fill', (d: AXBarChartData, i: number) => d.color || AXBarChartColors.getColor(i));\n\n // Add data labels if they're enabled\n if (this.effectiveOptions().showDataLabels !== false) {\n barGroups\n .append('text')\n .attr('class', 'ax-bar-chart-data-label')\n .attr('text-anchor', 'middle')\n .attr('x', (d: AXBarChartData) => this.xScale(d.label) + this.xScale.bandwidth() / 2)\n .attr('y', this.height) // Start from bottom for animation\n .style('font-size', 'clamp(8px, 2vmin, 12px)')\n .style('font-weight', '500')\n .style('fill', 'rgb(var(--ax-comp-bar-chart-data-labels-color))')\n .style('opacity', 0) // Start invisible for animation\n .text((d: AXBarChartData) => d.value);\n\n // Animate data labels\n barGroups\n .selectAll('.ax-bar-chart-data-label')\n .transition()\n .duration(animationDuration)\n .delay((d: AXBarChartData, i: number) => i * 50 + 100) // Slightly delayed after bar animation\n .attr('y', (d: AXBarChartData) => this.yScale(d.value) - 8) // Position above bar\n .style('opacity', 1)\n .ease(animationEasing);\n }\n\n // Set up event handlers on each group\n barGroups\n .on('mouseenter', (event: MouseEvent, d: AXBarChartData) => {\n // Only apply hover effects if initial animation is complete\n if (!this._initialAnimationComplete()) return;\n\n const barEl = this.d3.select(event.currentTarget).select('rect');\n\n // Standard hover effect - darken the bar slightly and add a subtle shadow\n barEl.transition().duration(150).style('filter', 'brightness(0.7) drop-shadow(0 0 2px rgba(0,0,0,0.1))');\n\n this.handleBarHover(event, d);\n })\n .on('mousemove', (event: MouseEvent) => {\n // Only update tooltip if initial animation is complete\n if (this._initialAnimationComplete()) {\n this.updateTooltipPosition(event);\n }\n })\n .on('mouseleave', (event: MouseEvent, d: AXBarChartData) => {\n // Only apply hover effects if initial animation is complete\n if (!this._initialAnimationComplete()) return;\n\n const barEl = this.d3.select(event.currentTarget).select('rect');\n\n // Remove hover effect\n barEl.transition().duration(150).style('filter', null);\n\n this._tooltipVisible.set(false);\n })\n .on('click', (event: MouseEvent, d: AXBarChartData) => {\n // Only trigger click events if initial animation is complete\n if (this._initialAnimationComplete()) {\n this.handleBarClick(event, d);\n }\n });\n\n // Add animation\n bars\n .transition()\n .duration(animationDuration)\n .delay((d: AXBarChartData, i: number) => i * 50) // Stagger each bar animation\n .attr('y', (d: AXBarChartData) => this.yScale(d.value))\n .attr('height', (d: AXBarChartData) => this.height - this.yScale(d.value))\n .ease(animationEasing) // Use the configured easing function\n .end() // Wait for all animations to complete\n .then(() => {\n // Mark animation as complete to enable hover effects\n this._initialAnimationComplete.set(true);\n });\n }\n\n /**\n * Gets the appropriate D3 easing function based on the option string\n */\n private getEasingFunction(easing?: string): any {\n switch (easing) {\n case 'linear':\n return this.d3.easeLinear;\n case 'ease':\n return this.d3.easePolyInOut;\n case 'ease-in':\n return this.d3.easePolyIn;\n case 'ease-out':\n return this.d3.easePolyOut;\n case 'ease-in-out':\n return this.d3.easePolyInOut;\n case 'cubic':\n return this.d3.easeCubic;\n case 'cubic-in':\n return this.d3.easeCubicIn;\n case 'cubic-out':\n return this.d3.easeCubicOut;\n case 'cubic-in-out':\n return this.d3.easeCubicInOut;\n default:\n return this.d3.easeCubicOut; // Default easing\n }\n }\n\n /**\n * Handles bar hover event and shows tooltip\n */\n private handleBarHover(event: MouseEvent, datum: AXBarChartData): void {\n if (this.effectiveOptions().showTooltip !== false) {\n const index = this.data().findIndex((item) => item.id === datum.id);\n const color = datum.color || AXBarChartColors.getColor(index);\n\n // Calculate percentage of total\n const total = this.data().reduce((sum, item) => sum + item.value, 0);\n const percentage = total > 0 ? ((datum.value / total) * 100).toFixed(1) : '0';\n\n this._tooltipData.set({\n title: datum.tooltipLabel || datum.label,\n value: datum.value.toString(),\n percentage: `${percentage}%`,\n color: color,\n });\n\n this.updateTooltipPosition(event);\n this._tooltipVisible.set(true);\n }\n }\n\n /**\n * Updates tooltip position based on mouse coordinates\n */\n private updateTooltipPosition(event: MouseEvent): void {\n const container = this.chartContainerEl().nativeElement.getBoundingClientRect();\n const tooltipEl = this.chartContainerEl().nativeElement.querySelector('.chart-tooltip');\n\n if (!tooltipEl) {\n const x = event.clientX - container.left;\n const y = event.clientY - container.top;\n this._tooltipPosition.set({ x, y });\n return;\n }\n\n const tooltipRect = tooltipEl.getBoundingClientRect();\n let x = event.clientX - container.left;\n const y = event.clientY - container.top;\n\n // Adjust position if near the right edge\n if (x + tooltipRect.width + 10 > container.width) {\n x = x - tooltipRect.width - 10;\n } else {\n x = x + 10;\n }\n\n this._tooltipPosition.set({ x, y });\n }\n\n /**\n * Handles bar click event\n */\n private handleBarClick(event: MouseEvent, datum: AXBarChartData): void {\n this.barClick.emit({ item: datum, event: { nativeEvent: event, sender: this } });\n }\n\n /**\n * Shows a message when no data is available\n */\n private showNoDataMessage(containerElement: HTMLElement): void {\n // Clear existing contents first\n this.d3.select(containerElement).selectAll('*').remove();\n\n const messageContainer = this.d3\n .select(containerElement)\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-message')\n .style('position', 'absolute')\n .style('left', '50%')\n .style('top', '50%')\n .style('transform', 'translate(-50%, -50%)')\n .style('text-align', 'center')\n .style('background-color', 'rgb(var(--ax-comp-bar-chart-bg-color))')\n .style('padding', '1.5rem')\n .style('border-radius', '0.5rem')\n .style('box-shadow', '0 2px 12px rgba(0, 0, 0, 0.08)')\n .style('width', '80%')\n .style('max-width', '300px');\n\n // Add an icon\n messageContainer\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-icon')\n .style('opacity', '0.6')\n .style('margin-bottom', '0.75rem')\n .html('<i class=\"fa-light fa-chart-column fa-2x\"></i>');\n\n // Add text message\n messageContainer\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-text')\n .style('font-size', '1rem')\n .style('font-weight', '600')\n .style('margin-bottom', '0.5rem')\n .text('No data available');\n\n // Add help text\n messageContainer\n .append('div')\n .attr('class', 'ax-bar-chart-no-data-help')\n .style('font-size', '0.8rem')\n .style('opacity', '0.6')\n .text('Please provide data to display the chart');\n }\n}\n","<div class=\"ax-bar-chart\" #chartContainer>\n <!-- Shared tooltip component -->\n <ax-chart-tooltip\n [visible]=\"tooltipVisible()\"\n [position]=\"tooltipPosition()\"\n [data]=\"tooltipData()\"\n [showPercentage]=\"true\"\n ></ax-chart-tooltip>\n</div>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAKa,MAAA,uBAAuB,GAAqB;AACvD,IAAA,SAAS,EAAE,IAAI;AACf,IAAA,SAAS,EAAE,IAAI;AACf,IAAA,QAAQ,EAAE,IAAI;AACd,IAAA,cAAc,EAAE,IAAI;AACpB,IAAA,WAAW,EAAE,IAAI;AACjB,IAAA,QAAQ,EAAE,EAAE;AACZ,IAAA,YAAY,EAAE,CAAC;AACf,IAAA,iBAAiB,EAAE,GAAG;AACtB,IAAA,eAAe,EAAE,WAAW;;MAGjB,mBAAmB,GAAG,IAAI,cAAc,CAAmB,qBAAqB,EAAE;AAC7F,IAAA,UAAU,EAAE,MAAM;IAClB,OAAO,EAAE,MAAK;AACZ,QAAA,MAAM,MAAM,GAAG,MAAM,CAAC,gBAAgB,CAAC;AACvC,QAAA,GAAG,CAAC,MAAM,EAAE,gBAAgB,EAAE,uBAAuB,CAAC;AACtD,QAAA,OAAO,uBAAuB;KAC/B;AACF,CAAA;AAIe,SAAA,cAAc,CAAC,MAAA,GAAgC,EAAE,EAAA;AAC/D,IAAA,MAAM,MAAM,GAAG;AACb,QAAA,GAAG,uBAAuB;AAC1B,QAA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A,cAAc,EAGT,aAAA,EAAA,iBAAiB,CAAC,IAAI,EAC5B,OAAA,EAAA,CAAC,YAAY,EAAE,uBAAuB,CAAC,EAC/B,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,iRAAA,EAAA,MAAA,EAAA,CAAA,k3CAAA,CAAA,EAAA;;;AErDjD;;AAEG;;;;"}
|
|
@@ -56,10 +56,10 @@ class AXChartTooltipComponent {
|
|
|
56
56
|
height: this.tooltipHeight,
|
|
57
57
|
};
|
|
58
58
|
}
|
|
59
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.
|
|
60
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.
|
|
59
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: AXChartTooltipComponent, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
60
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.11", type: AXChartTooltipComponent, isStandalone: true, selector: "ax-chart-tooltip", inputs: { data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, visible: { classPropertyName: "visible", publicName: "visible", isSignal: true, isRequired: false, transformFunction: null }, showPercentage: { classPropertyName: "showPercentage", publicName: "showPercentage", isSignal: true, isRequired: false, transformFunction: null }, style: { classPropertyName: "style", publicName: "style", isSignal: true, isRequired: false, transformFunction: null } }, viewQueries: [{ propertyName: "tooltipContainer", first: true, predicate: ["tooltipContainer"], descendants: true }], ngImport: i0, template: "@if (visible() && data()) {\n <div\n #tooltipContainer\n class=\"chart-tooltip\"\n [style.left.px]=\"position().x\"\n [style.top.px]=\"position().y\"\n [ngStyle]=\"style()\"\n >\n <div class=\"chart-tooltip-title\">{{ data()!.title }}</div>\n <div class=\"chart-tooltip-content\">\n @if (data()!.color) {\n <div class=\"chart-tooltip-color\" [style.background-color]=\"data()!.color\"></div>\n }\n <div class=\"chart-tooltip-value\">{{ data()!.value }}</div>\n @if (showPercentage() && data()!.percentage) {\n <div class=\"chart-tooltip-percentage\">{{ data()!.percentage }}</div>\n }\n </div>\n </div>\n}\n", styles: [".chart-tooltip{position:absolute;pointer-events:none;background-color:#212121e6;color:#fff;padding:.5rem .75rem;border-radius:.375rem;font-size:.8rem;z-index:10;box-shadow:0 4px 12px #00000026;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);border:1px solid rgba(255,255,255,.1);transform:translate(10px,-50%);max-width:200px;font-family:var(--ax-font-family, system-ui, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif);transition:opacity .15s ease,transform .15s ease}.chart-tooltip-title{font-weight:600;padding-bottom:.5rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.chart-tooltip-content{display:flex;justify-content:space-between;align-items:center;gap:.5rem}.chart-tooltip-color{width:10px;height:10px;border-radius:2px;flex-shrink:0;box-shadow:0 1px 2px #0003}.chart-tooltip-value{font-weight:500;flex-grow:1}.chart-tooltip-percentage{background-color:#fff3;padding:.125rem .375rem;border-radius:1rem;font-size:.7rem;font-weight:500;flex-shrink:0}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
61
61
|
}
|
|
62
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.
|
|
62
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.11", ngImport: i0, type: AXChartTooltipComponent, decorators: [{
|
|
63
63
|
type: Component,
|
|
64
64
|
args: [{ selector: 'ax-chart-tooltip', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (visible() && data()) {\n <div\n #tooltipContainer\n class=\"chart-tooltip\"\n [style.left.px]=\"position().x\"\n [style.top.px]=\"position().y\"\n [ngStyle]=\"style()\"\n >\n <div class=\"chart-tooltip-title\">{{ data()!.title }}</div>\n <div class=\"chart-tooltip-content\">\n @if (data()!.color) {\n <div class=\"chart-tooltip-color\" [style.background-color]=\"data()!.color\"></div>\n }\n <div class=\"chart-tooltip-value\">{{ data()!.value }}</div>\n @if (showPercentage() && data()!.percentage) {\n <div class=\"chart-tooltip-percentage\">{{ data()!.percentage }}</div>\n }\n </div>\n </div>\n}\n", styles: [".chart-tooltip{position:absolute;pointer-events:none;background-color:#212121e6;color:#fff;padding:.5rem .75rem;border-radius:.375rem;font-size:.8rem;z-index:10;box-shadow:0 4px 12px #00000026;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);border:1px solid rgba(255,255,255,.1);transform:translate(10px,-50%);max-width:200px;font-family:var(--ax-font-family, system-ui, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif);transition:opacity .15s ease,transform .15s ease}.chart-tooltip-title{font-weight:600;padding-bottom:.5rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.chart-tooltip-content{display:flex;justify-content:space-between;align-items:center;gap:.5rem}.chart-tooltip-color{width:10px;height:10px;border-radius:2px;flex-shrink:0;box-shadow:0 1px 2px #0003}.chart-tooltip-value{font-weight:500;flex-grow:1}.chart-tooltip-percentage{background-color:#fff3;padding:.125rem .375rem;border-radius:1rem;font-size:.7rem;font-weight:500;flex-shrink:0}\n"] }]
|
|
65
65
|
}], ctorParameters: () => [{ type: i0.NgZone }], propDecorators: { tooltipContainer: [{
|