diff --git a/src/chart/bar/PictorialBarView.ts b/src/chart/bar/PictorialBarView.ts index c9460daac7..0872d7b62a 100644 --- a/src/chart/bar/PictorialBarView.ts +++ b/src/chart/bar/PictorialBarView.ts @@ -341,7 +341,7 @@ function prepareBarLength( // if 'pxSign' means sign of pixel, it can't be zero, or symbolScale will be zero // and when borderWidth be settled, the actual linewidth will be NaN - outputSymbolMeta.pxSign = boundingLength > 0 ? 1 : -1; + outputSymbolMeta.pxSign = boundingLength >= 0 ? 1 : -1; } function convertToCoordOnAxis(axis: Axis2D, value: number) { diff --git a/test/pictorial-zero-value.html b/test/pictorial-zero-value.html index 49935bb2bb..7a7b924895 100644 --- a/test/pictorial-zero-value.html +++ b/test/pictorial-zero-value.html @@ -32,6 +32,7 @@
+ + + + +