@zezosoft/zezo-ott-react-native-ui-kit 1.1.1 → 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/module/Styles/globalStyles.js +0 -5
- package/lib/module/Styles/globalStyles.js.map +1 -1
- package/lib/module/components/Auth/AuthProvider/AuthProvider.js +64 -40
- package/lib/module/components/Auth/AuthProvider/AuthProvider.js.map +1 -1
- package/lib/module/components/Auth/ForgotPassword/ForgotPassword.js +5 -2
- package/lib/module/components/Auth/ForgotPassword/ForgotPassword.js.map +1 -1
- package/lib/module/components/Auth/Login/LoginWithEmail.js +17 -11
- package/lib/module/components/Auth/Login/LoginWithEmail.js.map +1 -1
- package/lib/module/components/Auth/Login/LoginWithPhone.js +12 -6
- package/lib/module/components/Auth/Login/LoginWithPhone.js.map +1 -1
- package/lib/module/components/Auth/OTP/OTP.js +7 -4
- package/lib/module/components/Auth/OTP/OTP.js.map +1 -1
- package/lib/module/components/Auth/QrLogin/QrLogin.js +357 -144
- package/lib/module/components/Auth/QrLogin/QrLogin.js.map +1 -1
- package/lib/module/components/Auth/QrLogin/components/QrViewArea.js +227 -110
- package/lib/module/components/Auth/QrLogin/components/QrViewArea.js.map +1 -1
- package/lib/module/components/Auth/SignUp/SignUp.js +19 -13
- package/lib/module/components/Auth/SignUp/SignUp.js.map +1 -1
- package/lib/module/components/Auth/SplashScreen/SplashScreen.js +54 -36
- package/lib/module/components/Auth/SplashScreen/SplashScreen.js.map +1 -1
- package/lib/module/components/Auth/SplashScreen/components/SplashImage/SplashImage.js +29 -11
- package/lib/module/components/Auth/SplashScreen/components/SplashImage/SplashImage.js.map +1 -1
- package/lib/module/components/Auth/SplashScreen/components/SplashLottie/SplashLottie.js +13 -7
- package/lib/module/components/Auth/SplashScreen/components/SplashLottie/SplashLottie.js.map +1 -1
- package/lib/module/components/Auth/SplashScreen/components/SplashVideo/SplashVideo.js +33 -21
- package/lib/module/components/Auth/SplashScreen/components/SplashVideo/SplashVideo.js.map +1 -1
- package/lib/module/components/BackgroundLayout/BackgroundLayout.js +26 -20
- package/lib/module/components/BackgroundLayout/BackgroundLayout.js.map +1 -1
- package/lib/module/components/BlogView/BlogView.js +36 -20
- package/lib/module/components/BlogView/BlogView.js.map +1 -1
- package/lib/module/components/Button/BackBtn.js +24 -20
- package/lib/module/components/Button/BackBtn.js.map +1 -1
- package/lib/module/components/Button/PrimaryBtn.js +19 -13
- package/lib/module/components/Button/PrimaryBtn.js.map +1 -1
- package/lib/module/components/Button/SecondaryBtn.js +19 -13
- package/lib/module/components/Button/SecondaryBtn.js.map +1 -1
- package/lib/module/components/Button/TextButton.js +19 -13
- package/lib/module/components/Button/TextButton.js.map +1 -1
- package/lib/module/components/Content/Card/Category/Category.js +151 -46
- package/lib/module/components/Content/Card/Category/Category.js.map +1 -1
- package/lib/module/components/Content/Card/NowWatching/NowWatching.js +237 -108
- package/lib/module/components/Content/Card/NowWatching/NowWatching.js.map +1 -1
- package/lib/module/components/Content/Card/Sliders/Styles/One.js +200 -133
- package/lib/module/components/Content/Card/Sliders/Styles/One.js.map +1 -1
- package/lib/module/components/Content/Card/Sliders/Styles/Two.js +192 -84
- package/lib/module/components/Content/Card/Sliders/Styles/Two.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/Five.js +131 -48
- package/lib/module/components/Content/Card/Styles/Five.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/Four.js +126 -59
- package/lib/module/components/Content/Card/Styles/Four.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/One.js +125 -50
- package/lib/module/components/Content/Card/Styles/One.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/RotateInOut.js +143 -65
- package/lib/module/components/Content/Card/Styles/RotateInOut.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/Six.js +207 -115
- package/lib/module/components/Content/Card/Styles/Six.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/Three.js +134 -79
- package/lib/module/components/Content/Card/Styles/Three.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/TopTen.js +186 -171
- package/lib/module/components/Content/Card/Styles/TopTen.js.map +1 -1
- package/lib/module/components/Content/Card/Styles/Two.js +144 -64
- package/lib/module/components/Content/Card/Styles/Two.js.map +1 -1
- package/lib/module/components/Content/Card/components/AdsPoster.js +162 -0
- package/lib/module/components/Content/Card/components/AdsPoster.js.map +1 -0
- package/lib/module/components/Content/Card/components/CardPoster.js +139 -93
- package/lib/module/components/Content/Card/components/CardPoster.js.map +1 -1
- package/lib/module/components/Content/Card/components/RentOrBuyIcon.js +18 -17
- package/lib/module/components/Content/Card/components/RentOrBuyIcon.js.map +1 -1
- package/lib/module/components/Content/Card/components/ThumbnailCard.js +78 -28
- package/lib/module/components/Content/Card/components/ThumbnailCard.js.map +1 -1
- package/lib/module/components/Content/Card/components/index.js +4 -0
- package/lib/module/components/Content/Card/components/index.js.map +1 -0
- package/lib/module/components/Content/Content.js +99 -40
- package/lib/module/components/Content/Content.js.map +1 -1
- package/lib/module/components/Content/Sections.js +63 -34
- package/lib/module/components/Content/Sections.js.map +1 -1
- package/lib/module/components/ContentView/ContentView.js +70 -41
- package/lib/module/components/ContentView/ContentView.js.map +1 -1
- package/lib/module/components/ContentView/MoreContentList.js +74 -40
- package/lib/module/components/ContentView/MoreContentList.js.map +1 -1
- package/lib/module/components/ContentView/components/AboutSection.js +40 -19
- package/lib/module/components/ContentView/components/AboutSection.js.map +1 -1
- package/lib/module/components/ContentView/components/CastCard.js +6 -7
- package/lib/module/components/ContentView/components/CastCard.js.map +1 -1
- package/lib/module/components/ContentView/components/EpisodeCard.js +2 -2
- package/lib/module/components/ContentView/components/EpisodeCard.js.map +1 -1
- package/lib/module/components/ContentView/components/GenreTags.js +25 -13
- package/lib/module/components/ContentView/components/GenreTags.js.map +1 -1
- package/lib/module/components/ContentView/components/HeroBanner.js +39 -11
- package/lib/module/components/ContentView/components/HeroBanner.js.map +1 -1
- package/lib/module/components/ContentView/components/MiniInfo.js +84 -77
- package/lib/module/components/ContentView/components/MiniInfo.js.map +1 -1
- package/lib/module/components/ContentView/components/PlayButton.js +11 -7
- package/lib/module/components/ContentView/components/PlayButton.js.map +1 -1
- package/lib/module/components/ContentView/components/Title.js +12 -12
- package/lib/module/components/ContentView/components/Title.js.map +1 -1
- package/lib/module/components/ContentView/components/TrailerButton.js +12 -7
- package/lib/module/components/ContentView/components/TrailerButton.js.map +1 -1
- package/lib/module/components/Fallbacks/NoContentFallback.js +27 -22
- package/lib/module/components/Fallbacks/NoContentFallback.js.map +1 -1
- package/lib/module/components/Fallbacks/NotFoundFallback.js +6 -4
- package/lib/module/components/Fallbacks/NotFoundFallback.js.map +1 -1
- package/lib/module/components/Headers/AppHeader.js +22 -13
- package/lib/module/components/Headers/AppHeader.js.map +1 -1
- package/lib/module/components/Headers/Three.js +6 -5
- package/lib/module/components/Headers/Three.js.map +1 -1
- package/lib/module/components/Headers/Two.js +19 -14
- package/lib/module/components/Headers/Two.js.map +1 -1
- package/lib/module/components/Input/InputOne.js +46 -31
- package/lib/module/components/Input/InputOne.js.map +1 -1
- package/lib/module/components/Loader/Loader.js +2 -2
- package/lib/module/components/Loader/Loader.js.map +1 -1
- package/lib/module/components/Logo/Logo.js +17 -14
- package/lib/module/components/Logo/Logo.js.map +1 -1
- package/lib/module/components/Search/One.js +2 -1
- package/lib/module/components/Search/One.js.map +1 -1
- package/lib/module/components/Search/components/SearchCard.js +15 -19
- package/lib/module/components/Search/components/SearchCard.js.map +1 -1
- package/lib/module/components/Settings/AppSettings.js +97 -62
- package/lib/module/components/Settings/AppSettings.js.map +1 -1
- package/lib/module/components/Subscription/SubOne.js +313 -254
- package/lib/module/components/Subscription/SubOne.js.map +1 -1
- package/lib/module/components/Text/Text.js +15 -12
- package/lib/module/components/Text/Text.js.map +1 -1
- package/lib/module/components/User/DeviceSessions/DeviceSessions.js +25 -23
- package/lib/module/components/User/DeviceSessions/DeviceSessions.js.map +1 -1
- package/lib/module/components/User/ProfileUpdate/ProfileUpdate.js +23 -18
- package/lib/module/components/User/ProfileUpdate/ProfileUpdate.js.map +1 -1
- package/lib/module/components/User/PurchaseHistory/PurchaseHistory.js +38 -24
- package/lib/module/components/User/PurchaseHistory/PurchaseHistory.js.map +1 -1
- package/lib/module/components/User/WatchHistory/WatchHistory.js +21 -14
- package/lib/module/components/User/WatchHistory/WatchHistory.js.map +1 -1
- package/lib/module/components/User/WatchLater/WatchLater.js +30 -21
- package/lib/module/components/User/WatchLater/WatchLater.js.map +1 -1
- package/lib/module/components/User/components/UserAvatar.js +38 -19
- package/lib/module/components/User/components/UserAvatar.js.map +1 -1
- package/lib/module/components/User/components/UserSection.js +37 -17
- package/lib/module/components/User/components/UserSection.js.map +1 -1
- package/lib/module/components/View/View.js +7 -4
- package/lib/module/components/View/View.js.map +1 -1
- package/lib/module/components/index.js +0 -1
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/constants/dummySections.js +44 -4
- package/lib/module/constants/dummySections.js.map +1 -1
- package/lib/module/hooks/Images/index.js +5 -0
- package/lib/module/hooks/Images/index.js.map +1 -0
- package/lib/module/hooks/Images/useImageLoader.js +168 -0
- package/lib/module/hooks/Images/useImageLoader.js.map +1 -0
- package/lib/module/hooks/Images/useImageValidation.js +36 -0
- package/lib/module/hooks/Images/useImageValidation.js.map +1 -0
- package/lib/module/hooks/index.js +20 -0
- package/lib/module/hooks/index.js.map +1 -0
- package/lib/module/hooks/useAdTracking.js +270 -0
- package/lib/module/hooks/useAdTracking.js.map +1 -0
- package/lib/module/hooks/useCards.js +164 -0
- package/lib/module/hooks/useCards.js.map +1 -0
- package/lib/module/hooks/useDebounce.js +25 -6
- package/lib/module/hooks/useDebounce.js.map +1 -1
- package/lib/module/hooks/useKeyboard.js +7 -4
- package/lib/module/hooks/useKeyboard.js.map +1 -1
- package/lib/module/hooks/useNavigationMode.js +10 -4
- package/lib/module/hooks/useNavigationMode.js.map +1 -1
- package/lib/module/hooks/usePaginatedSection.js +12 -7
- package/lib/module/hooks/usePaginatedSection.js.map +1 -1
- package/lib/module/hooks/usePrevious.js +30 -0
- package/lib/module/hooks/usePrevious.js.map +1 -0
- package/lib/module/hooks/useSafeCallback.js +33 -0
- package/lib/module/hooks/useSafeCallback.js.map +1 -0
- package/lib/module/hooks/useSkeletonItems.js +33 -0
- package/lib/module/hooks/useSkeletonItems.js.map +1 -0
- package/lib/module/hooks/useSplashCache.js +2 -1
- package/lib/module/hooks/useSplashCache.js.map +1 -1
- package/lib/module/hooks/useThemeColors.js +33 -0
- package/lib/module/hooks/useThemeColors.js.map +1 -0
- package/lib/module/theme/ThemeProvider.js +17 -11
- package/lib/module/theme/ThemeProvider.js.map +1 -1
- package/lib/module/theme/hook/useInternalTheme.js +18 -11
- package/lib/module/theme/hook/useInternalTheme.js.map +1 -1
- package/lib/module/theme/hook/useThemeStatusBar.js +10 -4
- package/lib/module/theme/hook/useThemeStatusBar.js.map +1 -1
- package/lib/typescript/src/Styles/globalStyles.d.ts +0 -5
- package/lib/typescript/src/Styles/globalStyles.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/AuthProvider/AuthProvider.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/ForgotPassword/ForgotPassword.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/Login/LoginWithEmail.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/Login/LoginWithPhone.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/OTP/OTP.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/QrLogin/QrLogin.d.ts +2 -15
- package/lib/typescript/src/components/Auth/QrLogin/QrLogin.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/QrLogin/components/QrViewArea.d.ts +0 -1
- package/lib/typescript/src/components/Auth/QrLogin/components/QrViewArea.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/SignUp/SignUp.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/SplashScreen/SplashScreen.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/SplashScreen/components/SplashImage/SplashImage.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/SplashScreen/components/SplashLottie/SplashLottie.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/SplashScreen/components/SplashVideo/SplashVideo.d.ts.map +1 -1
- package/lib/typescript/src/components/Auth/index.d.ts.map +1 -1
- package/lib/typescript/src/components/BackgroundLayout/BackgroundLayout.d.ts +1 -1
- package/lib/typescript/src/components/BackgroundLayout/BackgroundLayout.d.ts.map +1 -1
- package/lib/typescript/src/components/BlogView/BlogView.d.ts +2 -1
- package/lib/typescript/src/components/BlogView/BlogView.d.ts.map +1 -1
- package/lib/typescript/src/components/Button/BackBtn.d.ts +2 -2
- package/lib/typescript/src/components/Button/BackBtn.d.ts.map +1 -1
- package/lib/typescript/src/components/Button/PrimaryBtn.d.ts +2 -1
- package/lib/typescript/src/components/Button/PrimaryBtn.d.ts.map +1 -1
- package/lib/typescript/src/components/Button/SecondaryBtn.d.ts +2 -1
- package/lib/typescript/src/components/Button/SecondaryBtn.d.ts.map +1 -1
- package/lib/typescript/src/components/Button/TextButton.d.ts +2 -2
- package/lib/typescript/src/components/Button/TextButton.d.ts.map +1 -1
- package/lib/typescript/src/components/Button/index.d.ts +2 -2
- package/lib/typescript/src/components/Content/Card/Category/Category.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/NowWatching/NowWatching.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Sliders/Styles/One.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Sliders/Styles/Two.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/Five.d.ts +13 -1
- package/lib/typescript/src/components/Content/Card/Styles/Five.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/Four.d.ts +13 -1
- package/lib/typescript/src/components/Content/Card/Styles/Four.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/One.d.ts +15 -3
- package/lib/typescript/src/components/Content/Card/Styles/One.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/RotateInOut.d.ts +13 -1
- package/lib/typescript/src/components/Content/Card/Styles/RotateInOut.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/Six.d.ts +1 -0
- package/lib/typescript/src/components/Content/Card/Styles/Six.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/Three.d.ts +13 -5
- package/lib/typescript/src/components/Content/Card/Styles/Three.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/TopTen.d.ts +1 -0
- package/lib/typescript/src/components/Content/Card/Styles/TopTen.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/Styles/Two.d.ts +13 -1
- package/lib/typescript/src/components/Content/Card/Styles/Two.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/components/AdsPoster.d.ts +26 -0
- package/lib/typescript/src/components/Content/Card/components/AdsPoster.d.ts.map +1 -0
- package/lib/typescript/src/components/Content/Card/components/CardPoster.d.ts +3 -1
- package/lib/typescript/src/components/Content/Card/components/CardPoster.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/components/RentOrBuyIcon.d.ts +2 -2
- package/lib/typescript/src/components/Content/Card/components/RentOrBuyIcon.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/components/ThumbnailCard.d.ts +2 -0
- package/lib/typescript/src/components/Content/Card/components/ThumbnailCard.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Card/components/index.d.ts +2 -0
- package/lib/typescript/src/components/Content/Card/components/index.d.ts.map +1 -0
- package/lib/typescript/src/components/Content/Card/index.d.ts +76 -6
- package/lib/typescript/src/components/Content/Card/index.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Content.d.ts +6 -3
- package/lib/typescript/src/components/Content/Content.d.ts.map +1 -1
- package/lib/typescript/src/components/Content/Sections.d.ts +22 -8
- package/lib/typescript/src/components/Content/Sections.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/ContentView.d.ts +6 -1
- package/lib/typescript/src/components/ContentView/ContentView.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/MoreContentList.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/AboutSection.d.ts +2 -1
- package/lib/typescript/src/components/ContentView/components/AboutSection.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/CastCard.d.ts +6 -1
- package/lib/typescript/src/components/ContentView/components/CastCard.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/EpisodeCard.d.ts +2 -1
- package/lib/typescript/src/components/ContentView/components/EpisodeCard.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/GenreTags.d.ts +1 -1
- package/lib/typescript/src/components/ContentView/components/GenreTags.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/HeroBanner.d.ts +2 -1
- package/lib/typescript/src/components/ContentView/components/HeroBanner.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/MiniInfo.d.ts +1 -1
- package/lib/typescript/src/components/ContentView/components/MiniInfo.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/PlayButton.d.ts +2 -1
- package/lib/typescript/src/components/ContentView/components/PlayButton.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/Title.d.ts +1 -1
- package/lib/typescript/src/components/ContentView/components/Title.d.ts.map +1 -1
- package/lib/typescript/src/components/ContentView/components/TrailerButton.d.ts +2 -1
- package/lib/typescript/src/components/ContentView/components/TrailerButton.d.ts.map +1 -1
- package/lib/typescript/src/components/Fallbacks/NoContentFallback.d.ts +2 -1
- package/lib/typescript/src/components/Fallbacks/NoContentFallback.d.ts.map +1 -1
- package/lib/typescript/src/components/Fallbacks/NotFoundFallback.d.ts +1 -1
- package/lib/typescript/src/components/Fallbacks/NotFoundFallback.d.ts.map +1 -1
- package/lib/typescript/src/components/Headers/AppHeader.d.ts +2 -2
- package/lib/typescript/src/components/Headers/AppHeader.d.ts.map +1 -1
- package/lib/typescript/src/components/Headers/Three.d.ts +2 -2
- package/lib/typescript/src/components/Headers/Three.d.ts.map +1 -1
- package/lib/typescript/src/components/Headers/Two.d.ts +2 -2
- package/lib/typescript/src/components/Headers/Two.d.ts.map +1 -1
- package/lib/typescript/src/components/Headers/index.d.ts +2 -2
- package/lib/typescript/src/components/Input/Input.d.ts +1 -1
- package/lib/typescript/src/components/Input/InputOne.d.ts +2 -2
- package/lib/typescript/src/components/Input/InputOne.d.ts.map +1 -1
- package/lib/typescript/src/components/Loader/Loader.d.ts.map +1 -1
- package/lib/typescript/src/components/Logo/Logo.d.ts +2 -1
- package/lib/typescript/src/components/Logo/Logo.d.ts.map +1 -1
- package/lib/typescript/src/components/Search/One.d.ts.map +1 -1
- package/lib/typescript/src/components/Search/components/SearchCard.d.ts +2 -5
- package/lib/typescript/src/components/Search/components/SearchCard.d.ts.map +1 -1
- package/lib/typescript/src/components/Search/index.d.ts +1 -1
- package/lib/typescript/src/components/Settings/AppSettings.d.ts +2 -2
- package/lib/typescript/src/components/Settings/AppSettings.d.ts.map +1 -1
- package/lib/typescript/src/components/Subscription/SubOne.d.ts.map +1 -1
- package/lib/typescript/src/components/Subscription/index.d.ts.map +1 -1
- package/lib/typescript/src/components/Text/Text.d.ts +2 -2
- package/lib/typescript/src/components/Text/Text.d.ts.map +1 -1
- package/lib/typescript/src/components/User/DeviceSessions/DeviceSessions.d.ts +1 -1
- package/lib/typescript/src/components/User/DeviceSessions/DeviceSessions.d.ts.map +1 -1
- package/lib/typescript/src/components/User/ProfileUpdate/ProfileUpdate.d.ts +1 -1
- package/lib/typescript/src/components/User/ProfileUpdate/ProfileUpdate.d.ts.map +1 -1
- package/lib/typescript/src/components/User/PurchaseHistory/PurchaseHistory.d.ts +1 -1
- package/lib/typescript/src/components/User/PurchaseHistory/PurchaseHistory.d.ts.map +1 -1
- package/lib/typescript/src/components/User/WatchHistory/WatchHistory.d.ts +1 -1
- package/lib/typescript/src/components/User/WatchHistory/WatchHistory.d.ts.map +1 -1
- package/lib/typescript/src/components/User/WatchLater/WatchLater.d.ts +1 -1
- package/lib/typescript/src/components/User/WatchLater/WatchLater.d.ts.map +1 -1
- package/lib/typescript/src/components/User/components/UserAvatar.d.ts +1 -1
- package/lib/typescript/src/components/User/components/UserAvatar.d.ts.map +1 -1
- package/lib/typescript/src/components/User/components/UserSection.d.ts +1 -1
- package/lib/typescript/src/components/User/components/UserSection.d.ts.map +1 -1
- package/lib/typescript/src/components/View/View.d.ts +2 -0
- package/lib/typescript/src/components/View/View.d.ts.map +1 -1
- package/lib/typescript/src/components/index.d.ts +0 -1
- package/lib/typescript/src/components/index.d.ts.map +1 -1
- package/lib/typescript/src/constants/dummySections.d.ts +5 -0
- package/lib/typescript/src/constants/dummySections.d.ts.map +1 -1
- package/lib/typescript/src/hooks/Images/index.d.ts +3 -0
- package/lib/typescript/src/hooks/Images/index.d.ts.map +1 -0
- package/lib/typescript/src/hooks/Images/useImageLoader.d.ts +36 -0
- package/lib/typescript/src/hooks/Images/useImageLoader.d.ts.map +1 -0
- package/lib/typescript/src/hooks/Images/useImageValidation.d.ts +17 -0
- package/lib/typescript/src/hooks/Images/useImageValidation.d.ts.map +1 -0
- package/lib/typescript/src/hooks/index.d.ts +17 -0
- package/lib/typescript/src/hooks/index.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useAdTracking.d.ts +39 -0
- package/lib/typescript/src/hooks/useAdTracking.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useCards.d.ts +36 -0
- package/lib/typescript/src/hooks/useCards.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useDebounce.d.ts.map +1 -1
- package/lib/typescript/src/hooks/useKeyboard.d.ts.map +1 -1
- package/lib/typescript/src/hooks/useNavigationMode.d.ts.map +1 -1
- package/lib/typescript/src/hooks/usePaginatedSection.d.ts +12 -2
- package/lib/typescript/src/hooks/usePaginatedSection.d.ts.map +1 -1
- package/lib/typescript/src/hooks/usePrevious.d.ts +12 -0
- package/lib/typescript/src/hooks/usePrevious.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useSafeCallback.d.ts +15 -0
- package/lib/typescript/src/hooks/useSafeCallback.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useSkeletonItems.d.ts +11 -0
- package/lib/typescript/src/hooks/useSkeletonItems.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useSplashCache.d.ts.map +1 -1
- package/lib/typescript/src/hooks/useThemeColors.d.ts +27 -0
- package/lib/typescript/src/hooks/useThemeColors.d.ts.map +1 -0
- package/lib/typescript/src/theme/ThemeProvider.d.ts.map +1 -1
- package/lib/typescript/src/theme/hook/useInternalTheme.d.ts.map +1 -1
- package/lib/typescript/src/theme/hook/useThemeStatusBar.d.ts.map +1 -1
- package/lib/typescript/src/types/sections/index.d.ts +7 -4
- package/lib/typescript/src/types/sections/index.d.ts.map +1 -1
- package/package.json +6 -3
- package/src/Styles/globalStyles.ts +0 -5
- package/src/components/Auth/AuthProvider/AuthProvider.tsx +288 -212
- package/src/components/Auth/ForgotPassword/ForgotPassword.tsx +11 -4
- package/src/components/Auth/Login/LoginWithEmail.tsx +266 -238
- package/src/components/Auth/Login/LoginWithPhone.tsx +18 -6
- package/src/components/Auth/OTP/OTP.tsx +21 -5
- package/src/components/Auth/QrLogin/QrLogin.tsx +477 -177
- package/src/components/Auth/QrLogin/components/QrViewArea.tsx +349 -139
- package/src/components/Auth/SignUp/SignUp.tsx +312 -293
- package/src/components/Auth/SplashScreen/SplashScreen.tsx +186 -131
- package/src/components/Auth/SplashScreen/components/SplashImage/SplashImage.tsx +32 -15
- package/src/components/Auth/SplashScreen/components/SplashLottie/SplashLottie.tsx +11 -5
- package/src/components/Auth/SplashScreen/components/SplashVideo/SplashVideo.tsx +34 -18
- package/src/components/BackgroundLayout/BackgroundLayout.tsx +43 -37
- package/src/components/BlogView/BlogView.tsx +66 -30
- package/src/components/Button/BackBtn.tsx +64 -34
- package/src/components/Button/PrimaryBtn.tsx +42 -25
- package/src/components/Button/SecondaryBtn.tsx +41 -25
- package/src/components/Button/TextButton.tsx +54 -32
- package/src/components/Content/Card/Category/Category.tsx +189 -64
- package/src/components/Content/Card/NowWatching/NowWatching.tsx +281 -136
- package/src/components/Content/Card/Sliders/Styles/One.tsx +270 -158
- package/src/components/Content/Card/Sliders/Styles/Two.tsx +239 -90
- package/src/components/Content/Card/Styles/Five.tsx +161 -62
- package/src/components/Content/Card/Styles/Four.tsx +164 -85
- package/src/components/Content/Card/Styles/One.tsx +161 -71
- package/src/components/Content/Card/Styles/RotateInOut.tsx +162 -67
- package/src/components/Content/Card/Styles/Six.tsx +242 -142
- package/src/components/Content/Card/Styles/Three.tsx +166 -133
- package/src/components/Content/Card/Styles/TopTen.tsx +230 -191
- package/src/components/Content/Card/Styles/Two.tsx +182 -79
- package/src/components/Content/Card/components/AdsPoster.tsx +202 -0
- package/src/components/Content/Card/components/CardPoster.tsx +166 -105
- package/src/components/Content/Card/components/RentOrBuyIcon.tsx +58 -38
- package/src/components/Content/Card/components/ThumbnailCard.tsx +122 -47
- package/src/components/Content/Card/components/index.ts +1 -0
- package/src/components/Content/Content.tsx +211 -106
- package/src/components/Content/Sections.tsx +148 -51
- package/src/components/ContentView/ContentView.tsx +194 -128
- package/src/components/ContentView/MoreContentList.tsx +215 -151
- package/src/components/ContentView/components/AboutSection.tsx +132 -93
- package/src/components/ContentView/components/CastCard.tsx +148 -138
- package/src/components/ContentView/components/EpisodeCard.tsx +160 -155
- package/src/components/ContentView/components/GenreTags.tsx +68 -53
- package/src/components/ContentView/components/HeroBanner.tsx +326 -284
- package/src/components/ContentView/components/MiniInfo.tsx +181 -159
- package/src/components/ContentView/components/PlayButton.tsx +27 -16
- package/src/components/ContentView/components/Title.tsx +89 -72
- package/src/components/ContentView/components/TrailerButton.tsx +35 -22
- package/src/components/Fallbacks/NoContentFallback.tsx +107 -103
- package/src/components/Fallbacks/NotFoundFallback.tsx +12 -4
- package/src/components/Headers/AppHeader.tsx +42 -26
- package/src/components/Headers/Three.tsx +12 -8
- package/src/components/Headers/Two.tsx +31 -10
- package/src/components/Input/InputOne.tsx +136 -108
- package/src/components/Loader/Loader.tsx +2 -2
- package/src/components/Logo/Logo.tsx +43 -27
- package/src/components/Search/One.tsx +2 -4
- package/src/components/Search/components/SearchCard.tsx +19 -13
- package/src/components/Settings/AppSettings.tsx +217 -128
- package/src/components/Subscription/SubOne.tsx +394 -317
- package/src/components/Text/Text.tsx +33 -22
- package/src/components/User/DeviceSessions/DeviceSessions.tsx +129 -102
- package/src/components/User/ProfileUpdate/ProfileUpdate.tsx +36 -17
- package/src/components/User/PurchaseHistory/PurchaseHistory.tsx +194 -140
- package/src/components/User/WatchHistory/WatchHistory.tsx +63 -36
- package/src/components/User/WatchLater/WatchLater.tsx +119 -81
- package/src/components/User/components/UserAvatar.tsx +49 -15
- package/src/components/User/components/UserSection.tsx +71 -37
- package/src/components/View/View.tsx +10 -2
- package/src/components/index.ts +0 -1
- package/src/constants/dummySections.ts +48 -1
- package/src/hooks/Images/index.ts +2 -0
- package/src/hooks/Images/useImageLoader.ts +206 -0
- package/src/hooks/Images/useImageValidation.ts +36 -0
- package/src/hooks/index.ts +17 -0
- package/src/hooks/useAdTracking.ts +349 -0
- package/src/hooks/useCards.ts +228 -0
- package/src/hooks/useDebounce.ts +25 -6
- package/src/hooks/useKeyboard.ts +12 -5
- package/src/hooks/useNavigationMode.ts +16 -5
- package/src/hooks/usePaginatedSection.ts +27 -8
- package/src/hooks/usePrevious.ts +28 -0
- package/src/hooks/useSafeCallback.ts +43 -0
- package/src/hooks/useSkeletonItems.ts +30 -0
- package/src/hooks/useSplashCache.ts +2 -1
- package/src/hooks/useThemeColors.ts +51 -0
- package/src/theme/ThemeProvider.tsx +25 -9
- package/src/theme/hook/useInternalTheme.ts +19 -13
- package/src/theme/hook/useThemeStatusBar.ts +14 -5
- package/src/types/sections/index.ts +7 -4
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @author Naresh Dhamu
|
|
5
5
|
* @lastModified Fri 13 Jun 2025 at 11:10 AM
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
7
|
+
import React, { useMemo, useCallback } from 'react';
|
|
8
8
|
import { Platform, Pressable, StyleSheet, View } from 'react-native';
|
|
9
9
|
import { scale, verticalScale } from 'react-native-size-matters';
|
|
10
10
|
import { Logo } from "../Logo/Logo.js";
|
|
@@ -21,25 +21,30 @@ const HeaderTwo = ({
|
|
|
21
21
|
const {
|
|
22
22
|
theme: appliedTheme
|
|
23
23
|
} = useInternalTheme(theme);
|
|
24
|
-
const rippleColor = appliedTheme.colors.surfaceVariant + '33';
|
|
25
|
-
const pressedBackgroundColor = appliedTheme.colors.surfaceVariant;
|
|
24
|
+
const rippleColor = useMemo(() => appliedTheme.colors.surfaceVariant + '33', [appliedTheme.colors.surfaceVariant]);
|
|
25
|
+
const pressedBackgroundColor = useMemo(() => appliedTheme.colors.surfaceVariant, [appliedTheme.colors.surfaceVariant]);
|
|
26
|
+
const handleMenuPress = useCallback(() => {
|
|
27
|
+
onMenuPress?.();
|
|
28
|
+
}, [onMenuPress]);
|
|
29
|
+
const pressableStyle = useCallback(({
|
|
30
|
+
pressed
|
|
31
|
+
}) => [styles.iconPressable, pressed && {
|
|
32
|
+
backgroundColor: pressedBackgroundColor
|
|
33
|
+
}], [pressedBackgroundColor]);
|
|
34
|
+
const MemoMenuIcon = useMemo(() => /*#__PURE__*/_jsx(MenuIcon, {
|
|
35
|
+
width: scale(28),
|
|
36
|
+
height: scale(28)
|
|
37
|
+
}), [MenuIcon]);
|
|
26
38
|
return /*#__PURE__*/_jsxs(View, {
|
|
27
39
|
style: styles.headerContainer,
|
|
28
40
|
children: [/*#__PURE__*/_jsx(Pressable, {
|
|
29
|
-
onPress:
|
|
41
|
+
onPress: handleMenuPress,
|
|
30
42
|
android_ripple: {
|
|
31
43
|
color: rippleColor,
|
|
32
44
|
borderless: true
|
|
33
45
|
},
|
|
34
|
-
style:
|
|
35
|
-
|
|
36
|
-
}) => [styles.iconPressable, pressed && {
|
|
37
|
-
backgroundColor: pressedBackgroundColor
|
|
38
|
-
}],
|
|
39
|
-
children: /*#__PURE__*/_jsx(MenuIcon, {
|
|
40
|
-
width: scale(28),
|
|
41
|
-
height: scale(28)
|
|
42
|
-
})
|
|
46
|
+
style: pressableStyle,
|
|
47
|
+
children: MemoMenuIcon
|
|
43
48
|
}), /*#__PURE__*/_jsx(View, {
|
|
44
49
|
style: styles.logo,
|
|
45
50
|
children: /*#__PURE__*/_jsx(Logo, {
|
|
@@ -53,7 +58,7 @@ const HeaderTwo = ({
|
|
|
53
58
|
})]
|
|
54
59
|
});
|
|
55
60
|
};
|
|
56
|
-
export default HeaderTwo;
|
|
61
|
+
export default /*#__PURE__*/React.memo(HeaderTwo);
|
|
57
62
|
const styles = StyleSheet.create({
|
|
58
63
|
headerContainer: {
|
|
59
64
|
flexDirection: 'row',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Platform","Pressable","StyleSheet","View","scale","verticalScale","Logo","useInternalTheme","Menu","jsx","_jsx","jsxs","_jsxs","HeaderTwo","theme","logoUri","MenuIcon","onMenuPress","isLoading","appliedTheme","rippleColor","colors","surfaceVariant","pressedBackgroundColor","
|
|
1
|
+
{"version":3,"names":["React","useMemo","useCallback","Platform","Pressable","StyleSheet","View","scale","verticalScale","Logo","useInternalTheme","Menu","jsx","_jsx","jsxs","_jsxs","HeaderTwo","theme","logoUri","MenuIcon","onMenuPress","isLoading","appliedTheme","rippleColor","colors","surfaceVariant","pressedBackgroundColor","handleMenuPress","pressableStyle","pressed","styles","iconPressable","backgroundColor","MemoMenuIcon","width","height","style","headerContainer","children","onPress","android_ripple","color","borderless","logo","placeholder","memo","create","flexDirection","justifyContent","alignItems","paddingHorizontal","flex","marginVertical","OS","padding","borderRadius"],"sourceRoot":"../../../../src","sources":["components/Headers/Two.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA,OAAOA,KAAK,IAAIC,OAAO,EAAEC,WAAW,QAAQ,OAAO;AACnD,SAASC,QAAQ,EAAEC,SAAS,EAAEC,UAA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ACjBgD,YAAY,EAAEhD,KAAK,CAAC,EAAE;EACxB,CAAC;EACDqC,WAAW,EAAE;IACXV,KAAK,EAAE3B,KAAK,CAAC,EAAE,GAAG,EAAE;EACtB;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @author Naresh Dhamu
|
|
5
5
|
* @lastModified Tue 17 Jun 2025 at 11:20 AM
|
|
6
6
|
*/
|
|
7
|
-
import React, { useState } from 'react';
|
|
7
|
+
import React, { useState, useMemo, useCallback } from 'react';
|
|
8
8
|
import { StyleSheet, View, Text, TextInput, TouchableOpacity } from 'react-native';
|
|
9
9
|
import { Eye, EyeOff } from 'lucide-react-native';
|
|
10
10
|
import { scale, verticalScale, moderateScale } from 'react-native-size-matters';
|
|
@@ -27,9 +27,12 @@ const InputOne = ({
|
|
|
27
27
|
theme: appliedTheme
|
|
28
28
|
} = useInternalTheme(theme);
|
|
29
29
|
const [showPassword, setShowPassword] = useState(false);
|
|
30
|
-
const [isFocused, setIsFocused] = useState(false);
|
|
31
|
-
const isPasswordField = !!secureTextEntry;
|
|
32
|
-
const inputSecure = isPasswordField && !showPassword;
|
|
30
|
+
const [isFocused, setIsFocused] = useState(false);
|
|
31
|
+
const isPasswordField = useMemo(() => !!secureTextEntry, [secureTextEntry]);
|
|
32
|
+
const inputSecure = useMemo(() => isPasswordField && !showPassword, [isPasswordField, showPassword]);
|
|
33
|
+
const handleFocus = useCallback(() => setIsFocused(true), []);
|
|
34
|
+
const handleBlur = useCallback(() => setIsFocused(false), []);
|
|
35
|
+
const togglePassword = useCallback(() => setShowPassword(prev => !prev), []);
|
|
33
36
|
const {
|
|
34
37
|
textPrimary,
|
|
35
38
|
textSecondary,
|
|
@@ -38,50 +41,62 @@ const InputOne = ({
|
|
|
38
41
|
outlineDisabled,
|
|
39
42
|
error: inputErrorColor,
|
|
40
43
|
background,
|
|
41
|
-
primary
|
|
44
|
+
primary
|
|
42
45
|
} = appliedTheme?.colors || {};
|
|
46
|
+
const labelColor = useMemo(() => error ? inputErrorColor : disabled ? textDisabled : textPrimary, [error, disabled, inputErrorColor, textDisabled, textPrimary]);
|
|
47
|
+
const labelContainerStyle = useMemo(() => [styles.labelContainer, {
|
|
48
|
+
backgroundColor: background,
|
|
49
|
+
borderRadius: scale(5)
|
|
50
|
+
}], [background]);
|
|
51
|
+
const labelStyle = useMemo(() => [styles.label, {
|
|
52
|
+
color: labelColor
|
|
53
|
+
}], [labelColor]);
|
|
54
|
+
const borderColor = useMemo(() => disabled ? outlineDisabled : error ? inputErrorColor : isFocused ? primary || '#007AFF' : outline, [disabled, error, isFocused, outlineDisabled, inputErrorColor, primary, outline]);
|
|
55
|
+
const wrapperBackgroundColor = useMemo(() => disabled ? appliedTheme.colors.backgroundDisabled : error ? appliedTheme.colors.errorContainer : appliedTheme.colors.background, [disabled, error, appliedTheme.colors]);
|
|
56
|
+
const inputWrapperStyle = useMemo(() => [styles.inputWrapper, {
|
|
57
|
+
borderColor,
|
|
58
|
+
backgroundColor: wrapperBackgroundColor,
|
|
59
|
+
flexDirection: 'row',
|
|
60
|
+
alignItems: 'center'
|
|
61
|
+
}], [borderColor, wrapperBackgroundColor]);
|
|
62
|
+
const inputTextColor = useMemo(() => disabled ? textDisabled : error ? inputErrorColor : textPrimary, [disabled, error, textDisabled, inputErrorColor, textPrimary]);
|
|
63
|
+
const inputColorStyle = useMemo(() => [styles.input, {
|
|
64
|
+
color: inputTextColor
|
|
65
|
+
}, inputStyle], [inputTextColor, inputStyle]);
|
|
66
|
+
const placeholderColor = useMemo(() => placeholderTextColor || (disabled ? textDisabled : textSecondary), [placeholderTextColor, disabled, textDisabled, textSecondary]);
|
|
67
|
+
const cursorColor = useMemo(() => disabled ? textDisabled : error ? inputErrorColor : isFocused ? primary || '#007AFF' : textPrimary, [disabled, error, isFocused, textDisabled, inputErrorColor, primary, textPrimary]);
|
|
68
|
+
const iconColor = useMemo(() => disabled ? textDisabled : error ? inputErrorColor : textPrimary, [disabled, error, textDisabled, inputErrorColor, textPrimary]);
|
|
69
|
+
const textContentType = useMemo(() => isPasswordField ? 'oneTimeCode' : props.textContentType || 'none', [isPasswordField, props.textContentType]);
|
|
43
70
|
return /*#__PURE__*/_jsxs(View, {
|
|
44
71
|
style: [styles.container, containerStyle],
|
|
45
72
|
children: [label && /*#__PURE__*/_jsx(View, {
|
|
46
|
-
style:
|
|
47
|
-
backgroundColor: background,
|
|
48
|
-
borderRadius: scale(5)
|
|
49
|
-
}],
|
|
73
|
+
style: labelContainerStyle,
|
|
50
74
|
children: /*#__PURE__*/_jsx(Text, {
|
|
51
|
-
style:
|
|
52
|
-
color: error ? inputErrorColor : disabled ? textDisabled : textPrimary
|
|
53
|
-
}],
|
|
75
|
+
style: labelStyle,
|
|
54
76
|
children: label
|
|
55
77
|
})
|
|
56
78
|
}), /*#__PURE__*/_jsxs(View, {
|
|
57
|
-
style:
|
|
58
|
-
borderColor: disabled ? outlineDisabled : error ? inputErrorColor : isFocused ? primary || '#007AFF' : outline,
|
|
59
|
-
backgroundColor: disabled ? appliedTheme.colors.backgroundDisabled : error ? appliedTheme.colors.errorContainer : appliedTheme.colors.background,
|
|
60
|
-
flexDirection: 'row',
|
|
61
|
-
alignItems: 'center'
|
|
62
|
-
}],
|
|
79
|
+
style: inputWrapperStyle,
|
|
63
80
|
children: [/*#__PURE__*/_jsx(TextInput, {
|
|
64
81
|
...props,
|
|
65
82
|
editable: !disabled,
|
|
66
|
-
onFocus:
|
|
67
|
-
onBlur:
|
|
68
|
-
placeholderTextColor:
|
|
83
|
+
onFocus: handleFocus,
|
|
84
|
+
onBlur: handleBlur,
|
|
85
|
+
placeholderTextColor: placeholderColor,
|
|
69
86
|
secureTextEntry: inputSecure,
|
|
70
|
-
textContentType:
|
|
71
|
-
cursorColor:
|
|
72
|
-
selectionColor:
|
|
73
|
-
style:
|
|
74
|
-
color: disabled ? textDisabled : error ? inputErrorColor : textPrimary
|
|
75
|
-
}, inputStyle]
|
|
87
|
+
textContentType: textContentType,
|
|
88
|
+
cursorColor: cursorColor,
|
|
89
|
+
selectionColor: cursorColor,
|
|
90
|
+
style: inputColorStyle
|
|
76
91
|
}), isPasswordField && /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
77
|
-
onPress:
|
|
92
|
+
onPress: togglePassword,
|
|
78
93
|
disabled: disabled,
|
|
79
94
|
children: showPassword ? /*#__PURE__*/_jsx(EyeOff, {
|
|
80
95
|
size: scale(20),
|
|
81
|
-
color:
|
|
96
|
+
color: iconColor
|
|
82
97
|
}) : /*#__PURE__*/_jsx(Eye, {
|
|
83
98
|
size: scale(20),
|
|
84
|
-
color:
|
|
99
|
+
color: iconColor
|
|
85
100
|
})
|
|
86
101
|
})]
|
|
87
102
|
}), error && errorMessage && /*#__PURE__*/_jsx(Text, {
|
|
@@ -92,7 +107,7 @@ const InputOne = ({
|
|
|
92
107
|
})]
|
|
93
108
|
});
|
|
94
109
|
};
|
|
95
|
-
export default InputOne;
|
|
110
|
+
export default /*#__PURE__*/React.memo(InputOne);
|
|
96
111
|
const styles = StyleSheet.create({
|
|
97
112
|
container: {
|
|
98
113
|
width: '100%',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useState","StyleSheet","View","Text","TextInput","TouchableOpacity","Eye","EyeOff","scale","verticalScale","moderateScale","useInternalTheme","RFValue","jsx","_jsx","jsxs","_jsxs","InputOne","containerStyle","inputStyle","error","errorMessage","secureTextEntry","theme","label","placeholderTextColor","disabled","props","appliedTheme","showPassword","setShowPassword","isFocused","setIsFocused","isPasswordField","inputSecure","textPrimary","textSecondary","textDisabled","outline","outlineDisabled","inputErrorColor","background","primary","colors","
|
|
1
|
+
{"version":3,"names":["React","useState","useMemo","useCallback","StyleSheet","View","Text","TextInput","TouchableOpacity","Eye","EyeOff","scale","verticalScale","moderateScale","useInternalTheme","RFValue","jsx","_jsx","jsxs","_jsxs","InputOne","containerStyle","inputStyle","error","errorMessage","secureTextEntry","theme","label","placeholderTextColor","disabled","props","appliedTheme","showPassword","setShowPassword","isFocused","setIsFocused","isPasswordField","inputSecure","handleFocus","handleBlur","togglePassword","prev","textPrimary","textSecondary","textDisabled","outline","outlineDisabled","inputErrorColor","background","primary","colors","labelColor","labelContainerStyle","styles","labelContainer","backgroundColor","borderRadius","labelStyle","color","borderColor","wrapperBackgroundColor","backgroundDisabled","errorContainer","inputWrapperStyle","inputWrapper","flexDirection","alignItems","inputTextColor","inputColorStyle","input","placeholderColor","cursorColor","iconColor","textContentType","style","container","children","editable","onFocus","onBlur","selectionColor","onPress","size","errorText","memo","create","width","marginBottom","position","top","left","zIndex","paddingHorizontal","fontSize","fontWeight","borderWidth","paddingVertical","flex","minHeight","marginTop","marginLeft"],"sourceRoot":"../../../../src","sources":["components/Input/InputOne.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA,OAAOA,KAAK,IAAIC,QAAQ,EAAEC,OAAO,EAAEC,WAAW,QAAQ,OAAO;AAC7D,SACEC,UAAU,EACVC,IAAI,EACJC,IAAI,EACJC,SAAS,EACTC,gBAAgB,QAIX,cAAc;AACrB,SAASC,GAAG,EAAEC,MAAM,QAAQ,qBAAqB;AACjD,SAASC,KAAK,EAAEC,aAAa,EAAEC,aAAa,QAAQ,2BAA2B;AAC/E,SAASC,gBAAgB,QAAQ,sCAAmC;AAEpE,SAASC,OAAO,QAAQ,kCAAkC;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAc3D,MAAMC,QAAiC,GAAGA,CAAC;EACzCC,cAAc;EACdC,UAAU;EACVC,KAAK;EACLC,YAAY;EACZC,eAAe;EACfC,KAAK;EACLC,KAAK;EACLC,oBAAoB;EACpBC,QAAQ;EACR,GAAGC;AACL,CAAC,KAAK;EACJ,MAAM;IAAEJ,KAAK,EAAEK;EAAa,CAAC,GAAGjB,gBAAgB,CAACY,KAAK,CAAC;EACvD,MAAM,CAACM,YAAY,EAAEC,eAAe,CAAC,GAAGhC,QAAQ,CAAC,KAA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LkE,QAAQ,EAAE9E,OAAO,CAAC,EAAE,CAAC;IACrB+E,UAAU,EAAE,KAAK;IACjBvC,eAAe,EAAE;EACnB,CAAC;EACDS,YAAY,EAAE;IACZsB,KAAK,EAAE,MAAM;IACbS,WAAW,EAAEpF,KAAK,CAAC,GAAG,CAAC;IACvB6C,YAAY,EAAE3C,aAAa,CAAC,EAAE,CAAC;IAC/B+E,iBAAiB,EAAEjF,KAAK,CAAC,EAAE,CAAC;IAC5BqF,eAAe,EAAEpF,aAAa,CAAC,CAAC;EAClC,CAAC;EACDyD,KAAK,EAAE;IACL4B,IAAI,EAAE,CAAC;IACPX,KAAK,EAAE,MAAM;IACbO,QAAQ,EAAE9E,OAAO,CAAC,EAAE,CAAC;IACrBmF,SAAS,EAAEtF,aAAa,CAAC,EAAE;EAC7B,CAAC;EACDuE,SAAS,EAAE;IACTU,QAAQ,EAAE9E,OAAO,CAAC,EAAE,CAAC;IACrBoF,SAAS,EAAEvF,aAAa,CAAC,CAAC,CAAC;IAC3BwF,UAAU,EAAEzF,KAAK,CAAC,CAAC;EACrB;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { StyleSheet, View, ActivityIndicator } from 'react-native';
|
|
5
5
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
|
-
export const Loader = ({
|
|
6
|
+
export const Loader = /*#__PURE__*/React.memo(({
|
|
7
7
|
color
|
|
8
8
|
}) => {
|
|
9
9
|
return /*#__PURE__*/_jsx(View, {
|
|
@@ -13,7 +13,7 @@ export const Loader = ({
|
|
|
13
13
|
color: color
|
|
14
14
|
})
|
|
15
15
|
});
|
|
16
|
-
};
|
|
16
|
+
});
|
|
17
17
|
const styles = StyleSheet.create({
|
|
18
18
|
root: {
|
|
19
19
|
position: 'absolute',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","StyleSheet","View","ActivityIndicator","jsx","_jsx","Loader","color","style","styles","root","children","size","create","position","top","left","right","bottom","justifyContent","alignItems","zIndex","backgroundColor"],"sourceRoot":"../../../../src","sources":["components/Loader/Loader.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,IAAI,EAAEC,iBAAiB,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAMnE,OAAO,MAAMC,MAA6B,
|
|
1
|
+
{"version":3,"names":["React","StyleSheet","View","ActivityIndicator","jsx","_jsx","Loader","memo","color","style","styles","root","children","size","create","position","top","left","right","bottom","justifyContent","alignItems","zIndex","backgroundColor"],"sourceRoot":"../../../../src","sources":["components/Loader/Loader.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,IAAI,EAAEC,iBAAiB,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAMnE,OAAO,MAAMC,MAA6B,gBAAGN,KAAK,CAACO,IAAI,CAAC,CAAC;EAAEC;AAAM,CAAC,KAAK;EACrE,oBACEH,IAAA,CAACH,IAAI;IAACO,KAAK,EAAEC,MAAM,CAACC,IAAK;IAAAC,QAAA,eACvBP,IAAA,CAACF,iBAAiB;MAACU,IAAI,EAAC,OAAO;MAACL,KAAK,EAAEA;IAAM,CAAE;EAAC,CAC5C,CAAC;AAEX,CAAC,CAAC;AAEF,MAAME,MAAM,GAAGT,UAAU,CAACa,MAAM,CAAC;EAC/BH,IAAI,EAAE;IACJI,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE,CAAC;IACNC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACRC,MAAM,EAAE,CAAC;IACTC,cAAc,EAAE,QAAQ;IACxBC,UAAU,EAAE,QAAQ;IACpBC,MAAM,EAAE,GAAG;IACXC,eAAe,EAAE,uBAAuB,CAAE;EAC5C;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @author Naresh Dhamu
|
|
5
5
|
* @lastModified Sun 08 Jun 2025 at 03:23 PM
|
|
6
6
|
*/
|
|
7
|
-
import React from 'react';
|
|
7
|
+
import React, { useMemo } from 'react';
|
|
8
8
|
import { Image, View } from 'react-native';
|
|
9
9
|
import { moderateScale } from 'react-native-size-matters';
|
|
10
10
|
import SkeletonPlaceholder from 'react-native-skeleton-placeholder';
|
|
@@ -34,21 +34,29 @@ export const Logo = ({
|
|
|
34
34
|
} = useSplashCache({
|
|
35
35
|
logoUrl: logoUri
|
|
36
36
|
});
|
|
37
|
-
const finalSource = logoPath ? {
|
|
37
|
+
const finalSource = useMemo(() => logoPath ? {
|
|
38
38
|
uri: logoPath.startsWith('file://') ? logoPath : `file://${logoPath}`
|
|
39
39
|
} : logoUri ? {
|
|
40
40
|
uri: logoUri
|
|
41
41
|
} : fallbackUri ? {
|
|
42
42
|
uri: fallbackUri
|
|
43
|
-
} : undefined;
|
|
43
|
+
} : undefined, [logoPath, logoUri, fallbackUri]);
|
|
44
|
+
const containerStyleMemo = useMemo(() => [{
|
|
45
|
+
alignItems: 'center',
|
|
46
|
+
justifyContent: 'center'
|
|
47
|
+
}, containerStyle], [containerStyle]);
|
|
48
|
+
const imageStyleMemo = useMemo(() => [{
|
|
49
|
+
width: moderateScale(width),
|
|
50
|
+
height: moderateScale(height),
|
|
51
|
+
...(aspectRatio ? {
|
|
52
|
+
aspectRatio
|
|
53
|
+
} : {})
|
|
54
|
+
}, imageStyle], [width, height, aspectRatio, imageStyle]);
|
|
44
55
|
if (!finalSource && !isLoading) {
|
|
45
56
|
return null;
|
|
46
57
|
}
|
|
47
58
|
return /*#__PURE__*/_jsx(View, {
|
|
48
|
-
style:
|
|
49
|
-
alignItems: 'center',
|
|
50
|
-
justifyContent: 'center'
|
|
51
|
-
}, containerStyle],
|
|
59
|
+
style: containerStyleMemo,
|
|
52
60
|
children: isLoading || isSplashLoading ? /*#__PURE__*/_jsx(SkeletonPlaceholder, {
|
|
53
61
|
backgroundColor: appliedTheme.colors.skeletonBaseColor,
|
|
54
62
|
highlightColor: appliedTheme.colors.skeletonHighlightColor,
|
|
@@ -63,17 +71,12 @@ export const Logo = ({
|
|
|
63
71
|
}) : finalSource && /*#__PURE__*/_jsx(Image, {
|
|
64
72
|
source: finalSource,
|
|
65
73
|
resizeMode: resizeMode,
|
|
66
|
-
style:
|
|
67
|
-
width: moderateScale(width),
|
|
68
|
-
height: moderateScale(height),
|
|
69
|
-
...(aspectRatio ? {
|
|
70
|
-
aspectRatio
|
|
71
|
-
} : {})
|
|
72
|
-
}, imageStyle],
|
|
74
|
+
style: imageStyleMemo,
|
|
73
75
|
onError: () => {
|
|
74
76
|
return null;
|
|
75
77
|
}
|
|
76
78
|
})
|
|
77
79
|
});
|
|
78
80
|
};
|
|
81
|
+
export default /*#__PURE__*/React.memo(Logo);
|
|
79
82
|
//# sourceMappingURL=Logo.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Image","View","moderateScale","SkeletonPlaceholder","useSplashCache","useInternalTheme","jsx","_jsx","Logo","width","height","resizeMode","logoUri","imageStyle","containerStyle","aspectRatio","fallbackUri","theme","isLoading","appliedTheme","data","logoPath","isSplashLoading","logoUrl","finalSource","uri","startsWith","undefined","
|
|
1
|
+
{"version":3,"names":["React","useMemo","Image","View","moderateScale","SkeletonPlaceholder","useSplashCache","useInternalTheme","jsx","_jsx","Logo","width","height","resizeMode","logoUri","imageStyle","containerStyle","aspectRatio","fallbackUri","theme","isLoading","appliedTheme","data","logoPath","isSplashLoading","logoUrl","finalSource","uri","startsWith","undefined","containerStyleMemo","alignItems","justifyContent","imageStyleMemo","style","children","backgroundColor","colors","skeletonBaseColor","highlightColor","skeletonHighlightColor","speed","borderRadius","Item","alignSelf","source","onError","memo"],"sourceRoot":"../../../../src","sources":["components/Logo/Logo.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA,OAAOA,KAAK,IAAIC,OAAO,QAAQ,OAAO;AACtC,S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AAC;IAC3BC,MAAM,EAAER,aAAa,CAACQ,MAAM,CAAC;IAC7B,IAAIK,WAAW,GAAG;MAAEA;IAAY,CAAC,GAAG,CAAC,CAAC;EACxC,CAAC,EACDF,UAAU,CACX,EACD,CAACJ,KAAK,EAAEC,MAAM,EAAEK,WAAW,EAAEF,UAAU,CACzC,CAAC;EAED,IAAI,CAACW,WAAW,IAAI,CAACN,SAAS,EAAE;IAC9B,OAAO,IAAI;EACb;EACA,oBACEX,IAAA,CAACN,IAAI;IAAC+B,KAAK,EAAEJ,kBAAmB;IAAAK,QAAA,EAC7Bf,SAAS,IAAII,eAAe,gBAC3Bf,IAAA,CAACJ,mBAAmB;MAClB+B,eAAe,EAAEf,YAAY,CAACgB,MAAM,CAACC,iBAAkB;MACvDC,cAAc,EAAElB,YAAY,CAACgB,MAAM,CAACG,sBAAuB;MAC3DC,KAAK,EAAE,IAAK;MACZC,YAAY,EAAE,CAAE;MAAAP,QAAA,eAEhB1B,IAAA,CAACJ,mBAAmB,CAACsC,IAAI;QACvBC,SAAS,EAAC,QAAQ;QAClBjC,KAAK,EAAEP,aAAa,CAACO,KAAK,CAAE;QAC5BC,MAAM,EAAER,aAAa,CAACO,KAAK,GAAG,CAAC,CAAE;QACjC+B,YAAY,EAAE;MAAE,CACjB;IAAC,CACiB,CAAC,GAEtBhB,WAAW,iBACTjB,IAAA,CAACP,KAAK;MACJ2C,MAAM,EAAEnB,WAAY;MACpBb,UAAU,EAAEA,UAAW;MACvBqB,KAAK,EAAED,cAAe;MACtBa,OAAO,EAAEA,CAAA,KAAM;QACb,OAAO,IAAI;MACb;IAAE,CACH;EAEJ,CACG,CAAC;AAEX,CAAC;AAED,4BAAe9C,KAAK,CAAC+C,IAAI,CAACrC,IAAI,CAAC","ignoreList":[]}
|
|
@@ -15,6 +15,7 @@ import { scale, verticalScale } from 'react-native-size-matters';
|
|
|
15
15
|
import HideKeyboard from "../Keyboard/HideKeyboard.js";
|
|
16
16
|
import SearchCard from "./components/SearchCard.js";
|
|
17
17
|
import { useDebounce } from "../../hooks/useDebounce.js";
|
|
18
|
+
import { useSkeletonItems } from "../../hooks/useSkeletonItems.js";
|
|
18
19
|
import { useRecentSearchesStore } from "../../store/RecentSearchesStore.js";
|
|
19
20
|
import RecentSearchesSection from "./components/RecentSearchesSection.js";
|
|
20
21
|
import Cards from "../Content/Card/index.js";
|
|
@@ -77,7 +78,7 @@ const SearchBar = ({
|
|
|
77
78
|
item
|
|
78
79
|
});
|
|
79
80
|
}, [events]);
|
|
80
|
-
const skeletonItems =
|
|
81
|
+
const skeletonItems = useSkeletonItems(skeletonCardCount);
|
|
81
82
|
const showRecent = !recentSearchesLoading && search.trim() === '' && recentSearches.length > 0;
|
|
82
83
|
const shouldShowFooter = !isLoading && search.trim().length === 0 && results?.length === 0;
|
|
83
84
|
const renderItem = ({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","memo","useCallback","useMemo","View","StyleSheet","Platform","FlatList","Keyboard","useInternalTheme","InputTwo","LucideSearch","XCircle","Text","scale","verticalScale","HideKeyboard","SearchCard","useDebounce","useRecentSearchesStore","RecentSearchesSection","Cards","RFValue","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","SearchBar","placeholder","results","search","isLoading","events","pillMaxCount","skeletonCardCount","skeletonConfig","noResultsText","recommendedContentCardStyles","theme","recommendedContent","appliedTheme","recentSearches","addSearchTerm","clearSearches","recentSearchesLoading","colors","textPrimary","background","debouncedSubmit","keyword","trimmed","trim","onSubmit","handleTyping","text","onChangeText","handleClear","onClear","dismiss","handleItemPress","item","onItemPress","skeletonItems","
|
|
1
|
+
{"version":3,"names":["React","memo","useCallback","useMemo","View","StyleSheet","Platform","FlatList","Keyboard","useInternalTheme","InputTwo","LucideSearch","XCircle","Text","scale","verticalScale","HideKeyboard","SearchCard","useDebounce","useSkeletonItems","useRecentSearchesStore","RecentSearchesSection","Cards","RFValue","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","SearchBar","placeholder","results","search","isLoading","events","pillMaxCount","skeletonCardCount","skeletonConfig","noResultsText","recommendedContentCardStyles","theme","recommendedContent","appliedTheme","recentSearches","addSearchTerm","clearSearches","recentSearchesLoading","colors","textPrimary","background","debouncedSubmit","keyword","trimmed","trim","onSubmit","handleTyping","text","onChangeText","handleClear","onClear","dismiss","handleItemPress","item","onItemPress","skeletonItems","showRecent","length","shouldShowFooter","renderItem","index","style","styles","container","children","title","name","thumbnail","poster","description","category","type","content_offering_type","onPress","_id","renderFooter","onPressItem","onClearAll","content","data","Styles","Two","section_id","titleStyle","recommendedTitle","onPressRecommendedItem","onPressMore","onPressRecommendedMore","moreFetchData","moreFetchDataRecommended","renderEmptyComponent","emptyText","color","mainContainer","backgroundColor","value","leftIcon","size","rightIcon","onPressRightIcon","accessibilityLabel","keyboardVerticalOffset","keyExtractor","idx","ListEmptyComponent","ListFooterComponent","contentContainerStyle","paddingBottom","paddingTop","showsVerticalScrollIndicator","keyboardShouldPersistTaps","flex","marginTop","create","OS","paddingHorizontal","fontSize","textAlign"],"sourceRoot":"../../../../src","sources":["components/Search/One.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;;AAEA,OAAOA,KAAK,IAAIC,IAAI,EAAEC,WAAW,EAAEC,OAAO,QAAQ,OAAO;AACzD,SACEC,IAAI,EACJC,UAAU,EACVC,QAAQ,EACRC,QAAQ,EACRC,QAAQ,QAEH,cAAc;AACrB,SAASC,gBAAgB,QAAQ,sCAAmC;AACpE,OAAOC,QAAQ,MAAM,sBAAmB;AACxC,SAASC,YAAY,EAAEC,OAAO,QAAQ,qBAAqB;AAC3D,SAASC,IAAI,QAAQ,kBAAS;AAC9B,SAASC,KAAK,EAAEC,aAAa,QAAQ,2BAA2B;AAChE,OAAOC,YAAY,MAAM,6BAA0B;AACnD,OAAOC,UAAU,MAEV,4BAAyB;AAChC,SAASC,WAAW,QAAQ,4BAAyB;AACrD,SAASC,gBAAgB,QAAQ,iCAA8B;AAG/D,SAASC,sBAAsB,QAAQ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ACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -14,6 +14,8 @@ import { useInternalTheme } from "../../../theme/hook/useInternalTheme.js";
|
|
|
14
14
|
import { ThumbnailCard } from "../../Content/Card/components/ThumbnailCard.js";
|
|
15
15
|
import { Text } from "../../Text/index.js";
|
|
16
16
|
import { RFValue } from 'react-native-responsive-fontsize';
|
|
17
|
+
import { useSafePressHandler } from "../../../hooks/useSafeCallback.js";
|
|
18
|
+
import { useSkeletonItems } from "../../../hooks/useSkeletonItems.js";
|
|
17
19
|
|
|
18
20
|
/**
|
|
19
21
|
* Configuration for SearchCard skeleton rendering.
|
|
@@ -51,6 +53,10 @@ const SearchCard = ({
|
|
|
51
53
|
items = 5,
|
|
52
54
|
textWidths = ['80%', '100%', '70%', '50%', '40%']
|
|
53
55
|
} = skeletonConfig ?? {};
|
|
56
|
+
const skeletonItems = useSkeletonItems(items);
|
|
57
|
+
|
|
58
|
+
// Memoize handlePress before any early returns
|
|
59
|
+
const handlePress = useSafePressHandler(onPress);
|
|
54
60
|
const renderSkeleton = () => /*#__PURE__*/_jsx(SkeletonPlaceholder, {
|
|
55
61
|
backgroundColor: skeletonBaseColor,
|
|
56
62
|
highlightColor: skeletonHighlightColor,
|
|
@@ -68,9 +74,7 @@ const SearchCard = ({
|
|
|
68
74
|
style: [styles.textContainer, {
|
|
69
75
|
marginTop: verticalScale(3)
|
|
70
76
|
}],
|
|
71
|
-
children:
|
|
72
|
-
length: items
|
|
73
|
-
}).map((_, lineIdx) => {
|
|
77
|
+
children: skeletonItems.map((_, lineIdx) => {
|
|
74
78
|
const rawWidth = textWidths[lineIdx] ?? '90%';
|
|
75
79
|
const resolvedWidth = typeof rawWidth === 'string' ? rawWidth : `${Math.min(rawWidth, 100)}%`;
|
|
76
80
|
return /*#__PURE__*/_jsx(SkeletonPlaceholder.Item, {
|
|
@@ -83,14 +87,15 @@ const SearchCard = ({
|
|
|
83
87
|
})]
|
|
84
88
|
})
|
|
85
89
|
});
|
|
90
|
+
const pressableStyle = ({
|
|
91
|
+
pressed
|
|
92
|
+
}) => [styles.card, {
|
|
93
|
+
opacity: pressed ? 0.9 : 1
|
|
94
|
+
}];
|
|
86
95
|
if (isLoading) return renderSkeleton();
|
|
87
96
|
return /*#__PURE__*/_jsxs(Pressable, {
|
|
88
|
-
onPress:
|
|
89
|
-
style:
|
|
90
|
-
pressed
|
|
91
|
-
}) => [styles.card, {
|
|
92
|
-
opacity: pressed ? 0.9 : 1
|
|
93
|
-
}],
|
|
97
|
+
onPress: handlePress,
|
|
98
|
+
style: pressableStyle,
|
|
94
99
|
accessibilityRole: "button",
|
|
95
100
|
accessibilityLabel: title,
|
|
96
101
|
disabled: !onPress,
|
|
@@ -101,7 +106,6 @@ const SearchCard = ({
|
|
|
101
106
|
theme: appliedTheme,
|
|
102
107
|
borderRadius: scale(8),
|
|
103
108
|
resizeMode: FastImage.resizeMode.cover,
|
|
104
|
-
wrapperStyle: styles.thumbnail,
|
|
105
109
|
isLoading: false
|
|
106
110
|
})
|
|
107
111
|
}), /*#__PURE__*/_jsxs(View, {
|
|
@@ -128,7 +132,7 @@ const SearchCard = ({
|
|
|
128
132
|
})]
|
|
129
133
|
});
|
|
130
134
|
};
|
|
131
|
-
export default SearchCard;
|
|
135
|
+
export default /*#__PURE__*/React.memo(SearchCard);
|
|
132
136
|
const styles = StyleSheet.create({
|
|
133
137
|
card: {
|
|
134
138
|
flexDirection: 'row',
|
|
@@ -143,14 +147,6 @@ const styles = StyleSheet.create({
|
|
|
143
147
|
justifyContent: 'center',
|
|
144
148
|
alignItems: 'center'
|
|
145
149
|
},
|
|
146
|
-
thumbnail: {
|
|
147
|
-
width: '100%',
|
|
148
|
-
height: '100%',
|
|
149
|
-
borderRadius: scale(8),
|
|
150
|
-
position: 'absolute',
|
|
151
|
-
top: 0,
|
|
152
|
-
left: 0
|
|
153
|
-
},
|
|
154
150
|
textContainer: {
|
|
155
151
|
flex: 1,
|
|
156
152
|
height: verticalScale(80),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","Pressable","StyleSheet","SkeletonPlaceholder","FastImage","scale","verticalScale","moderateScale","useInternalTheme","ThumbnailCard","Text","RFValue","jsx","_jsx","jsxs","_jsxs","SearchCard","title","thumbnail","description","category","isLoading","onPress","theme","skeletonConfig","appliedTheme","colors","textPrimary","textSecondary","skeletonBaseColor","skeletonHighlightColor","items","textWidths","renderSkeleton","backgroundColor","highlightColor","borderRadius","children","style","styles","card","imageContainer","Item","width","height","textContainer","marginTop","
|
|
1
|
+
{"version":3,"names":["React","View","Pressable","StyleSheet","SkeletonPlaceholder","FastImage","scale","verticalScale","moderateScale","useInternalTheme","ThumbnailCard","Text","RFValue","useSafePressHandler","useSkeletonItems","jsx","_jsx","jsxs","_jsxs","SearchCard","title","thumbnail","description","category","isLoading","onPress","theme","skeletonConfig","appliedTheme","colors","textPrimary","textSecondary","skeletonBaseColor","skeletonHighlightColor","items","textWidths","skeletonItems","handlePress","renderSkeleton","backgroundColor","highlightColor","borderRadius","children","style","styles","card","imageContainer","Item","width","height","textContainer","marginTop","map","_","lineIdx","rawWidth","resolvedWidth","Math","min","marginBottom","pressableStyle","pressed","opacity","accessibilityRole","accessibilityLabel","disabled","thumbnailUri","resizeMode","cover","color","numberOfLines","categoryTextLine","memo","create","flexDirection","alignItems","overflow","justifyContent","flex","marginLeft","fontSize","fontWeight","lineHeight","flexShrink","textTransform"],"sourceRoot":"../../../../../src","sources":["components/Search/components/SearchCard.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;;AAEA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,EAAEC,SAAS,EAAEC,UAAU,QAA6B,cAAc;AAC/E,OAAOC,mBAAmB,MAAM,mCAAmC;AACnE,OAAOC,SAAS,MAAM,yBAAyB;AAC/C,SAASC,KAAK,EAAEC,aAAa,EAAEC,aAAa,QAAQ,2BAA2B;AAE/E,SAASC,gBAAgB,QAAQ,yCAAsC;AAGvE,SAASC,aAAa,QAA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