New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

vi-dialog

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vi-dialog

微信小程序组件dialog

latest
Source
npmnpm
Version
0.0.6
Version published
Maintainers
1
Created
Source

vi-dialog

使用

npm i vi-dialog 使用微信开发者工具构建NPM并使用NPM模块

{
  "usingComponents": {
    "vi-dialog": "vi-dialog"
  }
}

属性

接口数据类型说明选项默认值
ishideBoolean控制组件dialog显示隐藏必填false
titleStringdialog组件title选填提示
inputBoolean是否开启输入会话窗,默认不开启选填false
confirmBoolean确认会话窗选填false
alertBoolean警告会话窗选填false
customBoolean自定义会话窗按钮选填false
placeholderStringinput标签的placeholder属性要和组件的input接口配合使用选填请输入内容
valueStringinput标签的value属性要和组件的input接口配合使用选填''
inputTypeStringinput标签的type属性要和组件的input接口配合使用选填文本输入框(text)
maxlengthNumberinput标签的maxlength属性要和组件的input接口配合使用选填140
disabledBooleaninput标签的disable属性要和组件的input接口配合使用选填false
confirmTypeString小程序input组件的confirmType属性要和组件的input接口配合使用选填done
passwordBooleaninput组件的password属性要和组件的input接口配合使用选填false

event

event namedescription返回值数据类型返回值说明
triggerToCancel取消按钮的事件String按钮的标识:'cancel'
triggerToConfirm确认按钮的事件String, Object数据类型为String时是按钮的标识:'confirm',数据类型为Object时,是输入会话窗的event.detail值
triggerToInputinput的输入事件Object返回用户输入的值
triggerToFocusinput的聚焦事件Objectevent.detail
triggerToBlurinput的失焦事件Objectevent.detail

slot

slot namedescription
default默认插槽,会话窗的提示内容
customButton自定义按钮的插槽,注意需要和组件的custom接口配合使用

Bug&&Tips

  • 该组件的default形式与confirm形式是一样的

版本信息

  • v0.0.1 第一个版本
  • v0.0.6 修改组件层级、更新文档

Keywords

miniprogram

FAQs

Package last updated on 10 Oct 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts