Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generic panels and named custom panels and panel layouts #551

Open
ezio-melotti opened this issue Dec 25, 2023 · 0 comments
Open

Generic panels and named custom panels and panel layouts #551

ezio-melotti opened this issue Dec 25, 2023 · 0 comments

Comments

@ezio-melotti
Copy link
Collaborator

ezio-melotti commented Dec 25, 2023

This issue outlines a few ideas related to the dashboard, panels, and panel layouts.

This comes from the desire of solving two somewhat competing goals:

  • Offer the user a wider variety of panels able to show specific information
  • Move towards a smaller number of more generic panels and graphs (from a coding point of view)

In short, the proposed solution is to make generic panels/graphs that supports a wide variety of different configurations and add/improve the ability to easily saving/loading any of these specific configuration.

Saving/loading panel type, section, and plotted items

Currently, for each panel in the dashboard, it's possible to select two things:

  • the panel type (e.g. Production/Consumption, Storage Ratios, etc.)
  • the "section" (e.g. CO2 Prod/Cons, Water Storage Ratios, etc.)

These selections will be remembered when saving/loading a custom panel layout from the dashboard menu. This allowed us to merge different panels into fewer ones while retaining the ability to save/load specific graphs. For example, we used to have different Prod/Cons panels for CO2, O2, energy, etc., but they got combined in a single Prod/Cons panel, with a dropdown that allows us to select the currency being plotted.

As we move towards even more genetic panels (e.g. the Agent Explorer panel), we need the ability to save/load even more specific selections. The following PRs are attempts to add a third selection to the aforementioned two, namely the plotted items:

In the following example you can see two Storage Ratios panels, one used to display the Crew Habitat and the Greenhouse atmospheres (the "sections").
image

By the default the graph includes all the gasses of the atmosphere, and the user can hide some of them. In the image, only H2O and CO2 are visible for the Crew Habitat and only H2 and CH4 are visible for the Greenhouse -- the other gasses are hidden. The above PR allows the user to save this custom panel layout. This effectively gives the users the ability to save two "new" panels that can be loaded up automatically: "H20/CO2 Crew Habitat Levels" and "H2/CH4 Greenhouse Levels".

Once #540 is merged and the same changes are applied to the other panels/graph, it will be possible to save/load any combination of three things:

  • the panel type (e.g. Production/Consumption, Storage Ratios, etc.)
  • the "section" (e.g. CO2 Prod/Cons, Water Storage Ratios, etc.)
  • the items being plotted (e.g. H2O and CO2 in the Crew Habitat atmosphere)

Adding named custom panels

Once this feature is implemented, the next step would be a way to create/save a custom panel and give it a name (like "H20/CO2 Crew Habitat Levels" and "H2/CH4 Greenhouse Levels"), so that it could be brought up easily while changing panels. New panels could be added both by us (for common and/or interesting graphs) and by the users themselves (if they care about something specific). This is a mockup to show a possible implementation:

image

image

Code-wise this can be implemented internally with a simple string like "StorageRatios:crew_habitat_small:H₂O|CO₂" and "StorageRatios:greenhouse_small:H₂|CH₄" following the format panel_name:section:plotted_items. This format is already being used to save/load custom panel layout.


Improved panel selection

As seen in the mockup above, currently panels are selected from a dropdown with their name. We now have about a dozen of panels, but if we let the users create more it might get difficult to find them. The selection process is also a bit clunky, with buttons and dropdowns.

This could be replaced by a side pane that will provide more space where to add additional information, like a short description of the panel or even an image, like shown in the following mockup:

image


Panel collections / Custom panel layouts

Finally, we could provide "collections" of panels. This could be done both in the form of a group of panels in the side pane (e.g. a selection of CO2-related panels under the "CO2 Monitoring" header) and as a specific layout that will load a selection of panels in the dashboard, replacing the currently selected panels.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant