简体   繁体   中英

Navigator series in Highstock (highcharts-ng)

I have a Highstock chart. I use highcharts-ng for that. After I remove old serie and add new one, serie in navigator doesn't update. It's not so necessary to have this miniature of chart in navigator, I can set it's opacity and I don't see it, but I need to have the proper range after changing serie. And the range doesn't update too. Here is screencast:

http://videobam.com/jXwOC

Here is my navigator configuration:

    navigator:
      adaptToUpdatedData: true
      series:
        data: []
      xAxis:
        labels:
          style:
            fontSize: '14px'
            fontWeight: 'bold'
      maskFill: 'rgba(0, 165, 211, 0.05)'
      enabled: true
      series:
        # lineColor: 'rgba(0,0,0,0)'
        # fillColor: 'rgba(0,0,0,0)'
        lineColor: '#00a5d3'
        fillColor:
          linearGradient : {  
            x1 : 0, 
            y1 : 0, 
            x2 : 0, 
            y2 : 1 
          }, 
          stops : [[0, '#95d7e7'], [1, '#ffffff']] 

Navigator is always bind to the first series or the series according to ID. So instead of removing series, use series.update() - that will update series with all required options, and connection will be working.

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.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM