Skip to content

Commit ea8d897

Browse files
committed
Fix - VueUiHorizontalBar - Fix slight overflow of bottom bar #272
1 parent 524adb5 commit ea8d897

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/components/vue-ui-horizontal-bar.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -553,7 +553,11 @@ const parentLabelOffsets = computed(() => {
553553
const barHeight = computed(() => {
554554
const p = Math.max(0, ...parentLabelOffsets.value);
555555
const parentOffsets = p * parentLabelBlockHeight.value;
556-
return (HEIGHT.value - barCount.value * BAR_GAP.value - parentOffsets) / barCount.value;
556+
const innerHeight = HEIGHT.value - 24;
557+
return (
558+
(innerHeight - (barCount.value - 1) * BAR_GAP.value - parentOffsets) /
559+
barCount.value
560+
);
557561
});
558562
559563
const svg = computed(() => {

0 commit comments

Comments
 (0)