create-gufran-expo-app 2.0.0 → 2.0.2
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/createApp.js +7 -2
- package/package.json +1 -1
- package/template/App.tsx +118 -0
- package/template/ReactotronConfig.js +5 -0
- package/template/android/app/build.gradle +184 -0
- package/template/android/app/debug.keystore +0 -0
- package/template/android/app/google-services.json +29 -0
- package/template/android/app/proguard-rules.pro +14 -0
- package/template/android/app/src/debug/AndroidManifest.xml +7 -0
- package/template/android/app/src/debugOptimized/AndroidManifest.xml +7 -0
- package/template/android/app/src/main/AndroidManifest.xml +28 -0
- package/template/android/app/src/main/assets/fonts/Outfit-Bold.ttf +0 -0
- package/template/android/app/src/main/assets/fonts/Outfit-Light.ttf +0 -0
- package/template/android/app/src/main/assets/fonts/Outfit-Medium.ttf +0 -0
- package/template/android/app/src/main/assets/fonts/Outfit-Regular.ttf +0 -0
- package/template/android/app/src/main/assets/fonts/Outfit-SemiBold.ttf +0 -0
- package/template/android/app/src/main/java/com/club/yakka/MainActivity.kt +61 -0
- package/template/android/app/src/main/java/com/club/yakka/MainApplication.kt +60 -0
- package/template/android/app/src/main/res/drawable/ic_launcher_background.xml +6 -0
- package/template/android/app/src/main/res/drawable/rn_edit_text_material.xml +37 -0
- package/template/android/app/src/main/res/drawable-hdpi/splashscreen_logo.png +0 -0
- package/template/android/app/src/main/res/drawable-mdpi/splashscreen_logo.png +0 -0
- package/template/android/app/src/main/res/drawable-xhdpi/splashscreen_logo.png +0 -0
- package/template/android/app/src/main/res/drawable-xxhdpi/splashscreen_logo.png +0 -0
- package/template/android/app/src/main/res/drawable-xxxhdpi/splashscreen_logo.png +0 -0
- package/template/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml +5 -0
- package/template/android/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml +5 -0
- package/template/android/app/src/main/res/mipmap-hdpi/ic_launcher.webp +0 -0
- package/template/android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.webp +0 -0
- package/template/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.webp +0 -0
- package/template/android/app/src/main/res/mipmap-mdpi/ic_launcher.webp +0 -0
- package/template/android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.webp +0 -0
- package/template/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xhdpi/ic_launcher.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.webp +0 -0
- package/template/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.webp +0 -0
- package/template/android/app/src/main/res/values/colors.xml +6 -0
- package/template/android/app/src/main/res/values/strings.xml +5 -0
- package/template/android/app/src/main/res/values/styles.xml +14 -0
- package/template/android/app/src/main/res/values-night/colors.xml +1 -0
- package/template/android/build.gradle +33 -0
- package/template/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/template/android/gradle/wrapper/gradle-wrapper.properties +7 -0
- package/template/android/gradle.properties +65 -0
- package/template/android/gradlew +251 -0
- package/template/android/gradlew.bat +94 -0
- package/template/android/settings.gradle +39 -0
- package/template/app.json +69 -0
- package/template/assets/adaptive-icon.png +0 -0
- package/template/assets/adaptive-icon1.png +0 -0
- package/template/assets/app_icon.png +0 -0
- package/template/assets/favicon.png +0 -0
- package/template/assets/icon.png +0 -0
- package/template/assets/splash-icon.png +0 -0
- package/template/babel-plugin-disable-font-scaling.js +41 -0
- package/template/babel.config.js +28 -0
- package/template/firebase.json +5 -0
- package/template/index.ts +24 -0
- package/template/ios/.xcode.env +11 -0
- package/template/ios/ClubYakka/AppDelegate.swift +74 -0
- package/template/ios/ClubYakka/ClubYakka-Bridging-Header.h +3 -0
- package/template/ios/ClubYakka/ClubYakka.entitlements +8 -0
- package/template/ios/ClubYakka/GoogleService-Info.plist +30 -0
- package/template/ios/ClubYakka/Images.xcassets/AppIcon.appiconset/App-Icon-1024x1024@1x.png +0 -0
- package/template/ios/ClubYakka/Images.xcassets/AppIcon.appiconset/Contents.json +14 -0
- package/template/ios/ClubYakka/Images.xcassets/Contents.json +6 -0
- package/template/ios/ClubYakka/Images.xcassets/SplashScreenBackground.colorset/Contents.json +20 -0
- package/template/ios/ClubYakka/Images.xcassets/SplashScreenLegacy.imageset/Contents.json +23 -0
- package/template/ios/ClubYakka/Images.xcassets/SplashScreenLegacy.imageset/image.png +0 -0
- package/template/ios/ClubYakka/Images.xcassets/SplashScreenLegacy.imageset/image@2x.png +0 -0
- package/template/ios/ClubYakka/Images.xcassets/SplashScreenLegacy.imageset/image@3x.png +0 -0
- package/template/ios/ClubYakka/Info.plist +101 -0
- package/template/ios/ClubYakka/PrivacyInfo.xcprivacy +50 -0
- package/template/ios/ClubYakka/SplashScreen.storyboard +48 -0
- package/template/ios/ClubYakka/Supporting/Expo.plist +12 -0
- package/template/ios/ClubYakka.xcodeproj/project.pbxproj +669 -0
- package/template/ios/ClubYakka.xcodeproj/xcshareddata/xcschemes/ClubYakka.xcscheme +88 -0
- package/template/ios/ClubYakka.xcworkspace/contents.xcworkspacedata +10 -0
- package/template/ios/ClubYakka.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings +5 -0
- package/template/ios/Podfile +84 -0
- package/template/ios/Podfile.lock +2698 -0
- package/template/ios/Podfile.properties.json +8 -0
- package/template/metro.config.js +17 -0
- package/template/package.json +70 -0
- package/template/patches/react-native-background-upload+6.6.0.patch +704 -0
- package/template/react-native.config.js +7 -0
- package/template/src/assets/fonts/Outfit-Bold.ttf +0 -0
- package/template/src/assets/fonts/Outfit-Light.ttf +0 -0
- package/template/src/assets/fonts/Outfit-Medium.ttf +0 -0
- package/template/src/assets/fonts/Outfit-Regular.ttf +0 -0
- package/template/src/assets/fonts/Outfit-SemiBold.ttf +0 -0
- package/template/src/assets/icons/BG.svg +33 -0
- package/template/src/assets/icons/Ic_Users.svg +6 -0
- package/template/src/assets/icons/arrow-left-white.svg +4 -0
- package/template/src/assets/icons/arrow-left.svg +4 -0
- package/template/src/assets/icons/bell.svg +4 -0
- package/template/src/assets/icons/bottomSheetIcone.svg +3 -0
- package/template/src/assets/icons/call.svg +4 -0
- package/template/src/assets/icons/camera.svg +0 -0
- package/template/src/assets/icons/chatAppleGreenBG.svg +22 -0
- package/template/src/assets/icons/check.svg +4 -0
- package/template/src/assets/icons/check_Radio.svg +4 -0
- package/template/src/assets/icons/chevron-right.svg +3 -0
- package/template/src/assets/icons/clubDefauldImage.png +0 -0
- package/template/src/assets/icons/curvBackgroundView.svg +3 -0
- package/template/src/assets/icons/defaultClub.png +0 -0
- package/template/src/assets/icons/email.svg +3 -0
- package/template/src/assets/icons/emptyUser.svg +5 -0
- package/template/src/assets/icons/eye-Hide.svg +8 -0
- package/template/src/assets/icons/eye.svg +4 -0
- package/template/src/assets/icons/gallery.svg +4 -0
- package/template/src/assets/icons/home.svg +4 -0
- package/template/src/assets/icons/ic_Calendar.svg +14 -0
- package/template/src/assets/icons/ic_Calendar_blue.svg +12 -0
- package/template/src/assets/icons/ic_Calendar_white.svg +12 -0
- package/template/src/assets/icons/ic_Chat.svg +14 -0
- package/template/src/assets/icons/ic_ChatAppleGreen.svg +21 -0
- package/template/src/assets/icons/ic_ChatAppleWhite.svg +21 -0
- package/template/src/assets/icons/ic_Download.svg +6 -0
- package/template/src/assets/icons/ic_Events.svg +6 -0
- package/template/src/assets/icons/ic_HeadCoachIcon.svg +3 -0
- package/template/src/assets/icons/ic_Membership.svg +10 -0
- package/template/src/assets/icons/ic_Notification.svg +6 -0
- package/template/src/assets/icons/ic_Raffles.svg +14 -0
- package/template/src/assets/icons/ic_Referral_Members.svg +12 -0
- package/template/src/assets/icons/ic_Shop.svg +13 -0
- package/template/src/assets/icons/ic_Teams.svg +8 -0
- package/template/src/assets/icons/ic_Volunteer.svg +9 -0
- package/template/src/assets/icons/ic_add.svg +3 -0
- package/template/src/assets/icons/ic_addCircle.svg +5 -0
- package/template/src/assets/icons/ic_chatSend.svg +4 -0
- package/template/src/assets/icons/ic_chat_blue_bg.svg +22 -0
- package/template/src/assets/icons/ic_clock_blue.svg +4 -0
- package/template/src/assets/icons/ic_delete.svg +8 -0
- package/template/src/assets/icons/ic_more.svg +5 -0
- package/template/src/assets/icons/ic_mute.svg +10 -0
- package/template/src/assets/icons/ic_pdf.svg +3 -0
- package/template/src/assets/icons/ic_pending_AppleGreen.svg +11 -0
- package/template/src/assets/icons/ic_right_appleGreen.svg +11 -0
- package/template/src/assets/icons/ic_unread_chat_blue_bg.svg +23 -0
- package/template/src/assets/icons/ic_volunteer_Member.svg +8 -0
- package/template/src/assets/icons/index.ts +144 -0
- package/template/src/assets/icons/location-blue.svg +4 -0
- package/template/src/assets/icons/location-white.svg +4 -0
- package/template/src/assets/icons/location.svg +4 -0
- package/template/src/assets/icons/lock.svg +5 -0
- package/template/src/assets/icons/log-out.svg +5 -0
- package/template/src/assets/icons/login_logo.svg +9 -0
- package/template/src/assets/icons/mail.svg +4 -0
- package/template/src/assets/icons/or_saprater.svg +5 -0
- package/template/src/assets/icons/password.svg +4 -0
- package/template/src/assets/icons/profile-appleGreen.svg +6 -0
- package/template/src/assets/icons/search.svg +3 -0
- package/template/src/assets/icons/settings.svg +4 -0
- package/template/src/assets/icons/success.svg +4 -0
- package/template/src/assets/icons/unCheck_Radio.svg +3 -0
- package/template/src/assets/icons/uncheck.svg +3 -0
- package/template/src/assets/icons/upload_Image.svg +6 -0
- package/template/src/assets/icons/upload_Image_Member.svg +6 -0
- package/template/src/assets/icons/user.svg +4 -0
- package/template/src/assets/icons/wifi.svg +1 -0
- package/template/src/assets/images/Splash.png +0 -0
- package/template/src/assets/images/SplashLogo.png +0 -0
- package/template/src/assets/images/background.png +0 -0
- package/template/src/assets/images/clubDefauldImage.png +0 -0
- package/template/src/assets/images/index.tsx +9 -0
- package/template/src/assets/index.ts +1 -0
- package/template/src/components/common/AddMemberModal.tsx +543 -0
- package/template/src/components/common/AppLoader.tsx +91 -0
- package/template/src/components/common/Button.tsx +173 -0
- package/template/src/components/common/ClubCard.tsx +248 -0
- package/template/src/components/common/Icon.tsx +93 -0
- package/template/src/components/common/IconAlt.tsx +65 -0
- package/template/src/components/common/IconButton.tsx +92 -0
- package/template/src/components/common/ImagePicker.tsx +451 -0
- package/template/src/components/common/LoadingSpinner.tsx +30 -0
- package/template/src/components/common/OTPInput.tsx +128 -0
- package/template/src/components/common/ReminderCalendar.tsx +129 -0
- package/template/src/components/common/ReminderCardItem.tsx +91 -0
- package/template/src/components/common/SafeAreaWrapper.tsx +27 -0
- package/template/src/components/common/SetReminderModal.tsx +308 -0
- package/template/src/components/common/SlowInternet.js +57 -0
- package/template/src/components/common/TeamCard.tsx +297 -0
- package/template/src/components/common/TextInput.tsx +227 -0
- package/template/src/components/common/ToastConfig.tsx +103 -0
- package/template/src/components/common/ToastManager.ts +86 -0
- package/template/src/components/common/UploadProgressModal.tsx +284 -0
- package/template/src/components/common/WrapperContainer.tsx +39 -0
- package/template/src/components/common/index.ts +19 -0
- package/template/src/constants/Constants.tsx +7 -0
- package/template/src/constants/Fonts.tsx +30 -0
- package/template/src/constants/index.ts +45 -0
- package/template/src/constants/strings.ts +211 -0
- package/template/src/constants/theme.ts +72 -0
- package/template/src/contexts/AuthContext.tsx +268 -0
- package/template/src/contexts/index.ts +2 -0
- package/template/src/hooks/index.ts +3 -0
- package/template/src/hooks/useImageUpload.ts +199 -0
- package/template/src/index.ts +8 -0
- package/template/src/navigation/AuthStack.tsx +67 -0
- package/template/src/navigation/MainStack.tsx +183 -0
- package/template/src/navigation/MiddleStack.tsx +35 -0
- package/template/src/navigation/RootNavigator.tsx +101 -0
- package/template/src/navigation/index.ts +5 -0
- package/template/src/navigation/navigationRef.ts +5 -0
- package/template/src/providers/QueryProvider.tsx +30 -0
- package/template/src/screens/DetailsScreen.tsx +271 -0
- package/template/src/screens/HomeScreen.tsx +736 -0
- package/template/src/screens/ProfileScreen.tsx +202 -0
- package/template/src/screens/SettingsScreen.tsx +253 -0
- package/template/src/screens/SportHubScreen.tsx +280 -0
- package/template/src/screens/auth/AddMamber.tsx +428 -0
- package/template/src/screens/auth/ForgotPasswordScreen.tsx +176 -0
- package/template/src/screens/auth/LoginScreen.tsx +286 -0
- package/template/src/screens/auth/OTPVerifyScreen.tsx +359 -0
- package/template/src/screens/auth/RegisterScreen.tsx +430 -0
- package/template/src/screens/auth/SuccessScreen.tsx +201 -0
- package/template/src/screens/auth/WalcomeScreen.tsx +274 -0
- package/template/src/screens/auth/index.ts +8 -0
- package/template/src/screens/chat/ChatScreen.tsx +1819 -0
- package/template/src/screens/chat/ChatThreadsScreen.tsx +360 -0
- package/template/src/screens/chat/ReportMessageScreen.tsx +238 -0
- package/template/src/screens/clubs/Announcements.tsx +426 -0
- package/template/src/screens/clubs/BuyRaffleTicketsScreen.tsx +568 -0
- package/template/src/screens/clubs/ClubDeteils.tsx +497 -0
- package/template/src/screens/clubs/JoinClub.tsx +841 -0
- package/template/src/screens/events/EventScreen.tsx +460 -0
- package/template/src/screens/index.ts +42 -0
- package/template/src/screens/raffles/MyReferralMembersScreen.tsx +758 -0
- package/template/src/screens/raffles/RaffleDetailsScreen.tsx +762 -0
- package/template/src/screens/raffles/RafflesScreen.tsx +495 -0
- package/template/src/screens/raffles/SetRaffleReminderScreen.tsx +390 -0
- package/template/src/screens/teams/JoinTeamScreen.tsx +464 -0
- package/template/src/screens/teams/MyTeamDetailsScreen.tsx +979 -0
- package/template/src/screens/teams/MyTeamScreen.tsx +568 -0
- package/template/src/screens/teams/PendingRequestsScreen.tsx +426 -0
- package/template/src/screens/volunteerOpportunities/SetReminderScreen.tsx +631 -0
- package/template/src/screens/volunteerOpportunities/VolunteerOpportunitiesDetailsScreen.tsx +1049 -0
- package/template/src/screens/volunteerOpportunities/VolunteerOpportunitiesScreen.tsx +608 -0
- package/template/src/services/api.ts +167 -0
- package/template/src/services/authService.ts +422 -0
- package/template/src/services/index.ts +5 -0
- package/template/src/services/mainServices.ts +1963 -0
- package/template/src/stores/authStore.ts +159 -0
- package/template/src/stores/index.ts +2 -0
- package/template/src/types/index.ts +85 -0
- package/template/src/types/navigation.ts +206 -0
- package/template/src/utils/AzureUploaderService.ts +371 -0
- package/template/src/utils/ClubSearchManager.ts +222 -0
- package/template/src/utils/NotificationManager.ts +503 -0
- package/template/src/utils/UploadDebugUtil.ts +107 -0
- package/template/src/utils/imagePicker.ts +321 -0
- package/template/src/utils/index.ts +111 -0
- package/template/src/utils/permissions.ts +277 -0
- package/template/src/utils/scaling.ts +14 -0
- package/template/src/utils/storage.ts +247 -0
- package/template/src/utils/usePermissions.ts +275 -0
- package/template/src/utils/validation.ts +340 -0
- package/template/tsconfig.json +50 -0
- package/template/types/svg.d.ts +6 -0
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
import React, { useState, useRef } from 'react';
|
|
2
|
+
import {
|
|
3
|
+
View,
|
|
4
|
+
Text,
|
|
5
|
+
StyleSheet,
|
|
6
|
+
Dimensions,
|
|
7
|
+
TouchableOpacity,
|
|
8
|
+
ScrollView,
|
|
9
|
+
StatusBar,
|
|
10
|
+
ImageBackground,
|
|
11
|
+
} from 'react-native';
|
|
12
|
+
import { SafeAreaView } from 'react-native-safe-area-context';
|
|
13
|
+
import { useNavigation } from '@react-navigation/native';
|
|
14
|
+
import { NativeStackNavigationProp } from '@react-navigation/native-stack';
|
|
15
|
+
import { theme } from '../../constants';
|
|
16
|
+
import { Fonts } from '../../constants/Fonts';
|
|
17
|
+
import { AuthStackParamList } from '../../types/navigation';
|
|
18
|
+
import Images from '../../assets/images';
|
|
19
|
+
import { moderateScale, verticalScale } from '../../utils/scaling';
|
|
20
|
+
import SVG from '../../assets/icons';
|
|
21
|
+
import { Button } from '../../components/common';
|
|
22
|
+
import { StorageService } from '../../utils/storage';
|
|
23
|
+
|
|
24
|
+
const { width: SCREEN_WIDTH, height: SCREEN_HEIGHT } = Dimensions.get('window');
|
|
25
|
+
|
|
26
|
+
type WelcomeScreenNavigationProp = NativeStackNavigationProp<AuthStackParamList, 'Login'>;
|
|
27
|
+
|
|
28
|
+
interface OnboardingSlide {
|
|
29
|
+
id: number;
|
|
30
|
+
subtitle: string;
|
|
31
|
+
description: string;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
const onboardingSlides: OnboardingSlide[] = [
|
|
35
|
+
{
|
|
36
|
+
id: 1,
|
|
37
|
+
subtitle: 'Your Game, Your Club, Your Community.',
|
|
38
|
+
description: 'Join a new era of sports where players, coaches, and fans stay connected, motivated, and ready to win.',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
id: 2,
|
|
42
|
+
subtitle: 'Your Game, Your Club, Your Community.',
|
|
43
|
+
description: 'Join a new era of sports where players, coaches, and fans stay connected, motivated, and ready to win.',
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
id: 3,
|
|
47
|
+
subtitle: 'Your Game, Your Club, Your Community.',
|
|
48
|
+
description: 'Join a new era of sports where players, coaches, and fans stay connected, motivated, and ready to win.',
|
|
49
|
+
},
|
|
50
|
+
];
|
|
51
|
+
|
|
52
|
+
const WelcomeScreen: React.FC = () => {
|
|
53
|
+
const navigation = useNavigation<WelcomeScreenNavigationProp>();
|
|
54
|
+
const [currentSlideIndex, setCurrentSlideIndex] = useState(0);
|
|
55
|
+
const scrollViewRef = useRef<ScrollView>(null);
|
|
56
|
+
|
|
57
|
+
const handleSlideChange = (index: number) => {
|
|
58
|
+
setCurrentSlideIndex(index);
|
|
59
|
+
scrollViewRef.current?.scrollTo({
|
|
60
|
+
x: index * SCREEN_WIDTH,
|
|
61
|
+
animated: true,
|
|
62
|
+
});
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
const handleSignIn = () => {
|
|
66
|
+
// Mark welcome screen as shown before navigating
|
|
67
|
+
StorageService.preferences.setWelcomeScreenShown(true);
|
|
68
|
+
navigation.reset({
|
|
69
|
+
index: 0,
|
|
70
|
+
routes: [{ name: 'Login' }],
|
|
71
|
+
});
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
const handleSignUp = () => {
|
|
75
|
+
// Mark welcome screen as shown before navigating
|
|
76
|
+
StorageService.preferences.setWelcomeScreenShown(true);
|
|
77
|
+
navigation.reset({
|
|
78
|
+
index: 0,
|
|
79
|
+
routes: [{ name: 'Register' }],
|
|
80
|
+
});
|
|
81
|
+
};
|
|
82
|
+
|
|
83
|
+
const renderSlide = ({ item, index }: { item: OnboardingSlide; index: number }) => (
|
|
84
|
+
<View style={styles.slideContent}>
|
|
85
|
+
<Text style={styles.slideDescription}>{item.description}</Text>
|
|
86
|
+
<Text style={styles.slideSubtitle}>{item.subtitle}</Text>
|
|
87
|
+
</View>
|
|
88
|
+
|
|
89
|
+
);
|
|
90
|
+
|
|
91
|
+
const renderPaginationDots = () => (
|
|
92
|
+
<View style={styles.paginationContainer}>
|
|
93
|
+
{onboardingSlides.map((slide, index) => (
|
|
94
|
+
<TouchableOpacity
|
|
95
|
+
key={`pagination-${slide.id}`}
|
|
96
|
+
style={[
|
|
97
|
+
styles.paginationDot,
|
|
98
|
+
index === currentSlideIndex && styles.activePaginationDot,
|
|
99
|
+
]}
|
|
100
|
+
onPress={() => handleSlideChange(index)}
|
|
101
|
+
/>
|
|
102
|
+
))}
|
|
103
|
+
</View>
|
|
104
|
+
);
|
|
105
|
+
|
|
106
|
+
return (
|
|
107
|
+
<ImageBackground
|
|
108
|
+
source={Images.backgroundImage}
|
|
109
|
+
style={styles.backgroundImage}
|
|
110
|
+
resizeMode="cover"
|
|
111
|
+
>
|
|
112
|
+
<SafeAreaView edges={['top']} style={styles.container}>
|
|
113
|
+
<StatusBar barStyle="dark-content" backgroundColor="transparent" translucent />
|
|
114
|
+
|
|
115
|
+
{/* Logo Section */}
|
|
116
|
+
<View style={styles.logoSection}>
|
|
117
|
+
<SVG.login_logo
|
|
118
|
+
height={moderateScale(200)}
|
|
119
|
+
width={moderateScale(200)}
|
|
120
|
+
style={styles.logoIcon}
|
|
121
|
+
/>
|
|
122
|
+
</View>
|
|
123
|
+
|
|
124
|
+
{/* Curved Background Content Card */}
|
|
125
|
+
<View style={styles.curvedBackgroundContainer}>
|
|
126
|
+
<SVG.curvViewImage
|
|
127
|
+
width={SCREEN_WIDTH}
|
|
128
|
+
height={verticalScale(430)}
|
|
129
|
+
style={styles.curvedBackgroundImage}
|
|
130
|
+
/>
|
|
131
|
+
|
|
132
|
+
<View style={styles.contentCard}>
|
|
133
|
+
{/* Interactive Slider */}
|
|
134
|
+
<ScrollView
|
|
135
|
+
ref={scrollViewRef}
|
|
136
|
+
horizontal
|
|
137
|
+
pagingEnabled
|
|
138
|
+
showsHorizontalScrollIndicator={false}
|
|
139
|
+
onMomentumScrollEnd={(event) => {
|
|
140
|
+
const index = Math.round(event.nativeEvent.contentOffset.x / SCREEN_WIDTH);
|
|
141
|
+
setCurrentSlideIndex(index);
|
|
142
|
+
}}
|
|
143
|
+
>
|
|
144
|
+
{onboardingSlides.map((slide, index) => (
|
|
145
|
+
<View key={slide.id} style={styles.slideWrapper}>
|
|
146
|
+
{renderSlide({ item: slide, index })}
|
|
147
|
+
</View>
|
|
148
|
+
))}
|
|
149
|
+
</ScrollView>
|
|
150
|
+
|
|
151
|
+
{/* Pagination Dots */}
|
|
152
|
+
{renderPaginationDots()}
|
|
153
|
+
|
|
154
|
+
{/* Action Buttons */}
|
|
155
|
+
<View style={styles.buttonContainer}>
|
|
156
|
+
<Button
|
|
157
|
+
title="Sign In"
|
|
158
|
+
onPress={handleSignIn}
|
|
159
|
+
variant="outline"
|
|
160
|
+
size="medium"
|
|
161
|
+
textStyle={styles.signInButtonText}
|
|
162
|
+
/>
|
|
163
|
+
<Button
|
|
164
|
+
title="Sign Up"
|
|
165
|
+
onPress={handleSignUp}
|
|
166
|
+
variant="primary"
|
|
167
|
+
size="medium"
|
|
168
|
+
style={styles.signUpButton}
|
|
169
|
+
/>
|
|
170
|
+
</View>
|
|
171
|
+
</View>
|
|
172
|
+
</View>
|
|
173
|
+
</SafeAreaView>
|
|
174
|
+
</ImageBackground>
|
|
175
|
+
);
|
|
176
|
+
};
|
|
177
|
+
|
|
178
|
+
const styles = StyleSheet.create({
|
|
179
|
+
container: {
|
|
180
|
+
flex: 1,
|
|
181
|
+
},
|
|
182
|
+
backgroundImage: {
|
|
183
|
+
flex: 1,
|
|
184
|
+
width: '100%',
|
|
185
|
+
height: '100%',
|
|
186
|
+
},
|
|
187
|
+
logoSection: {
|
|
188
|
+
justifyContent: 'center',
|
|
189
|
+
alignItems: 'center',
|
|
190
|
+
paddingTop: verticalScale(40),
|
|
191
|
+
paddingBottom: verticalScale(20),
|
|
192
|
+
},
|
|
193
|
+
logoIcon: {
|
|
194
|
+
marginBottom: verticalScale(16),
|
|
195
|
+
},
|
|
196
|
+
curvedBackgroundContainer: {
|
|
197
|
+
flex: 1,
|
|
198
|
+
position: 'relative',
|
|
199
|
+
marginTop: verticalScale(20),
|
|
200
|
+
},
|
|
201
|
+
curvedBackgroundImage: {
|
|
202
|
+
position: 'absolute',
|
|
203
|
+
top: 0,
|
|
204
|
+
left: 0,
|
|
205
|
+
zIndex: 1,
|
|
206
|
+
},
|
|
207
|
+
contentCard: {
|
|
208
|
+
flex: 1,
|
|
209
|
+
backgroundColor: 'transparent',
|
|
210
|
+
paddingTop: verticalScale(90),
|
|
211
|
+
paddingHorizontal: theme.spacing.lg,
|
|
212
|
+
zIndex: 2,
|
|
213
|
+
},
|
|
214
|
+
|
|
215
|
+
slideWrapper: {
|
|
216
|
+
width: SCREEN_WIDTH - (theme.spacing.lg * 2),
|
|
217
|
+
},
|
|
218
|
+
slideContainer: {
|
|
219
|
+
},
|
|
220
|
+
slideContent: {
|
|
221
|
+
alignItems: 'center',
|
|
222
|
+
},
|
|
223
|
+
|
|
224
|
+
slideSubtitle: {
|
|
225
|
+
alignSelf: 'flex-start',
|
|
226
|
+
fontSize: theme.typography.fontSize.md,
|
|
227
|
+
color: theme.colors.black,
|
|
228
|
+
fontFamily: Fonts.outfitRegular,
|
|
229
|
+
marginTop: theme.spacing.sm,
|
|
230
|
+
},
|
|
231
|
+
|
|
232
|
+
slideDescription: {
|
|
233
|
+
fontSize: theme.typography.fontSize.lg,
|
|
234
|
+
color: theme.colors.black,
|
|
235
|
+
fontFamily: Fonts.outfitRegular,
|
|
236
|
+
},
|
|
237
|
+
paginationContainer: {
|
|
238
|
+
flexDirection: 'row',
|
|
239
|
+
alignItems: 'center',
|
|
240
|
+
marginBottom: theme.spacing.xl,
|
|
241
|
+
},
|
|
242
|
+
paginationDot: {
|
|
243
|
+
width: moderateScale(8),
|
|
244
|
+
height: moderateScale(8),
|
|
245
|
+
borderRadius: moderateScale(4),
|
|
246
|
+
backgroundColor: theme.colors.border,
|
|
247
|
+
marginHorizontal: theme.spacing.xs,
|
|
248
|
+
},
|
|
249
|
+
activePaginationDot: {
|
|
250
|
+
width: moderateScale(24),
|
|
251
|
+
height: moderateScale(8),
|
|
252
|
+
borderRadius: moderateScale(4),
|
|
253
|
+
backgroundColor: theme.colors.appleGreen,
|
|
254
|
+
},
|
|
255
|
+
buttonContainer: {
|
|
256
|
+
paddingBottom: theme.spacing.xl,
|
|
257
|
+
},
|
|
258
|
+
signInButton: {
|
|
259
|
+
backgroundColor: theme.colors.white,
|
|
260
|
+
borderColor: theme.colors.appleGreen,
|
|
261
|
+
marginBottom: theme.spacing.md,
|
|
262
|
+
},
|
|
263
|
+
signInButtonText: {
|
|
264
|
+
fontSize: theme.typography.fontSize.md,
|
|
265
|
+
fontWeight: theme.typography.fontWeight.semibold,
|
|
266
|
+
color: theme.colors.appleGreen,
|
|
267
|
+
},
|
|
268
|
+
signUpButton: {
|
|
269
|
+
marginVertical: theme.spacing.md,
|
|
270
|
+
},
|
|
271
|
+
});
|
|
272
|
+
|
|
273
|
+
export { WelcomeScreen };
|
|
274
|
+
export default WelcomeScreen;
|