ardaogulcan / react-native-keyboard-accessory

A React Native Keyboard Accessory (View, Navigation) Component. Sticky views on keyboard.
MIT License
534 stars 64 forks source link

KeyboardAccessoryNavigation children type error #61

Open guhyeon opened 3 years ago

guhyeon commented 3 years ago

KeyboardAccessoryNavigation does not need children. but it emit error message.

      <KeyboardAccessoryNavigation
        androidAdjustResize
      />

No overload matches this call. Overload 1 of 2, '(props: KeyboardAccessoryNavigationProps, context?: any): ReactElement<any, any> | Component<KeyboardAccessoryNavigationProps, any, any> | null', gave the following error. Property 'children' is missing in type '{ androidAdjustResize: true; nextDisabled: boolean; previousDisabled: boolean; nextHidden: boolean; previousHidden: boolean; onNext: () => void; onPrevious: () => void; }' but required in type 'KeyboardAccessoryNavigationProps'. Overload 2 of 2, '(props: PropsWithChildren, context?: any): ReactElement<any, any> | Component<...> | null', gave the following error. Property 'children' is missing in type '{ androidAdjustResize: true; nextDisabled: boolean; previousDisabled: boolean; nextHidden: boolean; previousHidden: boolean; onNext: () => void; onPrevious: () => void; }' but required in type 'KeyboardAccessoryNavigationProps'.ts(2769) index.d.ts(23, 3): 'children' is declared here. index.d.ts(23, 3): 'children' is declared here.

ifero commented 3 years ago

There is a PR pending to fix this issue https://github.com/ardaogulcan/react-native-keyboard-accessory/pull/57