add visual break before file description (if present)

This commit is contained in:
Akinwale Ariwodola 2018-08-08 15:12:33 +01:00
parent 56afde24db
commit cfb81fc530
3 changed files with 11 additions and 0 deletions

View file

@ -346,6 +346,9 @@ class FilePage extends React.PureComponent {
const channelUri = normalizeURI(channelName); const channelUri = normalizeURI(channelName);
navigation.navigate({ routeName: 'File', key: channelUri, params: { uri: channelUri }}); navigation.navigate({ routeName: 'File', key: channelUri, params: { uri: channelUri }});
}} />} }} />}
{description && description.length > 0 && <View style={filePageStyle.divider} />}
{description && <Text style={filePageStyle.description} selectable={true}>{this.linkify(description)}</Text>} {description && <Text style={filePageStyle.description} selectable={true}>{this.linkify(description)}</Text>}
</ScrollView> </ScrollView>
</View> </View>

View file

@ -4,6 +4,7 @@ const Colors = {
DescriptionGrey: '#999999', DescriptionGrey: '#999999',
LbryGreen: '#40b89a', LbryGreen: '#40b89a',
LightGrey: '#cccccc', LightGrey: '#cccccc',
LighterGrey: '#e5e5e5',
Orange: '#ffbb00', Orange: '#ffbb00',
Red: '#ff0000', Red: '#ff0000',
VeryLightGrey: '#f1f1f1', VeryLightGrey: '#f1f1f1',

View file

@ -12,6 +12,13 @@ const filePageStyle = StyleSheet.create({
pageContainer: { pageContainer: {
flex: 1 flex: 1
}, },
divider: {
backgroundColor: Colors.LighterGrey,
width: '100%',
height: 1,
marginTop: 4,
marginBottom: 20
},
innerPageContainer: { innerPageContainer: {
flex: 1, flex: 1,
marginBottom: 60 marginBottom: 60