-
-
Notifications
You must be signed in to change notification settings - Fork 58
/
Genres.js
38 lines (36 loc) · 780 Bytes
/
Genres.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import * as React from 'react';
import { View, Text, StyleSheet } from 'react-native';
export default function Genres({ genres }) {
return (
<View style={styles.genres}>
{genres.map((genre, i) => {
return (
<View key={genre} style={styles.genre}>
<Text style={styles.genreText}>{genre}</Text>
</View>
);
})}
</View>
);
}
const styles = StyleSheet.create({
genres: {
flexDirection: 'row',
flexWrap: 'wrap',
justifyContent: 'center',
marginVertical: 4,
},
genre: {
paddingHorizontal: 6,
paddingVertical: 2,
borderWidth: 1,
borderRadius: 14,
borderColor: '#ccc',
marginRight: 4,
marginBottom: 4,
},
genreText: {
fontSize: 9,
opacity: 0.4
}
});