evidence icon indicating copy to clipboard operation
evidence copied to clipboard

Chart Drilldowns

Open ItsMeBrianD opened this issue 1 year ago • 3 comments

@hughess or @archiewood please add more detail

ItsMeBrianD avatar Jun 24 '24 15:06 ItsMeBrianD

@hughess @archiewood

I was curious if the idea was for the link prop addition, do we want a link button (maybe below the graph), or the user to click the graph to activate the link?

Haven't looked into it yet, but concerns with the graph being clicked may affect the ability to interact with other graph components

e.g hovering over line image

kwongz avatar Jun 25 '24 14:06 kwongz

Maybe a link button/ or text with chevron in below graph image

kwongz avatar Jun 25 '24 15:06 kwongz

@kwongz this would be clicking on the chart itself - e.g., click on a line and it navigates to a page you specify.

Similar to the way links work in DataTable, where there is a link prop which accepts a column.

And the user populates a link in their SQL.

So the dataset might be:

date         |   sales  |   link
2024-01-01   |   1400   |   '/sales-detail/2024-01-01'
2024-01-02   |   2400   |   '/sales-detail/2024-01-02'
2024-01-03   |   1500   |   '/sales-detail/2024-01-03'
2024-01-04   |   1700   |   '/sales-detail/2024-01-04'
2024-01-05   |   1900   |   '/sales-detail/2024-01-05'

In the chart:

<LineChart
   data={sales_data}
   x=date
   y=sales
   link=link
/>

hughess avatar Jun 25 '24 15:06 hughess