On iPhoneX / iOS12. UITextView.inputAccessoryView is disappearing.

Originator:utrpanic
Number:rdar://43081635 Date Originated:09/08/2018
Status:Closed Resolved:Yes
Product:UIKit Product Version:
Classification:bug Reproducible:Yes
 
Summary: 
On iPhoneX / iOS12, switch UITextView.inputView to my custom view and switch back as nil, then UITextView.inputAccessoryView is disappearing.

Steps to Reproduce:
1. Run 'InputViewHeight' project attached.
2. Tap 'Switch' button which is contained in inputAccessoryView.
3. UITextView.inputView is changed to my custom view.
4. Tap 'Switch' button again. UITextView.inputView is now nil. 
5. Keyboard shows again.

Expected Results:
3. UItextView.inputView is changed to my custom view with same height.
5. Keyboard shows again and UITextView.inputAccessoryView should be shown on top of keyboard.

Actual Results:
3. UItextView.inputView is changed to my custom view but height is decreased.
5. Keyboard shows again but UITextView.inputAccessoryView is gone.

Version/Build: Xcode10 beta 5, iOS 12 beta 6

Comments

Apple Comment. 'Please know that our engineering team has determined that this issue behaves as intended based on the information provided.'

Set inputAccessoryView again when the inputTextView has changed. This works as expected on step5.


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!