@fadyshawky/react-native-magic 2.0.4 → 2.0.5
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/ImageResources.g.ts +33 -1
- package/template/src/common/components/Background.tsx +3 -1
- package/template/src/common/components/Container.tsx +1 -1
- package/template/src/common/components/OTPInput.tsx +3 -2
- package/template/src/common/components/PrimaryButton.tsx +23 -23
- package/template/src/common/components/PrimaryTextInput.tsx +189 -199
- package/template/src/common/components/RadioIcon.tsx +4 -4
- package/template/src/common/components/SafeText.tsx +41 -0
- package/template/src/common/components/SearchBar.tsx +19 -17
- package/template/src/common/components/TryAgain.tsx +3 -3
- package/template/src/common/localization/localization.ts +10 -0
- package/template/src/common/localization/translations/commonLocalization.ts +97 -0
- package/template/src/common/localization/translations/homeLocalization.ts +24 -0
- package/template/src/common/localization/translations/loginLocalization.ts +28 -2
- package/template/src/common/localization/translations/mainNavigationLocalization.ts +30 -0
- package/template/src/common/localization/translations/navigationLocalization.ts +48 -0
- package/template/src/common/localization/translations/otpLocalization.ts +28 -0
- package/template/src/common/localization/translations/passwordLocalization.ts +54 -0
- package/template/src/common/localization/translations/posLocalization.ts +196 -0
- package/template/src/common/utils/FeesCaalculation.tsx +37 -0
- package/template/src/common/utils/index.tsx +11 -0
- package/template/src/common/utils/printData.tsx +161 -0
- package/template/src/common/validations/errorValidations.ts +3 -2
- package/template/src/components/PrinterExample.js +226 -0
- package/template/src/core/api/serverHeaders.ts +62 -1
- package/template/src/core/store/Categories/categoryActions.ts +33 -0
- package/template/src/core/store/Categories/categorySlice.ts +75 -0
- package/template/src/core/store/Categories/categoryState.ts +41 -0
- package/template/src/core/store/Providers/providersActions.ts +102 -0
- package/template/src/core/store/Providers/providersSlice.ts +136 -0
- package/template/src/core/store/Providers/providersState.ts +37 -0
- package/template/src/core/store/Services/servicesActions.ts +191 -0
- package/template/src/core/store/Services/servicesSlice.ts +205 -0
- package/template/src/core/store/Services/servicesState.ts +466 -0
- package/template/src/core/store/app/appSlice.ts +13 -5
- package/template/src/core/store/app/appState.ts +10 -2
- package/template/src/core/store/rootReducer.ts +6 -1
- package/template/src/core/store/store.tsx +55 -2
- package/template/src/core/store/user/userActions.ts +164 -26
- package/template/src/core/store/user/userSlice.ts +193 -21
- package/template/src/core/store/user/userState.ts +148 -25
- package/template/src/core/theme/colors.ts +70 -94
- package/template/src/core/theme/commonConsts.ts +1 -1
- package/template/src/core/theme/commonSizes.ts +94 -119
- package/template/src/core/theme/commonStyles.ts +22 -22
- package/template/src/core/theme/fonts.ts +14 -13
- package/template/src/core/theme/themes.ts +75 -386
- package/template/src/core/theme/types.ts +15 -201
- package/template/src/core/utils/stringUtils.ts +114 -0
- package/template/src/modules/SunmiCard.js +212 -0
- package/template/src/modules/SunmiPrepaid.ts +122 -0
- package/template/src/navigation/AuthStack.tsx +8 -0
- package/template/src/navigation/HeaderComponents.tsx +76 -1
- package/template/src/navigation/MainNavigation.tsx +3 -1
- package/template/src/navigation/MainStack.tsx +130 -56
- package/template/src/navigation/TabBar.tsx +111 -59
- package/template/src/navigation/types.ts +24 -0
- package/template/src/screens/Categories/Categories.tsx +141 -0
- package/template/src/screens/Categories/hooks/useCategoriesData.ts +33 -0
- package/template/src/screens/Categories/types.ts +7 -0
- package/template/src/screens/Favorites/Favorites.tsx +130 -0
- package/template/src/screens/ForceChangePassword/ForceChangePasswordScreen.tsx +155 -0
- package/template/src/screens/History/History.tsx +430 -0
- package/template/src/screens/History/hooks/useHistoryData.ts +49 -0
- package/template/src/screens/History/types.ts +7 -0
- package/template/src/screens/InquiredBill/InquiredBill.tsx +443 -0
- package/template/src/screens/InquiredBill/hooks/useInquiredData.ts +91 -0
- package/template/src/screens/Login/Login.tsx +85 -85
- package/template/src/screens/OTP/OTPScreen.tsx +170 -0
- package/template/src/screens/PaymentConfirmation/PaymentConfirmation.tsx +326 -0
- package/template/src/screens/Providers/Providers.tsx +166 -0
- package/template/src/screens/Providers/hooks/useProvidersData.ts +33 -0
- package/template/src/screens/Providers/types.ts +7 -0
- package/template/src/screens/ReceiptScreen/ReceiptScreen.tsx +181 -0
- package/template/src/screens/ReceiptScreen/hooks/useReceiptData.ts +46 -0
- package/template/src/screens/ReceiptScreen/utils/utils.tsx +156 -0
- package/template/src/screens/Services/Services.tsx +144 -0
- package/template/src/screens/Services/hooks/useServicesData.ts +41 -0
- package/template/src/screens/SingleService/Components/FawryInputs.tsx +446 -0
- package/template/src/screens/SingleService/SingleService.tsx +229 -0
- package/template/src/screens/SingleService/hooks/useServiceData.ts +164 -0
- package/template/src/screens/home/Components/PayByCode.tsx +129 -0
- package/template/src/screens/home/HomeScreen.tsx +268 -77
- package/template/src/screens/home/hooks/useHomeData.ts +32 -38
- package/template/src/screens/index.tsx +24 -0
- package/template/src/screens/profile/Profile.tsx +290 -2
- package/template/src/services/SunmiPrinterInternal.js +268 -0
- package/template/src/types/sunmiPrepaid.d.ts +20 -0
- package/template/src/utils/SunmiPrinter.ts +442 -0
- package/template/src/utils/feesCalculator.ts +92 -0
- package/template/src/common/components/Stepper.tsx +0 -153
- package/template/src/common/components/Svg.tsx +0 -25
- package/template/src/common/hooks/useDebounce.ts +0 -17
- package/template/src/common/hooks/usePrevious.ts +0 -11
- package/template/src/common/localization/intlFormatter.ts +0 -37
- package/template/src/common/urls/emailUrl.ts +0 -20
- package/template/src/common/urls/mapUrl.ts +0 -22
- package/template/src/common/utils/listHandlers.ts +0 -30
- package/template/src/common/utils/serializeQueryParams.ts +0 -10
- package/template/src/common/validations/hooks/useDatesError.ts +0 -40
- package/template/src/common/validations/profileValidations.ts +0 -30
- package/template/src/core/theme/shadows.ts +0 -135
- package/template/src/navigation/TopTabBar.tsx +0 -77
- package/template/src/screens/Settings/Settings.tsx +0 -5
- package/template/src/screens/home/components/CarouselSection.tsx +0 -79
- package/template/src/screens/home/components/FeaturedCarousel.tsx +0 -128
- package/template/src/screens/main/Main.tsx +0 -5
- package/template/src/screens/registration/RegistrationScreen.tsx +0 -198
- package/template/src/screens/resetPassword/ForgotPasswordScreen.tsx +0 -129
|
@@ -6,8 +6,8 @@ import {
|
|
|
6
6
|
ViewStyle,
|
|
7
7
|
} from 'react-native';
|
|
8
8
|
import {Theme} from './types';
|
|
9
|
+
import {FontSizes, LineHeight, Spacing} from './commonSizes';
|
|
9
10
|
import {Fonts} from './fonts';
|
|
10
|
-
import {CommonSizes} from './commonSizes';
|
|
11
11
|
|
|
12
12
|
export const screenComponentWidth = Dimensions.get('screen').width - 60;
|
|
13
13
|
export const screenWidth = Dimensions.get('screen').width;
|
|
@@ -131,34 +131,34 @@ export const createThemedStyles = (theme: Theme) =>
|
|
|
131
131
|
} as TextStyle,
|
|
132
132
|
h4_semiBold: {
|
|
133
133
|
fontFamily: Fonts.semiBold,
|
|
134
|
-
fontSize:
|
|
135
|
-
lineHeight:
|
|
134
|
+
fontSize: FontSizes.medium,
|
|
135
|
+
lineHeight: LineHeight.medium,
|
|
136
136
|
} as TextStyle,
|
|
137
137
|
h4_regular: {
|
|
138
138
|
fontFamily: Fonts.regular,
|
|
139
|
-
fontSize:
|
|
140
|
-
lineHeight:
|
|
139
|
+
fontSize: FontSizes.medium,
|
|
140
|
+
lineHeight: LineHeight.medium,
|
|
141
141
|
} as TextStyle,
|
|
142
142
|
body_bold: {
|
|
143
143
|
fontFamily: Fonts.bold,
|
|
144
|
-
fontSize:
|
|
145
|
-
lineHeight:
|
|
144
|
+
fontSize: FontSizes.small,
|
|
145
|
+
lineHeight: LineHeight.small,
|
|
146
146
|
} as TextStyle,
|
|
147
147
|
body_bold_underlined: {
|
|
148
148
|
fontFamily: Fonts.bold,
|
|
149
|
-
fontSize:
|
|
150
|
-
lineHeight:
|
|
149
|
+
fontSize: FontSizes.small,
|
|
150
|
+
lineHeight: LineHeight.small,
|
|
151
151
|
textDecorationLine: 'underline',
|
|
152
152
|
} as TextStyle,
|
|
153
153
|
body_semiBold: {
|
|
154
154
|
fontFamily: Fonts.semiBold,
|
|
155
|
-
fontSize:
|
|
156
|
-
lineHeight:
|
|
155
|
+
fontSize: FontSizes.small,
|
|
156
|
+
lineHeight: LineHeight.small,
|
|
157
157
|
} as TextStyle,
|
|
158
158
|
body_regular: {
|
|
159
159
|
fontFamily: Fonts.regular,
|
|
160
|
-
fontSize:
|
|
161
|
-
lineHeight:
|
|
160
|
+
fontSize: FontSizes.small,
|
|
161
|
+
lineHeight: LineHeight.small,
|
|
162
162
|
} as TextStyle,
|
|
163
163
|
tabBar_bold: {
|
|
164
164
|
fontFamily: Fonts.bold,
|
|
@@ -204,47 +204,47 @@ export const CommonStyles = createThemedStyles({
|
|
|
204
204
|
text: {
|
|
205
205
|
header1: {
|
|
206
206
|
fontFamily: Fonts.medium,
|
|
207
|
-
fontSize:
|
|
207
|
+
fontSize: FontSizes.header1,
|
|
208
208
|
color: '#000000',
|
|
209
209
|
},
|
|
210
210
|
header2: {
|
|
211
211
|
fontFamily: Fonts.normal,
|
|
212
|
-
fontSize:
|
|
212
|
+
fontSize: FontSizes.header2,
|
|
213
213
|
color: '#000000',
|
|
214
214
|
},
|
|
215
215
|
body1: {
|
|
216
216
|
fontFamily: Fonts.light,
|
|
217
|
-
fontSize:
|
|
217
|
+
fontSize: FontSizes.body1,
|
|
218
218
|
color: '#000000',
|
|
219
219
|
},
|
|
220
220
|
body2: {
|
|
221
221
|
fontFamily: Fonts.regular,
|
|
222
|
-
fontSize:
|
|
222
|
+
fontSize: FontSizes.body2,
|
|
223
223
|
color: '#000000',
|
|
224
224
|
},
|
|
225
225
|
button: {
|
|
226
226
|
fontFamily: Fonts.regular,
|
|
227
|
-
fontSize:
|
|
227
|
+
fontSize: FontSizes.button,
|
|
228
228
|
color: '#FFFFFF',
|
|
229
229
|
},
|
|
230
230
|
cards: {
|
|
231
231
|
fontFamily: Fonts.semiBold,
|
|
232
|
-
fontSize:
|
|
232
|
+
fontSize: FontSizes.card,
|
|
233
233
|
color: '#000000',
|
|
234
234
|
},
|
|
235
235
|
SearchBar: {
|
|
236
236
|
fontFamily: Fonts.light,
|
|
237
|
-
fontSize:
|
|
237
|
+
fontSize: FontSizes.searchBar,
|
|
238
238
|
color: '#000000',
|
|
239
239
|
},
|
|
240
240
|
label: {
|
|
241
241
|
fontFamily: Fonts.light,
|
|
242
|
-
fontSize:
|
|
242
|
+
fontSize: FontSizes.label,
|
|
243
243
|
color: '#000000',
|
|
244
244
|
},
|
|
245
245
|
hyperlink: {
|
|
246
246
|
fontFamily: Fonts.light,
|
|
247
|
-
fontSize:
|
|
247
|
+
fontSize: FontSizes.hyperlink,
|
|
248
248
|
color: '#000000',
|
|
249
249
|
textDecorationLine: 'underline',
|
|
250
250
|
},
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
export const Fonts = {
|
|
2
|
-
//
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
bold: 'Almarai-Bold',
|
|
6
|
-
extraBold: 'Almarai-ExtraBold',
|
|
2
|
+
// Inter Variable Font
|
|
3
|
+
regular: 'Inter-VariableFont_opsz,wght',
|
|
4
|
+
italic: 'Inter-Italic-VariableFont_opsz,wght',
|
|
7
5
|
|
|
8
|
-
//
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
6
|
+
// Kanit Font
|
|
7
|
+
medium: 'Kanit-Medium',
|
|
8
|
+
|
|
9
|
+
// Font weights for Inter Variable Font
|
|
10
|
+
thin: 'Inter-Thin',
|
|
11
|
+
light: 'Inter-Light',
|
|
12
|
+
normal: 'Inter-Regular',
|
|
13
|
+
semiBold: 'Inter-SemiBold',
|
|
14
|
+
bold: 'Inter-Bold',
|
|
15
|
+
extraBold: 'Inter-ExtraBold',
|
|
16
|
+
black: 'Inter-Black',
|
|
16
17
|
};
|