Avoid hide dropdown when user clicked inside

This commit is contained in:
RubenPX 2022-04-12 11:38:31 +02:00
parent 7d9d091a31
commit c910e0f7c0
2 changed files with 8 additions and 1 deletions

View File

@ -245,4 +245,11 @@
tableListCheckboxes.forEach(ckeckbox => ckeckbox.checked = checkedState);
})
/**
* Avoid hide dropdown when user clicked inside
*/
document.getElementById("dropDownLotsSelector").addEventListener("click", event => {
event.stopPropagation();
})
})();

View File

@ -78,7 +78,7 @@
Lots
<span class="caret"></span>
</button>
<ul class="dropdown-menu" aria-labelledby="btnLots" style="width: 300px;">
<ul class="dropdown-menu" aria-labelledby="btnLots" style="width: 300px;" id="dropDownLotsSelector">
<h6 class="dropdown-header">Select some devices to manage lots</h6>
<ul style="list-style-type: none; margin: 0; padding: 0;" class="mx-3" id="LotsSelector"></ul>
<li><hr /></li>