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

Add basic position to dropup/right/left #25324

Closed
wants to merge 2 commits into from

Conversation

ysds
Copy link
Member

@ysds ysds commented Jan 16, 2018

Fixes: #25304

This changes fix a position of dropright/left menu on navbar. And give a basic position for dropup/right/left for disable popper support in the future enhancement (#24092).

Note:

  • The direction of carets on navbar is not responsive. (e.g. a caret of dropright is turning to the right even on mobile.)
  • display is not defined for dropright. In many cases it should be use in/on an inline element (.btn-group or .d-inline-block etc). Otherwise the dropright menu will jump to the right end (left: 100%) of the div.

@Johann-S
Copy link
Member

is it possible to see a live example in a CodePen ?

@ysds
Copy link
Member Author

ysds commented Jan 16, 2018

While creating a demo, I noticed a bug in this PR. The dropleft/dropup menu is broken by right, bottom property when not disabled popper (actually by default).

Demo: https://codepen.io/anon/pen/MrqGBV

@ysds
Copy link
Member Author

ysds commented Jan 16, 2018

Closing since has a bug

@ysds ysds closed this Jan 16, 2018
@Johann-S
Copy link
Member

Dropup works pretty well currently (with Popper.js disabled) : https://getbootstrap.com/docs/4.0/examples/navbar-bottom/

@Johann-S
Copy link
Member

I think it's doable to fix that issue @ysds , bottom: 100% should be applied only for Dropdown and not for Dropup

@ysds
Copy link
Member Author

ysds commented Jan 16, 2018

Dropup works pretty well currently (with Popper.js disabled) :

Yes. because it has the spesific scss:

bootstrap/scss/_navbar.scss

Lines 193 to 197 in 1f490ec

.dropup {
.dropdown-menu {
top: auto;
bottom: 100%;
}

but dropup will not work the outside of navbar after the future enhancement (#24092).

@ysds ysds deleted the dropdown-basic-position branch April 10, 2018 01:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants