优化点击区域

This commit is contained in:
lyswhut 2021-12-21 15:04:36 +08:00
parent b3e364542f
commit 3e625d4a61
5 changed files with 9 additions and 7 deletions

View File

@ -50,7 +50,7 @@ const Progress = ({ progress, bufferedProgress, duration }) => {
} }
const progressContentPadding = 10 const progressContentPadding = 9
const progressHeight = 3 const progressHeight = 3
const progressDotSize = 8 const progressDotSize = 8
const styles = StyleSheet.create({ const styles = StyleSheet.create({

View File

@ -40,8 +40,8 @@ export default () => {
<Image source={{ uri: musicInfo.img }} nativeID={`pic${musicInfo.songmid}`} progressiveRenderingEnabled={true} borderRadius={2} style={{ <Image source={{ uri: musicInfo.img }} nativeID={`pic${musicInfo.songmid}`} progressiveRenderingEnabled={true} borderRadius={2} style={{
// ...styles.playInfoImg, // ...styles.playInfoImg,
backgroundColor: theme.primary, backgroundColor: theme.primary,
width: 48, width: 50,
height: 48, height: 50,
}} /> }} />
</TouchableOpacity> </TouchableOpacity>
), [handleLongPress, handlePress, musicInfo, theme]) ), [handleLongPress, handlePress, musicInfo, theme])

View File

@ -41,11 +41,12 @@ export default () => {
const styles = StyleSheet.create({ const styles = StyleSheet.create({
progress: { progress: {
height: 12, height: 14,
flexGrow: 1, flexGrow: 1,
flexShrink: 0, flexShrink: 0,
flexDirection: 'column', flexDirection: 'column',
justifyContent: 'center', justifyContent: 'center',
marginBottom: -2,
// height: // height:
// position: 'absolute', // position: 'absolute',
// width: '100%', // width: '100%',

View File

@ -33,8 +33,8 @@ export default () => {
<Image source={{ uri: musicInfo.img }} nativeID={`pic${musicInfo.songmid}`} progressiveRenderingEnabled={true} borderRadius={2} style={{ <Image source={{ uri: musicInfo.img }} nativeID={`pic${musicInfo.songmid}`} progressiveRenderingEnabled={true} borderRadius={2} style={{
// ...styles.playInfoImg, // ...styles.playInfoImg,
backgroundColor: theme.primary, backgroundColor: theme.primary,
width: 48, width: 50,
height: 48, height: 50,
}} /> }} />
</TouchableOpacity> </TouchableOpacity>
), [handlePress, musicInfo, theme]) ), [handlePress, musicInfo, theme])

View File

@ -41,11 +41,12 @@ export default () => {
const styles = StyleSheet.create({ const styles = StyleSheet.create({
progress: { progress: {
height: 12, height: 14,
flexGrow: 1, flexGrow: 1,
flexShrink: 0, flexShrink: 0,
flexDirection: 'column', flexDirection: 'column',
justifyContent: 'center', justifyContent: 'center',
marginBottom: -2,
// height: // height:
// position: 'absolute', // position: 'absolute',
// width: '100%', // width: '100%',