Change chart grid lines color

This commit is contained in:
Maciej Pędzich 2022-07-10 21:34:33 +01:00
parent 158099ba45
commit e4945e7648

View File

@ -27,6 +27,18 @@ const sinceDate = computed(() => {
const chartOptions = {
responsive: true,
scales: {
x: {
grid: {
color: 'rgba(255, 255, 255, 0.2)'
}
},
y: {
grid: {
color: 'rgba(255, 255, 255, 0.2)'
}
}
},
plugins: {
legend: {
display: false
@ -86,9 +98,13 @@ watch(chartPeriod, async () => await refresh());
<p v-else-if="error">
Something went wrong while fetching follwer growth data
</p>
<template v-else-if="data">
<Chart class="mt-3" type="line" :options="chartOptions" :data="data" />
</template>
<Chart
v-else-if="data"
class="mt-3"
type="line"
:options="chartOptions"
:data="data"
/>
</ClientOnly>
</NuxtLayout>
</template>