Fix map android :
Add: - screens/Maps/ Fix: - android/app/src/main/AndroidManifest.xml - app.config.js - app/(application)/(user)/maps/index.tsx - bun.lock - ios/HIPMIBadungConnect.xcodeproj/project.pbxproj - ios/HIPMIBadungConnect/Info.plist - ios/Podfile.lock - package.json ### No Issue
This commit is contained in:
28
screens/Maps/MapsView2.tsx
Normal file
28
screens/Maps/MapsView2.tsx
Normal file
@@ -0,0 +1,28 @@
|
||||
import { TextCustom, ViewWrapper } from "@/components";
|
||||
import Mapbox from "@rnmapbox/maps";
|
||||
import { View } from "react-native";
|
||||
|
||||
// Nonaktifkan telemetry (opsional, untuk privasi)
|
||||
Mapbox.setTelemetryEnabled(false);
|
||||
|
||||
// Gunakan style OSM gratis
|
||||
const MAP_STYLE_URL = "https://tiles.stadiamaps.com/styles/osm_bright.json";
|
||||
|
||||
// Atau gunakan MapLibre default:
|
||||
// const MAP_STYLE_URL = 'https://demotiles.maplibre.org/style.json';
|
||||
export default function MapsView2() {
|
||||
return (
|
||||
<>
|
||||
<ViewWrapper>
|
||||
<View style={{ flex: 1 }}>
|
||||
<Mapbox.MapView style={{ flex: 1 }}>
|
||||
<Mapbox.Camera
|
||||
centerCoordinate={[115.2126, -8.65]} // Bali
|
||||
zoomLevel={12}
|
||||
/>
|
||||
</Mapbox.MapView>
|
||||
</View>
|
||||
</ViewWrapper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user