File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ import {
3636import  GlobalModel  from  '../Global' ; 
3737import  {  TooltipMarkupBlockFragment  }  from  '../../component/tooltip/tooltipMarkup' ; 
3838import  {  error ,  makePrintable  }  from  '../../util/log' ; 
39+ import  {  round  }  from  '../../util/number' ; 
3940
4041const  DIMENSION_LABEL_REG  =  / \{ @ ( .+ ?) \} / g; 
4142
@@ -102,8 +103,8 @@ export class DataFormatMixin {
102103            const  stackTop  =  data . get ( stackResultDim ,  dataIndex )  as  number ; 
103104            const  stackBottom  =  data . get ( stackedOverDim ,  dataIndex )  as  number ; 
104105            if  ( ! isNaN ( stackTop )  &&  ! isNaN ( stackBottom ) )  { 
105-                 const  fullPercentValue  =  stackTop  -  stackBottom ; 
106-                 params . percent  =  Math . round ( fullPercentValue   *   100 )   /   100 ; 
106+                 const  normalizedValue  =  stackTop  -  stackBottom ; 
107+                 params . percent  =  round ( normalizedValue ,   2 ) ; 
107108            } 
108109        } 
109110        return  params ; 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments