From ab716e0c61a6319a37cc2f2281842bbe4bc06b86 Mon Sep 17 00:00:00 2001 From: Nishit Suwal <81785002+NSUWAL123@users.noreply.github.com> Date: Wed, 7 Aug 2024 22:00:27 +0545 Subject: [PATCH] refactor: reword Data Extract --> Map Features (#1736) * fix(dataExtract): rename data extract to map features * refactor: update wording of data extract no features error * refactor: update info about requirement for linestrings during splitting * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * refactor: tweak text for data extract explanation --------- Co-authored-by: Sam <78538841+spwoodcock@users.noreply.github.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- src/frontend/e2e/createproject.spec.ts | 6 +-- .../LayerSwitcher/index.js | 2 +- .../ProjectDetailsV2/ProjectOptions.tsx | 4 +- .../createnewproject/DataExtract.tsx | 40 +++++++++---------- .../createnewproject/SelectForm.tsx | 2 +- .../createnewproject/SplitTasks.tsx | 2 +- .../validation/DataExtractValidation.tsx | 2 +- .../src/constants/StepFormConstants.ts | 4 +- src/frontend/src/constants/blockerUrl.ts | 2 +- src/frontend/src/routes.jsx | 2 +- src/frontend/src/views/CreateNewProject.tsx | 4 +- 11 files changed, 33 insertions(+), 37 deletions(-) diff --git a/src/frontend/e2e/createproject.spec.ts b/src/frontend/e2e/createproject.spec.ts index 09834e6618..6220ff881c 100644 --- a/src/frontend/e2e/createproject.spec.ts +++ b/src/frontend/e2e/createproject.spec.ts @@ -70,11 +70,11 @@ test('Project Creation', async ({ browserName, page }) => { await page.getByLabel('buildings').click(); await page.getByRole('button', { name: 'NEXT' }).click(); - // 4. Data Extract Step - const dataExtractRadio = await page.getByText('Use OSM data extract'); + // 4. Map Features Step + const dataExtractRadio = await page.getByText('Use OSM map features'); await dataExtractRadio.click(); await expect(dataExtractRadio).toBeChecked(); - await page.getByRole('button', { name: 'Generate Data Extract' }).click(); + await page.getByRole('button', { name: 'Generate Map Features' }).click(); await page.getByRole('button', { name: 'NEXT' }).click(); // 5. Split Tasks Step diff --git a/src/frontend/src/components/MapComponent/OpenLayersComponent/LayerSwitcher/index.js b/src/frontend/src/components/MapComponent/OpenLayersComponent/LayerSwitcher/index.js index b3d0d16c78..a51f8859d2 100644 --- a/src/frontend/src/components/MapComponent/OpenLayersComponent/LayerSwitcher/index.js +++ b/src/frontend/src/components/MapComponent/OpenLayersComponent/LayerSwitcher/index.js @@ -235,7 +235,7 @@ const LayerSwitcherControl = ({ map, visible = 'osm', pmTileLayerData = null }) location.pathname.includes('project/') || location.pathname.includes('upload-area') || location.pathname.includes('select-category') || - location.pathname.includes('data-extract') || + location.pathname.includes('map-features') || location.pathname.includes('split-tasks') ) { const olZoom = document.querySelector('.ol-zoom'); diff --git a/src/frontend/src/components/ProjectDetailsV2/ProjectOptions.tsx b/src/frontend/src/components/ProjectDetailsV2/ProjectOptions.tsx index 859534c334..afc50cffd7 100644 --- a/src/frontend/src/components/ProjectDetailsV2/ProjectOptions.tsx +++ b/src/frontend/src/components/ProjectDetailsV2/ProjectOptions.tsx @@ -91,8 +91,8 @@ const ProjectOptions = ({ projectName }: projectOptionPropTypes) => { />