react-native-contacts 7.0.8 → 8.0.1

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/.tool-versions CHANGED
@@ -1 +1 @@
1
- nodejs 19.2.0
1
+ nodejs lts
@@ -9,8 +9,14 @@ buildscript {
9
9
  }
10
10
  }
11
11
 
12
- apply plugin: 'com.android.library'
12
+ def isNewArchitectureEnabled() {
13
+ return project.hasProperty("newArchEnabled") && project.newArchEnabled == "true"
14
+ }
13
15
 
16
+ apply plugin: 'com.android.library'
17
+ if (isNewArchitectureEnabled()) {
18
+ apply plugin: 'com.facebook.react'
19
+ }
14
20
  def DEFAULT_MIN_SDK_VERSION = 21
15
21
  def DEFAULT_COMPILE_SDK_VERSION = 29
16
22
  def DEFAULT_TARGET_SDK_VERSION = 29
@@ -30,6 +36,20 @@ android {
30
36
  targetSdkVersion rootProject.hasProperty('targetSdkVersion') ? rootProject.targetSdkVersion : DEFAULT_TARGET_SDK_VERSION
31
37
  versionCode 1
32
38
  versionName "1.0"
39
+ buildConfigField("boolean", "IS_NEW_ARCHITECTURE_ENABLED", isNewArchitectureEnabled().toString())
40
+ }
41
+ sourceSets {
42
+ main {
43
+ if (isNewArchitectureEnabled()) {
44
+ java.srcDirs += [
45
+ "src/newarch",
46
+ // This is needed to build Kotlin project with NewArch enabled
47
+ "${project.buildDir}/generated/source/codegen/java"
48
+ ]
49
+ } else {
50
+ java.srcDirs += ["src/oldarch"]
51
+ }
52
+ }
33
53
  }
