react-native-contacts 8.0.7 → 8.0.8

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/index.d.ts CHANGED
@@ -24,10 +24,10 @@ export function getContactsByEmailAddress(
24
24
  emailAddress: string
25
25
  ): Promise<Contact[]>;
26
26
  export function checkPermission(): Promise<
27
- "authorized" | "denied" | "undefined"
27
+ "authorized" | "denied" | "undefined" | "limited"
28
28
  >;
29
29
  export function requestPermission(): Promise<
30
- "authorized" | "denied" | "undefined"
30
+ "authorized" | "denied" | "undefined" | "limited"
31
31
  >;
32
32
  export function writePhotoToPath(
33
33
  contactId: string,
@@ -63,7 +63,7 @@ RCT_EXPORT_METHOD(checkPermission:(RCTPromiseResolveBlock)resolve
63
63
  } else if (authStatus == CNAuthorizationStatusAuthorized) {
64
64
  resolve(@"authorized");
65
65
  } else if (@available(iOS 18, *)) {
66
- if (authStatus == CNAuthorizationStatusRestricted) {
66
+ if (authStatus == CNAuthorizationStatusLimited) {
67
67
  resolve(@"limited");
68
68
  } else {
69
69
  resolve(@"undefined");
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "type": "git",
5
5
  "url": "https://github.com/rt2zz/react-native-contacts.git"
6
6
  },
7
- "version": "8.0.7",
7
+ "version": "8.0.8",
8
8
  "description": "React Native Contacts (android & ios)",
9
9
  "nativePackage": true,
10
10
  "keywords": [
@@ -22,20 +22,20 @@ export interface Spec extends TurboModule {
22
22
  requestPermission: () => Promise<PermissionType>;
23
23
  writePhotoToPath: (contactId: string, file: string) => Promise<boolean>;
24
24
  iosEnableNotesUsage: (enabled: boolean) => void;
25
- getGroups(): Promise<Group[]>;
26
- getGroup: (identifier: string) => Promise<Group | null>;
27
- deleteGroup(identifier: string): Promise<boolean>;
28
- updateGroup(identifier: string, groupData: Object): Promise<Group>;
29
- addGroup(group: Object): Promise<Group>;
30
- contactsInGroup(identifier: string): Promise<Contact[]>;
31
- addContactsToGroup(
25
+ getGroups?: () => Promise<Group[]>;
26
+ getGroup?: (identifier: string) => Promise<Group | null>;
27
+ deleteGroup?: (identifier: string) => Promise<boolean>;
28
+ updateGroup?: (identifier: string, groupData: Object) => Promise<Group>;
29
+ addGroup?: (group: Object) => Promise<Group>;
30
+ contactsInGroup?: (identifier: string) => Promise<Contact[]>;
31
+ addContactsToGroup?: (
32
32
  groupIdentifier: string,
33
33
  contactIdentifiers: string[]
34
- ): Promise<boolean>;
35
- removeContactsFromGroup(
34
+ ) => Promise<boolean>;
35
+ removeContactsFromGroup?: (
36
36
  groupIdentifier: string,
37
37
  contactIdentifiers: string[]
38
- ): Promise<boolean>;
38
+ ) => Promise<boolean>;
39
39
  }
40
40
 
41
41
  export default TurboModuleRegistry.get<Spec>("RCTContacts");
package/.tool-versions DELETED
@@ -1 +0,0 @@
1
- nodejs 22.15.0