Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 

265 rindas
9.8 KiB

  1. import React, { Fragment } from "react";
  2. import { createStackNavigator } from "@react-navigation/stack";
  3. import { NavigationContainer } from "@react-navigation/native";
  4. import { fromRight } from "react-navigation-transitions";
  5. import Icon from "react-native-vector-icons/Ionicons";
  6. import * as colors from "./src/assets/css/Colors";
  7. import { createBottomTabNavigator } from "@react-navigation/bottom-tabs";
  8. import {
  9. View,
  10. StyleSheet,
  11. Text,
  12. TextInput,
  13. ScrollView,
  14. Image,
  15. BackHandler,
  16. Keyboard,
  17. TouchableOpacity,
  18. Picker,
  19. } from "react-native";
  20. /* Screens */
  21. import Splash from "./src/views/Splash";
  22. import Home from "./src/views/Home";
  23. import Pharmacy from "./src/views/Pharmacy";
  24. import EditProduct from "./src/views/EditProduct";
  25. import Call from "./src/views/Call";
  26. import VideoCall from "./src/views/VideoCall";
  27. import VendorDetails from "./src/views/VendorDetails";
  28. import LocationSearch from "./src/views/LocationSearch";
  29. import SubCategory from "./src/views/SubCategory";
  30. import Product from "./src/views/Product";
  31. import Category from "./src/views/Category";
  32. import DoctorSubCategories from "./src/views/DoctorSubCategories";
  33. import ProductDetails from "./src/views/ProductDetails";
  34. import Promo from "./src/views/Promo";
  35. import MyOrders from "./src/views/MyOrders";
  36. import OrderDetails from "./src/views/OrderDetails";
  37. import Cart from "./src/views/Cart";
  38. import Profile from "./src/views/Profile";
  39. import More from "./src/views/More";
  40. import Prescription from "./src/views/Prescription";
  41. import AddPrescription from "./src/views/AddPrescription";
  42. import ViewPrescription from "./src/views/ViewPrescription";
  43. import Address from "./src/views/Address";
  44. import AddressList from "./src/views/AddressList";
  45. import Payment from "./src/views/Payment";
  46. import Login from "./src/views/Login";
  47. import Register from "./src/views/Register";
  48. import Faq from "./src/views/Faq";
  49. import FaqDetails from "./src/views/FaqDetails";
  50. import PrivacyPolicy from "./src/views/PrivacyPolicy";
  51. import Forgot from "./src/views/Forgot";
  52. import Otp from "./src/views/Otp";
  53. import Rating from "./src/views/Rating";
  54. import Reset from "./src/views/Reset";
  55. import ContactUs from "./src/views/ContactUs";
  56. import Logout from "./src/views/Logout";
  57. import Search from "./src/views/Search";
  58. import Wallet from "./src/views/Wallet";
  59. import DoctorList from "./src/views/DoctorList";
  60. import DoctorDetail from "./src/views/DoctorDetail";
  61. import AppointmentDetail from "./src/views/AppointmentDetail";
  62. import CreateAppointment from "./src/views/CreateAppointment";
  63. import MyBookingDetails from "./src/views/MyBookingDetails";
  64. import Chat from "./src/views/Chat";
  65. import DoctorMap from "./src/views/DoctorMap";
  66. import home from "./src/assets/icons/home.png";
  67. import more from "./src/assets/icons/more.png";
  68. import file from "./src/assets/icons/file.png";
  69. import list from "./src/assets/icons/list.png";
  70. import bag from "./src/assets/icons/bag.png";
  71. import DoctorSymptoms from "./src/views/DoctorSymptoms";
  72. import PharmacyDetail from "./src/views/PharmacyDetail";
  73. import PrescriptionUpload from "./src/views/PrescriptionUpload";
  74. import Success from './src/views/Success'
  75. // import WallletAdd from './src/views/WalletAdd'
  76. import WalletAdd from "./src/views/WalletAdd";
  77. import AddressEnter from "./src/views/AddressEnter";
  78. import AddressMap from "./src/views/AddressMap";
  79. const Stack = createStackNavigator();
  80. const Tab = createBottomTabNavigator();
  81. function MyTabs() {
  82. return (
  83. <Tab.Navigator
  84. initialRouteName="Home"
  85. tabBarOptions={{
  86. activeTintColor: "#FFFFFF",
  87. inactiveTintColor: "#bfbfbf",
  88. labelStyle: { fontFamily: "GoogleSans-Medium" },
  89. style: {
  90. backgroundColor: colors.theme_bg_dark,
  91. fontFamily: "GoogleSans-Medium",
  92. },
  93. }}
  94. >
  95. <Tab.Screen
  96. name="Home"
  97. component={Home}
  98. options={{
  99. tabBarLabel: "Home",
  100. tabBarIcon: ({ color, size }) => (
  101. // <Icon name="ios-home"
  102. // color={color} size={size} />
  103. <View
  104. style={{borderRadius:1,backgroundColor:'white',width:20,justifyContent:'center',alignContent:'center',alignItems:'center'}}
  105. >
  106. <Image
  107. style={{ width: 20
  108. ,
  109. height: 20,}}
  110. source={home}
  111. /></View>
  112. ),
  113. }}
  114. />
  115. <Tab.Screen
  116. name="Pharmacy"
  117. component={Pharmacy}
  118. options={{
  119. tabBarLabel: "Pharmacy",
  120. tabBarIcon: ({ color, size }) => (
  121. // <Icon name="ios-medkit" color={color} size={size} />
  122. <Image
  123. style={{ width: 20
  124. ,
  125. height: 20,backgroundColor:'white'}}
  126. source={bag}
  127. />
  128. ),
  129. }}
  130. />
  131. <Tab.Screen
  132. name="MyOrders"
  133. component={MyOrders}
  134. options={{
  135. tabBarLabel: "MyOrders",
  136. tabBarIcon: ({ color, size }) => (
  137. // <Icon name="ios-list" color={color} size={size} />
  138. <View
  139. style={{borderRadius:2,backgroundColor:'white',width:20,justifyContent:'center',alignContent:'center',alignItems:'center'}}
  140. >
  141. <Image
  142. style={{ width: 20
  143. ,
  144. height: 20,}}
  145. source={list}
  146. />
  147. </View>
  148. ),
  149. }}
  150. />
  151. <Tab.Screen
  152. name="Prescription"
  153. component={Prescription}
  154. options={{
  155. tabBarLabel: "Prescription",
  156. tabBarIcon: ({ color, size }) => (
  157. // <Icon name="ios-document" color={color} size={size} />
  158. <View
  159. style={{borderRadius:3,backgroundColor:'white',width:12,justifyContent:'center',alignContent:'center',alignItems:'center'}}
  160. >
  161. <Image
  162. style={{ width: 20
  163. ,
  164. height: 20,}}
  165. source={file}
  166. />
  167. </View>
  168. ),
  169. }}
  170. />
  171. <Tab.Screen
  172. name="More"
  173. component={More}
  174. options={{
  175. tabBarLabel: "More",
  176. tabBarIcon: ({ color, size }) => (
  177. // <Icon name="ios-more" color={color} size={size} />
  178. <View
  179. style={{borderRadius:3,backgroundColor:'white',width:20,justifyContent:'center',alignContent:'center',alignItems:'center'}}
  180. >
  181. <Image
  182. style={{ width: 20
  183. ,
  184. height: 20,}}
  185. source={more}
  186. />
  187. </View>
  188. ),
  189. }}
  190. />
  191. </Tab.Navigator>
  192. );
  193. }
  194. function App() {
  195. return (
  196. <NavigationContainer>
  197. <Stack.Navigator headerMode="none" initialRouteName="Splash">
  198. <Stack.Screen name="DoctorMap" component={DoctorMap} />
  199. <Stack.Screen name="AddPrescription" component={AddPrescription} />
  200. <Stack.Screen name="Address" component={Address} />
  201. <Stack.Screen name="AddressList" component={AddressList} />
  202. <Stack.Screen name="LocationSearch" component={LocationSearch} />
  203. <Stack.Screen name="MyBookingDetails" component={MyBookingDetails} />
  204. <Stack.Screen name="ContactUs" component={ContactUs} />
  205. <Stack.Screen name="Faq" component={Faq} />
  206. <Stack.Screen name="EditProduct" component={EditProduct} />
  207. <Stack.Screen name="Cart" component={Cart} />
  208. <Stack.Screen name="Chat" component={Chat} />
  209. <Stack.Screen name="Call" component={Call} />
  210. <Stack.Screen name="VideoCall" component={VideoCall} />
  211. <Stack.Screen name="FaqDetails" component={FaqDetails} />
  212. <Stack.Screen name="Forgot" component={Forgot} />
  213. <Stack.Screen name="Rating" component={Rating} />
  214. <Stack.Screen name="Home" component={MyTabs} />
  215. <Stack.Screen name="Login" component={Login} />
  216. <Stack.Screen name="Logout" component={Logout} />
  217. <Stack.Screen name="OrderDetails" component={OrderDetails} />
  218. <Stack.Screen name="Otp" component={Otp} />
  219. <Stack.Screen name="Payment" component={Payment} />
  220. <Stack.Screen name="PrivacyPolicy" component={PrivacyPolicy} />
  221. <Stack.Screen name="Product" component={Product} />
  222. <Stack.Screen name="ProductDetails" component={ProductDetails} />
  223. <Stack.Screen name="Promo" component={Promo} />
  224. <Stack.Screen name="Register" component={Register} />
  225. <Stack.Screen name="Reset" component={Reset} />
  226. <Stack.Screen name="Splash" component={Splash} />
  227. <Stack.Screen name="Wallet" component={Wallet} />
  228. <Stack.Screen name="SubCategory" component={SubCategory} />
  229. <Stack.Screen name="ViewPrescription" component={ViewPrescription} />
  230. <Stack.Screen name="Profile" component={Profile} />
  231. <Stack.Screen name="Category" component={Category} />
  232. <Stack.Screen name="VendorDetails" component={VendorDetails} />
  233. <Stack.Screen name="Search" component={Search} />
  234. <Stack.Screen name="DoctorList" component={DoctorList} />
  235. <Stack.Screen name="DoctorSymptoms" component={DoctorSymptoms} />
  236. <Stack.Screen name="PharmacyDetail" component={PharmacyDetail} />
  237. <Stack.Screen name="DoctorDetail" component={DoctorDetail} />
  238. <Stack.Screen name="AppointmentDetail" component={AppointmentDetail} />
  239. <Stack.Screen name="CreateAppointment" component={CreateAppointment} />
  240. <Stack.Screen name="PrescriptionUpload" component={PrescriptionUpload} />
  241. <Stack.Screen name="Success" component={Success} />
  242. <Stack.Screen name="WalletAdd" component={WalletAdd} />
  243. <Stack.Screen name="AddressEnter"
  244. component={AddressEnter}
  245. />
  246. <Stack.Screen name="AddressMap"
  247. component={AddressMap}
  248. />
  249. <Stack.Screen
  250. name="DoctorSubCategories"
  251. component={DoctorSubCategories}
  252. />
  253. </Stack.Navigator>
  254. </NavigationContainer>
  255. );
  256. }
  257. export default App;