diff --git a/package-lock.json b/package-lock.json index d350da899a..695d6cd354 100644 --- a/package-lock.json +++ b/package-lock.json @@ -21,7 +21,6 @@ "@turf/bbox": "^6.5.0", "@turf/center": "^6.5.0", "@turf/helpers": "^6.5.0", - "@turf/intersect": "^6.5.0", "canvg": "^4.0.2", "filesize": "^10.1.2", "get-video-id": "^4.1.5", @@ -7681,30 +7680,6 @@ "url": "https://opencollective.com/turf" } }, - "node_modules/@turf/intersect": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/@turf/intersect/-/intersect-6.5.0.tgz", - "integrity": "sha512-2legGJeKrfFkzntcd4GouPugoqPUjexPZnOvfez+3SfIMrHvulw8qV8u7pfVyn2Yqs53yoVCEjS5sEpvQ5YRQg==", - "dependencies": { - "@turf/helpers": "^6.5.0", - "@turf/invariant": "^6.5.0", - "polygon-clipping": "^0.15.3" - }, - "funding": { - "url": "https://opencollective.com/turf" - } - }, - "node_modules/@turf/invariant": { - "version": "6.5.0", - "resolved": "https://registry.npmjs.org/@turf/invariant/-/invariant-6.5.0.tgz", - "integrity": "sha512-Wv8PRNCtPD31UVbdJE/KVAWKe7l6US+lJItRR/HOEW3eh+U/JwRCSUl/KZ7bmjM/C+zLNoreM2TU6OoLACs4eg==", - "dependencies": { - "@turf/helpers": "^6.5.0" - }, - "funding": { - "url": "https://opencollective.com/turf" - } - }, "node_modules/@turf/meta": { "version": "6.5.0", "resolved": "https://registry.npmjs.org/@turf/meta/-/meta-6.5.0.tgz", @@ -23521,15 +23496,6 @@ "semver-compare": "^1.0.0" } }, - "node_modules/polygon-clipping": { - "version": "0.15.7", - "resolved": "https://registry.npmjs.org/polygon-clipping/-/polygon-clipping-0.15.7.tgz", - "integrity": "sha512-nhfdr83ECBg6xtqOAJab1tbksbBAOMUltN60bU+llHVOL0e5Onm1WpAXXWXVB39L8AJFssoIhEVuy/S90MmotA==", - "dependencies": { - "robust-predicates": "^3.0.2", - "splaytree": "^3.1.0" - } - }, "node_modules/possible-typed-array-names": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.0.0.tgz", @@ -27775,11 +27741,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/robust-predicates": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/robust-predicates/-/robust-predicates-3.0.2.tgz", - "integrity": "sha512-IXgzBWvWQwE6PrDI05OvmXUIruQTcoMDzRsOd5CDvHCVLcLHMTSYvOK5Cm46kWqlV3yAbuSpBZdJ5oP5OUoStg==" - }, "node_modules/rollup": { "version": "2.79.1", "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.79.1.tgz", @@ -28967,11 +28928,6 @@ "node": ">= 6" } }, - "node_modules/splaytree": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/splaytree/-/splaytree-3.1.2.tgz", - "integrity": "sha512-4OM2BJgC5UzrhVnnJA4BkHKGtjXNzzUfpQjCO8I05xYPsfS/VuQDwjCGGMi8rYQilHEV4j8NBqTFbls/PZEE7A==" - }, "node_modules/split-on-first": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/split-on-first/-/split-on-first-1.1.0.tgz", diff --git a/package.json b/package.json index 53c7665fe2..0c30c27652 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,6 @@ "@turf/bbox": "^6.5.0", "@turf/center": "^6.5.0", "@turf/helpers": "^6.5.0", - "@turf/intersect": "^6.5.0", "canvg": "^4.0.2", "filesize": "^10.1.2", "get-video-id": "^4.1.5", diff --git a/src/storyMap/components/StoryMapForm.test.js b/src/storyMap/components/StoryMapForm.test.js index 1d18be9136..589a9d7f0f 100644 --- a/src/storyMap/components/StoryMapForm.test.js +++ b/src/storyMap/components/StoryMapForm.test.js @@ -217,6 +217,17 @@ beforeEach(() => { useAnalytics.mockReturnValue({ trackEvent: jest.fn(), }); + when(terrasoApi.requestGraphQL) + .calledWith(expect.stringContaining('query visualizationConfigs')) + .mockResolvedValue({ + visualizationConfigs: { + edges: [ + { + node: VISUALIZATION_CONFIG, + }, + ], + }, + }); }); const setup = async config => { @@ -823,18 +834,6 @@ test('StoryMapForm: Add data layer', async () => { }; mapboxgl.Map.mockReturnValue(map); - when(terrasoApi.requestGraphQL) - .calledWith(expect.stringContaining('query visualizationConfigs')) - .mockResolvedValue({ - visualizationConfigs: { - edges: [ - { - node: VISUALIZATION_CONFIG, - }, - ], - }, - }); - const { onSaveDraft } = await setup(BASE_CONFIG); const chapter1 = screen.getByRole('region', { @@ -856,7 +855,7 @@ test('StoryMapForm: Add data layer', async () => { await act(async () => fireEvent.click(addDataLayerButton)); const dataMapDialog = screen.getByRole('dialog', { - name: 'Add a data layer to Chapter 1', + name: 'Add a map layer to Chapter 1', }); const dataLayerItem = within(dataMapDialog).getByRole('listitem', { @@ -867,7 +866,7 @@ test('StoryMapForm: Add data layer', async () => { await act(async () => fireEvent.click(radioButton)); const addMapButton = within(dataMapDialog).getByRole('button', { - name: 'Add Map', + name: 'Add Map Layer', }); await act(async () => fireEvent.click(addMapButton));