axidio-styleguide-library1-v2 0.1.73 → 0.1.75
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/dropdown/dropdown.component.mjs +7 -5
- package/esm2022/lib/horizontal-bars-with-scroll-zoom/horizontal-bars-with-scroll-zoom.component.mjs +46 -10
- package/fesm2022/axidio-styleguide-library1-v2.mjs +51 -13
- package/fesm2022/axidio-styleguide-library1-v2.mjs.map +1 -1
- package/lib/dropdown/dropdown.component.d.ts +1 -1
- package/lib/horizontal-bars-with-scroll-zoom/horizontal-bars-with-scroll-zoom.component.d.ts +4 -3
- package/package.json +1 -1
|
@@ -3583,10 +3583,12 @@ class DropdownComponent {
|
|
|
3583
3583
|
}
|
|
3584
3584
|
handleShowOrHideChildList(parentName, event) {
|
|
3585
3585
|
event.stopPropagation();
|
|
3586
|
-
if (
|
|
3587
|
-
this.childDropdownListVisible
|
|
3588
|
-
|
|
3589
|
-
|
|
3586
|
+
if (this.childDropdownListVisible.includes(parentName)) {
|
|
3587
|
+
this.childDropdownListVisible = [];
|
|
3588
|
+
}
|
|
3589
|
+
else {
|
|
3590
|
+
this.childDropdownListVisible = [parentName];
|
|
3591
|
+
}
|
|
3590
3592
|
sessionStorage.setItem('childDropdownListVisible', JSON.stringify(this.childDropdownListVisible));
|
|
3591
3593
|
}
|
|
3592
3594
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: DropdownComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
@@ -7174,21 +7176,57 @@ class HorizontalBarsWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
7174
7176
|
}
|
|
7175
7177
|
isZoomOutSelected(isZoomOut) {
|
|
7176
7178
|
this.isZoomedOut = isZoomOut;
|
|
7177
|
-
this.
|
|
7179
|
+
this.clearChart();
|
|
7180
|
+
setTimeout(() => {
|
|
7181
|
+
this.initializeStackedChart();
|
|
7182
|
+
}, 10);
|
|
7178
7183
|
}
|
|
7179
|
-
ngOnChanges() {
|
|
7180
|
-
|
|
7181
|
-
|
|
7182
|
-
|
|
7184
|
+
ngOnChanges(changes) {
|
|
7185
|
+
// Only reinitialize if chartData actually changed and it's not the first change
|
|
7186
|
+
if (changes.chartData && !changes.chartData.firstChange) {
|
|
7187
|
+
this.clearChart();
|
|
7188
|
+
// Small timeout to ensure DOM cleanup is complete
|
|
7189
|
+
setTimeout(() => {
|
|
7190
|
+
this.initializeStackedChart();
|
|
7191
|
+
}, 10);
|
|
7192
|
+
}
|
|
7193
|
+
// Handle configuration changes
|
|
7194
|
+
if (changes.customChartConfiguration && !changes.customChartConfiguration.firstChange) {
|
|
7195
|
+
this.clearChart();
|
|
7196
|
+
setTimeout(() => {
|
|
7197
|
+
this.initializeStackedChart();
|
|
7198
|
+
}, 10);
|
|
7199
|
+
}
|
|
7200
|
+
}
|
|
7201
|
+
clearChart() {
|
|
7202
|
+
try {
|
|
7203
|
+
// Remove all content from container
|
|
7204
|
+
const container = d3.select(this.containerElt.nativeElement);
|
|
7205
|
+
container.selectAll('*').remove();
|
|
7206
|
+
// Remove by unique ID as backup
|
|
7207
|
+
d3.select('#' + this.uniqueId).remove();
|
|
7208
|
+
// Clear any event listeners
|
|
7209
|
+
container.on('click', null);
|
|
7210
|
+
container.on('mouseenter', null);
|
|
7211
|
+
container.on('mouseout', null);
|
|
7212
|
+
}
|
|
7213
|
+
catch (error) {
|
|
7214
|
+
console.warn('Error clearing chart:', error);
|
|
7215
|
+
}
|
|
7183
7216
|
}
|
|
7184
7217
|
onResized(event) {
|
|
7185
7218
|
let self = this;
|
|
7186
|
-
|
|
7187
|
-
|
|
7219
|
+
this.clearChart();
|
|
7220
|
+
setTimeout(() => {
|
|
7188
7221
|
self.initializeStackedChart();
|
|
7189
|
-
}
|
|
7222
|
+
}, 20); // Slightly longer timeout for resize events
|
|
7223
|
+
}
|
|
7224
|
+
ngOnInit() {
|
|
7225
|
+
// Initialize chart on component init
|
|
7226
|
+
if (this.chartData && this.chartData.data) {
|
|
7227
|
+
this.initializeStackedChart();
|
|
7228
|
+
}
|
|
7190
7229
|
}
|
|
7191
|
-
ngOnInit() { }
|
|
7192
7230
|
initializeStackedChart() {
|
|
7193
7231
|
var self = this;
|
|
7194
7232
|
let data = [];
|