fix(overlays): make them hidden until presented (#16903)

fixes #16685
This commit is contained in:
Manu MA
2018-12-29 01:31:33 +01:00
committed by GitHub
parent 3d656ac312
commit 302be5392c
25 changed files with 35 additions and 219 deletions

View File

@ -39,6 +39,10 @@
z-index: $z-index-overlay;
}
:host(.overlay-hidden) {
display: none;
}
.loading-wrapper {
display: flex;

View File

@ -91,16 +91,6 @@ export class Loading implements ComponentInterface, OverlayInterface {
*/
@Prop() animated = true;
/**
* Emitted after the loading has unloaded.
*/
@Event() ionLoadingDidUnload!: EventEmitter<void>;
/**
* Emitted after the loading has loaded.
*/
@Event() ionLoadingDidLoad!: EventEmitter<void>;
/**
* Emitted after the loading has presented.
*/
@ -127,14 +117,6 @@ export class Loading implements ComponentInterface, OverlayInterface {
}
}
componentDidLoad() {
this.ionLoadingDidLoad.emit();
}
componentDidUnload() {
this.ionLoadingDidUnload.emit();
}
@Listen('ionBackdropTap')
protected onBackdropTap() {
this.dismiss(undefined, BACKDROP);

View File

@ -108,9 +108,7 @@ async function presentLoadingWithOptions() {
| Event | Description | Type |
| ----------------------- | ----------------------------------------- | --------------------------------- |
| `ionLoadingDidDismiss` | Emitted after the loading has dismissed. | `CustomEvent<OverlayEventDetail>` |
| `ionLoadingDidLoad` | Emitted after the loading has loaded. | `CustomEvent<void>` |
| `ionLoadingDidPresent` | Emitted after the loading has presented. | `CustomEvent<void>` |
| `ionLoadingDidUnload` | Emitted after the loading has unloaded. | `CustomEvent<void>` |
| `ionLoadingWillDismiss` | Emitted before the loading has dismissed. | `CustomEvent<OverlayEventDetail>` |
| `ionLoadingWillPresent` | Emitted before the loading has presented. | `CustomEvent<void>` |