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

Compare two countries / zones. #7225

Open
steren opened this issue Sep 22, 2024 · 3 comments
Open

Compare two countries / zones. #7225

steren opened this issue Sep 22, 2024 · 3 comments

Comments

@steren
Copy link
Contributor

steren commented Sep 22, 2024

Very often, my goal of opening ElectricyMaps is to be able to compare how the energy policy of two country / zone translates to carbon emissions. (Typically, comparing France and Germany is eye opening to folks having doubts about nuclear energy)

I'd be great if ElectricityMaps could allow me to select multiple countries / zones and display side by side information

This is an advanced use case, so the implementation shouldn't clutter the default UI.

Suggestion for how to achieve this elegantly:

  • On desktop: Ctrl+click
  • On mobile: long tap

I suggest being opinionated and only allow comparing 2 or 3 countries, not N.

Not all information would need to be present, but energy breakdown would ne critical to understand the emissions.

Comparing should also make sure the times compared are local time (as the default), and potentially allow to switch to absolute time.

@madsnedergaard
Copy link
Member

Thanks for sharing @steren!
This is definitely a feature that would be great and that we'd love to eventually add (it's something we've considered for a while).

As you're probably aware, it does require quite some work both technically and on the UX side, so it's great to get more details about why it matters to you and how you could see it working :)

@vrkannan
Copy link

vrkannan commented Dec 3, 2024

Hi, we are interested in working on this issue and contributing to the project. Could you provide us with some guidance or starting points in the project code for both the back-end and UI that would help us get started? Specifically, we’d like to understand:

  • Any key back-end files or modules responsible for data fetching and synchronization for regions.

  • Relevant front-end components or structures where the UI changes for the comparison feature might integrate best.

Additionally, if there are any existing design considerations, API documentation, or similar features we should look into before starting, we’d appreciate it if you could point us in the right direction. Thank you!

@VIKTORVAV99
Copy link
Member

@vrkannan I love that you are interested in contributing to our project but I am not sure this is the place to start, for a few reasons.

You won't have and will not get access to the backend. With that said I don't think there are any changes that need to happen for this to work, however this API is not documented as it's for internal use only.

Relevant front end components resolves around the entire left panel, charts and tooltips. While there shouldn't be much changes needed here in theory I don't know how it looks in practice. Data fetching and state management would also need to be looked at.

Designs for this feature has not been finalized yet and there are a few different ideas that has been looked at internally, it mainly resolves around how to make a design that works both for mobile and desktop.

We would still love your contributions but I think starting with something smaller so you get to know the codebase a bit better would benefit both you and us before you start tackling something like this. I hope that makes sense!

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

4 participants