fix library album columns

This commit is contained in:
austinried 2021-08-12 09:44:01 +09:00
parent f523a231f1
commit 16b753e2bb
2 changed files with 9 additions and 8 deletions

View File

@ -17,7 +17,7 @@ const Debug = () => {
const App = () => (
<MenuProvider>
<View style={{ flex: 1, backgroundColor: colors.gradient.high }}>
<StatusBar animated={true} backgroundColor={'rgba(0, 0, 0, 0.4)'} barStyle={'light-content'} translucent={true} />
<StatusBar animated={true} backgroundColor={'rgba(0, 0, 0, 0.3)'} barStyle={'light-content'} translucent={true} />
<SplashPage>
<ProgressHook />
<Debug />

View File

@ -22,7 +22,8 @@ const AlbumItem = React.memo<{
return (
<AlbumContextPressable
album={album}
triggerWrapperStyle={[styles.item, { maxWidth: size, height }]}
menuStyle={[styles.itemMenu, { width: size }]}
triggerWrapperStyle={[styles.itemWrapper, { height }]}
onPress={() => navigation.navigate('album', { id: album.id, title: album.name })}>
<CoverArt
coverArt={album.coverArt}
@ -54,7 +55,7 @@ const AlbumsList = () => {
const layout = useWindowDimensions()
const size = layout.width / 3 - styles.item.marginHorizontal * 2
const size = layout.width / 3 - styles.itemWrapper.marginHorizontal * 2
const height = size + 36
const albumsList = list.map(album => ({ album, size, height }))
@ -88,15 +89,15 @@ const styles = StyleSheet.create({
container: {
flex: 1,
},
item: {
// alignItems: 'center',
marginVertical: 4,
marginHorizontal: 3,
itemMenu: {
flex: 1 / 3,
},
itemWrapper: {
marginVertical: 4,
marginHorizontal: 2,
},
itemDetails: {
flex: 1,
// width: '100%',
},
title: {
fontSize: 12,