You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2021/03/30 06:44:29 UTC

[GitHub] [echarts] 100pah opened a new issue #14554: emphasis state remain unexpectedly when using gradient

100pah opened a new issue #14554:
URL: https://github.com/apache/echarts/issues/14554


   ### Version
   5.0.2
   
   ### Steps to reproduce
   ```js
   
   option = {
       xAxis: {
           type: 'category',
           data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
       },
       yAxis: {
           type: 'value'
       },
       series: [{
           emphasis: {
               itemStyle: {
                   color: 'yellow'
               },
               focus: 'self'
           },
           select: {
               itemStyle: {
                   borderWidth: 5
               }
           },
           itemStyle: {
               color: {
                   type: 'linear',
                   x: 0,
                   y: 0,
                   x2: 0,
                   y2: 1,
                   colorStops: [{
                       offset: 0, color: 'red' // 0% 处的颜色
                   }, {
                       offset: 1, color: 'blue' // 100% 处的颜色
                   }],
                   global: false // 缺省为 false
               }
           },
           selectedMode: true,
           data: [150, 230, 224, 218, 135, 147, 260],
           type: 'bar'
       }]
   };
   ```
   
   +  click a bar and mouseout (the bar will be selected, where it's styled with a border).
   + click the bar again (which brings the state change: 'select' -> 'normal') and rapidly mouseout (before the state animation finished).
   + then the emphasis state (yellow filled) will be remained unexpectedly.
   
   
   ![aaa](https://user-images.githubusercontent.com/1956569/112944951-2ea21d00-9166-11eb-94c9-6cb0b4aea38b.gif)
   
   
   ### What is expected?
   state transition correct
   
   ### What is actually happening?
   not correct
   
   <!-- This issue is generated by echarts-issue-helper. DO NOT REMOVE -->
   <!-- This issue is in English. DO NOT REMOVE -->


-- 
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.

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



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