(self["webpackChunkapp"] = self["webpackChunkapp"] || []).push([[2738],{

/***/ 2738:
/*!******************************************************************************************!*\
  !*** ./src/app/create-event/create-event-event-hosts/create-event-event-hosts.module.ts ***!
  \******************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "CreateEventEventHostsPageModule": () => (/* binding */ CreateEventEventHostsPageModule)
/* harmony export */ });
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/common */ 90944);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_angular_common__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/router */ 61380);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_angular_router__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _ionic_angular__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @ionic/angular */ 93819);
/* harmony import */ var _shared_module_shared_module_module__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../shared-module/shared-module.module */ 69270);
/* harmony import */ var _create_event_event_hosts_page__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./create-event-event-hosts.page */ 35000);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/core */ 45449);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(_angular_core__WEBPACK_IMPORTED_MODULE_4__);








// import { FontAwesomeModule } from '@fortawesome/angular-fontawesome';
const routes = [
    {
        path: '',
        component: _create_event_event_hosts_page__WEBPACK_IMPORTED_MODULE_3__.CreateEventEventHostsPage
    }
];
class CreateEventEventHostsPageModule {
}
CreateEventEventHostsPageModule.ɵfac = function CreateEventEventHostsPageModule_Factory(t) { return new (t || CreateEventEventHostsPageModule)(); };
CreateEventEventHostsPageModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_4__["ɵɵdefineNgModule"]({ type: CreateEventEventHostsPageModule });
CreateEventEventHostsPageModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_4__["ɵɵdefineInjector"]({ imports: [_shared_module_shared_module_module__WEBPACK_IMPORTED_MODULE_2__.SharedModuleModule,
        _angular_common__WEBPACK_IMPORTED_MODULE_0__.CommonModule,
        _angular_forms__WEBPACK_IMPORTED_MODULE_5__.FormsModule,
        _ionic_angular__WEBPACK_IMPORTED_MODULE_6__.IonicModule,
        // FontAwesomeModule,
        _angular_router__WEBPACK_IMPORTED_MODULE_1__.RouterModule.forChild(routes)] });
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_4__["ɵɵsetNgModuleScope"](CreateEventEventHostsPageModule, { declarations: [_create_event_event_hosts_page__WEBPACK_IMPORTED_MODULE_3__.CreateEventEventHostsPage], imports: [_shared_module_shared_module_module__WEBPACK_IMPORTED_MODULE_2__.SharedModuleModule,
        _angular_common__WEBPACK_IMPORTED_MODULE_0__.CommonModule,
        _angular_forms__WEBPACK_IMPORTED_MODULE_5__.FormsModule,
        _ionic_angular__WEBPACK_IMPORTED_MODULE_6__.IonicModule, _angular_router__WEBPACK_IMPORTED_MODULE_1__.RouterModule] }); })();


/***/ }),

/***/ 35000:
/*!****************************************************************************************!*\
  !*** ./src/app/create-event/create-event-event-hosts/create-event-event-hosts.page.ts ***!
  \****************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "CreateEventEventHostsPage": () => (/* binding */ CreateEventEventHostsPage)
/* harmony export */ });
/* harmony import */ var _Volumes_case_workspace_work_APPS_KA_APP_WORK_NOW_KA_PASS_V2_2_6_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js */ 71670);
/* harmony import */ var _shared_components__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @shared/components */ 7667);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ 45449);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_angular_core__WEBPACK_IMPORTED_MODULE_2__);
/* harmony import */ var _shared_services__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @shared/services */ 17253);
/* harmony import */ var _ionic_angular__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @ionic/angular */ 93819);
/* harmony import */ var _shared_services_state_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @shared/services/state.service */ 21284);
/* harmony import */ var _shared_services_focus_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @shared/services/focus.service */ 37763);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common */ 90944);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(_angular_common__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var _shared_components_avatar_avatar_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../shared/components/avatar/avatar.component */ 87871);
/* harmony import */ var _shared_components_header_header_component__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../../shared/components/header/header.component */ 36290);
/* harmony import */ var _ngx_translate_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @ngx-translate/core */ 38699);












function CreateEventEventHostsPage_div_16_div_7_ng_container_5_Template(rf, ctx) {
  if (rf & 1) {
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementContainerStart"](0);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](1, "div", 19);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](2);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementContainerEnd"]();
  }

  if (rf & 2) {
    const selectedUser_r2 = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵnextContext"]().$implicit;
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](2);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate"](selectedUser_r2.department);
  }
}

function CreateEventEventHostsPage_div_16_div_7_Template(rf, ctx) {
  if (rf & 1) {
    const _r6 = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵgetCurrentView"]();

    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](0, "div", 14);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵlistener"]("click", function CreateEventEventHostsPage_div_16_div_7_Template_div_click_0_listener() {
      const restoredCtx = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵrestoreView"](_r6);
      const selectedUser_r2 = restoredCtx.$implicit;
      const ctx_r5 = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵnextContext"](2);
      return _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵresetView"](ctx_r5.toggleActions(selectedUser_r2));
    });
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelement"](1, "app-avatar", 15);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](2, "div", 16)(3, "div", 17);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](4);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtemplate"](5, CreateEventEventHostsPage_div_16_div_7_ng_container_5_Template, 3, 1, "ng-container", 18);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]()();
  }

  if (rf & 2) {
    const selectedUser_r2 = ctx.$implicit;
    const ctx_r1 = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵnextContext"](2);
    let tmp_2_0;
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](1);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵproperty"]("firstName", selectedUser_r2.firstName)("lastName", selectedUser_r2.lastName)("thumbnailImage", (tmp_2_0 = (tmp_2_0 = selectedUser_r2 == null ? null : selectedUser_r2.photos == null ? null : selectedUser_r2.photos[0] == null ? null : selectedUser_r2.photos[0].faceImageThumbnail) !== null && tmp_2_0 !== undefined ? tmp_2_0 : selectedUser_r2 == null ? null : selectedUser_r2.thumbnailImage) !== null && tmp_2_0 !== undefined ? tmp_2_0 : null)("size", "md");
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](3);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate1"](" ", ctx_r1.helperService.normalizeName(selectedUser_r2.firstName, selectedUser_r2.lastName), " ");
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](1);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵproperty"]("ngIf", selectedUser_r2.department);
  }
}

function CreateEventEventHostsPage_div_16_Template(rf, ctx) {
  if (rf & 1) {
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](0, "div", 10)(1, "div", 11);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](2);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](3, "translate");
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](4, "div", 12);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](5);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](6, "translate");
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtemplate"](7, CreateEventEventHostsPage_div_16_div_7_Template, 6, 6, "div", 13);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]();
  }

  if (rf & 2) {
    const ctx_r0 = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵnextContext"]();
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](2);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate"](_angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](3, 3, "PG_CREATE_HOSTS_STEP_TEXT_HOSTS"));
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](3);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate"](_angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](6, 5, "PG_CREATE_HOSTS_STEP_TEXT_TAP_ITEM_EDIT"));
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](2);
    _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵproperty"]("ngForOf", ctx_r0.selectedUsers);
  }
}

class CreateEventEventHostsPage {
  constructor(createEventService, navigationService, modalController, helperService, actionSheetController, apiService, pendingRelease, notificatorService, translateConfigService, stateService, focusService, userPhotoService) {
    var _this = this;

    this.createEventService = createEventService;
    this.navigationService = navigationService;
    this.modalController = modalController;
    this.helperService = helperService;
    this.actionSheetController = actionSheetController;
    this.apiService = apiService;
    this.pendingRelease = pendingRelease;
    this.notificatorService = notificatorService;
    this.translateConfigService = translateConfigService;
    this.stateService = stateService;
    this.focusService = focusService;
    this.userPhotoService = userPhotoService;
    this.existPendings = false;

    this.navigateToQRCode = () => {
      this.navigationService.root(['/home']);
    };

    this.navigateToPendingLiberations = () => {
      this.navigationService.forward(['/push-notifications']);
    };

    this.addUserToSelectedUsers = user => {
      if (!this.verifyForRepetition(user)) {
        this.selectedUsers.push(user);
      }
    };

    this.removeUserFromSelectedUsers = user => {
      this.selectedUsers = this.selectedUsers.filter(selectedUser => selectedUser.id !== user.id);
    };

    this.verifyForRepetition = user => this.selectedUsers.find(selectedUser => selectedUser.id === user.id);

    this.openAddUserModal = /*#__PURE__*/(0,_Volumes_case_workspace_work_APPS_KA_APP_WORK_NOW_KA_PASS_V2_2_6_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_0__["default"])(function* () {
      const modal = yield _this.modalController.create({
        component: _shared_components__WEBPACK_IMPORTED_MODULE_1__.SelectorForHostsToAddToEventComponent
      });
      modal.onDidDismiss().then(_this.onModalDismissCallback);
      yield modal.present();
    });

    this.onModalDismissCallback = detail => {
      if (detail && detail.data) {
        this.addUserToSelectedUsers(detail.data);
      }
    };

    this.goOneStepBack = () => {
      this.createEventService.setHosts(this.selectedUsers);

      if (this.canBeEdited()) {
        // this.navigationService.back(['/create-event-event-start-date-time']);
        this.navigationService.back(['/create-event-event-bookei']);
      } else {
        this.navigationService.forward(['/events']);
      }
    };

    this.goToNextStep = () => {
      const hosts = this.selectedUsers;

      if (hosts.length) {
        this.createEventService.setHosts(this.selectedUsers);

        if (this.createEventService.getAction() === 'approve-event-review' && !this.approveEventReview) {
          this.goToEventResumeStep();
        } else {
          this.goToAddGuestsStep();
        }
      } else {
        const notification = {
          title: this.translateConfigService.translate('PG_CREATE_HOSTS_TOAST_ERROR_TITLE'),
          message: this.translateConfigService.translate('PG_CREATE_HOSTS_TOAST_MESSAGE_ERROR'),
          type: 'error'
        };
        this.notificatorService.notify(notification);
      }
    };

    this.goToAddGuestsStep = () => {
      this.navigationService.forward(['/create-event-event-guests']);
    };

    this.goToEventResumeStep = () => {
      const isExistEventId = !this.createEventService.getIsNew();
      const event = {
        id: this.createEventService.getId(),
        title: this.createEventService.getTitle(),
        startAt: this.createEventService.getStartDate(),
        endAt: this.createEventService.getEndDate(),
        floor: this.createEventService.getSelectedFloor(),
        group: this.createEventService.getSelectedGroup(),
        hosts: this.createEventService.getHosts(),
        guests: this.createEventService.getGuests(),
        multiCheckin: this.createEventService.getMultiCheckIn(),
        allowCompanion: this.createEventService.getCompanionAllowed(),
        needAuthorization: this.createEventService.getNeedAuthorization(),
        checkinStartAt: this.createEventService.getCheckInStartAt(),
        bookeis: this.createEventService.getBookings(),
        bookeisToCancel: this.existIdEvent ? this.createEventService.getBookeisToCancel() : []
      };
      const navigationExtras = {
        state: {
          event,
          isLimitedProfile: false
        }
      };
      console.log('router HOSTS', event);
      this.navigationService.forward(['/create-event-event-resume'], navigationExtras);
    };

    this.canBeEdited = () => !this.createEventService.getGuests().find(g => g.status !== 'WAITING_FOR_CHECKIN' && g.status !== 'WAITING_FOR_EVENT_APPROVE');

    this.toggleActions = /*#__PURE__*/function () {
      var _ref2 = (0,_Volumes_case_workspace_work_APPS_KA_APP_WORK_NOW_KA_PASS_V2_2_6_node_modules_babel_runtime_helpers_esm_asyncToGenerator_js__WEBPACK_IMPORTED_MODULE_0__["default"])(function* (selectedUser) {
        const actionSheet = yield _this.actionSheetController.create({
          header: _this.translateConfigService.translate('ACTION_SHEET_HEADER'),
          cssClass: '',
          buttons: [{
            text: _this.translateConfigService.translate('ACTION_SHEET_BTN_REMOVE'),
            role: 'destructive',
            icon: 'trash',
            handler: () => {
              _this.removeUserFromSelectedUsers(selectedUser);
            }
          }, {
            text: _this.translateConfigService.translate('ACTION_SHEET_BTN_BACK'),
            icon: 'arrow-back',
            role: 'cancel',
            handler: () => {}
          }]
        });
        yield actionSheet.present();
      });

      return function (_x) {
        return _ref2.apply(this, arguments);
      };
    }();

    this.existIdEvent = !this.createEventService.getIsNew();
    this.approveEventReview = this.isApproveEventReview();
  }

