{ "version": 3, "sources": ["src/app/shared/header/header.service.ts"], "sourcesContent": ["import { Injectable } from \"@angular/core\";\r\nimport { Modal } from \"bootstrap\";\r\nimport { BehaviorSubject, Subject } from \"rxjs\";\r\n\r\nimport { ModalProperties } from \"src/app/constants/ids-modal-constants\";\r\nimport { SharedService } from \"@shared/services/shared.service\";\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HeaderService {\r\n private modalSourse = new BehaviorSubject(null!);\r\n modal = this.modalSourse.asObservable();\r\n\r\n private changeModalSub = new Subject();\r\n changeModal$ = this.changeModalSub.asObservable();\r\n\r\n constructor(\r\n private sharedService: SharedService,\r\n ) {}\r\n\r\n setModal(modal: Modal): void {\r\n this.modalSourse.next(modal);\r\n }\r\n\r\n showAuthModal(): void {\r\n const modal = this.sharedService.invokeModal(ModalProperties.idModalForms);\r\n this.setModal(modal);\r\n this.modal.subscribe(\r\n (value) => {\r\n value?.show();\r\n }\r\n )\r\n }\r\n\r\n setChangeModal(modalName: string): void {\r\n this.changeModalSub.next(modalName);\r\n }\r\n}\r\n"], "mappings": ";;;;;;;;;;;;;;AAWM,IAAO,gBAAP,MAAO,eAAa;EAOxB,YACU,eAA4B;AAA5B,SAAA,gBAAA;AAPF,SAAA,cAAc,IAAI,gBAAuB,IAAK;AACtD,SAAA,QAAQ,KAAK,YAAY,aAAY;AAE7B,SAAA,iBAAiB,IAAI,QAAO;AACpC,SAAA,eAAe,KAAK,eAAe,aAAY;EAI5C;EAEH,SAAS,OAAY;AACnB,SAAK,YAAY,KAAK,KAAK;EAC7B;EAEA,gBAAa;AACX,UAAM,QAAQ,KAAK,cAAc,YAAY,gBAAgB,YAAY;AACzE,SAAK,SAAS,KAAK;AACnB,SAAK,MAAM,UACT,CAAC,UAAS;AACR,aAAO,KAAI;IACb,CAAC;EAEL;EAEA,eAAe,WAAiB;AAC9B,SAAK,eAAe,KAAK,SAAS;EACpC;;;uBA3BW,gBAAa,mBAAA,aAAA,CAAA;IAAA;EAAA;;4EAAb,gBAAa,SAAb,eAAa,WAAA,YAFZ,OAAM,CAAA;EAAA;;", "names": [] }