[faucet] disable pointer when not available, fix unsubscribe()
This commit is contained in:
parent
3bbdf6fb25
commit
9e844ffbbd
@ -41,7 +41,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
@if (!loading) {
|
@if (!loading) {
|
||||||
<form [formGroup]="faucetForm" class="formGroup" (submit)="requestCoins()" [style]="(error || !this.user) ? 'opacity: 0.3' : ''">
|
<form [formGroup]="faucetForm" class="formGroup" (submit)="requestCoins()" [style]="(error || !this.user) ? 'opacity: 0.3; pointer-events: none' : ''">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<div class="form-group mb-0">
|
<div class="form-group mb-0">
|
||||||
|
@ -47,8 +47,13 @@ export class FaucetComponent implements OnInit, OnDestroy {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ngOnDestroy() {
|
ngOnDestroy() {
|
||||||
if (this.faucetStatusSubscription) {
|
this.stateService.markBlock$.next({});
|
||||||
this.faucetStatusSubscription.unsubscribe();
|
this.websocketService.stopTrackingTransaction();
|
||||||
|
if (this.mempoolPositionSubscription) {
|
||||||
|
this.mempoolPositionSubscription.unsubscribe();
|
||||||
|
}
|
||||||
|
if (this.confirmationSubscription) {
|
||||||
|
this.confirmationSubscription.unsubscribe();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user