Dropdowns shown incorrectly
See original GitHub issueBug description:
My dropdowns won’t work - neither the bootstrap-standard-dropdowns, nor the ng-bootstrap-dropdowns… The dropdown is ‘opened’ from the beginning and is shown very uncommon. If I press the toggle-button, nothing happens. The classes of the dropdown-items aren’t even changed.
Link to minimally-working StackBlitz that reproduces the issue:
That’s the problem. I can’t reproduce the problem. The stackblitz shows my scenario nonetheless… https://stackblitz.com/edit/angular-pvq85f --> modal - in the modal is a dropdown
It looks like the script-side of ng-bootstrap isn’t working, but I don’t know why…
<div class="modal-content">
<div class="modal-header">
<div>
TITLE
</div>
<button type="button" class="icon-button" (click)="activeModal.close()">
<i class="icon icon-delete" aria-hidden="true"></i>
</button>
</div>
<div class="modal-body">
<div>
<div class="form-group row">
<p class="col-4 text">{{'Priority'|translate}}</p>
<div class="col-8 no-padding">
<div class="col">
<div ngbDropdown class="d-inline-block">
<button class="btn btn-outline-primary" id="dropdownBasic1" ngbDropdownToggle>Toggle dropdown</button>
<div ngbDropdownMenu aria-labelledby="dropdownBasic1">
<button ngbDropdownItem>Action - 1</button>
<button ngbDropdownItem>Another Action</button>
<button ngbDropdownItem>Something else is here</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="modal-footer ">
<button type="button" class="normal-button" (click)="submit()">
FOOTER
</button>
</div>
</div>
My angular.json
My index.html
Versions of Angular, ng-bootstrap and Bootstrap:
Angular: 9.0.6
ng-bootstrap: 6.0.0
Bootstrap: 4.4.1
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
The problem with dropdown fields (and what you should use ...
In this article, I'm going to talk about the advantages and disadvantages of using dropdowns, show you how to pick a better input...
Read more >Dropdown showing incorrect data - Power Platform Community
Solved: I have a dropdown input control and the control settings are: Items: Distinct('Check Statuses','Check Statuses') Where Check ...
Read more >Dropdown filter is showing incorrect result in React
The display should show the result as per the values selected in checkboxes and dropdown. While checkboxes are working well and displaying ...
Read more >Excel Data Validation Tips and Troubleshooting - Contextures
Drop down not working, blank selected, not showing all data. ... Here's the most common cause for that problem, and how to fix...
Read more >Incorrect cursor showing in dropdown menu - HTML & CSS
Why is my cursor the text select button when its suppose to be the link click cursor when I click the dropdown menu...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Alright, so I did that and everything worked fine. I think, something in my app is wrong or so. It’s been a while since it was created and there have been many updates etc… But thank you anyways for helping out. I think I have to start from scratch in near future.
Ok, then 😄 Could you try to create a blank new project from Angular CLI, then manually (following our documentation) add ng-bootstrap, and finally try the broken pattern.