/** * Created by nghinv on Fri Jun 11 2021 * Copyright (c) 2021 nghinv@lumi.biz */ import React from 'react'; import { ServicesProvider } from '@nghinv/react-native-services'; import equals from 'react-fast-compare'; import { useTheme } from '@nghinv/react-native-theme'; import type { ActionSheetViewProps } from '@nghinv/react-native-action-sheet'; import type { BottomSheetViewProps } from '@nghinv/react-native-bottom-sheet'; import type { AlertViewProps } from '@nghinv/react-native-alert'; export interface ServiceProviderWithThemeType { children: React.ReactChild; actionSheetProps?: ActionSheetViewProps; bottomSheetProps?: BottomSheetViewProps; alertProps?: AlertViewProps; } const overlayOpacity = 0.45; function ServiceProviderWithTheme(props: ServiceProviderWithThemeType) { const { children, actionSheetProps, bottomSheetProps, alertProps, } = props; const { theme } = useTheme(); return ( {children} ); } export default React.memo(ServiceProviderWithTheme, equals);