useTheme applied globally

This commit is contained in:
Jakob Stornig 2023-12-30 14:35:05 +01:00
parent 1f304d41f2
commit 9de2678922
12 changed files with 31 additions and 39 deletions

View file

@ -2,7 +2,6 @@ import React from 'react'
import { Image, Text, View, ViewProps } from 'react-native'
import { TouchableOpacity } from 'react-native-gesture-handler'
import { MARGINS, SIZES } from '../../../constants/theme'
import { useThemeColor } from '../../../hooks/useThemeColor'
import { useTheme } from '../../../app/contexts/ThemeContext'
type WelcomeProps = ViewProps & {name: string, image : any, onPress: () => void | undefined}
@ -36,7 +35,6 @@ export default function Welcome(props: WelcomeProps) {
const onpress = props.onPress
const textcolor = colors.primaryText
//const backgroundColor: string = useThemeColor("backgroundColor")
return (
<View style={{

View file

@ -1,7 +1,6 @@
import React from 'react';
import { ColorValue, StyleSheet, Text, View } from 'react-native';
import { SIZES } from '../../../constants/theme';
import { useThemeColor } from '../../../hooks/useThemeColor';
import { useTheme } from '../../../app/contexts/ThemeContext';
import CustomCard from "../../common/CustomCard";
import { SimpleDate } from '../../../util/SimpleDate';

View file

@ -1,8 +1,6 @@
import { View, Text, StyleSheet, Switch, SwitchProps, useColorScheme, TouchableOpacityProps, TouchableOpacity, ViewProps } from 'react-native'
import { View, Text, StyleSheet, Switch, SwitchProps, useColorScheme, TouchableOpacityProps, TouchableOpacity } from 'react-native'
import React from 'react'
import { SIZES } from '../../../constants/theme'
import { useThemeColor } from '../../../hooks/useThemeColor';
import { CustomCard } from "../../"
import { useTheme } from '../../../app/contexts/ThemeContext';
interface ToggleSettingProps extends SwitchProps {