Skip to content

Commit 957997b

Browse files
authored
style: correct segmented buttons container styles (#3890)
1 parent 39b2e82 commit 957997b

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

example/src/Examples/SegmentedButtons/SegmentedButtonMultiselectRealCase.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ const SegmentedButtonMultiselectRealCase = () => {
5151
<FlatList
5252
data={value.length > 0 ? filteredData : restaurantsData}
5353
keyExtractor={(item) => item.id}
54+
contentContainerStyle={styles.contentContainer}
5455
renderItem={({ item }) => {
5556
return (
5657
<Card mode="contained" style={styles.card}>
@@ -75,6 +76,10 @@ const SegmentedButtonMultiselectRealCase = () => {
7576
const styles = StyleSheet.create({
7677
container: {
7778
marginVertical: 16,
79+
flex: 1,
80+
},
81+
contentContainer: {
82+
paddingBottom: 16,
7883
},
7984
card: {
8085
marginHorizontal: 16,

example/src/Examples/SegmentedButtons/SegmentedButtonRealCase.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ const SegmentedButtonRealCase = () => {
3232
<FlatList
3333
data={value === 'songs' ? songsData : albumsData}
3434
keyExtractor={(item) => item.id}
35+
contentContainerStyle={styles.contentContainer}
3536
renderItem={({ item }) => {
3637
return (
3738
<Card mode="contained" style={styles.card}>
@@ -56,6 +57,10 @@ const SegmentedButtonRealCase = () => {
5657
const styles = StyleSheet.create({
5758
container: {
5859
marginVertical: 16,
60+
flex: 1,
61+
},
62+
contentContainer: {
63+
paddingBottom: 16,
5964
},
6065
card: {
6166
marginHorizontal: 16,

0 commit comments

Comments
 (0)