From d48df6609f9bb481978c636eb8560402426f104c Mon Sep 17 00:00:00 2001 From: Mark Rickert Date: Thu, 15 Feb 2024 11:20:02 -0700 Subject: [PATCH] chore(docs): Update a few recipes for the new theming system. --- docs/recipes/Redux.md | 10 ++- docs/recipes/SelectFieldWithBottomSheet.mdx | 99 ++++++++------------- 2 files changed, 43 insertions(+), 66 deletions(-) diff --git a/docs/recipes/Redux.md b/docs/recipes/Redux.md index 355c7d83..e91606a6 100644 --- a/docs/recipes/Redux.md +++ b/docs/recipes/Redux.md @@ -131,7 +131,8 @@ import React, { FC } from "react"; import { View, ViewStyle } from "react-native"; import { Button, Text } from "app/components"; import { AppStackScreenProps } from "../navigators"; -import { colors } from "../theme"; +import type { ThemedStyle } from "app/theme"; +import { useAppTheme } from "app/utils/useAppTheme"; import { useSafeAreaInsetsStyle } from "../utils/useSafeAreaInsetsStyle"; import { useAppDispatch, useAppSelector } from "app/store/store"; import { decrement, increment } from "app/store/counterSlice"; @@ -139,11 +140,12 @@ import { decrement, increment } from "app/store/counterSlice"; interface WelcomeScreenProps extends AppStackScreenProps<"Welcome"> {} export const WelcomeScreen: FC = () => { + const { themed } = useAppTheme(); const $containerInsets = useSafeAreaInsetsStyle(["top", "bottom"]); const count = useAppSelector((state) => state.counter.value); const dispatch = useAppDispatch(); return ( - +