File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import React from 'react' ;
22import { requireNativeComponent , ViewProps } from 'react-native' ;
33
4- import { AdIconViewContext , AdIconViewContextValueType } from './contexts' ;
4+ import {
5+ AdIconViewContext ,
6+ AdIconViewContextValueType ,
7+ ComponentOrClass ,
8+ } from './contexts' ;
59import { NativeAd } from './nativeAd' ;
610
711export type AdIconViewProps = ViewProps ;
@@ -14,9 +18,9 @@ export const NativeAdIconView = requireNativeComponent<AdIconViewProps>(
1418class AdIconViewChild extends React . Component <
1519 AdIconViewProps & AdIconViewContextValueType
1620> {
17- private iconView : React . ReactNode | null = null ;
21+ private iconView : ComponentOrClass | null = null ;
1822
19- private handleAdIconViewRef = ( ref : React . ReactNode ) => {
23+ private handleAdIconViewRef = ( ref : ComponentOrClass | null ) => {
2024 if ( this . iconView ) {
2125 this . props . unregister ( ) ;
2226 this . iconView = null ;
Original file line number Diff line number Diff line change 1- import React , { ReactNode } from 'react' ;
1+ import React from 'react' ;
2+ import { requireNativeComponent , ViewProps } from 'react-native' ;
23import {
3- requireNativeComponent ,
4- StyleProp ,
5- ViewStyle ,
6- ViewProps ,
7- } from 'react-native' ;
8- import { MediaViewContext , MediaViewContextValueType } from './contexts' ;
4+ ComponentOrClass ,
5+ MediaViewContext ,
6+ MediaViewContextValueType ,
7+ } from './contexts' ;
98
109export type MediaViewProps = ViewProps ;
1110
@@ -17,9 +16,9 @@ export const NativeMediaView = requireNativeComponent<MediaViewProps>(
1716class MediaViewChild extends React . Component <
1817 MediaViewProps & MediaViewContextValueType
1918> {
20- private mediaView : ReactNode ;
19+ private mediaView : ComponentOrClass | null = null ;
2120
22- private handleMediaViewMount = ( ref : ReactNode ) => {
21+ private handleMediaViewMount = ( ref : ComponentOrClass | null ) => {
2322 if ( this . mediaView ) {
2423 this . props . unregister ( ) ;
2524 this . mediaView = null ;
You can’t perform that action at this time.
0 commit comments