forked from cemaden-educacao/WPD-MobileApp
GabrielTrettel
4 years ago
3 changed files with 40 additions and 8 deletions
-
27src/app/components/MapMarker.js
-
8src/app/hooks/selectFromDB.js
-
13src/app/screens/MapFeedScreen.js
@ -0,0 +1,27 @@ |
|||
import React from "react"; |
|||
import { View, StyleSheet, Image } from "react-native"; |
|||
import MapView from "react-native-maps"; |
|||
|
|||
const markerSize = 30; |
|||
|
|||
export default function MapMarker({ ID, title, image, coordinate, ...props }) { |
|||
console.log(ID); |
|||
return ( |
|||
<MapView.Marker key={ID} coordinate={coordinate} title={title} {...props}> |
|||
<View> |
|||
<Image style={styles.markerPoint} source={image} resizeMode="stretch" /> |
|||
</View> |
|||
</MapView.Marker> |
|||
); |
|||
} |
|||
|
|||
const styles = StyleSheet.create({ |
|||
markerPoint: { |
|||
alignSelf: "center", |
|||
height: markerSize, |
|||
width: markerSize, |
|||
}, |
|||
title: { |
|||
fontWeight: "400", |
|||
}, |
|||
}); |
Write
Preview
Loading…
Cancel
Save
Reference in new issue