@acorex/charts 21.1.0-next.2 → 22.0.0-next.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/acorex-charts-bar-chart.mjs +73 -58
- package/fesm2022/acorex-charts-bar-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-chart-legend.mjs +21 -13
- package/fesm2022/acorex-charts-chart-legend.mjs.map +1 -1
- package/fesm2022/acorex-charts-chart-tooltip.mjs +31 -21
- package/fesm2022/acorex-charts-chart-tooltip.mjs.map +1 -1
- package/fesm2022/acorex-charts-donut-chart.mjs +57 -26
- package/fesm2022/acorex-charts-donut-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-funnel-chart.mjs +34 -16
- package/fesm2022/acorex-charts-funnel-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-gauge-chart.mjs +139 -23
- package/fesm2022/acorex-charts-gauge-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-heatmap-chart.mjs +34 -16
- package/fesm2022/acorex-charts-heatmap-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-hierarchy-chart.mjs +38 -21
- package/fesm2022/acorex-charts-hierarchy-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-line-chart.mjs +33 -33
- package/fesm2022/acorex-charts-line-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts.mjs +23 -30
- package/fesm2022/acorex-charts.mjs.map +1 -1
- package/package.json +1 -1
- package/types/acorex-charts-bar-chart.d.ts +1 -0
- package/types/acorex-charts-donut-chart.d.ts +1 -0
- package/types/acorex-charts-funnel-chart.d.ts +1 -0
- package/types/acorex-charts-gauge-chart.d.ts +24 -0
- package/types/acorex-charts-heatmap-chart.d.ts +1 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { AX_CHART_DEFAULT_MESSAGES, AXChartComponent, AX_CHART_COLOR_PALETTE, mergeChartOptions, mergeChartMessages, resolveBarWidthFraction, formatLargeNumber, getEasingFunction, renderChartEmptyMessage, getChartColor } from '@acorex/charts';
|
|
2
2
|
import { AXChartTooltipComponent } from '@acorex/charts/chart-tooltip';
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
|
-
import { InjectionToken, input, output, viewChild, signal, inject, computed, afterNextRender, effect,
|
|
4
|
+
import { InjectionToken, input, output, viewChild, signal, inject, computed, afterNextRender, effect, ViewEncapsulation, Component } from '@angular/core';
|
|
5
5
|
|
|
6
6
|
const AXBarChartDefaultConfig = {
|
|
7
7
|
showXAxis: true,
|
|
@@ -41,14 +41,17 @@ function barChartConfig(config = {}) {
|
|
|
41
41
|
class AXBarChartComponent extends AXChartComponent {
|
|
42
42
|
// Inputs
|
|
43
43
|
/** Chart data input */
|
|
44
|
-
data = input([],
|
|
44
|
+
data = input([], /* @ts-ignore */
|
|
45
|
+
...(ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []));
|
|
45
46
|
/** Chart options input */
|
|
46
|
-
options = input({},
|
|
47
|
+
options = input({}, /* @ts-ignore */
|
|
48
|
+
...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
|
|
47
49
|
// Outputs
|
|
48
50
|
/** Emitted when a bar is clicked */
|
|
49
51
|
barClick = output();
|
|
50
52
|
// Chart container reference
|
|
51
|
-
chartContainerEl = viewChild.required('chartContainer'
|
|
53
|
+
chartContainerEl = viewChild.required('chartContainer', /* @ts-ignore */
|
|
54
|
+
...(ngDevMode ? [{ debugName: "chartContainerEl" }] : /* istanbul ignore next */ []));
|
|
52
55
|
// D3 reference - loaded asynchronously
|
|
53
56
|
d3;
|
|
54
57
|
// Chart elements - using proper D3 types
|
|
@@ -102,21 +105,27 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
102
105
|
MANY_ITEMS_THRESHOLD = 20;
|
|
103
106
|
VERY_MANY_ITEMS_THRESHOLD = 50;
|
|
104
107
|
// Animation state
|
|
105
|
-
_initialAnimationComplete = signal(false,
|
|
108
|
+
_initialAnimationComplete = signal(false, /* @ts-ignore */
|
|
109
|
+
...(ngDevMode ? [{ debugName: "_initialAnimationComplete" }] : /* istanbul ignore next */ []));
|
|
106
110
|
// Tooltip state
|
|
107
|
-
_tooltipVisible = signal(false,
|
|
108
|
-
|
|
111
|
+
_tooltipVisible = signal(false, /* @ts-ignore */
|
|
112
|
+
...(ngDevMode ? [{ debugName: "_tooltipVisible" }] : /* istanbul ignore next */ []));
|
|
113
|
+
_tooltipPosition = signal({ x: 0, y: 0 }, /* @ts-ignore */
|
|
114
|
+
...(ngDevMode ? [{ debugName: "_tooltipPosition" }] : /* istanbul ignore next */ []));
|
|
109
115
|
_tooltipData = signal({
|
|
110
116
|
title: '',
|
|
111
117
|
value: '0',
|
|
112
118
|
percentage: '0%',
|
|
113
119
|
color: '',
|
|
114
|
-
},
|
|
120
|
+
}, /* @ts-ignore */
|
|
121
|
+
...(ngDevMode ? [{ debugName: "_tooltipData" }] : /* istanbul ignore next */ []));
|
|
115
122
|
_tooltipRafId = null;
|
|
116
123
|
_pendingTooltipCoords = null;
|
|
117
124
|
// Signals for component state
|
|
118
|
-
_initialized = signal(false,
|
|
119
|
-
|
|
125
|
+
_initialized = signal(false, /* @ts-ignore */
|
|
126
|
+
...(ngDevMode ? [{ debugName: "_initialized" }] : /* istanbul ignore next */ []));
|
|
127
|
+
_rendered = signal(false, /* @ts-ignore */
|
|
128
|
+
...(ngDevMode ? [{ debugName: "_rendered" }] : /* istanbul ignore next */ []));
|
|
120
129
|
// Tooltip accessors
|
|
121
130
|
tooltipVisible = this._tooltipVisible.asReadonly();
|
|
122
131
|
tooltipPosition = this._tooltipPosition.asReadonly();
|
|
@@ -128,9 +137,11 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
128
137
|
// Inject AXPlatform
|
|
129
138
|
// Removed unused AXPlatform injection
|
|
130
139
|
// Configuration with defaults
|
|
131
|
-
effectiveOptions = computed(() => mergeChartOptions(this.configToken, this.options()),
|
|
140
|
+
effectiveOptions = computed(() => mergeChartOptions(this.configToken, this.options()), /* @ts-ignore */
|
|
141
|
+
...(ngDevMode ? [{ debugName: "effectiveOptions" }] : /* istanbul ignore next */ []));
|
|
132
142
|
// Messages with defaults
|
|
133
|
-
effectiveMessages = computed(() => mergeChartMessages(this.configToken.messages, this.options()?.messages),
|
|
143
|
+
effectiveMessages = computed(() => mergeChartMessages(this.configToken.messages, this.options()?.messages), /* @ts-ignore */
|
|
144
|
+
...(ngDevMode ? [{ debugName: "effectiveMessages" }] : /* istanbul ignore next */ []));
|
|
134
145
|
// Track hidden bars and series
|
|
135
146
|
hiddenBars = new Set();
|
|
136
147
|
hiddenSeries = new Set();
|
|
@@ -138,14 +149,16 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
138
149
|
isClusteredMode = computed(() => {
|
|
139
150
|
const value = this.data();
|
|
140
151
|
return Array.isArray(value) && value.length > 0 && 'chartData' in value[0];
|
|
141
|
-
},
|
|
152
|
+
}, /* @ts-ignore */
|
|
153
|
+
...(ngDevMode ? [{ debugName: "isClusteredMode" }] : /* istanbul ignore next */ []));
|
|
142
154
|
visibleData = computed(() => {
|
|
143
155
|
const value = this.data() || [];
|
|
144
156
|
if (this.isClusteredMode()) {
|
|
145
157
|
return value;
|
|
146
158
|
}
|
|
147
159
|
return value.filter((d) => !this.hiddenBars.has(d.id));
|
|
148
|
-
},
|
|
160
|
+
}, /* @ts-ignore */
|
|
161
|
+
...(ngDevMode ? [{ debugName: "visibleData" }] : /* istanbul ignore next */ []));
|
|
149
162
|
hasVisibleData = computed(() => {
|
|
150
163
|
const value = this.data();
|
|
151
164
|
if (!Array.isArray(value) || value.length === 0)
|
|
@@ -157,7 +170,8 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
157
170
|
return groups.some((g) => visibleSeries.some((label) => !!g.chartData.find((item) => item.label === label)));
|
|
158
171
|
}
|
|
159
172
|
return value.some((d) => !this.hiddenBars.has(d.id));
|
|
160
|
-
},
|
|
173
|
+
}, /* @ts-ignore */
|
|
174
|
+
...(ngDevMode ? [{ debugName: "hasVisibleData" }] : /* istanbul ignore next */ []));
|
|
161
175
|
// Type guard helper
|
|
162
176
|
isClusteredData(value) {
|
|
163
177
|
return Array.isArray(value) && value.length > 0 && 'chartData' in value[0];
|
|
@@ -221,7 +235,7 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
221
235
|
const visibleSingleData = isClustered ? [] : this.visibleData();
|
|
222
236
|
const groupedData = isClustered ? inputValue : [];
|
|
223
237
|
// Clear existing chart SVG and messages (do not remove tooltip component)
|
|
224
|
-
this.
|
|
238
|
+
this.clearChartArea(containerElement);
|
|
225
239
|
// Early return if no data
|
|
226
240
|
if (!Array.isArray(inputValue) || inputValue.length === 0) {
|
|
227
241
|
this.showNoDataMessage(containerElement);
|
|
@@ -264,7 +278,7 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
264
278
|
this._pendingTooltipCoords = null;
|
|
265
279
|
const container = this.chartContainerEl()?.nativeElement;
|
|
266
280
|
if (container) {
|
|
267
|
-
this.
|
|
281
|
+
this.clearChartArea(container);
|
|
268
282
|
}
|
|
269
283
|
this.svg = undefined;
|
|
270
284
|
this.chart = undefined;
|
|
@@ -920,24 +934,35 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
920
934
|
percentage: `${percentage}%`,
|
|
921
935
|
color: color,
|
|
922
936
|
});
|
|
923
|
-
this.updateTooltipPosition(event);
|
|
924
937
|
this._tooltipVisible.set(true);
|
|
938
|
+
this.updateTooltipPosition(event);
|
|
925
939
|
}
|
|
926
940
|
}
|
|
927
941
|
updateTooltipPosition(event) {
|
|
928
942
|
this._pendingTooltipCoords = { x: event.clientX, y: event.clientY };
|
|
929
943
|
if (this._tooltipRafId != null)
|
|
930
944
|
return;
|
|
945
|
+
this.scheduleTooltipPosition(0);
|
|
946
|
+
}
|
|
947
|
+
scheduleTooltipPosition(attempt) {
|
|
931
948
|
this._tooltipRafId = requestAnimationFrame(() => {
|
|
932
|
-
this._tooltipRafId = null;
|
|
933
949
|
const coords = this._pendingTooltipCoords;
|
|
934
|
-
if (!coords)
|
|
950
|
+
if (!coords) {
|
|
951
|
+
this._tooltipRafId = null;
|
|
935
952
|
return;
|
|
953
|
+
}
|
|
936
954
|
const containerEl = this.chartContainerEl()?.nativeElement;
|
|
937
|
-
if (!containerEl)
|
|
955
|
+
if (!containerEl) {
|
|
956
|
+
this._tooltipRafId = null;
|
|
938
957
|
return;
|
|
939
|
-
|
|
958
|
+
}
|
|
940
959
|
const tooltipEl = containerEl.querySelector('.chart-tooltip');
|
|
960
|
+
if (!tooltipEl && this._tooltipVisible() && attempt < 3) {
|
|
961
|
+
this.scheduleTooltipPosition(attempt + 1);
|
|
962
|
+
return;
|
|
963
|
+
}
|
|
964
|
+
this._tooltipRafId = null;
|
|
965
|
+
const containerRect = containerEl.getBoundingClientRect();
|
|
941
966
|
const tooltipRect = tooltipEl ? tooltipEl.getBoundingClientRect() : null;
|
|
942
967
|
const pos = this.computeEnhancedTooltipPosition(containerRect, tooltipRect, coords.x, coords.y);
|
|
943
968
|
this._tooltipPosition.set(pos);
|
|
@@ -947,51 +972,42 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
947
972
|
* Enhanced tooltip positioning that considers chart boundaries and prevents overflow
|
|
948
973
|
*/
|
|
949
974
|
computeEnhancedTooltipPosition(containerRect, tooltipRect, clientX, clientY) {
|
|
950
|
-
const
|
|
951
|
-
const
|
|
975
|
+
const containerLeft = containerRect.left;
|
|
976
|
+
const containerTop = containerRect.top;
|
|
977
|
+
const containerRight = containerRect.right;
|
|
978
|
+
const containerBottom = containerRect.bottom;
|
|
952
979
|
if (!tooltipRect) {
|
|
953
|
-
// Default positioning when tooltip dimensions are unknown
|
|
954
980
|
return {
|
|
955
|
-
x: Math.min(
|
|
956
|
-
y: Math.max(this.TOOLTIP_GAP, Math.min(
|
|
981
|
+
x: Math.min(clientX + this.TOOLTIP_GAP, containerRight - this.TOOLTIP_GAP),
|
|
982
|
+
y: Math.max(containerTop + this.TOOLTIP_GAP, Math.min(clientY + this.TOOLTIP_GAP, containerBottom - this.TOOLTIP_GAP)),
|
|
957
983
|
};
|
|
958
984
|
}
|
|
959
|
-
|
|
960
|
-
const
|
|
961
|
-
const
|
|
962
|
-
const
|
|
963
|
-
const spaceAbove = cursorY;
|
|
964
|
-
// Determine best horizontal position
|
|
985
|
+
const spaceRight = containerRight - clientX;
|
|
986
|
+
const spaceLeft = clientX - containerLeft;
|
|
987
|
+
const spaceBelow = containerBottom - clientY;
|
|
988
|
+
const spaceAbove = clientY - containerTop;
|
|
965
989
|
let x;
|
|
966
990
|
if (spaceRight >= tooltipRect.width + this.TOOLTIP_GAP) {
|
|
967
|
-
|
|
968
|
-
x = cursorX + this.TOOLTIP_GAP;
|
|
991
|
+
x = clientX + this.TOOLTIP_GAP;
|
|
969
992
|
}
|
|
970
993
|
else if (spaceLeft >= tooltipRect.width + this.TOOLTIP_GAP) {
|
|
971
|
-
|
|
972
|
-
x = cursorX - tooltipRect.width - this.TOOLTIP_GAP;
|
|
994
|
+
x = clientX - tooltipRect.width - this.TOOLTIP_GAP;
|
|
973
995
|
}
|
|
974
996
|
else {
|
|
975
|
-
|
|
976
|
-
x = Math.max(this.TOOLTIP_GAP, Math.min((containerRect.width - tooltipRect.width) / 2, containerRect.width - tooltipRect.width - this.TOOLTIP_GAP));
|
|
997
|
+
x = Math.max(containerLeft + this.TOOLTIP_GAP, Math.min(containerLeft + (containerRect.width - tooltipRect.width) / 2, containerRight - tooltipRect.width - this.TOOLTIP_GAP));
|
|
977
998
|
}
|
|
978
|
-
// Calculate best vertical position
|
|
979
999
|
let y;
|
|
980
1000
|
if (spaceBelow >= tooltipRect.height + this.TOOLTIP_GAP) {
|
|
981
|
-
|
|
982
|
-
y = cursorY + this.TOOLTIP_GAP;
|
|
1001
|
+
y = clientY + this.TOOLTIP_GAP;
|
|
983
1002
|
}
|
|
984
1003
|
else if (spaceAbove >= tooltipRect.height + this.TOOLTIP_GAP) {
|
|
985
|
-
|
|
986
|
-
y = cursorY - tooltipRect.height - this.TOOLTIP_GAP;
|
|
1004
|
+
y = clientY - tooltipRect.height - this.TOOLTIP_GAP;
|
|
987
1005
|
}
|
|
988
1006
|
else {
|
|
989
|
-
|
|
990
|
-
y = Math.max(this.TOOLTIP_GAP, Math.min((containerRect.height - tooltipRect.height) / 2, containerRect.height - tooltipRect.height - this.TOOLTIP_GAP));
|
|
1007
|
+
y = Math.max(containerTop + this.TOOLTIP_GAP, Math.min(containerTop + (containerRect.height - tooltipRect.height) / 2, containerBottom - tooltipRect.height - this.TOOLTIP_GAP));
|
|
991
1008
|
}
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
y = Math.max(this.TOOLTIP_GAP, Math.min(y, containerRect.height - tooltipRect.height - this.TOOLTIP_GAP));
|
|
1009
|
+
x = Math.max(containerLeft + this.TOOLTIP_GAP, Math.min(x, containerRight - tooltipRect.width - this.TOOLTIP_GAP));
|
|
1010
|
+
y = Math.max(containerTop + this.TOOLTIP_GAP, Math.min(y, containerBottom - tooltipRect.height - this.TOOLTIP_GAP));
|
|
995
1011
|
return { x, y };
|
|
996
1012
|
}
|
|
997
1013
|
/**
|
|
@@ -1176,10 +1192,7 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
1176
1192
|
this.hiddenBars.delete(id);
|
|
1177
1193
|
if (wasAllHidden) {
|
|
1178
1194
|
if (this.chartContainerEl()?.nativeElement) {
|
|
1179
|
-
this.
|
|
1180
|
-
?.select(this.chartContainerEl().nativeElement)
|
|
1181
|
-
.selectAll('svg, .ax-chart-message-container')
|
|
1182
|
-
.remove();
|
|
1195
|
+
this.clearChartArea(this.chartContainerEl().nativeElement);
|
|
1183
1196
|
setTimeout(() => {
|
|
1184
1197
|
this.createChart();
|
|
1185
1198
|
}, 0);
|
|
@@ -1204,7 +1217,7 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
1204
1217
|
this.hiddenSeries.delete(id);
|
|
1205
1218
|
if (wasAllHidden) {
|
|
1206
1219
|
if (this.chartContainerEl()?.nativeElement) {
|
|
1207
|
-
this.
|
|
1220
|
+
this.clearChartArea(this.chartContainerEl().nativeElement);
|
|
1208
1221
|
setTimeout(() => {
|
|
1209
1222
|
this.createChart();
|
|
1210
1223
|
}, 0);
|
|
@@ -1225,6 +1238,8 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
1225
1238
|
return this.chartContainerEl()?.nativeElement ?? null;
|
|
1226
1239
|
}
|
|
1227
1240
|
clearChartArea(containerElement) {
|
|
1241
|
+
if (!this.d3)
|
|
1242
|
+
return;
|
|
1228
1243
|
this.d3.select(containerElement).selectAll('svg, .ax-chart-empty, .ax-chart-message-container').remove();
|
|
1229
1244
|
}
|
|
1230
1245
|
/**
|
|
@@ -1313,12 +1328,12 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
1313
1328
|
this.createXAxisTitle(axesGroup, options.xAxisLabel, tickAreaHeight, gapBelowTicks);
|
|
1314
1329
|
}
|
|
1315
1330
|
}
|
|
1316
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1317
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "
|
|
1331
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXBarChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1332
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.0.8", 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\" role=\"img\" #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: ["@reference \"../../../../styles/themes/default.css\";@import \"../../../src/lib/chart-empty-state.css\";@layer components{ax-bar-chart{@apply box-border block h-full w-full;min-height:clamp(220px,38vw,360px);--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: 0, 0, 0, 0}ax-bar-chart .ax-bar-chart{@apply relative box-border h-full min-h-0 w-full overflow-hidden;background-color:rgba(var(--ax-comp-bar-chart-bg-color))}ax-bar-chart .ax-bar-chart svg{@apply block h-full max-h-full w-full max-w-full;}ax-bar-chart .ax-bar-chart svg g:has(text){font-family:inherit}ax-bar-chart .ax-bar-chart .ax-bar-chart-data-label{@apply pointer-events-none select-none;}ax-bar-chart .ax-bar-chart .ax-bar-chart-data-label[data-inside-bar=true]{fill:#fff;font-weight:600;text-shadow:0 0 2px rgba(0,0,0,.3)}}\n"], dependencies: [{ kind: "component", type: AXChartTooltipComponent, selector: "ax-chart-tooltip", inputs: ["data", "position", "visible", "showPercentage", "style"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
1318
1333
|
}
|
|
1319
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1334
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: AXBarChartComponent, decorators: [{
|
|
1320
1335
|
type: Component,
|
|
1321
|
-
args: [{ selector: 'ax-bar-chart', encapsulation: ViewEncapsulation.None, imports: [AXChartTooltipComponent],
|
|
1336
|
+
args: [{ selector: 'ax-bar-chart', encapsulation: ViewEncapsulation.None, imports: [AXChartTooltipComponent], template: "<div class=\"ax-bar-chart\" role=\"img\" #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: ["@reference \"../../../../styles/themes/default.css\";@import \"../../../src/lib/chart-empty-state.css\";@layer components{ax-bar-chart{@apply box-border block h-full w-full;min-height:clamp(220px,38vw,360px);--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: 0, 0, 0, 0}ax-bar-chart .ax-bar-chart{@apply relative box-border h-full min-h-0 w-full overflow-hidden;background-color:rgba(var(--ax-comp-bar-chart-bg-color))}ax-bar-chart .ax-bar-chart svg{@apply block h-full max-h-full w-full max-w-full;}ax-bar-chart .ax-bar-chart svg g:has(text){font-family:inherit}ax-bar-chart .ax-bar-chart .ax-bar-chart-data-label{@apply pointer-events-none select-none;}ax-bar-chart .ax-bar-chart .ax-bar-chart-data-label[data-inside-bar=true]{fill:#fff;font-weight:600;text-shadow:0 0 2px rgba(0,0,0,.3)}}\n"] }]
|
|
1322
1337
|
}], ctorParameters: () => [], propDecorators: { data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }], options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: false }] }], barClick: [{ type: i0.Output, args: ["barClick"] }], chartContainerEl: [{ type: i0.ViewChild, args: ['chartContainer', { isSignal: true }] }] } });
|
|
1323
1338
|
|
|
1324
1339
|
/**
|