Browse Source

[PM-29875] Close Send drawer on navigation

pull/18031/head
Mike Amirault 1 week ago
parent
commit
3762d4c36d
No known key found for this signature in database
  1. 1
      apps/web/src/app/tools/send/send.component.ts
  2. 5
      libs/components/src/dialog/dialog.service.ts

1
apps/web/src/app/tools/send/send.component.ts

@ -119,6 +119,7 @@ export class SendComponent extends BaseSendComponent implements OnInit, OnDestro
ngOnDestroy() { ngOnDestroy() {
this.dialogService.closeAll(); this.dialogService.closeAll();
this.dialogService.closeDrawer();
this.broadcasterService.unsubscribe(BroadcasterSubscriptionId); this.broadcasterService.unsubscribe(BroadcasterSubscriptionId);
} }

5
libs/components/src/dialog/dialog.service.ts

@ -300,6 +300,11 @@ export class DialogService {
return this.dialog.closeAll(); return this.dialog.closeAll();
} }
/** Close the open drawer */
closeDrawer(): void {
return this.activeDrawer?.close();
}
/** The injector that is passed to the opened dialog */ /** The injector that is passed to the opened dialog */
private createInjector(opts: { data: unknown; dialogRef: DialogRef }): Injector { private createInjector(opts: { data: unknown; dialogRef: DialogRef }): Injector {
return Injector.create({ return Injector.create({

Loading…
Cancel
Save