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-dialog-plus

v1.0.0

Published

An Cordova project is an extension to cordova-plugin-dialogs. It provides the progress bar, loading layer, file selection dialog box, toast to Android and IOS platform. Android part of the code reference to the cordova-plugin-dialogs source code.

Downloads

7

Readme

cordovaDialogsPlus

The Cordova project is an extension to cordova-plugin-dialogs. It provides the progress bar, loading layer, file selection dialog box, toast to Android and IOS platform. Android part of the code reference to the cordova-plugin-dialogs source code.

这是一个cordova的插件项目,是对cordova的官方插件cordova-plugin-dialogs的扩展,在ios和安卓平台上,提供了进度条、加载层、文件选择对话框、消息提示等功能。安卓平台的代码参考了cordova-plugin-dialogs的部分源码。

Installation

This requires cordova 5.0+

cordova plugin add https://github.com/laden666666/cordovaDialogsPlus

Does not support earlier versions

插件只支持cordova5.0及以上版本

cordova plugin add https://github.com/laden666666/cordovaDialogsPlus

Supported Platforms

支持的平台为

  • Android
  • iOS

API Reference

Display load layer

显示加载层

window.navigator.dialogsPlus.show.showLoading(title, loadingMassage);

Dismiss load layer

隐藏加载层

window.navigator.dialogsPlus.hideLoading();

Display progress dialog

显示进度条对话框

window.navigator.dialogsPlus.progressStart(title, loadingMassage, errorCallback, canCancel, cancelButtonName, cancelCallback);

The function returns a JSON object.Use this object to hide the progress bar, or set the progress value.

这个函数返回的是一个json对象,使用这个对象可以对此函数打开的进度条操作,例如设置进度或者隐藏进度条。

var progress = window.navigator.dialogsPlus.progressStart("title","loading....");
progress.setValue(100);
progress.hide(successCallback, errorCallback);

Open choose file dialog.On the Android platform, you can open the system file activity, it returns the absolute path of the selected file. On the IOS platform, you can only choose photo of the album by cordova-plugin-camera (because of IOS file sandbox).

选择文件,安卓上你可以使用系统对话框选择文件,选择后将获得所选文件的绝对路径。但是在ios上,你只能通过此插件依赖的cordova-plugin-camera插件,去选择相册里的图片,这主要是因为ios的文件沙箱机制,我无法向安卓那样获取其他应用目录里的图片。

window.navigator.dialogsPlus.chooseFile(title, successCallback, errorCallback);

Display toast notice. The duration of the unit is milliseconds.

通过类似安卓toast消息的形式显示通知。持续时间的单位是毫秒。

window.navigator.dialogsPlus.showNotice(notice,duration)