mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-17 10:41:13 +08:00
perf(item): remove delegatesFocus patch for iOS 13 (#25822)
This commit is contained in:
@ -25,16 +25,6 @@ export class Textarea implements ComponentInterface {
|
||||
private textareaWrapper?: HTMLElement;
|
||||
private inheritedAttributes: Attributes = {};
|
||||
|
||||
/**
|
||||
* This is required for a WebKit bug which requires us to
|
||||
* blur and focus an input to properly focus the input in
|
||||
* an item with delegatesFocus. It will no longer be needed
|
||||
* with iOS 14.
|
||||
*
|
||||
* @internal
|
||||
*/
|
||||
@Prop() fireFocusEvents = true;
|
||||
|
||||
@Element() el!: HTMLElement;
|
||||
|
||||
@State() hasFocus = false;
|
||||
@ -242,18 +232,6 @@ export class Textarea implements ComponentInterface {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets blur on the native `textarea` in `ion-textarea`. Use this method instead of the global
|
||||
* `textarea.blur()`.
|
||||
* @internal
|
||||
*/
|
||||
@Method()
|
||||
async setBlur() {
|
||||
if (this.nativeInput) {
|
||||
this.nativeInput.blur();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the native `<textarea>` element used under the hood.
|
||||
*/
|
||||
@ -332,18 +310,14 @@ export class Textarea implements ComponentInterface {
|
||||
this.hasFocus = true;
|
||||
this.focusChange();
|
||||
|
||||
if (this.fireFocusEvents) {
|
||||
this.ionFocus.emit(ev);
|
||||
}
|
||||
this.ionFocus.emit(ev);
|
||||
};
|
||||
|
||||
private onBlur = (ev: FocusEvent) => {
|
||||
this.hasFocus = false;
|
||||
this.focusChange();
|
||||
|
||||
if (this.fireFocusEvents) {
|
||||
this.ionBlur.emit(ev);
|
||||
}
|
||||
this.ionBlur.emit(ev);
|
||||
};
|
||||
|
||||
private onKeyDown = () => {
|
||||
|
Reference in New Issue
Block a user