typeahead-standalone icon indicating copy to clipboard operation
typeahead-standalone copied to clipboard

Function Source - WIP

Open bryan-gilbert opened this issue 1 year ago • 5 comments

Add new data source based on a function call that runs when the typeahead gains focus. This allows for dynamic content from the application's context.

Also changed ev.keyCode to ev.code because the ev.keyCode is depreciated.

If this PR is worthy of consideration then I will add tests and help in any way I can.

bryan-gilbert avatar Dec 30 '22 14:12 bryan-gilbert

Created a demo

bryan-gilbert avatar Dec 30 '22 15:12 bryan-gilbert

Thank you for your contribution, it is very well appreciated ! :smile:

niketpathak avatar Dec 30 '22 16:12 niketpathak

Once again, I accidentally committed something to this PR when I really wanted to first commit to just my fork and then, later, add to this PR or contribute a second. I can start this PR over if there is a problem.

bryan-gilbert avatar Dec 31 '22 19:12 bryan-gilbert

Renamed source to CustomSource (good suggestion).
Check that custom source is not used with other sources. Sort by the whole word for custom sources.

bryan-gilbert avatar Jan 12 '23 17:01 bryan-gilbert

Thank you for the updates, I'm gonna run/write some tests (this week hopefully) to ensure stuff works as expected, so bear with me until then, will approve the PR thereafter. Thanks!

niketpathak avatar Jan 15 '23 11:01 niketpathak