Skip to content
Discussion options

You must be logged in to vote

Thanks for sharing codes, you are setting colors perfect but you might not be using it charts component, you have to use it like following in chart-area-interactive.tsx -

const chartConfig = {
    visitors: {
        label: "Visitors",
    },
    desktop: {
        label: "Desktop",
        color: "var(--chart-1)",
    },
    mobile: {
        label: "Mobile",
        color: "var(--chart-2)",
    },
} satisfies ChartConfig;

You might be using --primary variable. So, use --chart-1 variable or define your own colors there.

Replies: 3 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@netnimit1998
Comment options

Comment options

You must be logged in to vote
1 reply
@dilkhush-raj
Comment options

Answer selected by lestan
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants