TimeLine initial setup #3301
TimeLine initial setup #3301offtherailz merged 1 commit intogeosolutions-it:c127_geonode_integrationfrom
Conversation
| /** | ||
| * when there is no timeline state rangeSelector(getState()) returns undefiend, so instead we use the timeData[id] range | ||
| */ | ||
| const dataRange = timeData.domain.split('--'); |
There was a problem hiding this comment.
Server may return also a list of values (corner cases, 1 element only or an empty list) you must consider also these 2 cases.
I suggest:
- in the case of list to get the first and the last
- in case of single value range should be something arbitrary like 1 day before - 1 day after the single value
- No data. 1 day before 1 day after today
There was a problem hiding this comment.
@offtherailz as I understand
loadRangeData(id, timeData, getState) is called in the "updateRangeDataOnRangeChange" epic.
in line 174
const layerIds = Object.keys(timeData).filter(id => timeData[id] && timeData[id].domain && isTimeDomainInterval(timeData[id].domain));
This filter removes :
[x] no data option (there is domain)
[x] single value option ( isTimeDomainInterval(domain) checks if domain.indexOf("--") > 0 ). "but not sure if this works for corners "
so it leaves the list option only. If my understanding is correct is there still a reason for checking these cases ?
There was a problem hiding this comment.
Good Point, querying the histogram is not needed in that case. So maybe initializing range is not needed.
We can only check if single values are shown. I'll check if an issue is present for this point.
Description
2 parts:
Issues
Please check if the PR fulfills these requirements
What kind of change does this PR introduce? (check one with "x", remove the others)
What is the current behavior? (You can also link to an open issue here)
see #3251
What is the new behavior?
When rendered, the plugin starts in a collapsed state ( loading pre-saved map or adding a timed layer ).
once the user click the (full size ) button the timeline is expanded and works normally.
Does this PR introduce a breaking change? (check one with "x", remove the other)
If this PR contains a breaking change, please describe the impact and migration path for existing applications: ...
Other information: