mirror of
https://github.com/kiwix/libkiwix.git
synced 2025-06-26 10:11:30 +00:00
Render suggestion snippet properly
To render the snippets properly, we need to use the _renderItem property of the autocomple ui.
This commit is contained in:
committed by
Matthieu Gautier
parent
56434de79e
commit
3288cd80e5
@ -34,7 +34,12 @@ jq(document).ready(() => {
|
||||
$( "#kiwixsearchform" ).submit();
|
||||
}
|
||||
},
|
||||
});
|
||||
}).data( "ui-autocomplete" )._renderItem = function( ul, item ) {
|
||||
return $( "<li>" )
|
||||
.data( "ui-autocomplete-item", item )
|
||||
.append( item.label )
|
||||
.appendTo( ul );
|
||||
};
|
||||
|
||||
/* cybook hack */
|
||||
if (navigator.userAgent.indexOf("bookeen/cybook") != -1) {
|
||||
|
Reference in New Issue
Block a user