I can't set the font size on organization diagram, I want to be in 'em' unit because isn't looking good on mobile device.
I already tried:
Highcharts.chart('container', {
chart: {
height: 600,
inverted: true
},
title: {
text: 'Highcharts Org Chart'
},
dataLabels: {
style: {
fontSize: '30px'
}
},
series: [{
type: 'organization',
name: '',
keys: ['from', 'to'],
data: [
['Shareholders', 'Board'],
['Board', 'CEO'],
['CEO', 'CTO'],
['CEO', 'CPO'],
['CEO', 'CSO'],
['CEO', 'CMO'],
['CEO', 'HR'],
['CTO', 'Product'],
['CTO', 'Web'],
['CSO', 'Sales'],
['CMO', 'Market']
],
levels: [{
level: 0
dataLabels: {
style: {
fontSize: '30px'
}
}
}],
dataLabels: {
style: {
fontSize: '30px'
}
}
}]
})
Any idea?
Anothers styles like "color" or "fontFamily" does work
The fontSize
defined for each particular level or defined for the whole series works fine, even using em
unit.
Demo: https://jsfiddle.net/BlackLabel/voz3btL1/
levels: [{
level: 0,
dataLabels: {
style: {
fontSize: '4em'
}
}
}],
API: https://api.highcharts.com/highcharts/series.organization.dataLabels.style.fontSize
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.