From 7363194b1e710720e44487593a85e1b4688680dd Mon Sep 17 00:00:00 2001 From: rex Date: Tue, 19 Jun 2018 19:50:59 +0800 Subject: [PATCH] =?UTF-8?q?[bugfix]=20Dialog:=20=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E4=BD=BF=E7=94=A8dialog=E7=BB=84=E4=BB=B6=E7=9A=84=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E5=88=87=E6=8D=A2=E8=B7=AF=E7=94=B1=E6=97=B6=E6=8A=A5?= =?UTF-8?q?=E9=94=99=20@rex-zsd=20(#310)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #289 --- packages/dialog/index.js | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/packages/dialog/index.js b/packages/dialog/index.js index 67f2d126..540ab254 100644 --- a/packages/dialog/index.js +++ b/packages/dialog/index.js @@ -1,12 +1,32 @@ -const defaultData = require('./data'); - const _f = function () {}; Component({ properties: {}, data: { - ...defaultData, + // 标题 + title: '', + // 自定义 btn 列表 + // { type: 按钮类型,回调时以此作为区分依据,text: 按钮文案, color: 按钮文字颜色 } + buttons: [], + // 内容 + message: ' ', + // 选择节点 + selector: '#zan-dialog', + // 按钮是否展示为纵向 + buttonsShowVertical: false, + // 是否展示确定 + showConfirmButton: true, + // 确认按钮文案 + confirmButtonText: '确定', + // 确认按钮颜色 + confirmButtonColor: '#3CC51F', + // 是否展示取消 + showCancelButton: false, + // 取消按钮文案 + cancelButtonText: '取消', + // 取消按钮颜色 + cancelButtonColor: '#333', key: '', show: false, showCustomBtns: false,