Per a [comment](https://github.com/elastic/kibana/pull/17452#issuecomment-380246722) by @trevan: > Could you sort the fields so that the items that start with the entered text are at the top? The field list in the terms aggregation does this. It uses https://github.com/elastic/kibana/blob/master/src/ui/public/utils/sort_prefix_first.js to do the sorting.
Per a comment by @trevan: