-
Notifications
You must be signed in to change notification settings - Fork 8
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
chore: Move basemap and selectedbasemap to redux #294
chore: Move basemap and selectedbasemap to redux #294
Conversation
This pull request is automatically being deployed by Amplify Hosting (learn more). |
Test cases execution result: Test Suites: 105 passed, 105 total Test Suites: 4 passed, 4 total |
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.
Looks good to me
const selectedBaseMapId = useAppSelector(selectSelectedBaseMapId); | ||
const selectedBaseMap = baseMaps.find((map) => map.id === selectedBaseMapId); |
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.
We could select necessary values in DeckGlWrapper
as it already depens on Redux
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.
- Removed props and selectors from comparison-side.tsx, debug-app.tsx, viewer-app.tsx:
const baseMaps = useAppSelector(selectBaseMaps);
const selectedBaseMapId = useAppSelector(selectSelectedBaseMapId);
const selectedBaseMap = baseMaps.find((map) => map.id === selectedBaseMapId);
...
showTerrain={selectedBaseMap?.id === "Terrain"}
mapStyle={selectedBaseMap?.mapUrl} - Added selectors to the deck-gl-wrapper.tsx:
const baseMaps = useAppSelector(selectBaseMaps);
const selectedBaseMapId = useAppSelector(selectSelectedBaseMapId);
const selectedBaseMap = baseMaps.find((map) => map.id === selectedBaseMapId);
const showTerrain=selectedBaseMap?.id === "Terrain";
const mapStyle=selectedBaseMap?.mapUrl; - Fixed 2 tests in the deck-gl-wrapper.spec.tsx
…/loaders.gl-showcases into move_basemap_to_redux2
No description provided.