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

@ -1,13 +1,14 @@
import { AntDesign } from '@expo/vector-icons'
import React from 'react'
import { StyleSheet, TouchableOpacity, ViewProps } from 'react-native'
import { useThemeColor } from '../../hooks/useThemeColor'
import { useTheme } from '../../app/contexts/ThemeContext'
type PlusProps = ViewProps & {onPress? : ()=> void | undefined}
const Plus = (props : PlusProps) => {
const accentColor = useThemeColor("accentColor");
const primaryText = useThemeColor("primaryText");
const {colors} = useTheme()
const accentColor = colors.accentColor;
const primaryText = colors.primaryText;
const style = StyleSheet.create({
plus:{