Fix popping up autocomplete if input not selected

If the user typed in the autocomplete input but subsequently blurred
the field before results came back from the server (by, say, tabbing
to the next form element), the asynchronous return of results would
end up rendering the suggestion list anyway. This is jarring and
unexpected behavior. This commit fixes this bug.

Change-Id: I3534e8ef12ff3aab565f332f29b8c01043ffde1c
Reviewed-on: https://gerrit.causes.com/19108
Reviewed-by: Alex Wallace <alex.wallace@causes.com>
Reviewed-by: Greg Hurrell <greg@causes.com>
Tested-by: Tony Wooster <tony.wooster@causes.com>
Fix caching bug in use of `paramName`

This commit fixes a bug whereby the `paramName` option wasn't being
used when retrieving cached query results. This manifested as queries
missing the cache when they shouldn't (because they were inserted on
`result[paramName]` but retrieved via `result.query`).

Change-Id: I30fac4cb1de45533d2373e1293e13362b13e76a8
Reviewed-on: https://gerrit.causes.com/19109
Reviewed-by: Greg Hurrell <greg@causes.com>
Tested-by: Tony Wooster <tony.wooster@causes.com>
Add `onShow` and `onHide` callbacks

This commit adds `onShow` and `onHide` callbacks which are triggered
when the suggestion list is shown or hidden.

Change-Id: Ia35906b47696c3f71bb6a944bbfb493557d325be
Reviewed-on: https://gerrit.causes.com/19120
Reviewed-by: Tony Wooster <tony.wooster@causes.com>
Tested-by: Tony Wooster <tony.wooster@causes.com>
Add `autoShow` option

This commit adds an `autoShow` option which pops up the suggestion
list (if appropriate) when the input element is focused.

Change-Id: I82a8da58455147d6c873aa936786ee12f469f50d
Reviewed-on: https://gerrit.causes.com/19121
Reviewed-by: Tony Wooster <tony.wooster@causes.com>
Tested-by: Tony Wooster <tony.wooster@causes.com>
Add `isSelectable` method

This commit adds an `isSelectable` callback which can be used to
indicate whether a given autocomplete suggestion should be
"selectable". This can be used to implements suggestion sections,
headings or similar.

Change-Id: Ibe88c57b021f0c3596415a8da320a4ef79aa9fe3
Reviewed-on: https://gerrit.causes.com/19125
Reviewed-by: Tony Wooster <tony.wooster@causes.com>
Tested-by: Tony Wooster <tony.wooster@causes.com>
Add `selectKeys` option

This commit adds a `selectKeys` option which is a customization that
allows a user to specify which keys should trigger selection. In some
situations, for example, pressing tab is expected, but pressing enter
is not or vice-versa. This aids in that use-case.

Change-Id: Ia744d87ea50bbf64873d9a08987c8d10b0fc1677
Reviewed-on: https://gerrit.causes.com/19126
Reviewed-by: Tony Wooster <tony.wooster@causes.com>
Tested-by: Tony Wooster <tony.wooster@causes.com>
Merge branches 'bugfix-dependent-features' and 'new-features' into causes-integration