@remobile/react-native-image-picker
Advanced tools
Comparing version 1.0.5 to 1.0.6
25
index.js
'use strict'; | ||
var ReactNative = require('react-native'); | ||
var { | ||
NativeModules | ||
const ReactNative = require('react-native'); | ||
const { | ||
NativeModules, | ||
} = ReactNative; | ||
var RCTImagePicker = NativeModules.ImagePicker; | ||
const RCTImagePicker = NativeModules.ImagePicker; | ||
var ImagePicker = { | ||
getPictures:function(options, successCallback, errorCallback) { | ||
options = options||{}; | ||
successCallback = successCallback || (()=>{}); | ||
errorCallback = errorCallback || (()=>{}); | ||
var params = { | ||
const ImagePicker = { | ||
getPictures:function (options, successCallback, errorCallback) { | ||
options = options || {}; | ||
successCallback = successCallback || (() => {}); | ||
errorCallback = errorCallback || (() => {}); | ||
const params = { | ||
maximumImagesCount: options.maximumImagesCount ? options.maximumImagesCount : 15, | ||
width: options.width ? options.width : 0, | ||
height: options.height ? options.height : 0, | ||
quality: options.quality ? options.quality : 100 | ||
quality: options.quality ? options.quality : 100, | ||
}; | ||
RCTImagePicker.getPictures([params], successCallback, errorCallback); | ||
} | ||
}, | ||
}; | ||
module.exports = ImagePicker; |
{ | ||
"name": "@remobile/react-native-image-picker", | ||
"version": "1.0.5", | ||
"version": "1.0.6", | ||
"description": "A image picker for react-native, support for ios and android", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
170043
43