Improve typeahead on dashboard page

This commit is contained in:
Raphael Michel
2017-08-24 14:21:30 +02:00
parent a773531003
commit ff21380099
3 changed files with 10 additions and 1 deletions

View File

@@ -13,6 +13,11 @@ $(function () {
$container.find("li:not(.query-holder)").remove();
$query.on("change", function () {
if ($container.attr("data-typeahead-field") && $query.val() === "") {
$container.removeClass('focused');
$container.find("li:not(.query-holder)").remove();
return;
}
$.getJSON(
$container.attr("data-source") + "?query=" + encodeURIComponent($query.val()),
function (data) {

View File

@@ -156,6 +156,10 @@
.focused.dropdown-menu {
display: block;
overflow: hidden;
}
.event-dropdown .event-name-full, .mobile-event-dropdown .event-name-full {
white-space: normal;
}
}