Commit 4f26555d authored by Trisno's avatar Trisno

balik ke design awal top up info

parent c352d7d8
......@@ -3,6 +3,7 @@ import React from 'react';
import { ScrollView, StyleSheet, Text, View, Image } from 'react-native';
import { TouchableOpacity } from 'react-native-gesture-handler';
import HTML from 'react-native-render-html';
import { Collapse, CollapseHeader, CollapseBody, AccordionList } from 'accordion-collapse-react-native'
import { getStatusBarHeight } from 'react-native-status-bar-height';
......@@ -37,19 +38,27 @@ export default class TopUpInfo extends React.Component {
</View>
<ScrollView>
<View style={styles.content}>
{
this.state.topup_info.map((item, i) => {
return (
<View style={styles.item_container} key={i}>
<View style={{flexDirection: 'row', height: 24, marginBottom: 16}}>
<Text style={styles.item_title}>{item.title}</Text>
<Image style={styles.item_image} source={item.title_thumb ? { uri: item.title_thumb } : null}/>
</View>
<HTML html={item.content} tagsStyles={{ p: { fontFamily: 'Gotham-Light', marginTop: 8, marginBottom: 8, color: '#adadad' }, blockquote: { backgroundColor: "#f1f1f1", padding: 12, paddingBottom: 0, marginTop: 6, color: '#adadad' }, ul: { fontFamily: 'Gotham-Light', marginLeft: 0, color: '#adadad', paddingLeft: 0 }, li: { fontFamily: 'Gotham-Light', marginLeft: 0, color: '#adadad', paddingLeft: 0 } }} />
<Collapse>
<CollapseHeader>
<View style={{ flexDirection: 'row', height: 24, marginBottom: 10 }}>
<Text style={styles.item_title}>{item.title}</Text>
<Image style={styles.item_image} source={item.title_thumb ? { uri: item.title_thumb } : null} />
</View>
</CollapseHeader>
<CollapseBody>
<HTML html={item.content} tagsStyles={{ p: { fontFamily: 'Gotham-Light', marginTop: 8, marginBottom: 8, color: '#adadad' }, blockquote: { backgroundColor: "#f1f1f1", padding: 12, paddingBottom: 0, marginTop: 6, color: '#adadad' }, ul: { fontFamily: 'Gotham-Light', marginLeft: 0, color: '#adadad', paddingLeft: 0 }, li: { fontFamily: 'Gotham-Light', marginLeft: 0, color: '#adadad', paddingLeft: 0 } }} />
</CollapseBody>
</Collapse>
</View>
)
})
}
</View>
</ScrollView>
</View>
......@@ -114,7 +123,7 @@ const styles = StyleSheet.create({
alignSelf: 'center',
},
item_image: {
width: 96,
width: 96,
height: 24,
alignItems: 'flex-end'
}
......
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