diff --git a/src/features/deck/components/BarChart.vue b/src/features/deck/components/BarChart.vue index e3c2fdf..7fa1e90 100644 --- a/src/features/deck/components/BarChart.vue +++ b/src/features/deck/components/BarChart.vue @@ -2,24 +2,26 @@ import { computed } from 'vue' import { palette, money } from '../data' +// Note: Vue casts an absent Boolean prop to `false`, so a "showValues" default +// of true isn't possible without a runtime default — invert it to hideValues. const props = defineProps<{ items: readonly { label: string; amount: number; color: string }[] - showValues?: boolean + hideValues?: boolean }>() const max = computed(() => Math.max(...props.items.map((i) => i.amount), 1))