Skip to content
Snippets Groups Projects
details.js 1.32 KiB
Newer Older
import React from "react";
Anael Lacour's avatar
Anael Lacour committed
import { View, Text, StyleSheet, Button,ScrollView} from "react-native";
import  colors from '../../../colors'
import styled from "styled-components/native";
Anael Lacour's avatar
Anael Lacour committed
import InsideRoom from '../../components/InsideRoom'
Anael Lacour's avatar
Anael Lacour committed
import ImageCarousel from '../../components/Carousel'
Anael Lacour's avatar
Anael Lacour committed
import Review from '../../components/review'
Anael Lacour's avatar
Anael Lacour committed
export default function Detail (props) {
  const {route,navigation}=props

Anael Lacour's avatar
Anael Lacour committed
  console.log(route.params.room)
  const goTo = () => navigation.navigate("stackMap");
Anael Lacour's avatar
Anael Lacour committed
    <ScrollView
      contentContainerStyle={{ alignItems: 'center' }}
      style={{ flex: 1, width: '100%' }}
      showsVerticalScrollIndicator={false}
    >

Anael Lacour's avatar
Anael Lacour committed

      <Text>{route.params.room.name}</Text>
      <View style={styles.carousel} >
Anael Lacour's avatar
Anael Lacour committed
      <ImageCarousel   />
      </View>
Anael Lacour's avatar
Anael Lacour committed
      <View>
Anael Lacour's avatar
Anael Lacour committed
        <View style={styles.container2}>
Anael Lacour's avatar
Anael Lacour committed
      <InsideRoom {...props} />
Anael Lacour's avatar
Anael Lacour committed
        </View>
        <View>
          <Review/>

        </View>
      <Button onPress={goTo} title={`Go to maps`} />
Anael Lacour's avatar
Anael Lacour committed
      </View>
Anael Lacour's avatar
Anael Lacour committed
    </ScrollView>

  );
}

const styles = StyleSheet.create({
  container: {
    flex: 1,
    backgroundColor: "azure",
    alignItems: "center",
    justifyContent: "center",
Anael Lacour's avatar
Anael Lacour committed
  },
Anael Lacour's avatar
Anael Lacour committed
  container2: {
    flex: 1,
    backgroundColor: "#F5F8FF",
    alignItems: "center",
    justifyContent: "center",
  },
Anael Lacour's avatar
Anael Lacour committed
  carousel: {