carbon-design-system / carbon-addons-data-viz-react

DEPRECATED. Please use Carbon Charts instead
https://github.com/carbon-design-system/carbon-charts
26 stars 26 forks source link

Gauge graph doesn't change color. #118

Closed Luc-Olsthoorn closed 4 years ago

Luc-Olsthoorn commented 6 years ago

Gauge graph doesn't change color. It doesn't change color, and defaults to fill color

Detailed description

I am using: "carbon-addons-data-viz-react":"1.21.0", "carbon-components": "^9.0.0", "carbon-icons": "latest", "carbon-components-react": "6.12.0" The Guage graph works well, except it always has the same fill color. After I looked at the underlying code, I expected this to change out of the box(?), but it also doesn't work with user-defined values either ie. [{ low: 0, high: 50, color: '#4B8400' },{ low: 50, high: 75, color: '#EFC100' },{ low: 75, high: 100, color: '#FF5050' }]

Steps to reproduce the issue

import { connect } from 'react-redux'
import React from 'react';
import { GaugeGraph } from 'carbon-addons-data-viz-react';
const Main = ({ severity }) => {
  return (
    <div>
      <GaugeGraph  labelText = {"Severity"} valueText= {severity + " / 5" } amount={60} total={100}/>
    </div>
  )
}

Additional information

screen shot 2018-07-19 at 4 20 34 pm

I may be doing something completley dumb, but have spent quite a while trying to debug this! Thanks!

williamgoodhew commented 4 years ago

is there any update on this?

tw15egan commented 4 years ago

This library has been deprecated in favor of Carbon Charts