openaire-library/sharedComponents/quick-contact/quick-contact.service.ts

17 lines
416 B
TypeScript

import { Injectable } from "@angular/core";
import { BehaviorSubject, Observable } from "rxjs";
@Injectable({
providedIn: "root"
})
export class QuickContactService {
private display: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false);
public get isDisplayed(): Observable<boolean> {
return this.display.asObservable();
}
public setDisplay(display: boolean) {
this.display.next(display);
}
}