rclement / datasette-dashboards

Datasette plugin providing data dashboards from metadata

Home Page:https://datasette-dashboards-demo.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add relative date picker

rclement opened this issue · comments

Context

  • It would be nice to set a default value for date-based filters such as "Last Month", automatically adjusting the dashboard given the current date
  • When exploring metrics on a dashboard, selecting canonical date ranges is tedious (current day/month/quarter/semester/year, past day/month/quarter/semester/year)

Technical details

  • Native HTML date input components are basic and do not let select relative dates
  • Datasette offers column filters arguments for queries
  • Date Range Picker is a JS component providing extensive options for relative and range based date filtering

References

Other BI tools are providing extensive date range filtering with relative dates.

For instance here is how Metabase currently displays it:
Screenshot 2023-08-09 at 11 08 38
Screenshot 2023-08-09 at 11 09 11
Screenshot 2023-08-09 at 11 09 20