import { Injectable } from "@angular/core"; import { BehaviorSubject } from "rxjs"; import { MenuItem } from "mirra-ui/api"; @Injectable({ providedIn: "root", }) export class BreadcrumbService { public breadcrumbLabels: BehaviorSubject = new BehaviorSubject([]); public newBreadcrumb: BehaviorSubject = new BehaviorSubject([]); constructor() {} updateBreadcrumbLabels(labels: any) { this.breadcrumbLabels.next(labels); } updateBreadcrumb(newBreadcrumb: MenuItem[]) { this.newBreadcrumb.next(newBreadcrumb); } }