f0ckapp_react/routes/settings.js

21 lines
566 B
JavaScript
Raw Normal View History

2020-01-20 17:24:37 +00:00
import React from "react";
import theme from "../config/themes";
import SyncStorage from "sync-storage";
import { Text, View, Switch, Image } from 'react-native';
let _theme = SyncStorage.get("theme") === "dark";
export default class SettingScreen extends React.Component {
render() {
return (
<View style={{ flex: 1, backgroundColor: theme.background }}>
<Image source={{ uri: theme.logo }} style={{ width: 112, height: 28, marginTop: 16 }} />
<Text>Dark?</Text>
<Switch value="{_theme}"></Switch>
</View>
);
}
}