From 7d215ee9d7301dc41e66ba1a9bbf795e5a7f4e28 Mon Sep 17 00:00:00 2001 From: YasinShaikh123 <123150391+YasinShaikh123@users.noreply.github.com> Date: Mon, 14 Oct 2024 18:44:20 +0530 Subject: [PATCH] charts pointer --- src/components/Doughnut/LineChart.jsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/Doughnut/LineChart.jsx b/src/components/Doughnut/LineChart.jsx index f98792a..961dd70 100644 --- a/src/components/Doughnut/LineChart.jsx +++ b/src/components/Doughnut/LineChart.jsx @@ -3,14 +3,15 @@ import React, { useState } from 'react'; import { Line } from 'react-chartjs-2'; import { Chart as ChartJS, CategoryScale, LinearScale, PointElement, LineElement, Title, Tooltip, Legend } from 'chart.js'; import { BsBorderWidth } from 'react-icons/bs'; -import { border, Box, Heading, Radio, RadioGroup, Stack } from '@chakra-ui/react'; +import { border, Box, Heading, Radio, RadioGroup, Stack, useColorMode } from '@chakra-ui/react'; import ChartsTabs from '../ChartsTabs'; // Register the components of Chart.js you need ChartJS.register(CategoryScale, LinearScale, PointElement, LineElement, Title, Tooltip, Legend); const LineChart = () => { - + + const { colorMode} = useColorMode(); const data = { labels: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], @@ -23,7 +24,7 @@ const LineChart = () => { // fill: true, tension: 0.3, pointRadius: 4, - pointBackgroundColor: '#232127', + pointBackgroundColor:colorMode === "light"? "#fff" :'#232127', pointBorderColor: '#978FED', pointHoverRadius: 5, pointHoverBackgroundColor: '#978FED', @@ -58,7 +59,6 @@ const LineChart = () => { titleColor: '#4B4B4B', bodyColor: '#4B4B4B', displayColors: false, - boxShadow:"3px 3px 3px #000", }, },