Twitter的引导3下拉菜单百万外出浏览器菜单、浏览器、Twitter

2023-09-11 08:00:52 作者:[ SEHUN° ]

我试图让使用Twitter Bootsrap 3.0兆菜单,它工作正常。但是,当涉及到与大型菜单中的最后一个列表项,下拉走出浏览器,因为它从左边开始。我怎样才能使最后一个列表项的下拉只有开始由右至左。我试图用拉权,但它不能正常工作。当在主菜单列表项使用右拉式,在下拉开始从极端的导航栏的右侧。我想它像,下拉完全正确对齐父的相对位置。任何人可以帮助我在这?

I'm trying to make a mega menu using Twitter Bootsrap 3.0 and it works fine. But when it comes to the last list item with mega menu, the dropdown goes out of the browser, since it starts from left. How can i make the last list item's dropdown only starts from right to left. I've tried to use "pull-right", but it doesn't work properly. When using "pull-right" for the main menu list item, the dropdown starts from extreme right of the navigation bar. I want it like, the dropdown perfectly right aligned to the parent 's relative position. Can anybody help me on this??

推荐答案

CSS

.navbar-nav > li:last-child > .dropdown-menu {
    left: auto;
    right: 0; }

引用

如何覆盖左:0使用CSS或jQuery的 更改CSS的最后李 how to override left:0 using CSS or Jquery? Changing CSS for Last li