import React from "react" import { useSafeAreaInsets } from "react-native-safe-area-context"; import { View, Text, StyleSheet, TouchableHighlight, Image } from "react-native"; import { City, Weather } from "../data/stub"; type CityProps = { weather: Weather, } export function Details(props: CityProps){ const weather: Weather = props.weather const city = weather.city return ( {city.name} {city.longitude} - {city.latitude} {weather?.weatherType} {weather?.temperature}°C Ressenti {weather?.temperatureFeelsLike}°C HUMIDITY {weather?.humidity}% WIND SPEED {weather?.windSpeed} km/h PRESSURE {weather?.pressure} hPa VISIBILITY {weather?.visibility} km ); } const styles = StyleSheet.create({ name: { marginTop: 30, fontSize: 35, fontWeight: "bold" }, place: { marginBottom: 20, }, petitText: { fontSize: 15 }, image: { height: 100, width: 100 }, title: { fontWeight: "bold", fontSize: 18 }, temperature: { marginTop: 10, fontSize: 25, fontWeight: "600" }, petitTemp: { fontSize: 16, marginBottom: 35 }, weatherType: { fontSize: 17, marginBottom: 20 }, button: { height: 30, width: 30, marginTop: 13, alignSelf: "flex-end", margin: 5 }, supertruc: { flexDirection: "row" }, supertrucencore: { flexDirection: "column" }, petitImage: { height: 40, width: 40, marginRight: 7, marginTop: 15 }, imageHumidity: { height: 20, width: 20, marginLeft: 10 }, leftBox: { alignSelf: "flex-start", margin: 25, marginTop: 10, marginBottom: 5, height: 90, width: 150, flexDirection: "column", backgroundColor: "powderblue", borderRadius: 20 }, rightBox: { alignSelf: "flex-start", marginRight: 25, marginTop: 10, marginBottom: 5, height: 90, width: 150, flexDirection: "column", backgroundColor: "powderblue", borderRadius: 20 }, humidityText: { marginTop: 13, fontWeight: "bold", fontSize: 20, alignSelf: "center" }, text: { fontWeight: "normal", fontStyle: 'italic', fontSize: 10, alignSelf: "center", marginLeft: 7 }, imageEtTexte: { flexDirection: "row", marginTop: 13 }, boxes: { flexDirection: "row" } });