import type { ImageStyle, TextStyle, ViewStyle } from 'react-native'; declare global { // eslint-disable-next-line @typescript-eslint/no-namespace namespace ReactNativeSimpleTheme { // eslint-disable-next-line @typescript-eslint/no-empty-interface interface ThemePalette {} } } type StringPathImpl = K extends string ? T[K] extends Record ? T[K] extends ArrayLike ? K | `${K}.${StringPathImpl>}` : K | `${K}.${StringPathImpl}` : K : never; type StringPath = StringPathImpl | keyof T; export type ThemeName = keyof ReactNativeSimpleTheme.ThemePalette; export type ThemeValues = { [key in ThemeName]: T }; export type ThemeContextValue = { themes: ReactNativeSimpleTheme.ThemePalette; getThemeName?: () => ThemeName; }; export type NamedStyles = { [P in keyof T]: ViewStyle | TextStyle | ImageStyle; }; export type CreateThemedStyleFunc = ( factory: (palette: ReactNativeSimpleTheme.ThemePalette[ThemeName]) => NamedStyles, ) => typeof factory; export type ThemePaths = StringPath;