-
Notifications
You must be signed in to change notification settings - Fork 96
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
[FLAG-1018][EPIC] Tree cover gain 5y baseline year #4873
base: develop
Are you sure you want to change the base?
Conversation
@@ -24,7 +24,7 @@ export default { | |||
metaKey: 'umd_tree_cover_gain_from_height', | |||
dataType: 'gain', | |||
pendingKeys: ['threshold'], | |||
refetchKeys: ['threshold'], | |||
refetchKeys: ['threshold', 'baselineYear'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I never understood this, what do we use refetchKeys
for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sometimes we don't need to refetch because the first request get all info we need, so the only thing needed is filter the data displayed. However, for some widgets, every time the user changes the settings, we need to refetch passing a new value to the query. It should be always, but for some reason it's not.
"ANNUAL_ADM2_SUMMARY": "v20240404", | ||
"ANNUAL_ADM2_WHITELIST": "v20240404", | ||
"ANNUAL_ADM0_CHANGE": "v20240815", | ||
"ANNUAL_ADM0_SUMMARY": "v20240815", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
awesome, I will be able to use this version for my new widget as well 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This update is a cherry pick from #4869. It's the epic for your widget.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…d timestep canPlay in decode params
…e plantations widget
1244042
to
54aea59
Compare
[FLAG-1016] Priority 1: Update gain layer with 5-year baselines
Now we can set each API separatedly, making it easier to test different environments at once
…to separate indicators
…old for parameters separator
… to sync with the map
Change the way we compare baseline years to match the value in the Data API. e.g. ('2015-2020)
dc037cc
to
becc80c
Compare
When we use the parameter grouped as true, we set adm1 as the table instead of iso
deb33bf
to
aa68713
Compare
Overview
As a user, I can view gain data with baselines for every 5 years of data.
Acceptance criteria
Given that:
the user is viewing the “Global tree cover gain” widget on the dashboards, which is the version of this widget that appears when the globe is being viewed in the dashboards
the user is viewing the “Tree cover gain in [area] compared to other areas” widget on the dashboards, which is the version of this widget that appears when a country, region, or subregion is selected
the user is viewing the “Tree cover gain in [custom area name]” widget on the saved area dashboards, which is the version of this widget that appears for a saved custom area
the user is viewing the “Tree cover gain outside plantations in [area]” widget on the dashboards, which is available for the globe, countries, regions, and subregions
Global tree cover gain
We will add a “baseline year” dropdown option to the settings to this widget.
It will be below both the “forest type” and “land category” options.
It will have five options for a baseline: 2000 (default), 2005, 2010, 2015, and 2020.
The selected baseline year will be the [beginning year] in the new sentence below (see #2).
We will change the sentence from:
Tree cover gain in [area] compared to other areas
Just as we did for the global widget above, we will add a “baseline year” dropdown option to the settings to this widget.
It will be below both the “forest type” and “land category” options.
It will have five options for a baseline: 2000 (default), 2005, 2010, 2015, and 2020.
The selected baseline year will be the [beginning year] in the new sentence below (see #2).
We will change the sentence from:
Tree cover gain in [custom area name]
Just as we did for the global and subnational widgets above, we will add a “baseline year” dropdown option to the settings to this widget.
It will be below both the “forest type” and “land category” options.
It will have five options for a baseline: 2000 (default), 2005, 2010, 2015, and 2020.
The selected baseline year will be the [beginning year] in the new sentence below (see #2).
We will change the sentence from:
Tree cover gain outside plantations
We will add a “baseline year” dropdown option to the settings to this widget.
It will be below both the “forest type” and “land category” options.
It will have five options for a baseline: 2000 (default), 2005, 2010, 2015, and 2020.
The selected baseline year will be the [beginning year] in the new sentence below (see #2).
We will change the global sentence from:
Globally between 2000 and 2020, [percentage] of tree cover gain occurred outside of plantations.
Globally between [beginning year] and 2020, [percentage] of tree cover gain occurred outside of plantations.
We will change the national and subnational sentence from: