Typeahead no data attribute

By using a data-value attribute, each item is forcefully
converted into a string. If the items are not simple values,
the resulting retrieval is useless at select time. 

Storing it with the jQuery data function instead means the
object is stored without problems.

This is the same as #6741, rebased against the 2.3.0-wip branch