fix: markedTextRange overlap with placeholder while inputing
This commit is contained in:
parent
48d6a84394
commit
25b6a69d02
@ -307,6 +307,12 @@ - (BOOL)textView:(UITextView *)textView shouldChangeTextInRange:(NSRange)range r
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (void)textViewDidChange:(UITextView *)textView {
|
- (void)textViewDidChange:(UITextView *)textView {
|
||||||
|
if (textView.markedTextRange || textView.text.length > 0) {
|
||||||
|
self.view.placeholderLabel.hidden = YES;
|
||||||
|
} else {
|
||||||
|
self.view.placeholderLabel.hidden = NO;
|
||||||
|
}
|
||||||
|
|
||||||
if (textView.markedTextRange) return;
|
if (textView.markedTextRange) return;
|
||||||
|
|
||||||
if (self.maxLength) {
|
if (self.maxLength) {
|
||||||
|
Reference in New Issue
Block a user