From f9a23ba3f3b9442871f06f3bdb397ce7e3cfbab9 Mon Sep 17 00:00:00 2001 From: Philipp Wambach Date: Mon, 20 Jul 2020 17:50:52 +0200 Subject: [PATCH] feat(globe): add screenshot export --- .../globe-navigation/globe-navigation.tsx | 3 +- src/scripts/components/globe/globe.tsx | 7 +++- src/scripts/libs/download-screenshot.ts | 42 +++++++++++++++++++ 3 files changed, 50 insertions(+), 2 deletions(-) create mode 100644 src/scripts/libs/download-screenshot.ts diff --git a/src/scripts/components/globe-navigation/globe-navigation.tsx b/src/scripts/components/globe-navigation/globe-navigation.tsx index c516df828..5326220a5 100644 --- a/src/scripts/components/globe-navigation/globe-navigation.tsx +++ b/src/scripts/components/globe-navigation/globe-navigation.tsx @@ -8,6 +8,7 @@ import {DownloadIcon} from '../icons/download-icon'; import setGlobeProjectionAction from '../../actions/set-globe-projection'; import {projectionSelector} from '../../selectors/globe/projection'; import setFlyToAction from '../../actions/set-fly-to'; +import {downloadScreenshot} from '../../libs/download-screenshot'; import {GlobeProjection} from '../../types/globe-projection'; @@ -40,7 +41,7 @@ const GlobeNavigation: FunctionComponent = () => {