You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/@awesome-cordova-plugins/plugins/diagnostic/index.ts
+41-8Lines changed: 41 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -153,6 +153,18 @@ export class Diagnostic extends AwesomeCordovaNativePlugin {
153
153
UNKNOWN: string;
154
154
};
155
155
156
+
/**
157
+
* Access to the photo library (iOS 14+)
158
+
*
159
+
* ADD_ONLY - can add to but not read from Photo Library
160
+
* READ_WRITE - can both add to and read from Photo Library
161
+
*
162
+
*/
163
+
photoLibraryAccessLevel={
164
+
ADD_ONLY: 'add_only',
165
+
READ_WRITE: 'read_write',
166
+
};
167
+
156
168
/**
157
169
* Checks if app is able to access device location.
158
170
*
@@ -814,20 +826,34 @@ export class Diagnostic extends AwesomeCordovaNativePlugin {
814
826
/**
815
827
* Checks if the application is authorized to use the Camera Roll in Photos app.
816
828
*
829
+
* @param accessLevel - (optional) On iOS 14+, specifies the level of access to the photo library to query as a constant in cordova.plugins.diagnostic.photoLibraryAccessLevel`
830
+
* Possible values are:
831
+
* ADD_ONLY - can add to but not read from Photo Library
832
+
* READ_WRITE - can both add to and read from Photo Library
* Returns the authorization status for the application to use the Camera Roll in Photos app.
826
845
*
846
+
* @param accessLevel - (optional) On iOS 14+, specifies the level of access to the photo library to query as a constant in cordova.plugins.diagnostic.photoLibraryAccessLevel`
847
+
* Possible values are:
848
+
* ADD_ONLY - can add to but not read from Photo Library
849
+
* READ_WRITE - can both add to and read from Photo Library
@@ -836,10 +862,17 @@ export class Diagnostic extends AwesomeCordovaNativePlugin {
836
862
* Should only be called if authorization status is NOT_REQUESTED.
837
863
* Calling it when in any other state will have no effect.
838
864
*
865
+
* @param accessLevel - (optional) On iOS 14+, specifies the level of access to the photo library to query as a constant in cordova.plugins.diagnostic.photoLibraryAccessLevel`
866
+
* Possible values are:
867
+
* ADD_ONLY - can add to but not read from Photo Library
868
+
* READ_WRITE - can both add to and read from Photo Library
@@ -1006,13 +1039,13 @@ export class Diagnostic extends AwesomeCordovaNativePlugin {
1006
1039
}
1007
1040
1008
1041
/**
1009
-
* Returns the location accuracy authorization for the application on iOS 14+. Note: calling on iOS <14 will result in the Promise being rejected.
1042
+
* Returns the location accuracy authorization for the application on iOS 14+ and Android 12+. Note: calling on iOS <14 or Android <12 will always return cordova.plugins.diagnostic.locationAccuracyAuthorization.FULL
1010
1043
*
1011
1044
* Learn more about this method [here](https://github.com/dpa99c/cordova-diagnostic-plugin#getlocationaccuracyauthorization)
0 commit comments