pargat
pargat

Reputation: 1

Highchart - Pie Chart Legend accessibility issue

Using Pie Chart [highchart] and with legend labelFormatter displaying the value with item name but screen reader is not reading that value. In documentation https://api.highcharts.com/highcharts/lang.accessibility.legend its mentioned this is the place where screen reader read the values but i am not able to access the value only the name is coming.

below are the code i am using

lang: {
accessibility:{
legend:{
legendItem:"{itemName} - {value}",
},
}
},

and below is what being render

<button class="highcharts-a11y-proxy-button" aria-label="U.S. Equity - " tabindex="-1" aria-pressed="true" style="border-width: 0px; background-color: transparent; cursor: pointer; outline: none; opacity: 0.001; z-index: 999; overflow: hidden; padding: 0px; margin: 0px; display: block; position: absolute; width: 138px; height: 18px; left: 437px; top: 64px;"> but expected output should be U.S. Equity - 36.7

but values is not coming so wondering if someone has came across the issue and fix.

Thanks in advance

Upvotes: 0

Views: 242

Answers (1)

Michał
Michał

Reputation: 1469

The legendItem property has a different variable naming, to display the value you must use the itemValue variable.

legend: {
    legendItem: '{itemName} - {itemValue}'
}

Upvotes: 0

Related Questions