Git Product home page Git Product logo

isabella232 / cordova-plugin-ios-camera-permissions Goto Github PK

View Code? Open in Web Editor NEW

This project forked from experience-monks/cordova-plugin-ios-camera-permissions

0.0 0.0 0.0 7 KB

Cordova / PhoneGap Plugin Permission Settings for NSCameraUsageDescription and NSPhotoLibraryUsageDescription in iOS 10 by adding a declaration to the Info.plist file

Home Page: http://cordobo.com/2269-cordova-plugin-for-nscamerausagedescription-in-ios-10/

cordova-plugin-ios-camera-permissions's Introduction

iOS 10 Camera Permissions Plugin for Apache Cordova

Cordova / PhoneGap Plugin Permission Settings for NSCameraUsageDescription, NSPhotoLibraryUsageDescription and NSMicrophoneUsageDescription in iOS 10 by adding a declaration to the Info.plist file

Install

Latest published version on npm (with Cordova CLI >= 5.0.0)

cordova plugin add cordova-plugin-ios-camera-permissions --save

Latest version from GitHub

cordova plugin add https://github.com/Cordobo/cordova-plugin-ios-camera-permissions.git --save

Customising the message prompts

On installation you can customise the prompts shown by setting the following variables on installation.

  • CAMERA_USAGE_DESCRIPTION for NSCameraUsageDescription
  • MICROPHONE_USAGE_DESCRIPTION for NSMicrophoneUsageDescription
  • PHOTOLIBRARY_USAGE_DESCRIPTION for NSPhotoLibraryUsageDescriptionentry

For example:

cordova plugin add https://github.com/Cordobo/cordova-plugin-ios-camera-permissions.git --variable CAMERA_USAGE_DESCRIPTION="your usage message" --variable MICROPHONE_USAGE_DESCRIPTION="your microphone usage message here" --variable PHOTOLIBRARY_USAGE_DESCRIPTION="your photo library usage message here" --save

Usage

See http://cordobo.com/2269-cordova-plugin-for-nscamerausagedescription-in-ios-10/

For the changes to plugin.xml to take effect, you must refresh the ios.json file (inside the /plugin folder):

$ cordova platform rm ios
$ cordova platform add ios

Platforms

Applies to iOS (10+) only.

License

[MIT License]

cordova-plugin-ios-camera-permissions's People

Contributors

cordobo avatar gaetanmallet avatar jmannau avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.