Highcharts test tool
HTML
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<div id="container"></div>
CSS
#container {
min-width: 300px;
max-width: 800px;
height: 500px;
margin: 1em auto;
}
.highcharts-xaxis-labels > span {
white-space: normal!important;
width: 300px;
}
JavaScript
Highcharts.chart('container', {
"chart": {
"backgroundColor": "#f5f5f5",
"height": 400,
"type": "bar"
},
"series": [
{
"data": [
{
"name": 'bar 5 ',
"color": "#000091",
"y": 5.0,
"id": "5"
},
{
"name": 'bar 7 ',
"color": "#000091",
"y": 7.0,
"id": "7"
},
{
"name": 'bar 9 ',
"color": "#000091",
"y": 9.0,
"id": "9"
},
{
"name": 'bar 11 ',
"color": "#000091",
"y": 11.0,
"id": "2"
},
{
"name": 'bar 13 ',
"color": "#000091",
"y": 13.0,
"id": "13"
},
{
"name": 'bar 14 ',
"color": "#000091",
"y": 14.0,
"id": "14"
}
],
"dataLabels": {
"align": "right",
"color": "#ffffff",
"enabled": true,
"format": "{point.y:.0f} %",
"style": {
"fontSize": "15px",
"textOutline": "none"
}
}
}
],
"title": {
"text": ""
},
"xAxis": [
{
"type": "category",
"alternateGridColor": "#ececec",
"labels": {
step: 1,
"align": "left",
"style": {
"fontSize": "15px"
},
"format": "<div style=\"max-height:65px;overflow:hidden;word-wrap:break-word;\">{value}</div>",
"useHTML": true,
"reserveSpace": true
}
}
],
"yAxis": [
{
"title": {
"text": ""
},
"gridLineWidth": 0,
"labels": {
...