Skip to content

refactor: clean up ReplaySubject usages #17804

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 25, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/cdk-experimental/popover-edit/lens-directives.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* found in the LICENSE file at https://angular.io/license
*/

import {ReplaySubject} from 'rxjs';
import {Subject} from 'rxjs';
import {
Directive,
ElementRef,
Expand Down Expand Up @@ -41,7 +41,7 @@ export type PopoverEditClickOutBehavior = 'close' | 'submit' | 'noop';
providers: [EditRef],
})
export class CdkEditControl<FormValue> implements OnDestroy, OnInit {
protected readonly destroyed = new ReplaySubject<void>();
protected readonly destroyed = new Subject<void>();

/**
* Specifies what should happen when the user clicks outside of the edit lens.
Expand Down
8 changes: 4 additions & 4 deletions src/cdk-experimental/popover-edit/table-directives.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import {
ViewContainerRef,
HostListener,
} from '@angular/core';
import {fromEvent, fromEventPattern, merge, ReplaySubject} from 'rxjs';
import {fromEvent, fromEventPattern, merge, Subject} from 'rxjs';
import {
filter,
map,
Expand Down Expand Up @@ -65,7 +65,7 @@ const MOUSE_MOVE_THROTTLE_TIME_MS = 10;
providers: [EditEventDispatcher, EditServices],
})
export class CdkEditable implements AfterViewInit, OnDestroy {
protected readonly destroyed = new ReplaySubject<void>();
protected readonly destroyed = new Subject<void>();

constructor(
protected readonly elementRef: ElementRef,
Expand Down Expand Up @@ -202,7 +202,7 @@ export class CdkPopoverEdit<C> implements AfterViewInit, OnDestroy {

protected focusTrap?: FocusTrap;
protected overlayRef?: OverlayRef;
protected readonly destroyed = new ReplaySubject<void>();
protected readonly destroyed = new Subject<void>();

constructor(
protected readonly services: EditServices, protected readonly elementRef: ElementRef,
Expand Down Expand Up @@ -374,7 +374,7 @@ export class CdkPopoverEditTabOut<C> extends CdkPopoverEdit<C> {
selector: '[cdkRowHoverContent]',
})
export class CdkRowHoverContent implements AfterViewInit, OnDestroy {
protected readonly destroyed = new ReplaySubject<void>();
protected readonly destroyed = new Subject<void>();
protected viewRef: EmbeddedViewRef<any>|null = null;

private _row?: Element;
Expand Down