It'd be good if the dashboard could be setup to customise itself based on the data read in. If we want users to just be able to select data by site then we just have markers and a popup detailing the site. If we want users to select by inlet then we create the buttons in the popup, if we want by instrument we have a couple of rows of buttons etc.
NOTE: I'll use source selection level here to mean selecting data by site or by inlet at a site etc
I've created a preliminary dashboard_config.json that can be read in by the dashboard that could control the setup of the markers / popups. See openghg/openghg#772 for the work on exporting this config file.
To implement this we'll need to
- read in the
dashboard_config.json file
- update the
createSourceKey function to create keys depending on the source selection level
- pass through the setting to the
LeafletMap component
- modify the
onClick so it's passed to inlet TextButton for inlet selection or the CircleMarker for site selection
- add some tests to cover this dynamic change of UI
It'd be good if the dashboard could be setup to customise itself based on the data read in. If we want users to just be able to select data by site then we just have markers and a popup detailing the site. If we want users to select by inlet then we create the buttons in the popup, if we want by instrument we have a couple of rows of buttons etc.
I've created a preliminary
dashboard_config.jsonthat can be read in by the dashboard that could control the setup of the markers / popups. See openghg/openghg#772 for the work on exporting this config file.To implement this we'll need to
dashboard_config.jsonfilecreateSourceKeyfunction to create keys depending on the source selection levelLeafletMapcomponentonClickso it's passed to inletTextButtonfor inlet selection or theCircleMarkerfor site selection