mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-10 00:27:41 +08:00
feat(all): add optional generics typings for overlay component methods (#21393)
This commit is contained in:
committed by
GitHub
parent
c7e94a1f23
commit
5bf83b80d7
@ -139,7 +139,7 @@ export class ActionSheet implements ComponentInterface, OverlayInterface {
|
||||
* Returns a promise that resolves when the action sheet did dismiss.
|
||||
*/
|
||||
@Method()
|
||||
onDidDismiss(): Promise<OverlayEventDetail> {
|
||||
onDidDismiss<T = any>(): Promise<OverlayEventDetail<T>> {
|
||||
return eventMethod(this.el, 'ionActionSheetDidDismiss');
|
||||
}
|
||||
|
||||
@ -148,7 +148,7 @@ export class ActionSheet implements ComponentInterface, OverlayInterface {
|
||||
*
|
||||
*/
|
||||
@Method()
|
||||
onWillDismiss(): Promise<OverlayEventDetail> {
|
||||
onWillDismiss<T = any>(): Promise<OverlayEventDetail<T>> {
|
||||
return eventMethod(this.el, 'ionActionSheetWillDismiss');
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user