Skip to content

Commit

Permalink
Add missing text field delegate method (#592)
Browse files Browse the repository at this point in the history
  • Loading branch information
aniastrzezek authored Jan 6, 2023
1 parent b2c695c commit 459510b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions PhoneNumberKit/UI/PhoneNumberTextField.swift
Original file line number Diff line number Diff line change
Expand Up @@ -514,6 +514,11 @@ open class PhoneNumberTextField: UITextField, UITextFieldDelegate {
return self._delegate?.textFieldShouldReturn?(textField) ?? true
}

@available(iOS 13.0, tvOS 13.0, *)
open func textFieldDidChangeSelection(_ textField: UITextField) {
self._delegate?.textFieldDidChangeSelection?(textField)
}

private func updateTextFieldDidEndEditing(_ textField: UITextField) {
if self.withExamplePlaceholder, self.withPrefix, let countryCode = phoneNumberKit.countryCode(for: currentRegion)?.description,
let text = textField.text,
Expand Down

0 comments on commit 459510b

Please sign in to comment.