  ngOnInit() {
    let selectedUsers = this.createEventService.getHosts();
    selectedUsers = selectedUsers ? selectedUsers : [];
    this.selectedUsers = selectedUsers;
    this.userPhotoService.enrichUsersWithPhotos(this.selectedUsers);
  }

  ionViewWillEnter() {
    this.focusService.applyFocusQuerySelector('create_event_hosts', 3500);
  }

  ionViewDidEnter() {//this.verifyNotifications;
  }

  ionViewDidLeave() {}

  isApproveEventReview() {
    return this.createEventService.getApproveEventReview() ? true : false;
  }

}

CreateEventEventHostsPage.ɵfac = function CreateEventEventHostsPage_Factory(t) {
  return new (t || CreateEventEventHostsPage)(_angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.CreateEventService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.NavigationService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_ionic_angular__WEBPACK_IMPORTED_MODULE_9__.ModalController), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.HelperService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_ionic_angular__WEBPACK_IMPORTED_MODULE_9__.ActionSheetController), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.ApiService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.PendingReleaseService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.NotificatorService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.TranslateConfigService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services_state_service__WEBPACK_IMPORTED_MODULE_4__.StateService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services_focus_service__WEBPACK_IMPORTED_MODULE_5__.FocusService), _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdirectiveInject"](_shared_services__WEBPACK_IMPORTED_MODULE_3__.UserPhotoService));
};

