Add iOS Dark Mode

This commit is contained in:
Lei Nelissen
2020-07-26 14:45:32 +02:00
parent ea91b083c3
commit 6978a4dfea
20 changed files with 4253 additions and 4157 deletions

View File

@@ -1,25 +1,35 @@
import React from 'react';
import { DynamicColorIOS, StyleSheet, ScrollView, Platform, PlatformColor } from 'react-native';
import MediaControls from './components/MediaControls';
import ProgressBar from './components/ProgressBar';
import NowPlaying from './components/NowPlaying';
import styled from 'styled-components/native';
import Queue from './components/Queue';
const Container = styled.ScrollView`
background-color: #fff;
`;
const containerStyle = {
padding: 25,
};
const styles = StyleSheet.create({
outer: {
...Platform.select({
ios: {
color: PlatformColor('label'),
backgroundColor: PlatformColor('systemBackground'),
},
android: {
color: PlatformColor('?android:attr/textColorPrimary'),
backgroundColor: PlatformColor('?android:attr/backgroundTint'),
}
}),
},
inner: {
padding: 25,
}
});
export default function Player() {
return (
<Container contentContainerStyle={containerStyle}>
<ScrollView contentContainerStyle={styles.inner} style={styles.outer}>
<NowPlaying />
<MediaControls />
<ProgressBar />
<Queue />
</Container>
</ScrollView>
);
}