1 Star 0 Fork 0

风度 / peng-modal

Create your Gitee Account
Explore and code with more than 5 million developers,Free private repositories !:)
Sign up
This repository doesn't specify license. Without author's permission, this code is only for learning and cannot be used for other purposes.
Clone or download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

界面截图

主要参数

参数名 类型 默认值 可选值
title String 提示
titleColor String #000
con String 确定要删除吗?
conColor String #000
btn1 String 确定
btn1Color String #000
btn2 String 取消
btn2Color String #FF0000
show Boolean false true&&false

使用说明

1.使用组件

<peng-modal con="确定删除吗?" :show="show" @confirm='confirm' @cancel='cancel'>

2.定义一个按钮,用于弹出

<view class="btn" @tap="tapshow">居中弹出

3.data里定义参数

data(){ return{ show:false, //是否显示或隐藏 } }

4.methods里定义点击事件

methods:{ tapshow(){ this.show = true }, confirm(){ this.show = false uni.showToast({ title:'你点击了确定', icon:'none' }) }, cancel(){ this.show = false uni.showToast({ title:'你点击了取消', icon:'none' }) } }

Comments ( 0 )

Sign in for post a comment

About

uni-app自定义弹框提示组件 spread retract
Cancel

Releases

No release

Contributors

All

Activities

load more
can not load any more
1
https://gitee.com/ifengdu/peng-modal.git
git@gitee.com:ifengdu/peng-modal.git
ifengdu
peng-modal
peng-modal
master

Search