Separate autocomplete behaviour from styling

@aeng please review this.