import React from "react"; import { View } from "react-native"; import Text from "react-native-text"; import { scale, verticalScale, moderateScale } from "react-native-size-matters"; import Size from "../../config/size"; const size = new Size(); import theme from "../../config/colors"; import { Fonts } from "../../config/fonts"; import { width, height } from "../../config/screen"; const dataLanguage = (data, value, lang) => { if (lang == "english") { switch (value) { case "name": return data.nameEn; break; } } else { switch (value) { case "name": return data.name; break; } } }; const FoodsRow = props => { return ( {dataLanguage(props.items.cuisine, "name", props.lang)} {dataLanguage(props.items.cuisine.restaurant, "name", props.lang)} Quantity: {props.items.count} HKD ${(props.items.price*props.items.count).toFixed(2)} ); }; export default FoodsRow;