Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Camera.getPhoto@capacitor/camera documentation 📸 #607

Closed
rpavez opened this issue Sep 15, 2021 · 3 comments · Fixed by #608
Closed

Improve Camera.getPhoto@capacitor/camera documentation 📸 #607

rpavez opened this issue Sep 15, 2021 · 3 comments · Fixed by #608

Comments

@rpavez
Copy link

rpavez commented Sep 15, 2021

Improve documentation Request

Plugin

@ionic/camera - Camera.getPhoto()

Description

Spent a lot of time trying to figure out how to trigger the native camera and it wasn't until read through the source code and w3c input file specs that understood how use make Camera.getPhoto() to just trigger the native camera.

Platform(s)

web

Preferred Solution

Improve documentation (https://github.com/ionic-team/capacitor-plugins/tree/main/camera#imageoptions) to clearly explain that prop source should be anything but CameraSource.Photos || CameraSource.Prompt to trigger the native camera (and not select from library) by using capture when using webUseInput: true. This is a non-documented behavior that can only be discovered by reading through the code here https://github.com/ionic-team/capacitor-plugins/blob/main/camera/src/web.ts#L146

@jcesarmobile
Copy link
Member

Photos I thought CameraSource.Camera was clear enough to describe that it uses the camera, while CameraSource.Photos will let you pick an existing photo and CameraSource.Prompt will prompt you with both options, but will add little descriptions for each.

@rpavez
Copy link
Author

rpavez commented Sep 15, 2021 via email

@ionitron-bot
Copy link

ionitron-bot bot commented Sep 30, 2022

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of the plugin, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Sep 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants