import React from "react"; import { Text, TextStyle, StyleProp } from "react-native"; import { withTheme } from "../core/theming"; import Theme from "../styles/DefaultTheme"; type Props = { text: string; style?: StyleProp; /** * @optional */ theme: typeof Theme; }; export const Title = withTheme(({ text, theme, style }: Props) => { return ( {text} ); }); export const Subtitle = withTheme(({ text, theme, style }: Props) => { return ( {text} ); }); export const Caption = withTheme(({ text, theme, style }: Props) => { return ( {text} ); });