CreateEventEventHostsPage.ɵcmp = /*@__PURE__*/_angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdefineComponent"]({
  type: CreateEventEventHostsPage,
  selectors: [["app-create-event-event-hosts"]],
  decls: 26,
  vars: 19,
  consts: [["defaultHref", "create-event-event-start-date-time", 3, "title", "showBadge", "refresh", "menuToggle"], [1, "centralized-content"], [1, "page-title"], ["id", "create_event_hosts", "tabindex", "1", 1, "sub-title"], [1, "add-user"], [3, "click"], ["class", "results", 4, "ngIf"], [1, "button-holder"], ["type", "button", 1, "back", 3, "click"], ["type", "submit", 3, "click"], [1, "results"], [1, "title"], [1, "sub-title"], ["class", "result", 3, "click", 4, "ngFor", "ngForOf"], [1, "result", 3, "click"], [3, "firstName", "lastName", "thumbnailImage", "size"], [1, "user-info"], [1, "full-name"], [4, "ngIf"], [1, "document"]],
  template: function CreateEventEventHostsPage_Template(rf, ctx) {
    if (rf & 1) {
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelement"](0, "app-header", 0);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](1, "translate");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](2, "ion-content")(3, "div", 1)(4, "div", 2)(5, "div", 3);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](6);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](7, "translate");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]()();
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](8, "ion-row")(9, "ion-col")(10, "div", 4)(11, "button", 5);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵlistener"]("click", function CreateEventEventHostsPage_Template_button_click_11_listener() {
        return ctx.openAddUserModal();
      });
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](12);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](13, "translate");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]()()()();
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](14, "ion-row")(15, "ion-col");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtemplate"](16, CreateEventEventHostsPage_div_16_Template, 8, 7, "div", 6);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]()();
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](17, "ion-row")(18, "ion-col")(19, "div", 7)(20, "button", 8);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵlistener"]("click", function CreateEventEventHostsPage_Template_button_click_20_listener() {
        return ctx.goOneStepBack();
      });
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](21);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](22, "translate");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]();
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementStart"](23, "button", 9);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵlistener"]("click", function CreateEventEventHostsPage_Template_button_click_23_listener() {
        return ctx.goToNextStep();
      });
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtext"](24);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipe"](25, "translate");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵelementEnd"]()()()()()();
    }

    if (rf & 2) {
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵproperty"]("title", _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](1, 9, "PG_CREATE_HOSTS_STEP_HEADER_TITLE"))("showBadge", true)("refresh", false)("menuToggle", false);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](6);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate1"](" ", _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](7, 11, "PG_CREATE_HOSTS_STEP_TEXT_SUBTITLE"), " ");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](6);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate1"](" ", _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](13, 13, "PG_CREATE_HOSTS_STEP_BTN_ADD_HOST"), " ");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](4);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵproperty"]("ngIf", !!ctx.selectedUsers.length);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](5);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate1"](" ", _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](22, 15, "BTN_BACK"), " ");
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵadvance"](3);
      _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵtextInterpolate"](_angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵpipeBind1"](25, 17, "BTN_NEXT"));
    }
  },
  dependencies: [_angular_common__WEBPACK_IMPORTED_MODULE_6__.NgForOf, _angular_common__WEBPACK_IMPORTED_MODULE_6__.NgIf, _ionic_angular__WEBPACK_IMPORTED_MODULE_9__.IonCol, _ionic_angular__WEBPACK_IMPORTED_MODULE_9__.IonContent, _ionic_angular__WEBPACK_IMPORTED_MODULE_9__.IonRow, _shared_components_avatar_avatar_component__WEBPACK_IMPORTED_MODULE_7__.AvatarComponent, _shared_components_header_header_component__WEBPACK_IMPORTED_MODULE_8__.HeaderComponent, _ngx_translate_core__WEBPACK_IMPORTED_MODULE_10__.TranslatePipe],
  styles: ["ion-content[_ngcontent-%COMP%] {\n  --background: #f1f1f1;\n}\n\nion-toolbar[_ngcontent-%COMP%] {\n  font-family: \"Nunito\", sans-serif;\n}\n\nion-toolbar[_ngcontent-%COMP%]   ion-img[_ngcontent-%COMP%] {\n  height: 25px;\n  width: 25px;\n}\n\nion-toolbar[_ngcontent-%COMP%]   ion-title[_ngcontent-%COMP%] {\n  letter-spacing: 1px;\n}\n\nion-toolbar[_ngcontent-%COMP%]   ion-button[_ngcontent-%COMP%]   fa-icon[_ngcontent-%COMP%] {\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  height: 24px;\n  padding: 0;\n  width: 24px;\n  margin: 0;\n  font-size: 19px;\n  color: #656768;\n}\n\nion-toolbar[_ngcontent-%COMP%]   ion-button.hover[_ngcontent-%COMP%] {\n  background: #fff;\n}\n\n.centralized-content[_ngcontent-%COMP%] {\n  height: calc(100vh - 56px);\n  display: flex;\n  justify-content: flex-start;\n  flex-direction: column;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .page-title[_ngcontent-%COMP%] {\n  margin-top: 30px;\n  margin-bottom: 26px;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .page-title[_ngcontent-%COMP%]   .title[_ngcontent-%COMP%] {\n  font-size: initial !important;\n  font-weight: bold;\n  text-align: center;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .page-title[_ngcontent-%COMP%]   .sub-title[_ngcontent-%COMP%] {\n  text-align: center;\n  color: #656768;\n  font-size: 0.9em;\n  margin-top: 4px;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .input-holder[_ngcontent-%COMP%] {\n  margin-top: 8px;\n  padding: 0 18px;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .add-user[_ngcontent-%COMP%] {\n  display: flex;\n  align-content: center;\n  justify-content: center;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .add-user[_ngcontent-%COMP%]   button[_ngcontent-%COMP%] {\n  padding: 0.75em 1.5em;\n  border-radius: 50px;\n  background-color: #0ec254;\n  color: #fff;\n  font-size: 1em;\n  transition: background-color 0.1s ease-out;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .add-user[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:active {\n  background-color: #fff;\n  color: #0ec254;\n  transition: background-color 0.1s ease-out;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .add-user[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]:focus {\n  outline: none;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%] {\n  margin-top: 1.5em;\n  padding: 0 18px;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%]   .title[_ngcontent-%COMP%] {\n  font-size: initial !important;\n  margin: 0 0 6px;\n  font-weight: bold;\n  text-align: center;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%]   .sub-title[_ngcontent-%COMP%] {\n  margin: 10px auto;\n  font-size: 0.9em;\n  background-color: #eee;\n  padding: 6px;\n  border-radius: 2px;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%]   .result[_ngcontent-%COMP%] {\n  margin: 0 0 4px;\n  border: 1px solid #eee;\n  border-radius: 4px;\n  padding: 4px 10px;\n  background-color: #fff;\n  display: flex;\n  align-items: center;\n  gap: 10px;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%]   .result[_ngcontent-%COMP%]   app-avatar[_ngcontent-%COMP%] {\n  flex-shrink: 0;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%]   .result[_ngcontent-%COMP%]   .user-info[_ngcontent-%COMP%] {\n  flex: 1;\n  min-width: 0;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .results[_ngcontent-%COMP%]   .result[_ngcontent-%COMP%]   .document[_ngcontent-%COMP%] {\n  font-size: 0.8em;\n  color: #aaa;\n}\n\n.centralized-content[_ngcontent-%COMP%]   .button-holder[_ngcontent-%COMP%] {\n  padding: 0 18px;\n}\n\n.pulsate-fwd[_ngcontent-%COMP%] {\n  animation: pulsate-fwd 0.5s ease-in-out infinite both;\n  outline: none;\n}\n\n@keyframes pulsate-fwd {\n  0% {\n    transform: scale(1);\n  }\n  50% {\n    transform: scale(1.5);\n  }\n  100% {\n    transform: scale(1);\n  }\n}\n/*# sourceMappingURL=data:application/json;base64,[encoded data, 5172 characters] */"]
});

