Skip to content

Commit 067ef5d

Browse files
committed
Split constants and types from main file
1 parent ed00c89 commit 067ef5d

File tree

8 files changed

+355
-344
lines changed

8 files changed

+355
-344
lines changed

example/ios/Podfile.lock

Lines changed: 185 additions & 185 deletions
Large diffs are not rendered by default.

example/ios/RNPermissionsExample.xcodeproj/project.pbxproj

Lines changed: 35 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; };
1212
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
1313
13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
14-
FF61E46FEEB7199D22A548F5 /* libPods-RNPermissionsExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = D78CFB0B797068FC55B9C8C1 /* libPods-RNPermissionsExample.a */; };
14+
6875196781331FFE9E603F87 /* libPods-RNPermissionsExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = DD155AF45729590903A0B306 /* libPods-RNPermissionsExample.a */; };
1515
/* End PBXBuildFile section */
1616

1717
/* Begin PBXFileReference section */
@@ -23,9 +23,9 @@
2323
13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = RNPermissionsExample/Images.xcassets; sourceTree = "<group>"; };
2424
13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = RNPermissionsExample/Info.plist; sourceTree = "<group>"; };
2525
13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = RNPermissionsExample/main.m; sourceTree = "<group>"; };
26-
6508191B9B16B2AC0281B3AC /* Pods-RNPermissionsExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNPermissionsExample.release.xcconfig"; path = "Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample.release.xcconfig"; sourceTree = "<group>"; };
27-
B6736F72654167EDBA7145AA /* Pods-RNPermissionsExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNPermissionsExample.debug.xcconfig"; path = "Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample.debug.xcconfig"; sourceTree = "<group>"; };
28-
D78CFB0B797068FC55B9C8C1 /* libPods-RNPermissionsExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RNPermissionsExample.a"; sourceTree = BUILT_PRODUCTS_DIR; };
26+
AEA89E08943D1AC580FE431E /* Pods-RNPermissionsExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNPermissionsExample.release.xcconfig"; path = "Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample.release.xcconfig"; sourceTree = "<group>"; };
27+
D6698846DE1278CE89BAFBAD /* Pods-RNPermissionsExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNPermissionsExample.debug.xcconfig"; path = "Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample.debug.xcconfig"; sourceTree = "<group>"; };
28+
DD155AF45729590903A0B306 /* libPods-RNPermissionsExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RNPermissionsExample.a"; sourceTree = BUILT_PRODUCTS_DIR; };
2929
ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
3030
ED2971642150620600B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = Platforms/AppleTVOS.platform/Developer/SDKs/AppleTVOS12.0.sdk/System/Library/Frameworks/JavaScriptCore.framework; sourceTree = DEVELOPER_DIR; };
3131
/* End PBXFileReference section */
@@ -35,7 +35,7 @@
3535
isa = PBXFrameworksBuildPhase;
3636
buildActionMask = 2147483647;
3737
files = (
38-
FF61E46FEEB7199D22A548F5 /* libPods-RNPermissionsExample.a in Frameworks */,
38+
6875196781331FFE9E603F87 /* libPods-RNPermissionsExample.a in Frameworks */,
3939
);
4040
runOnlyForDeploymentPostprocessing = 0;
4141
};
@@ -59,8 +59,8 @@
5959
2426786032D9E4653AC74A82 /* Pods */ = {
6060
isa = PBXGroup;
6161
children = (
62-
B6736F72654167EDBA7145AA /* Pods-RNPermissionsExample.debug.xcconfig */,
63-
6508191B9B16B2AC0281B3AC /* Pods-RNPermissionsExample.release.xcconfig */,
62+
D6698846DE1278CE89BAFBAD /* Pods-RNPermissionsExample.debug.xcconfig */,
63+
AEA89E08943D1AC580FE431E /* Pods-RNPermissionsExample.release.xcconfig */,
6464
);
6565
path = Pods;
6666
sourceTree = "<group>";
@@ -70,7 +70,7 @@
7070
children = (
7171
ED297162215061F000B7C4FE /* JavaScriptCore.framework */,
7272
ED2971642150620600B7C4FE /* JavaScriptCore.framework */,
73-
D78CFB0B797068FC55B9C8C1 /* libPods-RNPermissionsExample.a */,
73+
DD155AF45729590903A0B306 /* libPods-RNPermissionsExample.a */,
7474
);
7575
name = Frameworks;
7676
sourceTree = "<group>";
@@ -103,13 +103,13 @@
103103
isa = PBXNativeTarget;
104104
buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "RNPermissionsExample" */;
105105
buildPhases = (
106-
B8E3F604061BE0BB6353585E /* [CP] Check Pods Manifest.lock */,
106+
5CBE311E157ACE2DB1514386 /* [CP] Check Pods Manifest.lock */,
107107
FD10A7F022414F080027D42C /* Start Packager */,
108108
13B07F871A680F5B00A75B9A /* Sources */,
109109
13B07F8C1A680F5B00A75B9A /* Frameworks */,
110110
13B07F8E1A680F5B00A75B9A /* Resources */,
111111
00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
112-
B87A842ED79307A87D526EC5 /* [CP] Copy Pods Resources */,
112+
7BFDA05E75F4BA8ABC64EEC3 /* [CP] Copy Pods Resources */,
113113
);
114114
buildRules = (
115115
);
@@ -180,7 +180,29 @@
180180
shellPath = /bin/sh;
181181
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
182182
};
183-
B87A842ED79307A87D526EC5 /* [CP] Copy Pods Resources */ = {
183+
5CBE311E157ACE2DB1514386 /* [CP] Check Pods Manifest.lock */ = {
184+
isa = PBXShellScriptBuildPhase;
185+
buildActionMask = 2147483647;
186+
files = (
187+
);
188+
inputFileListPaths = (
189+
);
190+
inputPaths = (
191+
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
192+
"${PODS_ROOT}/Manifest.lock",
193+
);
194+
name = "[CP] Check Pods Manifest.lock";
195+
outputFileListPaths = (
196+
);
197+
outputPaths = (
198+
"$(DERIVED_FILE_DIR)/Pods-RNPermissionsExample-checkManifestLockResult.txt",
199+
);
200+
runOnlyForDeploymentPostprocessing = 0;
201+
shellPath = /bin/sh;
202+
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
203+
showEnvVarsInLog = 0;
204+
};
205+
7BFDA05E75F4BA8ABC64EEC3 /* [CP] Copy Pods Resources */ = {
184206
isa = PBXShellScriptBuildPhase;
185207
buildActionMask = 2147483647;
186208
files = (
@@ -228,28 +250,6 @@
228250
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-RNPermissionsExample/Pods-RNPermissionsExample-resources.sh\"\n";
229251
showEnvVarsInLog = 0;
230252
};
231-
B8E3F604061BE0BB6353585E /* [CP] Check Pods Manifest.lock */ = {
232-
isa = PBXShellScriptBuildPhase;
233-
buildActionMask = 2147483647;
234-
files = (
235-
);
236-
inputFileListPaths = (
237-
);
238-
inputPaths = (
239-
"${PODS_PODFILE_DIR_PATH}/Podfile.lock",
240-
"${PODS_ROOT}/Manifest.lock",
241-
);
242-
name = "[CP] Check Pods Manifest.lock";
243-
outputFileListPaths = (
244-
);
245-
outputPaths = (
246-
"$(DERIVED_FILE_DIR)/Pods-RNPermissionsExample-checkManifestLockResult.txt",
247-
);
248-
runOnlyForDeploymentPostprocessing = 0;
249-
shellPath = /bin/sh;
250-
shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
251-
showEnvVarsInLog = 0;
252-
};
253253
FD10A7F022414F080027D42C /* Start Packager */ = {
254254
isa = PBXShellScriptBuildPhase;
255255
buildActionMask = 2147483647;
@@ -298,7 +298,7 @@
298298
/* Begin XCBuildConfiguration section */
299299
13B07F941A680F5B00A75B9A /* Debug */ = {
300300
isa = XCBuildConfiguration;
301-
baseConfigurationReference = B6736F72654167EDBA7145AA /* Pods-RNPermissionsExample.debug.xcconfig */;
301+
baseConfigurationReference = D6698846DE1278CE89BAFBAD /* Pods-RNPermissionsExample.debug.xcconfig */;
302302
buildSettings = {
303303
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
304304
CURRENT_PROJECT_VERSION = 1;
@@ -319,7 +319,7 @@
319319
};
320320
13B07F951A680F5B00A75B9A /* Release */ = {
321321
isa = XCBuildConfiguration;
322-
baseConfigurationReference = 6508191B9B16B2AC0281B3AC /* Pods-RNPermissionsExample.release.xcconfig */;
322+
baseConfigurationReference = AEA89E08943D1AC580FE431E /* Pods-RNPermissionsExample.release.xcconfig */;
323323
buildSettings = {
324324
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
325325
CURRENT_PROJECT_VERSION = 1;

example/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
},
1313
"dependencies": {
1414
"react": "16.9.0",
15-
"react-native": "0.61.1",
15+
"react-native": "0.61.2",
1616
"react-native-paper": "2.16.0",
1717
"react-native-permissions": "../",
1818
"react-native-vector-icons": "6.6.0"

example/yarn.lock

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -847,7 +847,15 @@
847847
"@types/prop-types" "*"
848848
"@types/react" "*"
849849

850-
"@types/react@*", "@types/[email protected]":
850+
"@types/react@*":
851+
version "16.9.4"
852+
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.4.tgz#de8cf5e5e2838659fb78fa93181078469eeb19fc"
853+
integrity sha512-ItGNmJvQ0IvWt8rbk5PLdpdQhvBVxAaXI9hDlx7UMd8Ie1iMIuwMNiKeTfmVN517CdplpyXvA22X4zm4jGGZnw==
854+
dependencies:
855+
"@types/prop-types" "*"
856+
csstype "^2.2.0"
857+
858+
851859
version "16.9.3"
852860
resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.3.tgz#6d13251e441a3e67fb60d719d1fc8785b984a2ec"
853861
integrity sha512-Ogb2nSn+2qQv5opoCv7Ls5yFxtyrdUYxp5G+SWTrlGk7dmFKw331GiezCgEZj9U7QeXJi1CDtws9pdXU1zUL4g==
@@ -1165,9 +1173,9 @@ basic-auth@~2.0.0:
11651173
safe-buffer "5.1.2"
11661174

11671175
big-integer@^1.6.7:
1168-
version "1.6.45"
1169-
resolved "https://registry.yarnpkg.com/big-integer/-/big-integer-1.6.45.tgz#1bf2fa1271bfd20d4c52c3d6c6f08cab8d91c77e"
1170-
integrity sha512-nmb9E7oEtVJ7SmSCH/DeJobXyuRmaofkpoQSimMFu3HKJ5MADtM825SPLhDuWhZ6TElLAQtgJbQmBZuHIRlZoA==
1176+
version "1.6.46"
1177+
resolved "https://registry.yarnpkg.com/big-integer/-/big-integer-1.6.46.tgz#e18a75f0515be0f3ad10c0d110e37fa882b3f223"
1178+
integrity sha512-Vj2TNtZ8Y0XaL6HCkzJiEqfykjtv/9wVCWIutMe+QVIXLPe2tCLEzULtYvcX9WRtmNIj3Jqi5tNjIsR0N4QOsg==
11711179

11721180
binary-extensions@^1.0.0:
11731181
version "1.13.1"
@@ -1449,9 +1457,9 @@ colorette@^1.0.7:
14491457
integrity sha512-6S062WDQUXi6hOfkO/sBPVwE5ASXY4G2+b4atvhJfSsuUUhIaUKlkjLe9692Ipyt5/a+IPF5aVTu3V5gvXq5cg==
14501458

14511459
commander@^2.19.0:
1452-
version "2.20.0"
1453-
resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422"
1454-
integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==
1460+
version "2.20.1"
1461+
resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.1.tgz#3863ce3ca92d0831dcf2a102f5fb4b5926afd0f9"
1462+
integrity sha512-cCuLsMhJeWQ/ZpsFTbE765kvVfoeSddc4nU3up4fV+fDBcfUXnbITJ+JzhkdjzOqhURjZgujxaioam4RM9yGUg==
14551463

14561464
commander@~2.13.0:
14571465
version "2.13.0"
@@ -2648,9 +2656,9 @@ json-stable-stringify@^1.0.1:
26482656
jsonify "~0.0.0"
26492657

26502658
json5@^2.1.0:
2651-
version "2.1.0"
2652-
resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.0.tgz#e7a0c62c48285c628d20a10b85c89bb807c32850"
2653-
integrity sha512-8Mh9h6xViijj36g7Dxi+Y4S6hNGV96vcJZr/SrlHh1LR/pEn/8j/+qIBbs44YKl69Lrfctp4QD+AdWLTMqEZAQ==
2659+
version "2.1.1"
2660+
resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.1.tgz#81b6cb04e9ba496f1c7005d07b4368a2638f90b6"
2661+
integrity sha512-l+3HXD0GEI3huGq1njuqtzYK8OYJyXMkOLtQ53pjWh89tvWS2h6l+1zMkYWqlb57+SiQodKZyvMEFb2X+KrFhQ==
26542662
dependencies:
26552663
minimist "^1.2.0"
26562664

@@ -3167,15 +3175,7 @@ minimist@^1.1.1, minimist@^1.2.0:
31673175
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284"
31683176
integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=
31693177

3170-
minipass@^2.6.0, minipass@^2.8.6:
3171-
version "2.8.6"
3172-
resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.8.6.tgz#620d889ace26356391d010ecb9458749df9b6db5"
3173-
integrity sha512-lFG7d6g3+/UaFDCOtqPiKAC9zngWWsQZl1g5q6gaONqrjq61SX2xFqXMleQiFVyDpYwa018E9hmlAFY22PCb+A==
3174-
dependencies:
3175-
safe-buffer "^5.1.2"
3176-
yallist "^3.0.0"
3177-
3178-
minipass@^2.9.0:
3178+
minipass@^2.6.0, minipass@^2.8.6, minipass@^2.9.0:
31793179
version "2.9.0"
31803180
resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.9.0.tgz#e713762e7d3e32fed803115cf93e04bca9fcc9a6"
31813181
integrity sha512-wxfUjg9WebH+CUDX/CdbRlh5SmfZiy/hpkxaRI16Y9W56Pa75sWgd/rvFilSgrauD9NyFymP/+JFV3KwzIsJeg==
@@ -3184,9 +3184,9 @@ minipass@^2.9.0:
31843184
yallist "^3.0.0"
31853185

31863186
minizlib@^1.2.1:
3187-
version "1.3.2"
3188-
resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.3.2.tgz#5d24764998f98112586f7e566bd4c0999769dad4"
3189-
integrity sha512-lsNFqSHdJ21EwKzCp12HHJGxSMtHkCW1EMA9cceG3MkMNARjuWotZnMe3NKNshAvFXpm4loZqmYsCmRwhS2JMw==
3187+
version "1.3.3"
3188+
resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.3.3.tgz#2290de96818a34c29551c8a8d301216bd65a861d"
3189+
integrity sha512-6ZYMOEnmVsdCeTJVE0W9ZD+pVnE8h9Hma/iOwwRDsdQoePpoX56/8B6z3P9VNwppJuBKNRuFDRNRqRWexT9G9Q==
31903190
dependencies:
31913191
minipass "^2.9.0"
31923192

@@ -3768,9 +3768,9 @@ react-devtools-core@^3.6.3:
37683768
ws "^3.3.1"
37693769

37703770
react-is@^16.7.0, react-is@^16.8.1, react-is@^16.8.4:
3771-
version "16.10.0"
3772-
resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.10.0.tgz#3d6a031e57fff73c3cfa0347feb3e8f40c5141e5"
3773-
integrity sha512-WRki2sBb7MTpYp7FtDEmSeGKX2vamYyq3rc9o7fKUG+/DHVyJu69NnvJsiSwwhh2Tt8XN40MQHkDBEXwyfxncQ==
3771+
version "16.10.1"
3772+
resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.10.1.tgz#0612786bf19df406502d935494f0450b40b8294f"
3773+
integrity sha512-BXUMf9sIOPXXZWqr7+c5SeOKJykyVr2u0UDzEf4LNGc6taGkQe1A9DFD07umCIXz45RLr9oAAwZbAJ0Pkknfaw==
37743774

37753775
react-lifecycles-compat@^3.0.4:
37763776
version "3.0.4"
@@ -3790,7 +3790,7 @@ [email protected]:
37903790
react-native-safe-area-view "^0.12.0"
37913791

37923792
react-native-permissions@../:
3793-
version "2.0.0"
3793+
version "2.0.1"
37943794

37953795
react-native-safe-area-view@^0.12.0:
37963796
version "0.12.0"
@@ -3808,10 +3808,10 @@ [email protected]:
38083808
prop-types "^15.6.2"
38093809
yargs "^13.2.2"
38103810

3811-
3812-
version "0.61.1"
3813-
resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.61.1.tgz#ac2559f78f9e689356fedfa93159026a25313d7d"
3814-
integrity sha512-FjOhAgzjrPr2BjBITmCY+SHzWxfP/bv5ve3oN6ItoIPsVPjJG2QZE8yeByVdI4TzaZrGHU4Ag7/7hX4j39cj2Q==
3811+
3812+
version "0.61.2"
3813+
resolved "https://registry.yarnpkg.com/react-native/-/react-native-0.61.2.tgz#987b91b063557f8ebec803fdfea2044a24bdbe4d"
3814+
integrity sha512-hhd8bYbkkZYHoOndxUwbjJ6Yd9HFn5PvwqqS41uJ1xADdw44rx/svuwmJNA1RKF7jH74uR2jpBViWYGd36zGyg==
38153815
dependencies:
38163816
"@babel/runtime" "^7.0.0"
38173817
"@react-native-community/cli" "^3.0.0-alpha.1"
@@ -4841,9 +4841,9 @@ yallist@^2.1.2:
48414841
integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=
48424842

48434843
yallist@^3.0.0, yallist@^3.0.3:
4844-
version "3.1.0"
4845-
resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.0.tgz#906cc2100972dc2625ae78f566a2577230a1d6f7"
4846-
integrity sha512-6gpP93MR+VOOehKbCPchro3wFZNSNmek8A2kbkOAZLIZAYx1KP/zAqwO0sOHi3xJEb+UBz8NaYt/17UNit1Q9w==
4844+
version "3.1.1"
4845+
resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd"
4846+
integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==
48474847

48484848
yargs-parser@^11.1.1:
48494849
version "11.1.1"

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-native-permissions",
3-
"version": "2.0.0",
3+
"version": "2.0.1",
44
"license": "MIT",
55
"description": "An unified permissions API for React Native on iOS and Android",
66
"author": "Mathieu Acthernoene <[email protected]>",

src/constants.ts

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
export const ANDROID = Object.freeze({
2+
ACCEPT_HANDOVER: 'android.permission.ACCEPT_HANDOVER' as const,
3+
ACCESS_BACKGROUND_LOCATION: 'android.permission.ACCESS_BACKGROUND_LOCATION' as const,
4+
ACCESS_COARSE_LOCATION: 'android.permission.ACCESS_COARSE_LOCATION' as const,
5+
ACCESS_FINE_LOCATION: 'android.permission.ACCESS_FINE_LOCATION' as const,
6+
ACTIVITY_RECOGNITION: 'android.permission.ACTIVITY_RECOGNITION' as const,
7+
ADD_VOICEMAIL: 'com.android.voicemail.permission.ADD_VOICEMAIL' as const,
8+
ANSWER_PHONE_CALLS: 'android.permission.ANSWER_PHONE_CALLS' as const,
9+
BODY_SENSORS: 'android.permission.BODY_SENSORS' as const,
10+
CALL_PHONE: 'android.permission.CALL_PHONE' as const,
11+
CAMERA: 'android.permission.CAMERA' as const,
12+
GET_ACCOUNTS: 'android.permission.GET_ACCOUNTS' as const,
13+
PROCESS_OUTGOING_CALLS: 'android.permission.PROCESS_OUTGOING_CALLS' as const,
14+
READ_CALENDAR: 'android.permission.READ_CALENDAR' as const,
15+
READ_CALL_LOG: 'android.permission.READ_CALL_LOG' as const,
16+
READ_CONTACTS: 'android.permission.READ_CONTACTS' as const,
17+
READ_EXTERNAL_STORAGE: 'android.permission.READ_EXTERNAL_STORAGE' as const,
18+
READ_PHONE_NUMBERS: 'android.permission.READ_PHONE_NUMBERS' as const,
19+
READ_PHONE_STATE: 'android.permission.READ_PHONE_STATE' as const,
20+
READ_SMS: 'android.permission.READ_SMS' as const,
21+
RECEIVE_MMS: 'android.permission.RECEIVE_MMS' as const,
22+
RECEIVE_SMS: 'android.permission.RECEIVE_SMS' as const,
23+
RECEIVE_WAP_PUSH: 'android.permission.RECEIVE_WAP_PUSH' as const,
24+
RECORD_AUDIO: 'android.permission.RECORD_AUDIO' as const,
25+
SEND_SMS: 'android.permission.SEND_SMS' as const,
26+
USE_SIP: 'android.permission.USE_SIP' as const,
27+
WRITE_CALENDAR: 'android.permission.WRITE_CALENDAR' as const,
28+
WRITE_CALL_LOG: 'android.permission.WRITE_CALL_LOG' as const,
29+
WRITE_CONTACTS: 'android.permission.WRITE_CONTACTS' as const,
30+
WRITE_EXTERNAL_STORAGE: 'android.permission.WRITE_EXTERNAL_STORAGE' as const,
31+
});
32+
33+
export const IOS = Object.freeze({
34+
BLUETOOTH_PERIPHERAL: 'ios.permission.BLUETOOTH_PERIPHERAL' as const,
35+
CALENDARS: 'ios.permission.CALENDARS' as const,
36+
CAMERA: 'ios.permission.CAMERA' as const,
37+
CONTACTS: 'ios.permission.CONTACTS' as const,
38+
FACE_ID: 'ios.permission.FACE_ID' as const,
39+
LOCATION_ALWAYS: 'ios.permission.LOCATION_ALWAYS' as const,
40+
LOCATION_WHEN_IN_USE: 'ios.permission.LOCATION_WHEN_IN_USE' as const,
41+
MEDIA_LIBRARY: 'ios.permission.MEDIA_LIBRARY' as const,
42+
MICROPHONE: 'ios.permission.MICROPHONE' as const,
43+
MOTION: 'ios.permission.MOTION' as const,
44+
PHOTO_LIBRARY: 'ios.permission.PHOTO_LIBRARY' as const,
45+
REMINDERS: 'ios.permission.REMINDERS' as const,
46+
SIRI: 'ios.permission.SIRI' as const,
47+
SPEECH_RECOGNITION: 'ios.permission.SPEECH_RECOGNITION' as const,
48+
STOREKIT: 'ios.permission.STOREKIT' as const,
49+
});
50+
51+
export const PERMISSIONS = Object.freeze({ANDROID, IOS});
52+
53+
export const RESULTS = Object.freeze({
54+
UNAVAILABLE: 'unavailable' as const,
55+
DENIED: 'denied' as const,
56+
BLOCKED: 'blocked' as const,
57+
GRANTED: 'granted' as const,
58+
});

0 commit comments

Comments
 (0)