weexpack plugin add nat-media-image
options
(Object)limit
(Int) (default:1
)width
(Int)height
(Int)showCamera
(Boolean) (default:false
)
- [
callback
] (Function)
result
(Object)paths
(Array)
Nat.image.pick({
limit: 3,
showCamera: false
}, (err, ret) => {
console.log(ret.paths)
})
urls
(String | Array)- [
options
] (Object)current
(Int) (index)style
(String) (dots
|label
|none
, default:dots
)
- [
callback
] (Function)
Nat.image.preview('http://cdn.instapp.io/nat/samples/01.jpeg')
Nat.image.preview([
'http://cdn.instapp.io/nat/samples/01.jpeg',
'http://cdn.instapp.io/nat/samples/02.jpeg'
], {
current: 1,
style: 'none'
})
url
(String)- [
callback
] (Function)
result
(Object)width
(Int)height
(Int)
Nat.image.info('http://cdn.instapp.io/nat/samples/01.jpeg', (err, ret) => {
console.log(ret)
})
url
(String)- [
callback
] (Function)
result
(Object) (Exif Info)
Nat.image.exif('http://cdn.instapp.io/nat/samples/01.jpeg', (err, ret) => {
console.log(ret)
})
Error MEDIA_INTERNAL_ERROR MEDIA_NETWORK_ERROR MEDIA_DECODE_ERROR MEDIA_ABORTED MEDIA_PLAYER_NOT_STARTED MEDIA_FILE_TYPE_NOT_SUPPORTED MEDIA_SRC_NOT_SUPPORTED