|
|
import React, {useState} from 'react'; |
|
|
import { |
|
|
View, |
|
|
StyleSheet, |
|
|
Dimensions, |
|
|
ScrollView, |
|
|
Text, |
|
|
Pressable, |
|
|
Image, |
|
|
} from 'react-native'; |
|
|
import tw from 'tailwind-react-native-classnames'; |
|
|
import Header from '../../components/Header'; |
|
|
import bgQr from './assets/bgQr.png'; |
|
|
import qrIcon from './assets/qr.png'; |
|
|
import alertIcon from './assets/alert.png'; |
|
|
import bookIcon from './assets/book.png'; |
|
|
|
|
|
const width = Dimensions.get('window').width; |
|
|
|
|
|
function Activation(props) { |
|
|
const [formData, setFormData] = useState({ |
|
|
title: null, |
|
|
department: null, |
|
|
message: null, |
|
|
file: null, |
|
|
}); |
|
|
|
|
|
const onChange = (name, value) => { |
|
|
setFormData({...formData, [name]: value}); |
|
|
}; |
|
|
|
|
|
return ( |
|
|
<ScrollView |
|
|
contentContainerStyle={styles.contentContainerStyle} |
|
|
style={[tw.style('bg-white flex flex-col'), {width: width}]}> |
|
|
<Header |
|
|
background={bgQr} |
|
|
title={'فعالسازی کتاب دیجیتال'} |
|
|
description={''} |
|
|
icon={qrIcon} |
|
|
/> |
|
|
<View style={tw.style('flex flex-row w-full flex-wrap p-2')}> |
|
|
<View style={tw.style('w-full flex flex-row justify-center mb-7')}> |
|
|
<Image source={bookIcon} style={[{width: 113, height: 113}]} /> |
|
|
</View> |
|
|
<Pressable |
|
|
style={[ |
|
|
tw.style( |
|
|
'w-full rounded-md flex flex-row justify-end items-center py-3.5 px-3', |
|
|
), |
|
|
{backgroundColor: '#196EC01a'}, |
|
|
]}> |
|
|
<Text |
|
|
style={[ |
|
|
tw.style('text-right flex-1'), |
|
|
{color: '#275077', fontSize: width / 30}, |
|
|
]}> |
|
|
دانش آموز گرامی پس از خرید فیزیکی کتاب، یک کارت فعالسازی در درون |
|
|
کتاب قرار داده شده که شما میتوانید با وارد کردن کد در قسمت زیر و یا |
|
|
اسکن کد QR با دوربین موبایل خود اقدام به فعالسازی امکانات ویژه برای |
|
|
کتاب خود نمائید |
|
|
</Text> |
|
|
<View style={tw.style('p-2')}> |
|
|
<Image |
|
|
source={alertIcon} |
|
|
style={{width: 30, height: 30, marginLeft: 5}} |
|
|
/> |
|
|
</View> |
|
|
</Pressable> |
|
|
</View> |
|
|
</ScrollView> |
|
|
); |
|
|
} |
|
|
|
|
|
// Later on in your styles.. |
|
|
const styles = StyleSheet.create({ |
|
|
contentContainerStyle: { |
|
|
paddingBottom: 50, |
|
|
alignItems: 'flex-end', |
|
|
}, |
|
|
container: { |
|
|
width: Dimensions.get('window').width, |
|
|
backgroundColor: 'white', |
|
|
flexDirection: 'column', |
|
|
paddingVertical: 5, |
|
|
paddingHorizontal: 10, |
|
|
}, |
|
|
}); |
|
|
|
|
|
export default Activation;
|
|
|
|