typeahead.js icon indicating copy to clipboard operation
typeahead.js copied to clipboard

fix #1314 - limit doesn't work properly with more than one digit

Open PierreAnctil opened this issue 10 years ago • 4 comments

the suggestions where sliced with: rendered += suggestions.length; suggestions.slice(0, that.limit - rendered)

which is fine as long as limit < suggestions.length because slicing with a negative index works but if limit = suggestions.length then no element is rendered. if limit > suggestions.length then the results are truncated.

PierreAnctil avatar Jul 10 '15 14:07 PierreAnctil

I just ran into the same issue. If limit == suggestions it shows no results. suggestions.slice(0, 0) -> [] :(

ksykulev avatar Jul 10 '15 16:07 ksykulev

@PierreAnctil Could you please re-submit this PR to github:corejavascript/typeahead.js. This project pretty much has been abandoned, and we continue now on a new fork. For more information please see #1320

core-system-dev avatar Sep 25 '15 08:09 core-system-dev

Looks like a duplicate of #1212, has been fixed over at corejavascript/typeahead.js#8

jlbooker avatar Oct 05 '15 01:10 jlbooker

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar Jul 18 '19 15:07 CLAassistant