From fe01acf93da680b8722336ed5bd5b2fa0ea78b7d Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 15:08:27 +0545 Subject: [PATCH 1/8] fix(main): update helper text --- src/mapper/src/lib/components/map/main.svelte | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mapper/src/lib/components/map/main.svelte b/src/mapper/src/lib/components/map/main.svelte index b1e465b67b..11c2e6cf62 100644 --- a/src/mapper/src/lib/components/map/main.svelte +++ b/src/mapper/src/lib/components/map/main.svelte @@ -464,8 +464,8 @@ {#if projectSetupStep === projectSetupStepEnum['task_selection']} -
-

please select a task / feature for mapping

+
+

click on a task to select a feature for mapping

{/if} From 77c0aa7bd69f51e09010bb6d9ca659d0d6504d5c Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 15:50:08 +0545 Subject: [PATCH 2/8] fix(exploreProjectCard): navigate to mapper if mobile device else project page --- .../components/home/ExploreProjectCard.tsx | 23 ++++++------------- 1 file changed, 7 insertions(+), 16 deletions(-) diff --git a/src/frontend/src/components/home/ExploreProjectCard.tsx b/src/frontend/src/components/home/ExploreProjectCard.tsx index f46d66697d..79f61f2acf 100755 --- a/src/frontend/src/components/home/ExploreProjectCard.tsx +++ b/src/frontend/src/components/home/ExploreProjectCard.tsx @@ -6,7 +6,6 @@ import { projectType } from '@/models/home/homeModel'; import CoreModules from '@/shared/CoreModules'; import AssetModules from '@/shared/AssetModules'; import { useAppSelector } from '@/types/reduxTypes'; -import Button from '@/components/common/Button'; //Explore Project Card Model to be rendered in home view export default function ExploreProjectCard({ data }: { data: projectType }) { @@ -20,9 +19,14 @@ export default function ExploreProjectCard({ data }: { data: projectType }) { onClick={() => { const project: projectType = data; dispatch(HomeActions.SetSelectedProject(project)); - navigate(`/project/${data.id}`); + const isMobile = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent); + if (isMobile) { + window.location.href = `/mapnow/${data.id}`; + } else { + navigate(`/project/${data.id}`); + } }} - className="hover:fmtm-bg-red-50 hover:fmtm-shadow-xl fmtm-duration-500 fmtm-rounded-lg fmtm-border-[1px] fmtm-border-solid fmtm-border-[#706E6E] fmtm-bg-white fmtm-p-4 fmtm-max-h-fit" + className="hover:fmtm-bg-red-50 hover:fmtm-shadow-xl fmtm-duration-500 fmtm-rounded-lg fmtm-border-[1px] fmtm-border-solid fmtm-border-[#706E6E] fmtm-bg-white fmtm-p-4 fmtm-max-h-fit fmtm-cursor-pointer" >
@@ -87,19 +91,6 @@ export default function ExploreProjectCard({ data }: { data: projectType }) { {/* Contribution Progress Bar */}
- {/* Start Mapping Button */} -
); From 9625af88279114f2ff6ec38b57858563dba9bd0e Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 15:52:41 +0545 Subject: [PATCH 3/8] fix(projectDetailsV2): remove start mapping button --- src/frontend/src/views/ProjectDetailsV2.tsx | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/src/frontend/src/views/ProjectDetailsV2.tsx b/src/frontend/src/views/ProjectDetailsV2.tsx index b1cb292918..8c4978c540 100644 --- a/src/frontend/src/views/ProjectDetailsV2.tsx +++ b/src/frontend/src/views/ProjectDetailsV2.tsx @@ -466,17 +466,6 @@ const ProjectDetailsV2 = () => { className="!fmtm-text-sm !fmtm-pr-2 fmtm-bg-white" /> -
-
From 007cd1ec06e4fab9848bc0da87a25300b8fdf12e Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 16:26:41 +0545 Subject: [PATCH 4/8] fix(environment): update action text --- src/frontend/src/environment.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frontend/src/environment.ts b/src/frontend/src/environment.ts index ed07b586e6..d943679eb8 100755 --- a/src/frontend/src/environment.ts +++ b/src/frontend/src/environment.ts @@ -12,7 +12,7 @@ export default { tasksStatus: [ { label: 'UNLOCKED_TO_MAP', - action: [{ key: 'Start Mapping', value: 'MAP', btnBG: 'red' }], + action: [{ key: 'Assign To Mapper', value: 'MAP', btnBG: 'red' }], btnBG: 'red', }, { From 0bc0ccaff71b62b657b65d14f4455a54ba4bd246 Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 17:15:41 +0545 Subject: [PATCH 5/8] feat(assetModules): add sync icon --- src/frontend/src/shared/AssetModules.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/frontend/src/shared/AssetModules.js b/src/frontend/src/shared/AssetModules.js index de158e1cc8..1d81e26874 100755 --- a/src/frontend/src/shared/AssetModules.js +++ b/src/frontend/src/shared/AssetModules.js @@ -90,6 +90,7 @@ import { ChevronLeft as ChevronLeftIcon, RotateLeft as RotateLeftIcon, RotateRight as RotateRightIcon, + Sync as SyncIcon, } from '@mui/icons-material'; import LockPng from '@/assets/images/lock.png'; import RedLockPng from '@/assets/images/red-lock.png'; @@ -190,4 +191,5 @@ export default { ChevronLeftIcon, RotateLeftIcon, RotateRightIcon, + SyncIcon, }; From 01e58018f52a0ef17a222dfbd2a2038c77dcad5f Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 17:21:25 +0545 Subject: [PATCH 6/8] feat(projectDetailsV2): sync status button add to update entity status --- src/frontend/src/views/ProjectDetailsV2.tsx | 23 +++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/src/frontend/src/views/ProjectDetailsV2.tsx b/src/frontend/src/views/ProjectDetailsV2.tsx index 8090511674..9a83eea8dc 100644 --- a/src/frontend/src/views/ProjectDetailsV2.tsx +++ b/src/frontend/src/views/ProjectDetailsV2.tsx @@ -67,6 +67,7 @@ const ProjectDetailsV2 = () => { const taskModalStatus = CoreModules.useAppSelector((state) => state.project.taskModalStatus); const authDetails = CoreModules.useAppSelector((state) => state.login.authDetails); const entityOsmMap = useAppSelector((state) => state?.project?.entityOsmMap); + const entityOsmMapLoading = useAppSelector((state) => state?.project?.entityOsmMapLoading); useEffect(() => { if (state.projectInfo.name) { @@ -247,8 +248,12 @@ const ProjectDetailsV2 = () => { } }, [taskModalStatus]); - useEffect(() => { + const getEntityStatusList = () => { dispatch(GetEntityStatusList(`${import.meta.env.VITE_API_URL}/projects/${projectId}/entities/statuses`)); + }; + + useEffect(() => { + getEntityStatusList(); }, []); return ( @@ -455,7 +460,7 @@ const ProjectDetailsV2 = () => { popupId="locked-popup" className="fmtm-w-[235px]" /> -
+
+
+
From aee903abebd10722ba3c998c6ac5d30f899617be Mon Sep 17 00:00:00 2001 From: NSUWAL123 Date: Mon, 30 Dec 2024 17:39:10 +0545 Subject: [PATCH 7/8] fix(projectDetailsV2): remove qrcode component --- src/frontend/src/views/ProjectDetailsV2.tsx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/frontend/src/views/ProjectDetailsV2.tsx b/src/frontend/src/views/ProjectDetailsV2.tsx index 9a83eea8dc..a8f79fe0cf 100644 --- a/src/frontend/src/views/ProjectDetailsV2.tsx +++ b/src/frontend/src/views/ProjectDetailsV2.tsx @@ -34,9 +34,7 @@ import { useAppSelector } from '@/types/reduxTypes'; import Comments from '@/components/ProjectDetailsV2/Comments'; import { Geolocation } from '@/utilfunctions/Geolocation'; import Instructions from '@/components/ProjectDetailsV2/Instructions'; -import { CustomCheckbox } from '@/components/common/Checkbox'; import useDocumentTitle from '@/utilfunctions/useDocumentTitle'; -import QrcodeComponent from '@/components/QrcodeComponent'; const ProjectDetailsV2 = () => { useDocumentTitle('Project Details'); @@ -485,9 +483,6 @@ const ProjectDetailsV2 = () => { className={`!fmtm-text-sm !fmtm-pr-2 fmtm-bg-white ${entityOsmMapLoading && 'fmtm-cursor-not-allowed'}`} />
-
- -
Date: Mon, 30 Dec 2024 17:40:41 +0545 Subject: [PATCH 8/8] fix(mapControlComponent): fix map control alignment --- .../src/components/ProjectDetailsV2/MapControlComponent.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frontend/src/components/ProjectDetailsV2/MapControlComponent.tsx b/src/frontend/src/components/ProjectDetailsV2/MapControlComponent.tsx index 439d2717ec..4c60c0de47 100644 --- a/src/frontend/src/components/ProjectDetailsV2/MapControlComponent.tsx +++ b/src/frontend/src/components/ProjectDetailsV2/MapControlComponent.tsx @@ -76,7 +76,7 @@ const MapControlComponent = ({ map, projectName, pmTileLayerUrl }: mapControlCom }; return ( -
+
{btnList.map((btn) => (