Skip to content

Commit

Permalink
🐛 (stacked bar/area) show timeline on table tab
Browse files Browse the repository at this point in the history
  • Loading branch information
sophiamersmann committed Apr 8, 2024
1 parent 4d398a7 commit 9fbb01a
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions packages/@ourworldindata/grapher/src/core/Grapher.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1427,11 +1427,17 @@ export class Grapher
case GrapherTabOption.map:
return !this.map.hideTimeline

// use the chart-level `hideTimeline` option for the table, too
case GrapherTabOption.table:
// use the chart-level `hideTimeline` option
case GrapherTabOption.chart:
return !this.hideTimeline

// use the chart-level `hideTimeline` option for the table, with some exceptions
case GrapherTabOption.table:
// always show the timeline for stacked bar/area charts and line charts
if (this.isStackedBar || this.isStackedArea || this.isLineChart)
return true
return !this.hideTimeline

default:
return false
}
Expand Down

0 comments on commit 9fbb01a

Please sign in to comment.