@@ -100,7 +100,8 @@ export function createProgressBarCell(
100100 barMarkPositiveColor,
101101 barMarkNegativeColor,
102102 barMarkWidth,
103- barMarkPosition
103+ barMarkPosition,
104+ barMarkInBar
104105 } = style ;
105106 let { barHeight, barBottom, barPadding } = style ;
106107 // const { col, row, dataValue: originalValue } = context;
@@ -128,9 +129,14 @@ export function createProgressBarCell(
128129
129130 const borderWidth = getQuadProps ( getProp ( 'borderLineWidth' , style , col , row , table ) ) ;
130131 const barPaddingTop = Math . max ( ( barPadding as number [ ] ) [ 0 ] , Math . ceil ( borderWidth [ 0 ] / 2 ) ) ;
131- const barPaddingRight = Math . max ( ( barPadding as number [ ] ) [ 1 ] , Math . floor ( borderWidth [ 1 ] / 2 ) ) ;
132+ let barPaddingRight = Math . max ( ( barPadding as number [ ] ) [ 1 ] , Math . floor ( borderWidth [ 1 ] / 2 ) ) ;
132133 const barPaddingBottom = Math . max ( ( barPadding as number [ ] ) [ 2 ] , Math . floor ( borderWidth [ 2 ] / 2 ) ) ;
133- const barPaddingLeft = Math . max ( ( barPadding as number [ ] ) [ 3 ] , Math . ceil ( borderWidth [ 3 ] / 2 ) ) ;
134+ let barPaddingLeft = Math . max ( ( barPadding as number [ ] ) [ 3 ] , Math . ceil ( borderWidth [ 3 ] / 2 ) ) ;
135+
136+ if ( showBarMark && barMarkWidth > 0 && barMarkPosition === 'right' && barMarkInBar === false ) {
137+ barPaddingRight += barMarkWidth ;
138+ barPaddingLeft += barMarkWidth ;
139+ }
134140
135141 contentWidth -= barPaddingRight + barPaddingLeft ;
136142 contentHeight -= barPaddingBottom + barPaddingTop ;
@@ -395,7 +401,7 @@ export function createProgressBarCell(
395401 if ( barMarkPosition === 'right' ) {
396402 const markLeft = barRightToLeft
397403 ? barRectPosi . left + barMarkWidth / 2
398- : barRectPosi . left + barRectPosi . width - barMarkWidth / 2 ;
404+ : barRectPosi . left + barRectPosi . width + ( barMarkInBar ? - barMarkWidth / 2 : barMarkWidth / 2 ) ;
399405 points . push ( { x : markLeft , y : barRectPosi . top } ) ;
400406 points . push ( { x : markLeft , y : barRectPosi . top + barRectPosi . height } ) ;
401407 } else if ( barMarkPosition === 'bottom' ) {
0 commit comments