Dependency wheel label legend

by kzoon

HTML

<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/sankey.js"></script>
<script src="https://code.highcharts.com/modules/dependency-wheel.js"></script>

<figure class="highcharts-figure">
  <div id="container"></div>
</figure>

CSS

#container {
  height: 500px;
}

JavaScript

Highcharts.chart('container', {

  title: {
    text: 'Dependency Wheel Test'
  },

  legend: {
    enabled: true
  },
  plotOptions: {
    dependencywheel: {
      showInLegend: true,
      colorByPoint: true,
    }
  },
  series: [{
    showInLegend: true,
    colorByPoint: true,
    nodes: [{
      id: 'Spain',
      colorIndex: 0
    }, {
      id: 'France',
      colorIndex: 1
    }, {
      id: 'Germany',
      colorIndex: 2
    }, {
      id: 'Spain',
      colorIndex: 3
    }, {
      id: 'United Kingdom',
      colorIndex: 4
    }, {
      id: 'Italy',
      colorIndex: 5
    }, {
      id: 'Metherlands',
      colorIndex: 6
    }],
    keys: ['from', 'to', 'weight'],
    data: [
      ['Spain', 'France', 5],
      ['Spain', 'United Kingdom', 1],
      ['Spain', 'Italy', 8],
      ['Spain', 'Netherlands', 1],
      ['France', 'Germany', 2],
      ['France', 'United Kingdom', 5],
      ['France', 'Italy', 3],
      ['Germany', 'Spain', 1],
      ['United Kingdom', 'Germany', 3],
      ['Italy', 'United Kingdom', 2]

    ],

    type: 'dependencywheel',

    dataLabels: {
      color: 'black',
      textPath: {
        enabled: true,
        attributes: {
          dy: 5
        }
      },
      distance: 10
    },
    size: '95%'
  }]

});