"use strict";
(self["webpackChunkproject"] = self["webpackChunkproject"] || []).push([[247],{

/***/ 8792:
/*!*****************************************************************************!*\
  !*** ./src/app/appointment/documents/components/layout/layout.component.ts ***!
  \*****************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   DocumentsLayoutComponent: () => (/* binding */ DocumentsLayoutComponent)
/* harmony export */ });
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! rxjs */ 2714);
/* harmony import */ var src_app_shared_appointments_models_appointment__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! src/app/shared/appointments/models/appointment */ 8723);
/* harmony import */ var src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! src/app/shared/documents/models/document */ 735);
/* harmony import */ var src_app_shared_ui_pipes_order_by_pipe__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! src/app/shared/ui/pipes/order-by.pipe */ 9093);
/* harmony import */ var src_app_main_models_navigation__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/main/models/navigation */ 821);
/* harmony import */ var src_app_shared_contact_information_models_contact_information__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! src/app/shared/contact-information/models/contact-information */ 904);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/core */ 4380);
/* harmony import */ var src_app_shared_ui_services_ui_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! src/app/shared/ui/services/ui.service */ 345);
/* harmony import */ var src_app_shared_documents_services_document_service__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! src/app/shared/documents/services/document.service */ 3040);
/* harmony import */ var src_app_shared_navigation_services_device_route_service__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! src/app/shared/navigation/services/device-route.service */ 2405);
/* harmony import */ var src_app_appointment_services_appointment_service__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! src/app/appointment/services/appointment.service */ 7427);
/* harmony import */ var src_app_shared_appointments_services_appointment_service__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! src/app/shared/appointments/services/appointment.service */ 8036);
/* harmony import */ var _shared_documents_components_appointment_document_appointment_document_component__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ../../../../shared/documents/components/appointment-document/appointment-document.component */ 6488);
/* harmony import */ var _shared_documents_components_consent_consent_component__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ../../../../shared/documents/components/consent/consent.component */ 3528);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @angular/common */ 6216);

/* Models */


/* Pipes */













const _c0 = ["componentElm"];
function DocumentsLayoutComponent_ng_container_2_appointment_document_1_Template(rf, ctx) {
  if (rf & 1) {
    const _r1 = _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵgetCurrentView"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](0, "appointment-document", 14);
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵlistener"]("changed", function DocumentsLayoutComponent_ng_container_2_appointment_document_1_Template_appointment_document_changed_0_listener() {
      _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵrestoreView"](_r1);
      const document_r2 = _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵnextContext"]().$implicit;
      const ctx_r2 = _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵnextContext"]();
      return _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵresetView"](ctx_r2.documentChanged(document_r2));
    });
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementEnd"]();
  }
  if (rf & 2) {
    const document_r2 = _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵnextContext"]().$implicit;
    const ctx_r2 = _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵnextContext"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵproperty"]("appointmentContent", ctx_r2.content)("document", document_r2);
  }
}
function DocumentsLayoutComponent_ng_container_2_Template(rf, ctx) {
  if (rf & 1) {
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementContainerStart"](0);
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵtemplate"](1, DocumentsLayoutComponent_ng_container_2_appointment_document_1_Template, 1, 2, "appointment-document", 13);
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementContainerEnd"]();
  }
  if (rf & 2) {
    const document_r2 = ctx.$implicit;
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵproperty"]("ngIf", document_r2.active);
  }
}
let DocumentsLayoutComponent = /*#__PURE__*/(() => {
  class DocumentsLayoutComponent {
    constructor(uiService, documentService, deviceRouteService, localAppointmentService, appointmentService, orderByPipe) {
      this.uiService = uiService;
      this.documentService = documentService;
      this.deviceRouteService = deviceRouteService;
      this.localAppointmentService = localAppointmentService;
      this.appointmentService = appointmentService;
      this.orderByPipe = orderByPipe;
      // #endregion
      // #region Documents
      this.retrievingDocuments = false;
      this.activeDocumentIndex = 0;
      this.displayDocuments = [];
      // #endregion
      // #region Consent
      this.consenting = false;
      this.consenters = new rxjs__WEBPACK_IMPORTED_MODULE_13__.Subject();
      // #endregion
      // #region Navigation
      this.backLabel = "Previous Document";
      this.forwardLabel = "Next Document";
      this.back = new rxjs__WEBPACK_IMPORTED_MODULE_13__.Subject();
      this.complete = new rxjs__WEBPACK_IMPORTED_MODULE_13__.Subject();
      this.canGoBack = false;
      this.canGoForward = false;
    }
    generatePrice() {
      if (this.appointment?.price) {
        return {
          details: this.appointment.price.details,
          customItems: this.appointment.price.customItems,
          price: this.appointment.price.finalPrice
        };
      }
      return undefined;
    }
    generatePayments() {
      const payments = [];
      if (this.appointment?.paymentSetting != null) {
        const details = this.orderByPipe.transform(this.appointment.paymentSetting.details, "priority", false);
        details.forEach(detail => {
          const payment = {
            description: detail.name,
            amount: detail.amount
          };
          payments.push(payment);
        });
      }
      return payments;
    }
    generateContent() {
      if (this.appointment != null) {
        const content = {
          appointmentId: this.appointment.id,
          created_Utc: this.appointment.scheduled_Utc,
          lastUpdated_Utc: new Date(),
          scheduled_Utc: this.appointment.scheduled_Utc,
          property: this.appointment.property,
          jobId: this.appointment.jobId?.toString(),
          job: this.appointment.job,
          consultant: this.appointment.assignedTo,
          customer: this.appointment.customer,
          price: this.generatePrice(),
          documents: this.displayDocuments,
          payments: this.generatePayments(),
          recipient: undefined,
          completed: false
        };
        this.content = content;
      }
    }
    documentChanged(document) {
      this.appointment?.changed$.next();
      this.updateSigners();
      this.setNavigation();
    }
    updateSigners() {
      window.clearTimeout(this.signerDebounce);
      this.signerDebounce = window.setTimeout(() => {
        const signers = [];
        for (var i = 0, len = this.displayDocuments.length; i < len; i++) {
          const document = this.displayDocuments[i];
          for (var j = 0, jlen = document.signers.length; j < jlen; j++) {
            const signer = document.signers[j];
            const existingSigner = signers.find(x => x.fullName == signer.fullName);
            if (existingSigner == null) {
              signers.push(signer);
            } else {
              if (existingSigner.initials_B64 == null && signer.initials_B64 == null) {
                existingSigner.initials_B64 = signer.initials_B64;
              }
              if (existingSigner.signature_B64 == null && signer.signature_B64 == null) {
                existingSigner.signature_B64 = signer.signature_B64;
              }
            }
          }
          document.signers = signers;
        }
      }, 500);
    }
    generateSigners(document) {
      const signers = [];
      let customerAdded = false;
      let consultantAdded = false;
      if (document.mapping != null) {
        for (var i = 0, len = document.mapping.pages.length; i < len; i++) {
          const page = document.mapping.pages[i];
          for (var j = 0, jlen = page.fields.length; j < jlen; j++) {
            const field = page.fields[j];
            if ((field.id?.includes("initial.customer") || field.id?.includes("signature.customer")) && !customerAdded) {
              if (this.appointment?.customer != null) {
                const fullName = `${this.appointment.customer.firstName} ${this.appointment.customer.lastName}`;
                const email = this.appointment.customer.contactInformation.find(x => x.type == src_app_shared_contact_information_models_contact_information__WEBPACK_IMPORTED_MODULE_4__.ContactInformationType.Email);
                const phone = this.appointment.customer.contactInformation.find(x => x.type == src_app_shared_contact_information_models_contact_information__WEBPACK_IMPORTED_MODULE_4__.ContactInformationType.CellPhone);
                const signer = new src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSigner(fullName, phone?.value, email?.value, src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSignerType.Customer);
                signers.push(signer);
                customerAdded = true;
              }
            }
            if ((field.id?.includes("initial.consultant") || field.id?.includes("signature.consultant")) && !consultantAdded) {
              if (this.appointment?.assignedTo != null) {
                const fullName = `${this.appointment.assignedTo.firstName} ${this.appointment.assignedTo.lastName}`;
                const email = this.appointment.assignedTo.emailAddress;
                const phone = this.appointment.assignedTo.phone;
                const signer = new src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSigner(fullName, phone, email, src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSignerType.Consultant);
                signers.push(signer);
                consultantAdded = true;
              }
            }
          }
        }
      }
      if (document.content != null) {
        if ((document.content.includes("initial.customer") || document.content.includes("signature.customer")) && !customerAdded) {
          if (this.appointment?.customer != null) {
            const fullName = `${this.appointment.customer.firstName} ${this.appointment.customer.lastName}`;
            const email = this.appointment.customer.contactInformation.find(x => x.type == src_app_shared_contact_information_models_contact_information__WEBPACK_IMPORTED_MODULE_4__.ContactInformationType.Email);
            const phone = this.appointment.customer.contactInformation.find(x => x.type == src_app_shared_contact_information_models_contact_information__WEBPACK_IMPORTED_MODULE_4__.ContactInformationType.CellPhone);
            const signer = new src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSigner(fullName, phone?.value, email?.value, src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSignerType.Customer);
            signers.push(signer);
            customerAdded = true;
          }
        }
        if ((document.content.includes("initial.consultant") || document.content.includes("signature.consultant")) && !consultantAdded) {
          if (this.appointment?.assignedTo != null) {
            const fullName = `${this.appointment.assignedTo.firstName} ${this.appointment.assignedTo.lastName}`;
            const email = this.appointment.assignedTo.emailAddress;
            const phone = this.appointment.assignedTo.phone;
            const signer = new src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSigner(fullName, phone, email, src_app_shared_documents_models_document__WEBPACK_IMPORTED_MODULE_1__.DocumentSignerType.Consultant);
            signers.push(signer);
            consultantAdded = true;
          }
        }
      }
      return signers;
    }
    initDocuments() {
      if (this.appointment != null) {
        let documents = [];
        for (var i = 0, len = this.appointment.documents.length; i < len; i++) {
          const document = this.appointment.documents[i];
          document.active = false;
          document.executedDocument = undefined;
          document.executedDocument_B64 = undefined;
          document.executedHash = undefined;
          // document.generatedContent = undefined;
          if (document.customerFacing) {
            if (document.executedDocument_B64 == null && document.signers.length == 0) {
              document.signers = this.generateSigners(document);
            }
            documents.push(document);
          }
        }
        documents = this.orderByPipe.transform(documents, "displayOrder", false);
        this.displayDocuments = documents;
        this.setActiveDocument(0);
        this.verifyConsent();
      }
    }
    setActiveDocument(index) {
      const document = this.displayDocuments[index];
      this.displayDocuments.forEach(document => {
        document.active = false;
      });
      if (document != null) {
        document.active = true;
      }
      this.activeDocument = document;
      this.activeDocumentIndex = index;
      setTimeout(() => {
        this.setNavigation();
      }, 500);
    }
    finalizeConsent(consenters) {
      if (consenters.length > 0) {
        this.appointment?.documents.forEach(document => {
          document.signers = consenters;
        });
      }
      this.consenting = false;
      this.appointment?.changed$.next();
    }
    verifyConsent() {
      const consenters = [];
      for (var i = 0, len = this.displayDocuments.length; i < len; i++) {
        const document = this.displayDocuments[i];
        for (var j = 0, jlen = document.signers.length; j < jlen; j++) {
          const signer = document.signers[j];
          if (signer.consent == null) {
            const existingConsenter = consenters.find(x => x.fullName == signer.fullName);
            if (existingConsenter == null) {
              consenters.push(signer);
            }
          }
        }
      }
      this.consenters.next(consenters);
      if (consenters.length > 0) {
        this.consenting = true;
      } else {
        this.consenting = false;
      }
    }
    setNavigation() {
      window.clearTimeout(this.navigationDebounce);
      this.navigationDebounce = window.setTimeout(() => {
        const missingDocuments = null; // this.displayDocuments.find(x => x.executedHash == null);
        const nextDocument = this.displayDocuments[this.activeDocumentIndex + 1];
        if (nextDocument != null) {
          this.forwardLabel = "Next Document";
          this.canGoForward = true;
        } else if (missingDocuments == null) {
          this.forwardLabel = "Finish & Leave Appointment";
          this.canGoForward = true;
        } else {
          this.canGoForward = false;
        }
        if (this.activeDocument != null) {
          const previousDocument = this.displayDocuments[this.activeDocumentIndex - 1];
          if (previousDocument != null) {
            this.canGoBack = true;
          } else {
            this.canGoBack = false;
          }
        }
      }, 150);
    }
    goBack() {
      const previousDocument = this.displayDocuments[this.activeDocumentIndex - 1];
      if (previousDocument != null) {
        this.setActiveDocument(this.activeDocumentIndex - 1);
      } else {
        this.back.next();
      }
    }
    goForward() {
      const nextDocument = this.displayDocuments[this.activeDocumentIndex + 1];
      if (nextDocument != null) {
        this.setActiveDocument(this.activeDocumentIndex + 1);
        this.canGoForward = false;
      } else {
        this.uiService.prompt("Ready to Leave the Appointment?", "", "Yes", "No, Go Back").subscribe({
          next: confirmed => {
            if (confirmed) {
              if (this.appointment != null) {
                this.appointment.dispositionStatus = undefined;
                this.appointment.status = src_app_shared_appointments_models_appointment__WEBPACK_IMPORTED_MODULE_0__.AppointmentStatus.PendingSubmission;
                this.appointment.changed$.next();
              }
              this.deviceRouteService.viewRouteByType(src_app_main_models_navigation__WEBPACK_IMPORTED_MODULE_3__.MainRouteType.Dashboard, [], true);
            }
          }
        });
      }
    }
    init() {
      this.generateContent();
      this.initDocuments();
    }
    // #endregion
    ngAfterViewInit() {
      setTimeout(() => {
        this.init();
        setTimeout(() => {
          if (this.route != null) {
            this.route.initialized.next();
          }
        }, 32);
      }, 16);
    }
    ngOnDestroy() {}
    static #_ = (() => this.ɵfac = function DocumentsLayoutComponent_Factory(__ngFactoryType__) {
      return new (__ngFactoryType__ || DocumentsLayoutComponent)(_angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdirectiveInject"](src_app_shared_ui_services_ui_service__WEBPACK_IMPORTED_MODULE_5__.UiService), _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdirectiveInject"](src_app_shared_documents_services_document_service__WEBPACK_IMPORTED_MODULE_6__.DocumentService), _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdirectiveInject"](src_app_shared_navigation_services_device_route_service__WEBPACK_IMPORTED_MODULE_7__.DeviceRouteService), _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdirectiveInject"](src_app_appointment_services_appointment_service__WEBPACK_IMPORTED_MODULE_8__.LocalAppointmentService), _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdirectiveInject"](src_app_shared_appointments_services_appointment_service__WEBPACK_IMPORTED_MODULE_9__.AppointmentService), _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdirectiveInject"](src_app_shared_ui_pipes_order_by_pipe__WEBPACK_IMPORTED_MODULE_2__.OrderByPipe));
    })();
    static #_2 = (() => this.ɵcmp = /*@__PURE__*/_angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵdefineComponent"]({
      type: DocumentsLayoutComponent,
      selectors: [["ng-component"]],
      viewQuery: function DocumentsLayoutComponent_Query(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵviewQuery"](_c0, 5);
        }
        if (rf & 2) {
          let _t;
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵqueryRefresh"](_t = _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵloadQuery"]()) && (ctx.componentElm = _t.first);
        }
      },
      inputs: {
        appointment: "appointment",
        route: "route"
      },
      outputs: {
        back: "back",
        complete: "complete"
      },
      standalone: false,
      features: [_angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵProvidersFeature"]([src_app_shared_ui_pipes_order_by_pipe__WEBPACK_IMPORTED_MODULE_2__.OrderByPipe])],
      decls: 17,
      vars: 7,
      consts: [["id", "documentsLayout"], [1, "documents"], [4, "ngFor", "ngForOf"], ["id", "consent"], [1, "bg"], [3, "close", "consenters"], ["id", "mainNav"], [1, "island"], [1, "controls"], [1, "control", 3, "click"], [1, "fa-solid", "fa-arrow-left-long"], [1, "control", "success", 3, "click", "disabled"], [1, "fa-solid", "fa-arrow-right-long"], [3, "appointmentContent", "document", "changed", 4, "ngIf"], [3, "changed", "appointmentContent", "document"]],
      template: function DocumentsLayoutComponent_Template(rf, ctx) {
        if (rf & 1) {
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](0, "main", 0)(1, "div", 1);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵtemplate"](2, DocumentsLayoutComponent_ng_container_2_Template, 2, 1, "ng-container", 2);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementEnd"]()();
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](3, "aside", 3);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelement"](4, "div", 4);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](5, "signing-consent", 5);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵlistener"]("close", function DocumentsLayoutComponent_Template_signing_consent_close_5_listener($event) {
            return ctx.finalizeConsent($event);
          });
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementEnd"]()();
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](6, "nav", 6)(7, "div", 7)(8, "div", 8)(9, "button", 9);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵlistener"]("click", function DocumentsLayoutComponent_Template_button_click_9_listener() {
            return ctx.goBack();
          });
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelement"](10, "i", 10);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](11, "label");
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵtext"](12);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementEnd"]()();
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](13, "button", 11);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵlistener"]("click", function DocumentsLayoutComponent_Template_button_click_13_listener() {
            return ctx.goForward();
          });
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelement"](14, "i", 12);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementStart"](15, "label");
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵtext"](16);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵelementEnd"]()()()()();
        }
        if (rf & 2) {
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"](2);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵproperty"]("ngForOf", ctx.displayDocuments);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"]();
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵclassProp"]("active", ctx.consenting);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"](2);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵproperty"]("consenters", ctx.consenters);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"](7);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵtextInterpolate"](ctx.backLabel);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"]();
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵproperty"]("disabled", !ctx.canGoForward);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵadvance"](3);
          _angular_core__WEBPACK_IMPORTED_MODULE_12__["ɵɵtextInterpolate"](ctx.forwardLabel);
        }
      },
      dependencies: [_shared_documents_components_appointment_document_appointment_document_component__WEBPACK_IMPORTED_MODULE_10__.AppointmentDocumentComponent, _shared_documents_components_consent_consent_component__WEBPACK_IMPORTED_MODULE_11__.ConsentComponent, _angular_common__WEBPACK_IMPORTED_MODULE_14__.NgForOf, _angular_common__WEBPACK_IMPORTED_MODULE_14__.NgIf],
      styles: ["@keyframes _ngcontent-%COMP%_documentLoadIn {\n  0% {\n    opacity: 0;\n  }\n  100% {\n    opacity: 1;\n  }\n}\n#documentsLayout[_ngcontent-%COMP%] {\n  z-index: 0;\n  font-size: 0;\n}\n#documentsLayout[_ngcontent-%COMP%]    > .documents[_ngcontent-%COMP%]   appointment-document[_ngcontent-%COMP%]     .document {\n  position: absolute;\n  top: calc(var(--systemOffset-top) + 6vw);\n  left: 2vw;\n  right: 2vw;\n  bottom: calc(var(--systemOffset-bottom) + 7vw);\n  border: 0.2vw var(--color2Alt3) solid;\n  border-radius: 1vw;\n  background-color: var(--color2);\n  display: block;\n  overflow-x: hidden;\n}\n\n#consent[_ngcontent-%COMP%] {\n  pointer-events: none;\n}\n#consent[_ngcontent-%COMP%]    > .bg[_ngcontent-%COMP%] {\n  position: absolute;\n  top: 0;\n  left: 0;\n  right: 0;\n  bottom: 0;\n  z-index: var(--sideNav-layer);\n  opacity: 0;\n  background-color: rgba(var(--color1-raw), 0.4);\n  -webkit-backdrop-filter: blur(0.5vw);\n  -moz-backdrop-filter: blur(0.5vw);\n  -o-backdrop-filter: blur(0.5vw);\n  backdrop-filter: blur(0.5vw);\n  transition: opacity 0.2s linear;\n}\n#consent[_ngcontent-%COMP%]    > signing-consent[_ngcontent-%COMP%] {\n  display: block;\n  position: fixed;\n  top: 50%;\n  left: 50%;\n  transform: translate(-50%, -50%);\n  background-color: var(--color2);\n  border: 0.1vw var(--color2Alt2) solid;\n  width: 40vw;\n  border-radius: 1vw;\n  z-index: calc(var(--sideNav-layer) + 2);\n  opacity: 0;\n  overflow: hidden;\n  box-shadow: 0 0.2vw 1vw rgba(var(--black-raw), 0.1);\n  transition: opacity 0.2s linear;\n}\n#consent.active[_ngcontent-%COMP%] {\n  pointer-events: initial;\n}\n#consent.active[_ngcontent-%COMP%]    > .bg[_ngcontent-%COMP%] {\n  opacity: 1;\n}\n#consent.active[_ngcontent-%COMP%]    > signing-consent[_ngcontent-%COMP%] {\n  opacity: 1;\n}\n\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%] {\n  position: absolute;\n  bottom: 1vw;\n  right: 1vw;\n  z-index: calc(var(--navLayer) + 1);\n  background-color: var(--color2);\n  border-radius: 999px;\n  padding: 0.5vw 1vw;\n  opacity: 1;\n  transition: opacity 0.25s 0.25s;\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%] {\n  display: flex;\n  align-items: center;\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%] {\n  position: relative;\n  margin-left: 1vw;\n  padding: 0.8vw 2vw;\n  border-radius: 999px;\n  cursor: pointer;\n  margin-left: 1vw;\n  display: flex;\n  align-items: center;\n  background-color: var(--color3);\n  border: 0.1vw transparent solid;\n  transition: background-color 0.1s linear;\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]    > i[_ngcontent-%COMP%]:last-child, #mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]    > label[_ngcontent-%COMP%]:last-child {\n  margin-left: 0.5vw;\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]    > i[_ngcontent-%COMP%] {\n  font-size: 1.2vw;\n  color: var(--color2);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]    > label[_ngcontent-%COMP%] {\n  font-size: 1.2vw;\n  color: var(--color2);\n  font-weight: var(--strong);\n  line-height: 1;\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control.success[_ngcontent-%COMP%] {\n  background-color: var(--success);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control.alternate[_ngcontent-%COMP%] {\n  background-color: var(--color2);\n  border-color: var(--color1);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control.alternate[_ngcontent-%COMP%]    > label[_ngcontent-%COMP%] {\n  color: var(--color1);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[disabled][_ngcontent-%COMP%] {\n  opacity: 0.6;\n  pointer-events: none;\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]:active {\n  background-color: var(--color3Alt4);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]:active.success {\n  background-color: var(--successAlt4);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]:active.alternate {\n  background-color: var(--color2Alt2);\n}\n#mainNav[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%]    > .controls[_ngcontent-%COMP%]    > .control[_ngcontent-%COMP%]:first-child {\n  margin-left: 0;\n}\n#mainNav.hidden[_ngcontent-%COMP%]    > .island[_ngcontent-%COMP%] {\n  opacity: 0;\n  pointer-events: none;\n  transition: opacity 0.25s linear;\n}\n/*# sourceMappingURL=data:application/json;charset=utf-8;base64,  */"]
    }))();
  }
  return DocumentsLayoutComponent;
})();

