coinforbarter-react-native
Version:
CoinForBarter ReactNative Library - Integrate cryptocurrency payments for goods and services in your Mobile App
36 lines (35 loc) • 1.73 kB
JavaScript
import React from 'react';
import { Logo } from '../logo';
import { Images } from '../../assets';
import { View, Text, Image, ScrollView } from 'react-native';
import tw from 'tailwind-react-native-classnames';
import { CoinForBarterBodyStyle } from './style';
export const Body = ({ children, logo, description, title }) => {
return (<View style={CoinForBarterBodyStyle.main}>
<ScrollView style={CoinForBarterBodyStyle.c4bBody}>
<View style={Object.assign(Object.assign({}, tw `w-full my-8`), CoinForBarterBodyStyle.c4bHeader)}>
<View style={tw `flex flex-row items-center justify-center w-full`}>
{logo ? <Logo title={title} url={logo} classStyles=""/> : null}
{title ? (<Text style={Object.assign({}, tw `text-xl my-0`)}>
{title}
</Text>) : null}
</View>
{description ? (<Text style={tw `text-center text-xs`}>{description}</Text>) : null}
</View>
<View style={Object.assign(Object.assign({}, tw `bg-white w-full p-4 `), CoinForBarterBodyStyle.middleBody)}>
{children}
</View>
<View style={tw `mt-8 flex flex-col justify-center items-center`}>
<View style={Object.assign(Object.assign({}, tw `bg-white py-2 px-4 flex flex-row justify-between items-center `), CoinForBarterBodyStyle.Lock)}>
<Image source={Images.Lock} style={tw ` mr-2 `}/>
<Text style={tw `text-sm ml-2`}>Secured by CoinForBarter</Text>
</View>
<View>
<Text style={tw `text-white text-xs text-center my-2 mb-8`}>
https://coinforbarter.com
</Text>
</View>
</View>
</ScrollView>
</View>);
};