Twitter Bootstrap - 按钮宽度在下拉菜单中 [英] Twitter Bootstrap - Button Width in Drop-down menu

查看:132
本文介绍了Twitter Bootstrap - 按钮宽度在下拉菜单中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

相当新的引导 - 但是我有一个按钮和下拉菜单,它由包含按钮的无序列表组成。我如何使按钮宽度相同 - 或者我完全脱离了我的代码:

Fairly new to bootstrap-- but I have a button and drop down menu which is composed of an unordered list containing buttons. How would I make the button widths all the same-- or am I completely off base with my code:

这是代码:

<div class="btn-group" style="margin-bottom: 5px">
    <a class="btn btn-large dropdown-toggle" data-toggle="dropdown" href="#">
        <i class="icon-wrench">
    </i>Admin Actions <span class="caret"></span></a>
    <ul class="dropdown-menu">
        <li>
            <button  class="btn btn-large">
                <i class="icon-plus"></i>Create Content</button>
        </li>
        <li>
            <button  class="btn btn-large">
                <i class="icon-wrench"></i>Edit Page</button></li>
        <li><button   class="btn btn-large">
            <i class="icon-plus"></i>Add Page</button></li>
            </ul>
        </div>

这里是一个小提琴
http://jsfiddle.net/5wqU5/

推荐答案

你可以在您的按钮中添加btn-block...

You can add 'btn-block' to your buttons...

<button class="btn btn-large btn-block">

更新小提琴: http://jsfiddle.net/5wqU5/2/

这篇关于Twitter Bootstrap - 按钮宽度在下拉菜单中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