npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

cordova-plugin-imagepicker-plus

v2.0.0

Published

Cordova ImagePicker Plugin

Downloads

1

Readme

cordova-plugin-ImagePicker

非常感谢南尘banchichen 提供的源码支持 多点star✨开源不容易,谢谢。扣扣群:273613165

一个支持多选,相册实现了拍照、预览、(Android 图片压缩)等功能

功能

  • 相册目录
  • 多选图
  • 相册内部拍照
  • 预览选中的图片
  • 图片压缩(Android)

安装要求

  • Cordova Version >=5.0
  • Cordova-Android >=4.0
  • Cordova-iOS >=6.0

iOS Requirements 要求

OS 6 or later. Requires ARC iOS6及以上系统可使用. ARC环境.

When system version is iOS6 or iOS7, Using AssetsLibrary. When system version is iOS8 or later, Using PhotoKit. 如果运行在iOS6或7系统上,用的是AssetsLibrary库获取照片资源。 如果运行在iOS8及以上系统上,用的是PhotoKit库获取照片资源。

安装

  • cordova plugin add https://github.com/giantss/cordova-plugin-ImagePicker.git

或者

  • cordova plugin add cordova-plugin-imagepicker-plus

注意:Android 项目先不要直接 build ,见 android注意事项

Android 视频演示

iOS 视频演示

效果图

| Android | iOS | |:---------------:|:------------:| | | |

使用方式

注:目前下面demo中传入的参数都可以不传,程序默认会设置下面demo的传参数,如果需要传参数,都得一起传,一个都不能少,否则会报json错误。

ImagePicker.getPictures(function(result) {
    alert(result);
}, function(err) {
    alert(err);
}, { maximumImagesCount : 9, width : 1920, height : 1440, quality : 100 });

参数含义

| 配置参数 | 参数含义 | |:------------------:|:-------------------------:| | maximumImagesCount | 多选限制数量,默认为9 | | width | 设置图片的width,默认为1920 | | height | 设置图片的height,默认为1440 | | quality | 图片质量 默认100 |

android注意事项

缺少 provider_paths.xml 文件问题

出现下面错误

Error: /Users/guodapeng/Documents/Cordova/skateboard/platforms/android/gradlew: Command failed with exit code 1 Error output:
/Users/guodapeng/Documents/Cordova/skateboard/platforms/android/build/intermediates/manifests/full/debug/AndroidManifest.xml:66:35-54: AAPT: No resource found that matches the given name (at 'resource' with value '@xml/provider_paths').

将 cordova-plugin-ImagePicker/src/android/res/xml/ 目录的 provider_paths.xml 文件复制到 platforms/android/res/xml/ 目录下

插件选图闪退问题

在安装了扫描二维码插件时,在 patient-barcodescanner.gradle 文件中将 support-v4 修改为下面版本,可以解决闪退问题。

com.android.support:support-v4:25.3.1

License

The MIT License (MIT)