Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

140
Views
How can I make the legend change colors when unselected in React-Chartjs

I have a bar chart and I made some edits to the legend, but there is one I'm struggling to add in.

I have an onClick action that makes the chart only show one dataset and I put the sum of the dataset values next to the legend labels using generateLabels, and all I need now is to make the unselected labels become a lighter tone of color instead of having a strikethrough line but I've been looking everywhere for a solution but I can't find it.

This is the chart I'm working on: https://codesandbox.io/s/agitated-christian-0byxz

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!