life-as-flowers opened a new issue #16770:
URL: https://github.com/apache/echarts/issues/16770


   ### Version
   
   5.3.1
   
   ### Link to Minimal Reproduction
   
   _No response_
   
   ### Steps to Reproduce
   
   // 该示例是官方文档中的 实时排序柱状图 代码
   var data = [];
   for (let i = 0; i < 5; ++i) {
     data.push(Math.round(Math.random() * 200));
   }
   
   option = {
     xAxis: {
       max: 'dataMax'
     },
     yAxis: {
       type: 'category',
       data: ['A', 'B', 'C', 'D', 'E'],
       inverse: true,
       animationDuration: 300,
       animationDurationUpdate: 300,
       max: 2 // only the largest 3 bars will be displayed
     },
     series: [
       {
         realtimeSort: true,
         name: 'X',
         type: 'bar',
         data: data,
         label: {
           show: true,
           position: 'right',
           valueAnimation: true
         }
       }
     ],
     legend: {
       show: true
     },
     animationDuration: 3000,
     animationDurationUpdate: 3000,
     animationEasing: 'linear',
     animationEasingUpdate: 'linear'
   };
   
   function update() {
     var data = option.series[0].data;
     for (var i = 0; i < data.length; ++i) {
       if (Math.random() > 0.9) {
         data[i] += Math.round(Math.random() * 2000);
       } else {
         data[i] += Math.round(Math.random() * 200);
       }
     }
     myChart.setOption(option);
   }
   
   setInterval(function() {
     update();
   }, 3000);
   
   ### Current Behavior
   
   1、官方文档中series 没有 realtimeSort 字段说明,但是实例中使用了;
   2、文档中axis的realtimeSort 和 sortSeriesIndex 只针对 type: value 使用,针对category无效;
   
   
   ### Expected Behavior
   
   1、文档中 series 标出 realtimeSort 字段;
   2、希望能把 series 中的 realtimeSort 集成到 axis 的 realtimeSort 和 sortSeriesIndex 
字段,针对 type: value, type: category 都可以使用(放在 series 
中感觉很奇怪,而且以后兼容多系列排序时,还要新加优先级设置);
   
   ### Environment
   
   ```markdown
   - OS:win7
   - Browser: chrome 99
   - Framework:vue 2.6.11
   ```
   
   
   ### Any additional comments?
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org
For additional commands, e-mail: commits-h...@echarts.apache.org

Reply via email to