twitter/bootstrap — Issue #2347: responsive navbar w/ dropdown behavior bug
Author: brewster1134
Created: 2012-03-01 04:46:08+00:00
State: open

When a collapsed navbar is uncollapsed, dropdown menus are no longer visibile.

i have followed these steps in both Chrome and FF to reproduce this issue using the sample navbar at http://twitter.github.com/bootstrap/components.html#navbar

1. shrink the browser so the navbar collapses
2. expand the collapsed navbar
3. stretch the browser out so the navbar uncollapses
4. click the dropdown toggle. the dropdown menu will be hidden.

i didnt have time to really dive into the code, but i think its something to do with the reset function adding 'collapse' back to the nav-collapse div after it just removed it. it should remove it, in addition to the dimension style upon uncollapse.

reset: function ( size ) {
var dimension = this.dimension()

this.$element
.removeClass('collapse')
[dimension](size || 'auto')
[0].offsetWidth

this.$element.addClass('collapse')
}