cancel
Showing results for 
Search instead for 
Did you mean: 

Hide Data points (2nd child) & Center Legends

Former Member
0 Kudos

Chart Type - Column Combination Dual Axis


2 measures (line) in one axis and another KF (bar) is in the other axis.


I could hide Data points for one of the line measure using the below CSS code;

g.v-m-main g.v-m-plot g.v-axis1 g.v-marker:nth-child(1).v-datapoint.v-morphable-datapoint {visibility:hidden;}


Help 1:

Why the below code is not working for 2nd child?

g.v-m-main g.v-m-plot g.v-axis1 g.v-marker:nth-child(2).v-datapoint.v-morphable-datapoint {visibility:hidden;}


Help 2:

Please provide CSS to center Chart Legends. If there is a way to sequence Legend order, please provide that aswell.


Will be of great help, if anyone could assist me on these.


Thank you for the support

VeeKay




Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Regarding your first question - the following css should help you to hide the points (...use visibility:hidden instead of fill:red):


/* Chart Type: Line ; with 2 measures */

.v-axis1 .v-marker:nth-child(1) .v-datashape:nth-child(2n) .v-datapoint {/*visibility: hidden;*/ fill: red;}

.v-axis1 .v-marker:nth-child(2) .v-datashape:nth-child(2n+1) .v-datapoint {/*visibility: hidden;*/ fill: red;}

/* Chart Type: Line - Dual Axis ; with 2 measures */

.v-axis1 .v-marker .v-datashape:nth-child(2n) .v-datapoint {/*visibility: hidden;*/ fill: red;}

.v-axis2 .v-marker .v-datashape:nth-child(2n+1) .v-datapoint {/*visibility: hidden;*/ fill: red;}

To hide all points:


/* Hide all points */

.v-axis1 .v-datapoint {visibility: hidden;}

.v-axis2 .v-datapoint {visibility: hidden;}

Regarding your second question: I don't know about any css possibility to change the alignment or order of legend items. You could probably achieve that with javascript, but would have to in general use the SDK for it to create an extension.

Regards,

David

Former Member
0 Kudos

Hi Experts,

We also have the same requirement for centrally aligning the legend in the charts.

Has anyone created a SDK or extension for the same?

Thanks

Vishal

Answers (0)