Prerequisites
Describe the Feature Request
The default buttons of ion-datetime close the nearest overlay without supplying a role (=undefined).
When I await the onDidDismiss Promise I can't distinguish between submit and cancel.
see here
As a workaround I would have to supply my own Buttons instead of using the default buttons.
Describe the Use Case
this.modalIonDateTime.present();
const dtResult = await this.modalIonDateTime.onDidDismiss();
// dtResult.role is undefined. Unable to proceed with follow-up logic
<ion-modal [keepContentsMounted]="true">
<ng-template>
<ion-datetime formControlName="ionDateTimeCtrl" [presentation]="type"
[showDefaultButtons]="true" [locale]="(appLanguage.value | async)?.languageCode"
[cancelText]="'GLOBAL_CANCEL' | translate" [doneText]="'GLOBAL_OK' | translate">
</ion-datetime>
</ng-template>
</ion-modal>
Describe Preferred Solution
No response
Describe Alternatives
No response
Related Code
No response
Additional Information
No response
Prerequisites
Describe the Feature Request
The default buttons of ion-datetime close the nearest overlay without supplying a role (=undefined).
When I await the
onDidDismissPromise I can't distinguish between submit and cancel.see here
As a workaround I would have to supply my own Buttons instead of using the default buttons.
Describe the Use Case
Describe Preferred Solution
No response
Describe Alternatives
No response
Related Code
No response
Additional Information
No response