axidio-styleguide-library1-v2 0.0.945 → 0.0.947
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/group-chart/group-chart.component.mjs +43 -50
- package/esm2022/lib/horizontal-grouped-bar-with-scroll-zoom/horizontal-grouped-bar-with-scroll-zoom.component.mjs +5 -55
- package/fesm2022/axidio-styleguide-library1-v2.mjs +46 -103
- package/fesm2022/axidio-styleguide-library1-v2.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -4572,55 +4572,48 @@ class GroupChartComponent extends ComponentUniqueId {
|
|
|
4572
4572
|
* display data values on mouse over
|
|
4573
4573
|
* used by dashboard charts
|
|
4574
4574
|
*/
|
|
4575
|
-
|
|
4576
|
-
|
|
4577
|
-
|
|
4578
|
-
|
|
4579
|
-
|
|
4580
|
-
|
|
4581
|
-
|
|
4582
|
-
|
|
4583
|
-
|
|
4584
|
-
|
|
4585
|
-
|
|
4586
|
-
|
|
4587
|
-
|
|
4588
|
-
|
|
4589
|
-
|
|
4590
|
-
|
|
4591
|
-
|
|
4592
|
-
|
|
4593
|
-
|
|
4594
|
-
|
|
4595
|
-
|
|
4596
|
-
|
|
4597
|
-
|
|
4598
|
-
|
|
4599
|
-
|
|
4600
|
-
|
|
4601
|
-
|
|
4602
|
-
|
|
4603
|
-
|
|
4604
|
-
|
|
4605
|
-
|
|
4606
|
-
|
|
4607
|
-
|
|
4608
|
-
|
|
4609
|
-
|
|
4610
|
-
|
|
4611
|
-
|
|
4612
|
-
|
|
4613
|
-
|
|
4614
|
-
|
|
4615
|
-
|
|
4616
|
-
|
|
4617
|
-
// })
|
|
4618
|
-
// .attr('width', xSubgroup.bandwidth())
|
|
4619
|
-
// .text(function (d) {
|
|
4620
|
-
// return d.value;
|
|
4621
|
-
// });
|
|
4622
|
-
// });
|
|
4623
|
-
// }
|
|
4575
|
+
if (this.chartConfiguration.textsOnBar == undefined &&
|
|
4576
|
+
this.chartConfiguration.displayTitleOnTop == undefined) {
|
|
4577
|
+
state
|
|
4578
|
+
.selectAll('rect')
|
|
4579
|
+
.on('mouseout', function (d) {
|
|
4580
|
+
state.selectAll('.barstext').remove();
|
|
4581
|
+
})
|
|
4582
|
+
.on('mouseover', function (d1) {
|
|
4583
|
+
state
|
|
4584
|
+
.selectAll('text')
|
|
4585
|
+
.data(function (d) {
|
|
4586
|
+
let newList = [];
|
|
4587
|
+
subgroups.map(function (key) {
|
|
4588
|
+
if (key !== 'name' &&
|
|
4589
|
+
d1.key == key &&
|
|
4590
|
+
d1.value == d[key] &&
|
|
4591
|
+
d1.name == d.name) {
|
|
4592
|
+
let obj = { key: key, value: d[key], name: d.name };
|
|
4593
|
+
newList.push(obj);
|
|
4594
|
+
}
|
|
4595
|
+
});
|
|
4596
|
+
return newList;
|
|
4597
|
+
})
|
|
4598
|
+
.enter()
|
|
4599
|
+
.append('text')
|
|
4600
|
+
.attr('class', 'barstext')
|
|
4601
|
+
.attr('x', function (d) {
|
|
4602
|
+
return xSubgroup(d.key);
|
|
4603
|
+
})
|
|
4604
|
+
.attr('y', function (d) {
|
|
4605
|
+
return y(d.value);
|
|
4606
|
+
})
|
|
4607
|
+
.attr('style', 'font-size: ' + '.85em' + ';' + ' font-weight:' + 'bold' + ';')
|
|
4608
|
+
.style('fill', function (d) {
|
|
4609
|
+
return metaData.colors[d.key];
|
|
4610
|
+
})
|
|
4611
|
+
.attr('width', xSubgroup.bandwidth())
|
|
4612
|
+
.text(function (d) {
|
|
4613
|
+
return d.value;
|
|
4614
|
+
});
|
|
4615
|
+
});
|
|
4616
|
+
}
|
|
4624
4617
|
svg
|
|
4625
4618
|
.append('g')
|
|
4626
4619
|
.attr('class', 'x2 axis2')
|
|
@@ -9304,7 +9297,10 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
9304
9297
|
.on('mouseout', handleMouseOut)
|
|
9305
9298
|
.on('mouseover', handleMouseOver);
|
|
9306
9299
|
}
|
|
9307
|
-
|
|
9300
|
+
const shouldBindMouseEvents = this.chartConfiguration.displayTitleOnTop ||
|
|
9301
|
+
(this.chartConfiguration.textsOnBar === undefined &&
|
|
9302
|
+
this.chartConfiguration.displayTitleOnTop === undefined);
|
|
9303
|
+
if (shouldBindMouseEvents) {
|
|
9308
9304
|
state
|
|
9309
9305
|
.selectAll('rect')
|
|
9310
9306
|
.on('mouseout', handleMouseOut)
|
|
@@ -9426,59 +9422,6 @@ class HorizontalGroupedBarWithScrollZoomComponent extends ComponentUniqueId {
|
|
|
9426
9422
|
* display data values on mouse over
|
|
9427
9423
|
* used by dashboard charts
|
|
9428
9424
|
*/
|
|
9429
|
-
// if (
|
|
9430
|
-
// this.chartConfiguration.textsOnBar == undefined &&
|
|
9431
|
-
// this.chartConfiguration.displayTitleOnTop == undefined
|
|
9432
|
-
// ) {
|
|
9433
|
-
// state
|
|
9434
|
-
// .selectAll('rect')
|
|
9435
|
-
// .on('mouseout', function (d) {
|
|
9436
|
-
// state.selectAll('.barstext').remove();
|
|
9437
|
-
// })
|
|
9438
|
-
// .on('mouseover', function (d1) {
|
|
9439
|
-
// state
|
|
9440
|
-
// .selectAll('text')
|
|
9441
|
-
// .data(function (d) {
|
|
9442
|
-
// let newList: any = [];
|
|
9443
|
-
// subgroups.map(function (key) {
|
|
9444
|
-
// if (
|
|
9445
|
-
// key !== 'name' &&
|
|
9446
|
-
// d1.key == key &&
|
|
9447
|
-
// d1.value == d[key] &&
|
|
9448
|
-
// d1.name == d.name
|
|
9449
|
-
// ) {
|
|
9450
|
-
// let obj: any = { key: key, value: d[key], name: d.name };
|
|
9451
|
-
// newList.push(obj);
|
|
9452
|
-
// }
|
|
9453
|
-
// });
|
|
9454
|
-
// return newList;
|
|
9455
|
-
// })
|
|
9456
|
-
// .enter()
|
|
9457
|
-
// .append('text')
|
|
9458
|
-
// .attr('fill', 'var(--chart-text-color)')
|
|
9459
|
-
// .attr('class', 'barstext')
|
|
9460
|
-
// .attr('x', function (d) {
|
|
9461
|
-
// return xSubgroup(d.key);
|
|
9462
|
-
// })
|
|
9463
|
-
// .attr('y', function (d) {
|
|
9464
|
-
// return y(d.value);
|
|
9465
|
-
// })
|
|
9466
|
-
// .attr(
|
|
9467
|
-
// 'style',
|
|
9468
|
-
// 'font-size: ' + '.85em' + ';' + ' font-weight:' + 'bold' + ';'
|
|
9469
|
-
// )
|
|
9470
|
-
// .style('fill', function (d) {
|
|
9471
|
-
// return metaData.colors[d.key];
|
|
9472
|
-
// })
|
|
9473
|
-
// .attr(
|
|
9474
|
-
// 'width',
|
|
9475
|
-
// self.isZoomedOut ? xSubgroup.bandwidth() : xSubgroup.bandwidth()
|
|
9476
|
-
// )
|
|
9477
|
-
// .text(function (d) {
|
|
9478
|
-
// return d.value;
|
|
9479
|
-
// });
|
|
9480
|
-
// });
|
|
9481
|
-
// }
|
|
9482
9425
|
svg
|
|
9483
9426
|
.append('g')
|
|
9484
9427
|
.attr('class', 'x2 axis2')
|