Skip to content

Commit

Permalink
Merge pull request #1493 from nextstrain/fix-narrative-filters
Browse files Browse the repository at this point in the history
Fix: narrative dataset filters
  • Loading branch information
jameshadfield committed Mar 25, 2022
2 parents 8cf96da + aa00480 commit ca59615
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/actions/recomputeReduxState.js
Original file line number Diff line number Diff line change
Expand Up @@ -786,6 +786,7 @@ export const createStateFromQueryOrJSONs = ({
metadata = {...oldState.metadata};
frequencies = {...oldState.frequencies};
controls = restoreQueryableStateToDefaults(controls);
controls = modifyStateViaMetadata(controls, metadata);
}

/* For the creation of state, we want to parse out URL query parameters
Expand Down
4 changes: 3 additions & 1 deletion src/reducers/controls.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export const getDefaultControlsState = () => {
layout: defaultLayout,
geoResolution: defaultGeoResolution,
filters: {},
filtersInFooter: [],
colorBy: defaultColorBy,
selectedBranchLabel: "none",
showTransmissionLines: true
Expand Down Expand Up @@ -67,7 +68,8 @@ export const getDefaultControlsState = () => {
canRenderBranchLabels: true,
analysisSlider: false,
geoResolution: defaults.geoResolution,
filters: {},
filters: defaults.filters,
filtersInFooter: defaults.filtersInFooter,
showDownload: false,
quickdraw: false, // if true, components may skip expensive computes.
mapAnimationDurationInMilliseconds: 30000, // in milliseconds
Expand Down

0 comments on commit ca59615

Please sign in to comment.