@fadyshawky/react-native-magic 2.0.1 → 2.0.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/package.json +1 -1
- package/template/src/common/components/Cards.tsx +5 -5
- package/template/src/common/components/EmptyView.tsx +1 -1
- package/template/src/common/components/ImageCropPickerButton.tsx +1 -1
- package/template/src/common/components/OTPInput.tsx +5 -5
- package/template/src/common/components/PhotoTakingButton.tsx +2 -2
- package/template/src/common/components/PrimaryButton.tsx +19 -19
- package/template/src/common/components/PrimaryTextInput.tsx +195 -129
- package/template/src/common/components/RadioButton.tsx +2 -2
- package/template/src/common/components/RadioIcon.tsx +4 -4
- package/template/src/common/components/SearchBar.tsx +13 -13
- package/template/src/common/components/Separator.tsx +1 -1
- package/template/src/common/components/Stepper.tsx +153 -0
- package/template/src/common/components/TryAgain.tsx +3 -3
- package/template/src/common/helpers/defaultKeyIdExtractor.ts +1 -1
- package/template/src/common/helpers/shareHelpers.ts +47 -0
- package/template/src/common/helpers/stringsHelpers.ts +0 -4
- package/template/src/core/api/errorHandler.ts +1 -2
- package/template/src/core/store/app/appSlice.ts +5 -13
- package/template/src/core/store/app/appState.ts +2 -10
- package/template/src/core/theme/colors.ts +94 -72
- package/template/src/core/theme/commonSizes.ts +110 -43
- package/template/src/core/theme/commonStyles.ts +22 -22
- package/template/src/core/theme/fonts.ts +13 -14
- package/template/src/core/theme/shadows.ts +135 -0
- package/template/src/core/theme/themes.ts +386 -75
- package/template/src/core/theme/types.ts +145 -18
- package/template/src/navigation/HeaderComponents.tsx +1 -1
- package/template/src/navigation/MainNavigation.tsx +1 -2
- package/template/src/navigation/MainStack.tsx +1 -1
- package/template/src/navigation/TabBar.tsx +3 -3
- package/template/src/navigation/TopTabBar.tsx +5 -3
- package/template/src/screens/Login/Login.tsx +0 -14
- package/template/src/screens/home/HomeScreen.tsx +14 -14
- package/template/src/screens/home/components/CarouselSection.tsx +9 -9
- package/template/src/screens/home/components/FeaturedCarousel.tsx +10 -10
- package/template/src/screens/registration/RegistrationScreen.tsx +6 -6
- package/template/src/screens/resetPassword/ForgotPasswordScreen.tsx +6 -6
- package/template/src/types/react-native-config.d.ts +8 -0
|
@@ -1,9 +1,23 @@
|
|
|
1
1
|
import {TextStyle} from 'react-native';
|
|
2
|
+
import {ElevationShadow} from './shadows';
|
|
3
|
+
import {PrimaryColors, NaturalColors, AlertColors} from './colors';
|
|
2
4
|
|
|
3
5
|
export type ThemeMode = 'light' | 'dark';
|
|
4
6
|
|
|
5
7
|
export interface ISize {
|
|
6
8
|
font: {
|
|
9
|
+
// Almarai Design System Typography
|
|
10
|
+
bodySmall: number;
|
|
11
|
+
bodyMedium: number;
|
|
12
|
+
bodyLarge: number;
|
|
13
|
+
bodyXLarge: number;
|
|
14
|
+
heading6: number;
|
|
15
|
+
heading4: number;
|
|
16
|
+
heading3: number;
|
|
17
|
+
heading2: number;
|
|
18
|
+
heading1: number;
|
|
19
|
+
|
|
20
|
+
// Legacy support
|
|
7
21
|
extraSmall: number;
|
|
8
22
|
extraSmallPlus: number;
|
|
9
23
|
small: number;
|
|
@@ -17,6 +31,18 @@ export interface ISize {
|
|
|
17
31
|
extraLargePlus: number;
|
|
18
32
|
};
|
|
19
33
|
letterSpacing: {
|
|
34
|
+
// Almarai Design System
|
|
35
|
+
bodySmall: number;
|
|
36
|
+
bodyMedium: number;
|
|
37
|
+
bodyLarge: number;
|
|
38
|
+
bodyXLarge: number;
|
|
39
|
+
heading6: number;
|
|
40
|
+
heading4: number;
|
|
41
|
+
heading3: number;
|
|
42
|
+
heading2: number;
|
|
43
|
+
heading1: number;
|
|
44
|
+
|
|
45
|
+
// Legacy support
|
|
20
46
|
extraSmall: number;
|
|
21
47
|
extraSmallPlus: number;
|
|
22
48
|
small: number;
|
|
@@ -29,6 +55,18 @@ export interface ISize {
|
|
|
29
55
|
extraLargePlus: number;
|
|
30
56
|
};
|
|
31
57
|
lineHeight: {
|
|
58
|
+
// Almarai Design System
|
|
59
|
+
bodySmall: number;
|
|
60
|
+
bodyMedium: number;
|
|
61
|
+
bodyLarge: number;
|
|
62
|
+
bodyXLarge: number;
|
|
63
|
+
heading6: number;
|
|
64
|
+
heading4: number;
|
|
65
|
+
heading3: number;
|
|
66
|
+
heading2: number;
|
|
67
|
+
heading1: number;
|
|
68
|
+
|
|
69
|
+
// Legacy support
|
|
32
70
|
extraSmall: number;
|
|
33
71
|
extraSmallPlus: number;
|
|
34
72
|
small: number;
|
|
@@ -41,6 +79,21 @@ export interface ISize {
|
|
|
41
79
|
extraLargePlus: number;
|
|
42
80
|
};
|
|
43
81
|
spacing: {
|
|
82
|
+
// Design System Spacing Scale
|
|
83
|
+
none: number; // space / 0
|
|
84
|
+
xSmall: number; // space / 2
|
|
85
|
+
small: number; // space / 4
|
|
86
|
+
medium: number; // space / 8
|
|
87
|
+
large: number; // space / 12
|
|
88
|
+
xLarge: number; // space / 16
|
|
89
|
+
xxLarge: number; // space / 24 (2X-Large)
|
|
90
|
+
xxxLarge: number; // space / 32 (3X-Large)
|
|
91
|
+
xxxxLarge: number; // space / 48 (4X-Large)
|
|
92
|
+
xxxxxLarge: number; // space / 64 (5X-Large)
|
|
93
|
+
xxxxxxLarge: number; // space / 80 (6X-Large)
|
|
94
|
+
full: number; // space / 100 (Full)
|
|
95
|
+
|
|
96
|
+
// Legacy support
|
|
44
97
|
xs: number;
|
|
45
98
|
sm: number;
|
|
46
99
|
md: number;
|
|
@@ -48,6 +101,17 @@ export interface ISize {
|
|
|
48
101
|
xl: number;
|
|
49
102
|
};
|
|
50
103
|
borderRadius: {
|
|
104
|
+
// Design System Border Radius Scale
|
|
105
|
+
none: number; // Border / 0
|
|
106
|
+
xSmall: number; // Border / 2
|
|
107
|
+
small: number; // Border / 4
|
|
108
|
+
medium: number; // Border / 8
|
|
109
|
+
large: number; // Border / 12
|
|
110
|
+
xLarge: number; // Border / 16
|
|
111
|
+
xxLarge: number; // Border / 24 (2X-Large)
|
|
112
|
+
full: number; // Border / 1000 (Full)
|
|
113
|
+
|
|
114
|
+
// Legacy support
|
|
51
115
|
xs: number;
|
|
52
116
|
sm: number;
|
|
53
117
|
md: number;
|
|
@@ -55,32 +119,52 @@ export interface ISize {
|
|
|
55
119
|
xl: number;
|
|
56
120
|
};
|
|
57
121
|
borderWidth: {
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
122
|
+
// Design System Stroke Scale
|
|
123
|
+
none: number; // Stroke / 0
|
|
124
|
+
xSmall: number; // Stroke / 0.5
|
|
125
|
+
small: number; // Stroke / 1
|
|
126
|
+
medium: number; // Stroke / 1.5
|
|
127
|
+
large: number; // Stroke / 2
|
|
128
|
+
|
|
129
|
+
// Legacy support
|
|
130
|
+
extraSmall: number;
|
|
61
131
|
};
|
|
62
132
|
}
|
|
63
133
|
|
|
64
134
|
export interface Theme {
|
|
65
135
|
mode: ThemeMode;
|
|
66
|
-
colors:
|
|
67
|
-
indigoBlue: string;
|
|
68
|
-
mutedLavender: string;
|
|
69
|
-
tintColor: string;
|
|
70
|
-
mutedLavender30: string;
|
|
71
|
-
balanceBackground: string;
|
|
72
|
-
white: string;
|
|
73
|
-
backgroundOpacity: string;
|
|
74
|
-
black: string;
|
|
75
|
-
background: string;
|
|
76
|
-
surface: string;
|
|
77
|
-
card: string;
|
|
78
|
-
shadow: string;
|
|
79
|
-
red: string;
|
|
80
|
-
};
|
|
136
|
+
colors: typeof PrimaryColors & typeof NaturalColors & typeof AlertColors;
|
|
81
137
|
text: {
|
|
138
|
+
// Almarai Design System Typography
|
|
139
|
+
// Headings
|
|
82
140
|
header1: TextStyle;
|
|
83
141
|
header2: TextStyle;
|
|
142
|
+
header3: TextStyle;
|
|
143
|
+
header4: TextStyle;
|
|
144
|
+
header6: TextStyle;
|
|
145
|
+
|
|
146
|
+
// Body Text with different weights
|
|
147
|
+
bodyXLargeLight: TextStyle;
|
|
148
|
+
bodyXLargeRegular: TextStyle;
|
|
149
|
+
bodyXLargeBold: TextStyle;
|
|
150
|
+
bodyXLargeExtraBold: TextStyle;
|
|
151
|
+
|
|
152
|
+
bodyLargeLight: TextStyle;
|
|
153
|
+
bodyLargeRegular: TextStyle;
|
|
154
|
+
bodyLargeBold: TextStyle;
|
|
155
|
+
bodyLargeExtraBold: TextStyle;
|
|
156
|
+
|
|
157
|
+
bodyMediumLight: TextStyle;
|
|
158
|
+
bodyMediumRegular: TextStyle;
|
|
159
|
+
bodyMediumBold: TextStyle;
|
|
160
|
+
bodyMediumExtraBold: TextStyle;
|
|
161
|
+
|
|
162
|
+
bodySmallLight: TextStyle;
|
|
163
|
+
bodySmallRegular: TextStyle;
|
|
164
|
+
bodySmallBold: TextStyle;
|
|
165
|
+
bodySmallExtraBold: TextStyle;
|
|
166
|
+
|
|
167
|
+
// Legacy styles for backward compatibility
|
|
84
168
|
balanceTitle: TextStyle;
|
|
85
169
|
balanceAmount: TextStyle;
|
|
86
170
|
balanceLabel: TextStyle;
|
|
@@ -94,6 +178,21 @@ export interface Theme {
|
|
|
94
178
|
navBar: TextStyle;
|
|
95
179
|
};
|
|
96
180
|
spacing: {
|
|
181
|
+
// Design System Spacing Scale
|
|
182
|
+
none: number;
|
|
183
|
+
xSmall: number;
|
|
184
|
+
small: number;
|
|
185
|
+
medium: number;
|
|
186
|
+
large: number;
|
|
187
|
+
xLarge: number;
|
|
188
|
+
xxLarge: number;
|
|
189
|
+
xxxLarge: number;
|
|
190
|
+
xxxxLarge: number;
|
|
191
|
+
xxxxxLarge: number;
|
|
192
|
+
xxxxxxLarge: number;
|
|
193
|
+
full: number;
|
|
194
|
+
|
|
195
|
+
// Legacy support
|
|
97
196
|
xs: number;
|
|
98
197
|
sm: number;
|
|
99
198
|
md: number;
|
|
@@ -101,10 +200,38 @@ export interface Theme {
|
|
|
101
200
|
xl: number;
|
|
102
201
|
};
|
|
103
202
|
borderRadius: {
|
|
203
|
+
// Design System Border Radius Scale
|
|
204
|
+
none: number;
|
|
205
|
+
xSmall: number;
|
|
206
|
+
small: number;
|
|
207
|
+
medium: number;
|
|
208
|
+
large: number;
|
|
209
|
+
xLarge: number;
|
|
210
|
+
xxLarge: number;
|
|
211
|
+
full: number;
|
|
212
|
+
|
|
213
|
+
// Legacy support
|
|
104
214
|
xs: number;
|
|
105
215
|
sm: number;
|
|
106
216
|
md: number;
|
|
107
217
|
lg: number;
|
|
108
218
|
xl: number;
|
|
109
219
|
};
|
|
220
|
+
borderWidth: {
|
|
221
|
+
// Design System Stroke Scale
|
|
222
|
+
none: number;
|
|
223
|
+
xSmall: number;
|
|
224
|
+
small: number;
|
|
225
|
+
medium: number;
|
|
226
|
+
large: number;
|
|
227
|
+
|
|
228
|
+
// Legacy support
|
|
229
|
+
extraSmall: number;
|
|
230
|
+
};
|
|
231
|
+
shadows: {
|
|
232
|
+
elevation1: ElevationShadow;
|
|
233
|
+
elevation2: ElevationShadow;
|
|
234
|
+
elevation3: ElevationShadow;
|
|
235
|
+
elevation4: ElevationShadow;
|
|
236
|
+
};
|
|
110
237
|
}
|
|
@@ -35,7 +35,7 @@ const styles = StyleSheet.create({
|
|
|
35
35
|
backgroundColor: 'white',
|
|
36
36
|
justifyContent: 'flex-start',
|
|
37
37
|
alignItems: 'center',
|
|
38
|
-
paddingHorizontal: CommonSizes.spacing.
|
|
38
|
+
paddingHorizontal: CommonSizes.spacing.large,
|
|
39
39
|
flexDirection: 'row',
|
|
40
40
|
},
|
|
41
41
|
titleContainer: {
|
|
@@ -4,7 +4,6 @@ import {DefaultTheme, NavigationContainer} from '@react-navigation/native';
|
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import {useRef} from 'react';
|
|
6
6
|
import {useAppSelector} from '../core/store/reduxHelpers';
|
|
7
|
-
import {Colors} from '../core/theme/colors';
|
|
8
7
|
import {AuthStack} from './AuthStack';
|
|
9
8
|
import {AppMainNavigator} from './MainStack';
|
|
10
9
|
import {navigationRef} from './RootNavigation';
|
|
@@ -23,7 +22,7 @@ function AppNavigator() {
|
|
|
23
22
|
dark: false,
|
|
24
23
|
colors: {
|
|
25
24
|
primary: '#000',
|
|
26
|
-
background:
|
|
25
|
+
background: 'white',
|
|
27
26
|
card: '#fff',
|
|
28
27
|
text: '#000',
|
|
29
28
|
border: '#000',
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import {View, Text, TouchableOpacity, Image, StyleSheet} from 'react-native';
|
|
3
3
|
import {CommonStyles} from '../core/theme/commonStyles';
|
|
4
|
-
import {Colors} from '../core/theme/colors';
|
|
5
4
|
import {
|
|
6
5
|
BottomTabBarProps,
|
|
7
6
|
BottomTabNavigationOptions,
|
|
8
7
|
} from '@react-navigation/bottom-tabs';
|
|
9
8
|
import {ImageSourcePropType} from 'react-native';
|
|
10
9
|
import {toString} from 'lodash';
|
|
10
|
+
import {NaturalColors, PrimaryColors} from '../core/theme/colors';
|
|
11
11
|
|
|
12
12
|
interface TabBarOptions extends BottomTabNavigationOptions {
|
|
13
13
|
selectedIcon: ImageSourcePropType;
|
|
@@ -86,9 +86,9 @@ const styles = StyleSheet.create({
|
|
|
86
86
|
alignItems: 'center',
|
|
87
87
|
},
|
|
88
88
|
label: {
|
|
89
|
-
color:
|
|
89
|
+
color: NaturalColors.grayScale_50,
|
|
90
90
|
},
|
|
91
91
|
labelFocused: {
|
|
92
|
-
color:
|
|
92
|
+
color: PrimaryColors.PlatinateBlue_700,
|
|
93
93
|
},
|
|
94
94
|
});
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {Animated, View, TouchableOpacity} from 'react-native';
|
|
2
|
-
import {Colors} from '../core/theme/colors';
|
|
3
2
|
import {CommonStyles, screenWidth} from '../core/theme/commonStyles';
|
|
3
|
+
import {NaturalColors} from '../core/theme/colors';
|
|
4
4
|
|
|
5
5
|
export function TopBar({state, descriptors, navigation, position}: any) {
|
|
6
6
|
return (
|
|
7
7
|
<View
|
|
8
8
|
style={{
|
|
9
9
|
flexDirection: 'row',
|
|
10
|
-
backgroundColor:
|
|
10
|
+
backgroundColor: NaturalColors.grayScale_50,
|
|
11
11
|
width: screenWidth - 60,
|
|
12
12
|
alignSelf: 'center',
|
|
13
13
|
height: 40,
|
|
@@ -56,7 +56,9 @@ export function TopBar({state, descriptors, navigation, position}: any) {
|
|
|
56
56
|
flex: 1,
|
|
57
57
|
alignItems: 'center',
|
|
58
58
|
justifyContent: 'center',
|
|
59
|
-
backgroundColor: isFocused
|
|
59
|
+
backgroundColor: isFocused
|
|
60
|
+
? NaturalColors.grayScale_0
|
|
61
|
+
: NaturalColors.grayScale_50,
|
|
60
62
|
borderRadius: 20,
|
|
61
63
|
}}>
|
|
62
64
|
<Animated.Text
|
|
@@ -19,7 +19,6 @@ import {useInputError} from '../../common/validations/hooks/useInputError';
|
|
|
19
19
|
import {emailValidations} from '../../common/validations/profileValidations';
|
|
20
20
|
import {useAppDispatch} from '../../core/store/reduxHelpers';
|
|
21
21
|
import {userLogin} from '../../core/store/user/userActions';
|
|
22
|
-
import {Colors} from '../../core/theme/colors';
|
|
23
22
|
import {CommonSizes} from '../../core/theme/commonSizes';
|
|
24
23
|
import {CommonStyles} from '../../core/theme/commonStyles';
|
|
25
24
|
import type {RootStackParamList} from '../../navigation/types';
|
|
@@ -111,22 +110,12 @@ export function Login(): JSX.Element {
|
|
|
111
110
|
placeholder={localization.login.EnterPassword}
|
|
112
111
|
error={passwordError}
|
|
113
112
|
/>
|
|
114
|
-
<PrimaryButton
|
|
115
|
-
onPress={goToForgotPassword}
|
|
116
|
-
label={localization.login.forgetPassword}
|
|
117
|
-
type={ButtonType.borderless}
|
|
118
|
-
/>
|
|
119
113
|
<PrimaryButton
|
|
120
114
|
isLoading={loading}
|
|
121
115
|
onPress={loginUser}
|
|
122
116
|
label={localization.login.continue}
|
|
123
117
|
type={ButtonType.solid}
|
|
124
118
|
/>
|
|
125
|
-
<PrimaryButton
|
|
126
|
-
onPress={goToRegistration}
|
|
127
|
-
label={localization.login.notMember}
|
|
128
|
-
type={ButtonType.borderless}
|
|
129
|
-
/>
|
|
130
119
|
</KeyboardAwareScrollView>
|
|
131
120
|
);
|
|
132
121
|
}
|
|
@@ -138,7 +127,6 @@ const styles = StyleSheet.create({
|
|
|
138
127
|
},
|
|
139
128
|
container: {
|
|
140
129
|
flexGrow: 1,
|
|
141
|
-
backgroundColor: Colors.white,
|
|
142
130
|
borderTopRightRadius: CommonSizes.borderRadius.lg,
|
|
143
131
|
borderTopLeftRadius: CommonSizes.borderRadius.lg,
|
|
144
132
|
},
|
|
@@ -151,14 +139,12 @@ const styles = StyleSheet.create({
|
|
|
151
139
|
},
|
|
152
140
|
forgotPassword: {
|
|
153
141
|
...CommonStyles.normalText,
|
|
154
|
-
color: Colors.blueNormalActive,
|
|
155
142
|
textAlign: 'right',
|
|
156
143
|
marginTop: 8,
|
|
157
144
|
marginBottom: 24,
|
|
158
145
|
},
|
|
159
146
|
registerLink: {
|
|
160
147
|
...CommonStyles.normalText,
|
|
161
|
-
color: Colors.blueNormalActive,
|
|
162
148
|
textAlign: 'center',
|
|
163
149
|
marginTop: 16,
|
|
164
150
|
},
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import {
|
|
3
|
-
View,
|
|
4
|
-
StyleSheet,
|
|
5
|
-
ScrollView,
|
|
6
|
-
RefreshControl,
|
|
7
3
|
Dimensions,
|
|
4
|
+
RefreshControl,
|
|
5
|
+
ScrollView,
|
|
6
|
+
StyleSheet,
|
|
8
7
|
Text,
|
|
8
|
+
View,
|
|
9
9
|
} from 'react-native';
|
|
10
|
-
import {
|
|
10
|
+
import {NaturalColors} from '../../core/theme/colors';
|
|
11
11
|
import {CommonSizes} from '../../core/theme/commonSizes';
|
|
12
12
|
import {CommonStyles} from '../../core/theme/commonStyles';
|
|
13
13
|
import {CarouselSection} from './components/CarouselSection';
|
|
@@ -73,35 +73,35 @@ export function HomeScreen(): JSX.Element {
|
|
|
73
73
|
const styles = StyleSheet.create({
|
|
74
74
|
container: {
|
|
75
75
|
flex: 1,
|
|
76
|
-
backgroundColor:
|
|
76
|
+
backgroundColor: NaturalColors.grayScale_0,
|
|
77
77
|
},
|
|
78
78
|
content: {
|
|
79
|
-
paddingVertical: CommonSizes.spacing.
|
|
79
|
+
paddingVertical: CommonSizes.spacing.medium,
|
|
80
80
|
},
|
|
81
81
|
featuredSection: {
|
|
82
|
-
marginBottom: CommonSizes.spacing.
|
|
82
|
+
marginBottom: CommonSizes.spacing.large,
|
|
83
83
|
},
|
|
84
84
|
carouselSection: {
|
|
85
|
-
marginBottom: CommonSizes.spacing.
|
|
85
|
+
marginBottom: CommonSizes.spacing.large,
|
|
86
86
|
},
|
|
87
87
|
sectionTitle: {
|
|
88
88
|
...CommonStyles.h2_semiBold,
|
|
89
|
-
marginHorizontal: CommonSizes.spacing.
|
|
90
|
-
marginBottom: CommonSizes.spacing.
|
|
89
|
+
marginHorizontal: CommonSizes.spacing.large,
|
|
90
|
+
marginBottom: CommonSizes.spacing.medium,
|
|
91
91
|
},
|
|
92
92
|
trendingImage: {
|
|
93
93
|
width: width * 0.7,
|
|
94
94
|
height: 200,
|
|
95
|
-
borderRadius: CommonSizes.borderRadius.
|
|
95
|
+
borderRadius: CommonSizes.borderRadius.medium,
|
|
96
96
|
},
|
|
97
97
|
newArrivalsImage: {
|
|
98
98
|
width: width * 0.5,
|
|
99
99
|
height: 180,
|
|
100
|
-
borderRadius: CommonSizes.borderRadius.
|
|
100
|
+
borderRadius: CommonSizes.borderRadius.medium,
|
|
101
101
|
},
|
|
102
102
|
recommendedImage: {
|
|
103
103
|
width: width * 0.6,
|
|
104
104
|
height: 160,
|
|
105
|
-
borderRadius: CommonSizes.borderRadius.
|
|
105
|
+
borderRadius: CommonSizes.borderRadius.medium,
|
|
106
106
|
},
|
|
107
107
|
});
|
|
@@ -8,9 +8,9 @@ import {
|
|
|
8
8
|
TouchableOpacity,
|
|
9
9
|
View,
|
|
10
10
|
} from 'react-native';
|
|
11
|
-
import {Colors} from '../../../core/theme/colors';
|
|
12
11
|
import {CommonSizes} from '../../../core/theme/commonSizes';
|
|
13
12
|
import {CarouselItem} from '../types';
|
|
13
|
+
import {PrimaryColors} from '../../../core/theme/colors';
|
|
14
14
|
|
|
15
15
|
interface CarouselSectionProps {
|
|
16
16
|
items: CarouselItem[];
|
|
@@ -53,27 +53,27 @@ export function CarouselSection({
|
|
|
53
53
|
|
|
54
54
|
const styles = StyleSheet.create({
|
|
55
55
|
container: {
|
|
56
|
-
paddingHorizontal: CommonSizes.spacing.
|
|
56
|
+
paddingHorizontal: CommonSizes.spacing.large,
|
|
57
57
|
},
|
|
58
58
|
itemContainer: {
|
|
59
|
-
marginRight: CommonSizes.spacing.
|
|
59
|
+
marginRight: CommonSizes.spacing.medium,
|
|
60
60
|
},
|
|
61
61
|
image: {
|
|
62
62
|
width: 200,
|
|
63
63
|
height: 150,
|
|
64
|
-
borderRadius: CommonSizes.borderRadius.
|
|
64
|
+
borderRadius: CommonSizes.borderRadius.medium,
|
|
65
65
|
},
|
|
66
66
|
textContainer: {
|
|
67
|
-
marginTop: CommonSizes.spacing.
|
|
67
|
+
marginTop: CommonSizes.spacing.small,
|
|
68
68
|
},
|
|
69
69
|
title: {
|
|
70
|
-
fontSize:
|
|
70
|
+
fontSize: 16,
|
|
71
71
|
fontWeight: '600',
|
|
72
|
-
color:
|
|
72
|
+
color: PrimaryColors.PlatinateBlue_700,
|
|
73
73
|
},
|
|
74
74
|
subtitle: {
|
|
75
|
-
fontSize:
|
|
76
|
-
color:
|
|
75
|
+
fontSize: 14,
|
|
76
|
+
color: PrimaryColors.PlatinateBlue_700,
|
|
77
77
|
marginTop: 2,
|
|
78
78
|
},
|
|
79
79
|
});
|
|
@@ -8,9 +8,9 @@ import {
|
|
|
8
8
|
TouchableOpacity,
|
|
9
9
|
View,
|
|
10
10
|
} from 'react-native';
|
|
11
|
-
import {Colors} from '../../../core/theme/colors';
|
|
12
11
|
import {CommonSizes} from '../../../core/theme/commonSizes';
|
|
13
12
|
import {CarouselItem} from '../types';
|
|
13
|
+
import {NaturalColors, PrimaryColors} from '../../../core/theme/colors';
|
|
14
14
|
|
|
15
15
|
const {width} = Dimensions.get('window');
|
|
16
16
|
const ITEM_WIDTH = width * 0.85;
|
|
@@ -87,40 +87,40 @@ const styles = StyleSheet.create({
|
|
|
87
87
|
image: {
|
|
88
88
|
width: '100%',
|
|
89
89
|
height: '100%',
|
|
90
|
-
borderRadius: CommonSizes.borderRadius.
|
|
90
|
+
borderRadius: CommonSizes.borderRadius.large,
|
|
91
91
|
},
|
|
92
92
|
overlay: {
|
|
93
93
|
...StyleSheet.absoluteFillObject,
|
|
94
94
|
backgroundColor: 'rgba(0, 0, 0, 0.3)',
|
|
95
|
-
borderRadius: CommonSizes.borderRadius.
|
|
96
|
-
padding: CommonSizes.spacing.
|
|
95
|
+
borderRadius: CommonSizes.borderRadius.large,
|
|
96
|
+
padding: CommonSizes.spacing.large,
|
|
97
97
|
justifyContent: 'flex-end',
|
|
98
98
|
},
|
|
99
99
|
title: {
|
|
100
100
|
fontSize: 20,
|
|
101
101
|
fontWeight: '600',
|
|
102
|
-
color:
|
|
102
|
+
color: NaturalColors.grayScale_0,
|
|
103
103
|
},
|
|
104
104
|
subtitle: {
|
|
105
105
|
fontSize: 16,
|
|
106
|
-
color:
|
|
107
|
-
marginTop: CommonSizes.spacing.
|
|
106
|
+
color: NaturalColors.grayScale_0,
|
|
107
|
+
marginTop: CommonSizes.spacing.small,
|
|
108
108
|
},
|
|
109
109
|
pagination: {
|
|
110
110
|
flexDirection: 'row',
|
|
111
111
|
justifyContent: 'center',
|
|
112
112
|
alignItems: 'center',
|
|
113
|
-
marginTop: CommonSizes.spacing.
|
|
113
|
+
marginTop: CommonSizes.spacing.medium,
|
|
114
114
|
},
|
|
115
115
|
dot: {
|
|
116
116
|
width: 8,
|
|
117
117
|
height: 8,
|
|
118
118
|
borderRadius: 4,
|
|
119
|
-
backgroundColor:
|
|
119
|
+
backgroundColor: NaturalColors.grayScale_50,
|
|
120
120
|
marginHorizontal: 4,
|
|
121
121
|
},
|
|
122
122
|
activeDot: {
|
|
123
|
-
backgroundColor:
|
|
123
|
+
backgroundColor: PrimaryColors.PlatinateBlue_700,
|
|
124
124
|
width: 12,
|
|
125
125
|
height: 12,
|
|
126
126
|
borderRadius: 6,
|
|
@@ -21,10 +21,10 @@ import {
|
|
|
21
21
|
} from '../../common/validations/profileValidations';
|
|
22
22
|
import {useAppDispatch} from '../../core/store/reduxHelpers';
|
|
23
23
|
import {userRegister} from '../../core/store/user/userActions';
|
|
24
|
-
import {Colors} from '../../core/theme/colors';
|
|
25
24
|
import {CommonSizes} from '../../core/theme/commonSizes';
|
|
26
25
|
import {CommonStyles} from '../../core/theme/commonStyles';
|
|
27
26
|
import type {RootStackParamList} from '../../navigation/types';
|
|
27
|
+
import {NaturalColors, PrimaryColors} from '../../core/theme/colors';
|
|
28
28
|
|
|
29
29
|
export default function RegistrationScreen(): JSX.Element {
|
|
30
30
|
const dispatch = useAppDispatch();
|
|
@@ -178,20 +178,20 @@ export default function RegistrationScreen(): JSX.Element {
|
|
|
178
178
|
const styles = StyleSheet.create({
|
|
179
179
|
container: {
|
|
180
180
|
flexGrow: 1,
|
|
181
|
-
backgroundColor:
|
|
182
|
-
borderTopRightRadius: CommonSizes.
|
|
183
|
-
borderTopLeftRadius: CommonSizes.
|
|
181
|
+
backgroundColor: NaturalColors.grayScale_0,
|
|
182
|
+
borderTopRightRadius: CommonSizes.spacing.large,
|
|
183
|
+
borderTopLeftRadius: CommonSizes.spacing.large,
|
|
184
184
|
},
|
|
185
185
|
contentContainer: {
|
|
186
186
|
justifyContent: 'center',
|
|
187
187
|
alignItems: 'center',
|
|
188
|
-
paddingHorizontal: CommonSizes.spacing.
|
|
188
|
+
paddingHorizontal: CommonSizes.spacing.large,
|
|
189
189
|
paddingVertical: 26,
|
|
190
190
|
gap: 16,
|
|
191
191
|
},
|
|
192
192
|
loginLink: {
|
|
193
193
|
...CommonStyles.normalText,
|
|
194
|
-
color:
|
|
194
|
+
color: PrimaryColors.PlatinateBlue_700,
|
|
195
195
|
textAlign: 'center',
|
|
196
196
|
marginTop: 16,
|
|
197
197
|
},
|
|
@@ -17,10 +17,10 @@ import {useInputError} from '../../common/validations/hooks/useInputError';
|
|
|
17
17
|
import {emailValidations} from '../../common/validations/profileValidations';
|
|
18
18
|
import {useAppDispatch} from '../../core/store/reduxHelpers';
|
|
19
19
|
import {resetPassword} from '../../core/store/user/userActions';
|
|
20
|
-
import {Colors} from '../../core/theme/colors';
|
|
21
20
|
import {CommonSizes} from '../../core/theme/commonSizes';
|
|
22
21
|
import {CommonStyles} from '../../core/theme/commonStyles';
|
|
23
22
|
import type {RootStackParamList} from '../../navigation/types';
|
|
23
|
+
import {NaturalColors, PrimaryColors} from '../../core/theme/colors';
|
|
24
24
|
|
|
25
25
|
export default function ForgotPasswordScreen(): JSX.Element {
|
|
26
26
|
const dispatch = useAppDispatch();
|
|
@@ -104,14 +104,14 @@ export default function ForgotPasswordScreen(): JSX.Element {
|
|
|
104
104
|
const styles = StyleSheet.create({
|
|
105
105
|
container: {
|
|
106
106
|
flexGrow: 1,
|
|
107
|
-
backgroundColor:
|
|
108
|
-
borderTopRightRadius: CommonSizes.
|
|
109
|
-
borderTopLeftRadius: CommonSizes.
|
|
107
|
+
backgroundColor: NaturalColors.grayScale_0,
|
|
108
|
+
borderTopRightRadius: CommonSizes.spacing.large,
|
|
109
|
+
borderTopLeftRadius: CommonSizes.spacing.large,
|
|
110
110
|
},
|
|
111
111
|
contentContainer: {
|
|
112
112
|
justifyContent: 'center',
|
|
113
113
|
alignItems: 'center',
|
|
114
|
-
paddingHorizontal: CommonSizes.spacing.
|
|
114
|
+
paddingHorizontal: CommonSizes.spacing.large,
|
|
115
115
|
paddingVertical: 26,
|
|
116
116
|
gap: 16,
|
|
117
117
|
},
|
|
@@ -122,7 +122,7 @@ const styles = StyleSheet.create({
|
|
|
122
122
|
},
|
|
123
123
|
loginLink: {
|
|
124
124
|
...CommonStyles.normalText,
|
|
125
|
-
color:
|
|
125
|
+
color: PrimaryColors.PlatinateBlue_700,
|
|
126
126
|
textAlign: 'center',
|
|
127
127
|
marginTop: 16,
|
|
128
128
|
},
|