NativeScript / nativescript-imagepicker

Imagepicker plugin supporting both single and multiple selection.
Apache License 2.0
104 stars 74 forks source link

mediaType enum is not exported #285

Closed tgpetrov closed 5 years ago

tgpetrov commented 5 years ago

Make sure to check the demo app(s) for sample usage

Done

Make sure to check the existing issues in this repository

Done

If the demo apps cannot help and there is no issue for your problem, tell us about it

There is a ImagePickerMediaType enum that seems like it can be added to the demo app:

let context = imagepicker.create({ mode: "single", mediaType: imagepicker.ImagePickerMediaType.Image });

However when I run the app, it crashes withCannot read property 'Image' of undefined

Which platform(s) does your issue occur on?

Please, provide the following version numbers that your issue occurs with:

Please, tell us how to recreate the issue in as much detail as possible.

Go to demo app and replace this line:

let context = imagepicker.create({ mode: "single" });

with:

let context = imagepicker.create({ mode: "single", mediaType: imagepicker.ImagePickerMediaType.Image });

Run the app and tap the PICK SINGLE button.

expected: app to work same as before change actual: app crashes

zbranzov commented 5 years ago

The fix is published in nativescript-imagepicker@6.3.0