39 Commits

Author SHA1 Message Date
Tom Southall
2b1bd141fa Expose DOM methods via a forwarded ref 2022-04-06 22:27:33 +01:00
Tom Southall
c1d53e1d2b Allow functions for listbox and defaultListbox props
Extend listbox and defaultListbox prop types to allow functions returning a promise resolving to an array of group settings
2022-04-02 23:35:52 +01:00
Tom Southall
791622770a Remove console log 2022-04-02 12:56:14 +01:00
Tom Southall
941c25926e Move test API host to env. Add plugin as import. 2022-04-02 12:55:19 +01:00
Tom Southall
dcc7bfb640 Add enterKeyHint prop 2022-03-24 12:14:42 +00:00
Tom Southall
cbe957195d Prevent no items message from displaying whilst items are being fetched 2022-03-15 15:41:32 +00:00
Tom Southall
aad534f187 Remove redundant TODOs 2022-03-15 14:42:04 +00:00
Tom Southall
3cd6b1f017 Add no-console and no-debugger eslint rules 2022-03-15 13:26:22 +00:00
Tom Southall
cf28dacd35 Only show a transparent background on input box if there is no typeahead 2022-03-15 12:36:24 +00:00
Tom Southall
2500547716 Revamp plugins so that each acts as a wrapper component around Container 2022-03-12 20:51:42 +00:00
Tom Southall
3284de9f62 No need for dependency 2022-03-11 23:35:27 +00:00
Tom Southall
9c98b30e16 Do not show typeahead unless there is more than one item in the listbox 2022-03-11 21:05:51 +00:00
Tom Southall
ae48c619c4 Syntax tweak 2022-03-11 20:48:05 +00:00
Tom Southall
6c18efacf2 Fix localStorage state in recent searches plugin 2022-03-08 21:35:46 +00:00
Tom Southall
55354f5168 Remove xmlns 2022-03-04 16:27:49 +00:00
Tom Southall
1e70e1e2f2 Allow turning off typeahead via a prop 2022-03-04 15:35:26 +00:00
Tom Southall
ca39af8cc0 Rename ItemContents prop to Item 2022-03-04 15:10:02 +00:00
Tom Southall
7432818a22 Allow mobile search behaviour
Make focus/blur more robust

Allow Clear and Cancel button contents to be passed as components
2022-03-03 23:48:26 +00:00
Tom Southall
46a3a446d5 Ability to include sublocations 2022-03-02 20:36:44 +00:00
Tom Southall
aaeeaccafc Create Recent Searches plugin 2022-03-02 00:40:29 +00:00
Tom Southall
19e800fd8b Add displayField as second onSelect argument 2022-03-01 22:37:41 +00:00
Tom Southall
eb1d3a82db Add group ID 2022-03-01 21:12:49 +00:00
Tom Southall
71f41f896c Update split-match version
Tweaks to examples
2022-02-25 22:38:18 +00:00
Tom Southall
f74b64bd5a Rename dataSearchType prop to searchType 2022-02-25 00:39:01 +00:00
Tom Southall
70573f6e22 Change font weight in example 2022-02-25 00:37:16 +00:00
Tom Southall
3a8b0ba4ff Add useSWR error handling, errorMessage prop and errorbox component 2022-02-25 00:26:44 +00:00
Tom Southall
96525d8b6d Add a GroupName custom component 2022-02-24 15:37:46 +00:00
Tom Southall
1deef54576 Correctly handle clearing search input 2022-02-24 14:22:44 +00:00
Tom Southall
9d60c6e667 Give SplitMatch component some PropTypes validation 2022-02-23 23:04:41 +00:00
Tom Southall
76bf7f2f99 Remove text splitting and make text matching an option with a prop 2022-02-23 22:59:20 +00:00
Tom Southall
a1242eec5d Add ability to pass in an Item component
Create SplitMatch component

Create first (WIP) example
2022-02-23 21:41:55 +00:00
Tom Southall
f9467a8ede Rename splitChar to separator 2022-02-22 00:43:18 +00:00
Tom Southall
6e1b054195 dataSearchType now determines how list items are highlighted
Full search string now highlighted for startswith searches

Regularised item markup
2022-02-22 00:35:51 +00:00
Tom Southall
583726fcb9 Consolidate itemGroups and data props into a single listbox prop 2022-02-21 21:07:52 +00:00
Tom Southall
ac6f749762 Make ListBox one word: Listbox 2022-02-21 20:08:03 +00:00
Tom Southall
f9bf89b108 Add unit tests for reducer 2022-02-21 19:49:28 +00:00
Tom Southall
69e344d29d Clear selected value when query changes 2022-02-21 17:08:46 +00:00
Tom Southall
d66a2f413d Simplify rules for whether listbox is expanded 2022-02-21 16:42:55 +00:00
Tom Southall
1e91265556 Add examples folder 2022-02-21 15:57:53 +00:00