34
54
  lintOptions {
35
55
  abortOnError false
@@ -43,3 +63,10 @@ repositories {
43
63
  dependencies {
44
64
  implementation 'com.facebook.react:react-native:+'
45
65
  }
66
+ if (isNewArchitectureEnabled()) {
67
+ react {
68
+ jsRootDir = file("../src/")
69
+ libraryName = "react-native-contacts"
70
+ codegenJavaPackageName = "com.rt2zz.reactnativecontacts"
71
+ }
72
+ }
@@ -1,6 +1,7 @@
1
1
  package com.rt2zz.reactnativecontacts;
2
2
 
3
3
  import android.content.ContentResolver;
4
+ import android.content.res.Resources;
4
5
  import android.database.Cursor;
5
6
  import android.net.Uri;
6
7
  import android.provider.ContactsContract;
@@ -32,56 +33,63 @@ import static android.provider.ContactsContract.CommonDataKinds.StructuredPostal
32
33
  public class ContactsProvider {
33
34
  public static final int ID_FOR_PROFILE_CONTACT = -1;
34
35
 
35
- private static final List<String> JUST_ME_PROJECTION = new ArrayList<String>() {{
36
- add((ContactsContract.Data._ID));
37
- add(ContactsContract.Data.CONTACT_ID);
38
- add(ContactsContract.Data.RAW_CONTACT_ID);
39
- add(ContactsContract.Data.LOOKUP_KEY);
40
- add(ContactsContract.Data.STARRED);
41
- add(ContactsContract.Contacts.Data.MIMETYPE);
42
- add(ContactsContract.Profile.DISPLAY_NAME);
43
- add(Contactables.PHOTO_URI);
44
- add(StructuredName.DISPLAY_NAME);
45
- add(StructuredName.GIVEN_NAME);
46
- add(StructuredName.MIDDLE_NAME);
47
- add(StructuredName.FAMILY_NAME);
48
- add(StructuredName.PREFIX);
49
- add(StructuredName.SUFFIX);
50
- add(Phone.NUMBER);
51
- add(Phone.NORMALIZED_NUMBER);
52
- add(Phone.TYPE);
53
- add(Phone.LABEL);
54
- add(Email.DATA);
55
- add(Email.ADDRESS);
56
- add(Email.TYPE);
57
- add(Email.LABEL);
58
- add(Organization.COMPANY);
59
- add(Organization.TITLE);
60
- add(Organization.DEPARTMENT);
61
- add(StructuredPostal.FORMATTED_ADDRESS);
62
- add(StructuredPostal.TYPE);
63
- add(StructuredPostal.LABEL);
64
- add(StructuredPostal.STREET);
65
- add(StructuredPostal.POBOX);
66
- add(StructuredPostal.NEIGHBORHOOD);
67
- add(StructuredPostal.CITY);
68
- add(StructuredPostal.REGION);
69
- add(StructuredPostal.POSTCODE);
70
- add(StructuredPostal.COUNTRY);
71
- add(Note.NOTE);
72
- add(Website.URL);
73
- add(Im.DATA);
74
- add(Event.START_DATE);
75
- add(Event.TYPE);
76
- }};
77
-
78
- private static final List<String> FULL_PROJECTION = new ArrayList<String>() {{
79
- addAll(JUST_ME_PROJECTION);
80
- }};
81
-
82
- private static final List<String> PHOTO_PROJECTION = new ArrayList<String>() {{
83
- add(Contactables.PHOTO_URI);
84
- }};
36
+ public static final String NAME = "RCTContacts";
37
+ private static final List<String> JUST_ME_PROJECTION = new ArrayList<String>() {
38
+ {
39
+ add((ContactsContract.Data._ID));
40
+ add(ContactsContract.Data.CONTACT_ID);
41
+ add(ContactsContract.Data.RAW_CONTACT_ID);
42
+ add(ContactsContract.Data.LOOKUP_KEY);
43
+ add(ContactsContract.Data.STARRED);
44
+ add(ContactsContract.Contacts.Data.MIMETYPE);
45
+ add(ContactsContract.Profile.DISPLAY_NAME);
46
+ add(Contactables.PHOTO_URI);
47
+ add(StructuredName.DISPLAY_NAME);
48
+ add(StructuredName.GIVEN_NAME);
49
+ add(StructuredName.MIDDLE_NAME);
50
+ add(StructuredName.FAMILY_NAME);
51
+ add(StructuredName.PREFIX);
52
+ add(StructuredName.SUFFIX);
53
+ add(Phone.NUMBER);
54
+ add(Phone.NORMALIZED_NUMBER);
55
+ add(Phone.TYPE);
56
+ add(Phone.LABEL);
57
+ add(Email.DATA);
58
+ add(Email.ADDRESS);
59
+ add(Email.TYPE);
60
+ add(Email.LABEL);
61
+ add(Organization.COMPANY);
62
+ add(Organization.TITLE);
63
+ add(Organization.DEPARTMENT);
64
+ add(StructuredPostal.FORMATTED_ADDRESS);
65
+ add(StructuredPostal.TYPE);
66
+ add(StructuredPostal.LABEL);
67
+ add(StructuredPostal.STREET);
68
+ add(StructuredPostal.POBOX);
69
+ add(StructuredPostal.NEIGHBORHOOD);
70
+ add(StructuredPostal.CITY);
71
+ add(StructuredPostal.REGION);
72
+ add(StructuredPostal.POSTCODE);
73
+ add(StructuredPostal.COUNTRY);
74
+ add(Note.NOTE);
75
+ add(Website.URL);
76
+ add(Im.DATA);
77
+ add(Event.START_DATE);
78
+ add(Event.TYPE);
79
+ }
80
+ };
81
+
82
+ private static final List<String> FULL_PROJECTION = new ArrayList<String>() {
83
+ {
84
+ addAll(JUST_ME_PROJECTION);
85
+ }
86
+ };
87
+
88
+ private static final List<String> PHOTO_PROJECTION = new ArrayList<String>() {
89
+ {
90
+ add(Contactables.PHOTO_URI);
91
+ }
92
+ };
85
93
 
86
94
  private final ContentResolver contentResolver;
87
95
 
@@ -97,9 +105,8 @@ public class ContactsProvider {
97
105
  FULL_PROJECTION.toArray(new String[FULL_PROJECTION.size()]),
98
106
  ContactsContract.Contacts.DISPLAY_NAME_PRIMARY + " LIKE ? OR " +
99
107
  Organization.COMPANY + " LIKE ?",
100
- new String[]{"%" + searchString + "%", "%" + searchString + "%"},
101
- null
102
- );
108
+ new String[] { "%" + searchString + "%", "%" + searchString + "%" },
109
+ null);
103
110
 
104
111
  try {
105
112
  matchingContacts = loadContactsFrom(cursor);
@@ -117,7 +124,6 @@ public class ContactsProvider {
117
124
  return contacts;
118
125
  }
119
126
 
120
-
121
127
  public WritableArray getContactsByPhoneNumber(String phoneNumber) {
122
128
  Map<String, Contact> matchingContacts;
123
129
  {
@@ -126,9 +132,8 @@ public class ContactsProvider {
126
132
  FULL_PROJECTION.toArray(new String[FULL_PROJECTION.size()]),
127
133
  ContactsContract.CommonDataKinds.Phone.NUMBER + " LIKE ? OR "
128
134
  + ContactsContract.CommonDataKinds.Phone.NORMALIZED_NUMBER + " LIKE ?",
129
- new String[]{"%" + phoneNumber + "%", "%" + phoneNumber + "%"},
130
- null
131
- );
135
+ new String[] { "%" + phoneNumber + "%", "%" + phoneNumber + "%" },
136
+ null);
132
137
 
133
138
  try {
134
139
  matchingContacts = loadContactsFrom(cursor);
@@ -153,9 +158,8 @@ public class ContactsProvider {
153
158
  ContactsContract.Data.CONTENT_URI,
154
159
  FULL_PROJECTION.toArray(new String[FULL_PROJECTION.size()]),
155
160
  ContactsContract.CommonDataKinds.Email.ADDRESS + " LIKE ?",
156
- new String[]{"%" + emailAddress + "%"},
157
- null
158
- );
161
+ new String[] { "%" + emailAddress + "%" },
162
+ null);
159
163
 
160
164
  try {
161
165
  matchingContacts = loadContactsFrom(cursor);
@@ -173,16 +177,17 @@ public class ContactsProvider {
173
177
  return contacts;
174
178
  }
175
179
 
176
- public WritableMap getContactByRawId(String contactRawId) {
180
+ public WritableMap getContactByRawId(String contactRawId) {
177
181
 
178
182
  // Get Contact Id from Raw Contact Id
179
- String[] projections = new String[]{ContactsContract.RawContacts.CONTACT_ID};
183
+ String[] projections = new String[] { ContactsContract.RawContacts.CONTACT_ID };
180
184
  String select = ContactsContract.RawContacts._ID + "= ?";
181
- String[] selectionArgs = new String[]{contactRawId};
182
- Cursor rawCursor = contentResolver.query(ContactsContract.RawContacts.CONTENT_URI, projections, select, selectionArgs, null);
185
+ String[] selectionArgs = new String[] { contactRawId };
186
+ Cursor rawCursor = contentResolver.query(ContactsContract.RawContacts.CONTENT_URI, projections, select,
187
+ selectionArgs, null);
183
188
  String contactId = null;
184
189
  if (rawCursor.getCount() == 0) {
185
- /*contact id not found */
190
+ /* contact id not found */
186
191
  }
187
192
 
188
193
  if (cursorMoveToNext(rawCursor)) {
@@ -197,7 +202,7 @@ public class ContactsProvider {
197
202
 
198
203
  rawCursor.close();
199
204
 
200
- //Now that we have the real contact id, fetch information
205
+ // Now that we have the real contact id, fetch information
201
206
  return getContactById(contactId);
202
207
  }
203
208
 
@@ -206,12 +211,11 @@ public class ContactsProvider {
206
211
  Map<String, Contact> matchingContacts;
207
212
  {
208
213
  Cursor cursor = contentResolver.query(
209
- ContactsContract.Data.CONTENT_URI,
210
- FULL_PROJECTION.toArray(new String[FULL_PROJECTION.size()]),
211
- ContactsContract.RawContacts.CONTACT_ID + " = ?",
212
- new String[]{contactId},
213
- null
214
- );
214
+ ContactsContract.Data.CONTENT_URI,
215
+ FULL_PROJECTION.toArray(new String[FULL_PROJECTION.size()]),
216
+ ContactsContract.RawContacts.CONTACT_ID + " = ?",
217
+ new String[] { contactId },
218
+ null);
215
219
 
216
220
  try {
217
221
  matchingContacts = loadContactsFrom(cursor);
@@ -222,17 +226,17 @@ public class ContactsProvider {
222
226
  }
223
227
  }
224
228
 
225
- if(matchingContacts.values().size() > 0) {
229
+ if (matchingContacts.values().size() > 0) {
226
230
  return matchingContacts.values().iterator().next().toMap();
227
231
  }
228
232
 
229
- return null;
233
+ return null;
230
234
  }
231
235
 
232
236
  public Integer getContactsCount() {
233
- Cursor cursor = contentResolver.query(ContactsContract.Contacts.CONTENT_URI, null, null, null, null);
237
+ Cursor cursor = contentResolver.query(ContactsContract.Contacts.CONTENT_URI, null, null, null, null);
234
238
  int count = cursor.getCount();
235
-
239
+
236
240
  return count;
237
241
  }
238
242
 
@@ -240,12 +244,12 @@ public class ContactsProvider {
240
244
  Map<String, Contact> justMe;
241
245
  {
242
246
  Cursor cursor = contentResolver.query(
243
- Uri.withAppendedPath(ContactsContract.Profile.CONTENT_URI, ContactsContract.Contacts.Data.CONTENT_DIRECTORY),
247
+ Uri.withAppendedPath(ContactsContract.Profile.CONTENT_URI,
248
+ ContactsContract.Contacts.Data.CONTENT_DIRECTORY),
244
249
  JUST_ME_PROJECTION.toArray(new String[JUST_ME_PROJECTION.size()]),
245
250
  null,
246
251
  null,
247
- null
248
- );
252
+ null);
249
253
 
250
254
  try {
251
255
  justMe = loadContactsFrom(cursor);
@@ -262,27 +266,26 @@ public class ContactsProvider {
262
266
  ContactsContract.Data.CONTENT_URI,
263
267
  FULL_PROJECTION.toArray(new String[FULL_PROJECTION.size()]),
264
268
  ContactsContract.Data.MIMETYPE + "=? OR "
265
- + ContactsContract.Data.MIMETYPE + "=? OR "
266
- + ContactsContract.Data.MIMETYPE + "=? OR "
267
- + ContactsContract.Data.MIMETYPE + "=? OR "
268
- + ContactsContract.Data.MIMETYPE + "=? OR "
269
- + ContactsContract.Data.MIMETYPE + "=? OR "
270
- + ContactsContract.Data.MIMETYPE + "=? OR "
271
- + ContactsContract.Data.MIMETYPE + "=? OR "
272
- + ContactsContract.Data.MIMETYPE + "=?",
273
- new String[]{
274
- Email.CONTENT_ITEM_TYPE,
275
- Phone.CONTENT_ITEM_TYPE,
276
- StructuredName.CONTENT_ITEM_TYPE,
277
- Organization.CONTENT_ITEM_TYPE,
278
- StructuredPostal.CONTENT_ITEM_TYPE,
279
- Note.CONTENT_ITEM_TYPE,
280
- Website.CONTENT_ITEM_TYPE,
281
- Im.CONTENT_ITEM_TYPE,
282
- Event.CONTENT_ITEM_TYPE,
269
+ + ContactsContract.Data.MIMETYPE + "=? OR "
270
+ + ContactsContract.Data.MIMETYPE + "=? OR "
271
+ + ContactsContract.Data.MIMETYPE + "=? OR "
272
+ + ContactsContract.Data.MIMETYPE + "=? OR "
273
+ + ContactsContract.Data.MIMETYPE + "=? OR "
274
+ + ContactsContract.Data.MIMETYPE + "=? OR "
275
+ + ContactsContract.Data.MIMETYPE + "=? OR "
276
+ + ContactsContract.Data.MIMETYPE + "=?",
277
+ new String[] {
278
+ Email.CONTENT_ITEM_TYPE,
279
+ Phone.CONTENT_ITEM_TYPE,
280
+ StructuredName.CONTENT_ITEM_TYPE,
281
+ Organization.CONTENT_ITEM_TYPE,
282
+ StructuredPostal.CONTENT_ITEM_TYPE,
283
+ Note.CONTENT_ITEM_TYPE,
284
+ Website.CONTENT_ITEM_TYPE,
285
+ Im.CONTENT_ITEM_TYPE,
286
+ Event.CONTENT_ITEM_TYPE,
283
287
  },
284
- null
285
- );
288
+ null);
286
289
 
287
290
  try {
288
291
  everyoneElse = loadContactsFrom(cursor);
@@ -307,7 +310,7 @@ public class ContactsProvider {
307
310
  private Boolean cursorMoveToNext(Cursor cursor) {
308
311
  try {
309
312
  return cursor.moveToNext();
310
- } catch(RuntimeException error) {
313
+ } catch (RuntimeException error) {
311
314
  return false;
312
315
  }
313
316
  }
@@ -328,22 +331,22 @@ public class ContactsProvider {
328
331
  if (columnIndexContactId != -1) {
329
332
  contactId = cursor.getString(columnIndexContactId);
330
333
  } else {
331
- //todo - double check this, it may not be necessary any more
332
- contactId = String.valueOf(ID_FOR_PROFILE_CONTACT);//no contact id for 'ME' user
334
+ // todo - double check this, it may not be necessary any more
335
+ contactId = String.valueOf(ID_FOR_PROFILE_CONTACT);// no contact id for 'ME' user
333
336
  }
334
337
 
335
338
  if (columnIndexId != -1) {
336
339
  id = cursor.getString(columnIndexId);
337
340
  } else {
338
- //todo - double check this, it may not be necessary any more
339
- id = String.valueOf(ID_FOR_PROFILE_CONTACT);//no contact id for 'ME' user
341
+ // todo - double check this, it may not be necessary any more
342
+ id = String.valueOf(ID_FOR_PROFILE_CONTACT);// no contact id for 'ME' user
340
343
  }
341
344
 
342
345
  if (columnIndexRawContactId != -1) {
343
346
  rawContactId = cursor.getString(columnIndexRawContactId);
344
347
  } else {
345
- //todo - double check this, it may not be necessary any more
346
- rawContactId = String.valueOf(ID_FOR_PROFILE_CONTACT);//no contact id for 'ME' user
348
+ // todo - double check this, it may not be necessary any more
349
+ rawContactId = String.valueOf(ID_FOR_PROFILE_CONTACT);// no contact id for 'ME' user
347
350
  }
348
351
 
349
352
  if (!map.containsKey(contactId)) {
@@ -369,7 +372,7 @@ public class ContactsProvider {
369
372
  }
370
373
  }
371
374
 
372
- switch(mimeType) {
375
+ switch (mimeType) {
373
376
  case StructuredName.CONTENT_ITEM_TYPE:
374
377
  contact.givenName = cursor.getString(cursor.getColumnIndex(StructuredName.GIVEN_NAME));
375
378
  if (cursor.getString(cursor.getColumnIndex(StructuredName.MIDDLE_NAME)) != null) {
@@ -390,22 +393,14 @@ public class ContactsProvider {
390
393
  int phoneType = cursor.getInt(cursor.getColumnIndex(Phone.TYPE));
391
394
 
392
395
  if (!TextUtils.isEmpty(phoneNumber)) {
393
- String label;
394
- switch (phoneType) {
395
- case Phone.TYPE_HOME:
396
- label = "home";
397
- break;
398
- case Phone.TYPE_WORK:
399
- label = "work";
400
- break;
401
- case Phone.TYPE_MOBILE:
402
- label = "mobile";
403
- break;
404
- case Phone.TYPE_OTHER:
405
- label = "other";
406
- break;
407
- default:
408
- label = "other";
396
+ final String label;
397
+ int labelIndex = cursor.getColumnIndex(ContactsContract.CommonDataKinds.Phone.LABEL);
398
+ if (labelIndex >= 0) {
399
+ String typeLabel = cursor.getString(labelIndex);
400
+ label = ContactsContract.CommonDataKinds.Phone
401
+ .getTypeLabel(Resources.getSystem(), phoneType, typeLabel).toString();
402
+ } else {
403
+ label = "other";
409
404
  }
410
405
  contact.phones.add(new Contact.Item(label, phoneNumber, id));
411
406
  }
@@ -536,7 +531,8 @@ public class ContactsProvider {
536
531
  int eventType = cursor.getInt(cursor.getColumnIndex(Event.TYPE));
537
532
  if (eventType == Event.TYPE_BIRTHDAY) {
538
533
  try {
539
- String birthday = cursor.getString(cursor.getColumnIndex(Event.START_DATE)).replace("--", "");
534
+ String birthday = cursor.getString(cursor.getColumnIndex(Event.START_DATE)).replace("--",
535
+ "");
540
536
  String[] yearMonthDay = birthday.split("-");
541
537
  List<String> yearMonthDayList = Arrays.asList(yearMonthDay);
542
538
 
@@ -577,9 +573,8 @@ public class ContactsProvider {
577
573
  ContactsContract.Data.CONTENT_URI,
578
574
  PHOTO_PROJECTION.toArray(new String[PHOTO_PROJECTION.size()]),
579
575
  ContactsContract.RawContacts.CONTACT_ID + " = ?",
580
- new String[]{contactId},
581
- null
582
- );
576
+ new String[] { contactId },
577
+ null);
583
578
  try {
584
579
  if (cursor != null && cursorMoveToNext(cursor)) {
585
580
  String rawPhotoURI = cursor.getString(cursor.getColumnIndex(Contactables.PHOTO_URI));
@@ -607,7 +602,7 @@ public class ContactsProvider {
607
602
  private String company = "";
608
603
  private String jobTitle = "";
609
604
  private String department = "";
610
- private String note ="";
605
+ private String note = "";
611
606
  private List<Item> urls = new ArrayList<>();
612
607
  private List<Item> instantMessengers = new ArrayList<>();
613
608
  private boolean hasPhoto = false;
@@ -618,7 +613,6 @@ public class ContactsProvider {
618
613
  private List<PostalAddressItem> postalAddresses = new ArrayList<>();
619
614
  private Birthday birthday;
620
615
 
621
-
622
616
  public Contact(String contactId) {
623
617
  this.contactId = contactId;
624
618
  }
@@ -1,38 +1,54 @@
1
1
  package com.rt2zz.reactnativecontacts;
2
2
 
3
3
  import androidx.annotation.NonNull;
4
+ import androidx.annotation.Nullable;
5
+
4
6
  import com.facebook.react.ReactPackage;
7
+ import com.facebook.react.TurboReactPackage;
5
8
  import com.facebook.react.bridge.NativeModule;
6
9
  import com.facebook.react.bridge.ReactApplicationContext;
10
+ import com.facebook.react.module.model.ReactModuleInfo;
11
+ import com.facebook.react.module.model.ReactModuleInfoProvider;
7
12
  import com.facebook.react.uimanager.ViewManager;
8
13
  import com.facebook.react.bridge.JavaScriptModule;
9
14
 
10
15
  import java.util.ArrayList;
11
16
  import java.util.Arrays;
12
17
  import java.util.Collections;
18
+ import java.util.HashMap;
13
19
  import java.util.List;
20
+ import java.util.Map;
14
21
 
15
- public class ReactNativeContacts implements ReactPackage {
22
+ public class ReactNativeContacts extends TurboReactPackage {
16
23
 
24
+ @Nullable
17
25
  @Override
18
- public List<NativeModule> createNativeModules(
19
- ReactApplicationContext reactContext) {
20
- List<NativeModule> modules = new ArrayList<>();
21
-
22
- modules.add(new ContactsManager(reactContext));
23
- return modules;
24
- }
25
-
26
- public List<Class<? extends JavaScriptModule>> createJSModules() {
27
- return Collections.emptyList();
26
+ public NativeModule getModule(@NonNull String name, @NonNull ReactApplicationContext reactContext) {
27
+ if (name.equals(ContactsProvider.NAME)) {
28
+ return new ContactsManager(reactContext);
29
+ } else {
30
+ return null;
31
+ }
28
32
  }
29
33
 
30
34
  @Override
31
- public List<ViewManager> createViewManagers(ReactApplicationContext reactContext) {
32
- return Arrays.<ViewManager>asList();
35
+ public ReactModuleInfoProvider getReactModuleInfoProvider() {
36
+ return () -> {
37
+ final Map<String, ReactModuleInfo> moduleInfos = new HashMap<>();
38
+ boolean isTurboModule = BuildConfig.IS_NEW_ARCHITECTURE_ENABLED;
39
+ moduleInfos.put(
40
+ ContactsProvider.NAME,
41
+ new ReactModuleInfo(
42
+ ContactsProvider.NAME,
43
+ ContactsProvider.NAME,
44
+ false, // canOverrideExistingModule
45
+ false, // needsEagerInit
46
+ true, // hasConstants
47
+ false, // isCxxModule
48
+ isTurboModule // isTurboModule
49
+ ));
50
+ return moduleInfos;
51
+ };
33
52
  }
34
53
 
35
- public static void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
36
- ContactsManager.onRequestPermissionsResult(requestCode, permissions, grantResults);
37
- }
38
54
  }