photo
photo is a juci widget built for taking or choosing photos from the device using $m APIs in a user friendly and easy manner. Tapping on the container pops up a confirm dialog to choose or take picture from the device.
Syntax
<div data-juci="photo" data-label="Photo"></div>
<div data-juci="photo" data-label="Databound" data-bind="ref: photo" data-uri="true"></div>
Requires mowbly to be loaded.
Attributes
Events
-
cancel(eventObj) ¶Fires when the user has cancelled choosing or taking a picture. Can be used to update user interface.Parameters:
-
eventObj{EventObject}
-
img{juci.elem}
The image element on which the picture is loaded.
-
img{juci.elem}
-
eventObj{EventObject}
-
finish(eventObj) ¶Fires after the user has chosen or taken a picture successfully. Can be used to update user interface.Parameters:
-
eventObj{EventObject}
-
img{juci.elem}
The image element on which the picture is loaded.
-
img{juci.elem}
-
eventObj{EventObject}
-
photoerror(eventObj) ¶Fires when the chosen picture is loaded with errors in the photo control.Parameters:
-
eventObj{EventObject}
-
img{juci.elem}
The image element on which the picture is loaded.
-
img{juci.elem}
-
eventObj{EventObject}
-
photoload(eventObj) ¶Fires when the chosen picture is loaded successfully in the photo control.Parameters:
-
eventObj{EventObject}
-
img{juci.elem}
The image element on which the picture is loaded.
-
img{juci.elem}
-
eventObj{EventObject}
-
photooptions(eventObj) ¶Fires before the user is directed to the camera or a gallery.Parameters:
-
eventObj{EventObject}
-
options{Object}
The configuration for $m.choosePic() and $m.capturePic().
-
options{Object}
-
eventObj{EventObject}
-
start(eventObj) ¶Fires when the user taps on the control to start choosing or taking a picture. Can be used to update user interface.Parameters:
-
eventObj{EventObject}
-
img{juci.elem}
The image element on which the picture is loaded.
-
img{juci.elem}
-
eventObj{EventObject}