美文网首页KAMS
Semantic 弹窗提示

Semantic 弹窗提示

作者: cobantou | 来源:发表于2016-11-27 14:13 被阅读448次

两种类型

  1. 有“确认”和“取消”按钮的对话框弹窗,用来对用户的操作进行确认,如下图:
Paste_Image.png

对应插件:ui-dialog

2.对操作的结果进行提示,如是否成功、失败、警告等提示;

Paste_Image.png

对应插件:ui-alert

ui-dialog

根据semanticmodal封装而来,只是一层语法糖。

使用例子:

Paste_Image.png
$.uiDialog(msg,options)

参数说明:
msg:对话框的提示文字。
options:参考semantic.modal的settings

ui-alert

根据semanticmessage封装而来。

使用例子:

Paste_Image.png

参数说明:

$.uiAlert({
        textHead: 'Your user registration was successful.',//标题
        text: 'You may now log-in with the username you have chosen',//详细内容
        textcolor: '#fff',//文字颜色
        type: 'success',//提示类型:'success','info','waring','danger'
        position: 'top-right',//位置:'top-left','top-center','top-right','bottom-left','bottom-center','bottom-right','center'
        icon: '',//提示左边的图标
        time: 5,//几秒后消失
        permanent: false,//是否永远不消失
        onClosed:function(){//结束的回调                     
        }
})

相关文章

网友评论

本文标题:Semantic 弹窗提示

本文链接:https://www.haomeiwen.com/subject/ftcnpttx.html