组件 -- Button
.btn
---------------------------------
button的背景色:
.btn-primary
.btn-success
.btn-secondary
.btn-danger
.btn-info
.btn-light
.btn-dark
.btn-link
--------------------------
button的边框颜色:
.btn-outline-primary
.btn-outline-secondary
.btn-outline-success
--------------------------------
大小:
.btn-lg
.btn-sm
-------------------------------
状态:
.active
.disabled
disabled作为类只适用于<a>标签,不适用于<button>标签,<button>标签中disabled作为一种属性使用,例如:
<button type="button" class="btn btn-lg btn-primary" disabled>Primary button</button>
<a href="#" class="btn btn-secondary btn-lg disabled" role="button" aria-disabled="true">Link</a>
-----------------------------------
可使用的元素:
<a> <input> <button>
-----------------------------------
混合使用:
.button可与checkbox、radio等混合使用,会产生特殊的效果,如:
实例代码:
<div class="btn-group btn-group-toggle" data-toggle="buttons">
<label class="btn btn-secondary active">
<input type="radio" name="options" id="option1" autocomplete="off" checked> Active
</label>
<label class="btn btn-secondary">
<input type="radio" name="options" id="option2" autocomplete="off"> Radio
</label>
<label class="btn btn-secondary">
<input type="radio" name="options" id="option3" autocomplete="off"> Radio
</label>
</div>
<div class="btn-group-toggle" data-toggle="buttons">
<label class="btn btn-secondary active">
<input type="checkbox" checked autocomplete="off"> Checked
</label>
</div>
方法:
$().button('toggle') 点击button按钮,会进行状态切换
$().button('dispose') 摧毁button按钮
最新文章
- Ubuntu 配置有线网 IP
- python IOError: [Errno 0] Error
- PL/SQL Developer登入时候报ORA-12638: 身份证明检索失败的解决办法
- 机器学习&;数据挖掘笔记_21(PGM练习五:图模型的近似推理)
- Java 密码扩展无限制权限策略文件
- (四)Ubuntu 14.04 文件服务器--samba的安装和配置
- Linux 设备驱动 Edition 3
- linux系统快速查看进程pid的方法
- HDU 4931 Happy Three Friends
- 老李分享:Python开发性能测试脚本
- requests+正则表达式爬取ip
- Windows下面Node和NPM的绿色安装及配置
- PHP:自己写的mysql操作类
- 【BZOJ4784】[ZJOI2017]仙人掌(Tarjan,动态规划)
- 系统管理员需知的 16 个 iptables 使用技巧
- svn更新项目之后,项目报错一大堆并且tomcat部署项目时找不到项目
- 【python】参数中的*args和**kwargs
- [游记] HEOI2018酱油记
- yum安装软件报错:curl#6 - ";Could not resolve host: mirrorlist.centos.org; Temporary failure in name resolut
- T-SQL语句3