Integrasi Map Business

Add:
 components/Map/MapSelected.tsx
        components/_ShareComponent/GridTwoView.tsx
        service/api-client/api-maps.ts
utils/openInDeviceMaps.ts

Fix:
 modified:   app/(application)/(user)/maps/[id]/edit.tsx
        modified:   app/(application)/(user)/maps/create.tsx
        modified:   app/(application)/(user)/maps/index.tsx
        modified:   app/(application)/(user)/portofolio/[id]/index.tsx
        modified:   components/Map/MapCustom.tsx
        modified:   screens/Portofolio/BusinessLocationSection.tsx
        modified:   screens/Portofolio/DataPortofolio.tsx
        modified:   screens/Portofolio/ListPage.tsx

### No issue
This commit is contained in:
2025-10-13 17:46:47 +08:00
parent 0e7b29bb15
commit f750d158be
12 changed files with 907 additions and 77 deletions

View File

@@ -1,5 +1,7 @@
// components/MapComponent.js
import API_IMAGE from "@/constants/api-storage";
import { Image } from "expo-image";
import React from "react";
import { DimensionValue, StyleSheet, View } from "react-native";
import MapView, { Marker } from "react-native-maps";
@@ -10,6 +12,9 @@ interface MapComponentProps {
latitudeDelta?: number;
longitudeDelta?: number;
height?: DimensionValue;
namePin?: string;
imageId?: string;
onPress?: () => void;
}
const MapCustom = ({
@@ -18,6 +23,9 @@ const MapCustom = ({
latitudeDelta = 0.1,
longitudeDelta = 0.1,
height = 300,
namePin = "Bali",
imageId,
onPress,
}: MapComponentProps) => {
const initialRegion = {
latitude,
@@ -40,9 +48,22 @@ const MapCustom = ({
latitude,
longitude,
}}
title="Bali"
description="Badung, Bali, Indonesia"
/>
title={namePin}
onPress={onPress}
// Gunakan gambar kustom jika tersedia
>
<View style={{}}>
<Image
source={{ uri: API_IMAGE.GET({ fileId: imageId as string }) }}
style={{
width: 30,
height: 30,
borderRadius: 100,
borderWidth: 1,
}}
/>
</View>
</Marker>
</MapView>
</View>
);