Commit d16364c7 by tungnq

TODO: Tiến hành chỉnh sửa giao diện

parent b891c912
......@@ -23,7 +23,7 @@ const styles = StyleSheet.create({
flexDirection:'row',
alignItems:'center',
justifyContent:'center',
marginBottom:15,
marginBottom:5,
},
containerTextItemLeft:{
flex:3,
......@@ -32,9 +32,13 @@ const styles = StyleSheet.create({
},
containerTextItemRight:{
flex:3,
flexDirection:'row',
alignItems:'center',
justifyContent:'center',
marginRight:15
},
sizedBox:{
flex:1
flex:3
},
text:{
......
......@@ -9,13 +9,20 @@ import {
import Header from '../../../../components/Header/Header';
import R from '../../../../assets/R';
import styles from './style';
import * as SCREENNAME from '../../../../routers/ScreenNames';
import {useNavigation} from '@react-navigation/native';
import VersionCheck from '../../../../components/VersionCheck';
import CheckBox from '../../../../components/CheckBox';
const DetailStudentView = props => {
const {student, onCheckboxChange} = props;
const navigate = useNavigation();
const getStatusColor = status => {
const statusColors = {
'Đang học': '#4CAF50',
'Cảnh cáo': '#FF9800',
'Thôi học': '#F44336',
};
return statusColors[status] || '#9E9E9E';
};
const statusColor = getStatusColor(student.status);
return (
<SafeAreaView style={styles.container}>
<Header title={'Nguyễn Minh Đức - 2598671'} isBack />
......@@ -27,7 +34,10 @@ const DetailStudentView = props => {
</View>
<View style={styles.sizedBox}></View>
<View style={styles.containerTextItemRight}>
<Text style={styles.text}>Tình trng: Đang hc</Text>
<Text style={[styles.text]}>
Tình trng:
</Text>
<Text style={[styles.text,{color:statusColor}]}>{student.status}</Text>
</View>
</View>
{/*Row 2*/}
......@@ -156,7 +166,7 @@ const DetailStudentView = props => {
</Text>
</View>
<View style={{flex: 3}}>
<View style={{flex: 3, flexDirection:'row'}}>
<Text
style={[
{
......@@ -166,8 +176,9 @@ const DetailStudentView = props => {
color: R.colors.black,
},
]}>
Tình trng: Đang hc
Tình trng:
</Text>
<Text style={[styles.text,{color:statusColor}]}>{student.status}</Text>
</View>
</View>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment