react-native-salespanda 0.4.2 → 0.4.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.
Files changed (171) hide show
  1. package/lib/module/SalespandaApp.js +11 -37
  2. package/lib/module/SalespandaApp.js.map +1 -1
  3. package/lib/module/components/BottomSheet.js +141 -0
  4. package/lib/module/components/BottomSheet.js.map +1 -0
  5. package/lib/module/components/ContactViaModal.js +68 -0
  6. package/lib/module/components/ContactViaModal.js.map +1 -0
  7. package/lib/module/components/ScreenHeader.js +63 -0
  8. package/lib/module/components/ScreenHeader.js.map +1 -0
  9. package/lib/module/components/SearchBar.js +57 -0
  10. package/lib/module/components/SearchBar.js.map +1 -0
  11. package/lib/module/components/TabsHeader.js +80 -0
  12. package/lib/module/components/TabsHeader.js.map +1 -0
  13. package/lib/module/components/index.js +8 -0
  14. package/lib/module/components/index.js.map +1 -0
  15. package/lib/module/constants/Colors.js +3 -2
  16. package/lib/module/constants/Colors.js.map +1 -1
  17. package/lib/module/index.js +6 -4
  18. package/lib/module/index.js.map +1 -1
  19. package/lib/module/navigation/AppNavigator.js +5 -4
  20. package/lib/module/navigation/AppNavigator.js.map +1 -1
  21. package/lib/module/navigation/BottomTabNavigator.js +42 -23
  22. package/lib/module/navigation/BottomTabNavigator.js.map +1 -1
  23. package/lib/module/navigation/DrawerNavigator.js +36 -34
  24. package/lib/module/navigation/DrawerNavigator.js.map +1 -1
  25. package/lib/module/navigation/StackNavigator.js +23 -0
  26. package/lib/module/navigation/StackNavigator.js.map +1 -0
  27. package/lib/module/screens/CRM/AddContactModal.js +49 -0
  28. package/lib/module/screens/CRM/AddContactModal.js.map +1 -0
  29. package/lib/module/screens/CRM/CategoryTabs.js +70 -0
  30. package/lib/module/screens/CRM/CategoryTabs.js.map +1 -0
  31. package/lib/module/screens/CRM/ContactItem.js +168 -0
  32. package/lib/module/screens/CRM/ContactItem.js.map +1 -0
  33. package/lib/module/screens/CRM/FilterDropdown.js +39 -0
  34. package/lib/module/screens/CRM/FilterDropdown.js.map +1 -0
  35. package/lib/module/screens/CRM/FunnelChart.js +105 -0
  36. package/lib/module/screens/CRM/FunnelChart.js.map +1 -0
  37. package/lib/module/screens/CRM/InfoCard.js +56 -0
  38. package/lib/module/screens/CRM/InfoCard.js.map +1 -0
  39. package/lib/module/screens/CRM/LeadCard.js +76 -0
  40. package/lib/module/screens/CRM/LeadCard.js.map +1 -0
  41. package/lib/module/screens/CRM/LogCallScreen.js +271 -0
  42. package/lib/module/screens/CRM/LogCallScreen.js.map +1 -0
  43. package/lib/module/screens/CRM/TopTabs.js +63 -0
  44. package/lib/module/screens/CRM/TopTabs.js.map +1 -0
  45. package/lib/module/screens/CRM/index.js +13 -0
  46. package/lib/module/screens/CRM/index.js.map +1 -0
  47. package/lib/module/screens/ReportsScreen.js +6 -4
  48. package/lib/module/screens/ReportsScreen.js.map +1 -1
  49. package/lib/module/screens/Tabs/ActivityAnalytics.js +29 -0
  50. package/lib/module/screens/Tabs/ActivityAnalytics.js.map +1 -0
  51. package/lib/module/screens/Tabs/CRMScreen.js +316 -0
  52. package/lib/module/screens/Tabs/CRMScreen.js.map +1 -0
  53. package/lib/module/screens/Tabs/DigitalDiary.js +39 -0
  54. package/lib/module/screens/Tabs/DigitalDiary.js.map +1 -0
  55. package/lib/module/screens/Tabs/HomeScreen.js +240 -0
  56. package/lib/module/screens/Tabs/HomeScreen.js.map +1 -0
  57. package/lib/module/screens/Tabs/NotificationsScreen.js +29 -0
  58. package/lib/module/screens/Tabs/NotificationsScreen.js.map +1 -0
  59. package/lib/module/screens/contentliberary/contentliberary.js +283 -0
  60. package/lib/module/screens/contentliberary/contentliberary.js.map +1 -0
  61. package/lib/typescript/src/SalespandaApp.d.ts +2 -2
  62. package/lib/typescript/src/SalespandaApp.d.ts.map +1 -1
  63. package/lib/typescript/src/components/BottomSheet.d.ts +16 -0
  64. package/lib/typescript/src/components/BottomSheet.d.ts.map +1 -0
  65. package/lib/typescript/src/components/ContactViaModal.d.ts +13 -0
  66. package/lib/typescript/src/components/ContactViaModal.d.ts.map +1 -0
  67. package/lib/typescript/src/components/ScreenHeader.d.ts +8 -0
  68. package/lib/typescript/src/components/ScreenHeader.d.ts.map +1 -0
  69. package/lib/typescript/src/components/SearchBar.d.ts +8 -0
  70. package/lib/typescript/src/components/SearchBar.d.ts.map +1 -0
  71. package/lib/typescript/src/components/TabsHeader.d.ts +8 -0
  72. package/lib/typescript/src/components/TabsHeader.d.ts.map +1 -0
  73. package/lib/typescript/src/components/index.d.ts +5 -0
  74. package/lib/typescript/src/components/index.d.ts.map +1 -0
  75. package/lib/typescript/src/constants/Colors.d.ts +2 -1
  76. package/lib/typescript/src/constants/Colors.d.ts.map +1 -1
  77. package/lib/typescript/src/index.d.ts +4 -4
  78. package/lib/typescript/src/index.d.ts.map +1 -1
  79. package/lib/typescript/src/navigation/AppNavigator.d.ts +2 -1
  80. package/lib/typescript/src/navigation/AppNavigator.d.ts.map +1 -1
  81. package/lib/typescript/src/navigation/BottomTabNavigator.d.ts +9 -1
  82. package/lib/typescript/src/navigation/BottomTabNavigator.d.ts.map +1 -1
  83. package/lib/typescript/src/navigation/DrawerNavigator.d.ts +3 -1
  84. package/lib/typescript/src/navigation/DrawerNavigator.d.ts.map +1 -1
  85. package/lib/typescript/src/navigation/StackNavigator.d.ts +13 -0
  86. package/lib/typescript/src/navigation/StackNavigator.d.ts.map +1 -0
  87. package/lib/typescript/src/screens/CRM/AddContactModal.d.ts +11 -0
  88. package/lib/typescript/src/screens/CRM/AddContactModal.d.ts.map +1 -0
  89. package/lib/typescript/src/screens/CRM/CategoryTabs.d.ts +7 -0
  90. package/lib/typescript/src/screens/CRM/CategoryTabs.d.ts.map +1 -0
  91. package/lib/typescript/src/screens/CRM/ContactItem.d.ts +19 -0
  92. package/lib/typescript/src/screens/CRM/ContactItem.d.ts.map +1 -0
  93. package/lib/typescript/src/screens/CRM/FilterDropdown.d.ts +6 -0
  94. package/lib/typescript/src/screens/CRM/FilterDropdown.d.ts.map +1 -0
  95. package/lib/typescript/src/screens/CRM/FunnelChart.d.ts +17 -0
  96. package/lib/typescript/src/screens/CRM/FunnelChart.d.ts.map +1 -0
  97. package/lib/typescript/src/screens/CRM/InfoCard.d.ts +7 -0
  98. package/lib/typescript/src/screens/CRM/InfoCard.d.ts.map +1 -0
  99. package/lib/typescript/src/screens/CRM/LeadCard.d.ts +9 -0
  100. package/lib/typescript/src/screens/CRM/LeadCard.d.ts.map +1 -0
  101. package/lib/typescript/src/screens/CRM/LogCallScreen.d.ts +12 -0
  102. package/lib/typescript/src/screens/CRM/LogCallScreen.d.ts.map +1 -0
  103. package/lib/typescript/src/screens/CRM/TopTabs.d.ts +12 -0
  104. package/lib/typescript/src/screens/CRM/TopTabs.d.ts.map +1 -0
  105. package/lib/typescript/src/screens/CRM/index.d.ts +10 -0
  106. package/lib/typescript/src/screens/CRM/index.d.ts.map +1 -0
  107. package/lib/typescript/src/screens/ReportsScreen.d.ts +2 -1
  108. package/lib/typescript/src/screens/ReportsScreen.d.ts.map +1 -1
  109. package/lib/typescript/src/screens/Tabs/ActivityAnalytics.d.ts +3 -0
  110. package/lib/typescript/src/screens/Tabs/ActivityAnalytics.d.ts.map +1 -0
  111. package/lib/typescript/src/screens/Tabs/CRMScreen.d.ts +3 -0
  112. package/lib/typescript/src/screens/Tabs/CRMScreen.d.ts.map +1 -0
  113. package/lib/typescript/src/screens/Tabs/DigitalDiary.d.ts +3 -0
  114. package/lib/typescript/src/screens/Tabs/DigitalDiary.d.ts.map +1 -0
  115. package/lib/typescript/src/screens/Tabs/HomeScreen.d.ts +4 -0
  116. package/lib/typescript/src/screens/Tabs/HomeScreen.d.ts.map +1 -0
  117. package/lib/typescript/src/screens/Tabs/NotificationsScreen.d.ts +3 -0
  118. package/lib/typescript/src/screens/Tabs/NotificationsScreen.d.ts.map +1 -0
  119. package/lib/typescript/src/screens/contentliberary/contentliberary.d.ts +2 -0
  120. package/lib/typescript/src/screens/contentliberary/contentliberary.d.ts.map +1 -0
  121. package/package.json +5 -1
  122. package/src/SalespandaApp.tsx +12 -36
  123. package/src/components/BottomSheet.tsx +146 -0
  124. package/src/components/ContactViaModal.tsx +80 -0
  125. package/src/components/ScreenHeader.tsx +57 -0
  126. package/src/components/SearchBar.tsx +59 -0
  127. package/src/components/TabsHeader.tsx +72 -0
  128. package/src/components/index.ts +5 -0
  129. package/src/constants/Colors.ts +2 -1
  130. package/src/index.tsx +6 -4
  131. package/src/navigation/AppNavigator.tsx +6 -4
  132. package/src/navigation/BottomTabNavigator.tsx +51 -22
  133. package/src/navigation/DrawerNavigator.tsx +38 -33
  134. package/src/navigation/StackNavigator.tsx +32 -0
  135. package/src/screens/CRM/AddContactModal.tsx +57 -0
  136. package/src/screens/CRM/CategoryTabs.tsx +109 -0
  137. package/src/screens/CRM/ContactItem.tsx +168 -0
  138. package/src/screens/CRM/FilterDropdown.tsx +34 -0
  139. package/src/screens/CRM/FunnelChart.tsx +103 -0
  140. package/src/screens/CRM/InfoCard.tsx +51 -0
  141. package/src/screens/CRM/LeadCard.tsx +69 -0
  142. package/src/screens/CRM/LogCallScreen.tsx +318 -0
  143. package/src/screens/CRM/TopTabs.tsx +95 -0
  144. package/src/screens/CRM/index.ts +10 -0
  145. package/src/screens/ReportsScreen.tsx +7 -4
  146. package/src/screens/Tabs/ActivityAnalytics.tsx +25 -0
  147. package/src/screens/Tabs/CRMScreen.tsx +381 -0
  148. package/src/screens/Tabs/DigitalDiary.tsx +35 -0
  149. package/src/screens/Tabs/HomeScreen.tsx +223 -0
  150. package/src/screens/Tabs/NotificationsScreen.tsx +25 -0
  151. package/src/screens/contentliberary/contentliberary.tsx +268 -0
  152. package/lib/module/screens/CRMScreen.js +0 -41
  153. package/lib/module/screens/CRMScreen.js.map +0 -1
  154. package/lib/module/screens/HomeScreen.js +0 -211
  155. package/lib/module/screens/HomeScreen.js.map +0 -1
  156. package/lib/module/screens/NotificationsScreen.js +0 -41
  157. package/lib/module/screens/NotificationsScreen.js.map +0 -1
  158. package/lib/module/screens/ProfileScreen.js +0 -41
  159. package/lib/module/screens/ProfileScreen.js.map +0 -1
  160. package/lib/typescript/src/screens/CRMScreen.d.ts +0 -2
  161. package/lib/typescript/src/screens/CRMScreen.d.ts.map +0 -1
  162. package/lib/typescript/src/screens/HomeScreen.d.ts +0 -2
  163. package/lib/typescript/src/screens/HomeScreen.d.ts.map +0 -1
  164. package/lib/typescript/src/screens/NotificationsScreen.d.ts +0 -2
  165. package/lib/typescript/src/screens/NotificationsScreen.d.ts.map +0 -1
  166. package/lib/typescript/src/screens/ProfileScreen.d.ts +0 -2
  167. package/lib/typescript/src/screens/ProfileScreen.d.ts.map +0 -1
  168. package/src/screens/CRMScreen.tsx +0 -34
  169. package/src/screens/HomeScreen.tsx +0 -201
  170. package/src/screens/NotificationsScreen.tsx +0 -34
  171. package/src/screens/ProfileScreen.tsx +0 -34
@@ -0,0 +1,381 @@
1
+ import { useState } from 'react';
2
+ import {
3
+ StyleSheet,
4
+ ScrollView,
5
+ View,
6
+ Text,
7
+ TouchableOpacity,
8
+ } from 'react-native';
9
+ import { scale, verticalScale, moderateScale } from 'react-native-size-matters';
10
+ import { SafeAreaView } from 'react-native-safe-area-context';
11
+ import { Colors } from '../../constants/Colors';
12
+ import { SearchBar } from '../../components/SearchBar';
13
+ import { ContactViaModal } from '../../components/ContactViaModal';
14
+ import { useNavigation } from '@react-navigation/native';
15
+ import type { NativeStackNavigationProp } from '@react-navigation/native-stack';
16
+ import type { RootStackParamList } from '../../navigation/StackNavigator';
17
+ import {
18
+ FilterDropdown,
19
+ TopTabs,
20
+ InfoCard,
21
+ CategoryTabs,
22
+ FunnelChart,
23
+ ContactItem,
24
+ LeadCard,
25
+ AddContactModal,
26
+ } from '../CRM';
27
+ import TabsHeader from '../../components/TabsHeader';
28
+
29
+ type CRMScreenNavigationProp = NativeStackNavigationProp<RootStackParamList>;
30
+
31
+ const CRMScreen: React.FC = () => {
32
+ const navigation = useNavigation<CRMScreenNavigationProp>();
33
+ const [selectedTab, setSelectedTab] = useState<
34
+ 'leads' | 'prospects' | 'contacts'
35
+ >('leads');
36
+ const [selectedCategory, setSelectedCategory] = useState<
37
+ 'all' | 'followUp' | 'new' | 'engaged'
38
+ >('all');
39
+ const [showAddContactModal, setShowAddContactModal] = useState(false);
40
+ const [showContactViaModal, setShowContactViaModal] = useState(false);
41
+ const [selectedContact, setSelectedContact] = useState<any>(null);
42
+
43
+ const tabCounts = {
44
+ leads: 44,
45
+ prospects: 11,
46
+ contacts: 1865,
47
+ };
48
+
49
+ const funnelData = {
50
+ followUp: 11,
51
+ new: 44,
52
+ engaged: 0,
53
+ deal: 0,
54
+ quoteSent: 0,
55
+ won: 0,
56
+ dropped: 0,
57
+ };
58
+
59
+ // Sample data for contacts (with phone numbers)
60
+ const contactsData = [
61
+ {
62
+ name: 'Amit',
63
+ phone: '7677777700',
64
+ email: 'amitjai@icc.com',
65
+ avatarColor: '#C8A4C8',
66
+ avatarInitial: 'A',
67
+ },
68
+ {
69
+ name: 'Hari',
70
+ phone: '9797445501',
71
+ email: 'harikapoor@icc.com',
72
+ avatarColor: '#8B7C93',
73
+ avatarInitial: 'H',
74
+ },
75
+ {
76
+ name: 'Garry Kumar',
77
+ phone: '7878565601',
78
+ email: '',
79
+ avatarColor: '#C8A4C8',
80
+ avatarInitial: 'G',
81
+ },
82
+ {
83
+ name: 'rishabh sharma',
84
+ phone: '08006760073',
85
+ email: 'rishabh.sharma.for.me@gmail.com',
86
+ avatarColor: '#D4E4B4',
87
+ avatarInitial: 'R',
88
+ },
89
+ {
90
+ name: 'kumara lafosa',
91
+ phone: '6658388899',
92
+ email: 'kumara@mail.com',
93
+ avatarColor: '#B4D4E4',
94
+ avatarInitial: 'K',
95
+ },
96
+ {
97
+ name: 'raghvendra vashisht',
98
+ phone: '6987236496',
99
+ email: 'raghavendra@mail.com',
100
+ avatarColor: '#F4C4A4',
101
+ avatarInitial: 'R',
102
+ },
103
+ {
104
+ name: 'rishabh kumaea',
105
+ phone: '8923764268',
106
+ email: 'rishi@mail.com',
107
+ avatarColor: '#C8A4C8',
108
+ avatarInitial: 'R',
109
+ },
110
+ ];
111
+ const prospectsData = [
112
+ {
113
+ name: 'Harry Sharma',
114
+ description: 'Harry Sharma just visited your microsite',
115
+ avatarColor: '#C84B9E',
116
+ avatarInitial: 'H',
117
+ },
118
+ {
119
+ name: 'Alfred Jones',
120
+ description: 'Alfred Jones just visited your microsite',
121
+ avatarColor: '#8B7C93',
122
+ avatarInitial: 'A',
123
+ },
124
+ {
125
+ name: 'Mahendra Jee',
126
+ description: 'The prospect is added manually.',
127
+ avatarColor: '#C84B9E',
128
+ avatarInitial: 'M',
129
+ },
130
+ {
131
+ name: 'Rraghav Vohra',
132
+ description:
133
+ 'Rraghav Vohra just visited your microsite by clicking on the content Auto Email "Rraghav\'s Indirect Template Technochimes 13th May"',
134
+ avatarColor: '#9BC75C',
135
+ avatarInitial: 'R',
136
+ },
137
+ {
138
+ name: 'Mike Jordan',
139
+ description:
140
+ 'Mike Jordan just visited your microsite by clicking on the content Auto Email "Rraghav\'s Indirect Template Technochimes 13th May"',
141
+ avatarColor: '#5CB7C7',
142
+ avatarInitial: 'M',
143
+ },
144
+ ];
145
+
146
+ // Sample data for leads
147
+ const leadsData = {
148
+ new: [
149
+ {
150
+ name: 'Richa Jaiswall',
151
+ email: 'richa.jaiswal@salespanda.com',
152
+ description: 'Last visited your microsite and filled a Lead.',
153
+ timestamp: '10-Nov-2025 03:42 PM',
154
+ },
155
+ {
156
+ name: 'Amit',
157
+ email: 'amitjai@icc.com',
158
+ description: 'Last visited your microsite and filled a Lead.',
159
+ timestamp: '18-Sep-2025 11:48 AM',
160
+ },
161
+ ],
162
+ followUp: [
163
+ {
164
+ name: 'Harry Sharma',
165
+ email: 'harish.sharma@salespanda.com',
166
+ description: 'Last visited your microsite.',
167
+ timestamp: '27-Jun-2025 06:47 PM',
168
+ },
169
+ {
170
+ name: 'Alfred Jones',
171
+ email: 'alfred.jones@salespanda.com',
172
+ description: 'Last visited your microsite.',
173
+ timestamp: '15-May-2025 12:11 PM',
174
+ },
175
+ ],
176
+ };
177
+
178
+ const renderContent = () => {
179
+ // Prospects tab - always show contact list
180
+ if (selectedTab === 'prospects') {
181
+ return (
182
+ <>
183
+ <SearchBar placeholder="Search by name" />
184
+ {prospectsData.map((contact, index) => (
185
+ <ContactItem
186
+ key={index}
187
+ {...contact}
188
+ showActionButtons={true}
189
+ onReminderPress={() => console.log('Reminder:', contact.name)}
190
+ onCallPress={() => {
191
+ navigation.navigate('LogCall', {
192
+ contact: {
193
+ name: contact.name,
194
+ avatarInitial: contact.avatarInitial,
195
+ avatarColor: contact.avatarColor,
196
+ },
197
+ });
198
+ }}
199
+ onMenuPress={() => {
200
+ setSelectedContact(contact);
201
+ setShowContactViaModal(true);
202
+ }}
203
+ />
204
+ ))}
205
+ </>
206
+ );
207
+ }
208
+
209
+ // Leads tab - show different content based on category
210
+ if (selectedTab === 'leads') {
211
+ // Show funnel chart only when "All" is selected
212
+ if (selectedCategory === 'all') {
213
+ return (
214
+ <>
215
+ <InfoCard />
216
+ <CategoryTabs
217
+ selectedCategory={selectedCategory}
218
+ onSelectCategory={setSelectedCategory}
219
+ />
220
+ <FunnelChart data={funnelData} totalLeads={55} />
221
+ </>
222
+ );
223
+ }
224
+
225
+ // Show lead cards for specific categories
226
+ const categoryData =
227
+ selectedCategory === 'new'
228
+ ? leadsData.new
229
+ : selectedCategory === 'followUp'
230
+ ? leadsData.followUp
231
+ : [];
232
+
233
+ return (
234
+ <>
235
+ <InfoCard />
236
+ <CategoryTabs
237
+ selectedCategory={selectedCategory}
238
+ onSelectCategory={setSelectedCategory}
239
+ />
240
+ <View style={styles.totalLeads}>
241
+ <Text style={styles.totalLeadsText}>
242
+ Total Leads: {categoryData.length}
243
+ </Text>
244
+ </View>
245
+ {categoryData.map((lead, index) => (
246
+ <LeadCard key={index} {...lead} />
247
+ ))}
248
+ </>
249
+ );
250
+ }
251
+
252
+ if (selectedTab === 'contacts') {
253
+ return (
254
+ <>
255
+ <SearchBar placeholder="Search by name, number.." />
256
+ {contactsData.map((contact, index) => (
257
+ <ContactItem key={index} {...contact} showCheckbox={true} />
258
+ ))}
259
+ </>
260
+ );
261
+ }
262
+
263
+ return null;
264
+ };
265
+
266
+ return (
267
+ <SafeAreaView style={styles.container} edges={['top', 'bottom']}>
268
+ <TabsHeader title="CRM" rightSlot={<FilterDropdown />} />
269
+
270
+ <TopTabs
271
+ selectedTab={selectedTab}
272
+ onSelectTab={setSelectedTab}
273
+ counts={tabCounts}
274
+ />
275
+
276
+ <ScrollView style={styles.scrollView}>{renderContent()}</ScrollView>
277
+
278
+ {selectedTab === 'contacts' && (
279
+ <TouchableOpacity
280
+ style={styles.fab}
281
+ onPress={() => setShowAddContactModal(true)}
282
+ >
283
+ <Text style={styles.fabIcon}>+</Text>
284
+ </TouchableOpacity>
285
+ )}
286
+
287
+ <AddContactModal
288
+ visible={showAddContactModal}
289
+ onClose={() => setShowAddContactModal(false)}
290
+ onAddManually={() => {
291
+ // Navigate to add manually screen
292
+ console.log('Add manually');
293
+ }}
294
+ onUploadGmail={() => {
295
+ // Handle Gmail contact import
296
+ console.log('Upload Gmail');
297
+ }}
298
+ onUploadPhonebook={() => {
299
+ // Handle phonebook import
300
+ console.log('Upload Phonebook');
301
+ }}
302
+ onUploadCSV={() => {
303
+ // Handle CSV upload
304
+ console.log('Upload CSV');
305
+ }}
306
+ />
307
+
308
+ <ContactViaModal
309
+ visible={showContactViaModal}
310
+ onClose={() => setShowContactViaModal(false)}
311
+ onCall={() => {
312
+ console.log('Call:', selectedContact?.name);
313
+ // Handle call
314
+ }}
315
+ onWhatsapp={() => {
316
+ console.log('WhatsApp:', selectedContact?.name);
317
+ // Handle WhatsApp
318
+ }}
319
+ onEmail={() => {
320
+ console.log('Email:', selectedContact?.name);
321
+ // Handle email
322
+ }}
323
+ onSMS={() => {
324
+ console.log('SMS:', selectedContact?.name);
325
+ // Handle SMS
326
+ }}
327
+ onAddTask={() => {
328
+ console.log('Add Task for:', selectedContact?.name);
329
+ // Navigate to add task screen
330
+ }}
331
+ onAddNote={() => {
332
+ console.log('Add Note for:', selectedContact?.name);
333
+ // Navigate to add note screen
334
+ }}
335
+ />
336
+ </SafeAreaView>
337
+ );
338
+ };
339
+
340
+ export default CRMScreen;
341
+
342
+ const styles = StyleSheet.create({
343
+ container: {
344
+ flex: 1,
345
+ backgroundColor: Colors.background,
346
+ },
347
+ scrollView: {
348
+ flex: 1,
349
+ },
350
+ totalLeads: {
351
+ paddingHorizontal: scale(16),
352
+ paddingVertical: verticalScale(12),
353
+ backgroundColor: Colors.white,
354
+ },
355
+ totalLeadsText: {
356
+ fontSize: moderateScale(16),
357
+ fontWeight: '700',
358
+ color: Colors.black,
359
+ },
360
+ fab: {
361
+ position: 'absolute',
362
+ right: scale(16),
363
+ bottom: verticalScale(10),
364
+ width: scale(46),
365
+ height: scale(46),
366
+ borderRadius: moderateScale(28),
367
+ backgroundColor: '#46bdd3',
368
+ justifyContent: 'center',
369
+ alignItems: 'center',
370
+ shadowColor: Colors.black,
371
+ shadowOffset: { width: 0, height: verticalScale(4) },
372
+ shadowOpacity: 0.3,
373
+ shadowRadius: moderateScale(8),
374
+ elevation: 8,
375
+ },
376
+ fabIcon: {
377
+ fontSize: moderateScale(32),
378
+ color: Colors.white,
379
+ fontWeight: '300',
380
+ },
381
+ });
@@ -0,0 +1,35 @@
1
+ import { ScrollView, StyleSheet, Text } from 'react-native';
2
+ import { SafeAreaView } from 'react-native-safe-area-context';
3
+ import { Colors } from '../../constants/Colors';
4
+ import TabsHeader from '../../components/TabsHeader';
5
+
6
+ const DigitalDiary: React.FC = () => {
7
+ return (
8
+ <SafeAreaView style={styles.container} edges={['top', 'bottom']}>
9
+ <TabsHeader title="Digital Diary" />
10
+ <ScrollView contentContainerStyle={styles.content}>
11
+ <Text style={styles.placeholder}>
12
+ Digital Diary content coming soon.
13
+ </Text>
14
+ </ScrollView>
15
+ </SafeAreaView>
16
+ );
17
+ };
18
+
19
+ export default DigitalDiary;
20
+
21
+ const styles = StyleSheet.create({
22
+ container: {
23
+ flex: 1,
24
+ backgroundColor: Colors.background,
25
+ },
26
+ content: {
27
+ flexGrow: 1,
28
+ alignItems: 'center',
29
+ justifyContent: 'center',
30
+ padding: 24,
31
+ },
32
+ placeholder: {
33
+ color: Colors.black50,
34
+ },
35
+ });
@@ -0,0 +1,223 @@
1
+ import React from 'react';
2
+ import {
3
+ View,
4
+ Text,
5
+ StyleSheet,
6
+ TouchableOpacity,
7
+ ScrollView,
8
+ Image,
9
+ FlatList,
10
+ Dimensions,
11
+ } from 'react-native';
12
+ import { scale, verticalScale, moderateScale } from 'react-native-size-matters';
13
+ import { Colors } from '../../constants/Colors';
14
+ import { SafeAreaView } from 'react-native-safe-area-context';
15
+ import TabsHeader from '../../components/TabsHeader';
16
+
17
+ interface MenuItemProps {
18
+ title: string;
19
+ icon: string;
20
+ onPress?: () => void;
21
+ }
22
+
23
+ const MenuItem: React.FC<MenuItemProps> = ({ title, icon, onPress }) => {
24
+ return (
25
+ <TouchableOpacity style={styles.menuItem} onPress={onPress}>
26
+ <View style={styles.iconContainer}>
27
+ <Text style={styles.iconText}>{icon}</Text>
28
+ </View>
29
+ <Text style={styles.menuItemText}>{title}</Text>
30
+ </TouchableOpacity>
31
+ );
32
+ };
33
+
34
+ const HomeScreen: React.FC = () => {
35
+ const images = [
36
+ 'https://images.unsplash.com/photo-1500530855697-b586d89ba3ee?q=80&w=1200&auto=format&fit=crop',
37
+ 'https://images.unsplash.com/photo-1482192596544-9eb780fc7f66?q=80&w=1200&auto=format&fit=crop',
38
+ 'https://images.unsplash.com/photo-1522071820081-009f0129c71c?q=80&w=1200&auto=format&fit=crop',
39
+ 'https://images.unsplash.com/photo-1501785888041-af3ef285b470?q=80&w=1200&auto=format&fit=crop',
40
+ 'https://images.unsplash.com/photo-1460353581641-37baddab0fa2?q=80&w=1200&auto=format&fit=crop',
41
+ 'https://images.unsplash.com/photo-1496302662116-35cc4f36df92?q=80&w=1200&auto=format&fit=crop',
42
+ ];
43
+ const screenWidth = Dimensions.get('window').width;
44
+ const [activeIndex, setActiveIndex] = React.useState(0);
45
+ const flatListRef = React.useRef<any>(null);
46
+
47
+ const handleMomentumScrollEnd = (e: any) => {
48
+ const offsetX = e.nativeEvent.contentOffset.x;
49
+ const index = Math.round(offsetX / screenWidth);
50
+ setActiveIndex(index);
51
+ };
52
+ React.useEffect(() => {
53
+ const id = setInterval(() => {
54
+ setActiveIndex((prev) => {
55
+ const next = (prev + 1) % images.length;
56
+ if (flatListRef.current) {
57
+ try {
58
+ flatListRef.current.scrollToIndex({ index: next, animated: true });
59
+ } catch {
60
+ // ignore scroll failures
61
+ }
62
+ }
63
+ return next;
64
+ });
65
+ }, 2500);
66
+ return () => clearInterval(id);
67
+ }, [images.length]);
68
+
69
+ return (
70
+ <SafeAreaView style={styles.safeArea} edges={['top', 'bottom']}>
71
+ <View style={styles.container}>
72
+ <TabsHeader title="Home" />
73
+ <ScrollView style={styles.scrollView}>
74
+ {/* Edge-to-edge Image Carousel */}
75
+ <View style={styles.carouselContainer}>
76
+ <FlatList
77
+ ref={flatListRef}
78
+ data={images}
79
+ keyExtractor={(_, idx) => `${idx}`}
80
+ renderItem={({ item }) => (
81
+ <Image
82
+ source={{ uri: item }}
83
+ style={[styles.carouselImage, { width: screenWidth }]}
84
+ />
85
+ )}
86
+ horizontal
87
+ pagingEnabled
88
+ showsHorizontalScrollIndicator={false}
89
+ onMomentumScrollEnd={handleMomentumScrollEnd}
90
+ getItemLayout={(_, index) => ({
91
+ length: screenWidth,
92
+ offset: screenWidth * index,
93
+ index,
94
+ })}
95
+ />
96
+ {/* Overlay Indicators at bottom of the image */}
97
+ <View style={styles.carouselIndicatorsOverlay}>
98
+ {images.map((_, idx) => (
99
+ <View
100
+ key={idx}
101
+ style={[
102
+ styles.indicator,
103
+ idx === activeIndex ? styles.activeIndicator : null,
104
+ ]}
105
+ />
106
+ ))}
107
+ </View>
108
+ </View>
109
+
110
+ {/* Menu Grid */}
111
+ <View style={styles.menuGrid}>
112
+ <MenuItem title="Content Library" icon="📚" />
113
+ <MenuItem title="DigiCard" icon="�" />
114
+ <MenuItem title="Leads" icon="🎯" />
115
+
116
+ <MenuItem title="Email Campaign" icon="📧" />
117
+ <MenuItem title="Cadence" icon="⏰" />
118
+ <MenuItem title="Social Setup" icon="�" />
119
+
120
+ <MenuItem title="Quiz,Calculator & Referrals" icon="❓" />
121
+ <MenuItem title="My Profile" icon="�" />
122
+
123
+ <MenuItem title="Microsite Setup" icon="⚙️" />
124
+ <MenuItem title="My Activity" icon="📊" />
125
+ <MenuItem title="Internal Communication" icon="💬" />
126
+
127
+ <MenuItem title="Help Videos" icon="🎥" />
128
+ <MenuItem title="Import Gmail" icon="�" />
129
+ <MenuItem title="Proposal" icon="📋" />
130
+
131
+ <MenuItem title="Courses" icon="🎓" />
132
+ </View>
133
+ </ScrollView>
134
+ </View>
135
+ </SafeAreaView>
136
+ );
137
+ };
138
+
139
+ export default HomeScreen;
140
+
141
+ const styles = StyleSheet.create({
142
+ safeArea: {
143
+ flex: 1,
144
+ backgroundColor: Colors.white,
145
+ },
146
+ container: {
147
+ flex: 1,
148
+ backgroundColor: Colors.white,
149
+ },
150
+ scrollView: {
151
+ flex: 1,
152
+ backgroundColor: Colors.white,
153
+ },
154
+ carouselContainer: {
155
+ width: '100%',
156
+ backgroundColor: Colors.white, // subtle backplate for image load
157
+ position: 'relative',
158
+ },
159
+ carouselImage: {
160
+ height: verticalScale(200),
161
+ resizeMode: 'cover',
162
+ },
163
+ carouselIndicatorsOverlay: {
164
+ position: 'absolute',
165
+ left: 0,
166
+ right: 0,
167
+ bottom: verticalScale(12),
168
+ flexDirection: 'row',
169
+ justifyContent: 'center',
170
+ alignItems: 'center',
171
+ },
172
+ indicator: {
173
+ width: scale(8),
174
+ height: scale(8),
175
+ borderRadius: moderateScale(4),
176
+ backgroundColor: Colors.divider,
177
+ marginHorizontal: scale(4),
178
+ },
179
+ activeIndicator: {
180
+ backgroundColor: Colors.white,
181
+ width: scale(24),
182
+ },
183
+ menuGrid: {
184
+ flexDirection: 'row',
185
+ flexWrap: 'wrap',
186
+ padding: scale(8),
187
+ justifyContent: 'space-between',
188
+ },
189
+ menuItem: {
190
+ width: '31%',
191
+ aspectRatio: 1,
192
+ backgroundColor: Colors.lightblue,
193
+ borderRadius: moderateScale(16),
194
+ padding: scale(12),
195
+ marginBottom: verticalScale(12),
196
+ alignItems: 'center',
197
+ justifyContent: 'center',
198
+ shadowColor: Colors.black,
199
+ shadowOffset: { width: 0, height: 0 },
200
+ shadowOpacity: 0.1,
201
+ shadowRadius: 0.5,
202
+ borderWidth: 1,
203
+ borderColor: Colors.border,
204
+ },
205
+ iconContainer: {
206
+ width: scale(50),
207
+ height: scale(50),
208
+ borderRadius: moderateScale(25),
209
+ backgroundColor: Colors.divider,
210
+ justifyContent: 'center',
211
+ alignItems: 'center',
212
+ marginBottom: verticalScale(8),
213
+ },
214
+ iconText: {
215
+ fontSize: moderateScale(24),
216
+ },
217
+ menuItemText: {
218
+ fontSize: moderateScale(11),
219
+ textAlign: 'center',
220
+ color: Colors.black,
221
+ fontWeight: '500',
222
+ },
223
+ });
@@ -0,0 +1,25 @@
1
+ import { StyleSheet, ScrollView } from 'react-native';
2
+ import { SafeAreaView } from 'react-native-safe-area-context';
3
+ import { Colors } from '../../constants/Colors';
4
+ import TabsHeader from '../../components/TabsHeader';
5
+
6
+ const NotificationsScreen: React.FC = () => {
7
+ return (
8
+ <SafeAreaView style={styles.container} edges={['top', 'bottom']}>
9
+ <TabsHeader title="Notifications" />
10
+ <ScrollView style={styles.scrollView} />
11
+ </SafeAreaView>
12
+ );
13
+ };
14
+
15
+ export default NotificationsScreen;
16
+
17
+ const styles = StyleSheet.create({
18
+ container: {
19
+ flex: 1,
20
+ backgroundColor: Colors.background,
21
+ },
22
+ scrollView: {
23
+ flex: 1,
24
+ },
25
+ });