diff --git a/src/components/market/MarketChart.vue b/src/components/market/MarketChart.vue index 4c87679..04ef3eb 100644 --- a/src/components/market/MarketChart.vue +++ b/src/components/market/MarketChart.vue @@ -101,7 +101,7 @@ const chartOptions = computed(() => { }, y: { display: true, - position: 'right', + position: 'right' as const, min: domain.min, max: domain.max, grid: { display: false }, diff --git a/src/pages/HomePage.vue b/src/pages/HomePage.vue index bbcfa3f..9eb392d 100644 --- a/src/pages/HomePage.vue +++ b/src/pages/HomePage.vue @@ -36,7 +36,9 @@ const nextMissionLines = computed(() => { let bestDiff = Number.POSITIVE_INFINITY let used = 0 for (let index = 0; index < words.length - 1; index += 1) { - used += words[index].length + (index > 0 ? 1 : 0) + const word = words[index] + if (!word) continue + used += word.length + (index > 0 ? 1 : 0) const diff = Math.abs(used - total / 2) if (diff < bestDiff) { bestDiff = diff