Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

NativeThemeHost.tsx

11 lines485 Bytes

1import { Host } from "@expo/ui/swift-ui";
2import type { ComponentProps } from "react";
3import { useControlTheme } from "./useControlTheme";
4​
5/** SwiftUI shares the app's appearance and action tint. Row fills stay explicit. */
6export function NativeThemeHost(
7 props: Omit<ComponentProps<typeof Host>, "colorScheme" | "seedColor">,
8) {
9 const { colors, colorScheme } = useControlTheme();
10 return <Host {...props} colorScheme={colorScheme} seedColor={colors["--color-primary"]} />;