Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nav navbar-nav nav-justified is broken #8682

Closed
Bartmax opened this issue Jul 27, 2013 · 4 comments
Closed

nav navbar-nav nav-justified is broken #8682

Bartmax opened this issue Jul 27, 2013 · 4 comments

Comments

@Bartmax
Copy link

Bartmax commented Jul 27, 2013

When doing like the example :

`

`

as soon as I enter nav-justified to the ul it just explodes :D

@Bartmax
Copy link
Author

Bartmax commented Jul 28, 2013

1 issue is the .navbar-nav > li { float: left; }
take precedence over :
.nav-justified > li { display: table-cell; float: none; width: 1%;

other is that display:table should be applied i guess to nav element and remove the width:1% so it actually takes the 100%

workaround fix:

.navbar-nav.nav-justified {
    display:table;
}

.navbar-nav.nav-justified > li{
    float:none;
    width:auto;
}

@Bartmax
Copy link
Author

Bartmax commented Jul 28, 2013

Ok I guess i mixed nav with navbar which is great, with the proposed workaround/fix but actually I think it should be appropiate to have a navbar-justified class and leave the nav-justified alone. It's up to you guys if you want to implement a justfied navbar and how. I think it cheap and very usefull to add.
here's a full implementation of navbar with justified items. (using css workaround)

  ´´´´  <div class="container">
        <div class="navbar navbar-inverse">
            <ul class="navbar-nav nav nav-justified">
                <li class="active"><a href="#">Inicio</a></li>
                <li><a href="#">Item 1</a></li>
                <li><a href="#">Item 2</a></li>
                <li><a href="#">Item 3</a></li>
                <li><a href="#">Item 4</a></li>
            </ul>
        </div>
    </div>

´´´´

@mdo
Copy link
Member

mdo commented Jul 30, 2013

For now we'll pass on this—it's addressed in an example elsewhere.

@knyokolodi
Copy link

knyokolodi commented Mar 1, 2017

Use this code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants