-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Dropdown issue with autoClose set to 'outsideClick' starts to behave like 'disabled' #1674
Comments
Will be fixed after this PR: #1771
|
Hey, guys, so the 'ousideClick' option is not supported any more? Now to do this, we need to listen to clicks or Esc btn manually. That does not sound like a good thing for me(( |
autoclose: true, should close on any outside action |
difference is: outsideClick behavior was including a difference between internal\external click |
In my case, I have a datepicker inside the dropdown, so 'outsideClick' was just perfect, it prevented the dropdown from closing on datepicker UI clicks but did closing on outside actions. Maybe I need to stick with |
Yes, exactly. Stop propagation is what you need. |
I have almost the same case as @guryanovev and I feel a little disappointed by this. |
It was solving only one issue, but solution is needed for several components (tooltips, popovers, etc.) any pop over components. |
Ok I see. |
Not sure what happened, but the Now, I can click anywhere in the dropdown (I can click on the |
@a11smiles does it differs from bootstrap dropdowns? |
latest dev available here: http://ngx-bootstrap.surge.sh/#/dropdowns#single-button |
Place two dropdowns on a view one with autoClose="disabled" and second with autoClose="outsideClick", like :
<div class="btn-group" dropdown autoClose="disabled">
<button id="single-button" type="button" class="btn btn-primary" dropdownToggle>
Button dropdown <span class="caret"></span>
</button>
<ul dropdownMenu role="menu" aria-labelledby="single-button">
<li role="menuitem"><a class="dropdown-item" href="#">Action</a></li>
<li role="menuitem"><a class="dropdown-item" href="#">Another action</a></li>
<li role="menuitem"><a class="dropdown-item" href="#">Something else here</a></li>
<li class="divider dropdown-divider"></li>
<li role="menuitem"><a class="dropdown-item" href="#">Separated link</a></li>
</ul>
</div>
<div class="btn-group" dropdown autoClose="outsideClick">
<button id="single-button" type="button" class="btn btn-primary" dropdownToggle>
Button dropdown <span class="caret"></span>
</button>
<ul dropdownMenu role="menu" aria-labelledby="single-button">
<li role="menuitem"><a class="dropdown-item" href="#">Action</a></li>
<li role="menuitem"><a class="dropdown-item" href="#">Another action</a></li>
<li role="menuitem"><a class="dropdown-item" href="#">Something else here</a></li>
<li class="divider dropdown-divider"></li>
<li role="menuitem"><a class="dropdown-item" href="#">Separated link</a></li>
</ul>
</div>
Open them one by one clicking to [Button dropdown] button, after few clicks dropdown which should close by outsideClick losing this behavior and closed only by opening other one.
Also same can be reproduced on demo page @ http://valor-software.com/ng2-bootstrap/#/dropdowns#config
open Configuring defaults dropdown
open Dropup variation dropdown
try clicking outside
The text was updated successfully, but these errors were encountered: