# radioActionsheet 单选弹出框
# 参数
属性 | 类型 | 默认值 | 可选值 | 说明 |
---|---|---|---|---|
options | Array | [] | -- | 选项 |
# 回调
属性 | 类型 | 说明 |
---|---|---|
success | Function | 按钮执行点击选项事件后返回 |
# 示例代码
<view>
<button bindtap="onTap">点我</button>
<dialog-center></dialog-center>
</view>
import dialogSet from "../../../package/fxui/DialogCenter/DialogSet";
Page({
/**
* 页面的初始数据
*/
data: {
options: {
// show: true,
title: "纷享",
subtitle: "fxiaoke",
options: [
{
label: '2',
subtitle: 'subtitle',
subStyle: 'color: red;'
},
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' },
{ label: '2' }
],
success(res) {
console.log(res);
}
}
},
onTap() {
const _self = this;
dialogSet.actionsheet.show(_self.data.options);
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady: function () {
},
/**
* 生命周期函数--监听页面显示
*/
onShow: function () {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide: function () {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload: function () {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh: function () {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom: function () {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage: function () {
}
})
{
"usingComponents": {
"dialog-center": "../../../package/fxui/DialogCenter/DialogCenter"
}
}