/***/ }),

/***/ 1247:
/*!***********************************************************!*\
  !*** ./src/app/appointment/documents/documents.module.ts ***!
  \***********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   DocumentsModule: () => (/* binding */ DocumentsModule)
/* harmony export */ });
/* harmony import */ var _angular_elements__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/elements */ 3440);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common */ 6216);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 8143);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 8335);
/* harmony import */ var _components_layout_layout_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./components/layout/layout.component */ 8792);
/* harmony import */ var src_app_shared_ui_ui_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! src/app/shared/ui/ui.module */ 663);
/* harmony import */ var src_app_shared_documents_documents_module__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! src/app/shared/documents/documents.module */ 3749);
/* harmony import */ var src_app_shared_navigation_services_internal_route_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! src/app/shared/navigation/services/internal-route.service */ 8858);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/core */ 4380);




/* Components */

/* Shared Modules */


/* Services */


let DocumentsModule = /*#__PURE__*/(() => {
  class DocumentsModule {
    constructor(injector) {
      this.injector = injector;
      this.ngDoBootstrap();
    }
    ngDoBootstrap() {
      const el = (0,_angular_elements__WEBPACK_IMPORTED_MODULE_4__.createCustomElement)(_components_layout_layout_component__WEBPACK_IMPORTED_MODULE_0__.DocumentsLayoutComponent, {
        injector: this.injector
      });
      customElements.define('appointment-documents', el);
    }
    static #_ = (() => this.ɵfac = function DocumentsModule_Factory(__ngFactoryType__) {
      return new (__ngFactoryType__ || DocumentsModule)(_angular_core__WEBPACK_IMPORTED_MODULE_5__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_5__.Injector));
    })();
    static #_2 = (() => this.ɵmod = /*@__PURE__*/_angular_core__WEBPACK_IMPORTED_MODULE_5__["ɵɵdefineNgModule"]({
      type: DocumentsModule
    }))();
    static #_3 = (() => this.ɵinj = /*@__PURE__*/_angular_core__WEBPACK_IMPORTED_MODULE_5__["ɵɵdefineInjector"]({
      providers: [src_app_shared_navigation_services_internal_route_service__WEBPACK_IMPORTED_MODULE_3__.InternalRouteService, (0,_angular_common_http__WEBPACK_IMPORTED_MODULE_6__.provideHttpClient)((0,_angular_common_http__WEBPACK_IMPORTED_MODULE_6__.withInterceptorsFromDi)())],
      imports: [src_app_shared_ui_ui_module__WEBPACK_IMPORTED_MODULE_1__.UiModule, src_app_shared_documents_documents_module__WEBPACK_IMPORTED_MODULE_2__.SharedDocumentsModule, _angular_common__WEBPACK_IMPORTED_MODULE_7__.CommonModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.ReactiveFormsModule]
    }))();
  }
  return DocumentsModule;
})();
(function () {
  (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_5__["ɵɵsetNgModuleScope"](DocumentsModule, {
    declarations: [_components_layout_layout_component__WEBPACK_IMPORTED_MODULE_0__.DocumentsLayoutComponent],
    imports: [src_app_shared_ui_ui_module__WEBPACK_IMPORTED_MODULE_1__.UiModule, src_app_shared_documents_documents_module__WEBPACK_IMPORTED_MODULE_2__.SharedDocumentsModule, _angular_common__WEBPACK_IMPORTED_MODULE_7__.CommonModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.ReactiveFormsModule]
  });
})();

/***/ })

}]);
//# sourceMappingURL=247.js.map