/***/ }),

/***/ 37763:
/*!**************************************************!*\
  !*** ./src/app/shared/services/focus.service.ts ***!
  \**************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "FocusService": () => (/* binding */ FocusService)
/* harmony export */ });
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/router */ 61380);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_angular_router__WEBPACK_IMPORTED_MODULE_0__);
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs/operators */ 59151);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ 45449);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_angular_core__WEBPACK_IMPORTED_MODULE_1__);




class FocusService {
    constructor(router) {
        this.router = router;
    }
    focusInRouterNavigate() {
        this.router.events.pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_2__.filter)(event => event instanceof _angular_router__WEBPACK_IMPORTED_MODULE_0__.NavigationEnd)).subscribe(() => {
            const mainHeader = document.querySelector('#focusHeader');
            if (mainHeader) {
                mainHeader?.focus();
            }
        });
    }
    /**
     *
     * @param selector ID preference selector exemple: this.applyFocusQuerySelector('myselectorid', 300)
     * not necessary # .
     * @param time
     */
    applyFocusQuerySelector(selector, time) {
        setTimeout(() => {
            const nextTag = document.querySelector(`#${selector}`);
            nextTag?.focus();
        }, time);
    }
}
FocusService.ɵfac = function FocusService_Factory(t) { return new (t || FocusService)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_router__WEBPACK_IMPORTED_MODULE_0__.Router)); };
FocusService.ɵprov = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"]({ token: FocusService, factory: FocusService.ɵfac, providedIn: 'root' });


/***/ })

}])
//# sourceMappingURL=2738.js.map