mirror of
https://github.com/apache/cordova-plugin-camera.git
synced 2025-01-19 03:42:52 +08:00
CB-11661: (ios) Add mandatory iOS 10 privacy description
This commit is contained in:
parent
c98607c613
commit
a3af38ad5b
10
README.md
10
README.md
@ -50,6 +50,16 @@ It is also possible to install via repo url directly ( unstable )
|
||||
|
||||
cordova plugin add https://github.com/apache/cordova-plugin-camera.git
|
||||
|
||||
### iOS Quirks
|
||||
|
||||
Since iOS 10 it's mandatory to add a `NSCameraUsageDescription` entry in the info.plist.
|
||||
|
||||
`NSCameraUsageDescription` describes the reason that the app accesses the user’s camera. When the system prompts the user to allow access, this string is displayed as part of the dialog box. To add this entry you can pass the variable `CAMERA_USAGE_DESCRIPTION` on plugin install.
|
||||
|
||||
Example:
|
||||
`cordova plugin add cordova-plugin-camera --variable CAMERA_USAGE_DESCRIPTION="your usage message"`
|
||||
|
||||
If you don't pass the variable, the plugin will add an empty string as value.
|
||||
|
||||
## How to Contribute
|
||||
|
||||
|
@ -150,6 +150,11 @@
|
||||
<framework src="CoreGraphics.framework" />
|
||||
<framework src="AVFoundation.framework" />
|
||||
|
||||
<preference name="CAMERA_USAGE_DESCRIPTION" default=" " />
|
||||
<config-file target="*-Info.plist" parent="NSCameraUsageDescription">
|
||||
<string>$CAMERA_USAGE_DESCRIPTION</string>
|
||||
</config-file>
|
||||
|
||||
<config-file target="*-Info.plist" parent="NSLocationWhenInUseUsageDescription">
|
||||
<string></string>
|
||||
</config-file>
|
||||
|
Loading…
Reference in New Issue
Block a user