Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS 12 suggest phone number in QuickType bar

How is Lyft suggesting my phone number in the QuickType bar so that I do not have to enter it manually? I know Apple introduced autofill functionality for usernames, passwords, security codes, and more with iOS 12 and it looks like this phone number suggestion may be using a similar function but I cannot figure out how to get any of my apps to suggest the phone number like Lyft is doing below.

Lyft Enter Phone Number Screenshot

like image 676
Alec Avatar asked Sep 03 '25 17:09

Alec


1 Answers

From Interface Builder / Storyboard

  • Select a textField.
  • Show the Attributes inspector.

Content Type Telephone Number

From Code

You can access this property in any UITextField

textField.textContentType = .telephoneNumber
like image 72
barbarity Avatar answered Sep 07 '25 18:09

barbarity