@acorex/charts 21.0.3-next.33 → 21.0.3-next.36
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 +18 -18
- package/fesm2022/acorex-charts-bar-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-chart-legend.mjs +13 -13
- package/fesm2022/acorex-charts-chart-legend.mjs.map +1 -1
- package/fesm2022/acorex-charts-chart-tooltip.mjs +10 -10
- package/fesm2022/acorex-charts-chart-tooltip.mjs.map +1 -1
- package/fesm2022/acorex-charts-donut-chart.mjs +18 -18
- package/fesm2022/acorex-charts-donut-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-funnel-chart.mjs +15 -17
- package/fesm2022/acorex-charts-funnel-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-gauge-chart.mjs +15 -15
- package/fesm2022/acorex-charts-gauge-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-heatmap-chart.mjs +14 -14
- package/fesm2022/acorex-charts-heatmap-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-hierarchy-chart.mjs +19 -19
- package/fesm2022/acorex-charts-hierarchy-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts-line-chart.mjs +15 -15
- package/fesm2022/acorex-charts-line-chart.mjs.map +1 -1
- package/fesm2022/acorex-charts.mjs +4 -4
- package/fesm2022/acorex-charts.mjs.map +1 -1
- package/package.json +13 -12
- /package/{bar-chart/index.d.ts → types/acorex-charts-bar-chart.d.ts} +0 -0
- /package/{chart-legend/index.d.ts → types/acorex-charts-chart-legend.d.ts} +0 -0
- /package/{chart-tooltip/index.d.ts → types/acorex-charts-chart-tooltip.d.ts} +0 -0
- /package/{donut-chart/index.d.ts → types/acorex-charts-donut-chart.d.ts} +0 -0
- /package/{funnel-chart/index.d.ts → types/acorex-charts-funnel-chart.d.ts} +0 -0
- /package/{gauge-chart/index.d.ts → types/acorex-charts-gauge-chart.d.ts} +0 -0
- /package/{heatmap-chart/index.d.ts → types/acorex-charts-heatmap-chart.d.ts} +0 -0
- /package/{hierarchy-chart/index.d.ts → types/acorex-charts-hierarchy-chart.d.ts} +0 -0
- /package/{line-chart/index.d.ts → types/acorex-charts-line-chart.d.ts} +0 -0
- /package/{index.d.ts → types/acorex-charts.d.ts} +0 -0
|
@@ -41,9 +41,9 @@ function barChartConfig(config = {}) {
|
|
|
41
41
|
class AXBarChartComponent extends AXChartComponent {
|
|
42
42
|
// Inputs
|
|
43
43
|
/** Chart data input */
|
|
44
|
-
data = input([], ...(ngDevMode ? [{ debugName: "data" }] : []));
|
|
44
|
+
data = input([], ...(ngDevMode ? [{ debugName: "data" }] : /* istanbul ignore next */ []));
|
|
45
45
|
/** Chart options input */
|
|
46
|
-
options = input({}, ...(ngDevMode ? [{ debugName: "options" }] : []));
|
|
46
|
+
options = input({}, ...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
|
|
47
47
|
// Outputs
|
|
48
48
|
/** Emitted when a bar is clicked */
|
|
49
49
|
barClick = output();
|
|
@@ -102,21 +102,21 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
102
102
|
MANY_ITEMS_THRESHOLD = 20;
|
|
103
103
|
VERY_MANY_ITEMS_THRESHOLD = 50;
|
|
104
104
|
// Animation state
|
|
105
|
-
_initialAnimationComplete = signal(false, ...(ngDevMode ? [{ debugName: "_initialAnimationComplete" }] : []));
|
|
105
|
+
_initialAnimationComplete = signal(false, ...(ngDevMode ? [{ debugName: "_initialAnimationComplete" }] : /* istanbul ignore next */ []));
|
|
106
106
|
// Tooltip state
|
|
107
|
-
_tooltipVisible = signal(false, ...(ngDevMode ? [{ debugName: "_tooltipVisible" }] : []));
|
|
108
|
-
_tooltipPosition = signal({ x: 0, y: 0 }, ...(ngDevMode ? [{ debugName: "_tooltipPosition" }] : []));
|
|
107
|
+
_tooltipVisible = signal(false, ...(ngDevMode ? [{ debugName: "_tooltipVisible" }] : /* istanbul ignore next */ []));
|
|
108
|
+
_tooltipPosition = signal({ x: 0, y: 0 }, ...(ngDevMode ? [{ debugName: "_tooltipPosition" }] : /* istanbul ignore next */ []));
|
|
109
109
|
_tooltipData = signal({
|
|
110
110
|
title: '',
|
|
111
111
|
value: '0',
|
|
112
112
|
percentage: '0%',
|
|
113
113
|
color: '',
|
|
114
|
-
}, ...(ngDevMode ? [{ debugName: "_tooltipData" }] : []));
|
|
114
|
+
}, ...(ngDevMode ? [{ debugName: "_tooltipData" }] : /* istanbul ignore next */ []));
|
|
115
115
|
_tooltipRafId = null;
|
|
116
116
|
_pendingTooltipCoords = null;
|
|
117
117
|
// Signals for component state
|
|
118
|
-
_initialized = signal(false, ...(ngDevMode ? [{ debugName: "_initialized" }] : []));
|
|
119
|
-
_rendered = signal(false, ...(ngDevMode ? [{ debugName: "_rendered" }] : []));
|
|
118
|
+
_initialized = signal(false, ...(ngDevMode ? [{ debugName: "_initialized" }] : /* istanbul ignore next */ []));
|
|
119
|
+
_rendered = signal(false, ...(ngDevMode ? [{ debugName: "_rendered" }] : /* istanbul ignore next */ []));
|
|
120
120
|
// Tooltip accessors
|
|
121
121
|
tooltipVisible = this._tooltipVisible.asReadonly();
|
|
122
122
|
tooltipPosition = this._tooltipPosition.asReadonly();
|
|
@@ -128,9 +128,9 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
128
128
|
// Inject AXPlatform
|
|
129
129
|
// Removed unused AXPlatform injection
|
|
130
130
|
// Configuration with defaults
|
|
131
|
-
effectiveOptions = computed(() => mergeChartOptions(this.configToken, this.options()), ...(ngDevMode ? [{ debugName: "effectiveOptions" }] : []));
|
|
131
|
+
effectiveOptions = computed(() => mergeChartOptions(this.configToken, this.options()), ...(ngDevMode ? [{ debugName: "effectiveOptions" }] : /* istanbul ignore next */ []));
|
|
132
132
|
// Messages with defaults
|
|
133
|
-
effectiveMessages = computed(() => mergeChartMessages(this.configToken.messages, this.options()?.messages), ...(ngDevMode ? [{ debugName: "effectiveMessages" }] : []));
|
|
133
|
+
effectiveMessages = computed(() => mergeChartMessages(this.configToken.messages, this.options()?.messages), ...(ngDevMode ? [{ debugName: "effectiveMessages" }] : /* istanbul ignore next */ []));
|
|
134
134
|
// Track hidden bars and series
|
|
135
135
|
hiddenBars = new Set();
|
|
136
136
|
hiddenSeries = new Set();
|
|
@@ -138,14 +138,14 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
138
138
|
isClusteredMode = computed(() => {
|
|
139
139
|
const value = this.data();
|
|
140
140
|
return Array.isArray(value) && value.length > 0 && 'chartData' in value[0];
|
|
141
|
-
}, ...(ngDevMode ? [{ debugName: "isClusteredMode" }] : []));
|
|
141
|
+
}, ...(ngDevMode ? [{ debugName: "isClusteredMode" }] : /* istanbul ignore next */ []));
|
|
142
142
|
visibleData = computed(() => {
|
|
143
143
|
const value = this.data() || [];
|
|
144
144
|
if (this.isClusteredMode()) {
|
|
145
145
|
return value;
|
|
146
146
|
}
|
|
147
147
|
return value.filter((d) => !this.hiddenBars.has(d.id));
|
|
148
|
-
}, ...(ngDevMode ? [{ debugName: "visibleData" }] : []));
|
|
148
|
+
}, ...(ngDevMode ? [{ debugName: "visibleData" }] : /* istanbul ignore next */ []));
|
|
149
149
|
hasVisibleData = computed(() => {
|
|
150
150
|
const value = this.data();
|
|
151
151
|
if (!Array.isArray(value) || value.length === 0)
|
|
@@ -157,7 +157,7 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
157
157
|
return groups.some((g) => visibleSeries.some((label) => !!g.chartData.find((item) => item.label === label)));
|
|
158
158
|
}
|
|
159
159
|
return value.some((d) => !this.hiddenBars.has(d.id));
|
|
160
|
-
}, ...(ngDevMode ? [{ debugName: "hasVisibleData" }] : []));
|
|
160
|
+
}, ...(ngDevMode ? [{ debugName: "hasVisibleData" }] : /* istanbul ignore next */ []));
|
|
161
161
|
// Type guard helper
|
|
162
162
|
isClusteredData(value) {
|
|
163
163
|
return Array.isArray(value) && value.length > 0 && 'chartData' in value[0];
|
|
@@ -1313,13 +1313,13 @@ class AXBarChartComponent extends AXChartComponent {
|
|
|
1313
1313
|
this.createXAxisTitle(axesGroup, options.xAxisLabel, tickAreaHeight, gapBelowTicks);
|
|
1314
1314
|
}
|
|
1315
1315
|
}
|
|
1316
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1317
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "
|
|
1316
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXBarChartComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1317
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.2.9", 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: [".ax-chart-empty{position:absolute;inset:0;z-index:1;display:flex;align-items:center;justify-content:center;box-sizing:border-box;padding:1rem;pointer-events:none}.ax-chart-empty__card{text-align:center;padding:1.5rem;border-radius:.5rem;border:1px solid rgba(var(--ax-sys-color-surface));width:80%;max-width:300px;box-sizing:border-box}.ax-chart-empty__icon{opacity:.6;margin-bottom:.75rem}.ax-chart-empty__title{font-size:1rem;font-weight:600;margin-bottom:.5rem}.ax-chart-empty__help{font-size:.8rem;opacity:.6}ax-bar-chart{display:block;width:100%;height:100%;min-height:clamp(220px,38vw,360px);box-sizing:border-box;--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{width:100%;height:100%;position:relative;min-height:0;box-sizing:border-box;overflow:hidden;background-color:rgba(var(--ax-comp-bar-chart-bg-color))}ax-bar-chart .ax-bar-chart svg{display:block;width:100%;height:100%;max-width:100%;max-height:100%}ax-bar-chart .ax-bar-chart svg g:has(text){font-family:inherit}ax-bar-chart .ax-bar-chart .ax-bar-chart-data-label{pointer-events:none;-webkit-user-select:none;user-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"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1318
1318
|
}
|
|
1319
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1319
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: AXBarChartComponent, decorators: [{
|
|
1320
1320
|
type: Component,
|
|
1321
|
-
args: [{ selector: 'ax-bar-chart', encapsulation: ViewEncapsulation.None, imports: [AXChartTooltipComponent], changeDetection: ChangeDetectionStrategy.OnPush, 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: [".ax-chart-empty{position:absolute;
|
|
1322
|
-
}], ctorParameters: () => [] });
|
|
1321
|
+
args: [{ selector: 'ax-bar-chart', encapsulation: ViewEncapsulation.None, imports: [AXChartTooltipComponent], changeDetection: ChangeDetectionStrategy.OnPush, 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: [".ax-chart-empty{position:absolute;inset:0;z-index:1;display:flex;align-items:center;justify-content:center;box-sizing:border-box;padding:1rem;pointer-events:none}.ax-chart-empty__card{text-align:center;padding:1.5rem;border-radius:.5rem;border:1px solid rgba(var(--ax-sys-color-surface));width:80%;max-width:300px;box-sizing:border-box}.ax-chart-empty__icon{opacity:.6;margin-bottom:.75rem}.ax-chart-empty__title{font-size:1rem;font-weight:600;margin-bottom:.5rem}.ax-chart-empty__help{font-size:.8rem;opacity:.6}ax-bar-chart{display:block;width:100%;height:100%;min-height:clamp(220px,38vw,360px);box-sizing:border-box;--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{width:100%;height:100%;position:relative;min-height:0;box-sizing:border-box;overflow:hidden;background-color:rgba(var(--ax-comp-bar-chart-bg-color))}ax-bar-chart .ax-bar-chart svg{display:block;width:100%;height:100%;max-width:100%;max-height:100%}ax-bar-chart .ax-bar-chart svg g:has(text){font-family:inherit}ax-bar-chart .ax-bar-chart .ax-bar-chart-data-label{pointer-events:none;-webkit-user-select:none;user-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
|
+
}], 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
1323
|
|
|
1324
1324
|
/**
|
|
1325
1325
|
* Generated bundle index. Do not edit.
|