Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing children in Lightbox type #11

Open
kestarumper opened this issue Nov 15, 2022 · 2 comments
Open

Missing children in Lightbox type #11

kestarumper opened this issue Nov 15, 2022 · 2 comments

Comments

@kestarumper
Copy link

kestarumper commented Nov 15, 2022

Hi! 👋

Firstly, thanks for your work on this project! 🙂

Today I used patch-package to patch [email protected] for the project I'm working on.

Problem

The exported Lightbox type is not supporting React children

Diff

Here is the diff that solved my problem:

diff --git a/node_modules/react-native-lightbox-v2/dist/Lightbox.d.ts b/node_modules/react-native-lightbox-v2/dist/Lightbox.d.ts
index 984e8ae..38a52f2 100644
--- a/node_modules/react-native-lightbox-v2/dist/Lightbox.d.ts
+++ b/node_modules/react-native-lightbox-v2/dist/Lightbox.d.ts
@@ -12,7 +12,7 @@ export interface ISpringConfig {
     tension: number;
     friction: number;
 }
-export interface LightboxProps<T = any> extends IGestureProps {
+export interface LightboxProps<T = any> extends React.PropsWithChildren<IGestureProps> {
     activeProps?: Record<string, T>;
     renderContent?: Func<T, JSX.Element>;
     renderHeader?: Func<T, JSX.Element>;

This issue body was partially generated by patch-package.

@sohan-dutta
Copy link

Thanks! Resolved my issue

@cbbfcd
Copy link
Owner

cbbfcd commented Sep 20, 2024

We apologize for the late response. The related issues will be resolved in the upcoming version. You are also welcome to join us in the co-development.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants