react-google-charts icon indicating copy to clipboard operation
react-google-charts copied to clipboard

How to provide colour manually for the gantt chart ?

Open vivek7890 opened this issue 6 years ago • 3 comments
trafficstars

Can we provide colour manually for the gantt chart and also if we can customized left aligned text inside each horizontal bar itself? If yes how can we do it? Can you give one example?

vivek7890 avatar Jun 26 '19 11:06 vivek7890

              <Chart
                chartType="Gantt"
                loader={<div>Loading Chart</div>}
                data={series}
                width="100%"
                options={{
                  height: height,
                  gantt: {
                    trackHeight: trackHeight,
                    palette: [
                      {
                        "color": theme.palette.info,
                        "dark": theme.palette.info.dark,
                        "light": theme.palette.info.light
                      },
                      {
                        "color": theme.palette.success,
                        "dark": theme.palette.success.dark,
                        "light": theme.palette.success.light
                      },
                      {
                        "color": theme.palette.secondary,
                        "dark": theme.palette.secondary.dark,
                        "light": theme.palette.secondary.light
                      }
                    ]
                  }
                }}
                chartEvents={chartEvents}
              />

this works however, the colors are still not based on the specific item I'd want to color.

thellimist avatar Dec 14 '19 16:12 thellimist

Thanks @thellimist 🙏 !

rakannimer avatar Dec 15 '19 11:12 rakannimer

Am I able to color the specific item I'd want to color?

pohsiu avatar Nov 09 '20 02:11 pohsiu