{"version":3,"sources":["components/common/Scheduler/AppointmentsScheduler/Header/css.module.css","components/common/Scheduler/AppointmentsScheduler/TimeLine/css.module.css","models/import-excel-response.ts","assets/images/whatsapp-background.jpg","components/common/Scheduler/AppointmentsScheduler/Content/ContentGrid/css.module.css","components/common/Scheduler/AppointmentsScheduler/Content/css.module.css","components/common/Scheduler/AppointmentsScheduler/css.module.css","components/common/Scheduler/Cursor/css.module.css","assets/images/treatment-preview-signature.png","registerServiceWorker.js","constants/local-storage-key.ts","redux/authentication-slice.ts","redux/application-interface-slice.ts","redux/navbar-slice.ts","redux/blocked-schedule-slice.ts","redux/multiple-blocked-schedule-slice.ts","redux/scheduler-slice.ts","redux/alerts-slice.ts","constants/url.ts","redux/common-hub-slice.ts","models/user-info.ts","redux/user-info-slice.ts","api/api-client.ts","redux/whatsapp-hub-slice.ts","models/country.ts","redux/account-settings-slice.ts","redux/establishment-settings-slice.ts","models/interfaces/cash-register-current-state-model.ts","models/cash-register-movement-history.ts","redux/cash-register-slice.ts","redux/schedule-appointment-time-slice.ts","redux/enterprise-slice.ts","redux/file-downloader-slice.ts","redux/store.ts","redux/hooks.ts","i18n.tsx","assets/icons/ArrowLeftIcon.tsx","assets/icons/ArrowRightIcon.tsx","assets/icons/CashRegisterIcon.tsx","assets/icons/ComputerIcon.tsx","assets/icons/BanIcon.tsx","assets/icons/DotIcon.tsx","assets/icons/DocumentIcon.tsx","assets/icons/ConversationIcon.tsx","models/enums/customer-frequency-type.ts","assets/icons/StatusIcon.tsx","assets/icons/SortDownIcon.tsx","assets/icons/SortUpIcon.tsx","assets/icons/SortIcon.tsx","assets/icons/GroupIcon.tsx","assets/icons/GroupAppointmentsIcon.tsx","assets/icons/PersonIcon.tsx","assets/icons/ImportIcon.tsx","assets/icons/SuccessIcon.tsx","assets/icons/ErrorIcon.tsx","assets/icons/EstablishmentIcon.tsx","assets/icons/MinusArrow.tsx","assets/icons/PhoneIcon.tsx","assets/icons/NoteIcon.tsx","assets/icons/EditIcon.tsx","assets/icons/ExportIcon.tsx","assets/icons/ExportFileIcon.tsx","assets/icons/SaveIcon.tsx","assets/icons/CrossIcon.tsx","assets/icons/PlusIcon.tsx","assets/icons/DeleteIcon.tsx","assets/icons/MenuIconWhatsapp.tsx","assets/icons/MenuIconSettings.tsx","assets/icons/MenuIconReports.tsx","assets/icons/MenuIconCustomer.tsx","assets/icons/MenuIconLogoClear.tsx","assets/icons/MenuIconPower.tsx","assets/icons/MercadoPagoIcon.tsx","assets/icons/OxxoIcon.tsx","assets/icons/TrashIcon.tsx","assets/icons/FlagIcon.tsx","assets/icons/NotesIcon.tsx","assets/icons/MoneyIcon.tsx","assets/icons/CalendarCancelIcon.tsx","assets/icons/MegaphoneIcon.tsx","assets/icons/FiltersIcon.tsx","assets/icons/DoorIcon.tsx","assets/icons/ExclamationIcon.tsx","assets/icons/BroadcastIcon.tsx","assets/icons/ArrowDropDownIcon.tsx","assets/icons/ExcelIcon.tsx","assets/icons/UploadFileCloud.tsx","assets/icons/DownloadCloudIcon.tsx","assets/icons/AddCustomerIcon.tsx","assets/icons/FlatImageIcon.tsx","assets/icons/InfoIcon.tsx","assets/icons/ArrowLineDown.tsx","assets/icons/CalendarIcon.tsx","assets/icons/CalendarIcon2.tsx","assets/icons/InfoCircleIcon.tsx","assets/icons/CameraIcon.tsx","assets/icons/SearchIcon.tsx","assets/icons/PDFIcon.tsx","assets/icons/CashIcon.tsx","assets/icons/CreditCardIcon.tsx","assets/icons/BankIcon.tsx","assets/icons/LogoIcon.tsx","assets/icons/DownloadFileCloud.tsx","assets/icons/CheckIcon.tsx","assets/icons/CalendarNotificationIcon.tsx","assets/icons/ScreenNotificationIcon.tsx","assets/icons/WhatsAppNotificationIcon.tsx","assets/icons/DotsVerticalIcon.tsx","assets/icons/ClockIcon.tsx","assets/icons/MenuIcon.tsx","assets/icons/SideArrowForMessageIcon.tsx","assets/icons/AdminIcon.tsx","constants/colors.ts","assets/icons/ArrowDownIcon.tsx","assets/icons/ListPlusIcon.tsx","assets/icons/UserIcon.tsx","assets/icons/BellIcon.tsx","assets/icons/DollarSignNotificationIcon.tsx","assets/icons/WhatsAppPDFIcon.tsx","assets/icons/WhatsAppVideoIcon.tsx","assets/icons/WhatsAppPlayVideoIcon.tsx","assets/icons/WhatsAppPlayAudioIcon.tsx","assets/icons/WhatsAppMicrophoneIcon.tsx","assets/icons/WhatsAppAudioLogo.tsx","assets/icons/VideoCameraEmptyIcon.tsx","assets/icons/VideoCameraFilledIcon.tsx","assets/icons/LinkIcon.tsx","assets/icons/CalendarCheckmarkIcon.tsx","assets/icons/PersonCheckmarkIcon.tsx","assets/icons/PersonSpeechBalloonIcon.tsx","assets/icons/SectionNewIcon.tsx","assets/icons/SectionArrowIcon.tsx","assets/icons/SectionEditIcon.tsx","assets/icons/SectionDeleteIcon.tsx","assets/icons/SectionFieldNewIcon.tsx","assets/icons/DraggableIcon.tsx","assets/icons/SectionFieldTextIcon.tsx","assets/icons/SectionFieldDropdownIcon.tsx","assets/icons/SectionFieldRadioIcon.tsx","assets/icons/SectionFieldCheckboxIcon.tsx","assets/icons/SectionFieldNumericIcon.tsx","assets/icons/SectionFieldDateIcon.tsx","assets/icons/SectionFieldPhoneIcon.tsx","assets/icons/SectionFieldCheckboxItemIcon.tsx","assets/icons/SectionFieldDropdownItemIcon.tsx","assets/icons/SectionFieldOptionalTextFieldIcon.tsx","assets/icons/SectionFieldRadioItemIcon.tsx","assets/icons/SectionSaveIcon.tsx","assets/icons/SectionExitEditIcon.tsx","assets/icons/SectionItemEmailIcon.tsx","assets/icons/SuggestedServicesIcon.tsx","assets/icons/MedicalBookIcon.tsx","assets/icons/PatientAppointmentsIcon.tsx","assets/icons/PatientContactIcon.tsx","assets/icons/PatientFemaleIcon.tsx","assets/icons/PatientGeneralDataIcon.tsx","assets/icons/PatientMaleIcon.tsx","assets/icons/PatientServicesIcon.tsx","assets/icons/InternalNotesIcon.tsx","assets/icons/WordIcon.tsx","assets/icons/ImageIcon.tsx","assets/icons/PatientStethoscopeIcon.tsx","assets/icons/RoundCheckmarkIcon.tsx","assets/icons/ListMarkIcon.tsx","assets/icons/EyeIcon.tsx","assets/icons/WarningIcon.tsx","assets/icons/BillsIcon.tsx","assets/icons/BillIcon.tsx","assets/icons/TimeLimitIcon.tsx","assets/icons/SheetIcon.tsx","assets/icons/ListIcon.tsx","assets/icons/PenIcon.tsx","assets/icons/CopyIcon.tsx","assets/icons/ReportPersonIcon.tsx","assets/icons/CloseIcon.tsx","assets/icons/CheckboxCheckedIcon.tsx","assets/icons/CheckboxUncheckedIcon.tsx","assets/icons/CaptionImageMediaIcon.tsx","assets/icons/WhatsAppDocumentIcon.tsx","assets/icons/CaptionDocumentMediaIcon.tsx","assets/icons/SectionGearIcon.tsx","assets/icons/BlockIcon.tsx","assets/icons/StopHandIcon.tsx","components/navbar/NavBar/css.tsx","api/authentication-service.ts","components/navbar/notifications/NotificationBlock/css.ts","components/navbar/notifications/NotificationHeader/css.ts","components/navbar/notifications/NotificationHeader/notification-header.tsx","components/navbar/notifications/NotificationFooter/css.ts","models/enums/notification-type.ts","components/common/ProgressRingWithIcon/css.ts","components/common/ProgressRingWithIcon/progress-ring-with-icon.tsx","components/navbar/notifications/NotificationFooter/notification-footer.tsx","components/navbar/notifications/NotificationItem/css.ts","models/enums/appointment-created-by.ts","models/enums/appointment-status.ts","models/enums/appointment-payment-status.ts","models/appointment.ts","models/appointment-service-model.ts","models/appointment-available-hours.ts","models/create-appointment-model.ts","models/appointment-blocker.ts","models/appointment-tooltip-model.ts","models/enums/conversation-message-type.ts","api/appointment-service.ts","assets/icons/CustomerRequiresQuoteNotificationIcon.tsx","components/navbar/notifications/NotificationItem/notification-item.tsx","models/notification-entity.ts","api/notifications-service.ts","models/conversations-counter-model.ts","constants/business.ts","components/navbar/notifications/NotificationBlock/notification-block.tsx","components/common/AccountOverdueMessage/css.ts","components/common/AccountOverdueMessage/account-overdue-message.tsx","components/navbar/cash-register/CashRegisterIcon/css.ts","components/navbar/cash-register/CashRegisterIcon/cash-register-icon.tsx","components/navbar/cash-register/OpenCashRegisterModal/css.ts","components/common/Input/css.ts","hooks/useCurrencyValueTemplate/use-currency-value-template.ts","components/common/InputCurrency/input-currency.tsx","components/common/IconTooltip/css.ts","components/common/IconTooltip/icon-tooltip.tsx","models/enums/button-props-border-side.ts","models/enums/button-props-fill.ts","models/enums/button-props-color.ts","models/enums/button-props-border-radius.ts","components/common/ButtonWithSpinner/css.ts","components/common/ButtonWithSpinner/button-with-spinner.tsx","components/navbar/cash-register/OpenCashRegisterModal/open-cash-register-modal.tsx","models/open-cash-register-form-data.ts","components/navbar/cash-register/CashRegisterSidebar/css.ts","components/navbar/cash-register/CashStateHeader/css.ts","components/navbar/cash-register/CashStateHeader/cash-state-header.tsx","models/enums/cash-register-movement-type.ts","components/common/Radio/css.ts","components/common/Radio/radio.tsx","components/common/Textarea/css.ts","components/common/Textarea/textarea.tsx","models/close-cash-register-request.ts","models/register-cash-register-movement-request.ts","models/enums/payment-method-type.ts","components/navbar/cash-register/CashRegisterSidebar/cash-register-sidebar.tsx","models/appointment-payment-part-entity.ts","models/appointment-payment-entity.ts","models/appointment-payment-form-data.ts","api/payments-service.ts","models/open-cash-register-request.ts","components/navbar/cash-register/CashRegisterMain/cash-register-main.tsx","assets/icons/ExternalLink.tsx","hooks/useCustomerTerminology/use-customer-terminology.ts","components/navbar/Title/css.ts","components/navbar/Title/title.tsx","components/navbar/NavBar/navbar.tsx","components/navbar/LoaderLine/css.ts","components/navbar/LoaderLine/loaderLine.tsx","components/common/FileDownloadProvider/css.ts","components/common/FileDownloadProvider/file-download-provider.tsx","components/Layout.tsx","components/authentication/Login/css.ts","assets/images/logo.svg","assets/images/ornament-left.svg","assets/images/ornament-right.svg","components/authentication/AuthenticationLayout/css.ts","components/authentication/AuthenticationLayout/authentication-layout.tsx","components/authentication/EmailInput/css.ts","components/authentication/EmailInput/email-input.tsx","components/authentication/PasswordInput/css.ts","components/authentication/PasswordInput/password-input.tsx","constants/validator.ts","models/enums/appointment-time-interval-gap-minute.ts","models/enums/scheduler-block-duration-minute.ts","models/terminology.ts","models/account-schedule-section-settings-model.ts","models/enums/treatment-document-size.ts","models/establishment-certification.ts","models/treatment-document-field-settings-model.ts","api/account-service.ts","components/authentication/Login/login.tsx","components/authentication/Recovery/css.ts","components/authentication/SuccessBlock/css.ts","components/authentication/SuccessBlock/success-block.tsx","components/authentication/Recovery/recovery.tsx","components/authentication/ResetPassword/css.ts","components/authentication/ResetPassword/use-password-validation.ts","components/authentication/ResetPassword/reset-password.tsx","components/authentication/Join/css.ts","components/authentication/Join/join.tsx","components/authentication/AuthenticationRouter/authentication-router.tsx","components/common/Scheduler/mui/SMenu.tsx","components/common/Scheduler/mui/SMenuItem.tsx","components/common/Scheduler/ScheduleAppointmentActionsMenu/context.ts","components/common/Scheduler/ScheduleAppointmentActionsMenu/index.tsx","components/common/Scheduler/AppointmentsScheduler/_util.tsx","components/common/Scheduler/AppointmentsScheduler/Content/ContentGrid/index.tsx","components/common/Scheduler/AppointmentsScheduler/Content/index.tsx","components/common/Scheduler/AppointmentsScheduler/Header/index.tsx","components/common/Scheduler/DateTimeHelpers.ts","components/common/Scheduler/AppointmentsScheduler/TimeLine/index.tsx","components/common/Scheduler/AppointmentsScheduler/index.tsx","components/common/Scheduler/AbsenceItem/AbsenceBlock/css.ts","components/common/Scheduler/AbsenceItem/AbsenceBlock/index.tsx","components/common/Scheduler/AbsenceItem/AbsenceItem.tsx","components/common/Scheduler/AppointmentItem/AppointmentCard/css.ts","components/common/Scheduler/AppointmentItem/AppointmentCard/index.tsx","components/appointments/AppointmentDeleteModal/css.ts","components/appointments/AppointmentDeleteModal/appointment-delete-modal.tsx","components/common/TextareaWithLabel/css.ts","components/common/TextareaWithLabel/textarea-with-label.tsx","models/service.ts","models/response.ts","models/select-group-service-model.ts","models/service-group-model.ts","api/settings-services-service.ts","models/create-follow-up-model.ts","constants/mask.ts","components/appointments/AppointmentFollowUp/css.ts","assets/flags/CountryAllIcon.tsx","assets/flags/CountryDEUIcon.tsx","assets/flags/CountryAGOIcon.tsx","assets/flags/CountryARGIcon.tsx","assets/flags/CountryBOLIcon.tsx","assets/flags/CountryBRAIcon.tsx","assets/flags/CountryCANIcon.tsx","assets/flags/CountryCHLIcon.tsx","assets/flags/CountryCOLIcon.tsx","assets/flags/CountryCRIIcon.tsx","assets/flags/CountryECUIcon.tsx","assets/flags/CountryESPIcon.tsx","assets/flags/CountryGBRIcon.tsx","assets/flags/CountryUSAIcon.tsx","assets/flags/CountryGTMIcon.tsx","assets/flags/CountryHNDIcon.tsx","assets/flags/CountryMEXIcon.tsx","assets/flags/CountryNICIcon.tsx","assets/flags/CountryPANIcon.tsx","assets/flags/CountryPRYIcon.tsx","assets/flags/CountryPERIcon.tsx","assets/flags/CountryPRTIcon.tsx","assets/flags/CountryDOMIcon.tsx","assets/flags/CountrySLVIcon.tsx","assets/flags/CountryTTOIcon.tsx","assets/flags/CountryURYIcon.tsx","assets/flags/CountryVENIcon.tsx","assets/flags/CountryCUBIcon.tsx","assets/flags/CountryAUSIcon.tsx","assets/flags/CountryBELIcon.tsx","assets/flags/CountryNORIcon.tsx","assets/flags/CountryPRIIcon.tsx","assets/flags/CountrySWEIcon.tsx","assets/flags/CountrySVKIcon.tsx","assets/flags/CountryFRAIcon.tsx","assets/flags/CountryITAIcon.tsx","assets/flags/index.tsx","components/common/InputEditableItem/input-editable-item.tsx","components/appointments/AppointmentFollowUp/appointment-follow-up.tsx","components/appointments/AppointmentItemTooltip/css.ts","components/appointments/AppointmentPaymentSidebar/css.ts","components/common/SelectKey/css.ts","components/common/SelectKey/select-key.tsx","components/common/InputEditableItem/css.ts","components/common/InputEditableWithSelectItem/css.ts","models/enums/discount-type.ts","components/common/InputEditableWithSelectItem/input-editable-with-select-item.tsx","components/common/Select/css.ts","components/common/Select/select.tsx","components/common/InputDateWithLabel/css.ts","models/enums/payment-edition-type.ts","components/common/InputDateWithLabel/input-date-with-label.tsx","components/appointments/AppointmentPaymentParts/css.ts","components/appointments/AppointmentPaymentPart/css.ts","components/appointments/AppointmentPaymentPart/appointment-payment-part.tsx","components/appointments/AppointmentPaymentParts/appointment-payment-parts.tsx","components/appointments/AppointmentPaymentPartsEdit/css.ts","components/appointments/AppointmentPaymentPartsEdit/appointment-payment-parts-edit.tsx","components/appointments/AppointmentPaymentSidebar/appointment-payment-sidebar.tsx","api/appointment-payment-service.ts","components/appointments/RecurringAppointmentDeleteModal/css.ts","models/enums/custom-recurrence-mode.ts","models/enums/week-days-flags.ts","components/appointments/RecurringAppointmentDeleteModal/recurring-appointment-delete-modal.tsx","components/appointments/AppointmentStatusSelector/css.ts","components/appointments/AppointmentStatusSelector/appointment-status-selector.tsx","components/appointments/AppointmentItemTooltip/appointment-item-tooltip.tsx","components/common/Scheduler/styles/Colors.ts","components/common/Scheduler/AppointmentItem/AppointmentTicket/index.tsx","components/common/Scheduler/styles/ScrollbarStyles.ts","components/common/Scheduler/AppointmentItem/AppointmentItemList/css.tsx","components/common/Scheduler/AppointmentItem/AppointmentItemList/index.tsx","components/common/Scheduler/AppointmentItem/AppointmentItem.tsx","components/common/Scheduler/AppointmentItem/index.tsx","components/common/Scheduler/ColumnDecorations/index.tsx","components/common/Scheduler/Cursor/index.tsx","components/common/Scheduler/AppointmentsScheduler/StopComponent.tsx","components/common/Scheduler/_common.tsx","components/common/Scheduler/css.ts","components/common/Scheduler/WeekScheduler/HeaderCellComponent.tsx","components/common/Scheduler/styles/ColorHelpers.ts","components/common/Scheduler/DragNDropConfirmationModal/css.ts","components/common/Scheduler/DragNDropConfirmationModal/drag-n-drop-confirmation-modal.tsx","components/common/Scheduler/TdComponent.tsx","hooks/useLocalStorageState/use-local-storage-state.tsx","components/common/Scheduler/AppointmentGroupingCorner/css.ts","components/common/Scheduler/AppointmentGroupingCorner/AppointmentGroupingCorner.tsx","components/common/Scheduler/WeekScheduler/index.tsx","components/common/Scheduler/DayScheduler/HeaderCellComponent.tsx","components/common/Scheduler/DayScheduler/_context.ts","components/common/Scheduler/DayScheduler/index.tsx","models/blocked-schedule.ts","api/blocked-schedule-service.ts","models/users-response.ts","models/enums/user-commission-type.ts","models/enums/commission-type.ts","models/user-model.ts","models/user-general-info.ts","models/user-schedule-info.ts","models/user-services-info.ts","models/user-commission-info.ts","models/user-permissions-info.ts","models/user-professional-info.ts","models/user-entity.ts","models/is-user-phone-duplicated-response.ts","models/is-user-email-duplicated-response.ts","api/user-service.ts","components/appointments/AppointmentListToolbar/css.ts","components/common/MultiSelect/props.ts","components/common/MultiSelect/css.ts","components/common/InputSearch/css.ts","components/common/InputSearch/input-search.tsx","components/common/CheckboxWithLabel/css.ts","components/common/CheckboxWithLabel/checkbox-with-label.tsx","components/common/MultiSelect/select.tsx","components/common/DateIcon/css.ts","components/common/DateIcon/date-icon.tsx","components/navbar/EstablishmentSelector/css.ts","components/navbar/EstablishmentSelector/establishment-selector.tsx","components/common/Input/input.tsx","components/appointments/AppointmentListToolbar/appointment-list-toolbar.tsx","components/appointments/BlockScheduleModal/css.ts","components/common/SelectWithLabel/css.ts","components/common/SelectWithLabel/select-with-label.tsx","components/common/Switch/css.ts","components/common/Switch/switch.tsx","models/blocked-reason.ts","api/blocked-reason-service.ts","components/appointments/BlockedReasonSelect/css.ts","components/appointments/BlockedReasonSelect/blocked-reason-select.tsx","components/common/DateInput/css.ts","components/common/DateInput/date-input.tsx","components/appointments/BlockedScheduleForm/css.ts","models/enums/weekdays.ts","components/common/InputWithLabel/css.ts","components/common/InputWithLabel/input-with-label.tsx","components/appointments/BlockedScheduleForm/blocked-schedule-form.tsx","components/appointments/BlockScheduleModal/block-schedule-modal.tsx","components/appointments/AppointmentList/css.ts","models/weekday.ts","api/settings-weekdays-service.ts","components/appointments/MultipleBlockedScheduleModal/css.ts","components/appointments/MultipleBlockedScheduleModal/multiple-blocked-schedule-modal.tsx","components/appointments/AppointmentDragAndDropScheduleBusyModal/css.ts","components/appointments/AppointmentDragAndDropScheduleBusyModal/appointment-drag-and-drop-schedule-busy-modal.tsx","components/appointments/AppointmentList/appointment-list.tsx","models/create-appointment-service.ts","models/select-work-area-model.ts","models/workarea.ts","api/settings-workareas-service.ts","hooks/useDebounce/use-debounce.ts","components/common/SelectSearch/css.ts","components/common/SelectSearch/select-search.tsx","components/appointments/AppointmentService/css.ts","components/appointments/AppointmentService/appointment-service.tsx","components/appointments/AppointmentServices/css.ts","components/appointments/AppointmentServices/appointment-services.tsx","components/appointments/AppointmentStepOne/css.ts","components/appointments/AppointmentStepOne/appointment-step-one.tsx","assets/images/calendar-notime.svg","models/enums/appointment-recurrence-interval.ts","components/appointments/AppointmentStepTwo/css.ts","components/appointments/CustomRecurrenceModal/css.ts","components/common/ConfirmActionModal/css.ts","components/common/ConfirmActionModal/confirm-action-modal.tsx","models/recurrence-modal-data.ts","components/common/CircleCheckbox/css.ts","components/common/CircleCheckbox/circle-checkbox.tsx","components/appointments/CustomRecurrenceModal/custom-recurrence-modal.tsx","components/appointments/AppointmentStepTwo/appointment-step-two.tsx","models/enums/gender.ts","components/common/Autocomplete/autocomplete.tsx","components/common/InputMobileCode/css.ts","components/common/InputMobileCode/input-mobile-code.tsx","models/customer-entity.ts","components/customers/CustomerGeneral/css.ts","components/customers/CustomerNotifications/css.ts","components/customers/CustomerNotifications/customer-notifications.tsx","components/customers/CustomerGeneral/customer-general.tsx","models/enums/section-field-type.ts","models/customer-data.ts","models/customers-response.ts","models/customer-info-details.ts","models/customer-search.ts","models/customer-history.ts","models/patient-data-response.ts","models/patient-general-info-response.ts","models/form-field-item-value.ts","models/form-radio-value.ts","models/form-phone-number-value.ts","models/evolution-notes-grouped.ts","models/file-upload-response.ts","models/update-patient-form-data-response.ts","models/customer-clinical-file.ts","models/evolution-note-response.ts","models/patient-clinical-history-tab-data-response.ts","models/customer-by-id-response.ts","models/emergency-contact.ts","models/customer-appointment.ts","api/customer-service.ts","components/customers/CustomerModal/css.ts","components/customers/CustomerModal/customer-modal.tsx","components/appointments/AppointmentCustomerSection/css.ts","components/appointments/AppointmentCustomerSection/CustomerLastAppointmentsBlock/css.ts","components/appointments/AppointmentCustomerSection/CustomerLastAppointmentsBlock/customer-last-appointments-block.tsx","components/appointments/AppointmentCustomerSection/appointment-customer-sections.tsx","components/common/ExclamationModal/css.ts","models/enums/appointment-schedule-busy-reason.ts","components/common/ExclamationModal/exclamation-modal.tsx","components/appointments/AppointmentScheduleBusyModal/css.ts","components/appointments/AppointmentScheduleBusyModal/appoinment-schedule-busy-modal.tsx","components/appointments/RecurringAppointmentUpdateModal/css.ts","components/appointments/RecurringAppointmentUpdateModal/recurring-appointment-update-modal.tsx","components/appointments/AppointmentDetails/css.ts","components/common/BusyScheduleQuestion/css.ts","components/common/BusyScheduleQuestion/busy-schedule-question.tsx","models/appointment-busy-modal-data-model.ts","components/common/AppointmentWorkAreaBusyModal/css.ts","components/common/AppointmentWorkAreaBusyModal/appointment-work-area-busy-modal.tsx","components/common/OutsideBusinessHoursModal/css.ts","components/common/OutsideBusinessHoursModal/outside-business-hours-modal.tsx","components/appointments/AppointmentOutsideScheduleModal/css.ts","components/appointments/AppointmentOutsideScheduleModal/appoinment-outside-schedule-modal.tsx","components/common/TimeIsBusyAnotherAppointmentCanNotContinueModal/css.ts","components/common/TimeIsBusyAnotherAppointmentCanNotContinueModal/outside-business-hours-modal.tsx","components/appointments/AppointmentDetails/appointment-details.tsx","components/appointments/AppointmentNew/css.ts","components/appointments/AppointmentNew/appointment-new.tsx","components/appointments/AppointmentRouter/appointment-router.tsx","components/customers/CustomerClassificationItem/css.ts","components/customers/CustomerClassificationItem/customer-classification-item.tsx","components/customers/CustomerClassification/css.ts","components/customers/CustomerClassification/customer-classification.tsx","components/customers/CustomerImportModal/css.ts","api/file-service.ts","components/customers/CustomerImportModal/customer-import-modal.tsx","components/common/grid/ArrowDrop/arrow-drop.tsx","components/common/grid/EnhancedTableHead/css.ts","components/common/grid/EnhancedTableHead/enhanced-table-head.tsx","components/common/Pagination/css.ts","components/common/Pagination/pagination.tsx","components/common/grid/GridList/css.ts","components/common/grid/GridList/grid-list.tsx","components/customers/CustomerList/css.ts","components/common/ConfirmDeleteModal/css.ts","components/common/ConfirmDeleteModal/confirmdeletemodal.tsx","components/customers/CustomerList/customer-list.tsx","components/customers/CustomerMainPage/css.ts","models/customers-classification-entity.ts","models/customers-classification.ts","models/customers-classifications.ts","api/customer-classification-service.ts","components/common/EstablishmentsToolbar/css.ts","components/common/EstablishmentsToolbar/establishments-toolbar.tsx","components/customers/CustomerMainPage/customer-main-page.tsx","components/common/tabs/Tabs/css.ts","models/enums/months.ts","components/common/tabs/Tabs/tabs.tsx","components/common/tabs/TabPanel/tab-panel.tsx","components/customers/CustomerDataInfo/css.ts","components/customers/CustomerDataInfo/customer-data-info.tsx","components/customers/CustomerHistory/css.ts","components/customers/CustomerHistoryDetails/css.ts","components/customers/CustomerHistoryDetails/customer-history-details.tsx","components/customers/CustomerHistory/customer-history.tsx","components/customers/CustomerDetails/css.ts","components/customers/PatientEvolutionNotes/css.ts","assets/icons/DiaryIcon.tsx","components/customers/PatientImportEvolutionNoteClinicalFileModal/css.ts","components/customers/PatientImportEvolutionNoteClinicalFileModal/patient-import-evolution-note-clinical-file-modal.tsx","components/common/grid/GridListWithoutPagination/css.ts","components/common/grid/GridListWithoutPagination/grid-list-without-pagination.tsx","components/common/PatientFormTextInput/css.ts","hooks/useControlLabel/css.ts","hooks/useControlLabel/use-control-label.tsx","hooks/useInputFirstTouch/use-input-first-touch.tsx","components/common/PatientFormTextInput/patient-form-text-input.tsx","components/common/PatientFormMobileInput/css.ts","components/common/PatientFormMobileInput/patient-form-mobile-input.tsx","models/section-field-item-model.ts","models/section-field-value-model.ts","components/common/PatientFormRadioGroup/css.ts","components/common/PatientFormRadio/css.ts","components/common/PatientFormRadio/patient-form-radio.tsx","components/common/PatientFormFreeTextInput/css.ts","components/common/PatientFormFreeTextInput/patient-form-free-text-input.tsx","components/common/PatientFormRadioGroup/patient-form-radio-group.tsx","models/section-field-model.ts","models/enums/terminology-type.ts","models/enums/terminology-form.ts","models/field-and-value.ts","models/evolution-note-field-and-value.ts","hooks/useTerminology/use-terminology.ts","components/customers/PatientEvolutionNotes/patient-evolution-notes.tsx","components/customers/PatientData/css.ts","components/common/DataAccordion/css.ts","components/common/DataAccordion/data-accordion.tsx","components/customers/PatientData/patient-data.tsx","components/customers/CustomerInformationTab/css.ts","components/customers/CustomerEmergencyContacts/css.ts","components/customers/CustomerEmergencyContacts/customer-emergency-contacts.tsx","components/customers/CustomerEmergencyContactList/customer-emergency-contact-list.tsx","models/create-emergency-contacts.ts","components/customers/CustomerInformationTab/customer-information-tab.tsx","components/customers/PatientGeneralInformationTab/css.ts","components/customers/PatientGeneralInformationTab/PatientFormDateInput/css.ts","components/customers/PatientGeneralInformationTab/PatientFormDateInput/patient-form-date-input.tsx","utils/cloner.ts","models/update-patient-form-data-request.ts","components/customers/PatientGeneralInformationTab/patient-general-information-tab.tsx","components/customers/CustomerClinicalFiles/css.ts","assets/icons/NoFilesIcon.tsx","components/customers/PatientImportClinicalFileModal/css.ts","components/customers/PatientImportClinicalFileModal/patient-import-clinical-file-modal.tsx","components/customers/CustomerClinicalFiles/customer-clinical-files.tsx","components/customers/PatientClinicalHistoryTab/css.ts","components/customers/PatientClinicalHistoryTab/ClinicalHistoryRadioGroup/css.ts","components/customers/PatientClinicalHistoryTab/ClinicalHistoryRadio/css.ts","components/customers/PatientClinicalHistoryTab/ClinicalHistoryRadio/clinical-history-radio.tsx","components/customers/PatientClinicalHistoryTab/ClinicalHistoryFreeTextInput/css.ts","components/customers/PatientClinicalHistoryTab/ClinicalHistoryFreeTextInput/clinical-history-free-text-input.tsx","components/customers/PatientClinicalHistoryTab/ClinicalHistoryRadioGroup/clinical-history-radio-group.tsx","components/customers/PatientClinicalHistoryTab/ClinicalHistoryTextInput/css.ts","components/customers/PatientClinicalHistoryTab/ClinicalHistoryTextInput/clinical-history-text-input.tsx","models/update-patient-observations-request.ts","models/clinical-history-field-and-value.ts","models/update-patient-clinical-history-field-value-request.ts","components/customers/PatientClinicalHistoryTab/PatientSignature/css.ts","components/customers/PatientClinicalHistoryTab/PatientSignature/patient-signature.tsx","components/customers/PatientClinicalHistoryTab/SaveSignatureModal/css.ts","components/customers/PatientClinicalHistoryTab/SaveSignatureModal/save-signature-modal.tsx","components/customers/PatientClinicalHistoryTab/patient-clinical-history-tab.tsx","components/customers/PatientAppointmentHistoryTab/css.ts","components/customers/CustomerDetails/customer-details.tsx","components/customers/PatientAppointmentHistoryTab/patient-appointment-history-tab.tsx","components/customers/CustomerRouter/customer-router.tsx","components/settings/SettingsNavTabs/css.ts","components/settings/SettingsNavTabs/settings-nav-tabs.tsx","components/settings/Sections/Users/UsersMainPage/css.ts","components/settings/Sections/Users/UserList/css.ts","components/settings/Sections/Users/UserList/user-list.tsx","components/settings/Sections/Users/UserModal/css.ts","components/settings/Sections/Users/UserModalGeneralInfo/css.ts","models/job-position.ts","api/job-position-service.ts","components/common/SwitchWithLabelAndTooltip/css.ts","components/common/SwitchWithLabelAndTooltip/switch-with-label-and-tooltip.tsx","components/settings/Sections/Users/JobPositionSelect/css.ts","components/settings/Sections/Users/JobPositionSelect/job-position-select.tsx","components/settings/Sections/Users/JobPositionEditModal/css.ts","components/settings/Sections/Users/JobPositionEditModal/job-position-edit-modal.tsx","components/settings/Sections/Users/JobPositionDeleteModal/css.ts","components/settings/Sections/Users/JobPositionDeleteModal/job-position-delete-modal.tsx","components/settings/Sections/Users/UserModalHasUpcomingAppointment/css.ts","components/settings/Sections/Users/UserModalHasUpcomingAppointment/user-modal-has-upcoming-appointment.tsx","components/common/DropImage/css.ts","components/common/DropImage/dropimage.tsx","components/settings/Sections/Users/UserModalGeneralInfo/user-modal-general-info.tsx","components/common/SwitchWithLabel/css.ts","models/enums/day-of-week.ts","components/common/SwitchWithLabel/switch-with-label.tsx","components/settings/Sections/Users/UserScheduleItem/css.ts","components/settings/Sections/Users/UserScheduleItem/user-schedule-item.tsx","components/settings/Sections/Users/UserModalSchedules/user-modal-schedules.tsx","components/settings/Sections/Users/UserModalServices/css.ts","components/settings/Sections/Users/UserServiceCategory/css.ts","components/settings/Sections/Users/UserServiceCertifications/css.ts","components/settings/Sections/Users/UserServiceCertifications/user-service-certifications.tsx","components/settings/Sections/Users/UserServiceCategory/user-service-category.tsx","components/settings/Sections/Users/UserModalServices/user-modal-services.tsx","components/settings/Sections/Users/UserModalPermissions/css.ts","components/settings/Sections/Users/UserModalPermissions/user-modal-permissions.tsx","components/settings/Sections/Users/UserModalCommissions/css.ts","components/settings/Sections/Commissions/ConfirmationModal/css.ts","components/settings/Sections/Commissions/ConfirmationModal/confirmation-modal.tsx","components/common/RadioWithContent/css.ts","components/common/RadioWithContent/radio-with-content.tsx","components/settings/Sections/Users/UserModalCommissions/user-modal-commissions.tsx","components/settings/Sections/Users/UserCancelModal/css.ts","components/settings/Sections/Users/UserCancelModal/user-cancel-modal.tsx","components/settings/Sections/Users/UserModal/user-modal-tab-type.ts","components/settings/Sections/Users/UserModalStepper/css.ts","components/settings/Sections/Users/UserModalStepper/user-modal-stepper.tsx","components/settings/Sections/Users/UserContinueEditModal/css.ts","components/settings/Sections/Users/UserContinueEditModal/user-continue-edit-modal.tsx","components/settings/Sections/Users/UserModalProfessionalInfo/css.ts","models/enums/signature-image-type.ts","components/common/ImageDropzone/css.ts","components/common/ImageDropzone/image-dropzone.tsx","components/settings/Sections/Users/UserModalProfessionalInfo/user-modal-professional-info.tsx","components/settings/Sections/Users/UserModal/user-modal.tsx","components/settings/Sections/Users/UserStatistic/css.ts","models/enums/section-type.ts","components/settings/Sections/Users/UserStatistic/user-statistic.tsx","models/section-field-create-response.ts","models/section-field-update-response.ts","models/section-model.ts","models/section-update-request.ts","api/settings-patient-forms-service.ts","components/establishment-settings/Sections/FormsSettingsTabs/SectionNote/css.ts","models/enums/section-note-data.ts","components/establishment-settings/Sections/FormsSettingsTabs/SectionNote/section-note.tsx","components/settings/Sections/Users/UsersMainPage/users-main-page.tsx","components/settings/Sections/CustomerCommunications/CustomerCommunicationsMain/css.ts","models/enums/first-remind-before.ts","models/enums/second-remind-before.ts","models/enums/whatsapp-followup-send-time.ts","models/customer-communication.ts","api/settings-customer-communication-service.ts","models/customer-communication-wa.ts","models/get-specific-conversation-messages-response.ts","api/whatsapp-service.ts","components/settings/Sections/CustomerCommunications/CustomerCommunicationsMain/customer-communications-main.tsx","components/settings/Sections/WorkArea/WorkAreaGrid/css.ts","components/settings/Sections/WorkArea/WorkAreaGrid/index.ts","components/settings/Sections/WorkArea/WorkAreaGrid/work-area-grid.tsx","components/settings/Sections/WorkArea/WorkAreaForm/css.ts","models/category.ts","api/settings-category-service.ts","components/settings/Sections/CategorySelect/css.ts","models/enums/settings-field-update.ts","components/settings/Sections/CategorySelect/category-select.tsx","components/settings/Sections/WorkArea/WorkAreaForm/work-area-form.tsx","components/settings/Sections/WorkArea/WorkAreaModal/css.ts","components/settings/Sections/WorkArea/WorkAreaModal/work-area-modal.tsx","components/settings/Sections/WorkArea/WorkAreaDelete/css.ts","components/settings/Sections/WorkArea/WorkAreaDelete/work-area-delete.tsx","components/settings/Sections/WorkArea/WorkAreaMain/css.ts","components/settings/Sections/WorkArea/WorkAreaMain/work-area-main.tsx","components/settings/Sections/General/WeekdaysChangeSettingsModal/props.ts","models/establishmentinfo.ts","api/settings-establishmentinfo-service.ts","components/settings/Sections/General/WeekdaysChangeSettingsModal/css.ts","components/settings/Sections/General/WeekdaysChangeSettingsModal/weekdays-change-settings-modal.tsx","api/settings-timezone-service.ts","components/settings/Sections/General/Weekdays/css.ts","components/settings/Sections/General/Weekdays/weekdays.tsx","models/establishmentphoto.ts","api/settings-establishmentphoto-service.ts","components/settings/Sections/General/EstablishmentPhotos/css.ts","components/settings/Sections/General/EstablishmentPhotos/establishment-photos.tsx","components/settings/Sections/General/CustomerClassification/css.ts","components/settings/Sections/General/CustomerClassification/customer-classification.tsx","components/settings/Sections/General/GeneralMain/css.ts","components/common/EditTerminologyModal/css.ts","components/common/EditTerminologyModal/edit-terminology-modal.tsx","components/common/HtmlTextArea/css.ts","components/common/HtmlTextArea/html-text-area.tsx","assets/icons/CertificationImageIcon.tsx","components/common/Certifications/css.ts","components/common/Certifications/certifications.tsx","components/settings/Sections/General/GeneralMain/general-main.tsx","models/enums/payment-field-update.ts","models/currency.ts","models/payment-settings-model.ts","api/settings-payment-service.ts","models/bank-transfer-info.ts","models/enums/bank-transfer-type.ts","components/settings/Sections/Payments/PaymentMain/css.ts","components/settings/Sections/Payments/PaymentMain/payment-main.tsx","components/settings/Sections/Services/ServiceGrid/css.ts","components/settings/Sections/Services/ServiceGrid/index.ts","components/settings/Sections/Services/ServiceGrid/service-grid.tsx","components/settings/Sections/Services/ServiceForm/css.ts","components/settings/Sections/Services/ServiceForm/service-form.tsx","components/settings/Sections/Services/ServiceModal/css.ts","components/settings/Sections/Services/ServiceModal/service-modal.tsx","components/settings/Sections/Services/ServiceDeleteModal/css.ts","components/settings/Sections/Services/ServiceDeleteModal/service-delete-modal.tsx","components/settings/Sections/Services/ServiceImportModal/css.ts","components/settings/Sections/Services/ServiceImportModal/service-import-modal.tsx","components/settings/Sections/Services/ServiceMain/css.ts","components/settings/Sections/Services/ServiceMain/service-main.tsx","components/settings/Sections/FormsSettingsTabs/ClinicHistory/css.ts","components/settings/Sections/FormsSettingsTabs/SectionNewModal/css.ts","components/settings/Sections/FormsSettingsTabs/SectionNewModal/section-new-modal.tsx","components/settings/Sections/FormsSettingsTabs/SectionList/css.ts","components/settings/Sections/FormsSettingsTabs/Section/css.ts","models/section-field-create-request.ts","models/section-field-update-request.ts","components/settings/Sections/FormsSettingsTabs/FieldList/css.ts","components/common/DraggableBase/css.ts","components/common/DraggableBase/draggable-base.tsx","models/section-field-update-order-request.ts","components/settings/Sections/FormsSettingsTabs/FieldList/field-list.tsx","components/settings/Sections/FormsSettingsTabs/SectionFieldModal/css.ts","components/settings/Sections/FormsSettingsTabs/SectionFieldModal/section-field-modal.tsx","models/section-field-delete-request.ts","components/settings/Sections/FormsSettingsTabs/Section/section.tsx","models/section-delete-request.ts","models/enums/clinical-history-communication-setting-type.ts","models/section-create-request.ts","components/settings/Sections/FormsSettingsTabs/SectionList/section-list.tsx","models/clinical-history-communication-settings-model.ts","api/service-сlinical-history-communication-settings.ts","components/settings/Sections/FormsSettingsTabs/ClinicHistory/clinic-history.tsx","components/settings/Sections/FormsSettingsTabs/EvolutionNotes/css.ts","models/enums/static-treatment-document-field-type.ts","components/settings/Sections/FormsSettingsTabs/EvolutionNotes/TreatmentDocumentConfigurationModal/css.ts","components/settings/Sections/FormsSettingsTabs/EvolutionNotes/TreatmentDocumentConfigurationModal/TreatmentDocumentPreview/css.ts","components/settings/Sections/FormsSettingsTabs/EvolutionNotes/TreatmentDocumentConfigurationModal/TreatmentDocumentPreview/treatment-document-preview.tsx","components/settings/Sections/FormsSettingsTabs/EvolutionNotes/TreatmentDocumentConfigurationModal/treatment-document-configuration-modal.tsx","components/settings/Sections/FormsSettingsTabs/EvolutionNotes/evolution-notes.tsx","components/settings/Sections/FormsSettingsTabs/PatientForm/css.ts","components/settings/Sections/FormsSettingsTabs/PatientForm/patient-form.tsx","components/settings/Sections/Commissions/CommissionsMain/css.ts","models/users-commissions-response.ts","models/user-commission-entity.ts","api/commission-service.ts","components/settings/Sections/Commissions/CommissionList/css.ts","components/settings/Sections/Commissions/CommissionModal/css.ts","components/settings/Sections/Commissions/CommissionView/css.ts","components/settings/Sections/Commissions/CommissionView/commission-view.tsx","components/settings/Sections/Commissions/CommissionModal/commission-modal.tsx","components/settings/Sections/Commissions/CommissionList/commission-list.tsx","components/settings/Sections/Commissions/CommissionsMain/commissions-main.tsx","components/settings/SettingsRouter/settings-router.tsx","components/reports/sections/PredeterminedReports/PredeterminedReportsPage/css.ts","models/enums/predetermined-report-type.ts","models/report.ts","models/enums/report-column-id.ts","models/report-column.ts","models/preview-custom-report.ts","api/reports-service.ts","components/reports/ReportsNavTabs/css.ts","components/reports/ReportsNavTabs/reports-nav-tabs.tsx","components/reports/sections/PredeterminedReports/PredeterminedReportsPage/predetermined-reports-page.tsx","components/reports/sections/CustomReports/CustomReportsPage/css.ts","components/common/SelectKeyEditable/css.ts","components/common/SelectKeyEditable/select-key-editable.tsx","models/custom-report-preview-request.ts","models/ordered-report-property.ts","components/reports/SaveReportModal/css.ts","components/reports/SaveReportModal/save-report-modal.tsx","models/enterprise-custom-report-preview-request.ts","components/reports/sections/CustomReports/CustomReportsPage/custom-reports-page.tsx","components/reports/ReportsRouter/reports-router.tsx","components/whatsapp/Messenger/css.ts","models/conversation-preview.ts","components/whatsapp/ConversationWindow/css.ts","components/whatsapp/MessageAudioPlayer/css.ts","components/whatsapp/MessageAudioPlayer/message-audio-player.tsx","components/whatsapp/Message/message.tsx","components/whatsapp/Message/css.ts","assets/icons/ArrowDropDownTriangleIcon.tsx","assets/icons/ScheduledSendIcon.tsx","assets/icons/MercadoPagoLinkIcon.tsx","components/whatsapp/common/css.ts","components/whatsapp/common/ScheduledSendIconWithTooltip.tsx","components/whatsapp/ImageCarousel/css.ts","components/whatsapp/ImageCarousel/image-carousel.tsx","components/common/notifications/SnackbarNotification/snackbar-notification-kind.ts","components/common/notifications/SnackbarNotification/css.ts","components/common/notifications/SnackbarNotification/snackbar-notification.tsx","components/whatsapp/SelectWhatsAppTemplate/css.ts","components/whatsapp/SelectWhatsAppTemplate/select-whatsapp-template.tsx","models/enums/whatsapp-template-type.ts","components/whatsapp/ChatToolbar/css.ts","components/whatsapp/ChatToolbar/chat-toolbar.tsx","components/whatsapp/BlockCustomerIcon/css.ts","components/whatsapp/BlockCustomerIcon/block-customer-icon.tsx","components/whatsapp/BlockCustomerModal/css.ts","components/whatsapp/BlockCustomerModal/block-customer-modal.tsx","components/whatsapp/UnblockCustomerModal/css.ts","components/whatsapp/UnblockCustomerModal/unblock-customer-modal.tsx","components/whatsapp/ConversationWindow/conversation-window.tsx","components/whatsapp/ConversationsListItem/css.ts","components/whatsapp/ConversationsListItem/conversations-list-item.tsx","assets/images/no-conversations.svg","models/enums/availability-status.ts","components/whatsapp/Messenger/messenger.tsx","components/whatsapp/WhatsAppConversationRouter/whatsapp-conversation-router.tsx","models/massive-sending-entity.ts","models/massive-sending-service-model.ts","api/massive-sending-service.ts","components/whatsapp/massivesendings/MassiveSendingsList/css.ts","models/enums/massive-sending-type.ts","models/enums/massive-sending-birthday-type.ts","models/helpers/grid-info.model.ts","components/common/IconCounter/css.ts","components/common/IconCounter/icon-counter.tsx","components/whatsapp/massivesendings/MassiveSendingsList/massive-sendings-list.tsx","components/whatsapp/massivesendings/MassiveSendingsMain/css.ts","components/whatsapp/massivesendings/MassiveSendingModal/css.ts","components/whatsapp/massivesendings/MassiveSendingGeneralSettings/css.ts","components/common/ChipSelect/css.ts","components/common/Chip/css.ts","components/common/Chip/chip.tsx","components/common/ChipSelect/chip-select.tsx","components/common/RadioWithText/css.ts","components/common/RadioWithText/radio-with-text.tsx","components/whatsapp/massivesendings/TerminationDate/css.ts","components/whatsapp/massivesendings/TerminationDate/termination-date.tsx","components/whatsapp/massivesendings/TimeOfSending/css.ts","components/whatsapp/massivesendings/TimeOfSending/time-of-sending.tsx","components/common/SelectMonthDayDate/css.ts","components/common/SelectMonthDayDate/select-month-day-date.tsx","components/whatsapp/massivesendings/MassiveSendingGeneralSettings/massive-sending-general-settings.tsx","components/whatsapp/massivesendings/MassiveSendingStepper/css.ts","components/whatsapp/massivesendings/MassiveSendingStepper/massive-sending-stepper.tsx","components/common/CancelModal/css.ts","components/common/CancelModal/cancel-modal.tsx","components/whatsapp/massivesendings/MassiveSendingMessageSettings/css.ts","models/enums/massive-sending-content-type.ts","components/whatsapp/massivesendings/MassiveSendingMessageSettings/massive-sending-message-settings.tsx","components/whatsapp/massivesendings/MassiveSendingPreview/css.ts","components/whatsapp/massivesendings/MassiveSendingPreview/massive-sending-preview.tsx","components/whatsapp/massivesendings/MassiveSendingModal/massive-sending-modal.tsx","components/whatsapp/massivesendings/MassiveSendingDetail/css.ts","assets/icons/DuplicateIcon.tsx","assets/icons/DownloadFileIcon.tsx","components/whatsapp/massivesendings/MassiveSendingDetail/massive-sending-detail.tsx","components/whatsapp/massivesendings/MassiveSendingsMain/massive-sendings-main.tsx","components/whatsapp/WhatsAppRouter/whatsapp-router.tsx","components/Todo/todo.tsx","components/common/notifications/AlertProvider/css.ts","components/common/notifications/AlertProvider/use-alert.tsx","components/common/notifications/AlertProvider/alert-provider.tsx","api/country-service.ts","components/common/infrastructure/AccountSettingsProvider/account-settings-provider.tsx","components/establishment-settings/Sections/FormsSettingsTabs/ClinicHistory/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/SectionNewModal/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/SectionNewModal/section-new-modal.tsx","components/establishment-settings/Sections/FormsSettingsTabs/SectionList/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/Section/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/FieldList/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/FieldList/field-list.tsx","components/establishment-settings/Sections/FormsSettingsTabs/SectionFieldModal/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/SectionFieldModal/section-field-modal.tsx","components/establishment-settings/Sections/FormsSettingsTabs/Section/section.tsx","components/establishment-settings/Sections/FormsSettingsTabs/SectionList/section-list.tsx","models/copy-establishment-settings-model.ts","components/common/Backdrop/css.ts","components/common/Backdrop/backdrop.tsx","components/establishment-settings/Sections/FormsSettingsTabs/ClinicHistory/clinic-history.tsx","components/establishment-settings/Sections/FormsSettingsTabs/EvolutionNotes/css.ts","api/settings-evolution-notes-communication-service.ts","components/establishment-settings/Sections/FormsSettingsTabs/EvolutionNotes/evolution-notes.tsx","components/establishment-settings/Sections/FormsSettingsTabs/PatientForm/css.ts","components/establishment-settings/Sections/FormsSettingsTabs/PatientForm/patient-form.tsx","components/establishment-settings/EstablismentSettingsNavTabs/css.ts","components/establishment-settings/SettingsEstablishmentSelector/css.ts","components/establishment-settings/SettingsEstablishmentSelector/settings-establishment-selector.tsx","components/establishment-settings/EstablismentSettingsNavTabs/establishment-settings-nav-tabs.tsx","components/establishment-settings/Sections/FormsSettingsTabs/General/Enterprise/css.ts","models/enums/enterprise-settings-field-update.ts","models/enterpriseinfo.ts","api/settings-enterpriseinfo-service.ts","components/establishment-settings/Sections/FormsSettingsTabs/General/Enterprise/general.tsx","components/establishment-settings/Sections/FormsSettingsTabs/General/general-page.tsx","components/establishment-settings/EstablismentSettingsRouter/establishment-settings-router.tsx","components/common/InterweaveComponent/interweave-component.tsx","components/customers/PrivacyNoticePage/privacy-notice-page.tsx","components/customers/InformedConsentLetterPage/informed-consent-letter-page.tsx","constants/styles.ts","App.tsx","components/authentication/AuthenticationProvider/authentication-provider.tsx","index.tsx"],"names":["module","exports","ImportExcelResponse","x","isFileProcessed","processedRecordsCount","totalRecordsCount","invalidRecordsFile","this","Buffer","from","Boolean","window","location","hostname","match","LocalStorageKey","authenticationSlice","createSlice","name","initialState","value","reducers","authenticate","state","deauthenticate","actions","initialApplicationInterfaceState","title","isAccountOverdue","locale","localStorage","getItem","process","isWideLayout","applicationInterfaceSlice","updateTitle","currentState","action","payload","updateAccountOverdue","updateLocale","updateIsWideLayout","applicationInterfaceActions","navbarSlice","externalContent","conversationCounter","showLoader","setExternalContent","setConversationCounter","setShowLoader","navbarActions","blockedScheduleSlice","showMenu","showModal","date","userId","blockedSheduleId","setShowMenu","setShowModal","setDate","setUserId","setBlockedSheduleId","blockedScheduleActions","isModalOpen","blockerCount","blockers","multipleBlockedScheduleSlice","setState","resetState","multipleBlockedScheduleActions","initialSchedulerState","currentDate","Date","currentViewName","daysOff","allUsers","selectedUsers","selectedStatuses","tooltipAppointments","appointmentBlocked","startDayHours","endDayHours","startWeekHour","endWeekHour","weekDays","isDragging","isGrouping","appointmentDndModalState","open","hasSimultaneousAppointments","appointmentId","schedulerSlice","setCurrentDate","setCurrentViewName","setDaysOff","setAllUsers","setSelectedUsers","setSelectedStatuses","setTooltipAppointment","setAppointmentId","current","find","a","undefined","setAppointmentBlocked","setStartDayHours","setEndDayHours","setStartWeekHour","setEndWeekHour","setWeekDays","setIsDragging","setIsGrouping","setAppointmentDndModalState","schedulerActions","alertsSlice","alerts","enqueueAlert","key","replace","c","r","Math","random","toString","closeAlert","map","alert","dismissed","removeAlert","filter","alertsActions","Url","Login","Recovery","ResetPassword","Logout","Join","Main","MassiveSendings","CustomReport","CustomerCommunications","WorkAreas","Services","Users","Payments","ClinicHistory","EvolutionNotes","PatientForm","Commissions","CommonHub","WhatsAppHub","General","startSignalRConnection","connection","start","setTimeout","commonHubSlice","connect","HubConnectionState","Disconnected","accessToken","AccessToken","connectionOptions","accessTokenFactory","transport","HttpTransportType","WebSockets","skipNegotiation","HubConnectionBuilder","withUrl","withAutomaticReconnect","configureLogging","LogLevel","Information","build","serverTimeoutInMilliseconds","initializeConnection","disconnect","Connected","stop","UserInfo","email","username","fullName","accountId","isAdministrator","hasCustomerInfoVisible","hasMassiveSendings","canRegisterPayments","canOpenCloseCashRegister","canMakeCashRegisterMovements","hasAccessToReports","canSeeClinicalFile","canInteractWithEvolutionNotes","canInteractWithPatientFiles","hasAccessToWhatsAppConversationsAndNotifications","hasAccessToScheduleAllSpecialists","canPrescribeTreatment","showPrices","fullname","accountid","userid","isadministrator","hascustomerinfovisible","hasmassivesendings","canregisterpayments","hasaccesstoreports","hasaccesstoscheduleallspecialists","canopenclosecashregister","canmakecashregistermovements","canseeclinicalfile","caninteractwithevolutionnotes","caninteractwithpatientfiles","hasaccesstowhatsappconversationsandnotifications","canprescribetreatment","showprices","localStateJson","localState","JSON","parse","prop","Object","prototype","hasOwnProperty","call","initializeLocalStateDefaults","userInfoSlice","setUserInfo","setItem","stringify","resetUserInfo","removeItem","ApiClient","axios","interceptors","response","use","handleRejectedRequest","bind","defaults","headers","common","authorizationHeader","error","isCancel","Promise","reject","status","post","baseUrl","withCredentials","then","resp","configureAuthorization","data","store","dispatch","getUserInfo","catch","removeAuthorization","href","reload","originalRequest","config","refreshTokenPromise","url","formData","put","content","delete","get","values","all","token","decodedToken","jwtDecode","includeTime","serverDate","UTC","getFullYear","getMonth","getDate","setUTCHours","getHours","getMinutes","whatsAppHubSlice","userInfo","Country","iso3","dialCode","dialDigits","dialTemplate","accountName","accountLogo","currencyTemplate","paymentMethods","isCashRegisterActivated","paymentsAndCollectionsEnabled","isClinicMode","hasEstablishmentsInClinicMode","countries","countryInSettings","siteForFinalCustomersSmbName","scheduleSimultaneousServicesEnabled","hasMultipleAppointments","accountIanaTimezone","isEnterprise","establishments","terminologies","schedulerBlockDurationMinutes","accountSettingsSlice","setAccountSettings","setAccountName","setAccountLogo","setCurrencyTemplate","setPaymentMethods","setIsCashRegisterActivated","setAccountIanaTimezone","setCountries","setCountryInSettings","setSiteForFinalCustomersSmbName","setScheduleSimultaneousServicesEnabled","setHasMultipleAppointments","setIsEnterprise","setEstablishments","establishmentSettingsSlice","setEstablishmentSettings","CashRegisterCurrentStateModel","initialCash","cashNow","paymentsReceived","cashPayments","creditCardPayments","bankTransferPayments","oxxoPayments","mercadoPagoPayments","depositByAdministrator","withdrawalByAdministrator","CashRegisterMovementHistory","movements","isOpen","history","cashRegisterSlice","setCashRegisterFullState","setIsOpen","setCashRegisterCurrentState","appointmentTime","newAppointmentViaScheduler","scheduleAppointmentTimeSlice","setAppointmentTime","setClickNewAppointmentOnScheduler","scheduleAppointmentTimeActions","selectedEstablishments","settingsEstablishmentId","enterpriseSlice","setSelectedEstablishments","setSettingsEstablishmentId","enterpriseActions","callback","isDownloading","downloadProgress","fileName","mimeType","fileDownloaderSlice","startDownload","setProgress","finishDownload","cancelDownload","fileDownloadActions","configureStore","reducer","authentication","authenticationReducer","applicationInterface","applicationInterfaceReducer","navbar","navbarReducer","blockedSchedule","blockedScheduleReducer","multipleBlockedSchedule","multipleBlockedScheduleReducer","scheduler","schedulerReducer","alertsReducer","commonHub","commonHubReducer","whatsAppHub","whatsAppHubReducer","accountSettings","accountSettingsReducer","establishmentSettings","establishmentSettingsReducer","userInfoReducer","cashRegister","cashRegisterReducer","scheduleAppointmentTime","scheduleAppointmentTimeReducer","enterprise","enterpriseReducer","fileDownloader","fileDownloadReducer","middleware","getDefaultMiddleware","serializableCheck","selectAccountSettings","selectEstablishmentSettings","selectUserInfo","selectCommonHubConnection","selectCashRegisterState","selectCashRegisterOpen","useAppDispatch","useDispatch","useAppSelector","useSelector","i18n","initReactI18next","init","lng","fallbackLng","resources","react","defaultTransParent","transEmptyNodeValue","transSupportBasicHtmlNodes","transKeepBasicHtmlNodesFor","transWrapTextNodes","addResourceBundle","enGeneral","esGeneral","enNav","esNav","enClinicCustomer","esClinicCustomer","enMassiveSendings","esMassiveSendings","enClinicPatient","esClinicPatient","enSections","esSections","enSettings","esSettings","enTerminologies","esTerminologies","ArrowLeftIcon","props","style","color","otherProps","SvgIcon","viewBox","d","fill","ArrowRightIcon","CashRegisterIcon","ComputerIcon","BanIcon","width","height","DotIcon","DocumentIcon","fillRule","clipRule","CustomerFrequencyType","ConversationIcon","StatusIcon","Frequent","Infrequent","marginRight","SortDownIcon","SortUpIcon","transform","SortIcon","GroupIcon","GroupAppointmentsIcon","PersonIcon","ImportIcon","SuccessIcon","ErrorIcon","EditIcon","MinusArrowIcon","PhoneIcon","NoteIcon","ExportIcon","ExportFileIcon","clip-path","id","SaveIcon","CrossIcon","PlusIcon","disabled","opacity","DeleteIcon","MenuIconWhatsapp","MenuIconSettings","MenuIconReports","stroke","strokeWidth","strokeLinecap","MenuIconCustomer","MenuIconLogoClear","MenuIconPower","MercadoPagoIcon","OxxoIcon","TrashIcon","FlagIcon","NotesIcon","MoneyIcon","CalendarCancelIcon","MegaphoneIcon","FiltersIcon","DoorIcon","ExclamationIcon","BroadcastIcon","xmlns","ArrowDropDownIcon","ExcelIcon","fontSize","UploadFileCloud","position","top","DownloadCloudIcon","AddCustomerIcon","FlatImageIcon","InfoIcon","ArrowLineDown","CalendarIcon","CalendarIcon2","InfoCircleIcon","CameraIcon","SearchIcon","PDFIcon","CashIcon","CreditCardIcon","BankIcon","LogoIcon","DownloadFileCloud","CheckIcon","WhatsAppNotificationIcon","ScreenNotificationIcon","DotsVerticalIcon","cx","cy","ClockIcon","MenuIcon","SideArrowForMessageIcon","Color","AdminIcon","ArrowDownIcon","ListPlusIcon","UserIcon","BellIcon","DollarSignNotificationIcon","WhatsAppPDFIcon","gray5","WhatsAppVideoIcon","WhatsAppPlayVideoIcon","gray7","WhatsAppPlayAudioIcon","WhatsAppMicrophoneIcon","maskUnits","y","mask","WhatsAppAudioLogo","VideoCameraEmptyIcon","VideoCameraFilledIcon","LinkIcon","CalendarCheckmarkIcon","PersonCheckmarkIcon","PersonSpeechBalloonIcon","SectionNewIcon","gray1","SectionArrowIcon","gray4","SectionEditIcon","SectionDeleteIcon","SectionFieldNewIcon","DraggableIcon","SectionFieldTextIcon","SectionFieldDropdownIcon","SectionFieldRadioIcon","SectionFieldCheckboxIcon","SectionFieldNumericIcon","SectionFieldDateIcon","SectionFieldPhoneIcon","SectionFieldCheckboxItemIcon","SectionFieldDropdownItemIcon","SectionFieldOptionalTextFieldIcon","SectionFieldRadioItemIcon","SectionSaveIcon","SectionExitEditIcon","SectionFieldEmailIcon","SuggestedServicesIcon","MedicalBookIcon","PatientAppointmentsIcon","clear2","PatientContactIcon","PatientFemaleIcon","red","PatientGeneralDataIcon","PatientMaleIcon","blue","PatientServicesIcon","InternalNotesIcon","WordIcon","ImageIcon","PatientStethoscopeIcon","RoundCheckmarkIcon","green","ListMarkIcon","EyeIcon","WarningIcon","BillsIcon","BillIcon","fill-rule","clip-rule","TimeLimitIcon","SheetIcon","ListIcon","PenIcon","CopyIcon","border","ReportPersonIcon","rx","ry","CloseIcon","CheckboxCheckedIcon","CheckboxUncheckedIcon","CaptionImageMediaIcon","WhatsAppDocumentIcon","CaptionDocumentMediaIcon","SectionGearIcon","BlockIcon","StopHandIcon","marginLeft","useStyles","makeStyles","theme","root","flexGrow","menuButton","fontWeight","fontFamily","colors","grey4","externalContentPlaceholder","verticalDivider","paddingRight","borderRightColor","grey2","borderRightWidth","borderRightStyle","establishmentSelector","paper","background","borderTopRightRadius","borderBottomRightRadius","logoClear","marginTop","iconLogoClear","margin","enterpriseLabel","typography","txtBody1","versionLabel","drawerListItems","overflow","tablecss","borderCollapse","userLabel","emailLabel","overflowWrap","linkMenu","backgroundColor","textDecoration","linkMenuParent","listItem","borderLeft","listItemActive","childItemActive","listSubItemActive","paddingLeft","listItemIcon","minWidth","paddingTop","menuIcon","listItemText","menuHorizontalTop","padding","borderBottom","left","right","listSubItem","iconsBlock","display","justifyContent","alignItems","referFriend","flexDirection","borderRadius","clilac","referFriendTitle","marginBottom","referFriendDescription","referFriendLink","textAlign","popper","fontStyle","AuthenticationService","password","captchaToken","succeeded","timeZoneId","Error","newPassword","list","iconNotificationButton","notificationDot","clearRed","grey1","titleBlock","justifySelf","alignSelf","titleText","header4","closeIconButton","closeButtonContainer","clearMain","NotificationHeader","handleClose","classes","t","useTranslation","className","Typography","IconButton","size","aria-label","onClick","NotificationType","bottom","messagesIconContainer","messageRing","manyMessagesRemain","clearGreen","halfMessagesRemain","clearYellow","lowMessagesRemain","noMessagesRemain","expander","grey5","txtBody2","upsideDown","messagesFirstRow","gap","messagesFirstRowText","firstRowExpandedBorder","borderBottomWidth","borderBottomColor","messagesText","grey6","divider","iconContainer","ring","svg","circle","ProgressRingWithIcon","icon","fillPercent","circumference","radius","PI","offset","strokeDashoffset","strokeDasharray","NotificationFooter","monthlyConversationsLimit","spentMarketing","spentUtility","availableConversationsCount","useState","isExpanded","setIsExpanded","remainingPart","round","getProgressRingFillPercent","iconColor","yellow","WhatsAppIcon","ArrowIcon","e","stopPropagation","AppointmentCreatedBy","AppointmentStatus","minHeight","clear5","unreadDot","headerRow","header","headerIcon","headerText","txtBody3","senderRow","mainText","textRow","additionalText","strongText","messageCounter","clearBlue","timeContainer","fromToDateTimeRow","fromToLabel","AppointmentPaymentStatus","Appointment","startDate","endDate","createdBy","customerName","firstServiceId","users","isEditable","establishmentId","establishmentName","services","isDraggable","isRecurring","DateTime","fromISO","NotConfirmed","Account","now","AppointmentServiceModel","duration","price","user","workArea","AppointmentAvailableHours","availableHours","CreateAppointmentModel","number","customerId","firstName","lastName","mobile","mobileCodeIso3","mobileDigits","mobileCode","mobileTemplate","notes","isCustomSchedule","scheduledSimultaneousServices","recurrenceWeekInterval","recurredAppointmentsCount","totalPriceForRecurringAppointments","updateAllRecurringAppointments","recurringAppointmentOrder","isIgnoreScheduleBusy","customRecurrenceInterval","customRecurrenceMode","customRecurrenceWeekDays","AppointmentBlocker","serviceName","startData","appointmentDuration","ConversationMessageType","AppointmentTooltipModel","paymentStatus","paidAmount","customerEmail","customerMobile","customerMobileCodeIso3","customerMobileDigits","customerMobileCode","customerMobileTemplate","totalRecurringApptPriceExcludingSelected","totalRecurringApptPrice","recurredAppointmentsIds","recurringApptTotalToPaid","appointmentRecurrenceWeekInterval","Unpaid","AppointmentService","year","toLocaleString","month","day","time","hourCycle","hour","minute","second","isoDate","appointment","handleTime","appointmentBlocker","isScheduleBusy","appointmentScheduleBusyReason","allRecurringAppointments","endpointUrl","remove","serviceId","dataNotes","allAppointments","isUpdated","isUpdatable","userIds","statuses","FormData","append","forEach","String","appointments","dateFrom","dateTo","toISOString","establishmentIds","setHours","service","estimatedDuration","workAreaId","availableDays","followup","scheduled","followUpDate","CustomerRequiresQuoteNotificationIcon","NotificationItem","notification","markAsRead","senderMobile","type","senderId","sender","text","fromStartDate","fromEndDate","toStartDate","toEndDate","read","messageCount","whatsAppInboundMessageType","localeApp","useHistory","CustomerRequiresQuoteIcon","ScreenIcon","DollarIcon","markRead","appointmentDate","s","some","u","includes","push","redirectedAppointmentDate","redirectedAppointmentId","markReadAndRedirectToWhatsApp","markReadAndRedirectToAppointments","redirectToAppointmentPage","tryTrimText","maxTextLength","length","substring","notificationParameters","UnreadMessages","actionType","hasServices","hasDropDown","hasFromToDateTime","CustomerRequiresAttention","NewAppointment","ModifiedAppointment","AppointmentConfirmedByCustomer","ProofOfPayment","AppointmentModifiedByCustomer","AppointmentCancelledByCustomer","CustomerRequiresQuote","getParametersByNotificationType","formatSenderWithPlusSign","isNaN","formatDate","end","weekDay","weekday","charAt","toUpperCase","slice","monthDay","startTime","hour12","endTime","timeDifference","today","hours","parseInt","abs","getTime","minutes","Image","Video","Voice","Document","Pdf","getCaptionImage","notificationText","getText","Text","NotificationEntity","wasShown","NotificationsService","n","err","console","whatsAppUrl","ConversationsCounterModel","hasReachedReferralThreshold","StackableNotificationTypes","NotificationBlock","commonHubConnection","anchorElement","setAnchorElement","notifications","setNotifications","conversationsCounterModel","setConversationsCounterModel","isMenuOpen","handleMenuOpen","event","currentTarget","fetchConversationCounter","markNotificationsAsWasShown","newNotifications","handleMenuClose","unshownNotifications","getNotifications","receivedNotifications","getAvailableConversationsCount","remainingConversationsModel","markNotificationAsRead","handleNotificationReading","notificationId","notificationIds","updateNotification","handleNotificationsReading","useEffect","fetchNotifications","off","on","receivedNotification","receiveNotification","isStackable","updatedNotifications","notificationToFloatUpIndex","findIndex","splice","unshift","anchorEl","ClickAwayListener","onClickAway","not","message","zIndex","messageBack","messageIcon","messageLabel","AccountOverdueMessage","iconButton","isActive","isHovered","setIsHovered","onMouseEnter","onMouseLeave","popover","palette","boxShadow","shadows","headerDate","closeIcon","cursor","borderColor","inputWithLabel","controlLabel","buttons","dot","inputLabelTooltip","submitButton","noPermissionsText","showCounter","input","inputText","counter","container","inputFocused","inputDisabled","inputError","useCurrencyValueTemplate","valueTemplate","template","valueWithCommas","toFixed","InputCurrency","setValue","placeholder","isValid","inputClass","onBlur","onChange","readOnly","maxLength","maxValue","autoFocus","isZeroAllowed","maxDigitsLength","templatedValue","displayValue","setDisplayValue","displayPlaceholder","setDisplayPlaceholder","parsedValue","parseFloat","numberWithCommas","InputBase","focused","preventDefault","Number","target","actualValue","pointIndex","indexOf","onFocus","newDisplay","numberFormatted","inputProps","box","maxWidth","subtitle2","arrowBottom","arrowLeft","arrowRight","IconTooltip","setOpen","useRef","tooltipText","classNameRoot","placement","arrowPlacement","onMouseMove","Popper","disablePortal","getArrowPlacementClass","ref","ButtonPropsBorderSide","ButtonPropsFill","ButtonPropsColor","ButtonPropsBorderRadius","button","customStyle","lineHeight","paddingBottom","borderWidth","buttonItems","ButtonWithSpinner","Small","borderSide","All","Filled","backgroundOrBorderColor","innerText","textColor","Gray1","Gray4","innerIcon","hoverColor","isProcessing","localIsProcessing","setLocalIsProcessing","Outlined","customStyles","useMemo","getBorderRadiusStyles","borderStyle","getHoverStyles","Clilac","None","Left","Right","result","Button","CircularProgress","OpenCashRegisterModal","setInitialCash","onSubmit","onClose","anchor","dtFormattingRule","isUserAbleToOpenCashRegister","handleCloseModal","handleOnClose","SubmitButton","Green","Large","NoPermissionText","CrossCloseButton","Popover","anchorOrigin","vertical","horizontal","transformOrigin","PaperProps","moment","format","OpenCashRegisterFormData","drawer","white","borderTopLeftRadius","borderBottomLeftRadius","overflowX","tabs","textTransform","tab","selected","tabPanelRoot","headerDateText","headerDateDate","goBackHeader","goBackButton","backButtonText","backButtonIcon","cashDetailsBlock","cashDetailsHeader","cashDetailsRow","cashDetailsIcon","cashDetailsRowName","cashDetailsRowValue","historyBlock","historyMovementBlock","historyMovementRow","historyMovementTitle","historyMovementValue","wordBreak","historyChip","historyDepositChip","historyWithdrawalChip","historyCashOpeningChip","historyDivider","currencyValue","cashClosingBlock","cashClosingInputAndNumberBlock","cashClosingInputRow","cashClosingInputsFirstRow","cashClosingInputColumn","cashClosingNumberColumn","inputLabel","numberLabel","numberValue","cashClosingDivider","commentsLabel","singleButtonFooter","newMovementBlock","newMovementHeader","typeOfMovementRadios","radioGreen","radioRed","radioLabelRoot","radioLabel","inputSpacing","footer","mainButton","redButton","mainColorText","requiredFields","cancelModalPaper","cancelModalCenter","cancelModalTitleSpace","modalTitleText","modalSubTitleText","modalActions","goBack","cancelConfirmation","modal","block","blockCashExpected","centerBlock","textWithTooltip","blockLongText","iconTooltipRoot","CashStateHeader","CashRegisterMovementType","backgroundImage","outline","outlineOffset","checkedIcon","Radio","disableRipple","Textarea","minRows","maxRows","onKeyPress","styles","TextareaAutosize","CloseCashRegisterRequest","cashAtTheEndOfTheDay","chargingUserId","chargingUserName","PaymentMethodType","RegisterCashRegisterMovementRequest","amount","CashOpening","CashRegisterSidebar","onCashRegisterClose","onRegisterNewMovement","mode","setMode","activeTab","setActiveTab","goBackModalIsOpen","setGoBackModalIsOpen","cancelCashClosureModalIsOpen","setCancelCashClosureModalIsOpen","Deposit","newMovementType","setNewMovementType","newMovementAmount","setNewMovementAmount","newMovementComments","setNewMovementComments","cashAtTheEndOfDay","setCashAtTheEndOfDay","withdrawalAmount","setWithdrawalAmount","closingCashComments","setClosingCashComments","isUserAbleToOpenAndCloseCash","isUserAbleToRegisterMovements","templatedCurrency","paymentMethodsContains","paymentMethod","hasClosingCashCommentsBeenFocused","setClosingCashCommentsBeenFocused","hasNewMovementCommentsBeenFocused","setNewMovementCommentsBeenFocused","hasNewMovementAmountBeenFocused","setNewMovementAmountBeenFocused","dateTimeFormat","handleTabChange","newValue","resetAllInputs","handleRegisterMovementClick","resetNewMovementInputs","handleCloseCashRegisterClick","resetCashClosingInputs","handleGoBackClick","resetComponent","handleRegisterMovementButtonClick","handleCloseCashButtonClick","addedCurrencyValue","subtractedCurrencyValue","getCurrencyFormattedNegativeString","actualCash","inputValue","difference","GoBackHeader","ArrowBackIos","DateHeader","TabsHeader","TabContext","indicatorColor","Tab","label","CashDataHeader","CashDetailsBlock","Cash","CreditCard","BankTransfer","Oxxo","MercadoPago","HistoryMovementBlock","movement","Withdrawal","getChipByMovementType","getTemplateByMovementType","userName","RequiredFields","InputLabel","NumberValue","CloseCashButton","Red","RegisterMovementButton","ButtonsFooter","GoBackModal","aria-labelledby","aria-describedby","closeAfterTransition","BackdropComponent","Backdrop","BackdropProps","timeout","Fade","in","CancelCashClosureModal","Drawer","sort","b","RadioGroup","defaultValue","FormControlLabel","control","AppointmentPaymentPartEntity","amountPaid","AppointmentPaymentEntity","friendlyId","parts","editingPart","editionType","AppointmentPaymentFormData","payment","paymentValues","changeRecords","PaymentsService","basePaymentsUrl","request","currentAppointmentId","recurringAppointmentIds","baseCashRegisterUrl","cashOpeningInfo","closeCashRegisterRequest","OpenCashRegisterRequest","CashRegisterMain","refresh","isOpenCashRegisterModalOpen","setOpenCashRegisterModalOpen","isMainCashRegisterSidebarOpen","setMainCashRegisterSidebarOpen","openCashRegisterFormData","setOpenCashRegisterFormData","cashRegisterCurrentState","isCashRegisterOpen","loadData","getCashRegisterCurrentState","cashRegisterState","handleCashIconButtonClick","getInitialCash","displaySuccessfulOpeningAlert","description","displaySuccessfulCashClosingAlert","openCashRegister","cashRegisterMovement","isPayment","newState","movementAmount","concat","closeCashRegister","newMovementRequest","registerMovement","fetchData","ExternalLink","useCustomerTerminology","applyInterpolation","arrayTerms","i","reg","RegExp","clinicTerminology","countInterpolationsInTargetString","terms","item","index","array","terminology","ns","Title","useLocation","titleNav","navTitles","path","menuItem","pathname","titleUrl","variant","NavBar","isLocationInitialized","setIsLocationInitialized","isExternalLingHover","setIsExternalLinkHover","hoverItemId","seHoverItemId","showReferFriend","drawerOpen","setDrawerOpen","toggleDrawer","accountNavBarMenu","isDisplayed","isParent","parentId","enterpriseNavBarMenu","navBarMenuItems","logout","handleShowReferralChange","AppBar","Toolbar","edge","valign","List","ListItem","onMouseHoverItem","clickMenuItem","ListItemIcon","onClickHandleExternalLink","Tooltip","to","ListItemText","primary","colorPrimary","barColorPrimary","LoaderLine","Box","sx","LinearProgress","progress","side","dndIconContainer","closeIconContainer","contentContainer","mainIconContainer","mainIconBackground","downloadProgressBar","downloadProgressBarEmpty","downloadProgressBarProgress","FileDownloadProvider","setPosition","cancelTokenSource","CancelToken","source","dispatchProgress","blob","URL","createObjectURL","Blob","link","document","createElement","setAttribute","body","appendChild","click","removeChild","finally","enableUserSelectHack","onStop","handle","cancel","Layout","showLoaderIsActive","wideScreenUrls","transitionDelay","Container","children","rememberMeLabel","inputBox","textInput","inputNormalWeight","inputBoldWeight","forgetLink","utilities","form","_extends","assign","arguments","apply","_objectWithoutProperties","excluded","sourceKeys","keys","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","propertyIsEnumerable","clipPath","_ref","svgRef","ForwardRef","forwardRef","page","wrapper","formWrapper","logo","ornamentLeft","ornamentRight","formFooter","backButton","AuthenticationLayout","hiddenLogo","required","EmailInput","onChangeHandler","TextField","InputProps","isError","helperText","inputSuccess","outlineSuccess","PasswordInput","isPasswordVisible","setPasswordVisibility","TogglePasswordVisibilityIcon","onMouseDown","Visibility","VisibilityOff","success","notchedOutline","endAdornment","InputAdornment","AppointmentTimeIntervalGapMinute","SchedulerBlockDurationMinute","NameRegex","EmailRegex","AlphanumericRegex","CurrencyRegex","NameRegexV2","MultipleSpacesNameRegex","MassiveSendingUrlRegex","Terminology","terminologyType","singularForm","pluralForm","TreatmentDocumentSize","AccountScheduleSectionSettingsModel","gapBetweenTimeIntervals","Thirty","EstablishmentCertification","imageS3Key","order","TreatmentDocumentFieldSettingsModel","documentSize","logoIsEnabled","logoUrl","logoFile","fieldSettings","shouldRemoveLogo","specialistJobPositionName","specialistPhoneNumberIso","specialistPhoneNumberBody","accountPhoneNumberIso","accountPhoneNumberBody","accountAddress","Letter","AccountService","establishmentAccountId","endpoint","countryCode","urlEndpoint","businessNameUrl","languageCode","certification","establishmentCertification","executeRecaptcha","useGoogleReCaptcha","loginState","setLoginState","validate","test","displayAlert","setLocaleAndRedirect","requestLocaleAndRedirect","getAccountLanguage","language","changeLanguage","log","loginEnterprise","login","LogInButton","formHeader","formText","formTextLine","formTextLineBold","sendButton","blockHeight","SuccessBlock","headerMessage","textMessage","Check","setEmail","completed","setCompleted","recoverPasswordEnterprise","recoverPassword","Trans","i18nKey","passwordStrengthMeter","passwordStrengthEmpty","passwordStrengthBad","passwordStrengthMediocre","passwordStrengthGood","passwordStrengthHint","confirmPasswordInput","successBlock","usePasswordValidation","hint","isGood","resetPasswordData","setResetPasswordData","confirmPassword","formState","setFormState","passwordStrength","passwordsAreEqual","resetPassword","GoToLoginButton","params","formHeaderText","AuthenticationRouter","wrapperCaptcha","reCaptchaKey","component","SMenu","styled","Menu","borders","grey3","SMenuItem","MenuItem","header6","flexWrap","SMenuItem2","ScheduleAppointmentActionsMenuContext","createContext","useScheduleAppointmentActionsMenuContext","ctx","useContext","ScheduleAppointmentActionsMenu","addAbsenceClick","transitionDuration","keepMounted","ScheduleAppointmentActionsMenuContextProvider","addAbsence","useCallback","dt","el","toJSDate","Provider","normalizeGroupKey","k","str","btoa","encodeURIComponent","p1","fromCharCode","replaceAll","getGroupKeyOffsetVariable","AppointmentSchedulerContext","React","useAppointmentSchedulerContext","generateStops","intervalInMinutes","stops","AppointmentSchedulerRootElementContext","AppointmentSchedulerInnerElementContext","element","setInnerElement","AppointmentSchedulerInnerElementContextProvider","DefaultContentGridTdComponent","Component","memo","groups","ContentGridTdComponent","contentGridRootRef","TdComponent","rowHeight","columnWidth","innerHeight","innerWidth","cellData","stopsInterval","gridInnerRef","setGridInnerRef","gridOuterRef","setGridOuterRef","columnCount","rowCount","innerRef","outerRef","outer","itemData","clsx","grid","innerElementType","Inner","willChange","Cell","ReactDOM","createPortal","gridChildren","columnIndex","rowIndex","group","ts","startTimestamp","stopTimestamp","PassThroughWrapper","AppointmentSchedulerContent","renderContentGrid","pixelsPerMinute","ContentInnerWrapperComponent","renderColumns","renderItems","getItemGroupKey","getItemData","getItemKey","items","ContentGridColumnComponent","getGroupKey","column","PureComponent","Items","_renderItem","sizeInMinutes","groupKey","positionInPixels","sizeInPixels","data-group","data-ts","cell","AppointmentSchedulerHeader","classNameCorner","CornerComponent","classNameInner","classNameCell","innerElement","headerRef","scroll","scrollLeft","addEventListener","removeEventListener","corner","inner","g","AppointmentSchedulerTimeline","showTimezone","asideRef","scrollTop","timezone","ianaName","timeZone","IANAZone","hrsOffset","formatOffset","toMillis","timezoneShortName","offsetName","startsWith","GetOffsetLabel","zoneName","mark","visibility","AppointmentScheduler","range","sizes","headerHeight","timelineWidth","components","HeaderCellComponent","StopComponent","ItemComponent","onScrollChanged","scrollControllerRef","onScroll","scrollTopMinutes","scrollBottomMinutes","scrollHeight","rootElement","setRootElement","contentGridRoot","setContentGridRoot","rootElementSize","setRootElementSize","scrollController","SchedulerScrollControllerImpl","resizeDetectorRef","useResizeDetector","onResize","v","cssProps","fromEntries","actualColumnWidth","max","headerRoot","timelineRoot","contentRoot","minColumnWidth","_element","_pixelsPerMinute","scrollTo","closure","clientHeight","boxSizing","whiteSpace","rootBlocked","rootMultipleBlocked","multipleBlockerTitle","caption1","multipleBlockerDate","caption2","arrived","notArrived","confirmed","notConfirmed","blocked","contentNotArrive","customerTitle","grey7","customerTitleBlocked","customerNotArrived","hoursText","hoursTextBlocked","personChargeText","isAppointmentCustomerSite","personChargeTextBlocked","tooltipContainer","tooltipCustomerNameBox","tooltipAppointmentTime","tooltipUserName","personWithDot","serviceItemText","serviceItemsList","serviceItemsTooltipList","serviceSingleItemText","serviceListItem","establishmentRow","AbsenceBlock","absence","leftOffset","topOffset","pixelPerMinute","overrideDuration","rootElRef","startDt","diff","as","rootEl","setProperty","scrollbarParent","node","parentElement","dataset","scrollParent","classList","contains","getScrollableParent","parentRect","getBoundingClientRect","rootRect","rootElementOffset","dateFormat","toTimeString","split","role","isBlockedMultiple","data-absence-id","allDay","isBlockedReasonPredetermined","blockedReason","specialist","plusBtn","scale","transition","AbsenceItem","actionsPopupMenu","absences","rootRef","idx","originalAbsence","totalCount","clientX","clientY","useAppointmentCardStyles","AppointmentCard","enableTooltip","scrollIntoView","elementRef","isNotArrived","NotArrived","PopperProps","popperOptions","positionFixed","Arrived","Confirmed","getStatus","Customer","modalPaper","modalHeader","modalHeaderContent","modalClose","closeButton","modalTitle","modalContent","modalCircle","modalCenter","modalTitleSpace","modalContentText","modalDateText","deleteAppointment","separator","borderTop","AppointmentDeleteModal","onDelete","disableButton","setDisableButton","TextareaWithLabel","labelClass","inputReadOnly","onClickInput","onBlurInput","LabelComponent","inputId","htmlFor","Service","categoryId","category","recurrenceId","recurrence","photoName","photoURL","file","Response","entity","total","SelectGroupServiceModel","ServiceGroupModel","ServicesService","pageSize","orderBy","properties","property","AccountId","forbiddenDelete","recurrences","CreateFollowUpModel","GetMobileMaskByTemp","create","createDisabled","requiredText","requiredSymbol","labelText","selectStyle","inputTextareaClass","labelNotes","divClock","float","dateRoot","selectedDate","stepCaption","dateNotSelected","dateSelected","ulSchedule","listStyle","liSchedule","flex","liScheduleActive","selectService","selectRoot","itemRoot","itemSelected","divFlag","divCode","divMobile","CountryAllIcon","CountryDEUIcon","CountryAGOIcon","CountryARGIcon","CountryBOLIcon","CountryBRAIcon","CountryCANIcon","CountryCHLIcon","CountryCOLIcon","CountryCRIIcon","CountryECUIcon","CountryESPIcon","CountryGBRIcon","CountryUSAIcon","CountryGTMIcon","CountryHNDIcon","CountryMEXIcon","CountryNICIcon","x1","y1","x2","y2","gradientUnits","stopColor","CountryPANIcon","CountryPRYIcon","CountryPERIcon","CountryPRTIcon","CountryDOMIcon","CountryTTOIcon","CountryURYIcon","CountryVENIcon","CountryCUBIcon","stroke-width","maskType","CountryAUSIcon","stop-color","CountryBELIcon","CountryNORIcon","CountryPRIIcon","filterUnits","color-interpolation-filters","flood-opacity","dy","in2","CountrySWEIcon","CountrySVKIcon","CountryFRAIcon","CountryITAIcon","CountryFlagIcon","InputState","iso","CountrySLVIcon","AppointmentFollowUp","appointmentDetails","setIsValid","timePickerValue","setTimePickerValue","dateValue","setDateValue","setAvailableDays","setServices","groupServices","setGroupServices","setServiceId","setNotes","loadServices","getServicesGroupByCategory","selectArray","isGroup","OverriddenDateFnsUtils","DateFnsUtils","loadAvailableDays","getAvailableDays","days","Grid","spacing","xs","min","date1","followUp","createFollowUp","utils","esLocale","options","weekStartsOn","enLocale","getLocale","DatePicker","autoOk","disableToolbar","fullWidth","openTo","renderDay","dayInCurrentMonth","dayOff","getDay","isCurrentDate","isSelected","shouldDisableDate","disableFuture","alignContent","showNow","onOk","timePicker","disableUnderline","displayEmpty","renderValue","svc","categoryService","MenuProps","getContentAnchorEl","conformToMask","conformedValue","overflowY","scrollbarWidth","headerActions","headerSubText","headerButtons","modalActionsAppt","modalActionFont","modalActionFirst","modalActionLast","bodyContent","row","subsection","caption","recurringAppointmentInfo","paymentRow","paymentInfo","paymentAmount","recurringAppointmentPaymentText","paymentButton","clearLilac","newHeader","headerTitle","headerChargingInfo","headerChargingUserName","headerChargingPaymentId","marginTopBottom","paymentProgressBar","paymentProgressBarLegend","paymentProgressBarLegendItem","paymentProgressBarLegendIcon","paymentProgressBarLegendText","paidIcon","unpaidIcon","progressBarPaid","progressBarUnpaid","controlText","textArea","servicesDetail","servicesDetailRow","servicesDetailColumn","servicesDetailServiceBlock","servicesDetailDivider","servicesDetailHeader","servicesDetailSubheader","servicesDetailText","servicesDetailValue","servicesDetailDiscount","servicesDetailTotal","servicesDetailPaidWith","greenText","changeRecordBlock","changeRecordRow","changeRecordLeftColumn","historyRightColumn","historyRightColumnStrike","initialValuesBlock","initialValuesRow","initialValuesLeftColumn","changeRecordDivider","registerPaymentButton","chip","accordionSummary","accordionTitle","itemHeight","select","menuPaper","maxHeight","SelectKey","styleClass","itemRootClass","arrowIcon","colorArrowIcon","menuProps","useClasses","IconComponent","idleRoot","idleValue","editRoot","editSaveButton","editSaveIcon","InputEditableItem","setValid","actualMaxLength","setError","Idle","inputState","setInputState","handleSaveButtonClick","errorMessage","SaveButton","Edit","DiscountType","inputSelect","tooltipBlock","menuPaperDisableScroll","Select","disableScrollLock","onRender","showTooltip","selectRef","isTooltipOpen","setTooltipOpen","isSelectOpen","setIsSelectOpen","setTooltipText","tooltip","onRenderHandler","onOpen","firstChild","offsetWidth","scrollWidth","onMouseEnterItem","InputEditableWithSelectItem","selectValue","selectItems","subTotal","currentValue","displaySelectValue","Percentage","setDisplaySelectValue","mouseEvent","Value","calculateValue","PaymentEditionType","InputDateWithLabel","minDate","maxDate","keyboardIcon","modalCancelPaper","deleteContact","accordion","addButton","separatorWithoutLine","accordionDetails","AppointmentPaymentPart","paymentPart","excludedPaymentMethodTypes","allowedPaymentMethods","pm","setPaymentPart","part","AddAmount","SubtractAmount","getAmountPaidTitle","AppointmentPaymentParts","onAdd","p","openModal","setOpenModal","setPart","indexPart","setIndexPart","expandedAccordionIndex","setExpandedAccordionIndex","handleOnChange","Accordion","expanded","handleAccordionChange","AccordionSummary","expandIcon","aria-controls","handleDeletePart","AccordionDetails","AppointmentPaymentPartsEdit","AppointmentPaymentSidebar","paymentEntity","setPaymentEntity","onSave","isUnchanged","recurredAppointmentOrder","paidPreviously","newDate","firstDayOfCurrentYear","firstDayOfNextYear","dateAndTimeFormat","editionTypes","servicesValid","setServicesValid","cashRegisterIsOpen","setPaymentDate","setEditionType","setPaymentNotes","totalToBePaid","discountType","discountAmount","countTotalToBePaid","partsSum","reduce","sum","editingAmount","countPaidAmount","countPendingToBePaid","toBePaid","pendingToBePaid","change","countChange","paymentActualProgress","paymentProgress","doCancel","setActiveTabToHistory","handleCloseDrawer","drawerOnClose","getSaveButtonTitle","isSaveButtonDisabled","every","currencySelectList","getPaymentMethodName","formatChangeRecordField","fieldValue","changedField","join","setParts","handleOnChangePart","arrParts","handleAddPart","displayFriendlyId","Array","historyData","RegisterPaymentChip","ChargingUserHeader","PaymentProgressBar","RegisterPaymentButton","PaymentContent","inputTextClass","categoryName","newServices","setPaymentServicePrice","newValid","setServiceValid","setPaymentDiscount","editionSign","sign","paidWithList","isFirstPaymentHistoryBlock","discount","trim","changeRecord","formatChangedField","AppointmentPaymentService","previouslyPaid","newPayment","CustomRecurrenceMode","WeekDaysFlags","saveAppointment","radioOption","RecurringAppointmentDeleteModal","selectedOptionToDelete","setSelectedOptionToDelete","mainItem","mainItemText","itemDot","itemText","selectedItemText","AppointmentStatusSelector","appointmentStatus","handleAppointmentStatusChange","getDotStatus","getTxtStatus","handleListItemClick","AppointmentItemTooltip","appointmentMeta","visible","onHide","onDeleteButtonClick","hubConnection","setTarget","setAppointment","setAppointmentDetails","appointmentPayment","setAppointmentPayment","oldAppointmentPayment","setOldAppointmentPayment","appointmentPaymentFormData","setAppointmentPaymentFormData","firstService","setFirstService","openModalDelete","setOpenModalDelete","openModalFollowUp","setOpenModalFollowUp","isPaymentsSidebarOpen","setPaymentsSidebarOpen","itemId","paymentsSidebarMode","setPaymentsSidebarMode","openModalActionDots","setOpenModalActionDots","showRecurringAppointmentDeleteModal","setShowRecurringAppointmentDeleteModal","paymentButtonDisable","setPaymentButtonDisable","isUserAbleToRegisterPayments","isPaymentSidebarEnabled","canMakePayment","oldAppointmentPaymentAmountPaid","frequencyWeek","getAppointmentTooltip","loadPaymentData","getRecurringAppointmentPaymentFormData","getPaymentFormData","isNew","getAppointmentPricedServices","somePaymentsExist","updatePaymentInfo","currentAppointment","updateAppointmentsPaymentStatus","handleUpdateAppointmentData","newAppointmentStatus","handleStatusChange","updateStatus","appointmentTotalPrice","currentServicePrice","reason","handleDelete","resetAppointmentPaymentForm","setAppointmentPaymentValues","setAppointmentPaymentChangeRecords","createdPayment","setEditModeOnPaymentCreation","update","editedPayment","isBlocked","Paid","PaidPartially","getPaymentStatusColor","getTxtPaymentStatus","totalPrice","getAppointmentPriceByPaymentStatus","count","filtered","longDay","toLocaleDateString","toLowerCase","formatDay","modeString","modeStringEnding","Month","daysOfWeek","weekDaysFlags","chosenDays","getChosenDaysOfWeek","getRecurringWeekByDay","getStartEndTime","isCreated","Colors","AppointmentTicket","dragZone","setAnchorEl","isAppointmentPopupOpened","setIsAppointmentPopupOpened","useDrag","canDrag","collect","monitor","didDrop","drag","onDragEnd","scrollbarStyle","opts","widerHorizontal","Neutral3","Neutral5","Neutral7","useAppointmentItemListStyles","labelContainer","clear3","AppointmentItemList","groupedAppointments","elevation","marginThreshold","additionalBlock","plusBtnContainer","AppointmentItem","appointmentGroup","openAppointmentItemList","setOpenAppointmentItemList","firstAppointment","isGrouped","advisorId","widthMultiplier","getWidth","renderPlusButtonsForSlots","hasAdditionalBlock","minStart","maxEnd","slots","slotDuration","totalDurationInMinutes","totalSlots","floor","slotIndex","slotTime","plus","AppointmentGridItemComponent","absenceGroup","ActiveColumnOverlay","ColumnDecorations","noop","Cursor","setElement","isSame","millisecondsPerPixel","intervalTime","m","pos","interval","setInterval","clearInterval","full","Stop","add","getSlice","startOfDay","endOfDay","startOf","startsAt","endsAt","blockStart","blockEnd","parentGroupKey","tryAddToGroup","intersectsWithGroup","createEmptyGroup","createAbsencesGridItems","dayGroups","absencesSorted","sortBy","dayStr","fromFormat","groupIntersectingAbsencesByDays","createAbsencesGridItemsForDay","groupIds","groupsMapping","dayFilter","groupId","specialistId","applicableGroupIds","applicableGroupId","groupIntersectingAbsencesByUser","createAppointmentsGridItems","appointmentGroups","groupAppointments","sortedAppointments","getKey","groupBy","dateTime","flatMap","innerGroups","j","useSchedulerCommonStyles","dayName","header5","num","active","AppointmentsHeaderCellComponent","dayKey","isoWeekday","rgba","transparency","exec","modalDateTextContainer","DragNDropConfirmationModal","toDateTime","onContinue","selectedOptionToUpdate","setSelectedOptionToUpdate","fromJSDate","getNewEndDateTime","td","actionOverlay","userSelect","wd","dayNumber","openingSplitted","opening","openingHour","openingMinutes","openingHourDecimal","roundedOpeningHourDecimal","ceil","closingSplitted","closing","closingHour","closingMinutes","closingHourDecimal","roundedClosingHourDecimal","cellStartHour","isCellOpenedInSchedule","hovered","setHovered","droppedAppointment","setDroppedAppointment","useDrop","accept","canDrop","drop","isOver","updateTime","aria-hidden","onMouseOver","handleMoveAppointment","useLocalStorageState","itemKey","dispatchFunction","_setItem","localStorageItem","parsedItem","newItem","AppointmentGroupingCorner","SchedulerGroupingEnterprise","SchedulerGrouping","schedulerGrouping","setSchedulerGrouping","arrow","clear1","getAppointmentKey","getAppointmentGroupKey","getAppointmentData","ContentInnerWrapper","activeGroupKey","WeekScheduler","dateReference","setScrollController","monday","millisecond","_","clone","app","toFormat","scrolledRef","scrollAtCenterInMinutes","_event","onScrollChangedDebounced","debounce","gridItems","est","DaySchedulerDateContext","DayScheduler","es","BlockSchedule","blockedReasonId","BlockedScheduleService","forceSave","blockSchedule","blockedschedule","BlockedSchedule","forbiddenToBlock","appointmentsNotServed","blockedSchedules","entries","DateFrom","DateTo","EstablishmentIds","flat","it","UserCommissionType","CommissionType","UsersResponse","totalUsers","UserModel","authenticationId","hasServicesInCharge","servicesInChargeCount","UserGeneralInfo","photoS3Key","mobileNumber","jobPosition","UserScheduleInfo","schedule","UserScheduleDay","dayOfWeek","windows","UserScheduleWindow","timeStart","timeClosing","UserServicesInfo","serviceCategories","UserCommissionInfo","isCommissionEnabled","userCommissionType","initialUserCommissionType","commissionType","commissionValue","commissionsByServices","isArray","Absolute","ByService","localeCompare","UserPermissionsInfo","hasAdminAccess","notifyOnServiceInCharge","notifyOnCustomerRequiresAttention","notifyOnCashRegisterClosing","showAllAppointments","UserProfessionalInfo","fieldsAndValues","signatureImageUrl","signatureReactCanvasDrawJson","signType","uploadedSignatureWasDeleted","UserEntity","general","commission","permissions","professionalInformation","IsUserPhoneDuplicatedModel","isDuplicated","userFirstName","userLastName","IsUserEmailDuplicatedModel","userFullName","UserService","signatureImage","File","onlyWithServicesInCharge","userSchedule","appointmentCount","userUpcomingAppointmentsCount","disabledServicesIds","iso3Code","phoneNumber","MultiselectOverflowRenderType","dateNavigator","dateNavigatorText","dateNavigatorDayText","dateNavigatorDirectionButton","multiSelect","newAppointment","goToday","establishmentSelectorWrapper","viewSelect","appointmentsSelect","specialistsSelect","searchContainer","menuList","checkbox","noBorder","inputSearchClass","searchIcon","InputSearch","onSearch","onReset","rootClass","disabledCheckbox","textChecked","CheckboxWithLabel","checked","setChecked","disableRippleEffect","checkboxClass","Checkbox","MultiSelect","maxValues","allItemsPlaceholder","filterPlaceholder","overflowRenderCap","overflowRenderType","showSearch","showIconComponent","overflowCap","setFilter","restrictValuesCount","trimValuesSelection","restrictValuesSelection","displayItems","isHidden","flt","multiple","names","Dots","namesString","onKeyDown","hidden","dateIcon","datePicker","DateIcon","aria-haspopup","EstablishmentSelector","itemIds","removedEstablishments","newEstablishments","establishmentNames","handleOpenTooltip","handleCloseTooltip","disableHoverListener","disableTouchListener","disableFocusListener","Input","containerClass","inputType","step","AppointmentListToolbar","saveSelectedUsers","saveSelectedStatuses","currentUserAuthId","Establishments","accountEstablishments","setAccountEstablishments","views","changeCurrentDate","viewName","SchedulerViewName","handleNavigate","direction","Gray","parsedCurrentDate","formattedDate","MinusArrow","draggableModalHeader","createCustomer","iconTrash","modalConfirm","confirmModalPaper","modalConfirmTitleText","modalConfirmSubTitleText","body2","modalActionsConfirm","SelectWithLabel","rootStyle","switchBase","thumb","track","grey","focusVisible","Switch","baseClass","focusVisibleClassName","BlockedReason","isPredetermined","isEdit","BlockedReasonService","blockedReasons","blockedreason","w","labelCategory","optional","divDropdown","inputSelectBtn","pointerEvents","iconDropdown","divModalSelect","listCategoryScroll","listCategory","textOverflow","btnNewBlockedReason","elementList","divInputEdit","iconPlus","verticalAlign","iconSave","divItemEdit","btnInputNew","classRow","btnRow","deleteCategory","editCategory","divIconsRow","divNew","divTitle","BlockedReasonSelect","widthSelect","widthList","isOptional","onSelect","placeholderInput","setList","showNew","setShowNew","reasonSelected","setReasonSelected","reasonNew","setReasonNew","handleEditItem","newList","updatedItem","getBlockedReason","reasonList","saveReasonEdit","updateBlockedReason","saveBlockedReasonNew","createBlockedReason","deleteBlockedReason","handleOpenModal","newCat","DateInput","allowManualInput","handleOnKeyPress","inputVariant","WeekdaysEnum","rowContainer","switch","switchLabel","inputSpecialist","divUploadPhoto","backgroundRepeat","backgroundSize","backgroundPosition","colPhoto","colNotes","inputTextareaNotes","notesInstructions","labelAddPhoto","labelAddPhotoIns","divPhotoInfo","divPhotoInfoIcon","divPhotoInfoLabel","divPrice","moneyIcon","divCategory","divPhotoExistHover","iconCam","labelChangePhoto","selectHrsNotValid","selectHrs","selectStyleHrs","labelH2","dateText","clockPosition","InputWithLabel","BlockScheduleForm","validator","dateFromSchedule","userIdFromSchedule","EntityForm","entityState","setEntityState","changing","newEntity","added30Min","setMinutes","hhmm","endOf","df","handleStartTime","disabledHours","handleEndTime","BlockScheduleModal","draggableId","cancelModal","setCancelModal","confirmBlockModal","setConfirmBlockModal","counterAppointments","setCounterAppointments","isChanged","setIsChanged","setIsEdit","setUsers","setUserName","setEntity","entityInit","reasonId","entityValid","setEntityValid","loadUsers","getUsersBaseInfoByAccount","usersDb","currentUser","getBlockedSchedule","getBlockedScheduleById","handleOnCreateClick","entityToSave","createBlockedSchedule","updateBlockedSchedule","handleOnDeleteClick","deleteBlockedSchedule","runValidations","handleForceSave","onDrag","bounds","isSameObj","Weekday","WeekdayService","appointmentsAffected","weekdays","borderTopWidth","borderTopColor","borderTopRadius","blocker","blockerReason","blockerTimeRow","blockerSpecialist","MultipleBlockedScheduleModal","modalMain","editAppointmentLink","textDecorationColor","editAppointment","AppointmentDragAndDropScheduleBusyModal","AppointmentList","isLoaded","setIsLoaded","setAppointments","setAbsences","lastCurrentViewName","setLastCurrentViewName","appointmentsLoadedForDate","setAppointmentsLoadedForDate","handleUserHasServicesInChargeChange","appointmentToUpdateIndex","newAppointments","newUsers","getAppointmentCalendarById","getSplitByServicesAppointmentCalendarById","apps","_setTooltipAppointments","loadBlockedSchedule","getBlockedScheduleByEstablishments","getBlockedScheduleByAccount","mappedBlockers","mapBlockerToSingleOrMultipleAbsence","forceAppointmentsClean","startOfWeek","endOfWeek","getSplitByEstablishments","getByAccount","getSplitByServicesAppointmentsByAccount","storageKey","SchedulerSelectedStatusesEnterprise","SchedulerSelectedStatuses","json","constructor","loadDayOff","loadWeekDays","loadAppointments","usersOnlyWithServices","getUsersBaseInfoByEstablishments","isSelectedUsersSet","SchedulerSelectedUsersEnterprise","SchedulerSelectedUsers","removeUsers","getWeekdaysForEstablishments","getWeekdays","spl","hourDecimal","roundedHourDecimal","Saturday","Sunday","DndProvider","backend","HTML5Backend","CreateAppointmentService","SelectWorkAreaModel","Workarea","hasSimultaneousServices","WorkareasService","workarea","workareas","useDebounce","delay","debouncedValue","setDebouncedValue","handler","clearTimeout","labelItem","listItemScroll","itemValue","iconSearch","itemNoSelected","classRowDisabled","divSearch","menuPlacementTop","inset","SelectSearch","placeholderSelect","iconSelect","setItemSelected","search","setSearch","debouncedSearchValue","dropdownRef","menuRef","setMenuPlacementTop","searchValue","removeAccents","menuHeight","bodyRect","elemRect","openTop","windowHeight","normalize","onBackdropClick","handleItemSelected","selectHr","selectMin","formItem","appointmentService","desiredUserId","servicesArr","setServicesArr","usersArr","setUsersArr","workAreasArr","setWorkAreasArr","workAreas","setWorkAreas","utcOffset","set","setEstimatedDuration","timePickerIsOpen","setTimePickerIsOpen","setAppointmentService","loadWorkAreas","desiredUser","setUserByValue","getServicesSelect","arrServices","getUsersByServiceId","getWorkAreasSelect","cat","selectedService","handleDurationTimeChange","getTimePickerDurationPostfixClass","onOpenChange","firstElement","deleteButton","AppointmentServices","setService","indexService","setIndexService","handleDeleteService","stepTitle","header2","servicesHeader","servicesTitle","flagIcon","AppointmentStepOne","AppointmentRecurrenceInterval","subHeader","subTitle","dateTimeSubTitle","switchSubTitle","calendarIcon","dateTimeContent","dateTimeTxt","requiredField","calendarScheduler","rootCalendar","calendar","scheduleContent","scheduleInvalid","calendarNoTime","calendarTitle","calendarSubTitle","labelAppointment","scheduleDisabled","modalTitleTextCancel","inputContainer","arrowContainer","arrowUp","borderRight","arrowDown","cellWithTooltip","arrowButtonContainer","cancelCustomRecurrenceModal","closeModalContentContainer","closeModalTitleText","subhead","inputInfo","marginLeft10","marginRight10","daysWeekContainer","daysWeekTitle","modalContentTextTitle","confirmButton","ConfirmActionModal","onConfirm","buttonClass","classModal","confirmButtonText","RecurrenceModalData","customRecurredAppointmentsCount","CircleCheckbox","tooltipTitle","CheckboxComponent","CustomRecurrenceModal","handleConfirm","recurrenceInterval","setRecurrenceInterval","recurrenceItemId","setRecurrenceItemId","recurrenceAfterAppointments","setRecurrenceAfterAppointments","isValidRecurrenceAfterAppointments","setIsValidRecurrenceAfterAppointments","isValidRecurrenceInterval","setIsValidRecurrenceInterval","cancelCustomRecurrenceModalIsOpen","setCancelCustomRecurrenceModalIsOpen","inputDataHasChange","setInputDataHasChange","recurrenceWeekDays","setRecurrenceWeekDays","frequencyItems","inputDataIsValid","isRecurrenceAfterValid","isRecurrenceIntervalValid","forWeekModeDayIsChosen","Week","handleCheckboxChange","prevDays","CancelCustomRecurrenceModalContent","currentDayIndex","handleRecurrenceSelect","Monday","Tuesday","Wednesday","Thursday","Friday","isNotValid","modalData","Gender","AppointmentStepTwo","step1Valid","isEdition","refreshData","onRecurringChange","setAvailableHours","isAvailableHoursLoad","setIsAvailableHoursLoad","setSchedule","isNewAppointmentViaScheduler","desiredDate","setDesiredDate","isRecurringAppointment","setIsRecurringAppointment","customRecurrenceModalIsOpen","setCustomRecurrenceModalIsOpen","isCustomRecurrence","setIsCustomRecurrence","setCustomRecurrenceInterval","setCustomRecurrenceMode","customRecurrenceAfterAppointments","setCustomRecurrenceAfterAppointments","setCustomRecurrenceWeekDays","setIsCustomSchedule","setScheduledSimultaneousServices","recurrenceItems","setRecurrenceItems","customStartTime","setCustomStartTime","isValidRecurrence","setIsValidRecurrence","isValidEndRecurrence","setIsValidEndRecurrence","availableHoursDelayRef","loadAvailableTimeObservableValuesRef","loadAvailableTimePrevDateRef","isDaysOffLoadRef","servicesHaveRepeatedUsers","prevUser","observableValues","observableValuesString","prevObservableValues","prevStartDate","currentStartDate","loadAvailableHoursWithDelay","loadAvailableDaysIfNeed","appointmentStartDate","currentStateStartDate","getEstimatedDurations","fromDate","toDate","CustomRecurrenceSaved","durations","prev","next","getDurations","desiredSchedule","h","validateRecurring","isCustomRecurrenceWeekDaysModeChoose","newStateAppointment","firstAvailableHour","afterAppointments","recurrenceString","getAvailableHours","availableSchedule","disablePast","isCustomRecurrenceDay","availableHour","handleCustomStartTimeChange","minuteStep","CustomRecurrenceDefault","nextAvailableDayFlag","nextAvailableDate","updatedRecurrenceItems","Autocomplete","getOptionSelected","getOptionLabel","renderOption","filterOptions","cleanInput","onSelected","setInputValue","changeReason","setChangeReason","debouncedInputValue","freeSolo","autoComplete","autoHighlight","onInputChange","renderInput","labelCountry","searchInputContainer","searchIconContainer","titleCountries","divDialCode","inputFlag","divCodes","listCountryScroll","listCountry","countryName","inputClassic","inputGroup","InputMobileCode","heigthList","requiredDotClass","codeIso3","onChangeItem","onChangeMobile","onChangeComplete","setSmbPhoneNumber","countrySelected","setCountrySelected","setMobileNumber","setSearchValue","masking","setMasking","isValidNumber","setIsValidNumber","mobileComplete","digits","validDig","listCountries","countryByIso","country","placeholderChar","valid","handleSearch","lowercaseSearchValue","isSearchByDialCode","filterCountries","newNumber","CustomerEntity","birthDate","gender","customGender","contactableAppointments","contactableMassiveSendings","isMobileDuplicate","legend","fieldsContainer","infoContentRow","captionValue","CustomerNotifications","customer","setCustomer","appointmentDescription","massiveSendingsDescription","SectionFieldType","CustomerGeneral","appDispatch","mobilePhoneDuplicated","isModal","setIsDuplicated","minBirthDate","yesterdayDate","Custom","customerValid","setCustomerValid","updateCustomerNameHeaderTitleNav","handleBirthdayChange","birthdate","handleMobileChange","handleMobileCodeChange","handleValidMobile","mobilePhone","customerEntity","CustomerData","frequencyType","attended","servicePrice","serviceTimes","created","Inactive","CustomersResponse","customers","totalCustomers","CustomerInfoDetails","emergencyContacts","CustomerSearch","CustomerHistory","yearMonth","monthYear","PatientDataResponse","dateOfBirth","customerFrequency","contactable","arrivedAppointmentsCount","totalAppointmentsCount","favoriteServiceName","favoriteServiceRequestedCount","totalServicesCount","evolutionNoteSectionName","evolutionNoteFieldsLastUpdated","evolutionNoteFieldsValues","PatientGeneralInfoResponse","patientFormSections","FormFieldItemValue","fieldItemId","FormRadioValue","additionalFreeTextValue","FormPhoneNumberValue","countryIso","EvolutionNotesGrouped","evolutionNotes","vitalSignsFields","EvolutionNote","dateCreated","editMode","evolutionNoteText","diagnosis","additionalInstructions","clinicalFiles","treatments","studies","vitalSigns","EvolutionNoteDynamicInput","EvolutionNoteTreatmentInput","medication","prescription","EvolutionNoteClinicalFile","fileURL","s3Key","evolutionNoteId","fileComment","uploadedBy","fileBlob","FileUploadResponse","uploaded","fileSizeInBytes","UpdatePatientFormDataResponse","isDuplicatedPhoneNumber","duplicatedPatientId","CustomerClinicalFile","comments","EvolutionNoteResponse","evolutionNotesGrouped","sectionFields","vitalSignSectionName","PatientClinicalHistoryTabDataResponse","canAcceptPrivacyNotice","canReadConsentLetter","hasAcceptedPrivacyNotice","hasReadConsentLetter","signature","ip","formSignedAt","isFormSignedAtEstablishment","observations","phoneNumberIso3Code","phoneNumberBody","clinicalHistorySections","CustomersByIdResponse","EmergencyContact","relationship","CustomerLastAppointment","CustomerService","contactsIds","contactIds","contactId","fv","objectValue","getJsonObjectValue","patientFormSectionFields","clonedRequest","structuredClone","field","isRequired","PhoneNumber","fieldAndValue","note","evolutionNote","responseType","patientClinicalFiles","fileUrl","phoneObj","radioObj","CustomerModal","onDuplicate","onCreate","_setCustomer","_setIsValid","countryDefault","setCountryDefault","customerRef","isValidRef","titleTerminology","listener","createdCustomer","isUndefinedOrEmpty","validateMobile","validGroup","validName","validLastName","validMobile","validEmail","validGender","customerSection","txtBody1Bold","personInCharge","txtBody2Bold","lineSeparator","customerInfoTitle","label1","label2","radioRoot","radioConfirmed","radioArrived","radioNotArrived","radioPaid","radioUnpaid","customerListOverrides","customerList","customerListSelected","buttonNewCustomer","infoIcon","titleContainer","appointmentsContainer","appointmentsHeader","emptyContentContainer","emptyContentTitle","emptyContentBody","appointmentsList","scrollbarColor","appointmentCardContainer","appointmentCard","serviceItem","serviceTime","serviceSpecialist","postServiceNotes","notesTitle","notesContent","seeMoreToggle","seeMoreButton","seeMoreButtonText","CustomerLastAppointmentsBlock","visibleAppointments","setVisibleAppointments","expandedNotes","setExpandedNotes","containerHeight","setContainerHeight","listRef","EvolutionNotesContent","handleNoteExpansionToggle","NotesContent","removeHtmlTags","toggleText","EmptyContent","AppointmentsContent","setLocale","cards","querySelectorAll","totalHeight","totalCards","behavior","getAppointmentsTitle","AppointmentCustomerSection","customerModal","setCustomerModal","customersSearch","setCustomersSearch","terminologyCreateNewCustomer","terminologyFindCustomer","getCustomerInfoDetails","loadSearchData","getSearch","mobileFormat","getCustomerLastAppointmentsDetails","customerWithAppointments","decodeURIComponent","atob","charCodeAt","getUser","option","handleCustomerSelected","customerSearched","AppointmentScheduleBusyReason","modalYellow","modalPaperYellow","btnCancel","btnOk","ExclamationModal","okTextButton","normalText","scheduleText","AppointmentScheduleBusyModal","appointmentBusyModalData","setAppointmentSchedule","BusyScheduleInfo","RecurringAppointmentUpdateModal","onUpdate","appointmentSection","breadcrumb","breadcrumbContainer","boldFont","totalPriceBoldText","totalPriceText","goBackCancel","BusyScheduleQuestionModal","seconds","getDuration","AppointmentBusyModalDataModel","AppointmentWorkAreaBusyModal","OutsideBusinessHoursModal","onCancel","AppointmentOutsideScheduleModal","appointmentBusyModalReason","OutsideUserScheduleTime","OutsideUserScheduleTimeAndOutsideBusinessHours","textLine","bold","TimeIsBusyAnotherAppointmentCanNotContinueModal","AppointmentDetails","useParams","setDeleteAppointment","updateRecurringAppointment","setUpdateRecurringAppointment","setStep1Valid","step2Valid","setStep2Valid","deleteModal","setDeleteModal","showRecurringAppointmentUpdateModal","setShowRecurringAppointmentUpdateModal","openExclamationScheduleBusyModal","setOpenExclamationScheduleBusyModal","openOutsideScheduleModal","setOpenOutsideScheduleModal","openQuestionScheduleBusyModal","setOpenQuestionScheduleBusyModal","openAppointmentWorkAreaBusyModal","setOpenAppointmentWorkAreaBusyModal","openOutsideBusinessHoursModal","setOpenOutsideBusinessHoursModal","openTimeIsBusyAnotherAppointmentCanNotContinueModal","setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal","setAppointmentBusyModalData","refreshAvailableHours","setRefreshAvailableHours","getTemplatedCurrencyValue","loadAppointmentDetail","totalServicesPrice","setAppointmentBusyData","TimeIsBusyAnotherAppointment","BlockedScheduleTime","WorkAreaIsBusyAnotherAppointment","OutsideBusinessHours","TimeIsBusyAnotherAppointmentCanNotContinue","openScheduleBusyModal","updateAppointment","appointmentUpdate","handleContinueScheduleBusyModal","Breadcrumbs","Link","underline","AppointmentNew","isClicked","setIsClicked","recurringCount","setRecurringCount","setIsRecurring","eventAppointment","AppointmentRouter","exact","classification","titles","icons","CustomerClassificationItem","MainIcon","line","CustomerClassification","frequent","infrequent","inactive","dropZone","animation","dropZoneText","fileSize","fileSizeBold","downloadTemplate","cancelModalButton","FileService","CustomerImportModal","refreshCustomers","openCancelModal","setOpenCancelModal","cancelModalShouldAppear","setCancelModalShouldAppear","templateFileName","setFile","setFileSize","setFileName","customerListUpdatedTitle","customersNotImportedDescription","cleanupModal","handleTryCloseModal","createCustomersFromFile","uploadResponse","processed","handleOnDownloadClick","responseFile","parentNode","validateFile","pop","getTemplateFileUrl","pt","dropzoneClass","dropzoneParagraphClass","fileObjects","dropzoneText","files","EPSILON","showPreviewsInDropzone","showAlerts","filesLimit","acceptedFiles","maxFileSize","onDropRejected","Icon","ArrowDrop","propertyName","hover","dropdown","tableHeader","visuallyHidden","clip","arrowDropdown","arrowShow","arrowHide","totalResultText","EnhancedTableHead","columns","onRequestSort","setHover","modalFilter","setModalFilter","FilterControl","filtering","filterList","TableHead","TableRow","indexColumn","TableCell","headerTextAlign","cellHeaderStyle","sortDirection","sorting","TableSortLabel","onMouseOut","show","hide","headerClassName","headerStyle","pagination","Pagination","onPageChange","showPaginationAlways","boundaryCount","siblingCount","tableContainer","tableBody","rowText","GridList","totalItems","onRowClick","classTableBody","classTableContainer","tooltipIsVisible","customClasses","setPage","setOrder","setOrderBy","setShowTooltip","tableContainerRef","prevColumnsLength","elementsRefs","onMouseLeaveItem","getUniqueIndexForCell","colIndex","TableContainer","Paper","Table","stickyHeader","isAsc","TableBody","handleRowClick","rowClassName","cellStyle","completeObject","rowStyle","divMain","notFound","linkRegister","searchResultLabel","deleteConfirmationModal","deleteModalContentContainer","deleteModalTitleText","deleteModalContentText","deleteModalContentBoldText","deleteBtn","ConfirmDeleteModal","componentInfo","classButton","textButtonConfirm","CustomerList","isRefresh","openCustomerModal","setCustomers","customerToDelete","setCustomerToDelete","setTotalCustomers","currentCustomerId","setCurrentCustomerId","customerFound","setCustomerFound","deleteConfirmationModalIsOpen","setDeleteConfirmationModalIsOpen","customerDeletedLabel","deleteCustomerQuestionLabel","deleteCustomerAlertLabel","deleteCustomerButtonLabel","deleteCustomerUpcomingAppointmentsQuestionPartlyLabel","deleteCustomerUpcomingAppointmentsAlertLabel","fillMobileData","customersWithMobileData","getCustomersByEstablishments","getCustomers","handleOnSelectCustomer","getById","getSearchByEstablishments","resetSearchResults","Male","Female","PreferNotToSay","handleDeleteCustomerClick","handleDeleteCustomerConfirmClick","deleteCustomer","customersWithoutDeletedCustomer","DeleteCustomerModalContent","DeleteCustomerWithAppointmentsModalContent","upcomingAppointmentsCount","createFilterOptions","CustomerClassificationType","importCustomer","newCustomer","CustomersClassification","CustomersClassifications","customerFrequencyClassificationFrequentId","customerFrequencyClassificationInfrequentId","customerFrequencyClassificationInactiveId","CustomersClassificationEntity","months","classificationType","GetCustomerClassificationLocale","numMonth","CustomerClassificationService","customerClassification","baseUrlCustomerClassification","customerClassifications","customerClassificationList","frecuencyId","customerFrequencyId","ClassificationTypeUpd","EstablishmentsToolbar","CustomerMainPage","openImportModal","setOpenImportModal","setIsRefresh","setCustomerClassification","loadCustomerClassification","getCustomerClassificationByEstablishments","getCustomerClassification","importCustomersTitle","createCustomerTitle","rootTab","breakpoints","up","tabSelected","Tabs","TabPanel","other","customerData","goBackButtonText","customerStatus","contentText","contentBoldText","customerAge","appointmentsContent","appointmentsContentDoubleSpace","serviceText","dateRegistered","dateRegisteredText","CustomerDataInfo","isDataLoad","getCustomerData","dob","month_diff","getUTCFullYear","getAge","customerHistoryPanel","customerHistoryPanelContent","customerDetails","customerDetailsContent","customerHistoryTitle","customerHistoryContent","contactRow","iconTitle","recurringAppointment","appointmentsBox","appointmentsGrid","appointmentsGridLine","headerAppointments","lineHight","serviceDate","serviceStatus","divStatus","statusConfirmed","statusArrived","statusNotConfirmed","statusNotArrived","statusCanceled","apptDisabledGrid","divNotes","divNotesNone","divNotesExists","drawerHistoryDetails","statusPaid","statusUnpaid","customerHistoryDetailsPanel","closeDrawer","closeDrawerIcon","closeDrawerText","divGroup","dateTimeInfo","statusLabel","divTiny","divTinyFocus","divTinyWarning","saveButtonContainer","floatButton","floatButtonTxt","CustomerHistoryDetails","serviceHistory","servicePaymentStatus","onChangedWithoutSave","onRefresh","isDisabledBtnSave","setIsDisabledBtnSave","showBtnSave","setShowBtnSave","editorTxt","setEditorTxt","editorTxtLength","setEditorTxtLength","warningSave","setWarningSave","handleSaveNotes","updateNotes","apiKey","initialValue","onFocusIn","onFocusOut","onInit","editor","initialContentLength","getContent","menubar","plugins","toolbar","lists_indent_on_tab","formats","inline","italic","extended_valid_elements","entity_encoding","invalid_elements","content_style","onEditorChange","editorLength","outputFormat","appointmentsEntity","setAppointmentsEntity","appointmentsTotal","setAppointmentsTotal","setServiceStatus","setServicePaymentStatus","notesSaved","setNotesSaved","customerDidNotArriveTerminology","customerArrivedTerminology","getData","getCustomerHistory","appointmentIds","prevAppointmentsEntity","monthData","updatedAppointments","apptId","divPaymentStatus","DivStatus","DivPaymentStatus","indexHistory","defaultExpanded","indexAppointments","DivNotes","recurringAppointmentCount","saved","customerInfoPanel","customerInfoPanelContent","customerInfoContent","captionValueTextArea","detailsActions","editButton","saveButton","cancelButton","lastRow","addContactButton","addTreatmentButton","uploadFileCloud","iconRemove","iconDiary","diaryCaption","notesCountInMonth","evolutionNoteForm","evolutionNoteBox","counterWrapper","charCounter","removeModalContentContainer","closeModalContentText","closeModalContentText2","closeModalContentHeaderText","editModeSeparator","longSeparator","closeConfirmationModal","cancelEvolutionNoteConfirmationModal","tinyMceOverrides","tinyMceUnfocused","tinyMceFocused","tinyMceValidationError","accordionHeader","buttonArea","editEvolutionHeader","editModeTitle","editModeSimpleText","editModeBoldText","editModeTreatmentList","editorFieldHeader","treatmentFieldHeader","treatmentRow","treatmentInputContainer","pdfButtonsBlock","pdfButton","fileHeader","treatmentNameInput","gray2","carryOutTitle","editModeNoteHeaderContainer","editModeNoteHeaderContainerChild","editModeNoteFieldSmall","editModeNoteFieldBlue","fieldEditionContainer","fieldNameLabel","fieldValueLabel","phoneNumberCodeLabel","phoneNumberContainer","fieldContainer","fieldNameAsterisk","editorContent","fileNameContainer","actionsContainer","gridShowMode","DiaryIcon","GetMonthStringEnum","0","1","2","3","4","5","6","7","8","9","10","11","resize","PatientImportEvolutionNoteClinicalFileModal","setFileComment","fileExtension","setFileExtension","handleOnUploadClick","fileType","utc","tz","allowedExtension","CancelNewEvolutionNoteModalContent","wordWrap","GridListWithoutPagination","inputWidth","useControlLabel","useInputFirstTouch","hasBeenTouched","setHasBeenTouched","handleFirstTouch","PatientFormTextInput","inputStyle","ControlLabel","countryIcon","PatientFormMobileInput","defaultCountry","setMobile","handleCountrySelected","SectionFieldItemModel","isDeleted","SectionFieldValueModel","radios","freeTextAreaContainer","radio","PatientFormRadio","onCheck","PatientFormFreeTextInput","PatientFormRadioGroup","selectedItem","setSectionFieldItem","setFreeTextValue","setItems","itemsWithOldValue","i1","i2","isAdditionalTextareaEnabled","TerminologyType","TerminologyForm","SectionFieldModel","isRemovable","FieldAndValue","EvolutionNoteFieldAndValue","useTerminology","templateTermToLowercase","selectedAccountId","getTerminology","terminologyList","Commission","FiscalId","Treatment","Certification","getDefaultTerminology","Plural","term","formatTemplate","PatientEvolutionNotes","treatmentTerm","Singular","setEvolutionNotesGrouped","setVitalSignsFields","treatmentForRemove","setTreatmentForRemove","studyForRemove","setStudyForRemove","editNoteMode","setEditNoteMode","cancelEvolutionNoteModalIsOpen","setCancelEvolutionNoteModalIsOpen","evolutionNoteIsInvalid","setEvolutionNoteIsInvalid","removeTreatmentModalIsOpen","setRemoveTreatmentModalIsOpen","removeStudyModalIsOpen","setRemoveStudyModalIsOpen","focusedEvolutionNoteInput","setFocusedEvolutionNoteInput","focusedDiagnosisInput","setFocusedDiagnosisInput","focusedAdditionalInstructionsInput","setFocusedAdditionalInstructionsInput","evolutionNoteInputErrorHighlight","setEvolutionNoteInputErrorHighlight","editableEvolutionNoteBeforeChanges","setEditableEvolutionNoteBeforeChanges","editableEvolutionNote","setEditableEvolutionNote","deleteFileModalIsOpen","setDeleteFileModalIsOpen","deletableFile","setDeletableFile","diagnosisTextLength","setDiagnosisTextLength","additionalInstructionsTextLength","setAdditionalInstructionsTextLength","evolutionNoteTextLength","setEvolutionNoteTextLength","setVitalSignSectionName","importModalIsOpen","setImportModalIsOpen","isLoading","setIsLoading","getPatientEvolutionNotes","evolutionNoteGrouped","createEvolutionNote","newEvolutionNotesGrouped","updateEvolutionNote","handleEditNoteButton","handleOnConfirmCancelEvolutionNote","handleOnRemoveTreatmentConfirm","handleOnRemoveStudyConfirm","handleAddTreatmentClick","handleAddStudyClick","handleEditorEvolutionNoteTextChange","handleEditorDiagnosisChange","handleEditorAdditionalInstructionsChange","capitalizeFirstLetter","filesColumns","getExtenstionImage","getUploadDate","handleDownloadFile","handleOnClickDeleteFile","getPatientClinicalFileUrl","RemoveTreatmentModalContent","treatment","RemoveStudyModalContent","RemoveFileModalContent","onHandleChangeTreatment","changed","editableTreatment","sendTreatmentPdfByWhatsApp","getTreatmentPdf","validatePhoneNumber","numberOfDigits","validateEmailField","validateTextField","validateFieldsOnChange","Email","setFieldValue","fieldId","additionalTextValue","f","firstSelectItem","autoSelectedFirstItemValue","getTextInput","getEmailInput","getPhoneNumberInput","setEvolutionNotesTextLengthOnInit","evt","setDiagnosisTextLengthOnInit","setAdditionalInstructionsTextLengthOnInit","getRadioInput","isFakeRadioItem","getSelectedItem","setRadioValue","radioValue","itemModel","av","renderTreatment","dateTimeNow","yearIndex","monthIndex","e1","e2","indexEvolutionNote","noteDate1","MAX_VALUE","canceledEvolutionNote","editableEvolutionNoteEntity","handleCancelButtonEvolutionNoteModal","handleUpdateNoteButton","handleSaveNoteButton","statusbar","ev","cont","handleEvolutionNoteEditorOnBlur","t1","t2","study","onHandleChangeStudy","f1","f2","fieldAndValueModel","sectionField","valueField","phoneAsString","radioItemObj","getInputForEditMode","fileDate1","dangerouslySetInnerHTML","__html","handleSendPdfByWhatsAppClick","handlePrintPdfClick","fileDate","valueModel","phoneNumberValue","getFieldValueComponent","deletePatientClinicalFile","bodyItemsContainer","itemContainer","nameValueContainer","statusIconContainer","appointmentsFirstItemContainer","appointmentsFirstItemContainerRow","appointmentsFirstItemContainerItem","fieldValueLink","ageLabel","appointmentsValueLabel","fixedHeightLabelWrapper","exportToPdfButton","exportToPdfIcon","firstItemComponentHeight","headerTitleContainer","headerLabel","allItemsContainer","headerItemContainer","headerButton","itemTitleLabel","itemValueLabel","DataAccordion","firstItemComponent","bodyItems","isExpandedByDefault","setExpanded","IconButtonProps","PatientData","patientData","setPatientData","isPdfDownloading","setIsPdfDownloading","useImperativeHandle","updateVitalSigns","getPatientData","getPatientClinicalFilePdf","PatientFirstItem","PatientBody","newDateObj","getDateOfBirthString","ContactFirstItem","ContactBody","AppointmentsFirstItem","ServicesFirstItem","ServicesBody","EvolutionNoteFieldsAccordion","EvolutionNoteFirstItem","EvolutionNoteBody","toLocaleTimeString","timeStyle","getEvolutionNoteLastUpdatedString","fv1","fv2","phoneValue","infoContentFields","spaceBetween","deleteContactDiv","deleteContactButton","CustomerEmergencyContacts","contact","setContact","contactValid","setContactValid","CustomerEmergencyContactList","CreateEmergencyContacts","CustomerInformationTab","currentTabIndex","emergencyContact","setEmergencyContact","contactIndex","setContactIndex","contacts","setContacts","contactsCopy","setContactsCopy","contactDeleted","setContactDeleted","setIsEdition","customerCopy","setCustomerCopy","innerSetCustomer","loadedGeneral","setLoadedGeneral","loadedContacts","setLoadedContacts","setChanged","validContacts","updateData","customerSaved","showDuplicated","createEmergencyContacts","currentIsEdition","fillData","updateCustomer","responseCustomer","handleSave","deleteEmergencyContacts","handleEdit","duplicated","go","deleteBulkEmergencyContacts","createdDate","arrContacts","newContact","contactsDeleted","sectionsListContainer","sectionContainer","rowGap","fieldsEditionContainer","editDivider","sectionLabel","noNotes","editButtonContainer","editButtonLabel","cancelButtonLabel","saveButtonLabel","requiredFieldsNoteLabel","editModeButtonsGroupContainer","switchOverrides","muiSwitchTrackOverride","notesEditLabelContainer","tinyMceContainer","inputTextError","popoverOverride","toolbarBox","toolbarDateContainer","toolbarYearLabel","toolbarWeekDayDayMonthLabel","toolbarDateLabelContainer","PatientFormDateInput","PopoverProps","ToolbarComponent","setOpenView","getYear","getWeekDayDayMonth","Cloner","deepCopy","getOwnPropertyNames","o","defineProperty","getOwnPropertyDescriptor","getPrototypeOf","UpdatePatientFormDataRequest","htmledNotes","getHtmledNotes","PatientGeneralInformationTab","require","patient","setPatient","patientForEdit","setPatientForEdit","isFormValid","setIsFormValid","cancelEditModalIsOpen","setCancelEditModalIsOpen","focusedNotes","setFocusedNotes","notesTextLength","setNotesTextLength","maleGender","femaleGender","secretGender","year1900Date","getPatientGeneralInfo","patientResponse","handleEditButtonClick","patientForEditModel","handleCloseEdit","handleCancelEditButtonClick","handleSaveChangesButtonClick","updatePatientFormData","firstNameIsValid","lastNameIsValid","emailIsValid","mobileIsValid","dobIsValid","validateDobField","valueOf","getGenderAsRadioValue","StaticBasicInformationSection","getGenderString","NotesSection","EditButton","EditModeButtonsGroup","CloseModalContent","s1","s2","section","paste_as_text","forced_root_block","contentHtml","noFilesCaption","noFilesIcon","NoFilesIcon","PatientImportClinicalFileModal","refreshFiles","uploadPatientClinicalFile","CustomerClinicalFiles","customerClinicalFiles","setCustomerClinicalFiles","setTotal","getPatientClinicalFiles","signatureBlock","signatureBlockTitle","signatureBlockCheckbox","asterisk","signatureSectionContainer","signatureSectionTitle","signatureContainer","emptySignatureBox","signaturePlaceholder","metaInfoContainer","metaInfoFieldContainer","metaInfoFieldTitle","metaInfoFieldValue","checkBoxText","ClinicalHistoryRadio","ClinicalHistoryFreeTextInput","multiline","rows","ClinicalHistoryRadioGroup","onTextAreaBlur","initialTextAreaValue","setInitialTextAreaValue","textAreaValue","ClinicalHistoryTextInput","UpdatePatientObservationsRequest","ClinicalHistoryFieldAndValue","UpdatePatientClinicalHistoryFieldValueRequest","controlSignatureButtonsBlock","deleteSignatureButton","saveSignatureButton","hoverBackground","hoverContent","hoverIcon","hoverText","PatientSignature","setSignature","enabled","isDrawingEnabled","setIsDrawingEnabled","showHoverImage","setShowHoverImage","canvas","loadSaveData","canvasDraw","canvasWidth","canvasHeight","brushRadius","brushColor","lazyRadius","getSaveData","saveData","immediateLoading","clampLinesToDocument","hideInterface","hideGrid","clear","SaveSignatureModal","PatientClinicalHistoryTab","tabDataModel","setTabDataModel","tabDataModelInitialState","setTabDataModelInitialState","saveSignatureModalOpen","setSaveSignatureModalOpen","getPatientClinicalHistoryTabData","responseClone","updateFieldValue","validateFieldValue","initialFieldsAndValues","updatePatientClinicalHistoryFieldValue","newDataClone","updatePatientSignature","updateObservations","updatePatientObservations","handleRadioTextAreaOnBlur","getInput","freeTextValue","checkBoxDisplayText","textKey","linkKey","linkTo","getSignatureDateTime","getSignaturePhoneNumber","CustomerDetailsTab","appointmentCountInMonth","specialistName","PatientAppointmentHistoryTab","gotoEvolutionNotesTab","toLocaleUpperCase","serviceDateTime","getServiceDate","serviceStartTime","serviceEndTime","newStartDateObj","newEndDateObj","timeStartString","timeEndString","getServiceTime","hasEvolutionNotes","CustomerDetails","currentTab","setCurrentTab","setTabs","customerDetailsListRef","ClinicalHistory","AppointmentHistory","Files","handleUpdateEvolutionNotes","tryGetTabIndex","tabType","tabIndex","tt","tabsModels","getTabModels","CustomerRouter","tabBar","mainTab","headerBack","SettingsNavTabs","routeMatch","useRouteMatch","commissions","newUser","noteHeader","tabTitle","UserList","settingsSelectedEstablishmentId","setTotalUsers","setLocalTotalUsers","userToDelete","setUserToDelete","userToDeleteUpcomingAppointmentsCount","setUserToDeleteUpcomingAppointmentsCount","getUsers","userList","handleDeleteUserClick","getUserUpcomingAppointmentsCount","handleDeleteUserConfirmClick","deleteUser","usersWithoutDeletedCustomer","DeleteUserModalContent","DeleteUserWithAppointmentsModalContent","dialogHeader","dialogContent","modalTitleUserId","continueButton","requiredFieldsNote","inputRow","switchBox","phoneLabel","photoContainer","photo","photoIconConatiner","photoIcon","photoHover","backdropFilter","cameraIcon","changePhotoLabel","photoLabel","photoSizeLabel","photoInitials","header1","JobPosition","JobPositionService","jobPositions","jobPositionName","jobPositionId","labelWithTooltip","SwitchWithLabelAndTooltip","inactiveLabel","inactiveTooltip","tryGetRequiredAsterix","labelPlacement","labelWithoutTooltip","getLabel","editIcon","JobPositionSelect","itemState","setItemState","edit","addButtonState","setAddButtonState","addInputValue","setAddInputValue","resetAddInputState","getItemName","isItemSelected","handleRemove","focus","handleOnCreate","mainContent","modalFooter","JobPositionEditModal","onEdit","handleSubmit","GoBackButton","SaveChangesButton","h4","deleteIcon","itemName","JobPositionDeleteModal","DeleteButton","exclamationIcon","modalText","modalTextBlock","UserModalHasUpcomingAppointment","onCancelClick","onSaveClick","bkgPic","DropImage","classDivUploadImage","componentShowEmpty","componentShowEmptyHover","imageURL","disableChange","disableBlob","funcToValid","imageRef","picturl","setPicturl","openFileExplorerDialog","showOpenFileDialog","fileDrop","dataTransfer","handleFileSelected","handleChangeFile","onDragOver","onDragEnter","onDragLeave","onDrop","UserModalGeneralInfo","jobPositionEditModalOpen","setJobPositionEditModalOpen","jobPositionEditItem","setJobPositionEditItem","jobPositionDeleteModalOpen","setJobPositionDeleteModalOpen","jobPositionDeleteItem","setJobPositionDeleteItem","hasUpcomingAppointmentModalIsOpen","setHasUpcomingAppointmentModalIsOpen","setJobPositions","userServices","userGeneralInfo","setUserGeneralInfo","setRefresh","setPhoneNumberIsValid","setEmailIsValid","phoneFormatIsValid","setPhoneFormatIsValid","debouncedPhoneValue","debouncedEmailValue","getJobPositionList","getJobPositions","getIsUserEmailDuplicated","isUserEmailDuplicatedResponse","getIsPhoneDuplicated","isUserPhoneDuplicatedResponse","setHasServicesInCharge","disabledServiceIds","getAllUserAppointmentCount","handleJobOnCreate","createJobPosition","newJob","handleJobOnEdit","updatedJob","updateJobPosition","editedJob","handleJobOnDelete","job","deleteJobPosition","saveImage","s3Img","getImage","imgURL","newInfo","EmptyUserPhoto","UserPhotoHover","innerValidationResult","selectedJob","DayOfWeek","SwitchWithLabel","switchContainer","datePickers","datePickerMargin","timePickersContainer","timePickerContainer","timePickerInput","timePickerPopup","timePickerInvalid","addWindowButtonContainer","addWindowButton","copyToAllButton","removeWindowButtonContainer","removeWindowButton","topRowMargin","UserScheduleItem","setDay","copyToAll","setWindows","handleAddWindow","lastWindowClosing","newWindowOpen","newWindowClosing","newWindow","newWindowsExceptCurrent","currentStartTime","isInvalidStartTime","popupClassName","newWindows","setTimeStart","currentClosingTime","IsInvalidEndTime","setTimeClosing","UserModalSchedules","newSchedule","servicesContainer","addCertificationsContainer","certificationsNotesContainer","addButtonItems","notesBoldText","notesText","certificationsContainer","certificationHiddenContainer","certificationContainer","certificationName","WebkitBoxOrient","WebkitLineClamp","modalDelete","UserServiceCertifications","certifications","setCertifications","handleS3ImageSave","certTerminology","openDeleteDialog","setOpenDeleteDialog","certToDelete","setCertToDelete","isFileLoading","setIsFileLoading","fileInputTypes","fileInputRef","handleCertificationUpload","dataImg","newOrder","cert","newImg","updatedCerts","confirmDelete","UserServiceCategory","serviceCategory","setServiceCategory","UserModalServices","userServiceInfo","setUserServiceInfo","newServiceCategories","sectionRow","UserModalPermissionsInfo","userPermissionsInfo","setUserPermissionsInfo","Divider","radioContent","commissionByServiceItem","commissionByServiceValues","contentHeader","defaultServices","defaultServiceItem","defaultCommissionValues","ConfirmationModal","cancelTextButton","RadioWithContent","contentClass","UserModalCommissions","userCommissionsInfo","setUserCommissionsInfo","selectedServiceIds","isConfirmationModalOpen","setConfirmationModalOpen","isUserCommissionTypeChangeConfirmed","setIsUserCommissionTypeChangeConfirmed","displayableCommissionsByServices","cs","needConfirmUserCommissionTypeChange","commissionTypeToDisplayable","displayableToCommissionType","getPercentageValueByAbsolute","newVal","getAbsoluteValueByPercentage","getServiceAbsoluteTemplate","getServicePercentageTemplate","displayableCommissionTypes","Default","handleUserCommissionTypeCheck","confirmUserCommissionTypeChange","userWithCommission","userWillBeAbleToReceiveCommissions","commissionByService","defaultCommission","userWithoutServicesInCharge","setServiceCommissionValue","setServiceCommissionType","setCommissionValue","displayableType","setCommissionType","UserCancelModal","CancelButton","TabType","labelAlternativeLabel","labelCompleted","useStepIconStyles","activeCircle","UserModalStepper","activeStep","userHasServicesInCharge","userCanPrescribeTreatment","StyledStepperConnector","withStyles","alternativeLabel","StepConnector","StepIcon","Stepper","connector","Step","StepLabel","StepIconComponent","ProfessionalInfo","Schedule","Permissions","UserContinueEditModal","SignatureImageType","columnGap","signSectionContainer","signInteractiveSection","modeButtonsBox","signModeButtonDisabled","letterSpacing","signModeButtonEnabled","rightSignModeButton","leftSignModeButton","signInteractiveArea","drawerBox","dropzoneBoxEmpty","dropzoneBoxImage","canvasSignSectionFooter","uploadSignSectionFooter","signSectionLabel","addPhotoLabel","recommendedSizeLabel","deleteCanvasSignButton","editUploadedSignButton","deleteUploadedSignButton","modalBody","ImageDropzone","imageUrl","emptyFileComponent","validationFunction","invalidImageTitleModal","invalidImageBodyModal","removeImage","DataTransfer","handleFileDrop","Modal","UserModalProfessionalInfo","userProfessionalInfo","setUserProfessionalInfo","setSignatureImage","canvasRef","imageDropzoneRef","validSignImageExtensions","validateSignImage","postprocessUserSignature","Drawing","dataUrl","canvasContainer","childNodes","toDataURL","fetch","res","newProfessionalInfo","handleChangeFieldValue","Upload","UserModal","setUser","oldUser","customUserSchedule","setActiveStep","cancelModalOpen","setCancelModalOpen","continueModalState","setContinueModalState","phoneNumberIsValid","previousJobPositionName","setPreviousJobPositionName","professionalInfoTabRefs","signatureImageFileRef","getContinueButtonTitle","getFinishStepNumber","setUserScheduleInfo","image","validateTab","validateName","validateScheduleDay","getActiveTabs","noServices","userHasNoServicesInCharge","noProfInfo","userCannotPrescribeTreatment","getCurrentTab","generalInfoIsEmpty","otherWindows","validateScheduleWindow","userHasNotBeenEdited","executeSubmitAndCloseModal","handleFormSubmit","newUserSchedule","oldUserSchedule","newUserServices","oldUserService","userAppointmentCount","getUserAppointmentCount","newTab","nextStep","handleEditModalClose","newPermissions","GeneralInfoContent","ProfessionalInfoContent","SchedulesContent","ServicesContent","CommissionsContent","sc","PermissionsContent","Dialog","square","DialogTitle","DialogContent","getContentForTab","SectionType","UserStatistic","SectionFieldCreateResponse","fieldItemIds","SectionFieldUpdateResponse","SectionModel","fields","SectionUpdateRequest","newName","previousOrder","SettingsPatientFormsService","sectionType","establishmentAccountIdRequestValue","sectionBaseUrl","sections","sectionFieldBaseUrl","copyModel","SectionNoteData","sectionNotes","sectionNotesTitle","sectionNotesDescription","SectionNote","sectionData","article","UsersMainPage","modalMode","setModalMode","setOldUser","setCustomUserSchedule","getUserById","userCopy","getAccountSettingsTabSections","UserTreatment","userProfessionalInfoFields","sm","getUserServices","getCommissionsByServices","userCommissionsByServices","getAccountCountryCode","accountCountryCode","getAccountWeekdaysAsUserSchedule","fetchAccountSchedule","handleUserEdit","pushState","handleUserInvited","createUser","updateUser","FirstRemindBefore","SecondRemindBefore","WhatsappFollowupSendTime","divArea","divRowWhats","divRowWhatsHeight60","divCheck","divLabel","divSelect","divNote","disabledSelect","tinyMceInvalid","resetTimeContainer","saveInitialMessageButtonContainer","saveCustomMessageButtonContainer","saveCustomMessageText","whatsAppRequestQuotesDelay","selectHrsClose","availabilityStatusSelectHrsClose","initialMessage","scheduleFollowUp","resetAvailableStatus","showCancellationPoliciesDisabledBlock","CustomerCommunication","notifyOnAppointmentCreated","notifyOnAppointmentModified","notifyOnAppointmentCanceled","firstReminderEnabled","secondReminderEnabled","firstRemindBefore","secondRemindBefore","customContactUsMessageEnabled","customContactUsMessage","showServicePricesInWhatsApp","showSpecialistNameInWhatsApp","scheduleWhatsAppFollowUpMessageEnabled","whatsAppFollowUpMessage","whatsAppFollowUpSendTime","whatsAppRequestQuotesEnabled","whatsAppRequestQuotesMessage","showCancellationPolicies","hasWhatsAppCancellationPoliciesOnAppointmentConfirmation","hasWhatsAppCancellationPoliciesOnAppointmentReminder","hasWhatsAppCancellationPoliciesOnAppointmentCancel","smbName","smbPhone","CustomerCommunicationService","customerCommunication","customerCommunications","CustomerCommunicationWa","availabilityStatusResetTime","availabilityStatusResetEnabled","whatsAppInitialMessage","GetSpecificConversationMessagesResponse","currentPageNumber","messages","WhatsAppService","pagesize","Page","PageSize","searchQuery","conversationPreviews","SearchQueryString","messagesOffset","pageNumber","targetMessageId","availabilityStatus","IsAvailabilityStatusUpdated","isMessagesUpdated","isSent","isScheduled","templateType","accountUrl","model","availableTemplates","defaultCustomerCommunication","OneDay","OneHour","customContantUsMessageEnabled","defaultCustomerCommunicationWa","curCommunications","setCurCommunications","newCommunications","setNewCommunications","curWaCommunications","setCurWaCommunications","newWaCommunications","setNewWaCommunications","initialMessageTextLength","setInitialMessageTextLength","isInitialMessageTextChanged","setInitialMessageTextChanged","initialMessageFocused","setInitialMessageFocused","textLength","setTextLength","isTextChanged","setTextChanged","setFocused","followUpTextLength","setFollowUpTextLength","isFollowUpTextChanged","setFollowUpTextChanged","followUpFocused","setFollowUpFocused","savedWhatsAppFollowUpMessage","setSavedWhatsAppFollowUpMessage","requestQuotesTextLength","setRequestQuotesTextLength","isRequestQuotesTextChanged","setRequestQuotesTextChanged","requestQuotesFocused","setRequestQuotesFocused","savedWhatsAppRequestQuotesMessage","setSavedWhatsAppRequestQuotesMessage","isWhatsAppRequestQuotesDelayOpen","setIsWhatsAppRequestQuotesDelayOpen","availabilityStatusResetTimeIsOpen","setAvailabilityStatusResetTimeIsOpen","loadComplete","setLoadComplete","enterpriseSelected","getCustomerCommunication","waData","getDefaultFollowUpMessage","getDefaultRequestQuotesMessage","updateSettings","updateWaSettings","updateCustomerCommunication","firstReminderSelectList","TwoDays","secondReminderSelectList","TwoHours","ThreeHours","handleSaveInitialMessageButtonPressed","handleSaveCustomContantUsSettingsButtonPressed","whatsAppFollowUpSendTimeSelectList","HalfHour","handleSaveWhatsAppFollowUpMessageButtonPressed","handleSaveWhatsAppRequestQuotesMessageButtonPressed","getDefaultInitialMessage","Communication","strikethrough","setup","changedCommunicationEntity","asMinutes","flexBasis","handleAvailabilityStatusResetTimeOnChange","btnNewWorkArea","classHead","classCell","WorkareasGrid","openItemEditModal","openDeleteModal","setTotalRecords","entityList","setEntityList","EntityService","getWorkareas","handleOnDeleteBtnClick","handleOnRowClick","rowDescription","Category","CategoryService","SettingsFieldUpdate","btnNewWorkareaCategory","WorkareasCategorySelect","categorySelected","setCategorySelected","categoryNew","setCategoryNew","getCategory","saveCategoryEdit","updateCategory","saveCategoryNew","createCategory","WorkareasForm","onModify","handleChange","WorkareaModal","setInitialState","isChangesMade","setIsChangesMade","createWorkarea","updateWorkarea","WorkAreaDelete","headerRight","setOpenItemEditModal","openItemDeleteModal","setOpenItemDeleteModal","itemModal","setItemModal","setNewItem","handleDeleted","deleteWorkarea","deletedEntity","msg","edited","AlertPopupType","getEnum","Name","Address","AddressReferences","CancellationPolicies","ShowPrices","allowCustomerToCancelFromSite","allowCustomerToModifyFromSite","IsPaymentCash","IsPaymentCard","IsPaymentBankTransfer","Currency","Logo","minuteLimitToModifyAppointmentFromSite","gapBetweenTimeIntervalsFromSite","AllowCustomerScheduleSimultaneousServices","ShowCancellationPolicies","ShowSuggestedServices","ShowEstablishmentCertifications","ShowSpecialistCertifications","EstablishmentInfo","fiscalId","mobileCountry","address","addressReferences","cancellationPolicies","showSuggestedServices","allowCustomerToScheduleTodayFromSite","allowCustomerScheduleSimultaneousServices","requireSelectSpecialistFromSite","showAnySpecialistFromSite","showEstablishmentCertifications","establishmentCertifications","showSpecialistCertifications","fieldUpd","ControlInput","MobileCountry","EstablishmentInfoService","establishment","establishmentInfo","WeekdaysChangeSettingsModal","setCounter","typeModify","setTypeModify","Timezone","AvailableHours","TimezoneService","timezoneId","timezones","titleSection","selectTimezone","headerDays","bodyBackground","iconMoney","switchRoot","switchThumb","switchTrack","switchChecked","rowWeekDays","dayLabel","multipleAppointments","titleWithTooltipContainer","popupOpen","setPopupOpen","scheduleSectionSettingsModel","setScheduleSectionSettingsModel","apptsAffected","setApptsAffected","popupType","setPopupType","weekdaysState","setWeekdaysState","timezoneItems","setTimezoneItems","timeZoneSelected","setTimeZoneSelected","useReducer","forceUpdate","daysFalse","selectOpening","setSelectOpening","selectClosing","setSelectClosing","weekDaysOrder","setWeekDaysOrder","timeGapsSelectItems","Five","Ten","Fifteen","Twenty","Sixty","Ninety","HundredTwenty","blockDurationsSelectItems","handleLaborDay","newDay","saveWeekday","toTimestamp","strDate","updateWeekday","getDays","getTimezones","getAccountMultipleAppointmentsSettings","getAccountScheduleSectionSettings","initializeWeekdays","daysTemplate","daysDb","handleTimezone","updateTimezone","timezoneDb","systemId","displayName","handleOpenTimepicker","openclose","dayOpen","dayClose","updateAccountScheduleSectionSettings","updatedSettings","updatedAccountSettings","handleChangeScheduleSimultaneousServices","handleOpening","handleClosing","EstablishmentPhoto","photoId","EstablishmentPhotoService","establishmentPhoto","establishmentPhotos","labelSecondary","photosEstablishmentRow","tableLayout","photosEstablishmentCol","photoEstablishment","photoEstablishmentEmpty","photosEstablishmentControls","iconCamera","photos","setPhotos","photoToDel","setPhotoToDel","photoToUp","setPhotoToUp","updateState","getEstablishmentPhotos","photosDb","picturls","pic","handlePhotoUpload","photoIndex","isFileNotValid","dataPhoto","newPhoto","updateEstablishmentPhoto","delPhoto","deleteEstablishmentPhoto","DivPhotoEmpty","DivInfoDelete","iconLabel","frequencyList","setFrequencyList","infrequencyList","setInfrequencyList","inactiveList","setInactiveList","frequents","setFrequents","infrequents","setInfrequents","inactives","setInactives","classification0appt","classification1appt","getCustomerClassificationList","classificationList","appt1","appt0","getCustomerClassifications","classifications","_frequent","_infrequent","_inactive","disableInfraquency","disableFraquency","handleFrequency","mappedObjectsArray","updateCustomersClassification","handleInfrequency","handleInactive","iconSuggestedServices","iconCalendarCancel","iconEdit","iconListMark","iconEye","iconInCheck","paymentMethodsTitle","paymentLabel","logoSection","divLogo","divLogoIcon","logoIconClear","divLogoIconHover","flexContainer","copyLinkButton","selectContainer","terminologyButton","certsTerminologyButton","optionalLabel","termContainer","termTitle","termEditNameInput","termButtonsContainer","termButton","EditTerminologyModal","isSingleFieldOnly","setTerminology","singularTerm","setSingularTerm","singularTermHover","setSingularTermHover","isSingularTermEditMode","setSingularTermEditMode","pluralTerm","setPluralTerm","pluralTermHover","setPluralTermHover","isPluralTermEditMode","setPluralTermEditMode","getAccountTerminology","canSave","updateAccountTerminology","newTerms","currentSettings","handleEditSingularTerm","getExitEditSingularTermButton","getEditSingularTermButton","handleEditPluralTerm","getExitEditPluralTermButton","getEditPluralTermButton","val","singularTermHandleOnChange","pluralTermHandleOnChange","charCounterInvalid","urlWarning","HtmlTextArea","setText","remove_linebreaks","selection","getBody","collapse","CertificationImageIcon","Certifications","showCertifications","handleShowCertificationsChange","handleCertificationDelete","certsTerminology","showCertificationsShadow","setShowCertificationsShadow","openFileDialog","setOpenFileDialog","handleFileInputFocus","selectedFiles","hasCertsOrFile","PaymentFieldUpdate","setEstablishmentInfo","establishmentInfoShadow","setEstablishmentInfoShadow","readOnlyControl","setReadOnlyControl","timeLimitToModifyAppointment","setTimeLimitToModifyAppointment","timeLimitPickerIsOpen","setTimeLimitPickerIsOpen","logoURL","setLogoURL","isFiscalIdTerminologyModalOpen","setIsFiscalIdTerminologyModalOpen","terminologyAllowCustomerToCancelAppointment","terminologyAllowCustomerToScheduleAppointmentToday","terminologyAllowCustomerToModifyAppointment","fiscalIdTerminology","isCertsTerminologyModalOpen","setIsCertsTerminologyModalOpen","ALPHA_NUMERIC_REGEX","clickTextbox","updateOnBlur","handleEmptyRequired","saveByEnter","which","blur","updateEstablishmentInfo","handleInputChange","handleLogoUpload","handleShowEstablishmentCertifications","showCerts","certs","newEstablishmentInfo","getEstablishmentInfo","fileId","DivLogoEmpty","DivLogoEmptyHover","addEstablishmentCertification","addedCertification","deleteEstablishmentCertification","navigator","clipboard","writeText","handleChangeScheduleTimeIntervalGapSetting","handleTimeLimitOnOk","getTimePickerTimeLimitPostfixClass","check","AllowCustomerToScheduleTodayFromSite","isoCode","PaymentSettingsModel","currencies","currencyId","isPaymentCash","isPaymentCard","isPaymentCardMasterCard","isPaymentCardVisa","isPaymentCardOther","otherPaymentCardName","isPaymentBankTransfer","bankTransfers","isPaymentOxxo","oxxoCardNumber","isEnabledMercadoPagoByAdmin","isPaymentMercadoPago","hasAcceptedMercadoPagoTerms","mercadoPagoEnabledByAdmin","hasExtraCostMercadoPago","extraPercentage","extraAmount","ivaPercentage","hasWhatsAppPaymentReminderOnAppointmentConfirmation","hasWhatsAppPaymentReminderOnAppointmentReminder","hasWhatsAppPaymentReminderAfterAppointment","daysAfterAppointmentToSendWhatsAppPaymentReminder","initialCashInCashRegister","isSendReceiptByWhatsApp","SettingsPaymentService","paymentsSettings","settings","bank","bankTransfer","bankTransferId","deleted","BankTransferType","BankTransferInfo","bankName","bankTransferType","cardNumber","accountNumber","interbankClabe","bankNameValid","cardNumberValid","interbankClabeValid","accountNumberValid","bankInfoType","contentArea","requiredFieldsHeader","contentColumns","contentColumn","innerContent","cashOpeningInput","creditCardTypes","smallVerticalDivider","otherCardTypeInput","cardNumberOxxoInput","checkGroup","subtitle","fonFamily","deleteDiv","exclamationModalBody","textNoChecked","checkboxMP","checkboxMPRed","opacityMid","opacityTextMid","extraCostTitle","calcExtra","lineExtraCost","boxExtraCost","boxExtraCostPlus","inputExtraCost","labelExtraCostMain","labelExtraCost","radioGroupItems","PaymentMain","setCurrencies","currentCurrency","setCurrentCurrency","setBankTransfer","daysAfter","setDaysAfter","transferType","setTransferType","openForbiddenSaveDialog","setOpenForbiddenSaveDialog","itemToDelete","setItemToDelete","isAddExtraCost","setIsAddExtraCost","setValueTemplate","isExclamationModalOpen","setExclamationModalOpen","getPaymentsSettings","getDaysAfter","getTransferType","newCurrency","listItems","info","setCurrenciesSelectItems","handleAddInterbank","handleChangeCurrency","updating","saveCurrency","savePaymentsSettings","forbbidenSave","handleSetPaymentsInCash","handleSetPaymentsCreditCard","handleMasterCard","IsPaymentCardMasterCard","handleVisa","IsPaymentCardVisa","handleOtherPaymentSystem","IsPaymentCardOther","handlePaymentSystemNameChange","handlePaymentSystemNameBlur","handleBankTransfer","itemIndex","transfer","handleBankTransferSave","CardNumberClabe","CardNumber","Clabe","AccountNumber","CardNumberAccountNumberClabe","saveBankTransfer","transfers","handleOxxoCheck","IsPaymentOxxo","handleOxxoChange","handleOxxoBlur","handleMercadoPagoCheck","IsPaymentMercadoPago","handleMercadoPagoTerms","handleExtraCostMercadoPago","handleAppointmentConfirmation","HasWhatsAppPaymentReminderOnAppointmentConfirmation","saveWhatsAppPaymentSettings","handleIsSendReceiptByWhatsApp","IsSendReceiptByWhatsApp","handleAppointmentReminder","HasWhatsAppPaymentReminderOnAppointmentReminder","handleAppointmentAfter","HasWhatsAppPaymentReminderAfterAppointment","handleDaysAppointmentAfter","handlCashCheck","IsCashRegisterActivated","saveCashRegister","handleCashBlur","currencyList","arrBankTransfer","newBankTransfer","handleOnDelete","deleteBankTransfer","rel","newModel","with","headerLeft","headerCenter","serviceImportButton","buttonNew","buttonDel","colText","divNotesTrash","divTrash","divBackTrash","ServiceGrid","handleCreate","serviceSearch","setServiceSearch","getServices","groupByName","minutesToDateTime","minDuration","minDateTime","cropArea","servicePhotoButtonContainer","cropModalButtonContainer","saveCropButton","cropSlider","crossIconContainer","servicePhotoTooltipBlock","cropSliderContainer","cropInternalContainer","modalCropPaper","modalCropContainer","servicePhotoHeaderIcon","servicePhotoHeaderButtons","cropContainerBlackBox","cropContainer","deleteImageModalContentText","deleteImageModalCenter","modalDeleteImage","inputTextareaDescription","ServiceForm","openDeleteImageModal","setOpenDeleteImageModal","recurrenceList","setRecurrenceList","workareaList","setWorkareaList","showCropperModal","setShowCropperModal","cropImage","setCropImage","crop","setCrop","cropZoom","setCropZoom","croppedAreaPixels","setCroppedAreaPixels","durationTime","setDurationTime","priceValidator","selectedFile","setSelectedFile","getCroppedImg","croppedImageBlob","croppedImageURL","imageSrc","resolve","method","onload","getContext","drawImage","toBlob","crossOrigin","src","objectURL","revokeObjectURL","DivInfoDeleteImage","getRecurrences","handleDurationTime","maxZoom","minZoom","cropAreaClassName","containerClassName","objectFit","zoom","showGrid","cropSize","onCropChange","onCropComplete","croppedArea","onZoomChange","Slider","ServiceModal","isNewItem","madeChange","setMadeChange","disableSave","setDisableSave","filename","createService","updateService","ServiceDeleteModal","uploadButton","ServiceImportModal","refreshServices","setTemplateFileName","servicesImportTitle","servicesAddedDescription","servicesNotImportedDescription","createServicesFromFile","ServiceMain","openServiceImportModal","setOpenServiceImportModal","deleteService","func","alertTitle","newButton","sectionsContainer","communicationSettingsContainer","mainTitle","checkboxTitle","communicationSettingsMainTitle","communicationSettingsCheckboxGroupTitle","communicationSettingsHeader","previewButton","clinicalHistorySwitch","requiredAsterisk","SectionNewModal","justOpened","setJustOpened","dataIsValid","setDataIsValid","setName","closeConfirmationModalIsOpen","setCloseConfirmationModalIsOpen","handleAddButtonClick","tryCloseModal","nameIsAlreadyUsed","localName","newSectionName","headerContainer","headerButtonsContainer","headerButtonDisabled","innerLayout","noItemsBox","noItemsLabel","footerContainer","sectionEditNameInput","SectionFieldCreateRequest","sectionId","itemsNames","SectionFieldUpdateRequest","sectionLayout","draggableClassName","innerFieldContentContainer","fieldItemsContainer","fieldTypeContainer","fieldItemBox","fieldInnerComponentDivider","fieldTypeNameLabel","fieldItemNameLabel","isRequiredAsterisk","mainBox","innerContainer","justifyEnd","actionButton","DraggableBase","innerContainerStyle","mainBoxClass","isEditableByButton","onEditClick","onDeleteClick","isShowActionOnMouseHover","innerContainerClass","getActions","innerContentCommon","provided","draggableProps","dragHandleProps","isDragDisabled","SectionFieldUpdateOrderRequest","FieldList","getReorderedFields","prevOrder","movedFieldId","isMovedDown","affectedFieldIds","dragUpdateHandler","destination","dragEndHandler","droppableId","reorderSectionFields","fieldContentDividerComponent","getFieldTypeNameComponent","typeName","getInnerFieldContent","Dropdown","Numeric","getFieldTypeComponent","optionalFreeTextComponent","getOptionalFreeTextComponent","iconComponent","tryGetFieldItemComponents","onDragUpdate","droppableProps","scrollbarWrapper","contentRowContainer","fieldTypeSelectItemContainer","fieldItemsLayout","innerItemContentContainer","itemNameLabel","addItemButton","itemEditNameInput","SectionFieldModal","defaultSectionField","defaultControlTypeFieldItems","nameIsValid","setNameIsValid","formIsValid","setFormIsValid","sectionSelectItems","setSectionSelectItems","selectedSectionId","setSelectedSectionId","localField","setLocalField","editingItem","setEditingItem","deletingItem","setDeletingItem","validationCaller","forceValidation","itemInputRef","fieldIdStub","existingFieldCopy","newSectionField","getReorderedFieldItems","movedItemId","affectedItemsIds","tryClose","handleItemEditClicked","itemCopy","handleItemInputClickAway","handleItemEditBlur","updatedItems","itemToUpdate","getInnerItemContent","handleItemNameChange","handleItemFocus","keyCode","handleItemKeyDown","fieldType","getItemIcon","mapItemsToComponents","handleDeleteItemButtonClicked","DeleteModalContent","handleNameChange","newItems","lastItemOrder","itemOrder","handleDeleteItem","SectionFieldDeleteRequest","Section","customNote","customHeaderButton","setSection","onMoveDown","onMoveUp","sectionInputRef","deleteSectionConfirmationModalIsOpen","setDeleteSectionConfirmationModalIsOpen","sectionFieldModalIsOpen","setSectionFieldModalIsOpen","headerHover","setHeaderHover","deleteFieldConfirmationModalIsOpen","setDeleteFieldConfirmationModalIsOpen","fieldMode","setFieldMode","isSectionEditMode","setSectionEditMode","modalField","setModalField","deleteModalField","setDeleteModalField","handleDeleteSection","handleNewFieldButtonClick","handleEditFieldClick","selectedField","handleDeleteFieldClick","fieldToDelete","handleEditSection","handleSectionFieldSave","newField","sectionIdToSave","sectionToSave","createSectionField","afterResponseField","updateSectionField","fieldIndexToUpdate","handleSectionFieldDelete","fieldIndexToDelete","deleteSectionField","updatedSectionFields","handleExitEdit","getEditButton","DeleteSectionModalContent","VitalSigns","getTabName","DeleteFieldModalContent","getSaveButton","getExitEditButton","getDeleteSectionButton","isDisabled","getMoveDownButton","getMoveUpButton","getHeaderButtons","getSectionContent","getSectionFooterComponent","ClinicalHistoryCommunicationSettingType","SectionDeleteRequest","SectionCreateRequest","SectionList","setSections","createSection","resultId","newSections","updateSection","sectionOrder","deleteSection","updatedSections","handleMove","isUp","targetSection","targetSectionIndex","pairedSectionIndex","sectionsData","updatedSection","ClinicalHistoryCommunicationSettings","isClinicalHistoryEnabled","sendFormOnConfirmationNoHistory","sendFormOnReminderNoHistory","sendFormOnConfirmationIncompleteHistory","sendFormOnReminderIncompleteHistory","isPrivacyNoticeEnabled","privacyNotice","isConsentLetterEnabled","consentLetter","ClinicalHistoryCommunicationSettingsService","communicationSettingsModel","clinicalHistoryCommunicationSettings","currentTabSectionType","newSectionModalIsOpen","setNewSectionModalIsOpen","focusedPrivacyNotice","setFocusedPrivacyNotice","focusedConsentLetter","setFocusedConsentLetter","textLengthPrivacyNotice","setTextLengthPrivacyNotice","textLengthConsentLetter","setTextLengthConsentLetter","originalPrivacyNoticeValue","setOriginalPrivacyNoticeValue","originalConsentLetterValue","setOriginalConsentLetterValue","sectionListRef","loadClinicalHistoryCommunicationSettings","handleCreateSection","setPrivacyNoticeTextLength","setConsentLetterTextLength","updatePrivacyNotice","saveClinicalHistoryCommunicationSettings","updateConsentLetter","handleEditorPrivacyNoticeChange","handleEditorConsentLetterChange","updateClinicalHistoryCommunicationSettings","getClinicalHistoryCommunicationSetting","regex","handleToggleClinicalHistory","handleSetClinicalHistoryCommunicationSettings","ClinicalHistoryEnable","settingType","SendConfirmationToPatientWithoutHistory","SendReminderToPatientWithoutHistory","SendConfirmationToPatient","SendReminderToPatient","ConsentLetterEnable","PrivacyNoticeEnable","StaticTreatmentDocumentFieldType","treatmentNoteBox","treatmentNoteLabel","modalNameLabel","requiredFieldLabel","asterix","modalManagementButtonsContainer","saveDisabled","mainContentContainer","settingsContainer","scrollableSettingContainer","printDetailsLabelContainer","violetHeaderLabel","previewContainer","documentSizeSelect","logoDisableableSection","logoConfigurationSection","logoConfigurationLeftSection","logoConfigurationRightSection","logoNotesContainer","notesBold","logoEmpty","emptyLogoStubContainer","addPhotoMinSizeLabel","logoControls","logoControlsEmptyStub","columnNameLabel","logoNumericInputContainer","fieldSettingsContainer","fieldSettingsRow","fieldSettingsGridItem","previewSectionLabel","commonPage","halfLetterPage","letterPage","legalPage","dividerCommon","dividerHalfLetter","dividerLetter","dividerLegal","dividerHeader","specialistNameLabel","dynamicFieldValueLabel","staticFieldNameLabel","staticFieldValueLabel","flexColumn","flexRow","dividerSignature","pageHeader","headerSpecialistRow","logoSpecialistBlock","specialistInfoBlock","patientInfoBlock","flexDualColumn","dualLeftColumn","dualRightColumn","pageContent","pageHeaderWithContent","pageFooter","TreatmentDocumentPreview","displayedDate","getFormattedPhoneNumber","maskedPnoneNumberBody","getStyle","fs","staticTreatmentDocumentFieldType","isEnabled","getBoolStyle","Header","SpecialistFullName","fs1","fs2","AppointmentDate","PatientFullName","PatientAge","PatientGender","Footer","SpecialistSign","SignatureExampleImage","SpecialistPhoneNumber","Legal","getPageClass","getDividerClass","Diagnosis","TreatmentDocumentConfigurationModal","closeModal","vitalSignsSectionName","documentSizeSelectItems","dropImageRef","setSettings","settingsInitialStateToCompare","setSettingsInitialStateToCompare","closeModalConfirmationModalIsOpen","setCloseModalConfirmationModalIsOpen","getTreatmentDocumentFieldSettings","updateTreatmentDocumentFieldSettings","closeAndResetModal","getStaticFieldIsEnabled","setStaticFieldIsEnabled","newSettings","fieldSetting","getDynamicFieldIsEnabled","fieldSettingId","innerLoadData","validateLogoImage","setDynamicFieldIsEnabled","vitalSignsSection","setVitalSignsSection","userTreatmentSection","setUserTreatmentSection","openTreatmentPdfConfigurationModal","setOpenTreatmentPdfConfigurationModal","userTreatmentStaticFields","vitalSignsSections","userTreatmentSections","handleChangeTreatmentTerminology","newTerminology","handleVitalSignsSectionChange","footerNoteLabel","footerNoteLabelBold","footerNoteLabelLink","pacientBasicInfoSectionStaticModel","commissionsHeaderBlock","UsersCommissionsResponse","usersCommissions","totalUserCommissions","UserCommissionEntity","userCommission","CommissionService","usersServices","servicesCount","CommissionView","CommissionModal","setUserCommission","openedCommissionType","initialUserCommission","setInitialUserCommission","updateUserCommission","validateCommissions","editCommissionByDefaultFor","editCommissionByServiceFor","userCommissionJson","initUserCommission","CommissionList","setUsersCommissions","setTotalUserCommissions","isCommissionModalOpened","setIsCommissionModalOpened","currentUserCommission","setCurrentUserCommission","currentUserId","setCurrentUserId","currentUserName","setCurrentUserName","modalOpenedAs","setModalOpenedAs","getUsersCommissions","openCommissionModal","getUserCommissionsById","openEditByService","openEditByDefault","CommissionsMain","isTerminologyModalOpen","setIsTerminologyModalOpen","establishmentCommissions","setEstablishmentCommissions","fetchEstablishmentCommissions","SettingsRouter","Workareas","PredeterminedReportType","mainContainer","inputsBlock","dateLabel","controlWithLabel","dateInputText","reportTypeSelect","downloadReportButtonBlock","downloadReportButton","downloadReportButtonLabel","ColumnGroupNameId","ColumnNameId","Report","ReportColumnGroup","ReportColumn","isPrimary","PreviewCustomReport","resultNumbers","dataTable","ReportsService","ReportType","primaryPropertyId","reportName","reportId","reports","reportData","requestData","massiveSendingId","MassiveSendingId","TotalToPayRecurringAppt","AmountPaidRecurringAppt","AmountDueRecurringAppt","tooltippedColumns","Appointments","Specialist","GeneralInformation","orderGroup","RecurringAppointment","PaymentStatus","AppointmentTime","CustomerMobile","CustomerGender","CustomerContactableForAppointments","CustomerContactableForMassiveSendings","SpecialistID","SpecialistEmail","SpecialistJobTitle","CommissionPerService","CommissionAmount","PaymentID","UserWhoRegisteredThePayment","PaymentDate","PaymentTime","PaymentMethod","TotalToPay","AmountPaid","AmountDue","ServiceName","ServicePrice","ServiceCategory","ServiceDuration","ServiceRecurrence","ServiceWorkArea","Establishment","orderColumns","propertyGroups","col","downloadCustomReport","setPercentage","cancelToken","downloadEnterpriseCustomReport","ReportsNavTabs","PredeterminedReportsPage","todayDate","lastMonthDate","addMonths","nextDayOfLastMonthDate","addDays","setStartDate","setEndDate","commissionsReport","customerTerminology","customerReportNameTerminology","reportType","setReportType","reportTypes","Customers","CashClosing","sortedReportTypes","setIsDownloading","dateFormatPlaceholder","fileDateFormat","StartDateLabel","EndDateLabel","setMonth","getReportFileName","reportTypeName","getReportTypeName","dateFromFormatted","dateToFormatted","getPredeterminedReport","bottomRoot","columnNotFoundContainer","columnNotFoundCaptionBold","columnNotFoundCaption","selectEstablishmentContainer","scrollColumnsArea","columnsContainer","columnsHeader","columnsContent","emptyPreviewBoxCaption","emptyPreviewBoxTitle","checkboxLabel","columnCheckbox","groupHeader","subtitle1","selectedColumnsBox","cancelModalContainer","disabledButton","cancelModalContent","radioGroup","emptyPreviewBox","down","previewRoot","draggableInnerContainer","inputSearchContainer","informativeBoxContainer","inputSearchRoot","deleteModalContentReportName","columnWithTooltipLabel","columnLabel","columnCheckedLabel","dropDownWidth","deleteButtonClass","editNameInput","SelectKeyEditable","textButtonConfirmDelete","setDeletableItemName","hoveredItem","setHoveredItem","editableItem","setEditableItem","isEditMode","setIsEditMode","deleteItemConfirmationModalIsOpen","setDeleteItemConfirmationModalIsOpen","handleMouseLeave","handleOnSaveClick","EditButtons","handleTrashButtonOnClick","SaveButtons","onMouseUp","selectedId","handleMouseEnter","handleOnChangeInput","handleOnFocusInput","CustomReportPreviewRequest","OrderedReportProperty","inputInvalid","infoContent","SaveReportModal","checkNameIsInvalid","setReportName","cancelSaveModalOpen","setCancelSaveModalOpen","nameIsInvalid","setNameIsInvalid","handleClickGoBack","CancelSaveReportModalContent","EnterpriseCustomReportPreviewRequest","CustomReportsPage","saveReportModalIsOpen","setSaveReportModalIsOpen","cancelEditReportModalIsOpen","setCancelEditReportModalIsOpen","setReports","selectedReport","setSelectedReport","deletableReportName","setDeletableReportName","columnGroups","setColumnGroups","selectedColumns","setSelectedColumns","primaryColumn","setPrimaryColumn","previewGridData","setPreviewGridData","columnSearchQuery","setColumnSearchQuery","noSavedReports","allColumns","report","loadPreview","getCustomReportPreview","getEnterpriseCustomReportPreview","reportsData","transformedData","transformPreviewRowData","rowData","propertyId","getResultString","numberOfResults","createPreviewGridColumn","reportColumn","entry","shouldShowResults","obj","keyExists","loadReports","loadColumns","previewGridColumns","updatedColumns","getPreviewGridColumns","getCustomReportsList","getCustomReportsColumnList","columnsData","translatedColumnGroups","translateNames","grouped","renameCustomReport","updatedReport","updatedReports","deleteCustomReport","startDateFormatted","endDateFormatted","reportNameString","downloadFunction","updateCustomReport","createCustomReport","newReport","searchInputResultNotFound","primaryColumnsResultNotFound","columnsResultNotFound","isColumnStateChanged","initialStateColumns","currentStateColumns","initialPrimaryColumn","CancelEditModalContent","ColumnNotFoundContent","updatedSelectedColumns","getColumnLabel","selectedColumn","selectedReportKey","primaryColumnInfo","selectedColumnInfo","reorderedColumns","movedColumnId","getReorderedColumns","columnCurrentIndex","handlePrimaryColumnCheck","maxOrder","handleCheckColumn","stringName","ReportsRouter","messengerLayout","disableYScroll","scrollable","loader","hideScrollbars","buildScrollbars","noConversationsContainer","noConversation","noConversationImage","noConversationText1","noConversationText2","availableCaption","availabilityStatusContainer","availableCircle","toolbarContainer","ConversationPreview","lastMessageId","lastMessageText","lastMessageTime","lastMessageType","isDisabledActivity","isDisabledNotContactable","isCustomerBlocked","unreadMessagesCount","wasSendMore1DayAgo","canScheduleFollowUp","hasScheduledFollowUp","hasUnpaidAppointment","windowContainer","headerTitleWithEstablishmentName","overflowAnchor","messageWindow","inputLayout","inputItemsLayout","inputAreaContainer","messageInputArea","sendMessageButton","inputArea","disabledInputLayout","disabledInput","enabledSendButton","enabledSendButtonWithDropdown","enabledSendDropdownButton","alternativeNotificationSendButton","dayLabelBox","dayLabelText","templateTextAreaContainer","closeWindowButton","templateWindowArea","buttonContainer","templateTextContainer","infiniteScrollOverrides","avatarContainer","avatarWithInitials","avatarWithLogo","avatarInitials","avatarMicrophone","MessageAudioPlayer","isInbound","elementOrder","containerRef","currentTimeDisplayed","setCurrentTimeDisplayed","maxTimeDisplayed","setMaxTimeDisplayed","useWavesurfer","hideScrollbar","waveColor","progressColor","barWidth","barGap","barRadius","cursorWidth","wavesurfer","isReady","currentTime","isPlaying","onPlayPause","playPause","padLeft","pad","secondsToDisplayedTime","durationInSeconds","splitFullName","getInitials","alt","Message","openCarousel","setClickedMessageId","isCustomerRegistered","maxImageWidth","imageWidth","setImageWidth","isPlayIconDisplayed","setPlayIconDisplayed","outboundMessageContainer","inboundMessageContainer","outboundMessageLayout","inboundMessageLayout","inboundMessageText","outboundMessageText","messageTimeContainer","messageTimeText","pdfPreviewImage","documentMessageFooter","documentMessageFileNameText","documentContentBox","pdfPage","downloadFileIcon","fileCaptionText","fileMessageBox","previewMessageFooter","documentMessageContainer","circularLoaderContainer","blockLabel","blockLabelBox","blockLabelText","unblockLabelBox","unblockLabelText","videoPreviewImage","videoPreviewPlayIcon","mediaCaption","linkRegex","previewFileUrl","abortController","AbortController","onAbort","signal","checkImageUrl","previewFileHeadUrl","abort","messageTime","handleOnImageLoad","clientWidth","headUrl","ok","aborted","encaseLinksWithTags","matches","newStr","getMessageTextComponent","originalFileName","getTextComponentClassName","getFileCaptionComponent","downloadDocument","openCarouselModal","messageId","isBlock","loading","onLoad","getInnerContent","ScheduledSendIcon","ScheduledSendIconWithTooltip","gray6","indicatorContainer","indicatorBulletInactive","indicatorBulletActive","exitButton","crossIcon","carouselItem","zoomInCursor","zoomedImage","carouselRoot","mediaWrapper","carouselItemText","ImageCarousel","carouselIsOpen","closeCarousel","activeImageIndex","imagesCount","zoomedIn","setZoomedIn","activeChildIndex","setActiveChildIndex","changedFromArrowKeys","setChangedFromArrowKeys","carouselItems","changeChild","handleZoom","mapCarouselItem","controls","curIndex","prevIndex","autoPlay","indicators","swipe","cycleNavigation","navButtonsWrapperProps","indicatorContainerProps","getIndicatorContainerProps","indicatorIconButtonProps","activeIndicatorIconButtonProps","SnackbarNotificationKind","snackbarChatWindow","SnackbarNotification","classToUse","notificationKind","whatsappChatWindowLinkCopied","closeAction","Snackbar","autoHideDuration","SelectWhatsappTemplate","getTitleByKey","availableTemplate","templateText","WhatsAppTemplateType","toolbarWrapper","ChatToolbar","onCopyLinkClick","siteLink","setSiteLink","getAccountSubdomain","CopyToClipboardMemo","BlockCustomerIcon","isRegistered","continue","BlockCustomerModal","UnblockCustomerModal","ConversationWindowMemo","selectedConversation","markConversationAsRead","isSearch","foundMessageText","onBlockCustomer","outMessage","setOutMessage","setCarouselIsOpen","clickedMessageId","anchorSendDropdown","setAnchorSendDropdown","openSendDropdown","linkCopiedSnackbarShown","setLinkCopiedSnackbarShown","currentChatMessages","setCurrentChatMessages","setAvailableTemplates","setTemplateType","openBlockCustomerModal","setOpenBlockCustomerModal","domObserver","chatWindowRef","isLoadingRef","currentPageNumberRef","messagesOffsetRef","hasMoreRef","availableTemplateTypes","AfterGivingAQuote","AfterAppointmentNoShow","SiteForAppointmentsLink","AfterNotAnsweringCustomerQuestion","OnPendingPaymentWithMercadoPagoLink","handleScrollReachTop","chatWindow","maxScrollTop","hasScrollTrackAtVisualTop","loadMoreMessages","fetchFirstPageMessages","getSpecificConversationMessages","removeDomObserver","prevMessages","scrollToMessage","messageElement","getElementById","preventScroll","messageRect","MutationObserver","newRect","scrollPosition","observe","childList","subtree","getMessagesWithHighlightedOne","cleanedCustomerName","sendTemplate","handleSendDropdownClose","getAvailableTemplates","availableTemplatesData","addNewMessages","messagesWithHighlightedOne","customerPhoneNumber","scrollToBottom","chatWindowElement","setClickedMessageIdCallback","setOutboundMessageText","handleKeyDown","shiftKey","sendMessage","sendTextMessageAsEstablishment","sendTextMessage","formatCustomerNameWithPlusSign","handleBlockCustomerModalClick","daysByMessages","Map","timeNow","messageMoment","mapMessagesToComponents","aria-expanded","ArrowDropDownTriangleIcon","MenuListProps","sendMercadoPagoLink","MercadoPagoLinkIcon","endsWith","ConversationWindow","conversationBox","conversationSelected","conversationNotSelected","conversationEnabled","conversationDisabled","customerContactName","messagePreview","messageSentIcon","messageDeliveredIcon","messageReadIcon","ConversationsListItem","lastMessageFileName","formatText","noWrap","getFormattedTime","zeroMinWidth","getMessageMediaContentIcon","messageType","Badge","badge","badgeContent","getChatPreviewIndicator","AvailabilityStatus","Messenger","nextPageNumber","setNextPageNumber","hasMore","setHasMore","conversations","setConversations","currentChat","setCurrentChat","isSearchMode","setIsSearchMode","setSearchQuery","setSelectedConversation","searchWasRun","setSearchWasRun","Away","setAvailabilityStatus","debouncedSearchQuery","messengerRef","availabilityStatuses","Available","fetchSearchData","searchPreviews","curConv","getCurrentConversation","getConversationsPreviewByEstablishments","getConversationsPreview","conversationsPreviewList","conversationsPreviews","isDialogPresentInNewList","conversationsPreviewsList","handleSelectAvailabilityStatus","updateAvailabilityStatus","handleOnSelectAvailabilityRender","blockCustomer","conversationIndex","newConversations","updatedChat","AvailabilityStatusSelect","receiveMessages","messagesByCustomers","isDialogPresentInInboundMessageList","lastMessageInList","findLastMessage","sortConversationsByLastMessageTimeDesc","currentChatIndexInNewMessages","tryAddNewMessages","sortMessagesByTime","dialog","firstEl","secondEl","markConversationAsReadAsEstablishment","whatsAppHubConnection","onMarkConversationAsRead","onAvailabilityStatusUpdate","onChangeScheduledFollowUpState","pageStart","loadMore","useWindow","conversation","WhatsAppConversationRouter","MassiveSendingEntity","customerGender","prospectedServices","prospectedServicesAppointmentStartDate","prospectedServicesAppointmentEndDate","dateOfSending","timeOfSending","terminationDate","birthdaySendingType","contentType","imageFileName","sendImmediately","currentYear","currentMonth","nextDay","tomorrowDate","MassiveSendingServiceModel","MassiveSendingService","gridInfo","customerFilter","statusFilter","massiveSending","massiveSendingsNames","sendingId","MassiveSendingType","MassiveSendingBirthdayType","buttonRow","statusActive","statusDone","impactedCustomersContainer","GridInfoModel","IconCounter","MassiveSendingList","handleModalDetailOpen","filterCustomer","setFilterCustomer","filterStatus","setFilterStatus","sentToCustomersIconTooltipRecently","sentToCustomersIconTooltipThisYear","sentToCustomersIconTooltipThisMonth","customersRespondedTooltip","customersTypeAllCustomers","customersTypeFrequent","customersTypeInfrequent","customersTypeInactive","setGridInfo","getSendings","filterListCustomer","filterListStatus","getTerminologyForFrequencyType","dateParam","stringTimeOfSending","sendingType","birthdayType","Birthdays","padStart","DateStylizedStart","typeId","dateStartParam","dateEndParam","dateStart","dateEnd","SingleSending","DateStylizedEnd","massiveSendingType","sentToCustomersCount","responsesReceivedCount","appointmentsScheduledCount","sentToCustomersIconTooltip","GetImpactedCustomerComponent","handleOnEdit","handleDeleteButtonClick","modalTitleRequiredFields","controlRow","annualControlRow","disabledControlLabel","dividerCustomersServices","customerTypes","customerTypeSelectors","customerTypeSelector","servicesSelector","servicesInputIcon","tooltipBlockServices","iconTooltip","sendingTypes","sendingTypeEditText","sendingTypeName","singleSendingSettings","servicesDates","annualSendingSettings","birthdaySettings","controlRowSwitch","switchLabelActive","menuItemSelected","Chip","StyledInputBase","startAdornment","ChipSelect","RadioWithText","TerminationDate","nullText","innerMinDate","innerValue","setInnerValue","innerDate","setInnerDate","timePickerInputDisabled","TimeOfSending","setTime","SelectMonthDayDate","nextYear","getFirstDayOfMonthDate","minDayDate","setMinDayDate","getLastDayOfMonthDate","maxDayDate","setMaxDayDate","getCorrectYear","innerDateYear","validDate","newInnerDate","LabelWithDot","MassiveSendingGeneralSettings","setMassiveSending","sendingTypeNames","customerFrequencyTypes","customerGenders","birthdaySendingRules","existingMassiveSendingsNames","isServicesTooltipOpen","setIsServicesTooltipOpen","startDateChanged","setStartDateChanged","endDateChanged","setEndDateChanged","nameChanged","setNameChanged","sendingTypeTooltips","newServiceIds","setTerminationDate","setDateOfSingleOrAnnualSending","setTimeOfSending","MassiveSendingStepper","CancelModal","MassiveSendingContentType","imageBlock","imageBlockNotes","uploadedImage","emptyImage","plusIcon","addImageLabel","textBlock","goToSiteButton","goToSiteButtonInnerContainer","goToSiteIcon","MassiveSendingMessageSettings","validMimeTypes","massiveSendingTemplates","greetingMessage","scheduleAppointments","goToSite","textContainsUrl","setTextContainsUrl","setMassiveSendingText","setMassiveSendingContentType","EmptyImageComponent","ImageAndText","setMassiveSendingImage","paste_preprocess","plugin","args","newText","blocks","valuesBlock","valueLabel","valueText","previewBlock","messageBlock","objectPosition","timeBlock","MassiveSendingPreview","sendingCustomerGender","sendingCustomerFrequencyType","sendingBirthdaySendingRules","sendingRules","formattedTime","ValueBlock","WhatsappBackground","MassiveSendingModal","oldMassiveSending","setFirstStepCompleted","setSecondStepCompleted","duplicatedSending","duplicateMassiveSending","servicesValues","sendingIsEmpty","sendingHasNotBeenEdited","validateGeneralSettings","isNameValid","isServiceSelected","areDatesValid","validateMessageSettings","FirstStepContent","SecondStepContent","ThirdStepContent","isContinueButtonDisabled","buttonsContainer","buttonWithIcon","downloadReport","duplicate","DuplicateIcon","DownloadFileIcon","MassiveSendingDetail","onReportDownload","sendingRule","formatted","MassiveSengingsMain","setOldMassiveSending","modalOpen","setModalOpen","modalDetailOpen","setModalDetailOpen","setExistingMassiveSendingsNames","handleConfirmDelete","deleteSending","getServicesByAccount","getSendingsNamesByAccount","getSendingById","ms","displaySuccessfulCreationAlert","massiveSendingName","displaySuccessfulEditionAlert","createNewSending","createSendingWithImage","createSending","updateSending","updateSendingWithImage","detailedSending","getImpactedCustomersReport","WhatsAppRouter","notificationLink","notificationType","notificationSuccess","notificationError","notificationWarning","notificationBody","notificationIconContainer","notificationIcon","notificationContent","notificationTitle","notificationDescription","notificationClose","notificationCloseIcon","displayed","useAlert","useSnackbar","enqueueSnackbar","closeSnackbar","onExited","myKey","AlertProvider","maxSnack","TransitionComponent","Collapse","CountryService","AccountSettingsProvider","localeStorage","getAccountSettings","accountSettingsResponse","getCountries","countriesResponse","getEstablishmentSettings","establishmentSettingsResponse","requestAccountSettings","requestEstablishmentSettings","getAccountOverdue","isOverdue","newSectionButtonContainer","copyNotes","copyNotesTitle","copyNotesDescription","copyControls","copyButton","fieldTypeSelectItems","CopyEstablishmentSettingsModel","fromEstablishmentAccountId","toEstablishmentAccountIds","backdrop","fadeIn","currentEstablishmentId","setCurrentEstablishmentId","copyToEstablishments","setCopyToEstablishments","isCopyMode","setIsCopyMode","isCopying","setIsCopying","setEnterpriseSelected","handleCopyClick","copyClinicalHistorySetting","handleSaveCopyToEstablishments","copySection","SettingsEvolutionNotesCommunicationService","copyEvolutionNotesSetting","setBusinessNameUrl","copyPatientFormSetting","SettingsEstablishmentSelector","SettingsEstablishment","enterpriseWithEstablishments","handleSelectEstablishment","EstablishmentSettingsNavTabs","settingsSelectedAccountId","EnterpriseSettingsFieldUpdate","enterpriseInformationContainer","enterpriseLeftContainer","enterpriseRightContainer","copyLinkButtonContainer","EnterpriseInfo","EnterpriseInfoService","enterpriseInfo","enterpriseInfoDto","setEnterpriseInfo","getEnterpriseInfo","updateEnterpriseInfo","GeneralPage","EstablishmentSettingsRouter","render","InterweaveComponent","PrivacyNoticePage","privacyNoticeEnabled","setPrivacyNoticeEnabled","setPrivacyNotice","loadPrivacyNotice","getPrivacyNotice","InformedConsentLetterPage","consentLetterEnabled","setConsentLetterEnabled","setConsentLetter","getInformedConsentLetter","ThemeStyles","createTheme","main","light","clear4","clear6","header3","overrides","MuiAppBar","MuiToolbar","dense","MuiPopover","MuiButtonBase","MuiButton","contained","MuiIconButton","MuiInputBase","MuiOutlinedInput","inputMarginDense","adornedStart","MuiInputLabel","MuiTab","MuiTableCell","MuiPickersBasePicker","MuiPickersCalendarHeader","transitionContainer","generateVariables","vars","addition","addColors","useGlobalThemeCss","App","isAuthenticated","Todo","AuthenticationProvider","initialize","matchPath","isExact","redirectToLogin","getElementsByTagName","getAttribute","basename","ThemeProvider","fallback","serviceWorker","ready","registration","unregister"],"mappings":"2HACAA,EAAOC,QAAU,CAAC,OAAS,oBAAoB,MAAQ,mBAAmB,OAAS,oBAAoB,KAAO,oB,oBCA9GD,EAAOC,QAAU,CAAC,UAAY,uBAAuB,SAAW,sBAAsB,MAAQ,mBAAmB,KAAO,oB,2FCD3GC,EAMT,WAAYC,GAAU,yBALtBC,qBAKqB,OAJrBC,2BAIqB,OAHrBC,uBAGqB,OAFrBC,wBAEqB,EACA,kBAANJ,GACPK,KAAKJ,g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BmmO,UAGJt5N,EAAQgmB,KAAKlzB,EAAmBC,OAjBoCwmO,QACrE,IAoBI,KCdT,IAAMn/N,GAAUswC,SAAS8uL,qBAAqB,QAAQ,GAAGC,aAAa,QAChEr6K,GAAc1U,SAASsvK,eAAe,QAE5C5/J,IAASg8K,OACP,kBAAC,IAAD,CAAesD,SAAUt/N,IAAW,KAClC,kBAAC,KAAD,CAAUM,MAAOA,IACf,kBAACy+N,GAAD,MACA,kBAACQ,EAAA,EAAD,CAAepnN,MAAO0kN,IACpB,kBAAC,WAAD,CAAU2C,SAAS,IACjB,kBAAC,GAAD,KACE,kBAAC,GAAD,WAMVx6K,Ip8BgEI,kBAAmBstH,WACrBA,UAAUmtD,cAAcC,MAAMx/N,MAAK,SAAAy/N,GACjCA,EAAaC,kB","file":"static/js/main.435c214f.chunk.js","sourcesContent":["// extracted by mini-css-extract-plugin\nmodule.exports = {\"header\":\"css_header__36w-F\",\"inner\":\"css_inner__r2DOS\",\"corner\":\"css_corner__1zBkC\",\"cell\":\"css_cell__3-7bM\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"container\":\"css_container__1JGcs\",\"timezone\":\"css_timezone__1KgkQ\",\"inner\":\"css_inner__21yv3\",\"mark\":\"css_mark__mPNjm\"};","export class ImportExcelResponse {\n isFileProcessed: boolean | null;\n processedRecordsCount: number | null;\n totalRecordsCount: number | null;\n invalidRecordsFile: Uint8Array | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.isFileProcessed = x.isFileProcessed;\n this.processedRecordsCount = x.processedRecordsCount;\n this.totalRecordsCount = x.totalRecordsCount;\n this.invalidRecordsFile = x.invalidRecordsFile ? Buffer.from(x.invalidRecordsFile, 'base64') : null;\n } else {\n this.isFileProcessed = null;\n this.processedRecordsCount = null;\n this.totalRecordsCount = null;\n this.invalidRecordsFile = null;\n }\n }\n}\n","module.exports = __webpack_public_path__ + \"static/media/whatsapp-background.495bf587.jpg\";","// extracted by mini-css-extract-plugin\nmodule.exports = {\"contentGridContainer\":\"css_contentGridContainer__3dE1s\",\"columns\":\"css_columns__3K0Xz\",\"column\":\"css_column__2H4c_\",\"grid\":\"css_grid__3IG66\",\"gridChildren\":\"css_gridChildren__3Q4pN\",\"list\":\"css_list__1MHE_\",\"item\":\"css_item__3dklI\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"root\":\"css_root__2-IYC\",\"column\":\"css_column__1Iw21\",\"cell\":\"css_cell__2byVR\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"root\":\"css_root__3zVZv\",\"inner\":\"css_inner__v0Q87\"};","// extracted by mini-css-extract-plugin\nmodule.exports = {\"cursor\":\"css_cursor__1dVJD\",\"full\":\"css_full__3jsha\"};","module.exports = __webpack_public_path__ + \"static/media/treatment-preview-signature.efb8d41c.png\";","// In production, we register a service worker to serve assets from local cache.\n\n// This lets the app load faster on subsequent visits in production, and gives\n// it offline capabilities. However, it also means that developers (and users)\n// will only see deployed updates on the \"N+1\" visit to a page, since previously\n// cached resources are updated in the background.\n\n// To learn more about the benefits of this model, read https://goo.gl/KwvDNy.\n// This link also includes instructions on opting out of this behavior.\n\nconst isLocalhost = Boolean(\n window.location.hostname === 'localhost' ||\n // [::1] is the IPv6 localhost address.\n window.location.hostname === '[::1]' ||\n // 127.0.0.1/8 is considered localhost for IPv4.\n window.location.hostname.match(\n /^127(?:\\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/\n )\n);\n\nexport default function register () {\n if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {\n // The URL constructor is available in all browsers that support SW.\n const publicUrl = new URL(process.env.PUBLIC_URL, window.location);\n if (publicUrl.origin !== window.location.origin) {\n // Our service worker won't work if PUBLIC_URL is on a different origin\n // from what our page is served on. This might happen if a CDN is used to\n // serve assets; see https://github.com/facebookincubator/create-react-app/issues/2374\n return;\n }\n\n window.addEventListener('load', () => {\n const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;\n\n if (isLocalhost) {\n // This is running on localhost. Lets check if a service worker still exists or not.\n checkValidServiceWorker(swUrl);\n } else {\n // Is not local host. Just register service worker\n registerValidSW(swUrl);\n }\n });\n }\n}\n\nfunction registerValidSW (swUrl) {\n navigator.serviceWorker\n .register(swUrl)\n .then(registration => {\n registration.onupdatefound = () => {\n const installingWorker = registration.installing;\n installingWorker.onstatechange = () => {\n if (installingWorker.state === 'installed') {\n if (navigator.serviceWorker.controller) {\n // At this point, the old content will have been purged and\n // the fresh content will have been added to the cache.\n // It's the perfect time to display a \"New content is\n // available; please refresh.\" message in your web app.\n console.log('New content is available; refreshing.');\n refreshCacheAndReload();\n } else {\n // At this point, everything has been precached.\n // It's the perfect time to display a\n // \"Content is cached for offline use.\" message.\n console.log('Content is cached for offline use.');\n }\n }\n };\n };\n })\n .catch(error => {\n console.error('Error during service worker registration:', error);\n });\n}\n\nfunction checkValidServiceWorker (swUrl) {\n // Check if the service worker can be found. If it can't reload the page.\n fetch(swUrl)\n .then(response => {\n // Ensure service worker exists, and that we really are getting a JS file.\n if (\n response.status === 404 ||\n response.headers.get('content-type').indexOf('javascript') === -1\n ) {\n // No service worker found. Probably a different app. Reload the page.\n navigator.serviceWorker.ready.then(registration => {\n registration.unregister().then(() => {\n window.location.reload();\n });\n });\n } else {\n // Service worker found. Proceed as normal.\n registerValidSW(swUrl);\n }\n })\n .catch(() => {\n console.log(\n 'No internet connection found. App is running in offline mode.'\n );\n });\n}\n\nexport function unregister () {\n if ('serviceWorker' in navigator) {\n navigator.serviceWorker.ready.then(registration => {\n registration.unregister();\n });\n }\n}\n\nfunction refreshCacheAndReload() {\n if (caches) {\n // Service worker cache should be cleared with caches.delete()\n caches.keys().then((names) => {\n for (const name of names) {\n void caches.delete(name);\n }\n });\n }\n if ('serviceWorker' in navigator) {\n navigator.serviceWorker\n .getRegistrations()\n .then(function (registrations) {\n for (let registration of registrations) {\n void registration.unregister()\n }\n })\n }\n window.location.reload();\n}","export enum LocalStorageKey {\n AccessToken = \"access_token\",\n SchedulerSelectedUsers = \"scheduler_selected_users-\",\n SchedulerSelectedUsersEnterprise = \"scheduler_selected_users_enterprise-\",\n SchedulerViewName = \"scheduler_view-name-\",\n SchedulerViewNameEnterprise = \"scheduler_view-name_enterprise-\",\n Establishments = \"establishments-\",\n SchedulerSelectedStatuses = \"scheduler_selected_statuses-\",\n SchedulerSelectedStatusesEnterprise = \"scheduler_selected_statuses_enterprise-\",\n SettingsEstablishment = \"settings_selected_establishment-\",\n SchedulerGrouping = \"scheduler_grouping-\",\n SchedulerGroupingEnterprise = \"scheduler_grouping_enterprise-\",\n}","import { createSlice } from \"@reduxjs/toolkit\";\n\nconst initialState = {\n value: false\n};\n\nexport const authenticationSlice = createSlice({\n name: \"authenticated\",\n initialState: initialState,\n reducers: {\n authenticate: (state) => {\n state.value = true;\n },\n deauthenticate: (state) => {\n state.value = false;\n }\n }\n});\n\nexport const { authenticate, deauthenticate } = authenticationSlice.actions;\n\nexport default authenticationSlice.reducer;","import { createSlice } from '@reduxjs/toolkit';\n\nconst localeStorage = localStorage.getItem('locale') ?? process.env.REACT_APP_DEFAULT_LANGUAGE ?? 'es';\n\nconst initialApplicationInterfaceState = {\n title: \"Clear\",\n isAccountOverdue: false,\n locale: localeStorage,\n isWideLayout: false\n};\n\nconst applicationInterfaceSlice = createSlice({\n name: 'applicationInterface',\n initialState: initialApplicationInterfaceState,\n reducers: {\n updateTitle(currentState, action) {\n currentState.title = action.payload;\n },\n updateAccountOverdue(currentState, action) {\n currentState.isAccountOverdue = action.payload;\n },\n updateLocale(currentState, action) {\n currentState.locale = action.payload;\n },\n updateIsWideLayout(currentState, action) {\n currentState.isWideLayout = action.payload;\n }\n }\n});\n\nexport const applicationInterfaceActions = applicationInterfaceSlice.actions;\nexport default applicationInterfaceSlice.reducer;","import React from \"react\";\nimport { createSlice } from '@reduxjs/toolkit';\nimport ConversationCounter from \"../models/interfaces/conversation-counter-model\";\n\n\ninterface InitialNavbarState {\n externalContent: React.Component | null,\n conversationCounter: ConversationCounter | null,\n showLoader: boolean | null\n}\n\nconst initialNavbarState: InitialNavbarState = {\n externalContent: null,\n conversationCounter: null,\n showLoader: null\n};\n\nconst navbarSlice = createSlice({\n name: 'navbar',\n initialState: initialNavbarState,\n reducers: {\n setExternalContent(currentState, action) {\n currentState.externalContent = action.payload;\n },\n setConversationCounter(currentState, action) {\n currentState.conversationCounter = action.payload;\n },\n setShowLoader(currentState, action) {\n currentState.showLoader = action.payload;\n }\n }\n});\n\nexport const navbarActions = navbarSlice.actions;\nexport default navbarSlice.reducer;","import { createSlice } from '@reduxjs/toolkit';\n\nconst initialState = {\n showMenu: false,\n showModal: false,\n date: null,\n userId: \"\",\n blockedSheduleId: \"\"\n};\n\nconst blockedScheduleSlice = createSlice({\n name: 'blockedSchedule',\n initialState: initialState,\n reducers: {\n setShowMenu(currentState, action) {\n currentState.showMenu = action.payload;\n },\n setShowModal(currentState, action) {\n currentState.showModal = action.payload;\n },\n setDate(currentState, action) {\n currentState.date = action.payload;\n },\n setUserId(currentState, action) {\n currentState.userId = action.payload;\n },\n setBlockedSheduleId(currentState, action) {\n currentState.blockedSheduleId = action.payload;\n }\n }\n});\n\nexport const blockedScheduleActions = blockedScheduleSlice.actions;\nexport default blockedScheduleSlice.reducer;","import { createSlice } from '@reduxjs/toolkit';\nimport BlockSchedule from \"../models/blocked-schedule\";\n\nexport interface MultipleBlockedScheduleState {\n isModalOpen: boolean,\n blockerCount: number,\n blockers: BlockSchedule[]\n}\n\nconst initialState: MultipleBlockedScheduleState = {\n isModalOpen: false,\n blockerCount: 0,\n blockers: [],\n}\n\nconst multipleBlockedScheduleSlice = createSlice({\n name: \"multipleBlockedSchedule\",\n initialState: initialState,\n reducers: {\n setState(currentState, action) {\n return action.payload;\n },\n resetState() {\n return initialState;\n }\n }\n});\n\nexport const multipleBlockedScheduleActions = multipleBlockedScheduleSlice.actions;\nexport default multipleBlockedScheduleSlice.reducer;","import { createSlice } from \"@reduxjs/toolkit\";\nimport { AppointmentTooltip } from \"../models/appointment-tooltip\";\nimport { Weekday } from \"../models/weekday\";\nimport { SelectItem } from \"../components/common/Select\";\nimport { AppointmentStatus } from \"../models/enums/appointment-status\";\n\ninterface SchedulerState {\n currentDate: Date;\n currentViewName: string;\n daysOff: number[] | null;\n allUsers: SelectItem[];\n selectedUsers: string[] | null;\n selectedStatuses: AppointmentStatus[] | null;\n tooltipAppointments: AppointmentTooltip[];\n appointmentId?: string;\n appointmentBlocked?: boolean;\n startDayHours: number[];\n endDayHours: number[];\n startWeekHour: number;\n endWeekHour: number;\n weekDays: Weekday[];\n isDragging: boolean;\n isGrouping: boolean;\n appointmentDndModalState: {\n open: boolean,\n hasSimultaneousAppointments: boolean,\n appointmentId: string\n }\n}\n\nconst initialSchedulerState: SchedulerState = {\n currentDate: new Date(),\n currentViewName: \"Week\",\n daysOff: null,\n allUsers: [],\n selectedUsers: null,\n selectedStatuses: null,\n tooltipAppointments: [],\n appointmentBlocked: false,\n startDayHours: [],\n endDayHours: [],\n startWeekHour: 0,\n endWeekHour: 24,\n weekDays: [],\n isDragging: false,\n isGrouping: true,\n appointmentDndModalState: {\n open: false,\n hasSimultaneousAppointments: false,\n appointmentId: \"\"\n }\n};\n\nconst schedulerSlice = createSlice({\n name: \"scheduler\",\n initialState: initialSchedulerState,\n reducers: {\n setCurrentDate(currentState, action) {\n currentState.currentDate = action.payload;\n },\n setCurrentViewName(currentState, action) {\n currentState.currentViewName = action.payload;\n },\n setDaysOff(currentState, action) {\n currentState.daysOff = action.payload;\n },\n setAllUsers(currentState, action) {\n currentState.allUsers = action.payload;\n },\n setSelectedUsers(currentState, action) {\n currentState.selectedUsers = action.payload;\n },\n setSelectedStatuses(currentState, action) {\n currentState.selectedStatuses = action.payload;\n },\n setTooltipAppointment(currentState, action) {\n currentState.tooltipAppointments = action.payload;\n },\n setAppointmentId(currentState, action) {\n const current = currentState.tooltipAppointments.find(\n (a) => a.appointmentId === action.payload\n );\n if (current) {\n currentState.appointmentId = action.payload;\n }\n else{\n currentState.appointmentId = undefined;\n }\n },\n setAppointmentBlocked(currentState, action) {\n currentState.appointmentBlocked = action.payload;\n },\n setStartDayHours(currentState, action) {\n currentState.startDayHours = action.payload;\n },\n setEndDayHours(currentState, action) {\n currentState.endDayHours = action.payload;\n },\n setStartWeekHour(currentState, action) {\n currentState.startWeekHour = action.payload;\n },\n setEndWeekHour(currentState, action) {\n currentState.endWeekHour = action.payload;\n },\n setWeekDays(currentState, action) {\n currentState.weekDays = action.payload;\n },\n setIsDragging(currentState, action) {\n currentState.isDragging = action.payload;\n },\n setIsGrouping(currentState, action) {\n currentState.isGrouping = action.payload;\n },\n setAppointmentDndModalState(currentState, action) {\n currentState.appointmentDndModalState = action.payload;\n },\n },\n});\n\nexport const schedulerActions = schedulerSlice.actions;\nexport default schedulerSlice.reducer;\n","import { createSlice } from \"@reduxjs/toolkit\";\nimport { AlertProps } from \"./../components/common/notifications/AlertProvider\";\n\ninterface AlertState {\n alerts: AlertProps[];\n}\n\nconst defaultState: AlertState = {\n alerts: [],\n};\n\nconst newGuid = () => {\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(/[xy]/g, function (c) {\n var r = (Math.random() * 16) | 0,\n v = c === \"x\" ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n });\n};\n\nconst alertsSlice = createSlice({\n name: \"alerts\",\n initialState: defaultState,\n reducers: {\n enqueueAlert: (state, action) => {\n const key = action.payload.key ? action.payload.key : newGuid();\n state.alerts = [\n ...state.alerts,\n {\n ...action.payload,\n key: key,\n },\n ];\n },\n closeAlert: (state, action) => {\n state.alerts = state.alerts.map((alert) =>\n alert.key === action.payload\n ? { ...alert, dismissed: true }\n : { ...alert }\n );\n },\n removeAlert: (state, action) => {\n state.alerts = state.alerts.filter(\n (alert) => alert.key !== action.payload\n );\n },\n },\n});\n\nexport const alertsActions = alertsSlice.actions;\nexport default alertsSlice.reducer;\n","export const Url = {\n Default: \"/\",\n Authentication: {\n Login: \"/login\",\n Recovery: \"/recovery\",\n ResetPassword: \"/resetpassword/:email/*\",\n Logout: \"/logout\",\n Join: \"/join/:email/*\"\n },\n Appointments: {\n Main: \"/appointments\"\n },\n Customers: {\n Main: \"/customers\"\n },\n FollowUps: {\n Main: \"/followups\"\n },\n WhatsApp: {\n Main: \"/whatsapp\",\n MassiveSendings: \"/massive-sendings\"\n },\n Reports: {\n Main: \"/reports\",\n CustomReport: \"/custom-report\"\n },\n Settings: {\n Main: \"/settings\",\n CustomerCommunications: \"/customer-communications\",\n WorkAreas: \"/work-areas\",\n Services: \"/services\",\n Users: \"/users\",\n Payments: \"/payments\",\n ClinicHistory: \"/clinic-history\",\n EvolutionNotes: \"/evolution-notes\",\n PatientForm: \"/patient-form\",\n Commissions: \"/commissions\"\n },\n SignalRHubs: {\n CommonHub: \"/commonHub\",\n WhatsAppHub: \"/whatsAppHub\"\n },\n EstablishmentSettings: {\n General: \"/general\",\n ClinicHistory: \"/clinic-history\",\n EvolutionNotes: \"/evolution-notes\",\n PatientForm: \"/patient-form\",\n CustomerCommunications: \"/customer-communications\",\n WorkAreas: \"/work-areas\",\n Services: \"/services\",\n Users: \"/users\",\n Payments: \"/payments\",\n Commissions: \"/commissions\"\n },\n PrivacyNotice: \"/privacy-notice\",\n InformedConsentLetter: \"/informed-consent-letter\"\n};","import { createSlice } from \"@reduxjs/toolkit\";\nimport {\n HubConnectionBuilder,\n LogLevel,\n IHttpConnectionOptions,\n HttpTransportType,\n HubConnection,\n HubConnectionState\n} from '@microsoft/signalr';\nimport { LocalStorageKey } from \"../constants/local-storage-key\";\nimport { Url } from \"../constants/url\";\n\nconst startSignalRConnection = async (connection: HubConnection) => {\n try {\n await connection.start();\n } catch (err) {\n setTimeout(() => startSignalRConnection(connection), 5000);\n }\n};\n\nconst initializeConnection = () => {\n const accessToken = localStorage.getItem(LocalStorageKey.AccessToken) \n\n if (accessToken === null){\n return;\n }\n\n const connectionOptions: IHttpConnectionOptions = {\n accessTokenFactory: () => {\n return accessToken;\n },\n transport: HttpTransportType.WebSockets,\n skipNegotiation: true,\n }\n\n const connection = new HubConnectionBuilder()\n .withUrl(process.env.REACT_APP_SERVER_URL + \n Url.SignalRHubs.CommonHub, connectionOptions)\n .withAutomaticReconnect()\n .configureLogging(LogLevel.Information)\n .build();\n\n connection.serverTimeoutInMilliseconds = 60000;\n\n startSignalRConnection(connection);\n return connection;\n}\n\nconst initialState = {\n connection: undefined as undefined | HubConnection\n};\n\nexport const commonHubSlice = createSlice({\n name: \"commonHub\",\n initialState: initialState,\n reducers: {\n connect: (state) => {\n if(state.connection === undefined || state.connection.state == HubConnectionState.Disconnected){\n state.connection = initializeConnection();\n }\n },\n disconnect: (state) => {\n if(state.connection?.state == HubConnectionState.Connected){\n state.connection.stop();\n }\n }\n }\n});\n\nexport const { connect, disconnect } = commonHubSlice.actions;\n\nexport default commonHubSlice.reducer;","import { UserInfoModel } from \"./interfaces/user-info-model\"\n\nexport class UserInfo implements UserInfoModel {\n email: string | null;\n username: string | null;\n fullName: string | null;\n accountId: string | null;\n userId: string | null;\n isAdministrator: boolean;\n hasCustomerInfoVisible: boolean;\n hasMassiveSendings: boolean;\n canRegisterPayments: boolean;\n canOpenCloseCashRegister: boolean;\n canMakeCashRegisterMovements: boolean;\n hasAccessToReports: boolean;\n canSeeClinicalFile: boolean;\n canInteractWithEvolutionNotes: boolean;\n canInteractWithPatientFiles: boolean;\n hasAccessToWhatsAppConversationsAndNotifications: boolean;\n hasAccessToScheduleAllSpecialists: boolean;\n canPrescribeTreatment: boolean;\n showPrices: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.email = x.email;\n this.username = x.username;\n this.fullName = x.fullname;\n this.accountId = x.accountid;\n this.userId = x.userid;\n this.isAdministrator = x.isadministrator === 'True';\n this.hasCustomerInfoVisible = x.hascustomerinfovisible === 'True';\n this.hasMassiveSendings = x.hasmassivesendings === 'True';\n this.canRegisterPayments = x.canregisterpayments === 'True';\n this.hasAccessToReports = x.hasaccesstoreports === 'True';\n this.hasAccessToScheduleAllSpecialists = x.hasaccesstoscheduleallspecialists === 'True';\n this.canOpenCloseCashRegister = x.canopenclosecashregister === 'True';\n this.canMakeCashRegisterMovements = x.canmakecashregistermovements === 'True';\n this.canSeeClinicalFile = x.canseeclinicalfile === 'True';\n this.canInteractWithEvolutionNotes = x.caninteractwithevolutionnotes === 'True';\n this.canInteractWithPatientFiles = x.caninteractwithpatientfiles === 'True';\n this.hasAccessToWhatsAppConversationsAndNotifications = x.hasaccesstowhatsappconversationsandnotifications === 'True';\n this.canPrescribeTreatment = x.canprescribetreatment === 'True';\n this.showPrices = x.showprices === 'True';\n } else {\n this.email = null;\n this.username = null;\n this.fullName = \"Unknown user\";\n this.accountId = null;\n this.userId = null;\n this.isAdministrator = false;\n this.hasCustomerInfoVisible = false;\n this.hasMassiveSendings = false;\n this.canRegisterPayments = false;\n this.canOpenCloseCashRegister = false;\n this.canMakeCashRegisterMovements = false;\n this.canSeeClinicalFile = false;\n this.canInteractWithEvolutionNotes = false;\n this.canInteractWithPatientFiles = false;\n this.hasAccessToWhatsAppConversationsAndNotifications = false;\n this.hasAccessToReports = false;\n this.hasAccessToScheduleAllSpecialists = false;\n this.canPrescribeTreatment = false;\n this.showPrices = false;\n }\n }\n}","import { createSlice } from \"@reduxjs/toolkit\";\nimport { UserInfoModel } from \"../models/interfaces/user-info-model\";\n\n\nconst initialState: UserInfoModel = {\n email: null,\n username: null,\n fullName: null,\n accountId: null,\n userId: null,\n isAdministrator: false,\n hasCustomerInfoVisible: false,\n hasMassiveSendings: false,\n canRegisterPayments: false,\n canOpenCloseCashRegister: false,\n canMakeCashRegisterMovements: false,\n hasAccessToReports: false,\n canSeeClinicalFile: false,\n canInteractWithEvolutionNotes: false,\n canInteractWithPatientFiles: false,\n hasAccessToWhatsAppConversationsAndNotifications: false,\n hasAccessToScheduleAllSpecialists: true,\n canPrescribeTreatment: false,\n showPrices: false\n}\nconst initializeLocalStateDefaults = function (localState: UserInfoModel | null) {\n if (localState){\n for (const prop in initialState) {\n if (Object.prototype.hasOwnProperty.call(initialState, prop)) {\n // @ts-ignore\n if (localState[prop] === undefined) {\n // @ts-ignore\n localState[prop] = initialState[prop];\n }\n }\n }\n }\n}\n\nconst localStateJson = localStorage.getItem('userInfo');\nconst localState: UserInfoModel | null = localStateJson ? JSON.parse(localStateJson) : null;\ninitializeLocalStateDefaults(localState);\n\nexport const userInfoSlice = createSlice({\n name: \"userInfo\",\n initialState: localState ?? initialState,\n reducers: {\n setUserInfo: (currentState, action) => {\n localStorage.setItem('userInfo', JSON.stringify(action.payload));\n return action.payload;\n },\n resetUserInfo: () => {\n localStorage.removeItem('userInfo');\n return initialState;\n }\n }\n})\n\nexport const { setUserInfo, resetUserInfo } = userInfoSlice.actions;\nexport default userInfoSlice.reducer;","import axios, { AxiosRequestConfig, AxiosResponse } from \"axios\";\nimport jwtDecode from \"jwt-decode\";\nimport store from \"../redux/store\";\n\nimport { Url } from \"../constants/url\"\nimport { LocalStorageKey } from \"../constants/local-storage-key\";\nimport { UserInfo } from \"../models/user-info\";\nimport { setUserInfo } from \"../redux/user-info-slice\";\n\nexport class ApiClient {\n static baseUrl = process.env.REACT_APP_SERVER_URL;\n static authorizationHeader = \"Authorization\";\n private static refreshTokenPromise: null | Promise;\n\n static async initialize() {\n axios.interceptors.response.use((response) => {\n return response;\n }, ApiClient.handleRejectedRequest.bind(ApiClient));\n\n const accessToken = localStorage.getItem(LocalStorageKey.AccessToken);\n if (accessToken) {\n axios.defaults.headers.common[this.authorizationHeader] = `Bearer ${accessToken}`;\n return true;\n } else {\n axios.defaults.headers.common[this.authorizationHeader] = null;\n return false;\n }\n }\n\n static async handleRejectedRequest(error: any) {\n //Manual cancellation [19.12.23, CR-2225, Alex.B]\n if (axios.isCancel(error)) return Promise.reject('Cancelled');\n\n //\"423\" means that permissions were changed and we need to update access token\n if (error.response.status === 423) {\n await axios.post(`${this.baseUrl}/Refresh`, {}, { withCredentials: true })\n .then((resp) => {\n ApiClient.configureAuthorization(resp.data.accessToken);\n store.dispatch(setUserInfo(ApiClient.getUserInfo()));\n return resp;\n }).catch((resp) => {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n return Promise.reject(resp);\n });\n window.location.reload();\n return;\n }\n else if (error.response.status === 401) {\n const originalRequest = error.config;\n\n if (!ApiClient.refreshTokenPromise) { // check for an existing in-progress request\n // if nothing is in-progress, start a new refresh token request\n ApiClient.refreshTokenPromise =\n axios.post(`${this.baseUrl}/Refresh`, {}, { withCredentials: true })\n .then((resp) => {\n ApiClient.refreshTokenPromise = null;\n ApiClient.configureAuthorization(resp.data.accessToken);\n return resp;\n }).catch((resp) => {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n return Promise.reject(resp);\n });\n }\n\n return ApiClient.refreshTokenPromise\n .then(resp => {\n originalRequest.headers[this.authorizationHeader] = `Bearer ${resp.data.accessToken}`;\n return axios(originalRequest);\n });\n }\n else if (error.response.status === 403) { // forbidden\n window.location.href = \"/\";\n }\n else {\n return Promise.reject(error);\n }\n }\n\n static async post(url: string, formData?: any, config?: AxiosRequestConfig) {\n return axios.post(this.baseUrl + url, formData, config)\n .then((resp) => {\n if (!resp.data) {\n return Promise.reject(resp);\n }\n return resp.data;\n })\n .catch((resp) => {\n if (resp.response !== undefined && resp.response.status === 401) {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n }\n return Promise.reject(resp);\n });\n }\n\n static async put(url: string, formData?: any, config?: AxiosRequestConfig) {\n return axios.put(this.baseUrl + url, formData, config)\n .then((resp) => {\n if (!resp.data) {\n return Promise.reject(resp);\n }\n return resp.data;\n })\n .catch((resp) => {\n if (resp.response !== undefined && resp.response.status === 401) {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n }\n return Promise.reject(resp);\n });\n }\n\n static async remove(url: string, content?: any) {\n return axios.delete(this.baseUrl + url, {\n data: content\n })\n .then((resp) => {\n return resp.data;\n })\n .catch((resp) => {\n if (resp.response !== undefined && resp.response.status === 401) {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n }\n return Promise.reject(resp);\n });\n }\n\n static async get(url: string, config?: AxiosRequestConfig) {\n return axios.get(this.baseUrl + url, config)\n .then((resp) => {\n return resp.data;\n })\n .catch((resp) => {\n if (resp.response !== undefined && resp.response.status === 401) {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n }\n return Promise.reject(resp);\n });\n }\n\n static async all(values: (AxiosResponse | Promise> | Promise)[]): Promise {\n return axios.all(values)\n .then((resp) => {\n return resp;\n })\n .catch((resp) => {\n if (resp.response !== undefined && resp.response.status === 401) {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Logout;\n }\n return Promise.reject(resp);\n });\n }\n\n static configureAuthorization(accessToken: string) {\n axios.defaults.headers.common[this.authorizationHeader] = `Bearer ${accessToken}`;\n\n localStorage.setItem(LocalStorageKey.AccessToken, accessToken);\n }\n\n static removeAuthorization() {\n axios.defaults.headers.common[this.authorizationHeader] = null;\n\n localStorage.removeItem(LocalStorageKey.AccessToken);\n }\n\n static getUserInfo() {\n const token = localStorage.getItem(LocalStorageKey.AccessToken);\n if (token) {\n const decodedToken = jwtDecode(token);\n return new UserInfo(decodedToken);\n }\n return new UserInfo();\n }\n\n static toServerDate(date: Date, includeTime: boolean = false) {\n const serverDate = new Date(Date.UTC(date.getFullYear(), date.getMonth(), date.getDate()));\n if (includeTime) {\n serverDate.setUTCHours(date.getHours(), date.getMinutes(), 0); // TODO check UTC\n }\n return serverDate;\n }\n\n static toDate(date: any) {\n return new Date(date);\n }\n}\n","import { createSlice } from \"@reduxjs/toolkit\";\nimport {\n HubConnectionBuilder,\n LogLevel,\n IHttpConnectionOptions,\n HttpTransportType,\n HubConnection,\n HubConnectionState\n} from '@microsoft/signalr';\nimport { ApiClient } from \"../api/api-client\";\nimport { LocalStorageKey } from \"../constants/local-storage-key\";\nimport { Url } from \"../constants/url\";\n\nconst startSignalRConnection = async (connection: HubConnection) => {\n try {\n await connection.start();\n } catch (err) {\n setTimeout(() => startSignalRConnection(connection), 5000);\n }\n};\n\nconst initializeConnection = () => {\n const userInfo = ApiClient.getUserInfo();\n const accessToken = localStorage.getItem(LocalStorageKey.AccessToken)\n\n if (accessToken === null || \n userInfo.hasAccessToWhatsAppConversationsAndNotifications === null || \n !userInfo.hasAccessToWhatsAppConversationsAndNotifications) {\n return;\n }\n\n const connectionOptions: IHttpConnectionOptions = {\n accessTokenFactory: () => {\n return accessToken;\n },\n transport: HttpTransportType.WebSockets,\n skipNegotiation: true,\n }\n\n const connection = new HubConnectionBuilder()\n .withUrl(process.env.REACT_APP_SERVER_URL +\n Url.SignalRHubs.WhatsAppHub, connectionOptions)\n .withAutomaticReconnect()\n .configureLogging(LogLevel.Information)\n .build();\n\n connection.serverTimeoutInMilliseconds = 60000;\n\n startSignalRConnection(connection);\n return connection;\n}\n\nconst initialState = {\n connection: undefined as undefined | HubConnection\n};\n\nexport const whatsAppHubSlice = createSlice({\n name: \"whatsAppHub\",\n initialState: initialState,\n reducers: {\n connect: (state) => {\n if (state.connection === undefined || state.connection.state == HubConnectionState.Disconnected) {\n state.connection = initializeConnection();\n }\n },\n disconnect: (state) => {\n if (state.connection?.state == HubConnectionState.Connected) {\n state.connection.stop();\n }\n }\n }\n});\n\nexport const { connect, disconnect } = whatsAppHubSlice.actions;\n\nexport default whatsAppHubSlice.reducer;","export default class Country {\n iso3: string;\n name: string;\n dialCode: number;\n dialDigits: number;\n dialTemplate: string;\n\n constructor(x?: Country) {\n if (typeof x === \"object\" && x != null) {\n this.iso3 = x.iso3 || \"\";;\n this.name = x.name || \"\";\n this.dialCode = x.dialCode || 0;\n this.dialDigits = x.dialDigits || 0;\n this.dialTemplate = x.dialTemplate || \"\";\n }\n else {\n this.iso3 = \"\";\n this.name = \"\";\n this.dialCode = 0;\n this.dialDigits = 0;\n this.dialTemplate = \"\";\n }\n }\n}\n\n","import { createSlice } from \"@reduxjs/toolkit\";\nimport Country from \"../models/country\";\nimport { AccountSettingsModel } from \"../models/interfaces/account-settings-model\";\n\nconst initialState: AccountSettingsModel = {\n accountId: \"\",\n accountName: \"\",\n accountLogo: \"\",\n currencyTemplate: \"{0}\",\n paymentMethods: [],\n isCashRegisterActivated: false,\n paymentsAndCollectionsEnabled: false,\n isClinicMode: false,\n hasEstablishmentsInClinicMode: false,\n countries: [],\n countryInSettings: new Country(),\n siteForFinalCustomersSmbName: \"\",\n scheduleSimultaneousServicesEnabled: false,\n hasMultipleAppointments: false,\n accountIanaTimezone: \"\",\n isEnterprise: null,\n establishments: [],\n terminologies: [],\n schedulerBlockDurationMinutes: 30\n};\n\nexport const accountSettingsSlice = createSlice({\n name: \"accountSettings\",\n initialState: initialState,\n reducers: {\n setAccountSettings: (currentState, action) => {\n return action.payload;\n },\n setAccountName: (currentState, action) => {\n currentState = {...currentState, accountName: action.payload };\n },\n setAccountLogo: (currentState, action) => {\n currentState = {...currentState, accountLogo: action.payload };\n },\n setCurrencyTemplate: (currentState, action) => {\n currentState = {...currentState, currencyTemplate: action.payload };\n },\n setPaymentMethods: (currentState, action) => {\n currentState = {...currentState, paymentMethods: action.payload };\n },\n setIsCashRegisterActivated: (currentState, action) => {\n currentState = {...currentState, isCashRegisterActivated: action.payload };\n },\n setAccountIanaTimezone: (currentState, action) => {\n currentState = {...currentState, accountIanaTimezone: action.payload };\n },\n setCountries: (currentState, action) => {\n currentState = {...currentState, countries: action.payload };\n },\n setCountryInSettings: (currentState, action) => {\n currentState = {...currentState, countryInSettings: action.payload };\n },\n setSiteForFinalCustomersSmbName: (currentState, action) => {\n currentState = {...currentState, siteForFinalCustomersSmbName: action.payload };\n },\n setScheduleSimultaneousServicesEnabled: (currentState, action) => {\n currentState = {...currentState, scheduleSimultaneousServicesEnabled: action.payload };\n },\n setHasMultipleAppointments: (currentState, action) => {\n currentState = {...currentState, hasMultipleAppointments: action.payload };\n },\n setIsEnterprise: (currentState, action) => {\n currentState = {...currentState, isEnterprise: action.payload };\n },\n setEstablishments: (currentState, action) => {\n currentState = {...currentState, establishments: action.payload };\n },\n }\n})\n\nexport const { \n setAccountSettings, \n setAccountName,\n setAccountLogo,\n setCurrencyTemplate, \n setPaymentMethods, \n setIsCashRegisterActivated,\n setHasMultipleAppointments,\n setAccountIanaTimezone,\n setCountries, \n setCountryInSettings,\n setScheduleSimultaneousServicesEnabled,\n setSiteForFinalCustomersSmbName,\n} = accountSettingsSlice.actions;\n \nexport default accountSettingsSlice.reducer;","import { createSlice } from \"@reduxjs/toolkit\";\n\nimport { EstablishmentSettingsModel } from \"../models/interfaces/establishment-settings-model\";\n\n\nconst initialState: EstablishmentSettingsModel = {\n accountName: \"\",\n terminologies: [],\n};\n\nexport const establishmentSettingsSlice = createSlice({\n name: \"establishmentSettings\",\n initialState: initialState,\n reducers: {\n setEstablishmentSettings: (currentState, action) => {\n return action.payload;\n },\n }\n})\n\nexport const { \n setEstablishmentSettings\n} = establishmentSettingsSlice.actions;\n \nexport default establishmentSettingsSlice.reducer;","export interface ICashRegisterCurrentStateModel {\n initialCash: number;\n cashNow: number;\n paymentsReceived: number;\n cashPayments: number;\n creditCardPayments: number;\n bankTransferPayments: number;\n oxxoPayments: number;\n mercadoPagoPayments: number;\n depositByAdministrator: number;\n withdrawalByAdministrator: number;\n}\n\nexport class CashRegisterCurrentStateModel implements ICashRegisterCurrentStateModel {\n \n initialCash: number;\n cashNow: number;\n paymentsReceived: number;\n cashPayments: number;\n creditCardPayments: number;\n bankTransferPayments: number;\n oxxoPayments: number;\n mercadoPagoPayments: number;\n depositByAdministrator: number;\n withdrawalByAdministrator: number;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.initialCash = x.initialCash;\n this.cashNow = x.cashNow;\n this.paymentsReceived = x.paymentsReceived ?? 0.0;\n this.cashPayments = x.cashPayments ?? 0.0;\n this.creditCardPayments = x.creditCardPayments ?? 0.0;\n this.bankTransferPayments = x.bankTransferPayments ?? 0.0;\n this.oxxoPayments = x.oxxoPayments ?? 0.0;\n this.mercadoPagoPayments = x.mercadoPagoPayments ?? 0.0;\n this.depositByAdministrator = x.depositByAdministrator ?? 0.0;\n this.withdrawalByAdministrator = x.withdrawalByAdministrator ?? 0.0;\n }\n else {\n this.initialCash = 0.0;\n this.cashNow = 0.0;\n this.paymentsReceived = 0.0;\n this.cashPayments = 0.0;\n this.creditCardPayments = 0.0;\n this.bankTransferPayments = 0.0;\n this.oxxoPayments = 0.0;\n this.mercadoPagoPayments = 0.0;\n this.depositByAdministrator = 0.0;\n this.withdrawalByAdministrator = 0.0;\n }\n }\n}","import { CashRegisterMovement } from \"./cash-register-movement\";\n\nexport class CashRegisterMovementHistory {\n movements: CashRegisterMovement[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.movements = x.movements;\n } else {\n this.movements = [];\n }\n }\n}","import { createSlice } from \"@reduxjs/toolkit\";\nimport { CashRegisterStateModel } from \"../models/interfaces/cash-register-state-model\";\nimport { CashRegisterCurrentStateModel } from \"../models/interfaces/cash-register-current-state-model\";\nimport { CashRegisterMovementHistory } from \"../models/cash-register-movement-history\";\n\n\nconst initialState: CashRegisterStateModel = {\n isOpen: false,\n state: new CashRegisterCurrentStateModel(),\n history: new CashRegisterMovementHistory()\n};\n\n\nexport const cashRegisterSlice = createSlice({\n name: \"cashRegisterState\",\n initialState: initialState,\n reducers: {\n setCashRegisterFullState: (currentState, action) => {\n return action.payload;\n },\n setIsOpen: (currentState, action) => {\n currentState = {...currentState, isOpen: action.payload };\n },\n setCashRegisterCurrentState: (currentState, action) => {\n currentState = {...currentState, state: action.payload };\n },\n }\n})\n\nexport const { setCashRegisterFullState, setIsOpen, setCashRegisterCurrentState } = cashRegisterSlice.actions;\nexport default cashRegisterSlice.reducer;","import { createSlice } from \"@reduxjs/toolkit\";\nimport { ScheduleAppointmentTimeStateModel } from \"../models/interfaces/schedule-appointment-time-state-model\";\n\n\nconst initialState: ScheduleAppointmentTimeStateModel = {\n appointmentTime: new Date(),\n newAppointmentViaScheduler: false\n};\n\n\nexport const scheduleAppointmentTimeSlice = createSlice({\n name: \"scheduleAppointmentTimeState\",\n initialState: initialState,\n reducers: {\n setAppointmentTime: (currentState, action) => {\n currentState.appointmentTime = action.payload;\n },\n setClickNewAppointmentOnScheduler: (currentState, action) => {\n currentState.newAppointmentViaScheduler = action.payload;\n },\n }\n})\n\nexport const scheduleAppointmentTimeActions = scheduleAppointmentTimeSlice.actions;\nexport default scheduleAppointmentTimeSlice.reducer;","import React from \"react\";\n\nimport { createSlice } from \"@reduxjs/toolkit\";\n\ninterface EnterpriseState {\n selectedEstablishments: string[] | undefined;\n settingsEstablishmentId: string | undefined;\n}\n\nconst initialState: EnterpriseState = {\n selectedEstablishments: undefined,\n settingsEstablishmentId: undefined\n};\n\n\nconst enterpriseSlice = createSlice({\n name: 'enterprise',\n initialState: initialState,\n reducers: {\n setSelectedEstablishments(currentState, action) {\n currentState.selectedEstablishments = action.payload;\n },\n setSettingsEstablishmentId(currentState, action) {\n currentState.settingsEstablishmentId = action.payload;\n },\n }\n});\n\nexport const enterpriseActions = enterpriseSlice.actions;\nexport default enterpriseSlice.reducer;","import { createSlice } from \"@reduxjs/toolkit\";\nimport { CancelToken } from \"axios\";\n\ninterface FileDownloadState {\n callback: ((setPercentage: (num: number) => void, cancel: CancelToken) => Promise) | null;\n isDownloading: boolean;\n downloadProgress: number;\n fileName: string | null;\n mimeType: string | undefined;\n}\n\nconst initialState: FileDownloadState = {\n callback: null,\n isDownloading: false,\n downloadProgress: 0,\n fileName: null,\n mimeType: undefined\n}\n\nconst fileDownloaderSlice = createSlice({\n name: 'fileDownloader',\n initialState: initialState,\n reducers: {\n startDownload(currentState, action) {\n if (currentState.isDownloading) return currentState;\n return {\n callback: action.payload.callback,\n isDownloading: true,\n downloadProgress: 0,\n fileName: action.payload.fileName,\n mimeType: action.payload.mimeType\n }\n },\n setProgress(currentState, action) {\n if (action.payload < 0 || action.payload > 100) return currentState;\n\n if (action.payload === 100) {\n return initialState\n }\n\n return { ...currentState, downloadProgress: action.payload };\n },\n finishDownload() {\n return initialState;\n },\n cancelDownload() {\n return initialState;\n }\n }\n});\n\nexport const fileDownloadActions = fileDownloaderSlice.actions;\nexport default fileDownloaderSlice.reducer;","import { configureStore } from \"@reduxjs/toolkit\";\n\nimport authenticationReducer from \"./authentication-slice\";\nimport applicationInterfaceReducer from \"./application-interface-slice\";\nimport navbarReducer from \"./navbar-slice\";\nimport blockedScheduleReducer from \"./blocked-schedule-slice\";\nimport multipleBlockedScheduleReducer from \"./multiple-blocked-schedule-slice\";\nimport schedulerReducer from \"./scheduler-slice\";\nimport alertsReducer from \"./alerts-slice\";\nimport commonHubReducer from \"./common-hub-slice\";\nimport whatsAppHubReducer from \"./whatsapp-hub-slice\";\nimport accountSettingsReducer from \"./account-settings-slice\";\nimport establishmentSettingsReducer from \"./establishment-settings-slice\";\nimport userInfoReducer from \"./user-info-slice\";\nimport cashRegisterReducer from \"./cash-register-slice\";\nimport scheduleAppointmentTimeReducer from \"./schedule-appointment-time-slice\";\nimport enterpriseReducer from \"./enterprise-slice\";\nimport fileDownloadReducer from \"./file-downloader-slice\";\n\n\nconst store = configureStore({\n reducer: {\n authentication: authenticationReducer,\n applicationInterface: applicationInterfaceReducer,\n navbar: navbarReducer,\n blockedSchedule: blockedScheduleReducer,\n multipleBlockedSchedule: multipleBlockedScheduleReducer,\n scheduler: schedulerReducer,\n alerts: alertsReducer,\n commonHub: commonHubReducer,\n whatsAppHub: whatsAppHubReducer,\n accountSettings: accountSettingsReducer,\n establishmentSettings: establishmentSettingsReducer,\n userInfo: userInfoReducer,\n cashRegister: cashRegisterReducer,\n scheduleAppointmentTime: scheduleAppointmentTimeReducer,\n enterprise: enterpriseReducer,\n fileDownloader: fileDownloadReducer\n },\n middleware: (getDefaultMiddleware) =>\n getDefaultMiddleware({\n serializableCheck: false,\n }),\n});\n\nexport default store;\n\nexport const selectAccountSettings = (state: RootState) => state.accountSettings;\nexport const selectEstablishmentSettings = (state: RootState) => state.establishmentSettings;\nexport const selectUserInfo = (state: RootState) => state.userInfo;\nexport const selectCommonHubConnection = (state: RootState) => state.commonHub.connection;\nexport const selectCashRegisterState = (state: RootState) => state.cashRegister;\nexport const selectCashRegisterOpen = (state: RootState) => state.cashRegister.isOpen;\n\nexport type RootState = ReturnType;\nexport type AppDispatch = typeof store.dispatch;\n","import { TypedUseSelectorHook, useDispatch, useSelector } from 'react-redux'\nimport type { RootState, AppDispatch } from './store'\n\nexport const useAppDispatch = () => useDispatch()\nexport const useAppSelector: TypedUseSelectorHook = useSelector\n","import i18n from \"i18next\";\nimport { initReactI18next } from \"react-i18next\";\nimport enGeneral from './assets/locales/en/general.json';\nimport esGeneral from './assets/locales/es/general.json';\nimport enNav from './assets/locales/en/nav.json';\nimport esNav from './assets/locales/es/nav.json';\nimport enClinicCustomer from './assets/locales/en/clinic_terminology_customer.json';\nimport esClinicCustomer from './assets/locales/es/clinic_terminology_customer.json';\nimport enMassiveSendings from './assets/locales/en/massivesendings.json';\nimport esMassiveSendings from './assets/locales/es/massivesendings.json';\nimport enClinicPatient from './assets/locales/en/clinic_terminology_patient.json';\nimport esClinicPatient from './assets/locales/es/clinic_terminology_patient.json';\nimport enSections from './assets/locales/en/sections.json';\nimport esSections from './assets/locales/es/sections.json';\nimport enSettings from './assets/locales/en/settings.json';\nimport esSettings from './assets/locales/es/settings.json';\nimport enTerminologies from './assets/locales/en/terminologies.json';\nimport esTerminologies from './assets/locales/es/terminologies.json';\n\ni18n\n .use(initReactI18next)\n .init({\n lng: process.env.REACT_APP_DEFAULT_LANGUAGE ?? 'es',\n fallbackLng: process.env.REACT_APP_FALLBACK_LANGUAGE ?? 'en', // use en if detected lng is not available\n resources: {},\n react: {\n defaultTransParent: 'div', // a valid react element - required before react 16\n transEmptyNodeValue: '', // what to return for empty Trans\n transSupportBasicHtmlNodes: true, // allow
and simple html elements in translations\n transKeepBasicHtmlNodesFor: ['br', 'strong', 'i'], // don't convert to <1> if simple react elements\n transWrapTextNodes: ''\n }\n });\n\n// General\ni18n.addResourceBundle('en', 'general', enGeneral, true, true);\ni18n.addResourceBundle('es', 'general', esGeneral, true, true);\n\n// Navbar\ni18n.addResourceBundle('en', 'nav', enNav, true, true);\ni18n.addResourceBundle('es', 'nav', esNav, true, true);\n\n// Clinic Terminology Customer\ni18n.addResourceBundle('en', 'clinic_terminology_customer', enClinicCustomer, true, true);\ni18n.addResourceBundle('es', 'clinic_terminology_customer', esClinicCustomer, true, true);\n\n// Massive Sendings\ni18n.addResourceBundle('en', 'massivesendings', enMassiveSendings, true, true);\ni18n.addResourceBundle('es', 'massivesendings', esMassiveSendings, true, true);\n\n// Clinic Terminology Patient\ni18n.addResourceBundle('en', 'clinic_terminology_patient', enClinicPatient, true, true);\ni18n.addResourceBundle('es', 'clinic_terminology_patient', esClinicPatient, true, true);\n\n// Sections\ni18n.addResourceBundle('en', 'sections', enSections, true, true);\ni18n.addResourceBundle('es', 'sections', esSections, true, true);\n\n// Settings\ni18n.addResourceBundle('en', 'settings', enSettings, true, true);\ni18n.addResourceBundle('es', 'settings', esSettings, true, true);\n\n// Terminologies\ni18n.addResourceBundle('en', 'terminologies', enTerminologies, true, true);\ni18n.addResourceBundle('es', 'terminologies', esTerminologies, true, true);\n\nexport default i18n;","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function ArrowLeftIcon(props: any) {\n \n const { style, color, ...otherProps } = props;\n \n return (\n \n \n \n )\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function ArrowRightIcon(props: any) {\n\n const { style, color, ...otherProps } = props;\n\n return (\n \n \n \n )\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function CashRegisterIcon(props: any) {\n\n const { style, color, ...otherProps } = props;\n\n return (\n \n \n \n )\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ComputerIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default ComputerIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst BanIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default BanIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\ninterface DotIconProps {\n color: string;\n [x: string]: any;\n}\n\nconst DotIcon = (props: DotIconProps) => {\n const { color, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default DotIcon;\n","import React from 'react';\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function DocumentIcon(props: any) {\n\n const { style, viewBox, color, ...otherProps } = props;\n\n return (\n \n \n \n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ConversationIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default ConversationIcon;\n","export enum CustomerFrequencyType {\n Inactive = 1,\n Frequent,\n Infrequent\n}\n","import React from \"react\";\nimport { CustomerFrequencyType } from \"../../models/enums/customer-frequency-type\";\nimport DotIcon from \"./DotIcon\";\n\ninterface StatusIconProps {\n status: CustomerFrequencyType;\n [x: string]: any;\n}\n\nconst StatusIcon = (props: StatusIconProps) => {\n const { status, ...otherProps } = props;\n let color: string = \"\";\n switch (status) {\n case CustomerFrequencyType.Frequent:\n color = \"#36CE91\";\n break;\n case CustomerFrequencyType.Infrequent:\n color = \"#FFC626\";\n break;\n default:\n color = \"#F15857\";\n break;\n }\n\n return (\n \n );\n};\n\nexport default StatusIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SortDownIcon = () => (\n \n \n \n);\n\nexport default SortDownIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SortUpIcon = () => (\n \n \n \n );\n\nexport default SortUpIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SortIcon = () => (\n \n \n \n);\n\nexport default SortIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst GroupIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default GroupIcon;\n","import React from 'react';\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function GroupAppointmentsIcon(props: any) {\n\n const { style, viewBox, color, ...otherProps } = props;\n\n return (\n \n \n \n )\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function PersonIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ImportIcon = () => (\n \n \n \n);\n\nexport default ImportIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SuccessIcon = () => (\n \n \n \n \n \n);\n\nexport default SuccessIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ErrorIcon = () => (\n \n \n \n \n \n);\n\nexport default ErrorIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function EditIcon(props: any) {\n const { style, viewBox, color, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MinusArrowIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default MinusArrowIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst PhoneIcon = () => (\n \n \n \n);\n\nexport default PhoneIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst NoteIcon = (props: any) => {\n const { style, viewBox, color, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default NoteIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst EditIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default EditIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ExportIcon = (props: any) => {\n const { style, viewBox, color, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default ExportIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ExportFileIcon = (props: any) => {\n const { style, viewBox, color, ...otherProps } = props;\n return (\n \n \n \n \n \n \n \n \n \n \n\n \n );\n};\n\nexport default ExportFileIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SaveIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default SaveIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function CrossIcon(props: any) {\n\n const { style, viewBox, color, ...otherProps } = props;\n\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst PlusIcon = (props: any) => {\n\n const { style, viewBox, color, disabled, ...otherProps } = props;\n \n return (\n \n \n \n );\n}\n\nexport default PlusIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst DeleteIcon = (props: any) => {\n const { color, ...otherProps } = props;\n return (\n \n )\n};\n\nexport default DeleteIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MenuIconWhatsapp = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MenuIconWhatsapp;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MenuIconSettings = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MenuIconSettings;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function MenuIconReports(props: any) {\n return (\n \n \n \n \n \n )\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MenuIconCustomer = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MenuIconCustomer;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MenuIconLogoClear = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MenuIconLogoClear;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MenuIconPower = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MenuIconPower;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst MercadoPagoIcon = (props: any) => {\n \n const { style, color, ...otherProps } = props;\n \n return (\n \n \n \n \n \n \n \n )\n};\n\nexport default MercadoPagoIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst OxxoIcon = (props: any) => {\n\n const { style, color, ...otherProps } = props;\n \n return (\n \n \n \n )\n};\n\nexport default OxxoIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst TrashIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default TrashIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst FlagIcon = (props: any) => {\n return (\n \n \n \n );\n};\n\nexport default FlagIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst NotesIcon = (props: any) => {\n return (\n \n \n \n );\n};\n\nexport default NotesIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MoneyIcon = (props: any) => {\n const { style, color, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default MoneyIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CalendarCancelIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default CalendarCancelIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MegaphoneIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MegaphoneIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst FiltersIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default FiltersIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst DoorIcon = (props: any) => {\n return (\n \n \n \n );\n};\n\nexport default DoorIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ExclamationIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default ExclamationIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst BroadcastIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default BroadcastIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ArrowDropDownIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default ArrowDropDownIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ExcelIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default ExcelIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nconst UploadFileCloud = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\nexport default UploadFileCloud;\n","import React from 'react';\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function DownloadCloudIcon(props: any) {\n\n const { style, viewBox, color, ...otherProps } = props;\n\n return (\n \n \n \n )\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst AddCustomerIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default AddCustomerIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function FlatImageIcon(props: any) {\n\n const { style, viewBox, color, ...otherProps } = props;\n\n return (\n \n \n\n \n );\n}\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst InfoIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default InfoIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ArrowLineDown = (props: any) => (\n \n \n \n);\n\nexport default ArrowLineDown;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CalendarIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default CalendarIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CalendarIcon2 = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n const fill = \"#6462F3\"\n return (\n \n \n \n \n );\n};\n\nexport default CalendarIcon2;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst InfoCircleIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default InfoCircleIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CameraIcon = (props: any) => {\n\n const { style, viewBox, ...otherProps } = props;\n \n return (\n \n \n \n );\n}\n\nexport default CameraIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SearchIcon = (props: any) => {\n\n const { style, viewBox, ...otherProps } = props;\n \n return (\n \n \n \n );\n}\n\nexport default SearchIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst PDFIcon = (props: any) => {\n const { style, width, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default PDFIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CashIcon = (props: any) => {\n \n const { style, color, ...otherProps } = props;\n \n return (\n \n \n \n )\n};\nexport default CashIcon;","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst CreditCardIcon = (props: any) => {\n \n const { color, style, ...otherProps } = props;\n \n return (\n \n \n \n )\n};\nexport default CreditCardIcon;","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst BankIcon = (props: any) => {\n \n const { color, style, ...otherProps } = props;\n \n return (\n \n \n \n )\n};\nexport default BankIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst LogoIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default LogoIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nconst DownloadFileCloud = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\nexport default DownloadFileCloud;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CheckIcon = (props: any) => {\n const { viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default CheckIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function WhatsAppNotificationIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function ScreenNotificationIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function WhatsAppNotificationIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst DotsVerticalIcon = (props: any) => {\n return (\n \n \n \n \n \n );\n};\n\nexport default DotsVerticalIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ClockIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default ClockIcon;\n","import React from 'react';\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst MenuIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default MenuIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function SideArrowForMessageIcon(props: any) {\n const { style, viewBox, color, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst AdminIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default AdminIcon;\n","export enum Color {\n clear1 = \"#6462F3\",\n clear2 = \"#7175FA\",\n clear3 = \"#9FA9E6\",\n clear4 = \"#BDC7F8\",\n clear5 = \"#E1E9FE\",\n clear6 = \"#E9F1FE\",\n\n gray1 = \"#F6F6F6\",\n gray2 = \"#C9CDD3\",\n gray3 = \"#ACB7C0\",\n gray4 = \"#919CA5\",\n gray5 = \"#5C6477\",\n gray6 = \"#323947\",\n gray7 = \"#1D2027\",\n\n white = \"#FFFFFF\",\n green = \"#36CE91\",\n red = \"#F15857\",\n yellow = \"#FFC626\",\n blue = \"#0BCBE0\",\n clilac = \"#EAE9FF\",\n}\n\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ArrowDownIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default ArrowDownIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ListPlusIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n );\n};\n\nexport default ListPlusIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst UserIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default UserIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst BellIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default BellIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function DollarSignNotificationIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function WhatsAppPDFIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function WhatsAppVideoIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nimport { Color } from \"../../constants/colors\";\n\n\nexport default function WhatsAppPlayVideoIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nimport { Color } from \"../../constants/colors\";\n\n\nexport default function WhatsAppPlayAudioIcon(props: any) {\n\n const { style, viewBox, ...otherProps } = props;\n\n return (\n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nimport { Color } from \"../../constants/colors\";\n\n\nexport default function WhatsAppMicrophoneIcon(props: any) {\n\n const { style, viewBox, ...otherProps } = props;\n\n return (\n \n \n \n \n \n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nimport { Color } from \"../../constants/colors\";\n\n\nexport default function WhatsAppAudioLogo(props: any) {\n\n const { style, viewBox, ...otherProps } = props;\n\n return (\n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nimport { Color } from \"../../constants/colors\";\n\n\nexport default function VideoCameraEmptyIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nimport { Color } from \"../../constants/colors\";\n\n\nexport default function VideoCameraFilledIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst LinkIcon = (props: any) => {\n return (\n \n \n \n )\n};\n\nexport default LinkIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function CalendarCheckmarkIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function PersonCheckmarkIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function PersonSpeechBalloonIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n );\n};","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionNewIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionArrowIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionEditIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionDeleteIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldNewIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function DraggableIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n \n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldTextIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldDropdownIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldRadioIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldCheckboxIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldNumericIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldDateIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldPhoneIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldCheckboxItemIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldDropdownItemIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldOptionalTextFieldIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldRadioItemIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionSaveIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionExitEditIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionFieldEmailIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst SuggestedServicesIcon = (props: any) => {\n const { style, ...otherProps } = props;\n return (\n \n \n \n \n \n \n \n );\n};\n\nexport default SuggestedServicesIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function MedicalBookIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientAppointmentsIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientContactIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientFemaleIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientGeneralDataIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientMaleIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientServicesIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function InternalNotesIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst WordIcon = (props: any) => {\n const { style, width, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default WordIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ImageIcon = (props: any) => {\n const { style, width, height, ...otherProps } = props;\n return (\n \n \n \n )\n};\nexport default ImageIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function PatientStethoscopeIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function RoundCheckmarkIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ListMarkIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default ListMarkIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst EyeIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default EyeIcon;\n","\nimport React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function WarningIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst BillsIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n);\n};\n\nexport default BillsIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst BillIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n);\n};\n\nexport default BillIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function TimeLimitIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function SheetIcon (props: any) {\n\n const { style, viewBox, ...otherProps } = props;\n \n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ListIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default ListIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst PenIcon = (props: any) => {\n\n const { style, color, viewBox, ...otherProps } = props;\n\n return (\n \n \n \n \n )\n};\n\nexport default PenIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function CopyIcon(props: any) {\n const { style, viewBox, color, border, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function ReportPersonIcon(props: any) {\n const { style, viewBox, color, ...otherProps } = props;\n return (\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function CloseIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CheckboxCheckedIcon = (props: any) => {\n const { viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default CheckboxCheckedIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CheckboxUncheckedIcon = (props: any) => {\n const { viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default CheckboxUncheckedIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function CaptionImageMediaIcon(props: any) {\n const { style, height, width, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function WhatsAppDocumentIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function CaptionDocumentMediaIcon(props: any) {\n const { style, height, width, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\nimport { Color } from \"../../constants/colors\";\n\nexport default function SectionGearIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst BlockIcon = (props: any) => {\n const { style, color, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default BlockIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst StopHandIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n};\n\nexport default StopHandIcon;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n flexGrow: 1,\n },\n menuButton: {\n },\n title: {\n fontSize: 14,\n fontWeight: 700,\n fontFamily: \"Inter, sans-serif\",\n color: theme.colors.grey4,\n },\n externalContentPlaceholder: {\n flexGrow: 1,\n },\n verticalDivider: {\n height: 40,\n \n paddingRight: 15,\n marginRight: 15,\n borderRightColor: theme.colors.grey2,\n borderRightWidth: 1,\n borderRightStyle: \"solid\",\n },\n establishmentSelector: {\n },\n paper: {\n color: \"#fff\",\n background: \"#1D2027\",\n borderTopRightRadius: \"20px\",\n borderBottomRightRadius: \"20px\",\n width: \"250px\",\n },\n logoClear: {\n color: \"#F6F6F6\",\n fontSize: \"42px\",\n marginTop: \"30px\"\n },\n iconLogoClear: {\n margin: \"15px 5px 0 0\",\n fontSize: \"48px\",\n color: \"#F6F6F6\"\n },\n enterpriseLabel: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey2,\n },\n versionLabel: {\n color: \"#5C6477\",\n fontSize: \"10px\" \n },\n drawerListItems: {\n overflow: \"hidden\"\n },\n tablecss: {\n height: \"100%\",\n borderCollapse: \"collapse\"\n },\n userLabel: {\n color: \"#F6F6F6\",\n fontSize: \"1rem\",\n margin: \"40px 0 0 0\"\n },\n emailLabel: {\n color: \"#919CA5\",\n fontSize: \"12px\",\n overflow: \"hidden\",\n margin: \"0 0 40px 0\",\n overflowWrap: \"break-word\",\n width: 200\n },\n linkMenu: {\n backgroundColor: \"inherit\",\n color: \"#ACB7C0\",\n \"&:hover\": {\n color: \"#FFFFFF\",\n textDecoration: \"none\",\n \"& * svg\": {\n color: \"#FFFFFF\"\n }\n },\n \"& * svg\": {\n color: \"#ACB7C0\",\n },\n },\n \n linkMenuParent: {\n backgroundColor: \"inherit\",\n color: \"#ACB7C0\",\n \"& * svg\": {\n color: \"#ACB7C0\",\n },\n },\n listItem: {\n borderLeft: \"5px solid transparent\",\n },\n listItemActive: {\n color: \"#FFFFFF\",\n borderLeft: \"5px solid #6361f2\",\n backgroundColor: \"#2e3138\",\n \"& * svg\": {\n color: \"#FFF\",\n },\n \"&:hover\": {\n backgroundColor: \"#2e3138\",\n }\n },\n childItemActive: {\n color: \"#FFFFFF\",\n backgroundColor: \"#2e3138\",\n \"& * svg\": {\n color: \"#FFF\",\n },\n \"&:hover\": {\n backgroundColor: \"#2e3138\",\n }\n },\n listSubItemActive: {\n paddingLeft: 30,\n color: \"#FFFFFF\",\n borderLeft: \"5px solid #6361f2\",\n backgroundColor: \"#2e3138\",\n \"& * svg\": {\n color: \"#FFF\",\n },\n overflow: \"hidden\",\n \"&:hover\": {\n backgroundColor: \"#2e3138\",\n }\n },\n listItemIcon: {\n height: 25,\n width: 30,\n minWidth: 30,\n margin: \"auto\",\n paddingTop: 5,\n },\n menuIcon: {\n margin: \"auto\",\n fontSize: \"24px\",\n },\n listItemText: {\n marginLeft: \"10px\",\n fontSize: \"14px\",\n width: \"100%\"\n },\n menuHorizontalTop: {\n padding: \"3px 15px\",\n backgroundColor: \"#fff\",\n color: \"#919CA5\", // gray4\n fontWeight: \"bold\",\n borderBottom: \"1px solid #F6F6F6\",\n // Centering AppBar\n position: \"fixed\",\n left: 0,\n right: 0,\n margin: \"auto\",\n overflow: \"hidden\",\n },\n listSubItem: {\n marginLeft: 20,\n width: \"auto\",\n \"&:hover\": {\n color: \"#FFFFFF\",\n textDecoration: \"none\",\n \"& * svg\": {\n color: \"#FFFFFF\"\n }\n },\n \"& * svg\": {\n color: \"#ACB7C0\",\n },\n },\n iconsBlock: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n width: 85,\n },\n referFriend: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: \"#344153\",\n borderRadius: 10,\n color: Color.clilac,\n padding: \"8px 14px 14px\",\n margin: \"14px\"\n },\n referFriendTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontSize: 14,\n fontWeight: 700,\n marginBottom: 8\n },\n referFriendDescription: {\n fontFamily: \"Inter, sans-serif\",\n fontSize: 11,\n fontWeight: 400,\n marginBottom: 15\n },\n referFriendLink: {\n fontFamily: \"Inter, sans-serif\",\n display: \"inline-block\",\n width: \"100%\",\n height: 22,\n textAlign: \"center\",\n fontSize: 12,\n fontWeight: 700,\n border: \"1px solid \" + Color.clilac,\n borderRadius: 11,\n color: Color.clilac,\n \"&:hover\":{\n color: Color.clilac,\n }\n },\n popper:{\n [`& .MuiTooltip-tooltip`]: {\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12\n }\n }\n}));\n","import axios from \"axios\";\n\nimport { ApiClient } from \"./api-client\"\nimport { Url } from \"../constants/url\";\nimport store from \"../redux/store\";\nimport { setUserInfo } from \"../redux/user-info-slice\";\n\nexport class AuthenticationService {\n private static baseUrl = process.env.REACT_APP_SERVER_URL;\n\n static async login(email: string, password: string, captchaToken: string) {\n const formData = {\n email: email,\n password: password,\n captchaToken: captchaToken\n };\n\n return axios.post(`${this.baseUrl}/Login`, formData, { withCredentials: true })\n .then((resp) => {\n const { accessToken, succeeded } = resp.data;\n if (succeeded && accessToken && accessToken !== \"\") {\n ApiClient.configureAuthorization(accessToken);\n store.dispatch(setUserInfo(ApiClient.getUserInfo()));\n return;\n }\n return Promise.reject(\"authentication failed\");\n })\n .catch((error) => {\n return Promise.reject(error?.response?.data || error);\n });\n }\n \n static async loginEnterprise(email: string, password: string, captchaToken: string) {\n const formData = {\n email: email,\n password: password,\n captchaToken: captchaToken\n };\n \n return axios.post(`${this.baseUrl}/enterprise/Login`, formData, { withCredentials: true })\n .then((resp) => {\n const { accessToken, succeeded } = resp.data;\n if (succeeded && accessToken && accessToken !== \"\") {\n ApiClient.configureAuthorization(accessToken);\n store.dispatch(setUserInfo(ApiClient.getUserInfo()));\n return;\n }\n return Promise.reject(\"authentication failed\");\n })\n .catch((error) => {\n return Promise.reject(error?.response?.data || error);\n });\n }\n\n static signup(email: string, name: string, password: string, timeZoneId: string) {\n const formData = {\n email: email,\n name: name,\n password: password,\n timeZoneId: timeZoneId\n };\n\n return axios.post(`${this.baseUrl}/signup`, formData)\n .then((resp) => {\n window.location.href = Url.Authentication.Login;\n })\n .catch((data) => {\n throw new Error(data);\n });\n }\n\n static recoverPassword(email: string, captchaToken: string) {\n const formData = {\n email,\n captchaToken\n }\n\n return axios.post(`${this.baseUrl}/RecoverPassword`, formData);\n }\n \n static recoverPasswordEnterprise(email: string, captchaToken: string) {\n const formData = {\n email,\n captchaToken\n }\n \n return axios.post(`${this.baseUrl}/enterprise/RecoverPassword`, formData);\n }\n \n static resetPassword(email: string, token: string, newPassword: string, captchaToken: string) {\n const formData = {\n email,\n token,\n newPassword,\n captchaToken\n }\n return axios.post(`${this.baseUrl}/ResetPassword`, formData);\n }\n\n static async logout() {\n try {\n await axios.post(`${this.baseUrl}/logout`, {}, { withCredentials: true });\n } finally {\n ApiClient.removeAuthorization();\n window.location.href = Url.Authentication.Login;\n }\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n paper: {\n marginTop: -10,\n width: 360,\n borderRadius: 10\n },\n list: {\n padding: 0\n },\n iconNotificationButton: {\n width: 40,\n height: 40,\n backgroundColor: \"#F6F6F6\",\n \"&:hover\": {\n color: \"#fff\",\n backgroundColor: \"#6462F3\",\n },\n \n position: \"relative\"\n },\n notificationDot: {\n width: 16,\n height: 16,\n \n display: \"block\",\n position: \"absolute\",\n top: 0,\n right: 0,\n textAlign: \"center\",\n paddingTop: 0.7,\n \n backgroundColor: theme.colors.clearRed,\n borderRadius: \"50%\",\n \n fontFamily: \"Inter, sans-serif\",\n fontSize: 9,\n fontWeight: 700,\n \n color: theme.colors.grey1,\n \n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n width: 360,\n height: 72,\n display: \"flex\",\n justifyContent: \"space-between\"\n },\n titleBlock: {\n justifySelf: \"flex-start\",\n alignSelf: \"center\",\n marginLeft: 20\n },\n titleText: {\n ...theme.typography.header4,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n },\n closeIconButton: {\n \n },\n closeButtonContainer: {\n justifySelf: \"flex-end\",\n alignSelf: \"center\",\n marginRight: 25,\n color: theme.colors.clearMain\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport useStyles from \"./css\";\nimport { useTranslation } from \"react-i18next\";\nimport { INotificationHeaderProps } from \"./props\";\nimport { CrossIcon } from \"../../../../assets/icons\";\nimport IconButton from \"@material-ui/core/IconButton\";\n\n\nexport default function NotificationHeader(props: INotificationHeaderProps) {\n \n const { handleClose } = props;\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n return (\n
\n
\n \n {t(\"Notifications\")}\n \n
\n
\n \n
\n \n
\n \n
\n
\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n\n width: 360,\n\n position: \"sticky\",\n bottom: 0,\n\n backgroundColor: \"#ffffff\",\n },\n messagesIconContainer: {\n width: 40,\n height: 40,\n },\n messageRing: {\n width: 40,\n height: 40,\n },\n manyMessagesRemain: {\n color: theme.colors.clearGreen\n },\n halfMessagesRemain: {\n color: theme.colors.clearYellow\n },\n lowMessagesRemain: {\n color: theme.colors.clearRed\n },\n noMessagesRemain: {\n color: theme.colors.grey1\n },\n expander: {\n height: 22,\n\n marginRight: 12,\n\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n color: theme.colors.grey5,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\"\n },\n upsideDown: {\n \"-moz-transform\": \"scaleY(-1)\",\n \"-o-transform\": \"scaleY(-1)\",\n \"-webkit-transform\": \"scaleY(-1)\",\n transform: \"scaleY(-1)\",\n },\n messagesFirstRow: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n gap: 5,\n\n height: 72,\n },\n messagesFirstRowText: {\n width: 270,\n height: 34,\n\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n firstRowExpandedBorder: {\n borderBottom: \"solid\",\n borderBottomWidth: 1,\n borderBottomColor: \"rgba(201, 205, 211, 0.5)\",\n },\n messagesText: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n height: 28,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey6,\n },\n divider: {\n width: 270,\n height: 0,\n\n borderBottom: \"solid\",\n borderBottomWidth: 1,\n borderBottomColor: \"rgba(201, 205, 211, 0.5)\",\n },\n })\n);\n\nexport default useStyles;","export enum NotificationType {\n UnreadMessages = 0,\n CustomerRequiresAttention,\n NewAppointment,\n AppointmentConfirmedByCustomer,\n ProofOfPayment,\n AppointmentModifiedByCustomer,\n AppointmentCancelledByCustomer,\n CustomerRequiresQuote,\n ModifiedAppointment\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n iconContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n \n width: 40,\n height: 40\n },\n ring: {\n width: 40,\n height: 40,\n position: \"absolute\"\n },\n svg: {\n transform: \"rotate(-90deg)\"\n },\n circle: {\n fill: \"transparent\",\n strokeWidth: 2,\n strokeLinecap: \"round\",\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { IProgressRingWithIconProps } from \"./props\";\nimport useStyles from \"./css\";\n\nexport default function ProgressRingWithIcon(props: IProgressRingWithIconProps) {\n \n const classes = useStyles();\n const { icon, fillPercent, color, ...otherProps } = props;\n \n const radius = 18;\n const circumference = radius * 2 * Math.PI;\n const offset = circumference - fillPercent / 100 * circumference;\n \n return (\n
\n
\n \n \n \n \n
\n
\n {icon}\n
\n
\n );\n}","import React, { useState } from \"react\";\n\nimport useStyles from \"./css\";\nimport { useTranslation } from \"react-i18next\";\nimport ProgressRingWithIcon from \"../../../common/ProgressRingWithIcon\";\nimport WhatsAppNotificationIcon from \"../../../../assets/icons/WhatsAppNotificationIcon\";\nimport { Color } from \"../../../../constants/colors\";\nimport ConversationCounter from \"../../../../models/interfaces/conversation-counter-model\";\nimport { ArrowDropDownIcon } from \"../../../../assets/icons\";\n\n\nexport default function NotificationFooter(props: { conversationCounter: ConversationCounter }) {\n \n const { conversationCounter } = props;\n const { monthlyConversationsLimit, spentMarketing, spentUtility, availableConversationsCount } = conversationCounter;\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n const [isExpanded, setIsExpanded] = useState(false);\n \n function getProgressRingFillPercent() {\n if (availableConversationsCount <= 0) return 0;\n const remainingPart = availableConversationsCount / monthlyConversationsLimit;\n return Math.round(remainingPart * 100);\n }\n \n const fillPercent = getProgressRingFillPercent();\n \n function getColorByFillPercent() {\n if (fillPercent <= 0) return Color.gray1;\n if (fillPercent > 50) return Color.green;\n if (fillPercent <= 25) return Color.red;\n return Color.yellow;\n }\n \n const iconColor = getColorByFillPercent();\n \n const WhatsAppIcon =\n \n\n function handleExpanderClick(e: any) {\n e.stopPropagation();\n setIsExpanded(!isExpanded);\n }\n\n const ArrowIcon = \n \n return (\n
\n
\n
\n \n
\n
\n {`${availableConversationsCount}/${monthlyConversationsLimit} ${t(\"available WA conversations\")}`}\n
\n \n \n {ArrowIcon}\n
\n
\n \n {\n isExpanded &&\n <>\n
\n {`${t(\"WA marketing conversations used\")}: ${spentMarketing}`}\n
\n
\n
\n {`${t(\"WA utility/service conversations used\")}: ${spentUtility}`}\n
\n \n }\n
\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n width: 360,\n minHeight: 90,\n\n display: \"flex\",\n flexDirection: \"column\",\n position: \"relative\",\n justifyContent: \"space-between\",\n \n padding: \"16px 16px 12px 20px\",\n \n border: \"1px solid #F6F6F6\",\n backgroundColor: \"#FFFFFF\",\n \"&:hover\": {\n backgroundColor: theme.colors.clear5,\n }\n },\n unreadDot: {\n width: 8,\n height: 8,\n \n display: \"block\",\n position: \"absolute\",\n left: 7,\n top: 20,\n backgroundColor: theme.colors.clearMain,\n borderRadius: \"50%\",\n },\n headerRow: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n alignItems: \"center\"\n },\n header: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\"\n },\n headerIcon: {\n height: 16,\n width: 16,\n marginRight: 4,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\"\n },\n headerText: {\n ...theme.typography.txtBody3,\n color: theme.colors.grey5\n },\n senderRow: {\n minHeight: 17\n },\n mainText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey6\n },\n textRow: {\n minHeight: 17,\n \n justifySelf: \"flex-end\",\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"flex-end\"\n },\n additionalText: {\n width: 280,\n \n ...theme.typography.txtBody1,\n color: theme.colors.grey5\n },\n strongText: {\n fontWeight: \"bold\"\n },\n messageCounter: {\n width: 22,\n height: 22,\n \n \n alignSelf: \"flex-end\",\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n backgroundColor: theme.colors.clearBlue,\n borderRadius: 20,\n \n color: theme.colors.grey1,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\"\n },\n expander: {\n width: 26,\n height: 22,\n \n alignSelf: \"flex-start\",\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n backgroundColor: theme.colors.clearMain,\n borderRadius: 20,\n \n color: theme.colors.grey1,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\"\n },\n upsideDown: {\n \"-moz-transform\": \"scaleY(-1)\",\n \"-o-transform\": \"scaleY(-1)\",\n \"-webkit-transform\": \"scaleY(-1)\",\n transform: \"scaleY(-1)\",\n },\n timeContainer: {\n ...theme.typography.txtBody3,\n color: theme.colors.grey5\n },\n fromToDateTimeRow: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n paddingTop: 7,\n fontFamily: \"Inter, sans-serif\",\n },\n fromToLabel: {\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontFamily: \"Inter, sans-serif\",\n }\n })\n);\n\nexport default useStyles;","export enum AppointmentCreatedBy {\n Account = 0,\n Customer\n}\n","export enum AppointmentStatus {\n NotConfirmed = 0,\n Confirmed,\n NotArrived,\n Arrived\n}\n","export enum AppointmentPaymentStatus {\n Unpaid = 0,\n Paid,\n PaidPartially,\n}","import { AppointmentCreatedBy } from \"./enums/appointment-created-by\";\nimport { AppointmentStatus } from \"./enums/appointment-status\";\nimport { DateTime } from 'luxon';\n\nexport class Appointment {\n appointmentId: string;\n startDate: DateTime;\n endDate: DateTime;\n title?: string | undefined;\n status: AppointmentStatus;\n createdBy: AppointmentCreatedBy;\n customerName: string;\n firstServiceId: string | null;\n users: string[];\n userId: string;\n isEditable: boolean;\n establishmentId: string | null;\n establishmentName: string | null;\n services: string[];\n isDraggable: boolean;\n isRecurring: boolean;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.appointmentId = x.appointmentId;\n this.startDate = DateTime.fromISO(x.startDate);\n this.endDate = DateTime.fromISO(x.endDate);\n this.status = x.status;\n this.createdBy = x.createdBy;\n this.customerName = x.customerName;\n this.firstServiceId = x.firstServiceId;\n this.users = x.users;\n this.userId = x.userId;\n this.isEditable = x.isEditable;\n this.establishmentId = x.establishmentId;\n this.establishmentName = x.establishmentName;\n this.services = x.services;\n this.isDraggable = x.isDraggable;\n this.isRecurring = x.isRecurring;\n } else {\n this.appointmentId = \"\";\n this.status = AppointmentStatus.NotConfirmed;\n this.createdBy = AppointmentCreatedBy.Account;\n this.startDate = DateTime.now();\n this.endDate = DateTime.now();\n this.customerName = \"\";\n this.firstServiceId = null;\n this.users = [];\n this.userId = \"\";\n this.isEditable = true;\n this.establishmentId = null;\n this.establishmentName = null;\n this.services = [];\n this.isDraggable = false;\n this.isRecurring = false;\n }\n }\n}\n","export class AppointmentServiceModel {\n id: string | null;\n name: string | null;\n duration: number | null;\n price: number | null;\n user: string | null;\n workArea: string | null;\n startDate: Date | null;\n endDate: Date | null;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.duration = x.duration;\n this.price = x.price;\n this.user = x.user;\n this.workArea = x.workArea;\n this.startDate = x.startDate;\n this.endDate = x.endDate;\n } else {\n this.id = null;\n this.name = null;\n this.duration = null;\n this.price = null;\n this.user = null;\n this.workArea = null;\n this.startDate = null;\n this.endDate = null;\n }\n }\n}\n","export class AppointmentAvailableHours {\n availableHours: string[] | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.availableHours = x.availableHours;\n } else {\n this.availableHours = null;\n }\n }\n}\n","import { CreateAppointmentService } from \"./create-appointment-service\";\nimport { AppointmentPaymentStatus } from \"./enums/appointment-payment-status\";\nimport { AppointmentRecurrenceInterval } from \"./enums/appointment-recurrence-interval\";\nimport { AppointmentStatus } from \"./enums/appointment-status\";\nimport { CustomRecurrenceMode } from \"./enums/custom-recurrence-mode\";\nimport { WeekDaysFlags } from \"./enums/week-days-flags\";\n\nexport class CreateAppointmentModel {\n id: string | null;\n number: number | null;\n userId: string | null;\n user: string | null;\n customerId: string | null;\n firstName: string | null;\n lastName: string | null;\n mobile: string | null;\n mobileCodeIso3: string | null;\n mobileDigits: number | null;\n mobileCode: number | null;\n mobileTemplate: string | null;\n email: string | null;\n startDate: Date | null;\n endDate: Date | null;\n services: CreateAppointmentService[];\n notes: string | null;\n isRecurring: boolean;\n isCustomSchedule: boolean;\n scheduledSimultaneousServices: boolean;\n recurrenceWeekInterval: AppointmentRecurrenceInterval | null;\n recurredAppointmentsCount: number | null;\n totalPriceForRecurringAppointments: number | null;\n updateAllRecurringAppointments?: boolean | null;\n recurringAppointmentOrder?: number | null;\n isIgnoreScheduleBusy: boolean;\n customRecurrenceInterval: number | null;\n customRecurrenceMode: CustomRecurrenceMode | null;\n customRecurrenceWeekDays: WeekDaysFlags | null;\n\n constructor(x?: any) {\n if (x !== null && typeof x === \"object\") {\n this.id = x.id;\n this.number = x.number;\n this.userId = x.userId;\n this.user = x.user;\n this.customerId = x.customerId;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileDigits = x.mobileDigits;\n this.mobileCode = x.mobileCode;\n this.mobileTemplate = x.mobileTemplate;\n this.mobile = x.mobile;\n this.email = x.email;\n this.startDate = x.startDate;\n this.endDate = x.endDate;\n this.services = x.services;\n this.notes = x.notes;\n this.isRecurring = x.isRecurring;\n this.isCustomSchedule = x.isCustomSchedule;\n this.scheduledSimultaneousServices = x.scheduledSimultaneousServices;\n this.recurrenceWeekInterval = x.recurrenceWeekInterval;\n this.recurredAppointmentsCount = x.recurredAppointmentsCount;\n this.totalPriceForRecurringAppointments = x.totalPriceForRecurringAppointments;\n this.recurringAppointmentOrder = x.recurringAppointmentOrder;\n this.isIgnoreScheduleBusy = x.isIgnoreScheduleBusy;\n this.customRecurrenceInterval = x.customRecurrenceInterval;\n this.customRecurrenceMode = x.customRecurrenceMode;\n this.customRecurrenceWeekDays = x.customRecurrenceWeekDays;\n \n } else {\n this.id = null;\n this.number = null;\n this.userId = null;\n this.user = null;\n this.customerId = null;\n this.firstName = null;\n this.lastName = null;\n this.mobileCodeIso3 = null;\n this.mobileDigits = null;\n this.mobileCode = null;\n this.mobileTemplate = null;\n this.mobile = null;\n this.email = null;\n this.startDate = null;\n this.endDate = null;\n this.services = [];\n this.notes = null;\n this.isRecurring = false;\n this.isCustomSchedule = false;\n this.scheduledSimultaneousServices = false;\n this.recurrenceWeekInterval = null;\n this.recurredAppointmentsCount = null;\n this.totalPriceForRecurringAppointments = null;\n this.recurringAppointmentOrder = null;\n this.isIgnoreScheduleBusy = false;\n this.customRecurrenceInterval = null;\n this.customRecurrenceMode = null;\n this.customRecurrenceWeekDays = null;\n }\n }\n}\n","export class AppointmentBlocker {\n customerName: string | null;\n serviceName: string | null;\n workArea: string | null;\n startData: Date | null;\n appointmentDuration: number | null;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.customerName = x.customerName;\n this.serviceName = x.serviceName;\n this.workArea = x.workArea;\n this.startData = x.startData;\n this.appointmentDuration = x.appointmentDuration;\n } else {\n this.customerName = null;\n this.serviceName = null;\n this.workArea = null;\n this.startData = null;\n this.appointmentDuration = null;\n }\n }\n}\n","import {\n AppointmentModel,\n SchedulerDateTime,\n} from \"@devexpress/dx-react-scheduler\";\nimport { AppointmentCreatedBy } from \"./enums/appointment-created-by\";\nimport { AppointmentRecurrenceInterval } from \"./enums/appointment-recurrence-interval\";\nimport { AppointmentStatus } from \"./enums/appointment-status\";\nimport { AppointmentPaymentStatus } from \"./enums/appointment-payment-status\";\nimport {AppointmentServiceModel} from \"./appointment-service-model\";\nimport { CustomRecurrenceMode } from \"./enums/custom-recurrence-mode\";\nimport { WeekDaysFlags } from \"./enums/week-days-flags\";\n\nexport class AppointmentTooltipModel {\n appointmentId: string;\n paymentStatus: AppointmentPaymentStatus;\n paidAmount: number;\n customerId: string;\n customerEmail: string;\n customerMobile: string;\n customerMobileCodeIso3: string | null;\n customerMobileDigits: number | null;\n customerMobileCode: number | null;\n customerMobileTemplate: string | null;\n notes: string;\n isRecurring: boolean;\n totalRecurringApptPriceExcludingSelected: number;\n totalRecurringApptPrice: number;\n recurredAppointmentsIds: string[];\n recurringApptTotalToPaid: number;\n appointmentRecurrenceWeekInterval: AppointmentRecurrenceInterval | null;\n recurredAppointmentsCount: number | null;\n recurringAppointmentOrder: number | null;\n services: AppointmentServiceModel[];\n scheduledSimultaneousServices: boolean;\n customRecurrenceInterval: number | null;\n customRecurrenceMode: CustomRecurrenceMode | null;\n customRecurrenceWeekDays: WeekDaysFlags | null;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.appointmentId = x.appointmentId;\n this.paymentStatus = x.paymentStatus;\n this.paidAmount = x.paidAmount;\n this.customerId = x.customerId;\n this.customerEmail = x.customerEmail;\n this.customerMobile = x.customerMobile;\n this.customerMobileCodeIso3 = x.customerMobileCodeIso3;\n this.customerMobileDigits = x.mobileDigits;\n this.customerMobileCode = x.customerMobileCode;\n this.customerMobileTemplate = x.customerMobileTemplate;\n this.notes = x.notes;\n this.isRecurring = x.isRecurring;\n this.totalRecurringApptPriceExcludingSelected = x.totalRecurringApptPriceExcludingSelected;\n this.totalRecurringApptPrice = x.totalRecurringApptPrice;\n this.recurredAppointmentsIds = x.recurredAppointmentsIds;\n this.recurringApptTotalToPaid = x.recurringApptTotalToPaid;\n this.appointmentRecurrenceWeekInterval = x.appointmentRecurrenceWeekInterval;\n this.recurredAppointmentsCount = x.recurredAppointmentsCount;\n this.recurringAppointmentOrder = x.recurringAppointmentOrder;\n this.services = x.services;\n this.scheduledSimultaneousServices = x.scheduledSimultaneousServices;\n this.customRecurrenceInterval = x.customRecurrenceInterval;\n this.customRecurrenceMode = x.customRecurrenceMode;\n this.customRecurrenceWeekDays = x.customRecurrenceWeekDays;\n } else {\n this.appointmentId = \"\";\n this.paymentStatus = AppointmentPaymentStatus.Unpaid;\n this.paidAmount = 0.00;\n this.customerId = \"\";\n this.customerEmail = \"\";\n this.customerMobile = \"\";\n this.customerMobileCodeIso3 = null;\n this.customerMobileDigits = null;\n this.customerMobileCode = null;\n this.customerMobileTemplate = null;\n this.notes = \"\";\n this.isRecurring = false;\n this.totalRecurringApptPriceExcludingSelected = 0.00;\n this.totalRecurringApptPrice = 0.00;\n this.recurredAppointmentsIds = [];\n this.recurringApptTotalToPaid = 0.00;\n this.appointmentRecurrenceWeekInterval = null;\n this.recurredAppointmentsCount = null;\n this.recurringAppointmentOrder = null;\n this.services = [];\n this.customRecurrenceInterval = null;\n this.scheduledSimultaneousServices = false;\n this.customRecurrenceMode = null;\n this.customRecurrenceWeekDays = null;\n }\n }\n}\n","export enum ConversationMessageType {\n Text = 1,\n Image,\n Pdf,\n Video,\n Voice,\n Document,\n Location\n}","import { ApiClient } from \"./api-client\";\nimport { Appointment } from \"../models/appointment\";\nimport { AppointmentServiceModel } from \"./../models/appointment-service-model\";\nimport { AppointmentStatusModel } from \"./../models/appointment-status-model\";\nimport { AppointmentAvailableHours } from \"./../models/appointment-available-hours\";\nimport { CreateAppointmentService } from \"../models/create-appointment-service\";\nimport { CreateAppointmentModel } from \"../models/create-appointment-model\";\nimport { CreateFollowUpModel } from \"../models/create-follow-up-model\";\nimport { AppointmentBlocker } from \"../models/appointment-blocker\";\nimport {AppointmentTooltipModel} from \"../models/appointment-tooltip-model\";\nimport { AppointmentStatus } from \"../models/enums/appointment-status\";\n\nexport class AppointmentService {\n private static baseUrl: string = \"/appointment\";\n\n private static isoDate(date: Date): string {\n const year = date.toLocaleString(\"en-US\", {\n year: \"numeric\",\n });\n const month = date.toLocaleString(\"en-US\", {\n month: \"2-digit\",\n });\n const day = date.toLocaleString(\"en-US\", {\n day: \"2-digit\",\n });\n\n return `${year}-${month}-${day}`;\n }\n\n private static handleTime(date: Date): string {\n const time = date.toLocaleString(\"en-US\", {\n hourCycle: \"h23\",\n hour: \"2-digit\",\n minute: \"2-digit\",\n second: \"2-digit\"\n });\n\n return `${this.isoDate(date)}T${time}`;\n }\n\n static create(appointment: CreateAppointmentModel): Promise {\n return ApiClient.post(`${this.baseUrl}/create`, {\n ...appointment,\n startDate: this.handleTime(appointment.startDate as Date),\n }).then((data) => {\n return {\n appointment: data.appointment !== null ? new Appointment(data.appointment) : null,\n appointmentBlocker: data.appointmentBlocker !== null ? new AppointmentBlocker(data.appointmentBlocker) : null,\n isScheduleBusy: data.isScheduleBusy,\n appointmentScheduleBusyReason: data.appointmentScheduleBusyReason\n };\n });\n }\n\n static remove(appointmentId: string, allRecurringAppointments: boolean = false): Promise {\n\n let endpointUrl = `${this.baseUrl}/delete?appointmentId=${appointmentId}`\n \n if (allRecurringAppointments && allRecurringAppointments !== null) \n endpointUrl += `&allRecurringAppointments=${allRecurringAppointments}`;\n\n return ApiClient.remove(endpointUrl).then((data) => true);\n }\n\n static updateStatus(appointment: AppointmentStatusModel): Promise {\n return ApiClient.put(`${this.baseUrl}/updatestatus`, appointment).then(\n (data) => true\n );\n }\n \n \n static updateNotes(serviceId: string, appointmentId: string, notes: string): Promise {\n\n const dataNotes = {\n serviceId,\n appointmentId,\n notes\n }\n\n return ApiClient.put(`${this.baseUrl}/updatenotes`, dataNotes).then(\n (data) => true\n );\n }\n\n static update(appointment: CreateAppointmentModel): Promise {\n return ApiClient.put(`${this.baseUrl}/update`, {\n ...appointment,\n startDate: this.handleTime(appointment.startDate as Date),\n }).then((data) => {\n return {\n appointment: data.appointment !== null ? new Appointment(data.appointment) : null,\n appointmentBlocker: data.appointmentBlocker !== null ? new AppointmentBlocker(data.appointmentBlocker) : null,\n isScheduleBusy: data.isScheduleBusy,\n appointmentScheduleBusyReason: data.appointmentScheduleBusyReason\n };\n });\n }\n \n static updateTime(appointmentId: string, startDate: Date, allAppointments: boolean): Promise {\n return ApiClient.put(`${this.baseUrl}/updateTime`, {\n id: appointmentId,\n startDate: this.handleTime(startDate),\n allAppointments: allAppointments\n }).then((data) => {\n return {\n isUpdated: data.isUpdated,\n isScheduleBusy: data.isScheduleBusy,\n isUpdatable: data.isUpdatable,\n hasSimultaneousAppointments: data.hasSimultaneousAppointments\n };\n });\n }\n\n static get(appointmentId: string): Promise {\n return ApiClient.get(\n `${this.baseUrl}/getbyid?AppointmentId=${appointmentId}`\n ).then((data) => {\n return new CreateAppointmentModel(data.appointment);\n });\n }\n\n static getAppointmentCalendarById(appointmentId: string, userIds: string[] | undefined, statuses: AppointmentStatus[] | undefined): Promise {\n const formData = new FormData();\n formData.append(\"AppointmentId\", appointmentId);\n if (userIds) {\n userIds.forEach(userId => {\n formData.append(\"UserIds\", userId);\n })\n }\n if (statuses) {\n statuses.forEach(status => {\n formData.append(\"Statuses\", String(status));\n })\n }\n \n return ApiClient.post(\n `${this.baseUrl}/getappointmentcalendarbyid`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }\n }).then((data) => data!=null ? new Appointment(data.appointment) : null);\n }\n\n static getByCustomer(customerId: string): Promise {\n return ApiClient.get(\n `${this.baseUrl}/getbycustomer?customerId=${customerId}`\n ).then((data) => data.appointments.map((a: any) => new Appointment(a)));\n }\n\n static getByAccount(dateFrom: Date, dateTo: Date, userIds: string[] | undefined, statuses: AppointmentStatus[] | undefined): Promise {\n const formData = new FormData();\n formData.append(\"DateFrom\", dateFrom.toISOString().replace(\"Z\", \"\"));\n formData.append(\"DateTo\", dateTo.toISOString().replace(\"Z\", \"\"));\n if (userIds) {\n userIds.forEach(userId => {\n formData.append(\"UserIds\", userId);\n })\n }\n if (statuses) {\n statuses.forEach(status => {\n formData.append(\"Statuses\", String(status));\n })\n }\n\n return ApiClient.post(\n `${this.baseUrl}/getbyaccount`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }\n }).then((data) => data.appointments.map((a: any) => new Appointment(a)));\n }\n\n static getSplitByServicesAppointmentsByAccount(dateFrom: Date, dateTo: Date, userIds: string[] | undefined, statuses: AppointmentStatus[] | undefined): Promise {\n const formData = new FormData();\n formData.append(\"DateFrom\", dateFrom.toISOString().replace(\"Z\", \"\"));\n formData.append(\"DateTo\", dateTo.toISOString().replace(\"Z\", \"\"));\n if (userIds) {\n userIds.forEach(userId => {\n formData.append(\"UserIds\", userId);\n })\n }\n if (statuses) {\n statuses.forEach(status => {\n formData.append(\"Statuses\", String(status));\n })\n }\n \n return ApiClient.post(\n `${this.baseUrl}/getsplitbyservicesappointmentsbyaccount`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }\n }).then((data) => data.appointments.map((a: any) => new Appointment(a)));\n }\n \n static getSplitByEstablishments(dateFrom: Date, dateTo: Date, establishmentIds: string[] | undefined, userIds: string[] | undefined, statuses: AppointmentStatus[] | undefined): Appointment[] | PromiseLike {\n const formData = new FormData();\n formData.append(\"DateFrom\", dateFrom.toISOString().replace(\"Z\", \"\"));\n formData.append(\"DateTo\", dateTo.toISOString().replace(\"Z\", \"\"));\n if (establishmentIds) {\n establishmentIds.forEach(establishmentId => {\n formData.append(\"EstablishmentIds\", establishmentId);\n })\n }\n if (userIds) {\n userIds.forEach(userId => {\n formData.append(\"UserIds\", userId);\n })\n }\n if (statuses) {\n statuses.forEach(status => {\n formData.append(\"Statuses\", String(status));\n })\n }\n \n return ApiClient.post(\n `${this.baseUrl}/getsplitbyestablishments`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }\n }).then((data) => data.appointments.map((a: any) => new Appointment(a)));\n }\n\n static getSplitByServicesAppointmentCalendarById(appointmentId: string, userIds: string[] | undefined, statuses: AppointmentStatus[] | undefined): Promise {\n const formData = new FormData();\n formData.append(\"AppointmentId\", appointmentId);\n if (userIds) {\n userIds.forEach(userId => {\n formData.append(\"UserIds\", userId);\n })\n }\n if (statuses) {\n statuses.forEach(status => {\n formData.append(\"Statuses\", String(status));\n })\n }\n \n return ApiClient.post(\n `${this.baseUrl}/getsplitbyservicesappointmentcalendarbyid`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }\n }).then((data) => data.appointments.map((a: any) => new Appointment(a)));\n }\n\n static getAppointmentTooltip(\n appointmentId: string\n ): Promise {\n return ApiClient.get(\n `${this.baseUrl}/gettooltip?appointmentId=${appointmentId}`\n ).then((data) =>\n new AppointmentTooltipModel(data.data)\n );\n }\n\n static getServices(\n appointmentId: string\n ): Promise {\n return ApiClient.get(\n `${this.baseUrl}/getservices?appointmentId=${appointmentId}`\n ).then((data) =>\n data.services.map((a: any) => new AppointmentServiceModel(a))\n );\n }\n\n static getAvailableHours(\n startDate: Date,\n services: CreateAppointmentService[],\n scheduledSimultaneousServices: boolean,\n appointmentId?: string,\n recurrenceWeekInterval?: number | null,\n recurredAppointmentsCount?: number | null,\n customRecurrenceMode?: number | null,\n customRecurrenceInterval?: number | null,\n customRecurrenceWeekDays?: number | null\n ): Promise {\n const date = new Date(startDate);\n date.setHours(12, 0, 0, 0);\n let endpointUrl = `${\n this.baseUrl\n }/getavailablehours?startDate=${this.isoDate(date)}`;\n if (appointmentId) {\n endpointUrl += `&appointmentId=${appointmentId}`;\n }\n \n endpointUrl += `&scheduledSimultaneousServices=${scheduledSimultaneousServices}`;\n\n if (recurrenceWeekInterval && recurrenceWeekInterval !== null) \n endpointUrl += `&recurrenceWeekInterval=${recurrenceWeekInterval}`;\n\n if (recurredAppointmentsCount && recurredAppointmentsCount !== null) \n endpointUrl += `&recurredAppointmentsCount=${recurredAppointmentsCount}`;\n \n if (customRecurrenceMode !== null && customRecurrenceMode !== undefined) {\n endpointUrl += `&customRecurrenceMode=${customRecurrenceMode}`;\n }\n \n if (customRecurrenceInterval && customRecurrenceInterval !== null) \n endpointUrl += `&customRecurrenceInterval=${customRecurrenceInterval}`;\n\n if (customRecurrenceWeekDays && customRecurrenceWeekDays !== null) \n endpointUrl += `&customRecurrenceWeekDays=${customRecurrenceWeekDays}`;\n\n for (let service of services) {\n endpointUrl += `&serviceId=${service.serviceId}`;\n endpointUrl += `&userId=${service.userId}`;\n endpointUrl += `&estimatedDuration=${service.estimatedDuration}`;\n endpointUrl += `&workAreaId=${service.workAreaId ?? \"\"}`;\n }\n return ApiClient.get(endpointUrl).then((data) => {\n return new AppointmentAvailableHours(data);\n });\n }\n\n static getAvailableDays(): Promise {\n return ApiClient.get(`${this.baseUrl}/getavailabledays`).then(\n (data) => data.availableDays\n );\n }\n\n \n static createFollowUp(followup: CreateFollowUpModel): Promise {\n\n const date = this.handleTime(followup.scheduled as Date);\n\n const followUpDate = {\n ...followup,\n scheduled: date,\n };\n\n return ApiClient.post(`${this.baseUrl}/createfollowup`, followUpDate).then((data) => {\n return new Appointment(data.appointment);\n });\n }\n\n}\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nexport default function CustomerRequiresQuoteNotificationIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n \n \n \n );\n}","import React, { useState } from \"react\";\nimport { useHistory } from 'react-router-dom';\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { NotificationType } from \"../../../../models/enums/notification-type\";\nimport {\n ArrowDropDownIcon,\n CalendarNotificationIcon,\n CaptionDocumentMediaIcon,\n CaptionImageMediaIcon,\n DollarSignNotificationIcon,\n ScreenNotificationIcon,\n VideoCameraEmptyIcon,\n WhatsAppMicrophoneIcon,\n WhatsAppNotificationIcon\n} from \"../../../../assets/icons\";\nimport { Url } from \"../../../../constants/url\";\nimport { INotificationItemProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport { schedulerActions } from \"../../../../redux/scheduler-slice\";\nimport { AppointmentService } from \"../../../../api/appointment-service\";\nimport CustomerRequiresQuoteNotificationIcon from \"../../../../assets/icons/CustomerRequiresQuoteNotificationIcon\";\nimport { selectUserInfo } from \"../../../../redux/store\";\nimport { ConversationMessageType } from \"../../../../models/enums/conversation-message-type\";\n\n\nexport default function NotificationItem(props: INotificationItemProps) {\n\n interface INotificationParams {\n type: NotificationType;\n icon: any;\n headerText: string;\n actionType: string;\n hasServices: boolean;\n hasDropDown: boolean;\n hasFromToDateTime: boolean;\n onClick: () => void;\n }\n\n const { notification, markAsRead } = props;\n const { id, type, senderId, senderMobile, sender, appointmentId, text,\n fromStartDate, fromEndDate, toStartDate, toEndDate,\n date, read, messageCount, whatsAppInboundMessageType } = notification;\n\n const [isExpanded, setIsExpanded] = useState(false);\n\n const dispatch = useAppDispatch();\n const { setCurrentDate, setSelectedUsers } = schedulerActions;\n const selectedUsers = useAppSelector((state) => state.scheduler.selectedUsers);\n const userInfo = useAppSelector(selectUserInfo);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const classes = useStyles();\n const history = useHistory();\n const { t } = useTranslation(\"general\");\n\n const WhatsAppIcon = \n const CustomerRequiresQuoteIcon = \n const CalendarIcon = \n const ScreenIcon = \n const DollarIcon = \n const ArrowIcon = \n\n const textLengthThreshold = 40;\n const textWithIconLengthThreshold = 36;\n\n function markRead() {\n if (!read) {\n markAsRead(id);\n }\n }\n\n async function redirectToAppointmentPage() {\n if (appointmentId === null) return;\n const appointment = await AppointmentService.get(appointmentId);\n const appointmentDate = new Date(appointment.startDate ?? new Date());\n if (selectedUsers && !appointment.services?.map(s => s.userId).some(u => u && selectedUsers.includes(u)))\n dispatch(setSelectedUsers([]));\n dispatch(setCurrentDate(appointmentDate));\n history.push(Url.Appointments.Main, { redirectedAppointmentDate: appointmentDate, redirectedAppointmentId: appointmentId });\n }\n\n function markReadAndRedirectToWhatsApp() {\n if (!userInfo.hasAccessToWhatsAppConversationsAndNotifications)\n return;\n markRead();\n history.push(Url.WhatsApp.Main + \"/\" + senderMobile);\n }\n\n function markReadAndRedirectToAppointments() {\n markRead();\n redirectToAppointmentPage();\n }\n\n const getParametersByNotificationType = (type: NotificationType): INotificationParams => {\n switch (type) {\n case NotificationType.UnreadMessages:\n return {\n type: type,\n icon: WhatsAppIcon,\n headerText: t(\"Unread messages\"),\n actionType: \"\",\n hasServices: false,\n hasDropDown: false,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToWhatsApp\n }\n case NotificationType.CustomerRequiresAttention:\n return {\n type: type,\n icon: WhatsAppIcon,\n headerText: t(\"Customer requires attention\"),\n actionType: \"\",\n hasServices: false,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToWhatsApp\n }\n case NotificationType.NewAppointment:\n return {\n type: type,\n icon: ScreenIcon,\n headerText: t(\"New appointment\"),\n actionType: t(\"has made an appointment\"),\n hasServices: true,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToAppointments\n }\n case NotificationType.ModifiedAppointment:\n return {\n type: type,\n icon: CalendarIcon,\n headerText: t(\"Modified appointment\"),\n actionType: t(\"has modified the appointment\"),\n hasServices: true,\n hasDropDown: true,\n hasFromToDateTime: true,\n onClick: markReadAndRedirectToAppointments\n }\n case NotificationType.AppointmentConfirmedByCustomer:\n return {\n type: type,\n icon: CalendarIcon,\n headerText: t(\"Appointment confirmed by customer\"),\n actionType: t(\"has confirmed an appointment\"),\n hasServices: true,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToAppointments\n }\n case NotificationType.ProofOfPayment:\n return {\n type: type,\n icon: DollarIcon,\n headerText: t(\"Proof of payment received\"),\n actionType: t(\"has made a payment\"),\n hasServices: true,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToWhatsApp\n }\n case NotificationType.AppointmentModifiedByCustomer:\n return {\n type: type,\n icon: ScreenIcon,\n headerText: t(\"Appointment modified\"),\n actionType: t(\"has modified an appointment\"),\n hasServices: true,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToAppointments\n }\n case NotificationType.AppointmentCancelledByCustomer:\n return {\n type: type,\n icon: ScreenIcon,\n headerText: t(\"Appointment cancelled\"),\n actionType: t(\"has cancelled an appointment\"),\n hasServices: true,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToAppointments\n }\n case NotificationType.CustomerRequiresQuote:\n return {\n type: type,\n icon: CustomerRequiresQuoteIcon,\n headerText: messageCount == 1 ? t(\"Customer requests estimation\") : t(\"Estimation pending to respond\"),\n actionType: \"\",\n hasServices: false,\n hasDropDown: true,\n hasFromToDateTime: false,\n onClick: markReadAndRedirectToWhatsApp\n }\n default:\n return {\n type: type,\n icon: \"\",\n headerText: \"\",\n actionType: \"\",\n hasServices: false,\n hasDropDown: false,\n hasFromToDateTime: false,\n onClick: () => { }\n }\n }\n }\n\n const getCaptionImage = (type: ConversationMessageType | null) => {\n switch (type) {\n case ConversationMessageType.Image:\n return ;\n case ConversationMessageType.Video:\n return ;\n case ConversationMessageType.Voice:\n return ;\n case ConversationMessageType.Document:\n case ConversationMessageType.Pdf:\n return ;\n default:\n return <>;\n }\n }\n\n const getText = (type: NotificationType): string => {\n let notificationText = text;\n if (whatsAppInboundMessageType) {\n if (whatsAppInboundMessageType === ConversationMessageType.Video) {\n return t(\"Video\")\n }\n if (whatsAppInboundMessageType === ConversationMessageType.Voice) {\n return t(\"Voice message\")\n }\n else if (whatsAppInboundMessageType === ConversationMessageType.Image) {\n if (notificationText === null) return t(\"Photo\")\n else return tryTrimText(notificationText, textWithIconLengthThreshold);\n }\n if (whatsAppInboundMessageType === ConversationMessageType.Pdf || whatsAppInboundMessageType === ConversationMessageType.Document) {\n if (notificationText === null) return t(\"Document\")\n else return tryTrimText(notificationText, textWithIconLengthThreshold);\n }\n // TODO 1.10.0.1\n }\n if (notificationText === null) return \"\";\n if (type === NotificationType.ProofOfPayment) return t(notificationText);\n return tryTrimText(notificationText, textLengthThreshold);\n }\n\n const tryTrimText = (text: string | undefined, maxTextLength: number): string => {\n if (!text) return \"\";\n if (isExpanded) return text;\n if (text.length <= maxTextLength) return text;\n return text.substring(0, maxTextLength - 5) + \"...\";\n }\n\n const notificationParameters = getParametersByNotificationType(notification.type);\n\n const formatSenderWithPlusSign = (sender: string) => {\n if (!isNaN(+sender)) {\n sender = \"+\" + sender;\n }\n return sender;\n }\n\n function handleExpanderClick(e: any) {\n e.stopPropagation();\n setIsExpanded(!isExpanded);\n }\n \n const formatDate = (startDate: Date, endDate: Date): string => {\n const start = new Date(startDate);\n const end = new Date(endDate);\n \n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n \n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n \n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n \n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n \n const timeDifference = (today: Date, endDate: Date): string => {\n const hours = parseInt(\n `${\n (Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60 * 60)) % 24\n }`\n );\n const minutes = parseInt(\n `${(Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60)) % 60}`\n );\n if (hours > 0 && minutes < 1) {\n return `${hours}hr`;\n } else if (hours < 1 && minutes > 0) {\n return `${minutes}min`;\n } else {\n return `${hours}hr ${minutes}min`;\n }\n };\n \n return (\n
\n {!read &&
}\n
\n
\n
\n {notificationParameters.icon}\n
\n {notificationParameters.headerText}\n
\n
\n {formatDate}\n
\n
\n\n
\n {\n notificationParameters.hasServices\n ? {formatSenderWithPlusSign(sender)} {notificationParameters.actionType}\n : {formatSenderWithPlusSign(sender)}\n }\n
\n
\n
\n {getCaptionImage(notification.whatsAppInboundMessageType)}{getText(notification.type)}\n {notificationParameters.hasFromToDateTime && isExpanded &&\n <>\n \n {t(\"From\")}: \n {`${formatDate(\n fromStartDate!,\n fromEndDate!\n )} (${timeDifference(\n fromStartDate!,\n fromEndDate!\n )})`}\n \n \n {t(\"ToA\")}: \n {`${formatDate(\n toStartDate!,\n toEndDate!\n )} (${timeDifference(\n toStartDate!,\n toEndDate!\n )})`}\n \n \n }\n
\n {messageCount > 0 && !read &&
\n {messageCount}\n
}\n {\n notificationParameters.hasDropDown &&\n (notificationParameters.hasFromToDateTime ||\n (text?.length ?? false) &&\n (text?.length ?? 0) >\n (whatsAppInboundMessageType && whatsAppInboundMessageType !== ConversationMessageType.Text\n ? textLengthThreshold\n : textWithIconLengthThreshold)) &&\n \n \n {ArrowIcon}\n
\n
\n }\n \n \n );\n}","import { ConversationMessageType } from \"./enums/conversation-message-type\";\nimport { NotificationType } from \"./enums/notification-type\";\n\nexport default class NotificationEntity {\n id: string;\n appointmentId: string | null;\n type: NotificationType;\n senderId: string;\n senderMobile: string;\n sender: string;\n text: string | null;\n fromStartDate: Date | null;\n fromEndDate: Date | null;\n toStartDate: Date | null;\n toEndDate: Date | null;\n date: string;\n read: boolean;\n wasShown: boolean;\n messageCount: number;\n whatsAppInboundMessageType: ConversationMessageType | null;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.appointmentId = x.appointmentId;\n this.type = x.type;\n this.senderId = x.senderId;\n this.senderMobile = x.senderMobile;\n this.sender = x.sender;\n this.text = x.text;\n this.fromStartDate = new Date(x.fromStartDate);\n this.fromEndDate = new Date(x.fromEndDate);\n this.toStartDate = new Date(x.toStartDate);\n this.toEndDate = new Date(x.toEndDate);\n this.date = x.date;\n this.read = x.read;\n this.wasShown = x.wasShown;\n this.messageCount = x.messageCount;\n this.whatsAppInboundMessageType = x.whatsAppInboundMessageType;\n } else {\n this.id = \"\";\n this.appointmentId = null;\n this.type = 0;\n this.senderId = \"\";\n this.senderMobile = \"\";\n this.sender = \"\";\n this.text = \"\";\n this.fromStartDate = null;\n this.fromEndDate = null;\n this.toStartDate = null;\n this.toEndDate = null;\n this.date = \"\";\n this.read = true;\n this.wasShown = true;\n this.messageCount = 0;\n this.whatsAppInboundMessageType = null;\n }\n }\n}","import { ApiClient } from \"./api-client\"\nimport NotificationEntity from \"../models/notification-entity\";\nimport { JobPosition } from \"../models/job-position\";\nimport ConversationsCounterModel from \"../models/conversations-counter-model\";\nimport { Response } from \"../models/response\";\nimport { CustomerSearch } from \"../models/customer-search\";\n\nexport class NotificationsService {\n private static baseUrl = \"/notifications\";\n private static whatsAppUrl = \"/whatsApp/api\";\n\n static getNotifications(): Promise {\n return ApiClient.get(`${this.baseUrl}/getlist`).then((data) =>\n data.map((n: any) => new NotificationEntity(n)));\n }\n\n static markNotificationsAsWasShown(): Promise {\n return ApiClient.post(`${this.baseUrl}/markAsWasShown`);\n }\n\n static markNotificationAsRead(id: string) : Promise {\n return ApiClient.post(`${this.baseUrl}/markAsRead`, { id })\n .catch(err => console.error(err.response));\n }\n \n static getAvailableConversationsCount() : Promise {\n return ApiClient.get(`${this.whatsAppUrl}/account/getAvailableConversationsCount`)\n .catch(err => console.error(err.response));\n }\n}","import ConversationCounter from \"./interfaces/conversation-counter-model\"\n\nexport default class ConversationsCounterModel implements ConversationCounter {\n availableConversationsCount: number;\n monthlyConversationsLimit: number;\n spentMarketing: number;\n spentUtility: number;\n hasReachedReferralThreshold: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.monthlyConversationsLimit = x.monthlyConversationsLimit;\n this.hasReachedReferralThreshold = x.hasReachedReferralThreshold;\n this.spentMarketing = x.spentMarketing;\n this.spentUtility = x.spentUtility;\n this.availableConversationsCount = x.availableConversationsCount;\n } else {\n this.monthlyConversationsLimit = 1000;\n this.hasReachedReferralThreshold = false;\n this.spentMarketing = 0;\n this.spentUtility = 0;\n this.availableConversationsCount = 0;\n }\n }\n}","import { NotificationType } from \"../models/enums/notification-type\";\n\nexport const StackableNotificationTypes = [\n NotificationType.UnreadMessages,\n NotificationType.CustomerRequiresAttention,\n NotificationType.CustomerRequiresQuote\n];","import React, { useEffect, useState } from \"react\";\n\nimport { navbarActions } from '../../../../redux/navbar-slice'\n\nimport NotificationsIcon from \"@material-ui/icons/Notifications\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport { ClickAwayListener, Menu } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport NotificationHeader from \"../NotificationHeader\";\nimport NotificationFooter from \"../NotificationFooter\";\nimport NotificationItem from \"../NotificationItem\";\nimport NotificationEntity from \"../../../../models/notification-entity\";\nimport { NotificationsService } from \"../../../../api/notifications-service\";\nimport ConversationsCounterModel from \"../../../../models/conversations-counter-model\";\nimport { NotificationBlockProps } from \"./props\";\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport { selectUserInfo } from \"../../../../redux/store\";\nimport { NotificationType } from \"../../../../models/enums/notification-type\";\nimport { StackableNotificationTypes } from \"../../../../constants/business\";\n\nexport default function NotificationBlock(props: NotificationBlockProps) {\n\n const { commonHubConnection } = props;\n\n const dispatch = useAppDispatch();\n const userInfo = useAppSelector(selectUserInfo);\n const [anchorElement, setAnchorElement] = useState(null);\n const [notifications, setNotifications] = useState([]);\n const [conversationsCounterModel, setConversationsCounterModel] = useState(new ConversationsCounterModel());\n const isMenuOpen = Boolean(anchorElement)\n\n const classes = useStyles();\n\n const handleMenuOpen = async (event: any) => {\n setAnchorElement(event.currentTarget);\n fetchConversationCounter();\n\n if (notifications.some(n => !n.wasShown)) {\n let shownStatusIsUpdated = await NotificationsService.markNotificationsAsWasShown();\n if (shownStatusIsUpdated) {\n const newNotifications = notifications.map(n => {\n n.wasShown = true\n return n;\n });\n setNotifications(newNotifications);\n }\n }\n }\n\n const handleMenuClose = () => {\n setAnchorElement(null);\n }\n\n const unshownNotifications = notifications.filter(n => !n.wasShown);\n\n async function fetchNotifications() {\n const receivedNotifications = await NotificationsService.getNotifications();\n setNotifications(receivedNotifications ?? []);\n }\n\n async function fetchConversationCounter() {\n const remainingConversationsModel = await NotificationsService.getAvailableConversationsCount();\n setConversationsCounterModel(remainingConversationsModel ?? new ConversationsCounterModel());\n dispatch(navbarActions.setConversationCounter(remainingConversationsModel));\n }\n\n async function markNotificationAsRead(notification: string) {\n await NotificationsService.markNotificationAsRead(notification);\n }\n\n function updateNotification(notificationIds: string[], notification: NotificationEntity): NotificationEntity {\n if (Boolean(notificationIds.find(x => x === notification.id))) {\n return new NotificationEntity({ ...notification, read: true })\n }\n return notification;\n }\n\n function handleNotificationReading(notificationId: string) {\n handleNotificationsReading([notificationId]);\n }\n\n function handleNotificationsReading(notificationIds: string[]) {\n const newNotifications = notifications.map(x => updateNotification(notificationIds, x));\n setNotifications(newNotifications);\n }\n\n function removeWhatsAppNotificationsFilter(n: NotificationEntity) {\n if (userInfo.hasAccessToWhatsAppConversationsAndNotifications)\n return n;\n\n return n.type !== NotificationType.CustomerRequiresAttention &&\n n.type !== NotificationType.CustomerRequiresQuote &&\n n.type !== NotificationType.ProofOfPayment &&\n n.type !== NotificationType.UnreadMessages;\n }\n\n useEffect(() => {\n fetchNotifications()\n fetchConversationCounter();\n }, [])\n\n //unsubscribe first so subscriptions does not duplicate\n commonHubConnection?.off(\"receiveNotification\")\n commonHubConnection?.off(\"markNotificationRead\")\n\n commonHubConnection?.on(\"receiveNotification\", (receivedNotification) => receiveNotification(new NotificationEntity(receivedNotification)))\n commonHubConnection?.on(\"markNotificationRead\", (notificationId) => handleNotificationReading(notificationId))\n\n const receiveNotification = (receivedNotification: NotificationEntity) => {\n var isStackable = StackableNotificationTypes.some(t => t === receivedNotification.type);\n\n if (notifications.some(n => n.id === receivedNotification.id) && !isStackable)\n return;\n\n const updatedNotifications = [...notifications];\n\n //Removing stackable notification before adding the updated one at the beginning \n if (isStackable) {\n const notificationToFloatUpIndex = updatedNotifications.findIndex(n => n.id === receivedNotification.id);\n updatedNotifications.splice(notificationToFloatUpIndex, 1);\n }\n\n updatedNotifications.unshift(receivedNotification);\n setNotifications(updatedNotifications);\n };\n\n return (\n
\n \n \n {unshownNotifications.length > 0 &&\n
{unshownNotifications.length > 9 ? \"9+\" : unshownNotifications.length}
}\n \n\n \n \n
\n \n {notifications\n .filter(removeWhatsAppNotificationsFilter)\n .map(not =>\n \n )}\n \n
\n
\n \n
\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n message: {\n height: 32,\n background: \"#fff4d4\",\n textAlign: \"center\",\n paddingTop: 5,\n position: \"fixed\",\n width: \"100%\",\n zIndex: 9\n },\n messageBack: {\n height: 32,\n background: \"rgba(255, 198, 38, 0.2)\",\n textAlign: \"center\",\n paddingTop: 5,\n },\n messageIcon: {\n color: \"#B49A48\", \n display: \"inline-block\",\n marginRight: 10\n },\n messageLabel: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n alignItems: \"center\",\n color: \"#B49A48\",\n display: \"inline-block\"\n }\n})\n);\n\nexport default useStyles;","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { InfoCircleIcon } from \"../../../assets/icons\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport useStyles from \"./css\";\n\nconst AccountOverdueMessage = () => {\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n\n const isAccountOverdue = useAppSelector(state => state.applicationInterface.isAccountOverdue);\n\n return (<>\n {\n !isAccountOverdue ? <> : <>\n
\n
\n
\n
\n \n
\n
\n {t(\"Your account will be suspended for non-payment. For more information, contact your Account Executive.\")}\n
\n
\n }\n);\n};\n\nexport default AccountOverdueMessage;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n iconButton: {\n width: 40,\n height: 40,\n backgroundColor: \"#F6F6F6\",\n \"&:hover\": {\n color: \"#fff\",\n backgroundColor: theme.colors.clearGreen,\n },\n },\n })\n);\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport IconButton from \"@material-ui/core/IconButton\";\n\nimport useStyles from \"./css\";\nimport { CashRegisterIconProps } from \"./props\";\nimport { MoneyIcon } from \"../../../../assets/icons\";\n\n\nexport default function CashRegisterIcon(props: CashRegisterIconProps) {\n\n const { isActive, onClick } = props;\n \n const [isHovered, setIsHovered] = useState(false);\n \n const classes = useStyles();\n \n return (\n
\n setIsHovered(true)}\n onMouseLeave={() => setIsHovered(false)}\n >\n \n \n
\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n popover: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"flex-start\",\n \n width: 400,\n height: 267,\n \n marginTop: -5,\n padding: 24,\n\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: 8,\n boxShadow: theme.shadows[5],\n },\n header: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"flex-start\",\n justifyContent: \"space-between\",\n \n width: 352\n },\n headerDate: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n \n height: 40\n },\n closeIcon: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 16,\n height: 16,\n\n cursor: \"pointer\",\n color: theme.colors.grey5,\n },\n divider: {\n width: 352,\n height: 0,\n \n opacity: 0.5,\n border: \"1px solid\",\n borderColor: theme.colors.grey2\n },\n inputWithLabel: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n \n marginTop: 16,\n },\n controlLabel: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n dot: {\n ...theme.typography.buttons,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n inputLabelTooltip: {\n display: \"inline-flex\",\n marginLeft: 5\n },\n submitButton: {\n marginTop: 60,\n },\n noPermissionsText: {\n width: 352,\n height: 32,\n\n marginTop: 60,\n \n ...theme.typography.txtBody2,\n color: theme.colors.clearRed,\n fontWeight: 700\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number | string, showCounter?: boolean) =>\n makeStyles((theme) => ({\n input: {\n backgroundColor: theme.colors.grey1,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: width || 370,\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n width: showCounter? \"90%\" : \"99%\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n counter: {\n position: \"absolute\",\n bottom: -12,\n right: 7,\n fontSize: 12,\n color: \"#B5B9C1\",\n padding: \"5px\",\n },\n container: {\n position: \"relative\",\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: width || 370,\n },\n inputDisabled: {\n color: \"#676767\",\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n },\n }));\n\nexport default useStyles;\n","export default function useCurrencyValueTemplate(valueTemplate?: string) {\n\n const valuePlaceholder = \"{0}\";\n const template = valueTemplate ?? valuePlaceholder;\n \n function templatedValue(value: number) {\n const stringValue = value.toFixed(2);\n const valueWithCommas = stringValue.replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n return template.replace(valuePlaceholder, valueWithCommas);\n }\n \n return templatedValue;\n}","import React, { useEffect, useState } from \"react\";\n\nimport InputBase from \"@material-ui/core/InputBase\";\n\nimport useStyles from \"../Input/css\";\nimport { InputCurrencyProps } from \"./props\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\n\n\nexport default function InputCurrency(props: InputCurrencyProps) {\n \n const { id, value, setValue, valueTemplate, placeholder, name, isValid, width, inputClass, onChange, onBlur, disabled, readOnly, onClick, maxLength, maxValue, autoFocus, isZeroAllowed } = props;\n \n const maxDigitsLength = maxLength ?? 10;\n const maxDecimals = 2;\n \n const classes = useStyles(width)();\n\n const templatedValue = useCurrencyValueTemplate(valueTemplate);\n \n const [displayValue, setDisplayValue] = useState(\"\");\n\n const [displayPlaceholder, setDisplayPlaceholder] = useState(placeholder || \"0.00\");\n\n useEffect(() => {\n\n setDisplayPlaceholder(placeholder || templatedValue(0.00));\n\n if (value !== null && value >= 0) {\n let parsedValue = parseFloat(value.toString());\n setValue(parsedValue);\n setDisplayValue(numberWithCommas(templatedValue(parsedValue)));\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [value, valueTemplate])\n\n\n const isError = (): boolean => {\n if (value && +value === 0 && !isZeroAllowed) return true;\n \n if (isValid === undefined) {\n return displayValue === \"\";\n }\n\n if (!isValid) {\n return false;\n }\n\n return !isValid();\n };\n\n const handleOnChange = (event: any) => {\n event.preventDefault();\n\n if (Number.isNaN(+event.target.value)) return;\n\n const value = event.target.value+\"\";\n const actualValue = value.replace(\",\", \".\").replace(/[^\\d.]/g, \"\");\n\n // verify decimals\n const pointIndex = value.indexOf(\".\");\n const hasDecimals = pointIndex>-1;\n\n if (hasDecimals) {\n if ((value.length-pointIndex-1) > maxDecimals) return;\n }\n else {\n if (value.length > maxDigitsLength) return;\n }\n\n if (maxValue) {\n const value = +event.target.value;\n if (value > maxValue) return;\n }\n\n setDisplayValue((actualValue)+\"\");\n };\n\n const handleOnClick = (event: any) => {\n if (onClick) {\n onClick(event);\n }\n };\n\n const handleOnFocus = (event: any) => {\n let newDisplay: any;\n if ((value === 0 || Number.isNaN(value)) && !Number.isNaN(+event.target.value))\n newDisplay = \"\";\n else \n newDisplay = (value || \"\")+\"\";\n\n setDisplayValue(newDisplay);\n };\n\n const handleOnBlur = (event: any) => {\n\n const value = +event.target.value;\n\n if (value === 0 && isZeroAllowed) {\n setValue(0);\n setDisplayValue(templatedValue(value));\n if (onBlur) onBlur(0);\n return;\n }\n\n if (displayValue === null || Number.isNaN(value)) return;\n\n if (displayValue === \"\" || (+displayValue === 0 && !isZeroAllowed)) {\n setDisplayValue(templatedValue(value));\n return;\n }\n\n let parsedValue = parseFloat(displayValue);\n\n if (!Number.isNaN(parsedValue)) {\n const numberFormatted = numberWithCommas(templatedValue(parsedValue));\n setDisplayValue(numberFormatted);\n }\n \n setValue(parsedValue);\n if (onBlur) onBlur(parsedValue);\n };\n\n const numberWithCommas = (x: string | number) => {\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n };\n\n return (\n \n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n color: theme.colors.grey5,\n },\n icon: {\n width: \"max-content\",\n height: \"max-content\"\n },\n iconContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n paddingLeft: 5,\n paddingRight: 5\n },\n box: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n textAlign: \"center\",\n maxWidth: 174,\n padding: 8,\n zIndex: 1500,\n \n backgroundColor: theme.colors.grey1,\n\n ...theme.typography.subtitle2,\n color: theme.colors.grey5,\n \n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n },\n arrowBottom: {\n position: \"absolute\",\n bottom: -4,\n width: 8,\n height: 8,\n \n backgroundColor: theme.colors.grey1,\n transform: \"rotate(45deg)\",\n },\n arrowLeft: {\n position: \"absolute\",\n left: -4,\n width: 8,\n height: 8,\n\n backgroundColor: theme.colors.grey1,\n transform: \"rotate(45deg)\",\n },\n arrowRight: {\n position: \"absolute\",\n right: -4,\n width: 8,\n height: 8,\n\n backgroundColor: theme.colors.grey1,\n transform: \"rotate(45deg)\",\n }\n })\n);\n\nexport default useStyles;","import React, { useRef, useState } from \"react\";\n\nimport { Popper } from \"@material-ui/core\";\n\nimport { IconTooltipProps } from \"./props\";\nimport useStyles from \"./css\";\n\nexport default function IconTooltip(props: IconTooltipProps) {\n \n const [open, setOpen] = useState(false);\n const anchorEl = useRef(null);\n \n const { icon, tooltipText, classNameRoot, placement, arrowPlacement } = props;\n \n const classes = useStyles();\n \n function handleOpenPopper(event: any) {\n anchorEl.current = event.currentTarget;\n setOpen(true);\n }\n \n function handleClosePopper(event: any) {\n anchorEl.current = null;\n setOpen(false);\n }\n\n function getArrowPlacementClass(arrowPlacement: string) {\n switch (arrowPlacement) {\n case \"bottom\":\n return classes.arrowBottom;\n case \"left\":\n return classes.arrowLeft;\n case \"right\":\n return classes.arrowRight;\n default:\n return classes.arrowBottom;\n }\n }\n \n return (\n
\n \n \n {icon}\n
\n \n \n
\n
\n {tooltipText}\n
\n \n
\n );\n}","export enum ButtonPropsBorderSide {\n All,\n Right,\n Left\n}\n","export enum ButtonPropsFill {\n Filled,\n Outlined \n}\n","export enum ButtonPropsColor {\n Main = \"#6462F3\",\n Clilac = \"#EAE9FF\",\n Gray = \"#EBEBEB\",\n Gray1 = \"#F6F6F6\",\n Gray4 = \"#919CA5\",\n Green = \"#36CE91\",\n Red = \"#F15857\",\n None = \"transparent\"\n}\n","export enum ButtonPropsBorderRadius {\n Small = 5,\n Large = 51\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\n\nexport const useStyles = makeStyles((theme) => ({\n button: (customStyle) => ({\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 12,\n lineHeight: \"15px\",\n fontWeight: 700,\n paddingTop: 11,\n paddingBottom: 11,\n paddingLeft: 16,\n paddingRight: 16,\n borderWidth: 1,\n border: \"solid\",\n ...customStyle\n }),\n buttonItems: {\n gap: 10,\n display: \"flex\",\n alignItems: \"center\"\n },\n}));\n","import React, { useState, useMemo } from \"react\";\n\nimport { Button, CircularProgress } from \"@material-ui/core\";\n\nimport { ButtonWithSpinnerProps } from \"./props\";\nimport { ButtonPropsBorderSide } from \"../../../models/enums/button-props-border-side\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { useStyles } from \"./css\";\nimport { Color } from \"../../../constants/colors\";\n\n\nexport default function ButtonWithSpinner(props: ButtonWithSpinnerProps) {\n\n const {\n width = \"fit-content\",\n height = 32,\n margin,\n borderRadius = ButtonPropsBorderRadius.Small,\n borderSide = ButtonPropsBorderSide.All,\n fill = ButtonPropsFill.Filled,\n backgroundOrBorderColor = ButtonPropsColor.Main,\n innerText,\n textColor = fill === ButtonPropsFill.Filled\n ? backgroundOrBorderColor === ButtonPropsColor.Gray1\n ? ButtonPropsColor.Gray4\n : ButtonPropsColor.Gray1\n : backgroundOrBorderColor,\n innerIcon,\n hoverColor,\n onClick,\n disabled = false,\n isProcessing\n } = props;\n\n const [localIsProcessing, setLocalIsProcessing] = useState(false);\n\n const background = fill === ButtonPropsFill.Filled ? backgroundOrBorderColor : \"transparent\";\n const borderColor = fill === ButtonPropsFill.Outlined ? backgroundOrBorderColor : \"transparent\";\n\n const customStyles = useMemo(() => ({\n minWidth: width,\n height: height,\n margin: margin,\n borderRadius: getBorderRadiusStyles(),\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: borderColor,\n backgroundColor: background,\n color: textColor,\n \"&:hover\": getHoverStyles(),\n \"&:disabled\": {\n color: textColor,\n opacity: 0.4\n },\n }), [width, height, margin, borderRadius, borderSide, backgroundOrBorderColor, fill, textColor, hoverColor]);\n\n const classes = useStyles(customStyles);\n\n function getHoverStyles() {\n if (fill === ButtonPropsFill.Filled && !hoverColor) {\n return {\n backgroundColor: background,\n color: textColor\n };\n } else if (hoverColor) {\n return {\n backgroundColor: hoverColor,\n color: [ButtonPropsColor.Gray1, ButtonPropsColor.Clilac].includes(hoverColor)\n ? (backgroundOrBorderColor === ButtonPropsColor.None ? textColor : backgroundOrBorderColor)\n : Color.gray1,\n };\n }\n return {};\n }\n\n function getBorderRadiusStyles() {\n switch (borderSide) {\n case ButtonPropsBorderSide.All:\n return borderRadius;\n case ButtonPropsBorderSide.Left:\n return `${borderRadius}px 0 0 ${borderRadius}px`;\n case ButtonPropsBorderSide.Right:\n return `0 ${borderRadius}px ${borderRadius}px 0`;\n }\n };\n\n async function handleButtonClick(event?: React.MouseEvent) {\n setLocalIsProcessing(true);\n const result = event ? onClick(event) : onClick();\n if (result && typeof result.then === 'function') {\n await result;\n }\n setLocalIsProcessing(false);\n }\n\n return (\n \n
\n {(isProcessing ?? localIsProcessing)\n ? \n : innerIcon ? innerIcon : null\n }\n {innerText}\n
\n \n );\n};\n","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport moment from \"moment\";\n\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { selectUserInfo } from \"../../../../redux/store\";\n\nimport { Button, Popover } from \"@material-ui/core\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { OpenCashRegisterModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { CrossIcon, InfoIcon } from \"../../../../assets/icons\";\nimport InputCurrency from \"../../../common/InputCurrency\";\nimport IconTooltip from \"../../../common/IconTooltip\";\nimport ButtonWithSpinner from \"../../../common/ButtonWithSpinner\";\nimport { Color } from \"../../../../constants/colors\";\nimport { ButtonPropsColor } from \"../../../../models/enums/button-props-color\";\nimport { ButtonPropsFill } from \"../../../../models/enums/button-props-fill\";\nimport { ButtonPropsBorderRadius } from \"../../../../models/enums/button-props-border-radius\";\n\n\nexport default function OpenCashRegisterModal(props: OpenCashRegisterModalProps) {\n \n const { open, setOpen, initialCash, setInitialCash, currencyTemplate, onSubmit, onClose, anchor } = props;\n \n const { t } = useTranslation(\"general\");\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const classes = useStyles();\n const dtFormattingRule = localeApp === \"en\" ? \"MM/DD/YYYY\" : \"DD/MM/YYYY\"\n \n const isUserAbleToOpenCashRegister = useAppSelector(selectUserInfo).canOpenCloseCashRegister\n\n function handleCloseModal() {\n handleOnClose();\n }\n \n function handleOnClose() {\n if (onClose) onClose();\n setOpen(false);\n }\n \n const SubmitButton = () =>\n
\n {await onSubmit()}}\n />\n
\n\n const NoPermissionText = () =>\n
\n {t(\"This user does not have permission to open cash register\")}\n
\n \n\n const CrossCloseButton = () =>\n
\n \n
\n \n return (\n
\n \n
\n
{t(\"Date\") + \": \"}{moment(new Date()).format(dtFormattingRule)}
\n \n
\n
\n
\n
\n \n {t(\"Initial cash\")}\n \n *\n }\n tooltipText={t(\"Expected cash on hand\")}\n />\n
\n \n {\n isUserAbleToOpenCashRegister\n ? \n : \n }\n \n
\n \n
\n );\n}","export class OpenCashRegisterFormData {\n initialCash: number;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.initialCash = x.initialCash;\n } else {\n this.initialCash = 1000;\n }\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n\n height: \"100%\",\n width: 500\n },\n drawer: {\n background: theme.colors.white,\n borderTopLeftRadius: 5,\n borderBottomLeftRadius: 5,\n\n display: \"flex\",\n flexDirection: \"column\",\n overflowX: \"hidden\",\n },\n tabs: {\n ...theme.typography.txtBody1,\n backgroundColor: theme.colors.white,\n color: theme.colors.clearMain,\n\n borderBottom: \"solid\",\n borderBottomWidth: 1,\n borderBottomColor: \"rgba(201, 205, 211, 0.5)\",\n\n \"& .MuiTabs-indicator\": {\n backgroundColor: theme.palette.common.white\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n width: \"50%\",\n },\n \"& .MuiTab-root\": {\n paddingLeft: 0,\n paddingRight: 0,\n textTransform: \"none\",\n color: theme.colors.grey1,\n backgroundColor: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n \"& .Mui-selected\": {\n color: theme.colors.clearMain,\n backgroundColor: theme.palette.common.white,\n fontWeight: \"bold\",\n },\n },\n tab: {\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n }\n },\n tabPanelRoot: {\n padding: \"0 !important\",\n height: \"100%\"\n },\n divider: {\n width: 452,\n height: 0,\n \n marginLeft: 24,\n marginRight: 24,\n marginTop: 0,\n marginBottom: 0,\n \n color: theme.colors.grey2,\n },\n headerDate: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n\n width: \"100%\",\n padding: \"16px 24px\",\n },\n headerDateText: {\n display: \"flex\",\n alignItems: \"center\",\n \n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n\n height: 40\n },\n headerDateDate: {\n marginLeft: 8,\n },\n goBackHeader: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n\n width: \"100%\",\n padding: \"16px 24px\",\n },\n goBackButton: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n \n width: 89,\n height: 16,\n \n color: theme.colors.clearMain,\n \n cursor: \"pointer\",\n },\n backButtonText: {\n ...theme.typography.buttons,\n fontWeight: 700,\n },\n backButtonIcon: {\n fontSize: 12,\n lineHeight: 15,\n marginRight: 5,\n },\n closeIcon: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 16,\n height: 16,\n\n cursor: \"pointer\",\n color: theme.colors.grey5,\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n position: \"relative\",\n height: \"100%\"\n },\n cashDetailsBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n width: 452,\n height: 367,\n \n marginTop: 16,\n marginLeft: 15,\n marginRight: 33,\n marginBottom: 13,\n \n padding: 8,\n },\n cashDetailsHeader: {\n justifySelf: \"flex-start\",\n alignSelf: \"flex-start\",\n \n marginBottom: 18,\n\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n cashDetailsRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n \n height: 18,\n width: \"100%\",\n \n marginBottom: 18\n },\n cashDetailsIcon: {\n marginRight: 14\n },\n cashDetailsRowName: {\n display: \"inline-flex\",\n alignItems: \"center\",\n \n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n cashDetailsRowValue: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n fontSize: 12,\n \n color: theme.colors.grey5\n },\n historyBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n },\n historyMovementBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n marginTop: 20,\n marginLeft: 24,\n marginRight: 24,\n },\n historyMovementRow: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n \n marginBottom: 8,\n },\n historyMovementTitle: {\n width: 82,\n \n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n historyMovementValue: {\n //display: \"flex\",\n width: 340,\n wordBreak: \"break-all\",\n \n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n historyChip: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n padding: \"4px 8px\",\n \n borderRadius: 5,\n \n ...theme.typography.txtBody2,\n fontWeight: 700,\n },\n historyDepositChip: {\n color: theme.colors.clearGreen,\n backgroundColor: \"rgba(54, 206, 145, 0.2)\"\n },\n historyWithdrawalChip: {\n color: theme.colors.clearRed,\n backgroundColor: \"rgba(241, 88, 87, 0.2)\"\n },\n historyCashOpeningChip: {\n color: theme.colors.clearMain,\n backgroundColor: \"rgba(100, 98, 243, 0.2)\"\n },\n historyDivider: {\n width: 452,\n height: 0,\n \n marginTop: 8,\n \n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey1,\n },\n currencyValue: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey5\n },\n cashClosingBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n marginTop: 17,\n marginLeft: 24,\n },\n cashClosingInputAndNumberBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n marginBottom: 24,\n marginTop: 18,\n },\n cashClosingInputRow: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n },\n cashClosingInputsFirstRow: {\n marginTop: 18,\n },\n cashClosingInputColumn: {\n width: 300,\n },\n cashClosingNumberColumn: {\n marginLeft: 20,\n alignSelf: \"center\"\n },\n inputLabel: {\n ...theme.typography.buttons,\n color: theme.colors.grey4,\n fontWeight: 700,\n marginBottom: 8\n },\n numberLabel: {\n ...theme.typography.buttons,\n color: theme.colors.grey5,\n },\n numberValue: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n cashClosingDivider: {\n width: 225,\n height: 0,\n\n marginTop: 24,\n marginBottom: 24,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey2,\n },\n commentsLabel: {\n marginTop: 24\n },\n singleButtonFooter: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n height: 80,\n width: 500,\n\n position: \"sticky\",\n bottom: 0,\n padding: 24,\n backgroundColor: \"#FFFFFF\"\n },\n newMovementBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n\n marginTop: 16,\n marginLeft: 24,\n },\n newMovementHeader: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 700,\n marginBottom: 16,\n },\n typeOfMovementRadios: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n \n width: 200,\n \n marginBottom: 16,\n },\n radioGreen: {\n color: theme.colors.grey5,\n \"&.Mui-checked\": {\n color: theme.colors.clearGreen,\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearGreen,\n },\n },\n \"&:hover .MuiIconButton-label span\":{\n boxShadow: `inset 0 0 0 1px #36CE91, inset 0 -1px 0 #36CE91`\n }\n },\n radioRed: {\n color: theme.colors.grey5,\n \"&.Mui-checked\": {\n color: theme.colors.clearGreen,\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearRed,\n },\n },\n \"&:hover .MuiIconButton-label span\":{\n boxShadow: `inset 0 0 0 1px #F15857, inset 0 -1px 0 #F15857`\n }\n },\n radioLabelRoot: {\n margin: 0,\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n inputSpacing: {\n height: 0,\n marginBottom: 16,\n },\n footer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n \n width: \"100%\",\n height: 80,\n\n position: \"sticky\",\n bottom: 0,\n marginTop: \"auto\",\n \n padding: 24,\n },\n button: {\n minWidth: 214,\n height: 32,\n \n borderRadius: 51,\n \n ...theme.typography.buttons,\n fontWeight: 700,\n },\n mainButton: {\n color: theme.colors.clearMain,\n backgroundColor: theme.colors.white,\n \n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clear2,\n \n \"&:hover\": {\n backgroundColor: theme.colors.clear2,\n color: theme.colors.grey1,\n },\n\n \"&:disabled\": {\n backgroundColor: theme.colors.white,\n color: theme.colors.clearMain,\n borderColor: theme.colors.clearMain,\n opacity: 0.3\n }\n },\n redButton: {\n color: theme.colors.clearRed,\n backgroundColor: theme.colors.white,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearRed,\n\n \"&:hover\": {\n backgroundColor: theme.colors.clearRed,\n color: theme.colors.grey1,\n },\n\n \"&:disabled\": {\n backgroundColor: theme.colors.white,\n color: theme.colors.clearRed,\n borderColor: theme.colors.clearRed,\n opacity: 0.3\n }\n },\n mainColorText: {\n color: theme.colors.clearMain\n },\n requiredFields: { \n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n },\n dot: {\n marginLeft: 3,\n color: theme.colors.clearMain\n },\n cancelModalPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n cancelModalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n cancelModalTitleSpace: {\n margin: \"24px 0px 24px 0px\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n fontFamily: 'Inter, sans-serif',\n fontStyle: \"normal\",\n fontWeight: 700,\n color: \"#26292B\",\n },\n modalSubTitleText: {\n fontFamily: 'Inter, sans-serif',\n fontSize: 12,\n color: theme.colors.grey1,\n fontStyle: \"normal\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"space-around\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n\n width: \"100%\",\n height: 75,\n padding: \"8px 24px\",\n },\n block: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"inherit\",\n \n width: 159,\n height: 59,\n \n padding: \"4px 0\"\n },\n blockCashExpected: {\n display: \"flex\",\n },\n centerBlock: {\n width: 134\n },\n textWithTooltip: {\n lineHeight: \"15px\",\n },\n blockLongText: {\n paddingTop: \"0\",\n },\n text: {\n ...theme.typography.buttons,\n color: theme.colors.grey5\n },\n value: {\n ...theme.typography.txtBody1,\n fontSize: 12,\n fontWeight: 700,\n color: theme.colors.grey5\n },\n verticalDivider: {\n height: 59,\n width: 0,\n\n opacity: 0.5,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey2,\n \n margin: 8\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { CashStateHeaderProps } from \"./props\";\nimport useStyles from \"./css\";\nimport IconTooltip from \"../../../common/IconTooltip\";\nimport { InfoIcon } from \"../../../../assets/icons\";\nimport useCurrencyValueTemplate from \"../../../../hooks/useCurrencyValueTemplate\";\n\n\nexport default function CashStateHeader(props: CashStateHeaderProps) {\n \n const { state, currencyTemplate } = props;\n const { initialCash, cashNow, paymentsReceived } = state;\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n const templatedValue = useCurrencyValueTemplate(currencyTemplate);\n \n return (\n
\n
\n
\n {t(\"Initial cash\")} \n }\n tooltipText={t(\"Cash when the cash register was opened\")}\n />\n \n
\n
{templatedValue(initialCash)}
\n
\n
\n
\n
\n
\n {t(\"Cash expected at the end of the day\")}\n
\n }\n tooltipText={t(\"Cash expected at the cash register at this moment\")}\n />\n
\n
{templatedValue(cashNow)}
\n
\n
\n
\n
\n {t(\"Payments received\")}\n }\n tooltipText={t(\"Total sum of all payment methods\")}\n />\n
\n
{templatedValue(paymentsReceived)}
\n
\n
\n );\n}","export enum CashRegisterMovementType {\n CashOpening,\n Deposit,\n Withdrawal\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (color?: string) =>\n makeStyles((theme) => ({\n root: {\n \"&:hover\": {\n backgroundColor: \"transparent\",\n },\n },\n icon: {\n borderRadius: \"50%\",\n width: 16,\n height: 16,\n boxShadow: `inset 0 0 0 1px ${\n color || theme.colors.grey5\n }, inset 0 -1px 0 ${color || theme.colors.grey5}`,\n backgroundColor: \"#f5f8fa\",\n backgroundImage:\n \"linear-gradient(180deg,hsla(0,0%,100%,.8),hsla(0,0%,100%,0))\",\n \"$root.Mui-focusVisible &\": {\n outline: \"2px auto rgba(19,124,189,.6)\",\n outlineOffset: 2,\n },\n \"input:hover ~ &\": {\n backgroundColor: \"#ebf1f5\",\n },\n \"input:disabled ~ &\": {\n boxShadow: \"none\",\n background: \"rgba(206,217,224,.5)\",\n },\n },\n checkedIcon: {\n backgroundColor: \"#f5f8fa\",\n backgroundImage:\n \"linear-gradient(180deg,hsla(0,0%,100%,.1),hsla(0,0%,100%,0))\",\n \"&:before\": {\n display: \"block\",\n width: 16,\n height: 16,\n backgroundImage: `radial-gradient(${color || theme.colors.grey5},${\n color || theme.colors.grey5\n } 28%,transparent 32%)`,\n content: '\"\"',\n },\n \"input:hover ~ &\": {\n backgroundColor: \"#f5f8fa\",\n },\n },\n }));\n\nexport default useStyles;\n","import React from \"react\";\nimport MuiRadio, { RadioProps } from \"@material-ui/core/Radio\";\n\nimport useStyles from \"./css\";\n\nconst Radio = (props: RadioProps) => {\n const classes = useStyles(props.style?.color)();\n\n return (\n \n }\n icon={}\n {...props}\n />\n );\n};\n\nexport default Radio;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number | string) =>\n makeStyles((theme) => ({\n input: {\n backgroundColor: \"#F6F6F6\",\n height: 40,\n padding: \"13px 0px 13px 12px\",\n //fontSize: 14,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: width || 370,\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n border: \"solid 1px #6462F3\",\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n },\n inputError: {\n color: \"#f15857\",\n border: \"solid 1px #f15857\",\n },\n counter: {\n position: \"absolute\",\n bottom: 7,\n right: 15,\n fontSize: 12,\n color: \"#B5B9C1\",\n padding: \"5px\",\n },\n container: {\n position: \"relative\",\n },\n }));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\nimport TextareaAutosize from \"@material-ui/core/TextareaAutosize\";\nimport useStyles from \"./css\";\nimport { TextareaProps } from \"./props\";\n\nconst Textarea = (props: TextareaProps) => {\n \n const { id,\n value,\n minRows,\n maxRows,\n name,\n placeholder,\n isValid,\n width,\n inputClass,\n onChange,\n onKeyPress,\n disabled,\n readOnly,\n showCounter,\n onClick,\n onBlur,\n maxLength,\n styles,\n } = props;\n\n const classes = useStyles(width)();\n\n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n\n if (isValid() === undefined) {\n return false;\n }\n\n return !isValid();\n };\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n const handleOnKeyPress = (event: any) => {\n if (onKeyPress) {\n onKeyPress(event);\n }\n };\n\n const handleOnClick = (event: any) => {\n if (onClick) {\n onClick(event);\n }\n };\n\n const handleOnBlur = (event: any) => {\n if (onBlur) {\n onBlur(event);\n }\n };\n \n \n return (\n
\n \n {showCounter &&
{`${value?.length}/${maxLength}`}
}\n
\n );\n};\n\nexport default Textarea;","export class CloseCashRegisterRequest {\n cashAtTheEndOfTheDay: number;\n withdrawalByAdministrator: number;\n chargingUserId: string;\n chargingUserName: string;\n notes: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.cashAtTheEndOfTheDay = x.cashAtTheEndOfTheDay;\n this.chargingUserId = x.chargingUserId;\n this.chargingUserName = x.chargingUserName;\n this.withdrawalByAdministrator = x.withdrawalByAdministrator;\n this.notes = x.notes;\n } else {\n this.cashAtTheEndOfTheDay = 0.0;\n this.chargingUserId = \"\";\n this.chargingUserName = \"\";\n this.withdrawalByAdministrator = 0.0;\n this.notes = \"\";\n }\n }\n}","import { CashRegisterMovementType } from \"./enums/cash-register-movement-type\";\n\nexport class RegisterCashRegisterMovementRequest {\n type: CashRegisterMovementType;\n amount: number;\n time: Date;\n chargingUserId: string;\n chargingUserName: string;\n notes: string;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.type = x.type;\n this.amount = x.amount;\n this.time = x.time;\n this.chargingUserId = x.chargingUserId;\n this.chargingUserName = x.chargingUserName;\n this.notes = x.notes;\n } else {\n this.type = CashRegisterMovementType.CashOpening;\n this.amount = 0.0;\n this.time = new Date();\n this.chargingUserId = \"\";\n this.chargingUserName = \"\";\n this.notes = \"\";\n }\n }\n}","export enum PaymentMethodType {\n Cash,\n CreditCard,\n BankTransfer,\n Oxxo,\n MercadoPago\n}","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport moment from \"moment\";\n\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../redux/store\";\n\nimport { Backdrop, Button, Drawer, Fade, Modal, Tab, Tabs, Typography } from \"@material-ui/core\";\nimport { TabContext, TabPanel } from \"@material-ui/lab\";\nimport { ArrowBackIos } from \"@material-ui/icons\";\nimport RadioGroup from \"@material-ui/core/RadioGroup\";\n\nimport { CashRegisterSidebarProps } from \"./props\";\nimport useStyles from \"./css\";\nimport {\n ArrowLeftIcon,\n ArrowRightIcon,\n BankIcon,\n CashIcon,\n CashRegisterIcon,\n CreditCardIcon,\n CrossIcon,\n MercadoPagoIcon,\n OxxoIcon\n} from \"../../../../assets/icons\";\nimport CashStateHeader from \"../CashStateHeader/cash-state-header\";\nimport useCurrencyValueTemplate from \"../../../../hooks/useCurrencyValueTemplate\";\nimport { CashRegisterMovement } from \"../../../../models/cash-register-movement\";\nimport InputCurrency from \"../../../common/InputCurrency\";\nimport FormControlLabel from \"@material-ui/core/FormControlLabel\";\nimport Radio from \"../../../common/Radio\";\nimport Textarea from \"../../../common/Textarea\";\nimport { CloseCashRegisterRequest } from \"../../../../models/close-cash-register-request\";\nimport { CashRegisterMovementType } from \"../../../../models/enums/cash-register-movement-type\";\nimport { RegisterCashRegisterMovementRequest } from \"../../../../models/register-cash-register-movement-request\";\nimport { PaymentMethodType } from \"../../../../models/enums/payment-method-type\";\nimport ButtonWithSpinner from \"../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../models/enums/button-props-color\";\nimport { ButtonPropsFill } from \"../../../../models/enums/button-props-fill\";\n\n\nexport default function CashRegisterSidebar(props: CashRegisterSidebarProps) {\n\n const { open, setOpen, onCashRegisterClose, onRegisterNewMovement, state, history, onClose } = props;\n\n const [mode, setMode] = useState<\"main\" | \"newMovement\" | \"cashClosing\">(\"main\");\n const [activeTab, setActiveTab] = useState<\"cash\" | \"history\">(\"cash\");\n const [goBackModalIsOpen, setGoBackModalIsOpen] = useState(false);\n const [cancelCashClosureModalIsOpen, setCancelCashClosureModalIsOpen] = useState(false);\n\n const [newMovementType, setNewMovementType] = useState(CashRegisterMovementType.Deposit);\n const [newMovementAmount, setNewMovementAmount] = useState(0);\n const [newMovementComments, setNewMovementComments] = useState(\"\");\n\n const [cashAtTheEndOfDay, setCashAtTheEndOfDay] = useState(state.cashNow);\n const [withdrawalAmount, setWithdrawalAmount] = useState(0);\n const [closingCashComments, setClosingCashComments] = useState(\"\");\n\n const userInfo = useAppSelector(selectUserInfo);\n const isUserAbleToOpenAndCloseCash = userInfo.canOpenCloseCashRegister;\n const isUserAbleToRegisterMovements = userInfo.canMakeCashRegisterMovements;\n\n const accountSettings = useAppSelector(selectAccountSettings)\n const currencyTemplate = accountSettings.currencyTemplate;\n const templatedCurrency = useCurrencyValueTemplate(currencyTemplate);\n\n const paymentMethods = accountSettings.paymentMethods.map(x => x.key);\n\n function paymentMethodsContains(paymentMethod: PaymentMethodType): boolean {\n return paymentMethods.findIndex(x => x === paymentMethod) !== -1\n }\n\n const [hasClosingCashCommentsBeenFocused, setClosingCashCommentsBeenFocused] = useState(false);\n const [hasNewMovementCommentsBeenFocused, setNewMovementCommentsBeenFocused] = useState(false);\n const [hasNewMovementAmountBeenFocused, setNewMovementAmountBeenFocused] = useState(false);\n\n const { t } = useTranslation(\"general\");\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const classes = useStyles();\n\n const dateTimeFormat = localeApp === \"en\" ? \"MM/DD/YYYY\" : \"DD/MM/YYYY\";\n const timeFormat = \"HH:mm\";\n\n const handleTabChange = (event: any, newValue: \"cash\" | \"history\") => {\n setActiveTab(newValue);\n };\n\n function handleCloseModal() {\n handleOnClose();\n }\n\n function handleOnClose() {\n if (mode === \"newMovement\" && (newMovementAmount !== 0 || newMovementComments !== \"\")) {\n setGoBackModalIsOpen(true);\n return;\n }\n if (mode === \"cashClosing\" && (withdrawalAmount !== 0 || closingCashComments !== \"\")) {\n setCancelCashClosureModalIsOpen(true);\n return;\n }\n if (onClose) onClose();\n setOpen(false);\n setMode(\"main\");\n resetAllInputs();\n }\n\n function handleRegisterMovementClick() {\n resetNewMovementInputs()\n setMode(\"newMovement\");\n }\n\n function handleCloseCashRegisterClick() {\n resetCashClosingInputs()\n setMode(\"cashClosing\");\n }\n\n function handleGoBackClick() {\n if (mode === \"newMovement\" && (newMovementAmount !== 0 || newMovementComments !== \"\")) {\n setGoBackModalIsOpen(true);\n return;\n }\n if (mode === \"cashClosing\" && (withdrawalAmount !== 0 || closingCashComments !== \"\")) {\n setCancelCashClosureModalIsOpen(true);\n return;\n }\n resetComponent();\n }\n\n function resetComponent() {\n setMode(\"main\");\n resetAllInputs();\n }\n\n async function handleRegisterMovementButtonClick() {\n await onRegisterNewMovement(new RegisterCashRegisterMovementRequest(\n {\n type: newMovementType,\n amount: newMovementAmount,\n time: new Date(),\n chargingUserId: userInfo.userId,\n chargingUserName: userInfo.fullName,\n notes: newMovementComments\n }\n ));\n resetComponent()\n }\n\n async function handleCloseCashButtonClick() {\n await onCashRegisterClose(new CloseCashRegisterRequest(\n {\n cashAtTheEndOfTheDay: cashAtTheEndOfDay,\n chargingUserId: userInfo.userId,\n chargingUserName: userInfo.fullName,\n withdrawalByAdministrator: withdrawalAmount,\n notes: closingCashComments\n }));\n }\n\n function isRegisterMovementButtonDisabled(): boolean {\n return newMovementAmount === 0 || newMovementComments === \"\";\n }\n\n function isCloseCashButtonDisabled(): boolean {\n return withdrawalAmount > cashAtTheEndOfDay || closingCashComments === \"\";\n }\n\n function resetAllInputs() {\n resetNewMovementInputs();\n resetCashClosingInputs();\n }\n\n function resetNewMovementInputs() {\n setNewMovementType(CashRegisterMovementType.Deposit);\n setNewMovementAmount(0);\n setNewMovementComments(\"\");\n setNewMovementCommentsBeenFocused(false);\n setNewMovementAmountBeenFocused(false)\n }\n\n function resetCashClosingInputs() {\n setCashAtTheEndOfDay(state.cashNow);\n setWithdrawalAmount(0)\n setClosingCashComments(\"\");\n setClosingCashCommentsBeenFocused(false);\n }\n\n function addedCurrencyValue(value: number) {\n if (value > 0) return `+${templatedCurrency(value)}`\n return templatedCurrency(value)\n }\n\n function subtractedCurrencyValue(value: number) {\n if (value > 0) return `-${templatedCurrency(value)}`\n return templatedCurrency(value)\n }\n\n function getCurrencyFormattedNegativeString(actualCash: number, inputValue: number) {\n const difference = actualCash - inputValue;\n return difference < 0 ? `-${templatedCurrency(Math.abs(difference))}` : templatedCurrency(difference);\n }\n\n function countNextDayCash(actualCash: number, withdrawalAmount: number) {\n return actualCash - withdrawalAmount;\n }\n const nextCashOpening = countNextDayCash(cashAtTheEndOfDay, withdrawalAmount);\n\n function getChipByMovementType(type: CashRegisterMovementType) {\n switch (type) {\n case CashRegisterMovementType.CashOpening: return
{t(\"Open cash register\")}
\n case CashRegisterMovementType.Deposit: return
{t(\"Deposit\")}
\n case CashRegisterMovementType.Withdrawal: return
{t(\"Withdrawal\")}
\n }\n }\n\n function getTemplateByMovementType(type: CashRegisterMovementType, amount: number) {\n switch (type) {\n case CashRegisterMovementType.CashOpening: return templatedCurrency(amount)\n case CashRegisterMovementType.Deposit: return addedCurrencyValue(amount)\n case CashRegisterMovementType.Withdrawal: return subtractedCurrencyValue(amount)\n }\n }\n\n function handleNewMovementCommentsChange(event: any) {\n setNewMovementComments(event.target.value)\n }\n\n function handleClosingCashCommentsChange(event: any) {\n setClosingCashComments(event.target.value)\n }\n\n function getOrderedMovements() {\n const movements = [...history.movements];\n return movements.sort((a, b) => new Date(b.time).getTime() - new Date(a.time).getTime());\n }\n\n const CrossCloseButton = () =>\n
\n \n
\n\n const GoBackHeader = () =>\n
\n \n {t(\"Go back\")}\n
\n\n
\n\n const DateHeader = () =>\n <>\n
\n
{t(\"Date\") + \":\"}{moment(new Date()).format(dateTimeFormat)}
\n \n
\n
\n \n\n\n const TabsHeader = () =>\n \n \n \n \n \n \n\n const CashDataHeader = () =>\n <>\n \n
\n \n\n const CashDetailsBlock = () =>\n
\n
{t(\"Details\") + \":\"}
\n
\n
{t(\"Initial cash\")}
\n
{templatedCurrency(state.initialCash)}
\n
\n {\n paymentMethodsContains(PaymentMethodType.Cash) &&\n
\n
{t(\"Cash payments\")}
\n
{addedCurrencyValue(state.cashPayments)}
\n
\n }\n {\n paymentMethodsContains(PaymentMethodType.CreditCard) &&\n
\n
{t(\"Credit/debit card payments\")}
\n
{addedCurrencyValue(state.creditCardPayments)}
\n
\n }\n {\n paymentMethodsContains(PaymentMethodType.BankTransfer) &&\n
\n
{t(\"Bank transfers\")}
\n
{addedCurrencyValue(state.bankTransferPayments)}
\n
\n }\n {\n paymentMethodsContains(PaymentMethodType.Oxxo) &&\n
\n
{t(\"Payments with Oxxo\")}
\n
{addedCurrencyValue(state.oxxoPayments)}
\n
\n }\n {\n paymentMethodsContains(PaymentMethodType.MercadoPago) &&\n
\n
{t(\"Payments with Mercado pago\")}
\n
{addedCurrencyValue(state.mercadoPagoPayments)}
\n
\n }\n
\n
{t(\"Deposit by administrator\")}
\n
{addedCurrencyValue(state.depositByAdministrator)}
\n
\n
\n
{t(\"Withdrawal by administrator\")}
\n
{subtractedCurrencyValue(state.withdrawalByAdministrator)}
\n
\n
\n\n const HistoryMovementBlock = (movement: CashRegisterMovement) =>\n
\n
\n
{t(\"Movement\") + \":\"}
\n {getChipByMovementType(movement.type)}\n
\n
\n
{t(\"Amount\") + \":\"}
\n
{getTemplateByMovementType(movement.type, movement.amount)}
\n
\n
\n
{t(\"User\") + \":\"}
\n
{movement.userName}
\n
\n
\n
{t(\"Time\") + \":\"}
\n
{moment(movement.time).format(timeFormat)}
\n
\n
\n
{t(\"Notes\") + \":\"}
\n
{movement.notes ?? \"--\"}
\n
\n
\n
\n\n const RequiredFields = () =>\n
{t(\"Required fields\")}*
\n\n const InputLabel = ({ label }: any) =>\n
{label}*
\n\n const NumberValue = ({ number }: any) =>\n
{number}
\n\n const CloseCashButton = () =>\n
\n { await handleCloseCashButtonClick() }}\n disabled={isCloseCashButtonDisabled()}\n />\n
\n\n const RegisterMovementButton = () =>\n
\n { await handleRegisterMovementButtonClick() }}\n disabled={isRegisterMovementButtonDisabled()}\n />\n
\n\n const CashContent = () =>\n
\n \n \n \n
\n\n const HistoryContent = () =>\n
\n
\n {\n getOrderedMovements().map(x =>\n \n )\n }\n
\n
\n\n const ButtonsFooter = () =>\n <>\n {(isUserAbleToOpenAndCloseCash || isUserAbleToRegisterMovements) &&\n
\n {\n isUserAbleToRegisterMovements &&\n \n }\n {\n isUserAbleToOpenAndCloseCash &&\n \n }\n
\n }\n \n\n const GoBackModal = () =>\n setGoBackModalIsOpen(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n \n
\n
\n \n \n {t(\"Cancel new movement registration?\")}\n \n
\n
\n setGoBackModalIsOpen(false)}\n >\n {t(\"Go back\")}\n \n {\n resetComponent();\n setGoBackModalIsOpen(false);\n }}\n >\n {t(\"Cancel\")}\n \n
\n
\n
\n \n \n\n const CancelCashClosureModal = () =>\n setCancelCashClosureModalIsOpen(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n \n
\n
\n \n \n {t(\"Cancel cash register closure?\")}\n \n
\n
\n setCancelCashClosureModalIsOpen(false)}\n >\n {t(\"Go back\")}\n \n {\n resetComponent();\n setCancelCashClosureModalIsOpen(false);\n }}\n >\n {t(\"Cancel\")}\n \n
\n
\n
\n \n \n\n return (\n \n
\n {\n mode === \"main\"\n ? \n : \n }\n \n {\n mode === \"main\" &&\n \n \n {CashContent()}\n \n \n {HistoryContent()}\n \n \n }\n {\n mode === \"newMovement\" &&\n
\n
\n
{t(\"New movement\")}
\n \n setNewMovementType(+event.target.value)}\n value={newMovementType}\n className={classes.typeOfMovementRadios}\n >\n \n }\n label={t(\"Deposit\")}\n />\n\n \n }\n label={t(\"Withdrawal\")}\n />\n \n \n setNewMovementAmountBeenFocused(true)}\n isValid={() => !hasNewMovementAmountBeenFocused || newMovementAmount > 0}\n isZeroAllowed\n />\n
\n \n setNewMovementCommentsBeenFocused(true)}\n isValid={() => !hasNewMovementCommentsBeenFocused || newMovementComments.length > 0}\n />\n
\n \n \n
\n }\n {\n mode === \"cashClosing\" &&\n
\n \n
\n \n
\n
\n
\n \n
\n
\n
{t(\"Difference\")}
\n
\n
\n
\n
\n \n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
\n
{t(\"Next cash opening\")}
\n
\n
\n
\n
\n withdrawalAmount <= cashAtTheEndOfDay}\n isZeroAllowed\n />\n
\n
\n \n
\n
\n
\n \n
\n setClosingCashCommentsBeenFocused(true)}\n isValid={() => !hasClosingCashCommentsBeenFocused || closingCashComments.length > 0}\n />\n
\n
\n \n \n
\n }\n
\n \n );\n}","import { PaymentMethodType } from \"./enums/payment-method-type\";\n\nexport class AppointmentPaymentPartEntity {\n paymentMethod: PaymentMethodType | null;\n amountPaid: number;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.paymentMethod = x.paymentMethod;\n this.amountPaid = x.amountPaid;\n } else {\n this.paymentMethod = null;\n this.amountPaid = 0;\n }\n }\n}","import { AppointmentPricedService } from \"./appointment-priced-service\";\nimport { PaymentEditionType } from \"./enums/payment-edition-type\";\nimport { AppointmentPaymentPartEntity } from \"./appointment-payment-part-entity\";\n\nexport class AppointmentPaymentEntity {\n id: string | null;\n friendlyId: number | null;\n date: Date;\n parts: AppointmentPaymentPartEntity[];\n editingPart: AppointmentPaymentPartEntity | null;\n notes: string;\n services: AppointmentPricedService[];\n isEditable: boolean;\n editionType: PaymentEditionType | null;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.friendlyId = x.friendlyId;\n this.date = x.date;\n this.parts = x.parts;\n this.editingPart = x.editingPart;\n this.notes = x.notes;\n this.services = x.services;\n this.isEditable = x.isEditable;\n this.editionType = null;\n } else {\n this.id = null;\n this.friendlyId = null;\n this.date = new Date();\n this.parts = [new AppointmentPaymentPartEntity()]\n this.editingPart = null\n this.notes = \"\";\n this.services = [];\n this.isEditable = true;\n this.editionType = null;\n }\n }\n}","import { AppointmentPaymentValues } from \"./appointment-payment-values\";\nimport { AppointmentPaymentEntity } from \"./appointment-payment-entity\";\nimport { AppointmentPaymentChangeRecord } from \"./appointment-payment-change-record\";\n\nexport class AppointmentPaymentFormData {\n payment: AppointmentPaymentEntity;\n paymentValues: AppointmentPaymentValues[];\n changeRecords: AppointmentPaymentChangeRecord[];\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.payment = x.payment;\n this.paymentValues = x.paymentValues;\n this.changeRecords = x.changeRecords;\n }\n else {\n this.payment = new AppointmentPaymentEntity();\n this.paymentValues = [];\n this.changeRecords = [];\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport { AppointmentPaymentFormData } from \"../models/appointment-payment-form-data\";\nimport { OpenCashRegisterRequest } from \"../models/open-cash-register-request\";\nimport { CloseCashRegisterRequest } from \"../models/close-cash-register-request\";\nimport { PaymentMethodType } from \"../models/enums/payment-method-type\";\nimport { RegisterCashRegisterMovementRequest } from \"../models/register-cash-register-movement-request\";\nimport { CashRegisterStateModel } from \"../models/interfaces/cash-register-state-model\";\nimport { Appointment } from \"../models/appointment\";\n\n\nexport class PaymentsService {\n private static basePaymentsUrl: string = \"/payments\";\n private static baseCashRegisterUrl: string = \"/cashRegister\";\n\n static getPaymentFormData(appointmentId: string | number): Promise {\n return ApiClient\n .get(`${this.basePaymentsUrl}/getPaymentFormData?AppointmentId=${appointmentId}`)\n }\n \n static getRecurringAppointmentPaymentFormData(\n appointmentId: string | number,\n recurredAppointmentsIds: string[],\n recurringApptTotalToPaid: number): Promise {\n const request = {\n currentAppointmentId: appointmentId,\n recurringAppointmentIds: recurredAppointmentsIds,\n recurringApptTotalToPaid: recurringApptTotalToPaid\n };\n return ApiClient.post(`${this.basePaymentsUrl}/GetRecurringAppointmentPaymentFormData`, request).then((data) => {\n return new AppointmentPaymentFormData(data);\n });\n }\n\n static getInitialCash(): Promise {\n return ApiClient\n .get(`${this.baseCashRegisterUrl}/getInitialCash`)\n .then(data => data.initialCash)\n }\n\n static getCashRegisterCurrentState(paymentMethods: PaymentMethodType[]): Promise {\n return ApiClient.post(`${this.baseCashRegisterUrl}/getCashRegisterCurrentState`, { paymentMethods })\n .then(data => {\n return {\n isOpen: data.isOpen,\n state: data.state,\n history: data.history\n }\n });\n }\n\n static registerMovement(request: RegisterCashRegisterMovementRequest): Promise {\n return ApiClient.post(`${this.baseCashRegisterUrl}/registerMovement`, request);\n }\n\n static openCashRegister(cashOpeningInfo: OpenCashRegisterRequest): Promise {\n return ApiClient.post(`${this.baseCashRegisterUrl}/openCashRegister`, cashOpeningInfo);\n }\n\n static closeCashRegister(closeCashRegisterRequest: CloseCashRegisterRequest): Promise {\n return ApiClient.post(`${this.baseCashRegisterUrl}/closeCashRegister`, closeCashRegisterRequest);\n }\n}\n","export class OpenCashRegisterRequest {\n initialCash: number;\n chargingUserId: string;\n chargingUserName: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.initialCash = x.initialCash;\n this.chargingUserId = x.chargingUserId;\n this.chargingUserName = x.chargingUserName;\n }\n else {\n this.initialCash = 0;\n this.chargingUserId = \"\";\n this.chargingUserName = \"\";\n }\n }\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { alertsActions } from \"../../../../redux/alerts-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport { selectAccountSettings, selectCashRegisterState, selectUserInfo } from \"../../../../redux/store\";\nimport { setCashRegisterFullState } from \"../../../../redux/cash-register-slice\";\n\nimport { CashRegisterMainProps } from \"./props\";\nimport CashRegisterIcon from \"../CashRegisterIcon\";\nimport OpenCashRegisterModal from \"../OpenCashRegisterModal\";\nimport { OpenCashRegisterFormData } from \"../../../../models/open-cash-register-form-data\";\nimport CashRegisterSidebar from \"../CashRegisterSidebar/cash-register-sidebar\";\nimport { PaymentsService } from \"../../../../api/payments-service\";\nimport { OpenCashRegisterRequest } from \"../../../../models/open-cash-register-request\";\nimport { CloseCashRegisterRequest } from \"../../../../models/close-cash-register-request\";\nimport { CashRegisterMovement } from \"../../../../models/cash-register-movement\";\nimport { CashRegisterMovementHistory } from \"../../../../models/cash-register-movement-history\";\nimport { CashRegisterCurrentStateModel } from \"../../../../models/interfaces/cash-register-current-state-model\";\nimport { PaymentMethodType } from \"../../../../models/enums/payment-method-type\";\nimport { CashRegisterMovementType } from \"../../../../models/enums/cash-register-movement-type\";\nimport { CashRegisterStateModel } from \"../../../../models/interfaces/cash-register-state-model\";\nimport { RegisterCashRegisterMovementRequest } from \"../../../../models/register-cash-register-movement-request\";\n\n\nexport default function CashRegisterMain(props: CashRegisterMainProps) {\n\n const {commonHubConnection} = props;\n\n const [refresh, setRefresh] = useState();\n const [isOpenCashRegisterModalOpen, setOpenCashRegisterModalOpen] = useState(false);\n const [isMainCashRegisterSidebarOpen, setMainCashRegisterSidebarOpen] = useState(false);\n const [openCashRegisterFormData, setOpenCashRegisterFormData] = useState(new OpenCashRegisterFormData());\n\n const cashRegisterCurrentState = useAppSelector(selectCashRegisterState);\n const isCashRegisterOpen = cashRegisterCurrentState.isOpen;\n const accountSettings = useAppSelector(selectAccountSettings);\n const currencyTemplate = accountSettings.currencyTemplate;\n const paymentMethods = accountSettings.paymentMethods.map(x => x.key);\n const userInfo = useAppSelector(selectUserInfo);\n\n const dispatch = useAppDispatch();\n const {enqueueAlert} = alertsActions;\n\n const {t} = useTranslation(\"general\");\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n\n fetchData();\n }, [refresh])\n\n async function loadData() {\n const cashRegisterState = await PaymentsService.getCashRegisterCurrentState(paymentMethods);\n dispatch(setCashRegisterFullState(cashRegisterState));\n }\n\n function setInitialCash(value: number) {\n setOpenCashRegisterFormData({...openCashRegisterFormData, initialCash: value})\n }\n\n async function handleCashIconButtonClick() {\n if (!isCashRegisterOpen) {\n const initialCash = await PaymentsService.getInitialCash();\n setInitialCash(initialCash)\n setOpenCashRegisterModalOpen(true);\n } else {\n await loadData();\n setMainCashRegisterSidebarOpen(true);\n }\n }\n\n function displaySuccessfulOpeningAlert() {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Cash register opened\"),\n description: t(\"Opened successfully\")\n })\n );\n }\n\n function displaySuccessfulCashClosingAlert() {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Cash register closed\"),\n description: t(\"Cash closing was successful\")\n })\n );\n }\n\n async function handleOpenCashRegisterSubmit() {\n await PaymentsService.openCashRegister(new OpenCashRegisterRequest({\n initialCash: openCashRegisterFormData.initialCash,\n chargingUserId: userInfo.userId,\n chargingUserName: userInfo.fullName,\n }))\n setOpenCashRegisterModalOpen(false);\n displaySuccessfulOpeningAlert()\n }\n\n commonHubConnection?.off(\"openCashRegister\")\n commonHubConnection?.off(\"closeCashRegister\")\n commonHubConnection?.off(\"registerMovement\")\n commonHubConnection?.off(\"updateMovementsInfo\")\n commonHubConnection?.on(\"openCashRegister\", openCashRegister)\n commonHubConnection?.on(\"closeCashRegister\", closeCashRegister)\n commonHubConnection?.on(\"registerMovement\", registerMovement)\n commonHubConnection?.on(\"updateMovementsInfo\", updateMovement)\n\n\n async function openCashRegister(initialCash: number, movement: CashRegisterMovement) {\n dispatch(setCashRegisterFullState(\n {\n isOpen: true,\n state: new CashRegisterCurrentStateModel(\n {\n initialCash: initialCash,\n cashNow: initialCash,\n }),\n history: new CashRegisterMovementHistory({movements: [movement]})\n }\n ))\n }\n\n async function closeCashRegister() {\n dispatch(setCashRegisterFullState(\n {\n isOpen: false,\n state: null,\n history: null\n }\n ))\n }\n \n async function registerMovement(cashRegisterMovement: CashRegisterMovement, paymentMethod: PaymentMethodType, isPayment: boolean) {\n \n let newState: CashRegisterStateModel = {...cashRegisterCurrentState };\n const movementAmount = cashRegisterMovement.amount;\n const movements = [...cashRegisterCurrentState.history!.movements]\n \n if (!isPayment) {\n switch (cashRegisterMovement.type) {\n case CashRegisterMovementType.CashOpening:\n return;\n case CashRegisterMovementType.Deposit:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n cashNow: cashRegisterCurrentState.state!.cashNow + movementAmount,\n depositByAdministrator: cashRegisterCurrentState.state!.depositByAdministrator + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n case CashRegisterMovementType.Withdrawal:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n cashNow: cashRegisterCurrentState.state!.cashNow - movementAmount,\n withdrawalByAdministrator: cashRegisterCurrentState.state!.withdrawalByAdministrator + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n }\n dispatch(setCashRegisterFullState(newState))\n return;\n }\n \n switch (paymentMethod) {\n case PaymentMethodType.Cash:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n paymentsReceived: cashRegisterCurrentState.state!.paymentsReceived + movementAmount,\n cashNow: cashRegisterCurrentState.state!.cashNow + movementAmount,\n cashPayments: cashRegisterCurrentState.state!.cashPayments + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n case PaymentMethodType.CreditCard:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n paymentsReceived: cashRegisterCurrentState.state!.paymentsReceived + movementAmount,\n creditCardPayments: cashRegisterCurrentState.state!.creditCardPayments + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n case PaymentMethodType.BankTransfer:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n paymentsReceived: cashRegisterCurrentState.state!.paymentsReceived + movementAmount,\n bankTransferPayments: cashRegisterCurrentState.state!.bankTransferPayments + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n case PaymentMethodType.Oxxo:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n paymentsReceived: cashRegisterCurrentState.state!.paymentsReceived + movementAmount,\n oxxoPayments: cashRegisterCurrentState.state!.oxxoPayments + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n case PaymentMethodType.MercadoPago:\n newState = {\n ...cashRegisterCurrentState,\n state: new CashRegisterCurrentStateModel({\n ...cashRegisterCurrentState.state,\n paymentsReceived: cashRegisterCurrentState.state!.paymentsReceived + movementAmount,\n mercadoPagoPayments: cashRegisterCurrentState.state!.mercadoPagoPayments + movementAmount\n }),\n history: new CashRegisterMovementHistory({ movements: [cashRegisterMovement].concat(cashRegisterCurrentState.history!.movements)})\n }\n break;\n }\n\n dispatch(setCashRegisterFullState(newState))\n return;\n }\n \n async function updateMovement() {\n await loadData()\n }\n\n async function handleCloseCashRegisterSubmit(closeCashRegisterRequest: CloseCashRegisterRequest) {\n\n await PaymentsService.closeCashRegister(closeCashRegisterRequest);\n\n displaySuccessfulCashClosingAlert();\n setMainCashRegisterSidebarOpen(false);\n }\n\n async function handleRegisterNewMovement(newMovementRequest: RegisterCashRegisterMovementRequest) {\n await PaymentsService.registerMovement(newMovementRequest);\n }\n\n const CashIcon = () =>\n \n\n return (\n
\n \n {\n !isCashRegisterOpen &&\n \n }\n {\n isCashRegisterOpen && cashRegisterCurrentState.state && cashRegisterCurrentState.history &&\n \n }\n
\n );\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ExternalLink = (props: any) => {\n \n const { color, style, viewBox, ...otherProps } = props;\n return (\n \n \n \n )\n};\n\nexport default ExternalLink;\n","import { useTranslation } from \"react-i18next\";\n\nimport { useAppSelector } from \"../../redux/hooks\";\nimport { selectAccountSettings } from \"../../redux/store\";\n\n\nexport default function useCustomerTerminology(value: string, ...terms: string[]): string {\n \n function applyInterpolation(arrayTerms: string[]) {\n let result = arrayTerms[0];\n for (let i = 0; i < arrayTerms.length - 1; i++) {\n let reg = new RegExp(\"\\\\{\\\\{\" + i + \"\\\\}\\\\}\", \"gm\");\n result = result.replace(reg, arrayTerms[i + 1]);\n }\n return result;\n }\n\n const { t } = useTranslation(['clinic_terminology_customer', 'clinic_terminology_patient']);\n\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const clinicTerminology = accountSettings.isClinicMode ? \"clinic_terminology_patient\" : \"clinic_terminology_customer\";\n let countInterpolationsInTargetString = ((value || '').match(/\\{[0-9]+}/g) || []).length;\n\n if (countInterpolationsInTargetString > terms.length) {\n throw new Error(\"The number of terms does not match the number of interpolations in the target string.\");\n }\n\n let arrayTerms = [];\n arrayTerms.push(value);\n\n terms.forEach((item, index, array) => {\n let terminology = t(item, { ns: clinicTerminology });\n arrayTerms.push(terminology);\n });\n\n return applyInterpolation(arrayTerms);\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles((theme) => ({\n title: {\n fontSize: 14,\n fontWeight: 700,\n fontFamily: \"Inter, sans-serif\",\n color: theme.colors.grey4,\n },\n}));\n","import React, { useEffect } from \"react\";\n\nimport { useHistory, useLocation } from \"react-router-dom\";\n\nimport { useTranslation } from \"react-i18next\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { useStyles } from \"./css\";\n\n\nexport interface NavTitle {\n label: string;\n path: string;\n}\n\n\nexport default function Title() {\n \n const classes = useStyles();\n \n const { t } = useTranslation([\"general\", \"nav\", \"sections\"]);\n \n const location = useLocation();\n \n const dispatch = useAppDispatch();\n const titleNav = useAppSelector(state => state.applicationInterface.title);\n\n const navTitles: NavTitle[] = [\n { label: t('Appts'), path: \"/appointments\" },\n { label: t('New appointment'), path: \"/appointments/new\" },\n { label: useCustomerTerminology(t(\"Customers\"), \"Customers\"), path: \"/customers\" },\n { label: t(\"Conversations\"), path: \"/whatsapp\" },\n { label: t(\"Massive sendings\"), path: \"/massive-sendings\" },\n { label: t('Settings'), path: \"/settings\" },\n { label: t('Reports'), path: \"/reports\" },\n ];\n\n useEffect(() => {\n const menuItem = navTitles.find(x => x.path === location.pathname);\n if (menuItem) {\n const titleUrl = menuItem.label || \"Clear\";\n dispatch(applicationInterfaceActions.updateTitle(titleUrl));\n }\n }, [location.pathname]);\n\n return (\n \n {titleNav}\n \n );\n};","import * as React from \"react\";\nimport { useEffect, useState } from \"react\";\nimport { useHistory, Link } from \"react-router-dom\";\nimport { useLocation } from 'react-router-dom';\n\nimport { useTranslation } from 'react-i18next';\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { deauthenticate } from \"../../../redux/authentication-slice\";\nimport { navbarActions } from '../../../redux/navbar-slice'\nimport { RootState, selectAccountSettings, selectCommonHubConnection, selectUserInfo } from \"../../../redux/store\";\nimport { resetUserInfo } from \"../../../redux/user-info-slice\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport AppBar from \"@material-ui/core/AppBar\";\nimport Toolbar from \"@material-ui/core/Toolbar\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport Drawer from \"@material-ui/core/Drawer\";\nimport List from \"@material-ui/core/List\";\nimport ListItem from \"@material-ui/core/ListItem\";\nimport ListItemIcon from \"@material-ui/core/ListItemIcon\";\nimport ListItemText from \"@material-ui/core/ListItemText\";\nimport MenuIcon from \"@material-ui/icons/Menu\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nimport { MenuIconSettings, MenuIconReports, MenuIconCustomer, MenuIconLogoClear, MenuIconPower, MenuIconWhatsapp, MegaphoneIcon, ConversationIcon, PlusIcon } from \"../../../assets/icons\";\nimport { Url } from \"../../../constants/url\";\nimport { useStyles } from \"./css\";\nimport { AuthenticationService } from \"../../../api/authentication-service\";\nimport NotificationBlock from \"../notifications/NotificationBlock\";\nimport AccountOverdueMessage from \"../../common/AccountOverdueMessage\";\nimport CashRegisterMain from \"../cash-register/CashRegisterMain\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { connect } from \"../../../redux/common-hub-slice\";\nimport ExternalLink from \"../../../assets/icons/ExternalLink\";\nimport Title from \"../Title\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\n\nexport interface NavBarMenuItem {\n id: number;\n icon: JSX.Element;\n label: string;\n url: string;\n isDisplayed: boolean;\n isParent?: boolean;\n parentId?: number;\n}\n\n\nexport default function NavBar() {\n \n const { t, i18n } = useTranslation([\"general\", \"nav\", \"sections\"]);\n const location = useLocation();\n\n const [isLocationInitialized, setIsLocationInitialized] = useState(false);\n const [isExternalLingHover, setIsExternalLinkHover] = useState(false);\n const [hoverItemId, seHoverItemId] = useState(-1);\n \n const titleNav = useAppSelector(state => state.applicationInterface.title);\n const externalContent = useAppSelector(state => state.navbar.externalContent);\n\n const dispatch = useAppDispatch();\n\n const conversationCounter = useAppSelector(state => state.navbar.conversationCounter)\n\n const showReferFriend = conversationCounter\n ? conversationCounter.hasReachedReferralThreshold\n : false;\n\n const userInfo = useAppSelector(selectUserInfo);\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const classes = useStyles();\n const history = useHistory();\n \n const [drawerOpen, setDrawerOpen] = useState(false);\n \n const version = \"1.12.4.1\";\n\n const toggleDrawer =\n (open: boolean) => (event: React.KeyboardEvent | React.MouseEvent) => {\n setDrawerOpen(open);\n };\n \n const accountNavBarMenu = [\n { id: 1, icon: , label: t('Appointments'), url: Url.Appointments.Main, isDisplayed: true },\n { id: 2, icon: , label: useCustomerTerminology(t(\"Customers\"), \"Customers\"), url: Url.Customers.Main, isDisplayed: userInfo.hasCustomerInfoVisible },\n { id: 3, isParent: true, icon: , label: \"WhatsApp\", url: \"\", isDisplayed: true },\n { id: 3.1, parentId: 3, icon: , label: t(\"Conversations\"), url: Url.WhatsApp.Main, isDisplayed: userInfo.hasAccessToWhatsAppConversationsAndNotifications },\n { id: 3.2, parentId: 3, icon: , label: t(\"Massive sendings\"), url: Url.WhatsApp.MassiveSendings, isDisplayed: true },\n { id: 4, icon: , label: t('Reports'), url: Url.Reports.Main, isDisplayed: userInfo.hasAccessToReports },\n { id: 5, icon: , label: t('Settings'), url: Url.Settings.Main, isDisplayed: userInfo.isAdministrator }\n ];\n \n const enterpriseNavBarMenu = [\n { id: 1, icon: , label: t('Appointments'), url: Url.Appointments.Main, isDisplayed: true },\n { id: 2, icon: , label: useCustomerTerminology(t(\"Customers\"), \"Customers\"), url: Url.Customers.Main, isDisplayed: userInfo.hasCustomerInfoVisible },\n { id: 3, isParent: true, icon: , label: \"WhatsApp\", url: \"\", isDisplayed: true },\n { id: 3.1, parentId: 3, icon: , label: t(\"Conversations\"), url: Url.WhatsApp.Main, isDisplayed: true },\n { id: 4, icon: , label: t('Reports'), url: Url.Reports.CustomReport, isDisplayed: userInfo.hasAccessToReports },\n { id: 5, icon: , label: t('Settings'), url: Url.EstablishmentSettings.General, isDisplayed: userInfo.isAdministrator }\n ];\n \n const navBarMenuItems: NavBarMenuItem[] = \n accountSettings.isEnterprise \n ? enterpriseNavBarMenu \n : accountNavBarMenu\n \n const clickMenuItem = (e: any, item: NavBarMenuItem) => {\n if (item.isParent) {\n e.preventDefault();\n } else {\n setDrawerOpen(false);\n history.push(item.url);\n }\n };\n const onClickHandleExternalLink = (e: any, item: NavBarMenuItem) => {\n e.stopPropagation();\n window.open(item.url, \"_blank\");\n };\n \n const onMouseHoverItem = (item: NavBarMenuItem) => {\n seHoverItemId(item.id);\n };\n const onMouseLeaveItem = () => {\n seHoverItemId(-1);\n };\n \n async function logOut() {\n await dispatch(resetUserInfo());\n await dispatch(deauthenticate());\n await AuthenticationService.logout();\n }\n \n useEffect(() => {\n if (isLocationInitialized) {\n dispatch(navbarActions.setExternalContent(null));\n } else {\n setIsLocationInitialized(true);\n }\n }, [location.pathname]);\n\n const commonHubConnection = useSelector(\n (state: RootState) => state.commonHub.connection\n );\n\n // unsubscribe\n commonHubConnection?.off(\"updateShowReferral\");\n // subscribe\n commonHubConnection?.on(\"updateShowReferral\",\n (accountId, hasReachedReferralThreshold) => handleShowReferralChange(accountId, hasReachedReferralThreshold)\n );\n dispatch(connect());\n\n function handleShowReferralChange(accountId: string, hasReachedReferralThreshold: boolean) {\n if (userInfo.accountId === accountId) {\n dispatch(navbarActions.setConversationCounter({...conversationCounter, hasReachedReferralThreshold }))\n }\n }\n\n return (\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n {conversationCounter !== null && showReferFriend && accountSettings.isEnterprise === false &&\n \n \n \n }\n \n \n \n \n \n \n
\n \n
\n
\n \n clear\n
\n {\n accountSettings.isEnterprise &&\n
\n {t(\"Enterprise account\")}\n
\n }\n
\n {t(\"Version\") + \" \" + version}\n
\n
\n {userInfo.fullName}\n
\n
\n {userInfo.email}\n
\n
\n \n \n {navBarMenuItems.filter(x => x.isDisplayed).map((item: NavBarMenuItem, index: number) => (\n \n
\n \n x.parentId === item.id).some(x => x.url === history.location.pathname)\n ? classes.childItemActive\n : null} \n ${history.location.pathname === item.url\n ? item.parentId ? classes.listSubItemActive : classes.listItemActive\n : item.parentId ? classes.listSubItem : classes.listItem}`,\n }}\n onMouseEnter={() => onMouseHoverItem(item)}\n onMouseLeave={() => onMouseLeaveItem()}\n onClick={(e) => clickMenuItem(e, item)}>\n \n \n {item.icon}\n \n \n \n {item.label}\n \n \n {!item.isParent && hoverItemId === item.id &&\n
setIsExternalLinkHover(true)}\n onMouseLeave={() => setIsExternalLinkHover(false)}\n onClick={(e) => onClickHandleExternalLink(e, item)}>\n {t(\"Open in new tab\")} } classes={{popper: classes.popper}}>\n
\n \n
\n
\n
\n }\n
\n
\n ))}\n
\n
\n
\n
{t(\"NavbarReferFriendTitle\")}
\n
{t(\"NavbarReferFriendDescription\")}
\n \n
\n
\n
\n \n \n \n \n \n \n \n \n \n \n
\n \n
\n
\n \n \n <div className={classes.externalContentPlaceholder}>\n {externalContent}\n </div>\n \n {\n accountSettings.isEnterprise === false\n ? <div className={classes.iconsBlock}>\n {\n accountSettings.isCashRegisterActivated && accountSettings.paymentsAndCollectionsEnabled &&\n <CashRegisterMain commonHubConnection={commonHubConnection}/>\n }\n <NotificationBlock commonHubConnection={commonHubConnection}/>\n </div> \n : null\n }\n </Toolbar>\n </AppBar>\n );\n \n};\n\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n height: 3,\n },\n colorPrimary: {\n backgroundColor: \"#C9CDD3\"\n },\n barColorPrimary: {\n backgroundColor: \"#6462F3\"\n },\n}));\n","import React from \"react\";\nimport Box from \"@material-ui/core/Box\";\nimport LinearProgress from '@material-ui/core/LinearProgress';\n\nimport { useStyles } from \"./css\";\n\nconst LoaderLine = () => {\n const classes = useStyles();\n \n return (\n <Box sx={{ width: '100%', position: 'fixed', top: 61, zIndex: 999}} className={classes.root}>\n <LinearProgress classes={{root: classes.root, colorPrimary: classes.colorPrimary, barColorPrimary: classes.barColorPrimary}} />\n </Box>\n );\n};\n\nexport default LoaderLine;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (progress: number) => makeStyles((theme) => ({\n root: {\n display: \"flex\",\n\n zIndex: 3000,\n\n position: \"absolute\",\n left: 20,\n bottom: 14,\n\n width: 282,\n height: 117,\n\n borderRadius: 10,\n\n boxShadow: \"0px 4px 4px rgba(0,0,0,0.1)\",\n },\n side: {\n alignSelf: \"flex-start\",\n\n height: \"100%\",\n width: 5,\n\n backgroundColor: theme.colors.clearMain,\n\n borderBottomLeftRadius: 10,\n borderTopLeftRadius: 10,\n },\n container: {\n display: \"flex\",\n flexDirection: \"column\",\n\n width: 277,\n },\n header: {\n alignSelf: \"flex-start\",\n\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n\n height: 17,\n width: \"100%\",\n\n backgroundColor: theme.colors.grey1,\n\n borderTopRightRadius: 10,\n },\n dndIconContainer: {\n marginLeft: 3,\n },\n closeIconContainer: {\n marginRight: 8,\n },\n closeIconButton: {\n alignSelf: \"flex-start\",\n },\n closeIcon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n contentContainer: {\n display: \"flex\",\n\n width: 277,\n height: 100,\n\n backgroundColor: theme.colors.white,\n\n borderBottomRightRadius: 10,\n },\n mainIconContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n paddingLeft: 14,\n paddingRight: 14,\n\n height: \"100%\",\n },\n mainIconBackground: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 28,\n height: 28,\n\n borderRadius: 14,\n backgroundColor: theme.colors.clearMain\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n\n width: 221,\n\n paddingTop: 8,\n paddingBottom: 12,\n paddingRight: 16,\n },\n title: {\n marginBottom: 4,\n\n ...theme.typography.txtBody2,\n fontWeight: 700,\n color: theme.colors.grey5,\n },\n text: {\n marginBottom: 13,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n downloadProgressBar: {\n display: \"block\",\n width: 200,\n height: 6,\n backgroundColor: theme.colors.grey1,\n\n borderRadius: 10\n },\n downloadProgressBarEmpty: {\n height: \"100%\",\n },\n downloadProgressBarProgress: {\n display: \"block\",\n\n height: \"100%\",\n width: `${progress}%`,\n\n backgroundColor: theme.colors.clearGreen,\n borderRadius: 10\n }\n}));\n\nexport default useStyles;","import React, { useEffect, useState } from 'react';\n\nimport Draggable from 'react-draggable';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { fileDownloadActions } from \"../../../redux/file-downloader-slice\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\n\nimport useStyles from \"./css\";\nimport { CrossIcon, DownloadCloudIcon, DraggableIcon } from \"../../../assets/icons\";\nimport { Color } from \"../../../constants/colors\";\nimport { Position } from \"../../../models/interfaces/position\";\nimport axios from \"axios\";\n\n\nexport default function FileDownloadProvider() {\n\n const state = useAppSelector(store => store.fileDownloader);\n const {\n setProgress,\n finishDownload,\n cancelDownload\n } = fileDownloadActions;\n const { enqueueAlert } = alertsActions;\n\n const dispatch = useAppDispatch();\n\n const { downloadProgress, fileName, mimeType, isDownloading, callback } = state;\n\n const { t } = useTranslation(\"general\");\n const classes = useStyles(downloadProgress)();\n\n const [position, setPosition] = useState<Position>({ x: 0, y: 0 })\n const cancelTokenSource = axios.CancelToken.source();\n\n function dispatchProgress(progress: number) {\n dispatch(setProgress(progress))\n }\n\n function onDownloadFinished() {\n dispatch(finishDownload())\n }\n\n function onDownloadCanceled() {\n cancelTokenSource.cancel()\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Download canceled\")\n }));\n }\n\n function onDragStop(event: any, data: any) {\n const { x, y } = data;\n setPosition({ x, y })\n }\n\n useEffect(() => {\n if (callback === null) return;\n\n callback(dispatchProgress, cancelTokenSource.token).then(blob => {\n const url = window.URL.createObjectURL(new Blob([blob], {\n type: mimeType\n }));\n const link = document.createElement('a');\n link.href = url;\n link.setAttribute('download', `${fileName}`);\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Downloaded report\"),\n description: fileName\n }));\n })\n .finally(() => onDownloadFinished())\n }, [callback])\n\n return (\n isDownloading\n ?\n <Draggable\n position={position}\n enableUserSelectHack={false}\n onStop={onDragStop}\n handle={'#modalDragHandler'}\n >\n <div\n className={classes.root}\n style={{ zIndex: 7000 }}\n >\n <div className={classes.side}/>\n <div className={classes.container}>\n\n <div className={classes.header}>\n\n <div\n className={classes.dndIconContainer}\n id={'modalDragHandler'}\n >\n <DraggableIcon style={{ width: 16, height: 16, color: Color.gray4, cursor: \"grab\" }}/>\n </div>\n\n <div className={classes.closeIconContainer}>\n <div className={classes.closeIcon} onClick={onDownloadCanceled}>\n <CrossIcon style={{ width: 12, height: 12 }} color={Color.gray4} viewBox=\"0 0 16 16\"/>\n </div>\n </div>\n\n </div>\n\n <div className={classes.contentContainer}>\n <div className={classes.mainIconContainer}>\n <div className={classes.mainIconBackground}>\n <DownloadCloudIcon style={{ width: 24, height: 24 }} color={Color.white} viewBox=\"0 0 24 24\"/>\n </div>\n </div>\n <div className={classes.content}>\n <div className={classes.title}>{t(\"Downloading in progress!\")}</div>\n <div className={classes.text}>{t(\"YouCanContinueUsingOtherScreens\")}</div>\n\n <div className={classes.downloadProgressBar}>\n <span\n className={downloadProgress > 0 ? classes.downloadProgressBarProgress : classes.downloadProgressBarEmpty}/>\n </div>\n </div>\n </div>\n\n </div>\n </div>\n </Draggable>\n : null\n )\n}","import * as React from \"react\";\nimport Container from \"@material-ui/core/Container\";\n\nimport NavBar from \"./navbar/NavBar\";\nimport { useAppDispatch, useAppSelector } from \"../redux/hooks\";\nimport { useEffect } from \"react\";\nimport { applicationInterfaceActions } from \"../redux/application-interface-slice\";\nimport { useLocation } from \"react-router-dom\";\nimport LoaderLine from \"./navbar/LoaderLine\";\nimport Fade from \"@material-ui/core/Fade\";\nimport { Url } from \"../constants/url\";\nimport FileDownloadProvider from \"./common/FileDownloadProvider\";\n\nexport default function Layout(props: any) {\n \n const dispatch = useAppDispatch();\n const location = useLocation();\n const isAccountOverdue = useAppSelector(state => state.applicationInterface.isAccountOverdue);\n const isWideLayout = useAppSelector(state => state.applicationInterface.isWideLayout);\n const showLoaderIsActive = useAppSelector(state => state.navbar.showLoader);\n const maxWidth = isWideLayout ? false : undefined;\n const wideScreenUrls = [Url.Reports.Main, Url.Reports.CustomReport];\n \n useEffect(() => {\n if (!wideScreenUrls.includes(location.pathname)) {\n dispatch(applicationInterfaceActions.updateIsWideLayout(false));\n }\n }, [location.pathname]);\n \n return (\n <div>\n <NavBar/>\n <Fade\n in={showLoaderIsActive ?? false}\n style={{\n transitionDelay: '800ms',\n zIndex: 999,\n position: \"absolute\",\n width: \"100%\",\n top: 0\n }}\n \n >\n <span>\n <LoaderLine />\n </span>\n </Fade>\n <div style={{ position: \"relative\", top: isWideLayout ? 61 : isAccountOverdue ? 113 : 80 }}>\n <Container maxWidth={maxWidth}>{props.children}</Container>\n </div>\n <FileDownloadProvider />\n </div>\n );\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n label: {\n display: \"block\",\n color: theme.colors.grey6,\n fontFamily: \"Inter, sans-serif\",\n fontSize: 12,\n lineHeight: \"15px\",\n fontWeight: \"bold\",\n },\n rememberMeLabel: {\n color: \"#899198\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: 500,\n },\n inputBox: {\n marginTop: \"25px\"\n },\n textInput: {\n marginTop: \"8px\",\n width: \"370px\",\n },\n input: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: 12,\n lineHeight: \"14px\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: \"5px\",\n \"& input\": {\n height: 24,\n backgroundColor: \"#F6F6F6 !important\"\n }\n },\n inputNormalWeight: {\n fontWeight: \"normal\"\n },\n inputBoldWeight: {\n fontWeight: \"bold\"\n },\n forgetLink: {\n color: theme.colors.grey4,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n \"&:hover\": {\n color: theme.colors.grey4\n },\n },\n utilities: {\n display: \"flex\",\n alignItems: \"center\",\n marginTop: \"25px\",\n marginBottom: \"33px\"\n },\n form: {\n marginTop: 33\n }\n}));\n\nexport default useStyles;","function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\n\nvar _ref2 = /*#__PURE__*/React.createElement(\"g\", {\n clipPath: \"url(#clip0_9943_7689)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M52.096 35.2729C50.4106 33.6021 49.514 31.2629 49.4062 28.2554L49.3632 26.6012L49.4062 24.9471C49.514 21.9396 50.4106 19.6004 52.096 17.9295C53.7813 16.2587 56.1104 15.4233 59.0834 15.4233C61.0856 15.4233 62.7818 15.7817 64.1722 16.4985C65.5626 17.2153 66.6008 18.1041 67.2867 19.1651C67.9275 20.0981 68.3086 21.1822 68.3915 22.308C68.4099 22.4305 68.3964 22.5557 68.3521 22.6715C68.3079 22.7873 68.2344 22.89 68.1387 22.9696C67.9418 23.1366 67.6898 23.2258 67.4308 23.2203H65.4287C65.2069 23.2362 64.9861 23.178 64.8017 23.0549C64.6129 22.8693 64.4702 22.6428 64.3846 22.3932C63.911 21.0699 63.2436 20.1259 62.3824 19.5611C61.5212 18.9964 60.4367 18.714 59.1289 18.714C57.4048 18.714 56.0354 19.2445 55.0209 20.3055C54.0063 21.3665 53.4569 22.9864 53.3726 25.1651L53.3322 26.6539L53.3726 28.0599C53.4569 30.2654 53.9996 31.892 55.0006 32.9396C56.0017 33.9872 57.3778 34.511 59.1289 34.511C60.435 34.511 61.5195 34.2278 62.3824 33.6614C63.2453 33.095 63.9127 32.1509 64.3846 30.8293C64.4743 30.5758 64.6163 30.3436 64.8017 30.1476C64.9802 30.0106 65.2037 29.9445 65.4287 29.9621H67.4308C67.6929 29.9572 67.9467 30.0533 68.1387 30.2303C68.2336 30.3149 68.3063 30.4213 68.3504 30.5401C68.3944 30.6589 68.4085 30.7866 68.3915 30.912C68.3015 32.0293 67.9208 33.1044 67.2867 34.0323C66.5116 35.1742 65.447 36.0938 64.2 36.699C62.8231 37.4158 61.1201 37.7742 59.091 37.7742C56.1079 37.7742 53.7763 36.9404 52.096 35.2729ZM72.6183 37.0925C72.5282 37.0034 72.4575 36.8969 72.4105 36.7797C72.3635 36.6624 72.3413 36.5368 72.3453 36.4107V8.9521C72.3411 8.8259 72.363 8.70019 72.4098 8.58275C72.4566 8.46531 72.5272 8.35864 72.6172 8.26935C72.7073 8.18007 72.8149 8.11007 72.9334 8.06369C73.0518 8.01731 73.1786 7.99553 73.3059 7.99972H75.2651C75.3926 7.99479 75.5197 8.01605 75.6385 8.06216C75.7573 8.10828 75.8652 8.17825 75.9555 8.26769C76.0457 8.35713 76.1163 8.4641 76.1628 8.58188C76.2093 8.69967 76.2307 8.82571 76.2258 8.9521V36.4107C76.2304 36.5369 76.2087 36.6627 76.162 36.7802C76.1153 36.8977 76.0447 37.0043 75.9545 37.0935C75.8643 37.1827 75.7566 37.2524 75.6379 37.2984C75.5193 37.3443 75.3924 37.3655 75.2651 37.3606H73.3059C73.1788 37.3653 73.0522 37.3439 72.9339 37.2978C72.8155 37.2516 72.7081 37.1817 72.6183 37.0925ZM83.2132 35.1476C81.5025 33.3982 80.5638 31.0072 80.397 27.9747L80.354 26.5686L80.397 25.2027C80.5908 22.2253 81.543 19.8544 83.2536 18.0899C84.9642 16.3255 87.2259 15.4433 90.0388 15.4433C93.1246 15.4433 95.5161 16.4149 97.2132 18.3581C98.9104 20.3013 99.7589 22.9279 99.7589 26.2378V26.9496C99.7632 27.0758 99.7412 27.2015 99.6944 27.319C99.6476 27.4364 99.577 27.5431 99.487 27.6323C99.3969 27.7216 99.2893 27.7916 99.1708 27.838C99.0524 27.8844 98.9256 27.9062 98.7983 27.902H84.3583V28.2729C84.393 29.9329 84.9716 31.5366 86.0066 32.8418C86.4812 33.4484 87.0941 33.9347 87.795 34.261C88.4959 34.5873 89.2649 34.7443 90.0388 34.719C91.3179 34.719 92.3679 34.4684 93.1887 33.9671C93.8936 33.5605 94.5105 33.0196 95.0038 32.3757C95.1558 32.1449 95.3465 31.9414 95.5675 31.7742C95.7861 31.6896 96.0211 31.6545 96.2551 31.6714H98.2978C98.5251 31.6639 98.7477 31.7377 98.9247 31.8794C99.0089 31.9502 99.0755 32.0392 99.1193 32.1396C99.1632 32.24 99.1831 32.3491 99.1775 32.4584C99.1775 33.0649 98.7949 33.795 98.0298 34.6488C97.1263 35.5997 96.0329 36.3534 94.8192 36.8619C93.3264 37.5046 91.7116 37.8217 90.0843 37.7917C87.2141 37.78 84.9238 36.8986 83.2132 35.1476ZM95.7874 25.0373V24.9145C95.7874 23.0131 95.2667 21.4617 94.2251 20.2604C93.1836 19.059 91.7881 18.46 90.0388 18.4634C88.2877 18.4634 86.9049 19.0624 85.8903 20.2604C84.8757 21.4584 84.3701 23.0097 84.3735 24.9145V25.0373H95.7874ZM105.965 36.9471C104.857 36.447 103.898 35.6697 103.184 34.6915C102.517 33.7706 102.162 32.6626 102.173 31.5285C102.173 29.709 102.932 28.2128 104.448 27.0398C105.965 25.8669 108.016 25.1025 110.602 24.7466L116.815 23.8769V22.6889C116.815 19.8769 115.189 18.4709 111.936 18.4709C110.713 18.4709 109.712 18.7215 108.933 19.2228C108.212 19.6743 107.611 20.2916 107.181 21.0223C107.125 21.225 107.017 21.4098 106.868 21.5586C106.721 21.676 106.535 21.735 106.347 21.724H104.552C104.309 21.7214 104.078 21.6247 103.906 21.4547C103.735 21.2846 103.637 21.0547 103.634 20.8143C103.663 20.1459 103.976 19.394 104.575 18.5586C105.173 17.7232 106.1 16.9922 107.356 16.3656C108.608 15.7474 110.151 15.4375 111.984 15.4358C115.099 15.4358 117.338 16.1593 118.701 17.6062C120.065 19.0532 120.746 20.8527 120.744 23.0047V36.4032C120.748 36.5291 120.726 36.6544 120.679 36.7716C120.633 36.8888 120.563 36.9954 120.473 37.0849C120.383 37.1739 120.276 37.2437 120.158 37.2898C120.039 37.3359 119.913 37.3575 119.786 37.3531H117.847C117.72 37.3573 117.593 37.3356 117.475 37.2893C117.357 37.2431 117.249 37.1733 117.159 37.0843C117.069 36.9953 116.998 36.889 116.951 36.7718C116.905 36.6547 116.882 36.5292 116.886 36.4032V34.6238C116.194 35.5739 115.278 36.3408 114.217 36.8569C113.049 37.4634 111.561 37.7666 109.755 37.7666C108.445 37.779 107.15 37.4989 105.965 36.9471V36.9471ZM115.081 32.9145C116.234 31.7449 116.81 30.0565 116.81 27.8493V26.699L111.972 27.4032C109.997 27.6789 108.509 28.1401 107.51 28.7867C106.51 29.4333 106.01 30.2537 106.008 31.2478C105.989 31.7547 106.107 32.2574 106.348 32.7044C106.59 33.1514 106.947 33.5267 107.383 33.7917C108.355 34.4007 109.488 34.7103 110.637 34.6814C112.445 34.6764 113.927 34.0874 115.081 32.9145V32.9145ZM125.967 37.0925C125.877 37.0033 125.807 36.8967 125.76 36.7794C125.714 36.6622 125.692 36.5367 125.696 36.4107V16.8619C125.69 16.6018 125.787 16.3496 125.967 16.1601C126.053 16.0654 126.16 15.9904 126.278 15.9402C126.397 15.89 126.525 15.8658 126.654 15.8694H128.573C128.841 15.8694 129.098 15.975 129.288 16.163C129.478 16.351 129.584 16.606 129.584 16.8719V18.6789C130.724 16.8042 132.67 15.8669 135.424 15.8669H137.052C137.179 15.8623 137.306 15.8838 137.425 15.9301C137.543 15.9764 137.651 16.0464 137.741 16.1358C137.831 16.2252 137.901 16.3321 137.947 16.4497C137.994 16.5673 138.015 16.6931 138.01 16.8193V18.5035C138.015 18.6265 137.994 18.7492 137.947 18.8634C137.901 18.9775 137.83 19.0804 137.74 19.1651C137.552 19.3336 137.305 19.4234 137.052 19.4158H134.532C133.033 19.4158 131.854 19.8502 130.992 20.719C130.131 21.5879 129.701 22.7666 129.701 24.2554V36.4133C129.704 36.5411 129.679 36.6681 129.629 36.7857C129.578 36.9033 129.503 37.0088 129.407 37.095C129.215 37.2719 128.962 37.3681 128.7 37.3631H126.654C126.527 37.3675 126.4 37.3457 126.282 37.2991C126.164 37.2525 126.056 37.1822 125.967 37.0925V37.0925ZM52.096 35.2729C50.4106 33.6021 49.514 31.2629 49.4062 28.2554L49.3632 26.6012L49.4062 24.9471C49.514 21.9396 50.4106 19.6004 52.096 17.9295C53.7813 16.2587 56.1104 15.4233 59.0834 15.4233C61.0856 15.4233 62.7818 15.7817 64.1722 16.4985C65.5626 17.2153 66.6008 18.1041 67.2867 19.1651C67.9275 20.0981 68.3086 21.1822 68.3915 22.308C68.4099 22.4305 68.3964 22.5557 68.3521 22.6715C68.3079 22.7873 68.2344 22.89 68.1387 22.9696C67.9418 23.1366 67.6898 23.2258 67.4308 23.2203H65.4287C65.2069 23.2362 64.9861 23.178 64.8017 23.0549C64.6129 22.8693 64.4702 22.6428 64.3846 22.3932C63.911 21.0699 63.2436 20.1259 62.3824 19.5611C61.5212 18.9964 60.4367 18.714 59.1289 18.714C57.4048 18.714 56.0354 19.2445 55.0209 20.3055C54.0063 21.3665 53.4569 22.9864 53.3726 25.1651L53.3322 26.6539L53.3726 28.0599C53.4569 30.2654 53.9996 31.892 55.0006 32.9396C56.0017 33.9872 57.3778 34.511 59.1289 34.511C60.435 34.511 61.5195 34.2278 62.3824 33.6614C63.2453 33.095 63.9127 32.1509 64.3846 30.8293C64.4743 30.5758 64.6163 30.3436 64.8017 30.1476C64.9802 30.0106 65.2037 29.9445 65.4287 29.9621H67.4308C67.6929 29.9572 67.9467 30.0533 68.1387 30.2303C68.2336 30.3149 68.3063 30.4213 68.3504 30.5401C68.3944 30.6589 68.4085 30.7866 68.3915 30.912C68.3015 32.0293 67.9208 33.1044 67.2867 34.0323C66.5116 35.1742 65.447 36.0938 64.2 36.699C62.8231 37.4158 61.1201 37.7742 59.091 37.7742C56.1079 37.7742 53.7763 36.9404 52.096 35.2729V35.2729ZM72.6183 37.0925C72.5282 37.0034 72.4575 36.8969 72.4105 36.7797C72.3635 36.6624 72.3413 36.5368 72.3453 36.4107V8.9521C72.3411 8.8259 72.363 8.70019 72.4098 8.58275C72.4566 8.46531 72.5272 8.35864 72.6172 8.26935C72.7073 8.18007 72.8149 8.11007 72.9334 8.06369C73.0518 8.01731 73.1786 7.99553 73.3059 7.99972H75.2651C75.3926 7.99479 75.5197 8.01605 75.6385 8.06216C75.7573 8.10828 75.8652 8.17825 75.9555 8.26769C76.0457 8.35713 76.1163 8.4641 76.1628 8.58188C76.2093 8.69967 76.2307 8.82571 76.2258 8.9521V36.4107C76.2304 36.5369 76.2087 36.6627 76.162 36.7802C76.1153 36.8977 76.0447 37.0043 75.9545 37.0935C75.8643 37.1827 75.7566 37.2524 75.6379 37.2984C75.5193 37.3443 75.3924 37.3655 75.2651 37.3606H73.3059C73.1788 37.3653 73.0522 37.3439 72.9339 37.2978C72.8155 37.2516 72.7081 37.1817 72.6183 37.0925V37.0925ZM83.2132 35.1476C81.5025 33.3982 80.5638 31.0072 80.397 27.9747L80.354 26.5686L80.397 25.2027C80.5908 22.2253 81.543 19.8544 83.2536 18.0899C84.9642 16.3255 87.2259 15.4433 90.0388 15.4433C93.1246 15.4433 95.5161 16.4149 97.2132 18.3581C98.9104 20.3013 99.7589 22.9279 99.7589 26.2378V26.9496C99.7632 27.0758 99.7412 27.2015 99.6944 27.319C99.6476 27.4364 99.577 27.5431 99.487 27.6323C99.3969 27.7216 99.2893 27.7916 99.1708 27.838C99.0524 27.8844 98.9256 27.9062 98.7983 27.902H84.3583V28.2729C84.393 29.9329 84.9716 31.5366 86.0066 32.8418C86.4812 33.4484 87.0941 33.9347 87.795 34.261C88.4959 34.5873 89.2649 34.7443 90.0388 34.719C91.3179 34.719 92.3679 34.4684 93.1887 33.9671C93.8936 33.5605 94.5105 33.0196 95.0038 32.3757C95.1558 32.1449 95.3465 31.9414 95.5675 31.7742C95.7861 31.6896 96.0211 31.6545 96.2551 31.6714H98.2978C98.5251 31.6639 98.7477 31.7377 98.9247 31.8794C99.0089 31.9502 99.0755 32.0392 99.1193 32.1396C99.1632 32.24 99.1831 32.3491 99.1775 32.4584C99.1775 33.0649 98.7949 33.795 98.0298 34.6488C97.1263 35.5997 96.0329 36.3534 94.8192 36.8619C93.3264 37.5046 91.7116 37.8217 90.0843 37.7917C87.2141 37.78 84.9238 36.8986 83.2132 35.1476ZM95.7874 25.0373V24.9145C95.7874 23.0131 95.2667 21.4617 94.2251 20.2604C93.1836 19.059 91.7881 18.46 90.0388 18.4634C88.2877 18.4634 86.9049 19.0624 85.8903 20.2604C84.8757 21.4584 84.3701 23.0097 84.3735 24.9145V25.0373H95.7874ZM105.965 36.9471C104.857 36.447 103.898 35.6697 103.184 34.6915C102.517 33.7706 102.162 32.6626 102.173 31.5285C102.173 29.709 102.932 28.2128 104.448 27.0398C105.965 25.8669 108.016 25.1025 110.602 24.7466L116.815 23.8769V22.6889C116.815 19.8769 115.189 18.4709 111.936 18.4709C110.713 18.4709 109.712 18.7215 108.933 19.2228C108.212 19.6743 107.611 20.2916 107.181 21.0223C107.125 21.225 107.017 21.4098 106.868 21.5586C106.721 21.676 106.535 21.735 106.347 21.724H104.552C104.309 21.7214 104.078 21.6247 103.906 21.4547C103.735 21.2846 103.637 21.0547 103.634 20.8143C103.663 20.1459 103.976 19.394 104.575 18.5586C105.173 17.7232 106.1 16.9922 107.356 16.3656C108.608 15.7474 110.151 15.4375 111.984 15.4358C115.099 15.4358 117.338 16.1593 118.701 17.6062C120.065 19.0532 120.746 20.8527 120.744 23.0047V36.4032C120.748 36.5291 120.726 36.6544 120.679 36.7716C120.633 36.8888 120.563 36.9954 120.473 37.0849C120.383 37.1739 120.276 37.2437 120.158 37.2898C120.039 37.3359 119.913 37.3575 119.786 37.3531H117.847C117.72 37.3573 117.593 37.3356 117.475 37.2893C117.357 37.2431 117.249 37.1733 117.159 37.0843C117.069 36.9953 116.998 36.889 116.951 36.7718C116.905 36.6547 116.882 36.5292 116.886 36.4032V34.6238C116.194 35.5739 115.278 36.3408 114.217 36.8569C113.049 37.4634 111.561 37.7666 109.755 37.7666C108.445 37.779 107.15 37.4989 105.965 36.9471V36.9471ZM115.081 32.9145C116.234 31.7449 116.81 30.0565 116.81 27.8493V26.699L111.972 27.4032C109.997 27.6789 108.509 28.1401 107.51 28.7867C106.51 29.4333 106.01 30.2537 106.008 31.2478C105.989 31.7547 106.107 32.2574 106.348 32.7044C106.59 33.1514 106.947 33.5267 107.383 33.7917C108.355 34.4007 109.488 34.7103 110.637 34.6814C112.445 34.6764 113.927 34.0874 115.081 32.9145V32.9145ZM125.967 37.0925C125.877 37.0033 125.807 36.8967 125.76 36.7794C125.714 36.6622 125.692 36.5367 125.696 36.4107V16.8619C125.69 16.6018 125.787 16.3496 125.967 16.1601C126.053 16.0654 126.16 15.9904 126.278 15.9402C126.397 15.89 126.525 15.8658 126.654 15.8694H128.573C128.841 15.8694 129.098 15.975 129.288 16.163C129.478 16.351 129.584 16.606 129.584 16.8719V18.6789C130.724 16.8042 132.67 15.8669 135.424 15.8669H137.052C137.179 15.8623 137.306 15.8838 137.425 15.9301C137.543 15.9764 137.651 16.0464 137.741 16.1358C137.831 16.2252 137.901 16.3321 137.947 16.4497C137.994 16.5673 138.015 16.6931 138.01 16.8193V18.5035C138.015 18.6265 137.994 18.7492 137.947 18.8634C137.901 18.9775 137.83 19.0804 137.74 19.1651C137.552 19.3336 137.305 19.4234 137.052 19.4158H134.532C133.033 19.4158 131.854 19.8502 130.992 20.719C130.131 21.5879 129.701 22.7666 129.701 24.2554V36.4133C129.704 36.5411 129.679 36.6681 129.629 36.7857C129.578 36.9033 129.503 37.0088 129.407 37.095C129.215 37.2719 128.962 37.3681 128.7 37.3631H126.654C126.527 37.3675 126.4 37.3457 126.282 37.2991C126.164 37.2525 126.056 37.1822 125.967 37.0925V37.0925Z\",\n fill: \"#323947\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M38.69 26.8273L27.7311 15.9601C27.551 15.7818 27.3068 15.6816 27.0523 15.6816C26.7978 15.6816 26.5536 15.7818 26.3735 15.9601L24.2803 18.0378C24.1002 18.2161 23.8561 18.3162 23.6016 18.3162C23.347 18.3162 23.1029 18.2161 22.9228 18.0378L20.8296 15.9601C20.6495 15.7818 20.4054 15.6816 20.1508 15.6816C19.8963 15.6816 19.6522 15.7818 19.4721 15.9601V15.9601L8.28061 27.0553C8.10077 27.2339 7.99976 27.4759 7.99976 27.7283C7.99976 27.9806 8.10077 28.2226 8.28061 28.4012L19.2547 39.2684C19.4348 39.4466 19.6789 39.5468 19.9334 39.5468C20.188 39.5468 20.4321 39.4466 20.6122 39.2684V39.2684L22.2453 37.6493C22.3341 37.5604 22.4399 37.4899 22.5564 37.4417C22.6729 37.3936 22.7978 37.3688 22.9241 37.3688C23.0503 37.3688 23.1753 37.3936 23.2918 37.4417C23.4083 37.4899 23.514 37.5604 23.6028 37.6493V37.6493L25.6834 39.732C25.8635 39.9103 26.1076 40.0105 26.3622 40.0105C26.6167 40.0105 26.8608 39.9103 27.0409 39.732L38.69 28.1806C38.8698 28.0021 38.9708 27.76 38.9708 27.5077C38.9708 27.2554 38.8698 27.0133 38.69 26.8348V26.8273ZM19.2547 35.3686L12.2268 28.4012C12.047 28.2226 11.946 27.9806 11.946 27.7283C11.946 27.4759 12.047 27.2339 12.2268 27.0553V27.0553L19.4721 19.8598C19.6522 19.6815 19.8963 19.5814 20.1508 19.5814C20.4054 19.5814 20.6495 19.6815 20.8296 19.8598V19.8598L20.956 19.9851C21.045 20.0734 21.1156 20.1781 21.1637 20.2933C21.2119 20.4086 21.2367 20.5321 21.2367 20.6568C21.2367 20.7816 21.2119 20.9051 21.1637 21.0203C21.1156 21.1356 21.045 21.2403 20.956 21.3285L19.0499 23.2182L14.4995 27.7295L18.112 31.3085L19.2547 32.4237C19.3433 32.5126 19.4488 32.5831 19.5651 32.6312C19.6814 32.6793 19.8062 32.7041 19.9322 32.7041C20.0582 32.7041 20.183 32.6793 20.2992 32.6312C20.4155 32.5831 20.5211 32.5126 20.6097 32.4237V32.4237L23.4967 29.5616L26.3735 26.6994C26.4625 26.6112 26.5681 26.5413 26.6844 26.4935C26.8006 26.4458 26.9252 26.4212 27.051 26.4212C27.1769 26.4212 27.3015 26.4458 27.4177 26.4935C27.5339 26.5413 27.6396 26.6112 27.7285 26.6994V26.6994L27.8549 26.8247C28.0348 27.0033 28.1358 27.2453 28.1358 27.4977C28.1358 27.75 28.0348 27.992 27.8549 28.1706L20.9434 35.0227L20.597 35.3661C20.5082 35.4546 20.4027 35.5248 20.2864 35.5728C20.1701 35.6207 20.0455 35.6454 19.9195 35.6454C19.7936 35.6454 19.6689 35.6207 19.5527 35.5728C19.4364 35.5248 19.3308 35.4546 19.242 35.3661L19.2547 35.3686ZM31.8037 28.1756C31.9835 27.9971 32.0845 27.755 32.0845 27.5027C32.0845 27.2503 31.9835 27.0083 31.8037 26.8298L27.051 22.1305L20.5996 28.5265C20.5106 28.6151 20.4048 28.6854 20.2883 28.7333C20.1718 28.7813 20.0469 28.806 19.9208 28.806C19.7947 28.806 19.6698 28.7813 19.5533 28.7333C19.4368 28.6854 19.331 28.6151 19.242 28.5265V28.5265L19.1156 28.4012C19.0267 28.313 18.9561 28.2083 18.9079 28.093C18.8598 27.9778 18.835 27.8542 18.835 27.7295C18.835 27.6048 18.8598 27.4812 18.9079 27.366C18.9561 27.2507 19.0267 27.146 19.1156 27.0578V27.0578L25.5747 20.6593L26.3811 19.8623C26.4701 19.7741 26.5757 19.7042 26.692 19.6564C26.8082 19.6087 26.9328 19.5841 27.0586 19.5841C27.1844 19.5841 27.309 19.6087 27.4253 19.6564C27.5415 19.7042 27.6472 19.7741 27.7361 19.8623L34.764 26.8298C34.8529 26.918 34.9235 27.0227 34.9717 27.1379C35.0198 27.2532 35.0446 27.3767 35.0446 27.5014C35.0446 27.6262 35.0198 27.7497 34.9717 27.8649C34.9235 27.9802 34.8529 28.0849 34.764 28.1731V28.1731L27.0409 35.8247C26.8608 36.003 26.6167 36.1032 26.3622 36.1032C26.1076 36.1032 25.8635 36.003 25.6834 35.8247V35.8247L25.557 35.6994C25.468 35.6112 25.3974 35.5065 25.3493 35.3913C25.3011 35.276 25.2763 35.1525 25.2763 35.0278C25.2763 34.903 25.3011 34.7795 25.3493 34.6642C25.3974 34.549 25.468 34.4443 25.557 34.3561V34.3561L31.8037 28.1756Z\",\n fill: \"#6462F3\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_9943_7689\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 130,\n height: 32,\n fill: \"white\",\n transform: \"translate(8 8)\"\n})));\n\nvar SvgLogo = function SvgLogo(_ref) {\n var svgRef = _ref.svgRef,\n title = _ref.title,\n props = _objectWithoutProperties(_ref, [\"svgRef\", \"title\"]);\n\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n width: 146,\n height: 48,\n viewBox: \"0 0 146 48\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgLogo, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/logo.f8a89a94.svg\";\nexport { ForwardRef as ReactComponent };","function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\n\nvar _ref2 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M117.479 68H146.399C144.399 73.84 140.289 78.14 135.669 81.91C131.049 85.68 125.599 87.73 119.769 88.91C117.769 89.33 117.459 88.63 117.479 86.91C117.529 80.62 117.489 74.31 117.479 68Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M48.966 59.0005H42.546C42.2404 58.9932 41.9397 59.0789 41.6838 59.2462C41.4279 59.4134 41.2288 59.6545 41.1129 59.9373C40.9969 60.2202 40.9695 60.5316 41.0344 60.8304C41.0992 61.1291 41.2532 61.4012 41.476 61.6105L47.886 67.9605C48.0966 68.172 48.3651 68.3164 48.6577 68.3753C48.9503 68.4343 49.2538 68.4052 49.5299 68.2918C49.8059 68.1784 50.0422 67.9857 50.2088 67.7381C50.3754 67.4904 50.4649 67.199 50.466 66.9005L50.516 60.5205C50.5174 60.318 50.4781 60.1172 50.4003 59.9302C50.3225 59.7432 50.2079 59.5737 50.0633 59.4319C49.9187 59.2901 49.747 59.1788 49.5585 59.1047C49.37 59.0306 49.1685 58.9952 48.966 59.0005V59.0005Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M50.0001 3.57051V18.6805C49.995 19.3895 50.2017 20.0839 50.5938 20.6747C50.9858 21.2655 51.5454 21.7258 52.2007 21.9965C52.8561 22.2672 53.5773 22.3361 54.272 22.1943C54.9668 22.0525 55.6033 21.7064 56.1001 21.2005L71.1001 6.20051C71.6042 5.7055 71.9495 5.07171 72.0923 4.37981C72.235 3.68791 72.1687 2.96918 71.9017 2.3151C71.6347 1.66102 71.1791 1.10116 70.593 0.706796C70.0068 0.312427 69.3166 0.101378 68.6101 0.100507L53.6101 0.000508122C53.1372 -0.00749368 52.6675 0.0790844 52.2285 0.255158C51.7895 0.431232 51.3901 0.693248 51.0538 1.02582C50.7175 1.3584 50.4511 1.75482 50.2701 2.19181C50.0892 2.6288 49.9974 3.09754 50.0001 3.57051V3.57051Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M3 173.5H51.5C51.5 152.237 34.263 135 13 135H0V170.5C0 172.157 1.34315 173.5 3 173.5Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref6 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M85 93H114C116.209 93 118 94.7909 118 97V124.731C118 125.432 117.432 126 116.731 126V126C99.2064 126 85 111.794 85 94.2692V93Z\",\n fill: \"#BDC7F8\"\n});\n\nvar SvgOrnamentLeft = function SvgOrnamentLeft(_ref) {\n var svgRef = _ref.svgRef,\n title = _ref.title,\n props = _objectWithoutProperties(_ref, [\"svgRef\", \"title\"]);\n\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n width: 147,\n height: 174,\n viewBox: \"0 0 147 174\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5, _ref6);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgOrnamentLeft, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/ornament-left.fa486ee4.svg\";\nexport { ForwardRef as ReactComponent };","function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\n\nvar _ref2 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M28.92 68H2.67029e-05C2.00003 73.84 6.11002 78.14 10.73 81.91C15.35 85.68 20.8 87.73 26.63 88.91C28.63 89.33 28.94 88.63 28.92 86.91C28.87 80.62 28.91 74.31 28.92 68Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M97.4334 59.0005H103.853C104.159 58.9932 104.46 59.0789 104.716 59.2462C104.971 59.4134 105.171 59.6545 105.287 59.9373C105.403 60.2202 105.43 60.5316 105.365 60.8304C105.3 61.1291 105.146 61.4012 104.923 61.6105L98.5134 67.9605C98.3028 68.172 98.0343 68.3164 97.7417 68.3753C97.4491 68.4343 97.1456 68.4052 96.8696 68.2918C96.5935 68.1784 96.3572 67.9857 96.1906 67.7381C96.024 67.4904 95.9345 67.199 95.9334 66.9005L95.8834 60.5205C95.882 60.318 95.9214 60.1172 95.9991 59.9302C96.0769 59.7432 96.1915 59.5737 96.3361 59.4319C96.4807 59.2901 96.6524 59.1788 96.8409 59.1047C97.0294 59.0306 97.2309 58.9952 97.4334 59.0005V59.0005Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M96.3993 3.57051V18.6805C96.4044 19.3895 96.1977 20.0839 95.8056 20.6747C95.4136 21.2655 94.854 21.7258 94.1987 21.9965C93.5433 22.2672 92.8221 22.3361 92.1274 22.1943C91.4327 22.0525 90.7961 21.7064 90.2993 21.2005L75.2993 6.20051C74.7953 5.7055 74.4499 5.07171 74.3071 4.37981C74.1644 3.68791 74.2307 2.96918 74.4977 2.3151C74.7647 1.66102 75.2203 1.10116 75.8064 0.706796C76.3926 0.312427 77.0828 0.101378 77.7893 0.100507L92.7893 0.000508122C93.2622 -0.00749368 93.732 0.0790844 94.1709 0.255158C94.6099 0.431232 95.0093 0.693248 95.3456 1.02582C95.6819 1.3584 95.9483 1.75482 96.1293 2.19181C96.3102 2.6288 96.4021 3.09754 96.3993 3.57051V3.57051Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M143.399 173.5H94.8994C94.8994 152.237 112.136 135 133.399 135H146.399V170.5C146.399 172.157 145.056 173.5 143.399 173.5Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref6 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M61.3994 93H32.3994C30.1903 93 28.3994 94.7909 28.3994 97V124.731C28.3994 125.432 28.9677 126 29.6686 126V126C47.1931 126 61.3994 111.794 61.3994 94.2692V93Z\",\n fill: \"#BDC7F8\"\n});\n\nvar SvgOrnamentRight = function SvgOrnamentRight(_ref) {\n var svgRef = _ref.svgRef,\n title = _ref.title,\n props = _objectWithoutProperties(_ref, [\"svgRef\", \"title\"]);\n\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n width: 147,\n height: 174,\n viewBox: \"0 0 147 174\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5, _ref6);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgOrnamentRight, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/ornament-right.f6c98c0c.svg\";\nexport { ForwardRef as ReactComponent };","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n container: {\n height: \"100%\",\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\"\n },\n page: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\"\n },\n wrapper: {\n position: \"relative\",\n width: \"100%\",\n maxWidth: 996,\n minWidth: 812,\n height: 556,\n minHeight: 315,\n display: \"flex\",\n justifyContent: \"center\",\n backgroundColor: \"#fff\",\n boxShadow: \"15px 30px 80px #F2F3F7\"\n },\n formWrapper: {\n display: \"flex\",\n flexDirection: \"column\",\n width: \"370px\",\n justifyContent: \"center\"\n },\n logo: {\n display: \"flex\",\n alignSelf: \"center\",\n width: 186,\n height: 80,\n justifyContent: \"center\",\n alignItems: \"center\"\n },\n ornamentLeft: {\n display: \"block\",\n position: \"absolute\",\n bottom: 0,\n left: 0\n },\n ornamentRight: {\n display: \"block\",\n position: \"absolute\",\n bottom: 0,\n right: 0\n },\n formFooter: {\n position: \"absolute\",\n bottom: 37,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"11px\",\n lineHeight: \"13px\",\n color: theme.colors.grey4,\n \"& a\": {\n color: theme.colors.grey4,\n fontWeight: \"bold\"\n }\n },\n backButton: {\n position: \"absolute\",\n left: 40,\n top: 20,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n width: 89,\n height: 40,\n color: theme.colors.clearMain,\n zIndex: 1,\n \"&:focus\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n },\n \"&:hover\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n }, \n \"&:visited\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n },\n \"&:link\" : {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n }, \n \"&:active\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n }\n },\n backButtonText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: 15,\n },\n backButtonIcon: {\n fontSize: 12,\n lineHeight: 15,\n }\n}));\n\nexport default useStyles;","import React from \"react\";\nimport { Link } from \"react-router-dom\";\n\nimport { Box, Typography } from \"@material-ui/core\";\nimport { ArrowBackIos } from \"@material-ui/icons\";\n\nimport { useTranslation } from 'react-i18next';\n\nimport { ReactComponent as Logo } from \"../../../assets/images/logo.svg\";\nimport { ReactComponent as OrnamentLeft } from \"../../../assets/images/ornament-left.svg\";\nimport { ReactComponent as OrnamentRight } from \"../../../assets/images/ornament-right.svg\";\nimport useStyles from \"./css\";\nimport { AuthenticationLayoutProps } from \"./props\";\n\nimport { Url } from \"../../../constants/url\";\n\nexport default function AuthenticationLayout(props: AuthenticationLayoutProps) {\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const getCurrentYear = () =>{\n return new Date().getFullYear();\n }\n\n return (\n <div className={classes.container}>\n <div className={classes.page}>\n <div className={classes.wrapper}>\n {props.backButton &&\n <Link to={Url.Authentication.Login} className={classes.backButton}>\n <Typography className={classes.backButtonText}><ArrowBackIos className={classes.backButtonIcon} /> {t(\"Back\")}</Typography>\n </Link>\n }\n <div className={classes.formWrapper}>\n {!props.hiddenLogo &&\n <div className={classes.logo}>\n <Logo />\n </div>\n }\n <div>\n {props.children}\n </div>\n </div>\n <div className={classes.ornamentLeft}>\n <OrnamentLeft />\n </div>\n <div className={classes.ornamentRight}>\n <OrnamentRight />\n </div>\n </div>\n <div className={classes.formFooter}>\n © {getCurrentYear()} {t('ClearCheck and its affiliate')}. | {t('Visit us at')}: <a href=\"https://www.somosclear.com\" target=\"_blank\">somosclear.com</a>\n </div>\n </div>\n </div>\n )\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n label: {\n display: \"block\",\n color: theme.colors.grey6,\n fontFamily: \"Inter, sans-serif\",\n fontSize: 12,\n lineHeight: \"15px\",\n fontWeight: \"bold\",\n alignSelf: \"flex-start\"\n },\n required: {\n color: theme.colors.clearMain\n },\n textInput: {\n marginTop: \"8px\",\n width: \"100%\",\n \"&:hover .MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline\": {\n borderColor: theme.colors.grey4\n },\n \"& .MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline\": {\n borderColor: theme.colors.clearMain\n }\n },\n input: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: 12,\n lineHeight: \"14px\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: \"5px\",\n \"& input\": {\n height: 24,\n backgroundColor: \"#F6F6F6 !important\"\n }\n },\n inputNormalWeight: {\n fontWeight: \"normal\"\n },\n inputBoldWeight: {\n fontWeight: \"bold\"\n }\n}));\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { TextField, Typography } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { EmailInputProps } from \"./props\";\n\n\nexport default function EmailInput(props: EmailInputProps) {\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n const { value, onChangeHandler, placeholder, error, required } = props;\n return (\n <>\n <Typography className={classes.label}>\n {t(\"Email\")} {required && <span className={classes.required}>*</span>}\n </Typography>\n <TextField\n className={classes.textInput}\n variant=\"outlined\"\n value={value}\n onChange={onChangeHandler}\n placeholder={placeholder}\n InputProps={{\n className: `${classes.input} ${value.length > 0 ? classes.inputBoldWeight : classes.inputNormalWeight}`,\n }}\n error={error?.isError}\n helperText={error?.message}\n />\n </>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n label: {\n display: \"block\",\n color: theme.colors.grey6,\n fontFamily: \"Inter, sans-serif\",\n fontSize: 12,\n lineHeight: \"15px\",\n fontWeight: \"bold\",\n },\n required: {\n color: theme.colors.clearMain\n },\n textInput: {\n marginTop: \"8px\",\n width: \"100%\",\n \"&:hover .MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline\": {\n borderColor: theme.colors.grey4\n },\n \"& .MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline\": {\n borderColor: theme.colors.clearMain\n }\n },\n input: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: 12,\n lineHeight: \"14px\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: \"5px\",\n \"& input\": {\n height: 24,\n backgroundColor: \"#F6F6F6 !important\"\n }\n },\n inputNormalWeight: {\n fontWeight: \"normal\"\n },\n inputBoldWeight: {\n fontWeight: \"bold\"\n },\n inputSuccess: {\n color: theme.colors.clearGreen,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: 12,\n lineHeight: \"14px\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: \"5px\",\n \"& input\": {\n height: 24,\n backgroundColor: \"#F6F6F6 !important\"\n }\n },\n outline: {\n borderWidth: \"1px\"\n },\n outlineSuccess: {\n borderWidth: \"1px\",\n borderColor: theme.colors.clearGreen\n }\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { InputAdornment, TextField, Typography } from \"@material-ui/core\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport { Visibility, VisibilityOff } from \"@material-ui/icons\";\n\nimport useStyles from \"./css\";\nimport { PasswordInputProps } from \"./props\";\n\n\nexport default function PasswordInput(props: PasswordInputProps) {\n \n const classes = useStyles();\n\n const [isPasswordVisible, setPasswordVisibility] = useState<boolean>(false);\n\n function handlePasswordVisibility() {\n setPasswordVisibility(!isPasswordVisible);\n }\n\n function handleMouseDownPassword(event: any) {\n event.preventDefault()\n }\n \n const TogglePasswordVisibilityIcon =\n <IconButton\n aria-label=\"toggle password visibility\"\n onClick={handlePasswordVisibility}\n onMouseDown={handleMouseDownPassword}\n edge=\"end\"\n >\n {isPasswordVisible ? <Visibility/> : <VisibilityOff/>}\n </IconButton>\n \n return (\n <>\n <Typography className={classes.label}>\n {props.label} {props.required && <span className={classes.required}>*</span>}\n </Typography>\n <TextField\n className={classes.textInput}\n variant=\"outlined\"\n value={props.value}\n onChange={props.onChangeHandler}\n placeholder={props.placeholder}\n type={isPasswordVisible ? \"text\" : \"password\"}\n InputProps={{\n classes: {\n root: props.success ? classes.inputSuccess : `${classes.input} ${props.value.length > 0 ? classes.inputBoldWeight : classes.inputNormalWeight}`,\n notchedOutline: props.success ? classes.outlineSuccess : classes.outline\n },\n endAdornment: (\n <InputAdornment position=\"end\">\n {TogglePasswordVisibilityIcon}\n </InputAdornment>\n )\n }}\n />\n </>\n );\n}","// export const nameRegex = new RegExp(\"^([a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+((?: [a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+)?)+(?: [a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+)?)$\");\nexport const NameRegex = /^([a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+((?: [a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+)?)+(?: [a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+)?)$/;\nexport const MobileRegex = /^\\d{10}$/;\nexport const EmailRegex = /^(([^<>()[\\]\\\\.,;:\\s@\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/;\nexport const AlphanumericRegex = /^(?!.*[ ]{2})[a-zA-Z ¡!¿?)(.,;:áéíóúÁÉÍÓÚäëïöüÄËÏÖÜÑñ1234567890]{2,80}$/; // Alphanumeric\nexport const AlphanumericExtendedRegex = /^(?!.*[ ]{2})[a-zA-Z ¡!¿?@#$%^&*)(.,;:áéíóúÁÉÍÓÚäëïöüÄËÏÖÜ1234567890]{2,80}$/; // Alphanumeric with some symbols\nexport const CurrencyRegex = /^(\\d+(\\.\\d{0,2})?|\\.?\\d{1,2})$/;\nexport const NameRegexV2 = /^[^\\d!@#$%^&*<>?`]*$/;\nexport const LetterSpaceRegex = /^[a-zA-Z\\s]*$/;\nexport const MultipleSpacesNameRegex = /^\\s*([a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+((?:\\s{0,}[a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+)?)+(?:\\s{0,}[a-zA-Z'-.À-ÿ\\u00f1\\u00d1]+)?)( *)$/;\nexport const URLRegex = /[(http(s)?):\\/\\/(www\\.)?a-zA-Z0-9@:%._\\+~#=]{2,256}\\.[a-z]{2,6}\\b([-a-zA-Z0-9@:%_\\+.~#?&//=]*)/ig;\nexport const MassiveSendingUrlRegex = /(https?:\\/\\/(?:www\\.|(?!www))[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9]\\.[^\\s]{2,}|www\\.[a-zA-Z0-9][a-zA-Z0-9-]+[a-zA-Z0-9]\\.[^\\s]{2,}|https?:\\/\\/(?:www\\.|(?!www))[a-zA-Z0-9]+\\.[^\\s]{2,}|www\\.[a-zA-Z0-9]+\\.[^\\s]{2,})/ig;\n\n","export enum AppointmentTimeIntervalGapMinute {\n Five = 5,\n Ten = 10,\n Fifteen = 15,\n Twenty = 20,\n Thirty = 30,\n Sixty = 60,\n Ninety = 90,\n HundredTwenty = 120\n}","export enum SchedulerBlockDurationMinute {\n Five = 5,\n Ten = 10,\n Fifteen = 15,\n Thirty = 30,\n Sixty = 60,\n Ninety = 90\n}","import { TerminologyType } from \"./enums/terminology-type\";\n\nexport class Terminology {\n terminologyType: TerminologyType;\n singularForm: string;\n pluralForm: string;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.terminologyType = x.terminologyType;\n this.singularForm = x.singularForm;\n this.pluralForm = x.pluralForm;\n }\n else {\n this.terminologyType = 0;\n this.singularForm = \"\";\n this.pluralForm = \"\";\n }\n }\n}","import { AppointmentTimeIntervalGapMinute } from \"./enums/appointment-time-interval-gap-minute\";\nimport { SchedulerBlockDurationMinute } from \"./enums/scheduler-block-duration-minute\";\n\nexport class AccountScheduleSectionSettingsModel {\n accountId: string;\n hasMultipleAppointments: boolean;\n scheduleSimultaneousServicesEnabled: boolean;\n gapBetweenTimeIntervals: AppointmentTimeIntervalGapMinute;\n schedulerBlockDurationMinutes: SchedulerBlockDurationMinute;\n \n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.accountId = x.accountId;\n this.hasMultipleAppointments = x.hasMultipleAppointments;\n this.scheduleSimultaneousServicesEnabled = x.scheduleSimultaneousServicesEnabled;\n this.gapBetweenTimeIntervals = x.gapBetweenTimeIntervals;\n this.schedulerBlockDurationMinutes = x.schedulerBlockDurationMinutes;\n } else {\n this.accountId = \"\";\n this.hasMultipleAppointments = false;\n this.scheduleSimultaneousServicesEnabled = false;\n this.gapBetweenTimeIntervals = AppointmentTimeIntervalGapMinute.Thirty;\n this.schedulerBlockDurationMinutes = SchedulerBlockDurationMinute.Thirty;\n }\n }\n}\n ","export enum TreatmentDocumentSize {\n HalfLetter = 1,\n Letter,\n Legal\n}","export class EstablishmentCertification {\n id?: string;\n accountId?: string;\n imageS3Key?: string;\n fileName?: string;\n order: number;\n\n\n constructor(x?: EstablishmentCertification) {\n if (typeof x === \"object\" && x !== null) {\n this.id = x.id || \"\";\n this.accountId = x.accountId || \"\";\n this.imageS3Key = x.imageS3Key || \"\";\n this.fileName = x.fileName || \"\";\n this.order = x.order || 0;\n }\n else {\n this.id = \"\";\n this.accountId = \"\";\n this.imageS3Key = \"\";\n this.fileName = \"\";\n this.order = 0;\n }\n }\n}\n","import { TreatmentDocumentSize } from \"./enums/treatment-document-size\";\nimport { TreatmentDocumentFieldSetting } from \"./treatment-document-field-setting\";\n\nexport class TreatmentDocumentFieldSettingsModel {\n documentSize: TreatmentDocumentSize;\n logoIsEnabled: boolean;\n logoUrl: string | null;\n logoFile: File | null;\n fieldSettings: TreatmentDocumentFieldSetting[];\n shouldRemoveLogo: boolean;\n specialistJobPositionName: string;\n specialistPhoneNumberIso: string;\n specialistPhoneNumberBody: string;\n accountPhoneNumberIso: string;\n accountPhoneNumberBody: string;\n accountAddress: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.documentSize = x.documentSize;\n this.logoIsEnabled = x.logoIsEnabled;\n this.logoUrl = x.logoUrl;\n this.logoFile = x.logoFile === undefined ? null : x.logoFile;\n this.fieldSettings = x.fieldSettings;\n this.shouldRemoveLogo = x.shouldRemoveLogo;\n this.specialistJobPositionName = x.specialistJobPositionName;\n this.specialistPhoneNumberIso = x.specialistPhoneNumberIso;\n this.specialistPhoneNumberBody = x.specialistPhoneNumberBody;\n this.accountPhoneNumberIso = x.accountPhoneNumberIso;\n this.accountPhoneNumberBody = x.accountPhoneNumberBody;\n this.accountAddress = x.accountAddress;\n }\n else {\n this.documentSize = TreatmentDocumentSize.Letter;\n this.logoIsEnabled = false;\n this.logoUrl = null;\n this.logoFile = null;\n this.fieldSettings = [];\n this.shouldRemoveLogo = false;\n this.specialistJobPositionName = \"\";\n this.specialistPhoneNumberIso = \"\";\n this.specialistPhoneNumberBody = \"\";\n this.accountPhoneNumberIso = \"\";\n this.accountPhoneNumberBody = \"\";\n this.accountAddress = \"\";\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport { AccountSettingsModel } from \"../models/interfaces/account-settings-model\";\nimport { TerminologyType } from \"../models/enums/terminology-type\";\nimport { Terminology } from \"../models/terminology\";\nimport { AccountScheduleSectionSettingsModel } from \"../models/account-schedule-section-settings-model\";\nimport { EstablishmentCertification } from \"../models/establishment-certification\";\nimport { TreatmentDocumentFieldSettingsModel } from \"../models/treatment-document-field-settings-model\";\nimport { EstablishmentSettingsModel } from \"../models/interfaces/establishment-settings-model\";\n\nexport class AccountService {\n private static baseUrl: string = \"/account\";\n\n static getAccountSettings(): Promise<AccountSettingsModel> {\n return ApiClient.get(`${this.baseUrl}/getAccountSettings`).then(\n (data) => data.accountSettings\n );\n }\n\n static getEstablishmentSettings(establishmentAccountId: string): Promise<EstablishmentSettingsModel> {\n return ApiClient.get(`${this.baseUrl}/GetEstablishmentSettings?AccountId=${establishmentAccountId}`).then(\n (data) => data.establishmentSettings\n );\n }\n\n static async getAccountScheduleSectionSettings(establishmentAccountId?: string): Promise<AccountScheduleSectionSettingsModel> {\n var endpoint = `${this.baseUrl}/GetAccountScheduleSectionSettings`;\n\n if (establishmentAccountId)\n endpoint += `?AccountId=${establishmentAccountId}`;\n\n return await ApiClient.get(endpoint)\n .then((data) => new AccountScheduleSectionSettingsModel(data));\n }\n\n static async updateAccountScheduleSectionSettings(request: AccountScheduleSectionSettingsModel): Promise<AccountScheduleSectionSettingsModel> {\n return await ApiClient.put(`${this.baseUrl}/UpdateAccountScheduleSectionSettings`, request)\n .then((data) => new AccountScheduleSectionSettingsModel(data));\n }\n\n static getAccountCountryCode(establishmentAccountId?: string): Promise<string> {\n let endpoint = `${this.baseUrl}/getcountrycode`;\n if (establishmentAccountId) {\n endpoint += `?accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint,)\n .then((data) => data.countryCode);\n }\n\n static getAccountOverdue(): Promise<string> {\n return ApiClient.get(`${this.baseUrl}/getaccountoverdue`,)\n .then((data) => data.isAccountOverdue);\n }\n\n static getAccountSubdomain(establishmentAccountId?: string): Promise<string> {\n let urlEndpoint = !!establishmentAccountId\n ? `${this.baseUrl}/getBusinessNameUrl?EstablishmentAccountId=${establishmentAccountId}`\n : `${this.baseUrl}/getBusinessNameUrl`;\n\n return ApiClient.get(urlEndpoint).then(\n (data) => {\n return data.businessNameUrl;\n });\n }\n\n static getAccountLanguage(): Promise<string> {\n return ApiClient.get(`${this.baseUrl}/getaccountlanguage`,)\n .then((data) => data.languageCode);\n }\n\n static getAccountTerminology(type: TerminologyType, establishmentAccountId?: string): Promise<Terminology> {\n let endpoint = `${this.baseUrl}/getaccountterminology?TerminologyType=${type}`;\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint,)\n .then((data) => new Terminology(data.terminology));\n }\n\n static updateAccountTerminology(terminology: Terminology, establishmentAccountId?: string): Promise<Terminology> {\n const request = { \n accountId: establishmentAccountId,\n terminologyType: terminology.terminologyType,\n singularForm: terminology.singularForm,\n pluralForm: terminology.pluralForm\n }; \n return ApiClient.post(`${this.baseUrl}/updateaccountterminology`, request)\n .then((data) => new Terminology(data.terminology));\n }\n\n static async addEstablishmentCertification(certification: EstablishmentCertification) {\n const endpoint = `${this.baseUrl}/addestablishmentcertification`;\n\n const request: any = {\n imageS3Key: certification.imageS3Key,\n fileName: certification.fileName,\n order: certification.order\n };\n\n if (certification.accountId) {\n request.accountId = certification.accountId;\n }\n\n return ApiClient.post(endpoint, request)\n .then(data => {\n return new EstablishmentCertification(data.establishmentCertification)\n });\n }\n\n static deleteEstablishmentCertification(certification: EstablishmentCertification): Promise<EstablishmentCertification> {\n let endpoint = `${this.baseUrl}/deleteestablishmentcertification?id=${certification.id}`;\n\n if (certification.accountId) {\n endpoint += `&accountId=${certification.accountId}`;\n }\n\n return ApiClient.remove(endpoint)\n .then(data => {\n return new EstablishmentCertification(data.establishmentCertification)\n });\n }\n\n static async getTreatmentDocumentFieldSettings(): Promise<TreatmentDocumentFieldSettingsModel> {\n return ApiClient.get(`${this.baseUrl}/GetTreatmentDocumentFieldSettings`)\n .then((data) => new TreatmentDocumentFieldSettingsModel(data));\n }\n\n static async updateTreatmentDocumentFieldSettings(request: TreatmentDocumentFieldSettingsModel): Promise<boolean> {\n const formData = new FormData();\n\n formData.append('DocumentSize', request.documentSize.toString());\n formData.append('LogoIsEnabled', request.logoIsEnabled ? 'true' : 'false');\n formData.append('ShouldRemoveLogo', request.shouldRemoveLogo ? 'true' : 'false');\n\n if (request.logoFile) {\n formData.append('LogoFile', request.logoFile, request.logoFile.name);\n }\n\n formData.append(\"TreatmentDocumentFieldSettingsJsonString\", JSON.stringify(request.fieldSettings));\n\n return ApiClient.put(`${this.baseUrl}/UpdateTreatmentDocumentFieldSettings`, formData)\n .then((data) => data.succeeded);\n }\n}\n","import React, { useState } from 'react';\nimport { Link, useHistory } from \"react-router-dom\";\nimport { useTranslation } from 'react-i18next';\n\nimport { useGoogleReCaptcha } from \"react-google-recaptcha-v3\";\n\nimport { useDispatch } from 'react-redux';\nimport { authenticate } from \"../../../redux/authentication-slice\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\n\nimport useStyles from \"./css\";\nimport { AuthenticationService } from \"../../../api/authentication-service\";\nimport { ILoginState, ILoginValidationState } from \"./props\";\nimport { Url } from \"../../../constants/url\"\nimport AuthenticationLayout from \"../AuthenticationLayout\";\nimport EmailInput from \"../EmailInput\";\nimport PasswordInput from \"../PasswordInput\";\nimport { EmailRegex } from '../../../constants/validator';\nimport { AccountService } from \"../../../api/account-service\";\nimport ButtonWithSpinner from '../../common/ButtonWithSpinner';\nimport { ButtonPropsBorderRadius } from '../../../models/enums/button-props-border-radius';\nimport { ButtonPropsColor } from '../../../models/enums/button-props-color';\n\n\nexport default function Login() {\n\n const classes = useStyles();\n \n const history = useHistory();\n \n const isEnterprise = window.location.hostname.includes(\"enterprise\");\n \n const dispatch = useDispatch();\n const { enqueueAlert } = alertsActions;\n\n const { t, i18n } = useTranslation([\"general\", \"nav\"]);\n\n const { executeRecaptcha } = useGoogleReCaptcha();\n\n const [loginState, setLoginState] = useState<ILoginState>({\n email: \"\",\n password: \"\"\n });\n\n function handleEmailChange(event: any) {\n setLoginState({...loginState, email: event.target.value});\n }\n\n function handlePasswordChange(event: any) {\n setLoginState({...loginState, password: event.target.value});\n }\n\n function validate() {\n return EmailRegex.test(loginState.email) && loginState.password.length > 0;\n }\n\n function displayAlert() {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t('Incorrect email and/or password. Please try again.'),\n })\n );\n }\n \n async function submitLogin() {\n if (!validate()) {\n displayAlert();\n return;\n }\n\n if (!executeRecaptcha) {\n console.log(\"no recaptcha\");\n return;\n }\n const token = await executeRecaptcha('login');\n if (!token) return;\n\n const { email, password } = loginState;\n\n function setLocaleAndRedirect(language: string){\n localStorage.setItem('locale', language);\n i18n.changeLanguage(language).finally(() => {\n dispatch(applicationInterfaceActions.updateLocale(language));\n dispatch(authenticate());\n history.push(Url.Appointments.Main);\n });\n }\n\n function requestLocaleAndRedirect(){\n AccountService.getAccountLanguage()\n .then(language => {\n setLocaleAndRedirect(language);\n })\n .catch((resp) => {\n const language = process.env.REACT_APP_DEFAULT_LANGUAGE ?? 'es';\n setLocaleAndRedirect(language);\n return Promise.reject(resp);\n })\n }\n\n if (isEnterprise) {\n return AuthenticationService.loginEnterprise(email, password, token).then(requestLocaleAndRedirect, displayAlert)\n } else {\n return AuthenticationService.login(email, password, token).then(requestLocaleAndRedirect, displayAlert)\n }\n }\n\n const LogInButton =\n <ButtonWithSpinner\n width={370}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"Log in\")}\n onClick={submitLogin}\n disabled={loginState.email.length === 0 || loginState.password.length === 0}\n />\n\n return (\n <AuthenticationLayout>\n <div className={classes.form}>\n <EmailInput\n value={loginState.email}\n placeholder={t(\"Enter your email address\")}\n onChangeHandler={handleEmailChange}\n />\n <div className={classes.inputBox}>\n <PasswordInput\n value={loginState.password}\n label={t(\"Password\")}\n placeholder={t(\"Enter your password here\")}\n onChangeHandler={handlePasswordChange}\n />\n </div>\n <div className={classes.utilities}>\n <Link to=\"/recovery\" className={classes.forgetLink}>{t('Forgot your password?')}</Link>\n </div>\n {LogInButton}\n </div>\n </AuthenticationLayout>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n form: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"100%\"\n },\n formHeader: {\n marginBottom: \"27px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\"\n },\n formText: {\n marginTop: \"27px\",\n marginBottom: \"48px\",\n \n fontFamily: \"Roboto\", \n fontStyle: \"normal\", \n fontWeight: \"normal\", \n fontSize: \"14px\", \n lineHeight: \"18px\",\n alignItems: \"center\", \n textAlign: \"center\", \n color: \"#6A6E72\"\n },\n formTextLine: {\n ...theme.typography.txtBody1\n },\n formTextLineBold: {\n fontWeight: \"bold\"\n },\n sendButton: {\n marginTop: 22,\n width: \"100%\",\n borderRadius: 51,\n padding: \"9px 16px\"\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (blockHeight: number) => makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\",\n alignItems: \"center\",\n width: \"100%\",\n minHeight: blockHeight,\n border: \"1px solid #36CE91\",\n borderRadius: 5\n },\n icon: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n width: \"50px\",\n height: \"50px\",\n border: \"1px solid #36CE91\",\n borderRadius: \"25px\",\n color: \"#36CE91\"\n },\n header: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"16px\",\n lineHeight: \"19px\",\n textAlign: \"center\",\n color: \"#26292B\"\n },\n text: {\n display: \"flex\",\n alignItems: \"center\",\n textAlign: \"center\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: \"#676767\",\n margin: \"0 34px 0 34px\"\n }\n}));\n\nexport default useStyles;","import React from \"react\";\n\nimport { Check } from \"@material-ui/icons\";\nimport { Typography } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { SuccessBlockProps } from \"./props\";\n\n\nexport default function SuccessBlock(props: SuccessBlockProps) {\n\n const { headerMessage, textMessage, blockHeight } = props;\n const classes = useStyles(blockHeight)();\n \n return (\n <div className={classes.root}>\n <div className={classes.icon}>\n <Check />\n </div>\n <Typography className={classes.header}>{headerMessage}</Typography>\n <Typography className={classes.text}>{textMessage}</Typography>\n </div>\n );\n}","import React, { useState } from \"react\";\n\nimport { useGoogleReCaptcha } from \"react-google-recaptcha-v3\";\n\nimport { Button, Typography } from \"@material-ui/core\";\n\nimport AuthenticationLayout from \"../AuthenticationLayout\";\nimport useStyles from \"./css\";\nimport EmailInput from \"../EmailInput\";\nimport SuccessBlock from \"../SuccessBlock\";\nimport { AuthenticationService } from \"../../../api/authentication-service\";\nimport { useTranslation, Trans } from \"react-i18next\";\nimport { EmailRegex } from \"../../../constants/validator\";\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { AxiosResponse } from \"axios\";\n\n\nexport default function Recovery() {\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n const isEnterprise = window.location.hostname.includes(\"enterprise\");\n\n const { executeRecaptcha } = useGoogleReCaptcha();\n \n const [email, setEmail] = useState<string>(\"\");\n \n const [completed, setCompleted] = useState<boolean>(false);\n \n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n \n \n const handleEmailChange = (event : any) => {\n setEmail(event.target.value);\n }\n\n function displayAlert(message: string) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: message\n })\n );\n }\n\n function validate() {\n return EmailRegex.test(email);\n }\n \n async function submitEmail() {\n if (!validate()) {\n displayAlert(t(\"Please enter valid e-mail.\"));\n return;\n }\n\n if (!executeRecaptcha) {\n console.log(\"no recaptcha\");\n return;\n }\n const token = await executeRecaptcha('recovery');\n if (!token) return;\n \n if (isEnterprise) {\n AuthenticationService.recoverPasswordEnterprise(email, token)\n .then(\n () => setCompleted(true),\n () => setCompleted(true)\n );\n } else {\n AuthenticationService.recoverPassword(email, token)\n .then(\n () => setCompleted(true),\n () => setCompleted(true)\n );\n }\n }\n \n \n return (\n <AuthenticationLayout \n hiddenLogo\n backButton\n >\n \n <div className={classes.form}>\n <Typography className={classes.formHeader}>\n {t(\"Did you forget your password?\")}\n </Typography>\n \n <div className={classes.formText}>\n <Typography className={classes.formTextLine}>\n {t(\"To reset your password, \")}<span className={classes.formTextLineBold}>{t(\"enter your email address.\")}</span> {t(\"You may need to check your spam folder.\")}\n </Typography>\n </div>\n \n {completed ? \n <SuccessBlock \n headerMessage={t(\"Success!\")}\n textMessage={<Trans i18nKey=\"IfAccountExistsEmailWillBeSent\" t={t} values={{ email }}/>}\n blockHeight={220}\n />\n : \n <>\n <EmailInput \n value={email} \n onChangeHandler={handleEmailChange} \n placeholder=\"usuario@clear.com\"\n required\n />\n \n <Button\n className={classes.sendButton}\n color=\"primary\"\n variant=\"contained\"\n onClick={submitEmail}\n disabled={email.length === 0}\n >\n {t(\"Send\")}\n </Button>\n </>\n }\n </div>\n </AuthenticationLayout>\n )\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n submitButton: {\n width: \"370px\",\n height: \"39px\",\n borderRadius: \"51px\",\n marginTop: \"24px\",\n\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n display: \"flex\",\n alignItems: \"center\",\n color: \"#FFFFFF\"\n },\n formHeader: {\n width: \"370px\",\n height: \"34px\",\n \n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#6A6E72\",\n marginBottom: \"16px\",\n marginTop: 7\n },\n passwordStrengthMeter: {\n display: \"block\",\n width: \"369px\",\n height: \"5px\",\n backgroundColor: \"#F6F6F6\",\n \n marginTop: \"8px\",\n borderRadius: \"10px\"\n },\n passwordStrengthEmpty: {\n \n },\n passwordStrengthBad: {\n display: \"block\",\n height: \"100%\",\n width: \"100%\",\n backgroundColor: \"#F15857\",\n borderRadius: \"10px\"\n },\n passwordStrengthMediocre: {\n display: \"block\",\n height: \"100%\",\n width: \"50%\",\n backgroundColor: \"#FFC626\",\n borderRadius: \"10px\"\n },\n passwordStrengthGood: {\n display: \"block\",\n height: \"100%\",\n width: \"100%\",\n backgroundColor: \"#36CE91\",\n borderRadius: \"10px\"\n },\n passwordStrengthHint: {\n marginTop: \"8px\",\n\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"9px\",\n lineHeight: \"11px\",\n display: \"flex\",\n alignItems: \"center\",\n color: \"#919CA5\"\n },\n confirmPasswordInput: {\n marginTop: \"24px\",\n marginBottom: \"24px\"\n },\n successBlock: {\n marginTop: 40\n }\n}));\n\nexport default useStyles;","import { IPasswordStrengthInfo } from \"./props\";\nimport { useTranslation } from \"react-i18next\";\n\nexport default function usePasswordValidation(password : string, classes : any) : IPasswordStrengthInfo {\n \n const { t } = useTranslation(\"general\");\n \n if (password === \"\") {\n return {\n className: classes.passwordStrengthEmpty,\n hint: t(\"Minimum 8 characters, you must include at least 1 special character (!, @, #, $,%, & Etc.)\"),\n isGood: false\n }\n }\n\n const oneCapitalLetter = /([A-Z]+)/;\n if (!oneCapitalLetter.test(password)) {\n return {\n className: classes.passwordStrengthBad,\n hint: t(\"Must contain at least 1 capital letter\"),\n isGood: false\n }\n }\n\n const noWhitespaces = /(\\s+)/;\n if (noWhitespaces.test(password)) {\n return {\n className: classes.passwordStrengthBad,\n hint: t(\"Must not contain whitespaces\"),\n isGood: false\n }\n }\n\n const oneDigit = /(\\d+)/;\n if (!oneDigit.test(password)) {\n return {\n className: classes.passwordStrengthBad,\n hint: t(\"Must contain at least 1 digit\"),\n isGood: false\n }\n }\n\n const oneSpecial = /[\\@\\$\\!\\%\\*\\&\\\"\\#\\/\\(\\)\\=\\?\\-\\.\\,\\_\\[\\]\\*\\+]+/; \n if (!oneSpecial.test(password)) {\n return {\n className: classes.passwordStrengthMediocre,\n hint: t(\"Must contain at least 1 special character\"),\n isGood: false\n }\n }\n \n const eightCharacters = /^\\S{8,}$/;\n if (!eightCharacters.test(password)) {\n return {\n className: classes.passwordStrengthMediocre,\n hint: t(\"Must be at least 8 characters\"),\n isGood: false\n }\n }\n\n return {\n className: classes.passwordStrengthGood,\n hint: t(\"Password secure\"),\n isGood: true\n }\n}","import React, { useEffect, useState } from 'react';\nimport { Link, useHistory } from 'react-router-dom';\n\nimport { Button, Typography } from \"@material-ui/core\";\nimport { useGoogleReCaptcha } from \"react-google-recaptcha-v3\";\n\nimport useStyles from \"./css\";\nimport { IResetPasswordFormState, IResetPasswordData } from \"./props\";\nimport AuthenticationLayout from \"../AuthenticationLayout\";\nimport PasswordInput from \"../PasswordInput\";\nimport SuccessBlock from \"../SuccessBlock\";\nimport { Url } from \"../../../constants/url\";\nimport { AuthenticationService } from \"../../../api/authentication-service\";\nimport usePasswordValidation from \"./use-password-validation\";\nimport { useTranslation } from \"react-i18next\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { useAppDispatch } from \"../../../redux/hooks\";\n\nexport default function ResetPassword(props: any) {\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n const history = useHistory();\n\n const { executeRecaptcha } = useGoogleReCaptcha();\n \n const [resetPasswordData, setResetPasswordData] = useState<IResetPasswordData>({ token: \"\", email: \"\" });\n const [formState, setFormState] = useState<IResetPasswordFormState>({ newPassword: \"\", confirmPassword: \"\"});\n const [completed, setCompleted] = useState<boolean>(false);\n \n const { enqueueAlert } = alertsActions;\n const dispatch = useAppDispatch();\n \n function handleNewPasswordChange(e: any) {\n setFormState({...formState, newPassword: e.target.value });\n }\n\n function handleConfirmPasswordChange(e: any) {\n setFormState({...formState, confirmPassword: e.target.value});\n }\n\n function displayAlert(message: string) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: message\n })\n );\n }\n \n const passwordStrength = usePasswordValidation(formState.newPassword, classes);\n \n function passwordsAreEqual() {\n return formState.newPassword === formState.confirmPassword;\n }\n \n async function submitNewPassword() {\n if (!passwordStrength.isGood) {\n return;\n }\n \n if (!passwordsAreEqual()) {\n return;\n }\n\n if (!executeRecaptcha) {\n console.log(\"no recaptcha\")\n return;\n }\n \n const captchaToken = await executeRecaptcha('reset');\n if (!captchaToken) return;\n \n AuthenticationService\n .resetPassword(resetPasswordData.email, resetPasswordData.token, formState.newPassword, captchaToken)\n .then(\n () => setCompleted(true),\n () => setCompleted(true)\n );\n }\n\n const SubmitButton =\n <Button\n className={classes.submitButton}\n color=\"primary\"\n variant=\"contained\"\n onClick={submitNewPassword}\n disabled={!(passwordsAreEqual() && passwordStrength.isGood)}\n >\n {t(\"Reset password\")}\n </Button>\n \n const GoToLoginButton =\n <Link to={Url.Authentication.Login}>\n <Button\n className={classes.submitButton}\n color=\"primary\"\n variant=\"contained\"\n >\n {t(\"Log in\")}\n </Button>\n </Link>\n \n useEffect(() => {\n const token = props.match.params[0];\n const { email } = props.match.params;\n if (!token || token === \"\" || !email || email === \"\") {\n history.push(Url.Authentication.Login);\n }\n \n setResetPasswordData(\n {\n ...resetPasswordData,\n token: token,\n email: email,\n })\n }, [])\n \n return (\n <AuthenticationLayout>\n <div>\n\n {completed ? \n <div className={classes.successBlock}>\n <SuccessBlock \n headerMessage={t(\"Done!\")}\n textMessage={t(\"Your password has been restored\")}\n blockHeight={180}\n />\n {GoToLoginButton}\n </div>\n : \n <>\n <Typography className={classes.formHeader}>\n {t(\"Reset password\")}\n </Typography>\n \n <PasswordInput\n value={formState.newPassword}\n label={t(\"New password\")}\n placeholder={t(\"Enter new password\")}\n onChangeHandler={handleNewPasswordChange}\n success={passwordStrength.isGood}\n />\n <div className={classes.passwordStrengthMeter}>\n <span className={passwordStrength.className} />\n </div>\n <Typography className={classes.passwordStrengthHint}>\n {passwordStrength.hint}\n </Typography>\n <div className={classes.confirmPasswordInput}>\n <PasswordInput\n value={formState.confirmPassword}\n label={t(\"Confirm your new password\")}\n placeholder={t(\"Confirm new password\")}\n onChangeHandler={handleConfirmPasswordChange}\n success={passwordsAreEqual() && passwordStrength.isGood}\n />\n </div>\n \n {SubmitButton}\n </>\n }\n </div>\n </AuthenticationLayout>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n submitButton: {\n width: 370,\n height: 39,\n borderRadius: 51,\n marginTop: 24,\n\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 14,\n lineHeight: \"17px\",\n display: \"flex\",\n alignItems: \"center\",\n color: \"#FFFFFF\"\n },\n formHeader: {\n width: 370,\n height: 17,\n \n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 14,\n lineHeight: 17,\n textAlign: \"center\",\n color: \"#6A6E72\",\n marginBottom: 6,\n marginTop: 7\n },\n formHeaderText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n \n width: 370,\n height: 28,\n\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginBottom: 23\n },\n passwordStrengthMeter: {\n display: \"block\",\n width: \"369px\",\n height: \"5px\",\n backgroundColor: \"#F6F6F6\",\n \n marginTop: \"8px\",\n borderRadius: \"10px\"\n },\n passwordStrengthEmpty: {\n \n },\n passwordStrengthBad: {\n display: \"block\",\n height: \"100%\",\n width: \"100%\",\n backgroundColor: \"#F15857\",\n borderRadius: \"10px\"\n },\n passwordStrengthMediocre: {\n display: \"block\",\n height: \"100%\",\n width: \"50%\",\n backgroundColor: \"#FFC626\",\n borderRadius: \"10px\"\n },\n passwordStrengthGood: {\n display: \"block\",\n height: \"100%\",\n width: \"100%\",\n backgroundColor: \"#36CE91\",\n borderRadius: \"10px\"\n },\n passwordStrengthHint: {\n marginTop: \"8px\",\n\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"9px\",\n lineHeight: \"11px\",\n display: \"flex\",\n alignItems: \"center\",\n color: \"#919CA5\"\n },\n confirmPasswordInput: {\n marginTop: \"24px\",\n marginBottom: \"24px\"\n },\n successBlock: {\n marginTop: 40\n }\n}));\n\nexport default useStyles;","import React, { useEffect, useState } from 'react';\nimport { Link, useHistory } from 'react-router-dom';\n\nimport { Button, Typography } from \"@material-ui/core\";\nimport { useGoogleReCaptcha } from \"react-google-recaptcha-v3\";\n\nimport useStyles from \"./css\";\nimport { ISetPasswordFormState, ISetPasswordData } from \"./props\";\nimport AuthenticationLayout from \"../AuthenticationLayout\";\nimport PasswordInput from \"../PasswordInput\";\nimport SuccessBlock from \"../SuccessBlock\";\nimport { Url } from \"../../../constants/url\";\nimport { AuthenticationService } from \"../../../api/authentication-service\";\nimport usePasswordValidation from \"../ResetPassword/use-password-validation\";\nimport { useTranslation } from \"react-i18next\";\n\nexport default function Join(props: any) {\n\n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n const history = useHistory();\n\n const { executeRecaptcha } = useGoogleReCaptcha();\n\n const [resetPasswordData, setResetPasswordData] = useState<ISetPasswordData>({ token: \"\", email: \"\" });\n const [formState, setFormState] = useState<ISetPasswordFormState>({ password: \"\", confirmPassword: \"\"});\n const [completed, setCompleted] = useState<boolean>(false);\n\n function handlePasswordChange(e: any) {\n setFormState({...formState, password: e.target.value });\n }\n\n function handleConfirmPasswordChange(e: any) {\n setFormState({...formState, confirmPassword: e.target.value});\n }\n\n const passwordStrength = usePasswordValidation(formState.password, classes);\n\n function passwordsAreEqual() {\n return formState.password === formState.confirmPassword;\n }\n\n async function submitNewPassword() {\n if (!passwordStrength.isGood) {\n return;\n }\n\n if (!passwordsAreEqual()) {\n return;\n }\n\n if (!executeRecaptcha) {\n console.log(\"no recaptcha\")\n return;\n }\n\n const captchaToken = await executeRecaptcha('reset');\n if (!captchaToken) return;\n\n AuthenticationService\n .resetPassword(resetPasswordData.email, resetPasswordData.token, formState.password, captchaToken)\n .then(\n () => setCompleted(true),\n () => setCompleted(true)\n );\n }\n\n const SubmitButton =\n <Button\n className={classes.submitButton}\n color=\"primary\"\n variant=\"contained\"\n onClick={submitNewPassword}\n disabled={!(passwordsAreEqual() && passwordStrength.isGood)}\n >\n {t(\"Sign up\")}\n </Button>\n\n const GoToLoginButton =\n <Link to={Url.Authentication.Login}>\n <Button\n className={classes.submitButton}\n color=\"primary\"\n variant=\"contained\"\n >\n {t(\"Log in\")}\n </Button>\n </Link>\n\n useEffect(() => {\n const token = props.match.params[0];\n const { email } = props.match.params;\n if (!token || token === \"\" || !email || email === \"\") {\n history.push(Url.Authentication.Login);\n }\n\n setResetPasswordData(\n {\n ...resetPasswordData,\n token: token,\n email: email,\n })\n }, [])\n\n return (\n <AuthenticationLayout>\n <div>\n\n {completed ?\n <div className={classes.successBlock}>\n <SuccessBlock\n headerMessage={t(\"Done!\")}\n textMessage={t(\"Your password has been set\")}\n blockHeight={180}\n />\n {GoToLoginButton}\n </div>\n :\n <>\n <Typography className={classes.formHeader}>\n {t(\"Sign up to join your team\")}\n </Typography>\n <Typography className={classes.formHeaderText}>\n {t(\"We need a few details to create an account for\")}\n <strong>{resetPasswordData.email}</strong>\n </Typography>\n\n <PasswordInput\n value={formState.password}\n label={t(\"Create password\")}\n placeholder={t(\"Enter your password\")}\n onChangeHandler={handlePasswordChange}\n success={passwordStrength.isGood}\n required\n />\n <div className={classes.passwordStrengthMeter}>\n <span className={passwordStrength.className} />\n </div>\n <Typography className={classes.passwordStrengthHint}>\n {passwordStrength.hint}\n </Typography>\n <div className={classes.confirmPasswordInput}>\n <PasswordInput\n value={formState.confirmPassword}\n label={t(\"Confirm password\")}\n placeholder={t(\"Confirm your password\")}\n onChangeHandler={handleConfirmPasswordChange}\n success={passwordsAreEqual() && passwordStrength.isGood}\n required\n />\n </div>\n\n {SubmitButton}\n </>\n }\n </div>\n </AuthenticationLayout>\n );\n}","import React from \"react\";\nimport { Route } from \"react-router-dom\";\n\nimport { GoogleReCaptchaProvider } from \"react-google-recaptcha-v3\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport Login from \"../Login\";\nimport Recovery from \"../Recovery\";\nimport { Url } from \"../../../constants/url\";\nimport ResetPassword from \"../ResetPassword\";\nimport Join from \"../Join\";\n\nexport default function AuthenticationRouter() {\n\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n \n const wrapperCaptcha: any = (children: JSX.Element) => (\n <GoogleReCaptchaProvider\n language={localeApp}\n reCaptchaKey={process.env.REACT_APP_RECAPTCHA_TOKEN}>\n {children}\n </GoogleReCaptchaProvider>\n );\n\n return (<>\n <Route path={Url.Authentication.Login} component={(props: any) => wrapperCaptcha(<Login {...props}/>)} />\n <Route path={Url.Authentication.Logout} />\n <Route path={Url.Authentication.Recovery} component={(props: any) => wrapperCaptcha(<Recovery {...props}/>)} />\n <Route path={Url.Authentication.ResetPassword} component={(props: any) => wrapperCaptcha(<ResetPassword {...props}/>)} />\n <Route path={Url.Authentication.Join} component={(props: any) => wrapperCaptcha(<Join {...props}/>)} />\n </>);\n}","import React from \"react\";\nimport { Menu, Theme, styled } from '@material-ui/core';\n\nconst SMenu = styled(Menu)<Theme, { borders?: boolean }>(({ theme, borders }) => ({\n '& .MuiPaper-root': {\n borderRadius: 8,\n boxShadow: `0 2px 6px -1px ${theme.colors.grey3}`,\n },\n\n '& .MuiMenuItem-root': {\n borderBottom: borders ? `1px solid ${theme.colors.grey2}` : undefined,\n\n '&:last-child': {\n borderBottom: borders ? 'none' : undefined,\n },\n },\n}));\n\nexport default SMenu;\n","import React from \"react\";\nimport { MenuItem, styled } from '@material-ui/core';\nimport { rgba } from '../styles/ColorHelpers';\n\nconst SMenuItem = styled(MenuItem)(({ theme }) => ({\n ...theme.typography.header6,\n flexWrap: 'wrap',\n fontWeight: 'normal',\n padding: '8px 14px',\n}));\n\nexport const SMenuItem2 = styled(SMenuItem)(({ theme }) => ({\n minHeight: 32,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: theme.colors.grey5,\n padding: 5,\n cursor: \"pointer\",\n position: \"relative\",\n width: 240,\n textAlign: \"left\",\n paddingLeft: 15,\n height: 35,\n '&:not(:hover)': {\n backgroundColor: \"white\",\n },\n '&:hover': {\n backgroundColor: \"#E1E9FE\",\n },\n}));\n\nexport default SMenuItem;\n","import { DateTime } from 'luxon';\nimport { createContext, useContext } from 'react';\n\nexport interface IScheduleAppointmentActionsMenuContext {\n open(dateTime: DateTime, userId: string | null, x: number, y: number): void;\n}\n\nexport const ScheduleAppointmentActionsMenuContext =\n createContext<IScheduleAppointmentActionsMenuContext | null>(null);\n\nexport function useScheduleAppointmentActionsMenuContext() {\n const ctx = useContext(ScheduleAppointmentActionsMenuContext);\n if (!ctx) throw new Error('ScheduleAppointmentActionsMenuContext is not available');\n return ctx;\n}\n","import React from \"react\";\nimport { BanIcon, CalendarIcon } from \"../../../../assets/icons\";\nimport SMenu from '../mui/SMenu';\nimport { SMenuItem2 } from '../mui/SMenuItem';\nimport { useCallback, useEffect, useMemo, useState } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { NavLink, useHistory } from 'react-router-dom';\nimport {\n IScheduleAppointmentActionsMenuContext,\n ScheduleAppointmentActionsMenuContext,\n} from './context';\nimport { Url } from \"../../../../constants/url\";\nimport { blockedScheduleActions } from \"../../../../redux/blocked-schedule-slice\";\nimport { useAppDispatch } from \"../../../../redux/hooks\";\nimport { scheduleAppointmentTimeActions } from \"../../../../redux/schedule-appointment-time-slice\";\n\ntype ScheduleAppointmentActionsMenuProps = {\n anchorEl: HTMLElement | null;\n onClose: () => void;\n addAbsenceClick: React.MouseEventHandler;\n};\n\nexport default function ScheduleAppointmentActionsMenu({\n anchorEl,\n addAbsenceClick,\n onClose,\n}: ScheduleAppointmentActionsMenuProps) {\n const { t } = useTranslation(['general']);\n const history = useHistory();\n const dispatch = useAppDispatch();\n \n const handleNewAppointment = () => {\n dispatch(blockedScheduleActions.setShowMenu(false));\n history.push(`${Url.Appointments.Main}/new`);\n }\n \n return (\n <SMenu\n borders\n anchorOrigin={{ horizontal: 'center', vertical: 'bottom' }}\n transformOrigin={{ horizontal: 'center', vertical: 'top' }}\n id=\"scheduler-add-work-menu-keke\"\n anchorEl={anchorEl}\n onClose={onClose}\n transitionDuration={150}\n open={!!anchorEl}\n keepMounted\n >\n <SMenuItem2 onClick={handleNewAppointment}>\n <span style={{marginRight: 10, paddingLeft: 2}}>\n <CalendarIcon />\n </span>\n {t('Create new appointment')}\n </SMenuItem2>\n <SMenuItem2 onClick={addAbsenceClick}>\n <span style={{marginRight: 10}}>\n <BanIcon />\n </span>\n {t('Block schedule')}\n </SMenuItem2>\n </SMenu>\n );\n}\n\nexport function ScheduleAppointmentActionsMenuContextProvider({\n children,\n}: React.PropsWithChildren<{}>) {\n \n const [state, setState] = useState<{anchorEl: HTMLElement;} | null>(null);\n useEffect(() => {\n return () => state?.anchorEl.remove();\n }, [state?.anchorEl]);\n \n const dispatch = useAppDispatch();\n\n const addAbsence = useCallback(() => {\n if (!state) return;\n dispatch(blockedScheduleActions.setShowModal(true));\n // close the menu after 200ms to give the schedule absence popup some time to position iteself in the right place before\n // removing anchor element\n setTimeout(() => {\n setState(null);\n }, 200);\n }, [/*scheduleAbsencePopup, */state]);\n\n const ctx: IScheduleAppointmentActionsMenuContext = useMemo(\n () => ({\n open: (dt, userId, x, y) => {\n // create temporary anchor element to avoid menu acting weird if original anchor disappears\n const el = document.createElement('div');\n el.style.position = 'fixed';\n el.style.left = `${x}px`;\n el.style.top = `${y}px`;\n el.style.width = el.style.height = '1px';\n document.body.appendChild(el);\n\n setState({\n anchorEl: el,\n });\n \n dispatch(scheduleAppointmentTimeActions.setAppointmentTime(dt.toJSDate()));\n dispatch(scheduleAppointmentTimeActions.setClickNewAppointmentOnScheduler(true));\n dispatch(blockedScheduleActions.setDate(dt.toJSDate()));\n dispatch(blockedScheduleActions.setUserId(userId));\n },\n }),\n []\n );\n\n return (\n <>\n <ScheduleAppointmentActionsMenuContext.Provider value={ctx}>\n {children}\n </ScheduleAppointmentActionsMenuContext.Provider>\n <ScheduleAppointmentActionsMenu\n anchorEl={state ? state.anchorEl : null}\n addAbsenceClick={addAbsence}\n onClose={() => setState(null)}\n />\n </>\n );\n}\n","import React, { createContext, useContext, useState } from 'react';\n\nexport type KeyGetterFunction<T> = (value: T) => string;\n\nexport function normalizeGroupKey(k: string) {\n return 'g-' + b64EncodeUnicode(k).replaceAll('=', '_');\n}\n\nexport function getGroupKeyOffsetVariable(k: string) {\n return `--cmos-aps--x-${normalizeGroupKey(k)}`;\n}\n\nfunction b64EncodeUnicode(str: string) {\n // first we use encodeURIComponent to get percent-encoded UTF-8,\n // then we convert the percent encodings into raw bytes which\n // can be fed into btoa.\n return btoa(\n encodeURIComponent(str).replace(/%([0-9A-F]{2})/g, function toSolidBytes(match, p1) {\n return String.fromCharCode(+('0x' + p1));\n })\n );\n}\n\nexport type AppointmentSchedulerContextData = {\n from: number;\n to: number;\n pixelsPerMinute: number;\n groups: unknown[];\n rowHeight: number;\n minColumnWidth: number;\n columnWidth: number;\n headerHeight: number;\n timelineWidth: number;\n innerWidth: number;\n innerHeight: number;\n};\n\nexport const AppointmentSchedulerContext =\n React.createContext<AppointmentSchedulerContextData | null>(null);\n\nexport function useAppointmentSchedulerContext(): AppointmentSchedulerContextData {\n const data = useContext(AppointmentSchedulerContext);\n if (data === null) throw new Error('could not find AppointmentSchedulerContextData');\n return data;\n}\n\nexport function generateStops(from: number, to: number, intervalInMinutes: number) {\n const stops: number[] = [];\n let stop = from;\n do {\n stops.push(stop);\n stop += intervalInMinutes;\n // given intervalInMinutes = 30 and from = 0 and to = 24 * 60 (24:00 time)\n // last stop will be 23 * 60 + 30 or in other words 23:30\n } while (stop + intervalInMinutes <= to);\n return stops;\n}\n\nexport const AppointmentSchedulerRootElementContext = createContext<HTMLElement | null>(null);\n\ntype InnerElementContext = {\n element: HTMLElement | null;\n setInnerElement(element: HTMLElement | null): void;\n};\n\n/**\n * context for passing \"inner\" element (i.e. the element where all grid cells and appointments are)\n * to all children of the scheduler, can be used to subscribe to scrolling of the inner\n * element to synchornize scrolling between inner element and timeline/header\n *\n * we can probably do the same with props instead of context, but context is easier to work with IMO\n */\nexport const AppointmentSchedulerInnerElementContext = createContext<InnerElementContext>({\n element: null,\n setInnerElement: () => {},\n});\n\nexport function AppointmentSchedulerInnerElementContextProvider({\n children,\n}: React.PropsWithChildren<{}>) {\n const [element, setInnerElement] = useState<HTMLElement | null>(null);\n\n return (\n <AppointmentSchedulerInnerElementContext.Provider value={{ element, setInnerElement }}>\n {children}\n </AppointmentSchedulerInnerElementContext.Provider>\n );\n}\n","import { styled } from '@material-ui/core';\nimport { CSSProperties } from '@material-ui/core/styles/withStyles';\nimport clsx from 'clsx';\nimport React, { memo, useContext, useEffect, useMemo, useState } from 'react';\nimport ReactDOM from 'react-dom';\nimport { FixedSizeGrid, GridChildComponentProps } from 'react-window';\nimport {\n AppointmentSchedulerInnerElementContext,\n generateStops,\n useAppointmentSchedulerContext,\n} from '../../_util';\nimport styles from './css.module.css';\n\nexport type ContentGridProps<G> = {\n groups: G[];\n from: number;\n to: number;\n intervalInMinutes: number;\n pixelsPerMinute: number;\n children?: React.ReactNode;\n ContentGridTdComponent?: ContentGridTdComponent<G>;\n contentGridRootRef?: React.RefCallback<HTMLElement>;\n};\n\nexport type ContentGridTdProps<G> = {\n startTimestamp: number;\n stopTimestamp: number;\n group: G;\n};\nexport type ContentGridTdComponent<G> = React.ComponentType<ContentGridTdProps<G>>;\nclass DefaultContentGridTdComponent<G> extends React.Component<ContentGridTdProps<G>> {\n render(): React.ReactNode {\n return <div />;\n }\n shouldComponentUpdate(): boolean {\n return false;\n }\n}\nexport type ContentGridColumnProps<G> = {\n group: G;\n};\nexport type ContentGridColumnComponent<G> = React.ComponentType<ContentGridColumnProps<G>>;\n\ntype CellData<G> = {\n stops: number[];\n stopsInterval: number;\n groups: G[];\n Component: ContentGridTdComponent<G>;\n};\n\nfunction ContentGrid<G>({\n from,\n to,\n groups,\n children,\n ContentGridTdComponent,\n intervalInMinutes,\n contentGridRootRef,\n}: ContentGridProps<G>) {\n const stops = generateStops(from, to, intervalInMinutes);\n const TdComponent = ContentGridTdComponent ?? DefaultContentGridTdComponent;\n\n const { rowHeight, columnWidth, innerHeight, innerWidth } = useAppointmentSchedulerContext();\n\n const cellData: CellData<G> = useMemo(\n () => ({\n Component: TdComponent,\n stops,\n stopsInterval: intervalInMinutes,\n groups,\n }),\n [stops, intervalInMinutes, groups, TdComponent]\n );\n\n const [gridInnerRef, setGridInnerRef] = useState<HTMLElement | null>(null);\n const [gridOuterRef, setGridOuterRef] = useState<HTMLElement | null>(null);\n const { setInnerElement } = useContext(AppointmentSchedulerInnerElementContext);\n\n useEffect(() => {\n if (contentGridRootRef) {\n contentGridRootRef(gridOuterRef);\n }\n }, [gridOuterRef, contentGridRootRef]);\n\n // we use react-window because react-virtuoso does not support virtual grid with horizontal scrolling\n\n return (\n <>\n <FixedSizeGrid<CellData<G>>\n columnCount={groups.length}\n rowCount={stops.length}\n innerRef={setGridInnerRef}\n outerRef={(outer) => {\n setGridOuterRef(outer);\n setInnerElement(outer); // from AppointmentScheduler perspective this \"outer\" element is \"inner\"\n }}\n height={innerHeight}\n width={innerWidth}\n rowHeight={rowHeight}\n itemData={cellData}\n columnWidth={columnWidth}\n className={clsx(styles.grid, 'custom-scrollbar', 'data-scroll-parent')}\n innerElementType={Inner}\n style={\n {\n // this should hurt performance a little, but 1) I don't notice it 2) without this, absence reason will move out of sync with the scheduler\n // try creating a long absence and then scrolling past that absence with/without this property\n willChange: 'initial',\n\n '--cmos-aps-cell-width': `${columnWidth}px`,\n '--cmos-aps-cell-height': `${rowHeight}px`,\n } as CSSProperties\n }\n >\n {Cell}\n </FixedSizeGrid>\n {/* ugly hack that I hate, but it works so uh... yeah */}\n {gridInnerRef &&\n ReactDOM.createPortal(\n <>\n <div className={styles.gridChildren}>{children}</div>\n </>,\n gridInnerRef\n )}\n </>\n );\n}\n\nexport default memo(ContentGrid) as typeof ContentGrid;\n\nfunction Cell<G>({ columnIndex, rowIndex, data, style }: GridChildComponentProps<CellData<G>>) {\n const group = data.groups[columnIndex];\n const ts = data.stops[rowIndex];\n const Component = data.Component;\n return (\n <div className={styles.item} style={style}>\n <Component startTimestamp={ts} stopTimestamp={ts + data.stopsInterval} group={group} />\n </div>\n );\n}\n\nconst Inner = styled('div')({\n display: 'flex',\n flexWrap: 'wrap',\n});\n","import clsx from 'clsx';\nimport React, { CSSProperties, memo } from 'react';\nimport { KeyGetterFunction, getGroupKeyOffsetVariable } from '../_util';\nimport ContentGrid, { ContentGridColumnComponent, ContentGridTdComponent } from './ContentGrid';\nimport styles from './css.module.css';\n\nexport type AppointmentSchedulerContentComponents<G> = {\n ContentInnerWrapperComponent?: ContentInnerWrapperComponent;\n ContentGridTdComponent?: ContentGridTdComponent<G>;\n ContentGridColumnComponent?: ContentGridColumnComponent<G>;\n};\n\nexport type AppointmentSchedulerContentProps<I, G> = ItemsProps<I> &\n AppointmentSchedulerContentComponents<G> & {\n groups: G[];\n intervalInMinutes: number;\n classNameRoot?: string;\n contentGridRootRef?: React.RefCallback<HTMLElement>;\n getGroupKey: KeyGetterFunction<G>;\n };\n\nexport type ContentInnerWrapperComponent = React.ComponentType<React.PropsWithChildren<{}>>;\nconst PassThroughWrapper: ContentInnerWrapperComponent = memo(({ children }) => <>{children}</>);\n\nexport default class AppointmentSchedulerContent<I, G> extends React.PureComponent<\n AppointmentSchedulerContentProps<I, G>\n> {\n render() {\n const { classNameRoot } = this.props;\n\n return (\n <main style={{ width: 'fit-content' }} className={clsx(styles.root, classNameRoot)}>\n {this.renderContentGrid()}\n </main>\n );\n }\n renderContentGrid(): React.ReactNode {\n const {\n groups,\n from,\n to,\n pixelsPerMinute,\n intervalInMinutes,\n ContentGridTdComponent,\n ContentInnerWrapperComponent = PassThroughWrapper,\n contentGridRootRef,\n } = this.props;\n return (\n <ContentGrid<G>\n pixelsPerMinute={pixelsPerMinute}\n intervalInMinutes={intervalInMinutes}\n from={from}\n to={to}\n groups={groups}\n ContentGridTdComponent={ContentGridTdComponent}\n contentGridRootRef={contentGridRootRef}\n >\n <ContentInnerWrapperComponent>\n {this.renderColumns()}\n {this.renderItems()}\n </ContentInnerWrapperComponent>\n </ContentGrid>\n );\n }\n\n private renderItems() {\n const {\n getItemGroupKey,\n getItemData,\n getItemKey,\n items,\n component,\n pixelsPerMinute,\n from,\n to,\n } = this.props;\n return (\n <Items\n from={from}\n to={to}\n pixelsPerMinute={pixelsPerMinute}\n component={component}\n getItemData={getItemData}\n getItemGroupKey={getItemGroupKey}\n getItemKey={getItemKey}\n items={items}\n />\n );\n }\n\n private renderColumns() {\n const { ContentGridColumnComponent, groups, getGroupKey } = this.props;\n\n if (!ContentGridColumnComponent) {\n return;\n }\n\n return groups.map((group, i) => (\n <div className={styles.column} style={{ '--index': i } as CSSProperties}>\n <ContentGridColumnComponent key={getGroupKey(group)} group={group} />\n </div>\n ));\n }\n}\n\nexport type ItemComponentProps<I> = {\n value: I;\n};\nexport type GetItemDataFunction<I> = (item: I) => { ts: number; sizeInMinutes: number };\nexport type ItemComponent<I> = React.ComponentType<ItemComponentProps<I>>;\ntype ItemsProps<I> = {\n items: I[];\n getItemKey: KeyGetterFunction<I>;\n getItemGroupKey: KeyGetterFunction<I>;\n getItemData: GetItemDataFunction<I>;\n component: ItemComponent<I>;\n from: number;\n to: number;\n pixelsPerMinute: number;\n};\n\nclass Items<I> extends React.PureComponent<ItemsProps<I>> {\n render() {\n const { items } = this.props;\n\n return <>{items.map((i) => this._renderItem(i))}</>;\n }\n\n private _renderItem(i: I) {\n const {\n getItemData,\n getItemGroupKey,\n getItemKey,\n component: Component,\n from,\n pixelsPerMinute,\n } = this.props;\n const { ts, sizeInMinutes } = getItemData(i);\n const groupKey = getItemGroupKey(i);\n\n const offsetFromStartInMinutes = ts - from;\n const positionInPixels = offsetFromStartInMinutes * pixelsPerMinute;\n const sizeInPixels = sizeInMinutes * pixelsPerMinute;\n\n return (\n <div\n data-group={groupKey}\n key={getItemKey(i)}\n data-ts={ts}\n className={styles.cell}\n style={\n {\n '--pos': `${positionInPixels}px`,\n '--size': `${sizeInPixels}px`,\n '--offset': `var(${getGroupKeyOffsetVariable(groupKey)})`,\n } as CSSProperties\n }\n >\n <Component value={i} />\n </div>\n );\n }\n}\n","import clsx from 'clsx';\nimport React, { useContext, useEffect, useRef } from 'react';\nimport { AppointmentSchedulerInnerElementContext, KeyGetterFunction } from '../_util';\n\nimport styles from './css.module.css';\n\nexport type HeaderCellComponentProps<G> = {\n value: G;\n};\nexport type HeaderCellComponent<G> = React.ComponentType<HeaderCellComponentProps<G>>;\n\nexport type AppointmentSchedulerHeaderProps<G> = {\n groups: G[];\n getGroupKey: KeyGetterFunction<G>;\n component: HeaderCellComponent<G>;\n CornerComponent?: React.ComponentType<{}>;\n classNameCorner?: string;\n classNameInner?: string;\n classNameRoot?: string;\n classNameCell?: string;\n};\n\nexport default function AppointmentSchedulerHeader<G>({\n groups,\n classNameCorner,\n CornerComponent,\n classNameInner,\n classNameRoot,\n getGroupKey,\n classNameCell,\n component: Component,\n}: AppointmentSchedulerHeaderProps<G>) {\n const { element: innerElement } = useContext(AppointmentSchedulerInnerElementContext);\n const headerRef = useRef<HTMLElement | null>(null);\n\n useEffect(() => {\n if (!innerElement) return;\n\n const callback = () => {\n if (!headerRef.current) return;\n\n headerRef.current.scroll(innerElement.scrollLeft, 0);\n };\n\n innerElement.addEventListener('scroll', callback);\n return () => innerElement.removeEventListener('scroll', callback);\n }, [innerElement]);\n\n return (\n <header ref={headerRef} className={clsx(styles.header, classNameRoot)}>\n <div className={clsx(styles.corner, classNameCorner)}>\n {CornerComponent && <CornerComponent />}\n </div>\n <div className={clsx(styles.inner, classNameInner)}>\n {groups.map((g) => {\n return (\n <div key={getGroupKey(g)} className={clsx(styles.cell, classNameCell)}>\n <Component value={g} />\n </div>\n );\n })}\n </div>\n </header>\n );\n}\n","import { DateTime, IANAZone } from 'luxon';\n\nexport const GetOffsetLabel = (ianaName: string | undefined) => {\n const timeZone = new IANAZone(ianaName ?? '');\n if (!timeZone.isValid) {\n return '(INVALID TIMEZONE)';\n } else {\n const now = DateTime.now();\n const hrsOffset = timeZone.formatOffset(now.toMillis(), 'narrow');\n\n const timezoneShortName = timeZone.offsetName(now.toMillis(), {\n format: 'short',\n locale: 'en',\n });\n if (timezoneShortName!.startsWith('GMT')) {\n return `(GMT${hrsOffset})`;\n } else {\n return `(GMT${hrsOffset} / ${timezoneShortName})`;\n }\n }\n};\n","import clsx from 'clsx';\nimport { GetOffsetLabel } from '../../DateTimeHelpers';\nimport { DateTime } from 'luxon';\nimport React, { CSSProperties, useContext, useEffect, useRef } from 'react';\nimport {\n AppointmentSchedulerInnerElementContext,\n generateStops,\n useAppointmentSchedulerContext,\n} from '../_util';\nimport styles from './css.module.css';\n\nexport type TimelineStopProps = {\n ts: number;\n};\nexport type StopComponent = React.ComponentType<TimelineStopProps>;\n\nexport type AppointmentSchedulerTimelineProps = {\n from: number;\n to: number;\n intervalInMinutes: number;\n pixelsPerMinute: number;\n component: StopComponent;\n classNameRoot?: string;\n showTimezone: boolean;\n};\n\nexport default function AppointmentSchedulerTimeline({\n from,\n to,\n pixelsPerMinute,\n intervalInMinutes,\n component: Component,\n showTimezone,\n classNameRoot,\n}: AppointmentSchedulerTimelineProps) {\n const stops = generateStops(from, to, intervalInMinutes);\n\n const { innerHeight } = useAppointmentSchedulerContext();\n const { element: innerElement } = useContext(AppointmentSchedulerInnerElementContext);\n const asideRef = useRef<HTMLElement | null>(null);\n\n useEffect(() => {\n if (!innerElement) return;\n\n const callback = () => {\n if (!asideRef.current) return;\n\n asideRef.current.scroll(0, innerElement.scrollTop);\n };\n\n innerElement.addEventListener('scroll', callback);\n return () => innerElement.removeEventListener('scroll', callback);\n }, [innerElement]);\n\n return (\n <aside\n ref={asideRef}\n style={{ height: innerHeight }}\n className={clsx(styles.container, classNameRoot)}\n >\n {showTimezone ? (\n <div className={clsx(styles.timezone, classNameRoot)}>\n {GetOffsetLabel(DateTime.now().zoneName)}\n </div>\n ) : undefined}\n {stops.map((minutes) => {\n return (\n <div\n className={styles.mark}\n data-ts={minutes}\n key={minutes}\n style={\n {\n '--pos': `${pixelsPerMinute * (minutes - from)}px`,\n visibility:\n Math.abs(minutes - from) < 2 || Math.abs(minutes - to) < 2\n ? 'hidden'\n : undefined,\n } as CSSProperties\n }\n >\n <Component ts={minutes} />\n </div>\n );\n })}\n {/* another \"fake\" mark to make sure that after last mark (23:30 for example) there is additional space for last grid row */}\n <div\n data-ts={stops[stops.length - 1] + intervalInMinutes}\n className={styles.mark}\n key=\"last\"\n style={\n {\n '--pos': `${\n pixelsPerMinute * (stops[stops.length - 1] + intervalInMinutes - 1)\n }px`,\n visibility: 'hidden',\n } as CSSProperties\n }\n />\n </aside>\n );\n}\n","import React from \"react\";\nimport clsx from 'clsx';\nimport { MutableRefObject, useEffect, useMemo, useState } from 'react';\nimport { useResizeDetector } from 'react-resize-detector';\nimport AppointmentSchedulerContent, {\n AppointmentSchedulerContentComponents,\n GetItemDataFunction,\n ItemComponent,\n} from './Content';\nimport AppointmentSchedulerHeader, {\n AppointmentSchedulerHeaderProps,\n HeaderCellComponent,\n} from './Header';\nimport AppointmentSchedulerTimeline, { StopComponent } from './TimeLine';\nimport {\n AppointmentSchedulerContext,\n AppointmentSchedulerInnerElementContextProvider,\n AppointmentSchedulerRootElementContext,\n KeyGetterFunction,\n getGroupKeyOffsetVariable,\n useAppointmentSchedulerContext,\n} from './_util';\nimport styles from './css.module.css';\n\nexport { useAppointmentSchedulerContext };\n\ntype SchedulerScrollData = {\n scrollLeft: number;\n scrollTop: number;\n scrollTopMinutes: number;\n scrollBottomMinutes: number;\n};\n\nexport type OnSchedulerScrollChangedHandler = (\n data: SchedulerScrollData,\n event: React.SyntheticEvent\n) => void;\n\nexport type AppointmentSchedulerProps<I, G> = {\n groups: G[];\n items: I[];\n getItemKey: KeyGetterFunction<I>;\n getItemGroupKey: KeyGetterFunction<I>;\n getItemData: GetItemDataFunction<I>;\n getGroupKey: KeyGetterFunction<G>;\n components: {\n HeaderCellComponent: HeaderCellComponent<G>;\n ItemComponent: ItemComponent<I>;\n StopComponent: StopComponent;\n } & AppointmentSchedulerContentComponents<G> &\n Pick<AppointmentSchedulerHeaderProps<G>, 'CornerComponent'>;\n classes?: {\n root?: string;\n headerRoot?: string;\n timelineRoot?: string;\n contentRoot?: string;\n };\n\n range: number[];\n sizes: {\n columnWidth: number;\n headerHeight: number;\n timelineWidth: number;\n pixelsPerMinute: number;\n };\n stopsInterval: number;\n showTimezone: boolean;\n onScrollChanged?: OnSchedulerScrollChangedHandler;\n scrollControllerRef?:\n | MutableRefObject<SchedulerScrollController | null>\n | ((controller: SchedulerScrollController | null) => void);\n};\n\nfunction AppointmentScheduler<I, G>({\n items,\n getItemData,\n getItemGroupKey,\n getItemKey,\n getGroupKey,\n groups,\n range: [from, to],\n stopsInterval,\n showTimezone,\n sizes: { headerHeight, timelineWidth, columnWidth, pixelsPerMinute },\n components: {\n HeaderCellComponent,\n StopComponent,\n ItemComponent,\n ContentGridColumnComponent,\n ContentGridTdComponent,\n ContentInnerWrapperComponent,\n CornerComponent,\n },\n classes,\n onScrollChanged,\n scrollControllerRef,\n}: AppointmentSchedulerProps<I, G>) {\n if (stopsInterval < 1) throw new Error('intervalInMinutes must be at least 1');\n\n const onScroll = useMemo(() => {\n if (!onScrollChanged) return undefined;\n\n return (event: React.SyntheticEvent) => {\n const el = event.target as HTMLElement;\n\n onScrollChanged!(\n {\n scrollTop: el.scrollTop,\n scrollLeft: el.scrollLeft,\n scrollTopMinutes: el.scrollTop / pixelsPerMinute,\n scrollBottomMinutes: (el.scrollTop + el.scrollHeight) / pixelsPerMinute,\n },\n event\n );\n };\n }, [onScrollChanged, pixelsPerMinute]);\n\n const [rootElement, setRootElement] = useState<HTMLDivElement | null>(null);\n const [contentGridRoot, setContentGridRoot] = useState<HTMLElement | null>(null);\n\n const [rootElementSize, setRootElementSize] = useState({ width: 0, height: 0 });\n\n const scrollController = useMemo(\n () =>\n contentGridRoot\n ? new SchedulerScrollControllerImpl(contentGridRoot, pixelsPerMinute)\n : null,\n [contentGridRoot, pixelsPerMinute]\n );\n\n useEffect(() => {\n if (scrollControllerRef && scrollController) {\n if (typeof scrollControllerRef === 'object')\n scrollControllerRef.current = scrollController;\n else scrollControllerRef(scrollController);\n }\n }, [scrollControllerRef, scrollController]);\n\n const { ref: resizeDetectorRef } = useResizeDetector<HTMLDivElement>({\n onResize(width, height) {\n setRootElementSize((v) => ({ height: height ?? v.height, width: width ?? v.width }));\n },\n });\n\n const cssProps = useMemo(() => {\n return Object.fromEntries(\n groups.map((g, i) => [\n getGroupKeyOffsetVariable(getGroupKey(g)),\n `max(${(100 * i) / groups.length}%, calc(var(--cmos-aps-column-size) * ${i}))`,\n ])\n ) as React.CSSProperties;\n }, [getGroupKey, groups]);\n\n const actualColumnWidth = Math.max(\n (rootElementSize.width - timelineWidth - 6) / Math.max(1, groups.length),\n columnWidth\n );\n\n const body = (\n <div\n ref={(el) => {\n setRootElement(el);\n resizeDetectorRef.current = el;\n }}\n onScroll={onScroll}\n className={clsx(styles.root, classes?.root)}\n style={\n {\n '--cmos-aps-column-size': `${actualColumnWidth}px`,\n '--cmos-aps-row-size': `${pixelsPerMinute * stopsInterval}px`,\n '--cmos-aps-timeline-size': `${timelineWidth}px`,\n '--cmos-aps-header-size': `${headerHeight}px`,\n '--cmos-aps-columns-count': groups.length,\n '--cmos-aps-pixels-per-minute': `${pixelsPerMinute}px`,\n '--cmos-aps-viewport-width': `${rootElementSize.width - timelineWidth}px`,\n '--cmos-aps-viewport-height': `${rootElementSize.height - headerHeight}px`,\n } as React.CSSProperties\n }\n >\n <AppointmentSchedulerHeader<G>\n component={HeaderCellComponent}\n getGroupKey={getGroupKey}\n groups={groups}\n classNameRoot={classes?.headerRoot}\n CornerComponent={CornerComponent}\n />\n <div className={styles.inner} style={cssProps}>\n <AppointmentSchedulerTimeline\n component={StopComponent}\n pixelsPerMinute={pixelsPerMinute}\n to={to}\n from={from}\n showTimezone={showTimezone}\n intervalInMinutes={stopsInterval}\n classNameRoot={classes?.timelineRoot}\n />\n\n <AppointmentSchedulerContent<I, G>\n pixelsPerMinute={pixelsPerMinute}\n groups={groups}\n intervalInMinutes={stopsInterval}\n from={from}\n to={to}\n component={ItemComponent}\n getItemData={getItemData}\n getItemGroupKey={getItemGroupKey}\n getItemKey={getItemKey}\n getGroupKey={getGroupKey}\n items={items}\n classNameRoot={classes?.contentRoot}\n ContentGridColumnComponent={ContentGridColumnComponent}\n ContentGridTdComponent={ContentGridTdComponent}\n ContentInnerWrapperComponent={ContentInnerWrapperComponent}\n contentGridRootRef={setContentGridRoot}\n />\n </div>\n </div>\n );\n\n return (\n <AppointmentSchedulerRootElementContext.Provider value={rootElement}>\n <AppointmentSchedulerContext.Provider\n value={useMemo(\n () => ({\n pixelsPerMinute,\n from,\n to,\n groups,\n rowHeight: stopsInterval * pixelsPerMinute,\n minColumnWidth: columnWidth,\n timelineWidth,\n headerHeight,\n innerHeight: rootElementSize.height - headerHeight,\n innerWidth: rootElementSize.width - timelineWidth,\n columnWidth: actualColumnWidth,\n }),\n [\n from,\n to,\n pixelsPerMinute,\n groups,\n stopsInterval,\n columnWidth,\n timelineWidth,\n headerHeight,\n rootElementSize,\n actualColumnWidth,\n ]\n )}\n >\n <AppointmentSchedulerInnerElementContextProvider>\n {body}\n </AppointmentSchedulerInnerElementContextProvider>\n </AppointmentSchedulerContext.Provider>\n </AppointmentSchedulerRootElementContext.Provider>\n );\n}\n\nexport default AppointmentScheduler;\n\nexport interface SchedulerScrollController {\n scrollAtCenterInMinutes(number: number): void;\n scrollAtTopInMinutes(number: number): void;\n}\n\nclass SchedulerScrollControllerImpl implements SchedulerScrollController {\n private readonly _element: HTMLElement;\n private readonly _pixelsPerMinute: number;\n\n constructor(element: HTMLElement, pixelsPerMinute: number) {\n this._element = element;\n this._pixelsPerMinute = pixelsPerMinute;\n }\n scrollAtTopInMinutes(number: number): void {\n const top = Math.max(0, this._pixelsPerMinute * number);\n this._element?.scrollTo({\n top,\n });\n }\n scrollAtCenterInMinutes(number: number): void {\n const closure = this;\n setTimeout(function (){ // timeout is the workaround for _element is become fully rendered and clientHeight is correct\n const top = Math.max(0, closure._pixelsPerMinute * number - closure._element.clientHeight / 2);\n closure._element.scrollTo({\n top,\n });\n }, 0);\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n position: \"relative\",\n overflow: \"hidden\",\n border: \"1px solid #C9CDD3\",\n boxSizing: \"border-box\",\n borderRadius: \"4px\",\n background: \"#FFFFFF\",\n zIndex: 99,\n \"&:hover\": {\n border: \"1px solid #C9CDD3\",\n boxSizing: \"border-box\",\n borderRadius: \"4px\",\n background: \"#FFFFFF\",\n },\n },\n inner: {\n transform: 'translate(var(--absence-block-offset-x), var(--absence-block-offset-y))',\n position: 'absolute',\n top: 0,\n left: 0,\n padding: '2px 5px',\n whiteSpace: 'nowrap',\n display: 'flex',\n gap: 8,\n width: '100%',\n boxSizing: 'border-box',\n },\n rootBlocked: {\n background: theme.colors.grey2,\n\n boxSizing: \"border-box\",\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey2,\n borderRadius: 4,\n\n zIndex: 99,\n boxShadow: \"0px 0px 5px rgba(0, 0, 0, 0.25)\",\n \"&:hover\": {\n background: theme.colors.grey2,\n // border: \"1px solid gray\",\n boxSizing: \"border-box\",\n borderRadius: \"4px\",\n },\n },\n rootMultipleBlocked: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n\n background: theme.colors.grey2,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey2,\n borderRadius: 4,\n\n padding: 9,\n\n zIndex: 99,\n boxShadow: \"0px 0px 5px rgba(0, 0, 0, 0.25)\",\n\n \"&:hover\": {\n background: theme.colors.grey2,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey2,\n borderRadius: 4,\n },\n },\n vertical: {\n '& $inner': {\n flexDirection: 'column',\n },\n },\n multipleBlockerTitle: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: \"rgba(50, 57, 71, 0.76);\",\n },\n multipleBlockerDate: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n marginTop: 2,\n },\n header: {\n // background: \"#0BCBE0\",\n borderRadius: \"5px 5px 0px 0px\",\n width: \"100%\",\n height: \"4px\",\n },\n arrived: {\n background: theme.colors.clearGreen,\n },\n notArrived: {\n background: theme.colors.clearRed,\n },\n confirmed: {\n background: theme.colors.clearBlue,\n },\n notConfirmed: {\n background: theme.colors.grey4,\n },\n blocked: {\n background: theme.colors.grey2,\n },\n content: {\n padding: \"9px 8px 9px 8px\",\n height: \"100%\",\n },\n contentNotArrive: {\n background: theme.colors.grey1,\n },\n customerTitle: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: theme.colors.grey7,\n },\n customerTitleBlocked: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: \"rgba(50, 57, 71, 0.76);\",\n },\n customerNotArrived: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n textDecoration: \"line-through\",\n },\n hoursText: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n marginTop: 2,\n },\n hoursTextBlocked: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n marginTop: 2,\n },\n personChargeText: {\n ...theme.typography.caption2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n marginTop: 4,\n },\n isAppointmentCustomerSite: {\n color: theme.colors.clearMain,\n },\n personChargeTextBlocked: {\n ...theme.typography.caption2,\n fontWeight: \"bold\",\n color: \"rgba(50, 57, 71, 0.76)\",\n marginTop: 8,\n },\n tooltipContainer: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n tooltipCustomerNameBox: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 10,\n color: theme.colors.grey5,\n },\n tooltipAppointmentTime: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 9,\n color: theme.colors.grey5,\n },\n tooltipUserName: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 9,\n color: theme.colors.grey5,\n },\n personWithDot: {\n display: \"flex\",\n alignItems: \"center\",\n \"& .dot\": {\n width: 4,\n height: 4,\n display: \"block\",\n backgroundColor: theme.colors.grey4,\n borderRadius: \"50%\",\n marginRight: 7\n }\n },\n dot: {\n width: 4,\n height: 4,\n display: \"block\",\n position: \"absolute\",\n left: 2,\n top: 4,\n backgroundColor: theme.colors.grey4,\n borderRadius: \"50%\",\n },\n serviceItemText: {\n marginTop: 0,\n marginBottom: 4,\n \"& .MuiTypography-root\": {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"9px\",\n lineHeight: \"11px\",\n color: theme.colors.grey4,\n }\n },\n serviceItemsList: {\n padding: \"0\",\n },\n serviceItemsTooltipList: {\n padding: \"0px 0px 3px 0px\",\n },\n serviceSingleItemText: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"9px\",\n lineHeight: \"11px\",\n color: theme.colors.grey4,\n marginBottom: 4\n },\n serviceListItem: {\n padding: \"0px 0px 0px 12px\"\n },\n popper:{\n [`& .MuiTooltip-tooltip`]: {\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: theme.colors.grey1,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey5,\n boxShadow: \"0px 0px 4px #00000034\",\n position: \"absolute\",\n height: \"auto\",\n width: \"max-content\",\n top: 35,\n left: -55\n },\n },\n establishmentRow: {\n display: \"flex\",\n alignItems: \"center\",\n gap: 4,\n }\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport clsx from 'clsx';\nimport { CSSProperties, useEffect, useMemo, useRef } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport BlockSchedule from \"../../../../../models/blocked-schedule\";\nimport { DeleteIcon, EstablishmentIcon } from \"../../../../../assets/icons\";\nimport Typography from \"@material-ui/core/Typography\";\nimport useStyles from \"./css\";\n\ntype AbsenceBlockProps = {\n onClick?: React.MouseEventHandler;\n topOffset?: number;\n leftOffset?: number;\n absence: BlockSchedule;\n vertical?: boolean;\n\n /**\n * if set, block's size will be determined based on the given ratio of\n * pixels per minute, if vertical is set to true, this will determine the height of the block,\n * otherwise width\n */\n pixelPerMinute?: number;\n overrideDuration?: number;\n};\n\nexport default function AbsenceBlock({\n onClick,\n absence,\n leftOffset = 10,\n topOffset = 10,\n vertical,\n pixelPerMinute,\n overrideDuration,\n}: AbsenceBlockProps) {\n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n\n const rootElRef = useRef<HTMLDivElement | null>(null);\n\n const duration = useMemo(() => {\n if (overrideDuration) {\n return overrideDuration;\n }\n\n const startDt = absence.start;\n const endDt = absence.end;\n return endDt.diff(startDt).as('minutes');\n }, [overrideDuration, absence.start, absence.end]);\n\n const style = useMemo(() => {\n const s: CSSProperties = {};\n\n if (pixelPerMinute) {\n const size = pixelPerMinute * duration;\n s[vertical ? 'height' : 'width'] = `${size}px`;\n }\n\n return s;\n }, [pixelPerMinute, vertical, duration]);\n\n useEffect(() => {\n // I hate this, but it works\n if (!rootElRef.current) throw new Error();\n const rootEl = rootElRef.current;\n rootEl.style.setProperty('--absence-block-offset-y', `0px`);\n rootEl.style.setProperty('--absence-block-offset-x', `0px`);\n const scrollbarParent = getScrollableParent(rootEl);\n if (!scrollbarParent) return;\n const parentRect = scrollbarParent.getBoundingClientRect();\n\n const callback = () => {\n const rootRect = rootEl.getBoundingClientRect();\n\n if (!vertical) {\n const rootElementOffset = rootRect.left;\n const diff = parentRect.left - rootElementOffset;\n\n if (diff > -leftOffset) {\n rootEl.style.setProperty('--absence-block-offset-x', `${diff + leftOffset}px`);\n } else {\n rootEl.style.setProperty('--absence-block-offset-x', `0px`);\n }\n } else {\n const rootElementOffset = rootRect.top;\n const diff = parentRect.top - rootElementOffset;\n\n if (diff > -topOffset) {\n rootEl.style.setProperty('--absence-block-offset-y', `${diff + topOffset}px`);\n } else {\n rootEl.style.setProperty('--absence-block-offset-y', `0px`);\n }\n }\n };\n callback();\n\n scrollbarParent.addEventListener('scroll', callback);\n return () => scrollbarParent.removeEventListener('scroll', callback);\n }, [rootElRef, leftOffset, topOffset, vertical]);\n \n const dateFormat = (date: Date): string => {\n const formatDate = date.toTimeString().split(\" \")[0].split(\":\");\n return `${formatDate[0]}:${formatDate[1]}`;\n };\n\n return (<>\n <div\n style={style}\n ref={rootElRef}\n role=\"button\"\n className={clsx(classes.root, vertical && classes.vertical, absence.isBlockedMultiple ? classes.rootMultipleBlocked : classes.rootBlocked)}\n onClick={onClick}\n >\n <div className={classes.inner}>\n <div key={absence.id} data-absence-id={absence.id}>\n {\n absence.isBlockedMultiple ?\n <>\n <div className={classes.multipleBlockerTitle}>\n {absence.blockerCount + \" \" + t(\"blocked schedules\")}\n </div>\n <div className={classes.multipleBlockerDate}>\n {\n absence.allDay\n ?\n t(\"All day\")\n :\n dateFormat(absence.start.toJSDate()) +\n \" - \" +\n dateFormat(absence.end.toJSDate())\n }\n </div>\n </>\n :\n <>\n <div className={`${classes.header} ${classes.blocked}`}></div>\n <div className={classes.content}>\n <span style={{ display: \"inline-block\", marginRight: 5 }}>\n <DeleteIcon color={\"rgba(50, 57, 71, 0.76);\"}/>\n </span>\n <Typography style={{ display: \"inline-block\" }}\n className={classes.customerTitleBlocked}>\n {\n absence.isBlockedReasonPredetermined ? t(absence.blockedReason!) : absence.blockedReason\n }\n </Typography>\n <Typography className={classes.hoursTextBlocked}>\n {dateFormat(absence.start.toJSDate()) +\n \" - \" +\n dateFormat(absence.end.toJSDate())}\n </Typography>\n <Typography className={classes.personChargeTextBlocked}>\n {t(absence.specialist!)}\n </Typography>\n {\n absence.establishmentName &&\n <div className={classes.establishmentRow}>\n <EstablishmentIcon/>\n <Typography className={classes.hoursTextBlocked}>\n {absence.establishmentName}\n </Typography>\n </div>\n }\n </div>\n </>\n }\n </div>\n </div>\n </div>\n \n \n \n </>\n );\n}\n\nfunction getScrollableParent(element: HTMLElement): HTMLElement | null {\n let node = element.parentElement;\n\n while (node !== null) {\n if (node.dataset.scrollParent || node.classList.contains('data-scroll-parent')) {\n return node;\n }\n\n node = node.parentElement;\n }\n\n return null;\n}\n","import React from \"react\";\nimport { makeStyles } from '@material-ui/core';\nimport { useAppointmentSchedulerContext } from '../AppointmentsScheduler';\nimport { ItemComponentProps } from '../AppointmentsScheduler/Content';\nimport { CSSProperties, Fragment, useRef } from 'react';\nimport { useAppDispatch } from \"../../../../redux/hooks\";\nimport AbsenceBlock from './AbsenceBlock';\nimport { AbsenceGroup } from '../_common';\nimport BlockSchedule from \"../../../../models/blocked-schedule\";\nimport { blockedScheduleActions } from \"../../../../redux/blocked-schedule-slice\";\nimport { PlusIcon } from \"../../../../assets/icons\";\nimport { useScheduleAppointmentActionsMenuContext } from \"../ScheduleAppointmentActionsMenu/context\";\nimport { multipleBlockedScheduleActions } from \"../../../../redux/multiple-blocked-schedule-slice\";\n\nconst useStyles = makeStyles({\n root: {\n height: '100%',\n position: 'relative',\n },\n item: {\n boxSizing: 'border-box',\n position: 'absolute',\n left: 'calc(100% / var(--total-count) * var(--index) * 2 / 3)',\n top: 'calc(var(--cmos-aps-pixels-per-minute) * var(--absence-offset))',\n height: 'calc(var(--cmos-aps-pixels-per-minute) * var(--absence-duration))',\n },\n plusBtn: {\n all: 'initial',\n backgroundColor: 'var(--clearMain)',\n display: 'block',\n zIndex: 100,\n height: 24,\n width: 24,\n borderRadius: 12,\n position: 'absolute',\n right: 0,\n top: '50%',\n transform: 'translateY(-50%)',\n color: '#fff',\n cursor: 'pointer',\n scale: 0,\n visibility: 'hidden',\n transition: 'scale .15s',\n transformOrigin: 'center',\n \n '&:hover': {\n backgroundColor: 'var(--clear2)',\n },\n \n '&>svg': {\n top: \"1.5px\",\n left: \"4px\",\n position: \"relative\"\n }\n },\n wrapper: {\n display: 'contents',\n position: 'relative',\n '&:hover $plusBtn': {\n scale: 1,\n visibility: 'visible',\n },\n },\n});\n\nfunction getWidth(index: number, totalCount: number): number {\n return 100 - ((index / totalCount) * 100 * 2) / 3;\n}\n\nexport default function AbsenceItem({ value }: ItemComponentProps<AbsenceGroup>) {\n const styles = useStyles();\n const dispatch = useAppDispatch();\n const { pixelsPerMinute } = useAppointmentSchedulerContext();\n const actionsPopupMenu = useScheduleAppointmentActionsMenuContext();\n \n const firstAbsence = value.absences[0];\n const date = firstAbsence.start;\n const rootRef = useRef<HTMLTableCellElement | null>(null);\n\n const handleOnClick = (event: React.MouseEvent, absence: BlockSchedule) => {\n if (absence?.isBlockedMultiple) {\n dispatch(multipleBlockedScheduleActions.setState({\n isModalOpen: true,\n blockerCount: absence.blockerCount,\n blockers: absence.blockers\n }))\n return;\n }\n dispatch(blockedScheduleActions.setBlockedSheduleId(absence.id));\n dispatch(blockedScheduleActions.setShowModal(true));\n };\n\n const body = (<div\n ref={rootRef}\n className={styles.root}\n style={{ '--total-count': value.absences.length } as CSSProperties}\n >\n {value.absences.map((s, idx) => (\n <Fragment key={s.originalAbsence.id}>\n <div\n className={styles.item}\n style={\n {\n '--index': idx,\n '--absence-offset': s.start.diff(value.start).as('seconds') / 60,\n '--absence-duration': s.duration,\n width: `${getWidth(idx, value.absences.length)}%`,\n } as CSSProperties\n }\n >\n <AbsenceBlock\n vertical\n pixelPerMinute={pixelsPerMinute}\n absence={s.originalAbsence}\n topOffset={3}\n overrideDuration={s.duration}\n onClick={(e) => handleOnClick(e, s.originalAbsence)}\n />\n </div>\n </Fragment>\n ))}\n </div>);\n \n return (\n <div className={styles.wrapper}>\n {body}\n <>\n <div\n ref={rootRef}\n className={styles.plusBtn}\n onClick={(e) => actionsPopupMenu.open(date, null, e.clientX, e.clientY)}\n >\n <PlusIcon size={24} fill=\"currentColor\" />\n </div>\n \n </>\n </div>\n );\n}\n","import { makeStyles } from '@material-ui/core/styles';\n\nconst useAppointmentCardStyles = makeStyles((theme) => ({\n root: {\n overflow: \"hidden\",\n border: \"1px solid #C9CDD3\",\n boxSizing: \"border-box\",\n borderRadius: \"4px\",\n background: \"#FFFFFF\",\n zIndex: 99,\n \"&:hover\": {\n border: \"1px solid #C9CDD3\",\n boxSizing: \"border-box\",\n borderRadius: \"4px\",\n background: \"#FFFFFF\",\n },\n },\n header: {\n // background: \"#0BCBE0\",\n borderRadius: \"5px 5px 0px 0px\",\n width: \"100%\",\n height: \"4px\",\n },\n arrived: {\n background: theme.colors.clearGreen,\n },\n notArrived: {\n background: theme.colors.clearRed,\n },\n confirmed: {\n background: theme.colors.clearBlue,\n },\n notConfirmed: {\n background: theme.colors.grey4,\n },\n content: {\n padding: \"9px 8px 9px 8px\",\n height: \"100%\",\n },\n contentNotArrive: {\n background: theme.colors.grey1,\n },\n customerTitle: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: theme.colors.grey7,\n },\n customerTitleBlocked: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: \"rgba(50, 57, 71, 0.76);\",\n },\n customerNotArrived: {\n ...theme.typography.caption1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n textDecoration: \"line-through\",\n },\n hoursText: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n marginTop: 2,\n },\n hoursTextBlocked: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n marginTop: 2,\n },\n personChargeText: {\n ...theme.typography.caption2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n marginTop: 4,\n },\n isAppointmentCustomerSite: {\n color: theme.colors.clearMain,\n },\n personChargeTextBlocked: {\n ...theme.typography.caption2,\n fontWeight: \"bold\",\n color: \"rgba(50, 57, 71, 0.76)\",\n marginTop: 8,\n },\n tooltipContainer: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n tooltipCustomerNameBox: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 10,\n color: theme.colors.grey5,\n },\n tooltipAppointmentTime: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 9,\n color: theme.colors.grey5,\n },\n tooltipUserName: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 9,\n color: theme.colors.grey5,\n },\n personWithDot: {\n display: \"flex\",\n alignItems: \"center\",\n \"& .dot\": {\n width: 4,\n height: 4,\n display: \"block\",\n backgroundColor: theme.colors.grey4,\n borderRadius: \"50%\",\n marginRight: 7\n }\n },\n dot: {\n width: 4,\n height: 4,\n display: \"block\",\n position: \"absolute\",\n left: 2,\n top: 4,\n backgroundColor: theme.colors.grey4,\n borderRadius: \"50%\",\n },\n serviceItemText: {\n marginTop: 0,\n marginBottom: 4,\n \"& .MuiTypography-root\": {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"9px\",\n lineHeight: \"11px\",\n color: theme.colors.grey4,\n }\n },\n serviceItemsList: {\n padding: \"0\",\n },\n serviceItemsTooltipList: {\n padding: \"0px 0px 3px 0px\",\n },\n serviceSingleItemText: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"9px\",\n lineHeight: \"11px\",\n color: theme.colors.grey4,\n marginBottom: 4\n },\n serviceListItem: {\n padding: \"0px 0px 0px 12px\"\n },\n popper:{\n [`& .MuiTooltip-tooltip`]: {\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: theme.colors.grey1,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey5,\n boxShadow: \"0px 0px 4px #00000034\",\n position: \"absolute\",\n height: \"auto\",\n width: \"max-content\",\n top: 35,\n left: -55\n },\n },\n establishmentRow: {\n display: \"flex\",\n alignItems: \"center\",\n gap: 4,\n }\n}));\n\nexport default useAppointmentCardStyles;\n","import React, { useEffect } from \"react\";\nimport { ListItem, Typography } from '@material-ui/core';\nimport { forwardRef } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { AppointmentStatus } from \"../../../../../models/enums/appointment-status\";\nimport { Appointment } from \"../../../../../models/appointment\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\nimport { ComputerIcon, EstablishmentIcon } from \"../../../../../assets/icons\";\nimport List from \"@material-ui/core/List\";\nimport ListItemText from \"@material-ui/core/ListItemText\";\nimport { AppointmentCreatedBy } from \"../../../../../models/enums/appointment-created-by\";\nimport useStyles from \"./css\";\nimport { schedulerActions } from \"../../../../../redux/scheduler-slice\";\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { RootState } from \"../../../../../redux/store\";\n\nexport type AppointmentCardProps = {\n appointment: Appointment;\n enableTooltip?: boolean;\n onClick: () => void;\n anchorEl?: any;\n};\n\nconst AppointmentCard = forwardRef(\n (\n { appointment, onClick, enableTooltip, anchorEl }: AppointmentCardProps,\n ref: React.ForwardedRef<HTMLDivElement>\n ) => {\n const classes = useStyles();\n \n const { setTooltipAppointment } = schedulerActions;\n \n const dispatch = useDispatch();\n const appointmentId = useSelector((state: RootState) => state.scheduler.appointmentId);\n const tooltipAppointments = useSelector((state: RootState) => state.scheduler.tooltipAppointments);\n \n useEffect(() => {\n if (appointmentId && appointmentId === appointment.appointmentId) {\n // onClick();\n anchorEl?.scrollIntoView({ block: \"center\" });\n const current = tooltipAppointments.find((a) => a.appointmentId === appointment.appointmentId);\n if (current) {\n current.elementRef = anchorEl;\n dispatch(\n setTooltipAppointment([\n ...tooltipAppointments.filter((a) => a.appointmentId !== current.appointmentId),\n current,\n ])\n );\n }\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointmentId]);\n \n const getStatus = (status: AppointmentStatus): string => {\n switch (status) {\n case AppointmentStatus.Arrived:\n return classes.arrived;\n case AppointmentStatus.NotArrived:\n return classes.notArrived;\n case AppointmentStatus.NotConfirmed:\n return classes.notConfirmed;\n case AppointmentStatus.Confirmed:\n default:\n return classes.confirmed;\n }\n };\n \n const dateFormat = (date: Date): string => {\n const formatDate = date.toTimeString().split(\" \")[0].split(\":\");\n return `${formatDate[0]}:${formatDate[1]}`;\n };\n \n //const restProps = { ...otherProps, style, data, children };\n const isNotArrived = appointment.status === AppointmentStatus.NotArrived;\n \n return (\n <Tooltip\n classes={{\n popper: classes.popper\n }}\n PopperProps={{\n popperOptions: {\n positionFixed: true\n }\n }}\n placement=\"top\"\n title={<div className={classes.tooltipContainer}>\n <div className={classes.tooltipCustomerNameBox}>\n <ComputerIcon style={{ position: \"relative\", left: -5, marginRight: -5 }}/> {appointment.customerName}\n </div>\n {appointment?.services?.length === 1\n ? <span style={{ marginTop: 2, marginBottom: 4 }} className={classes.serviceSingleItemText}>{appointment.services[0]}</span>\n : <List className={classes.serviceItemsTooltipList}>\n {appointment?.services?.map((item, index) => (\n <ListItem classes={{ root: classes.serviceListItem }} key={index}>\n <div className={classes.dot}></div>\n <ListItemText className={classes.serviceItemText} primary={item}/>\n </ListItem>\n ))}\n </List>}\n <div className={classes.tooltipAppointmentTime}>\n {dateFormat(appointment.startDate.toJSDate()) +\n \" - \" +\n dateFormat(appointment.endDate.toJSDate())}\n </div>\n {appointment?.users?.length === 1\n ? <div className={classes.tooltipUserName}>\n {appointment.users[0]}\n </div>\n : <>\n {appointment?.users?.map((item, index) => (\n <div className={`${classes.tooltipUserName} ${classes.personWithDot}`}>\n <div className=\"dot\"></div>\n {item}\n </div>\n ))}\n </>}\n {\n appointment?.establishmentName &&\n <div className={classes.establishmentRow}>\n <EstablishmentIcon />\n <Typography className={`${classes.tooltipAppointmentTime}`}>\n {appointment?.establishmentName}\n </Typography>\n </div>\n }\n </div>\n }>\n \n <div className={classes.root} style={{height: \"100%\"}}>\n <div ref={ref} id={appointment.appointmentId as string} onClick={onClick} style={{height: \"100%\"}}>\n <div className={`${classes.header} ${getStatus(appointment.status)}`}></div>\n <div\n className={`${classes.content} ${\n isNotArrived ? classes.contentNotArrive : \"\"\n }`}\n >\n <Typography style={{ display: \"inline-block\" }}\n className={`${isNotArrived ? classes.customerNotArrived : (classes.customerTitle)}\n ${appointment.createdBy === AppointmentCreatedBy.Customer ? classes.isAppointmentCustomerSite : null}`}\n >\n {appointment.createdBy === AppointmentCreatedBy.Customer && <ComputerIcon style={{ position: \"relative\", left: -5, marginRight: -5 }}/>}\n {appointment.customerName}\n </Typography>\n {appointment?.services?.length === 1\n ? <div className={classes.serviceSingleItemText}>{appointment.services[0]}</div>\n : <List className={classes.serviceItemsList}>\n {appointment?.services?.map((item, index) => (\n <ListItem classes={{ root: classes.serviceListItem }} key={index}>\n <div className={classes.dot}></div>\n <ListItemText className={classes.serviceItemText} primary={item}/>\n </ListItem>\n ))}\n </List>}\n <Typography className={classes.hoursText}>\n {dateFormat(appointment.startDate.toJSDate()) +\n \" - \" +\n dateFormat(appointment.endDate.toJSDate())}\n </Typography>\n {appointment?.users?.length === 1\n ? <Typography className={classes.personChargeText}>\n {appointment.users[0]}\n </Typography>\n : <>\n {appointment?.users?.map((item, index) => (\n <Typography className={`${classes.personChargeText} ${classes.personWithDot}`}>\n <div className=\"dot\"></div>\n {item}\n </Typography>\n ))}\n </>}\n {\n appointment?.establishmentName &&\n <div className={classes.establishmentRow}>\n <EstablishmentIcon />\n <Typography className={classes.hoursText}>\n {appointment?.establishmentName}\n </Typography>\n </div>\n }\n </div>\n </div>\n </div>\n </Tooltip>\n );\n }\n);\n\nexport default AppointmentCard;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"18px 24px 24px 24px\",\n width: 464,\n height: 288,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteAppointment: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { TrashIcon, CrossIcon } from \"../../../assets/icons\";\n\nimport useStyles from \"./css\";\nimport { AppointmentDeleteModalProps } from \"./props\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nconst AppointmentDeleteModal = (props: AppointmentDeleteModalProps) => {\n const { open, appointment, service, onClose, onDelete } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const [disableButton, setDisableButton] = useState<boolean>(false);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n useEffect(() => {\n setDisableButton(false);\n }, [appointment]);\n\n const date = (startDate: Date, endDate: Date): string => {\n const start = new Date(startDate);\n const end = new Date(endDate);\n \n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n\n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n\n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n\n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n\n const timeDifference = (today: Date, endDate: Date): string => {\n const hours = parseInt(\n `${\n (Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60 * 60)) % 24\n }`\n );\n const minutes = parseInt(\n `${(Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60)) % 60}`\n );\n if (hours > 0 && minutes < 1) {\n return `${hours}hr`;\n } else if (hours < 1 && minutes > 0) {\n return `${minutes}min`;\n } else {\n return `${hours}hr ${minutes}min`;\n }\n };\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Delete the appointment?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {appointment?.customerName}\n {service ? ` - ${service}` : \"\"}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalDateText}>\n {`${date(\n appointment?.startDate.toJSDate(),\n appointment?.endDate.toJSDate()\n )} (${timeDifference(\n appointment?.startDate.toJSDate(),\n appointment?.endDate.toJSDate()\n )})`}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n disabled={disableButton}\n className={`${classes.button} ${classes.deleteAppointment}`}\n onClick={() => {\n setDisableButton(true);\n onDelete(appointment);\n }}\n >\n {t(\"Delete appointment\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default AppointmentDeleteModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n label: {\n display: \"block\",\n color: \"#4a4d51\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\n\nimport Textarea from \"./../Textarea\";\nimport useStyles from \"./css\";\nimport { TextareaWithLabelProps } from \"./props\";\n\nconst TextareaWithLabel = (props: TextareaWithLabelProps) => {\n const {\n id,\n label,\n labelClass,\n inputClass,\n name,\n value,\n isValid,\n placeholder,\n width,\n onChange,\n onKeyPress,\n inputDisabled,\n inputReadOnly,\n showCounter,\n onClickInput,\n onBlurInput,\n maxLength,\n minRows,\n maxRows\n } = props;\n const classes = useStyles();\n\n const getId = (): string => {\n if (id) {\n return id;\n }\n\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(\n /[xy]/g,\n function (c) {\n var r = (Math.random() * 16) | 0,\n v = c === \"x\" ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n }\n );\n };\n\n const LabelComponent = label;\n\n const [inputId] = useState<string>(id || getId());\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n const handleOnKeyPress = (event: any) => {\n if (onKeyPress) {\n onKeyPress(event);\n }\n };\n\n return (\n <div className={classes.root}>\n <label htmlFor={inputId} className={labelClass ?? classes.label}>\n {typeof label === \"string\" ? label : <LabelComponent />}\n </label>\n <Textarea\n id={inputId}\n name={name}\n minRows={minRows}\n maxRows={maxRows}\n showCounter={showCounter}\n value={value}\n placeholder={placeholder}\n width={width}\n inputClass={inputClass}\n isValid={isValid}\n onChange={handleOnChange}\n onKeyPress={handleOnKeyPress}\n disabled={inputDisabled}\n readOnly={inputReadOnly}\n onClick={onClickInput}\n onBlur={onBlurInput}\n maxLength={maxLength}\n />\n </div>\n );\n};\n\nexport default TextareaWithLabel;\n","export default class Service {\n id: string | null;\n name: string;\n price?: number;\n categoryId: string;\n category: string;\n duration?: number;\n recurrenceId: string;\n recurrence: string;\n\n // (optional)\n workAreaId?: string | null;\n workArea?: string;\n photoName?: string;\n photoURL?: string;\n file?: File | null;\n description?: string;\n notes?: string;\n\n constructor(x?: Service) {\n if (typeof x === \"object\" && x != null) {\n this.id = x.id;\n this.name = x.name || \"\";\n this.price = x.price;\n this.categoryId = x.categoryId;\n this.category = x.category || \"\";\n this.photoName = x.photoName || \"\";\n this.photoURL = x.photoURL || \"\";\n this.duration = x.duration;\n this.recurrenceId = x.recurrenceId || \"\";\n this.recurrence = x.recurrence || \"\";\n this.description = x.description || \"\";\n this.notes = x.notes || \"\";\n this.workAreaId = x.workAreaId || null;\n }\n else {\n this.id = null;\n this.name = \"\";\n //this.price = null;\n //this.duration = null;\n this.photoName = \"\";\n this.photoURL = \"\";\n this.categoryId = \"\";\n this.category = \"\";\n this.recurrenceId = \"\";\n this.recurrence = \"\";\n this.description = \"\";\n this.notes = \"\";\n this.workAreaId = null;\n }\n }\n}\n\n//Form Valid\nexport interface ServiceValidator {\n name?: boolean;\n price?: boolean;\n categoryId?: boolean;\n duration?: boolean;\n recurrenceId?: boolean;\n}\n\n","export class Response {\n entity: any[] | null;\n total: number | null;\n\n constructor(entity?: any, total?: number) {\n if ((typeof entity === \"object\" || typeof entity === \"string\" )&& entity !== null && entity !== undefined) {\n this.entity = entity;\n this.total = total ?? 0;\n\n } else {\n this.entity = null;\n this.total = null;\n }\n }\n}\n","import { SelectServiceModel } from \"./select-service-model\";\n\nexport class SelectGroupServiceModel {\n category: string | null;\n services: SelectServiceModel[] | null;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.category = x.category;\n this.services = x.services;\n } else {\n this.category = null;\n this.services = null;\n }\n }\n}\n","import { ServiceSelectModel } from \"./service-select-model\";\n\nexport class ServiceGroupModel {\n category: string | null;\n services: ServiceSelectModel[] | null;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.category = x.category;\n this.services = x.services;\n } else {\n this.category = null;\n this.services = null;\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport Service from \"../models/service\";\nimport { Response } from \"./../models/response\";\nimport { SelectGroupServiceModel } from \"../models/select-group-service-model\";\nimport { ServiceGroupModel } from \"../models/service-group-model\";\nimport { ImportExcelResponse } from \"../models/import-excel-response\";\n\nexport default class ServicesService {\n private static baseUrl: string = \"/service\";\n\n static saveImage(file: File): Promise<any> {\n const formData = new FormData();\n formData.append(\"File\", file);\n\n return ApiClient.post(\n `${this.baseUrl}/saveserviceimage`,\n formData,\n {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }\n })\n .then(data => {\n return data;\n });\n }\n\n\n static getImage(fileName: string): Promise<any> {\n\n let urlEndpoint = `${this.baseUrl}/getserviceimage?FileName=${fileName}`;\n\n return ApiClient.get(urlEndpoint)\n .then((data) => {\n return data;\n });\n }\n\n static getServices(\n page: number,\n pageSize: number,\n order?: string,\n orderBy?: string,\n establishmentAccountId?: string,\n value?: string,\n properties?: string[]\n ): Promise<Response> {\n\n let urlEndpoint = `${this.baseUrl}/getservices?page=${page}&pageSize=${pageSize}`;\n\n if (order && orderBy) {\n urlEndpoint += `&order=${order}&orderBy=${orderBy}`;\n }\n if (establishmentAccountId) {\n urlEndpoint += `&accountId=${establishmentAccountId}`;\n }\n if (value && properties && properties.length > 0) {\n urlEndpoint += `&value=${value}`;\n for (const property of properties) {\n urlEndpoint += `&Properties=${property}`;\n }\n }\n\n return ApiClient.get(urlEndpoint)\n .then((data) => {\n\n let services: Service[] = [];\n const list = data.services;\n\n list.forEach((data: any, index: number) => {\n services.push(data);\n });\n\n return new Response(services, data.total);\n\n });\n }\n\n static createService(entity: Service, establishmentAccountId?: string,): Promise<Service> {\n const request = {\n ...entity,\n AccountId: establishmentAccountId\n };\n return ApiClient.post(`${this.baseUrl}/createservice`, request).then(\n (data) => {\n return new Service(data.service);\n }\n );\n }\n\n static updateService(entity: Service, establishmentAccountId?: string,): Promise<Service> {\n const request = {\n ...entity,\n accountId: establishmentAccountId\n };\n return ApiClient.put(`${this.baseUrl}/updateservice`, request).then(\n (data) => {\n return new Service(data.service);\n }\n );\n }\n\n static deleteService(entity: Service): Promise<any> {\n return ApiClient.remove(`${this.baseUrl}/deleteservice?id=${entity.id}`).then(\n (data) => {\n return {\n entity: new Service(data.service),\n forbiddenDelete: data.forbiddenDelete,\n };\n }\n );\n }\n\n\n static getRecurrences(): Promise<Response> {\n\n let urlEndpoint = `/account/getrecurrences`;//TODO: CHANGE\n\n return ApiClient.get(urlEndpoint)\n .then((data) => {\n return new Response(data.recurrences, data.total);\n });\n }\n\n static getServicesSelect(): Promise<SelectGroupServiceModel[]> {\n let urlEndpoint = `${this.baseUrl}/getservicestoappt`;\n\n return ApiClient.get(urlEndpoint).then((data) => {\n return data.services.map(\n (service: any) => new SelectGroupServiceModel(service)\n );\n });\n }\n \n static async getServicesGroupByCategory(): Promise<ServiceGroupModel[]> {\n const data = await ApiClient.get(\n `${this.baseUrl}/GetServicesGroupByCategory`\n );\n return data.services.map((service: any) => new ServiceGroupModel(service));\n }\n\n static createServicesFromFile(file: File, establishmentAccountId?: string): Promise<ImportExcelResponse> {\n const formData = new FormData();\n formData.append(\"File\", file);\n\n if (establishmentAccountId) {\n formData.append(\"AccountId\", establishmentAccountId);\n }\n\n return ApiClient.post(`${this.baseUrl}/createfromfile`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n }, \n }).then((data) => {\n return new ImportExcelResponse(data);\n });\n }\n\n}\n","\nexport class CreateFollowUpModel {\n \n appointmentId: string | null;\n customerId: string | null;\n serviceId: string | null;\n scheduled: Date | null;\n notes: string | null;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.appointmentId = x.appointmentId;\n this.customerId = x.customerId;\n this.serviceId = x.serviceId;\n this.scheduled = x.scheduled;\n this.notes = x.notes;\n } else {\n this.appointmentId = null;\n this.customerId = null;\n this.serviceId = null;\n this.scheduled = null;\n this.notes = null;\n }\n\n }\n}\n","export const MobileMask = [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/];\n\nexport const CardNumberMask = [/\\d/, /\\d/, /\\d/, /\\d/, \"-\", \n /\\d/, /\\d/, /\\d/, /\\d/, \"-\",\n /\\d/, /\\d/, /\\d/, /\\d/, \"-\",\n /\\d/, /\\d/, /\\d/, /\\d/];\n\nexport const ClabeMask = [/\\d/, /\\d/, /\\d/, /\\d/, \"-\", \n /\\d/, /\\d/, /\\d/, /\\d/, \"-\",\n /\\d/, /\\d/, /\\d/, /\\d/, \"-\",\n /\\d/, /\\d/, /\\d/, /\\d/, \"-\",\n /\\d/, /\\d/];\n\nexport function GetMobileMask(digits: number): any {\n \n const mask: { [key: string] : any } = {\n \"7\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"8\": [/\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"9\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/],\n \"10\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"11\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"12\": [/\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/]\n };\n \n return mask[digits] || mask[\"10\"];\n}\n\n\nexport function GetMobileMaskByTemp(template: string): any {\n \n const mask: { [key: string] : any } = {\n \"000-0000\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"0000-0000\": [/\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"0-000-0000\": [/\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"00-000-000\": [/\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/],\n \"0000-00-00\": [/\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, \"-\", /\\d/, /\\d/],\n \"00-0000-000\": [/\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/],\n \"000-000-000\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/],\n \"000 000-000\": [/\\d/, /\\d/, /\\d/, \" \", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/],\n \"000-000-0000\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"00000-00000\": [/\\d/, /\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, /\\d/],\n \"000-0000-0000\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"000-000-000000\": [/\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, /\\d/, /\\d/],\n \"0-000-000-0000\": [/\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/],\n \"00-0000-00000\": [/\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, \"-\", /\\d/, /\\d/, /\\d/, /\\d/, /\\d/]\n };\n \n return mask[template] || mask[\"000-000-0000\"];\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n body: {\n \".ant-picker-dropdown\": {\n zIndex: 99999999\n },\n },\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n \n },\n modalPaper: {\n zIndex: 100,\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid white\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"30px\",\n width: 800,\n height: 600,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid white\",\n },\n },\n \n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n create: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n \n requiredText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n marginLeft: 2,\n marginTop: 9,\n },\n requiredSymbol: {\n color: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n \n labelText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: 700,\n marginLeft: 2,\n marginTop: 7,\n },\n\n selectStyle: {\n color: Color.gray5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: \"100%\",\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: Color.gray5,\n cursor: \"pointer\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n fontWeight: \"normal\",\n opacity: 0.8,\n }\n }\n },\n \n inputTextareaClass: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n fontWeight: \"normal\",\n opacity: 0.8,\n },\n },\n \n labelNotes: {\n ...theme.typography.txtBody3,\n color: \"#8F9AA4\",\n fontWeight: 400,\n fontSize: 11,\n marginLeft: 2,\n marginTop: 7,\n },\n divClock: {\n position: \"relative\",\n right: 10,\n top: -32,\n float: \"right\"\n },\n \n dateRoot: {\n width: 36,\n height: 36,\n margin: \"0 2px\",\n },\n date: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey7,\n width: 36,\n height: 36,\n margin: \"0 2px\",\n },\n currentDate: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n selectedDate: {\n fontWeight: \"bold\",\n background: theme.colors.clearMain,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearMain,\n },\n },\n stepCaption: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey6,\n },\n availableHours: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey6,\n },\n dateNotSelected: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey3,\n },\n dateSelected: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n ulSchedule: {\n flexWrap: \"wrap\",\n display: \"flex\",\n listStyle: \"none\",\n padding: 0,\n },\n liSchedule: {\n width: 116,\n height: 32,\n marginRight: 16,\n marginBottom: 16,\n borderRadius: 51,\n cursor: \"pointer\",\n display: \"flex\",\n flex: \"0 0 30%\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\",\n boxSizing: \"border-box\",\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n border: `1px solid ${theme.colors.clearMain}`,\n \"&:nth-child(3n + 3)\": {\n marginRight: 0,\n },\n \"&:hover\": {\n background: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n },\n liScheduleActive: {\n background: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n\n \n selectService: {\n ...theme.typography.txtBody2,\n background: theme.colors.grey1,\n backgroundColor: theme.colors.grey1,\n border: `1px solid ${theme.colors.grey2}`,\n borderRadius: 5,\n height: 40,\n padding: \"0px 9px 0px\",\n },\n selectRoot: {\n color: theme.colors.grey5,\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n selected: {\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n placeholder: {\n color: \"#676767\",\n opacity: \"0.42\",\n \"&.Mui-disabled\": {\n opacity: \"0.42\",\n },\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n group: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n \"&.Mui-disabled\": {\n opacity: 1,\n },\n },\n divFlag: {\n display: \"inline-block\",\n position: \"relative\",\n height: 20,\n width: 20,\n \"& svg\": {\n width: \"20px !important\", \n height: \"20px !important\"\n }\n },\n divCode: {\n position: \"relative\",\n display: \"inline-block\",\n fontStyle: \"normal\",\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: \"bold\",\n width: 40,\n textAlign: \"center\"\n },\n divMobile: {\n display: \"inline-block\",\n }\n \n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryAllIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <circle cx=\"12\" cy=\"12\" r=\"10\" fill=\"#35ABDE\"/>\n <path d=\"M19.4245 4.58174C18.4512 3.59885 17.2933 2.81795 16.0173 2.28389C14.7414 1.74984 13.3725 1.47316 11.9892 1.46976C10.606 1.46635 9.23573 1.73629 7.95715 2.26405C6.67856 2.79182 5.51685 3.56702 4.53876 4.54511C3.56067 5.5232 2.78547 6.6849 2.25771 7.96349C1.72994 9.24208 1.46001 10.6123 1.46341 11.9956C1.46682 13.3788 1.74349 14.7477 2.27754 16.0237C2.8116 17.2997 3.5925 18.4575 4.5754 19.4308C5.54866 20.4137 6.70654 21.1946 7.98251 21.7287C9.25849 22.2627 10.6274 22.5394 12.0106 22.5428C13.3939 22.5462 14.7641 22.2763 16.0427 21.7485C17.3213 21.2207 18.483 20.4455 19.4611 19.4674C20.4392 18.4894 21.2144 17.3276 21.7422 16.0491C22.2699 14.7705 22.5399 13.4002 22.5365 12.017C22.533 10.6338 22.2564 9.26483 21.7223 7.98886C21.1883 6.71289 20.4074 5.55501 19.4245 4.58174ZM2.99993 12.0063C2.99959 11.2097 3.1052 10.4167 3.31399 9.64799C3.65805 10.3886 4.15774 11.0285 4.49758 11.7883C4.9368 12.7652 6.11618 12.4942 6.63696 13.3502C7.09915 14.11 6.60555 15.071 6.95149 15.866C7.20274 16.443 7.79524 16.5691 8.20399 16.991C8.62165 17.4166 8.61274 17.9997 8.67649 18.5547C8.74843 19.2068 8.86511 19.8532 9.02571 20.4892C9.02571 20.4939 9.02571 20.4991 9.02946 20.5038C5.5218 19.2719 2.99993 15.9283 2.99993 12.0063ZM11.9999 21.0063C11.4973 21.0061 10.9956 20.9641 10.4999 20.8807C10.5051 20.7536 10.5074 20.635 10.5201 20.5525C10.634 19.8072 11.0071 19.0783 11.5106 18.5205C12.0079 17.9702 12.6895 17.598 13.1095 16.9736C13.521 16.3642 13.6443 15.5439 13.4746 14.8319C13.2248 13.78 11.7956 13.4289 11.0249 12.8585C10.582 12.5303 10.1877 12.0231 9.60602 11.9819C9.3379 11.9632 9.11337 12.0208 8.84759 11.9524C8.60384 11.8891 8.41258 11.7578 8.1529 11.7921C7.66774 11.8558 7.36165 12.3742 6.8404 12.3039C6.34587 12.2378 5.83633 11.6589 5.72383 11.1878C5.57946 10.5822 6.05852 10.3858 6.5718 10.3319C6.78602 10.3094 7.02649 10.285 7.23227 10.3638C7.50321 10.4641 7.63118 10.7294 7.87446 10.8635C8.33055 11.1138 8.4229 10.7139 8.35305 10.3089C8.24852 9.70237 8.12665 9.45534 8.66759 9.03768C9.04259 8.74987 9.36321 8.54174 9.30321 8.02471C9.26759 7.72096 9.10118 7.58362 9.25634 7.28127C9.37399 7.05112 9.69696 6.84346 9.90743 6.70612C10.4507 6.35174 12.2348 6.37799 11.5059 5.38612C11.2916 5.09502 10.8965 4.57471 10.5215 4.50346C10.0527 4.41487 9.84462 4.93799 9.5179 5.16862C9.1804 5.40721 8.52321 5.67815 8.18524 5.30924C7.73055 4.81284 8.48665 4.65018 8.65399 4.30331C8.73134 4.14159 8.65399 3.91706 8.52368 3.70565C8.69274 3.6344 8.86462 3.56831 9.0393 3.50737C9.14878 3.58823 9.27865 3.63693 9.4143 3.64799C9.7279 3.66862 10.0237 3.49893 10.2974 3.71268C10.6012 3.94706 10.8201 4.24331 11.2232 4.31643C11.6132 4.38721 12.0262 4.15987 12.1227 3.76049C12.1813 3.51768 12.1227 3.26127 12.0665 3.01049C13.8196 3.02058 15.5312 3.54561 16.9884 4.52034C16.8946 4.48471 16.7826 4.48893 16.6443 4.55315C16.3598 4.68534 15.9567 5.0219 15.9234 5.35565C15.8854 5.7344 16.4442 5.78784 16.7095 5.78784C17.1079 5.78784 17.5115 5.60971 17.3831 5.1494C17.3273 4.94971 17.2513 4.74206 17.129 4.61643C17.4231 4.8205 17.7048 5.04183 17.9727 5.27924C17.9685 5.28346 17.9643 5.28721 17.9601 5.2919C17.6901 5.57315 17.3765 5.79581 17.1918 6.13799C17.0615 6.37893 16.9148 6.49331 16.6509 6.55565C16.5056 6.58987 16.3396 6.60252 16.2177 6.70002C15.8784 6.96721 16.0715 7.6094 16.3931 7.80206C16.7995 8.04534 17.4023 7.93096 17.7088 7.58362C17.9484 7.31174 18.0895 6.83971 18.5202 6.84018C18.7099 6.83979 18.8921 6.91404 19.0274 7.0469C19.2056 7.23159 19.1704 7.40409 19.2084 7.63471C19.2754 8.0444 19.6368 7.82221 19.8567 7.61549C20.0169 7.90069 20.1615 8.19441 20.2898 8.49534C20.0479 8.84362 19.8557 9.22331 19.274 8.81737C18.9257 8.57409 18.7115 8.22112 18.2742 8.11143C17.8921 8.01768 17.5007 8.11518 17.1234 8.18034C16.6945 8.25487 16.1859 8.28768 15.8606 8.61252C15.546 8.92565 15.3796 9.34471 15.0449 9.65924C14.3976 10.2686 14.1243 10.9338 14.5434 11.7953C14.9465 12.6236 15.7898 13.0731 16.6996 13.0141C17.5935 12.9546 18.5221 12.4361 18.4963 13.735C18.487 14.1949 18.5831 14.5132 18.7242 14.9402C18.8549 15.3339 18.846 15.7155 18.876 16.1219C18.9046 16.5978 18.979 17.0698 19.0982 17.5314C18.258 18.6132 17.1817 19.4886 15.9515 20.0909C14.7213 20.6931 13.3697 21.0062 11.9999 21.0063Z\" fill=\"#94E8C6\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryAllIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryDEUIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props}>\n <path d=\"M11.9626 0.75C7.0501 0.75 2.8876 3.9 1.3501 8.25H22.5751C21.0376 3.9 16.8751 0.75 11.9626 0.75Z\" fill=\"#3E4347\"/>\n <path d=\"M11.9626 23.25C16.8751 23.25 21.0376 20.1375 22.5751 15.75H1.3501C2.8876 20.1375 7.0501 23.25 11.9626 23.25Z\" fill=\"#FFE62E\"/>\n <path d=\"M1.3499 8.25C0.937402 9.4125 0.712402 10.6875 0.712402 12C0.712402 13.3125 0.937402 14.5875 1.3499 15.75H22.5749C22.9874 14.5875 23.2124 13.3125 23.2124 12C23.2124 10.6875 22.9874 9.4125 22.5749 8.25H1.3499Z\" fill=\"#ED4C5C\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryDEUIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryAGOIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 23.25C18.225 23.25 23.25 18.225 23.25 12H0.75C0.75 18.225 5.775 23.25 12 23.25Z\" fill=\"#3E4347\"/>\n <path d=\"M12 0.75C5.775 0.75 0.75 5.775 0.75 12H23.25C23.25 5.775 18.225 0.75 12 0.75Z\" fill=\"#ED4C5C\"/>\n <path d=\"M10.3125 9.1874L9.825 10.6874L11.1 9.7499L12.4125 10.6874L11.925 9.1874L13.2 8.2499H11.5875L11.1 6.7124L10.6125 8.2499H9L10.3125 9.1874Z\" fill=\"#FFE62E\"/>\n <path d=\"M18 18.2247C17.8125 17.9247 17.5875 17.6997 17.2875 17.4372C16.9875 17.1747 16.575 16.8747 16.2375 16.5747L15.6375 17.2497C15.6 17.2872 15.6375 17.3622 15.6375 17.3622C16.3125 17.4747 16.5 17.6997 16.7625 17.9247C17.1375 18.2997 17.25 18.7122 17.5125 18.8997C17.9625 19.1622 18.3 18.6747 18 18.2247Z\" fill=\"#FFE62E\"/>\n <path d=\"M12.675 15.6375C12.0375 15.8625 11.325 15.9375 10.6125 15.8625C9.67495 15.75 8.81245 15.4125 8.09995 14.8125L7.38745 15.675C7.68745 15.9375 8.02495 16.125 8.32495 16.3125L8.09995 16.7625C8.47495 16.95 8.84995 17.1375 9.26245 17.25L9.41245 16.8C9.78745 16.9125 10.1625 16.9875 10.5375 17.025L10.5 17.475C10.9125 17.5125 11.325 17.5125 11.7375 17.475L11.7 16.9875C12.075 16.95 12.45 16.875 12.825 16.7625L12.975 17.2125C13.1625 17.1375 13.35 17.1 13.575 16.9875L13.3125 15.975L12.675 15.6375Z\" fill=\"#FFE62E\"/>\n <path d=\"M15.8625 11.6248C15.7125 12.8998 15.1125 13.9873 14.2125 14.7748L15.5625 15.7123C15.75 15.5248 15.9 15.3748 16.05 15.1873L15.675 14.8873C15.9375 14.5873 16.125 14.2498 16.3125 13.9498L16.7625 14.1748C16.95 13.7998 17.1375 13.4248 17.25 13.0123L16.8 12.8623C16.9125 12.4873 16.9875 12.1123 17.025 11.7373L17.5125 11.7748C17.55 11.3623 17.55 10.9498 17.5125 10.5373L17.025 10.5748C16.9875 10.1998 16.9125 9.82481 16.8 9.44981L17.25 9.2998C17.1375 8.8873 16.9875 8.51231 16.7625 8.13731L16.3125 8.3623C16.125 8.0248 15.9375 7.68731 15.675 7.38731L16.05 7.0873C15.7875 6.7498 15.4875 6.4873 15.15 6.1873L14.85 6.5623C14.55 6.2998 14.25 6.1123 13.9125 5.9248L14.1375 5.4748C13.7625 5.2873 13.3875 5.0998 12.975 4.9873L12.825 5.4748C12.4875 5.3623 12.1125 5.2873 11.7375 5.2498L11.625 6.3748C14.2125 6.6373 16.125 8.99981 15.8625 11.6248Z\" fill=\"#FFE62E\"/>\n <path d=\"M13.9875 15.45C12.7125 14.55 11.4375 13.65 10.3125 12.6L10.3875 12.525C11.475 13.5375 12.7875 14.475 14.025 15.3375C14.6625 15.7875 15.3 16.2375 15.9 16.6875L16.125 16.5C14.025 15 9.07497 11.55 8.99997 10.3125C8.02497 12.225 9.26247 13.35 10.05 13.8375C12.075 15 13.425 15.75 15.5625 17.175L15.8625 16.8375C15.2625 16.3125 14.625 15.8625 13.9875 15.45Z\" fill=\"#FFE62E\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryAGOIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryARGIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M0.75 12C0.75 14.2125 1.3875 16.275 2.475 18H21.4875C22.575 16.275 23.2125 14.2125 23.2125 12C23.2125 9.7875 22.575 7.725 21.4875 6H2.475C1.3875 7.725 0.75 9.7875 0.75 12Z\" fill=\"#F9F9F9\"/>\n <path d=\"M21.5251 6C19.5376 2.85 16.0126 0.75 12.0001 0.75C7.9876 0.75 4.4626 2.85 2.4751 6H21.5251Z\" fill=\"#B4D7EE\"/>\n <path d=\"M2.4751 18C4.4626 21.15 7.9876 23.25 12.0001 23.25C16.0126 23.25 19.5376 21.15 21.5251 18H2.4751Z\" fill=\"#B4D7EE\"/>\n <path d=\"M17.1374 11.925L14.0624 11.8125V11.775C14.5499 11.7 14.9249 11.4 15.4499 11.4375C16.0874 11.5125 16.4624 11.1375 16.6874 11.0625C16.9499 10.9875 17.0999 11.1375 17.0999 11.0625C17.1374 10.9875 16.9499 10.8375 16.5749 10.875C16.2374 10.9125 16.1249 11.2125 15.3374 11.1375C14.6624 11.1 14.4374 11.3625 13.9499 11.3625V11.325L16.7249 10.05C16.7249 10.05 16.7999 10.0125 16.7999 9.9375C16.7624 9.8625 16.6874 9.9 16.6874 9.9L13.8749 11.025V10.9875C14.2874 10.725 14.5124 10.3125 15.0374 10.1625C15.6374 9.975 15.8624 9.525 16.0499 9.3375C16.2374 9.15 16.4624 9.2625 16.4624 9.1875C16.4624 9.1125 16.2374 9.0375 15.9374 9.225C15.6374 9.4125 15.6374 9.7125 14.8874 9.9375C14.2499 10.125 14.1374 10.4625 13.6874 10.6875L13.6499 10.65L15.7499 8.4C15.7499 8.4 15.8249 8.325 15.7874 8.2875C15.7499 8.25 15.6749 8.325 15.6749 8.325L13.4249 10.425L13.3874 10.3875C13.6874 9.975 13.7249 9.525 14.1374 9.1875C14.6249 8.775 14.6249 8.2875 14.7374 8.0625C14.8499 7.8375 15.0749 7.8375 15.0374 7.7625C14.9999 7.6875 14.7749 7.725 14.5499 7.9875C14.3249 8.2875 14.4374 8.55 13.8749 9.0375C13.3874 9.45 13.3874 9.825 13.0874 10.1625C13.0874 10.1625 13.0499 10.1625 13.0499 10.125L14.0999 7.2375C14.0999 7.2375 14.1374 7.1625 14.0624 7.125C13.9874 7.0875 13.9499 7.2 13.9499 7.2L12.6749 9.975H12.6374C12.7499 9.4875 12.6374 9.0375 12.8624 8.5875C13.1624 8.025 12.9749 7.5375 12.9749 7.3125C13.0124 7.05 13.1999 6.975 13.1624 6.9375C13.1249 6.8625 12.8999 7.0125 12.7874 7.35C12.7124 7.6875 12.8999 7.9125 12.5624 8.5875C12.2624 9.1875 12.4124 9.4875 12.2624 9.9375H12.2249L12.1124 6.8625C12.1124 6.8625 12.1124 6.75 12.0374 6.75C11.9624 6.75 11.9624 6.8625 11.9624 6.8625L11.8499 9.9375H11.8124C11.7374 9.45 11.4374 9.075 11.4749 8.55C11.5499 7.9125 11.1749 7.5375 11.0999 7.3125C11.0249 7.0875 11.1749 6.9 11.0999 6.9C11.0249 6.8625 10.8749 7.05 10.9124 7.425C10.9499 7.7625 11.2499 7.875 11.1749 8.6625C11.1374 9.3375 11.3999 9.5625 11.3999 10.05H11.3624L10.0874 7.275C10.0874 7.275 10.0499 7.2 9.9749 7.2C9.8999 7.2375 9.9374 7.3125 9.9374 7.3125L10.9874 10.2H10.9499C10.6874 9.7875 10.2749 9.5625 10.1249 9.0375C9.9374 8.4375 9.4874 8.2125 9.2999 8.025C9.1124 7.8375 9.2249 7.6125 9.1499 7.6125C9.0749 7.6125 8.9999 7.8375 9.1874 8.1375C9.3749 8.4375 9.6749 8.4375 9.8999 9.1875C10.0874 9.825 10.4249 9.9375 10.6499 10.3875L10.6124 10.425L8.3624 8.325C8.3624 8.325 8.2874 8.25 8.2499 8.2875C8.2124 8.325 8.2874 8.4 8.2874 8.4L10.3874 10.65L10.3499 10.6875C9.9374 10.3875 9.4874 10.35 9.1499 9.9375C8.7374 9.45 8.2499 9.45 8.0249 9.3375C7.7999 9.225 7.7999 9 7.7249 9.0375C7.6499 9.075 7.6874 9.3 7.9499 9.525C8.2499 9.75 8.5124 9.6375 8.9999 10.2C9.4124 10.6875 9.7874 10.6875 10.1249 10.9875C10.1249 10.9875 10.1249 11.025 10.0874 11.025L7.1999 9.975C7.1999 9.975 7.1249 9.9375 7.0874 10.0125C7.0499 10.0875 7.1624 10.125 7.1624 10.125L9.9374 11.4V11.4375C9.4499 11.325 8.9999 11.4375 8.5499 11.2125C7.9874 10.9125 7.4999 11.1 7.2749 11.1C7.0124 11.0625 6.9374 10.875 6.8999 10.9125C6.8249 10.95 6.9749 11.175 7.3124 11.2875C7.6499 11.3625 7.8749 11.175 8.5499 11.5125C9.1499 11.8125 9.4499 11.6625 9.8999 11.8125V11.85L6.8249 11.9625C6.8249 11.9625 6.7124 11.9625 6.7124 12.0375C6.7124 12.1125 6.8249 12.1125 6.8249 12.1125L9.8999 12.225V12.2625C9.4124 12.3375 9.0374 12.6375 8.5124 12.6C7.8749 12.525 7.4999 12.9 7.2749 12.975C7.0124 13.05 6.8624 12.9 6.8624 12.975C6.8249 13.05 7.0124 13.2 7.3874 13.1625C7.7624 13.125 7.8374 12.8625 8.6249 12.9C9.2999 12.9375 9.5249 12.675 10.0124 12.675V12.7125L7.2374 13.9875C7.2374 13.9875 7.1624 14.025 7.1624 14.1C7.1624 14.175 7.2749 14.1375 7.2749 14.1375L10.1624 13.0875V13.125C9.7499 13.3875 9.5249 13.8 8.9999 13.95C8.3999 14.1375 8.1749 14.5875 7.9874 14.775C7.7999 14.9625 7.5749 14.85 7.5749 14.925C7.5749 15 7.7999 15.075 8.0999 14.8875C8.3999 14.7 8.3999 14.4 9.1499 14.175C9.7874 13.9875 9.8999 13.65 10.3499 13.425L10.3874 13.4625L8.2874 15.7125C8.2874 15.7125 8.2124 15.7875 8.2499 15.825C8.2874 15.8625 8.3624 15.7875 8.3624 15.7875L10.6124 13.6875L10.6499 13.725C10.3499 14.1375 10.3124 14.5875 9.8999 14.925C9.4124 15.3375 9.4124 15.825 9.2999 16.05C9.1874 16.275 8.9624 16.275 8.9999 16.35C9.0374 16.425 9.2624 16.3875 9.4874 16.125C9.7124 15.8625 9.5999 15.5625 10.1624 15.075C10.6499 14.6625 10.6499 14.2875 10.9499 13.95C10.9499 13.95 10.9874 13.95 10.9874 13.9875L9.9374 16.875C9.9374 16.875 9.8999 16.95 9.9749 16.9875C10.0499 17.025 10.0874 16.9125 10.0874 16.9125L11.3624 14.1375H11.3999C11.2874 14.625 11.3999 15.075 11.1749 15.525C10.8749 16.0875 11.0624 16.575 11.0249 16.8C10.9874 17.0625 10.7999 17.1375 10.8374 17.175C10.8749 17.25 11.0999 17.1 11.2124 16.7625C11.2874 16.425 11.0999 16.2375 11.4374 15.525C11.7374 14.925 11.5874 14.625 11.7374 14.175H11.7749L11.8874 17.25C11.8874 17.25 11.8874 17.3625 11.9624 17.3625C12.0374 17.3625 12.0374 17.25 12.0374 17.25L12.1499 14.175H12.1874C12.2624 14.6625 12.5624 15.0375 12.5249 15.5625C12.4499 16.2 12.8249 16.575 12.8999 16.8C12.9749 17.0625 12.8249 17.2125 12.8999 17.2125C12.9749 17.25 13.1249 17.0625 13.0874 16.6875C13.0499 16.35 12.7499 16.2375 12.8249 15.45C12.8624 14.775 12.5999 14.55 12.5999 14.0625H12.6374L13.9124 16.8375C13.9124 16.8375 13.9499 16.9125 14.0249 16.9125C14.0999 16.875 14.0624 16.8 14.0624 16.8L12.9749 13.875H13.0124C13.2749 14.2875 13.6874 14.5125 13.8374 15.0375C14.0249 15.6375 14.4749 15.8625 14.6624 16.05C14.8499 16.2375 14.7374 16.4625 14.8124 16.4625C14.8874 16.4625 14.9624 16.2375 14.7749 15.9375C14.5874 15.6375 14.2874 15.6375 14.0624 14.8875C13.8749 14.25 13.5374 14.1375 13.3124 13.6875L13.3499 13.65L15.5999 15.75C15.5999 15.75 15.6749 15.825 15.7124 15.7875C15.7499 15.75 15.6749 15.675 15.6749 15.675L13.5749 13.425L13.6124 13.3875C14.0249 13.6875 14.4749 13.725 14.8124 14.1375C15.2249 14.625 15.7124 14.625 15.9374 14.7375C16.1624 14.85 16.1624 15.075 16.2374 15.0375C16.3124 15 16.2749 14.775 16.0124 14.55C15.7124 14.325 15.4499 14.4375 14.9624 13.875C14.5499 13.3875 14.1749 13.3875 13.8374 13.05C13.8374 13.05 13.8374 13.0125 13.8749 13.0125L16.7624 14.0625C16.7624 14.0625 16.8374 14.1 16.8749 14.025C16.9124 13.95 16.7999 13.9125 16.7999 13.9125L14.0249 12.6375V12.6C14.5124 12.7125 14.9624 12.6 15.4124 12.825C15.9749 13.125 16.4624 12.9375 16.6874 12.9375C16.9499 12.975 17.0249 13.1625 17.0624 13.125C17.1374 13.0875 16.9874 12.8625 16.6499 12.75C16.3124 12.675 16.0874 12.8625 15.4124 12.525C14.8124 12.225 14.5124 12.375 14.0624 12.225V12.1875L17.1374 12.075C17.1374 12.075 17.2499 12.075 17.2499 12C17.2499 11.925 17.1374 11.925 17.1374 11.925Z\" fill=\"#F6B40E\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryARGIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryBOLIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 0.75C7.08745 0.75 2.92495 3.9 1.38745 8.25H22.6124C21.0749 3.9 16.9124 0.75 12 0.75Z\" fill=\"#C94747\"/>\n <path d=\"M12 23.25C16.9124 23.25 21.0749 20.1375 22.6124 15.75H1.38745C2.92495 20.1375 7.08745 23.25 12 23.25Z\" fill=\"#83BF4F\"/>\n <path d=\"M1.3875 8.25C0.975 9.4125 0.75 10.6875 0.75 12C0.75 13.3125 0.975 14.5875 1.3875 15.75H22.6125C23.025 14.5875 23.25 13.3125 23.25 12C23.25 10.6875 23.025 9.4125 22.6125 8.25H1.3875Z\" fill=\"#FFCE31\"/>\n <path d=\"M11.7375 14.1377H12.2626V15.2252H11.7375V14.1377Z\" fill=\"#ED1C24\"/>\n <path d=\"M11.325 14.25H11.85V15.3375H11.325V14.25Z\" fill=\"#FFE000\"/>\n <path d=\"M12.1499 14.25H12.6749V15.3375H12.1499V14.25Z\" fill=\"#FFE000\"/>\n <path d=\"M11.25 14.25H11.5875V15.6375H11.25V14.25Z\" fill=\"#699635\"/>\n <path d=\"M12.4126 14.25H12.7501V15.6375H12.4126V14.25Z\" fill=\"#699635\"/>\n <path d=\"M11.1001 8.7749C11.1001 8.7749 10.9876 8.7374 10.8751 8.7374C10.9501 8.6249 10.9876 8.3999 10.9876 8.3999C10.9876 8.3999 10.8001 8.5124 10.7251 8.6249C10.6876 8.5499 10.6126 8.4374 10.6126 8.4374C10.6126 8.4374 10.5376 8.5499 10.5376 8.6249C10.5376 8.7374 10.6876 8.8874 10.6876 8.8874C10.6876 8.8874 10.8751 8.9249 10.9876 8.9249C11.0251 8.8874 11.1001 8.7749 11.1001 8.7749Z\" fill=\"#699635\"/>\n <path d=\"M10.9125 9.0377C10.9125 9.0377 10.8 9.0377 10.6875 9.0752C10.725 8.9252 10.6875 8.7002 10.6875 8.7002C10.6875 8.7002 10.5375 8.8877 10.5 9.0002L10.35 8.8502C10.35 8.8502 10.275 8.9627 10.3125 9.0752C10.35 9.1502 10.5 9.2627 10.5 9.2627C10.5 9.2627 10.6875 9.2627 10.8 9.2252C10.9125 9.1877 10.9125 9.0377 10.9125 9.0377Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.8374 9.37481L10.6124 9.44981C10.6124 9.29981 10.5374 9.1123 10.5374 9.1123C10.5374 9.1123 10.4249 9.29981 10.4249 9.44981C10.3499 9.41231 10.2374 9.37481 10.2374 9.37481C10.2374 9.37481 10.1999 9.52481 10.2749 9.59981C10.3499 9.67481 10.5374 9.74981 10.5374 9.74981C10.5374 9.74981 10.7249 9.71231 10.7999 9.63731C10.8374 9.52481 10.8374 9.37481 10.8374 9.37481Z\" fill=\"#699635\"/>\n <path d=\"M10.7999 9.7125C10.7999 9.7125 10.6875 9.7875 10.6125 9.8625C10.575 9.7125 10.425 9.5625 10.425 9.5625C10.425 9.5625 10.3875 9.7875 10.3875 9.9C10.3125 9.8625 10.2 9.8625 10.2 9.8625C10.2 9.8625 10.2 10.0125 10.275 10.05C10.35 10.125 10.5375 10.125 10.5375 10.125C10.5375 10.125 10.725 10.05 10.7625 9.9375C10.875 9.825 10.7999 9.7125 10.7999 9.7125Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.875 10.0501C10.875 10.0501 10.8 10.1251 10.725 10.2376C10.65 10.1251 10.4625 9.9751 10.4625 9.9751C10.4625 9.9751 10.4625 10.2001 10.5375 10.3126H10.3125C10.3125 10.3126 10.35 10.4251 10.4625 10.4626C10.575 10.5001 10.7625 10.4626 10.7625 10.4626C10.7625 10.4626 10.9125 10.3126 10.9125 10.2376C10.95 10.1626 10.875 10.0501 10.875 10.0501Z\" fill=\"#699635\"/>\n <path d=\"M11.0624 10.3125C11.0624 10.3125 10.9874 10.425 10.9874 10.5C10.8749 10.3875 10.6874 10.3125 10.6874 10.3125C10.6874 10.3125 10.7624 10.5375 10.8374 10.65C10.7624 10.65 10.6499 10.725 10.6499 10.725C10.6499 10.725 10.7249 10.8375 10.8374 10.8375C10.9499 10.8375 11.0999 10.7625 11.0999 10.7625C11.0999 10.7625 11.2124 10.6125 11.2124 10.5C11.1374 10.425 11.0624 10.3125 11.0624 10.3125Z\" fill=\"#83BF4F\"/>\n <path d=\"M11.2876 10.5752C11.2876 10.5752 11.2501 10.6877 11.2501 10.8002C11.1376 10.7252 10.9126 10.6877 10.9126 10.6877C10.9126 10.6877 11.0251 10.8752 11.1376 10.9502C11.0626 10.9877 10.9501 11.0627 10.9501 11.0627C10.9501 11.0627 11.0626 11.1377 11.1376 11.1377C11.2501 11.1377 11.4001 10.9877 11.4001 10.9877C11.4001 10.9877 11.4376 10.8002 11.4376 10.6877C11.4001 10.6502 11.2876 10.5752 11.2876 10.5752Z\" fill=\"#699635\"/>\n <path d=\"M11.5499 10.7627C11.5499 10.7627 11.5499 10.8752 11.5874 10.9877C11.4374 10.9502 11.2124 10.9877 11.2124 10.9877C11.2124 10.9877 11.3624 11.1377 11.5124 11.1752L11.3624 11.3252C11.3624 11.3252 11.4749 11.4002 11.5874 11.3627C11.6624 11.3252 11.7749 11.1752 11.7749 11.1752C11.7749 11.1752 11.7749 10.9877 11.7374 10.9127C11.6999 10.7627 11.5499 10.7627 11.5499 10.7627Z\" fill=\"#83BF4F\"/>\n <path d=\"M12.8999 8.7749C12.8999 8.7749 13.0124 8.7374 13.1249 8.7374C13.0499 8.6249 13.0124 8.3999 13.0124 8.3999C13.0124 8.3999 13.1999 8.5124 13.2749 8.6249C13.3124 8.5499 13.3874 8.4374 13.3874 8.4374C13.3874 8.4374 13.4624 8.5499 13.4624 8.6249C13.4624 8.7374 13.3124 8.8874 13.3124 8.8874C13.3124 8.8874 13.1249 8.9249 13.0124 8.9249C12.9749 8.8874 12.8999 8.7749 12.8999 8.7749Z\" fill=\"#699635\"/>\n <path d=\"M13.0874 9.0377C13.0874 9.0377 13.1999 9.0377 13.3124 9.0752C13.2749 8.9252 13.3124 8.7002 13.3124 8.7002C13.3124 8.7002 13.4624 8.8502 13.4999 9.0002L13.6499 8.8502C13.6499 8.8502 13.7249 8.9627 13.6874 9.0752C13.6499 9.1502 13.4999 9.2627 13.4999 9.2627C13.4999 9.2627 13.3124 9.2627 13.1999 9.2252C13.0874 9.1877 13.0874 9.0377 13.0874 9.0377Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.1626 9.37481L13.3876 9.44981C13.3876 9.29981 13.4626 9.1123 13.4626 9.1123C13.4626 9.1123 13.5751 9.29981 13.5751 9.44981C13.6501 9.41231 13.7626 9.37481 13.7626 9.37481C13.7626 9.37481 13.8001 9.52481 13.7251 9.59981C13.6501 9.67481 13.4626 9.74981 13.4626 9.74981C13.4626 9.74981 13.2751 9.71231 13.2001 9.63731C13.1626 9.52481 13.1626 9.37481 13.1626 9.37481Z\" fill=\"#699635\"/>\n <path d=\"M13.2 9.7125C13.2 9.7125 13.3125 9.7875 13.3875 9.8625C13.425 9.7125 13.575 9.5625 13.575 9.5625C13.575 9.5625 13.6125 9.7875 13.6125 9.9C13.6875 9.8625 13.8 9.8625 13.8 9.8625C13.8 9.8625 13.8 10.0125 13.725 10.05C13.65 10.125 13.4625 10.125 13.4625 10.125C13.4625 10.125 13.275 10.05 13.2375 9.9375C13.125 9.825 13.2 9.7125 13.2 9.7125Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.1249 10.0501C13.1249 10.0501 13.1999 10.1251 13.2749 10.2376C13.3499 10.1251 13.5374 9.9751 13.5374 9.9751C13.5374 9.9751 13.5374 10.2001 13.4624 10.3126H13.6874C13.6874 10.3126 13.6499 10.4251 13.5374 10.4626C13.4624 10.5001 13.2374 10.4626 13.2374 10.4626C13.2374 10.4626 13.0874 10.3126 13.0874 10.2376C13.0874 10.1626 13.1249 10.0501 13.1249 10.0501Z\" fill=\"#699635\"/>\n <path d=\"M12.9376 10.3125C12.9376 10.3125 13.0126 10.425 13.0126 10.5C13.1251 10.3875 13.3126 10.3125 13.3126 10.3125C13.3126 10.3125 13.2376 10.5375 13.1626 10.65C13.2376 10.65 13.3501 10.725 13.3501 10.725C13.3501 10.725 13.2751 10.8375 13.1626 10.8375C13.0501 10.8375 12.9001 10.7625 12.9001 10.7625C12.9001 10.7625 12.7876 10.6125 12.7876 10.5C12.7876 10.3875 12.9376 10.3125 12.9376 10.3125Z\" fill=\"#83BF4F\"/>\n <path d=\"M12.7125 10.5752C12.7125 10.5752 12.75 10.6877 12.75 10.8002C12.8625 10.7252 13.0875 10.6877 13.0875 10.6877C13.0875 10.6877 12.975 10.8752 12.8625 10.9502C12.9375 10.9877 13.05 11.0627 13.05 11.0627C13.05 11.0627 12.9375 11.1377 12.8625 11.1377C12.75 11.1377 12.6 10.9877 12.6 10.9877C12.6 10.9877 12.5625 10.8002 12.5625 10.6877C12.6 10.6502 12.7125 10.5752 12.7125 10.5752Z\" fill=\"#699635\"/>\n <path d=\"M12.4501 10.7627C12.4501 10.7627 12.4501 10.8752 12.4126 10.9877C12.5626 10.9502 12.7876 10.9877 12.7876 10.9877C12.7876 10.9877 12.6376 11.1377 12.4876 11.1752L12.6376 11.3252C12.6376 11.3252 12.5251 11.4002 12.4126 11.3627C12.3376 11.3252 12.2251 11.1752 12.2251 11.1752C12.2251 11.1752 12.2251 10.9877 12.2626 10.9127C12.3001 10.7627 12.4501 10.7627 12.4501 10.7627Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.2375 9.6001C12.8624 9.6001 12.4125 10.0501 12 10.0501C11.5875 10.0501 11.1375 9.6001 10.7625 9.6001C10.3875 9.6001 8.88745 10.0501 8.88745 10.0501C10.95 10.0501 12 11.1751 12 11.1751C12 11.1751 13.05 10.0501 15.1124 10.0501C15.1124 10.0501 13.6124 9.6001 13.2375 9.6001Z\" fill=\"#594640\"/>\n <path d=\"M12 10.1251C12.145 10.1251 12.2626 10.0076 12.2626 9.8626C12.2626 9.71762 12.145 9.6001 12 9.6001C11.8551 9.6001 11.7375 9.71762 11.7375 9.8626C11.7375 10.0076 11.8551 10.1251 12 10.1251Z\" fill=\"white\"/>\n <path d=\"M10.2 12.075L10.425 12.2625L10.5375 12.0375L10.575 11.925V11.175L10.65 11.2125C10.575 11.1375 10.5 11.0625 10.3875 10.9875L10.2375 10.875C10.2 10.9125 10.2 11.6625 10.2 12.075Z\" fill=\"#FFE000\"/>\n <path d=\"M10.575 11.9248L10.8 11.3623L10.575 11.1748C10.5375 11.1748 10.5375 11.5498 10.575 11.9248Z\" fill=\"#699635\"/>\n <path d=\"M10.2 10.9125L10.35 11.025C10.0875 10.8 9.75 10.5375 9.6 10.3875C9.5625 10.35 9.5625 10.9125 9.5625 11.55L10.2 12.075V10.9125Z\" fill=\"#D52B1E\"/>\n <path d=\"M13.8001 12.075L13.5751 12.2625L13.4626 12.0375L13.4251 11.925V11.175L13.3501 11.2125C13.4251 11.1375 13.5001 11.0625 13.6126 10.9875L13.7626 10.875C13.8001 10.9125 13.8001 11.6625 13.8001 12.075Z\" fill=\"#FFE000\"/>\n <path d=\"M13.425 11.9248L13.2 11.3623L13.425 11.1748C13.4625 11.1748 13.4625 11.5498 13.425 11.9248Z\" fill=\"#699635\"/>\n <path d=\"M13.7999 10.9125L13.6499 11.025C13.9124 10.8 14.2499 10.5375 14.3999 10.3875C14.4374 10.35 14.4374 10.9125 14.4374 11.55L13.7999 12.075V10.9125Z\" fill=\"#D52B1E\"/>\n <path d=\"M10.425 14.2499C9.93752 13.9874 9.82502 13.1999 9.86252 13.0874V11.6999L10.0125 11.8124C9.75002 11.5874 9.41252 11.3249 9.26252 11.1749C9.22502 11.1374 9.26252 12.8624 9.26252 13.6124C9.26252 13.9874 9.52502 15.2249 11.1 14.5874C11.1 14.5874 11.8875 14.3624 12.1125 14.0624H11.9625L11.8875 14.0999C10.95 14.6249 10.425 14.2499 10.425 14.2499Z\" fill=\"#D52B1E\"/>\n <path d=\"M9.82495 13.0875C9.82495 13.2 9.89995 13.9875 10.3875 14.25C10.3875 14.25 10.9125 14.625 11.85 14.1C11.5875 14.2125 11.3625 14.2125 11.2125 14.175C10.7625 14.0625 10.3125 13.65 10.2375 13.2C10.1625 12.7875 10.2 11.925 10.2 11.925L10.275 11.9625C10.2 11.8875 10.125 11.8125 10.0125 11.7375L9.86245 11.625C9.86245 11.7 9.86245 12.975 9.82495 13.0875Z\" fill=\"#FFE000\"/>\n <path d=\"M10.4626 12.5248V12.1873C10.3501 12.1123 10.5001 12.2248 10.2376 11.9998L10.1626 11.9248V11.9998C10.1626 12.1123 10.1626 12.8623 10.2001 13.2373C10.2751 13.6498 10.7251 14.0998 11.1751 14.2123C11.3251 14.2498 11.5501 14.2123 11.8501 14.1373L11.8876 14.0998C11.1376 13.9873 10.5751 13.3873 10.4626 12.5248Z\" fill=\"#699635\"/>\n <path d=\"M13.575 14.2875C14.0625 14.025 14.175 13.2375 14.1375 13.125V11.7375L13.9875 11.85C14.25 11.625 14.5875 11.3625 14.7375 11.2125C14.775 11.175 14.7375 12.9 14.7375 13.65C14.7375 14.025 14.475 15.2625 12.9 14.625C12.9 14.625 12.1125 14.4 11.8875 14.1H12.0375L12.1125 14.1375C13.05 14.6625 13.575 14.2875 13.575 14.2875Z\" fill=\"#D52B1E\"/>\n <path d=\"M14.1749 13.1251C14.1749 13.2376 14.0999 14.0251 13.6124 14.2876C13.6124 14.2876 13.0874 14.6626 12.1499 14.1376C12.4124 14.2501 12.6374 14.2501 12.7874 14.2126C13.2374 14.1001 13.6874 13.6876 13.7624 13.2376C13.8374 12.8251 13.7999 11.9626 13.7999 11.9626L13.7249 12.0001C13.7999 11.9251 13.8749 11.8501 13.9874 11.7751L14.1374 11.6626C14.1374 11.7376 14.1374 13.0126 14.1749 13.1251Z\" fill=\"#FFE000\"/>\n <path d=\"M13.5375 12.5624V12.2249C13.65 12.1499 13.5 12.2624 13.7625 12.0374L13.8376 11.9624V11.9999C13.8376 12.1124 13.8375 12.8624 13.8 13.2374C13.725 13.6499 13.275 14.0999 12.825 14.2124C12.675 14.2499 12.45 14.2124 12.15 14.1374L12.1125 14.0999C12.8625 14.0249 13.425 13.4249 13.5375 12.5624Z\" fill=\"#699635\"/>\n <path d=\"M12 14.3249C12.8699 14.3249 13.5751 13.5022 13.5751 12.4874C13.5751 11.4726 12.8699 10.6499 12 10.6499C11.1302 10.6499 10.425 11.4726 10.425 12.4874C10.425 13.5022 11.1302 14.3249 12 14.3249Z\" fill=\"#00A6DE\"/>\n <path d=\"M13.3126 12.5248C13.3126 13.3873 10.7251 13.3873 10.7251 12.5248C10.7251 11.6623 11.2876 10.9873 12.0376 10.9873C12.7876 10.9873 13.3126 11.6998 13.3126 12.5248Z\" fill=\"#E8A30E\"/>\n <path d=\"M11.9625 12.3752C12.3145 12.3752 12.5999 12.1401 12.5999 11.8502C12.5999 11.5602 12.3145 11.3252 11.9625 11.3252C11.6104 11.3252 11.325 11.5602 11.325 11.8502C11.325 12.1401 11.6104 12.3752 11.9625 12.3752Z\" fill=\"#D52B1E\"/>\n <path d=\"M11.925 11.7373C11.55 11.7373 10.6875 12.5623 10.6875 12.5623C10.6875 13.3498 11.25 13.9873 12 13.9873C12.75 13.9873 13.3125 13.3498 13.3125 12.5623C13.3125 12.5623 12.3375 11.7373 11.925 11.7373Z\" fill=\"#699635\"/>\n <path d=\"M12.1125 13.125H12.4501V13.65H12.1125V13.125Z\" fill=\"#E8A30E\"/>\n <path d=\"M12.6001 12.5249H12.7876V13.5749H12.6001V12.5249Z\" fill=\"white\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryBOLIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryBRAIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M23.0625 10.05C22.1625 4.7625 17.55 0.75 12 0.75C6.45 0.75 1.8375 4.7625 0.9375 10.05L12 4.5L23.0625 10.05Z\" fill=\"#16A260\"/>\n <path d=\"M0.9375 13.9502C1.8375 19.2377 6.45 23.2502 12 23.2502C17.55 23.2502 22.1625 19.2377 23.0625 13.9502L12 19.5002L0.9375 13.9502Z\" fill=\"#16A260\"/>\n <path d=\"M12 4.5L0.9375 10.05C0.825 10.6875 0.75 11.325 0.75 12C0.75 12.675 0.825 13.3125 0.9375 13.95L12 19.5L23.0625 13.95C23.175 13.3125 23.25 12.675 23.25 12C23.25 11.325 23.175 10.6875 23.0625 10.05L12 4.5Z\" fill=\"#FFE62E\"/>\n <path d=\"M9.75 10.6499C8.55 10.6499 7.425 10.9124 6.4125 11.3624C6.375 11.5874 6.375 11.7749 6.375 11.9999C6.375 15.1124 8.8875 17.6249 12 17.6249C14.1 17.6249 15.9375 16.4624 16.9125 14.7749C15.525 12.3374 12.825 10.6499 9.75 10.6499Z\" fill=\"#0D5FDB\"/>\n <path d=\"M17.55 12.9C17.5875 12.6 17.625 12.3 17.625 12C17.625 8.8875 15.1125 6.375 12 6.375C9.7875 6.375 7.875 7.65 6.9375 9.525C7.8375 9.2625 8.775 9.1125 9.75 9.1125C12.9375 9.1125 15.75 10.6125 17.55 12.9Z\" fill=\"#0D5FDB\"/>\n <path d=\"M9.7501 9.1123C8.7751 9.1123 7.8376 9.2623 6.9376 9.5248C6.6751 10.0873 6.4876 10.6873 6.4126 11.3623C7.4251 10.9123 8.5501 10.6498 9.7501 10.6498C12.8251 10.6498 15.5251 12.2998 16.9126 14.7373C17.2501 14.1748 17.4376 13.5373 17.5501 12.8998C15.7501 10.6123 12.9376 9.1123 9.7501 9.1123Z\" fill=\"white\"/>\n <path d=\"M8.25 12.375C8.45711 12.375 8.625 12.2071 8.625 12C8.625 11.7929 8.45711 11.625 8.25 11.625C8.04289 11.625 7.875 11.7929 7.875 12C7.875 12.2071 8.04289 12.375 8.25 12.375Z\" fill=\"white\"/>\n <path d=\"M9.75 14.625C9.95711 14.625 10.125 14.4571 10.125 14.25C10.125 14.0429 9.95711 13.875 9.75 13.875C9.54289 13.875 9.375 14.0429 9.375 14.25C9.375 14.4571 9.54289 14.625 9.75 14.625Z\" fill=\"white\"/>\n <path d=\"M12 14.625C12.2071 14.625 12.375 14.4571 12.375 14.25C12.375 14.0429 12.2071 13.875 12 13.875C11.7929 13.875 11.625 14.0429 11.625 14.25C11.625 14.4571 11.7929 14.625 12 14.625Z\" fill=\"white\"/>\n <path d=\"M12 16.125C12.2071 16.125 12.375 15.9571 12.375 15.75C12.375 15.5429 12.2071 15.375 12 15.375C11.7929 15.375 11.625 15.5429 11.625 15.75C11.625 15.9571 11.7929 16.125 12 16.125Z\" fill=\"white\"/>\n <path d=\"M15 14.625C15.2071 14.625 15.375 14.4571 15.375 14.25C15.375 14.0429 15.2071 13.875 15 13.875C14.7929 13.875 14.625 14.0429 14.625 14.25C14.625 14.4571 14.7929 14.625 15 14.625Z\" fill=\"white\"/>\n <path d=\"M15 16.125C15.2071 16.125 15.375 15.9571 15.375 15.75C15.375 15.5429 15.2071 15.375 15 15.375C14.7929 15.375 14.625 15.5429 14.625 15.75C14.625 15.9571 14.7929 16.125 15 16.125Z\" fill=\"white\"/>\n <path d=\"M13.5 15.375C13.7071 15.375 13.875 15.2071 13.875 15C13.875 14.7929 13.7071 14.625 13.5 14.625C13.2929 14.625 13.125 14.7929 13.125 15C13.125 15.2071 13.2929 15.375 13.5 15.375Z\" fill=\"white\"/>\n <path d=\"M8.25 13.875C8.45711 13.875 8.625 13.7071 8.625 13.5C8.625 13.2929 8.45711 13.125 8.25 13.125C8.04289 13.125 7.875 13.2929 7.875 13.5C7.875 13.7071 8.04289 13.875 8.25 13.875Z\" fill=\"white\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryBRAIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryCANIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M18 2.475C16.275 1.3875 14.2125 0.75 12 0.75C9.7875 0.75 7.725 1.3875 6 2.475V21.4875C7.725 22.575 9.7875 23.2125 12 23.2125C14.2125 23.2125 16.275 22.575 18 21.4875V2.475Z\" fill=\"#F9F9F9\"/>\n <path d=\"M18 2.4751V21.4876C21.15 19.5376 23.25 15.9376 23.25 11.9626C23.25 7.9876 21.15 4.4626 18 2.4751Z\" fill=\"#ED4C5C\"/>\n <path d=\"M6 2.4751C2.85 4.4626 0.75 8.0626 0.75 12.0001C0.75 15.9376 2.85 19.5376 6 21.5251V2.4751Z\" fill=\"#ED4C5C\"/>\n <path d=\"M16.0875 11.85C15.9375 11.775 15.9 11.625 15.9375 11.55L16.3125 10.2L15 10.4625C14.9625 10.4625 14.8125 10.4625 14.775 10.2L14.6625 9.75L13.7625 10.8C13.7625 10.8 13.1625 11.4375 13.35 10.4625L13.725 8.4L13.0125 8.775C12.975 8.775 12.825 8.8125 12.6375 8.4375L12 7.125L11.325 8.3625C11.1375 8.7375 10.9875 8.7 10.95 8.7L10.2375 8.325L10.6125 10.3875C10.8 11.3625 10.2 10.725 10.2 10.725L9.3 9.675L9.1875 10.125C9.1125 10.3875 9 10.3875 8.9625 10.3875L7.65 10.125L8.025 11.475C8.025 11.5875 8.025 11.7 7.875 11.775L7.5 12C7.5 12 9 13.2 9.4875 13.6125C9.6 13.6875 9.825 13.9125 9.75 14.175L9.5625 14.7L11.625 14.4C11.7375 14.4 11.9625 14.4 11.925 14.7375L11.8125 16.875H12.1875L12.075 14.7375C12.075 14.4 12.3 14.4 12.375 14.4L14.4375 14.7L14.25 14.175C14.175 13.9125 14.4 13.6875 14.5125 13.6125C15 13.2 16.5 12 16.5 12L16.0875 11.85Z\" fill=\"#ED4C5C\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryCANIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryCHLIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M0.75 12C0.75 18.225 5.775 23.25 12 23.25C18.225 23.25 23.25 18.225 23.25 12H0.75Z\" fill=\"#ED4C5C\"/>\n <path d=\"M12 0.75C18.225 0.75 23.25 5.775 23.25 12H12V0.75Z\" fill=\"#F9F9F9\"/>\n <path d=\"M12 0.75C5.775 0.75 0.75 5.775 0.75 12H12V0.75Z\" fill=\"#2A5F9E\"/>\n <path d=\"M7.5 8.1375L9.3375 9.375L8.6625 7.3875L10.5 6.075H8.2125L7.5 4.125L6.825 6.075H4.5L6.3375 7.3875L5.6625 9.375L7.5 8.1375Z\" fill=\"#F9F9F9\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryCHLIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryCOLIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props}>\n <path d=\"M23.25 12H0.75C0.75 14.0625 1.3125 15.975 2.25 17.625H21.75C22.725 15.975 23.25 14.0625 23.25 12Z\" fill=\"#2A5F9E\"/>\n <path d=\"M12 0.75C5.8125 0.75 0.75 5.775 0.75 12H23.25C23.25 5.775 18.225 0.75 12 0.75Z\" fill=\"#FFE62E\"/>\n <path d=\"M12 23.25C16.1625 23.25 19.8 21 21.75 17.625H2.25C4.2375 21 7.8375 23.25 12 23.25Z\" fill=\"#ED4C5C\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryCOLIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryCRIIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props}>\n <path d=\"M19.6501 3.75C17.6251 1.875 14.9626 0.75 12.0001 0.75C9.0376 0.75 6.3751 1.875 4.3501 3.75H19.6501Z\" fill=\"#2A5F9E\"/>\n <path d=\"M4.3501 20.25C6.3751 22.125 9.0376 23.25 12.0001 23.25C14.9626 23.25 17.6251 22.125 19.6501 20.25H4.3501Z\" fill=\"#2A5F9E\"/>\n <path d=\"M0.75 12C0.75 13.6125 1.0875 15.1125 1.6875 16.5H22.3125C22.9125 15.1125 23.25 13.6125 23.25 12C23.25 10.3875 22.9125 8.8875 22.3125 7.5H1.6875C1.0875 8.8875 0.75 10.3875 0.75 12Z\" fill=\"#C94747\"/>\n <path d=\"M4.3499 20.25H19.6124C20.7374 19.2 21.6749 17.925 22.2749 16.5H1.6499C2.3249 17.925 3.2249 19.2 4.3499 20.25Z\" fill=\"#F9F9F9\"/>\n <path d=\"M19.65 3.75H4.35C3.225 4.8 2.2875 6.075 1.6875 7.5H22.3125C21.675 6.075 20.775 4.8 19.65 3.75Z\" fill=\"#F9F9F9\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryCRIIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryECUIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M23.25 12H0.75C0.75 14.0625 1.3125 15.975 2.25 17.625H21.75C22.6875 15.975 23.25 14.0625 23.25 12Z\" fill=\"#2A5F9E\"/>\n <path d=\"M12 0.75C5.775 0.75 0.75 5.775 0.75 12H23.25C23.25 5.775 18.225 0.75 12 0.75Z\" fill=\"#FFE62E\"/>\n <path d=\"M12 23.25C16.1625 23.25 19.8 21 21.75 17.625H2.25C4.2 21 7.8375 23.25 12 23.25Z\" fill=\"#ED4C5C\"/>\n <path d=\"M9.51855 11.0822L9.8193 11.3897L9.9483 11.0383L9.99143 10.8186C9.9483 10.2036 9.99143 9.58858 9.99143 9.58858L10.0777 9.67671L9.73343 9.32533L9.51855 9.10596V11.0822Z\" fill=\"#034EA2\"/>\n <path d=\"M9.99146 10.8189L10.2922 9.89637L9.99146 9.58887V10.8189Z\" fill=\"#ED1C24\"/>\n <path d=\"M9.51857 9.10635L9.73344 9.32572L8.70182 8.27197C8.65869 8.22772 8.65869 9.1941 8.65869 10.2482L9.51857 11.1265V9.10635Z\" fill=\"#FFDD00\"/>\n <path d=\"M9.81937 14.8157C9.08887 14.3766 9.00262 13.0149 9.00262 12.7952V10.4237L9.21787 10.6434L8.18587 9.58932C8.1 9.50157 8.18587 12.4438 8.18587 13.7177C8.18587 14.3327 8.57287 16.4844 10.7224 15.3864C10.7224 15.3864 11.7971 14.9912 12.141 14.5082H11.9261C11.883 14.5521 11.8399 14.5521 11.7971 14.5521C10.5502 15.4303 9.81937 14.8157 9.81937 14.8157Z\" fill=\"#FFDD00\"/>\n <path d=\"M9.00269 12.7949C9.00269 12.9708 9.08894 14.3324 9.77669 14.7712C9.77669 14.7712 10.5076 15.3862 11.7972 14.5518C11.4102 14.7277 11.1094 14.7277 10.8942 14.6834C10.2923 14.5079 9.64769 13.8052 9.56181 13.0585C9.47556 12.3123 9.47556 10.9064 9.47556 10.9064L9.56181 10.9945L9.21794 10.6432L9.00269 10.4673V12.7949Z\" fill=\"#034EA2\"/>\n <path d=\"M9.90556 11.8731V11.302C9.77656 11.1707 9.9483 11.3462 9.60443 10.9945L9.51855 10.9067V10.951C9.51855 11.1265 9.51856 12.4 9.60481 13.0589C9.69068 13.8055 10.3353 14.5082 10.9372 14.6837C11.1521 14.728 11.4532 14.728 11.8398 14.5525C11.8829 14.5525 11.8829 14.5082 11.9261 14.5082C10.7651 14.3766 10.0346 13.3225 9.90556 11.8731Z\" fill=\"#ED1C24\"/>\n <path d=\"M14.2042 14.8594C14.8923 14.4202 15.0213 13.0586 14.9782 12.8831V10.5112L14.7633 10.731L15.795 9.67723C15.8812 9.5891 15.795 12.5317 15.795 13.8052C15.795 14.4202 15.408 16.572 13.2585 15.474C13.2585 15.474 12.1837 15.0791 11.8398 14.5957H12.0551C12.0978 14.5957 12.141 14.6396 12.141 14.6396C13.4737 15.4744 14.2042 14.8594 14.2042 14.8594Z\" fill=\"#FFDD00\"/>\n <path d=\"M14.9783 12.8392C14.9783 13.0147 14.8921 14.3763 14.2043 14.8154C14.2043 14.8154 13.4738 15.4304 12.1838 14.5957C12.5708 14.7715 12.872 14.7715 13.0868 14.7277C13.6887 14.5518 14.3333 13.849 14.4196 13.1024C14.5055 12.3562 14.5055 10.9507 14.5055 10.9507L14.4192 11.0384L14.7635 10.687L14.9783 10.4673V12.8392Z\" fill=\"#034EA2\"/>\n <path d=\"M14.1188 11.9167V11.3459L14.4195 11.0384L14.5054 10.9507V10.9946C14.5054 11.1701 14.5054 12.4436 14.4191 13.1024C14.3333 13.8491 13.7314 14.5518 13.0868 14.7712C12.8719 14.8154 12.5708 14.8154 12.1838 14.6399C12.141 14.6399 12.141 14.5957 12.0979 14.5957C13.2154 14.4202 13.9894 13.3661 14.1184 11.9167\" fill=\"#ED1C24\"/>\n <path d=\"M9.86255 11.6251C9.86255 13.1626 10.8375 14.4001 12 14.4001C13.1625 14.4001 14.1376 13.1626 14.1376 11.6251C14.1376 10.0876 13.1625 8.8501 12 8.8501C10.8375 8.8501 9.86255 10.1251 9.86255 11.6251Z\" fill=\"#8CDDEA\"/>\n <path d=\"M9.86255 11.7373C9.86255 13.2748 10.8375 14.5123 12 14.5123C13.2 14.5123 14.1376 13.2748 14.1376 11.7373H9.86255Z\" fill=\"#6DD337\"/>\n <path d=\"M9.9375 11.8127L13.9875 11.8877L14.025 11.5877C14.025 11.5502 14.1 11.5127 13.9875 11.5127C13.5375 11.4752 13.725 11.4377 13.4625 11.4377C13.3875 11.4377 11.6625 11.0252 11.5125 11.0252C11.3625 10.9877 10.0125 11.2127 10.0125 11.2127L9.9375 11.8127Z\" fill=\"#557176\"/>\n <path d=\"M9.8999 11.0998L10.5374 11.3623C10.5374 11.3623 11.3624 11.2123 11.4374 11.2498C11.5124 11.2873 12.2249 11.3998 12.2624 11.3998H13.3499H13.3124C13.2374 11.3623 12.4124 11.1373 12.3374 11.0998C12.2999 11.0623 11.6624 10.8373 11.6249 10.7623C11.5499 10.6873 11.0999 10.4248 11.0249 10.4248C10.9499 10.3873 9.8999 11.0998 9.8999 11.0998Z\" fill=\"white\"/>\n <path d=\"M12.9 8.9251C12.9 8.9251 12.4875 8.6626 11.9625 8.6626C11.55 8.6626 11.1375 8.8876 11.1375 8.8876C10.6875 9.1501 10.3125 9.6376 10.0875 10.2376C9.93745 10.6501 9.82495 11.1376 9.82495 11.6251C9.82495 13.0876 10.6125 14.2126 11.625 14.5126C11.625 14.5126 11.775 14.5876 11.9625 14.5876C12.15 14.5876 12.3375 14.5501 12.3375 14.5501C13.35 14.2876 14.1749 13.1251 14.1749 11.6626C14.1749 9.7501 12.7125 8.7751 12.9 8.9251ZM12.375 14.3626C12.375 14.3626 12.1875 14.4001 12 14.4001C11.8125 14.4001 11.625 14.3626 11.625 14.3626C10.725 14.1001 10.0125 13.0126 10.0125 11.7001C10.0125 11.2501 10.125 10.7626 10.275 10.3876C10.5 9.8626 10.8375 9.4126 11.25 9.1876C11.25 9.1876 11.6625 8.9251 12 8.9251C12.4875 8.9251 12.8624 9.1876 12.8624 9.1876C13.5374 9.6001 14.025 10.5751 14.025 11.6626C13.9875 13.0126 13.275 14.1376 12.375 14.3626Z\" fill=\"#B1BABF\"/>\n <path d=\"M10.725 11.7L11.3625 12.5625L10.3875 13.125C10.3875 13.125 10.4625 13.35 10.65 13.6125C10.8375 13.8375 11.2875 14.325 11.7 14.3625C12.15 14.4 12.45 14.4 12.7125 14.25C12.9375 14.1 13.275 13.9125 13.5 13.5375C13.725 13.2 13.7249 13.125 13.7249 13.125C13.7249 13.125 12.3 12.825 12.2625 12.825C12.225 12.7875 10.875 11.7375 10.8375 11.7C10.8 11.6625 11.1375 11.25 11.1375 11.25L10.725 11.7Z\" fill=\"#034EA2\"/>\n <path d=\"M11.6626 14.9248H12.3751V16.7623H11.6626V14.9248Z\" fill=\"#ED1C24\"/>\n <path d=\"M11.1001 15.0752H11.8126V16.9127H11.1001V15.0752Z\" fill=\"#034EA2\"/>\n <path d=\"M12.1875 15.0752H12.9V16.9127H12.1875V15.0752Z\" fill=\"#034EA2\"/>\n <path d=\"M10.95 15.0752H11.4V17.4002H10.95V15.0752Z\" fill=\"#FFDD00\"/>\n <path d=\"M12.5999 15.0752H13.0499V17.4002H12.5999V15.0752Z\" fill=\"#FFDD00\"/>\n <path d=\"M10.3125 14.2876H13.6875V15.1876H10.3125V14.2876Z\" fill=\"white\"/>\n <path d=\"M14.1 6.9375C13.425 6.9375 12.7125 7.6875 12 7.6875C11.2875 7.6875 10.575 6.9375 9.9 6.9375C9.2625 6.9375 6.75 7.6875 6.75 7.6875C10.2375 7.6875 12 9.5625 12 9.5625C12 9.5625 13.7625 7.6875 17.25 7.6875C17.25 7.6875 14.7375 6.9375 14.1 6.9375Z\" fill=\"#594640\"/>\n <path d=\"M12 7.8375C12.2486 7.8375 12.4501 7.63603 12.4501 7.3875C12.4501 7.13897 12.2486 6.9375 12 6.9375C11.7515 6.9375 11.55 7.13897 11.55 7.3875C11.55 7.63603 11.7515 7.8375 12 7.8375Z\" fill=\"#F9F9F9\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryECUIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryESPIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M0.75 12C0.75 14.2125 1.3875 16.275 2.475 18H21.4875C22.575 16.275 23.2125 14.2125 23.2125 12C23.2125 9.7875 22.575 7.725 21.4875 6H2.475C1.3875 7.725 0.75 9.7875 0.75 12Z\" fill=\"#FFCE31\"/>\n <path d=\"M21.5251 6C19.5376 2.85 16.0126 0.75 12.0001 0.75C7.9876 0.75 4.4626 2.85 2.4751 6H21.5251Z\" fill=\"#ED4C5C\"/>\n <path d=\"M2.4751 18C4.4626 21.15 7.9876 23.25 12.0001 23.25C16.0126 23.25 19.5376 21.15 21.5251 18H2.4751Z\" fill=\"#ED4C5C\"/>\n <path d=\"M3.44995 10.7627H4.64995V11.4377H3.44995V10.7627Z\" fill=\"#C8B100\"/>\n <path d=\"M3.44995 15.7129H4.68745V16.3504H3.44995V15.7129Z\" fill=\"#C8B100\"/>\n <path d=\"M3.3374 14.6626C3.2249 14.7376 3.1499 14.8126 3.1499 14.8501C3.1499 14.8876 3.1874 14.9251 3.2624 14.9626C3.3374 15.0001 3.4124 15.0751 3.3749 15.1501C3.4499 15.0751 3.4874 15.0001 3.4874 14.9251C3.4874 14.8126 3.4124 14.7001 3.3374 14.6626Z\" fill=\"#ED4C5C\"/>\n <path d=\"M3.63745 11.4375H4.49995V15.7125H3.63745V11.4375Z\" fill=\"white\"/>\n <path d=\"M5.39999 13.0125C5.21249 12.9375 4.87499 12.8625 4.49999 12.8625C4.38749 12.8625 4.23749 12.8625 4.08749 12.9C3.56249 12.975 3.14999 13.2 3.18749 13.35L2.99999 12.9375C2.96249 12.75 3.41249 12.525 3.97499 12.4125C4.16249 12.375 4.34999 12.375 4.49999 12.375C4.87499 12.375 5.21249 12.4125 5.39999 12.4875V13.0125Z\" fill=\"#ED4C5C\"/>\n <path d=\"M3.6376 13.575C3.4126 13.575 3.2251 13.5 3.2251 13.3875C3.2251 13.3125 3.3001 13.2 3.4501 13.125H3.6751L3.6376 13.575Z\" fill=\"#ED4C5C\"/>\n <path d=\"M4.5 13.2373C4.65 13.2748 4.7625 13.3123 4.8375 13.3498C4.875 13.3873 4.725 13.5373 4.5 13.6498V13.2373Z\" fill=\"#ED4C5C\"/>\n <path d=\"M3.07511 14.4001C3.03761 14.3251 3.30011 14.1751 3.63761 14.0626C3.78761 14.0251 3.90011 13.9501 4.08761 13.8751C4.53761 13.6876 4.91261 13.4251 4.83761 13.3501L4.91261 13.8001C4.95011 13.8751 4.65011 14.1001 4.20011 14.3251C4.05011 14.4001 3.78761 14.5126 3.63761 14.5501C3.37511 14.6251 3.15011 14.7751 3.15011 14.8126L3.07511 14.4001Z\" fill=\"#ED4C5C\"/>\n <path d=\"M11.5127 10.7627H12.7127V11.4377H11.5127V10.7627Z\" fill=\"#C8B100\"/>\n <path d=\"M11.4751 15.7129H12.7126V16.3504H11.4751V15.7129Z\" fill=\"#C8B100\"/>\n <path d=\"M12.825 14.6626C12.9376 14.7376 13.0126 14.8126 13.0126 14.8501C13.0126 14.8876 12.9751 14.9251 12.9001 14.9626C12.8251 15.0376 12.75 15.1501 12.7875 15.1876C12.7125 15.1126 12.675 15.0376 12.675 14.9626C12.675 14.8126 12.75 14.7001 12.825 14.6626Z\" fill=\"#ED4C5C\"/>\n <path d=\"M11.6626 11.4375H12.5251V15.7125H11.6626V11.4375Z\" fill=\"white\"/>\n <path d=\"M10.7625 13.0125C10.95 12.9375 11.2875 12.8625 11.6625 12.8625C11.775 12.8625 11.925 12.8625 12.075 12.9C12.6 12.975 13.0124 13.2 12.9749 13.35L13.1624 12.9C13.1999 12.7125 12.75 12.4875 12.1875 12.375H11.6625C11.2875 12.375 10.95 12.4125 10.7625 12.4875V13.0125Z\" fill=\"#ED4C5C\"/>\n <path d=\"M12.525 13.575C12.75 13.575 12.9375 13.5 12.9375 13.3875C12.9375 13.3125 12.8625 13.2 12.7125 13.125H12.4875L12.525 13.575Z\" fill=\"#ED4C5C\"/>\n <path d=\"M11.6626 13.2373C11.5126 13.2748 11.4001 13.3123 11.3251 13.3498C11.2876 13.3873 11.4376 13.5373 11.6626 13.6498V13.2373Z\" fill=\"#ED4C5C\"/>\n <path d=\"M13.0875 14.3996C13.125 14.3246 12.8625 14.1746 12.525 14.0621C12.375 14.0246 12.2625 13.9496 12.075 13.8746C11.625 13.6871 11.25 13.4246 11.325 13.3496L11.25 13.7996C11.2125 13.8746 11.5125 14.0996 11.9625 14.3246C12.1125 14.3996 12.375 14.5121 12.525 14.5496C12.7875 14.6246 13.0125 14.8121 12.975 14.8496L13.0875 14.3996Z\" fill=\"#ED4C5C\"/>\n <path d=\"M8.06255 8.3623C8.77505 8.3623 10.2375 8.51231 10.7625 9.03731C10.2 10.3873 9.30005 9.82481 8.06255 9.82481C6.86255 9.82481 5.92505 10.3873 5.36255 9.03731C5.88755 8.51231 7.31255 8.3623 8.06255 8.3623Z\" fill=\"#ED4C5C\"/>\n <path d=\"M9.9001 9.8625C9.4501 9.6 8.7751 9.5625 8.0626 9.5625C7.3501 9.5625 6.6751 9.6375 6.2251 9.8625L6.3751 10.5C6.7876 10.6125 7.3876 10.6875 8.0626 10.6875C8.7376 10.6875 9.3001 10.6125 9.7501 10.5L9.9001 9.8625Z\" fill=\"#C8B100\"/>\n <path d=\"M10.5375 8.25C10.3875 8.1375 10.0875 8.025 9.82505 8.025C9.71255 8.025 9.60005 8.025 9.48755 8.0625C9.48755 8.0625 9.26255 7.7625 8.73755 7.7625C8.55005 7.7625 8.40005 7.8 8.25005 7.875V7.8375C8.21255 7.7625 8.13755 7.6875 8.06255 7.6875C7.98755 7.6875 7.87505 7.8 7.87505 7.875V7.9125C7.72505 7.8375 7.57505 7.8 7.38755 7.8C6.86255 7.8 6.63755 8.1375 6.63755 8.1C6.52505 8.0625 6.41255 8.0625 6.30005 8.0625C4.57505 8.0625 5.43755 9.225 5.43755 9.225L5.62505 9C5.21255 8.475 5.58755 8.175 6.33755 8.175C6.45005 8.175 6.52505 8.175 6.60005 8.2125C6.33755 8.5875 6.82505 8.925 6.82505 8.925L6.93755 8.7375C6.67505 8.55 6.63755 7.9125 7.38755 7.9125C7.57505 7.9125 7.72505 7.95 7.87505 8.0625C7.87505 8.1 7.83755 8.625 7.80005 8.7L8.10005 8.9625L8.40005 8.7C8.36255 8.5875 8.32505 8.1 8.32505 8.0625C8.43755 7.9875 8.62505 7.9125 8.81255 7.9125C9.60005 7.9125 9.60005 8.55 9.26255 8.7375L9.37505 8.925C9.37505 8.925 9.78755 8.5875 9.60005 8.2125C9.67505 8.2125 9.78755 8.175 9.86255 8.175C10.7625 8.175 10.8 8.85 10.575 9L10.725 9.225C10.65 9.225 11.0625 8.7 10.5375 8.25Z\" fill=\"#C8B100\"/>\n <path d=\"M7.8374 7.5375C7.8374 7.425 7.9499 7.3125 8.0624 7.3125C8.2124 7.3125 8.2874 7.425 8.2874 7.5375C8.2874 7.65 8.1749 7.7625 8.0624 7.7625C7.9499 7.7625 7.8374 7.65 7.8374 7.5375Z\" fill=\"#005BBF\"/>\n <path d=\"M7.9874 6.8999V7.0124H7.8749V7.1249H7.9874V7.4999H7.8374V7.6124H8.2874L8.3249 7.5374L8.2874 7.4999H8.1374V7.1249H8.2499V7.0124H8.1374V6.8999H7.9874Z\" fill=\"#C8B100\"/>\n <path d=\"M8.0624 10.6123C7.4624 10.6123 6.9374 10.5373 6.5249 10.4248C6.9374 10.3123 7.4624 10.2373 8.0624 10.2373C8.6624 10.2373 9.1874 10.3123 9.5999 10.4248C9.2249 10.5373 8.6624 10.6123 8.0624 10.6123Z\" fill=\"#ED4C5C\"/>\n <path d=\"M8.0999 17.1001C7.3874 17.1001 6.7124 16.9126 6.1124 16.6501C5.6624 16.4251 5.3999 16.0126 5.3999 15.5251V13.7251H10.7999V15.5251C10.7999 16.0126 10.4999 16.4626 10.0874 16.6501C9.4874 16.9501 8.8124 17.1001 8.0999 17.1001Z\" fill=\"white\"/>\n <path d=\"M8.0625 10.7251H10.7625V13.7251H8.0625V10.7251Z\" fill=\"white\"/>\n <path d=\"M8.0999 15.5251C8.0999 16.2376 7.4999 16.8001 6.7499 16.8001C5.9999 16.8001 5.3999 16.2376 5.3999 15.5251V13.7251H8.0999V15.5251Z\" fill=\"#ED4C5C\"/>\n <path d=\"M5.96265 16.5749C6.03765 16.6124 6.15015 16.6874 6.30015 16.7249V13.6499H6.00015L5.96265 16.5749Z\" fill=\"#C8B100\"/>\n <path d=\"M5.36255 15.4874C5.36255 15.8624 5.51255 16.1624 5.66255 16.3124V13.6499H5.36255V15.4874Z\" fill=\"#C8B100\"/>\n <path d=\"M6.5625 16.7999H6.8625V13.6499H6.5625V16.7999Z\" fill=\"#C7B500\"/>\n <path d=\"M7.1626 16.7249C7.2751 16.6874 7.4251 16.6124 7.5001 16.5749V13.6499H7.2001L7.1626 16.7249Z\" fill=\"#C8B100\"/>\n <path d=\"M5.36255 10.7251H8.06255V13.7251H5.36255V10.7251Z\" fill=\"#ED4C5C\"/>\n <path d=\"M7.80005 16.3125C7.95005 16.2 8.06255 15.9375 8.10005 15.6375V13.6875H7.80005V16.3125Z\" fill=\"#C8B100\"/>\n <path d=\"M10.7999 13.7246V15.5246C10.7999 16.2371 10.1999 16.7996 9.44985 16.7996C8.69985 16.7996 8.09985 16.2371 8.09985 15.5246V13.7246H10.7999Z\" fill=\"#ED4C5C\"/>\n <path d=\"M9.8248 11.2498C9.9373 11.4748 9.9373 12.0373 9.5998 11.9248C9.6748 11.9623 9.7123 12.2248 9.8248 12.3748C10.0123 12.5998 10.2373 12.4123 10.1998 12.1498C10.1248 11.7373 10.1623 11.4748 10.2373 11.0623C10.2373 11.0998 10.4248 11.0998 10.4998 11.0248C10.4623 11.1373 10.4248 11.2873 10.4998 11.2873C10.4248 11.3998 10.2373 11.5873 10.1998 11.6998C10.1623 11.9623 10.5748 12.4498 10.1248 12.5623C9.8248 12.6373 10.0123 12.8623 10.1248 12.9748C10.1248 12.9748 9.9748 13.4623 10.0498 13.4248C9.7498 13.5373 9.8248 13.2748 9.8248 13.2748C9.9748 12.8248 9.5623 12.7873 9.5998 12.7123C9.2248 12.6748 9.6373 13.0498 9.2998 13.0498C9.2248 13.0498 9.0748 13.1248 9.0748 13.1248C8.6623 13.0873 8.8873 12.7123 9.0373 12.7498C9.1498 12.7873 9.2623 12.9748 9.2623 12.7123C9.2623 12.7123 9.0748 12.4123 9.5623 12.4123C9.3748 12.4123 9.2623 12.2623 9.1873 12.0748C9.1123 12.1123 8.9998 12.2998 8.5873 12.3373C8.5873 12.3373 8.4748 11.9248 8.5873 11.9998C8.7373 12.0748 8.8123 12.0748 8.9623 11.9248C8.8873 11.8123 8.4373 11.6623 8.5123 11.3998C8.5123 11.3248 8.7373 11.2123 8.7373 11.2123C8.6998 11.3998 8.8123 11.5873 9.0373 11.5873C9.3373 11.6248 9.2248 11.5123 9.2623 11.4373C9.2998 11.3623 9.5248 11.4748 9.4498 11.2873C9.4498 11.2498 9.1873 11.2123 9.2623 11.0998C9.4123 10.9123 9.6373 11.0623 9.8248 11.2498Z\" fill=\"#ED4C5C\"/>\n <path d=\"M8.0999 16.725L8.0249 16.5375L8.0999 16.3125L8.1749 16.5375L8.0999 16.725Z\" fill=\"#ED4C5C\"/>\n <path d=\"M6.1874 11.3625V11.55H6.2624V11.7H6.0749V12.075H6.1874V12.9H5.9624V13.3125H7.4999V12.9H7.3124V12.075H7.3874V11.7H7.1999V11.55H7.3124V11.3625H6.9374V11.55H7.0124V11.7H6.8249V11.25H6.9374V11.0625H6.5249V11.25H6.6374V11.7H6.4499V11.55H6.5249V11.3625H6.1874Z\" fill=\"#C8B100\"/>\n <path d=\"M10.4249 15.9751V14.1001H8.47485V15.9751L9.37485 16.3876H9.48735L10.4249 15.9751ZM9.37485 14.2501V14.8876L8.73735 14.2501H9.37485ZM8.58735 14.2876L9.33735 15.0376L8.58735 15.7876V14.2876ZM8.66235 15.9376L9.37485 15.2251V16.2751L8.66235 15.9376ZM9.48735 16.2376V15.1876L10.1999 15.9001L9.48735 16.2376ZM10.2749 15.7876L9.52485 15.0376L10.2749 14.2876V15.7876ZM9.48735 14.2501H10.1249L9.48735 14.8876V14.2501Z\" fill=\"#C8B100\"/>\n <path d=\"M7.19995 13.6874C7.19995 13.1249 7.57495 12.7124 8.06245 12.7124C8.54995 12.7124 8.92495 13.1624 8.92495 13.6874C8.92495 14.2124 8.54995 14.6624 8.06245 14.6624C7.57495 14.6624 7.19995 14.2499 7.19995 13.6874Z\" fill=\"#ED4C5C\"/>\n <path d=\"M7.4624 13.6876C7.4624 13.2751 7.7249 12.9751 8.0624 12.9751C8.3999 12.9751 8.6624 13.3126 8.6624 13.6876C8.6624 14.1001 8.3999 14.4001 8.0624 14.4001C7.7624 14.4376 7.4624 14.1001 7.4624 13.6876Z\" fill=\"#005BBF\"/>\n <path d=\"M7.7999 13.2002L7.6499 13.6127L7.7624 13.6502L7.6874 13.8002H7.9124L7.8374 13.6502L7.9499 13.6127L7.7999 13.2002Z\" fill=\"#C8B100\"/>\n <path d=\"M8.3624 13.2002L8.2124 13.6127L8.3249 13.6502L8.2499 13.8002H8.4749L8.4374 13.6502L8.5499 13.6127L8.3624 13.2002Z\" fill=\"#C8B100\"/>\n <path d=\"M8.09985 13.6875L7.91235 14.1L8.02485 14.1375L7.98735 14.2875H8.17485L8.13735 14.1375L8.24985 14.1L8.09985 13.6875Z\" fill=\"#C8B100\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryESPIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryGBRIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" x=\"0px\" y=\"0px\" viewBox=\"0 0 512 512\" fill=\"none\" {...props} >\n <circle fill=\"#F0F0F0\" cx=\"256\" cy=\"256\" r=\"256\"/>\n <g>\n <path fill=\"#0052B4\" d=\"M52.92,100.142c-20.109,26.163-35.272,56.318-44.101,89.077h133.178L52.92,100.142z\"/>\n <path fill=\"#0052B4\" d=\"M503.181,189.219c-8.829-32.758-23.993-62.913-44.101-89.076l-89.075,89.076H503.181z\"/>\n <path fill=\"#0052B4\" d=\"M8.819,322.784c8.83,32.758,23.993,62.913,44.101,89.075l89.074-89.075L8.819,322.784L8.819,322.784\n z\"/>\n <path fill=\"#0052B4\" d=\"M411.858,52.921c-26.163-20.109-56.317-35.272-89.076-44.102v133.177L411.858,52.921z\"/>\n <path fill=\"#0052B4\" d=\"M100.142,459.079c26.163,20.109,56.318,35.272,89.076,44.102V370.005L100.142,459.079z\"/>\n <path fill=\"#0052B4\" d=\"M189.217,8.819c-32.758,8.83-62.913,23.993-89.075,44.101l89.075,89.075V8.819z\"/>\n <path fill=\"#0052B4\" d=\"M322.783,503.181c32.758-8.83,62.913-23.993,89.075-44.101l-89.075-89.075V503.181z\"/>\n <path fill=\"#0052B4\" d=\"M370.005,322.784l89.075,89.076c20.108-26.162,35.272-56.318,44.101-89.076H370.005z\"/>\n </g>\n <g>\n <path fill=\"#D80027\" d=\"M509.833,222.609h-220.44h-0.001V2.167C278.461,0.744,267.317,0,256,0\n c-11.319,0-22.461,0.744-33.391,2.167v220.44v0.001H2.167C0.744,233.539,0,244.683,0,256c0,11.319,0.744,22.461,2.167,33.391\n h220.44h0.001v220.442C233.539,511.256,244.681,512,256,512c11.317,0,22.461-0.743,33.391-2.167v-220.44v-0.001h220.442\n C511.256,278.461,512,267.319,512,256C512,244.683,511.256,233.539,509.833,222.609z\"/>\n <path fill=\"#D80027\" d=\"M322.783,322.784L322.783,322.784L437.019,437.02c5.254-5.252,10.266-10.743,15.048-16.435\n l-97.802-97.802h-31.482V322.784z\"/>\n <path fill=\"#D80027\" d=\"M189.217,322.784h-0.002L74.98,437.019c5.252,5.254,10.743,10.266,16.435,15.048l97.802-97.804\n V322.784z\"/>\n <path fill=\"#D80027\" d=\"M189.217,189.219v-0.002L74.981,74.98c-5.254,5.252-10.266,10.743-15.048,16.435l97.803,97.803\n H189.217z\"/>\n <path fill=\"#D80027\" d=\"M322.783,189.219L322.783,189.219L437.02,74.981c-5.252-5.254-10.743-10.266-16.435-15.047\n l-97.802,97.803V189.219z\"/>\n </g>\n </SvgIcon>\n )\n};\n\nexport default CountryGBRIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryUSAIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M18 2.475C16.2375 1.3875 14.2125 0.75 12 0.75V2.475H18Z\" fill=\"#ED4C5C\"/>\n <path d=\"M12 4.2001H20.1C19.4625 3.5626 18.75 2.9626 18 2.4751H12V4.2001Z\" fill=\"white\"/>\n <path d=\"M12 5.9252H21.4875C21.075 5.2877 20.625 4.7252 20.1375 4.2002H12V5.9252Z\" fill=\"#ED4C5C\"/>\n <path d=\"M12 7.6498H22.3875C22.125 7.0498 21.825 6.4498 21.4875 5.9248H12V7.6498Z\" fill=\"white\"/>\n <path d=\"M12 9.3749H22.95C22.8 8.7749 22.6125 8.2124 22.3875 7.6499H12V9.3749Z\" fill=\"#ED4C5C\"/>\n <path d=\"M12 11.1376H23.2125C23.175 10.5376 23.0625 9.9751 22.95 9.4126H12V11.1376Z\" fill=\"white\"/>\n <path d=\"M23.2125 11.1377H12V12.0002H0.75C0.75 12.3002 0.75 12.5627 0.7875 12.8627H23.2125C23.25 12.5627 23.25 12.3002 23.25 12.0002C23.25 11.7002 23.25 11.4002 23.2125 11.1377Z\" fill=\"#ED4C5C\"/>\n <path d=\"M1.0501 14.5873H22.9501C23.1001 14.0248 23.1751 13.4623 23.2126 12.8623H0.787598C0.825098 13.4248 0.900098 14.0248 1.0501 14.5873Z\" fill=\"white\"/>\n <path d=\"M1.61255 16.3124H22.3876C22.6126 15.7499 22.8001 15.1874 22.9501 14.5874H1.05005C1.20005 15.1874 1.38755 15.7499 1.61255 16.3124Z\" fill=\"#ED4C5C\"/>\n <path d=\"M2.51255 18.0375H21.4876C21.8251 17.475 22.1251 16.9125 22.3876 16.3125H1.61255C1.87505 16.9125 2.17505 17.475 2.51255 18.0375Z\" fill=\"white\"/>\n <path d=\"M3.86245 19.7626H20.1374C20.625 19.2376 21.1124 18.6376 21.4874 18.0376H2.51245C2.88745 18.6751 3.37495 19.2376 3.86245 19.7626Z\" fill=\"#ED4C5C\"/>\n <path d=\"M5.96255 21.4877H18.0375C18.825 21.0002 19.5001 20.4002 20.1376 19.7627H3.86255C4.50005 20.4377 5.21255 21.0002 5.96255 21.4877Z\" fill=\"white\"/>\n <path d=\"M11.9999 23.2498C14.2124 23.2498 16.2749 22.6123 18.0374 21.4873H5.9624C7.7249 22.6123 9.7874 23.2498 11.9999 23.2498Z\" fill=\"#ED4C5C\"/>\n <path d=\"M6 2.475C5.2125 2.9625 4.5 3.5625 3.8625 4.2C3.3375 4.725 2.8875 5.325 2.5125 5.925C2.175 6.4875 1.8375 7.05 1.6125 7.65C1.3875 8.2125 1.2 8.775 1.05 9.375C0.9 9.9375 0.825 10.5 0.7875 11.1C0.75 11.4 0.75 11.7 0.75 12H12V0.75C9.7875 0.75 7.7625 1.3875 6 2.475Z\" fill=\"#428BC1\"/>\n <path d=\"M9.375 1.125L9.5625 1.6875H10.125L9.675 2.0625L9.825 2.625L9.375 2.2875L8.925 2.625L9.075 2.0625L8.625 1.6875H9.1875L9.375 1.125Z\" fill=\"white\"/>\n <path d=\"M10.875 3.375L11.0625 3.9375H11.625L11.175 4.3125L11.325 4.875L10.875 4.5375L10.425 4.875L10.575 4.3125L10.125 3.9375H10.6875L10.875 3.375Z\" fill=\"white\"/>\n <path d=\"M7.875 3.375L8.0625 3.9375H8.625L8.175 4.3125L8.325 4.875L7.875 4.5375L7.425 4.875L7.575 4.3125L7.125 3.9375H7.6875L7.875 3.375Z\" fill=\"white\"/>\n <path d=\"M9.375 5.625L9.5625 6.1875H10.125L9.675 6.5625L9.825 7.125L9.375 6.7875L8.925 7.125L9.075 6.5625L8.625 6.1875H9.1875L9.375 5.625Z\" fill=\"white\"/>\n <path d=\"M6.375 5.625L6.5625 6.1875H7.125L6.675 6.5625L6.825 7.125L6.375 6.7875L5.925 7.125L6.075 6.5625L5.625 6.1875H6.1875L6.375 5.625Z\" fill=\"white\"/>\n <path d=\"M3.375 5.625L3.5625 6.1875H4.125L3.675 6.5625L3.825 7.125L3.375 6.7875L2.925 7.125L3.075 6.5625L2.625 6.1875H3.1875L3.375 5.625Z\" fill=\"white\"/>\n <path d=\"M10.875 7.875L11.0625 8.4375H11.625L11.175 8.8125L11.325 9.375L10.875 9.0375L10.425 9.375L10.575 8.8125L10.125 8.4375H10.6875L10.875 7.875Z\" fill=\"white\"/>\n <path d=\"M7.875 7.875L8.0625 8.4375H8.625L8.175 8.8125L8.325 9.375L7.875 9.0375L7.425 9.375L7.575 8.8125L7.125 8.4375H7.6875L7.875 7.875Z\" fill=\"white\"/>\n <path d=\"M4.875 7.875L5.0625 8.4375H5.625L5.175 8.8125L5.325 9.375L4.875 9.0375L4.425 9.375L4.575 8.8125L4.125 8.4375H4.6875L4.875 7.875Z\" fill=\"white\"/>\n <path d=\"M9.375 10.125L9.5625 10.6875H10.125L9.675 11.0625L9.825 11.625L9.375 11.2875L8.925 11.625L9.075 11.0625L8.625 10.6875H9.1875L9.375 10.125Z\" fill=\"white\"/>\n <path d=\"M6.375 10.125L6.5625 10.6875H7.125L6.675 11.0625L6.825 11.625L6.375 11.2875L5.925 11.625L6.075 11.0625L5.625 10.6875H6.1875L6.375 10.125Z\" fill=\"white\"/>\n <path d=\"M3.375 10.125L3.5625 10.6875H4.125L3.675 11.0625L3.825 11.625L3.375 11.2875L2.925 11.625L3.075 11.0625L2.625 10.6875H3.1875L3.375 10.125Z\" fill=\"white\"/>\n <path d=\"M4.42485 4.875L4.87485 4.5375L5.32485 4.875L5.13735 4.3125L5.58735 3.9375H5.02485L4.87485 3.375L4.68735 3.9375H4.16235L4.61235 4.275L4.42485 4.875Z\" fill=\"white\"/>\n <path d=\"M1.4249 9.375L1.8749 9.0375L2.3249 9.375L2.1374 8.8125L2.5874 8.4375H2.0624L1.8749 7.875L1.6874 8.4375H1.3124C1.3124 8.475 1.2749 8.5125 1.2749 8.55L1.5749 8.775L1.4249 9.375Z\" fill=\"white\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryUSAIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryGTMIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props}>\n <path d=\"M23.25 12.0002C23.25 7.08769 20.1375 2.9252 15.75 1.3877V22.6127C20.1375 21.0752 23.25 16.9127 23.25 12.0002Z\" fill=\"#42ADE2\"/>\n <path d=\"M0.75 12.0002C0.75 16.9127 3.9 21.0752 8.25 22.6127V1.3877C3.9 2.9252 0.75 7.08769 0.75 12.0002Z\" fill=\"#42ADE2\"/>\n <path d=\"M15.75 1.3875C14.5875 0.975 13.3125 0.75 12 0.75C10.6875 0.75 9.4125 0.975 8.25 1.3875V22.6125C9.4125 23.025 10.6875 23.25 12 23.25C13.3125 23.25 14.5875 23.025 15.75 22.6125V1.3875Z\" fill=\"#F9F9F9\"/>\n <path d=\"M10.1626 9.7123C10.1626 9.7123 9.90008 9.6373 9.71258 9.6373C9.86258 9.37481 9.93758 8.9248 9.93758 8.9248C9.93758 8.9248 9.52508 9.14981 9.37508 9.4123C9.30008 9.2248 9.15008 9.03731 9.15008 9.03731C9.15008 9.03731 8.96258 9.26231 9.00008 9.44981C9.03758 9.6373 9.30008 9.9748 9.30008 9.9748C9.30008 9.9748 9.67508 10.0873 9.90008 10.0123C10.0126 9.9748 10.1626 9.7123 10.1626 9.7123Z\" fill=\"#699635\"/>\n <path d=\"M9.78755 10.3126C9.78755 10.3126 9.52505 10.3126 9.33755 10.3501C9.41255 10.0876 9.37505 9.6001 9.37505 9.6001C9.37505 9.6001 9.03755 9.9376 8.96255 10.2001C8.85005 10.0501 8.62505 9.9001 8.62505 9.9001C8.62505 9.9001 8.51255 10.1626 8.58755 10.3501C8.66255 10.5376 9.00005 10.7626 9.00005 10.7626C9.00005 10.7626 9.41255 10.7626 9.56255 10.6501C9.71255 10.5751 9.78755 10.3126 9.78755 10.3126Z\" fill=\"#83BF4F\"/>\n <path d=\"M9.56259 10.9873C9.56259 10.9873 9.30009 11.0623 9.11259 11.1373C9.11259 10.8373 8.92509 10.4248 8.92509 10.4248C8.92509 10.4248 8.70009 10.8373 8.70009 11.0998C8.55009 10.9873 8.32509 10.9123 8.32509 10.9123C8.32509 10.9123 8.28759 11.1748 8.40009 11.3623C8.51259 11.5123 8.92509 11.6623 8.92509 11.6623C8.92509 11.6623 9.30009 11.5498 9.45009 11.3998C9.60009 11.2498 9.56259 10.9873 9.56259 10.9873Z\" fill=\"#699635\"/>\n <path d=\"M9.5624 11.6626C9.5624 11.6626 9.3374 11.7751 9.1874 11.9251C9.1124 11.6251 8.8499 11.2876 8.8499 11.2876C8.8499 11.2876 8.7374 11.7376 8.8124 12.0001C8.6249 11.9251 8.3999 11.9251 8.3999 11.9251C8.3999 11.9251 8.3999 12.1876 8.5874 12.3376C8.7374 12.4501 9.1499 12.4876 9.1499 12.4876C9.1499 12.4876 9.4874 12.3001 9.5999 12.1126C9.6374 11.9251 9.5624 11.6626 9.5624 11.6626Z\" fill=\"#83BF4F\"/>\n <path d=\"M9.7124 12.3375C9.7124 12.3375 9.5249 12.525 9.4124 12.7125C9.2624 12.45 8.8874 12.1875 8.8874 12.1875C8.8874 12.1875 8.8874 12.6375 9.0374 12.9C8.8499 12.9 8.5874 12.9375 8.5874 12.9375C8.5874 12.9375 8.6624 13.2 8.8874 13.275C9.0749 13.35 9.4874 13.275 9.4874 13.275C9.4874 13.275 9.7874 13.0125 9.8249 12.7875C9.8624 12.5625 9.7124 12.3375 9.7124 12.3375Z\" fill=\"#699635\"/>\n <path d=\"M10.0499 12.9375C10.0499 12.9375 9.8999 13.1625 9.8624 13.35C9.6749 13.125 9.2249 12.975 9.2249 12.975C9.2249 12.975 9.3374 13.425 9.5624 13.65C9.3749 13.6875 9.1499 13.8 9.1499 13.8C9.1499 13.8 9.2999 14.025 9.5249 14.0625C9.7499 14.1 10.0874 13.9125 10.0874 13.9125C10.0874 13.9125 10.3124 13.575 10.2749 13.35C10.2749 13.125 10.0499 12.9375 10.0499 12.9375Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.4999 13.4624C10.4999 13.4624 10.4249 13.7249 10.4249 13.9124C10.1624 13.7624 9.7124 13.6874 9.7124 13.6874C9.7124 13.6874 9.9374 14.0999 10.1999 14.2499C10.0124 14.3249 9.8249 14.4749 9.8249 14.4749C9.8249 14.4749 10.0499 14.6624 10.2374 14.6249C10.4249 14.5874 10.7624 14.3249 10.7624 14.3249C10.7624 14.3249 10.8749 13.9499 10.7999 13.7249C10.7249 13.4999 10.4999 13.4624 10.4999 13.4624Z\" fill=\"#699635\"/>\n <path d=\"M11.1 13.8374C11.1 13.8374 11.1 14.0999 11.1375 14.2874C10.875 14.2124 10.3875 14.2499 10.3875 14.2499C10.3875 14.2499 10.725 14.5874 10.9875 14.6624C10.875 14.7749 10.725 14.9999 10.725 14.9999C10.725 14.9999 10.9875 15.1124 11.175 15.0374C11.3625 14.9624 11.5875 14.6249 11.5875 14.6249C11.5875 14.6249 11.5875 14.2124 11.475 14.0624C11.4 13.8749 11.1 13.8374 11.1 13.8374Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.8374 9.7123C13.8374 9.7123 14.0999 9.6373 14.2874 9.6373C14.1374 9.37481 14.0624 8.9248 14.0624 8.9248C14.0624 8.9248 14.4749 9.14981 14.6249 9.4123C14.6999 9.2248 14.8499 9.03731 14.8499 9.03731C14.8499 9.03731 15.0374 9.26231 14.9999 9.44981C14.9624 9.6373 14.6999 9.9748 14.6999 9.9748C14.6999 9.9748 14.3249 10.0873 14.0999 10.0123C13.9874 9.9748 13.8374 9.7123 13.8374 9.7123Z\" fill=\"#699635\"/>\n <path d=\"M14.2124 10.3126C14.2124 10.3126 14.4749 10.3126 14.6624 10.3501C14.5874 10.0876 14.6249 9.6001 14.6249 9.6001C14.6249 9.6001 14.9624 9.9376 15.0374 10.2001C15.1499 10.0501 15.3749 9.9001 15.3749 9.9001C15.3749 9.9001 15.4874 10.1626 15.4124 10.3501C15.3374 10.5376 14.9999 10.7626 14.9999 10.7626C14.9999 10.7626 14.5874 10.7626 14.4374 10.6501C14.2874 10.5751 14.2124 10.3126 14.2124 10.3126Z\" fill=\"#83BF4F\"/>\n <path d=\"M14.4374 10.9873C14.4374 10.9873 14.6999 11.0623 14.8874 11.1373C14.8874 10.8373 15.0749 10.4248 15.0749 10.4248C15.0749 10.4248 15.2999 10.8373 15.3374 11.0998C15.4874 10.9873 15.7124 10.9123 15.7124 10.9123C15.7124 10.9123 15.7499 11.1748 15.6374 11.3623C15.5249 11.5123 15.1124 11.6623 15.1124 11.6623C15.1124 11.6623 14.7374 11.5498 14.5874 11.3998C14.3999 11.2498 14.4374 10.9873 14.4374 10.9873Z\" fill=\"#699635\"/>\n <path d=\"M14.4374 11.6626C14.4374 11.6626 14.6624 11.7751 14.8124 11.9251C14.8874 11.6251 15.1499 11.2876 15.1499 11.2876C15.1499 11.2876 15.2624 11.7376 15.1874 12.0001C15.3749 11.9251 15.5999 11.9251 15.5999 11.9251C15.5999 11.9251 15.5999 12.1876 15.4124 12.3376C15.2624 12.4501 14.8499 12.4876 14.8499 12.4876C14.8499 12.4876 14.5124 12.3001 14.3999 12.1126C14.3624 11.9251 14.4374 11.6626 14.4374 11.6626Z\" fill=\"#83BF4F\"/>\n <path d=\"M14.2875 12.3375C14.2875 12.3375 14.475 12.525 14.5875 12.7125C14.7375 12.45 15.1125 12.1875 15.1125 12.1875C15.1125 12.1875 15.1125 12.6375 14.9625 12.9C15.15 12.9 15.4125 12.9375 15.4125 12.9375C15.4125 12.9375 15.3375 13.2 15.1125 13.275C14.925 13.35 14.5125 13.275 14.5125 13.275C14.5125 13.275 14.2125 13.0125 14.175 12.7875C14.1375 12.5625 14.2875 12.3375 14.2875 12.3375Z\" fill=\"#699635\"/>\n <path d=\"M13.9499 12.9375C13.9499 12.9375 14.0999 13.1625 14.1374 13.35C14.3249 13.125 14.7749 12.975 14.7749 12.975C14.7749 12.975 14.6624 13.425 14.4374 13.65C14.6249 13.6875 14.8499 13.8 14.8499 13.8C14.8499 13.8 14.6999 14.025 14.4749 14.0625C14.2499 14.1 13.9124 13.9125 13.9124 13.9125C13.9124 13.9125 13.6874 13.575 13.7249 13.35C13.7624 13.125 13.9499 12.9375 13.9499 12.9375Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.5001 13.4624C13.5001 13.4624 13.5751 13.7249 13.5751 13.9124C13.8376 13.7624 14.2876 13.6874 14.2876 13.6874C14.2876 13.6874 14.0626 14.0999 13.8001 14.2499C13.9876 14.3249 14.1751 14.4749 14.1751 14.4749C14.1751 14.4749 13.9501 14.6624 13.7626 14.6249C13.5751 14.5874 13.2376 14.3249 13.2376 14.3249C13.2376 14.3249 13.1251 13.9499 13.2001 13.7249C13.2376 13.5749 13.5001 13.4624 13.5001 13.4624Z\" fill=\"#699635\"/>\n <path d=\"M12.9 13.8374C12.9 13.8374 12.9 14.0999 12.8625 14.2874C13.125 14.2124 13.6124 14.2499 13.6124 14.2499C13.6124 14.2499 13.275 14.5874 13.0125 14.6624C13.1625 14.7749 13.3125 14.9999 13.3125 14.9999C13.3125 14.9999 13.05 15.1124 12.8625 15.0374C12.675 14.9624 12.45 14.6249 12.45 14.6249C12.45 14.6249 12.45 14.2124 12.5625 14.0624C12.6 13.8749 12.9 13.8374 12.9 13.8374Z\" fill=\"#83BF4F\"/>\n <path d=\"M15 9.0376L9.75 13.8751L10.2 14.2876L15 9.0376Z\" fill=\"#94989B\"/>\n <path d=\"M9 9.0376L14.25 13.8751L13.8 14.2876L9 9.0376Z\" fill=\"#94989B\"/>\n <path d=\"M10.95 12.375H12.45C12.45 12.375 12.825 12 12.825 10.875C12.825 9.75 12.45 9.375 12.45 9.375H10.95C10.95 9.375 11.325 9.75 11.325 10.875C11.325 12 10.95 12.375 10.95 12.375Z\" fill=\"#FFDD7D\"/>\n <path d=\"M11.6251 7.7998V7.8748C11.6251 7.9123 11.6251 7.98731 11.6626 8.09981C11.6626 8.13731 11.7001 8.1748 11.7001 8.2498C11.7376 8.2873 11.7376 8.3623 11.7751 8.3998C11.8126 8.4373 11.8501 8.5123 11.8876 8.5498C11.9251 8.5873 11.9626 8.66231 12.0376 8.69981C12.1501 8.81231 12.2626 8.88731 12.4126 8.9998C12.4876 9.0373 12.5626 9.1123 12.6376 9.1498C12.7126 9.2248 12.7876 9.2623 12.9001 9.3373C13.0876 9.5248 13.2376 9.6748 13.3876 9.8998C13.4626 10.0123 13.5376 10.0873 13.5751 10.1998C13.6501 10.3123 13.6876 10.4248 13.7251 10.5373C13.8001 10.7623 13.8751 11.0248 13.8751 11.2873C13.9126 11.5498 13.8376 11.7748 13.8001 12.0373C13.7251 12.2623 13.6126 12.4873 13.5001 12.6748C13.4626 12.7498 13.3501 12.8248 13.3126 12.8998C13.2376 12.9748 13.1626 13.0498 13.0876 13.0873C13.0126 13.1248 12.9376 13.1998 12.8626 13.2373L12.6376 13.3498C12.5251 13.4248 12.3751 13.4623 12.3001 13.4623C12.1126 13.4998 12.0001 13.4998 12.0001 13.4998C12.0001 13.4998 12.0751 13.4248 12.2251 13.3123C12.3001 13.2748 12.3751 13.1623 12.4876 13.0873C12.6001 13.0123 12.6751 12.8998 12.7876 12.7873C12.8251 12.7498 12.8626 12.6748 12.9001 12.5998C12.9376 12.5248 12.9751 12.4873 13.0126 12.3748C13.0876 12.2248 13.1251 12.0748 13.1626 11.8873C13.2001 11.6998 13.2001 11.5498 13.1626 11.3623C13.1251 11.1748 13.0876 10.9873 13.0126 10.8373C12.9751 10.7623 12.9376 10.6498 12.9001 10.5748C12.8626 10.4998 12.8251 10.3873 12.7501 10.3123C12.6376 10.1623 12.5626 9.9748 12.4501 9.8623C12.3001 9.7123 12.1876 9.56231 12.0376 9.44981C11.9626 9.37481 11.8876 9.29981 11.8501 9.22481C11.8126 9.14981 11.7376 9.07481 11.7001 8.9998L11.5876 8.7748C11.5501 8.6998 11.5126 8.6248 11.5126 8.5498C11.5126 8.4748 11.4751 8.39981 11.4751 8.32481V8.13731C11.4751 8.02481 11.5126 7.94981 11.5501 7.91231C11.5876 7.83731 11.6251 7.7998 11.6251 7.7998Z\" fill=\"#699635\"/>\n <path d=\"M9.5251 14.9623C9.4126 15.0748 9.2251 15.0748 9.0751 14.9623C8.9626 14.8498 8.9626 14.6623 9.0751 14.5123L9.9376 13.6498C10.0501 13.5373 10.2376 13.5373 10.3876 13.6498C10.5001 13.7623 10.5001 13.9498 10.3876 14.0998L9.5251 14.9623Z\" fill=\"#594640\"/>\n <path d=\"M14.4752 14.9623C14.5877 15.0748 14.7752 15.0748 14.9252 14.9623C15.0377 14.8498 15.0377 14.6623 14.9252 14.5123L14.0627 13.6498C13.9502 13.5373 13.7627 13.5373 13.6127 13.6498C13.5002 13.7623 13.5002 13.9498 13.6127 14.0998L14.4752 14.9623Z\" fill=\"#594640\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryGTMIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryHNDIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 23.25C16.9124 23.25 21.0749 20.1375 22.6124 15.75H1.38745C2.92495 20.1375 7.08745 23.25 12 23.25Z\" fill=\"#42ADE2\"/>\n <path d=\"M12 0.75C7.08745 0.75 2.92495 3.8625 1.38745 8.25H22.6124C21.0749 3.8625 16.9124 0.75 12 0.75Z\" fill=\"#42ADE2\"/>\n <path d=\"M22.6125 15.75C23.025 14.5875 23.25 13.3125 23.25 12C23.25 10.6875 23.025 9.4125 22.6125 8.25H1.3875C0.975 9.4125 0.75 10.6875 0.75 12C0.75 13.3125 0.975 14.5875 1.3875 15.75H22.6125Z\" fill=\"#F9F9F9\"/>\n <path d=\"M12 12.6L12.7125 13.125L12.45 12.2625L13.125 11.7375H12.2625L12 10.875L11.7375 11.7375H10.875L11.55 12.2625L11.2875 13.125L12 12.6Z\" fill=\"#42ADE2\"/>\n <path d=\"M8.25 10.725L8.9625 11.25L8.7 10.3875L9.375 9.8625H8.5125L8.25 9L7.9875 9.8625H7.125L7.8 10.3875L7.5375 11.25L8.25 10.725Z\" fill=\"#42ADE2\"/>\n <path d=\"M15.75 10.725L16.4625 11.25L16.2 10.3875L16.875 9.8625H16.0125L15.75 9L15.4875 9.8625H14.625L15.3 10.3875L15.0375 11.25L15.75 10.725Z\" fill=\"#42ADE2\"/>\n <path d=\"M8.25 14.475L8.9625 15L8.7 14.1375L9.375 13.6125H8.5125L8.25 12.75L7.9875 13.6125H7.125L7.8 14.1375L7.5375 15L8.25 14.475Z\" fill=\"#42ADE2\"/>\n <path d=\"M15.75 14.475L16.4625 15L16.2 14.1375L16.875 13.6125H16.0125L15.75 12.75L15.4875 13.6125H14.625L15.3 14.1375L15.0375 15L15.75 14.475Z\" fill=\"#42ADE2\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryHNDIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryMEXIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M23.25 12.0002C23.25 7.08769 20.1375 2.9252 15.75 1.3877V22.6127C20.1375 21.0752 23.25 16.9127 23.25 12.0002Z\" fill=\"#ED4C5C\"/>\n <path d=\"M0.75 12.0002C0.75 16.9127 3.9 21.0752 8.25 22.6127V1.3877C3.9 2.9252 0.75 7.08769 0.75 12.0002Z\" fill=\"#75A843\"/>\n <path d=\"M15.75 1.3875C14.5875 0.975 13.3125 0.75 12 0.75C10.6875 0.75 9.4125 0.975 8.25 1.3875V22.6125C9.4125 23.025 10.6875 23.25 12 23.25C13.3125 23.25 14.5875 23.025 15.75 22.6125V1.3875Z\" fill=\"white\"/>\n <path d=\"M15.2625 11.8876C15.225 11.7751 15.1875 11.9251 15.1875 11.9626C15.1875 11.8501 15.15 11.7751 15.075 11.6626C14.9625 11.7751 14.925 11.9251 14.925 12.0751C14.8875 11.9626 14.85 11.8501 14.7375 11.8126C14.8125 11.9251 14.775 12.0001 14.775 12.1126C14.775 12.2626 14.8875 12.3751 14.8875 12.5251C14.8875 12.6751 14.8125 12.7876 14.7 12.9001V12.7876C14.325 12.9376 14.4 13.1251 14.4 13.4626C14.4 13.8001 14.2125 13.7251 13.9875 13.9126C14.025 13.8376 14.025 13.7251 13.9875 13.6501C13.9875 13.8751 13.6875 13.8751 13.65 14.0626C13.6125 14.1376 13.65 14.2876 13.5375 14.3251C13.4625 14.3626 13.35 14.4376 13.35 14.5126C13.275 14.4751 13.2 14.4751 13.0875 14.4751C13.125 14.4376 13.1625 14.4376 13.2 14.4001C12.825 14.2126 12.7125 14.6251 12.375 14.6626C12.2625 14.6626 12 14.5126 12 14.6626C12.3375 14.6626 12.4875 14.9626 12.75 14.9626C12.975 14.9626 13.1625 14.7751 13.3875 14.7751C13.35 14.7751 13.2375 14.7001 13.125 14.7001C13.3125 14.5876 13.425 14.3626 13.65 14.3626C14.025 14.3626 14.2125 14.2876 14.325 13.9126C14.2875 13.9126 14.25 13.9126 14.2125 13.9501C14.2125 13.8001 14.3625 13.6126 14.5125 13.5376C14.8875 13.4626 14.85 13.1626 15.075 12.9001C15 12.9001 14.925 12.9376 14.85 13.0126C14.85 12.7876 14.8125 12.5626 15 12.4126C15.375 12.2251 15.3375 12.1501 15.2625 11.8876Z\" fill=\"#75A843\"/>\n <path d=\"M8.73741 11.8876C8.66241 12.1876 8.62491 12.2626 8.92491 12.4501C9.14991 12.6001 9.07491 12.8251 9.07491 13.0501C8.99991 12.9751 8.96241 12.9376 8.84991 12.9376C9.07491 13.1626 9.03741 13.5001 9.41241 13.5751C9.52491 13.6501 9.71241 13.8376 9.71241 13.9876C9.67491 13.9876 9.63741 13.9501 9.59991 13.9501C9.71241 14.3251 9.89991 14.4001 10.2749 14.4001C10.4999 14.4001 10.6124 14.6251 10.7999 14.7376C10.6874 14.7376 10.5749 14.7751 10.5374 14.8126C10.7624 14.8126 10.9499 15.0376 11.1749 15.0001C11.4374 15.0001 11.6249 14.7001 11.9249 14.7001C11.9249 14.5501 11.6624 14.7001 11.5499 14.7001C11.2499 14.6251 11.1374 14.2501 10.7249 14.4001C10.7624 14.4376 10.7999 14.4751 10.8374 14.4751C10.7624 14.4751 10.6499 14.4376 10.5749 14.5126C10.5374 14.4376 10.4624 14.3626 10.3874 14.3251C10.3124 14.2501 10.3124 14.1376 10.2749 14.0626C10.1999 13.8751 9.93741 13.8376 9.93741 13.6501C9.89991 13.7251 9.89991 13.8376 9.93741 13.9126C9.71241 13.7251 9.52491 13.8001 9.52491 13.4626C9.52491 13.1626 9.59991 12.9376 9.22491 12.7876V12.9001C9.11241 12.7876 9.03741 12.7126 9.03741 12.5251C9.03741 12.3751 9.18741 12.2626 9.14991 12.1126C9.14991 12.0001 9.11241 11.9251 9.18741 11.8126C9.07491 11.8501 9.03741 11.9626 8.99991 12.0751C8.99991 11.9251 8.96241 11.7751 8.84991 11.6626C8.81241 11.7376 8.77491 11.8501 8.73741 11.9626C8.77491 11.8876 8.73741 11.7751 8.73741 11.8876Z\" fill=\"#75A843\"/>\n <path d=\"M13.0124 14.1373C12.9374 14.1373 12.8999 14.0623 12.8624 14.0248C12.8624 13.9498 13.1624 13.8748 13.1999 13.8748V13.7998C12.7124 13.9498 11.2499 14.0623 10.9499 13.5373C10.7999 13.7623 10.5374 13.6123 10.2749 13.4248C10.3124 13.4998 10.4624 13.8748 10.4624 13.8373C10.5374 13.8748 11.0249 13.9873 11.0249 14.0998L10.9124 14.2123C11.6999 14.4748 12.1874 14.5498 13.0124 14.1373Z\" fill=\"#428BC1\"/>\n <path d=\"M12.525 14.1377C12.5625 14.1002 12.5625 14.0627 12.5625 13.9877L12.525 13.8752C12.6 13.8002 12.525 13.6127 12.4125 13.6502C12.3375 13.6877 12.375 13.6877 12.3 13.6502C12.2625 13.6502 12.2625 13.6127 12.225 13.6127H11.55C11.475 13.6127 11.475 13.5752 11.4 13.5752C11.325 13.5377 11.2875 13.6127 11.25 13.6502C11.25 13.7252 11.2875 13.7252 11.2875 13.7627C11.2875 13.8002 11.25 13.8377 11.25 13.9127C11.25 13.9877 11.2875 14.0252 11.325 14.0627C11.175 14.1752 11.325 14.3627 11.475 14.2502C11.5125 14.3252 11.625 14.3252 11.7375 14.3252H12.15C12.225 14.3252 12.375 14.3627 12.4125 14.2502C12.525 14.4377 12.675 14.2127 12.525 14.1377Z\" fill=\"#ED4C5C\"/>\n <path d=\"M13.7251 13.1624C13.4251 12.7874 13.2751 13.3499 12.9376 13.3124C13.0126 12.8624 12.3376 13.0124 12.1501 13.1249C12.1876 13.0874 12.2251 13.0124 12.2626 12.9374C12.1126 12.9374 11.9251 13.0124 11.8126 12.8999C11.5876 12.7499 11.2876 12.6749 11.1001 12.9374C10.9501 12.7124 10.5376 12.4874 10.3126 12.7124C10.3126 12.4874 10.0876 12.1499 9.82512 12.1874C9.52512 12.2249 9.63762 12.5999 9.78762 12.7499C9.90012 12.8624 10.0501 12.8999 10.2001 12.8999C10.2001 12.9749 10.2376 13.0124 10.2751 13.0499C10.4626 13.1999 10.8376 13.2374 11.0251 13.0874C11.0251 13.4624 11.7751 13.4624 11.9626 13.2749C11.8876 13.4624 11.8126 13.8374 12.0751 13.8374C12.3001 13.8374 12.2251 13.6124 12.4126 13.5374C12.5626 13.4624 12.7501 13.4249 12.9001 13.4999C13.1626 13.6499 13.9876 13.6124 13.7251 13.1624Z\" fill=\"#428BC1\"/>\n <path d=\"M10.6499 12.2246C10.6124 12.1496 10.5374 12.0746 10.5374 12.0746C10.3874 12.1121 10.3874 11.9996 10.3499 11.8871C10.3124 11.6996 10.0499 11.6246 10.0499 11.4746C10.0499 11.3246 10.1999 11.1746 10.0874 11.0246C9.97493 10.8746 9.78743 10.7996 9.78743 10.8746C9.74993 10.9496 9.93743 10.9496 9.93743 11.1371C9.93743 11.3621 9.71243 11.5496 9.97493 11.7371C10.1249 11.9621 10.1249 12.3746 10.3874 12.3746C10.4999 12.3746 10.6124 12.3371 10.6499 12.2246Z\" fill=\"#75A843\"/>\n <path d=\"M11.2125 12.0375C11.1375 11.8875 11.2125 11.6625 11.0625 11.55C10.875 11.4 10.5 11.7 10.4625 11.325C10.4625 11.25 10.875 10.8 10.95 10.7625C11.0625 10.6125 11.025 10.35 10.9125 10.275C10.7625 10.2 10.725 10.275 10.6125 10.425C10.65 10.4625 10.8 10.5375 10.8 10.575C10.6875 10.8375 10.35 10.875 10.275 11.1375C10.2 11.325 10.2375 11.625 10.425 11.7375C10.5375 11.8125 10.6125 11.8125 10.725 11.8125C11.0625 11.775 10.875 11.85 10.9125 11.925C10.9125 12 11.025 12.2625 11.2125 12.0375Z\" fill=\"#75A843\"/>\n <path d=\"M10.0874 10.1998C10.0874 10.4248 10.3124 10.3873 10.4624 10.3498C10.4624 10.2748 10.4624 10.1998 10.4999 10.1248C10.4249 10.1623 10.3124 10.1623 10.2749 10.1248C10.1624 10.0498 10.5374 9.89984 10.4999 9.89984C10.4999 9.89984 10.1249 10.0873 10.2749 9.86234C10.3124 9.78734 10.3874 9.71234 10.4249 9.63734C10.4624 9.56234 10.3124 9.63734 10.3124 9.63734C10.2749 9.63734 10.2374 9.63734 10.1999 9.67484C9.97488 9.86234 10.0499 9.97484 10.0874 10.1998Z\" fill=\"#75A843\"/>\n <path d=\"M14.0624 10.2C13.8749 9.9375 13.1624 9.075 12.1499 9C12.0374 9 11.7374 9.1125 11.6249 9.15C11.2874 9.375 11.9999 9.5625 12.0374 9.7125C12.0374 9.7875 12.0749 9.825 12.0749 9.9C11.9624 9.7125 11.8499 9.6 11.8124 9.525C11.6249 9.6 11.3249 9.4875 11.2874 9.3C11.2499 9.375 11.2499 9.4125 11.1749 9.4875C11.1749 9.375 11.1374 9.375 11.0999 9.3C11.0999 9.4125 11.0999 9.5625 10.9874 9.6C11.0249 9.525 10.9874 9.45 10.9499 9.375C10.9499 9.4875 10.9499 9.5625 10.8749 9.6375C10.9124 9.5625 10.8374 9.525 10.8374 9.45C10.7999 9.75 10.3874 9.8625 10.7999 9.975C10.9499 10.0125 11.0249 9.975 11.1749 10.05C11.2124 10.0875 11.2874 10.1625 11.2874 10.125C11.2874 10.1625 11.1374 10.3125 11.2499 10.35C11.2124 10.3875 11.0999 10.6125 11.0999 10.6125C11.2124 10.6125 11.1374 10.6875 11.0624 10.7625C10.9499 10.95 11.0624 11.1375 11.0999 11.3625C11.0999 11.2875 11.2124 11.4 11.2124 11.5125C11.2124 11.6625 11.3624 11.7375 11.3999 11.85C11.2124 11.6625 11.1749 11.85 11.3999 11.9625C11.2124 11.9625 11.1749 12.075 11.3624 12.15C10.9124 12.15 11.2874 12.3375 11.3624 12.375C11.6624 12.45 11.8874 12.225 11.8874 12.1875C11.8874 12.1875 12.4874 12.7875 12.5249 12.7875C12.5624 12.7875 12.8624 12.6375 12.9374 12.7125C13.0124 12.825 13.0874 12.7125 13.1624 12.75C13.2374 12.825 13.5374 12.75 13.6124 12.7125C13.6499 12.7125 14.0249 12.6375 13.9499 12.5625C13.7624 12.4125 13.5374 12.2625 13.3499 12.1125C13.1624 11.9625 12.9749 11.85 12.8249 11.7C12.7499 11.625 12.7499 11.475 12.7124 11.3625C13.0499 11.7 13.3874 11.8875 13.3499 11.25C13.5749 11.4375 14.0249 12.4875 14.0624 12.4875C14.1749 12.4875 14.0624 11.3625 14.0624 11.25C14.2124 11.4 14.2124 12.6375 14.2499 12.6375C14.4374 12.675 14.6999 11.025 14.0624 10.2Z\" fill=\"#89664C\"/>\n <path d=\"M11.3624 12.1127C11.3249 12.1127 11.1374 11.8502 11.1374 11.8127C11.2499 12.2627 10.7999 12.0002 10.9124 11.8127C10.7624 11.7752 10.3874 12.0002 10.5374 12.2252C10.4624 12.3752 11.0624 12.2627 11.0999 12.1877C11.2499 12.5252 11.6249 12.1502 11.3624 12.1127Z\" fill=\"#FFCE31\"/>\n <path d=\"M13.1251 13.2376C13.3126 12.9751 12.5251 12.9001 12.6001 12.6001C12.4876 12.6751 12.3376 12.9376 12.1876 12.8626C12.1126 12.8251 11.8126 13.0126 11.9626 13.1251C11.9626 12.9751 12.0376 13.0876 12.1501 13.0501C12.1126 13.1626 12.0001 13.2751 12.1876 13.3501C12.1126 13.1251 12.4126 13.2376 12.3751 13.1251C12.3001 13.0501 12.6376 13.0501 12.6751 13.0501C12.7876 13.0501 13.1626 13.1626 13.0126 13.2751C13.0126 13.2751 13.0876 13.2751 13.1251 13.2376Z\" fill=\"#FFCE31\"/>\n <path d=\"M10.6125 10.0125C10.575 10.0875 10.425 10.2 10.425 10.3125C10.425 10.3875 10.6125 10.575 10.6875 10.4625C10.4625 10.3125 10.725 10.2 10.8375 10.2C10.875 10.2 10.875 10.275 10.875 10.275C10.9125 10.3125 11.2125 10.2 11.175 10.125C11.2125 9.97503 10.725 9.97503 10.6125 10.0125Z\" fill=\"#FFCE31\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryMEXIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryNICIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 0.75C7.08745 0.75 2.92495 3.9 1.38745 8.25H22.6124C21.0749 3.9 16.9124 0.75 12 0.75ZM12 23.25C16.9124 23.25 21.0749 20.1375 22.6124 15.75H1.38745C2.92495 20.1375 7.08745 23.25 12 23.25Z\" fill=\"#428BC1\"/>\n <path d=\"M1.3875 8.25C0.975 9.4125 0.75 10.6875 0.75 12C0.75 13.3125 0.975 14.5875 1.3875 15.75H22.6125C23.025 14.5875 23.25 13.3125 23.25 12C23.25 10.6875 23.025 9.4125 22.6125 8.25H1.3875Z\" fill=\"#F9F9F9\"/>\n <path d=\"M12 9.4873L9.63745 13.2748H14.3624L12 9.4873Z\" fill=\"#42ADE2\"/>\n <path d=\"M10.8375 11.4004L9.63745 13.2754H14.3624L13.1624 11.4004H10.8375Z\" fill=\"#428BC1\"/>\n <path d=\"M12.375 11.6248V11.4748C12.375 11.3623 12.3 11.2123 12.1875 11.0623C12.1125 10.9123 12 10.8748 11.8125 10.9873C11.7375 11.0248 11.7 11.0623 11.6625 11.1748V11.2873C11.6625 11.2873 11.7375 11.3248 11.775 11.2498C11.8125 11.2498 11.8125 11.2123 11.8125 11.2123C11.775 11.2123 11.775 11.2498 11.775 11.2498C11.7375 11.2873 11.7 11.3248 11.6625 11.3998C11.625 11.4748 11.625 11.5498 11.625 11.5873C11.625 11.5873 11.6625 11.6623 11.7375 11.6623C11.8125 11.6998 11.85 11.7373 11.8875 11.7748C11.925 11.8123 11.925 11.8498 11.925 11.9248C11.925 11.9623 11.925 12.0373 11.9625 12.0373C12 12.0373 12.0375 11.9998 12.075 11.9623C12.075 11.8873 12.1125 11.8498 12.1125 11.8123C12.15 11.7748 12.15 11.7748 12.225 11.7748C12.2625 11.7748 12.3 11.7748 12.3 11.7373V11.6998C12.375 11.6998 12.3375 11.6623 12.375 11.6248Z\" fill=\"url(#paint0_linear_19508_8217)\"/>\n <path d=\"M14.0999 12.9004C13.7249 12.8629 13.3874 12.5254 13.3124 12.1879C13.3124 12.1879 13.2749 12.1504 13.2374 12.1504C13.1624 12.1504 13.1624 12.1879 13.1624 12.1879C13.1249 12.3004 13.0499 12.4504 12.9374 12.5629C12.8249 12.4504 12.7499 12.3004 12.7124 12.1879C12.7124 12.1879 12.6749 12.1504 12.6374 12.1504C12.5624 12.1504 12.5624 12.1879 12.5624 12.1879C12.5249 12.3004 12.4499 12.4504 12.3374 12.5629C12.2249 12.4504 12.1499 12.3004 12.1124 12.1879C12.1124 12.1879 12.0749 12.1504 12.0374 12.1504C11.9999 12.1504 11.9624 12.1879 11.9624 12.1879C11.9249 12.3004 11.8499 12.4504 11.7374 12.5629C11.6249 12.4504 11.5499 12.3004 11.5124 12.1879C11.5124 12.1879 11.4749 12.1504 11.4374 12.1504C11.3624 12.1504 11.3624 12.1879 11.3624 12.1879C11.3249 12.3004 11.2499 12.4504 11.1374 12.5629C11.0249 12.4504 10.9499 12.3004 10.9124 12.1879C10.9124 12.1879 10.8749 12.1504 10.8374 12.1504C10.7624 12.1504 10.7624 12.1879 10.7624 12.1879C10.6499 12.5254 10.3124 12.9379 9.8999 12.9754L9.7124 13.2379H14.3624L14.0999 12.9004Z\" fill=\"#83BF4F\"/>\n <path d=\"M12 8.625C10.125 8.625 8.625 10.125 8.625 12C8.625 13.875 10.125 15.375 12 15.375C13.875 15.375 15.375 13.875 15.375 12C15.375 10.125 13.875 8.625 12 8.625ZM12 14.8125C10.4625 14.8125 9.1875 13.5375 9.1875 12C9.1875 10.4625 10.4625 9.1875 12 9.1875C13.5375 9.1875 14.8125 10.4625 14.8125 12C14.8125 13.5375 13.5375 14.8125 12 14.8125Z\" fill=\"#DBB471\"/>\n <defs>\n <linearGradient id=\"paint0_linear_19508_8217\" x1=\"11.9632\" y1=\"11.4328\" x2=\"12.1852\" y2=\"12.0204\" gradientUnits=\"userSpaceOnUse\">\n <stop stopColor=\"#FF2A2A\"/>\n <stop offset=\"1\" stopColor=\"#FF0000\"/>\n </linearGradient>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountryNICIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryPANIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 0.75V12H23.25C23.25 5.775 18.225 0.75 12 0.75Z\" fill=\"#ED4C5C\"/>\n <path d=\"M12 23.25V12H0.75C0.75 18.225 5.775 23.25 12 23.25Z\" fill=\"#2A5F9E\"/>\n <path d=\"M12 23.25V12H23.25C23.25 18.225 18.225 23.25 12 23.25Z\" fill=\"#F9F9F9\"/>\n <path d=\"M12 0.75V12H0.75C0.75 5.775 5.775 0.75 12 0.75Z\" fill=\"#F9F9F9\"/>\n <path d=\"M6.375 7.7625L7.5375 8.625L7.0875 7.2L8.25 6.3H6.825L6.375 4.875L5.925 6.3H4.5L5.6625 7.2L5.2125 8.625L6.375 7.7625Z\" fill=\"#2A5F9E\"/>\n <path d=\"M17.625 17.5125L18.7875 18.375L18.3375 16.95L19.5 16.05H18.075L17.625 14.625L17.175 16.05H15.75L16.9125 16.95L16.4625 18.375L17.625 17.5125Z\" fill=\"#ED4C5C\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryPANIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryPRYIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 23.25C16.9124 23.25 21.0749 20.1375 22.6124 15.75H1.38745C2.92495 20.1375 7.08745 23.25 12 23.25Z\" fill=\"#428BC1\"/>\n <path d=\"M12 0.75C7.08745 0.75 2.92495 3.9 1.38745 8.25H22.6124C21.0749 3.9 16.9124 0.75 12 0.75Z\" fill=\"#ED4C5C\"/>\n <path d=\"M22.6125 15.75C23.025 14.5875 23.25 13.3125 23.25 12C23.25 10.6875 23.025 9.4125 22.6125 8.25H1.3875C0.975 9.4125 0.75 10.6875 0.75 12C0.75 13.3125 0.975 14.5875 1.3875 15.75H22.6125Z\" fill=\"#F9F9F9\"/>\n <path d=\"M12 15.375C10.125 15.375 8.625 13.875 8.625 12C8.625 10.125 10.125 8.625 12 8.625C13.875 8.625 15.375 10.125 15.375 12C15.375 13.875 13.875 15.375 12 15.375ZM12 8.7375C10.2 8.7375 8.7375 10.2 8.7375 12C8.7375 13.8 10.2 15.2625 12 15.2625C13.8 15.2625 15.2625 13.8 15.2625 12C15.2625 10.2 13.8 8.7375 12 8.7375Z\" fill=\"#3E4347\"/>\n <path d=\"M11.9999 9.1499C10.4249 9.1499 9.1499 10.4249 9.1499 11.9999C9.1499 13.5749 10.4249 14.8499 11.9999 14.8499C13.5749 14.8499 14.8499 13.5749 14.8499 11.9999C14.8499 10.4249 13.5749 9.1499 11.9999 9.1499ZM11.9999 14.1374C10.8374 14.1374 9.8624 13.1624 9.8624 11.9999C9.8624 10.8374 10.8374 9.8624 11.9999 9.8624C13.1624 9.8624 14.1374 10.8374 14.1374 11.9999C14.1374 13.1624 13.1624 14.1374 11.9999 14.1374Z\" fill=\"#ED4C5C\"/>\n <path d=\"M9.74995 12.0002C9.74995 10.7627 10.7625 9.75019 12 9.75019C13.2375 9.75019 14.2499 10.7627 14.2499 12.0002H14.7374C14.7374 10.5002 13.5 9.2627 12 9.2627C10.5 9.2627 9.26245 10.5002 9.26245 12.0002H9.74995Z\" fill=\"#FFCE31\"/>\n <path d=\"M13.0876 11.8873C13.0876 12.4873 12.6001 12.9748 12.0001 12.9748C11.4001 12.9748 10.9126 12.4873 10.9126 11.8873C10.9126 11.2873 11.4001 10.7998 12.0001 10.7998C12.6001 10.7998 13.0876 11.2873 13.0876 11.8873Z\" fill=\"#428BC1\"/>\n <path d=\"M12.6001 12.6001L12.0001 12.1876L11.4001 12.6001L11.6251 11.9626L11.1001 11.5501H11.7376L11.9626 10.9126L12.1876 11.5501H12.8251L12.3751 11.9626L12.6001 12.6001Z\" fill=\"#FFCE31\"/>\n <path d=\"M11.0249 11.0624C11.0249 11.0624 10.8749 11.0249 10.7999 11.0249C10.8749 10.9124 10.9124 10.6499 10.9124 10.6499C10.9124 10.6499 10.6874 10.7624 10.6124 10.9124C10.5749 10.8374 10.4999 10.7249 10.4999 10.7249C10.4999 10.7249 10.3874 10.8374 10.4249 10.9499C10.4249 11.0624 10.5749 11.2124 10.5749 11.2124C10.5749 11.2124 10.7624 11.2874 10.8749 11.2499C10.9499 11.1749 11.0249 11.0624 11.0249 11.0624Z\" fill=\"#699635\"/>\n <path d=\"M10.8376 11.3624C10.8376 11.3624 10.6876 11.3624 10.6126 11.3999C10.6501 11.2499 10.6126 11.0249 10.6126 11.0249C10.6126 11.0249 10.4251 11.2124 10.3876 11.3249C10.3126 11.2499 10.2001 11.1749 10.2001 11.1749C10.2001 11.1749 10.1251 11.3249 10.1626 11.3999C10.2001 11.4749 10.3876 11.6249 10.3876 11.6249C10.3876 11.6249 10.6126 11.6249 10.6876 11.5874C10.7626 11.5499 10.8376 11.3624 10.8376 11.3624Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.7251 11.6999C10.7251 11.6999 10.5751 11.7374 10.5001 11.7749C10.5001 11.6249 10.4251 11.3999 10.4251 11.3999C10.4251 11.3999 10.3126 11.6249 10.3126 11.7749C10.2376 11.6999 10.1251 11.6624 10.1251 11.6624C10.1251 11.6624 10.0876 11.8124 10.1626 11.8874C10.2376 11.9624 10.4251 12.0374 10.4251 12.0374C10.4251 12.0374 10.6126 11.9999 10.6876 11.9249C10.7626 11.8499 10.7251 11.6999 10.7251 11.6999Z\" fill=\"#699635\"/>\n <path d=\"M10.7249 12.0752C10.7249 12.0752 10.6124 12.1502 10.5374 12.2252C10.4999 12.0752 10.3499 11.8877 10.3499 11.8877C10.3499 11.8877 10.2749 12.1127 10.3124 12.2627C10.1999 12.2252 10.0874 12.2252 10.0874 12.2252C10.0874 12.2252 10.0874 12.3752 10.1999 12.4502C10.2749 12.5252 10.4999 12.5252 10.4999 12.5252C10.4999 12.5252 10.6874 12.4127 10.7249 12.3377C10.7624 12.2627 10.7249 12.0752 10.7249 12.0752Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.8 12.4124C10.8 12.4124 10.6875 12.5249 10.65 12.5999C10.575 12.4499 10.3875 12.3374 10.3875 12.3374C10.3875 12.3374 10.3875 12.5624 10.4625 12.7124H10.2375C10.2375 12.7124 10.275 12.8624 10.3875 12.8999C10.5 12.9374 10.6875 12.8999 10.6875 12.8999C10.6875 12.8999 10.8375 12.7499 10.875 12.6374C10.9125 12.5249 10.8 12.4124 10.8 12.4124Z\" fill=\"#699635\"/>\n <path d=\"M10.9874 12.75C10.9874 12.75 10.9124 12.8625 10.8749 12.975C10.7624 12.8625 10.5374 12.7875 10.5374 12.7875C10.5374 12.7875 10.6124 13.0125 10.6874 13.125C10.5749 13.125 10.4624 13.2 10.4624 13.2C10.4624 13.2 10.5374 13.3125 10.6499 13.35C10.7624 13.35 10.9499 13.275 10.9499 13.275C10.9499 13.275 11.0624 13.0875 11.0624 12.975C11.0999 12.825 10.9874 12.75 10.9874 12.75Z\" fill=\"#83BF4F\"/>\n <path d=\"M11.2125 13.0127C11.2125 13.0127 11.175 13.1627 11.175 13.2377C11.0625 13.1627 10.8 13.1252 10.8 13.1252C10.8 13.1252 10.9125 13.3127 11.0625 13.4252C10.9875 13.4627 10.875 13.5377 10.875 13.5377C10.875 13.5377 10.9875 13.6502 11.1 13.6127C11.2125 13.6127 11.3625 13.4627 11.3625 13.4627C11.3625 13.4627 11.4375 13.2752 11.4 13.1627C11.3625 13.0877 11.2125 13.0127 11.2125 13.0127Z\" fill=\"#699635\"/>\n <path d=\"M11.5499 13.2002C11.5499 13.2002 11.5499 13.3502 11.5874 13.4252C11.4374 13.3877 11.2124 13.4252 11.2124 13.4252C11.2124 13.4252 11.3999 13.5752 11.5124 13.6502L11.3624 13.8002C11.3624 13.8002 11.5124 13.8752 11.5874 13.8377C11.6999 13.8002 11.8124 13.6127 11.8124 13.6127C11.8124 13.6127 11.8124 13.3877 11.7749 13.3127C11.6624 13.2377 11.5499 13.2002 11.5499 13.2002Z\" fill=\"#83BF4F\"/>\n <path d=\"M12.9751 11.0624C12.9751 11.0624 13.1251 11.0249 13.2001 11.0249C13.1251 10.9124 13.0876 10.6499 13.0876 10.6499C13.0876 10.6499 13.3126 10.7624 13.3876 10.9124C13.4251 10.8374 13.5001 10.7249 13.5001 10.7249C13.5001 10.7249 13.6126 10.8374 13.5751 10.9499C13.5751 11.0624 13.4251 11.2124 13.4251 11.2124C13.4251 11.2124 13.2376 11.2499 13.1251 11.2124C13.0501 11.1749 12.9751 11.0624 12.9751 11.0624Z\" fill=\"#699635\"/>\n <path d=\"M13.1626 11.3624C13.1626 11.3624 13.3126 11.3624 13.3876 11.3999C13.3501 11.2499 13.3876 11.0249 13.3876 11.0249C13.3876 11.0249 13.5751 11.2124 13.6126 11.3249C13.6876 11.2499 13.8001 11.1749 13.8001 11.1749C13.8001 11.1749 13.8751 11.3249 13.8376 11.3999C13.8001 11.4749 13.5751 11.6249 13.5751 11.6249C13.5751 11.6249 13.3501 11.6249 13.2751 11.5874C13.2001 11.5499 13.1626 11.3624 13.1626 11.3624Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.275 11.6999C13.275 11.6999 13.425 11.7374 13.5 11.7749C13.5 11.6249 13.575 11.3999 13.575 11.3999C13.575 11.3999 13.6875 11.6249 13.6875 11.7749C13.7625 11.6999 13.875 11.6624 13.875 11.6624C13.875 11.6624 13.9125 11.8124 13.8375 11.8874C13.7625 11.9624 13.575 12.0374 13.575 12.0374C13.575 12.0374 13.3875 11.9999 13.3125 11.9249C13.2375 11.8499 13.275 11.6999 13.275 11.6999Z\" fill=\"#699635\"/>\n <path d=\"M13.275 12.0752C13.275 12.0752 13.3875 12.1502 13.4625 12.2252C13.5 12.0752 13.65 11.8877 13.65 11.8877C13.65 11.8877 13.725 12.1127 13.6875 12.2627C13.8 12.2252 13.9125 12.2252 13.9125 12.2252C13.9125 12.2252 13.9125 12.3752 13.8 12.4502C13.725 12.5252 13.5 12.5252 13.5 12.5252C13.5 12.5252 13.3125 12.4127 13.275 12.3377C13.2375 12.2252 13.275 12.0752 13.275 12.0752Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.2001 12.4124C13.2001 12.4124 13.3126 12.5249 13.3501 12.5999C13.4251 12.4499 13.6126 12.3374 13.6126 12.3374C13.6126 12.3374 13.6126 12.5624 13.5376 12.7124H13.7626C13.7626 12.7124 13.7251 12.8624 13.6126 12.8999C13.5001 12.9374 13.3126 12.8999 13.3126 12.8999C13.3126 12.8999 13.1626 12.7499 13.1251 12.6374C13.0876 12.5249 13.2001 12.4124 13.2001 12.4124Z\" fill=\"#699635\"/>\n <path d=\"M13.0126 12.75C13.0126 12.75 13.0876 12.8625 13.1251 12.975C13.2376 12.8625 13.4626 12.7875 13.4626 12.7875C13.4626 12.7875 13.3876 13.0125 13.3126 13.125C13.4251 13.125 13.5376 13.2 13.5376 13.2C13.5376 13.2 13.4626 13.3125 13.3501 13.35C13.2376 13.35 13.0501 13.275 13.0501 13.275C13.0501 13.275 12.9376 13.0875 12.9376 12.975C12.9001 12.825 13.0126 12.75 13.0126 12.75Z\" fill=\"#83BF4F\"/>\n <path d=\"M12.7876 13.0127C12.7876 13.0127 12.8251 13.1627 12.8251 13.2377C12.9376 13.1627 13.2001 13.1252 13.2001 13.1252C13.2001 13.1252 13.0876 13.3127 12.9376 13.4252C13.0126 13.4627 13.1251 13.5377 13.1251 13.5377C13.1251 13.5377 13.0126 13.6502 12.9001 13.6127C12.7876 13.6127 12.6376 13.4627 12.6376 13.4627C12.6376 13.4627 12.5626 13.2752 12.6001 13.1627C12.6376 13.0877 12.7876 13.0127 12.7876 13.0127Z\" fill=\"#699635\"/>\n <path d=\"M12.45 13.2002C12.45 13.2002 12.45 13.3502 12.4125 13.4252C12.5625 13.3877 12.7875 13.4252 12.7875 13.4252C12.7875 13.4252 12.6 13.5752 12.4875 13.6502L12.6375 13.8002C12.6375 13.8002 12.4875 13.8752 12.4125 13.8377C12.3 13.8002 12.1875 13.6127 12.1875 13.6127C12.1875 13.6127 12.1875 13.3877 12.225 13.3127C12.3375 13.2377 12.45 13.2002 12.45 13.2002Z\" fill=\"#83BF4F\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryPRYIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryPERIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M23.25 12.0002C23.25 7.08769 20.1375 2.9252 15.75 1.3877V22.6127C20.1375 21.0752 23.25 16.9127 23.25 12.0002Z\" fill=\"#ED4C5C\"/>\n <path d=\"M0.75 12.0002C0.75 16.9127 3.9 21.0752 8.25 22.6127V1.3877C3.9 2.9252 0.75 7.08769 0.75 12.0002Z\" fill=\"#ED4C5C\"/>\n <path d=\"M15.75 1.3875C14.5875 0.975 13.3125 0.75 12 0.75C10.6875 0.75 9.4125 0.975 8.25 1.3875V22.6125C9.4125 23.025 10.6875 23.25 12 23.25C13.3125 23.25 14.5875 23.025 15.75 22.6125V1.3875Z\" fill=\"#F9F9F9\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryPERIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryPRTIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M6.375 21.75V2.25C3 4.2 0.75 7.8375 0.75 12C0.75 16.1625 3 19.8 6.375 21.75Z\" fill=\"#699635\"/>\n <path d=\"M12 0.75C9.9375 0.75 8.025 1.3125 6.375 2.25V21.75C8.025 22.725 9.9375 23.25 12 23.25C18.225 23.25 23.25 18.225 23.25 12C23.25 5.775 18.225 0.75 12 0.75Z\" fill=\"#ED4C5C\"/>\n <path d=\"M6.375 7.5C3.9 7.5 1.875 9.525 1.875 12C1.875 14.475 3.9 16.5 6.375 16.5C8.85 16.5 10.875 14.475 10.875 12C10.875 9.525 8.85 7.5 6.375 7.5ZM6.375 15.9375C4.2 15.9375 2.4375 14.175 2.4375 12C2.4375 9.825 4.2 8.0625 6.375 8.0625C8.55 8.0625 10.3125 9.825 10.3125 12C10.3125 14.175 8.55 15.9375 6.375 15.9375Z\" fill=\"#FFE62E\"/>\n <path d=\"M7.91255 16.3877C7.83755 16.4627 7.72505 16.4627 7.65005 16.3877L2.51255 9.6002C2.43755 9.5252 2.43755 9.4127 2.51255 9.3377L2.62505 9.2252C2.70005 9.1502 2.81255 9.1502 2.88755 9.2252L8.02505 16.0127C8.10005 16.0877 8.10005 16.2002 8.02505 16.2752L7.91255 16.3877Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.4502 7.3125C6.5627 7.3125 6.6377 7.3875 6.6377 7.5V16.5C6.6377 16.6125 6.5627 16.6875 6.4502 16.6875H6.2627C6.1502 16.6875 6.0752 16.6125 6.0752 16.5V7.5C6.0752 7.3875 6.1502 7.3125 6.2627 7.3125H6.4502Z\" fill=\"#FFE62E\"/>\n <path d=\"M10.8375 12.4877L6.375 11.7002V12.2627L10.7625 13.0502C10.875 13.0502 10.95 13.0127 10.9875 12.9002L11.025 12.7127C11.025 12.6377 10.95 12.5252 10.8375 12.4877Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.37521 11.6624L2.85021 9.18737C2.77521 9.11237 2.66271 9.14987 2.58771 9.22487L2.47521 9.37487C2.40021 9.44987 2.43771 9.56237 2.51271 9.63737L6.37521 12.3374V11.6624Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.22505 11.25L2.70005 14.775C2.62505 14.85 2.62505 14.9625 2.70005 15.0375L2.85005 15.1875C2.92505 15.2625 3.03755 15.2625 3.11255 15.1875L6.22505 12.075V11.25Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.37511 9.5625L1.68761 11.775C1.61261 11.8125 1.53761 11.925 1.61261 12.0375L1.68761 12.225C1.72511 12.3 1.83761 12.375 1.95011 12.3L6.37511 10.2V9.5625Z\" fill=\"#FFE62E\"/>\n <path d=\"M10.5377 10.2001L6.0752 9.4126V9.9751L10.4627 10.7626C10.5752 10.7626 10.6502 10.7251 10.6877 10.6126L10.7252 10.4251C10.6877 10.3126 10.6127 10.2001 10.5377 10.2001Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.33751 14.5873C6.26251 14.6248 6.18751 14.7373 6.26251 14.8498L6.33751 15.0373C6.37501 15.1123 6.48751 15.1873 6.60001 15.1123L10.35 13.3873L10.5375 12.6748L6.33751 14.5873Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.3377 13.3124L2.1377 11.7749V12.3749L6.3377 13.9124V13.3124Z\" fill=\"#FFE62E\"/>\n <path d=\"M3.4126 14.5498V15.1123L8.9626 15.4873C9.1876 15.3373 9.3751 15.1498 9.5626 14.9623L3.4126 14.5498Z\" fill=\"#FFE62E\"/>\n <path d=\"M4.5 10.125V12.75C4.5 13.8 5.325 14.625 6.375 14.625C7.425 14.625 8.25 13.8 8.25 12.75V10.125H4.5Z\" fill=\"white\"/>\n <path d=\"M6.375 15.375C4.9125 15.375 3.75 14.2125 3.75 12.75V9.375H9V12.75C9 14.2125 7.8375 15.375 6.375 15.375ZM5.25 10.875V12.75C5.25 13.3875 5.7375 13.875 6.375 13.875C7.0125 13.875 7.5 13.3875 7.5 12.75V10.875H5.25Z\" fill=\"#ED4C5C\"/>\n <path d=\"M6.0376 11.0248V11.6248C6.0376 11.7373 6.1126 11.8123 6.2251 11.8123H6.5251C6.6376 11.8123 6.7126 11.7373 6.7126 11.6248V10.9873H6.0376V11.0248Z\" fill=\"#0071BC\"/>\n <path d=\"M6.0376 11.9624V12.5999C6.0376 12.7124 6.1126 12.7874 6.2251 12.7874H6.5251C6.6376 12.7874 6.7126 12.7124 6.7126 12.5999V11.9624H6.0376Z\" fill=\"#0071BC\"/>\n <path d=\"M5.2876 11.9624V12.5999C5.2876 12.7124 5.3626 12.7874 5.4751 12.7874H5.7751C5.8876 12.7874 5.9626 12.7124 5.9626 12.5999V11.9624H5.2876Z\" fill=\"#0071BC\"/>\n <path d=\"M6.7876 11.9624V12.5999C6.7876 12.7124 6.8626 12.7874 6.9751 12.7874H7.2751C7.3876 12.7874 7.4626 12.7124 7.4626 12.5999V11.9624H6.7876Z\" fill=\"#0071BC\"/>\n <path d=\"M6.0376 12.8623V13.4998C6.0376 13.6123 6.1126 13.6873 6.2251 13.6873H6.5251C6.6376 13.6873 6.7126 13.6123 6.7126 13.4998V12.8623H6.0376Z\" fill=\"#0071BC\"/>\n <path d=\"M6.3748 12.4127C6.41623 12.4127 6.44981 12.3791 6.44981 12.3377C6.44981 12.2963 6.41623 12.2627 6.3748 12.2627C6.33338 12.2627 6.2998 12.2963 6.2998 12.3377C6.2998 12.3791 6.33338 12.4127 6.3748 12.4127Z\" fill=\"white\"/>\n <path d=\"M6.2249 12.6002C6.26632 12.6002 6.2999 12.5666 6.2999 12.5252C6.2999 12.4838 6.26632 12.4502 6.2249 12.4502C6.18348 12.4502 6.1499 12.4838 6.1499 12.5252C6.1499 12.5666 6.18348 12.6002 6.2249 12.6002Z\" fill=\"white\"/>\n <path d=\"M6.52495 12.6002C6.56637 12.6002 6.59995 12.5666 6.59995 12.5252C6.59995 12.4838 6.56637 12.4502 6.52495 12.4502C6.48353 12.4502 6.44995 12.4838 6.44995 12.5252C6.44995 12.5666 6.48353 12.6002 6.52495 12.6002Z\" fill=\"white\"/>\n <path d=\"M6.2249 12.2252C6.26632 12.2252 6.2999 12.1916 6.2999 12.1502C6.2999 12.1088 6.26632 12.0752 6.2249 12.0752C6.18348 12.0752 6.1499 12.1088 6.1499 12.1502C6.1499 12.1916 6.18348 12.2252 6.2249 12.2252Z\" fill=\"white\"/>\n <path d=\"M6.52495 12.2252C6.56637 12.2252 6.59995 12.1916 6.59995 12.1502C6.59995 12.1088 6.56637 12.0752 6.52495 12.0752C6.48353 12.0752 6.44995 12.1088 6.44995 12.1502C6.44995 12.1916 6.48353 12.2252 6.52495 12.2252Z\" fill=\"white\"/>\n <path d=\"M6.3748 11.4752C6.41623 11.4752 6.44981 11.4416 6.44981 11.4002C6.44981 11.3588 6.41623 11.3252 6.3748 11.3252C6.33338 11.3252 6.2998 11.3588 6.2998 11.4002C6.2998 11.4416 6.33338 11.4752 6.3748 11.4752Z\" fill=\"white\"/>\n <path d=\"M6.2249 11.6627C6.26632 11.6627 6.2999 11.6291 6.2999 11.5877C6.2999 11.5463 6.26632 11.5127 6.2249 11.5127C6.18348 11.5127 6.1499 11.5463 6.1499 11.5877C6.1499 11.6291 6.18348 11.6627 6.2249 11.6627Z\" fill=\"white\"/>\n <path d=\"M6.52495 11.6627C6.56637 11.6627 6.59995 11.6291 6.59995 11.5877C6.59995 11.5463 6.56637 11.5127 6.52495 11.5127C6.48353 11.5127 6.44995 11.5463 6.44995 11.5877C6.44995 11.6291 6.48353 11.6627 6.52495 11.6627Z\" fill=\"white\"/>\n <path d=\"M6.2249 11.2877C6.26632 11.2877 6.2999 11.2541 6.2999 11.2127C6.2999 11.1713 6.26632 11.1377 6.2249 11.1377C6.18348 11.1377 6.1499 11.1713 6.1499 11.2127C6.1499 11.2541 6.18348 11.2877 6.2249 11.2877Z\" fill=\"white\"/>\n <path d=\"M6.52495 11.2877C6.56637 11.2877 6.59995 11.2541 6.59995 11.2127C6.59995 11.1713 6.56637 11.1377 6.52495 11.1377C6.48353 11.1377 6.44995 11.1713 6.44995 11.2127C6.44995 11.2541 6.48353 11.2877 6.52495 11.2877Z\" fill=\"white\"/>\n <path d=\"M7.1248 12.4127C7.16623 12.4127 7.19981 12.3791 7.19981 12.3377C7.19981 12.2963 7.16623 12.2627 7.1248 12.2627C7.08338 12.2627 7.0498 12.2963 7.0498 12.3377C7.0498 12.3791 7.08338 12.4127 7.1248 12.4127Z\" fill=\"white\"/>\n <path d=\"M6.9749 12.6002C7.01632 12.6002 7.0499 12.5666 7.0499 12.5252C7.0499 12.4838 7.01632 12.4502 6.9749 12.4502C6.93348 12.4502 6.8999 12.4838 6.8999 12.5252C6.8999 12.5666 6.93348 12.6002 6.9749 12.6002Z\" fill=\"white\"/>\n <path d=\"M7.27495 12.6002C7.31637 12.6002 7.34995 12.5666 7.34995 12.5252C7.34995 12.4838 7.31637 12.4502 7.27495 12.4502C7.23353 12.4502 7.19995 12.4838 7.19995 12.5252C7.19995 12.5666 7.23353 12.6002 7.27495 12.6002Z\" fill=\"white\"/>\n <path d=\"M6.9749 12.2252C7.01632 12.2252 7.0499 12.1916 7.0499 12.1502C7.0499 12.1088 7.01632 12.0752 6.9749 12.0752C6.93348 12.0752 6.8999 12.1088 6.8999 12.1502C6.8999 12.1916 6.93348 12.2252 6.9749 12.2252Z\" fill=\"white\"/>\n <path d=\"M7.27495 12.2252C7.31637 12.2252 7.34995 12.1916 7.34995 12.1502C7.34995 12.1088 7.31637 12.0752 7.27495 12.0752C7.23353 12.0752 7.19995 12.1088 7.19995 12.1502C7.19995 12.1916 7.23353 12.2252 7.27495 12.2252Z\" fill=\"white\"/>\n <path d=\"M5.6248 12.4127C5.66623 12.4127 5.6998 12.3791 5.6998 12.3377C5.6998 12.2963 5.66623 12.2627 5.6248 12.2627C5.58338 12.2627 5.5498 12.2963 5.5498 12.3377C5.5498 12.3791 5.58338 12.4127 5.6248 12.4127Z\" fill=\"white\"/>\n <path d=\"M5.4749 12.6002C5.51632 12.6002 5.5499 12.5666 5.5499 12.5252C5.5499 12.4838 5.51632 12.4502 5.4749 12.4502C5.43348 12.4502 5.3999 12.4838 5.3999 12.5252C5.3999 12.5666 5.43348 12.6002 5.4749 12.6002Z\" fill=\"white\"/>\n <path d=\"M5.77495 12.6002C5.81637 12.6002 5.84995 12.5666 5.84995 12.5252C5.84995 12.4838 5.81637 12.4502 5.77495 12.4502C5.73353 12.4502 5.69995 12.4838 5.69995 12.5252C5.69995 12.5666 5.73353 12.6002 5.77495 12.6002Z\" fill=\"white\"/>\n <path d=\"M5.4749 12.2252C5.51632 12.2252 5.5499 12.1916 5.5499 12.1502C5.5499 12.1088 5.51632 12.0752 5.4749 12.0752C5.43348 12.0752 5.3999 12.1088 5.3999 12.1502C5.3999 12.1916 5.43348 12.2252 5.4749 12.2252Z\" fill=\"white\"/>\n <path d=\"M5.77495 12.2252C5.81637 12.2252 5.84995 12.1916 5.84995 12.1502C5.84995 12.1088 5.81637 12.0752 5.77495 12.0752C5.73353 12.0752 5.69995 12.1088 5.69995 12.1502C5.69995 12.1916 5.73353 12.2252 5.77495 12.2252Z\" fill=\"white\"/>\n <path d=\"M6.3748 13.3502C6.41623 13.3502 6.44981 13.3166 6.44981 13.2752C6.44981 13.2338 6.41623 13.2002 6.3748 13.2002C6.33338 13.2002 6.2998 13.2338 6.2998 13.2752C6.2998 13.3166 6.33338 13.3502 6.3748 13.3502Z\" fill=\"white\"/>\n <path d=\"M6.2249 13.5377C6.26632 13.5377 6.2999 13.5041 6.2999 13.4627C6.2999 13.4213 6.26632 13.3877 6.2249 13.3877C6.18348 13.3877 6.1499 13.4213 6.1499 13.4627C6.1499 13.5041 6.18348 13.5377 6.2249 13.5377Z\" fill=\"white\"/>\n <path d=\"M6.52495 13.5377C6.56637 13.5377 6.59995 13.5041 6.59995 13.4627C6.59995 13.4213 6.56637 13.3877 6.52495 13.3877C6.48353 13.3877 6.44995 13.4213 6.44995 13.4627C6.44995 13.5041 6.48353 13.5377 6.52495 13.5377Z\" fill=\"white\"/>\n <path d=\"M6.2249 13.1627C6.26632 13.1627 6.2999 13.1291 6.2999 13.0877C6.2999 13.0463 6.26632 13.0127 6.2249 13.0127C6.18348 13.0127 6.1499 13.0463 6.1499 13.0877C6.1499 13.1291 6.18348 13.1627 6.2249 13.1627Z\" fill=\"white\"/>\n <path d=\"M6.52495 13.1627C6.56637 13.1627 6.59995 13.1291 6.59995 13.0877C6.59995 13.0463 6.56637 13.0127 6.52495 13.0127C6.48353 13.0127 6.44995 13.0463 6.44995 13.0877C6.44995 13.1291 6.48353 13.1627 6.52495 13.1627Z\" fill=\"white\"/>\n <path d=\"M6 10.5H6.75L6.675 10.125V9.75H6.75V9.5625H6.6375V9.675H6.6V9.5625H6.4875V9.675H6.4125V9.5625H6.3375V9.675H6.2625V9.5625H6.15V9.675H6.075V9.5625H6V9.75H6.075V10.125L6 10.5Z\" fill=\"#FFE62E\"/>\n <path d=\"M6.48745 10.5003H6.44995V10.3503C6.44995 10.3128 6.41245 10.2753 6.37495 10.2753C6.33745 10.2753 6.29995 10.3128 6.29995 10.3503V10.5003H6.26245V10.3503C6.26245 10.2753 6.29995 10.2378 6.37495 10.2378C6.44995 10.2378 6.48745 10.2753 6.48745 10.3503V10.5003Z\" fill=\"#3E4347\"/>\n <path d=\"M6.3749 10.0876H6.1499V9.9001C6.1499 9.8251 6.1874 9.7876 6.2624 9.7876C6.3374 9.7876 6.3749 9.8251 6.3749 9.9001V10.0876ZM6.1874 10.0501H6.3374V9.9001C6.3374 9.8626 6.2999 9.8251 6.2624 9.8251C6.2249 9.8251 6.1874 9.8626 6.1874 9.9001V10.0501Z\" fill=\"#3E4347\"/>\n <path d=\"M6.6 10.0876H6.375V9.9001C6.375 9.8251 6.4125 9.7876 6.4875 9.7876C6.5625 9.7876 6.6 9.8251 6.6 9.9001V10.0876ZM6.4125 10.0501H6.5625V9.9001C6.5625 9.8626 6.525 9.8251 6.4875 9.8251C6.45 9.8251 6.4125 9.8626 6.4125 9.9001V10.0501Z\" fill=\"#3E4347\"/>\n <path d=\"M4.125 10.5H4.875L4.8 10.125V9.75H4.875V9.5625H4.7625V9.675H4.725V9.5625H4.6125V9.675H4.5375V9.5625H4.4625V9.675H4.3875V9.5625H4.275V9.675H4.2V9.5625H4.125V9.75H4.2V10.125L4.125 10.5Z\" fill=\"#FFE62E\"/>\n <path d=\"M4.61245 10.5003H4.57495V10.3503C4.57495 10.3128 4.53745 10.2753 4.49995 10.2753C4.46245 10.2753 4.42495 10.3128 4.42495 10.3503V10.5003H4.38745V10.3503C4.38745 10.2753 4.42495 10.2378 4.49995 10.2378C4.57495 10.2378 4.61245 10.2753 4.61245 10.3503V10.5003Z\" fill=\"#3E4347\"/>\n <path d=\"M4.4999 10.0876H4.2749V9.9001C4.2749 9.8251 4.3124 9.7876 4.3874 9.7876C4.4624 9.7876 4.4999 9.8251 4.4999 9.9001V10.0876ZM4.3124 10.0501H4.4624V9.9001C4.4624 9.8626 4.4249 9.8251 4.3874 9.8251C4.3499 9.8251 4.3124 9.8626 4.3124 9.9001V10.0501Z\" fill=\"#3E4347\"/>\n <path d=\"M4.725 10.0876H4.5V9.9001C4.5 9.8251 4.5375 9.7876 4.6125 9.7876C4.6875 9.7876 4.725 9.8251 4.725 9.9001V10.0876ZM4.5375 10.0501H4.6875V9.9001C4.6875 9.8626 4.65 9.8251 4.6125 9.8251C4.575 9.8251 4.5375 9.8626 4.5375 9.9001V10.0501Z\" fill=\"#3E4347\"/>\n <path d=\"M4.125 12.7124H4.875L4.8 12.3374V11.9624H4.875V11.7749H4.8V11.8874H4.725V11.7749H4.65V11.8874H4.5375V11.7749H4.4625V11.8874H4.3875V11.7749H4.3125V11.8874H4.2375V11.7749H4.125V11.9624H4.2375V12.3374L4.125 12.7124Z\" fill=\"#FFE62E\"/>\n <path d=\"M4.61245 12.7127H4.57495V12.5627C4.57495 12.5252 4.53745 12.4877 4.49995 12.4877C4.46245 12.4877 4.42495 12.5252 4.42495 12.5627V12.7127H4.38745V12.5627C4.38745 12.4877 4.42495 12.4502 4.49995 12.4502C4.57495 12.4502 4.61245 12.4877 4.61245 12.5627V12.7127Z\" fill=\"#3E4347\"/>\n <path d=\"M4.4999 12.3H4.2749V12.1125C4.2749 12.0375 4.3124 12 4.3874 12C4.4624 12 4.4999 12.0375 4.4999 12.1125V12.3ZM4.3124 12.2625H4.4624V12.1125C4.4624 12.075 4.4249 12.0375 4.3874 12.0375C4.3499 12.0375 4.3124 12.075 4.3124 12.1125V12.2625Z\" fill=\"#3E4347\"/>\n <path d=\"M4.76235 12.3H4.53735V12.1125C4.53735 12.0375 4.57485 12 4.64985 12C4.72485 12 4.76235 12.0375 4.76235 12.1125V12.3ZM4.57485 12.2625H4.72485V12.1125C4.72485 12.075 4.68735 12.0375 4.64985 12.0375C4.61235 12.0375 4.57485 12.075 4.57485 12.1125V12.2625Z\" fill=\"#3E4347\"/>\n <path d=\"M7.875 12.7501H8.625L8.55 12.3751V12.0001H8.625V11.8501H8.5125V11.9251H8.475V11.8501H8.3625V11.9251H8.2875V11.8501H8.2125V11.9251H8.1375V11.8501H8.025V11.9251H7.95V11.8501H7.875V12.0001H7.95V12.3751L7.875 12.7501Z\" fill=\"#FFE62E\"/>\n <path d=\"M8.36245 12.7503H8.32495V12.6003C8.32495 12.5628 8.28745 12.5253 8.24995 12.5253C8.21245 12.5253 8.17495 12.5628 8.17495 12.6003V12.7503H8.13745V12.6003C8.13745 12.5253 8.17495 12.4878 8.24995 12.4878C8.32495 12.4878 8.36245 12.5253 8.36245 12.6003V12.7503Z\" fill=\"#3E4347\"/>\n <path d=\"M8.2499 12.3376H8.0249V12.1501C8.0249 12.0751 8.0624 12.0376 8.1374 12.0376C8.2124 12.0376 8.2499 12.0751 8.2499 12.1501V12.3376ZM8.0624 12.3001H8.2124V12.1501C8.2124 12.1126 8.1749 12.0751 8.1374 12.0751C8.0999 12.0751 8.0624 12.1126 8.0624 12.1501V12.3001Z\" fill=\"#3E4347\"/>\n <path d=\"M8.475 12.3376H8.25V12.1501C8.25 12.0751 8.2875 12.0376 8.3625 12.0376C8.4375 12.0376 8.475 12.0751 8.475 12.1501V12.3376ZM8.2875 12.3001H8.4375V12.1501C8.4375 12.1126 8.4 12.0751 8.3625 12.0751C8.325 12.0751 8.2875 12.1126 8.2875 12.1501V12.3001Z\" fill=\"#3E4347\"/>\n <path d=\"M7.875 10.5H8.625L8.55 10.125V9.75H8.625V9.5625H8.5125V9.675H8.475V9.5625H8.3625V9.675H8.2875V9.5625H8.2125V9.675H8.1375V9.5625H8.025V9.675H7.95V9.5625H7.875V9.75H7.95V10.125L7.875 10.5Z\" fill=\"#FFE62E\"/>\n <path d=\"M8.36245 10.5003H8.32495V10.3503C8.32495 10.3128 8.28745 10.2753 8.24995 10.2753C8.21245 10.2753 8.17495 10.3128 8.17495 10.3503V10.5003H8.13745V10.3503C8.13745 10.2753 8.17495 10.2378 8.24995 10.2378C8.32495 10.2378 8.36245 10.2753 8.36245 10.3503V10.5003Z\" fill=\"#3E4347\"/>\n <path d=\"M8.2499 10.0876H8.0249V9.9001C8.0249 9.8251 8.0624 9.7876 8.1374 9.7876C8.2124 9.7876 8.2499 9.8251 8.2499 9.9001V10.0876ZM8.0624 10.0501H8.2124V9.9001C8.2124 9.8626 8.1749 9.8251 8.1374 9.8251C8.0999 9.8251 8.0624 9.8626 8.0624 9.9001V10.0501Z\" fill=\"#3E4347\"/>\n <path d=\"M8.475 10.0876H8.25V9.9001C8.25 9.8251 8.2875 9.7876 8.3625 9.7876C8.4375 9.7876 8.475 9.8251 8.475 9.9001V10.0876ZM8.2875 10.0501H8.4375V9.9001C8.4375 9.8626 8.4 9.8251 8.3625 9.8251C8.325 9.8251 8.2875 9.8626 8.2875 9.9001V10.0501Z\" fill=\"#3E4347\"/>\n <path d=\"M5.325 14.8499L5.85 14.2874L5.5125 14.0999L5.25 13.8374L5.325 13.7624L5.2125 13.6499L5.1375 13.7249L5.2125 13.7999L5.175 13.8374L5.1 13.7624L5.025 13.8374L5.1 13.8749L5.025 13.9499L4.9875 13.8749L4.9125 13.9499L4.9875 14.0249L4.9125 14.0624L4.875 13.9874L4.8 14.0624L4.8375 14.1374L4.8 14.1749L4.7625 14.0999L4.6875 14.1749L4.8 14.2874H4.8375L4.875 14.2499L5.1375 14.5124L5.325 14.8499Z\" fill=\"#FFE62E\"/>\n <path d=\"M5.66235 14.4752L5.51235 14.4002C5.47485 14.3627 5.43735 14.3627 5.39985 14.4002C5.36235 14.4377 5.36235 14.4752 5.39985 14.5127L5.51235 14.6252L5.47485 14.6627L5.36235 14.5502C5.32485 14.5127 5.32485 14.4377 5.36235 14.4002C5.39985 14.3627 5.47485 14.3627 5.51235 14.4002L5.66235 14.4752Z\" fill=\"#3E4347\"/>\n <path d=\"M5.28745 14.2876L5.13745 14.4376L5.02495 14.3251C4.98745 14.2876 4.98745 14.2126 5.02495 14.1751C5.06245 14.1376 5.13745 14.1376 5.17495 14.1751L5.28745 14.2876ZM5.13745 14.4001L5.24995 14.2876L5.13745 14.1751C5.09995 14.1376 5.06245 14.1376 5.02495 14.1751C4.98745 14.2126 4.98745 14.2501 5.02495 14.2876L5.13745 14.4001Z\" fill=\"#3E4347\"/>\n <path d=\"M5.47495 14.1001L5.32495 14.2501L5.21245 14.1376C5.17495 14.1001 5.17495 14.0251 5.21245 13.9876C5.24995 13.9501 5.32495 13.9501 5.36245 13.9876L5.47495 14.1001ZM5.32495 14.2126L5.43745 14.1001L5.32495 13.9876C5.28745 13.9501 5.24995 13.9501 5.21245 13.9876C5.17495 14.0251 5.17495 14.0626 5.21245 14.1001L5.32495 14.2126Z\" fill=\"#3E4347\"/>\n <path d=\"M7.4249 14.8499L6.8999 14.2874L7.1999 14.0999L7.4624 13.8374L7.4249 13.7624L7.5374 13.6499L7.6124 13.7249L7.5374 13.7999L7.5749 13.8374L7.6499 13.7624L7.7249 13.8374L7.6499 13.8749L7.7249 13.9499L7.7624 13.8749L7.8374 13.9499L7.7624 14.0249L7.8374 14.0624L7.8749 13.9874L7.9499 14.0624L7.8749 14.1374L7.9499 14.1749L7.9874 14.0999L8.0624 14.1749L7.9499 14.2874H7.9124L7.8749 14.2499L7.6124 14.5124L7.4249 14.8499Z\" fill=\"#FFE62E\"/>\n <path d=\"M7.0874 14.4752L7.2374 14.4002C7.2749 14.3627 7.3124 14.3627 7.3499 14.4002C7.3874 14.4377 7.3874 14.4752 7.3499 14.5127L7.1999 14.6252L7.2374 14.6627L7.3499 14.5502C7.3874 14.5127 7.3874 14.4377 7.3499 14.4002C7.3124 14.3627 7.2374 14.3627 7.1999 14.4002L7.0874 14.4752Z\" fill=\"#3E4347\"/>\n <path d=\"M7.5749 14.1751C7.6124 14.1376 7.6874 14.1376 7.7249 14.1751C7.7624 14.2126 7.7624 14.2876 7.7249 14.3251L7.6124 14.4376L7.4624 14.2876L7.5749 14.1751ZM7.6874 14.2876C7.7249 14.2501 7.7249 14.2126 7.6874 14.1751C7.6499 14.1376 7.6124 14.1376 7.5749 14.1751L7.4999 14.2876L7.6124 14.4001L7.6874 14.2876Z\" fill=\"#3E4347\"/>\n <path d=\"M7.3874 13.9876C7.4249 13.9501 7.4999 13.9501 7.5374 13.9876C7.5749 14.0251 7.5749 14.1001 7.5374 14.1376L7.4249 14.2501L7.2749 14.1001L7.3874 13.9876ZM7.5374 14.1001C7.5749 14.0626 7.5749 14.0251 7.5374 13.9876C7.4999 13.9501 7.4624 13.9501 7.4249 13.9876L7.3124 14.1001L7.4249 14.2126L7.5374 14.1001Z\" fill=\"#3E4347\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryPRTIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryDOMIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props}>\n <path d=\"M14.25 0.975098V9.7501H23.025C22.125 5.3251 18.675 1.8751 14.25 0.975098Z\" fill=\"#C94747\"/>\n <path d=\"M9.7501 23.025V14.25H0.975098C1.8751 18.675 5.3251 22.125 9.7501 23.025Z\" fill=\"#C94747\"/>\n <path d=\"M14.25 14.25V23.025C18.675 22.125 22.125 18.675 23.025 14.25H14.25Z\" fill=\"#2A5F9E\"/>\n <path d=\"M0.975098 9.7501H9.7501V0.975098C5.3251 1.8751 1.8751 5.3251 0.975098 9.7501Z\" fill=\"#2A5F9E\"/>\n <path d=\"M23.025 9.75H14.25V0.975C13.5375 0.825 12.7875 0.75 12 0.75C11.2125 0.75 10.4625 0.825 9.75 0.975V9.75H0.975C0.825 10.4625 0.75 11.2125 0.75 12C0.75 12.7875 0.825 13.5375 0.975 14.25H9.75V23.025C10.4625 23.175 11.2125 23.25 12 23.25C12.7875 23.25 13.5375 23.175 14.25 23.025V14.25H23.025C23.175 13.5375 23.25 12.7875 23.25 12C23.25 11.2125 23.175 10.4625 23.025 9.75Z\" fill=\"#F9F9F9\"/>\n <path d=\"M10.875 10.9875C10.875 10.9875 10.725 10.95 10.575 10.95C10.6875 10.8 10.725 10.5 10.725 10.5C10.725 10.5 10.4625 10.65 10.3875 10.8C10.35 10.6875 10.2375 10.575 10.2375 10.575C10.2375 10.575 10.125 10.725 10.125 10.8375C10.125 10.95 10.3125 11.1375 10.3125 11.1375C10.3125 11.1375 10.5375 11.2125 10.6875 11.175C10.8 11.175 10.875 10.9875 10.875 10.9875Z\" fill=\"#699635\"/>\n <path d=\"M10.6501 11.3627C10.6501 11.3627 10.5001 11.3627 10.3501 11.4002C10.3876 11.2127 10.3501 10.9502 10.3501 10.9502C10.3501 10.9502 10.1626 11.1377 10.0876 11.3252L9.90005 11.1377C9.90005 11.1377 9.82505 11.2877 9.86255 11.4002C9.90005 11.5127 10.1251 11.6627 10.1251 11.6627C10.1251 11.6627 10.3876 11.6627 10.5001 11.5877C10.6126 11.5502 10.6501 11.3627 10.6501 11.3627Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.5375 11.775C10.5375 11.775 10.3875 11.8125 10.275 11.8875C10.275 11.7 10.1625 11.4375 10.1625 11.4375C10.1625 11.4375 10.0125 11.7 10.0125 11.85C9.89995 11.775 9.78745 11.7375 9.78745 11.7375C9.78745 11.7375 9.74995 11.925 9.82495 12C9.89995 12.1125 10.125 12.1875 10.125 12.1875C10.125 12.1875 10.35 12.1125 10.4625 12.0375C10.5375 11.925 10.5375 11.775 10.5375 11.775Z\" fill=\"#699635\"/>\n <path d=\"M10.5 12.1873C10.5 12.1873 10.35 12.2623 10.275 12.3373C10.2375 12.1498 10.05 11.9248 10.05 11.9248C10.05 11.9248 9.975 12.1873 10.0125 12.3748C9.9 12.3748 9.75 12.3373 9.75 12.3373C9.75 12.3373 9.75 12.5248 9.8625 12.5998C9.975 12.6748 10.2 12.7123 10.2 12.7123C10.2 12.7123 10.425 12.5998 10.4625 12.4873C10.575 12.3748 10.5 12.1873 10.5 12.1873Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.6125 12.5998C10.6125 12.5998 10.5 12.7123 10.425 12.8248C10.35 12.6748 10.125 12.4873 10.125 12.4873C10.125 12.4873 10.125 12.7873 10.2 12.9373H9.9375C9.9375 12.9373 9.975 13.0873 10.125 13.1623C10.2375 13.1998 10.5 13.1623 10.5 13.1623C10.5 13.1623 10.6875 12.9748 10.725 12.8623C10.6875 12.7498 10.6125 12.5998 10.6125 12.5998Z\" fill=\"#699635\"/>\n <path d=\"M10.8 12.9751C10.8 12.9751 10.725 13.1251 10.6875 13.2376C10.575 13.0876 10.3125 13.0126 10.3125 13.0126C10.3125 13.0126 10.3875 13.2751 10.5 13.4251C10.3875 13.4626 10.2375 13.5001 10.2375 13.5001C10.2375 13.5001 10.35 13.6501 10.4625 13.6501C10.575 13.6501 10.8 13.5751 10.8 13.5751C10.8 13.5751 10.9125 13.3501 10.9125 13.2376C10.95 13.0876 10.8 12.9751 10.8 12.9751Z\" fill=\"#83BF4F\"/>\n <path d=\"M11.1 13.3125C11.1 13.3125 11.0625 13.4625 11.0625 13.575C10.9125 13.4625 10.6125 13.4625 10.6125 13.4625C10.6125 13.4625 10.7625 13.6875 10.9125 13.8C10.8 13.8375 10.6875 13.95 10.6875 13.95C10.6875 13.95 10.8375 14.0625 10.95 14.0625C11.0625 14.0625 11.25 13.875 11.25 13.875C11.25 13.875 11.325 13.65 11.2875 13.5C11.25 13.3875 11.1 13.3125 11.1 13.3125Z\" fill=\"#699635\"/>\n <path d=\"M11.475 13.5376C11.475 13.5376 11.475 13.6876 11.5125 13.8376C11.325 13.8001 11.0625 13.8376 11.0625 13.8376C11.0625 13.8376 11.25 14.0251 11.4375 14.1001L11.25 14.2876C11.25 14.2876 11.4 14.3626 11.5125 14.3251C11.625 14.2876 11.775 14.0626 11.775 14.0626C11.775 14.0626 11.775 13.8001 11.7 13.7251C11.625 13.6501 11.475 13.5376 11.475 13.5376Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.1626 10.9875C13.1626 10.9875 13.3126 10.95 13.4626 10.95C13.3501 10.8 13.3126 10.5 13.3126 10.5C13.3126 10.5 13.5751 10.65 13.6501 10.8C13.6876 10.6875 13.8001 10.575 13.8001 10.575C13.8001 10.575 13.9126 10.6875 13.9126 10.8375C13.9126 10.95 13.7251 11.1375 13.7251 11.1375C13.7251 11.1375 13.5001 11.2125 13.3501 11.175C13.2001 11.1375 13.1626 10.9875 13.1626 10.9875Z\" fill=\"#699635\"/>\n <path d=\"M13.3875 11.3627C13.3875 11.3627 13.5375 11.3627 13.6875 11.4002C13.6125 11.2127 13.6875 10.9502 13.6875 10.9502C13.6875 10.9502 13.875 11.1377 13.95 11.3252L14.1375 11.1377C14.1375 11.1377 14.2124 11.2877 14.1749 11.4002C14.1374 11.5127 13.9124 11.6627 13.9124 11.6627C13.9124 11.6627 13.6499 11.6627 13.5375 11.5877C13.425 11.5502 13.3875 11.3627 13.3875 11.3627Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.5 11.775C13.5 11.775 13.65 11.8125 13.7625 11.8875C13.7625 11.7 13.875 11.4375 13.875 11.4375C13.875 11.4375 14.025 11.7 14.025 11.85C14.1375 11.775 14.25 11.7375 14.25 11.7375C14.25 11.7375 14.2875 11.925 14.2125 12C14.1375 12.1125 13.9125 12.1875 13.9125 12.1875C13.9125 12.1875 13.6875 12.1125 13.575 12.0375C13.5 11.925 13.5 11.775 13.5 11.775Z\" fill=\"#699635\"/>\n <path d=\"M13.5374 12.1873C13.5374 12.1873 13.6874 12.2623 13.7624 12.3373C13.7999 12.1498 13.9874 11.9248 13.9874 11.9248C13.9874 11.9248 14.0624 12.1873 14.0249 12.3748C14.1374 12.3373 14.2874 12.3373 14.2874 12.3373C14.2874 12.3373 14.2874 12.5248 14.1749 12.5998C14.0624 12.6748 13.8374 12.7123 13.8374 12.7123C13.8374 12.7123 13.6124 12.5998 13.5749 12.4873C13.4624 12.3748 13.5374 12.1873 13.5374 12.1873Z\" fill=\"#83BF4F\"/>\n <path d=\"M13.4249 12.5998C13.4249 12.5998 13.5374 12.7123 13.6124 12.8248C13.6874 12.6748 13.9124 12.4873 13.9124 12.4873C13.9124 12.4873 13.9124 12.7873 13.8374 12.9373H14.0999C14.0999 12.9373 14.0624 13.0873 13.9124 13.1623C13.7999 13.1998 13.5374 13.1623 13.5374 13.1623C13.5374 13.1623 13.3499 12.9748 13.3124 12.8623C13.2749 12.7498 13.4249 12.5998 13.4249 12.5998Z\" fill=\"#699635\"/>\n <path d=\"M13.2374 12.9751C13.2374 12.9751 13.3124 13.1251 13.3499 13.2376C13.4624 13.0876 13.7249 13.0126 13.7249 13.0126C13.7249 13.0126 13.6499 13.2751 13.5374 13.4251C13.6499 13.4626 13.7999 13.5001 13.7999 13.5001C13.7999 13.5001 13.6874 13.6501 13.5749 13.6501C13.4624 13.6501 13.2374 13.5751 13.2374 13.5751C13.2374 13.5751 13.1249 13.3501 13.1249 13.2376C13.0874 13.0876 13.2374 12.9751 13.2374 12.9751Z\" fill=\"#83BF4F\"/>\n <path d=\"M12.9375 13.3125C12.9375 13.3125 12.975 13.4625 12.975 13.575C13.125 13.4625 13.425 13.4625 13.425 13.4625C13.425 13.4625 13.275 13.6875 13.125 13.8C13.2375 13.8375 13.35 13.95 13.35 13.95C13.35 13.95 13.2 14.0625 13.0875 14.0625C12.975 14.0625 12.7875 13.875 12.7875 13.875C12.7875 13.875 12.7125 13.65 12.75 13.5C12.7875 13.3875 12.9375 13.3125 12.9375 13.3125Z\" fill=\"#699635\"/>\n <path d=\"M12.5625 13.5376C12.5625 13.5376 12.5625 13.6876 12.525 13.8376C12.7125 13.8001 12.9749 13.8376 12.9749 13.8376C12.9749 13.8376 12.7874 14.0251 12.6 14.1001L12.7874 14.2876C12.7874 14.2876 12.6375 14.3626 12.525 14.3251C12.4125 14.2876 12.2625 14.0626 12.2625 14.0626C12.2625 14.0626 12.2625 13.8001 12.3375 13.7251C12.4125 13.5376 12.5625 13.5376 12.5625 13.5376Z\" fill=\"#83BF4F\"/>\n <path d=\"M10.875 10.9123V12.7123C10.875 12.8623 10.875 12.9748 10.95 13.0873C11.025 13.1623 11.1 13.2373 11.2125 13.2748H11.6625C11.8875 13.2748 11.8875 13.3123 11.9625 13.4248C12.0375 13.2748 12.15 13.2748 12.3375 13.2748H12.7125C12.825 13.2373 12.9 13.1998 12.9375 13.1248C13.05 13.0123 13.05 12.8623 13.05 12.7123V10.9873C13.05 10.9123 13.05 10.9123 13.0875 10.8748L13.3499 10.6123H10.575L10.875 10.9123Z\" fill=\"white\"/>\n <path d=\"M11.7375 11.6998V10.6123H10.6125L10.9125 10.9123V11.6998H11.7375Z\" fill=\"#002D62\"/>\n <path d=\"M12.2251 11.6998V10.6123H13.3876L13.0876 10.9123V11.6998H12.2251Z\" fill=\"#CE1126\"/>\n <path d=\"M11.7375 12.1499H10.875V12.8624C10.9125 13.1624 11.1375 13.2749 11.325 13.2749H11.7375V12.1499Z\" fill=\"#CE1126\"/>\n <path d=\"M12.2249 12.1504H13.0874V12.8629C13.0499 13.1629 12.8249 13.2754 12.6374 13.2754H12.2249V12.1504Z\" fill=\"#002D62\"/>\n <path d=\"M11.325 9.71266C10.9875 9.71266 10.6125 9.78766 10.35 9.97516C10.2 10.0502 10.2 10.0877 10.275 10.2377L10.0875 10.3127C9.97495 10.3502 9.86245 10.3877 9.74995 10.4627C9.67495 10.5002 9.67495 10.5377 9.63745 10.5752L9.89995 10.5377L9.86245 10.6127C9.82495 10.6877 9.78745 10.7252 9.74995 10.8002C9.82495 10.7627 9.89995 10.6877 9.97495 10.6502C10.1625 10.5377 10.5375 10.5377 10.6875 10.3877C10.725 10.3502 10.6875 10.3127 10.6875 10.2377C10.8 10.2002 10.8375 10.1627 10.95 10.1627C11.2875 10.0877 11.475 10.1627 11.625 10.1252C11.6625 10.1252 11.7375 10.0877 11.7375 10.0502L11.7 9.90016H12.225C12.225 9.97516 12.15 10.1252 12.3 10.1627C12.45 10.2002 12.75 10.1252 12.975 10.2002L13.2375 10.2752L13.2 10.3502V10.4252C13.2375 10.4627 13.275 10.5002 13.3125 10.5002C13.3875 10.5377 13.5 10.5752 13.6125 10.6127C13.9125 10.6877 13.95 10.6877 14.175 10.8377C14.175 10.8002 14.0625 10.6502 14.025 10.5752L14.2874 10.6127C14.2499 10.5377 14.1 10.4627 14.025 10.4252L13.6875 10.3127C13.725 10.2377 13.7625 10.2002 13.7249 10.1627C13.6874 10.0877 13.3875 9.93766 13.3125 9.93766C13.2 9.90016 13.05 9.86266 12.9375 9.86266C12.825 9.82516 12.6 9.82516 12.6 9.82516C12.6 9.82516 12.6375 9.71266 12.5625 9.63766C12.525 9.60016 12.45 9.60016 12.375 9.60016C12.1125 9.56266 11.775 9.60016 11.5125 9.60016C11.4375 9.60016 11.4 9.60016 11.325 9.63766V9.71266Z\" fill=\"#002D62\"/>\n <path d=\"M10.8749 13.8C10.7249 13.8375 10.6499 13.875 10.4999 13.95C10.4624 13.875 10.3874 13.7625 10.3124 13.6875L10.1999 13.575C10.1249 13.5375 10.0874 13.5375 10.0499 13.575L10.0124 13.5C9.9374 13.3875 9.8624 13.3125 9.7874 13.2375L9.7499 13.2L9.7124 13.1625C9.7499 13.275 9.7499 13.35 9.7874 13.4625C9.7499 13.425 9.7124 13.425 9.6749 13.3875C9.6374 13.3875 9.5624 13.35 9.5249 13.35L9.5624 13.3875C9.6374 13.4625 9.7124 13.575 9.7499 13.6875C9.7874 13.8 9.8624 13.95 9.9749 14.025C9.9749 14.025 10.0499 14.1 10.0874 14.1C10.1999 14.1375 10.1999 14.1 10.2374 14.0625C10.3124 14.2125 10.3499 14.25 10.4624 14.3625C10.5749 14.475 10.7249 14.475 10.8374 14.475C10.9124 14.475 10.9499 14.4375 10.9874 14.4C11.1749 14.2875 11.0624 14.2125 11.0624 14.1375C11.1374 14.1375 11.3624 14.0625 11.4374 14.025C11.7374 13.9875 12.2624 13.95 12.5999 14.025C12.6374 14.025 12.9749 14.1375 13.0124 14.1375C12.9749 14.2125 12.9749 14.2125 12.9749 14.2875C12.9749 14.3625 13.0499 14.3625 13.0874 14.4C13.1249 14.4375 13.1624 14.4375 13.2374 14.475H13.4249C13.5374 14.4375 13.6124 14.3625 13.6874 14.325C13.7624 14.2125 13.7999 14.1375 13.8749 14.0625L13.9124 14.1H13.9874C14.0249 14.1 14.0624 14.0625 14.0999 14.025C14.2124 13.95 14.2874 13.8 14.3249 13.6875C14.3624 13.5375 14.4374 13.4625 14.5499 13.35C14.3999 13.35 14.3624 13.3875 14.2874 13.425L14.3249 13.275C14.3249 13.2375 14.3624 13.1625 14.3624 13.125C14.2874 13.2 14.2499 13.275 14.1749 13.35C14.1374 13.3875 14.0999 13.425 14.0999 13.4625C14.0249 13.5375 14.0624 13.5375 14.0249 13.575C13.8374 13.4625 13.7249 13.725 13.5749 13.9125C13.3124 13.7625 13.0874 13.725 12.7874 13.65C12.7124 13.65 12.6749 13.65 12.5999 13.6125C12.2249 13.575 11.8124 13.575 11.4374 13.6125C11.1749 13.725 11.0249 13.7625 10.8749 13.8Z\" fill=\"#CE1126\"/>\n <path d=\"M11.8875 10.5376V10.7626H11.625V10.9876H11.8875V11.8876H12.1125V10.9876H12.3375V10.7626H12.1125V10.5376H11.8875Z\" fill=\"#EAC102\"/>\n <path d=\"M11.2124 12.0751L12.2249 11.4751L12.7874 12.2626L11.6999 12.9751L11.2124 12.0751Z\" fill=\"#201B18\"/>\n <path d=\"M11.325 11.8874L12.1875 11.3999L12.6375 12.0374L11.7375 12.6374L11.325 11.8874Z\" fill=\"#C9C9C9\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryDOMIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryPRYIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z\" fill=\"#F0F0F0\"/>\n <path d=\"M12 0C7.24242 0 3.13167 2.76867 1.19067 6.78263H22.8092C20.8682 2.76867 16.7574 0 12 0Z\" fill=\"#0052B4\"/>\n <path d=\"M12 23.9999C16.7574 23.9999 20.8682 21.2312 22.8092 17.2173H1.19067C3.13167 21.2312 7.24242 23.9999 12 23.9999Z\" fill=\"#0052B4\"/>\n <path d=\"M9.59009 12.5215L11.9999 8.34766L14.4098 12.5215H9.59009Z\" fill=\"#FFDA44\"/>\n <path d=\"M15.1305 13.8999L12.0001 15.4652L8.86963 13.8999V11.813H15.1305V13.8999Z\" fill=\"#6DA544\"/>\n <path d=\"M14.9514 8.52686L13.8446 9.63362C14.3167 10.1057 14.6088 10.7579 14.6088 11.4782C14.6088 12.919 13.4408 14.0869 12.0001 14.0869C10.5594 14.0869 9.39138 12.9189 9.39138 11.4782C9.39138 10.7579 9.68341 10.1057 10.1555 9.63362L9.04872 8.52686C8.29333 9.28211 7.82617 10.3256 7.82617 11.4782C7.82617 13.7835 9.69489 15.6521 12.0001 15.6521C14.3052 15.6521 16.174 13.7834 16.174 11.4782C16.1739 10.3256 15.7068 9.28211 14.9514 8.52686Z\" fill=\"#FFDA44\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryPRYIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryTTOIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M20.4903 3.50972C17.0061 0.0254982 11.9199 -0.855569 7.59467 0.826468L23.1735 16.4053C24.8556 12.0801 23.9745 6.99394 20.4903 3.50972ZM3.50972 20.4903C6.99394 23.9745 12.0801 24.8556 16.4053 23.1735L0.826468 7.59467C-0.855569 11.9199 0.0254982 17.0061 3.50972 20.4903Z\" fill=\"#ED4C5C\"/>\n <path d=\"M3.50974 3.50974C2.70877 4.31071 2.06799 5.15173 1.54736 6.07284L17.9272 22.4527C18.8483 21.932 19.7294 21.2913 20.4903 20.4903C21.2913 19.6893 21.932 18.8483 22.4527 17.9272L6.07284 1.54736C5.15173 2.06799 4.27066 2.70877 3.50974 3.50974Z\" fill=\"#3E4347\"/>\n <path d=\"M1.14706 6.83345C1.02691 7.07374 0.906767 7.35408 0.786621 7.63442L16.4055 23.1732C16.6859 23.0531 16.9262 22.973 17.2065 22.8128C17.4468 22.6927 17.6871 22.5725 17.9274 22.4123L1.54754 6.07253C1.4274 6.31282 1.2672 6.55311 1.14706 6.83345ZM7.59487 0.826172C7.31453 0.946317 7.07424 1.02641 6.7939 1.18661C6.55361 1.30675 6.31331 1.4269 6.07302 1.58709L22.4529 17.9669C22.573 17.7266 22.7332 17.4863 22.8533 17.2461C22.9735 16.9657 23.0936 16.7254 23.2138 16.4451L7.59487 0.826172Z\" fill=\"white\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryTTOIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryURYIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M23.1375 10.5H22.6125V8.25C22.2375 7.1625 21.675 6.15 21 5.25H18.75V3C16.875 1.575 14.55 0.75 12 0.75C5.775 0.75 0.75 5.775 0.75 12C0.75 12.525 0.7875 13.0125 0.8625 13.5H1.3875V15.75C1.7625 16.8375 2.325 17.85 3 18.75H5.25V21C7.125 22.425 9.45 23.25 12 23.25C14.55 23.25 16.875 22.425 18.75 21V18.75H21C21.675 17.85 22.2375 16.8375 22.6125 15.75V13.5H23.1375C23.2125 13.0125 23.25 12.525 23.25 12C23.25 11.475 23.2125 10.9875 23.1375 10.5Z\" fill=\"#F9F9F9\"/>\n <path d=\"M1.38755 15.75H22.6126C22.8751 15.0375 23.0626 14.2875 23.1376 13.5H0.862549C0.937549 14.2875 1.12505 15.0375 1.38755 15.75Z\" fill=\"#428BC1\"/>\n <path d=\"M3 18.75C3.6375 19.6125 4.3875 20.3625 5.25 21H18.75C19.6125 20.3625 20.3625 19.6125 21 18.75H3Z\" fill=\"#428BC1\"/>\n <path d=\"M12 5.25H21C20.3625 4.3875 19.6125 3.6375 18.75 3H12V5.25Z\" fill=\"#428BC1\"/>\n <path d=\"M12 10.5H23.1375C23.025 9.7125 22.8375 8.9625 22.6125 8.25H12V10.5Z\" fill=\"#428BC1\"/>\n <path d=\"M6.26245 9.2998C6.26245 9.2623 6.26245 9.2998 6.26245 9.2998L5.73745 9.6748C5.43745 10.3873 5.54995 10.6873 5.58745 10.9498L5.32495 11.5873C6.33745 11.2498 5.47495 10.6498 6.86245 9.63731L6.52495 9.1123L6.26245 9.2998Z\" fill=\"#FCD116\"/>\n <path d=\"M5.9625 8.7374L5.6625 8.6999L5.0625 8.5874C4.35 8.8874 4.2 9.1874 4.05 9.3749L3.375 9.5999C4.3125 10.0874 4.125 9.0374 5.85 9.2999L5.9625 8.7374Z\" fill=\"#FCD116\"/>\n <path d=\"M5.325 8.36269L5.85 8.02519L5.6625 7.7627H5.7C5.7 7.7627 5.6625 7.76269 5.6625 7.72519L5.325 7.2002C4.6125 6.9002 4.3125 7.01269 4.05 7.05019L3.375 6.8252C3.7125 7.80019 4.3125 6.93769 5.325 8.36269Z\" fill=\"#FCD116\"/>\n <path d=\"M5.66239 7.2749L6.26239 7.3874L6.29989 7.0874L6.41239 6.4874C6.11239 5.7749 5.81239 5.6249 5.62489 5.4749L5.36239 4.8374C4.87489 5.7749 5.92489 5.5874 5.66239 7.2749Z\" fill=\"#FCD116\"/>\n <path d=\"M8.17495 4.875C7.16245 5.2125 8.02495 5.8125 6.63745 6.825L6.97495 7.35L7.76245 6.825C8.28745 5.55 7.57495 5.475 8.17495 4.875Z\" fill=\"#FCD116\"/>\n <path d=\"M7.61255 7.76239L7.91255 7.79989H7.87505H7.91255L8.51255 7.91239C9.22505 7.61239 9.37505 7.31239 9.52505 7.12489L10.1625 6.86239C9.22505 6.37489 9.41255 7.42489 7.68755 7.16239L7.61255 7.76239Z\" fill=\"#FCD116\"/>\n <path d=\"M8.2125 8.1377L7.6875 8.4752L7.875 8.73769H7.8375C7.8375 8.73769 7.875 8.73769 7.875 8.77519L8.2125 9.30019C8.925 9.60019 9.225 9.48769 9.4875 9.45019L10.125 9.71269C9.825 8.70019 9.225 9.56269 8.2125 8.1377Z\" fill=\"#FCD116\"/>\n <path d=\"M7.79995 9.1877L7.19995 9.0752L7.12495 9.37519V9.33769V9.37519L7.01245 9.9752C7.31245 10.6877 7.61245 10.8377 7.79995 10.9877L8.06245 11.6252C8.54995 10.6877 7.49995 10.8752 7.79995 9.1877Z\" fill=\"#FCD116\"/>\n <path d=\"M7.875 8.7375L10.5 8.25L7.875 7.7625L9.4125 5.5875L7.2375 7.125L6.75 4.5L6.2625 7.125L4.0875 5.5875L5.5875 7.7625L3 8.25L5.5875 8.7375L4.0875 10.9125L6.2625 9.4125L6.75 12L7.2375 9.4125L9.4125 10.9125L7.875 8.7375Z\" fill=\"#FCD116\"/>\n <path d=\"M6.75007 9.1123C6.67507 9.1123 6.56257 9.1498 6.75007 9.1123V9.1123Z\" fill=\"black\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryURYIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryVENIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 0.75C7.08745 0.75 2.92495 3.9 1.38745 8.25H22.6124C21.0749 3.9 16.9124 0.75 12 0.75Z\" fill=\"#FFE62E\"/>\n <path d=\"M12 23.25C16.9124 23.25 21.0749 20.1375 22.6124 15.75H1.38745C2.92495 20.1375 7.08745 23.25 12 23.25Z\" fill=\"#ED4C5C\"/>\n <path d=\"M1.3875 8.25C0.975 9.4125 0.75 10.6875 0.75 12C0.75 13.3125 0.975 14.5875 1.3875 15.75H22.6125C23.025 14.5875 23.25 13.3125 23.25 12C23.25 10.6875 23.025 9.4125 22.6125 8.25H1.3875Z\" fill=\"#2A5F9E\"/>\n <path d=\"M12.9749 10.1624L13.3499 10.5749L13.2749 10.0124L13.7624 9.7874L13.2374 9.6749L13.1624 9.1499L12.8999 9.6374L12.3374 9.5249L12.7124 9.9374L12.4499 10.4249L12.9749 10.1624Z\" fill=\"white\"/>\n <path d=\"M10.9499 10.1999L11.4374 10.4249L11.1749 9.9374L11.5499 9.5249L10.9874 9.6374L10.7249 9.1499L10.6499 9.7124L10.0874 9.7874L10.6124 10.0499L10.5749 10.5749L10.9499 10.1999Z\" fill=\"white\"/>\n <path d=\"M9.07495 10.8751L9.63745 10.9501L9.18745 10.5751L9.37495 10.0876L8.88745 10.3501L8.43745 9.9751L8.62495 10.5376L8.13745 10.8001L8.69995 10.8376L8.84995 11.4001L9.07495 10.8751Z\" fill=\"white\"/>\n <path d=\"M7.57505 12.1876L8.13755 12.0376L7.57505 11.8501V11.2876L7.23755 11.7376L6.67505 11.5501L7.01255 12.0001L6.71255 12.4126L7.23755 12.2626L7.61255 12.7126L7.57505 12.1876Z\" fill=\"white\"/>\n <path d=\"M6.7125 13.8748L7.1625 13.5373L6.5625 13.5748L6.375 13.0498L6.225 13.5748H5.625L6.1125 13.8748L5.9625 14.3998L6.4125 14.0623L6.9375 14.3623L6.7125 13.8748Z\" fill=\"white\"/>\n <path d=\"M17.2874 13.7997L17.0999 14.3247L17.5874 13.9872L18.0374 14.3247L17.8874 13.7997L18.3749 13.4997H17.7749L17.6249 13.0122L17.4374 13.4997H16.8374L17.2874 13.7997Z\" fill=\"white\"/>\n <path d=\"M16.35 12.1125L16.3875 12.6375L16.725 12.225L17.25 12.3375L16.9124 11.925L17.25 11.475L16.725 11.6625L16.35 11.25V11.775L15.825 11.9625L16.35 12.1125Z\" fill=\"white\"/>\n <path d=\"M14.8501 10.8375L15.0751 11.3625L15.2251 10.8L15.7876 10.7625L15.3001 10.5L15.4501 9.9375L15.0001 10.3125L14.5126 10.05L14.7376 10.5375L14.2876 10.9125L14.8501 10.8375Z\" fill=\"white\"/>\n </SvgIcon>\n )\n};\n\nexport default CountryVENIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryCUBIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <g clip-path=\"url(#clip0_27973_194969)\">\n <rect x=\"0.554688\" y=\"1\" width=\"31.5\" height=\"23.5\" rx=\"1.75\" fill=\"white\" stroke=\"#F5F5F5\" stroke-width=\"0.5\" />\n <mask id=\"mask0_27973_194969\" style={{maskType: \"luminance\"}} maskUnits=\"userSpaceOnUse\" x=\"0\" y=\"0\" width=\"33\" height=\"25\">\n <rect x=\"0.554688\" y=\"1\" width=\"31.5\" height=\"23.5\" rx=\"1.75\" fill=\"white\" stroke=\"white\" stroke-width=\"0.5\" />\n </mask>\n <g mask=\"url(#mask0_27973_194969)\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M0.304688 5.55H32.3047V0.75H0.304688V5.55Z\" fill=\"#2A5F9E\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M0.304688 15.1516H32.3047V10.3516H0.304688V15.1516Z\" fill=\"#2A5F9E\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M0.304688 24.7531H32.3047V19.9531H0.304688V24.7531Z\" fill=\"#2A5F9E\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M0.304688 0.75L15.5428 12.75L0.304688 24.75V0.75Z\" fill=\"#ED4C5C\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M5.64137 13.9741L3.85002 15.3357L4.52979 13.1261L2.74291 11.758L4.95437 11.754L5.64137 9.54688L6.32836 11.754L8.53983 11.758L6.75295 13.1261L7.43271 15.3357L5.64137 13.9741Z\" fill=\"white\" />\n </g>\n </g>\n <defs>\n <clipPath id=\"clip0_27973_194969\">\n <rect x=\"0.304688\" y=\"0.75\" width=\"24\" height=\"24\" rx=\"12\" fill=\"white\" />\n </clipPath>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountryCUBIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryAUSIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <g clip-path=\"url(#clip0_27973_194967)\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" rx=\"2\" fill=\"white\" />\n <mask id=\"mask0_27973_194967\" style={{maskType: \"luminance\"}} maskUnits=\"userSpaceOnUse\" x=\"-4\" y=\"0\" width=\"33\" height=\"25\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" rx=\"2\" fill=\"white\" />\n </mask>\n <g mask=\"url(#mask0_27973_194967)\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" fill=\"#2A5F9E\" />\n <path d=\"M-3.69531 0.416667H-4.56397L-3.9183 0.997765L1.30469 5.69845V6.98333L-3.89531 10.8833L-4.02865 10.9833V11.15V11.95V12.5675L-3.51243 12.2287L2.49953 8.28333H3.81262L8.98794 12.1648C9.09051 12.2418 9.21527 12.2833 9.34347 12.2833C9.88654 12.2833 10.1435 11.6136 9.73987 11.2503L5.01897 7.00155V5.71667L10.0856 1.91667C10.2535 1.79076 10.3523 1.59317 10.3523 1.38333V0.75V0.132549L9.83609 0.471317L3.82413 4.41667H2.51104L-2.73341 0.483333L-2.8223 0.416667H-2.93341H-3.69531Z\" fill=\"#FF2E3B\" stroke=\"white\" stroke-width=\"0.666667\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M-3.69531 4.75V7.95H1.63802V12.0833C1.63802 12.4515 1.9365 12.75 2.30469 12.75H4.01897C4.38716 12.75 4.68564 12.4515 4.68564 12.0833V7.95H10.1142C10.4824 7.95 10.7809 7.65152 10.7809 7.28333V5.41667C10.7809 5.04848 10.4824 4.75 10.1142 4.75H4.68564V0.75H1.63802V4.75H-3.69531Z\" fill=\"url(#paint0_linear_27973_194967)\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M-3.69531 5.55H2.39993V4.75V0.75H3.92374V4.75V5.55H10.019V7.15H3.92374V7.95V11.95H2.39993V7.95V7.15H-3.69531V5.55Z\" fill=\"url(#paint1_linear_27973_194967)\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M3.16071 20.35L1.81721 21.0916L2.07379 19.5208L0.986871 18.4084L2.48896 18.1792L3.16071 16.75L3.83247 18.1792L5.33456 18.4084L4.24764 19.5208L4.50422 21.0916L3.16071 20.35Z\" fill=\"white\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M19.1644 21.5484L18.0869 21.8798L18.4025 20.7484L18.0869 19.6171L19.1644 19.9484L20.2419 19.6171L19.9263 20.7484L20.2419 21.8798L19.1644 21.5484Z\" fill=\"white\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M19.1644 6.35313L18.0869 6.6845L18.4025 5.55313L18.0869 4.42175L19.1644 4.75313L20.2419 4.42175L19.9263 5.55313L20.2419 6.6845L19.1644 6.35313Z\" fill=\"white\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M23.7347 11.15L22.6573 11.4814L22.9728 10.35L22.6573 9.21863L23.7347 9.55L24.8122 9.21863L24.4967 10.35L24.8122 11.4814L23.7347 11.15Z\" fill=\"white\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M14.5941 12.7516L13.5166 13.0829L13.8322 11.9516L13.5166 10.8202L14.5941 11.1516L15.6716 10.8202L15.356 11.9516L15.6716 13.0829L14.5941 12.7516Z\" fill=\"white\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M21.4494 14.7469L20.9107 14.9126L21.0685 14.3469L20.9107 13.7812L21.4494 13.9469L21.9882 13.7812L21.8304 14.3469L21.9882 14.9126L21.4494 14.7469Z\" fill=\"white\" />\n </g>\n </g>\n <defs>\n <linearGradient id=\"paint0_linear_27973_194967\" x1=\"-3.69531\" y1=\"0.75\" x2=\"-3.69531\" y2=\"12.75\" gradientUnits=\"userSpaceOnUse\">\n <stop stop-color=\"white\" />\n <stop offset=\"1\" stop-color=\"#F0F0F0\" />\n </linearGradient>\n <linearGradient id=\"paint1_linear_27973_194967\" x1=\"-3.69531\" y1=\"0.75\" x2=\"-3.69531\" y2=\"11.95\" gradientUnits=\"userSpaceOnUse\">\n <stop stop-color=\"#ED4C5C\" />\n <stop offset=\"1\" stop-color=\"#FC0D1B\" />\n </linearGradient>\n <clipPath id=\"clip0_27973_194967\">\n <rect x=\"0.304688\" y=\"0.75\" width=\"24\" height=\"24\" rx=\"12\" fill=\"white\" />\n </clipPath>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountryAUSIcon;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryBELIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <g clip-path=\"url(#clip0_27973_194977)\">\n <g clip-path=\"url(#clip1_27973_194977)\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" rx=\"2\" fill=\"white\" />\n <mask id=\"mask0_27973_194977\" style={{maskType: \"luminance\"}} maskUnits=\"userSpaceOnUse\" x=\"-4\" y=\"0\" width=\"33\" height=\"25\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" rx=\"2\" fill=\"white\" />\n </mask>\n <g mask=\"url(#mask0_27973_194977)\">\n <rect x=\"11.5391\" y=\"0.75\" width=\"16.7619\" height=\"24\" fill=\"#ED4C5C\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M-3.69531 24.75H6.97135V0.75H-3.69531V24.75Z\" fill=\"#262626\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M6.96875 24.75H17.6354V0.75H6.96875V24.75Z\" fill=\"#FFCF3C\" />\n </g>\n </g>\n </g>\n <defs>\n <clipPath id=\"clip0_27973_194977\">\n <rect x=\"0.304688\" y=\"0.75\" width=\"24\" height=\"24\" rx=\"12\" fill=\"white\" />\n </clipPath>\n <clipPath id=\"clip1_27973_194977\">\n <rect width=\"32\" height=\"24\" fill=\"white\" transform=\"translate(-3.69531 0.75)\" />\n </clipPath>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountryBELIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryNORIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <g clip-path=\"url(#clip0_27973_194973)\">\n <rect x=\"-3.44531\" y=\"1\" width=\"31.5\" height=\"23.5\" rx=\"1.75\" fill=\"white\" stroke=\"#F5F5F5\" stroke-width=\"0.5\" />\n <mask id=\"mask0_27973_194973\" style={{maskType: \"luminance\"}} maskUnits=\"userSpaceOnUse\" x=\"-4\" y=\"0\" width=\"33\" height=\"25\">\n <rect x=\"-3.44531\" y=\"1\" width=\"31.5\" height=\"23.5\" rx=\"1.75\" fill=\"white\" stroke=\"white\" stroke-width=\"0.5\" />\n </mask>\n <g mask=\"url(#mask0_27973_194973)\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M5.44755 0.75H-3.69531V10.35H5.44755V0.75ZM10.019 0.75V10.35H28.3047V0.75H10.019ZM28.3047 15.15H10.019V24.75H28.3047V15.15ZM5.44755 24.75V15.15H-3.69531V24.75H5.44755Z\" fill=\"#ED4C5C\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M-3.69531 13.55H6.97135V24.75H8.49516V13.55H28.3047V11.95H8.49516V0.75H6.97135V11.95H-3.69531V13.55Z\" fill=\"#0A3A85\" />\n </g>\n </g>\n <defs>\n <clipPath id=\"clip0_27973_194973\">\n <rect x=\"0.304688\" y=\"0.75\" width=\"24\" height=\"24\" rx=\"12\" fill=\"white\" />\n </clipPath>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountryNORIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountryPRIIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <g clip-path=\"url(#clip0_27973_194971)\">\n <rect x=\"0.554688\" y=\"1\" width=\"31.5\" height=\"23.5\" rx=\"1.75\" fill=\"white\" stroke=\"#F5F5F5\" stroke-width=\"0.5\" />\n <mask id=\"mask0_27973_194971\" style={{maskType: \"luminance\"}} maskUnits=\"userSpaceOnUse\" x=\"0\" y=\"0\" width=\"33\" height=\"25\">\n <rect x=\"0.554688\" y=\"1\" width=\"31.5\" height=\"23.5\" rx=\"1.75\" fill=\"white\" stroke=\"white\" stroke-width=\"0.5\" />\n </mask>\n <g mask=\"url(#mask0_27973_194971)\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M0.304688 0.75H32.3047V5.55H0.304688V0.75ZM0.304688 10.35H32.3047V15.15H0.304688V10.35ZM0.304688 19.95V24.75H32.3047V19.95H0.304688Z\" fill=\"#ED4C5C\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M0.304688 0.75L15.5428 12.75L0.304688 24.75V0.75Z\" fill=\"#2A5F9E\" />\n <g filter=\"url(#filter0_d_27973_194971)\">\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M5.63765 14.2789L3.39847 15.9861L4.25282 13.2225L2.01458 11.5139L4.78178 11.5131L5.63765 8.75L6.49352 11.5131L9.26072 11.5139L7.02247 13.2225L7.87683 15.9861L5.63765 14.2789Z\" fill=\"url(#paint0_linear_27973_194971)\" />\n </g>\n </g>\n </g>\n <defs>\n <filter id=\"filter0_d_27973_194971\" x=\"2.01562\" y=\"8.75\" width=\"7.24219\" height=\"8.23438\" filterUnits=\"userSpaceOnUse\" color-interpolation-filters=\"sRGB\">\n <feFlood flood-opacity=\"0\" result=\"BackgroundImageFix\" />\n <feColorMatrix in=\"SourceAlpha\" type=\"matrix\" values=\"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0\" result=\"hardAlpha\" />\n <feOffset dy=\"1\" />\n <feColorMatrix type=\"matrix\" values=\"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.06 0\" />\n <feBlend mode=\"normal\" in2=\"BackgroundImageFix\" result=\"effect1_dropShadow_27973_194971\" />\n <feBlend mode=\"normal\" in=\"SourceGraphic\" in2=\"effect1_dropShadow_27973_194971\" result=\"shape\" />\n </filter>\n <linearGradient id=\"paint0_linear_27973_194971\" x1=\"1.82812\" y1=\"8.75\" x2=\"1.82812\" y2=\"16.75\" gradientUnits=\"userSpaceOnUse\">\n <stop stop-color=\"white\" />\n <stop offset=\"1\" stop-color=\"#F0F0F0\" />\n </linearGradient>\n <clipPath id=\"clip0_27973_194971\">\n <rect x=\"0.304688\" y=\"0.75\" width=\"24\" height=\"24\" rx=\"12\" fill=\"white\" />\n </clipPath>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountryPRIIcon;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst CountrySWEIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <g clip-path=\"url(#clip0_27973_194975)\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" rx=\"2\" fill=\"white\" />\n <mask id=\"mask0_27973_194975\" style={{maskType: \"luminance\"}} maskUnits=\"userSpaceOnUse\" x=\"-4\" y=\"0\" width=\"33\" height=\"25\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" rx=\"2\" fill=\"white\" />\n </mask>\n <g mask=\"url(#mask0_27973_194975)\">\n <rect x=\"-3.69531\" y=\"0.75\" width=\"32\" height=\"24\" fill=\"#006AA7\" />\n <path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M-3.69531 15.15H5.44755V24.75H10.019V15.15H28.3047V10.35H10.019V0.75H5.44755V10.35H-3.69531V15.15Z\" fill=\"#FFD34D\" />\n </g>\n </g>\n <defs>\n <clipPath id=\"clip0_27973_194975\">\n <rect x=\"0.304688\" y=\"0.75\" width=\"24\" height=\"24\" rx=\"12\" fill=\"white\" />\n </clipPath>\n </defs>\n </SvgIcon>\n )\n};\n\nexport default CountrySWEIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function CountrySVKIcon(props: any) {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M9.51953 11.0856L9.82028 11.3931L9.94928 11.0418L9.99241 10.822C9.94928 10.207 9.99241 9.592 9.99241 9.592L10.0787 9.68012L9.73441 9.32875L9.51953 9.10938V11.0856Z\" fill=\"#034EA2\"/>\n <path d=\"M9.99219 10.8159L10.2929 9.89344L9.99219 9.58594V10.8159Z\" fill=\"#ED1C24\"/>\n <path d=\"M9.52003 9.10928L9.73491 9.32865L8.70328 8.2749C8.66016 8.23065 8.66016 9.19703 8.66016 10.2512L9.52003 11.1294V9.10928Z\" fill=\"#FFDD00\"/>\n <path d=\"M9.8201 14.8142C9.0896 14.3751 9.00335 13.0135 9.00335 12.7937V10.4222L9.2186 10.642L8.1866 9.58786C8.10073 9.50011 8.1866 12.4424 8.1866 13.7162C8.1866 14.3312 8.5736 16.483 10.7231 15.385C10.7231 15.385 11.7979 14.9897 12.1417 14.5067H11.9269C11.8837 14.5506 11.8406 14.5506 11.7979 14.5506C10.551 15.4289 9.8201 14.8142 9.8201 14.8142Z\" fill=\"#FFDD00\"/>\n <path d=\"M9.00391 12.7964C9.00391 12.9722 9.09016 14.3339 9.77791 14.7726C9.77791 14.7726 10.5088 15.3876 11.7984 14.5533C11.4114 14.7291 11.1107 14.7291 10.8954 14.6849C10.2935 14.5094 9.64891 13.8066 9.56303 13.06C9.47678 12.3138 9.47678 10.9079 9.47678 10.9079L9.56303 10.996L9.21916 10.6446L9.00391 10.4688V12.7964Z\" fill=\"#034EA2\"/>\n <path d=\"M9.90653 11.8726V11.3015C9.77753 11.1703 9.94928 11.3458 9.60541 10.994L9.51953 10.9062V10.9505C9.51953 11.126 9.51953 12.3995 9.60578 13.0584C9.69166 13.805 10.3363 14.5077 10.9382 14.6832C11.153 14.7275 11.4542 14.7275 11.8408 14.552C11.8839 14.552 11.8839 14.5078 11.927 14.5078C10.766 14.3761 10.0355 13.322 9.90653 11.8726Z\" fill=\"#ED1C24\"/>\n <path d=\"M14.2042 14.8559C14.8923 14.4168 15.0213 13.0552 14.9782 12.8797V10.5078L14.7633 10.7276L15.795 9.67381C15.8812 9.58569 15.795 12.5283 15.795 13.8018C15.795 14.4168 15.408 16.5686 13.2585 15.4706C13.2585 15.4706 12.1837 15.0757 11.8398 14.5923H12.0551C12.0978 14.5923 12.141 14.6362 12.141 14.6362C13.4737 15.4709 14.2042 14.8559 14.2042 14.8559Z\" fill=\"#FFDD00\"/>\n <path d=\"M14.9781 12.8406C14.9781 13.0161 14.8918 14.3777 14.2041 14.8169C14.2041 14.8169 13.4736 15.4319 12.1836 14.5971C12.5706 14.773 12.8717 14.773 13.0866 14.7291C13.6885 14.5532 14.3331 13.8505 14.4193 13.1039C14.5052 12.3576 14.5052 10.9521 14.5052 10.9521L14.419 11.0399L14.7632 10.6885L14.9781 10.4688V12.8406Z\" fill=\"#034EA2\"/>\n <path d=\"M14.1185 11.9191V11.3484L14.4193 11.0409L14.5052 10.9531V10.997C14.5052 11.1725 14.5052 12.446 14.4189 13.1049C14.333 13.8515 13.7312 14.5542 13.0865 14.7736C12.8717 14.8179 12.5705 14.8179 12.1835 14.6424C12.1408 14.6424 12.1408 14.5981 12.0977 14.5981C13.2152 14.4226 13.9892 13.3685 14.1182 11.9191\" fill=\"#ED1C24\"/>\n <path d=\"M9.86328 11.6266C9.86328 13.1641 10.8383 14.4016 12.0008 14.4016C13.1633 14.4016 14.1383 13.1641 14.1383 11.6266C14.1383 10.0891 13.1633 8.85156 12.0008 8.85156C10.8383 8.85156 9.86328 10.1266 9.86328 11.6266Z\" fill=\"#8CDDEA\"/>\n <path d=\"M9.86328 11.7344C9.86328 13.2719 10.8383 14.5094 12.0008 14.5094C13.2008 14.5094 14.1383 13.2719 14.1383 11.7344H9.86328Z\" fill=\"#6DD337\"/>\n <path d=\"M9.9375 11.8152L13.9875 11.8902L14.025 11.5902C14.025 11.5527 14.1 11.5152 13.9875 11.5152C13.5375 11.4777 13.725 11.4402 13.4625 11.4402C13.3875 11.4402 11.6625 11.0277 11.5125 11.0277C11.3625 10.9902 10.0125 11.2152 10.0125 11.2152L9.9375 11.8152Z\" fill=\"#557176\"/>\n <path d=\"M9.89844 11.0983L10.5359 11.3608C10.5359 11.3608 11.3609 11.2108 11.4359 11.2483C11.5109 11.2858 12.2234 11.3983 12.2609 11.3983H13.3484H13.3109C13.2359 11.3608 12.4109 11.1358 12.3359 11.0983C12.2984 11.0608 11.6609 10.8358 11.6234 10.7608C11.5484 10.6858 11.0984 10.4233 11.0234 10.4233C10.9484 10.3858 9.89844 11.0983 9.89844 11.0983Z\" fill=\"white\"/>\n <path d=\"M12.8992 8.92656C12.8992 8.92656 12.4867 8.66406 11.9617 8.66406C11.5492 8.66406 11.1367 8.88906 11.1367 8.88906C10.6867 9.15156 10.3117 9.63906 10.0867 10.2391C9.93672 10.6516 9.82422 11.1391 9.82422 11.6266C9.82422 13.0891 10.6117 14.2141 11.6242 14.5141C11.6242 14.5141 11.7742 14.5891 11.9617 14.5891C12.1492 14.5891 12.3367 14.5516 12.3367 14.5516C13.3492 14.2891 14.1742 13.1266 14.1742 11.6641C14.1742 9.75156 12.7117 8.77656 12.8992 8.92656ZM12.3742 14.3641C12.3742 14.3641 12.1867 14.4016 11.9992 14.4016C11.8117 14.4016 11.6242 14.3641 11.6242 14.3641C10.7242 14.1016 10.0117 13.0141 10.0117 11.7016C10.0117 11.2516 10.1242 10.7641 10.2742 10.3891C10.4992 9.86406 10.8367 9.41406 11.2492 9.18906C11.2492 9.18906 11.6617 8.92656 11.9992 8.92656C12.4867 8.92656 12.8617 9.18906 12.8617 9.18906C13.5367 9.60156 14.0242 10.5766 14.0242 11.6641C13.9867 13.0141 13.2742 14.1391 12.3742 14.3641Z\" fill=\"#B1BABF\"/>\n <path d=\"M10.7242 11.7L11.3617 12.5625L10.3867 13.125C10.3867 13.125 10.4617 13.35 10.6492 13.6125C10.8367 13.8375 11.2867 14.325 11.6992 14.3625C12.1492 14.4 12.4492 14.4 12.7117 14.25C12.9367 14.1 13.2742 13.9125 13.4992 13.5375C13.7242 13.2 13.7242 13.125 13.7242 13.125C13.7242 13.125 12.2992 12.825 12.2617 12.825C12.2242 12.7875 10.8742 11.7375 10.8367 11.7C10.7992 11.6625 11.1367 11.25 11.1367 11.25L10.7242 11.7Z\" fill=\"#034EA2\"/>\n <path d=\"M11.6641 14.9219H12.3766V16.7594H11.6641V14.9219Z\" fill=\"#ED1C24\"/>\n <path d=\"M11.1016 15.0781H11.8141V16.9156H11.1016V15.0781Z\" fill=\"#034EA2\"/>\n <path d=\"M12.189 15.0781H12.9015V16.9156H12.189V15.0781Z\" fill=\"#034EA2\"/>\n <path d=\"M10.9492 15.0781H11.3992V17.4031H10.9492V15.0781Z\" fill=\"#FFDD00\"/>\n <path d=\"M12.5991 15.0781H13.0491V17.4031H12.5991V15.0781Z\" fill=\"#FFDD00\"/>\n <path d=\"M10.3125 14.2891H13.6875V15.1891H10.3125V14.2891Z\" fill=\"white\"/>\n <path d=\"M12.25 23.4981C18.4632 23.4981 23.5 18.4617 23.5 12.2491C23.5 6.03637 18.4632 1 12.25 1C6.0368 1 1 6.03637 1 12.2491C1 18.4617 6.0368 23.4981 12.25 23.4981Z\" fill=\"#F0F0F0\"/>\n <path d=\"M12.25 23.5C18.4632 23.5 23.5 18.4636 23.5 12.251C23.5 10.875 23.2525 9.55685 22.8003 8.33826H1.69974C1.24754 9.55685 1 10.875 1 12.251C1 18.4636 6.03684 23.5 12.25 23.5Z\" fill=\"#0052B4\"/>\n <path d=\"M12.2495 23.4963C17.0866 23.4963 21.2102 20.4436 22.7997 16.1599H1.69922C3.28876 20.4436 7.41237 23.4963 12.2495 23.4963Z\" fill=\"#D80027\"/>\n <path d=\"M3.90625 7.35693V12.9685C3.90625 16.1606 8.0767 17.1387 8.0767 17.1387C8.0767 17.1387 12.2471 16.1606 12.2471 12.9685V7.35693H3.90625Z\" fill=\"#F0F0F0\"/>\n <path d=\"M4.89062 7.35693V12.9685C4.89062 13.3433 4.97386 13.6972 5.13874 14.029H11.0268C11.1917 13.6972 11.275 13.3433 11.275 12.9685V7.35693H4.89062Z\" fill=\"#D80027\"/>\n <path d=\"M10.038 11.2728H8.57069V10.2946H9.54896V9.3164H8.57069V8.33826H7.59242V9.3164H6.6142V10.2946H7.59242V11.2728H6.125V12.251H7.59242V13.2291H8.57069V12.251H10.038V11.2728Z\" fill=\"#F0F0F0\"/>\n <path d=\"M6.46712 15.3973C7.09752 15.7934 7.74519 16.0234 8.07675 16.1257C8.40832 16.0235 9.05599 15.7934 9.68638 15.3973C10.3221 14.9978 10.7677 14.5409 11.0208 14.0318C10.7417 13.8344 10.4012 13.7179 10.0333 13.7179C9.89934 13.7179 9.76922 13.7338 9.64411 13.7629C9.37898 13.1606 8.77715 12.7397 8.0768 12.7397C7.37644 12.7397 6.77457 13.1606 6.50949 13.7629C6.38437 13.7338 6.25421 13.7179 6.12031 13.7179C5.75244 13.7179 5.41191 13.8344 5.13281 14.0318C5.38572 14.5408 5.83137 14.9977 6.46712 15.3973Z\" fill=\"#0052B4\"/>\n <path d=\"M12.0008 7.8375C12.2493 7.8375 12.4508 7.63603 12.4508 7.3875C12.4508 7.13897 12.2493 6.9375 12.0008 6.9375C11.7523 6.9375 11.5508 7.13897 11.5508 7.3875C11.5508 7.63603 11.7523 7.8375 12.0008 7.8375Z\" fill=\"#F9F9F9\"/>\n </SvgIcon>\n )\n}","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst CountryFRAIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z\" fill=\"white\" />\n <path d=\"M7.99875 23.3171C3.33863 21.6694 0 17.2247 0 12.0003C0 6.77592 3.33863 2.33129 7.99875 0.683594V23.3171Z\" fill=\"#002654\" />\n <path d=\"M24 11.973V12.0277C23.9883 17.2403 20.6532 21.6723 16.0012 23.3171V0.683594C20.6532 2.32841 23.9883 6.76041 24 11.973Z\" fill=\"#CE1126\" />\n </SvgIcon>\n )\n};\n\nexport default CountryFRAIcon;\n","import React from \"react\";\n\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nconst CountryITAIcon = (props: any) => {\n return (\n <SvgIcon width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" {...props} >\n <path d=\"M12 24C18.6274 24 24 18.6274 24 12C24 5.37258 18.6274 0 12 0C5.37258 0 0 5.37258 0 12C0 18.6274 5.37258 24 12 24Z\" fill=\"white\" />\n <path d=\"M7.99875 23.3171C3.33863 21.6694 0 17.2247 0 12.0003C0 6.77592 3.33863 2.33129 7.99875 0.683594V23.3171Z\" fill=\"#009246\" />\n <path d=\"M24 11.973V12.0277C23.9883 17.2403 20.6532 21.6723 16.0012 23.3171V0.683594C20.6532 2.32841 23.9883 6.76041 24 11.973Z\" fill=\"#CE2B37\" />\n </SvgIcon>\n )\n};\n\nexport default CountryITAIcon;\n","import * as React from \"react\";\n\nimport CountryAllIcon from \"./CountryAllIcon\";\nimport CountryDEUIcon from \"./CountryDEUIcon\";\nimport CountryAGOIcon from \"./CountryAGOIcon\";\nimport CountryARGIcon from \"./CountryARGIcon\";\nimport CountryBOLIcon from \"./CountryBOLIcon\";\nimport CountryBRAIcon from \"./CountryBRAIcon\";\nimport CountryCANIcon from \"./CountryCANIcon\";\nimport CountryCHLIcon from \"./CountryCHLIcon\";\nimport CountryCOLIcon from \"./CountryCOLIcon\";\nimport CountryCRIIcon from \"./CountryCRIIcon\";\nimport CountryECUIcon from \"./CountryECUIcon\";\nimport CountryESPIcon from \"./CountryESPIcon\";\nimport CountryGBRIcon from \"./CountryGBRIcon\";\nimport CountryUSAIcon from \"./CountryUSAIcon\";\nimport CountryGTMIcon from \"./CountryGTMIcon\";\nimport CountryHNDIcon from \"./CountryHNDIcon\";\nimport CountryMEXIcon from \"./CountryMEXIcon\";\nimport CountryNICIcon from \"./CountryNICIcon\";\nimport CountryPANIcon from \"./CountryPANIcon\";\nimport CountryPRYIcon from \"./CountryPRYIcon\";\nimport CountryPERIcon from \"./CountryPERIcon\";\nimport CountryPRTIcon from \"./CountryPRTIcon\";\nimport CountryDOMIcon from \"./CountryDOMIcon\";\nimport CountrySLVIcon from \"./CountrySLVIcon\";\nimport CountryTTOIcon from \"./CountryTTOIcon\";\nimport CountryURYIcon from \"./CountryURYIcon\";\nimport CountryVENIcon from \"./CountryVENIcon\";\nimport CountryCUBIcon from \"./CountryCUBIcon\";\nimport CountryAUSIcon from \"./CountryAUSIcon\";\nimport CountryBELIcon from \"./CountryBELIcon\";\nimport CountryNORIcon from \"./CountryNORIcon\";\nimport CountryPRIIcon from \"./CountryPRIIcon\";\nimport CountrySWEIcon from \"./CountrySWEIcon\";\nimport CountrySVKIcon from \"./CountrySVKIcon\";\nimport CountryFRAIcon from \"./CountryFRAIcon\";\nimport CountryITAIcon from \"./CountryITAIcon\";\n\n\nexport {\n CountryDEUIcon\n , CountryAGOIcon\n , CountryARGIcon\n , CountryBOLIcon\n , CountryBRAIcon\n , CountryCANIcon\n , CountryCHLIcon\n , CountryCOLIcon\n , CountryCRIIcon\n , CountryECUIcon\n , CountryESPIcon\n , CountryGBRIcon\n , CountryUSAIcon\n , CountryGTMIcon\n , CountryHNDIcon\n , CountryMEXIcon\n , CountryNICIcon\n , CountryPANIcon\n , CountryPRYIcon\n , CountryPERIcon\n , CountryPRTIcon\n , CountryDOMIcon\n , CountrySLVIcon\n , CountryTTOIcon\n , CountryURYIcon\n , CountryVENIcon\n , CountryAUSIcon\n , CountryCUBIcon\n , CountryPRIIcon\n , CountryBELIcon\n , CountrySWEIcon\n , CountryNORIcon\n , CountrySVKIcon\n , CountryAllIcon\n};\n\n\ninterface CountryFlagIconProps {\n iso: string\n}\n\n\nfunction CountryFlagIcon({ iso }: CountryFlagIconProps): JSX.Element {\n\n const flag: { [key: string]: JSX.Element } = {\n \"DEU\": <CountryDEUIcon />,\n \"AGO\": <CountryAGOIcon />,\n \"ARG\": <CountryARGIcon />,\n \"BOL\": <CountryBOLIcon />,\n \"BRA\": <CountryBRAIcon />,\n \"CAN\": <CountryCANIcon />,\n \"CHL\": <CountryCHLIcon />,\n \"COL\": <CountryCOLIcon />,\n \"CRI\": <CountryCRIIcon />,\n \"ECU\": <CountryECUIcon />,\n \"ESP\": <CountryESPIcon />,\n \"FRA\": <CountryFRAIcon />,\n \"GBR\": <CountryGBRIcon />,\n \"USA\": <CountryUSAIcon />,\n \"GTM\": <CountryGTMIcon />,\n \"HND\": <CountryHNDIcon />,\n \"ITA\": <CountryITAIcon />,\n \"MEX\": <CountryMEXIcon />,\n \"NIC\": <CountryNICIcon />,\n \"PAN\": <CountryPANIcon />,\n \"PRY\": <CountryPRYIcon />,\n \"PER\": <CountryPERIcon />,\n \"PRT\": <CountryPRTIcon />,\n \"DOM\": <CountryDOMIcon />,\n \"SLV\": <CountrySLVIcon />,\n \"TTO\": <CountryTTOIcon />,\n \"URY\": <CountryURYIcon />,\n \"VEN\": <CountryVENIcon />,\n \"AUS\": <CountryAUSIcon />,\n \"CUB\": <CountryCUBIcon />,\n \"PRI\": <CountryPRIIcon />,\n \"BEL\": <CountryBELIcon />,\n \"SWE\": <CountrySWEIcon />,\n \"NOR\": <CountryNORIcon />,\n \"SVK\": <CountrySVKIcon />,\n \n \"ALL\": <CountryAllIcon /> \n };\n\n return flag[iso] || <CountryAllIcon />;\n}\n\nexport default CountryFlagIcon;","import React, { useState } from \"react\";\n\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\n\nimport { InputEditableItemProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { EditIcon, SaveIcon } from \"../../../assets/icons\";\nimport { ClickAwayListener } from \"@material-ui/core\";\nimport InputBase from \"@material-ui/core/InputBase\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport { CurrencyRegex } from \"../../../constants/validator\";\n\n\nenum InputState {\n Idle,\n Edit\n}\n\n\nexport default function InputEditableItem(props: InputEditableItemProps) {\n \n const { value, setValue, valueTemplate, setValid, disabled, maxLength, maxValue, color } = props;\n \n const actualMaxLength = maxLength ?? 10;\n const maxDecimals = 2;\n \n const classes = useStyles(color)();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n \n const templatedValue = useCurrencyValueTemplate(valueTemplate);\n \n const [isError, setError] = useState<boolean>(false);\n const [inputState, setInputState] = useState<InputState>(InputState.Idle);\n const [displayValue, setDisplayValue] = useState<string>(templatedValue(value));\n \n function handleEditButtonClick() {\n setDisplayValue(value.toString());\n setInputState(InputState.Edit);\n setValid(false);\n }\n \n function handleEditClickAway() {\n setError(true);\n }\n \n function handleEditFocus() {\n setError(false);\n }\n \n function handleSaveButtonClick() {\n let parsedValue = parseFloat(displayValue);\n if (Number.isNaN(parsedValue)) parsedValue = 0;\n if (maxValue && parsedValue > maxValue.maxValue) {\n displayAlert(maxValue.errorMessage)\n return;\n }\n setValue(parsedValue);\n setDisplayValue(templatedValue(parsedValue));\n setError(false);\n setValid(true);\n setInputState(InputState.Idle);\n }\n \n function displayAlert(message: string) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: null,\n description: message,\n })\n )\n }\n \n function handleEditOnChange(event: any) {\n event.preventDefault();\n\n if (Number.isNaN(+event.target.value)) return;\n\n const value = event.target.value+\"\";\n const actualValue = value.replace(\",\", \".\").replace(/[^\\d.]/g, \"\");\n\n // verify decimals\n const pointIndex = value.indexOf(\".\");\n const hasDecimals = pointIndex>-1;\n\n if (hasDecimals) {\n if ((value.length-pointIndex-1) > maxDecimals) return;\n }\n else {\n if (value.length > actualMaxLength) return;\n }\n\n setDisplayValue((actualValue)+\"\");\n }\n \n const SaveButton = () => \n <SaveIcon \n style={{ width: 16, height: 16, color: \"6462F3\" }}\n viewBox={\"0 0 16 16\"}\n className={classes.editSaveButton}\n />\n \n \n return (\n <div>\n {\n inputState === InputState.Idle\n ?\n <div className={classes.idleRoot}>\n <div className={classes.idleValue}>{displayValue}</div>\n <div>\n {disabled \n ? \"\" \n :\n <EditIcon\n style={{width: 11, height: 11, color: \"#919CA5\"}}\n viewBox={\"0 0 16 16\"}\n onClick={handleEditButtonClick}\n />\n }\n </div>\n </div>\n : \n <ClickAwayListener onClickAway={handleEditClickAway}>\n <div className={classes.editRoot}>\n <InputBase\n className={`${classes.input} ${isError ? classes.inputError : \"\"}`}\n classes={{\n focused: classes.inputFocused,\n disabled: classes.inputDisabled,\n input: classes.inputText,\n }}\n value={displayValue}\n placeholder={templatedValue(0.00)}\n onChange={handleEditOnChange}\n onFocus={handleEditFocus}\n disabled={disabled ?? false}\n inputProps={{\n maxLength: maxLength ?? 10,\n }}\n type=\"text\"\n />\n <div className={classes.editSaveIcon} onClick={() => handleSaveButtonClick()}>\n <SaveButton />\n </div>\n </div>\n </ClickAwayListener>\n }\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { useHistory } from \"react-router-dom\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport { DatePicker, MuiPickersUtilsProvider } from \"@material-ui/pickers\";\nimport { MaterialUiPickersDate } from \"@material-ui/pickers/typings/date\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport DateFnsUtils from \"@date-io/date-fns\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\nimport { Grid, MenuItem } from \"@material-ui/core\";\nimport Select from \"@material-ui/core/Select\";\nimport { conformToMask } from \"react-text-mask\";\nimport \"antd/dist/antd.css\";\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\n\nimport { AppointmentService } from \"./../../../api/appointment-service\";\nimport { ClockIcon } from \"../../../assets/icons\";\nimport { AppointmentFollowUpProps } from \"./props\";\nimport TextareaWithLabel from \"../../common/TextareaWithLabel\";\nimport { ServiceGroupModel } from \"../../../models/service-group-model\";\nimport ServicesService from \"../../../api/settings-services-service\";\nimport { SelectItem } from \"../../common/Select\";\nimport { CreateFollowUpModel } from \"../../../models/create-follow-up-model\";\nimport { useAppDispatch, useAppSelector } from \"./../../../redux/hooks\";\nimport { alertsActions } from \"./../../../redux/alerts-slice\";\nimport { GetMobileMaskByTemp } from \"./../../../constants/mask\";\n\nimport useStyles from \"./css\";\nimport CountryFlagIcon from \"../../../assets/flags\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\n\nconst AppointmentFollowUp = (props: AppointmentFollowUpProps) => {\n \n const dispatch = useAppDispatch();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const { enqueueAlert } = alertsActions;\n const history = useHistory();\n const { open, appointment, appointmentDetails, onClose } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const format = \"HH:mm\";\n const mobileTemplate: string = \"000-000-0000\";\n \n const [isValid, setIsValid] = useState<Boolean>(false);\n const [timePickerValue, setTimePickerValue] = useState<string | null>(null);\n const [dateValue, setDateValue] = useState<Date>(new Date());\n const [availableDays, setAvailableDays] = useState<number[]>([]);\n const [services, setServices] = useState<ServiceGroupModel[]>([]);\n const [groupServices, setGroupServices] = useState<SelectItem[]>([]);\n const [serviceId, setServiceId] = useState<string>(\"\");\n const [notes, setNotes] = useState<string>(\"\");\n\n\n const handleGoBackClick = () => {\n onClose(false);\n }\n\n const handleOnCreateClick = () => {\n \n if (!timePickerValue) return;\n\n const hour = timePickerValue.split(\":\")[0];\n const min = timePickerValue.split(\":\")[1];\n\n const date1 = new Date(dateValue);\n const scheduled = new Date(date1.getFullYear(), date1.getMonth(), date1.getDate(), (+hour), (+min), 0);\n\n const followUp = new CreateFollowUpModel({\n appointmentId: appointment?.appointmentId,\n customerId: appointmentDetails?.customerId,\n serviceId: serviceId,\n scheduled: scheduled,\n notes: notes\n });\n\n (async() => {\n const result = await AppointmentService.createFollowUp(followUp);\n\n if (result) {\n\n onClose(true);\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Follow-up created successfully\"),\n description: null,\n // link: {\n // onClick: (e: any) => {\n // e.preventDefault();\n // history.push(`${Url.FollowUps.Main}`);\n // },\n // title: t(\"Go to my follow-ups\"),\n // }\n })\n );\n\n }\n })();\n }\n \n\n const handleTime = (e: any) => {\n setTimePickerValue(e);\n };\n\n\n const getLocale = (): any => {\n switch (localeApp) {\n case \"es\":\n if (esLocale && esLocale.options) esLocale.options = { ...esLocale.options, weekStartsOn: 1 };\n return esLocale;\n\n default:\n if (enLocale && enLocale.options) enLocale.options = { ...enLocale.options, weekStartsOn: 1 };\n return enLocale;\n }\n };\n\n\n const renderWrappedDay = (\n date: MaterialUiPickersDate,\n selectedDate: MaterialUiPickersDate,\n dayInCurrentMonth: boolean\n ) => {\n const day = new Date(date as Date);\n const selected = new Date(selectedDate as Date);\n const current = new Date();\n current.setHours(0, 0, 0, 0);\n const dayOff =\n availableDays.findIndex((dayOff) => dayOff === day.getDay()) !== -1;\n const disabled = day < current || dayOff;\n const isCurrentDate =\n day.getDate() === current.getDate() &&\n day.getMonth() === current.getMonth();\n const isSelected =\n selected.getDate() === day.getDate() &&\n selected.getMonth() === day.getMonth();\n\n return (\n <div className={classes.dateRoot}>\n {dayInCurrentMonth ? (\n <IconButton\n className={`${classes.date} ${\n isCurrentDate ? classes.currentDate : \"\"\n } ${isSelected ? classes.selectedDate : \"\"}`}\n disabled={disabled}\n >\n {day.getDate()}\n </IconButton>\n ) : null}\n </div>\n );\n };\n\n\n const handleDisabledDay = (date: MaterialUiPickersDate): boolean => {\n const day = new Date(date as Date);\n const current = new Date();\n current.setHours(0, 0, 0, 0);\n const dayOff =\n availableDays.findIndex((dayOff) => dayOff === day.getDay()) !== -1;\n return day < current || dayOff;\n };\n\n\n const handleChangeDate = (date: MaterialUiPickersDate) => {\n setDateValue(date as Date);\n };\n \n\n const numberWithCommas = (x: any) => {\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n };\n \n\n const loadServices = async () => {\n if (!open)\n return;\n const services = await ServicesService.getServicesGroupByCategory();\n\n setServices(services);\n const selectArray: SelectItem[] = [];\n\n const showPrices = true;\n\n services.map((category, index) => {\n selectArray.push({\n key: `${category.category}-${index}`,\n value: `${category.category} (${category.services?.length})`,\n isGroup: true,\n });\n category.services?.map((service) =>\n selectArray.push({\n key: service.id,\n value:\n `${service.name}` +\n (showPrices ? ` ($${numberWithCommas(service.price)})` : \"\"),\n })\n );\n\n return null;\n });\n setGroupServices(selectArray);\n };\n\n\n const getServiceName = (id: any): string => {\n if (!id) {\n return t(\"Select one of your services\");\n }\n\n const category = services.find(\n (service) => service.services?.findIndex((svc) => svc.id === id) !== -1\n );\n\n const categoryService = category?.services?.find(\n (service) => service.id === id\n );\n\n return `${category?.category} \\u00B7 ${categoryService?.name}`;\n };\n\n\n const handleServiceChange = (event: React.ChangeEvent<{ value: any }>) => {\n const id = event.target.value;\n setServiceId(id);\n };\n\n\n const handleNotesChange = (e: any) => {\n const { value } = e.target;\n setNotes(value);\n };\n\n\n class OverriddenDateFnsUtils extends DateFnsUtils {\n getWeekdays() {\n if (localeApp === \"es\")\n return [\"Lun\", \"Mar\", \"Mié\", \"Jue\", \"Vie\", \"Sáb\", \"Dom\"];\n else\n return [\"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\", \"Sun\"]\n\n }\n }\n \n\n useEffect(() => {\n\n if (timePickerValue\n && dateValue\n && serviceId\n && notes) {\n setIsValid(true);\n } else {\n setIsValid(false);\n }\n\n }, [timePickerValue, dateValue, serviceId, notes])\n\n\n useEffect(() => {\n\n (async () => {\n setDateValue(new Date());\n setTimePickerValue(null);\n setServiceId(appointment?.firstServiceId ?? \"\");\n setNotes(\"\");\n setIsValid(false);\n await loadServices();\n await loadAvailableDays();\n })();\n\n }, [open])\n\n \n const loadAvailableDays = async () => {\n if (!open)\n return;\n const days = await AppointmentService.getAvailableDays();\n setAvailableDays(days);\n };\n\n\n return (<>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n\n <Fade in={open}>\n <div className={classes.modalPaper}>\n \n <Grid container spacing={2}>\n <Grid item xs={4}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {t(\"New follow-up\")}\n </Typography>\n </Grid>\n <Grid item xs={8} style={{textAlign: \"right\"}}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleGoBackClick}\n >\n {t(\"Go back\")}\n </Button>\n \n <Button\n className={`${classes.button} ${classes.create}`}\n disabled={!isValid}\n classes={{ disabled: classes.createDisabled }}\n onClick={handleOnCreateClick}\n >\n {t(\"Create follow-up\")}\n </Button>\n </Grid>\n </Grid>\n\n <Grid container spacing={2} style={{marginTop: 30}} >\n <Grid item xs={12}>\n <Typography className={classes.requiredText}>\n {t(\"Required fields\")}\n <span className={classes.requiredSymbol}>{\" *\"}</span>\n </Typography>\n </Grid>\n </Grid>\n\n <Grid container spacing={2} style={{marginTop: 10}} >\n <Grid item xs={6}>\n <Typography className={classes.labelText} style={{marginBottom: 10}}>\n {t(\"Select the date\")}\n <span className={classes.requiredSymbol}>{\" *\"}</span>\n </Typography>\n\n <MuiPickersUtilsProvider utils={OverriddenDateFnsUtils} locale={getLocale()} >\n <DatePicker\n autoOk\n disableToolbar\n fullWidth\n variant=\"static\"\n openTo=\"date\"\n value={dateValue}\n onChange={handleChangeDate}\n renderDay={renderWrappedDay}\n shouldDisableDate={handleDisabledDay}\n disableFuture={false}\n style={{\n alignItems: \"center\",\n alignContent: \"center\",\n justifyContent: \"center\",\n }}\n />\n </MuiPickersUtilsProvider>\n\n </Grid>\n <Grid item xs={6}>\n\n <Typography className={classes.labelText} style={{marginBottom: 10}}>\n {t(\"Time\")}\n <span className={classes.requiredSymbol}>{\" *\"}</span>\n </Typography> \n\n <div style={{marginBottom: 20}}>\n <TimePicker\n key={`timePicker`}\n className={`${classes.selectStyle}`}\n placeholder={t(\"Time the follow-up will be sent\")}\n inputReadOnly={true}\n showNow={false}\n value={timePickerValue !== null ? moment(timePickerValue, format) : timePickerValue}\n onOk={(timePicker) => { handleTime(timePicker.format(format)); }}\n format={format}\n />\n <div className={classes.divClock}>\n <ClockIcon />\n </div>\n </div>\n \n <div style={{marginBottom: 20}}>\n\n <Typography className={classes.labelText} style={{marginBottom: 10}}>\n {t(\"Service\")}\n <span className={classes.requiredSymbol}>{\" *\"}</span>\n </Typography> \n\n <Select\n disableUnderline\n displayEmpty\n placeholder={t(\"Select one of your services\")}\n id=\"service-id\"\n name=\"service\"\n className={classes.selectService}\n classes={{\n root: `${classes.selectRoot} ${\n serviceId ? classes.selected : classes.placeholder\n }`,\n }}\n style={{ width: \"100%\" }}\n value={groupServices.length ? serviceId! : \"\"}\n onChange={handleServiceChange}\n renderValue={getServiceName}\n inputProps={{ style: { padding: 0 } }}\n MenuProps={{\n getContentAnchorEl: null,\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\",\n },\n }}>\n <MenuItem classes={{ root: classes.itemRoot }} value={\"\"} disabled>\n {t(\"Select one of your services\")}\n </MenuItem>\n {groupServices && groupServices.length\n ? groupServices.map((category, index) => {\n if (category.isGroup) {\n return (\n <MenuItem\n key={category.key}\n classes={{ root: classes.group }}\n disabled\n >\n {category.value}\n </MenuItem>\n );\n }\n\n return (\n <MenuItem\n key={category.key}\n classes={{\n root: classes.itemRoot,\n selected: classes.itemSelected,\n }}\n value={category.key}\n >\n {category.value}\n </MenuItem>\n );\n })\n : null}\n </Select>\n </div>\n\n <div style={{marginBottom: 10}}>\n <TextareaWithLabel\n value={notes}\n width=\"100%\"\n maxRows={3}\n showCounter={true}\n inputClass={classes.inputTextareaClass}\n label={() => (<>\n <Typography className={classes.labelText}>\n {t(\"Notes for the customer\")}\n <span className={classes.requiredSymbol}>{\" *\"}</span>\n </Typography> \n </>)}\n placeholder={t(\"Write relevant notes for follow-up\")}\n maxLength={700}\n onChange={handleNotesChange}\n />\n </div>\n\n <div style={{marginBottom: 5}}>\n\n <Typography className={classes.labelNotes}>\n {t(\"The notes will be sent to the customer via WhatsApp.\")}\n </Typography> \n\n <Typography className={classes.labelNotes}>\n {t(\"Example: “This is a reminder that you should schedule an appointment to review the progress of your hair treatment.”\")}\n </Typography> \n </div>\n\n </Grid>\n </Grid>\n\n <hr />\n \n <Grid container spacing={2}>\n <Grid item xs={4}>\n <Typography className={classes.labelNotes}>\n {useCustomerTerminology(t(\"Customer name\"), \"Customer name\")}\n </Typography> \n <Typography className={classes.labelText}>\n {appointment?.customerName}\n </Typography> \n </Grid>\n <Grid item xs={4}>\n <Typography className={classes.labelNotes}>\n {t(\"Email\")}\n </Typography> \n <Typography className={classes.labelText}>\n {appointmentDetails?.customerEmail ?? \"- -\"}\n </Typography> \n </Grid>\n <Grid item xs={4}>\n <Typography className={classes.labelNotes}>\n {t(\"PhoneNumberCellular\")}\n </Typography> \n <div className={classes.labelText}>\n <div className={classes.divFlag}>\n <CountryFlagIcon iso={appointmentDetails?.customerMobileCodeIso3 || \"MEX\"} />\n </div>\n <div className={classes.divCode}> \n {appointmentDetails?.customerMobileCode !== undefined ? `+${appointmentDetails?.customerMobileCode}` : \"+52\"}\n </div>\n <div className={classes.divMobile}>\n {appointmentDetails?.customerMobile ? conformToMask(appointmentDetails?.customerMobile, GetMobileMaskByTemp(appointmentDetails.customerMobileTemplate || mobileTemplate)).conformedValue : \"\"}\n </div>\n </div> \n </Grid>\n </Grid>\n\n </div>\n </Fade>\n\n </Modal>\n\n </>);\n};\n\nexport default AppointmentFollowUp;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n popover: {\n borderRadius: \"8px\",\n width: 415,\n height: 541,\n \n overflowY: \"scroll\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n root: {\n padding: \"0px 20px 20px 20px\",\n overflow: \"hidden\",\n },\n header: {\n borderRadius: \"5px 5px 0px 0px\",\n width: \"100%\",\n height: \"4px\",\n },\n headerActions: {\n height: 60,\n paddingTop: 25,\n },\n headerText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: \"#899198\",\n textTransform: \"uppercase\",\n marginLeft: 12,\n width: 103,\n },\n headerSubText: {\n color: theme.colors.grey4,\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontSize: 10,\n position: \"relative\",\n width: 150,\n paddingLeft: 26,\n top: -15,\n fontWeight: 400,\n },\n headerButtons: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n margin: \"0px auto\"\n },\n headerIcon: {\n marginLeft: 10,\n display: \"flex\",\n width: 20,\n height: 20,\n },\n modalActionsAppt: {\n position: \"absolute\",\n top: 25,\n right: 0,\n background: \"white\",\n width: 202,\n textAlign: \"center\",\n border: \"1px solid #DBDCDD\",\n boxShadow: \"0px 4px 4px rgb(166 166 166 / 25%)\",\n borderRadius: 5,\n backgroundColor: \"#FFFFFF\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n color: theme.colors.grey5,\n },\n modalActionFont: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: theme.colors.grey5,\n padding: 5,\n cursor: \"pointer\",\n position: \"relative\",\n background: \"white\",\n width: 200,\n textAlign: \"left\",\n paddingLeft: 15,\n height: 35\n },\n modalActionFirst: {\n borderTopLeftRadius: 5,\n borderTopRightRadius: 5,\n borderBottom: \"1px solid #DBDCDD\",\n \"&:hover\": {\n backgroundColor: \"#E1E9FE\"\n }\n },\n modalActionLast: {\n borderBottomLeftRadius: 5,\n borderBottomRightRadius: 5,\n \"&:hover\": {\n backgroundColor: \"#E1E9FE\"\n }\n },\n arrived: {\n background: \"#36CE91\",\n },\n notArrived: {\n background: \"#F15857\",\n },\n confirmed: {\n background: \"#0BCBE0\",\n },\n notConfirmed: {\n background: \"#919CA5\",\n },\n content: {\n width: \"100%\",\n paddingTop: 16,\n },\n bodyContent: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n },\n row: {\n display: \"flex\",\n width: \"100%\",\n },\n subsection: {\n marginTop: 8\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: 288,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"80%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteAppointment: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n width: 317,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n caption: {\n ...theme.typography.caption2,\n color: \"#6A6E72\",\n },\n recurringAppointmentInfo: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 8\n },\n txtBody1: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey6,\n },\n txtBody2: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey6,\n },\n paymentRow: {\n justifyContent: \"space-between\",\n alignItems: \"center\"\n },\n paymentInfo: {\n display: \"flex\"\n },\n paymentAmount: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n recurringAppointmentPaymentText: {\n ...theme.typography.caption1,\n color: theme.colors.grey4,\n },\n paymentButton: {\n justifySelf: \"flex-end\",\n \n width: 131,\n height: 32,\n marginRight: 30,\n \n backgroundColor: \"transparent\",\n borderRadius: 5,\n \n ...theme.typography.buttons,\n fontWeight: 700,\n color: theme.colors.clearMain,\n \n \"&:hover\": {\n backgroundColor: theme.colors.clearLilac\n }\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n \n height: \"100%\",\n position: \"relative\",\n width: 400,\n padding: 16,\n paddingTop: 0\n },\n drawer: {\n background: \"#FFFFFF\",\n borderTopLeftRadius: 10,\n borderBottomLeftRadius: 10,\n\n display: \"flex\",\n flexDirection: \"column\",\n overflowX: \"hidden\",\n },\n newHeader: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-between\",\n alignItems: \"flex-start\",\n \n height: 67,\n width: \"100%\",\n \n paddingTop: 16,\n paddingBottom: 16,\n \n position: \"sticky\",\n },\n tabs: {\n ...theme.typography.txtBody1,\n backgroundColor: \"#FFFFFF\",\n color: theme.colors.clearMain,\n \n borderBottom: \"solid\",\n borderBottomWidth: 1,\n borderBottomColor: \"rgba(201, 205, 211, 0.5)\",\n \n \"& .MuiTabs-indicator\": {\n backgroundColor: \"#FFFFFF\"\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n width: \"50%\",\n },\n \"& .MuiTab-root\": {\n paddingLeft: 0,\n paddingRight: 0,\n textTransform: \"none\",\n color: theme.colors.grey1,\n backgroundColor: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n \"& .Mui-selected\": {\n color: theme.colors.clearMain,\n backgroundColor: \"#FFFFFF\",\n fontWeight: \"bold\",\n },\n },\n tab: {\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n }\n },\n tabPanelRoot: {\n padding: \"0 !important\",\n display: \"flex\",\n flexDirection: \"column\",\n height: \"100%\"\n },\n headerTitle: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 700\n },\n headerChargingInfo: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n headerChargingUserName: {\n paddingLeft: 4,\n fontWeight: 700\n },\n headerChargingPaymentId: {\n paddingLeft: 4,\n fontWeight: 700\n },\n closeIcon: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n width: 16,\n height: 16,\n \n position: \"absolute\",\n top: 16,\n right: 16,\n \n cursor: \"pointer\",\n color: theme.colors.grey4,\n },\n divider: {\n width: 368,\n height: 0,\n borderTop: \"1px solid\",\n borderColor: theme.colors.grey2,\n opacity: 0.5,\n marginTop: 5,\n marginBottom: 15\n },\n marginTopBottom: {\n marginTop: 24,\n marginBottom: 24\n },\n content: {\n overflowY: \"scroll\",\n },\n paymentProgressBar: {\n display: \"flex\",\n flexDirection: \"column\",\n \n marginTop: 24,\n marginBottom: 24,\n },\n paymentProgressBarLegend: {\n display: \"flex\",\n justifyContent: \"space-between\",\n \n marginTop: 8,\n },\n paymentProgressBarLegendItem: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\"\n },\n paymentProgressBarLegendIcon: {\n width: 5,\n height: 5,\n \n margin: 4,\n \n borderRadius: \"50%\"\n },\n paymentProgressBarLegendText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n paidIcon: {\n backgroundColor: theme.colors.clearGreen\n },\n unpaidIcon: {\n backgroundColor: theme.colors.clearMain\n },\n progressBarPaid: {\n borderRadius: 5,\n \n backgroundColor: theme.colors.clearGreen\n },\n progressBarUnpaid: {\n backgroundColor: theme.colors.clearMain\n },\n inputWithLabel: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n marginTop: 16,\n },\n label: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n margin: 0,\n marginBottom: 8\n },\n controlLabel: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n controlText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n dot: {\n ...theme.typography.buttons,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n textArea: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n fontWeight: \"normal\",\n opacity: 0.8,\n },\n },\n servicesDetail: {\n display: \"flex\",\n flexDirection: \"row\",\n flexWrap: \"wrap\"\n },\n servicesDetailRow: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n width: 368,\n \n marginBottom: 8,\n },\n servicesDetailColumn: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n \"&:first-child\": {\n width: 220\n }\n },\n servicesDetailServiceBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\"\n },\n servicesDetailDivider: {\n width: 368,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey1,\n marginBottom: 8,\n },\n servicesDetailHeader: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey4,\n marginBottom: 8\n },\n servicesDetailSubheader: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n servicesDetailText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n servicesDetailValue: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey5\n },\n servicesDetailDiscount: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n },\n servicesDetailTotal: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearGreen,\n marginTop: 8,\n },\n servicesDetailPaidWith: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n paddingLeft: 15\n },\n mainColorText: {\n color: theme.colors.clearMain,\n },\n greenText: {\n color: theme.colors.clearGreen\n },\n changeRecords: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n marginTop: 16\n },\n changeRecordBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\"\n },\n changeRecordRow: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n marginBottom: 8\n },\n changeRecordLeftColumn: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n minWidth: 115,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n historyRightColumn: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n alignSelf: \"center\",\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n historyRightColumnStrike: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n initialValuesBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\"\n },\n initialValuesRow: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n marginBottom: 8\n },\n initialValuesLeftColumn: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n maxWidth: 120,\n minWidth: 115,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n changeRecordDivider: {\n width: 368,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey2,\n opacity: 0.5,\n marginTop: 16,\n marginBottom: 16,\n },\n footer: {\n height: \"auto\",\n width: 368,\n \n position: \"sticky\",\n bottom: 0,\n paddingBottom: 16,\n backgroundColor: \"#FFFFFF\", \n marginTop: \"auto\"\n },\n registerPaymentButton: {\n width: \"100%\",\n height: 32,\n \n backgroundColor: theme.colors.clearMain,\n borderRadius: 51,\n \n ...theme.typography.buttons,\n color: theme.colors.grey1,\n fontWeight: 700,\n \n \"&:hover\": {\n backgroundColor: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n \"&:disabled\": {\n backgroundColor: theme.colors.clearMain,\n opacity: 0.3,\n color: theme.colors.grey1,\n }\n },\n \n chip: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n padding: \"4px 8px\",\n backgroundColor: \"rgba(100, 98, 243, 0.2)\",\n borderRadius: 5,\n marginBottom: 12,\n \n ...theme.typography.txtBody2,\n fontWeight: 700,\n color: theme.colors.clearMain\n },\n \n accordionSummary: {\n backgroundColor: \"#f6f6f6\",\n width: \"100%\"\n },\n accordionTitle: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey5,\n position: \"relative\",\n top: 5,\n left: 10\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n fontSize: 12,\n display: \"flex\",\n alignItems: \"center\"\n },\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number | string, itemHeight?: number | string) =>\n makeStyles((theme) => ({\n select: {\n ...theme.typography.txtBody2,\n backgroundColor: theme.colors.grey1,\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n cursor: \"pointer\",\n width: width || 370,\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n cursor: \"pointer\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"11px\",\n marginBottom: \"11px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: \"#919CA5\"\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"11px 0px 12px 12px\",\n },\n placeholder: {\n color: \"#676767\",\n opacity: \"0.42\",\n padding: \"13px 0px 13px 12px\",\n \"&.Mui-disabled\": {\n opacity: \"0.42\",\n },\n },\n focused: {\n color: \"#5C6477\",\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n menuPaper: {\n maxHeight: 300,\n marginTop: 6,\n\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: itemHeight || 40,\n display: \"flex\",\n alignItems: \"center\",\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n },\n group: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n \"&.Mui-disabled\": {\n opacity: 1,\n },\n },\n }));\n\nexport default useStyles;","import React from \"react\";\n\nimport Input from \"@material-ui/core/Input\";\nimport MuiSelect from \"@material-ui/core/Select\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\n\nimport ArrowDropDownIcon from \"./../../../assets/icons/ArrowDropDownIcon\";\n\nimport useStyles from \"./css\";\nimport { SelectKeyProps } from \"./props\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\"\n\nconst SelectKey = (props: SelectKeyProps) => {\n const {\n value,\n setValue,\n placeholder,\n name,\n items,\n width,\n itemHeight,\n onChange,\n onBlur,\n disabled,\n styleClass,\n itemRootClass,\n classes,\n isValid,\n arrowIcon,\n colorArrowIcon,\n menuProps\n } = props;\n const useClasses = useStyles(width, itemHeight)();\n\n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n\n if (isValid() === undefined) {\n return false;\n }\n\n return !isValid();\n };\n\n const handleOnChange = (event: React.ChangeEvent<{ value: unknown }>) => {\n setValue(event.target.value);\n if (onChange) {\n onChange();\n }\n };\n \n function handleOnBlur(event: React.ChangeEvent<{ value: unknown }>) {\n if (onBlur) {\n onBlur();\n }\n }\n\n const ArrowIcon = (props: any) => (\n arrowIcon ? {...arrowIcon, props} :\n <ArrowDropDownIcon\n {...props}\n style={{ top: \"inherit\", right: 12, color: colorArrowIcon ?? \"#6462F3\" }}\n />\n );\n\n return (\n <MuiSelect\n disableUnderline\n classes={\n classes || {\n root: `${useClasses.focused} ${useClasses.selected} ${isError() ? useClasses.inputError : \"\"}`,\n }\n }\n name={name}\n className={styleClass ?? useClasses.select}\n input={<Input />}\n MenuProps={menuProps ??\n {\n getContentAnchorEl: null,\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\",\n },\n classes: { paper: useClasses.menuPaper },\n }}\n displayEmpty\n disabled={disabled ?? false}\n onChange={handleOnChange}\n onBlur={handleOnBlur}\n placeholder={placeholder}\n value={value === undefined || value === null ? \"\" : value}\n IconComponent={ArrowIcon}\n >\n {placeholder ? (\n <MenuItem classes={{ root: `${itemRootClass ?? useClasses.itemRoot}`, }} value=\"\" disabled>\n {placeholder}\n </MenuItem>\n ) : null}\n {items.map((item: SelectItem) =>\n (\n <MenuItem\n classes={{\n root: `${itemRootClass ?? useClasses.itemRoot}`,\n selected: useClasses.itemSelected,\n }}\n key={item.key}\n value={item.key}\n disabled={item?.disabled ?? false}\n >\n {item.value}\n </MenuItem>\n )\n )}\n </MuiSelect>\n );\n};\n\nexport default SelectKey;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (color?: string) => makeStyles((theme) => ({\n idleRoot: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n height: 24\n },\n idleValue: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: color ?? theme.colors.grey5,\n marginRight: 6\n },\n editRoot: {\n position: \"relative\"\n },\n input: {\n backgroundColor: theme.colors.grey1,\n height: 24,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 148,\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: 160,\n },\n inputDisabled: {\n color: \"#676767\",\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n },\n editSaveButton: {\n cursor: \"pointer\",\n marginRight: 7\n },\n editSaveIcon: {\n position: \"absolute\",\n right: 2,\n top: 8,\n\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n cursor: \"pointer\",\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (color?: string) => makeStyles((theme) => ({\n idleRoot: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n height: 24\n },\n idleValue: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: color ?? theme.colors.grey5,\n marginRight: 6\n },\n editRoot: {\n position: \"relative\"\n },\n input: {\n backgroundColor: theme.colors.grey1,\n height: 24,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 80,\n },\n inputSelect: {\n backgroundColor: theme.colors.grey1,\n height: 8,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 80,\n },\n selected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n focused: {\n padding: \"6px 0px 6px 15px\",\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n select: {\n ...theme.typography.txtBody2,\n backgroundColor: theme.colors.grey1,\n height: 29,\n marginLeft: 8,\n // padding: \"13px 10px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 60,\n \"&.MuiSelect-root\": {\n borderRadius: 5,\n },\n },\n \n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: 81,\n },\n inputDisabled: {\n color: \"#676767\",\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n },\n editSaveButton: {\n cursor: \"pointer\",\n marginRight: 7\n },\n editSaveIcon: {\n position: \"absolute\",\n right: 2,\n top: 8,\n \n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n cursor: \"pointer\",\n }\n })\n);\n\nexport default useStyles;","export enum DiscountType {\n Value = 1,\n Percentage = 2 \n}","import React, { useEffect, useState } from \"react\";\n\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\n\nimport { InputEditableWithSelectItemProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { EditIcon, SaveIcon } from \"../../../assets/icons\";\nimport { ClickAwayListener } from \"@material-ui/core\";\nimport InputBase from \"@material-ui/core/InputBase\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport Select from \"../Select\";\nimport { DiscountType } from \"../../../models/enums/discount-type\";\n\nenum InputState {\n Idle,\n Edit\n}\n\n\nexport default function InputEditableWithSelectItem(props: InputEditableWithSelectItemProps) {\n \n const { value, selectValue, setValue, valueTemplate, disabled, maxLength, maxValue, color, selectItems, subTotal } = props;\n \n const actualMaxLength = maxLength ?? 10;\n const maxDecimals = 2;\n \n const classes = useStyles(color)();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n \n const templatedValue = useCurrencyValueTemplate(valueTemplate);\n \n useEffect(() => {\n if (subTotal) {\n let currentValue = value;\n if (displaySelectValue === DiscountType.Percentage) {\n currentValue = (currentValue / 100) * subTotal;\n }\n setDisplayValue(templatedValue(currentValue));\n }\n }, [subTotal])\n \n \n const [isError, setError] = useState<boolean>(false);\n const [inputState, setInputState] = useState<InputState>(InputState.Idle);\n \n function getAmountDiscountByDiscountType() {\n return selectValue === DiscountType.Percentage ? (value / 100) * subTotal : value;\n }\n \n const [displayValue, setDisplayValue] = useState<string>(templatedValue(getAmountDiscountByDiscountType()));\n const [displaySelectValue, setDisplaySelectValue] = useState<DiscountType>(selectValue);\n \n function handleEditButtonClick() {\n setDisplayValue(value.toString());\n setInputState(InputState.Edit);\n }\n \n function handleEditClickAway() {\n let parsedValue = parseFloat(displayValue);\n let selectValue = displaySelectValue;\n if (Number.isNaN(parsedValue)) parsedValue = 0;\n setValue(parsedValue, selectValue);\n setError(false);\n \n if ((maxValue && parsedValue > maxValue.maxValue) && displaySelectValue === DiscountType.Value) {\n setError(true);\n }\n if ((maxValue && parsedValue > 100) && displaySelectValue === DiscountType.Percentage) {\n setError(true);\n }\n \n let calculateValue = parsedValue;\n if (displaySelectValue === DiscountType.Percentage) {\n calculateValue = (calculateValue / 100) * subTotal;\n }\n setDisplayValue(templatedValue(calculateValue));\n \n setInputState(InputState.Idle);\n }\n \n function handleEditOnChange(event: any) {\n event.preventDefault();\n \n if (Number.isNaN(+event.target.value)) return;\n \n const value = event.target.value + \"\";\n const actualValue = value.replace(\",\", \".\").replace(/[^\\d.]/g, \"\");\n \n // verify decimals\n const pointIndex = value.indexOf(\".\");\n const hasDecimals = pointIndex > -1;\n \n if (hasDecimals) {\n if ((value.length - pointIndex - 1) > maxDecimals) return;\n } else {\n if (value.length > actualMaxLength) return;\n }\n \n setDisplayValue((actualValue) + \"\");\n }\n \n function handleSelectEditOnChange(event: any) {\n event.preventDefault();\n const value = event.target.value;\n setDisplaySelectValue(value);\n }\n \n \n return (\n <div>\n {\n inputState === InputState.Idle\n ?\n <div className={classes.idleRoot}>\n <div className={classes.idleValue}>{displayValue}</div>\n <div>\n {disabled\n ? \"\"\n :\n <EditIcon\n style={{ width: 11, height: 11, color: \"#919CA5\" }}\n viewBox={\"0 0 16 16\"}\n onClick={handleEditButtonClick}\n />\n }\n </div>\n </div>\n :\n \n <ClickAwayListener mouseEvent=\"onMouseDown\" onClickAway={handleEditClickAway}>\n \n <div className={classes.editRoot}>\n <InputBase\n className={`${classes.input} ${isError ? classes.inputError : \"\"}`}\n classes={{\n focused: classes.inputFocused,\n disabled: classes.inputDisabled,\n input: classes.inputText,\n }}\n value={displayValue}\n placeholder={templatedValue(0.00)}\n onChange={handleEditOnChange}\n disabled={disabled ?? false}\n inputProps={{\n maxLength: maxLength ?? 10,\n }}\n type=\"text\"\n />\n <Select\n key={\"inputEditableWithSelectItem\"}\n width={51}\n classes={{\n root: `${classes.focused} ${classes.selected}`,\n }}\n styleClass={classes.select}\n value={displaySelectValue}\n onChange={handleSelectEditOnChange}\n colorArrowIcon={\"#5C6477\"}\n items={selectItems}\n disabled={false}/>\n \n </div>\n </ClickAwayListener>\n }\n \n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = (width?: number | string) =>\n makeStyles((theme) => ({\n select: {\n ...theme.typography.txtBody2,\n backgroundColor: theme.colors.grey1,\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n cursor: \"default\",\n width: width || 370,\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n cursor: \"default\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"11px\",\n marginBottom: \"11px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: Color.gray4\n },\n },\n menuPaper: {\n maxHeight: 300,\n marginTop: 6\n },\n tooltipBlock: {\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n menuPaperDisableScroll: {\n maxHeight: 300,\n marginTop: 6,\n top: 38,\n left: 0,\n maxWidth: \"fit-content!important\"\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"11px 0px 12px 12px\",\n },\n placeholder: {\n color: \"#676767\",\n // opacity: \"0.42\",\n padding: \"13px 0px 13px 12px\",\n \"&.Mui-disabled\": {\n opacity: \"0.42\",\n },\n },\n focused: {\n color: \"#5C6477\",\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n borderRadius: 5,\n },\n group: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n \"&.Mui-disabled\": {\n opacity: 1,\n },\n },\n }));\n\nexport default useStyles;\n","import React, { useEffect, useState, useRef } from \"react\";\n\nimport Input from \"@material-ui/core/Input\";\nimport MuiSelect from \"@material-ui/core/Select\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\n\nimport ArrowDropDownIcon from \"./../../../assets/icons/ArrowDropDownIcon\";\n\nimport useStyles from \"./css\";\nimport { SelectProps, SelectItem } from \"./props\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nconst Select = (props: SelectProps) => {\n const {\n value,\n placeholder,\n name,\n items,\n width,\n onChange,\n onBlur,\n disabled,\n disableScrollLock,\n styleClass,\n itemRootClass,\n classes,\n onRender,\n isValid,\n colorArrowIcon,\n showTooltip\n } = props;\n const useClasses = useStyles(width)();\n \n const selectRef = useRef<HTMLDivElement>(null);\n \n const [isTooltipOpen, setTooltipOpen] = useState<boolean>(false);\n const [isSelectOpen, setIsSelectOpen] = useState<boolean>(false);\n const [tooltipText, setTooltipText] = useState<string>(\"\");\n \n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n \n if (isValid() === undefined) {\n return false;\n }\n \n return !isValid();\n };\n \n const handleOnChange = (event: React.ChangeEvent<{ value: unknown }>) => {\n if (onChange) {\n onChange(event);\n }\n };\n \n const ArrowIcon = (props: any) => (\n <ArrowDropDownIcon\n {...props}\n style={{ top: \"inherit\", right: 12, color: colorArrowIcon ?? \"#6462F3\" }}\n />\n );\n \n const onMouseEnterItem = () => {\n let offsetWidth = (selectRef.current?.firstChild as HTMLElement | null)?.offsetWidth ?? 0;\n let scrollWidth = (selectRef.current?.firstChild as HTMLElement | null)?.scrollWidth ?? 0;\n\n if (offsetWidth < scrollWidth && !isSelectOpen && showTooltip) {\n setTooltipText(selectRef.current?.innerText ?? \"\");\n setTooltipOpen(true);\n }\n }\n \n function onRenderHandler(key: any) {\n if (onRender) {\n let renderedValue = onRender(key);\n return renderedValue;\n }\n }\n \n return (\n <Tooltip\n title={tooltipText}\n classes={{ tooltip: useClasses.tooltipBlock }}\n open={isTooltipOpen}>\n <MuiSelect\n disableUnderline\n classes={\n classes || { \n root: `${useClasses.focused} ${\n value ? useClasses.selected : useClasses.placeholder\n } ${isError() ? useClasses.inputError : \"\"}`,\n }\n }\n name={name}\n ref={selectRef}\n className={styleClass ?? useClasses.select}\n input={<Input/>}\n MenuProps={{\n classes: disableScrollLock\n ? { paper: useClasses.menuPaperDisableScroll }\n : { paper: useClasses.menuPaper },\n getContentAnchorEl: null,\n style: disableScrollLock ? { position: \"absolute\" } : {},\n disableScrollLock: disableScrollLock,\n //disablePortal: true,\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\",\n },\n }}\n displayEmpty\n disabled={disabled ?? false}\n onChange={handleOnChange}\n onBlur={(e) => {\n if (onBlur) onBlur(e)\n }}\n value={value || \"\"}\n { ...(onRender && { renderValue: (selected) => onRenderHandler(selected) }) }\n IconComponent={ArrowIcon}\n onOpen={() => setIsSelectOpen(true)}\n onClose={() => setIsSelectOpen(false)}\n onMouseEnter={() => onMouseEnterItem()}\n onMouseLeave={() => setTooltipOpen(false)}\n onClick={() => setTooltipOpen(false)}\n >\n {placeholder ? (\n <MenuItem classes={{ root: `${itemRootClass ?? useClasses.itemRoot}`, }} value=\"\" disabled>\n {placeholder}\n </MenuItem>\n ) : null}\n {items.map((item: SelectItem | string | number, index) =>\n typeof item === \"object\" ? (\n item.isGroup ? (\n <MenuItem\n key={`option-${item.key}-${index}`}\n classes={{ root: useClasses.group }}\n disabled\n >\n {item.value}\n </MenuItem>\n ) : (\n <MenuItem\n classes={{\n root: `${itemRootClass ?? useClasses.itemRoot}`,\n selected: useClasses.itemSelected,\n }}\n key={`option-${item.key}-${index}`}\n value={item.key}\n >\n {item.value}\n </MenuItem>\n )\n ) : (\n <MenuItem\n classes={{\n root: `${itemRootClass ?? useClasses.itemRoot}`,\n selected: useClasses.itemSelected,\n }}\n key={item || index}\n value={item}\n >\n {item}\n </MenuItem>\n )\n )}\n </MuiSelect>\n </Tooltip>\n );\n};\n\nexport default Select;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number) =>\n makeStyles((theme) => ({\n root: {},\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n },\n input: {\n backgroundColor: theme.colors.grey1,\n height: 40,\n padding: \"0px 0px 0px 12px\",\n fontSize: 14,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: width || 370,\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"0px 0px 0px 12px\",\n width: width || 370,\n },\n inputDisabled: {\n color: \"#676767\",\n },\n inputError: {\n color: \"#f15857\",\n border: \"solid 1px #f15857\",\n },\n }));\n\nexport default useStyles;\n","export enum PaymentEditionType {\n AddAmount = 1,\n SubtractAmount = 2,\n}","import React, { useState } from \"react\";\n\nimport DateFnsUtils from \"@date-io/date-fns\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\nimport {\n MuiPickersUtilsProvider,\n KeyboardDatePicker,\n} from \"@material-ui/pickers\";\n\nimport useStyles from \"./css\";\nimport { InputDateWithLabelProps } from \"./props\";\nimport { CalendarIcon } from \"../../../assets/icons\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nconst InputDateWithLabel = (props: InputDateWithLabelProps) => {\n const {\n id,\n label,\n name,\n value,\n isValid,\n placeholder,\n width,\n minDate,\n maxDate,\n onChange,\n onKeyPress,\n disabled\n } = props;\n const classes = useStyles(width)();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n \n const getId = (): string => {\n if (id) {\n return id;\n }\n\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(\n /[xy]/g,\n function (c) {\n var r = (Math.random() * 16) | 0,\n v = c === \"x\" ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n }\n );\n };\n\n const LabelComponent = label;\n\n const [inputId] = useState<string>(id || getId());\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n const handleOnKeyPress = (event: any) => {\n if (onKeyPress) {\n onKeyPress(event);\n }\n };\n\n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n\n if (isValid() === undefined) {\n return false;\n }\n\n return !isValid();\n };\n\n const getLocale = (): any => {\n switch (localeApp) {\n case \"es\":\n return esLocale;\n\n default:\n return enLocale;\n }\n };\n\n return (\n <div className={classes.root}>\n <label htmlFor={inputId} className={classes.label}>\n {typeof label === \"string\" ? label : <LabelComponent />}\n </label>\n <MuiPickersUtilsProvider utils={DateFnsUtils} locale={getLocale()}>\n <KeyboardDatePicker\n id={id}\n name={name}\n placeholder={placeholder}\n autoOk\n variant=\"inline\"\n format=\"dd/MM/yy\"\n InputProps={{\n disableUnderline: true,\n className: `${classes.input} ${\n isError() ? classes.inputError : \"\"\n }`,\n classes: { input: classes.inputText },\n }}\n margin=\"none\"\n value={value || null}\n minDate={minDate}\n maxDate={maxDate}\n onChange={handleOnChange}\n onKeyPress={handleOnKeyPress}\n helperText={null}\n keyboardIcon={<CalendarIcon style={{ color: \"#6462F3\" }} />}\n disabled={disabled ?? false}\n />\n </MuiPickersUtilsProvider>\n </div>\n );\n};\n\nexport default InputDateWithLabel;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n marginTop: 24,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n minHeight: 288,\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n margin: \"24px 0px 8px 0px\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteContact: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n accordion: {\n boxShadow: \"none\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: theme.colors.grey2,\n borderRadius: 4,\n overflow: \"hidden\",\n marginBottom: 16\n },\n accordionSummary: {\n backgroundColor: \"#f6f6f6\",\n width: \"100%\",\n minHeight: \"46px !important\",\n \"& >div:first-child\": {\n margin: 0\n }\n },\n accordionTitle: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey5,\n position: \"relative\",\n top: 5,\n left: 10\n },\n addButton: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n border: `1px solid ${theme.colors.clearMain}`,\n justifyContent: \"space-around\",\n \"&.Mui-disabled\": {\n color: theme.colors.clearMain,\n },\n \"& svg\": {\n marginRight: 10\n }\n },\n separatorWithoutLine: {\n marginBottom: 10,\n },\n accordionDetails: {\n display: \"block\",\n padding: \"10px 15px 15px\"\n }\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n controlLabel: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n inputWithLabel: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n \"&:not(:first-child)\": {\n marginTop: 16\n }\n },\n dot: {\n ...theme.typography.buttons,\n color: theme.colors.clearMain\n },\n itemRoot: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n },\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { AppointmentPaymentPartProps } from \"./props\";\nimport useStyles from \"./css\";\nimport Typography from \"@material-ui/core/Typography\";\nimport InputCurrency from \"../../common/InputCurrency\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport { AppointmentPaymentPartEntity } from \"../../../models/appointment-payment-part-entity\";\nimport { PaymentMethodType } from \"../../../models/enums/payment-method-type\";\nimport SelectKey from \"../../common/SelectKey\";\nimport { PaymentEditionType } from \"../../../models/enums/payment-edition-type\";\nimport { BillIcon } from \"../../../assets/icons\";\n\nexport default function AppointmentPaymentPart(props: AppointmentPaymentPartProps) {\n\n const { paymentPart, onChange, editionType, paymentMethods, excludedPaymentMethodTypes } = props;\n\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const currencyTemplate: string = accountSettings.currencyTemplate;\n \n const allowedPaymentMethods = paymentMethods.filter(pm => !excludedPaymentMethodTypes.some(t => pm.key === t && pm.key !== paymentPart.paymentMethod));\n\n function setPaymentPart(part: AppointmentPaymentPartEntity) {\n onChange(part)\n }\n\n function setPaymentAmount(amountPaid: number) {\n if (amountPaid >= 0) {\n setPaymentPart({ ...paymentPart, amountPaid })\n }\n }\n \n function setPaymentMethod(paymentMethod: PaymentMethodType) {\n setPaymentPart({ ...paymentPart, paymentMethod })\n }\n \n function getAmountPaidTitle() : string {\n switch (editionType) {\n case PaymentEditionType.AddAmount:\n return t(\"Add amount\");\n case PaymentEditionType.SubtractAmount:\n return t(\"Subtract amount\");\n default:\n return t(\"Amount paid\");\n }\n }\n\n return (\n <>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {getAmountPaidTitle()}\n </Typography>\n <span className={classes.dot}> *</span>\n </div>\n <InputCurrency\n value={paymentPart.amountPaid}\n setValue={setPaymentAmount}\n valueTemplate={currencyTemplate}\n width={\"100%\"}\n isZeroAllowed={true}\n isValid={() => {\n return (paymentPart.amountPaid >= 0);\n }}\n />\n </div>\n \n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Payment method\")}\n </Typography>\n <span className={classes.dot}> *</span>\n </div>\n <SelectKey\n value={paymentPart.paymentMethod}\n setValue={setPaymentMethod}\n itemRootClass={classes.itemRoot}\n placeholder={t(\"Select a payment method\")}\n items={allowedPaymentMethods}\n width={\"100%\"}\n arrowIcon={<BillIcon />}\n />\n </div>\n </>\n );\n}","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { DeleteIcon, CrossIcon, TrashIcon, ArrowDownIcon, BillsIcon, PlusIcon } from \"../../../assets/icons\";\n\nimport { Accordion, AccordionDetails, AccordionSummary } from \"@material-ui/core\";\n\nimport { AppointmentPaymentPartsProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { AppointmentPaymentPartEntity } from \"../../../models/appointment-payment-part-entity\";\nimport AppointmentPaymentPart from \"../AppointmentPaymentPart\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\n\nexport default function AppointmentPaymentParts(props: AppointmentPaymentPartsProps) {\n \n const { parts, onDelete, onChange, onAdd } = props;\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const paymentMethods = accountSettings.paymentMethods;\n const excludedPaymentMethodTypes = parts.filter(p => p.paymentMethod !== null).map(p => p.paymentMethod!);\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n const [openModal, setOpenModal] = useState<boolean>(false);\n const [part, setPart] = useState<AppointmentPaymentPartEntity>();\n const [indexPart, setIndexPart] = useState<number>(0);\n const [expandedAccordionIndex, setExpandedAccordionIndex] = useState<number>(0);\n\n const handleDeletePart = (e: any, index: number) => {\n e.preventDefault();\n e.stopPropagation();\n const part = parts.find((part, idx) => idx === index);\n setPart(part);\n setIndexPart(index);\n setOpenModal(true);\n };\n\n const removePart = () => {\n onDelete(indexPart);\n setOpenModal(false);\n };\n\n const handleOnChange =\n (index: number) => (part: AppointmentPaymentPartEntity) => {\n setExpandedAccordionIndex(index);\n onChange(index, part);\n };\n \n function handleAccordionChange(index: number) {\n const newIndex = expandedAccordionIndex === index ? -1 : index;\n setExpandedAccordionIndex(newIndex);\n }\n\n return (\n <div className={classes.root}>\n {parts.map((part, index) => (\n <Accordion\n className={classes.accordion}\n expanded={expandedAccordionIndex === index}\n onChange={() => handleAccordionChange(index)}\n >\n <AccordionSummary\n className={classes.accordionSummary}\n expandIcon={<ArrowDownIcon style={{height: 15, width: 15, color: \"#5c6477\"}} />}\n aria-controls=\"panel1a-content\"\n id=\"panel1a-header\"\n >\n <div style={{width: 25}}>\n {\n index > 0 ?\n <span onClick={(e) => handleDeletePart(e, index)}>\n <DeleteIcon />\n </span>\n :\n <span>\n <BillsIcon />\n </span>\n }\n </div>\n <Typography className={classes.accordionTitle}>\n {`${t(\"Payment method\")} ${index+1}` }\n </Typography>\n </AccordionSummary>\n <AccordionDetails\n className={classes.accordionDetails}\n >\n <AppointmentPaymentPart\n paymentPart={part}\n onChange={handleOnChange(index)}\n editionType={null}\n paymentMethods={paymentMethods}\n excludedPaymentMethodTypes={excludedPaymentMethodTypes}\n />\n </AccordionDetails>\n </Accordion>\n ))}\n \n {paymentMethods.length > excludedPaymentMethodTypes.length &&\n <Button\n className={classes.addButton}\n onClick={onAdd}\n >\n <PlusIcon/>\n {t(\"Add another method\")}\n </Button>\n }\n <div className={classes.separatorWithoutLine}></div>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={() => {\n setOpenModal(false);\n }}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <span\n className={classes.closeButton}\n onClick={() => {\n setOpenModal(false);\n }}\n >\n <CrossIcon />\n </span>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div className={classes.modalCenter}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Do you want to remove this payment method?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {/*{part?.name || \"--\"}*/}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={() => {\n setOpenModal(false);\n }}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.deleteContact}`}\n onClick={removePart}\n >\n {t(\"Remove\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n accordion: {\n boxShadow: \"none\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: theme.colors.grey2,\n borderRadius: 4\n },\n accordionSummary: {\n backgroundColor: \"#f6f6f6\",\n width: \"100%\",\n minHeight: \"46px !important\",\n \"& >div:first-child\": {\n margin: 0\n }\n },\n accordionTitle: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey5,\n position: \"relative\",\n top: 5,\n left: 10\n },\n accordionDetails: {\n display: \"block\",\n padding: \"10px 15px 15px\"\n }\n}));\n\nexport default useStyles;\n","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { BillsIcon } from \"../../../assets/icons\";\n\nimport { Accordion, AccordionDetails, AccordionSummary } from \"@material-ui/core\";\n\nimport { AppointmentPaymentPartsEditProps } from \"./props\";\nimport useStyles from \"./css\";\nimport AppointmentPaymentPart from \"../AppointmentPaymentPart\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\n\nexport default function AppointmentPaymentPartsEdit(props: AppointmentPaymentPartsEditProps) {\n \n const { part, onChange, editionType } = props;\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const paymentMethods = accountSettings.paymentMethods;\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n return (\n <Accordion\n className={classes.accordion}\n expanded={true}\n >\n <AccordionSummary\n className={classes.accordionSummary}\n >\n <div style={{width: 25}}>\n <span>\n <BillsIcon />\n </span>\n </div>\n <Typography className={classes.accordionTitle}>\n {t(\"Payment method\")}\n </Typography>\n </AccordionSummary>\n <AccordionDetails\n className={classes.accordionDetails}\n >\n <AppointmentPaymentPart\n paymentPart={part}\n onChange={onChange}\n editionType={editionType}\n paymentMethods={paymentMethods}\n excludedPaymentMethodTypes={[]}\n />\n </AccordionDetails>\n </Accordion>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings, selectCashRegisterOpen, selectUserInfo } from \"../../../redux/store\";\n\nimport { Button, Drawer, LinearProgress, Tab, Tabs } from \"@material-ui/core\";\n\nimport { AppointmentPaymentSidebarProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { CrossIcon } from \"../../../assets/icons\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { PaymentMethodType } from \"../../../models/enums/payment-method-type\";\nimport SelectKey from \"../../common/SelectKey\";\nimport Textarea from \"../../common/Textarea\";\nimport InputCurrency from \"../../common/InputCurrency\";\nimport InputEditableItem from \"../../common/InputEditableItem\";\nimport InputEditableWithSelectItem from \"../../common/InputEditableWithSelectItem\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport { TabContext, TabPanel } from \"@material-ui/lab\";\nimport InputDateWithLabel from \"../../common/InputDateWithLabel\";\nimport moment from \"moment\";\nimport { SelectItem } from \"../../common/SelectWithLabel\";\nimport { DiscountType } from \"../../../models/enums/discount-type\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { PaymentEditionType } from \"../../../models/enums/payment-edition-type\";\nimport AppointmentPaymentParts from \"../AppointmentPaymentParts\";\nimport { AppointmentPaymentPartEntity } from \"../../../models/appointment-payment-part-entity\";\nimport { AppointmentPaymentEntity } from \"../../../models/appointment-payment-entity\";\nimport AppointmentPaymentPartsEdit from \"../AppointmentPaymentPartsEdit\";\nimport { AppointmentPaymentChangeRecord } from \"../../../models/appointment-payment-change-record\";\nimport { AppointmentPaymentValues } from \"../../../models/appointment-payment-values\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\n\n\nexport default function AppointmentPaymentSidebar(props: AppointmentPaymentSidebarProps) {\n \n const { mode,\n isOpen,\n setOpen,\n userName,\n paymentEntity,\n setPaymentEntity,\n formData,\n onSave,\n onClose,\n isUnchanged,\n recurredAppointmentOrder,\n recurredAppointmentsCount,\n totalRecurringApptPriceExcludingSelected,\n paidPreviously\n } = props;\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const { enqueueAlert } = alertsActions;\n const currencyTemplate: string = accountSettings.currencyTemplate;\n \n const { t } = useTranslation(\"general\");\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const classes = useStyles();\n const newDate = new Date();\n const firstDayOfCurrentYear = new Date(newDate.getFullYear(), 1, 1);\n const firstDayOfNextYear = new Date(newDate.getFullYear(), 11, 31);\n const dateAndTimeFormat = localeApp === \"en\" ? \"MM/DD/YYYY HH:mm a\" : \"DD/MM/YYYY HH:mm a\";\n \n const editionTypes = [\n { key: PaymentEditionType.AddAmount, value: t(\"Add amount\") },\n { key: PaymentEditionType.SubtractAmount, value: t(\"Subtract amount\"), disabled: !paymentEntity.isEditable }\n ];\n \n const [servicesValid, setServicesValid] = useState<boolean[]>(paymentEntity.services.map(x => true));\n const [activeTab, setActiveTab] = useState<\"payment\" | \"history\">(\"payment\");\n \n const canRegisterPayments = useAppSelector(selectUserInfo).canRegisterPayments;\n const cashRegisterIsOpen = useAppSelector(selectCashRegisterOpen);\n \n const templatedValue = useCurrencyValueTemplate(currencyTemplate);\n const dispatch = useAppDispatch();\n \n useEffect(() => {\n if (paymentEntity?.services) {\n setServicesValid(paymentEntity.services.map(x => true))\n }\n }, [paymentEntity?.services])\n \n function setPaymentDate(date: Date) {\n setPaymentEntity({ ...paymentEntity, date })\n }\n \n function getCurrencySign() {\n return currencyTemplate.replace(\"{0}\", \"\");\n }\n \n function setEditingPart(editingPart: AppointmentPaymentPartEntity) {\n setPaymentEntity({ ...paymentEntity, editingPart })\n }\n \n function setEditionType(editionType: PaymentEditionType) {\n const editingPart = new AppointmentPaymentPartEntity();\n setPaymentEntity({ ...paymentEntity, editionType, editingPart })\n }\n \n function setPaymentDiscount(discountAmount: number, discountType: DiscountType, index: number) {\n const newServices = [...paymentEntity.services];\n newServices[index] = { ...newServices[index], discountAmount };\n newServices[index] = { ...newServices[index], discountType };\n setPaymentEntity({ ...paymentEntity, services: newServices })\n }\n \n function setPaymentNotes(event: any) {\n const notes = event.target.value;\n setPaymentEntity({ ...paymentEntity, notes })\n }\n \n function setPaymentServicePrice(index: number, price: number) {\n const newServices = [...paymentEntity.services];\n newServices[index] = { ...newServices[index], price };\n setPaymentEntity({ ...paymentEntity, services: newServices })\n }\n \n function countTotalToBePaid(): number {\n let total = 0;\n paymentEntity.services?.map(service => {\n if (service.discountType === DiscountType.Percentage) {\n total += service.price - (service.discountAmount / 100) * service.price;\n } else {\n total += service.price - service.discountAmount;\n }\n });\n if (total <= 0) return 0;\n return total + totalRecurringApptPriceExcludingSelected;\n }\n \n const totalToBePaid = countTotalToBePaid()\n \n function countPaidAmount(): number {\n const partsSum = paymentEntity.parts?.map(x => x.amountPaid).reduce((sum, x) => sum + x) || 0;\n const editingAmount = (paymentEntity.editingPart?.amountPaid || 0)\n switch (paymentEntity.editionType) {\n case PaymentEditionType.AddAmount: \n return paidPreviously + editingAmount;\n case PaymentEditionType.SubtractAmount:\n const amount = paidPreviously - editingAmount;\n return amount <= 0 ? 0 : amount;\n default:\n return partsSum;\n }\n }\n \n const paidAmount = countPaidAmount()\n \n function countPendingToBePaid(): number {\n const toBePaid = paidAmount < 0 \n ? totalToBePaid \n : totalToBePaid - paidAmount;\n if (toBePaid <= 0) return 0;\n return toBePaid;\n }\n \n const pendingToBePaid = countPendingToBePaid()\n \n function countChange(): number {\n const change = paidAmount - totalToBePaid;\n if (change <= 0) return 0;\n return change;\n }\n \n const change = countChange();\n \n const paymentActualProgress = (paidAmount / totalToBePaid) * 100;\n const paymentProgress = paymentActualProgress > 100 ? 100 : paymentActualProgress;\n \n async function handleSaveButtonClick() {\n let doCancel = false;\n paymentEntity.services.forEach((service) => {\n if (service.discountType === DiscountType.Value && service.discountAmount > service.price) {\n displayAlert(t(\"The discount must not be greater than the total to be paid for the service\"));\n doCancel = true;\n return;\n }\n });\n if (doCancel) return;\n paymentEntity.services.forEach((service) => {\n if (service.discountType === DiscountType.Percentage && service.discountAmount > 100) {\n displayAlert(t(\"It is not possible to add more than 100% discount\"));\n doCancel = true;\n return;\n }\n });\n if (doCancel) return;\n if (mode === \"edit\" && paymentEntity.editionType === PaymentEditionType.SubtractAmount && paidPreviously - (paymentEntity.editingPart?.amountPaid || 0) < 0) {\n displayAlert(t(\"It is not possible to subtract an amount greater than the amount already paid.\"));\n return;\n }\n await onSave(totalToBePaid).then(setActiveTabToHistory);\n }\n \n function handleCloseDrawer() {\n drawerOnClose()\n }\n \n function drawerOnClose() {\n setOpen(false);\n if (onClose) onClose();\n setActiveTab(\"payment\");\n }\n \n function setActiveTabToHistory() {\n setActiveTab(\"history\");\n }\n \n function handleTabChange(event: any, newValue: \"payment\" | \"history\") {\n setActiveTab(newValue);\n }\n \n function setServiceValid(value: boolean, index: number) {\n const newValid = [...servicesValid];\n newValid[index] = value;\n setServicesValid(newValid)\n }\n \n function getSaveButtonTitle() {\n switch (mode) {\n case \"new\":\n return t(\"Register payment\")\n case \"edit\":\n return t(\"Save payment details\")\n }\n }\n \n function displayAlert(message: string) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: null,\n description: message,\n })\n )\n }\n \n function isSaveButtonDisabled() {\n return !servicesValid.every(x => x) ||\n paymentEntity.parts.some(x => x.paymentMethod === null || !(x.amountPaid !== 0)) ||\n (mode === \"edit\" && (isUnchanged() || paymentEntity.editionType === null || !((paymentEntity.editingPart?.amountPaid || 0) !== 0 && paymentEntity.editingPart?.paymentMethod !== null)));\n }\n \n const currencySelectList: SelectItem[] = [\n { key: DiscountType.Value, value: getCurrencySign() },\n { key: DiscountType.Percentage, value: \"%\" }];\n \n function getPaymentMethodName(paymentMethod: PaymentMethodType) {\n switch (paymentMethod) {\n case PaymentMethodType.Cash:\n return t(\"Cash\")\n case PaymentMethodType.CreditCard:\n return t(\"Credit/debit card\")\n case PaymentMethodType.BankTransfer:\n return t(\"Bank transfer\")\n case PaymentMethodType.Oxxo:\n return t(\"Oxxo\")\n case PaymentMethodType.MercadoPago:\n return t(\"Mercado Pago\")\n }\n }\n \n function formatChangedField(changedField: string): string {\n switch (changedField) {\n case \"Date\":\n return t(changedField);\n case \"Payment method\":\n return t(changedField);\n case \"Paid amount\":\n return t(changedField);\n case \"Discount\":\n return t(changedField);\n case \"Total paid\":\n return t(changedField);\n case \"Notes\":\n return t(\"Comments\");\n case \"Discount type\":\n return t(changedField);\n default:\n return t(\"Price of\") + \": \" + changedField;\n }\n }\n \n function formatChangeRecordField(fieldValue: string, changedField: string) {\n switch (changedField) {\n case \"Date\":\n return moment(fieldValue).format(dateAndTimeFormat);\n case \"Payment method\":\n return fieldValue.split(', ').map(x => t(x)).join(', ');\n case \"Paid amount\":\n return templatedValue(parseFloat(fieldValue));\n case \"Discount\":\n return templatedValue(parseFloat(fieldValue));\n case \"Total paid\":\n return templatedValue(parseFloat(fieldValue));\n case \"Notes\":\n return fieldValue;\n case \"Discount type\":\n return t(fieldValue);\n default: {\n if (!isNaN(parseFloat(fieldValue))) {\n return templatedValue(parseFloat(fieldValue));\n }\n return fieldValue;\n }\n }\n }\n \n function handleDeletePart(index: number) {\n const arrParts = paymentEntity!.parts!.filter((part, idx) => idx !== index);\n setParts(arrParts);\n }\n \n function handleOnChangePart(index: number, part: AppointmentPaymentPartEntity) {\n let arrParts = [...paymentEntity!.parts!];\n arrParts[index] = part;\n setParts(arrParts)\n }\n \n function setParts(parts: AppointmentPaymentPartEntity[]) {\n setPaymentEntity(new AppointmentPaymentEntity({ ...paymentEntity, parts }))\n }\n \n function handleAddPart() {\n setParts([...paymentEntity?.parts ?? [], new AppointmentPaymentPartEntity()]);\n }\n \n function lpad(value: number, padding: number) {\n var zeroes = new Array(padding + 1).join(\"0\");\n return (zeroes + value).slice(-padding);\n }\n \n function displayFriendlyId(friendlyId: any) {\n return friendlyId < 1000 ? lpad(friendlyId, 4) : friendlyId\n }\n \n const historyData = () => {\n const paymentValues = formData.paymentValues.map(x => {return {\n date: new Date(x.date),\n data: x,\n type: \"paymentValues\"\n }});\n const changeRecords = formData.changeRecords.map(x => {return {\n date: new Date(x.date),\n data: x,\n type: \"changeRecords\"\n }});\n // @ts-ignore\n let data = paymentValues.concat(changeRecords);\n data.sort((a,b)=>b.date.getTime()-a.date.getTime());\n return data;\n }\n \n const RegisterPaymentChip = () =>\n <div className={classes.chip}>\n {t(\"Payment register\")}\n </div>\n \n const CrossCloseButton = () =>\n <div className={classes.closeIcon}>\n <CrossIcon\n style={{\n width: 16,\n height: 16\n }}\n viewBox=\"0 0 16 16\"\n onClick={handleCloseDrawer}\n />\n </div>\n \n const TabsHeader = () =>\n <TabContext\n value={activeTab}\n >\n <Tabs\n className={classes.tabs}\n value={activeTab}\n onChange={handleTabChange}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n >\n <Tab\n className={classes.tab}\n label={t(\"Payment detail\")}\n value=\"payment\"\n />\n <Tab\n className={classes.tab}\n label={t(\"Movements history\")}\n value=\"history\"\n />\n </Tabs>\n </TabContext>\n \n const ChargingUserHeader = () =>\n <div className={classes.newHeader}>\n {mode === \"new\" && <span className={classes.headerTitle}>{t(\"Register payment\")}</span>}\n <span className={classes.headerChargingInfo}>{t(\"Charging user:\")}<span className={classes.headerChargingUserName}>{userName}</span></span>\n {!!(paymentEntity?.friendlyId)\n ? <span className={classes.headerChargingInfo}>{t(\"Payment ID:\")}<span className={classes.headerChargingPaymentId}>{displayFriendlyId(paymentEntity.friendlyId)}</span></span>\n : null\n }\n <CrossCloseButton/>\n </div>\n \n const PaymentProgressBar = () => \n <div className={classes.paymentProgressBar}>\n <LinearProgress \n variant=\"determinate\" \n value={paymentProgress} \n classes={{\n barColorPrimary: classes.progressBarPaid,\n colorPrimary: classes.progressBarUnpaid\n }}\n />\n <div className={classes.paymentProgressBarLegend}>\n <div className={classes.paymentProgressBarLegendItem}>\n <div className={`${classes.paymentProgressBarLegendIcon} ${classes.paidIcon}`} />\n <span className={classes.paymentProgressBarLegendText}>{t(\"Paid\")} <strong>{templatedValue(paidAmount > totalToBePaid ? totalToBePaid : paidAmount)}</strong></span>\n </div>\n <div className={classes.paymentProgressBarLegendItem}>\n <div className={`${classes.paymentProgressBarLegendIcon} ${classes.unpaidIcon}`} />\n <span className={classes.paymentProgressBarLegendText}>{t(\"Unpaid\")} <strong>{templatedValue(countPendingToBePaid())}</strong></span>\n </div>\n </div>\n </div>\n \n const RegisterPaymentButton = () =>\n <div className={classes.footer}>\n <ButtonWithSpinner\n width={368}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={getSaveButtonTitle()}\n onClick={async () => { await handleSaveButtonClick() }}\n disabled={isSaveButtonDisabled()}\n />\n </div>\n \n const paidWithList = () => {\n let parts = paymentEntity.parts.filter(p => p.paymentMethod !== null && p.amountPaid).map(part =>\n ({\n paymentMethod: part.paymentMethod,\n amountPaid: part.amountPaid\n }));\n \n if (mode === \"edit\" &&\n paymentEntity.editionType !== null &&\n (paymentEntity.editingPart?.amountPaid || 0) !== 0 &&\n paymentEntity.editingPart?.paymentMethod !== null) {\n const editionSign = paymentEntity.editionType === PaymentEditionType.AddAmount ? 1 : -1;\n const part = parts.find(x => x.paymentMethod === paymentEntity.editingPart!.paymentMethod && Math.sign(x.amountPaid) === editionSign);\n if (part) { // part has the same paymentMethod and amountPaid sign as editingPart\n part.amountPaid += paymentEntity.editingPart!.amountPaid * editionSign;\n } else {\n parts.push({\n paymentMethod: paymentEntity.editingPart!.paymentMethod,\n amountPaid: paymentEntity.editingPart!.amountPaid * editionSign\n })\n }\n }\n \n return parts.sort((a, b) => {\n if (Math.sign(a.amountPaid) < Math.sign(b.amountPaid)) {\n return 1;\n } else if (Math.sign(a.amountPaid) > Math.sign(b.amountPaid)) {\n return -1;\n }\n \n if (a.paymentMethod! < b.paymentMethod!) {\n return -1;\n } else if (a.paymentMethod! > b.paymentMethod!) {\n return 1\n } else {\n return 0;\n }\n });\n }\n \n const PaymentContent = () =>\n <>\n <div>\n <ChargingUserHeader />\n </div>\n <div className={classes.divider} />\n <PaymentProgressBar />\n \n {mode === \"new\" &&\n <AppointmentPaymentParts\n parts={paymentEntity.parts}\n onChange={handleOnChangePart}\n onDelete={handleDeletePart}\n onAdd={handleAddPart}/>\n }\n {\n mode === \"edit\" &&\n <>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Payment edition\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <SelectKey\n value={paymentEntity.editionType}\n setValue={setEditionType}\n itemRootClass={classes.itemRoot}\n placeholder={t(\"Select a type\")}\n items={editionTypes}\n disabled={!cashRegisterIsOpen}\n />\n </div>\n {paymentEntity.editingPart !== null && paymentEntity.editionType !== null &&\n <AppointmentPaymentPartsEdit\n part={paymentEntity.editingPart!}\n onChange={part => setEditingPart(part)}\n editionType={paymentEntity.editionType}\n />\n }\n {paymentEntity.editionType === null &&\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Amount paid\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <InputCurrency\n value={paidAmount}\n setValue={()=>{}}\n valueTemplate={currencyTemplate}\n isZeroAllowed\n disabled={true}\n />\n </div>\n }\n </>\n }\n \n <div className={classes.inputWithLabel} style={{marginTop: 21}}>\n \n <InputDateWithLabel\n label={() =>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Payment date\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>}\n placeholder={t(\"dd/mm/yy\")}\n format={\"dd/MM/yyyy\"}\n value={paymentEntity.date}\n onChange={setPaymentDate}\n inputTextClass={classes.controlText}\n iconColor={\"#5C6477\"}\n width={368}\n minDate={firstDayOfCurrentYear}\n maxDate={firstDayOfNextYear}\n disabled={!cashRegisterIsOpen}\n />\n </div>\n \n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Comments\")}\n </Typography>\n </div>\n <Textarea\n name=\"notes\"\n inputClass={classes.textArea}\n placeholder={t(\"Write your comments here\")}\n maxLength={180}\n value={paymentEntity.notes}\n onChange={setPaymentNotes}\n width={368}\n disabled={!cashRegisterIsOpen}\n />\n </div>\n \n <div className={`${classes.divider} ${classes.marginTopBottom}`}/>\n \n <div className={classes.servicesDetail}>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailHeader} ${classes.servicesDetailColumn}`}>{t(\"Detail\")}</div>\n <div className={`${classes.servicesDetailHeader} ${classes.servicesDetailColumn}`}>{t(\"Price\")}</div>\n </div>\n {\n paymentEntity.services.map((service, index) =>\n <>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailColumn} ${classes.servicesDetailServiceBlock}`}>\n <div className={`${classes.servicesDetailText}`}>{service.categoryName + \" - \" + service.name}</div>\n <div className={`${classes.servicesDetailSubheader}`}>{t(\"Service\")}</div>\n </div>\n <InputEditableItem\n value={service.price}\n setValue={(price: number) => setPaymentServicePrice(index, price)}\n valueTemplate={currencyTemplate}\n setValid={(value: boolean) => setServiceValid(value, index)}\n disabled={!cashRegisterIsOpen}\n />\n </div>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailDiscount} ${classes.servicesDetailColumn}`}>{t(\"Discount\")}</div>\n <div className={classes.servicesDetailColumn}>\n <InputEditableWithSelectItem\n value={service.discountAmount}\n selectValue={service.discountType}\n setValue={(amount, type) => setPaymentDiscount(amount, type, index)}\n valueTemplate={\"-\" + currencyTemplate}\n color={\"#6462F3\"}\n selectItems={currencySelectList}\n subTotal={service.price}\n maxValue={{\n maxValue: service.price\n }}\n disabled={!cashRegisterIsOpen}\n />\n </div>\n </div>\n <div className={classes.servicesDetailDivider}/>\n </>\n )\n }\n {recurredAppointmentOrder && recurredAppointmentsCount && <>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailText} ${classes.servicesDetailColumn}`}>\n {t(\"Recurring appointment\")}\n </div>\n <div className={classes.servicesDetailValue}>\n {`${recurredAppointmentOrder} ${t(\"of\")} ${recurredAppointmentsCount}`}\n </div>\n </div>\n <div className={classes.servicesDetailDivider}/>\n </>}\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailTotal} ${classes.servicesDetailColumn}`}>\n {t(\"Total to be paid\")}\n </div>\n <div className={`${classes.servicesDetailValue} ${classes.greenText} ${classes.servicesDetailColumn}`}>{templatedValue(totalToBePaid)}</div>\n </div>\n {paidWithList().map(part =>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailPaidWith} ${classes.servicesDetailColumn}`}>\n {part.amountPaid > 0 &&\n t(\"Paid with\")\n }\n {part.amountPaid < 0 &&\n t(\"Subtracted with\")\n }\n  \n <span style={{textTransform: \"lowercase\"}}>{getPaymentMethodName(part.paymentMethod!)}</span>\n </div>\n \n <div className={`${classes.servicesDetailValue} ${classes.servicesDetailColumn}`}>{templatedValue(part.amountPaid)}</div>\n </div>\n )}\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailText} ${classes.servicesDetailColumn}`}>\n {t(\"Amount paid\")}\n </div>\n <div className={`${classes.servicesDetailValue} ${classes.servicesDetailColumn}`}>{templatedValue(paidAmount)}</div>\n </div>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailText} ${classes.servicesDetailColumn}`}>\n {t(\"Pending to be paid\")}\n </div>\n <div className={`${classes.servicesDetailValue} ${classes.servicesDetailColumn}`}>{templatedValue(pendingToBePaid)}</div>\n </div>\n <div className={classes.servicesDetailRow}>\n <div className={`${classes.servicesDetailText} ${classes.servicesDetailColumn}`}>{t(\"Change\")}</div>\n <div className={`${classes.servicesDetailValue} ${classes.servicesDetailColumn}`}>{templatedValue(change)}</div>\n </div>\n </div>\n \n {\n canRegisterPayments && cashRegisterIsOpen &&\n <RegisterPaymentButton/>\n }\n </>\n \n const HistoryContent = () =>\n <>\n <div>\n <ChargingUserHeader/>\n </div>\n {historyData().map((data, index) => {\n if (data.type === \"paymentValues\") {\n const paymentValues: AppointmentPaymentValues = data.data;\n const isFirstPaymentHistoryBlock = index === historyData().length - 1;\n return <>\n <div className={classes.divider}/>\n <div className={classes.initialValuesBlock}>\n <RegisterPaymentChip/>\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"User\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{paymentValues.userName}</div>\n </div>\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Payment date\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{moment(paymentValues.date).format(dateAndTimeFormat)}</div>\n </div>\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Payment method\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{getPaymentMethodName(paymentValues.paymentMethod)}</div>\n </div>\n {isFirstPaymentHistoryBlock &&\n <>\n {recurredAppointmentOrder && recurredAppointmentsCount &&\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Recurring appointments\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{recurredAppointmentsCount}</div>\n </div>\n }\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Total to be paid\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{templatedValue(totalToBePaid)}</div>\n </div>\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Discount\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{`-${templatedValue(paymentValues.discount)}`}</div>\n </div>\n </>\n }\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>\n {\n (index === formData.paymentValues.length-1 ? t(\"Amount paid\") : paymentValues.amountPaid >= 0 ? t(\"Add amount\") : t(\"Subtract amount\"))\n + \":\"\n }\n </div>\n <div className={classes.historyRightColumn}>{templatedValue(paymentValues.amountPaid)}</div>\n </div>\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Pending to be paid\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{templatedValue(pendingToBePaid > 0 ? pendingToBePaid : 0)}</div>\n </div>\n {/*{*/}\n {/* paymentValues.amountPaid > prevPendingToBePaid &&*/}\n {/* <div className={classes.initialValuesRow}>*/}\n {/* <div className={classes.initialValuesLeftColumn}>{t(\"Change\") + \":\"}</div>*/}\n {/* <div className={classes.historyRightColumn}>{templatedValue(paymentValues.amountPaid - prevPendingToBePaid)}</div>*/}\n {/* </div>*/}\n {/*}*/}\n <div className={classes.initialValuesRow}>\n <div className={classes.initialValuesLeftColumn}>{t(\"Comments\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{ paymentValues.notes !== null && paymentValues.notes.trim() !== \"\" ? paymentValues.notes : \"--\" }</div>\n </div>\n </div>\n </>\n } else {\n // @ts-ignore\n const changeRecord: AppointmentPaymentChangeRecord = data.data;\n return <>\n <div className={classes.divider}/>\n <div className={classes.changeRecords}>\n <div className={classes.changeRecordBlock}>\n <div className={classes.changeRecordRow}>\n <div className={classes.changeRecordLeftColumn}>{t(\"User\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{changeRecord.chargingUserName}</div>\n </div>\n <div className={classes.changeRecordRow}>\n <div className={classes.changeRecordLeftColumn}>{t(\"Changed\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{formatChangedField(changeRecord.changedField)}</div>\n </div>\n <div className={classes.changeRecordRow}>\n <div className={classes.changeRecordLeftColumn}>{t(\"Date and time\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{moment(changeRecord.date).format(dateAndTimeFormat)}</div>\n </div>\n <div className={classes.changeRecordRow}>\n <div className={classes.changeRecordLeftColumn}>{t(\"From\") + \":\"}</div>\n <div className={classes.historyRightColumnStrike}><s>{formatChangeRecordField(changeRecord.from, changeRecord.changedField)}</s></div>\n </div>\n <div className={classes.changeRecordRow}>\n <div className={classes.changeRecordLeftColumn}>{t(\"To\") + \":\"}</div>\n <div className={classes.historyRightColumn}>{formatChangeRecordField(changeRecord.to, changeRecord.changedField)}</div>\n </div>\n </div>\n </div>\n </>\n }\n })\n }\n </>\n \n \n return (\n <Drawer\n open={isOpen}\n anchor=\"right\"\n classes={{ paper: classes.drawer }}\n onClose={drawerOnClose}\n >\n {\n mode === \"edit\" && <TabsHeader/>\n }\n <div className={classes.root}>\n {mode === \"edit\"\n ?\n <>\n <TabContext\n value={activeTab}\n >\n <TabPanel\n classes={{\n root: classes.tabPanelRoot\n }}\n value=\"payment\"\n >\n {PaymentContent()}\n </TabPanel>\n <TabPanel\n value=\"history\"\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {HistoryContent()}\n </TabPanel>\n </TabContext>\n </>\n :\n <>\n {PaymentContent()}\n </>\n }\n \n </div>\n \n </Drawer>\n );\n}","import { ApiClient } from \"./api-client\";\nimport { AppointmentPaymentEntity } from \"../models/appointment-payment-entity\";\nimport { AppointmentPaymentValues } from \"../models/appointment-payment-values\";\nimport { AppointmentPricedService } from \"../models/appointment-priced-service\";\nimport { AppointmentPaymentChangeRecord } from \"../models/appointment-payment-change-record\";\n\n\nexport class AppointmentPaymentService {\n private static baseUrl: string = \"/appointmentPayment\";\n\n private static isoDate(date: Date): string {\n const year = date.toLocaleString(\"en-US\", {\n year: \"numeric\",\n });\n const month = date.toLocaleString(\"en-US\", {\n month: \"2-digit\",\n });\n const day = date.toLocaleString(\"en-US\", {\n day: \"2-digit\",\n });\n\n return `${year}-${month}-${day}`;\n }\n \n static getAppointmentPricedServices(appointmentId: string | number): Promise<AppointmentPricedService[]> {\n return ApiClient\n .get(`${this.baseUrl}/getAppointmentPricedServices?AppointmentId=${appointmentId}`)\n .then(data => data.services)\n }\n\n static create(appointmentId: string | number, payment: AppointmentPaymentEntity, totalToBePaid: number): Promise<{payment: AppointmentPaymentEntity, paymentValues: AppointmentPaymentValues[] }> {\n return ApiClient\n .post(`${this.baseUrl}/create`, { appointmentId, payment, totalToBePaid })\n .then(data => { return { payment: new AppointmentPaymentEntity(data.payment), paymentValues: data.paymentValues }});\n }\n\n static update(appointmentId: string | number, payment: AppointmentPaymentEntity, previouslyPaid: number, totalToBePaid: number): Promise<{ payment: AppointmentPaymentEntity, changeRecords: AppointmentPaymentChangeRecord[] }> {\n const newPayment = { ...payment, previouslyPaid }\n return ApiClient\n .put(`${this.baseUrl}/update`, { appointmentId, payment: newPayment, totalToBePaid })\n .then(data => { return { payment: new AppointmentPaymentEntity(data.payment), changeRecords: data.changeRecords }});\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #F15857\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"18px 24px 24px 24px\",\n width: 464,\n height: 340,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #F15857\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: theme.colors.clearRed,\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 15,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n saveAppointment: {\n background: theme.colors.clearRed,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearRed,\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n radioLabelRoot: {\n margin: 0,\n marginRight: 15\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n radioOption: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: \"#4A4D51\", //theme.colors.clearMain,\n },\n },\n },\n}));\n\nexport default useStyles;\n","export enum CustomRecurrenceMode {\n Day = 0,\n Week,\n Month,\n Year\n}\n","export enum WeekDaysFlags {\n None = 0,\n Sunday = 1,\n Monday = 2,\n Tuesday = 4,\n Wednesday = 8,\n Thursday = 16,\n Friday = 32,\n Saturday = 64,\n}","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { FormControlLabel, Radio, RadioGroup } from \"@material-ui/core\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { CrossIcon, TrashIcon } from \"../../../assets/icons\";\n\nimport { RecurringAppointmentDeleteModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport {useAppSelector} from \"../../../redux/hooks\";\n\n\nconst RecurringAppointmentDeleteModal = (props: RecurringAppointmentDeleteModalProps) => {\n const { open, appointment, service, onClose, onDelete } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n \n const optionDeleteOnlyThisAppointment = 0;\n const optionDeleteThisAndFutureAppointment = 1;\n const [selectedOptionToDelete, setSelectedOptionToDelete] = useState<number>(-1);\n const [disableButton, setDisableButton] = useState<boolean>(false);\n\n useEffect(() => {\n setSelectedOptionToDelete(-1);\n setDisableButton(false);\n }, [open]);\n\n const date = (startDate: Date, endDate: Date): string => {\n const start = new Date(startDate);\n const end = new Date(endDate);\n\n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n\n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n\n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n\n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n\n const timeDifference = (today: Date, endDate: Date): string => {\n const hours = parseInt(\n `${\n (Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60 * 60)) % 24\n }`\n );\n const minutes = parseInt(\n `${(Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60)) % 60}`\n );\n if (hours > 0 && minutes < 1) {\n return `${hours}hr`;\n } else if (hours < 1 && minutes > 0) {\n return `${minutes}min`;\n } else {\n return `${hours}hr ${minutes}min`;\n }\n };\n\n \n const handleDeleteOption = (event: any) => {\n setSelectedOptionToDelete(+event.target.value);\n }\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Delete recurring appointment?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {appointment?.customerName}\n {service ? ` - ${service}` : \"\"}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalDateText}>\n {`${date(\n appointment?.startDate.toJSDate(),\n appointment?.endDate.toJSDate()\n )} (${timeDifference(\n appointment?.startDate.toJSDate(),\n appointment?.endDate.toJSDate()\n )})`}\n </Typography>\n </div>\n \n <div style={{textAlign: \"center\", marginTop: 15}}>\n <div style={{display: \"inline-block\"}}>\n <RadioGroup\n defaultValue={-1}\n aria-label=\"appointmentEnds\"\n name=\"appointmentEnds\"\n onChange={handleDeleteOption}\n value={selectedOptionToDelete}\n row \n >\n\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={optionDeleteOnlyThisAppointment}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={t(\"This appointment\")}\n />\n\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={optionDeleteThisAndFutureAppointment}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={t(\"This and the following appointments\")}\n />\n \n </RadioGroup>\n </div>\n </div>\n\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n disabled={disableButton || selectedOptionToDelete===-1}\n className={`${classes.button} ${classes.saveAppointment}`}\n onClick={() => {\n setDisableButton(true);\n onDelete(selectedOptionToDelete === optionDeleteThisAndFutureAppointment);\n }}\n >\n {t(\"Delete appointment\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default RecurringAppointmentDeleteModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n zIndex: 2,\n },\n mainItem: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n \n width: 171,\n padding: 0,\n },\n mainItemText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey4,\n fontWeight: 700\n },\n list: {\n marginTop: 5,\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n \n \"& > :first-child\": {\n borderTopLeftRadius: 5,\n borderTopRightRadius: 5,\n },\n \"& > :last-child\": {\n borderBottomLeftRadius: 5,\n borderBottomRightRadius: 5,\n },\n },\n itemDot: {\n paddingLeft: 17.75,\n paddingRight: 11.75,\n },\n item: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n \n width: 171,\n height: 40,\n padding: 0,\n \n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey1,\n \n backgroundColor: theme.colors.white,\n \n cursor: \"pointer\",\n \n \"&:hover\": {\n backgroundColor: theme.colors.grey1\n }\n },\n itemText: {\n ...theme.typography.buttons,\n color: theme.colors.grey5,\n fontWeight: 400,\n },\n selectedItemText: {\n color: theme.colors.clearMain,\n fontWeight: 700,\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from 'react'\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { ArrowDropDownIcon, DotIcon } from \"../../../assets/icons\";\nimport { AppointmentStatusSelectorProps } from \"./props\";\nimport { AppointmentStatus } from \"../../../models/enums/appointment-status\";\nimport useStyles from \"./css\";\nimport { ClickAwayListener, ListItem } from \"@material-ui/core\";\n\n\nexport default function AppointmentStatusSelector(props: AppointmentStatusSelectorProps) {\n \n const { appointmentStatus, handleAppointmentStatusChange, disabled } = props;\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n const statuses = [AppointmentStatus.NotConfirmed, AppointmentStatus.Confirmed, AppointmentStatus.Arrived, AppointmentStatus.NotArrived];\n \n const [open, setOpen] = useState<boolean>(false);\n \n const getDotStatus = (status: AppointmentStatus | undefined): string => {\n switch (status) {\n case AppointmentStatus.Arrived:\n return \"#36CE91\";\n case AppointmentStatus.NotArrived:\n return \"#F15857\";\n case AppointmentStatus.NotConfirmed:\n return \"#919CA5\";\n case AppointmentStatus.Confirmed:\n default:\n return \"#0BCBE0\";\n }\n };\n \n const getTxtStatus = (status: AppointmentStatus | undefined): string => { //TODO probably cleanup\n switch (status) {\n case AppointmentStatus.Arrived:\n return t(\"Arrived\");\n case AppointmentStatus.NotArrived:\n return t(\"Not Arrived\");\n case AppointmentStatus.NotConfirmed:\n return t(\"Not Confirmed\");\n case AppointmentStatus.Confirmed:\n default:\n return t(\"Confirmed\");\n }\n };\n \n function handleDropdown() {\n setOpen(!open)\n }\n \n function handleCloseList() {\n setOpen(false)\n }\n \n function handleListItemClick(item: AppointmentStatus) {\n handleAppointmentStatusChange(item);\n handleCloseList();\n }\n \n function renderStatusAsListItem(item: AppointmentStatus) {\n const selected = item === appointmentStatus;\n return (\n <ListItem \n className={classes.item}\n onClick={() => handleListItemClick(item)}\n >\n <div className={classes.itemDot}>\n <DotIcon\n color={getDotStatus(item)}\n style={{ width: \"10.5px\", height: \"10.5px\" }}\n viewBox=\"0 0 14 14\"\n />\n </div>\n <Typography className={`${classes.itemText} ${selected ? classes.selectedItemText : \"\"}`}>\n {getTxtStatus(item).toUpperCase()}\n </Typography>\n </ListItem>\n );\n }\n \n return (\n <div className={classes.root}>\n <ListItem className={classes.mainItem}>\n <DotIcon\n color={getDotStatus(appointmentStatus)}\n style={{ width: 14, height: 14, marginRight: 11.75, }}\n viewBox=\"0 0 14 14\"\n />\n <Typography className={classes.mainItemText}>\n {getTxtStatus(appointmentStatus).toUpperCase()}\n </Typography>\n {\n disabled \n ? null\n : \n <ArrowDropDownIcon\n style={{ color: \"#919CA5\", marginLeft: 5, transform: open ? \"rotate(180deg)\" : \"rotate(0deg)\", cursor: \"pointer\" }}\n onClick={handleDropdown}\n />\n }\n </ListItem>\n {\n open &&\n <ClickAwayListener mouseEvent=\"onClick\" onClickAway={() => setOpen(false)}>\n <div className={classes.list}>\n {statuses.map(renderStatusAsListItem)}\n </div>\n </ClickAwayListener>\n }\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useHistory } from \"react-router-dom\";\n\nimport { useTranslation } from \"react-i18next\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\nimport { useDispatch, useSelector } from \"react-redux\";\nimport {\n RootState,\n selectAccountSettings,\n selectCommonHubConnection,\n selectCashRegisterOpen,\n selectUserInfo\n} from \"../../../redux/store\";\nimport { schedulerActions } from \"../../../redux/scheduler-slice\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { blockedScheduleActions } from \"../../../redux/blocked-schedule-slice\";\nimport { multipleBlockedScheduleActions } from \"../../../redux/multiple-blocked-schedule-slice\";\n\nimport Popover from \"@material-ui/core/Popover\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport Modal from \"@material-ui/core/Modal\";\nimport CircularProgress from \"@material-ui/core/CircularProgress\";\n\nimport { Url } from \"../../../constants/url\";\nimport { AppointmentService } from \"../../../api/appointment-service\";\nimport { Appointment } from \"../../../models/appointment\";\nimport { AppointmentStatus } from \"../../../models/enums/appointment-status\";\nimport {\n CrossIcon,\n DotsVerticalIcon,\n EditIcon,\n FlagIcon,\n GroupIcon,\n MoneyIcon,\n NotesIcon,\n TrashIcon,\n} from \"../../../assets/icons\";\nimport AppointmentDeleteModal from \"./../AppointmentDeleteModal\";\nimport AppointmentFollowUp from \"./../AppointmentFollowUp\";\nimport useStyles from \"./css\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport { conformToMask } from \"react-text-mask\";\nimport { AppointmentCreatedBy } from \"../../../models/enums/appointment-created-by\";\nimport AppointmentPaymentSidebar from \"../AppointmentPaymentSidebar\";\nimport { AppointmentPaymentStatus } from \"../../../models/enums/appointment-payment-status\";\nimport { EditableItemProps } from \"../../../models/interfaces/editable-item-props\";\nimport { AppointmentPaymentEntity } from \"../../../models/appointment-payment-entity\";\nimport { AppointmentPaymentFormData } from \"../../../models/appointment-payment-form-data\";\nimport { AppointmentPaymentService } from \"../../../api/appointment-payment-service\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport { AppointmentPaymentChangeRecord } from \"../../../models/appointment-payment-change-record\";\nimport RecurringAppointmentDeleteModal from \"../RecurringAppointmentDeleteModal\";\nimport { PaymentsService } from \"../../../api/payments-service\";\nimport { AppointmentPaymentValues } from \"../../../models/appointment-payment-values\";\nimport AppointmentStatusSelector from \"../AppointmentStatusSelector\";\nimport { AppointmentTooltipModel } from \"../../../models/appointment-tooltip-model\";\nimport { CustomRecurrenceMode } from \"../../../models/enums/custom-recurrence-mode\";\nimport { WeekDaysFlags } from \"../../../models/enums/week-days-flags\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\n\nexport default function AppointmentItemTooltip(props: any) {\n\n const {\n anchorEl,\n appointmentMeta,\n visible,\n onHide,\n onDeleteButtonClick,\n ...otherProps\n } = props;\n \n const classes = useStyles();\n const history = useHistory();\n \n const dispatch = useDispatch();\n const accountSettings = useAppSelector(selectAccountSettings);\n const currencyTemplate: string = accountSettings.currencyTemplate;\n const isEnterprise = accountSettings.isEnterprise;\n const isCashRegisterActivated: boolean = accountSettings.isCashRegisterActivated;\n const isCashRegisterOpen: boolean = useAppSelector(selectCashRegisterOpen);\n const hubConnection = useAppSelector(selectCommonHubConnection);\n const { enqueueAlert } = alertsActions;\n\n const { t } = useTranslation([\"general\"]);\n const [target, setTarget] = useState<any>();\n const [appointment, setAppointment] = useState<Appointment>(new Appointment());\n const [appointmentDetails, setAppointmentDetails] = useState<AppointmentTooltipModel>(new AppointmentTooltipModel());\n const [appointmentPayment, setAppointmentPayment] = useState<AppointmentPaymentEntity>(new AppointmentPaymentEntity());\n const [oldAppointmentPayment, setOldAppointmentPayment] = useState<AppointmentPaymentEntity>(new AppointmentPaymentEntity());\n const [appointmentPaymentFormData, setAppointmentPaymentFormData] = useState<AppointmentPaymentFormData>(new AppointmentPaymentFormData());\n const [firstService, setFirstService] = useState<string>();\n const [openModalDelete, setOpenModalDelete] = useState<boolean>(false);\n const [openModalFollowUp, setOpenModalFollowUp] = useState<boolean>(false);\n const [open, setOpen] = useState<boolean>(false);\n const [isPaymentsSidebarOpen, setPaymentsSidebarOpen] = useState<boolean>(false);\n const [paymentsSidebarMode, setPaymentsSidebarMode] = useState<EditableItemProps>({ mode: \"new\", itemId: null });\n //const [services, setServices] = useState<AppointmentServiceModel[]>([]);\n const [openModalActionDots, setOpenModalActionDots] = useState<boolean>(false);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const [showRecurringAppointmentDeleteModal, setShowRecurringAppointmentDeleteModal] = useState<boolean>(false);\n const [paymentButtonDisable , setPaymentButtonDisable] = useState<boolean>(false);\n const mobileTemplate: string = \"000-000-0000\";\n const templatedValue = useCurrencyValueTemplate(currencyTemplate);\n \n const userInfo = useAppSelector(selectUserInfo);\n const hasCustomerInfoVisible = userInfo.hasCustomerInfoVisible;\n const isUserAbleToRegisterPayments = userInfo.canRegisterPayments;\n const isPaymentSidebarEnabled =\n isEnterprise === false &&\n (isCashRegisterActivated &&\n (isCashRegisterOpen && isUserAbleToRegisterPayments && appointmentDetails?.paymentStatus === AppointmentPaymentStatus.Unpaid) ||\n appointmentDetails?.paymentStatus !== AppointmentPaymentStatus.Unpaid)\n const canMakePayment = isCashRegisterActivated && isCashRegisterOpen && isUserAbleToRegisterPayments;\n const oldAppointmentPaymentAmountPaid = oldAppointmentPayment.parts?.map(x => x.amountPaid).reduce((sum, x) => sum + x) || 0\n\n const frequencyWeek: any[] = [\n { key: \"1\", value: `${t(\"Every week, on the\")} DAY` },\n { key: \"2\", value: `${t(\"Every 2 weeks, on the\")} DAY` },\n { key: \"3\", value: `${t(\"Every 3 weeks, on the\")} DAY` },\n { key: \"4\", value: `${t(\"Every 4 weeks, on the\")} DAY` },\n { key: \"8\", value: `${t(\"Every 8 weeks, on the\")} DAY` },\n { key: \"12\", value: `${t(\"Every 12 weeks, on the\")} DAY` }\n ];\n\n const appointmentId = useSelector(\n (state: RootState) => state.scheduler.appointmentId\n );\n const tooltipAppointments = useSelector(\n (state: RootState) => state.scheduler.tooltipAppointments\n );\n\n useEffect(() => {\n setAppointment(appointmentMeta);\n setTarget(anchorEl);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointmentMeta, anchorEl]);\n\n useEffect(() => {\n if (appointmentId && appointmentId === appointment.appointmentId) {\n const currentAppointment = tooltipAppointments.find(\n (a) => a.appointmentId === appointmentId\n );\n\n if (currentAppointment && currentAppointment.elementRef) {\n setAppointment(new Appointment(currentAppointment));\n setTarget(currentAppointment.elementRef);\n setOpen(true);\n }\n } else {\n setOpen(false);\n onHide();\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointmentId]);\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n\n if (open && appointment && appointment.appointmentId) {\n void fetchData();\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n \n useEffect(() => {\n async function fetchData() {\n await loadData();\n await loadPaymentData();\n }\n\n if (appointment && appointment.appointmentId) {\n fetchData();\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isCashRegisterOpen]);\n\n useEffect(() => {\n setOpen(!!visible);\n }, [visible]);\n \n async function loadData() {\n const data = await AppointmentService.getAppointmentTooltip(appointment.appointmentId as string);\n const appointmentDate = appointment.startDate.toJSDate();\n \n if (data.services.length > 0) {\n let duration = 0;\n const services = data.services.map((service) => {\n const startDate = data.scheduledSimultaneousServices ? appointmentDate : new Date(appointmentDate.getTime() + duration * 60000);\n const endDate = new Date(startDate.getTime() + service.duration! * 60000);\n duration += service.duration!;\n return { ...service, startDate, endDate };\n });\n setFirstService(services[0].name || undefined);\n data.services = services;\n }\n setAppointmentDetails(data);\n }\n\n async function loadPaymentData() {\n if (!appointment.appointmentId) return;\n\n setPaymentButtonDisable(true);\n\n try {\n const result = appointmentDetails.isRecurring\n ? await PaymentsService.getRecurringAppointmentPaymentFormData(appointment.appointmentId,\n appointmentDetails.recurredAppointmentsIds,\n appointmentDetails.recurringApptTotalToPaid)\n : await PaymentsService.getPaymentFormData(appointment.appointmentId);\n\n setPaymentButtonDisable(false);\n\n if (!result || !result.payment) return;\n setOldAppointmentPayment(result.payment);\n setAppointmentPaymentFormData(result);\n\n const isNew = result.payment.id === null;\n if (isNew){\n result.payment.services = await AppointmentPaymentService.getAppointmentPricedServices(appointment.appointmentId);\n }\n\n const somePaymentsExist = result.payment.parts.some(x => x.amountPaid > 0);\n\n const mode = appointmentDetails.isRecurring \n ? (somePaymentsExist ? \"edit\" : \"new\") \n : (isNew ? \"new\" : \"edit\");\n\n setPaymentsSidebarMode({ mode: mode, itemId: appointmentPayment.id });\n setAppointmentPayment({ ...result.payment });\n } catch (error) {\n setPaymentButtonDisable(false);\n }\n }\n \n async function updatePaymentInfo(appointmentId: string) {\n if (!(appointment && appointment.appointmentId)) return;\n if (appointment.appointmentId == appointmentId) {\n await loadPaymentData()\n }\n }\n \n function updateAppointmentsPaymentStatus(appointmentId: string, paymentStatus: AppointmentPaymentStatus, paidAmount: number) {\n if (!(appointmentDetails && appointmentDetails.appointmentId)) return;\n if (appointmentDetails.appointmentId == appointmentId) {\n setAppointmentDetails({...appointmentDetails, paymentStatus, paidAmount });\n }\n }\n\n const handleUpdateAppointmentData = (appointmentId: string) => {\n async function fetchData() {\n await loadData();\n }\n if (!(appointmentDetails && appointmentDetails.appointmentId)) return;\n if (appointmentDetails.appointmentId === appointmentId) {\n void fetchData();\n }\n };\n\n const handleStatusChange = (appointmentId: string, status: string) => {\n if (!(appointment && appointment.appointmentId)) return;\n const newAppointmentStatus: AppointmentStatus = parseInt(status);\n\n if (appointment.appointmentId == appointmentId) {\n setAppointment({ ...appointment, status: newAppointmentStatus });\n }\n };\n\n // unsubscribe\n hubConnection?.off(\"updatePaymentInfo\");\n hubConnection?.off(\"changeAppointmentPaymentStatus\");\n hubConnection?.off(\"updateAppointmentTooltipData\");\n hubConnection?.off(\"changeAppointmentStatusOnTooltip\");\n // subscribe\n hubConnection?.on(\"updatePaymentInfo\", async (appointmentId) => await updatePaymentInfo(appointmentId));\n hubConnection?.on(\"changeAppointmentPaymentStatus\", (appointmentId, status, paidAmount) => updateAppointmentsPaymentStatus(appointmentId, status, paidAmount));\n hubConnection?.on(\"updateAppointmentTooltipData\", (appointmentId) => handleUpdateAppointmentData(appointmentId));\n hubConnection?.on(\"changeAppointmentStatusOnTooltip\", (appointmentId, status) => handleStatusChange(appointmentId, status));\n\n function isAppointmentPaymentUnchanged() {\n return JSON.stringify(appointmentPayment) === JSON.stringify(oldAppointmentPayment);\n }\n\n const getStatus = (status: AppointmentStatus | undefined): string => {\n switch (status) {\n case AppointmentStatus.Arrived:\n return classes.arrived;\n case AppointmentStatus.NotArrived:\n return classes.notArrived;\n case AppointmentStatus.NotConfirmed:\n return classes.notConfirmed;\n case AppointmentStatus.Confirmed:\n default:\n return classes.confirmed;\n }\n };\n \n async function handleAppointmentStatusSelect(status: AppointmentStatus) {\n await AppointmentService.updateStatus({\n id: appointment.appointmentId as string,\n status\n });\n setAppointment({ ...appointment, status });\n }\n \n function getTxtPaymentStatus(status: AppointmentPaymentStatus | undefined): string {\n switch (status) {\n case AppointmentPaymentStatus.Unpaid:\n return t(\"Unpaid\");\n case AppointmentPaymentStatus.Paid:\n return t(\"Paid\");\n case AppointmentPaymentStatus.PaidPartially:\n return t(\"Unpaid\");\n default:\n return t(\"Unpaid\");\n }\n }\n\n function getPaymentStatusColor(status: AppointmentPaymentStatus | undefined): string {\n switch (status) {\n case AppointmentPaymentStatus.Unpaid:\n return \"#F15857\";\n case AppointmentPaymentStatus.Paid:\n return \"#36CE91\";\n case AppointmentPaymentStatus.PaidPartially:\n return \"#F15857\";\n default:\n return \"#F15857\";\n }\n }\n \n let appointmentTotalPrice = appointmentDetails.services\n .map(x => x.price)\n .reduce((sum: number, currentServicePrice) => sum += currentServicePrice ?? 0, 0);\n \n function getAppointmentPriceByPaymentStatus(status: AppointmentPaymentStatus | undefined) : number {\n const totalPrice = appointmentDetails.isRecurring\n ? appointmentDetails.totalRecurringApptPriceExcludingSelected + appointmentTotalPrice\n : appointmentTotalPrice;\n\n switch (status) {\n case AppointmentPaymentStatus.Unpaid:\n return totalPrice;\n case AppointmentPaymentStatus.Paid:\n return appointmentDetails.paidAmount;\n case AppointmentPaymentStatus.PaidPartially:\n return appointmentDetails.paidAmount;\n default:\n return appointmentDetails.services.map(x => x.price).reduce((sum : number, currentServicePrice) => sum += currentServicePrice ?? 0, 0);\n }\n }\n\n const onClose = (event: any, reason: any) => {\n setOpen(false);\n onHide(event, reason);\n\n //need to be able to open same appointment tooltip from notifications more than once\n dispatch(schedulerActions.setAppointmentId(undefined));\n dispatch(blockedScheduleActions.setBlockedSheduleId(undefined));\n \n };\n\n const handleCloseModal = () => {\n setOpenModalDelete(false);\n };\n\n const onEdit = () => {\n history.push(`${Url.Appointments.Main}/${appointment?.appointmentId}`);\n };\n\n const handleDelete = (allRecurringAppointments: boolean) => {\n if (appointment.appointmentId) {\n AppointmentService.remove(appointment.appointmentId as string, allRecurringAppointments).then(() => {\n setShowRecurringAppointmentDeleteModal(false);\n setOpenModalDelete(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Appointment deleted\"),\n description: t(\"Appointment has been successfully deleted.\"),\n })\n );\n });\n }\n };\n\n const handleDeleteModal = () => {\n if (appointmentDetails.isRecurring) {\n setShowRecurringAppointmentDeleteModal(true);\n } else {\n setOpenModalDelete(true);\n }\n };\n\n async function handlePaymentSidebarOpen() {\n if (!appointment.appointmentId || !appointmentPayment) return;\n resetAppointmentPaymentForm();\n await loadPaymentData().then(() => {\n setPaymentsSidebarOpen(true);\n });\n\n }\n\n const getStartEndTime = (startDate: Date, endDate: Date): string => {\n const start = new Date(startDate);\n const end = new Date(endDate);\n\n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n return `${startTime} - ${endTime}hrs`;\n };\n\n const isEditable = (): boolean => {\n if (isEnterprise || isEnterprise === null) return false;\n return appointment ? appointment.isEditable : true;\n };\n\n const handleCreateNewAppointment = () => {\n history.push(`${Url.Appointments.Main}/new/${appointmentDetails?.customerId}`);\n };\n\n const handleCloseModalFollowUp = (isCreated: boolean) => {\n if (isCreated) {\n onHide();\n setOpen(false);\n }\n \n setOpenModalActionDots(false);\n setOpenModalFollowUp(false);\n \n };\n\n const handleCreateFollowUp = () => {\n setOpenModalActionDots(false);\n setOpenModalFollowUp(true);\n };\n \n function setAppointmentPaymentValues(paymentValues: AppointmentPaymentValues[]) {\n setAppointmentPaymentFormData({...appointmentPaymentFormData, paymentValues });\n }\n \n function setAppointmentPaymentChangeRecords(changeRecords: AppointmentPaymentChangeRecord[]) {\n setAppointmentPaymentFormData({...appointmentPaymentFormData, changeRecords });\n }\n \n async function handlePaymentSave(totalToBePaid: number): Promise<void> {\n if (!appointment.appointmentId) return;\n if (!canMakePayment) {\n setPaymentsSidebarOpen(false);\n return;\n }\n if (paymentsSidebarMode.mode === \"new\" || !appointmentPayment.id) {\n const createdPayment = await AppointmentPaymentService\n .create(appointment.appointmentId, appointmentPayment, totalToBePaid);\n \n if (createdPayment.paymentValues && createdPayment.payment) {\n if (!appointmentDetails.isRecurring) setAppointmentPaymentValues(createdPayment.paymentValues);\n setEditModeOnPaymentCreation(createdPayment.payment.id);\n setOldAppointmentPayment(createdPayment.payment);\n setAppointmentPayment(createdPayment.payment);\n }\n return;\n }\n \n const editedPayment = await AppointmentPaymentService\n .update(appointment.appointmentId, appointmentPayment, oldAppointmentPaymentAmountPaid, totalToBePaid);\n\n if (editedPayment.changeRecords && editedPayment.payment) {\n setAppointmentPaymentChangeRecords(editedPayment.changeRecords);\n setAppointmentPayment(editedPayment.payment);\n setOldAppointmentPayment(editedPayment.payment);\n }\n }\n \n function setEditModeOnPaymentCreation(itemId: string | null) {\n setPaymentsSidebarMode({ mode: \"edit\", itemId: itemId });\n }\n\n function resetAppointmentPaymentForm() {\n setPaymentsSidebarMode({ mode: \"new\", itemId: null });\n }\n \n const mobileFormat = (mobile: string, template: any): string => {\n return conformToMask(mobile, GetMobileMaskByTemp(template || mobileTemplate)).conformedValue;\n };\n\n const formatDay = (): string => {\n const date = appointment?.startDate.toJSDate();\n let longDay = date.toLocaleDateString(localeApp, { weekday: \"long\" });\n return longDay.charAt(0).toLowerCase() + longDay.slice(1);\n };\n\n const getRecurringWeekByDay = () => {\n\n if (appointmentDetails?.appointmentRecurrenceWeekInterval) {\n let filtered = frequencyWeek.filter(x => x.key == appointmentDetails?.appointmentRecurrenceWeekInterval);\n const day = \" \" + formatDay();\n if (filtered.length === 1) {\n return filtered[0].value.replace(\"DAY\", day);\n }\n }\n \n if (appointmentDetails?.customRecurrenceInterval) {\n const modeString = t(CustomRecurrenceMode[appointmentDetails?.customRecurrenceMode!].toLowerCase());\n const modeStringEnding = localeApp == 'es' && appointmentDetails?.customRecurrenceMode === CustomRecurrenceMode.Month ? \"es\" : \"s\";\n const daysOfWeek = appointmentDetails?.customRecurrenceWeekDays && appointmentDetails?.customRecurrenceWeekDays > 0 \n ? ` ${t(\"_the\")} ${getChosenDaysOfWeek(appointmentDetails?.customRecurrenceWeekDays)}` \n : \"\";\n const recurrenceString = `${t(\"Every\")} ${appointmentDetails.customRecurrenceInterval} ${modeString}${modeStringEnding}${daysOfWeek}`;\n return recurrenceString;\n }\n\n return \"\";\n };\n \n function getChosenDaysOfWeek(weekDaysFlags: WeekDaysFlags): string {\n const chosenDays = [];\n for (const day in WeekDaysFlags) {\n if (weekDaysFlags & parseInt(day)) {\n chosenDays.push(t(WeekDaysFlags[day]));\n }\n }\n \n return chosenDays.join(\", \");\n }\n\n return (\n <>\n <Popover\n open={(!appointmentMeta?.isBlocked && open) || false}\n anchorEl={target}\n onClose={onClose}\n anchorOrigin={{ vertical: \"top\", horizontal: \"center\" }}\n transformOrigin={{ vertical: \"top\", horizontal: \"center\" }}\n PaperProps={{\n className: classes.popover,\n }}\n {...otherProps}\n >\n <div className={`${classes.header} ${getStatus(appointment?.status)}`}/>\n <div className={classes.root}>\n <div className={`${classes.headerActions} ${classes.row}`}>\n <AppointmentStatusSelector \n appointmentStatus={appointment?.status}\n handleAppointmentStatusChange={handleAppointmentStatusSelect}\n disabled={isEnterprise !== false}\n />\n <div\n style={{ display: \"flex\", justifyContent: \"end\", width: \"100%\" }}\n >\n {isEditable() ? (\n <>\n <span className={classes.headerIcon}>\n <TrashIcon\n className={classes.headerButtons}\n style={{\n width: 13,\n height: 17,\n color: \"#919CA5\",\n }}\n onClick={handleDeleteModal}\n />\n </span>\n <span className={classes.headerIcon}>\n <EditIcon\n className={classes.headerButtons}\n style={{\n width: 16,\n height: 16,\n }}\n onClick={onEdit}\n />\n </span>\n </>\n ) : null}\n <span\n className={classes.headerIcon}\n style={{ marginTop: -2, position: \"relative\" }}\n >\n {hasCustomerInfoVisible && (isEnterprise === false) &&\n <span className={classes.headerIcon} style={{marginTop: -2, position: \"relative\", left: -10}}>\n <DotsVerticalIcon\n className={classes.headerButtons}\n style={{\n width: 20,\n height: 20,\n marginTop: \"3px\"\n }}\n color=\"#919CA5\"\n viewBox=\"0 0 25 25\"\n onClick={() => setOpenModalActionDots(true)}\n />\n\n <Modal\n open={openModalActionDots}\n onClose={() => setOpenModalActionDots(false)}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n disablePortal={true}\n style={{ position: \"relative\", top: 0 }} >\n <div className={classes.modalActionsAppt} >\n <div className={`${classes.modalActionFont} ${classes.modalActionFirst}`} onClick={handleCreateNewAppointment}>{t(\"Create new appointment\")} </div>\n <div className={`${classes.modalActionFont} ${classes.modalActionLast}`} onClick={handleCreateFollowUp}>{t(\"NewFollowUpCreateFollowUp\")} </div>\n </div>\n </Modal>\n </span> \n }\n </span>\n\n <span className={classes.headerIcon}>\n <CrossIcon\n className={classes.headerButtons}\n style={{\n width: 20,\n height: 20,\n }}\n viewBox=\"0 0 16 16\"\n onClick={onClose}\n />\n </span>\n </div>\n </div>\n\n {\n appointment?.createdBy === AppointmentCreatedBy.Customer &&\n <div className={classes.headerSubText}>\n {t(\"Scheduled from site for appointments\")}\n </div>\n }\n\n <div className={classes.content}>\n <div className={classes.bodyContent}>\n <div className={`${classes.row} ${classes.paymentRow}`}>\n <div className={classes.paymentInfo}>\n <MoneyIcon\n viewBox={\"0 0 10 16\"}\n style={{\n width: 16,\n height: 16,\n marginTop: 5,\n marginRight: 12,\n fontSize: '16px'\n }}\n />\n <div>\n <div>\n <span className={classes.txtBody2}\n style={{ color: getPaymentStatusColor(appointmentDetails?.paymentStatus) }}>\n {getTxtPaymentStatus(appointmentDetails?.paymentStatus)}\n </span>\n {\" \"}\n {userInfo.showPrices &&\n <span className={classes.paymentAmount}>\n {templatedValue(getAppointmentPriceByPaymentStatus(appointmentDetails?.paymentStatus))}\n </span>\n }\n </div>\n {appointmentDetails.isRecurring && <div className={classes.recurringAppointmentPaymentText}>\n {t(\"Includes {{count}} recurring appointments\", {\n count: appointmentDetails.recurredAppointmentsCount ?? 0,\n })}\n </div>}\n </div>\n \n </div>\n {\n isPaymentSidebarEnabled &&\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Small}\n backgroundOrBorderColor={ButtonPropsColor.None}\n hoverColor={ButtonPropsColor.Clilac}\n textColor={ButtonPropsColor.Main}\n innerText={appointmentDetails?.paymentStatus === AppointmentPaymentStatus.Unpaid\n ? t(\"Register payment\")\n : t(\"Payment detail\")}\n onClick={handlePaymentSidebarOpen}\n disabled={paymentButtonDisable}\n />\n }\n </div>\n <div\n className={classes.separator}\n />\n \n {appointmentDetails?.isRecurring &&\n <>\n <div className={classes.row} >\n <div\n style={{\n width: 12,\n height: 16,\n marginTop: 4,\n marginRight: 14,\n }}\n />\n <div className={classes.recurringAppointmentInfo} >\n <div>\n <Typography className={classes.caption}>\n {t(\"Recurring appointment\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {`(${appointmentDetails?.recurringAppointmentOrder}/${appointmentDetails?.recurredAppointmentsCount}) ${getRecurringWeekByDay()}`}\n </Typography>\n </div>\n {userInfo.showPrices && \n <>\n <div>\n <Typography className={classes.caption}>\n {t(\"Total of {{count}} appointments:\", {\n count: appointmentDetails.recurredAppointmentsCount ?? 0,\n })}\n </Typography>\n <Typography className={classes.txtBody2}>\n {templatedValue(appointmentDetails.totalRecurringApptPrice)}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Total per appointment:\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {templatedValue((appointmentDetails.totalRecurringApptPrice) \n / (appointmentDetails.recurredAppointmentsCount ?? 1))}\n </Typography>\n </div>\n </>\n }\n </div>\n </div>\n <div\n className={classes.separator}\n />\n </>}\n\n \n <div className={classes.row}>\n <GroupIcon\n style={{\n width: 16,\n height: 16,\n marginTop: 5,\n marginRight: 12,\n }}\n />\n <div>\n <div>\n <Typography className={classes.caption}>\n {useCustomerTerminology(t(\"Customer name\"), \"Customer name\")}\n </Typography>\n <Typography className={classes.txtBody1}>\n {appointment?.customerName}\n </Typography>\n </div>\n {!hasCustomerInfoVisible ? <></> : <>\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Email\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {appointmentDetails?.customerEmail || \"--\"}\n </Typography>\n </div>\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Mobile number\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {appointmentDetails?.customerMobile ? mobileFormat(appointmentDetails?.customerMobile || \"\", appointmentDetails.customerMobileTemplate) : \"\"}\n </Typography>\n </div>\n </>}\n </div>\n </div>\n <div \n className={classes.separator}\n />\n {appointmentDetails.services.map((service, index) => (\n <>\n <div className={classes.row}>\n <FlagIcon\n style={{\n color: \"#919CA5\",\n width: 12,\n height: 16,\n marginTop: 4,\n marginRight: 14,\n }}\n viewBox=\"0 0 12 16\"\n />\n <div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Service\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {service.name}\n </Typography>\n </div>\n {userInfo.showPrices &&\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Price\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {templatedValue(service.price ?? 0)}\n </Typography>\n </div>\n }\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Specialist\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {service.user}\n </Typography>\n </div>\n {\n appointment?.establishmentName &&\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Establishment\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {appointment.establishmentName}\n </Typography>\n </div>\n }\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Work area\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {service.workArea || \"--\"}\n </Typography>\n </div>\n <div className={classes.subsection}>\n <Typography className={classes.caption}>\n {t(\"Duration\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {`${getStartEndTime(\n service.startDate || new Date(),\n service.endDate || new Date()\n )} (${service.duration} min)`}\n </Typography>\n </div>\n </div>\n </div>\n <div className={classes.separator} />\n </>\n ))}\n\n <div className={classes.row}>\n <NotesIcon\n style={{\n width: 14,\n height: 14,\n color: \"#919CA5\",\n marginTop: 6,\n marginRight: 14,\n }}\n viewBox=\"0 0 14 14\"\n />\n <div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Comments\")}\n </Typography>\n <Typography className={classes.txtBody2}>\n {appointmentDetails?.notes || t(\"No comments\")}\n </Typography>\n </div>\n </div>\n \n </div>\n </div>\n </div>\n </div>\n </Popover>\n\n <AppointmentDeleteModal\n open={openModalDelete}\n appointment={appointment}\n service={firstService}\n onClose={handleCloseModal}\n onDelete={() => handleDelete(false)}\n />\n \n <RecurringAppointmentDeleteModal\n open={showRecurringAppointmentDeleteModal}\n appointment={appointment}\n service={firstService}\n onClose={() => {\n setShowRecurringAppointmentDeleteModal(false);\n }}\n onDelete={handleDelete}\n />\n\n <AppointmentFollowUp\n open={openModalFollowUp} \n appointment={appointment}\n appointmentDetails={appointmentDetails}\n onClose={handleCloseModalFollowUp}\n />\n\n {\n isPaymentSidebarEnabled &&\n <AppointmentPaymentSidebar\n mode={paymentsSidebarMode.mode}\n itemId={paymentsSidebarMode.itemId}\n isOpen={isPaymentsSidebarOpen}\n setOpen={setPaymentsSidebarOpen}\n userName={userInfo.fullName!}\n paymentEntity={appointmentPayment}\n setPaymentEntity={setAppointmentPayment}\n formData={appointmentPaymentFormData}\n onSave={handlePaymentSave}\n onClose={resetAppointmentPaymentForm}\n isUnchanged={isAppointmentPaymentUnchanged}\n paidPreviously={oldAppointmentPaymentAmountPaid}\n recurredAppointmentOrder={appointmentDetails.recurringAppointmentOrder}\n recurredAppointmentsCount={appointmentDetails.recurredAppointmentsCount}\n totalRecurringApptPriceExcludingSelected={appointmentDetails.totalRecurringApptPriceExcludingSelected}\n />\n }\n </>\n );\n}","export enum Colors {\n Transparent = 'transparent',\n White = '#FFFFFF',\n Neutral2 = '#FAFAFA',\n Neutral3 = '#EFEFEF',\n Neutral4 = '#C9CDD3',\n Neutral5 = '#ACB7C0',\n Neutral6 = '#899198',\n Neutral7 = '#6A6E72',\n Neutral8 = '#4A4D51',\n Neutral9 = '#26292B',\n Black = '#26292B',\n GrayBlue = '#63799B',\n\n Success = '#36CE91',\n Success_dark = '#33AF7E',\n Success_background = '#D7F5E9',\n Error = '#F15857',\n Error_dark = '#CA4F4F',\n Error_background = '#FCDEDD',\n Warning = '#FFC626',\n Warning_dark = '#E8B423',\n\n CM1 = '#0069FF',\n CM1_dark = '#075DD7',\n CM2 = '#467CFC',\n CM3 = '#6797F5',\n CM4 = '#7BABF9',\n CM5 = '#E6EEFE',\n\n Grey5 = '#5C6477',\n Black0 = '#000000',\n}\n","import React, { useState } from 'react';\nimport AppointmentCard from '../AppointmentCard';\nimport { Appointment } from \"../../../../../models/appointment\";\nimport AppointmentItemTooltip from \"../../../../appointments/AppointmentItemTooltip\";\nimport { useDrag } from \"react-dnd\";\nimport { schedulerActions } from \"../../../../../redux/scheduler-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\n\ntype AppointmentTicketProps = {\n appointment: Appointment;\n};\n\nexport default function AppointmentTicket({ appointment }: AppointmentTicketProps) {\n const accountSettings = useAppSelector(selectAccountSettings);\n const mode = useAppSelector((state) => state.scheduler.currentViewName);\n const [anchorEl, setAnchorEl] = useState<HTMLElement | null>(null);\n const [isAppointmentPopupOpened, setIsAppointmentPopupOpened] = useState<boolean>(false);\n const { setIsDragging } = schedulerActions;\n const dispatch = useAppDispatch();\n \n let dragZone: string;\n if (mode === \"Day\"){\n if (accountSettings.isEnterprise && accountSettings.establishments.length > 1){\n dragZone = `Appointment-${appointment.establishmentId}`;\n } else {\n dragZone = `Appointment-${appointment.userId}`;\n }\n } else {\n dragZone = \"Appointment\";\n }\n \n const [{ opacity }, drag] = useDrag(\n () => ({\n type: dragZone,\n item: { appointment: appointment },\n canDrag: appointment.isDraggable && appointment.startDate.toMillis() > Date.now(),\n collect: (monitor) => {\n if (monitor.isDragging() && monitor.getItem()?.appointment.appointmentId === appointment.appointmentId)\n {\n dispatch(setIsDragging(true));\n }\n if (monitor.didDrop())\n {\n dispatch(setIsDragging(false));\n }\n return ({opacity: monitor.isDragging() ? 0.4 : 1})},\n }),\n )\n \n const onDragEnd = function (){\n dispatch(setIsDragging(false));\n }\n \n return (\n <div ref={drag} style={{ height: \"100%\", opacity}} onDragEnd={onDragEnd}>\n <AppointmentCard\n ref={setAnchorEl}\n anchorEl={anchorEl}\n appointment={appointment}\n onClick={() => setIsAppointmentPopupOpened(true)}\n />\n <AppointmentItemTooltip\n anchorEl={anchorEl}\n appointmentMeta={appointment}\n visible={isAppointmentPopupOpened}\n onHide={() => setIsAppointmentPopupOpened(false)}\n />\n </div>\n );\n}\n","import { Colors } from './Colors';\n\nconst scrollbarWidth = 6;\n\ntype ScrollbarOptions = {\n widerHorizontal?: boolean;\n};\n\nexport const scrollbarStyle = (opts?: ScrollbarOptions) => ({\n '&::-webkit-scrollbar': {\n width: scrollbarWidth,\n height: scrollbarWidth * (opts?.widerHorizontal ? 2 : 1),\n },\n /* Track */\n '&::-webkit-scrollbar-track': {\n background: `${Colors.Neutral3}!important`,\n borderRadius: '50px',\n },\n\n /* Handle */\n '&::-webkit-scrollbar-thumb': {\n background: `${Colors.Neutral5} !important`,\n borderRadius: '50px',\n marginTop: '10%',\n marginBottom: '10%',\n\n '&:hover': {\n background: `${Colors.Neutral7} !important`,\n },\n },\n});\n","import { makeStyles } from '@material-ui/core';\nimport { scrollbarStyle } from '../../styles/ScrollbarStyles';\n\nconst useAppointmentItemListStyles = makeStyles((theme) => ({\n root: {\n width: 420,\n marginTop: 47,\n padding: '0 0 20px 0',\n flexDirection: 'column',\n justifyContent: 'flex-end',\n alignItems: 'center',\n boxSizing: 'border-box',\n height: '100%',\n overflowY: 'hidden',\n borderRadius: 0,\n fontFamily: \"Inter, sans-serif\"\n },\n\n header: {\n margin: 0,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n height: 52,\n paddingLeft: 24,\n paddingRight: 11,\n backgroundColor: theme.colors.grey5,\n },\n\n title: {\n color: '#fff',\n fontSize: 18,\n fontWeight: 700,\n lineHeight: \"22px\"\n },\n\n list: {\n marginTop: 20,\n padding: '0 14px 0 0',\n maxHeight: 'calc(100vh - 150px)',\n overflowY: 'auto',\n overflowX: 'hidden',\n ...scrollbarStyle(),\n },\n\n labelContainer: {\n display: 'flex',\n alignItems: 'baseline',\n marginBottom: 10,\n gap: 4,\n flexDirection: 'row',\n justifyContent: 'flex-start',\n },\n\n label: {\n padding: 0,\n margin: 0,\n fontSize: 14,\n fontWeight: 700,\n color: theme.colors.clear3,\n },\n\n timezone: {\n padding: 0,\n margin: 0,\n fontSize: 10,\n fontWeight: 700,\n color: theme.colors.grey5,\n },\n\n item: {\n display: 'flex',\n marginBottom: 17,\n flexDirection: 'column',\n width: '100%',\n height: 'auto',\n '&:last-child': {\n marginBottom: 20,\n },\n },\n\n wrapper: {\n display: 'flex',\n height: '100%',\n flexDirection: 'column',\n padding: '0 13px 0 25px',\n },\n}));\n\nexport default useAppointmentItemListStyles;\n","import React from \"react\";\nimport { Box, IconButton, Popover } from '@material-ui/core';\nimport { CloseIcon } from \"../../../../../assets/icons\";\nimport groupBy from 'lodash/groupBy';\nimport { useTranslation } from 'react-i18next';\nimport { Appointment } from \"../../../../../models/appointment\";\nimport AppointmentTicket from '../AppointmentTicket';\nimport useAppointmentItemListStyles from './css';\n\nexport type AppointmentItemListProps = {\n appointments: Appointment[];\n open: boolean;\n onClose: () => void;\n};\n\nexport default function AppointmentItemList({\n appointments,\n open,\n onClose,\n}: AppointmentItemListProps) {\n const { t } = useTranslation(['general']);\n const styles = useAppointmentItemListStyles();\n\n const groupedAppointments = [...appointments].sort((a, b) => a.startDate > b.startDate ? 1 : -1)\n\n const body = (\n <ul className={styles.list}>\n {groupedAppointments.map(a =>\n <li key={a.appointmentId} className={styles.item}>\n <AppointmentTicket appointment={a} />\n </li>\n )}\n </ul>\n );\n\n return (\n <>\n <Popover\n disableScrollLock\n elevation={3}\n marginThreshold={0}\n classes={{ paper: styles.root }}\n anchorOrigin={{ horizontal: 'right', vertical: 'center' }}\n transformOrigin={{ horizontal: 'right', vertical: 'center' }}\n onClose={onClose}\n open={open}\n style={{ zIndex: 4 }}\n >\n <Box className={styles.header} marginTop={1} display=\"flex\" alignItems=\"center\">\n <span className={styles.title}>\n {appointments.length} {t('appointments')}\n </span>\n <IconButton style={{ width: 13, height: 13 }} onClick={() => onClose()}>\n <CloseIcon fill={'#fff'} />\n </IconButton>\n </Box>\n <Box className={styles.wrapper}>{body}</Box>\n </Popover>\n </>\n );\n}\n","import React, { CSSProperties } from \"react\";\nimport { makeStyles } from '@material-ui/core';\nimport { ItemComponent } from '../AppointmentsScheduler/Content';\nimport { PlusIcon } from \"../../../../assets/icons\";\nimport { memo, useRef, useState } from 'react';\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { AppointmentsGroup } from '../_common';\nimport { IScheduleAppointmentActionsMenuContext, useScheduleAppointmentActionsMenuContext } from \"../ScheduleAppointmentActionsMenu/context\";\nimport AppointmentItemList from \"./AppointmentItemList\";\nimport AppointmentTicket from \"./AppointmentTicket\";\nimport { selectAccountSettings } from \"../../../../redux/store\";\nimport { Appointment } from \"../../../../models/appointment\";\n\nconst useStyles = makeStyles({\n root: {\n position: 'relative',\n overflow: 'hidden',\n height: '100%',\n },\n item: {\n boxSizing: 'border-box',\n position: 'absolute',\n left: 'calc(100% / var(--total-count) * var(--index) * var(--width-multiplier))',\n top: 'calc(var(--cmos-aps-pixels-per-minute) * var(--appointment-offset))',\n height: 'calc(var(--cmos-aps-pixels-per-minute) * var(--appointment-duration))',\n },\n additionalBlock: {\n position: 'absolute',\n height: '100%',\n left: '75%',\n width: '25%',\n cursor: 'pointer',\n zIndex: 3,\n borderRadius: 4,\n border: 'solid 1px var(--clearMain)',\n backgroundColor: 'var(--clear5)',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n fontSize: 14,\n fontWeight: 400,\n color: 'var(--clearMain)',\n '&:hover': {\n borderWidth: 2\n },\n },\n plusBtnContainer: {\n display: 'block',\n position: 'absolute',\n zIndex: 4,\n height: 54,\n width: '40%',\n right: 0,\n '&:hover $plusBtn': {\n scale: 1,\n visibility: 'visible',\n },\n },\n plusBtn: {\n all: 'initial',\n backgroundColor: 'var(--clearMain)',\n display: 'block',\n zIndex: 2,\n height: 24,\n width: 24,\n borderRadius: 12,\n position: 'absolute',\n marginTop: 20,\n right: 0,\n color: '#fff',\n cursor: 'pointer',\n scale: 0,\n visibility: 'hidden',\n transition: 'scale .15s',\n transformOrigin: 'center',\n\n '&:hover': {\n backgroundColor: 'var(--clear2)',\n },\n\n '&>svg': {\n top: \"1.5px\",\n left: \"4px\",\n position: \"relative\"\n }\n },\n wrapper: {\n display: 'contents',\n position: 'relative',\n },\n});\n\nconst AppointmentItem: ItemComponent<AppointmentsGroup> = memo(({ value: appointmentGroup }) => {\n const styles = useStyles();\n const currentViewName = useAppSelector((state) => state.scheduler.currentViewName);\n const actionsPopupMenu = useScheduleAppointmentActionsMenuContext();\n const [openAppointmentItemList, setOpenAppointmentItemList] = useState(false);\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const appointments = appointmentGroup.list;\n const firstAppointment = appointments[0];\n\n const isGrouped = appointmentGroup.isGrouped;\n\n // all appointments in the group will belong to the same service advisor in \"day\" mode\n const advisorId = currentViewName === 'Day' ? firstAppointment.userId : null;\n const date = firstAppointment.startDate;\n const rootRef = useRef<HTMLTableCellElement | null>(null);\n\n const widthMultiplier = isGrouped ? (2 / 3) : 0.8;\n\n function getWidth(index: number, totalCount: number): number {\n return 100 - ((index / totalCount) * 100) * widthMultiplier;\n }\n\n function renderPlusButtonsForSlots(appointments: Appointment[], hasAdditionalBlock: boolean) {\n if (!appointments || appointments.length === 0 || !accountSettings) return null;\n\n const { minStart, maxEnd } = appointments.reduce(\n ({ minStart, maxEnd }, { startDate, endDate }) => ({\n minStart: startDate < minStart ? startDate : minStart,\n maxEnd: endDate > maxEnd ? endDate : maxEnd,\n }),\n {\n minStart: appointments[0]?.startDate,\n maxEnd: appointments[0]?.endDate,\n }\n );\n\n const slots = [];\n const slotDuration = accountSettings.schedulerBlockDurationMinutes;\n const slotHeight = 54;\n const totalDurationInMinutes = maxEnd.diff(minStart, 'minutes').minutes;\n const totalSlots = Math.floor(totalDurationInMinutes / slotDuration);\n\n for (let slotIndex = 0; slotIndex < totalSlots; slotIndex++) {\n const marginTop = slotIndex * slotHeight;\n\n slots.push(\n <div\n className={styles.plusBtnContainer}\n style={{\n top: `${marginTop}px`,\n }}\n key={slotIndex}\n >\n <div\n ref={rootRef}\n className={styles.plusBtn}\n onClick={(e: React.MouseEvent) => {\n const slotTime = minStart.plus({ minutes: slotDuration * slotIndex });\n actionsPopupMenu.open(slotTime, advisorId, e.clientX, e.clientY);\n }}\n >\n <PlusIcon />\n </div>\n </div>\n );\n }\n\n return slots;\n }\n\n function getBody(): React.ReactNode {\n if (appointments.length === 1) {\n return (\n <>\n <AppointmentTicket appointment={firstAppointment} />\n {\n !accountSettings.isEnterprise && firstAppointment &&\n renderPlusButtonsForSlots([firstAppointment], false)\n }\n </>\n );\n }\n\n if (appointments.length > 4 && isGrouped) {\n return (\n <div className={styles.root} style={{ '--total-count': 3 } as CSSProperties}>\n {appointments.slice(0, 3).map((a, idx) => (\n <div\n key={a.appointmentId + a.userId}\n //style={{ left: `${(50 / 2) * idx}%` }}\n className={styles.item}\n style={\n {\n '--index': idx,\n '--appointment-offset': a.startDate.diff(date).as('minutes'),\n '--appointment-duration': a.endDate.diff(a.startDate).as('minutes'),\n '--width-multiplier': widthMultiplier,\n width: `${getWidth(idx, 3)}%`,\n } as CSSProperties\n }\n >\n <AppointmentTicket appointment={a} />\n </div>\n ))}\n <div\n className={styles.additionalBlock}\n onClick={() => setOpenAppointmentItemList(true)}\n >\n +{appointments.length - 3}\n {\n !accountSettings.isEnterprise &&\n renderPlusButtonsForSlots(appointments, true)\n }\n </div>\n <AppointmentItemList\n open={openAppointmentItemList}\n appointments={appointments}\n onClose={() => setOpenAppointmentItemList(false)}\n />\n </div>\n )\n }\n\n return (\n <div className={styles.root} style={{ '--total-count': appointments.length } as CSSProperties}>\n {appointments.map((a, idx) => (\n <div\n key={a.appointmentId + a.userId}\n className={styles.item}\n style={\n {\n '--index': idx,\n '--appointment-offset': a.startDate.diff(date).as('minutes'),\n '--appointment-duration': a.endDate.diff(a.startDate).as('minutes'),\n '--width-multiplier': widthMultiplier,\n width: `${getWidth(idx, appointments.length)}%`\n } as CSSProperties\n }\n >\n <AppointmentTicket appointment={a} />\n </div>\n ))}\n {!accountSettings.isEnterprise &&\n renderPlusButtonsForSlots(appointments, false)\n }\n </div>\n )\n }\n\n let body: React.ReactNode = getBody();\n\n return (\n <div className={styles.wrapper}>\n {body}\n </div>\n );\n});\n\nexport default AppointmentItem;\n","import React from \"react\";\nimport { ItemComponentProps } from '../AppointmentsScheduler/Content';\nimport { AppointmentGridItem } from '../_common';\nimport AbsenceItem from '../AbsenceItem/AbsenceItem';\nimport AppointmentItem from './AppointmentItem';\n\nfunction AppointmentGridItemComponent({ value }: ItemComponentProps<AppointmentGridItem>) {\n if (value.type === 'appointments') return <AppointmentItem value={value.group} />;\n\n return <AbsenceItem value={value.absenceGroup} />;\n}\n\nexport default AppointmentGridItemComponent;\n","import React from \"react\";\nimport { styled } from '@material-ui/core';\nimport { ContentGridColumnComponent } from '../AppointmentsScheduler/Content/ContentGrid';\nimport moment from 'moment';\nimport { memo, useMemo } from 'react';\n\nconst ActiveColumnOverlay = styled('div')({\n backgroundColor: '#6462F31A',\n height: '100%',\n});\n\nconst ColumnDecorations: ContentGridColumnComponent<string> = memo(({ group }) => {\n const isActive = useMemo(() => moment().format('YYYY-MM-DD') === group, [group]);\n\n return <>{isActive && <ActiveColumnOverlay />}</>;\n});\n\nexport default ColumnDecorations;\n","import React from \"react\";\nimport clsx from 'clsx';\nimport moment from 'moment';\nimport { CSSProperties, useEffect, useState } from 'react';\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport {\n getGroupKeyOffsetVariable,\n useAppointmentSchedulerContext,\n} from '../AppointmentsScheduler/_util';\nimport styles from './css.module.css';\n\ntype CursorProps = {\n groupKey?: string;\n};\n\nconst now = () => {\n const m = moment();\n return m.hour() * 60 + m.minute() + m.second() / 60;\n};\n\nconst noop = () => {};\n\nexport default function Cursor({ groupKey }: CursorProps) {\n const date = useAppSelector((state) => state.scheduler.currentDate);\n const mode = useAppSelector((state) => state.scheduler.currentViewName);\n const { from, to, pixelsPerMinute } = useAppointmentSchedulerContext();\n const [element, setElement] = useState<HTMLDivElement | null>(null);\n\n useEffect(() => {\n if (!element) return noop;\n\n if (!moment().isSame(moment(date), mode === 'Week' ? 'w' : 'd')) {\n element.style.display = 'none';\n return noop;\n }\n\n const millisecondsPerPixel = (1 / pixelsPerMinute) * 60 * 1000;\n const intervalTime = Math.max(500, millisecondsPerPixel);\n const update = () => {\n const value = now();\n\n if (value < from || value > to) {\n element.style.display = 'none';\n } else {\n if (element.style.display === 'none') element.style.display = 'block';\n const pos = (value - from) * pixelsPerMinute;\n element.style.setProperty('--pos', `${pos}px`);\n }\n };\n update();\n const interval = setInterval(update, intervalTime);\n return () => clearInterval(interval);\n }, [element, from, to, pixelsPerMinute, date, mode]);\n\n return (\n <div\n className={clsx(styles.cursor, !groupKey && styles.full)}\n style={\n groupKey\n ? ({\n '--offset': `var(${getGroupKeyOffsetVariable(groupKey)})`,\n } as CSSProperties)\n : undefined\n }\n ref={setElement}\n />\n );\n}\n","import React from \"react\";\nimport { makeStyles } from '@material-ui/core';\nimport { StopComponent } from './TimeLine';\nimport moment from 'moment';\nimport { memo } from 'react';\n\nconst useStyles = makeStyles((theme) => ({\n stop: {\n color: \"#899198\",\n ...theme.typography.header6,\n },\n}));\n\nconst day = moment();\n\nconst Stop: StopComponent = memo(({ ts }) => {\n const styles = useStyles();\n day.hour(0).minute(0).add(ts, 'm');\n const str = day.format('HH:mm');\n return <span className={styles.stop}>{str}</span>;\n});\n\nexport default Stop;\n","import groupBy from 'lodash/groupBy';\nimport sortBy from 'lodash/sortBy';\nimport { DateTime } from 'luxon';\nimport React from 'react';\nimport { Appointment } from \"../../../models/appointment\";\nimport BlockSchedule from \"../../../models/blocked-schedule\";\n\nexport type AppointmentsGroup = {\n list: Appointment[];\n groupKey: string;\n key: string;\n isGrouped: boolean;\n};\n\n//namespace absenceGridItem {\n export type Slice = {\n originalAbsence: BlockSchedule;\n start: DateTime;\n end: DateTime;\n duration: number;\n };\n\n function getSlice(originalAbsence: BlockSchedule, startOfDay: DateTime): Slice | null {\n startOfDay = startOfDay.startOf('day');\n const endOfDay = startOfDay.plus({ day: 1 });\n const startsAt = originalAbsence.start;\n const endsAt = originalAbsence.end;\n\n if (startsAt >= endOfDay || endsAt <= startOfDay) return null;\n\n const blockStart = startsAt > startOfDay ? startsAt : startOfDay;\n const blockEnd = endsAt > endOfDay ? endOfDay : endsAt;\n\n return {\n originalAbsence,\n start: blockStart,\n end: blockEnd,\n duration: blockEnd.diff(blockStart).as('minutes'),\n };\n }\n\n export function getGroupKey(group: Group): string {\n return `g/${group.start.toMillis()}-${group.end.toMillis()}/${\n group.parentGroupKey\n }/${group.absences.map((x) => x.originalAbsence.id).join('-')}`;\n }\n\n /**\n * group of absence slices that overlap with each other\n */\n export type Group = {\n absences: Slice[];\n start: DateTime;\n end: DateTime;\n parentGroupKey: string;\n };\n\n function intersectsWithGroup(a: Slice, g: Group): boolean {\n return a.start < g.end && a.end > g.start;\n }\n\n function tryAddToGroup(a: Slice, g: Group): boolean {\n if (intersectsWithGroup(a, g)) {\n g.absences.push(a);\n g.start = g.start < a.start ? g.start : a.start;\n g.end = g.end > a.end ? g.end : a.end;\n return true;\n }\n\n return false;\n }\n\n function createEmptyGroup(slice: Slice, parentGroupKey: string): Group {\n return {\n absences: [slice],\n start: slice.start,\n end: slice.end,\n parentGroupKey,\n };\n }\n\n /**\n *\n * @param absences list of absences\n * @param days list of days in the format yyyy-MM-dd\n * @returns mapping of day -> list of appointment group\n */\n function groupIntersectingAbsencesByDays(\n absences: BlockSchedule[],\n days: string[]\n ): Record<string, Group[]> {\n const dayGroups: Record<string, Group[]> = {};\n const absencesSorted = sortBy(absences, (x) => x.start.toMillis());\n\n for (const dayStr of days) {\n const groups: Group[] = [];\n dayGroups[dayStr] = groups;\n const day = DateTime.fromFormat(dayStr, 'yyyy-MM-dd');\n\n for (const absence of absencesSorted) {\n const slice = getSlice(absence, day);\n if (slice === null) {\n // slice is empty meaning this absence does not overlap with the current day\n continue;\n }\n\n if (groups.length === 0) {\n groups.push({\n start: slice.start,\n end: slice.end,\n absences: [slice],\n parentGroupKey: dayStr,\n });\n } else {\n const lastGroup = groups[groups.length - 1];\n if (!tryAddToGroup(slice, lastGroup)) {\n groups.push(createEmptyGroup(slice, dayStr));\n }\n }\n }\n }\n\n return dayGroups;\n }\n\n function groupIntersectingAbsencesByUser(\n groupIds: string[],\n absences: BlockSchedule[],\n dayFilter: DateTime,\n isEnterprise: boolean\n ) {\n const groups: Record<string, Group[]> = {};\n for (const groupId of groupIds)\n groups[groupId] = [];\n\n for (const absence of absences) {\n const groupId = isEnterprise ? absence.establishmentId : absence.specialistId\n if (groupId && !groupIds.includes(groupId)) continue;\n const slice = getSlice(absence, dayFilter);\n if (slice === null) continue;\n\n const applicableGroupIds = groupId ? [groupId] : groupIds;\n\n for (const applicableGroupId of applicableGroupIds) {\n const list = groups[applicableGroupId];\n if (list.length === 0) {\n list.push(createEmptyGroup(slice, applicableGroupId));\n } else {\n const lastGroup = list[list.length - 1];\n if (!tryAddToGroup(slice, lastGroup)) {\n list.push(createEmptyGroup(slice, applicableGroupId));\n }\n }\n }\n }\n\n return groups;\n }\n\n export function createAbsencesGridItems(\n absences: BlockSchedule[],\n days: string[]\n ): AppointmentGridItem[] {\n const dayGroups = groupIntersectingAbsencesByDays(absences, days);\n const items: AppointmentGridItem[] = [];\n\n for (const groupKey in dayGroups) {\n const groups = dayGroups[groupKey];\n\n for (const group of groups) {\n items.push({\n groupKey,\n absenceGroup: group,\n duration: group.end.diff(group.start).as('minutes'),\n startsAt: group.start.hour * 60 + group.start.minute,\n key: getGroupKey(group),\n type: 'absence',\n });\n }\n }\n\n return items;\n }\n\n export function createAbsencesGridItemsForDay(\n absences: BlockSchedule[],\n day: DateTime,\n groupIds: string[],\n isEnterprise: boolean\n ): AppointmentGridItem[] {\n const groupsMapping = groupIntersectingAbsencesByUser(groupIds, absences, day, isEnterprise);\n const items: AppointmentGridItem[] = [];\n\n for (const groupKey in groupsMapping) {\n const groups = groupsMapping[groupKey];\n for (const group of groups) {\n items.push({\n groupKey,\n absenceGroup: group,\n duration: group.end.diff(group.start).as('minutes'),\n startsAt: group.start.hour * 60 + group.start.minute,\n key: getGroupKey(group),\n type: 'absence',\n });\n }\n }\n\n return items;\n }\n//}\n\nexport type AbsenceGroup = Group;\n\nexport type AppointmentGridItem = {\n key: string;\n groupKey: string;\n startsAt: number;\n duration: number;\n} & (\n | {\n type: 'appointments';\n group: AppointmentsGroup;\n }\n | {\n type: 'absence';\n absenceGroup: AbsenceGroup;\n }\n);\n\nexport function createAppointmentsGridItems(\n appointmentGroups: AppointmentsGroup[]\n): AppointmentGridItem[] {\n return appointmentGroups.map((x) => {\n const startsAt = DateTime.min(...x.list.map(d => d.startDate));\n const endsAt = DateTime.max(...x.list.map(d => d.endDate));\n\n const item: AppointmentGridItem = {\n type: 'appointments',\n group: x,\n groupKey: x.groupKey,\n duration: endsAt.diff(startsAt).as('minutes'),\n startsAt: startsAt.hour * 60 + startsAt.minute,\n key: x.key,\n };\n\n return item;\n });\n}\n\nexport function groupAppointments(appointments: Appointment[], getGroupKey: (appointment: Appointment) => string, isGrouped: boolean): AppointmentsGroup[] {\n if (!appointments.length)\n return [];\n \n const sortedAppointments = [...appointments].sort((a,b) => a.startDate.diff(b.startDate).as('minutes'));\n\n function convertAppointmentListToGroups(list: Appointment[]): Appointment[][] {\n const innerGroups = [[list[0]]];\n let j = 0;\n let end = list[0].endDate;\n\n for (let i = 1; i < list.length; i++) {\n if (list[i].startDate < end) {\n if (list[i].endDate > end) {\n end = list[i].endDate;\n }\n innerGroups[j].push(list[i]);\n } else {\n innerGroups.push([list[i]]);\n j++;\n end = list[i].endDate;\n }\n }\n\n return innerGroups\n }\n\n const groups: Appointment[][] = Object.values(groupBy(sortedAppointments, getGroupKey)).flatMap(convertAppointmentListToGroups)\n \n function getKey(appointment: Appointment) {\n const groupBy = getGroupKey(appointment);\n const dateTime = +appointment.startDate.toJSDate() / 60000;\n return `${groupBy}_${dateTime}`;\n }\n\n return groups.map((list) => ({\n list,\n groupKey: getGroupKey(list[0]),\n key: getKey(list[0]),\n isGrouped: isGrouped\n }));\n}","import { makeStyles } from '@material-ui/core';\nimport { scrollbarStyle } from './styles/ScrollbarStyles';\n\nconst useSchedulerCommonStyles = makeStyles({\n root: {\n ...scrollbarStyle(),\n },\n});\n\nexport default useSchedulerCommonStyles;\n","import React from \"react\";\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { HeaderCellComponent } from '../AppointmentsScheduler/Header';\nimport moment from 'moment';\nimport { memo, useMemo } from 'react';\nimport { useTranslation } from 'react-i18next';\n\nconst useStyles = makeStyles((theme) => ({\n dayName: {\n ...theme.typography.header5,\n fontWeight: 'normal',\n color: \"#6A6E72\"\n },\n num: {\n ...theme.typography.header5,\n color: \"#6A6E72\"\n },\n root: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n height: '100%',\n width: '100%',\n gap: 2,\n color: theme.colors.grey5,\n justifySelf: 'stretch',\n },\n active: {\n color: theme.colors.clear2,\n backgroundColor: '#6462F31A',\n \"& span\": {\n color: theme.colors.clearMain,\n }\n },\n}));\n\nconst AppointmentsHeaderCellComponent: HeaderCellComponent<string> = memo(({ value }) => {\n const date = moment(value);\n const { t } = useTranslation(['general']);\n const dayKey = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday'][\n date.isoWeekday() - 1\n ];\n const dayName = t(`${dayKey}`);\n const styles = useStyles();\n const isActive = useMemo(() => moment().format('YYYY-MM-DD') === value, [value]);\n\n return (\n <div className={clsx(styles.root, isActive && styles.active)}>\n <span className={styles.dayName}>{dayName}</span>\n <span className={styles.num}>{date.date()}</span>\n </div>\n );\n});\n\nexport default AppointmentsHeaderCellComponent;\n","export function rgba(color: string, transparency: number) {\n var result = /^#?([a-f\\d]{2})([a-f\\d]{2})([a-f\\d]{2})$/i.exec(color);\n return result\n ? `rgba(${parseInt(result[1], 16)},${parseInt(result[2], 16)},${parseInt(\n result[3],\n 16\n )}, ${transparency})`\n : '';\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"18px 24px 24px 24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n fontFamily: \"Inter, sans-serif\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#5C6477\",\n fontFamily: \"Inter, sans-serif\",\n },\n modalDateTextContainer: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n color: \"#5C6477\",\n paddingTop: 7,\n textAlign: \"center\",\n fontFamily: \"Inter, sans-serif\",\n },\n fromToLabel: {\n color: \"#5C6477\",\n fontWeight: \"bold\",\n fontFamily: \"Inter, sans-serif\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 25,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n saveAppointment: {\n background: \"#FFC626\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#FFC626\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n radioLabelRoot: {\n margin: 0,\n marginRight: 15\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n radioOption: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: \"#4A4D51\", //theme.colors.clearMain,\n },\n },\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport { DateTime } from 'luxon';\n\nimport { CrossIcon, ExclamationIcon } from \"../../../../assets/icons\";\n\nimport { DragNDropConfirmationModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { FormControlLabel, Radio, RadioGroup } from \"@material-ui/core\";\nimport {useAppSelector} from \"../../../../redux/hooks\";\n\n\nconst DragNDropConfirmationModal = (props: DragNDropConfirmationModalProps) => {\n const { open, appointment, toDateTime, onClose, onContinue } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n \n const optionUpdateOnlyThisAppointment = 0;\n const optionUpdateThisAndFutureAppointment = 1;\n const [selectedOptionToUpdate, setSelectedOptionToUpdate] = useState<number>(-1);\n const [disableButton, setDisableButton] = useState<boolean>(false);\n\n const date = (startDate: Date, endDate: Date): string => {\n const start = new Date(startDate);\n const end = new Date(endDate);\n\n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n\n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n\n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n\n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n\n const timeDifference = (today: Date, endDate: Date): string => {\n const hours = parseInt(\n `${\n (Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60 * 60)) % 24\n }`\n );\n const minutes = parseInt(\n `${(Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60)) % 60}`\n );\n if (hours > 0 && minutes < 1) {\n return `${hours}hr`;\n } else if (hours < 1 && minutes > 0) {\n return `${minutes}min`;\n } else {\n return `${hours}hr ${minutes}min`;\n }\n };\n \n const getNewEndDateTime = () => {\n const duration = appointment.endDate.diff(appointment.startDate);\n return DateTime.fromJSDate(toDateTime).plus(duration).toJSDate();\n }\n \n const handleUpdateOption = (event: any) => {\n setSelectedOptionToUpdate(+event.target.value);\n }\n\n useEffect(() => {\n setSelectedOptionToUpdate(-1);\n setDisableButton(false);\n }, [open]);\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {appointment.isRecurring ? t(\"Move recurring appointment?\") : \"\"}\n {!appointment.isRecurring ? t(\"Move this appointment?\") : \"\"}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {appointment.customerName} - {appointment.services[0]}\n </Typography>\n </div>\n <div className={classes.modalDateTextContainer}>\n <Typography className={classes.modalDateText}>\n <span className={classes.fromToLabel}>{t(\"From\")}:</span> \n {`${date(\n appointment.startDate.toJSDate(),\n appointment.endDate.toJSDate()\n )} (${timeDifference(\n appointment.startDate.toJSDate(),\n appointment.endDate.toJSDate()\n )})`}\n </Typography>\n <Typography className={classes.modalDateText}>\n <span className={classes.fromToLabel}>{t(\"ToA\")}:</span> \n {`${date(\n toDateTime, getNewEndDateTime()\n )} (${timeDifference(\n appointment.startDate.toJSDate(),\n appointment.endDate.toJSDate()\n )})`}\n </Typography>\n </div>\n \n {appointment.isRecurring &&\n <div style={{ textAlign: \"center\", marginTop: 15 }}>\n <div style={{ display: \"inline-block\" }}>\n <RadioGroup\n defaultValue={-1}\n aria-label=\"appointmentEnds\"\n name=\"appointmentEnds\"\n onChange={handleUpdateOption}\n value={selectedOptionToUpdate}\n row\n >\n\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={optionUpdateOnlyThisAppointment}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={t(\"This appointment\")}\n />\n\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={optionUpdateThisAndFutureAppointment}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={t(\"This and the following appointments\")}\n />\n\n </RadioGroup>\n </div>\n </div>\n }\n\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n disabled={disableButton || appointment.isRecurring && selectedOptionToUpdate===-1}\n className={`${classes.button} ${classes.saveAppointment}`}\n onClick={() => {\n setDisableButton(true);\n onContinue(selectedOptionToUpdate === optionUpdateThisAndFutureAppointment);\n }}\n >\n {t(\"Save changes\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default DragNDropConfirmationModal;\n","import React from \"react\";\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { useDrop } from 'react-dnd'\nimport { ContentGridTdComponent } from './AppointmentsScheduler/Content/ContentGrid';\nimport { rgba } from './styles/ColorHelpers';\nimport { DateTime } from 'luxon';\nimport { memo, useState } from 'react';\nimport { useTranslation } from 'react-i18next';\nimport { useScheduleAppointmentActionsMenuContext } from './ScheduleAppointmentActionsMenu/context';\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { AppointmentService } from \"../../../api/appointment-service\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { Appointment } from \"../../../models/appointment\";\nimport { schedulerActions } from \"../../../redux/scheduler-slice\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport DragNDropConfirmationModal from \"./DragNDropConfirmationModal\";\n\nconst useStyles = makeStyles((theme) => ({\n td: {\n position: 'relative',\n '&:hover $actionOverlay': {\n opacity: 1,\n },\n },\n\n disabled: {\n backgroundColor: '#FAFAFA',\n // '& > $actionOverlay': {\n // display: 'none',\n // },\n },\n\n actionOverlay: {\n userSelect: 'none',\n textDecoration: 'none',\n cursor: 'pointer',\n backgroundColor: rgba(theme.colors.clearMain, 0.1),\n ...theme.typography.header4,\n borderRadius: 4,\n position: 'absolute',\n left: 6,\n right: 6,\n top: 3,\n bottom: 3,\n color: theme.colors.clearMain,\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n textAlign: 'center',\n border: `1px dashed ${theme.colors.clearMain}`,\n fontSize: 11,\n },\n}));\n\nconst TdComponent: ContentGridTdComponent<string> = memo(({ group, startTimestamp }) => {\n const styles = useStyles();\n const { t } = useTranslation(['general']);\n const dispatch = useAppDispatch();\n const actionsPopupMenu = useScheduleAppointmentActionsMenuContext();\n const { enqueueAlert } = alertsActions;\n const { setAppointmentDndModalState } = schedulerActions;\n const accountSettings = useAppSelector(selectAccountSettings);\n const mode = useAppSelector((state) => state.scheduler.currentViewName);\n const currentDate = useAppSelector((state) => state.scheduler.currentDate);\n const weekDays = useAppSelector((state) => state.scheduler.weekDays);\n const daysOff = useAppSelector((state) => state.scheduler.daysOff);\n const isDragging = useAppSelector((state) => state.scheduler.isDragging);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n let dragZone: string;\n let date: DateTime;\n let userId: string | null = null;\n if (mode === \"Day\"){\n dragZone = `Appointment-${group}`;\n date = DateTime.fromJSDate(currentDate).startOf(\"day\").plus({minutes: startTimestamp});\n if (!(accountSettings.isEnterprise)) {\n userId = group;\n }\n } else {\n dragZone = \"Appointment\";\n date = DateTime.fromFormat(group, 'yyyy-MM-dd').plus({minutes: startTimestamp});\n }\n \n const isActive = isCellOpenedInSchedule();\n\n const [hovered, setHovered] = useState<boolean>(false);\n const [droppedAppointment, setDroppedAppointment] = useState<{appointment: Appointment, newDate: Date} | null>(null)\n const [{ canDrop, isOver }, drop] = useDrop(\n () => ({\n accept: dragZone,\n canDrop: () => !accountSettings.isEnterprise && date.toMillis() >= Date.now(),\n drop: async (data: {appointment: Appointment}) => {\n if (date.diff(data.appointment.startDate).toMillis() !== 0){\n setDroppedAppointment({appointment: data.appointment, newDate: date.toJSDate()})\n }\n },\n collect: (monitor: any) => ({\n isOver: monitor.isOver(),\n canDrop: monitor.canDrop(),\n }),\n }), [date]\n )\n \n function isCellOpenedInSchedule(): boolean {\n // if it's in the past, then it's outside of schedule\n //if (date.toMillis() < Date.now()) return false;\n \n const weekDay = weekDays.find(wd => wd.dayNumber == date.weekday || wd.dayNumber === 0 && date.weekday === 7)!;\n \n const openingSplitted = weekDay.opening!.split(':')\n const openingHour = parseInt(openingSplitted[0]);\n const openingMinutes = parseInt(openingSplitted[1]);\n const openingHourDecimal = +(openingHour + (openingMinutes / 60)).toFixed(2);\n const roundedOpeningHourDecimal = Math.ceil(openingHourDecimal * 2) / 2;\n \n const closingSplitted = weekDay.closing!.split(':')\n const closingHour = parseInt(closingSplitted[0]);\n const closingMinutes = parseInt(closingSplitted[1]);\n const closingHourDecimal = +(closingHour + (closingMinutes / 60)).toFixed(2);\n const roundedClosingHourDecimal = Math.floor(closingHourDecimal * 2) / 2;\n \n const cellStartHour = +(date.hour + date.minute/ 60).toFixed(2);\n \n if (roundedOpeningHourDecimal > cellStartHour\n || roundedClosingHourDecimal <= cellStartHour\n || daysOff && daysOff.findIndex((day) => day === date.weekday || day === 0 && date.weekday === 7) !== -1)\n return false;\n \n return true;\n }\n \n async function handleMoveAppointment(appointment: Appointment, startDate: Date, allAppointments: boolean) {\n setDroppedAppointment(null);\n \n const response = await AppointmentService.updateTime(appointment.appointmentId as string, startDate, allAppointments)\n \n if (response.isUpdated) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Appointment successfully modified\"),\n description: `${appointment.customerName} - ${formatDate(startDate)}`\n })\n );\n return;\n }\n \n if (!response.isUpdatable) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Please try again.\"),\n description: t(\"It is not possible to move appointments with past dates or times\"),\n })\n );\n return;\n }\n \n if (response.isScheduleBusy === true) {\n dispatch(setAppointmentDndModalState({ open: true, hasSimultaneousAppointments: response.hasSimultaneousAppointments, appointmentId: appointment.appointmentId }))\n return;\n }\n }\n \n function formatDate(date: Date | null): string {\n const day = date?.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n const month = date?.toLocaleString(localeApp, {\n month: \"long\",\n });\n const year = date?.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n \n return `${day}/${month}/${year}`;\n }\n\n return (\n <>\n <div\n ref={drop}\n aria-hidden={!isActive}\n className={clsx(styles.td, !isActive && styles.disabled)}\n onMouseOver={() => setHovered(true)}\n onMouseLeave={() => setHovered(false)}\n style={{zIndex: isDragging ? 1 : 'initial'}}\n >\n {!accountSettings.isEnterprise && hovered && !isDragging && (\n <div\n className={styles.actionOverlay}\n onClick={(e) => actionsPopupMenu.open(date, userId, e.clientX, e.clientY)}\n >\n {t('scheduleNewAppointmentOrBlock')}\n </div>\n )}\n {isOver && canDrop && (\n <div className={styles.actionOverlay}>\n {t('Drop')}\n </div>\n )}\n </div>\n {!!droppedAppointment && // render only if needed\n <DragNDropConfirmationModal\n open={!!droppedAppointment}\n appointment={droppedAppointment.appointment}\n toDateTime={droppedAppointment.newDate}\n onClose={() => setDroppedAppointment(null)}\n onContinue={(allAppointments) => handleMoveAppointment(droppedAppointment.appointment, droppedAppointment.newDate, allAppointments)}\n />\n }\n </>\n );\n});\n\nexport default TdComponent;\n","import React, { useEffect, useState } from 'react';\n\nimport { useAppDispatch } from \"../../redux/hooks\";\nimport { Dispatch } from \"redux\";\n\n\nexport default function useLocalStorageState(props: { itemKey: string, dispatchFunction: Dispatch }) {\n \n const { itemKey, dispatchFunction } = props;\n \n const dispatch = useAppDispatch();\n \n const [item, _setItem] = useState<any>();\n \n function setItem(newItem: any) {\n localStorage.setItem(itemKey, JSON.stringify(newItem))\n _setItem(newItem)\n }\n \n useEffect(() => {\n if (!item) {\n const localStorageItem = localStorage.getItem(itemKey)\n if (localStorageItem !== null) {\n const parsedItem = JSON.parse(localStorageItem);\n if (parsedItem) {\n _setItem(parsedItem)\n }\n }\n }\n }, [localStorage.getItem(itemKey)])\n \n useEffect(() => {\n dispatch(dispatchFunction(item))\n }, [item])\n \n return [item, setItem];\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n height: '100%',\n width: '100%',\n gap: 2,\n color: theme.colors.grey5,\n justifySelf: 'stretch',\n },\n popper: {\n [`& .MuiTooltip-tooltip`]: {\n padding: 8,\n borderRadius: 5,\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n boxShadow: \"0px 4px 4px 0px rgba(166, 166, 166, 0.25)\",\n marginLeft: 4,\n },\n [`& .MuiTooltip-arrow`]: {\n color: theme.colors.grey1,\n },\n }\n}));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { schedulerActions } from \"../../../../redux/scheduler-slice\";\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../redux/store\";\n\nimport useLocalStorageState from \"../../../../hooks/useLocalStorageState\";\nimport { LocalStorageKey } from \"../../../../constants/local-storage-key\";\n\nimport { IconButton, Tooltip } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { GroupAppointmentsIcon } from \"../../../../assets/icons\";\nimport { Color } from \"../../../../constants/colors\";\n\n\nexport default function AppointmentGroupingCorner() {\n\n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n\n const isEnterprise = useAppSelector(selectAccountSettings).isEnterprise;\n const userId = useAppSelector(selectUserInfo).userId;\n const { setIsGrouping } = schedulerActions;\n\n const groupingStorageKey = `${isEnterprise ? LocalStorageKey.SchedulerGroupingEnterprise : LocalStorageKey.SchedulerGrouping}${userId}`;\n //@ts-ignore\n const [schedulerGrouping, setSchedulerGrouping] = useLocalStorageState({ itemKey: groupingStorageKey, dispatchFunction: setIsGrouping });\n\n function invertGrouping() {\n setSchedulerGrouping(!schedulerGrouping)\n }\n\n return (\n <div className={classes.root}>\n <Tooltip\n classes={{\n popper: classes.popper,\n }}\n arrow\n title={`${schedulerGrouping ? t(\"Ungroup appointments\") : t(\"Group appointments\")}`}\n placement=\"right\"\n >\n <IconButton\n onClick={() => invertGrouping()}\n >\n <GroupAppointmentsIcon\n color={schedulerGrouping ? Color.clear1 : Color.gray5}\n />\n </IconButton>\n </Tooltip>\n </div>\n );\n}","import * as React from \"react\";\nimport AppointmentScheduler, {\n OnSchedulerScrollChangedHandler,\n SchedulerScrollController,\n} from '../AppointmentsScheduler';\nimport {\n ContentInnerWrapperComponent,\n GetItemDataFunction,\n} from '../AppointmentsScheduler/Content';\nimport { KeyGetterFunction } from '../AppointmentsScheduler/_util';\nimport { debounce } from 'lodash';\nimport moment from 'moment';\nimport { memo, useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport AppointmentItem from '../AppointmentItem';\nimport ColumnDecorations from '../ColumnDecorations';\nimport Cursor from '../Cursor';\nimport StopComponent from '../AppointmentsScheduler/StopComponent';\nimport {\n AppointmentGridItem,\n createAbsencesGridItems,\n createAppointmentsGridItems,\n groupAppointments,\n} from '../_common';\nimport useSchedulerCommonStyles from '../css';\nimport AppointmentsHeaderCellComponent from './HeaderCellComponent';\nimport TdComponent from '../TdComponent';\nimport { Appointment } from \"../../../../models/appointment\";\nimport BlockSchedule from \"../../../../models/blocked-schedule\";\nimport AppointmentGroupingCorner from \"../AppointmentGroupingCorner\";\n\nconst getAppointmentKey: KeyGetterFunction<AppointmentGridItem> = (a) => a.key;\nconst getAppointmentGroupKey: KeyGetterFunction<AppointmentGridItem> = (a) => a.groupKey;\nconst getGroupKey: KeyGetterFunction<string> = (d) => d;\nconst getAppointmentData: GetItemDataFunction<AppointmentGridItem> = (a) => {\n return {\n ts: a.startsAt,\n sizeInMinutes: a.duration,\n };\n};\n\nexport type WeekSchedulerProps = {\n appointments: Appointment[];\n dateReference: Date;\n stopsInterval: number;\n absences: BlockSchedule[];\n};\n\nconst ContentInnerWrapper: ContentInnerWrapperComponent = memo(({ children }) => {\n const activeGroupKey = moment().format('YYYY-MM-DD');\n\n return (\n <>\n {children}\n <Cursor groupKey={activeGroupKey} />\n </>\n );\n});\n\nexport default function WeekScheduler({\n dateReference,\n appointments,\n stopsInterval,\n absences,\n}: WeekSchedulerProps) {\n const [scrollController, setScrollController] = useState<SchedulerScrollController | null>(\n null\n );\n const styles = useSchedulerCommonStyles();\n const isGrouping = useAppSelector((state) => state.scheduler.isGrouping);\n\n const days = useMemo(() => {\n const monday = moment(dateReference)\n .hour(0)\n .minute(0)\n .second(0)\n .millisecond(0)\n .startOf('isoWeek');\n return Array.from({ length: 7 }).map((_, i) =>\n monday.clone().add(i, 'day').format('YYYY-MM-DD')\n );\n }, [dateReference]);\n const appointmentGroups = useMemo(() => groupAppointments(appointments, (app) => app.startDate.toFormat('yyyy-MM-dd'), isGrouping), [appointments, isGrouping]);\n const [from, to] = [0, 24 * 60];\n const scrolledRef = useRef(false);\n\n useEffect(() => {\n if (!scrollController) return;\n if (scrolledRef.current) return;\n scrolledRef.current = true;\n const now = moment();\n // if (uiData.scrollInMinutes !== null) { // todo: try use this for navigation from bell\n // scrollController.scrollAtTopInMinutes(uiData.scrollInMinutes);\n // } else {\n scrollController.scrollAtCenterInMinutes(now.hour() * 60 + now.minute() - from);\n // }\n }, [scrollController, /*uiData,*/ from]);\n\n const dispatch = useAppDispatch();\n const onScrollChanged: OnSchedulerScrollChangedHandler = useCallback(\n (data, _event) => {\n //dispatch(setWeekSchedulerScroll(data.scrollTopMinutes));\n },\n [dispatch]\n );\n const onScrollChangedDebounced = useMemo(\n () => debounce(onScrollChanged, 1000),\n [onScrollChanged]\n );\n\n const gridItems = useMemo(() => {\n const items: AppointmentGridItem[] = [\n ...createAbsencesGridItems(absences, days),\n ...createAppointmentsGridItems(appointmentGroups),\n ];\n return items;\n }, [absences, days, appointmentGroups]);\n\n return (\n <AppointmentScheduler<AppointmentGridItem, string>\n groups={days}\n classes={{ root: styles.root }}\n items={gridItems}\n showTimezone={false}\n getItemKey={getAppointmentKey}\n getItemGroupKey={getAppointmentGroupKey}\n getItemData={getAppointmentData}\n getGroupKey={getGroupKey}\n components={{\n StopComponent,\n HeaderCellComponent: AppointmentsHeaderCellComponent,\n ItemComponent: AppointmentItem,\n ContentGridColumnComponent: ColumnDecorations,\n ContentGridTdComponent: TdComponent,\n CornerComponent: AppointmentGroupingCorner,\n ContentInnerWrapperComponent: ContentInnerWrapper\n }}\n range={[from, to]} // full day\n sizes={{\n columnWidth: 160,\n headerHeight: 50,\n timelineWidth: 120,\n pixelsPerMinute: (1.8 * 30) / stopsInterval,\n }}\n stopsInterval={stopsInterval}\n scrollControllerRef={setScrollController}\n onScrollChanged={onScrollChangedDebounced}\n />\n );\n}\n","import React from \"react\";\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { HeaderCellComponent } from '../AppointmentsScheduler/Header';\nimport { memo, useMemo } from 'react';\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../../redux/store\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.header5,\n color: \"#6A6E72\",\n textAlign: 'center',\n },\n}));\n\nconst AppointmentsHeaderCellComponent: HeaderCellComponent<string> = memo(({ value }) => {\n const styles = useStyles();\n const accountSettings = useAppSelector(selectAccountSettings);\n const allUsers = useAppSelector((state) => state.scheduler.allUsers);\n const isEnterprise = accountSettings.isEnterprise === true && accountSettings.establishments.length > 0;\n let title;\n if (isEnterprise) {\n const est = useMemo(() => accountSettings.establishments.find((x) => x.key === value), [accountSettings.establishments, value]);\n title = est?.value ?? value;\n } else {\n const user = useMemo(() => (allUsers ?? []).find((x) => x.key === value), [allUsers, value]);\n title = user?.value ?? value;\n }\n\n return <div className={clsx(styles.root)}>{title}</div>;\n});\n\nexport default AppointmentsHeaderCellComponent;\n","import React from 'react';\n\nexport const DaySchedulerDateContext = React.createContext<string>('');\n","import * as React from \"react\";\nimport { DateTime } from 'luxon';\nimport AppointmentScheduler, {\n OnSchedulerScrollChangedHandler,\n SchedulerScrollController,\n} from '../AppointmentsScheduler';\nimport {\n ContentInnerWrapperComponent,\n GetItemDataFunction,\n} from '../AppointmentsScheduler/Content';\nimport { KeyGetterFunction } from '../AppointmentsScheduler/_util';\nimport moment from 'moment';\nimport { memo, useEffect, useMemo, useRef, useState } from 'react';\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport AppointmentItem from '../AppointmentItem';\nimport ColumnDecorations from '../ColumnDecorations';\nimport Cursor from '../Cursor';\nimport StopComponent from '../AppointmentsScheduler/StopComponent';\nimport {\n AppointmentGridItem,\n createAbsencesGridItemsForDay,\n createAppointmentsGridItems,\n groupAppointments,\n} from '../_common';\nimport useSchedulerCommonStyles from '../css';\nimport AppointmentsHeaderCellComponent from './HeaderCellComponent';\nimport TdComponent from '../TdComponent';\nimport { DaySchedulerDateContext } from './_context';\nimport { Appointment } from \"../../../../models/appointment\";\nimport BlockSchedule from \"../../../../models/blocked-schedule\";\nimport { selectAccountSettings } from \"../../../../redux/store\";\nimport { SelectItem } from \"../../Select\";\nimport AppointmentGroupingCorner from \"../AppointmentGroupingCorner\";\n\nconst getAppointmentKey: KeyGetterFunction<AppointmentGridItem> = (a) => a.key;\nconst getAppointmentGroupKey: KeyGetterFunction<AppointmentGridItem> = (a) => a.groupKey;\nconst getGroupKey: KeyGetterFunction<string> = (d) => d;\nconst getAppointmentData: GetItemDataFunction<AppointmentGridItem> = (a) => {\n return {\n ts: a.startsAt,\n sizeInMinutes: a.duration,\n };\n};\n\nexport type DaySchedulerProps = {\n appointments: Appointment[];\n stopsInterval: number;\n dateReference: Date;\n absences: BlockSchedule[];\n};\n\nconst ContentInnerWrapper: ContentInnerWrapperComponent = memo(({ children }) => {\n return (\n <>\n {children}\n <Cursor />\n </>\n );\n});\n\nexport default function DayScheduler({ appointments, stopsInterval, dateReference, absences }: DaySchedulerProps) {\n const accountSettings = useAppSelector(selectAccountSettings);\n const selectedEstablishments = useAppSelector(state => state.enterprise.selectedEstablishments);\n const allUsers = useAppSelector((state) => state.scheduler.allUsers);\n const selectedUsers = useAppSelector((state) => state.scheduler.selectedUsers);\n const isGrouping = useAppSelector((state) => state.scheduler.isGrouping);\n \n const isEnterprise = accountSettings.isEnterprise === true && accountSettings.establishments.length > 0;\n const appointmentGroups = useMemo(() => groupAppointments(appointments, (app) => isEnterprise ? app.establishmentId! : app.userId, isGrouping), [appointments, isGrouping, isEnterprise]);\n const [scrollController, setScrollController] = useState<SchedulerScrollController | null>(\n null\n );\n const styles = useSchedulerCommonStyles();\n const [from, to] = [0, 24 * 60];\n const scrolledRef = useRef(false);\n \n useEffect(() => {\n if (!scrollController) return;\n if (scrolledRef.current) return;\n scrolledRef.current = true;\n const now = moment();\n scrollController.scrollAtCenterInMinutes(now.hour() * 60 + now.minute() - from);\n }, [scrollController, from]);\n \n let groups: string[];\n if (isEnterprise) {\n groups = accountSettings.establishments\n .filter(es => !selectedEstablishments || selectedEstablishments.length === 0 || selectedEstablishments.includes(es.key))\n .sort(compareEstablishments)\n .map((x) => x.key)\n } else {\n groups = selectedUsers?.length ? selectedUsers : allUsers.map((x) => x.key);\n }\n \n function compareEstablishments(a: SelectItem, b: SelectItem) {\n if (a.value < b.value) {\n return -1;\n }\n if (a.value > b.value) {\n return 1;\n }\n return 0;\n }\n \n const gridItems = useMemo(() => {\n const items: AppointmentGridItem[] = [\n ...createAbsencesGridItemsForDay(absences, DateTime.fromJSDate(dateReference), groups, isEnterprise),\n ...createAppointmentsGridItems(appointmentGroups),\n ];\n return items;\n }, [absences, dateReference, appointmentGroups, groups]);\n\n return (\n <DaySchedulerDateContext.Provider value={dateReference.toISOString()}>\n <AppointmentScheduler<AppointmentGridItem, string>\n groups={groups}\n classes={{ root: styles.root }}\n showTimezone={false}\n items={gridItems}\n getItemKey={getAppointmentKey}\n getItemGroupKey={getAppointmentGroupKey}\n getItemData={getAppointmentData}\n getGroupKey={getGroupKey}\n components={{\n StopComponent,\n HeaderCellComponent: AppointmentsHeaderCellComponent,\n ItemComponent: AppointmentItem,\n ContentGridColumnComponent: ColumnDecorations,\n ContentInnerWrapperComponent: ContentInnerWrapper,\n CornerComponent: AppointmentGroupingCorner,\n ContentGridTdComponent: TdComponent,\n }}\n range={[from, to]} // full day\n sizes={{\n columnWidth: 150,\n headerHeight: 50,\n timelineWidth: 120,\n pixelsPerMinute: (1.8 * 30) / stopsInterval,\n }}\n stopsInterval={stopsInterval}\n scrollControllerRef={setScrollController}\n />\n </DaySchedulerDateContext.Provider>\n );\n}\n","import { DateTime } from 'luxon';\n\nexport default class BlockSchedule {\n \n id?: string | null;\n specialistId?: string | null;\n specialist?: string;\n blockedReasonId: string;\n blockedReason?: string;\n isBlockedReasonPredetermined?: boolean;\n allDay: boolean;\n start: DateTime;\n end: DateTime;\n notes?: string | null;\n isEditable?: boolean;\n isBlockedMultiple: boolean;\n blockerCount: number;\n blockers: BlockSchedule[];\n establishmentId: string | null;\n establishmentName: string | null;\n\n constructor(x?: BlockSchedule | any) {\n if (x != null && typeof x === \"object\") {\n this.id = x.id;\n this.specialistId = x.userId !== null ? x.userId : \"AllSpecialists\";\n this.specialist = x.user;\n this.blockedReasonId = x.blockedReasonId;\n this.blockedReason = x.blockedReason;\n this.isBlockedReasonPredetermined = x.isBlockedReasonPredetermined;\n this.allDay = x.allDay;\n this.start = DateTime.fromISO(x.start);\n this.end = DateTime.fromISO(x.end);\n this.notes = x.notes;\n this.isBlockedMultiple = x.isBlockedMultiple;\n this.blockerCount = x.blockerCount;\n this.blockers = x.blockers?.map((b: any) => new BlockSchedule(b)) ?? [];\n this.establishmentId = x.establishmentId;\n this.establishmentName = x.establishmentName;\n }\n else {\n this.id = null;\n this.specialistId = null;\n this.blockedReasonId = \"\";\n this.blockedReason = \"\";\n this.allDay = false;\n this.start = DateTime.now();\n this.end = DateTime.now();\n this.notes = null;\n this.isBlockedMultiple = false;\n this.blockerCount = 0;\n this.blockers = [];\n this.establishmentId = null;\n this.establishmentName = null;\n }\n }\n}\n\n//Form Props\nexport interface FormProps {\n users: any;\n item: BlockSchedule;\n validator: Validator;\n onChange?: (entity: BlockSchedule) => void; //isValid: boolean,\n onModify?: () => void;\n}\n\n//Form Valid\nexport interface Validator {\n specialistId: boolean;\n reasonId: boolean;\n date: boolean;\n start: boolean;\n end: boolean;\n}\n","import { ApiClient } from \"./api-client\";\nimport BlockedSchedule from \"../models/blocked-schedule\";\nimport { Response } from \"../models/response\";\nimport { Appointment } from \"../models/appointment\";\nimport BlockSchedule from \"../models/blocked-schedule\";\n\n\nexport default class BlockedScheduleService {\n\n private static baseUrl: string = \"/blockedschedule\";\n\n private static isoDate(date: Date): string {\n const year = date.toLocaleString(\"en-US\", {\n year: \"numeric\",\n });\n const month = date.toLocaleString(\"en-US\", {\n month: \"2-digit\",\n });\n const day = date.toLocaleString(\"en-US\", {\n day: \"2-digit\",\n });\n \n return `${year}-${month}-${day}`;\n }\n\n private static handleTime(date: Date): string {\n const time = date.toLocaleString(\"en-US\", {\n hourCycle: \"h23\",\n hour: \"2-digit\",\n minute: \"2-digit\",\n second: \"2-digit\"\n });\n\n return `${this.isoDate(date)}T${time}`;\n }\n\n static createBlockedSchedule(blocked: BlockedSchedule, forceSave: boolean = false): Promise<any> {\n const blockSchedule = {\n ...blocked,\n start: this.handleTime(blocked.start.toJSDate()),\n end: this.handleTime(blocked.end.toJSDate()),\n forceSave\n }\n\n return ApiClient\n .post(`${this.baseUrl}/createBlockedSchedule`, blockSchedule)\n .then(data => {\n const blockedschedule = new BlockedSchedule(data.blockedschedule);\n return {\n blockedschedule,\n forbiddenToBlock: data.forbiddenToBlock,\n appointmentsNotServed: data.appointmentsNotServed,\n }\n });\n }\n\n static updateBlockedSchedule(blocked: BlockedSchedule, forceSave: boolean = false): Promise<any> {\n const blockSchedule = {\n ...blocked,\n start: this.handleTime(blocked.start.toJSDate()),\n end: this.handleTime(blocked.end.toJSDate()),\n forceSave\n }\n\n return ApiClient\n .put(`${this.baseUrl}/updateBlockedSchedule`, blockSchedule)\n .then(data => {\n const blockedschedule = new BlockedSchedule(data.blockedschedule);\n return {\n blockedschedule,\n forbiddenToBlock: data.forbiddenToBlock,\n appointmentsNotServed: data.appointmentsNotServed,\n }\n });\n }\n\n static getBlockedScheduleByAccount(dateFrom: Date, dateTo: Date): Promise<any[]> {\n const params = `${\"?DateFrom=\" + dateFrom.toISOString().replace(\"Z\", \"\") + \"&DateTo=\" + dateTo.toISOString().replace(\"Z\", \"\")}`;\n let urlEndpoint = `${this.baseUrl}/getblockedschedule${params}`;\n return ApiClient.get(urlEndpoint).then((data) => data.blockedSchedules.map((a: any) => new BlockSchedule(a)));\n }\n \n static getBlockedScheduleByEstablishments(dateFrom: Date, dateTo: Date, establishmentIds: string[] | undefined): Promise<any[]> {\n let urlEndpoint = `${this.baseUrl}/getblockedschedulebyestablishments?` +\n Object.entries({\n DateFrom: dateFrom.toISOString().replace(\"Z\", \"\"),\n DateTo: dateTo.toISOString().replace(\"Z\", \"\"),\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\");\n return ApiClient.get(urlEndpoint).then((data) => data.blockedSchedules.map((a: any) => new BlockSchedule(a)));\n }\n\n \n static getBlockedScheduleById(id: string): Promise<BlockSchedule> {\n const params = `?id=${id}`;\n let urlEndpoint = `${this.baseUrl}/getblockedschedulebyid${params}`;\n return ApiClient.get(urlEndpoint).then((data) => {\n const a = data.blockedSchedule;\n return new BlockSchedule(a);\n });\n }\n\n static deleteBlockedSchedule(blocked: BlockedSchedule): Promise<any> {\n return ApiClient.remove(`${this.baseUrl}/deleteBlockedSchedule?id=${blocked.id}`)\n .then(data => {\n return {\n entity: new BlockedSchedule(data.blockedschedule),\n forbiddenDelete: data.forbiddenDelete\n };\n });\n }\n\n}\n","import { User } from \"./user\";\n\nexport class UsersResponse {\n users: User[] | null;\n totalUsers: number | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.users = x.users;\n this.totalUsers = x.totalUsers;\n } else {\n this.users = null;\n this.totalUsers = null;\n }\n }\n}","export enum UserCommissionType {\n Default = 0,\n ByService = 1\n}\n","export enum CommissionType {\n Absolute = 0,\n Percentage = 1\n}\n","export class UserModel {\n id: string | null;\n authenticationId: string | null;\n firstName: string | null;\n lastName: string | null;\n hasServicesInCharge : boolean\n servicesInChargeCount: number\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.authenticationId = x.authenticationId;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.hasServicesInCharge = x.hasServicesInCharge;\n this.servicesInChargeCount = x.servicesInChargeCount;\n } else {\n this.id = null;\n this.authenticationId = null;\n this.firstName = null;\n this.lastName = null;\n this.hasServicesInCharge = false;\n this.servicesInChargeCount = 0;\n }\n }\n}\n","import { JobPosition } from \"./job-position\";\n\nexport class UserGeneralInfo {\n id: string | null;\n friendlyId: number;\n photoS3Key?: string;\n photoURL?: string;\n name: string | null;\n lastName: string | null;\n email: string | null;\n mobileCodeIso3: string | null;\n mobileNumber: string | null;\n jobPosition: JobPosition | null;\n hasServicesInCharge: boolean;\n canPrescribeTreatment: boolean\n\n constructor(x? : any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.friendlyId = x.friendlyId;\n this.photoS3Key = x.photoS3Key;\n this.photoURL = x.photoURL;\n this.name = x.name;\n this.lastName = x.lastName;\n this.email = x.email;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileNumber = x.mobileNumber;\n this.jobPosition = x.jobPosition ?? null;\n this.hasServicesInCharge = x.hasServicesInCharge;\n this.canPrescribeTreatment = x.canPrescribeTreatment;\n\n } else {\n this.id = null;\n this.friendlyId = 0;\n this.photoS3Key = undefined;\n this.photoURL = undefined;\n this.name = null;\n this.lastName = null;\n this.email = null;\n this.mobileCodeIso3 = null;\n this.mobileNumber = null;\n this.jobPosition = null;\n this.hasServicesInCharge = true;\n this.canPrescribeTreatment = false;\n }\n }\n}","import { DayOfWeek } from \"./enums/day-of-week\";\n\nexport class UserScheduleInfo {\n schedule : UserScheduleDay[];\n \n constructor(days: UserScheduleDay[]) {\n this.schedule = days ? JSON.parse(JSON.stringify(days)) : [];\n }\n}\n\nexport class UserScheduleDay {\n dayOfWeek: DayOfWeek;\n isActive: boolean;\n windows: UserScheduleWindow[];\n \n constructor(dayOfWeek: DayOfWeek, windows: UserScheduleWindow[], isActive?: boolean) {\n this.dayOfWeek = dayOfWeek;\n this.windows = JSON.parse(JSON.stringify(windows));\n this.isActive = isActive ?? false;\n }\n}\n\nexport class UserScheduleWindow {\n timeStart: string;\n timeClosing: string;\n \n constructor(timeStart : string, timeClosing : string) {\n this.timeStart = timeStart;\n this.timeClosing = timeClosing;\n }\n}","import { ServiceCategoryEntity } from \"./service-category-entity\";\n\nexport class UserServicesInfo {\n serviceCategories: ServiceCategoryEntity[];\n \n constructor(services? : ServiceCategoryEntity[]) {\n this.serviceCategories = services ? JSON.parse(JSON.stringify(services)) : [];\n }\n}","import {UserCommissionType} from \"./enums/user-commission-type\";\nimport {CommissionByServiceEntity} from \"./commission-by-service-entity\";\nimport {CommissionType} from \"./enums/commission-type\";\n\nexport class UserCommissionInfo {\n isCommissionEnabled: boolean;\n userCommissionType: UserCommissionType;\n initialUserCommissionType: UserCommissionType;\n commissionType: CommissionType | null;\n commissionValue: number | null;\n commissionsByServices: CommissionByServiceEntity[];\n\n constructor(x?: any) {\n if (Array.isArray(x)){\n this.commissionsByServices = x;\n this.isCommissionEnabled = true;\n this.commissionType = CommissionType.Absolute;\n this.commissionValue = 0;\n this.userCommissionType = UserCommissionType.ByService;\n this.initialUserCommissionType = UserCommissionType.ByService;\n }\n else if (typeof x === \"object\") {\n this.isCommissionEnabled = x.isCommissionEnabled;\n this.userCommissionType = x.userCommissionType;\n this.initialUserCommissionType = x.userCommissionType;\n this.commissionType = x.commissionType;\n this.commissionValue = x.commissionValue;\n this.commissionsByServices = x.commissionsByServices || [];\n }\n else {\n this.isCommissionEnabled = true;\n this.userCommissionType = UserCommissionType.ByService;\n this.initialUserCommissionType = UserCommissionType.ByService;\n this.commissionType = CommissionType.Absolute;\n this.commissionValue = 0;\n this.commissionsByServices = [];\n }\n this.commissionsByServices = this.commissionsByServices.sort((a, b) => a.serviceName.localeCompare(b.serviceName))\n }\n}","export class UserPermissionsInfo {\n hasAdminAccess: boolean;\n hasCustomerInfoVisible: boolean;\n hasMassiveSendings: boolean;\n notifyOnServiceInCharge: boolean;\n notifyOnCustomerRequiresAttention: boolean;\n notifyOnCashRegisterClosing: boolean;\n showAllAppointments: boolean;\n canRegisterPayments: boolean;\n canOpenCloseCashRegister: boolean;\n canMakeCashRegisterMovements: boolean;\n canSeeClinicalFile: boolean;\n canInteractWithEvolutionNotes: boolean;\n canInteractWithPatientFiles: boolean;\n hasAccessToWhatsAppConversationsAndNotifications: boolean;\n hasAccessToReports: boolean;\n hasAccessToScheduleAllSpecialists: boolean;\n showPrices: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.hasAdminAccess = x.hasAdminAccess;\n this.hasMassiveSendings = x.hasMassiveSendings;\n this.notifyOnServiceInCharge = x.notifyOnServiceInCharge;\n this.notifyOnCustomerRequiresAttention = x.notifyOnCustomerRequiresAttention;\n this.hasCustomerInfoVisible = x.hasCustomerInfoVisible ?? true;\n this.notifyOnCashRegisterClosing = x.notifyOnCashRegisterClosing;\n this.showAllAppointments = x.showAllAppointments;\n this.canRegisterPayments = x.canRegisterPayments;\n this.canOpenCloseCashRegister = x.canOpenCloseCashRegister;\n this.canMakeCashRegisterMovements = x.canMakeCashRegisterMovements;\n this.canSeeClinicalFile = x.canSeeClinicalFile;\n this.canInteractWithEvolutionNotes = x.canInteractWithEvolutionNotes;\n this.canInteractWithPatientFiles = x.canInteractWithPatientFiles;\n this.hasAccessToWhatsAppConversationsAndNotifications = x.hasAccessToWhatsAppConversationsAndNotifications;\n this.hasAccessToReports = x.hasAccessToReports;\n this.hasAccessToScheduleAllSpecialists = x.hasAccessToScheduleAllSpecialists;\n this.showPrices = x.showPrices;\n }\n else {\n this.notifyOnServiceInCharge = true;\n this.notifyOnCustomerRequiresAttention = false;\n this.hasCustomerInfoVisible = true;\n this.hasAdminAccess = false;\n this.hasMassiveSendings = false;\n this.notifyOnCashRegisterClosing = false;\n this.showAllAppointments = false;\n this.canRegisterPayments = false;\n this.canOpenCloseCashRegister = false;\n this.canMakeCashRegisterMovements = false;\n this.canSeeClinicalFile = false;\n this.canInteractWithEvolutionNotes = false;\n this.canInteractWithPatientFiles = false;\n this.hasAccessToWhatsAppConversationsAndNotifications = true;\n this.hasAccessToReports = true;\n this.hasAccessToScheduleAllSpecialists = true;\n this.showPrices = false;\n }\n }\n}","import { SignatureImageType } from \"./enums/signature-image-type\";\nimport { FieldAndValue } from \"./field-and-value\";\n\nexport class UserProfessionalInfo {\n fieldsAndValues: FieldAndValue[];\n signatureImageUrl: string | null;\n signatureReactCanvasDrawJson: string | null\n signType: SignatureImageType | null;\n uploadedSignatureWasDeleted: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.fieldsAndValues = x.fieldsAndValues;\n this.signatureImageUrl = x.signatureImageUrl;\n this.signType = x.signType;\n this.signatureReactCanvasDrawJson = x.signatureReactCanvasDrawJson;\n this.uploadedSignatureWasDeleted = x.uploadedSignatureWasDeleted;\n }\n else {\n this.fieldsAndValues = [];\n this.signatureImageUrl = null;\n this.signType = null;\n this.signatureReactCanvasDrawJson = null;\n this.uploadedSignatureWasDeleted = false;\n }\n }\n}","import { UserGeneralInfo } from \"./user-general-info\";\nimport { UserScheduleInfo } from \"./user-schedule-info\";\nimport { UserServicesInfo } from \"./user-services-info\";\nimport { UserCommissionInfo } from \"./user-commission-info\";\nimport { UserPermissionsInfo } from \"./user-permissions-info\";\nimport { UserProfessionalInfo } from \"./user-professional-info\";\n\nexport class UserEntity {\n accountId?: string;\n general: UserGeneralInfo;\n schedule: UserScheduleInfo;\n services: UserServicesInfo;\n commission: UserCommissionInfo;\n permissions: UserPermissionsInfo;\n professionalInformation: UserProfessionalInfo;\n\n constructor(\n accountId?: string,\n general?: UserGeneralInfo,\n schedule?: UserScheduleInfo,\n services?: UserServicesInfo,\n commission?: UserCommissionInfo,\n permissions?: UserPermissionsInfo,\n professionalInformation?: UserProfessionalInfo\n )\n {\n this.accountId = accountId;\n this.general = general !== undefined ? new UserGeneralInfo(general) : new UserGeneralInfo();\n this.schedule = schedule ? new UserScheduleInfo(schedule.schedule) : new UserScheduleInfo([]);\n this.services = services ? new UserServicesInfo(services.serviceCategories) : new UserServicesInfo();\n this.commission = commission ? new UserCommissionInfo(commission) : new UserCommissionInfo();\n this.permissions = permissions ? new UserPermissionsInfo(permissions) : new UserPermissionsInfo();\n this.professionalInformation = professionalInformation ? new UserProfessionalInfo(professionalInformation) : new UserProfessionalInfo();\n }\n}","export class IsUserPhoneDuplicatedModel {\n \n isDuplicated: boolean;\n userId: string | null;\n userFirstName: string | null;\n userLastName: string | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.isDuplicated = x.isDuplicated;\n this.userId = x.userId;\n this.userFirstName = x.userFirstName;\n this.userLastName = x.userLastName;\n } else {\n this.isDuplicated = false;\n this.userId = null;\n this.userFirstName = null;\n this.userLastName = null;\n }\n }\n }","export class IsUserEmailDuplicatedModel {\n \n isDuplicated: boolean;\n userId: string | null;\n userFullName: string | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.isDuplicated = x.isDuplicated;\n this.userId = x.userId;\n this.userFullName = x.userFullName;\n } else {\n this.isDuplicated = false;\n this.userId = null;\n this.userFullName = null;\n }\n }\n }","import { ApiClient } from \"./api-client\";\nimport { UsersResponse } from \"../models/users-response\";\n\nimport { UserModel } from \"../models/user-model\";\nimport { UserEntity } from \"../models/user-entity\";\nimport { ServiceCategoryEntity } from \"../models/service-category-entity\";\nimport { UserScheduleInfo } from \"../models/user-schedule-info\";\nimport { IsUserPhoneDuplicatedModel } from \"../models/is-user-phone-duplicated-response\";\nimport { IsUserEmailDuplicatedModel } from \"../models/is-user-email-duplicated-response\";\nimport { CommissionByServiceEntity } from \"../models/commission-by-service-entity\";\n\nexport class UserService {\n private static baseUrl: string = \"/user\";\n\n static getUserServices(establishmentAccountId?: string): Promise<ServiceCategoryEntity[]> {\n let endpoint = `${this.baseUrl}/getuserservices`;\n if (establishmentAccountId) {\n endpoint += `?accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint).then(\n (data) => data.serviceCategories\n );\n }\n\n static getCommissionsByServices(establishmentAccountId?: string): Promise<CommissionByServiceEntity[]> {\n let endpoint = `${this.baseUrl}/getcommissionsbyservices`;\n if (establishmentAccountId) {\n endpoint += `?accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint).then(\n (data) => data.commissionsByServices\n );\n }\n\n static getUsers(\n page: number,\n pageSize: number,\n order?: string,\n orderBy?: string,\n establishmentAccountId?: string\n ): Promise<UsersResponse> {\n let urlEndpoint = `${this.baseUrl}/getbyaccount?page=${page}&pageSize=${pageSize}`;\n if (order && orderBy) {\n urlEndpoint += `&order=${order}&orderBy=${orderBy}`;\n }\n if(establishmentAccountId){\n urlEndpoint += `&accountId=${establishmentAccountId}`;\n }\n\n return ApiClient.get(urlEndpoint).then((data) => new UsersResponse(data));\n }\n\n static async getUserById(userId: string, establishmentAccountId?: string): Promise<UserEntity> {\n let endpoint = `${this.baseUrl}/get?userId=${userId}`;\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint).then(\n (data) =>\n new UserEntity(\n data.accountId,\n data.user?.general,\n data.user?.schedule,\n data.user?.services,\n data.user?.commission,\n data.user?.permissions,\n data.user?.professionalInformation\n )\n );\n }\n\n static async createUser(user: UserEntity, signatureImage: File | null, establishmentAccountId?: string): Promise<UserEntity> {\n const formData = new FormData();\n\n formData.append(\"UserEntityDtoSerialized\", JSON.stringify(user));\n if (establishmentAccountId) {\n formData.append(\"AccountId\", establishmentAccountId);\n }\n\n // Append the signature if it exists\n if (signatureImage instanceof File) {\n formData.append(\"SignatureImage\", signatureImage);\n }\n\n return await ApiClient\n .post(`${this.baseUrl}/create`, formData)\n .then(data => new UserEntity(data.user));\n }\n\n static async updateUser(user: UserEntity, signatureImage: File | null, establishmentAccountId?: string): Promise<UserEntity> {\n const formData = new FormData();\n\n formData.append(\"UserEntityDtoSerialized\", JSON.stringify(user));\n if (establishmentAccountId) {\n formData.append(\"AccountId\", establishmentAccountId);\n }\n\n // Append the signature if it exists\n if (signatureImage instanceof File) {\n formData.append(\"SignatureImage\", signatureImage);\n }\n\n return await ApiClient\n .put(`${this.baseUrl}/update`, formData)\n .then(data => new UserEntity(data.user));\n }\n\n static async deleteUser(userId: string, establishmentAccountId?: string): Promise<boolean> {\n let endpoint = `${this.baseUrl}/Delete?Id=${userId}`;\n if(establishmentAccountId){\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return await ApiClient.remove(endpoint).then(\n (data) => (data.succeeded)\n );\n }\n\n static getUsersBaseInfoByAccount(onlyWithServicesInCharge: boolean): Promise<UserModel[]> {\n return ApiClient.get(`${this.baseUrl}/GetUsersByAccount?onlyWithServicesInCharge=${onlyWithServicesInCharge}`).then((data) =>\n data.users.map((user: any) => new UserModel(user))\n );\n }\n\n static getUsersBaseInfoByEstablishments(establishmentIds: string[] | undefined): Promise<UserModel[]> {\n return ApiClient.get(\n `${this.baseUrl}/GetUsersByEstablishments?` +\n Object.entries({\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\")\n ).then((data) =>\n data.users.map((user: any) => new UserModel(user))\n );\n }\n\n static getUsersByServiceId(serviceId: string): Promise<UserModel[]> {\n return ApiClient.get(\n `${this.baseUrl}/GetUsersByServiceId?serviceId=${serviceId}`\n ).then((data) => data.users.map((user: any) => new UserModel(user)));\n }\n\n static getUserAppointmentCount(userId: string, userSchedule: UserScheduleInfo): Promise<number> {\n return ApiClient.post(\n `${this.baseUrl}/getAppointmentCount`, { userId, userSchedule }\n ).then((data) => data.appointmentCount)\n }\n\n static async getUserUpcomingAppointmentsCount(userId: string, establishmentAccountId?: string): Promise<number> {\n let endpoint = `${this.baseUrl}/GetUserUpcomingAppointmentsCount?Id=${userId}`;\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return await ApiClient.get(endpoint).then(\n (data) => (data.userUpcomingAppointmentsCount)\n );\n }\n \n static getAllUserAppointmentCount(userId: string, disabledServicesIds?: string[], establishmentAccountId?: string) : Promise<number> {\n return ApiClient.post(\n `${this.baseUrl}/getAllAppointmentCount`, { userId, disabledServicesIds, establishmentAccountId }\n ).then((data) => data.appointmentCount)\n }\n \n static getIsPhoneDuplicated(iso3Code: string, phoneNumber: string, establishmentAccountId?: string) : Promise<IsUserPhoneDuplicatedModel> {\n let endpoint = `${this.baseUrl}/GetIsPhoneDuplicated?mobileCodeIso3=${iso3Code}&mobileNumber=${phoneNumber}` ;\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint).then(\n (data) => new IsUserPhoneDuplicatedModel(data));\n }\n \n static getIsUserEmailDuplicated(email: string, establishmentAccountId?: string) : Promise<IsUserEmailDuplicatedModel> {\n let endpoint = `${this.baseUrl}/CheckIsUserEmailDuplicated?email=${email}`;\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint).then(\n (data) => new IsUserEmailDuplicatedModel(data));\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n container: {\n display: \"flex\",\n alignItems: \"center\",\n paddingLeft: 10,\n gap: 10,\n },\n separator: {\n paddingRight: 15,\n marginRight: 15,\n borderRightColor: theme.colors.grey2,\n borderRightWidth: 1,\n borderRightStyle: \"solid\",\n },\n dateNavigator: {\n display: \"flex\",\n flexGrow: 1,\n justifyContent: \"left\",\n alignItems: \"center\",\n \"&>svg\": {\n margin: 12\n }\n },\n dateNavigatorText: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n whiteSpace: \"nowrap\"\n },\n dateNavigatorDayText: {\n textTransform: \"lowercase\",\n \"&:first-letter\":{\n textTransform: \"uppercase\"\n }\n },\n dateNavigatorDirectionButton: {\n padding: \"12px 14px\"\n },\n users: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n },\n multiSelect: {\n ...theme.typography.txtBody2,\n height: 32,\n border: \"solid 1px\",\n borderColor: theme.colors.clearMain,\n borderRadius: 5,\n width: 205,\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n select: {\n ...theme.typography.txtBody2,\n height: 32,\n width: 96,\n border: \"solid 1px\",\n borderColor: theme.colors.clearMain,\n borderRadius: 5,\n \"& .MuiPaper-rounded\": {\n borderRadius: 10,\n marginTop: 5\n },\n \"& .MuiPaper-rounded .MuiListItem-root.Mui-selected:not(:hover)\": {\n backgroundColor: \"white\",\n },\n \"& .MuiPaper-rounded .MuiListItem-root\": {\n fontSize: 12,\n },\n \"& .MuiPaper-rounded .MuiListItem-root:hover\": {\n backgroundColor: theme.colors.grey1\n },\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n input: {\n height: \"32px !important\",\n backgroundColor: \"white !important\",\n borderColor: theme.colors.clearMain + \" !important\",\n \"& input\": {\n color: theme.colors.clearMain + \" !important\",\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"8px 0px 8px 15px\",\n color: theme.colors.clearMain\n },\n placeholder: {\n color: \"#676767\",\n opacity: \"0.42\",\n padding: \"8px 0px 8px 15px\",\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n button: {\n height: 32,\n borderRadius: 5,\n padding: \"0 20px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: \"15px\",\n whiteSpace: \"nowrap\"\n },\n newAppointment: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n },\n goToday: {\n marginLeft: 7,\n marginRight: 8,\n },\n establishmentSelectorWrapper: {\n \"& .MuiInput-root\": {\n borderColor: theme.colors.clearMain + \" !important\",\n }\n },\n viewSelect: {\n width: 100\n },\n appointmentsSelect: {\n width: 150\n },\n specialistsSelect: {\n width: 200\n },\n}));\n\nexport default useStyles;\n","import { ClassNameMap } from \"@material-ui/core/styles/withStyles\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\";\n\nexport interface SelectProps {\n styleClass?: any;\n classes?: Partial<ClassNameMap<string>>;\n values: Array<SelectItem | string | number>;\n maxValues?: number | null;\n allItemsPlaceholder: string;\n name?: string;\n items: Array<SelectItem | string | number>;\n width?: number | string;\n disabled?: boolean;\n isValid?: () => boolean | undefined;\n onChange?: (users: Array<SelectItem | string | number>) => void;\n onReset: () => void;\n onBlur?: (event: any) => void;\n onOpen?: (event: any) => void;\n colorArrowIcon?: string;\n sort?: boolean;\n filterPlaceholder: string;\n height?: number | string;\n overflowRenderCap?: number;\n overflowRenderType?: MultiselectOverflowRenderType;\n showSearch?: boolean;\n input?: React.ReactElement<any, any>;\n showIconComponent?: boolean;\n}\n\nexport enum MultiselectOverflowRenderType {\n Plus,\n Dots\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number | string, height?: number | string) =>\n makeStyles((theme) => ({\n select: {\n ...theme.typography.txtBody2,\n backgroundColor: \"theme.colors.grey1\",\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: width || 370,\n },\n paper:{\n overflow: \"hidden\",\n marginTop: 5,\n width: width || 370,\n borderRadius: 10\n },\n searchContainer:{\n marginBottom: 8,\n padding: \"0px 10px\"\n },\n menuList:{\n maxHeight: height || \"auto\",\n overflowY: \"auto\",\n padding: 0,\n \"&::-webkit-scrollbar\": {\n display: \"none\"\n },\n \"-ms-overflow-style\": \"none\",\n \"scrollbar-width\": \"none\"\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"11px 0px 12px 12px\",\n },\n placeholder: {\n color: \"#676767\",\n padding: \"13px 0px 13px 12px\",\n \"&.Mui-disabled\": {\n opacity: \"0.42\",\n },\n },\n focused: {\n color: \"#5C6477\",\n \"&:focus\": {\n backgroundColor: \"inherit\",\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n paddingLeft: 0,\n display: \"flex\",\n alignItems: \"center\",\n \"&.Mui-focusVisible\": {\n backgroundColor: \"inherit\"\n },\n overflowWrap: 'break-word',\n whiteSpace: 'normal'\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n backgroundColor: \"inherit\",\n \"&.Mui-selected\": {\n backgroundColor: \"inherit\"\n },\n },\n checkbox: {\n \"&.Mui-checked\":{\n color: theme.colors.clearMain,\n },\n \"&:not(.Mui-checked)~ div\":{\n fontWeight: \"normal\"\n }\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n borderRadius: 5,\n },\n group: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n \"&.Mui-disabled\": {\n opacity: 1,\n },\n },\n }));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.txtBody2,\n borderRadius: \"100px\",\n background: \"#F6F6F6\",\n border: `1px solid ${theme.colors.grey2}`,\n height: 32,\n paddingLeft: 12,\n \"&:focus\": {\n border: \"solid 1px #6462F3\",\n },\n },\n noBorder: {\n border: \"none!important\",\n \"&:focus\": {\n border: \"none!important\",\n },\n paddingLeft: \"16px!important\",\n },\n inputSearchClass: {\n height: 32,\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n },\n searchIcon: {\n padding: 6,\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\n\nimport TextField from \"@material-ui/core/TextField\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport InputAdornment from \"@material-ui/core/InputAdornment\";\n\nimport { InputSearchProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { CrossIcon, SearchIcon } from \"../../../assets/icons\";\n\nconst InputSearch = (props: InputSearchProps) => {\n \n const classes = useStyles();\n const { placeholder, noBorder, onSearch, onReset, inputSearchClass, rootClass, value, ...params } = props;\n\n const handleKeyPress = (event: any) => {\n if (event.key === \"Enter\" && onSearch) {\n onSearch();\n }\n };\n\n const getEndAdornmentComponent = () => {\n if (onSearch && onReset && value && value.length > 0) {\n return <IconButton onClick={() => onReset()}>\n <CrossIcon\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </IconButton>\n }\n\n return (\n <IconButton \n className={classes.searchIcon}\n onClick={() => {\n if (onSearch)\n onSearch()\n }}\n >\n <SearchIcon />\n </IconButton>\n )\n }\n\n return (\n <TextField\n {...params}\n onKeyPress={handleKeyPress}\n className={inputSearchClass ?? classes.inputSearchClass}\n placeholder={placeholder}\n value={value ?? undefined}\n InputProps={{\n ...params.InputProps,\n disableUnderline: true,\n className: `${noBorder ? classes.noBorder : \"\" } ${rootClass ? rootClass : classes.root}`,\n classes: { focused: !noBorder ? classes.inputFocused : undefined },\n type: \"text\",\n endAdornment: (\n <InputAdornment position=\"end\">\n {getEndAdornmentComponent()}\n </InputAdornment>\n ),\n }}\n />\n );\n};\n\nexport default InputSearch;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\"\n },\n checkbox: {\n color: theme.colors.clearMain,\n '&.Mui-checked': {\n color: theme.colors.clearMain,\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n disabledCheckbox: {\n opacity: 0.5\n },\n text: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 700\n },\n textChecked: {\n color: \"#6462F3!important\"\n }\n })\n);\n\nexport default useStyles;","import React, { useEffect } from \"react\";\n\nimport { CheckboxWithLabelProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Checkbox } from \"@material-ui/core\";\n\n\nexport default function CheckboxWithLabel(props: CheckboxWithLabelProps) {\n \n const { checked, setChecked, labelClass, disableRippleEffect, label, disabled, checkboxClass } = props;\n const classes = useStyles();\n \n function handleChecking() {\n setChecked(!checked);\n }\n \n return (\n <div className={`${classes.root} ${disabled ? classes.disabledCheckbox : \"\"}`}>\n <Checkbox\n disableRipple={disableRippleEffect ?? false}\n checked={checked}\n disabled={disabled}\n onChange={handleChecking}\n className={checkboxClass ?? classes.checkbox}\n size={\"small\"}\n />\n {typeof label === \"string\"\n ? <div className={`${labelClass ?? classes.text} ${checked ? classes.textChecked : \"\"}`}>{label}</div>\n : label ?? null\n }\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport Box from \"@material-ui/core/Box\";\nimport Input from \"@material-ui/core/Input\";\nimport MuiSelect from \"@material-ui/core/Select\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\n\nimport ArrowDropDownIcon from \"./../../../assets/icons/ArrowDropDownIcon\";\nimport useStyles from \"./css\";\nimport { MultiselectOverflowRenderType, SelectProps } from \"./props\";\nimport InputSearch from \"./../InputSearch\";\nimport CheckboxWithLabel from \"../CheckboxWithLabel\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\";\n\n\nexport default function MultiSelect(props: SelectProps) {\n const {\n values,\n maxValues,\n allItemsPlaceholder,\n filterPlaceholder,\n name,\n items,\n width,\n onChange,\n onReset,\n onBlur,\n onOpen,\n disabled,\n styleClass,\n classes,\n isValid,\n colorArrowIcon,\n sort,\n height,\n overflowRenderCap,\n overflowRenderType,\n showSearch,\n input = <Input />,\n showIconComponent = true\n } = props;\n \n const overflowCap = overflowRenderCap ?? 25;\n \n const useClasses = useStyles(width, height)();\n const [filter, setFilter] = useState<string>(\"\");\n const restrictValuesCount = !!maxValues && items.length > maxValues && values.length === 0;\n const trimValuesSelection = !!maxValues && values.length > maxValues;\n const restrictValuesSelection = !!maxValues && values.length >= maxValues;\n \n const displayItems = (items: Array<SelectItem | string | number>): Array<SelectItem | string | number> => {\n if (sort) {\n const compare = (a: SelectItem | string | number, b: SelectItem | string | number) => {\n if (typeof a === \"object\" && typeof b === \"object\") {\n if (a.value < b.value) {\n return -1;\n }\n if (a.value > b.value) {\n return 1;\n }\n return 0;\n } else {\n return a < b ? -1 : a > b ? 1 : 0;\n }\n }\n return [...items].sort(compare);\n } else {\n return items;\n }\n }\n \n if (onChange && maxValues && (restrictValuesCount || trimValuesSelection)){\n const keys = displayItems(items).map((item: SelectItem | string | number, index) => typeof item === \"object\" ? item.key : item);\n onChange(keys.slice(0, maxValues))\n }\n \n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n\n if (isValid() === undefined) {\n return false;\n }\n\n return !isValid();\n };\n\n const handleOnChange = (value: string | number) => {\n if (value === \"\"){\n if (onChange && !!maxValues && items.length > maxValues){\n const keys = displayItems(items).map((item: SelectItem | string | number, index) => typeof item === \"object\" ? item.key : item);\n onChange(keys.slice(0, maxValues))\n } else {\n onReset();\n }\n } else {\n if (!values.includes(value)) {\n const v = [...values, value]\n onChange && onChange(v);\n } else {\n const v = values.filter(e => e !== value);\n onChange && onChange(v);\n }\n }\n };\n\n const handleOnFilter = (event: React.ChangeEvent<{ value: string }>) => {\n setFilter(event.target.value);\n };\n\n const handleOnClose = (event: React.ChangeEvent<{ }>) => {\n setFilter(\"\");\n };\n\n const ArrowIcon = (props: any) => (\n <ArrowDropDownIcon\n {...props}\n style={{ top: \"inherit\", right: 12, color: colorArrowIcon ?? \"#6462F3\" }}\n />\n );\n\n const isHidden = (item: SelectItem | string | number): boolean => {\n if (filter) {\n const flt = filter.toUpperCase();\n if (typeof item === \"object\") {\n return !(item as SelectItem).value.toUpperCase().includes(flt);\n } else if (typeof item === \"string\") {\n return !item.toUpperCase().includes(flt);\n } else {\n return String(item) !== flt;\n }\n }\n return false;\n }\n \n function renderValue(selected: unknown) {\n if ((selected as Array<any>).length === 0)\n return allItemsPlaceholder;\n \n let names = (selected as Array<string | number>).map((item: string | number) =>\n ((items as Array<SelectItem>).find(v => v.key === item) || { value: item }).value);\n if (sort) {\n names = names.sort();\n }\n \n if (overflowRenderType === MultiselectOverflowRenderType.Dots) {\n const namesString = names.join(', ');\n if (namesString.length > overflowCap) {\n return namesString.substring(0, overflowCap) + \" + ...\"\n } else {\n return namesString;\n }\n }\n \n if (names.length > 2) {\n names = names.map(n => n.split(' ')[0]);\n return names.slice(0, 2).join(', ') + `, +${names.length - 2}`\n } else {\n return names.join(', ');\n }\n }\n\n return (\n <MuiSelect\n multiple\n renderValue={renderValue}\n disableUnderline\n classes={\n classes || {\n root: `${useClasses.focused} ${values && values.length ? useClasses.selected : useClasses.placeholder\n } ${isError() ? useClasses.inputError : \"\"}`,\n }\n }\n name={name}\n className={styleClass ?? useClasses.select}\n input={input}\n MenuProps={{\n getContentAnchorEl: null,\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\",\n },\n PaperProps: {\n className: useClasses.paper,\n }\n }}\n displayEmpty\n disabled={disabled ?? false}\n onBlur={(e) => { if (onBlur) onBlur(e) }}\n onClose={handleOnClose}\n value={values || []}\n IconComponent={showIconComponent ? ArrowIcon : () => null}\n onOpen={(e) => { if (onOpen) onOpen(e) }}\n >\n {showSearch &&\n <Box key={`option-filter`} className={useClasses.searchContainer} onKeyDown={(e) => {e.stopPropagation();}}>\n <InputSearch placeholder={filterPlaceholder} onChange={handleOnFilter} value={filter} style={{width: '100%'}} />\n </Box>\n }\n <ul className={useClasses.menuList}>\n <MenuItem\n key={`option-all-items`}\n classes={{ root: useClasses.itemRoot }}\n onClick={() => handleOnChange(\"\")}\n disabled={restrictValuesCount}\n >\n <CheckboxWithLabel\n checked={!values.length}\n setChecked={() => { }}\n label={allItemsPlaceholder}\n checkboxClass={useClasses.checkbox}\n />\n </MenuItem>\n {displayItems(items).map((item: SelectItem | string | number, index) =>\n typeof item === \"object\" ? (\n <MenuItem\n classes={{\n root: useClasses.itemRoot,\n selected: useClasses.itemSelected,\n }}\n key={`option-${item.key}-${index}`}\n onClick={() => handleOnChange(item.key)}\n hidden={isHidden(item)}\n disabled={restrictValuesSelection && values.indexOf(item.key) < 0}\n >\n <CheckboxWithLabel\n checked={values.indexOf(item.key) > -1}\n setChecked={() => { }}\n label={item.value}\n checkboxClass={useClasses.checkbox}\n />\n </MenuItem>\n ) : (\n <MenuItem\n classes={{\n root: useClasses.itemRoot,\n selected: useClasses.itemSelected,\n }}\n key={item || index}\n onClick={() => handleOnChange(item)}\n hidden={isHidden(item)}\n >\n <CheckboxWithLabel\n checked={values.indexOf(item) > -1}\n setChecked={() => { }}\n label={item}\n checkboxClass={useClasses.checkbox}\n />\n </MenuItem>\n )\n )}\n </ul>\n </MuiSelect>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = () =>\nmakeStyles((theme) => ({\n root:{},\n dateIcon: {\n padding: 0\n },\n datePicker: {\n \"& .MuiPopover-paper\": {\n width: 202,\n height: 233,\n },\n \"& .MuiPickersDay-hidden\": {\n opacity: 0.25\n },\n \"& .MuiPaper-rounded\": {\n borderRadius: 10\n },\n \"& .MuiPickersCalendarHeader-switchHeader::after\": {\n content: '\"\"',\n display: 'block',\n width: 176,\n borderBottomWidth: 1,\n borderBottom: 'solid',\n borderBottomColor: '#EFEFEF',\n position: 'absolute',\n marginLeft : 10,\n bottom: 0\n },\n \"& .MuiPickersCalendarHeader-switchHeader\": {\n width: 202,\n height: 40,\n position: 'relative',\n },\n \"& .MuiPickersCalendar - transitionContainer\": {\n width: 177,\n height: 137,\n },\n \"& .MuiPickersCalendarHeader-daysHeader\": {\n width: 177,\n margin: 'auto',\n marginBottom: 7\n },\n \"& .MuiPickersDay-day\": {\n width: 22,\n height: 22,\n margin: 2\n },\n \"& .MuiPickersCalendar-transitionContainer\": {\n width: 177,\n margin: 'auto'\n },\n \"& .MuiPickersStaticWrapper-staticWrapperRoot\": {\n width: 202,\n height: 233,\n minWidth: 202\n },\n \"& .MuiPickersBasePicker-pickerView\": {\n minWidth: 202,\n minHeight: 233\n },\n \"& .MuiPickersCalendarHeader-iconButton\": {\n backgroundColor: 'initial'\n }\n }\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { DatePicker, KeyboardDatePicker, MuiPickersUtilsProvider } from \"@material-ui/pickers\";\nimport DateFnsUtils from \"@date-io/date-fns\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\n\nimport { DateIconProps } from \"./props\";\nimport {CalendarIcon2} from \"../../../assets/icons\";\nimport useStyles from \"./css\";\nimport {useAppSelector} from \"../../../redux/hooks\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport Popover from \"@material-ui/core/Popover\";\n\n\nexport default function DateIcon(props: DateIconProps) {\n\n const {\n value,\n disabled,\n minDate,\n maxDate,\n onChange,\n } = props;\n\n const classes = useStyles()();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const [anchorEl, setAnchorEl] = useState<HTMLButtonElement | null>(null);\n const open = Boolean(anchorEl);\n\n const getId = (): string => {\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(\n /[xy]/g,\n function (c) {\n const r = (Math.random() * 16) | 0,\n v = c === \"x\" ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n }\n );\n };\n const [inputId] = useState<string>(getId());\n const id = open ? inputId : undefined;\n\n const handleOpen = (event: React.MouseEvent<HTMLButtonElement>) => {\n setAnchorEl(event.currentTarget);\n };\n const handleClose = () => {\n setAnchorEl(null);\n };\n const handleOnChange = (event: any) => {\n handleClose();\n if (onChange) {\n onChange(event);\n }\n };\n\n const getLocale = (): any => {\n switch (localeApp) {\n case \"es\":\n return esLocale;\n\n default:\n return enLocale;\n }\n };\n\n return (\n <div className={classes.root}>\n <IconButton\n aria-describedby={id}\n aria-haspopup={true}\n className={classes.dateIcon}\n onClick={handleOpen}>\n <CalendarIcon2 />\n </IconButton>\n <Popover\n id={id}\n open={open}\n anchorEl={anchorEl}\n onClose={handleClose}\n anchorOrigin={{\n vertical: 'bottom',\n horizontal: 'left',\n }}\n transformOrigin={{\n vertical: 'top',\n horizontal: 'left',\n }}\n className={classes.datePicker}\n >\n <MuiPickersUtilsProvider\n utils={DateFnsUtils}\n locale={getLocale()}\n >\n <DatePicker\n autoOk\n disableToolbar\n variant=\"static\"\n openTo=\"date\"\n onChange={handleOnChange}\n disabled={disabled ?? false}\n value={value || null}\n minDate={minDate}\n maxDate={maxDate}\n />\n </MuiPickersUtilsProvider>\n </Popover>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n multiSelect: {\n width: 205,\n height: 32,\n \n border: \"solid\",\n borderWidth: 1,\n borderColor: \"rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \n ...theme.typography.txtBody2,\n \n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n selected: {\n paddingTop: 8,\n paddingBottom: 8,\n paddingLeft: 15,\n \n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Tooltip } from \"@material-ui/core\";\n\nimport { EstablishmentSelectorProps } from \"./props\";\nimport MultiSelect from \"../../common/MultiSelect\";\nimport useStyles from './css';\nimport { MultiselectOverflowRenderType } from \"../../common/MultiSelect\";\n\n\nexport default function EstablishmentSelector(props: EstablishmentSelectorProps) {\n \n const { items, establishments, setEstablishments } = props;\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n const [isTooltipOpen, setTooltipOpen] = useState<boolean>(false);\n \n useEffect(() => {\n //If establishment has been removed from enterprise, and it was selected before, remove it.\n if (items && establishments) {\n const itemIds = items.map(x => x.key);\n const removedEstablishments = establishments.filter(x => !itemIds.includes(x))\n if (removedEstablishments.length > 0) {\n const newEstablishments = [...establishments.filter(x => !removedEstablishments.includes(x))]\n setEstablishments(newEstablishments)\n }\n }\n }, [establishments])\n \n function handleSelectEstablishments(newEstablishments: any[]) {\n setEstablishments(newEstablishments)\n }\n \n function resetEstablishments() {\n setEstablishments([]);\n }\n \n const establishmentNames = items && establishments && establishments.length > 1 \n ? items\n .filter(i => establishments.includes(i.key))\n .map(i => i.value)\n .join(', ')\n : \"\"\n \n function handleOpenTooltip() {\n setTooltipOpen(true)\n }\n \n function handleCloseTooltip() {\n setTooltipOpen(false)\n }\n \n return (\n <Tooltip\n title={establishmentNames}\n open={isTooltipOpen}\n onOpen={handleOpenTooltip}\n onClose={handleCloseTooltip}\n disableHoverListener\n disableTouchListener\n disableFocusListener\n >\n <div\n onMouseEnter={handleOpenTooltip}\n onMouseLeave={handleCloseTooltip}\n >\n <MultiSelect\n allItemsPlaceholder={t(\"All\")}\n filterPlaceholder={t(\"Search for establishments\")}\n items={items}\n sort={true}\n values={establishments}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.multiSelect}\n width={205}\n height={372}\n onChange={handleSelectEstablishments}\n onReset={resetEstablishments}\n onOpen={handleCloseTooltip}\n overflowRenderType={MultiselectOverflowRenderType.Dots}\n showSearch={true}\n />\n </div>\n </Tooltip>\n );\n}","import React from \"react\";\n\nimport InputBase from \"@material-ui/core/InputBase\";\n\nimport useStyles from \"./css\";\nimport { InputProps } from \"./props\";\n\nconst Input = (props: InputProps) => {\n \n const {\n id,\n value,\n name,\n placeholder,\n isValid,\n width,\n inputClass,\n containerClass,\n onChange,\n onKeyPress,\n disabled,\n readOnly,\n onClick,\n onBlur,\n onKeyDown,\n onFocus,\n maxLength,\n autoFocus,\n showCounter,\n inputType,\n min,\n max,\n step\n } = props;\n\n const classes = useStyles(width, showCounter)();\n\n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n\n if (isValid() === undefined) {\n return false;\n }\n\n return !isValid();\n };\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n const handleOnKeyPress = (event: any) => {\n if (onKeyPress) {\n onKeyPress(event);\n }\n };\n \n function handleFocus(event: any) {\n if (onFocus)\n onFocus(event)\n }\n \n function handleOnKeyDown(event: any) {\n if (onKeyDown) \n onKeyDown(event)\n }\n \n const handleOnClick = (event: any) => {\n if (onClick) {\n onClick(event);\n }\n };\n \n const handleOnBlur = (event: any) => {\n if (onBlur) {\n onBlur(event);\n }\n };\n \n return (\n <span className={`${containerClass} ${classes.container}`}>\n <InputBase\n id={id}\n className={`${inputClass} ${classes.input} ${\n isError() ? classes.inputError : \"\"\n }`}\n classes={{\n focused: classes.inputFocused,\n disabled: classes.inputDisabled,\n input: classes.inputText,\n }}\n value={value}\n name={name}\n placeholder={placeholder}\n onChange={handleOnChange}\n onKeyPress={handleOnKeyPress}\n onKeyDown={handleOnKeyDown}\n onFocus={handleFocus}\n disabled={disabled}\n readOnly={readOnly}\n onClick={handleOnClick}\n onBlur={handleOnBlur}\n autoFocus={autoFocus}\n inputProps={{\n maxLength: maxLength,\n min: min,\n max: max,\n step: step\n }}\n type={inputType ?? \"text\"}\n />\n {showCounter && <div className={classes.counter}>{`${value?.length}/${maxLength}`}</div>}\n </span>\n );\n};\n\nexport default Input;","import * as React from \"react\";\nimport { useEffect, useState } from \"react\";\nimport clsx from 'clsx';\n\nimport { useHistory } from \"react-router-dom\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { schedulerActions } from \"../../../redux/scheduler-slice\";\n\nimport Button from \"@material-ui/core/Button\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport { MaterialUiPickersDate } from \"@material-ui/pickers/typings/date\";\n\nimport Select, { SelectItem } from \"../../common/Select\";\n\nimport { Url } from \"../../../constants/url\";\nimport useStyles from \"./css\";\nimport { AppointmentListToolbarProps } from \"./props\";\nimport { MinusArrowIcon } from \"../../../assets/icons\";\nimport Typography from \"@material-ui/core/Typography\";\nimport MultiSelect from \"../../common/MultiSelect\";\nimport DateIcon from \"../../common/DateIcon/date-icon\";\nimport { LocalStorageKey } from \"../../../constants/local-storage-key\";\nimport EstablishmentSelector from \"../../navbar/EstablishmentSelector\";\nimport useLocalStorageState from \"../../../hooks/useLocalStorageState\";\nimport { enterpriseActions } from \"../../../redux/enterprise-slice\";\nimport Input from \"../../common/Input\";\nimport { AppointmentStatus } from \"../../../models/enums/appointment-status\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\n\nexport default function AppointmentListToolbar(props: AppointmentListToolbarProps) {\n \n const { allUsers, selectedUsers, selectedStatuses, saveSelectedUsers, saveSelectedStatuses } = props;\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const history = useHistory();\n \n const dispatch = useAppDispatch();\n \n const userInfo = useAppSelector(state => state.userInfo);\n const currentUserAuthId = userInfo.userId;\n const hasAccessToScheduleAllSpecialists = userInfo.hasAccessToScheduleAllSpecialists;\n \n const accountSettings = useAppSelector((state) => state.accountSettings);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const currentDate = useAppSelector((state) => state.scheduler.currentDate);\n const currentViewName = useAppSelector((state) => state.scheduler.currentViewName);\n const { setCurrentDate, setCurrentViewName } = schedulerActions;\n \n const establishmentsStorageKey = LocalStorageKey.Establishments + userInfo.userId;\n const { setSelectedEstablishments } = enterpriseActions;\n // @ts-ignore\n const [accountEstablishments, setAccountEstablishments] = useLocalStorageState({ itemKey: establishmentsStorageKey, dispatchFunction: setSelectedEstablishments });\n \n const views: SelectItem[] = [\n { key: \"Week\", value: t(\"Week\") } as SelectItem,\n { key: \"Day\", value: t(\"Day\") } as SelectItem\n ];\n \n const statuses: SelectItem[] = [\n { key: AppointmentStatus.NotConfirmed, value: t(\"Not Confirmed\") } as SelectItem,\n { key: AppointmentStatus.Confirmed, value: t(\"Confirmed\") } as SelectItem,\n { key: AppointmentStatus.NotArrived, value: t(\"Not Arrived\") } as SelectItem,\n { key: AppointmentStatus.Arrived, value: t(\"Arrived\") } as SelectItem,\n ];\n \n useEffect(() => {\n if (currentUserAuthId) {\n const viewName = localStorage.getItem(LocalStorageKey.SchedulerViewName + currentUserAuthId);\n if (viewName) {\n dispatch(setCurrentViewName(viewName));\n }\n }\n }, []);\n \n function changeCurrentDate(date: Date) {\n dispatch(setCurrentDate(date));\n }\n \n function handleSelectUsers(users: any) {\n saveSelectedUsers(users);\n }\n \n function handleResetUsers() {\n saveSelectedUsers([]);\n }\n \n function handleSelectStatuses(users: any) {\n saveSelectedStatuses(users);\n }\n \n function handleResetStatuses() {\n saveSelectedStatuses([]);\n }\n \n function handleSelectView(event: any) {\n changeCurrentDate(new Date());\n dispatch(setCurrentViewName(event.target.value));\n if (currentUserAuthId) {\n localStorage.setItem(LocalStorageKey.SchedulerViewName + currentUserAuthId, event.target.value);\n }\n }\n \n const formattedDate = (): string => {\n if (currentViewName === \"Week\") {\n const startDate = new Date(currentDate);\n const parsedCurrentDate = new Date(currentDate);\n startDate.setDate(\n parsedCurrentDate.getDate() -\n ((parsedCurrentDate.getDay() !== 0 ? parsedCurrentDate.getDay() : 7) - 1)\n );\n const endDate = new Date(startDate);\n endDate.setDate(startDate.getDate() + 6);\n return `${startDate.toLocaleDateString(\n localeApp,\n {\n month: \"short\",\n day: \"numeric\",\n }\n )} - ${endDate.toLocaleDateString(localeApp, {\n month: \"short\",\n day: \"numeric\",\n })}`;\n } else { // Day\n return currentDate.toLocaleDateString(localeApp,\n {\n weekday: \"long\",\n month: \"long\",\n day: \"numeric\",\n }).replace(',', '');\n }\n };\n \n function handleNavigate(direction: string) {\n let date = new Date(currentDate);\n const step = currentViewName === \"Week\" ? 7 : 1;\n if (direction === \"forward\") {\n date.setDate(date.getDate() + step);\n changeCurrentDate(date);\n } else if (direction === \"back\") {\n date.setDate(date.getDate() - step);\n changeCurrentDate(date);\n }\n }\n \n function handleDateChange(date: MaterialUiPickersDate) {\n changeCurrentDate(date as Date)\n }\n \n function handleGoToday() {\n changeCurrentDate(new Date());\n }\n \n return (\n <div className={clsx(classes.container, {[classes.separator]: !accountSettings.isEnterprise})} >\n <div className={classes.dateNavigator}>\n <div className={classes.goToday}>\n <ButtonWithSpinner\n width={70}\n borderRadius={ButtonPropsBorderRadius.Small}\n backgroundOrBorderColor={ButtonPropsColor.Gray}\n textColor={ButtonPropsColor.Gray4}\n fill={ButtonPropsFill.Outlined}\n innerText={t(\"Today\")}\n onClick={handleGoToday}\n />\n </div>\n <DateIcon value={currentDate} onChange={handleDateChange} />\n <Typography\n className={`${classes.dateNavigatorText} ${currentViewName === \"Day\" ? classes.dateNavigatorDayText : \"\"}`}>\n {formattedDate()}\n </Typography>\n <IconButton\n className={classes.dateNavigatorDirectionButton}\n onClick={() => {\n handleNavigate(\"back\");\n }}\n >\n <MinusArrowIcon/>\n </IconButton>\n <IconButton\n className={classes.dateNavigatorDirectionButton}\n onClick={() => {\n handleNavigate(\"forward\");\n }}\n >\n <MinusArrowIcon style={{ transform: \"rotate(180deg)\" }}/>\n </IconButton>\n </div>\n <Select\n items={views}\n value={currentViewName}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={`${classes.select} ${classes.viewSelect}`}\n onChange={handleSelectView}\n />\n \n {\n accountSettings.isEnterprise ?\n <>\n <div className={classes.establishmentSelectorWrapper}>\n <EstablishmentSelector\n establishments={accountEstablishments ?? []}\n setEstablishments={setAccountEstablishments}\n items={accountSettings?.establishments ?? []}\n />\n </div>\n </>\n : null\n }\n <MultiSelect\n allItemsPlaceholder={t(\"All Appts\")}\n filterPlaceholder={\"\"}\n items={statuses}\n values={selectedStatuses}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={`${classes.multiSelect} ${classes.appointmentsSelect}`}\n width={205}\n height={372}\n onChange={handleSelectStatuses}\n onReset={handleResetStatuses}\n />\n {hasAccessToScheduleAllSpecialists &&\n <MultiSelect\n allItemsPlaceholder={t(\"All specialists\")}\n filterPlaceholder={t(\"Search a specialist\")}\n items={allUsers}\n sort={true}\n showSearch={true}\n values={selectedUsers}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={`${classes.multiSelect} ${classes.specialistsSelect}`}\n width={205}\n height={372}\n onChange={handleSelectUsers}\n onReset={handleResetUsers}\n />\n }\n {!hasAccessToScheduleAllSpecialists &&\n <Input\n value={userInfo.fullName}\n width={205}\n inputClass={classes.input}\n disabled={true}\n readOnly={true}\n />\n }\n \n {accountSettings?.isEnterprise ? <></> :\n <ButtonWithSpinner\n width={64}\n borderRadius={ButtonPropsBorderRadius.Small}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Create appt\")}\n onClick={() => {\n history.push(`${Url.Appointments.Main}/new`);\n }}\n />\n }\n </div>\n );\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 513,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n draggableModalHeader: {\n margin: \"-40px -40px 0\",\n padding: \"40px 40px 0\",\n cursor: \"grab\"\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalSubTitleText: {\n fontSize: 12,\n color: \"#5C6477\",\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n cancelModalPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n cancelModalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n cancelModalTitleSpace: {\n margin: \"24px 0px 24px 0px\",\n },\n iconTrash: {\n display: \"inline\",\n cursor: \"pointer\",\n width: 30,\n height: 30,\n color: \"#919CA5\",\n borderRadius: 25\n },\n \n modalConfirm: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n confirmModalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 610,\n height: 360,\n },\n modalConfirmTitleText: {\n ...theme.typography.header4,\n color: theme.colors.grey7,\n fontWeight: 700\n },\n modalConfirmSubTitleText: {\n ...theme.typography.body2,\n color: theme.colors.grey7\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n alignItems: \"center\",\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"50px\",\n height: \"50px\",\n margin: \"auto\"\n },\n modalActionsConfirm: {\n display: \"flex\",\n justifyContent: \"center\",\n }\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n marginBottom: \"0.5rem\",\n },\n disabled: {\n opacity: \"0.42\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\n\nimport InputLabel from \"@material-ui/core/InputLabel\";\n\nimport Select from \"./../Select\";\n\nimport useStyles from \"./css\";\nimport { SelectWithLabelProps } from \"./props\";\n\nconst SelectWithLabel = (props: SelectWithLabelProps) => {\n const {\n label,\n value,\n placeholder,\n name,\n items,\n width,\n onChange,\n onBlur,\n styleClass,\n itemRootClass,\n isValid,\n disabled,\n disableScrollLock,\n colorArrowIcon,\n showTooltip,\n rootStyle\n } = props;\n const classes = useStyles();\n\n const LabelComponent = label;\n\n const handleOnChange = (event: React.ChangeEvent<{ value: unknown }>) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n return (\n <div className={classes.root} style={rootStyle}>\n <InputLabel\n className={`${classes.label} ${disabled ? classes.disabled : \"\"}`}\n >\n {typeof label === \"string\" ? label : <LabelComponent />}\n </InputLabel>\n <Select\n styleClass={styleClass}\n itemRootClass={itemRootClass}\n name={name}\n placeholder={placeholder}\n width={width}\n items={items}\n value={value}\n isValid={isValid}\n onChange={handleOnChange}\n onBlur={(e) => { if (onBlur) onBlur(e)}}\n disabled={disabled}\n disableScrollLock={disableScrollLock}\n colorArrowIcon={colorArrowIcon}\n showTooltip={showTooltip}\n />\n </div>\n );\n};\n\nexport default SelectWithLabel;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n width: 32,\n height: 21,\n padding: 0,\n // margin: theme.spacing(1),\n },\n switchBase: {\n padding: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&$checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: theme.palette.common.white,\n \"& + $track\": {\n backgroundColor: \"#6462F3\",\n opacity: 1,\n border: \"none\",\n },\n },\n \"&$focusVisible $thumb\": {\n color: \"#6462F3\",\n border: \"6px solid #fff\",\n },\n },\n thumb: {\n width: 15,\n height: 15,\n boxShadow: \"none\",\n },\n track: {\n borderRadius: 23 / 2,\n border: \"3px solid #323947\",\n backgroundColor: theme.palette.grey[50],\n opacity: 1,\n //transition: theme.transitions.create([\"background-color\", \"border\"]),\n },\n checked: {},\n focusVisible: {},\n}));\n\nexport default useStyles;\n","import React from \"react\";\n\nimport MuiSwitch from \"@material-ui/core/Switch\";\n\nimport useStyles from \"./css\";\nimport { SwitchProps } from \"./props\";\n\nconst Switch = (props: SwitchProps) => {\n const { value, disabled, onChange, baseClass } = props;\n const classes = useStyles();\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n return (\n <MuiSwitch\n focusVisibleClassName={classes.focusVisible}\n disableRipple\n classes={{\n root: classes.root,\n switchBase: baseClass || classes.switchBase,\n thumb: classes.thumb,\n track: classes.track,\n checked: classes.checked,\n }}\n onChange={handleOnChange}\n checked={value}\n disabled={disabled}\n />\n );\n};\n\nexport default Switch;\n","export default class BlockedReason {\n id?: string | null;\n name: string;\n isPredetermined?: boolean;\n isEdit?: boolean;\n\n constructor(x?: BlockedReason) {\n if (typeof x === \"object\" && x != null) {\n this.id = x.id;\n this.name = x.name || \"\";\n this.isPredetermined = x.isPredetermined;\n this.isEdit = false;\n }\n else {\n this.id = null;\n this.name = \"\";\n this.isPredetermined = false;\n this.isEdit = false;\n }\n }\n}\n\n","import { ApiClient } from \"./api-client\";\nimport BlockedReason from \"../models/blocked-reason\";\nimport { Response } from \"../models/response\";\n\n\nexport default class BlockedReasonService {\n\n private static baseUrl: string = \"/blockedschedule\";\n\n static getBlockedReason(): Promise<Response> {\n let urlEndpoint = `${this.baseUrl}/GetBlockedReason`;\n return ApiClient.get(urlEndpoint)\n .then((data) => {\n return new Response(data.blockedReasons, 0);\n });\n }\n\n static createBlockedReason(blockedreason: BlockedReason): Promise<BlockedReason> {\n return ApiClient.post(`${this.baseUrl}/createBlockedReason`, blockedreason)\n .then(data => {\n return new BlockedReason(data.blockedreason);\n });\n }\n\n static updateBlockedReason(blockedreason: BlockedReason): Promise<BlockedReason> {\n return ApiClient.put(`${this.baseUrl}/updateBlockedReason`, blockedreason)\n .then(data => {\n return new BlockedReason(data.blockedreason);\n });\n }\n\n static deleteBlockedReason(w: BlockedReason): Promise<any> {\n return ApiClient.remove(`${this.baseUrl}/deleteBlockedReason?id=${w.id}`)\n .then(data => {\n return {\n entity: new BlockedReason(data.blockedreason),\n forbiddenDelete: data.forbiddenDelete\n };\n });\n }\n\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n \n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n\n component: {\n zIndex: 2,\n position: \"relative\",\n left: 0\n },\n labelCategory: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n required: {\n color: \"#6462F3\",\n fontFamily: \"Roboto, sans-serif\"\n },\n optional: {\n fontWeight: \"normal\",\n },\n divDropdown: {\n cursor: \"pointer\",\n width: 350,\n display: \"block\",\n marginTop: -7,\n\n\n },\n inputSelectBtn: {\n cursor: \"pointer\",\n width: 300,\n pointerEvents: \"none\"\n\n },\n iconDropdown: {\n cursor: \"pointer\",\n position: \"relative\",\n top: -24,\n textAlign: \"right\",\n right: 2\n },\n divModalSelect: {\n backgroundColor: \"#FFFFFF\",\n padding: \"0px 0 20px 0\", \n border: \"1px solid #DBDCDD\",\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n width: 350,\n textAlign: \"center\",\n position: \"fixed\"\n },\n listCategoryScroll: {\n maxHeight: 200,\n overflowY: \"scroll\"\n },\n listCategory: {\n padding: \"5px 0\",\n \"&:first-child\": {\n paddingTop: 10,\n },\n borderBottom: \"1px solid #F6F6F6\",\n marginBottom: 0,\n //maxHeight: 200,\n //overflow: \"hidden\",\n //overflowY: \"auto\"\n },\n name: {\n textAlign: \"left\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\",\n width: \"75%\",\n overflow: \"hidden\",\n display: \"inline-block\",\n paddingTop: \"5px\",\n height: 40\n },\n button: {\n width: 300,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#786EFF\",\n border: \"1px solid #786EFF\",\n\n },\n btnNewBlockedReason: {\n },\n elementList: {\n height: 32,\n padding: \"0px 30px 10px 30px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n display: \"flex\",\n color: theme.colors.grey5,\n\n },\n divInputEdit: {\n margin: \"auto\",\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n input: {\n marginLeft: \"auto\",\n \"& input\": {\n width: 250,\n }\n },\n iconPlus: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n\n iconSave: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n divItemEdit: {\n height: 32,\n display: \"block\"\n },\n btnInputNew: {\n height: 32,\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n classRow: {\n cursor: \"pointer\",\n \"& button\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n \"& button\": {\n visibility: \"visible\"\n }\n }\n },\n btnRow: {\n width: 32,\n height: 32,\n borderRadius: 51,\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\",\n border: \"none\",\n padding: 0,\n margin: 0,\n backgroundColor: \"transparent\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n deleteCategory: {\n color: theme.colors.grey4,\n width: 13,\n height: 17,\n padding: 0,\n },\n editCategory: {\n color: theme.colors.grey4,\n width: 13,\n height: 17,\n padding: 0,\n },\n divIconsRow: {\n right: 0,\n textAlign: \"center\",\n marginLeft: \"auto\",\n float: \"right\",\n paddingTop: 0\n\n },\n divNew: {\n marginTop: 15,\n },\n divTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n display: \"flex\",\n alignItems: \"center\",\n color: theme.colors.grey4,\n marginLeft: 25,\n marginTop: 10\n }\n\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Button from \"@material-ui/core/Button\";\n\nimport Input from \"./../../common/Input\";\nimport { ArrowLineDown, PlusIcon, SaveIcon, EditIcon, TrashIcon } from \"./../../../assets/icons\";\n\nimport BlockedReason from './../../../models/blocked-reason';\nimport BlockedReasonService from \"./../../../api/blocked-reason-service\"\n\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\n\nimport { BlockedReasonSelectProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nconst BlockedReasonSelect = (props: BlockedReasonSelectProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { widthSelect, widthList, isOptional, onSelect, placeholderInput, item } = props;\n const classes = useStyles();\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const [list, setList] = useState<BlockedReason[]>([]);\n const [showNew, setShowNew] = useState<boolean>(false);\n const [reasonSelected, setReasonSelected] = useState<BlockedReason>();\n const [reasonNew, setReasonNew] = useState<BlockedReason>();\n\n const [openModal, setOpenModal] = useState<boolean>(false);\n\n const handleEditItem = (i: BlockedReason) => {\n setShowNew(false);\n const newList = list.map((item) => {\n if (item.id === i.id) {\n const updatedItem = {\n ...item,\n isEdit: !item.isEdit,\n };\n setReasonNew(item);\n return updatedItem;\n }\n else {\n const updatedItem = {\n ...item,\n isEdit: false,\n };\n\n return updatedItem;\n }\n });\n\n setList(newList);\n }\n\n const itemSelected = (i: BlockedReason) => {\n setReasonSelected(i);\n onSelect(i);\n setOpenModal(false);\n }\n\n\n useEffect(() => {\n (async () => {\n await loadData();\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n\n const loadData = async () => {\n const data = await BlockedReasonService.getBlockedReason();\n\n if (data.entity) {\n\n let reasonList: BlockedReason[] = [];\n const reasons = data.entity;\n \n reasons.forEach((r) => {\n reasonList.push(new BlockedReason ({\n id: r.id,\n name: r.isPredetermined ? t(r.name) : r.name,\n isPredetermined: r.isPredetermined,\n isEdit: false\n }));\n\n });\n\n setList(reasonList);\n\n if (item && item.id) {\n let reason = new BlockedReason({\n id: item.id,\n name: item.isPredetermined ? t(item.name) : item.name,\n isPredetermined: item.isPredetermined,\n isEdit: false\n });\n setReasonSelected(reason);\n }\n }\n };\n\n const handleReasonNew = () => {\n setReasonNew(new BlockedReason());\n handleEditItem(new BlockedReason());\n setShowNew(true);\n }\n\n const changeReasonNew = (event: React.ChangeEvent<{ name: string, value: string }>) => {\n let value = event.target.value;\n let newCat = new BlockedReason({ name: value });\n setReasonNew(newCat);\n }\n\n const changeReasonEdit = (i: BlockedReason) => (event: React.ChangeEvent<{ name: string, value: string }>) => {\n setReasonNew(i);\n let value = event.target.value;\n\n setReasonNew({ ...i, name: value });\n }\n\n const saveReasonEdit = async (i: BlockedReason) => {\n if (reasonNew && reasonNew?.name !== \"\") {\n const data = await BlockedReasonService.updateBlockedReason(reasonNew);\n if (data) {\n setReasonNew(new BlockedReason());\n await loadData();\n }\n }\n }\n\n const saveBlockedReasonNew = async () => {\n if (reasonNew && reasonNew?.name !== \"\") {\n const data = await BlockedReasonService.createBlockedReason(reasonNew);\n if (data) {\n setShowNew(false);\n setReasonNew(new BlockedReason());\n await loadData();\n }\n }\n }\n\n const handleDelete = async (i: BlockedReason) => {\n if (i) {\n\n const data = await BlockedReasonService.deleteBlockedReason(i);\n if (data.forbiddenDelete) {\n // it wasn't deleted\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"It is not possible to delete a reason linked to a block schedule\"),\n description: \"\"\n })\n );\n }\n else if (data.entity) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Reason successfully removed\"),\n description: \"\"\n })\n );\n await loadData();\n }\n }\n }\n\n\n const handleOpenModal = () => {\n setReasonNew(new BlockedReason());\n handleEditItem(new BlockedReason());\n setShowNew(false);\n setOpenModal(true);\n }\n\n\n const handleCloseModal = () => {\n setOpenModal(false);\n itemSelected(new BlockedReason());\n }\n\n const isValid = () => {\n return isOptional ? isOptional : !reasonSelected || reasonSelected?.id !== null\n }\n\n return (<div className={classes.component}>\n\n <div className={classes.divDropdown} style={{ width: widthSelect || 350}} >\n\n <label className={classes.labelCategory}>\n <Typography className={classes.labelCategory}>\n\n {t(\"Reason\")}{\" \"}\n\n {(isOptional ?? true) ?\n <span className={classes.optional}>({t(\"Optional\")})</span>\n :\n <span className={classes.required}>*</span>\n }\n\n </Typography >\n </label>\n\n <div onClick={handleOpenModal}>\n <Input\n id={\"itemSelect\"}\n name={\"reasonSelected\"}\n value={reasonSelected?.name || \"\"}\n placeholder={placeholderInput || t(\"Select an option\")}\n width={widthSelect || 350}\n inputClass={classes.inputSelectBtn}\n isValid={isValid}\n />\n </div>\n <div className={classes.iconDropdown} onClick={handleOpenModal}>\n <ArrowLineDown />\n </div>\n\n </div>\n\n <Modal\n open={openModal}\n onClose={handleCloseModal}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n disablePortal={true}\n style={{ position: \"relative\", top: -20 }} >\n\n <div className={classes.divModalSelect} style={{ width: widthList || 350}}>\n\n <div className={classes.divTitle}>\n {t(\"Default Reasons\")}\n </div>\n\n <div className={classes.listCategoryScroll} >\n\n {list.map((item) => {\n return <div key={item.id} className={classes.listCategory}>\n\n {!item.isEdit &&\n <div className={`${classes.elementList} ${classes.classRow}`}>\n <div className={classes.name} onClick={() => itemSelected(item)}>\n {item.name}\n </div>\n {item.id !== reasonSelected?.id ?\n <div className={classes.divIconsRow}>\n <button className={classes.btnRow} onClick={(e) => {\n e.stopPropagation();\n handleEditItem(item);\n }}>\n <EditIcon className={classes.editCategory}/>\n </button>\n <button className={classes.btnRow} onClick={(e) => {\n e.stopPropagation();\n handleDelete(item);\n }}>\n <TrashIcon className={classes.deleteCategory}\n style={{color: \"#919CA5\"}}/>\n </button>\n </div>\n : null\n }\n </div>\n }\n {item.isEdit &&\n <div className={classes.divItemEdit} >\n <div className={classes.divInputEdit} >\n <Input\n id={`inputEdit${reasonNew?.id}`}\n name={\"reasonEdit\"}\n value={reasonNew?.name}\n width={widthList || 300}\n maxLength={50}\n placeholder={t(\"Write new reason\")}\n inputClass={classes.input}\n isValid={() => reasonNew?.name != \"\" }\n autoFocus={true}\n onChange={changeReasonEdit(item)}\n />\n </div>\n <button className={classes.iconSave} onClick={() => saveReasonEdit(item)}>\n <SaveIcon />\n </button>\n </div>\n }\n </div >\n })}\n </div >\n\n <div className={classes.divNew} >\n {!showNew &&\n <div className={classes.btnInputNew}>\n <Button className={`${classes.button} ${classes.btnNewBlockedReason}`} onClick={handleReasonNew} >\n {t('New reason')}\n </Button>\n </div>\n }\n {showNew &&\n <div className={classes.btnInputNew}>\n <div >\n <Input\n id={\"reason\"}\n name={\"reason\"}\n value={reasonNew?.name}\n width={widthList || 300}\n maxLength={50}\n placeholder={t(\"Write new reason\")}\n inputClass={classes.input}\n isValid={() => reasonNew?.name != \"\"}\n autoFocus={true}\n onChange={changeReasonNew}\n />\n </div>\n <button className={classes.iconPlus} onClick={saveBlockedReasonNew}>\n <PlusIcon style={{ color: \"#6462F3\", height: 15, width: 15 }} />\n </button>\n </div>\n }\n </div>\n\n </div>\n </Modal>\n </div>);\n};\n\nexport default BlockedReasonSelect;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number) =>\nmakeStyles((theme) => ({\n root: {\n position: \"relative\",\n },\n icon: {\n position: \"absolute\",\n right: 12,\n top: 12,\n \n width: 14,\n height: 16,\n \n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n cursor: \"text\",\n },\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n },\n input: {\n backgroundColor: theme.colors.grey1,\n height: 40,\n padding: \"0px 0px 0px 12px\",\n fontSize: 14,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: width ?? 370\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"0px 0px 0px 12px\",\n width: width ?? 370,\n },\n inputDisabled: {\n backgroundColor: theme.colors.grey1,\n color: theme.colors.grey4,\n },\n inputError: {\n color: \"#f15857\",\n border: \"solid 1px #f15857\",\n },\n })\n);\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { DatePicker, KeyboardDatePicker, MuiPickersUtilsProvider } from \"@material-ui/pickers\";\nimport DateFnsUtils from \"@date-io/date-fns\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\n\nimport { DateInputProps } from \"./props\";\nimport { CalendarIcon } from \"../../../assets/icons\";\nimport useStyles from \"./css\";\nimport {useAppSelector} from \"../../../redux/hooks\";\n\n\nexport default function DateInput(props: DateInputProps) {\n\n const {\n id,\n name,\n value,\n isValid,\n disabled,\n placeholder,\n width,\n format,\n minDate,\n maxDate,\n inputTextClass,\n iconColor,\n onChange,\n onKeyPress,\n onBlur,\n allowManualInput\n } = props;\n \n const [open, setOpen] = useState<boolean>(false);\n const classes = useStyles(width)();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const getId = (): string => {\n if (id) {\n return id;\n }\n\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(\n /[xy]/g,\n function (c) {\n var r = (Math.random() * 16) | 0,\n v = c === \"x\" ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n }\n );\n };\n\n const [inputId] = useState<string>(id || getId());\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n const handleOnKeyPress = (event: any) => {\n if (onKeyPress) {\n onKeyPress(event);\n }\n };\n \n const handleOnBlur = (event: any) => {\n if (onBlur) {\n onBlur(event);\n }\n }\n\n const isError = (): boolean => {\n if (!isValid) {\n return false;\n }\n\n if (isValid() === undefined) {\n return false;\n }\n\n return !isValid();\n };\n\n const getLocale = (): any => {\n switch (localeApp) {\n case \"es\":\n return esLocale;\n\n default:\n return enLocale;\n }\n };\n\n return (\n <div className={classes.root}>\n <MuiPickersUtilsProvider utils={DateFnsUtils} locale={getLocale()}>\n {allowManualInput ? (\n <KeyboardDatePicker\n id={inputId}\n name={name}\n placeholder={placeholder}\n open={open}\n onOpen={() => setOpen(true)}\n onClose={() => setOpen(false)}\n autoOk\n variant=\"inline\"\n inputVariant=\"standard\"\n format={format ?? \"dd/MM/yy\"}\n disabled={disabled ?? false}\n InputProps={{\n disableUnderline: true,\n className: `${classes.input} ${isError() ? classes.inputError : \"\"}`,\n classes: {\n input: inputTextClass ?? classes.inputText,\n disabled: classes.inputDisabled,\n },\n }}\n margin=\"none\"\n value={value || null}\n minDate={minDate}\n maxDate={maxDate}\n onChange={handleOnChange}\n onKeyPress={handleOnKeyPress}\n helperText={null}\n keyboardIcon={<CalendarIcon style={{ color: disabled ? \"#919CA5\" : iconColor ?? \"#6462F3\"}} />}\n onBlur={handleOnBlur}\n />\n ) : (\n <>\n <DatePicker\n id={id}\n name={name}\n placeholder={placeholder}\n open={open}\n onOpen={() => setOpen(true)}\n onClose={() => setOpen(false)}\n autoOk\n variant=\"inline\"\n format={format ?? \"dd/MM/yy\"}\n disabled={disabled ?? false}\n InputProps={{\n disableUnderline: true,\n className: `${classes.input} ${isError() ? classes.inputError : \"\"}`,\n classes:\n {\n input: inputTextClass ?? classes.inputText,\n disabled: classes.inputDisabled\n },\n }}\n margin=\"none\"\n value={value || null}\n minDate={minDate}\n maxDate={maxDate}\n onChange={handleOnChange}\n onKeyPress={handleOnKeyPress}\n helperText={null}\n />\n <div className={classes.icon} onClick={() => setOpen(!disabled ?? true)}>\n <CalendarIcon style={{ color: disabled ? \"#919CA5\" : iconColor ?? \"#6462F3\" }} />\n </div>\n </>\n )}\n </MuiPickersUtilsProvider>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n \"@global\": {\n \".ant-picker-time-panel-cell-disabled\": {\n display: \"none\"\n },\n },\n root: {},\n title: {\n fontFamily: \"Roboto\",\n fontSize: \"12px\",\n color: \"#919CA5\",\n margin: 0,\n },\n required: {\n color: \"#6462F3\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n ...theme.typography.txtBody2,\n margin: 0,\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n display: \"block\",\n marginBottom: \"0.5rem\",\n },\n description: {\n margin: 0,\n color: \"#919CA5\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n },\n inputSpecialist: {\n ...theme.typography.txtBody2,\n backgroundColor: theme.colors.grey1,\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 354,\n \"&::placeholder\": {\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontSize: 12,\n color: \"#5C6477\",\n },\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 399,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n divUploadPhoto: {\n width: 228,\n height: 127,\n backgroundColor: \"#F6F6F6\",\n border: \"1px dashed #DBDCDD\",\n borderRadius: 5,\n cursor: \"pointer\",\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\",\n backgroundPosition: \"center top\",\n display: \"grid\"\n },\n colPhoto: {\n width: 228\n },\n colNotes: {\n width: 479,\n \"& input\": {\n height: 190,\n backgroundColor: \"#F6F6F6\",\n boxSizing: \"border-box\",\n borderRadius: 5,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n width: 480,\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n border: \"solid 1px #6462F3\",\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n }\n },\n inputTextareaNotes: {\n height: 90,\n backgroundColor: \"#F6F6F6\",\n boxSizing: \"border-box\",\n borderRadius: 5,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n width: 480,\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n color: \"rgba(38, 41, 43, 0.8)\", //\"#919CA5\",\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n border: \"solid 1px #6462F3\",\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n },\n notesInstructions: {\n display: \"block\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n iconPlus: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: theme.colors.clearMain\n },\n labelAddPhoto: {\n marginTop: 0,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#919CA5\"\n },\n labelAddPhotoIns: {\n marginTop: -5,\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 9,\n color: \"#919CA5\",\n textAlign: \"center\",\n },\n divPhotoInfo: {\n width: \"100%\",\n display: \"inline\",\n },\n divPhotoInfoIcon: {\n display: \"inline\",\n width: 20,\n height: 20,\n textAlign: \"center\",\n position: \"relative\",\n top: 4,\n left: 2\n },\n divPhotoInfoLabel: {\n display: \"inline\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 11,\n color: \"#919CA5\",\n opacity: \"0.8\",\n position: \"relative\",\n left: -5\n },\n divPrice: {\n },\n moneyIcon: {\n position: \"relative\",\n top: -30,\n right: -205,\n color: \"#5C6477\",\n width: 22,\n backgroundColor: \"#F6F6F6\"\n },\n divCategory: {\n width: 228,\n },\n divPhotoExistHover: {\n width: 228,\n height: 127,\n borderRadius: 5,\n opacity: 0,\n top: 0,\n position: \"relative\",\n \"&:hover\": {\n background: \"rgba(29, 32, 39, 0.7)\",\n display: \"flow-root\",\n opacity: 0.7\n }\n },\n iconCam: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n },\n labelChangePhoto: {\n marginTop: 5,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n opacity: 1\n },\n selectStyle: {\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 165,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n },\n selectHrsNotValid:{\n border: \"1px solid red\"\n },\n selectHrs: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectStyleHrs: {\n position: \"relative\",\n top: 1,\n left: -150,\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n },\n labelH2: {\n fontFamily: \"Inter, sans-serif\",\n display: \"flex\",\n paddingTop: 7,\n color: \"#5C6477\",\n fontSize: \"14px\",\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: \"#FFFFFF\",\n \"& + .MuiSwitch-track\": {\n backgroundColor: theme.colors.clearMain,\n opacity: 1,\n border: \"none\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n //\n },\n // \"&$focusVisible .MuiSwitch-thumb\": {\n // color: \"#6462F3\",\n // border: \"6px solid #fff\",\n // },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n controlLabel: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n dateText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n clockPosition: {\n position: \"absolute\", \n top: 10, \n right: 10\n },\n input: {\n width: \"320px !important\",\n margin: \"0 0 22px\"\n }\n}));\n\nexport default useStyles;\n","export enum WeekdaysEnum {\n Sunday = 0,\n Monday = 1,\n Tuesday = 2,\n Wednesday = 3,\n Thursday = 4,\n Friday = 5,\n Saturday = 6\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\n\nimport Input from \"./../Input\";\nimport useStyles from \"./css\";\nimport { InputWithLabelProps } from \"./props\";\n\nconst InputWithLabel = (props: InputWithLabelProps) => {\n const {\n id,\n label,\n labelClass,\n inputClass,\n name,\n value,\n isValid,\n placeholder,\n width,\n onChange,\n onKeyPress,\n inputDisabled,\n inputReadOnly,\n onClickInput,\n onBlurInput,\n maxLength,\n showCounter,\n inputType\n } = props;\n const classes = useStyles();\n\n const getId = (): string => {\n if (id) {\n return id;\n }\n\n return \"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx\".replace(\n /[xy]/g,\n function (c) {\n var r = (Math.random() * 16) | 0,\n v = c === \"x\" ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n }\n );\n };\n\n const LabelComponent = label;\n\n const [inputId] = useState<string>(id || getId());\n\n const handleOnChange = (event: any) => {\n if (onChange) {\n onChange(event);\n }\n };\n\n const handleOnKeyPress = (event: any) => {\n if (onKeyPress) {\n onKeyPress(event);\n }\n };\n\n return (\n <div className={classes.root}>\n <label htmlFor={inputId} className={labelClass ?? classes.label}>\n {typeof label === \"string\" ? label : <LabelComponent />}\n </label>\n <Input\n id={inputId}\n name={name}\n value={value}\n placeholder={placeholder}\n width={width}\n inputClass={inputClass}\n isValid={isValid}\n onChange={handleOnChange}\n onKeyPress={handleOnKeyPress}\n disabled={inputDisabled}\n readOnly={inputReadOnly}\n onClick={onClickInput}\n onBlur={onBlurInput}\n showCounter={showCounter}\n maxLength={maxLength}\n inputType={inputType}\n />\n </div>\n );\n};\n\nexport default InputWithLabel;\n","import React, { useEffect, useState } from \"react\";\nimport { Typography } from \"@material-ui/core\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport \"antd/dist/antd.css\";\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\n\nimport SelectWithLabel from \"../../../components/common/SelectWithLabel\";\nimport Textarea from \"../../../components/common/Textarea\";\n\nimport EntityForm, {FormProps, Validator} from \"./../../../models/blocked-schedule\";\nimport Switch from \"../../common/Switch\";\nimport BlockedReasonSelect from \"../BlockedReasonSelect\";\nimport DateInput from \"../../common/DateInput\";\nimport BlockSchedule from \"./../../../models/blocked-schedule\";\nimport useStyles from \"./css\";\nimport { ClockIcon } from \"../../../assets/icons\";\nimport BlockedReason from \"../../../models/blocked-reason\";\nimport InputWithLabel from \"../../common/InputWithLabel\";\nimport { DateTime } from 'luxon';\n\n\nconst BlockScheduleForm = (props: FormProps) => {\n\n const {\n users,\n item, \n validator,\n onChange,\n } = props;\n\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const dateFromSchedule = useAppSelector(state => state.blockedSchedule.date);\n const userIdFromSchedule = useAppSelector(state => state.blockedSchedule.userId);\n const userInfo = useAppSelector(state => state.userInfo);\n const [entityState, setEntityState] = useState<EntityForm>(item || new EntityForm());\n const [notes, setNotes] = useState<string>(\"\");\n\n const format = \"HH:mm\";\n const formatDate = \"YYYY-MM-DD\";\n\n const changing = (blocked: BlockSchedule) => { if (onChange) onChange(blocked); }\n\n useEffect(() => {\n if (item && (item.id || dateFromSchedule || userIdFromSchedule)) {\n let newEntity: EntityForm;\n if (item.id) {\n newEntity = {\n ...item,\n start: item.start!,\n end: item.end!,\n };\n\n if (item.notes)\n setNotes(item.notes)\n }\n else {\n newEntity = {...item}\n if (dateFromSchedule){\n let added30Min: Date = new Date(dateFromSchedule!);\n added30Min.setMinutes(added30Min.getMinutes() + 30);\n\n newEntity = {\n ...newEntity,\n start: DateTime.fromJSDate(dateFromSchedule!),\n end: DateTime.fromJSDate(added30Min),\n notes: \"\"\n };\n }\n if (userIdFromSchedule){\n newEntity = {\n ...newEntity,\n specialistId: userIdFromSchedule\n };\n }\n }\n\n setEntityState(newEntity);\n }\n }, [item.id])\n\n const handleStartTime = (time: any) => {\n let newValue: BlockSchedule = entityState;\n const d = toDateTime(moment(entityState.start.toJSDate()).format(formatDate).toString(), time);\n newValue.start = d;\n changing(newValue);\n };\n\n const handleEndTime = (time: any) => {\n let newValue: BlockSchedule = entityState;\n const d = toDateTime(moment(entityState.start.toJSDate()).format(formatDate).toString(), time);\n newValue.end = d;\n changing(newValue);\n };\n\n const toDateTime = (date: string, hhmm: string): DateTime => {\n const newDate = new Date(`${date} ${hhmm}:00`);\n return DateTime.fromJSDate(newDate);\n };\n\n const handleNotes = (event: React.ChangeEvent<{ name: string, value: string }>) => {\n setNotes(event.target.value);\n };\n \n const handleNotesBlur = (event: React.ChangeEvent<{ name: string, value: string }>) => {\n let newValue: BlockSchedule = entityState;\n newValue.notes = event.target.value\n changing(newValue);\n };\n \n const handleAllDay = (event: any) => {\n\n const checked = event.target.checked;\n let newValue: BlockSchedule = entityState;\n\n newValue.allDay = checked;\n\n if (checked) {\n newValue.start = entityState.start.startOf('day');\n newValue.end = entityState.start.endOf('day');\n } \n else {\n newValue.end = toDateTime(moment(entityState.start).format(formatDate).toString(), \"23:59\");\n }\n\n changing(newValue);\n };\n\n const handleDate = (date: Date) => {\n const d = toDateTime(moment(date).format(formatDate).toString(), moment(entityState.start).format(format).toString());\n const df = toDateTime(moment(date).format(formatDate).toString(), moment(entityState.end).format(format).toString());\n let newValue = entityState;\n newValue.start = d;\n newValue.end = df;\n changing(newValue);\n }\n\n const handleStartDate = (date: Date) => {\n let newValue: BlockSchedule = entityState;\n const d = toDateTime(moment(date).format(formatDate).toString(), \"00:00\");\n\n if (entityState.allDay) {\n newValue.start = d;\n }\n else {\n newValue.start = d;\n }\n\n changing(newValue);\n }\n\n const handleEndDate = (date: Date) => {\n let newValue: BlockSchedule = entityState;\n const d = toDateTime(moment(date).format(formatDate).toString(), \"23:59\");\n newValue.end = d;\n changing(newValue);\n }\n\n const handleSpecialist = (e: any) => {\n let newValue = entityState;\n newValue.specialistId = e.target.value;\n changing(newValue);\n }\n\n const handleReasonSelected = (e: any) => {\n let newValue = entityState;\n newValue.blockedReasonId = e.id;\n newValue.blockedReason = e.name;\n changing(newValue);\n }\n\n\n return (<>\n <div className={classes.root}>\n\n <div className={classes.rowContainer}>\n <label className={classes.title}>\n {t(\"Required fields\")} <span className={classes.required}>*</span>\n </label>\n </div>\n\n <div className={classes.rowContainer}>\n <div style={{position: \"relative\"}}>\n {userInfo.hasAccessToScheduleAllSpecialists &&\n <SelectWithLabel\n label={() => (<>\n {t(\"Choose the specialist\")} <span className={classes.required}>*</span>\n </>)}\n value={entityState?.specialistId}\n placeholder={t(\"Name of the specialist\")}\n styleClass={classes.inputSpecialist}\n width={354}\n isValid={() => true}\n name=\"specialist\"\n onChange={handleSpecialist}\n items={users || []}\n />\n }\n {!userInfo.hasAccessToScheduleAllSpecialists &&\n <InputWithLabel\n label={() => (<>\n {t(\"Specialist\")} <span className={classes.required}>*</span>\n </>)}\n value={userInfo.fullName}\n inputClass={classes.input}\n inputDisabled={true}\n inputReadOnly={true}\n width={354}\n />\n }\n </div>\n <div style={{position: \"relative\"}}>\n <BlockedReasonSelect \n placeholderInput={t(\"Select a reason\")}\n isOptional={false}\n item={item ? new BlockedReason({\n id: item.blockedReasonId,\n name: item.blockedReason!,\n isPredetermined: item.isBlockedReasonPredetermined,\n isEdit: false,\n }) : null }\n key={item.blockedReasonId}\n onSelect={handleReasonSelected} \n />\n </div>\n </div>\n\n \n <div className={classes.rowContainer} style={{marginTop: 0}}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleAllDay}\n value={entityState.allDay}\n />\n <div className={classes.switchLabel}>\n <label className={classes.labelH2}>\n {t(\"All day\")}\n </label>\n </div>\n </div>\n </div>\n\n {entityState.allDay ?\n\n <div className={classes.rowContainer}>\n <div style={{marginRight: 26}}>\n <div style={{width: 354}}>\n <Typography className={classes.controlLabel}>\n {t(\"Start date\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div style={{position: \"relative\"}}>\n <DateInput\n placeholder={t(\"dd/mm/yy\")}\n format={\"dd/MMMM/yyyy\"}\n value={entityState.start}\n onChange={handleStartDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={354}\n />\n </div>\n </div>\n\n <div style={{width: 354}}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"End date\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div style={{position: \"relative\"}}>\n <DateInput\n placeholder={t(\"dd/mm/yy\")}\n format={\"dd/MMMM/yyyy\"}\n value={entityState.end.toJSDate()}\n onChange={handleEndDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={354}\n />\n </div>\n </div>\n </div>\n : \n <div className={classes.rowContainer}>\n <div style={{marginRight: 26}}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Date\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div style={{position: \"relative\"}}>\n <DateInput\n placeholder={t(\"dd/mm/yy\")}\n format={\"dd/MMMM/yyyy\"}\n value={entityState.start.toJSDate()}\n onChange={handleDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={354}\n isValid={() => validator?.date}\n />\n </div>\n </div>\n\n <div style={{marginRight: 22}}>\n <Typography className={classes.controlLabel}>\n {t(\"Start time\")}\n </Typography>\n <span className={classes.dot}>*</span>\n \n <div style={{position: \"relative\"}}>\n <TimePicker\n onOk={(time) => {\n handleStartTime(time.format(format));\n }}\n className={`${classes.selectStyle} ${classes.selectHrs} ${validator?.start ? \"\" : classes.selectHrsNotValid}`}\n placeholder=\"HH:mm\"\n inputReadOnly={true}\n showNow={false}\n value={moment(entityState.start.toJSDate(), format)}\n disabledHours={() => []}\n format={format}\n />\n <div className={classes.clockPosition}>\n <ClockIcon />\n </div>\n </div>\n </div>\n \n <div>\n <Typography className={classes.controlLabel}>\n {t(\"End time\")}\n </Typography>\n <span className={classes.dot}>*</span>\n <div style={{position: \"relative\"}}>\n <TimePicker\n onOk={(time) => {\n handleEndTime(time.format(format));\n }}\n className={`${classes.selectStyle} ${classes.selectHrs} ${validator?.end ? \"\" : classes.selectHrsNotValid}`}\n placeholder=\"HH:mm\"\n inputReadOnly={true}\n showNow={false}\n value={moment(entityState.end.toJSDate(), format)}\n disabledHours={() => []}\n format={format}\n />\n <div className={classes.clockPosition}>\n <ClockIcon />\n </div>\n </div>\n </div>\n </div>\n }\n\n\n <div className={classes.rowContainer}>\n <div className={classes.colNotes}>\n\n <label htmlFor={\"lblNotes\"} className={classes.label}>\n {t(\"Notes\")} <span className={classes.optional}> {\" \"} ({t(\"Optional\")})</span>\n </label>\n\n <Textarea\n inputClass={`${classes.inputTextareaNotes}`}\n id={\"notes\"}\n name={\"notes\"}\n maxLength={180}\n value={notes ?? ''}\n onChange={handleNotes}\n placeholder={t(\"Enter here notes of why this schedule will be blocked.\")}\n width={732} styles={{ height: 90 }}\n onBlur={handleNotesBlur}\n />\n </div>\n </div>\n </div >\n </>);\n\n};\n\nexport default BlockScheduleForm;","import React, { useEffect, useMemo, useState } from \"react\";\nimport { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport { Trans, useTranslation } from \"react-i18next\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport Draggable, { ControlPosition } from 'react-draggable';\nimport useStyles from \"./css\";\nimport { blockedScheduleActions } from \"../../../redux/blocked-schedule-slice\";\nimport { ExclamationIcon, TrashIcon } from \"../../../assets/icons\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport BlockedScheduleForm from \"../BlockedScheduleForm\";\nimport { UserService } from \"../../../api/user-service\";\nimport BlockedScheduleService from \"../../../api/blocked-schedule-service\";\n\nimport { SelectItem } from \"../../common/Select\";\nimport { ApiClient } from \"../../../api/api-client\";\nimport BlockSchedule, { Validator } from \"../../../models/blocked-schedule\";\nimport BlockedSchedule from \"../../../models/blocked-schedule\";\n\nconst BlockScheduleModal = (props: any) => {\n\n const { refresh } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n const dispatch = useAppDispatch();\n const showModal = useAppSelector(state => state.blockedSchedule.showModal);\n const blockedSheduleId = useAppSelector((state) => state.blockedSchedule.blockedSheduleId);\n const userInfo = useAppSelector(state => state.userInfo);\n const { enqueueAlert } = alertsActions;\n \n const [position, setPosition] = useState<ControlPosition>({ x: 0, y: 0 });\n const draggableId = useMemo(\n () => `draggable-schedule-popup-handle-${Math.random().toString(36).substring(2)}`,\n []\n );\n \n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [confirmBlockModal, setConfirmBlockModal] = useState<boolean>(false);\n const [counterAppointments, setCounterAppointments] = useState<number>(0);\n const [isValid, setIsValid] = useState<boolean>(false);\n const [isChanged, setIsChanged] = useState<boolean>(false);\n const [isEdit, setIsEdit] = useState<boolean>(false);\n const [users, setUsers] = useState<SelectItem[]>([]);\n const [userName, setUserName] = useState<string>(\"\");\n const [entity, setEntity] = useState<BlockSchedule>(new BlockSchedule());\n const [entityInit, setEntityInit] = useState<BlockSchedule>(new BlockSchedule());\n const [entityValid, setEntityValid] = useState<Validator>({\n specialistId: true,\n reasonId: true,\n date: true,\n start: true,\n end: true\n });\n const AllSpecialists = \"AllSpecialists\";\n\n const loadUsers = async () => {\n const usersOnlyWithServices = false;\n const usersDb = await UserService.getUsersBaseInfoByAccount(usersOnlyWithServices);\n\n let selectItems:SelectItem[] = [];\n \n selectItems.push({\n key: AllSpecialists,\n value: t(AllSpecialists),\n } as SelectItem);\n\n usersDb.map((u) => {\n const select: SelectItem = {\n key: u.id,\n value: `${u.firstName} ${u.lastName}`,\n };\n return selectItems.push(select);\n });\n\n setUsers(selectItems);\n\n const currentUserAuthId = ApiClient.getUserInfo().userId;\n const currentUser = usersDb.filter(u => u.authenticationId == currentUserAuthId);\n\n if (currentUser.length > 0) {\n const fullName = currentUser[0].firstName + \" \" + currentUser[0].lastName;\n setUserName(fullName);\n }\n };\n\n useEffect(() => {\n\n\n\n }, [])\n\n const getBlockedSchedule = async () => {\n const schedule: BlockSchedule = await BlockedScheduleService.getBlockedScheduleById(blockedSheduleId);\n setEntity(schedule);\n setIsEdit(true);\n }\n\n useEffect(() => {\n if (blockedSheduleId) {\n (async () => {\n await getBlockedSchedule();\n })();\n }\n }, [blockedSheduleId])\n\n useEffect(() => {\n if (!showModal) return;\n\n if (!users.length){\n (async () => {\n await loadUsers();\n })();\n }\n\n setEntity(new BlockSchedule());\n const v: Validator = {\n specialistId: true,\n reasonId: true,\n date: true,\n start: true,\n end: true\n };\n setEntityValid(v);\n \n }, [showModal])\n\n const handleCloseModal = () => {\n setEntity(new BlockSchedule());\n setIsEdit(false);\n setIsChanged(false);\n dispatch(blockedScheduleActions.setShowModal(false));\n dispatch(blockedScheduleActions.setBlockedSheduleId(undefined));\n };\n \n const handleGoBackClick = () => {\n if (isChanged) {\n setCancelModal(true);\n }\n else {\n handleCloseModal();\n }\n }\n\n const handleOnCreateClick = async () => {\n\n const entityToSave = {...entity, \n specialistId: entity.specialistId !== AllSpecialists ? entity.specialistId : null \n };\n\n let response;\n if (!entityToSave.id){\n response = await BlockedScheduleService.createBlockedSchedule(entityToSave);\n } else {\n response = await BlockedScheduleService.updateBlockedSchedule(entityToSave);\n }\n\n if (response) {\n if (!response.forbiddenToBlock) {\n handleCloseModal();\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Blocked schedule\"),\n description: isEdit ? \n `${t(\"The block schedule has been updated\")}` : \n `${t(\"Schedule blocked by\")} ${entity.isBlockedReasonPredetermined && entity.blockedReason ? t(entity.blockedReason) : entity.blockedReason}`,\n })\n );\n if (refresh) refresh();\n }\n else {\n setConfirmBlockModal(true);\n setCounterAppointments(response.appointmentsNotServed);\n }\n }\n }\n\n const handleOnDeleteClick = async () => {\n \n const entityToSave = {...entity, \n specialistId: entity.specialistId !== AllSpecialists ? entity.specialistId : null \n };\n\n const deleting = await BlockedScheduleService.deleteBlockedSchedule(entityToSave);\n\n if (deleting){\n handleCloseModal();\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Block schedule removed\"),\n description: t(\"The blocked schedule has been successfully deleted\"),\n })\n );\n if (refresh) refresh();\n }\n }\n\n \n const handleFormChange = (e: BlockSchedule) => {\n setEntity(e);\n runValidations(e);\n\n const isSameObj = JSON.stringify(entityInit) !== JSON.stringify(e);\n setIsChanged(isSameObj);\n };\n\n \n const runValidations = (item: BlockSchedule) => {\n const v: Validator = {\n specialistId: !userInfo.hasAccessToScheduleAllSpecialists || Boolean(item.specialistId) && item.specialistId !== \"\",\n reasonId: item.blockedReasonId !== \"\",\n date: true,\n start: (item.start && item.end) ? item.start <= item.end : true,\n end: (item.start && item.end) ? item.start <= item.end : true\n };\n \n const isV: boolean = v.specialistId && v.reasonId && v.date && v.start && v.end;\n setIsValid(isV);\n setEntityValid(v);\n\n };\n\n const handleForceSave = async () => {\n \n const entityToSave = {...entity, \n specialistId: entity.specialistId !== AllSpecialists ? entity.specialistId : null \n };\n\n let response;\n if (!entityToSave.id){\n response = await BlockedScheduleService.createBlockedSchedule(entityToSave, true);\n } else {\n response = await BlockedScheduleService.updateBlockedSchedule(entityToSave, true);\n }\n if (response) {\n handleCloseModal();\n setConfirmBlockModal(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Blocked schedule\"),\n description: isEdit ? \n `${t(\"The block schedule has been updated\")}` : \n `${t(\"Schedule blocked by\")} ${entity.isBlockedReasonPredetermined && entity.blockedReason ? t(entity.blockedReason) : entity.blockedReason}`,\n })\n );\n if (refresh) refresh();\n }\n }\n\n return (<>\n \n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={showModal}\n onClose={handleGoBackClick}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={showModal}>\n <Draggable\n position={position}\n enableUserSelectHack={false}\n onDrag={(_, { x, y }) => setPosition({ x, y })}\n bounds=\"body\"\n handle={'#' + draggableId}\n >\n <div className={classes.paper}>\n <div className={classes.draggableModalHeader} id={draggableId}></div>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {isEdit\n ?\n t(\"Block schedule detail\")\n :\n t(\"Block schedule\")\n }\n \n </Typography>\n \n <div className={classes.modalSubTitleText}>{t(\"Person blocking schedule by:\") + \" \" + userName}</div>\n </div>\n \n <div className={classes.modalActions}>\n {isEdit &&\n <Button className={`${classes.iconTrash}`} onClick={handleOnDeleteClick} >\n <TrashIcon style={{ color: \"#919CA5\", fontSize: 14 }} />\n </Button>\n }\n \n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleGoBackClick}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.createCustomer}`}\n disabled={!(isValid && isChanged)}\n classes={{ disabled: classes.createDisabled }}\n onClick={handleOnCreateClick}\n >\n {isEdit\n ?\n t(\"Save changes\")\n :\n t(\"Block schedule\")\n }\n </Button>\n </div>\n </div>\n \n <BlockedScheduleForm\n users={users}\n item={entity}\n validator={entityValid}\n onChange={handleFormChange}\n />\n \n </div>\n </Draggable>\n </Fade>\n </Modal>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.cancelModalPaper}>\n <div>\n <div\n className={`${classes.cancelModalCenter} ${classes.cancelModalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n\n {isEdit \n ?\n t(\"Cancel block schedule edition?\")\n :\n t(\"Cancel block schedule registration?\")\n }\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={() => setCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n handleCloseModal();\n setCancelModal(false);\n }}\n >\n {t(\"Cancel\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n\n \n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalConfirm}\n open={confirmBlockModal}\n onClose={() => setConfirmBlockModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={confirmBlockModal}>\n <div className={classes.confirmModalPaper}>\n <div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n <div className={`${classes.cancelModalCenter} ${classes.cancelModalTitleSpace}`} >\n <Typography className={classes.modalConfirmTitleText}>\n {t(\"Continue with the block schedule?\")}\n </Typography>\n </div>\n \n <div className={`${classes.cancelModalCenter} ${classes.cancelModalTitleSpace}`} >\n <Typography className={classes.modalConfirmSubTitleText}>\n <Trans i18nKey=\"ThereAreAppointmentsToBlockSchedule\" t={t} count={counterAppointments} />\n </Typography>\n </div>\n \n <div className={`${classes.cancelModalCenter} ${classes.cancelModalTitleSpace}`} >\n <Typography className={classes.modalConfirmSubTitleText}>\n <Trans i18nKey=\"ThereAreAppointmentsToBlockScheduleSuggest\" t={t} />\n </Typography>\n </div>\n\n <div className={classes.modalActionsConfirm}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={() => setConfirmBlockModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={handleForceSave}\n >\n {t(\"Save changes\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </>);\n};\n\nexport default BlockScheduleModal;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n container: {\n height: \"calc(100vh - 61px)\",\n minWidth: \"800px\",\n margin: \"0 -24px\",\n padding: \"0 0px 0 5px\",\n backgroundColor: \"white\"\n },\n}));\n\nexport default useStyles;\n","export class Weekday {\n accountId: string | null;\n dayNumber: number;\n dayName: string;\n opening: string | null;\n closing: string | null;\n isOpen: boolean;\n\n constructor(x?: Weekday) {\n if (typeof x === \"object\" && x != null) {\n this.accountId = x.accountId ?? null;\n this.dayNumber = x.dayNumber || 0;\n this.dayName = x.dayName || \"\";\n this.opening = x.opening || \"\";\n this.closing = x.closing || \"\";\n this.isOpen = x.isOpen || false;\n }\n else {\n this.accountId = x!.accountId ?? null;\n this.dayNumber = x!.dayNumber ?? 0;\n this.dayName = x!.dayName || \"\";\n this.opening = x!.opening || \"\";\n this.closing = x!.closing || \"\";\n this.isOpen = x!.isOpen || false;\n }\n }\n}\n\n","import { ApiClient } from \"./api-client\";\nimport { Weekday } from \"../models/weekday\";\nimport { Response } from \"./../models/response\";\nimport { UserScheduleInfo } from \"../models/user-schedule-info\";\n\nexport class WeekdayService {\n\n private static baseUrl: string = \"/weekdays\";\n\n static updateWeekday(day: Weekday, establishmentAccountId?: string): Promise<number> {\n let endpoint = `${this.baseUrl}/updateweekday`;\n\n day.accountId = establishmentAccountId ?? null;\n\n return ApiClient.post(endpoint, day)\n .then(data => {\n return data.appointmentsAffected;\n });\n }\n \n static async getWeekdaysForEstablishments(establishmentIds: string[] | undefined): Promise<Weekday[]> {\n let days: Weekday[] = [];\n const endpoint = `${this.baseUrl}/getweekdaysforestablishments?`\n \n Object.entries({\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\")\n \n const data = await ApiClient.get(endpoint);\n \n data.weekdays.forEach((i: any) => {\n if (i)\n days.push(new Weekday(i));\n });\n \n return days;\n }\n\n static async getWeekdays(establishmentAccountId?: string): Promise<Weekday[]> {\n let days: Weekday[] = [];\n\n let endpoint = `${this.baseUrl}/getweekdays`;\n\n if (establishmentAccountId) {\n endpoint += `?AccountId=${establishmentAccountId}`;\n }\n\n const data = await ApiClient.get(endpoint);\n\n data.weekdays.forEach((i: any) => {\n if (i)\n days.push(new Weekday(i));\n });\n\n return days;\n }\n\n static async getAccountWeekdaysAsUserSchedule(establishmentAccountId?: string): Promise<UserScheduleInfo> {\n let endpoint = `${this.baseUrl}/getaccountweekdaysasuserschedule`;\n\n if (establishmentAccountId) {\n endpoint += `?AccountId=${establishmentAccountId}`;\n }\n return await ApiClient.get(endpoint,)\n .then((data) => data.schedule);\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n \n width: 415,\n maxHeight: 500,\n \n overflowY: \"auto\",\n \n \"&::-webkit-scrollbar\": {\n backgroundColor: theme.colors.white,\n width: 16,\n },\n \"&::-webkit-scrollbar-track\": {\n backgroundColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-track:hover\": {\n backgroundColor: \"#F4F4F4\",\n width: 16,\n },\n \"&::-webkit-scrollbar-thumb\": {\n backgroundColor: \"#babac0\",\n \n border: \"solid\",\n borderRadius: 16,\n borderWidth: 5,\n borderColor: theme.colors.white, \n },\n \"&::-webkit-scrollbar-thumb:hover\": {\n backgroundColor: \"#a0a0a5\",\n \n border: \"solid\",\n borderWidth: 4,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-button\": {\n display: \"none\",\n },\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n \n paddingTop: 2,\n paddingLeft: 15,\n paddingRight: 10,\n paddingBottom: 16,\n },\n modalHeader: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"flex-start\",\n \n position: \"sticky\",\n top: 0,\n \n width: \"100%\",\n height: 71,\n \n paddingLeft: 15,\n paddingTop: 23,\n paddingRight: 10,\n paddingBottom: 22,\n \n backgroundColor: theme.palette.background.paper,\n \n borderTop: \"solid\",\n borderTopWidth: 1,\n borderTopColor: \"#dbdcdd\",\n borderTopRadius: \"10px\",\n },\n modalTitle: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey5,\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n blockers: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 16,\n },\n blocker: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n width: 374,\n height: 68,\n \n paddingTop: 9,\n paddingLeft: 8,\n \n backgroundColor: theme.colors.grey2,\n borderRadius: 4,\n boxShadow: \"0px 0px 5px rgba(0, 0, 0, 0.25)\",\n \n cursor: \"pointer\",\n },\n blockerReason: {\n ...theme.typography.caption1,\n fontWeight: 700,\n color: \"rgba(50, 57, 71, 0.76)\"\n },\n blockerTimeRow: {\n marginTop: 2,\n \n ...theme.typography.caption2,\n color: theme.colors.grey5,\n },\n blockerSpecialist: {\n marginTop: 4,\n \n ...theme.typography.caption2,\n fontWeight: 700,\n color: \"rgba(50, 57, 71, 0.76)\",\n },\n}));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { multipleBlockedScheduleActions } from \"../../../redux/multiple-blocked-schedule-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { blockedScheduleActions } from \"../../../redux/blocked-schedule-slice\";\n\nimport { Backdrop, Fade, Modal } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { CrossIcon, DeleteIcon } from \"../../../assets/icons\";\nimport BlockSchedule from \"../../../models/blocked-schedule\";\n\n\nexport default function MultipleBlockedScheduleModal() {\n\n const state = useAppSelector((state) => state.multipleBlockedSchedule);\n const { isModalOpen, blockerCount, blockers } = state;\n\n const dispatch = useAppDispatch();\n\n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n\n const dateFormat = (date: Date): string => {\n const formatDate = date.toTimeString().split(\" \")[0].split(\":\");\n return `${formatDate[0]}:${formatDate[1]}`;\n };\n\n function handleOpenSpecificBlockerModal(appointmentId: string) {\n dispatch(blockedScheduleActions.setShowModal(true));\n dispatch(blockedScheduleActions.setBlockedSheduleId(appointmentId));\n }\n\n function handleCloseModal() {\n dispatch(multipleBlockedScheduleActions.resetState())\n }\n\n function mapAppointmentBlockerToDisplayBlock(blockSchedule: BlockSchedule) {\n return (\n <div\n className={classes.blocker}\n key={blockSchedule.id}\n onClick={() => handleOpenSpecificBlockerModal(blockSchedule.id!)}\n >\n <div>\n <span style={{ display: \"inline-block\", marginRight: 5 }}>\n <DeleteIcon color={\"rgba(50, 57, 71, 0.76);\"} />\n </span>\n <span className={classes.blockerReason}>\n {blockSchedule.isBlockedReasonPredetermined ? t(blockSchedule.blockedReason!) : blockSchedule.blockedReason}\n </span>\n </div>\n\n <div className={classes.blockerTimeRow}>\n {\n blockSchedule.allDay\n ?\n t(\"All day\")\n :\n dateFormat(blockSchedule.start.toJSDate()) +\n \" - \" +\n dateFormat(blockSchedule.end.toJSDate())\n }\n </div>\n <div className={classes.blockerSpecialist}>\n {blockSchedule.specialist}\n </div>\n </div>\n );\n }\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isModalOpen}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={isModalOpen}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n {blockerCount + \" \" + t(\"blocked schedules\")}\n </div>\n <span className={classes.closeButton} onClick={handleCloseModal}>\n <CrossIcon color={\"#919CA5\"} />\n </span>\n </div>\n <div className={classes.content}>\n <div className={classes.blockers}>\n {blockers.map(mapAppointmentBlockerToDisplayBlock)}\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n \n minWidth: 320,\n width: 464,\n \n border: \"solid\",\n borderColor: theme.colors.clearYellow,\n borderWidth: 1,\n borderRadius: 10,\n \n boxShadow: theme.shadows[5],\n padding: 24,\n \n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"solid\",\n borderColor: theme.colors.clearYellow,\n borderWidth: 1,\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: theme.colors.grey4,\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n ...theme.typography.header4,\n fontWeight: 700,\n textAlign: \"center\",\n \n color: \"#26292B\",\n },\n modalContent: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n width: 50,\n height: 50,\n \n borderRadius: \"50%\",\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearYellow,\n },\n modalMain: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n \n gap: 3,\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n marginTop: 3,\n \n ...theme.typography.txtBody1,\n fontSize: 12,\n fontWeight: 300,\n \n textAlign: \"center\",\n \n color: \"#4A4D51\",\n },\n editAppointmentLink: {\n color: theme.colors.clearMain,\n textDecoration: \"underline\",\n textDecorationColor: theme.colors.clearMain,\n \n \"&:hover\": {\n color: theme.colors.clearMain,\n textDecoration: \"underline\",\n textDecorationColor: theme.colors.clearMain,\n }\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: \"#ACB7C0\",\n },\n editAppointment: {\n background: theme.colors.clearYellow,\n color: theme.colors.grey1,\n \"&:hover\": {\n background: theme.colors.clearYellow,\n },\n },\n separator: {\n \n width: 217,\n height: 0,\n \n borderTop: \"solid\",\n borderTopWidth: 1,\n borderTopColor: \"rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n \n },\n}));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { Link } from \"react-router-dom\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Modal, Typography, Button } from '@material-ui/core';\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\n\nimport { CrossIcon, ExclamationIcon } from \"../../../assets/icons\";\nimport { AppointmentDragAndDropScheduleBusyModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Url } from \"../../../constants/url\";\n\n\nexport default function AppointmentDragAndDropScheduleBusyModal(props: AppointmentDragAndDropScheduleBusyModalProps) {\n \n const { state, onContinue, onClose } = props;\n const { open, appointmentId, hasSimultaneousAppointments } = state;\n \n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={classes.modalTitleSpace}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Are you sure to move the appointment?\")}\n </Typography>\n </div>\n <div className={classes.separator} />\n <div className={classes.modalMain}>\n <Typography className={classes.modalContentText}>\n {hasSimultaneousAppointments \n ? t(\"It is possible that the new schedule is outside business hours.\")\n : t(\"Existing appointments may be scheduled at this time or the new schedule is outside business hours.\")\n }\n </Typography>\n <Typography className={classes.modalContentText}>\n <span>{t(\"We suggest you go to the\") + \" \\\"\"}</span>\n <Link className={classes.editAppointmentLink} to={`${Url.Appointments.Main}/${appointmentId}`}>{`${t(\"Edit appointment\")}`}</Link>\n <span>{\"\\\" \" + t(\"screen to review available dates and times.\")}</span>\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.editAppointment}`}\n onClick={() => {\n if (onContinue) {\n onContinue();\n }\n }}\n >\n {t(\"Continue\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import * as React from \"react\";\nimport { useEffect, useState } from \"react\";\nimport { useHistory, useLocation } from \"react-router-dom\";\nimport { ScheduleAppointmentActionsMenuContextProvider } from '../../common/Scheduler/ScheduleAppointmentActionsMenu';\nimport WeekScheduler from '../../common/Scheduler/WeekScheduler';\nimport DayScheduler from '../../common/Scheduler/DayScheduler';\nimport { DndProvider } from 'react-dnd'\nimport { HTML5Backend } from 'react-dnd-html5-backend'\nimport { AppointmentService } from \"../../../api/appointment-service\";\nimport BlockedScheduleService from \"../../../api/blocked-schedule-service\";\nimport { UserService } from \"../../../api/user-service\";\nimport { useSelector } from \"react-redux\";\nimport { RootState, selectAccountSettings } from \"../../../redux/store\";\nimport { connect } from \"../../../redux/common-hub-slice\";\nimport { Appointment } from \"../../../models/appointment\";\nimport AppointmentListToolbar from \"./../AppointmentListToolbar\";\nimport { SelectItem } from \"../../common/Select\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { navbarActions } from '../../../redux/navbar-slice';\nimport { schedulerActions } from \"../../../redux/scheduler-slice\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport { startOfDay, startOfWeek } from \"date-fns\";\nimport { endOfDay, endOfWeek } from \"date-fns/esm\";\nimport BlockScheduleModal from \"../BlockScheduleModal\";\nimport useStyles from \"./css\";\nimport BlockSchedule from \"../../../models/blocked-schedule\";\nimport { AppointmentStatus } from \"../../../models/enums/appointment-status\";\nimport { LocalStorageKey } from \"../../../constants/local-storage-key\";\nimport { WeekdayService } from \"../../../api/settings-weekdays-service\";\nimport { WeekdaysEnum } from \"../../../models/enums/weekdays\";\nimport MultipleBlockedScheduleModal from \"../MultipleBlockedScheduleModal\";\nimport AppointmentDragAndDropScheduleBusyModal from \"../AppointmentDragAndDropScheduleBusyModal\";\nimport { Url } from \"../../../constants/url\";\nimport { useTranslation } from \"react-i18next\";\n\ninterface LocationState {\n redirectedAppointmentId: string | undefined;\n redirectedAppointmentDate: Date | undefined;\n}\n\n\nexport default function AppointmentList() {\n\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n const AllSpecialists = \"AllSpecialists\";\n\n const location = useLocation<LocationState | undefined>();\n const history = useHistory();\n const [isLoaded, setIsLoaded] = useState<boolean>(false);\n const dispatch = useAppDispatch();\n const { setDaysOff, setAllUsers, setSelectedUsers, setSelectedStatuses, setTooltipAppointment, setStartDayHours, setEndDayHours, setCurrentViewName, setStartWeekHour, setEndWeekHour, setWeekDays, setAppointmentDndModalState } = schedulerActions;\n const daysOff = useAppSelector((state) => state.scheduler.daysOff);\n const { updateIsWideLayout } = applicationInterfaceActions;\n const [appointments, setAppointments] = useState<Appointment[]>([]);\n const [absences, setAbsences] = useState<BlockSchedule[]>([]);\n const currentDate = useAppSelector((state) => state.scheduler.currentDate);\n const currentViewName = useAppSelector((state) => state.scheduler.currentViewName);\n const [lastCurrentViewName, setLastCurrentViewName] = useState<string>(currentViewName);\n const [appointmentsLoadedForDate, setAppointmentsLoadedForDate] = useState<Date | null>(null);\n\n const userId = useAppSelector((state) => state.userInfo.userId);\n const hasAccessToScheduleAllSpecialists = useAppSelector((state) => state.userInfo.hasAccessToScheduleAllSpecialists);\n const accountSettings = useAppSelector(selectAccountSettings);\n const allUsers = useAppSelector((state) => state.scheduler.allUsers);\n const selectedUsers = useAppSelector((state) => state.scheduler.selectedUsers);\n const selectedStatuses = useAppSelector((state) => state.scheduler.selectedStatuses);\n const startDayHours = useAppSelector((state) => state.scheduler.startDayHours);\n const appointmentDndModalState = useAppSelector(state => state.scheduler.appointmentDndModalState);\n const selectedEstablishments = useAppSelector(state => state.enterprise.selectedEstablishments);\n \n const commonHubConnection = useSelector(\n (state: RootState) => state.commonHub.connection\n );\n\n // unsubscribe\n commonHubConnection?.off(\"updateAppointmentList\");\n commonHubConnection?.off(\"changeAppointmentStatus\");\n commonHubConnection?.off(\"updateAppointmentData\");\n commonHubConnection?.off(\"updateAppointmentsBlockedSchedule\");\n commonHubConnection?.off(\"updateUserHasServicesInCharge\");\n // subscribe\n commonHubConnection?.on(\"updateAppointmentList\", () => {\n void loadData(false, true);\n });\n commonHubConnection?.on(\"changeAppointmentStatus\",\n (appointmentId, status) => handleStatusChange(appointmentId, status)\n );\n commonHubConnection?.on(\"updateAppointmentData\", (appointmentId) => handleUpdateAppointmentData(appointmentId));\n commonHubConnection?.on(\"updateAppointmentsBlockedSchedule\", () => updateBlockedSchedule());\n commonHubConnection?.on(\"updateUserHasServicesInCharge\",\n (userId, fullName, hasServicesInCharge) => handleUserHasServicesInChargeChange(userId, fullName, hasServicesInCharge)\n );\n dispatch(connect());\n\n const handleStatusChange = (appointmentId: string, status: string) => {\n let appointmentToUpdateIndex = appointments.findIndex(a => a.appointmentId === appointmentId);\n if (appointmentToUpdateIndex !== -1) {\n const newAppointmentStatus: AppointmentStatus = parseInt(status);\n let newAppointments = [...appointments];\n newAppointments[appointmentToUpdateIndex] = {\n ...newAppointments[appointmentToUpdateIndex],\n status: newAppointmentStatus\n };\n setAppointments(newAppointments);\n }\n };\n\n const handleUserHasServicesInChargeChange = (userId: string, fullName: string, hasServicesInCharge: boolean) => {\n let newUsers = [...allUsers];\n\n if (hasServicesInCharge) { \n newUsers.push({ key: userId, value: fullName });\n } else {\n newUsers = newUsers.filter(user => user.key !== userId);\n }\n dispatch(setAllUsers(newUsers));\n };\n\n\n const handleUpdateAppointmentData = (appointmentId: string) => {\n async function fetchData(appointmentId: string) {\n\n if (currentViewName === \"Week\") {\n const appointment: Appointment | null =\n await AppointmentService.getAppointmentCalendarById(appointmentId, !selectedUsers?.length ? undefined : selectedUsers, !selectedStatuses?.length ? undefined : selectedStatuses);\n if (appointment) {\n const appointmentToUpdateIndex = appointments.findIndex(a => a.appointmentId === appointmentId);\n if (appointmentToUpdateIndex !== -1) {\n let newAppointments = [...appointments];\n newAppointments[appointmentToUpdateIndex] = appointment;\n setAppointments(newAppointments);\n }\n }\n } else {\n const apps: Appointment[] =\n await AppointmentService.getSplitByServicesAppointmentCalendarById(appointmentId, !selectedUsers?.length ? undefined : selectedUsers, !selectedStatuses?.length ? undefined : selectedStatuses);\n let newAppointments = [...appointments];\n apps.forEach(app => {\n const appointmentToUpdateIndex = appointments.findIndex(a => a.appointmentId === app.appointmentId && a.firstServiceId === app.firstServiceId);\n if (appointmentToUpdateIndex !== -1) {\n newAppointments[appointmentToUpdateIndex] = app;\n }\n });\n setAppointments(newAppointments);\n }\n }\n\n const appointmentToUpdateIndex = appointments.findIndex(a => a.appointmentId === appointmentId);\n if (appointmentToUpdateIndex !== -1) {\n fetchData(appointmentId);\n }\n };\n\n const _setTooltipAppointments = (appointments: any[]) => {\n dispatch(setTooltipAppointment(appointments));\n };\n\n useEffect(() => {\n dispatch(updateIsWideLayout(true));\n });\n \n useEffect(() => {\n // restore selected statuses from localStorage\n if (selectedStatuses === null) {\n const storageKey = accountSettings.isEnterprise ? LocalStorageKey.SchedulerSelectedStatusesEnterprise : LocalStorageKey.SchedulerSelectedStatuses\n const json = localStorage.getItem(storageKey + userId);\n if (json) {\n const selectedStatuses = JSON.parse(json);\n if (selectedStatuses.constructor === Array) {\n dispatch(setSelectedStatuses(selectedStatuses));\n }\n }\n }\n }, []);\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n if (accountSettings.isEnterprise === null) return;\n\n if (!Array.isArray(daysOff)) {\n await loadDayOff();\n }\n if (!startDayHours.length) {\n await loadWeekDays();\n }\n \n if (hasAccessToScheduleAllSpecialists){\n await loadUsers();\n } else {\n dispatch(setSelectedUsers([]));\n }\n\n if (location?.state?.redirectedAppointmentDate !== undefined) {\n const loadAppointments = async () => {\n await loadData(false, true);\n };\n loadAppointments();\n }\n\n setIsLoaded(true);\n dispatch(navbarActions.setShowLoader(false));\n }\n\n if (userId) {\n const viewName = localStorage.getItem(LocalStorageKey.SchedulerViewName + userId);\n if (viewName) {\n dispatch(setCurrentViewName(viewName));\n }\n }\n\n fetchData();\n },\n [accountSettings.isEnterprise, selectedEstablishments]\n );\n \n useEffect(\n () => {\n async function fetchData() {\n await loadData(false, true);\n }\n \n if (accountSettings.isEnterprise === null) return;\n if (allUsers && selectedUsers) {\n fetchData();\n }\n \n dispatch(navbarActions.setExternalContent((\n <AppointmentListToolbar\n allUsers={allUsers}\n selectedUsers={selectedUsers ?? []}\n selectedStatuses={selectedStatuses ?? []}\n saveSelectedUsers={saveSelectedUsers}\n saveSelectedStatuses={saveSelectedStatuses}\n />)));\n },\n [selectedUsers, selectedStatuses, allUsers]\n );\n \n useEffect(\n () => {\n async function fetchData() {\n await loadData(true, true); //Forcing appointments array cleanup to fix phantom blocked schedules\n }\n \n if (currentDate.getTime() !== appointmentsLoadedForDate?.getTime() || currentViewName !== lastCurrentViewName) {\n void fetchData();\n setLastCurrentViewName(currentViewName);\n }\n },\n [currentDate, currentViewName]\n );\n \n useEffect(() => {\n if (location?.state?.redirectedAppointmentId && location?.state?.redirectedAppointmentDate?.getTime() === appointmentsLoadedForDate?.getTime()) {\n dispatch(schedulerActions.setAppointmentId(location.state.redirectedAppointmentId));\n history.replace(Url.Appointments.Main, { redirectedAppointmentDate: undefined, redirectedAppointmentId: undefined });\n }\n }, [location?.state?.redirectedAppointmentId, appointmentsLoadedForDate]);\n\n async function loadBlockedSchedule(showLoader: boolean, dateFrom: Date, dateTo: Date) {\n if (showLoader) dispatch(navbarActions.setShowLoader(true));\n const blocked: BlockSchedule[] = accountSettings.isEnterprise\n ? await BlockedScheduleService.getBlockedScheduleByEstablishments(dateFrom, dateTo, selectedEstablishments)\n : await BlockedScheduleService.getBlockedScheduleByAccount(dateFrom, dateTo);\n if (showLoader) dispatch(navbarActions.setShowLoader(false));\n\n const mappedBlockers = blocked.flatMap(mapBlockerToSingleOrMultipleAbsence);\n\n return mappedBlockers;\n }\n\n function mapBlockerToSingleOrMultipleAbsence(blocker: BlockSchedule): BlockSchedule[] {\n if (blocker.isBlockedMultiple) {\n if (currentViewName === \"Week\") {\n const newBlocked = { ...blocker, specialistId: blocker.specialistId !== AllSpecialists ? blocker.specialistId : t(AllSpecialists) };\n return [newBlocked];\n }\n return blocker.blockers;\n }\n if (currentViewName === \"Week\" || blocker.specialistId !== AllSpecialists) {\n const newBlocker = { ...blocker, specialistId: blocker.specialistId !== AllSpecialists ? blocker.specialistId : t(AllSpecialists) };\n return [newBlocker];\n } else {\n const allUsersAbsences = allUsers.map(specialist => ({\n ...blocker,\n specialistId: specialist.key,\n specialist: t(AllSpecialists)\n }));\n return allUsersAbsences;\n }\n }\n\n async function loadData(forceAppointmentsClean: boolean, showLoader: boolean) {\n if (!selectedUsers)\n return;\n if (forceAppointmentsClean) {\n setAppointments([]);\n _setTooltipAppointments([]);\n }\n if (showLoader) dispatch(navbarActions.setShowLoader(true));\n if (accountSettings.isEnterprise === null) return;\n\n const dateFrom = currentViewName === \"Week\" ? startOfWeek(currentDate, { weekStartsOn: 1 }) : startOfDay(currentDate);\n const dateTo = currentViewName === \"Week\" ? endOfWeek(currentDate, { weekStartsOn: 1 }) : endOfDay(currentDate);\n let appointments: Appointment[] =\n accountSettings.isEnterprise\n ? await AppointmentService.getSplitByEstablishments(dateFrom, dateTo, selectedEstablishments, !selectedUsers ? undefined : selectedUsers, !selectedStatuses?.length ? undefined : selectedStatuses)\n : currentViewName === \"Week\"\n ? await AppointmentService.getByAccount(dateFrom, dateTo, !selectedUsers ? undefined : selectedUsers, !selectedStatuses?.length ? undefined : selectedStatuses)\n : await AppointmentService.getSplitByServicesAppointmentsByAccount(dateFrom, dateTo, !selectedUsers ? undefined : selectedUsers, !selectedStatuses?.length ? undefined : selectedStatuses);\n\n const blocked = await loadBlockedSchedule(showLoader, dateFrom, dateTo);\n\n if (showLoader) dispatch(navbarActions.setShowLoader(false));\n\n setAbsences(blocked)\n setAppointments(appointments);\n _setTooltipAppointments(appointments);\n setAppointmentsLoadedForDate(currentDate);\n }\n\n const updateBlockedSchedule = async () => {\n const dateFrom = currentViewName === \"Week\" ? startOfWeek(currentDate, { weekStartsOn: 1 }) : startOfDay(currentDate);\n const dateTo = currentViewName === \"Week\" ? endOfWeek(currentDate, { weekStartsOn: 1 }) : endOfDay(currentDate);\n\n const blocked = await loadBlockedSchedule(false, dateFrom, dateTo);\n\n setAbsences(blocked);\n };\n\n const loadUsers = async () => {\n const usersOnlyWithServices = true;\n const users = accountSettings.isEnterprise\n ? await UserService.getUsersBaseInfoByEstablishments(selectedEstablishments)\n : await UserService.getUsersBaseInfoByAccount(usersOnlyWithServices);\n\n const selectItems = users.map((user) => {\n const select: SelectItem = {\n key: user.id,\n value: `${user.firstName} ${user.lastName}`,\n };\n return select;\n });\n dispatch(setAllUsers(selectItems));\n\n let isSelectedUsersSet = false;\n if (userId) {\n const storageKey = accountSettings.isEnterprise ? LocalStorageKey.SchedulerSelectedUsersEnterprise : LocalStorageKey.SchedulerSelectedUsers\n const json = localStorage.getItem(storageKey + userId);\n if (json) {\n const selectedUsers = JSON.parse(json);\n if (selectedUsers.constructor === Array) {\n if (selectItems && selectedUsers) {\n const userIds = selectItems.map(x => x.key);\n const removeUsers = selectedUsers.filter(x => !userIds.includes(x))\n \n if (removeUsers.length > 0) {\n const newUsers = [...selectedUsers.filter(x => !removeUsers.includes(x))]\n saveSelectedUsers(newUsers)\n }\n else {\n dispatch(setSelectedUsers(selectedUsers));\n }\n \n isSelectedUsersSet = true;\n }\n }\n }\n }\n \n if (!isSelectedUsersSet) {\n dispatch(setSelectedUsers([]));\n }\n };\n\n const loadDayOff = async () => {\n const days = await AppointmentService.getAvailableDays();\n dispatch(setDaysOff([...days]));\n };\n\n const loadWeekDays = async () => {\n const weekdays = accountSettings.isEnterprise \n ? await WeekdayService.getWeekdaysForEstablishments(selectedEstablishments)\n : await WeekdayService.getWeekdays();\n\n dispatch(setWeekDays(weekdays))\n \n let startDayHours = [], endDayHours = [], startWeekHour = 24, endWeekHour = 0;\n for (let i = 0; i < 7; i++) {\n let weekday = weekdays.find(x => x.dayNumber == i);\n if (weekday && weekday.isOpen) {\n if (weekday.opening) {\n const spl = weekday.opening.split(':')\n const hour = parseInt(spl[0]);\n const minutes = parseInt(spl[1]) - 1;\n const hourDecimal = +(hour + (minutes / 60)).toFixed(2);\n const roundedHourDecimal = Math.floor(hourDecimal * 2) / 2;\n startDayHours.push(roundedHourDecimal);\n startWeekHour = Math.min(startWeekHour, roundedHourDecimal);\n } else {\n startDayHours.push(9);\n }\n if (weekday.closing) {\n const spl = weekday.closing.split(':');\n const hour = parseInt(spl[0]);\n const minutes = parseInt(spl[1]) + 1;\n const hourDecimal = +(hour + (minutes / 60)).toFixed(2);\n const roundedHourDecimal = Math.ceil(hourDecimal * 2) / 2;\n endDayHours.push(roundedHourDecimal);\n endWeekHour = Math.max(endWeekHour, roundedHourDecimal);\n } else {\n if (i === WeekdaysEnum.Saturday || i === WeekdaysEnum.Sunday) {\n endDayHours.push(15);\n }\n endDayHours.push(19);\n }\n }\n }\n dispatch(setStartDayHours(startDayHours));\n dispatch(setEndDayHours(endDayHours));\n dispatch(setStartWeekHour(startWeekHour));\n dispatch(setEndWeekHour(endWeekHour));\n };\n\n const saveSelectedUsers = (users: string[]) => {\n dispatch(setSelectedUsers(users));\n if (userId) {\n const storageKey = accountSettings.isEnterprise ? LocalStorageKey.SchedulerSelectedUsersEnterprise : LocalStorageKey.SchedulerSelectedUsers\n localStorage.setItem(storageKey + userId, JSON.stringify(users));\n }\n };\n \n const saveSelectedStatuses = (statuses: AppointmentStatus[]) => {\n dispatch(setSelectedStatuses(statuses));\n if (userId) {\n const storageKey = accountSettings.isEnterprise ? LocalStorageKey.SchedulerSelectedStatusesEnterprise : LocalStorageKey.SchedulerSelectedStatuses\n localStorage.setItem(storageKey + userId, JSON.stringify(statuses));\n }\n };\n \n function handleEditAppointmentModalClick() {\n history.push(`${Url.Appointments.Main}/${appointmentDndModalState.appointmentId}`)\n }\n \n function handleDndModalOnClose() {\n dispatch(setAppointmentDndModalState({ ...appointmentDndModalState, open: false }));\n }\n \n return (\n <>\n {isLoaded && <>\n <div className={classes.container}>\n <DndProvider backend={HTML5Backend}>\n <ScheduleAppointmentActionsMenuContextProvider>\n {(currentViewName === 'Week'\n ? (<WeekScheduler\n stopsInterval={accountSettings.schedulerBlockDurationMinutes}\n appointments={appointments}\n dateReference={currentDate}\n absences={absences}\n />)\n : (<>\n <DayScheduler\n stopsInterval={accountSettings.schedulerBlockDurationMinutes}\n appointments={appointments}\n dateReference={currentDate}\n absences={absences}\n />\n </>))}\n </ScheduleAppointmentActionsMenuContextProvider>\n </DndProvider>\n <MultipleBlockedScheduleModal />\n <BlockScheduleModal refresh={() => loadData(true, true)} />\n <AppointmentDragAndDropScheduleBusyModal\n state={appointmentDndModalState}\n onContinue={handleEditAppointmentModalClick}\n onClose={handleDndModalOnClose}\n />\n </div>\n </>}\n </>\n );\n}\n","export class CreateAppointmentService {\n appointmentId: string | null;\n serviceId: string | null;\n name: string | null;\n duration: number | null;\n estimatedDuration: number;\n userId: string | null;\n user: string | null;\n workAreaId: string | null;\n workArea: string | null;\n price: number;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.appointmentId = x.appointmentId;\n this.serviceId = x.serviceId;\n this.name = x.name;\n this.duration = x.duration;\n this.userId = x.userId;\n this.user = x.user;\n this.estimatedDuration = x.estimatedDuration;\n this.workAreaId = x.workAreaId;\n this.workArea = x.workArea;\n this.price = x.price;\n \n } else {\n this.appointmentId = null;\n this.serviceId = null;\n this.name = null;\n this.duration = null;\n this.userId = null;\n this.user = null;\n this.estimatedDuration = 0;\n this.workAreaId = null;\n this.workArea = null;\n this.price = 0;\n }\n }\n}\n","export class SelectWorkAreaModel {\n id: string | null;\n workArea: string | null;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.workArea = x.workArea;\n } else {\n this.id = null;\n this.workArea = null;\n }\n }\n}\n","export default class Workarea {\n accountId: string | null;\n id: string | null;\n name: string;\n categoryId?: null | string;\n category: string;\n description: string | null;\n hasSimultaneousServices: boolean;\n\n constructor(x?: Workarea) {\n if (typeof x === \"object\" && x !== null && x !== undefined) {\n this.accountId = x.accountId;\n this.id = x.id;\n this.name = x.name || \"\";\n this.categoryId = x.categoryId || null;\n this.category = x.category || \"\";\n this.description = x.description || \"\";\n this.hasSimultaneousServices = x.hasSimultaneousServices\n }\n else {\n this.accountId = null;\n this.id = null;\n this.name = \"\";\n this.categoryId = null;\n this.category = \"\";\n this.description = \"\";\n this.hasSimultaneousServices = true;\n }\n }\n}\n\n//Form Props\nexport interface WorkareasFormProps {\n settingsSelectedEstablishmentId?: string;\n item?: Workarea;\n onChange?: (isValid: boolean, entity: Workarea) => void;\n onModify?: () => void;\n}\n\n//Form Valid\nexport interface WorkareasValid {\n name?: boolean;\n categoryId?: boolean;\n description?: boolean;\n}\n\n","import { SelectWorkAreaModel } from \"./../models/select-work-area-model\";\nimport { ApiClient } from \"./api-client\";\nimport Workarea from \"../models/workarea\";\nimport { Response } from \"./../models/response\";\n\nexport default class WorkareasService {\n private static baseUrl: string = \"/workarea\";\n\n static createWorkarea(w: Workarea): Promise<Workarea> {\n return ApiClient.post(`${this.baseUrl}/createworkarea`, w).then((data) => {\n return new Workarea(data.workarea);\n });\n }\n\n static updateWorkarea(w: Workarea): Promise<Workarea> {\n return ApiClient.put(`${this.baseUrl}/updateworkarea`, w).then((data) => {\n return new Workarea(data.workarea);\n });\n }\n\n static getWorkareas(\n page: number,\n pageSize: number,\n establishmentAccountId?: string,\n order?: string,\n orderBy?: string\n ): Promise<Response> {\n let urlEndpoint = `${this.baseUrl}/getworkareas?page=${page}&pageSize=${pageSize}`;\n\n if (order && orderBy) {\n urlEndpoint += `&order=${order}&orderBy=${orderBy}`;\n }\n if (establishmentAccountId) {\n urlEndpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(urlEndpoint).then((data) => {\n return new Response(data.workareas, data.total);\n });\n }\n\n static deleteWorkarea(w: Workarea): Promise<any> {\n return ApiClient.remove(`${this.baseUrl}/deleteworkarea?id=${w.id}`).then((data) => {\n return {\n entity: new Workarea(data.Workarea),\n forbiddenDelete: data.forbiddenDelete,\n };\n });\n }\n\n static getWorkAreasSelect(): Promise<SelectWorkAreaModel[]> {\n let urlEndpoint = `${this.baseUrl}/getworkareatoappt`;\n\n return ApiClient.get(urlEndpoint).then((data) => {\n return data.workareas.map(\n (workArea: any) =>\n new SelectWorkAreaModel({ id: workArea.id, workArea: workArea.value })\n );\n });\n }\n}\n","import { useState, useEffect } from \"react\";\n\nconst useDebounce = (value: any, delay: number): any => {\n const [debouncedValue, setDebouncedValue] = useState<any>(value);\n\n useEffect(() => {\n const handler = setTimeout(() => {\n setDebouncedValue(value);\n }, delay);\n\n return () => {\n clearTimeout(handler);\n };\n }, [value, delay]);\n\n return debouncedValue;\n};\n\nexport default useDebounce;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n \n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n component: {\n position: \"relative\",\n left: 0\n },\n labelItem: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n marginBottom: \"0.5rem\",\n },\n required: {\n color: \"#6462F3\",\n fontFamily: \"Roboto, sans-serif\"\n },\n optional: {\n fontWeight: \"normal\",\n },\n divDropdown: {\n width: 350,\n display: \"block\",\n },\n inputSelectBtn: {\n width: 300,\n pointerEvents: \"none\",\n paddingRight: \"30px !important\",\n \"& input\": {\n textOverflow: \"ellipsis\"\n }\n },\n iconDropdown: {\n position: \"relative\",\n top: -32,\n right: 12,\n textAlign: \"right\",\n },\n divModalSelect: {\n backgroundColor: \"#FFFFFF\",\n border: \"1px solid #DBDCDD\",\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n width: 350,\n textAlign: \"center\"\n },\n listItemScroll: {\n maxHeight: 300,\n overflowY: \"auto\",\n minHeight: 40\n },\n listItem: {\n height: \"max-content\",\n \"&:first-child\": {\n paddingTop: 0,\n },\n marginBottom: 0,\n },\n itemValue: {\n textAlign: \"left\",\n textOverflow: \"ellipsis\",\n overflow: \"hidden\",\n display: \"inline-block\",\n paddingTop: \"10px\",\n height: \"max-content\"\n },\n button: {\n width: 300,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#786EFF\",\n border: \"1px solid #786EFF\",\n\n },\n divInputEdit: {\n margin: \"auto\",\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n input: {\n marginLeft: \"auto\",\n \"& input\": {\n width: 250,\n }\n },\n iconSearch: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"absolute\",\n top: 20,\n right: 17,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n btnInputNew: {\n height: 32,\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n elementList: {\n height: \"max-content\",\n padding: \"0px 5px 10px 15px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n display: \"flex\",\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n backgroundColor: \"#ebebeb\",\n },\n itemNoSelected: {\n fontWeight: \"normal\",\n color: theme.colors.grey5,\n },\n classRow: {\n cursor: \"pointer\",\n \"& button\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n backgroundColor: \"#f5f5f5\",\n \"& button\": {\n visibility: \"visible\"\n }\n }\n },\n classRowDisabled: {\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n cursor: \"cursor\",\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n height: 40,\n display: \"flex\",\n \"&.Mui-disabled\": {\n opacity: 1,\n },\n },\n divIconsRow: {\n right: 0,\n textAlign: \"center\",\n marginLeft: \"auto\",\n float: \"right\",\n paddingTop: 0\n\n },\n divSearch: {\n marginTop: 15,\n marginBottom: 10\n },\n menuPlacementTop: {\n \"&>div[role=presentation]\": {\n inset: \"auto !important\",\n bottom: \"65px !important\"\n }\n }\n}));\n\nexport default useStyles;\n","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Modal from \"@material-ui/core/Modal\";\nimport { InputLabel } from \"@material-ui/core\";\n\nimport { ArrowDropDownIcon, SearchIcon } from \"../../../assets/icons\";\nimport Input from \"../Input\";\nimport useDebounce from \"../../../hooks/useDebounce\";\n\nimport { SelectSearchItem, SelectSearchProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function SelectSearch(props: SelectSearchProps) {\n \n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n \n const {\n items,\n itemId,\n placeholderSelect,\n placeholderInput,\n label,\n iconSelect,\n disabled,\n disableScrollLock,\n widthSelect,\n widthList,\n isOptional,\n onSelect\n } = props;\n \n const [list, setList] = useState<SelectSearchItem[]>(items);\n const [itemSelected, setItemSelected] = useState<SelectSearchItem>();\n const [search, setSearch] = useState<string>(\"\");\n const [openModal, setOpenModal] = useState<boolean>(false);\n const debouncedSearchValue = useDebounce(search, 400);\n const dropdownRef = useRef<any>(null);\n const menuRef = useRef<any>(null);\n const [menuPlacementTop, setMenuPlacementTop] = useState<boolean>(false);\n \n const handleItemSelected = (i: SelectSearchItem) => {\n if (i.isGroup) return;\n setItemSelected(i);\n onSelect(i);\n setOpenModal(false);\n setSearch(\"\");\n }\n \n useEffect(() => {\n setList([]);\n setItemSelected(undefined);\n if (items.length > 0) {\n setList(items);\n if (itemId) {\n const item = items.find(x => x.key === itemId);\n if (item) setItemSelected(item);\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [items]);\n \n useEffect(() => {\n if (items.length > 0) {\n if (itemId) {\n const item = items.find(x => x.key === itemId);\n if (item) setItemSelected(item);\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [itemId]);\n \n useEffect(() => {\n \n if (debouncedSearchValue) {\n const searchValue = removeAccents(debouncedSearchValue).toLowerCase();\n const newList = items.filter((x) => {\n const itemValue = removeAccents(x.value).toLowerCase();\n return !x.isGroup && itemValue.includes(searchValue);\n });\n setList(newList);\n } else {\n setList(items);\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [debouncedSearchValue]);\n \n useEffect(() => {\n if (openModal) {\n const menuHeight = menuRef.current.getBoundingClientRect().height;\n const bodyRect = document.body.getBoundingClientRect();\n const elemRect = dropdownRef.current.getBoundingClientRect();\n const offset = elemRect.top - bodyRect.top;\n const canOpenTop = offset >= menuHeight;\n let openTop = false;\n if (canOpenTop) {\n const windowHeight = window.innerHeight;\n if (windowHeight - elemRect.bottom < menuHeight) {\n if (elemRect.top >= menuHeight\n || elemRect.top > windowHeight - elemRect.bottom) {\n openTop = true;\n }\n }\n }\n setMenuPlacementTop(openTop);\n } else {\n setMenuPlacementTop(false);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [openModal])\n \n const handleSearch = (event: React.ChangeEvent<{ name: string, value: string }>) => {\n let value = event.target.value;\n setSearch(value);\n }\n \n const handleOpenModal = () => {\n if (disabled) return;\n setSearch(\"\");\n setOpenModal(true);\n }\n \n const handleCloseModal = () => {\n setSearch(\"\");\n setOpenModal(false);\n }\n\n function removeAccents(value: string) {\n return value.normalize('NFD').replace(/[\\u0300-\\u036f]/g, '');\n }\n \n return (<div className={`${classes.component} ${menuPlacementTop ? classes.menuPlacementTop : ''}`}>\n \n <div className={classes.divDropdown} style={{ width: widthSelect || 350 }}>\n \n {label && <>\n <InputLabel className={`${classes.label}`}>\n {label + \" \"}\n {\n (isOptional ?? true) ?\n <span className={classes.optional}>({t(\"Optional\")})</span>\n :\n <span className={classes.required}>*</span>\n }\n </InputLabel>\n </>}\n \n <div onClick={handleOpenModal} style={{ cursor: disabled ? \"cursor\" : \"pointer\" }} ref={dropdownRef}>\n <Input\n id={\"itemSelect\"}\n name={\"itemSelected\"}\n value={itemSelected?.value || \"\"}\n placeholder={placeholderSelect}\n width={widthSelect || 350}\n inputClass={classes.inputSelectBtn}\n style={{ cursor: disabled ? \"cursor\" : \"pointer\" }}\n isValid={() => isOptional ? isOptional : itemSelected?.value !== \"\"}\n />\n </div>\n \n <div className={classes.iconDropdown} onClick={handleOpenModal}\n style={{ cursor: disabled ? \"cursor\" : \"pointer\" }}>\n {iconSelect ??\n <ArrowDropDownIcon style={{ color: \"#6462F3\", transform: openModal ? \"rotate(180deg)\" : \"rotate(0deg)\" }}/>}\n </div>\n \n </div>\n \n <Modal\n open={openModal}\n onClose={handleCloseModal}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n disableScrollLock={disableScrollLock}\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n onBackdropClick={handleCloseModal}\n disablePortal={true}\n style={{position: \"absolute\", top: 65}}>\n \n <div className={classes.divModalSelect} style={{ width: widthList || 350 }} ref={menuRef}>\n \n <div className={classes.divSearch}>\n \n <div className={classes.btnInputNew}>\n <div>\n <Input\n id={\"searchInput\"}\n name={\"searchInput\"}\n value={search}\n width={\"95%\"}\n maxLength={50}\n placeholder={placeholderInput}\n inputClass={classes.input}\n autoFocus={true}\n onChange={handleSearch}\n />\n </div>\n <button className={classes.iconSearch}>\n <SearchIcon style={{ color: \"#DDD\", height: 15, width: 15 }}/>\n </button>\n </div>\n </div>\n \n <div className={classes.listItemScroll}>\n {items && list.map((i: SelectSearchItem, index) => {\n return <span key={`option-${i.key}-${index}`}>\n <div key={i.key} className={classes.listItem}>\n <div\n className={`${classes.elementList} ${itemId === i.key ? classes.itemSelected : classes.itemNoSelected} ${i.isGroup ? classes.classRowDisabled : classes.classRow}`}>\n <div className={classes.itemValue} onClick={() => handleItemSelected(i)}>\n {i.value}\n </div>\n </div>\n </div>\n </span>\n })}\n </div>\n \n </div>\n </Modal>\n </div>);\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n column: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n width: \"100%\",\n },\n selectHrs: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectHr: {\n \"& div:after\": {\n content: \"'hr'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectMin: {\n \"& div:after\": {\n content: \"'min'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectStyle: {\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 320,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n \"&:disabled\": {\n color: \"#5C6477\",\n },\n },\n },\n form: {\n display: \"flex\",\n flexWrap: \"wrap\",\n justifyContent: \"space-between\",\n width: \"100%\",\n },\n formItem: {\n },\n required: {\n color: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n controlLabel: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n marginBottom: 7\n },\n dot: {\n ...theme.typography.buttons,\n color: theme.colors.clearMain\n },\n itemRootClass: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n fontSize: 12,\n alignItems: \"center\"\n },\n input: {\n width: \"320px !important\",\n margin: \"0 0 22px\"\n }\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\n\nimport SelectWithLabel, { SelectItem } from \"./../../common/SelectWithLabel\";\nimport ServicesService from \"./../../../api/settings-services-service\";\nimport { UserService } from \"../../../api/user-service\";\nimport WorkareasService from \"../../../api/settings-workareas-service\";\nimport { UserModel } from \"../../../models/user-model\";\nimport { SelectWorkAreaModel } from \"../../../models/select-work-area-model\";\nimport { SelectGroupServiceModel } from \"../../../models/select-group-service-model\";\nimport { CreateAppointmentService } from \"../../../models/create-appointment-service\";\nimport SelectSearch from \"../../common/SelectSearch\";\n\nimport { AppointmentServiceProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { CurrencyRegex } from \"../../../constants/validator\";\nimport Typography from \"@material-ui/core/Typography\";\nimport InputCurrency from \"../../common/InputCurrency\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport { ArrowDropDownIcon } from \"../../../assets/icons\";\nimport Input from \"../../common/Input\";\nimport InputWithLabel from \"../../common/InputWithLabel\";\n\nexport default function AppointmentService(props: AppointmentServiceProps) {\n\n const { appointmentService, desiredUserId, onChange, disabled } = props;\n\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n const [services, setServices] = useState<SelectItem[]>([]);\n const [servicesArr, setServicesArr] = useState<SelectGroupServiceModel[]>([]);\n const [usersArr, setUsersArr] = useState<UserModel[]>([]);\n const [users, setUsers] = useState<SelectItem[]>([]);\n const [workAreasArr, setWorkAreasArr] = useState<SelectWorkAreaModel[]>([]);\n const [workAreas, setWorkAreas] = useState<SelectItem[]>([]);\n const [estimatedDuration, setEstimatedDuration] = useState<moment.Moment>(moment().utcOffset(0).set({ hour: 0, minute: 0, second: 0, millisecond: 0 }));\n const [timePickerIsOpen, setTimePickerIsOpen] = useState<boolean>(false);\n const format = \"HH:mm\";\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const currencyTemplate: string = accountSettings.currencyTemplate;\n const userInfo = useAppSelector(state => state.userInfo);\n\n function setAppointmentService(appointmentService: CreateAppointmentService) {\n onChange(appointmentService)\n }\n\n useEffect(() => {\n async function fetchData() {\n await loadServices();\n await loadWorkAreas();\n }\n\n fetchData();\n }, []);\n\n useEffect(() => {\n setEstimatedDuration(moment().utcOffset(0).set({ hour: 0, minute: appointmentService?.estimatedDuration ?? appointmentService?.duration ?? 0, second: 0, millisecond: 0 }))\n }, [appointmentService?.serviceId])\n\n useEffect(() => {\n async function fetchData() {\n await loadUsers();\n }\n\n if (appointmentService.serviceId) {\n fetchData();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointmentService.serviceId]);\n\n useEffect(() => {\n if (!userInfo.hasAccessToScheduleAllSpecialists){\n const user = usersArr.find((svc) => svc.authenticationId === userInfo.userId);\n if (user) {\n setUserByValue(user);\n }\n } else if (desiredUserId) {\n const desiredUser = usersArr.find((svc) => svc.id === desiredUserId);\n if (desiredUser) {\n setUserByValue(desiredUser);\n }\n }\n }, [usersArr]);\n\n const loadServices = async () => {\n const services = await ServicesService.getServicesSelect();\n setServicesArr(services);\n\n const arrServices: SelectItem[] = [];\n let x = 0;\n for (let category of services) {\n arrServices.push({\n key: x,\n value: `${category.category} (${category.services?.length})`,\n isGroup: true,\n });\n if (category.services) {\n\n arrServices.push(\n ...category.services.map((service) => ({\n key: service.id,\n value: `${service.name} (${service.duration} min)`,\n }))\n );\n }\n x++;\n }\n\n setServices(arrServices);\n };\n\n const getTimePickerDurationPostfixClass = () => {\n const postfix = estimatedDuration.hours() > 1 ? \"hrs\" : (estimatedDuration.hours() === 1 ? \"hr\" : \"min\");\n switch (postfix) {\n case \"hrs\":\n return classes.selectHrs;\n case \"hr\":\n return classes.selectHr;\n case \"min\":\n return classes.selectMin;\n }\n }\n\n const handleOpenTimepicker = (isOpen: boolean) => {\n setTimePickerIsOpen(isOpen);\n };\n\n const loadUsers = async () => {\n let users = await UserService.getUsersByServiceId(appointmentService.serviceId!);\n if (!users.some(u => u.id == appointmentService.userId)) {\n setUserByValue(undefined);\n }\n setUsersArr(users);\n setUsers(\n users.map((user) => {\n return { key: user.id, value: `${user.firstName} ${user.lastName}` };\n })\n );\n };\n\n const loadWorkAreas = async () => {\n const workAreas = await WorkareasService.getWorkAreasSelect();\n setWorkAreasArr(workAreas);\n setWorkAreas(\n workAreas.map((workArea) => {\n return { key: workArea.id, value: workArea.workArea };\n })\n );\n };\n\n const handleDurationTimeChange = (time: moment.Moment) => {\n\n const minutes = (time.hour() * 60) + time.minute();\n\n setEstimatedDuration(time);\n\n setAppointmentService(\n new CreateAppointmentService({\n ...appointmentService,\n estimatedDuration: minutes\n })\n );\n\n setTimePickerIsOpen(false);\n };\n\n const handleServiceChange = (event: any) => {\n const service = event.key;//event.target.value;\n const category = servicesArr.find((cat) => cat.services?.findIndex((svc) => svc.id === service) !== -1);\n if (category && category.services) {\n const selectedService = category.services.find((svc) => svc.id === service);\n if (selectedService && selectedService.workAreaId) {\n setAppointmentService(\n new CreateAppointmentService({\n ...appointmentService,\n serviceId: service,\n name: selectedService.name || \"\",\n duration: selectedService.duration,\n estimatedDuration: selectedService.duration,\n workAreaId: selectedService.workAreaId,\n workArea: selectedService.workArea || \"\",\n price: selectedService.price,\n userId: null,\n user: null,\n })\n );\n } else {\n setAppointmentService(\n new CreateAppointmentService({\n ...appointmentService,\n serviceId: service,\n name: selectedService?.name || \"\",\n duration: selectedService?.duration,\n estimatedDuration: selectedService?.duration,\n price: selectedService?.price,\n userId: null,\n user: null,\n workAreaId: null,\n workArea: \"\",\n })\n );\n }\n }\n };\n\n const handleUserChange = (event: any) => {\n const user = usersArr.find((svc) => svc.id === event.key);\n setUserByValue(user);\n };\n\n const setUserByValue = (user: UserModel | undefined) => {\n setAppointmentService(\n new CreateAppointmentService({\n ...appointmentService,\n userId: user?.id,\n user: `${user?.firstName} ${user?.lastName}`,\n })\n );\n };\n\n const handleWorkAreaChange = (event: any) => {\n const workArea = workAreasArr.find((svc) => svc.id === event.target.value);\n setAppointmentService(\n new CreateAppointmentService({\n ...appointmentService,\n workAreaId: event.target.value,\n workArea: workArea?.workArea || \"\",\n })\n );\n };\n\n const handlePriceChange = (price: number) => {\n setAppointmentService(\n new CreateAppointmentService({\n ...appointmentService,\n price: price\n })\n );\n };\n\n return (\n <>\n <div className={classes.column}>\n <div className={classes.form}>\n <div className={classes.formItem}>\n <SelectSearch\n label={t(\"Service\")}\n items={services}\n itemId={appointmentService.serviceId}\n placeholderSelect={t(\"Select a service\")}\n placeholderInput={t(\"Search one of our services\")}\n widthSelect={320}\n widthList={320}\n isOptional={false}\n onSelect={handleServiceChange}\n disabled={disabled}\n disableScrollLock={true}\n />\n </div>\n {userInfo.showPrices && (\n <div className={classes.formItem}>\n <Typography className={classes.controlLabel}>\n {t(\"Price\")} <span className={classes.dot}>*</span>\n </Typography>\n <InputCurrency\n value={appointmentService.price}\n setValue={handlePriceChange}\n valueTemplate={currencyTemplate}\n disabled={disabled || !appointmentService.serviceId}\n isZeroAllowed={true}\n isValid={() =>\n disabled ||\n !appointmentService.serviceId ||\n (appointmentService.price > 0 &&\n CurrencyRegex.test(String(appointmentService.price)))\n }\n width={320}\n />\n </div>\n )}\n <div className={classes.formItem}>\n <div style={{ position: \"relative\" }}>\n <Typography className={classes.controlLabel}>\n {t(\"Estimated duration\")} <span className={classes.dot}>*</span>\n </Typography>\n <TimePicker\n onOk={(time) => {\n handleDurationTimeChange(time);\n }}\n className={`${\n classes.selectStyle\n } ${getTimePickerDurationPostfixClass()}`}\n placeholder=\"HH:mm\"\n inputReadOnly={true}\n showNow={false}\n value={estimatedDuration}\n disabled={disabled || !appointmentService.serviceId}\n disabledHours={() => [21, 22, 23]}\n onOpenChange={(e) => handleOpenTimepicker(e)}\n format={format}\n />\n <ArrowDropDownIcon\n style={{\n top: \"60%\",\n right: 15,\n pointerEvents: \"none\",\n color: \"#5C6477\",\n position: \"absolute\",\n transform: timePickerIsOpen ? \"rotate(180deg)\" : \"rotate(0deg)\",\n }}\n />\n </div>\n </div>\n {userInfo.hasAccessToScheduleAllSpecialists && (\n <div className={classes.formItem}>\n <SelectSearch\n label={t(\"appointment_step_one_Specialist\")}\n items={users}\n itemId={appointmentService.userId}\n placeholderSelect={t(\"Select a specialist\")}\n placeholderInput={t(\"Search specialist\")}\n widthSelect={320}\n widthList={320}\n isOptional={false}\n onSelect={handleUserChange}\n disabled={disabled || !appointmentService.serviceId}\n disableScrollLock={true}\n />\n </div>\n )}\n {!userInfo.hasAccessToScheduleAllSpecialists && (\n <div className={classes.formItem}>\n <InputWithLabel\n label={t(\"appointment_step_one_Specialist\")}\n value={userInfo.fullName}\n inputClass={classes.input}\n inputDisabled={true}\n inputReadOnly={true}\n />\n </div>\n )}\n <div className={classes.formItem}>\n <SelectWithLabel\n label={() => (\n <>\n {t(\"Work area\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n itemRootClass={classes.itemRootClass}\n placeholder={t(\"Select a work area\")}\n width=\"320px\"\n items={workAreas}\n value={appointmentService.workAreaId}\n onChange={handleWorkAreaChange}\n disabled={disabled || !appointmentService.serviceId}\n disableScrollLock={true}\n />\n </div>\n </div>\n </div>\n </>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n marginTop: 24,\n },\n required: {\n color: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n form: {\n display: \"flex\",\n justifyContent: \"space-between\",\n width: \"100%\",\n },\n firstElement: {\n marginLeft: 26,\n },\n element: {\n marginTop: 25,\n },\n row: {\n display: \"flex\",\n alignItems: \"center\",\n width: \"100%\",\n },\n deleteButton: {\n marginRight: 10,\n marginTop: 0,\n \"&:hover\": {\n cursor: \"pointer\",\n },\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n minHeight: 288,\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n margin: \"24px 0px 8px 0px\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteContact: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n accordionSummary: {\n backgroundColor: \"#f6f6f6\",\n width: \"100%\"\n },\n accordionTitle: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey5,\n position: \"relative\",\n top: 5,\n left: 10\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { DeleteIcon, CrossIcon, TrashIcon, ArrowDownIcon, ListPlusIcon } from \"../../../assets/icons\";\n\nimport { Accordion, AccordionDetails, AccordionSummary } from \"@material-ui/core\";\nimport { CreateAppointmentService } from \"../../../models/create-appointment-service\";\nimport AppointmentService from \"./../AppointmentService\";\n\nimport { AppointmentServicesProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function AppointmentServices(props: AppointmentServicesProps) {\n \n const { services, desiredUserId, onDelete, onChange, disabled } = props;\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n const [openModal, setOpenModal] = useState<boolean>(false);\n const [service, setService] = useState<CreateAppointmentService>();\n const [indexService, setIndexService] = useState<number>(0);\n const [expandedAccordionIndex, setExpandedAccordionIndex] = useState<number>(0);\n\n const handleDeleteService = (e: any, index: number) => {\n e.preventDefault();\n e.stopPropagation();\n const service = services.find((service, idx) => idx === index);\n setService(service);\n setIndexService(index);\n setOpenModal(true);\n };\n\n const removeService = () => {\n onDelete(indexService);\n setOpenModal(false);\n };\n\n const handleOnChange =\n (index: number) => (appointmentService: CreateAppointmentService) => {\n setExpandedAccordionIndex(index);\n onChange(index, appointmentService);\n };\n \n function handleAccordionChange(index: number) {\n const newIndex = expandedAccordionIndex === index ? -1 : index;\n setExpandedAccordionIndex(newIndex);\n }\n\n return (\n <div className={classes.root}>\n {services.map((service, index) => (\n <Accordion\n style={{width: \"97%\", marginLeft: \"auto\"}}\n expanded={expandedAccordionIndex === index}\n onChange={() => handleAccordionChange(index)}\n >\n <AccordionSummary\n className={classes.accordionSummary}\n expandIcon={<ArrowDownIcon style={{height: 15, width: 15, color: \"#5c6477\"}} />}\n aria-controls=\"panel1a-content\"\n id=\"panel1a-header\"\n >\n <div style={{width: 25}}>\n {\n index > 0 ?\n <span onClick={(e) => handleDeleteService(e, index)}>\n <DeleteIcon />\n </span>\n :\n <span>\n <ListPlusIcon />\n </span>\n }\n </div>\n <Typography className={classes.accordionTitle}>\n {`${t(\"Service\")} ${index+1}` }\n </Typography>\n </AccordionSummary>\n <AccordionDetails\n style={{display: \"block\", padding: 28}}\n >\n <AppointmentService\n appointmentService={service}\n desiredUserId={desiredUserId}\n onChange={handleOnChange(index)}\n disabled={disabled}\n />\n </AccordionDetails>\n </Accordion>\n ))}\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={() => {\n setOpenModal(false);\n }}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <span\n className={classes.closeButton}\n onClick={() => {\n setOpenModal(false);\n }}\n >\n <CrossIcon />\n </span>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div className={classes.modalCenter}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Are you sure to delete this service?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {service?.name || \"--\"}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={() => {\n setOpenModal(false);\n }}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.deleteContact}`}\n onClick={removeService}\n >\n {t(\"Delete\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n marginLeft: 26,\n },\n stepTitle: {\n ...theme.typography.header2,\n color: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n servicesHeader: {\n display: \"flex\",\n marginTop: 24,\n },\n servicesTitle: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n flagIcon: {\n color: theme.colors.grey5,\n },\n addButton: {\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n width: 137,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n border: `1px solid ${theme.colors.clearMain}`,\n justifyContent: \"space-around\",\n marginTop: 23,\n marginLeft: 26,\n \"&.Mui-disabled\": {\n color: theme.colors.clearMain,\n },\n },\n separator: {\n height: 0,\n borderTop: `1px solid ${theme.colors.grey2}`,\n margin: \"24px 0px 24px 26px\",\n },\n inputTextareaClass: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n fontWeight: \"normal\",\n opacity: 0.8,\n },\n },\n label: {\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: theme.colors.grey4,\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n notes: {\n marginLeft: 26,\n },\n disabled: {\n opacity: 0.5,\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { CreateAppointmentModel } from \"../../../models/create-appointment-model\";\nimport { CreateAppointmentService } from \"../../../models/create-appointment-service\";\nimport { FlagIcon, PlusIcon } from \"../../../assets/icons\";\nimport AppointmentServices from \"./../AppointmentServices\";\nimport TextareaWithLabel from \"./../../common/TextareaWithLabel\";\n\nimport { AppointmentStepOneProps } from \"./props\";\nimport useStyles from \"./css\";\nimport {useAppDispatch, useAppSelector} from \"../../../redux/hooks\";\nimport {blockedScheduleActions} from \"../../../redux/blocked-schedule-slice\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\n\nexport default function AppointmentStepOne(props: AppointmentStepOneProps) {\n \n const { appointment, onChange } = props;\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const dispatch = useAppDispatch();\n const [desiredUserId] = useState(useAppSelector(state => state.blockedSchedule.userId));\n \n function setAppointment(appointment: CreateAppointmentModel) {\n const isValid = appointment.services.every(service => service.serviceId && service.userId && service.price > 0);\n onChange(appointment, isValid)\n }\n \n function setServices(services: CreateAppointmentService[]) {\n setAppointment(new CreateAppointmentModel({ ...appointment, services }))\n }\n\n useEffect(() => {\n if (desiredUserId) {\n dispatch(blockedScheduleActions.setUserId(null));\n }\n }, []);\n\n useEffect(() => {\n if (!appointment){\n setAppointment(new CreateAppointmentModel());\n }\n if (appointment.services.length === 0) {\n setServices([...appointment.services, new CreateAppointmentService()]);\n }\n }, [appointment])\n\n const handleAddService = () => {\n setServices([...appointment?.services ?? [], new CreateAppointmentService()]);\n };\n\n const handleDeleteService = (index: number) => {\n const arrServices = appointment!.services!.filter((service, idx) => idx !== index);\n setServices(arrServices);\n };\n\n const handleOnChangeService = (\n index: number,\n service: CreateAppointmentService\n ) => {\n let arrServices = [...appointment!.services!];\n arrServices[index] = service;\n setServices(arrServices)\n };\n\n return (\n <div className={!appointment?.customerId ? classes.disabled : \"\"}>\n <div className={classes.header}>\n <Typography className={classes.stepTitle}>{t(\"STEP 1\")}</Typography>\n <div className={classes.servicesHeader}>\n <FlagIcon\n className={classes.flagIcon}\n viewBox=\"0 0 12 16\"\n style={{ width: 12, height: 16, marginLeft: 7 }}\n />\n <div style={{ marginLeft: 14 }}>\n <Typography className={classes.servicesTitle}>\n {t(\"Services\")}\n </Typography>\n </div>\n </div>\n </div>\n <AppointmentServices\n services={appointment!.services}\n desiredUserId={desiredUserId}\n onDelete={handleDeleteService}\n onChange={handleOnChangeService}\n disabled={!appointment?.customerId}\n />\n <ButtonWithSpinner\n width={137}\n margin={\"30px 26px\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n fill={ButtonPropsFill.Outlined}\n innerText={t(\"Add another\")}\n innerIcon={<PlusIcon />}\n onClick={handleAddService}\n />\n {appointment?.services && appointment?.services.length > 1 ? (\n <div className={classes.separator} style={{ width: 480, marginTop: 0 }}></div>\n ) : null}\n <div className={classes.notes}>\n <TextareaWithLabel\n name=\"notes\"\n width=\"100%\"\n inputClass={classes.inputTextareaClass}\n label={() => (\n <>\n <Typography className={classes.label}>{t(\"Comments\")}</Typography>\n </>\n )}\n labelClass={classes.label}\n placeholder={t(\"Enter here any appointment comments.\")}\n maxLength={180}\n inputDisabled={!appointment?.customerId}\n showCounter={true}\n onChange={(event) => {\n setAppointment(\n new CreateAppointmentModel({\n ...appointment,\n notes: event.target.value,\n })\n );\n }}\n value={appointment?.notes || \"\"}\n />\n </div>\n <div className={classes.separator} style={{ width: 704 }}></div>\n </div>\n );\n};","function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\n\nvar _ref2 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.1,\n d: \"M112.418 7.81674C70.4346 -9.49906 20.0803 20.2705 8.42536 44.8258C-19.5611 103.789 29.3463 131 50.8615 121.047C59.8434 116.892 67.1802 109.796 74.271 102.892C84.9178 92.6148 99.0241 86.6922 113.817 86.2887C125.209 86.0269 136.547 89.0838 147.907 88.1862C159.266 87.2886 169.301 71.6216 168.993 60.2305C168.523 42.8442 157.438 26.3844 112.418 7.81674Z\",\n fill: \"#9FA9E6\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M141.326 6.27734H27.6745C23.9058 6.27734 20.8506 9.33253 20.8506 13.1013V102.538C20.8506 106.307 23.9058 109.362 27.6745 109.362H141.326C145.095 109.362 148.15 106.307 148.15 102.538V13.1013C148.15 9.33253 145.095 6.27734 141.326 6.27734Z\",\n fill: \"white\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M141.326 109.576H27.6742C25.8082 109.574 24.0193 108.831 22.6999 107.512C21.3805 106.192 20.6383 104.404 20.6362 102.538V13.1007C20.6383 11.2347 21.3805 9.44576 22.6999 8.1263C24.0193 6.80684 25.8082 6.06463 27.6742 6.0625H141.326C143.192 6.06463 144.981 6.80684 146.3 8.1263C147.619 9.44576 148.362 11.2347 148.364 13.1007V102.538C148.362 104.404 147.619 106.192 146.3 107.512C144.981 108.831 143.192 109.574 141.326 109.576V109.576ZM27.6742 6.49073C25.9217 6.49274 24.2417 7.1898 23.0025 8.42897C21.7634 9.66815 21.0664 11.3482 21.0645 13.1007V102.538C21.0664 104.29 21.7634 105.97 23.0025 107.209C24.2417 108.448 25.9217 109.145 27.6742 109.148H141.326C143.078 109.145 144.758 108.448 145.997 107.209C147.236 105.97 147.933 104.29 147.935 102.538V13.1007C147.933 11.3482 147.236 9.66815 145.997 8.42897C144.758 7.1898 143.078 6.49274 141.326 6.49073H27.6742Z\",\n fill: \"#292A2E\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M148.15 13.0988V26.0387H20.8511V13.0988C20.8508 12.2024 21.0272 11.3148 21.3701 10.4867C21.7129 9.65854 22.2156 8.90606 22.8494 8.27223C23.4831 7.6384 24.2356 7.13565 25.0637 6.79269C25.8918 6.44973 26.7794 6.27329 27.6757 6.27344H141.326C143.136 6.27374 144.872 6.99299 146.152 8.27298C147.431 9.55296 148.15 11.2888 148.15 13.0988V13.0988Z\",\n fill: \"#6462F3\"\n});\n\nvar _ref6 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M148.38 26.2679H20.6213V13.0981C20.6231 11.2277 21.3669 9.43435 22.6894 8.11166C24.0119 6.78896 25.8052 6.04498 27.6756 6.04297H141.326C143.197 6.04528 144.989 6.78939 146.312 8.11205C147.634 9.4347 148.378 11.2279 148.38 13.0981V26.2679ZM21.0815 25.8082H147.92V13.0981C147.918 11.3498 147.223 9.67351 145.987 8.43706C144.751 7.2006 143.075 6.50495 141.326 6.50269H27.6756C25.9271 6.50464 24.2507 7.20017 23.0144 8.43667C21.7781 9.67316 21.0828 11.3496 21.0811 13.0981L21.0815 25.8082Z\",\n fill: \"#367CFF\"\n});\n\nvar _ref7 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M53.916 12.9787V3.42625C53.916 1.66774 52.4905 0.242188 50.732 0.242188C48.9734 0.242188 47.5479 1.66774 47.5479 3.42625V12.9787C47.5479 14.7372 48.9734 16.1627 50.732 16.1627C52.4905 16.1627 53.916 14.7372 53.916 12.9787Z\",\n fill: \"white\"\n});\n\nvar _ref8 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M50.731 16.3767C49.8302 16.3755 48.9666 16.017 48.3297 15.38C47.6928 14.7429 47.3346 13.8792 47.3336 12.9784V3.42624C47.3299 2.97763 47.4151 2.53274 47.5842 2.11721C47.7533 1.70169 48.0031 1.32376 48.319 1.00524C48.6349 0.686713 49.0107 0.433892 49.4249 0.26136C49.839 0.0888281 50.2832 0 50.7318 0C51.1804 0 51.6246 0.0888281 52.0387 0.26136C52.4528 0.433892 52.8287 0.686713 53.1446 1.00524C53.4605 1.32376 53.7102 1.70169 53.8794 2.11721C54.0485 2.53274 54.1337 2.97763 54.13 3.42624V12.9784C54.129 13.8795 53.7706 14.7434 53.1333 15.3805C52.4961 16.0177 51.6321 16.3759 50.731 16.3767V16.3767ZM50.731 0.456183C49.9435 0.457035 49.1886 0.770224 48.6318 1.32703C48.075 1.88384 47.7618 2.63879 47.7609 3.42624V12.9784C47.7575 13.3706 47.8317 13.7597 47.9795 14.123C48.1272 14.4864 48.3454 14.8169 48.6215 15.0954C48.8976 15.374 49.2262 15.5951 49.5882 15.746C49.9503 15.8969 50.3386 15.9746 50.7309 15.9746C51.1231 15.9746 51.5114 15.8969 51.8735 15.746C52.2355 15.5951 52.5641 15.374 52.8402 15.0954C53.1164 14.8169 53.3346 14.4864 53.4823 14.123C53.63 13.7597 53.7043 13.3706 53.7008 12.9784V3.42624C53.7 2.63883 53.3868 1.88392 52.83 1.32711C52.2733 0.770312 51.5184 0.457096 50.731 0.456183V0.456183Z\",\n fill: \"#262626\"\n});\n\nvar _ref9 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M121.453 12.9748V3.42235C121.453 1.66384 120.027 0.238281 118.269 0.238281C116.51 0.238281 115.085 1.66384 115.085 3.42235V12.9748C115.085 14.7333 116.51 16.1588 118.269 16.1588C120.027 16.1588 121.453 14.7333 121.453 12.9748Z\",\n fill: \"white\"\n});\n\nvar _ref10 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M118.269 16.3722C117.368 16.3712 116.504 16.0129 115.867 15.3758C115.23 14.7387 114.871 13.8749 114.87 12.9739V3.42173C114.87 2.52045 115.228 1.65608 115.866 1.01877C116.503 0.381471 117.367 0.0234375 118.269 0.0234375C119.17 0.0234375 120.034 0.381471 120.672 1.01877C121.309 1.65608 121.667 2.52045 121.667 3.42173V12.9739C121.666 13.8749 121.308 14.7387 120.671 15.3758C120.033 16.0129 119.17 16.3712 118.269 16.3722V16.3722ZM118.269 0.451672C117.481 0.452767 116.727 0.766064 116.17 1.32285C115.613 1.87963 115.3 2.63444 115.3 3.42173V12.9739C115.3 13.7616 115.612 14.5171 116.169 15.0741C116.726 15.6311 117.482 15.944 118.27 15.944C119.057 15.944 119.813 15.6311 120.37 15.0741C120.927 14.5171 121.24 13.7616 121.24 12.9739V3.42173C121.239 2.63412 120.925 1.87903 120.368 1.3222C119.811 0.765362 119.056 0.45228 118.269 0.451672V0.451672Z\",\n fill: \"#262626\"\n});\n\nvar _ref11 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M69.1345 67.9304C70.8319 67.9304 72.2078 67.2062 72.2078 66.3129C72.2078 65.4195 70.8319 64.6953 69.1345 64.6953C67.4372 64.6953 66.0613 65.4195 66.0613 66.3129C66.0613 67.2062 67.4372 67.9304 69.1345 67.9304Z\",\n fill: \"white\"\n});\n\nvar _ref12 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M99.8657 67.9304C101.563 67.9304 102.939 67.2062 102.939 66.3129C102.939 65.4195 101.563 64.6953 99.8657 64.6953C98.1684 64.6953 96.7925 65.4195 96.7925 66.3129C96.7925 67.2062 98.1684 67.9304 99.8657 67.9304Z\",\n fill: \"white\"\n});\n\nvar _ref13 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M45.3975 35.1992H27.0708V53.2124H45.3975V35.1992Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref14 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M45.3975 58.2188H27.0708V76.232H45.3975V58.2188Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref15 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M45.3975 81.2383H27.0708V99.2515H45.3975V81.2383Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref16 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M69.5291 35.1992H51.2024V53.2124H69.5291V35.1992Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref17 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M69.5291 58.2188H51.2024V76.232H69.5291V58.2188Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref18 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M93.4176 35.1992H75.0908V53.2124H93.4176V35.1992Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref19 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M93.4176 58.2188H75.0908V76.232H93.4176V58.2188Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref20 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M117.982 35.1992H99.6553V53.2124H117.982V35.1992Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref21 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M117.982 58.2188H99.6553V76.232H117.982V58.2188Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref22 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M69.5291 81.2383H51.2024V99.2515H69.5291V81.2383Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref23 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M93.4176 81.2383H75.0908V99.2515H93.4176V81.2383Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref24 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M141.929 35.1992H123.603V53.2124H141.929V35.1992Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref25 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.3,\n d: \"M141.929 58.2188H123.603V76.232H141.929V58.2188Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref26 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.5,\n d: \"M65.3025 62.4964C65.0796 62.2734 64.7772 62.1482 64.462 62.1482C64.1467 62.1482 63.8444 62.2734 63.6214 62.4964L60.3999 65.7179L57.1784 62.4964C56.9554 62.2734 56.6531 62.1482 56.3378 62.1482C56.0226 62.1482 55.7202 62.2734 55.4973 62.4964C55.2744 62.7193 55.1491 63.0216 55.1491 63.3369C55.1491 63.6522 55.2744 63.9545 55.4973 64.1774L58.7188 67.399L55.4973 70.6205C55.2744 70.8434 55.1491 71.1458 55.1491 71.461C55.1491 71.7763 55.2744 72.0786 55.4973 72.3016C55.7202 72.5245 56.0226 72.6497 56.3378 72.6497C56.6531 72.6497 56.9554 72.5245 57.1784 72.3016L60.3968 69.0831L63.6184 72.3046C63.8413 72.5276 64.1437 72.6528 64.4589 72.6528C64.7742 72.6528 65.0765 72.5276 65.2995 72.3046C65.5224 72.0817 65.6476 71.7794 65.6476 71.4641C65.6476 71.1488 65.5224 70.8465 65.2994 70.6236L62.081 67.4051L65.3056 64.1805C65.4162 64.0698 65.5039 63.9385 65.5637 63.7938C65.6234 63.6492 65.654 63.4943 65.6537 63.3378C65.6534 63.1813 65.6223 63.0265 65.562 62.8821C65.5017 62.7377 65.4135 62.6066 65.3025 62.4964Z\",\n fill: \"#F15857\"\n});\n\nvar _ref27 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.5,\n d: \"M89.3025 62.6956C89.0796 62.4727 88.7772 62.3474 88.462 62.3474C88.1467 62.3474 87.8444 62.4727 87.6214 62.6956L84.3999 65.9171L81.1784 62.6956C80.9554 62.4727 80.6531 62.3474 80.3378 62.3474C80.0226 62.3474 79.7202 62.4727 79.4973 62.6956C79.2744 62.9185 79.1491 63.2208 79.1491 63.5361C79.1491 63.8514 79.2744 64.1537 79.4973 64.3766L82.7188 67.5982L79.4973 70.8197C79.2744 71.0426 79.1491 71.345 79.1491 71.6603C79.1491 71.9755 79.2744 72.2779 79.4973 72.5008C79.7202 72.7237 80.0226 72.8489 80.3378 72.8489C80.6531 72.8489 80.9554 72.7237 81.1784 72.5008L84.3968 69.2823L87.6184 72.5038C87.8413 72.7268 88.1437 72.852 88.4589 72.852C88.7742 72.852 89.0765 72.7268 89.2995 72.5038C89.5224 72.2809 89.6476 71.9786 89.6476 71.6633C89.6476 71.3481 89.5224 71.0457 89.2994 70.8228L86.081 67.6043L89.3056 64.3797C89.4162 64.2691 89.5039 64.1377 89.5637 63.9931C89.6234 63.8485 89.654 63.6935 89.6537 63.537C89.6534 63.3805 89.6223 63.2257 89.562 63.0813C89.5017 62.9369 89.4135 62.8058 89.3025 62.6956Z\",\n fill: \"#F15857\"\n});\n\nvar _ref28 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.5,\n d: \"M114.303 39.2971C114.08 39.0742 113.777 38.949 113.462 38.949C113.147 38.949 112.844 39.0742 112.621 39.2971L109.4 42.5187L106.178 39.2971C105.955 39.0742 105.653 38.949 105.338 38.949C105.023 38.949 104.72 39.0742 104.497 39.2971C104.274 39.5201 104.149 39.8224 104.149 40.1377C104.149 40.4529 104.274 40.7553 104.497 40.9782L107.719 44.1997L104.497 47.4213C104.274 47.6442 104.149 47.9466 104.149 48.2618C104.149 48.5771 104.274 48.8794 104.497 49.1024C104.72 49.3253 105.023 49.4505 105.338 49.4505C105.653 49.4505 105.955 49.3253 106.178 49.1024L109.397 45.8839L112.618 49.1054C112.841 49.3283 113.144 49.4536 113.459 49.4536C113.774 49.4536 114.077 49.3283 114.299 49.1054C114.522 48.8825 114.648 48.5801 114.648 48.2649C114.648 47.9496 114.522 47.6473 114.299 47.4243L111.081 44.2059L114.306 40.9813C114.416 40.8706 114.504 40.7392 114.564 40.5946C114.623 40.45 114.654 40.295 114.654 40.1386C114.653 39.9821 114.622 39.8272 114.562 39.6828C114.502 39.5385 114.414 39.4074 114.303 39.2971Z\",\n fill: \"#F15857\"\n});\n\nvar SvgCalendarNotime = function SvgCalendarNotime(_ref) {\n var svgRef = _ref.svgRef,\n title = _ref.title,\n props = _objectWithoutProperties(_ref, [\"svgRef\", \"title\"]);\n\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n width: 169,\n height: 124,\n viewBox: \"0 0 169 124\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5, _ref6, _ref7, _ref8, _ref9, _ref10, _ref11, _ref12, _ref13, _ref14, _ref15, _ref16, _ref17, _ref18, _ref19, _ref20, _ref21, _ref22, _ref23, _ref24, _ref25, _ref26, _ref27, _ref28);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgCalendarNotime, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/calendar-notime.639406b4.svg\";\nexport { ForwardRef as ReactComponent };","export enum AppointmentRecurrenceInterval {\n OneWeek = 1,\n TwoWeeks = 2,\n ThreeWeeks = 3,\n FourWeeks = 4,\n EightWeeks = 8,\n TwelveWeeks = 12,\n CustomRecurrenceDefault = 101,\n CustomRecurrenceSaved = 100\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n marginLeft: 26,\n },\n disabled: {\n opacity: 0.5,\n },\n header: {\n display: \"flex\",\n },\n subHeader: {\n marginTop: 28,\n display: \"flex\",\n width: \"100%\",\n },\n subTitle: {\n display: \"flex\",\n width: \"50%\",\n },\n stepTitle: {\n ...theme.typography.header2,\n color: theme.colors.clearMain,\n fontWeight: \"bold\",\n },\n separator: {\n height: 0,\n borderTop: `1px solid ${theme.colors.grey2}`,\n margin: \"24px 0px 24px 0px\",\n },\n selectStyle: {\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 91,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n fontStyle: \"normal\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n },\n dateTimeSubTitle: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5\n },\n switchSubTitle: {\n ...theme.typography.txtBody2,\n fontWeight: 700,\n color: theme.colors.grey4\n },\n calendarIcon: {\n marginLeft: 7,\n marginRight: 13,\n color: theme.colors.grey5,\n },\n dateTimeContent: {\n display: \"flex\",\n width: \"48%\",\n justifyContent: \"end\"\n },\n dateTimeTxt: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n bodyContent: {\n marginTop: 11,\n },\n requiredField: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n calendarScheduler: {\n display: \"flex\",\n marginTop: 18,\n },\n rootCalendar: {\n border: `1px solid ${theme.colors.grey1}`,\n boxSizing: \"border-box\",\n borderRadius: 8,\n boxShadow: \"0px 3px 20px rgba(229, 231, 234, 0.56)\",\n },\n calendar: {},\n schedule: {\n width: \"100%\",\n height: \"auto\",\n marginLeft: 32,\n marginTop: 18\n },\n scheduleContent: {\n marginTop: 15,\n },\n dateRoot: {\n width: 36,\n height: 36,\n margin: \"0 2px\",\n },\n datePicker: {\n marginTop: 16,\n },\n date: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey7,\n width: 36,\n height: 36,\n margin: \"0 2px\",\n },\n currentDate: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n selectedDate: {\n fontWeight: \"bold\",\n background: theme.colors.clearMain,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearMain,\n },\n },\n ulSchedule: {\n flexWrap: \"wrap\",\n display: \"flex\",\n listStyle: \"none\",\n padding: 0\n },\n liSchedule: {\n width: 116,\n height: 32,\n marginRight: 16,\n marginBottom: 16,\n borderRadius: 51,\n cursor: \"pointer\",\n display: \"flex\",\n flex: \"0 0 30%\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\",\n boxSizing: \"border-box\",\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n border: `1px solid ${theme.colors.clearMain}`,\n \"&:nth-child(3n + 3)\": {\n marginRight: 0,\n },\n \"&:hover\": {\n background: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n },\n liScheduleActive: {\n background: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n scheduleInvalid: {\n ...theme.typography.txtBody2,\n fontSize: 14,\n lineHeight: \"18px\",\n fontFamily: \"Roboto\",\n fontWeight: 400\n },\n calendarNoTime: {\n textAlign: \"center\",\n paddingTop: 25\n },\n calendarTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n textAlign: \"center\",\n color: theme.colors.grey4,\n marginTop: 20,\n marginBottom: 15,\n padding: \"0 60px\"\n },\n calendarSubTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontSize: 12,\n textAlign: \"center\",\n color: theme.colors.grey4,\n padding: \"0 60px\"\n },\n \n required: {\n color: \"#6462F3\",\n },\n rowContainer: {\n margin: \"24px 0px 0px 0px\",\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 7px\",\n paddingTop: 6\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: \"#FFFFFF\",\n \"& + .MuiSwitch-track\": {\n backgroundColor: theme.colors.clearGreen,\n opacity: 1,\n border: \"none\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n inputSelect: {\n ...theme.typography.txtBody2,\n backgroundColor: theme.colors.grey1,\n height: 40,\n width: 312,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \"&::placeholder\": {\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontSize: 12,\n color: \"#5C6477\",\n },\n },\n radioLabelRoot: {\n margin: 0,\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n radioOption: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearMain,\n },\n },\n },\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n marginBottom: \"0.5rem\",\n },\n labelAppointment: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 500,\n fontSize: 12,\n color: theme.colors.grey4,\n },\n inputDisabled: {\n opacity: \"0.5\"\n },\n scheduleDisabled: {\n pointerEvents: \"none\",\n opacity: \"0.5\"\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n fontSize: 12,\n alignItems: \"center\"\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { grey } from \"@material-ui/core/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n '& input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button': {\n '-webkit-appearance': 'none',\n margin: '0',\n },\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalTitleTextCancel: {\n marginTop: 0,\n marginBottom: 20,\n fontSize: 18,\n fontWeight: \"bold\"\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: \"15px\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n inputContainer: {\n display: \"flex\",\n width: 344,\n gap: 5,\n alignItems: \"center\",\n marginBottom: 18\n },\n label: {\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#4a4d51\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n labelAppointment: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 500,\n fontSize: 12,\n color: theme.colors.grey4,\n },\n arrowContainer: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n },\n arrowUp: {\n width: '20px',\n height: '20px',\n backgroundColor: 'white',\n border: 'none',\n padding: \"5px\",\n outline: 'none',\n '&:before': {\n content: '\"\"',\n display: 'block',\n width: '0',\n height: '0',\n borderLeft: '5px solid transparent',\n borderRight: '5px solid transparent',\n borderBottom: '5px solid black',\n },\n '&:focus': {\n outline: 'none',\n },\n '&:hover': {\n backgroundColor: 'lightgray',\n borderRadius: '50%',\n },\n },\n \n arrowDown: {\n width: '20px',\n height: '20px',\n backgroundColor: 'white',\n border: 'none',\n padding: \"5px\",\n outline: 'none',\n '&:before': {\n content: '\"\"',\n display: 'block',\n width: '0',\n height: '0',\n borderLeft: '5px solid transparent',\n borderRight: '5px solid transparent',\n borderTop: '5px solid black',\n },\n '&:focus': {\n outline: 'none',\n },\n '&:hover': {\n backgroundColor: 'lightgray',\n borderRadius: '50%',\n },\n },\n tooltipBlock: {\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n cellWithTooltip: {\n cursor: \"pointer !important\",\n },\n arrowButtonContainer: {\n cursor: 'pointer',\n borderRadius: '100%',\n },\n cancelCustomRecurrenceModal: {\n height: \"180px !important\"\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\"\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n modalHeader: {\n fontFamily: 'Inter',\n fontSize: '14px',\n fontStyle: 'normal',\n fontWeight: 700,\n lineHeight: 'normal',\n color: theme.colors.grey5\n },\n subhead: {\n fontFamily: 'Roboto',\n fontSize: '12px',\n fontStyle: 'normal',\n fontWeight: 700,\n lineHeight: 'normal',\n color: theme.colors.grey4\n },\n inputInfo: {\n fontFamily: 'Roboto',\n fontSize: '12px',\n fontStyle: 'normal',\n fontWeight: 400,\n lineHeight: 'normal',\n color: theme.colors.grey4\n },\n marginLeft10: {\n marginLeft: 10\n },\n marginRight10: {\n marginRight: 10\n },\n daysWeekContainer: {\n marginBottom: 15,\n marginLeft: 15,\n display: 'flex',\n gap: 10\n },\n daysWeekTitle: {\n fontFamily: 'Roboto',\n fontSize: '12px',\n fontStyle: 'normal',\n fontWeight: 700,\n lineHeight: 'normal',\n color: theme.colors.grey4,\n \n paddingBottom: 13,\n paddingLeft: 6,\n },\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: \"auto\",\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\"\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalContent: {},\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: theme.colors.grey4, //Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\"\n },\n confirmButton: {\n fontWeight: \"bold\",\n fontSize: 12,\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport useStyles from \"./css\";\nimport { ConfirmActionModalProps } from \"./props\";\nimport { CrossIcon } from \"../../../assets/icons\";\n\nexport default function ConfirmActionModal(props: ConfirmActionModalProps) {\n\n const { t } = useTranslation([\"general\"]);\n const { open, content, onClose, onConfirm, buttonClass, classModal, confirmButtonText } = props;\n const classes = useStyles();\n\n const handleConfirm = () => {\n if (onConfirm) onConfirm();\n };\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={`${classes.modal}`}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={open}>\n <div className={`${classes.modalPaper} ${classModal}`}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n <div className={classes.modalContent}>\n {content}\n <div className={classes.modalActions}>\n <Button className={`${buttonClass ?? \"\"} ${classes.button} ${classes.goBack}`} onClick={onClose} >\n {t(\"Go back\")}\n </Button>\n\n <Button className={`${buttonClass ?? \"\"} ${classes.button} ${classes.confirmButton}`} onClick={handleConfirm} >\n {confirmButtonText ?? t(\"Yes\")}\n </Button>\n </div>\n\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};","import { CustomRecurrenceMode } from \"./enums/custom-recurrence-mode\";\nimport { WeekDaysFlags } from \"./enums/week-days-flags\";\n\n\nexport class RecurrenceModalData {\n customRecurrenceInterval: number | null;\n customRecurrenceMode: CustomRecurrenceMode | null;\n customRecurredAppointmentsCount: number | null;\n customRecurrenceWeekDays: WeekDaysFlags | null;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.customRecurrenceInterval = x.customRecurrenceInterval;\n this.customRecurrenceMode = x.customRecurrenceMode;\n this.customRecurredAppointmentsCount = x.customRecurredAppointmentsCount;\n this.customRecurrenceWeekDays = x.customRecurrenceWeekDays;\n } else {\n this.customRecurrenceInterval = null;\n this.customRecurrenceMode = null;\n this.customRecurredAppointmentsCount = null;\n this.customRecurrenceWeekDays = null;\n }\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n \n icon: {\n userSelect: \"none\",\n pointerEvents: \"all\",\n \n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderRadius: '50%',\n \n width: 40,\n height: 40,\n \n backgroundColor: theme.colors.grey1,\n \n boxShadow: '0px 1px 3px rgba(0, 0, 0, 0.5)',\n },\n checkedIcon: {\n userSelect: \"none\",\n pointerEvents: \"all\",\n \n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderRadius: '50%',\n \n width: 40,\n height: 40,\n \n backgroundColor: theme.colors.clearMain,\n color: '#FFFFFF',\n \n boxShadow: '0px 1px 3px rgba(0, 0, 0, 0.5)',\n },\n tooltipBlock: {\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n \n position: \"relative\",\n top: -5\n },\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { Checkbox, FormControlLabel } from \"@material-ui/core\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nimport useStyles from \"./css\";\nimport { CircleCheckboxProps } from \"./props\";\n\nexport default function CircleCheckbox(props: CircleCheckboxProps) {\n const { checked, setChecked, label, tooltipTitle } = props;\n const classes = useStyles();\n \n function handleChecking() {\n setChecked(!checked);\n }\n \n const CheckboxComponent = \n <Checkbox\n checked={checked}\n onChange={handleChecking}\n hidden={true}\n />\n \n return (\n <Tooltip\n title={tooltipTitle}\n classes={{ tooltip: classes.tooltipBlock }}\n >\n <FormControlLabel\n control={CheckboxComponent}\n label={label}\n classes={{\n label: checked \n ? classes.checkedIcon\n : classes.icon\n }}\n />\n </Tooltip>\n );\n}","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport useStyles from \"./css\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\nimport ConfirmActionModal from \"../../common/ConfirmActionModal\";\nimport Input from \"../../common/Input\";\nimport Select from \"../../common/Select\";\n\nimport { CustomRecurrenceModalProps } from \"./props\";\nimport { SelectItem } from \"../../common/SelectWithLabel\";\nimport { CustomRecurrenceMode } from \"../../../models/enums/custom-recurrence-mode\";\nimport { RecurrenceModalData } from \"../../../models/recurrence-modal-data\";\nimport CircleCheckbox from \"../../common/CircleCheckbox\";\nimport { WeekDaysFlags } from \"../../../models/enums/week-days-flags\";\n\n\nexport default function CustomRecurrenceModal(props: CustomRecurrenceModalProps) {\n \n const { isOpen, handleClose, handleConfirm } = props;\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n const [recurrenceInterval, setRecurrenceInterval] = useState<number>(1);\n const [recurrenceItemId, setRecurrenceItemId] = useState<CustomRecurrenceMode | null>(null);\n const [recurrenceAfterAppointments, setRecurrenceAfterAppointments] = useState<number | null>(6);\n \n const [isValidRecurrenceAfterAppointments, setIsValidRecurrenceAfterAppointments] = useState<boolean>(true);\n const [isValidRecurrenceInterval, setIsValidRecurrenceInterval] = useState<boolean>(true);\n \n const [cancelCustomRecurrenceModalIsOpen, setCancelCustomRecurrenceModalIsOpen] = useState<boolean>(false);\n const [inputDataHasChange, setInputDataHasChange] = useState<boolean>(false);\n \n const [recurrenceWeekDays, setRecurrenceWeekDays] = useState<WeekDaysFlags>(WeekDaysFlags.None);\n \n const frequencyItems: SelectItem[] = [\n { key: \"0\", value: recurrenceInterval > 1 ? `${t(\"days\")}` : `${t(\"day\")}` } as SelectItem,\n { key: \"1\", value: recurrenceInterval > 1 ? `${t(\"weeks\")}` : `${t(\"week\")}` } as SelectItem,\n { key: \"2\", value: recurrenceInterval > 1 ? `${t(\"months\")}` : `${t(\"month\")}` } as SelectItem,\n { key: \"3\", value: recurrenceInterval > 1 ? `${t(\"years\")}` : `${t(\"year\")}` } as SelectItem,\n ];\n \n function recurrenceChangeHandler(event: any) {\n setInputDataHasChange(true);\n const inputValue = event.target.value;\n if (inputValue.startsWith('0')) {\n return;\n }\n setRecurrenceInterval(Number(inputValue));\n }\n \n function handleIncrease() {\n setInputDataHasChange(true);\n if (recurrenceInterval > 998) {\n return;\n }\n setRecurrenceInterval(recurrenceInterval + 1);\n }\n \n function handleDecrease() {\n setInputDataHasChange(true);\n if (recurrenceInterval < 2) {\n return;\n }\n setRecurrenceInterval(recurrenceInterval - 1);\n }\n \n function inputDataIsValid(): boolean {\n const isRecurrenceAfterValid = recurrenceAfterAppointments && recurrenceAfterAppointments > 1 && recurrenceAfterAppointments < 51;\n const isRecurrenceIntervalValid = recurrenceInterval > 0 && recurrenceInterval < 1000;\n const forWeekModeDayIsChosen = recurrenceItemId !== CustomRecurrenceMode.Week || recurrenceWeekDays > 0;\n return !!(isRecurrenceAfterValid && isRecurrenceIntervalValid && forWeekModeDayIsChosen);\n }\n \n function handleRecurrenceSelect(event: any) {\n setInputDataHasChange(true);\n const value = parseInt(event.target.value);\n if (value === CustomRecurrenceMode.Week) {\n const currentDayIndex = new Date().getDay();\n const initialRecurrenceWeekDays = 1 << currentDayIndex;\n setRecurrenceWeekDays(initialRecurrenceWeekDays);\n } else {\n setRecurrenceWeekDays(WeekDaysFlags.None);\n }\n setRecurrenceItemId(Number(value));\n }\n \n function handleRecurrenceAfterAppointments(event: any) {\n const value = event.target.value.replace(/\\D/g, \"\");\n if (value.startsWith('0')) {\n return;\n }\n setInputDataHasChange(true);\n setRecurrenceAfterAppointments(value);\n }\n \n function handleBlurRecurrencesAfterAppointments(event: any) {\n let value = event.target.value;\n const isNotValid = (value === \"\" || +value < 0) || !(value >= 2 && value <= 50);\n if (isNotValid) {\n setRecurrenceAfterAppointments(null);\n }\n setIsValidRecurrenceAfterAppointments(!isNotValid);\n }\n \n function handleBlurRepeatEvery(event: any) {\n let value = event.target.value;\n const isNotValid = (value === \"\" || +value < 0) || !(value >= 1 && value <= 999);\n setIsValidRecurrenceInterval(!isNotValid);\n }\n \n function handleOnClickSave() {\n const modalData = new RecurrenceModalData({\n customRecurrenceInterval: +recurrenceInterval!,\n customRecurrenceMode: +recurrenceItemId!,\n customRecurredAppointmentsCount: +recurrenceAfterAppointments!,\n customRecurrenceWeekDays: +recurrenceWeekDays!\n });\n setInputDataHasChange(false);\n handleConfirm(modalData);\n }\n \n function handleOnClickConfirmModalCancel() {\n setInputDataHasChange(false);\n setCancelCustomRecurrenceModalIsOpen(false);\n handleClose();\n }\n \n function handleOnClose() {\n if (inputDataHasChange) {\n setCancelCustomRecurrenceModalIsOpen(true);\n } else {\n setInputDataHasChange(false);\n handleClose();\n }\n }\n \n function handleCheckboxChange(day: WeekDaysFlags) {\n setInputDataHasChange(true);\n setRecurrenceWeekDays((prevDays) => {\n return prevDays ^ day;\n })\n }\n \n const CancelCustomRecurrenceModalContent: React.FC = () => {\n return (\n <div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {t(\"Cancel custom recurrence?\")}\n </Typography>\n </div>);\n };\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={handleOnClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={isOpen}>\n <div className={classes.modalCancelPaper}>\n <div>\n <Typography className={classes.modalHeader}>\n {t(\"Custom recurrence\")}\n </Typography>\n <div className={`${classes.modalTitleSpace}`}>\n \n <Typography className={classes.modalTitleTextCancel}>\n <div className={classes.inputContainer}>\n <div className={`${classes.inputInfo} ${classes.marginRight10}`}>\n {t(\"Repeat every\")}\n </div>\n <Input\n id={\"inputRecurrence\"}\n name={\"inputRecurrence\"}\n value={recurrenceInterval}\n onChange={recurrenceChangeHandler}\n width={50}\n onBlur={handleBlurRepeatEvery}\n inputType={\"number\"}\n isValid={() => isValidRecurrenceInterval}\n />\n <div className={classes.arrowContainer}>\n <Tooltip\n title={<span>{t(\"Increase\")} </span>}\n classes={{ tooltip: classes.tooltipBlock }}\n >\n <button\n className={classes.arrowUp}\n onClick={handleIncrease}\n />\n </Tooltip>\n <Tooltip\n title={<span>{t(\"Decrease\")} </span>}\n classes={{ tooltip: classes.tooltipBlock }}\n >\n <button\n className={classes.arrowDown}\n onClick={handleDecrease}\n />\n </Tooltip>\n </div>\n <Select key={\"inputRecurrenceMode-id\"}\n width={100}\n value={recurrenceItemId || \"0\"}\n onChange={(e) => handleRecurrenceSelect(e)}\n colorArrowIcon={\"#5C6477\"}\n items={frequencyItems}/>\n </div>\n \n {recurrenceItemId === CustomRecurrenceMode.Week && <>\n <div className={classes.daysWeekTitle}>{t(\"Days\")}</div>\n <div className={classes.daysWeekContainer}>\n <CircleCheckbox\n tooltipTitle={t(\"Sunday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Sunday) === WeekDaysFlags.Sunday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Sunday)}\n label={t(\"short_weekday_Sunday\")}\n />\n <CircleCheckbox\n tooltipTitle={t(\"Monday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Monday) === WeekDaysFlags.Monday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Monday)}\n label={t(\"short_weekday_Monday\")}\n />\n <CircleCheckbox\n tooltipTitle={t(\"Tuesday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Tuesday) === WeekDaysFlags.Tuesday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Tuesday)}\n label={t(\"short_weekday_Tuesday\")}\n />\n <CircleCheckbox\n tooltipTitle={t(\"Wednesday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Wednesday) === WeekDaysFlags.Wednesday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Wednesday)}\n label={t(\"short_weekday_Wednesday\")}\n />\n <CircleCheckbox\n tooltipTitle={t(\"Thursday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Thursday) === WeekDaysFlags.Thursday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Thursday)}\n label={t(\"short_weekday_Thursday\")}\n />\n <CircleCheckbox\n tooltipTitle={t(\"Friday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Friday) === WeekDaysFlags.Friday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Friday)}\n label={t(\"short_weekday_Friday\")}\n />\n <CircleCheckbox\n tooltipTitle={t(\"Saturday\")}\n checked={(recurrenceWeekDays & WeekDaysFlags.Saturday) === WeekDaysFlags.Saturday}\n setChecked={() => handleCheckboxChange(WeekDaysFlags.Saturday)}\n label={t(\"short_weekday_Saturday\")}\n />\n </div>\n </>}\n <div className={classes.subhead} style={{ marginBottom: 18 }}>\n {t(\"Term of recurrence\")}*\n </div>\n <div style={{ display: \"inline-block\" }}>\n <span className={classes.inputInfo}>\n {t(\"After\")} \n </span>\n </div>\n \n <div style={{ display: \"inline-block\", position: \"relative\", top: 0, left: 20 }}>\n <Input\n type={\"text\"}\n value={recurrenceAfterAppointments}\n isValid={() => isValidRecurrenceAfterAppointments}\n width={50}\n onChange={handleRecurrenceAfterAppointments}\n onBlur={handleBlurRecurrencesAfterAppointments}\n />\n <span className={`${classes.inputInfo} ${classes.marginLeft10}`}>\n {t(\"appointments\")}\n </span>\n </div>\n \n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleOnClose}>\n {t(\"Close\")}\n </Button>\n <Button\n style={{ opacity: inputDataIsValid() ? 1 : 0.5 }}\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={handleOnClickSave}\n disabled={!inputDataIsValid()}\n >\n {t(\"Save\")}\n </Button>\n </div>\n </div>\n <ConfirmActionModal\n classModal={classes.cancelCustomRecurrenceModal}\n content={<CancelCustomRecurrenceModalContent/>}\n open={cancelCustomRecurrenceModalIsOpen}\n onClose={() => setCancelCustomRecurrenceModalIsOpen(false)}\n onConfirm={handleOnClickConfirmModalCancel}\n />\n </div>\n </Fade>\n </Modal>\n );\n}","import React, { useEffect, useRef, useState } from \"react\";\nimport { Trans, useTranslation } from \"react-i18next\";\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\n\nimport DateFnsUtils from \"@date-io/date-fns\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\nimport Typography from \"@material-ui/core/Typography\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport { DatePicker, MuiPickersUtilsProvider } from \"@material-ui/pickers\";\nimport { MaterialUiPickersDate } from \"@material-ui/pickers/typings/date\";\n\nimport Switch from \"../../common/Switch\";\nimport Input from \"../../common/Input\";\nimport { CalendarIcon } from \"./../../../assets/icons\";\nimport { AppointmentService } from \"./../../../api/appointment-service\";\nimport { CreateAppointmentModel } from \"../../../models/create-appointment-model\";\nimport { CreateAppointmentService } from \"../../../models/create-appointment-service\";\nimport { ReactComponent as CalendarNoTime } from \"./../../../assets/images/calendar-notime.svg\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { blockedScheduleActions } from \"../../../redux/blocked-schedule-slice\";\n\nimport { AppointmentStepTwoProps } from \"./props\";\nimport useStyles from \"./css\";\nimport SelectWithLabel, { SelectItem } from \"../../common/SelectWithLabel\";\nimport { AppointmentRecurrenceInterval } from \"../../../models/enums/appointment-recurrence-interval\";\nimport { scheduleAppointmentTimeActions } from \"../../../redux/schedule-appointment-time-slice\";\nimport { schedulerActions } from \"../../../redux/scheduler-slice\";\nimport CustomRecurrenceModal from \"../CustomRecurrenceModal\";\nimport { CustomRecurrenceMode } from \"../../../models/enums/custom-recurrence-mode\";\nimport { RecurrenceModalData } from \"../../../models/recurrence-modal-data\";\nimport { WeekDaysFlags } from \"../../../models/enums/week-days-flags\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\nconst AppointmentStepTwo = (props: AppointmentStepTwoProps) => {\n const { appointment, step1Valid, isEdition, refreshData, onChange, onRecurringChange } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const [date, setDate] = useState<Date>(new Date());\n const [availableHours, setAvailableHours] = useState<string[]>([]);\n const [isAvailableHoursLoad, setIsAvailableHoursLoad] = useState<boolean>(false);\n const [schedule, setSchedule] = useState<string>();\n const [services, setServices] = useState<CreateAppointmentService[]>();\n const dispatch = useAppDispatch();\n const { setDaysOff } = schedulerActions;\n const daysOff = useAppSelector((state) => state.scheduler.daysOff);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const scheduleAppointmentTime = useAppSelector(state => state.scheduleAppointmentTime.appointmentTime);\n const isNewAppointmentViaScheduler = useAppSelector(state => state.scheduleAppointmentTime.newAppointmentViaScheduler);\n const [desiredDate, setDesiredDate] = useState<Date | null>(useAppSelector(state => state.blockedSchedule.date));\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const [isRecurringAppointment, setIsRecurringAppointment] = useState<boolean>(false);\n const [customRecurrenceModalIsOpen, setCustomRecurrenceModalIsOpen] = useState<boolean>(false);\n const [isCustomRecurrence, setIsCustomRecurrence] = useState<boolean>(false);\n const [customRecurrenceInterval, setCustomRecurrenceInterval] = useState<number | null>(null);\n const [customRecurrenceMode, setCustomRecurrenceMode] = useState<CustomRecurrenceMode | null>(null);\n const [customRecurrenceAfterAppointments, setCustomRecurrenceAfterAppointments] = useState<number | null>(null);\n const [customRecurrenceWeekDays, setCustomRecurrenceWeekDays] = useState<WeekDaysFlags | null>(null);\n const [isCustomSchedule, setIsCustomSchedule] = useState<boolean>(false);\n const [scheduledSimultaneousServices, setScheduledSimultaneousServices] = useState<boolean>(false);\n const [recurrenceItems, setRecurrenceItems] = useState<SelectItem[]>([]);\n const [recurrenceItemId, setRecurrenceItemId] = useState<AppointmentRecurrenceInterval | null>(null);\n const [recurrenceAfterAppointments, setRecurrenceAfterAppointments] = useState<number | null>(null);\n const [customStartTime, setCustomStartTime] = useState<moment.Moment>(moment().utcOffset(0).set({ hour: 9, minute: 30}));\n\n const [isValidRecurrence, setIsValidRecurrence] = useState<boolean>(true);\n const [isValidEndRecurrence, setIsValidEndRecurrence] = useState<boolean>(true);\n\n const availableHoursDelayRef = useRef<any>(null);\n const loadAvailableTimeObservableValuesRef = useRef<string|null>(null);\n const loadAvailableTimePrevDateRef = useRef<number|null>(null);\n const isDaysOffLoadRef = useRef<boolean>(false);\n\n const frequencyItems: SelectItem[] = [\n {key: \"1\", value: `${t(\"Every week, on the\")} DAY`} as SelectItem,\n {key: \"2\", value: `${t(\"Every 2 weeks, on the\")} DAY`} as SelectItem,\n {key: \"3\", value: `${t(\"Every 3 weeks, on the\")} DAY`} as SelectItem,\n {key: \"4\", value: `${t(\"Every 4 weeks, on the\")} DAY`} as SelectItem,\n {key: \"8\", value: `${t(\"Every 8 weeks, on the\")} DAY`} as SelectItem,\n {key: \"12\", value: `${t(\"Every 12 weeks, on the\")} DAY`} as SelectItem,\n {key: \"101\", value: `${t(\"Custom\")}`} as SelectItem,\n ];\n const format = \"HH:mm\";\n \n const servicesHaveRepeatedUsers = appointment?.services.some((user, index) => {\n return appointment?.services.slice(0, index).some((prevUser) => {\n return prevUser.userId === user.userId;\n });\n });\n\n useEffect(() => {\n if (desiredDate) {\n dispatch(blockedScheduleActions.setDate(null));\n }\n }, []);\n\n useEffect(() => {\n const observableValues = {\n customerId: appointment?.customerId,\n services: appointment?.services.map(x => { return { serviceId:x.serviceId, userId:x.userId, workAreaId:x.workAreaId, estimatedDuration: x.estimatedDuration }}),\n startDate: appointment?.startDate,\n isRecurringAppointment: isRecurringAppointment,\n recurrenceItemId: recurrenceItemId,\n customRecurrenceInterval: customRecurrenceInterval,\n customRecurrenceWeekDays: customRecurrenceWeekDays,\n customRecurrenceAfterAppointments: customRecurrenceAfterAppointments, \n customRecurrenceMode: customRecurrenceMode,\n recurrenceAfterAppointments: recurrenceAfterAppointments,\n scheduledSimultaneousServices: scheduledSimultaneousServices,\n refreshData: refreshData\n }\n const observableValuesString = JSON.stringify(observableValues);\n if (observableValuesString === loadAvailableTimeObservableValuesRef.current){\n return;\n }\n const prevObservableValues = loadAvailableTimeObservableValuesRef.current ? JSON.parse(loadAvailableTimeObservableValuesRef.current) : null;\n loadAvailableTimeObservableValuesRef.current = observableValuesString;\n if (prevObservableValues &&\n (prevObservableValues.isRecurringAppointment && !observableValues.isRecurringAppointment ||\n !observableValues.isRecurringAppointment &&\n (prevObservableValues.recurrenceItemId !== observableValues.recurrenceItemId ||\n prevObservableValues.recurrenceAfterAppointments !== observableValues.recurrenceAfterAppointments ||\n prevObservableValues.customRecurrenceInterval !== observableValues.customRecurrenceInterval ||\n prevObservableValues.customRecurrenceAfterAppointments !== observableValues.customRecurrenceAfterAppointments ||\n prevObservableValues.customRecurrenceWeekDays !== observableValues.customRecurrenceWeekDays ||\n prevObservableValues.customRecurrenceMode !== observableValues.customRecurrenceMode ||\n prevObservableValues.scheduledSimultaneousServices !== observableValues.scheduledSimultaneousServices))) {\n return;\n }\n if (prevObservableValues?.startDate && observableValues?.startDate && new Date(prevObservableValues.startDate).getTime() !== new Date(observableValues.startDate).getTime()) {\n let prevStartDate = new Date(prevObservableValues.startDate);\n let currentStartDate = new Date(prevObservableValues.startDate);\n prevStartDate.setHours(0, 0, 0, 0);\n currentStartDate.setHours(0, 0, 0, 0);\n if (prevStartDate.getTime() === currentStartDate.getTime()){\n return;\n }\n }\n\n async function fetchData() {\n await loadAvailableHoursWithDelay();\n await loadAvailableDaysIfNeed();\n }\n\n if (step1Valid && !desiredDate) {\n fetchData();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointment?.customerId,\n appointment?.services,\n appointment?.startDate,\n isRecurringAppointment,\n scheduledSimultaneousServices,\n recurrenceItemId,\n recurrenceAfterAppointments,\n customRecurrenceInterval,\n customRecurrenceAfterAppointments,\n customRecurrenceWeekDays,\n customRecurrenceMode,\n refreshData]);\n \n useEffect(() => {\n if (appointment?.startDate) {\n let appointmentStartDate = new Date(appointment?.startDate);\n let currentStateStartDate = new Date(date);\n \n if (appointmentStartDate.getTime() === currentStateStartDate?.getTime() && isCustomSchedule) {\n setIsAvailableHoursLoad(true);\n return;\n }\n\n currentStateStartDate.setHours(0, 0, 0, 0);\n if (loadAvailableTimePrevDateRef.current && loadAvailableTimePrevDateRef.current === currentStateStartDate?.getTime() && !isCustomSchedule) {\n setIsAvailableHoursLoad(true);\n return;\n }\n loadAvailableTimePrevDateRef.current = currentStateStartDate.getTime();\n }\n \n async function fetchData() {\n await loadAvailableHoursWithDelay();\n await loadAvailableDaysIfNeed();\n }\n\n if (step1Valid) {\n fetchData().then(() => {\n if (isCustomSchedule) {\n setSchedule(undefined);\n }\n });\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [date]);\n\n useEffect(() => {\n \n if (\n appointment &&\n appointment.services &&\n JSON.stringify(appointment.services) !== JSON.stringify(services)\n ) {\n setServices(appointment.services);\n setSchedule(undefined);\n }\n\n if (\n appointment &&\n appointment.startDate &&\n appointment.startDate !== date\n ) {\n setDate(new Date(appointment.startDate));\n if (appointment.services) {\n const duration = getEstimatedDurations() ?? 0;\n const fromDate = new Date(appointment.startDate).toLocaleString(\n undefined,\n {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n }\n );\n\n const appointmentDate = new Date(appointment.startDate);\n const toDate = new Date(\n appointmentDate.getTime() + duration * 60000\n ).toLocaleString(undefined, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n setSchedule(`${fromDate} - ${toDate}`);\n }\n\n \n if (appointment) {\n setIsCustomRecurrence(appointment.customRecurrenceInterval != null);\n setIsRecurringAppointment(appointment.isRecurring);\n let recurrenceItemId = (isCustomRecurrence || appointment.customRecurrenceInterval != null)\n ? AppointmentRecurrenceInterval.CustomRecurrenceSaved\n : appointment.recurrenceWeekInterval;\n setRecurrenceItemId(recurrenceItemId);\n setRecurrenceAfterAppointments(appointment.recurredAppointmentsCount);\n onRecurringChange?.(appointment.recurredAppointmentsCount ?? 0, isRecurringAppointment);\n if (appointment.id) {\n setCustomRecurrenceAfterAppointments(appointment.recurredAppointmentsCount);\n setCustomRecurrenceInterval(appointment.customRecurrenceInterval);\n setCustomRecurrenceMode(appointment.customRecurrenceMode);\n setCustomRecurrenceWeekDays(appointment.customRecurrenceWeekDays);\n }\n }\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointment]);\n \n useEffect(() => {\n if (servicesHaveRepeatedUsers && !accountSettings.hasMultipleAppointments) {\n setScheduledSimultaneousServices(false);\n }\n }, [servicesHaveRepeatedUsers]);\n \n useEffect(() => {\n if (appointment?.id) {\n setScheduledSimultaneousServices(appointment.scheduledSimultaneousServices);\n }\n }, [appointment?.id]);\n \n useEffect(() => {\n async function fetchData() {\n await loadAvailableHoursWithDelay();\n await loadAvailableDaysIfNeed();\n }\n if (step1Valid) {\n fetchData().then(() => {\n if (isCustomSchedule) {\n setSchedule(undefined);\n }\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [scheduledSimultaneousServices]);\n\n useEffect(() => {\n if (step1Valid && desiredDate) {\n const startDate = new Date(desiredDate);\n setIsAvailableHoursLoad(false);\n setDate(startDate);\n }\n }, [step1Valid]);\n\n useEffect(() => {\n if (desiredDate && step1Valid && Array.isArray(daysOff) && isAvailableHoursLoad && appointment && appointment.services) {\n const isDayOff = daysOff.findIndex((dayOff) => dayOff === desiredDate.getDay()) !== -1;\n if (!isDayOff){\n const fromDate = new Date(desiredDate).toLocaleString(\n undefined,\n {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n }\n );\n const duration = getDurations();\n const toDate = new Date(\n desiredDate.getTime() + duration * 60000\n ).toLocaleString(undefined, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n const desiredSchedule = `${fromDate} - ${toDate}`;\n if (availableHours.findIndex((h) => h === desiredSchedule) >= 0){\n setSchedule(desiredSchedule);\n }\n }\n setDesiredDate(null);\n }\n }, [daysOff, isAvailableHoursLoad]);\n\n useEffect(() => {\n if (onChange) {\n const validateRecurring = !isRecurringAppointment\n || (isRecurringAppointment\n && recurrenceItemId !== null\n && (!isCustomRecurrence && recurrenceAfterAppointments! > 1 && recurrenceAfterAppointments! <= 50)\n || (isCustomRecurrence && customRecurrenceAfterAppointments! > 1 && customRecurrenceAfterAppointments! <= 50));\n \n const customRecurrenceWeekDayValid = !isCustomRecurrenceWeekDaysModeChoose || \n customRecurrenceWeekDays !== null && (customRecurrenceWeekDays & (1 << date.getDay())) !== 0;\n \n if (customRecurrenceWeekDayValid && validateRecurring && (schedule || isCustomSchedule)) {\n let startDate = new Date(date);\n\n if (isCustomSchedule) {\n startDate.setHours(\n +customStartTime.hours(),\n +customStartTime.minutes(),\n 0,\n 0\n );\n }\n else if (schedule) {\n const startTime = schedule.split(\"-\")[0];\n startDate.setHours(\n +startTime.split(\":\")[0],\n +startTime.split(\":\")[1],\n 0,\n 0\n );\n }\n\n const newStateAppointment = new CreateAppointmentModel({ ...appointment, \n startDate: startDate,\n isRecurring: isRecurringAppointment,\n scheduledSimultaneousServices: scheduledSimultaneousServices,\n recurrenceWeekInterval: isCustomRecurrence ? null : recurrenceItemId,\n recurredAppointmentsCount: isCustomRecurrence ? +customRecurrenceAfterAppointments! : +recurrenceAfterAppointments!,\n customRecurrenceInterval: isCustomRecurrence ? +customRecurrenceInterval! : null,\n customRecurrenceMode: isCustomRecurrence ? customRecurrenceMode : null,\n customRecurrenceWeekDays: isCustomRecurrence && isCustomRecurrenceWeekDaysModeChoose ? customRecurrenceWeekDays : null,\n isCustomSchedule: isCustomSchedule\n });\n \n onChange(newStateAppointment, true);\n } \n else {\n onChange(null, false);\n }\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [\n schedule,\n scheduledSimultaneousServices,\n isCustomSchedule,\n recurrenceAfterAppointments,\n recurrenceItemId]);\n \n useEffect(() => {\n if (isCustomSchedule && !appointment?.id) {\n if (isNewAppointmentViaScheduler) {\n setDate(scheduleAppointmentTime);\n setCustomStartTime(moment(scheduleAppointmentTime, 'HH:mm'));\n \n if (onChange) {\n const newStateAppointment = new CreateAppointmentModel({ ...appointment,\n startDate: scheduleAppointmentTime,\n isRecurring: isRecurringAppointment,\n scheduledSimultaneousServices: scheduledSimultaneousServices,\n recurrenceWeekInterval: isCustomRecurrence ? null : recurrenceItemId,\n recurredAppointmentsCount: isCustomRecurrence ? +customRecurrenceAfterAppointments! : +recurrenceAfterAppointments!,\n customRecurrenceInterval: isCustomRecurrence ? +customRecurrenceInterval! : null,\n customRecurrenceMode: isCustomRecurrence ? customRecurrenceMode : null,\n customRecurrenceWeekDays: isCustomRecurrence && isCustomRecurrenceWeekDaysModeChoose ? customRecurrenceWeekDays : null,\n isCustomSchedule: isCustomSchedule\n });\n\n onChange(newStateAppointment, true);\n setSchedule(\"---\");\n }\n dispatch(scheduleAppointmentTimeActions.setClickNewAppointmentOnScheduler(false));\n }\n else {\n if (!appointment?.id) {\n const firstAvailableHour = availableHours[0]?.substring(0, availableHours[0]?.indexOf(' '));\n setCustomStartTime(moment(firstAvailableHour ?? moment().utcOffset(0).set({ hour: 9, minute: 30, }), 'HH:mm'));\n }\n else {\n if (appointment?.startDate) {\n let appointmentStartDate = new Date(appointment?.startDate);\n setCustomStartTime(moment(moment().utcOffset(0).set({ hour: appointmentStartDate?.getHours(), minute: appointmentStartDate?.getMinutes(), }), 'HH:mm'));\n }\n }\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isCustomSchedule]);\n \n useEffect(() => {\n // Refresh day name in SelectItems \n const day = \" \" + formatDay();\n let selectItems: SelectItem[] = [];\n\n frequencyItems.forEach(item => {\n const newValue = item.value.replace(\"DAY\", day);\n selectItems.push({key: item.key, value: newValue} as SelectItem);\n });\n \n if (customRecurrenceInterval !== null && customRecurrenceMode !== null && customRecurrenceAfterAppointments !== null) {\n const modeString = t(CustomRecurrenceMode[customRecurrenceMode].toLowerCase());\n const modeStringEnding = localeApp == 'es' && customRecurrenceMode === CustomRecurrenceMode.Month ? \"es\" : \"s\";\n\n const daysOfWeek = customRecurrenceWeekDays && customRecurrenceWeekDays > 0 \n ? ` ${t(\"_the\")} ${getChosenDaysOfWeek(customRecurrenceWeekDays)}` \n : \"\";\n const afterAppointments = `${t(\"after\")} ${customRecurrenceAfterAppointments} ${t(\"appointments\")}`;\n const recurrenceString = `${t(\"Every\")} ${customRecurrenceInterval} ${modeString}${modeStringEnding}${daysOfWeek}, ${afterAppointments}`;\n\n selectItems.push({ key: AppointmentRecurrenceInterval.CustomRecurrenceSaved, value: recurrenceString } as SelectItem);\n }\n setRecurrenceItems(selectItems);\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [date]);\n \n useEffect(() => {\n setIsCustomSchedule(appointment?.isCustomSchedule ?? false);\n if (appointment?.isCustomSchedule && appointment?.id && appointment?.startDate) {\n let appointmentStartDate = new Date(appointment?.startDate);\n setCustomStartTime(moment().utcOffset(0).set({ hour: appointmentStartDate?.getHours(), minute:appointmentStartDate?.getMinutes()}));\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [appointment?.isCustomSchedule]);\n \n const loadAvailableHoursWithDelay = async () => {\n if (appointment && appointment.services && appointment.services.length) {\n if (availableHoursDelayRef.current){\n clearTimeout(availableHoursDelayRef.current!);\n availableHoursDelayRef.current = null;\n }\n availableHoursDelayRef.current = setTimeout(async function () {\n if (appointment.services.some(service => service.userId === undefined)) {\n return;\n } \n\n const availableSchedule = await AppointmentService.getAvailableHours(\n date,\n appointment.services,\n scheduledSimultaneousServices,\n appointment.id || undefined,\n isCustomRecurrence ? null : recurrenceItemId,\n isCustomRecurrence ? customRecurrenceAfterAppointments : recurrenceAfterAppointments,\n isCustomRecurrence ? customRecurrenceMode : null,\n isCustomRecurrence ? customRecurrenceInterval : null,\n isCustomRecurrence && isCustomRecurrenceWeekDaysModeChoose ? customRecurrenceWeekDays : null,\n );\n const values = availableSchedule.availableHours || [];\n setAvailableHours(values);\n\n if (!isCustomSchedule && schedule && values.findIndex((h) => h === schedule) < 0){\n setSchedule(undefined);\n }\n setIsAvailableHoursLoad(true);\n\n clearTimeout(availableHoursDelayRef.current);\n availableHoursDelayRef.current = null;\n }, 10);\n }\n };\n\n const loadAvailableDaysIfNeed = async () => {\n if (!isDaysOffLoadRef.current && !Array.isArray(daysOff)){\n isDaysOffLoadRef.current = true;\n const days = await AppointmentService.getAvailableDays();\n dispatch(setDaysOff([...days]));\n }\n };\n \n const isCustomRecurrenceWeekDaysModeChoose = recurrenceItemId === AppointmentRecurrenceInterval.CustomRecurrenceSaved\n && customRecurrenceWeekDays !== null\n && customRecurrenceWeekDays !== 0;\n\n const getLocale = (): any => {\n switch (localeApp) {\n case \"es\":\n return esLocale;\n\n default:\n return enLocale;\n }\n };\n\n const formatDate = (): string => {\n let longDay = date.toLocaleDateString(localeApp, { weekday: \"long\" });\n longDay = longDay.charAt(0).toUpperCase() + longDay.slice(1);\n let month = date.toLocaleDateString(localeApp, { month: \"long\" });\n month = month.charAt(0).toUpperCase() + month.slice(1);\n const day = date.toLocaleDateString(localeApp, { day: \"numeric\" });\n const year = date.toLocaleDateString(localeApp, { year: \"numeric\" });\n\n switch (localeApp) {\n case \"es\":\n return `${longDay}, ${day} de ${month} ${year}`;\n\n default:\n return `${longDay}, ${month} ${day}, ${year}`;\n }\n };\n \n const formatDay = (): string => {\n let longDay = date.toLocaleDateString(localeApp, { weekday: \"long\" });\n return longDay.charAt(0).toLowerCase() + longDay.slice(1);\n };\n\n const renderWrappedDay = (\n date: MaterialUiPickersDate,\n selectedDate: MaterialUiPickersDate,\n dayInCurrentMonth: boolean\n ) => {\n const day = new Date(date as Date);\n const selected = new Date(selectedDate as Date);\n const current = new Date();\n current.setHours(0, 0, 0, 0);\n const dayOff = Array.isArray(daysOff) && daysOff.findIndex((dayOff) => dayOff === day.getDay()) !== -1;\n const isCustomRecurrenceDay =\n customRecurrenceWeekDays !== null\n && (customRecurrenceWeekDays & (1 << (day.getDay()))) !== 0;\n \n let disabled = day < current || !appointment?.customerId || dayOff || (isCustomRecurrenceWeekDaysModeChoose && !isCustomRecurrenceDay);\n const isCurrentDate =\n day.getDate() === current.getDate() &&\n day.getMonth() === current.getMonth();\n const isSelected =\n selected.getDate() === day.getDate() &&\n selected.getMonth() === day.getMonth();\n\n return (\n <div className={classes.dateRoot}>\n {dayInCurrentMonth ? (\n <IconButton\n className={`${classes.date} ${\n isCurrentDate ? classes.currentDate : \"\"\n } ${isSelected ? classes.selectedDate : \"\"}`}\n disabled={disabled}\n >\n {day.getDate()}\n </IconButton>\n ) : null}\n </div>\n );\n };\n\n const handleDisabledDay = (date: MaterialUiPickersDate): boolean => {\n const day = new Date(date as Date);\n const current = new Date();\n current.setHours(0, 0, 0, 0);\n const dayOff = Array.isArray(daysOff) && daysOff.findIndex((dayOff) => dayOff === day.getDay()) !== -1;\n const isCustomRecurrenceDay =\n customRecurrenceWeekDays !== null\n && (customRecurrenceWeekDays & (1 << (day.getDay()))) !== 0;\n return day < current || !appointment?.customerId || dayOff || (isCustomRecurrenceWeekDaysModeChoose && !isCustomRecurrenceDay);\n };\n\n const handleChangeDate = (date: MaterialUiPickersDate) => {\n setDate(date as Date);\n setSchedule(undefined);\n };\n\n const handleRecurringAppointment = (event: any) => {\n const checked = event.target.checked;\n setIsRecurringAppointment(checked);\n onRecurringChange?.(0, checked);\n if (!checked) {\n setRecurrenceItemId(null);\n setRecurrenceAfterAppointments(null);\n setIsValidRecurrence(true);\n }\n \n setSchedule(undefined);\n }\n \n const handleCustomSchedule = (event: any) => {\n const checked = event.target.checked;\n setIsCustomSchedule(checked);\n setSchedule(undefined);\n }\n \n function handleChangeScheduleSimultaneousServices(event: any) {\n const checked = event.target.checked;\n setScheduledSimultaneousServices(checked);\n setSchedule(undefined);\n }\n\n const handleRecurrenceSelect = (event: any) => {\n setIsValidRecurrence(true);\n setSchedule(undefined);\n const value = +event.target.value;\n if (value == AppointmentRecurrenceInterval.CustomRecurrenceDefault) {\n setIsValidEndRecurrence(true);\n setCustomRecurrenceModalIsOpen(true);\n return;\n }\n \n if (value == AppointmentRecurrenceInterval.CustomRecurrenceSaved) {\n setIsValidEndRecurrence(true);\n setIsCustomRecurrence(true);\n onRecurringChange?.(customRecurrenceAfterAppointments ?? 0, isRecurringAppointment);\n }\n else {\n setIsCustomRecurrence(false);\n onRecurringChange?.(recurrenceAfterAppointments ?? 0, isRecurringAppointment);\n }\n\n setRecurrenceItemId(value);\n }\n\n const handleBlurRecurrenceSelect = (event: any) => {\n if (customRecurrenceModalIsOpen) {\n return;\n }\n \n const value = event.target.value;\n const isNotValid = value === \"\" || +value < 0;\n if (!isNotValid) {\n setRecurrenceItemId(value);\n }\n setIsValidRecurrence(!isNotValid);\n setSchedule(undefined);\n }\n \n const handleCustomStartTimeChange = (time: moment.Moment) => {\n setCustomStartTime(time);\n setSchedule(undefined);\n };\n\n const handleRecurrenceAfterAppointments = (event: any) => {\n const value = event.target.value.replace(/\\D/g, \"\");\n setRecurrenceAfterAppointments(value);\n }\n\n const handleBlurRecurrencesAfterAppointments = (event: any) => {\n let value = event.target.value;\n const isNotValid = (value === \"\" || +value < 0) || !(value >= 2 && value <= 50);\n if (isNotValid) {\n setRecurrenceAfterAppointments(null);\n }\n setIsValidEndRecurrence(!isNotValid);\n onRecurringChange?.(value, isRecurringAppointment);\n setSchedule(undefined);\n }\n \n const getChosenDaysOfWeek = (weekDaysFlags: WeekDaysFlags): string => {\n const chosenDays = [];\n for (const day in WeekDaysFlags) {\n if (weekDaysFlags & parseInt(day)) {\n chosenDays.push(t(WeekDaysFlags[day]));\n }\n }\n\n return chosenDays.join(\", \");\n };\n \n const handleCustomRecurrenceModalOnSave = (modalData: RecurrenceModalData) => {\n onRecurringChange?.(modalData.customRecurredAppointmentsCount!, isRecurringAppointment);\n setCustomRecurrenceInterval(modalData.customRecurrenceInterval);\n setCustomRecurrenceMode(modalData.customRecurrenceMode);\n setCustomRecurrenceAfterAppointments(modalData.customRecurredAppointmentsCount);\n setCustomRecurrenceWeekDays(modalData.customRecurrenceWeekDays);\n setIsCustomRecurrence(true);\n if (modalData.customRecurrenceWeekDays && modalData.customRecurrenceWeekDays > 0) {\n const currentDayIndex = date.getDay();\n for (let i = 1; i <= 7; i++) {\n const nextAvailableDayIndex = (currentDayIndex + i) % 7; // Cast to day of the week\n const nextAvailableDayFlag = 1 << nextAvailableDayIndex;\n \n if (modalData.customRecurrenceWeekDays & nextAvailableDayFlag) {\n const nextAvailableDate = new Date(date);\n nextAvailableDate.setDate(date.getDate() + i);\n setDate(nextAvailableDate);\n break;\n }\n }\n }\n\n const updatedRecurrenceItems = recurrenceItems.filter(item => item.key !== AppointmentRecurrenceInterval.CustomRecurrenceSaved);\n const modeString = t(CustomRecurrenceMode[modalData.customRecurrenceMode!].toLowerCase());\n const modeStringEnding = localeApp == 'es' && modalData.customRecurrenceMode === CustomRecurrenceMode.Month ? \"es\" : \"s\";\n \n const daysOfWeek = modalData.customRecurrenceWeekDays && modalData.customRecurrenceWeekDays > 0 \n ? ` ${t(\"_the\")} ${getChosenDaysOfWeek(modalData.customRecurrenceWeekDays)}` \n : \"\";\n const afterAppointments = `${t(\"after\")} ${modalData.customRecurredAppointmentsCount} ${t(\"appointments\")}`;\n const recurrenceString = `${t(\"Every\")} ${modalData.customRecurrenceInterval} ${modeString}${modeStringEnding}${daysOfWeek}, ${afterAppointments}`;\n\n updatedRecurrenceItems.push({\n key: AppointmentRecurrenceInterval.CustomRecurrenceSaved,\n value: recurrenceString\n } as SelectItem);\n \n setRecurrenceItems(updatedRecurrenceItems);\n setRecurrenceItemId(AppointmentRecurrenceInterval.CustomRecurrenceSaved);\n setCustomRecurrenceModalIsOpen(false);\n }\n \n function getEstimatedDurations() {\n if (scheduledSimultaneousServices) {\n const services = appointment?.services || []; \n const durations = services.map(service => service?.estimatedDuration ?? 0);\n return Math.max(...durations);\n }\n return ( appointment?.services?.map((service) => service.estimatedDuration).reduce((prev, next) => (prev ? prev : 0) + (next ? next : 0)) || 0 ) ?? 0;\n }\n \n function getDurations() {\n if (scheduledSimultaneousServices) {\n const services = appointment?.services || []; \n const durations = services.map(service => service?.duration ?? 0);\n return Math.max(...durations);\n }\n return appointment?.services.map((service) => service.duration).reduce((prev, next) => (prev ? prev : 0) + (next ? next : 0)) || 0;\n }\n function getCustomEndDate() {\n return moment().utcOffset(0).set({hour:customStartTime.hours(),minute:customStartTime.minutes() + getEstimatedDurations(),second:0,millisecond:0});\n }\n \n return (\n <div\n className={`${classes.root} ${\n !appointment?.customerId || !step1Valid ? classes.disabled : \"\"\n }`}\n >\n <div className={classes.header}>\n <Typography className={classes.stepTitle}>{t(\"STEP 2\")}</Typography>\n </div>\n\n \n <div className={classes.subHeader}>\n <div className={classes.subTitle}>\n <CalendarIcon className={classes.calendarIcon} />\n <Typography className={classes.dateTimeSubTitle}>\n {t(\"Select the date and time of your appointment\")}\n </Typography>\n </div>\n <div className={classes.dateTimeContent}>\n <Typography className={classes.dateTimeTxt}>\n {!appointment?.customerId ? \"--\" : formatDate()} /{\" \"}\n {schedule || \"--\"}\n </Typography>\n </div>\n </div>\n <div className={classes.bodyContent}>\n <div className={classes.calendarScheduler}>\n <div className={classes.calendar}>\n <div className={classes.datePicker}>\n <MuiPickersUtilsProvider\n utils={DateFnsUtils}\n locale={getLocale()}\n >\n <DatePicker\n autoOk\n disableToolbar\n variant=\"static\"\n openTo=\"date\"\n value={date}\n onChange={handleChangeDate}\n disablePast\n renderDay={renderWrappedDay}\n shouldDisableDate={handleDisabledDay}\n disableFuture={!appointment?.customerId}\n />\n </MuiPickersUtilsProvider>\n </div>\n </div>\n <div className={classes.schedule}>\n <Typography className={classes.requiredField}>\n {t(\"Schedules available\")}\n </Typography>\n <div className={`${classes.scheduleContent} ${\n isCustomSchedule ? classes.scheduleDisabled : \"\"\n }`}>\n {!appointment?.customerId || !step1Valid ? (\n <Trans\n className={classes.scheduleInvalid}\n i18nKey=\"AppointmentScheduleNotValidMessage\"\n t={t}\n />\n ) : (\n <ul className={classes.ulSchedule}>\n {(availableHours && availableHours.length) ||\n (Array.isArray(daysOff) &&\n daysOff.length &&\n daysOff.findIndex(\n (dayOff) => dayOff === date.getDay()\n ) !== -1)\n ? availableHours.map((availableHour, index) => (\n <li\n key={index}\n \n className={`${classes.liSchedule} ${\n availableHour === schedule\n ? isCustomSchedule ? \"\" : classes.liScheduleActive\n : \"\"\n }`}\n onClick={() => {\n setSchedule(availableHour);\n }}\n >\n {availableHour}\n </li>\n ))\n : <>\n <div className={classes.calendarNoTime} >\n <CalendarNoTime />\n <Typography className={classes.calendarTitle}>\n {t(\"There are no available times on the selected date.\")}\n </Typography>\n <Typography className={classes.calendarSubTitle}>\n {t(\"Please select another date or specialist.\")}\n </Typography>\n </div>\n </>}\n </ul>\n )}\n </div>\n {accountSettings.scheduleSimultaneousServicesEnabled && services && services?.length > 1 && <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleChangeScheduleSimultaneousServices}\n value={scheduledSimultaneousServices}\n disabled={!step1Valid || (servicesHaveRepeatedUsers && !accountSettings.hasMultipleAppointments)}\n />\n <div className={classes.switchLabel}>\n <label className={classes.switchSubTitle}>\n {t(\"Services performed simultaneously\")}\n </label>\n </div>\n </div>}\n <div className={classes.separator} >\n </div>\n\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleCustomSchedule}\n value={isCustomSchedule}\n disabled={!step1Valid}\n />\n <div className={classes.switchLabel}>\n <label className={classes.switchSubTitle}>\n {t(\"Custom schedule\")}\n </label>\n </div>\n </div>\n {\n isCustomSchedule && <div style={{height: 45, marginTop: 20, display: \"flex\"}}>\n <div >\n <TimePicker\n onOk={(time) => {\n handleCustomStartTimeChange(time);\n }}\n className={classes.selectStyle}\n placeholder=\"HH:mm\"\n inputReadOnly={false}\n showNow={false}\n minuteStep={5}\n value={customStartTime}\n disabled={!step1Valid}\n format={format}\n />\n </div>\n <div style={{marginLeft: 8, marginRight: 8, paddingTop: 6, color: \"#cfc9c4\"}}>\n - \n </div>\n <div >\n <TimePicker\n className={classes.selectStyle}\n placeholder=\"HH:mm\"\n inputReadOnly={true}\n disabled={true}\n value={getCustomEndDate()}\n format={format}\n />\n </div>\n </div>\n }\n <div className={classes.separator} > </div>\n {!isEdition && <>\n <div className={classes.rowContainer} style={{marginTop: 20}}>\n\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleRecurringAppointment}\n value={isRecurringAppointment}\n disabled={!step1Valid}\n />\n <div className={classes.switchLabel}>\n <label className={classes.switchSubTitle}>\n {t(\"Recurring appointment\")}\n </label>\n </div>\n </div>\n \n {\n isRecurringAppointment && step1Valid && <div style={{height: 85, marginTop: 20}}>\n <div style={{display: \"inline-block\", marginRight: 32}}>\n <SelectWithLabel\n label={() => (<>\n {t(\"Recurrence\")} <span className={classes.required}>*</span>\n </>)}\n value={recurrenceItemId}\n placeholder={t(\"Select the recurrence\")}\n styleClass={classes.inputSelect}\n width={312}\n itemRootClass={classes.itemRoot}\n isValid={() => isValidRecurrence}\n name=\"recurrenceId\"\n showTooltip={true}\n onChange={handleRecurrenceSelect}\n onBlur={handleBlurRecurrenceSelect}\n items={recurrenceItems || []}\n />\n </div>\n <div style={{display: \"inline-block\", opacity: isCustomRecurrence ? 0.5 : 1}}>\n <div style={{position: \"relative\", top: 0}} >\n\n <div className={classes.label} style={{paddingTop: 10}}>\n {t(\"Recurrence end\")} <span className={classes.required}>*</span>\n </div>\n\n <div style={{display: \"inline-block\"}}>\n <span className={classes.labelAppointment}>\n {t(\"After\")} \n </span>\n </div>\n\n <div style={{display: \"inline-block\", position: \"relative\", top: 0, left: 20}}>\n <Input\n type={\"text\"}\n disabled={!isRecurringAppointment || isCustomRecurrence}\n value={isCustomRecurrence ? \"\" : recurrenceAfterAppointments}\n isValid={() => isValidEndRecurrence}\n width={60}\n onChange={handleRecurrenceAfterAppointments}\n onBlur={handleBlurRecurrencesAfterAppointments}\n />\n <span className={classes.labelAppointment} style={{marginLeft: 10}}>\n {t(\"appointments\")}\n </span>\n </div>\n\n </div>\n </div>\n\n </div>\n }\n </div>\n </>}\n <br></br>\n </div>\n </div>\n </div>\n <CustomRecurrenceModal\n isOpen={customRecurrenceModalIsOpen}\n handleClose={() => setCustomRecurrenceModalIsOpen(false)}\n handleConfirm={handleCustomRecurrenceModalOnSave}\n />\n </div>\n \n );\n};\n\nexport default AppointmentStepTwo;\n","export enum Gender {\n Male = 1,\n Female,\n PreferNotToSay,\n Custom,\n}\n","import React, { useState, useEffect } from \"react\";\n\nimport MuiAutocomplete from \"@material-ui/lab/Autocomplete\";\n\nimport InputSearch from \"./../InputSearch\";\nimport useDebounce from \"./../../../hooks/useDebounce\";\n\nimport { AutocompleteProps } from \"./props\";\n\nconst Autocomplete = (props: AutocompleteProps) => {\n const {\n id,\n style,\n items,\n placeholder,\n noBorder,\n getOptionSelected,\n getOptionLabel,\n renderOption,\n filterOptions,\n cleanInput,\n onChange,\n onSelected,\n } = props;\n\n const [open, setOpen] = useState<boolean>(false);\n const [inputValue, setInputValue] = useState<string>(\"\");\n const [changeReason, setChangeReason] = useState<\n \"input\" | \"reset\" | \"clear\" | \"\"\n >(\"\");\n\n const debouncedInputValue = useDebounce(inputValue, 400);\n\n useEffect(() => {\n if (onChange) {\n onChange(debouncedInputValue, changeReason);\n }\n if (inputValue) {\n setOpen(true);\n }\n\n if (changeReason === \"reset\") {\n setOpen(false);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [debouncedInputValue]);\n\n useEffect(() => {\n setInputValue(\"\");\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [cleanInput]);\n\n return (\n <MuiAutocomplete\n freeSolo\n id={id || \"auto-complete\"}\n style={style}\n autoComplete\n autoHighlight\n open={open}\n onOpen={() => {\n if (inputValue) {\n setOpen(true);\n }\n }}\n inputValue={inputValue}\n onInputChange={(e, value, reason) => {\n setChangeReason(reason);\n setInputValue(value);\n if (!value) {\n setOpen(false);\n }\n }}\n onClose={() => {\n setOpen(false);\n }}\n onChange={(e, value) => {\n if (onSelected) {\n onSelected(value);\n }\n }}\n getOptionSelected={getOptionSelected}\n getOptionLabel={getOptionLabel}\n options={items}\n renderOption={renderOption}\n filterOptions={filterOptions}\n renderInput={(params) => (\n <InputSearch\n {...params}\n placeholder={placeholder}\n noBorder={noBorder}\n />\n )}\n />\n );\n};\n\nexport default Autocomplete;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n \n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n\n component: {\n zIndex: 2,\n position: \"relative\",\n left: 0\n },\n labelCountry: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n required: {\n color: \"#6462F3\",\n fontFamily: \"Roboto, sans-serif\"\n },\n optional: {\n fontWeight: \"normal\",\n },\n searchInputContainer: {\n position: \"relative\",\n padding: \"0 15px 10px 15px\",\n width: \"-webkit-fill-available\"\n },\n searchIconContainer: {\n position: \"absolute\",\n top: 7,\n right: 21\n },\n divDropdown: {\n // cursor: \"pointer\",\n width: 350,\n display: \"block\",\n marginTop: -7,\n height: 70,\n position: \"relative\"\n },\n inputSelectBtn: {\n // cursor: \"pointer\",\n // pointerEvents: \"none\"\n width: 300,\n paddingLeft: 100,\n \"& input\": {\n marginLeft: 90,\n width: 140,\n\n }\n },\n titleCountries: {\n fontSize: 12,\n fontStyle: \"normal\",\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: \"bold\",\n color: \"#919ca5\",\n textAlign: \"left\",\n margin: \"15px auto 10px 15px\",\n },\n divDialCode: {\n position: \"relative\",\n top: 0.5,\n left: 18,\n display: \"inline\",\n // color: \"#5C6477\",\n fontSize: 12,\n fontStyle: \"normal\",\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n iconDropdown: {\n cursor: \"pointer\",\n display: \"inline\",\n textAlign: \"left\",\n position: \"relative\",\n top: -1,\n left: 15,\n \"& svg\": {\n width: 24, \n height: 24,\n }\n },\n inputFlag: {\n display: \"inline\",\n position: \"relative\",\n top: -2,\n left: 12,\n height: 20,\n width: 20,\n \"& svg\": {\n width: \"20px !important\", \n height: \"20px !important\"\n }\n },\n divCodes: {\n cursor: \"pointer\",\n position: \"relative\",\n top: -32,\n left: 0,\n width: 90,\n // pointerEvents: \"none\"\n },\n divModalSelect: {\n backgroundColor: \"#FFFFFF\",\n padding: \"0px\", \n border: \"1px solid #DBDCDD\",\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n width: 350,\n textAlign: \"center\",\n position: \"absolute\",\n top: 20\n },\n listCountryScroll: {\n overflowY: \"scroll\",\n \"&::-webkit-scrollbar\": {\n backgroundColor: theme.colors.white,\n width: 16,\n },\n \"&::-webkit-scrollbar-track\": {\n backgroundColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-track:hover\": {\n backgroundColor: \"#F4F4F4\",\n width: 16,\n },\n \"&::-webkit-scrollbar-thumb\": {\n backgroundColor: \"#babac0\",\n \n border: \"solid\",\n borderRadius: 16,\n borderWidth: 5,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-thumb:hover\": {\n backgroundColor: \"#a0a0a5\",\n \n border: \"solid\",\n borderWidth: 4,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-button\": {\n display: \"none\",\n },\n },\n listCountry: {\n padding: \"5px 0\",\n \"&:first-child\": {\n paddingTop: 10,\n },\n borderBottom: \"1px solid #F6F6F6\",\n marginBottom: 0,\n //maxHeight: 200,\n //overflow: \"hidden\",\n //overflowY: \"auto\"\n },\n countryName: {\n textAlign: \"left\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\",\n width: \"75%\",\n overflow: \"hidden\",\n display: \"inline-block\",\n paddingTop: \"1px\",\n height: 40\n },\n button: {\n width: 300,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#786EFF\",\n border: \"1px solid #786EFF\",\n\n },\n elementList: {\n height: 35,\n padding: \"5px 5px 10px 10px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n display: \"flex\",\n color: Color.gray5,\n },\n divInputEdit: {\n margin: \"auto\",\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n input: {\n marginLeft: \"auto\",\n \"& input\": {\n width: 250,\n }\n },\n inputClassic: {\n marginLeft: 85,\n border: \"none\",\n width: 135,\n height: 38,\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n opacity: \"0.42\",\n },\n padding: \"13px 0px 13px 12px\",\n borderRadius: 5,\n \"&:focus\": {\n border: \"none\",\n padding: \"14px 0px 14px 12px\",\n width: 135,\n \"&$inputError\": {\n color: theme.colors.clearRed,\n border: \"none\",\n },\n },\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"none\",\n padding: \"14px 0px 14px 12px\",\n width: 135,\n \"&$inputError\": {\n color: theme.colors.clearRed,\n border: \"none\",\n },\n },\n },\n iconPlus: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n inputError: {\n color: `${theme.colors.clearRed} !important`,\n border: `solid 1px ${theme.colors.clearRed} !important`,\n \"& input\": {\n color: `${theme.colors.clearRed} !important`,\n },\n // \"& div\": {\n // color: `${theme.colors.clearRed} !important`,\n // }\n },\n iconSave: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n divItemEdit: {\n height: 32,\n display: \"block\"\n },\n btnInputNew: {\n height: 32,\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n classRow: {\n cursor: \"pointer\",\n \"& button\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n backgroundColor: \"#e1e9fe\",\n \"& button\": {\n visibility: \"visible\"\n }\n }\n },\n btnRow: {\n width: 32,\n height: 32,\n borderRadius: 51,\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\",\n border: \"none\",\n padding: 0,\n margin: 0,\n backgroundColor: \"transparent\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n divIconsRow: {\n right: 0,\n textAlign: \"center\",\n marginLeft: \"auto\",\n float: \"right\",\n paddingTop: 0\n\n },\n inputGroup: {\n height: 40,\n backgroundColor: \"#f6f6f6\",\n borderRadius: 5,\n border: \"1px solid #dddddd\"\n },\n\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport MaskedInput, { conformToMask } from \"react-text-mask\";\n\nimport { SearchIcon, SortDownIcon } from \"./../../../assets/icons\";\nimport CountryFlagIcon from \"./../../../assets/flags\";\nimport Country from \"../../../models/country\";\nimport CountryService from \"../../../api/country-service\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport { InputMobileCodeProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport Input from \"../Input\";\n\n\nconst InputMobileCode = (props: InputMobileCodeProps) => {\n\n const dialTemplate: string = \"000-000-0000\";\n const { t } = useTranslation([\"general\"]);\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const { label, widthSelect, widthList, heigthList, isOptional,\n labelClass, requiredDotClass,\n codeIso3, mobile,\n isValid, onChangeItem, onChangeMobile, onChangeComplete, onBlur, setSmbPhoneNumber\n } = props;\n const classes = useStyles();\n\n const [openModal, setOpenModal] = useState<boolean>(false);\n\n const [countries, setCountries] = useState<Country[]>([]);\n const [countrySelected, setCountrySelected] = useState<Country>(new Country({\n iso3: \"MEX\", dialCode: 52, dialDigits: 10, dialTemplate: dialTemplate, name: \"México\"\n }));\n const [mobileNumber, setMobileNumber] = useState<string>(mobile!);\n const [searchValue, setSearchValue] = useState<string | null>(null);\n const [masking, setMasking] = useState<any>(GetMobileMaskByTemp(dialTemplate));\n const [isValidNumber, setIsValidNumber] = useState<boolean>(true);\n\n const itemSelected = (item: Country) => {\n setSearchValue(null);\n let country = new Country({\n iso3: item.iso3,\n name: item.name,\n dialCode: item.dialCode,\n dialDigits: item.dialDigits,\n dialTemplate: item.dialTemplate\n });\n\n // setIso3(country.iso3);\n setCountrySelected(country);\n setOpenModal(false);\n\n let newNumber: string;\n if (mobileNumber) {\n newNumber = mobileNumber.substring(0, country.dialDigits || 10);\n setMobileNumber(newNumber);\n } else {\n newNumber = mobileNumber;\n }\n\n // setCodeNumber(item.dialCode.toString());\n const m = GetMobileMaskByTemp(country.dialTemplate || dialTemplate);\n setMasking(m);\n\n if (onChangeItem)\n onChangeItem(country);\n\n const valid = validate(newNumber, country.dialDigits);\n\n if (onChangeComplete)\n onChangeComplete(country.iso3, newNumber, valid);\n }\n\n const handleMobileChange = (event: React.ChangeEvent<{ value: string }>) => {\n const mobile = event.target.value.replace(/[^0-9]/g, \"\");\n\n setMobileNumber(mobile);\n if (onChangeMobile) onChangeMobile(mobile);\n\n const valid = validate(mobile, countrySelected?.dialDigits);\n\n if (onChangeComplete)\n onChangeComplete(countrySelected.iso3, mobile, valid);\n };\n\n const validate = (mobileComplete: string, digits: number): boolean => {\n let validDig = false;\n\n if (mobileComplete) {\n const mobile = mobileComplete.replace(/[^0-9]/g, \"\");\n validDig = (digits === 7 && /^\\d{7}$/.test(mobile!)) ||\n (digits === 8 && /^\\d{8}$/.test(mobile!)) ||\n (digits === 9 && /^\\d{9}$/.test(mobile!)) ||\n (digits === 10 && /^\\d{10}$/.test(mobile!)) ||\n (digits === 11 && /^\\d{11}$/.test(mobile!)) ||\n (digits === 12 && /^\\d{12}$/.test(mobile!));\n\n setIsValidNumber(validDig);\n if (isValid)\n isValid(validDig);\n }\n if (!isOptional && !mobileComplete) {\n if (isValid)\n isValid(false);\n setIsValidNumber(false);\n }\n\n return validDig;\n }\n\n useEffect(() => {\n\n (async () => {\n const listCountries: Country[] = accountSettings.countries;\n const countryInSettings: Country = accountSettings.countryInSettings;\n\n setCountries(listCountries || []);\n let iso = codeIso3 || (countryInSettings ? countryInSettings.iso3 : null) || \"MEX\";\n\n const countryByIso = listCountries.filter(x => x.iso3 === iso);\n\n if (countryByIso.length > 0) {\n const country = countryByIso[0];\n setCountrySelected(country);\n const m = GetMobileMaskByTemp(country.dialTemplate || dialTemplate);\n setMasking(m);\n }\n\n })();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [codeIso3]);\n\n\n useEffect(() => {\n\n if (mobile) {\n setMobileNumber(mobile);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [mobile]);\n\n useEffect(() => {\n if (setSmbPhoneNumber)\n setSmbPhoneNumber(\"+\" + countrySelected.dialCode + mobile);\n }, [mobile, countrySelected]);\n\n const handleOpenModal = () => {\n setOpenModal(true);\n }\n \n function handleSearch(searchValue: string) {\n setSearchValue(searchValue);\n }\n \n function filterCountries (item: Country) {\n const lowercaseSearchValue = searchValue!.toLowerCase();\n let isSearchByDialCode = /^\\+?\\d+$/.test(searchValue!);\n \n if (searchValue!.trim().length < 2 && !isSearchByDialCode) {\n return true;\n }\n \n return (\n item.name.toLowerCase().includes(lowercaseSearchValue) ||\n item.dialCode.toString().startsWith(lowercaseSearchValue.replace(\"+\", \"\"))\n );\n }\n\n const handleCloseModal = () => {\n setSearchValue(null);\n setOpenModal(false);\n }\n\n return (<div className={classes.component}>\n\n <div className={classes.divDropdown} style={{ width: widthSelect || 350 }} >\n\n <label className={labelClass ?? classes.labelCountry}>\n <Typography className={labelClass ?? classes.labelCountry}>\n {label || t(\"Mobile\") + \" \"}\n {(isOptional ?? true) ?\n <span className={classes.optional}>({t(\"Optional\")})</span>\n :\n <span className={requiredDotClass ?? classes.required}>*</span>\n }\n </Typography >\n </label>\n\n <div className={`${classes.inputGroup} ${!isValidNumber ? classes.inputError : \"\"}`} >\n <MaskedInput\n className={`${classes.inputClassic} ${classes.inputSelectBtn} `}\n placeholder={countrySelected?.dialTemplate || dialTemplate}\n mask={masking}\n placeholderChar=\" \"\n onChange={handleMobileChange}\n onBlur={() => { if (onBlur) onBlur(validate(mobileNumber, countrySelected?.dialDigits)) }}\n value={mobileNumber}\n />\n\n <div className={classes.divCodes} onClick={handleOpenModal} >\n <div className={classes.inputFlag}>\n <CountryFlagIcon iso={countrySelected?.iso3 || \"MEX\"} />\n </div>\n <div className={classes.iconDropdown} >\n <SortDownIcon />\n </div>\n <div className={classes.divDialCode}>\n {countrySelected.dialCode !== undefined ? `+${countrySelected.dialCode}` : \"+52\"}\n </div>\n </div>\n\n </div>\n </div>\n\n <Modal\n open={openModal}\n onClose={handleCloseModal}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n disablePortal={true}\n style={{ position: \"relative\", top: -20 }} >\n\n <div className={classes.divModalSelect} style={{ width: widthList || 350, maxHeight: heigthList ? heigthList + 10 : 310 }}>\n <div className={classes.titleCountries} >{t(\"Countries\")}</div>\n <div className={classes.searchInputContainer}>\n <Input\n placeholder={t(\"Search country code\")}\n width={\"-webkit-fill-available\"}\n onChange={(event) => handleSearch(event.target.value)}\n />\n <div className={classes.searchIconContainer}><SearchIcon\n style={{ fontSize: 17, color: \"#919CA5\" }}/></div>\n </div>\n <div className={classes.listCountryScroll} style={{ maxHeight: heigthList ? heigthList - 10 : 214 }}>\n {(searchValue === null \n ? countries \n : countries.filter((item) => filterCountries(item)))\n .map((item) => (\n <div key={item.iso3} className={classes.listCountry}>\n <div className={`${classes.elementList} ${classes.classRow}`}\n onClick={() => itemSelected(item)}>\n <span style={{ marginRight: 10 }}>\n <CountryFlagIcon iso={item.iso3}/>\n </span>\n <div className={classes.countryName}>\n {item.name} (+{item.dialCode})\n </div>\n </div>\n </div>\n ))}\n </div>\n\n </div>\n </Modal>\n\n\n\n </div>);\n};\n\nexport default InputMobileCode;\n","import { Gender } from \"./enums/gender\";\nexport class CustomerEntity {\n id?: string;\n firstName: string;\n lastName: string;\n birthDate?: Date;\n mobileCodeIso3: string | null;\n mobileDigits: number | null;\n mobileCode: number | null;\n mobileTemplate: string | null;\n mobile: string;\n email?: string;\n gender?: Gender;\n customGender: string | null;\n contactableAppointments: boolean;\n contactableMassiveSendings: boolean;\n isMobileDuplicate: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.birthDate = x.birthDate ? new Date(x.birthDate) : undefined;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileDigits = x.mobileDigits;\n this.mobileCode = x.mobileCode;\n this.mobileTemplate = x.mobileTemplate;\n this.mobile = x.mobile;\n this.email = x.email;\n this.gender = x.gender;\n this.customGender = x.customGender;\n this.contactableAppointments = x.contactableAppointments;\n this.contactableMassiveSendings = x.contactableMassiveSendings;\n this.isMobileDuplicate = x.isMobileDuplicate;\n } else {\n this.id = undefined;\n this.firstName = \"\";\n this.lastName = \"\";\n this.birthDate = undefined;\n this.mobileCodeIso3 = null;\n this.mobileDigits = null;\n this.mobileCode = null;\n this.mobileTemplate = null;\n this.mobile = \"\";\n this.email = undefined;\n this.gender = undefined;\n this.customGender = null;\n this.contactableAppointments = true;\n this.contactableMassiveSendings = true;\n this.isMobileDuplicate = false;\n }\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n legend: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n marginTop: 24,\n },\n required: {\n color: \"#6462F3\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n fieldsContainer: {\n display: \"flex\",\n flexWrap: \"wrap\",\n justifyContent: \"space-between\",\n \"& > div\": {\n marginTop: 24\n }\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n display: \"flex\",\n margin: 0,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n description: {\n margin: 0,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n required: {\n color: \"#6462F3\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n display: \"flex\",\n margin: 0,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n description: {\n margin: 0,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n infoContentRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n caption: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n width: 228,\n margin: \"0px\",\n },\n captionValue: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n width: 228,\n margin: \"0px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Switch from \"../../common/Switch\";\nimport { CustomerEntity } from \"../../../models/customer-entity\";\n\nimport useStyles from \"./css\";\nimport { CustomerNotificationsProps } from \"./props\";\n\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport { Typography } from \"@material-ui/core\";\n\n\nconst CustomerNotifications = (props: CustomerNotificationsProps) => {\n const { t } = useTranslation([\"general\"]);\n const { value, isEdition, onChange } = props;\n const [customer, setCustomer] = useState<CustomerEntity>(\n value || new CustomerEntity()\n );\n\n const appointmentDescription = useCustomerTerminology(t(\"The customer will receive automatic notifications such as: Appointments, reminders, etc.\"), \"customer\");\n const massiveSendingsDescription = useCustomerTerminology(t(\"The customer will receive automated Massive sending messages.\"), \"customer\");\n\n useEffect(() => {\n if (value && JSON.stringify(value) !== JSON.stringify(customer)) {\n setCustomer(value);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [value]);\n\n useEffect(() => {\n if (onChange) {\n onChange(customer);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [customer]);\n\n const handleContactableAppointmentsChange = (\n event: React.ChangeEvent<{ checked: unknown }>\n ) => {\n setCustomer(\n new CustomerEntity({ ...customer, contactableAppointments: event.target.checked })\n );\n };\n\n const handleContactableMassiveSendingsChange = (\n event: React.ChangeEvent<{ checked: unknown }>\n ) => {\n setCustomer(\n new CustomerEntity({ ...customer, contactableMassiveSendings: event.target.checked })\n );\n };\n\n\n const classes = useStyles();\n return (\n <div className={classes.root}>\n {isEdition ?\n <>\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n onChange={handleContactableAppointmentsChange}\n value={customer?.contactableAppointments}\n />\n <div className={classes.switchLabel}>\n <label className={classes.label}>\n {t(\"Appointment\")}{\" \"}\n </label>\n <p className={classes.description}>\n {appointmentDescription}\n </p>\n </div>\n </div>\n </div>\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n onChange={handleContactableMassiveSendingsChange}\n value={customer?.contactableMassiveSendings}\n />\n <div className={classes.switchLabel}>\n <label className={classes.label}>\n {t(\"Massive sendings\")}{\" \"}\n </label>\n <p className={classes.description}>\n {massiveSendingsDescription}\n </p>\n </div>\n </div>\n </div>\n </> :\n <>\n <div className={classes.infoContentRow}>\n <div>\n <Typography className={classes.caption}>\n {t(\"Appointment\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {customer.contactableAppointments ? t(\"Yes\") : t(\"No\")}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Massive sendings\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {customer.contactableMassiveSendings ? t(\"Yes\") : t(\"No\")}\n </Typography>\n </div>\n <div><div className={classes.caption}></div></div>\n </div>\n </>}\n </div>\n );\n};\n\nexport default CustomerNotifications;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport InputMobileCode from \"../../common/InputMobileCode\";\nimport InputWithLabel from \"../../common/InputWithLabel\";\nimport InputDateWithLabel from \"../../common/InputDateWithLabel\";\nimport SelectWithLabel from \"../../common/SelectWithLabel\";\nimport { CustomerEntity } from \"../../../models/customer-entity\";\n\nimport useStyles from \"./css\";\nimport { CustomerGeneralProps, CustomerValid } from \"./props\";\n\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport { EmailRegex, MultipleSpacesNameRegex } from \"../../../constants/validator\";\nimport Country from \"../../../models/country\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport CustomerNotifications from \"../CustomerNotifications\";\nimport { Gender } from \"../../../models/enums/gender\";\n\n\nconst CustomerGeneral = (props: CustomerGeneralProps) => {\n const appDispatch = useAppDispatch();\n const { t } = useTranslation([\"general\"]);\n const { value, isEdition, mobilePhoneDuplicated, isModal, onChange } = props;\n const [isDuplicated, setIsDuplicated] = useState<boolean>(false);\n const [customer, setCustomer] = useState<CustomerEntity>(\n value || new CustomerEntity()\n );\n\n const minBirthDate = new Date(1900, 0);\n const yesterdayDate = new Date(new Date().setDate(new Date().getDate() - 1));\n\n const runValidations = (): CustomerValid | undefined => {\n if (value) {\n return {\n firstName: MultipleSpacesNameRegex.test(value.firstName),\n lastName: MultipleSpacesNameRegex.test(value.lastName),\n email: !value.email ? undefined : EmailRegex.test(value.email),\n customGender: value.gender !== Gender.Custom || !!value.customGender && MultipleSpacesNameRegex.test(value.customGender)\n };\n }\n\n return undefined;\n };\n const [customerValid, setCustomerValid] = useState<CustomerValid | undefined>(\n runValidations()\n );\n\n useEffect(() => {\n if (mobilePhoneDuplicated) setIsDuplicated(mobilePhoneDuplicated)\n }, [mobilePhoneDuplicated]);\n\n\n useEffect(() => {\n if (value && JSON.stringify(value) !== JSON.stringify(customer)) {\n setCustomer(value);\n }\n\n runValidations();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [value]);\n\n useEffect(() => {\n if (onChange && customerValid) {\n onChange(customer, true);\n } else if (onChange) {\n onChange(customer, false);\n }\n setIsDuplicated(false);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [customer]);\n\n const handleFirstNameChange = (\n event: React.ChangeEvent<{ value: string }>\n ) => {\n setCustomerValid({\n ...customerValid,\n firstName: MultipleSpacesNameRegex.test(event.target.value),\n });\n setCustomer(\n new CustomerEntity({ ...customer, firstName: event.target.value })\n );\n updateCustomerNameHeaderTitleNav(event.target.value, \"\");\n };\n\n const handleLastNameChange = (\n event: React.ChangeEvent<{ value: string }>\n ) => {\n setCustomerValid({\n ...customerValid,\n lastName: MultipleSpacesNameRegex.test(event.target.value),\n });\n setCustomer(\n new CustomerEntity({ ...customer, lastName: event.target.value })\n );\n updateCustomerNameHeaderTitleNav(\"\", event.target.value);\n };\n\n const updateCustomerNameHeaderTitleNav = (\n firstName: string,\n lastName: string\n ) => {\n if (isEdition) {\n if (!firstName) firstName = customer.firstName;\n if (!lastName) lastName = customer.lastName;\n let titleNav = t(\"Customer detail\") + \" / \" + firstName + \" \" + lastName;\n appDispatch(applicationInterfaceActions.updateTitle(titleNav));\n }\n };\n\n const handleBirthdayChange = (date: Date) => {\n if (date) {\n const birthdate = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 0, 0, 0, 0);\n setCustomer(\n new CustomerEntity({\n ...customer,\n birthDate: birthdate,\n })\n );\n }\n };\n\n const handleGenderChange = (event: React.ChangeEvent<{ value: unknown }>) => {\n setCustomer(\n new CustomerEntity({ ...customer, gender: event.target.value })\n );\n };\n \n const handleCustomGenderChange = (event: React.ChangeEvent<{ value: string | null }>) => {\n setCustomerValid({\n ...customerValid,\n customGender: customer.gender !== Gender.Custom || MultipleSpacesNameRegex.test(event.target.value || \"\"),\n });\n setCustomer(\n new CustomerEntity({ ...customer, customGender: event.target.value })\n );\n };\n\n const handleEmailChange = (event: React.ChangeEvent<{ value: string }>) => {\n const email = event.target.value ? event.target.value : undefined;\n setCustomerValid({\n ...customerValid,\n email: email ? EmailRegex.test(email.toLowerCase()) : undefined,\n });\n setCustomer(new CustomerEntity({ ...customer, email: email }));\n };\n\n const handleMobileChange = (num: any) => {\n setCustomer(\n new CustomerEntity({\n ...customer,\n mobile: num,\n })\n );\n };\n \n const handleMobileCodeChange = (c: Country) => {\n setCustomer(\n new CustomerEntity({\n ...customer,\n mobileCodeIso3: c.iso3,\n mobileCode: c.dialCode,\n mobileDigits: c.dialDigits,\n mobileTemplate: c.dialTemplate\n })\n );\n setIsDuplicated(false);\n };\n\n const handlerCustomerNotificationsChange = (customerEntity: CustomerEntity) => {\n setCustomer(customerEntity);\n };\n\n const handleValidMobile = (valid: boolean) => {\n setCustomerValid({\n ...customerValid,\n mobilePhone: valid && !isDuplicated\n });\n }\n\n const classes = useStyles();\n return (\n <div className={classes.root}>\n <label className={classes.legend}>\n {t(\"Required fields\")} <span className={classes.required}>*</span>\n </label>\n <div className={classes.fieldsContainer}>\n <InputWithLabel\n label={() => (\n <>\n {t(\"Name\")} <span className={classes.required}>*</span>\n </>\n )}\n value={customer?.firstName}\n placeholder={useCustomerTerminology(t(\"Enter the names of the customer\"), \"customer\")}\n width={228}\n isValid={() => customerValid?.firstName}\n onChange={handleFirstNameChange}\n />\n <InputWithLabel\n label={() => (\n <>\n {t(\"Last names\")} <span className={classes.required}>*</span>\n </>\n )}\n placeholder={useCustomerTerminology(t(\"Enter the last names of the customer\"), \"customer\")}\n value={customer?.lastName}\n width={228}\n isValid={() => customerValid?.lastName}\n onChange={handleLastNameChange}\n />\n\n {isModal ? \n <div style={{zIndex: 1001}} >\n <InputMobileCode \n isOptional={false} \n widthSelect={228} \n widthList={isModal ? 260 : 250}\n isValid={handleValidMobile}\n onChangeItem={handleMobileCodeChange}\n onChangeMobile={handleMobileChange}\n codeIso3={customer.mobileCodeIso3!}\n mobile={customer.mobile!} />\n </div>\n : \n <InputDateWithLabel\n label={() => (\n <>\n {t(\"Birth date\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n width={228}\n placeholder={t(\"dd/mm/yy\")}\n value={customer.birthDate}\n onChange={handleBirthdayChange}\n minDate={minBirthDate}\n maxDate={yesterdayDate}\n />\n }\n <SelectWithLabel\n label={() => (\n <>\n {t(\"Gender\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n items={[\n { key: 1, value: t(\"Male\") },\n { key: 2, value: t(\"Female\") },\n { key: 3, value: t(\"I prefer not to say\") },\n { key: 4, value: t(\"gender_custom\") },\n ]}\n placeholder={t(\"Select the gender\")}\n width={228}\n onChange={handleGenderChange}\n value={customer?.gender}\n />\n {customer.gender === Gender.Custom &&\n <InputWithLabel\n label={() => (\n <>\n {t(\"Custom gender\")} <span className={classes.required}>*</span>\n </>\n )}\n placeholder={t(\"Enter custom gender\")}\n width={228}\n isValid={() => customerValid?.customGender}\n onChange={handleCustomGenderChange}\n value={customer?.customGender || \"\"}\n maxLength={60}\n />\n }\n <InputWithLabel\n label={() => (\n <>\n {t(\"Email\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n placeholder={useCustomerTerminology(t(\"Enter the email of the customer\"), \"customer\")}\n width={228}\n isValid={() => customerValid?.email}\n onChange={handleEmailChange}\n value={customer?.email || \"\"}\n />\n {isModal ? \n <InputDateWithLabel\n label={() => (\n <>\n {t(\"Birth date\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n width={228}\n placeholder={t(\"dd/mm/yy\")}\n value={customer.birthDate}\n onChange={handleBirthdayChange}\n minDate={minBirthDate}\n maxDate={yesterdayDate}\n />\n :\n <div style={{zIndex: 1001}} >\n <InputMobileCode \n isOptional={false} \n widthSelect={228} \n widthList={isModal ? 260 : 250}\n isValid={handleValidMobile}\n onChangeItem={handleMobileCodeChange}\n onChangeMobile={handleMobileChange}\n codeIso3={customer.mobileCodeIso3!}\n mobile={customer.mobile!} />\n </div>\n }\n\n </div>\n {isModal ?\n <CustomerNotifications\n onChange={handlerCustomerNotificationsChange}\n value={new CustomerEntity(customer)}\n isEdition={true}\n />\n : <></>}\n </div>\n );\n};\n\nexport default CustomerGeneral;\n","export enum SectionFieldType {\n //Additional validation\n PhoneNumber = 11,\n Email = 12,\n\n //Controls\n Radio = 21,\n Checkbox = 22, //NOT IN USE\n Dropdown = 23, //NOT IN USE\n\n //Basic\n Text = 31,\n Numeric = 32, //NOT IN USE\n Date = 33 //NOT IN USE\n}","import { CustomerFrequencyType } from \"./enums/customer-frequency-type\";\n\nexport class CustomerData {\n name: string | null;\n birthDate: Date | null;\n frequencyType: CustomerFrequencyType;\n appointments: number | null;\n attended: number | null;\n services: number | null;\n serviceName: string | null;\n servicePrice: number | null;\n serviceTimes: number | null;\n created: Date;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.name = x.name;\n this.birthDate = x.birthDate;\n this.frequencyType = x.frequencyType;\n this.appointments = x.appointments;\n this.attended = x.attended;\n this.services = x.services;\n this.serviceName = x.serviceName;\n this.servicePrice = x.servicePrice;\n this.serviceTimes = x.serviceTimes;\n this.created = x.created;\n } else {\n this.name = null;\n this.birthDate = null;\n this.frequencyType = CustomerFrequencyType.Inactive;\n this.appointments = null;\n this.attended = null;\n this.services = null;\n this.serviceName = null;\n this.servicePrice = null;\n this.serviceTimes = null;\n this.created = new Date();\n }\n }\n}\n","import { Customer } from \"./customer\";\nexport class CustomersResponse {\n customers: Customer[] | null;\n totalCustomers: number | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.customers = x.customers;\n this.totalCustomers = x.totalCustomers;\n } else {\n this.customers = null;\n this.totalCustomers = null;\n }\n }\n}\n","import { EmergencyContact } from \"./emergency-contact\";\nimport { CustomerEntity } from \"./customer-entity\";\n\nexport class CustomerInfoDetails extends CustomerEntity {\n notes: string | null;\n emergencyContacts: EmergencyContact[] | null;\n constructor(x?: any) {\n super(x);\n if (typeof x === \"object\") {\n this.notes = x.notes;\n this.emergencyContacts = x.emergencyContacts;\n } else {\n this.notes = null;\n this.emergencyContacts = null;\n }\n }\n}\n","import { CustomerLastAppointment } from \"./customer-appointment\";\n\nexport class CustomerSearch {\n id: string | null;\n firstName: string | null;\n lastName: string | null;\n mobile: string | null;\n email: string | null;\n mobileCodeIso3: string | null;\n mobileDigits: string | null;\n mobileCode: string | null;\n mobileTemplate: string | null;\n appointments: CustomerLastAppointment[] | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.mobile = x.mobile;\n this.email = x.email;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileDigits = x.mobileDigits;\n this.mobileCode = x.mobileCode;\n this.mobileTemplate = x.mobileTemplate;\n this.appointments = x.appointments;\n } else {\n this.id = null;\n this.firstName = null;\n this.lastName = null;\n this.mobile = null;\n this.email = null;\n this.mobileCodeIso3 = null;\n this.mobileDigits = null;\n this.mobileCode = null;\n this.mobileTemplate = null;\n this.appointments = null;\n }\n }\n}\n","import { AppointmentStatus } from \"./enums/appointment-status\";\nimport { AppointmentPaymentStatus } from \"./enums/appointment-payment-status\";\n\n\nexport default class CustomerHistory {\n yearMonth: number;\n monthYear: string;\n appointments: CustomerApptsHistory[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.yearMonth = x.yearMonth;\n this.monthYear = x.monthYear;\n this.appointments = x.appointments;\n } else {\n this.yearMonth = 0;\n this.monthYear = \"\";\n this.appointments = [];\n }\n }\n}\n\n\nexport class CustomerApptsHistory {\n id: string;\n status: AppointmentStatus;\n paymentStatus: AppointmentPaymentStatus;\n recurringAppointmentCount: number | null;\n recurringAppointmentOrder: number | null;\n services: CustomerApptsServicesHistory[]\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.services = x.services;\n this.paymentStatus = x.paymentStatus;\n this.status = x.status;\n this.recurringAppointmentCount = x.recurringAppointmentCount;\n this.recurringAppointmentOrder = x.recurringAppointmentOrder;\n } else {\n this.id = \"\";\n this.status = 0;\n this.paymentStatus = AppointmentPaymentStatus.Unpaid;\n this.services = [];\n this.recurringAppointmentCount = null;\n this.recurringAppointmentOrder = null;\n }\n }\n}\n\n\nexport class CustomerApptsServicesHistory {\n id: string; \n name: string;\n specialist: string;\n start: Date;\n end: Date;\n duration: number;\n price: number | null;\n statusId: AppointmentStatus;\n notes: string;\n hasEvolutionNotes: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.serviceId;\n this.name = x.name;\n this.specialist = x.specialist;\n this.start = x.start;\n this.end = x.end;\n this.duration = x.duration;\n this.price = x.price;\n this.statusId = x.statusId;\n this.notes = x.notes || \"\";\n this.hasEvolutionNotes = x.hasEvolutionNotes;\n } else {\n this.id = \"\";\n this.name = \"\";\n this.specialist = \"\";\n this.start = new Date();\n this.end = new Date();\n this.duration = 0;\n this.price = null;\n this.statusId = 0;\n this.notes = \"\";\n this.hasEvolutionNotes = false;\n }\n }\n}\n","import { CustomerFrequencyType } from \"./enums/customer-frequency-type\";\nimport { Gender } from \"./enums/gender\";\nimport { EvolutionNoteFieldAndValue } from \"./evolution-note-field-and-value\";\n\nexport class PatientDataResponse {\n firstName: string;\n lastName: string;\n dateOfBirth?: Date;\n gender?: Gender;\n customerFrequency: CustomerFrequencyType;\n\n email?: string;\n mobileCodeIso3: string;\n mobileDigits: number;\n mobileCode: number;\n mobileTemplate: string;\n mobile?: string;\n contactable: boolean;\n\n arrivedAppointmentsCount: number;\n totalAppointmentsCount: number;\n favoriteServiceName?: string;\n favoriteServiceRequestedCount: number;\n totalServicesCount: number;\n\n evolutionNoteSectionName?: string;\n evolutionNoteFieldsLastUpdated?: Date;\n evolutionNoteFieldsValues?: EvolutionNoteFieldAndValue[];\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.dateOfBirth = x.dateOfBirth;\n this.gender = x.gender;\n this.customerFrequency = x.customerFrequency;\n this.email = x.email;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileDigits = x.mobileDigits;\n this.mobileCode = x.mobileCode;\n this.mobileTemplate = x.mobileTemplate;\n this.mobile = x.mobile;\n this.contactable = x.contactable;\n this.arrivedAppointmentsCount = x.arrivedAppointmentsCount;\n this.totalAppointmentsCount = x.totalAppointmentsCount;\n this.favoriteServiceName = x.favoriteServiceName;\n this.favoriteServiceRequestedCount = x.favoriteServiceRequestedCount;\n this.totalServicesCount = x.totalServicesCount;\n this.evolutionNoteSectionName = x.evolutionNoteSectionName;\n this.evolutionNoteFieldsLastUpdated = x.evolutionNoteFieldsLastUpdated;\n this.evolutionNoteFieldsValues = x.evolutionNoteFieldsValues;\n }\n else {\n this.firstName = \"\";\n this.lastName = \"\";\n this.dateOfBirth = undefined;\n this.gender = undefined;\n this.customerFrequency = CustomerFrequencyType.Inactive;\n this.email = undefined;\n this.mobileCodeIso3 = \"MEX\";\n this.mobileDigits = 10;\n this.mobileCode = 52;\n this.mobileTemplate = \"000-000-0000\";\n this.mobile = undefined;\n this.contactable = false;\n this.arrivedAppointmentsCount = 0;\n this.totalAppointmentsCount = 0;\n this.favoriteServiceName = undefined;\n this.favoriteServiceRequestedCount = 0;\n this.totalServicesCount = 0;\n this.evolutionNoteSectionName = undefined;\n this.evolutionNoteFieldsLastUpdated = undefined;\n this.evolutionNoteFieldsValues = undefined;\n }\n }\n }","import { Gender } from \"./enums/gender\";\nimport { PatientFormSection } from \"./patient-form-section\";\n\nexport class PatientGeneralInfoResponse {\n id: string;\n firstName: string;\n lastName: string;\n dateOfBirth?: Date;\n gender?: Gender;\n customGender?: string | null;\n email?: string;\n mobileCodeIso3: string;\n mobileDigits: number;\n mobileCode: number;\n mobileTemplate: string;\n mobile?: string;\n contactableAppointments: boolean;\n contactableMassiveSendings: boolean;\n\n notes: string;\n\n patientFormSections: PatientFormSection[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.dateOfBirth = x.dateOfBirth;\n this.gender = x.gender;\n this.customGender = x.customGender;\n this.email = x.email;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileDigits = x.mobileDigits;\n this.mobileCode = x.mobileCode;\n this.mobileTemplate = x.mobileTemplate;\n this.mobile = x.mobile;\n this.contactableAppointments = x.contactableAppointments;\n this.contactableMassiveSendings = x.contactableMassiveSendings;\n this.patientFormSections = x.patientFormSections;\n this.notes = x.notes;\n }\n else {\n this.id = \"\";\n this.firstName = \"\";\n this.lastName = \"\";\n this.dateOfBirth = undefined;\n this.gender = undefined;\n this.customGender = undefined;\n this.email = undefined;\n this.mobileCodeIso3 = \"MEX\";\n this.mobileDigits = 10;\n this.mobileCode = 52;\n this.mobileTemplate = \"000-000-0000\";\n this.mobile = undefined;\n this.contactableAppointments = false;\n this.contactableMassiveSendings = false;\n this.patientFormSections = [];\n this.notes = \"\";\n }\n }\n }","export class FormFieldItemValue {\n fieldItemId: string;\n value: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.fieldItemId = x.fieldItemId;\n this.value = x.value;\n }\n else {\n this.fieldItemId = \"\";\n this.value = \"\";\n }\n }\n}","import { FormFieldItemValue } from \"./form-field-item-value\";\n\nexport class FormRadioValue {\n item: FormFieldItemValue;\n additionalFreeTextValue: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.item = x.item;\n this.additionalFreeTextValue = x.additionalFreeTextValue;\n }\n else {\n this.item = new FormFieldItemValue();\n this.additionalFreeTextValue = \"\";\n }\n }\n}","export class FormPhoneNumberValue {\n body: string;\n countryIso: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.body = x.body;\n this.countryIso = x.countryIso;\n }\n else {\n this.body = \"\";\n this.countryIso = \"\";\n }\n }\n}","import { EvolutionNoteFieldAndValue } from \"./evolution-note-field-and-value\";\n\nexport default class EvolutionNotesGrouped {\n \n year: number;\n month: number;\n evolutionNotes: EvolutionNote[];\n vitalSignsFields: EvolutionNoteFieldAndValue[];\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.year = x.year;\n this.month = x.month;\n this.evolutionNotes = x.evolutionNotes;\n this.vitalSignsFields = x.vitalSignsFields;\n \n } else {\n this.year = 0;\n this.month = 0;\n this.evolutionNotes = [];\n this.vitalSignsFields = [];\n }\n }\n}\n\nexport class EvolutionNote {\n id: string;\n customerId: string;\n appointmentId: string | undefined;\n serviceId: string | undefined;\n user: string;\n appointmentDate: Date | null;\n dateCreated: Date;\n editMode: boolean;\n evolutionNoteText: string;\n diagnosis: string | null;\n additionalInstructions: string | null;\n clinicalFiles: EvolutionNoteClinicalFile[];\n treatments: EvolutionNoteTreatmentInput[];\n studies: EvolutionNoteDynamicInput[];\n vitalSigns: EvolutionNoteFieldAndValue[];\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.customerId = x.customerId;\n this.appointmentId = x.appointmentId;\n this.serviceId = x.serviceId;\n this.editMode = x.editMode;\n this.user = x.user;\n this.evolutionNoteText = x.evolutionNoteText;\n this.diagnosis = x.diagnosis;\n this.additionalInstructions = x.additionalInstructions;\n this.treatments = x.treatments;\n this.vitalSigns = x.vitalSigns;\n this.studies = x.studies;\n this.clinicalFiles = x.clinicalFiles;\n this.appointmentDate = x.appointmentDate;\n this.dateCreated = x.dateCreated;\n } else {\n this.id = \"\";\n this.customerId = \"\";\n this.appointmentId = undefined;\n this.serviceId = undefined;\n this.user = \"\";\n this.editMode = false;\n this.evolutionNoteText = \"\";\n this.diagnosis = null;\n this.additionalInstructions = null;\n this.treatments = [];\n this.vitalSigns = [];\n this.clinicalFiles = [];\n this.studies = [];\n this.appointmentDate = new Date();\n this.dateCreated = new Date();\n }\n }\n}\n\nexport class EvolutionNoteDynamicInput {\n id: string | null;\n name: string;\n order: number;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.order = x.order;\n } else {\n this.id = null;\n this.name = \"\";\n this.order = 0;\n }\n }\n}\n\nexport class EvolutionNoteTreatmentInput {\n id: string | null;\n medication: string;\n prescription: string;\n order: number;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.medication = x.medication;\n this.prescription = x.prescription;\n this.order = x.order;\n } else {\n this.id = null;\n this.medication = \"\";\n this.prescription = \"\";\n this.order = 0;\n }\n }\n}\n\nexport class EvolutionNoteClinicalFile {\n id: string | null;\n fileName: string;\n fileURL: string;\n s3Key: string;\n customerId: number;\n evolutionNoteId: string;\n fileComment: string;\n uploadedBy: string;\n created: Date;\n fileBlob: Blob;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.fileName = x.fileName;\n this.fileURL = x.fileURL;\n this.s3Key = x.s3Key;\n this.customerId = x.customerId;\n this.evolutionNoteId = x.evolutionNoteId;\n this.fileComment = x.fileComment;\n this.uploadedBy = x.uploadedBy;\n this.created = x.created;\n this.fileBlob = x.fileBlob;\n } else {\n this.id = null;\n this.fileName = \"\";\n this.fileURL = \"\";\n this.s3Key = \"\";\n this.customerId = 0;\n this.evolutionNoteId = \"\";\n this.fileComment = \"\";\n this.uploadedBy = \"\";\n this.created = new Date();\n this.fileBlob = new Blob();\n }\n }\n}","export class FileUploadResponse {\n uploaded: boolean | null;\n fileName: string | null;\n fileURL: string | null;\n fileSizeInBytes: string | null\n constructor(x?: any){\n if (typeof x === \"object\") {\n this.uploaded = x.uploaded;\n this.fileName = x.fileName;\n this.fileURL = x.fileURL;\n this.fileSizeInBytes = x.fileSizeInBytes;\n } else {\n this.uploaded = null;\n this.fileName = null;\n this.fileURL = null;\n this.fileSizeInBytes = null;\n }\n }\n}\n","export class UpdatePatientFormDataResponse {\n isDuplicatedPhoneNumber: boolean;\n duplicatedPatientId: string | null;\n firstName: string | null;\n lastName: string | null;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.isDuplicatedPhoneNumber = x.isDuplicatedPhoneNumber;\n this.duplicatedPatientId = x.duplicatedPatientId;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n } else {\n this.isDuplicatedPhoneNumber = false;\n this.duplicatedPatientId = null;\n this.firstName = null;\n this.lastName = null;\n }\n }\n }\n ","export class CustomerClinicalFile {\n id: string;\n customerId: string;\n s3Key: string;\n fileName: string;\n comments: string | null;\n uploadedBy: string;\n created: Date;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.customerId = x.customerId;\n this.s3Key = x.s3Key;\n this.fileName = x.fileName;\n this.comments = x.comments;\n this.uploadedBy = x.uploadedBy;\n this.created = x.created;\n } else {\n this.id = \"\";\n this.customerId = \"\";\n this.s3Key = \"\";\n this.fileName = \"\";\n this.comments = null;\n this.uploadedBy = \"\";\n this.created = new Date();\n }\n }\n}\n","import EvolutionNotesGrouped from \"./evolution-notes-grouped\";\nimport { SectionFieldModel } from \"./section-field-model\";\n\nexport class EvolutionNoteResponse {\n evolutionNotesGrouped: EvolutionNotesGrouped[];\n sectionFields: SectionFieldModel[];\n vitalSignSectionName: string;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.evolutionNotesGrouped = x.evolutionNotesGrouped;\n this.sectionFields = x.sectionFields;\n this.vitalSignSectionName = x.vitalSignSectionName;\n } else {\n this.evolutionNotesGrouped = [];\n this.sectionFields = [];\n this.vitalSignSectionName = \"\";\n }\n }\n}","import { ClinicalHistorySection } from \"./clinical-history-section\";\n\nexport class PatientClinicalHistoryTabDataResponse {\n \n canAcceptPrivacyNotice: boolean;\n canReadConsentLetter: boolean;\n hasAcceptedPrivacyNotice: boolean;\n hasReadConsentLetter: boolean;\n signature: string | null;\n ip?: string;\n formSignedAt?: Date;\n isFormSignedAtEstablishment: boolean;\n observations?: string;\n phoneNumberIso3Code: string;\n phoneNumberBody: string\n clinicalHistorySections: ClinicalHistorySection[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.canAcceptPrivacyNotice = x.canAcceptPrivacyNotice;\n this.canReadConsentLetter = x.canReadConsentLetter;\n this.hasAcceptedPrivacyNotice = x.hasAcceptedPrivacyNotice;\n this.hasReadConsentLetter = x.hasReadConsentLetter;\n this.signature = x.signature;\n this.ip = x.ip;\n this.formSignedAt = x.formSignedAt;\n this.isFormSignedAtEstablishment = x.isFormSignedAtEstablishment;\n this.observations = x.observations;\n this.phoneNumberIso3Code = x.phoneNumberIso3Code;\n this.phoneNumberBody = x.phoneNumberBody;\n this.clinicalHistorySections = x.clinicalHistorySections;\n }\n else {\n this.canAcceptPrivacyNotice = false;\n this.canReadConsentLetter = false;\n this.hasAcceptedPrivacyNotice = false;\n this.hasReadConsentLetter = false;\n this.signature = null;\n this.ip = undefined;\n this.formSignedAt = undefined;\n this.isFormSignedAtEstablishment = false;\n this.observations = undefined;\n this.phoneNumberIso3Code = \"\";\n this.phoneNumberBody = \"\";\n this.clinicalHistorySections = [];\n }\n }\n }","import { Customer } from \"./customer\";\nexport class CustomersByIdResponse {\n customer: Customer | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.customer = x.customer;\n } else {\n this.customer = null;\n }\n }\n}\n","export class EmergencyContact {\n id?: string;\n name: string | null;\n relationship: string | null;\n mobileCodeIso3: string | null;\n mobileCode: number | null;\n mobileDigits: number | null;\n mobileTemplate: string | null;\n mobile: string | null;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.relationship = x.relationship;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobileDigits = x.mobileDigits;\n this.mobileCode = x.mobileCode;\n this.mobileTemplate = x.mobileTemplate;\n this.mobile = x.mobile;\n } else {\n this.name = null;\n this.relationship = null;\n this.mobileCodeIso3 = null; //\"MEX\";\n this.mobileDigits = 10;\n this.mobileCode = 52;\n this.mobileTemplate = \"000-000-0000\";\n this.mobile = null;\n }\n }\n}\n","import { DateTime } from 'luxon';\nimport { AppointmentServiceModel } from './appointment-service-model';\n\n\nexport class CustomerLastAppointment {\n id: string; \n customerId: string;\n startDate: DateTime;\n services: AppointmentServiceModel[];\n notes: string;\n evolutionNotes: string[];\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.id = x.id;\n this.customerId = x.customerId;\n this.startDate = DateTime.fromISO(x.startDate);\n this.services = x.services;\n this.notes = x.notes;\n this.evolutionNotes = x.evolutionNotes;\n } else {\n this.id = \"\";\n this.customerId = \"\";\n this.startDate = DateTime.now(); \n this.services = [];\n this.notes = \"\";\n this.evolutionNotes = [];\n }\n }\n}\n","import { CreateEmergencyContacts } from \"../models/create-emergency-contacts\";\nimport { CustomerData } from \"../models/customer-data\";\nimport { ApiClient } from \"./api-client\";\nimport { CustomersResponse } from \"../models/customers-response\";\nimport { CustomerEntity } from \"../models/customer-entity\";\nimport { CustomerInfoDetails } from \"../models/customer-info-details\";\nimport { CustomerSearch } from \"../models/customer-search\";\nimport { ImportExcelResponse } from \"../models/import-excel-response\";\nimport CustomerHistory from \"./../models/customer-history\";\nimport { Response } from \"../models/response\";\nimport { PatientDataResponse } from \"../models/patient-data-response\";\nimport { PatientGeneralInfoResponse } from \"../models/patient-general-info-response\";\nimport { UpdatePatientFormDataRequest } from \"../models/update-patient-form-data-request\";\nimport { SectionFieldType } from \"../models/enums/section-field-type\";\nimport { FormRadioValue } from \"../models/form-radio-value\";\nimport { FormPhoneNumberValue } from \"../models/form-phone-number-value\";\nimport { PatientFormFieldAndValue } from \"../models/patient-form-field-and-value\";\nimport { PatientFormSection } from \"../models/patient-form-section\";\n\nimport EvolutionNotesGrouped, { EvolutionNote } from \"../models/evolution-notes-grouped\";\nimport { FileUploadResponse } from \"../models/file-upload-response\";\nimport { UpdatePatientFormDataResponse } from \"../models/update-patient-form-data-response\";\nimport { EvolutionNoteFieldAndValue } from \"../models/evolution-note-field-and-value\";\nimport { CustomerClinicalFile } from \"../models/customer-clinical-file\";\nimport { EvolutionNoteResponse } from \"../models/evolution-note-response\";\nimport { ClinicalHistorySection } from \"../models/clinical-history-section\";\nimport { ClinicalHistoryFieldAndValue } from \"../models/clinical-history-field-and-value\";\nimport { PatientClinicalHistoryTabDataResponse } from \"../models/patient-clinical-history-tab-data-response\";\nimport { UpdatePatientObservationsRequest } from \"../models/update-patient-observations-request\";\nimport { UpdatePatientClinicalHistoryFieldValueRequest } from \"../models/update-patient-clinical-history-field-value-request\";\nimport { CustomersByIdResponse } from \"../models/customer-by-id-response\";\nimport { EmergencyContact } from \"../models/emergency-contact\";\nimport { PredeterminedReportType } from \"../models/enums/predetermined-report-type\";\nimport UpdatePatientSignatureRequest from \"../models/update-patient-signature-request\";\nimport UpdatePatientSignatureResponse from \"../models/update-patient-signature-response\";\nimport { CustomerLastAppointment } from \"../models/customer-appointment\";\n\nexport class CustomerService {\n private static baseUrl: string = \"/customer\";\n\n static getCustomers(\n page: number,\n pageSize: number,\n order?: string,\n orderBy?: string,\n locale?: string\n ): Promise<CustomersResponse> {\n let urlEndpoint = `${this.baseUrl}/getbyaccount?page=${page}&pageSize=${pageSize}&locale=${locale ?? \"es\"}`;\n if (order && orderBy) {\n urlEndpoint += `&order=${order}&orderBy=${orderBy}`;\n }\n \n return ApiClient.get(urlEndpoint).then(\n (data) => {\n return new CustomersResponse(data);\n }\n );\n }\n \n static getCustomersByEstablishments(\n page: number,\n pageSize: number,\n establishmentIds: string[] | undefined,\n order?: string,\n orderBy?: string,\n ): Promise<CustomersResponse> {\n let urlEndpoint = `${this.baseUrl}/getbyestablishments?page=${page}&pageSize=${pageSize}`;\n \n if (order && orderBy) {\n urlEndpoint += `&order=${order}&orderBy=${orderBy}`;\n }\n \n urlEndpoint += '&' + Object.entries({\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\");\n \n return ApiClient.get(urlEndpoint).then(\n (data) => {\n return new CustomersResponse(data);\n }\n );\n }\n\n static getSearch(\n value?: string,\n size?: number\n ): Promise<CustomerSearch[]> {\n let urlEndpoint = `${this.baseUrl}/getsearch?value=${value}`;\n \n if (size) {\n urlEndpoint += `&size=${size}`;\n }\n\n return ApiClient.get(urlEndpoint).then((data) =>\n data.customers.map((customer: any) => new CustomerSearch(customer))\n );\n }\n \n static getSearchByEstablishments(\n establishmentIds: string[] | undefined,\n value?: string,\n size?: number\n ): Promise<CustomerSearch[]> {\n let urlEndpoint = `${this.baseUrl}/getsearchbyestablishments?value=${value}`;\n \n if (size) {\n urlEndpoint += `&size=${size}`;\n }\n \n urlEndpoint += '&' + Object.entries({\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\");\n \n return ApiClient.get(urlEndpoint).then((data) =>\n data.customers.map((customer: any) => new CustomerSearch(customer))\n );\n }\n\n static createCustomer(customer: CustomerEntity): Promise<CustomerEntity> {\n return ApiClient.post(`${this.baseUrl}/createNew`, customer).then(\n (data) => new CustomerEntity(data.customer)\n );\n }\n\n static async deleteCustomer(customerId: string): Promise<boolean> {\n return await ApiClient.remove(`${this.baseUrl}/delete?customerId=${customerId}`).then(\n (data) => data?.succeeded ?? false\n );\n }\n\n static createCustomersFromFile(file: File): Promise<ImportExcelResponse> {\n const formData = new FormData();\n formData.append(\"File\", file);\n\n return ApiClient.post(`${this.baseUrl}/createfromfile`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n },\n }).then((data) => {\n return new ImportExcelResponse(data);\n });\n }\n\n static createEmergencyContacts(\n emergencyContacts: CreateEmergencyContacts\n ): Promise<EmergencyContact[]> {\n return ApiClient.post(\n `${this.baseUrl}/createemergencycontacts`,\n emergencyContacts\n ).then((data) => {\n return data.emergencyContacts.map((item: EmergencyContact) => new EmergencyContact(item));\n });\n }\n\n static deleteBulkEmergencyContacts(\n contactsIds: string[]\n ): Promise<CustomerEntity> {\n return ApiClient.put(`${this.baseUrl}/deletebulkemergencycontacts`, {\n contactIds: contactsIds,\n }).then((data) => new CustomerEntity(data));\n }\n\n static deleteEmergencyContacts(contactId: string): Promise<boolean> {\n return ApiClient.remove(\n `${this.baseUrl}/deleteemergencycontacts?contactId=${contactId}`\n ).then((data) => true);\n }\n\n static updateCustomer(\n customer: CustomerInfoDetails\n ): Promise<CustomerInfoDetails> {\n return ApiClient.put(`${this.baseUrl}/update`, customer).then(\n (data) => new CustomerInfoDetails(data.customer)\n );\n }\n\n static getCustomerData(customerId: string): Promise<CustomerData> {\n return ApiClient.get(\n `${this.baseUrl}/getcustomerdata?customerId=${customerId}`\n ).then((data) => new CustomerData(data.customer));\n }\n \n static getById(customerId: string): Promise<CustomersByIdResponse> {\n return ApiClient.get(\n `${this.baseUrl}/getbyid?customerId=${customerId}`\n ).then((data) => {\n return new CustomersByIdResponse(data);\n });\n }\n\n static getCustomerInfoDetails(\n customerId: string\n ): Promise<CustomerInfoDetails> {\n return ApiClient.get(\n `${this.baseUrl}/getinfodetails?customerId=${customerId}`\n ).then((data) => new CustomerInfoDetails(data.customer));\n }\n\n static getCustomerLastAppointmentsDetails(customerId: string): Promise<CustomerLastAppointment[]> {\n return ApiClient.get(\n `${this.baseUrl}/getlastappointmentsdetails?customerId=${customerId}`\n ).then((data) => {\n return data.appointments.map((item: CustomerLastAppointment) => new CustomerLastAppointment(item));\n });\n }\n\n static getCustomerHistory(customerId: string, locale?: string): Promise<Response> {\n return ApiClient.get(`${this.baseUrl}/gethistory?customerId=${customerId}&locale=${locale ?? \"es\"}`)\n .then((data) => {\n if (data) {\n let entity = data.history.map((item: any) => new CustomerHistory(item));\n return new Response(entity, data.total);\n } else {\n return new Response();\n }\n });\n }\n\n static async getPatientData(customerId: string): Promise<PatientDataResponse> {\n return ApiClient.get(`${this.baseUrl}/getpatientdata?customerId=${customerId}`)\n .then((data) => {\n if (data) {\n if (data.evolutionNoteFieldsValues)\n data.evolutionNoteFieldsValues.forEach((fv: EvolutionNoteFieldAndValue) => {\n if (!fv?.value?.value)\n return;\n else {\n const objectValue = CustomerService.getJsonObjectValue(fv.value);\n fv.value.value = objectValue;\n }\n })\n return new PatientDataResponse(data);\n } else {\n return new PatientDataResponse();\n }\n });\n }\n\n static async getPatientGeneralInfo(customerId: string): Promise<PatientGeneralInfoResponse> {\n return ApiClient.get(`${this.baseUrl}/getpatientgeneralinfo?customerId=${customerId}`)\n .then((data) => {\n if (data) {\n data.patientFormSections.forEach((s: PatientFormSection) => {\n s.patientFormSectionFields.forEach((fv: PatientFormFieldAndValue) => {\n if (!fv?.value?.value)\n return;\n else {\n const objectValue = CustomerService.getJsonObjectValue(fv.value);\n fv.value.value = objectValue;\n }\n })\n })\n return new PatientGeneralInfoResponse(data);\n } else {\n return new PatientGeneralInfoResponse();\n }\n });\n }\n\n static async getPatientClinicalHistoryTabData(customerId: string): Promise<PatientClinicalHistoryTabDataResponse> {\n return ApiClient.get(`${this.baseUrl}/getpatientclinicalhistorytabdata?customerId=${customerId}`)\n .then((data) => {\n if (data) {\n data.clinicalHistorySections.forEach((s: ClinicalHistorySection) => {\n s.fieldsAndValues.forEach((fv: ClinicalHistoryFieldAndValue) => {\n if (!fv?.value?.value)\n return;\n else {\n const objectValue = CustomerService.getJsonObjectValue(fv.value);\n fv.value.value = objectValue;\n }\n })\n })\n return new PatientClinicalHistoryTabDataResponse(data);\n } else {\n return new PatientClinicalHistoryTabDataResponse();\n }\n });\n }\n\n static async updatePatientFormData(request: UpdatePatientFormDataRequest): Promise<UpdatePatientFormDataResponse> {\n const clonedRequest: UpdatePatientFormDataRequest = structuredClone(request);\n clonedRequest.patientFormSectionFields.forEach(fv => {\n if (!fv.value?.value)\n return;\n\n //if optional phone number input has country, but phone body is empty\n if (!fv.field.isRequired\n && fv.value.type === SectionFieldType.PhoneNumber\n && ((fv.value.value as FormPhoneNumberValue).body === null\n || (fv.value.value as FormPhoneNumberValue).body === undefined\n || (fv.value.value as FormPhoneNumberValue).body.trim() === \"\")) {\n fv.value = null;\n return;\n }\n if (fv.value.type === SectionFieldType.Radio || fv.value.type === SectionFieldType.PhoneNumber) {\n fv.value.value = JSON.stringify(fv.value.value);\n }\n });\n return ApiClient.put(`${this.baseUrl}/updatepatientformdata`, clonedRequest)\n .then((data) => new UpdatePatientFormDataResponse(data));\n }\n \n\n static async updatePatientClinicalHistoryFieldValue(request: UpdatePatientClinicalHistoryFieldValueRequest): Promise<boolean> {\n const clonedRequest: UpdatePatientClinicalHistoryFieldValueRequest = structuredClone(request);\n if (!clonedRequest.fieldAndValue.value?.value)\n return false;\n\n if (clonedRequest.fieldAndValue.value.type === SectionFieldType.Radio\n || clonedRequest.fieldAndValue.value.type === SectionFieldType.PhoneNumber) {\n clonedRequest.fieldAndValue.value.value = JSON.stringify(clonedRequest.fieldAndValue.value.value);\n }\n\n return ApiClient.put(`${this.baseUrl}/updatepatientclinicalhistoryfieldvalue`, clonedRequest)\n .then((data) => data.isUpdated);\n }\n\n static async updatePatientObservations(request: UpdatePatientObservationsRequest): Promise<boolean> {\n return ApiClient.put(`${this.baseUrl}/updatepatientobservations`, request)\n .then((data) => data.isUpdated);\n }\n\n static async updatePatientSignature(request: UpdatePatientSignatureRequest): Promise<UpdatePatientSignatureResponse> {\n return ApiClient.put(`${this.baseUrl}/updatepatientsignature`, request);\n }\n\n static async getPatientEvolutionNotes(customerId: string, appointmentId: string | undefined, serviceId: string | undefined): Promise<EvolutionNoteResponse> {\n return ApiClient.get(`${this.baseUrl}/getpatientevolutionnotes?customerId=${customerId}${appointmentId && serviceId ? \"&appointmentId=\" + appointmentId + \"&serviceId=\" + serviceId : \"\"}`)\n .then((data) => {\n if (data.evolutionNotesGrouped) {\n data.evolutionNotesGrouped.map((evolutionNotesGrouped: EvolutionNotesGrouped) => {\n evolutionNotesGrouped.evolutionNotes.map((note: EvolutionNote) => {\n note.vitalSigns.map((fv: EvolutionNoteFieldAndValue) => {\n if (!fv?.value?.value)\n return;\n else {\n const objectValue = CustomerService.getJsonObjectValue(fv.value);\n fv.value.value = objectValue;\n }\n return fv;\n })\n return note;\n })\n return evolutionNotesGrouped;\n });\n return new EvolutionNoteResponse(data);\n } else {\n return new EvolutionNoteResponse();\n }\n });\n }\n\n static createEvolutionNote(evolutionNote: EvolutionNote): Promise<EvolutionNote> {\n const formData = new FormData();\n \n let clonedRequest: EvolutionNote = structuredClone(evolutionNote);\n clonedRequest.vitalSigns.forEach(fv => {\n if (!fv.value?.value)\n return;\n \n //if optional phone number input has country, but phone body is empty\n if (!fv.field.isRequired\n && fv.value.type === SectionFieldType.PhoneNumber\n && ((fv.value.value as FormPhoneNumberValue).body === null\n || (fv.value.value as FormPhoneNumberValue).body === undefined\n || (fv.value.value as FormPhoneNumberValue).body.trim() === \"\")) {\n \n fv.value = null;\n return;\n }\n if (fv.value.type === SectionFieldType.Radio || fv.value.type === SectionFieldType.PhoneNumber) {\n fv.value.value = JSON.stringify(fv.value.value);\n }\n });\n \n clonedRequest.clinicalFiles.forEach(function (item, index, array) {\n formData.append(\"Files\", new File([item.fileBlob], item.fileComment + \":\" + item.fileName, { type: \"multipart/form-data\" }));\n });\n formData.append(\"CustomerId\", clonedRequest.customerId);\n if (clonedRequest.appointmentId && clonedRequest.serviceId){\n formData.append(\"AppointmentId\", clonedRequest.appointmentId);\n formData.append(\"ServiceId\", clonedRequest.serviceId);\n }\n formData.append(\"EvolutionNoteText\", clonedRequest.evolutionNoteText);\n formData.append(\"Diagnosis\", clonedRequest.diagnosis ?? \"\");\n formData.append(\"AdditionalInstructions\", clonedRequest.additionalInstructions ?? \"\");\n formData.append(\"Studies\", JSON.stringify(clonedRequest.studies));\n formData.append(\"Treatments\", JSON.stringify(clonedRequest.treatments));\n formData.append(\"VitalSigns\", JSON.stringify(clonedRequest.vitalSigns));\n\n return ApiClient.post(`${this.baseUrl}/createevolutionnote`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n },\n }).then((data) => {\n return new EvolutionNote(data.evolutionNote)\n });\n }\n\n static updateEvolutionNote(evolutionNote: EvolutionNote): Promise<EvolutionNote> {\n const formData = new FormData();\n \n let clonedRequest: EvolutionNote = structuredClone(evolutionNote);\n clonedRequest.vitalSigns.forEach(fv => {\n if (!fv.value?.value)\n return;\n \n //if optional phone number input has country, but phone body is empty\n if (!fv.field.isRequired\n && fv.value.type === SectionFieldType.PhoneNumber\n && ((fv.value.value as FormPhoneNumberValue).body === null\n || (fv.value.value as FormPhoneNumberValue).body === undefined\n || (fv.value.value as FormPhoneNumberValue).body.trim() === \"\")) {\n \n fv.value = null;\n return;\n }\n if (fv.value.type === SectionFieldType.Radio || fv.value.type === SectionFieldType.PhoneNumber) {\n fv.value.value = JSON.stringify(fv.value.value);\n }\n });\n clonedRequest.clinicalFiles.filter(file => !file.s3Key).forEach(function (item, index, array) {\n formData.append(\"Files\", new File([item.fileBlob], item.fileComment + \":\" + item.fileName));\n });\n formData.append(\"Id\", clonedRequest.id);\n formData.append(\"CustomerId\", clonedRequest.customerId);\n formData.append(\"EvolutionNoteText\", clonedRequest.evolutionNoteText);\n formData.append(\"Diagnosis\", clonedRequest.diagnosis ?? \"\");\n formData.append(\"AdditionalInstructions\", clonedRequest.additionalInstructions ?? \"\");\n formData.append(\"Studies\", JSON.stringify(clonedRequest.studies));\n formData.append(\"Treatments\", JSON.stringify(clonedRequest.treatments));\n formData.append(\"VitalSigns\", JSON.stringify(clonedRequest.vitalSigns));\n \n return ApiClient.post(`${this.baseUrl}/updateevolutionnote`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n },\n }).then((data) => new EvolutionNote(data.evolutionNote));\n }\n\n static getTreatmentPdf(customerId: string, evolutionNoteId: string) {\n let endpoint = `${this.baseUrl}/gettreatmentpdf?customerId=${customerId}&evolutionNoteId=${evolutionNoteId}`\n\n return ApiClient.get(endpoint, {\n responseType: 'arraybuffer',\n headers:\n {\n 'Content-Type': 'application/pdf'\n }\n }).then((data) => {\n return data;\n });\n }\n\n static sendTreatmentPdfByWhatsApp(customerId: string, evolutionNoteId: string): Promise<boolean> {\n let endpoint = `${this.baseUrl}/sendtreatmentpdfbywhatsapp?customerId=${customerId}&evolutionNoteId=${evolutionNoteId}`\n\n return ApiClient.get(endpoint).then(data => data?.succeeded ?? false)\n }\n\n static uploadPatientClinicalFile(file: File, customerId: string, evolutionNoteId: string, fileComment: string): Promise<FileUploadResponse> {\n const formData = new FormData();\n formData.append(\"File\", file);\n formData.append(\"CustomerId\", customerId);\n formData.append(\"EvolutionNoteId\", evolutionNoteId);\n formData.append(\"FileComment\", fileComment);\n return ApiClient.post(`${this.baseUrl}/uploadpatientclinicalfile`, formData, {\n headers: {\n \"Content-Type\": \"multipart/form-data\",\n },\n }).then((data) => new FileUploadResponse(data));\n }\n \n static async getPatientClinicalFiles(page: number, pageSize: number, customerId: string): Promise<Response> {\n return ApiClient.get(`${this.baseUrl}/getpatientclinicalfiles?customerId=${customerId}&pageSize=${pageSize}&page=${page}`)\n .then((data) => {\n let entity = data.patientClinicalFiles.map((item: any) => new CustomerClinicalFile(item));\n let total = data.total;\n if (data) {\n return new Response(entity, total);\n } else {\n return new Response();\n }\n });\n }\n \n static getPatientClinicalFileUrl(s3Key: string): Promise<Response> {\n return ApiClient.get(`${this.baseUrl}/getpatientclinicalfileurl?s3Key=${s3Key}`)\n .then((data) => {\n if (data) {\n return new Response(data.fileUrl);\n } else {\n return new Response();\n }\n });\n }\n \n static deletePatientClinicalFile(s3Key: string): Promise<Response> {\n return ApiClient.remove(`${this.baseUrl}/deletepatientclinicalfile?s3Key=${s3Key}`)\n .then((data) => {\n if (data) {\n return new Response(data);\n } else {\n return new Response();\n }\n });\n }\n \n static async getPatientClinicalFilePdf(customerId: string): Promise<any> {\n let endpoint = `${this.baseUrl}/getpatientclinicalfilepdf?customerId=${customerId}`\n \n return ApiClient.get(endpoint, {\n responseType: 'arraybuffer',\n headers:\n {\n 'Content-Type': 'application/pdf'\n }\n }).then((data) => {\n return data;\n });\n }\n\n static async getPrivacyNotice(): Promise<{ privacyNotice: string, privacyNoticeEnabled: boolean }> {\n const data = await ApiClient.get(\n `${this.baseUrl}/getprivacynotice`\n );\n\n return data;\n }\n\n static async getInformedConsentLetter(): Promise<{ consentLetter: string, consentLetterEnabled: boolean }> {\n const data = await ApiClient.get(\n `${this.baseUrl}/getinformedconsentletter`\n );\n\n return data;\n }\n \n private static getJsonObjectValue = (x: any) => {\n switch (x.type) {\n case SectionFieldType.PhoneNumber:\n const phoneObj = JSON.parse(x.value);\n return new FormPhoneNumberValue(phoneObj);\n case SectionFieldType.Radio:\n const radioObj = JSON.parse(x.value);\n return new FormRadioValue(radioObj);\n default:\n return x.value;\n }\n };\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n cancelModalPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n cancelModalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n cancelModalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport CustomerGeneral from \"./../CustomerGeneral\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { CustomerEntity } from \"../../../models/customer-entity\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport { EmailRegex, MultipleSpacesNameRegex } from \"../../../constants/validator\";\nimport Country from \"../../../models/country\";\n\nimport { CustomerModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport { Gender } from \"../../../models/enums/gender\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\n\nconst CustomerModal = (props: CustomerModalProps) => {\n const appDispatch = useAppDispatch();\n const { t } = useTranslation([\"general\"]);\n const { open, onDuplicate, onClose, onCreate } = props;\n const accountSettings = useAppSelector(selectAccountSettings);\n const classes = useStyles();\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [customer, _setCustomer] = useState<CustomerEntity>();\n const [isValid, _setIsValid] = useState<boolean>(false);\n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [countryDefault, setCountryDefault] = useState<Country>(new Country({\n iso3: \"MEX\", dialCode: 52, dialDigits: 10, dialTemplate: \"000-000-0000\", name: \"México\"\n }));\n\n const customerRef = useRef(customer);\n const setCustomer = (data?: CustomerEntity) => {\n customerRef.current = data;\n _setCustomer(data);\n };\n\n const isValidRef = useRef(isValid);\n const setIsValid = (data: boolean) => {\n isValidRef.current = data;\n _setIsValid(data);\n };\n const titleTerminology = useCustomerTerminology(t(\"Customers\"), \"Customers\");\n const listener = (event: any) => {\n if (event.key === \"Enter\" || event.key === \"NumpadEnter\") {\n const fetchData = async () => {\n if (customerRef.current && isValidRef.current) {\n const createdCustomer = await CustomerService.createCustomer(customerRef.current);\n\n if (createdCustomer.isMobileDuplicate) {\n\n onDuplicate(new CustomerEntity(createdCustomer));\n \n } else {\n \n if (onCreate) {\n onCreate({ ...customerRef.current, id: createdCustomer.id });\n }\n \n setCustomer();\n\n }\n\n }\n };\n\n fetchData();\n }\n };\n\n useEffect(() => {\n setOpenModal(open);\n if (open) {\n window.addEventListener(\"keypress\", listener, false);\n } else {\n window.removeEventListener(\"keypress\", listener, false);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n\n \n useEffect(() => {\n (async () => {\n const countryInSettings: Country = accountSettings.countryInSettings;\n const entity = new CustomerEntity ({...customer,\n mobileCodeIso3: countryInSettings.iso3,\n mobileDigits: countryInSettings.dialDigits,\n mobileCode: countryInSettings.dialCode,\n mobileTemplate: countryInSettings.dialTemplate\n });\n setCountryDefault(countryInSettings);\n setCustomer(entity);\n })();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n\n const handleCloseModal = () => {\n setCustomer();\n appDispatch(applicationInterfaceActions.updateTitle(titleTerminology));\n setOpenModal(false);\n if (onClose) {\n onClose();\n }\n };\n \n const isUndefinedOrEmpty = (str: string | undefined) => {\n return str === undefined || str === \"\";\n }\n \n const isFormEmpty = () => {\n return isUndefinedOrEmpty(customer?.firstName) &&\n isUndefinedOrEmpty(customer?.lastName) &&\n isUndefinedOrEmpty(customer?.mobile) &&\n isUndefinedOrEmpty(customer?.email) &&\n customer?.birthDate === undefined\n }\n \n const handleGoBackClick = () => {\n if (isFormEmpty()) {\n handleCloseModal();\n }\n else {\n setCancelModal(true);\n }\n }\n\n const onCloseHandler = (event: any, reason: any) => {\n if (reason === \"backdropClick\") {\n handleGoBackClick()\n }\n };\n\n const handleOnCreateClick = async () => {\n if (customer && isValid) {\n setIsValid(false);\n try {\n const entity = new CustomerEntity ({...customer,\n mobileCodeIso3: customer.mobileCodeIso3 || countryDefault.iso3,\n mobileDigits: customer.mobileDigits || countryDefault.dialDigits,\n mobileCode: customer.mobileCode || countryDefault.dialCode,\n mobileTemplate: customer.mobileTemplate || countryDefault.dialTemplate\n });\n \n const createdCustomer = await CustomerService.createCustomer(entity);\n\n if (createdCustomer.isMobileDuplicate) {\n onDuplicate(new CustomerEntity(createdCustomer));\n } \n else {\n setCustomer(createdCustomer);\n if (onCreate) {\n onCreate({ ...entity, id: createdCustomer.id });\n setOpenModal(false);\n }\n }\n } catch (error) {\n setIsValid(true);\n }\n }\n };\n\n const handleCustomerGeneralChange = (customer: CustomerEntity, valid: boolean) => {\n\n let validGroup = true;\n\n const validName = MultipleSpacesNameRegex.test(customer.firstName || \"\");\n const validLastName = MultipleSpacesNameRegex.test(customer.lastName || \"\");\n const validMobile = validateMobile(customer);\n const validEmail = !customer.email ? true : EmailRegex.test(customer.email || \"\");\n const validGender = customer.gender !== Gender.Custom || MultipleSpacesNameRegex.test(customer.customGender || \"\");\n\n if (!validName ||\n !validLastName ||\n !validEmail ||\n !validMobile ||\n !validGender\n ) {\n validGroup = false;\n }\n\n setCustomer(customer);\n setIsValid(valid && validGroup);\n };\n\n \n const validateMobile = (c: CustomerEntity): boolean => {\n const digits: number = c.mobileDigits || countryDefault.dialDigits;\n let mobile: string = c.mobile!;\n if (mobile) mobile = mobile.length > 0 ? mobile.substring(0, digits) : mobile;\n const validDig = (digits === 7 && /^\\d{7}$/.test(mobile!)) ||\n (digits === 8 && /^\\d{8}$/.test(mobile!)) ||\n (digits === 9 && /^\\d{9}$/.test(mobile!)) ||\n (digits === 10 && /^\\d{10}$/.test(mobile!)) ||\n (digits === 11 && /^\\d{11}$/.test(mobile!)) ||\n (digits === 12 && /^\\d{12}$/.test(mobile!));\n\n return validDig;\n}\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={onCloseHandler}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {useCustomerTerminology(t(\"New customer\"), \"customer\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={handleGoBackClick}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={useCustomerTerminology(t(\"Create customer\"), \"customer\")}\n onClick={handleOnCreateClick}\n disabled={!isValid}\n />\n </div>\n </div>\n <CustomerGeneral onChange={handleCustomerGeneralChange} isModal={true} />\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.cancelModalPaper}>\n <div>\n <div\n className={`${classes.cancelModalCenter} ${classes.cancelModalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\n \"Are you sure you want to cancel customer creation? The changes made will not be saved?\"\n )}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={() => setCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n handleCloseModal();\n setCancelModal(false);\n }}\n >\n {t(\"Yes\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default CustomerModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n customerSection: {\n width: 228,\n marginRight: 34,\n },\n txtBody1Bold: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n personInCharge: {\n display: \"flex\",\n width: 228,\n },\n txtBody2: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n },\n txtBody2Bold: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n lineSeparator: {\n borderTop: \"1px solid #E5E7EA\",\n height: 0,\n },\n customerInfoTitle: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 28,\n },\n label1: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n },\n label2: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n },\n radioRoot: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.grey5,\n },\n },\n },\n radioConfirmed: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearBlue,\n },\n },\n },\n radioArrived: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearGreen,\n },\n },\n },\n radioNotArrived: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearRed,\n },\n },\n },\n radioPaid: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearGreen,\n },\n },\n },\n radioUnpaid: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearRed,\n },\n },\n },\n radioLabelRoot: {\n margin: 0,\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n customerListOverrides: {\n \"& .MuiSvgIcon-root\": {\n height: \"18px\",\n width: \"18px\"\n }\n },\n customerList: {\n ...theme.typography.txtBody2,\n lineHeight: \"15px\",\n color: theme.colors.grey5,\n },\n customerListSelected: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n lineHeight: \"15px\",\n color: theme.colors.clearMain,\n },\n buttonNewCustomer: {\n border: `1px solid ${theme.colors.clearMain}`,\n borderRadius: 50,\n width: 196,\n height: 32,\n ...theme.typography.buttons,\n fontWeight: \"bold\",\n color: \"#786EFF\",\n \"&:hover\": {\n color: theme.colors.grey1,\n background: \"#786EFF\",\n },\n },\n infoIcon: {\n color: theme.colors.grey3,\n marginLeft: 5,\n width: 8,\n height: 8,\n minWidth: 8,\n cursor: \"pointer\",\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n marginTop: 35,\n width: 262,\n },\n titleContainer: {\n display: 'flex',\n flexDirection: 'row',\n gap: 8,\n alignItems: 'center',\n },\n title: {\n color: theme.colors.grey5,\n ...theme.typography.header5,\n },\n appointmentsContainer: {\n marginTop: 10,\n borderRadius: 5,\n borderWidth: 1,\n border: 'solid',\n borderColor: theme.colors.grey2\n },\n appointmentsHeader: {\n minHeight: 40,\n borderRadius: 5,\n background: theme.colors.grey1,\n paddingLeft: 18,\n display: 'flex',\n alignItems: 'center',\n },\n emptyContentContainer: {\n width: 209,\n minHeight: 432,\n margin: 'auto',\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n alignItems: 'center',\n justifyContent: 'center'\n },\n emptyContentTitle: {\n textAlign: 'center',\n color: theme.colors.clearMain,\n ...theme.typography.header5,\n fontSize: 16,\n },\n emptyContentBody: {\n textAlign: 'center',\n color: theme.colors.grey4,\n ...theme.typography.txtBody2,\n },\n appointmentsList: {\n display: 'flex',\n flexDirection: 'column',\n padding: '0px 16px 22px 16px',\n overflowY: 'auto',\n scrollbarWidth: 'thin',\n scrollbarColor: '#c1c1c1 #f5f5f5',\n '&::-webkit-scrollbar': {\n width: '6px',\n },\n },\n appointmentCardContainer: {},\n appointmentCard: {\n paddingTop: 7,\n paddingBottom: 7,\n paddingRight: 4,\n paddingLeft: 4,\n borderRadius: 5,\n borderWidth: 1,\n border: 'solid',\n borderColor: theme.colors.grey2,\n marginTop: 8,\n },\n appointmentDate: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 700,\n marginTop: 15,\n marginBottom: 15\n },\n serviceItem: {\n marginTop: 0,\n },\n serviceName: {\n ...theme.typography.caption1,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n serviceTime: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n },\n serviceSpecialist: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n },\n postServiceNotes: {\n marginTop: 10,\n },\n notesTitle: {\n ...theme.typography.caption1,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n notesContent: {\n ...theme.typography.caption2,\n color: theme.colors.grey5,\n wordBreak: 'break-word',\n },\n seeMoreToggle: {\n ...theme.typography.caption2,\n color: theme.colors.clearMain,\n fontWeight: 700,\n cursor: 'pointer',\n },\n seeMoreButton: {\n marginTop: 16,\n padding: '8px 16px',\n borderRadius: 5,\n borderColor: theme.colors.clearMain,\n color: theme.colors.clearMain,\n borderWidth: 1,\n border: 'solid',\n cursor: 'pointer',\n '&:disabled': {\n color: theme.colors.clearMain,\n opacity: 0.3\n }\n },\n seeMoreButtonText: {\n ...theme.typography.buttons,\n fontWeight: 700,\n },\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect, useRef } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { DateTime } from 'luxon';\nimport { Button, Typography } from \"@material-ui/core\";\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../../redux/store\";\n\nimport { CustomerLastAppointmentsBlockProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { CalendarCheckmarkIcon, CalendarIcon } from \"../../../../assets/icons\";\nimport { Color } from \"../../../../constants/colors\";\nimport { CustomerLastAppointment } from \"../../../../models/customer-appointment\";\n\n\nexport default function CustomerLastAppointmentsBlock(props: CustomerLastAppointmentsBlockProps) {\n\n const { appointments } = props;\n\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const dateFormat = t(\"last_appointments_date_format\");\n const isClinicMode = accountSettings.isClinicMode;\n\n const [visibleAppointments, setVisibleAppointments] = useState<number>(3);\n const [expandedNotes, setExpandedNotes] = useState<{ [key: string]: boolean }>({});\n const [containerHeight, setContainerHeight] = useState<string | number>('auto');\n const listRef = useRef<HTMLDivElement>(null);\n\n const EvolutionNotesContent = ({ appointment }: { appointment: CustomerLastAppointment }) => {\n if (!(appointment.evolutionNotes && appointment.evolutionNotes.length > 0))\n return (<span>--</span>);\n\n return (\n <>\n {expandedNotes[appointment.id]\n ? appointment.evolutionNotes.map((note, index) => (\n <span key={index}>\n {note.replace(/<[^>]*>/g, '') + '\\n'}\n </span>\n ))\n : appointment.evolutionNotes\n .join('; ')\n .replace(/<[^>]*>/g, '')\n .substring(0, 120)\n }\n\n {appointment.evolutionNotes\n .join(' ')\n .replace(/<[^>]*>/g, '')\n .length > 120 && (\n <span\n className={classes.seeMoreToggle}\n onClick={() => handleNoteExpansionToggle(appointment.id)}\n >\n {expandedNotes[appointment.id]\n ? ` ${t(\"See less.\")}`\n : `...${t(\"See more.\")}`\n }\n </span>\n )}\n </>\n );\n };\n\n const NotesContent = ({ appointment }: { appointment: CustomerLastAppointment }) => {\n if (!appointment.notes)\n return (<span>--</span>);\n\n const isExpanded = expandedNotes[appointment.id];\n const content = isExpanded\n ? removeHtmlTags(appointment.notes)\n : removeHtmlTags(appointment.notes).substring(0, 120);\n\n const toggleText = isExpanded\n ? ` ${t(\"See less.\")}`\n : `...${t(\"See more.\")}`;\n\n return (\n <>\n {content}\n {removeHtmlTags(appointment.notes).length > 120 && (\n <span\n className={classes.seeMoreToggle}\n onClick={() => handleNoteExpansionToggle(appointment.id)}\n >\n {toggleText}\n </span>\n )}\n </>\n );\n };\n\n const EmptyContent = () => {\n return (\n <div className={classes.emptyContentContainer}>\n <CalendarIcon style={{ width: 38, height: 41, color: Color.gray4 }} />\n <Typography className={classes.emptyContentTitle}>\n {t(\"There are no appointments scheduled previously.\")}\n </Typography>\n <Typography className={classes.emptyContentBody}>\n {t(\"You can schedule an appointment now.\")}\n </Typography>\n </div>\n );\n };\n\n const AppointmentsContent = () => {\n return (\n <div className={classes.appointmentsList} ref={listRef} style={{ maxHeight: containerHeight, overflowY: 'auto' }}>\n {appointments && appointments.slice(0, visibleAppointments).map((appointment) => (\n <div key={appointment.id} className={'appointment-card-container'}>\n <Typography className={classes.appointmentDate}>\n {DateTime.fromISO(appointment.startDate.toString())\n .setLocale(localeApp)\n .toFormat(dateFormat)}\n </Typography>\n\n <div className={classes.appointmentCard}>\n\n {appointment.services.map((service) => (\n <div key={service.id} className={classes.serviceItem}>\n <Typography className={classes.serviceName}>{service.name}</Typography>\n <Typography className={classes.serviceTime}>\n {DateTime.fromISO(appointment.startDate.toString()).toFormat('HH:mm')} -\n {DateTime.fromISO(appointment.startDate.toString()).plus({ minutes: service.duration || 0 }).toFormat('HH:mm')}\n </Typography>\n <Typography className={classes.serviceSpecialist}>{service.user}</Typography>\n </div>\n ))}\n\n <div className={classes.postServiceNotes}>\n\n <Typography className={classes.notesTitle}>\n {accountSettings.isClinicMode\n ? t(\"Evolution note:\")\n : t(\"Post-service notes:\")\n }\n </Typography>\n\n <Typography className={classes.notesContent}>\n\n {isClinicMode\n ? <EvolutionNotesContent appointment={appointment} />\n : <NotesContent appointment={appointment} />\n }\n\n </Typography>\n\n </div>\n </div>\n </div>\n ))}\n {appointments && appointments.length > 0 &&\n <Button\n className={`${classes.seeMoreButton} see-more-button`}\n onClick={() => setVisibleAppointments((prev) => prev + 3)}\n disabled={appointments.length < visibleAppointments || appointments.length <= 3}\n >\n <Typography className={classes.seeMoreButtonText}>\n {t(\"See more\")}\n </Typography>\n </Button>\n }\n </div>\n );\n };\n\n useEffect(() => {\n setVisibleAppointments(3);\n }, [appointments]);\n\n useEffect(() => {\n if (listRef.current) {\n\n if (visibleAppointments <= 3) {\n setContainerHeight('auto');\n }\n\n else {\n const cards = listRef.current?.querySelectorAll('.appointment-card-container');\n let totalHeight = 0;\n\n const totalCards = cards.length;\n const startIndex = Math.max(0, totalCards - 3);\n\n for (let i = startIndex; i < totalCards; i++) {\n const card = cards[i];\n totalHeight += card.getBoundingClientRect().height;\n }\n\n totalHeight += 64;\n\n setContainerHeight(totalHeight);\n }\n }\n }, [visibleAppointments, expandedNotes]);\n\n useEffect(() => {\n if (listRef.current) {\n listRef.current.scrollTo({\n top: listRef.current.scrollHeight,\n behavior: 'smooth',\n });\n }\n }, [visibleAppointments, containerHeight]);\n\n function handleNoteExpansionToggle(appointmentId: string) {\n setExpandedNotes((prev) => ({\n ...prev,\n [appointmentId]: !prev[appointmentId],\n }));\n };\n\n function removeHtmlTags(text: string) {\n return text.replace(/<\\/?[^>]+(>|$)/g, \"\");\n }\n\n function getAppointmentsTitle() {\n if (!appointments || appointments.length === 0) {\n return t(\"Last appointments\");\n } else if (appointments.length === 1) {\n return t(\"Last scheduled appointment\");\n } else {\n const count = Math.min(appointments.length, visibleAppointments || 3);\n return t(\"Last {{count}} appointments\", { count });\n }\n }\n\n return (\n <div className={classes.root}>\n <div className={classes.titleContainer}>\n <div>\n <CalendarCheckmarkIcon style={{ width: 24, height: 24, color: Color.gray5 }} />\n </div>\n <Typography className={classes.title}>\n {t(\"Previous appointments details\")}\n </Typography>\n </div>\n\n <div className={classes.appointmentsContainer}>\n <div className={classes.appointmentsHeader}>\n <Typography className={classes.title}>\n {getAppointmentsTitle()}\n </Typography>\n </div>\n\n {appointments && appointments.length > 0 ? <AppointmentsContent /> : <EmptyContent />}\n </div>\n </div>\n );\n}\n","import React, { useState, useEffect } from \"react\";\n\nimport { useHistory } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport { conformToMask } from \"react-text-mask\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\nimport { Url } from \"../../../constants/url\";\nimport Autocomplete from \"../../common/Autocomplete\";\nimport CustomerModal from \"./../../customers/CustomerModal\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { CustomerSearch } from \"../../../models/customer-search\";\nimport {\n GroupIcon,\n AddCustomerIcon,\n} from \"./../../../assets/icons\";\nimport { LocalStorageKey } from \"../../../constants/local-storage-key\";\nimport { CreateAppointmentModel } from \"../../../models/create-appointment-model\";\n\nimport { AppointmentCustomerSectionProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport CountryFlagIcon from \"../../../assets/flags\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport { ApiClient } from \"../../../api/api-client\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\nimport CustomerLastAppointmentsBlock from \"./CustomerLastAppointmentsBlock\";\n\n\nexport default function AppointmentCustomerSection(props: AppointmentCustomerSectionProps) {\n\n const { appointment, isEdition, customerId, onChange } = props;\n\n const classes = useStyles();\n const history = useHistory();\n const { t } = useTranslation([\"general\"]);\n \n const hasCustomerInfoVisible = ApiClient.getUserInfo().hasCustomerInfoVisible;\n \n const [search, setSearch] = useState<string>();\n const [customer, setCustomer] = useState<CustomerSearch>();\n const [customerModal, setCustomerModal] = useState<boolean>(false);\n const [customersSearch, setCustomersSearch] = useState<CustomerSearch[]>([]);\n\n const dispatch = useAppDispatch();\n const terminologyCreateNewCustomer = useCustomerTerminology(t(\"Create new customer\"), \"customer\");\n const terminologyFindCustomer = useCustomerTerminology(t(\"Find & select customer\"), \"customer\");\n const accountSettings = useAppSelector(selectAccountSettings);\n const { enqueueAlert } = alertsActions;\n\n const mobileTemplate: string = \"000-000-0000\";\n\n useEffect(() => {\n if (customerId) {\n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n const customer = await CustomerService.getCustomerInfoDetails(customerId);\n dispatch(navbarActions.setShowLoader(false));\n\n const countries = accountSettings.countries;\n let mobileCode = customer.mobileCodeIso3 ?? \"MEX\";\n customer.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n customer.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n customer.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n \n setCustomer(new CustomerSearch(customer));\n onChange(\n new CreateAppointmentModel({\n ...appointment,\n customerId: customerId,\n firstName: customer.firstName,\n lastName: customer.lastName,\n })\n );\n })();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [customerId]);\n\n useEffect(() => {\n async function fetchData() {\n await loadSearchData();\n }\n\n if (search) {\n fetchData();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [search]);\n\n const loadSearchData = async () => {\n const customers = await CustomerService.getSearch(search);\n\n const countries = accountSettings.countries;\n\n [...customers].map(customer => {\n let mobileCode = customer.mobileCodeIso3 ?? \"MEX\";\n customer.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits.toString();\n customer.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode.toString();\n customer.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n return customer;\n })\n \n setCustomersSearch(customers || []);\n };\n\n const getUser = (): string => {\n const accessToken = localStorage.getItem(LocalStorageKey.AccessToken) || \"\";\n const jsonPayload = JSON.parse(\n decodeURIComponent(\n atob(accessToken.split(\".\")[1].replace(/-/g, \"+\").replace(/_/g, \"/\"))\n .split(\"\")\n .map(function (c) {\n return \"%\" + (\"00\" + c.charCodeAt(0).toString(16)).slice(-2);\n })\n .join(\"\")\n )\n );\n return jsonPayload.fullname;\n };\n\n const handleCustomerCreated = (customer: any) => {\n\n const customerSearched = new CustomerSearch(customer);\n setCustomer(customerSearched);\n onChange(\n new CreateAppointmentModel({\n ...appointment,\n customerId: customer.id,\n firstName: customer.firstName,\n lastName: customer.lastName,\n })\n );\n setCustomerModal(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Customer Created\"),\n description: `${customer.firstName} ${customer.lastName}`\n })\n );\n };\n\n const handleCustomerDuplicated = (customer: any) => {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid number\"),\n description: t(\"This number already belongs to customer\"),\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n history.push(`${Url.Customers.Main}/${customer.id}`);\n },\n title: `${customer.firstName} ${customer.lastName}`,\n }\n })\n );\n };\n\n const mobileFormat = (mobile: string, template: any): string => {\n return conformToMask(mobile, GetMobileMaskByTemp(template || mobileTemplate)).conformedValue;\n };\n\n async function handleCustomerSelected(customer: CustomerSearch) {\n if (customer.id === null) { return; }\n\n const appointments = await CustomerService.getCustomerLastAppointmentsDetails(customer.id);\n\n const customerWithAppointments = {\n ...customer,\n appointments: appointments,\n };\n\n setCustomer(customerWithAppointments);\n\n onChange(\n new CreateAppointmentModel({\n ...appointment,\n customerId: customer.id,\n firstName: customer.firstName,\n lastName: customer.lastName\n })\n );\n }\n\n return (\n <div className={classes.customerSection}>\n <Typography className={classes.txtBody1Bold}>\n {isEdition ? t(\"Edit appointment\") : t(\"New appointment\")}\n </Typography>\n <div className={classes.personInCharge}>\n <Typography className={classes.txtBody2}>\n {isEdition ? t(\"PersonInChargeEdition\") : t(\"Person in charge:\")}\n </Typography>\n <Typography style={{ marginLeft: 3 }} className={classes.txtBody2Bold}>\n {isEdition ? appointment?.user : getUser()}\n </Typography>\n </div>\n {isEdition ? (\n <div className={classes.personInCharge}>\n <Typography className={classes.txtBody2}>\n {t(\"Appointment number:\")}\n </Typography>\n <Typography\n style={{ marginLeft: 3 }}\n className={classes.txtBody2Bold}\n >\n {appointment?.number}\n </Typography>\n </div>\n ) : null}\n <div\n className={classes.lineSeparator}\n style={{ width: 227, marginTop: 16, marginBottom: 28 }}\n />\n <div className={classes.customerInfoTitle}>\n <GroupIcon style={{ marginRight: 12 }} />\n <Typography className={classes.txtBody1Bold}>\n {useCustomerTerminology(t(\"Customer information\"), \"Customer information\")}\n </Typography>\n </div>\n {!isEdition ? (\n <Autocomplete\n style={{ width: 228, marginBottom: 24, height: 32 }}\n items={customersSearch}\n placeholder={terminologyFindCustomer}\n noBorder\n renderOption={(option: CustomerSearch) => {\n if (option.firstName) {\n return (\n <Typography\n className={`${classes.customerListOverrides} ${customer && customer.id === option.id\n ? classes.customerListSelected\n : classes.customerList\n }`}\n >\n {`${option.firstName} ${option.lastName}`}\n {hasCustomerInfoVisible &&\n <>\n { \" / \" }\n <CountryFlagIcon iso={option.mobileCodeIso3!} />\n {\" +\" + option.mobileCode + \" \"}\n {mobileFormat(option.mobile || \"\", option.mobileTemplate)}\n </>\n }\n </Typography>\n );\n }\n return option;\n }}\n getOptionSelected={(option, value) =>\n `${option.firstName} ${option.lastName}` ===\n `${value.firstName} ${value.lastName}`\n }\n getOptionLabel={() => \"\"}\n filterOptions={(options) => {\n const result = [...options];\n result.push(\n <ButtonWithSpinner\n width={196}\n borderRadius={ButtonPropsBorderRadius.Large}\n hoverColor={ButtonPropsColor.Main}\n fill={ButtonPropsFill.Outlined}\n innerText={ terminologyCreateNewCustomer }\n innerIcon={<AddCustomerIcon />}\n onClick={() => { setCustomerModal(true); }}\n />\n );\n return result;\n }}\n onChange={(value: any, reason) => {\n if (reason === \"input\" && value.length > 2) {\n setSearch(value);\n } else {\n setCustomersSearch([]);\n }\n }}\n onSelected={(option: CustomerSearch) => {\n handleCustomerSelected(option);\n }}\n />\n ) : null}\n <Typography className={classes.label2} style={{ width: 220, height: 14 }}>\n {useCustomerTerminology(t(\"Customer name\"), \"Customer name\")}\n </Typography>\n <Typography className={classes.label1} style={{ width: 220, height: 14 }}>\n {isEdition\n ? `${appointment?.firstName} ${appointment?.lastName}`\n : customer\n ? `${customer.firstName} ${customer.lastName}`\n : \"--\"}\n </Typography>\n {hasCustomerInfoVisible &&\n <>\n <Typography\n className={classes.label2}\n style={{ width: 220, height: 14, marginTop: 16 }}\n >\n {t(\"Mobile number\")}\n </Typography>\n <Typography className={classes.label1} style={{ width: 220, height: 14 }}>\n {isEdition\n ? mobileFormat(appointment?.mobile || \"\", appointment?.mobileTemplate || mobileTemplate)\n : customer\n ? mobileFormat(customer.mobile || \"\", customer.mobileTemplate)\n : \"--\"}\n </Typography>\n <Typography\n className={classes.label2}\n style={{ width: 220, height: 14, marginTop: 24 }}\n >\n {t(\"Email\")}\n </Typography>\n <Typography className={classes.label1} style={{ width: 220, height: 14 }}>\n {isEdition\n ? appointment?.email || \"--\"\n : customer\n ? customer.email\n ? customer.email\n : \"--\"\n : \"--\"}\n </Typography>\n {!isEdition && customer &&\n <CustomerLastAppointmentsBlock appointments={customer.appointments} />\n }\n </>\n }\n <CustomerModal\n open={customerModal}\n onClose={() => {\n setCustomerModal(false);\n }}\n onDuplicate={handleCustomerDuplicated}\n onCreate={handleCustomerCreated}\n />\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: 400,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"60px\",\n height: \"60px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 20px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnCancel: {\n background: \"#F6F6F6\",\n color: theme.colors.grey4,\n fontSize: 12,\n fontWeight: \"bold\",\n margin: \"auto\"\n },\n btnOk: {\n background: \"#FFC626\",\n borderRadius: 51,\n color: \"white\",\n fontSize: 12,\n margin: \"auto\",\n fontWeight: 700,\n paddingTop: 10,\n paddingBottom: 10,\n height: 37,\n width: 225,\n \"&:hover\": {\n background: \"#FFC626\",\n color: \"white\",\n fontSize: 12,\n }\n },\n separator: {\n height: 0,\n width: 217,\n margin: \"0px auto 20px auto\",\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n}));\n\nexport default useStyles;\n","export enum AppointmentScheduleBusyReason {\n TimeIsBusyAnotherAppointment = 0,\n BlockedScheduleTime,\n OutsideUserScheduleTime,\n WorkAreaIsBusyAnotherAppointment,\n OutsideBusinessHours,\n OutsideUserScheduleTimeAndOutsideBusinessHours,\n TimeIsBusyAnotherAppointmentCanNotContinue\n}\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { ExclamationIcon, CrossIcon } from \"../../../assets/icons\";\n\nimport { ExclamationModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\nconst ExclamationModal = (props: ExclamationModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, title, body, okTextButton, height, onClose } = props;\n const classes = useStyles();\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n\n <Fade in={open}>\n <div className={classes.modalPaperYellow} style={{height: height || \"auto\"}}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {title}\n </Typography>\n </div>\n \n <div className={classes.separator}></div>\n\n <div>\n {body}\n </div>\n\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnOk}`} onClick={onClose} >\n {okTextButton ? okTextButton : t(\"Ok\")}\n </Button>\n </div>\n\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default ExclamationModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modalCenter: {\n display: \"block\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n marginTop: 24,\n textAlign: \"center\"\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n textAlign: \"center\",\n marginBottom: 5\n },\n normalText: {\n ...theme.typography.txtBody1,\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n textAlign: \"center\",\n color: \"#5C6477\"\n },\n scheduleText: {\n ...theme.typography.txtBody1,\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n textAlign: \"center\",\n color: \"#5C6477\"\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\n\n\nimport ExclamationModal from \"../../common/ExclamationModal\";\nimport { AppointmentScheduleBusyModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Appointment } from \"../../../models/appointment\";\n\nconst AppointmentScheduleBusyModal = (props: AppointmentScheduleBusyModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, appointmentBusyModalData, appointment, onClose } = props;\n const classes = useStyles();\n \n const [appointmentSchedule, setAppointmentSchedule] = useState<Appointment>()\n\n useEffect(() => {\n\n if (appointment.startDate && appointment.services) {\n const duration = appointment.services\n .map((service: { duration: any; }) => service.duration)\n .reduce((prev: any, next: any) => (prev || 0) + (next || 0));\n const endDate = new Date(\n new Date(appointment.startDate).getTime() + (duration || 0) * 60000\n );\n\n setAppointmentSchedule({\n ...appointment,\n endDate: endDate\n });\n }\n\n }, [appointment]);\n\n const BusyScheduleInfo = () => <>\n <div>\n <Typography className={classes.normalText}>\n {t(\"It is not possible to schedule the appointment at this time because the selected specialist has a schedule block activated.\")}\n </Typography>\n </div>\n\n <div>\n <Typography className={classes.normalText} style={{ marginTop: 10 }}>\n {t(\"We suggest you modify the customized schedule or select another specialist.\")}\n </Typography>\n </div>\n </>\n\n\n return (<>\n \n <ExclamationModal\n open={open}\n title={`${t(\"Specialist not available\")}`}\n body={<BusyScheduleInfo />}\n okTextButton={t(\"OkDeAcuerdo\")}\n height={360}\n onClose={onClose}\n />\n\n </>)\n};\n\nexport default AppointmentScheduleBusyModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"18px 24px 24px 24px\",\n width: 464,\n height: 340,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 15,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n saveAppointment: {\n background: \"#FFC626\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#FFC626\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n radioLabelRoot: {\n margin: 0,\n marginRight: 15\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n radioOption: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: \"#4A4D51\", //theme.colors.clearMain,\n },\n },\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { CrossIcon, ExclamationIcon } from \"../../../assets/icons\";\n\nimport { RecurringAppointmentUpdateModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { FormControlLabel, Radio, RadioGroup } from \"@material-ui/core\";\nimport {useAppSelector} from \"../../../redux/hooks\";\n\n\nconst RecurringAppointmentUpdateModal = (props: RecurringAppointmentUpdateModalProps) => {\n const { open, appointment, service, onClose, onUpdate } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n \n const optionUpdateOnlyThisAppointment = 0;\n const optionUpdateThisAndFutureAppointment = 1;\n const [selectedOptionToUpdate, setSelectedOptionToUpdate] = useState<number>(-1);\n const [disableButton, setDisableButton] = useState<boolean>(false);\n\n const date = (startDate: Date, endDate: Date): string => {\n const start = new Date(startDate);\n const end = new Date(endDate);\n\n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n\n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n\n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n\n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n\n const timeDifference = (today: Date, endDate: Date): string => {\n const hours = parseInt(\n `${\n (Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60 * 60)) % 24\n }`\n );\n const minutes = parseInt(\n `${(Math.abs(endDate.getTime() - today.getTime()) / (1000 * 60)) % 60}`\n );\n if (hours > 0 && minutes < 1) {\n return `${hours}hr`;\n } else if (hours < 1 && minutes > 0) {\n return `${minutes}min`;\n } else {\n return `${hours}hr ${minutes}min`;\n }\n };\n\n \n const handleUpdateOption = (event: any) => {\n setSelectedOptionToUpdate(+event.target.value);\n }\n\n useEffect(() => {\n setSelectedOptionToUpdate(-1);\n setDisableButton(false);\n }, [open]);\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Edit recurring appointment\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {appointment?.customerName}\n {service ? ` - ${service}` : \"\"}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalDateText}>\n {`${date(\n appointment?.startDate.toJSDate(),\n appointment?.endDate.toJSDate()\n )} (${timeDifference(\n appointment?.startDate.toJSDate(),\n appointment?.endDate.toJSDate()\n )})`}\n </Typography>\n </div>\n \n <div style={{textAlign: \"center\", marginTop: 15}}>\n <div style={{display: \"inline-block\"}}>\n <RadioGroup\n defaultValue={-1}\n aria-label=\"appointmentEnds\"\n name=\"appointmentEnds\"\n onChange={handleUpdateOption}\n value={selectedOptionToUpdate}\n row \n >\n\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={optionUpdateOnlyThisAppointment}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={t(\"This appointment\")}\n />\n\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={optionUpdateThisAndFutureAppointment}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={t(\"This and the following appointments\")}\n />\n \n </RadioGroup>\n </div>\n </div>\n\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n disabled={disableButton || selectedOptionToUpdate===-1}\n className={`${classes.button} ${classes.saveAppointment}`}\n onClick={() => {\n setDisableButton(true);\n onUpdate(selectedOptionToUpdate === optionUpdateThisAndFutureAppointment);\n }}\n >\n {t(\"Save changes\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default RecurringAppointmentUpdateModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n border: \"solid 1px #DBDCDD\",\n borderRadius: 12,\n padding: \"40px 40px 32px\",\n display: \"flex\",\n backgroundColor: \"#FFF\",\n width: 1070,\n margin: \"auto\",\n },\n appointmentSection: {\n display: \"block\",\n width: \"100%\",\n },\n breadcrumb: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: \"#5C6477\"\n },\n breadcrumbContainer: {\n padding: \"0 80px 16px\",\n margin: \"auto\",\n },\n boldFont: {\n \"& .MuiTypography-root\": {\n color: \"#1D2027\",\n fontWeight: 500,\n fontStyle: \"normal\",\n fontSize: 14,\n }\n },\n actions: {\n height: 72,\n position: \"fixed\",\n bottom: 0,\n left: 0,\n width: \"100%\",\n backgroundColor: \"#FAFAFA\",\n padding: \"14px 61px 14px 77px\",\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n zIndex: 999\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: \"15px\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n newAppointment: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n \"&.Mui-disabled\": {\n color: \"#F6F6F6\",\n opacity: 0.3,\n },\n },\n deleteButton: {\n height: 32,\n width: 32,\n marginRight: 15,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n margin: \"24px 0px 8px 0px\",\n },\n totalPriceBoldText: {\n marginBottom: 8,\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey6,\n },\n totalPriceText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey6,\n },\n goBackCancel: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n \"&:hover\": {\n background: theme.colors.grey3,\n color: theme.colors.grey1,\n },\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n width: 464,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"18px 24px 24px 24px\",\n minWidth: 320,\n margin: \"0 20px\",\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteAppointment: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport moment from \"moment\";\n\nimport { CrossIcon } from \"../../../assets/icons\";\n\nimport useStyles from \"./css\";\nimport { BusyScheduleQuestionModalProps } from \"./props\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nconst BusyScheduleQuestionModal = (props: BusyScheduleQuestionModalProps) => {\n const { open, appointmentBusyModalData, onClose, onContinue, appointment } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const date = (startDate: Date, duration: number): string => {\n const start = new Date(startDate);\n const end = moment(start).add(duration, 'm').toDate();\n\n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n\n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n\n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n \n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n\n const getDuration = (duration: number): string => {\n const seconds = duration * 60;\n const hour = Math.floor(seconds / 3600);\n const minute = Math.floor((seconds % 3600) / 60);\n const hourDisplay = hour > 0 ? `${hour} ${hour === 1 ? \"hr\" : \"hrs\"} ` : \"\";\n const minuteDisplay = minute > 0 ? `${minute} min` : \"\";\n const format = hourDisplay + minuteDisplay;\n return format.trim();\n };\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"There are already scheduled appointments at this time, do you want to continue?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {(appointmentBusyModalData?.customerName) + (\" - \") + (appointmentBusyModalData?.serviceName)}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalDateText}>\n {`${date(\n appointmentBusyModalData?.startData ?? new Date(),\n appointmentBusyModalData?.appointmentDuration ?? 0\n )} (${getDuration(appointmentBusyModalData?.appointmentDuration ?? 0)})`}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.deleteAppointment}`}\n onClick={() => {\n if (onContinue) {\n onContinue();\n }\n }}\n >\n {t(\"Continue\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default BusyScheduleQuestionModal;\n","import { AppointmentScheduleBusyReason } from \"./enums/appointment-schedule-busy-reason\";\n\nexport class AppointmentBusyModalDataModel {\n customerName: string | null;\n serviceName: string | null;\n workArea: string | null;\n startData: Date;\n appointmentDuration: number | null;\n appointmentScheduleBusyReason: AppointmentScheduleBusyReason | null;\n\n constructor(x?: any) {\n if (typeof x == \"object\") {\n this.customerName = x.customerName;\n this.serviceName = x.serviceName;\n this.workArea = x.workArea;\n this.startData = x.startData;\n this.appointmentDuration = x.appointmentDuration;\n this.appointmentScheduleBusyReason = x.appointmentScheduleBusyReason;\n } else {\n this.customerName =null;\n this.serviceName = null;\n this.workArea = null;\n this.startData = new Date();\n this.appointmentDuration = null;\n this.appointmentScheduleBusyReason = null;\n }\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modalCenter: {\n display: \"block\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n marginTop: 24,\n textAlign: \"center\"\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n textAlign: \"center\",\n marginBottom: 5\n },\n normalText: {\n ...theme.typography.txtBody1,\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n textAlign: \"center\",\n color: \"#5C6477\"\n },\n scheduleText: {\n ...theme.typography.txtBody1,\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n textAlign: \"center\",\n color: \"#5C6477\"\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport {Trans, useTranslation} from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport moment from \"moment\";\n\nimport ExclamationModal from \"../../common/ExclamationModal\";\n\nimport useStyles from \"./css\";\nimport { AppointmentWorkAreaBusyModalProps } from \"./props\";\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nconst AppointmentWorkAreaBusyModal = (props: AppointmentWorkAreaBusyModalProps) => {\n const { open, appointmentBusyModalData, onClose } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const date = (startDate: Date, duration: number): string => {\n const start = new Date(startDate);\n const end = moment(start).add(duration, 'm').toDate();\n\n let weekDay = start.toLocaleString(localeApp, {\n weekday: \"long\",\n });\n\n weekDay = `${weekDay.charAt(0).toUpperCase()}${weekDay.slice(1)}`;\n\n const monthDay = start.toLocaleString(localeApp, {\n day: \"2-digit\",\n month: \"long\",\n });\n \n const startTime = start.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n const endTime = end.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n return `${weekDay}, ${monthDay} \\u00B7 ${startTime} - ${endTime}hrs`;\n };\n\n const getDuration = (duration: number): string => {\n const seconds = duration * 60;\n const hour = Math.floor(seconds / 3600);\n const minute = Math.floor((seconds % 3600) / 60);\n const hourDisplay = hour > 0 ? `${hour} ${hour === 1 ? \"hr\" : \"hrs\"} ` : \"\";\n const minuteDisplay = minute > 0 ? `${minute} min` : \"\";\n const format = hourDisplay + minuteDisplay;\n return format.trim();\n };\n\n const BusyScheduleInfo = () => <>\n <div>\n <Typography className={classes.normalText}>\n <Trans i18nKey=\"TheWorkAreaIsBusy\" t={t} values={{ workArea: appointmentBusyModalData?.workArea || \"\" }}/>\n </Typography>\n </div>\n\n <div className={classes.modalDateText}>\n <Typography className={classes.scheduleText}>\n {`${date(\n appointmentBusyModalData?.startData ?? new Date(),\n appointmentBusyModalData?.appointmentDuration ?? 0\n )} (${getDuration(appointmentBusyModalData?.appointmentDuration ?? 0)})`}\n </Typography>\n </div>\n\n <div>\n <Typography className={classes.normalText}>\n {t(\"Please select another work area.\")}\n </Typography>\n </div>\n </>\n\n return (\n <ExclamationModal\n open={open}\n title={t(\"Busy work area\")}\n body={<BusyScheduleInfo />}\n okTextButton={t(\"OkUnderstand\")}\n height={330}\n onClose={onClose}\n />\n );\n};\n\nexport default AppointmentWorkAreaBusyModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {\n fontFamily: \"Inter, sans-serif\",\n },\n bodyContent: {\n color: theme.colors.grey5,\n textAlign: \"center\"\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"60px\",\n height: \"60px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 20px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 196,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnCancel: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n btnOk: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n separator: {\n height: 0,\n width: 217,\n margin: \"0px auto 20px auto\",\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { BroadcastIcon, CrossIcon } from \"../../../assets/icons\";\n\nimport { OutsideBusinessHoursModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nconst OutsideBusinessHoursModal = (props: OutsideBusinessHoursModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, onClose, onCancel, onConfirm } = props;\n const classes = useStyles();\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n\n <Fade in={open}>\n <div className={classes.modalPaperYellow}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <BroadcastIcon />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"Appointment outside business hours\")}\n </Typography>\n </div>\n \n <div className={classes.separator}></div>\n\n <div className={classes.bodyContent}>\n <div>\n {t(\"The customized schedule is outside the establishment's business hours.\")}\n </div>\n <br/>\n <div>\n {t(\"Do you want to continue?\")}\n </div>\n </div>\n\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnCancel}`} onClick={onCancel} >\n {t(\"Go back\")}\n </Button>\n <Button className={`${classes.button} ${classes.btnOk}`} onClick={onConfirm} >\n {t(\"Yes, continue\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default OutsideBusinessHoursModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {\n fontFamily: \"Inter, sans-serif\",\n },\n bodyContent: {\n color: theme.colors.grey5,\n textAlign: \"center\"\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"60px\",\n height: \"60px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 20px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 196,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnCancel: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n btnOk: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n separator: {\n height: 0,\n width: 217,\n margin: \"0px auto 20px auto\",\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation, Trans } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { AppointmentOutsideScheduleModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Appointment } from \"../../../models/appointment\";\nimport { AppointmentScheduleBusyReason } from \"../../../models/enums/appointment-schedule-busy-reason\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport { BroadcastIcon, CrossIcon } from \"../../../assets/icons\";\nimport Button from \"@material-ui/core/Button\";\nimport Modal from \"@material-ui/core/Modal\";\n\nconst AppointmentOutsideScheduleModal = (props: AppointmentOutsideScheduleModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, appointmentBusyModalData, appointment, onClose, onContinue } = props;\n const classes = useStyles();\n \n const [appointmentSchedule, setAppointmentSchedule] = useState<Appointment>()\n\n useEffect(() => {\n\n if (appointment.startDate && appointment.services) {\n const duration = appointment.services\n .map((service: { duration: any; }) => service.duration)\n .reduce((prev: any, next: any) => (prev || 0) + (next || 0));\n const endDate = new Date(\n new Date(appointment.startDate).getTime() + (duration || 0) * 60000\n );\n\n setAppointmentSchedule({\n ...appointment,\n endDate: endDate\n });\n }\n\n }, [appointment]);\n\n const textLine = (appointmentBusyModalReason: AppointmentScheduleBusyReason) => {\n switch (appointmentBusyModalReason) {\n case AppointmentScheduleBusyReason.OutsideUserScheduleTime:\n return \"This appointment is outside the specialist's working hours.\"\n case AppointmentScheduleBusyReason.OutsideUserScheduleTimeAndOutsideBusinessHours:\n return \"This appointment is outside the establishment's and specialist's working hours.\"\n }\n }\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n \n <Fade in={open}>\n <div className={classes.modalPaperYellow}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <BroadcastIcon />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n \n <div className={classes.modalContent}>\n \n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"Out-of-hours appointment\")}\n </Typography>\n </div>\n \n <div className={classes.separator}></div>\n \n <div className={classes.bodyContent}>\n <div>\n <Trans i18nKey={textLine(appointmentBusyModalData?.appointmentScheduleBusyReason ?? AppointmentScheduleBusyReason.OutsideUserScheduleTime)} t={t} components={{ bold: <b /> }} />\n </div>\n <br/>\n <div>\n {t(\"Do you want to continue?\")}\n </div>\n </div>\n \n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnCancel}`} onClick={onClose} >\n {t(\"Go back\")}\n </Button>\n <Button className={`${classes.button} ${classes.btnOk}`} onClick={onContinue} >\n {t(\"Yes, continue\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n )\n};\n\nexport default AppointmentOutsideScheduleModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {\n fontFamily: \"Inter, sans-serif\",\n },\n bodyContent: {\n color: theme.colors.grey5,\n textAlign: \"center\"\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"60px\",\n height: \"60px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 20px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 196,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnOk: {\n background: \"#FFC626\",\n color: \"#F6F6F6\",\n },\n separator: {\n height: 0,\n width: 217,\n margin: \"0px auto 20px auto\",\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation, Trans } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { BroadcastIcon, CrossIcon } from \"../../../assets/icons\";\n\nimport { TimeIsBusyAnotherAppointmentCanNotContinueModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nconst TimeIsBusyAnotherAppointmentCanNotContinueModal = (props: TimeIsBusyAnotherAppointmentCanNotContinueModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, onClose } = props;\n const classes = useStyles();\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n\n <Fade in={open}>\n <div className={classes.modalPaperYellow}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <BroadcastIcon />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"There's another appointment scheduled at the same time\")}\n </Typography>\n </div>\n \n <div className={classes.separator}></div>\n\n <div className={classes.bodyContent}>\n <div>\n {t(\"The selected specialist is not available because they already have another appointment scheduled at this time.\")}\n </div>\n <br/>\n <div>\n <Trans ns={[\"general\"]} i18nKey=\"We recommend activating the Schedule simultaneous appointments switch button so that your specialists can attend appointments at the same time.\">\n We recommend activating the \"<a href='/settings'>Schedule simultaneous appointments</a>\" switch button so that your specialists can attend appointments at the same time.\n </Trans>\n </div>\n </div>\n\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnOk}`} onClick={onClose} >\n {t(\"Understood\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default TimeIsBusyAnotherAppointmentCanNotContinueModal;\n","import React, { useState, useEffect } from \"react\";\nimport { useParams } from \"react-router-dom\";\nimport { useHistory } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Button from \"@material-ui/core/Button\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Breadcrumbs from '@material-ui/core/Breadcrumbs';\nimport Link from '@material-ui/core//Link';\n\nimport { Url } from \"./../../../constants/url\";\nimport { Appointment } from \"../../../models/appointment\";\nimport { CreateAppointmentModel } from \"../../../models/create-appointment-model\";\nimport { AppointmentService } from \"./../../../api/appointment-service\";\nimport { TrashIcon } from \"../../../assets/icons\";\nimport AppointmentStepOne from \"./../AppointmentStepOne\";\nimport AppointmentStepTwo from \"./../AppointmentStepTwo\";\nimport AppointmentDeleteModal from \"./../AppointmentDeleteModal\";\nimport AppointmentCustomerSection from \"./../AppointmentCustomerSection\";\nimport { useAppDispatch, useAppSelector } from \"./../../../redux/hooks\";\nimport { alertsActions } from \"./../../../redux/alerts-slice\";\nimport { ApiClient } from \"../../../api/api-client\";\nimport AppointmentScheduleBusyModal from \"../AppointmentScheduleBusyModal\";\nimport RecurringAppointmentUpdateModal from \"../RecurringAppointmentUpdateModal\";\nimport RecurringAppointmentDeleteModal from \"../RecurringAppointmentDeleteModal\";\nimport useStyles from \"./css\";\nimport BusyScheduleQuestionModal from \"../../common/BusyScheduleQuestion/busy-schedule-question\";\nimport { CustomerFrequencyType } from \"../../../models/enums/customer-frequency-type\";\nimport { AppointmentScheduleBusyReason } from \"../../../models/enums/appointment-schedule-busy-reason\";\nimport { AppointmentBusyModalDataModel } from \"../../../models/appointment-busy-modal-data-model\";\nimport { AppointmentBlocker } from \"../../../models/appointment-blocker\";\nimport AppointmentWorkAreaBusyModal from \"../../common/AppointmentWorkAreaBusyModal\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport OutsideBusinessHoursModal from \"../../common/OutsideBusinessHoursModal\";\nimport AppointmentOutsideScheduleModal from \"../AppointmentOutsideScheduleModal\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport TimeIsBusyAnotherAppointmentCanNotContinueModal\n from \"../../common/TimeIsBusyAnotherAppointmentCanNotContinueModal\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\nexport default function AppointmentDetails() {\n const classes = useStyles();\n const history = useHistory();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n const { appointmentId } = useParams<any>();\n const { t } = useTranslation([\"general\"]);\n const [appointment, setAppointment] = useState<CreateAppointmentModel>(\n new CreateAppointmentModel()\n );\n const [deleteAppointment, setDeleteAppointment] = useState<Appointment>(\n new Appointment()\n );\n const [updateRecurringAppointment, setUpdateRecurringAppointment] = useState<Appointment>(\n new Appointment()\n );\n const [step1Valid, setStep1Valid] = useState<boolean>(false);\n const [step2Valid, setStep2Valid] = useState<boolean>(false);\n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [deleteModal, setDeleteModal] = useState<boolean>(false);\n const [firstService, setFirstService] = useState<string>();\n const [showRecurringAppointmentUpdateModal, setShowRecurringAppointmentUpdateModal] = useState<boolean>(false);\n const [showRecurringAppointmentDeleteModal, setShowRecurringAppointmentDeleteModal] = useState<boolean>(false);\n const [openExclamationScheduleBusyModal, setOpenExclamationScheduleBusyModal] = useState<boolean>(false);\n const [openOutsideScheduleModal, setOpenOutsideScheduleModal] = useState<boolean>(false);\n const [openQuestionScheduleBusyModal, setOpenQuestionScheduleBusyModal] = useState<boolean>(false);\n const [openAppointmentWorkAreaBusyModal, setOpenAppointmentWorkAreaBusyModal] = useState<boolean>(false);\n const [openOutsideBusinessHoursModal, setOpenOutsideBusinessHoursModal] = useState<boolean>(false);\n const [openTimeIsBusyAnotherAppointmentCanNotContinueModal, setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal] = useState<boolean>(false);\n const [appointmentBusyModalData, setAppointmentBusyModalData] = useState<AppointmentBusyModalDataModel>();\n const [refreshAvailableHours, setRefreshAvailableHours] = useState<number>(0);\n const accountSettings = useAppSelector(selectAccountSettings);\n const getTemplatedCurrencyValue = useCurrencyValueTemplate(accountSettings.currencyTemplate);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const userInfo = useAppSelector(state => state.userInfo);\n\n useEffect(() => {\n dispatch(applicationInterfaceActions.updateTitle(t(\"Edit appointment\")));\n\n async function fetchData() {\n await loadAppointmentDetail();\n }\n\n fetchData();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useEffect(() => {\n if (accountSettings.countries.length) {\n let newAppointment = appointment;\n const countries = accountSettings.countries;\n let mobileCode = newAppointment.mobileCodeIso3 ?? \"MEX\";\n newAppointment.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n newAppointment.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n newAppointment.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n setAppointment(newAppointment);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [accountSettings.countries]);\n\n const loadAppointmentDetail = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const appointment = await AppointmentService.get(appointmentId);\n dispatch(navbarActions.setShowLoader(false));\n setAppointment(appointment);\n if (appointment.startDate && appointment.services) {\n const duration = appointment.services\n .map((service) => service.duration)\n .reduce((prev, next) => (prev || 0) + (next || 0));\n const endDate = new Date(\n new Date(appointment.startDate).getTime() + (duration || 0) * 60000\n );\n setFirstService(appointment.services[0].name || undefined);\n setDeleteAppointment(\n new Appointment({\n ...appointment,\n customerName: `${appointment.firstName} ${appointment.lastName}`,\n customerEmail: appointment.email,\n customerMobile: appointment.mobile,\n endDate: endDate,\n })\n );\n }\n };\n\n const formatDate = (date: Date | null): string => {\n const day = date?.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n const month = date?.toLocaleString(localeApp, {\n month: \"long\",\n });\n const year = date?.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n\n return `${day}/${month}/${year}`;\n };\n \n const totalServicesPrice = (appointment?.totalPriceForRecurringAppointments ?? 0) \n + appointment.services.reduce((total, service) => total + service.price, 0);\n \n const handleSaveButton = () => {\n if (appointment.isRecurring) {\n\n if (appointment.startDate && appointment.services) {\n const duration = appointment.services\n .map((service) => service.duration)\n .reduce((prev, next) => (prev || 0) + (next || 0));\n const endDate = new Date(\n new Date(appointment.startDate).getTime() + (duration || 0) * 60000\n );\n setFirstService(appointment.services[0].name || undefined);\n setUpdateRecurringAppointment(\n new Appointment({\n ...appointment,\n customerName: `${appointment.firstName} ${appointment.lastName}`,\n customerEmail: appointment.email,\n customerMobile: appointment.mobile,\n endDate: endDate,\n }));\n }\n\n setShowRecurringAppointmentUpdateModal(true);\n } else {\n updateAppointment();\n }\n };\n\n const handleSaveRecurringAppointmentButton = (allRecurringAppointments: boolean) => {\n const newAppointment = {\n ...appointment,\n updateAllRecurringAppointments: allRecurringAppointments\n };\n setShowRecurringAppointmentUpdateModal(false);\n updateAppointment(newAppointment);\n };\n\n function setAppointmentBusyData(appointmentBlocker: AppointmentBlocker, appointmentScheduleBusyReason: AppointmentScheduleBusyReason) {\n setAppointmentBusyModalData(\n new AppointmentBusyModalDataModel({\n customerName: appointmentBlocker?.customerName,\n serviceName: appointmentBlocker?.serviceName,\n workArea: appointmentBlocker?.workArea,\n startData: appointmentBlocker?.startData,\n appointmentDuration: appointmentBlocker?.appointmentDuration,\n appointmentScheduleBusyReason: appointmentScheduleBusyReason,\n }));\n openScheduleBusyModal(appointmentScheduleBusyReason);\n }\n\n function openScheduleBusyModal(data: AppointmentScheduleBusyReason) {\n switch (data) {\n case AppointmentScheduleBusyReason.TimeIsBusyAnotherAppointment:\n setOpenQuestionScheduleBusyModal(true);\n break;\n case AppointmentScheduleBusyReason.BlockedScheduleTime:\n setOpenExclamationScheduleBusyModal(true);\n break;\n case AppointmentScheduleBusyReason.OutsideUserScheduleTime:\n setOpenOutsideScheduleModal(true);\n break;\n case AppointmentScheduleBusyReason.OutsideUserScheduleTimeAndOutsideBusinessHours:\n setOpenOutsideScheduleModal(true);\n break;\n case AppointmentScheduleBusyReason.WorkAreaIsBusyAnotherAppointment:\n setOpenAppointmentWorkAreaBusyModal(true);\n break;\n case AppointmentScheduleBusyReason.OutsideBusinessHours:\n setOpenOutsideBusinessHoursModal(true);\n break;\n case AppointmentScheduleBusyReason.TimeIsBusyAnotherAppointmentCanNotContinue:\n setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal(true);\n break;\n default:\n setOpenExclamationScheduleBusyModal(true);\n break;\n }\n }\n\n const updateAppointment = (newAppointment?: CreateAppointmentModel) => {\n const appointmentUpdate = newAppointment ?? appointment;\n dispatch(navbarActions.setShowLoader(true));\n AppointmentService.update(appointmentUpdate).then((data) => {\n dispatch(navbarActions.setShowLoader(false));\n if (data.isScheduleBusy) {\n setAppointmentBusyData(data.appointmentBlocker, data.appointmentScheduleBusyReason);\n setRefreshAvailableHours(refreshAvailableHours + 1);\n setStep2Valid(false);\n return;\n } else {\n dispatch(applicationInterfaceActions.updateTitle(t(\"Appointments\")));\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Appointment updated\"),\n description: `${appointment.firstName} ${appointment.lastName\n } - ${formatDate(appointment.startDate)}`,\n })\n );\n history.push(`${Url.Appointments.Main}`);\n }\n });\n };\n\n const handleDelete = (allRecurringAppointments: boolean) => {\n if (appointment.id) {\n AppointmentService.remove(appointment.id as string, allRecurringAppointments).then(() => {\n dispatch(applicationInterfaceActions.updateTitle(t(\"Appointments\")));\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Appointment deleted\"),\n description: t(\"Appointment has been successfully deleted.\"),\n })\n );\n history.push(`${Url.Appointments.Main}`);\n });\n }\n };\n\n const handleDeleteModal = () => {\n if (appointment.isRecurring) {\n setShowRecurringAppointmentDeleteModal(true);\n } else {\n setDeleteModal(true);\n }\n };\n\n const handleContinueScheduleBusyModal = () => {\n const newAppointment = {\n ...appointment,\n isIgnoreScheduleBusy: true\n };\n updateAppointment(newAppointment);\n };\n\n return (<>\n\n <div style={{ paddingBottom: 75 }}>\n <div className={classes.breadcrumbContainer}>\n <Breadcrumbs aria-label=\"breadcrumb\" className={classes.breadcrumb}>\n <Link\n underline=\"hover\"\n color=\"inherit\"\n href=\"/appointments\"\n >\n {t(\"Appointments\")}\n </Link>\n <div className={classes.boldFont}>\n <Typography> {t(\"Edit appointment\")}</Typography>\n </div>\n </Breadcrumbs>\n </div>\n <div className={classes.root}>\n <AppointmentCustomerSection\n appointment={appointment}\n onChange={(appointment) => {\n setAppointment(appointment);\n }}\n isEdition\n />\n <div className={classes.appointmentSection}>\n <AppointmentStepOne\n appointment={appointment}\n onChange={(appointment: any, isValid: any) => {\n setAppointment(appointment);\n setStep1Valid(isValid);\n }}\n />\n <AppointmentStepTwo\n appointment={appointment}\n step1Valid={step1Valid}\n isEdition\n refreshData={refreshAvailableHours}\n onChange={(appointment: any, isValid: any) => {\n if (isValid) {\n setAppointment(appointment);\n }\n\n setStep2Valid(isValid);\n }}\n />\n </div>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.modalCancelPaper}>\n <div>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Cancel appointment edition?\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBackCancel}`}\n onClick={() => setCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n setCancelModal(false);\n history.push(`${Url.Appointments.Main}`);\n }}\n >\n {t(\"Yes, cancel\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n\n <AppointmentDeleteModal\n open={deleteModal}\n appointment={deleteAppointment}\n service={firstService}\n onClose={() => {\n setDeleteModal(false);\n }}\n onDelete={() => handleDelete(false)}\n />\n\n <RecurringAppointmentUpdateModal\n open={showRecurringAppointmentUpdateModal}\n appointment={updateRecurringAppointment}\n service={firstService}\n onClose={() => {\n setShowRecurringAppointmentUpdateModal(false);\n }}\n onUpdate={handleSaveRecurringAppointmentButton}\n />\n\n <RecurringAppointmentDeleteModal\n open={showRecurringAppointmentDeleteModal}\n appointment={deleteAppointment}\n service={firstService}\n onClose={() => {\n setShowRecurringAppointmentDeleteModal(false);\n }}\n onDelete={handleDelete}\n />\n <BusyScheduleQuestionModal\n open={openQuestionScheduleBusyModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenQuestionScheduleBusyModal(false)}\n onContinue={handleContinueScheduleBusyModal}\n />\n <AppointmentWorkAreaBusyModal\n open={openAppointmentWorkAreaBusyModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenAppointmentWorkAreaBusyModal(false)}\n />\n <AppointmentScheduleBusyModal\n open={openExclamationScheduleBusyModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenExclamationScheduleBusyModal(false)}\n />\n <AppointmentOutsideScheduleModal\n open={openOutsideScheduleModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenOutsideScheduleModal(false)}\n onContinue={handleContinueScheduleBusyModal}\n />\n <OutsideBusinessHoursModal\n open={openOutsideBusinessHoursModal}\n onClose={() => setOpenOutsideBusinessHoursModal(false)}\n onCancel={() => setOpenOutsideBusinessHoursModal(false)}\n onConfirm={handleContinueScheduleBusyModal}\n />\n <TimeIsBusyAnotherAppointmentCanNotContinueModal\n open={openTimeIsBusyAnotherAppointmentCanNotContinueModal}\n onClose={() => setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal(false)}\n />\n </div>\n \n <div className={classes.actions}>\n <div>\n {(appointment.isRecurring && userInfo.showPrices) && <div>\n <div className={classes.totalPriceBoldText}>\n {t(\"Total for the {{count}} appointments: {{total}}\", {\n count: appointment.recurredAppointmentsCount ?? 0,\n total: getTemplatedCurrencyValue((totalServicesPrice) ?? 0),\n })}\n </div>\n <div className={classes.totalPriceText}>\n {t(\"Total per appointment: {{price}}\", {\n price: getTemplatedCurrencyValue(totalServicesPrice / (appointment.recurredAppointmentsCount ?? 1)),\n })}\n </div>\n </div>}\n </div>\n <div>\n <IconButton\n className={classes.deleteButton}\n onClick={handleDeleteModal}\n >\n <TrashIcon style={{ color: \"#ACB7C0\" }}/>\n </IconButton>\n <ButtonWithSpinner\n width={200}\n margin={\"0px 16px 0px 0px\"}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n innerText={t(\"Go back\")}\n onClick={() => { setCancelModal(true); }}\n />\n <ButtonWithSpinner\n width={200}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Save changes\")}\n onClick={handleSaveButton}\n disabled={!appointment.customerId || !step1Valid || !step2Valid}\n isProcessing={useAppSelector((state) => state.navbar.showLoader) ?? undefined}\n />\n </div>\n </div>\n </div>\n </>);\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n border: \"solid 1px #DBDCDD\",\n borderRadius: 12,\n padding: \"40px 40px 50px 40px\",\n display: \"flex\",\n backgroundColor: \"#FFF\",\n width: 1070,\n margin: \"auto\",\n },\n appointmentSection: {\n display: \"block\",\n width: \"100%\",\n },\n breadcrumb: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: \"#5C6477\"\n },\n breadcrumbContainer: {\n padding: \"0 80px 16px\",\n margin: \"auto\",\n },\n actions: {\n height: 72,\n position: \"fixed\",\n bottom: 0,\n left: 0,\n width: \"100%\",\n backgroundColor: \"#FAFAFA\",\n padding: \"14px 61px 14px 77px\",\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n zIndex: 999\n },\n \n boldFont: {\n \"& .MuiTypography-root\": {\n color: \"#1D2027\",\n fontWeight: 500,\n fontStyle: \"normal\",\n fontSize: 14,\n }\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: \"15px\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n newAppointment: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n \"&.Mui-disabled\": {\n color: \"#F6F6F6\",\n opacity: 0.3,\n },\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n margin: \"24px 0px 8px 0px\",\n },\n totalPriceBoldText: {\n marginBottom: 8,\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey6,\n },\n totalPriceText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey6,\n },\n goBackCancel: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n \"&:hover\": {\n background: theme.colors.grey3,\n color: theme.colors.grey1,\n },\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\nimport { useHistory, useParams } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Button from \"@material-ui/core/Button\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Breadcrumbs from '@material-ui/core/Breadcrumbs';\nimport Link from '@material-ui/core//Link';\n\nimport { Url } from \"./../../../constants/url\";\nimport AppointmentStepOne from \"./../AppointmentStepOne\";\nimport AppointmentStepTwo from \"./../AppointmentStepTwo\";\nimport { CreateAppointmentModel } from \"../../../models/create-appointment-model\";\nimport AppointmentCustomerSection from \"./../AppointmentCustomerSection\";\nimport { AppointmentService } from \"../../../api/appointment-service\";\nimport { useAppDispatch, useAppSelector } from \"./../../../redux/hooks\";\nimport { alertsActions } from \"./../../../redux/alerts-slice\";\nimport AppointmentScheduleBusyModal from \"../AppointmentScheduleBusyModal\";\nimport useStyles from \"./css\";\nimport BusyScheduleQuestionModal from \"../../common/BusyScheduleQuestion\";\nimport { AppointmentBusyModalDataModel } from \"../../../models/appointment-busy-modal-data-model\";\nimport { AppointmentScheduleBusyReason } from \"../../../models/enums/appointment-schedule-busy-reason\";\nimport { AppointmentBlocker } from \"../../../models/appointment-blocker\";\nimport AppointmentWorkAreaBusyModal from \"../../common/AppointmentWorkAreaBusyModal\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport OutsideBusinessHoursModal from \"../../common/OutsideBusinessHoursModal\";\nimport AppointmentOutsideScheduleModal from \"../AppointmentOutsideScheduleModal\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport TimeIsBusyAnotherAppointmentCanNotContinueModal\n from \"../../common/TimeIsBusyAnotherAppointmentCanNotContinueModal\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\nconst AppointmentNew = () => {\n\n const classes = useStyles();\n const history = useHistory();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n const { t } = useTranslation([\"general\"]);\n const [appointment, setAppointment] = useState<CreateAppointmentModel>(\n new CreateAppointmentModel()\n );\n const [step1Valid, setStep1Valid] = useState<boolean>(false);\n const [step2Valid, setStep2Valid] = useState<boolean>(false);\n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [isClicked, setIsClicked] = useState<boolean>(false);\n const [refreshAvailableHours, setRefreshAvailableHours] = useState<number>(0);\n const [openExclamationScheduleBusyModal, setOpenExclamationScheduleBusyModal] = useState<boolean>(false);\n const [openOutsideScheduleModal, setOpenOutsideScheduleModal] = useState<boolean>(false);\n const [openQuestionScheduleBusyModal, setOpenQuestionScheduleBusyModal] = useState<boolean>(false);\n const [openOutsideBusinessHoursModal, setOpenOutsideBusinessHoursModal] = useState<boolean>(false);\n const [openAppointmentWorkAreaBusyModal, setOpenAppointmentWorkAreaBusyModal] = useState<boolean>(false);\n const [openTimeIsBusyAnotherAppointmentCanNotContinueModal, setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal] = useState<boolean>(false);\n const [appointmentBusyModalData, setAppointmentBusyModalData] = useState<AppointmentBusyModalDataModel>();\n const [recurringCount, setRecurringCount] = useState<number>();\n const [isRecurring, setIsRecurring] = useState<boolean>();\n const { customerId } = useParams<any>();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n const getTemplatedCurrencyValue = useCurrencyValueTemplate(accountSettings.currencyTemplate);\n const userInfo = useAppSelector(state => state.userInfo);\n\n useEffect(() => {\n window.scrollTo({\n top: 0,\n behavior: 'smooth',\n });\n\n dispatch(applicationInterfaceActions.updateTitle(t(\"New appointment\")));\n }, []);\n\n useEffect(() => {\n if (isClicked) {\n dispatch(navbarActions.setShowLoader(true));\n AppointmentService.create(appointment).then((data) => {\n dispatch(navbarActions.setShowLoader(false));\n if (data.isScheduleBusy) {\n setAppointmentBusyData(data.appointmentBlocker, data.appointmentScheduleBusyReason);\n setRefreshAvailableHours(refreshAvailableHours + 1);\n setStep2Valid(false);\n setIsClicked(false);\n return;\n } else {\n dispatch(applicationInterfaceActions.updateTitle(t(\"Appointments\")));\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Appointment created\"),\n description: `${appointment.firstName} ${\n appointment.lastName\n } - ${formatDate(appointment.startDate)}`,\n })\n );\n history.push(`${Url.Appointments.Main}`);\n }\n });\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isClicked]);\n\n function setAppointmentBusyData(appointmentBlocker: AppointmentBlocker, appointmentScheduleBusyReason: AppointmentScheduleBusyReason) {\n setAppointmentBusyModalData(\n new AppointmentBusyModalDataModel({\n customerName: appointmentBlocker?.customerName,\n serviceName: appointmentBlocker?.serviceName,\n workArea: appointmentBlocker?.workArea,\n startData: appointmentBlocker?.startData,\n appointmentDuration: appointmentBlocker?.appointmentDuration,\n appointmentScheduleBusyReason: appointmentScheduleBusyReason,\n }));\n openScheduleBusyModal(appointmentScheduleBusyReason);\n }\n\n function openScheduleBusyModal(data: AppointmentScheduleBusyReason) {\n switch (data) {\n case AppointmentScheduleBusyReason.TimeIsBusyAnotherAppointment:\n setOpenQuestionScheduleBusyModal(true);\n break;\n case AppointmentScheduleBusyReason.BlockedScheduleTime:\n setOpenExclamationScheduleBusyModal(true);\n break;\n case AppointmentScheduleBusyReason.OutsideUserScheduleTime:\n setOpenOutsideScheduleModal(true);\n break;\n case AppointmentScheduleBusyReason.OutsideUserScheduleTimeAndOutsideBusinessHours:\n setOpenOutsideScheduleModal(true);\n break;\n case AppointmentScheduleBusyReason.WorkAreaIsBusyAnotherAppointment:\n setOpenAppointmentWorkAreaBusyModal(true);\n break;\n case AppointmentScheduleBusyReason.OutsideBusinessHours:\n setOpenOutsideBusinessHoursModal(true);\n break;\n case AppointmentScheduleBusyReason.TimeIsBusyAnotherAppointmentCanNotContinue:\n setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal(true);\n break;\n default:\n setOpenExclamationScheduleBusyModal(true);\n break;\n }\n }\n \n const totalServicesPrice = appointment.services.reduce((total, service) => total + service.price, 0); \n\n const formatDate = (date: Date | null): string => {\n const day = date?.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n const month = date?.toLocaleString(localeApp, {\n month: \"long\",\n });\n const year = date?.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n\n return `${day}/${month}/${year}`;\n };\n\n const handleCreateButton = (event: any) => {\n event.preventDefault();\n setIsClicked(true);\n };\n\n const handleContinueScheduleBusyModal = () => {\n const newAppointment = {\n ...appointment,\n isIgnoreScheduleBusy: true\n };\n setAppointment(newAppointment);\n setIsClicked(true);\n };\n \n function onRecurringChange(recurringCount: number, isRecurring: boolean) {\n setIsRecurring(isRecurring);\n setRecurringCount(recurringCount);\n }\n\n return (<>\n <div style={{ paddingBottom: 75 }}>\n <div className={classes.breadcrumbContainer}>\n <Breadcrumbs aria-label=\"breadcrumb\" className={classes.breadcrumb}>\n <Link\n underline=\"hover\"\n color=\"inherit\"\n href=\"/appointments\"\n >\n {t(\"Appointments\")}\n </Link>\n <div className={classes.boldFont}>\n <Typography> {t(\"New appointment\")}</Typography>\n </div>\n </Breadcrumbs>\n </div>\n <div className={classes.root}>\n <AppointmentCustomerSection\n appointment={appointment}\n customerId={customerId}\n onChange={(eventAppointment) => {\n setAppointment(eventAppointment);\n }}\n />\n <div className={classes.appointmentSection}>\n <AppointmentStepOne\n appointment={appointment}\n onChange={(appointment: any, isValid: any) => {\n setAppointment(appointment);\n setStep1Valid(isValid);\n }}\n />\n <AppointmentStepTwo\n appointment={appointment}\n step1Valid={step1Valid}\n isEdition={false}\n refreshData={refreshAvailableHours}\n onChange={(appointment: any, isValid: any) => {\n if (isValid) {\n setAppointment(appointment);\n }\n\n setStep2Valid(isValid);\n }}\n onRecurringChange={onRecurringChange}\n />\n </div>\n </div>\n\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.modalCancelPaper}>\n <div>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Cancel new appointment registration?\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBackCancel}`}\n onClick={() => setCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n setCancelModal(false);\n history.push(`${Url.Appointments.Main}`);\n }}\n >\n {t(\"Yes, cancel it\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n\n <BusyScheduleQuestionModal\n open={openQuestionScheduleBusyModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenQuestionScheduleBusyModal(false)}\n onContinue={handleContinueScheduleBusyModal}\n />\n <OutsideBusinessHoursModal\n open={openOutsideBusinessHoursModal}\n onClose={() => setOpenOutsideBusinessHoursModal(false)}\n onCancel={() => setOpenOutsideBusinessHoursModal(false)}\n onConfirm={handleContinueScheduleBusyModal}\n />\n <AppointmentWorkAreaBusyModal\n open={openAppointmentWorkAreaBusyModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenAppointmentWorkAreaBusyModal(false)}\n />\n <AppointmentScheduleBusyModal\n open={openExclamationScheduleBusyModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenExclamationScheduleBusyModal(false)}\n />\n <AppointmentOutsideScheduleModal\n open={openOutsideScheduleModal}\n appointment={appointment}\n appointmentBusyModalData={appointmentBusyModalData}\n onClose={() => setOpenOutsideScheduleModal(false)}\n onContinue={handleContinueScheduleBusyModal}\n />\n <TimeIsBusyAnotherAppointmentCanNotContinueModal\n open={openTimeIsBusyAnotherAppointmentCanNotContinueModal}\n onClose={() => setOpenTimeIsBusyAnotherAppointmentCanNotContinueModal(false)}\n />\n <div className={classes.actions}>\n <div >\n {(isRecurring && userInfo.showPrices) && <div>\n <div className={classes.totalPriceBoldText}>\n {t(\"Total for the {{count}} appointments: {{total}}\", {\n count: recurringCount ?? 0,\n total: getTemplatedCurrencyValue((totalServicesPrice * recurringCount!) ?? 0),\n })}\n </div>\n <div className={classes.totalPriceText}>\n {t(\"Total per appointment: {{price}}\", {\n price: getTemplatedCurrencyValue(recurringCount && recurringCount > 0 ? totalServicesPrice : 0),\n })}\n </div>\n </div>}\n </div>\n <div>\n <ButtonWithSpinner\n width={200}\n margin={\"0px 16px 0px 0px\"}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n innerText={t(\"Go back\")}\n onClick={() => {\n if (\n appointment.services &&\n appointment.services.length &&\n appointment.customerId\n ) {\n setCancelModal(true);\n } else {\n history.push(`${Url.Appointments.Main}`);\n }\n }}\n />\n <ButtonWithSpinner\n width={200}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Create appointment\")}\n onClick={handleCreateButton}\n disabled={(!appointment.customerId || !step1Valid || !step2Valid) && !isClicked}\n isProcessing={useAppSelector((state) => state.navbar.showLoader) ?? undefined}\n />\n </div>\n </div>\n \n </div>\n </>);\n};\n\nexport default AppointmentNew;\n","import * as React from \"react\";\nimport { Route, Switch, Redirect } from \"react-router-dom\";\n\nimport { Url } from \"../../../constants/url\";\nimport AppointmentList from \"../AppointmentList\";\nimport AppointmentDetails from \"../AppointmentDetails\";\nimport AppointmentNew from \"./../AppointmentNew\";\n\nexport default function AppointmentRouter() {\n return (\n <Switch>\n <Route exact path={Url.Appointments.Main} component={AppointmentList} />\n <Route\n exact\n path={Url.Appointments.Main + \"/new\"}\n component={AppointmentNew}\n />\n <Route\n exact\n path={Url.Appointments.Main + \"/new/:customerId\"}\n component={AppointmentNew}\n />\n <Route\n exact\n path={Url.Appointments.Main + \"/:appointmentId\"}\n component={AppointmentDetails}\n />\n <Route path={Url.Appointments.Main}>\n <Redirect to={Url.Appointments.Main} />\n </Route>\n </Switch>\n );\n}\n","import { makeStyles } from \"@material-ui/core\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n alignItems: \"center\",\n margin: \"7px 0px 0px 0px\",\n },\n classification: {\n width: 104,\n margin: \"0px 25px 0px 0px\",\n },\n titles: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n icons: {\n ...theme.typography.header4,\n color: theme.colors.grey5,\n display: \"flex\",\n alignItems: \"center\",\n margin: \"7px 0px 0px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { CustomerClassificationItemProps } from \"./props\";\nimport useStyles from \"./css\";\n\nconst CustomerClassificationItem = (props: CustomerClassificationItemProps) => {\n const { title, value, icon, ...otherProps } = props;\n const classes = useStyles();\n const MainIcon = icon;\n return (\n <div {...otherProps} className={classes.root}>\n <div className={classes.classification}>\n <Typography className={classes.titles}>{title}</Typography>\n <Typography className={classes.icons}>\n <MainIcon />\n {value}\n </Typography>\n </div>\n </div>\n );\n};\n\nexport default CustomerClassificationItem;\n","import { makeStyles } from \"@material-ui/core\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n verticalAlign: \"middle\",\n display: \"inline-flex\",\n margin: \"0px 0px 24px 0px\",\n },\n icon: {\n marginRight: 6,\n },\n line: {\n width: 1,\n height: 41,\n borderLeft: \"1px solid #C9CDD3\",\n margin: \"7px 24px 0px 0px\",\n },\n}));\n","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { GroupIcon, StatusIcon } from \"../../../assets/icons\";\nimport CustomerClassificationItem from \"./../CustomerClassificationItem\";\nimport { useStyles } from \"./css\";\nimport { CustomerClassificationProps } from \"./props\";\n\n\nexport default function CustomerClassification(props: CustomerClassificationProps) {\n \n const { classification } = props;\n \n const { t } = useTranslation([\"general\"]);\n\n const classes = useStyles();\n \n return (\n <div className={classes.root}>\n <CustomerClassificationItem\n title={t(\"Registered\")}\n value={classification.total}\n icon={GroupIcon}\n />\n <div className={classes.line} />\n <CustomerClassificationItem\n title={t(\"Frequent\")}\n value={classification.frequent}\n icon={() => <StatusIcon status={2} />}\n />\n <CustomerClassificationItem\n title={t(\"Infrequent\")}\n value={classification.infrequent}\n icon={() => <StatusIcon status={3} />}\n />\n <CustomerClassificationItem\n title={t(\"Inactive\")}\n value={classification.inactive}\n icon={() => <StatusIcon status={1} />}\n />\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 344,\n },\n cancelModalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"50px 40px 55px\",\n width: 523,\n height: 216,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n paddingBottom: \"12px\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n\n dropZone: {\n height: \"136px\",\n width: \"373px\",\n background: \"rgba(100, 98, 243, 0.1)\",\n border: \"0px dashed\",\n borderRadius: \"15px\",\n borderColor: theme.colors.clearMain,\n minHeight: \"100px\",\n backgroundImage: `url(\"data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='15' ry='15' stroke='%236462F3FF' stroke-width='2' stroke-dasharray='12%2c 12' stroke-dashoffset='0' stroke-linecap='round'/%3e%3c/svg%3e\")`,\n animation: 'none !important',\n },\n\n dropZoneText: {\n color: theme.colors.clearMain,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n position: \"relative\",\n top: \"70px\",\n },\n fileName: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n },\n fileSize: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n paddingTop: \"4px\",\n },\n fileSizeBold: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n },\n downloadTemplate: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n notesTitle: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n notes: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n divider: {\n borderTop: \"1px solid\",\n borderColor: theme.colors.grey2,\n marginTop: \"24px\",\n marginBottom: \"24px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginBottom: 8,\n },\n cancelModalButton: {\n width: 244,\n height: 39,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 14,\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n modalTitleTextCancel: {\n marginBottom: 57,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 18,\n fontWeight: \"bold\"\n },\n goBackCancel: {\n marginRight: 38,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n link: {\n color: theme.colors.clearMain,\n cursor: \"pointer\"\n }\n}));\n\nexport default useStyles;\n","import { ApiClient } from \"./api-client\";\n\nexport default class FileService {\n private static baseUrl: string = \"/static\";\n\n static getTemplateFileUrl(fileName: string, locale: string): Promise<string> {\n return ApiClient.get(`${this.baseUrl}/gettemplatefileurl?FileName=${fileName}&Locale=${locale}`).then(\n (data) => data.fileUrl);\n }\n}","import React, { useState, useEffect, useRef } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { DropzoneAreaBase, FileObject } from \"material-ui-dropzone\";\nimport useStyles from \"./css\";\nimport { CustomerImportModalProps } from \"./props\";\nimport { Box, Grid } from \"@material-ui/core\";\n\nimport {\n ExcelIcon,\n UploadFileCloud,\n DownloadFileCloud,\n} from \"../../../assets/icons\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport FileService from \"../../../api/file-service\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\n\nexport default function CustomerImportModal(props: CustomerImportModalProps) {\n\n const { t } = useTranslation([\"general\"]);\n const { open, onClose, refreshCustomers } = props;\n const classes = useStyles();\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [openCancelModal, setOpenCancelModal] = useState<boolean>(false);\n const [cancelModalShouldAppear, setCancelModalShouldAppear] = useState<boolean>(false);\n\n const templateFileName = useRef<string>(\"\");\n const [file, setFile] = useState<FileObject[]>([]);\n const [fileSize, setFileSize] = useState<number>(0);\n const [fileName, setFileName] = useState<string>(t(\"No file.\"));\n const [isValid, setIsValid] = useState<boolean>(false);\n const maxFileSize: number = 1 * 1024 * 1024;\n\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n const customerListUpdatedTitle = useCustomerTerminology(t(\"Customer list updated\"), \"Customer list updated\")\n const customersNotImportedDescription = useCustomerTerminology(t(\"Customers were not imported\"), \"Customers were not imported\")\n\n const { enqueueAlert } = alertsActions;\n const dispatch = useAppDispatch();\n\n useEffect(() => {\n if (localeApp && accountSettings) {\n const templateFileNameCustomersES: string = \"Lista_de_clientes_2024.xlsx\";\n const templateFileNameCustomersEN: string = \"List_of_customers_2024.xlsx\";\n const templateFileNamePatientsES: string = \"Lista_de_pacientes_2024.xlsx\";\n const templateFileNamePatientsEN: string = \"List_of_patients_2024.xlsx\";\n\n if (localeApp === 'en'){\n if (accountSettings.isClinicMode) {\n templateFileName.current = templateFileNamePatientsEN;\n } else {\n templateFileName.current = templateFileNameCustomersEN;\n }\n } else {\n if (accountSettings.isClinicMode) {\n templateFileName.current = templateFileNamePatientsES;\n } else {\n templateFileName.current = templateFileNameCustomersES;\n }\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [localeApp, accountSettings]);\n\n useEffect(() => {\n setOpenModal(open);\n if (open === true) {\n cleanupModal();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n\n const handleTryCloseModal = () => {\n if (cancelModalShouldAppear) {\n setOpenCancelModal(true);\n } else {\n handleCloseModal();\n }\n };\n\n const handleCloseModal = () => {\n setOpenModal(false);\n if (onClose) {\n onClose();\n }\n };\n\n async function handleOnUploadClick() {\n\n if (isValid) {\n setIsValid(false);\n const uploadResponse = await CustomerService.createCustomersFromFile(\n file[0].file\n );\n\n if (!uploadResponse.isFileProcessed) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"File could not be uploaded\"),\n description: customersNotImportedDescription\n })\n );\n \n handleCloseModal();\n return;\n }\n \n const processed: string = uploadResponse.processedRecordsCount!+\"\";\n const total: string = uploadResponse.totalRecordsCount!+\"\";\n\n if (uploadResponse.processedRecordsCount == uploadResponse.totalRecordsCount) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: customerListUpdatedTitle,\n description: t(\"{n} of {m} records were uploaded\").replace(\"{n}\", processed).replace(\"{m}\", total)\n })\n );\n\n handleCloseModal();\n refreshCustomers();\n return;\n }\n\n if (uploadResponse.processedRecordsCount! < uploadResponse.totalRecordsCount!) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: customerListUpdatedTitle,\n description:\n <>\n {t(\"{n} of {m} records were uploaded\").replace(\"{n}\", processed).replace(\"{m}\", total)}\n <div\n className={classes.link}\n onClick={async () => await handleOnDownloadClick(uploadResponse.invalidRecordsFile)}\n >\n {t(\"View records that were not loaded\")}\n </div>\n </>\n })\n );\n \n handleCloseModal();\n refreshCustomers();\n return;\n }\n }\n\n cleanupModal();\n }\n\n async function handleOnDownloadClick(responseFile: Uint8Array | null) {\n\n if (responseFile) {\n const fileUrl = URL.createObjectURL(new Blob([responseFile], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' }));\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", fileUrl);\n link.setAttribute(\"download\", templateFileName.current);\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n }\n\n const handleOnAddFile = (files: FileObject[]) => {\n setFile(files);\n setFileName(files[0].file.name);\n let size = files[0].file.size / (1024 * 1024);\n setFileSize(Math.round((size + Number.EPSILON) * 100) / 100); // in megabytes\n setIsValid(validateFile(files[0].file));\n setCancelModalShouldAppear(true);\n };\n\n const handleDropRejected = (file: File[]) => {\n if (file[0].name.split(\".\").pop() !== \"xlsx\") {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Use the indicated .xlsx format\")\n })\n );\n }\n };\n\n const validateFile = (file: File) => {\n if (file.size > maxFileSize)\n //1 megabyte\n return false;\n return file.name.split(\".\").pop() === \"xlsx\";\n };\n\n function cleanupModal() {\n setFile([]);\n setFileName(t(\"No file.\"));\n setFileSize(0);\n setIsValid(false);\n setCancelModalShouldAppear(false);\n setOpenCancelModal(false);\n }\n\n async function downloadTemplateFile() {\n const fileUrl = await FileService.getTemplateFileUrl(templateFileName.current, localeApp!);\n\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", fileUrl);\n link.setAttribute(\"download\", templateFileName.current);\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n\n return (\n <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={handleTryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div>\n <div\n className={classes.paper}\n style={openCancelModal ? { display: \"none\" } : {}}\n >\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {useCustomerTerminology(t(\"Import customers\"), \"customers\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={handleTryCloseModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Upload file\")}\n onClick={handleOnUploadClick}\n disabled={!isValid}\n />\n </div>\n </div>\n <Box sx={{ width: \"100%\" }} pt={1}>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <DropzoneAreaBase\n dropzoneClass={classes.dropZone}\n dropzoneParagraphClass={classes.dropZoneText}\n fileObjects={file}\n dropzoneText={t(\n \"Drag or click here to upload your .xlsx file\"\n )}\n onAdd={handleOnAddFile}\n showPreviewsInDropzone={false}\n showAlerts={false}\n filesLimit={1}\n acceptedFiles={[\n \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\",\n ]}\n maxFileSize={maxFileSize}\n onDropRejected={handleDropRejected}\n // @ts-ignore: type negotiation problem\n Icon={UploadFileCloud} // works and builds but https://github.com/Yuvaleros/material-ui-dropzone/issues/246\n />\n </Grid>\n <Grid item xs={1} style={{ paddingLeft: \"38px\" }}>\n <ExcelIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>\n <Grid\n item\n xs={5}\n style={{ paddingLeft: \"48px\", paddingTop: \"30px\" }}\n >\n <Typography className={classes.fileName}>\n {fileName}\n </Typography>\n <Typography className={classes.fileSize}>\n {t(\"Size: \")}\n <b>{fileSize} MB</b>\n </Typography>\n </Grid>\n </Grid>\n <hr className={classes.divider} />\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <Typography className={classes.notesTitle}>\n {t(\"NOTES: \")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Accepted format: xlsx\")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Maximum allowed document size: 1 Mb\")}\n </Typography>\n </Grid>\n <Grid\n item\n xs={6}\n container\n direction=\"row\"\n alignItems=\"center\"\n justifyContent=\"flex-end\"\n >\n <Typography\n className={classes.downloadTemplate}\n onClick={downloadTemplateFile}\n >\n <DownloadFileCloud\n style={{ fontSize: 18, margin: \"0px 4px 2px 0px\" }}\n />\n {t(\"Download template\")}\n </Typography>\n </Grid>\n </Grid>\n </Box>\n </div>\n <div\n className={classes.cancelModalPaper}\n style={openCancelModal ? {} : { display: \"none\" }}\n >\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleTextCancel}>\n {t(\"Cancel the upload of the .xlsx file?\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.cancelModalButton} ${classes.goBackCancel}`}\n onClick={() => setOpenCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.cancelModalButton} ${classes.cancelConfirmation}`}\n onClick={handleCloseModal}\n >\n {t(\"Yes, cancel it\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </>\n );\n}","import React from \"react\";\n\nimport { SortIcon, SortUpIcon, SortDownIcon } from \"./../../../../assets/icons\";\n\nimport { ArrowDropProps } from \"./props\";\n\nconst ArrowDrop = (props: ArrowDropProps) => {\n const { classes, propertyName, hover, active, direction, ...otherProps } =\n props;\n return (\n <div {...otherProps} className={classes.dropdown}>\n {direction === \"asc\" && active ? (\n <SortUpIcon />\n ) : direction === \"desc\" && active ? (\n <SortDownIcon />\n ) : (\n <SortIcon />\n )}\n </div>\n );\n};\n\nexport default ArrowDrop;\n","import { makeStyles } from \"@material-ui/core\";\n\nconst useStyles = makeStyles((theme) => ({\n tableHeader: {\n backgroundColor: \"#F6F6F6\",\n left: \"unset\"\n },\n headerText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n visuallyHidden: {\n border: 0,\n clip: \"rect(0 0 0 0)\",\n height: 1,\n margin: -1,\n overflow: \"hidden\",\n padding: 0,\n position: \"absolute\",\n top: 20,\n width: 1,\n },\n arrowDropdown: {\n display: \"inline-grid\",\n },\n arrowShow: {\n visibility: \"visible\",\n },\n arrowHide: {\n visibility: \"hidden\",\n },\n totalResultText: {\n ...theme.typography.caption2,\n color: theme.colors.clearMain,\n },\n modalActionsAppt: {\n position: \"relative\",\n top: 58,\n left: 15,\n background: \"white\",\n width: 202,\n textAlign: \"center\",\n border: \"1px solid #DBDCDD\",\n boxShadow: \"0px 4px 4px rgb(166 166 166 / 25%)\",\n borderRadius: 5,\n backgroundColor: \"#FFFFFF\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n color: theme.colors.grey5, \n },\n modalActionFont: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: theme.colors.grey5, \n padding: 5,\n cursor: \"pointer\",\n position: \"relative\",\n background: \"white\",\n width: 200,\n textAlign: \"left\",\n paddingLeft: 15,\n height: 35\n },\n modalActionFirst: {\n paddingTop: 10,\n borderTopLeftRadius: 5,\n borderTopRightRadius: 5,\n borderBottom: \"1px solid #DBDCDD\",\n \"&:hover\": {\n backgroundColor: \"#E1E9FE\"\n }\n },\n modalActionLast: {\n borderBottomLeftRadius: 5,\n borderBottomRightRadius: 5,\n \"&:hover\": {\n backgroundColor: \"#E1E9FE\"\n }\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\n\nimport TableRow from \"@material-ui/core/TableRow\";\nimport TableCell from \"@material-ui/core/TableCell\";\nimport TableHead from \"@material-ui/core/TableHead\";\nimport Typography from \"@material-ui/core/Typography\";\nimport TableSortLabel from \"@material-ui/core/TableSortLabel\";\nimport Modal from \"@material-ui/core/Modal\";\n\nimport ArrowDrop from \"./../ArrowDrop\";\nimport { TableColumn } from \"./../table-column\";\n\nimport { EnhancedTableHeadProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { FiltersIcon } from \"../../../../assets/icons\";\nimport { useTranslation } from \"react-i18next\";\n\nconst EnhancedTableHead = (props: EnhancedTableHeadProps) => {\n const { order, orderBy, columns, onRequestSort } = props;\n const classes = useStyles();\n const [hover, setHover] = useState<string>(\"\");\n \n const [modalFilter, setModalFilter] = useState<number>();\n\n const sortHandler = (property: string) => (event: any) => {\n onRequestSort(event, property);\n };\n\n const FilterControl = (index: number, column: TableColumn) => {\n const filtering = column.filtering\n const filterList = column.filterList;\n const setFilter = column.setFilter;\n\n return <>\n {\n filtering && filterList && setFilter ? \n <>\n <span style={{marginRight: 5, cursor: \"pointer\"}} onClick={() => setModalFilter(index)}>\n <FiltersIcon />\n </span>\n <Modal\n open={index === modalFilter }\n onClose={() => setModalFilter(-1)}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n disablePortal={true}\n style={{ position: \"absolute\", top: 0, float: \"right\" }} >\n <div className={classes.modalActionsAppt} >\n {filterList.map(item => \n <div \n className={`${classes.modalActionFont} ${classes.modalActionFirst}`} \n onClick={() => {\n setModalFilter(-1); \n if (setFilter) setFilter(item)\n }}>\n {item.value} \n </div>\n )}\n </div>\n </Modal>\n </> \n : \n <></>\n }\n </>\n};\n\n return (<>\n <TableHead>\n <TableRow>\n {columns.map((column: TableColumn, indexColumn) => (\n (column.visible! ?? true) && <>\n <TableCell\n className={classes.tableHeader}\n style={{\n width: column.width,\n minWidth: column.minWidth,\n maxWidth: column.maxWidth,\n textAlign: column.headerTextAlign\n ? column.headerTextAlign\n : \"left\",\n ...column.cellHeaderStyle\n }}\n key={column.id}\n sortDirection={orderBy === column.id ? order : false}\n >\n {column.sorting ? (<>\n <span className={`${classes.headerText}`}>\n {FilterControl(indexColumn, column)} \n </span>\n <TableSortLabel\n onMouseOver={() => {setHover(column.id)}}\n onMouseOut={() => {setHover(\"\")}}\n active={orderBy === column.id}\n direction={orderBy === column.id ? order : \"asc\"}\n onClick={sortHandler(column.id)}\n IconComponent={() => (\n <ArrowDrop\n classes={{\n dropdown: classes.arrowDropdown,\n show: classes.arrowShow,\n hide: classes.arrowHide,\n }}\n active={orderBy === column.id}\n hover={hover}\n propertyName={column.id}\n direction={orderBy === column.id ? order : \"asc\"}\n />\n )}\n >\n <Typography\n className={`${classes.headerText} ${column.headerClassName || \"\"}`}\n style={column.headerStyle}\n >\n <>\n {column.label}\n </>\n </Typography>\n {orderBy === column.id ? (\n <span className={classes.visuallyHidden}>\n {order === \"asc\" ? \"sorted descending\" : \"sorted ascending\"}\n </span>\n ) : null}\n </TableSortLabel>\n </>) : (\n <Typography\n className={`${classes.headerText} ${column.headerClassName || \"\"}`}\n style={column.headerStyle}\n >\n <>\n {FilterControl(indexColumn, column)}\n {column.label}\n </>\n </Typography>\n )}\n </TableCell>\n </>\n ))}\n </TableRow>\n </TableHead>\n </>);\n};\n\nexport default EnhancedTableHead;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles({\n pagination: {\n marginTop: \"12px\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\", \n \"& .MuiPaginationItem-page\": {\n color: \"#919CA5\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n },\n \"& .Mui-selected\": {\n backgroundColor: \"#6462F3\",\n color: \"#F6F6F6\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n \"& .Mui-selected:hover\": {\n backgroundColor: \"#6462F3\",\n opacity: 0.5,\n color: \"#F6F6F6\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12\n },\n \"& svg\": {\n color: \"#6462F3\"\n }\n },\n});\n\nexport default useStyles;\n","import React from \"react\";\nimport MuiPagination from \"@material-ui/lab/Pagination\";\n\nimport useStyles from \"./css\";\nimport { PaginationProps } from \"./props\";\n\nconst Pagination = (props: PaginationProps) => {\n const classes = useStyles();\n const { count, page, onPageChange, showPaginationAlways } = props;\n\n const handlePageChange = (\n event: React.ChangeEvent<unknown>,\n page: number\n ) => {\n onPageChange(event, page);\n };\n\n if (count <= (showPaginationAlways ? 0 : 1)) {\n return null;\n }\n\n return (\n <MuiPagination\n className={classes.pagination}\n count={count}\n page={page}\n onChange={handlePageChange}\n boundaryCount={2}\n siblingCount={0}\n />\n );\n};\n\nexport default Pagination;\n","import { makeStyles } from \"@material-ui/core\";\n\nconst useStyles = (height: number | string | undefined, width: number | undefined) =>\n makeStyles((theme) => ({\n container: {\n height: height || 605,\n width: width,\n },\n tableContainer: {\n border: \"1px solid #DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: height || 605,\n width: width,\n overflow: \"hidden\",\n },\n tableHeader: {\n backgroundColor: \"#F6F6F6\",\n },\n popper:{\n [`& .MuiTooltip-tooltip`]: {\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: theme.colors.grey1,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey5,\n boxShadow: \"0px 0px 4px #00000034\"\n }\n },\n tableBody: {\n overflowY: \"scroll\",\n height: height || 605,\n width: width,\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n rowText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n }));\n\nexport default useStyles;\n","import React, { useEffect, useState, useRef } from \"react\";\n\nimport Box from \"@material-ui/core/Box\";\nimport Paper from \"@material-ui/core/Paper\";\nimport Table from \"@material-ui/core/Table\";\nimport TableRow from \"@material-ui/core/TableRow\";\nimport TableBody from \"@material-ui/core/TableBody\";\nimport TableCell from \"@material-ui/core/TableCell\";\nimport Typography from \"@material-ui/core/Typography\";\nimport TableContainer from \"@material-ui/core/TableContainer\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nimport EnhancedTableHead from \"./../EnhancedTableHead\";\nimport { TableColumn } from \"../table-column\";\n\nimport Pagination from \"./../../Pagination\";\n\nimport useStyles from \"./css\";\nimport { GridListProps } from \"./props\";\n\nexport default function GridList(props: GridListProps) {\n const {\n columns,\n items,\n totalItems,\n pageSize,\n height,\n width,\n onChange,\n onRowClick,\n classRow,\n classTableBody,\n classTableContainer,\n showPaginationAlways,\n tooltipIsVisible\n } = props;\n\n const customClasses = useStyles(height, width)();\n const [page, setPage] = useState<number>(1);\n const [order, setOrder] = useState<\"asc\" | \"desc\">(\"asc\");\n const [orderBy, setOrderBy] = useState<string>(\"\");\n const [showTooltip, setShowTooltip] = useState<boolean>(false);\n const tableContainerRef = useRef<HTMLDivElement>(null);\n const prevColumnsLength = useRef(columns.length);\n const elementsRefs = useRef<(HTMLSpanElement | null)[]>([]);\n\n useEffect(() => {\n if (onChange) {\n onChange({\n page: page,\n sorting:\n order && orderBy\n ? {\n direction: order,\n orderBy: orderBy,\n }\n : undefined,\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [page, order, orderBy]);\n \n useEffect(() => {\n if (columns.length > prevColumnsLength.current ) {\n tableContainerRef.current!.scrollLeft += 9999;\n }\n prevColumnsLength.current = columns.length;\n }, [columns.length]);\n \n function onMouseEnterItem(rowIndex: number, colIndex: number) {\n let offsetWidth = elementsRefs.current[getUniqueIndexForCell(rowIndex, colIndex)]?.offsetWidth ?? 0;\n let scrollWidth = elementsRefs.current[getUniqueIndexForCell(rowIndex, colIndex)]?.scrollWidth ?? 0;\n \n if (offsetWidth < scrollWidth) {\n setShowTooltip(true);\n }\n }\n function onMouseLeaveItem() {\n setShowTooltip(false);\n }\n \n function getUniqueIndexForCell(rowIndex: number, colIndex: number) {\n return rowIndex * 100000 + colIndex;\n }\n \n const handleRequestSort = (event: any, property: string) => {\n const isAsc = orderBy === property && order === \"asc\";\n setPage(1);\n setOrder(isAsc ? \"desc\" : \"asc\");\n setOrderBy(property);\n };\n\n const handlePage = (event: React.ChangeEvent<unknown>, page: number) => {\n setPage(page);\n };\n\n const handleRowClick = <T extends unknown>(item: T) => {\n if (onRowClick) {\n onRowClick(item);\n }\n };\n\n return (\n <Box style={{ height: height }}>\n <div className={customClasses.container}>\n <TableContainer\n component={Paper}\n className={classTableContainer ?? customClasses.tableContainer}\n >\n <div ref={tableContainerRef} className={classTableBody ?? customClasses.tableBody}>\n <Table stickyHeader aria-label=\"sticky table\">\n <EnhancedTableHead\n columns={columns}\n order={order}\n orderBy={orderBy}\n onRequestSort={handleRequestSort}\n />\n \n <TableBody>\n {items.map((item: any, rowIndex: number) => (\n <TableRow\n key={rowIndex}\n id={`$GridList-${rowIndex}`}\n className={classRow}\n onClick={() => handleRowClick(item)}\n hover\n >\n {columns.map((column: TableColumn, colIndex: number) => (\n (column.visible! ?? true) && <>\n <TableCell\n key={colIndex}\n className={`${customClasses.rowText} ${\n column.rowClassName || \"\"\n }`.trim()}\n style={{\n width: column.width,\n minWidth: column.minWidth,\n maxWidth: column.maxWidth,\n textAlign: column.textAlign\n ? column.textAlign\n : \"left\",\n ...column.cellStyle,\n }}\n >\n {!column.component ? (\n <Tooltip\n title={tooltipIsVisible && showTooltip ? item[column.id] : \"\"}\n placement=\"bottom\"\n classes={{ popper: customClasses.popper }}>\n <Typography\n onMouseEnter={() => onMouseEnterItem(rowIndex, colIndex)} \n onMouseLeave={onMouseLeaveItem}\n className={`${customClasses.rowText} ${column.rowClassName || \"\"}`.trim()}\n style={column.rowStyle}\n ref={(ref) => elementsRefs.current[getUniqueIndexForCell(rowIndex, colIndex)] = ref}\n >\n {item[column.id]}\n </Typography>\n </Tooltip>\n ) : (\n column.component(\n column.completeObject ? item : item[column.id]\n )\n )}\n </TableCell>\n </>\n ))}\n </TableRow>\n ))}\n </TableBody>\n </Table>\n </div>\n </TableContainer>\n <Pagination\n count={Math.ceil(totalItems / (pageSize || 20))}\n page={page || 1}\n onPageChange={handlePage}\n showPaginationAlways={showPaginationAlways}\n />\n </div>\n </Box>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n divMain: {\n position: \"relative\"\n },\n notFound: {\n // width: 200,\n position: \"absolute\",\n top: \"50%\",\n left: \"50%\",\n transform: \"translate(-50%, -50%)\",\n color: theme.colors.grey4,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 18,\n textAlign: \"center\"\n\n },\n linkRegister: {\n color: theme.colors.clearMain,\n display: \"inline\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 18,\n cursor: \"pointer\",\n marginLeft: 5\n },\n searchResultLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n deleteConfirmationModal: {\n height: \"auto !important\"\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n deleteModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n textAlign: \"center\"\n },\n deleteModalContentBoldText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: 288,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"80%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: theme.colors.grey7\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: theme.colors.grey4, //Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\"\n },\n deleteBtn: {\n fontWeight: \"bold\",\n fontSize: 12,\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { TrashIcon, CrossIcon } from \"./../../../assets/icons\";\n\nimport useStyles from \"./css\";\nimport { ConfirmDeleteModalProps } from \"./props\";\n\nconst ConfirmDeleteModal = (props: ConfirmDeleteModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, item, componentInfo, onClose, onDelete, classModal, classButton, textButtonConfirm } = props;\n const classes = useStyles();\n\n const handleDelete = () => {\n if (onDelete) onDelete(item);\n };\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={`${classes.modal}`}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={open}>\n <div className={`${classes.modalPaper} ${classModal}`}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n\n {\n componentInfo\n }\n\n <div className={classes.modalActions}>\n <Button className={`${classButton ?? classes.button} ${classes.goBack}`} onClick={onClose} >\n {t(\"Go back\")}\n </Button>\n\n <Button className={`${classButton ?? classes.button} ${classes.deleteBtn}`} onClick={handleDelete} >\n {textButtonConfirm ?? t(\"Delete\")}\n </Button>\n </div>\n\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default ConfirmDeleteModal;\n","import React, { useEffect, useState } from \"react\";\nimport { useHistory } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport { conformToMask } from \"react-text-mask\";\n\nimport { Customer } from \"../../../models/customer\";\nimport { Gender } from \"../../../models/enums/gender\";\nimport StatusIcon from \"../../../assets/icons/StatusIcon\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport GridList, { OnChangeEvent } from \"./../../common/grid/GridList\";\nimport { TableColumn } from \"../../common/grid/table-column\";\nimport { Url } from \"./../../../constants/url\";\nimport { GetMobileMaskByTemp } from \"./../../../constants/mask\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport Autocomplete from \"../../common/Autocomplete\";\nimport { CustomerSearch } from \"../../../models/customer-search\";\n\nimport { CustomerListProps } from \"./props\";\nimport CountryFlagIcon from \"./../../../assets/flags\";\nimport { SearchIcon, TrashIcon } from \"../../../assets/icons\";\nimport useStyles from \"./css\";\nimport { ApiClient } from \"../../../api/api-client\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport { createFilterOptions } from \"@material-ui/lab\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport { Color } from \"../../../constants/colors\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport ConfirmDeleteModal from \"../../common/ConfirmDeleteModal\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\n\nexport default function CustomerList(props: CustomerListProps) {\n \n const appDispatch = useAppDispatch();\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const { isRefresh, openCustomerModal, refreshCustomers } = props;\n const [customers, setCustomers] = useState<Customer[]>([]);\n const [customerToDelete, setCustomerToDelete] = useState<Customer | null>(null);\n const [customersSearch, setCustomersSearch] = useState<CustomerSearch[]>([]);\n const [totalCustomers, setTotalCustomers] = useState<number>(0);\n const [page, setPage] = useState<number>(1);\n const pageSize: number = 20;\n const [order, setOrder] = useState<\"asc\" | \"desc\">(\"asc\");\n const [orderBy, setOrderBy] = useState<string>(\"firstName\");\n const [currentCustomerId, setCurrentCustomerId] = useState<string>();\n const [search, setSearch] = useState<string>();\n const [customerFound, setCustomerFound] = useState<boolean>(true);\n const [deleteConfirmationModalIsOpen, setDeleteConfirmationModalIsOpen] = useState<boolean>(false);\n const history = useHistory();\n const mobileTemplate: string = \"000-000-0000\";\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n \n const selectedEstablishments = useAppSelector(state => state.enterprise.selectedEstablishments)\n\n const hasCustomerInfoVisible = ApiClient.getUserInfo().hasCustomerInfoVisible;\n \n const titleTerminology = useCustomerTerminology(t(\"Customers\"), \"Customers\");\n const customerDeletedLabel = useCustomerTerminology(t(\"Deleted customer\"), \"customer\");\n const deleteCustomerQuestionLabel = useCustomerTerminology(t(\"Are you sure you want to delete this customer?\"), \"customer\");\n const deleteCustomerAlertLabel = useCustomerTerminology(t(\"All data for this customer will be deleted.\"), \"customer\");\n const deleteCustomerButtonLabel = useCustomerTerminology(t(\"Delete customer\"), \"customer\");\n const deleteCustomerUpcomingAppointmentsQuestionPartlyLabel = useCustomerTerminology(t(\"existing appointments with this customer that cannot be served if you delete this customer.\"), \"customer\", \"customer\");\n const deleteCustomerUpcomingAppointmentsAlertLabel = useCustomerTerminology(t(\"We suggest you confirm that you want to delete this customer.\"), \"customer\");\n\n appDispatch(applicationInterfaceActions.updateTitle(titleTerminology));\n\n useEffect(() => {\n appDispatch(applicationInterfaceActions.updateTitle(titleTerminology));\n\n (async () => {\n await loadData();\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [page, orderBy, order, isRefresh, accountSettings.isEnterprise, selectedEstablishments]);\n\n useEffect(() => {\n\n if (search && search.length > 2) {\n (async () => {\n await loadSearchData();\n })();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [search, accountSettings.isEnterprise, selectedEstablishments]);\n\n function fillMobileData() {\n const countries = accountSettings.countries;\n let customersWithMobileData = [...customers].map(customer => {\n let mobileCode = customer.mobileCodeIso3 ?? \"MEX\";\n customer.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n customer.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n customer.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n return customer;\n });\n setCustomers(customersWithMobileData);\n }\n\n useEffect(() => {\n if (accountSettings.countries.length && customers.length) {\n fillMobileData();\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [accountSettings.countries, customers[0]]);\n\n const loadData = async () => {\n appDispatch(navbarActions.setShowLoader(true));\n if (accountSettings.isEnterprise === null) return;\n const customers = accountSettings.isEnterprise \n ? await CustomerService.getCustomersByEstablishments(\n page,\n pageSize, \n selectedEstablishments,\n order,\n orderBy,\n )\n : await CustomerService.getCustomers(\n page,\n pageSize,\n order,\n orderBy,\n localeApp\n );\n appDispatch(navbarActions.setShowLoader(false));\n\n if (accountSettings.countries.length) {\n fillMobileData();\n }\n\n setCustomers(customers.customers || []);\n setTotalCustomers(customers.totalCustomers || 0);\n setCustomerFound(customers.customers?.length! > 0);\n };\n\n const handleOnSelectCustomer = async (id: string) => {\n const response = await CustomerService.getById(id);\n if (response.customer) {\n setCustomers([response.customer] || []);\n setTotalCustomers(1);\n setCustomerFound(true);\n }\n };\n \n const loadSearchData = async () => {\n const customers = accountSettings.isEnterprise \n ? await CustomerService.getSearchByEstablishments(selectedEstablishments, search)\n : await CustomerService.getSearch(search);\n const countries = accountSettings.countries;\n\n [...customers].map(customer => {\n let mobileCode = customer.mobileCodeIso3 ?? \"MEX\";\n customer.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits.toString();\n customer.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode.toString();\n customer.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n return customer;\n })\n \n if (customers.length !== 0) {\n setCustomerFound(true);\n setCustomersSearch(customers || []);\n } else {\n resetSearchResults();\n }\n };\n \n const getCustomerGender = (customer: Customer) => {\n switch (customer.gender){\n case Gender.Male:\n return t(\"Male\");\n case Gender.Female:\n return t(\"Female\");\n case Gender.PreferNotToSay:\n return t(\"I prefer not to say\");\n case Gender.Custom:\n return customer.customGender;\n default:\n return \"--\";\n }\n };\n\n const resetSearchResults = () => {\n setCustomerFound(false);\n setCustomersSearch([]);\n setCustomers([]);\n setTotalCustomers(0);\n }\n\n function shortString(value: string) {\n return value?.length > 50 \n ? value.substring(0, 47) + \"...\"\n : value;\n }\n\n const columns: TableColumn[] = [\n {\n id: \"name\",\n label: useCustomerTerminology(t(\"CUSTOMER\"), \"CUSTOMER\"),\n sorting: true,\n width: 240,\n },\n {\n id: \"establishmentName\",\n label: t(\"ESTABLISHMENT\"),\n width: 115,\n sorting: true,\n component: (item: any) => shortString(item),\n visible: accountSettings?.isEnterprise ?? false\n },\n {\n id: \"mobileCodeIso3\",\n label: t(\"COUNTRY\"),\n sorting: true,\n completeObject: true,\n component: (item: any) => <>\n {item && <>\n <CountryFlagIcon iso={item.mobileCodeIso3} />\n <div style={{ width: 30, display: \"inline-block\", textAlign: \"center\" }}>\n {`+${item.mobileCode}`}\n </div>\n </>}\n </>,\n width: 115,\n headerTextAlign: \"center\",\n textAlign: \"center\",\n visible: hasCustomerInfoVisible\n },\n {\n id: \"mobile\",\n label: t(\"MOBILE\"),\n sorting: true,\n completeObject: true,\n component: (item: any) => (\n <>\n {\n item.mobile ? conformToMask(item.mobile, GetMobileMaskByTemp(item.mobileTemplate || mobileTemplate)).conformedValue : \"\"\n }\n </>\n ),\n width: 100,\n visible: hasCustomerInfoVisible\n },\n {\n id: \"email\",\n label: t(\"EMAIL\"),\n sorting: true,\n width: 240,\n component: (email: any) => <>{email || \"--\"}</>,\n visible: hasCustomerInfoVisible\n },\n {\n id: \"gender\",\n label: t(\"GENDER\"),\n sorting: true,\n completeObject: true,\n component: getCustomerGender,\n width: 80,\n },\n {\n id: \"contactable\",\n label: t(\"CONTACTABLE\"),\n sorting: true,\n component: (contactable: any) => <>{contactable ? t(\"Yes\") : t(\"No\")}</>,\n width: 115,\n textAlign: \"left\",\n },\n {\n id: \"frequencyType\",\n label: t(\"FREQUENCY\"),\n sorting: true,\n component: (frequencyType: any) => <StatusIcon status={frequencyType} />,\n width: 115,\n textAlign: \"left\",\n },\n {\n id: \"actions\",\n label: t(\"ACTIONS\"),\n sorting: false,\n completeObject: true,\n component: (customer: Customer) => <Button onClick={(e) => { e.stopPropagation(); handleDeleteCustomerClick(customer) }}>\n <TrashIcon style={{ color: Color.gray5, width: 13, height: 17, }} />\n </Button>,\n width: 50,\n textAlign: \"center\",\n visible: !accountSettings.isEnterprise\n },\n ];\n\n const handleOnChangeGrid = (event: OnChangeEvent) => {\n setPage(event.page);\n if (event.sorting) {\n setOrder(event.sorting.direction);\n setOrderBy(\n event.sorting.orderBy === \"name\" ? \"firstName\" : event.sorting.orderBy\n );\n }\n };\n\n const handleOnRowClick = (item: Customer) => {\n if (!accountSettings.isEnterprise) {\n history.push(`${Url.Customers.Main}/${item.id}`);\n }\n };\n\n const handleDeleteCustomerClick = (customer: Customer) => {\n setCustomerToDelete(customer);\n setDeleteConfirmationModalIsOpen(true);\n };\n\n const handleDeleteCustomerConfirmClick = async () => {\n const isDeleted = await CustomerService.deleteCustomer(customerToDelete!.id!)\n\n if (isDeleted) {\n const customersWithoutDeletedCustomer = [...customers].filter(c => c.id !== customerToDelete!.id);\n setCustomers(customersWithoutDeletedCustomer);\n refreshCustomers();\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: customerDeletedLabel.charAt(0).toUpperCase() + customerDeletedLabel.slice(1),\n description: customerToDelete?.name\n })\n );\n }\n\n setCustomerToDelete(null);\n setDeleteConfirmationModalIsOpen(false);\n };\n\n const DeleteCustomerModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {deleteCustomerQuestionLabel}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentBoldText}>\n {customerToDelete?.name}\n </Typography>\n <Typography className={classes.deleteModalContentText}>\n {deleteCustomerAlertLabel}\n </Typography>\n </div>);\n };\n\n const DeleteCustomerWithAppointmentsModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"There are\") + \" \" + customerToDelete?.upcomingAppointmentsCount + \" \"\n + deleteCustomerUpcomingAppointmentsQuestionPartlyLabel}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentText}>\n {deleteCustomerUpcomingAppointmentsAlertLabel}\n </Typography>\n </div>);\n };\n\n\n return (\n <div className={classes.divMain}>\n <Autocomplete\n style={{ width: 464, marginBottom: 19 }}\n items={customersSearch}\n placeholder={useCustomerTerminology(t(\"Search customer\"), \"customer\")}\n renderOption={(option: CustomerSearch) => {\n return <div className={classes.searchResultLabel}>\n {`${option.firstName} ${option.lastName}`}\n {hasCustomerInfoVisible\n ? <span>\n {\" / \"}\n <CountryFlagIcon iso={option.mobileCodeIso3!} />\n {\" +\" + option.mobileCode + \" \"}\n {conformToMask(option.mobile!, GetMobileMaskByTemp(option.mobileTemplate!)).conformedValue}\n </span>\n : <></>}\n </div>\n }\n }\n getOptionSelected={(option, value) =>\n `${option.firstName} ${option.lastName}` ===\n `${value.firstName} ${value.lastName}`\n }\n getOptionLabel={(option) =>\n `${option?.firstName || \"\"} ${option?.lastName || \"\"}`.trim()\n }\n filterOptions={createFilterOptions({\n stringify: (option) => search || \"\"\n })}\n onChange={(value: any, reason) => {\n if (reason === \"input\") {\n setSearch(value);\n }\n }}\n onSelected={(option: any) => {\n const customerId = option?.id || undefined;\n if (customerId !== currentCustomerId) {\n resetSearchResults();\n setCurrentCustomerId(option?.id || undefined);\n handleOnSelectCustomer(option?.id);\n }\n }}\n cleanInput={isRefresh}\n />\n <GridList\n columns={columns}\n items={customers}\n totalItems={totalCustomers}\n pageSize={20}\n onChange={handleOnChangeGrid}\n onRowClick={handleOnRowClick}\n />\n {\n !customerFound && <>\n <div className={classes.notFound}>\n <SearchIcon style={{ fontSize: 48 }} />\n <br /><br />\n {\n accountSettings.isEnterprise\n ?\n <>\n {t(\"There are no registered customers. Register customers from the account to which it belongs.\")}\n </>\n : \n <>\n {t(\"Customer not found\")},\n <br />\n {t(\"please\")}\n <div className={classes.linkRegister} onClick={() => openCustomerModal()}>\n {t(\"register it\")}.\n </div>\n </>\n }\n </div>\n </>\n }\n {customerToDelete\n ? <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteConfirmationModalIsOpen}\n item={customerToDelete}\n componentInfo={customerToDelete!.upcomingAppointmentsCount! > 0\n ? <DeleteCustomerWithAppointmentsModalContent />\n : <DeleteCustomerModalContent />}\n onClose={() => setDeleteConfirmationModalIsOpen(false)}\n onDelete={() => handleDeleteCustomerConfirmClick()}\n textButtonConfirm={deleteCustomerButtonLabel} />\n : <></>}\n </div>\n );\n};","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n width: \"100%\",\n },\n root: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n width: \"100%\",\n justifyContent: \"flex-end\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n importCustomer: {\n border: \"1px solid #6462F3\",\n marginRight: 25,\n color: \"#6462F3\",\n },\n newCustomer: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n },\n}));\n\nexport default useStyles;\n","import { useTranslation } from \"react-i18next\";\n\n\nexport class CustomersClassificationEntity {\n id: string | null;\n description: string | null;\n months: number | null;\n classificationType?: CustomerClassificationType | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\" && x != null) {\n this.id = x.id;\n this.description = x.description;\n this.months = x.months;\n this.classificationType = null;\n } else {\n this.id = null;\n this.description = null;\n this.months = null;\n this.classificationType = null;\n }\n }\n}\n\n\nexport enum CustomerClassificationType {\n Frequent = 0,\n Infrequent,\n Inactive\n}\n\n\nexport const GetCustomerClassificationLocale = (type: CustomerClassificationType = CustomerClassificationType.Frequent): string[] => {\n\n const { t } = useTranslation([\"general\"]);\n let items: string[] = [];\n\n if (type === CustomerClassificationType.Inactive) {\n\n items.push(t('0 appointments in the last month'))\n\n for (let m: number = 2; m <= 12; m++) {\n items.push(t('0 appointments in the last N months', { numMonth: m }))\n }\n } else {\n items.push(t('1 appointment in the last month'))\n\n for (let m: number = 2; m <= 12; m++) {\n items.push(t('1 appointment in the last N months', { numMonth: m }))\n }\n }\n\n\n return items;\n}\n\n\n","export class CustomersClassification {\n total: number | null;\n frequent: number | null;\n infrequent: number | null;\n inactive: number | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\" && x != null) {\n this.total = x.total;\n this.frequent = x.frequent;\n this.infrequent = x.infrequent;\n this.inactive = x.inactive;\n } else {\n this.total = null;\n this.frequent = null;\n this.infrequent = null;\n this.inactive = null;\n }\n }\n}\n","export class CustomersClassifications {\n customerFrequencyClassificationFrequentId: string | null;\n customerFrequencyClassificationInfrequentId: string | null;\n customerFrequencyClassificationInactiveId: string | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\" && x != null) {\n this.customerFrequencyClassificationFrequentId =\n x.customerFrequencyClassificationFrequentId;\n this.customerFrequencyClassificationInfrequentId =\n x.customerFrequencyClassificationInfrequentId;\n this.customerFrequencyClassificationInactiveId =\n x.customerFrequencyClassificationInactiveId;\n } else {\n this.customerFrequencyClassificationFrequentId = null;\n this.customerFrequencyClassificationInfrequentId = null;\n this.customerFrequencyClassificationInactiveId = null;\n }\n }\n}\n","import { ApiClient } from \"./api-client\";\nimport { CustomersClassification } from \"../models/customers-classification\";\nimport { CustomersClassifications } from \"../models/customers-classifications\";\nimport { CustomerClassificationType, CustomersClassificationEntity } from \"../models/customers-classification-entity\";\n\nexport class CustomerClassificationService {\n\n private static baseUrl = \"/customer\";\n\n static getCustomerClassification(): Promise<CustomersClassification> {\n return ApiClient.get(`${this.baseUrl}/getclassification`).then(\n (data) => new CustomersClassification(data.customerClassification)\n );\n }\n \n static getCustomerClassificationByEstablishments(establishmentIds: string[] | undefined): Promise<CustomersClassification> {\n let endpoint = `${this.baseUrl}/getclassificationbyestablishments?`\n \n endpoint += Object.entries({\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\");\n \n return ApiClient.get(endpoint).then(\n (data) => new CustomersClassification(data.customerClassification)\n );\n }\n\n\n private static baseUrlCustomerClassification = \"/customerclassification\";\n\n static getCustomerClassifications(establishmentAccountId?: string): Promise<CustomersClassifications> {\n let url = `${this.baseUrlCustomerClassification}/getclassifications`;\n\n if (establishmentAccountId) {\n url += `?AccountId=${establishmentAccountId}`;\n }\n\n return ApiClient.get(url)\n .then((data) => {\n return new CustomersClassifications(data.customerClassifications);\n });\n }\n\n static getCustomerClassificationList(establishmentAccountId?: string): Promise<CustomersClassificationEntity[]> {\n let url = `${this.baseUrlCustomerClassification}/getclassificationlist`;\n\n if (establishmentAccountId) {\n url += `?AccountId=${establishmentAccountId}`;\n }\n\n return ApiClient.get(url)\n .then((data) => {\n return data.customerClassificationList.map((x: CustomersClassificationEntity) => new CustomersClassificationEntity(x));\n });\n }\n\n static updateCustomersClassification(frecuencyId: string, type: CustomerClassificationType, establishmentAccountId?: string): Promise<any> {\n return ApiClient.post(`${this.baseUrlCustomerClassification}/updatecustomersclassification`, {\n accountId: establishmentAccountId,\n customerFrequencyId: frecuencyId,\n ClassificationTypeUpd: type\n }).then((data) => {\n return (data.customerClassifications);\n });\n }\n\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n container: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"end\",\n }\n}));\n\nexport default useStyles;\n","import * as React from \"react\";\nimport { useEffect } from \"react\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\n\nimport useStyles from \"./css\";\nimport { LocalStorageKey } from \"../../../constants/local-storage-key\";\nimport EstablishmentSelector from \"../../navbar/EstablishmentSelector\";\nimport useLocalStorageState from \"../../../hooks/useLocalStorageState\";\nimport { enterpriseActions } from \"../../../redux/enterprise-slice\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\n\n\nexport default function EstablishmentsToolbar() {\n \n const classes = useStyles();\n const dispatch = useAppDispatch();\n \n const userInfo = useAppSelector(state => state.userInfo)\n const accountSettings = useAppSelector((state) => state.accountSettings);\n const establishmentsStorageKey = LocalStorageKey.Establishments + userInfo.userId;\n const { setSelectedEstablishments } = enterpriseActions;\n // @ts-ignore\n const [accountEstablishments, setAccountEstablishments] = useLocalStorageState({ itemKey: establishmentsStorageKey, dispatchFunction: setSelectedEstablishments });\n \n useEffect(\n () => {\n dispatch(navbarActions.setExternalContent((\n <>\n {\n accountSettings.isEnterprise ?\n <div className={classes.container}>\n <EstablishmentSelector\n establishments={accountEstablishments ?? []}\n setEstablishments={setAccountEstablishments}\n items={accountSettings?.establishments ?? []}\n />\n </div>\n : null\n }\n </>)));\n },\n [accountSettings, accountEstablishments]\n );\n \n return null;\n}\n","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\nimport { useHistory } from \"react-router-dom\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\nimport Button from \"@material-ui/core/Button\";\n\nimport CustomerClassification from \"../CustomerClassification\";\nimport { ImportIcon } from \"../../../assets/icons\";\nimport CustomerModal from \"./../CustomerModal\";\nimport CustomerImportModal from \"./../CustomerImportModal\";\nimport CustomerList from \"./../CustomerList\";\nimport { Url } from \"../../../constants/url\";\nimport useStyles from \"./css\";\nimport { CustomersClassification } from \"../../../models/customers-classification\";\nimport { CustomerClassificationService } from \"../../../api/customer-classification-service\";\nimport EstablishmentsToolbar from \"../../common/EstablishmentsToolbar/establishments-toolbar\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\n\n\nexport default function CustomerMainPage() {\n \n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const history = useHistory();\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [openImportModal, setOpenImportModal] = useState<boolean>(false);\n\n const [isRefresh, setIsRefresh] = useState<any>();\n const [customerClassification, setCustomerClassification] = useState<CustomersClassification>(new CustomersClassification());\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const selectedEstablishments = useAppSelector(state => state.enterprise.selectedEstablishments)\n \n useEffect(() => {\n async function fetchData() {\n await loadCustomerClassification();\n }\n \n fetchData();\n }, [isRefresh, accountSettings.isEnterprise, selectedEstablishments]);\n \n async function loadCustomerClassification() {\n dispatch(navbarActions.setShowLoader(true));\n if (accountSettings.isEnterprise === null) return;\n const classification = accountSettings.isEnterprise \n ? await CustomerClassificationService.getCustomerClassificationByEstablishments(selectedEstablishments)\n : await CustomerClassificationService.getCustomerClassification();\n dispatch(navbarActions.setShowLoader(false));\n setCustomerClassification(classification);\n }\n\n function handleOpenModal() {\n setOpenModal(true);\n }\n\n function handleCloseModal() {\n setOpenModal(false);\n }\n \n function handleOpenImportModal() {\n setOpenImportModal(true);\n }\n\n function handleCloseImportModal() {\n setOpenImportModal(false);\n }\n\n function handleCustomerCreated(customer: any) {\n setIsRefresh(customer);\n setOpenModal(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Customer Created\"),\n description: `${customer.firstName} ${customer.lastName}`\n })\n );\n }\n\n function handleCustomerDuplicated(customer: any) {\n setIsRefresh(customer);\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid number\"),\n description: t(\"This number already belongs to customer\"),\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n history.push(`${Url.Customers.Main}/${customer.id}`);\n },\n title: `${customer.firstName} ${customer.lastName}`,\n }\n })\n );\n }\n \n const importCustomersTitle = useCustomerTerminology(t(\"Import customers\"), \"customers\")\n const createCustomerTitle = useCustomerTerminology(t(\"Create customer\"), \"customer\")\n\n return (\n <>\n <EstablishmentsToolbar />\n <div className={classes.header}>\n <CustomerClassification \n classification={customerClassification} \n />\n {\n accountSettings.isEnterprise \n ? null\n : \n <>\n <div className={classes.root}>\n <ButtonWithSpinner\n width={200}\n margin={\"0px 16px 0px 0px\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n fill={ButtonPropsFill.Outlined}\n innerText={importCustomersTitle}\n innerIcon={<ImportIcon/>}\n onClick={handleOpenImportModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={createCustomerTitle}\n onClick={handleOpenModal}\n />\n </div>\n </>\n }\n </div>\n <CustomerList\n isRefresh={isRefresh}\n openCustomerModal={handleOpenModal}\n refreshCustomers={() => { setIsRefresh(Math.random()) }}\n />\n <CustomerImportModal\n open={openImportModal}\n onClose={handleCloseImportModal}\n refreshCustomers={() => { setIsRefresh(Math.random()) }}\n />\n <CustomerModal\n open={openModal}\n onClose={handleCloseModal}\n onDuplicate={handleCustomerDuplicated}\n onCreate={handleCustomerCreated}\n />\n </>\n );\n};\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n borderBottom: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n rootTab: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey6,\n minWidth: \"auto\",\n padding: 0,\n margin: \"0px 0px 0px 24px\",\n textTransform: \"none\",\n [theme.breakpoints.up(\"sm\")]: {\n minWidth: \"auto\",\n padding: 0,\n margin: \"0px 0px 0px 24px\",\n },\n },\n tabSelected: {\n fontWeight: \"bold\",\n color: `${theme.colors.clearMain} !important`, //\"#6462F3 !important\",\n },\n}));\n\nexport default useStyles;\n","\nexport enum Month\n{\n January = 0,\n February,\n March,\n April,\n May,\n June,\n July,\n August,\n September,\n October,\n November,\n December\n}\n\n\nexport const GetMonthStringEnum = (num: Month | number): string => {\n \n const month: { [key: number] : string } = {\n 0: \"January\",\n 1: \"February\",\n 2: \"March\",\n 3: \"April\",\n 4: \"May\",\n 5: \"June\",\n 6: \"July\",\n 7: \"August\",\n 8: \"September\",\n 9: \"October\",\n 10: \"November\",\n 11: \"December\"\n };\n\n return month[num] || \"\";\n}\n\n","import React from \"react\";\n\nimport MuiTabs from \"@material-ui/core/Tabs\";\nimport Tab from \"@material-ui/core/Tab\";\nimport Box from \"@material-ui/core/Box\";\n\nimport useStyles from \"./css\";\nimport { TabsProps } from \"./props\";\n\nconst Tabs = (props: TabsProps) => {\n const { value, tabs, onChange } = props;\n const classes = useStyles();\n\n const handleChange = (event: React.ChangeEvent<{}>, newValue: number) => {\n if (onChange) {\n onChange(newValue);\n }\n };\n\n const a11yProps = (index: any) => {\n return {\n id: `tab-${index}`,\n \"aria-controls\": `tabpanel-${index}`,\n };\n };\n\n return (\n <Box>\n <MuiTabs\n className={classes.root}\n value={value}\n onChange={handleChange}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n aria-label=\"tabs\"\n >\n {tabs.map((tab) => (\n <Tab\n classes={{ root: classes.rootTab, selected: classes.tabSelected }}\n key={tab.index}\n label={tab.label}\n {...a11yProps(tab.index)}\n />\n ))}\n </MuiTabs>\n </Box>\n );\n};\n\nexport default Tabs;\n","import React from \"react\";\n\nimport Box from \"@material-ui/core/Box\";\n\nimport { TabPanelProps } from \"./props\";\n\nconst TabPanel = (props: TabPanelProps) => {\n const { children, value, index, ...other } = props;\n return (\n <div\n role=\"tabpanel\"\n hidden={value !== index}\n id={`simple-tabpanel-${index}`}\n aria-labelledby={`simple-tab-${index}`}\n {...other}\n >\n {value === index && <Box>{children}</Box>}\n </div>\n );\n};\n\nexport default TabPanel;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n customerData: {\n width: 256,\n },\n content: {\n border: \"1px solid #DBDCDD\",\n borderRadius: 12,\n boxSizing: \"border-box\",\n padding: 16,\n height: 417,\n boxShadow: \"none\",\n },\n goBackButton: {\n display: \"flex\",\n alignItems: \"center\",\n cursor: \"pointer\",\n height: 32,\n },\n goBackButtonText: {\n margin: \"0px 0px 0px 17px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n lineHeight: \"15px\",\n display: \"flex\",\n alignItems: \"center\",\n textAlign: \"center\",\n color: \"#786EFF\",\n },\n customerStatus: {\n display: \"flex\",\n alignItems: \"center\",\n margin: \"24px 0px 0px 0px\",\n },\n titleText: {\n ...theme.typography.header4,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n contentText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n },\n contentBoldText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n customerName: {\n margin: \"9px 0px 0px 0px\",\n },\n customerAge: {\n margin: \"4px 0px 0px 0px\",\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n appointments: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n },\n appointmentsContent: {\n width: 104,\n },\n appointmentsContentDoubleSpace: {\n width: 208,\n },\n service: {\n display: \"flex\",\n alignItems: \"center\",\n marginTop: 4,\n marginBottom: 4,\n },\n serviceText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n },\n dateRegistered: {\n display: \"flex\",\n alignItems: \"center\",\n margin: \"16px 0px 0px 0px\",\n },\n dateRegisteredText: {\n margin: \"0px 0px 0px 9px\",\n },\n}));\n\nexport default useStyles;\n","import React, {useEffect, useState, useRef} from \"react\";\nimport { useHistory } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\nimport Paper from \"@material-ui/core/Paper\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { MinusArrowIcon, StatusIcon } from \"../../../assets/icons\";\nimport { Url } from \"./../../../constants/url\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { CustomerData } from \"./../../../models/customer-data\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\n\nimport useStyles from \"./css\";\nimport { CustomerDataInfoProps } from \"./props\";\nimport { CustomerFrequencyType } from \"../../../models/enums/customer-frequency-type\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\n\nconst CustomerDataInfo = (props: CustomerDataInfoProps) => {\n const { t } = useTranslation([\"general\"]);\n const { customerId, name, birthDate } = props;\n const classes = useStyles();\n const history = useHistory();\n const dispatch = useAppDispatch();\n const [customer, setCustomer] = useState<CustomerData>(new CustomerData());\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n const isDataLoad = useRef<boolean>(false);\n\n useEffect(() => {\n if (isDataLoad.current || accountSettings.accountName === \"\" || accountSettings.isClinicMode) //need to prevent useless API call in clinic mode\n return;\n async function fetchData() {\n await loadData();\n }\n\n isDataLoad.current = true;\n void fetchData();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [accountSettings.accountName]);\n\n useEffect(() => {\n if (customer.name !== name)\n {\n setCustomer({ ...customer, name: name || null });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [name]);\n\n useEffect(() => {\n if (!customer.birthDate || birthDate && new Date(customer.birthDate).getTime() !== birthDate.getTime())\n {\n setCustomer({ ...customer, birthDate: birthDate });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [birthDate]);\n\n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const customerData = await CustomerService.getCustomerData(customerId);\n dispatch(navbarActions.setShowLoader(false));\n setCustomer(customerData);\n };\n\n const handleGoBackClick = () => {\n history.push(`${Url.Customers.Main}`);\n };\n\n const getAge = (birthDate?: Date | null): number => {\n if (!birthDate) {\n return 0;\n }\n\n var dob = new Date(birthDate);\n //calculate month difference from current date in time\n var month_diff = Date.now() - dob.getTime();\n\n //convert the calculated difference in date format\n var age_dt = new Date(month_diff);\n\n //extract year from date\n var year = age_dt.getUTCFullYear();\n\n //now calculate the age of the user\n return Math.abs(year - 1970);\n };\n\n const date = (created: Date): string => {\n var createdDate = new Date(created);\n return createdDate.toLocaleString(localeApp, {\n day: \"numeric\",\n month: \"long\",\n year: \"numeric\",\n });\n };\n\n const customerStatus = (status: CustomerFrequencyType) => {\n switch (status) {\n case CustomerFrequencyType.Frequent:\n return t(\"Frequent Client\");\n case CustomerFrequencyType.Infrequent:\n return t(\"Infrequent Client\");\n default:\n return t(\"Inactive Client\");\n }\n };\n\n return (\n <div className={classes.customerData}>\n <Paper className={classes.content}>\n <span className={classes.goBackButton} onClick={handleGoBackClick}>\n <MinusArrowIcon />\n <Typography className={classes.goBackButtonText}>\n {t(\"Go back to customers listing\")}\n </Typography>\n </span>\n <div className={classes.customerStatus}>\n <StatusIcon status={customer.frequencyType} />\n <Typography className={classes.contentText}>\n {customerStatus(customer.frequencyType)}\n </Typography>\n </div>\n <div className={classes.customerName}>\n <Typography className={classes.titleText}>\n {customer?.name}\n </Typography>\n </div>\n <div className={classes.customerAge}>\n <Typography className={classes.contentText}>\n {getAge(customer.birthDate)} {t(\"years\")}\n </Typography>\n </div>\n <div className={classes.separator}></div>\n <div className={classes.appointments}>\n <div className={classes.appointmentsContent}>\n <Typography className={classes.contentText}>\n {t(\"Appointments created\")}\n </Typography>\n <Typography className={classes.titleText}>\n {customer?.appointments}\n </Typography>\n </div>\n <div className={classes.appointmentsContent}>\n <Typography className={classes.contentText}>\n {t(\"Attended\")}\n </Typography>\n <Typography className={classes.titleText}>\n {customer?.attended}\n </Typography>\n </div>\n </div>\n <div className={classes.separator}></div>\n <div className={classes.appointments}>\n <div className={classes.appointmentsContentDoubleSpace}>\n <Typography className={classes.contentText}>\n {t(\"Services fulfilled\")}\n </Typography>\n <Typography className={classes.titleText}>\n {customer?.services}\n </Typography>\n </div>\n </div>\n <div className={classes.separator}></div>\n <div>\n <Typography className={classes.contentText}>\n {t(\"Favorite Service\")}\n </Typography>\n <div className={classes.service}>\n <Typography className={classes.titleText}>\n {customer?.serviceName || t(\"No Services\")}\n </Typography>\n <Typography\n style={{ marginLeft: 4 }}\n className={classes.serviceText}\n >\n (${customer?.servicePrice})\n </Typography>\n </div>\n <Typography className={classes.serviceText}>\n {t(\"Times requested\")} ({customer?.serviceTimes})\n </Typography>\n </div>\n </Paper>\n <div className={classes.dateRegistered}>\n <Typography className={classes.contentText}>\n {t(\"Date registered\")}\n </Typography>\n <Typography\n className={`${classes.contentBoldText} ${classes.dateRegisteredText}`}\n >\n {date(customer.created)}\n </Typography>\n </div>\n </div>\n );\n};\n\nexport default CustomerDataInfo;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n customerHistoryPanel: {\n height: 560,\n position: \"absolute\",\n width: 779,\n overflow: \"hidden\",\n },\n customerHistoryPanelContent: {\n overflowY: \"scroll\",\n maxHeight: \"calc(100vh - 152px)\",\n padding: \"28px 28px 0px 28px\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n customerDetails: {\n width: 779,\n height: 610,\n margin: \"0px 0px 0px 36px\",\n },\n customerDetailsContent: {\n width: 779,\n height: 610,\n borderRadius: 12,\n border: \"1px solid #DBDCDD\",\n backgroundColor: \"#FFF\",\n boxShadow: \"none\",\n },\n customerHistoryTitle: {\n display: \"flex\",\n alignItems: \"center\",\n },\n customerHistoryContent: {\n margin: \"20px 0px 0px 0px\",\n },\n infoContentRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n contactRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n },\n iconTitle: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n margin: \"0px 0px 0px 10px\",\n },\n recurringAppointment: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderTop: \"1px solid #C9CDD361\",\n paddingTop: 10,\n marginTop: 10,\n width: \"90%\",\n marginLeft: \"auto\",\n marginRight: \"auto\"\n },\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n required: {\n color: \"#6462F3\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n display: \"flex\",\n margin: 0,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n description: {\n margin: 0,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n monthYear: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontSize: 18,\n color: \"#6462F3\"\n },\n accordion: {\n border: \"none\",\n boxShadow: \"none\"\n },\n accordionSummary: {\n padding: 0\n },\n accordionDetails: {\n padding: 0\n },\n appointmentsBox: {\n border: \"1px solid #C9CDD3\",\n boxShadow: \"1px 1px 3px rgba(0, 0, 0, 0.15)\",\n borderRadius: 4,\n background: \"#FFFFFF\",\n //opacity: 0.5,\n width: \"100%\", //680,\n marginBottom: 20,\n padding: 15\n },\n appointmentsGrid: {\n width: \"100%\",\n },\n appointmentsGridLine: {\n borderBottom: \"1px solid #C9CDD3\",\n marginTop: 10,\n marginBottom: 10,\n width: \"80%\",\n alignContent: \"center\",\n marginLeft: \"auto\",\n marginRight: \"auto\",\n opacity: 0.5\n },\n headerAppointments: {\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n lineHight: 14,\n display: \"flex\",\n alignItems: \"center\",\n color: \"#919CA5\"\n },\n serviceName: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontSize: 14,\n display: \"flex\",\n alignItems: \"center\",\n color: \"#5C6477\"\n },\n serviceDate: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontSize: 14,\n display: \"flex\",\n alignItems: \"center\",\n color: \"#5C6477\"\n },\n servicePrice: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontSize: 14,\n display: \"flex\",\n alignItems: \"center\",\n color: \"#5C6477\"\n },\n serviceStatus: {\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n display: \"flex\",\n alignItems: \"center\",\n color: \"#5C6477\",\n },\n expandIcon: {\n flexDirection: 'row-reverse',\n display: \"none\"\n //order: -1\n },\n expanded: {\n \"& * svg\": {\n flexDirection: 'row-reverse',\n transform: 'rotate(180deg)',\n\n }\n },\n ArrowIcon: {\n color: \"#6462F3\",\n fontSize: 24,\n width: 18,\n marginLeft: 10,\n height: 15\n },\n divStatus: {\n borderRadius: 5,\n color: \"#FFFFFF\",\n padding: \"5px 10px\",\n width: \"fit-content\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n marginBottom: 10,\n marginRight: 5,\n display: \"inline-block\"\n },\n statusConfirmed: {\n color: \"#0BCBE0\",\n backgroundColor: \"rgba(11, 203, 224, 0.2)\"\n },\n statusArrived: {\n marginLeft: -2,\n color: \"#36CE91\",\n backgroundColor: \"rgba(54, 206, 145, 0.2)\"\n },\n statusNotConfirmed: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\",\n },\n statusNotArrived: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\",\n },\n statusCanceled: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\"\n },\n apptDisabledGrid: {\n \"& * p\": {\n opacity: 0.5\n }\n },\n divNotes: {\n borderRadius: 5,\n color: \"#FFFFFF\",\n padding: \"5px 8px 5px 10px\",\n width: \"fit-content\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n cursor: \"pointer\"\n },\n divNotesNone: {\n marginLeft: -2,\n color: \"#36CE91\",\n backgroundColor: \"rgba(145, 156, 165, 0.2)\"\n },\n divNotesExists: {\n marginLeft: -2,\n color: \"#36CE91\",\n backgroundColor: \"rgba(100, 98, 243, 0.2)\"\n },\n drawerHistoryDetails: {\n color: \"#000\",\n background: \"#fff\",\n borderTopLeftRadius: 20,\n borderBottomLeftRadius: 20,\n width: \"250px\",\n },\n statusPaid: {\n color: \"#36CE91\",\n backgroundColor: \"rgba(54, 206, 145, 0.2)\"\n },\n statusUnpaid: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\",\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n \"&.tox-toolbar__group\": {\n color: theme.colors.grey4\n },\n \"&.tox-editor-container\": {\n backgroundColor: theme.colors.grey1\n }},\n customerHistoryDetailsPanel: {\n color: \"#000\",\n background: \"#fff\",\n borderTopLeftRadius: 20,\n borderBottomLeftRadius: 20,\n width: \"250px\",\n padding: \"20px 15px\"\n },\n counter: {\n position: \"absolute\",\n bottom: 7,\n right: 153,\n fontSize: 12,\n color: theme.colors.grey5,\n padding: \"5px\",\n },\n closeDrawer: {\n color: theme.colors.clearMain,\n fontSize: 12,\n marginBottom: 30,\n cursor: \"pointer\"\n },\n closeDrawerIcon: {\n display: \"inline-block\"\n },\n closeDrawerText: {\n display: \"inline-block\",\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n position: \"relative\",\n top: -4\n },\n divGroup: {\n marginBottom: 20\n },\n title: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12,\n color: theme.colors.grey4,\n marginBottom: 5\n },\n service: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n color: theme.colors.grey5\n },\n specialist: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: theme.colors.grey5\n },\n dateTimeInfo: {\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12,\n color: theme.colors.grey5\n },\n statusLabel: {\n\n },\n divTiny: {\n position: \"relative\",\n \"& div.tox-tinymce\": {\n borderRadius: 5\n },\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& div.tox-toolbar__primary, div.tox-edit-area, iframe.tox-edit-area__iframe, #tinymce\": {\n backgroundColor: \"#F6F6F6 !important\"\n },\n \"& iframe.tox-edit-area__iframe\": {\n height: \"75%\"\n },\n \"& div.tox-statusbar\": {\n display: \"none\"\n }\n },\n divTinyFocus: {\n \"& div.tox-tinymce\": {\n borderColor: \"#6462F3 !important\"\n },\n \"& svg\": {\n fill: \"#323947 !important\"\n },\n },\n divTinyWarning: {\n \"& div.tox-tinymce\": {\n borderColor: \"#F15857 !important\"\n },\n },\n saveButtonContainer: {\n position: \"relative\",\n top: -40,\n right: 5,\n float: \"right\"\n },\n floatButton: {\n borderRadius: 51,\n textTransform: \"none\",\n boxShadow: \"none\",\n display: \"inline-block\",\n padding: \"0px 16px\",\n },\n floatButtonTxt: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n display: \"inline-block\",\n },\n\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\nimport { Editor } from '@tinymce/tinymce-react';\n\nimport { Button } from '@material-ui/core';\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { useTranslation } from \"react-i18next\";\nimport moment from 'moment';\n\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { CustomerApptsServicesHistory } from \"../../../models/customer-history\";\nimport { CrossIcon, SaveIcon } from \"../../../assets/icons\";\nimport { AppointmentService } from \"../../../api/appointment-service\";\nimport useStyles from \"./css\";\n\n import { CustomerHistoryDetailsProps } from \"./props\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n \nconst CustomerHistoryDetails = (props: CustomerHistoryDetailsProps) => {\n\n const { appointmentId, serviceHistory, serviceStatus, servicePaymentStatus, onChangedWithoutSave, onClose, onRefresh } = props;\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const [isDisabledBtnSave, setIsDisabledBtnSave] = useState(true);\n const [showBtnSave, setShowBtnSave] = useState(false);\n\n const [service, setService] = useState<CustomerApptsServicesHistory>(serviceHistory);\n const [editorTxt, setEditorTxt] = useState<string>(serviceHistory.notes);\n const [editorTxtLength, setEditorTxtLength] = useState<number>(0);\n const maxEditorText = 1954;\n const [warningSave, setWarningSave] = useState(false);\n const [editorTextDisabled, setEditorTextDisabled] = useState<boolean>(false);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n useEffect(() => {\n setService(serviceHistory);\n // setEditorTxtLength(serviceHistory.notes?.replace(/<[^>]*>/g, '').length ?? 0);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [serviceHistory]);\n \n \n const handleEditorChange = (content: any, editor: any) => {\n let editorLength = editor.getContent({ format: 'text' }).length;\n setEditorTxt(content);\n setWarningSave(false);\n setEditorTxtLength(editorLength);\n if(content !== \"\" && serviceHistory.notes !== content ) {\n setIsDisabledBtnSave(false);\n if (onChangedWithoutSave) onChangedWithoutSave(false);\n }\n else {\n setIsDisabledBtnSave(true);\n if (onChangedWithoutSave) onChangedWithoutSave(true);\n }\n\n };\n\n const handleSaveNotes = async () => {\n const result = await AppointmentService.updateNotes(serviceHistory.id, appointmentId, editorTxt);\n \n if (result && onRefresh) onRefresh(service);\n setIsDisabledBtnSave(true);\n setWarningSave(false);\n if (onChangedWithoutSave) onChangedWithoutSave(true);\n };\n\n const onFocus = () => {\n setShowBtnSave(true);\n };\n \n const onFocusOut = () => {\n\n if(serviceHistory.notes !== editorTxt && editorTxt !== \"\")\n setWarningSave(true);\n else\n setWarningSave(false);\n };\n\n \n useEffect(() => {\n\n setEditorTxt(serviceHistory.notes);\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [serviceHistory]);\n\n return (<div className={classes.customerHistoryDetailsPanel}>\n <div className={classes.closeDrawer} onClick={onClose} >\n <div className={classes.closeDrawerIcon}>\n <CrossIcon />\n </div>\n <div className={classes.closeDrawerText}>\n {t(\"Close window\")}\n </div>\n </div>\n\n <div className={classes.divGroup} >\n <div className={classes.title} >\n {t(\"Service & specialist\")}\n </div>\n <div className={classes.service} >\n {serviceHistory.name}\n </div>\n <div className={classes.specialist} >\n {serviceHistory.specialist}\n </div>\n </div>\n\n <div className={classes.divGroup} >\n <div className={classes.title} >\n {t(\"Date & Time\")}\n </div>\n <div className={classes.dateTimeInfo} >\n {\n new Date(serviceHistory.start).toLocaleDateString(\n localeApp,\n {\n month: \"long\",\n day: \"numeric\",\n })\n + \" \" + new Date(serviceHistory.start).getFullYear()\n }\n ·\n {moment(serviceHistory.start).format(\"HH:mm\") + \" - \" + moment(serviceHistory.end).format(\"HH:mm\")}\n </div>\n \n </div>\n\n <div className={classes.divGroup} >\n <div className={classes.title} >\n {t(\"Status\")}\n </div>\n <div className={classes.statusLabel} >\n {serviceStatus}\n {servicePaymentStatus}\n </div>\n </div>\n\n <div className={classes.divGroup} >\n <div className={classes.title} >\n {t(\"Notes after service\")}\n </div>\n <div className={`\n ${classes.divTiny} ${showBtnSave ? classes.divTinyFocus : \"\"} \n ${warningSave || editorTxtLength > maxEditorText ? classes.divTinyWarning : \"\"}` } >\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n initialValue={serviceHistory.notes}\n value={editorTxt ?? \"\"}\n onFocusIn={onFocus}\n onFocusOut={onFocusOut}\n onInit={(e: any, editor: any) => {\n const initialContentLength = editor.getContent({ format: 'text' }).length;\n setEditorTxtLength(initialContentLength);\n }}\n init={{\n placeholder: `${t(\"No notes\")}.`,\n height: 190,\n menubar: false,\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | bullist numlist',\n lists_indent_on_tab: false,\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n extended_valid_elements: \"b, i, s\",\n entity_encoding: \"raw\",\n invalid_elements: \"strong, em, span\",\n content_style: \"body {font-style: normal; font-weight: 400; font-size: 14px; color: #323947 }\"\n }}\n onEditorChange={handleEditorChange}\n outputFormat=\"html\"\n />\n <div className={classes.counter}>{`${editorTxtLength}/${maxEditorText}`}</div>\n </div>\n \n <div className={`${classes.divGroup} ${showBtnSave ? classes.divGroup : \"\"}`} >\n \n {showBtnSave && <>\n <div className={classes.saveButtonContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Gray1}\n innerText={t(\"Save\")}\n innerIcon={<SaveIcon\n style={{ width: 16, height: 16 }}\n viewBox=\"0 0 16 16\"\n />}\n onClick={handleSaveNotes}\n disabled={isDisabledBtnSave || editorTxtLength > maxEditorText}\n />\n </div>\n </>}\n </div>\n\n </div>\n </div>);\n};\n\nexport default CustomerHistoryDetails;\n","import React, { useState, useEffect } from \"react\";\nimport { Accordion, AccordionSummary, AccordionDetails, Grid, Drawer } from '@material-ui/core';\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { useTranslation } from \"react-i18next\";\nimport moment from 'moment';\n\nimport { ArrowDropDownIcon, CalendarIcon, CheckIcon, CrossIcon, MenuIconLogoClear, NoteIcon, NotesIcon, PersonIcon } from \"../../../assets/icons\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport CustomerHistoryEntity, { CustomerApptsServicesHistory } from \"../../../models/customer-history\";\nimport { AppointmentStatus } from \"../../../models/enums/appointment-status\";\nimport { AppointmentPaymentStatus } from \"../../../models/enums/appointment-payment-status\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\n\nimport { CustomerHistoryProps } from \"./props\";\nimport useStyles from \"./css\";\nimport CustomerHistoryDetails from \"../CustomerHistoryDetails\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport { selectAccountSettings, selectCommonHubConnection } from \"../../../redux/store\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\n\n\nconst CustomerHistory = (props: CustomerHistoryProps) => {\n\n const { customer } = props;\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const [appointmentsEntity, setAppointmentsEntity] = useState<CustomerHistoryEntity[]>([]);\n const [appointmentsTotal, setAppointmentsTotal] = useState<number>(0);\n const [drawerOpen, setDrawerOpen] = useState(false);\n const [service, setService] = useState<CustomerApptsServicesHistory>();\n const [serviceStatus, setServiceStatus] = useState<any>();\n const [servicePaymentStatus, setServicePaymentStatus] = useState<any>();\n const [appointmentId, setAppointmentId] = useState<any>();\n const [notesSaved, setNotesSaved] = useState<boolean>(true);\n\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const customerDidNotArriveTerminology = useCustomerTerminology(t(\"Customer did not arrive\"), \"Customer\");\n const customerArrivedTerminology = useCustomerTerminology(t(\"Customer arrived\"), \"Customer\");\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const hubConnection = useAppSelector(selectCommonHubConnection);\n const getTemplatedCurrencyValue = useCurrencyValueTemplate(accountSettings.currencyTemplate);\n\n useEffect(() => {\n\n getData();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n const getData = () => {\n (async () => {\n if (customer && customer.id) {\n dispatch(navbarActions.setShowLoader(true));\n const values = await CustomerService.getCustomerHistory(customer.id, localeApp);\n dispatch(navbarActions.setShowLoader(false));\n\n if (values) {\n setAppointmentsEntity(values.entity!);\n setAppointmentsTotal(values.total!);\n }\n\n }\n })();\n }\n \n // unsubscribe\n hubConnection?.off(\"changeAppointmentsListPaymentStatus\");\n // subscribe\n hubConnection?.on(\"changeAppointmentsListPaymentStatus\", (appointmentIds, status) => {updateAppointmentsPaymentStatus(appointmentIds, status)});\n\n const toggleDrawer = (s: CustomerApptsServicesHistory, apptId: string, divStatus: any, divPaymentStatus: any) => {\n setDrawerOpen(!drawerOpen);\n\n if (s)\n setService(s);\n\n if (divStatus)\n setServiceStatus(divStatus);\n\n if (divPaymentStatus)\n setServicePaymentStatus(divPaymentStatus)\n\n if (apptId)\n setAppointmentId(apptId);\n };\n\n const refreshClose = (s: CustomerApptsServicesHistory) => {\n // setDrawerOpen(false);\n getData();\n\n if (s) setService(s);\n }\n\n const changedNotesWithoutSave = (saved: boolean) => {\n setNotesSaved(saved);\n }\n\n const DivStatus = (status: AppointmentStatus | number) => {\n if (status == AppointmentStatus.Arrived) {\n return (<div className={`${classes.divStatus} ${classes.statusArrived}`}>\n <CheckIcon style={{ color: \"#36CE91\", width: 14, height: 10, marginRight: 3 }} />\n {customerArrivedTerminology}\n </div>)\n }\n else if (status == AppointmentStatus.Confirmed) {\n return (<div className={`${classes.divStatus} ${classes.statusConfirmed}`}>\n <MenuIconLogoClear viewBox=\"0 0 16 16\" style={{ color: \"#0BCBE0\", width: 16, height: 10, marginRight: 5, marginLeft: -4 }} />\n {t(\"Confirmed\")}\n </div>)\n }\n else if (status == AppointmentStatus.NotArrived) {\n return (<span className={`${classes.divStatus} ${classes.statusNotArrived}`}>\n <PersonIcon style={{ color: \"#F15857\", width: 10, height: 10, marginRight: 5 }} />\n {customerDidNotArriveTerminology}\n </span>);\n }\n else if (status == AppointmentStatus.NotConfirmed) {\n return (<div className={`${classes.divStatus} ${classes.statusNotConfirmed}`}>\n <CrossIcon viewBox=\"0 0 16 16\" style={{ color: \"#F15857\", width: 10, height: 10, marginRight: 5 }} />\n {t(\"Not Confirmed\")}\n </div>);\n } else {\n return <div></div>\n }\n };\n \n function updateAppointmentsPaymentStatus(appointmentIds: string[], paymentStatus: AppointmentPaymentStatus) {\n setAppointmentsEntity(prevAppointmentsEntity => {\n return prevAppointmentsEntity.map(monthData => {\n const updatedAppointments = monthData.appointments.map(appointment => {\n if (appointmentIds.includes(appointment.id)) {\n return { ...appointment, paymentStatus: paymentStatus, };\n }\n return appointment;\n });\n return { ...monthData, appointments: updatedAppointments, };\n });\n });\n }\n\n const DivPaymentStatus = (status: AppointmentPaymentStatus | number) => {\n if (status === AppointmentPaymentStatus.Paid) {\n return (<div className={`${classes.divStatus} ${classes.statusPaid}`}>\n {t(\"Paid\")}\n </div>)\n }\n else if (status === AppointmentPaymentStatus.Unpaid || status === AppointmentPaymentStatus.PaidPartially) {\n return (<span className={`${classes.divStatus} ${classes.statusUnpaid}`}>\n {t(\"Unpaid\")}\n </span>);\n } else {\n return <div></div>\n }\n };\n\n const DivNotes = (service: CustomerApptsServicesHistory | null, apptId: string, divStatus: any, divPaymentStatus: any) => {\n if (service?.notes) {\n return (<div className={`${classes.divNotes} ${classes.divNotesExists}`} onClick={() => toggleDrawer(service, apptId, divStatus, divPaymentStatus)} >\n <NoteIcon style={{ color: \"#6462F3\", width: 14, height: 10, marginRight: 0 }} color={\"#6462F3\"} />\n </div>)\n } else {\n return (<div className={`${classes.divNotes} ${classes.divNotesNone}`} onClick={() => toggleDrawer(service!, apptId, divStatus, divPaymentStatus)}>\n <NoteIcon style={{ color: \"#919CA5\", width: 14, height: 10, marginRight: 0 }} />\n </div>)\n }\n };\n\n return (<div className={classes.customerHistoryPanelContent}>\n\n <div className={classes.customerHistoryTitle}>\n <CalendarIcon style={{ color: \"#919CA5\" }} />\n <Typography className={classes.iconTitle}>\n {t(\"Appointments\")} ({appointmentsTotal})\n </Typography>\n </div>\n\n <div className={classes.customerHistoryContent}>\n {\n appointmentsEntity.map((history, indexHistory) =>\n (<Accordion key={indexHistory} defaultExpanded={true} className={classes.accordion} >\n\n <AccordionSummary\n className={classes.accordionSummary}\n classes={{\n expandIcon: classes.expandIcon,\n expanded: classes.expanded\n }} >\n <div className={classes.monthYear} >\n <b>{history.monthYear}</b>\n {\" (\" + history.appointments.length + \")\"}\n <ArrowDropDownIcon className={classes.ArrowIcon} style={{ width: 15, height: 15 }} />\n </div>\n </AccordionSummary>\n\n <AccordionDetails className={classes.accordionDetails} >\n\n <div className={classes.appointmentsGrid}>\n {\n history.appointments.map((appointments, indexAppointments) =>\n (<div key={appointments.id} className={classes.appointmentsBox}>\n\n <Grid container spacing={2} className={classes.appointmentsGrid}>\n <Grid item xs={3}>\n <Typography className={classes.headerAppointments}>\n {t(\"Service & specialist\")}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n <Typography className={classes.headerAppointments}>\n {t(\"Date & Time\")}\n </Typography>\n </Grid>\n <Grid item xs={2}>\n <Typography className={classes.headerAppointments}>\n {t(\"Price\")}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n <Typography className={classes.headerAppointments}>\n {t(\"Status\")}\n </Typography>\n </Grid>\n <Grid item xs={1}>\n <Typography className={classes.headerAppointments}>\n {t(\"NotesDetails\")}\n </Typography>\n </Grid>\n\n </Grid>\n\n {\n appointments.services.map((service, indexService) =>\n (<div key={indexService}>\n <Grid\n key={indexService}\n container\n spacing={2}\n className={`${classes.appointmentsGrid} ${appointments.status === AppointmentStatus.NotArrived ? classes.apptDisabledGrid : \"\"}`}\n >\n <Grid item xs={3}>\n <Typography className={classes.serviceName}>\n <b>{service.name}</b>\n </Typography>\n <Typography className={classes.serviceName}>\n {service.specialist}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n <Typography className={classes.serviceDate}>\n {\n new Date(service.start).toLocaleDateString(\n localeApp,\n {\n month: \"long\",\n day: \"numeric\",\n })\n + \" \" + new Date(service.start).getFullYear()\n }\n <br />\n {moment(service.start).format(\"HH:mm\") + \" - \" + moment(service.end).format(\"HH:mm\")}\n </Typography>\n </Grid>\n <Grid item xs={2}>\n <Typography className={classes.servicePrice}>\n {service.price ? getTemplatedCurrencyValue(service.price) : \"--\"}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n {DivStatus(appointments.status)}\n {DivPaymentStatus(appointments.paymentStatus)}\n </Grid>\n <Grid item xs={1}>\n {DivNotes(service, appointments.id, DivStatus(appointments.status), DivPaymentStatus(appointments.paymentStatus))}\n </Grid>\n </Grid>\n {\n (indexService !== appointments.services.length - 1) && <div className={classes.appointmentsGridLine}></div>\n }\n\n </div>))\n }\n \n {appointments?.recurringAppointmentOrder &&\n <div className={classes.recurringAppointment}>\n {`${t(\"Recurring appointment\")} (${appointments?.recurringAppointmentOrder}/${appointments?.recurringAppointmentCount})`} </div>\n }\n </div>))\n }\n\n </div>\n\n </AccordionDetails>\n\n </Accordion>)\n )\n }\n </div>\n\n {service && <>\n <Drawer\n open={drawerOpen}\n anchor=\"right\"\n classes={{ paper: classes.drawerHistoryDetails }}\n onClose={() => { if (notesSaved) setDrawerOpen(false) }}\n >\n\n <CustomerHistoryDetails\n serviceHistory={service}\n appointmentId={appointmentId}\n serviceStatus={serviceStatus}\n servicePaymentStatus={servicePaymentStatus}\n onChangedWithoutSave={changedNotesWithoutSave}\n onClose={() => setDrawerOpen(false)}\n onRefresh={refreshClose} />\n\n </Drawer>\n </>}\n\n </div>);\n};\n\nexport default CustomerHistory;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: { display: \"flex\" },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n customerInfoPanel: {\n height: 560,\n position: \"absolute\",\n width: 779,\n overflow: \"hidden\",\n },\n customerInfoPanelContent: {\n overflowY: \"scroll\",\n height: 560,\n padding: \"28px 28px 0px 28px\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n customerDetails: {\n width: 779,\n margin: \"0px 0px 0px 36px\",\n },\n customerDetailsContent: {\n width: 779,\n height: \"calc(100vh - 101px)\",\n borderRadius: 12,\n border: \"1px solid #DBDCDD\",\n backgroundColor: \"#FFF\",\n boxShadow: \"none\",\n position: \"relative\"\n },\n customerInfoTitle: {\n display: \"flex\",\n alignItems: \"center\",\n },\n customerInfoContent: {\n margin: \"20px 0px 0px 0px\",\n },\n infoContentRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n contactRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n marginTop: 10\n },\n iconTitle: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n margin: \"0px 0px 0px 10px\",\n },\n caption: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n width: 228,\n margin: \"0px\",\n },\n captionValue: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n width: 228,\n margin: \"0px\",\n },\n captionValueTextArea: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n minWidth: 228,\n margin: \"0px\",\n },\n detailsActions: {\n position: \"absolute\",\n bottom: theme.spacing(4),\n right: theme.spacing(2),\n zIndex: 1002\n },\n floatButton: {\n borderRadius: 51,\n textTransform: \"none\",\n boxShadow: \"none\",\n display: \"inline-block\",\n padding: \"0px 16px\",\n },\n floatButtonTxt: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n display: \"inline-block\",\n },\n editButton: {\n height: 32,\n background: \"#F6F6F6\",\n color: \"#6462F3\",\n \"&:hover\": {\n background: \"#6462F3\",\n color: \"#F6F6F6\",\n },\n },\n saveButton: {\n height: 32,\n background: \"#F6F6F6\",\n color: \"#36CE91\",\n \"&:hover\": {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n },\n },\n cancelButton: {\n marginRight: 24,\n height: 32,\n background: \"#F6F6F6\",\n color: \"#5C6477\",\n \"&:hover\": {\n background: \"#5C6477\",\n color: \"#F6F6F6\",\n },\n },\n lastRow: {\n marginBottom: 98,\n },\n addContactButton: {\n width: 137,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n border: \"1px solid #6462F3\",\n marginRight: 25,\n color: \"#6462F3\",\n textTransform: \"none\",\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n minHeight: 288,\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n margin: \"24px 0px 8px 0px\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteContact: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n divFlag: {\n display: \"inline-block\",\n position: \"relative\",\n height: 20,\n width: 20,\n \"& svg\": {\n width: \"20px !important\", \n height: \"20px !important\"\n }\n },\n divCode: {\n position: \"relative\",\n display: \"inline-block\",\n fontStyle: \"normal\",\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"normal\",\n width: 40,\n textAlign: \"center\",\n fontSize: 14\n },\n divMobile: {\n display: \"inline-block\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 14,\n }\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n \"& .MuiAccordion-root:before\": {\n backgroundColor: \"unset\"\n },\n \"& .MuiAccordionSummary-root\": {\n padding: \"10px 19px 10px 15px\",\n background: \"#FAFAFA\",\n minHeight: \"unset\",\n height: 46,\n },\n \"& .MuiAccordionSummary-root.Mui-expanded\": {\n minHeight: 0,\n margin: \"unset\"\n },\n \"& .MuiAccordionSummary-content\": {\n margin: 0,\n },\n \"& .MuiAccordion-root.Mui-expanded\": {\n margin: \"unset\"\n },\n overflowY: \"scroll\",\n minHeight: 560,\n maxHeight: \"calc(100vh - 152px)\",\n borderRadius: 12,\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n addButton: {\n width: 140,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n alignItems: \"center\",\n justifyContent: \"space-around\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n position: \"relative\",\n top: 25,\n left: 600,\n \"&.Mui-disabled\": {\n color: \"#F6F6F6\",\n opacity: 0.3,\n },\n },\n addTreatmentButton: {\n alignSelf: \"center\",\n\n width: 20,\n height: 32,\n borderRadius: 51,\n padding: \"11px 0\",\n \"&:hover\": {\n background: \"none\",\n },\n alignItems: \"center\",\n justifyContent: \"space-around\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n \"&.Mui-disabled\": {\n color: \"#F6F6F6\",\n opacity: 0.5,\n },\n },\n saveButton: {\n display: \"flex\",\n justifyContent: \"center\",\n\n ...theme.typography.buttons,\n color: theme.colors.clearGreen,\n width: \"auto\",\n height: 32,\n fontWeight: 700,\n borderRadius: 51,\n padding: \"11px 16px\",\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearGreen,\n\n \"&.Mui-disabled\": {\n color: theme.colors.clearGreen,\n opacity: 0.3,\n },\n },\n editButton: {\n alignItems: \"center\",\n justifyContent: \"space-around\",\n color: theme.colors.clearMain,\n width: \"auto\",\n height: 32,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n borderRadius: 51,\n padding: \"11px 16px\",\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n \"&.Mui-disabled\": {\n color: theme.colors.clearMain,\n opacity: 0.3,\n },\n },\n cancelButton: {\n display: \"flex\",\n justifyContent: \"center\",\n\n ...theme.typography.buttons,\n color: theme.colors.grey4,\n width: \"auto\",\n height: 32,\n borderRadius: 51,\n fontWeight: 700,\n padding: \"11px 16px\",\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.grey4,\n marginRight: 15,\n \"&.Mui-disabled\": {\n color: theme.colors.grey4,\n },\n },\n iconPlus: {\n height: 25,\n textAlign: \"center\",\n color: \"#FAFAFA\"\n },\n uploadFileCloud: {\n height: 25,\n textAlign: \"center\",\n color: \"#FAFAFA\",\n position: \"relative\",\n left: 115\n },\n iconRemove: {\n height: 25,\n textAlign: \"center\",\n color: \"#F15857\",\n paddingTop: 1\n },\n iconDiary: {\n position: \"relative\",\n top: 76,\n left: 210,\n },\n diaryCaption: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#6462F3\",\n marginTop: 34,\n marginLeft: 15,\n },\n customerHistoryContent: {\n margin: \"48px 0px 0px 0px\",\n },\n accordion: {\n border: \"none\",\n boxShadow: \"none\"\n },\n accordionDetails: {\n padding: 0\n },\n expandIcon: {\n flexDirection: 'row-reverse',\n display: \"none\"\n },\n expanded: {\n \"& * svg\": {\n flexDirection: 'row-reverse',\n transform: 'rotate(180deg)',\n\n }\n },\n monthYear: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n lineHight: 17,\n color: Color.clear1\n },\n notesCountInMonth: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n lineHight: 17,\n color: Color.clear1\n },\n evolutionNoteForm: {\n width: \"100%\",\n },\n evolutionNoteBox: {\n borderBottom: \"1px solid #C9CDD3\",\n background: \"#FFFFFF\",\n width: \"100%\", //680,\n marginBottom: 20,\n padding: \"15px 15px 25px 15px\"\n },\n counterWrapper: {\n display: \"flex\",\n justifyContent: \"flex-end\"\n },\n charCounter: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n position: \"absolute\",\n paddingLeft: \"10px\",\n marginTop: \"-23px\",\n right: 24,\n color: theme.colors.grey5\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n removeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n marginTop: 7\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n closeModalContentText2: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n },\n closeModalContentHeaderText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n editModeSeparator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"22px 16px 24px 16px\",\n width: \"auto\"\n },\n longSeparator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"25px 0px 16px 0px\",\n width: \"100%\"\n },\n closeConfirmationModal: {\n minHeight: \"240px !important\",\n height: \"auto !important\",\n },\n cancelEvolutionNoteConfirmationModal: {\n height: \"200px !important\"\n },\n tinyMceOverrides: {\n marginBottom: 26,\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n \"& div.tox-edit-area\": {\n marginBottom: \"22px\"\n },\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n tinyMceValidationError: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#FF0000 !important\"\n }\n },\n accordionHeader: {\n display: \"flex\",\n justifyContent: \"space-between\",\n marginBottom: 10\n },\n buttonArea: {\n display: \"flex\",\n width: \"22%\",\n justifyContent: \"space-between\"\n\n },\n editEvolutionHeader: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n color: Color.gray5\n },\n editModeTitle: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n color: Color.gray5,\n marginBottom: 4\n },\n editModeSimpleText: {\n ...theme.typography.txtBody1,\n fontWeight: 400,\n color: Color.gray5\n },\n editModeBoldText: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: Color.gray5\n },\n editModeTreatmentList: {\n paddingLeft: 20,\n },\n editorFieldHeader: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 700,\n\n marginBottom: 18,\n },\n treatmentFieldHeader: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 700,\n\n marginBottom: 9,\n },\n treatmentRow: {\n display: \"flex\",\n gap: 15,\n },\n treatmentInputContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n\n width: \"42%\",\n },\n pdfButtonsBlock: {\n display: \"flex\",\n gap: 16,\n\n marginTop: -10,\n marginBottom: 24,\n },\n pdfButton: {\n height: 32,\n\n padding: \"11px 16px\",\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n borderRadius: 5,\n\n ...theme.typography.buttons,\n color: theme.colors.clearMain,\n fontWeight: 700,\n },\n fileHeader: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n marginBottom: 16,\n marginTop: 24,\n color: Color.gray5\n },\n treatmentNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n marginBottom: 23,\n marginRight: 15,\n color: Color.gray5 + \" !important\"\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey6,\n \"& ::placeholder\": {\n fontWeight: \"normal\" ,\n fontSize: 12,\n color: theme.colors.grey5,\n opacity: 0.8 \n },\n },\n carryOutTitle: {\n borderRadius: \"5px !important\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n marginTop: -12,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n marginBottom: 15,\n color: Color.gray4 + \" !important\"\n },\n dropZone: {\n height: \"136px\",\n width: \"97%\",\n background: \"rgba(100, 98, 243, 0.1)\",\n border: \"0px dashed\",\n borderRadius: \"15px\",\n borderColor: theme.colors.clearMain,\n minHeight: \"100px\",\n backgroundImage: `url(\"data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='15' ry='15' stroke='%236462F3FF' stroke-width='2' stroke-dasharray='12%2c 12' stroke-dashoffset='0' stroke-linecap='round'/%3e%3c/svg%3e\")`,\n animation: 'none !important',\n\n color: theme.colors.clearMain,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n // position: \"relative\",\n // top: \"70px\",\n },\n editModeNoteHeaderContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n padding: \"0px 16px\",\n marginTop: 22,\n \"&>*:last-child\":{\n marginLeft: 20\n }\n },\n editModeNoteHeaderContainerChild: {\n display: \"flex\",\n flexGrow: 1,\n justifyContent: \"space-between\"\n },\n editModeNoteFieldSmall: {\n color: theme.colors.grey4,\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12\n },\n editModeNoteFieldBlue: {\n color: theme.colors.clearMain,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14\n },\n fieldEditionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n gap: 2,\n marginBottom: 24\n },\n fieldNameLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4\n },\n fieldValueLabel: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n overflowWrap: 'break-word'\n },\n phoneNumberCodeLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.clear2\n },\n phoneNumberContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 4,\n \"& svg\": {\n width: \"20px !important\",\n height: \"20px !important\"\n }\n },\n fieldContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n marginTop: 16,\n minWidth: \"33%\",\n maxWidth: \"33%\",\n gap: 2\n },\n fieldsContainer: {\n display: \"flex\",\n flexWrap: \"wrap\"\n },\n fieldNameAsterisk: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.clear1\n },\n editorContent: {\n \"& p\": {\n display: \"inline\"\n },\n },\n fileNameContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\"\n },\n actionsContainer: {\n display: \"flex\",\n alignItems: \"center\"\n },\n grid: {\n marginTop: 25,\n width: \"97.5%\",\n \"& .MuiPagination-root\": {\n marginTop: 30\n },\n \"& td\": {\n padding: \"7px 0px 7px 12px\"\n },\n },\n classRow: {\n // cursor: \"pointer\",\n \"& div.buttonRow\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n \"& div.buttonRow\": {\n visibility: \"visible\"\n }\n }\n },\n gridShowMode: {\n marginTop: 16,\n width: \"95%\",\n marginRight: \"auto\",\n marginLeft: \"auto\",\n \"& .MuiPagination-root\": {\n marginTop: 30\n },\n \"& td\": {\n padding: \"7px 0px 7px 12px\"\n },\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst DiaryIcon = () => (\n <SvgIcon style={{ width: 266, height: 191 }}\n viewBox={ \"0 0 266 191\"}>\n <path\n d=\"M 65.6182 177.423 C 65.6182 177.423 76.259 186.63 78 186.5 C 79.1836 186.434 184.327 190.828 185.5 191 L 70.1187 175.861 L 65.6182 177.423 Z\"\n fill=\"#6462F3\"\n />\n <path\n d=\"M 0.782343 55.4022 C -4.30393 95.4126 16.2201 136.431 48.6458 160.419 C 81.0716 184.408 123.742 192.326 163.668 186.578 C 192.171 182.494 220.44 171.319 240.529 150.694 C 260.618 130.068 271.208 99.0798 263.116 71.4481 C 260.057 61.0132 254.053 50.9002 244.524 45.6589 C 229.307 37.311 210.536 43.4288 194.329 49.7017 C 178.122 55.9746 159.381 62.1521 144.128 53.8757 C 132.411 47.5014 126.389 34.3773 117.803 24.169 C 103.2 6.81121 79.4736 -2.4073 56.9818 0.544297 C 54.1657 0.91488 51.377 1.47063 48.6339 2.20792 C 24.7051 8.62987 6.61398 28.2893 1.39055 52.5102 L 0.782343 55.4022 Z\"\n fill=\"#E1E9FE\"\n />\n <path\n opacity={0.6}\n d=\"M 185.251 190.924 L 78.3671 186.281 C 78.0422 186.268 77.7231 186.19 77.4282 186.053 C 77.1333 185.916 76.8684 185.722 76.6487 185.482 C 76.429 185.242 76.2588 184.962 76.148 184.656 C 76.0371 184.35 75.9877 184.026 76.0026 183.701 C 77.8053 124.829 80.7254 54.9563 82.4108 34.2994 C 82.4553 33.6552 82.7503 33.054 83.2327 32.6247 C 83.715 32.1955 84.3464 31.9722 84.9914 32.0028 L 191.949 36.6453 C 192.278 36.6579 192.601 36.736 192.899 36.8751 C 193.197 37.0142 193.464 37.2114 193.685 37.4553 C 193.906 37.6991 194.076 37.9847 194.185 38.2951 C 194.294 38.6055 194.34 38.9346 194.32 39.2629 L 187.838 188.516 C 187.812 189.178 187.525 189.802 187.041 190.253 C 186.556 190.705 185.913 190.946 185.251 190.924 Z\"\n fill=\"#6462F3\"\n />\n <path\n d=\"M 184.287 188.641 L 77.5333 184.788 L 69.1187 178.343 L 74.1872 25.4351 L 184.769 32.973 L 190.233 39.0973 L 184.287 188.641 Z\"\n fill=\"#FFFFFF\"\n />\n <path\n d=\"M 184.5 188.5 L 174 179.352 L 182.618 31 L 190.5 39 L 184.5 188.5 Z\"\n fill=\"#E0E0E0\"\n />\n <path\n d=\"M 175.743 182.973 L 67.4085 178.269 C 66.7502 178.243 66.1285 177.959 65.6779 177.478 C 65.2273 176.998 64.9841 176.359 65.0008 175.701 C 66.7912 116.823 69.7113 46.9561 71.409 26.2992 C 71.4627 25.6529 71.7647 25.0526 72.2517 24.6243 C 72.7386 24.1961 73.3726 23.9732 74.0205 24.0026 L 182.435 28.7069 C 183.1 28.7373 183.726 29.0297 184.176 29.5202 C 184.626 30.0107 184.864 30.6594 184.837 31.3245 L 178.361 180.578 C 178.33 181.242 178.038 181.867 177.547 182.316 C 177.056 182.765 176.408 183.002 175.743 182.973 Z\"\n fill=\"#9FA9E6\"\n />\n <path\n opacity={0.6}\n d=\"M 71.6316 67.447 L 69.0776 67.3359 L 65.9916 138.302 L 68.5455 138.413 C 70.7526 138.509 72.6196 136.798 72.7155 134.591 L 75.454 71.617 C 75.55 69.4099 73.8386 67.543 71.6316 67.447 Z\"\n fill=\"#6462F3\"\n />\n <circle xmlns=\"http://www.w3.org/2000/svg\" cx=\"94.9628\" cy=\"95.9628\" r=\"5.96281\" fill=\"#323947\"/>\n <circle xmlns=\"http://www.w3.org/2000/svg\" cx=\"158.963\" cy=\"99.9628\" r=\"5.96281\" fill=\"#323947\"/>\n <path\n fillRule= \"evenodd\"\n clipRule= \"evenodd\"\n d=\"M 137.399 111.379 C 137.273 111.486 137.084 111.469 136.976 111.345 C 130.955 104.46 120.549 103.582 113.46 109.362 C 113.333 109.466 113.144 109.451 113.037 109.325 V 109.325 C 112.931 109.2 112.948 109.011 113.075 108.907 C 120.416 102.914 131.198 103.823 137.431 110.96 C 137.54 111.084 137.524 111.273 137.399 111.379 V 111.379 Z\"\n stroke=\"#323947\"\n strokeWidth={3}\n />\n </SvgIcon>\n);\n\nexport default DiaryIcon;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 488,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n paddingBottom: \"12px\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n \n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n commentsLabel: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontSize: 14,\n fontWeight: 400\n },\n\n dropZone: {\n height: \"136px\",\n width: \"373px\",\n background: \"rgba(100, 98, 243, 0.1)\",\n border: \"0px dashed\",\n borderRadius: \"15px\",\n borderColor: theme.colors.clearMain,\n minHeight: \"100px\",\n backgroundImage: `url(\"data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='15' ry='15' stroke='%236462F3FF' stroke-width='2' stroke-dasharray='12%2c 12' stroke-dashoffset='0' stroke-linecap='round'/%3e%3c/svg%3e\")`,\n animation: 'none !important',\n },\n\n dropZoneText: {\n color: theme.colors.clearMain,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n position: \"relative\",\n top: \"70px\",\n },\n fileName: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n },\n fileSize: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n paddingTop: \"4px\",\n },\n fileSizeBold: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n },\n downloadTemplate: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n notesTitle: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n notes: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n divider: {\n borderTop: \"1px solid\",\n borderColor: theme.colors.grey2,\n marginTop: \"24px\",\n marginBottom: \"24px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n cancelModalButton: {\n width: 244,\n height: 39,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 14,\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n modalTitleTextCancel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 18,\n fontWeight: \"bold\"\n },\n goBackCancel: {\n marginRight: 38,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n link: {\n color: theme.colors.clearMain,\n cursor: \"pointer\"\n },\n label: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n marginTop: 32\n },\n inputClass: {\n ...theme.typography.body2,\n height: \"70px !important\",\n backgroundColor: \"inherit !important\",\n \n resize: \"none\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"normal\",\n opacity: 0.8,\n }\n }\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { DropzoneAreaBase, FileObject } from \"material-ui-dropzone\";\nimport useStyles from \"./css\";\nimport { PatientImportEvolutionNoteClinicalFileModalProps } from \"./props\";\nimport { Box, Grid } from \"@material-ui/core\";\nimport moment from \"moment\";\n\nimport { PDFIcon, UploadFileCloud, WordIcon, ImageIcon, } from \"../../../assets/icons\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport TextareaWithLabel from \"../../common/TextareaWithLabel\";\nimport { EvolutionNoteClinicalFile } from \"../../../models/evolution-notes-grouped\";\nimport { ApiClient } from \"../../../api/api-client\";\nimport ConfirmActionModal from \"../../common/ConfirmActionModal\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\nconst PatientImportEvolutionNoteClinicalFileModal = (props: PatientImportEvolutionNoteClinicalFileModalProps) => {\n const { t } = useTranslation([\"general\"]);\n const { open, onClose, evolutionNote } = props;\n const classes = useStyles();\n const accountSettings = useAppSelector(selectAccountSettings)\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [openCancelModal, setOpenCancelModal] = useState<boolean>(false);\n const [cancelModalShouldAppear, setCancelModalShouldAppear] = useState<boolean>(false);\n const username = ApiClient.getUserInfo().fullName;\n const [file, setFile] = useState<FileObject[]>([]);\n const [fileSize, setFileSize] = useState<number>(0);\n const [fileName, setFileName] = useState<string>(t(\"No file attached.\"));\n const [fileComment, setFileComment] = useState<string>(\"\");\n const [fileExtension, setFileExtension] = useState<string>(\"pdf\");\n const [isValid, setIsValid] = useState<boolean>(false);\n const maxFileSize: number = 1 * 1024 * 10240;\n \n const { enqueueAlert } = alertsActions;\n const dispatch = useAppDispatch();\n \n useEffect(() => {\n setOpenModal(open);\n if (open === true) {\n cleanupModal();\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n \n const handleTryCloseModal = () => {\n if (cancelModalShouldAppear) {\n setOpenCancelModal(true);\n } else {\n handleCloseModal();\n }\n };\n \n const handleCloseModal = () => {\n setOpenModal(false);\n if (onClose) {\n setFileExtension(\"pdf\");\n onClose();\n }\n };\n \n const handleOnUploadClick = async () => {\n handleCloseModal();\n if (isValid) {\n setIsValid(false);\n let fileExtension = file[0].file.name.split(\".\").pop();\n let fileType = \"multipart/form-data\";\n switch (fileExtension) {\n case \"pdf\":\n fileType = 'application/pdf';\n break;\n case \"docx\":\n fileType = 'application/vnd.openxmlformats-officedocument.wordprocessingml.document';\n break;\n case \"jpg\":\n fileType = 'image/jpg';\n break;\n case \"png\":\n fileType = 'image/png';\n break;\n }\n let url = window.URL.createObjectURL(new Blob([file[0].file], { type: fileType }));\n\n evolutionNote?.clinicalFiles.push(new EvolutionNoteClinicalFile({\n fileName: file[0].file.name,\n fileComment: fileComment,\n fileURL: url,\n fileBlob: new Blob([file[0].file], { type: fileType }),\n created: new Date(moment().utc().tz(accountSettings.accountIanaTimezone).format(\"YYYY-MM-DD HH:mm\")),\n uploadedBy: username,\n }));\n }\n };\n \n const handleOnAddFile = (files: FileObject[]) => {\n setFile(files);\n setFileName(files[0].file.name);\n let size = files[0].file.size / (1024 * 1024);\n setFileSize(Math.round((size + Number.EPSILON) * 100) / 100); // in megabytes\n setIsValid(validateFile(files[0].file));\n \n setCancelModalShouldAppear(true);\n };\n \n const handleDropRejected = (file: File[]) => {\n let fileExtension = file[0].name.split(\".\").pop();\n let allowedExtension = [\"png\", \"jpg\", \"docx\", \"pdf\"];\n\n if (allowedExtension.indexOf(fileExtension!) == -1) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Format not allowed\")\n })\n );\n return;\n } else {\n setFileExtension(fileExtension ?? 'pdf');\n }\n \n if (file[0].size > maxFileSize) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"The file exceeds the maximum size allowed\")\n })\n );\n }\n };\n \n const validateFile = (file: File) => {\n if (file.size > maxFileSize)\n //10 megabyte\n return false;\n let fileExtension = file.name.split(\".\").pop();\n let allowedExtension = [\"png\", \"jpg\", \"docx\", \"pdf\"];\n let isValid = allowedExtension.indexOf(fileExtension!) > -1;\n if (isValid) {\n setFileExtension(fileExtension ?? \"pdf\");\n }\n return (allowedExtension.indexOf(fileExtension!) > -1);\n };\n \n const cleanupModal = () => {\n setFile([]);\n setFileName(t(\"No file attached.\"));\n setFileSize(0);\n setFileComment(\"\");\n setIsValid(false);\n setCancelModalShouldAppear(false);\n setOpenCancelModal(false);\n };\n \n const handleInputChange = (e: any) => {\n const { name, value } = e.target;\n setFileComment(value);\n };\n \n const CancelNewEvolutionNoteModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.modalTitleTextCancel}>\n {t(\"Cancel file upload?\")}\n </Typography>\n </div>);\n };\n \n return (\n <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={handleTryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div>\n <div\n className={classes.paper}\n >\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {t(\"Upload files\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Cancel\")}\n onClick={handleTryCloseModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Upload file\")}\n onClick={handleOnUploadClick}\n disabled={!isValid}\n />\n </div>\n </div>\n <Box sx={{ width: \"100%\" }} pt={1}>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <DropzoneAreaBase\n dropzoneClass={classes.dropZone}\n dropzoneParagraphClass={classes.dropZoneText}\n fileObjects={file}\n dropzoneText={t(\n \"Drag or click here to upload your file\"\n )}\n onAdd={handleOnAddFile}\n showPreviewsInDropzone={false}\n showAlerts={false}\n filesLimit={1}\n acceptedFiles={[\n \"application/pdf,.docx,.jpg,.png\",\n ]}\n maxFileSize={maxFileSize}\n onDropRejected={handleDropRejected}\n // @ts-ignore: type negotiation problem\n Icon={UploadFileCloud} // works and builds but https://github.com/Yuvaleros/material-ui-dropzone/issues/246\n />\n </Grid>\n {fileExtension === \"pdf\" && <Grid item xs={1} style={{ paddingLeft: \"48px\", paddingTop: 25 }}>\n <PDFIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>}\n {fileExtension === \"docx\" && <Grid item xs={1} style={{ paddingLeft: \"38px\", paddingTop: 16 }}>\n <WordIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>}\n {(fileExtension === \"jpg\" || fileExtension === \"png\") && <Grid item xs={1} style={{ paddingLeft: \"38px\", paddingTop: 16 }}>\n <ImageIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>}\n <Grid\n item\n xs={5}\n style={{ paddingLeft: \"48px\", paddingTop: \"30px\", wordWrap: \"break-word\" }}\n >\n <Typography className={classes.fileName}>\n {fileName}\n </Typography>\n <Typography className={classes.fileSize}>\n {t(\"Size: \")}\n <b>{fileSize} MB</b>\n </Typography>\n </Grid>\n </Grid>\n \n <TextareaWithLabel\n name=\"comments\"\n value={fileComment}\n onChange={handleInputChange}\n width=\"100%\"\n inputClass={classes.inputClass}\n showCounter={true}\n label={() => (<>\n <Typography className={classes.commentsLabel}>\n {t(\"Comments\")}\n </Typography>\n </>)}\n labelClass={classes.label}\n placeholder={t(\"Write your comments here\")}\n maxLength={180}\n />\n \n <hr className={classes.divider}/>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <Typography className={classes.notesTitle}>\n {t(\"NOTES: \")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Accepted formats .jpg . png .docx .pdf\")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Maximum allowed file size: 10MB\")}\n </Typography>\n </Grid>\n <Grid\n item\n xs={6}\n container\n direction=\"row\"\n alignItems=\"center\"\n justifyContent=\"flex-end\"\n >\n </Grid>\n </Grid>\n </Box>\n </div>\n <div>\n <ConfirmActionModal\n onClose={() => setOpenCancelModal(false)}\n open={openCancelModal}\n onConfirm={handleCloseModal}\n content={<CancelNewEvolutionNoteModalContent/>}\n />\n </div>\n </div>\n </Fade>\n </Modal>\n </>\n );\n};\n\nexport default PatientImportEvolutionNoteClinicalFileModal;\n","import { makeStyles } from \"@material-ui/core\";\n\nconst useStyles = (height: number | undefined, width: number | undefined) =>\n makeStyles((theme) => ({\n container: {\n height: height || 605,\n width: width,\n // overflowY: \"scroll\",\n maxHeight: 460\n },\n tableContainer: {\n border: \"1px solid #DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: height || 605,\n maxHeight: 460,\n width: width,\n overflow: \"hidden\",\n },\n tableHeader: {\n backgroundColor: \"#F6F6F6\",\n },\n tableBody: {\n overflowY: \"scroll\",\n height: height || 605,\n maxHeight: 460,\n width: width,\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n rowText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n }));\n\nexport default useStyles;\n","import React from \"react\";\n\nimport Box from \"@material-ui/core/Box\";\nimport Paper from \"@material-ui/core/Paper\";\nimport Table from \"@material-ui/core/Table\";\nimport TableRow from \"@material-ui/core/TableRow\";\nimport TableBody from \"@material-ui/core/TableBody\";\nimport TableCell from \"@material-ui/core/TableCell\";\nimport Typography from \"@material-ui/core/Typography\";\nimport TableContainer from \"@material-ui/core/TableContainer\";\n\nimport EnhancedTableHead from \"./../EnhancedTableHead\";\nimport { TableColumn } from \"../table-column\";\n\nimport useStyles from \"./css\";\nimport { GridListWithoutPaginationProps } from \"./props\";\n\nconst GridListWithoutPagination = (props: GridListWithoutPaginationProps) => {\n const {\n columns,\n items,\n height,\n width,\n onRowClick,\n classRow\n } = props;\n \n const customClasses = useStyles(height, width)();\n \n const handleRequestSort = (event: any, property: string) => {\n };\n \n const handleRowClick = <T extends unknown>(item: T) => {\n if (onRowClick) {\n onRowClick(item);\n }\n };\n \n return (\n <Box>\n <div className={customClasses.container}>\n <TableContainer\n component={Paper}\n className={customClasses.tableContainer}\n >\n <div className={customClasses.tableBody}>\n <Table stickyHeader aria-label=\"sticky table\">\n <EnhancedTableHead\n columns={columns}\n order={\"asc\"}\n orderBy={\"\"}\n onRequestSort={handleRequestSort}\n />\n <TableBody>\n {items.map((item: any, index: number) => (\n <TableRow\n key={index}\n id={`$GridList-${index}`}\n className={classRow}\n onClick={() => handleRowClick(item)}\n hover\n >\n {columns.map((column: TableColumn, colIndex: number) => (\n (column.visible! ?? true) && <>\n <TableCell\n key={colIndex}\n className={`${customClasses.rowText} ${\n column.rowClassName || \"\"\n }`.trim()}\n style={{\n width: column.width,\n textAlign: column.textAlign\n ? column.textAlign\n : \"left\",\n ...column.rowStyle,\n }}\n >\n {!column.component ? (\n <Typography\n className={`${customClasses.rowText} ${\n column.rowClassName || \"\"\n }`.trim()}\n style={column.rowStyle}\n >\n {item[column.id]}\n </Typography>\n ) : (\n column.component(\n column.completeObject ? item : item[column.id]\n )\n )}\n </TableCell>\n </>\n ))}\n </TableRow>\n ))}\n </TableBody>\n </Table>\n </div>\n </TableContainer>\n </div>\n </Box>\n );\n};\n\nexport default GridListWithoutPagination;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = () =>\n makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n backgroundColor: theme.colors.white,\n position: \"relative\"\n },\n input: {\n backgroundColor: theme.colors.white,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: \"100%\"\n },\n inputWidth: {\n width: \"90%\"\n },\n counter: {\n position: \"absolute\",\n bottom: 7,\n right: 7,\n fontSize: 12,\n color: \"#B5B9C1\",\n padding: \"5px\",\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: theme.colors.grey5,\n opacity: 0.8\n },\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: \"100%\",\n },\n inputDisabled: {\n color: \"#676767\",\n },\n inputError: {\n color: theme.colors.clearRed,\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearRed\n },\n }));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n label: {\n ...theme.typography.buttons,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey5,\n marginBottom: 8\n },\n dot: {\n ...theme.typography.buttons,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n}));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { Typography } from \"@material-ui/core\";\n\nimport { UseControlLabelProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function useControlLabel(props: UseControlLabelProps) {\n \n const { label, required, labelClass } = props;\n \n const LabelComponent = label;\n \n const classes = useStyles();\n \n const LabelWithDot = () =>\n <div>\n <Typography className={labelClass ?? classes.label}>\n {typeof label === \"string\" ? label : <LabelComponent />}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n \n const LabelWithoutDot = () =>\n <div>\n <Typography className={labelClass ?? classes.label}>\n {typeof label === \"string\" ? label : <LabelComponent />}\n </Typography>\n </div>\n \n return required ? LabelWithDot : LabelWithoutDot;\n}","import React, { useState } from 'react';\n\n\nexport default function useInputFirstTouch() {\n \n const [hasBeenTouched, setHasBeenTouched] = useState<boolean>(false)\n \n function handleFirstTouch() {\n if (hasBeenTouched) return;\n setHasBeenTouched(true);\n }\n \n return { hasBeenTouched, handleFirstTouch }\n}","import React from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { InputBase } from \"@material-ui/core\";\n\nimport { PatientFormTextInputProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport useControlLabel from \"../../../hooks/useControlLabel\";\nimport useInputFirstTouch from \"../../../hooks/useInputFirstTouch\";\n\n\nexport default function PatientFormTextInput(props: PatientFormTextInputProps) {\n \n const { value, setValue, label, required, placeholder, isValid, disabled, inputStyle, maxLength, key } = props;\n \n const classes = useStyles()();\n \n const { t } = useTranslation(\"general\");\n \n function handleOnChange(event: any) {\n setValue(event.target.value);\n }\n \n function isError(): boolean {\n if (!isValid || isValid(value) === undefined) {\n return false;\n }\n return !isValid(value);\n }\n \n const ControlLabel = useControlLabel({ label, required });\n const { hasBeenTouched, handleFirstTouch } = useInputFirstTouch();\n \n return (\n <div className={classes.root}>\n {!!label &&\n <ControlLabel/>\n }\n <InputBase\n key={key}\n className={`${classes.input} ${inputStyle} ${hasBeenTouched && isError() ? classes.inputError : \"\"}`}\n placeholder={`${t(\"Write here your answer for\")} ${placeholder}`}\n value={value}\n onChange={handleOnChange}\n onBlur={handleFirstTouch}\n disabled={disabled}\n inputProps={{\n className: classes.inputWidth,\n maxLength: maxLength\n }}\n />\n <div className={classes.counter}>{`${value?.length}/${maxLength}`}</div>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = () => makeStyles((theme) => ({\n root: {\n zIndex: 2,\n position: \"relative\",\n left: 0,\n backgroundColor: theme.colors.white\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n searchInputContainer: {\n position: \"relative\",\n padding: \"0 15px 10px 15px\",\n width: \"-webkit-fill-available\"\n },\n searchIconContainer: {\n position: \"absolute\",\n top: 7,\n right: 21\n },\n divDropdown: {\n width: \"100%\",\n display: \"block\",\n marginTop: -7,\n height: 70,\n position: \"relative\"\n },\n inputSelectBtn: {\n width: 300,\n paddingLeft: 100,\n \"& input\": {\n marginLeft: 100,\n width: 140,\n }\n },\n titleCountries: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n textAlign: \"left\",\n margin: \"15px auto 10px 15px\",\n },\n divDialCode: {\n position: \"relative\",\n top: -1,\n left: 18,\n display: \"inline\",\n fontSize: 12,\n fontStyle: \"normal\",\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n iconDropdown: {\n cursor: \"pointer\",\n display: \"inline\",\n textAlign: \"left\",\n position: \"relative\",\n top: -1,\n left: 15,\n \"& svg\": {\n width: 24,\n height: 24,\n }\n },\n inputFlag: {\n display: \"inline\",\n position: \"relative\",\n top: -2,\n left: 12,\n height: 20,\n width: 20,\n \"& svg\": {\n width: \"20px !important\",\n height: \"20px !important\"\n }\n },\n divCodes: {\n cursor: \"pointer\",\n position: \"relative\",\n top: -30,\n left: 0,\n width: 90,\n },\n divModalSelect: {\n backgroundColor: theme.colors.white,\n \n position: \"absolute\",\n top: 0,\n \n width: 288,\n maxHeight: 382,\n padding: 0,\n \n border: \"solid\",\n borderWidth: 1,\n borderColor: \"#DBDCDD\",\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n \n textAlign: \"center\",\n },\n listCountryScroll: {\n maxHeight: 290,\n \n overflowY: \"scroll\",\n \"&::-webkit-scrollbar\": {\n backgroundColor: theme.colors.white,\n width: 16,\n },\n \"&::-webkit-scrollbar-track\": {\n backgroundColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-track:hover\": {\n backgroundColor: \"#F4F4F4\",\n width: 16,\n },\n \"&::-webkit-scrollbar-thumb\": {\n backgroundColor: \"#babac0\",\n \n border: \"solid\",\n borderRadius: 16,\n borderWidth: 5,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-thumb:hover\": {\n backgroundColor: \"#a0a0a5\",\n \n border: \"solid\",\n borderWidth: 4,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-button\": {\n display: \"none\",\n },\n },\n listCountry: {\n padding: \"5px 0\",\n \"&:first-child\": {\n paddingTop: 10,\n },\n borderBottom: \"1px solid #F6F6F6\",\n marginBottom: 0,\n },\n countryName: {\n textAlign: \"left\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\",\n width: \"75%\",\n overflow: \"hidden\",\n display: \"inline-block\",\n paddingTop: \"1px\",\n height: 40\n },\n countryIcon: {\n marginRight: 10,\n },\n button: {\n width: 300,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#786EFF\",\n border: \"1px solid #786EFF\",\n \n },\n elementList: {\n height: 35,\n padding: \"5px 5px 10px 10px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n display: \"flex\",\n color: theme.colors.grey5\n },\n divInputEdit: {\n margin: \"auto\",\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n input: {\n marginLeft: \"auto\",\n \"& input\": {\n width: 250,\n }\n },\n inputClassic: {\n marginLeft: 85,\n border: \"none\",\n width: \"55%\",\n height: 38,\n backgroundColor: theme.colors.white,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n opacity: \"0.42\",\n },\n padding: \"13px 0px 13px 12px\",\n borderRadius: 5,\n \"&:focus\": {\n border: \"none\",\n padding: \"14px 0px 14px 12px\",\n \"&$inputError\": {\n color: theme.colors.clearRed,\n border: \"none\",\n },\n },\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"none\",\n padding: \"14px 0px 14px 12px\",\n \"&$inputError\": {\n color: theme.colors.clearRed,\n border: \"none\",\n },\n },\n },\n iconPlus: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n inputError: {\n color: `${theme.colors.clearRed} !important`,\n border: `solid 1px ${theme.colors.clearRed} !important`,\n \"& input\": {\n color: `${theme.colors.clearRed} !important`,\n },\n },\n iconSave: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n divItemEdit: {\n height: 32,\n display: \"block\"\n },\n btnInputNew: {\n height: 32,\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n classRow: {\n cursor: \"pointer\",\n \"& button\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n backgroundColor: \"#e1e9fe\",\n \"& button\": {\n visibility: \"visible\"\n }\n }\n },\n btnRow: {\n width: 32,\n height: 32,\n borderRadius: 51,\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\",\n border: \"none\",\n padding: 0,\n margin: 0,\n backgroundColor: \"transparent\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n divIconsRow: {\n right: 0,\n textAlign: \"center\",\n marginLeft: \"auto\",\n float: \"right\",\n paddingTop: 0\n \n },\n inputGroup: {\n height: 40,\n backgroundColor: theme.colors.white,\n borderRadius: 5,\n border: \"1px solid #dddddd\"\n }\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport Modal from \"@material-ui/core/Modal\";\n\nimport MaskedInput from \"react-text-mask\";\n\nimport useStyles from \"./css\";\n\nimport CountryFlagIcon from \"../../../assets/flags\";\nimport { SearchIcon, SortDownIcon } from \"../../../assets/icons\";\nimport { PatientFormMobileInputProps } from \"./props\";\nimport useControlLabel from \"../../../hooks/useControlLabel\";\nimport Country from '../../../models/country';\nimport { FormPhoneNumberValue } from '../../../models/form-phone-number-value';\nimport { GetMobileMaskByTemp } from '../../../constants/mask';\nimport Input from \"../Input\";\n\n\nexport default function PatientFormMobileInput(props: PatientFormMobileInputProps) {\n \n const defaultDialTemplate: string = \"000-000-0000\";\n const defaultCountry = new Country({ iso3: \"MEX\", dialCode: 52, dialDigits: 10, dialTemplate: defaultDialTemplate, name: \"México\" });\n \n const { t } = useTranslation([\"general\"]);\n \n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n \n const {\n mobileNumber,\n setMobileNumber,\n countryInSettings,\n countries,\n required,\n label,\n isValid,\n onBlur \n } = props;\n \n const classes = useStyles()();\n \n const [openModal, setOpenModal] = useState<boolean>(false);\n \n const [countrySelected, setCountrySelected] = useState<Country>(defaultCountry);\n const [masking, setMasking] = useState<any>(GetMobileMaskByTemp(defaultDialTemplate));\n const [isValidNumber, setIsValidNumber] = useState<boolean>(true);\n const [searchValue, setSearchValue] = useState<string | null>(null);\n \n function setMobile(mobile: string) {\n setMobileNumber(new FormPhoneNumberValue({ countryIso: mobileNumber.countryIso, body: mobile }))\n }\n \n function handleCountrySelected(country: Country) {\n setSearchValue(null);\n setCountrySelected(country);\n setOpenModal(false);\n \n let newNumber: string;\n if (mobileNumber.body) {\n newNumber = mobileNumber.body.substring(0, country.dialDigits || 10);\n } else {\n newNumber = mobileNumber.body;\n }\n \n const m = GetMobileMaskByTemp(country.dialTemplate || defaultDialTemplate);\n setMasking(m);\n \n setMobileNumber(new FormPhoneNumberValue({ countryIso: country.iso3, body: newNumber }))\n \n const valid = validate(newNumber, country.dialDigits); //TODO check and probably remove\n }\n \n const handleMobileChange = (event: React.ChangeEvent<{ value: string }>) => {\n const mobile = event.target.value.replace(/[^0-9]/g, \"\");\n \n setMobile(mobile);\n \n const valid = validate(mobile, countrySelected?.dialDigits); //TODO check and probably remove\n };\n \n const validate = (mobileComplete: string, digits: number): boolean => {\n let validDig = false;\n\n if (mobileComplete.length === 0 && !required) {\n setIsValidNumber(true);\n return true;\n }\n\n if (mobileComplete) {\n const mobile = mobileComplete.replace(/[^0-9]/g, \"\");\n validDig = (digits === 7 && /^\\d{7}$/.test(mobile!)) ||\n (digits === 8 && /^\\d{8}$/.test(mobile!)) ||\n (digits === 9 && /^\\d{9}$/.test(mobile!)) ||\n (digits === 10 && /^\\d{10}$/.test(mobile!)) ||\n (digits === 11 && /^\\d{11}$/.test(mobile!)) ||\n (digits === 12 && /^\\d{12}$/.test(mobile!));\n \n setIsValidNumber(validDig);\n if (isValid) isValid(validDig);\n }\n \n return validDig;\n }\n \n useEffect(() => {\n \n (async () => {\n \n let iso = mobileNumber.countryIso || (countryInSettings ? countryInSettings.iso3 : null) || \"MEX\";\n \n const countryByIso = countries.filter(x => x.iso3 === iso);\n \n if (countryByIso.length > 0) {\n const country = countryByIso[0];\n setCountrySelected(country);\n const m = GetMobileMaskByTemp(country.dialTemplate || defaultDialTemplate);\n setMasking(m);\n }\n })();\n }, [countries, mobileNumber.countryIso]);\n \n function handleSearch(searchValue: string) {\n setSearchValue(searchValue);\n }\n \n function filterCountries (item: Country) {\n const lowercaseSearchValue = searchValue!.toLowerCase();\n let isSearchByDialCode = /^\\+?\\d+$/.test(searchValue!);\n \n if (searchValue!.trim().length < 2 && !isSearchByDialCode) {\n return true;\n }\n \n return (\n item.name.toLowerCase().includes(lowercaseSearchValue) ||\n item.dialCode.toString().startsWith(lowercaseSearchValue.replace(\"+\", \"\"))\n );\n }\n \n useEffect(() => {\n \n if (mobileNumber.body) {\n const m = GetMobileMaskByTemp(countrySelected.dialTemplate);\n setMasking(m);\n }\n \n }, [countrySelected]);\n \n const handleOpenModal = () => {\n setOpenModal(true);\n }\n \n const handleCloseModal = () => {\n setSearchValue(null);\n setOpenModal(false);\n }\n \n const inputLabel = label || t(\"Mobile\") + \" \";\n const ControlLabel = useControlLabel({ label: inputLabel, required })\n \n function countryAsListItem(country: Country) {\n return (\n <div key={country.iso3} className={classes.listCountry}>\n <div className={`${classes.elementList} ${classes.classRow}`} onClick={() => handleCountrySelected(country)}>\n <span className={classes.countryIcon}>\n <CountryFlagIcon iso={country.iso3} />\n </span>\n <div className={classes.countryName}>\n {country.name} (+{country.dialCode})\n </div>\n </div>\n </div>\n );\n }\n \n return (\n <div className={classes.root}>\n <div className={classes.divDropdown}>\n \n <ControlLabel />\n \n <div className={`${classes.inputGroup} ${!isValidNumber ? classes.inputError : \"\"}`}>\n <MaskedInput\n className={`${classes.inputClassic} ${classes.inputSelectBtn} `}\n placeholder={countrySelected?.dialTemplate || defaultDialTemplate}\n mask={masking}\n placeholderChar=\" \"\n onChange={handleMobileChange}\n onBlur={() => {if (onBlur) onBlur(validate(mobileNumber.body, countrySelected?.dialDigits))}}\n value={mobileNumber.body}\n />\n \n <div className={classes.divCodes} onClick={handleOpenModal}>\n <div className={classes.inputFlag}>\n <CountryFlagIcon iso={countrySelected?.iso3 || \"MEX\"}/>\n </div>\n <div className={classes.iconDropdown}>\n <SortDownIcon/>\n </div>\n <div className={classes.divDialCode}>\n {countrySelected.dialCode !== undefined ? `+${countrySelected.dialCode}` : \"+52\"}\n </div>\n </div>\n \n </div>\n </div>\n \n <Modal\n open={openModal}\n onClose={handleCloseModal}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n disablePortal={true}\n className={classes.modal}\n style={{ position: \"relative\" }}\n >\n <div className={classes.divModalSelect}>\n <div className={classes.titleCountries} >{t(\"Countries\")}</div>\n <div className={classes.searchInputContainer}>\n <Input\n placeholder={t(\"Search country code\")}\n width={\"-webkit-fill-available\"}\n onChange={(event) => handleSearch(event.target.value)}\n />\n <div className={classes.searchIconContainer}><SearchIcon style={{ fontSize: 17, color: \"#919CA5\" }}/></div>\n </div>\n <div className={classes.listCountryScroll}>\n {(searchValue === null\n ? countries\n : countries.filter((item) => filterCountries(item))).map(countryAsListItem)}\n </div>\n </div>\n </Modal>\n </div>\n );\n}","export class SectionFieldItemModel {\n id: string | null;\n name: string;\n order: number;\n isDeleted: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.order = x.order;\n this.isDeleted = x.isDeleted;\n } else {\n this.id = null;\n this.name = \"\";\n this.order = 1;\n this.isDeleted = false;\n }\n }\n}","import { SectionFieldType } from \"./enums/section-field-type\";\nimport { FormPhoneNumberValue } from \"./form-phone-number-value\";\nimport { FormRadioValue } from \"./form-radio-value\";\n\nexport class SectionFieldValueModel {\n type: SectionFieldType;\n value: string | FormPhoneNumberValue | FormRadioValue;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.type = x.type;\n this.value = x.value;\n }\n else {\n this.type = SectionFieldType.Text;\n this.value = \"\";\n }\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n width: \"100%\",\n backgroundColor: theme.colors.white\n },\n radios: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n },\n freeTextAreaContainer: {\n paddingTop: 15\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.subtitle2,\n \n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n radio: {\n color: theme.colors.grey5,\n paddingRight: 9,\n \"& svg\": {\n width: 14,\n height: 14\n }\n },\n text: {\n paddingRight: 3,\n \n ...theme.typography.txtBody1,\n color: theme.colors.grey5\n },\n checked: {\n color: theme.colors.clearMain,\n fontWeight: 700,\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { Radio } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { PatientFormRadioProps } from \"./props\";\n\n\nexport default function PatientFormRadio(props: PatientFormRadioProps) {\n \n const { value, checked, onCheck } = props;\n \n const classes = useStyles();\n \n function handleChecking() {\n onCheck();\n }\n \n return (\n <div className={classes.root}>\n <Radio\n checked={checked}\n onChange={handleChecking}\n color={checked ? \"primary\" : \"default\"}\n classes={{\n root: classes.radio,\n checked: classes.checked\n }}\n />\n <div className={`${classes.text} ${checked ? classes.checked : ''}`}>{value}</div>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number | string) =>\n makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n backgroundColor: \"#FFFFFF\", \n position: \"relative\",\n },\n input: {\n backgroundColor: \"#FFFFFF\",\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: \"100%\",\n },\n inputWidth: {\n width: \"90%\"\n },\n counter: {\n position: \"absolute\",\n bottom: 7,\n right: 7,\n fontSize: 12,\n color: \"#B5B9C1\",\n padding: \"5px\",\n },\n inputText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey6,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: \"auto\",\n },\n inputDisabled: {\n color: \"#676767\",\n }\n }));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { InputBase } from \"@material-ui/core\";\n\nimport { PatientFormFreeTextInputProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function PatientFormFreeTextInput(props: PatientFormFreeTextInputProps) {\n \n const { value, setValue, placeholder, width, disabled, maxLength } = props;\n \n const classes = useStyles(width)();\n \n function handleOnChange(event: any) {\n setValue(event.target.value);\n }\n \n return (\n <div className={classes.root}>\n <InputBase\n className={classes.input}\n placeholder={placeholder}\n value={value}\n onChange={handleOnChange}\n disabled={disabled}\n inputProps={{\n className: classes.inputWidth,\n maxLength: maxLength\n }}\n />\n <div className={classes.counter}>{`${value?.length}/${maxLength}`}</div>\n </div>\n );\n}","import React, { useEffect, useState } from 'react';\n\nimport { PatientFormRadioGroupProps } from \"./props\";\nimport useStyles from \"./css\";\nimport PatientFormRadio from \"../PatientFormRadio\";\nimport useControlLabel from \"../../../hooks/useControlLabel\";\nimport PatientFormFreeTextInput from '../PatientFormFreeTextInput';\nimport { useTranslation } from 'react-i18next';\nimport { SectionFieldItemModel } from '../../../models/section-field-item-model';\n\n\nexport default function PatientFormRadioGroup(props: PatientFormRadioGroupProps) {\n\n const { field, value, selectedItem, setSectionFieldItem, setFreeTextValue } = props;\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const classes = useStyles();\n\n const ControlLabel = useControlLabel({ label: t(field.name, { ns: sectionTNamespace }), required: field.isRequired });\n\n const [items, setItems] = useState<SectionFieldItemModel[]>(field.items.filter((i: SectionFieldItemModel) => {\n if (field.isDeleted)\n return true;\n else {\n return !i.isDeleted\n }\n }));\n\n useEffect(() => {\n if (!value || items.some(i => i.id === value.item.fieldItemId)) {\n return;\n }\n\n const itemsWithOldValue = [...items];\n itemsWithOldValue.unshift(new SectionFieldItemModel({ id: value.item.fieldItemId, name: value.item.value, order: 0 }))\n setItems(itemsWithOldValue);\n }, []);\n\n function itemAsRenderItem(item: SectionFieldItemModel) {\n return (\n <div>\n <PatientFormRadio\n key={item.name}\n value={t(item.name, { ns: sectionTNamespace })}\n checked={selectedItem !== null && selectedItem.id === item.id}\n onCheck={() => setSectionFieldItem(item)}\n />\n </div>\n );\n }\n\n return (\n <div className={classes.root}>\n <ControlLabel />\n <div className={classes.radios}>\n {\n items.sort((i1, i2) => i1.order - i2.order).map(itemAsRenderItem)\n }\n </div>\n {\n (value?.additionalFreeTextValue !== \"\" || field.isAdditionalTextareaEnabled) && setFreeTextValue\n ?\n <div className={classes.freeTextAreaContainer}>\n <PatientFormFreeTextInput\n key={field.id! + \"freeTextInput\"}\n value={value?.additionalFreeTextValue ?? \"\"}\n setValue={setFreeTextValue}\n placeholder={`${t(\"Write here your answer for\")} ${t(field.name, { ns: sectionTNamespace })}`}\n maxLength={100}\n />\n </div>\n :\n null\n }\n </div>\n );\n}","import { SectionFieldType } from \"./enums/section-field-type\";\nimport { SectionFieldItemModel } from \"./section-field-item-model\";\n\nexport class SectionFieldModel {\n id: string | null;\n name: string;\n order: number;\n type: SectionFieldType;\n items: SectionFieldItemModel[];\n isRequired: boolean;\n isAdditionalTextareaEnabled: boolean;\n isEditable: boolean;\n isRemovable: boolean;\n isDeleted: boolean;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.order = x.order;\n this.type = x.type;\n this.items = x.items;\n this.isRequired = x.isRequired;\n this.isAdditionalTextareaEnabled = x.isAdditionalTextareaEnabled;\n this.isEditable = x.isEditable;\n this.isRemovable = x.isRemovable;\n this.isDeleted = x.isDeleted;\n } else {\n this.id = null;\n this.name = \"\";\n this.order = 0;\n this.type = 31;\n this.items = [];\n this.isRequired = false;\n this.isAdditionalTextareaEnabled = false;\n this.isEditable = true;\n this.isRemovable = true;\n this.isDeleted = false;\n }\n }\n}","export enum TerminologyType {\n None = 0,\n Commission = 1,\n FiscalId = 2,\n Treatment = 3,\n Certification = 4\n}","export enum TerminologyForm {\n Singular,\n Plural\n}","import { SectionFieldModel } from \"./section-field-model\";\nimport { SectionFieldValueModel } from \"./section-field-value-model\";\n\nexport class FieldAndValue {\n field: SectionFieldModel;\n value: SectionFieldValueModel | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.field = x.field;\n this.value = x.value;\n }\n else {\n this.field = new SectionFieldModel();\n this.value = new SectionFieldValueModel();\n }\n }\n}","import { FieldAndValue } from \"./field-and-value\";\n\nexport class EvolutionNoteFieldAndValue extends FieldAndValue{\n constructor(x?: any) {\n super(x);\n }\n}","import { useTranslation } from \"react-i18next\";\nimport { useSelector } from \"react-redux\";\n\nimport { RootState, selectAccountSettings, selectEstablishmentSettings } from \"../../redux/store\";\nimport { useAppSelector } from '../../redux/hooks';\n\nimport { TerminologyProps } from \"./props\";\nimport { TerminologyType } from \"../../models/enums/terminology-type\";\nimport { Terminology } from '../../models/terminology';\nimport { TerminologyForm } from \"../../models/enums/terminology-form\";\n\n\nexport default function useTerminology(props: TerminologyProps) {\n \n const {\n type,\n form,\n template,\n templateTermToLowercase\n } = props;\n \n const { t } = useTranslation([\"terminologies\"]);\n const accountSettings = useAppSelector(selectAccountSettings);\n const establishmentSettings = useAppSelector(selectEstablishmentSettings);\n const selectedAccountId = useSelector((state: RootState) => state.enterprise.settingsEstablishmentId);\n\n function getDefaultTerminology(terminologyType: TerminologyType) {\n switch (terminologyType){\n case TerminologyType.Commission:\n return new Terminology({\n terminologyType: TerminologyType.Commission,\n singularForm: t('Commission'),\n pluralForm: t('Commissions'),\n })\n case TerminologyType.FiscalId:\n return new Terminology({\n terminologyType: TerminologyType.FiscalId,\n singularForm: t('Fiscal ID'),\n pluralForm: t('Fiscal ID'),\n })\n case TerminologyType.Treatment:\n return new Terminology({\n terminologyType: TerminologyType.Treatment,\n singularForm: t('Treatment'),\n pluralForm: t('Treatment'),\n })\n case TerminologyType.Certification:\n return new Terminology({\n terminologyType: TerminologyType.Certification,\n singularForm: t('Certification'),\n pluralForm: t('Certifications'),\n })\n default:\n return new Terminology({\n terminologyType: TerminologyType.None,\n singularForm: '',\n pluralForm: '',\n });\n }\n }\n \n function getTerminology() {\n if (type === TerminologyType.None) return \"\";\n\n const terminologyList = selectedAccountId\n ? establishmentSettings.terminologies\n : accountSettings.terminologies;\n\n const terminology = terminologyList?.find(t => t.terminologyType === type) ?? getDefaultTerminology(type);\n\n return form === TerminologyForm.Plural ? terminology.pluralForm : terminology.singularForm\n }\n \n function formatTemplate() {\n const countInterpolationsInTargetString = ((template!).match(/\\{[0-9]+}/g) || []).length;\n if (countInterpolationsInTargetString !== 1) {\n throw new Error(\"The number of terms does not match the number of interpolations in the target string.\");\n }\n const term = !!templateTermToLowercase ? getTerminology().toLowerCase() : getTerminology();\n let reg = new RegExp(\"\\\\{\\\\{\" + 0 + \"\\\\}\\\\}\", \"gm\");\n return template!.replace(reg, term);\n }\n \n return !!template ? formatTemplate() : getTerminology();\n}","import React, { useEffect, useState } from \"react\";\nimport { useHistory, useParams } from \"react-router-dom\";\nimport { conformToMask } from \"react-text-mask\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { Accordion, AccordionDetails, AccordionSummary, Button } from \"@material-ui/core\";\n\nimport { useDispatch } from 'react-redux';\n\nimport { PatientEvolutionNotesProps } from \"./props\";\nimport useStyles from \"./css\";\nimport DiaryIcon from \"../../../assets/icons/DiaryIcon\";\nimport {\n ArrowDownIcon,\n DeleteIcon,\n DownloadFileCloud,\n ImageIcon,\n InfoIcon,\n PDFIcon,\n PlusIcon,\n TrashIcon,\n UploadFileCloud,\n WordIcon\n} from \"../../../assets/icons\";\nimport EvolutionNotesGrouped, {\n EvolutionNote,\n EvolutionNoteClinicalFile,\n EvolutionNoteDynamicInput,\n EvolutionNoteTreatmentInput\n} from \"../../../models/evolution-notes-grouped\";\nimport { GetMonthStringEnum } from \"../../../models/enums/months\";\nimport { Editor } from \"@tinymce/tinymce-react\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport ConfirmActionModal from \"../../common/ConfirmActionModal\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport Input from \"../../common/Input\";\nimport ConfirmDeleteModal from \"../../common/ConfirmDeleteModal\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport PatientImportEvolutionNoteClinicalFileModal from \"../PatientImportEvolutionNoteClinicalFileModal\";\nimport { TableColumn } from \"../../common/grid/table-column\";\nimport GridListWithoutPagination from \"../../common/grid/GridListWithoutPagination\";\nimport { PatientFormFieldAndValue } from \"../../../models/patient-form-field-and-value\";\nimport { SectionFieldType } from \"../../../models/enums/section-field-type\";\nimport { FormPhoneNumberValue } from \"../../../models/form-phone-number-value\";\nimport { FormRadioValue } from \"../../../models/form-radio-value\";\nimport { SectionFieldModel } from \"../../../models/section-field-model\";\nimport PatientFormTextInput from \"../../common/PatientFormTextInput\";\nimport PatientFormMobileInput from \"../../common/PatientFormMobileInput\";\nimport { SectionFieldItemModel } from \"../../../models/section-field-item-model\";\nimport { SectionFieldValueModel } from \"../../../models/section-field-value-model\";\nimport { FormFieldItemValue } from \"../../../models/form-field-item-value\";\nimport { EmailRegex } from \"../../../constants/validator\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport PatientFormRadioGroup from \"../../common/PatientFormRadioGroup\";\nimport { EvolutionNoteFieldAndValue } from \"../../../models/evolution-note-field-and-value\";\nimport CountryFlagIcon from \"../../../assets/flags\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport { Color } from \"../../../constants/colors\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport CircularProgress from \"@material-ui/core/CircularProgress\";\nimport IconTooltip from \"../../common/IconTooltip\";\nimport useTerminology from \"../../../hooks/useTerminology\";\nimport { TerminologyType } from \"../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../models/enums/terminology-form\";\nimport { Url } from \"../../../constants/url\";\nimport { Customer } from \"../../../models/customer\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\n\n\nconst PatientEvolutionNotes = (props: PatientEvolutionNotesProps) => {\n\n const { customerName, customerMobile, appointmentId, serviceId, onUpdate } = props;\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const classes = useStyles();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const showLoaderIsActive = useAppSelector(state => state.navbar.showLoader);\n const dispatch = useDispatch();\n const history = useHistory();\n const { enqueueAlert } = alertsActions;\n const accountSettings = useAppSelector(selectAccountSettings);\n const { customerId } = useParams<any>();\n\n const treatmentTerm = useTerminology({ type: TerminologyType.Treatment, form: TerminologyForm.Singular });\n\n const [evolutionNotesGrouped, setEvolutionNotesGrouped] = useState<EvolutionNotesGrouped[]>([]);\n const [vitalSignsFields, setVitalSignsFields] = useState<SectionFieldModel[]>([]);\n const [treatmentForRemove, setTreatmentForRemove] = useState<EvolutionNoteTreatmentInput>();\n const [studyForRemove, setStudyForRemove] = useState<EvolutionNoteDynamicInput>();\n const [editNoteMode, setEditNoteMode] = useState<boolean>();\n const [cancelEvolutionNoteModalIsOpen, setCancelEvolutionNoteModalIsOpen] = useState<boolean>(false);\n const [evolutionNoteIsInvalid, setEvolutionNoteIsInvalid] = useState<boolean>(true);\n const [removeTreatmentModalIsOpen, setRemoveTreatmentModalIsOpen] = useState<boolean>(false);\n const [removeStudyModalIsOpen, setRemoveStudyModalIsOpen] = useState<boolean>(false);\n const [focusedEvolutionNoteInput, setFocusedEvolutionNoteInput] = useState<boolean>(false);\n const [focusedDiagnosisInput, setFocusedDiagnosisInput] = useState<boolean>(false);\n const [focusedAdditionalInstructionsInput, setFocusedAdditionalInstructionsInput] = useState<boolean>(false);\n const [evolutionNoteInputErrorHighlight, setEvolutionNoteInputErrorHighlight] = useState<boolean>(false);\n const [editableEvolutionNoteBeforeChanges, setEditableEvolutionNoteBeforeChanges] = useState<EvolutionNote>();\n const [editableEvolutionNote, setEditableEvolutionNote] = useState<EvolutionNote>();\n const [deleteFileModalIsOpen, setDeleteFileModalIsOpen] = useState<boolean>(false);\n const [deletableFile, setDeletableFile] = useState<EvolutionNoteClinicalFile | undefined>();\n const [diagnosisTextLength, setDiagnosisTextLength] = useState<number>(0);\n const [additionalInstructionsTextLength, setAdditionalInstructionsTextLength] = useState<number>(0);\n const [evolutionNoteTextLength, setEvolutionNoteTextLength] = useState<number>(0);\n const [vitalSignSectionName, setVitalSignSectionName] = useState<string>(\"\");\n const maxEditorTxtLength = 3485;\n\n const [importModalIsOpen, setImportModalIsOpen] = useState<boolean>(false);\n const [isLoading, setIsLoading] = useState<boolean>(true);\n\n useEffect(() => {\n const getData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const data = await CustomerService.getPatientEvolutionNotes(customerId, appointmentId, serviceId);\n dispatch(navbarActions.setShowLoader(false));\n if (data.evolutionNotesGrouped) {\n setEvolutionNotesGrouped(data.evolutionNotesGrouped);\n }\n if (data.sectionFields) {\n setVitalSignsFields(data.sectionFields);\n }\n\n if (data.vitalSignSectionName) {\n setVitalSignSectionName(data.vitalSignSectionName);\n }\n };\n\n getData()\n .then(() => setIsLoading(false));\n }, []);\n\n useEffect(() => {\n [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n if ((evolutionNote.evolutionNoteText === undefined\n || evolutionNote.evolutionNoteText.length < 1)\n || evolutionNoteTextLength > maxEditorTxtLength\n || diagnosisTextLength > maxEditorTxtLength\n || evolutionNote.vitalSigns.filter(x => x.field?.isRequired && !x.field?.isDeleted).some(x => x.value === null)) {\n setEvolutionNoteIsInvalid(true);\n } else {\n setEvolutionNoteIsInvalid(false);\n }\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n }, [evolutionNotesGrouped]);\n\n const handleAddNoteButton = () => {\n setEditNoteMode(true);\n let dateTimeNow = new Date();\n let yearIndex = dateTimeNow.getFullYear();\n let monthIndex = dateTimeNow.getMonth() + 1;\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped];\n\n let result = newEvolutionNotesGrouped?.find(item => item.month === monthIndex && item.year === yearIndex);\n\n let treatments: Array<EvolutionNoteTreatmentInput> = [];\n let studies: Array<EvolutionNoteDynamicInput> = [];\n let vitalSigns: Array<EvolutionNoteFieldAndValue> = [];\n [...vitalSignsFields].forEach(field => {\n vitalSigns.push(new EvolutionNoteFieldAndValue({ field: field, value: null }));\n });\n\n let clinicalFiles: EvolutionNoteClinicalFile[] = [];\n if (result) {\n newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n if (evolutionNoteGrouped.month === monthIndex && evolutionNoteGrouped.year === yearIndex) {\n treatments.push(new EvolutionNoteTreatmentInput({ id: null, order: 1, medication: \"\", prescription: \"\" }));\n studies.push(new EvolutionNoteDynamicInput({ id: null, order: 1, name: \"\" }));\n let evolutionNote = new EvolutionNote({ editMode: true, vitalSigns: vitalSigns, treatments: treatments, studies: studies, clinicalFiles: clinicalFiles });\n evolutionNoteGrouped.evolutionNotes.push(evolutionNote);\n setEditableEvolutionNote(evolutionNote);\n }\n return evolutionNoteGrouped;\n });\n\n } else {\n treatments.push(new EvolutionNoteTreatmentInput({ id: null, order: 1, medication: \"\", prescription: \"\" }));\n studies.push(new EvolutionNoteDynamicInput({ id: null, order: 1, name: \"\" }));\n let evolutionNotes: Array<EvolutionNote> = [];\n let evolutionNote = new EvolutionNote({ editMode: true, vitalSigns: vitalSigns, treatments: treatments, studies: studies, clinicalFiles: clinicalFiles });\n evolutionNotes.push(evolutionNote);\n newEvolutionNotesGrouped.push(new EvolutionNotesGrouped({ evolutionNotes: evolutionNotes, month: dateTimeNow.getMonth() + 1, year: dateTimeNow.getFullYear() }));\n setEditableEvolutionNote(evolutionNote);\n }\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const handleEvolutionNoteEditorOnBlur = (c: any, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n if (contentText.length < 1 || contentText.length > maxEditorTxtLength) {\n setEvolutionNoteInputErrorHighlight(true);\n } else {\n setEvolutionNoteInputErrorHighlight(false);\n }\n setFocusedEvolutionNoteInput(false)\n }\n\n async function handleSaveNoteButton(evolutionNote: EvolutionNote) {\n evolutionNote.customerId = customerId;\n evolutionNote.appointmentId = appointmentId;\n evolutionNote.serviceId = serviceId;\n evolutionNote.treatments = evolutionNote.treatments.filter(x => x.medication !== \"\" && x.medication !== undefined);\n evolutionNote.studies = evolutionNote.studies.filter(x => x.name !== \"\" && x.name !== undefined);\n dispatch(navbarActions.setShowLoader(true));\n const data = await CustomerService.createEvolutionNote(evolutionNote);\n dispatch(navbarActions.setShowLoader(false));\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === undefined) {\n if (data) {\n evolutionNote.id = data.id;\n evolutionNote.diagnosis = data.diagnosis;\n evolutionNote.evolutionNoteText = data.evolutionNoteText;\n evolutionNote.user = data.user;\n evolutionNote.dateCreated = data.dateCreated;\n evolutionNote.appointmentDate = data.appointmentDate;\n evolutionNote.editMode = false;\n evolutionNote.treatments = data.treatments.map((item: any) => new EvolutionNoteTreatmentInput(item));\n evolutionNote.studies = data.studies.map((item: any) => new EvolutionNoteDynamicInput(item));\n evolutionNote.clinicalFiles = data.clinicalFiles.map((item: any) => new EvolutionNoteClinicalFile(item));\n }\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEditNoteMode(false);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Evolution note successfully created\"),\n }));\n\n onUpdate();\n }\n\n async function handleUpdateNoteButton(evolutionNote: EvolutionNote) {\n evolutionNote.treatments = evolutionNote.treatments.filter(x => x.medication !== \"\" && x.medication !== undefined);\n evolutionNote.studies = evolutionNote.studies.filter(x => x.name !== \"\" && x.name !== undefined);\n dispatch(navbarActions.setShowLoader(true));\n const data = await CustomerService.updateEvolutionNote(evolutionNote);\n dispatch(navbarActions.setShowLoader(false));\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === data.id) {\n evolutionNote.diagnosis = data.diagnosis;\n evolutionNote.evolutionNoteText = data.evolutionNoteText;\n evolutionNote.editMode = false;\n evolutionNote.treatments = data.treatments.map((item: any) => new EvolutionNoteTreatmentInput(item));\n evolutionNote.studies = data.studies.map((item: any) => new EvolutionNoteDynamicInput(item));\n evolutionNote.clinicalFiles = data.clinicalFiles.map((item: any) => new EvolutionNoteClinicalFile(item));\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEditNoteMode(false);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n\n onUpdate();\n\n }\n\n const handleEditNoteButton = async (editableEvolutionNote: EvolutionNote) => {\n setEditNoteMode(true);\n setEditableEvolutionNoteBeforeChanges({\n ...editableEvolutionNote,\n studies: structuredClone(editableEvolutionNote.studies),\n treatments: structuredClone(editableEvolutionNote.treatments),\n clinicalFiles: structuredClone(editableEvolutionNote.clinicalFiles)\n });\n\n setEditableEvolutionNote(editableEvolutionNote);\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote.id) {\n if (evolutionNote.treatments.length === 0) {\n let treatments: Array<EvolutionNoteTreatmentInput> = [];\n treatments.push(new EvolutionNoteTreatmentInput({ id: null, order: 1, medication: \"\", prescription: \"\" }));\n evolutionNote.treatments = treatments;\n }\n if (evolutionNote.studies.length === 0) {\n let studies: Array<EvolutionNoteDynamicInput> = [];\n studies.push(new EvolutionNoteDynamicInput({ id: null, order: 1, name: \"\" }));\n evolutionNote.studies = studies;\n }\n\n evolutionNote.editMode = true;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const handleCancelButtonEvolutionNoteModal = (canceledEvolutionNote: EvolutionNote) => {\n if (canceledEvolutionNote.id) {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n\n if (evolutionNote.id === canceledEvolutionNote.id) {\n evolutionNote.evolutionNoteText = editableEvolutionNoteBeforeChanges!.evolutionNoteText;\n evolutionNote.diagnosis = editableEvolutionNoteBeforeChanges!.diagnosis!;\n evolutionNote.treatments = editableEvolutionNoteBeforeChanges!.treatments!;\n evolutionNote.studies = editableEvolutionNoteBeforeChanges!.studies;\n evolutionNote.clinicalFiles = editableEvolutionNoteBeforeChanges!.clinicalFiles;\n evolutionNote.editMode = false;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n setEditableEvolutionNoteBeforeChanges(undefined);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n setEvolutionNoteInputErrorHighlight(false);\n setEditNoteMode(false);\n } else {\n [...evolutionNotesGrouped].filter(evolutionNoteGrouped => {\n let editableEvolutionNoteEntity = evolutionNoteGrouped.evolutionNotes.find(evolutionNote => evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined);\n if (editableEvolutionNoteEntity) {\n if ((editableEvolutionNoteEntity.evolutionNoteText === undefined || editableEvolutionNoteEntity.evolutionNoteText?.length === 0)\n && (editableEvolutionNoteEntity.diagnosis === undefined || editableEvolutionNoteEntity.diagnosis?.length === 0)\n && (editableEvolutionNoteEntity.treatments.length > 1 || editableEvolutionNoteEntity.treatments[0].medication.length === 0)\n && (editableEvolutionNoteEntity.studies.length > 1 || editableEvolutionNoteEntity.studies[0].name.length === 0)) {\n handleOnConfirmCancelEvolutionNote();\n } else {\n setCancelEvolutionNoteModalIsOpen(true);\n }\n }\n });\n }\n };\n\n const handleOnConfirmCancelEvolutionNote = () => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].filter(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes = evolutionNoteGrouped.evolutionNotes.filter(note => note.id != undefined);\n if (evolutionNoteGrouped.evolutionNotes.length > 0) {\n return evolutionNoteGrouped;\n }\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n setEditNoteMode(false);\n setCancelEvolutionNoteModalIsOpen(false);\n setEvolutionNoteInputErrorHighlight(false);\n };\n const handleOnRemoveTreatmentConfirm = () => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n let index = evolutionNote.treatments.map(x => x.order).indexOf(treatmentForRemove!.order);\n if (index !== -1) {\n evolutionNote.treatments.splice(index, 1);\n }\n evolutionNote.treatments.forEach(s => {\n if (s.order! <= index)\n return;\n s.order = s.order! - 1;\n });\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n setRemoveTreatmentModalIsOpen(false);\n };\n\n const handleOnRemoveStudyConfirm = () => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n let index = evolutionNote.studies.map(x => x.order).indexOf(studyForRemove!.order);\n if (index !== -1) {\n evolutionNote.studies.splice(index, 1);\n }\n evolutionNote.studies.forEach(s => {\n if (s.order! <= index)\n return;\n s.order = s.order! - 1;\n });\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n setRemoveStudyModalIsOpen(false);\n };\n\n const handleAddTreatmentClick = () => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.treatments.push(new EvolutionNoteTreatmentInput({ id: null, order: evolutionNote.treatments.length + 1, medication: \"\", prescription: \"\" }));\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const handleAddStudyClick = () => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.studies.push(new EvolutionNoteDynamicInput({ id: null, order: evolutionNote.studies.length + 1, name: \"\" }));\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const handleEditorEvolutionNoteTextChange = async (text: string, editor: any) => {\n const editorLength = editor.getContent({ format: \"text\" }).length;\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.evolutionNoteText = text;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNoteTextLength(editorLength);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const handleEditorDiagnosisChange = async (text: string, editor: any) => {\n const editorLength = editor.getContent({ format: \"text\" }).length;\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.diagnosis = text;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n setDiagnosisTextLength(editorLength);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const handleEditorAdditionalInstructionsChange = async (text: string, editor: any) => {\n const editorLength = editor.getContent({ format: \"text\" }).length;\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.additionalInstructions = text;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n setAdditionalInstructionsTextLength(editorLength);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const fileDate = (appointmentDate: Date): string => {\n const date = new Date(appointmentDate);\n\n const day = date.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n\n const month = date.toLocaleString(localeApp, {\n month: \"2-digit\",\n });\n\n const year = date.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n\n if (localeApp === \"es\")\n return `${day}-${month}-${year}`;\n else\n return `${month}-${day}-${year}`;\n }\n\n const date = (startDate: Date | null): string => {\n if (startDate === null) {\n return \"--\";\n }\n\n const date = new Date(startDate);\n\n const day = date.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n\n const month = date.toLocaleString(localeApp, {\n month: \"short\",\n }).toLowerCase();\n\n const year = date.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n\n const time = date.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n const capitalizeFirstLetter = function (str: string) {\n return str.charAt(0).toUpperCase() + str.slice(1);\n }\n\n if (localeApp === \"es\")\n return capitalizeFirstLetter(`${day}/${month}/${year} - ${time}hrs`);\n else\n return capitalizeFirstLetter(`${month}/${day}/${year} - ${time}hrs`);\n };\n\n const filesColumns: TableColumn[] = [\n {\n id: \"fileName\",\n label: t(\"NAME\"),\n sorting: false,\n completeObject: true,\n width: 130,\n component: (item: any) => <>\n <div className={classes.fileNameContainer}>\n <div style={{ fontWeight: 700 }}>\n {getExtenstionImage(item.fileName)}\n </div>\n <div style={{ wordBreak: \"break-word\" }}>\n {t(item.fileName)}\n </div>\n </div>\n </>,\n },\n {\n id: \"uploadedBy\",\n label: t(\"UPLOADED\"),\n width: 80,\n completeObject: true,\n component: (item: any) => <>\n <div style={{ marginLeft: 3 }}>\n {item.uploadedBy}\n </div>\n </>,\n },\n {\n id: \"created\",\n label: t(\"DATE AND TIME\"),\n width: 20,\n completeObject: true,\n component: (item: any) => <>\n <div style={{ whiteSpace: \"pre-line\", marginLeft: 3 }}>\n {getUploadDate(item.created)}\n </div>\n </>,\n },\n {\n id: \"fileComment\",\n label: t(\"COMMENTS\"),\n width: 130,\n completeObject: true,\n component: (item: any) => <>\n {item.fileComment\n ? item.fileComment\n : <div style={{ color: \"#919CA5\", marginLeft: 3 }}>\n {t(\"No comments\")}\n </div>}\n </>,\n },\n {\n id: \"s3Key\",\n label: t(\"ACTIONS\"),\n width: 60,\n completeObject: true,\n component: (item: any) => <>\n <div className={classes.actionsContainer}>\n <IconButton\n onClick={() => handleDownloadFile(item)}>\n <DownloadFileCloud />\n </IconButton>\n <IconButton\n onClick={() => handleOnClickDeleteFile(item)}>\n <TrashIcon style={{ color: \"#5C6477\" }} />\n </IconButton>\n </div>\n </>,\n },\n ];\n\n const getUploadDate = (startDate: Date): string => {\n const date = new Date(startDate);\n\n const day = date.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n\n const month = date.toLocaleString(localeApp, {\n month: \"long\",\n }).toLowerCase();\n\n const year = date.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n\n const time = date.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n\n if (localeApp === \"es\")\n return `${day}/${month}/${year} \\n ${time} hrs`;\n else\n return `${month}/${day}/${year} \\n ${time} hrs`;\n };\n\n const getExtenstionImage = (name: string) => {\n if (name) {\n let fileExtension = name.split(\".\").pop();\n switch (fileExtension) {\n case \"pdf\":\n return <div style={{ padding: 8 }}><PDFIcon width={16} style={{ color: \"#5C6477\" }}></PDFIcon></div>\n case \"docx\":\n return <WordIcon width={32} style={{ color: \"#5C6477\" }}></WordIcon>\n case \"jpg\":\n return <ImageIcon width={32} style={{ color: \"#5C6477\" }}></ImageIcon>\n case \"png\":\n return <ImageIcon width={32} style={{ color: \"#5C6477\" }}></ImageIcon>\n default:\n return <PDFIcon width={16} style={{ color: \"#5C6477\" }}></PDFIcon>\n }\n }\n };\n\n const handleDownloadFile = (file: EvolutionNoteClinicalFile) => {\n if (file.s3Key) {\n dispatch(navbarActions.setShowLoader(true));\n (async () => {\n const data = await CustomerService.getPatientClinicalFileUrl(file.s3Key);\n dispatch(navbarActions.setShowLoader(false));\n if (data.entity) {\n let fileUrl = data.entity.toString();\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", fileUrl);\n link.setAttribute(\"target\", \"_blank\");\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n })();\n } else {\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", file.fileURL);\n link.setAttribute(\"target\", \"_blank\");\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n };\n\n const handleDeleteFile = () => {\n if (deletableFile?.s3Key) {\n dispatch(navbarActions.setShowLoader(true));\n (async () => {\n await CustomerService.deletePatientClinicalFile(deletableFile.s3Key);\n dispatch(navbarActions.setShowLoader(false));\n })();\n }\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n evolutionNote.clinicalFiles.map((file, index) => {\n if ((file.s3Key && file.s3Key === deletableFile?.s3Key) || (file.fileURL && file.fileURL === deletableFile?.fileURL)) {\n evolutionNote.clinicalFiles.splice(index, 1);\n }\n })\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"File successfully deleted\"),\n description: deletableFile?.fileName,\n }));\n setDeletableFile(undefined);\n setDeleteFileModalIsOpen(false);\n };\n\n const handleOnClickDeleteFile = (file: EvolutionNoteClinicalFile) => {\n setDeletableFile(file);\n setDeleteFileModalIsOpen(true);\n };\n\n const CancelNewEvolutionNoteModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {t(\"Cancel new evolution note?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {t(\"Changes made will not be saved\")}\n </Typography>\n </div>);\n };\n\n const RemoveTreatmentModalContent: React.FC = () => {\n return (<div className={classes.removeModalContentContainer}>\n <Typography className={classes.closeModalContentHeaderText}>\n {t(\"Delete this treatment?\", { treatment: treatmentTerm.toLowerCase() })}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {treatmentForRemove?.medication}\n </Typography>\n <Typography className={classes.closeModalContentText2}>\n {treatmentForRemove?.prescription}\n </Typography>\n </div>);\n };\n\n const RemoveStudyModalContent: React.FC = () => {\n return (<div className={classes.removeModalContentContainer}>\n <Typography className={classes.closeModalContentHeaderText}>\n {t(\"Delete this study?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {studyForRemove?.name}\n </Typography>\n </div>);\n };\n\n const RemoveFileModalContent: React.FC = () => {\n return (<div className={classes.removeModalContentContainer}>\n <Typography className={classes.closeModalContentHeaderText}>\n {t(\"Are you sure to delete the file?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {deletableFile?.fileName}\n </Typography>\n </div>);\n };\n\n const onHandleChangeTreatment = (event: React.ChangeEvent<{ name: string, value: string }>, treatment: EvolutionNoteTreatmentInput, changed: \"medication\" | \"prescription\") => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n let editableTreatment = evolutionNote.treatments.find(x => x.order === treatment.order);\n if (editableTreatment) {\n if (changed === \"medication\") {\n editableTreatment.medication = event.target.value;\n } else {\n editableTreatment.prescription = event.target.value;\n }\n }\n\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n async function handleSendPdfByWhatsAppClick(evolutionNoteId: string) {\n const response = await CustomerService.sendTreatmentPdfByWhatsApp(customerId, evolutionNoteId);\n\n if (response) {\n dispatch(enqueueAlert({\n type: \"Success\",\n title: t(\"Treatment successfully sent\", { treatment: treatmentTerm }),\n description: customerName,\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n history.push(`${Url.WhatsApp.Main}/${customerMobile}`);\n },\n title: t(\"Go to the conversation\"),\n }\n }));\n }\n }\n\n async function handlePrintPdfClick(evolutionNoteId: string, appointmentDate: string) {\n const blob = await CustomerService.getTreatmentPdf(customerId, evolutionNoteId);\n const url = window.URL.createObjectURL(new Blob([blob], {\n type: \"application/pdf\"\n }));\n const link = document.createElement('a');\n link.href = url;\n const fileName = `${treatmentTerm}-${appointmentDate}.pdf`\n link.setAttribute('download', `${fileName}`);\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n }\n\n const onHandleChangeStudy = (event: React.ChangeEvent<{ name: string, value: string }>, study: EvolutionNoteDynamicInput) => {\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n let editableTreatment = evolutionNote.studies.find(x => x.order === study.order);\n if (editableTreatment) {\n editableTreatment.name = event.target.value;\n }\n\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n };\n\n const getFieldValueComponent = (valueModel: SectionFieldValueModel | null | undefined) => {\n if (valueModel?.value === null || valueModel?.value == undefined || valueModel?.value === \"\")\n return <Typography className={classes.fieldValueLabel}>\n {\"--\"}\n </Typography>\n switch (valueModel.type) {\n case SectionFieldType.Text:\n return <Typography className={classes.fieldValueLabel}>\n {valueModel.value as string}\n </Typography>\n case SectionFieldType.Email:\n return <Typography className={classes.fieldValueLabel}>\n {valueModel.value as string}\n </Typography>\n case SectionFieldType.Radio:\n return <Typography className={classes.fieldValueLabel}>\n {t((valueModel.value as FormRadioValue).item.value, { ns: sectionTNamespace })}\n {!!(valueModel.value as FormRadioValue).additionalFreeTextValue &&\n <> / {(valueModel.value as FormRadioValue).additionalFreeTextValue}</>\n }\n </Typography>\n case SectionFieldType.PhoneNumber: {\n const phoneNumberValue = valueModel.value as FormPhoneNumberValue;\n return <div className={classes.phoneNumberContainer}>\n <CountryFlagIcon iso={phoneNumberValue.countryIso} />\n <Typography className={classes.phoneNumberCodeLabel}>\n {\"+\" + accountSettings.countries.find(c => c.iso3 === phoneNumberValue.countryIso)!.dialCode}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {conformToMask(phoneNumberValue.body,\n GetMobileMaskByTemp(\n accountSettings.countries.find(c => c.iso3 === phoneNumberValue.countryIso)!.dialTemplate)).conformedValue}\n </Typography>\n </div>\n }\n }\n };\n\n const getInputForEditMode = (fieldAndValueModel: PatientFormFieldAndValue) => {\n const sectionField = fieldAndValueModel.field;\n const valueField = fieldAndValueModel.value;\n if (!valueField?.value) {\n //return empty input for sectionField type\n switch (sectionField.type) {\n case SectionFieldType.Text:\n return getTextInput(sectionField);\n case SectionFieldType.Email:\n return getEmailInput(sectionField);\n case SectionFieldType.PhoneNumber:\n return getPhoneNumberInput(sectionField);\n case SectionFieldType.Radio:\n return getRadioInput(sectionField);\n default:\n return;\n }\n }\n\n if (sectionField.type !== valueField.type) {\n switch (sectionField.type) {\n case SectionFieldType.Text:\n switch (valueField.type) {\n case SectionFieldType.Email:\n //return TextInput with valueField.value\n return getTextInput(sectionField, valueField.value as string);\n case SectionFieldType.PhoneNumber:\n //return TextInput with PhoneNumber like \"+52123456789\"\n const phoneObj = valueField.value as FormPhoneNumberValue;\n const dialCode = accountSettings.countries.find(c => c.iso3 === phoneObj.countryIso)!.dialCode;\n const phoneAsString = `+${dialCode}${phoneObj.body}`\n return getTextInput(sectionField, phoneAsString);\n case SectionFieldType.Radio:\n //return TextInput with valueField.value.item.value\n const radioItemObj = valueField.value as FormRadioValue;\n return getTextInput(sectionField, radioItemObj.item.value);\n }\n case SectionFieldType.Email:\n //return empty input for Email type\n return getEmailInput(sectionField);\n case SectionFieldType.PhoneNumber:\n //return empty input for PhoneNumber type\n return getPhoneNumberInput(sectionField);\n case SectionFieldType.Radio:\n //return empty input for Radio type\n return getRadioInput(sectionField);\n }\n }\n\n //dealing with filled RadioInput\n if (sectionField.type === SectionFieldType.Radio && valueField.type === SectionFieldType.Radio) {\n if (sectionField.items\n .filter(i => !i.isDeleted)\n .map(i => i.id)\n .some(i => i === (valueField.value as FormRadioValue).item.fieldItemId)) {\n //return RadioInput with valueField.value.item checked\n return getRadioInput(sectionField, valueField.value as FormRadioValue);\n } else {\n //return RadioInput with FAKE valueField.value.item checked\n return getRadioInput(sectionField, valueField.value as FormRadioValue, true);\n }\n }\n\n //dealing with other filled field types\n switch (sectionField.type) {\n case SectionFieldType.Text:\n //return filled TextInput\n return getTextInput(sectionField, valueField.value as string);\n case SectionFieldType.Email:\n //return filled EmailInput\n return getEmailInput(sectionField, valueField.value as string);\n case SectionFieldType.PhoneNumber:\n //return filled PhoneNumberInput\n return getPhoneNumberInput(sectionField, valueField.value as FormPhoneNumberValue);\n }\n };\n\n const validatePhoneNumber = (iso3Code: string, phoneNumber: string) => {\n const numberOfDigits = accountSettings.countries?.find(c => c.iso3 === iso3Code)!.dialDigits;\n if (!numberOfDigits)\n return false;\n return (numberOfDigits === 7 && /^\\d{7}$/.test(phoneNumber)) ||\n (numberOfDigits === 8 && /^\\d{8}$/.test(phoneNumber)) ||\n (numberOfDigits === 9 && /^\\d{9}$/.test(phoneNumber)) ||\n (numberOfDigits === 10 && /^\\d{10}$/.test(phoneNumber)) ||\n (numberOfDigits === 11 && /^\\d{11}$/.test(phoneNumber)) ||\n (numberOfDigits === 12 && /^\\d{12}$/.test(phoneNumber));\n };\n\n const validateEmailField = (field: SectionFieldModel, value: string): boolean => {\n if (field.isRequired) {\n return EmailRegex.test(value) && value !== \"\"\n }\n return EmailRegex.test(value) || value === \"\"\n };\n\n const validateTextField = (field: SectionFieldModel, value: string): boolean => {\n const isValid = !(field.isRequired && value === \"\");\n return isValid;\n };\n\n const validateFieldsOnChange = (fieldsAndValues: PatientFormFieldAndValue[]) => {\n const isValid = !fieldsAndValues.some(fv => {\n if (fv.field.isRequired) {\n if (!fv.value?.value || fv.value?.value === \"\") {\n if (!fv.field.isDeleted) {\n return true;\n } else {\n return false;\n }\n }\n switch (fv.field.type) {\n case SectionFieldType.Text:\n if (!fv.value?.value || fv.value.value === \"\") {\n return true;\n }\n break;\n case SectionFieldType.Email:\n if (!fv.value?.value || fv.value.value === \"\" || !EmailRegex.test(fv.value!.value as string)) {\n return true;\n }\n break;\n case SectionFieldType.Radio:\n if (!fv.field.isDeleted && (fv.value?.value as FormRadioValue).item === null) {\n return true;\n }\n break;\n case SectionFieldType.PhoneNumber:\n const phoneNumber = (fv.value?.value as FormPhoneNumberValue);\n if (!fv.field.isDeleted && (phoneNumber.body === \"\" || !validatePhoneNumber(phoneNumber.countryIso, phoneNumber.body))) {\n return true;\n }\n break;\n }\n } else {\n switch (fv.field.type) {\n case SectionFieldType.Email:\n if (fv.value?.value && !EmailRegex.test(fv.value.value as string)) {\n return true;\n }\n break;\n case SectionFieldType.PhoneNumber:\n const phoneNumber = (fv.value?.value as FormPhoneNumberValue);\n if (phoneNumber && phoneNumber.body !== \"\" && !validatePhoneNumber(phoneNumber.countryIso, phoneNumber.body)) {\n return true;\n }\n break;\n }\n }\n\n return false;\n });\n\n setEvolutionNoteIsInvalid(!isValid);\n };\n\n const setFieldValue = (fieldId: string, value: string | FormPhoneNumberValue | FormRadioValue | null, additionalTextValue: string | null = null) => {\n if (!editableEvolutionNote?.vitalSigns)\n return;\n\n const fieldsAndValues = [...editableEvolutionNote.vitalSigns];\n const fieldAndValue = fieldsAndValues.find(f => f.field.id === fieldId);\n\n if (!fieldAndValue)\n return;\n\n //make value null if field is empty (need for compairing with old patient version and for proper storing)\n if (typeof value === \"string\" && value === \"\") {\n fieldAndValue.value = null;\n validateFieldsOnChange(fieldsAndValues);\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.vitalSigns = fieldsAndValues;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n //setEditableEvolutionNote({ ...editableEvolutionNote, vitalSigns: fieldsAndValues })\n return;\n }\n\n if (!additionalTextValue) {\n if (!fieldAndValue.value) {\n fieldAndValue.value = new SectionFieldValueModel({ type: fieldAndValue.field.type, value: value })\n } else {\n fieldAndValue.value.type = fieldAndValue.field.type;\n fieldAndValue.value.value = value!;\n }\n }\n //if field is Radio and contain additional text value\n else if (additionalTextValue && fieldAndValue.field.type === SectionFieldType.Radio) {\n let newValue: FormRadioValue;\n //if this field value has already selected field item - just setting the argument value\n if (value && (value as FormRadioValue).item) {\n newValue = value as FormRadioValue;\n }\n //if not - we're selecting first item automatically\n else {\n const firstSelectItem = fieldAndValue.field.items.sort((i1, i2) => i1.order - i2.order)[0];\n const autoSelectedFirstItemValue = new FormFieldItemValue({ fieldItemId: firstSelectItem.id, value: firstSelectItem.name })\n newValue = new FormRadioValue();\n newValue.item = autoSelectedFirstItemValue;\n newValue.additionalFreeTextValue = additionalTextValue;\n }\n if (!fieldAndValue.value) {\n fieldAndValue.value = new SectionFieldValueModel({ type: fieldAndValue.field.type, value: newValue })\n } else {\n fieldAndValue.value.value = newValue!;\n }\n }\n\n let newEvolutionNotesGrouped = [...evolutionNotesGrouped].map(evolutionNoteGrouped => {\n evolutionNoteGrouped.evolutionNotes.map(evolutionNote => {\n if (evolutionNote.id === editableEvolutionNote?.id || evolutionNote.id === undefined) {\n evolutionNote.vitalSigns = fieldsAndValues;\n }\n return evolutionNote;\n })\n return evolutionNoteGrouped;\n });\n\n validateFieldsOnChange(fieldsAndValues);\n setEvolutionNotesGrouped(newEvolutionNotesGrouped);\n\n //setEditableEvolutionNote({ ...editableEvolutionNote, vitalSigns: fieldsAndValues })\n };\n\n const getTextInput = (field: SectionFieldModel, value: string | null = null) => {\n return <>\n <PatientFormTextInput\n key={field.id!}\n inputStyle={classes.inputText}\n value={value ? t(value, { ns: sectionTNamespace }) : \"\"}\n setValue={(v) => setFieldValue(field.id!, v)}\n label={t(field.name, { ns: sectionTNamespace })}\n isValid={(v) => validateTextField(field, v)}\n required={field.isRequired}\n placeholder={t(field.name, { ns: sectionTNamespace })}\n maxLength={1500} />\n </>\n };\n\n const getEmailInput = (field: SectionFieldModel, value: string | null = null) => {\n return <>\n <PatientFormTextInput\n key={field.id!}\n value={value ? value : \"\"}\n setValue={(v) => setFieldValue(field.id!, v)}\n label={t(field.name, { ns: sectionTNamespace })}\n isValid={(v) => validateEmailField(field, v)}\n required={field.isRequired}\n placeholder={t(field.name, { ns: sectionTNamespace })}\n maxLength={100} />\n </>\n };\n\n const getPhoneNumberInput = (field: SectionFieldModel, value: FormPhoneNumberValue | null = null) => {\n return <>\n <PatientFormMobileInput\n key={field.id!}\n mobileNumber={value ?? new FormPhoneNumberValue({ countryIso: accountSettings.countryInSettings!.iso3, body: \"\" })}\n label={t(field.name, { ns: sectionTNamespace })}\n setMobileNumber={(v) => setFieldValue(field.id!, v)}\n required={field.isRequired}\n countryInSettings={accountSettings.countryInSettings!}\n countries={accountSettings.countries!} />\n </>\n };\n\n function setEvolutionNotesTextLengthOnInit(evt: any, editor: any) {\n setEvolutionNoteTextLength(editor.getContent({ format: \"text\" }).length);\n }\n function setDiagnosisTextLengthOnInit(evt: any, editor: any) {\n setDiagnosisTextLength(editor.getContent({ format: \"text\" }).length);\n }\n function setAdditionalInstructionsTextLengthOnInit(evt: any, editor: any) {\n setAdditionalInstructionsTextLength(editor.getContent({ format: \"text\" }).length);\n }\n\n const getRadioInput = (field: SectionFieldModel, value: FormRadioValue | null = null, isFakeRadioItem: boolean = false) => {\n const getSelectedItem = () => {\n if (!value && !isFakeRadioItem) {\n //Possibly QA team will ask for this (TODO: fix lack of real value in request)\n // if (field.isRequired) {\n // //return first selected item\n // return field.items.filter(i => !i.isDeleted).sort((i1, i2) => i1.order - i2.order)[0]\n // }\n // else {\n // //return no selected item\n // return null;\n // }\n return null;\n }\n ;\n if (value && !isFakeRadioItem)\n //return genuine selected item\n return field.items.filter(i => i.id === value.item.fieldItemId)[0];\n if (value && isFakeRadioItem)\n //return \"fake\"/old selected item\n return new SectionFieldItemModel({ id: value.item.fieldItemId, name: value.item.value, order: 0 });\n\n return null;\n };\n\n const setRadioValue = (fieldId: string, i: SectionFieldItemModel) => {\n const radioValue = new FormFieldItemValue();\n radioValue.fieldItemId = i.id!;\n radioValue.value = i.name;\n\n const itemModel = new FormRadioValue();\n itemModel.item = radioValue;\n itemModel.additionalFreeTextValue = value ? value.additionalFreeTextValue : \"\"\n setFieldValue(fieldId, itemModel);\n };\n\n return <>\n <PatientFormRadioGroup\n key={field.id!}\n field={field}\n value={value}\n selectedItem={getSelectedItem()}\n setSectionFieldItem={(i) => setRadioValue(field.id!, i)}\n setFreeTextValue={\n field.isAdditionalTextareaEnabled\n ? (av) => {\n setFieldValue(field.id!, new FormRadioValue({ item: value?.item, additionalFreeTextValue: av }), av)\n }\n : undefined}\n />\n </>\n };\n\n function renderTreatment(treatment: EvolutionNoteTreatmentInput) {\n return (\n <li className={classes.editModeBoldText}>\n <Typography className={classes.editModeBoldText}>\n {treatment.medication}\n </Typography>\n <Typography className={classes.editModeSimpleText}>\n {treatment.prescription}\n </Typography>\n </li>\n )\n }\n\n function renderTreatments(treatments: EvolutionNoteTreatmentInput[]) {\n return (\n <ol className={classes.editModeTreatmentList}>\n {treatments.sort((t1, t2) => t1.order! - t2.order!).map(renderTreatment)}\n </ol>\n );\n }\n\n return (\n <div className={classes.root}>\n <ButtonWithSpinner\n width={140}\n margin={\"25px 0px -30px 600px\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n hoverColor={ButtonPropsColor.Main}\n innerText={t(\"Add note\")}\n innerIcon={<PlusIcon />}\n onClick={handleAddNoteButton}\n disabled={editNoteMode}\n />\n\n {!isLoading && evolutionNotesGrouped.length === 0 && <>\n <div className={classes.iconDiary}>\n <DiaryIcon />\n <Typography className={classes.diaryCaption}>\n {t(\"There are no evolution notes\")}\n </Typography>\n </div>\n </>}\n\n {!isLoading && (evolutionNotesGrouped.length > 1 || evolutionNotesGrouped[0]?.evolutionNotes?.length > 0) && <>\n <div className={classes.customerHistoryContent}>\n {evolutionNotesGrouped?.sort((e1, e2) => e2.year! - e1.year! || e2.month! - e1.month!).map((evolutionNoteGrouped, indexEvolutionNote) =>\n (<Accordion key={indexEvolutionNote} defaultExpanded={true} className={classes.accordion}>\n <AccordionSummary\n expandIcon={<ArrowDownIcon style={{ height: 15, width: 15, color: Color.clear1 }} />}>\n <div className={classes.monthYear}>\n {t(GetMonthStringEnum(evolutionNoteGrouped.month - 1))} {evolutionNoteGrouped.year}\n <span className={classes.notesCountInMonth}>{\" (\" + evolutionNoteGrouped.evolutionNotes.length + \")\"}</span>\n </div>\n </AccordionSummary>\n <AccordionDetails className={classes.accordionDetails}>\n <div className={classes.evolutionNoteForm}>\n {\n evolutionNoteGrouped.evolutionNotes.sort(function (e1, e2) {\n let noteDate1 = isNaN((new Date(e1.dateCreated).getTime()))\n ? Number.MAX_VALUE\n : new Date(e1.dateCreated).getTime();\n let noteDate2 = new Date(e2.dateCreated).getTime();\n return noteDate2 - noteDate1\n }).map((evolutionNote, indexEvolutionNote) =>\n (\n evolutionNote.editMode\n ?\n <div key={evolutionNote.id} className={classes.evolutionNoteBox}>\n <div className={classes.accordionHeader}>\n <Typography className={classes.editEvolutionHeader}>\n {t(\"New evolution note\")}\n </Typography>\n\n <div className={classes.buttonArea}>\n <ButtonWithSpinner\n width={75}\n fill={ButtonPropsFill.Outlined}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray4}\n innerText={t(\"Cancel\")}\n onClick={() => handleCancelButtonEvolutionNoteModal(evolutionNote)}\n />\n\n {evolutionNote.id\n ? <ButtonWithSpinner\n width={75}\n fill={ButtonPropsFill.Outlined}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Update\")}\n onClick={() => { handleUpdateNoteButton(evolutionNote) }}\n disabled={evolutionNoteIsInvalid || showLoaderIsActive!}\n />\n : <ButtonWithSpinner\n width={75}\n fill={ButtonPropsFill.Outlined}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Save\")}\n onClick={() => { handleSaveNoteButton(evolutionNote) }}\n disabled={evolutionNoteIsInvalid || showLoaderIsActive!}\n />\n }\n </div>\n </div>\n <Typography className={classes.editorFieldHeader}>\n {t(\"Evolution note *\")}\n </Typography>\n <div className={`${classes.tinyMceOverrides} \n ${evolutionNoteTextLength > maxEditorTxtLength || evolutionNoteInputErrorHighlight ? classes.tinyMceValidationError : <></>} \n ${focusedEvolutionNoteInput ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"No notes\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\"\n }}\n value={evolutionNote.evolutionNoteText ?? \"\"}\n onInit={setEvolutionNotesTextLengthOnInit}\n onFocusIn={() => {\n setFocusedEvolutionNoteInput(true)\n }}\n onBlur={(ev, cont) => {\n handleEvolutionNoteEditorOnBlur(ev, cont)\n }}\n onKeyDown={(e) => {\n setEvolutionNoteInputErrorHighlight(false);\n }}\n onEditorChange={handleEditorEvolutionNoteTextChange}\n outputFormat=\"html\"\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{evolutionNoteTextLength + \"/\" + maxEditorTxtLength}</span>\n </div>\n </div>\n <Typography className={classes.editorFieldHeader}>\n {t(\"Diagnosis\")}\n </Typography>\n <div className={`${classes.tinyMceOverrides} \n ${diagnosisTextLength > maxEditorTxtLength ? classes.tinyMceValidationError : <></>} \n ${focusedDiagnosisInput ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"No notes\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n }}\n\n value={evolutionNote.diagnosis ?? \"\"}\n onFocusIn={() => {\n setFocusedDiagnosisInput(true)\n }}\n onBlur={() => {\n setFocusedDiagnosisInput(false)\n }}\n onInit={setDiagnosisTextLengthOnInit}\n onEditorChange={handleEditorDiagnosisChange}\n outputFormat=\"html\"\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{diagnosisTextLength + \"/\" + maxEditorTxtLength}</span>\n </div>\n </div>\n\n <Typography className={classes.editorFieldHeader}>\n {treatmentTerm}\n </Typography>\n {evolutionNote.treatments.sort((t1, t2) => t1.order! - t2.order!).map((treatment, index, treatments) => {\n return (\n <div className={classes.treatmentRow}>\n <div className={classes.treatmentInputContainer}>\n <Typography className={classes.treatmentFieldHeader}>\n {t(\"Medication\")}\n </Typography>\n <Input\n inputClass={classes.treatmentNameInput}\n value={treatment.medication}\n maxLength={500}\n width={\"100%\"}\n onChange={(e) => onHandleChangeTreatment(e, treatment, \"medication\")}\n />\n </div>\n <div className={classes.treatmentInputContainer}>\n <Typography className={classes.treatmentFieldHeader}>\n {t(\"Prescription\")}\n </Typography>\n <Input\n inputClass={classes.treatmentNameInput}\n value={treatment.prescription}\n maxLength={500}\n width={\"100%\"}\n onChange={(e) => onHandleChangeTreatment(e, treatment, \"prescription\")}\n />\n </div>\n {index + 1 === treatments.length &&\n <IconButton\n disableRipple\n className={`${classes.addTreatmentButton}`}\n onClick={handleAddTreatmentClick}\n >\n <div className={classes.iconPlus}>\n <PlusIcon style={{ color: \"#36CE91\", height: 20, width: 20 }} />\n </div>\n </IconButton>}\n {treatments.length > 1 &&\n <IconButton\n disableRipple\n className={`${classes.addTreatmentButton}`}\n onClick={() => {\n setTreatmentForRemove(treatment)\n setRemoveTreatmentModalIsOpen(true)\n }}\n >\n <div className={classes.iconRemove}>\n <DeleteIcon style={{ color: \"#36CE91\" }} />\n </div>\n </IconButton>}\n <ConfirmDeleteModal\n textButtonConfirm={t(\"Delete\")}\n classModal={classes.closeConfirmationModal}\n open={removeTreatmentModalIsOpen}\n item={treatment}\n componentInfo={<RemoveTreatmentModalContent />}\n onClose={() => {\n setTreatmentForRemove(undefined)\n setRemoveTreatmentModalIsOpen(false)\n }}\n onDelete={handleOnRemoveTreatmentConfirm}\n />\n </div>\n )\n })}\n\n <Typography className={classes.editorFieldHeader}>\n {t(\"Additional specialist instructions\")}\n </Typography>\n <div className={`${classes.tinyMceOverrides} \n ${additionalInstructionsTextLength > maxEditorTxtLength ? classes.tinyMceValidationError : <></>} \n ${focusedAdditionalInstructionsInput ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"Enter any additional instructions here\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n }}\n\n value={evolutionNote.additionalInstructions ?? \"\"}\n onFocusIn={() => {\n setFocusedAdditionalInstructionsInput(true)\n }}\n onBlur={() => {\n setFocusedAdditionalInstructionsInput(false)\n }}\n onInit={setAdditionalInstructionsTextLengthOnInit}\n onEditorChange={handleEditorAdditionalInstructionsChange}\n outputFormat=\"html\"\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{additionalInstructionsTextLength + \"/\" + maxEditorTxtLength}</span>\n </div>\n </div>\n\n <Typography className={classes.editorFieldHeader}>\n {t(\"Studies\")}\n </Typography>\n <Typography className={classes.carryOutTitle}>\n {t(\"Carry out:\")}\n </Typography>\n {evolutionNote.studies.sort((t1, t2) => t1.order! - t2.order!).map((study, index, studies) => {\n return <div>\n <Input\n inputClass={classes.treatmentNameInput}\n maxLength={600}\n value={study.name}\n width={\"87%\"}\n onChange={(e) => onHandleChangeStudy(e, study)}\n />\n {index + 1 === studies.length &&\n <IconButton\n disableRipple\n className={`${classes.addTreatmentButton}`}\n onClick={handleAddStudyClick}\n >\n <div className={classes.iconPlus}>\n <PlusIcon style={{ color: \"#36CE91\", height: 20, width: 20 }} />\n </div>\n </IconButton>}\n {studies.length > 1 &&\n <IconButton\n disableRipple\n className={`${classes.addTreatmentButton}`}\n onClick={() => {\n setStudyForRemove(study)\n setRemoveStudyModalIsOpen(true)\n }}\n >\n <div className={classes.iconRemove}>\n <DeleteIcon style={{ color: \"#36CE91\" }} />\n </div>\n </IconButton>}\n <ConfirmDeleteModal\n textButtonConfirm={t(\"Yes, delete\")}\n classModal={classes.closeConfirmationModal}\n open={removeStudyModalIsOpen}\n item={study}\n componentInfo={<RemoveStudyModalContent />}\n onClose={() => {\n setStudyForRemove(undefined)\n setRemoveStudyModalIsOpen(false)\n }}\n onDelete={handleOnRemoveStudyConfirm}\n />\n </div>\n })}\n <div className={classes.longSeparator} />\n <Typography className={classes.editEvolutionHeader} style={{ marginBottom: 32 }}>\n {t(vitalSignSectionName, { ns: sectionTNamespace })}\n </Typography>\n {evolutionNote.vitalSigns\n .sort((f1, f2) => f1.field.order - f2.field.order)\n .map(f => {\n if (f.field.isDeleted && f.value === null)\n return;\n else {\n const fieldAndValue = editableEvolutionNote?.vitalSigns.find(fv => fv.field.id === f.field.id);\n return <div className={classes.fieldEditionContainer}>\n {getInputForEditMode(fieldAndValue!)}\n </div>\n }\n })}\n\n <div className={classes.longSeparator} />\n <Typography className={classes.fileHeader}>\n {t(\"Files\")}\n </Typography>\n\n <Button\n className={`${classes.dropZone}`}\n onClick={() => setImportModalIsOpen(true)}\n >\n <div className={classes.uploadFileCloud}>\n <UploadFileCloud />\n </div>\n <div style={{ marginTop: 39 }}>\n {t(\"Click here to upload your file\")}\n </div>\n </Button>\n\n\n {evolutionNote.clinicalFiles.length > 0 &&\n <div className={classes.grid}>\n <GridListWithoutPagination\n columns={filesColumns}\n items={evolutionNote.clinicalFiles.sort(function (f1, f2) {\n let fileDate1 = isNaN((new Date(f1.created).getTime()))\n ? Number.MAX_VALUE\n : new Date(f1.created).getTime();\n let fileDate2 = new Date(f2.created).getTime();\n return fileDate2 - fileDate1\n })}\n height={\"auto\"}\n classRow={classes.classRow}\n />\n </div>\n }\n\n\n </div>\n :\n <div>\n <div className={classes.editModeNoteHeaderContainer}>\n <div className={classes.editModeNoteHeaderContainerChild}>\n <div>\n <Typography className={classes.editModeNoteFieldSmall}>\n {t(\"User\")}\n </Typography>\n <Typography className={classes.editModeNoteFieldBlue}>\n {evolutionNote.user}\n </Typography>\n </div>\n <div>\n <Typography className={classes.editModeNoteFieldSmall}>\n {t(\"Date and time of the appointment\")}\n </Typography>\n <Typography className={classes.editModeNoteFieldBlue}>\n {date(evolutionNote.appointmentDate)}\n </Typography>\n </div>\n <div>\n <Typography className={classes.editModeNoteFieldSmall}>\n {t(\"Date and time of the note\")}\n <IconTooltip\n classNameRoot={classes.iconTooltipRoot}\n icon={<InfoIcon style={{ width: 11, height: 11, marginLeft: 4 }} viewBox={\"0 0 11 11\"} />}\n tooltipText={t(\"Date and time of the creation of the evolution note.\")}\n />\n </Typography>\n <Typography className={classes.editModeNoteFieldBlue}>\n {date(evolutionNote.dateCreated)}\n </Typography>\n </div>\n </div>\n <div>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n fill={ButtonPropsFill.Outlined}\n innerText={t(\"Edit note\")}\n onClick={() => handleEditNoteButton(evolutionNote)}\n />\n </div>\n </div>\n <div className={classes.editModeSeparator} />\n <div style={{ padding: \"0px 16px\" }}>\n <div style={{ marginBottom: 24 }}>\n <Typography className={classes.editModeTitle}>\n {t(\"Evolution note\")}\n </Typography>\n <Typography className={classes.editModeSimpleText}>\n <div className={classes.editorContent} dangerouslySetInnerHTML={{ __html: evolutionNote.evolutionNoteText }} />\n </Typography>\n </div>\n {evolutionNote.diagnosis && <div style={{ marginBottom: 24 }}>\n <Typography className={classes.editModeTitle}>\n {t(\"Diagnosis\")}\n </Typography>\n <Typography className={classes.editModeSimpleText}>\n <div className={classes.editorContent} dangerouslySetInnerHTML={{ __html: evolutionNote.diagnosis }} />\n </Typography>\n </div>}\n {evolutionNote.treatments.length > 0 && <div style={{ marginBottom: 24 }}>\n <Typography className={classes.editModeTitle}>\n {treatmentTerm}\n </Typography>\n {renderTreatments(evolutionNote.treatments)}\n </div>}\n {evolutionNote.additionalInstructions && <div style={{ marginBottom: 24 }}>\n <Typography className={classes.editModeTitle}>\n {t(\"Additional specialist instructions\")}\n </Typography>\n <Typography className={classes.editModeSimpleText}>\n <div className={classes.editorContent} dangerouslySetInnerHTML={{ __html: evolutionNote.additionalInstructions }} />\n </Typography>\n </div>}\n {evolutionNote.treatments.length > 0 &&\n <div className={classes.pdfButtonsBlock}>\n <Button\n className={classes.pdfButton}\n onClick={() => handleSendPdfByWhatsAppClick(evolutionNote.id)}\n >\n {t(\"Send PDF by WhatsApp\")}\n </Button>\n <Button\n className={classes.pdfButton}\n onClick={() => handlePrintPdfClick(evolutionNote.id, fileDate(evolutionNote.appointmentDate ?? evolutionNote.dateCreated))}\n >\n {t(\"Print PDF\")}\n </Button>\n </div>\n }\n {evolutionNote.studies.length > 0 &&\n <div style={{ marginBottom: 24 }}>\n <Typography className={classes.editModeTitle}>\n {t(\"Studies\")}\n </Typography>\n {evolutionNote.studies.sort((t1, t2) => t1.order! - t2.order!).map((study) => {\n return <div>\n <Typography className={classes.editModeSimpleText}>\n {study.name}\n </Typography>\n </div>\n })}\n </div>\n }\n </div>\n {!evolutionNote.vitalSigns.filter(x => x.value).every(x => x.value === null) && <>\n <div className={classes.editModeSeparator} />\n <div style={{ padding: \"0px 16px\" }}>\n <Typography className={classes.editModeTitle} style={{ marginBottom: 6 }}>\n {t(vitalSignSectionName, { ns: sectionTNamespace })}\n </Typography>\n <div className={classes.fieldsContainer}>\n {evolutionNote.vitalSigns\n .sort((f1, f2) => f1.field.order - f2.field.order)\n .map((f, index) => {\n if (f.field.isDeleted && !f.value?.value)\n return;\n else\n return <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(f.field.name, { ns: sectionTNamespace })} <span className={classes.fieldNameAsterisk}>{f.field.isRequired ? \"*\" : \"\"}</span>\n </Typography>\n {getFieldValueComponent(f.value)}\n\n </div>\n })}\n </div>\n </div>\n </>}\n\n {evolutionNote.clinicalFiles.length > 0 && <>\n <div className={classes.editModeSeparator} />\n <div style={{ padding: \"0px 16px\" }}>\n <Typography className={classes.editModeTitle}>\n {t(\"Files\")}\n </Typography>\n </div>\n\n <div className={classes.gridShowMode}>\n <GridListWithoutPagination\n columns={filesColumns}\n items={evolutionNote.clinicalFiles.sort(function (f1, f2) {\n let fileDate1 = isNaN((new Date(f1.created).getTime()))\n ? Number.MAX_VALUE\n : new Date(f1.created).getTime();\n let fileDate2 = new Date(f2.created).getTime();\n return fileDate2 - fileDate1\n })}\n height={\"auto\"}\n classRow={classes.classRow}\n />\n </div>\n </>\n }\n {indexEvolutionNote === evolutionNoteGrouped.evolutionNotes.length - 1\n ? <></>\n : <div className={classes.longSeparator} />}\n </div>))\n }\n </div>\n </AccordionDetails>\n </Accordion>)\n )}\n </div>\n </>}\n <ConfirmActionModal\n classModal={classes.cancelEvolutionNoteConfirmationModal}\n content={<CancelNewEvolutionNoteModalContent />}\n open={cancelEvolutionNoteModalIsOpen}\n onClose={() => setCancelEvolutionNoteModalIsOpen(false)}\n onConfirm={handleOnConfirmCancelEvolutionNote}\n />\n <PatientImportEvolutionNoteClinicalFileModal\n open={importModalIsOpen}\n evolutionNote={editableEvolutionNote}\n onClose={() => setImportModalIsOpen(false)}\n ></PatientImportEvolutionNoteClinicalFileModal>\n <ConfirmDeleteModal\n textButtonConfirm={t(\"Delete\")}\n classModal={classes.closeConfirmationModal}\n open={deleteFileModalIsOpen}\n item={deletableFile}\n componentInfo={<RemoveFileModalContent />}\n onClose={() => {\n setDeleteFileModalIsOpen(false)\n setDeletableFile(undefined);\n }}\n onDelete={handleDeleteFile}\n />\n </div>\n );\n};\n\nexport default PatientEvolutionNotes;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n maxWidth: 320,\n display: \"flex\",\n flexDirection: \"column\",\n gap: 25,\n paddingRight: 25,\n marginBottom: 30\n },\n bodyItemsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 16,\n },\n itemContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 4\n },\n nameValueContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 6\n },\n statusIconContainer: {\n marginLeft: \"auto\"\n },\n phoneNumberContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 4,\n \"& svg\": {\n width: \"20px !important\", \n height: \"20px !important\"\n }\n },\n appointmentsFirstItemContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n appointmentsFirstItemContainerRow: {\n display: \"flex\",\n flexWrap: \"wrap\",\n textAlign: \"start\"\n },\n appointmentsFirstItemContainerItem: {\n width: \"50%\"\n },\n fieldNameLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4\n },\n fieldValueLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n fieldValueLink: {\n display: \"flex\",\n alignItems: \"center\",\n gap: 5\n },\n ageLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n phoneNumberCodeLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.clear2\n },\n appointmentsValueLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n fixedHeightLabelWrapper: {\n overflow: \"hidden\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\"\n },\n divider: {\n height: 0,\n borderTop: \"1px solid \" + Color.gray2,\n opacity: \"0.5\",\n },\n exportToPdfButton: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n gap: 5,\n\n width: 320,\n height: 32,\n\n borderRadius: 5,\n\n backgroundColor: theme.colors.clearMain,\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: theme.colors.grey1,\n\n cursor: \"pointer\",\n\n \"&:hover\": {\n background: theme.colors.clearMain,\n },\n },\n exportToPdfIcon: {\n marginRight: 5,\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = (firstItemComponentHeight: number) => makeStyles(() => ({\n root: {\n width: 320,\n \"& .MuiAccordion-root\": {\n border: \"1px solid \" + Color.gray2,\n borderRadius: 10,\n },\n \"& .MuiAccordionSummary-root\": {\n padding: \"5px 15px\",\n background: Color.gray1,\n position: \"static\",\n borderRadius: 10,\n transition: \"0.5s\",\n height: `calc(48px + ${firstItemComponentHeight}px)`\n },\n \"& .MuiAccordionSummary-root.Mui-expanded\": {\n minHeight: 0,\n },\n \"& .MuiAccordionSummary-content\": {\n margin: 0,\n },\n \"& .MuiAccordionSummary-content.Mui-expanded\": {\n margin: 0\n },\n \"& .MuiPaper-elevation1\": {\n boxShadow: \"none\"\n },\n \"& .MuiAccordionSummary-expandIcon\": {\n position: \"absolute\",\n top: \"5px\",\n right: \"18px\"\n },\n \"& .MuiAccordionDetails-root\": {\n padding: \"0px 16px 16px 16px\"\n },\n \"& .MuiButtonBase-root\": {\n cursor: \"pointer !important\"\n },\n \"& .MuiAccordionSummary-root:hover:not(.Mui-disabled)\": {\n cursor: \"default !important\"\n }\n },\n headerTitleContainer: {\n background: Color.gray1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n gap: 8,\n height: 48,\n position: \"absolute\",\n top: 0\n },\n headerLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.clear2,\n },\n allItemsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n headerItemContainer: {\n maxWidth: \"100%\",\n background: Color.white,\n position: \"absolute\",\n top: 48,\n left: 0,\n right: 0,\n height: firstItemComponentHeight,\n borderRadius: \"0px 0px 10px 10px\",\n padding: 16\n }, \n headerButton: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n },\n divFlag: {\n display: \"inline-block\",\n position: \"relative\",\n height: 20,\n width: 20,\n \"& svg\": {\n width: \"20px !important\",\n height: \"20px !important\"\n }\n },\n divCode: {\n position: \"relative\",\n display: \"inline-block\",\n fontStyle: \"normal\",\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"normal\",\n width: 40,\n textAlign: \"center\",\n fontSize: 14\n },\n divMobile: {\n display: \"inline-block\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 14,\n },\n itemTitleLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4,\n },\n itemValueLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n },\n divider: {\n height: 0,\n borderTop: \"1px solid \" + Color.gray2,\n opacity: \"0.5\",\n marginBottom: \"16px\",\n }\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { DataAccordionProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport { Accordion, AccordionDetails, AccordionSummary, Button, Typography } from \"@material-ui/core\";\nimport { ArrowDownIcon} from \"../../../assets/icons\";\nimport { Color } from \"../../../constants/colors\";\n\n\nexport default function DataAccordion(props: DataAccordionProps) {\n const {\n headerIcon,\n title,\n firstItemComponent,\n firstItemComponentHeight,\n bodyItems,\n isExpandedByDefault,\n ...otherProps\n } = props;\n\n const classes = useStyles(firstItemComponentHeight)();\n\n const [expanded, setExpanded] = useState<boolean>(isExpandedByDefault ?? false);\n\n const toggleAccordion = () => {\n setExpanded((prev) => !prev)\n }\n\n const getBodyItems = () => {\n return bodyItems\n ? <>\n <div className={classes.divider}></div>\n {bodyItems}\n </>\n : <></>\n }\n\n return <>\n <div className={classes.root}>\n <Accordion\n expanded={bodyItems ? expanded : false}\n >\n <AccordionSummary\n expandIcon={bodyItems ? <ArrowDownIcon style={{ height: 15, width: 15, color: Color.clear1 }} /> : <></>}\n IconButtonProps={{\n onClick: toggleAccordion,\n disabled: !bodyItems\n }}\n >\n <div className={classes.headerTitleContainer}>\n {headerIcon}\n <Typography className={classes.headerLabel}>\n {title}\n </Typography>\n </div>\n <div className={classes.headerItemContainer}>\n {firstItemComponent}\n </div>\n </AccordionSummary>\n <AccordionDetails className={classes.allItemsContainer}>\n {getBodyItems()}\n </AccordionDetails>\n </Accordion>\n </div>\n </>\n};","import React, { useEffect, useState, forwardRef, useImperativeHandle } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { conformToMask } from \"react-text-mask\";\nimport { format } from 'date-fns';\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../redux/store\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport useStyles from \"./css\";\nimport { PatientDataProps } from \"./props\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { StatusIcon, PatientGeneralDataIcon, PatientMaleIcon, PatientFemaleIcon, PatientContactIcon, PatientAppointmentsIcon, PatientServicesIcon, PatientStethoscopeIcon, ExportFileIcon } from \"../../../assets/icons\";\nimport CountryFlagIcon from \"../../../assets/flags\";\n\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { Gender } from \"../../../models/enums/gender\";\nimport { PatientDataResponse } from \"../../../models/patient-data-response\";\nimport { EvolutionNoteFieldAndValue } from \"../../../models/evolution-note-field-and-value\";\nimport { SectionFieldType } from \"../../../models/enums/section-field-type\";\nimport { FormPhoneNumberValue } from \"../../../models/form-phone-number-value\";\nimport { FormRadioValue } from \"../../../models/form-radio-value\";\n\nimport DataAccordion from \"../../common/DataAccordion\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport CustomerDetailsRefs from \"../CustomerDetails/customer-details-refs\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport { CircularProgress } from \"@material-ui/core\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\nimport { Color } from \"../../../constants/colors\";\n\n\nconst PatientData = forwardRef<CustomerDetailsRefs, any>((props: PatientDataProps, ref) => {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { customerId } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const [patientData, setPatientData] = useState<PatientDataResponse>(new PatientDataResponse());\n const [isPdfDownloading, setIsPdfDownloading] = useState<boolean>(false);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const userInfo = useAppSelector(selectUserInfo);\n const hasCustomerInfoVisible = userInfo.hasCustomerInfoVisible;\n const canSeeClinicalFile = userInfo.canSeeClinicalFile;\n \n //to make the \"updateVitalSigns\" function callable from the parent component\n useImperativeHandle(ref, () => ({\n updateVitalSigns: async () => {\n await loadData();\n }\n }));\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n\n fetchData();\n }, []);\n\n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const response = await CustomerService.getPatientData(customerId);\n\n const countries = accountSettings.countries;\n let mobileCode = response.mobileCodeIso3 ?? \"MEX\";\n response.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n response.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n response.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n\n dispatch(navbarActions.setShowLoader(false));\n setPatientData(response);\n };\n \n async function handleDownloadPdfClick() {\n if (isPdfDownloading)\n return;\n \n setIsPdfDownloading(true);\n \n try {\n const blob = await CustomerService.getPatientClinicalFilePdf(customerId);\n const url = window.URL.createObjectURL(new Blob([blob], {\n type: \"application/pdf\"\n }));\n const link = document.createElement('a');\n const name = `${t(\"Patient clinical file\")} - ${patientData.firstName} ${patientData.lastName} - ${format(new Date(), t(\"clinical_file_date_format\"), {locale:getLocale()})}`;\n link.href = url;\n link.setAttribute('download', `${name}.pdf`);\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n }\n finally {\n setIsPdfDownloading(false);\n }\n }\n \n const tryGetGenderIcon = () => {\n if (!patientData.gender)\n return <></>\n if (patientData.gender === Gender.Male)\n return <PatientMaleIcon />\n if (patientData.gender === Gender.Female)\n return <PatientFemaleIcon />\n };\n\n const tryGetAgeLabel = () => {\n if (!patientData.dateOfBirth)\n return <></>\n\n return <Typography className={classes.ageLabel}>\n {getAge(patientData.dateOfBirth) + \" \" + t(\"years\")}\n </Typography>\n };\n\n const getAge = (birthDate: Date): number => {\n const dob = new Date(birthDate);\n //calculate month difference from current date in time\n const month_diff = Date.now() - dob.getTime();\n\n //convert the calculated difference in date format\n const age_dt = new Date(month_diff);\n\n //extract year from date\n const year = age_dt.getUTCFullYear();\n\n //now calculate the age of the user\n return Math.abs(year - 1970);\n };\n\n const getDateOfBirthString = () => {\n const newDateObj = new Date(patientData.dateOfBirth!);\n const day = newDateObj.toLocaleString(localeApp, { day: \"numeric\" });\n const month = newDateObj.toLocaleString(localeApp, { month: \"long\", });\n const year = newDateObj.toLocaleString(localeApp, { year: \"numeric\", });\n\n return localeApp === \"es\"\n ? `${day}/${month}/${year}`\n : `${month.charAt(0).toUpperCase() + month.slice(1)}/${day}/${year}`;\n };\n\n const getEvolutionNoteLastUpdatedString = () => {\n if (!patientData.evolutionNoteFieldsLastUpdated)\n return \"--\";\n\n const newDateObj = new Date(patientData.evolutionNoteFieldsLastUpdated);\n const time = newDateObj.toLocaleTimeString(\"es\", { timeStyle: \"short\" })\n const day = newDateObj.toLocaleString(localeApp, { day: \"2-digit\" });\n const month = newDateObj.toLocaleString(localeApp, { month: \"long\", });\n const year = newDateObj.toLocaleString(localeApp, { year: \"numeric\", });\n\n return localeApp === \"es\"\n ? `${day}/${month}/${year} - ${time}hrs`\n : `${month.charAt(0).toUpperCase() + month.slice(1)}/${day}/${year} - ${time}hrs`;\n };\n \n function getLocale(): any {\n switch (localeApp) {\n case \"es\":\n return esLocale;\n \n default:\n return enLocale;\n }\n }\n \n const getFieldValueComponent = (fv: EvolutionNoteFieldAndValue) => {\n if (!fv?.value?.value)\n return <Typography className={classes.fieldValueLabel}>\n {\"--\"}\n </Typography>;\n\n switch (fv.value.type) {\n case SectionFieldType.Text:\n return <Typography className={classes.fieldValueLabel}>\n {t(fv.value.value as string, { ns: sectionTNamespace })}\n </Typography>;\n case SectionFieldType.Email:\n return <Typography className={classes.fieldValueLabel}>\n {t(fv.value.value as string, { ns: sectionTNamespace })}\n </Typography>;\n case SectionFieldType.PhoneNumber:\n const phoneValue = fv.value.value as FormPhoneNumberValue;\n const country = accountSettings.countries.find(c => c.iso3 === phoneValue.countryIso);\n return <div className={classes.phoneNumberContainer}>\n <CountryFlagIcon iso={phoneValue.countryIso} />\n <Typography className={classes.phoneNumberCodeLabel}>\n {\"+\" + country!.dialCode}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {conformToMask(phoneValue.body, GetMobileMaskByTemp(country!.dialTemplate)).conformedValue}\n </Typography>\n </div>\n case SectionFieldType.Radio:\n return <Typography className={classes.fieldValueLabel}>\n {t((fv.value.value as FormRadioValue)?.item?.value ?? \"--\", { ns: sectionTNamespace })}\n {!!(fv.value.value as FormRadioValue).additionalFreeTextValue &&\n <> / {(fv.value.value as FormRadioValue).additionalFreeTextValue}</>\n }\n </Typography>;\n };\n }\n\n const PatientFirstItem: React.FC = () => {\n return <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Name\")}\n </Typography>\n <div className={classes.nameValueContainer}>\n {tryGetGenderIcon()}\n <Typography className={`${classes.fieldValueLabel} ${classes.fixedHeightLabelWrapper}`}>\n {patientData.firstName + \" \" + patientData.lastName}\n </Typography>\n <div className={classes.statusIconContainer}>\n <StatusIcon status={patientData.customerFrequency} />\n </div>\n </div>\n {tryGetAgeLabel()}\n </div>\n };\n\n const PatientBody: React.FC = () => {\n return (\n <div className={classes.bodyItemsContainer}>\n {!!patientData.dateOfBirth &&\n <>\n <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Date of birth\")}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {getDateOfBirthString()}\n </Typography>\n </div>\n </>\n }\n </div>\n )\n };\n\n const ContactFirstItem: React.FC = () => {\n return <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Mobile\")}\n </Typography>\n {patientData.mobile && hasCustomerInfoVisible\n ? <div className={classes.phoneNumberContainer}>\n <CountryFlagIcon iso={patientData.mobileCodeIso3} />\n <Typography className={classes.phoneNumberCodeLabel}>\n {\"+\" + patientData.mobileCode}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patientData.mobile ? conformToMask(patientData.mobile, GetMobileMaskByTemp(patientData.mobileTemplate)).conformedValue : \"--\"}\n </Typography>\n </div>\n : <Typography className={classes.fieldValueLabel}>\n {\"--\"}\n </Typography>}\n </div>\n };\n\n const ContactBody: React.FC = () => {\n return <div className={classes.bodyItemsContainer}>\n {patientData.email && hasCustomerInfoVisible\n ? <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Email\")}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patientData.email}\n </Typography>\n </div>\n : <></>}\n <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Contactable\")}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patientData.contactable ? t(\"Yes\") : t(\"No\")}\n </Typography>\n </div>\n </div>\n };\n\n const AppointmentsFirstItem: React.FC = () => {\n return <div className={classes.appointmentsFirstItemContainer}>\n <div className={classes.appointmentsFirstItemContainerRow}>\n <Typography className={`${classes.fieldNameLabel} ${classes.appointmentsFirstItemContainerItem}`}>\n {useCustomerTerminology(t(\"Customer arrived\"), \"Customer\")}\n </Typography>\n <Typography className={`${classes.fieldNameLabel} ${classes.appointmentsFirstItemContainerItem}`}>\n {t(\"Created\")}\n </Typography>\n </div>\n <div className={classes.appointmentsFirstItemContainerRow}>\n <Typography className={`${classes.appointmentsValueLabel} ${classes.appointmentsFirstItemContainerItem}`}>\n {patientData.arrivedAppointmentsCount}\n </Typography>\n <Typography className={`${classes.appointmentsValueLabel} ${classes.appointmentsFirstItemContainerItem}`}>\n {patientData.totalAppointmentsCount}\n </Typography>\n </div>\n </div>\n };\n\n const ServicesFirstItem: React.FC = () => {\n return <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Favorite\")}\n </Typography>\n <Typography className={`${classes.fieldValueLabel} ${classes.fixedHeightLabelWrapper}`}>\n {patientData.favoriteServiceName ? patientData.favoriteServiceName : \"--\"}\n </Typography>\n </div>\n };\n\n const ServicesBody: React.FC = () => {\n return <div className={classes.bodyItemsContainer}>\n <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Times requested\")}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patientData.favoriteServiceRequestedCount}\n </Typography>\n </div>\n <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Total services performed\")}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patientData.totalServicesCount}\n </Typography>\n </div>\n </div>\n };\n\n const EvolutionNoteFieldsAccordion: React.FC = () => {\n if (!patientData.evolutionNoteSectionName)\n return <></>\n return <DataAccordion\n headerIcon={<PatientStethoscopeIcon />}\n title={t(patientData.evolutionNoteSectionName, { ns: sectionTNamespace })}\n firstItemComponent={<EvolutionNoteFirstItem />}\n firstItemComponentHeight={65}\n bodyItems={<EvolutionNoteBody />} />\n };\n\n const EvolutionNoteFirstItem: React.FC = () => {\n return <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"Last update\")}\n </Typography>\n <Typography className={`${classes.fieldValueLabel} ${classes.fixedHeightLabelWrapper}`}>\n {getEvolutionNoteLastUpdatedString()}\n </Typography>\n </div>\n };\n\n const EvolutionNoteBody: React.FC = () => {\n return <div className={classes.bodyItemsContainer}>\n {patientData.evolutionNoteFieldsValues!\n .sort((fv1, fv2) => fv1.field.order - fv2.field.order)\n .map(fv => <div className={classes.itemContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(fv.field.name, { ns: sectionTNamespace })}\n </Typography>\n {getFieldValueComponent(fv)}\n </div>)}\n </div>\n };\n\n\n return (\n <div className={classes.root}>\n <DataAccordion\n headerIcon={<PatientGeneralDataIcon />}\n title={t(\"Patient\")}\n firstItemComponent={<PatientFirstItem />}\n firstItemComponentHeight={patientData.dateOfBirth ? 90 : 70}\n bodyItems={<PatientBody />}\n />\n <DataAccordion\n headerIcon={<PatientContactIcon />}\n title={t(\"Contact\")}\n firstItemComponent={<ContactFirstItem />}\n firstItemComponentHeight={68}\n bodyItems={<ContactBody />}\n />\n <EvolutionNoteFieldsAccordion />\n <DataAccordion\n headerIcon={<PatientAppointmentsIcon />}\n title={t(\"Appointments\")}\n firstItemComponent={<AppointmentsFirstItem />}\n firstItemComponentHeight={65}\n />\n <DataAccordion\n headerIcon={<PatientServicesIcon />}\n title={t(\"Services\")}\n firstItemComponent={<ServicesFirstItem />}\n firstItemComponentHeight={65}\n bodyItems={<ServicesBody />}\n />\n {\n canSeeClinicalFile &&\n <Button\n className={classes.exportToPdfButton}\n onClick={handleDownloadPdfClick}\n >\n <div className={classes.exportToPdfIcon}>\n {isPdfDownloading\n ? <CircularProgress size=\"12px\" color=\"inherit\" />\n : <ExportFileIcon color={Color.gray1} />\n }\n </div>\n {t(\"Export clinical file to PDF\")}\n </Button>\n }\n </div>\n );\n});\n\nexport default PatientData;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: { display: \"flex\" },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n customerInfoPanel: {\n //height: 560,\n position: \"absolute\",\n width: 779,\n overflow: \"hidden\",\n },\n customerInfoPanelContent: {\n overflowY: \"scroll\",\n maxHeight: \"calc(100vh - 152px)\",\n padding: \"28px 28px 0px 28px\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n customerDetails: {\n width: 779,\n height: 610,\n margin: \"0px 0px 0px 36px\",\n },\n customerDetailsContent: {\n width: 779,\n height: 610,\n borderRadius: 12,\n border: \"1px solid #DBDCDD\",\n backgroundColor: \"#FFF\",\n boxShadow: \"none\",\n },\n customerInfoTitle: {\n display: \"flex\",\n alignItems: \"center\",\n },\n customerInfoContent: {\n margin: \"20px 0px 0px 0px\",\n },\n infoContentRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n infoContentFields: {\n display: \"flex\",\n flexWrap: \"wrap\",\n justifyContent: \"space-between\",\n \"& > div\": {\n marginTop: 24\n }\n },\n contactRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n marginTop: 10\n },\n iconTitle: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n margin: \"0px 0px 0px 10px\",\n },\n caption: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n width: 228,\n margin: \"0px\",\n },\n captionValue: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n width: 228,\n margin: \"0px\",\n },\n captionValueTextArea: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n minWidth: 228,\n margin: \"0px\",\n },\n detailsActions: {\n position: \"absolute\",\n bottom: theme.spacing(4),\n right: theme.spacing(2),\n zIndex: 999\n },\n floatButton: {\n borderRadius: 51,\n textTransform: \"none\",\n boxShadow: \"none\",\n display: \"inline-block\",\n padding: \"0px 16px\",\n },\n floatButtonTxt: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n display: \"inline-block\",\n },\n editButton: {\n height: 32,\n background: \"#F6F6F6\",\n color: \"#6462F3\",\n \"&:hover\": {\n background: \"#6462F3\",\n color: \"#F6F6F6\",\n },\n },\n saveButton: {\n height: 32,\n background: \"#F6F6F6\",\n color: \"#36CE91\",\n \"&:hover\": {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n },\n },\n cancelButton: {\n marginRight: 24,\n height: 32,\n background: \"#F6F6F6\",\n color: \"#5C6477\",\n \"&:hover\": {\n background: \"#5C6477\",\n color: \"#F6F6F6\",\n },\n },\n lastRow: {\n marginBottom: 98,\n },\n addContactButton: {\n width: 137,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n border: \"1px solid #6462F3\",\n marginRight: 25,\n color: \"#6462F3\",\n textTransform: \"none\",\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n minHeight: 288,\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n margin: \"24px 0px 8px 0px\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteContact: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n divFlag: {\n display: \"inline-block\",\n position: \"relative\",\n height: 20,\n width: 20,\n \"& svg\": {\n width: \"20px !important\", \n height: \"20px !important\"\n }\n },\n divCode: {\n position: \"relative\",\n display: \"inline-block\",\n fontStyle: \"normal\",\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"normal\",\n width: 40,\n textAlign: \"center\",\n fontSize: 14\n },\n divMobile: {\n display: \"inline-block\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 14,\n }\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n // justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n spaceBetween: {\n marginRight: 24,\n },\n deleteContactDiv: {\n paddingTop: 25,\n },\n deleteContactButton: {\n \"&:hover\": {\n cursor: \"pointer\",\n },\n },\n required: {\n color: \"#6462F3\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport InputWithLabel from \"./../../common/InputWithLabel\";\nimport DeleteIcon from \"./../../../assets/icons/DeleteIcon\";\n\nimport { EmergencyContact } from \"../../../models/emergency-contact\";\nimport { NameRegex } from \"../../../constants/validator\";\nimport InputMobileCode from \"../../common/InputMobileCode\";\n\nimport { CustomerEmergencyContactsProps } from \"./props\";\nimport useStyles from \"./css\";\nimport Country from \"../../../models/country\";\n\nconst CustomerEmergencyContacts = (props: CustomerEmergencyContactsProps) => {\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const { zIndex, value, onChange, onDelete } = props;\n const [contact, setContact] = useState<EmergencyContact>(\n value || new EmergencyContact()\n );\n const [contactValid, setContactValid] =\n useState<{ name?: boolean; relationship?: boolean; mobile?: boolean }>();\n\n useEffect(() => {\n if (value && JSON.stringify(value) !== JSON.stringify(contact)) {\n setContact(value);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [value]);\n\n useEffect(() => {\n if (onChange) {\n onChange(contact);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [contact, contactValid]);\n\n const handleNameChange = (event: any) => {\n setContactValid({\n ...contactValid,\n name: NameRegex.test(event.target.value),\n });\n setContact({ ...contact, name: event.target.value });\n };\n\n const handleRelationshipChange = (event: any) => {\n setContactValid({\n ...contactValid,\n relationship: NameRegex.test(event.target.value),\n });\n setContact({ ...contact, relationship: event.target.value });\n };\n\n const handleMobileChange = (mobile: any) => {\n setContact({\n ...contact,\n mobile\n });\n };\n\n const handlerOnDelete = () => {\n if (onDelete) {\n onDelete(contact);\n }\n };\n \n const handleMobileCodeChange = (item: Country) => {\n setContact({\n ...contact,\n mobileCodeIso3: item.iso3,\n mobileDigits: item.dialDigits,\n mobileCode: item.dialCode\n });\n };\n\n const handleValidMobile = (valid: boolean) => {\n setContactValid({\n ...contactValid,\n mobile: valid\n });\n }\n\n return (\n <div className={classes.root} >\n <div className={classes.spaceBetween}>\n <InputWithLabel\n label={() => (\n <>\n {t(\"Name\")} <span className={classes.required}>*</span>\n </>\n )}\n placeholder={t(\"Enter the contact name\")}\n value={contact?.name || \"\"}\n width={200}\n isValid={() => contactValid?.name}\n onChange={handleNameChange}\n />\n </div>\n <div className={classes.spaceBetween}>\n <InputWithLabel\n label={() => (\n <>\n {t(\"Relationship\")} <span className={classes.required}>*</span>\n </>\n )}\n placeholder={t(\"Enter the relationship of the contact\")}\n value={contact?.relationship || \"\"}\n width={200}\n isValid={() => contactValid?.relationship}\n onChange={handleRelationshipChange}\n />\n </div>\n <div className={classes.spaceBetween} style={{zIndex: 1000-zIndex!}}>\n \n <InputMobileCode \n isOptional={false} \n widthSelect={228} \n widthList={280}\n isValid={handleValidMobile}\n label={t(\"Mobile Number\")}\n onChangeItem={handleMobileCodeChange}\n onChangeMobile={handleMobileChange}\n codeIso3={contact?.mobileCodeIso3!}\n mobile={contact?.mobile!} />\n \n </div>\n <div className={classes.deleteContactDiv}>\n <span className={classes.deleteContactButton} onClick={handlerOnDelete}>\n <DeleteIcon />\n </span>\n </div>\n </div>\n );\n};\n\nexport default CustomerEmergencyContacts;\n","import React, { } from \"react\";\n\nimport CustomerEmergencyContacts from \"./../CustomerEmergencyContacts\";\n\nimport { CustomerEmergencyContactListProps } from \"./props\";\n\nconst CustomerEmergencyContactList = (\n props: CustomerEmergencyContactListProps\n) => {\n const { list, onChange, onDelete } = props;\n\n return (\n <>\n {list.map((contact, index) => (\n <CustomerEmergencyContacts\n zIndex={index}\n key={index}\n value={contact}\n onChange={(contact) => {\n onChange(contact, index);\n }}\n onDelete={(contact) => {\n onDelete(contact, index);\n }}\n />\n ))}\n </>\n );\n};\n\nexport default CustomerEmergencyContactList;\n","import { EmergencyContact } from \"./emergency-contact\";\n\nexport class CreateEmergencyContacts {\n customerId: string | null;\n emergencyContacts: EmergencyContact[] | null;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.customerId = x.customerId;\n this.emergencyContacts = x.emergencyContacts;\n } else {\n this.customerId = null;\n this.emergencyContacts = null;\n }\n }\n}\n","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport InputWithLabel from \"../../common/InputWithLabel\";\n\nimport { CustomerEntity } from \"../../../models/customer-entity\";\n\nimport useStyles from \"./css\";\nimport { CustomerInformationTabProps } from \"./props\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\nimport { EmailRegex, MultipleSpacesNameRegex, NameRegex } from \"../../../constants/validator\";\nimport { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport {\n CrossIcon,\n EditIcon,\n GroupIcon,\n NoteIcon,\n PhoneIcon,\n PlusIcon,\n SaveIcon,\n TrashIcon\n} from \"../../../assets/icons\";\nimport TabPanel from \"../../common/tabs/TabPanel\";\nimport CustomerEmergencyContactList from \"../CustomerEmergencyContactList\";\nimport CustomerGeneral from \"../CustomerGeneral\";\nimport { ApiClient } from \"../../../api/api-client\";\nimport { Gender } from \"../../../models/enums/gender\";\nimport { EmergencyContact } from \"../../../models/emergency-contact\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { CreateEmergencyContacts } from \"../../../models/create-emergency-contacts\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport { conformToMask } from \"react-text-mask\";\nimport CountryFlagIcon from \"../../../assets/flags\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { CustomerInfoDetails } from \"../../../models/customer-info-details\";\nimport { useHistory } from \"react-router-dom\";\nimport { Url } from \"../../../constants/url\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport BellIcon from \"../../../assets/icons/BellIcon\";\nimport CustomerNotifications from \"../CustomerNotifications\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\n\nconst CustomerInformationTab = (props: CustomerInformationTabProps) => {\n const { customerId, customer, currentTabIndex, setCustomer } = props;\n\n const hasCustomerInfoVisible = ApiClient.getUserInfo().hasCustomerInfoVisible;\n const { t } = useTranslation([\"general\"]);\n const history = useHistory();\n const classes = useStyles();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n const appDispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const [isValid, _setIsValid] = useState<boolean>(true);\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [emergencyContact, setEmergencyContact] = useState<EmergencyContact>();\n const [contactIndex, setContactIndex] = useState<number>(0);\n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [contacts, setContacts] = useState<EmergencyContact[]>([]);\n const [contactsCopy, setContactsCopy] = useState<EmergencyContact[]>([]);\n const [contactDeleted, setContactDeleted] = useState<EmergencyContact[]>([]);\n const [customerValid, setCustomerValid] = useState<boolean>(false);\n const [contactValid, setContactValid] = useState<boolean>(false);\n const [isEdition, setIsEdition] = useState<boolean>(false);\n const [customerCopy, setCustomerCopy] = useState<CustomerInfoDetails | null>(null);\n\n\n const isValidRef = useRef(isValid);\n const customerRef = useRef(customer);\n const innerSetCustomer = (data: CustomerInfoDetails) => {\n customerRef.current = data;\n setCustomer(data);\n };\n\n const [isDuplicated, setIsDuplicated] = useState<boolean>(false);\n const mobileTemplate: string = \"000-000-0000\";\n\n const [loadedGeneral, setLoadedGeneral] = useState<boolean>(false);\n const [loadedContacts, setLoadedContacts] = useState<boolean>(false);\n const [changed, setChanged] = useState<boolean>(false);\n\n const setIsValid = (data: boolean) => {\n isValidRef.current = data;\n _setIsValid(data);\n };\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n\n fetchData();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n useEffect(() => {\n setIsValid(customerValid && contactValid);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [customerValid, contactValid]);\n\n\n useEffect(() => {\n\n let validContacts = true;\n\n if (contacts.length !== 0)\n for (let c of contacts) {\n if (!NameRegex.test(c?.name || \"\") ||\n !NameRegex.test(c?.relationship || \"\") ||\n !validateMobile(c)\n ) {\n validContacts = false;\n break;\n }\n }\n\n setContactValid(validContacts);\n innerSetCustomer({ ...customer, emergencyContacts: contacts });\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [contacts]);\n\n const validateMobile = (c: EmergencyContact | CustomerInfoDetails | CustomerEntity): boolean => {\n const digits: number = c.mobileDigits!;\n let mobile: string = c.mobile!;\n if (mobile) mobile = mobile.length > 0 ? mobile.substring(0, digits) : mobile;\n const validDig = (digits === 7 && /^\\d{7}$/.test(mobile!)) ||\n (digits === 8 && /^\\d{8}$/.test(mobile!)) ||\n (digits === 9 && /^\\d{9}$/.test(mobile!)) ||\n (digits === 10 && /^\\d{10}$/.test(mobile!)) ||\n (digits === 11 && /^\\d{11}$/.test(mobile!)) ||\n (digits === 12 && /^\\d{12}$/.test(mobile!));\n\n return validDig;\n }\n\n const listener = (event: any) => {\n if (event.key === \"Enter\" || event.key === \"NumpadEnter\") {\n const fetchData = async () => {\n if (customerRef.current && isValidRef.current) {\n // await CustomerService.updateCustomer(customerRef.current);\n const customerSaved = await updateData(customerRef.current);\n\n if (customerSaved.isMobileDuplicate) {\n\n showDuplicated(customerSaved);\n\n } else {\n\n await CustomerService.createEmergencyContacts(\n new CreateEmergencyContacts({\n customerId: customerRef.current.id,\n emergencyContacts: customerRef.current.emergencyContacts,\n })\n );\n setIsEdition((currentIsEdition) => false);\n\n }\n\n }\n };\n\n fetchData();\n }\n };\n\n useEffect(() => {\n\n if (isEdition) {\n window.addEventListener(\"keypress\", listener);\n } else {\n window.removeEventListener(\"keypress\", listener);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isEdition]);\n\n useEffect(() => {\n if (accountSettings.countries.length && customerCopy) {\n fillMobileData(customerCopy);\n setCustomerCopy(customerCopy);\n innerSetCustomer(customerCopy);\n setCustomerCopy(customerCopy);\n setContacts(customerCopy.emergencyContacts || []);\n setContactsCopy(customerCopy.emergencyContacts || []);\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [accountSettings.countries]);\n \n\n function fillMobileData(customerData: CustomerInfoDetails) {\n const countries = accountSettings.countries;\n let mobileCode = customerData.mobileCodeIso3 ?? \"MEX\";\n customerData.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n customerData.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n customerData.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n\n if (customerData.emergencyContacts?.length) {\n [...customerData.emergencyContacts].map(emergencyContact => {\n emergencyContact.mobileDigits = countries.find(x => x.iso3 === emergencyContact.mobileCodeIso3)!.dialDigits;\n emergencyContact.mobileCode = countries.find(x => x.iso3 === emergencyContact.mobileCodeIso3)!.dialCode;\n emergencyContact.mobileTemplate = countries.find(x => x.iso3 === emergencyContact.mobileCodeIso3)!.dialTemplate.toString();\n return customer;\n })\n }\n fillData(customerData);\n }\n\n const loadData = async () => {\n let customerData;\n if (!customerCopy) {\n appDispatch(navbarActions.setShowLoader(true));\n customerData = await CustomerService.getCustomerInfoDetails(customerId);\n appDispatch(navbarActions.setShowLoader(false));\n if (accountSettings.countries.length) {\n fillMobileData(customerData);\n }\n \n setCustomerCopy(customerData);\n } else {\n customerData = customerCopy;\n }\n\n await fillData(customerData);\n };\n\n const fillData = async (customerData: CustomerInfoDetails) => {\n innerSetCustomer(customerData);\n setContacts(customerData.emergencyContacts || []);\n setContactsCopy(customerData.emergencyContacts || []);\n\n let titleNav =\n t(\"Customer detail\") +\n \" / \" +\n customerData.firstName +\n \" \" +\n customerData.lastName;\n appDispatch(applicationInterfaceActions.updateTitle(titleNav));\n setLoadedGeneral(true);\n setLoadedContacts(true);\n };\n\n const updateData = async (customer: any) => {\n const responseCustomer = await CustomerService.updateCustomer(customer);\n responseCustomer.mobileTemplate =\n accountSettings.countries.find(c => c.iso3 === responseCustomer.mobileCodeIso3)!.dialTemplate;\n return responseCustomer;\n };\n\n const date = (created: Date | null | undefined): string => {\n if (!created) {\n return \"\";\n }\n\n const createdDate = new Date(created);\n const day = createdDate.toLocaleString(\n localeApp,\n {\n day: \"numeric\",\n }\n );\n\n let month = createdDate.toLocaleString(\n localeApp,\n {\n month: \"long\",\n }\n );\n\n month = month.charAt(0).toUpperCase() + month.slice(1);\n\n const year = createdDate.toLocaleString(\n localeApp,\n {\n year: \"numeric\",\n }\n );\n\n return `${day} / ${month} / ${year}`;\n };\n\n const gender = (gender: Gender | null | undefined): string | null => {\n switch (gender) {\n case Gender.Female:\n return t(\"Female\");\n case Gender.Male:\n return t(\"Male\");\n case Gender.PreferNotToSay:\n return t(\"I prefer not to say\");\n case Gender.Custom:\n return t(\"gender_custom\");\n default:\n return null;\n }\n };\n\n const handleSave = async () => {\n const customerSaved = await updateData(customer);\n\n if (customerSaved.isMobileDuplicate) {\n\n showDuplicated(customerSaved);\n\n } else {\n\n if (contacts.length) {\n let emergencyContact = await createEmergencyContacts();\n customerSaved.emergencyContacts = [...emergencyContact];\n if (customerSaved.emergencyContacts?.length) {\n const countries = accountSettings.countries;\n [...customerSaved.emergencyContacts].map(emergencyContact => {\n emergencyContact.mobileDigits = countries.find(x => x.iso3 === emergencyContact.mobileCodeIso3)!.dialDigits;\n emergencyContact.mobileCode = countries.find(x => x.iso3 === emergencyContact.mobileCodeIso3)!.dialCode;\n emergencyContact.mobileTemplate = countries.find(x => x.iso3 === emergencyContact.mobileCodeIso3)!.dialTemplate.toString();\n return customer;\n })\n }\n }\n\n if (contactDeleted.length) {\n await deleteEmergencyContacts();\n }\n\n setIsEdition(!isEdition);\n appDispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Customer Updated\"),\n description: `${customer.firstName} ${customer.lastName}`\n })\n );\n\n setChanged(false);\n setCustomerCopy(customerSaved);\n await fillData(customerSaved);\n }\n };\n\n const handleEdit = () => {\n setIsEdition(!isEdition);\n innerSetCustomer(customerCopy || new CustomerInfoDetails());\n setContacts([...contactsCopy]);\n setContactDeleted([]);\n };\n\n\n const showDuplicated = (duplicated: any) => {\n appDispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid number\"),\n description: t(\"This number already belongs to customer\"),\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n const location = `${Url.Customers.Main}/${duplicated.id}`;\n history.push(location);\n history.replace(location);\n history.go(0);\n },\n title: `${duplicated.firstName} ${duplicated.lastName}`,\n }\n })\n );\n setIsDuplicated(true);\n }\n\n const handlerCustomerGeneralChange = (customerEntity: CustomerEntity, valid: boolean) => {\n\n if (loadedGeneral)\n setLoadedGeneral(false);\n else\n setChanged(true);\n\n let validGroup = true;\n\n const validName = MultipleSpacesNameRegex.test(customerEntity.firstName || \"\");\n const validLastName = MultipleSpacesNameRegex.test(customerEntity.lastName || \"\");\n const validMobile = validateMobile(customerEntity);\n const validEmail = !customerEntity.email ? true : EmailRegex.test(customerEntity.email || \"\");\n const validGender = customer.gender !== Gender.Custom || MultipleSpacesNameRegex.test(customer.customGender || \"\");\n\n if (!validName ||\n !validLastName ||\n !validEmail ||\n !validMobile ||\n !validGender\n ) {\n validGroup = false;\n }\n\n innerSetCustomer({ ...customer, ...customerEntity });\n setCustomerValid(valid && validGroup);\n };\n\n const handlerCustomerNotificationsChange = (customerEntity: CustomerEntity) => {\n innerSetCustomer({ ...customer, ...customerEntity });\n };\n\n const handleNoteChange = (event: React.ChangeEvent<{ value: string }>) => {\n innerSetCustomer({ ...customer, notes: event.target.value });\n };\n\n const handleAddContact = () => {\n const arrContacts = contacts;\n const countryDefault = accountSettings.countryInSettings;\n\n let newContact = new EmergencyContact();\n newContact.mobileCodeIso3 = countryDefault.iso3;\n newContact.mobileDigits = countryDefault.dialDigits;\n newContact.mobileCode = countryDefault.dialCode;\n newContact.mobileTemplate = countryDefault.dialTemplate;\n\n arrContacts.push(newContact);\n setContacts([...arrContacts]);\n };\n\n const handleChangeContact = (contact: EmergencyContact, index: any) => {\n\n if (loadedContacts)\n setLoadedContacts(false);\n else\n setChanged(true);\n\n const arrContacts = contacts;\n arrContacts[index] = contact;\n setContacts([...arrContacts]);\n };\n\n const handleDeleteContact = (contact: EmergencyContact, index: any) => {\n setContactIndex(index);\n setEmergencyContact(contact);\n setOpenModal(true);\n };\n\n const handleCloseModal = () => {\n setOpenModal(false);\n };\n\n const createEmergencyContacts = async () => {\n return await CustomerService.createEmergencyContacts(\n new CreateEmergencyContacts({\n customerId: customer.id,\n emergencyContacts: contacts,\n })\n );\n };\n\n const deleteEmergencyContacts = async () => {\n if (contactDeleted.length) {\n await CustomerService.deleteBulkEmergencyContacts(\n contactDeleted.map((contact) => contact.id || \"\")\n );\n }\n };\n\n const removeEmergencyContact = () => {\n const contactsDeleted = contactDeleted;\n if (contacts[contactIndex] && contacts[contactIndex].id) {\n contactsDeleted.push(contacts[contactIndex]);\n }\n setContactDeleted(contactsDeleted);\n\n const arrContacts = contacts.filter(\n (contact, index) => index !== contactIndex\n );\n\n setContacts(arrContacts);\n\n setChanged(true);\n\n setEmergencyContact(undefined);\n setOpenModal(false);\n };\n\n return (<>\n <TabPanel\n className={classes.customerInfoPanel}\n value={currentTabIndex}\n index={0}\n >\n <div className={classes.customerInfoPanelContent}>\n <div className={classes.customerInfoTitle}>\n <GroupIcon />\n <Typography className={classes.iconTitle}>\n {t(\"Customer info\")}\n </Typography>\n </div>\n <div className={classes.customerInfoContent}>\n {isEdition ? (\n <CustomerGeneral\n onChange={handlerCustomerGeneralChange}\n mobilePhoneDuplicated={isDuplicated}\n value={new CustomerEntity(customer)}\n isEdition\n />\n ) : (\n <div>\n <div className={classes.infoContentFields}>\n <div>\n <Typography className={classes.caption}>\n {t(\"Name(s)\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {customer.firstName}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Last names\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {customer.lastName}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Date of birth\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {date(customer.birthDate)}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Gender\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {gender(customer.gender)}\n </Typography>\n </div>\n {customer.gender === Gender.Custom &&\n <div>\n <Typography className={classes.caption}>\n {t(\"Custom gender\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {customer.customGender}\n </Typography>\n </div>\n }\n <div>\n <Typography className={classes.caption}>\n {hasCustomerInfoVisible ? t(\"Email\") : t(\"Contactable\")}\n </Typography>\n <Typography className={classes.captionValue}>\n {hasCustomerInfoVisible ? customer.email : customer.contactableAppointments || customer.contactableMassiveSendings ? t(\"Yes\") : t(\"No\")}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {hasCustomerInfoVisible && t(\"Mobile\")}\n </Typography>\n <div className={classes.captionValue} style={{ display: `${hasCustomerInfoVisible ? \"\" : \"none\"}` }}>\n <div className={classes.divFlag}>\n <CountryFlagIcon iso={customer?.mobileCodeIso3 || \"MEX\"} />\n </div>\n <div className={classes.divCode}>\n {customer.mobileCode !== undefined ? `+${customer.mobileCode}` : \"+52\"}\n </div>\n <div className={classes.divMobile}>\n {\n customer.mobile ? conformToMask(customer.mobile, GetMobileMaskByTemp(customer.mobileTemplate || mobileTemplate)).conformedValue : \"\"\n }\n </div>\n </div>\n </div>\n </div>\n </div>\n )}\n\n <div className={classes.separator} style={{ width: 360 }}></div>\n <div className={classes.customerInfoTitle}>\n <BellIcon />\n <Typography className={classes.iconTitle}>\n {t(\"Notifications\")}\n </Typography>\n </div>\n <CustomerNotifications\n onChange={handlerCustomerNotificationsChange}\n value={new CustomerEntity(customer)}\n isEdition={isEdition}\n />\n\n <div className={classes.separator} style={{ width: 360 }}></div>\n <div className={classes.customerInfoTitle}>\n <PhoneIcon />\n <Typography className={classes.iconTitle}>\n {t(\"Emergency contacts\")}\n </Typography>\n </div>\n {contacts && contacts.length > 0 ? (\n <>\n {isEdition ? (\n <CustomerEmergencyContactList\n list={contacts}\n onChange={handleChangeContact}\n onDelete={handleDeleteContact}\n />\n ) : (\n <>\n <div className={classes.infoContentRow}>\n <div>\n <Typography className={classes.caption}>\n {t(\"Name\")}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"Relationship\")}\n </Typography>\n </div>\n <div>\n <Typography className={classes.caption}>\n {t(\"ContactMobileNumber\")}\n </Typography>\n </div>\n </div>\n {contacts.map((contact, index) => (\n <div key={index} className={classes.contactRow}>\n <div>\n <Typography className={classes.captionValue}>\n {contact.name}\n </Typography>\n </div>\n <div>\n <Typography className={classes.captionValue}>\n {contact.relationship}\n </Typography>\n </div>\n <div className={classes.captionValue}>\n <div>\n <div className={classes.divFlag}>\n <CountryFlagIcon iso={contact?.mobileCodeIso3 || \"MEX\"} />\n </div>\n <div className={classes.divCode}>\n {(customer.mobileCode !== undefined && customer.mobileCode !== null) ? `+${customer.mobileCode}` : \"+52\"}\n </div>\n <div className={classes.divMobile}>\n {\n conformToMask(contact.mobile!, GetMobileMaskByTemp(contact.mobileTemplate || mobileTemplate)).conformedValue\n }\n </div>\n </div>\n </div>\n </div>\n ))}\n </>\n )}\n </>\n ) : (\n <div className={classes.infoContentRow}>\n <Typography className={classes.captionValue}>\n {t(\"No Emergency Contacts\")}\n </Typography>\n </div>\n )}\n {isEdition ? (\n <div className={classes.infoContentRow}>\n <Button\n className={classes.addContactButton}\n onClick={handleAddContact}\n >\n <PlusIcon />\n {t(\"Add another\")}\n </Button>\n </div>\n ) : null}\n <div className={classes.separator} style={{ width: 360 }}></div>\n <div className={classes.customerInfoTitle}>\n <NoteIcon />\n <Typography className={classes.iconTitle}>\n {t(\"Notes\")}\n </Typography>\n </div>\n <div className={classes.infoContentRow}>\n <div style={{ marginBottom: 98 }}>\n {isEdition ? (\n <InputWithLabel\n label={t(\"Allergies\")}\n placeholder={t(\"Enter customer allergies\")}\n width={730}\n value={customer.notes || \"\"}\n maxLength={180}\n showCounter={true}\n onChange={handleNoteChange}\n />\n ) : (\n <>\n <Typography className={classes.caption}>\n {t(\"Allergies\")}\n </Typography>\n <Typography className={classes.captionValueTextArea}>\n {customer.notes || t(\"No allergies\") + \".\"}\n </Typography>\n </>\n )}\n </div>\n </div>\n </div>\n </div>\n {currentTabIndex === 0 ? (\n <div className={classes.detailsActions}>\n {isEdition ? (\n <div>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n hoverColor={ButtonPropsColor.Red}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Cancel\")}\n innerIcon={<CrossIcon style={{ width: 16, height: 14 }} viewBox=\"0 0 16 16\" />}\n onClick={() => setCancelModal(true)}\n />\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Green}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Save changes\")}\n innerIcon={<SaveIcon style={{ width: 16, height: 16 }} />}\n onClick={handleSave}\n disabled={!isValid || !changed}\n />\n </div>\n ) : (\n !hasCustomerInfoVisible ? <></> : <>\n <ButtonWithSpinner\n width={108}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Main}\n hoverColor={ButtonPropsColor.Main}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Edit info\")}\n innerIcon={<EditIcon style={{ width: 18, height: 16 }} />}\n onClick={handleEdit}\n />\n </>\n )}\n </div>\n ) : null}\n </TabPanel>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <span\n className={classes.closeButton}\n onClick={handleCloseModal}\n >\n <CrossIcon />\n </span>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div className={classes.modalCenter}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Are you sure to delete the emergency contact?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {emergencyContact?.name} - {emergencyContact?.relationship}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.deleteContact}`}\n onClick={removeEmergencyContact}\n >\n {t(\"Delete Contact\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.modalCancelPaper}>\n <div className={classes.modalContent}>\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleText}>\n {t(\n \"Are you sure you want to cancel the data editing? The changes made will not be saved?\"\n )}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={() => setCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n handleEdit();\n setCancelModal(false);\n }}\n >\n {t(\"Yes\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </>\n );\n};\n\nexport default CustomerInformationTab;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n maxHeight: \"calc(100vh - 152px)\",\n overflowY: \"scroll\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n sectionsListContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n padding: \"0px 16px\",\n },\n sectionContainer: {\n paddingTop: 32,\n display: \"flex\",\n flexDirection: \"column\",\n gap: 22,\n minHeight: 80\n },\n fieldsContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n flexWrap: \"wrap\",\n rowGap: 16\n },\n fieldsEditionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n flexWrap: \"wrap\",\n gap: 24\n },\n fieldContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n minWidth: \"50%\",\n maxWidth: \"50%\",\n gap: 2\n },\n fieldEditionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n gap: 2\n },\n divider: {\n height: 0,\n borderTop: \"1px solid \" + Color.gray2,\n opacity: \"0.5\",\n marginTop: 47\n },\n editDivider: {\n height: 0,\n borderTop: \"1px solid \" + Color.gray2,\n opacity: \"0.5\",\n marginTop: 32\n },\n sectionLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray4\n },\n fieldNameLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4\n },\n fieldNameAsterisk: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.clear1\n },\n fieldValueLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n overflowWrap: 'break-word'\n },\n phoneNumberCodeLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.clear1\n },\n noNotes: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray4,\n paddingBottom: 32,\n },\n notes: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n paddingBottom: 32,\n },\n phoneNumberContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 4,\n \"& svg\": {\n width: \"20px !important\",\n height: \"20px !important\"\n }\n },\n editButtonContainer: {\n position: \"absolute\",\n bottom: 32,\n right: 16\n },\n editButton: {\n borderRadius: 51,\n padding: \"0px 16px\",\n height: 32,\n background: Color.gray1,\n color: Color.clear1,\n \"div > span\": {\n \"&:hover\": {\n background: Color.clear1,\n color: Color.gray1,\n },\n },\n \"&:hover\": {\n background: Color.clear1,\n color: Color.gray1,\n },\n },\n editButtonLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n },\n cancelButton: {\n borderRadius: 51,\n padding: \"0px 16px\",\n height: 32,\n background: Color.gray1,\n color: Color.gray5,\n \"div > span\": {\n \"&:hover\": {\n background: Color.red,\n color: Color.gray1,\n },\n },\n \"&:hover\": {\n background: Color.red,\n color: Color.gray1,\n },\n },\n cancelButtonLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n },\n saveButton: {\n borderRadius: 51,\n padding: \"0px 16px\",\n height: 32,\n background: Color.gray1,\n color: Color.green,\n \"div > span\": {\n \"&:hover\": {\n background: Color.green,\n color: Color.gray1,\n },\n },\n \"&:hover\": {\n background: Color.green,\n color: Color.gray1,\n },\n },\n saveButtonLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n },\n requiredFieldsNoteLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4\n },\n editModeButtonsGroupContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-end\",\n alignItems: \"center\",\n gap: 16,\n paddingTop: 40,\n paddingBottom: 16\n },\n closeConfirmationModal: {\n height: \"234px + !important\"\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n switchOverrides: {\n \"& .MuiFormControlLabel-root\": {\n marginLeft: \"unset\",\n marginRight: \"unset\",\n },\n \"& #labelId\": {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5,\n marginBottom: 5,\n },\n \"& #labelAsterixId\": {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.clear1\n },\n \"& #tooltipTextId\": {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4,\n }\n },\n muiSwitchTrackOverride: {\n \"& .MuiSwitch-track\": {\n backgroundColor: Color.clear1 + \" !important\"\n }\n },\n notesEditLabelContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n flexWrap: \"wrap\",\n rowGap: 8,\n alignItems: \"center\"\n },\n tinyMceOverrides: {\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n position: \"relative\",\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n charCounter: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"10px\",\n lineHeight: \"12px\",\n position: \"absolute\",\n paddingRight: 15,\n marginTop: \"-18px\",\n color: theme.colors.grey5\n },\n counterWrapper: {\n display: \"flex\",\n justifyContent: \"flex-end\"\n },\n tinyMceContainer: {\n width: \"100%\"\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n display: \"flex\",\n margin: 0,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n description: {\n margin: 0,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../constants/colors\";\n\nconst useStyles = () => makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n backgroundColor: theme.colors.white,\n },\n datePicker: {\n position: \"relative\",\n alignItems: \"center\",\n alignContent: \"center\",\n justifyContent: \"center\",\n },\n input: {\n width: \"auto\",\n height: 40,\n backgroundColor: theme.colors.white,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n inputText: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontSize: \"0.9rem\",\n lineHeight: \"1.1876em\",\n fontWeight: 400,\n color: \"rgba(0, 0, 0, 0.87)\"\n },\n },\n inputTextError: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n color: theme.colors.clearRed,\n },\n\n inputDisabled: {\n backgroundColor: theme.colors.grey1,\n color: theme.colors.grey4,\n },\n inputError: {\n color: theme.colors.clearRed,\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearRed,\n },\n icon: {\n position: \"absolute\",\n right: 6,\n top: 6,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n minWidth: \"unset\"\n },\n popoverOverride: {\n borderRadius: \"12px\"\n },\n toolbarBox: {\n backgroundColor: Color.clear1,\n height: 70,\n borderRadius: \"10px 10px 0px 0px\"\n },\n toolbarDateContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 3,\n padding: 20\n },\n toolbarYearLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"11px\",\n lineHeight: \"13px\",\n color: Color.clear3,\n cursor: \"pointer\",\n width: \"fit-content\"\n },\n toolbarWeekDayDayMonthLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: \"#FAFAFA\",\n cursor: \"pointer\",\n width: \"fit-content\"\n },\n toolbarDateLabelContainer: {\n width: \"fit-content\"\n }\n}));\n\nexport default useStyles;\n","import React, { useState } from 'react';\n\nimport { useAppSelector } from \"../../../../redux/hooks\";\n\nimport DateFnsUtils from \"@date-io/date-fns\";\nimport { KeyboardDatePicker, MuiPickersUtilsProvider } from \"@material-ui/pickers\";\nimport esLocale from \"date-fns/locale/es\";\nimport enLocale from \"date-fns/locale/en-US\";\n\nimport useStyles from \"./css\";\nimport { PatientFormDateInputProps } from \"./props\";\n\nimport useControlLabel from \"../../../../hooks/useControlLabel\";\nimport useInputFirstTouch from \"../../../../hooks/useInputFirstTouch\";\nimport { MaterialUiPickersDate } from \"@material-ui/pickers/typings/date\";\nimport CalendarIcon from \"../../../../assets/icons/CalendarIcon\";\nimport { Button, Typography } from '@material-ui/core';\nimport { ToolbarComponentProps } from '@material-ui/pickers/Picker/Picker';\n\n\nexport default function PatientFormDateInput(props: PatientFormDateInputProps) {\n\n const { value, setValue, label, isValid, required, minDate, maxDate } = props;\n\n const classes = useStyles()();\n\n const [open, setOpen] = useState<boolean>(false);\n\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const yesterdayDate = new Date(new Date().setDate(new Date().getDate() - 1));\n\n function getLocale() {\n switch (localeApp) {\n case \"es\":\n return esLocale;\n\n default:\n return enLocale;\n }\n }\n\n function handleChangeDate(date: MaterialUiPickersDate) {\n const actualDate = date as Date;\n setValue(actualDate);\n }\n\n const ControlLabel = useControlLabel({ label, required });\n const { hasBeenTouched, handleFirstTouch } = useInputFirstTouch();\n\n function getYear(value: Date | null) {\n if (!value || !isValid(value)) {\n return \"--\";\n }\n\n const newDateObj = new Date(value!);\n const year = newDateObj.toLocaleString(localeApp, { year: \"numeric\", });\n\n return year;\n }\n\n function getWeekDayDayMonth(value: Date | null) {\n if (!value || !isValid(value)) {\n return \"--\";\n }\n\n const newDateObj = new Date(value!);\n const day = newDateObj.toLocaleString(localeApp, { day: \"numeric\" });\n let month = newDateObj.toLocaleString(localeApp, { month: \"long\", });\n const weekDay = newDateObj.toLocaleString(localeApp, { weekday: \"short\" })\n\n const result = `${weekDay.charAt(0).toUpperCase() + weekDay.slice(1)}, ${month.charAt(0).toUpperCase() + month.slice(1)} ${day}`;\n\n return result;\n }\n\n const ToolbarComponent: React.FC<ToolbarComponentProps> = ({ setOpenView }) => {\n return <div className={classes.toolbarBox}>\n <div className={classes.toolbarDateContainer}>\n <div className={classes.toolbarDateLabelContainer} onClick={() => setOpenView(\"year\")}>\n <Typography className={classes.toolbarYearLabel}>\n {getYear(value)}\n </Typography>\n </div>\n <div className={classes.toolbarDateLabelContainer} onClick={() => setOpenView(\"date\")}>\n <Typography className={classes.toolbarWeekDayDayMonthLabel}>\n {getWeekDayDayMonth(value)}\n </Typography>\n </div>\n </div>\n </div>\n }\n\n return (\n <div className={classes.root}>\n <ControlLabel />\n <div className={classes.datePicker}>\n <MuiPickersUtilsProvider utils={DateFnsUtils} locale={getLocale()}>\n <KeyboardDatePicker\n variant={\"inline\"}\n format={localeApp === \"es\" ? \"dd/MM/yyyy\" : \"MM/dd/yyyy\"}\n open={open}\n onClose={() => setOpen(false)}\n autoOk\n fullWidth\n openTo=\"date\"\n value={value}\n minDate={minDate}\n maxDate={maxDate}\n inputVariant=\"standard\"\n onChange={handleChangeDate}\n onBlur={() => handleFirstTouch()}\n disableFuture\n keyboardIcon={<></>}\n helperText={<></>}\n PopoverProps={{\n anchorOrigin: { horizontal: \"right\", vertical: \"top\" },\n transformOrigin: { horizontal: \"right\", vertical: \"bottom\" },\n classes: { paper: classes.popoverOverride }\n }}\n InputProps={{\n disableUnderline: true,\n placeholder: localeApp === \"es\" ? \"dd/mm/yyyy\" : \"mm/dd/yyyy\",\n className: `${classes.input} ${!isValid(value) ? classes.inputError : \"\"}`,\n classes:\n {\n input: isValid(value) ? classes.inputText : classes.inputTextError,\n disabled: classes.inputDisabled\n }\n }}\n ToolbarComponent={ToolbarComponent}\n />\n <Button className={classes.icon} onClick={() => setOpen(true)}>\n <CalendarIcon style={{ width: 14, height: 16, color: \"#5C6477\" }} />\n </Button>\n </MuiPickersUtilsProvider>\n </div>\n </div>\n );\n}","export default class Cloner {\n //Returns deep copy with prototype and type preserving\n public static deepCopy<TSource>(source: TSource): TSource {\n return Array.isArray(source)\n ? source.map(item => this.deepCopy(item))\n : source instanceof Date\n ? new Date(source.getTime())\n : source && typeof source === 'object'\n ? Object.getOwnPropertyNames(source).reduce((o, prop) => {\n Object.defineProperty(o, prop, Object.getOwnPropertyDescriptor(source, prop)!);\n o[prop] = this.deepCopy((source as { [key: string]: any })[prop]);\n return o;\n }, Object.create(Object.getPrototypeOf(source)))\n : source as TSource;\n }\n }","import { Gender } from \"./enums/gender\";\nimport { PatientFormFieldAndValue } from \"./patient-form-field-and-value\";\nimport { PatientGeneralInfoResponse } from \"./patient-general-info-response\";\n\nexport class UpdatePatientFormDataRequest {\n customerId: string;\n firstName: string;\n lastName: string;\n dateOfBirth?: Date;\n gender?: Gender;\n customGender?: string | null;\n\n email?: string;\n mobileCodeIso3: string;\n mobile: string;\n contactableAppointments: boolean;\n contactableMassiveSendings: boolean;\n\n notes: string;\n\n patientFormSectionFields: PatientFormFieldAndValue[];\n\n constructor(x?: any | PatientGeneralInfoResponse) {\n if (x instanceof PatientGeneralInfoResponse) {\n this.customerId = x.id;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.dateOfBirth = x.dateOfBirth;\n this.gender = x.gender;\n this.customGender = x.customGender;\n this.email = x.email;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobile = x.mobile ?? \"\";\n this.contactableAppointments = x.contactableAppointments;\n this.contactableMassiveSendings = x.contactableMassiveSendings;\n this.patientFormSectionFields = x.patientFormSections.flatMap(s => s.patientFormSectionFields);\n this.notes = getHtmledNotes(x.notes);\n }\n else if (typeof x === \"object\") {\n this.customerId = x.id;\n this.firstName = x.firstName;\n this.lastName = x.lastName;\n this.dateOfBirth = x.dateOfBirth;\n this.gender = x.gender;\n this.customGender = x.customGender;\n this.email = x.email;\n this.mobileCodeIso3 = x.mobileCodeIso3;\n this.mobile = x.mobile;\n this.contactableAppointments = x.contactableAppointments;\n this.contactableMassiveSendings = x.contactableMassiveSendings;\n this.patientFormSectionFields = x.patientFormSectionFields;\n this.notes = x.notes;\n }\n else {\n this.customerId = \"\";\n this.firstName = \"\";\n this.lastName = \"\";\n this.dateOfBirth = undefined;\n this.gender = undefined;\n this.customGender = undefined;\n this.email = undefined;\n this.mobileCodeIso3 = \"MEX\";\n this.mobile = \"\";\n this.contactableAppointments = false;\n this.contactableMassiveSendings = false;\n this.patientFormSectionFields = [];\n this.notes = \"\";\n }\n }\n }\n\n //need to make stringify validation work - TinyMCE/HTML eats whitespaces on init\n function getHtmledNotes(v: string) {\n if (!v) return \"\";\n\n let htmledNotes = v.trim();\n while (htmledNotes.includes(\" \")) {\n htmledNotes = htmledNotes.replace(\" \", \" \");\n }\n\n return htmledNotes;\n }\n\n","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport useStyles from \"./css\";\nimport Button from \"@material-ui/core/Button\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { useHistory } from \"react-router-dom\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { selectAccountSettings } from \"../../../redux/store\";\nimport { applicationInterfaceActions } from \"../../../redux/application-interface-slice\";\n\nimport { conformToMask } from \"react-text-mask\";\nimport Interweave from \"interweave\";\n\nimport { PatientGeneralInformationTabProps } from \"./props\";\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport { EmailRegex, MultipleSpacesNameRegex } from \"../../../constants/validator\";\nimport { Url } from \"../../../constants/url\";\n\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { ApiClient } from \"../../../api/api-client\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport { Editor } from \"@tinymce/tinymce-react\";\nimport PatientFormTextInput from \"../../common/PatientFormTextInput\";\nimport PatientFormMobileInput from \"../../common/PatientFormMobileInput\";\nimport PatientFormRadioGroup from \"../../common/PatientFormRadioGroup\";\nimport { SectionFieldItemModel } from \"../../../models/section-field-item-model\";\nimport ConfirmActionModal from \"../../common/ConfirmActionModal\";\nimport PatientFormDateInput from \"./PatientFormDateInput\";\nimport Cloner from \"../../../utils/cloner\";\n\nimport { CrossIcon, EditIcon, InternalNotesIcon, SaveIcon } from \"../../../assets/icons\";\nimport CountryFlagIcon from \"../../../assets/flags\";\n\nimport { PatientGeneralInfoResponse } from \"../../../models/patient-general-info-response\";\nimport { Gender } from \"../../../models/enums/gender\";\nimport { SectionFieldType } from \"../../../models/enums/section-field-type\";\nimport { FormRadioValue } from \"../../../models/form-radio-value\";\nimport { SectionFieldValueModel } from \"../../../models/section-field-value-model\";\nimport { FormPhoneNumberValue } from \"../../../models/form-phone-number-value\";\nimport { PatientFormFieldAndValue } from \"../../../models/patient-form-field-and-value\";\nimport { FormFieldItemValue } from \"../../../models/form-field-item-value\";\nimport { UpdatePatientFormDataRequest } from \"../../../models/update-patient-form-data-request\";\nimport { SectionFieldModel } from \"../../../models/section-field-model\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport Switch from \"../../common/Switch\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\nimport { CustomerInfoDetails } from \"../../../models/customer-info-details\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\n\n\nexport default function PatientGeneralInformationTab(props: PatientGeneralInformationTabProps) {\n const { customerId, setCustomer } = props;\n const sectionTNamespace = \"sections\";\n const maxNotesTextLength: number = 1500;\n const stringify = require('safe-stable-stringify')\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const classes = useStyles();\n const history = useHistory();\n const appDispatch = useAppDispatch();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n const { enqueueAlert } = alertsActions;\n const hasCustomerInfoVisible = ApiClient.getUserInfo().hasCustomerInfoVisible;\n\n const [patient, setPatient] = useState<PatientGeneralInfoResponse>(new PatientGeneralInfoResponse());\n const [isEdition, setIsEdition] = useState<boolean>(false);\n const [patientForEdit, setPatientForEdit] = useState<UpdatePatientFormDataRequest | null>(null);\n const [isFormValid, setIsFormValid] = useState<boolean>(false);\n const [cancelEditModalIsOpen, setCancelEditModalIsOpen] = useState<boolean>(false);\n const [focusedNotes, setFocusedNotes] = useState<boolean>(false);\n const [notesTextLength, setNotesTextLength] = useState<number>(0);\n\n const maleGender = new FormFieldItemValue({ fieldItemId: Gender.Male.toString(), value: t(\"default_field_item_name_Male\", { ns: sectionTNamespace }) });\n const femaleGender = new FormFieldItemValue({ fieldItemId: Gender.Female.toString(), value: t(\"default_field_item_name_Female\", { ns: sectionTNamespace }) });\n const secretGender = new FormFieldItemValue({ fieldItemId: Gender.PreferNotToSay.toString(), value: t(\"default_field_item_name_PreferNotToSay\", { ns: sectionTNamespace }) });\n const customGender = new FormFieldItemValue({ fieldItemId: Gender.Custom.toString(), value: t(\"default_field_item_name_Custom\", { ns: sectionTNamespace }) });\n\n const appointmentDescription = useCustomerTerminology(t(\"The customer will receive automatic notifications such as: Appointments, reminders, etc.\"), \"customer\");\n const massiveSendingsDescription = useCustomerTerminology(t(\"The customer will receive automated Massive sending messages.\"), \"customer\");\n\n const yesterdayDate = new Date(new Date().setDate(new Date().getDate() - 1));\n const year1900Date = new Date(1900, 0);\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n\n fetchData();\n }, []);\n\n useEffect(() => {\n if (!patientForEdit)\n return;\n validateFieldsOnChange(patientForEdit.patientFormSectionFields);\n }, [\n patientForEdit?.firstName,\n patientForEdit?.lastName,\n patientForEdit?.email,\n patientForEdit?.mobile,\n patientForEdit?.mobileCodeIso3,\n patientForEdit?.gender,\n patientForEdit?.notes,\n patientForEdit?.dateOfBirth,\n patientForEdit?.contactableAppointments,\n patientForEdit?.contactableMassiveSendings]);\n\n const loadData = async () => {\n appDispatch(navbarActions.setShowLoader(true));\n const patientResponse = await CustomerService.getPatientGeneralInfo(customerId);\n appDispatch(navbarActions.setShowLoader(false));\n \n const countries = accountSettings.countries;\n let mobileCode = patientResponse.mobileCodeIso3 ?? \"MEX\";\n patientResponse.mobileDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n patientResponse.mobileCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n patientResponse.mobileTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n \n setPatient(patientResponse);\n setCustomer(patientResponse);\n\n const titleNav = t(\"Patient clinical file\") + \" / \" + patientResponse.firstName + \" \" + patientResponse.lastName;\n appDispatch(applicationInterfaceActions.updateTitle(titleNav));\n };\n\n const handleEditButtonClick = async () => {\n const clone = Cloner.deepCopy<PatientGeneralInfoResponse>(patient);\n const patientForEditModel = new UpdatePatientFormDataRequest(clone);\n setPatientForEdit(patientForEditModel);\n setIsEdition(true);\n };\n\n const handleCloseEdit = () => {\n setCancelEditModalIsOpen(false);\n setIsEdition(false);\n setIsFormValid(false);\n };\n\n const handleCancelEditButtonClick = async () => {\n if (stringify(new UpdatePatientFormDataRequest(patient)) !== stringify(patientForEdit)) {\n setCancelEditModalIsOpen(true);\n }\n else {\n handleCloseEdit();\n }\n };\n\n const handleSaveChangesButtonClick = async () => {\n if (!patientForEdit)\n return;\n\n const response = await CustomerService.updatePatientFormData(patientForEdit);\n if (response.isDuplicatedPhoneNumber) {\n appDispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid number\"),\n description: t(\"This number already belongs to patient\"),\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n const location = `${Url.Customers.Main}/${response.duplicatedPatientId!}`;\n history.push(location);\n history.replace(location);\n history.go(0);\n },\n title: `${response.firstName} ${response.lastName}`,\n }\n })\n );\n return;\n }\n\n await loadData();\n handleCloseEdit();\n appDispatch(\n enqueueAlert({\n type: \"Success\",\n description: t(\"Information updated\")\n }));\n };\n\n const setFirstName = (v: string) => {\n setPatientForEdit(prev => ({ ...prev!, firstName: v }));\n };\n\n const setLastName = (v: string) => {\n setPatientForEdit(prev => ({ ...prev!, lastName: v }));\n };\n \n const setPhoneNumber = (v: FormPhoneNumberValue) => {\n setPatientForEdit(prev => ({ ...prev!, mobileCodeIso3: v.countryIso, mobile: v.body }));\n };\n\n const setEmail = (v: string) => {\n setPatientForEdit(prev => ({ ...prev!, email: v }));\n };\n \n const setCustomGender = (v: string) => {\n setPatientForEdit(prev => ({ ...prev!, customGender: v }));\n };\n \n const setDob = (v: Date) => {\n setPatientForEdit(prev => ({ ...prev!, dateOfBirth: v }));\n };\n \n function setContactableAppointments(event: any) {\n setPatientForEdit(prev => ({ ...prev!, contactableAppointments: event.target.checked }));\n }\n \n function setContactableMassiveSendings(event: any) {\n setPatientForEdit(prev => ({ ...prev!, contactableMassiveSendings: event.target.checked }));\n }\n\n const setNotesTextLengthOnInit = (evt: any, editor: any) => {\n setNotesTextLength(editor.getContent({ format: \"text\" }).length);\n };\n\n const setNotes = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n let contentHtml: string = editor.getContent();\n if (contentText.length <= maxNotesTextLength) {\n setPatientForEdit(prev => ({ ...prev!, notes: contentHtml }));\n setNotesTextLength(contentText.length);\n }\n };\n\n const setFieldValue = (fieldId: string, value: string | FormPhoneNumberValue | FormRadioValue | null, additionalTextValue: string | null = null) => {\n if (!patientForEdit?.patientFormSectionFields)\n return;\n\n const fieldsAndValues = [...patientForEdit.patientFormSectionFields];\n const fieldAndValue = fieldsAndValues.find(f => f.field.id === fieldId);\n\n if (!fieldAndValue)\n return;\n\n //make value null if field is empty (need for compairing with old patient version and for proper storing)\n if (typeof value === \"string\" && value === \"\") {\n fieldAndValue.value = null;\n validateFieldsOnChange(fieldsAndValues);\n setPatientForEdit({ ...patientForEdit, patientFormSectionFields: fieldsAndValues })\n return;\n }\n\n if (!additionalTextValue) {\n if (!fieldAndValue.value) {\n fieldAndValue.value = new SectionFieldValueModel({ type: fieldAndValue.field.type, value: value })\n }\n else {\n fieldAndValue.value.type = fieldAndValue.field.type;\n fieldAndValue.value.value = value!;\n }\n }\n //if field is Radio and contain additional text value\n else if (additionalTextValue && fieldAndValue.field.type === SectionFieldType.Radio) {\n let newValue: FormRadioValue;\n //if this field value has already selected field item - just setting the argument value\n if (value && (value as FormRadioValue).item) {\n newValue = value as FormRadioValue;\n }\n //if not - we're selecting first item automatically\n else {\n const firstSelectItem = fieldAndValue.field.items.sort((i1, i2) => i1.order - i2.order)[0];\n const autoSelectedFirstItemValue = new FormFieldItemValue({ fieldItemId: firstSelectItem.id, value: firstSelectItem.name })\n newValue = new FormRadioValue();\n newValue.item = autoSelectedFirstItemValue;\n newValue.additionalFreeTextValue = additionalTextValue;\n }\n if (!fieldAndValue.value) {\n fieldAndValue.value = new SectionFieldValueModel({ type: fieldAndValue.field.type, value: newValue })\n }\n else {\n fieldAndValue.value.value = newValue!;\n }\n\n };\n\n validateFieldsOnChange(fieldsAndValues);\n setPatientForEdit({ ...patientForEdit, patientFormSectionFields: fieldsAndValues })\n };\n\n const validateFieldsOnChange = (fieldsAndValues: PatientFormFieldAndValue[]) => {\n //if any of the fields is invalid - returning true \n const firstNameIsValid = MultipleSpacesNameRegex.test(patientForEdit!.firstName) && patientForEdit!.firstName.trim() !== \"\";\n const lastNameIsValid = MultipleSpacesNameRegex.test(patientForEdit!.lastName) && patientForEdit!.lastName.trim() !== \"\";\n const emailIsValid = EmailRegex.test(patientForEdit!.email ?? \"\") || !patientForEdit!.email || patientForEdit!.email === \"\";\n const mobileIsValid = validatePhoneNumber(patientForEdit!.mobileCodeIso3, patientForEdit!.mobile);\n const dobIsValid = validateDobField(patientForEdit!.dateOfBirth);\n\n if (!(firstNameIsValid && lastNameIsValid && emailIsValid && mobileIsValid)) {\n setIsFormValid(false);\n return;\n }\n\n const isValid = !fieldsAndValues.some(fv => {\n if (fv.field.isRequired) {\n if (!fv.value?.value || fv.value?.value === \"\") {\n if (!fv.field.isDeleted) {\n return true;\n }\n else {\n return false;\n }\n }\n switch (fv.field.type) {\n case SectionFieldType.Text:\n if (!fv.value?.value || fv.value.value === \"\") {\n return true;\n }\n break;\n case SectionFieldType.Email:\n if (!fv.value?.value || fv.value.value === \"\" || !EmailRegex.test(fv.value!.value as string)) {\n return true;\n }\n break;\n case SectionFieldType.Radio:\n if (!fv.field.isDeleted && (fv.value?.value as FormRadioValue).item === null) {\n return true;\n }\n break;\n case SectionFieldType.PhoneNumber:\n const phoneNumber = (fv.value?.value as FormPhoneNumberValue);\n if (!fv.field.isDeleted && (phoneNumber.body === \"\" || !validatePhoneNumber(phoneNumber.countryIso, phoneNumber.body))) {\n return true;\n }\n break;\n }\n }\n else {\n switch (fv.field.type) {\n case SectionFieldType.Email:\n if (fv.value?.value && !EmailRegex.test(fv.value.value as string)) {\n return true;\n }\n break;\n case SectionFieldType.PhoneNumber:\n const phoneNumber = (fv.value?.value as FormPhoneNumberValue);\n if (phoneNumber && phoneNumber.body !== \"\" && !validatePhoneNumber(phoneNumber.countryIso, phoneNumber.body)) {\n return true;\n }\n break;\n }\n }\n\n return false;\n });\n\n const isAllValid = isValid && firstNameIsValid && lastNameIsValid && emailIsValid && mobileIsValid && dobIsValid;\n setIsFormValid(isAllValid);\n }\n\n const validateTextField = (field: SectionFieldModel, value: string): boolean => {\n const isValid = !(field.isRequired && value === \"\");\n return isValid;\n };\n\n const validateEmailField = (field: SectionFieldModel, value: string): boolean => {\n if (field.isRequired) {\n return EmailRegex.test(value) && value !== \"\"\n }\n return EmailRegex.test(value) || value === \"\"\n };\n\n const validatePhoneNumber = (iso3Code: string, phoneNumber: string) => {\n const numberOfDigits = accountSettings.countries?.find(c => c.iso3 === iso3Code)!.dialDigits;\n if (!numberOfDigits)\n return false;\n return (numberOfDigits === 7 && /^\\d{7}$/.test(phoneNumber)) ||\n (numberOfDigits === 8 && /^\\d{8}$/.test(phoneNumber)) ||\n (numberOfDigits === 9 && /^\\d{9}$/.test(phoneNumber)) ||\n (numberOfDigits === 10 && /^\\d{10}$/.test(phoneNumber)) ||\n (numberOfDigits === 11 && /^\\d{11}$/.test(phoneNumber)) ||\n (numberOfDigits === 12 && /^\\d{12}$/.test(phoneNumber));\n }\n\n const validateDobField = (date: Date | undefined | null): boolean => {\n if (!date)\n return true;\n\n const newDateObj = new Date(date);\n\n return newDateObj instanceof Date &&\n !isNaN(newDateObj.valueOf()) &&\n newDateObj <= yesterdayDate &&\n newDateObj >= year1900Date\n };\n\n const mapSectionsToComponents = () => {\n if (!isEdition)\n return patient.patientFormSections\n .sort((s1, s2) => s1.section.order! - s2.section.order!)\n .map(s => {\n if (!s.patientFormSectionFields ||\n s.patientFormSectionFields.length === 0 ||\n s.patientFormSectionFields.every(f => f.field.isDeleted && f.value === null) ||\n (s.section.isDeleted && (s.patientFormSectionFields.length === 0 || s.patientFormSectionFields.every(f => f.value === null))))\n return <></>\n return <>\n <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(s.section.name!, { ns: sectionTNamespace })}\n </Typography>\n <div className={classes.fieldsContainer}>\n {s.patientFormSectionFields\n .sort((f1, f2) => f1.field.order - f2.field.order)\n .map(f => {\n if (f.field.isDeleted && !f.value?.value)\n return;\n else\n return <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(f.field.name, { ns: sectionTNamespace })} <span className={classes.fieldNameAsterisk}>{f.field.isRequired ? \"*\" : \"\"}</span>\n </Typography>\n {getFieldValueComponent(f.value)}\n </div>\n })}\n </div>\n </div>\n <div className={classes.divider}></div>\n </>\n });\n else\n return patient.patientFormSections\n .sort((s1, s2) => s1.section.order! - s2.section.order!)\n .map(s => {\n if (!s.patientFormSectionFields ||\n s.patientFormSectionFields.length === 0 ||\n s.patientFormSectionFields.every(f => f.field.isDeleted && f.value === null) ||\n (s.section.isDeleted && (s.patientFormSectionFields.length === 0 || s.patientFormSectionFields.every(f => f.value === null))))\n return <></>\n return <>\n <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(s.section.name!, { ns: sectionTNamespace })}\n </Typography>\n <Typography className={classes.requiredFieldsNoteLabel}>\n {t(\"Required fields\")} <span className={classes.fieldNameAsterisk}>*</span>\n </Typography>\n <div className={classes.fieldsEditionContainer}>\n {s.patientFormSectionFields\n .sort((f1, f2) => f1.field.order - f2.field.order)\n .map(f => {\n if (f.field.isDeleted && f.value === null)\n return;\n else {\n const fieldAndValue = patientForEdit?.patientFormSectionFields.find(fv => fv.field.id === f.field.id);\n return <div className={classes.fieldEditionContainer}>\n {getInputForEditMode(fieldAndValue!)}\n </div>\n }\n })}\n </div>\n </div>\n <div className={classes.editDivider}></div>\n </>\n });\n };\n\n const getFieldValueComponent = (valueModel: SectionFieldValueModel | null | undefined) => {\n if (valueModel?.value === null || valueModel?.value == undefined || valueModel?.value === \"\")\n return <Typography className={classes.fieldValueLabel}>\n {\"--\"}\n </Typography>\n\n switch (valueModel.type) {\n case SectionFieldType.Text:\n return <Typography className={classes.fieldValueLabel}>\n {valueModel.value as string}\n </Typography>\n case SectionFieldType.Email:\n return <Typography className={classes.fieldValueLabel}>\n {valueModel.value as string}\n </Typography>\n case SectionFieldType.Radio:\n return <Typography className={classes.fieldValueLabel}>\n {t((valueModel.value as FormRadioValue).item.value, { ns: sectionTNamespace })}\n {!!(valueModel.value as FormRadioValue).additionalFreeTextValue &&\n <> / {(valueModel.value as FormRadioValue).additionalFreeTextValue}</>\n }\n </Typography>\n case SectionFieldType.PhoneNumber: {\n const phoneNumberValue = valueModel.value as FormPhoneNumberValue;\n return <div className={classes.phoneNumberContainer}>\n <CountryFlagIcon iso={phoneNumberValue.countryIso} />\n <Typography className={classes.phoneNumberCodeLabel}>\n {\"+\" + accountSettings.countries.find(c => c.iso3 === phoneNumberValue.countryIso)!.dialCode}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {conformToMask(phoneNumberValue.body, GetMobileMaskByTemp(accountSettings.countries.find(c => c.iso3 === phoneNumberValue.countryIso)!.dialTemplate)).conformedValue}\n </Typography>\n </div>\n }\n }\n };\n\n const getInputForEditMode = (fieldAndValueModel: PatientFormFieldAndValue) => {\n const sectionField = fieldAndValueModel.field;\n const valueField = fieldAndValueModel.value;\n if (!valueField?.value) {\n //return empty input for sectionField type\n switch (sectionField.type) {\n case SectionFieldType.Text:\n return getTextInput(sectionField);\n case SectionFieldType.Email:\n return getEmailInput(sectionField);\n case SectionFieldType.PhoneNumber:\n return getPhoneNumberInput(sectionField);\n case SectionFieldType.Radio:\n return getRadioInput(sectionField);\n default:\n return;\n }\n }\n\n if (sectionField.type !== valueField.type) {\n switch (sectionField.type) {\n case SectionFieldType.Text:\n switch (valueField.type) {\n case SectionFieldType.Email:\n //return TextInput with valueField.value\n return getTextInput(sectionField, valueField.value as string);\n case SectionFieldType.PhoneNumber:\n //return TextInput with PhoneNumber like \"+52123456789\"\n const phoneObj = valueField.value as FormPhoneNumberValue;\n const dialCode = accountSettings.countries.find(c => c.iso3 === phoneObj.countryIso)!.dialCode;\n const phoneAsString = `+${dialCode}${phoneObj.body}`\n return getTextInput(sectionField, phoneAsString);\n case SectionFieldType.Radio:\n //return TextInput with valueField.value.item.value\n const radioItemObj = valueField.value as FormRadioValue;\n return getTextInput(sectionField, radioItemObj.item.value);\n }\n case SectionFieldType.Email:\n //return empty input for Email type\n return getEmailInput(sectionField);\n case SectionFieldType.PhoneNumber:\n //return empty input for PhoneNumber type\n return getPhoneNumberInput(sectionField);\n case SectionFieldType.Radio:\n //return empty input for Radio type\n return getRadioInput(sectionField);\n }\n }\n\n //dealing with filled RadioInput\n if (sectionField.type === SectionFieldType.Radio && valueField.type === SectionFieldType.Radio) {\n if (sectionField.items\n .filter(i => !i.isDeleted)\n .map(i => i.id)\n .some(i => i === (valueField.value as FormRadioValue).item.fieldItemId)) {\n //return RadioInput with valueField.value.item checked\n return getRadioInput(sectionField, valueField.value as FormRadioValue);\n }\n else {\n //return RadioInput with FAKE valueField.value.item checked\n return getRadioInput(sectionField, valueField.value as FormRadioValue, true);\n }\n }\n\n //dealing with other filled field types\n switch (sectionField.type) {\n case SectionFieldType.Text:\n //return filled TextInput\n return getTextInput(sectionField, valueField.value as string);\n case SectionFieldType.Email:\n //return filled EmailInput\n return getEmailInput(sectionField, valueField.value as string);\n case SectionFieldType.PhoneNumber:\n //return filled PhoneNumberInput\n return getPhoneNumberInput(sectionField, valueField.value as FormPhoneNumberValue);\n }\n };\n\n const getTextInput = (field: SectionFieldModel, value: string | null = null) => {\n return <>\n <PatientFormTextInput\n key={field.id!}\n value={value ? t(value, { ns: sectionTNamespace }) : \"\"}\n setValue={(v) => setFieldValue(field.id!, v)}\n label={t(field.name, { ns: sectionTNamespace })}\n isValid={(v) => validateTextField(field, v)}\n required={field.isRequired}\n placeholder={t(field.name, { ns: sectionTNamespace })}\n maxLength={1500} />\n </>\n };\n\n const getEmailInput = (field: SectionFieldModel, value: string | null = null) => {\n return <>\n <PatientFormTextInput\n key={field.id!}\n value={value ? value : \"\"}\n setValue={(v) => setFieldValue(field.id!, v)}\n label={t(field.name, { ns: sectionTNamespace })}\n isValid={(v) => validateEmailField(field, v)}\n required={field.isRequired}\n placeholder={t(field.name, { ns: sectionTNamespace })}\n maxLength={100} />\n </>\n };\n\n const getPhoneNumberInput = (field: SectionFieldModel, value: FormPhoneNumberValue | null = null) => {\n return <>\n <PatientFormMobileInput\n key={field.id!}\n mobileNumber={value ?? new FormPhoneNumberValue({ countryIso: accountSettings.countryInSettings!.iso3, body: \"\" })}\n label={t(field.name, { ns: sectionTNamespace })}\n setMobileNumber={(v) => setFieldValue(field.id!, v)}\n required={field.isRequired}\n countryInSettings={accountSettings.countryInSettings!}\n countries={accountSettings.countries!} />\n </>\n };\n\n const getRadioInput = (field: SectionFieldModel, value: FormRadioValue | null = null, isFakeRadioItem: boolean = false) => {\n const getSelectedItem = () => {\n if (!value && !isFakeRadioItem) {\n //Possibly QA team will ask for this (TODO: fix lack of real value in request)\n // if (field.isRequired) {\n // //return first selected item\n // return field.items.filter(i => !i.isDeleted).sort((i1, i2) => i1.order - i2.order)[0]\n // }\n // else {\n // //return no selected item\n // return null;\n // }\n return null;\n };\n if (value && !isFakeRadioItem)\n //return genuine selected item\n return field.items.filter(i => i.id === value.item.fieldItemId)[0];\n if (value && isFakeRadioItem)\n //return \"fake\"/old selected item\n return new SectionFieldItemModel({ id: value.item.fieldItemId, name: value.item.value, order: 0 });\n\n return null;\n };\n\n const setRadioValue = (fieldId: string, i: SectionFieldItemModel) => {\n const radioValue = new FormFieldItemValue();\n radioValue.fieldItemId = i.id!;\n radioValue.value = i.name;\n\n const itemModel = new FormRadioValue();\n itemModel.item = radioValue;\n itemModel.additionalFreeTextValue = value ? value.additionalFreeTextValue : \"\"\n setFieldValue(fieldId, itemModel);\n };\n\n return <>\n <PatientFormRadioGroup\n key={field.id!}\n field={field}\n value={value}\n selectedItem={getSelectedItem()}\n setSectionFieldItem={(i) => setRadioValue(field.id!, i)}\n setFreeTextValue={\n field.isAdditionalTextareaEnabled\n ? (av) => { setFieldValue(field.id!, new FormRadioValue({ item: value?.item, additionalFreeTextValue: av }), av) }\n : undefined}\n />\n </>\n };\n\n const getGenderString = (patient: PatientGeneralInfoResponse): string => {\n switch (patient.gender) {\n case Gender.Female:\n return t(\"Female\");\n case Gender.Male:\n return t(\"Male\");\n case Gender.PreferNotToSay:\n return t(\"I prefer not to say\");\n case Gender.Custom:\n return t(\"gender_custom\");\n default:\n return \"--\";\n }\n };\n\n const getGenderAsRadioValue = (gender: Gender | null) => {\n if (gender === null) return null;\n if (gender === Gender.Male) return new FormRadioValue({ item: maleGender });\n if (gender === Gender.Female) return new FormRadioValue({ item: femaleGender });\n if (gender === Gender.PreferNotToSay) return new FormRadioValue({ item: secretGender });\n return new FormRadioValue({ item: customGender });\n };\n\n const getGenderItemModels = () => {\n return [\n new SectionFieldItemModel({ id: maleGender.fieldItemId, name: maleGender.value }),\n new SectionFieldItemModel({ id: femaleGender.fieldItemId, name: femaleGender.value }),\n new SectionFieldItemModel({ id: secretGender.fieldItemId, name: secretGender.value }),\n new SectionFieldItemModel({ id: customGender.fieldItemId, name: customGender.value })];\n };\n\n const getDateOfBirthString = (date: Date | undefined) => {\n if (!date)\n return \"--\";\n\n var newDateObj = new Date(date);\n const day = newDateObj.toLocaleString(\n localeApp,\n {\n day: \"numeric\",\n }\n );\n let month = newDateObj.toLocaleString(\n localeApp,\n {\n month: \"long\",\n }\n );\n\n const year = newDateObj.toLocaleString(\n localeApp,\n {\n year: \"numeric\",\n }\n );\n\n return localeApp === \"es\"\n ? `${day}/${month}/${year}`\n : `${month.charAt(0).toUpperCase() + month.slice(1)}/${day}/${year}`;\n };\n\n const StaticBasicInformationSection: React.FC = () => {\n return <>\n <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(\"default_section_name_Basic patient information\", { ns: sectionTNamespace })}\n </Typography>\n <div className={classes.fieldsContainer}>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_First name(s)\", { ns: sectionTNamespace }) + \" \"} <span className={classes.fieldNameAsterisk}>*</span>\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {t(patient.firstName)}\n </Typography>\n </div>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Last name\", { ns: sectionTNamespace }) + \" \"} <span className={classes.fieldNameAsterisk}>*</span>\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {t(patient.lastName)}\n </Typography>\n </div>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Mobile\", { ns: sectionTNamespace }) + \" \"} <span className={classes.fieldNameAsterisk}>*</span>\n </Typography>\n {patient.mobile && hasCustomerInfoVisible\n ? <div className={classes.phoneNumberContainer}>\n <CountryFlagIcon iso={patient.mobileCodeIso3} />\n <Typography className={classes.phoneNumberCodeLabel}>\n {\"+\" + patient.mobileCode}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patient.mobile ? conformToMask(patient.mobile, GetMobileMaskByTemp(patient.mobileTemplate)).conformedValue : \"--\"}\n </Typography>\n </div>\n : <Typography className={classes.fieldValueLabel}>\n {\"--\"}\n </Typography>}\n </div>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Email\", { ns: sectionTNamespace })}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patient.email ? t(patient.email) : \"--\"}\n </Typography>\n </div>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Gender\", { ns: sectionTNamespace })}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {getGenderString(patient)}\n </Typography>\n </div>\n {patient.gender === Gender.Custom &&\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Custom gender\", { ns: sectionTNamespace })}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patient.customGender}\n </Typography>\n </div>\n }\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Date of Birth\", { ns: sectionTNamespace })}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {getDateOfBirthString(patient.dateOfBirth)}\n </Typography>\n </div>\n </div>\n </div>\n <div className={classes.divider}></div>\n <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(\"default_section_name_Notifications\", { ns: sectionTNamespace })}\n </Typography>\n <div className={classes.fieldsContainer}>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Appointment\", { ns: sectionTNamespace }) + \" \"}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patient.contactableAppointments ? t(\"Yes\") : t(\"No\")}\n </Typography>\n </div>\n <div className={classes.fieldContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(\"default_field_name_Massive sendings\", { ns: sectionTNamespace }) + \" \"}\n </Typography>\n <Typography className={classes.fieldValueLabel}>\n {patient.contactableMassiveSendings ? t(\"Yes\") : t(\"No\")}\n </Typography>\n </div>\n </div>\n </div>\n <div className={classes.divider}></div>\n </>\n };\n\n const NotesSection: React.FC = () => {\n return <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(\"Internal notes\")}\n </Typography>\n <div className={classes.fieldsContainer}>\n <div className={classes.fieldContainer}>\n <Typography className={patient.notes ? classes.notes : classes.noNotes}>\n {patient.notes ? <Interweave content={patient.notes} /> : t(\"No notes.\")}\n </Typography>\n </div>\n </div>\n </div>\n };\n\n const EditButton: React.FC = () => {\n return hasCustomerInfoVisible ? <div className={classes.editButtonContainer}>\n <ButtonWithSpinner\n width={108}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Main}\n hoverColor={ButtonPropsColor.Main}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Edit info\")}\n innerIcon={<EditIcon style={{ width: 18, height: 16 }} />}\n onClick={handleEditButtonClick}\n />\n </div>\n : <></>\n };\n\n const EditModeButtonsGroup: React.FC = () => {\n return <div className={classes.editModeButtonsGroupContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n hoverColor={ButtonPropsColor.Red}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Cancel\")}\n innerIcon={<CrossIcon style={{ width: 16, height: 14 }} viewBox=\"0 0 16 16\" />}\n onClick={handleCancelEditButtonClick}\n />\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Green}\n fill={ButtonPropsFill.Filled}\n innerText={t(\"Save changes\")}\n innerIcon={<SaveIcon style={{ width: 16, height: 16 }} />}\n onClick={handleSaveChangesButtonClick}\n disabled={stringify(new UpdatePatientFormDataRequest(patient)) === stringify(patientForEdit) || !isFormValid}\n />\n </div>\n };\n\n const CloseModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {t(\"Are you sure you want to cancel the editing of the data?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {t(\"The changes made will not be saved\")}\n </Typography>\n </div>);\n };\n\n\n return <>\n <div className={classes.root}>\n <div className={classes.sectionsListContainer}>\n {!isEdition\n ? <StaticBasicInformationSection />\n : <>\n <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(\"default_section_name_Basic patient information\", { ns: sectionTNamespace })}\n </Typography>\n <Typography className={classes.requiredFieldsNoteLabel}>\n {t(\"Required fields\")} <span className={classes.fieldNameAsterisk}>*</span>\n </Typography>\n <div className={classes.fieldsEditionContainer}>\n <div className={classes.fieldEditionContainer}>\n <PatientFormTextInput\n key={\"firstName\"}\n value={patientForEdit?.firstName ?? \"\"}\n setValue={setFirstName}\n label={t(\"default_field_name_First name(s)\", { ns: sectionTNamespace })}\n isValid={(v) => MultipleSpacesNameRegex.test(v) && v.trim() !== \"\"}\n required={true}\n placeholder={t(\"default_field_name_First name(s)\", { ns: sectionTNamespace })}\n maxLength={100} />\n </div>\n <div className={classes.fieldEditionContainer}>\n <PatientFormTextInput\n key={\"lastName\"}\n value={patientForEdit?.lastName ?? \"\"}\n setValue={setLastName}\n label={t(\"default_field_name_Last name\", { ns: sectionTNamespace })}\n isValid={(v) => MultipleSpacesNameRegex.test(v) && v.trim() !== \"\"}\n required={true}\n placeholder={t(\"default_field_name_Last name\", { ns: sectionTNamespace })}\n maxLength={100} />\n </div>\n <div className={classes.fieldEditionContainer}>\n <PatientFormMobileInput\n key={\"phoneNumber\"}\n mobileNumber={patientForEdit\n ? new FormPhoneNumberValue({\n countryIso: patientForEdit.mobileCodeIso3,\n body: patientForEdit.mobile\n })\n : new FormPhoneNumberValue({\n countryIso: accountSettings.countryInSettings!.iso3,\n body: \"\"\n })}\n label={t(\"default_field_name_Mobile\", { ns: sectionTNamespace })}\n setMobileNumber={setPhoneNumber}\n required={true}\n countryInSettings={accountSettings.countryInSettings!}\n countries={accountSettings.countries!} />\n </div>\n <div className={classes.fieldEditionContainer}>\n <PatientFormTextInput\n key={\"email\"}\n value={patientForEdit?.email ?? \"\"}\n setValue={setEmail}\n label={t(\"default_field_name_Email\", { ns: sectionTNamespace })}\n isValid={(v) => EmailRegex.test(v) || v === \"\"}\n required={false}\n placeholder={t(\"default_field_name_Email\", { ns: sectionTNamespace })}\n maxLength={100} />\n </div>\n <div className={classes.fieldEditionContainer}>\n <PatientFormRadioGroup\n key={\"gender\"}\n field={new SectionFieldModel({\n name: t(\"default_field_name_Gender\", { ns: sectionTNamespace }),\n items: getGenderItemModels(),\n isRequired: false,\n isDeleted: false,\n isAdditionalTextareaEnabled: false\n })}\n value={getGenderAsRadioValue(patientForEdit?.gender ?? null)}\n selectedItem={patientForEdit?.gender\n ? new SectionFieldItemModel({ id: getGenderAsRadioValue(patientForEdit.gender!)?.item.fieldItemId })\n : null}\n setSectionFieldItem={(i) => setPatientForEdit(prev => ({ ...prev!, gender: +i.id! }))}\n />\n {patientForEdit?.gender === Gender.Custom &&\n <div style={{marginTop: 10}}>\n <PatientFormTextInput\n key={\"customGender\"}\n value={patientForEdit?.customGender ?? \"\"}\n setValue={setCustomGender}\n label={\"\"}\n isValid={(v) => MultipleSpacesNameRegex.test(v) && v.trim() !== \"\"}\n required={true}\n placeholder={t(\"default_field_name_Custom gender\", { ns: sectionTNamespace })}\n maxLength={100}/>\n </div>\n }\n </div>\n <div className={classes.fieldEditionContainer}>\n <PatientFormDateInput\n key={\"dob\"}\n value={patientForEdit?.dateOfBirth ?? null}\n setValue={setDob}\n label={t(\"default_field_name_Date of Birth\", { ns: sectionTNamespace })}\n required={false}\n isValid={(v) => validateDobField(v)} \n minDate={year1900Date} \n maxDate={yesterdayDate} />\n </div>\n </div>\n </div>\n <div className={classes.editDivider}></div>\n <div className={classes.sectionContainer}>\n <Typography className={classes.sectionLabel}>\n {t(\"default_section_name_Notifications\", { ns: sectionTNamespace })}\n </Typography>\n <div className={classes.fieldsEditionContainer}>\n <div className={classes.fieldEditionContainer}>\n <div className={classes.switch}>\n <Switch\n onChange={setContactableAppointments}\n value={patientForEdit?.contactableAppointments ?? false}\n />\n <div className={classes.switchLabel}>\n <label className={classes.label}>\n {t(\"default_field_name_Appointment\", { ns: sectionTNamespace })}\n </label>\n <p className={classes.description}>\n {appointmentDescription}\n </p>\n </div>\n </div>\n </div>\n <div className={classes.fieldEditionContainer}>\n <div className={classes.switch}>\n <Switch\n onChange={setContactableMassiveSendings}\n value={patientForEdit?.contactableMassiveSendings ?? false}\n />\n <div className={classes.switchLabel}>\n <label className={classes.label}>\n {t(\"default_field_name_Massive sendings\", { ns: sectionTNamespace })}\n </label>\n <p className={classes.description}>\n {massiveSendingsDescription}\n </p>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div className={classes.editDivider}></div>\n </>}\n {mapSectionsToComponents()}\n {!isEdition\n ? <NotesSection />\n : <div className={classes.sectionContainer}>\n <div className={classes.notesEditLabelContainer}>\n <InternalNotesIcon />\n <Typography className={classes.sectionLabel}>\n {t(\"Internal notes\")}\n </Typography>\n </div>\n <div className={classes.fieldsContainer}>\n <div className={classes.tinyMceContainer}>\n <div className={`${classes.tinyMceOverrides} ${focusedNotes ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"No notes.\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n forced_root_block: \"\"\n }}\n value={patientForEdit?.notes}\n onFocusIn={() => setFocusedNotes(true)}\n onBlur={() => setFocusedNotes(false)}\n onInit={setNotesTextLengthOnInit}\n onEditorChange={setNotes}\n outputFormat=\"html\"\n onChange={(e) => {\n if (notesTextLength >= maxNotesTextLength) {\n e.preventDefault();\n }\n }}\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{notesTextLength + \"/\" + maxNotesTextLength}</span>\n </div>\n </div>\n </div>\n </div>\n </div>}\n {!isEdition\n ? <EditButton />\n : <EditModeButtonsGroup />}\n </div>\n </div>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<CloseModalContent />}\n open={cancelEditModalIsOpen}\n onClose={() => setCancelEditModalIsOpen(false)}\n onConfirm={handleCloseEdit}\n />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n noFilesCaption: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#6462F3\",\n marginTop: 34,\n textAlign: \"center\"\n },\n noFilesIcon: {\n position: \"relative\",\n top: 76,\n left: 210,\n width: 266\n },\n fileNameContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-start\"\n },\n actionsContainer: {\n display: \"flex\",\n alignItems: \"center\"\n },\n grid: {\n marginRight: \"auto\",\n marginTop: 50,\n marginLeft: \"auto\",\n width: \"95%\",\n \"& .MuiPagination-root\": {\n marginTop: 30\n },\n \"& td\": {\n padding: \"7px 0px 7px 12px\"\n },\n \"&>div>div, &>div>div>div\":{\n height: \"calc(100vh - 254px)\",\n }\n },\n classRow: {\n // cursor: \"pointer\",\n \"& div.buttonRow\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n \"& div.buttonRow\": {\n visibility: \"visible\"\n }\n }\n },\n removeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n marginTop: 7\n },\n closeModalContentHeaderText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n textAlign: \"center\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n closeConfirmationModal: {\n minHeight: \"240px !important\",\n height: \"auto !important\",\n },\n addButton: { \n position: \"relative\",\n top: 25,\n left: 650,\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst NoFilesIcon = () => (\n <SvgIcon style={{ width: 266, height: 191 }}\n viewBox={\"0 0 266 196\"}>\n <path\n d=\"M0.771601 55.4022C-4.31468 95.4126 16.2093 136.431 48.6351 160.419C81.0609 184.408 123.731 192.326 163.658 186.578C192.16 182.494 220.43 171.319 240.518 150.694C260.607 130.068 271.197 99.0798 263.106 71.4481C260.047 61.0132 254.042 50.9002 244.513 45.6589C229.296 37.311 210.525 43.4288 194.319 49.7017C178.112 55.9746 159.37 62.1521 144.118 53.8757C132.401 47.5014 126.378 34.3773 117.792 24.169C103.189 6.81121 79.4628 -2.40729 56.9711 0.544297C54.1549 0.91488 51.3662 1.47063 48.6232 2.20792C24.6944 8.62987 6.60323 28.2893 1.37981 52.5102L0.771601 55.4022Z\"\n fill=\"rgb(225, 233, 254)\"\n />\n <path\n d=\"M89.2121 72.0544L68.1037 180.458L65.3608 194.65L206.083 193.97C212.404 193.94 218.009 188.329 220.03 179.993L244.991 77.6535C246.535 71.327 243.148 64.744 238.354 64.75L95.8904 64.8991C92.7898 64.8931 90.0111 67.8268 89.2121 72.0544Z\"\n fill=\"#FF725E\"\n />\n <path\n d=\"M89.2121 72.0544L68.1037 180.458L65.3608 194.65L206.083 193.97C212.404 193.94 218.009 188.329 220.03 179.993L244.991 77.6535C246.535 71.327 243.148 64.744 238.354 64.75L95.8904 64.8991C92.7898 64.8931 90.0111 67.8268 89.2121 72.0544Z\"\n fill=\"#6462F3\"\n />\n <path\n d=\"M192.601 173.1L177.694 53.0033C177.098 48.084 173.169 44.4109 168.535 44.4288L135.859 44.5301C134.645 44.5438 133.446 44.8047 132.336 45.2967C131.226 45.7888 130.227 46.5018 129.402 47.3923L113.898 63.8914L23.025 64.3803C17.4736 64.4102 13.2042 69.6694 13.9376 75.5725L27.7773 186.57C28.3736 191.484 32.3031 195.151 36.9243 195.145L195.326 194.829C212.964 195.193 214.652 189.987 214.652 189.987C194.402 194.465 192.601 173.13 192.601 173.1Z\"\n fill=\"#9FA9E6\"\n />\n <circle xmlns=\"http://www.w3.org/2000/svg\" cx=\"58.9628\" cy=\"128.963\" r=\"5.96281\" fill=\"#323947\"/>\n <circle xmlns=\"http://www.w3.org/2000/svg\" cx=\"141.25\" cy=\"128.963\" r=\"5.96281\" fill=\"#323947\"/>\n <path\n fillRule=\"evenodd\"\n clipRule=\"evenodd\"\n d=\"M112.243 137.306C112.126 137.422 111.937 137.421 111.819 137.307C105.24 130.952 94.7978 130.952 88.2195 137.307C88.1011 137.421 87.9117 137.422 87.7953 137.306V137.306C87.6789 137.189 87.6795 137 87.7979 136.885C94.6091 130.297 105.429 130.297 112.24 136.885C112.359 137 112.359 137.189 112.243 137.306V137.306Z\"\n stroke=\"#323947\"\n strokeWidth={3}\n />\n </SvgIcon>\n);\n\nexport default NoFilesIcon;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 488,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n paddingBottom: \"12px\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n\n dropZone: {\n height: \"136px\",\n width: \"373px\",\n background: \"rgba(100, 98, 243, 0.1)\",\n border: \"0px dashed\",\n borderRadius: \"15px\",\n borderColor: theme.colors.clearMain,\n minHeight: \"100px\",\n backgroundImage: `url(\"data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='15' ry='15' stroke='%236462F3FF' stroke-width='2' stroke-dasharray='12%2c 12' stroke-dashoffset='0' stroke-linecap='round'/%3e%3c/svg%3e\")`,\n animation: 'none !important',\n },\n\n dropZoneText: {\n color: theme.colors.clearMain,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n position: \"relative\",\n top: \"70px\",\n },\n fileName: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n },\n fileSize: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n paddingTop: \"4px\",\n },\n fileSizeBold: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n },\n downloadTemplate: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n notesTitle: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n notes: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n divider: {\n borderTop: \"1px solid\",\n borderColor: theme.colors.grey2,\n marginTop: \"24px\",\n marginBottom: \"24px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n cancelModalButton: {\n width: 244,\n height: 39,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 14,\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n modalTitleTextCancel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 18,\n fontWeight: \"bold\"\n },\n goBackCancel: {\n marginRight: 38,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n link: {\n color: theme.colors.clearMain,\n cursor: \"pointer\"\n },\n commentsLabel: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontSize: 14,\n fontWeight: 400\n },\n label: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n marginTop: 32\n },\n inputClass: {\n ...theme.typography.body2,\n height: \"70px !important\",\n backgroundColor: \"inherit !important\",\n \n resize: \"none\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"normal\",\n opacity: 0.8,\n }\n }\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect } from \"react\";\nimport { useParams } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { DropzoneAreaBase, FileObject } from \"material-ui-dropzone\";\nimport useStyles from \"./css\";\nimport { PatientImportClinicalFileModalProps } from \"./props\";\nimport { Box, Grid } from \"@material-ui/core\";\n\nimport { PDFIcon, UploadFileCloud, WordIcon, ImageIcon, } from \"../../../assets/icons\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { useAppDispatch } from \"../../../redux/hooks\";\nimport TextareaWithLabel from \"../../common/TextareaWithLabel\";\nimport ConfirmActionModal from \"../../common/ConfirmActionModal\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\nconst PatientImportClinicalFileModal = (props: PatientImportClinicalFileModalProps) => {\n const { t } = useTranslation([\"general\"]);\n const { open, onClose, refreshFiles, evolutionNoteId } = props;\n const classes = useStyles();\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [openCancelModal, setOpenCancelModal] = useState<boolean>(false);\n const [cancelModalShouldAppear, setCancelModalShouldAppear] = useState<boolean>(false);\n const [file, setFile] = useState<FileObject[]>([]);\n const [fileSize, setFileSize] = useState<number>(0);\n const [fileName, setFileName] = useState<string>(t(\"No file attached.\"));\n const [fileComment, setFileComment] = useState<string>(\"\");\n const [fileExtension, setFileExtension] = useState<string>(\"pdf\");\n const [isValid, setIsValid] = useState<boolean>(false);\n const maxFileSize: number = 1 * 1024 * 10240;\n const { customerId } = useParams<any>();\n \n const { enqueueAlert } = alertsActions;\n const dispatch = useAppDispatch();\n \n useEffect(() => {\n setOpenModal(open);\n if (open === true) {\n cleanupModal();\n }\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n \n const handleTryCloseModal = () => {\n if (cancelModalShouldAppear) {\n setOpenCancelModal(true);\n } else {\n handleCloseModal();\n }\n };\n \n const handleCloseModal = () => {\n setOpenModal(false);\n if (onClose) {\n setFileExtension(\"pdf\");\n onClose();\n }\n };\n \n const handleOnUploadClick = async () => {\n handleCloseModal();\n if (isValid) {\n setIsValid(false);\n let uploadResponse = await CustomerService.uploadPatientClinicalFile(\n file[0].file,\n customerId,\n evolutionNoteId ?? \"\",\n fileComment\n );\n if (uploadResponse?.uploaded) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"File uploaded\"),\n description: t(fileName),\n })\n );\n cleanupModal();\n refreshFiles();\n } else {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\")\n })\n );\n }\n }\n };\n \n const handleOnAddFile = (files: FileObject[]) => {\n setFile(files);\n setFileName(files[0].file.name);\n let size = files[0].file.size / (1024 * 1024);\n setFileSize(Math.round((size + Number.EPSILON) * 100) / 100); // in megabytes\n setIsValid(validateFile(files[0].file));\n \n setCancelModalShouldAppear(true);\n };\n \n const handleDropRejected = (file: File[]) => {\n let fileExtension = file[0].name.split(\".\").pop();\n let allowedExtension = [\"png\", \"jpg\", \"docx\", \"pdf\"];\n\n if (allowedExtension.indexOf(fileExtension!) == -1) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Format not allowed\")\n })\n );\n return;\n } else {\n setFileExtension(fileExtension ?? 'pdf');\n }\n \n if (file[0].size > maxFileSize) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"The file exceeds the maximum size allowed\")\n })\n );\n }\n };\n \n const validateFile = (file: File) => {\n if (file.size > maxFileSize)\n //10 megabyte\n return false;\n let fileExtension = file.name.split(\".\").pop();\n let allowedExtension = [\"png\", \"jpg\", \"docx\", \"pdf\"];\n let isValid = allowedExtension.indexOf(fileExtension!) > -1;\n if (isValid) {\n setFileExtension(fileExtension ?? \"pdf\");\n }\n return (allowedExtension.indexOf(fileExtension!) > -1);\n };\n \n const cleanupModal = () => {\n setFile([]);\n setFileName(t(\"No file attached.\"));\n setFileSize(0);\n setFileComment(\"\");\n setIsValid(false);\n setCancelModalShouldAppear(false);\n setOpenCancelModal(false);\n };\n \n const handleInputChange = (e: any) => {\n const { name, value } = e.target;\n setFileComment(value);\n };\n \n const CancelNewEvolutionNoteModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.modalTitleTextCancel} >\n {t(\"Cancel file upload?\")}\n </Typography>\n </div>);\n };\n \n return (\n <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={handleTryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div>\n <div\n className={classes.paper}\n >\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {t(\"Upload files\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={244}\n margin={\"0px 16px 0px 0px\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n innerText={t(\"Cancel\")}\n onClick={handleTryCloseModal}\n />\n <ButtonWithSpinner\n width={244}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Upload file\")}\n onClick={handleOnUploadClick}\n disabled={!isValid}\n />\n </div>\n </div>\n <Box sx={{ width: \"100%\" }} pt={1}>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <DropzoneAreaBase\n dropzoneClass={classes.dropZone}\n dropzoneParagraphClass={classes.dropZoneText}\n fileObjects={file}\n dropzoneText={t(\n \"Drag or click here to upload your file\"\n )}\n onAdd={handleOnAddFile}\n showPreviewsInDropzone={false}\n showAlerts={false}\n filesLimit={1}\n acceptedFiles={[\n \"application/pdf,.docx,.jpg,.png\",\n ]}\n maxFileSize={maxFileSize}\n onDropRejected={handleDropRejected}\n // @ts-ignore: type negotiation problem\n Icon={UploadFileCloud} // works and builds but https://github.com/Yuvaleros/material-ui-dropzone/issues/246\n />\n </Grid>\n {fileExtension === \"pdf\" && <Grid item xs={1} style={{ paddingLeft: \"48px\", paddingTop: 25 }}>\n <PDFIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>}\n {fileExtension === \"docx\" && <Grid item xs={1} style={{ paddingLeft: \"38px\", paddingTop: 16 }}>\n <WordIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>}\n {(fileExtension === \"jpg\" || fileExtension === \"png\") && <Grid item xs={1} style={{ paddingLeft: \"38px\", paddingTop: 16 }}>\n <ImageIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>}\n <Grid\n item\n xs={5}\n style={{ paddingLeft: \"48px\", paddingTop: \"30px\", wordWrap: \"break-word\" }}\n >\n <Typography className={classes.fileName}>\n {fileName}\n </Typography>\n <Typography className={classes.fileSize}>\n {t(\"Size: \")}\n <b>{fileSize} MB</b>\n </Typography>\n </Grid>\n </Grid>\n \n <TextareaWithLabel\n name=\"comments\"\n value={fileComment}\n onChange={handleInputChange}\n width=\"100%\"\n inputClass={classes.inputClass}\n label={() => (<>\n <Typography className={classes.commentsLabel}>\n {t(\"Comments\")}\n </Typography>\n </>)}\n showCounter={true}\n labelClass={classes.label}\n placeholder={t(\"Write your comments here\")}\n maxLength={180}\n />\n \n <hr className={classes.divider}/>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <Typography className={classes.notesTitle}>\n {t(\"NOTES: \")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Accepted formats .jpg . png .docx .pdf\")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Maximum allowed file size: 10MB\")}\n </Typography>\n </Grid>\n <Grid\n item\n xs={6}\n container\n direction=\"row\"\n alignItems=\"center\"\n justifyContent=\"flex-end\"\n >\n </Grid>\n </Grid>\n </Box>\n </div>\n <div>\n <ConfirmActionModal\n onClose={() => setOpenCancelModal(false)}\n open={openCancelModal}\n onConfirm={handleCloseModal}\n content={<CancelNewEvolutionNoteModalContent/>}\n />\n </div>\n </div>\n\n </Fade>\n </Modal>\n </>\n );\n};\n\nexport default PatientImportClinicalFileModal;\n","import React, { useEffect, useState } from \"react\";\nimport { useParams } from \"react-router-dom\";\nimport Typography from \"@material-ui/core/Typography\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport { useTranslation } from \"react-i18next\";\nimport { Button } from \"@material-ui/core\";\nimport { useDispatch } from 'react-redux';\n\nimport useStyles from \"./css\";\n\nimport NoFilesIcon from \"../../../assets/icons/NoFilesIcon\";\nimport PatientImportClinicalFileModal from \"./../PatientImportClinicalFileModal\";\nimport GridList, { OnChangeEvent } from \"../../common/grid/GridList\";\nimport { TableColumn } from \"../../common/grid/table-column\";\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { CustomerClinicalFile } from \"../../../models/customer-clinical-file\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { DownloadFileCloud, ImageIcon, PDFIcon, TrashIcon, WordIcon } from \"../../../assets/icons\";\nimport ConfirmDeleteModal from \"../../common/ConfirmDeleteModal\";\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsFill } from \"../../../models/enums/button-props-fill\";\n\nconst CustomerClinicalFiles = () => {\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const { customerId } = useParams<any>();\n const dispatch = useDispatch();\n const { enqueueAlert } = alertsActions;\n \n const [importModalIsOpen, setImportModalIsOpen] = useState<boolean>(false);\n const [deleteFileModalIsOpen, setDeleteFileModalIsOpen] = useState<boolean>(false);\n const [deletableFile, setDeletableFile] = useState<CustomerClinicalFile>();\n const [customerClinicalFiles, setCustomerClinicalFiles] = useState<CustomerClinicalFile[]>([]);\n const [page, setPage] = useState<number>(1);\n const [total, setTotal] = useState<number>(1);\n const pageSize: number = 20;\n \n useEffect(() => {\n getData();\n }, [page]);\n \n const getData = () => {\n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n let data = await CustomerService.getPatientClinicalFiles(\n page,\n pageSize,\n customerId\n );\n dispatch(navbarActions.setShowLoader(false));\n setCustomerClinicalFiles(data.entity!);\n setTotal(data.total!)\n })();\n };\n \n let handleUploadFilesButton = () => {\n setImportModalIsOpen(true);\n };\n \n const getUploadDate = (startDate: Date): string => {\n const date = new Date(startDate);\n \n const day = date.toLocaleString(localeApp, {\n day: \"2-digit\",\n });\n \n const month = date.toLocaleString(localeApp, {\n month: \"long\",\n }).toLowerCase();\n \n const year = date.toLocaleString(localeApp, {\n year: \"numeric\",\n });\n \n const time = date.toLocaleString(localeApp, {\n hour: \"2-digit\",\n minute: \"2-digit\",\n hour12: false,\n });\n \n if (localeApp === \"es\")\n return `${day}/${month}/${year} \\n ${time} hrs`;\n else\n return `${month}/${day}/${year} \\n ${time} hrs`;\n };\n \n const handleOnChangeGrid = (event: OnChangeEvent) => {\n setPage(event.page);\n };\n const getExtenstionImage = (name: string) => {\n if (name) {\n let fileExtension = name.split(\".\").pop();\n switch (fileExtension) {\n case \"pdf\":\n return <div style={{ padding: 8 }}><PDFIcon width={16} style={{ color: \"#5C6477\" }}></PDFIcon></div>\n case \"docx\":\n return <WordIcon width={32} style={{ color: \"#5C6477\" }}></WordIcon>\n case \"jpg\":\n return <ImageIcon width={32} style={{ color: \"#5C6477\" }}></ImageIcon>\n case \"png\":\n return <ImageIcon width={32} style={{ color: \"#5C6477\" }}></ImageIcon>\n default:\n return <PDFIcon width={16} style={{ color: \"#5C6477\" }}></PDFIcon>\n }\n }\n \n };\n const handleDeleteFile = (file: CustomerClinicalFile) => {\n setDeletableFile(file);\n setDeleteFileModalIsOpen(true);\n };\n \n const handleOnRemoveFileConfirm = () => {\n (async () => {\n const data = await CustomerService.deletePatientClinicalFile(deletableFile?.s3Key!);\n if (data) {\n getData();\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"File successfully deleted\"),\n description: deletableFile?.fileName,\n }));\n }\n })();\n setDeleteFileModalIsOpen(false);\n };\n \n const handleDownloadFile = (s3Key: string) => {\n (async () => {\n const data = await CustomerService.getPatientClinicalFileUrl(s3Key);\n if (data.entity) {\n let fileUrl = data.entity.toString();\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", fileUrl);\n link.setAttribute(\"target\", \"_blank\");\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n })();\n };\n \n const columns: TableColumn[] = [\n {\n id: \"fileName\",\n label: t(\"NAME\"),\n sorting: false,\n completeObject: true,\n width: 130,\n component: (item: any) => <>\n <div className={classes.fileNameContainer}>\n <div style={{ fontWeight: 700 }}>\n {getExtenstionImage(item.fileName)}\n </div>\n <div style={{ wordBreak: \"break-word\" }}>\n {t(item.fileName)}\n </div>\n </div>\n </>,\n },\n {\n id: \"uploadedBy\",\n label: t(\"UPLOADED\"),\n width: 80,\n completeObject: true,\n component: (item: any) => <>\n <div style={{ marginLeft: 3 }}>\n {item.uploadedBy}\n </div>\n </>,\n },\n {\n id: \"created\",\n label: t(\"DATE AND TIME\"),\n width: 20,\n completeObject: true,\n component: (item: any) => <>\n <div style={{ whiteSpace: \"pre-line\", marginLeft: 3 }}>\n {getUploadDate(item.created)}\n </div>\n </>,\n },\n {\n id: \"comments\",\n label: t(\"COMMENTS\"),\n width: 130,\n completeObject: true,\n component: (item: any) => <>\n {item.comments\n ? item.comments\n : <div style={{ color: \"#919CA5\", marginLeft: 3 }}>\n {t(\"No comments\")}\n </div>}\n </>,\n },\n {\n id: \"s3Key\",\n label: t(\"ACTIONS\"),\n width: 60,\n completeObject: true,\n component: (item: any) => <>\n <div className={classes.actionsContainer}>\n <IconButton\n onClick={() => handleDownloadFile(item.s3Key)}>\n <DownloadFileCloud/>\n </IconButton>\n <IconButton\n onClick={() => handleDeleteFile(item)}>\n <TrashIcon style={{ color: \"#5C6477\" }}/>\n </IconButton>\n </div>\n </>,\n },\n ];\n \n const RemoveFileModalContent: React.FC = () => {\n return (<div className={classes.removeModalContentContainer}>\n <Typography className={classes.closeModalContentHeaderText}>\n {t(\"Are you sure to delete the file?\")}\n </Typography>\n <div className={classes.separator}/>\n <Typography className={classes.closeModalContentText}>\n {deletableFile?.fileName}\n </Typography>\n </div>);\n };\n \n return (\n <div>\n <div className={classes.addButton}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n fill={ButtonPropsFill.Outlined}\n innerText={t(\"Upload file\")}\n onClick={handleUploadFilesButton}\n />\n </div>\n \n {customerClinicalFiles.length === 0 &&\n <div className={classes.noFilesIcon}>\n <NoFilesIcon></NoFilesIcon>\n <Typography className={classes.noFilesCaption}>\n {t(\"No files\")}\n </Typography>\n </div>}\n \n {customerClinicalFiles.length > 0 &&\n <div className={classes.grid}>\n <GridList\n columns={columns}\n items={customerClinicalFiles}\n height={460}\n totalItems={total}\n pageSize={pageSize}\n showPaginationAlways={false}\n onChange={handleOnChangeGrid}\n classRow={classes.classRow}\n />\n </div>\n }\n \n <PatientImportClinicalFileModal\n open={importModalIsOpen}\n refreshFiles={getData}\n onClose={() => setImportModalIsOpen(false)}\n ></PatientImportClinicalFileModal>\n <ConfirmDeleteModal\n textButtonConfirm={t(\"Delete\")}\n classModal={classes.closeConfirmationModal}\n open={deleteFileModalIsOpen}\n item={deletableFile}\n componentInfo={<RemoveFileModalContent/>}\n onClose={() => {\n setDeleteFileModalIsOpen(false)\n setDeletableFile(undefined);\n }}\n onDelete={handleOnRemoveFileConfirm}\n />\n </div>\n );\n};\n\nexport default CustomerClinicalFiles;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n maxHeight: \"calc(100vh - 152px)\",\n overflowY: \"scroll\",\n borderRadius: \"0px 0px 12px 12px\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n \"& .MuiAccordion-root\": {\n },\n \"& .MuiAccordionSummary-root\": {\n background: \"#FAFAFA\",\n minHeight: \"unset\",\n height: \"46px\"\n },\n \"& .MuiAccordionSummary-root.Mui-expanded\": {\n minHeight: 0,\n },\n \"& .MuiAccordionSummary-content\": {\n margin: 0,\n },\n \"& .MuiPaper-elevation1\": {\n boxShadow: \"none\"\n },\n \"& .MuiAccordionDetails-root\": {\n padding: \"40px 16px 24px 16px\"\n },\n },\n sectionsListContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n paddingBottom: \"24px\",\n },\n sectionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n fieldsEditionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n flexWrap: \"wrap\",\n width: \"100%\",\n gap: 24\n },\n fieldEditionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n width: \"100%\",\n gap: 2\n },\n sectionLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.clear2\n },\n signatureBlock: {\n marginBottom: 15,\n fontSize: 12\n },\n signatureBlockTitle: {\n fontWeight: 700,\n marginBottom: 5,\n fontSize: 12,\n color: \"#676767\",\n },\n signatureBlockCheckbox: {\n display: \"flex\",\n alignItems: \"center\",\n \"& > *:first-child\": {\n marginRight: 5\n },\n \"& > div\": {\n display: \"flex\"\n }\n },\n asterisk: {\n color: \"#6462F3\"\n },\n signatureSectionContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n width: \"100%\",\n gap: 10\n },\n signatureSectionTitle: {\n fontWeight: 700,\n marginBottom: 5,\n fontSize: 12,\n color: \"#676767\",\n },\n signatureContainer: {\n flexDirection: \"column\"\n },\n emptySignatureBox: {\n width: 329,\n height: 118,\n border: \"1px solid rgba(0, 0, 0, 0.1)\",\n borderRadius: \"5px\"\n },\n signaturePlaceholder: {\n padding: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: \"#676767\",\n opacity: \"0.8\",\n },\n metaInfoContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 9\n },\n metaInfoFieldContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n metaInfoFieldTitle: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray4,\n },\n metaInfoFieldValue: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n },\n signature: {\n border: \"1px solid rgba(0, 0, 0, 0.1)\",\n borderRadius: \"5px\"\n },\n checkBoxText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: 400\n },\n link: {\n fontWeight: 700,\n \"&:focus\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n },\n \"&:hover\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n },\n \"&:visited\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n },\n \"&:link\" : {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n },\n \"&:active\": {\n textDecoration: \"none\",\n color: theme.colors.clearMain\n }\n }\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n width: \"100%\",\n backgroundColor: theme.colors.white\n },\n radios: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n },\n freeTextAreaContainer: {\n paddingTop: 15,\n position: \"relative\",\n left: \"-2px\"\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.subtitle2,\n \n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n position: \"relative\",\n left: \"-10px\"\n },\n radio: {\n color: theme.colors.grey5,\n paddingRight: 9,\n \"& svg\": {\n width: 14,\n height: 14\n }\n },\n text: {\n paddingRight: 3,\n \n ...theme.typography.txtBody1,\n color: theme.colors.grey5\n },\n checked: {\n color: theme.colors.clearMain,\n fontWeight: 700,\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { Radio } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { ClinicalHistoryRadioProps } from \"./props\";\n\n\nexport default function ClinicalHistoryRadio(props: ClinicalHistoryRadioProps) {\n \n const { value, checked, onCheck } = props;\n \n const classes = useStyles();\n \n function handleChecking() {\n onCheck();\n }\n \n return (\n <div className={classes.root}>\n <Radio\n checked={checked}\n onChange={handleChecking}\n color={checked ? \"primary\" : \"default\"}\n classes={{\n root: classes.radio,\n checked: classes.checked\n }}\n />\n <div className={`${classes.text} ${checked ? classes.checked : ''}`}>{value}</div>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number | string) =>\n makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n backgroundColor: \"#FFFFFF\",\n position: \"relative\"\n },\n input: {\n backgroundColor: \"#FFFFFF\",\n height: 65,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: \"100%\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: theme.colors.grey6,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n inputWidth: {\n width: \"100%\"\n },\n counter: {\n position: \"absolute\",\n bottom: 7,\n right: 18,\n fontSize: 12,\n color: \"#B5B9C1\",\n padding: \"5px\",\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: \"auto\",\n },\n inputDisabled: {\n color: \"#676767\",\n }\n }));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { InputBase } from \"@material-ui/core\";\n\nimport { ClinicalHistoryFreeTextInputProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function ClinicalHistoryFreeTextInput(props: ClinicalHistoryFreeTextInputProps) {\n \n const { value, setValue, placeholder, width, disabled, onBlur, maxLength } = props;\n \n const classes = useStyles(width)();\n \n function handleOnChange(event: any) {\n setValue(event.target.value);\n }\n \n return (\n <div className={classes.root}>\n <InputBase\n className={classes.input}\n placeholder={placeholder}\n value={value}\n onChange={handleOnChange}\n onBlur={() => onBlur && onBlur(value)}\n disabled={disabled}\n multiline\n rows={3}\n inputProps={{\n className: classes.inputWidth,\n maxLength: maxLength\n }}\n />\n <div className={classes.counter}>{`${value?.length}/${maxLength}`}</div>\n\n </div>\n );\n}","import React, { useEffect, useState } from 'react';\n\nimport { ClinicalHistoryRadioGroupProps } from \"./props\";\nimport useStyles from \"./css\";\nimport PatientFormRadio from \"../ClinicalHistoryRadio\";\nimport useControlLabel from \"../../../../hooks/useControlLabel\";\nimport { useTranslation } from 'react-i18next';\nimport { SectionFieldItemModel } from '../../../../models/section-field-item-model';\nimport ClinicalHistoryFreeTextInput from '../ClinicalHistoryFreeTextInput';\n\n\nexport default function ClinicalHistoryRadioGroup(props: ClinicalHistoryRadioGroupProps) {\n\n const { field, value, selectedItem, setSectionFieldItem, setFreeTextValue, onTextAreaBlur } = props;\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const classes = useStyles();\n\n const ControlLabel = useControlLabel({ label: t(field.name, { ns: sectionTNamespace }), required: field.isRequired });\n\n const [initialTextAreaValue, setInitialTextAreaValue] = useState<string | null>(null);\n const [items, setItems] = useState<SectionFieldItemModel[]>(field.items.filter((i: SectionFieldItemModel) => {\n if (field.isDeleted)\n return true;\n else {\n return !i.isDeleted\n }\n }));\n\n useEffect(() => {\n if (!value || items.some(i => i.id === value.item.fieldItemId)) {\n return;\n }\n\n const itemsWithOldValue = [...items];\n itemsWithOldValue.unshift(new SectionFieldItemModel({ id: value.item.fieldItemId, name: value.item.value, order: 0 }))\n setItems(itemsWithOldValue);\n }, []);\n\n useEffect(() => {\n if (initialTextAreaValue !== null && value?.additionalFreeTextValue)\n return;\n setInitialTextAreaValue(value?.additionalFreeTextValue ?? null) \n }, []);\n\n function itemAsRenderItem(item: SectionFieldItemModel) {\n return (\n <div>\n <PatientFormRadio\n key={item.name}\n value={t(item.name, { ns: sectionTNamespace })}\n checked={selectedItem !== null && selectedItem.id === item.id}\n onCheck={() => setSectionFieldItem(item)}\n />\n </div>\n );\n }\n\n return (\n <div className={classes.root}>\n <ControlLabel />\n <div className={classes.radios}>\n {\n items.sort((i1, i2) => i1.order - i2.order).map(itemAsRenderItem)\n }\n </div>\n {\n (value?.additionalFreeTextValue !== \"\" || field.isAdditionalTextareaEnabled) && setFreeTextValue\n ?\n <div className={classes.freeTextAreaContainer}>\n <ClinicalHistoryFreeTextInput\n key={field.id! + \"freeTextInput\"}\n value={value?.additionalFreeTextValue ?? \"\"}\n setValue={setFreeTextValue}\n onBlur={(textAreaValue) => {onTextAreaBlur && onTextAreaBlur(textAreaValue, initialTextAreaValue)}}\n placeholder={`${t(\"Write here your notes for\")} ${t(field.name, { ns: sectionTNamespace })}`}\n maxLength={1500}\n />\n </div>\n :\n null\n }\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = () =>\n makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n backgroundColor: theme.colors.white,\n position: \"relative\"\n },\n input: {\n backgroundColor: theme.colors.white,\n height: 65,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: \"100%\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: theme.colors.grey6,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n marginTop: 10\n },\n inputFocused: {\n border: \"solid 1px #6462F3\",\n padding: \"14px 0px 14px 12px\",\n width: \"100%\",\n },\n inputDisabled: {\n color: \"#676767\",\n },\n counter: {\n position: \"absolute\",\n bottom: 7,\n right: 18,\n fontSize: 12,\n color: \"#B5B9C1\",\n padding: \"5px\",\n },\n inputError: {\n color: theme.colors.clearRed,\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearRed\n },\n }));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { InputBase } from \"@material-ui/core\";\n\nimport { ClinicalHistoryTextInputProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport useControlLabel from \"../../../../hooks/useControlLabel\";\nimport useInputFirstTouch from \"../../../../hooks/useInputFirstTouch\";\n\n\nexport default function ClinicalHistoryTextInput(props: ClinicalHistoryTextInputProps) {\n \n const { value, setValue, label, required, placeholder, isValid, disabled, maxLength, key, onBlur } = props;\n \n const classes = useStyles()();\n \n const { t } = useTranslation(\"general\");\n \n function handleOnChange(event: any) {\n setValue(event.target.value);\n }\n \n function isError(): boolean {\n if (!isValid || isValid(value) === undefined) {\n return false;\n }\n return !isValid(value);\n }\n \n const ControlLabel = useControlLabel({ label, required });\n const { hasBeenTouched, handleFirstTouch } = useInputFirstTouch();\n \n return (\n <div className={classes.root}>\n <ControlLabel />\n <InputBase\n key={key}\n className={`${classes.input} ${hasBeenTouched && isError() ? classes.inputError : \"\"}`}\n placeholder={`${t(\"Write here your notes for\")} ${placeholder}`}\n value={value}\n onChange={handleOnChange}\n onBlur={() => {handleFirstTouch(); onBlur();}}\n disabled={disabled}\n multiline\n rows={3}\n inputProps={{\n maxLength: maxLength\n }}\n />\n <div className={classes.counter}>{`${value?.length}/${maxLength}`}</div>\n </div>\n );\n}","export class UpdatePatientObservationsRequest {\n customerId: string;\n observations: string | null | undefined;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.customerId = x.customerId;\n this.observations = x.observations;\n } else {\n this.customerId = \"\";\n this.observations = null;\n }\n }\n}","import { SectionFieldModel } from \"./section-field-model\";\nimport { SectionFieldValueModel } from \"./section-field-value-model\";\n\nexport class ClinicalHistoryFieldAndValue {\n field: SectionFieldModel;\n value: SectionFieldValueModel | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.field = x.field;\n this.value = x.value;\n }\n else {\n this.field = new SectionFieldModel();\n this.value = new SectionFieldValueModel();\n }\n }\n}","import { ClinicalHistoryFieldAndValue } from \"./clinical-history-field-and-value\";\n\nexport class UpdatePatientClinicalHistoryFieldValueRequest {\n customerId: string;\n fieldAndValue: ClinicalHistoryFieldAndValue;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.customerId = x.customerId;\n this.fieldAndValue = x.fieldAndValue;\n } else {\n this.customerId = \"\";\n this.fieldAndValue = new ClinicalHistoryFieldAndValue();\n }\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n \n width: 328,\n \n backgroundColor: theme.colors.white\n },\n signatureBlock: {\n border: \"solid\",\n borderColor: theme.colors.grey2,\n borderRadius: 10,\n borderWidth: 1,\n },\n controlSignatureButtonsBlock: {\n alignSelf: \"flex-end\",\n \n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n \n width: 328,\n height: 32,\n\n marginTop: 12,\n },\n deleteSignatureButton: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n width: 160,\n height: 32,\n \n backgroundColor: theme.colors.white,\n \n border: \"solid\",\n borderWidth: 1,\n borderRadius: 5,\n borderColor: theme.colors.grey4,\n \n ...theme.typography.buttons,\n color: theme.colors.grey4,\n fontWeight: 700,\n \n \"&:disabled\": {\n opacity: 0.3,\n color: theme.colors.grey4,\n },\n \"&:hover\": {\n backgroundColor: theme.colors.white + \"!important\",\n color: theme.colors.grey4 + \"!important\",\n }\n },\n saveSignatureButton: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 160,\n height: 32,\n\n backgroundColor: theme.colors.white,\n\n border: \"solid\",\n borderWidth: 1,\n borderRadius: 5,\n borderColor: theme.colors.clearMain,\n\n ...theme.typography.buttons,\n color: theme.colors.clearMain,\n fontWeight: 700,\n\n \"&:disabled\": {\n opacity: 0.3,\n color: theme.colors.clearMain,\n },\n \"&:hover\": {\n backgroundColor: theme.colors.white + \"!important\",\n color: theme.colors.clearMain + \"!important\",\n }\n },\n hoverBackground: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 328,\n height: 118,\n\n backgroundColor: \"#1D2027\",\n },\n hoverContent: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n\n width: 120,\n height: 49,\n },\n hoverIcon: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 40,\n height: 40,\n },\n hoverText: {\n marginTop: 2,\n\n ...theme.typography.txtBody2,\n fontWeight: 700,\n color: theme.colors.grey1,\n }\n}));\n\nexport default useStyles;\n","import React, { useEffect, useRef, useState } from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport CanvasDraw from \"react-canvas-draw\";\n\nimport { Button } from \"@material-ui/core\";\n\nimport { PatientSignatureProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { PenIcon } from \"../../../../assets/icons\";\n\n\nexport default function PatientSignature(props: PatientSignatureProps) {\n \n const { signature, setSignature, onSave, enabled } = props;\n\n const [isDrawingEnabled, setIsDrawingEnabled] = useState<boolean>(false);\n const [showHoverImage, setShowHoverImage] = useState<boolean>(false);\n\n const { t } = useTranslation(\"general\");\n \n const classes = useStyles();\n \n const canvas = useRef<CanvasDraw | null>(null);\n const brushColor = \"#000000\";\n const brushRadius = 2;\n const lazyRadius = 3;\n \n useEffect(() => {\n if (signature) {\n canvas.current?.loadSaveData(signature)\n }\n }, [])\n \n function handleDeleteSignatureClick() {\n canvas.current?.clear();\n setSignature(null)\n }\n\n function handleSaveSignatureClick() {\n onSave();\n setIsDrawingEnabled(false)\n }\n \n function isDeleteSignatureButtonDisabled() {\n return signature === null;\n }\n\n function isSaveSignatureButtonDisabled() {\n return signature === null;\n }\n \n function handleCanvasOnChange(canvas: CanvasDraw) {\n setSignature(canvas.getSaveData())\n }\n\n function handleOnMouseEnter() {\n if (!enabled) return;\n if (isDrawingEnabled) return;\n\n setShowHoverImage(true)\n }\n\n function handleOnMouseLeave() {\n if (isDrawingEnabled) return;\n\n setShowHoverImage(false)\n }\n\n function handleHoverClick() {\n setIsDrawingEnabled(true)\n setShowHoverImage(false)\n }\n \n return (\n <div className={classes.root}>\n <div\n onMouseEnter={() => handleOnMouseEnter()}\n onMouseLeave={() => handleOnMouseLeave()}\n >\n {\n showHoverImage\n ?\n <div\n className={classes.hoverBackground}\n onClick={handleHoverClick}\n >\n <div className={classes.hoverContent}>\n <div className={classes.hoverIcon}>\n <PenIcon />\n </div>\n <div className={classes.hoverText}>\n {t(\"Draw signature\")}\n </div>\n </div>\n </div>\n :\n <CanvasDraw\n ref={canvasDraw => (canvas.current = canvasDraw)}\n className={classes.signatureBlock}\n canvasWidth={329}\n canvasHeight={118}\n brushRadius={brushRadius}\n brushColor={brushColor}\n lazyRadius={lazyRadius}\n disabled={!isDrawingEnabled}\n onChange={handleCanvasOnChange}\n saveData={signature ?? canvas.current?.getSaveData()}\n immediateLoading\n clampLinesToDocument\n hideInterface\n hideGrid\n />\n }\n </div>\n {\n isDrawingEnabled &&\n <div className={classes.controlSignatureButtonsBlock}>\n <Button\n className={classes.deleteSignatureButton}\n onClick={handleDeleteSignatureClick}\n disabled={isDeleteSignatureButtonDisabled()}\n >\n {t(\"Delete signature\")}\n </Button>\n <Button\n className={classes.saveSignatureButton}\n onClick={handleSaveSignatureClick}\n disabled={isSaveSignatureButtonDisabled()}\n >\n {t(\"Save signature\")}\n </Button>\n </div>\n }\n\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n \n minWidth: 320,\n width: 464,\n \n border: \"solid\",\n borderColor: theme.colors.clearYellow,\n borderWidth: 1,\n borderRadius: 10,\n \n boxShadow: theme.shadows[5],\n padding: 24,\n \n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"solid\",\n borderColor: theme.colors.clearYellow,\n borderWidth: 1,\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: theme.colors.grey4,\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n ...theme.typography.header4,\n fontWeight: 700,\n textAlign: \"center\",\n \n color: \"#26292B\",\n },\n modalContent: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n \n width: 50,\n height: 50,\n \n borderRadius: \"50%\",\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearYellow,\n },\n modalMain: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n \n gap: 3,\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n marginTop: 3,\n \n ...theme.typography.txtBody1,\n fontSize: 12,\n fontWeight: 300,\n \n textAlign: \"center\",\n \n color: \"#4A4D51\",\n },\n editAppointmentLink: {\n color: theme.colors.clearMain,\n textDecoration: \"underline\",\n textDecorationColor: theme.colors.clearMain,\n \n \"&:hover\": {\n color: theme.colors.clearMain,\n textDecoration: \"underline\",\n textDecorationColor: theme.colors.clearMain,\n }\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: \"#ACB7C0\",\n },\n editAppointment: {\n background: theme.colors.clearYellow,\n color: theme.colors.grey1,\n \"&:hover\": {\n background: theme.colors.clearYellow,\n },\n },\n separator: {\n \n width: 217,\n height: 0,\n \n borderTop: \"solid\",\n borderTopWidth: 1,\n borderTopColor: \"rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n \n },\n}));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Modal, Typography, Button } from '@material-ui/core';\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\n\nimport { CrossIcon, ExclamationIcon } from \"../../../../assets/icons\";\nimport { SaveSignatureModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function SaveSignatureModal(props: SaveSignatureModalProps) {\n \n const { open, onConfirm, onClose } = props;\n \n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n <div className={classes.modalContent}>\n <div\n className={classes.modalTitleSpace}\n >\n <Typography className={classes.modalTitleText}>\n {t(\"Confirm that you want to save your signature\")}\n </Typography>\n </div>\n <div className={classes.separator} />\n <div className={classes.modalMain}>\n <Typography className={classes.modalContentText}>\n {t(\"The signature cannot be modified after saving.\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.editAppointment}`}\n onClick={() => {\n if (onConfirm) {\n onConfirm();\n }\n }}\n >\n {t(\"Yes, save signature\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import React, { useState, useEffect } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { conformToMask } from \"react-text-mask\";\n\nimport useStyles from \"./css\";\nimport { PatientClinicalHistoryTabProps } from \"./props\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\nimport Cloner from \"../../../utils/cloner\";\n\nimport { GetMobileMaskByTemp } from \"../../../constants/mask\";\nimport { Color } from \"../../../constants/colors\";\nimport {\n ArrowDownIcon,\n RoundCheckmarkIcon,\n CheckboxCheckedIcon,\n CheckboxUncheckedIcon\n} from \"../../../assets/icons\";\n\nimport { Accordion, AccordionDetails, AccordionSummary, Typography } from \"@material-ui/core\";\nimport ClinicalHistoryRadioGroup from \"./ClinicalHistoryRadioGroup\";\nimport ClinicalHistoryTextInput from \"./ClinicalHistoryTextInput\";\n\nimport { CustomerService } from \"../../../api/customer-service\";\nimport { SectionFieldItemModel } from \"../../../models/section-field-item-model\";\nimport { SectionFieldType } from \"../../../models/enums/section-field-type\";\nimport { FormRadioValue } from \"../../../models/form-radio-value\";\nimport { SectionFieldValueModel } from \"../../../models/section-field-value-model\";\nimport { FormPhoneNumberValue } from \"../../../models/form-phone-number-value\";\nimport { FormFieldItemValue } from \"../../../models/form-field-item-value\";\nimport { SectionFieldModel } from \"../../../models/section-field-model\";\nimport { PatientClinicalHistoryTabDataResponse } from \"../../../models/patient-clinical-history-tab-data-response\";\nimport { ClinicalHistoryFieldAndValue } from \"../../../models/clinical-history-field-and-value\";\nimport { UpdatePatientObservationsRequest } from \"../../../models/update-patient-observations-request\";\nimport { UpdatePatientClinicalHistoryFieldValueRequest } from \"../../../models/update-patient-clinical-history-field-value-request\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\nimport PatientSignature from \"./PatientSignature\";\nimport { Link } from \"react-router-dom\";\nimport { Url } from \"../../../constants/url\";\nimport SaveSignatureModal from \"./SaveSignatureModal\";\n\n\nexport default function PatientClinicalHistoryTab(props: PatientClinicalHistoryTabProps) {\n const { customerId } = props;\n const stringify = require('safe-stable-stringify');\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const accountSettings = useAppSelector(selectAccountSettings);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const [tabDataModel, setTabDataModel] = useState<PatientClinicalHistoryTabDataResponse>(new PatientClinicalHistoryTabDataResponse());\n const [tabDataModelInitialState, setTabDataModelInitialState] = useState<PatientClinicalHistoryTabDataResponse>(new PatientClinicalHistoryTabDataResponse());\n const [saveSignatureModalOpen, setSaveSignatureModalOpen] = useState<boolean>(false);\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n\n fetchData();\n }, []);\n\n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const response = await CustomerService.getPatientClinicalHistoryTabData(customerId);\n dispatch(navbarActions.setShowLoader(false));\n const responseClone = Cloner.deepCopy<PatientClinicalHistoryTabDataResponse>(response);\n setTabDataModel(response);\n setTabDataModelInitialState(responseClone);\n };\n\n const updateFieldValue = async (fieldId: string) => {\n const fieldsAndValues = [...tabDataModel.clinicalHistorySections\n .find(s => s.fieldsAndValues\n .some(fv => fv.field.id === fieldId))!\n .fieldsAndValues];\n const fieldAndValue = fieldsAndValues.find(f => f.field.id === fieldId);\n\n if (!validateFieldValue(fieldAndValue!))\n return;\n\n const initialFieldsAndValues = [...tabDataModelInitialState.clinicalHistorySections\n .find(s => s.fieldsAndValues\n .some(fv => fv.field.id === fieldId))!\n .fieldsAndValues];\n const initialValue = initialFieldsAndValues.find(f => f.field.id === fieldId)?.value;\n\n //Prevent API call if data remains the same\n if (stringify(initialValue) === stringify(fieldAndValue?.value)) {\n return;\n }\n\n const isUpdated = await CustomerService.updatePatientClinicalHistoryFieldValue(new UpdatePatientClinicalHistoryFieldValueRequest({customerId: customerId, fieldAndValue: fieldAndValue}))\n\n if (isUpdated) {\n const newDataClone = Cloner.deepCopy<PatientClinicalHistoryTabDataResponse>(tabDataModel);\n setTabDataModelInitialState(newDataClone);\n }\n };\n\n function updateSignature(value: string | null) {\n setTabDataModel({ ...tabDataModel, signature: value });\n }\n\n async function saveSignature() {\n const response = await CustomerService.updatePatientSignature({\n customerId: customerId,\n signature: tabDataModel.signature!\n });\n\n if (response.isUpdated) {\n setTabDataModel({...tabDataModel,\n isFormSignedAtEstablishment: true,\n ip: response.ip,\n formSignedAt: response.date\n })\n const newDataClone = Cloner.deepCopy<PatientClinicalHistoryTabDataResponse>(tabDataModel);\n setTabDataModelInitialState(newDataClone);\n }\n else\n {\n setTabDataModel({...tabDataModel, signature: tabDataModelInitialState.signature })\n }\n setSaveSignatureModalOpen(false);\n }\n\n const updateObservations = async () => {\n if (tabDataModel.observations?.trim() === tabDataModelInitialState.observations?.trim() ||\n !tabDataModelInitialState.observations && tabDataModel.observations?.trim() === \"\") {\n return;\n }\n \n const isUpdated = await CustomerService.updatePatientObservations(\n new UpdatePatientObservationsRequest({\n customerId: customerId,\n observations: tabDataModel.observations?.trim()\n }));\n\n if (isUpdated) {\n setTabDataModelInitialState({ \n ...tabDataModelInitialState, \n observations: tabDataModel.observations?.trim().slice() })\n }\n };\n\n const handleRadioTextAreaOnBlur = async (fieldId: string, radioValue: FormRadioValue | null, textAreaValue: string | undefined, initialTextAreaValue: string | null) => {\n if (!radioValue)\n return;\n if (initialTextAreaValue?.trim() === textAreaValue?.trim())\n return;\n await updateFieldValue(fieldId);\n };\n\n const setFieldValue = (fieldId: string, value: string | FormPhoneNumberValue | FormRadioValue | null, additionalTextValue: string | null = null) => {\n if (!tabDataModel.clinicalHistorySections)\n return;\n\n const fieldsAndValues = [...tabDataModel.clinicalHistorySections\n .find(s => s.fieldsAndValues\n .some(fv => fv.field.id === fieldId))!\n .fieldsAndValues];\n const fieldAndValue = fieldsAndValues.find(f => f.field.id === fieldId);\n\n if (!fieldAndValue)\n return;\n\n //make value null if field is empty (need for compairing with old patient version and for proper storing)\n if (typeof value === \"string\" && value === \"\") {\n fieldAndValue.value = null;\n const clone = Cloner.deepCopy<PatientClinicalHistoryTabDataResponse>(tabDataModel);\n clone.clinicalHistorySections.find(s => s.fieldsAndValues.some(fv => fv.field.id === fieldId))!.fieldsAndValues = fieldsAndValues;\n setTabDataModel(clone);\n return;\n }\n\n if (!additionalTextValue) {\n if (!fieldAndValue.value) {\n fieldAndValue.value = new SectionFieldValueModel({ type: fieldAndValue.field.type, value: value })\n }\n else {\n fieldAndValue.value.type = fieldAndValue.field.type;\n fieldAndValue.value.value = value!;\n }\n }\n //if field is Radio and contain additional text value\n else if (additionalTextValue && fieldAndValue.field.type === SectionFieldType.Radio) {\n let newValue: FormRadioValue;\n //if this field value has already selected field item - just setting the argument value\n if (value && (value as FormRadioValue).item) {\n newValue = value as FormRadioValue;\n }\n //if not - we're selecting first item automatically\n else {\n const firstSelectItem = fieldAndValue.field.items.sort((i1, i2) => i1.order - i2.order)[0];\n const autoSelectedFirstItemValue = new FormFieldItemValue({ fieldItemId: firstSelectItem.id, value: firstSelectItem.name })\n newValue = new FormRadioValue();\n newValue.item = autoSelectedFirstItemValue;\n newValue.additionalFreeTextValue = additionalTextValue;\n }\n if (!fieldAndValue.value) {\n fieldAndValue.value = new SectionFieldValueModel({ type: fieldAndValue.field.type, value: newValue })\n }\n else {\n fieldAndValue.value.value = newValue!;\n }\n };\n\n const clone = Cloner.deepCopy<PatientClinicalHistoryTabDataResponse>(tabDataModel);\n clone.clinicalHistorySections.find(s => s.fieldsAndValues.some(fv => fv.field.id === fieldId))!.fieldsAndValues = fieldsAndValues;\n setTabDataModel(clone);\n };\n\n const validateFieldValue = (fv: ClinicalHistoryFieldAndValue): boolean => {\n if (fv.field.isRequired) {\n if (!fv.value?.value || fv.value?.value === \"\") {\n if (!fv.field.isDeleted) {\n return false;\n }\n else {\n return true;\n }\n }\n switch (fv.field.type) {\n case SectionFieldType.Text:\n if (!fv.value?.value || fv.value.value === \"\") {\n return false;\n }\n break;\n case SectionFieldType.Radio:\n if (!fv.field.isDeleted && (fv.value?.value as FormRadioValue).item === null) {\n return false;\n }\n break;\n }\n }\n\n return true;\n };\n\n const validateTextField = (field: SectionFieldModel, value: string): boolean => {\n const isValid = !(field.isRequired && value === \"\");\n return isValid;\n };\n\n const mapSectionsToComponents = () => {\n return tabDataModel.clinicalHistorySections\n .sort((s1, s2) => s1.section.order! - s2.section.order!)\n .map(s => {\n if (!s.fieldsAndValues ||\n s.fieldsAndValues.length === 0 ||\n s.fieldsAndValues.every(f => f.field.isDeleted && f.value === null) ||\n (s.section.isDeleted && (s.fieldsAndValues.length === 0 || s.fieldsAndValues.every(f => f.value === null))))\n return <></>\n return <>\n <div className={classes.sectionContainer}>\n <Accordion defaultExpanded={true}>\n <AccordionSummary\n expandIcon={<ArrowDownIcon style={{ height: 15, width: 15, color: Color.clear1 }}\n />}>\n <Typography className={classes.sectionLabel}>\n {t(s.section.name!, { ns: sectionTNamespace })}\n </Typography>\n </AccordionSummary>\n <AccordionDetails>\n <div className={classes.fieldsEditionContainer}>\n {s.fieldsAndValues\n .sort((f1, f2) => f1.field.order - f2.field.order)\n .map(f => {\n if (f.field.isDeleted && f.value === null)\n return;\n else {\n const fieldAndValue = tabDataModel.clinicalHistorySections\n .flatMap(s => s.fieldsAndValues)\n .find(fv => fv.field.id === f.field.id);\n return <div className={classes.fieldEditionContainer}>\n {getInput(fieldAndValue!)}\n </div>\n }\n })}\n </div>\n </AccordionDetails>\n </Accordion>\n </div>\n </>\n });\n };\n\n const getInput = (fieldAndValueModel: ClinicalHistoryFieldAndValue) => {\n const sectionField = fieldAndValueModel.field;\n const valueField = fieldAndValueModel.value;\n if (!valueField?.value) {\n //return empty input for sectionField type\n switch (sectionField.type) {\n case SectionFieldType.Text:\n return getTextInput(sectionField);\n case SectionFieldType.Radio:\n return getRadioInput(sectionField);\n default:\n return;\n }\n }\n\n if (sectionField.type !== valueField.type) {\n switch (sectionField.type) {\n case SectionFieldType.Text:\n switch (valueField.type) {\n case SectionFieldType.Radio:\n //return TextInput with valueField.value.item.value\n const radioItemObj = valueField.value as FormRadioValue;\n return getTextInput(sectionField, radioItemObj.item.value);\n }\n case SectionFieldType.Radio:\n //return empty input for Radio type\n return getRadioInput(sectionField);\n }\n }\n\n //dealing with filled RadioInput\n if (sectionField.type === SectionFieldType.Radio && valueField.type === SectionFieldType.Radio) {\n if (sectionField.items\n .filter(i => !i.isDeleted)\n .map(i => i.id)\n .some(i => i === (valueField.value as FormRadioValue).item.fieldItemId)) {\n //return RadioInput with valueField.value.item checked\n return getRadioInput(sectionField, valueField.value as FormRadioValue);\n }\n else {\n //return RadioInput with FAKE valueField.value.item checked\n return getRadioInput(sectionField, valueField.value as FormRadioValue, true);\n }\n }\n\n //dealing with other filled field types\n switch (sectionField.type) {\n case SectionFieldType.Text:\n //return filled TextInput\n return getTextInput(sectionField, valueField.value as string);\n }\n };\n\n const getTextInput = (field: SectionFieldModel, value: string | null = null) => {\n return <>\n <ClinicalHistoryTextInput\n key={field.id!}\n value={value ? t(value, { ns: sectionTNamespace }) : \"\"}\n setValue={(v) => setFieldValue(field.id!, v)}\n onBlur={async () => { await updateFieldValue(field.id!) }}\n label={t(field.name, { ns: sectionTNamespace })}\n isValid={(v) => validateTextField(field, v)}\n required={field.isRequired}\n placeholder={t(field.name, { ns: sectionTNamespace })}\n maxLength={1500} />\n </>\n };\n\n const getRadioInput = (field: SectionFieldModel, value: FormRadioValue | null = null, isFakeRadioItem: boolean = false) => {\n const getSelectedItem = () => {\n if (!value && !isFakeRadioItem) {\n return null;\n };\n if (value && !isFakeRadioItem)\n //return genuine selected item\n return field.items.filter(i => i.id === value.item.fieldItemId)[0];\n if (value && isFakeRadioItem)\n //return \"fake\"/old selected item\n return new SectionFieldItemModel({ id: value.item.fieldItemId, name: value.item.value, order: 0 });\n\n return null;\n };\n\n const setRadioValue = async (fieldId: string, i: SectionFieldItemModel) => {\n const radioValue = new FormFieldItemValue();\n radioValue.fieldItemId = i.id!;\n radioValue.value = i.name;\n\n const itemModel = new FormRadioValue();\n itemModel.item = radioValue;\n itemModel.additionalFreeTextValue = value ? value.additionalFreeTextValue : \"\"\n setFieldValue(fieldId, itemModel);\n await updateFieldValue(fieldId);\n };\n\n return <>\n <ClinicalHistoryRadioGroup\n key={field.id!}\n field={field}\n value={value}\n selectedItem={getSelectedItem()}\n setSectionFieldItem={async (i) => await setRadioValue(field.id!, i)}\n onTextAreaBlur={async (freeTextValue, initialTextAreaValue) => { await handleRadioTextAreaOnBlur(field.id!, value, freeTextValue, initialTextAreaValue) }}\n setFreeTextValue={\n field.isAdditionalTextareaEnabled\n ? (av) => { setFieldValue(field.id!, new FormRadioValue({ item: value?.item, additionalFreeTextValue: av }), av) }\n : undefined}\n />\n </>\n };\n\n const getSignatureDateTime = () => {\n var newDateObj = new Date(tabDataModel.formSignedAt!);\n const time = newDateObj.toLocaleTimeString(\"es\", { timeStyle: \"short\" })\n const day = newDateObj.toLocaleString(localeApp, { day: \"numeric\" });\n let month = newDateObj.toLocaleString(localeApp, { month: \"long\", });\n const year = newDateObj.toLocaleString(localeApp, { year: \"numeric\", });\n\n let result = localeApp === \"es\"\n ? `${day} de ${month}, ${year} ${time}hrs`\n : `${month.charAt(0).toUpperCase() + month.slice(1)} ${day}, ${year} ${time}hrs`;\n\n return result;\n };\n\n const getSignaturePhoneNumber = () => {\n if (tabDataModel.isFormSignedAtEstablishment) {\n return t(\"Signed at the establishment\");\n }\n const template = accountSettings.countries?.find(c => c.iso3 === tabDataModel.phoneNumberIso3Code)!.dialTemplate;\n return conformToMask(tabDataModel.phoneNumberBody, GetMobileMaskByTemp(template)).conformedValue;\n };\n\n function checkBoxDisplayText(textKey: string, linkKey: string, linkTo: string) {\n return (\n <span\n className={classes.checkBoxText}\n >\n {t(textKey)} <Link className={classes.link} to={linkTo} target=\"_blank\">{t(linkKey)}</Link>\n </span>\n );\n }\n\n return <>\n <div className={classes.root}>\n <div className={classes.sectionsListContainer}>\n {mapSectionsToComponents()}\n <div className={classes.sectionContainer}>\n <Accordion defaultExpanded={true}>\n <AccordionSummary\n expandIcon={<ArrowDownIcon style={{ height: 15, width: 15, color: Color.clear1 }}\n />}>\n <Typography className={classes.sectionLabel}>\n {t(\"Patient's signature\")}\n </Typography>\n </AccordionSummary>\n <AccordionDetails className={classes.signatureContainer}>\n {tabDataModel.canAcceptPrivacyNotice &&\n <div className={classes.signatureBlock}>\n <div className={classes.signatureBlockTitle}>{t(\"Privacy notice\")} <span className={classes.asterisk}>*</span></div>\n <div className={classes.signatureBlockCheckbox}>\n {tabDataModel.hasAcceptedPrivacyNotice\n ? <CheckboxCheckedIcon />\n : <CheckboxUncheckedIcon />\n }\n\n <div style={{width: 250}}>{checkBoxDisplayText(\"PrivacyNoticeAcceptance\", \"privacy notice\", `${Url.PrivacyNotice}`)}</div>\n </div>\n </div>\n }\n {tabDataModel.canReadConsentLetter &&\n <div className={classes.signatureBlock}>\n <div className={classes.signatureBlockTitle}>{t(\"Informed consent letter\")} <span className={classes.asterisk}>*</span></div>\n <div className={classes.signatureBlockCheckbox}>\n {tabDataModel.hasReadConsentLetter\n ? <CheckboxCheckedIcon />\n : <CheckboxUncheckedIcon />\n }\n\n <div style={{width: 250}}>{checkBoxDisplayText(\"ConsentLetterAcceptance\", \"informed consent letter\", `${Url.InformedConsentLetter}`)}</div>\n </div>\n </div>\n }\n <div className={classes.signatureSectionTitle}>{t(\"Patient's signature\")}</div>\n <div className={classes.signatureSectionContainer}>\n <div>\n <PatientSignature\n signature={tabDataModel.signature}\n setSignature={updateSignature}\n onSave={() => setSaveSignatureModalOpen(true)}\n enabled={!tabDataModel.isFormSignedAtEstablishment && tabDataModel.hasReadConsentLetter && tabDataModel.hasAcceptedPrivacyNotice}\n />\n </div>\n <div className={classes.metaInfoContainer}>\n <div className={classes.metaInfoFieldContainer}>\n <Typography className={classes.metaInfoFieldTitle}>\n {t(\"Signed IP address\")}\n </Typography>\n <Typography className={classes.metaInfoFieldValue}>\n {!tabDataModel?.signature || tabDataModel.signature === \"\"\n ? \"--\"\n : <>\n {tabDataModel.ip}\n <RoundCheckmarkIcon style={{ margin: \"0px 0px 3px 5px\" }} />\n </>}\n </Typography>\n </div>\n <div className={classes.metaInfoFieldContainer}>\n <Typography className={classes.metaInfoFieldTitle}>\n {t(\"Signature date\")}\n </Typography>\n <Typography className={classes.metaInfoFieldValue}>\n {!tabDataModel?.signature || tabDataModel.signature === \"\"\n ? \"--\"\n : <>\n {getSignatureDateTime()}\n <RoundCheckmarkIcon style={{ margin: \"0px 0px 3px 5px\" }} />\n </>}\n </Typography>\n </div>\n <div className={classes.metaInfoFieldContainer}>\n <Typography className={classes.metaInfoFieldTitle}>\n {t(\"Mobile\")}\n </Typography>\n <Typography className={classes.metaInfoFieldValue}>\n {!tabDataModel?.signature || tabDataModel.signature === \"\"\n ? \"--\"\n : <>\n {getSignaturePhoneNumber()}\n <RoundCheckmarkIcon style={{ margin: \"0px 0px 3px 5px\" }} />\n </>}\n </Typography>\n </div>\n </div>\n </div>\n </AccordionDetails>\n </Accordion>\n </div>\n <div className={classes.sectionContainer}>\n <Accordion defaultExpanded={true}>\n <AccordionSummary\n expandIcon={<ArrowDownIcon style={{ height: 15, width: 15, color: Color.clear1 }}\n />}>\n <Typography className={classes.sectionLabel}>\n {t(\"Observations\")}\n </Typography>\n </AccordionSummary>\n <AccordionDetails>\n <div className={classes.fieldsEditionContainer} style={{marginTop: \"-14px\"}}>\n <ClinicalHistoryTextInput\n key={\"observations\"}\n value={tabDataModel?.observations ?? \"\"}\n setValue={(v) => setTabDataModel({ ...tabDataModel, observations: v })}\n onBlur={async () => { await updateObservations() }}\n label={t(\"Patient's general observations\") + \":\"}\n isValid={(_) => true}\n required={false}\n placeholder={t(\"Patient's general observations\")}\n maxLength={1500} />\n </div>\n </AccordionDetails>\n </Accordion>\n </div>\n </div>\n <SaveSignatureModal\n open={saveSignatureModalOpen}\n onConfirm={saveSignature}\n onClose={() => setSaveSignatureModalOpen(false)}\n />\n </div>\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n \"& .MuiAccordion-root:before\": {\n backgroundColor: \"unset\"\n },\n \"& .MuiAccordionSummary-root\": {\n padding: \"10px 19px 10px 15px\",\n background: \"#FAFAFA\",\n minHeight: \"unset\",\n height: 46,\n },\n \"& .MuiAccordionSummary-root.Mui-expanded\": {\n minHeight: 0,\n margin: \"unset\"\n },\n \"& .MuiAccordionSummary-content\": {\n margin: 0,\n },\n \"& .MuiAccordion-root.Mui-expanded\": {\n margin: \"unset\"\n }\n },\n customerHistoryPanelContent: {\n overflowY: \"scroll\",\n maxHeight: \"calc(100vh - 152px)\",\n borderRadius: \"0px 0px 12px 12px\",\n \"&::-webkit-scrollbar\": {\n display: \"none\",\n },\n scrollbarWidth: \"none\",\n \"-ms-overflow-style\": \"none\",\n },\n customerDetails: {\n width: 779,\n height: 610,\n margin: \"0px 0px 0px 36px\",\n },\n recurringAppointment: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderTop: \"1px solid #C9CDD361\",\n paddingTop: 7,\n marginBottom: 10,\n marginTop: 10,\n width: \"90%\",\n marginLeft: \"auto\",\n marginRight: \"auto\"\n },\n customerDetailsContent: {\n width: 779,\n height: 610,\n borderRadius: \"0px 0px 12px 12px\",\n border: \"1px solid #DBDCDD\",\n backgroundColor: \"#FFF\",\n boxShadow: \"none\",\n },\n customerHistoryTitle: {\n display: \"flex\",\n alignItems: \"center\",\n },\n infoContentRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n contactRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n },\n iconTitle: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n margin: \"0px 0px 0px 10px\",\n },\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n required: {\n color: \"#6462F3\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n display: \"flex\",\n margin: 0,\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n description: {\n margin: 0,\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n monthYear: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n lineHight: 17,\n color: Color.clear1\n },\n appointmentCountInMonth: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n lineHight: 17,\n color: Color.clear1\n },\n accordion: {\n border: \"none\",\n boxShadow: \"none\"\n },\n accordionSummary: {\n padding: 0\n },\n accordionDetails: {\n padding: 0\n },\n appointmentsBox: {\n background: \"#FFFFFF\",\n width: \"100%\",\n padding: \"15px 15px 0px 15px\"\n },\n appointmentsGrid: {\n width: \"100%\",\n },\n appointmentsGridLine: {\n borderBottom: \"1px solid #C9CDD3\",\n marginTop: 10,\n alignContent: \"center\",\n opacity: 0.5\n },\n headerAppointments: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n lineHight: 14,\n display: \"flex\",\n alignItems: \"center\",\n color: Color.gray4\n },\n serviceName: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n lineHeight: \"14px\",\n display: \"flex\",\n alignItems: \"center\",\n color: Color.gray5\n },\n serviceDate: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n lineHeight: \"14px\",\n display: \"flex\",\n alignItems: \"center\",\n color: Color.gray5\n },\n servicePrice: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n lineHeight: \"14px\",\n display: \"flex\",\n alignItems: \"center\",\n color: Color.gray5\n },\n serviceStatus: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n display: \"flex\",\n alignItems: \"center\",\n color: \"#5C6477\",\n },\n ArrowIcon: {\n color: \"#6462F3\",\n fontSize: 24,\n width: 18,\n // marginLeft: 10,\n height: 15\n },\n divStatus: {\n borderRadius: 5,\n color: \"#FFFFFF\",\n padding: \"5px 10px\",\n width: \"fit-content\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n lineHeight: \"14px\",\n marginBottom: 10,\n marginRight: 5,\n display: \"inline-block\",\n maxHeight: 22\n },\n statusConfirmed: {\n color: \"#0BCBE0\",\n backgroundColor: \"rgba(11, 203, 224, 0.2)\"\n },\n statusArrived: {\n color: \"#36CE91\",\n backgroundColor: \"rgba(54, 206, 145, 0.2)\"\n },\n statusNotConfirmed: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\",\n },\n statusNotArrived: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\",\n },\n statusCanceled: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\"\n },\n apptDisabledGrid: {\n \"& * p\": {\n opacity: 0.5\n }\n },\n divNotes: {\n borderRadius: 5,\n color: \"#FFFFFF\",\n padding: \"5px 8px 5px 10px\",\n width: 28,\n height: 20,\n cursor: \"pointer\"\n },\n divNotesNone: {\n color: \"#36CE91\",\n backgroundColor: \"rgba(145, 156, 165, 0.2)\"\n },\n divNotesExists: {\n color: \"#36CE91\",\n backgroundColor: \"rgba(100, 98, 243, 0.2)\"\n },\n drawerHistoryDetails: {\n color: \"#000\",\n background: \"#fff\",\n borderTopLeftRadius: 20,\n borderBottomLeftRadius: 20,\n width: \"250px\",\n },\n statusPaid: {\n color: \"#36CE91\",\n backgroundColor: \"rgba(54, 206, 145, 0.2)\"\n },\n statusUnpaid: {\n color: \"#F15857\",\n backgroundColor: \"rgba(241, 88, 87, 0.2)\",\n },\n specialistName: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12,\n lineHeight: \"14px\",\n display: \"flex\",\n alignItems: \"center\",\n color: Color.gray5\n }\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState, useRef } from \"react\";\nimport { useParams } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Paper from \"@material-ui/core/Paper\";\n\nimport Tabs from \"./../../common/tabs/Tabs\";\nimport TabPanel from \"./../../common/tabs/TabPanel\";\nimport { TabsModel } from \"../../common/tabs/tabs-model\";\n\nimport CustomerDataInfo from \"./../CustomerDataInfo\";\nimport { CustomerInfoDetails } from \"../../../models/customer-info-details\";\nimport CustomerHistory from \"./../CustomerHistory\";\n\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../redux/store\";\n\nimport useStyles from \"./css\";\nimport PatientEvolutionNotes from \"../PatientEvolutionNotes\";\nimport PatientData from \"../PatientData\";\nimport CustomerInformationTab from \"../CustomerInformationTab\";\nimport PatientGeneralInformationTab from \"../PatientGeneralInformationTab\";\nimport CustomerClinicalFiles from \"../CustomerClinicalFiles\";\nimport PatientClinicalHistoryTab from \"../PatientClinicalHistoryTab\";\nimport CustomerDetailsRefs from \"./customer-details-refs\";\nimport PatientAppointmentHistoryTab from \"../PatientAppointmentHistoryTab\";\n\nenum CustomerDetailsTab {\n General,\n ClinicalHistory,\n EvolutionNotes,\n AppointmentHistory,\n Files\n}\n\n\nconst CustomerDetails = () => {\n const { t } = useTranslation([\"general\"]);\n const { customerId } = useParams<any>();\n const classes = useStyles();\n const [currentTab, setCurrentTab] = useState<number>(0);\n const [tabs, setTabs] = useState<CustomerDetailsTab[]>([])\n const [appointmentId, setAppointmentId] = useState<string | undefined>();\n const [serviceId, setServiceId] = useState<string | undefined>();\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const userInfo = useAppSelector(selectUserInfo);\n\n const canSeeClinicalFile = userInfo.canSeeClinicalFile;\n const canInteractWithEvolutionNotes = userInfo.canInteractWithEvolutionNotes;\n const canInteractWithPatientFiles = userInfo.canInteractWithPatientFiles;\n const customerDetailsListRef = useRef<CustomerDetailsRefs>(null);\n\n useEffect(() => {\n const tabs: CustomerDetailsTab[] = [];\n tabs.push(CustomerDetailsTab.General);\n if (accountSettings.isClinicMode && canSeeClinicalFile)\n tabs.push(CustomerDetailsTab.ClinicalHistory);\n if (accountSettings.isClinicMode && canInteractWithEvolutionNotes)\n tabs.push(CustomerDetailsTab.EvolutionNotes);\n tabs.push(CustomerDetailsTab.AppointmentHistory);\n if ((canInteractWithPatientFiles && accountSettings.isClinicMode) || !accountSettings.isClinicMode)\n tabs.push(CustomerDetailsTab.Files);\n setTabs(tabs);\n }, [accountSettings]);\n\n const [customer, _setCustomer] = useState<CustomerInfoDetails>(\n new CustomerInfoDetails()\n );\n \n const handleUpdateEvolutionNotes = async () => {\n await customerDetailsListRef?.current?.updateVitalSigns();\n }\n\n const getTabModels = (): TabsModel[] => {\n const tabsModels: TabsModel[] = [];\n for (let i = 0; i < tabs.length; i++) {\n switch (tabs[i]) {\n case CustomerDetailsTab.General:\n tabsModels.push({\n index: i, label: accountSettings.isClinicMode\n ? t(\"General information\")\n : t(\"Customer info\")\n });\n break;\n case CustomerDetailsTab.ClinicalHistory:\n tabsModels.push({ index: i, label: t(\"Clinical history\") });\n break;\n case CustomerDetailsTab.EvolutionNotes:\n tabsModels.push({ index: i, label: t(\"Evolution notes\") });\n break;\n case CustomerDetailsTab.AppointmentHistory:\n tabsModels.push({ index: i, label: t(\"Appointments history\") });\n break;\n case CustomerDetailsTab.Files:\n tabsModels.push({ index: i, label: t(\"Files\") });\n break;\n }\n }\n return tabsModels;\n };\n\n const tryGetTabIndex = (tabType: CustomerDetailsTab) => {\n const tabIndex = tabs.findIndex(tt => tt === tabType);\n if (tabIndex === -1)\n return null;\n return tabIndex;\n };\n\n const onChangeTab = (index: number) => {\n setAppointmentId(undefined);\n setServiceId(undefined);\n setCurrentTab(index);\n };\n\n\n return (\n <div className={classes.root}>\n {accountSettings.isClinicMode\n ? <PatientData customerId={customerId} ref={customerDetailsListRef}/>\n : <CustomerDataInfo\n customerId={customerId}\n name={`${customer.firstName} ${customer.lastName}`}\n birthDate={customer.birthDate || null}\n />\n }\n <div className={classes.customerDetails}>\n <Paper className={classes.customerDetailsContent}>\n <Tabs value={currentTab} tabs={getTabModels()} onChange={onChangeTab} />\n <TabPanel value={currentTab} index={tryGetTabIndex(CustomerDetailsTab.General)}>\n {accountSettings.isClinicMode\n ?\n <PatientGeneralInformationTab\n customerId={customerId}\n setCustomer={_setCustomer}\n />\n :\n <CustomerInformationTab\n customerId={customerId}\n customer={customer}\n currentTabIndex={currentTab}\n setCustomer={_setCustomer}\n />\n }\n </TabPanel>\n {tryGetTabIndex(CustomerDetailsTab.ClinicalHistory) && <>\n <TabPanel value={currentTab} index={tryGetTabIndex(CustomerDetailsTab.ClinicalHistory)}>\n <PatientClinicalHistoryTab customerId={customerId} />\n </TabPanel></>}\n {tryGetTabIndex(CustomerDetailsTab.EvolutionNotes) && <>\n <TabPanel value={currentTab} index={tryGetTabIndex(CustomerDetailsTab.EvolutionNotes)}>\n <PatientEvolutionNotes\n customerName={`${customer.firstName} ${customer.lastName}`}\n customerMobile={customer.mobile}\n appointmentId={appointmentId}\n serviceId={serviceId}\n onUpdate={handleUpdateEvolutionNotes}\n />\n </TabPanel></>}\n {tryGetTabIndex(CustomerDetailsTab.AppointmentHistory) && <>\n <TabPanel value={currentTab} index={tryGetTabIndex(CustomerDetailsTab.AppointmentHistory)}>\n {accountSettings.isClinicMode\n ? <PatientAppointmentHistoryTab\n customerId={customerId}\n gotoEvolutionNotesTab={(appointmentId, serviceId) => {\n setAppointmentId(appointmentId);\n setServiceId(serviceId);\n setCurrentTab(CustomerDetailsTab.EvolutionNotes);\n }} />\n : <CustomerHistory\n customer={customer} />}\n </TabPanel></>}\n {tryGetTabIndex(CustomerDetailsTab.Files) && <>\n <TabPanel value={currentTab} index={tryGetTabIndex(CustomerDetailsTab.Files)}>\n <CustomerClinicalFiles />\n </TabPanel></>}\n </Paper>\n </div>\n </div>\n );\n};\n\nexport default CustomerDetails;","import React, { useEffect, useState } from \"react\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings, selectCommonHubConnection } from \"../../../redux/store\";\nimport useCurrencyValueTemplate from \"../../../hooks/useCurrencyValueTemplate\";\nimport { useTranslation } from \"react-i18next\";\nimport useCustomerTerminology from \"../../../hooks/useCustomerTerminology\";\n\nimport { PatientAppointmentHistoryTabProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport { CustomerService } from \"../../../api/customer-service\";\nimport CustomerHistoryEntity, { CustomerApptsServicesHistory } from \"../../../models/customer-history\";\nimport { AppointmentStatus } from \"../../../models/enums/appointment-status\";\nimport { AppointmentPaymentStatus } from \"../../../models/enums/appointment-payment-status\";\n\nimport { Accordion, AccordionDetails, AccordionSummary, Drawer, Grid, Typography } from '@material-ui/core';\nimport CustomerHistoryDetails from \"../CustomerHistoryDetails\";\nimport { ArrowDownIcon, CheckIcon, CrossIcon, MenuIconLogoClear, NoteIcon, PersonIcon } from \"../../../assets/icons\";\nimport { Color } from \"../../../constants/colors\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\n\n\nexport default function PatientAppointmentHistoryTab(props: PatientAppointmentHistoryTabProps) {\n\n const { customerId, gotoEvolutionNotesTab } = props;\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const [appointmentsEntity, setAppointmentsEntity] = useState<CustomerHistoryEntity[]>([]);\n const [drawerOpen, setDrawerOpen] = useState(false);\n const [service, setService] = useState<CustomerApptsServicesHistory>();\n const [serviceStatus, setServiceStatus] = useState<any>();\n const [servicePaymentStatus, setServicePaymentStatus] = useState<any>();\n const [appointmentId, setAppointmentId] = useState<any>();\n const [notesSaved, setNotesSaved] = useState<boolean>(true);\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const hubConnection = useAppSelector(selectCommonHubConnection);\n const getTemplatedCurrencyValue = useCurrencyValueTemplate(accountSettings.currencyTemplate);\n\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const customerDidNotArriveTerminology = useCustomerTerminology(t(\"Customer did not arrive\"), \"Customer\");\n const customerArrivedTerminology = useCustomerTerminology(t(\"Customer arrived\"), \"Customer\");\n\n useEffect(() => {\n\n getData();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n const getData = () => {\n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n const values = await CustomerService.getCustomerHistory(customerId, localeApp);\n dispatch(navbarActions.setShowLoader(false));\n if (values) {\n setAppointmentsEntity(values.entity!);\n }\n })();\n };\n \n // unsubscribe\n hubConnection?.off(\"changeAppointmentsListPaymentStatus\");\n // subscribe\n hubConnection?.on(\"changeAppointmentsListPaymentStatus\", (appointmentIds, status) => {updateAppointmentsPaymentStatus(appointmentIds, status)});\n const toggleDrawer = (s: CustomerApptsServicesHistory, apptId: string, divStatus: any, divPaymentStatus: any) => {\n if (s.notes && s.notes.trim() !== \"\") {\n setDrawerOpen(!drawerOpen);\n if (s)\n setService(s);\n if (divStatus)\n setServiceStatus(divStatus);\n if (divPaymentStatus)\n setServicePaymentStatus(divPaymentStatus)\n if (apptId)\n setAppointmentId(apptId);\n }\n else {\n gotoEvolutionNotesTab(apptId, s.id);\n }\n };\n \n function updateAppointmentsPaymentStatus(appointmentIds: string[], paymentStatus: AppointmentPaymentStatus) {\n setAppointmentsEntity(prevAppointmentsEntity => {\n return prevAppointmentsEntity.map(monthData => {\n const updatedAppointments = monthData.appointments.map(appointment => {\n if (appointmentIds.includes(appointment.id)) {\n return { ...appointment, paymentStatus: paymentStatus, };\n }\n return appointment;\n });\n return { ...monthData, appointments: updatedAppointments, };\n });\n });\n }\n\n const refreshClose = (s: CustomerApptsServicesHistory) => {\n getData();\n if (s)\n setService(s);\n };\n\n const changedNotesWithoutSave = (saved: boolean) => {\n setNotesSaved(saved);\n };\n\n const getServiceDate = (serviceDateTime: Date) => {\n const newDateObj = new Date(serviceDateTime);\n const day = newDateObj.toLocaleString(localeApp, { day: \"numeric\", });\n const month = newDateObj.toLocaleString(localeApp, { month: \"long\", });\n const year = newDateObj.toLocaleString(localeApp, { year: \"numeric\", });\n\n return localeApp === \"es\"\n ? `${day} de ${month[0].toUpperCase() + month.slice(1)} ${year}`\n : `${month.charAt(0).toUpperCase() + month.slice(1)} ${day} ${year}`;\n };\n\n const getServiceTime = (serviceStartTime: Date, serviceEndTime: Date) => {\n const newStartDateObj = new Date(serviceStartTime);\n const newEndDateObj = new Date(serviceEndTime);\n let timeStartString = newStartDateObj.toLocaleTimeString(\"en-US\", { timeStyle: \"short\" })\n let timeEndString = newEndDateObj.toLocaleTimeString(\"en-US\", { timeStyle: \"short\" })\n timeStartString = timeStartString.slice(0, timeStartString.length - 3) +\n timeStartString.slice(timeStartString.length - 2).toLowerCase();\n timeEndString = timeEndString.slice(0, timeEndString.length - 3) +\n timeEndString.slice(timeEndString.length - 2).toLowerCase();\n return `${timeStartString} - ${timeEndString}`\n };\n\n const DivStatus = (status: AppointmentStatus | number) => {\n if (status == AppointmentStatus.Arrived) {\n return (<div className={`${classes.divStatus} ${classes.statusArrived}`}>\n <CheckIcon style={{ color: \"#36CE91\", width: 14, height: 10, marginRight: 3 }} />\n {customerArrivedTerminology}\n </div>)\n }\n else if (status == AppointmentStatus.Confirmed) {\n return (<div className={`${classes.divStatus} ${classes.statusConfirmed}`}>\n <MenuIconLogoClear viewBox=\"0 0 16 16\" style={{ color: \"#0BCBE0\", width: 16, height: 10, marginRight: 5, marginLeft: -4 }} />\n {t(\"Confirmed\")}\n </div>)\n }\n else if (status == AppointmentStatus.NotArrived) {\n return (<span className={`${classes.divStatus} ${classes.statusNotArrived}`}>\n <PersonIcon style={{ color: \"#F15857\", width: 10, height: 10, marginRight: 5 }} />\n {customerDidNotArriveTerminology}\n </span>);\n }\n else if (status == AppointmentStatus.NotConfirmed) {\n return (<div className={`${classes.divStatus} ${classes.statusNotConfirmed}`}>\n <CrossIcon viewBox=\"0 0 16 16\" style={{ color: \"#F15857\", width: 10, height: 10, marginRight: 5 }} />\n {t(\"Not Confirmed\")}\n </div>);\n } else {\n return <div></div>\n }\n };\n\n const DivPaymentStatus = (status: AppointmentPaymentStatus | number) => {\n if (status === AppointmentPaymentStatus.Paid) {\n return (<div className={`${classes.divStatus} ${classes.statusPaid}`}>\n {t(\"Paid\")}\n </div>)\n }\n else if (status === AppointmentPaymentStatus.Unpaid || status === AppointmentPaymentStatus.PaidPartially) {\n return (<span className={`${classes.divStatus} ${classes.statusUnpaid}`}>\n {t(\"Unpaid\")}\n </span>);\n } else {\n return <div></div>\n }\n };\n\n const DivNotes = (service: CustomerApptsServicesHistory | null, apptId: string, divStatus: any, divPaymentStatus: any) => {\n if (service?.notes || service?.hasEvolutionNotes) {\n return (<div className={`${classes.divNotes} ${classes.divNotesExists}`} onClick={() => toggleDrawer(service, apptId, divStatus, divPaymentStatus)} >\n <NoteIcon style={{ color: \"#6462F3\", width: 14, height: 10, marginLeft: \"-2px\", marginTop: \"-16px\" }} color={\"#6462F3\"} />\n </div>)\n } else {\n return (<div className={`${classes.divNotes} ${classes.divNotesNone}`} onClick={() => toggleDrawer(service!, apptId, divStatus, divPaymentStatus)}>\n <NoteIcon style={{ color: \"#919CA5\", width: 14, height: 10, marginLeft: \"-2px\", marginTop: \"-16px\" }} />\n </div>)\n }\n };\n\n return <div className={classes.root}>\n <div className={classes.customerHistoryPanelContent}>\n {\n appointmentsEntity.map((history, indexHistory) =>\n (<Accordion key={indexHistory} defaultExpanded={true} className={classes.accordion} >\n\n <AccordionSummary\n expandIcon={<ArrowDownIcon style={{ height: 15, width: 15, color: Color.clear1 }} />}>\n <div className={classes.monthYear} >\n {history.monthYear[0].toLocaleUpperCase(localeApp) + history.monthYear.slice(1)}\n <span className={classes.appointmentCountInMonth}>\n {\" (\" + history.appointments.length + \")\"}\n </span>\n </div>\n </AccordionSummary>\n\n <AccordionDetails className={classes.accordionDetails} >\n\n <div className={classes.appointmentsGrid}>\n {\n history.appointments.map((appointment, indexAppointments) =>\n (\n <div key={appointment.id} className={classes.appointmentsBox}>\n \n <Grid container spacing={2} className={classes.appointmentsGrid}>\n <Grid item xs={3}>\n <Typography className={classes.headerAppointments}>\n {t(\"Service & specialist\")}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n <Typography className={classes.headerAppointments}>\n {t(\"Date & Time\")}\n </Typography>\n </Grid>\n <Grid item xs={2}>\n <Typography className={classes.headerAppointments}>\n {t(\"Price\")}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n <Typography className={classes.headerAppointments}>\n {t(\"Status\")}\n </Typography>\n </Grid>\n <Grid item xs={1}>\n <Typography className={classes.headerAppointments}>\n {t(\"NotesDetails\")}\n </Typography>\n </Grid>\n \n </Grid>\n \n {\n appointment.services.map((service, indexService) =>\n (<div key={indexService}>\n <Grid\n key={indexService}\n container\n spacing={2}\n className={`${classes.appointmentsGrid} ${appointment.status === AppointmentStatus.NotArrived ? classes.apptDisabledGrid : \"\"}`}\n >\n <Grid item xs={3}>\n <Typography className={classes.serviceName}>\n {service.name}\n </Typography>\n <Typography className={classes.specialistName}>\n {service.specialist}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n <Typography className={classes.serviceDate}>\n {getServiceDate(service.start)}\n <br/>\n {getServiceTime(service.start, service.end)}\n </Typography>\n </Grid>\n <Grid item xs={2}>\n <Typography className={classes.servicePrice}>\n {service.price ? getTemplatedCurrencyValue(service.price) : \"--\"}\n </Typography>\n </Grid>\n <Grid item xs={3}>\n {DivStatus(appointment.status)}\n {DivPaymentStatus(appointment.paymentStatus)}\n </Grid>\n <Grid item xs={1}>\n {DivNotes(service, appointment.id, DivStatus(appointment.status), DivPaymentStatus(appointment.paymentStatus))}\n </Grid>\n </Grid>\n </div>\n ))\n }\n {appointment?.recurringAppointmentOrder &&\n <div className={classes.recurringAppointment}>\n {`${t(\"Recurring appointment\")} (${appointment?.recurringAppointmentOrder}/${appointment?.recurringAppointmentCount})`} </div>\n }\n {indexAppointments !== history.appointments.length - 1 &&\n <div className={classes.appointmentsGridLine}/>\n }\n </div>\n ))\n }\n </div>\n </AccordionDetails>\n </Accordion>))\n }\n {service && <>\n <Drawer\n open={drawerOpen}\n anchor=\"right\"\n classes={{ paper: classes.drawerHistoryDetails }}\n onClose={() => { if (notesSaved) setDrawerOpen(false) }}\n >\n\n <CustomerHistoryDetails\n serviceHistory={service}\n appointmentId={appointmentId}\n serviceStatus={serviceStatus}\n servicePaymentStatus={servicePaymentStatus}\n onChangedWithoutSave={changedNotesWithoutSave}\n onClose={() => setDrawerOpen(false)}\n onRefresh={refreshClose} />\n\n </Drawer>\n </>}\n </div>\n </div>;\n};","import React from \"react\";\nimport { Route, Switch, Redirect } from \"react-router-dom\";\n\nimport { Url } from \"./../../../constants/url\";\nimport CustomerMainPage from \"./../CustomerMainPage\";\nimport CustomerDetails from \"./../CustomerDetails\";\n\nconst CustomerRouter = () => {\n return (\n <Switch>\n <Route exact path={Url.Customers.Main} component={CustomerMainPage} />\n <Route\n exact\n path={Url.Customers.Main + \"/:customerId\"}\n component={CustomerDetails}\n />\n <Route path={Url.Customers.Main}>\n <Redirect to={Url.Customers.Main} />\n </Route>\n </Switch>\n );\n};\n\nexport default CustomerRouter;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n tabBar: {\n width: \"100%\",\n height: 47,\n marginTop: -20\n },\n tabs: {\n ...theme.typography.txtBody2,\n \"& .MuiTabs-indicator\": {\n backgroundColor: \"#7175FA\"\n },\n \"& .Mui-selected\": {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: \"bold\"\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n alignItems: \"left\",\n marginRight: 25\n },\n \"& .MuiTab-root\": {\n paddingLeft: 0,\n paddingRight: 0,\n },\n },\n tab: {\n ...theme.typography.txtBody2,\n textTransform: \"none\",\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n },\n \"&:hover\": {\n color: theme.colors.clearMain\n }\n },\n mainTab: {\n paddingTop: 0,\n paddingBottom: 20,\n backgroundColor: \"#ffffff\",\n height: 50,\n marginBottom: 30\n },\n headerBack: {\n height: 50,\n width: \"100%\",\n backgroundColor: \"#ffffff\",\n position: \"absolute\",\n left: 0\n }\n})\n);\n\nexport default useStyles;","import React from 'react';\n\nimport { Link, useRouteMatch } from \"react-router-dom\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { TerminologyType } from \"../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../models/enums/terminology-form\";\n\nimport { useAppSelector } from '../../../redux/hooks';\nimport { selectAccountSettings } from '../../../redux/store';\n\nimport { Tab, Tabs } from \"@material-ui/core\";\n\nimport { Url } from \"../../../constants/url\";\nimport useStyles from \"./css\";\nimport useTerminology from \"../../../hooks/useTerminology\";\n\n\nexport default function SettingsNavTabs() {\n \n const routeMatch = useRouteMatch({\n path: [\n Url.Settings.Main,\n Url.Settings.CustomerCommunications,\n Url.Settings.WorkAreas,\n Url.Settings.Services,\n Url.Settings.Users,\n Url.Settings.Payments,\n Url.Settings.ClinicHistory,\n Url.Settings.EvolutionNotes,\n Url.Settings.PatientForm,\n Url.Settings.Commissions\n ],\n exact: true\n });\n \n const currentTab = routeMatch?.path;\n \n const { t } = useTranslation([\"settings\"]);\n \n const classes = useStyles();\n \n const accountSettings = useAppSelector(selectAccountSettings);\n \n const commissions = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural });\n \n return (\n <>\n <div className={classes.headerBack}/>\n <div className={classes.mainTab}>\n <div className={classes.tabBar}>\n <Tabs\n value={currentTab}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n className={classes.tabs}\n >\n <Tab\n className={classes.tab}\n label={t(\"General\")}\n value={Url.Settings.Main}\n to={Url.Settings.Main}\n component={Link}/>\n <Tab\n className={classes.tab}\n label={t(\"Communication with the customer\")}\n value={Url.Settings.CustomerCommunications}\n to={Url.Settings.CustomerCommunications}\n component={Link}/>\n <Tab\n className={classes.tab}\n label={t(\"Work areas\")}\n value={Url.Settings.WorkAreas}\n to={Url.Settings.WorkAreas}\n component={Link}/>\n <Tab\n className={classes.tab}\n label={t(\"Services\")}\n value={Url.Settings.Services}\n to={Url.Settings.Services}\n component={Link}/>\n <Tab\n className={classes.tab}\n label={t(\"Users\")}\n value={Url.Settings.Users}\n to={Url.Settings.Users}\n component={Link}/>\n <Tab\n className={classes.tab}\n label={t(\"Payments\")}\n value={Url.Settings.Payments}\n to={Url.Settings.Payments}\n component={Link}/>\n {\n accountSettings.isClinicMode ?\n <Tab\n className={classes.tab}\n label={t(\"Clinic history\")}\n value={Url.Settings.ClinicHistory}\n to={Url.Settings.ClinicHistory}\n component={Link}\n /> :\n <div/>\n }\n {\n accountSettings.isClinicMode ?\n <Tab\n className={classes.tab}\n label={t(\"Evolution notes\")}\n value={Url.Settings.EvolutionNotes}\n to={Url.Settings.EvolutionNotes}\n component={Link}\n /> :\n <div/>\n }\n {\n accountSettings.isClinicMode ?\n <Tab\n className={classes.tab}\n label={t(\"Patient Form\")}\n value={Url.Settings.PatientForm}\n to={Url.Settings.PatientForm}\n component={Link}\n /> :\n <div/>\n }\n <Tab\n className={classes.tab}\n label={commissions}\n value={Url.Settings.Commissions}\n to={Url.Settings.Commissions}\n component={Link}/>\n </Tabs>\n </div>\n </div>\n </>);\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n width: \"100%\",\n justifyContent: \"flex-end\",\n },\n header: {\n display: \"flex\",\n width: \"100%\"\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n newUser: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n }\n },\n noteHeader: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n deleteConfirmationModal: {\n height: \"271px !important\"\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n deleteModalContentText: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n textAlign: \"center\"\n },\n deleteModalContentBoldText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\n\nimport GridList, { OnChangeEvent } from \"../../../../common/grid/GridList\";\nimport { TableColumn } from \"../../../../common/grid/table-column\";\nimport { useTranslation } from \"react-i18next\";\nimport { User } from \"../../../../../models/user\";\nimport { UserService } from \"../../../../../api/user-service\";\nimport { UserListProps } from \"./props\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { TrashIcon } from \"../../../../../assets/icons\";\nimport { Color } from \"../../../../../constants/colors\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport useStyles from \"./css\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { selectUserInfo } from \"../../../../../redux/store\";\n\n\nexport default function UserList(props: UserListProps) {\n const classes = useStyles();\n const { t } = useTranslation([\"settings\"]);\n const dispatch = useAppDispatch();\n const { settingsSelectedEstablishmentId, onRowClick, setTotalUsers, isRefresh } = props;\n const { enqueueAlert } = alertsActions;\n const userInfo = useAppSelector(selectUserInfo);\n\n const [users, setUsers] = useState<User[]>([]);\n const [totalUsers, setLocalTotalUsers] = useState<number>(0);\n\n const [page, setPage] = useState<number>(1);\n const pageSize: number = 20;\n const [order, setOrder] = useState<\"asc\" | \"desc\">(\"asc\");\n const [orderBy, setOrderBy] = useState<string>(\"friendlyId\");\n\n const [userToDelete, setUserToDelete] = useState<User | null>(null);\n const [userToDeleteUpcomingAppointmentsCount, setUserToDeleteUpcomingAppointmentsCount] = useState<number>(0);\n const [deleteConfirmationModalIsOpen, setDeleteConfirmationModalIsOpen] = useState<boolean>(false);\n\n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n fetchData();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId, page, orderBy, order, isRefresh]);\n\n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const userList = await UserService.getUsers(\n page,\n pageSize,\n order,\n orderBy,\n settingsSelectedEstablishmentId\n );\n dispatch(navbarActions.setShowLoader(false));\n setUsers(userList.users || []);\n setLocalTotalUsers(userList.totalUsers || 0);\n setTotalUsers(userList.totalUsers || 0);\n };\n\n function lpad(value: number, padding: number) {\n var zeroes = new Array(padding + 1).join(\"0\");\n return (zeroes + value).slice(-padding);\n }\n\n function displayFriendlyId(friendlyId: any) {\n return friendlyId < 1000 ? lpad(friendlyId, 3) : friendlyId\n }\n\n const columns: TableColumn[] = [\n {\n id: \"friendlyId\",\n label: t(\"ID\"),\n sorting: true,\n width: 115,\n component: displayFriendlyId,\n headerTextAlign: \"center\",\n textAlign: \"center\",\n },\n {\n id: \"name\",\n label: t(\"NAME\"),\n sorting: true,\n width: 240,\n },\n {\n id: \"email\",\n label: t(\"EMAIL\"),\n sorting: true,\n width: 240,\n },\n {\n id: \"jobPosition\",\n label: t(\"JOBPOSITION\"),\n sorting: true,\n width: 160,\n component: (item: any) => <>{t(item)}</>\n },\n {\n id: \"actions\",\n label: t(\"ACTIONS\"),\n sorting: false,\n completeObject: true,\n component: (user: User) => <Button onClick={async (e) => { e.stopPropagation(); await handleDeleteUserClick(user) }}>\n <TrashIcon style={{ color: Color.gray5, width: 13, height: 17, }} />\n </Button>,\n width: 50,\n visible: userInfo.isAdministrator\n },\n ];\n\n const handleOnChangeGrid = (event: OnChangeEvent) => {\n setPage(event.page);\n if (event.sorting) {\n setOrder(event.sorting.direction);\n setOrderBy(\n event.sorting.orderBy === \"name\" ? \"firstName\" : event.sorting.orderBy\n );\n }\n };\n\n const handleOnRowClick = (item: User) => {\n onRowClick(item.id);\n };\n\n async function handleDeleteUserClick(user: User) {\n var userUpcomingAppointmentsCount = await UserService.getUserUpcomingAppointmentsCount(user!.id!, settingsSelectedEstablishmentId);\n setUserToDeleteUpcomingAppointmentsCount(userUpcomingAppointmentsCount)\n setUserToDelete(user);\n setDeleteConfirmationModalIsOpen(true);\n };\n\n async function handleDeleteUserConfirmClick() {\n const isDeleted = await UserService.deleteUser(userToDelete!.id!, settingsSelectedEstablishmentId)\n\n if (isDeleted) {\n const usersWithoutDeletedCustomer = [...users].filter(u => u.id !== userToDelete!.id);\n setUsers(usersWithoutDeletedCustomer);\n // refreshCustomers();\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Deleted user\"),\n description: `${userToDelete?.name} (${userToDelete?.jobPosition})`\n })\n );\n }\n\n setUserToDelete(null);\n setDeleteConfirmationModalIsOpen(false);\n };\n\n const DeleteUserModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Are you sure you want to delete this user?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentBoldText}>\n {userToDelete?.name}\n </Typography>\n <Typography className={classes.deleteModalContentText}>\n {t(\"All information for this user will be deleted.\")}\n </Typography>\n </div>);\n };\n\n const DeleteUserWithAppointmentsModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"There are\") + \" \" + userToDeleteUpcomingAppointmentsCount + \" \"\n + t(\"existing appointments that cannot be served if you delete this user.\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentText}>\n {t(\"We suggest you change the specialist of these future appointments\")}\n </Typography>\n </div>);\n };\n\n return <>\n <GridList\n columns={columns}\n items={users}\n totalItems={totalUsers}\n pageSize={20}\n onChange={handleOnChangeGrid}\n onRowClick={handleOnRowClick}\n />\n {userToDelete\n ? <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteConfirmationModalIsOpen}\n item={userToDelete}\n componentInfo={userToDeleteUpcomingAppointmentsCount > 0\n ? <DeleteUserWithAppointmentsModalContent />\n : <DeleteUserModalContent />}\n onClose={() => setDeleteConfirmationModalIsOpen(false)}\n onDelete={async () => await handleDeleteUserConfirmClick()}\n textButtonConfirm={t(\"Delete user\")} />\n : <></>}\n </>\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n container: {\n width: 812,\n height: 550,\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n display: \"flex\",\n alignItems: \"flex-start\"\n },\n dialogHeader: {\n padding: \"0 0 12px\",\n },\n dialogContent: {\n padding: 0,\n overflowX: \"hidden\",\n },\n paper: {\n margin: 0,\n height: \"100%\",\n width: 812,\n maxWidth: 812,\n maxHeight: 550,\n padding: \"40px 40px 18px\",\n overflowY: \"auto\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"33px\",\n marginBottom: \"33px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: theme.colors.grey3,\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: theme.colors.grey4\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n modalTitleUserId: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n tabs: {\n \"& .MuiTabs-indicator\": {\n backgroundColor: \"#7175FA\"\n },\n \"& .Mui-selected\": {\n fontWeight: \"700 !important\",\n color: theme.colors.clearMain + \" !important\",\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n alignItems: \"left\",\n marginRight: 25\n },\n \"& .MuiTab-root\": {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.grey5,\n paddingLeft: 0,\n paddingRight: 0,\n textTransform: \"none\"\n },\n },\n tab: {\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n }\n },\n tabPanelRoot: {\n padding: \"0 !important\"\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n requiredFieldsNote: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey3,\n marginTop: 13\n },\n label: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n display: \"inline-flex\",\n margin: 0,\n marginBottom: 5\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n inputRow: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n marginTop: 24,\n width: 706\n },\n inputContainer: {\n width: 344\n },\n note: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey3,\n marginTop: 24,\n },\n divider: {\n backgroundColor: \"rgba(201, 205, 211, 0.5)\"\n },\n switchBox: {\n marginTop: 30,\n marginBottom: 6,\n display: \"flex\",\n justifyContent: \"center\"\n },\n phoneLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontFamily: \"Inter, sans-serif\",\n display: \"inline-flex\",\n marginBottom: 6,\n },\n photoContainer: {\n textAlign: \"center\",\n },\n photo: {\n width: 120,\n height: 120,\n borderRadius: \"50%\",\n backgroundColor: theme.colors.grey1,\n margin: \"auto\",\n position: \"relative\",\n cursor: \"pointer\",\n marginBottom: 10,\n marginTop: 10,\n },\n photoIconConatiner: {\n zIndex: 2,\n position: \"absolute\",\n height: \"100%\",\n padding: 30,\n },\n photoIcon: {\n width: \"70%\",\n height: \"100%\",\n margin: \"auto\",\n fontSize: 70,\n color: theme.colors.grey1,\n },\n photoHover: {\n zIndex: 3,\n position: \"absolute\",\n width: 120,\n height: 120,\n borderRadius: \"50%\",\n margin: \"auto\",\n opacity: 0,\n background: \"rgba(29, 32, 39, 0.70);\",\n \"&:hover\": {\n opacity: 1,\n backdropFilter: \"blur(5px)\"\n },\n },\n cameraIcon: {\n marginTop: 40,\n color: theme.colors.white,\n },\n changePhotoLabel: {\n marginTop: 5,\n fontWeight: 700,\n fontSize: 12,\n textAlign: \"center\",\n color: theme.colors.white,\n opacity: 1\n },\n photoLabel: {\n ...theme.typography.txtBody3,\n color: theme.colors.grey4,\n fontWeight: 700,\n fontSize: 12,\n },\n photoSizeLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n photoInitials: {\n ...theme.typography.header1,\n color: theme.colors.clear2,\n fontWeight: 700,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n width: 120,\n height: 120,\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clear2,\n borderRadius: \"50%\",\n },\n})\n);\n\nexport default useStyles;","export class JobPosition {\n id: string | null;\n name: string | null;\n isEditable: boolean;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.isEditable = x.isEditable;\n } else {\n this.id = null;\n this.name = null;\n this.isEditable = false;\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport { JobPosition } from \"../models/job-position\";\n\n\nexport class JobPositionService {\n private static baseUrl: string = \"/jobposition\";\n \n static getJobPositionList(establishmentAccountId?: string) : Promise<JobPosition[]> {\n let endpoint = `${this.baseUrl}/getlist`;\n if (establishmentAccountId) {\n endpoint += `?accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(endpoint).then(\n (data) => data.jobPositions\n );\n }\n \n static createJobPosition(jobPositionName: string, establishmentAccountId?: string) : Promise<JobPosition> {\n let request: any = { name: jobPositionName }\n if (establishmentAccountId) {\n request.accountId = establishmentAccountId;\n }\n return ApiClient.post(`${this.baseUrl}/create`, request).then(\n (data) => new JobPosition(data)\n );\n }\n \n static updateJobPosition(jobPosition: JobPosition, establishmentAccountId?: string) : Promise<JobPosition> {\n let request: any = { jobPosition: jobPosition }\n if (establishmentAccountId) {\n request.accountId = establishmentAccountId;\n }\n return ApiClient.put(`${this.baseUrl}/update`, request).then(\n (data) => new JobPosition(data)\n );\n }\n\n static deleteJobPosition(jobPositionId: string, establishmentAccountId?: string) : Promise<any> {\n let endpoint = `${this.baseUrl}/delete?jobPositionId=${jobPositionId}`;\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.remove(endpoint);\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n width: 32,\n height: 21,\n padding: 0,\n // margin: theme.spacing(1),\n },\n switchBase: {\n padding: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&$checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: theme.palette.common.white,\n \"& + $track\": {\n backgroundColor: \"#36CE91\",\n opacity: 1,\n border: \"none\",\n },\n },\n \"&$focusVisible $thumb\": {\n color: \"#36CE91\",\n border: \"6px solid #fff\",\n },\n },\n thumb: {\n width: 15,\n height: 15,\n boxShadow: \"none\",\n },\n track: {\n borderRadius: 23 / 2,\n border: \"3px solid #323947\",\n backgroundColor: theme.palette.grey[50],\n opacity: 1,\n //transition: theme.transitions.create([\"background-color\", \"border\"]),\n },\n checked: {},\n focusVisible: {},\n \n label: {\n marginLeft: \"16px\"\n },\n labelText: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: \"#5C6477\"\n },\n tooltipText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n labelWithTooltip: {\n display: \"flex\",\n flexDirection: \"column\"\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport MuiSwitch from \"@material-ui/core/Switch\";\nimport { FormControlLabel } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { SwitchWithLabelAndTooltipProps } from \"./props\";\nimport { Color } from \"../../../constants/colors\";\n\n\nexport default function SwitchWithLabelAndTooltip(props: SwitchWithLabelAndTooltipProps) {\n \n const { value, setValue, label, inactiveLabel, tooltip, inactiveTooltip, required, disabled } = props;\n \n const classes = useStyles();\n \n function getActiveLabel() {\n if (!inactiveLabel) {\n return label;\n }\n return value ? label : inactiveLabel;\n }\n \n function getActiveTooltip() {\n if (!inactiveTooltip) {\n return tooltip;\n }\n return value ? tooltip : inactiveTooltip;\n }\n \n const tryGetRequiredAsterix = () => {\n return required\n ? <span id={\"labelAsterixId\"} className={classes.labelText} style={{color: Color.clear1}}> *</span>\n : <></>\n }\n const labelWithoutTooltip = (label: string) =>\n <>\n <span id={\"labelId\"} className={classes.labelText}>{label}{tryGetRequiredAsterix()}</span>\n </>\n\n const labelWithTooltip = (label: string, tooltip?: string) =>\n <span className={classes.labelWithTooltip}>\n <span id={\"labelId\"} className={classes.labelText}>{label}{tryGetRequiredAsterix()}</span>\n <span id={\"tooltipTextId\"}className={classes.tooltipText}>{tooltip}</span>\n </span>\n \n function getLabel() {\n const labelText = getActiveLabel();\n \n if (!tooltip) {\n return labelWithoutTooltip(labelText);\n }\n \n const tooltipText = getActiveTooltip();\n return labelWithTooltip(labelText, tooltipText);\n }\n \n const Switch = \n <MuiSwitch\n focusVisibleClassName={classes.focusVisible}\n disableRipple\n classes={{\n root: classes.root,\n switchBase: classes.switchBase,\n thumb: classes.thumb,\n track: classes.track,\n checked: classes.checked,\n }}\n onChange={() => setValue(!value)}\n checked={value}\n disabled={disabled ?? false}\n />\n \n return (\n <FormControlLabel\n classes={{\n label: classes.label\n }}\n value={value}\n control={Switch}\n labelPlacement=\"end\"\n label={getLabel()}\n />\n \n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number) =>\n makeStyles((theme) => ({\n root: {},\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n },\n select: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n backgroundColor: theme.colors.grey1,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: width || 370,\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n },\n menuItem: {\n display: \"flex\",\n justifyContent: \"space-between\",\n height: 40\n },\n icons: {\n width: \"80px\",\n display: \"flex\",\n justifyContent: \"space-evenly\",\n '&:hover': {\n }\n },\n editIcon: {\n margin: \"1px\",\n color: theme.colors.grey4,\n },\n menuPaper: {\n maxHeight: 210,\n marginTop: 6\n },\n addButton: {\n borderColor: theme.colors.clearMain,\n borderRadius: \"51px\",\n width: 200,\n height: 32,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n },\n input: {\n color: \"#4a4d51\",\n width: 200,\n height: 40,\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: \"5px\",\n \"& input\": {\n backgroundColor: \"#F6F6F6 !important\"\n }\n }\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport MuiSelect from \"@material-ui/core/Select\";\nimport Input from \"@material-ui/core/Input\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\nimport Button from \"@material-ui/core/Button\";\nimport { InputAdornment, TextField } from \"@material-ui/core\";\nimport IconButton from \"@material-ui/core/IconButton\";\n\nimport { JobPositionSelectProps, SelectItem } from \"./props\";\nimport useStyles from \"./css\";\nimport { EditIcon, PlusIcon, TrashIcon } from \"../../../../../assets/icons\";\n\nexport default function JobPositionSelect(props: JobPositionSelectProps) {\n\n const { label, labelClass, placeholder, items, itemState, setItemState, width, onCreate, edit, remove, isRefresh } = props;\n\n const [addButtonState, setAddButtonState] = useState<\"button\" | \"input\">(\"button\");\n const [addInputValue, setAddInputValue] = useState<string>(\"\");\n\n const { t } = useTranslation(\"settings\");\n const classes = useStyles(width)();\n\n function isItemSelected(item: SelectItem) {\n if (typeof itemState === null || typeof item === null) return false;\n return item?.id === itemState?.id;\n }\n\n const resetAddInputState = () => {\n setAddButtonState(\"button\");\n setAddInputValue(\"\");\n };\n\n const handleOnChange = (event: any) => {\n const item = items.find(x => x.id === event.target.value) ?? null;\n setItemState(item);\n resetAddInputState();\n };\n\n const handleEdit = (item: any, event: any) => {\n if (edit) {\n edit(item);\n event.stopPropagation();\n }\n };\n\n const handleRemove = (item: any, event: any) => {\n if (remove) {\n remove(item);\n event.stopPropagation();\n }\n };\n\n const handleAddButtonClick = (event: any) => {\n setAddButtonState(\"input\");\n event.stopPropagation();\n };\n\n const handleAddInputClick = (event: any) => {\n event.target.focus();\n event.stopPropagation();\n };\n\n const handleAddInputChange = (event: any) => {\n setAddInputValue(event.target.value);\n event.target.focus();\n };\n\n const handleOnCreate = (event: any) => {\n if (onCreate) {\n onCreate(addInputValue);\n event.stopPropagation();\n }\n resetAddInputState();\n };\n\n const LabelComponent = label;\n\n const getItemName = (item: SelectItem) => {\n return item.name.substring(0, 3) === \"jp_\" ? t(item.name) : item.name;\n };\n\n return (\n <div className={classes.root}>\n <label className={labelClass ?? classes.label}>\n {typeof label === \"string\" ? label : <LabelComponent/>}\n </label>\n <MuiSelect\n disableUnderline\n className={classes.select}\n MenuProps={{\n classes: { paper: classes.menuPaper },\n getContentAnchorEl: null,\n disablePortal: true,\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\",\n },\n }}\n classes={{ root: classes.focused }}\n input={<Input/>}\n displayEmpty\n onChange={handleOnChange}\n onClose={resetAddInputState}\n value={itemState?.id || \"\"}\n >\n {placeholder ? (\n <MenuItem value=\"\" disabled>\n {placeholder}\n </MenuItem>\n ) : null}\n {items.map((item: SelectItem) =>\n <MenuItem\n key={item.id}\n value={item.id}\n className={classes.menuItem}\n >\n {getItemName(item)}\n {!isItemSelected(item) && item.isEditable &&\n <div className={classes.icons}>\n <EditIcon\n onClick={(event: any) => handleEdit(item, event)}\n className={classes.editIcon}\n />\n <TrashIcon\n onClick={(event: any) => handleRemove(item, event)}\n style={{ width: 13, height: 17, color: \"#919CA5\" }}\n />\n </div>\n }\n </MenuItem>\n )}\n <MenuItem value=\"d0429362-35e0-43dc-8acd-a8f57be02c27\">\n {addButtonState === \"button\" ?\n <Button\n className={classes.addButton}\n variant=\"outlined\"\n color=\"primary\"\n onClick={handleAddButtonClick}\n >\n {t(\"New job position\")}\n </Button>\n :\n <>\n <TextField\n variant=\"outlined\"\n value={addInputValue}\n placeholder={t(\"Job title\")}\n onChange={handleAddInputChange}\n onClick={handleAddInputClick}\n onKeyDown={e => e.stopPropagation()}\n InputProps={{\n className: classes.input,\n endAdornment: (\n <InputAdornment position=\"end\">\n <IconButton\n edge=\"end\"\n onClick={(event: any) => handleOnCreate(event)}\n disabled={addInputValue.length === 0}\n >\n <PlusIcon\n style={{ width: 16, height: 16, color: addInputValue.length === 0 ? \"#ACB7C0\" : \"#6462F3\" }}\n />\n </IconButton>\n </InputAdornment>\n )\n }}\n />\n\n </>\n }\n </MenuItem>\n </MuiSelect>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"32px 24px\",\n width: 464,\n height: 237,\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n mainContent: {\n display: \"flex\",\n flexDirection: \"column\",\n marginBottom: \"32px\"\n },\n modalHeader: {\n alignSelf: \"flex-start\",\n marginBottom: \"24px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: theme.colors.grey5\n },\n modalFooter: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-evenly\"\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { JobPositionEditModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport { JobPosition } from \"../../../../../models/job-position\";\n\n\nexport default function JobPositionEditModal(props: JobPositionEditModalProps) {\n \n const { open, setOpen, item, setItem, onClose, onEdit } = props;\n \n const setItemName = (value: string) => {\n setItem({...item, name: value})\n }\n \n const handleInputChange = (event: any) => {\n setItemName(event.target.value);\n }\n\n const handleCloseModal = () => {\n setOpen(false);\n if (onClose) {\n onClose();\n }\n setItem(new JobPosition());\n };\n \n const handleSubmit = () => {\n if (onEdit) {\n onEdit(item);\n }\n handleCloseModal();\n }\n \n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n \n const GoBackButton = () =>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n \n const SaveChangesButton = () =>\n <Button\n className={`${classes.button} ${classes.continueButton}`}\n disabled={!item?.name || item.name.length === 0}\n onClick={handleSubmit}\n >\n {t(\"Save Changes\")}\n </Button>\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.paper}>\n <div className={classes.content}>\n <div className={classes.mainContent}>\n <Typography variant=\"h4\" className={classes.modalHeader}>{t(\"Edit job position\")}</Typography>\n <InputWithLabel \n value={item.name}\n onChange={handleInputChange}\n label={t(\"Name of the job position\")}\n width={416}\n />\n </div>\n <div className={classes.modalFooter}>\n <GoBackButton />\n <SaveChangesButton />\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n position: \"relative\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"16px 24px\",\n width: 464,\n height: 227,\n },\n closeButton: {\n position: \"absolute\",\n width: 24,\n height: 24,\n top: 18,\n right: 28,\n color: theme.colors.grey4\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n mainContent: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n marginBottom: 16\n },\n modalHeader: {\n ...theme.typography.h4,\n fontFamily: \"Inter\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n marginTop: 8\n },\n deleteIcon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: 24,\n width: 50,\n height: 50,\n borderRadius: 25,\n borderColor: theme.colors.clearRed,\n color: theme.colors.clearRed,\n border: \"1px solid\"\n },\n divider: {\n width: 217,\n height: 0,\n marginTop: 16,\n border: \"1px solid #E5E7EA\",\n },\n itemName: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n marginTop: 16\n },\n modalFooter: {\n display: \"flex\",\n justifyContent: \"space-evenly\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n deleteButton: {\n background: theme.colors.clearRed,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearRed,\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n}));\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { JobPositionDeleteModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { CrossIcon, TrashIcon } from \"../../../../../assets/icons\";\n\n\nexport default function JobPositionDeleteModal(props: JobPositionDeleteModalProps) {\n \n const { item, open, setOpen, onClose, onDelete } = props;\n\n const handleCloseModal = () => {\n setOpen(false);\n if (onClose) {\n onClose();\n }\n };\n \n const handleDelete = () => {\n if (onDelete) {\n onDelete(item);\n }\n handleCloseModal();\n }\n \n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n \n const GoBackButton = () =>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n \n const DeleteButton = () =>\n <Button\n className={`${classes.button} ${classes.deleteButton}`}\n onClick={handleDelete}\n >\n {t(\"Delete\")}\n </Button>\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.paper}>\n <div className={classes.closeButton} onClick={handleCloseModal}>\n <CrossIcon />\n </div>\n <div className={classes.content}>\n <div className={classes.mainContent}>\n <div className={classes.deleteIcon}>\n <TrashIcon />\n </div>\n <Typography className={classes.modalHeader}>{t(\"Delete this job title?\")}</Typography>\n <div className={classes.divider} />\n <Typography className={classes.itemName}>{item.name}</Typography>\n </div>\n <div className={classes.modalFooter}>\n <GoBackButton />\n <DeleteButton />\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n position: \"relative\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid\",\n borderColor: theme.colors.clearYellow,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 534,\n height: 311,\n padding: \"16px 24px\",\n },\n closeButton: {\n position: \"absolute\",\n width: 24,\n height: 24,\n top: 18,\n right: 28,\n color: theme.colors.grey4\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\"\n },\n exclamationIcon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: 10,\n marginBottom: 18,\n width: 50,\n height: 50,\n borderRadius: 25,\n borderColor: theme.colors.clearYellow,\n color: theme.colors.clearYellow,\n border: \"1px solid\"\n },\n modalTitle: {\n ...theme.typography.h4,\n fontFamily: \"Inter\",\n fontWeight: \"bold\",\n color: theme.colors.grey7,\n justifySelf: \"center\",\n marginBottom: 24\n },\n modalText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n modalTextBlock: {\n height: 84,\n marginBottom: 24,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\",\n textAlign: \"center\"\n },\n modalFooter: {\n display: \"flex\",\n justifyContent: \"space-evenly\",\n },\n goBackButton: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: theme.colors.grey3,\n },\n submitButton: {\n background: theme.colors.clearGreen,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n }\n}));\n\nexport default useStyles;","import React from \"react\";\n\nimport Button from \"@material-ui/core/Button\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport useStyles from \"./css\";\nimport { useTranslation, Trans } from \"react-i18next\";\nimport { UserModalHasUpcomingAppointmentProps } from \"./props\";\nimport { CrossIcon, ExclamationIcon } from \"../../../../../assets/icons\";\n\n\nexport default function UserModalHasUpcomingAppointment(props: UserModalHasUpcomingAppointmentProps) {\n \n const { open, onCancelClick, onSaveClick } = props;\n\n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n\n const handleCloseModal = () => {\n onCancelClick();\n };\n\n const handleSubmit = () => {\n onSaveClick();\n handleCloseModal();\n }\n\n const GoBackButton = () =>\n <Button\n className={`${classes.button} ${classes.goBackButton}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n\n const SubmitButton = () =>\n <Button\n className={`${classes.button} ${classes.submitButton}`}\n onClick={handleSubmit}\n >\n {t(\"Save changes\")}\n </Button>\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.paper}>\n <div className={classes.closeButton} onClick={handleCloseModal}>\n <CrossIcon />\n </div>\n <div className={classes.content}>\n <div className={classes.exclamationIcon}>\n <ExclamationIcon viewBox=\"0 0 7 16\" />\n </div>\n <Typography className={classes.modalTitle}>\n {t(\"Continue with the new configuration?\")}\n </Typography>\n <div className={classes.modalTextBlock}>\n <Typography className={classes.modalText}>\n {t(\"This user has upcoming appointments to attend. If the user is no longer with services in charge, scheduled appointments may be affected.\")}\n </Typography>\n <Typography className={classes.modalText}>\n {t(\"We suggest you assign the appointments to another specialist. Don't forget to notify your customers about this change.\")}\n </Typography>\n </div>\n <div className={classes.modalFooter}>\n <GoBackButton />\n <SubmitButton />\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.txtBody2,\n },\n bkgPic: {\n backgroundPosition: \"center\",\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\"\n }\n\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect, useRef, useImperativeHandle } from \"react\";\nimport useStyles from \"./css\";\nimport { DropImageProps } from \"./props\";\nimport DropImageRefs from \"./refs\";\n\n\nconst DropImage = React.forwardRef<DropImageRefs, DropImageProps>((props: DropImageProps, ref) => {\n const {\n classDivUploadImage,\n componentShowEmpty,\n componentShowEmptyHover,\n imageURL,\n disableChange,\n disableBlob,\n onChange,\n funcToValid\n } = props;\n\n const classes = useStyles();\n const imageRef = useRef<HTMLInputElement>(null);\n\n const [picturl, setPicturl] = useState<any>();\n\n useImperativeHandle(ref, () => ({\n openFileExplorerDialog: showOpenFileDialog,\n }));\n\n const showOpenFileDialog = () => {\n if (disableChange) return;\n if (imageRef && imageRef != null && imageRef != undefined && imageRef.current != undefined) {\n imageRef.current.click();\n }\n };\n\n\n useEffect(() => {\n setPicturl(imageURL);\n }, [imageURL]);\n\n const dragOver = (e: any) => {\n e.preventDefault();\n }\n\n const dragEnter = (e: any) => {\n e.preventDefault();\n }\n\n const dragLeave = (e: any) => {\n e.preventDefault();\n }\n\n const fileDrop = async (e: any) => {\n e.stopPropagation();\n e.preventDefault();\n if (disableChange) return;\n\n if (imageRef.current) {\n const files = e.dataTransfer.files;\n imageRef.current.files = files;\n await handleFileSelected(files);\n }\n }\n\n const handleChangeFile = async (e: React.FormEvent<HTMLInputElement>) => {\n e.stopPropagation();\n e.preventDefault();\n if (disableChange) return;\n\n const files = imageRef.current?.files;\n await handleFileSelected(files);\n };\n\n const handleFileSelected = async (files: any) => {\n\n if (files && files.length > 0) {\n if (typeof funcToValid === \"function\" && funcToValid) {\n const validate = await funcToValid(files[0]);\n if (validate) return;\n }\n\n if (!disableBlob)\n setPicturl(URL.createObjectURL(files[0]));\n\n if (onChange) onChange(files);\n }\n }\n\n\n return (<>\n\n <input\n ref={imageRef!}\n type=\"file\"\n style={{ display: 'none' }}\n accept=\"image/jpeg, image/jpg, image/png\"\n onChange={handleChangeFile}\n />\n\n <div className={`${classes.bkgPic} ${classDivUploadImage}`}\n onClick={showOpenFileDialog}\n style={{ backgroundImage: `url(${picturl})` }}\n onDragOver={dragOver}\n onDragEnter={dragEnter}\n onDragLeave={dragLeave}\n onDrop={fileDrop} >\n\n {\n componentShowEmptyHover\n }\n {\n !picturl && componentShowEmpty\n }\n\n </div>\n\n </>);\n});\n\nexport default DropImage;\n","import React, { useEffect, useState } from \"react\";\nimport { useHistory } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport useDebounce from \"../../../../../hooks/useDebounce\";\nimport useStyles from \"./css\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { UserService } from \"../../../../../api/user-service\";\nimport { JobPositionService } from \"../../../../../api/job-position-service\";\nimport { Url } from \"../../../../../constants/url\";\n\nimport { UserModalGeneralInfoProps } from \"./props\";\nimport SwitchWithLabelAndTooltip from \"../../../../common/SwitchWithLabelAndTooltip\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport { JobPosition } from \"../../../../../models/job-position\";\nimport Country from \"../../../../../models/country\";\nimport JobPositionSelect, { SelectItem } from \"../JobPositionSelect\";\nimport JobPositionEditModal from \"../JobPositionEditModal\";\nimport JobPositionDeleteModal from \"../JobPositionDeleteModal\";\nimport InputMobileCode from \"../../../../common/InputMobileCode\";\nimport UserModalHasUpcomingAppointment from \"../UserModalHasUpcomingAppointment\";\nimport DropImage from \"../../../../common/DropImage\";\nimport { CameraIcon, UserIcon } from \"../../../../../assets/icons\";\nimport ServicesService from \"../../../../../api/settings-services-service\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\n\n\n\nexport default function UserModalGeneralInfo(props: UserModalGeneralInfoProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n const history = useHistory();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const { t } = useTranslation(\"settings\");\n const classes = useStyles();\n const treatmentTerm = useTerminology({ type: TerminologyType.Treatment, form: TerminologyForm.Singular });\n\n\n const [jobPositionEditModalOpen, setJobPositionEditModalOpen] = useState<boolean>(false);\n const [jobPositionEditItem, setJobPositionEditItem] = useState<JobPosition>(new JobPosition());\n const [jobPositionDeleteModalOpen, setJobPositionDeleteModalOpen] = useState<boolean>(false);\n const [jobPositionDeleteItem, setJobPositionDeleteItem] = useState<JobPosition>(new JobPosition());\n const [hasUpcomingAppointmentModalIsOpen, setHasUpcomingAppointmentModalIsOpen] = useState<boolean>(false);\n const [jobPositions, setJobPositions] = useState<JobPosition[]>([])\n\n const { userServices, userGeneralInfo, setUserGeneralInfo, isRefresh, setRefresh, setPhoneNumberIsValid, setEmailIsValid, emailIsValid, mode } = props;\n const [phoneFormatIsValid, setPhoneFormatIsValid] = useState<boolean>(userGeneralInfo.mobileNumber ? true : false);\n\n const debouncedPhoneValue = useDebounce({ iso3: userGeneralInfo.mobileCodeIso3, phoneNumber: userGeneralInfo.mobileNumber }, 1000);\n\n const debouncedEmailValue = useDebounce({ email: userGeneralInfo.email }, 1000);\n\n useEffect(() => {\n async function getJobPositions() {\n const jobPositions = await JobPositionService.getJobPositionList(settingsSelectedEstablishmentId)\n setJobPositions(jobPositions ?? []);\n }\n\n getJobPositions()\n }, [isRefresh])\n\n useEffect(() => {\n (async () => {\n const isUserEmailDuplicatedResponse = await UserService.getIsUserEmailDuplicated(debouncedEmailValue.email, settingsSelectedEstablishmentId);\n if (isUserEmailDuplicatedResponse.isDuplicated && userGeneralInfo.id !== isUserEmailDuplicatedResponse.userId) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid email\"),\n description: t(\"This email already belongs to user\"),\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n const location = `${Url.Settings.Users}/${isUserEmailDuplicatedResponse.userId}`;\n history.push(location);\n history.replace(location);\n history.go(0);\n },\n title: `${isUserEmailDuplicatedResponse.userFullName}`,\n }\n })\n );\n setEmailIsValid(false);\n }\n else {\n setEmailIsValid(true);\n }\n })();\n }, [debouncedEmailValue.email])\n\n useEffect(() => {\n (async () => {\n if (!phoneFormatIsValid) return;\n const isUserPhoneDuplicatedResponse = await UserService.getIsPhoneDuplicated(debouncedPhoneValue.iso3, debouncedPhoneValue.phoneNumber, settingsSelectedEstablishmentId);\n if (isUserPhoneDuplicatedResponse.isDuplicated && userGeneralInfo.id !== isUserPhoneDuplicatedResponse.userId) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid number\"),\n description: t(\"This number already belongs to user\"),\n link: {\n onClick: (e: any) => {\n e.preventDefault();\n const location = `${Url.Settings.Users}/${isUserPhoneDuplicatedResponse.userId}`;\n history.push(location);\n history.replace(location);\n history.go(0);\n },\n title: `${isUserPhoneDuplicatedResponse.userFirstName} ${isUserPhoneDuplicatedResponse.userLastName}`,\n }\n })\n );\n setPhoneNumberIsValid(false);\n }\n else\n setPhoneNumberIsValid(true);\n })();\n }, [debouncedPhoneValue.iso3, debouncedPhoneValue.phoneNumber])\n\n const setHasServicesInCharge = async (value: boolean) => {\n if (value || !userGeneralInfo.id) {\n setUserGeneralInfo({ ...userGeneralInfo, hasServicesInCharge: value });\n } \n else \n {\n let disabledServiceIds = userServices.serviceCategories\n .flatMap(category => (userGeneralInfo.hasServicesInCharge\n ? category.services.filter(service => !service.value)\n : category.services))\n .map(service => service.id);\n\n let userAppointmentCount = await UserService.getAllUserAppointmentCount(userGeneralInfo.id, disabledServiceIds, settingsSelectedEstablishmentId);\n if (userAppointmentCount > 0) {\n setHasUpcomingAppointmentModalIsOpen(true);\n }\n else {\n setUserGeneralInfo({ ...userGeneralInfo, hasServicesInCharge: value });\n }\n }\n }\n\n const setCanPrescribeTreatment = (value: boolean) => {\n setUserGeneralInfo({ ...userGeneralInfo, canPrescribeTreatment: value });\n }\n\n const handleSaveClickUserHasUpcomingAppointmentModal = () => {\n setUserGeneralInfo({ ...userGeneralInfo, hasServicesInCharge: false });\n }\n\n const setJobPosition = (value: SelectItem | null) => {\n setUserGeneralInfo({ ...userGeneralInfo, jobPosition: value ? new JobPosition(value) : null });\n }\n\n const setName = (value: string) => {\n setUserGeneralInfo({ ...userGeneralInfo, name: value });\n }\n\n const setLastNames = (value: string) => {\n setUserGeneralInfo({ ...userGeneralInfo, lastName: value });\n }\n\n const setEmail = (value: string) => {\n setUserGeneralInfo({ ...userGeneralInfo, email: value });\n }\n\n const nameChangeHandler = (event: any) => {\n setName(event.target.value)\n }\n\n const lastNameChangeHandler = (event: any) => {\n setLastNames(event.target.value)\n }\n\n const emailChangeHandler = (event: any) => {\n setEmail(event.target.value)\n }\n\n const handleMobileCodeChange = (c: Country) => {\n setUserGeneralInfo({\n ...userGeneralInfo,\n mobileCodeIso3: c.iso3,\n\n });\n };\n\n const handleMobilePhoneChange = (p: string) => {\n setUserGeneralInfo({\n ...userGeneralInfo,\n mobileNumber: p\n });\n };\n\n const handleJobOnCreate = async (jobPositionName: string) => {\n const newJob = await JobPositionService.createJobPosition(jobPositionName, settingsSelectedEstablishmentId);\n setRefresh(newJob);\n }\n\n const handleJobEdit = (selectedJob: any) => {\n setJobPositionEditItem(new JobPosition(selectedJob));\n setJobPositionEditModalOpen(true);\n }\n\n const handleJobOnEdit = async (updatedJob: JobPosition) => {\n const editedJob = await JobPositionService.updateJobPosition(updatedJob, settingsSelectedEstablishmentId);\n setRefresh(editedJob);\n }\n\n const handleJobDelete = (selectedJob: any) => {\n setJobPositionDeleteItem(new JobPosition(selectedJob));\n setJobPositionDeleteModalOpen(true);\n }\n\n const handleJobOnDelete = async (job: JobPosition) => {\n if (!job?.id) return;\n const response = await JobPositionService.deleteJobPosition(job.id, settingsSelectedEstablishmentId);\n setRefresh(response);\n }\n\n const validatePhoneNumber = (innerValidationResult: boolean) => {\n if (innerValidationResult && userGeneralInfo.mobileNumber) {\n setPhoneFormatIsValid(true);\n }\n else {\n setPhoneNumberIsValid(false);\n setPhoneFormatIsValid(false);\n }\n }\n\n async function handleUserPhotoChange(files: FileList) {\n const s3Img: any = await ServicesService.saveImage(files[0]);\n\n if (s3Img) {\n const imgURL: any = await ServicesService.getImage(s3Img.fileName);\n\n const newInfo = {\n ...userGeneralInfo,\n photoS3Key: s3Img.fileName,\n photoURL: imgURL.fileURL\n }\n\n setUserGeneralInfo(newInfo);\n }\n }\n\n function EmptyUserPhoto() {\n if (mode === \"new\")\n return (\n <div className={classes.photoIconConatiner}>\n <UserIcon className={classes.photoIcon} />\n </div>\n );\n return (\n userGeneralInfo && userGeneralInfo.name && userGeneralInfo.lastName\n ? (\n <div className={classes.photoInitials}>\n {`${userGeneralInfo.name[0]}${userGeneralInfo.lastName[0]}`.toUpperCase()}\n </div>)\n : null\n ); \n };\n\n function UserPhotoHover() {\n return (\n <div className={classes.photoHover}>\n <div className={classes.cameraIcon}>\n <CameraIcon />\n </div>\n <div className={classes.changePhotoLabel}>\n {t(\"Upload photo\")}\n </div>\n </div>\n );\n };\n\n return (\n <div className={classes.root}>\n <JobPositionEditModal\n open={jobPositionEditModalOpen}\n setOpen={setJobPositionEditModalOpen}\n item={jobPositionEditItem}\n setItem={setJobPositionEditItem}\n onEdit={handleJobOnEdit}\n />\n <JobPositionDeleteModal\n open={jobPositionDeleteModalOpen}\n setOpen={setJobPositionDeleteModalOpen}\n item={jobPositionDeleteItem}\n onDelete={handleJobOnDelete}\n />\n\n <div className={classes.photoContainer}>\n <Typography className={classes.photoLabel}>\n {t(\"Profile photo\")}\n </Typography>\n <DropImage\n classDivUploadImage={classes.photo}\n onChange={handleUserPhotoChange}\n imageURL={userGeneralInfo.photoURL}\n componentShowEmptyHover={<UserPhotoHover />}\n componentShowEmpty={<EmptyUserPhoto />}\n />\n <div className={classes.photoSizeLabel}>\n {t(\"Max size\")}: <b>800px x 800px</b>\n </div>\n </div>\n\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userGeneralInfo.hasServicesInCharge}\n setValue={setHasServicesInCharge}\n label={t(\"User with services in charge\")}\n inactiveLabel={t(\"User without services in charge\")}\n />\n <SwitchWithLabelAndTooltip\n value={userGeneralInfo.canPrescribeTreatment}\n setValue={setCanPrescribeTreatment}\n label={`${t(\"User prescribes\")} ${treatmentTerm.toLowerCase()}`}\n inactiveLabel={`${t(\"User prescribes\")} ${treatmentTerm.toLowerCase()}`}\n />\n </div>\n <div className={classes.inputRow}>\n <div className={classes.inputContainer}>\n <InputWithLabel\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Name\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </>)}\n placeholder={t(\"Enter the name of the user\")}\n value={userGeneralInfo.name || \"\"}\n onChange={nameChangeHandler}\n width={344}\n />\n </div>\n <div className={classes.inputContainer}>\n <InputWithLabel\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Last names\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </>)}\n placeholder={t(\"Enter the last name of the user\")}\n value={userGeneralInfo.lastName || \"\"}\n onChange={lastNameChangeHandler}\n width={344}\n />\n </div>\n </div>\n\n <div className={classes.inputRow}>\n <div className={classes.inputContainer}>\n <InputWithLabel\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Email\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </>)}\n placeholder={t(\"Enter the email of the user\")}\n value={userGeneralInfo.email || \"\"}\n onChange={emailChangeHandler}\n isValid={() => emailIsValid}\n width={344}\n />\n </div>\n <div className={classes.inputContainer}>\n <InputMobileCode\n isOptional={false}\n widthSelect={344}\n widthList={344}\n labelClass={classes.phoneLabel}\n requiredDotClass={classes.dot}\n isValid={validatePhoneNumber}\n onChangeItem={handleMobileCodeChange}\n onChangeMobile={handleMobilePhoneChange}\n codeIso3={userGeneralInfo.mobileCodeIso3 ?? \"MEX\"}\n mobile={userGeneralInfo.mobileNumber ?? \"\"} />\n </div>\n </div>\n <div className={classes.inputRow}>\n <div className={classes.inputContainer}>\n <JobPositionSelect\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Job position\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </>)}\n placeholder={t(\"Select the job title\")}\n items={jobPositions}\n itemState={userGeneralInfo.jobPosition}\n setItemState={setJobPosition}\n edit={handleJobEdit}\n remove={handleJobDelete}\n onCreate={handleJobOnCreate}\n width={344}\n />\n </div>\n </div>\n <span className={classes.note}>{t(\"NOTE: The password will be defined by the user of your team.\")}</span>\n <UserModalHasUpcomingAppointment\n open={hasUpcomingAppointmentModalIsOpen}\n onCancelClick={() => setHasUpcomingAppointmentModalIsOpen(false)}\n onSaveClick={handleSaveClickUserHasUpcomingAppointmentModal}\n />\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (active: boolean) => makeStyles((theme) => ({\n root: {\n width: 32,\n height: 21,\n padding: 0,\n marginLeft: 11\n // margin: theme.spacing(1),\n },\n switchBase: {\n padding: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&$checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: theme.palette.common.white,\n \"& + $track\": {\n backgroundColor: \"#36CE91\",\n opacity: 1,\n border: \"none\",\n },\n },\n \"&$focusVisible $thumb\": {\n color: \"#36CE91\",\n border: \"6px solid #fff\",\n },\n },\n thumb: {\n width: 15,\n height: 15,\n boxShadow: \"none\",\n },\n track: {\n borderRadius: 23 / 2,\n border: \"3px solid #323947\",\n backgroundColor: theme.palette.grey[50],\n opacity: 1,\n //transition: theme.transitions.create([\"background-color\", \"border\"]),\n },\n checked: {},\n focusVisible: {},\n label: {\n marginLeft: 16,\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: active ? theme.colors.grey5 : theme.colors.grey3\n },\n icon: {\n marginRight: 6\n }\n })\n);\n\nexport default useStyles;","export enum DayOfWeek {\n Sunday = 0,\n Monday,\n Tuesday,\n Wednesday,\n Thursday,\n Friday,\n Saturday\n}","import React from \"react\";\n\nimport { FormControlLabel } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { SwitchWithLabelProps } from \"./props\";\nimport MuiSwitch from \"@material-ui/core/Switch\";\n\n\nexport default function SwitchWithLabel(props: SwitchWithLabelProps) {\n \n const { className, value, setValue, label, icon, disabled } = props;\n \n const classes = useStyles(value)();\n\n const Icon = icon;\n\n const Switch =\n <MuiSwitch\n focusVisibleClassName={classes.focusVisible}\n disableRipple\n classes={{\n root: classes.root,\n switchBase: classes.switchBase,\n thumb: classes.thumb,\n track: classes.track,\n checked: classes.checked,\n }}\n onChange={() => setValue(!value)}\n checked={value}\n />\n \n return (\n <FormControlLabel\n className={className}\n classes={{\n label: classes.label\n }}\n disabled={disabled ?? false}\n value={value}\n control={Switch}\n labelPlacement=\"end\"\n label={<span><span className={icon && classes.icon}>{icon && <Icon />}</span>{label}</span>}\n />\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"row\",\n\n marginTop: 10,\n\n position: \"relative\",\n },\n header: {\n ...theme.typography.buttons,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n marginBottom: 8\n },\n switchContainer: {\n justifySelf: \"flex-start\",\n alignSelf: \"flex-start\",\n width: 140\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n\n height: 46,\n },\n windows: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n datePickers: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n gap: 6,\n\n marginBottom: 24,\n position: \"relative\"\n },\n datePickerMargin: {\n width: 24,\n height: 40\n },\n timePickersContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n gap: 6,\n\n width: 426,\n },\n timePickerContainer: {\n width: 210,\n display: \"flex\",\n flexDirection: \"column\"\n },\n timePickerInput: {\n \n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: 5,\n paddingRight: 10,\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\"\n },\n \"& * input\": {\n color: theme.colors.grey5,\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n borderRadius: \"5px\",\n height: 24,\n }\n },\n timePickerPopup: {\n zIndex: 2500\n },\n timePickerInvalid: {\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearRed\n },\n addWindowButtonContainer: {\n width: 40,\n height: 40,\n\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n addWindowButton: {\n width: 16,\n height: 16\n },\n copyToAllButton: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n position: \"absolute\",\n right: 4,\n\n width: 102,\n height: 32,\n\n backgroundColor: theme.colors.grey1,\n marginTop: 28,\n\n ...theme.typography.caption2,\n color: theme.colors.clearMain,\n fontWeight: 700,\n\n \"&:hover\": {\n backgroundColor: theme.colors.grey2,\n },\n },\n removeWindowButtonContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n width: 40,\n height: 40,\n },\n removeWindowButton: {\n width: 16,\n height: 16\n },\n divider: {\n width: 524,\n height: 0,\n marginBottom: 39,\n border: \"1px solid #F6F6F6\"\n },\n topRowMargin: {\n marginTop: 24,\n },\n tooltip: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n textAlign: \"center\",\n\n maxWidth: 150,\n paddingLeft: 8,\n paddingRight: 8,\n zIndex: 1500,\n\n backgroundColor: theme.colors.grey1,\n\n ...theme.typography.subtitle2,\n color: theme.colors.grey5,\n\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n },\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport 'antd/dist/antd.css';\nimport { TimePicker } from \"antd\";\nimport moment, { Moment } from \"moment\";\n\nimport Button from \"@material-ui/core/Button\";\nimport IconButton from \"@material-ui/core/IconButton\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nimport SwitchWithLabelAndTooltip from \"../../../../common/SwitchWithLabel\";\nimport { CopyIcon, DeleteIcon, PlusIcon } from \"../../../../../assets/icons\";\nimport { UserScheduleWindow } from \"../../../../../models/user-schedule-info\";\nimport { UserScheduleItemProps } from \"./props\";\nimport { DayOfWeek } from \"../../../../../models/enums/day-of-week\";\nimport useStyles from \"./css\";\n\n\nexport default function UserScheduleItem(props: UserScheduleItemProps) {\n \n const { day, setDay, copyToAll } = props;\n\n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n const format = 'HH:mm';\n \n function setIsAvailable(value: boolean) {\n setDay({...day, isActive: value });\n }\n\n function setWindows(value: UserScheduleWindow[]) {\n setDay({...day, windows: value });\n }\n\n function handleCopyToAll() {\n copyToAll(day)\n }\n \n function renderWindows(window: UserScheduleWindow, index: number) {\n \n const setTimeStart = (value: Moment) => {\n const newWindows = [...day.windows];\n newWindows[index].timeStart = value.format(format);\n setWindows(newWindows);\n }\n\n const setTimeClosing = (value: Moment) => {\n const newWindows = [...day.windows];\n newWindows[index].timeClosing = value.format(format);\n setWindows(newWindows);\n }\n\n const isInvalidStartTime = () => {\n const newWindowsExceptCurrent = [...day.windows].filter(x => x !== day.windows[index])\n const currentStartTime = moment(day.windows[index].timeStart, format);\n return newWindowsExceptCurrent.some(x => currentStartTime >= moment(x.timeStart, format) && currentStartTime <= moment(x.timeClosing, format))\n }\n\n const IsInvalidEndTime = () => {\n const newWindowsExceptCurrent = [...day.windows].filter(x => x !== day.windows[index])\n const currentClosingTime = moment(day.windows[index].timeClosing, format);\n return newWindowsExceptCurrent.some(x => currentClosingTime >= moment(x.timeStart, format) && currentClosingTime <= moment(x.timeClosing, format))\n }\n\n return (\n <div className={classes.datePickers} key={`day_${day.dayOfWeek}_${index}`}>\n\n <div className={classes.timePickersContainer}>\n <div className={classes.timePickerContainer}>\n {index === 0 && day.dayOfWeek === DayOfWeek.Monday &&\n <Typography className={classes.header}>\n {t('Start')}\n </Typography>\n }\n <TimePicker\n key={`timeStart_${day.dayOfWeek}_${index}`}\n className={`${classes.timePickerInput} ${isInvalidStartTime() ? classes.timePickerInvalid : null}`}\n popupClassName={classes.timePickerPopup}\n onOk={(time) => setTimeStart(time)}\n placeholder={t(\"Start\")}\n inputReadOnly={true}\n showNow={false}\n value={moment(day.windows[index].timeStart, format)}\n defaultValue={moment(day.windows[index].timeStart, format)}\n disabled={!day?.isActive}\n format={format}\n />\n </div>\n <div className={classes.timePickerContainer}>\n {index === 0 && day.dayOfWeek === DayOfWeek.Monday &&\n <Typography className={classes.header}>\n {t('Closing')}\n </Typography>\n }\n <TimePicker\n key={`timeClosing_${day.dayOfWeek}_${index}`}\n className={`${classes.timePickerInput} ${IsInvalidEndTime() ? classes.timePickerInvalid : null}`}\n popupClassName={classes.timePickerPopup}\n onOk={(time) => setTimeClosing(time)}\n placeholder={t(\"Closing\")}\n inputReadOnly={true}\n showNow={false}\n value={moment(day.windows[index].timeClosing, format)}\n defaultValue={moment(day.windows[index].timeClosing, format)}\n disabled={!day?.isActive}\n format={format}\n />\n </div>\n </div>\n\n {day?.isActive &&\n <div\n className={`${classes.addWindowButtonContainer} ${index === 0 && day.dayOfWeek === DayOfWeek.Monday ? classes.topRowMargin : null}`}\n >\n {\n day.windows.length - 1 === index &&\n <Tooltip\n title={`${t(\"Add another work schedule period to this day\")}`}\n classes={{\n tooltip: classes.tooltip\n }}\n >\n <IconButton\n className={classes.addWindowButton}\n onClick={handleAddWindow}\n disabled={day.windows.length >= 5}\n >\n <PlusIcon\n color={\"#6462F3\"}\n disabled={day.windows.length >= 5}\n />\n </IconButton>\n </Tooltip>\n }\n </div>\n }\n\n {day.isActive && index !== 0 &&\n <div\n className={`${classes.removeWindowButtonContainer} ${index === 0 && day.dayOfWeek === DayOfWeek.Monday ? classes.topRowMargin : null}`}\n >\n <Tooltip\n title={`${t(\"Remove this work schedule period\")}`}\n classes={{\n tooltip: classes.tooltip\n }}\n >\n <IconButton className={classes.removeWindowButton} onClick={() => handleRemoveWindow(window)}>\n <DeleteIcon />\n </IconButton>\n </Tooltip>\n\n </div>\n }\n </div>\n );\n }\n \n function handleAddWindow() {\n const lastWindowClosing = day.windows[day.windows.length - 1].timeClosing;\n const newWindowOpen = moment(lastWindowClosing, format).add(1, \"hour\").format(format);\n const newWindowClosing = moment(newWindowOpen, format).add(1, \"hour\").format(format)\n const newWindow = new UserScheduleWindow(newWindowOpen,newWindowClosing);\n setWindows([...day.windows, newWindow]);\n }\n \n function handleRemoveWindow(item: UserScheduleWindow) {\n const newWindows = day.windows.filter((x: UserScheduleWindow) => x !== item);\n setWindows(newWindows);\n }\n \n return (\n <div className={classes.root}>\n <div className={classes.switchContainer}>\n {day.dayOfWeek === 1 &&\n <Typography className={classes.header}>\n {t('Availability')}\n </Typography>\n }\n <div className={classes.switch}>\n <SwitchWithLabelAndTooltip\n value={day?.isActive}\n setValue={setIsAvailable}\n label={t(DayOfWeek[day.dayOfWeek])}\n />\n </div>\n </div>\n <div className={classes.windows}>\n {day.windows.map(renderWindows)}\n {day.isActive && day.dayOfWeek === DayOfWeek.Monday &&\n <Button\n variant=\"text\"\n className={classes.copyToAllButton}\n onClick={handleCopyToAll}\n >\n <CopyIcon\n color={\"#FAFAFA\"}\n border={\"#6462F3\"}\n style={{ width: 22, height: 22 }}\n />\n {t(\"Copy to all\")}\n </Button>\n }\n <div className={classes.divider} />\n </div>\n \n </div>\n );\n}","import React from \"react\";\n\nimport UserScheduleItem from \"../UserScheduleItem\";\nimport { UserModalSchedulesProps } from \"./props\";\nimport { UserScheduleDay } from \"../../../../../models/user-schedule-info\";\n\nexport default function UserModalSchedules(props: UserModalSchedulesProps) {\n \n const { schedule, setSchedule } = props;\n \n const renderScheduleItems = (day: UserScheduleDay, index: number) => {\n\n const setDay = (day: UserScheduleDay) => {\n const newSchedule = [...schedule.schedule];\n newSchedule[index] = day;\n setSchedule({...schedule, schedule: newSchedule });\n }\n\n const copyToAll = (day: UserScheduleDay) => {\n const newSchedule = [...schedule.schedule].map(item => {\n if (!item.isActive) return item;\n return new UserScheduleDay(item.dayOfWeek, day.windows, true);\n });\n setSchedule({...schedule, schedule: newSchedule });\n }\n\n return (\n <UserScheduleItem\n key={`user_schedule_item_${index}`}\n day={day}\n setDay={setDay}\n copyToAll={copyToAll}\n />\n );\n }\n \n return (\n <>\n {schedule.schedule.map(renderScheduleItems)}\n </>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n ...theme.typography.txtBody1,\n marginBottom: 21\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n marginBottom: 20\n },\n servicesContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\"\n },\n serviceItem: {\n margin: 10\n },\n divider: {\n marginTop: 30,\n marginBottom: 24,\n width: 772,\n height: 0,\n border: \"1px solid #F6F6F6\"\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\n\nexport const useStyles = makeStyles((theme) => ({\n addCertificationsContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 24,\n marginTop: 15\n },\n certificationsNotesContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n alignItems: \"flex-start\",\n width: 430,\n height: 42,\n },\n deleteButton: {\n minWidth: 16,\n height: 16,\n },\n addButton: {\n ...theme.typography.buttons,\n fontWeight: 700,\n color: theme.colors.clearMain,\n minWidth: 162,\n height: 24,\n borderRadius: 5,\n padding: \"11px 16px\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n border: \"solid\",\n justifyContent: \"space-around\",\n \"&:disabled\": {\n color: theme.colors.grey4,\n borderColor: theme.colors.grey4,\n opacity: 0.3\n }\n },\n addButtonItems: {\n width: \"100%\",\n display: \"flex\",\n justifyContent: \"space-around\",\n alignItems: \"center\",\n gap: 10\n },\n notesBoldText: {\n fontFamily: \"Roboto,sans serif\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey5\n },\n notesText: {\n fontFamily: \"Roboto,sans serif\",\n fontWeight: 400,\n fontSize: 12,\n color: theme.colors.grey5\n },\n certificationsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n minWidth: 162,\n },\n certificationHiddenContainer: {\n display: \"none\"\n },\n certificationContainer: {\n display: \"flex\",\n height: 24,\n padding: \"8px 16px\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n marginBottom: 4,\n backgroundColor: \"#FAFAFA\"\n },\n certificationName: {\n fontFamily: \"Roboto,sans serif\",\n color: theme.colors.grey4,\n fontSize: 10,\n fontWeight: 700,\n overflow: \"hidden\",\n wordWrap: \"break-word\",\n display: \"-webkit-box\",\n WebkitBoxOrient: \"vertical\",\n WebkitLineClamp: 1,\n },\n modalDelete: {\n height: 220\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalTitleText: {\n fontSize: 18,\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: theme.colors.grey7\n },\n header: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n marginBottom: 20\n },\n servicesContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\"\n },\n serviceItem: {\n margin: 10\n },\n divider: {\n marginTop: 30,\n marginBottom: 24,\n width: 772,\n height: 0,\n border: \"1px solid #F6F6F6\"\n },\n}));","import React, { useRef, useState } from \"react\";\n\nimport { useTranslation } from 'react-i18next';\n\nimport useTerminology from \"../../../../../hooks/useTerminology\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport { CircularProgress } from \"@material-ui/core\";\n\nimport { useStyles } from \"./css\";\nimport { UserServiceCertification } from \"../../../../../models/user-service-certification\";\nimport { DeleteIcon, PlusIcon } from \"../../../../../assets/icons\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport { UserServiceCertificationsProps } from \"./props\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\n\n\nexport default function UserServiceCertifications(props: UserServiceCertificationsProps) {\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const { certifications, setCertifications, handleS3ImageSave } = props;\n\n const certTerminology = useTerminology({ type: TerminologyType.Certification, form: TerminologyForm.Singular });\n\n const [openDeleteDialog, setOpenDeleteDialog] = useState<boolean>(false);\n const [certToDelete, setCertToDelete] = useState<UserServiceCertification | null>(null);\n\n const [isFileLoading, setIsFileLoading] = useState<boolean>(false);\n\n const fileInputTypes = ['image/jpeg', 'image/jpg', 'image/png'];\n const fileInputRef = useRef<HTMLInputElement>(null);\n\n async function handleCertificationUpload(file: File) {\n const dataImg = await handleS3ImageSave(file);\n\n if (dataImg) {\n\n const newOrder = certifications.certifications.length > 0\n ? Math.max(...certifications.certifications.map(cert => cert.order)) + 1\n : 0;\n\n const newImg: UserServiceCertification = {\n imageS3Key: dataImg.fileName,\n fileName: file.name,\n order: newOrder,\n serviceId: certifications.serviceId,\n userId: certifications.userId || null\n }\n\n const updatedCerts = [...certifications.certifications, newImg];\n setCertifications({ ...certifications, certifications: updatedCerts });\n }\n }\n\n async function handleFileInputChange(e: React.FormEvent<HTMLInputElement>) {\n const files = fileInputRef.current?.files;\n const file = files ? files[0] : null;\n\n setIsFileLoading(true);\n\n if (file && fileInputTypes.includes(file.type)) {\n await handleCertificationUpload(file);\n }\n\n setIsFileLoading(false);\n\n if (fileInputRef.current) {\n fileInputRef.current.value = \"\";\n }\n }\n\n function showOpenFileDialog() {\n if (fileInputRef.current) {\n fileInputRef.current?.click();\n }\n }\n\n function confirmDelete(cert: UserServiceCertification) {\n setOpenDeleteDialog(true);\n setCertToDelete(cert);\n }\n\n async function handleDelete(cert: UserServiceCertification) {\n const updatedCerts = certifications.certifications.filter(c => c.order !== cert.order);\n\n setCertifications({\n serviceId: cert.serviceId,\n userId: cert.userId ?? null,\n certifications: updatedCerts\n });\n\n setOpenDeleteDialog(false);\n }\n\n return (\n <>\n <div className={classes.addCertificationsContainer}>\n <div className={classes.certificationsContainer}>\n {certifications.certifications.map((cert, index) => (\n <div\n key={index}\n className={cert.imageS3Key ? classes.certificationContainer : classes.certificationHiddenContainer}\n >\n <Typography className={classes.certificationName}>\n {cert.fileName}\n </Typography>\n <Button\n className={classes.deleteButton}\n onClick={() => confirmDelete(cert)}\n >\n <DeleteIcon />\n </Button>\n </div>\n ))}\n\n <input\n ref={fileInputRef}\n type=\"file\"\n style={{ display: 'none' }}\n accept=\"image/jpeg, image/png\"\n onChange={handleFileInputChange}\n />\n <Button\n className={classes.addButton}\n onClick={() => showOpenFileDialog()}\n disabled={isFileLoading}\n >\n <div className={classes.addButtonItems}>\n {isFileLoading\n ? (<CircularProgress style={{ width: 10, height: 10, color: 'initial' }} />)\n : <PlusIcon style={{ width: 10, height: 10 }} />\n }\n {t(\"Add certification\", { terminology: certTerminology.toLowerCase() })}\n </div>\n </Button>\n </div>\n <div className={classes.certificationsNotesContainer}>\n <Typography className={classes.notesBoldText}>\n {`${t(\"Notes\")}:`}\n </Typography>\n <Typography className={classes.notesText}>\n {t(\"This image will be displayed on the site for appointments used by customers. Allowed formats for the image: \")}\n <span className={classes.notesBoldText}>{t(\".png or .jpg.\")}</span>\n {t(\" Maximum size: 800px x 800px.\")}\n </Typography>\n </div>\n </div>\n\n <ConfirmDeleteModal\n classModal={classes.modalDelete}\n open={openDeleteDialog}\n item={certToDelete}\n componentInfo={\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {t(\"Delete this image?\")}\n </Typography>\n </div>\n }\n onClose={() => setOpenDeleteDialog(false)}\n onDelete={handleDelete}\n />\n </>\n );\n}\n","import React from \"react\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport useStyles from \"./css\";\nimport { UserServiceCategoryProps } from \"./props\";\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport UserServiceCertifications from \"../UserServiceCertifications\";\nimport { UserServiceCertificationGroup } from \"../../../../../models/user-service-certification-group\";\nimport { UserService } from \"../../../../../models/user-service\";\n\n\nexport default function UserServiceCategory(props: UserServiceCategoryProps) {\n\n const { userId, serviceCategory, setServiceCategory, handleS3ImageSave } = props;\n \n const classes = useStyles();\n \n const renderServiceItems = (service: UserService, index: number) => {\n \n const setServices = (value: boolean) => {\n const newServices = serviceCategory.services;\n newServices[index].value = value;\n setServiceCategory({...serviceCategory, services: newServices });\n }\n\n const certifications: UserServiceCertificationGroup = {\n serviceId: service.id,\n userId: userId,\n certifications: serviceCategory.services.find(s => s.id === service.id)?.certifications ?? []\n };\n\n const setCertifications = (value: UserServiceCertificationGroup) => {\n const newServices = serviceCategory.services;\n newServices[index].certifications = value.certifications;\n setServiceCategory({ ...serviceCategory, services: newServices });\n };\n\n return (\n <div className={classes.serviceItem} key={service.id}>\n <SwitchWithLabel\n value={service.value}\n setValue={setServices}\n label={service.name}\n />\n {service.value &&\n <UserServiceCertifications\n certifications={certifications}\n setCertifications={setCertifications}\n handleS3ImageSave={handleS3ImageSave}\n />\n }\n </div>\n );\n }\n \n return (\n <div key={serviceCategory.id}>\n <Typography className={classes.header}>{serviceCategory.name}</Typography>\n <div className={classes.servicesContainer}>\n {serviceCategory.services.map(renderServiceItems)}\n </div>\n <div className={classes.divider} />\n </div>\n );\n}","import React from \"react\";\n\nimport { Trans, useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\n\nimport useStyles from \"./css\";\nimport { UserModalServicesProps } from \"./props\";\nimport { ServiceCategoryEntity } from \"../../../../../models/service-category-entity\";\nimport UserServiceCategory from \"../UserServiceCategory\";\n\n\nexport default function UserModalServices(props: UserModalServicesProps) {\n\n const { userId, userServiceInfo, setUserServiceInfo, mode, handleS3ImageSave } = props;\n \n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n \n const renderServiceCategories = (serviceCategory: ServiceCategoryEntity, index: number) => {\n \n const setServiceCategory = (value: ServiceCategoryEntity) => {\n const newServiceCategories = [...userServiceInfo.serviceCategories];\n newServiceCategories[index] = value;\n setUserServiceInfo({...userServiceInfo, serviceCategories: newServiceCategories });\n }\n \n return (\n <UserServiceCategory \n key={`service_category_${index}`}\n serviceCategory={serviceCategory}\n setServiceCategory={setServiceCategory}\n userId={userId} \n handleS3ImageSave={handleS3ImageSave}\n />\n );\n }\n \n return (\n <div>\n {mode === \"new\" &&\n <Typography className={classes.header}><Trans i18nKey=\"SelectAtLeastOneService\" t={t} /></Typography>\n }\n {userServiceInfo.serviceCategories.map(renderServiceCategories)}\n </div>\n );\n \n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n divider: {\n backgroundColor: \"rgba(201, 205, 211, 0.5) !important\",\n marginTop: \"12px !important\",\n marginBottom: \"18px !important\"\n },\n switchBox: {\n marginTop: 20,\n marginLeft: 36\n },\n sectionRow: {\n display: \"flex\",\n alignItems: \"center\"\n },\n sectionLabel: {\n color: theme.colors.grey4,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n marginLeft: 10\n },\n})\n);\n\nexport default useStyles;","import React from \"react\";\nimport { useAppSelector } from '../../../../../redux/hooks';\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { useTranslation } from \"react-i18next\";\n\nimport useStyles from \"./css\";\nimport { Divider, Typography } from \"@material-ui/core\";\nimport { UserModalPermissionsProps } from \"./props\";\nimport SwitchWithLabelAndTooltip from \"../../../../common/SwitchWithLabelAndTooltip\";\nimport { AdminIcon, UserIcon, BellIcon, MoneyIcon, MedicalBookIcon } from \"../../../../../assets/icons\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\n\n\nexport default function UserModalPermissionsInfo(props: UserModalPermissionsProps) {\n const { t } = useTranslation(\"settings\");\n const classes = useStyles();\n\n const { userPermissionsInfo, setUserPermissionsInfo } = props;\n\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const setHasCustomerInfoVisible = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, hasCustomerInfoVisible: value });\n }\n const setHasAdminAccess = (value: boolean) => {\n setUserPermissionsInfo({ \n ...userPermissionsInfo,\n hasAdminAccess: value,\n ...(value && { showPrices: true })\n });\n }\n\n const setHasMassiveSendings = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, hasMassiveSendings: value });\n }\n const setHasAccessToReports = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, hasAccessToReports: value });\n }\n const setHasAccessToScheduleAllSpecialists = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, hasAccessToScheduleAllSpecialists: value });\n }\n const setShowPrices = (value: boolean) => {\n setUserPermissionsInfo({\n ...userPermissionsInfo,\n showPrices: value,\n ...(!value && {\n canRegisterPayments: false,\n canOpenCloseCashRegister: false,\n canMakeCashRegisterMovements: false\n })\n });\n }\n\n const setNotifyOnServiceInCharge = (value: boolean) => {\n setUserPermissionsInfo({\n ...userPermissionsInfo,\n notifyOnServiceInCharge: value,\n ...(!value && {\n showAllAppointments: value\n }),\n });\n };\n\n const setNotifyOnCustomerRequiresAttention = (value: boolean) => {\n setUserPermissionsInfo({\n ...userPermissionsInfo,\n //TODO: remove or uncomment after clarifiaction (CR-2163)\n //hasAccessToWhatsAppConversationsAndNotifications: value === true ? true : userPermissionsInfo.hasAccessToWhatsAppConversationsAndNotifications,\n notifyOnCustomerRequiresAttention: value\n });\n }\n\n const setNotifyOnCashRegisterClosing = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, notifyOnCashRegisterClosing: value });\n }\n\n const setShowAllAppointments = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, showAllAppointments: value });\n }\n\n const setCanRegisterPayments = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, canRegisterPayments: value });\n }\n\n const setCanOpenCloseCashRegister = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, canOpenCloseCashRegister: value });\n }\n\n const setCanMakeCashRegisterMovements = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, canMakeCashRegisterMovements: value });\n }\n\n const setCanSeeClinicalFile = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, canSeeClinicalFile: value });\n }\n\n const setCanInteractWithEvolutionNotes = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, canInteractWithEvolutionNotes: value });\n }\n\n const setCanInteractWithPatientFiles = (value: boolean) => {\n setUserPermissionsInfo({ ...userPermissionsInfo, canInteractWithPatientFiles: value });\n }\n\n const setHasAccessToWhatsAppConversationsAndNotifications = (value: boolean) => {\n setUserPermissionsInfo({\n ...userPermissionsInfo,\n //TODO: remove or uncomment after clarifiaction (CR-2163)\n //notifyOnCustomerRequiresAttention: value === false ? false : userPermissionsInfo.notifyOnCustomerRequiresAttention,\n hasAccessToWhatsAppConversationsAndNotifications: value\n });\n }\n\n return (<>\n <div className={classes.sectionRow}>\n <AdminIcon />\n <Typography className={classes.sectionLabel}>\n {t(\"Administrator\")}\n </Typography>\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.hasAdminAccess}\n setValue={setHasAdminAccess}\n label={t(\"Administrator access\")}\n tooltip={t(\"This user can access or manage any settings.\")}\n inactiveTooltip={t(\"This user cannot access or manage any settings.\")}\n />\n </div>\n\n <Divider className={classes.divider} />\n\n <div className={classes.sectionRow}>\n <UserIcon />\n <Typography className={classes.sectionLabel}>\n {t(\"Activity\")}\n </Typography>\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.hasCustomerInfoVisible}\n setValue={setHasCustomerInfoVisible}\n label={useCustomerTerminology(t(\"Show customer information\"), \"customer\")}\n inactiveLabel={useCustomerTerminology(t(\"Show customer information\"), \"customer\")}\n tooltip={useCustomerTerminology(t(\"This user can view customer information.\"), \"customer\")}\n inactiveTooltip={t(\"This user cannot view customer information.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.hasMassiveSendings}\n setValue={setHasMassiveSendings}\n label={t(\"Send massive sendings\")}\n tooltip={t(\"This user can create, edit and delete massive sendings.\")}\n inactiveTooltip={t(\"This user cannot create, edit and delete massive sendings.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.hasAccessToWhatsAppConversationsAndNotifications}\n setValue={setHasAccessToWhatsAppConversationsAndNotifications}\n label={t(\"Show Conversations\")}\n tooltip={t(\"This user can view and send WhatsApp messages.\")}\n inactiveTooltip={t(\"This user cannot view and send WhatsApp messages.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.hasAccessToReports}\n setValue={setHasAccessToReports}\n label={t(\"Show reports\")}\n tooltip={t(\"This user can view, download, and create reports.\")}\n inactiveTooltip={t(\"This user cannot view, download, and create reports.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.hasAccessToScheduleAllSpecialists}\n setValue={setHasAccessToScheduleAllSpecialists}\n label={t(\"Show the schedule of all specialists\")}\n tooltip={t(\"This user can view the schedule of all specialists.\")}\n inactiveTooltip={t(\"This user can only view their schedule.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.showPrices}\n setValue={setShowPrices}\n label={t(\"Show price\")}\n tooltip={t(\"This user can see the prices of the appointment services and create services.\")}\n inactiveTooltip={t(\"This user cannot see the prices of the appointment services and create services.\")}\n disabled={userPermissionsInfo.hasAdminAccess}\n />\n </div>\n\n <Divider className={classes.divider} />\n\n <div className={classes.sectionRow}>\n <BellIcon />\n <Typography className={classes.sectionLabel}>\n {t(\"Notifications\")}\n </Typography>\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.notifyOnServiceInCharge}\n setValue={setNotifyOnServiceInCharge}\n label={t(\"Email notifications\")}\n tooltip={t(\"This user will be notified when he is in charge of performing a service on an appointment.\")}\n inactiveTooltip={t(\"This user will not be notified when he is in charge of performing a service on an appointment.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.notifyOnCustomerRequiresAttention}\n setValue={setNotifyOnCustomerRequiresAttention}\n label={t(\"WhatsApp notifications\")}\n tooltip={t(\"This user will be notified when a customer requires personalized attention or an estimation.\")}\n inactiveTooltip={t(\"This user will not be notified when a customer requires personalized attention or an estimation.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.notifyOnCashRegisterClosing}\n setValue={setNotifyOnCashRegisterClosing}\n label={t(\"Send WhatsApp at cash closing\")}\n tooltip={t(\"This user will be notified when the cash register is closed.\")}\n inactiveTooltip={t(\"This user will not be notified when the cash closing is performed.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.showAllAppointments}\n setValue={setShowAllAppointments}\n label={t(\"Show all appointments in other calendars\")}\n tooltip={t(\"This user can see all the appointments of all the specialists in his third calendar.\")}\n inactiveTooltip={t(\"This user can only see his appointments on his third calendar.\")}\n />\n </div>\n\n <Divider className={classes.divider} />\n\n <div className={classes.sectionRow}>\n <MoneyIcon viewBox={\"0 0 14 16\"} style={{ fontSize: '16px' }} />\n <Typography className={classes.sectionLabel}>\n {t(\"Payments\")}\n </Typography>\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.canRegisterPayments}\n setValue={setCanRegisterPayments}\n label={t(\"Register payment\")}\n tooltip={t(\"This user can perform payment registration and edition.\")}\n inactiveTooltip={t(\"This user cannot perform payment registration and edition.\")}\n disabled={!userPermissionsInfo.showPrices}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.canOpenCloseCashRegister}\n setValue={setCanOpenCloseCashRegister}\n label={t(\"Opening and closing of cash register\")}\n tooltip={t(\"This user can open and close the cash register.\")}\n inactiveTooltip={t(\"This user cannot open and close cash register.\")}\n disabled={!userPermissionsInfo.showPrices}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.canMakeCashRegisterMovements}\n setValue={setCanMakeCashRegisterMovements}\n label={t(\"New movements\")}\n tooltip={t(\"This user can perform cash movements in the cash register.\")}\n inactiveTooltip={t(\"This user cannot perform cash movements in the cash register.\")}\n disabled={!userPermissionsInfo.showPrices}\n />\n </div>\n {accountSettings.isClinicMode\n ? <>\n <Divider className={classes.divider} />\n\n <div className={classes.sectionRow}>\n <MedicalBookIcon />\n <Typography className={classes.sectionLabel}>\n {t(\"USER_PERMISSONS Clinic history\")}\n </Typography>\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.canSeeClinicalFile}\n setValue={setCanSeeClinicalFile}\n label={t(\"Clinical file\")}\n tooltip={t(\"This user can see the patient clinical file.\")}\n inactiveTooltip={t(\"This user cannot see the patient clinical file.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.canInteractWithEvolutionNotes}\n setValue={setCanInteractWithEvolutionNotes}\n label={t(\"Evolution notes\")}\n tooltip={t(\"This user can view or create the patient evolution notes.\")}\n inactiveTooltip={t(\"This user cannot view or create the patient evolution notes.\")}\n />\n </div>\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={userPermissionsInfo.canInteractWithPatientFiles}\n setValue={setCanInteractWithPatientFiles}\n label={t(\"Patient files\")}\n tooltip={t(\"This user can view or upload patient files.\")}\n inactiveTooltip={t(\"This user cannot view or upload patient files.\")}\n />\n </div>\n </>\n : <></>}\n\n </>);\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n divider: {\n backgroundColor: \"rgba(201, 205, 211, 0.5) !important\",\n marginTop: \"12px !important\",\n marginBottom: \"18px !important\"\n },\n switchBox: {\n display: \"flex\",\n marginLeft: 12,\n \"&>label\": {\n marginBottom: 0,\n marginRight: 5\n }\n },\n tooltip: {\n \"&>div[role=tooltip]\": {\n marginTop: -22\n }\n },\n sectionRow: {\n display: \"flex\",\n alignItems: \"center\"\n },\n sectionLabel: {\n color: theme.colors.grey4,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n marginLeft: 10\n },\n radios: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n gap: 10,\n marginBottom: 20\n },\n radio: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n \"&>div:first-child>div\": { // label\n color: theme.colors.grey5,\n opacity: 0.5,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n marginRight: 5\n }\n },\n radioContent: {\n textTransform: \"lowercase\",\n \"&:first-letter\": {\n textTransform: \"capitalize\"\n }\n },\n commissionsByServices: {\n display: \"flex\",\n justifyContent: \"space-between\",\n flexWrap: \"wrap\"\n },\n\n commissionByServiceItem: {\n width: \"48%\",\n marginRight: 10,\n height: 85\n },\n commissionByServiceValues: {\n display: \"flex\",\n gap: 10\n },\n serviceName: {\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: 12,\n color: \"#919CA5\",\n marginBottom: 4\n },\n contentHeader: {\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: 12,\n color: \"#919CA5\",\n marginBottom: 4,\n textTransform: \"lowercase\",\n \"&:first-letter\": {\n textTransform: \"capitalize\"\n }\n },\n defaultServices: {\n display: \"flex\",\n flexWrap: \"wrap\",\n gap: 15,\n marginBottom: 30\n },\n defaultServiceItem: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n backgroundColor: \"#F1F1F1\",\n height: 32,\n borderRadius: 51,\n padding: \"0 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: 12,\n color: \"#919CA5\",\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n defaultCommissionValues: {\n display: \"flex\",\n gap: 10,\n width: 357\n }\n})\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {\n fontFamily: \"Inter, sans-serif\",\n },\n bodyContent: {\n color: theme.colors.grey5,\n textAlign: \"center\"\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"60px\",\n height: \"60px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 20px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 196,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnCancel: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n btnOk: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n separator: {\n height: 0,\n width: 217,\n margin: \"0px auto 20px auto\",\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { CrossIcon } from \"../../../../../assets/icons\";\nimport BroadcastIcon from \"../../../../../assets/icons/BroadcastIcon\";\nimport { ConfirmationModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\nconst ConfirmationModal = (props: ConfirmationModalProps) => {\n \n const { t } = useTranslation([\"general\"]);\n const { open, title, body, okTextButton, cancelTextButton, onClose, onCancel, onConfirm } = props;\n const classes = useStyles();\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n \n <Fade in={open}>\n <div className={classes.modalPaperYellow}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <BroadcastIcon/>\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon/>\n </span>\n </div>\n </div>\n \n <div className={classes.modalContent}>\n \n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {title}\n </Typography>\n </div>\n \n <div className={classes.separator}></div>\n \n <div className={classes.bodyContent}>\n {body}\n </div>\n \n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnCancel}`} onClick={onCancel}>\n {cancelTextButton ? cancelTextButton : t(\"Cancel\")}\n </Button>\n <Button className={`${classes.button} ${classes.btnOk}`} onClick={onConfirm}>\n {okTextButton ? okTextButton : t(\"Ok\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default ConfirmationModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.subtitle2,\n \n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n radio: {\n color: theme.colors.grey5,\n paddingRight: 9,\n \"& svg\": {\n width: 14,\n height: 14\n }\n },\n checked: {\n color: theme.colors.clearMain,\n fontWeight: 700\n },\n text: {\n paddingRight: 3\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { FormControlLabel, Radio } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { RadioWithContentProps } from \"./props\";\n\n\nexport default function RadioWithContent(props: RadioWithContentProps) {\n \n const { value, checked, onCheck, content, contentClass, disabled } = props;\n const classes = useStyles();\n \n function handleChecking() {\n onCheck();\n }\n \n return (\n <div className={classes.root}>\n <Radio\n checked={checked}\n onChange={handleChecking}\n color={checked ? \"primary\" : \"default\"}\n classes={{\n root: classes.radio,\n checked: classes.checked\n }}\n disabled={disabled}\n />\n <div className={`${classes.text} ${checked ? classes.checked : ''} ${!!contentClass ? contentClass : ''}`}>{content}</div>\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\nimport { useAppSelector } from '../../../../../redux/hooks';\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { useTranslation } from \"react-i18next\";\n\nimport useStyles from \"./css\";\nimport { Divider } from \"@material-ui/core\";\nimport { UserModalCommissionsProps } from \"./props\";\nimport { InfoIcon } from \"../../../../../assets/icons\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport { UserCommissionType } from \"../../../../../models/enums/user-commission-type\";\nimport InputCurrency from \"../../../../common/InputCurrency\";\nimport { CommissionByServiceEntity } from \"../../../../../models/commission-by-service-entity\";\nimport Select from \"../../../../common/Select\";\nimport { CommissionType } from \"../../../../../models/enums/commission-type\";\nimport useCurrencyValueTemplate from \"../../../../../hooks/useCurrencyValueTemplate\";\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport ConfirmationModal from \"../../Commissions/ConfirmationModal\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport RadioWithContent from \"../../../../common/RadioWithContent\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\n\n\nexport default function UserModalCommissions(props: UserModalCommissionsProps) {\n const { t } = useTranslation(\"settings\");\n const classes = useStyles();\n\n const { userCommissionsInfo, setUserCommissionsInfo, selectedServiceIds, hasServicesInCharge, mode } = props;\n\n const [isConfirmationModalOpen, setConfirmationModalOpen] = useState<boolean>(false);\n const [isUserCommissionTypeChangeConfirmed, setIsUserCommissionTypeChangeConfirmed] = useState<boolean>(false);\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const percentageTemplate = \"{0}%\";\n const displayableCommissionsByServices = userCommissionsInfo.commissionsByServices\n .filter(cs => selectedServiceIds.includes(cs.serviceId));\n const getTemplatedCurrencyValue = useCurrencyValueTemplate(accountSettings.currencyTemplate);\n\n function needConfirmUserCommissionTypeChange(userCommissionType?: UserCommissionType) {\n const type = userCommissionType !== undefined ? userCommissionType : userCommissionsInfo.userCommissionType;\n return userCommissionsInfo.initialUserCommissionType !== type && mode === \"edit\" && !isUserCommissionTypeChangeConfirmed;\n }\n\n function getCurrencySign() {\n return accountSettings.currencyTemplate.replace(\"{0}\", \"\");\n }\n\n function commissionTypeToDisplayable(type: CommissionType | null) {\n if (type === CommissionType.Absolute) {\n return getCurrencySign();\n }\n else if (type === CommissionType.Percentage) {\n return \"%\";\n }\n return null;\n }\n\n function displayableToCommissionType(type: string) {\n if (type === \"%\") {\n return CommissionType.Percentage;\n }\n return CommissionType.Absolute;\n }\n\n function getPercentageValueByAbsolute(service: CommissionByServiceEntity): number {\n let newVal = service.commissionValue / service.servicePrice * 100;\n newVal = Math.round((newVal + Number.EPSILON) * 100) / 100;\n return newVal > 100 ? 100 : newVal;\n }\n\n function getAbsoluteValueByPercentage(service: CommissionByServiceEntity): number {\n const newVal = service.servicePrice * (service.commissionValue / 100);\n return Math.round((newVal + Number.EPSILON) * 100) / 100;\n }\n\n function getServiceAbsoluteTemplate(service: CommissionByServiceEntity): string {\n return accountSettings.currencyTemplate + ` (${percentageTemplate.replace(\"{0}\", getPercentageValueByAbsolute(service) + \"\")})`\n }\n\n function getServicePercentageTemplate(service: CommissionByServiceEntity): string {\n return percentageTemplate + ` (${getTemplatedCurrencyValue(getAbsoluteValueByPercentage(service))})`\n }\n\n const displayableCommissionTypes: string[] = [\n commissionTypeToDisplayable(CommissionType.Absolute)!,\n commissionTypeToDisplayable(CommissionType.Percentage)!,\n ];\n\n useEffect(() => {\n if (!hasServicesInCharge){\n setUserCommissionsInfo({ ...userCommissionsInfo, userCommissionType: UserCommissionType.Default });\n }\n }, [hasServicesInCharge])\n\n const setIsCommissionEnabled = (value: boolean) => {\n setUserCommissionsInfo({ ...userCommissionsInfo, isCommissionEnabled: value });\n }\n\n const handleUserCommissionTypeCheck = (value: UserCommissionType) => {\n if (needConfirmUserCommissionTypeChange(value)){\n if (value === UserCommissionType.Default) {\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionType: null, commissionValue: null, userCommissionType: value });\n }\n else if (value === UserCommissionType.ByService) {\n userCommissionsInfo.commissionsByServices.forEach(service => {\n service.commissionValue = userCommissionsInfo.commissionValue!;\n service.commissionType = userCommissionsInfo.commissionType!;\n });\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionsByServices: userCommissionsInfo.commissionsByServices, userCommissionType: value });\n }\n }\n else {\n setUserCommissionsInfo({ ...userCommissionsInfo, userCommissionType: value });\n }\n }\n\n const setServiceCommissionValue = (service: CommissionByServiceEntity, value: number) => {\n service.commissionValue = value;\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionsByServices: userCommissionsInfo.commissionsByServices });\n if (needConfirmUserCommissionTypeChange() && userCommissionsInfo.commissionValue !== value) {\n setConfirmationModalOpen(true);\n }\n }\n\n const setServiceCommissionType = (service: CommissionByServiceEntity, type: string) => {\n service.commissionType = displayableToCommissionType(type);\n if (service.commissionType === CommissionType.Percentage) {\n service.commissionValue = getPercentageValueByAbsolute(service);\n }\n else if (service.commissionType === CommissionType.Absolute) {\n service.commissionValue = getAbsoluteValueByPercentage(service);\n }\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionsByServices: userCommissionsInfo.commissionsByServices });\n if (needConfirmUserCommissionTypeChange() && userCommissionsInfo.commissionType !== service.commissionType) {\n setConfirmationModalOpen(true);\n }\n }\n\n const setCommissionValue = (value: number) => {\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionValue: value });\n if (needConfirmUserCommissionTypeChange()) {\n setConfirmationModalOpen(true);\n }\n }\n\n const setCommissionType = (displayableType: string) => {\n const type = displayableToCommissionType(displayableType);\n if (type === CommissionType.Percentage) {\n let value: number | null = null;\n if (userCommissionsInfo.commissionValue && userCommissionsInfo.commissionValue > 100) {\n value = 100;\n }\n if (value !== null) {\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionType: type, commissionValue: value });\n return;\n }\n }\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionType: type });\n if (needConfirmUserCommissionTypeChange()) {\n setConfirmationModalOpen(true);\n }\n }\n\n const confirmUserCommissionTypeChange = () => {\n setIsUserCommissionTypeChangeConfirmed(true);\n setConfirmationModalOpen(false);\n }\n\n const rejectUserCommissionTypeChange = () => {\n if (userCommissionsInfo.userCommissionType === UserCommissionType.Default) {\n setUserCommissionsInfo({ ...userCommissionsInfo, userCommissionType: UserCommissionType.ByService });\n }\n else if (userCommissionsInfo.userCommissionType === UserCommissionType.ByService) {\n setUserCommissionsInfo({ ...userCommissionsInfo, userCommissionType: UserCommissionType.Default });\n }\n setConfirmationModalOpen(false);\n }\n \n const getTerminology = (form: TerminologyForm): string => {\n const terminology = accountSettings.terminologies.find(t => t.terminologyType === TerminologyType.Commission);\n return (form === TerminologyForm.Plural ? terminology?.pluralForm ?? t('commissions') : terminology?.singularForm ?? t('commission'))!.toLowerCase();\n }\n \n const userWithCommission = useTerminology({ type: TerminologyType.Commission, template: t(\"User with commission\"), templateTermToLowercase: true });\n const userWillBeAbleToReceiveCommissions = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural, template: t(\"This user will be able to receive commissions for the services performed\"), templateTermToLowercase: true });\n const commissionByService = useTerminology({ type: TerminologyType.Commission, template: t(\"Commission by service\") });\n const defaultCommission = useTerminology({ type: TerminologyType.Commission, template: t(\"Default commission\") });\n const userWithoutServicesInCharge = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural, template: t(\"A user without services in charge may receive commissions for all services performed. It can be an amount or a percentage.\"), templateTermToLowercase: true });\n \n return (<>\n <div className={classes.switchBox}>\n <SwitchWithLabel\n value={userCommissionsInfo.isCommissionEnabled}\n setValue={setIsCommissionEnabled}\n label={userWithCommission}\n />\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 4 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={userWillBeAbleToReceiveCommissions}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n classNameRoot={classes.tooltip}\n />\n </div>\n\n <Divider className={classes.divider} />\n {userCommissionsInfo.isCommissionEnabled &&\n <>\n <div className={classes.radios}>\n <div className={classes.radio}>\n <RadioWithContent\n value={UserCommissionType.ByService}\n checked={userCommissionsInfo.userCommissionType === UserCommissionType.ByService}\n onCheck={() => handleUserCommissionTypeCheck(UserCommissionType.ByService)}\n content={commissionByService}\n contentClass={classes.radioContent}\n disabled={!hasServicesInCharge}\n />\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 4 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={hasServicesInCharge\n ? t(\"Can be different for each service, based on a fixed amount or a percentage.\")\n : t(\"It is not possible to select this option because the user is not in charge of any services.\")}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n />\n </div>\n <div className={classes.radio}>\n <RadioWithContent\n value={UserCommissionType.Default}\n checked={userCommissionsInfo.userCommissionType === UserCommissionType.Default}\n onCheck={() => handleUserCommissionTypeCheck(UserCommissionType.Default)}\n content={defaultCommission}\n contentClass={classes.radioContent}\n />\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 4 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={hasServicesInCharge\n ? t(\"Fixed amount or percentage which applies equally to all services performed.\")\n : userWithoutServicesInCharge}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n />\n </div>\n </div>\n {userCommissionsInfo.userCommissionType === UserCommissionType.ByService &&\n <>\n <div className={classes.commissionsByServices}>\n {displayableCommissionsByServices.map((service) => {\n return <div key={service.serviceId} className={classes.commissionByServiceItem}>\n <div className={classes.serviceName}>{service.serviceName} {getTemplatedCurrencyValue(service.servicePrice)}</div>\n <div className={classes.commissionByServiceValues}>\n <InputCurrency\n value={service.commissionValue}\n setValue={(value: number) => setServiceCommissionValue(service, value)}\n valueTemplate={service.commissionType === CommissionType.Absolute\n ? getServiceAbsoluteTemplate(service)\n : getServicePercentageTemplate(service)}\n isZeroAllowed={true}\n isValid={() => {\n return true;\n }}\n maxValue={service.commissionType === CommissionType.Percentage ? 100 : undefined}\n />\n <Select\n key={service.serviceId}\n width={100}\n value={commissionTypeToDisplayable(service.commissionType)}\n onChange={(event) => setServiceCommissionType(service, event.target.value)}\n colorArrowIcon={\"#5C6477\"}\n items={displayableCommissionTypes}/>\n </div>\n </div >\n })}\n </div>\n </>\n }\n {userCommissionsInfo.userCommissionType === UserCommissionType.Default &&\n <>\n {hasServicesInCharge &&\n <>\n <div className={classes.contentHeader}>{t(\"Services in charge\")}:</div>\n <div className={classes.defaultServices}>\n {displayableCommissionsByServices.map((service) => {\n return <div key={service.serviceId} className={classes.defaultServiceItem}>\n {service.serviceName}\n </div >\n })}\n </div>\n </>\n }\n <div className={classes.contentHeader}>\n {defaultCommission}\n <span className={classes.dot}>*</span>\n </div>\n <div className={classes.defaultCommissionValues}>\n <InputCurrency\n value={userCommissionsInfo.commissionValue}\n setValue={(value: number) => setCommissionValue(value)}\n valueTemplate={userCommissionsInfo.commissionType === CommissionType.Absolute\n ? accountSettings.currencyTemplate\n : userCommissionsInfo.commissionType === CommissionType.Percentage ? percentageTemplate : \"{0}\"}\n placeholder={\"--\"}\n isZeroAllowed={true}\n isValid={() => {\n return true;\n }}\n maxValue={userCommissionsInfo.commissionType === CommissionType.Percentage ? 100 : undefined}\n />\n <Select\n key={\"\"}\n width={100}\n value={commissionTypeToDisplayable(userCommissionsInfo.commissionType)}\n placeholder={\"--\"}\n onChange={(event) => setCommissionType(event.target.value)}\n colorArrowIcon={\"#5C6477\"}\n items={displayableCommissionTypes}/>\n </div>\n </>\n }\n </>\n }\n <ConfirmationModal\n open={isConfirmationModalOpen}\n title={t(\"Do you want to continue?\")}\n body={\n <>\n <div style={{display: userCommissionsInfo.userCommissionType === UserCommissionType.ByService ? \"none\" : \"\"}}>\n {useCustomerTerminology(t(\"If you modify this field, this user can no longer have different commissions for each service and instead will have a default commission for all services.\"), getTerminology(TerminologyForm.Singular), getTerminology(TerminologyForm.Plural))}\n </div>\n <div style={{display: userCommissionsInfo.userCommissionType === UserCommissionType.Default ? \"none\" : \"\"}}>\n {useCustomerTerminology(t(\"If you modify this field, this user will no longer have a default commission for all services and instead can have different commissions for each service.\"), getTerminology(TerminologyForm.Singular), getTerminology(TerminologyForm.Plural))}\n </div>\n </>\n }\n okTextButton={t(\"Yes, continue\")}\n cancelTextButton={t(\"Go back\")}\n onConfirm={confirmUserCommissionTypeChange}\n onCancel={rejectUserCommissionTypeChange}\n onClose={confirmUserCommissionTypeChange}\n />\n </>);\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n position: \"relative\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 472,\n height: 153,\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\"\n },\n modalTitle: {\n ...theme.typography.h4,\n fontFamily: \"Inter\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n marginTop: 40,\n marginBottom: 40,\n justifySelf: \"center\"\n },\n modalFooter: {\n display: \"flex\",\n justifyContent: \"space-evenly\",\n },\n goBackButton: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: theme.colors.grey3,\n },\n cancelButton: {\n background: theme.colors.clearGreen,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n }\n \n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Button from \"@material-ui/core/Button\";\n\nimport useStyles from \"./css\";\nimport { UserCancelModalProps } from \"./props\";\n\n\nexport default function UserCancelModal(props: UserCancelModalProps) {\n\n const { open, setOpen, onSubmit, title } = props;\n \n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n\n const handleCloseModal = () => {\n setOpen(false);\n };\n\n const handleSubmit = () => {\n onSubmit();\n handleCloseModal();\n }\n\n const GoBackButton = () =>\n <Button\n className={`${classes.button} ${classes.goBackButton}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n\n const CancelButton = () =>\n <Button\n className={`${classes.button} ${classes.cancelButton}`}\n onClick={handleSubmit}\n >\n {t(\"Cancel\")}\n </Button>\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.paper}>\n <div className={classes.content}>\n <Typography className={classes.modalTitle}>\n {title}\n </Typography>\n <div className={classes.modalFooter}>\n <GoBackButton />\n <CancelButton />\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","export enum TabType {\n General,\n ProfessionalInfo,\n Schedule,\n Services,\n Commissions,\n Permissions\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n labelAlternativeLabel: {\n ...theme.typography.txtBody2,\n color: `${theme.colors.grey4} !important`,\n \"& .MuiStepLabel-active\": {\n color: `${theme.colors.clearMain} !important`\n }\n },\n labelCompleted: {\n color: `${theme.colors.clearGreen} !important`\n },\n })\n);\n\nexport const useStepIconStyles = makeStyles((theme) => ({\n root: {\n color: theme.colors.grey2,\n display: 'flex',\n height: 22,\n alignItems: 'center',\n },\n circle: {\n width: 14,\n height: 14,\n borderRadius: '50%',\n border: `1px solid ${theme.colors.grey2}`\n },\n activeCircle: {\n width: 14,\n height: 14,\n borderRadius: '50%',\n border: `1px solid ${theme.colors.clearMain}`,\n backgroundColor: theme.colors.clearMain\n },\n completed: {\n color: theme.colors.clearGreen,\n zIndex: 1,\n fontSize: 22,\n fontWeight: \"bold\"\n }})\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Step, StepConnector, StepLabel, Stepper, withStyles } from \"@material-ui/core\";\n\nimport useStyles, { useStepIconStyles } from \"./css\";\nimport { Check } from \"@material-ui/icons\";\nimport { CustomStepperProps } from \"../../../../../models/interfaces/custom-stepper-props\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport { TabType } from \"../UserModal/user-modal-tab-type\";\n\n\nexport default function UserModalStepper(props: CustomStepperProps) {\n \n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n const { activeStep, userHasServicesInCharge, userCanPrescribeTreatment } = props;\n\n const StyledStepperConnector = withStyles((theme) => ({\n alternativeLabel: {\n top: 10,\n left: 'calc(-50% + 16px)',\n right: 'calc(50% + 16px)',\n },\n active: {\n '& $line': {\n borderColor: theme.colors.clearGreen,\n },\n },\n completed: {\n '& $line': {\n borderColor: theme.colors.clearGreen,\n },\n },\n line: {\n borderColor: theme.colors.grey2,\n borderTopWidth: 1,\n borderRadius: 1,\n },\n }))(StepConnector);\n\n function StepIcon(props: any) {\n const classes = useStepIconStyles();\n const { active, completed } = props;\n\n return (\n <div\n className={classes.root}\n >\n {completed ? <Check className={classes.completed} /> : active ? <div className={classes.activeCircle} /> : <div className={classes.circle} />}\n </div>\n );\n }\n \n const commissions = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural })\n \n return (\n <Stepper\n alternativeLabel\n activeStep={activeStep}\n connector={<StyledStepperConnector />}\n >\n <Step key={TabType.General}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"General information\")}\n </StepLabel>\n </Step>\n {userCanPrescribeTreatment && <Step key={TabType.ProfessionalInfo}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"Professional information\")}\n </StepLabel>\n </Step>}\n {userHasServicesInCharge && <Step key={TabType.Schedule}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"Schedules\")}\n </StepLabel>\n </Step>}\n {userHasServicesInCharge && <Step key={TabType.Services}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"Services\")}\n </StepLabel>\n </Step>}\n <Step key={TabType.Commissions}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {commissions}\n </StepLabel>\n </Step>\n <Step key={TabType.Permissions}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"Permissions and notifications\")}\n </StepLabel>\n </Step>\n </Stepper>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n position: \"relative\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid\",\n borderColor: theme.colors.clearYellow,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 534,\n height: 311,\n padding: \"16px 24px\",\n },\n closeButton: {\n position: \"absolute\",\n width: 24,\n height: 24,\n top: 18,\n right: 28,\n color: theme.colors.grey4\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\"\n },\n exclamationIcon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: 10,\n marginBottom: 18,\n width: 50,\n height: 50,\n borderRadius: 25,\n borderColor: theme.colors.clearYellow,\n color: theme.colors.clearYellow,\n border: \"1px solid\"\n },\n modalTitle: {\n ...theme.typography.h4,\n fontFamily: \"Inter\",\n fontWeight: \"bold\",\n color: theme.colors.grey7,\n justifySelf: \"center\",\n marginBottom: 24\n },\n modalText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n modalTextBlock: {\n height: 84,\n marginBottom: 24,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\",\n textAlign: \"center\"\n },\n modalFooter: {\n display: \"flex\",\n justifyContent: \"space-evenly\",\n },\n goBackButton: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: theme.colors.grey3,\n },\n submitButton: {\n background: theme.colors.clearGreen,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n }\n}));\n\nexport default useStyles;","import React from \"react\";\n\nimport Button from \"@material-ui/core/Button\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport useStyles from \"./css\";\nimport { useTranslation, Trans } from \"react-i18next\";\nimport { UserContinueEditModalProps } from \"./props\";\nimport { CrossIcon, ExclamationIcon } from \"../../../../../assets/icons\";\n\n\nexport default function UserContinueEditModal(props: UserContinueEditModalProps) {\n \n const { open, setOpen, onSubmit, appointmentCount } = props;\n\n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n\n const handleCloseModal = () => {\n setOpen(false);\n };\n\n const handleSubmit = () => {\n onSubmit();\n handleCloseModal();\n }\n\n const GoBackButton = () =>\n <Button\n className={`${classes.button} ${classes.goBackButton}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n\n const SubmitButton = () =>\n <Button\n className={`${classes.button} ${classes.submitButton}`}\n onClick={handleSubmit}\n >\n {t(\"Save changes\")}\n </Button>\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.paper}>\n <div className={classes.closeButton} onClick={handleCloseModal}>\n <CrossIcon />\n </div>\n <div className={classes.content}>\n <div className={classes.exclamationIcon}>\n <ExclamationIcon viewBox=\"0 0 7 16\" />\n </div>\n <Typography className={classes.modalTitle}>\n {t(\"Continue with the new configuration?\")}\n </Typography>\n <div className={classes.modalTextBlock}>\n <Typography className={classes.modalText}>\n <Trans i18nKey=\"ThereAreExistingAppointments\" t={t} values={{ appointmentCount }} />\n </Typography>\n <Typography className={classes.modalText}>\n <Trans i18nKey=\"WeSuggestToMoveOrReassignThem\" t={t} />\n <Trans i18nKey=\"DontForgetToNotify\" t={t} />\n </Typography>\n </div>\n <div className={classes.modalFooter}>\n <GoBackButton />\n <SubmitButton />\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n label: {\n display: \"inline-flex\",\n margin: 0,\n marginBottom: 5,\n fontFamily: \"Inter, sans-serif\",\n fontSize: \"12px\",\n fontWeight: 700,\n color: theme.colors.grey4\n },\n fieldsContainer: {\n width: 706,\n display: \"flex\",\n flexDirection: \"row\",\n flexWrap: \"wrap\",\n columnGap: \"18px\",\n rowGap: \"24px\"\n },\n inputContainer: {\n width: 344,\n flex: `1 0 calc(50% - ${theme.spacing(3)}px)`\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n requiredFieldsNote: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey3,\n marginTop: 13,\n marginBottom: 22\n },\n note: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey3,\n },\n signSectionContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n rowGap: 18\n },\n signInteractiveSection: {\n height: 233,\n width: 706,\n },\n modeButtonsBox: {\n display: \"flex\",\n height: 32,\n borderTop: \"1px solid \" + theme.colors.clearMain,\n borderLeft: \"1px solid \" + theme.colors.clearMain,\n borderRight: \"1px solid \" + theme.colors.clearMain,\n borderRadius: \"5px 5px 0px 0px\",\n },\n signModeButtonDisabled: {\n width: \"50%\",\n display: \"flex\",\n flexDirection: \"row\",\n gap: 8,\n justifyContent: \"center\",\n backgroundColor: theme.colors.clearMain,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: \"14px\",\n lineHeight: \"20px\",\n letterSpacing: \"0.1px\",\n color: theme.colors.grey1,\n \"&.MuiButton-root\": {\n borderRadius: 0,\n },\n \"&:hover\": {\n background: theme.colors.clearMain,\n },\n },\n signModeButtonEnabled: {\n width: \"50%\",\n display: \"flex\",\n flexDirection: \"row\",\n gap: 8,\n justifyContent: \"center\",\n backgroundColor: theme.colors.white,\n fontFamily: \"Roboto, sans-serif\",\n fontSize: \"14px\",\n lineHeight: \"20px\",\n letterSpacing: \"0.1px\",\n color: theme.colors.clearMain,\n \"&:hover\": {\n background: theme.colors.white,\n },\n },\n rightSignModeButton: {\n \"&.MuiButton-root\": {\n borderRadius: \"0px 4px 0px 0px\",\n },\n },\n leftSignModeButton: {\n \"&.MuiButton-root\": {\n borderRadius: \"4px 0px 0px 0px\",\n },\n },\n signInteractiveArea: {\n width: 706,\n height: 201,\n },\n drawerBox: {\n position: \"relative\",\n width: 706,\n height: 201,\n borderRadius: \"0px 0px 5px 5px\",\n border: \"1px solid \" + theme.colors.clearMain,\n },\n dropzoneBoxEmpty: {\n width: 706,\n height: 201,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n alignItems: \"center\",\n background: theme.colors.clearLilac,\n borderRadius: \"0px 0px 5px 5px\",\n border: \"1px dashed \" + theme.colors.clearMain,\n\n },\n dropzoneBoxImage: {\n width: 706,\n height: 201,\n background: theme.colors.white,\n borderRadius: \"0px 0px 5px 5px\",\n border: \"1px solid \" + theme.colors.clearMain,\n backgroundSize: \"contain !important\",\n },\n canvasSignSectionFooter: {\n display: \"flex\",\n paddingBottom: 10,\n },\n uploadSignSectionFooter: {\n display: \"flex\",\n alignItems: \"center\",\n paddingBottom: 10,\n marginTop: -10\n },\n signSectionLabel: {\n display: \"inline-flex\",\n marginTop: 21,\n marginBottom: 15,\n fontFamily: \"Inter, sans-serif\",\n fontSize: \"12px\",\n fontWeight: 700,\n color: theme.colors.grey4\n },\n addPhotoLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontSize: \"12px\",\n fontWeight: 700,\n color: theme.colors.clearMain\n },\n recommendedSizeLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontSize: \"9px\",\n fontWeight: 400,\n color: theme.colors.clear2\n },\n deleteCanvasSignButton: {\n marginLeft: \"calc(100% - 123px)\",\n width: 103,\n height: 32,\n background: theme.colors.white,\n color: theme.colors.grey4,\n borderRadius: \"51px\",\n border: \"1px solid \" + theme.colors.grey4,\n fontFamily: \"Inter, sans-serif\",\n fontSize: \"12px\",\n fontWeight: 700,\n },\n editUploadedSignButton: {\n marginLeft: \"auto\",\n \"&.MuiButton-root\": {\n minWidth: 0\n }\n },\n deleteUploadedSignButton: {\n marginRight: 16,\n \"&.MuiButton-root\": {\n minWidth: 0\n }\n },\n deleteConfirmationModal: {\n height: \"200px !important\"\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n }\n})\n);\n\nexport default useStyles;","export enum SignatureImageType {\n Drawing = 1,\n Upload = 2\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.txtBody2,\n },\n bkgPic: {\n backgroundPosition: \"center\",\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\"\n },\n modalBody: {\n ...theme.typography.txtBody1,\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n textAlign: \"center\",\n color: \"#5C6477\"\n },\n })\n);\n\nexport default useStyles;","import React, { useImperativeHandle, useRef, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Typography } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { ImageDropzoneProps } from \"./props\";\nimport ImageDropzoneRefs from \"./refs\";\nimport ExclamationModal from \"../ExclamationModal\";\n\n\nconst ImageDropzone = React.forwardRef<ImageDropzoneRefs, ImageDropzoneProps>((props: ImageDropzoneProps, ref) => {\n\n const {\n imageUrl,\n emptyFileComponent,\n onChange,\n validationFunction,\n invalidImageTitleModal,\n invalidImageBodyModal,\n dropzoneClass,\n disableChange\n } = props;\n\n const { t } = useTranslation(\"general\");\n\n const classes = useStyles();\n const imageRef = useRef<HTMLInputElement>(null);\n\n const [openModal, setOpenModal] = useState<boolean>(false);\n\n useImperativeHandle(ref, () => ({\n openFileExplorerDialog: showOpenFileDialog,\n removeImage: () => {\n if (!imageRef?.current || !imageRef.current.files || imageRef.current.files.length === 0)\n return;\n\n imageRef.current.files = new DataTransfer().files;\n }\n }));\n\n const showOpenFileDialog = () => {\n if (disableChange) return;\n if (imageRef && imageRef.current != undefined) {\n imageRef.current.click();\n }\n };\n\n const dragOver = (e: any) => {\n e.preventDefault();\n }\n\n const dragEnter = (e: any) => {\n e.preventDefault();\n }\n\n const dragLeave = (e: any) => {\n e.preventDefault();\n }\n\n const handleFileDrop = async (e: any) => {\n e.stopPropagation();\n e.preventDefault();\n if (disableChange) return;\n\n if (imageRef.current) {\n const files = e.dataTransfer.files;\n imageRef.current.files = files;\n await handleFileSelected(files);\n }\n }\n\n const handleChangeFile = async (e: React.FormEvent<HTMLInputElement>) => {\n e.stopPropagation();\n e.preventDefault();\n if (disableChange) return;\n\n const files = imageRef.current?.files;\n await handleFileSelected(files);\n };\n\n const handleFileSelected = async (files: any) => {\n\n if (files && files.length > 0) {\n const file = files[0];\n if (typeof validationFunction === \"function\" && validationFunction) {\n const validated = await validationFunction(file);\n if (!validated) {\n if (invalidImageTitleModal && invalidImageBodyModal)\n setOpenModal(true);\n return;\n }\n }\n if (onChange) onChange(file);\n }\n }\n\n const Modal = () => {\n return (\n invalidImageTitleModal && invalidImageBodyModal\n ? (\n <ExclamationModal\n open={openModal}\n title={invalidImageTitleModal}\n body={\n <Typography className={classes.modalBody}>\n {invalidImageBodyModal}\n </Typography>\n }\n okTextButton={t(\"OkUnderstand\")}\n onClose={() => setOpenModal(false)}\n />\n )\n : null\n );\n };\n\n return (\n <div>\n <Modal/>\n <input\n ref={imageRef!}\n type=\"file\"\n style={{ display: 'none' }}\n accept=\".jpg,.jpeg,.png\"\n onChange={handleChangeFile}\n />\n <div\n className={`${classes.bkgPic} ${dropzoneClass}`}\n onClick={showOpenFileDialog}\n style={{ backgroundImage: `url(${imageUrl})` }}\n onDragOver={dragOver}\n onDragEnter={dragEnter}\n onDragLeave={dragLeave}\n onDrop={handleFileDrop}\n >\n {\n !imageUrl && emptyFileComponent\n }\n </div>\n </div>);\n})\n\nexport default ImageDropzone;\n","import React, { useImperativeHandle, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport useStyles from \"./css\";\nimport { UserModalProfessionalInfoProps } from \"./props\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { FieldAndValue } from \"../../../../../models/field-and-value\";\nimport { SectionFieldValueModel } from \"../../../../../models/section-field-value-model\";\nimport { CheckIcon, PlusIcon, SectionDeleteIcon, SectionEditIcon } from \"../../../../../assets/icons\";\nimport { Color } from \"../../../../../constants/colors\";\nimport ImageDropzone from \"../../../../common/ImageDropzone\";\nimport CanvasDraw from \"react-canvas-draw\";\nimport { SignatureImageType } from \"../../../../../models/enums/signature-image-type\";\nimport UserModalProfessionalInfoRefs from \"./refs\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport ImageDropzoneRefs from \"../../../../common/ImageDropzone/refs\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\n\n\nconst UserModalProfessionalInfo = React.forwardRef<UserModalProfessionalInfoRefs, UserModalProfessionalInfoProps>((props: UserModalProfessionalInfoProps, ref) => {\n\n const { userProfessionalInfo, setUserProfessionalInfo, setSignatureImage } = props;\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"settings\", sectionTNamespace]);\n const classes = useStyles();\n\n const canvasRef = useRef<CanvasDraw | null>(null);\n const imageDropzoneRef = useRef<ImageDropzoneRefs>(null);\n const [deleteConfirmationModalIsOpen, setDeleteConfirmationModalIsOpen] = useState<boolean>(false);\n\n const brushColor = \"#000000\";\n const brushRadius = 2;\n const lazyRadius = 3;\n const validSignImageExtensions = [\"jpg\", \"jpeg\", \"png\"];\n const canvasExportImageMimeType = \"image/png\";\n const maxSignImageSize: number = 3 * 1024 * 1024; //3 Mb\n\n useImperativeHandle(ref, () => ({\n postprocessUserSignature: async () => {\n if (!canvasRef?.current ||\n userProfessionalInfo.signType !== SignatureImageType.Drawing ||\n !userProfessionalInfo.signatureReactCanvasDrawJson?.length ||\n userProfessionalInfo.signatureReactCanvasDrawJson?.length < 10)\n return;\n\n // We use \"any\" here because of outdated TS types for the \"react-canvas-draw\" lib, some functions and props are not available with the explicit \"CanvasDraw\" type.\n // Compare below GitHub code for more context and more APIs\n // TS types: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/0692d01fdbf8cfff51b8754f8b7f1df0a70cbd54/types/react-canvas-draw/index.d.ts\n // Original lib: https://github.com/embiem/react-canvas-draw/blob/987d9fb6c27b232a5a2422a7b64b27852e7c71b2/src/index.js\n const dataUrl = (canvasRef.current as any).canvasContainer.childNodes[1].toDataURL(canvasExportImageMimeType);\n\n const res = await fetch(dataUrl);\n const blob = await res.blob();\n\n const file = new File([blob], \"user_signature.png\", { type: canvasExportImageMimeType });\n\n setSignatureImage(file);\n }\n }));\n\n\n function handleChangeFieldValue(event: React.ChangeEvent<HTMLTextAreaElement | HTMLInputElement>, fieldId: string) {\n let newProfessionalInfo = { ...userProfessionalInfo };\n\n if (!newProfessionalInfo.fieldsAndValues)\n return;\n\n const index = newProfessionalInfo.fieldsAndValues.findIndex(fv => fv.field.id === fieldId);\n if (index === -1)\n return;\n\n let fieldAndValue = { ...newProfessionalInfo.fieldsAndValues[index] } as FieldAndValue;\n fieldAndValue!.value = { ...fieldAndValue.value, type: SectionFieldType.Text, value: event.target.value, } as SectionFieldValueModel;\n newProfessionalInfo.fieldsAndValues[index] = fieldAndValue;\n setUserProfessionalInfo(newProfessionalInfo);\n }\n\n function handleSetUploadSignType(): void {\n setUserProfessionalInfo({ ...userProfessionalInfo, signType: SignatureImageType.Upload });\n }\n\n function handleSetDrawingSignType(): void {\n setUserProfessionalInfo({ ...userProfessionalInfo, signType: SignatureImageType.Drawing });\n }\n\n function handleCanvasOnChange(canvas: CanvasDraw) {\n setUserProfessionalInfo({ ...userProfessionalInfo, signatureReactCanvasDrawJson: canvas.getSaveData() });\n }\n\n function handleClearCanvas() {\n canvasRef.current?.clear();\n setUserProfessionalInfo({ ...userProfessionalInfo, signatureReactCanvasDrawJson: null });\n }\n\n function handleSignImageUpload(file: File): void {\n const fileIsInvalid = validateSignImage(file);\n if (!fileIsInvalid)\n return;\n\n setUserProfessionalInfo({ ...userProfessionalInfo, signatureImageUrl: URL.createObjectURL(file), uploadedSignatureWasDeleted: false });\n setSignatureImage(file);\n }\n\n function handleDeleteUploadedSignature(): void {\n setDeleteConfirmationModalIsOpen(false);\n setUserProfessionalInfo({ ...userProfessionalInfo, signatureImageUrl: null, uploadedSignatureWasDeleted: true });\n setSignatureImage(null);\n imageDropzoneRef?.current?.removeImage();\n }\n\n function handleEditUploadedSignature(): void {\n imageDropzoneRef?.current?.openFileExplorerDialog();\n }\n\n function validateSignImage(file: File) {\n if (validSignImageExtensions.indexOf(file.name.split('.').pop()!) === -1) {\n return false;\n }\n return file.size < maxSignImageSize;\n }\n\n function mapFieldsAndValuesToComponents() {\n return userProfessionalInfo.fieldsAndValues.map(fv =>\n <div\n className={classes.inputContainer}\n key={fv.field.id + \"_input\"}\n >\n <InputWithLabel\n label={() => (<>\n <Typography className={classes.label}>\n {t(fv.field.name, { ns: sectionTNamespace })}\n </Typography>\n {fv.field.isRequired && <span className={classes.dot}>*</span>}\n </>)}\n placeholder={t(\"Enter the\") + \" \" + t(fv.field.name, { ns: sectionTNamespace }).toLowerCase()}\n value={fv.value?.value ?? \"\"}\n onChange={(e) => handleChangeFieldValue(e, fv.field.id!)}\n maxLength={80}\n width={344}\n />\n </div>)\n }\n\n\n return (\n <div className={classes.root}>\n <span className={classes.requiredFieldsNote}>\n <span>\n {t(\"Required fields\")} <span className={classes.dot}>*</span>\n </span>\n </span>\n <div className={classes.fieldsContainer}>\n {mapFieldsAndValuesToComponents()}\n </div>\n <Typography className={classes.signSectionLabel}>\n {t(\"Sign\")}\n </Typography>\n <div className={classes.signSectionContainer}>\n <Typography className={classes.note}>\n {t(\"Upload an image or draw to create your signature in this section.\")}\n </Typography>\n <div className={classes.signInteractiveSection}>\n <div className={classes.modeButtonsBox}>\n <Button\n className={`${userProfessionalInfo.signType === SignatureImageType.Drawing\n ? classes.signModeButtonEnabled\n : classes.signModeButtonDisabled}\n ${classes.leftSignModeButton}`}\n onClick={handleSetDrawingSignType}>\n {userProfessionalInfo.signType === SignatureImageType.Drawing ? <CheckIcon /> : <></>}\n {t(\"Draw signature\")}\n </Button>\n <Button\n className={`${userProfessionalInfo.signType === SignatureImageType.Upload\n ? classes.signModeButtonEnabled\n : classes.signModeButtonDisabled}\n ${classes.rightSignModeButton}`}\n onClick={handleSetUploadSignType}>\n {userProfessionalInfo.signType === SignatureImageType.Upload ? <CheckIcon /> : <></>}\n {t(\"Upload signature\")}\n </Button>\n </div>\n <div className={classes.signInteractiveArea}>\n {userProfessionalInfo.signType === SignatureImageType.Drawing\n ? <CanvasDraw\n className={classes.drawerBox}\n ref={canvasDraw => (canvasRef.current = canvasDraw)}\n canvasWidth={706}\n canvasHeight={201}\n brushRadius={brushRadius}\n brushColor={brushColor}\n lazyRadius={lazyRadius}\n onChange={handleCanvasOnChange}\n saveData={userProfessionalInfo.signatureReactCanvasDrawJson ?? canvasRef.current?.getSaveData()}\n immediateLoading\n clampLinesToDocument\n hideInterface\n hideGrid\n />\n : <div>\n <ImageDropzone\n key={\"sign-photo-upload\"}\n ref={imageDropzoneRef}\n imageUrl={userProfessionalInfo.signatureImageUrl ?? undefined}\n emptyFileComponent={<>\n <PlusIcon\n style={{ height: 32, width: 32, marginLeft: 10, marginBottom: 6, color: Color.clear1 }}\n viewBox={\"0 0 24 24\"} />\n <Typography className={classes.addPhotoLabel}>\n {t(\"Add photo\")}\n </Typography>\n <Typography className={classes.recommendedSizeLabel}>\n {t(\"Recommended size: 430px x 240px\")}\n </Typography>\n </>}\n onChange={handleSignImageUpload}\n validationFunction={validateSignImage}\n dropzoneClass={userProfessionalInfo.signatureImageUrl\n ? classes.dropzoneBoxImage\n : classes.dropzoneBoxEmpty} />\n </div>}\n </div>\n </div>\n {userProfessionalInfo.signType === SignatureImageType.Upload\n ? <div className={classes.uploadSignSectionFooter}>\n <Typography className={classes.note}>\n {t(\"Here you can upload an image with your signature. Allowed image formats: .png or .jpg.\")}\n </Typography>\n <Button\n key={\"editUploadedSignature\"}\n onClick={handleEditUploadedSignature}\n className={classes.editUploadedSignButton}\n >\n <SectionEditIcon />\n </Button>\n <Button\n key={\"deleteUploadedSignature\"}\n onClick={() => setDeleteConfirmationModalIsOpen(true)}\n className={classes.deleteUploadedSignButton}\n >\n <SectionDeleteIcon />\n </Button>\n </div>\n : <div className={classes.canvasSignSectionFooter}>\n <Button\n key={\"clearCanvasButton\"}\n className={classes.deleteCanvasSignButton}\n onClick={handleClearCanvas}>\n {t(\"Clear\")}\n </Button>\n </div>}\n </div>\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteConfirmationModalIsOpen}\n item={null}\n componentInfo={<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete this photo?\")}\n </Typography>\n </div>}\n onClose={() => setDeleteConfirmationModalIsOpen(false)}\n onDelete={handleDeleteUploadedSignature}\n textButtonConfirm={t(\"Delete\")}\n />\n </div >\n );\n})\n\nexport default UserModalProfessionalInfo;","import React, { useEffect, useRef, useState } from \"react\";\n\nimport moment from \"moment\";\n\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport { Dialog, DialogContent, DialogTitle, Tab, Tabs } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { useTranslation } from \"react-i18next\";\nimport { UserModalProps } from \"./props\";\nimport { UserEntity } from \"../../../../../models/user-entity\";\nimport UserModalGeneralInfo from \"../UserModalGeneralInfo/user-modal-general-info\";\nimport UserModalSchedules from \"../UserModalSchedules\";\nimport UserModalServices from \"../UserModalServices\";\nimport UserModalPermissions from \"../UserModalPermissions\";\nimport UserModalCommissions from \"../UserModalCommissions\";\nimport { TabContext, TabPanel } from \"@material-ui/lab\";\nimport UserCancelModal from \"../UserCancelModal\";\nimport UserModalStepper from \"../UserModalStepper\";\nimport UserContinueEditModal from \"../UserContinueEditModal\";\nimport { EmailRegex, NameRegexV2 } from \"../../../../../constants/validator\";\nimport { UserService } from \"../../../../../api/user-service\";\nimport { UserCommissionType } from \"../../../../../models/enums/user-commission-type\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { useAppSelector } from \"../../../../../redux/hooks\";\nimport UserModalProfessionalInfo from \"../UserModalProfessionalInfo\";\nimport { UserGeneralInfo } from \"../../../../../models/user-general-info\";\nimport { UserPermissionsInfo } from \"../../../../../models/user-permissions-info\";\nimport { UserProfessionalInfo } from \"../../../../../models/user-professional-info\";\nimport { UserScheduleInfo } from \"../../../../../models/user-schedule-info\";\nimport { UserServicesInfo } from \"../../../../../models/user-services-info\";\nimport { UserCommissionInfo } from \"../../../../../models/user-commission-info\";\nimport UserModalProfessionalInfoRefs from \"../UserModalProfessionalInfo/refs\";\nimport { TabType } from \"./user-modal-tab-type\";\nimport { SignatureImageType } from \"../../../../../models/enums/signature-image-type\";\nimport { UserScheduleDay, UserScheduleWindow } from \"../../../../../models/user-schedule-info\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\ninterface IContinueModalState {\n open: boolean;\n appointmentCount: number;\n}\n\n\nexport default function UserModal(props: UserModalProps) {\n\n const { settingsSelectedEstablishmentId, user, setUser, oldUser, open, setOpen, onClose, onCreate, mode, customUserSchedule, handleS3ImageSave } = props;\n \n const { t } = useTranslation(\"settings\");\n\n const [activeStep, setActiveStep] = useState<number>(0);\n const [activeTab, setActiveTab] = useState<TabType>(TabType.General);\n const [cancelModalOpen, setCancelModalOpen] = useState<boolean>(false);\n const [continueModalState, setContinueModalState] = useState<IContinueModalState>({\n open: false,\n appointmentCount: 0\n });\n const [phoneNumberIsValid, setPhoneNumberIsValid] = useState<boolean>(false);\n const [emailIsValid, setEmailIsValid] = useState<boolean>(false);\n const [previousJobPositionName, setPreviousJobPositionName] = useState<string>();\n const accountSettings = useAppSelector(selectAccountSettings);\n\n\n const timeFormat = 'HH:mm';\n \n const [isRefresh, setRefresh] = useState<any>();\n\n const professionalInfoTabRefs = useRef<UserModalProfessionalInfoRefs>(null);\n const signatureImageFileRef = useRef<File | null>(null);\n\n const classes = useStyles();\n\n const getContinueButtonTitle = mode === \"edit\"\n ? t(\"Save changes\")\n : activeStep === getFinishStepNumber()\n ? t(\"Send invite\")\n : t(\"Continue\");\n const commissions = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural });\n\n useEffect(() => {\n const jobPositionName = user?.general?.jobPosition?.name;\n\n if (previousJobPositionName !== \"jp_Administrator\" && jobPositionName !== \"jp_Administrator\")\n return;\n\n if (jobPositionName && jobPositionName !== previousJobPositionName) {\n const newPermissions = { \n ...user.permissions,\n hasAdminAccess: jobPositionName === \"jp_Administrator\",\n showPrices: jobPositionName === \"jp_Administrator\"\n };\n const newUser = { ...user, permissions: newPermissions };\n setUser(newUser);\n }\n setPreviousJobPositionName(jobPositionName!);\n }, [user.general.jobPosition]);\n\n useEffect(() => {\n if (user.general.hasServicesInCharge)\n if (user.schedule.schedule.length === 0) {\n setUserScheduleInfo(customUserSchedule!);\n }\n if (mode == \"new\" && user.general.canPrescribeTreatment) {\n setUser({ ...user, professionalInformation: { ...user.professionalInformation, signType: SignatureImageType.Drawing } });\n }\n }, [user.general.hasServicesInCharge, user.general.canPrescribeTreatment, open]);\n\n\n function setUserGeneralInfo(value: UserGeneralInfo): void {\n setUser({ ...user, general: value });\n };\n\n function setUserProfessionalInfo(value: UserProfessionalInfo): void {\n setUser({ ...user, professionalInformation: value });\n };\n\n function setUserScheduleInfo(value: UserScheduleInfo): void {\n setUser({ ...user, schedule: value });\n };\n\n function setUserServiceInfo(value: UserServicesInfo): void {\n setUser({ ...user, services: value });\n };\n\n function setUserCommissionsInfo(value: UserCommissionInfo): void {\n setUser({ ...user, commission: value });\n };\n\n function setUserPermissionsInfo(value: UserPermissionsInfo): void {\n setUser({ ...user, permissions: value });\n };\n\n function setSignatureImage(image: File | null): void {\n signatureImageFileRef.current = image;\n }\n\n function handleCloseModal(): void {\n setOpen(false);\n resetForm();\n if (onClose) {\n onClose();\n }\n }\n\n function validateTab(tab: TabType): boolean {\n switch (tab) {\n case TabType.General:\n return validateGeneralInfo();\n case TabType.ProfessionalInfo:\n return validateProfessionalInfo();\n case TabType.Schedule:\n return validateSchedule();\n case TabType.Services:\n return validateServices();\n case TabType.Commissions:\n return validateCommissions();\n case TabType.Permissions:\n return true;\n }\n }\n\n function getFinishStepNumber(): number {\n return getActiveTabs().length - 1;\n }\n\n\n function getActiveTabs(): TabType[] {\n const noServices = userHasNoServicesInCharge();\n const noProfInfo = userCannotPrescribeTreatment();\n\n if (noServices && noProfInfo)\n return [TabType.General, TabType.Commissions, TabType.Permissions];\n\n if (noServices && !noProfInfo)\n return [TabType.General, TabType.ProfessionalInfo, TabType.Commissions, TabType.Permissions];\n\n if (!noServices && noProfInfo)\n return [TabType.General, TabType.Schedule, TabType.Services, TabType.Commissions, TabType.Permissions];\n\n if (!noServices && !noProfInfo)\n return [TabType.General, TabType.ProfessionalInfo, TabType.Schedule, TabType.Services, TabType.Commissions, TabType.Permissions];\n\n return [];\n }\n\n function getContentForTab(tab: TabType): JSX.Element {\n switch (tab) {\n case TabType.General:\n return GeneralInfoContent();\n case TabType.ProfessionalInfo:\n return ProfessionalInfoContent();\n case TabType.Schedule:\n return SchedulesContent();\n case TabType.Services:\n return ServicesContent();\n case TabType.Commissions:\n return CommissionsContent();\n case TabType.Permissions:\n return PermissionsContent();\n }\n }\n\n function getContentForCurrentStep(): JSX.Element {\n const currentTab = getCurrentTab()\n return getContentForTab(currentTab);\n }\n\n function getCurrentTab(): TabType {\n const activeTabs = getActiveTabs();\n return activeTabs[activeStep];\n }\n\n function resetForm(): void {\n setUser(new UserEntity());\n setActiveStep(0);\n setActiveTab(TabType.General);\n setPhoneNumberIsValid(false);\n setEmailIsValid(false);\n }\n\n function generalInfoIsEmpty(): boolean {\n return (user.general.name?.trim() === \"\" || user.general.name === null) &&\n (user.general.lastName?.trim() === \"\" || user.general.lastName === null) &&\n (user.general.email?.trim() === \"\" || user.general.email === null);\n }\n\n function validateName(name: string | null): boolean {\n if (name === null || name?.trim() === \"\")\n return false;\n return NameRegexV2.test(name);\n }\n\n function validateGeneralInfo(): boolean {\n if (!validateName(user.general.name))\n return false;\n if (!validateName(user.general.lastName))\n return false;\n if (user.general.jobPosition === null)\n return false;\n if (!user.general.email)\n return false;\n if (!phoneNumberIsValid)\n return false;\n if (!emailIsValid)\n return false;\n return EmailRegex.test(user.general.email);\n }\n\n function validateProfessionalInfo(): boolean {\n return !user.general.canPrescribeTreatment ||\n user.professionalInformation.fieldsAndValues\n .filter(fv => fv.field.isRequired)\n .every(fv => fv.value && fv.value.value && fv.value.value.toString().length > 0);\n }\n\n function validateSchedule(): boolean {\n return user.schedule.schedule.length === 7 &&\n !user.schedule.schedule.every(x => !x.isActive) &&\n validateScheduleWindows();\n }\n\n function validateScheduleWindows(): boolean {\n return user.schedule.schedule.every(validateScheduleDay);\n }\n\n function validateScheduleDay(day: UserScheduleDay): boolean {\n return day.windows.every((window, index) => {\n const newWindowsExceptCurrent = [...day.windows].filter(x => x !== day.windows[index])\n return validateScheduleWindow(window, index, newWindowsExceptCurrent);\n })\n }\n\n function validateScheduleWindow(window: UserScheduleWindow, index: number, otherWindows: UserScheduleWindow[]): boolean {\n const currentStartTime = moment(window.timeStart, timeFormat);\n const currentClosingTime = moment(window.timeClosing, timeFormat);\n return !otherWindows.some(x =>\n (currentStartTime >= moment(x.timeStart, timeFormat) &&\n currentStartTime <= moment(x.timeClosing, timeFormat)) ||\n (currentClosingTime >= moment(x.timeStart, timeFormat) &&\n currentClosingTime <= moment(x.timeClosing, timeFormat)))\n }\n\n function validateServices(): boolean {\n return !user.services.serviceCategories.every(x => x.services.every(x => !x.value));\n }\n\n function validateCommissions(): boolean {\n return (user.commission.userCommissionType === UserCommissionType.Default || !user.general.hasServicesInCharge) && user.commission.isCommissionEnabled\n ? !!user.commission.commissionValue && user.commission.commissionValue > 0 && user.commission.commissionType !== null\n : true;\n }\n\n function userHasNoServicesInCharge() {\n return !user.general.hasServicesInCharge;\n }\n\n function userCannotPrescribeTreatment() {\n return !user.general.canPrescribeTreatment || !accountSettings.isClinicMode;\n }\n\n function isFormValid() {\n return getActiveTabs().every(t => validateTab(t));\n }\n\n function userHasNotBeenEdited() {\n return JSON.stringify(oldUser) === JSON.stringify(user);\n }\n\n function isContinueButtonDisabled() {\n if (mode === \"new\") {\n return !validateTab(getCurrentTab());\n }\n else {\n return !isFormValid() || userHasNotBeenEdited();\n }\n }\n\n function executeSubmitAndCloseModal() {\n if (onCreate) {\n onCreate(user, signatureImageFileRef.current);\n }\n handleCloseModal();\n }\n\n async function handleFormSubmit(): Promise<void> {\n if (!isFormValid())\n return;\n if (mode === \"new\") {\n executeSubmitAndCloseModal();\n return;\n }\n\n if (!user.general.id)\n return;\n\n let newUserSchedule = JSON.stringify(user.schedule);\n let oldUserSchedule = JSON.stringify(oldUser.schedule);\n let newUserServices = JSON.stringify(user.services);\n let oldUserService = JSON.stringify(oldUser.services);\n let userAppointmentCount = 0;\n\n\n if (newUserServices !== oldUserService) {\n let disabledServiceIds = user.services.serviceCategories\n .flatMap(category => (user.general.hasServicesInCharge\n ? category.services.filter(service => !service.value)\n : category.services))\n .map(service => service.id);\n\n userAppointmentCount = await UserService.getAllUserAppointmentCount(user.general.id, disabledServiceIds, settingsSelectedEstablishmentId);\n } else if (newUserSchedule !== oldUserSchedule)\n userAppointmentCount = await UserService.getUserAppointmentCount(user.general.id, user.schedule);\n\n if (userAppointmentCount === 0) {\n executeSubmitAndCloseModal();\n }\n else {\n setContinueModalState({ open: true, appointmentCount: userAppointmentCount });\n }\n }\n\n async function handleTabChange(_: any, newTab: TabType): Promise<void> {\n const currentTab = getCurrentTab();\n const nextStep = getActiveTabs().indexOf(newTab);\n setActiveStep(nextStep);\n if (mode === \"edit\" && currentTab === TabType.ProfessionalInfo) {\n await professionalInfoTabRefs?.current?.postprocessUserSignature();\n }\n setActiveTab(newTab);\n }\n\n function handleGoBackButtonClick(): void {\n if (mode === \"edit\") {\n if (userHasNotBeenEdited()) {\n handleCloseModal();\n }\n else {\n setCancelModalOpen(true);\n }\n }\n else {\n if (activeStep === 0) {\n if (generalInfoIsEmpty()) {\n handleCloseModal();\n }\n else {\n setCancelModalOpen(true);\n }\n }\n else {\n setActiveStep((prev) => prev - 1);\n }\n }\n }\n\n function onCloseHandler(_: any, reason: any): void {\n if (reason === \"backdropClick\") {\n if (mode === \"edit\") {\n if (userHasNotBeenEdited()) {\n handleCloseModal();\n }\n else {\n setCancelModalOpen(true);\n }\n }\n else {\n if (generalInfoIsEmpty()) {\n handleCloseModal();\n }\n else {\n setCancelModalOpen(true);\n }\n }\n }\n }\n\n function handleEditModalClose(): void {\n setContinueModalState({ ...continueModalState, open: false });\n }\n\n function handleEditModalSubmit(): void {\n handleEditModalClose();\n executeSubmitAndCloseModal();\n }\n\n async function handleContinueButtonClick(): Promise<void> {\n if (getCurrentTab() === TabType.ProfessionalInfo) {\n await professionalInfoTabRefs?.current?.postprocessUserSignature();\n }\n if (mode === \"edit\" || activeStep === getFinishStepNumber()) {\n handleFormSubmit();\n }\n else {\n setActiveStep((prev) => prev + 1);\n }\n }\n\n const GeneralInfoContent = () =>\n <UserModalGeneralInfo\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n userServices={user.services}\n userGeneralInfo={user.general}\n setUserGeneralInfo={setUserGeneralInfo}\n isRefresh={isRefresh}\n setRefresh={setRefresh}\n emailIsValid={emailIsValid}\n setPhoneNumberIsValid={setPhoneNumberIsValid}\n setEmailIsValid={setEmailIsValid}\n mode={mode}\n />;\n\n const ProfessionalInfoContent = () =>\n <UserModalProfessionalInfo\n ref={professionalInfoTabRefs}\n userProfessionalInfo={user.professionalInformation}\n setUserProfessionalInfo={setUserProfessionalInfo}\n setSignatureImage={setSignatureImage}\n />;\n\n const SchedulesContent = () =>\n <UserModalSchedules\n schedule={user.schedule}\n setSchedule={setUserScheduleInfo}\n />;\n\n const ServicesContent = () =>\n <UserModalServices\n userId={user.general.id}\n userServiceInfo={user.services}\n setUserServiceInfo={setUserServiceInfo}\n mode={mode}\n handleS3ImageSave={handleS3ImageSave}\n />;\n\n const CommissionsContent = () =>\n <UserModalCommissions\n userCommissionsInfo={user.commission}\n setUserCommissionsInfo={setUserCommissionsInfo}\n selectedServiceIds={user.services.serviceCategories.flatMap(sc => sc.services.filter(x => x.value).map(s => s.id))}\n hasServicesInCharge={user.general.hasServicesInCharge}\n mode={mode}\n />;\n\n const PermissionsContent = () =>\n <UserModalPermissions\n userPermissionsInfo={user.permissions}\n setUserPermissionsInfo={setUserPermissionsInfo}\n mode={mode}\n />;\n\n\n return (\n <Dialog\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n classes={{\n root: classes.modal,\n container: classes.container\n }}\n open={open}\n onClose={onCloseHandler}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n PaperProps={{\n className: classes.paper,\n elevation: 0,\n square: false\n }}\n maxWidth={false}\n scroll=\"paper\"\n >\n <DialogTitle\n className={classes.dialogHeader}\n >\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {mode === \"new\"\n ? t('New user')\n : t('User detail')\n }\n </Typography>\n {\n mode === \"edit\" &&\n <Typography className={classes.modalTitleUserId} variant=\"h1\">\n {`ID:${user.general.friendlyId}`}\n </Typography>\n }\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleGoBackButtonClick}\n >\n {t('Go back')}\n </Button>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={getContinueButtonTitle}\n onClick={handleContinueButtonClick}\n disabled={isContinueButtonDisabled()}\n />\n </div>\n </div>\n {\n mode === \"new\"\n ? <UserModalStepper\n activeStep={activeStep}\n userHasServicesInCharge={user.general.hasServicesInCharge}\n userCanPrescribeTreatment={!userCannotPrescribeTreatment()}\n />\n :\n <TabContext\n value={activeTab.toString()}\n >\n <Tabs\n className={classes.tabs}\n value={activeTab}\n onChange={handleTabChange}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n >\n <Tab\n className={classes.tab}\n label={t(\"General information\")}\n value={TabType.General}\n />\n {!userCannotPrescribeTreatment() && <Tab\n className={classes.tab}\n label={t(\"Professional information\")}\n value={TabType.ProfessionalInfo}\n />}\n {!userHasNoServicesInCharge() && <Tab\n className={classes.tab}\n label={t(\"Schedules\")}\n value={TabType.Schedule}\n />}\n {!userHasNoServicesInCharge() && <Tab\n className={classes.tab}\n label={t(\"UserModalServices\")}\n value={TabType.Services}\n />}\n <Tab\n className={classes.tab}\n label={commissions}\n value={TabType.Commissions}\n />\n <Tab\n className={classes.tab}\n label={t(\"Permissions and notifications\")}\n value={TabType.Permissions}\n />\n </Tabs>\n </TabContext>\n }\n </DialogTitle>\n <DialogContent\n className={classes.dialogContent}\n >\n <Fade in={open}>\n <div>\n {\n mode === \"new\"\n ?\n <>\n {getContentForCurrentStep()}\n </>\n :\n <>\n <TabContext\n value={activeTab.toString()}\n >\n <TabPanel\n classes={{\n root: classes.tabPanelRoot\n }}\n value={TabType.General.toString()}\n >\n {GeneralInfoContent()}\n </TabPanel>\n {!userCannotPrescribeTreatment() && <TabPanel\n classes={{\n root: classes.tabPanelRoot\n }}\n value={TabType.ProfessionalInfo.toString()}\n >\n {ProfessionalInfoContent()}\n </TabPanel>}\n {!userHasNoServicesInCharge() && <TabPanel\n value={TabType.Schedule.toString()}\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {SchedulesContent()}\n </TabPanel>}\n {!userHasNoServicesInCharge() && <TabPanel\n value={TabType.Services.toString()}\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {ServicesContent()}\n </TabPanel>}\n <TabPanel\n value={TabType.Commissions.toString()}\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {CommissionsContent()}\n </TabPanel>\n <TabPanel\n value={TabType.Permissions.toString()}\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {PermissionsContent()}\n </TabPanel>\n </TabContext>\n </>\n }\n <UserCancelModal\n open={cancelModalOpen}\n setOpen={setCancelModalOpen}\n title={mode === \"new\" ? t(\"Cancel user invitation?\") : t(\"Cancel user edition?\")}\n onSubmit={handleCloseModal}\n />\n <UserContinueEditModal\n open={continueModalState.open}\n setOpen={handleEditModalClose}\n appointmentCount={continueModalState.appointmentCount}\n onSubmit={handleEditModalSubmit}\n />\n </div>\n </Fade>\n </DialogContent>\n </Dialog>\n );\n}","import { makeStyles } from \"@material-ui/core\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n verticalAlign: \"middle\",\n display: \"inline-flex\",\n margin: \"0px 0px 24px 0px\",\n },\n titles: {\n color: \"#919CA5\",\n },\n icons: {\n display: \"flex\",\n alignItems: \"center\",\n margin: \"7px 0px 0px 0px\"\n },\n icon: {\n marginRight: 6,\n },\n classification: {\n width: 104,\n margin: \"0px 25px 0px 0px\",\n }\n}));","export enum SectionType {\n ClinicHistory = 1,\n VitalSigns = 2,\n PatientForm = 3,\n UserTreatment = 4\n}","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { useStyles } from \"./css\";\nimport { UserStatisticProps } from \"./props\";\n\nimport CustomerClassificationItem from \"../../../../customers/CustomerClassificationItem\";\nimport { PersonIcon } from \"../../../../../assets/icons\";\n\n\nexport default function UserStatistic(props: UserStatisticProps) {\n\n const { totalUsers } = props;\n\n const { t } = useTranslation([\"settings\"]);\n const classes = useStyles();\n \n return (\n <div className={classes.root}>\n <CustomerClassificationItem\n className={classes.icons}\n classes={classes}\n title={t(\"Users\")}\n value={totalUsers}\n icon={PersonIcon}\n />\n \n </div>\n );\n}","export class SectionFieldCreateResponse {\n id: string;\n fieldItemIds: string[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.fieldItemIds = x.fieldItemIds;\n } else {\n this.id = \"\";\n this.fieldItemIds = [];\n }\n }\n}","export class SectionFieldUpdateResponse {\n id: string;\n fieldItemIds: string[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.fieldItemIds = x.fieldItemIds;\n } else {\n this.id = \"\";\n this.fieldItemIds = [];\n }\n }\n}","import { SectionType } from \"./enums/section-type\";\nimport { SectionFieldModel } from \"./section-field-model\";\n\nexport class SectionModel {\n id: string | null;\n name: string | null;\n order: number | null;\n type: SectionType | null;\n fields: SectionFieldModel[];\n isEditable: boolean | null;\n isRemovable: boolean | null;\n isDeleted: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.order = x.order;\n this.type = x.type;\n this.fields = x.fields;\n this.isEditable = x.isEditable;\n this.isRemovable = x.isRemovable;\n this.isDeleted = x.isDeleted;\n } else {\n this.id = null;\n this.name = null;\n this.order = null;\n this.type = null;\n this.fields = [];\n this.isEditable = null;\n this.isRemovable = null;\n this.isDeleted = false;\n }\n }\n}","import { SectionType } from \"./enums/section-type\";\n\nexport class SectionUpdateRequest {\n establishmentAccountId?: string|null;\n id: string;\n type: SectionType;\n newName: string;\n newOrder: number;\n previousOrder: number | null;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.id = x.id;\n this.type = x.type;\n this.newName = x.newName;\n this.newOrder = x.newOrder;\n this.previousOrder = x.previousOrder;\n } else {\n this.establishmentAccountId = null;\n this.id = \"\";\n this.newName = \"\";\n this.type = SectionType.ClinicHistory;\n this.newOrder = 0;\n this.previousOrder = null;\n }\n }\n}","import { SectionType } from \"../models/enums/section-type\";\nimport { SectionCreateRequest } from \"../models/section-create-request\";\nimport { SectionDeleteRequest } from \"../models/section-delete-request\";\nimport { SectionFieldCreateRequest } from \"../models/section-field-create-request\";\nimport { SectionFieldCreateResponse } from \"../models/section-field-create-response\";\nimport { SectionFieldDeleteRequest } from \"../models/section-field-delete-request\";\nimport { SectionFieldUpdateOrderRequest } from \"../models/section-field-update-order-request\";\nimport { SectionFieldUpdateRequest } from \"../models/section-field-update-request\";\nimport { SectionFieldUpdateResponse } from \"../models/section-field-update-response\";\nimport { SectionModel } from \"../models/section-model\";\nimport { SectionUpdateRequest } from \"../models/section-update-request\";\nimport { ApiClient } from \"./api-client\";\nimport { CopyEstablishmentSettingsModel } from \"../models/copy-establishment-settings-model\";\n\nexport class SettingsPatientFormsService {\n private static baseUrl: string = \"/account\";\n private static sectionBaseUrl: string = \"/section\";\n private static sectionFieldBaseUrl: string = `${SettingsPatientFormsService.sectionBaseUrl}/sectionField`;\n\n static async getAccountSettingsTabSections(sectionType: SectionType, establishmentAccountId?: string | null): Promise<SectionModel[]> {\n const establishmentAccountIdRequestValue = establishmentAccountId === null || establishmentAccountId === undefined \n ? \"\" \n : establishmentAccountId;\n\n const data = await ApiClient.get(\n `${this.sectionBaseUrl}/GetAccountSettingsTabSections?TabType=${sectionType}${establishmentAccountIdRequestValue ? `&EstablishmentAccountId=${establishmentAccountIdRequestValue}` : ''}`\n );\n\n if (data)\n return data.sections.map(\n (item: SectionModel) => new SectionModel(item));\n else\n return [];\n }\n\n static async createSection(request: SectionCreateRequest): Promise<string | null> {\n const data = await ApiClient.post(`${this.sectionBaseUrl}/Create`, request);\n if (data)\n return data.id;\n else\n return null;\n }\n\n static async updateSection(request: SectionUpdateRequest): Promise<SectionUpdateRequest | null> {\n const data = await ApiClient.put(`${this.sectionBaseUrl}/Update`, request);\n if (data)\n return new SectionUpdateRequest(data);\n else\n return null;\n }\n\n static async deleteSection(request: SectionDeleteRequest): Promise<boolean> {\n const data = await ApiClient.remove(`${this.sectionBaseUrl}/Delete`, request);\n if (data)\n return true;\n else\n return false;\n }\n\n static async createSectionField(request: SectionFieldCreateRequest): Promise<SectionFieldCreateResponse | null> {\n const data = await ApiClient.post(this.sectionFieldBaseUrl, request);\n if (data)\n return new SectionFieldCreateResponse(data);\n else\n return null;\n }\n\n static async updateSectionField(request: SectionFieldUpdateRequest): Promise<SectionFieldUpdateResponse | null> {\n const data = await ApiClient.put(this.sectionFieldBaseUrl, request);\n if (data)\n return new SectionFieldUpdateResponse(data);\n else\n return null;\n }\n\n static async deleteSectionField(request: SectionFieldDeleteRequest): Promise<boolean> {\n const data = await ApiClient.remove(this.sectionFieldBaseUrl, request);\n if (data)\n return true;\n else\n return false;\n }\n\n static async reorderSectionFields(request: SectionFieldUpdateOrderRequest): Promise<boolean> {\n const data = await ApiClient.put(`${this.sectionFieldBaseUrl}/ReorderSectionFields`, request);\n return data;\n }\n \n static async copyPatientFormSetting(copyModel: CopyEstablishmentSettingsModel): Promise<boolean> {\n return await ApiClient.post(`${this.baseUrl}/copypatientformsetting`, copyModel).then(\n (data) => (data.succeeded)\n );\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n sectionNotes:{\n backgroundColor: theme.colors.clearLilac,\n borderRadius: 5,\n padding: \"20px 30px\",\n marginBottom: 32\n },\n sectionNotesTitle: {\n color: theme.colors.clearMain,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 700,\n wordWrap: \"break-word\"\n },\n sectionNotesDescription: {\n color: theme.colors.grey5,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 400,\n wordWrap: \"break-word\"\n },\n}));\n\nexport default useStyles;","export enum SectionNoteData {\n General = \"GeneralSectionNoteParam\",\n Communication = \"CommunicationSectionNoteParam\",\n WorkAreas = \"WorkAreasSectionNoteParam\",\n Services = \"ServicesSectionNoteParam\",\n Users = \"UsersSectionNoteParam\",\n Payments = \"PaymentsSectionNoteParam\",\n Commissions = \"CommissionsSectionNoteParam\",\n ClinicalHistory = \"ClinicalHistorySectionNoteParam\",\n EvolutionNotes = \"EvolutionNotesSectionNoteParam\",\n PatientForm = \"PatientFormSectionNoteParam\"\n}","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { SectionNoteProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function SectionNote(props: SectionNoteProps) {\n const { t } = useTranslation([\"general\"]);\n const { sectionData } = props;\n const classes = useStyles();\n\n function capitalizeSectionTitle(str: string) {\n if (!str) return \"\";\n return str.charAt(0).toUpperCase() + str.slice(1);\n }\n\n const title = capitalizeSectionTitle(t(sectionData));\n const body = t(sectionData);\n const article = t(`${sectionData}_Article`);\n\n return (\n <>\n <div className={classes.sectionNotes}>\n <div className={classes.sectionNotesTitle}>\n {t(\"SectionNoteTitleTemplate\", { title })}\n </div>\n <div className={classes.sectionNotesDescription}>\n {t(\"SectionNoteBodyTemplate\", { article, body })}\n </div>\n </div>\n </>\n );\n};\n","import React, { useEffect, useState } from 'react';\n\nimport { useTranslation } from \"react-i18next\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport { Typography } from '@material-ui/core';\n\nimport useStyles from \"./css\";\nimport UserList from \"../UserList\";\nimport UserModal from \"../UserModal\";\nimport { EditableItemProps } from \"../../../../../models/interfaces/editable-item-props\";\nimport { Url } from \"../../../../../constants/url\";\nimport { UserService } from \"../../../../../api/user-service\";\nimport { AccountService } from '../../../../../api/account-service';\nimport { UserEntity } from \"../../../../../models/user-entity\";\nimport { UserServicesInfo } from \"../../../../../models/user-services-info\";\nimport { UserScheduleInfo } from \"../../../../../models/user-schedule-info\";\nimport { WeekdayService } from \"../../../../../api/settings-weekdays-service\";\nimport { UserCommissionInfo } from \"../../../../../models/user-commission-info\";\nimport UserStatistic from '../UserStatistic/user-statistic';\nimport { SectionType } from '../../../../../models/enums/section-type';\nimport { SettingsPatientFormsService } from '../../../../../api/settings-patient-forms-service';\nimport { FieldAndValue } from '../../../../../models/field-and-value';\nimport SectionNote from '../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote';\nimport { SectionNoteData } from '../../../../../models/enums/section-note-data';\nimport ServicesService from '../../../../../api/settings-services-service';\nimport { SaveImageResponse } from '../../../../../models/save-image-response';\nimport ButtonWithSpinner from '../../../../common/ButtonWithSpinner';\nimport { ButtonPropsBorderRadius } from '../../../../../models/enums/button-props-border-radius';\n\n\nexport default function UsersMainPage(props: any) {\n\n const { settingsSelectedEstablishmentId } = props;\n const [isRefresh, setIsRefresh] = useState<any>();\n const [modalMode, setModalMode] = useState<EditableItemProps>({ mode: \"new\", itemId: null });\n const [openModal, setOpenModal] = useState<boolean>(false);\n\n const [user, setUser] = useState<UserEntity>(new UserEntity());\n const [oldUser, setOldUser] = useState<UserEntity>(new UserEntity());\n const [customUserSchedule, setCustomUserSchedule] = useState<UserScheduleInfo>();\n const [totalUsers, setTotalUsers] = useState<number>(0);\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const getUser = async (itemId: any) => {\n const response = await UserService.getUserById(itemId, settingsSelectedEstablishmentId);\n const user = new UserEntity(settingsSelectedEstablishmentId, response.general, response.schedule, response.services, response.commission, response.permissions, response.professionalInformation);\n const userCopy: UserEntity = JSON.parse(JSON.stringify(user))\n setUser(user);\n setOldUser(userCopy);\n };\n\n const handleOpenModal = async (itemId?: any) => {\n if (itemId) {\n await getUser(itemId);\n } else {\n const userProfessionalInfoFields = (await SettingsPatientFormsService.getAccountSettingsTabSections(SectionType.UserTreatment)).flatMap(sm => sm.fields);\n const userServices = await UserService.getUserServices(settingsSelectedEstablishmentId);\n const userCommissionsByServices = await UserService.getCommissionsByServices(settingsSelectedEstablishmentId);\n const accountCountryCode = await AccountService.getAccountCountryCode(settingsSelectedEstablishmentId);\n\n let userInfo;\n\n userInfo = {\n ...user,\n commission: user.commission?.commissionsByServices?.length ? user.commission : new UserCommissionInfo(userCommissionsByServices),\n services: user.services.serviceCategories.length === 0 ? new UserServicesInfo(userServices) : user.services,\n schedule: user.schedule ? user.schedule : new UserScheduleInfo([]),\n general: { ...user.general, mobileCodeIso3: accountCountryCode },\n professionalInformation: { ...user.professionalInformation, fieldsAndValues: userProfessionalInfoFields.map(f => new FieldAndValue({ field: f, value: null })) }\n };\n\n setUser(userInfo);\n }\n\n setOpenModal(true);\n };\n\n useEffect(() => {\n if (props.match.params?.userId) {\n setModalMode({ mode: \"edit\", itemId: props.match.params?.userId });\n handleOpenModal(props.match.params?.userId);\n }\n const fetchAccountSchedule = async () => {\n const result = await WeekdayService.getAccountWeekdaysAsUserSchedule(settingsSelectedEstablishmentId);\n return result;\n };\n fetchAccountSchedule().then(s => setCustomUserSchedule(s));\n }, [settingsSelectedEstablishmentId]);\n\n const handleCloseModal = () => {\n const title = document.title;\n window.history.pushState(\"\", title, `${Url.Settings.Users}`);\n setModalMode({ mode: \"new\", itemId: null });\n setOpenModal(false);\n };\n\n const handleUserEdit = async (userId: string) => {\n const title = document.title;\n window.history.pushState(\"\", title, `${Url.Settings.Users}/${userId}`);\n setModalMode({ mode: \"edit\", itemId: userId });\n await handleOpenModal(userId);\n };\n\n const handleUserInvited = async (user: UserEntity, signatureImage: File | null) => {\n const newUser = modalMode.mode === \"new\"\n ? await UserService.createUser(user, signatureImage, settingsSelectedEstablishmentId)\n .then(() => {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"User invited\"),\n description: `${user.general.name} ${user.general.lastName} (${user.general.jobPosition?.name}).`\n })\n );\n })\n .catch((e) => {\n console.log(e);\n })\n : await UserService.updateUser(user, signatureImage, settingsSelectedEstablishmentId)\n .then(() => {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"User modified\"),\n description: `${user.general.name} ${user.general.lastName} (${user.general.jobPosition?.name}).`\n })\n );\n })\n .catch((e) => {\n console.log(e);\n });\n\n setIsRefresh(user);\n };\n\n async function handleS3ImageSave(file: File) {\n const dataImg: SaveImageResponse = await ServicesService.saveImage(file);\n return dataImg;\n }\n\n const { t } = useTranslation([\"settings\"]);\n const classes = useStyles();\n\n return (\n <div>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.noteHeader}>\n <Typography className={classes.tabTitle}>\n {t(\"Users\")}\n </Typography>\n </div>\n <SectionNote \n sectionData={SectionNoteData.Users} \n />\n </>\n )}\n <div className={classes.header}>\n <UserStatistic totalUsers={totalUsers} />\n <div className={classes.root}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"Invite user\")}\n onClick={() => handleOpenModal()}\n />\n </div>\n </div>\n <UserList\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n isRefresh={isRefresh}\n onRowClick={handleUserEdit}\n setTotalUsers={setTotalUsers}\n />\n <UserModal\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n user={user}\n setUser={setUser}\n oldUser={oldUser}\n mode={modalMode.mode}\n itemId={modalMode.itemId}\n open={openModal}\n setOpen={setOpenModal}\n onClose={handleCloseModal}\n onCreate={handleUserInvited}\n customUserSchedule={customUserSchedule}\n handleS3ImageSave={handleS3ImageSave}\n />\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport {Color} from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {},\n section: {\n paddingBottom: 73\n },\n divArea: {\n backgroundColor: \"#fff\",\n borderRadius: 20,\n border: \"1px solid #dbdcdd\",\n padding: \"40px 40px 31px 40px\",\n margin: \"10px 0\"\n },\n title: {\n fontSize: \"14px\",\n color: theme.colors.grey5,\n marginBottom: 16,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n \"&:first-letter\": {\n textTransform: \"capitalize\"\n }\n },\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"block\",\n marginBottom: \"0.5rem\",\n },\n divider: {\n borderTop: \"1px solid\",\n borderColor: theme.colors.grey2,\n opacity: 0.3,\n marginTop: \"15px\",\n marginBottom: \"15px\",\n },\n notesTitle: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n notes: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n divRowWhats: {\n paddingTop: 5\n },\n divRowWhatsHeight60: {\n height: 60\n },\n divCheck: {\n display: \"inline-block\",\n width: 45,\n },\n divLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontSize: 14,\n fontWeight: 700,\n fontStyle: \"normal\",\n marginBottom: \"0.5rem\",\n display: \"inline-block\",\n },\n divSelect: {\n marginTop: \"-8px\"\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: theme.palette.common.white,\n \"& + .MuiSwitch-track\": {\n backgroundColor: \"#36ce91\",\n opacity: 1,\n border: \"none\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n //\n },\n \"&$focusVisible .MuiSwitch-thumb\": {\n color: \"#6462F3\",\n border: \"6px solid #fff\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n divNote: {\n marginTop: 20,\n fontFamily: 'Roboto',\n fontStyle: \"normal\",\n fontSize: 12,\n color: \"#5C6477\"\n },\n disabledSelect: {\n opacity: \"0.42\"\n },\n tinyMceOverrides: {\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n \"& iframe.tox-edit-area__iframe\": {\n backgroundColor: theme.colors.grey1 + \" !important\"\n },\n \"& div.tox-toolbar__primary\": {\n backgroundColor: theme.colors.grey1 + \" !important\"\n },\n \"& div.tox-sidebar-wrap\": {\n backgroundColor: theme.colors.grey1 + \" !important\"\n },\n \"& div.tox-edit-area\": {\n marginBottom: \"22px\"\n },\n position: \"relative\",\n margin: \"0px 0px 0px 43px\",\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n tinyMceInvalid: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: theme.colors.clearRed + \" !important\"\n }\n },\n resetTimeContainer: {\n display: \"inline-block\"\n },\n charCounter: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n position: \"absolute\",\n paddingLeft: \"10px\",\n marginTop: \"-23px\",\n color: theme.colors.grey5\n },\n saveInitialMessageButtonContainer: { \n position: \"relative\",\n top: -40,\n right: 5,\n float: \"right\",\n display: \"inline-block\",\n },\n saveCustomMessageButtonContainer: { \n position: \"relative\",\n top: -40,\n right: 5,\n float: \"right\",\n display: \"inline-block\",\n margin: \"1px -157px -33px 0px\"\n },\n saveCustomMessageText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n display: \"inline-block\"\n },\n whatsAppRequestQuotesDelay: {\n marginTop: 10,\n marginLeft: 43,\n \"& label\": {\n ...theme.typography.txtBody2,\n display: \"block\",\n color: theme.colors.grey5,\n fontSize: 12,\n fontWeight: 700,\n fontStyle: \"normal\",\n }\n },\n selectStyle: {\n color: Color.gray5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 200,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: Color.gray5,\n cursor: \"pointer\",\n },\n },\n selectHrs: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\"\n },\n },\n selectHrsClose: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n },\n },\n availabilityStatusSelectHrsClose: {\n \"& div:after\": {\n content: \"'hrs'\",\n color: \"rgba(0, 0, 0, 0.25)\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n },\n },\n initialMessage: {\n padding: 20,\n backgroundColor: theme.colors.grey1,\n borderRadius: 14,\n borderColor: theme.colors.grey2,\n borderWidth: 1,\n borderStyle: \"solid\",\n width: 730,\n \"& .tinyMceOverrides\": {\n \"& iframe.tox-edit-area__iframe\": {\n backgroundColor: \"white !important\"\n },\n \"& div.tox-toolbar__primary\": {\n backgroundColor: \"white !important\"\n },\n \"& div.tox-sidebar-wrap\": {\n backgroundColor: \"white !important\"\n },\n margin: 0,\n },\n \"& .saveCustomMessageButton\": {\n right: 162\n },\n \"& .staticText\": {\n marginBottom: 15,\n \"& p\": {\n margin: 0\n },\n \"& p:first-child\": {\n margin: \"10px 0 20px\"\n }\n },\n \"& .menuButton\": {\n borderRadius: 7,\n borderColor: theme.colors.grey2,\n borderWidth: 1,\n borderStyle: \"solid\",\n color: theme.colors.grey2,\n fontWeight: 700,\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n height: 32,\n \"& span\": {\n paddingBottom: 2\n }\n }\n },\n scheduleFollowUp: {\n width: 733,\n display: \"flex\",\n justifyContent: \"space-between\",\n \"&>div:first-child\": {\n display: \"flex\"\n }\n },\n resetAvailableStatus: {\n marginTop: 16,\n width: 745,\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"end\",\n \"&>div:first-child\": {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 9,\n \"& div\": {\n marginBottom: 0\n },\n \"& label\": {\n marginBottom: 0\n }\n }\n },\n showCancellationPoliciesDisabledBlock: {\n width: \"100%\",\n\n marginTop: 8,\n marginBottom: 8,\n\n paddingTop: 18,\n paddingRight: 18,\n paddingBottom: 18,\n paddingLeft: 18,\n\n backgroundColor: theme.colors.clearLilac,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n iconTooltipRoot: {\n\n display: \"inline-block\",\n marginLeft: 5,\n\n \"&>div\": {\n maxWidth: 220\n }\n },\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n}));\n\n","export enum FirstRemindBefore {\n OneDay = 24,\n TwoDays = 48,\n}","export enum SecondRemindBefore {\n OneHour = 1,\n TwoHours = 2,\n ThreeHours = 3\n}","export enum WhatsappFollowupSendTime {\n HalfHour = 1,\n OneHour = 2 ,\n TwoHours = 3,\n}","import { FirstRemindBefore } from \"./enums/first-remind-before\";\nimport { SecondRemindBefore } from \"./enums/second-remind-before\";\nimport {WhatsappFollowupSendTime} from \"./enums/whatsapp-followup-send-time\";\n\nexport class CustomerCommunication{\n accountId: string | null;\n notifyOnAppointmentCreated: boolean | null;\n notifyOnAppointmentModified: boolean | null;\n notifyOnAppointmentCanceled: boolean | null;\n firstReminderEnabled: boolean | null;\n secondReminderEnabled: boolean | null;\n firstRemindBefore: FirstRemindBefore | null;\n secondRemindBefore: SecondRemindBefore | null;\n customContactUsMessageEnabled: boolean | null;\n customContactUsMessage: string | null;\n showServicePricesInWhatsApp: boolean | null;\n showSpecialistNameInWhatsApp: boolean | null;\n scheduleWhatsAppFollowUpMessageEnabled: number | null;\n whatsAppFollowUpMessage: string | null;\n whatsAppFollowUpSendTime: WhatsappFollowupSendTime | null;\n whatsAppRequestQuotesEnabled: boolean | null;\n whatsAppRequestQuotesMessage: string | null;\n whatsAppRequestQuotesDelay: string | null;\n showCancellationPolicies: boolean;\n hasWhatsAppCancellationPoliciesOnAppointmentConfirmation: boolean;\n hasWhatsAppCancellationPoliciesOnAppointmentReminder: boolean;\n hasWhatsAppCancellationPoliciesOnAppointmentCancel: boolean;\n smbName: string;\n smbPhone: string | null;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.accountId = x.accountId;\n this.firstReminderEnabled = x.firstReminderEnabled;\n this.secondReminderEnabled = x.secondReminderEnabled;\n this.firstRemindBefore = x.firstRemindBefore;\n this.secondRemindBefore = x.secondRemindBefore;\n this.notifyOnAppointmentCreated = x.notifyOnAppointmentCreated;\n this.notifyOnAppointmentModified = x.notifyOnAppointmentModified;\n this.notifyOnAppointmentCanceled = x.notifyOnAppointmentCanceled;\n this.customContactUsMessageEnabled = x.customContactUsMessageEnabled;\n this.customContactUsMessage = x.customContactUsMessage;\n this.showServicePricesInWhatsApp = x.showServicePricesInWhatsApp;\n this.showSpecialistNameInWhatsApp = x.showSpecialistNameInWhatsApp;\n this.scheduleWhatsAppFollowUpMessageEnabled = x.scheduleWhatsAppFollowUpMessageEnabled;\n this.whatsAppFollowUpMessage = x.whatsAppFollowUpMessage;\n this.whatsAppFollowUpSendTime = x.whatsAppFollowUpSendTime;\n this.whatsAppRequestQuotesEnabled = x.whatsAppRequestQuotesEnabled;\n this.whatsAppRequestQuotesMessage = x.whatsAppRequestQuotesMessage;\n this.whatsAppRequestQuotesDelay = x.whatsAppRequestQuotesDelay;\n this.showCancellationPolicies = x.showCancellationPolicies;\n this.hasWhatsAppCancellationPoliciesOnAppointmentConfirmation = x.hasWhatsAppCancellationPoliciesOnAppointmentConfirmation;\n this.hasWhatsAppCancellationPoliciesOnAppointmentReminder = x.hasWhatsAppCancellationPoliciesOnAppointmentReminder;\n this.hasWhatsAppCancellationPoliciesOnAppointmentCancel = x.hasWhatsAppCancellationPoliciesOnAppointmentCancel;\n this.smbName = x.smbName;\n this.smbPhone = x.smbPhone;\n }\n else {\n this.accountId = null;\n this.firstReminderEnabled = null;\n this.secondReminderEnabled = null;\n this.firstRemindBefore = null;\n this.secondRemindBefore = null;\n this.notifyOnAppointmentCreated = null;\n this.notifyOnAppointmentModified = null;\n this.notifyOnAppointmentCanceled = null;\n this.customContactUsMessageEnabled = null;\n this.customContactUsMessage = null;\n this.showServicePricesInWhatsApp = null;\n this.showSpecialistNameInWhatsApp = null;\n this.scheduleWhatsAppFollowUpMessageEnabled = null;\n this.whatsAppFollowUpMessage = null;\n this.whatsAppFollowUpSendTime = null;\n this.whatsAppRequestQuotesEnabled = null;\n this.whatsAppRequestQuotesMessage = null;\n this.whatsAppRequestQuotesDelay = null;\n this.showCancellationPolicies = false;\n this.hasWhatsAppCancellationPoliciesOnAppointmentConfirmation = false;\n this.hasWhatsAppCancellationPoliciesOnAppointmentReminder = false;\n this.hasWhatsAppCancellationPoliciesOnAppointmentCancel = false;\n this.smbName = \"\";\n this.smbPhone = null;\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport { CustomerCommunication } from \"./../models/customer-communication\";\nimport {FileUploadResponse} from \"./../models/file-upload-response\"\n\nexport class CustomerCommunicationService {\n\n private static baseUrl: string = \"/account\";\n\n static updateCustomerCommunication(customerCommunication: CustomerCommunication): Promise<CustomerCommunication> {\n return ApiClient.post(`${this.baseUrl}/updatecustomercommunications`, customerCommunication)\n .then(data => new CustomerCommunication(data.customerCommunications)\n );\n }\n \n static async getCustomerCommunication(establishmentAccountId?: string): Promise<CustomerCommunication> {\n let endpoint = `${this.baseUrl}/getcustomercommunications`;\n if (establishmentAccountId)\n endpoint += `?AccountId=${establishmentAccountId}`;\n const data = await ApiClient.get(endpoint);\n return new CustomerCommunication(data.customerCommunications);\n }\n}","export class CustomerCommunicationWa {\n accountId: string | null;\n availabilityStatusResetTime: string | null;\n availabilityStatusResetEnabled: boolean | null;\n whatsAppInitialMessage: string | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.accountId = x.accountId;\n this.availabilityStatusResetTime = x.availabilityStatusResetTime;\n this.availabilityStatusResetEnabled = x.availabilityStatusResetEnabled;\n this.whatsAppInitialMessage = x.whatsAppInitialMessage;\n }\n else {\n this.accountId = null;\n this.availabilityStatusResetTime = null;\n this.availabilityStatusResetEnabled = null;\n this.whatsAppInitialMessage = null;\n }\n }\n}","import { Message } from \"./message\";\n\nexport class GetSpecificConversationMessagesResponse {\n currentPageNumber: number;\n messages: Message[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.currentPageNumber = x.currentPageNumber;\n this.messages = x.messages;\n }\n else {\n this.currentPageNumber = 1;\n this.messages = [];\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport { Message } from \"../models/message\";\nimport { ConversationPreviewsList } from \"../models/conversation-previews-list\";\nimport { ConversationPreview } from \"../models/conversation-preview\";\nimport { WhatsAppTemplate } from \"../models/whatsapp-template\";\nimport { WhatsAppTemplateType } from \"../models/enums/whatsapp-template-type\";\nimport { AvailabilityStatus } from \"../models/enums/availability-status\";\nimport { CustomerCommunicationWa } from \"../models/customer-communication-wa\";\nimport { GetSpecificConversationMessagesResponse } from \"../models/get-specific-conversation-messages-response\";\n\n\nexport class WhatsAppService {\n private static baseUrl: string = \"/whatsapp/api/Conversation\";\n private static accountUrl: string = \"/whatsapp/api/Account\";\n\n static getConversationsPreview(page: number, pagesize: number): Promise<ConversationPreviewsList> {\n return ApiClient.get(`${this.baseUrl}/GetConversationsPreviews?Page=${page}&Pagesize=${pagesize}`);\n }\n\n static getConversationsPreviewByEstablishments(page: number, pagesize: number, establishmentIds: string[] | undefined): Promise<ConversationPreviewsList> {\n let endpoint = `${this.baseUrl}/GetConversationsPreviewsForEstablishments?`;\n\n endpoint += Object.entries({\n Page: page,\n PageSize: pagesize,\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\")\n\n return ApiClient.get(endpoint);\n }\n\n static async getSearch(searchQuery: string, page: number, pagesize: number): Promise<ConversationPreview[]> {\n return await ApiClient\n .get(`${this.baseUrl}/GetSearch?SearchQueryString=${searchQuery}&Page=${page}&PageSize=${pagesize}`)\n .then((data) => data.conversationPreviews);\n }\n\n static async getSearchByEstablishments(searchQuery: string, page: number, pagesize: number, establishmentIds: string[] | undefined): Promise<ConversationPreview[]> {\n let endpoint = `${this.baseUrl}/GetSearchForEstablishments?`;\n\n endpoint += Object.entries({\n SearchQueryString: searchQuery,\n Page: page,\n PageSize: pagesize,\n EstablishmentIds: establishmentIds && establishmentIds.length > 0 ? establishmentIds : [],\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\")\n\n return await ApiClient\n .get(endpoint)\n .then((data) => data.conversationPreviews);\n }\n\n static async getSpecificConversationMessages(\n customerMobile: string,\n messagesOffset: number,\n establishmentId: string | null, \n pageNumber: number | null,\n targetMessageId: string | null): Promise<GetSpecificConversationMessagesResponse> {\n return await ApiClient.get(`${this.baseUrl}/GetSpecificConversationMessages?CustomerMobile=${customerMobile}&MessagesOffset=${messagesOffset}&establishmentId=${establishmentId ?? \"\"}&PageNumber=${pageNumber ?? \"\"}&TargetMessageId=${targetMessageId ?? \"\"}`)\n .then(\n (data) => new GetSpecificConversationMessagesResponse(data)\n );\n }\n\n static updateAvailabilityStatus(availabilityStatus: AvailabilityStatus): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/updateAvailabilityStatus`, { availabilityStatus })\n .then(\n (data) => data.IsAvailabilityStatusUpdated\n );\n }\n\n static markConversationAsRead(customerMobile: string): Promise<boolean> {\n return ApiClient.put(`${this.baseUrl}/MarkConversationAsRead?CustomerMobile=${customerMobile}`)\n .then(\n (data) => data.isMessagesUpdated\n );\n }\n\n static markConversationAsReadAsEstablishment(establishmentId: string, customerMobile: string): Promise<boolean> {\n return ApiClient.put(`${this.baseUrl}/MarkConversationAsReadAsEstablishment?CustomerMobile=${customerMobile}&EstablishmentId=${establishmentId}`)\n .then(\n (data) => data.isMessagesUpdated\n );\n }\n\n static sendTextMessage(customerId: string, customerMobile: string, text: string): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/SendTextMessage`, { customerId, customerMobile, text })\n .then(\n (data) => data.isSent\n );\n }\n\n static sendTextMessageAsEstablishment(customerId: string, establishmentId: string, customerMobile: string, text: string): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/SendTextMessageAsEstablishment`, { customerId, establishmentId, customerMobile, text })\n .then(\n (data) => data.isSent\n );\n }\n\n static scheduleFollowUp(customerId: string, customerMobile: string): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/ScheduleFollowUp`, { customerId, customerMobile })\n .then(\n (data) => data.isScheduled\n );\n }\n\n static sendMercadoPagoLink(customerId: string, customerName: string, customerMobile: string): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/SendMercadoPagoLink`, { customerId, customerName, customerMobile })\n .then(\n (data) => data.isSent\n );\n }\n\n static sendTemplate(customerId: string, customerName: string, customerMobile: string, templateType: WhatsAppTemplateType): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/SendTemplate`, { customerId, customerName, customerMobile, templateType })\n .then(\n (data) => data.isSent\n );\n }\n\n static async getCustomerCommunication(establishmentAccountId?: string): Promise<CustomerCommunicationWa> {\n let endpoint = `${this.accountUrl}/getcustomercommunications`;\n if (establishmentAccountId)\n endpoint += `?AccountId=${establishmentAccountId}`;\n const data = await ApiClient.get(endpoint);\n return new CustomerCommunicationWa(data.customerCommunications);\n }\n\n static async updateCustomerCommunication(model: CustomerCommunicationWa): Promise<CustomerCommunicationWa> {\n return ApiClient.post(`${this.accountUrl}/updatecustomercommunications`, model)\n .then(data => new CustomerCommunicationWa(data.customerCommunications)\n );\n }\n\n static getAvailableTemplates(customerId?: string): Promise<WhatsAppTemplate[]> {\n let url = `${this.baseUrl}/GetAvailableTemplates`;\n\n if (customerId) {\n url += `?CustomerId=${customerId}`;\n }\n\n return ApiClient\n .get(url)\n .then(\n (data) => data.availableTemplates\n );\n }\n \n static blockCustomer(customerId: string, customerMobile: string, isBlocked: boolean): Promise<boolean> {\n return ApiClient.post(`${this.baseUrl}/blockCustomer`, { customerId, customerMobile, isBlocked })\n .then(\n (data) => data.isBlocked\n );\n }\n}","import React, { useEffect, useState } from \"react\";\nimport { Box, Grid, Typography } from \"@material-ui/core\";\nimport { Button } from \"@material-ui/core\";\nimport { Editor } from \"@tinymce/tinymce-react\";\nimport { ArrowDropDownIcon, InfoIcon, ListIcon, SaveIcon } from \"./../../../../../assets/icons\"\nimport { useStyles } from \"./css\";\nimport { CustomerCommunicationService } from \"../../../../../api/settings-customer-communication-service\";\nimport { CustomerCommunication } from \"../../../../../models/customer-communication\";\nimport { Trans, useTranslation } from 'react-i18next';\nimport Switch from \"./../../../../common/Switch\";\nimport { FirstRemindBefore } from \"../../../../../models/enums/first-remind-before\";\nimport { SecondRemindBefore } from \"../../../../../models/enums/second-remind-before\";\nimport { SelectItem } from \"../../../../common/SelectWithLabel/props\";\nimport Select from \"../../../../common/Select\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport {WhatsappFollowupSendTime} from \"../../../../../models/enums/whatsapp-followup-send-time\";\nimport {TimePicker} from \"antd\";\nimport moment from \"moment/moment\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { WhatsAppService } from \"../../../../../api/whatsapp-service\";\nimport { CustomerCommunicationWa } from \"../../../../../models/customer-communication-wa\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport SectionNote from \"../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote\";\nimport { selectUserInfo } from \"../../../../../redux/store\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\nexport default (props: SettingsEnterpriseProps) => {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const defaultCustomerCommunication = new CustomerCommunication({\n notifyOnAppointmentCreated: true,\n notifyOnAppointmentModified: false,\n notifyOnAppointmentCanceled: false,\n firstReminderEnabled: true,\n secondReminderEnabled: false,\n firstRemindBefore: FirstRemindBefore.OneDay,\n secondRemindBefore: SecondRemindBefore.OneHour,\n customContactUsMessage: \"\",\n customContantUsMessageEnabled: false,\n showServicePricesInWhatsApp: true,\n showSpecialistNameInWhatsApp: false,\n showCancellationPolicies: false,\n hasWhatsAppCancellationPoliciesOnAppointmentConfirmation: false,\n hasWhatsAppCancellationPoliciesOnAppointmentReminder: false,\n hasWhatsAppCancellationPoliciesOnAppointmentCancel: false,\n });\n const defaultCustomerCommunicationWa = new CustomerCommunicationWa({\n availabilityStatusResetTime: \"23:59\",\n availabilityStatusResetEnabled: true\n });\n\n const { t } = useTranslation([\"general\"]);\n const [curCommunications, setCurCommunications] = useState<CustomerCommunication>(defaultCustomerCommunication);\n const [newCommunications, setNewCommunications] = useState<CustomerCommunication>(defaultCustomerCommunication);\n const [curWaCommunications, setCurWaCommunications] = useState<CustomerCommunicationWa>(defaultCustomerCommunicationWa);\n const [newWaCommunications, setNewWaCommunications] = useState<CustomerCommunicationWa>(defaultCustomerCommunicationWa);\n\n const maxInitialMessageTextLength: number = 800;\n const [initialMessageTextLength, setInitialMessageTextLength] = useState<number>(0);\n const [isInitialMessageTextChanged, setInitialMessageTextChanged] = useState<boolean>(false);\n const [initialMessageFocused, setInitialMessageFocused] = useState<boolean>(false);\n\n const maxTextLength: number = 1024;\n const [textLength, setTextLength] = useState<number>(0);\n const [isTextChanged, setTextChanged] = useState<boolean>(false);\n const [focused, setFocused] = useState<boolean>(false);\n\n const maxFollowUpTextLength: number = 1024;\n const [followUpTextLength, setFollowUpTextLength] = useState<number>(0);\n const [isFollowUpTextChanged, setFollowUpTextChanged] = useState<boolean>(false);\n const [followUpFocused, setFollowUpFocused] = useState<boolean>(false);\n const [savedWhatsAppFollowUpMessage, setSavedWhatsAppFollowUpMessage] = useState<string | null>(\"\");\n\n const maxRequestQuotesTextLength: number = 1024;\n const [requestQuotesTextLength, setRequestQuotesTextLength] = useState<number>(0);\n const [isRequestQuotesTextChanged, setRequestQuotesTextChanged] = useState<boolean>(false);\n const [requestQuotesFocused, setRequestQuotesFocused] = useState<boolean>(false);\n const [savedWhatsAppRequestQuotesMessage, setSavedWhatsAppRequestQuotesMessage] = useState<string | null>(\"\");\n const [isWhatsAppRequestQuotesDelayOpen, setIsWhatsAppRequestQuotesDelayOpen] = useState<boolean>(false);\n const [availabilityStatusResetTimeIsOpen, setAvailabilityStatusResetTimeIsOpen] = useState<boolean>(false);\n const [loadComplete, setLoadComplete] = useState<boolean>(false);\n\n const dispatch = useAppDispatch();\n\n const classes = useStyles();\n\n const timeFormat = \"HH:mm\";\n\n const userInfo = useAppSelector(selectUserInfo);\n const enterpriseSelected = userInfo.accountId === settingsSelectedEstablishmentId;\n\n useEffect(() => {\n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n const data = settingsSelectedEstablishmentId\n ? await CustomerCommunicationService.getCustomerCommunication(settingsSelectedEstablishmentId)\n : await CustomerCommunicationService.getCustomerCommunication();\n const waData = settingsSelectedEstablishmentId\n ? await WhatsAppService.getCustomerCommunication(settingsSelectedEstablishmentId)\n : await WhatsAppService.getCustomerCommunication();\n setCurCommunications(data);\n setCurWaCommunications(waData);\n dispatch(navbarActions.setShowLoader(false));\n setSavedWhatsAppFollowUpMessage(data.whatsAppFollowUpMessage === null\n ? getDefaultFollowUpMessage()\n : data.whatsAppFollowUpMessage);\n\n setSavedWhatsAppRequestQuotesMessage(data.whatsAppRequestQuotesMessage === null\n ? getDefaultRequestQuotesMessage()\n : data.whatsAppRequestQuotesMessage);\n setLoadComplete(true);\n })();\n }, [settingsSelectedEstablishmentId])\n\n useEffect(() => {\n if (curCommunications.firstReminderEnabled !== newCommunications.firstReminderEnabled ||\n curCommunications.secondReminderEnabled !== newCommunications.secondReminderEnabled ||\n curCommunications.firstRemindBefore !== newCommunications.firstRemindBefore ||\n curCommunications.secondRemindBefore !== newCommunications.secondRemindBefore ||\n curCommunications.notifyOnAppointmentCreated !== newCommunications.notifyOnAppointmentCreated ||\n curCommunications.notifyOnAppointmentModified !== newCommunications.notifyOnAppointmentModified ||\n curCommunications.notifyOnAppointmentCanceled !== newCommunications.notifyOnAppointmentCanceled ||\n curCommunications.customContactUsMessageEnabled !== newCommunications.customContactUsMessageEnabled ||\n curCommunications.showServicePricesInWhatsApp !== newCommunications.showServicePricesInWhatsApp ||\n curCommunications.showSpecialistNameInWhatsApp !== newCommunications.showSpecialistNameInWhatsApp ||\n curCommunications.scheduleWhatsAppFollowUpMessageEnabled !== newCommunications.scheduleWhatsAppFollowUpMessageEnabled ||\n curCommunications.whatsAppFollowUpMessage !== newCommunications.whatsAppFollowUpMessage ||\n curCommunications.whatsAppFollowUpSendTime !== newCommunications.whatsAppFollowUpSendTime ||\n curCommunications.whatsAppRequestQuotesEnabled !== newCommunications.whatsAppRequestQuotesEnabled ||\n curCommunications.whatsAppRequestQuotesMessage !== newCommunications.whatsAppRequestQuotesMessage ||\n curCommunications.whatsAppRequestQuotesDelay !== newCommunications.whatsAppRequestQuotesDelay ||\n curCommunications.hasWhatsAppCancellationPoliciesOnAppointmentConfirmation !== newCommunications.hasWhatsAppCancellationPoliciesOnAppointmentConfirmation ||\n curCommunications.hasWhatsAppCancellationPoliciesOnAppointmentReminder !== newCommunications.hasWhatsAppCancellationPoliciesOnAppointmentReminder ||\n curCommunications.hasWhatsAppCancellationPoliciesOnAppointmentCancel !== newCommunications.hasWhatsAppCancellationPoliciesOnAppointmentCancel) {\n (async () => await updateSettings(newCommunications))();\n }\n\n }, [newCommunications])\n\n useEffect(() => {\n if (curWaCommunications.availabilityStatusResetEnabled !== newWaCommunications.availabilityStatusResetEnabled ||\n curWaCommunications.availabilityStatusResetTime !== newWaCommunications.availabilityStatusResetTime) {\n (async () => await updateWaSettings(newWaCommunications))();\n }\n\n }, [newWaCommunications])\n\n const updateSettings = async (model: CustomerCommunication) => {\n if (model.customContactUsMessage === \"\")\n model.customContactUsMessage = null;\n model.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : null;\n const data = await CustomerCommunicationService.updateCustomerCommunication(model);\n setCurCommunications(data);\n };\n\n async function updateWaSettings(model: CustomerCommunicationWa) {\n if (model.whatsAppInitialMessage === \"\")\n model.whatsAppInitialMessage = null;\n model.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : null;\n const data = await WhatsAppService.updateCustomerCommunication(model);\n setCurWaCommunications(data);\n }\n\n const firstReminderSelectList: SelectItem[] = [\n { key: FirstRemindBefore.OneDay, value: FirstRemindBefore.OneDay + \" \" + t(\"hours before the appointment\") },\n { key: FirstRemindBefore.TwoDays, value: FirstRemindBefore.TwoDays + \" \" + t(\"hours before the appointment\") }];\n\n const secondReminderSelectList: SelectItem[] = [\n { key: SecondRemindBefore.OneHour, value: SecondRemindBefore.OneHour + \" \" + t(\"hour before the appointment\") },\n { key: SecondRemindBefore.TwoHours, value: SecondRemindBefore.TwoHours + \" \" + t(\"hours before the appointment\") },\n { key: SecondRemindBefore.ThreeHours, value: SecondRemindBefore.ThreeHours + \" \" + t(\"hours before the appointment\") }];\n\n const handleFirstReminderEnabledChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n firstReminderEnabled: event.target.checked\n })\n );\n };\n const handleSecondReminderEnabledChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n secondReminderEnabled: event.target.checked\n })\n );\n };\n const handleFirstRemindBeforeChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({ ...curCommunications, firstRemindBefore: event.target.value })\n );\n };\n const handleSecondRemindBeforeChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({ ...curCommunications, secondRemindBefore: event.target.value })\n );\n };\n const handleNotifyOnAppointmentCreatedChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n notifyOnAppointmentCreated: event.target.checked\n })\n );\n };\n const handleNotifyOnAppointmentModifiedChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n notifyOnAppointmentModified: event.target.checked\n })\n );\n };\n\n const handleNotifyOnAppointmentCanceledChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n notifyOnAppointmentCanceled: event.target.checked\n })\n );\n };\n\n const handleShowServicePricesInWhatsAppChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n showServicePricesInWhatsApp: event.target.checked\n })\n );\n };\n\n const handleShowSpecialistNameInWhatsAppChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n showSpecialistNameInWhatsApp: event.target.checked\n })\n );\n };\n\n const handleCustomContactUsMessageEnabledChanged = (event: any) => {\n const changedCommunicationEntity = new CustomerCommunication({\n ...curCommunications,\n customContactUsMessageEnabled: event.target.checked,\n });\n\n if (event.target.checked === false && curCommunications.customContactUsMessageEnabled === true)\n setNewCommunications(changedCommunicationEntity)\n else\n setCurCommunications(changedCommunicationEntity)\n };\n\n const handleInitialMessageChanged = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n if (contentText.length <= maxInitialMessageTextLength) {\n if (!isInitialMessageTextChanged && curWaCommunications.whatsAppInitialMessage !== contentHtml\n && !(curWaCommunications.whatsAppInitialMessage === null && contentHtml == getDefaultInitialMessage())) {\n setInitialMessageTextChanged(true);\n }\n setCurWaCommunications(\n new CustomerCommunicationWa({\n ...curWaCommunications,\n whatsAppInitialMessage: contentHtml\n })\n );\n setInitialMessageTextLength(contentText.length);\n }\n };\n\n const handleSaveInitialMessageButtonPressed = async () => {\n await updateWaSettings(curWaCommunications);\n setInitialMessageTextChanged(false);\n };\n\n const handleCustomContactUsMessageChanged = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n if (contentText.length <= maxTextLength) {\n if (!isTextChanged && curCommunications.customContactUsMessage !== contentHtml) {\n setTextChanged(true);\n }\n setCurCommunications(\n new CustomerCommunication({\n ...curCommunications,\n customContactUsMessage: contentHtml\n })\n );\n setTextLength(contentText.length);\n }\n };\n\n const handleSaveCustomContantUsSettingsButtonPressed = async () => {\n await updateSettings(curCommunications);\n setTextChanged(false);\n };\n\n const handleScheduleWhatsAppFollowUpMessageEnabledChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n scheduleWhatsAppFollowUpMessageEnabled: event.target.checked,\n whatsAppFollowUpMessage: savedWhatsAppFollowUpMessage\n })\n );\n };\n\n const handleWhatsAppFollowUpMessageChanged = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n if (contentText.length <= maxFollowUpTextLength) {\n const contentHtml = editor.getContent();\n setCurCommunications(\n new CustomerCommunication({\n ...curCommunications,\n whatsAppFollowUpMessage: contentHtml\n })\n );\n setFollowUpTextChanged(savedWhatsAppFollowUpMessage !== contentHtml);\n setFollowUpTextLength(contentText.length);\n }\n };\n\n const whatsAppFollowUpSendTimeSelectList: SelectItem[] = [\n { key: WhatsappFollowupSendTime.HalfHour, value: t(\"30 minutes later\") },\n { key: WhatsappFollowupSendTime.OneHour, value: t(\"1 hour later\") },\n { key: WhatsappFollowupSendTime.TwoHours, value: t(\"2 hours later\") }];\n\n const handleWhatsAppFollowUpSendTimeChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({ ...curCommunications, whatsAppFollowUpSendTime: event.target.value })\n );\n };\n\n const handleSaveWhatsAppFollowUpMessageButtonPressed = async () => {\n await updateSettings(curCommunications);\n setSavedWhatsAppFollowUpMessage(curCommunications.whatsAppFollowUpMessage);\n setFollowUpTextChanged(false);\n };\n\n const handleWhatsAppRequestQuotesEnabledChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n whatsAppRequestQuotesEnabled: event.target.checked,\n whatsAppRequestQuotesMessage: savedWhatsAppRequestQuotesMessage\n })\n );\n };\n\n function handleAvailabilityStatusResetEnabledOnChange(event: any) {\n setNewWaCommunications(\n new CustomerCommunicationWa({\n ...curWaCommunications,\n availabilityStatusResetEnabled: event.target.checked,\n })\n );\n }\n\n function handleAvailabilityStatusResetTimeOnChange(time: any) {\n setNewWaCommunications(\n new CustomerCommunicationWa({\n ...curWaCommunications,\n availabilityStatusResetTime: time,\n })\n );\n }\n\n const handleWhatsAppRequestQuotesMessageChanged = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n if (contentText.length <= maxRequestQuotesTextLength) {\n const contentHtml = editor.getContent();\n setCurCommunications(\n new CustomerCommunication({\n ...curCommunications,\n whatsAppRequestQuotesMessage: contentHtml\n })\n );\n setRequestQuotesTextChanged(savedWhatsAppRequestQuotesMessage !== contentHtml);\n setRequestQuotesTextLength(contentText.length);\n }\n };\n\n const handleWhatsAppRequestQuotesDelayChanged = (event: any) => {\n setNewCommunications(\n new CustomerCommunication({ ...curCommunications, whatsAppRequestQuotesDelay: event })\n );\n };\n\n const handleSaveWhatsAppRequestQuotesMessageButtonPressed = async () => {\n await updateSettings(curCommunications);\n setSavedWhatsAppRequestQuotesMessage(curCommunications.whatsAppRequestQuotesMessage);\n setRequestQuotesTextChanged(false);\n };\n\n function handleWhatsAppCancellationPoliciesOnAppointmentConfirmation(event: any) {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n hasWhatsAppCancellationPoliciesOnAppointmentConfirmation: event.target.checked,\n })\n );\n }\n\n function handleWhatsAppCancellationPoliciesOnAppointmentReminder(event: any) {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n hasWhatsAppCancellationPoliciesOnAppointmentReminder: event.target.checked,\n })\n );\n }\n\n function handleWhatsAppCancellationPoliciesOnAppointmentCancel(event: any) {\n setNewCommunications(\n new CustomerCommunication({\n ...curCommunications,\n hasWhatsAppCancellationPoliciesOnAppointmentCancel: event.target.checked,\n })\n );\n }\n\n const setInitialMessageLength = (evt: any, editor: any) => {\n setInitialMessageTextLength(editor.getContent({ format: \"text\" }).length);\n };\n\n const setLength = (evt: any, editor: any) => {\n setTextLength(editor.getContent({ format: \"text\" }).length);\n };\n\n const setFollowUpLength = (evt: any, editor: any) => {\n setFollowUpTextLength(editor.getContent({ format: \"text\" }).length);\n };\n\n const setRequestQuotesLength = (evt: any, editor: any) => {\n setRequestQuotesTextLength(editor.getContent({ format: \"text\" }).length);\n };\n\n const getBorderStyle = () => {\n if (textLength === 0) {\n return classes.tinyMceInvalid;\n }\n else {\n return focused ? classes.tinyMceFocused : classes.tinyMceUnfocused\n }\n }\n\n const getInitialMessageBorderStyle = () => {\n if (initialMessageTextLength === 0) {\n return classes.tinyMceInvalid;\n }\n else {\n return initialMessageFocused ? classes.tinyMceFocused : classes.tinyMceUnfocused\n }\n }\n\n const getFollowUpBorderStyle = () => {\n if (followUpTextLength === 0 || isFollowUpTextChanged) {\n return classes.tinyMceInvalid;\n }\n else {\n return followUpFocused ? classes.tinyMceFocused : classes.tinyMceUnfocused\n }\n }\n\n const getRequestQuotesBorderStyle = () => {\n if (requestQuotesTextLength === 0 || isRequestQuotesTextChanged) {\n return classes.tinyMceInvalid;\n }\n else {\n return requestQuotesFocused ? classes.tinyMceFocused : classes.tinyMceUnfocused\n }\n }\n\n const getDefaultInitialMessage = () => {\n return t(\"default_initial_message_template\").replace(\"{{0}}\", curCommunications.smbName)\n }\n\n const getDefaultMessage = () => {\n return t(\"default_custom_send_us_a_message_template\") + curCommunications.smbPhone + \"</b>.</p>\"\n }\n\n const getDefaultFollowUpMessage = () => {\n return t(\"default_whatsapp_followup_a_message_template\")\n }\n\n const getDefaultRequestQuotesMessage = () => {\n return t(\"default_whatsapp_request_quotes_message_template\")\n }\n\n\n return (\n <>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Communication with the customer\")}\n </Typography>\n </div>\n <SectionNote\n sectionData={SectionNoteData.Communication}\n />\n </>\n )}\n <div className={classes.section}>\n <div>\n <Typography className={classes.title}>\n {t('WhatsApp Chatbot terms')}\n </Typography>\n </div>\n <Box className={classes.divArea}>\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.root}>\n <label className={classes.label}>\n {useCustomerTerminology(t('Initial message that is sent when the customer contacts the WhatsApp Chatbot'), 'customer')}\n </label>\n {!loadComplete ? <></> :\n <div className={classes.initialMessage}>\n <div\n className={`${classes.tinyMceOverrides} ${getInitialMessageBorderStyle()} tinyMceOverrides`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n menubar: false,\n statusbar: false,\n plugins: 'wordcount paste',\n toolbar: 'bold italic strikethrough',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n strikethrough: { inline: 's' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n forced_root_block: false,\n setup: (editor) => {\n editor.on(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \"Tab\") {\n e.preventDefault();\n e.stopPropagation();\n return false;\n }\n });\n }\n }}\n value={curWaCommunications?.whatsAppInitialMessage === null || curWaCommunications.whatsAppInitialMessage === null\n ? getDefaultInitialMessage()\n : curWaCommunications?.whatsAppInitialMessage}\n onFocusIn={() => setInitialMessageFocused(true)}\n onFocusOut={() => setInitialMessageFocused(false)}\n onEditorChange={handleInitialMessageChanged}\n outputFormat=\"html\"\n onChange={(e) => {\n if (initialMessageTextLength >= maxInitialMessageTextLength) {\n e.preventDefault();\n }\n }}\n onInit={setInitialMessageLength}\n />\n <span\n className={classes.charCounter}>{initialMessageTextLength + \"/\" + maxInitialMessageTextLength}</span>\n </div>\n <div className={classes.saveInitialMessageButtonContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Gray1}\n innerText={t(\"Save\")}\n innerIcon={<SaveIcon\n style={{ width: 16, height: 16 }}\n viewBox=\"0 0 16 16\"\n />}\n onClick={handleSaveInitialMessageButtonPressed}\n disabled={!isInitialMessageTextChanged || initialMessageTextLength >= maxInitialMessageTextLength || initialMessageTextLength === 0}\n />\n </div>\n <div className={\"staticText\"}>\n <p>\n <b>{t(\"Type the number\")}</b> {t(\"of the option you would like to more about.\")}\n </p>\n <p>{t(\"Type 0 if you want to schedule an appointment.\")}</p>\n <p>{t(\"Type 1 if you want personalized attention.\")}</p>\n </div>\n <div className={\"menuButton\"}>\n <ListIcon/>\n <span>{t(\"Menu\")}</span>\n </div>\n </div>\n }\n </div>\n </Grid>\n </Grid>\n <hr className={classes.divider} />\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.root}>\n <>\n <div className={classes.divRowWhats}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.customContactUsMessageEnabled ?? false}\n onChange={handleCustomContactUsMessageEnabledChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Customized Chatbot message for the “I want to chat with someone” option\")}\n </label>\n </div>\n </div>\n {!curCommunications?.customContactUsMessageEnabled ?\n <></> :\n <div>\n <div className={`${classes.tinyMceOverrides} ${getBorderStyle()}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: 690,\n menubar: false,\n statusbar: false,\n plugins: 'wordcount paste',\n toolbar: 'bold italic strikethrough',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n strikethrough: { inline: 's' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n forced_root_block: false,\n setup: (editor) => {\n editor.on(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \"Tab\") {\n e.preventDefault();\n e.stopPropagation();\n return false;\n }\n });\n }\n }}\n value={curCommunications?.customContactUsMessage === null || curCommunications.customContactUsMessage === null\n ? getDefaultMessage()\n : curCommunications?.customContactUsMessage}\n onFocusIn={() => setFocused(true)}\n onFocusOut={() => setFocused(false)}\n onInit={setLength}\n onEditorChange={handleCustomContactUsMessageChanged}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLength >= maxTextLength) {\n e.preventDefault();\n }\n }}\n />\n <span className={classes.charCounter}>{textLength + \"/\" + maxTextLength}</span>\n </div>\n <div className={classes.saveCustomMessageButtonContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Gray1}\n innerText={t(\"Save\")}\n innerIcon={<SaveIcon\n style={{ width: 16, height: 16 }}\n viewBox=\"0 0 16 16\"\n />}\n onClick={handleSaveCustomContantUsSettingsButtonPressed}\n disabled={!isTextChanged || textLength >= maxTextLength || textLength === 0}\n />\n </div>\n </div>\n }\n </>\n </div>\n </Grid>\n </Grid>\n <hr className={classes.divider} />\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.root}>\n <>\n <div className={classes.divRowWhats}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.whatsAppRequestQuotesEnabled ?? false}\n onChange={handleWhatsAppRequestQuotesEnabledChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Allow to request quotes from the WhatsApp Chatbot\")}\n </label>\n </div>\n </div>\n {!curCommunications?.whatsAppRequestQuotesEnabled ?\n <></> :\n <>\n <div className={`${classes.tinyMceOverrides} ${getRequestQuotesBorderStyle()}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: 690,\n menubar: false,\n statusbar: false,\n plugins: 'wordcount paste',\n toolbar: 'bold italic underline',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n strikethrough: { inline: 's' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n forced_root_block: false,\n setup: (editor) => {\n editor.on(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \"Tab\") {\n e.preventDefault();\n e.stopPropagation();\n return false;\n }\n });\n }\n }}\n value={curCommunications?.whatsAppRequestQuotesMessage === null\n ? getDefaultRequestQuotesMessage()\n : curCommunications?.whatsAppRequestQuotesMessage}\n onFocusIn={() => setRequestQuotesFocused(true)}\n onFocusOut={() => setRequestQuotesFocused(false)}\n onInit={setRequestQuotesLength}\n onEditorChange={handleWhatsAppRequestQuotesMessageChanged}\n outputFormat=\"html\"\n onChange={(e) => {\n if (requestQuotesTextLength >= maxRequestQuotesTextLength) {\n e.preventDefault();\n }\n }}\n />\n <span className={classes.charCounter}>{requestQuotesTextLength + \"/\" + maxRequestQuotesTextLength}</span>\n </div>\n <div className={classes.saveCustomMessageButtonContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Gray1}\n innerText={t(\"Save\")}\n innerIcon={<SaveIcon\n style={{ width: 16, height: 16 }}\n viewBox=\"0 0 16 16\"\n />}\n onClick={handleSaveWhatsAppRequestQuotesMessageButtonPressed}\n disabled={!isRequestQuotesTextChanged || requestQuotesTextLength > maxRequestQuotesTextLength || requestQuotesTextLength === 0}\n />\n </div>\n\n <div className={classes.whatsAppRequestQuotesDelay}>\n <label>\n {t(\"Notify me estimate pending in\")}\n </label>\n <TimePicker\n key={`opening_whatsAppRequestQuotesDelay`}\n onOk={(time) => {handleWhatsAppRequestQuotesDelayChanged(moment.duration(time.format(timeFormat)).asMinutes())}}\n className={`${classes.selectStyle} ${\n isWhatsAppRequestQuotesDelayOpen ? classes.selectHrs : classes.selectHrsClose\n }`}\n placeholder=\"Opened\"\n inputReadOnly={true}\n showNow={false}\n value={moment().startOf(\"day\").add(curCommunications?.whatsAppRequestQuotesDelay, \"minutes\")}\n onOpenChange={setIsWhatsAppRequestQuotesDelayOpen}\n format={timeFormat}\n />\n <ArrowDropDownIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: isWhatsAppRequestQuotesDelayOpen ? \"#5C6477\" : \"#CCC\",\n position: \"relative\",\n transform: isWhatsAppRequestQuotesDelayOpen\n ? \"rotate(180deg)\"\n : \"rotate(0deg)\",\n }}\n />\n </div>\n </>\n }\n </>\n </div>\n </Grid>\n </Grid>\n </Box>\n </div>\n <div className={classes.section}>\n <div>\n <Typography className={classes.title}>\n {t('Conversations')}\n </Typography>\n </div>\n <Box className={classes.divArea}>\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.root}>\n <>\n <div className={`${classes.divRowWhats} ${classes.scheduleFollowUp}`}>\n <div>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.scheduleWhatsAppFollowUpMessageEnabled ?? false}\n onChange={handleScheduleWhatsAppFollowUpMessageEnabledChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel} style={{flexBasis:\"fit-content\", paddingRight: 10}}>\n <label>\n {useCustomerTerminology(t('Schedule follow-up message when customer has not responded to a conversation'), 'customer')}\n </label>\n </div>\n </div>\n <div className={`${classes.divSelect} ${curCommunications?.scheduleWhatsAppFollowUpMessageEnabled ? \"\" : classes.disabledSelect}`}>\n <Select\n key={\"whatsAppFollowUpSendTime\"}\n width={230}\n placeholder={t(\"Send time\")}\n value={curCommunications?.whatsAppFollowUpSendTime}\n onChange={handleWhatsAppFollowUpSendTimeChanged}\n colorArrowIcon={\"#5C6477\"}\n items={whatsAppFollowUpSendTimeSelectList}\n disabled={!curCommunications.scheduleWhatsAppFollowUpMessageEnabled} />\n </div>\n </div>\n {!curCommunications?.scheduleWhatsAppFollowUpMessageEnabled ?\n <></> :\n <>\n <div className={`${classes.tinyMceOverrides} ${getFollowUpBorderStyle()}`} style={{ marginTop: 10 }}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: 690,\n menubar: false,\n statusbar: false,\n plugins: 'wordcount paste',\n toolbar: 'bold italic underline',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n strikethrough: { inline: 's' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n forced_root_block: false,\n setup: (editor) => {\n editor.on(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \"Tab\") {\n e.preventDefault();\n e.stopPropagation();\n return false;\n }\n });\n }\n }}\n value={curCommunications?.whatsAppFollowUpMessage === null\n ? getDefaultFollowUpMessage()\n : curCommunications?.whatsAppFollowUpMessage}\n onFocusIn={() => setFollowUpFocused(true)}\n onFocusOut={() => setFollowUpFocused(false)}\n onInit={setFollowUpLength}\n onEditorChange={handleWhatsAppFollowUpMessageChanged}\n outputFormat=\"html\"\n onChange={(e) => {\n if (followUpTextLength >= maxFollowUpTextLength) {\n e.preventDefault();\n }\n }}\n />\n <span className={classes.charCounter}>{followUpTextLength + \"/\" + maxFollowUpTextLength}</span>\n </div>\n <div className={classes.saveCustomMessageButtonContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n hoverColor={ButtonPropsColor.Gray1}\n innerText={t(\"Save\")}\n innerIcon={<SaveIcon\n style={{ width: 16, height: 16 }}\n viewBox=\"0 0 16 16\"\n />}\n onClick={handleSaveWhatsAppFollowUpMessageButtonPressed}\n disabled={!isFollowUpTextChanged || followUpTextLength > maxFollowUpTextLength || followUpTextLength === 0}\n />\n </div>\n </>\n }\n </>\n <div className={`${classes.divRowWhats} ${classes.resetAvailableStatus}`}>\n <div>\n <div className={classes.divCheck}>\n <Switch\n value={curWaCommunications?.availabilityStatusResetEnabled ?? true}\n onChange={handleAvailabilityStatusResetEnabledOnChange}\n disabled={true}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label>\n {t(\"Reset \\\"Available\\\" status to \\\"Away\\\" to reply in WhatsApp\")}\n </label>\n </div>\n </div>\n <div className={classes.resetTimeContainer}>\n <label className={classes.label}>\n {t(\"Reset time\")}\n </label>\n <TimePicker\n onOk={(time) => {\n handleAvailabilityStatusResetTimeOnChange(time.format(timeFormat));\n }}\n className={`${classes.selectStyle} ${curWaCommunications.availabilityStatusResetEnabled\n ? classes.selectHrs\n : classes.availabilityStatusSelectHrsClose\n }`}\n inputReadOnly={true}\n showNow={false}\n value={moment(curWaCommunications.availabilityStatusResetTime, timeFormat)}\n disabled={!curWaCommunications.availabilityStatusResetEnabled}\n onOpenChange={(e) =>\n setAvailabilityStatusResetTimeIsOpen(e)\n }\n format={timeFormat}\n />\n <ArrowDropDownIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: curWaCommunications.availabilityStatusResetEnabled ? \"#5C6477\" : \"#CCC\",\n position: \"relative\",\n transform: availabilityStatusResetTimeIsOpen\n ? \"rotate(180deg)\"\n : \"rotate(0deg)\",\n }}\n />\n </div>\n </div>\n </div>\n </Grid>\n </Grid>\n </Box>\n </div>\n <div className={classes.section}>\n <div>\n <Typography className={classes.title}>\n {useCustomerTerminology(t('Customer notifications by WhatsApp'), 'customer')}\n </Typography>\n </div>\n <Box className={classes.divArea}>\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.root}>\n <label className={classes.label}>\n {t(\"Notification to:\")}\n </label>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.notifyOnAppointmentCreated}\n onChange={handleNotifyOnAppointmentCreatedChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Create appointment\")}\n </label>\n </div>\n </div>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.notifyOnAppointmentModified}\n onChange={handleNotifyOnAppointmentModifiedChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Modify appointment\")}\n </label>\n </div>\n </div>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.notifyOnAppointmentCanceled}\n onChange={handleNotifyOnAppointmentCanceledChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Cancel appointment\")}\n </label>\n </div>\n </div>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.firstReminderEnabled}\n onChange={handleFirstReminderEnabledChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"First appointment reminder\")}\n </label>\n </div>\n </Grid>\n <Grid item xs={6} className={`${classes.divSelect} ${curCommunications?.firstReminderEnabled ? \"\" : classes.disabledSelect}`}>\n <Select\n key={\"firstReminder\"}\n width={230}\n placeholder={t(\"Hours before the appointment\")}\n value={curCommunications?.firstRemindBefore}\n onChange={handleFirstRemindBeforeChanged}\n colorArrowIcon={\"#5C6477\"}\n items={firstReminderSelectList}\n disabled={!curCommunications.firstReminderEnabled} />\n </Grid>\n </Grid>\n </div>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <Grid container>\n <Grid item xs={6}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.secondReminderEnabled}\n onChange={handleSecondReminderEnabledChanged}\n baseClass={classes.switchBase} />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Second appointment reminder\")}\n </label>\n </div>\n </Grid>\n <Grid item xs={6} className={`${classes.divSelect} ${curCommunications?.secondReminderEnabled ? \"\" : classes.disabledSelect}`}>\n <Select\n key={\"secondReminder\"}\n width={230}\n placeholder={t(\"Hours before the appointment\")}\n value={curCommunications?.secondRemindBefore}\n onChange={handleSecondRemindBeforeChanged}\n colorArrowIcon={\"#5C6477\"}\n items={secondReminderSelectList}\n disabled={!curCommunications.secondReminderEnabled} />\n </Grid>\n </Grid>\n </div>\n\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.showServicePricesInWhatsApp}\n onChange={handleShowServicePricesInWhatsAppChanged}\n baseClass={classes.switchBase}\n />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Show prices of my services in WhatsApp messages\")}\n </label>\n </div>\n </div>\n\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications?.showSpecialistNameInWhatsApp}\n onChange={handleShowSpecialistNameInWhatsAppChanged}\n baseClass={classes.switchBase}\n />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Show specialist responsible for the appointment in WhatsApp messages\")}\n </label>\n </div>\n </div>\n\n\n <label className={classes.label}>\n {t(\"Send additional messages with cancellation policies:\")}\n </label>\n </div>\n </Grid>\n <Grid item xs={12}>\n <div className={classes.showCancellationPoliciesDisabledBlock}>\n <Trans i18nKey=\"ShowCancellationPoliciesMustBeTurnedOn\" t={t} />\n </div>\n </Grid>\n <Grid item xs={12} />\n <Grid container xs={6}>\n <div className={classes.root}>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications.hasWhatsAppCancellationPoliciesOnAppointmentConfirmation}\n onChange={handleWhatsAppCancellationPoliciesOnAppointmentConfirmation}\n baseClass={classes.switchBase}\n disabled={!curCommunications.showCancellationPolicies}\n />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Appointment confirmation\")}\n </label>\n </div>\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 1 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Send cancellation policies when creating the appointment\")}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n classNameRoot={classes.iconTooltipRoot}\n />\n </div>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications.hasWhatsAppCancellationPoliciesOnAppointmentReminder}\n onChange={handleWhatsAppCancellationPoliciesOnAppointmentReminder}\n baseClass={classes.switchBase}\n disabled={!curCommunications.showCancellationPolicies}\n />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Appointment reminder\")}\n </label>\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 1 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Send cancellation policies in the first appointment reminder\")}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n classNameRoot={classes.iconTooltipRoot}\n />\n </div>\n </div>\n <div className={`${classes.divRowWhats} ${classes.divRowWhatsHeight60}`}>\n <div className={classes.divCheck}>\n <Switch\n value={curCommunications.hasWhatsAppCancellationPoliciesOnAppointmentCancel}\n onChange={handleWhatsAppCancellationPoliciesOnAppointmentCancel}\n baseClass={classes.switchBase}\n disabled={!curCommunications.showCancellationPolicies}\n />\n </div>\n <div className={classes.divLabel}>\n <label >\n {t(\"Appointment cancellation\")}\n </label>\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 1 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Send the cancellation policies when canceling the appointment\")}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n classNameRoot={classes.iconTooltipRoot}\n />\n </div>\n </div>\n </div>\n </Grid>\n </Grid>\n </Box>\n </div>\n </>\n )\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n button: {\n width: 32,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\"\n },\n iconTrash: {\n fill: Color.gray5\n },\n btnNewWorkArea: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n },\n icon: {\n paddingTop: 5,\n height: 30,\n width: 30,\n fontWeight: \"bold\"\n },\n classRow: {\n cursor: \"pointer\",\n \"& button\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n \"& button\": {\n visibility: \"visible\"\n }\n }\n },\n classHead: {\n color: theme.colors.grey5,\n textAlign: \"left\"\n },\n classCell: {\n color: theme.colors.grey5,\n },\n}));\n\n\nexport default useStyles;\n","import WorkareasGrid from \"./work-area-grid\";\nexport default WorkareasGrid;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from 'react-i18next';\nimport { TrashIcon } from \"../../../../../assets/icons\";\nimport GridList, { OnChangeEvent } from \"../../../../common/grid/GridList\";\nimport { TableColumn } from \"../../../../common/grid/table-column\";\nimport { Button } from \"@material-ui/core\";\n\nimport EntityService from \"../../../../../api/settings-workareas-service\";\nimport Workarea from \"../../../../../models/workarea\";\nimport { ListProps } from \"./props\";\n\nimport { Color } from \"../../../../../constants/colors\";\nimport useStyles from \"./css\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\n\n\nconst WorkareasGrid = (props: ListProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const { settingsSelectedEstablishmentId, isRefresh, item, openItemEditModal, openDeleteModal, setTotalRecords } = props;\n\n const [entityList, setEntityList] = useState<Workarea[]>([]);\n const [total, setTotal] = useState<number>(0);\n\n const [page, setPage] = useState<number>(1);\n const pageSize: number = 20;\n const [order, setOrder] = useState<\"asc\" | \"desc\">(\"asc\");\n const [orderBy, setOrderBy] = useState<string>(\"name\");\n\n useEffect(() => {\n\n (async () => {\n await loadData();\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [page, orderBy, order, isRefresh, settingsSelectedEstablishmentId]);\n\n\n\n useEffect(() => {\n\n if (item) {\n const newList = [item].concat(entityList);\n setEntityList(newList);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [item]);\n\n\n \n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const data = await EntityService.getWorkareas(\n page,\n pageSize,\n settingsSelectedEstablishmentId,\n order,\n orderBy\n );\n dispatch(navbarActions.setShowLoader(false));\n setEntityList(data.entity || []);\n setTotal(data.total || 0);\n if (setTotalRecords) setTotalRecords(data.total || 0);\n };\n\n const columns: TableColumn[] = [\n {\n id: \"name\",\n label: t('NAME'),\n sorting: true,\n width: 200,\n },\n {\n id: \"category\",\n label: t('CATEGORY'),\n sorting: true,\n width: 200,\n },\n {\n id: \"description\",\n label: t('DESCRIPTION'),\n sorting: false,\n width: 340,\n },\n {\n id: \"id\",\n label: \"\",\n sorting: false,\n completeObject: true,\n component: (item: any) => <Button className={classes.button} onClick={(e) => { e.stopPropagation(); handleOnDeleteBtnClick(item); } } >\n <TrashIcon style={{color: Color.gray4, width: 13, height: 17, }} />\n </Button>,\n width: 50,\n headerTextAlign: \"center\",\n textAlign: \"center\",\n },\n ];\n\n const handleOnChangeGrid = (event: OnChangeEvent) => {\n setPage(event.page);\n if (event.sorting) {\n setOrder(event.sorting.direction);\n setOrderBy(\n event.sorting.orderBy\n );\n }\n };\n\n const handleOnRowClick = (item: Workarea, showModal: boolean) => {\n if (typeof openItemEditModal === \"function\") {\n openItemEditModal(item);\n }\n };\n\n\n const handleOnDeleteBtnClick = (item: any) => {\n if (typeof openDeleteModal === \"function\") {\n openDeleteModal(item);\n }\n };\n\n return (\n <GridList\n columns={columns}\n items={entityList}\n totalItems={total}\n pageSize={pageSize}\n onChange={handleOnChangeGrid}\n onRowClick={(e) => handleOnRowClick(e, true)}\n classRow={classes.classRow}\n />\n );\n};\n\nexport default WorkareasGrid;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n title: {\n fontFamily: \"Roboto\",\n fontSize: \"12px\",\n color: \"#919CA5\",\n margin: 0,\n },\n required: {\n color: \"#6462F3\",\n },\n optional: {\n fontWeight: \"normal\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n switchBox: {\n marginTop: 24,\n marginLeft: 11\n },\n label: {\n display: \"flex\",\n margin: 0,\n color: \"#4a4d51\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n },\n description: {\n margin: 0,\n color: \"#919CA5\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n },\n rowDescription: {\n position: \"relative\",\n zIndex: 1,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 399,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n}));\n\nexport default useStyles;\n","export default class Category {\n accountId?: string | null;\n id?: string | null;\n name: string;\n isEdit?: boolean;\n\n constructor(x?: Category) {\n if (typeof x === \"object\" && x != null) {\n this.accountId = x.accountId;\n this.id = x.id;\n this.name = x.name || \"\";\n this.isEdit = false;\n }\n else {\n this.accountId = null;\n this.id = null;\n this.name = \"\";\n this.isEdit = false;\n }\n }\n}\n","import { ApiClient } from \"./api-client\";\nimport Category from \"../models/category\";\nimport { Response } from \"./../models/response\";\n\n\nexport default class CategoryService {\n\n private static baseUrl: string = \"/category\";\n\n static getCategory(establishmentAccountId?: string): Promise<Response> {\n\n let urlEndpoint = `${this.baseUrl}/getcategories`;\n\n if (establishmentAccountId)\n urlEndpoint += `?AccountId=${establishmentAccountId}`;\n\n return ApiClient.get(urlEndpoint)\n .then((data) => {\n return new Response(data.category, data.total);\n });\n }\n\n static createCategory(category: Category): Promise<Category> {\n return ApiClient.post(`${this.baseUrl}/createcategory`, category)\n .then(data => {\n return new Category(data.category);\n });\n }\n\n static updateCategory(category: Category): Promise<Category> {\n return ApiClient.put(`${this.baseUrl}/updatecategory`, category)\n .then(data => {\n return new Category(data.category);\n });\n }\n\n static deleteCategory(w: Category): Promise<any> {\n let endpoint = `${this.baseUrl}/deletecategory?id=${w.id}`;\n\n if (w.accountId)\n endpoint += `&AccountId=${w.accountId}`;\n\n return ApiClient.remove(endpoint)\n .then(data => {\n return {\n entity: new Category(data.category),\n forbiddenDelete: data.forbiddenDelete\n };\n });\n }\n\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n \n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n\n component: {\n zIndex: 2,\n position: \"relative\",\n left: 0\n },\n labelCategory: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n required: {\n color: \"#6462F3\",\n fontFamily: \"Roboto, sans-serif\"\n },\n optional: {\n fontWeight: \"normal\",\n },\n divDropdown: {\n cursor: \"pointer\",\n width: 350,\n display: \"block\",\n marginTop: -7,\n\n\n },\n inputSelectBtn: {\n cursor: \"pointer\",\n width: 300,\n pointerEvents: \"none\"\n\n },\n iconDropdown: {\n cursor: \"pointer\",\n position: \"relative\",\n top: -24,\n textAlign: \"right\",\n right: 2\n },\n divModalSelect: {\n backgroundColor: \"#FFFFFF\",\n padding: \"0px 0 20px 0\", \n border: \"1px solid #DBDCDD\",\n borderRadius: 5,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n width: 350,\n textAlign: \"center\",\n position: \"fixed\"\n },\n listCategoryScroll: {\n overflowY: \"scroll\",\n maxHeight: 300,\n \"@media (max-height: 768px)\":{\n maxHeight: 215,\n },\n \"@media (max-height: 600px)\":{\n maxHeight: 121,\n }\n },\n listCategory: {\n padding: \"5px 0\",\n \"&:first-child\": {\n paddingTop: 10,\n },\n borderBottom: \"1px solid #F6F6F6\",\n marginBottom: 0,\n //maxHeight: 200,\n //overflow: \"hidden\",\n //overflowY: \"auto\"\n },\n categoryName: {\n textAlign: \"left\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\",\n width: \"75%\",\n overflow: \"hidden\",\n display: \"inline-block\",\n paddingTop: \"5px\",\n height: 40\n },\n button: {\n width: 300,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n color: \"#786EFF\",\n border: \"1px solid #786EFF\",\n\n },\n btnNewWorkareaCategory: {\n },\n elementList: {\n height: 32,\n padding: \"0px 30px 10px 30px\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n display: \"flex\",\n color: Color.gray5,\n\n },\n divInputEdit: {\n margin: \"auto\",\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n input: {\n marginLeft: \"auto\",\n \"& input\": {\n width: 250,\n }\n },\n iconPlus: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n\n iconSave: {\n border: \"none\",\n backgroundColor: \"transparent\",\n position: \"relative\",\n top: -30,\n left: 130,\n textAlign: \"center\",\n verticalAlign: \"middle\",\n padding: 0,\n color: \"#6462F3\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n divItemEdit: {\n height: 32,\n display: \"block\"\n },\n btnInputNew: {\n height: 32,\n \"& .MuiInputBase-root\": {\n height: 32\n }\n },\n classRow: {\n cursor: \"pointer\",\n \"& button\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n \"& button\": {\n visibility: \"visible\"\n }\n }\n },\n btnRow: {\n width: 32,\n height: 32,\n borderRadius: 51,\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\",\n border: \"none\",\n padding: 0,\n margin: 0,\n backgroundColor: \"transparent\",\n \"&:focus\": {\n outline: \"none\"\n }\n },\n deleteCategory: {\n color: Color.gray4,\n width: 13,\n height: 17,\n padding: 0,\n },\n editCategory: {\n color: Color.gray4,\n width: 13,\n height: 17,\n padding: 0,\n },\n divIconsRow: {\n right: 0,\n textAlign: \"center\",\n marginLeft: \"auto\",\n float: \"right\",\n paddingTop: 0\n\n },\n divNew: {\n marginTop: 15,\n //height: 55\n }\n\n}));\n\nexport default useStyles;\n","export enum SettingsFieldUpdate {\n None = -1,\n All = 0,\n Name = 1,\n PhoneNumber = 2,\n Address = 3,\n AddressReferences = 4,\n CancellationPolicies = 5,\n ShowPrices = 6,\n Logo = 7,\n IsPaymentCash = 8,\n IsPaymentCard = 9,\n IsPaymentBankTransfer = 10,\n Currency = 11,\n allowCustomerToCancelFromSite = 12,\n allowCustomerToModifyFromSite = 13,\n minuteLimitToModifyAppointmentFromSite = 14,\n requireSelectSpecialistFromSite = 15,\n showAnySpecialistFromSite = 16,\n gapBetweenTimeIntervalsFromSite = 17,\n AllowCustomerScheduleSimultaneousServices = 18,\n FiscalId = 19,\n AllowCustomerToScheduleTodayFromSite = 20,\n ShowCancellationPolicies = 21,\n ShowSuggestedServices = 22,\n ShowEstablishmentCertifications = 23,\n ShowSpecialistCertifications = 24,\n}\n\nexport const getEnum = (field: string) => {\n\n let e: { [key: string]: SettingsFieldUpdate } = {};\n\n e[\"name\"] = SettingsFieldUpdate.Name;\n e[\"fiscalid\"] = SettingsFieldUpdate.FiscalId;\n e[\"phonenumber\"] = SettingsFieldUpdate.PhoneNumber;\n e[\"address\"] = SettingsFieldUpdate.Address;\n e[\"addressreferences\"] = SettingsFieldUpdate.AddressReferences;\n e[\"cancellationpolicies\"] = SettingsFieldUpdate.CancellationPolicies;\n e[\"showprices\"] = SettingsFieldUpdate.ShowPrices;\n e[\"allowcustomertocancelfromsite\"] = SettingsFieldUpdate.allowCustomerToCancelFromSite;\n e[\"allowcustomertomodifyfromsite\"] = SettingsFieldUpdate.allowCustomerToModifyFromSite;\n e[\"ispaymentcash\"] = SettingsFieldUpdate.IsPaymentCash;\n e[\"ispaymentcard\"] = SettingsFieldUpdate.IsPaymentCard;\n e[\"ispaymentbanktransfer\"] = SettingsFieldUpdate.IsPaymentBankTransfer;\n e[\"currency\"] = SettingsFieldUpdate.Currency;\n e[\"logo\"] = SettingsFieldUpdate.Logo;\n e[\"minutelimittomodifyappointmentfromsite\"] = SettingsFieldUpdate.minuteLimitToModifyAppointmentFromSite;\n e[\"gapbetweentimeintervalsfromsite\"] = SettingsFieldUpdate.gapBetweenTimeIntervalsFromSite;\n e[\"allowcustomerschedulesimultaneousservices\"] = SettingsFieldUpdate.AllowCustomerScheduleSimultaneousServices;\n e[\"allowcustomertoscheduletodayfromsite\"] = SettingsFieldUpdate.AllowCustomerScheduleSimultaneousServices;\n e[\"showcancellationpolicies\"] = SettingsFieldUpdate.ShowCancellationPolicies;\n e[\"showsuggestedservices\"] = SettingsFieldUpdate.ShowSuggestedServices;\n e[\"showestablishmentcertifications\"] = SettingsFieldUpdate.ShowEstablishmentCertifications;\n e[\"showspecialistcertifications\"] = SettingsFieldUpdate.ShowSpecialistCertifications;\n\n return e[field.toLowerCase()];\n\n}","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Button from \"@material-ui/core/Button\";\n\nimport Input from \"./../../../common/Input\";\nimport { ArrowLineDown, PlusIcon, SaveIcon, EditIcon, TrashIcon } from \"./../../../../assets/icons\";\nimport Category from './../../../../models/category';\nimport CategoryService from \"./../../../../api/settings-category-service\"\n\nimport { WorkareasCategorySelectProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { useAppDispatch } from \"../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../redux/alerts-slice\";\n\nconst WorkareasCategorySelect = (props: WorkareasCategorySelectProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { settingsSelectedEstablishmentId, widthSelect, widthList, isOptional, onSelect, item } = props;\n const classes = useStyles();\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const [list, setList] = useState<Category[]>([]);\n const [showNew, setShowNew] = useState<boolean>(false);\n const [categorySelected, setCategorySelected] = useState<Category>();\n const [categoryNew, setCategoryNew] = useState<Category>();\n\n const [openModal, setOpenModal] = useState<boolean>(false);\n\n const handleEditItem = (i: Category) => {\n setShowNew(false);\n const newList = list.map((item) => {\n if (item.id === i.id) {\n const updatedItem = {\n ...item,\n isEdit: !item.isEdit,\n };\n setCategoryNew(item);\n return updatedItem;\n }\n else {\n const updatedItem = {\n ...item,\n isEdit: false,\n };\n\n return updatedItem;\n }\n });\n\n setList(newList);\n }\n\n const itemSelected = (i: Category) => {\n setCategorySelected(i);\n onSelect(i);\n setOpenModal(false);\n }\n\n\n useEffect(() => {\n (async () => {\n await loadData();\n })();\n\n if (item) {\n let cat = new Category({\n id: item.id,\n name: item.category,\n isEdit: false\n });\n\n setCategorySelected(cat);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId]);\n\n\n const loadData = async () => {\n const data = settingsSelectedEstablishmentId\n ? await CategoryService.getCategory(settingsSelectedEstablishmentId)\n : await CategoryService.getCategory();\n setList(data.entity || []);\n };\n\n const handleCategoryNew = () => {\n setCategoryNew(new Category());\n handleEditItem(new Category());\n setShowNew(true);\n\n }\n\n const changeCategoryNew = (event: React.ChangeEvent<{ name: string, value: string }>) => {\n let value = event.target.value;\n let newCat = new Category({ name: value });\n setCategoryNew(newCat);\n }\n\n const changeCategoryEdit = (i: Category) => (event: React.ChangeEvent<{ name: string, value: string }>) => {\n setCategoryNew(i);\n let value = event.target.value;\n\n setCategoryNew({ ...i, name: value });\n }\n\n const saveCategoryEdit = async (i: Category) => {\n if (categoryNew && categoryNew?.name !== \"\") {\n categoryNew.accountId = settingsSelectedEstablishmentId || null;\n const data = await CategoryService.updateCategory(categoryNew);\n if (data) {\n\n setCategoryNew(new Category());\n await loadData();\n }\n }\n }\n\n const saveCategoryNew = async () => {\n if (categoryNew && categoryNew?.name !== \"\") {\n categoryNew.accountId = settingsSelectedEstablishmentId || null;\n const data = await CategoryService.createCategory(categoryNew);\n if (data) {\n setShowNew(false);\n setCategoryNew(new Category());\n await loadData();\n }\n }\n }\n\n const handleDelete = async (i: Category) => {\n if (i) {\n i.accountId = settingsSelectedEstablishmentId || null;\n const data = await CategoryService.deleteCategory(i);\n if (data.forbiddenDelete) {\n // it wasn't deleted\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"It is not possible to delete a category linked to a work area or service\"),\n description: \"\"\n })\n );\n }\n else if (data.entity) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Category successfully removed\"),\n description: \"\"\n })\n );\n await loadData();\n }\n }\n }\n\n\n const handleOpenModal = () => {\n setCategoryNew(new Category());\n handleEditItem(new Category());\n setShowNew(false);\n setOpenModal(true);\n }\n\n\n const handleCloseModal = () => {\n setOpenModal(false);\n itemSelected(new Category());\n }\n\n\n return (<div className={classes.component}>\n\n <div className={classes.divDropdown} style={{ width: widthSelect || 350}} >\n\n <label className={classes.labelCategory}>\n <Typography className={classes.labelCategory}>\n\n\n {t(\"Category\")}{\" \"}\n\n {(isOptional ?? true) ?\n <span className={classes.optional}>({t(\"Optional\")})</span>\n :\n <span className={classes.required}>*</span>\n }\n\n\n </Typography >\n </label>\n\n <div onClick={handleOpenModal}>\n <Input\n id={\"itemSelect\"}\n name={\"categorySelected\"}\n value={categorySelected?.name || \"\"}\n placeholder={t(\"Select a category\")}\n width={widthSelect || 350}\n inputClass={classes.inputSelectBtn}\n isValid={() => isOptional ? isOptional : categorySelected?.name != \"\"}\n />\n </div>\n <div className={classes.iconDropdown} onClick={handleOpenModal}>\n <ArrowLineDown />\n </div>\n\n </div>\n\n <Modal\n open={openModal}\n onClose={handleCloseModal}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n onBackdropClick={handleCloseModal}\n disablePortal={true}\n style={{ position: \"relative\", top: -20 }} >\n\n <div className={classes.divModalSelect} style={{ width: widthList || 350}}>\n\n <div className={classes.listCategoryScroll} >\n {list.map((item) => {\n return <div key={item.id} className={classes.listCategory}>\n\n {!item.isEdit &&\n <div className={`${classes.elementList} ${classes.classRow}`}>\n <div className={classes.categoryName} onClick={() => itemSelected(item)}>\n {item.name}\n </div>\n <div className={classes.divIconsRow} >\n <button className={classes.btnRow} onClick={(e) => { e.stopPropagation(); handleEditItem(item); }} >\n <EditIcon className={classes.editCategory} />\n </button>\n <button className={classes.btnRow} onClick={(e) => { e.stopPropagation(); handleDelete(item); }} >\n <TrashIcon className={classes.deleteCategory} style={{ color: \"#919CA5\" }} />\n </button>\n </div >\n </div>\n }\n {item.isEdit &&\n <div className={classes.divItemEdit} >\n <div className={classes.divInputEdit} >\n <Input\n id={`inputEdit${categoryNew?.id}`}\n name={\"categoryEdit\"}\n value={categoryNew?.name}\n width={widthList || 300}\n maxLength={50}\n placeholder={t(\"Name of the category\")}\n inputClass={classes.input}\n isValid={() => categoryNew?.name != \"\" }\n autoFocus={true}\n onChange={changeCategoryEdit(item)}\n />\n </div>\n <button className={classes.iconSave} onClick={() => saveCategoryEdit(item)}>\n <SaveIcon />\n </button>\n </div>\n }\n </div >\n })}\n </div >\n\n <div className={classes.divNew} >\n {!showNew &&\n <div className={classes.btnInputNew}>\n <Button className={`${classes.button} ${classes.btnNewWorkareaCategory}`} onClick={handleCategoryNew} >\n {t('New category')}\n </Button>\n </div>\n }\n {showNew &&\n <div className={classes.btnInputNew}>\n <div >\n <Input\n id={\"category\"}\n name={\"category\"}\n value={categoryNew?.name}\n width={widthList || 300}\n maxLength={50}\n placeholder={t(\"Name of the category\")}\n inputClass={classes.input}\n isValid={() => categoryNew?.name != \"\"}\n autoFocus={true}\n onChange={changeCategoryNew}\n />\n </div>\n <button className={classes.iconPlus} onClick={saveCategoryNew}>\n <PlusIcon style={{ color: \"#6462F3\", height: 15, width: 15 }} />\n </button>\n </div>\n }\n </div>\n\n </div>\n </Modal>\n </div>);\n};\n\nexport default WorkareasCategorySelect;\n","import React, { useState, useEffect } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\n\nimport { AlphanumericRegex } from \"../../../../../constants/validator\";\n\nimport EntityForm, { WorkareasFormProps, WorkareasValid } from \"../../../../../models/workarea\";\nimport useStyles from \"./css\";\n\nimport Category from \"../../../../../models/category\";\nimport CategorySelect from \"./../../CategorySelect\";\nimport SwitchWithLabelAndTooltip from \"../../../../common/SwitchWithLabelAndTooltip\";\n\n\nconst WorkareasForm = (props: WorkareasFormProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const { settingsSelectedEstablishmentId, item, onChange, onModify } = props;\n const [entityState, setEntityState] = useState<EntityForm>(item || new EntityForm());\n\n const runValidations = (): WorkareasValid | undefined => {\n if (item) {\n return {\n name: AlphanumericRegex.test(item.name),\n description: true\n };\n }\n };\n\n const [entityValid, setEntityValid] = useState<WorkareasValid | undefined>(runValidations());\n\n useEffect(() => {\n\n if (item && JSON.stringify(item) !== JSON.stringify(entityState)) {\n setEntityState(item);\n }\n\n runValidations();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [item]);\n\n\n useEffect(() => {\n if (\n onChange\n && entityValid\n && entityValid.name\n ) {\n onChange(true, entityState);\n } else if (onChange) {\n onChange(false, entityState);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [entityState]);\n\n const handleChange = (event: any) => {\n let value = event.target.value;\n setEntityValid({\n ...entityValid,\n [event.target.name]: (value !== undefined && value !== null) ? AlphanumericRegex.test(value) : false\n });\n setEntityState({\n ...entityState,\n [event.target.name]: value\n });\n if (onModify) onModify();\n };\n\n const handleSelectCategory = (category: Category) => {\n setEntityState({\n ...entityState,\n categoryId: category.id,\n category: category.name\n });\n if (onModify) onModify();\n }\n\n const handleChangeSimultaneousServices = (value: boolean) => {\n setEntityState({\n ...entityState,\n hasSimultaneousServices: value,\n });\n if (onModify) onModify();\n }\n\n return (\n <div className={classes.root}>\n\n <div className={classes.rowContainer}>\n <label className={classes.title}>\n {t(\"Required fields\")} <span className={classes.required}>*</span>\n </label>\n </div>\n\n <div className={classes.rowContainer}>\n\n <InputWithLabel\n label={() => (\n <>\n {t(\"Work area name\")} <span className={classes.required}>*</span>\n </>\n )}\n value={entityState?.name}\n placeholder={t(\"Enter the work area name\")}\n width={350}\n maxLength={60}\n isValid={() => entityValid?.name}\n name=\"name\"\n onChange={handleChange}\n />\n\n <CategorySelect\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n onSelect={handleSelectCategory}\n item={item}\n isOptional={true}\n />\n\n </div>\n\n <div className={classes.rowDescription}>\n <InputWithLabel\n label={() => (\n <>\n {t(\"Description\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n placeholder={t(\"Enter a short description for the work area (Maximum 180 characters).\")}\n width={730}\n showCounter={true}\n maxLength={180}\n name=\"description\"\n onChange={handleChange}\n value={entityState?.description || \"\"}\n />\n </div>\n\n <div className={classes.switchBox}>\n <SwitchWithLabelAndTooltip\n value={entityState?.hasSimultaneousServices}\n setValue={handleChangeSimultaneousServices}\n label={t(\"Simultaneous services\")}\n tooltip={t(\"simultaneous-services-tooltip\")}\n inactiveTooltip={t(\"simultaneous-services-inactive-tooltip\")}\n />\n </div>\n\n </div>\n );\n};\n\nexport default WorkareasForm;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 399,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n \n },\n modalTitleTextCancel: {\n marginTop: 0,\n marginBottom: 20,\n fontSize: 18,\n fontWeight: \"bold\"\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n minHeight: 288,\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n // border: \"1px solid red\",\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n }\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect, useRef } from \"react\";\nimport { useTranslation } from 'react-i18next';\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport EntityService from \"../../../../../api/settings-workareas-service\";\nimport WorkareaForm from './../WorkAreaForm'\nimport Workarea from \"../../../../../models/workarea\";\n\nimport useStyles from \"./css\";\nimport Cloner from \"../../../../../utils/cloner\";\nimport stringify from \"safe-stable-stringify\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\n\nconst WorkareaModal = (props: any) => {\n const { settingsSelectedEstablishmentId, open, onClose, onCreate, item } = props;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const [entityState, setEntityState] = useState<Workarea>(new Workarea());\n const [initialState, setInitialState] = useState<string | null>(null);\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [isValid, _setIsValid] = useState<boolean>(false);\n const [isChangesMade, setIsChangesMade] = useState<boolean>(false);\n const isValidRef = useRef(isValid);\n\n useEffect(() => {\n setOpenModal(open);\n setIsChangesMade(false);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n\n const setIsValid = (data: boolean) => {\n isValidRef.current = data;\n _setIsValid(data);\n };\n\n const handleOnCreateClick = async () => {\n if (isValid) {\n setIsValid(false);\n let entity: Workarea;\n entityState.accountId = settingsSelectedEstablishmentId || null;\n if (!entityState.id) {\n entity = await EntityService.createWorkarea(entityState);\n }\n else {\n entity = await EntityService.updateWorkarea(entityState);\n }\n\n const newEntity: Workarea = { ...entityState, id: entity.id };\n setEntityState(newEntity);\n\n if (onCreate) {\n let edited = item !== null;\n onCreate(newEntity, edited);\n setInitialState(null);\n onClose();\n }\n }\n };\n\n const handleFormChange = (isValid: boolean, entity: Workarea) => {\n setIsValid(isValid);\n setEntityState(entity);\n if (initialState === null) {\n setInitialState(stringify(Cloner.deepCopy<Workarea>(entity)));\n }\n };\n\n const handleModifying = () => {\n setIsChangesMade(true);\n };\n\n return (<>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={(event, reason) => {\n if (reason === 'backdropClick') {\n if (isChangesMade)\n setCancelModal(true);\n else {\n setInitialState(null);\n onClose();\n }\n }\n }}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n <Fade in={openModal}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {item ? t('Work area detail') : t('New work area')}\n </Typography>\n </div>\n\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t\t backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={() => isChangesMade \n ? setCancelModal(true)\n : (setInitialState(null), onClose())\n }\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t\t backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={item ? t(\"Save changes\") : t(\"Create work area\")}\n onClick={handleOnCreateClick}\n\t\t\t disabled={!isValid || initialState === stringify(entityState)}\n />\n </div>\n\n </div>\n\n <WorkareaForm\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n item={item}\n onChange={handleFormChange}\n onModify={handleModifying}\n />\n\n </div>\n </Fade>\n </Modal>\n\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.modalCancelPaper}>\n <div className={classes.modalContent}>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleTextCancel}>\n {item ? t(\"Cancel work area edition?\") : t(\"Cancel work area registration?\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.goBack}`} onClick={() => setCancelModal(false)}>\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n setInitialState(null);\n setCancelModal(false);\n onClose();\n }}\n >\n {t(\"WorkAreaModalCancelEditConfirm\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </>);\n};\n\nexport default WorkareaModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: 288,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"80%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: theme.colors.grey7\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\"\n },\n deleteBtn: {\n fontWeight: \"bold\",\n fontSize: 12,\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { TrashIcon, CrossIcon } from \"../../../../../assets/icons\";\n\nimport { WorkAreaDeleteProps } from \"./props\";\nimport useStyles from \"./css\";\n\nconst WorkAreaDelete = (props: WorkAreaDeleteProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, item, onClose, onDelete } = props;\n const classes = useStyles();\n\n const handleDelete = () => {\n if (typeof onDelete === \"function\") onDelete(item);\n };\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"Delete this work area?\")}\n </Typography>\n </div>\n\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentTextTitle}>\n {item?.name}\n </Typography>\n </div>\n\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {item?.category}\n </Typography>\n </div>\n\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.goBack}`} onClick={onClose} >\n {t(\"Go back\")}\n </Button>\n\n <Button className={`${classes.button} ${classes.deleteBtn}`} onClick={handleDelete} >\n {t(\"Delete\")}\n </Button>\n </div>\n\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default WorkAreaDelete;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nimport { Color } from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n header: {\n marginBottom: 10,\n paddingTop: 5\n },\n headerRight: {\n textAlign: \"right\"\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\"\n },\n btnNewWorkArea: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n },\n titles: {\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\",\n marginBottom: 10\n },\n icons: {\n color: Color.gray5,\n fontSize: 18\n },\n icon: {\n paddingTop: 5,\n height: 30,\n width: 30,\n fontWeight: \"bold\"\n },\n noteHeader: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n}));\n\n\nexport default useStyles;\n","import React, { useState } from \"react\";\nimport { useTranslation } from 'react-i18next';\nimport { Grid, Typography } from \"@material-ui/core\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { DoorIcon } from \"../../../../../assets/icons\";\nimport EntityGrid from \"./../WorkAreaGrid\";\nimport EntityModal from './../WorkAreaModal';\nimport EntityDeleteModal from './../WorkAreaDelete/work-area-delete';\nimport Workarea from \"../../../../../models/workarea\";\nimport EntityService from \"../../../../../api/settings-workareas-service\";\nimport useStyles from \"./css\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport SectionNote from \"../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default (props: SettingsEnterpriseProps) => {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"general\"]);\n\n const classes = useStyles();\n const [isRefresh, setIsRefresh] = useState<any>();\n\n const [openItemEditModal, setOpenItemEditModal] = useState<boolean>(false);\n const [openItemDeleteModal, setOpenItemDeleteModal] = useState<boolean>(false);\n\n const [total, setTotal] = useState<number>(0);\n\n const [openAlert, setOpenAlert] = useState<boolean>(false);\n const [itemModal, setItemModal] = useState<Workarea | null>(null);\n\n const [newItem, setNewItem] = useState<Workarea | null>(null);\n \n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const handleCreate = (entity: any) => {\n\n setItemModal(null);\n setOpenItemEditModal(true);\n\n setIsRefresh(entity);\n };\n\n const handleRowClick = (item: Workarea) => {\n setOpenItemEditModal(true);\n setItemModal(item)\n }\n\n const handleDelete = (item: any) => {\n setItemModal(item);\n setOpenItemDeleteModal(true);\n }\n\n const handleCreated = (item: Workarea, edited: boolean) => {\n\n setOpenItemEditModal(false);\n\n if (edited) {\n setIsRefresh(item);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Work area updated successfully\"),\n description: item.name\n })\n );\n }\n else {\n setNewItem(item);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"New work area created successfully\"),\n description: item.name\n })\n );\n setTotal(total+1);\n }\n }\n\n const handleDeleted = async (item: any) => {\n\n const deletedEntity = await EntityService.deleteWorkarea(item);\n if (deletedEntity.forbiddenDelete) {\n setOpenItemDeleteModal(false);\n\n let msg: string = \"\";\n if (deletedEntity.forbiddenDelete == \"appointments\")\n msg = `${item.name} ${t(\"cannot be deleted because it has one or more future appointments associate\")}`;\n else // services\n msg = `${item.name} ${t(\"cannot be deleted because it has one or more services associate\")}`;\n\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Work area cannot be deleted\"),\n description: msg\n })\n );\n }\n else if (deletedEntity.entity) {\n setOpenItemDeleteModal(false);\n setIsRefresh(item);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Work area has been deleted\"),\n description: `${item.name} ${t(\"has been deleted\")}`\n })\n );\n }\n }\n\n const handleTotal = (total: number) => {\n setTotal(total);\n }\n\n\n return (<>\n <div>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.noteHeader}>\n <Typography className={classes.tabTitle}>\n {t(\"Work areas\")}\n </Typography>\n </div>\n <SectionNote\n sectionData={SectionNoteData.WorkAreas}\n />\n </>\n )}\n <div className={classes.header}>\n\n <Grid container spacing={2}>\n\n <Grid item xs={6}>\n <div>\n <Typography className={classes.titles} variant=\"subtitle1\">\n {t('Work areas created')}\n </Typography>\n <Typography className={classes.icons} variant=\"h4\">\n <DoorIcon className={classes.icon} />\n {total}\n </Typography>\n </div>\n </Grid>\n\n <Grid item xs={6}>\n <div className={classes.headerRight}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"Create work area\")}\n onClick={handleCreate}\n />\n </div>\n </Grid>\n\n </Grid>\n\n </div>\n\n <EntityGrid\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n isRefresh={isRefresh}\n item={newItem}\n openItemEditModal={handleRowClick}\n openDeleteModal={handleDelete}\n setTotalRecords={handleTotal}\n />\n\n </div>\n\n <EntityModal\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n open={openItemEditModal}\n item={itemModal}\n onClose={() => setOpenItemEditModal(false)}\n onCreate={handleCreated}\n />\n\n <EntityDeleteModal\n open={openItemDeleteModal}\n item={itemModal}\n onClose={() => setOpenItemDeleteModal(false)}\n onDelete={handleDeleted}\n />\n </>);\n};\n","export interface WeekdaysChangeSettingsModalProps {\n open: boolean;\n count: number;\n type: AlertPopupType;\n onClose?: () => void;\n}\n\n\nexport enum AlertPopupType {\n AvailableHours = 0,\n Timezone\n}","import { AppointmentTimeIntervalGapMinute } from \"./enums/appointment-time-interval-gap-minute\";\nimport { SettingsFieldUpdate } from \"./enums/settings-field-update\";\nimport { EstablishmentCertification } from \"./establishment-certification\";\n\nexport class EstablishmentInfo {\n accountId: string | null;\n name: string;\n fiscalId: string;\n mobileCodeIso3: string;\n mobileCountry: MobileCountry | null;\n phoneNumber: string;\n address: string;\n addressReferences?: string;\n cancellationPolicies?: string;\n showPrices: boolean;\n showSuggestedServices: boolean;\n allowCustomerToCancelFromSite: boolean;\n allowCustomerToScheduleTodayFromSite: boolean;\n minuteLimitToModifyAppointmentFromSite: number;\n allowCustomerToModifyFromSite: boolean;\n allowCustomerScheduleSimultaneousServices: boolean;\n requireSelectSpecialistFromSite: boolean;\n showAnySpecialistFromSite: boolean;\n showCancellationPolicies: boolean;\n showEstablishmentCertifications: boolean;\n establishmentCertifications: EstablishmentCertification[];\n showSpecialistCertifications: boolean;\n gapBetweenTimeIntervalsFromSite: AppointmentTimeIntervalGapMinute;\n logo?: string;\n fieldUpd: SettingsFieldUpdate;\n constructor(x?: EstablishmentInfo) {\n if (typeof x === \"object\" && x !== null) {\n this.accountId = x.accountId || null;\n this.name = x.name || \"\";\n this.fiscalId = x.fiscalId || \"\";\n this.mobileCodeIso3 = x.mobileCodeIso3 || \"\";\n this.mobileCountry = x.mobileCountry;\n this.phoneNumber = x.phoneNumber || \"\";\n this.address = x.address || \"\";\n this.addressReferences = x.addressReferences || \"\";\n this.cancellationPolicies = x.cancellationPolicies || \"\";\n this.showPrices = x.showPrices || false;\n this.showSuggestedServices = x.showSuggestedServices || false;\n this.allowCustomerToCancelFromSite = x.allowCustomerToCancelFromSite;\n this.allowCustomerToScheduleTodayFromSite = x.allowCustomerToScheduleTodayFromSite;\n this.minuteLimitToModifyAppointmentFromSite = x.minuteLimitToModifyAppointmentFromSite;\n this.allowCustomerToModifyFromSite = x.allowCustomerToModifyFromSite;\n this.allowCustomerScheduleSimultaneousServices = x.allowCustomerScheduleSimultaneousServices;\n this.requireSelectSpecialistFromSite = x.requireSelectSpecialistFromSite;\n this.showAnySpecialistFromSite = x.showAnySpecialistFromSite;\n this.gapBetweenTimeIntervalsFromSite = x.gapBetweenTimeIntervalsFromSite;\n this.showCancellationPolicies = x.showCancellationPolicies;\n this.showEstablishmentCertifications = x.showEstablishmentCertifications;\n this.establishmentCertifications = x.establishmentCertifications;\n this.showSpecialistCertifications = x.showSpecialistCertifications;\n this.fieldUpd = x.fieldUpd || SettingsFieldUpdate.None;\n this.logo = x.logo || \"\";\n }\n else {\n this.accountId = null;\n this.name = \"\";\n this.fiscalId = \"\";\n this.mobileCodeIso3 = \"\";\n this.mobileCountry = null;\n this.phoneNumber = \"\";\n this.address = \"\";\n this.addressReferences = undefined;\n this.cancellationPolicies = undefined;\n this.showPrices = false;\n this.showSuggestedServices = false;\n this.allowCustomerToCancelFromSite = true;\n this.allowCustomerToScheduleTodayFromSite = true;\n this.allowCustomerToModifyFromSite = true;\n this.allowCustomerScheduleSimultaneousServices = false;\n this.requireSelectSpecialistFromSite = true;\n this.showAnySpecialistFromSite = true;\n this.gapBetweenTimeIntervalsFromSite = AppointmentTimeIntervalGapMinute.Thirty;\n this.logo = \"\";\n this.showCancellationPolicies = false;\n this.showEstablishmentCertifications = false;\n this.establishmentCertifications = [];\n this.showSpecialistCertifications = false;\n this.minuteLimitToModifyAppointmentFromSite = 0;\n this.fieldUpd = SettingsFieldUpdate.None;\n }\n }\n}\n\n\nexport class ControlInput {\n name: boolean = true;\n fiscalId: boolean = true;\n phoneNumber: boolean = false;\n address: boolean = false;\n addressReferences: boolean = false;\n cancellationPolicies: boolean = false;\n showPrices: boolean = false;\n showSuggestedServices: boolean = false;\n\n constructor(x: boolean) {\n this.name = x;\n this.fiscalId = x;\n this.phoneNumber = x;\n this.address = x;\n this.addressReferences = x;\n this.cancellationPolicies = x;\n this.showPrices = x;\n this.showSuggestedServices = x;\n }\n}\n\n\nexport class MobileCountry {\n iso3?: string;\n dialCode?: number;\n dialDigits?: number;\n dialTemplate?: string;\n\n constructor(x: MobileCountry) {\n if (typeof x === \"object\" && x !== null) {\n this.iso3 = x.iso3;\n this.dialCode = x.dialCode;\n this.dialDigits = x.dialDigits;\n this.dialTemplate = x.dialTemplate;\n } else {\n this.iso3 = \"MEX\";\n this.dialCode = 52;\n this.dialDigits = 10;\n this.dialTemplate = \"000-000-0000\";\n }\n }\n}\n","import { ApiClient } from \"./api-client\";\nimport { EstablishmentInfo } from \"./../models/establishmentinfo\";\n//import { EstablishmentInfoEntity } from \"./../models/establishmentinfo-entity\";\n\nexport class EstablishmentInfoService {\n\n private static baseUrl: string = \"/account\";\n\n static updateEstablishmentInfo(establishment: EstablishmentInfo): Promise<EstablishmentInfo> {\n return ApiClient.post(`${this.baseUrl}/updateestablishmentinfo`, establishment)\n .then(data => new EstablishmentInfo(data.establishmentInfo)\n );\n }\n static async getEstablishmentInfo(establishmentAccountId?: string): Promise<EstablishmentInfo> {\n let url = `${this.baseUrl}/getestablishmentinfo`;\n\n if (establishmentAccountId) {\n url = `${this.baseUrl}/getestablishmentinfo?AccountId=${establishmentAccountId}`;\n }\n\n const data = await ApiClient.get(url);\n return new EstablishmentInfo(data.establishmentInfo);\n }\n\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 564,\n height: 388,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"80%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 30px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n //display: \"flex\",\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnCancel: {\n background: \"#F6F6F6\",\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\",\n margin: \"auto\"\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation, Trans } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { ExclamationIcon, CrossIcon } from \"../../../../../assets/icons\";\n\nimport { WeekdaysChangeSettingsModalProps, AlertPopupType } from \"./props\";\nimport useStyles from \"./css\";\n\nconst WeekdaysChangeSettingsModal = (props: WeekdaysChangeSettingsModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, count, type, onClose } = props;\n const classes = useStyles();\n\n const [counter, setCounter] = useState<number>(5);\n const [typeModify, setTypeModify] = useState<AlertPopupType>();\n\n useEffect(() => {\n setCounter(count);\n setTypeModify(type);\n });\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <ExclamationIcon viewBox=\"0 0 5 16\" />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {typeModify === AlertPopupType.Timezone && t(\"It is not possible to modify your time zone\")}\n {typeModify === AlertPopupType.AvailableHours && t(\"It is not possible to modify your available hours\")}\n </Typography>\n </div>\n\n <div className={classes.modalCenter}>\n {typeModify === AlertPopupType.Timezone && <Trans i18nKey=\"SettingsAlertChangeAboutTimezone\" t={t} count={counter} />}\n {typeModify === AlertPopupType.AvailableHours && <Trans i18nKey=\"SettingsAlertChangeAboutAvailableHours\" t={t} count={counter} />}\n </div>\n\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnCancel}`} onClick={onClose} >\n {t(\"OK!\")}\n </Button>\n </div>\n\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default WeekdaysChangeSettingsModal;\n","import { Timezone } from \"../models/timezone\";\nimport { ApiClient } from \"./api-client\";\nimport { Response } from \"./../models/response\";\nimport { useAppSelector } from \"../redux/hooks\";\n\nexport class TimezoneService {\n\n private static baseUrl: string = \"/timezone\";\n\n static updateTimezone(timezoneId: number, establishmentAccountId?: string): Promise<Response> {\n const request: any = { Timezone: timezoneId };\n\n if (establishmentAccountId) {\n request.AccountId = establishmentAccountId;\n }\n\n return ApiClient.post(`${this.baseUrl}/updatetimezone`, request)\n .then(data => {\n return new Response(data.timezone, data.appointmentsAffected);\n });\n }\n\n\n static async getTimezones(locale?: string, establishmentAccountId?: string): Promise<Timezone[]> {\n let endpoint = `${this.baseUrl}/gettimezones?locale=${locale ?? 'es'}`;\n\n if (establishmentAccountId) {\n endpoint += `&accountId=${establishmentAccountId}`;\n }\n\n const data = await ApiClient.get(endpoint);\n\n return data.timezones;\n }\n\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nimport { Color } from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n backgroundColor: \"gray\",\n },\n section: {\n marginTop: 30,\n },\n title: {\n fontSize: \"14px\",\n color: Color.gray5,\n marginBottom: 20,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n },\n titleSection: {\n fontSize: 12,\n color: Color.gray4,\n marginBottom: 10,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n },\n selectTimezone: {\n ...theme.typography.body2,\n fontWeight: \"bold\",\n marginTop: 10,\n marginBottom: 30,\n },\n headerDays: {\n fontSize: 12,\n color: Color.gray4,\n marginBottom: 5,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n },\n bodyBackground: {\n backgroundColor: \"#fff\",\n },\n divArea: {\n backgroundColor: \"#fff\",\n borderRadius: 20,\n border: \"1px solid #dbdcdd\",\n padding: \"40px\",\n margin: \"20px 0\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n label: {\n display: \"flex\",\n margin: 0,\n color: \"#4a4d51\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n required: {\n color: \"#6462F3\",\n marginLeft: 5,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n optional: {\n fontWeight: \"normal\",\n marginLeft: 10,\n },\n description: {\n margin: 0,\n color: \"#919CA5\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n },\n iconMoney: {\n color: \"#6462F3\",\n paddingTop: 4,\n fontSize: 30,\n fontWeight: \"bolder\",\n },\n labelH2: {\n display: \"flex\",\n paddingTop: 7,\n color: \"#5C6477\",\n fontSize: 14,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n inputClass: {\n color: Color.gray5,\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n display: \"inline-flex\",\n verticalAlign: \"middle\",\n },\n switchRoot: {\n width: 32,\n height: 21,\n padding: 0,\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: Color.white, //theme.palette.common.white,\n \"& + .MuiSwitch-track\": {\n backgroundColor: Color.green,\n opacity: 1,\n border: \"none\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n //\n },\n \"&$focusVisible .MuiSwitch-thumb\": {\n color: \"#6462F3\",\n border: \"6px solid #fff\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n switchThumb: {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n switchTrack: {\n borderRadius: 23 / 2,\n border: \"3px solid #323947\",\n backgroundColor: theme.palette.grey[50],\n opacity: 1,\n // .MuiSwitch-track\n },\n switchChecked: {},\n focusVisible: {},\n rowWeekDays: {\n height: 60,\n },\n dayLabel: {\n fontFamily: \"Inter\",\n width: 100,\n color: Color.gray5,\n fontSize: 14,\n display: \"inline\",\n fontWeight: \"bold\",\n },\n headerLabel: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\",\n },\n selectStyle: {\n color: Color.gray5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 200,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: Color.gray5,\n cursor: \"pointer\",\n },\n },\n selectHrs: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: Color.gray5,\n },\n },\n selectHrsClose: {\n \"& div:after\": {\n content: \"'hrs'\",\n color: \"rgba(0, 0, 0, 0.25)\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n },\n },\n selectStyleHrs: {\n position: \"relative\",\n top: 1,\n left: -150,\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n },\n multipleAppointments: {\n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n },\n titleWithTooltipContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 7\n }\n}));\n","import React, { useEffect, useReducer, useState } from \"react\";\nimport { Grid } from \"@material-ui/core\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { useTranslation } from \"react-i18next\";\n\nimport \"antd/dist/antd.css\";\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\n\nimport { useAppSelector } from \"../../../../../redux/hooks\";\nimport Switch from \"./../../../../common/Switch\";\nimport Select, { SelectItem } from \"../../../../common/Select\";\nimport PopupChangeSettings from \"./../WeekdaysChangeSettingsModal\";\nimport { AlertPopupType } from \"../WeekdaysChangeSettingsModal/props\";\nimport { WeekdayService } from \"../../../../../api/settings-weekdays-service\";\nimport { AccountService } from \"../../../../../api/account-service\";\nimport { Weekday } from \"../../../../../models/weekday\";\nimport { WeekdaysEnum } from \"../../../../../models/enums/weekdays\";\nimport { TimezoneService } from \"../../../../../api/settings-timezone-service\";\nimport { ArrowDropDownIcon, InfoIcon } from \"../../../../../assets/icons\";\n\nimport { useStyles } from \"./css\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { schedulerActions } from \"../../../../../redux/scheduler-slice\";\nimport { setAccountSettings } from \"../../../../../redux/account-settings-slice\";\nimport { AppointmentTimeIntervalGapMinute } from \"../../../../../models/enums/appointment-time-interval-gap-minute\";\nimport { AccountScheduleSectionSettingsModel } from \"../../../../../models/account-schedule-section-settings-model\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { SchedulerBlockDurationMinute } from \"../../../../../models/enums/scheduler-block-duration-minute\";\n\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\n\nexport default (props: SettingsEnterpriseProps) => {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n \n\n const [popupOpen, setPopupOpen] = useState<boolean>(false);\n const [scheduleSectionSettingsModel, setScheduleSectionSettingsModel] = \n useState<AccountScheduleSectionSettingsModel>(new AccountScheduleSectionSettingsModel());\n const [apptsAffected, setApptsAffected] = useState<number>(0);\n const [popupType, setPopupType] = useState<AlertPopupType>(\n AlertPopupType.AvailableHours\n );\n\n const [weekdaysState, setWeekdaysState] = useState<Weekday[]>([]);\n\n const [timezoneItems, setTimezoneItems] = useState<SelectItem[]>([]);\n const [timeZoneSelected, setTimeZoneSelected] = useState<string>(\"\");\n const [, forceUpdate] = useReducer((x) => x + 1, 0);\n\n\n const daysFalse = [false, false, false, false, false, false, false];\n const [selectOpening, setSelectOpening] = useState<boolean[]>(daysFalse);\n const [selectClosing, setSelectClosing] = useState<boolean[]>(daysFalse);\n\n const dispatch = useAppDispatch();\n const { setWeekDays } = schedulerActions;\n const { enqueueAlert } = alertsActions;\n\n const weekDays = [\n t(\"Sunday\"),\n t(\"Monday\"),\n t(\"Tuesday\"),\n t(\"Wednesday\"),\n t(\"Thursday\"),\n t(\"Friday\"),\n t(\"Saturday\"),\n ];\n const [weekDaysOrder, setWeekDaysOrder] = useState<number[]>([\n 1, 2, 3, 4, 5, 6, 0,\n ]);\n const format = \"HH:mm\";\n\n const timeGapsSelectItems: SelectItem[] = [\n {\n key: AppointmentTimeIntervalGapMinute.Five,\n value: `5 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Ten,\n value: `10 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Fifteen,\n value: `15 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Twenty,\n value: `20 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Thirty,\n value: `30 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Sixty,\n value: `1:00 ${t(\"hour\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Ninety,\n value: `1:30 ${t(\"hours\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.HundredTwenty,\n value: `2:00 ${t(\"hours\")}`\n }\n ];\n \n const blockDurationsSelectItems: SelectItem[] = [\n {\n key: SchedulerBlockDurationMinute.Five,\n value: `5 ${t(\"min\")}`\n },\n {\n key: SchedulerBlockDurationMinute.Ten,\n value: `10 ${t(\"min\")}`\n },\n {\n key: SchedulerBlockDurationMinute.Fifteen,\n value: `15 ${t(\"min\")}`\n },\n {\n key: SchedulerBlockDurationMinute.Thirty,\n value: `30 ${t(\"min\")}`\n },\n {\n key: SchedulerBlockDurationMinute.Sixty,\n value: `1 ${t(\"hour\")}`\n },\n {\n key: SchedulerBlockDurationMinute.Ninety,\n value: `1.5 ${t(\"hours\")}`\n }\n ];\n\n const handleLaborDay = async (event: any, dayNumber: number) => {\n var index = weekdaysState.findIndex((x) => x.dayNumber === dayNumber);\n\n let isOpen = event.target.checked;\n let newDay = [...weekdaysState];\n\n newDay[index].isOpen = isOpen;\n\n setWeekdaysState(newDay);\n saveWeekday(newDay[index]);\n };\n\n const toTimestamp = (strDate: string) => {\n const newDate = \"2000-01-01 \" + strDate;\n let datum = Date.parse(newDate);\n return datum / 1000;\n };\n\n const handleOpening = (e: any, dayNumber: number) => {\n let time = e;\n let index = weekdaysState.findIndex((x) => x.dayNumber === dayNumber);\n let newDay = [...weekdaysState];\n\n if (toTimestamp(time) < toTimestamp(newDay[index].closing!)) {\n newDay[index].opening = time;\n setWeekdaysState(newDay);\n saveWeekday(newDay[index]);\n } else {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Verify opening time\"),\n description: t(\"It is not possible to select a opening time after closing time\")\n })\n );\n }\n setSelectOpening(daysFalse);\n };\n\n const handleClosing = (e: any, dayNumber: number) => {\n let time = e;\n let index = weekdaysState.findIndex((x) => x.dayNumber === dayNumber);\n let newDay = [...weekdaysState];\n\n if (toTimestamp(time) > toTimestamp(newDay[index].opening!)) {\n newDay[index].closing = time;\n setWeekdaysState(newDay);\n saveWeekday(newDay[index]);\n } else {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Verify closing time\"),\n description: t(\"It is not possible to select a closing time before opening time\")\n })\n );\n }\n setSelectClosing(daysFalse);\n };\n\n const saveWeekday = (newDay: Weekday) => {\n (async () => {\n const total = settingsSelectedEstablishmentId\n ? await WeekdayService.updateWeekday(newDay, settingsSelectedEstablishmentId)\n : await WeekdayService.updateWeekday(newDay);\n \n if (total && +total > 0) {\n (async () => {\n await getDays();\n })();\n\n setPopupType(AlertPopupType.AvailableHours);\n setApptsAffected(total);\n setPopupOpen(true);\n }\n })();\n };\n\n useEffect(() => {\n (async () => {\n await getDays();\n await getTimezones();\n await getAccountMultipleAppointmentsSettings();\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId]);\n\n const getAccountMultipleAppointmentsSettings = async () => {\n const response = settingsSelectedEstablishmentId\n ? await AccountService.getAccountScheduleSectionSettings(settingsSelectedEstablishmentId)\n : await AccountService.getAccountScheduleSectionSettings();\n setScheduleSectionSettingsModel(response);\n };\n\n const getDays = async () => {\n setWeekDaysOrder([1, 2, 3, 4, 5, 6, 0]);\n\n let daysTemplate = await initializeWeekdays();\n let daysDb = settingsSelectedEstablishmentId\n ? await WeekdayService.getWeekdays(settingsSelectedEstablishmentId)\n : await WeekdayService.getWeekdays();\n \n dispatch(setWeekDays(daysDb))\n\n daysTemplate.map((item) => {\n var idx = daysTemplate.findIndex((x) => x.dayNumber === item.dayNumber);\n let d = daysDb.filter((a) => a.dayNumber === item.dayNumber);\n\n if (d.length === 1 && idx >= 0) {\n daysTemplate[idx].isOpen = d[0].isOpen;\n if (d[0].opening !== \"\") daysTemplate[idx].opening = d[0].opening;\n if (d[0].closing !== \"\") daysTemplate[idx].closing = d[0].closing;\n }\n });\n\n setWeekdaysState(daysTemplate);\n };\n\n const handleTimezone = async (event: any) => {\n let value = event.target.value;\n const data = settingsSelectedEstablishmentId\n ? await TimezoneService.updateTimezone(value, settingsSelectedEstablishmentId)\n : await TimezoneService.updateTimezone(value);\n\n if (data && data.total && +data.total > 0) {\n setPopupType(AlertPopupType.Timezone);\n setApptsAffected(data.total);\n setPopupOpen(true);\n\n await getTimezones();\n } else {\n setTimeZoneSelected(value);\n }\n };\n\n const getTimezones = async () => {\n const timezoneDb = settingsSelectedEstablishmentId\n ? await TimezoneService.getTimezones(localeApp, settingsSelectedEstablishmentId)\n : await TimezoneService.getTimezones(localeApp);\n\n const items: SelectItem[] = timezoneDb.map((i) => ({\n key: i.systemId,\n value: i.displayName,\n }));\n setTimezoneItems(items);\n\n const itemSelected = timezoneDb.filter((x) => x.isSelected)[0]?.systemId;\n setTimeZoneSelected(itemSelected);\n };\n\n const initializeWeekdays = async () => {\n let days: Weekday[] = [];\n\n weekDaysOrder.map((i) => {\n let dayName = weekDays[i];\n let opening = null;\n let closing = null;\n let isOpen: boolean = true;\n\n if (i >= WeekdaysEnum.Monday && i <= WeekdaysEnum.Friday) {\n opening = \"09:30\";\n closing = \"19:00\";\n }\n\n if (i === WeekdaysEnum.Saturday || i === WeekdaysEnum.Sunday) {\n opening = \"09:30\";\n closing = \"15:00\";\n }\n\n if (i === WeekdaysEnum.Sunday) isOpen = false;\n\n days.push(\n new Weekday({\n accountId: settingsSelectedEstablishmentId ?? accountSettings.accountId,\n dayNumber: i,\n dayName: dayName,\n opening: opening,\n closing: closing,\n isOpen: isOpen,\n })\n );\n });\n\n return days;\n };\n\n const handleOpenTimepicker = (\n type: number,\n day: number,\n openclose: boolean\n ) => {\n if (type === 0) {\n // opening\n let dayOpen = selectOpening;\n dayOpen[day] = openclose;\n setSelectOpening(dayOpen);\n }\n\n if (type === 1) {\n // closing\n let dayClose = selectClosing;\n dayClose[day] = openclose;\n setSelectClosing(dayClose);\n }\n\n forceUpdate();\n };\n\n const handleChangeMultiplesAppointmentsSetting = (event: any) => {\n (async () => {\n const result = settingsSelectedEstablishmentId\n ? await AccountService.updateAccountScheduleSectionSettings(\n new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n accountId: settingsSelectedEstablishmentId,\n hasMultipleAppointments: event.target.checked\n })\n )\n : await AccountService.updateAccountScheduleSectionSettings(\n new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n hasMultipleAppointments: event.target.checked\n })\n );\n setScheduleSectionSettingsModel(result);\n })();\n };\n \n async function handleChangeScheduleSimultaneousServices(event: any) {\n let value = event.target.checked;\n \n const result = settingsSelectedEstablishmentId\n ? await AccountService.updateAccountScheduleSectionSettings(\n new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n accountId: settingsSelectedEstablishmentId,\n scheduleSimultaneousServicesEnabled: value\n })\n )\n : await AccountService.updateAccountScheduleSectionSettings(\n new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n scheduleSimultaneousServicesEnabled: value\n })\n )\n setScheduleSectionSettingsModel(result);\n if (result) {\n dispatch(setAccountSettings({ ...accountSettings, scheduleSimultaneousServicesEnabled: value }));\n }\n }\n\n const handleChangeScheduleTimeIntervalGapSetting = (event: any) => {\n (async () => {\n const result = settingsSelectedEstablishmentId\n ? await AccountService.updateAccountScheduleSectionSettings(\n new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n accountId: settingsSelectedEstablishmentId,\n gapBetweenTimeIntervals: event.target.value\n })\n )\n : await AccountService.updateAccountScheduleSectionSettings(\n new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n gapBetweenTimeIntervals: event.target.value\n })\n );\n setScheduleSectionSettingsModel(result);\n })();\n };\n \n const handleChangeBlockDurationTimeIntervalsSetting = (event: any) => {\n (async () => {\n const updatedSettings = new AccountScheduleSectionSettingsModel({\n ...scheduleSectionSettingsModel,\n schedulerBlockDurationMinutes: event.target.value,\n ...(settingsSelectedEstablishmentId && { accountId: settingsSelectedEstablishmentId })\n });\n\n const result = await AccountService.updateAccountScheduleSectionSettings(updatedSettings);\n\n setScheduleSectionSettingsModel(result);\n if (result) {\n const updatedAccountSettings = {\n ...accountSettings,\n schedulerBlockDurationMinutes: result.schedulerBlockDurationMinutes,\n ...(settingsSelectedEstablishmentId && { accountId: settingsSelectedEstablishmentId })\n };\n dispatch(setAccountSettings(updatedAccountSettings));\n }\n })();\n };\n\n return (\n <div className={classes.section}>\n <Typography className={classes.title}>{t(\"Schedule\")}</Typography>\n\n <div className={classes.divArea}>\n <div style={{ marginBottom: 40 }}>\n <Grid container spacing={0} >\n <Grid item xs={4}>\n <Typography className={classes.titleSection}>\n {t(\"Time zone\")}\n </Typography>\n </Grid>\n <Grid item xs={3} className={classes.titleWithTooltipContainer}>\n <Typography className={classes.titleSection}>\n {t(\"Default block duration\")}\n </Typography>\n <IconTooltip\n key={\"gapTooltip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Adjust the duration of the calendar blocks\")}\n />\n </Grid>\n <Grid item xs={3} className={classes.titleWithTooltipContainer}>\n <Typography className={classes.titleSection}>\n {t(\"Time slot for scheduling an appointment\")}\n </Typography>\n <IconTooltip\n key={\"gapTooltip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Time interval displayed between the options to schedule an appointment\")}\n />\n </Grid>\n </Grid>\n <Grid container spacing={0} >\n <Grid item xs={4}>\n <Select\n key={\"cmbTimeZone\"}\n width={230}\n placeholder={t(\"Time zone\")}\n value={timeZoneSelected}\n onChange={(e) => handleTimezone(e)}\n colorArrowIcon={\"#5C6477\"}\n items={timezoneItems}\n />\n </Grid>\n <Grid item xs={3}>\n <Select\n key={\"defaultBlockDurationClient\"}\n width={254}\n value={scheduleSectionSettingsModel.schedulerBlockDurationMinutes}\n onChange={(e) => handleChangeBlockDurationTimeIntervalsSetting(e)}\n colorArrowIcon={\"#5C6477\"}\n items={blockDurationsSelectItems}\n />\n </Grid>\n <Grid item xs={3}>\n <Select\n key={\"timeGapAccountClient\"}\n width={254}\n value={scheduleSectionSettingsModel.gapBetweenTimeIntervals}\n onChange={(e) => handleChangeScheduleTimeIntervalGapSetting(e)}\n colorArrowIcon={\"#5C6477\"}\n items={timeGapsSelectItems}\n />\n </Grid>\n </Grid>\n </div>\n <Grid container spacing={3} className={classes.headerDays}>\n <Grid item xs={2}>\n <div className={classes.headerLabel} style={{ marginLeft: 0 }}>{t(\"Appointment\")}</div>\n </Grid>\n </Grid>\n <Grid\n container\n spacing={1}\n className={classes.rowWeekDays}\n >\n <Grid item xs={4}>\n <div style={{ display: \"flex\", alignItems: \"center\", marginRight: 16, height: 36, marginLeft: 2 }}>\n <Switch\n value={scheduleSectionSettingsModel.hasMultipleAppointments}\n onChange={(e) => handleChangeMultiplesAppointmentsSetting(e)}\n baseClass={classes.switchBase}\n />\n <Typography\n className={classes.multipleAppointments}\n style={{ marginLeft: 16, display: \"inline-block\" }}\n >\n {t(\"Schedule simultaneous appointments\")}\n </Typography>\n </div>\n </Grid>\n <Grid item xs={5}>\n <div style={{ display: \"flex\", alignItems: \"center\", height: 36, marginLeft: 2 }}>\n <Switch\n value={scheduleSectionSettingsModel.scheduleSimultaneousServicesEnabled}\n onChange={(e) => handleChangeScheduleSimultaneousServices(e)}\n baseClass={classes.switchBase}\n />\n <Typography\n className={classes.multipleAppointments}\n style={{ marginLeft: 16, display: \"inline-block\" }}\n >\n {t(\"Schedule appointments with simultaneous services\")}\n </Typography>\n </div>\n </Grid>\n </Grid>\n <Grid container spacing={3} className={classes.headerDays}>\n <Grid item xs={4}>\n <div className={classes.headerLabel} style={{ marginLeft: 0 }}>{t(\"Weekdays\")}</div>\n </Grid>\n <Grid item xs={3}>\n <div className={classes.headerLabel}>{t(\"Opening time\")}</div>\n </Grid>\n <Grid item xs={3}>\n <div className={classes.headerLabel}>{t(\"Closing time\")}</div>\n </Grid>\n </Grid>\n\n {weekDaysOrder.map((day) => {\n const item = weekdaysState.filter((a) => a.dayNumber === day)[0];\n\n return (\n item && (\n <Grid\n key={item.dayNumber}\n container\n spacing={1}\n className={classes.rowWeekDays}\n >\n <Grid item xs={4}>\n <div\n style={{ marginRight: 20, width: 50, display: \"inline\", marginLeft: 0 }}\n >\n <Switch\n value={item.isOpen}\n onChange={(e) => handleLaborDay(e, item.dayNumber)}\n baseClass={classes.switchBase}\n />\n </div>\n <div className={classes.dayLabel}>{item.dayName}</div>\n </Grid>\n <Grid item xs={3}>\n <div>\n <TimePicker\n key={`opening_${item.dayNumber}`}\n onOk={(time) => {\n handleOpening(time.format(format), item.dayNumber);\n }}\n className={`${classes.selectStyle} ${item.isOpen ? classes.selectHrs : classes.selectHrsClose\n }`}\n placeholder=\"Opened\"\n inputReadOnly={true}\n showNow={false}\n value={moment(item.opening, format)}\n disabled={!item.isOpen}\n onOpenChange={(e) =>\n handleOpenTimepicker(0, item.dayNumber, e)\n }\n format={format}\n />\n <ArrowDropDownIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: item.isOpen ? \"#5C6477\" : \"#CCC\",\n position: \"relative\",\n transform: selectOpening[item.dayNumber]\n ? \"rotate(180deg)\"\n : \"rotate(0deg)\",\n }}\n />\n </div>\n </Grid>\n <Grid item xs={3}>\n <div>\n <TimePicker\n key={`closing_${item.dayNumber}`}\n className={`${classes.selectStyle} ${item.isOpen ? classes.selectHrs : classes.selectHrsClose\n }`}\n onOk={(time) => {\n handleClosing(time.format(format), item.dayNumber);\n }}\n placeholder=\"Closed\"\n inputReadOnly={true}\n showNow={false}\n value={moment(item.closing, format)}\n disabled={!item.isOpen}\n onOpenChange={(e) =>\n handleOpenTimepicker(1, item.dayNumber, e)\n }\n format={format}\n />\n <ArrowDropDownIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: item.isOpen ? \"#5C6477\" : \"#CCC\",\n position: \"relative\",\n transform: selectClosing[item.dayNumber]\n ? \"rotate(180deg)\"\n : \"rotate(0deg)\",\n }}\n />\n </div>\n </Grid>\n </Grid>\n )\n );\n })}\n </div>\n\n <PopupChangeSettings\n open={popupOpen}\n onClose={() => setPopupOpen(false)}\n count={apptsAffected}\n type={popupType}\n />\n </div>\n );\n};\n","export class EstablishmentPhoto {\n accountId?: string | null;\n photoId?: string;\n photoURL?: string;\n order: number;\n\n\n constructor(x?: EstablishmentPhoto) {\n if (typeof x === \"object\" && x !== null) {\n this.accountId = x.accountId;\n this.photoId = x.photoId || \"\";\n this.photoURL = x.photoURL || \"\";\n this.order = x.order || 0;\n }\n else {\n this.accountId = null;\n this.photoId = \"\";\n this.photoURL = \"\";\n this.order = 0;\n }\n }\n}\n","import { ApiClient } from \"./api-client\";\nimport { EstablishmentPhoto } from \"./../models/establishmentphoto\";\n\nexport class EstablishmentPhotoService {\n\n private static baseUrl: string = \"/account\";\n\n static updateEstablishmentPhoto(establishment: EstablishmentPhoto): Promise<EstablishmentPhoto> {\n return ApiClient.post(`${this.baseUrl}/updateestablishmentphoto`, establishment)\n .then(data => {\n return new EstablishmentPhoto(data.establishmentPhoto)\n });\n }\n\n static deleteEstablishmentPhoto(establishment: EstablishmentPhoto): Promise<EstablishmentPhoto> {\n let endpoint = `${this.baseUrl}/deleteestablishmentphoto?order=${establishment.order}`;\n\n if (establishment.accountId) {\n endpoint += `&accountId=${establishment.accountId}`;\n }\n\n return ApiClient.remove(endpoint)\n .then(data => {\n return new EstablishmentPhoto(data.establishmentPhoto)\n });\n }\n\n static async getEstablishmentPhotos(establishmentAccountId?: string): Promise<EstablishmentPhoto[]> {\n var endpoint = `${this.baseUrl}/getestablishmentphotos`;\n if (establishmentAccountId)\n endpoint += `?AccountId=${establishmentAccountId}`;\n const data = await ApiClient.get(endpoint);\n if (data)\n return data.establishmentPhotos.map(\n (item: any) =>\n new EstablishmentPhoto(item)\n );\n else\n return [];\n }\n\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles((theme) => ({\n label: {\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#4a4d51\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n labelSecondary: {\n fontFamily: \"Roboto,sans serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n optional: {\n marginLeft: 3,\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#4a4d51\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n photosEstablishmentRow: {\n marginTop: 10,\n display: \"table\",\n width: \"100%\",\n tableLayout: \"fixed\",\n textAlign: \"center\"\n },\n photosEstablishmentCol: {\n display: \"inline-grid\",\n \"&:first-child\": {\n float: \"left\"\n },\n \"&:last-child\": {\n float: \"right\"\n }\n },\n photoEstablishment: {\n width: 230,\n height: 120,\n backgroundColor: \"#FFF\",\n borderRadius: 12,\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\",\n backgroundPosition: \"center top\",\n },\n photoEstablishmentEmpty: {\n width: 230,\n height: 120,\n backgroundColor: \"#F6F6F6\",\n borderRadius: 12,\n border: \"1px dashed #DBDCDD;\",\n cursor: \"pointer\",\n },\n iconPlus: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: theme.colors.clearMain\n },\n labelAddPhoto: {\n marginTop: 0,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#919CA5\"\n },\n labelAddPhotoIns: {\n marginTop: -5,\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 9,\n color: \"#919CA5\",\n textAlign: \"center\",\n },\n photosEstablishmentControls: {\n height: 24,\n textAlign: \"right\",\n paddingTop: 5,\n paddingRight: 5\n },\n iconCamera: {\n color: \"#919CA5\",\n fontSize: 20,\n cursor: \"pointer\",\n marginLeft: 10,\n marginTop: 3,\n\n },\n iconTrash: {\n color: \"#919CA5\",\n fontSize: 24,\n cursor: \"pointer\",\n marginLeft: 10,\n },\n modalDelete: {\n height: 220\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: theme.colors.grey7\n },\n}));\n\n","import React, { useEffect, useState, useRef, useCallback } from \"react\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { useTranslation } from 'react-i18next';\n\nimport ServicesService from \"../../../../../api/settings-services-service\";\nimport { EstablishmentPhotoService } from \"../../../../../api/settings-establishmentphoto-service\";\nimport { EstablishmentPhoto } from \"../../../../../models/establishmentphoto\";\n\nimport Alert from \"../../../../../models/alert\";\nimport { AlertType } from \"../../../../../models/enums/alert-type\";\n\nimport DropImage from \"../../../../common/DropImage\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\n\nimport { CameraIcon, PlusIcon, TrashIcon } from \"../../../../../assets/icons\";\nimport { useStyles } from \"./css\";\n\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\n\nexport default (props: SettingsEnterpriseProps) => {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const imageRef = useRef<HTMLInputElement>(null);\n\n const [photos, setPhotos] = useState<EstablishmentPhoto[]>([]);\n const [openDeleteDialog, setOpenDeleteDialog] = useState<boolean>(false);\n const [photoToDel, setPhotoToDel] = useState<number>(0);\n const [photoToUp, setPhotoToUp] = useState<number>(0);\n\n const [, updateState] = useState<object>();\n const forceUpdate = useCallback(() => updateState({}), []);\n\n useEffect(() => {\n\n (async () => {\n\n const photosDb = settingsSelectedEstablishmentId\n ? await EstablishmentPhotoService.getEstablishmentPhotos(settingsSelectedEstablishmentId)\n : await EstablishmentPhotoService.getEstablishmentPhotos();\n let picturls: EstablishmentPhoto[] = [];\n\n for (let pic: number = 0; pic < 3; pic++) {\n const p = photosDb.filter(x => x.order === pic);\n if (p.length > 0) {\n picturls.push(p[0]);\n } else {\n picturls.push(new EstablishmentPhoto());\n }\n }\n\n setPhotos(picturls);\n\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId]);\n\n const handlePhotoUpload = async (files: any, photoIndex: number) => {\n\n if (files && files.length > 0) {\n\n const validate = await isFileNotValid(files[0]);\n if (validate) return;\n\n let dataPhoto: any = await ServicesService.saveImage(files[0]);\n if (dataPhoto) {\n const newPhoto: EstablishmentPhoto = new EstablishmentPhoto();\n newPhoto.photoId = dataPhoto.fileName;\n //newPhoto.photoURL = dataPhoto.fileURL;\n newPhoto.order = photoIndex;\n\n if (settingsSelectedEstablishmentId)\n newPhoto.accountId = settingsSelectedEstablishmentId\n\n const establishmentPhoto: EstablishmentPhoto = await EstablishmentPhotoService.updateEstablishmentPhoto(newPhoto);\n\n if (establishmentPhoto.photoId) {\n photos[photoIndex] = establishmentPhoto;\n setPhotos(photos);\n\n forceUpdate();\n }\n }\n }\n }\n\n\n const isFileNotValid = async (file: any) => {\n const validTypes = ['image/jpeg', 'image/jpg', 'image/png'];\n if (validTypes.indexOf(file.type) === -1) {\n //console.log(\"File is not jpg/png\");\n return true;\n }\n\n if (file.size > (800 * 1024)) {\n //console.log(\"File is too large. Maximium is 800kb\");\n return true;\n }\n\n return false;\n }\n\n\n const handleChangeFile = async (e: React.FormEvent<HTMLInputElement>) => {\n e.stopPropagation();\n e.preventDefault();\n\n const files = imageRef.current?.files;\n await handlePhotoUpload(files, photoToUp);\n }\n\n\n const showOpenFileDialog = (index: number) => {\n if (imageRef && imageRef != null && imageRef != undefined && imageRef.current != undefined) {\n imageRef.current.click();\n setPhotoToUp(index);\n }\n };\n\n\n const confirmDelete = (index: number) => {\n setOpenDeleteDialog(true);\n setPhotoToDel(index);\n };\n\n const handleDelete = async (photoIndex: number) => {\n\n const delPhoto: EstablishmentPhoto = photos.filter(x => x.order === photoIndex)[0];\n\n if (settingsSelectedEstablishmentId)\n delPhoto.accountId = settingsSelectedEstablishmentId;\n\n let establishmentPhoto = await EstablishmentPhotoService.deleteEstablishmentPhoto(delPhoto);\n\n if (establishmentPhoto) {\n photos[photoIndex] = new EstablishmentPhoto();\n setPhotos(photos);\n setOpenDeleteDialog(false);\n forceUpdate();\n }\n };\n\n\n const DivPhotoEmpty: React.FC = () => {\n return (<>\n <div className={classes.iconPlus}>\n <PlusIcon style={{ color: \"#6462F3\" }} />\n </div>\n <div className={classes.labelAddPhoto}>\n {t(\"Add photo\")}\n </div>\n <div className={classes.labelAddPhotoIns}>\n {t(\"Min size\") + \": 660px x 450px\"}\n </div>\n </>);\n };\n\n\n const DivInfoDelete: React.FC = () => {\n return (<>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"Delete this establishment photo?\")}\n </Typography>\n </div>\n </>);\n };\n\n\n return (<>\n <input\n ref={imageRef!}\n type=\"file\"\n style={{ display: 'none' }}\n accept=\"image/jpeg, image/jpg, image/png\"\n onChange={(e) => handleChangeFile(e)}\n />\n\n <Typography className={classes.label}>\n {t(\"Photographs of the establishment\")}\n </Typography>\n <span className={classes.optional}>({t(\"Optional\")})</span>\n <br />\n <div className={classes.labelSecondary}>\n {t(\"These photos will appear on your site for appointments\")}.\n </div>\n\n <div className={classes.photosEstablishmentRow}>\n {\n photos.map((photo, index) => {\n return (<div key={index} className={classes.photosEstablishmentCol}>\n\n <DropImage\n key={index}\n classDivUploadImage={photo.photoURL ? classes.photoEstablishment : classes.photoEstablishmentEmpty}\n onChange={e => handlePhotoUpload(e, index)}\n imageURL={photo.photoURL}\n disableChange={photo.photoId !== \"\"}\n funcToValid={isFileNotValid}\n disableBlob={true}\n componentShowEmpty={<DivPhotoEmpty />} />\n\n <div className={classes.photosEstablishmentControls}>\n {\n <div style={{ display: photo.photoId ? \"\" : \"none\" }}>\n <CameraIcon className={classes.iconCamera} onClick={() => showOpenFileDialog(index)} />\n <TrashIcon style={{ color: \"#919CA5\" }} className={classes.iconTrash} onClick={() => confirmDelete(index)} />\n </div>\n }\n </div>\n </div>)\n })\n }\n </div>\n\n <ConfirmDeleteModal\n classModal={classes.modalDelete}\n open={openDeleteDialog}\n item={photoToDel}\n componentInfo={<DivInfoDelete />}\n onClose={() => setOpenDeleteDialog(false)}\n onDelete={handleDelete}\n />\n\n </>\n );\n};\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {},\n section: {\n paddingBottom: 10\n },\n divArea: {\n backgroundColor: \"#fff\",\n borderRadius: 20,\n border: \"1px solid #dbdcdd\",\n padding: \"40px\",\n margin: \"10px 0\"\n },\n title: {\n fontSize: \"14px\",\n color: theme.colors.grey5,\n marginBottom: 16,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n },\n inputClass: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n },\n label: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n display: \"inline-flex\",\n marginBottom: \"0.5rem\",\n },\n iconLabel: {\n display: \"inline-flex\",\n fontSize: 14,\n marginRight: 5,\n marginLeft: 5\n },\n select: {\n ...theme.typography.txtBody2,\n // fontWeight: \"bold\",\n backgroundColor: theme.colors.grey1,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 230,\n },\n selected: {\n fontWeight: \"bold\",\n },\n placeholder: {\n color: \"#676767\",\n opacity: \"0.42\",\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n },\n menuItem: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n }\n}));\n\n","import React, { useEffect, useState } from \"react\";\nimport { Box, Grid, Typography } from \"@material-ui/core\";\nimport { useStyles } from \"./css\";\nimport { useTranslation } from 'react-i18next';\nimport { SelectItem } from \"../../../../common/SelectWithLabel/props\";\nimport Select from \"../../../../common/Select\";\nimport { StatusIcon } from \"../../../../../assets/icons\";\nimport { CustomerFrequencyType } from \"../../../../../models/enums/customer-frequency-type\";\n\nimport { CustomersClassificationEntity, CustomerClassificationType, GetCustomerClassificationLocale } from \"../../../../../models/customers-classification-entity\";\nimport { CustomerClassificationService } from \"../../../../../api/customer-classification-service\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\n\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport { CustomersClassifications } from \"../../../../../models/customers-classifications\";\n\nconst CustomerClassification = (props: SettingsEnterpriseProps) => {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const [frequencyList, setFrequencyList] = useState<SelectItem[]>([]);\n const [infrequencyList, setInfrequencyList] = useState<SelectItem[]>([]);\n const [inactiveList, setInactiveList] = useState<SelectItem[]>([]);\n const dispatch = useAppDispatch();\n\n const [frequents, setFrequents] = useState<SelectItem>();\n const [infrequents, setInfrequents] = useState<SelectItem>();\n const [inactives, setInactives] = useState<SelectItem>();\n\n const classification0appt: string[] = GetCustomerClassificationLocale(CustomerClassificationType.Inactive);\n const classification1appt: string[] = GetCustomerClassificationLocale();\n\n useEffect(() => {\n\n (async () => {\n CustomerClassificationService.getCustomerClassificationList().then(classificationList => {\n\n const appt1: SelectItem[] = classificationList.map(x => ({ key: x.id, value: classification1appt[(x?.months||0) - 1] }));\n\n setFrequencyList(appt1);\n setInfrequencyList(appt1);\n\n const appt0: SelectItem[] = classificationList.map(x => ({ key: x.id, value: classification0appt[(x?.months||0) - 1] }));\n setInactiveList(appt0);\n\n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n\n let classifications: CustomersClassifications;\n if (settingsSelectedEstablishmentId)\n classifications = await CustomerClassificationService.getCustomerClassifications(settingsSelectedEstablishmentId);\n else\n classifications = await CustomerClassificationService.getCustomerClassifications();\n\n dispatch(navbarActions.setShowLoader(false));\n if (classifications.customerFrequencyClassificationFrequentId) {\n\n const _frequent: SelectItem = appt1.filter(x => x.key === classifications.customerFrequencyClassificationFrequentId)[0];\n setFrequents(_frequent);\n\n const _infrequent: SelectItem = appt1.filter(x => x.key === classifications.customerFrequencyClassificationInfrequentId)[0];\n setInfrequents(_infrequent);\n\n const _inactive: SelectItem = appt0.filter(x => x.key === classifications.customerFrequencyClassificationInactiveId)[0];\n setInactives(_inactive);\n\n const disableInfraquency = appt1.map(x => x.key === _frequent.key ? { ...x, 'isGroup': true } : { ...x, 'isGroup': false });\n setInfrequencyList(disableInfraquency);\n\n const disableFraquency = appt1.map(x => x.key === _infrequent.key ? { ...x, 'isGroup': true } : { ...x, 'isGroup': false });\n setFrequencyList(disableFraquency);\n }\n })();\n\n }); \n\n })();\n\n\n }, [settingsSelectedEstablishmentId])\n\n const handleFrequency = async (e: any) => {\n let value = e.target?.value!;\n\n let selected = frequencyList.filter(x => x.key === value)[0];\n setFrequents(selected);\n\n const mappedObjectsArray = infrequencyList.map(x => x.key === value ? { ...x, 'isGroup': true } : { ...x, 'isGroup': false });\n setInfrequencyList(mappedObjectsArray);\n if (settingsSelectedEstablishmentId)\n await CustomerClassificationService.updateCustomersClassification(value, CustomerClassificationType.Frequent, settingsSelectedEstablishmentId);\n else\n await CustomerClassificationService.updateCustomersClassification(value, CustomerClassificationType.Frequent);\n }\n\n const handleInfrequency = async (e: any) => {\n let value = e.target?.value!;\n\n let selected = infrequencyList.filter(x => x.key === value)[0];\n setInfrequents(selected);\n\n const mappedObjectsArray = frequencyList.map(x => x.key === value ? { ...x, 'isGroup': true } : { ...x, 'isGroup': false });\n setFrequencyList(mappedObjectsArray);\n\n if (settingsSelectedEstablishmentId)\n await CustomerClassificationService.updateCustomersClassification(value, CustomerClassificationType.Infrequent, settingsSelectedEstablishmentId);\n else\n await CustomerClassificationService.updateCustomersClassification(value, CustomerClassificationType.Infrequent);\n }\n\n const handleInactive = async (e: any) => {\n let value = e.target?.value!;\n\n let selected = inactiveList.filter(x => x.key === value)[0];\n setInactives(selected);\n\n if (settingsSelectedEstablishmentId)\n await CustomerClassificationService.updateCustomersClassification(value, CustomerClassificationType.Inactive, settingsSelectedEstablishmentId);\n else\n await CustomerClassificationService.updateCustomersClassification(value, CustomerClassificationType.Inactive);\n }\n\n\n return (\n <div className={classes.section}>\n <div>\n <Typography className={classes.title}>\n {useCustomerTerminology(t(\"Customer classification\"), \"Customer classification\")}\n </Typography>\n </div>\n <Box className={classes.divArea}>\n\n <Grid container>\n <Grid item xs={3}>\n <div className={classes.root}>\n <StatusIcon status={CustomerFrequencyType.Frequent} className={classes.iconLabel} />\n <label className={classes.label}>\n {t(\"Frequents\")}\n </label>\n <Select key={\"cmbFrequency\"}\n width={230}\n placeholder={t(\"Frequents\")}\n value={frequents?.key}\n onChange={(e) => handleFrequency(e)}\n colorArrowIcon={\"#5C6477\"}\n items={frequencyList} />\n </div>\n </Grid>\n <Grid item xs={3}>\n <div className={classes.root}>\n <StatusIcon status={CustomerFrequencyType.Infrequent} className={classes.iconLabel} />\n <label className={classes.label}>\n {t(\"Infrequents\")}\n </label>\n <Select key={\"cmbInfrequents\"}\n width={230}\n placeholder={t(\"Infrequents\")}\n value={infrequents?.key}\n onChange={(e) => handleInfrequency(e)}\n colorArrowIcon={\"#5C6477\"}\n items={infrequencyList} />\n </div>\n </Grid>\n <Grid item xs={3}>\n <div className={classes.root}>\n <StatusIcon status={CustomerFrequencyType.Inactive} className={classes.iconLabel} />\n <label className={classes.label}>\n {t(\"Inactives\")}\n </label>\n <Select key={\"cmbInactives\"}\n width={230}\n placeholder={t(\"Inactives\")}\n value={inactives?.key}\n onChange={(e) => handleInactive(e)}\n colorArrowIcon={\"#5C6477\"}\n items={inactiveList} />\n\n </div>\n </Grid>\n <Grid item xs={3}>\n </Grid>\n </Grid>\n </Box>\n </div>\n )\n}\n\nexport default CustomerClassification;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n root: {\n backgroundColor: \"gray\"\n },\n title: {\n fontFamily: \"Inter\",\n fontSize: \"14px\",\n color: Color.gray5,\n marginBottom: 10,\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n },\n titleSection: {\n fontFamily: \"Inter\",\n fontSize: \"14px\",\n color: Color.gray4,\n marginBottom: 20,\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n },\n divArea: {\n backgroundColor: \"#fff\",\n borderRadius: 20,\n border: \"1px solid #dbdcdd\",\n padding: \"40px 40px 51px 40px\",\n margin: \"10px 0\"\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n margin: \"24px 0px 0px 0px\",\n },\n label: {\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#919CA5\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n labelSecondary: {\n fontFamily: \"Roboto,sans serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n required: {\n color: \"#6462F3\",\n marginLeft: 5,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n optional: {\n marginLeft: 3,\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#919CA5\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n description: {\n margin: 0,\n color: \"#919CA5\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n },\n iconMoney: {\n color: theme.colors.clearMain,\n paddingTop: 4,\n fontSize: 22,\n fontWeight: \"bolder\"\n },\n iconSuggestedServices: {\n color: \"#6462F3\",\n fontSize: 22,\n fontWeight: \"bolder\",\n height: \"24px !important\",\n width: \"24px !important\"\n },\n iconCalendarCancel: {\n color: \"#6462F3\",\n fontSize: 17,\n fontWeight: \"bolder\"\n },\n iconEdit: {\n color: \"#6462F3\",\n paddingTop: 4,\n paddingLeft: 4,\n fontSize: 22,\n fontWeight: \"bolder\",\n height: \"24px !important\",\n width: \"24px !important\"\n },\n iconListMark: {\n color: \"#6462F3\",\n paddingTop: 4,\n paddingLeft: 4,\n fontSize: 22,\n fontWeight: \"bolder\",\n height: \"24px !important\",\n width: \"24px !important\"\n },\n iconEye: {\n color: \"#6462F3\",\n paddingTop: 9,\n paddingLeft: 6,\n fontSize: 22,\n fontWeight: \"bolder\",\n height: \"29px !important\",\n width: \"29px !important\"\n },\n iconInCheck: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n width: 45,\n paddingLeft: 5\n },\n labelH2: {\n fontFamily: \"Roboto, sans-serif\",\n display: \"flex\",\n paddingTop: 7,\n color: \"#5C6477\",\n fontSize: \"14px\",\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n inputClass: {\n ...theme.typography.body2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"normal\",\n opacity: 0.4,\n }\n },\n inputTextareaClass: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n fontWeight: \"normal\",\n opacity: 0.8,\n }\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 5px\",\n display: \"inline-flex\",\n verticalAlign: \"middle\"\n },\n switchRoot: {\n width: 32,\n height: 21,\n padding: 0,\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: Color.white,\n \"& + .MuiSwitch-track\": {\n opacity: 0.3,\n border: \"none\",\n backgroundColor: Color.green,\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n //\n },\n \"&.Mui-checked:not(.Mui-disabled)\": {\n \"& + .MuiSwitch-track\": {\n opacity: 1,\n }\n },\n \"&$focusVisible .MuiSwitch-thumb\": {\n color: \"#6462F3\",\n border: \"6px solid #fff\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n switchThumb: {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n switchTrack: {\n borderRadius: 23 / 2,\n border: \"3px solid #323947\",\n backgroundColor: theme.palette.grey[50],\n opacity: 1,\n // .MuiSwitch-track\n },\n switchChecked: {},\n focusVisible: {},\n rowWeekDays: {\n height: 60\n },\n dayLabel: {\n width: 100,\n color: Color.gray5,\n fontSize: \"14px\",\n display: \"inline\",\n fontWeight: \"bold\"\n },\n headerLabel: {\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\"\n },\n divider: {\n borderTop: \"1px solid\",\n borderColor: \"#F0F0F0\",\n marginTop: \"24px\",\n marginBottom: \"24px\",\n },\n paymentMethodsTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: theme.colors.grey4,\n },\n paymentLabel: {\n fontFamily: \"Inter, sans-serif\",\n display: \"flex\",\n color: theme.colors.grey5,\n fontSize: \"14px\",\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n paddingLeft: \"5px\",\n paddingTop: \"5px\"\n },\n logoSection: {\n width: \"100%\",\n textAlign: \"center\",\n paddingTop: 5,\n height: 150\n },\n divLogo: {\n width: 120,\n height: 120,\n borderRadius: \"50%\",\n backgroundColor: \"#6462F3\",\n margin: \"auto\",\n position: \"relative\",\n cursor: \"pointer\"\n },\n divLogoIcon: {\n zIndex: 2,\n position: \"absolute\",\n height: \"100%\"\n },\n logoIconClear: {\n width: \"70%\",\n height: \"100%\",\n margin: \"auto\",\n fontSize: 70,\n color: \"#F6F6F6\",\n },\n divLogoIconHover: {\n zIndex: 3,\n position: \"absolute\",\n width: 120,\n height: 120,\n borderRadius: \"50%\",\n margin: \"auto\",\n opacity: 0,\n \"&:hover\": {\n background: \"rgba(29, 32, 39, 0.7)\",\n display: \"flow-root\",\n opacity: 0.7\n }\n },\n iconCam: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n },\n labelChangePhoto: {\n marginTop: 5,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n opacity: 1\n },\n photosEstablishmentRow: {\n marginTop: 10,\n display: \"table\",\n width: \"100%\",\n tableLayout: \"fixed\",\n textAlign: \"center\"\n },\n photosEstablishmentCol: {\n display: \"inline-grid\",\n //marginRight: 30,\n \"&:first-child\": {\n float: \"left\"\n },\n \"&:last-child\": {\n float: \"right\"\n }\n },\n photoEstablishment: {\n width: 230,\n height: 120,\n backgroundColor: \"#F6F6F6\",\n border: \"1px dashed #DBDCDD;\",\n borderRadius: 12,\n cursor: \"pointer\",\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\",\n backgroundPosition: \"center top\",\n },\n iconPlus: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: theme.colors.clearMain\n },\n labelAddPhoto: {\n marginTop: 0,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#919CA5\"\n },\n labelAddPhotoIns: {\n marginTop: -5,\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 9,\n color: \"#919CA5\",\n textAlign: \"center\",\n },\n photosEstablishmentControls: {\n textAlign: \"right\",\n paddingTop: 5,\n paddingRight: 5\n },\n iconCamera: {\n color: \"#919CA5\",\n fontSize: 20,\n cursor: \"pointer\",\n marginLeft: 10,\n marginTop: 3,\n\n },\n iconTrash: {\n color: \"#919CA5\",\n fontSize: 24,\n cursor: \"pointer\",\n marginLeft: 10,\n },\n selectStyle: {\n color: Color.gray5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 327,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: Color.gray5,\n cursor: \"pointer\",\n },\n },\n selectHrs: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n // marginBottom: \"2px\",\n position: \"absolute\",\n color: Color.gray5,\n \"@media (max-width: 960px)\": {\n marginBottom: \"2px\",\n }\n },\n },\n selectHrsClose: {\n \"& div:after\": {\n content: \"'hrs'\",\n color: \"rgba(0, 0, 0, 0.25)\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n \"@media (max-width: 960px)\": {\n marginBottom: \"2px\",\n }\n },\n },\n selectStyleHrs: {\n position: \"relative\",\n top: 1,\n left: -150,\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n },\n selectHr: {\n \"& div:after\": {\n content: \"'hr'\",\n marginLeft: \"35px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n \"@media (max-width: 2150px)\": {\n marginBottom: \"4px\",\n },\n \"@media (max-width: 1950px)\": {\n marginBottom: \"2px\",\n },\n \"@media (max-width: 1750px)\": {\n marginBottom: \"0\",\n },\n \"@media (max-width: 1600px)\": {\n marginBottom: \"1px\",\n },\n },\n },\n selectMin: {\n \"& div:after\": {\n content: \"'min'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n flexContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n width: \"90%\"\n\n },\n copyLinkButton: {\n width: \"100%\",\n marginTop: 32,\n },\n iconTooltipRoot: {\n display: \"inline-block\",\n marginLeft: 5,\n \"&>div\": {\n maxWidth: 300\n }\n },\n titleWithTooltipContainer: {\n display: \"flex\",\n flexDirection: \"row\"\n },\n selectContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 6\n },\n terminologyButton: {\n \"&.MuiButton-root\": {\n minWidth: 0,\n marginLeft: 5,\n padding: 0,\n height: 15,\n \"& svg\": {\n height: \"18px !important\",\n width: \"18px !important\"\n }\n },\n },\n certsTerminologyButton: {\n \"&.MuiButton-root\": {\n minWidth: 0,\n marginTop: 3,\n height: 15,\n \"& svg\": {\n height: \"18px !important\",\n width: \"18px !important\"\n }\n },\n },\n optionalLabel: {\n fontWeight: \"normal\",\n marginLeft: 3\n },\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n}));\n\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n display: \"flex\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"73%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {\n fontFamily: \"Inter, sans-serif\",\n },\n bodyContent: {\n color: theme.colors.grey5,\n textAlign: \"center\"\n },\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n width: \"60px\",\n height: \"60px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n modalTitleSpace: {\n margin: \"30px 0px 20px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n marginTop: 32,\n justifyContent: \"center\",\n textAlign: \"center\"\n },\n button: {\n width: 196,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n margin: \"auto\"\n },\n btnCancel: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n btnOk: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n \"&.Mui-disabled\": {\n background: \"rgba(54, 206, 145, 0.5)\",\n color: \"white\"\n }\n },\n separator: {\n height: 0,\n margin: \"0px auto 20px auto\",\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n },\n \n termContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n height: 57,\n width: \"100%\",\n },\n termTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray7\n },\n termEditNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\" ,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5 + \" !important\"\n },\n termButtonsContainer: {\n display: \"flex\"\n },\n termButton: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n },\n closeConfirmationModal: {\n height: \"234px + !important\",\n width: 660\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\"\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n}));\n\nexport default useStyles;","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { setAccountSettings } from \"../../../redux/account-settings-slice\";\nimport { setEstablishmentSettings } from \"../../../redux/establishment-settings-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings, selectEstablishmentSettings } from \"../../../redux/store\";\n\nimport { Backdrop, Button, Fade, Grid, Modal, Typography } from \"@material-ui/core\";\n\nimport { EditTerminologyModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { AccountService } from \"../../../api/account-service\";\nimport { Terminology } from \"../../../models/terminology\";\nimport BroadcastIcon from \"../../../assets/icons/BroadcastIcon\";\nimport {\n CrossIcon,\n SectionEditIcon,\n SectionExitEditIcon,\n SectionSaveIcon\n} from \"../../../assets/icons\";\nimport Input from \"../Input\";\nimport ConfirmActionModal from \"../ConfirmActionModal\";\n\n\nexport default function EditTerminologyModal(props: EditTerminologyModalProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { isOpen, setOpen, type, isSingleFieldOnly } = props;\n \n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n const dispatch = useAppDispatch();\n \n const maxTextFieldLength = 200;\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const establishmentSettings = useAppSelector(selectEstablishmentSettings);\n\n const [initialState, setInitialState] = useState<string>(\"\");\n const [terminology, setTerminology] = useState<Terminology>(new Terminology());\n \n const [singularTerm, setSingularTerm] = useState<string>(\"\");\n const [singularTermHover, setSingularTermHover] = useState<boolean>(false);\n const [isSingularTermEditMode, setSingularTermEditMode] = useState<boolean>(false);\n const [pluralTerm, setPluralTerm] = useState<string>(\"\");\n const [pluralTermHover, setPluralTermHover] = useState<boolean>(false);\n const [isPluralTermEditMode, setPluralTermEditMode] = useState<boolean>(false);\n const [cancelEditModalIsOpen, setCancelEditModalIsOpen] = useState<boolean>(false);\n \n useEffect(() => {\n async function fetchData() {\n const terminology = await AccountService.getAccountTerminology(type, settingsSelectedEstablishmentId);\n setInitialState(JSON.stringify(terminology));\n setTerminology(terminology);\n }\n \n if (isOpen) {\n void fetchData();\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId, isOpen]);\n \n const handleOnClose = () => {\n if (canSave()){\n setCancelEditModalIsOpen(true);\n } else {\n setOpen(false);\n setTerminology(new Terminology());\n }\n };\n \n const handleSaveButtonClick = async () => {\n await AccountService.updateAccountTerminology(terminology, settingsSelectedEstablishmentId);\n\n const currentSettings = settingsSelectedEstablishmentId ? establishmentSettings : accountSettings;\n\n const newTerms = currentSettings.terminologies.map(t =>\n t.terminologyType === type ? terminology : t\n );\n\n const updatedSettings = {\n ...currentSettings,\n terminologies: newTerms\n };\n\n const action = settingsSelectedEstablishmentId ? setEstablishmentSettings : setAccountSettings;\n dispatch(action(updatedSettings));\n\n setOpen(false);\n };\n \n const canSave = () => {\n return initialState !== JSON.stringify(terminology);\n }\n \n const singularTermHandleOnChange = (event: React.ChangeEvent<{ value: string }>) => {\n const val = event.target.value;\n if (val.length > maxTextFieldLength) {\n return;\n }\n setSingularTerm(val);\n if (isSingleFieldOnly) {\n setPluralTerm(val);\n }\n };\n \n const handleEditSingularTerm = async () => {\n setSingularTermEditMode(false);\n if (terminology.singularForm === singularTerm.trim() || singularTerm.trim().length === 0) {\n return;\n }\n if (isSingleFieldOnly) {\n setTerminology({ ...terminology, singularForm: singularTerm, pluralForm: singularTerm });\n } else {\n setTerminology({ ...terminology, singularForm: singularTerm });\n }\n };\n \n const handleExitEditSingularTerm = () => {\n setSingularTermEditMode(false);\n }\n \n const handleEditSingularTermButtonClick = () => {\n setSingularTerm(terminology.singularForm);\n setSingularTermEditMode(true);\n }\n \n const getSaveSingularTermButton = () => {\n if (isSingularTermEditMode)\n return (<Button\n key={\"saveButton\"}\n onClick={async () => await handleEditSingularTerm()}\n className={classes.termButton}\n >\n <SectionSaveIcon />\n </Button>);\n return <></>;\n };\n \n const getExitEditSingularTermButton = () => {\n if (isSingularTermEditMode)\n return (<Button\n onMouseDown={() => handleExitEditSingularTerm()}\n className={classes.termButton}\n >\n <SectionExitEditIcon />\n </Button>);\n return <></>;\n };\n \n const getEditSingularTermButton = () => {\n return (<Button\n key={\"editButton\"}\n onClick={() => handleEditSingularTermButtonClick()}\n className={classes.termButton}\n >\n <SectionEditIcon />\n </Button>);\n };\n \n const getSingularTermButtons = () => {\n if (isSingularTermEditMode) {\n return (\n <>\n {getSaveSingularTermButton()}\n {getExitEditSingularTermButton()}\n </>\n );\n }\n return (\n <>\n {getEditSingularTermButton()}\n </>\n );\n };\n \n const pluralTermHandleOnChange = (event: React.ChangeEvent<{ value: string }>) => {\n const val = event.target.value;\n if (val.length > maxTextFieldLength) {\n return;\n }\n setPluralTerm(val);\n };\n \n const handleEditPluralTerm = async () => {\n setPluralTermEditMode(false);\n if (terminology.pluralForm === pluralTerm.trim() || pluralTerm.trim().length === 0) {\n return;\n }\n setTerminology({ ...terminology, pluralForm: pluralTerm });\n };\n \n const handleExitEditPluralTerm = () => {\n setPluralTermEditMode(false);\n }\n \n const handleEditPluralTermButtonClick = () => {\n setPluralTerm(terminology.pluralForm);\n setPluralTermEditMode(true);\n }\n \n const getSavePluralTermButton = () => {\n if (isPluralTermEditMode)\n return (<Button\n key={\"saveButton\"}\n onClick={async () => await handleEditPluralTerm()}\n className={classes.termButton}\n >\n <SectionSaveIcon />\n </Button>);\n return <></>;\n };\n \n const getExitEditPluralTermButton = () => {\n if (isPluralTermEditMode)\n return (<Button\n onMouseDown={() => handleExitEditPluralTerm()}\n className={classes.termButton}\n >\n <SectionExitEditIcon />\n </Button>);\n return <></>;\n };\n \n const getEditPluralTermButton = () => {\n return (<Button\n key={\"editButton\"}\n onClick={() => handleEditPluralTermButtonClick()}\n className={classes.termButton}\n >\n <SectionEditIcon />\n </Button>);\n };\n \n const getPluralTermButtons = () => {\n if (isPluralTermEditMode) {\n return (\n <>\n {getSavePluralTermButton()}\n {getExitEditPluralTermButton()}\n </>\n );\n }\n return (\n <>\n {getEditPluralTermButton()}\n </>\n );\n };\n \n const CloseModalContent: React.FC = () => {\n return (\n <div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {t(\"Are you sure you want to cancel the term modification?\")}\n </Typography>\n <div className={classes.separator}/>\n <Typography className={classes.closeModalContentText}>\n {t(\"Changes made will not be saved.\")}\n </Typography>\n </div>\n );\n };\n \n const handleCloseEdit = () => {\n setCancelEditModalIsOpen(false);\n setOpen(false);\n setTerminology(new Terminology());\n };\n \n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={isOpen}\n onClose={handleOnClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n \n <Fade in={isOpen}>\n <div className={classes.modalPaperYellow}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <BroadcastIcon/>\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={handleOnClose}>\n <CrossIcon/>\n </span>\n </div>\n </div>\n \n <div className={classes.modalContent}>\n \n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n { isSingleFieldOnly\n ? t(\"Type the term you want to use\")\n : t(\"Choose the term you want to modify\")}\n </Typography>\n </div>\n \n <div className={classes.separator}></div>\n \n <div className={classes.bodyContent}>\n <Grid item\n className={classes.termContainer}\n onMouseEnter={() => { setSingularTermHover(true) }}\n onMouseLeave={() => { setSingularTermHover(false) }} >\n {!isSingularTermEditMode\n ? <Typography className={classes.termTitle}>\n {terminology.singularForm}\n </Typography>\n \n : <Input\n inputClass={classes.termEditNameInput}\n value={singularTerm}\n isValid={() => { return singularTerm.trim().length > 0 && singularTerm.length <= maxTextFieldLength }}\n onChange={(event) => singularTermHandleOnChange(event)}\n onBlur={async () => await handleEditSingularTerm()}\n disabled={!isSingularTermEditMode}\n maxLength={maxTextFieldLength}\n width={\"75%\"}\n autoFocus\n />}\n {singularTermHover || isSingularTermEditMode\n ? <div className={classes.termButtonsContainer}>\n {getSingularTermButtons()}\n </div>\n : <></>}\n </Grid>\n \n {isSingleFieldOnly !== true &&\n <Grid item\n className={classes.termContainer}\n onMouseEnter={() => { setPluralTermHover(true) }}\n onMouseLeave={() => { setPluralTermHover(false) }} >\n {!isPluralTermEditMode\n ? <Typography className={classes.termTitle}>\n {terminology.pluralForm}\n </Typography>\n \n : <Input\n inputClass={classes.termEditNameInput}\n value={pluralTerm}\n isValid={() => { return terminology.pluralForm.trim().length > 0 && terminology.pluralForm.length <= maxTextFieldLength }}\n onChange={(event) => pluralTermHandleOnChange(event)}\n onBlur={async () => await handleEditPluralTerm()}\n disabled={!isPluralTermEditMode}\n maxLength={maxTextFieldLength}\n width={\"75%\"}\n autoFocus\n />}\n {pluralTermHover || isPluralTermEditMode\n ? <div className={classes.termButtonsContainer}>\n {getPluralTermButtons()}\n </div>\n : <></>}\n </Grid>\n }\n </div>\n \n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.btnCancel}`} onClick={handleOnClose}>\n {t(\"Go back\")}\n </Button>\n <Button className={`${classes.button} ${classes.btnOk}`} onClick={handleSaveButtonClick} disabled={!canSave()}>\n {t(\"Save\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<CloseModalContent />}\n open={cancelEditModalIsOpen}\n onClose={() => setCancelEditModalIsOpen(false)}\n onConfirm={handleCloseEdit}\n />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n tinyMceOverrides: {\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n position: \"relative\",\n padding: \"15px 0px 15px 0px\",\n\n \"& div.tox-tinymce\": {\n ...theme.typography.body2,\n color: theme.colors.grey5,\n backgroundColor: theme.colors.grey1,\n },\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n tinyMceInvalid: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: Color.red +\" !important\"\n }\n },\n charCounter: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"10px\",\n lineHeight: \"12px\",\n position: \"absolute\",\n right: 20,\n paddingLeft: \"629px\",\n marginTop: \"-18px\",\n color: theme.colors.grey5\n },\n charCounterInvalid: {\n color: theme.colors.clearRed\n },\n urlWarning: {\n position: \"absolute\",\n paddingLeft: \"656px\",\n marginTop: \"-198px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from 'react';\n\nimport { Editor } from \"@tinymce/tinymce-react\";\n\nimport { HtmlTextAreaProps } from \"./props\";\nimport useStyles from \"./css\";\n\n\nexport default function HtmlTextArea(props: HtmlTextAreaProps) {\n\n const { text, setText, maxLength, onBlur } = props;\n\n const classes = useStyles();\n\n const [focused, setFocused] = useState<boolean>(false);\n const [textLength, setTextLength] = useState<number>(0);\n\n function getTextInitialValue(): string {\n if (!text || text === \"\") {\n return \"\";\n }\n return text;\n }\n\n useEffect(() => {\n setText(getTextInitialValue())\n }, [])\n\n function setLength(evt: any, editor: any) {\n setTextLength(editor.getContent({ format: \"text\" }).length);\n }\n\n const handleEditorChange = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n\n if (contentText.length > maxLength) {\n return;\n }\n\n setText(contentHtml);\n setTextLength(contentText.length);\n }\n\n function handleFocusOut() {\n setFocused(false)\n onBlur?.();\n }\n\n return (\n <div className={`${classes.tinyMceOverrides} ${textLength === 0\n ? classes.tinyMceInvalid\n : (focused\n ? classes.tinyMceFocused\n : classes.tinyMceUnfocused)}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: 790,\n menubar: false,\n statusbar: false,\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist styleselect ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, u\",\n invalid_elements: \"strong, em, span\",\n remove_linebreaks: true,\n setup: (editor) => {\n editor.on(\"keydown\", (e) => {\n //without the next block, the cursor will lose its position immediately after the text becomes invalid\n if (textLength > maxLength) {\n editor.focus();\n editor.selection.select(editor.getBody(), true);\n editor.selection.collapse(false);\n }\n });\n }\n }}\n value={text}\n onFocusIn={() => setFocused(true)}\n onFocusOut={handleFocusOut}\n onInit={setLength}\n onEditorChange={handleEditorChange}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLength >= maxLength) {\n e.preventDefault();\n }\n }}\n />\n <span className={`${classes.charCounter} ${textLength > maxLength ? classes.charCounterInvalid : \"\"}`}>{textLength + \"/\" + maxLength}</span>\n </div>\n )\n}","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function CertificationImageIcon (props: any) {\n\n const { style, width, height, ...otherProps } = props;\n\n return (\n <SvgIcon\n {...otherProps}\n style={{ width: width ?? 25, height: height ?? 25 }}\n viewBox=\"0 0 25 25\"\n >\n <path\n d=\"M18.8599 19.5547C19.6724 19.5547 20.3599 18.7891 20.3599 17.8047V7.30469C20.3599 6.35677 19.6724 5.55469 18.8599 5.55469H5.85986C5.01611 5.55469 4.35986 6.35677 4.35986 7.30469V17.8047C4.35986 18.7891 5.01611 19.5547 5.85986 19.5547H18.8599ZM7.85986 7.59635C8.79736 7.59635 9.60986 8.54427 9.60986 9.63802C9.60986 10.7682 8.79736 11.6797 7.85986 11.6797C6.89111 11.6797 6.10986 10.7682 6.10986 9.63802C6.10986 8.54427 6.89111 7.59635 7.85986 7.59635ZM6.35986 17.2214V15.4714L8.57861 12.8828C8.73486 12.7005 8.95361 12.7005 9.10986 12.8828L10.8599 14.888L15.0786 9.96615C15.2349 9.78385 15.4536 9.78385 15.6099 9.96615L18.3599 13.138V17.2214H6.35986Z\"\n fill=\"#6462F3\"\n />\n </SvgIcon>\n )\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\n\nexport const useStyles = makeStyles((theme) => ({\n addCertificationsContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 100,\n marginTop: 15,\n marginLeft: 50\n },\n certificationsNotesContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n alignItems: \"flex-start\",\n width: 430,\n height: 42,\n },\n deleteButton: { \n minWidth: 16,\n height: 16,\n },\n addButton: {\n ...theme.typography.buttons,\n fontWeight: 700,\n color: theme.colors.clearMain,\n minWidth: 162,\n height: 24,\n borderRadius: 5,\n padding: \"11px 16px\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n border: \"solid\",\n justifyContent: \"space-around\",\n \"&:disabled\": {\n color: theme.colors.grey4,\n borderColor: theme.colors.grey4,\n opacity: 0.3\n }\n },\n addButtonItems: {\n width: \"100%\",\n display: \"flex\",\n justifyContent: \"space-around\",\n alignItems: \"center\",\n gap: 10\n },\n notesBoldText: {\n fontFamily: \"Roboto,sans serif\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey5\n },\n notesText: {\n fontFamily: \"Roboto,sans serif\",\n fontWeight: 400,\n fontSize: 12,\n color: theme.colors.grey5\n },\n certificationsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n minWidth: 162,\n maxWidth: 180,\n },\n certificationHiddenContainer: {\n display: \"none\"\n },\n certificationContainer: {\n display: \"flex\",\n height: 24,\n padding: \"8px 16px\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n marginBottom: 4,\n backgroundColor: \"#FAFAFA\"\n },\n certificationName: {\n fontFamily: \"Roboto,sans serif\",\n color: theme.colors.grey4,\n fontSize: 10,\n fontWeight: 700,\n overflow: \"hidden\",\n wordWrap: \"break-word\",\n display: \"-webkit-box\",\n WebkitBoxOrient: \"vertical\",\n WebkitLineClamp: 1,\n },\n modalDelete: {\n height: 220\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalTitleText: {\n fontSize: 18,\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: theme.colors.grey7\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n margin: \"24px 0px 0px 0px\",\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 5px\",\n display: \"inline-flex\",\n verticalAlign: \"middle\"\n },\n switchRoot: {\n width: 32,\n height: 21,\n padding: 0,\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: Color.white,\n \"& + .MuiSwitch-track\": {\n opacity: 0.3,\n border: \"none\",\n backgroundColor: Color.green,\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n //\n },\n \"&.Mui-checked:not(.Mui-disabled)\": {\n \"& + .MuiSwitch-track\": {\n opacity: 1,\n }\n },\n \"&$focusVisible .MuiSwitch-thumb\": {\n color: \"#6462F3\",\n border: \"6px solid #fff\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n switchThumb: {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n switchTrack: {\n borderRadius: 23 / 2,\n border: \"3px solid #323947\",\n backgroundColor: theme.palette.grey[50],\n opacity: 1,\n // .MuiSwitch-track\n },\n switchChecked: {},\n focusVisible: {},\n rowWeekDays: {\n height: 60\n },\n iconInCheck: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n width: 45,\n paddingLeft: 5\n },\n labelH2: {\n fontFamily: \"Roboto, sans-serif\",\n display: \"flex\",\n paddingTop: 7,\n color: \"#5C6477\",\n fontSize: \"14px\",\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n}));\n\n","import React, { useState, useRef, useEffect } from \"react\";\n\nimport { useTranslation } from 'react-i18next';\n\nimport useTerminology from \"../../../hooks/useTerminology\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport { CircularProgress } from \"@material-ui/core\";\n\nimport { useStyles } from \"./css\";\nimport { CertificationsProps } from \"./props\";\nimport { EstablishmentCertification } from \"../../../models/establishment-certification\";\nimport { DeleteIcon, PlusIcon } from \"../../../assets/icons\";\nimport ConfirmDeleteModal from \"../ConfirmDeleteModal\";\nimport CertificationImageIcon from \"../../../assets/icons/CertificationImageIcon\";\nimport Switch from \"../Switch\";\nimport { TerminologyType } from \"../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../models/enums/terminology-form\";\n\n\nexport default function Certifications(props: CertificationsProps) {\n\n const { certifications, showCertifications, handleShowCertificationsChange, handleCertificationDelete, handleCertificationUpload } = props;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const certsTerminology: string = useTerminology({ type: TerminologyType.Certification, form: TerminologyForm.Plural });\n const certTerminology: string = useTerminology({ type: TerminologyType.Certification, form: TerminologyForm.Singular });\n\n const [showCertificationsShadow, setShowCertificationsShadow] = useState<boolean>(showCertifications);\n\n const [openDeleteDialog, setOpenDeleteDialog] = useState<boolean>(false);\n const [certToDelete, setCertToDelete] = useState<EstablishmentCertification | null>(null);\n\n const [openFileDialog, setOpenFileDialog] = useState<boolean>(false);\n const [isFileLoading, setIsFileLoading] = useState<boolean>(false);\n\n const fileInputTypes = ['image/jpeg', 'image/jpg', 'image/png'];\n const fileInputRef = useRef<HTMLInputElement>(null);\n\n useEffect(() => {\n setShowCertificationsShadow(showCertifications);\n }, [showCertifications]);\n\n useEffect(() => {\n if (openFileDialog) {\n showOpenFileDialog();\n setOpenFileDialog(false);\n }\n }, [openFileDialog]);\n\n async function handleFileInputChange(e: React.FormEvent<HTMLInputElement>) {\n const files = fileInputRef.current?.files;\n const file = files ? files[0] : null;\n\n setIsFileLoading(true);\n\n if (file && fileInputTypes.includes(file.type)) {\n await handleCertificationUpload(file);\n }\n\n setIsFileLoading(false);\n\n if (fileInputRef.current) {\n fileInputRef.current.value = \"\";\n }\n }\n\n function showOpenFileDialog() {\n fileInputRef.current?.click();\n }\n\n function confirmDelete(cert: EstablishmentCertification) {\n setOpenDeleteDialog(true);\n setCertToDelete(cert);\n }\n\n async function handleDelete(cert: EstablishmentCertification) {\n handleCertificationDelete(cert);\n\n setOpenDeleteDialog(false);\n }\n function handleSwitchChange(event: any) {\n const value = event.target.checked;\n\n setShowCertificationsShadow(value);\n\n if (!value)\n handleShowCertificationsChange(value, certifications);\n\n setOpenFileDialog(value);\n }\n\n function handleFileInputFocus() {\n setTimeout(() => {\n const selectedFiles = fileInputRef.current?.files || [];\n\n const hasCertsOrFile = (certifications?.length || selectedFiles.length) > 0;\n\n setShowCertificationsShadow(hasCertsOrFile);\n\n if (showCertifications !== hasCertsOrFile) {\n handleShowCertificationsChange(hasCertsOrFile, certifications);\n }\n\n window.removeEventListener('focus', handleFileInputFocus);\n }, 250);\n }\n\n function handleFileInputClick() {\n window.addEventListener('focus', handleFileInputFocus);\n }\n\n return (\n <>\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleSwitchChange}\n value={showCertificationsShadow}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <CertificationImageIcon />\n </div>\n <label className={classes.labelH2}>\n {t(\"Show establishment certifications\", { terminology: certsTerminology.toLowerCase() })}\n </label>\n </div>\n </div>\n </div>\n\n {showCertificationsShadow &&\n <div className={classes.addCertificationsContainer}>\n <div className={classes.certificationsContainer}>\n {certifications.map((cert, index) => (\n <div\n key={index}\n className={cert.imageS3Key ? classes.certificationContainer : classes.certificationHiddenContainer}\n >\n <Typography className={classes.certificationName}>\n {cert.fileName}\n </Typography>\n <Button\n className={classes.deleteButton}\n onClick={() => confirmDelete(cert)}\n >\n <DeleteIcon />\n </Button>\n </div>\n ))}\n\n <input\n ref={fileInputRef}\n type=\"file\"\n style={{ display: 'none' }}\n accept=\"image/jpeg, image/png\"\n onChange={handleFileInputChange}\n onClick={handleFileInputClick}\n onFocus={handleFileInputFocus}\n />\n <Button\n className={classes.addButton}\n onClick={() => showOpenFileDialog()}\n disabled={isFileLoading}\n >\n <div className={classes.addButtonItems}>\n {isFileLoading\n ? (<CircularProgress style={{ width: 10, height: 10, color: 'initial' }} />)\n : <PlusIcon style={{ width: 10, height: 10 }} />\n }\n {t(\"Add certification\", { terminology: certTerminology.toLowerCase() })}\n </div>\n </Button>\n </div>\n <div className={classes.certificationsNotesContainer}>\n <Typography className={classes.notesBoldText}>\n {`${t(\"Notes\")}:`}\n </Typography>\n <Typography className={classes.notesText}>\n {t(\"This image will be displayed on the site for appointments used by customers. Allowed formats for the image: \")}\n <span className={classes.notesBoldText}>{t(\".png or .jpg.\")}</span>\n {t(\" Maximum size: 800px x 800px.\")}\n </Typography>\n </div>\n </div>\n }\n <ConfirmDeleteModal\n classModal={classes.modalDelete}\n open={openDeleteDialog}\n item={certToDelete}\n componentInfo={\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {t(\"Delete this image?\")}\n </Typography>\n </div>\n }\n onClose={() => setOpenDeleteDialog(false)}\n onDelete={handleDelete}\n />\n </>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { Button, Grid } from \"@material-ui/core\";\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\nimport Typography from \"@material-ui/core/Typography\";\nimport { useTranslation } from 'react-i18next';\n\nimport Switch from \"../../../../common/Switch\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport TextareaWithLabel from \"../../../../common/TextareaWithLabel\";\nimport {\n MoneyIcon,\n SuggestedServicesIcon,\n LogoIcon,\n CameraIcon,\n CalendarCancelIcon,\n ArrowDropDownIcon,\n EditIcon,\n ListMarkIcon,\n EyeIcon,\n InfoIcon,\n SectionEditIcon,\n DocumentIcon,\n} from \"../../../../../assets/icons\";\nimport ServicesService from \"../../../../../api/settings-services-service\";\nimport { EstablishmentInfoService } from \"../../../../../api/settings-establishmentinfo-service\";\nimport { EstablishmentInfo, ControlInput, MobileCountry } from \"../../../../../models/establishmentinfo\";\nimport { SettingsFieldUpdate, getEnum } from \"../../../../../models/enums/settings-field-update\";\nimport Weekdays from '../Weekdays'\nimport DropImage from \"../../../../common/DropImage\";\nimport EstablishmentPhotos from \"../EstablishmentPhotos\";\nimport CustomerClassification from \"../CustomerClassification\";\n\nimport InputMobileCode from \"../../../../common/InputMobileCode\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { useStyles } from \"./css\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport Select, { SelectItem } from \"../../../../common/Select\";\nimport { AppointmentTimeIntervalGapMinute } from \"../../../../../models/enums/appointment-time-interval-gap-minute\";\nimport TimeLimitIcon from \"../../../../../assets/icons/TimeLimitIcon\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport EditTerminologyModal from \"../../../../common/EditTerminologyModal\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport HtmlTextArea from \"../../../../common/HtmlTextArea\";\n\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport SectionNote from \"../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\nimport CertificationImageIcon from \"../../../../../assets/icons/CertificationImageIcon\";\nimport Certifications from \"../../../../common/Certifications/certifications\";\nimport { EstablishmentCertification } from \"../../../../../models/establishment-certification\";\nimport { AccountService } from \"../../../../../api/account-service\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner/\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsFill } from \"../../../../../models/enums/button-props-fill\";\n\n\nexport default (props: SettingsEnterpriseProps) => {\n\n const { settingsSelectedEstablishmentId } = props;\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const [establishmentInfo, setEstablishmentInfo] = useState<EstablishmentInfo>(new EstablishmentInfo());\n const [establishmentInfoShadow, setEstablishmentInfoShadow] = useState<EstablishmentInfo>(new EstablishmentInfo());\n const [readOnlyControl, setReadOnlyControl] = useState<ControlInput>(new ControlInput(true));\n const [timeLimitToModifyAppointment, setTimeLimitToModifyAppointment] = useState<moment.Moment>(moment().utcOffset(0).set({\n hour: 1,\n minute: 0,\n second: 0,\n millisecond: 0\n }));\n const [timeLimitPickerIsOpen, setTimeLimitPickerIsOpen] = useState<boolean>(false);\n const [logoURL, setLogoURL] = useState<string>(\"\");\n const [loadComplete, setLoadComplete] = useState<boolean>(false);\n const [smbPhoneNumber, setSmbPhoneNumber] = useState<string>(\"\");\n const [isFiscalIdTerminologyModalOpen, setIsFiscalIdTerminologyModalOpen] = useState<boolean>(false);\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const terminologyAllowCustomerToCancelAppointment = useCustomerTerminology(t(\"Allow the customer to cancel appointment\"), \"customer\");\n const terminologyAllowCustomerToScheduleAppointmentToday = useCustomerTerminology(t(\"Allow the customer to schedule appointments on the current day\"), \"customer\");\n const terminologyAllowCustomerToModifyAppointment = useCustomerTerminology(t(\"Allow the customer to modify appointment\"), \"customer\");\n const fiscalIdTerminology = useTerminology({ type: TerminologyType.FiscalId });\n\n const [isCertsTerminologyModalOpen, setIsCertsTerminologyModalOpen] = useState<boolean>(false); \n const certsTerminology: string = useTerminology({ type: TerminologyType.Certification, form: TerminologyForm.Plural });\n\n const cancellationPoliciesMaxLength: number = 2000;\n\n const ALPHA_NUMERIC_REGEX = /^[a-zA-Z0-9]+$/;\n const timeGapsSelectItems: SelectItem[] = [\n {\n key: AppointmentTimeIntervalGapMinute.Five,\n value: `5 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Ten,\n value: `10 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Fifteen,\n value: `15 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Twenty,\n value: `20 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Thirty,\n value: `30 ${t(\"min\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Sixty,\n value: `1:00 ${t(\"hour\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.Ninety,\n value: `1:30 ${t(\"hours\")}`\n },\n {\n key: AppointmentTimeIntervalGapMinute.HundredTwenty,\n value: `2:00 ${t(\"hours\")}`\n }\n ];\n\n const handleShowPrice = (event: any) => {\n\n let check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n showPrices: check\n });\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n showPrices: check,\n fieldUpd: SettingsFieldUpdate.ShowPrices\n };\n\n saveByEnter(newInfo);\n };\n\n const handleShowSuggestedServices = (event: any) => {\n\n let check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n showSuggestedServices: check\n });\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n showSuggestedServices: check,\n fieldUpd: SettingsFieldUpdate.ShowSuggestedServices\n };\n\n saveByEnter(newInfo);\n };\n\n const handleAllowCancel = (event: any) => {\n\n const check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n allowCustomerToCancelFromSite: check\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n allowCustomerToCancelFromSite: check,\n fieldUpd: SettingsFieldUpdate.allowCustomerToCancelFromSite\n };\n\n saveByEnter(newInfo);\n };\n\n const handleAllowScheduleToday = (event: any) => {\n\n const check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n allowCustomerToScheduleTodayFromSite: check\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n allowCustomerToScheduleTodayFromSite: check,\n fieldUpd: SettingsFieldUpdate.AllowCustomerToScheduleTodayFromSite\n };\n\n saveByEnter(newInfo);\n };\n\n const handleAllowModify = (event: any) => {\n const check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n allowCustomerToModifyFromSite: check\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n allowCustomerToModifyFromSite: check,\n fieldUpd: SettingsFieldUpdate.allowCustomerToModifyFromSite\n };\n\n saveByEnter(newInfo);\n };\n\n const handleRequireSelectSpecialistFromSite = (event: any) => {\n const check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n requireSelectSpecialistFromSite: check\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n requireSelectSpecialistFromSite: check,\n fieldUpd: SettingsFieldUpdate.requireSelectSpecialistFromSite\n };\n\n saveByEnter(newInfo);\n };\n\n const handleShowAnySpecialistFromSite = (event: any) => {\n const check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n showAnySpecialistFromSite: check\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n showAnySpecialistFromSite: check,\n fieldUpd: SettingsFieldUpdate.showAnySpecialistFromSite\n };\n\n saveByEnter(newInfo);\n };\n\n function handleAllowCustomerScheduleSimultaneousServicesChange(event: any) {\n const check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n allowCustomerScheduleSimultaneousServices: check\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n allowCustomerScheduleSimultaneousServices: check,\n fieldUpd: SettingsFieldUpdate.AllowCustomerScheduleSimultaneousServices\n };\n\n saveByEnter(newInfo);\n }\n\n const handleChangeScheduleTimeIntervalGapSetting = (event: any) => {\n const newValue = event.target.value;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n gapBetweenTimeIntervalsFromSite: newValue\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n gapBetweenTimeIntervalsFromSite: newValue,\n fieldUpd: SettingsFieldUpdate.gapBetweenTimeIntervalsFromSite\n };\n\n saveByEnter(newInfo);\n }\n\n const clickTextbox = (e: any) => {\n const { name } = e.target;\n\n setReadOnlyControl({\n ...readOnlyControl,\n [name]: false\n });\n };\n\n function updateOnBlur(e: any) {\n const { name, value } = e.target;\n\n setReadOnlyControl({\n ...readOnlyControl,\n [name]: true\n });\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n fieldUpd: getEnum(name)\n };\n\n return newInfo;\n }\n\n function onBlur(e: any) {\n const { name, value } = e.target;\n\n const newInfo = updateOnBlur(e);\n\n const canSave = handleEmptyRequired(name, value);\n\n if (canSave)\n saveByEnter(newInfo);\n }\n\n function onBlurNotRequired(e: any) {\n const newInfo = updateOnBlur(e);\n\n saveByEnter(newInfo);\n }\n\n const onKeyPress = (e: any) => {\n if (e.which === 13) {\n e.target.blur();\n }\n };\n\n const saveByEnter = (newInfo: EstablishmentInfo) => {\n (async () => {\n if (settingsSelectedEstablishmentId)\n newInfo.accountId = settingsSelectedEstablishmentId;\n await EstablishmentInfoService.updateEstablishmentInfo(newInfo);\n })();\n };\n\n const handleInputChange = (e: any) => {\n const { name, value } = e.target;\n setEstablishmentInfo({\n ...establishmentInfo,\n [name]: value\n });\n };\n\n function handleCancellationPoliciesSet(newValue: string) {\n setEstablishmentInfo({\n ...establishmentInfo, cancellationPolicies: newValue\n });\n }\n\n function handleCancellationPoliciesBlur() {\n if (establishmentInfo.cancellationPolicies &&\n establishmentInfo.cancellationPolicies.trim() !== \"\" &&\n establishmentInfo.cancellationPolicies !== establishmentInfoShadow.cancellationPolicies) {\n const newInfo = { ...establishmentInfo, fieldUpd: SettingsFieldUpdate.CancellationPolicies }\n saveByEnter(newInfo)\n }\n }\n\n const handleInputChangeAlphaNumeric = (e: any) => {\n const { name, value } = e.target;\n if (value && !ALPHA_NUMERIC_REGEX.test(value)) {\n e.preventDefault();\n } else {\n handleInputChange(e);\n }\n };\n\n const handleEmptyRequired = (name: string, value: any): boolean => {\n switch (name) {\n case \"name\": {\n if (value === \"\") {\n setEstablishmentInfo({\n ...establishmentInfo,\n [name]: establishmentInfoShadow.name\n });\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Enter establishment name is required\")\n })\n );\n return false;\n } else if (value === establishmentInfoShadow.name)\n return false;\n\n return true;\n }\n case \"phoneNumber\": {\n if (value === \"\") {\n setEstablishmentInfo({\n ...establishmentInfo,\n mobileCodeIso3: establishmentInfoShadow.mobileCodeIso3,\n phoneNumber: establishmentInfoShadow.phoneNumber\n });\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Capture phone number is required\")\n })\n );\n return false;\n } else if (value === establishmentInfoShadow.phoneNumber)\n return false;\n\n return true;\n }\n case \"address\": {\n if (value === \"\") {\n setEstablishmentInfo({\n ...establishmentInfo,\n [name]: establishmentInfoShadow.address\n });\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Capture address is required\")\n })\n );\n return false;\n } else if (value === establishmentInfoShadow.address)\n return false;\n\n return true;\n }\n case \"addressReferences\": {\n setEstablishmentInfoShadow({\n ...establishmentInfo,\n [name]: value\n });\n if (value === \"\" && value !== establishmentInfoShadow.addressReferences)\n return true;\n else if (value === establishmentInfoShadow.addressReferences)\n return false;\n\n return true;\n }\n case \"cancellationPolicies\": {\n setEstablishmentInfoShadow({\n ...establishmentInfo,\n [name]: value\n });\n if (value === \"\" && value !== establishmentInfoShadow.cancellationPolicies)\n return true;\n\n return value !== establishmentInfoShadow.cancellationPolicies;\n }\n default: {\n return false;\n }\n }\n }\n\n const handleMobileComplete = (codeIso3: string, number: string, valid: boolean) => {\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n fieldUpd: getEnum(\"phonenumber\"),\n mobileCodeIso3: codeIso3,\n mobileCountry: new MobileCountry({ iso3: codeIso3 }),\n phoneNumber: number.toString(),\n };\n\n setEstablishmentInfo(newInfo);\n\n if (valid && codeIso3 !== establishmentInfo.mobileCodeIso3)\n saveByEnter(newInfo);\n }\n\n const handleTimeLimitOnOk = (time: moment.Moment) => {\n\n const minutes = (time.hour() * 60) + time.minute();\n\n setTimeLimitToModifyAppointment(time);\n\n setEstablishmentInfo({\n ...establishmentInfo,\n minuteLimitToModifyAppointmentFromSite: minutes\n });\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n minuteLimitToModifyAppointmentFromSite: minutes,\n fieldUpd: SettingsFieldUpdate.minuteLimitToModifyAppointmentFromSite\n };\n\n saveByEnter(newInfo);\n\n setTimeLimitPickerIsOpen(false);\n };\n\n const getTimePickerTimeLimitPostfixClass = () => {\n const postfix = timeLimitToModifyAppointment.hours() > 1 ? \"hrs\" : (timeLimitToModifyAppointment.hours() === 1 ? \"hr\" : \"min\");\n switch (postfix) {\n case \"hrs\":\n return classes.selectHrs;\n case \"hr\":\n return classes.selectHr;\n case \"min\":\n return classes.selectMin;\n }\n }\n\n const handleOpenTimepicker = (openclose: boolean) => {\n setTimeLimitPickerIsOpen(openclose);\n };\n\n const handleBlurMobile = (valid: boolean) => {\n let canSave = true;\n\n if (!valid) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Capture phone number is required\")\n })\n );\n } else if (establishmentInfo.phoneNumber === establishmentInfoShadow.phoneNumber)\n canSave = false;\n\n if (canSave) {\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n fieldUpd: getEnum(\"phonenumber\")\n };\n saveByEnter(newInfo);\n }\n }\n\n const handleLogoUpload = async (files: any) => {\n\n if (files && files.length > 0) {\n\n let data: any = await ServicesService.saveImage(files[0]);\n if (data) {\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n logo: data.fileName,\n fieldUpd: getEnum(\"logo\")\n };\n\n saveByEnter(newInfo);\n }\n }\n\n }\n\n function handleShowCancellationPolicies(event: any) {\n\n let check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n showCancellationPolicies: check\n });\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n showCancellationPolicies: check,\n fieldUpd: SettingsFieldUpdate.ShowCancellationPolicies\n };\n\n saveByEnter(newInfo);\n }\n\n function handleShowEstablishmentCertifications(showCerts: boolean, certs: EstablishmentCertification[]) {\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n showEstablishmentCertifications: showCerts,\n establishmentCertifications: certs,\n };\n\n setEstablishmentInfo(newInfo);\n\n if (showCerts != establishmentInfo.showEstablishmentCertifications) {\n newInfo.fieldUpd = SettingsFieldUpdate.ShowEstablishmentCertifications;\n saveByEnter(newInfo);\n }\n }\n\n function handleShowSpecialistCertifications(event: any) {\n\n let check = event.target.checked;\n\n setEstablishmentInfo({\n ...establishmentInfo,\n showSpecialistCertifications: check\n });\n\n let newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n showSpecialistCertifications: check,\n fieldUpd: SettingsFieldUpdate.ShowSpecialistCertifications\n };\n\n saveByEnter(newInfo);\n }\n\n useEffect(() => {\n if (accountSettings.countries.length) {\n let newEstablishmentInfo = establishmentInfo;\n if (newEstablishmentInfo.mobileCountry) {\n const countries = accountSettings.countries;\n let mobileCode = newEstablishmentInfo.mobileCountry?.iso3 ?? \"MEX\";\n newEstablishmentInfo.mobileCountry.dialDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n newEstablishmentInfo.mobileCountry.dialCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n newEstablishmentInfo.mobileCountry.dialTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n }\n\n setEstablishmentInfo(newEstablishmentInfo);\n }\n\n }, [accountSettings.countries])\n\n useEffect(() => {\n if (!accountSettings.scheduleSimultaneousServicesEnabled) {\n setEstablishmentInfo({\n ...establishmentInfo,\n allowCustomerScheduleSimultaneousServices: false\n });\n\n const newInfo: EstablishmentInfo = {\n ...establishmentInfo,\n allowCustomerScheduleSimultaneousServices: false,\n fieldUpd: SettingsFieldUpdate.AllowCustomerScheduleSimultaneousServices\n };\n\n saveByEnter(newInfo);\n }\n\n }, [accountSettings.scheduleSimultaneousServicesEnabled])\n\n useEffect(() => {\n\n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n\n let establishment: EstablishmentInfo = settingsSelectedEstablishmentId\n ? await EstablishmentInfoService.getEstablishmentInfo(settingsSelectedEstablishmentId)\n : await EstablishmentInfoService.getEstablishmentInfo();\n\n const countries = accountSettings.countries;\n let mobileCode = establishment.mobileCountry?.iso3 ?? \"MEX\";\n if (establishment.mobileCountry && countries.length) {\n establishment.mobileCountry.dialDigits = countries.find(x => x.iso3 === mobileCode)!.dialDigits;\n establishment.mobileCountry.dialCode = countries.find(x => x.iso3 === mobileCode)!.dialCode;\n establishment.mobileCountry.dialTemplate = countries.find(x => x.iso3 === mobileCode)!.dialTemplate.toString();\n }\n\n setEstablishmentInfoShadow(establishment);\n setTimeLimitToModifyAppointment(moment().utcOffset(0).set({\n hour: 0,\n minute: establishment?.minuteLimitToModifyAppointmentFromSite ?? 0,\n second: 0,\n millisecond: 0\n }))\n setEstablishmentInfo(establishment);\n await getImage(establishment.logo);\n dispatch(navbarActions.setShowLoader(false));\n setLoadComplete(true);\n })();\n\n }, [settingsSelectedEstablishmentId])\n\n const getImage = async (fileId: string | null = \"\") => {\n\n if (!fileId) {\n setLogoURL(\"\");\n return;\n }\n\n const data = await ServicesService.getImage(fileId);\n\n if (data)\n setLogoURL(data.fileURL);\n }\n\n const DivLogoEmpty: React.FC = () => {\n return (\n <div className={classes.divLogoIcon}>\n <LogoIcon className={classes.logoIconClear} />\n </div>);\n };\n\n const DivLogoEmptyHover: React.FC = () => {\n return (\n <>\n <div className={classes.divLogoIconHover}>\n <div className={classes.iconCam}>\n <CameraIcon />\n </div>\n <div className={classes.labelChangePhoto}>\n {t(\"upload photo\")}\n </div>\n </div>\n </>);\n };\n\n const handleCopyLink = () => {\n navigator.clipboard.writeText(`https://sitiodereservas.somosclear.com/${accountSettings.siteForFinalCustomersSmbName}`);\n }\n\n async function handleCertificationUpload(file: File) {\n const dataImg = await ServicesService.saveImage(file);\n\n if (dataImg) {\n const newImg = new EstablishmentCertification();\n const newOrder = establishmentInfo.establishmentCertifications.length\n ? Math.max(...establishmentInfo.establishmentCertifications.map(cert => cert.order)) + 1\n : 0;\n\n newImg.imageS3Key = dataImg.fileName;\n newImg.fileName = file.name;\n newImg.order = newOrder;\n newImg.accountId = settingsSelectedEstablishmentId;\n\n const addedCertification = await AccountService.addEstablishmentCertification(newImg);\n\n if (addedCertification?.imageS3Key) {\n\n const certs = [...establishmentInfo.establishmentCertifications, addedCertification];\n const showCerts = true;\n\n handleShowEstablishmentCertifications(showCerts, certs);\n }\n }\n }\n\n async function handleDeleteCertification(cert: EstablishmentCertification) {\n cert.accountId = settingsSelectedEstablishmentId;\n\n const deletedCert = await AccountService.deleteEstablishmentCertification(cert);\n\n if (deletedCert) {\n const certs = establishmentInfo.establishmentCertifications.filter(c => c.id !== cert.id);\n const showCerts = certs.length > 0;\n \n handleShowEstablishmentCertifications(showCerts, certs);\n }\n }\n\n return (!loadComplete ? <></> :\n <>\n <div>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"General\")}\n </Typography>\n </div>\n <SectionNote\n sectionData={SectionNoteData.General}\n />\n </>\n )}\n <div className={classes.title}>\n <Typography className={classes.title}>\n {t(\"General Settings\")}\n </Typography>\n </div>\n <div className={classes.divArea}>\n <div className={classes.titleSection}>\n <Typography className={classes.titleSection}>\n {t(\"Establishment information\")}\n </Typography>\n </div>\n\n <Grid container spacing={5}>\n\n <Grid item xs={4}>\n <Typography className={classes.label}>\n {t(\"Establishment logo\")}\n </Typography>\n\n <span className={classes.optional}>({t(\"Optional\")})</span>\n <br />\n\n <div className={classes.logoSection}>\n\n <DropImage\n classDivUploadImage={classes.divLogo}\n onChange={handleLogoUpload}\n imageURL={logoURL}\n componentShowEmptyHover={<DivLogoEmptyHover />}\n componentShowEmpty={<DivLogoEmpty />}\n />\n\n <div style={{ marginTop: 10 }} className={classes.labelSecondary}>\n {t(\"Max size\")}: <b>800px x 800px</b>\n </div>\n\n </div>\n </Grid>\n\n <Grid item xs={8}>\n <EstablishmentPhotos settingsSelectedEstablishmentId={settingsSelectedEstablishmentId} />\n </Grid>\n\n </Grid>\n\n <Grid container spacing={2} direction={\"column\"} style={{ marginTop: 24 }}>\n\n <Grid item container spacing={4}>\n <Grid item xs={9}>\n <InputWithLabel\n name=\"name\" value={establishmentInfo.name}\n onChange={handleInputChange}\n onKeyPress={onKeyPress}\n inputReadOnly={readOnlyControl.name}\n onClickInput={clickTextbox}\n onBlurInput={onBlur}\n width=\"100%\"\n inputClass={classes.inputClass}\n label={() => (\n <>\n <Typography className={classes.label}>\n {t(\"Establishment name\")}\n </Typography>\n <span className={classes.required}>*</span>\n </>)}\n labelClass={classes.label}\n placeholder={t(\"Enter the name of the establishment\")}\n maxLength={60}\n />\n </Grid>\n <Grid item xs={3} style={{ alignSelf: \"flex-end\" }}>\n <InputMobileCode\n isOptional={false}\n requiredDotClass={classes.required}\n widthSelect={\"100%\"}\n widthList={250}\n label={t(\"WhatsApp\")}\n onChangeComplete={handleMobileComplete}\n codeIso3={establishmentInfo.mobileCountry?.iso3!}\n mobile={establishmentInfo.phoneNumber!}\n onBlur={handleBlurMobile}\n setSmbPhoneNumber={setSmbPhoneNumber}\n />\n </Grid>\n </Grid>\n\n <Grid item container spacing={4}>\n <Grid item xs={9}>\n <InputWithLabel\n name=\"address\" value={establishmentInfo.address}\n onChange={handleInputChange}\n onKeyPress={onKeyPress}\n inputReadOnly={readOnlyControl.address}\n onClickInput={clickTextbox}\n onBlurInput={onBlur}\n width=\"100%\"\n inputClass={classes.inputClass}\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Address\")}\n </Typography>\n <span className={classes.required}>*</span>\n </>)}\n labelClass={classes.label}\n placeholder={t(\"Ex. Hidalgo Av. #123\")}\n maxLength={180}\n />\n </Grid>\n <Grid item xs={3}>\n <InputWithLabel\n name=\"fiscalId\"\n value={establishmentInfo.fiscalId}\n onChange={handleInputChangeAlphaNumeric}\n onKeyPress={onKeyPress}\n inputReadOnly={readOnlyControl.fiscalId}\n onClickInput={clickTextbox}\n onBlurInput={onBlurNotRequired}\n width=\"100%\"\n inputClass={classes.inputClass}\n label={() => (<>\n <Typography className={classes.label}>\n {fiscalIdTerminology}\n </Typography>\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 1 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"It is the identification code of the tax service.\")}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n classNameRoot={classes.iconTooltipRoot}\n />\n <Button\n onClick={(e) => {\n setIsFiscalIdTerminologyModalOpen(true);\n e.preventDefault();\n }}\n className={classes.terminologyButton}\n >\n <SectionEditIcon />\n </Button>\n <span className={classes.optionalLabel}>({t(\"Optional\")})</span>\n <EditTerminologyModal\n isOpen={isFiscalIdTerminologyModalOpen}\n setOpen={setIsFiscalIdTerminologyModalOpen}\n type={TerminologyType.FiscalId}\n isSingleFieldOnly={true}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n </>)}\n labelClass={classes.label}\n maxLength={500}\n />\n </Grid>\n </Grid>\n\n <Grid item container spacing={4}>\n <Grid item xs={9}>\n <TextareaWithLabel\n name=\"addressReferences\" value={establishmentInfo.addressReferences}\n onChange={handleInputChange}\n onKeyPress={onKeyPress}\n inputReadOnly={readOnlyControl.addressReferences}\n onClickInput={clickTextbox}\n onBlurInput={onBlur}\n width=\"100%\"\n showCounter={true}\n inputClass={classes.inputTextareaClass}\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Establishment references\")}\n </Typography>\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>)}\n labelClass={classes.label}\n placeholder={t(\"E.g. Gray color premises, located between Avenue A and Avenue B\")}\n maxLength={180}\n />\n </Grid>\n <Grid item xs={3}>\n <div className={classes.copyLinkButton}>\n <ButtonWithSpinner\n width={\"100%\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n fill={ButtonPropsFill.Outlined}\n innerText={t(\"Copy Site for appts link\")}\n onClick={handleCopyLink}\n />\n </div>\n </Grid>\n </Grid>\n </Grid>\n </div>\n\n <div className={classes.title} style={{ marginTop: 30 }}>\n <Typography className={classes.title}>\n {t(\"Site for appointments\")}\n </Typography>\n </div>\n <div className={classes.divArea} style={{ padding: \"22px 2px 38px 40px\" }}>\n <div className={classes.flexContainer}>\n <div>\n <div className={classes.rowContainer} style={{ gap: 50 }}>\n <div className={classes.selectContainer} style={{ gap: 0 }}>\n <div className={classes.titleWithTooltipContainer}>\n <label className={classes.label}>\n {t(\"Time slot for scheduling an appointment\")}\n </label>\n <IconTooltip\n key={\"gapFromSiteTooltip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Time interval displayed between the options to schedule an appointment\")}\n />\n </div>\n <Select\n key={\"gapFromSiteSelect\"}\n width={254}\n value={establishmentInfo.gapBetweenTimeIntervalsFromSite}\n onChange={(e) => handleChangeScheduleTimeIntervalGapSetting(e)}\n colorArrowIcon={\"#5C6477\"}\n items={timeGapsSelectItems}\n />\n </div>\n <div className={classes.selectContainer}>\n <label className={classes.label}>\n {t(\"Time limit to modify appointments before they start\")}{\" \"}\n </label>\n <div>\n <TimePicker\n onOk={(time) => {\n handleTimeLimitOnOk(time);\n }}\n className={`${classes.selectStyle} ${getTimePickerTimeLimitPostfixClass()}`}\n placeholder=\"HH:mm\"\n inputReadOnly={true}\n showNow={false}\n disabledHours={() => [23]}\n value={timeLimitToModifyAppointment}\n onOpenChange={(e) =>\n handleOpenTimepicker(e)\n }\n format={\"HH:mm\"}\n />\n <ArrowDropDownIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: \"#5C6477\",\n position: \"relative\",\n transform: timeLimitPickerIsOpen\n ? \"rotate(180deg)\"\n : \"rotate(0deg)\",\n }}\n />\n </div>\n </div>\n </div>\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleShowPrice}\n value={establishmentInfo.showPrices}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <MoneyIcon className={classes.iconMoney} style={{ color: \"#6462F3\" }} viewBox=\"-5 0 18 18\" />\n </div>\n <label className={classes.labelH2}>\n {t(\"Show prices of my services\")}\n </label>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleShowSuggestedServices}\n value={establishmentInfo.showSuggestedServices}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <SuggestedServicesIcon className={classes.iconSuggestedServices} style={{ color: \"#6462F3\" }} viewBox=\"-5 0 18 18\" />\n </div>\n <label className={classes.labelH2}>\n {t(\"Show Suggested Services\")}\n </label>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleAllowCancel}\n value={establishmentInfo.allowCustomerToCancelFromSite}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <CalendarCancelIcon className={classes.iconCalendarCancel} />\n </div>\n <Typography className={classes.labelH2}>\n {terminologyAllowCustomerToCancelAppointment}\n </Typography>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleAllowScheduleToday}\n value={establishmentInfo.allowCustomerToScheduleTodayFromSite}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <CalendarCancelIcon className={classes.iconCalendarCancel} />\n </div>\n <Typography className={classes.labelH2}>\n {terminologyAllowCustomerToScheduleAppointmentToday}\n </Typography>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleAllowModify}\n value={establishmentInfo.allowCustomerToModifyFromSite}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <EditIcon viewBox={\"0 0 24 24\"} className={classes.iconEdit} />\n </div>\n <Typography className={classes.labelH2}>\n {terminologyAllowCustomerToModifyAppointment}\n </Typography>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleRequireSelectSpecialistFromSite}\n value={establishmentInfo.requireSelectSpecialistFromSite}\n disabled={!establishmentInfo.showAnySpecialistFromSite}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <ListMarkIcon viewBox={\"0 0 24 24\"} className={classes.iconListMark} />\n </div>\n <Typography className={classes.labelH2}>\n {t(\"Make it required to select a Specialist\")}\n </Typography>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleShowAnySpecialistFromSite}\n value={establishmentInfo.showAnySpecialistFromSite}\n disabled={!establishmentInfo.requireSelectSpecialistFromSite}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <EyeIcon viewBox={\"0 0 24 24\"} className={classes.iconEye} />\n </div>\n <Typography className={classes.labelH2}>\n {t(\"Show Any specialist option\")}\n </Typography>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleAllowCustomerScheduleSimultaneousServicesChange}\n disabled={!accountSettings.scheduleSimultaneousServicesEnabled}\n value={establishmentInfo.allowCustomerScheduleSimultaneousServices}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <TimeLimitIcon viewBox={\"0 0 24 24\"} />\n </div>\n <Typography className={classes.labelH2}>\n {t(\"Allow the customer to schedule simultaneous services\")}\n </Typography>\n </div>\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleShowCancellationPolicies}\n value={establishmentInfo.showCancellationPolicies}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <DocumentIcon />\n </div>\n <label className={classes.labelH2}>\n {t(\"Show cancellation policies\")}\n </label>\n </div>\n </div>\n </div>\n\n {\n establishmentInfo.showCancellationPolicies &&\n <HtmlTextArea\n text={establishmentInfo.cancellationPolicies}\n setText={handleCancellationPoliciesSet}\n maxLength={cancellationPoliciesMaxLength}\n onBlur={handleCancellationPoliciesBlur}\n />\n }\n\n <hr className={classes.divider} />\n <div className={classes.titleWithTooltipContainer}>\n <Typography className={classes.title}>\n {t(certsTerminology)}\n </Typography>\n <IconTooltip\n key={\"gapFromSiteTooltip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Documentation confirming the quality and training of the establishment and its specialists\")}\n />\n <Button\n onClick={() => setIsCertsTerminologyModalOpen(true)}\n className={classes.certsTerminologyButton}\n >\n <SectionEditIcon />\n </Button>\n\n <EditTerminologyModal\n isOpen={isCertsTerminologyModalOpen}\n setOpen={setIsCertsTerminologyModalOpen}\n type={TerminologyType.Certification}\n isSingleFieldOnly={false}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n </div>\n\n <Certifications\n certifications={establishmentInfo.establishmentCertifications}\n showCertifications={establishmentInfo.showEstablishmentCertifications}\n handleShowCertificationsChange={handleShowEstablishmentCertifications}\n\n handleCertificationDelete={handleDeleteCertification}\n handleCertificationUpload={handleCertificationUpload}\n />\n\n <div className={classes.rowContainer}>\n <div className={classes.switch}>\n <Switch\n baseClass={classes.switchBase}\n onChange={handleShowSpecialistCertifications}\n value={establishmentInfo.showSpecialistCertifications}\n />\n <div className={classes.switchLabel}>\n <div className={classes.iconInCheck}>\n <CertificationImageIcon />\n </div>\n <label className={classes.labelH2}>\n {t(\"Show specialist certifications\", { terminology: certsTerminology.toLowerCase() })}\n </label>\n </div>\n </div>\n </div>\n\n </div>\n </div>\n </div>\n\n\n <Weekdays settingsSelectedEstablishmentId={settingsSelectedEstablishmentId} />\n\n <CustomerClassification settingsSelectedEstablishmentId={settingsSelectedEstablishmentId} />\n\n </div>\n\n </>);\n};","export enum PaymentFieldUpdate {\n None = 0,\n Currency = 1,\n IsPaymentCash,\n IsPaymentCard,\n IsPaymentCardMasterCard,\n IsPaymentCardVisa,\n IsPaymentCardOther,\n IsPaymentBankTransfer,\n IsPaymentOxxo, // oxxoCardNumber\n IsPaymentMercadoPago, // hasAcceptedMercadoPagoTerms\n HasWhatsAppPaymentReminderOnAppointmentConfirmation,\n HasWhatsAppPaymentReminderOnAppointmentReminder,\n HasWhatsAppPaymentReminderAfterAppointment, // DaysAfterAppointmentToSendWhatsAppPaymentReminder\n IsCashRegisterActivated, // InitialCashInCashRegister\n IsSendReceiptByWhatsApp\n}\n","export class Currency {\n id: string;\n name: string;\n isoCode: string;\n valueTemplate: string;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id\n this.name = x.name;\n this.isoCode = x.isoCode;\n this.valueTemplate = x.valueTemplate;\n }\n else {\n this.id = \"\";\n this.name = \"\";\n this.isoCode = \"\";\n this.valueTemplate = \"{0}\";\n }\n }\n }","import { BankTransferInfo } from \"./bank-transfer-info\";\nimport { Currency } from \"./currency\";\nimport { PaymentFieldUpdate } from \"./enums/payment-field-update\";\n\nexport class PaymentSettingsModel {\n accountId: string | \"\";\n currencies: Currency[];\n currencyId: string | null;\n isPaymentCash: boolean;\n isPaymentCard: boolean;\n isPaymentCardMasterCard: boolean;\n isPaymentCardVisa: boolean;\n isPaymentCardOther: boolean;\n otherPaymentCardName: string | null;\n isPaymentBankTransfer: boolean;\n bankTransfers: BankTransferInfo[];\n isPaymentOxxo: boolean;\n oxxoCardNumber: string | null;\n isEnabledMercadoPagoByAdmin: boolean;\n isPaymentMercadoPago: boolean;\n hasAcceptedMercadoPagoTerms: boolean;\n mercadoPagoEnabledByAdmin: boolean;\n hasExtraCostMercadoPago: boolean;\n extraPercentage: number | null;\n extraAmount: number | null;\n ivaPercentage: number | null;\n currencyTemplate: string | null;\n hasWhatsAppPaymentReminderOnAppointmentConfirmation: boolean;\n hasWhatsAppPaymentReminderOnAppointmentReminder: boolean;\n hasWhatsAppPaymentReminderAfterAppointment: boolean;\n daysAfterAppointmentToSendWhatsAppPaymentReminder: number | null;\n isCashRegisterActivated: boolean;\n initialCashInCashRegister: number | null;\n fieldUpd: PaymentFieldUpdate;\n isSendReceiptByWhatsApp: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.accountId = x.accountId;\n this.currencies = x.currencies;\n this.currencyId = x.currencyId;\n this.isPaymentCash = x.isPaymentCash;\n this.isPaymentCard = x.isPaymentCard;\n this.isPaymentCardMasterCard = x.isPaymentCardMasterCard;\n this.isPaymentCardVisa = x.isPaymentCardVisa;\n this.isPaymentCardOther = x.isPaymentCardOther;\n this.otherPaymentCardName = x.otherPaymentCardName;\n this.isPaymentBankTransfer = x.isPaymentBankTransfer;\n this.bankTransfers = x.bankTransfers;\n this.isPaymentOxxo = x.isPaymentOxxo;\n this.oxxoCardNumber = x.oxxoCardNumber;\n this.isEnabledMercadoPagoByAdmin = x.isEnabledMercadoPagoByAdmin;\n this.isPaymentMercadoPago = x.isPaymentMercadoPago;\n this.hasAcceptedMercadoPagoTerms = x.hasAcceptedMercadoPagoTerms;\n this.mercadoPagoEnabledByAdmin = x.mercadoPagoEnabledByAdmin;\n this.hasExtraCostMercadoPago = x.hasExtraCostMercadoPago;\n this.extraPercentage = x.extraPercentage;\n this.extraAmount = x.extraAmount;\n this.ivaPercentage = x.ivaPercentage;\n this.currencyTemplate = x.currencyTemplate;\n this.hasWhatsAppPaymentReminderOnAppointmentConfirmation = x.hasWhatsAppPaymentReminderOnAppointmentConfirmation;\n this.hasWhatsAppPaymentReminderOnAppointmentReminder = x.hasWhatsAppPaymentReminderOnAppointmentReminder;\n this.hasWhatsAppPaymentReminderAfterAppointment = x.hasWhatsAppPaymentReminderAfterAppointment;\n this.daysAfterAppointmentToSendWhatsAppPaymentReminder = x.daysAfterAppointmentToSendWhatsAppPaymentReminder || 2;\n this.isCashRegisterActivated = x.isCashRegisterActivated;\n this.initialCashInCashRegister = x.initialCashInCashRegister;\n this.fieldUpd = x.fieldUpd;\n this.isSendReceiptByWhatsApp = x.isSendReceiptByWhatsApp;\n }\n else {\n this.accountId = \"\";\n this.currencies = [];\n this.currencyId = null;\n this.isPaymentCash = false;\n this.isPaymentCard = false;\n this.isPaymentCardMasterCard = false;\n this.isPaymentCardVisa = false;\n this.isPaymentCardOther = false;\n this.otherPaymentCardName = \"\";;\n this.isPaymentBankTransfer = false;\n this.bankTransfers = [];\n this.isEnabledMercadoPagoByAdmin = false;\n this.isPaymentOxxo = false;\n this.oxxoCardNumber = \"\";\n this.isPaymentMercadoPago = false;\n this.hasAcceptedMercadoPagoTerms = false;\n this.mercadoPagoEnabledByAdmin = false;\n this.hasExtraCostMercadoPago = true;\n this.extraPercentage = null;\n this.extraAmount = null;\n this.ivaPercentage = null;\n this.currencyTemplate = null;\n this.hasWhatsAppPaymentReminderOnAppointmentConfirmation = false;\n this.hasWhatsAppPaymentReminderOnAppointmentReminder = false;\n this.hasWhatsAppPaymentReminderAfterAppointment = false;\n this.daysAfterAppointmentToSendWhatsAppPaymentReminder = 2;\n this.isCashRegisterActivated = false;\n this.initialCashInCashRegister = null;\n this.fieldUpd = PaymentFieldUpdate.None;\n this.isSendReceiptByWhatsApp = true;\n }\n }\n}\n\n\n ","import { ApiClient } from \"./api-client\";\nimport { SettingsPaymentTabInfo } from \"../models/settings-payment-tab-info\";\nimport { Currency } from \"../models/currency\";\nimport { PaymentSettingsModel } from \"../models/payment-settings-model\";\nimport { BankTransferInfo } from \"../models/bank-transfer-info\";\n\nexport class SettingsPaymentService {\n\n private static baseUrl: string = \"/paymentsSettings\";\n\n static async getCurrencyList(): Promise<Currency[]> {\n const data = await ApiClient.get(`${this.baseUrl}/GetCurrency`);\n let list: Currency[] = [];\n data.currencies.forEach((item: Currency) => {\n list.push(new Currency(item));\n });\n return list;\n }\n\n static async getPaymentsSettings(establishmentAccountId?: string): Promise<PaymentSettingsModel> {\n let endpoint = `${this.baseUrl}/getPaymentsSettings`;\n if (establishmentAccountId) \n endpoint += `?AccountId=${establishmentAccountId}`;\n\n const data = await ApiClient.get(endpoint);\n \n return new PaymentSettingsModel(data.paymentsSettings);\n }\n\n static saveCurrency(settings: PaymentSettingsModel): Promise<boolean> {\n let payload: any = {\n currencyId: settings.currencyId\n };\n if (settings.accountId)\n payload.accountId = settings.accountId;\n return ApiClient.post(`${this.baseUrl}/saveCurrency`, payload)\n .then(data => data.saved);\n }\n \n static savePaymentsSettings(settings: PaymentSettingsModel): Promise<any> {\n const payload: any = {\n isPaymentCash: settings.isPaymentCash,\n isPaymentCard: settings.isPaymentCard,\n isPaymentCardMasterCard: settings.isPaymentCardMasterCard,\n isPaymentCardVisa: settings.isPaymentCardVisa,\n isPaymentCardOther: settings.isPaymentCardOther,\n otherPaymentCardName: settings.otherPaymentCardName,\n isPaymentBankTransfer: settings.isPaymentBankTransfer,\n isPaymentOxxo: settings.isPaymentOxxo,\n oxxoCardNumber: settings.oxxoCardNumber,\n isPaymentMercadoPago: settings.isPaymentMercadoPago,\n hasAcceptedMercadoPagoTerms: settings.hasAcceptedMercadoPagoTerms,\n hasExtraCostMercadoPago: settings.hasExtraCostMercadoPago\n };\n if (settings.accountId)\n payload.accountId = settings.accountId;\n return ApiClient.post(`${this.baseUrl}/savePaymentsSettings`, payload)\n .then(data => data);\n }\n \n static saveBankTransfer(bank: BankTransferInfo): Promise<BankTransferInfo> {\n return ApiClient.post(`${this.baseUrl}/saveBankTransfer`, bank)\n .then(data => data.bankTransfer);\n }\n \n static deleteBankTransfer(bank: BankTransferInfo): Promise<boolean> {\n return ApiClient.remove(`${this.baseUrl}/deleteBankTransfer?id=${bank.bankTransferId}`)\n .then(data => data.deleted);\n }\n \n static saveWhatsAppPaymentSettings(settings: PaymentSettingsModel): Promise<boolean> {\n const payload: any = {\n hasWhatsAppPaymentReminderOnAppointmentConfirmation: settings.hasWhatsAppPaymentReminderOnAppointmentConfirmation,\n hasWhatsAppPaymentReminderOnAppointmentReminder: settings.hasWhatsAppPaymentReminderOnAppointmentReminder,\n hasWhatsAppPaymentReminderAfterAppointment: settings.hasWhatsAppPaymentReminderAfterAppointment,\n daysAfterAppointmentToSendWhatsAppPaymentReminder: settings.daysAfterAppointmentToSendWhatsAppPaymentReminder,\n isSendReceiptByWhatsApp: settings.isSendReceiptByWhatsApp\n };\n if (settings.accountId)\n payload.accountId = settings.accountId;\n return ApiClient.post(`${this.baseUrl}/saveWhatsAppPaymentSettings`, payload)\n .then(data => data.saved);\n }\n \n static saveCashRegister(settings: PaymentSettingsModel): Promise<boolean> {\n const payload: any = {\n isCashRegisterActivated: settings.isCashRegisterActivated,\n initialCashInCashRegister: settings.initialCashInCashRegister\n };\n if (settings.accountId)\n payload.accountId = settings.accountId;\n return ApiClient.post(`${this.baseUrl}/saveCashRegister`, payload)\n .then(data => data.saved);\n }\n\n}","export class BankTransferInfo {\n accountId: string | null;\n bankTransferId: string | null;\n bankName: string;\n bankTransferType: number | null;\n cardNumber: string | null;\n accountNumber: string | null;\n interbankClabe: string | null;\n index: number;\n bankNameValid: boolean;\n cardNumberValid: boolean;\n interbankClabeValid: boolean;\n accountNumberValid: boolean;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.accountId = x.accountId;\n this.bankTransferId = x.bankTransferId;\n this.bankName = x.bankName;\n this.bankTransferType = x.bankInfoType;\n this.cardNumber = x.cardNumber;\n this.interbankClabe = x.interbankClabe;\n this.index = x.index;\n this.bankNameValid = x.bankNameValid;\n this.cardNumberValid = x.cardNumberValid;\n this.interbankClabeValid = x.interbankClabeValid;\n this.accountNumberValid = x.accountNumberValid;\n this.accountNumber = x.accountNumber;\n }\n else {\n this.accountId = null;\n this.bankTransferId = null;\n this.bankName = \"\";\n this.bankTransferType = 0;\n this.cardNumber = null;\n this.interbankClabe = null;\n this.index = 0;\n this.bankNameValid = true;\n this.cardNumberValid = true;\n this.interbankClabeValid = true;\n this.accountNumberValid = true;\n this.accountNumber = null;\n }\n }\n}","export enum BankTransferType {\n None = 0,\n CardNumberClabe = 1,\n CardNumber,\n Clabe,\n AccountNumber,\n CardNumberAccountNumberClabe\n}\n ","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n block: {\n paddingBottom: 30\n },\n title: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \n marginBottom: 10,\n },\n contentArea: {\n backgroundColor: \"#fff\",\n borderRadius: 20,\n border: \"1px solid #dbdcdd\",\n padding: \"40px 40px 30px 40px\",\n margin: \"10px 0\"\n },\n requiredFieldsHeader: {\n ...theme.typography.buttons,\n color: theme.colors.grey4,\n marginBottom: 20\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n contentColumns: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\"\n },\n contentColumn: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n marginRight: 16\n },\n innerContent: {\n padding: 24\n },\n cashOpeningInput: {\n marginLeft: 48\n },\n creditCardTypes: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n marginLeft: 42,\n marginBottom: 20,\n marginTop: -15\n },\n bankTransfers: {\n marginLeft: 42,\n marginBottom: 20,\n marginTop: -20\n },\n smallVerticalDivider: {\n width: 0,\n height: 16,\n marginLeft: 24,\n marginRight: 15,\n border: \"1px solid\",\n borderColor: theme.colors.grey4\n },\n otherCardTypeInput: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n marginLeft: 9\n },\n cardNumberOxxoInput: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n marginLeft: 9\n },\n checkGroup: {\n \"&:not(:last-child)\": {\n marginBottom: 20\n }\n },\n subtitle: {\n fonFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n color: \"#5C6477\",\n opacity: 0.5\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n },\n infoContentRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"20px 0px 0px 0px\",\n },\n addButton: {\n width: 137,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n border: \"1px solid #6462F3\",\n marginRight: 25,\n color: \"#6462F3\",\n textTransform: \"none\",\n },\n deleteDiv: {\n paddingTop: 25,\n position: \"relative\",\n top: 60,\n left: -35\n },\n deleteButton: {\n \"&:hover\": {\n cursor: \"pointer\",\n },\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalDelete: {\n height: 210\n },\n exclamationModalBody: {\n display: \"flex\",\n justifyContent: \"center\"\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n text: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n textChecked: {\n color: theme.colors.grey5,\n textDecoration: \"none\",\n fontSize: 12\n },\n textNoChecked: {\n color: theme.colors.clearRed,\n textDecoration: \"none\",\n fontSize: 12\n },\n link: {\n marginLeft: 4,\n textDecoration: \"underline\",\n fontWeight: 700,\n },\n checkboxMP: {\n color: theme.colors.clearMain,\n '&.Mui-checked': {\n color: theme.colors.clearMain,\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n checkboxMPRed: {\n color: theme.colors.clearRed,\n '&.Mui-checked': {\n color: theme.colors.clearRed,\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n opacityMid: {\n opacity: \"0.5\"\n },\n opacityTextMid: {\n ...theme.typography.txtBody2,\n opacity: \"0.5\",\n backgroundColor: theme.colors.grey1,\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 230 \n },\n\n\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBackButton: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: theme.colors.grey3,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n position: \"relative\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid\",\n borderColor: theme.colors.clearYellow,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 534,\n height: 260,\n padding: \"16px 24px\",\n },\n closeButton: {\n position: \"absolute\",\n width: 24,\n height: 24,\n top: 18,\n right: 28,\n color: theme.colors.grey4\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\"\n },\n exclamationIcon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: 10,\n marginBottom: 18,\n width: 50,\n height: 50,\n borderRadius: 25,\n borderColor: theme.colors.clearYellow,\n color: theme.colors.clearYellow,\n border: \"1px solid\"\n },\n modalTitle: {\n ...theme.typography.h4,\n fontFamily: \"Inter\",\n fontWeight: \"bold\",\n color: theme.colors.grey7,\n justifySelf: \"center\",\n marginBottom: 24\n },\n modalText: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n modalTextBlock: {\n marginBottom: 24,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\",\n textAlign: \"center\"\n },\n modalFooter: {\n display: \"flex\",\n justifyContent: \"space-evenly\",\n },\n initialCash: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n color: theme.colors.grey4,\n marginBottom: 10\n },\n\n extraCostTitle: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 14,\n color: theme.colors.grey5\n },\n calcExtra: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: theme.colors.grey5,\n marginBottom: 15\n },\n lineExtraCost: {\n width: 330,\n marginTop: 10,\n marginBottom: 10,\n borderTop: \"1px solid #C9CDD3\",\n height: 15,\n },\n boxExtraCost: {\n height: 70,\n display: \"inline-block\",\n textAlign: \"left\"\n },\n boxExtraCostPlus: {\n width: 50,\n display: \"inline-block\",\n textAlign: \"center\",\n color: theme.colors.grey4,\n position: \"relative\",\n top: -10\n },\n inputExtraCost: {\n width: 100,\n padding: \"0 !important\",\n \"& input\": {\n textAlign: \"center\",\n padding: \"0 !important\",\n color: theme.colors.grey4,\n }\n },\n labelExtraCostMain: {\n height: 22,\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 18,\n color: \"#919CA5\"\n },\n labelExtraCost: {\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12,\n color: theme.colors.grey4\n },\n infoIcon: {\n color: theme.colors.grey5,\n marginLeft: 5,\n width: 8,\n height: 8,\n minWidth: 8,\n cursor: \"pointer\",\n },\n radioLabelRoot: {\n margin: 0,\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n },\n radioRoot: {\n \"&.Mui-checked\": {\n color: theme.colors.clearMain,\n \"&, & + .MuiFormControlLabel-label\": {\n color: theme.colors.clearMain,\n },\n },\n },\n radioGroupItems: {\n marginBottom: 15\n },\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n })\n);\n\nexport default useStyles;","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { setAccountSettings, setIsCashRegisterActivated } from \"../../../../../redux/account-settings-slice\";\n\nimport { Backdrop, Button, Fade, FormControlLabel, Modal, Radio, RadioGroup } from \"@material-ui/core\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport { SettingsPaymentService } from \"../../../../../api/settings-payment-service\";\nimport SelectWithLabel from \"../../../../common/SelectWithLabel\";\nimport { BankIcon, CashIcon, CreditCardIcon, CrossIcon, DeleteIcon, ExclamationIcon, InfoIcon, MercadoPagoIcon, OxxoIcon, PlusIcon } from \"../../../../../assets/icons\";\nimport CheckboxWithLabel from \"../../../../common/CheckboxWithLabel\";\nimport Input from \"../../../../common/Input\";\nimport { SelectItem } from \"../../../../common/Select\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport { BankTransferInfo } from \"../../../../../models/bank-transfer-info\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport { PaymentSettingsModel } from \"../../../../../models/payment-settings-model\";\nimport { PaymentFieldUpdate } from \"../../../../../models/enums/payment-field-update\";\nimport { BankTransferType } from \"../../../../../models/enums/bank-transfer-type\";\nimport { Currency } from \"../../../../../models/currency\";\nimport InputCurrency from \"../../../../common/InputCurrency\";\nimport { NameRegexV2 } from \"../../../../../constants/validator\";\nimport useCurrencyValueTemplate from \"../../../../../hooks/useCurrencyValueTemplate\";\nimport useStyles from \"./css\";\nimport ExclamationModal from \"../../../../common/ExclamationModal\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../../redux/store\";\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport SectionNote from \"../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\n\n\nexport default function PaymentMain(props: SettingsEnterpriseProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"general\", \"settings\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const accountSettings = useAppSelector(selectAccountSettings);\n const [currencies, setCurrencies] = useState<SelectItem[]>([]);\n const [currentCurrency, setCurrentCurrency] = useState<Currency>(new Currency());\n const [bankTransfer, setBankTransfer] = useState<BankTransferInfo[]>([]);\n const [daysAfter, setDaysAfter] = useState<SelectItem[]>([]);\n const [transferType, setTransferType] = useState<SelectItem[]>([]);\n const [openDeleteDialog, setOpenDeleteDialog] = useState<boolean>(false);\n const [openForbiddenSaveDialog, setOpenForbiddenSaveDialog] = useState<boolean>(false);\n const [itemToDelete, setItemToDelete] = useState<any | null>(null);\n const [entity, setEntity] = useState<PaymentSettingsModel>(new PaymentSettingsModel());\n const [isAddExtraCost, setIsAddExtraCost] = useState<string>(\"1\");\n const [valueTemplate, setValueTemplate] = useState<string>(\"{0}\");\n \n const [isExclamationModalOpen, setExclamationModalOpen] = useState<boolean>(false);\n\n const templatedValue = useCurrencyValueTemplate(valueTemplate);\n\n const userInfo = useAppSelector(selectUserInfo);\n const enterpriseSelected = userInfo.accountId === settingsSelectedEstablishmentId;\n\n useEffect(() => {\n\n (async () => {\n await getPaymentsSettings();\n })();\n\n getDaysAfter();\n getTransferType();\n\n }, [settingsSelectedEstablishmentId])\n\n useEffect(() => {\n if (entity.currencyId) {\n const newCurrency = entity.currencies.find(x => x.id === entity.currencyId)\n setCurrentCurrency(newCurrency ?? new Currency());\n dispatch(setAccountSettings({...accountSettings, currencyTemplate : newCurrency?.valueTemplate ?? \"{0}\"}))\n }\n }, [entity.currencyId])\n\n\n const getDaysAfter = () => {\n let listItems: SelectItem[] = [];\n listItems.push({ key: 1, value: t(\"1 day after\") });\n listItems.push({ key: 2, value: t(\"2 days after\") });\n listItems.push({ key: 3, value: t(\"3 days after\") });\n setDaysAfter(listItems);\n }\n\n const getTransferType = () => {\n let listItems: SelectItem[] = [];\n listItems.push({ key: 1, value: t(\"Card number and interbank CLABE\") });\n listItems.push({ key: 5, value: t(\"Card number, account number and interbank CLABE\") });\n listItems.push({ key: 4, value: t(\"Account number\") });\n listItems.push({ key: 2, value: t(\"Card number\") });\n listItems.push({ key: 3, value: t(\"Interbank CLABE\") });\n setTransferType(listItems);\n }\n\n\n const getPaymentsSettings = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const info = settingsSelectedEstablishmentId \n ? await SettingsPaymentService.getPaymentsSettings(settingsSelectedEstablishmentId)\n : await SettingsPaymentService.getPaymentsSettings();\n dispatch(navbarActions.setShowLoader(false));\n \n if (info.currencies)\n await setCurrenciesSelectItems(info.currencies);\n\n if (info.isPaymentBankTransfer && info.bankTransfers.length === 0) {\n handleAddInterbank();\n }\n else {\n setBankTransfer(info.bankTransfers);\n }\n setEntity(info);\n setIsAddExtraCost(info.hasExtraCostMercadoPago ? \"1\" : \"0\");\n\n if (info.currencyTemplate != null)\n setValueTemplate(info.currencyTemplate);\n }\n\n\n const handleChangeCurrency = async (event: React.ChangeEvent<{ value: string }>) => {\n const value = event.target.value;\n\n const updating: PaymentSettingsModel = {\n ...entity,\n currencyId: value,\n fieldUpd: PaymentFieldUpdate.Currency\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveCurrency(updating);\n\n if (result) {\n const currencySel = currencies?.find(c => { return c.key === value });\n if (currencySel)\n setEntity(updating);\n }\n };\n\n const savePaymentsSettings = async (updating: PaymentSettingsModel): Promise<boolean> => {\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.savePaymentsSettings(updating);\n\n if (result.saved) {\n setEntity(updating);\n }\n else {\n if (result.forbbidenSave)\n setOpenForbiddenSaveDialog(true);\n }\n\n return result.saved;\n }\n\n const handleSetPaymentsInCash = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentCash: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentCash\n }\n\n await savePaymentsSettings(updating);\n }\n\n\n const handleSetPaymentsCreditCard = async (value: boolean) => {\n let updating: PaymentSettingsModel;\n\n if (!value) {\n updating = {\n ...entity,\n isPaymentCard: false,\n isPaymentCardMasterCard: false,\n isPaymentCardVisa: false,\n isPaymentCardOther: false,\n otherPaymentCardName: \"\",\n fieldUpd: PaymentFieldUpdate.IsPaymentCard\n };\n }\n else {\n updating = {\n ...entity,\n isPaymentCard: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentCard\n };\n }\n\n await savePaymentsSettings(updating);\n }\n\n\n const handleMasterCard = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentCardMasterCard: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentCardMasterCard\n }\n\n await savePaymentsSettings(updating);\n }\n\n\n const handleVisa = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentCardVisa: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentCardVisa\n }\n\n await savePaymentsSettings(updating);\n }\n\n\n const handleOtherPaymentSystem = async (value: boolean) => {\n if (!value) {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentCardOther: value,\n otherPaymentCardName: \"\",\n fieldUpd: PaymentFieldUpdate.IsPaymentCardOther\n }\n await savePaymentsSettings(updating);\n }\n else {\n setEntity({\n ...entity,\n isPaymentCardOther: value,\n });\n }\n }\n\n const handlePaymentSystemNameChange = async (event: React.ChangeEvent<{ value: string }>) => {\n const value = event.target.value.replace(\" \", \" \");\n if (!NameRegexV2.test(value)) return;\n\n const updating: PaymentSettingsModel = {\n ...entity,\n otherPaymentCardName: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentCardOther\n }\n setEntity(updating);\n }\n\n const handlePaymentSystemNameBlur = async () => {\n const updating: PaymentSettingsModel = {\n ...entity,\n fieldUpd: PaymentFieldUpdate.IsPaymentCardOther\n }\n await savePaymentsSettings(updating);\n }\n\n async function handleSetPaymentsBankTransfer(value: boolean) {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentBankTransfer: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentBankTransfer\n }\n\n const result = await savePaymentsSettings(updating);\n if (result) {\n setEntity(updating);\n\n if (!value)\n setBankTransfer([]);\n\n if (value && bankTransfer.length === 0)\n handleAddInterbank();\n }\n }\n\n\n const handleBankTransfer = async (item: BankTransferInfo, e: any) => {\n let transfer = bankTransfer;\n const itemIndex = transfer.findIndex(x => x.index === item.index);\n const value = e.target.value;\n\n if (e.target.name === \"bank\") {\n transfer[itemIndex].bankName = value;\n transfer[itemIndex].bankNameValid = value.toString().trim().length > 0\n }\n\n if (e.target.name === \"cardNumber\") {\n transfer[itemIndex].cardNumber = value;\n transfer[itemIndex].cardNumberValid = value.toString().trim().length > 0\n }\n\n if (e.target.name === \"clabe\") {\n transfer[itemIndex].interbankClabe = value;\n transfer[itemIndex].interbankClabeValid = value.toString().trim().length > 0\n }\n if (e.target.name === \"accountNumber\") {\n transfer[itemIndex].accountNumber = value;\n transfer[itemIndex].accountNumberValid = value.toString().trim().length > 0\n }\n\n if (e.target.name === \"transferType\") {\n transfer[itemIndex].bankTransferType = value;\n if (value === 2) transfer[itemIndex].interbankClabe = \"\";\n if (value === 3) transfer[itemIndex].cardNumber = \"\";\n await handleBankTransferSave(transfer[itemIndex]);\n }\n\n setBankTransfer([...transfer]);\n }\n\n const handleBankTransferSave = async (item: BankTransferInfo) => {\n let cardNumberValid = item?.cardNumber && item.cardNumber?.trim().length > 0;\n let accountNumberValid = item?.accountNumber && item.accountNumber?.trim().length > 0;\n let interbankClabeValid = item?.interbankClabe && item.interbankClabe?.trim().length > 0;\n\n if (item.bankName !== \"\" &&\n (( item.bankTransferType === BankTransferType.CardNumberClabe && cardNumberValid && interbankClabeValid) ||\n (item.bankTransferType === BankTransferType.CardNumber && cardNumberValid) ||\n (item.bankTransferType === BankTransferType.Clabe && interbankClabeValid) ||\n (item.bankTransferType === BankTransferType.AccountNumber && accountNumberValid) ||\n (item.bankTransferType === BankTransferType.CardNumberAccountNumberClabe && cardNumberValid && interbankClabeValid && accountNumberValid))\n ) {\n\n item.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : null;\n const result = await SettingsPaymentService.saveBankTransfer(item);\n\n let transfers = bankTransfer;\n const itemIndex = transfers.findIndex(x => x.index === item.index);\n transfers[itemIndex] = result;\n transfers[itemIndex].bankNameValid = true;\n transfers[itemIndex].cardNumberValid = true;\n transfers[itemIndex].interbankClabeValid = true;\n transfers[itemIndex].accountNumberValid = true;\n setBankTransfer([...transfers]);\n }\n\n }\n\n\n const handleOxxoCheck = async (value: boolean) => {\n if (!value) {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentOxxo: value,\n oxxoCardNumber: \"\",\n fieldUpd: PaymentFieldUpdate.IsPaymentOxxo\n }\n\n const result = await savePaymentsSettings(updating);\n if (result) setEntity(updating);\n }\n else {\n setEntity({\n ...entity,\n isPaymentOxxo: value,\n });\n }\n }\n\n\n const handleOxxoChange = async (event: React.ChangeEvent<{ value: string }>) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n oxxoCardNumber: event.target.value,\n fieldUpd: PaymentFieldUpdate.IsPaymentOxxo\n }\n setEntity(updating);\n }\n\n\n const handleOxxoBlur = async () => {\n if (entity.isPaymentOxxo && entity.oxxoCardNumber?.trim().length !== 0) {\n const updating: PaymentSettingsModel = {\n ...entity,\n fieldUpd: PaymentFieldUpdate.IsPaymentOxxo\n }\n await savePaymentsSettings(updating);\n }\n }\n\n\n const handleMercadoPagoCheck = async (value: boolean) => {\n if (!value) {\n const updating: PaymentSettingsModel = {\n ...entity,\n isPaymentMercadoPago: value,\n hasAcceptedMercadoPagoTerms: false,\n fieldUpd: PaymentFieldUpdate.IsPaymentMercadoPago\n }\n await savePaymentsSettings(updating);\n }\n else {\n setEntity({\n ...entity,\n isPaymentMercadoPago: value,\n });\n }\n }\n\n const handleMercadoPagoTerms = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n hasAcceptedMercadoPagoTerms: value,\n fieldUpd: PaymentFieldUpdate.IsPaymentMercadoPago\n }\n await savePaymentsSettings(updating);\n }\n\n const handleExtraCostMercadoPago = async (value: string) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n hasExtraCostMercadoPago: value === \"1\",\n fieldUpd: PaymentFieldUpdate.IsPaymentMercadoPago\n }\n const result = await savePaymentsSettings(updating);\n\n if (result)\n setIsAddExtraCost(value);\n }\n\n const handleAppointmentConfirmation = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n hasWhatsAppPaymentReminderOnAppointmentConfirmation: value,\n fieldUpd: PaymentFieldUpdate.HasWhatsAppPaymentReminderOnAppointmentConfirmation\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveWhatsAppPaymentSettings(updating);\n if (result) setEntity(updating);\n }\n \n const handleIsSendReceiptByWhatsApp = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n isSendReceiptByWhatsApp: value,\n fieldUpd: PaymentFieldUpdate.IsSendReceiptByWhatsApp\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveWhatsAppPaymentSettings(updating);\n if (result) setEntity(updating);\n }\n\n\n const handleAppointmentReminder = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n hasWhatsAppPaymentReminderOnAppointmentReminder: value,\n fieldUpd: PaymentFieldUpdate.HasWhatsAppPaymentReminderOnAppointmentReminder\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveWhatsAppPaymentSettings(updating);\n if (result) setEntity(updating);\n }\n\n\n const handleAppointmentAfter = async (value: boolean) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n hasWhatsAppPaymentReminderAfterAppointment: value,\n fieldUpd: PaymentFieldUpdate.HasWhatsAppPaymentReminderAfterAppointment\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveWhatsAppPaymentSettings(updating);\n if (result) setEntity(updating);\n }\n\n const handleDaysAppointmentAfter = async (e: any) => {\n const updating: PaymentSettingsModel = {\n ...entity,\n daysAfterAppointmentToSendWhatsAppPaymentReminder: e.target.value,\n fieldUpd: PaymentFieldUpdate.HasWhatsAppPaymentReminderAfterAppointment\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveWhatsAppPaymentSettings(updating);\n if (result) setEntity(updating);\n }\n\n const handlCashCheck = async (value: boolean) => {\n if (!value) {\n const updating: PaymentSettingsModel = {\n ...entity,\n isCashRegisterActivated: value,\n // initialCashInCashRegister: initialCashDefaultValue,\n fieldUpd: PaymentFieldUpdate.IsCashRegisterActivated\n }\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveCashRegister(updating);\n if (result) {\n setEntity(updating);\n dispatch(setIsCashRegisterActivated(value))\n }\n }\n else {\n const updating: PaymentSettingsModel = {\n ...entity,\n isCashRegisterActivated: value,\n fieldUpd: PaymentFieldUpdate.IsCashRegisterActivated\n }\n if (entity.initialCashInCashRegister !== null && entity.initialCashInCashRegister >= 0) {\n updating.accountId = (settingsSelectedEstablishmentId && !enterpriseSelected) ? settingsSelectedEstablishmentId : \"\";\n const result = await SettingsPaymentService.saveCashRegister(updating);\n if (result) setEntity(updating);\n }\n else {\n setEntity(updating);\n }\n }\n }\n\n function setInitialCash(value: number) {\n const newModel: PaymentSettingsModel = {\n ...entity,\n initialCashInCashRegister: value,\n fieldUpd: PaymentFieldUpdate.IsCashRegisterActivated\n }\n setEntity(newModel);\n\n }\n\n const handleCashBlur = async (value?: number) => {\n if (value === undefined) return;\n if (value === entity.initialCashInCashRegister) return;\n\n const updating: PaymentSettingsModel = {\n ...entity,\n initialCashInCashRegister: value,\n fieldUpd: PaymentFieldUpdate.IsCashRegisterActivated\n }\n\n if (!entity.isCashRegisterActivated || (entity.isCashRegisterActivated && value !== null && +value >= 0)) {\n const result = await SettingsPaymentService.saveCashRegister(updating);\n if (result) setEntity(updating);\n }\n }\n\n const setCurrenciesSelectItems = async (currencyList: Currency[]) => {\n\n let listItems: SelectItem[] = [];\n if (currencyList === undefined)\n return listItems;\n\n currencyList.forEach(c => {\n listItems.push({\n key: c.id,\n value: t(c.name) + \" (\" + c.isoCode + \")\"\n })\n });\n\n setCurrencies(listItems);\n }\n\n const handleAddInterbank = () => {\n if (bankTransfer.length >= 3) {\n setExclamationModalOpen(true);\n return;\n }\n const arrBankTransfer = bankTransfer;\n let newBankTransfer = new BankTransferInfo();\n newBankTransfer.index = bankTransfer.length === 0 ? 0 : Math.max(...bankTransfer.map(o => o.index)) + 1\n arrBankTransfer.push(newBankTransfer);\n setBankTransfer([...arrBankTransfer]);\n };\n\n const handleAskToRemoveBank = (bank: BankTransferInfo) => {\n setOpenDeleteDialog(true);\n setItemToDelete(bank);\n };\n\n const handleOnDelete = async (item: any) => {\n if (item?.bankTransferId === null) {\n const arrBankTransfer = bankTransfer.filter(data => data.index !== item.index);\n setBankTransfer(arrBankTransfer);\n setItemToDelete(null);\n setOpenDeleteDialog(false);\n return;\n }\n \n const result = await SettingsPaymentService.deleteBankTransfer(item);\n\n if (result) {\n const arrBankTransfer = bankTransfer.filter(data => data.index !== item.index);\n setBankTransfer(arrBankTransfer);\n setItemToDelete(null);\n }\n\n setOpenDeleteDialog(false);\n };\n\n const DivInfoDelete: React.FC = () => {\n return (<>\n <div className={classes.modalCenter} style={{ marginTop: 20 }}>\n <Typography className={classes.modalContentText}>\n {t(\"Delete info from this bank?\")}\n </Typography>\n </div>\n </>);\n };\n\n return (\n <div>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Payments\")}\n </Typography>\n </div>\n <SectionNote \n sectionData={SectionNoteData.Payments}\n />\n </>\n )}\n <div className={classes.block}>\n <div className={classes.title}>\n <Typography className={classes.title}>\n {t(\"Payment methods\")}\n </Typography>\n </div>\n <div className={classes.contentArea}>\n <div className={classes.requiredFieldsHeader}>\n {t(\"Required fields\")} <span className={classes.dot}>*</span>\n </div>\n <div className={classes.contentColumns}>\n <div className={classes.contentColumn}>\n <SelectWithLabel\n label={() => (\n <>\n {t(\"Currency\")}\n </>\n )}\n items={currencies}\n placeholder={t(\"Select a currency\")}\n width={230}\n name=\"currencyid\"\n onChange={handleChangeCurrency}\n value={entity.currencyId}\n />\n </div>\n <div className={classes.contentColumn} style={{ paddingLeft: 20 }}>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.isPaymentCash}\n setValue={handleSetPaymentsInCash}\n label={t(\"Cash\")}\n icon={() => <CashIcon style={{ color: entity.isPaymentCash ? \"#6462F3\" : null }} />}\n />\n </div>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.isPaymentCard}\n setValue={handleSetPaymentsCreditCard}\n label={t(\"Credit / debit cards\")}\n icon={() => <CreditCardIcon style={{ color: entity.isPaymentCard ? \"#6462F3\" : null }} />}\n />\n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"You need to select an option\")}\n />\n </div>\n {\n entity.isPaymentCard &&\n <div className={classes.creditCardTypes}>\n\n <div style={{ marginRight: 30 }}>\n <CheckboxWithLabel\n checked={entity.isPaymentCardMasterCard}\n setChecked={handleMasterCard}\n label={t(\"MasterCard\")}\n />\n </div>\n <div style={{ marginRight: 20 }}>\n <CheckboxWithLabel\n checked={entity.isPaymentCardVisa}\n setChecked={handleVisa}\n label={t(\"Visa\")}\n />\n </div>\n <div className={classes.smallVerticalDivider} />\n <div style={{ display: \"flex\" }}>\n <CheckboxWithLabel\n checked={entity.isPaymentCardOther}\n setChecked={handleOtherPaymentSystem}\n label={t(\"Other\")}\n />\n <Input\n inputClass={classes.otherCardTypeInput}\n value={entity.otherPaymentCardName}\n onChange={handlePaymentSystemNameChange}\n onBlur={handlePaymentSystemNameBlur}\n placeholder={t(\"Card type\")}\n disabled={!entity.isPaymentCardOther}\n />\n </div>\n </div>\n }\n <div className={classes.checkGroup} style={{ zIndex: 10 }}>\n <SwitchWithLabel\n value={entity.isPaymentBankTransfer}\n setValue={handleSetPaymentsBankTransfer}\n label={t(\"Bank transfers\")}\n icon={() => <BankIcon style={{ color: entity.isPaymentBankTransfer ? \"#6462F3\" : null }} />}\n />\n <IconTooltip\n key={\"banktransfersToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"You need to fill in the required fields\")}\n />\n </div>\n {\n entity.isPaymentBankTransfer &&\n <div className={classes.bankTransfers}>\n {bankTransfer.map((transfer, index) => (\n <div style={{ display: \"block\", marginTop: -30, zIndex: 5 }}>\n <div className={classes.deleteDiv}>\n {index > 0 &&\n <span className={classes.deleteButton} onClick={() => handleAskToRemoveBank(transfer)}>\n <DeleteIcon />\n </span>\n }\n </div>\n <div style={{ display: \"inline-block\", margin: \"10px 15px 20px 5px\" }}>\n <InputWithLabel\n label={() => <>{t(\"BankLabel\")} <span className={classes.dot}>*</span></>}\n placeholder={t(\"Name of the bank\")}\n value={transfer.bankName}\n width={336}\n name=\"bank\"\n onChange={(e) => handleBankTransfer(transfer, e)}\n onBlurInput={() => handleBankTransferSave(transfer)}\n isValid={() => transfer.bankNameValid}\n />\n </div>\n <div style={{ display: \"inline-block\", margin: \"10px 0px 20px 0px\" }}>\n <SelectWithLabel\n label={() => <>{t(\"Info to be sent\")} <span className={classes.dot}>*</span></>}\n items={transferType}\n placeholder={t(\"Select information\")}\n width={336}\n name=\"transferType\"\n onChange={(e) => handleBankTransfer(transfer, e)}\n value={transfer.bankTransferType}\n />\n </div>\n\n <div style={{ display: \"inline-block\", margin: \"10px 15px 20px 5px\" }}>\n <InputWithLabel\n label={() => <>{t(\"Account number\")} <span className={classes.dot}>*</span></>}\n placeholder={t(\"XXXXXXXXXX\")}\n value={transfer.accountNumber}\n width={336}\n name=\"accountNumber\"\n onKeyPress={(event) => {\n if (!/[0-9]/.test(event.key)) {\n event.preventDefault();\n }\n }}\n maxLength={100}\n inputDisabled={!(transfer.bankTransferType === BankTransferType.AccountNumber || transfer.bankTransferType === BankTransferType.CardNumberAccountNumberClabe)}\n onChange={(e) => handleBankTransfer(transfer, e)}\n onBlurInput={() => handleBankTransferSave(transfer)}\n isValid={() => transfer.accountNumberValid}\n />\n </div>\n \n <div style={{ display: \"inline-block\", margin: \"10px 15px 20px 5px\" }}>\n <InputWithLabel\n label={() => <>{t(\"Card number\")} <span className={classes.dot}>*</span></>}\n value={transfer.cardNumber}\n placeholder={\"XXXXXXXXXXXXXXXX\"}\n inputDisabled={!(transfer.bankTransferType === BankTransferType.CardNumberClabe || transfer.bankTransferType === BankTransferType.CardNumber || transfer.bankTransferType === BankTransferType.CardNumberAccountNumberClabe)}\n onKeyPress={(event) => {\n if (!/[0-9-]/.test(event.key)) {\n event.preventDefault();\n }\n }}\n maxLength={100}\n width={336}\n name=\"cardNumber\"\n onChange={(e) => handleBankTransfer(transfer, e)}\n onBlurInput={() => handleBankTransferSave(transfer)}\n isValid={() => transfer.cardNumberValid}\n />\n </div>\n <div style={{ display: \"inline-block\", margin: \"10px 0px 20px 0px\" }}>\n <InputWithLabel\n label={() => <>{t(\"Interbank CLABE\")} <span className={classes.dot}>*</span></>}\n value={transfer.interbankClabe}\n placeholder={\"XXXXXXXXXXXXXXXXXX\"}\n inputDisabled={!(transfer.bankTransferType === BankTransferType.CardNumberClabe || transfer.bankTransferType === BankTransferType.Clabe || transfer.bankTransferType === BankTransferType.CardNumberAccountNumberClabe)}\n onKeyPress={(event) => {\n if (!/[0-9-]/.test(event.key)) {\n event.preventDefault();\n }\n }}\n maxLength={100}\n width={336}\n name=\"clabe\"\n onChange={(e) => handleBankTransfer(transfer, e)}\n onBlurInput={() => handleBankTransferSave(transfer)}\n isValid={() => transfer.interbankClabeValid}\n />\n </div>\n </div>\n ))}\n <div style={{ display: \"block\" }}>\n <Button\n className={classes.addButton}\n onClick={handleAddInterbank}\n >\n <PlusIcon />\n {t(\"Add another\")}\n </Button>\n </div>\n </div>\n }\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.isPaymentOxxo}\n setValue={handleOxxoCheck}\n label={t(\"Payments with Oxxo\")}\n icon={() => <OxxoIcon style={{ color: entity.isPaymentOxxo ? \"#6462F3\" : null }} />}\n />\n <IconTooltip\n key={\"oxxoToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"You need to fill in the required fields\")}\n />\n {\n entity.isPaymentOxxo &&\n <div className={classes.creditCardTypes}>\n <div style={{ marginTop: 30 }}>\n <InputWithLabel\n label={() => <>{t(\"Card number for deposits\")} <span className={classes.dot}>*</span></>}\n value={entity.oxxoCardNumber}\n onChange={handleOxxoChange}\n onBlurInput={handleOxxoBlur}\n placeholder={\"XXXXXXXXXXXXXXXX\"}\n disabled={!entity.isPaymentOxxo}\n onKeyPress={(event) => {\n if (!/[0-9-]/.test(event.key)) {\n event.preventDefault();\n }\n }}\n maxLength={100}\n isValid={() => (true || entity.isPaymentOxxo && entity.oxxoCardNumber?.trim().length === 19)}\n />\n </div>\n </div>\n }\n </div>\n {\n entity.isEnabledMercadoPagoByAdmin && <>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.isPaymentMercadoPago}\n setValue={handleMercadoPagoCheck}\n label={t(\"Payments with Mercado Pago\")}\n icon={() => <MercadoPagoIcon style={{ color: entity.isPaymentMercadoPago ? \"#6462F3\" : null }} />}\n />\n {\n entity.isPaymentMercadoPago && <>\n <div className={classes.creditCardTypes}>\n <div style={{ marginTop: 30 }}>\n <CheckboxWithLabel\n checked={entity.hasAcceptedMercadoPagoTerms}\n setChecked={handleMercadoPagoTerms}\n checkboxClass={`${entity.hasAcceptedMercadoPagoTerms ? classes.checkboxMP : classes.checkboxMPRed}`}\n label={<div className={`${classes.text} ${entity.hasAcceptedMercadoPagoTerms ? classes.textChecked : classes.textNoChecked}`}>\n {t(\"You must accept the\")}\n <a\n href=\"https://www.mercadopago.com.mx/ayuda/T%C3%A9rminos-rendimientos_15581\"\n target=\"_blank\"\n className={`${entity.hasAcceptedMercadoPagoTerms ? classes.textChecked : classes.textNoChecked} ${classes.link}`}\n rel=\"noopener noreferrer\">\n {t(\"terms and conditions to activate payments by WhatsApp link\")}\n </a>\n {\".\"}\n </div>\n }\n />\n </div>\n </div>\n <div className={classes.creditCardTypes}>\n <div>\n <div className={classes.lineExtraCost} />\n <div className={classes.extraCostTitle}>\n {t(\"Extra cost to the total of the appointment for the use of Mercado Pago\")}\n </div>\n <div className={classes.radioGroupItems}>\n <RadioGroup\n defaultValue={\"1\"}\n name=\"addExtraCost\"\n onChange={(event) => {\n handleExtraCostMercadoPago(event.target.value)\n }}\n value={isAddExtraCost || true}\n row\n >\n <div>\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={\"0\"}\n control={<Radio className={classes.radioRoot} />}\n label={t(\"Do not add extra cost.\")}\n />\n <IconTooltip\n key={\"mpFreeToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginLeft: 10, marginRight: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"You will pay the fee for using Mercado Pago\")}\n />\n </div>\n <div>\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n value={\"1\"}\n control={<Radio className={classes.radioRoot} />}\n label={t(\"Add extra cost.\")}\n />\n <IconTooltip\n key={\"mpPayToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginLeft: 10, marginRight: 10 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Your customer will pay the fee for using Mercado Pago\")}\n />\n </div>\n </RadioGroup>\n </div>\n <div className={classes.calcExtra}>\n {t(\"Calculation of the extra cost per appointment:\")}\n </div>\n <div>\n <div className={classes.boxExtraCost}>\n <div>\n <Typography className={classes.labelExtraCostMain}>\n {`${entity.extraPercentage || 0}%`}\n </Typography>\n </div>\n <div className={classes.labelExtraCost}>\n {t(\"Extra percentage\")}\n </div>\n </div>\n <div className={classes.boxExtraCostPlus}>\n <PlusIcon />\n </div>\n <div className={classes.boxExtraCost}>\n <div className={classes.labelExtraCost}>\n <div>\n <Typography className={classes.labelExtraCostMain}>\n {`${entity.extraAmount !== null ? templatedValue(entity.extraAmount) : templatedValue(0)}`}\n </Typography>\n </div>\n {t(\"Extra amount\")}\n </div>\n </div>\n <div className={classes.boxExtraCostPlus}>\n <PlusIcon />\n </div>\n <div className={classes.boxExtraCost}>\n <div>\n <Typography className={classes.labelExtraCostMain}>\n {`${entity.ivaPercentage || 0}%`}\n </Typography>\n </div>\n <div className={classes.labelExtraCost}>\n {t(\"IVA Percentage\")}\n </div>\n </div>\n </div>\n </div>\n </div>\n </>}\n </div>\n </>\n }\n </div>\n </div>\n </div>\n </div>\n {(accountSettings.paymentsAndCollectionsEnabled || accountSettings.isEnterprise) &&\n <>\n <div className={classes.block}>\n <div className={classes.title}>\n <Typography className={classes.title}>\n {t(\"Communication with the customer about payments\")}\n </Typography>\n </div>\n <div className={classes.contentArea}>\n <div className={classes.subtitle}>\n <Typography className={classes.title}>\n {t(\"Send additional WhatsApp to make payments before the appointment\")}\n </Typography>\n </div>\n <div className={classes.innerContent}>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.hasWhatsAppPaymentReminderOnAppointmentConfirmation}\n setValue={handleAppointmentConfirmation}\n label={t(\"Appointment confirmation\")}\n />\n <IconTooltip\n key={\"confirmationToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send a message to make the payment when creating the appointment\")}\n />\n </div>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.hasWhatsAppPaymentReminderOnAppointmentReminder}\n setValue={handleAppointmentReminder}\n label={t(\"Appointment reminder\")}\n />\n <IconTooltip\n key={\"reminderToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send a message to make the payment in the appointment reminder\")}\n />\n </div>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.hasWhatsAppPaymentReminderAfterAppointment}\n setValue={handleAppointmentAfter}\n label={t(\"After appointment\")}\n />\n <IconTooltip\n key={\"afterToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Apply for appointments with \\\"Customer arrived\\\" and \\\"Unpaid\\\" status\")}\n />\n <div className={classes.contentColumn} style={{ paddingLeft: 45 }}>\n <SelectWithLabel\n label={\"\"}\n items={daysAfter}\n placeholder={t(\"Select days\")}\n width={230}\n name=\"daysAfter\"\n onChange={handleDaysAppointmentAfter}\n value={entity.daysAfterAppointmentToSendWhatsAppPaymentReminder}\n disabled={!entity.hasWhatsAppPaymentReminderAfterAppointment}\n styleClass={!entity.hasWhatsAppPaymentReminderAfterAppointment ? classes.opacityTextMid : null}\n />\n </div>\n </div>\n </div>\n <div className={classes.subtitle}>\n <Typography className={classes.title}>\n {t(\"Send receipt by WhatsApp\")}\n </Typography>\n </div>\n <div className={classes.innerContent}>\n <div className={classes.checkGroup}>\n <SwitchWithLabel\n value={entity.isSendReceiptByWhatsApp}\n setValue={handleIsSendReceiptByWhatsApp}\n label={t(\"Send receipt by WhatsApp\")}\n />\n <IconTooltip\n key={\"confirmationToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"When a payment is registered, the payment receipt is sent to your customer by WhatsApp.\")}\n />\n </div>\n </div>\n </div>\n </div>\n <div className={classes.block} style={{ height: 300 }}>\n <div className={classes.title}>\n <Typography className={classes.title}>\n {t(\"Activate cash register\")}\n </Typography>\n </div>\n <div className={classes.contentArea}>\n <div className={classes.innerContent}>\n <SwitchWithLabel\n value={entity.isCashRegisterActivated}\n setValue={handlCashCheck}\n label={t(\"ActivateCashRegisterLabel\")}\n />\n <div className={classes.cashOpeningInput}>\n <Typography className={classes.initialCash}>\n {t(\"Initial cash\")} <span className={classes.dot}>*</span>\n </Typography>\n <InputCurrency\n value={entity.initialCashInCashRegister!}\n setValue={setInitialCash}\n valueTemplate={currentCurrency.valueTemplate}\n disabled={!entity.isCashRegisterActivated}\n onBlur={handleCashBlur}\n isZeroAllowed={true}\n isValid={() => {\n return (!entity.isCashRegisterActivated || (entity.isCashRegisterActivated && entity.initialCashInCashRegister !== null && +entity.initialCashInCashRegister >= 0));\n }}\n />\n </div>\n </div>\n </div>\n </div>\n </>}\n <ConfirmDeleteModal\n textButtonConfirm={t(\"Delete\")}\n classModal={classes.modalDelete}\n open={openDeleteDialog}\n item={itemToDelete}\n componentInfo={<DivInfoDelete />}\n onClose={() => setOpenDeleteDialog(false)}\n onDelete={handleOnDelete}\n />\n <ExclamationModal \n open={isExclamationModalOpen} \n height={303}\n title={t(\"Sorry, you have reached the limit of banks to add\")} \n body={\n <div className={classes.exclamationModalBody}>\n {t(\"At the moment you can only add 3 banks\")}\n </div>\n }\n okTextButton={t(\"I agree\")}\n onClose={() => setExclamationModalOpen(false)}\n />\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openForbiddenSaveDialog}\n onClose={() => setOpenForbiddenSaveDialog(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openForbiddenSaveDialog}>\n <div className={classes.paper}>\n <div className={classes.closeButton} onClick={() => setOpenForbiddenSaveDialog(false)}>\n <CrossIcon />\n </div>\n <div className={classes.content}>\n <div className={classes.exclamationIcon}>\n <ExclamationIcon viewBox=\"0 0 7 16\" />\n </div>\n <Typography className={classes.modalTitle}>\n {t(\"It is not possible to deactivate all payment methods\")}\n </Typography>\n <div className={classes.modalTextBlock}>\n <Typography className={classes.modalText}>\n {t(\"At least 1 active payment method is required.\")}\n </Typography>\n </div>\n <div className={classes.modalFooter}>\n <Button\n className={`${classes.button} ${classes.goBackButton}`}\n onClick={() => setOpenForbiddenSaveDialog(false)}\n >\n {t(\"OKForbiddenSavePayment\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </div >\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nimport { Color } from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n header: {\n marginBottom: 10,\n paddingTop: 5,\n display: \"flex\",\n with: \"100%\"\n },\n headerLeft: {\n textAlign: \"left\",\n display: \"inline\"\n },\n headerCenter: {\n textAlign: \"right\",\n display: \"inline\",\n marginRight: 0,\n marginLeft: \"auto\"\n },\n headerRight: {\n textAlign: \"right\",\n display: \"inline\",\n marginRight: 0,\n marginLeft: 25\n },\n serviceImportButton: {\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n\n marginRight: 25,\n\n color: theme.colors.clearMain,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n buttonNew: {\n textTransform: \"none\",\n\n background: \"#7175FA\",\n color: theme.colors.grey1,\n \"&:hover\": {\n background: theme.colors.clearMain,\n },\n },\n\n titles: {\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\",\n marginBottom: 10\n },\n icons: {\n color: Color.gray5,\n fontSize: 18\n },\n buttonDel: {\n width: 32,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\",\n position: \"relative\",\n top: \"50%\",\n transform: \"translateY(-50%)\"\n },\n iconTrash: {\n fill: Color.gray5\n },\n icon: {\n paddingTop: 5,\n height: 30,\n width: 30,\n fontWeight: \"bold\"\n },\n classHead: {\n color: theme.colors.grey5,\n textAlign: \"left\"\n },\n classRow: {\n cursor: \"pointer\",\n backgroundColor: \"white !important\",\n },\n classCell: {\n color: theme.colors.grey5,\n },\n colText: {\n ...theme.typography.body2,\n fontSize: 12,\n },\n divNotesTrash: {\n verticalAlign: \"middle\",\n alignItems: \"left\",\n display: \"flex\",\n cursor: \"pointer\",\n \"& #divBackTrash, #divTrash\": {\n visibility: \"hidden\"\n },\n \"&:hover\": {\n \"& #divBackTrash, #divTrash\": {\n visibility: \"visible\"\n }\n },\n position: \"relative\"\n },\n divNotes: {\n textAlign: \"left\",\n display: \"inline-flex\",\n minHeight: 35,\n width: \"100%\",\n fontSize: 12,\n fontFamily: \"Roboto,sans-serif\",\n whiteSpace: \"pre-wrap\",\n wordBreak: \"break-word\",\n alignItems: \"center\"\n },\n divTrash: {\n height: \"100%\",\n position: \"absolute\",\n right: 0,\n },\n divBackTrash: {\n background: \"linear-gradient(270deg, #FFFFFF 50%, rgba(255, 255, 255, 0) 96.63%);\",\n height: \"100%\",\n position: \"absolute\",\n top: 0,\n right: 0,\n width: 200,\n }\n}));\n\n\nexport default useStyles;\n","import ServiceGrid from \"./service-grid\";\nexport default ServiceGrid;\n","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport moment from \"moment\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\n\nimport { ImportIcon, TrashIcon } from \"../../../../../assets/icons\";\nimport GridList, { OnChangeEvent } from \"./../../../../common/grid/GridList\";\nimport { TableColumn } from \"../../../../common/grid/table-column\";\nimport { Button } from \"@material-ui/core\";\nimport { Typography } from \"@material-ui/core\";\n\nimport EntityService from \"../../../../../api/settings-services-service\";\nimport Service from \"../../../../../models/service\";\nimport { ServiceListProps } from \"./props\";\n\nimport { Color } from \"../../../../../constants/colors\";\nimport useStyles from \"./css\";\n\nimport { FlagIcon } from \"../../../../../assets/icons\";\nimport Autocomplete from \"../../../../../components/common/Autocomplete\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\n\nexport default function ServicesGrid(props: ServiceListProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n \n const {\n isRefresh,\n item,\n openImportModal,\n openItemEditModal,\n openDeleteModal,\n setTotalRecords,\n handleCreate,\n } = props;\n\n const [entityList, setEntityList] = useState<Service[]>([]);\n const [total, setTotal] = useState<number>(0);\n\n const [serviceSearch, setServiceSearch] = useState<Service[]>([]);\n const [search, setSearch] = useState<string>();\n\n const [page, setPage] = useState<number>(1);\n const pageSize: number = 20;\n const [order, setOrder] = useState<\"asc\" | \"desc\">(\"asc\");\n const [orderBy, setOrderBy] = useState<string>(\"name\");\n const [value, setValue] = useState<string>();\n const format = \"HH:mm\";\n\n const userInfo = useAppSelector(state => state.userInfo);\n\n useEffect(() => {\n if (item) {\n const newList = [item].concat(entityList);\n setEntityList(newList);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [item]);\n\n useEffect(() => {\n (async () => {\n await loadData();\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId, page, orderBy, order, value, isRefresh]);\n\n useEffect(() => {\n if (search && search.length > 2) {\n (async () => {\n await loadSearchData();\n })();\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [search]);\n\n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const data = await EntityService.getServices(\n page,\n pageSize,\n order,\n orderBy,\n settingsSelectedEstablishmentId,\n value,\n [\"Name\", \"Category\"]\n );\n dispatch(navbarActions.setShowLoader(false));\n data.entity?.forEach((item, index) => {\n item.recurrence = t(item.recurrence)\n .replace(\"weeks\", t(\"weeks\"))\n .replace(\"week\", t(\"week\"))\n .replace(\"months\", t(\"months\"))\n .replace(\"month\", t(\"month\"));\n });\n setEntityList(data.entity || []);\n setTotal(data.total || 0);\n if (setTotalRecords) setTotalRecords(data.total || 0);\n };\n\n const loadSearchData = async () => {\n const data = await EntityService.getServices(1, 20, \"asc\", \"Name\", settingsSelectedEstablishmentId, search, [\n \"Name\",\n \"Category\",\n ]);\n\n // avoid names duplicated\n const list: Service[] = data.entity ?? [];\n const names = list.map((o) => o.name);\n const groupByName = list.filter(\n ({ name }, index) => !names.includes(name, index + 1)\n );\n\n setServiceSearch(groupByName || []);\n };\n\n const numberWithCommas = (x: number) => {\n return x.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n };\n\n const duration = (minDuration: number) => {\n const minDateTime = minutesToDateTime(minDuration);\n const minutes = moment(minDateTime).format(format);\n\n return `${minutes} ${ minDateTime.getHours() > 1 ? \"hrs\" : (minDateTime.getHours() === 1 ? \"hr\" : \"min\") }`;\n };\n\n const minutesToDateTime = (minutes: number): Date => {\n let newDate = new Date(2000, 1, 1, 0, 0, 0, 0);\n newDate.setMinutes( newDate.getMinutes() + minutes );\n return newDate;\n };\n\n const columns: TableColumn[] = [\n {\n id: \"name\",\n label: t(\"SERVICE NAME\"),\n sorting: true,\n width: \"20%\",\n headerClassName: classes.classHead,\n rowClassName: classes.classCell,\n },\n {\n id: \"price\",\n label: t(\"PRICE\"),\n sorting: false,\n component: (price: any) => (\n <Typography className={classes.colText}>\n $ {numberWithCommas(price)}\n </Typography>\n ),\n width: \"10%\",\n headerClassName: classes.classHead,\n rowClassName: classes.classCell,\n },\n {\n id: \"category\",\n label: t(\"CATEGORY\"),\n sorting: true,\n width: \"10%\",\n headerClassName: classes.classHead,\n rowClassName: classes.classCell,\n },\n {\n id: \"duration\",\n label: t(\"DURATION\"),\n sorting: false,\n component: (min: any) => (\n <Typography className={classes.colText}>{duration(min)}</Typography>\n ),\n width: \"15%\",\n headerClassName: classes.classHead,\n rowClassName: classes.classCell,\n },\n {\n id: \"recurrence\",\n label: t(\"RECURRENCE\"),\n sorting: false,\n width: \"10%\",\n headerClassName: classes.classHead,\n rowClassName: classes.classCell,\n component: (r: any) => (\n <Typography className={classes.colText}>{r.toString()}</Typography>\n ),\n },\n {\n id: \"notes\",\n label: t(\"NOTES\"),\n width: \"35%\",\n sorting: false,\n completeObject: true,\n component: (item: any) => (\n <>\n <div className={classes.divNotesTrash}>\n <div className={classes.divNotes}>{item.notes}</div>\n <div id=\"divBackTrash\" className={classes.divBackTrash}></div>\n <div id=\"divTrash\" className={classes.divTrash}>\n <Button\n className={classes.buttonDel}\n onClick={(e) => {\n e.stopPropagation();\n handleOnDeleteBtnClick(item);\n }}\n >\n <TrashIcon\n style={{ color: Color.gray4, width: 13, height: 17 }}\n />\n </Button>\n </div>\n </div>\n </>\n ),\n headerTextAlign: \"center\",\n textAlign: \"center\",\n headerClassName: classes.classHead,\n rowClassName: classes.classCell,\n },\n ];\n\n const handleOnChangeGrid = (event: OnChangeEvent) => {\n setPage(event.page);\n if (event.sorting) {\n setOrder(event.sorting.direction);\n setOrderBy(\n event.sorting.orderBy === \"name\" ? \"name\" : event.sorting.orderBy\n );\n }\n };\n\n const handleOnRowClick = (item: Service, showModal: boolean) => {\n if (typeof openItemEditModal === \"function\") {\n openItemEditModal(item);\n }\n };\n\n const handleOnDeleteBtnClick = (item: any) => {\n if (typeof openDeleteModal === \"function\") {\n openDeleteModal(item);\n }\n };\n\n const handleOnServiceCreate = () => {\n if (typeof handleCreate === \"function\") {\n handleCreate();\n }\n };\n\n return (\n <>\n <div className={classes.header}>\n <div className={classes.headerLeft}>\n <Typography className={classes.titles} variant=\"subtitle1\">\n {t(\"Services created\")}\n </Typography>\n <Typography className={classes.icons} variant=\"h4\">\n <FlagIcon className={classes.icon} />\n {total}\n </Typography>\n </div>\n\n <div className={classes.headerCenter}>\n <Autocomplete\n style={{ width: 200, marginBottom: 19 }}\n items={serviceSearch}\n placeholder={t(\"Find service\")}\n renderOption={(option: any) => `${option.name}`}\n getOptionSelected={(option, value) => option.name === value.name}\n getOptionLabel={(option) => option.name}\n onChange={(value: any, reason) => {\n if (reason === \"input\" && value.length >= 3)\n setSearch(value); \n else\n setServiceSearch([]);\n }}\n onSelected={(option: any) => {\n setValue(option?.name || undefined);\n }}\n />\n </div>\n\n <div className={classes.headerRight}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Import services\")}\n innerIcon={<ImportIcon />}\n onClick={openImportModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"Create Service\")}\n onClick={handleOnServiceCreate}\n />\n </div>\n </div>\n\n <GridList\n columns={columns}\n items={entityList}\n totalItems={total}\n pageSize={20}\n onChange={handleOnChangeGrid}\n onRowClick={(e) => handleOnRowClick(e, true)}\n classRow={classes.classRow}\n />\n </>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n \"@global\": {\n \".ant-picker-time-panel-cell-disabled\": {\n display: \"none\"\n },\n },\n root: {},\n title: {\n fontFamily: \"Roboto\",\n fontSize: \"12px\",\n color: \"#919CA5\",\n margin: 0,\n },\n required: {\n color: \"#6462F3\",\n },\n\n cropArea: {\n border: \"none!important\",\n background: `linear-gradient(to right, #e5e5e5 3px, transparent 3px) 0 0,\n linear-gradient(to right, #e5e5e5 3px, transparent 3px) 0 100%,\n linear-gradient(to left, #e5e5e5 4px, transparent 3px) 100% 0,\n linear-gradient(to left, #e5e5e5 4px, transparent 3px) 100% 100%,\n linear-gradient(to bottom, #e5e5e5 3px, transparent 3px) 0 0,\n linear-gradient(to bottom, #e5e5e5 3px, transparent 3px) 100% 0,\n linear-gradient(to top, #e5e5e5 3px, transparent 3px) 0 99.7%,\n linear-gradient(to top, #e5e5e5 3px, transparent 3px) 100% 99.7%`,\n backgroundRepeat: 'no-repeat',\n backgroundSize: '30% 20%',\n },\n servicePhotoButtonContainer: {\n display: \"flex\",\n marginTop: 8,\n justifyContent: \"end\"\n },\n cropModalButtonContainer: {\n display: \"flex\",\n justifyContent: \"center\"\n },\n saveCropButton: {\n width: 270,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: \"15px\",\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n \"&.Mui-disabled\": {\n color: \"#F6F6F6\",\n opacity: 0.3,\n },\n },\n goBackButton: {\n width: 270,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n lineHeight: \"15px\",\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n cropSlider: {\n color: \"#ACB7C0\",\n '& .MuiSlider-thumb': { \n width: 25, \n height: 25,\n marginTop: -10\n \n },\n },\n crossIconContainer: { \n position: \"absolute\", \n right: 8,\n top: 15,\n zIndex: 99,\n cursor: \"pointer\"\n },\n servicePhotoTooltipBlock: {\n [`& .MuiTooltip-tooltip`]: {\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: theme.colors.grey1,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey5,\n boxShadow: \"0px 0px 4px #00000034\",\n position: \"absolute\",\n height: \"auto\",\n width: \"max-content\"\n },\n },\n cropSliderContainer: {\n display: \"flex\",\n alignItems: \"center\",\n gap: 21,\n marginLeft: 33,\n marginRight: 33,\n marginBottom: 42\n },\n cropInternalContainer: {\n height: \"83%\",\n backgroundColor: \"black\",\n },\n modalCropPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"29px 24px 47px 24px\",\n width: 736,\n height: 594,\n position: \"absolute\"\n },\n modalCropContainer: {\n margin: \"24px 0px 8px 0px\",\n height: \"95%\",\n display: \"flex\",\n flexDirection: \"column-reverse\",\n overflow: \"hidden\",\n },\n servicePhotoHeaderIcon: {\n marginLeft: 10,\n display: \"flex\",\n width: 20,\n height: 20,\n },\n servicePhotoHeaderButtons: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n margin: \"0px auto\"\n },\n cropContainerBlackBox: {\n marginLeft: \"auto\",\n marginRight: \"auto\",\n background: \"black\",\n height: \"108%\",\n padding: \"23px\",\n width: \"95%\",\n marginTop: \"-20px\",\n },\n cropContainer: {\n position: \"absolute\",\n overflow: \"hidden\",\n top: 80,\n left: 0,\n right: 0,\n bottom: 80,\n marginLeft: 50,\n marginRight: 50,\n padding: 10\n },\n deleteImageModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n textAlign: \"center\",\n color: \"#26292B\",\n },\n deleteImageModalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalDeleteImage: {\n height: 206\n },\n optional: {\n fontWeight: \"normal\",\n },\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n\n marginTop: 24,\n\n maxWidth: 813,\n },\n switch: {\n display: \"flex\",\n alignItems: \"center\",\n },\n switchLabel: {\n margin: \"0px 0px 0px 16px\",\n },\n label: {\n ...theme.typography.txtBody2,\n margin: 0,\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n display: \"block\",\n marginBottom: \"0.5rem\",\n },\n description: {\n margin: 0,\n color: \"#919CA5\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 399,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n color: \"#000\",\n textAlign: \"center\",\n fontFamily: \"Roboto\",\n fontSize: \"24px\",\n fontStyle: \"normal\",\n fontWeight: 700,\n lineHeight: \"28px\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n divUploadPhoto: {\n width: 228,\n height: 127,\n backgroundColor: theme.colors.grey1,\n border: \"dashed\",\n borderWidth: 1,\n borderColor: \"#DBDCDD\",\n borderRadius: 5,\n cursor: \"pointer\",\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\",\n backgroundPosition: \"center top\",\n display: \"grid\"\n },\n colPhoto: {\n width: 228\n },\n colNotes: {\n width: 557,\n \"& input\": {\n height: 190,\n backgroundColor: \"#F6F6F6\",\n boxSizing: \"border-box\",\n borderRadius: 5,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n width: 480,\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n border: \"solid 1px #6462F3\",\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n }\n },\n inputTextareaDescription: {\n height: 90,\n width: 480,\n\n padding: \"13px 0px 13px 12px\",\n\n boxSizing: \"border-box\",\n\n borderRadius: 5,\n border: \"solid\",\n borderWidth: 1,\n borderColor: \"rgba(0, 0, 0, 0.1)\",\n\n backgroundColor: theme.colors.grey1,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n },\n inputTextareaNotes: {\n height: 90,\n width: 813,\n\n padding: \"13px 0px 13px 12px\",\n\n boxSizing: \"border-box\",\n \n overflow: \"auto!important\",\n\n borderRadius: 5,\n border: \"solid\",\n borderWidth: 1,\n borderColor: \"rgba(0, 0, 0, 0.1)\",\n\n backgroundColor: theme.colors.grey1,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n\n border: \"solid\",\n borderWidth: 1,\n borderColor: theme.colors.clearMain,\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n },\n iconPlus: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: theme.colors.clearMain\n },\n labelAddPhoto: {\n marginTop: 0,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#919CA5\"\n },\n labelAddPhotoIns: {\n marginTop: -5,\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 9,\n color: \"#919CA5\",\n textAlign: \"center\",\n },\n divPhotoInfo: {\n width: \"100%\",\n display: \"inline\",\n },\n divPhotoInfoIcon: {\n display: \"inline\",\n width: 20,\n height: 20,\n textAlign: \"center\",\n position: \"relative\",\n top: 4,\n left: 2\n },\n divPhotoInfoLabel: {\n display: \"inline\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 11,\n color: \"#919CA5\",\n opacity: \"0.8\",\n position: \"relative\",\n left: -5\n },\n divPrice: {\n height: 62,\n },\n moneyIcon: {\n position: \"relative\",\n top: -30,\n right: -222,\n color: \"#5C6477\",\n width: 15,\n backgroundColor: theme.colors.grey1\n },\n divCategory: {\n width: 255,\n height: 62,\n },\n divPhotoExistHover: {\n width: 228,\n height: 127,\n borderRadius: 5,\n opacity: 0,\n top: 0,\n position: \"relative\",\n \"&:hover\": {\n background: \"rgba(29, 32, 39, 0.7)\",\n display: \"flow-root\",\n opacity: 0.7\n }\n },\n iconCam: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n },\n labelChangePhoto: {\n marginTop: 5,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n opacity: 1\n },\n selectStyle: {\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n padding: \"13px 0px 13px 12px\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 255,\n paddingRight: 10,\n backgroundColor: \"#F6F6F6\",\n cursor: \"pointer\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\",\n },\n \"& * input\": {\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n },\n selectHrs: {\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectHr: {\n \"& div:after\": {\n content: \"'hr'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectMin: {\n \"& div:after\": {\n content: \"'min'\",\n marginLeft: \"35px\",\n marginBottom: \"2px\",\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n selectStyleHrs: {\n position: \"relative\",\n top: 1,\n left: -150,\n fontFamily: \"Roboto\",\n fontWeight: \"bold\",\n fontSize: 12,\n fontStyle: \"normal\",\n },\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect, useRef } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport Cropper from \"react-easy-crop\";\nimport { Area, Point } from \"react-easy-crop/types\";\nimport \"antd/dist/antd.css\";\nimport { TimePicker } from \"antd\";\nimport moment from \"moment\";\n\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport Button from \"@material-ui/core/Button\";\nimport { Backdrop, Fade, Modal, Slider, Typography } from \"@material-ui/core\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport SelectWithLabel from \"../../../../common/SelectWithLabel\";\nimport Textarea from \"../../../../common/Textarea\";\nimport { SelectItem } from \"../../../../common/Select\";\nimport { PlusIcon, InfoIcon, MoneyIcon, CameraIcon, ArrowDropDownIcon, TrashIcon, EditIcon, CrossIcon, FlatImageIcon } from \"../../../../../assets/icons\";\nimport { AlphanumericRegex, CurrencyRegex } from \"../../../../../constants/validator\";\nimport Service, { ServiceValidator } from \"../../../../../models/service\";\nimport Category from \"../../../../../models/category\";\nimport CategorySelect from \"./../../CategorySelect\";\nimport ServicesService from \"./../../../../../api/settings-services-service\"\nimport WorkareasService from \"./../../../../../api/settings-workareas-service\"\nimport useStyles from \"./css\";\nimport { ServiceFormProps } from \"./props\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\n\nexport default function ServiceForm(props: ServiceFormProps) {\n\n const { settingsSelectedEstablishmentId, item, onChange, onModify } = props;\n\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n\n const imageRef = useRef<HTMLInputElement>(null);\n\n const [entityState, setEntityState] = useState<Service>(item || new Service());\n \n const [openDeleteImageModal, setOpenDeleteImageModal] = useState<boolean>(false);\n\n const [recurrenceList, setRecurrenceList] = useState<SelectItem[]>([]);\n const [workareaList, setWorkareaList] = useState<SelectItem[]>([]);\n \n const [showCropperModal, setShowCropperModal] = useState(false);\n const [cropImage, setCropImage] = useState<string | undefined>(\"\");\n const [crop, setCrop] = useState<Point>({ x: 0, y: 0 });\n const [cropZoom, setCropZoom] = useState<number>(1);\n const [croppedAreaPixels, setCroppedAreaPixels] = useState<Area | null>(null);\n \n const [timePickerIsOpen, setTimePickerIsOpen] = useState<boolean>(false);\n const [durationTime, setDurationTime] = useState<moment.Moment>(moment().utcOffset(0).set({\n hour: 1,\n minute: 0,\n second: 0,\n millisecond: 0\n }));\n\n const format = \"HH:mm\";\n const maxFileSize = 800 * 1024;\n const initialCropZoom = 0.815;\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n function runValidations(): ServiceValidator | undefined {\n if (item) {\n\n let priceValidator = item.price !== null && isNumber(item.price) ? CurrencyRegex.test(item.price!.toString()) : false;\n\n return {\n name: AlphanumericRegex.test(item.name),\n price: priceValidator,\n categoryId: item.categoryId !== \"\",\n duration: item.duration! > 0,\n recurrenceId: item.recurrenceId !== \"\",\n };\n }\n }\n\n function isNumber(n: any) {\n return !isNaN(parseFloat(n)) && !isNaN(n - 0);\n }\n\n const [entityValid, setEntityValid] = useState<ServiceValidator | undefined>(runValidations());\n\n const [selectedFile, setSelectedFile] = useState<any>();\n\n function showOpenFileDialog() {\n if (imageRef && imageRef.current) {\n imageRef.current.click();\n }\n }\n\n // Clean up the selection to avoid memory leak\n useEffect(() => {\n if (selectedFile) {\n const objectURL = URL.createObjectURL(selectedFile);\n return () => URL.revokeObjectURL(objectURL);\n }\n }, [selectedFile]);\n\n async function handleChangeFile(event: React.FormEvent<HTMLInputElement>) {\n\n event.stopPropagation();\n event.preventDefault();\n const files = imageRef.current?.files;\n\n if (files && files.length > 0) {\n if (imageRef && imageRef.current) {\n\n const validate = await isFileNotValid(files[0]);\n if (validate) return;\n\n setSelectedFile(files[0]);\n\n setEntityState({\n ...entityState,\n photoURL: URL.createObjectURL(files[0]),\n photoName: \"\",\n file: files[0]\n });\n runValidations();\n if (onModify) onModify();\n }\n }\n }\n \n function handleCropComplete(croppedArea: Area, croppedAreaPixels: Area) {\n setCroppedAreaPixels(croppedAreaPixels);\n }\n \n function handleZoomSliderChange(e: any, newValue: any) {\n setCropZoom(newValue);\n }\n \n function handleCropChange(crop: Point) {\n setCrop(crop);\n }\n \n function handleZoomChange(zoom: number) {\n setCropZoom(zoom);\n }\n \n function handleGoBackCropModalClick(){\n setShowCropperModal(false);\n }\n \n async function handleCropImage() {\n try {\n const croppedImageBlob = await getCroppedImg(cropImage, croppedAreaPixels);\n const croppedImageURL = URL.createObjectURL(croppedImageBlob);\n setSelectedFile(croppedImageBlob);\n const file = new File([croppedImageBlob], 'croppedImage.jpg', { type: croppedImageBlob.type });\n setEntityState({\n ...entityState,\n photoURL: croppedImageURL,\n photoName: \"\",\n file: file\n });\n runValidations();\n if (onModify) onModify();\n setShowCropperModal(false);\n } catch (error) {\n console.error('Error cropping image:', error);\n }\n }\n \n async function getCroppedImg(imageSrc: any, crop: any): Promise<Blob> {\n return new Promise((resolve, reject) => {\n fetch(\n imageSrc,\n {\n method: 'GET',\n headers: { \"Cache-Control\": 'no-cache' },\n }\n )\n .then(r => r.blob())\n .then(blob => {\n const imageUrl = URL.createObjectURL(blob);\n const image = new Image();\n \n image.onload = function() {\n const canvas = document.createElement('canvas');\n const ctx = canvas.getContext('2d');\n \n canvas.width = crop.width;\n canvas.height = crop.height;\n \n ctx!.drawImage(\n image,\n crop.x,\n crop.y,\n crop.width,\n crop.height,\n 0,\n 0,\n crop.width,\n crop.height\n );\n \n canvas.toBlob(\n (blob) => {\n if (!blob) {\n return;\n }\n resolve(blob);\n }, 'image/jpeg', 1);\n };\n \n image.crossOrigin = 'anonymous';\n image.src = imageUrl;\n });\n });\n }\n\n function handleOnClickDeleteServicePhoto() {\n if (entityState?.photoURL) {\n setOpenDeleteImageModal(true);\n }\n }\n \n async function handleDeleteServicePhoto(service: Service) {\n setEntityState({\n ...entityState,\n photoName: \"\",\n photoURL: \"\",\n file: null\n });\n if (imageRef && imageRef.current) {\n imageRef.current.files = new DataTransfer().files; // assign empty file list for input\n }\n if (onModify) onModify();\n setOpenDeleteImageModal(false);\n }\n \n function handleOnClickEditServicePhoto() {\n setCropZoom(initialCropZoom);\n setCropImage(entityState.photoURL);\n setShowCropperModal(true);\n }\n \n function handleCrossIconCropImageClick() {\n setEntityState({\n ...entityState,\n photoName: \"\",\n photoURL: \"\",\n file: null\n });\n if (imageRef && imageRef.current) {\n imageRef.current.files = new DataTransfer().files; // assign empty file list for input\n }\n setShowCropperModal(false);\n if (onModify) onModify();\n }\n \n const DivInfoDeleteImage: React.FC = () => {\n return (<>\n <div className={classes.deleteImageModalCenter} style={{ marginTop: 20 }}>\n <Typography className={classes.deleteImageModalContentText}>\n {t(\"Delete this photo?\")}\n </Typography>\n </div>\n </>);\n };\n\n useEffect(() => {\n (async () => {\n await getRecurrences();\n })();\n\n (async () => {\n await getWorkareas();\n })();\n\n if (item && item.duration) {\n setDurationTime(moment().utcOffset(0).set({ hour: 0, minute: item.duration, second: 0, millisecond: 0 }));\n }\n if (item && JSON.stringify(item) !== JSON.stringify(entityState)) {\n setEntityState(item);\n }\n\n (async () => {\n await getImage(item?.photoName);\n })();\n\n runValidations();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [item]);\n\n useEffect(() => {\n\n if (\n onChange\n && entityValid\n && entityValid.name\n && entityValid.price\n && entityValid.duration\n && entityValid.recurrenceId\n && entityValid.categoryId\n ) {\n onChange(true, entityState);\n } else if (onChange) {\n onChange(false, entityState);\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [entityState]);\n\n async function getRecurrences() {\n const data = await ServicesService.getRecurrences();\n\n let listItems: SelectItem[] = [];\n\n data.entity?.forEach(i => {\n listItems.push({\n key: i.id,\n value: t(i.name)\n .replace(\"weeks\", t(\"weeks\"))\n .replace(\"week\", t(\"week\"))\n .replace(\"months\", t(\"months\"))\n .replace(\"month\", t(\"month\"))\n })\n });\n\n setRecurrenceList(listItems || []);\n }\n\n async function getWorkareas() {\n const data = await WorkareasService.getWorkareas(1, 1000, settingsSelectedEstablishmentId);\n\n let listItems: SelectItem[] = [];\n\n data.entity?.forEach(i => {\n listItems.push({\n key: i.id,\n value: i.name\n })\n });\n\n setWorkareaList(listItems || []);\n }\n\n async function getImage(fileName: string | null = \"\") {\n\n let fileId = fileName || entityState.photoName;\n if (!fileId) return;\n\n const data = await ServicesService.getImage(fileId);\n\n setEntityState({\n ...entityState,\n photoURL: data.fileURL,\n });\n\n }\n\n function getTimePickerDurationPostfixClass() {\n const postfix = durationTime.hours() > 1 ? \"hrs\" : (durationTime.hours() === 1 ? \"hr\" : \"min\");\n switch (postfix) {\n case \"hrs\":\n return classes.selectHrs;\n case \"hr\":\n return classes.selectHr;\n case \"min\":\n return classes.selectMin;\n }\n }\n\n function handleChange(event: React.ChangeEvent<{ name: string, value: string }>) {\n let value = event.target.value;\n\n switch (event.target.name) {\n case \"name\":\n setEntityValid({\n ...entityValid,\n [event.target.name]: AlphanumericRegex.test(value)\n });\n break;\n case \"price\":\n setEntityValid({\n ...entityValid,\n [event.target.name]: CurrencyRegex.test(value)\n });\n break;\n }\n\n setEntityState({\n ...entityState,\n [event.target.name]: value\n });\n\n if (onModify) onModify();\n }\n\n function handleChangeRecurrence(event: React.ChangeEvent<{ value: string }>) {\n let value = event.target.value;\n\n setEntityValid({\n ...entityValid,\n recurrenceId: value !== \"\"\n });\n\n const recurrence: string = recurrenceList.filter(x => x.key == value)[0].value;\n\n setEntityState({\n ...entityState,\n recurrence: recurrence,\n recurrenceId: value\n });\n\n if (onModify) onModify();\n }\n\n function handleChangeWorkArea(event: React.ChangeEvent<{ value: string }>) {\n let value = event.target.value;\n\n setEntityState({\n ...entityState,\n workAreaId: value\n });\n\n if (onModify) onModify();\n }\n\n function handleSelectCategory(item: Category) {\n\n if (item) {\n\n setEntityValid({\n ...entityValid,\n categoryId: item.name !== \"\"\n });\n\n setEntityState({\n ...entityState,\n categoryId: item.id || \"\",\n category: item.name\n });\n\n if (onModify) onModify();\n }\n }\n\n function onDragOver(e: any) {\n e.preventDefault();\n }\n\n function onDragEnter(e: any) {\n e.preventDefault();\n }\n\n function onDragLeave(e: any) {\n e.preventDefault();\n }\n\n async function onFileDrop(e: any) {\n e.preventDefault();\n const files = e.dataTransfer.files;\n\n if (!(imageRef && imageRef.current)) {\n return;\n }\n\n imageRef.current.files = files;\n\n if (files && files.length > 0) {\n const validate = await isFileNotValid(files[0]);\n if (validate) return;\n\n setSelectedFile(files[0]);\n\n setEntityState({\n ...entityState,\n photoURL: URL.createObjectURL(files[0]),\n photoName: \"\",\n file: files[0]\n });\n\n if (onModify) onModify();\n }\n }\n\n async function isFileNotValid(file: any) {\n const validTypes = ['image/jpeg', 'image/jpg', 'image/png'];\n if (validTypes.indexOf(file.type) === -1) {\n return true;\n }\n\n return file.size > maxFileSize;\n }\n\n\n function handleDurationTime(time: moment.Moment) {\n\n const minutes = (time.hour() * 60) + time.minute();\n\n if (minutes < 1) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Invalid duration\"),\n })\n );\n return;\n }\n\n setDurationTime(time);\n\n setEntityValid({\n ...entityValid,\n duration: +minutes > 0\n });\n\n setEntityState({\n ...entityState,\n duration: minutes\n });\n\n if (onModify) onModify();\n\n setTimePickerIsOpen(false);\n }\n\n\n function handleOpenTimepicker(isOpen: boolean) {\n setTimePickerIsOpen(isOpen);\n }\n\n return (\n <div className={classes.root}>\n\n <div className={classes.rowContainer}>\n\n <InputWithLabel\n label={() => (\n <>\n {t(\"Service name\")} <span className={classes.required}>*</span>\n </>\n )}\n value={entityState?.name}\n placeholder={t(\"Enter the service name\")}\n width={255}\n isValid={() => entityValid?.name}\n name=\"name\"\n maxLength={60}\n onChange={handleChange}\n />\n\n <div className={classes.divPrice}>\n <InputWithLabel\n label={() => (\n <>\n {t(\"Price\")} <span className={classes.required}>*</span>\n </>\n )}\n value={entityState?.price}\n placeholder={t(\"Enter the price\")}\n width={255}\n isValid={() => entityValid?.price}\n name=\"price\"\n inputType=\"number\"\n onChange={handleChange}\n />\n\n <div className={classes.moneyIcon}>\n <MoneyIcon style={{ color: \"#5C6477\" }}/>\n </div>\n </div>\n <div className={classes.divCategory}>\n <CategorySelect\n onSelect={handleSelectCategory}\n item={item}\n widthSelect={255}\n isOptional={false}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n </div>\n </div>\n\n <div className={classes.rowContainer}>\n\n <div>\n <label className={classes.label}>\n {t(\"Estimated duration\")}{\" \"}<span className={classes.required}>*</span>\n </label>\n\n <TimePicker\n onOk={(time) => {\n handleDurationTime(time);\n }}\n className={`${classes.selectStyle} ${getTimePickerDurationPostfixClass()}`}\n placeholder=\"HH:mm\"\n inputReadOnly={true}\n showNow={false}\n value={durationTime}\n disabledHours={() => [21, 22, 23]}\n onOpenChange={(e) =>\n handleOpenTimepicker(e)\n }\n format={format}\n />\n\n <ArrowDropDownIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: \"#5C6477\",\n position: \"relative\",\n transform: timePickerIsOpen\n ? \"rotate(180deg)\"\n : \"rotate(0deg)\",\n }}\n />\n </div>\n\n <SelectWithLabel\n label={() => (\n <>\n {t(\"Recurrence\")}{\" \"}<span className={classes.required}>*</span>\n </>\n )}\n isValid={() => entityValid?.recurrenceId}\n items={recurrenceList}\n placeholder={t(\"Select an option\")}\n width={255}\n name=\"recurrenceid\"\n onChange={handleChangeRecurrence}\n value={entityState?.recurrenceId}\n />\n\n <SelectWithLabel\n label={() => (\n <>\n {t(\"Work area\")}{\" \"}\n <span className={classes.optional}>({t(\"Optional\")})</span>\n </>\n )}\n items={workareaList}\n placeholder={t(\"Select one of your list\")}\n width={255}\n name=\"workareaId\"\n onChange={handleChangeWorkArea}\n value={entityState?.workAreaId}\n />\n </div>\n\n <div className={classes.rowContainer}>\n <div className={classes.colPhoto}>\n\n <label htmlFor={\"lblPhoto\"} className={classes.label}>\n {t(\"Service photo\")} <span className={classes.optional}>({t(\"Optional\")})</span>\n </label>\n\n <input\n ref={imageRef!}\n type=\"file\"\n style={{ display: 'none' }}\n accept=\"image/jpeg, image/jpg, image/png\"\n onChange={handleChangeFile}\n />\n <div\n className={`${classes.divUploadPhoto}`}\n onClick={showOpenFileDialog}\n style={{ backgroundImage: `url(${entityState.photoURL})` }}\n onDragOver={onDragOver}\n onDragEnter={onDragEnter}\n onDragLeave={onDragLeave}\n onDrop={onFileDrop}\n >\n {\n entityState.photoURL && <div className={classes.divPhotoExistHover}>\n <div className={classes.iconCam}>\n <CameraIcon/>\n </div>\n <div className={classes.labelChangePhoto}>\n {t(\"Change photo\")}\n </div>\n </div>\n }\n {\n !entityState.photoURL && <>\n <div className={classes.iconPlus}>\n <PlusIcon style={{ color: \"#6462F3\" }}/>\n </div>\n <div className={classes.labelAddPhoto}>\n {t(\"Add photo\")}\n </div>\n <div className={classes.labelAddPhotoIns}>\n {t(\"Recommended size\") + \": 430px x 240px\"}\n </div>\n </>\n }\n </div>\n {entityState.photoURL && <div className={classes.servicePhotoButtonContainer}>\n <Tooltip\n title={`${t(\"Edit photograph\")}`}\n placement=\"bottom-start\"\n classes={{ popper: classes.servicePhotoTooltipBlock }}>\n <div className={classes.servicePhotoHeaderIcon}>\n <EditIcon\n className={classes.servicePhotoHeaderButtons}\n style={{ width: 16, height: 16, }}\n onClick={handleOnClickEditServicePhoto}\n />\n </div>\n </Tooltip>\n <span className={classes.servicePhotoHeaderIcon}>\n <TrashIcon\n className={classes.servicePhotoHeaderButtons}\n style={{ width: 13, height: 17, color: \"#919CA5\", }}\n onClick={handleOnClickDeleteServicePhoto}\n />\n </span>\n </div>}\n\n </div>\n <div className={classes.colNotes}>\n <label htmlFor={\"lblDescription\"} className={classes.label}>\n {t(\"Service description\")} <span className={classes.optional}> {\" \"} ({t(\"Optional\")})</span>\n </label>\n\n <Textarea\n inputClass={`${classes.inputTextareaDescription}`}\n id={\"description\"}\n name={\"description\"}\n showCounter={true}\n maxLength={224}\n value={entityState?.description}\n onChange={handleChange}\n placeholder={t(\"Write a short description of the service here.\")}\n width={557}\n styles={{ height: 127 }}\n />\n </div>\n </div>\n <div className={classes.rowContainer}>\n <div>\n <label htmlFor={\"lblNotes\"} className={classes.label}>\n {t(\"Notes prior to the service\")}\n <span className={classes.optional}> {\" \"} ({t(\"Optional\")})</span>\n <IconTooltip\n classNameRoot={classes.iconTooltipRoot}\n icon={<InfoIcon style={{ width: 12, height: 12, marginLeft: 4 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Notes will be provided to the customer prior to their appointment and by WhatsApp.\")}\n />\n </label>\n\n <Textarea\n inputClass={`${classes.inputTextareaNotes}`}\n id={\"notes\"}\n name={\"notes\"}\n maxLength={600}\n showCounter={true}\n value={entityState?.notes}\n onChange={handleChange}\n placeholder={t(\"Write your pre-service notes here.\")}\n width={813}\n styles={{ height: 61 }}\n />\n </div>\n </div>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={showCropperModal}\n onClose={() => setShowCropperModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{ timeout: 500, }}\n >\n <Fade in={showCropperModal}>\n <div className={classes.modalCropPaper}>\n <Typography className={classes.modalHeader}>\n {t(\"Crop photo\")}\n </Typography>\n <div className={`${classes.modalCropContainer}`}>\n <div className={classes.cropContainer}>\n <div className={classes.crossIconContainer} onClick={handleCrossIconCropImageClick}>\n <CrossIcon color={\"white\"}/>\n </div>\n <Cropper\n image={entityState.photoURL}\n maxZoom={10}\n minZoom={initialCropZoom}\n classes={{\n cropAreaClassName: classes.cropArea,\n containerClassName: classes.cropInternalContainer,\n }}\n objectFit={\"cover\"}\n crop={crop}\n zoom={cropZoom}\n showGrid={false}\n cropSize={{width: 522, height: 294}}\n onCropChange={handleCropChange}\n onCropComplete={handleCropComplete}\n onZoomChange={handleZoomChange}\n />\n \n </div>\n <div>\n <div className={classes.cropSliderContainer}>\n <FlatImageIcon color={\"#ACB7C0\"} style={{ width: 25, height: 25 }}/>\n <Slider\n min={initialCropZoom}\n max={10}\n className={classes.cropSlider}\n step={0.001}\n value={cropZoom}\n onChange={handleZoomSliderChange}\n />\n <FlatImageIcon color={\"#ACB7C0\"}/>\n </div>\n \n <div className={classes.cropModalButtonContainer}>\n <Button\n className={`${classes.goBackButton}`}\n onClick={handleGoBackCropModalClick}>\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.saveCropButton}`}\n onClick={handleCropImage}>\n {t(\"Save\")}\n </Button>\n </div>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n <ConfirmDeleteModal\n classModal={classes.modalDeleteImage}\n open={openDeleteImageModal}\n item={item}\n componentInfo={<DivInfoDeleteImage />}\n onClose={() => setOpenDeleteImageModal(false)}\n onDelete={handleDeleteServicePhoto}\n />\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 895,\n height: 575,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalTitleTextCancel: {\n marginTop: 0,\n marginBottom: 20,\n fontSize: 18,\n fontWeight: \"bold\"\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n createCustomer: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n iconTrash: {\n display: \"inline\",\n cursor: \"pointer\",\n width: 30,\n height: 30,\n color: \"#919CA5\",\n borderRadius: 25\n },\n modalCancelPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"12px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 472,\n minHeight: 153,\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n }\n}));\n\nexport default useStyles;\n","import React, { useState, useEffect, useRef } from \"react\";\n\nimport { useTranslation } from 'react-i18next';\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport EntityService from \"../../../../../api/settings-services-service\";\nimport ServiceForm from './../ServiceForm'\nimport Service from \"../../../../../models/service\";\nimport { TrashIcon } from \"../../../../../assets/icons\";\nimport useStyles from \"./css\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\n\nexport default function ServiceModal(props: any) {\n \n const {settingsSelectedEstablishmentId, open, onClose, onCreate, item, onDelete } = props;\n \n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n \n const isNewItem: boolean = item === null;\n const [entityState, setEntityState] = useState<Service>(new Service());\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [cancelModal, setCancelModal] = useState<boolean>(false);\n const [madeChange, setMadeChange] = useState<boolean>(false);\n const [disableSave, setDisableSave] = useState<boolean>(true);\n const [isValid, _setIsValid] = useState<boolean>(false);\n const isValidRef = useRef(isValid);\n \n const setIsValid = (data: boolean) => {\n isValidRef.current = data;\n _setIsValid(data);\n };\n \n \n useEffect(() => {\n setOpenModal(open);\n setMadeChange(false);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n \n \n async function handleOnCreateClick() {\n \n if (isValid) {\n \n let filename: string = \"\";\n \n const file = entityState.file;\n \n if (file) {\n let data: any = await EntityService.saveImage(file);\n filename = data.fileName;\n }\n \n const service: Service = {\n ...entityState,\n photoName: filename || entityState.photoName || \"\",\n file: null\n };\n let entity: any;\n if (isNewItem) {\n entity = await EntityService.createService(service, settingsSelectedEstablishmentId);\n } else {\n entity = await EntityService.updateService(service, settingsSelectedEstablishmentId);\n }\n \n \n const newEntity: Service = { ...entityState, id: entity.id, photoName: filename, file: null };\n setEntityState(newEntity);\n \n if (onCreate) {\n onCreate(newEntity, isNewItem);\n onClose();\n }\n }\n }\n \n \n function handleFormChange(isValid: boolean, entity: Service) {\n setIsValid(isValid);\n setEntityState(entity);\n \n setDisableSave(!(madeChange && isValid));\n }\n \n function handleModifying() {\n setMadeChange(true);\n setDisableSave(!isValid);\n }\n \n return (\n <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={(event, reason) => {\n if (reason === 'backdropClick') {\n if (madeChange)\n setCancelModal(true);\n else\n onClose();\n }\n }}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={openModal}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n \n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {isNewItem ? t('New service') : t('Service detail')}\n </Typography>\n </div>\n \n <div className={classes.modalActions}>\n \n {!isNewItem &&\n <Button className={`${classes.iconTrash}`} onClick={() => onDelete(item)}>\n <TrashIcon style={{ color: \"#919CA5\", fontSize: 14 }}/>\n </Button>\n }\n \n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={() => { madeChange ? setCancelModal(true) : onClose() }}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={isNewItem ? t(\"Create service\") : t(\"Save changes\")}\n onClick={handleOnCreateClick}\n disabled={disableSave}\n />\n </div>\n </div>\n \n <ServiceForm\n item={item}\n onChange={handleFormChange}\n onModify={handleModifying}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n </div>\n </Fade>\n </Modal>\n \n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={cancelModal}\n onClose={() => setCancelModal(false)}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={cancelModal}>\n <div className={classes.modalCancelPaper}>\n <div className={classes.modalContent}>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleTextCancel}>\n {item ? t(\"Cancel service edition?\") : t(\"Cancel service registration?\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n \n onClick={() => setCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.cancelConfirmation}`}\n onClick={() => {\n setCancelModal(false);\n onClose();\n }}\n >\n {t(\"WorkAreaModalCancelEditConfirm\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n </>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: 288,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"80%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\"\n },\n deleteBtn: {\n fontWeight: \"bold\",\n fontSize: 12,\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { TrashIcon, CrossIcon } from \"./../../../../../assets/icons\";\n\nimport useStyles from \"./css\";\nimport { ServiceDeleteModalProps } from \"./props\";\n\nconst ServiceDeleteModal = (props: ServiceDeleteModalProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { open, item, onClose, onDelete } = props;\n const classes = useStyles();\n\n const handleDelete = () => {\n if (typeof onDelete === \"function\") onDelete(item);\n };\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n <div className={classes.modalClose}>\n <span className={classes.closeButton} onClick={onClose}>\n <CrossIcon />\n </span>\n </div>\n </div>\n\n <div className={classes.modalContent}>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"Delete this service?\")}\n </Typography>\n </div>\n\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentTextTitle}>\n {item?.name}\n </Typography>\n </div>\n\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.goBack}`} onClick={onClose} >\n {t(\"Go back\")}\n </Button>\n\n <Button className={`${classes.button} ${classes.deleteBtn}`} onClick={handleDelete} >\n {t(\"Delete\")}\n </Button>\n </div>\n\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default ServiceDeleteModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"40px 40px 48px\",\n width: 812,\n height: 344,\n },\n cancelModalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"50px 40px 55px\",\n width: 523,\n height: 216,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n paddingBottom: \"12px\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: \"#5C6477\",\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n goBack: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: \"#ACB7C0\",\n },\n uploadButton: {\n background: theme.colors.clearGreen,\n color: theme.colors.grey1,\n\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n title: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n margin: 0,\n },\n\n rowContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n margin: \"24px 0px 0px 0px\",\n },\n\n dropZone: {\n height: \"136px\",\n width: \"373px\",\n background: \"rgba(100, 98, 243, 0.1)\",\n border: \"0px dashed\",\n borderRadius: \"15px\",\n borderColor: theme.colors.clearMain,\n minHeight: \"100px\",\n backgroundImage: `url(\"data:image/svg+xml,%3csvg width='100%25' height='100%25' xmlns='http://www.w3.org/2000/svg'%3e%3crect width='100%25' height='100%25' fill='none' rx='15' ry='15' stroke='%236462F3FF' stroke-width='2' stroke-dasharray='12%2c 12' stroke-dashoffset='0' stroke-linecap='round'/%3e%3c/svg%3e\")`,\n animation: 'none !important',\n },\n\n dropZoneText: {\n color: theme.colors.clearMain,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n position: \"relative\",\n top: \"70px\",\n },\n fileName: {\n color: theme.colors.grey5,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n },\n fileSize: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n paddingTop: \"4px\",\n },\n fileSizeBold: {\n color: theme.colors.grey3,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n },\n downloadTemplate: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n color: theme.colors.grey5,\n cursor: \"pointer\",\n },\n notesTitle: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n notes: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n display: \"flex\",\n color: theme.colors.grey5,\n },\n divider: {\n borderTop: \"1px solid\",\n borderColor: theme.colors.grey2,\n marginTop: \"24px\",\n marginBottom: \"24px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginBottom: 8,\n },\n cancelModalButton: {\n width: 244,\n height: 39,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 14,\n },\n cancelConfirmation: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n modalTitleTextCancel: {\n marginBottom: 57,\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontSize: 18,\n fontWeight: \"bold\"\n },\n goBackCancel: {\n marginRight: 38,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n link: {\n color: theme.colors.clearMain,\n cursor: \"pointer\"\n }\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from 'react';\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport { Box, Grid } from \"@material-ui/core\";\nimport { DropzoneAreaBase, FileObject } from \"material-ui-dropzone\";\n\nimport { ServiceImportModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport ServicesService from \"../../../../../api/settings-services-service\";\nimport FileService from \"../../../../../api/file-service\";\nimport { DownloadFileCloud, ExcelIcon, UploadFileCloud } from \"../../../../../assets/icons\";\nimport ButtonWithSpinner from '../../../../common/ButtonWithSpinner';\nimport { ButtonPropsBorderRadius } from '../../../../../models/enums/button-props-border-radius';\nimport { ButtonPropsColor } from '../../../../../models/enums/button-props-color';\n\n\nexport default function ServiceImportModal(props: ServiceImportModalProps) {\n\n const { t } = useTranslation([\"general\"]);\n const { settingsSelectedEstablishmentId, open, onClose, refreshServices } = props;\n const classes = useStyles();\n\n const [openModal, setOpenModal] = useState<boolean>(false);\n const [openCancelModal, setOpenCancelModal] = useState<boolean>(false);\n\n const [cancelModalShouldAppear, setCancelModalShouldAppear] = useState<boolean>(false);\n\n const [templateFileName, setTemplateFileName] = useState<string>(\"\");\n\n const [file, setFile] = useState<FileObject[]>([]);\n const [fileSize, setFileSize] = useState<number>(0);\n const [fileName, setFileName] = useState<string>(t(\"No file.\"));\n const [isValid, setIsValid] = useState<boolean>(false);\n\n const maxFileSize: number = 1 * 1024 * 1024; //1 megabyte\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n\n const { enqueueAlert } = alertsActions;\n const dispatch = useAppDispatch();\n\n const servicesImportTitle = t(\"Import of services\")\n const servicesAddedDescription = t(\"Services were added successfully\")\n const servicesNotImportedDescription = t(\"Services were not imported\")\n\n const templateFileNameEN = \"List_of_services.xlsx\";\n const templateFileNameES = \"Lista_de_servicios.xlsx\";\n\n useEffect(() => {\n setTemplateFileName(localeApp === 'es' ? templateFileNameES : templateFileNameEN)\n }, [localeApp]);\n\n useEffect(() => {\n setOpenModal(open);\n if (open) {\n cleanupModal();\n }\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [open]);\n\n function handleTryCloseModal() {\n if (cancelModalShouldAppear) {\n setOpenCancelModal(true);\n } else {\n handleCloseModal();\n }\n }\n\n function handleCloseModal() {\n setOpenModal(false);\n if (onClose) {\n onClose();\n }\n }\n\n async function handleOnUploadClick() {\n if (isValid) {\n setIsValid(false);\n let uploadResponse = await ServicesService.createServicesFromFile(\n file[0].file,\n settingsSelectedEstablishmentId\n );\n\n if (!uploadResponse.isFileProcessed) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"File could not be uploaded\"),\n description: servicesNotImportedDescription\n })\n );\n\n handleCloseModal();\n return;\n }\n\n const processed: string = uploadResponse.processedRecordsCount! + \"\";\n const total: string = uploadResponse.totalRecordsCount! + \"\";\n\n if (uploadResponse.processedRecordsCount == uploadResponse.totalRecordsCount) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: servicesImportTitle,\n description: servicesAddedDescription\n })\n );\n\n handleCloseModal();\n refreshServices();\n return;\n }\n\n if (uploadResponse.processedRecordsCount! < uploadResponse.totalRecordsCount!) {\n dispatch(\n enqueueAlert({\n type: \"Warning\",\n title: servicesImportTitle,\n description:\n <>\n {t(\"{n} of {m} records were uploaded\").replace(\"{n}\", processed).replace(\"{m}\", total)}\n <div\n className={classes.link}\n onClick={async () => await handleOnDownloadClick(uploadResponse.invalidRecordsFile)}\n >\n {t(\"View records that were not loaded\")}\n </div>\n </>\n })\n );\n\n handleCloseModal();\n refreshServices();\n return;\n }\n }\n\n cleanupModal();\n }\n\n async function handleOnDownloadClick(responseFile: Uint8Array | null) {\n if (responseFile) {\n const fileUrl = URL.createObjectURL(new Blob([responseFile], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'}));\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", fileUrl);\n link.setAttribute(\"download\", templateFileName);\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n }\n\n function handleOnAddFile(files: FileObject[]) {\n setFile(files);\n setFileName(files[0].file.name);\n let size = files[0].file.size / (1024 * 1024);\n setFileSize(Math.round((size + Number.EPSILON) * 100) / 100); // in megabytes\n setIsValid(validateFile(files[0].file));\n setCancelModalShouldAppear(true);\n }\n\n function handleDropRejected(file: File[]) {\n if (file[0].name.split(\".\").pop() !== \"xlsx\") {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Use the indicated .xlsx format\")\n })\n );\n }\n }\n\n function validateFile(file: File) {\n if (file.size > maxFileSize)\n return false;\n\n return file.name.split(\".\").pop() === \"xlsx\";\n }\n\n function cleanupModal() {\n setFile([]);\n setFileName(t(\"No file.\"));\n setFileSize(0);\n setIsValid(false);\n setCancelModalShouldAppear(false);\n setOpenCancelModal(false);\n }\n\n async function downloadTemplateFile() {\n const fileUrl = await FileService.getTemplateFileUrl(templateFileName, localeApp!);\n\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", fileUrl);\n link.setAttribute(\"download\", templateFileName);\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n }\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={openModal}\n onClose={handleTryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={openModal}>\n <div>\n <div\n className={classes.paper}\n style={openCancelModal ? { display: \"none\" } : {}}\n >\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {t(\"Import services\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={handleTryCloseModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Upload file\")}\n onClick={handleOnUploadClick}\n disabled={!isValid}\n />\n </div>\n </div>\n <Box sx={{ width: \"100%\" }} pt={1}>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <DropzoneAreaBase\n dropzoneClass={classes.dropZone}\n dropzoneParagraphClass={classes.dropZoneText}\n fileObjects={file}\n dropzoneText={t(\n \"Drag or click here to upload your .xlsx file\"\n )}\n onAdd={handleOnAddFile}\n showPreviewsInDropzone={false}\n showAlerts={false}\n filesLimit={1}\n acceptedFiles={[\n \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\",\n ]}\n maxFileSize={maxFileSize}\n onDropRejected={handleDropRejected}\n // @ts-ignore: type negotiation problem\n Icon={UploadFileCloud} // works and builds but https://github.com/Yuvaleros/material-ui-dropzone/issues/246\n />\n </Grid>\n <Grid item xs={1} style={{ paddingLeft: \"38px\" }}>\n <ExcelIcon\n style={isValid ? { color: \"#6462F3\" } : {}}\n />\n </Grid>\n <Grid\n item\n xs={5}\n style={{ paddingLeft: \"48px\", paddingTop: \"30px\" }}\n >\n <Typography className={classes.fileName}>\n {fileName}\n </Typography>\n <Typography className={classes.fileSize}>\n {t(\"Size: \")}\n <b>{fileSize} MB</b>\n </Typography>\n </Grid>\n </Grid>\n <hr className={classes.divider}/>\n <Grid container spacing={3}>\n <Grid item xs={6}>\n <Typography className={classes.notesTitle}>\n {t(\"NOTES: \")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Accepted format: xlsx\")}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Maximum allowed document size: 1 Mb\")}\n </Typography>\n </Grid>\n <Grid\n item\n xs={6}\n container\n direction=\"row\"\n alignItems=\"center\"\n justifyContent=\"flex-end\"\n >\n <Typography\n className={classes.downloadTemplate}\n onClick={downloadTemplateFile}\n >\n <DownloadFileCloud\n style={{ fontSize: 18, margin: \"0px 4px 2px 0px\" }}\n />\n {t(\"Download template\")}\n </Typography>\n </Grid>\n </Grid>\n </Box>\n </div>\n <div\n className={classes.cancelModalPaper}\n style={openCancelModal ? {} : { display: \"none\" }}\n >\n <div\n className={`${classes.modalCenter} ${classes.modalTitleSpace}`}\n >\n <Typography className={classes.modalTitleTextCancel}>\n {t(\"Cancel the upload of the .xlsx file?\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.cancelModalButton} ${classes.goBackCancel}`}\n onClick={() => setOpenCancelModal(false)}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.cancelModalButton} ${classes.cancelConfirmation}`}\n onClick={handleCloseModal}\n >\n {t(\"Yes, cancel it\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nimport { Color } from \"../../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n header: {\n marginBottom: 10,\n paddingTop: 5\n },\n headerRight: {\n textAlign: \"right\"\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\"\n },\n btnNewWorkArea: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n },\n titles: {\n color: Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\",\n marginBottom: 10\n },\n icons: {\n color: Color.gray5,\n fontSize: 18\n },\n icon: {\n paddingTop: 5,\n height: 30,\n width: 30,\n fontWeight: \"bold\"\n },\n noteHeader: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n}));\n\n\nexport default useStyles;\n","import React, { useState } from \"react\";\n\nimport { useTranslation } from 'react-i18next';\n\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport EntityService from \"../../../../../api/settings-services-service\";\nimport Service from \"../../../../../models/service\";\nimport ServiceGrid from \"../ServiceGrid\";\nimport ServiceModal from '../ServiceModal';\nimport ServiceDeleteModal from './../ServiceDeleteModal';\nimport ServiceImportModal from \"../ServiceImportModal\";\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport { Typography } from \"@material-ui/core\";\nimport SectionNote from \"../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote\";\nimport useStyles from \"./css\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\n\n\nexport default function ServiceMain(props: SettingsEnterpriseProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"general\"]);\n\n const classes = useStyles();\n\n const [isRefresh, setIsRefresh] = useState<any>();\n\n const [openItemEditModal, setOpenItemEditModal] = useState<boolean>(false);\n const [openItemDeleteModal, setOpenItemDeleteModal] = useState<boolean>(false);\n\n const [itemModal, setItemModal] = useState<Service | null>(null);\n\n const [newItem, setNewItem] = useState<Service | null>(null);\n\n const [openServiceImportModal, setOpenServiceImportModal] = useState<boolean>(false);\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n function handleCreate(entity: any) {\n setItemModal(null);\n setOpenItemEditModal(true);\n setIsRefresh(entity);\n }\n\n function handleRowClick(item: Service) {\n setOpenItemEditModal(true);\n setItemModal(item);\n }\n\n function handleDelete(item: any) {\n setItemModal(item);\n setOpenItemDeleteModal(true);\n }\n\n function handleCreated(item: Service, isNew: boolean) {\n setOpenItemEditModal(false);\n\n let alertString = isNew ? \"New service created successfully\" : \"Service has been updated\";\n\n let func = isNew ? setNewItem : setIsRefresh;\n\n let alertTitle: string = t(alertString);\n\n func(item);\n displayAlert(alertTitle, item.name)\n }\n\n function displayAlert(title: string, description: string) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: title,\n description: description\n })\n );\n }\n\n function handleOpenImportModal() {\n setOpenServiceImportModal(true)\n }\n\n async function handleDeleted(item: any) {\n\n const deletedEntity = await EntityService.deleteService(item);\n\n if (deletedEntity.forbiddenDelete) {\n setOpenItemDeleteModal(false);\n\n dispatch(\n enqueueAlert({\n type: \"Warning\",\n title: t(\"Service cannot be deleted\"),\n description: `${item.name} ${t(\"cannot be deleted because it has one or more future appointments associate\")}`\n })\n );\n } else if (deletedEntity) {\n setOpenItemEditModal(false);\n setOpenItemDeleteModal(false);\n setIsRefresh(item);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Service has been deleted\"),\n description: `${item.name} ${t(\"has been deleted\")}`\n })\n );\n }\n }\n\n return (\n <>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.noteHeader}>\n <Typography className={classes.tabTitle}>\n {t(\"Services\")}\n </Typography>\n </div>\n <SectionNote \n sectionData={SectionNoteData.Services}\n />\n </>\n )}\n\n <ServiceGrid\n isRefresh={isRefresh}\n item={newItem}\n openImportModal={handleOpenImportModal}\n openItemEditModal={handleRowClick}\n openDeleteModal={handleDelete}\n handleCreate={handleCreate}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n\n <ServiceModal\n open={openItemEditModal}\n item={itemModal}\n onClose={() => setOpenItemEditModal(false)}\n onCreate={handleCreated}\n onDelete={handleDelete}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n\n <ServiceImportModal\n open={openServiceImportModal}\n onClose={() => setOpenServiceImportModal(false)}\n refreshServices={() => {\n setIsRefresh(Math.random())\n }}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n\n <ServiceDeleteModal\n open={openItemDeleteModal}\n item={itemModal}\n onClose={() => setOpenItemDeleteModal(false)}\n onDelete={handleDeleted}\n />\n </>\n );\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n newButton: {\n marginLeft: \"auto\",\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n sectionsContainer: {\n border: \"1px solid\",\n borderColor: \"#DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"auto\",\n overflow: \"hidden\"\n },\n communicationSettingsContainer: {\n border: \"1px solid\",\n borderColor: \"#DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"auto\",\n backgroundColor: \"#FFFFFF\",\n overflow: \"hidden\"\n },\n mainTitle: {\n fontWeight: 700,\n fontSize: 14,\n color: \"#919CA5\"\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n },\n checkboxTitle: {\n fontWeight: 400,\n fontSize: 14,\n color: \"#919CA5\"\n },\n tinyMceOverrides: {\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n position: \"relative\",\n padding: \"15px 0px 23px 47px\"\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n charCounter: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"10px\",\n lineHeight: \"12px\",\n position: \"absolute\",\n paddingRight: 15,\n marginTop: \"-18px\",\n marginRight: \"15px\",\n color: theme.colors.grey5\n },\n communicationSettingsMainTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"14px\",\n marginBottom: \"13px\",\n color: \"#919CA5\"\n },\n communicationSettingsCheckboxGroupTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n marginBottom: \"20px\",\n color: \"#919CA5\"\n },\n communicationSettingsHeader: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n marginBottom: \"16px\",\n color: \"#5C6477\"\n },\n previewButton: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n border: \"1px solid \" + Color.clear1,\n color: Color.clear1,\n },\n counterWrapper: {\n display: \"flex\",\n justifyContent: \"flex-end\"\n },\n clinicalHistorySwitch: {\n marginLeft: 11,\n },\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 720,\n height: 210,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n padding: \"26px 40px 22px 40px\"\n },\n modalTitle: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 5,\n width: \"100%\",\n \"& svg path\": {\n fill: theme.colors.grey5\n }\n },\n modalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n gap: 16\n },\n goBack: {\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n content: {\n backgroundColor: \"#FAFAFA\",\n height: \"100%\",\n padding: \"33px 40px\",\n borderRadius: \"10px\",\n },\n requiredAsterisk: {\n color: Color.clear1,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n closeConfirmationModal: {\n height: \"234px + !important\"\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { SectionNewModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport { SectionNewIcon } from \"../../../../../assets/icons\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport ConfirmActionModal from \"../../../../common/ConfirmActionModal\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\nexport default function SectionNewModal(props: SectionNewModalProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n\n const { sections, isOpen, setOpen, onCreate } = props;\n const classes = useStyles();\n\n const maxTextFieldLength = 200;\n\n const [justOpened, setJustOpened] = useState<boolean>(true); //need to make input look valid on open\n const [dataIsValid, setDataIsValid] = useState<boolean>(false);\n const [name, setName] = useState<string>(\"\");\n const [closeConfirmationModalIsOpen, setCloseConfirmationModalIsOpen] = useState<boolean>(false);\n\n const handleOnClose = () => {\n setCloseConfirmationModalIsOpen(false);\n setOpen(false);\n setDataIsValid(false);\n setName(\"\");\n setJustOpened(true);\n };\n\n const handleAddButtonClick = async () => {\n if (!dataIsValid)\n return;\n\n await onCreate(name);\n handleOnClose();\n };\n\n const tryCloseModal = () => {\n if (name === \"\") {\n handleOnClose()\n }\n else {\n setCloseConfirmationModalIsOpen(true);\n }\n };\n\n const handleOnChange = (event: React.ChangeEvent<{ value: string }>) => {\n const localName = event.target.value;\n if (localName.length > maxTextFieldLength ||\n localName.trim().length === 0 ||\n (sections && !nameIsAlreadyUsed(localName))) {\n setDataIsValid(false);\n setName(localName);\n return;\n }\n\n if (justOpened)\n setJustOpened(false);\n\n setName(localName);\n setDataIsValid(true);\n };\n \n const nameIsAlreadyUsed = (localName: any) => {\n let newSectionName = localName\n .trim()\n .toLowerCase()\n .normalize('NFD')\n .replace(/\\p{Diacritic}/gu, '');\n \n let currentSectionNames = sections!.map(s => t(s.name!, { ns: sectionTNamespace })\n .trim()\n .toLowerCase()\n .normalize('NFD')\n .replace(/\\p{Diacritic}/gu, ''));\n \n return !currentSectionNames.includes(newSectionName);\n };\n\n const CloseModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {t(\"Are you sure you want to cancel the creation of the new section?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {t(\"The changes made will not be saved\")}\n </Typography>\n </div>);\n };\n\n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={tryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n <Fade in={isOpen}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <SectionNewIcon />\n <Typography className={classes.modalTitleText}>\n {t(\"New section\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t\t backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={tryCloseModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t \t backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Add\")}\n onClick={handleAddButtonClick}\n\t\t \t disabled={!dataIsValid}\n />\n </div>\n </div>\n <div className={classes.content}>\n <InputWithLabel\n label={() => <>{t(\"Name\")} <span className={classes.requiredAsterisk}>*</span></>}\n placeholder={t(\"Enter the name of the section\")}\n value={name}\n showCounter={true}\n width={637}\n name=\"name\"\n maxLength={200}\n onChange={(e) => handleOnChange(e)}\n isValid={() => justOpened || dataIsValid}\n />\n </div>\n </div>\n </Fade>\n </Modal>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<CloseModalContent />}\n open={closeConfirmationModalIsOpen}\n onClose={() => setCloseConfirmationModalIsOpen(false)}\n onConfirm={handleOnClose}\n />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n sectionsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n paddingBottom: 32\n },\n sectionContainer: {\n border: \"1px solid\",\n borderColor: \"#DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"auto\",\n overflow: \"hidden\",\n },\n headerContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n backgroundColor: Color.gray1,\n height: 57,\n width: \"100%\",\n paddingLeft: 32,\n paddingRight: 22\n },\n headerTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray7\n },\n headerButtonsContainer: {\n\n },\n headerButton: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n },\n headerButtonDisabled: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n \"& svg path\": {\n fill: Color.gray2\n }\n },\n innerLayout: {\n width: \"100%\",\n padding: 16\n },\n fieldsContainer: {\n\n },\n noItemsBox: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n height: 80,\n width: \"100%\",\n backgroundColor: Color.gray1,\n borderRadius: 10,\n },\n noItemsLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"21px\",\n lineHeight: \"25px\",\n color: Color.gray4\n },\n footerContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n paddingTop: 24,\n paddingBottom: 8\n },\n newButton: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n deleteConfirmationModal: {\n height: \"auto !important\"\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n deleteModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n textAlign: \"center\"\n },\n deleteModalContentBoldText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n sectionEditNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\" ,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5 + \" !important\"\n },\n \n}));\n\nexport default useStyles;","import { SectionFieldType } from \"./enums/section-field-type\";\n\nexport class SectionFieldCreateRequest {\n establishmentAccountId?: string|null;\n sectionId: string | null;\n name: string;\n type: SectionFieldType;\n isRequired: boolean;\n isAdditionalTextareaEnabled: boolean;\n itemsNames: string[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.sectionId = x.sectionId;\n this.name = x.name;\n this.type = x.type;\n this.isRequired = x.isRequired;\n this.isAdditionalTextareaEnabled = x.isAdditionalTextareaEnabled;\n this.itemsNames = x.itemsNames;\n } else {\n this.establishmentAccountId = null;\n this.sectionId = null;\n this.name = \"\";\n this.type = 11;\n this.isRequired = false;\n this.isAdditionalTextareaEnabled = false;\n this.itemsNames = [];\n }\n }\n}","import { SectionFieldType } from \"./enums/section-field-type\";\nimport { SectionFieldItemModel } from \"./section-field-item-model\";\n\nexport class SectionFieldUpdateRequest {\n establishmentAccountId?: string|null;\n id: string;\n sectionId: string;\n name: string;\n type: SectionFieldType;\n isRequired: boolean;\n isAdditionalTextareaEnabled: boolean;\n items: SectionFieldItemModel[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.id = x.id;\n this.sectionId = x.sectionId;\n this.name = x.name;\n this.type = x.type;\n this.isRequired = x.isRequired;\n this.isAdditionalTextareaEnabled = x.isAdditionalTextareaEnabled;\n this.items = x.items;\n } else {\n this.establishmentAccountId = null;\n this.id = \"\";\n this.sectionId = \"\";\n this.name = \"\";\n this.type = 11;\n this.isRequired = false;\n this.isAdditionalTextareaEnabled = false;\n this.items = [];\n }\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n sectionContainer: {\n boxSizing: \"border-box\",\n borderRadius: \"12px\",\n overflow: \"hidden\",\n backgroundColor: Color.gray1,\n },\n sectionLayout: {\n display: \"flex\",\n flexDirection: \"column\",\n padding: \"8px 12px\"\n },\n draggableClassName: {\n padding: \"4px 0px\"\n },\n innerFieldContentContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"baseline\",\n gap: 10,\n flexWrap: \"wrap\"\n },\n fieldItemsContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n flexDirection: \"column\",\n gap: 13,\n flex: \"1 1 100%\"\n },\n fieldTypeContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"baseline\",\n gap: 5,\n marginRight: 9\n },\n fieldItemBox: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 7\n },\n fieldNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n maxWidth: \"300px\",\n overflow: \"hidden\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\"\n },\n fieldInnerComponentDivider: {\n fontSize: \"21px\",\n lineHeight: \"23px\",\n color: Color.gray4,\n padding: \"0 7px\"\n },\n fieldTypeNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n color: Color.gray4\n },\n fieldItemNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n overflow: 'hidden',\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis',\n maxWidth: 980\n },\n isRequiredAsterisk: {\n \"&::after\": {\n content: '\"*\"',\n marginLeft: \"2px\",\n color: Color.clear1\n },\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((height: number) => ({\n mainBox: {\n border: \"1px solid\",\n borderColor: Color.gray2,\n boxSizing: \"border-box\",\n borderRadius: \"5px\",\n width: \"100%\",\n overflow: \"hidden\",\n },\n innerContainer: {\n display: \"flex\",\n alignItems: \"center\",\n gap: 10,\n backgroundColor: Color.white,\n padding: 12,\n width: \"100%\",\n },\n justifyEnd: {\n marginLeft: \"auto\",\n minWidth: \"fit-content\",\n alignSelf: \"baseline\",\n marginTop: -6\n },\n actionButton: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n },\n}));\n\nexport default useStyles;","import React, { useState } from 'react';\n\nimport { DraggableBaseProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button } from \"@material-ui/core\";\nimport { Draggable, DraggableProvided } from \"react-beautiful-dnd\";\nimport { DraggableIcon, SectionEditIcon, SectionDeleteIcon } from \"../../../assets/icons\";\n\ntype DraggableFunction = (provided: DraggableProvided) => JSX.Element;\n\n\nexport default function DraggableBase(props: DraggableBaseProps) {\n const {\n className,\n height,\n draggableId,\n index,\n innerContainerStyle,\n mainBoxClass,\n isEditable,\n isEditableByButton,\n isRemovable,\n children,\n onEditClick,\n onDeleteClick,\n isShowActionOnMouseHover,\n innerContainerClass,\n closeIcon,\n ...otherProps\n } = props;\n\n const classes = useStyles();\n const [isHovered, setIsHovered] = useState<boolean>(false);\n\n const tryGetEditButton = () => {\n if (isEditable && isEditableByButton)\n return (<Button\n onClick={() => { onEditClick && onEditClick() }}\n className={classes.actionButton}\n >\n <SectionEditIcon />\n </Button>);\n return <></>;\n };\n\n const tryGetDeleteButton = () => {\n if (isRemovable)\n return (<Button\n onClick={() => { onDeleteClick && onDeleteClick() }}\n className={classes.actionButton}\n >\n {closeIcon ? closeIcon : <SectionDeleteIcon />}\n </Button>);\n return <></>;\n };\n\n const getActions = () => {\n return <>\n {tryGetEditButton()}\n {tryGetDeleteButton()}\n </>\n };\n\n const getBaseNode = (innerContent: JSX.Element | DraggableFunction): JSX.Element => {\n if (isEditable)\n return <Draggable\n key={draggableId}\n draggableId={draggableId}\n index={index}\n isDragDisabled={!isEditable}\n {...otherProps}\n >\n {(provided) => (innerContent as DraggableFunction)(provided)}\n </ Draggable>\n else\n return <>\n {innerContent}\n </>\n }\n\n const innerContentDraggable = (): DraggableFunction =>\n (provided) => (\n <div className={className}\n ref={provided.innerRef}\n onMouseEnter={() => setIsHovered(true)}\n onMouseLeave={() => setIsHovered(false)}\n {...provided.draggableProps}\n {...provided.dragHandleProps}\n >\n {innerContentCommon()}\n </div>\n );\n\n const innerContentStatic = (): JSX.Element => {\n return <div className={className}>\n {innerContentCommon()}\n </div>\n }\n\n const innerContentCommon = (): JSX.Element => {\n return <div className={mainBoxClass ?? classes.mainBox}>\n <div className={innerContainerClass ?? classes.innerContainer} style={innerContainerStyle ?? { height: 48 }}>\n <div>\n {isEditable ? <DraggableIcon style={{ cursor: \"grab\" }} /> : <DraggableIcon style={{ display: \"none\" }} />}\n </div>\n <div>\n {children}\n </div>\n <div className={classes.justifyEnd}>\n {isShowActionOnMouseHover ? isHovered && getActions() : getActions()}\n </div>\n </div>\n </div>\n }\n\n\n return getBaseNode(isEditable ? innerContentDraggable() : innerContentStatic());\n};","export class SectionFieldUpdateOrderRequest {\n establishmentAccountId?: string|null;\n id: string;\n sectionId: string;\n newOrder: number;\n previousOrder: number;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.id = x.id;\n this.sectionId = x.sectionId;\n this.newOrder = x.newOrder;\n this.previousOrder = x.previousOrder;\n } else {\n this.establishmentAccountId = null;\n this.id = \"\";\n this.sectionId = \"\";\n this.newOrder = 0;\n this.previousOrder = 0;\n }\n }\n}","import React, { CSSProperties } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { FieldListProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Box, Grid, Typography } from \"@material-ui/core\";\nimport { DragDropContext, Droppable, DropResult } from \"react-beautiful-dnd\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport DraggableBase from \"../../../../common/DraggableBase\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport {\n SectionFieldCheckboxIcon,\n SectionFieldCheckboxItemIcon,\n SectionFieldDateIcon,\n SectionFieldDropdownIcon,\n SectionFieldDropdownItemIcon,\n SectionFieldEmailIcon,\n SectionFieldNumericIcon,\n SectionFieldOptionalTextFieldIcon,\n SectionFieldPhoneIcon,\n SectionFieldRadioIcon,\n SectionFieldRadioItemIcon,\n SectionFieldTextIcon\n} from \"../../../../../assets/icons\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionFieldUpdateOrderRequest } from \"../../../../../models/section-field-update-order-request\";\n\nexport default function FieldList(props: FieldListProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { section, onEditClick, onDeleteClick } = props;\n const classes = useStyles();\n\n const getReorderedFields = (fields: SectionFieldModel[], prevOrder: number, newOrder: number, movedFieldId: string) => {\n const result = Array.from(fields);\n\n const positionsMoved = newOrder - prevOrder;\n const isMovedDown = positionsMoved > 0;\n const affectedFieldIds = isMovedDown\n ? fields.filter(f => f.id === movedFieldId ||\n f.order! <= newOrder &&\n f.order! >= prevOrder)\n .map(f => f.id)\n : fields.filter(f => f.id === movedFieldId ||\n f.order! >= newOrder &&\n f.order! <= prevOrder)\n .map(f => f.id);\n\n result.forEach(f => {\n if (!affectedFieldIds.includes(f.id!))\n return;\n if (f.id === movedFieldId) {\n f.order = newOrder;\n return;\n }\n f.order = isMovedDown ? f.order! - 1 : f.order! + 1;\n });\n\n return result;\n };\n\n const dragUpdateHandler = async (update: DropResult) => {\n if (update.destination && update.destination.index < 0) {\n return;\n }\n }\n\n const dragEndHandler = async (result: DropResult) => {\n const { destination, source, draggableId } = result;\n\n //dropped not at droppable\n if (!destination)\n return;\n\n //dropped at other field list\n if (destination.droppableId !== source.droppableId)\n return;\n\n //dropped at the same spot\n if (destination.droppableId === source.droppableId && destination.index === source.index)\n return;\n\n if (destination.index < 0)\n return;\n\n const prevOrder = source.index + 1;\n const newOrder = destination.index + 1;\n\n section.fields = getReorderedFields(section.fields, prevOrder, newOrder, draggableId);\n\n await SettingsPatientFormsService.reorderSectionFields(new SectionFieldUpdateOrderRequest(\n {\n id: draggableId,\n sectionId: section.id,\n newOrder: newOrder,\n previousOrder: prevOrder\n }));\n };\n\n const fieldContentDividerComponent =\n <Typography className={classes.fieldInnerComponentDivider}>\n |\n </Typography>;\n\n const getFieldTypeNameComponent = (typeName: string) => {\n return <Typography className={classes.fieldTypeNameLabel}>\n {t(typeName)}\n </Typography>\n };\n\n const getFieldTypeComponent = (type: SectionFieldType) => {\n switch (type) {\n case SectionFieldType.PhoneNumber:\n return <>\n <SectionFieldPhoneIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"PhoneNumberPatientFormsSections\")}\n </>\n case SectionFieldType.Email:\n return <>\n <SectionFieldEmailIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"Email\")}\n </>\n case SectionFieldType.Radio:\n return <>\n <SectionFieldRadioIcon style={{ position: \"relative\", top: 4 }} />\n {getFieldTypeNameComponent(\"Multiple choice\")}\n </>\n case SectionFieldType.Checkbox:\n return <>\n <SectionFieldCheckboxIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"Checkboxes\")}\n </>\n case SectionFieldType.Dropdown:\n return <>\n <SectionFieldDropdownIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"Dropdown list\")}\n </>\n case SectionFieldType.Text:\n return <>\n <SectionFieldTextIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"Free text\")}\n </>\n case SectionFieldType.Numeric:\n return <>\n <SectionFieldNumericIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"Numeric field\")}\n </>\n case SectionFieldType.Date:\n return <>\n <SectionFieldDateIcon style={{ position: \"relative\", top: 6 }} />\n {getFieldTypeNameComponent(\"Date\")}\n </>\n };\n };\n\n const tryGetFieldItemComponents = (field: SectionFieldModel) => {\n let iconComponent: JSX.Element;\n\n switch (field.type) {\n case SectionFieldType.Checkbox:\n iconComponent = <SectionFieldCheckboxItemIcon />;\n break;\n case SectionFieldType.Radio:\n iconComponent = <SectionFieldRadioItemIcon />;\n break;\n case SectionFieldType.Dropdown:\n iconComponent = <SectionFieldDropdownItemIcon />;\n break;\n default:\n return <>\n\n </>\n }\n\n return <>\n {field.items.sort((i1, i2) => i1.order! - i2.order!).map(i =>\n <div className={classes.fieldItemBox}>\n {iconComponent}\n <Typography className={classes.fieldItemNameLabel}>\n {t(i.name!, { ns: sectionTNamespace })}\n </Typography>\n </div>)\n }\n </>\n\n };\n\n const getOptionalFreeTextComponent = (field: SectionFieldModel) => {\n let optionalFreeTextComponent: JSX.Element;\n\n if (field.isAdditionalTextareaEnabled) {\n optionalFreeTextComponent = <>\n <div>\n {fieldContentDividerComponent}\n </div>\n <div className={classes.fieldItemBox} style={{ marginLeft: \"14px\", paddingTop: 6 }}>\n <SectionFieldOptionalTextFieldIcon />\n <Typography className={classes.fieldItemNameLabel}>\n {t(\"Free text\")}\n </Typography>\n </div>\n </>\n }\n else {\n optionalFreeTextComponent = <></>\n }\n\n return <>\n {optionalFreeTextComponent}\n </>\n\n };\n\n const getInnerFieldContent = (field: SectionFieldModel) => {\n return <div className={classes.innerFieldContentContainer}>\n <Typography className={`${classes.fieldNameLabel} ${field.isRequired ? classes.isRequiredAsterisk : \"\"}`}>\n {t(field.name!, { ns: sectionTNamespace })}\n </Typography>\n <div style={{ padding: \"0px 7px\" }}>\n {fieldContentDividerComponent}\n </div>\n <div className={classes.fieldTypeContainer}>\n {getFieldTypeComponent(field.type!)}\n </div>\n <div style={{ display: \"flex\" }}>\n {getOptionalFreeTextComponent(field)}\n </div>\n\n <div className={classes.fieldItemsContainer}>\n {tryGetFieldItemComponents(field)}\n </div>\n </div>\n };\n\n const getInnerContainerStyle = (type: SectionFieldType): CSSProperties => {\n if (type === SectionFieldType.Radio) {\n return {\n minHeight: 48\n };\n }\n return {\n height: 48\n }\n };\n\n\n const mapFieldsToComponents = (fields: SectionFieldModel[]) => {\n return fields.sort((f1, f2) => f1.order! - f2.order!).map(f =>\n <DraggableBase\n key={f.id!}\n className={classes.draggableClassName}\n height={48}\n innerContainerStyle={getInnerContainerStyle(f.type)}\n draggableId={f.id!}\n index={f.order! - 1}\n isEditable={f.isEditable!}\n isEditableByButton={f.isEditable!}\n isRemovable={f.isRemovable!}\n onEditClick={() => onEditClick(f.id!)}\n onDeleteClick={() => onDeleteClick(f.id!)}\n >\n {getInnerFieldContent(f)}\n </DraggableBase>)\n };\n\n return <>\n <DragDropContext onDragUpdate={dragUpdateHandler} onDragEnd={dragEndHandler}>\n <Droppable key={section.id!} droppableId={section.id!}>\n {(provided) => (\n <Box>\n <div className={classes.sectionContainer} >\n <Grid\n container\n justifyContent=\"center\"\n className={classes.sectionLayout}\n ref={provided.innerRef}\n {...provided.droppableProps}\n >\n {mapFieldsToComponents(section.fields)}\n {provided.placeholder}\n </Grid>\n </div>\n </Box>\n )}\n </Droppable>\n </DragDropContext>\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n overflowY: \"auto\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"33px\",\n marginBottom: \"33px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: Color.gray4\n },\n },\n paper: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 720,\n maxHeight: 500,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n padding: \"24px 40px\",\n },\n modalTitle: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 5,\n width: \"100%\",\n \"& svg path\": {\n fill: theme.colors.grey5\n }\n },\n modalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n gap: 16\n },\n goBack: {\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n scrollbarWrapper: {\n width: \"100%\",\n borderRadius: \"0 0 10px 10px\",\n backgroundColor: \"#FAFAFA\",\n },\n content: {\n backgroundColor: \"#FAFAFA\",\n maxHeight: 420,\n padding: \"24px 25px 16px 40px\",\n borderRadius: \"0 0 10px 10px\",\n display: \"flex\",\n flexDirection: \"column\",\n gap: 25,\n overflowY: \"auto\",\n width: \"calc(100% - 15px)\",\n },\n requiredAsterisk: {\n color: Color.clear1,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n contentRowContainer: {\n display: \"flex\",\n alignItems: \"flex-end\",\n gap: 30\n },\n fieldTypeSelectItemContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 10\n },\n fieldItemsContainer: {\n boxSizing: \"border-box\",\n overflow: \"hidden\",\n },\n fieldItemsLayout: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n draggableClassName: {\n padding: \"4px 0px\",\n cursor: \"text !important\",\n },\n innerItemContentContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 3,\n },\n itemNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: theme.colors.grey5\n },\n addItemButton: {\n justifyContent: \"space-around\",\n \n marginTop: -17,\n height: 32,\n \n ...theme.typography.buttons,\n fontWeight: 700,\n color: theme.colors.clearMain,\n \n borderRadius: 51,\n border: `1px solid ${theme.colors.clearMain}`,\n \n \"&.Mui-disabled\": {\n color: theme.colors.clearMain,\n }\n },\n itemEditNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5 + \" !important\"\n },\n closeConfirmationModal: {\n height: \"234px + !important\"\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n deleteConfirmationModal: {\n height: 194\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\"\n },\n}));\n\nexport default useStyles;","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { DragDropContext, Droppable, DropResult } from \"react-beautiful-dnd\";\n\nimport { Backdrop, Box, Button, ClickAwayListener, Fade, Grid, Modal, Typography } from \"@material-ui/core\";\nimport { SectionFieldModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport { PlusIcon, SectionEditIcon, SectionFieldEmailIcon, SectionFieldNewIcon, SectionFieldPhoneIcon, SectionFieldRadioIcon, SectionFieldRadioItemIcon, SectionFieldTextIcon } from \"../../../../../assets/icons\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport SelectWithLabel from \"../../../../common/SelectWithLabel\";\nimport { SelectItem } from \"../../../../common/Select\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport { Color } from \"../../../../../constants/colors\";\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport { SectionFieldItemModel } from \"../../../../../models/section-field-item-model\";\nimport DraggableBase from \"../../../../common/DraggableBase/draggable-base\";\nimport Input from \"../../../../common/Input\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport ConfirmActionModal from \"../../../../common/ConfirmActionModal\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\nexport default function SectionFieldModal(props: SectionFieldModalProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { isOpen, section, sections, mode, field, setOpen, onSave } = props;\n const classes = useStyles();\n const isNew = mode === \"new\";\n const maxNameLength = 200;\n\n const getFieldTypeSelectItemsForSectionType = (): SelectItem[] => {\n if (section.type === SectionType.ClinicHistory)\n return [\n {\n key: SectionFieldType.Radio, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldRadioIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Multiple choice\")}\n </Typography>\n </div>\n },\n {\n key: SectionFieldType.Text, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldTextIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Free text\")}\n </Typography>\n </div>\n }\n ]\n else if (section.type === SectionType.UserTreatment)\n return [\n {\n key: SectionFieldType.Text, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldTextIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Free text\")}\n </Typography>\n </div>\n }\n ]\n else \n return [\n {\n key: SectionFieldType.Email, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldEmailIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Email\")}\n </Typography>\n </div>\n },\n {\n key: SectionFieldType.PhoneNumber, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldPhoneIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"PhoneNumberPatientFormsSections\")}\n </Typography>\n </div >\n },\n {\n key: SectionFieldType.Radio, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldRadioIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Multiple choice\")}\n </Typography>\n </div>\n },\n {\n key: SectionFieldType.Text, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldTextIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Free text\")}\n </Typography>\n </div>\n }\n ];\n }\n\n const defaultSectionField = new SectionFieldModel();\n const defaultControlTypeFieldItems: SectionFieldItemModel[] = [\n new SectionFieldItemModel({ id: 1, name: t(\"Option\") + \" \" + 1, order: 1 }),\n new SectionFieldItemModel({ id: 2, name: t(\"Option\") + \" \" + 2, order: 2 }),\n ];\n defaultSectionField.items = defaultControlTypeFieldItems;\n\n const [nameIsValid, setNameIsValid] = useState<boolean>(isNew ? false : true);\n const [formIsValid, setFormIsValid] = useState<boolean>(false);\n\n const [sectionSelectItems, setSectionSelectItems] = useState<SelectItem[]>([]);\n const [selectedSectionId, setSelectedSectionId] = useState<string>(section.id!);\n\n const [localField, setLocalField] = useState<SectionFieldModel>(isNew ? new SectionFieldModel() : new SectionFieldModel({ ...field, items: field!.items.map(i => ({ ...i })) }));\n const [editingItem, setEditingItem] = useState<SectionFieldItemModel | null>(null);\n const [deletingItem, setDeletingItem] = useState<SectionFieldItemModel | null>(null);\n\n const [deleteConfirmationModalIsOpen, setDeleteConfirmationModalIsOpen] = useState<boolean>(false);\n const [closeConfirmationModalIsOpen, setCloseConfirmationModalIsOpen] = useState<boolean>(false);\n\n const [validationCaller, forceValidation] = useState<number>(-1);\n\n const itemInputRef = useRef<HTMLInputElement>();\n\n const fieldIdStub = localField.id ?? \"fieldId\";\n\n useEffect(() => {\n //when edit and nothing changed\n if (!isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(field, Object.keys(field!).sort())) {\n setFormIsValid(false);\n return;\n }\n //when new and default state and options are default\n if (isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(defaultSectionField, Object.keys(defaultSectionField).sort())\n && localField.type === SectionFieldType.Radio && JSON.stringify(localField.items) === JSON.stringify(defaultControlTypeFieldItems)) {\n setFormIsValid(false);\n return;\n }\n //when <2 items when control component\n if (localField.type === SectionFieldType.Radio && localField.items.length < 2) {\n setFormIsValid(false);\n return;\n }\n //when name isn't valid\n if (!nameIsValid) {\n setFormIsValid(false);\n return;\n }\n\n setFormIsValid(true);\n }, [localField, ...localField.items, validationCaller]);\n\n useEffect(() => {\n if (!isOpen)\n return;\n if (field) {\n const existingFieldCopy = new SectionFieldModel({ ...field, items: field!.items.map(i => ({ ...i })) })\n setLocalField(existingFieldCopy);\n setNameIsValid(true);\n }\n else {\n const newSectionField = new SectionFieldModel();\n newSectionField.items = defaultControlTypeFieldItems.map(i => ({ ...i }));\n setLocalField(newSectionField);\n setNameIsValid(false);\n }\n }, [field, mode, isOpen]);\n\n useEffect(() => {\n if (isNew && localField.type === SectionFieldType.Radio)\n setLocalField({ ...localField, items: defaultControlTypeFieldItems.map(i => ({ ...i })) });\n else if (isNew && localField.type !== SectionFieldType.Radio)\n setLocalField({ ...localField, items: [] })\n else if (!isNew && localField.type === SectionFieldType.Radio && field?.type !== SectionFieldType.Radio)\n setLocalField({ ...localField, items: defaultControlTypeFieldItems.map(i => ({ ...i })), isAdditionalTextareaEnabled: true })\n else if (!isNew && localField.type !== SectionFieldType.Radio && field?.type === SectionFieldType.Radio)\n setLocalField({ ...localField, items: field!.items.map(i => ({ ...i })) })\n }, [localField.type]);\n\n useEffect(() => {\n const selectItems: SelectItem[] = sections.sort((s1, s2) => s1.order! - s2.order!).map((s) => ({\n key: s.id,\n value: t(s.name!, { ns: sectionTNamespace })\n }));\n setSectionSelectItems(selectItems);\n }, [sections]);\n\n useEffect(() => {\n if (editingItem)\n itemInputRef?.current?.focus();\n }, [editingItem]);\n\n const getReorderedFieldItems = (items: SectionFieldItemModel[], prevOrder: number, newOrder: number, movedItemId: string) => {\n const result = Array.from(items);\n\n const positionsMoved = newOrder - prevOrder;\n const isMovedDown = positionsMoved > 0;\n const affectedItemsIds = isMovedDown\n ? items.filter(i => i.id === movedItemId ||\n i.order! <= newOrder &&\n i.order! >= prevOrder)\n .map(i => i.id)\n : items.filter(i => i.id === movedItemId ||\n i.order! >= newOrder &&\n i.order! <= prevOrder)\n .map(i => i.id);\n\n result.forEach(i => {\n if (!affectedItemsIds.includes(i.id!))\n return;\n if (i.order.toString() === movedItemId) {\n i.order = newOrder;\n return;\n }\n i.order = isMovedDown ? i.order! - 1 : i.order! + 1;\n });\n\n return result;\n };\n\n const handleOnClose = () => {\n setOpen(false);\n setNameIsValid(false);\n setFormIsValid(false);\n setCloseConfirmationModalIsOpen(false);\n };\n\n const handleAddButtonClick = async () => {\n if (!nameIsValid)\n return;\n\n await onSave(localField, selectedSectionId);\n handleOnClose();\n };\n\n const tryClose = () => {\n if (!isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(field, Object.keys(field!).sort())) {\n handleOnClose();\n return;\n }\n if (isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(defaultSectionField, Object.keys(defaultSectionField).sort())) {\n handleOnClose();\n return;\n }\n setCloseConfirmationModalIsOpen(true);\n };\n\n const handleNewItemButtonClick = () => {\n const newItems = Array.from(localField.items);\n const lastItemOrder = newItems.length;\n newItems.push(new SectionFieldItemModel({\n id: lastItemOrder + 1,\n name: t(\"Option\") + \" \" + (lastItemOrder + 1).toString(),\n order: lastItemOrder + 1\n }));\n\n setLocalField({ ...localField, items: newItems });\n };\n\n const handleItemEditClicked = (item: SectionFieldItemModel) => {\n if (editingItem) {\n return;\n }\n const itemCopy = new SectionFieldItemModel({ id: item.id, name: item.name, order: item.order });\n setEditingItem(itemCopy);\n };\n\n function handleItemFocus(event: any) {\n event.target.select();\n }\n\n function handleItemKeyDown(event: any) {\n if (event.keyCode === 13)\n event.target.blur();\n }\n\n function handleItemInputClickAway() {\n handleItemEditBlur()\n }\n\n const handleItemEditBlur = () => {\n if (editingItem!.name.length === 0 || editingItem!.name.length > maxNameLength) {\n setEditingItem(null);\n return;\n }\n\n const updatedItems = Array.from(localField.items);\n const itemToUpdate = updatedItems.find(i => i.id === editingItem?.id)\n if (itemToUpdate && editingItem) {\n itemToUpdate.name = editingItem.name;\n setLocalField({ ...localField, items: updatedItems });\n setEditingItem(null);\n }\n };\n\n const handleItemNameChange = (event: React.ChangeEvent<{ value: string }>) => {\n const name = event.target.value;\n if (name.length > maxNameLength) {\n return;\n }\n\n if (editingItem)\n setEditingItem((prev) => (prev ? {\n ...prev,\n name: name\n } : null));\n };\n\n const handleDeleteItemButtonClicked = (item: SectionFieldItemModel) => {\n const itemToDelete = localField.items.find(i => i.id === item.id)\n if (itemToDelete) {\n setDeletingItem(itemToDelete);\n setDeleteConfirmationModalIsOpen(true);\n }\n };\n\n const handleDeleteItem = (item: SectionFieldItemModel) => {\n const itemOrder = item.order;\n const updatedItems = localField.items.filter(i => i.id !== item.id);\n updatedItems.forEach(i => {\n if (i.order! < itemOrder!)\n return;\n i.order = i.order! - 1;\n });\n\n setLocalField({ ...localField, items: updatedItems });\n setDeletingItem(null);\n setDeleteConfirmationModalIsOpen(false);\n };\n\n const handleNameChange = (event: React.ChangeEvent<{ value: string }>) => {\n const newName = event.target.value;\n if (newName.length > maxNameLength || newName.trim().length == 0) {\n setNameIsValid(false);\n setLocalField((prev) => ({\n ...prev,\n name: newName\n }));\n return;\n }\n\n setLocalField((prev) => ({\n ...prev,\n name: newName\n }));\n setNameIsValid(true);\n };\n\n const dragEndHandler = async (result: DropResult) => {\n const { destination, source, draggableId } = result;\n\n //dropped not at droppable\n if (!destination)\n return;\n\n //dropped at other item list\n if (destination.droppableId !== source.droppableId)\n return;\n\n //dropped at the same spot\n if (destination.droppableId === source.droppableId && destination.index === source.index)\n return;\n\n const prevOrder = source.index + 1;\n const newOrder = destination.index + 1;\n\n localField.items = getReorderedFieldItems(localField.items, prevOrder, newOrder, draggableId);\n forceValidation(Math.random());\n };\n\n const getItemIcon = (fieldType: SectionFieldType) => {\n switch (fieldType) {\n case SectionFieldType.Radio:\n return <SectionFieldRadioItemIcon />;\n default:\n return <></>;\n }\n };\n\n const getInnerItemContent = (item: SectionFieldItemModel) => {\n return <>\n {editingItem && editingItem.id === item.id\n ?\n <ClickAwayListener onClickAway={handleItemInputClickAway}>\n <div className={classes.innerItemContentContainer}>\n <Input\n inputClass={classes.itemEditNameInput}\n value={t(editingItem.name, { ns: sectionTNamespace })}\n isValid={() => { return editingItem.name.length > 0 && editingItem.name.length <= maxNameLength }}\n onChange={(event) => handleItemNameChange(event)}\n onFocus={(event: any) => handleItemFocus(event)}\n onKeyDown={(event: any) => handleItemKeyDown(event)}\n onBlur={() => handleItemEditBlur()}\n disabled={!editingItem || !localField.isEditable}\n maxLength={maxNameLength}\n width={500}\n ref={itemInputRef}\n autoFocus\n />\n </div>\n </ClickAwayListener>\n :\n <div\n className={classes.innerItemContentContainer}\n onClick={() => handleItemEditClicked(item)}\n >\n {getItemIcon(localField.type)}\n <Typography className={classes.itemNameLabel}>\n {t(item.name!, { ns: sectionTNamespace })}\n </Typography>\n </div>}\n </>\n };\n\n const mapItemsToComponents = (items: SectionFieldItemModel[]) => {\n return items.sort((i1, i2) => i1.order! - i2.order!).map(i =>\n <div onClick={() => handleItemEditClicked(i)}>\n <DraggableBase\n key={i.order!.toString()}\n className={classes.draggableClassName}\n height={48}\n draggableId={i.order!.toString()}\n index={i.order! - 1}\n isEditable={true}\n isEditableByButton={false}\n isRemovable={true}\n onEditClick={() => { }}\n onDeleteClick={() => { handleDeleteItemButtonClicked(i) }}\n >\n {getInnerItemContent(i)}\n </DraggableBase>\n </div>\n )\n };\n\n const DeleteModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete item response?\")}\n </Typography>\n </div>);\n };\n\n const CloseModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {isNew\n ? t(\"Are you sure you want to cancel the creation of the new item?\")\n : t(\"Are you sure you want to cancel the edition of the item?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {t(\"The changes made will not be saved\")}\n </Typography>\n </div>);\n };\n\n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={tryClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n <Fade in={isOpen}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n {isNew\n ? <>\n <SectionFieldNewIcon />\n <Typography className={classes.modalTitleText}>\n {t(\"New item\")}\n </Typography>\n </>\n : <>\n <SectionEditIcon fill={Color.gray5} />\n <Typography className={classes.modalTitleText}>\n {t(\"Edit item\")}\n </Typography>\n </>}\n\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t\t backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={tryClose}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t \t backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={isNew ? t(\"Add\") : t(\"Save changes\")}\n onClick={handleAddButtonClick}\n\t\t \t disabled={!formIsValid}\n />\n </div>\n </div>\n <div className={classes.scrollbarWrapper}>\n <div className={classes.content}>\n <div className={classes.contentRowContainer}>\n <InputWithLabel\n label={() => (<>{t(\"Name\")} <span className={classes.requiredAsterisk}>*</span></>)}\n placeholder={t(\"Enter the name of the item\")}\n value={t(localField.name, { ns: sectionTNamespace })}\n width={isNew ? 305 : 637}\n name=\"name\"\n onChange={(e) => handleNameChange(e)}\n isValid={() => true}\n />\n {isNew\n ? <SelectWithLabel\n label={() => (<>{t(\"Add to\")} <span className={classes.requiredAsterisk}>*</span></>)}\n items={sectionSelectItems}\n value={selectedSectionId}\n name={\"sections\"}\n width={305}\n isValid={() => true}\n onChange={(event) => setSelectedSectionId(event.target.value)} />\n : <></>}\n\n </div>\n <div className={classes.contentRowContainer}>\n <SelectWithLabel\n label={() => (<>{t(\"Type\")} <span className={classes.requiredAsterisk}>*</span></>)}\n items={getFieldTypeSelectItemsForSectionType()}\n value={localField.type}\n name={\"fieldTypes\"}\n width={305}\n isValid={() => true}\n onChange={(event) => setLocalField((prev) => ({\n ...prev,\n type: event.target.value\n }))} />\n {localField.type === SectionFieldType.Radio\n ? <SwitchWithLabel\n value={localField.isAdditionalTextareaEnabled}\n setValue={(value) => setLocalField((prev) => ({\n ...prev,\n isAdditionalTextareaEnabled: value\n }))}\n label={t(\"Add free text area at the end\")}\n />\n : <></>}\n </div>\n {localField.type === SectionFieldType.Radio\n ? <>\n <div className={classes.contentRowContainer}>\n <DragDropContext onDragEnd={dragEndHandler}>\n <Droppable key={fieldIdStub} droppableId={fieldIdStub}>\n {(provided) => (\n <Box style={{ width: \"100%\" }}>\n <div className={classes.fieldItemsContainer} >\n <Grid\n container\n justifyContent=\"center\"\n className={classes.fieldItemsLayout}\n ref={provided.innerRef}\n {...provided.droppableProps}\n >\n {mapItemsToComponents(localField.items)}\n {provided.placeholder}\n </Grid>\n </div>\n </Box>\n )}\n </Droppable>\n </DragDropContext>\n </div>\n <div className={classes.contentRowContainer}>\n <Button\n className={classes.addItemButton}\n onClick={handleNewItemButtonClick}\n >\n <PlusIcon style={{ paddingRight: 10 }} />\n {t(\"Add another option\")}\n </Button>\n </div>\n </>\n : <></>}\n <div className={classes.contentRowContainer}>\n <SwitchWithLabel\n value={localField.isRequired}\n setValue={(value) => setLocalField((prev) => ({\n ...prev,\n isRequired: value\n }))}\n label={t(\"Required\")} />\n </div>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<CloseModalContent />}\n open={closeConfirmationModalIsOpen}\n onClose={() => setCloseConfirmationModalIsOpen(false)}\n onConfirm={handleOnClose}\n />\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteConfirmationModalIsOpen}\n item={deletingItem}\n componentInfo={<DeleteModalContent />}\n onClose={() => { setDeleteConfirmationModalIsOpen(false); setDeletingItem(null); }}\n onDelete={() => deletingItem && handleDeleteItem(deletingItem)}\n />\n </>\n};","export class SectionFieldDeleteRequest {\n establishmentAccountId?: string|null;\n id: string;\n sectionId: string;\n order: number;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.id = x.id;\n this.sectionId = x.sectionId;\n this.order = x.order;\n } else {\n this.establishmentAccountId = null;\n this.id = \"\";\n this.sectionId = \"\";\n this.order = 0;\n }\n }\n}","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport { SectionProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionFieldCreateRequest } from \"../../../../../models/section-field-create-request\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport { SectionFieldItemModel } from \"../../../../../models/section-field-item-model\";\nimport { SectionFieldUpdateRequest } from \"../../../../../models/section-field-update-request\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\n\nimport { Box, Button, Grid, Typography } from \"@material-ui/core\";\nimport { SectionArrowIcon, SectionDeleteIcon, SectionEditIcon, SectionExitEditIcon, SectionFieldNewIcon, SectionSaveIcon } from \"../../../../../assets/icons\";\nimport FieldList from \"../FieldList\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport SectionFieldModal from \"../SectionFieldModal\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport Input from \"../../../../common/Input\";\nimport { SectionFieldDeleteRequest } from \"../../../../../models/section-field-delete-request\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default function Section(props: SectionProps) {\n const sectionTNamespace = \"sections\";\n const maxTextFieldLength = 200;\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { section, sections, customNote, customHeaderButton, setSection, onEdit, onDelete, onMoveDown, onMoveUp } = props;\n const classes = useStyles();\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const sectionInputRef = useRef<HTMLInputElement>();\n\n const [deleteSectionConfirmationModalIsOpen, setDeleteSectionConfirmationModalIsOpen] = useState<boolean>(false);\n const [sectionFieldModalIsOpen, setSectionFieldModalIsOpen] = useState<boolean>(false);\n const [headerHover, setHeaderHover] = useState<boolean>(false);\n const [deleteFieldConfirmationModalIsOpen, setDeleteFieldConfirmationModalIsOpen] = useState<boolean>(false);\n\n const [fieldMode, setFieldMode] = useState<\"new\" | \"edit\">(\"new\");\n const [isSectionEditMode, setSectionEditMode] = useState<boolean>(false);\n\n const [modalField, setModalField] = useState<SectionFieldModel | undefined>(undefined);\n const [deleteModalField, setDeleteModalField] = useState<SectionFieldModel | undefined>(undefined);\n\n const [name, setName] = useState<string>(section.name!);\n\n useEffect(() => {\n if (section.name)\n setName(section.name);\n }, [section]);\n\n useEffect(() => {\n if (isSectionEditMode)\n sectionInputRef?.current?.focus();\n }, [isSectionEditMode]);\n\n const handleEditButtonClick = () => {\n setSectionEditMode(true);\n }\n\n const handleDeleteSection = (section: SectionModel) => {\n setDeleteSectionConfirmationModalIsOpen(false);\n if (onDelete)\n onDelete(section);\n }\n\n const handleNewFieldButtonClick = () => {\n setFieldMode(\"new\");\n setModalField(undefined);\n setSectionFieldModalIsOpen(true);\n };\n\n const handleEditFieldClick = (fieldId: string) => {\n const selectedField = section.fields.filter(f => f.id === fieldId)[0];\n setFieldMode(\"edit\");\n setModalField(selectedField);\n setSectionFieldModalIsOpen(true);\n };\n\n const handleDeleteFieldClick = (fieldId: string) => {\n const fieldToDelete = section.fields.filter(f => f.id === fieldId)[0];\n setDeleteModalField(fieldToDelete);\n setDeleteFieldConfirmationModalIsOpen(true);\n }\n\n const handleOnChange = (event: React.ChangeEvent<{ value: string }>) => {\n const name = event.target.value;\n if (name.length > maxTextFieldLength) {\n return;\n }\n setName(name);\n };\n\n const handleEditSection = async () => {\n if (!onEdit)\n return;\n setSectionEditMode(false);\n if (section.name === name.trim() || name.trim().length === 0) {\n setName(section.name!);\n return;\n }\n section.name = name;\n await onEdit(section);\n };\n\n const handleSectionFieldSave = async (newField: SectionFieldModel, sectionIdToSave: string) => {\n if (!sections || !setSection)\n return;\n\n const sectionToSave = sections.filter(s => s.id === sectionIdToSave)[0];\n \n if (!sectionToSave)\n return;\n\n let sectionFields = [...sectionToSave.fields];\n\n if (fieldMode === \"new\") {\n const response = await SettingsPatientFormsService.createSectionField(new SectionFieldCreateRequest({\n sectionId: sectionToSave.id,\n name: newField.name,\n type: newField.type,\n isRequired: newField.isRequired,\n isAdditionalTextareaEnabled: newField.type === SectionFieldType.Radio\n ? newField.isAdditionalTextareaEnabled\n : false,\n itemsNames: newField.items.sort((i1, i2) => i1.order - i2.order).map(i => i.name)\n }));\n\n if (!response)\n return;\n\n const afterResponseField = { ...newField }\n afterResponseField.id = response.id\n afterResponseField.order = sectionToSave.fields.length + 1;\n afterResponseField.isAdditionalTextareaEnabled = afterResponseField.type === SectionFieldType.Radio\n ? afterResponseField.isAdditionalTextareaEnabled\n : false;\n\n for (let i = 0; i < response.fieldItemIds.length; i++) {\n afterResponseField.items[i].id = response.fieldItemIds[i];\n }\n\n sectionFields.push(afterResponseField);\n }\n else {\n const response = await SettingsPatientFormsService.updateSectionField(new SectionFieldUpdateRequest({\n id: newField.id,\n sectionId: sectionToSave.id,\n name: newField.name,\n type: newField.type,\n isRequired: newField.isRequired,\n isAdditionalTextareaEnabled: newField.type === SectionFieldType.Radio\n ? newField.isAdditionalTextareaEnabled\n : false,\n items: newField.items.sort((i1, i2) => i1.order - i2.order).map(i => new SectionFieldItemModel({\n id: i.id?.length === 36 ? i.id : null, //is guid?\n name: i.name,\n order: i.order\n }))\n }));\n\n if (!response)\n return;\n\n for (let i = 0; i < response.fieldItemIds.length; i++) {\n newField.items[i].id = response.fieldItemIds[i];\n }\n\n newField.isAdditionalTextareaEnabled = newField.type === SectionFieldType.Radio\n ? newField.isAdditionalTextareaEnabled\n : false;\n const fieldIndexToUpdate = sectionFields.findIndex(i => i.id === newField.id);\n sectionFields[fieldIndexToUpdate] = newField;\n }\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: fieldMode === \"new\" ? t(\"Item created\") : t(\"Item edited\"),\n description: t(newField.name, { ns: sectionTNamespace })\n })\n );\n\n sectionFields = sectionFields.sort((f1, f2) => f1.order - f2.order)\n setSection({ ...sectionToSave, fields: sectionFields })\n }\n\n const handleSectionFieldDelete = async (field: SectionFieldModel) => {\n if (!setSection)\n return;\n \n const sectionFields = [...section.fields];\n const fieldIndexToDelete = sectionFields.findIndex(i => i.id === field.id);\n\n if (fieldIndexToDelete === -1)\n return;\n\n const isSuccessful = await SettingsPatientFormsService.deleteSectionField(new SectionFieldDeleteRequest({\n id: field.id,\n sectionId: section.id,\n order: field.order\n }));\n\n if (!isSuccessful)\n return;\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Item deleted\"),\n description: t(field.name, { ns: sectionTNamespace })\n })\n );\n\n let updatedSectionFields = sectionFields.filter((_, i) => i !== fieldIndexToDelete);\n updatedSectionFields = updatedSectionFields.sort((f1, f2) => f1.order - f2.order)\n setSection({ ...section, fields: updatedSectionFields })\n\n setDeleteModalField(undefined);\n setDeleteFieldConfirmationModalIsOpen(false);\n }\n\n const handleExitEdit = () => {\n setName(section.name!);\n setSectionEditMode(false);\n }\n\n const getTabName = (sectionType: SectionType) => {\n switch (sectionType) {\n case SectionType.ClinicHistory:\n return t(\"of the Clinic history\");\n case SectionType.VitalSigns:\n return t(\"of the Evolution notes\");\n case SectionType.PatientForm:\n return t(\"of the Patient form\");\n }\n }\n\n const getCustomHeaderButton = () => {\n if (customHeaderButton)\n return customHeaderButton;\n return <></>;\n };\n\n const getEditButton = (section: SectionModel) => {\n if (section.isEditable)\n return (<Button\n key={\"editButton\"}\n onClick={() => handleEditButtonClick()}\n className={classes.headerButton}\n >\n <SectionEditIcon />\n </Button>);\n return <></>;\n };\n\n const getSaveButton = (section: SectionModel) => {\n if (section.isEditable && isSectionEditMode)\n return (<Button\n key={\"saveButton\"}\n onClick={async () => await handleEditSection()}\n className={classes.headerButton}\n >\n <SectionSaveIcon />\n </Button>);\n return <></>;\n };\n\n const getExitEditButton = (section: SectionModel) => {\n if (section.isEditable && isSectionEditMode)\n return (<Button\n onMouseDown={() => handleExitEdit()}\n className={classes.headerButton}\n >\n <SectionExitEditIcon />\n </Button>);\n return <></>;\n };\n\n const getDeleteSectionButton = (section: SectionModel) => {\n if (section.isRemovable && section.type !== SectionType.VitalSigns)\n return (<Button\n onClick={() => setDeleteSectionConfirmationModalIsOpen(true)}\n className={classes.headerButton}\n >\n <SectionDeleteIcon />\n </Button>);\n return <></>;\n };\n\n const getMoveDownButton = (section: SectionModel) => {\n if (onMoveDown && section.type !== SectionType.VitalSigns) {\n const isDisabled = section.order === sections?.length ?? 0;\n return (<Button\n onClick={() => onMoveDown && onMoveDown()}\n disabled={section.order === sections?.length ?? 0}\n className={isDisabled ? classes.headerButtonDisabled : classes.headerButton}\n >\n <SectionArrowIcon />\n </Button>);\n }\n return <></>;\n };\n\n const getMoveUpButton = (section: SectionModel) => {\n if (onMoveUp && section.type !== SectionType.VitalSigns) {\n const isDisabled = section.order === 1;\n return (<Button\n onClick={() => onMoveUp && onMoveUp()}\n disabled={isDisabled}\n className={isDisabled ? classes.headerButtonDisabled : classes.headerButton}\n >\n <SectionArrowIcon style={{ transform: \"rotate(180deg)\" }} />\n </Button>);\n }\n return <></>;\n };\n\n const getHeaderButtons = (section: SectionModel) => {\n if (isSectionEditMode) {\n return (\n <>\n {getSaveButton(section)}\n {getExitEditButton(section)}\n </>\n );\n }\n return (\n <>\n {getCustomHeaderButton()}\n {getEditButton(section)}\n {getDeleteSectionButton(section)}\n {getMoveDownButton(section)}\n {getMoveUpButton(section)}\n </>\n );\n };\n\n const getSectionFooterComponent = (section: SectionModel) => {\n if (section.isEditable) {\n return <Grid item className={classes.footerContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New item\")}\n innerIcon={<SectionFieldNewIcon />}\n onClick={handleNewFieldButtonClick}\n />\n </Grid>\n }\n\n return <></>\n }\n \n const getSectionContent = (section: SectionModel) => {\n if (section.fields.length === 0)\n return (\n <div className={classes.noItemsBox}>\n <Typography className={classes.noItemsLabel}>\n {t(\"Section without items\")}\n </Typography>\n </div>);\n else\n return (<FieldList\n section={section}\n onEditClick={handleEditFieldClick}\n onDeleteClick={handleDeleteFieldClick}\n />)\n };\n\n const DeleteSectionModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete this section\") + \" \" + getTabName(section.type!) + \"?\"}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentBoldText}>\n {t(section.name!, { ns: sectionTNamespace })}\n </Typography>\n </div>);\n };\n\n const DeleteFieldModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete this item?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentText}>\n {t(\"Delete the\") + \" \"}\n <span className={classes.deleteModalContentBoldText}>\n {\"\\\"\" + t(deleteModalField?.name ?? \"\", { ns: sectionTNamespace }) + \"\\\"\"}\n </span>\n {\" \" + t(\"item from the\") + \" \"}\n <span className={classes.deleteModalContentBoldText}>\n {\"\\\"\" + t(section.name!, { ns: sectionTNamespace }) + \"\\\"\" + \"?\"}\n </span>\n </Typography>\n </div>);\n };\n\n return <>\n <div className={classes.root}>\n <Box>\n <Grid container justifyContent=\"center\" className={classes.sectionContainer}>\n <Grid item\n className={classes.headerContainer}\n onMouseEnter={() => { setHeaderHover(true) }}\n onMouseLeave={() => { setHeaderHover(false) }} >\n {!isSectionEditMode\n ? <Typography className={classes.headerTitle}>\n {t(section.name!, { ns: sectionTNamespace })}\n </Typography>\n : <Input\n inputClass={classes.sectionEditNameInput}\n value={t(name, { ns: sectionTNamespace })}\n isValid={() => { return name.trim().length > 0 && name.length <= 200 }}\n onChange={(event) => handleOnChange(event)}\n onBlur={async () => await handleEditSection()}\n disabled={!isSectionEditMode || !section.isEditable}\n maxLength={maxTextFieldLength}\n width={\"91%\"}\n ref={sectionInputRef}\n autoFocus\n />}\n {headerHover || isSectionEditMode\n ? <div className={classes.headerButtonsContainer}>\n {getHeaderButtons(section)}\n </div>\n : <></>}\n </Grid>\n <div className={classes.innerLayout}>\n {customNote ? customNote : <></>}\n <Grid item className={classes.fieldsContainer}>\n {getSectionContent(section)}\n </Grid>\n {getSectionFooterComponent(section)}\n </div>\n </Grid>\n </Box>\n </div>\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteSectionConfirmationModalIsOpen}\n item={section}\n componentInfo={<DeleteSectionModalContent />}\n onClose={() => setDeleteSectionConfirmationModalIsOpen(false)}\n onDelete={() => handleDeleteSection(section)}\n />\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteFieldConfirmationModalIsOpen}\n item={deleteModalField}\n componentInfo={<DeleteFieldModalContent />}\n onClose={() => setDeleteFieldConfirmationModalIsOpen(false)}\n onDelete={async () => await handleSectionFieldDelete(deleteModalField!)}\n />\n <SectionFieldModal\n isOpen={sectionFieldModalIsOpen}\n setOpen={setSectionFieldModalIsOpen}\n mode={fieldMode}\n field={modalField}\n section={section}\n sections={sections ?? []}\n onSave={async (newField, sectionIdToSave) => await handleSectionFieldSave(newField, sectionIdToSave)} />\n </>\n\n};","import { SectionType } from \"./enums/section-type\";\n\nexport class SectionDeleteRequest {\n establishmentAccountId?: string|null;\n id: string | null;\n type: SectionType;\n order: number;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.id = x.id;\n this.type = x.type;\n this.order = x.order;\n } else {\n this.establishmentAccountId = null;\n this.id = null;\n this.type = SectionType.ClinicHistory;\n this.order = 0;\n }\n }\n}","export enum ClinicalHistoryCommunicationSettingType {\n SendConfirmationToPatientWithoutHistory = 0,\n SendReminderToPatientWithoutHistory, \n SendConfirmationToPatient,\n SendReminderToPatient,\n PrivacyNoticeEnable,\n ConsentLetterEnable,\n ClinicalHistoryEnable,\n}\n","import { SectionType } from \"./enums/section-type\";\n\nexport class SectionCreateRequest {\n establishmentAccountId?: string|null;\n type: SectionType;\n name: string;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.type = x.type;\n this.name = x.name;\n } else {\n this.establishmentAccountId = null;\n this.name = \"\";\n this.type = SectionType.ClinicHistory;\n }\n }\n}","import React, { forwardRef, useEffect, useImperativeHandle } from \"react\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { SectionListProps } from \"./props\";\nimport SectionListRefs from \"./section-list-refs\";\nimport useStyles from \"./css\";\n\nimport Section from \"../Section\";\n\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport { SectionUpdateRequest } from \"../../../../../models/section-update-request\";\nimport { SectionDeleteRequest } from \"../../../../../models/section-delete-request\";\nimport { SectionCreateRequest } from \"../../../../../models/section-create-request\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\n\n\nconst SectionList = forwardRef<SectionListRefs, any>((props: SectionListProps, ref) => {\n const { sectionType, sections, setSections } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n const { t } = useTranslation([\"general\"]);\n\n //to make the \"createSection\" function callable from the parent component\n useImperativeHandle(ref, () => ({\n createSection: async (name: string) => {\n const resultId = await SettingsPatientFormsService.createSection(new SectionCreateRequest({\n type: sectionType,\n name: name,\n }));\n\n const newSections = [...sections];\n newSections.forEach(s => {\n s.order = s.order! + 1;\n });\n\n newSections.push(new SectionModel({\n id: resultId,\n name: name,\n order: 1,\n type: sectionType,\n fields: [],\n isEditable: true,\n isRemovable: true\n }));\n\n setSections(newSections);\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Section created\"),\n description: name\n })\n );\n }\n }));\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n dispatch(navbarActions.setShowLoader(false));\n }\n fetchData();\n }, []);\n\n const handleEditSection = async (section: SectionModel) => {\n await SettingsPatientFormsService.updateSection(new SectionUpdateRequest({\n id: section.id,\n type: section.type,\n newName: section.name,\n newOrder: section.order,\n previousOrder: null\n }))\n .then(() => {\n setSection(section)\n })\n };\n\n const handleDeleteSection = async (section: SectionModel) => {\n const sectionOrder = section.order;\n await SettingsPatientFormsService.deleteSection(new SectionDeleteRequest({\n id: section.id,\n type: sectionType,\n order: sectionOrder\n }));\n\n const updatedSections = sections.filter(s => s.id !== section.id);\n\n updatedSections.forEach(s => {\n if (s.order! < sectionOrder!)\n return;\n s.order = s.order! - 1;\n });\n\n setSections(updatedSections);\n };\n\n const handleMove = async (sectionId: string, isUp: boolean) => {\n const step = isUp ? -1 : 1;\n const targetSection = sections.find(s => s.id === sectionId);\n const targetSectionIndex = sections.findIndex(s => s.id === sectionId);\n const pairedSectionIndex = sections.findIndex(s => s.order === targetSection!.order! + step);\n\n const newSections = [...sections];\n newSections[pairedSectionIndex].order = targetSection!.order!;\n newSections[targetSectionIndex].order = targetSection!.order! + step;\n setSections(newSections);\n\n await SettingsPatientFormsService.updateSection(new SectionUpdateRequest({\n id: targetSection!.id!,\n type: sectionType,\n newName: targetSection!.name!,\n newOrder: targetSection?.order,\n previousOrder: targetSection!.order! - step\n }));\n };\n\n const setSection = (section: SectionModel) => {\n const targetSection = sections.find(s => s.id === section.id);\n if (!targetSection)\n return;\n\n const targetSectionIndex = sections.findIndex(s => s.id === section.id);\n const updatedSections = [...sections];\n\n updatedSections[targetSectionIndex].fields = [...section.fields];\n\n setSections(updatedSections);\n };\n\n const loadData = async () => {\n const sectionsData =\n await SettingsPatientFormsService.getAccountSettingsTabSections(sectionType);\n setSections(sectionsData);\n };\n\n const mapSections = () => {\n return sections.sort((s1, s2) => s1.order! - s2.order!).map(s =>\n <Section\n key={s.id!}\n section={s}\n sections={sections}\n setSection={(updatedSection) => setSection(updatedSection)}\n onEdit={async () => { await handleEditSection(s) }}\n onDelete={async () => { await handleDeleteSection(s) }}\n onMoveDown={async () => { await handleMove(s.id!, false) }}\n onMoveUp={async () => { await handleMove(s.id!, true) }} />)\n };\n\n return <div className={classes.sectionsContainer}>\n {mapSections()}\n </div>\n});\n\nexport default SectionList;","export class ClinicalHistoryCommunicationSettings {\n establishmentAccountId: string|null;\n isClinicalHistoryEnabled: boolean;\n sendFormOnConfirmationNoHistory: boolean;\n sendFormOnReminderNoHistory: boolean;\n sendFormOnConfirmationIncompleteHistory: boolean;\n sendFormOnReminderIncompleteHistory: boolean;\n isPrivacyNoticeEnabled: boolean;\n privacyNotice: string;\n isConsentLetterEnabled: boolean;\n consentLetter: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.establishmentAccountId = x.establishmentAccountId;\n this.isClinicalHistoryEnabled = x.isClinicalHistoryEnabled;\n this.sendFormOnConfirmationNoHistory = x.sendFormOnConfirmationNoHistory;\n this.sendFormOnReminderNoHistory = x.sendFormOnReminderNoHistory;\n this.sendFormOnConfirmationIncompleteHistory = x.sendFormOnConfirmationIncompleteHistory;\n this.sendFormOnReminderIncompleteHistory = x.sendFormOnReminderIncompleteHistory;\n this.isPrivacyNoticeEnabled = x.isPrivacyNoticeEnabled;\n this.privacyNotice = x.privacyNotice;\n this.isConsentLetterEnabled = x.isConsentLetterEnabled;\n this.consentLetter = x.consentLetter;\n } \n else {\n this.establishmentAccountId = null;\n this.isClinicalHistoryEnabled = false;\n this.sendFormOnConfirmationNoHistory = false;\n this.sendFormOnReminderNoHistory = false;\n this.sendFormOnConfirmationIncompleteHistory =false;\n this.sendFormOnReminderIncompleteHistory = false;\n this.isPrivacyNoticeEnabled = false;\n this.privacyNotice = \"\";\n this.isConsentLetterEnabled = false;\n this.consentLetter = \"\";\n }\n }\n}","import { ApiClient } from \"./api-client\";\nimport { ClinicalHistoryCommunicationSettings } from \"../models/clinical-history-communication-settings-model\";\nimport { CopyEstablishmentSettingsModel } from \"../models/copy-establishment-settings-model\";\n\nexport class ClinicalHistoryCommunicationSettingsService {\n \n private static baseUrl: string = \"/account\";\n \n static async updateClinicalHistoryCommunicationSettings(communicationSettingsModel: ClinicalHistoryCommunicationSettings): Promise<ClinicalHistoryCommunicationSettings> {\n const data = await ApiClient.post(`${this.baseUrl}/updateclinicalhistorycommunicationsettings`, communicationSettingsModel);\n return new ClinicalHistoryCommunicationSettings(data.clinicalHistoryCommunicationSettings);\n }\n \n static async getClinicalHistoryCommunicationSetting(establishmentAccountId?: string | null | undefined): Promise<ClinicalHistoryCommunicationSettings> {\n const establishmentAccountIdRequestValue = establishmentAccountId === null || establishmentAccountId === undefined \n ? \"\" \n : establishmentAccountId;\n const data = await ApiClient.get(`${this.baseUrl}/getclinicalhistorycommunicationsettings?EstablishmentAccountId=${establishmentAccountIdRequestValue}`);\n return new ClinicalHistoryCommunicationSettings(data.clinicalHistoryCommunicationSettings);\n }\n \n static async copyClinicalHistorySetting(copyModel: CopyEstablishmentSettingsModel): Promise<boolean> {\n return await ApiClient.post(`${this.baseUrl}/copyclinicalhistorysetting`, copyModel).then(\n (data) => (data.succeeded)\n );\n }\n}\n","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { ClinicHistoryProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { InfoIcon, SectionNewIcon } from \"../../../../../assets/icons\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport SectionNewModal from \"../SectionNewModal\";\nimport SectionList from \"../SectionList\";\nimport SectionListRefs from \"../SectionList/section-list-refs\";\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport {\n ClinicalHistoryCommunicationSettingsService\n} from \"../../../../../api/service-сlinical-history-communication-settings\";\nimport {\n ClinicalHistoryCommunicationSettings\n} from \"../../../../../models/clinical-history-communication-settings-model\";\nimport {\n ClinicalHistoryCommunicationSettingType\n} from \"../../../../../models/enums/clinical-history-communication-setting-type\";\nimport { Editor } from \"@tinymce/tinymce-react\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport SwitchWithLabelAndTooltip from \"../../../../common/SwitchWithLabelAndTooltip\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default function ClinicHistory(props: ClinicHistoryProps) {\n \n const { t } = useTranslation([\"general\"]);\n const {} = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const currentTabSectionType = SectionType.ClinicHistory;\n const maxTextLength: number = 25000;\n const [sections, setSections] = useState<SectionModel[]>([]);\n const [newSectionModalIsOpen, setNewSectionModalIsOpen] = useState<boolean>(false);\n const [entity, setEntity] = useState<ClinicalHistoryCommunicationSettings>(new ClinicalHistoryCommunicationSettings());\n const [focusedPrivacyNotice, setFocusedPrivacyNotice] = useState<boolean>(false);\n const [focusedConsentLetter, setFocusedConsentLetter] = useState<boolean>(false);\n const [textLengthPrivacyNotice, setTextLengthPrivacyNotice] = useState<number>(0);\n const [textLengthConsentLetter, setTextLengthConsentLetter] = useState<number>(0);\n const [originalPrivacyNoticeValue, setOriginalPrivacyNoticeValue] = useState<string>(\"\");\n const [originalConsentLetterValue, setOriginalConsentLetterValue] = useState<string>(\"\");\n const accountSettings = useAppSelector(selectAccountSettings);\n \n const sectionListRef = useRef<SectionListRefs>(null);\n \n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n await loadClinicalHistoryCommunicationSettings();\n dispatch(navbarActions.setShowLoader(false));\n }\n \n fetchData();\n }, []);\n \n const handleCreateSection = async (name: string) => {\n await sectionListRef?.current?.createSection(name);\n }\n \n const loadData = async () => {\n \n const sectionsData =\n await SettingsPatientFormsService.getAccountSettingsTabSections(currentTabSectionType);\n setSections(sectionsData);\n };\n\n const handleOpenPreview = () => {\n window.open(`https://sitiodereservas.somosclear.com/${accountSettings.siteForFinalCustomersSmbName}/patient-form?previewStep=second`, '_blank', 'noopener,noreferrer');\n }\n \n const setPrivacyNoticeTextLength = (evt: any, editor: any) => {\n setTextLengthPrivacyNotice(editor.getContent({ format: \"text\" }).length);\n };\n const setConsentLetterTextLength = (evt: any, editor: any) => {\n setTextLengthConsentLetter(editor.getContent({ format: \"text\" }).length);\n };\n const updatePrivacyNotice = async () => {\n setFocusedPrivacyNotice(false);\n if (entity.privacyNotice != originalPrivacyNoticeValue) {\n await saveClinicalHistoryCommunicationSettings(entity);\n setOriginalPrivacyNoticeValue(entity.privacyNotice);\n }\n \n };\n const updateConsentLetter = async () => {\n setFocusedConsentLetter(false);\n if (entity.consentLetter != originalConsentLetterValue) {\n await saveClinicalHistoryCommunicationSettings(entity);\n setOriginalConsentLetterValue(entity.consentLetter);\n }\n };\n \n const handleEditorPrivacyNoticeChange = async (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n \n if (contentText.length <= maxTextLength) {\n let updating: ClinicalHistoryCommunicationSettings;\n updating = {\n ...entity,\n privacyNotice: contentHtml\n };\n setEntity(updating);\n setTextLengthPrivacyNotice(contentText.length);\n }\n }\n \n const handleEditorConsentLetterChange = async (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n if (contentText.length <= maxTextLength) {\n let updating: ClinicalHistoryCommunicationSettings;\n updating = {\n ...entity,\n consentLetter: contentHtml\n };\n setEntity(updating);\n setTextLengthConsentLetter(contentText.length);\n }\n }\n \n const saveClinicalHistoryCommunicationSettings = async (updating: ClinicalHistoryCommunicationSettings) => {\n const result = await ClinicalHistoryCommunicationSettingsService.updateClinicalHistoryCommunicationSettings(updating);\n if (result) {\n setEntity(result);\n }\n }\n \n const loadClinicalHistoryCommunicationSettings = async () => {\n \n const info = await ClinicalHistoryCommunicationSettingsService.getClinicalHistoryCommunicationSetting();\n \n const regex = /(<([^>]+)>)/ig;\n \n setTextLengthPrivacyNotice(info.privacyNotice?.replace(regex, \"\").length);\n setTextLengthConsentLetter(info.consentLetter?.replace(regex, \"\").length);\n setOriginalPrivacyNoticeValue(info.privacyNotice);\n setOriginalConsentLetterValue(info.consentLetter);\n setEntity(info);\n }\n\n async function handleToggleClinicalHistory(value: boolean) {\n if (value) {\n await handleSetClinicalHistoryCommunicationSettings(value, ClinicalHistoryCommunicationSettingType.ClinicalHistoryEnable)\n return;\n }\n\n let updating = {\n ...entity,\n isClinicalHistoryEnabled: false,\n sendFormOnReminderNoHistory: false,\n sendFormOnConfirmationNoHistory: false\n }\n\n await saveClinicalHistoryCommunicationSettings(updating);\n }\n \n const handleSetClinicalHistoryCommunicationSettings = async (value: boolean, settingType: ClinicalHistoryCommunicationSettingType) => {\n let updating: ClinicalHistoryCommunicationSettings;\n updating = {\n ...entity\n };\n switch (settingType) {\n case ClinicalHistoryCommunicationSettingType.SendConfirmationToPatientWithoutHistory:\n updating = {\n ...entity,\n sendFormOnConfirmationNoHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.SendReminderToPatientWithoutHistory:\n updating = {\n ...entity,\n sendFormOnReminderNoHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.SendConfirmationToPatient:\n updating = {\n ...entity,\n sendFormOnConfirmationIncompleteHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.SendReminderToPatient:\n updating = {\n ...entity,\n sendFormOnReminderIncompleteHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.ConsentLetterEnable:\n updating = {\n ...entity,\n isConsentLetterEnabled: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.PrivacyNoticeEnable:\n updating = {\n ...entity,\n isPrivacyNoticeEnabled: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.ClinicalHistoryEnable:\n updating = {\n ...entity,\n isClinicalHistoryEnabled: value\n };\n break;\n }\n await saveClinicalHistoryCommunicationSettings(updating);\n }\n \n const getClinicalHistoryCommunicationSettingsContent = () => {\n return <div>\n <Typography className={classes.communicationSettingsHeader}>\n {t(\"Communication with the patient about the Clinical history\")}\n </Typography>\n <div style={{ paddingBottom: 32 }}>\n <div className={classes.communicationSettingsContainer}>\n <div style={{ padding: 36, display: \"flex\", flexDirection: \"column\" }}>\n <div style={{ marginBottom: 14 }}>\n <Typography className={classes.communicationSettingsMainTitle}>\n {t(\"Patient form\")}\n </Typography>\n <div className={classes.clinicalHistorySwitch}>\n <SwitchWithLabelAndTooltip\n value={entity.isClinicalHistoryEnabled}\n setValue={handleToggleClinicalHistory}\n label={t(\"Clinical history\")}\n tooltip={t(\"PatientFormIncludesClinicalHistory\")}\n inactiveTooltip={t(\"PatientFormDoesNotIncludeClinicalHistory\")}\n />\n </div>\n </div>\n\n <Typography className={classes.communicationSettingsMainTitle}>\n {t(\"Send form by WhatsApp\")}\n </Typography>\n \n <Typography className={classes.communicationSettingsCheckboxGroupTitle}>\n {t(\"To patients without Clinical history\")}\n </Typography>\n <div style={{ marginBottom: 14 }}>\n <SwitchWithLabel\n value={entity.sendFormOnConfirmationNoHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendConfirmationToPatientWithoutHistory)}\n label={t(\"Appointment confirmation\")}\n disabled={!entity.isClinicalHistoryEnabled}\n />\n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form when creating the appointment\")}\n />\n </div>\n <div style={{ marginBottom: 26 }}>\n <SwitchWithLabel\n value={entity.sendFormOnReminderNoHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendReminderToPatientWithoutHistory)}\n label={t(\"Appointment reminder\")}\n disabled={!entity.isClinicalHistoryEnabled}\n />\n \n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form on the appointment reminder\")}\n />\n </div>\n \n <Typography className={classes.communicationSettingsCheckboxGroupTitle}>\n {t(entity.isClinicalHistoryEnabled ? \"To patients with Incomplete General information and/or clinical history\" : \"To patients with incomplete General info\")}\n </Typography>\n <div style={{ marginBottom: 14 }}>\n <SwitchWithLabel\n value={entity.sendFormOnConfirmationIncompleteHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendConfirmationToPatient)}\n label={t(\"Appointment confirmation\")}\n />\n \n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form when creating the appointment\")}\n />\n </div>\n <div style={{ marginBottom: 31 }}>\n <SwitchWithLabel\n value={entity.sendFormOnReminderIncompleteHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendReminderToPatient)}\n label={t(\"Appointment reminder\")}\n />\n \n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form on the appointment reminder\")}\n />\n </div>\n \n <Typography className={classes.mainTitle} style={{ marginBottom: 13 }}>\n {t(\"Privacy notice\")}\n </Typography>\n \n <SwitchWithLabel\n value={entity.isPrivacyNoticeEnabled}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.PrivacyNoticeEnable)}\n label={t(\"Include privacy notice in the form\")}\n />\n <div className={`${classes.tinyMceOverrides} ${focusedPrivacyNotice ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"Write here.\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\"\n }}\n value={entity.privacyNotice}\n onFocusIn={() => setFocusedPrivacyNotice(true)}\n onBlur={updatePrivacyNotice}\n onInit={setPrivacyNoticeTextLength}\n onEditorChange={handleEditorPrivacyNoticeChange}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLengthPrivacyNotice >= maxTextLength) {\n e.preventDefault();\n }\n }}\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{textLengthPrivacyNotice + \"/\" + maxTextLength}</span>\n </div>\n \n </div>\n \n <Typography className={classes.mainTitle} style={{ marginBottom: 13 }}>\n {t(\"Consent letter\")}\n </Typography>\n \n <SwitchWithLabel\n value={entity.isConsentLetterEnabled}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.ConsentLetterEnable)}\n label={t(\"Include informed consent letter in the form\")}\n />\n <div className={`${classes.tinyMceOverrides} ${focusedConsentLetter ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"Write here.\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\"\n }}\n value={entity.consentLetter}\n onFocusIn={() => setFocusedConsentLetter(true)}\n onBlur={updateConsentLetter}\n onInit={setConsentLetterTextLength}\n onEditorChange={handleEditorConsentLetterChange}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLengthConsentLetter >= maxTextLength) {\n e.preventDefault();\n }\n }}\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{textLengthConsentLetter + \"/\" + maxTextLength}</span>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n };\n \n return <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Clinic history\")}\n </Typography>\n {\n entity.isClinicalHistoryEnabled &&\n <Button\n className={classes.previewButton}\n onClick={handleOpenPreview}\n >\n {t(\"Preview\")}\n </Button>\n }\n \n <ButtonWithSpinner\n margin={\"0px 0px 0px auto\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New section\")}\n innerIcon={<SectionNewIcon />}\n onClick={() => setNewSectionModalIsOpen(true)}\n />\n </div>\n <SectionList\n ref={sectionListRef}\n sectionType={currentTabSectionType}\n sections={sections}\n setSections={setSections}/>\n <SectionNewModal\n sections={sections}\n isOpen={newSectionModalIsOpen}\n setOpen={setNewSectionModalIsOpen}\n onCreate={handleCreateSection}\n />\n \n {getClinicalHistoryCommunicationSettingsContent()}\n \n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n sectionsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n treatmentNoteBox: {\n width: \"100%\",\n height: \"37px\",\n display: \"flex\",\n alignItems: \"center\",\n borderRadius: \"5px\",\n background: Color.clilac,\n marginBottom: 14\n },\n treatmentNoteLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: Color.gray5,\n margin: \"0px 14px 0px 14px\"\n },\n headerButton: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n},\n\n}));\n\nexport default useStyles;","export enum StaticTreatmentDocumentFieldType {\n SpecialistFullName = 1,\n SpecialistPhoneNumber,\n PatientFullName,\n AppointmentDate,\n PatientAge,\n PatientGender,\n VitalSigns,\n Diagnosis,\n Treatment,\n SpecialistSign\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"10px\",\n marginBottom: \"10px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: theme.colors.grey3,\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: theme.colors.grey4\n }\n },\n paper: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"5px\",\n boxShadow: theme.shadows[5],\n width: 1000,\n height: 565,\n padding: \"25px 27px 109px 45px\"\n },\n headerContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n paddingBottom: 43\n },\n titleContainer: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n modalNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"normal\",\n color: theme.colors.grey5\n },\n requiredFieldLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.grey4\n },\n asterix: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.clearMain\n },\n modalManagementButtonsContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 16\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: \"5px\",\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n },\n goBack: {\n color: theme.colors.grey3,\n border: \"1px solid \" + theme.colors.grey3\n },\n continueButton: {\n background: theme.colors.clearGreen,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n },\n saveDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n mainContentContainer: {\n display: \"flex\",\n flexDirection: \"row\"\n },\n settingsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n width: \"50%\",\n maxWidth: \"50%\"\n },\n scrollableSettingContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n maxHeight: 434,\n overflowY: \"auto\"\n },\n printDetailsLabelContainer: {\n display: \"flex\",\n flexDirection: \"row\"\n },\n violetHeaderLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"normal\",\n color: theme.colors.clear2,\n paddingBottom: 13\n },\n iconTooltipRoot: {\n display: \"inline-block\",\n marginLeft: 5,\n },\n previewContainer: {\n width: \"50%\",\n maxWidth: \"50%\"\n },\n documentSizeSelect: {\n color: theme.colors.clearMain + \" !important\",\n paddingBottom: 22\n },\n logoDisableableSection: {\n display: \"flex\",\n flexDirection: \"column\",\n paddingTop: 20\n },\n disabled: {\n pointerEvents: \"none\",\n opacity: 0.3,\n },\n logoConfigurationSection: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 9\n },\n logoConfigurationLeftSection: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 12\n },\n logoConfigurationRightSection: {\n display: \"flex\",\n columnGap: 24,\n rowGap: 19,\n flexWrap: \"wrap\",\n alignContent: \"flex-start\"\n },\n logoNotesContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n paddingTop: 24\n },\n notes: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.grey5,\n },\n notesBold: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.grey5,\n },\n logo: {\n width: 194,\n height: 127,\n borderRadius: 15,\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"contain\",\n backgroundPosition: \"center top\",\n },\n logoEmpty: {\n width: 194,\n height: 127,\n backgroundColor: \"#F6F6F6\",\n borderRadius: 15,\n border: \"1px dashed #DBDCDD;\",\n cursor: \"pointer\",\n },\n emptyLogoStubContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 5,\n alignItems: \"center\",\n marginTop: 31\n },\n iconCamera: {\n color: \"#919CA5\",\n fontSize: 20,\n cursor: \"pointer\",\n marginLeft: 10,\n marginTop: 3,\n },\n iconTrash: {\n color: \"#919CA5\",\n fontSize: 24,\n cursor: \"pointer\",\n marginLeft: 10,\n },\n addPhotoLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.grey4,\n marginTop: 8\n },\n addPhotoMinSizeLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"9px\",\n lineHeight: \"normal\",\n color: theme.colors.grey4,\n },\n logoControls: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n alignItems: \"center\",\n gap: 7,\n marginTop: -7\n },\n logoControlsEmptyStub: {\n marginTop: -7,\n height: 23\n },\n columnNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"normal\",\n color: theme.colors.grey4,\n },\n logoNumericInputContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 12\n },\n fieldSettingsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n marginTop: 24,\n maxWidth: 435\n },\n fieldSettingsRow: {\n display: \"flex\",\n justifyContent: \"space-between\",\n marginBottom: 29\n },\n fieldSettingsGridItem: {\n \"&:nth-child(1)\": {\n width: 180,\n maxWidth: 180\n },\n \"&:nth-child(2)\": {\n marginLeft: -10,\n }\n },\n deleteConfirmationModal: {\n height: \"200px !important\"\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n closeConfirmationModal: {\n height: \"234px + !important\"\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n previewSectionLabel: {\n marginLeft: 15\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { TreatmentDocumentFieldSettingsModel } from \"../../../../../../../models/treatment-document-field-settings-model\";\n\nconst useStyles = makeStyles((theme) => ({\n previewContainer: {\n backgroundColor: theme.colors.grey2,\n height: 425,\n width: 446,\n marginLeft: 15,\n },\n commonPage: {\n backgroundColor: theme.colors.white,\n\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-between\",\n\n padding: \"1cm\",\n },\n halfLetterPage: {\n width: \"14cm\",\n height: \"21.6cm\",\n transform: 'scale(0.5)',\n transformOrigin: '34% 2%'\n },\n letterPage: {\n width: \"21.6cm\",\n height: \"27.9cm\",\n transform: 'scale(0.39)',\n transformOrigin: '13% 1%'\n },\n legalPage: {\n width: \"21.6cm\",\n height: \"33cm\",\n transform: 'scale(0.33)',\n transformOrigin: '16% 1%'\n },\n dividerCommon: {\n borderBottom: \"solid\",\n borderBottomWidth: 1,\n borderBottomColor: theme.colors.grey2,\n },\n dividerHalfLetter: {\n width: \"12cm\"\n },\n dividerLetter: {\n width: \"19.6cm\"\n },\n dividerLegal: {\n width: \"19.6cm\"\n },\n dividerHeader: {\n marginTop: 1,\n marginBottom: 5,\n },\n specialistNameLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"0.42cm\",\n lineHeight: \"normal\",\n color: theme.colors.grey7,\n },\n dynamicFieldValueLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"0.38cm\",\n lineHeight: \"normal\",\n color: theme.colors.grey7,\n },\n staticFieldNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"0.40cm\",\n lineHeight: \"normal\",\n color: theme.colors.grey7,\n },\n staticFieldValueLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"0.40cm\",\n lineHeight: \"normal\",\n color: theme.colors.grey7,\n },\n flexColumn: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 5\n },\n flexRow: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 5\n },\n signatureContainer: {\n width: \"8.33cm\",\n\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n\n alignSelf: \"flex-end\"\n },\n dividerSignature: {\n width: \"8.33cm\"\n },\n pageHeader: {\n alignSelf: \"flex-start\",\n\n display: \"flex\",\n flexDirection: \"column\",\n gap: 5,\n\n width: \"100%\",\n },\n headerSpecialistRow: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n },\n logo: {\n alignSelf: \"flex-start\",\n objectFit: \"contain\",\n width: 90,\n height: 90,\n },\n logoSpecialistBlock: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 5,\n },\n specialistInfoBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n patientInfoBlock: {\n display: \"flex\",\n flexDirection: \"row\",\n\n justifyContent: \"space-between\",\n },\n flexDualColumn: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 5\n },\n dualLeftColumn: {\n display: \"flex\",\n flex: \"66%\",\n gap: 5,\n },\n dualRightColumn: {\n display: \"flex\",\n flex: \"33%\",\n gap: 5,\n },\n pageContent: {\n display: \"flex\",\n flexDirection: \"column\",\n gap: 5,\n },\n pageHeaderWithContent: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n pageFooter: {\n display: \"flex\",\n flexDirection: \"column\",\n }\n}));\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { conformToMask } from \"react-text-mask\";\nimport moment from \"moment\";\n\nimport { useAppSelector } from \"../../../../../../../redux/hooks\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../../../../redux/store\";\n\nimport { TreatmentDocumentPreviewProps } from \"./props\";\nimport useTerminology from \"../../../../../../../hooks/useTerminology\";\nimport { TerminologyType } from \"../../../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../../../models/enums/terminology-form\";\nimport useStyles from \"./css\";\nimport { TreatmentDocumentSize } from \"../../../../../../../models/enums/treatment-document-size\";\nimport { StaticTreatmentDocumentFieldType } from \"../../../../../../../models/enums/static-treatment-document-field-type\";\nimport SignatureExampleImage from \"../../../../../../../assets/images/treatment-preview-signature.png\"\nimport { GetMobileMaskByTemp } from \"../../../../../../../constants/mask\";\n\n\nexport default function TreatmentDocumentPreview(props: TreatmentDocumentPreviewProps) {\n\n const { settings } = props;\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"settings\", sectionTNamespace]);\n const treatmentTerm = useTerminology({ type: TerminologyType.Treatment, form: TerminologyForm.Singular });\n const classes = useStyles();\n const accountSettings = useAppSelector(selectAccountSettings);\n const userInfo = useAppSelector(selectUserInfo);\n\n const locale = useAppSelector(state => state.applicationInterface.locale);\n const dateFormat = locale === \"en\" ? \"MM/DD/YYYY\" : \"DD/MM/YYYY\";\n const displayedDate = moment('2023-10-23').format(dateFormat);\n\n function getFormattedPhoneNumber(isoCode: string, body: string): string {\n const country = accountSettings.countries?.find(c => c.iso3 === isoCode);\n\n const dialTemplate = country?.dialTemplate ?? \"\";\n const dialCode = country?.dialCode ?? \"\";\n const maskedPnoneNumberBody = conformToMask(body, GetMobileMaskByTemp(dialTemplate)).conformedValue;\n\n return `+${dialCode} ${maskedPnoneNumberBody}`;\n }\n\n function mapDynamicFieldsToComponents(): JSX.Element[] {\n return settings.fieldSettings\n .filter(fs => fs.field !== null)\n .sort((fs1, fs2) => fs1.field!.order - fs2.field!.order)\n .map(fs => (\n <span\n className={classes.dynamicFieldValueLabel}\n style={getBoolStyle(fs.isEnabled)}\n >\n {`${t(\"Here your\")} ${t(fs.field!.name, { ns: sectionTNamespace }).toLowerCase()} ${(t(\"will be displayed.\"))}`}\n </span>\n ));\n }\n\n function getPageClass(): string {\n switch (settings.documentSize) {\n // https://clearmechanic.atlassian.net/browse/CR-2437?focusedCommentId=151047\n // case TreatmentDocumentSize.HalfLetter:\n // return classes.halfLetterPage;\n case TreatmentDocumentSize.Letter:\n return classes.letterPage;\n case TreatmentDocumentSize.Legal:\n return classes.legalPage;\n default:\n return \"\";\n }\n }\n\n function getDividerClass(): string {\n switch (settings.documentSize) {\n // https://clearmechanic.atlassian.net/browse/CR-2437?focusedCommentId=151047\n // case TreatmentDocumentSize.HalfLetter:\n // return classes.halfLetterPage;\n case TreatmentDocumentSize.Letter:\n return classes.dividerLetter;\n case TreatmentDocumentSize.Legal:\n return classes.dividerLegal;\n default:\n return \"\";\n }\n }\n\n function getStyle(fieldType: StaticTreatmentDocumentFieldType): React.CSSProperties {\n const isEnabled = settings.fieldSettings.find(fs => fs.staticTreatmentDocumentFieldType === fieldType)?.isEnabled ?? true;\n\n return isEnabled\n ? { visibility: \"visible\" }\n : { display: \"none\" }\n }\n\n function getBoolStyle(isEnabled: boolean): React.CSSProperties {\n\n return isEnabled\n ? { visibility: \"visible\" }\n : { display: \"none\" }\n }\n\n const Header = () =>\n <div className={classes.pageHeader}>\n <div className={classes.headerSpecialistRow}>\n <div className={classes.logoSpecialistBlock}>\n <img\n className={classes.logo}\n src={settings.logoUrl ?? undefined}\n style={{\n ...getBoolStyle(settings.logoIsEnabled && (settings.logoUrl !== null))\n }}\n />\n\n <div className={classes.specialistInfoBlock}>\n <div className={classes.flexColumn} style={getStyle(StaticTreatmentDocumentFieldType.SpecialistFullName)}>\n <span className={classes.specialistNameLabel}>\n {userInfo.fullName}\n </span>\n <span className={classes.dynamicFieldValueLabel}>\n {t(settings.specialistJobPositionName)}\n </span>\n </div>\n\n {mapDynamicFieldsToComponents()}\n </div>\n </div>\n\n\n <div style={getStyle(StaticTreatmentDocumentFieldType.AppointmentDate)}>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Date\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {displayedDate}\n </span>\n </div>\n </div>\n\n <div className={classes.flexDualColumn}>\n <div className={classes.dualLeftColumn}>\n <div style={getStyle(StaticTreatmentDocumentFieldType.PatientFullName)}>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Patient\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {t(\"John Doe\")}\n </span>\n </div>\n </div>\n\n <div className={`${classes.dualRightColumn} ${classes.patientInfoBlock}`}>\n <div style={getStyle(StaticTreatmentDocumentFieldType.PatientAge)}>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Age\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {t(\"31 years old\")}\n </span>\n </div>\n\n <div style={getStyle(StaticTreatmentDocumentFieldType.PatientGender)}>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Gender\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {t(\"Male\")}\n </span>\n </div>\n </div>\n </div>\n </div>\n\n const Footer = () =>\n <div className={classes.pageFooter}>\n <div className={classes.signatureContainer} style={getStyle(StaticTreatmentDocumentFieldType.SpecialistSign)}>\n <img src={SignatureExampleImage} style={{ width: \"4.29cm\" }} />\n <hr className={`${classes.dividerCommon} ${classes.dividerSignature}`} />\n <span className={classes.staticFieldValueLabel}>\n {t(\"Signature\")}\n </span>\n </div>\n\n <div className={classes.flexRow} style={getStyle(StaticTreatmentDocumentFieldType.SpecialistPhoneNumber)}>\n <div>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Appointments\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {getFormattedPhoneNumber(settings.accountPhoneNumberIso, settings.accountPhoneNumberBody)}\n </span>\n </div>\n\n <div>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Mobile\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {getFormattedPhoneNumber(settings.specialistPhoneNumberIso, settings.specialistPhoneNumberBody)}\n </span>\n </div>\n\n </div>\n\n <div className={classes.flexColumn}>\n <span className={classes.staticFieldValueLabel}>\n {settings.accountAddress}\n </span>\n </div>\n </div>\n\n return (\n <div className={classes.previewContainer}>\n <div className={`${classes.commonPage} ${getPageClass()}`}>\n\n <div className={classes.pageHeaderWithContent}>\n <Header />\n\n <hr className={`${classes.dividerCommon} ${classes.dividerHeader} ${getDividerClass()}`} />\n\n <div className={classes.pageContent}>\n <div className={classes.flexDualColumn}>\n <div className={classes.dualLeftColumn}>\n <div style={getStyle(StaticTreatmentDocumentFieldType.Diagnosis)}>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Diagnosis\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {t(\"Here the diagnosis that you prescribe in the patient evolution note will be displayed.\")}\n </span>\n </div>\n </div>\n <div className={classes.dualRightColumn}>\n <span className={classes.dynamicFieldValueLabel} style={getStyle(StaticTreatmentDocumentFieldType.VitalSigns)}>\n {t(\"Here the patient vital signs that you registered in the patient evolution note will be displayed.\")}\n </span>\n </div>\n </div>\n\n <div className={classes.flexColumn} style={getStyle(StaticTreatmentDocumentFieldType.Treatment)}>\n <span className={classes.staticFieldNameLabel}>\n {`${treatmentTerm}: `}\n </span>\n\n <span className={classes.staticFieldValueLabel}>\n {`${t(\"Here the\")} ${treatmentTerm} ${t(\"that you prescribe in the patient evolution note will be displayed.\")}`}\n </span>\n </div>\n\n <div className={classes.flexColumn} style={{ top: \"16.5cm\", left: \"1cm\" }}>\n <span className={classes.staticFieldNameLabel}>\n {`${t(\"Additional specialist instructions\")}: `}\n </span>\n <span className={classes.staticFieldValueLabel}>\n {t(\"Here the additional specialist instructions that you prescribe in the patient evolution note will be displayed.\")}\n </span>\n </div>\n </div>\n\n </div>\n\n <Footer />\n\n </div>\n </div>\n );\n}","import { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport { TreatmentDocumentConfigurationModalProps } from \"./props\";\nimport React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport useStyles from \"./css\";\nimport { CameraIcon, InfoIcon, PlusIcon, TrashIcon } from \"../../../../../../assets/icons\";\nimport IconTooltip from \"../../../../../common/IconTooltip\";\nimport SwitchWithLabel from \"../../../../../common/SwitchWithLabel\";\nimport { AccountService } from \"../../../../../../api/account-service\";\nimport { TreatmentDocumentFieldSettingsModel } from \"../../../../../../models/treatment-document-field-settings-model\";\nimport { TreatmentDocumentSize } from \"../../../../../../models/enums/treatment-document-size\";\nimport { SelectItem } from \"../../../../../common/Select\";\nimport { Color } from \"../../../../../../constants/colors\";\nimport { TerminologyType } from \"../../../../../../models/enums/terminology-type\";\nimport useTerminology from \"../../../../../../hooks/useTerminology\";\nimport { TerminologyForm } from \"../../../../../../models/enums/terminology-form\";\nimport SelectWithLabel from \"../../../../../common/SelectWithLabel\";\nimport DropImage from \"../../../../../common/DropImage\";\nimport DropImageRefs from \"../../../../../common/DropImage/refs\";\nimport Input from \"../../../../../common/Input\";\nimport { StaticTreatmentDocumentFieldType } from \"../../../../../../models/enums/static-treatment-document-field-type\";\nimport { TreatmentDocumentFieldSetting } from \"../../../../../../models/treatment-document-field-setting\";\nimport stringify from \"safe-stable-stringify\";\nimport Cloner from \"../../../../../../utils/cloner\";\nimport ConfirmDeleteModal from \"../../../../../common/ConfirmDeleteModal\";\nimport ConfirmActionModal from \"../../../../../common/ConfirmActionModal\";\nimport TreatmentDocumentPreview from \"./TreatmentDocumentPreview\";\n\n\nconst TreatmentDocumentConfigurationModal = (props: TreatmentDocumentConfigurationModalProps) => {\n\n const { isOpen, closeModal, vitalSignsSectionName } = props;\n\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"settings\", sectionTNamespace]);\n const treatmentTerm = useTerminology({ type: TerminologyType.Treatment, form: TerminologyForm.Singular });\n const classes = useStyles();\n\n const documentSizeSelectItems: SelectItem[] = [\n // https://clearmechanic.atlassian.net/browse/CR-2437?focusedCommentId=151047\n // { key: TreatmentDocumentSize.HalfLetter, value: t(\"Half-letter (5.5 x 8.5 inches)\") },\n { key: TreatmentDocumentSize.Letter, value: t(\"Letter (8.5 x 11 inches)\") },\n { key: TreatmentDocumentSize.Legal, value: t(\"Legal (8.5 x 14 inches)\") },\n ];\n const validSignImageExtensions = [\"jpg\", \"jpeg\", \"png\"];\n const maxSignImageSize: number = 800 * 1024; //800 kb\n\n const dropImageRef = useRef<DropImageRefs>(null);\n\n const [settings, setSettings] = useState<TreatmentDocumentFieldSettingsModel>(new TreatmentDocumentFieldSettingsModel());\n const [settingsInitialStateToCompare, setSettingsInitialStateToCompare] = useState<TreatmentDocumentFieldSettingsModel>(new TreatmentDocumentFieldSettingsModel());\n\n const [closeModalConfirmationModalIsOpen, setCloseModalConfirmationModalIsOpen] = useState<boolean>(false);\n const [deleteConfirmationModalIsOpen, setDeleteConfirmationModalIsOpen] = useState<boolean>(false);\n\n useEffect(() => {\n if (!isOpen)\n return;\n\n async function innerLoadData() {\n await loadData();\n }\n\n innerLoadData();\n }, [isOpen]);\n\n\n async function loadData(): Promise<void> {\n const response = await AccountService.getTreatmentDocumentFieldSettings();\n setSettings(response);\n setSettingsInitialStateToCompare(Cloner.deepCopy<TreatmentDocumentFieldSettingsModel>(response));\n }\n\n async function handleSave(): Promise<void> {\n await AccountService.updateTreatmentDocumentFieldSettings(settings);\n closeAndResetModal();\n }\n\n function tryCloseModal(): void {\n if (stringify(settings) === stringify(settingsInitialStateToCompare)) {\n closeAndResetModal();\n }\n else {\n setCloseModalConfirmationModalIsOpen(true);\n }\n }\n\n function closeAndResetModal(): void {\n setCloseModalConfirmationModalIsOpen(false);\n closeModal();\n }\n\n function handleChangeDocumentSize(event: React.ChangeEvent<{ value: TreatmentDocumentSize }>) {\n setSettings({ ...settings, documentSize: event.target.value });\n }\n\n function handleLogoSwitchChanged(isEnabled: boolean) {\n setSettings({ ...settings, logoIsEnabled: isEnabled });\n }\n\n function handleLogoUpload(files: FileList) {\n const file = files.item(0);\n if (!file)\n return;\n const fileIsInvalid = validateLogoImage(file);\n if (!fileIsInvalid)\n return;\n\n setSettings({ ...settings, logoUrl: URL.createObjectURL(file), logoFile: file });\n }\n\n function openFileDialog() {\n dropImageRef?.current?.openFileExplorerDialog();\n }\n\n function deleteLogoFile() {\n setSettings((prev) => ({ ...prev, logoUrl: null, logoFile: null, shouldRemoveLogo: true }));\n setDeleteConfirmationModalIsOpen(false);\n }\n\n function validateLogoImage(file: File) {\n if (validSignImageExtensions.indexOf(file.name.split('.').pop()!) === -1) {\n return false;\n }\n return file.size < maxSignImageSize;\n }\n\n function getStaticFieldIsEnabled(fieldType: StaticTreatmentDocumentFieldType): boolean {\n return settings.fieldSettings.find(fs => fs.staticTreatmentDocumentFieldType === fieldType)?.isEnabled ?? true;\n }\n\n function setStaticFieldIsEnabled(isEnabled: boolean, fieldType: StaticTreatmentDocumentFieldType): void {\n let newSettings = { ...settings };\n const index = settings.fieldSettings.findIndex(fs => fs.staticTreatmentDocumentFieldType === fieldType);\n let fieldSetting = { ...settings.fieldSettings[index] } as TreatmentDocumentFieldSetting;\n fieldSetting.isEnabled = isEnabled;\n newSettings.fieldSettings[index] = fieldSetting;\n setSettings(newSettings);\n }\n\n function getDynamicFieldIsEnabled(fieldSettingId: string): boolean {\n return settings.fieldSettings.find(fs => fs.id === fieldSettingId)?.isEnabled ?? true;\n }\n\n function setDynamicFieldIsEnabled(isEnabled: boolean, fieldSettingId: string): void {\n let newSettings = { ...settings };\n const index = settings.fieldSettings.findIndex(fs => fs.id === fieldSettingId);\n let fieldSetting = { ...settings.fieldSettings[index] } as TreatmentDocumentFieldSetting;\n fieldSetting.isEnabled = isEnabled;\n newSettings.fieldSettings[index] = fieldSetting;\n setSettings(newSettings);\n }\n\n function mapDynamicFieldSettingsToComponents(): JSX.Element[] {\n return settings.fieldSettings\n .filter(fs => fs.field !== null)\n .sort((fs1, fs2) => fs1.field!.order - fs2.field!.order)\n .map(fs => (<div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getDynamicFieldIsEnabled(fs.id)}\n setValue={(v) => setDynamicFieldIsEnabled(v, fs.id)}\n label={t(fs.field!.name, { ns: sectionTNamespace })}\n />\n </div>))\n }\n\n\n\n return <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={tryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n <Fade in={isOpen}>\n <div className={classes.paper}>\n <div className={classes.headerContainer}>\n <div className={classes.titleContainer}>\n <Typography className={classes.modalNameLabel}>\n {`${t(\"Customize\")} ${treatmentTerm.toLowerCase()}`}\n </Typography>\n <Typography className={classes.requiredFieldLabel}>\n {t(\"Required fields\")} <span className={classes.asterix}> *</span>\n </Typography>\n </div>\n <div className={classes.modalManagementButtonsContainer}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={tryCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.continueButton}`}\n disabled={stringify(settings) === stringify(settingsInitialStateToCompare)}\n classes={{ disabled: classes.saveDisabled }}\n onClick={handleSave}\n >\n {t(\"Save\")}\n </Button>\n </div>\n </div>\n <div className={classes.mainContentContainer}>\n <div className={classes.settingsContainer}>\n <div className={classes.printDetailsLabelContainer}>\n <Typography className={classes.violetHeaderLabel}>\n {t(\"Print details\")}\n </Typography>\n </div>\n <div className={classes.scrollableSettingContainer}>\n <SelectWithLabel\n key={\"documentSizeSelect\"}\n rootStyle={{ color: Color.clear1 + \" !important\", paddingBottom: 22 }}\n width={183}\n value={settings.documentSize}\n onChange={handleChangeDocumentSize}\n colorArrowIcon={Color.gray5}\n items={documentSizeSelectItems}\n label={t(\"Size\")} />\n <SwitchWithLabel\n value={settings.logoIsEnabled}\n setValue={handleLogoSwitchChanged}\n label={t(\"Logo\")}\n />\n <div className={`${classes.logoDisableableSection} ${settings.logoIsEnabled ? \"\" : classes.disabled}`}>\n <div className={classes.logoConfigurationSection}>\n <div className={classes.logoConfigurationLeftSection}>\n <Typography className={classes.columnNameLabel}>\n {t(\"Logo\") + \" *\"}\n </Typography>\n <DropImage\n ref={dropImageRef}\n classDivUploadImage={settings.logoUrl ? classes.logo : classes.logoEmpty}\n onChange={handleLogoUpload}\n imageURL={settings.logoUrl ?? undefined}\n disableBlob={true}\n componentShowEmpty={<div className={classes.emptyLogoStubContainer}>\n <div>\n <PlusIcon style={{ color: Color.clear1 }} />\n </div>\n <div className={classes.addPhotoLabel}>\n {t(\"Add photo\")}\n </div>\n <div className={classes.addPhotoMinSizeLabel}>\n {t(\"Min. size\") + \": 660px x 450px\"}\n </div>\n </div>} />\n {settings.logoUrl\n ? <div className={classes.logoControls}>\n <CameraIcon\n className={classes.iconCamera}\n onClick={openFileDialog}\n />\n <TrashIcon\n style={{ color: \"#919CA5\" }}\n className={classes.iconTrash}\n onClick={() => setDeleteConfirmationModalIsOpen(true)}\n />\n </div>\n : <div className={classes.logoControlsEmptyStub} />\n }\n </div>\n </div>\n <div className={classes.logoNotesContainer}>\n <Typography className={classes.notesBold}>\n {t(\"Notes\") + \":\"}\n </Typography>\n <Typography className={classes.notes}>\n {`${t(\"The logo will be displayed as part of the\")} ${treatmentTerm.toLowerCase()}.`}\n </Typography>\n <Typography className={classes.notes}>\n {t(\"Allowed formats for the image:\")}\n <span className={classes.notesBold}>{\" \" + t(\".png or .jpg\")}</span>\n </Typography>\n </div>\n </div>\n <div className={classes.fieldSettingsContainer}>\n <div className={classes.fieldSettingsRow}>\n <Typography className={`${classes.columnNameLabel} ${classes.fieldSettingsGridItem}`}>\n {t(\"Professional information\") + \" *\"}\n </Typography>\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.SpecialistFullName)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.SpecialistFullName)}\n label={t(\"Specialist\")}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.SpecialistPhoneNumber)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.SpecialistPhoneNumber)}\n label={t(\"Mobile\")}\n />\n </div>\n {mapDynamicFieldSettingsToComponents()}\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.AppointmentDate)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.AppointmentDate)}\n label={t(\"Date\")}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.PatientFullName)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.PatientFullName)}\n label={t(\"Patient\")}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.PatientAge)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.PatientAge)}\n label={t(\"Age\")}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.PatientGender)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.PatientGender)}\n label={t(\"Gender\")}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.VitalSigns)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.VitalSigns)}\n label={vitalSignsSectionName}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.Diagnosis)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.Diagnosis)}\n label={t(\"Diagnosis\")}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.Treatment)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.Treatment)}\n label={treatmentTerm}\n />\n </div>\n <div className={classes.fieldSettingsRow}>\n <SwitchWithLabel\n className={classes.fieldSettingsGridItem}\n value={getStaticFieldIsEnabled(StaticTreatmentDocumentFieldType.SpecialistSign)}\n setValue={(v) => setStaticFieldIsEnabled(v, StaticTreatmentDocumentFieldType.SpecialistSign)}\n label={t(\"Sign\")}\n />\n </div>\n </div>\n </div>\n </div>\n <div className={classes.previewContainer}>\n <Typography className={`${classes.violetHeaderLabel} ${classes.previewSectionLabel}`}>\n {t(\"Preview\")}\n </Typography>\n <TreatmentDocumentPreview settings={settings} />\n </div>\n </div>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<Typography className={classes.closeModalTitleText}>\n {`${t(\"Cancel_treatment_customization_modal\")} ${treatmentTerm.toLowerCase()}${t(\" customization?\")}`}\n </Typography>}\n open={closeModalConfirmationModalIsOpen}\n onClose={() => setCloseModalConfirmationModalIsOpen(false)}\n onConfirm={closeAndResetModal}\n confirmButtonText={t(\"Yes, cancel\")}\n />\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteConfirmationModalIsOpen}\n item={null}\n componentInfo={<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete this image?\")}\n </Typography>\n </div>}\n onClose={() => setDeleteConfirmationModalIsOpen(false)}\n onDelete={deleteLogoFile}\n textButtonConfirm={t(\"Delete\")}\n />\n </div>\n </Fade>\n </Modal>\n};\n\nexport default TreatmentDocumentConfigurationModal;","import React, { useEffect, useState } from \"react\";\nimport { Trans, useTranslation } from \"react-i18next\";\n\nimport { EvolutionNotesProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport Section from \"../Section\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport { AccountService } from \"../../../../../api/account-service\";\nimport { Terminology } from \"../../../../../models/terminology\";\nimport { setAccountSettings } from \"../../../../../redux/account-settings-slice\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { SectionGearIcon } from \"../../../../../assets/icons\";\nimport TreatmentDocumentConfigurationModal from \"./TreatmentDocumentConfigurationModal\";\nimport { SectionUpdateRequest } from \"../../../../../models/section-update-request\";\n\n\nconst EvolutionNotes = (props: EvolutionNotesProps) => {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const treatmentTerm = useTerminology({ type: TerminologyType.Treatment, form: TerminologyForm.Singular });\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const { } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const [vitalSignsSection, setVitalSignsSection] = useState<SectionModel | null>(null);\n const [userTreatmentSection, setUserTreatmentSection] = useState<SectionModel>(new SectionModel());\n const [openTreatmentPdfConfigurationModal, setOpenTreatmentPdfConfigurationModal] = useState<boolean>(false);\n\n const userTreatmentStaticFields = [new SectionFieldModel({\n id: \"specialist\",\n name: t(\"default_field_name_Specialist\", { ns: sectionTNamespace }),\n order: -1,\n type: SectionFieldType.Text,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"mobile\",\n name: t(\"default_field_name_Mobile\", { ns: sectionTNamespace }),\n order: 0,\n type: SectionFieldType.PhoneNumber,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n })];\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n dispatch(navbarActions.setShowLoader(false));\n }\n fetchData();\n }, []);\n\n async function loadData () {\n const vitalSignsSections = await SettingsPatientFormsService.getAccountSettingsTabSections(SectionType.VitalSigns);\n\n const userTreatmentSections = await SettingsPatientFormsService.getAccountSettingsTabSections(SectionType.UserTreatment);\n let userTreatmentSection = userTreatmentSections[0];\n userTreatmentSection = { ...userTreatmentSection, name: treatmentTerm };\n userTreatmentSection.fields.unshift(...userTreatmentStaticFields);\n\n setVitalSignsSection(vitalSignsSections[0]);\n setUserTreatmentSection(userTreatmentSection);\n };\n\n async function handleChangeTreatmentTerminology (section: SectionModel) {\n const newTerminology = new Terminology({\n terminologyType: TerminologyType.Treatment,\n singularForm: section.name,\n pluralForm: section.name\n });\n await AccountService.updateAccountTerminology(newTerminology);\n const newTerms = accountSettings.terminologies.map(t => t.terminologyType === TerminologyType.Treatment\n ? newTerminology\n : t);\n dispatch(setAccountSettings({ ...accountSettings, terminologies: newTerms }));\n }\n\n async function handleVitalSignsSectionChange (section: SectionModel) {\n await SettingsPatientFormsService.updateSection(new SectionUpdateRequest({\n id: section.id,\n type: section.type,\n newName: section.name,\n newOrder: section.order,\n previousOrder: null\n }))\n .then(() => {\n setVitalSignsSection(section)\n })\n };\n\n return <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Evolution notes\")}\n </Typography>\n </div>\n {vitalSignsSection &&\n <Section\n key={vitalSignsSection.id}\n sections={[vitalSignsSection]}\n section={vitalSignsSection}\n setSection={(updatedSection) => setVitalSignsSection(updatedSection)}\n onEdit={async () => { await handleVitalSignsSectionChange(vitalSignsSection) }}\n />\n }\n <Section\n key={userTreatmentSection.id}\n sections={[userTreatmentSection]}\n section={userTreatmentSection}\n customNote={\n <div className={classes.treatmentNoteBox}>\n <Trans \n className={classes.treatmentNoteLabel}\n i18nKey=\"The Treatment contains the indications for medications or care prescribed for the patient. It also includes information about the specialist and the patient.\"\n t={t}\n values={{ \"treatment\": treatmentTerm }} />\n </div>}\n customHeaderButton={<Button\n onClick={() => setOpenTreatmentPdfConfigurationModal(true)}\n className={classes.headerButton}\n >\n <SectionGearIcon />\n </Button>}\n setSection={(updatedSection) => setUserTreatmentSection(updatedSection)}\n onEdit={async () => { await handleChangeTreatmentTerminology(userTreatmentSection) }}\n />\n {vitalSignsSection && (\n <TreatmentDocumentConfigurationModal\n isOpen={openTreatmentPdfConfigurationModal}\n closeModal={() => setOpenTreatmentPdfConfigurationModal(false)}\n vitalSignsSectionName={vitalSignsSection.name}\n />\n )}\n </>\n};\n\nexport default EvolutionNotes;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Clear } from \"@material-ui/icons\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n width: \"100%\",\n gap: 20\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n newButton: {\n marginLeft: \"auto\",\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n footerContainer: {\n paddingTop: 10,\n paddingBottom: 80\n },\n footerNoteLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12,\n lineHeight: \"14px\",\n color: Color.gray5,\n },\n footerNoteLabelBold: {\n fontWeight: 700,\n },\n footerNoteLabelLink: {\n textDecoration: \"underline\",\n fontWeight: 700,\n color: Color.clear1,\n \"&:hover\": {\n color: Color.blue\n }\n },\n previewButton: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n border: \"1px solid \" + Color.clear1,\n color: Color.clear1,\n }\n}));\n\nexport default useStyles;","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { Link } from \"react-router-dom\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\n\nimport { PatientFormProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { SectionNewIcon } from \"../../../../../assets/icons\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport SectionNewModal from \"../SectionNewModal\";\nimport SectionList from \"../SectionList\";\nimport SectionListRefs from \"../SectionList/section-list-refs\";\nimport { Url } from \"../../../../../constants/url\";\nimport Section from \"../Section\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport { SectionFieldItemModel } from \"../../../../../models/section-field-item-model\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default function PatientForm(props: PatientFormProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const currentTabSectionType = SectionType.PatientForm;\n const accountSettings = useAppSelector(selectAccountSettings)\n\n const [sections, setSections] = useState<SectionModel[]>([]);\n const [newSectionModalIsOpen, setNewSectionModalIsOpen] = useState<boolean>(false);\n\n const sectionListRef = useRef<SectionListRefs>(null);\n\n const pacientBasicInfoSectionStaticModel = new SectionModel({\n id: \"patientBasicInfoId\",\n name: t(\"default_section_name_Basic patient information\", { ns: sectionTNamespace }),\n order: 0,\n type: SectionType.PatientForm,\n fields: [\n new SectionFieldModel({\n id: \"firstName\",\n name: t(\"default_field_name_First name(s)\", { ns: sectionTNamespace }),\n order: 1,\n type: SectionFieldType.Text,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"lastName\",\n name: t(\"default_field_name_Last name\", { ns: sectionTNamespace }),\n order: 2,\n type: SectionFieldType.Text,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"mobile\",\n name: t(\"default_field_name_Mobile\", { ns: sectionTNamespace }),\n order: 3,\n type: SectionFieldType.PhoneNumber,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"email\",\n name: t(\"default_field_name_Email\", { ns: sectionTNamespace }),\n order: 4,\n type: SectionFieldType.Email,\n isRequired: false,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"gender\",\n name: t(\"default_field_name_Gender\", { ns: sectionTNamespace }),\n order: 5,\n type: SectionFieldType.Radio,\n isRequired: false,\n isAdditionalTextareaEnabled: true,\n isEditable: false,\n isRemovable: false,\n items: [\n new SectionFieldItemModel({\n id: \"male\",\n name: t(\"default_field_item_name_Male\", { ns: sectionTNamespace }),\n order: 1\n }),\n new SectionFieldItemModel({\n id: \"Female\",\n name: t(\"default_field_item_name_Female\", { ns: sectionTNamespace }),\n order: 2\n }),\n new SectionFieldItemModel({\n id: \"PreferNotToSay\",\n name: t(\"default_field_item_name_PreferNotToSay\", { ns: sectionTNamespace }),\n order: 3\n }),\n new SectionFieldItemModel({\n id: \"Custom\",\n name: t(\"default_field_item_name_Custom\", { ns: sectionTNamespace }),\n order: 4\n }),\n ]\n }),\n new SectionFieldModel({\n id: \"dateOfBirth\",\n name: t(\"default_field_name_Date of Birth\", { ns: sectionTNamespace }),\n order: 6,\n type: SectionFieldType.Date,\n isRequired: false,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n ],\n isEditable: false,\n isRemovable: false\n });\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n dispatch(navbarActions.setShowLoader(false));\n }\n fetchData();\n }, []);\n\n const handleCreateSection = async (name: string) => {\n await sectionListRef?.current?.createSection(name);\n }\n\n const loadData = async () => {\n const sectionsData =\n await SettingsPatientFormsService.getAccountSettingsTabSections(currentTabSectionType);\n setSections(sectionsData);\n };\n\n const handleOpenPreview = () => {\n window.open(`https://sitiodereservas.somosclear.com/${accountSettings.siteForFinalCustomersSmbName}/patient-form?previewStep=first`, '_blank', 'noopener,noreferrer');\n }\n\n return <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Patient form\")}\n </Typography>\n <Button\n className={classes.previewButton}\n onClick={handleOpenPreview}\n >\n {t(\"Preview\")}\n </Button>\n <ButtonWithSpinner\n margin={\"0px 0px 0px auto\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New section\")}\n innerIcon={<SectionNewIcon />}\n onClick={() => setNewSectionModalIsOpen(true)}\n />\n </div>\n <Section\n key={\"patientBasicInfo\"}\n section={pacientBasicInfoSectionStaticModel}\n />\n <SectionList\n ref={sectionListRef}\n sectionType={currentTabSectionType}\n sections={sections}\n setSections={setSections}\n />\n <div className={classes.footerContainer}>\n <Typography className={classes.footerNoteLabel}>\n <span className={classes.footerNoteLabelBold}>\n {t(\"Note\") + \": \"}\n </span>\n {t(\"The customization of the Clinical History to be displayed in the form is done in the\") + \" \"}\n <Link\n to={Url.Settings.ClinicHistory}\n className={classes.footerNoteLabelLink}\n >\n {t(\"Clinical History\")}\n </Link>\n {\" \" + t(\"tab of the Settings screen\") + \".\"}\n </Typography>\n </div>\n <SectionNewModal\n sections={sections}\n isOpen={newSectionModalIsOpen}\n setOpen={setNewSectionModalIsOpen}\n onCreate={handleCreateSection}\n />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n commissionsHeaderBlock: {\n display: \"flex\",\n padding: \"12px 24px\",\n color: theme.colors.grey7,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n backgroundColor: \"white\",\n marginBottom: 32,\n alignItems: \"center\"\n },\n actionButton: {\n \"&.MuiButton-root\": {\n minWidth: 0,\n marginLeft: 10\n },\n },\n title: {\n marginRight: 10\n },\n iconTooltipRoot: {\n \"&>div\": {\n maxWidth: 220\n }\n },\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n})\n);\n\nexport default useStyles;","import {UserCommissions} from \"./user-commissions\";\n\nexport class UsersCommissionsResponse {\n usersCommissions: UserCommissions[] | null;\n totalUserCommissions: number | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.usersCommissions = x.usersCommissions;\n this.totalUserCommissions = x.totalUserCommissions;\n } else {\n this.usersCommissions = null;\n this.totalUserCommissions = null;\n }\n }\n}","import { UserCommissionInfo } from \"./user-commission-info\";\n\nexport class UserCommissionEntity {\n userId: string;\n userCommission: UserCommissionInfo;\n accountId?: string | null;\n\n constructor(\n userId: string,\n userCommission: UserCommissionInfo,\n accountId?: string | null,\n )\n {\n this.userId = userId;\n this.userCommission = userCommission;\n this.accountId = accountId;\n }\n}","import { ApiClient } from \"./api-client\";\n\nimport {UsersCommissionsResponse} from \"../models/users-commissions-response\";\nimport {UserCommissionInfo} from \"../models/user-commission-info\";\nimport {UserCommissionEntity} from \"../models/user-commission-entity\";\nimport {UserEntity} from \"../models/user-entity\";\n\nexport class CommissionService {\n private static baseUrl: string = \"/commission\";\n\n static getUsersCommissions(\n page: number,\n pageSize: number,\n establishmentAccountId?: string,\n order?: string,\n orderBy?: string\n ): Promise<UsersCommissionsResponse> {\n let urlEndpoint = `${this.baseUrl}/getbyaccount?page=${page}&pageSize=${pageSize}`;\n if (order && orderBy) {\n urlEndpoint += `&order=${order}&orderBy=${orderBy}`;\n }\n if (establishmentAccountId) {\n urlEndpoint += `&accountId=${establishmentAccountId}`;\n }\n\n return ApiClient.get(urlEndpoint).then((data) => new UsersCommissionsResponse(data));\n }\n\n static getUserCommissionsById(userId: string, establishmentAccountId?: string): Promise<UserCommissionInfo> {\n let urlEndpoint = `${this.baseUrl}/get?userId=${userId}`;\n if (establishmentAccountId) {\n urlEndpoint += `&accountId=${establishmentAccountId}`;\n }\n return ApiClient.get(urlEndpoint).then(\n (data) => new UserCommissionInfo(data.userCommission));\n }\n\n static updateUserCommission(userId: string, userCommission: UserCommissionInfo, establishmentAccountId?: string): Promise<UserCommissionInfo> {\n const user = new UserCommissionEntity(userId, userCommission,establishmentAccountId);\n const request = { accountId: establishmentAccountId, userId: userId, user: user}\n return ApiClient.put(`${this.baseUrl}/update`, user).then(\n (data) => data.userCommission\n );\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n pageContent: {\n \"&>nav\": {\n marginTop: 120\n }\n },\n usersServices: {\n display: \"flex\",\n flexWrap: \"wrap\",\n gap: 16,\n overflowY: \"auto\",\n maxHeight: 333\n },\n userServices: {\n width: \"calc(33% - 8px)\",\n backgroundColor: \"white\",\n padding: 16,\n borderRadius: 12,\n fontFamily: \"Inter, sans-serif\",\n },\n userName: {\n color: theme.colors.clearMain,\n fontWeight: 700,\n fontSize: \"18px\"\n },\n servicesCount: {\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n marginTop: 20\n },\n buttons: {\n display: \"flex\",\n gap: 8,\n marginTop: 20\n },\n button: {\n minWidth: 120,\n height: 32,\n borderRadius: 51,\n padding: \"8.5px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: \"#F6F6F6\",\n color: theme.colors.grey5,\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"33px\",\n marginBottom: \"33px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: Color.gray4\n },\n },\n paper: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 812,\n minHeight: 500,\n maxHeight: 500,\n overflow: \"auto\"\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n padding: \"24px 40px 24px 40px\"\n },\n modalTitle: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 5,\n width: \"100%\",\n \"& svg path\": {\n fill: theme.colors.grey5\n }\n },\n modalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n gap: 16\n },\n goBack: {\n width: 120,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n width: 164,\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n \"&.Mui-disabled\": {\n background: \"rgba(54, 206, 145, 0.5)\",\n color: \"white\"\n }\n },\n button: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n content: {\n height: \"100%\",\n padding: \"24px 40px\",\n borderRadius: \"10px\",\n },\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n divider: {\n backgroundColor: \"rgba(201, 205, 211, 0.5) !important\",\n marginTop: \"12px !important\",\n marginBottom: \"18px !important\"\n },\n switchBox: {\n display: \"flex\",\n marginLeft: 12,\n \"&>label\": {\n marginBottom: 0\n }\n },\n tooltip: {\n \"&>div[role=tooltip]\": {\n marginTop: -22\n }\n },\n sectionRow: {\n display: \"flex\",\n alignItems: \"center\"\n },\n sectionLabel: {\n color: theme.colors.grey4,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n marginLeft: 10\n },\n radios: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n gap: 10,\n marginBottom: 20\n },\n radio: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n \"&>div:first-child>div\": { // label\n color: theme.colors.grey5,\n opacity: 0.5,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: \"14px\",\n marginRight: 5\n }\n },\n commissionsByServices: {\n display: \"flex\",\n justifyContent: \"space-between\",\n flexWrap: \"wrap\"\n },\n\n commissionByServiceItem: {\n width: \"48%\",\n marginRight: 10,\n height: 85\n },\n commissionByServiceValues: {\n display: \"flex\",\n gap: 10\n },\n serviceName: {\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: 12,\n color: \"#919CA5\",\n marginBottom: 4\n },\n contentHeader: {\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: 12,\n color: \"#919CA5\",\n marginBottom: 4,\n textTransform: \"lowercase\",\n \"&:first-letter\": {\n textTransform: \"capitalize\"\n }\n },\n defaultServices: {\n display: \"flex\",\n flexWrap: \"wrap\",\n gap: 15,\n marginBottom: 30\n },\n defaultServiceItem: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n backgroundColor: \"#F1F1F1\",\n height: 32,\n borderRadius: 51,\n padding: \"0 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontWeight: 700,\n fontSize: 12,\n color: \"#919CA5\",\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n defaultCommissionValues: {\n display: \"flex\",\n gap: 10,\n width: 357\n }\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { CommissionViewProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { useAppSelector } from \"../../../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport useCurrencyValueTemplate from \"../../../../../hooks/useCurrencyValueTemplate\";\nimport { UserCommissionType } from \"../../../../../models/enums/user-commission-type\";\nimport { CommissionType } from \"../../../../../models/enums/commission-type\";\nimport { CommissionByServiceEntity } from \"../../../../../models/commission-by-service-entity\";\nimport InputCurrency from \"../../../../common/InputCurrency\";\nimport Select from \"../../../../common/Select\";\nimport ConfirmationModal from \"../ConfirmationModal\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\n\n\nexport default function CommissionView(props: CommissionViewProps) {\n const { t } = useTranslation(\"settings\");\n const classes = useStyles();\n \n const {\n userCommissionsInfo,\n setUserCommissionsInfo,\n isUserCommissionTypeChangeConfirmed,\n setIsUserCommissionTypeChangeConfirmed\n } = props;\n \n const [isConfirmationModalOpen, setConfirmationModalOpen] = useState<boolean>(false);\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const percentageTemplate = \"{0}%\";\n const getTemplatedCurrencyValue = useCurrencyValueTemplate(accountSettings.currencyTemplate);\n \n const needConfirmUserCommissionTypeChange = () => {\n return userCommissionsInfo.initialUserCommissionType !== userCommissionsInfo.userCommissionType && !isUserCommissionTypeChangeConfirmed;\n }\n \n const getCurrencySign = () => {\n return accountSettings.currencyTemplate.replace(\"{0}\", \"\");\n }\n \n const commissionTypeToDisplayable = (type: CommissionType | null) => {\n if (type === CommissionType.Absolute) {\n return getCurrencySign();\n } else if (type === CommissionType.Percentage) {\n return \"%\";\n }\n return null;\n }\n \n const displayableToCommissionType = (type: string) => {\n if (type === \"%\") {\n return CommissionType.Percentage;\n }\n return CommissionType.Absolute;\n }\n \n const getPercentageValueByAbsolute = (service: CommissionByServiceEntity): number => {\n let newVal = service.commissionValue / service.servicePrice * 100;\n newVal = Math.round((newVal + Number.EPSILON) * 100) / 100;\n return newVal > 100 ? 100 : newVal;\n }\n \n const getAbsoluteValueByPercentage = (service: CommissionByServiceEntity): number => {\n const newVal = service.servicePrice * (service.commissionValue / 100);\n return Math.round((newVal + Number.EPSILON) * 100) / 100;\n }\n \n const getServiceAbsoluteTemplate = (service: CommissionByServiceEntity): string => {\n return accountSettings.currencyTemplate + ` (${percentageTemplate.replace(\"{0}\", getPercentageValueByAbsolute(service) + \"\")})`\n }\n \n const getServicePercentageTemplate = (service: CommissionByServiceEntity): string => {\n return percentageTemplate + ` (${getTemplatedCurrencyValue(getAbsoluteValueByPercentage(service))})`\n }\n \n const displayableCommissionTypes: string[] = [\n commissionTypeToDisplayable(CommissionType.Absolute)!,\n commissionTypeToDisplayable(CommissionType.Percentage)!,\n ];\n \n const setServiceCommissionValue = (service: CommissionByServiceEntity, value: number) => {\n service.commissionValue = value;\n setUserCommissionsInfo({\n ...userCommissionsInfo,\n commissionsByServices: userCommissionsInfo.commissionsByServices\n });\n if (needConfirmUserCommissionTypeChange() && userCommissionsInfo.commissionValue !== value) {\n setConfirmationModalOpen(true);\n }\n }\n \n const setServiceCommissionType = (service: CommissionByServiceEntity, type: string) => {\n service.commissionType = displayableToCommissionType(type);\n if (service.commissionType === CommissionType.Percentage) {\n service.commissionValue = getPercentageValueByAbsolute(service);\n } else if (service.commissionType === CommissionType.Absolute) {\n service.commissionValue = getAbsoluteValueByPercentage(service);\n }\n setUserCommissionsInfo({\n ...userCommissionsInfo,\n commissionsByServices: userCommissionsInfo.commissionsByServices\n });\n if (needConfirmUserCommissionTypeChange() && userCommissionsInfo.commissionType !== service.commissionType) {\n setConfirmationModalOpen(true);\n }\n }\n \n const setCommissionValue = (value: number) => {\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionValue: value });\n if (needConfirmUserCommissionTypeChange()) {\n setConfirmationModalOpen(true);\n }\n }\n \n const setCommissionType = (displayableType: string) => {\n const type = displayableToCommissionType(displayableType);\n if (type === CommissionType.Percentage) {\n let value: number | null = null;\n if (userCommissionsInfo.commissionValue && userCommissionsInfo.commissionValue > 100) {\n value = 100;\n }\n if (value !== null) {\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionType: type, commissionValue: value });\n return;\n }\n }\n setUserCommissionsInfo({ ...userCommissionsInfo, commissionType: type });\n if (needConfirmUserCommissionTypeChange()) {\n setConfirmationModalOpen(true);\n }\n }\n \n const confirmUserCommissionTypeChange = () => {\n setIsUserCommissionTypeChangeConfirmed(true);\n setConfirmationModalOpen(false);\n }\n \n const rejectUserCommissionTypeChange = () => {\n setConfirmationModalOpen(false);\n }\n \n const getTerminology = (form: TerminologyForm): string => {\n const terminology = accountSettings.terminologies.find(t => t.terminologyType === TerminologyType.Commission);\n return (form === TerminologyForm.Plural ? terminology?.pluralForm ?? t('commissions') : terminology?.singularForm ?? t('commission'))!.toLowerCase();\n }\n \n const renderServiceItem = (service: CommissionByServiceEntity) => {\n return <div key={service.serviceId} className={classes.commissionByServiceItem}>\n <div className={classes.serviceName}>{service.serviceName} {getTemplatedCurrencyValue(service.servicePrice)}</div>\n <div className={classes.commissionByServiceValues}>\n <InputCurrency\n value={service.commissionValue}\n setValue={(value: number) => setServiceCommissionValue(service, value)}\n valueTemplate={service.commissionType === CommissionType.Absolute\n ? getServiceAbsoluteTemplate(service)\n : getServicePercentageTemplate(service)}\n isZeroAllowed={true}\n isValid={() => {\n return true;\n }}\n maxValue={service.commissionType === CommissionType.Percentage ? 100 : undefined}\n />\n <Select\n key={service.serviceId}\n width={100}\n value={commissionTypeToDisplayable(service.commissionType)}\n onChange={(event) => setServiceCommissionType(service, event.target.value)}\n colorArrowIcon={\"#5C6477\"}\n items={displayableCommissionTypes}/>\n </div>\n </div>\n }\n \n const defaultCommission = useTerminology({ type: TerminologyType.Commission, template: t(\"Default commission\") });\n \n return (\n <>\n {userCommissionsInfo.userCommissionType === UserCommissionType.ByService &&\n <>\n <div className={classes.commissionsByServices}>\n {userCommissionsInfo.commissionsByServices.map(renderServiceItem)}\n </div>\n </>\n }\n {userCommissionsInfo.userCommissionType === UserCommissionType.Default &&\n <>\n <div className={classes.contentHeader}>\n {defaultCommission}\n <span className={classes.dot}>*</span>\n </div>\n <div className={classes.defaultCommissionValues}>\n <InputCurrency\n value={userCommissionsInfo.commissionValue}\n setValue={(value: number) => setCommissionValue(value)}\n valueTemplate={userCommissionsInfo.commissionType === CommissionType.Absolute\n ? accountSettings.currencyTemplate\n : userCommissionsInfo.commissionType === CommissionType.Percentage ? percentageTemplate : \"{0}\"}\n placeholder={\"--\"}\n isZeroAllowed={true}\n isValid={() => {\n return true;\n }}\n maxValue={userCommissionsInfo.commissionType === CommissionType.Percentage ? 100 : undefined}\n />\n <Select\n key={\"\"}\n width={100}\n value={commissionTypeToDisplayable(userCommissionsInfo.commissionType)}\n placeholder={\"--\"}\n onChange={(event) => setCommissionType(event.target.value)}\n colorArrowIcon={\"#5C6477\"}\n items={displayableCommissionTypes}/>\n </div>\n </>\n }\n <ConfirmationModal\n open={isConfirmationModalOpen}\n title={t(\"Do you want to continue?\")}\n body={\n <>\n <div style={{display: userCommissionsInfo.userCommissionType === UserCommissionType.ByService ? \"none\" : \"\"}}>\n {useCustomerTerminology(t(\"If you modify this field, this user can no longer have different commissions for each service and instead will have a default commission for all services.\"), getTerminology(TerminologyForm.Singular), getTerminology(TerminologyForm.Plural))}\n </div>\n <div style={{display: userCommissionsInfo.userCommissionType === UserCommissionType.Default ? \"none\" : \"\"}}>\n {useCustomerTerminology(t(\"If you modify this field, this user will no longer have a default commission for all services and instead can have different commissions for each service.\"), getTerminology(TerminologyForm.Singular), getTerminology(TerminologyForm.Plural))}\n </div>\n </>\n }\n okTextButton={t(\"Yes, continue\")}\n cancelTextButton={t(\"Go back\")}\n onConfirm={confirmUserCommissionTypeChange}\n onCancel={rejectUserCommissionTypeChange}\n onClose={confirmUserCommissionTypeChange}\n />\n </>);\n};","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\n\nimport { CommissionModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport { UserCommissionType } from \"../../../../../models/enums/user-commission-type\";\nimport CommissionView from \"../CommissionView\";\nimport { CommissionService } from \"../../../../../api/commission-service\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { UserCommissionInfo } from \"../../../../../models/user-commission-info\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\n\nexport default function CommissionModal(props: CommissionModalProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation(\"settings\");\n const dispatch = useAppDispatch();\n \n const { isOpen, setOpen, userCommission, setUserCommission, userId, userName, openedCommissionType } = props;\n const classes = useStyles();\n const { enqueueAlert } = alertsActions;\n \n const [isUserCommissionTypeChangeConfirmed, setIsUserCommissionTypeChangeConfirmed] = useState<boolean>(false);\n const [initialUserCommission, setInitialUserCommission] = useState<string>(\"\");\n \n useEffect(() => {\n if (isOpen) {\n setInitialUserCommission(JSON.stringify(userCommission));\n if (userCommission.initialUserCommissionType !== openedCommissionType) {\n if (openedCommissionType === UserCommissionType.Default) {\n setUserCommission({\n ...userCommission,\n commissionType: null,\n commissionValue: null,\n userCommissionType: openedCommissionType\n });\n } else if (openedCommissionType === UserCommissionType.ByService) {\n userCommission.commissionsByServices.forEach(service => {\n service.commissionValue = userCommission.commissionValue!;\n service.commissionType = userCommission.commissionType!;\n });\n setUserCommission({\n ...userCommission,\n commissionsByServices: userCommission.commissionsByServices,\n userCommissionType: openedCommissionType\n });\n }\n } else {\n setUserCommission({ ...userCommission, userCommissionType: openedCommissionType });\n }\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId, isOpen]);\n \n const handleOnClose = () => {\n setOpen(false);\n setIsUserCommissionTypeChangeConfirmed(false);\n };\n \n const handleSaveButtonClick = async () => {\n await CommissionService.updateUserCommission(userId, userCommission, settingsSelectedEstablishmentId);\n setOpen(false);\n setIsUserCommissionTypeChangeConfirmed(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Information updated successfully\")\n })\n );\n };\n \n const validateCommissions = () => {\n return userCommission.userCommissionType === UserCommissionType.Default\n ? !!userCommission.commissionValue && userCommission.commissionValue > 0 && userCommission.commissionType !== null\n : true;\n }\n \n const canSave = () => {\n const userCommissionJson = JSON.stringify(userCommission);\n if (!!initialUserCommission && initialUserCommission !== userCommissionJson){\n const initUserCommission: UserCommissionInfo = JSON.parse(initialUserCommission);\n // extra comparison logic for Daimara\n if (initUserCommission.userCommissionType != userCommission.userCommissionType){\n if (userCommission.userCommissionType === UserCommissionType.ByService) {\n initUserCommission.commissionsByServices.forEach(service => {\n service.commissionValue = userCommission.commissionValue!;\n service.commissionType = userCommission.commissionType!;\n });\n }\n initUserCommission.userCommissionType = userCommission.userCommissionType;\n return isUserCommissionTypeChangeConfirmed && JSON.stringify(initUserCommission) !== userCommissionJson && validateCommissions()\n }\n return JSON.stringify(initUserCommission) !== userCommissionJson && validateCommissions()\n }\n return false;\n }\n \n const editCommissionByDefaultFor = useTerminology({ type: TerminologyType.Commission, template: t(\"Edit commission by default for\"), templateTermToLowercase: true });\n const editCommissionByServiceFor = useTerminology({ type: TerminologyType.Commission, template: t(\"Edit commission by service for\"), templateTermToLowercase: true });\n \n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={handleOnClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={isOpen}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText}>\n {openedCommissionType === UserCommissionType.Default\n ? editCommissionByDefaultFor\n : editCommissionByServiceFor\n } \n {userName}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={120}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Cancel\")}\n onClick={handleOnClose}\n />\n <ButtonWithSpinner\n width={164}\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Save\")}\n onClick={handleSaveButtonClick}\n disabled={!canSave()}\n />\n </div>\n </div>\n <div className={classes.content}>\n <CommissionView\n userCommissionsInfo={userCommission}\n setUserCommissionsInfo={setUserCommission}\n isUserCommissionTypeChangeConfirmed={isUserCommissionTypeChangeConfirmed}\n setIsUserCommissionTypeChangeConfirmed={setIsUserCommissionTypeChangeConfirmed}/>\n </div>\n </div>\n </Fade>\n </Modal>\n </>\n};","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\n\nimport { Button } from \"@material-ui/core\";\n\nimport { CommissionService } from \"../../../../../api/commission-service\";\nimport { UserCommissions } from \"../../../../../models/user-commissions\";\nimport { CommissionListProps } from \"./props\";\nimport Pagination from \"../../../../common/Pagination\";\nimport useStyles from \"./css\";\nimport CommissionModal from \"../CommissionModal\";\nimport { UserCommissionInfo } from \"../../../../../models/user-commission-info\";\nimport { UserCommissionType } from \"../../../../../models/enums/user-commission-type\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\nimport { Color } from \"../../../../../constants/colors\";\n\n\nexport default function CommissionList(props: CommissionListProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"settings\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n \n const [usersCommissions, setUsersCommissions] = useState<UserCommissions[]>([]);\n const [totalUserCommissions, setTotalUserCommissions] = useState<number>(0);\n \n const [isCommissionModalOpened, setIsCommissionModalOpened] = useState<boolean>(false);\n const [currentUserCommission, setCurrentUserCommission] = useState<UserCommissionInfo>(new UserCommissionInfo());\n const [currentUserId, setCurrentUserId] = useState<string>(\"\");\n const [currentUserName, setCurrentUserName] = useState<string>(\"\");\n const [modalOpenedAs, setModalOpenedAs] = useState<UserCommissionType>(UserCommissionType.Default);\n \n const [page, setPage] = useState<number>(1);\n const pageSize: number = 12;\n \n \n useEffect(() => {\n async function fetchData() {\n await loadData();\n }\n \n void fetchData();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [settingsSelectedEstablishmentId, page]);\n \n async function loadData() {\n dispatch(navbarActions.setShowLoader(true));\n const usersCommissions = await CommissionService.getUsersCommissions(\n page,\n pageSize,\n settingsSelectedEstablishmentId\n );\n dispatch(navbarActions.setShowLoader(false));\n setUsersCommissions(usersCommissions.usersCommissions || []);\n setTotalUserCommissions(usersCommissions.totalUserCommissions || 0);\n }\n \n function handlePage(event: React.ChangeEvent<unknown>, page: number) {\n setPage(page);\n }\n \n async function openEditByService(user: UserCommissions) {\n setModalOpenedAs(UserCommissionType.ByService);\n await openCommissionModal(user);\n }\n \n async function openEditByDefault(user: UserCommissions) {\n setModalOpenedAs(UserCommissionType.Default);\n await openCommissionModal(user);\n }\n \n async function openCommissionModal(user: UserCommissions) {\n dispatch(navbarActions.setShowLoader(true));\n const userCommission = await CommissionService.getUserCommissionsById(user.id!, settingsSelectedEstablishmentId);\n dispatch(navbarActions.setShowLoader(false));\n \n setCurrentUserCommission(userCommission);\n setCurrentUserId(user.id!);\n setCurrentUserName(user.name!);\n setIsCommissionModalOpened(true);\n }\n \n function closeCommissionModal() {\n setIsCommissionModalOpened(false);\n }\n \n function renderAsCommissionCard(user: UserCommissions) {\n return (\n <div className={classes.userServices}>\n <div className={classes.userName}>{user.name}</div>\n <div className={classes.servicesCount}>{t(\"Number of services\")}: {user.servicesCount}</div>\n <div className={classes.buttons}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n innerText={t(\"Edit by service\")}\n onClick={() => openEditByService(user)}\n />\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n backgroundOrBorderColor={ButtonPropsColor.Gray1}\n textColor={ButtonPropsColor.Gray4}\n innerText={t(\"Edit by default\")}\n onClick={() => openEditByDefault(user)}\n />\n </div>\n </div>\n )\n }\n \n return (\n <div className={classes.pageContent}>\n <div className={classes.usersServices}>\n {usersCommissions.map(renderAsCommissionCard)}\n </div>\n <Pagination\n count={Math.ceil(totalUserCommissions / pageSize)}\n page={page || 1}\n onPageChange={handlePage}\n showPaginationAlways={false}\n />\n <CommissionModal\n isOpen={isCommissionModalOpened}\n setOpen={closeCommissionModal}\n userCommission={currentUserCommission}\n setUserCommission={setCurrentUserCommission}\n userId={currentUserId}\n userName={currentUserName}\n openedCommissionType={modalOpenedAs}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Button, Typography } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { InfoIcon, SectionEditIcon } from \"../../../../../assets/icons\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport CommissionList from \"../CommissionList\";\nimport EditTerminologyModal from \"../../../../common/EditTerminologyModal\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport { SettingsEnterpriseProps } from \"../../../../../models/interfaces/settings-enterprise-props\";\nimport { AccountService } from \"../../../../../api/account-service\";\nimport SectionNote from \"../../../../establishment-settings/Sections/FormsSettingsTabs/SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\n\n\nexport default function CommissionsMain(props: SettingsEnterpriseProps) {\n\n const { settingsSelectedEstablishmentId } = props;\n\n const { t } = useTranslation([\"settings\"]);\n\n const classes = useStyles();\n \n const [isTerminologyModalOpen, setIsTerminologyModalOpen] = useState<boolean>(false);\n const [establishmentCommissions, setEstablishmentCommissions] = useState<string>('');\n\n const commissions = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural });\n\n useEffect(() => {\n async function fetchEstablishmentCommissions() {\n if (settingsSelectedEstablishmentId) {\n const result = await AccountService.getAccountTerminology(TerminologyType.Commission, settingsSelectedEstablishmentId);\n setEstablishmentCommissions(result.pluralForm);\n }\n }\n fetchEstablishmentCommissions();\n }, [settingsSelectedEstablishmentId, isTerminologyModalOpen]);\n\n return (\n <>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Commissions\")}\n </Typography>\n </div>\n <SectionNote \n sectionData={SectionNoteData.Commissions}\n />\n </>\n )}\n <div className={classes.commissionsHeaderBlock}>\n <div className={classes.title}>\n {settingsSelectedEstablishmentId ? establishmentCommissions : commissions}\n </div>\n <IconTooltip\n icon={\n <InfoIcon\n style={{ width: 12, height: 12, marginBottom: 1 }}\n viewBox={\"0 0 12 12\"}\n />}\n tooltipText={t(\"The payment from an establishment to a user for performing services\")}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n classNameRoot={classes.iconTooltipRoot}\n />\n <Button\n onClick={() => setIsTerminologyModalOpen(true)}\n className={classes.actionButton}\n >\n <SectionEditIcon />\n </Button>\n </div>\n <CommissionList \n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n <EditTerminologyModal\n isOpen={isTerminologyModalOpen}\n setOpen={setIsTerminologyModalOpen}\n type={TerminologyType.Commission}\n settingsSelectedEstablishmentId={settingsSelectedEstablishmentId}\n />\n </>\n );\n}","import React from 'react';\nimport { Redirect, Route, Switch, BrowserRouter } from \"react-router-dom\";\n\nimport { Url } from \"../../../constants/url\";\nimport SettingsNavTabs from \"../SettingsNavTabs\";\nimport UsersMainPage from \"../Sections/Users/UsersMainPage\";\nimport CustomerCommunications from \"../Sections/CustomerCommunications/CustomerCommunicationsMain\";\nimport Workareas from \"../Sections/WorkArea/WorkAreaMain\";\nimport General from \"../Sections/General/GeneralMain\";\nimport PaymentMain from \"../Sections/Payments/PaymentMain\";\nimport Services from \"../Sections/Services/ServiceMain\";\nimport ClinicHistory from '../Sections/FormsSettingsTabs/ClinicHistory';\nimport EvolutionNotes from '../Sections/FormsSettingsTabs/EvolutionNotes';\nimport PatientForm from '../Sections/FormsSettingsTabs/PatientForm';\nimport Commissions from '../Sections/Commissions/CommissionsMain';\nimport { useAppSelector } from '../../../redux/hooks';\nimport { selectUserInfo } from '../../../redux/store';\n\nexport default function SettingsRouter() {\n\n const userInfo = useAppSelector(selectUserInfo);\n\n return (\n <>\n {\n userInfo.isAdministrator ?\n <BrowserRouter>\n <SettingsNavTabs />\n <Switch>\n <Route exact path={Url.Settings.Main} component={General} />\n <Route exact path={Url.Settings.CustomerCommunications} component={CustomerCommunications} />\n <Route exact path={Url.Settings.WorkAreas} component={Workareas} />\n <Route exact path={Url.Settings.Services} component={Services} />\n <Route exact path={Url.Settings.Users} component={UsersMainPage} />\n <Route exact path={Url.Settings.Payments} component={PaymentMain} />\n <Route exact path={Url.Settings.ClinicHistory} component={ClinicHistory} />\n <Route exact path={Url.Settings.EvolutionNotes} component={EvolutionNotes} />\n <Route exact path={Url.Settings.PatientForm} component={PatientForm} />\n <Route exact path={Url.Settings.Commissions} component={Commissions} />\n <Route\n exact\n path={Url.Settings.Users + \"/:userId\"}\n component={UsersMainPage}\n />\n <Route path={Url.Settings.Main}>\n <Redirect to={Url.Settings.Main} />\n </Route>\n </Switch>\n </BrowserRouter>\n :\n <Redirect to={Url.Appointments.Main} />\n }\n </>\n );\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n marginTop: 20,\n paddingLeft: 20,\n paddingRight: 11\n },\n mainContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"end\",\n \n height: 90,\n \n paddingTop: 0,\n paddingLeft: 11,\n paddingRight: 11,\n paddingBottom: 13,\n \n border: \"1px solid #C9CDD3\",\n borderRadius: 5,\n \n backgroundColor: theme.colors.white,\n },\n inputsBlock: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 8,\n },\n dateLabel: {\n ...theme.typography.buttons,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: Color.gray4,\n marginBottom: 8\n },\n controlWithLabel: {},\n dateInputText: {\n ...theme.typography.txtBody2,\n fontWeight: 700,\n color: theme.colors.grey5,\n opacity: 0.8,\n },\n reportTypeSelect: {\n alignSelf: \"flex-end\",\n },\n downloadReportButtonBlock: {},\n downloadReportButton: {\n width: 202,\n height: 40,\n \n backgroundColor: theme.colors.clearMain,\n borderRadius: 5,\n \n ...theme.typography.buttons,\n color: theme.colors.grey1,\n fontWeight: 700,\n \n \"&:hover\": {\n backgroundColor: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n \"&:disabled\": {\n backgroundColor: theme.colors.clearMain,\n opacity: 0.3,\n color: theme.colors.grey1,\n }\n },\n downloadReportButtonLabel: {\n display: \"flex\",\n gap: 10,\n },\n}));\n\nexport default useStyles;\n","export enum PredeterminedReportType {\n Appointments,\n CashClosing,\n Commissions,\n Services,\n Customers,\n}","import { ReportColumn } from \"./report-column\";\n\nexport class Report {\n id: string;\n name: string;\n properties: ReportColumn[];\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.properties = x.properties;\n }\n else {\n this.id = \"\";\n this.name = \"\";\n this.properties = [];\n }\n }\n}","export enum ColumnGroupNameId {\n Appointments = \"7998866e-9e64-4266-9fc3-f056756d4025\",\n Customer = \"860a48fe-d46d-4f61-a9d5-ab3314cedc9b\",\n Specialist = \"c429a37d-0cce-4e1e-8243-4791825ab33c\",\n Commissions = \"2f21c735-b174-4113-9247-8fe8fe5c1ee7\",\n Payments = \"80335ed6-f2d7-4f71-a0ea-811daa56e487\",\n Services = \"8036b1bf-3bd9-4e58-a630-992e9a4e4335\",\n GeneralInformation = \"303e5ed5-95da-46c0-bc22-db42089a8695\",\n}\n\nexport enum ColumnNameId {\n // Appointments\n Appointment = \"24a7305c-875c-418d-a85f-42a0078ef3b8\",\n AppointmentStatus = \"22fa4585-cf52-44ab-80e0-b137f2d2ab16\",\n PaymentStatus = \"70af27d9-1da0-49f3-b3bc-353cc3f88256\",\n AppointmentDate = \"e02b5859-5941-4fd5-b4c8-5229ca0a357a\",\n AppointmentTime = \"43bdbd03-4474-44cc-9e37-8a9f969281e3\",\n AppointmentCreatedBy = \"5b653b33-f075-4788-8f0b-b5a672f0b113\",\n RecurringAppointment = \"dafdc3dd-5572-4ca2-b304-0a03259c2e7f\",\n\n // Customer\n Customer = \"3fca98b7-2606-4256-ba86-21f98163534e\",\n CustomerMobile = \"a195db5b-61e0-4432-b997-1ec98cbd6bcd\",\n CustomerGender = \"d1e5e8bb-0223-40c2-9426-8136165c7c0a\",\n CustomerContactableForAppointments = \"df73d3b4-15f8-4975-9144-c6c9e5fc8e46\",\n CustomerContactableForMassiveSendings = \"355c86eb-25c9-483e-9daf-8212f7296d0d\",\n \n // Specialist\n Specialist = \"5239e9a8-6407-4826-abcd-04c8ae2246f4\",\n SpecialistID = \"26749ec1-804e-4125-ba4c-669f2a079858\",\n SpecialistEmail = \"a2dce254-ef17-4069-9ad6-e368b1e8f971\",\n SpecialistJobTitle = \"26f8543a-527c-4803-acbb-733cd402bda0\",\n \n // Commissions\n CommissionPerService = \"af847f96-0ab6-436c-8aad-0818b32280ab\",\n CommissionAmount = \"eb2b51f0-aee6-42cb-8fd6-2172ccbbc191\",\n \n // Payments\n PaymentID = \"09739a33-5089-44a5-a20e-069bbd4467d3\",\n UserWhoRegisteredThePayment = \"1a153857-8b48-457e-a5a4-1531d5ab91d9\",\n PaymentDate = \"2fe5bd5b-b27a-479e-a8fb-041533bee854\",\n PaymentTime = \"eb251570-4e8d-4ddf-99c6-a8d315b11a97\",\n PaymentMethod = \"7a88309c-c600-4633-ae5e-0ab086660187\",\n TotalToPay = \"1d5b5bf0-94ad-45cb-b983-21f640956d12\",\n AmountPaid = \"54f4c1f8-3d33-4e4d-9b16-d3ae6b9567eb\",\n AmountDue = \"c75a8ee2-c5eb-4333-8989-32a66b1d171e\",\n TotalToPayRecurringAppt = \"0cd182d5-2016-40b7-979a-c0d632e14838\",\n AmountPaidRecurringAppt = \"fb2c007e-42f6-4926-8b75-9e2e3aa4572f\",\n AmountDueRecurringAppt = \"49adebfe-5aa2-4c88-8071-e361d96e8306\",\n\n // Services\n ServiceName = \"e3b7f7a4-8f7d-406f-b419-d3aa28de2c18\",\n ServicePrice = \"4f2f473a-f752-4b5b-b861-c3d80fe5cf87\",\n ServiceCategory = \"f23191ce-1edc-4f3c-a1bb-af1c365acf0e\",\n ServiceDuration = \"90e2bb8b-e001-4525-bd3a-277232df0085\",\n ServiceRecurrence = \"8ca824e7-3df8-4157-b54d-a9321f14b5c1\",\n ServiceWorkArea = \"50df2d35-ce52-4611-9e42-6372bf8626d1\",\n \n // General Information\n Establishment = \"d9c6dca2-85ff-4b9d-874b-501952df5738\",\n}\n","\nexport class ReportColumnGroup {\n id: string;\n name: string;\n columns: ReportColumn[];\n order: number;\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.columns = x.columns;\n this.order = x.order;\n }\n else {\n this.id = \"\";\n this.name = \"\";\n this.columns = [];\n this.order = 1;\n }\n }\n}\n\nexport class ReportColumn {\n id: string;\n order: number;\n isPrimary: boolean;\n name: string;\n tooltip?: string;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.id = x.id;\n this.order = x.order;\n this.isPrimary = x.isPrimary;\n this.name = x.name;\n this.tooltip = x.tooltip;\n }\n else {\n this.id = \"\";\n this.order = 1;\n this.isPrimary = false;\n this.name = \"\";\n this.tooltip = undefined;\n }\n }\n}","import OrderedReportProperty from \"./ordered-report-property\";\n\nexport class PreviewCustomReport {\n properties: Array<OrderedReportProperty>;\n resultNumbers: Array<number>;\n dataTable: Array<Array<Record<string, any>>>;\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.properties = x.properties;\n this.resultNumbers = x.resultNumbers;\n this.dataTable = x.dataTable;\n } else {\n this.properties = [];\n this.resultNumbers = [];\n this.dataTable = [];\n }\n }\n}","import axios, { CancelToken } from \"axios\";\n\nimport { PredeterminedReportType } from \"../models/enums/predetermined-report-type\";\nimport { ApiClient } from \"./api-client\";\nimport { Report } from \"../models/report\";\nimport { ReportColumnGroup, ReportColumn } from \"../models/report-column\";\nimport { CustomReportPreviewRequest } from \"../models/custom-report-preview-request\";\nimport { PreviewCustomReport } from \"../models/preview-custom-report\";\nimport OrderedReportProperty from \"../models/ordered-report-property\";\nimport { ColumnGroupNameId, ColumnNameId } from \"../models/enums/report-column-id\";\nimport { EnterpriseCustomReportPreviewRequest } from \"../models/enterprise-custom-report-preview-request\";\n\n\nexport class ReportsService {\n private static baseUrl: string = \"/reports\";\n \n private static isoDate(date: Date): string {\n const year = date.toLocaleString(\"en-US\", {\n year: \"numeric\",\n });\n const month = date.toLocaleString(\"en-US\", {\n month: \"2-digit\",\n });\n const day = date.toLocaleString(\"en-US\", {\n day: \"2-digit\",\n });\n \n return `${year}-${month}-${day}`;\n }\n \n public static handleTime(date: Date): string {\n const time = date.toLocaleString(\"en-US\", {\n hourCycle: \"h23\",\n hour: \"2-digit\",\n minute: \"2-digit\",\n second: \"2-digit\"\n });\n \n return `${this.isoDate(date)}T${time}`;\n }\n \n static getPredeterminedReport(dateFrom: Date, dateTo: Date, type: PredeterminedReportType): Promise<any> {\n let endpoint = `${this.baseUrl}/getPredeterminedReport?`\n \n endpoint += Object.entries({\n DateFrom: this.handleTime(dateFrom),\n DateTo: this.handleTime(dateTo),\n ReportType: type\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\")\n \n return ApiClient.get(endpoint, {\n responseType: 'arraybuffer',\n headers:\n {\n 'Content-Type': 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml'\n }\n }).then((data) => {\n return data;\n });\n }\n\n static downloadCustomReport = (\n dateFrom: Date,\n dateTo: Date,\n primaryPropertyId: string,\n properties: OrderedReportProperty[],\n reportName: string | null,\n ) =>\n async (setPercentage: (num: number) => void, cancelToken: CancelToken): Promise<Blob> =>\n {\n let endpoint = `${this.baseUrl}/downloadCustomReport`\n\n const request = {\n dateFrom: this.handleTime(dateFrom),\n dateTo: this.handleTime(dateTo),\n primaryPropertyId,\n properties,\n reportName: reportName\n }\n \n return ApiClient.post(endpoint, request, {\n responseType: 'blob',\n cancelToken: cancelToken\n }).then((data) => {\n return data;\n });\n }\n \n static downloadEnterpriseCustomReport = (\n dateFrom: Date,\n dateTo: Date,\n primaryPropertyId: string,\n properties: OrderedReportProperty[],\n reportName: string | null,\n establishmentIds: string[]\n ) =>\n async (setPercentage: (num: number) => void, cancelToken: CancelToken): Promise<Blob> =>\n {\n let endpoint = `${this.baseUrl}/downloadEnterpriseCustomReport`\n\n const request = {\n dateFrom: this.handleTime(dateFrom),\n dateTo: this.handleTime(dateTo),\n primaryPropertyId,\n properties,\n establishmentIds,\n reportName: reportName\n }\n \n return ApiClient.post(endpoint, request, {\n responseType: 'blob',\n cancelToken: cancelToken\n }).then((data) => {\n return data;\n });\n }\n \n static async createCustomReport(\n primaryPropertyId: string,\n properties: OrderedReportProperty[],\n reportName: string): Promise<Report> {\n let endpoint = `${this.baseUrl}/createCustomReport`\n\n const request = {\n primaryPropertyId,\n properties,\n reportName\n }\n\n return ApiClient.post(endpoint, request).then((data) => data);\n }\n \n static async deleteCustomReport(reportId: string): Promise<boolean> {\n let endpoint = `${this.baseUrl}/deleteCustomReport?id=${reportId}`\n await ApiClient.remove(endpoint);\n return true;\n }\n \n static async updateCustomReport(\n primaryPropertyId: string,\n properties: OrderedReportProperty[],\n reportId: string): Promise<Report> {\n let endpoint = `${this.baseUrl}/updateCustomReport`\n\n const request = {\n primaryPropertyId,\n properties,\n reportId\n }\n\n return ApiClient.post(endpoint, request).then((data) => data);\n }\n \n static async renameCustomReport(\n reportId: string,\n name: string): Promise<Report> {\n let endpoint = `${this.baseUrl}/renameCustomReport`\n\n const request = {\n reportId,\n name\n }\n\n return ApiClient.post(endpoint, request).then((data) => data);\n }\n \n static async getCustomReportsList(): Promise<Report[]> {\n let endpoint = `${this.baseUrl}/getCustomReportsList`;\n return ApiClient.get(endpoint).then((data) => {\n return data.reports.map((reportData: any) => new Report(reportData));\n });\n }\n \n static async getCustomReportPreview(requestData: CustomReportPreviewRequest): Promise<PreviewCustomReport> {\n let endpoint = `${this.baseUrl}/getCustomReportPreview`;\n return ApiClient.post(endpoint, requestData).then((data) => {\n return new PreviewCustomReport({\n properties: data.properties,\n resultNumbers: data.resultNumbers,\n dataTable: data.dataTable,\n });\n });\n }\n \n static async getEnterpriseCustomReportPreview(requestData: EnterpriseCustomReportPreviewRequest): Promise<PreviewCustomReport> {\n let endpoint = `${this.baseUrl}/getEnterpriseCustomReportPreview`;\n return ApiClient.post(endpoint, requestData).then((data) => {\n return new PreviewCustomReport({\n properties: data.properties,\n resultNumbers: data.resultNumbers,\n dataTable: data.dataTable,\n });\n });\n }\n\n static getImpactedCustomersReport(massiveSendingId: string): Promise<Blob> {\n let endpoint = `${this.baseUrl}/getImpactedCustomersReport?`\n\n endpoint += Object.entries({\n MassiveSendingId: massiveSendingId\n }).flatMap(([key, value]) => [value].flat().map(v => [key, v]))\n .map(it => it.join(\"=\"))\n .join(\"&\")\n\n return ApiClient.get(endpoint, {\n responseType: 'arraybuffer',\n headers:\n {\n 'Content-Type': 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml'\n }\n }).then((data) => {\n return data;\n });\n }\n\n static async getCustomReportsColumnList(): Promise<ReportColumnGroup[]> {\n let endpoint = `${this.baseUrl}/getcustomreportcolumns`;\n\n const tooltippedColumns: { [id: string]: string } = {\n [ColumnNameId.TotalToPayRecurringAppt]: \"It's the sum of all recurring appointments\",\n [ColumnNameId.AmountPaidRecurringAppt]: \"It's the sum of all recurring appointments\",\n [ColumnNameId.AmountDueRecurringAppt]: \"It's the sum of all recurring appointments\",\n }\n \n const orderGroup: { [id: string]: number } = {\n [ColumnGroupNameId.Appointments]: 1,\n [ColumnGroupNameId.Customer]: 2,\n [ColumnGroupNameId.Specialist]: 3,\n [ColumnGroupNameId.Commissions]: 4,\n [ColumnGroupNameId.Payments]: 5,\n [ColumnGroupNameId.Services]: 6,\n [ColumnGroupNameId.GeneralInformation]: 7,\n };\n \n const orderColumns: { [id: string]: number } = {\n // appointments\n [ColumnNameId.Appointment]: 1,\n [ColumnNameId.RecurringAppointment]: 2,\n [ColumnNameId.AppointmentStatus]: 3,\n [ColumnNameId.PaymentStatus]: 4,\n [ColumnNameId.AppointmentDate]: 5,\n [ColumnNameId.AppointmentTime]: 6,\n [ColumnNameId.AppointmentCreatedBy]: 7,\n\n // customer\n [ColumnNameId.Customer]: 1,\n [ColumnNameId.CustomerMobile]: 2,\n [ColumnNameId.CustomerGender]: 3,\n [ColumnNameId.CustomerContactableForAppointments]: 4,\n [ColumnNameId.CustomerContactableForMassiveSendings]: 5,\n \n // specialist\n [ColumnNameId.Specialist]: 1,\n [ColumnNameId.SpecialistID]: 2,\n [ColumnNameId.SpecialistEmail]: 3,\n [ColumnNameId.SpecialistJobTitle]: 4,\n \n // commissions\n [ColumnNameId.CommissionPerService]: 1,\n [ColumnNameId.CommissionAmount]: 2,\n \n // payments\n [ColumnNameId.PaymentID]: 1,\n [ColumnNameId.UserWhoRegisteredThePayment]: 2,\n [ColumnNameId.PaymentDate]: 3,\n [ColumnNameId.PaymentTime]: 4,\n [ColumnNameId.PaymentMethod]: 5,\n [ColumnNameId.TotalToPay]: 6,\n [ColumnNameId.AmountPaid]: 7,\n [ColumnNameId.AmountDue]: 8,\n [ColumnNameId.TotalToPayRecurringAppt]: 9,\n [ColumnNameId.AmountPaidRecurringAppt]: 10,\n [ColumnNameId.AmountDueRecurringAppt]: 11,\n\n // services\n [ColumnNameId.ServiceName]: 1,\n [ColumnNameId.ServicePrice]: 2,\n [ColumnNameId.ServiceCategory]: 3,\n [ColumnNameId.ServiceDuration]: 4,\n [ColumnNameId.ServiceRecurrence]: 5,\n [ColumnNameId.ServiceWorkArea]: 6,\n \n // general information\n [ColumnNameId.Establishment]: 1,\n };\n \n return ApiClient.get(endpoint).then((data) => {\n return data.propertyGroups.map((group: ReportColumnGroup) => {\n const columns = group.columns.map((col: ReportColumn) => {\n return new ReportColumn({ ...col,\n order: orderColumns[col.id],\n tooltip: tooltippedColumns[col.id]\n });\n });\n return new ReportColumnGroup({ ...group,\n order: orderGroup[group.id],\n columns });\n });\n });\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n tabBar: {\n width: \"100%\",\n height: 47,\n marginTop: -20\n },\n tabs: {\n ...theme.typography.txtBody2,\n \"& .MuiTabs-indicator\": {\n backgroundColor: \"#7175FA\"\n },\n \"& .Mui-selected\": {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: \"bold\"\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n alignItems: \"left\",\n marginRight: 25\n },\n \"& .MuiTab-root\": {\n paddingLeft: 0,\n paddingRight: 0,\n },\n },\n tab: {\n ...theme.typography.txtBody2,\n textTransform: \"none\",\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n },\n \"&:hover\": {\n color: theme.colors.clearMain\n }\n },\n mainTab: {\n paddingTop: 0,\n paddingBottom: 20,\n backgroundColor: \"#ffffff\",\n height: 50,\n marginBottom: 30\n },\n headerBack: {\n height: 50,\n width: \"100%\",\n backgroundColor: \"#ffffff\",\n position: \"absolute\",\n left: 0\n }\n}));\n\nexport default useStyles;\n","import React from 'react';\n\nimport { Link, useRouteMatch } from \"react-router-dom\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { Tab, Tabs } from \"@material-ui/core\";\n\nimport { Url } from \"../../../constants/url\";\nimport useStyles from './css';\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\n\nexport default function ReportsNavTabs() {\n \n const accountSettings = useAppSelector(selectAccountSettings);\n \n const routeMatch = useRouteMatch({\n path: [\n Url.Reports.Main,\n Url.Reports.CustomReport\n ],\n exact: true\n });\n \n const currentTab = routeMatch?.path;\n \n const { t } = useTranslation([\"general\"]);\n \n const classes = useStyles();\n \n return (\n <>\n <div className={classes.headerBack} />\n <div className={classes.mainTab}>\n <div className={classes.tabBar}>\n <Tabs\n value={currentTab}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n className={classes.tabs}\n >\n {!accountSettings.isEnterprise && (<Tab\n className={classes.tab}\n label={t(\"Predefined reports\")}\n value={Url.Reports.Main}\n to={Url.Reports.Main}\n component={Link}\n />)}\n <Tab\n className={classes.tab}\n label={t(\"Customizable reports\")}\n value={Url.Reports.CustomReport}\n to={Url.Reports.CustomReport}\n component={Link} \n />\n </Tabs>\n </div>\n </div>\n </>\n );\n}","import React, { useEffect, useState } from 'react';\nimport { useTranslation } from \"react-i18next\";\n\nimport { useDispatch } from \"react-redux\";\nimport { useAppSelector } from \"../../../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { applicationInterfaceActions } from \"../../../../../redux/application-interface-slice\";\n\nimport { Button, CircularProgress } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport useControlLabel from \"../../../../../hooks/useControlLabel\";\nimport DateInput from \"../../../../common/DateInput\";\nimport moment from \"moment\";\nimport SelectKey from \"../../../../common/SelectKey\";\nimport { SelectItem } from \"../../../../../models/interfaces/select-item\";\nimport { PredeterminedReportType } from \"../../../../../models/enums/predetermined-report-type\";\nimport { ReportsService } from \"../../../../../api/reports-service\";\nimport useTerminology from \"../../../../../hooks/useTerminology\";\nimport { TerminologyType } from \"../../../../../models/enums/terminology-type\";\nimport { TerminologyForm } from \"../../../../../models/enums/terminology-form\";\nimport ReportsNavTabs from \"../../../ReportsNavTabs\";\nimport useCustomerTerminology from \"../../../../../hooks/useCustomerTerminology\";\n\n\nexport default function PredeterminedReportsPage() {\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n const dispatch = useDispatch();\n \n const todayDate = new Date();\n const lastMonthDate = addMonths(new Date(), -1);\n const nextDayOfLastMonthDate = addDays(addMonths(new Date(), -1), 1);\n \n const [startDate, setStartDate] = useState<Date>(lastMonthDate);\n const [endDate, setEndDate] = useState<Date>(nextDayOfLastMonthDate);\n \n const { updateIsWideLayout } = applicationInterfaceActions;\n \n const commissions = useTerminology({ type: TerminologyType.Commission, form: TerminologyForm.Plural });\n const commissionsReport = useTerminology({ type: TerminologyType.Commission, template: t(\"Commissions report\"), form: TerminologyForm.Plural });\n \n const accountSettings = useAppSelector(selectAccountSettings);\n \n const customerTerminology = useCustomerTerminology(t(\"Customers\"), \"Customers\");\n const customerReportNameTerminology = useCustomerTerminology(t(\"Customers report\"), \"Customers report\");\n \n const [reportType, setReportType] = useState<PredeterminedReportType | null>(null);\n const reportTypes: SelectItem[] = \n [\n { key: PredeterminedReportType.Appointments, value: t(\"Appointments\") },\n { key: PredeterminedReportType.Commissions, value: commissions },\n { key: PredeterminedReportType.Services, value: t(\"Services\") },\n { key: PredeterminedReportType.Customers, value: customerTerminology },\n ]\n \n if (accountSettings.paymentsAndCollectionsEnabled) {\n reportTypes.push({ key: PredeterminedReportType.CashClosing, value: t(\"Cash closing\") });\n }\n \n //sorted alphabetically\n const sortedReportTypes = reportTypes.sort((a, b) => a.value.localeCompare(b.value))\n \n const [isDownloading, setIsDownloading] = useState<boolean>(false);\n \n const locale = useAppSelector(state => state.applicationInterface.locale);\n\n const accountName = accountSettings.accountName;\n \n const dateFormatPlaceholder = locale === \"en\" ? \"mm/dd/yy\" : \"dd/mm/yy\";\n const dateFormat = locale === \"en\" ? \"MM/dd/yy\" : \"dd/MM/yy\";\n const fileDateFormat = locale === \"en\" ? \"MM-DD-YYYY\" : \"DD-MM-YYYY\";\n \n const StartDateLabel = useControlLabel({ label: t(\"Start date\"), required: true, labelClass: classes.dateLabel, })\n const EndDateLabel = useControlLabel({ label: t(\"End date\"), required: true, labelClass: classes.dateLabel, })\n \n useEffect(() => {\n dispatch(updateIsWideLayout(true));\n });\n \n function addDays(date: Date, days: number): Date {\n let result = new Date(date);\n result.setDate(result.getDate() + days);\n return result;\n }\n \n function addMonths(date: Date, months: number): Date {\n let result = new Date(date);\n result.setMonth(result.getMonth() + months);\n return result;\n }\n \n function getReportTypeName(type: PredeterminedReportType) {\n switch (type) {\n case PredeterminedReportType.Appointments:\n return t(\"Appointments report\");\n case PredeterminedReportType.CashClosing:\n return t(\"Cash closing report\");\n case PredeterminedReportType.Commissions:\n return commissionsReport;\n case PredeterminedReportType.Services:\n return t(\"Services report\");\n case PredeterminedReportType.Customers:\n return customerReportNameTerminology;\n default:\n return t(\"Report\");\n }\n }\n \n function getReportFileName(type: PredeterminedReportType, dateFrom: Date, dateTo: Date) {\n const reportTypeName = getReportTypeName(type)\n const dateFromFormatted = moment(dateFrom).format(fileDateFormat)\n const dateToFormatted = moment(dateTo).format(fileDateFormat)\n return `${accountName} - ${reportTypeName} - ${dateFromFormatted} - ${dateToFormatted}`;\n }\n \n async function handleDownloadReportClick() {\n if (reportType === null) return;\n \n setIsDownloading(true);\n \n try {\n const blob = await ReportsService.getPredeterminedReport(startDate, endDate, reportType);\n const url = window.URL.createObjectURL(new Blob([blob], {\n type: \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml\"\n }));\n const link = document.createElement('a');\n const name = getReportFileName(reportType, startDate, endDate);\n link.href = url;\n link.setAttribute('download', `${name}.xlsx`);\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n }\n finally {\n setIsDownloading(false);\n }\n }\n \n return (\n <div className={classes.root}>\n <ReportsNavTabs/>\n <div className={classes.mainContainer}>\n <div className={classes.inputsBlock}>\n <div className={classes.controlWithLabel}>\n <StartDateLabel/>\n <DateInput\n width={158}\n placeholder={t(dateFormatPlaceholder)}\n format={dateFormat}\n value={startDate}\n onChange={setStartDate}\n maxDate={todayDate}\n inputTextClass={classes.dateInputText}\n iconColor={\"#ACB7C0\"}\n />\n </div>\n <div className={classes.controlWithLabel}>\n <EndDateLabel/>\n <DateInput\n width={158}\n placeholder={t(dateFormatPlaceholder)}\n format={dateFormat}\n value={endDate}\n onChange={setEndDate}\n minDate={startDate}\n maxDate={todayDate}\n inputTextClass={classes.dateInputText}\n iconColor={\"#ACB7C0\"}\n />\n </div>\n <div className={classes.reportTypeSelect}>\n <SelectKey\n value={reportType}\n setValue={setReportType}\n items={sortedReportTypes}\n width={348}\n placeholder={t(\"Select a report\")}\n />\n </div>\n \n </div>\n <div className={classes.downloadReportButtonBlock}>\n <Button\n className={classes.downloadReportButton}\n disabled={isDownloading || reportType === null}\n onClick={handleDownloadReportClick}\n >\n {\n <span className={classes.downloadReportButtonLabel}>\n {isDownloading\n ? <CircularProgress size=\"1rem\" style={{ color: \"#FFFFFF\" }}/>\n : null\n }\n {t(\"Download report\")}\n </span>\n }\n </Button>\n </div>\n </div>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n marginTop: 20,\n paddingLeft: 20,\n paddingRight: 11\n },\n mainContainer: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"end\",\n \n height: 90,\n \n paddingTop: 0,\n paddingLeft: 11,\n paddingRight: 11,\n paddingBottom: 13,\n \n border: \"1px solid #C9CDD3\",\n borderRadius: 5,\n \n backgroundColor: theme.colors.white,\n },\n bottomRoot: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 10,\n marginTop: 8\n },\n columnNotFoundContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n gap: 12,\n marginTop: 20\n },\n columnNotFoundCaptionBold: {\n ...theme.typography.header4,\n color: theme.colors.clear2,\n fontWeight: 700,\n marginTop: 10\n },\n columnNotFoundCaption: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n selectEstablishmentContainer: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginRight: 27\n },\n scrollColumnsArea: {\n height: \"calc(100vh - 402px)\",\n paddingLeft: 16,\n overflowY: \"auto\",\n \n \"&::-webkit-scrollbar\": {\n backgroundColor: theme.colors.white,\n width: 16,\n },\n \"&::-webkit-scrollbar-track\": {\n backgroundColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-track:hover\": {\n backgroundColor: \"#F4F4F4\",\n width: 16,\n },\n \"&::-webkit-scrollbar-thumb\": {\n backgroundColor: \"#babac0\",\n \n border: \"solid\",\n borderRadius: 16,\n borderWidth: 5,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-thumb:hover\": {\n backgroundColor: \"#a0a0a5\",\n \n border: \"solid\",\n borderWidth: 4,\n borderColor: theme.colors.white,\n },\n \"&::-webkit-scrollbar-button\": {\n display: \"none\",\n },\n },\n columnsContainer: {\n height: \"calc(100vh - 262px)\",\n flexBasis: \"17%\",\n \n border: \"1px solid #C9CDD3\",\n borderRadius: 5,\n \n backgroundColor: theme.colors.white,\n },\n columnsHeader: {\n ...theme.typography.buttons,\n fontWeight: 700,\n borderTopLeftRadius: 5,\n borderTopRightRadius: 5,\n \n display: \"flex\",\n alignItems: \"center\",\n height: 80,\n color: \"#6A6E72\",\n justifyContent: \"center\",\n backgroundColor: theme.colors.grey1,\n },\n columnsContent: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 400,\n \n marginBottom: 24\n },\n draggableClassName: {},\n emptyPreviewBoxCaption: {\n ...theme.typography.txtBody3,\n color: \"#6A6E72\"\n },\n emptyPreviewBoxTitle: {\n fontFamily: \"Inter\",\n fontSize: \"34px\",\n fontStyle: \"normal\",\n fontWeight: 700,\n lineHeight: \"normal\",\n color: theme.colors.clearMain,\n },\n checkboxLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 400\n },\n columnCheckbox: {\n paddingBottom: 3,\n paddingTop: 0,\n paddingRight: 8,\n paddingLeft: 12,\n \n '&.Mui-checked': {\n color: \"#6462F3!important\",\n \"&:hover\": {\n backgroundColor: \"transparent\"\n }\n },\n \"&:hover\": {\n backgroundColor: \"transparent\"\n },\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 400\n },\n groupHeader: {\n marginBottom: 12,\n display: \"flex\",\n ...theme.typography.subtitle1,\n fontFamily: \"Inter, sans-serif\",\n },\n selectedColumnsBox: {\n ...theme.typography.txtBody2\n },\n mainBoxClass: {\n boxSizing: \"border-box\",\n borderRadius: \"5px\",\n width: \"100%\",\n overflow: \"hidden\",\n },\n modalActionsAppt: {\n position: \"absolute\",\n top: 6,\n right: 5,\n background: \"white\",\n width: 150,\n textAlign: \"center\",\n border: \"1px solid #DBDCDD\",\n boxShadow: \"0px 4px 4px rgb(166 166 166 / 25%)\",\n borderRadius: 5,\n backgroundColor: \"#FFFFFF\",\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 14,\n color: theme.colors.grey5,\n },\n modalActionFont: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n color: theme.colors.grey5,\n padding: 5,\n cursor: \"pointer\",\n position: \"relative\",\n background: \"white\",\n width: 150,\n textAlign: \"left\",\n paddingLeft: 15,\n height: 35,\n \"&:hover\": {\n backgroundColor: \"#E1E9FE\"\n }\n },\n modalHeader: {\n ...theme.typography.txtBody1,\n fontWeight: 700\n },\n cancelModalContainer: {\n textAlign: \"center\"\n },\n disabledButton: {\n opacity: 0.5, \n pointerEvents: 'none', \n },\n cancelModalContent: {\n fontFamily: \"Roboto\",\n fontSize: \"11px\",\n fontStyle: \"normal\",\n fontWeight: 400,\n lineHeight: \"normal\",\n color: \"#6A6E72\"\n },\n cancelButton: {\n width: 200,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n sectionContainer: {\n marginLeft: 10\n },\n sectionLayout: {\n display: \"flex\",\n flexDirection: \"column\",\n paddingTop: 0,\n marginBottom: 16\n },\n iconTooltipRoot: {\n width: 150,\n position: \"relative\"\n },\n radioGroup: {\n padding: 10,\n paddingTop: 0,\n paddingLeft: 5\n },\n radioLabelRoot: {\n margin: \"-7px 15px 0 0\"\n },\n emptyPreviewBox: {\n display: \"flex\",\n flexDirection: \"column\",\n textAlign: \"center\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"100%\",\n gap: 8,\n \n [theme.breakpoints.down(1536)]: {\n transform: \"scale(0.5)\"\n },\n },\n radioLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n },\n radioOption: {\n \"&.Mui-checked\": {\n \"&, & + .MuiFormControlLabel-label\": {\n color: \"#6462F3\",\n },\n \"&::after\": {\n content: '\"\"',\n position: \"absolute\",\n top: \"50%\",\n left: \"50%\",\n transform: \"translate(-50%, -50%)\",\n width: 7,\n height: 7,\n borderRadius: \"50%\",\n backgroundColor: \"#6462F3\",\n borderColor: \"#6462F3\"\n },\n },\n },\n previewRoot: {\n flexBasis: \"83%\",\n width: \"50%\",\n },\n totalResultText: {\n ...theme.typography.caption2,\n color: theme.colors.clearMain,\n },\n draggableInnerContainer: {\n display: \"flex\",\n alignItems: \"center\",\n height: \"27px!important\",\n padding: 0,\n gap: 0,\n width: \"95%\",\n backgroundColor: Color.white,\n borderRadius: 5,\n \"&:hover\": {\n backgroundColor: \"#EAE9FF\"\n },\n },\n rowStyle: {\n whiteSpace: \"nowrap\",\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n width: \"inherit\"\n },\n classTableBody: {\n overflowY: \"auto\",\n overflowX: \"auto\",\n height: \"100%\",\n },\n classTableContainer: {\n border: \"1px solid #DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"100%\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n height: \"10px\",\n cursor: \"pointer\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"11px\",\n marginBottom: \"11px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: \"#919CA5\"\n },\n\n },\n inputSearchClass: {\n height: 32,\n width: \"85%\"\n },\n inputSearchContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n marginTop: 14, \n marginBottom: 7\n },\n \n informativeBoxContainer: {\n ...theme.typography.buttons,\n borderRadius: 5,\n \n padding: \"9px 0 9px 19px\",\n \n color: theme.colors.clearMain,\n backgroundColor: theme.colors.clearLilac,\n },\n \n previewContainer: {\n border: \"1px solid #C9CDD3\",\n borderRadius: 12,\n \n backgroundColor: theme.colors.white,\n \n height: \"calc(100vh - 302px)\",\n marginTop: 8\n },\n \n inputSearchRoot: {\n ...theme.typography.txtBody2,\n borderRadius: 100,\n background: \"#F6F6F6\",\n border: `1px solid ${theme.colors.grey2}`,\n height: 40,\n paddingLeft: 12,\n \"&:focus\": {\n border: \"solid 1px #6462F3\",\n },\n },\n \n inputsBlock: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: 8\n },\n itemRootClass: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n paddingRight: 8,\n paddingLeft: 12\n },\n dateInputText: {\n ...theme.typography.txtBody2,\n fontWeight: 700,\n color: theme.colors.grey5,\n opacity: 0.8,\n },\n controlWithLabel: {},\n dateLabel: {\n ...theme.typography.buttons,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: Color.gray4,\n marginBottom: 8\n },\n deleteModalContentReportName: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n color: Color.gray5,\n textAlign: \"center\",\n marginBottom: 10\n },\n deleteModalContentText: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"11px\",\n lineHeight: \"17px\",\n color: \"#6A6E72\"\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n reportTypeSelect: {\n alignSelf: \"flex-end\",\n },\n downloadReportButtonBlock: {},\n downloadReportButton: {\n width: 130,\n height: 40,\n \n backgroundColor: theme.colors.clearMain,\n borderRadius: 5,\n \n ...theme.typography.buttons,\n color: theme.colors.grey1,\n fontWeight: 700,\n \n \"&:hover\": {\n backgroundColor: theme.colors.clearMain,\n color: theme.colors.grey1,\n },\n \"&:disabled\": {\n backgroundColor: theme.colors.clearMain,\n opacity: 0.3,\n color: theme.colors.grey1,\n }\n },\n downloadReportButtonLabel: {\n display: \"flex\",\n gap: 10,\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n columnWithTooltipLabel: {\n display: \"flex\",\n },\n columnLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 700,\n },\n columnCheckedLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: 700,\n },\n}));\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = (width?: number | string, dropDownWidth?: number | string, itemHeight?: number | string) =>\n makeStyles((theme) => ({\n select: {\n ...theme.typography.txtBody2,\n backgroundColor: theme.colors.grey1,\n height: 40,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n cursor: \"pointer\",\n width: width || 370,\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n cursor: \"pointer\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"11px\",\n marginBottom: \"11px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: \"#919CA5\"\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"11px 0px 12px 12px\",\n },\n placeholder: {\n color: \"#676767\",\n opacity: \"0.42\",\n padding: \"13px 0px 13px 12px\",\n \"&.Mui-disabled\": {\n opacity: \"0.42\",\n },\n },\n focused: {\n color: theme.colors.grey5,\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n menuPaper: {\n maxHeight: 300,\n marginTop: 6,\n width: dropDownWidth ?? 370\n },\n deleteButtonClass: {\n width: 200,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n itemContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n width: \"100%\",\n alignItems: \"center\",\n justifyContent: \"space-between\"\n },\n headerButton: {\n \"&.MuiButton-root\": {\n minWidth: 0,\n padding: 0\n },\n },\n headerButtonDisabled: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n \"& svg path\": {\n fill: Color.gray2\n }\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: itemHeight || 40,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\"\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n itemText: {\n width: \"84%\",\n textOverflow: \"ellipsis\",\n overflow: \"hidden\",\n whiteSpace: \"nowrap\",\n },\n inputError: {\n color: theme.colors.clearRed,\n border: `solid 1px ${theme.colors.clearRed}`,\n },\n group: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey4,\n height: 40,\n display: \"flex\",\n alignItems: \"center\",\n \"&.Mui-disabled\": {\n opacity: 1,\n },\n },\n deleteConfirmationModal: {\n height: \"auto !important\"\n },\n editNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5 + \" !important\",\n height: \"30px!important\"\n },\n }));\n\nexport default useStyles;","import React, { useEffect, useState } from 'react';\n\nimport MuiSelect from \"@material-ui/core/Select\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\nimport InputMUI from \"@material-ui/core/Input\";\nimport { Button } from \"@material-ui/core\";\nimport ArrowDropDownIcon from \"./../../../assets/icons/ArrowDropDownIcon\";\n\nimport useStyles from \"./css\";\nimport { SelectKeyProps } from \"./props\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\"\nimport { SectionDeleteIcon, SectionEditIcon, SectionExitEditIcon, SectionSaveIcon } from \"../../../assets/icons\";\nimport InputCustom from \"../Input\";\nimport ConfirmDeleteModal from \"../ConfirmDeleteModal\";\n\n\nconst SelectKeyEditable = (props: SelectKeyProps) => {\n const {\n value,\n setValue,\n placeholder,\n name,\n items,\n width,\n dropDownWidth,\n itemHeight,\n onChange,\n disabled,\n styleClass,\n itemRootClass,\n deleteModal,\n textButtonConfirmDelete,\n onDelete,\n setDeletableItemName,\n classes,\n isValid,\n onSave,\n arrowIcon,\n colorArrowIcon,\n menuProps\n } = props;\n const useClasses = useStyles(width, dropDownWidth, itemHeight)();\n \n const [hoveredItem, setHoveredItem] = useState<SelectItem | null>(null);\n const [editableItem, setEditableItem] = useState<SelectItem | null>(null);\n const [isEditMode, setIsEditMode] = useState<boolean>(false);\n const [deleteItemConfirmationModalIsOpen, setDeleteItemConfirmationModalIsOpen] = useState<boolean>(false);\n \n function handleMouseEnter(item: SelectItem) {\n setHoveredItem(item);\n }\n \n function handleMouseLeave() {\n setHoveredItem(null);\n }\n \n function onRenderValue(selectedId: any) {\n if (!value) {\n return placeholder;\n }\n return items.find(item => item.key === selectedId)?.value;\n }\n \n function isError(): boolean {\n if (!isValid) {\n return false;\n }\n \n if (isValid() === undefined) {\n return false;\n }\n \n return !isValid();\n }\n \n function handleOnChangeSelect(event: React.ChangeEvent<{ value: unknown }>) {\n let value = event.target.value;\n setValue(value);\n if (onChange) {\n onChange(value);\n }\n }\n \n function handleOnClose() {\n setIsEditMode(false);\n setEditableItem(null);\n }\n \n function handleOnChangeInput(event: React.ChangeEvent<{ value: unknown }>) {\n event.preventDefault();\n let newItem: SelectItem = {\n key: editableItem?.key,\n value: event.target.value\n };\n setEditableItem(newItem);\n }\n \n function handleOnFocusInput(event: any) {\n if (isEditMode) {\n event.preventDefault();\n event.stopPropagation();\n }\n }\n \n function handleEditButtonClick(e: any, item: SelectItem) {\n e.preventDefault();\n e.stopPropagation();\n setIsEditMode(true);\n setEditableItem(item);\n }\n \n async function handleOnSaveClick(e: any) {\n e.preventDefault();\n e.stopPropagation();\n setIsEditMode(false);\n setEditableItem(null);\n onSave(editableItem!);\n }\n \n function handleExitEdit(e: any) {\n e.preventDefault();\n e.stopPropagation();\n setIsEditMode(false);\n setEditableItem(null);\n }\n \n function handleTrashButtonOnClick(e: any, item: SelectItem) {\n e.preventDefault();\n e.stopPropagation();\n setEditableItem(item);\n setDeleteItemConfirmationModalIsOpen(true);\n if (setDeletableItemName) {\n setDeletableItemName(item.value);\n }\n }\n \n const EditButtons = ({ item } : { item: SelectItem }) => (\n <div>\n <Button\n key={\"editButton\"}\n onClick={(e) => handleEditButtonClick(e, item)}\n className={useClasses.headerButton}\n >\n <SectionEditIcon style={{ color: '#5C6477' }} />\n </Button>\n <Button\n onClick={(e) => handleTrashButtonOnClick(e, item)}\n className={useClasses.headerButton}\n >\n <SectionDeleteIcon style={{ color: '#5C6477' }} />\n </Button>\n </div>\n );\n \n const SaveButtons = () => (\n <div>\n <Button\n key={\"saveButton\"}\n onClick={async (e) => await handleOnSaveClick(e)}\n disabled={editableItem?.value.length < 1}\n className={useClasses.headerButton}\n >\n <SectionSaveIcon style={{ color: '#5C6477' }} />\n </Button>\n <Button\n onMouseUp={(e) => handleExitEdit(e)}\n className={useClasses.headerButton}\n >\n <SectionExitEditIcon style={{ color: '#5C6477' }} />\n </Button>\n </div>\n );\n \n function handleDeleteItem() {\n setDeleteItemConfirmationModalIsOpen(false);\n if (editableItem?.key === value) {\n setValue(null);\n }\n \n if (onDelete && editableItem) {\n onDelete(editableItem);\n }\n }\n \n function handleDeleteModalClose() {\n setDeleteItemConfirmationModalIsOpen(false);\n setEditableItem(null);\n }\n \n const ArrowIcon = (props: any) => (\n arrowIcon ? { ...arrowIcon, props } :\n <ArrowDropDownIcon\n {...props}\n style={{ top: \"inherit\", right: 12, color: colorArrowIcon ?? \"#6462F3\" }}\n />\n );\n \n return (\n <MuiSelect\n disableUnderline\n classes={\n classes || {\n root: `${useClasses.focused} ${useClasses.selected} ${isError() ? useClasses.inputError : \"\"}`,\n }\n }\n name={name}\n className={styleClass ?? useClasses.select}\n input={<InputMUI/>}\n MenuProps={menuProps ??\n {\n autoFocus: false,\n getContentAnchorEl: null,\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\",\n },\n classes: { paper: useClasses.menuPaper },\n }}\n displayEmpty\n disabled={disabled ?? false}\n onChange={handleOnChangeSelect}\n onClose={handleOnClose}\n placeholder={placeholder}\n renderValue={onRenderValue}\n value={value === undefined || value === null ? \"\" : value}\n IconComponent={ArrowIcon}\n >\n {items.map((item: SelectItem) =>\n (\n <MenuItem\n classes={{\n root: `${itemRootClass ?? useClasses.itemRoot}`,\n selected: useClasses.itemSelected,\n }}\n key={item.key}\n value={item.key}\n disabled={item?.disabled ?? false}\n onMouseEnter={() => handleMouseEnter(item)}\n onMouseLeave={handleMouseLeave}\n >\n <div className={useClasses.itemContainer}>\n <div className={useClasses.itemText}>\n {isEditMode && item.key === editableItem?.key ? (\n <InputCustom\n inputClass={useClasses.editNameInput}\n value={editableItem?.value}\n isValid={() => {\n return editableItem?.value.trim().length > 0 && editableItem?.value.length <= 200\n }}\n onKeyDown={(event) => event.stopPropagation()}\n onChange={(event) => handleOnChangeInput(event)}\n onClick={(event) => handleOnFocusInput(event)}\n width={\"100%\"}\n autoFocus\n />\n ) : (\n item.value\n )}\n </div>\n \n {!isEditMode && hoveredItem && hoveredItem.key === item.key && <EditButtons item={item}/>}\n {isEditMode && editableItem?.key === item.key && <SaveButtons/>}\n </div>\n </MenuItem>\n )\n )}\n <ConfirmDeleteModal\n classModal={useClasses.deleteConfirmationModal}\n open={deleteItemConfirmationModalIsOpen}\n item={editableItem}\n textButtonConfirm={textButtonConfirmDelete}\n classButton={useClasses.deleteButtonClass}\n componentInfo={deleteModal}\n onClose={handleDeleteModalClose}\n onDelete={handleDeleteItem}\n />\n </MuiSelect>\n );\n};\n\nexport default SelectKeyEditable;\n","import OrderedReportProperty from \"./ordered-report-property\";\n\nexport class CustomReportPreviewRequest {\n dateFrom: Date;\n dateTo: Date;\n primaryPropertyId: string;\n properties: OrderedReportProperty[];\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.dateFrom = x.dateFrom;\n this.dateTo = x.dateTo;\n this.primaryPropertyId = x.primaryPropertyId;\n this.properties = x.properties;\n } else {\n this.dateFrom = new Date();\n this.dateTo = new Date();\n this.primaryPropertyId = \"\";\n this.properties = [];\n }\n }\n}","export default class OrderedReportProperty {\n order: number;\n id: string;\n\n constructor(order: number, id: string) {\n this.order = order;\n this.id = id;\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n height: \"auto\",\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n },\n },\n modalHeader: {\n ...theme.typography.txtBody1,\n fontWeight: 700\n },\n inputInvalid: {\n borderColor: \"#F15857!important\"\n },\n cancelModalContainer: {\n textAlign: \"center\"\n },\n infoContent: {\n marginTop: 10,\n marginLeft: -6,\n display: \"flex\",\n gap: 5,\n alignItems: \"center\",\n \n fontFamily: \"Roboto\",\n fontSize: \"11px\",\n fontStyle: \"normal\",\n fontWeight: 400,\n lineHeight: \"normal\",\n color: \"#6A6E72\"\n },\n cancelModalContent: {\n fontFamily: \"Roboto\",\n fontSize: \"11px\",\n fontStyle: \"normal\",\n fontWeight: 400,\n lineHeight: \"normal\",\n color: \"#6A6E72\"\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\"\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalContent: {},\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentTextTitle: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: theme.colors.grey5\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"center\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: theme.colors.grey4, //Color.gray4,\n fontSize: 12,\n fontWeight: \"bold\"\n },\n confirmButton: {\n fontWeight: \"bold\",\n fontSize: 12,\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n \"&:disabled\": {\n opacity: 0.5,\n }\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\nimport { Typography } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { SaveReportModalProps } from \"./props\";\nimport { InfoIcon } from \"../../../assets/icons\";\nimport InputWithLabel from \"../../common/InputWithLabel\";\nimport ConfirmActionModal from \"../../common/ConfirmActionModal\";\n\n\nexport default function SaveReportModal(props: SaveReportModalProps) {\n \n const { t } = useTranslation([\"general\"]);\n const { open, onClose, onConfirm, checkNameIsInvalid } = props;\n const classes = useStyles();\n \n const [reportName, setReportName] = useState<string>(\"\");\n const [cancelSaveModalOpen, setCancelSaveModalOpen] = useState<boolean>(false);\n const [nameIsInvalid, setNameIsInvalid] = useState<boolean>(false);\n \n function handleConfirm() {\n onConfirm(reportName);\n }\n \n function handleClose() {\n setNameIsInvalid(false);\n setReportName(\"\");\n setCancelSaveModalOpen(false);\n onClose();\n }\n \n function handleClickGoBack() {\n if(reportName.length < 1) {\n handleClose()\n return;\n }\n setCancelSaveModalOpen(true);\n }\n \n function handleOnInputChange(event: React.ChangeEvent<{ value: string }>) {\n let reportName = event.target.value;\n setNameIsInvalid(checkNameIsInvalid(reportName));\n setReportName(reportName);\n }\n \n const CancelSaveReportModalContent: React.FC = () => {\n return (\n <div className={classes.cancelModalContainer}>\n <Typography style={{marginBottom: 8}} className={classes.modalHeader}>\n {t(\"Cancel custom report creation?\")}\n </Typography>\n <Typography className={classes.cancelModalContent}>\n {t(\"Unsaved changes will be lost.\")}\n </Typography>\n </div>);\n };\n \n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={`${classes.modal}`}\n open={open}\n onClose={handleClickGoBack}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}>\n <Fade in={open}>\n <div className={`${classes.modalPaper}`}>\n <div style={{marginBottom: 24}} className={classes.modalHeader}>\n {t(\"Save custom report\")}\n </div>\n <div className={classes.modalContent}>\n <InputWithLabel\n label={() => (\n <>\n {t(\"Report name\")} <span style={{ color: \"#6462F3\" }}> *</span>\n </>\n )}\n value={reportName}\n inputClass={nameIsInvalid && classes.inputInvalid}\n maxLength={180}\n placeholder={t(\"Enter the name of your custom report\")}\n onChange={handleOnInputChange}\n width={416}\n >\n </InputWithLabel>\n \n <div className={classes.infoContent}>\n <InfoIcon\n style={{ width: 17, height: 16, marginLeft: 5, color: \"#6462F3\" }}\n viewBox={\"0 0 12 12\"}\n />\n {nameIsInvalid \n ? t(\"There is already a report with the same name. Please write another name.\") \n : t(\"This report will be saved for easy future reference.\")}\n </div>\n <div className={classes.modalActions}>\n <Button className={`${classes.button} ${classes.goBack}`} onClick={handleClickGoBack}>\n {t(\"Go back\")}\n </Button>\n \n <Button \n className={`${classes.button} ${classes.confirmButton}`} \n disabled={reportName.length < 1 || nameIsInvalid} \n onClick={handleConfirm}>\n {t(\"Save report\")}\n </Button>\n </div>\n \n </div>\n <ConfirmActionModal\n open={cancelSaveModalOpen}\n content={<CancelSaveReportModalContent/>}\n onClose={() => setCancelSaveModalOpen(false)}\n onConfirm={handleClose}\n confirmButtonText={t(\"Yes, cancel\")}\n buttonClass={classes.button}\n />\n </div>\n </Fade>\n </Modal>\n );\n}","import OrderedReportProperty from \"./ordered-report-property\";\n\nexport class EnterpriseCustomReportPreviewRequest {\n dateFrom: Date;\n dateTo: Date;\n primaryPropertyId: string;\n properties: OrderedReportProperty[];\n establishmentIds: string[];\n \n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.dateFrom = x.dateFrom;\n this.dateTo = x.dateTo;\n this.primaryPropertyId = x.primaryPropertyId;\n this.properties = x.properties;\n this.establishmentIds = x.establishmentIds;\n } else {\n this.dateFrom = new Date();\n this.dateTo = new Date();\n this.primaryPropertyId = \"\";\n this.properties = [];\n this.establishmentIds = [];\n }\n }\n}","import React, { useEffect, useState } from 'react';\n\nimport { Trans, useTranslation } from \"react-i18next\";\n\nimport { DragDropContext, Droppable, DropResult } from \"react-beautiful-dnd\";\n\nimport { useDispatch } from \"react-redux\";\nimport { useAppSelector } from \"../../../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../../../redux/store\";\nimport { applicationInterfaceActions } from \"../../../../../redux/application-interface-slice\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { fileDownloadActions } from \"../../../../../redux/file-downloader-slice\";\n\nimport { Box, Button, CircularProgress, FormControlLabel, Grid, RadioGroup, Typography } from \"@material-ui/core\";\nimport Modal from \"@material-ui/core/Modal\";\n\nimport useStyles from \"./css\";\nimport useControlLabel from \"../../../../../hooks/useControlLabel\";\nimport DateInput from \"../../../../common/DateInput\";\nimport { SelectItem } from \"../../../../../models/interfaces/select-item\";\nimport { Report } from \"../../../../../models/report\";\nimport SelectKeyEditable from \"../../../../common/SelectKeyEditable\";\nimport DotsVerticalIcon from \"../../../../../assets/icons/DotsVerticalIcon\";\nimport ReportsNavTabs from \"../../../ReportsNavTabs\";\nimport { ReportsService } from \"../../../../../api/reports-service\";\nimport { ReportColumn, ReportColumnGroup } from \"../../../../../models/report-column\";\nimport CheckboxWithLabel from \"../../../../common/CheckboxWithLabel\";\nimport Radio from \"../../../../common/Radio\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport { CloseIcon, InfoIcon, ReportPersonIcon, TrashIcon } from \"../../../../../assets/icons\";\nimport DraggableBase from \"../../../../common/DraggableBase\";\nimport InputSearch from \"../../../../common/InputSearch\";\nimport { CustomReportPreviewRequest } from '../../../../../models/custom-report-preview-request';\nimport moment from \"moment/moment\";\nimport OrderedReportProperty from '../../../../../models/ordered-report-property';\nimport SaveReportModal from \"../../../SaveReportModal\";\nimport ConfirmActionModal from \"../../../../common/ConfirmActionModal\";\nimport GridList from \"../../../../common/grid/GridList\";\nimport { TableColumn } from \"../../../../common/grid/table-column\";\nimport { ColumnGroupNameId } from \"../../../../../models/enums/report-column-id\";\nimport SearchIcon from \"../../../../../assets/icons/SearchIcon\";\nimport EstablishmentsToolbar from \"../../../../common/EstablishmentsToolbar\";\nimport { EnterpriseCustomReportPreviewRequest } from \"../../../../../models/enterprise-custom-report-preview-request\";\n\n\nexport default function CustomReportsPage() {\n \n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n const dispatch = useDispatch();\n\n const { enqueueAlert } = alertsActions;\n const { startDownload } = fileDownloadActions;\n const { updateIsWideLayout } = applicationInterfaceActions;\n \n const todayDate = new Date();\n const lastMonthDate = addMonths(new Date(), -1);\n const nextDayOfLastMonthDate = new Date();\n \n const [openModalActionDots, setOpenModalActionDots] = useState<boolean>(false);\n const [saveReportModalIsOpen, setSaveReportModalIsOpen] = useState<boolean>(false);\n const [cancelEditReportModalIsOpen, setCancelEditReportModalIsOpen] = useState<boolean>(false);\n \n const [startDate, setStartDate] = useState<Date>(lastMonthDate);\n const [endDate, setEndDate] = useState<Date>(nextDayOfLastMonthDate);\n \n const [reports, setReports] = useState<Report[]>([]);\n const [selectedReport, setSelectedReport] = useState<Report | null>(null);\n const [deletableReportName, setDeletableReportName] = useState<string>(\"\");\n \n const [columnGroups, setColumnGroups] = useState<ReportColumnGroup[]>([]);\n const [selectedColumns, setSelectedColumns] = useState<ReportColumn[]>([]);\n const [primaryColumn, setPrimaryColumn] = useState<ReportColumn | null>(null);\n const [previewGridData, setPreviewGridData] = useState<{ [key: string]: string }[]>();\n \n const [columnSearchQuery, setColumnSearchQuery] = useState<string>(\"\");\n \n const selectedEstablishments = useAppSelector(state => state.enterprise.selectedEstablishments); \n const noSavedReports = new Report({\n id: \"NoSavedReports\",\n name: t(\"No saved reports\")\n });\n \n const allColumns = columnGroups.flatMap(group => group.columns);\n \n const selectItems: SelectItem[] = reports.map(report => ({\n key: report.id,\n value: report.name,\n disabled: report.id === noSavedReports.id\n }));\n \n const isDownloading = useAppSelector(state => state.fileDownloader.isDownloading);\n \n const locale = useAppSelector(state => state.applicationInterface.locale);\n const accountSettings = useAppSelector(selectAccountSettings);\n const accountName = accountSettings.accountName;\n \n const dateFormatPlaceholder = locale === \"en\" ? \"mm/dd/yy\" : \"dd/mm/yy\";\n const dateFormat = locale === \"en\" ? \"MM/dd/yy\" : \"dd/MM/yy\";\n const fileDateFormat = locale === \"en\" ? \"MM-DD-YYYY\" : \"DD-MM-YYYY\";\n \n const StartDateLabel = useControlLabel({ label: t(\"Start date\"), required: true, labelClass: classes.dateLabel, })\n const EndDateLabel = useControlLabel({ label: t(\"End date\"), required: true, labelClass: classes.dateLabel, })\n \n function addDays(date: Date, days: number): Date {\n let result = new Date(date);\n result.setDate(result.getDate() + days);\n return result;\n }\n \n function addMonths(date: Date, months: number): Date {\n let result = new Date(date);\n result.setMonth(result.getMonth() + months);\n return result;\n }\n \n useEffect(() => {\n dispatch(updateIsWideLayout(true));\n });\n \n useEffect(() => {\n (async () => {\n await loadReports();\n await loadColumns();\n })();\n }, []);\n \n useEffect(() => {\n (async () => {\n if (primaryColumn) {\n await loadPreview();\n }\n })();\n }, [selectedColumns.length, primaryColumn, startDate, endDate, selectedEstablishments]);\n \n \n async function loadPreview() {\n dispatch(navbarActions.setShowLoader(true));\n const requestData = {\n dateFrom: ReportsService.handleTime(startDate),\n dateTo: ReportsService.handleTime(endDate),\n primaryPropertyId: primaryColumn?.id!,\n properties: selectedColumns.map(c => new OrderedReportProperty(c.order, c.id))\n };\n const establishmentIds = selectedEstablishments || [];\n \n const reportsData = !accountSettings.isEnterprise\n ? await ReportsService.getCustomReportPreview(new CustomReportPreviewRequest(requestData))\n : await ReportsService.getEnterpriseCustomReportPreview(new EnterpriseCustomReportPreviewRequest({ ...requestData, establishmentIds }));\n dispatch(navbarActions.setShowLoader(false));\n \n const properties = reportsData.properties.sort((s1, s2) => s1.order! - s2.order!);\n const transformedData = reportsData.dataTable.map(row => transformPreviewRowData(row, properties));\n setPreviewGridData(transformedData);\n }\n \n function transformPreviewRowData(row: Record<string, any>[], properties: OrderedReportProperty[]) {\n const rowData: { [key: string]: any } = {};\n row.forEach((cell, index) => {\n const propertyId = properties[index].id;\n rowData[propertyId] = cell.value;\n });\n return rowData;\n }\n \n function getResultString(numberOfResults: number | undefined) {\n if (!numberOfResults) return '0';\n if (numberOfResults < 20) return `${numberOfResults}`;\n return `20+`;\n }\n \n function createPreviewGridColumn(reportColumn: ReportColumn): TableColumn {\n const countResults = (id: string) => previewGridData?.filter((entry: Record<string, any>) => entry[id] !== null);\n const keyExists = (id: string) => previewGridData?.some(obj => obj.hasOwnProperty(id));\n \n const numberOfResults = countResults(reportColumn.id);\n const shouldShowResults = numberOfResults !== undefined && keyExists(reportColumn.id);\n \n return {\n id: reportColumn.id,\n label: (\n <div>\n {reportColumn.name.toUpperCase()}\n <br />\n {shouldShowResults && (\n <span className={classes.totalResultText}>\n {`${getResultString(numberOfResults?.length)} ${t('results')}`}\n </span>\n )}\n </div>\n ),\n sorting: false,\n width: 180,\n maxWidth: 180,\n minWidth: 180,\n headerTextAlign: 'center',\n rowStyle: { whiteSpace: 'nowrap', overflow: 'hidden', textOverflow: 'ellipsis' },\n cellStyle: { borderRight: '1px solid rgba(224, 224, 224, 1)' },\n cellHeaderStyle: { borderRight: '1px solid rgba(224, 224, 224, 1)' },\n };\n }\n \n function getPreviewGridColumns(): TableColumn[] {\n const updatedColumns: TableColumn[] = selectedColumns\n .sort((a, b) => a.order - b.order)\n .map(createPreviewGridColumn);\n \n if (primaryColumn) {\n updatedColumns.unshift(createPreviewGridColumn(primaryColumn));\n }\n return updatedColumns;\n }\n \n const previewGridColumns: TableColumn[] = getPreviewGridColumns();\n \n async function loadReports() {\n dispatch(navbarActions.setShowLoader(true));\n let reportsData = await ReportsService.getCustomReportsList();\n if (reportsData.length === 0) {\n reportsData.push(noSavedReports);\n } else {\n reportsData.forEach(report => {\n report.properties.forEach(property => {\n property.name = t(property.name);\n });\n });\n }\n \n dispatch(navbarActions.setShowLoader(false));\n setReports(reportsData);\n }\n \n async function loadColumns() {\n dispatch(navbarActions.setShowLoader(true));\n let columnsData = await ReportsService.getCustomReportsColumnList();\n if (!accountSettings.isEnterprise) {\n columnsData = columnsData.filter(item => item.id !== ColumnGroupNameId.GeneralInformation);\n }\n let translatedColumnGroups = translateNames(columnsData);\n setColumnGroups(translatedColumnGroups);\n dispatch(navbarActions.setShowLoader(false));\n }\n \n function translateNames(columnsData: ReportColumnGroup[]): ReportColumnGroup[] {\n return columnsData.map((grouped) => {\n grouped.name = t(grouped.name);\n grouped.columns = grouped.columns.map((column) => {\n column.name = t(column.name);\n return column;\n });\n return grouped;\n });\n }\n \n async function onSaveReportName(item: SelectItem) {\n dispatch(navbarActions.setShowLoader(true));\n let updatedReport = await ReportsService.renameCustomReport(item.key, item.value);\n dispatch(navbarActions.setShowLoader(false));\n if (updatedReport) {\n if (selectedReport?.id === item.key) {\n const updatedReport = { ...selectedReport, name: item.value } as Report;\n setSelectedReport(updatedReport);\n }\n const updatedReports = reports.map(report => {\n if (report.id === updatedReport.id) {\n return { ...report, name: updatedReport.name };\n }\n return report;\n });\n setReports(updatedReports);\n }\n }\n \n async function onDeleteReport(item: SelectItem) {\n dispatch(navbarActions.setShowLoader(true));\n let data = await ReportsService.deleteCustomReport(item.key);\n dispatch(navbarActions.setShowLoader(false));\n if (data) {\n const updatedReports = reports.filter(report => report.id !== item.key);\n \n if (updatedReports.length === 0) {\n updatedReports.push(noSavedReports);\n }\n \n if (item.key === selectedReport?.id) {\n setPrimaryColumn(null);\n setSelectedColumns([]);\n }\n \n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Report deleted\"),\n description: deletableReportName,\n })\n );\n \n setReports(updatedReports);\n }\n }\n \n const DeleteModalContent = () => {\n return (\n <div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete custom report?\")}\n </Typography>\n <div className={classes.separator}/>\n <Typography className={classes.deleteModalContentReportName}>\n {deletableReportName}\n </Typography>\n <Typography className={classes.deleteModalContentText}>\n {t(\"This report will be permanently deleted.\")}\n </Typography>\n </div>\n );\n }\n\n function getReportFileName(startDate: Date, endDate: Date, reportName?: string) {\n const startDateFormatted = moment(startDate).format(fileDateFormat)\n const endDateFormatted = moment(endDate).format(fileDateFormat)\n const reportNameString = reportName ? ` ${reportName} -` : \"\"\n return `${t(\"Custom report\")} -${reportNameString} ${startDateFormatted} - ${endDateFormatted}`;\n }\n \n async function handleDownloadReportClick() {\n const reportName = selectedReport?.name;\n const fileName = `${getReportFileName(startDate, endDate, reportName)}.xlsx`;\n const mimeType = \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml\";\n \n const downloadFunction = accountSettings.isEnterprise\n ? ReportsService.downloadEnterpriseCustomReport(startDate, endDate, primaryColumn!.id, selectedColumns.map(c => new OrderedReportProperty(c.order, c.id)), reportName ?? null, selectedEstablishments || [])\n : ReportsService.downloadCustomReport(startDate, endDate, primaryColumn!.id, selectedColumns.map(c => new OrderedReportProperty(c.order, c.id)), reportName ?? null);\n \n dispatch(startDownload({ fileName, mimeType, callback: downloadFunction }));\n }\n \n function handleCheckColumn(column: ReportColumn) {\n let updatedSelectedColumns = [...selectedColumns];\n \n let columnCurrentIndex = updatedSelectedColumns.findIndex(col => col.id === column.id);\n if (columnCurrentIndex !== -1) {\n updatedSelectedColumns.splice(columnCurrentIndex, 1);\n } else {\n const maxOrder = Math.max(...updatedSelectedColumns.map(c => c.order))\n updatedSelectedColumns.push(new ReportColumn({\n id: column.id,\n name: column.name,\n order: maxOrder + 1\n }));\n }\n \n updatedSelectedColumns.sort((a, b) => a.order - b.order);\n updatedSelectedColumns.forEach((column, index) => {\n column.order = index + 1;\n });\n \n setSelectedColumns(updatedSelectedColumns);\n }\n \n function dragEndHandler(result: DropResult) {\n const { destination, source, draggableId } = result;\n if (!destination)\n return;\n if (destination.droppableId !== source.droppableId)\n return;\n if (destination.droppableId === source.droppableId && destination.index === source.index)\n return;\n const prevOrder = source.index + 1;\n const newOrder = destination.index + 1;\n \n let reorderedColumns = getReorderedColumns(selectedColumns, prevOrder, newOrder, draggableId);\n \n setSelectedColumns(reorderedColumns);\n }\n \n function getReorderedColumns(columns: ReportColumn[], prevOrder: number, newOrder: number, movedColumnId: string) {\n const result = Array.from(columns);\n const positionsMoved = newOrder - prevOrder;\n const isMovedDown = positionsMoved > 0;\n const affectedFieldIds = isMovedDown\n ? columns.filter(f => f.id === movedColumnId ||\n f.order! <= newOrder &&\n f.order! >= prevOrder)\n .map(f => f.id)\n : columns.filter(f => f.id === movedColumnId ||\n f.order! >= newOrder &&\n f.order! <= prevOrder)\n .map(f => f.id);\n \n result.forEach(f => {\n if (!affectedFieldIds.includes(f.id!))\n return;\n if (f.id === movedColumnId) {\n f.order = newOrder;\n return;\n }\n f.order = isMovedDown ? f.order! - 1 : f.order! + 1;\n });\n \n return result;\n }\n \n function handlePrimaryColumnCheck(key: string) {\n let updatedSelectedColumns = [...selectedColumns];\n const selectedColumn = allColumns.find(column => column.id === key)!;\n\n const columnCurrentIndex = updatedSelectedColumns.findIndex(col => col.id === key);\n \n if (columnCurrentIndex !== -1) {\n updatedSelectedColumns.splice(columnCurrentIndex, 1);\n }\n \n updatedSelectedColumns.sort((a, b) => a.order - b.order);\n updatedSelectedColumns.forEach((column, index) => {\n column.order = index + 1;\n });\n \n setSelectedColumns(updatedSelectedColumns);\n selectedColumn.order = 0;\n setPrimaryColumn(selectedColumn);\n }\n \n async function handleSaveReportButtonClick() {\n if (selectedReport) {\n await updateCustomReport();\n }\n else {\n setSaveReportModalIsOpen(true);\n }\n }\n \n function nameAlreadyExist(reportName: string) {\n return reports.flatMap(x => x.name.toLowerCase().trim()).includes(reportName.toLowerCase().trim());\n }\n \n function onDeleteClick(id: string) {\n const columnIndex = selectedColumns.findIndex(column => column.id === id);\n \n if (columnIndex !== -1) {\n const updatedSelectedColumns = [...selectedColumns];\n updatedSelectedColumns.splice(columnIndex, 1);\n updatedSelectedColumns.sort((a, b) => a.order - b.order);\n updatedSelectedColumns.forEach((column, index) => {\n column.order = index + 1;\n });\n \n setSelectedColumns(updatedSelectedColumns);\n }\n }\n \n async function updateCustomReport() {\n dispatch(navbarActions.setShowLoader(true));\n let updatedReport = await ReportsService.updateCustomReport(\n primaryColumn!.id,\n selectedColumns.map(c => new OrderedReportProperty(c.order, c.id)),\n selectedReport?.id!);\n dispatch(navbarActions.setShowLoader(false));\n if (updatedReport) {\n let updatedReports = reports.map(report => {\n if (report.id === updatedReport.id) {\n return {\n ...report,\n name: updatedReport.name,\n properties: updatedReport.properties.map(prop => {return { ...prop, name: t(prop.name), };}),\n };\n }\n return report;\n });\n setReports(updatedReports);\n setSaveReportModalIsOpen(false);\n setOpenModalActionDots(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Updated report\"),\n description: updatedReport.name,\n })\n );\n }\n }\n \n async function saveCustomReport(reportName: string) {\n let newReport = await ReportsService.createCustomReport(\n primaryColumn!.id,\n selectedColumns.map(c => new OrderedReportProperty(c.order, c.id)),\n reportName);\n if (newReport) {\n let updatedReports = [...reports.filter(item => item.id !== noSavedReports.id)];\n newReport.properties.forEach(prop => {\n prop.name = t(prop.name)\n });\n updatedReports.push(newReport);\n setReports(updatedReports);\n setSelectedReport(newReport);\n setSaveReportModalIsOpen(false);\n setOpenModalActionDots(false);\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Saved report\"),\n description: newReport.name,\n })\n );\n }\n }\n \n function handleCancelButtonClick() {\n setCancelEditReportModalIsOpen(true);\n }\n \n function handleNewReportButtonClick() {\n setPrimaryColumn(null);\n setSelectedColumns([]);\n setSelectedReport(null);\n setOpenModalActionDots(false);\n }\n \n function searchInputResultNotFound(): boolean {\n let primaryColumnsResultNotFound = columnGroups\n .filter(group => group.columns.filter(x => x.isPrimary)\n .some(column => column.name.toLowerCase()\n .includes(columnSearchQuery.toLowerCase()))).length === 0;\n let columnsResultNotFound = columnGroups\n .filter(group => group.columns\n .some(column => column.name.toLowerCase()\n .includes(columnSearchQuery.toLowerCase()))).length === 0;\n return columnSearchQuery !== \"\" && primaryColumnsResultNotFound && columnsResultNotFound;\n }\n \n function handleCancel() {\n if (selectedReport) {\n const initialStateColumns = reports.find(report => report.id === selectedReport?.id)?.properties;\n setSelectedColumns(initialStateColumns?.filter(col => col.order !== 0)!);\n setPrimaryColumn(initialStateColumns?.find(col => col.order === 0)!);\n }\n else {\n setPrimaryColumn(null);\n setSelectedColumns([]);\n }\n setCancelEditReportModalIsOpen(false);\n setOpenModalActionDots(false);\n }\n \n function handleSetSelectedReport(selectedReportKey: string) {\n let report = reports.find(x => x.id === selectedReportKey);\n setSelectedReport(report!);\n }\n \n function handleOnChangeSelectedReport(selectedReportKey: string) {\n let primaryColumnInfo = reports.find(x => x.id === selectedReportKey)?.properties.find(x => x.isPrimary);\n let primaryColumn = new ReportColumn({\n id: primaryColumnInfo?.id,\n isPrimary: true,\n order: primaryColumnInfo?.order,\n name: t(primaryColumnInfo!.name),\n });\n setPrimaryColumn(primaryColumn);\n \n let selectedColumnInfo = reports.find(x => x.id === selectedReportKey)?.properties.filter(x => !x.isPrimary);\n let selectedColumns = selectedColumnInfo?.map(column => new ReportColumn({\n id: column?.id,\n isPrimary: false,\n order: column?.order,\n name: t(column!.name),\n }));\n setSelectedColumns(selectedColumns ?? []);\n }\n \n function isColumnStateChanged(): boolean {\n const initialStateColumns = reports\n .find(report => report.id === selectedReport?.id)?.properties\n .filter(item => item.order !== 0)\n .map(({ isPrimary, name, ...rest }) => rest);\n \n const currentStateColumns = selectedColumns.map(({ isPrimary, name, ...rest }) => rest);\n \n if (!initialStateColumns || !currentStateColumns) {\n return true;\n }\n \n const initialPrimaryColumn = reports\n .find(report => report.id === selectedReport?.id)?.properties\n .find(item => item.order === 0);\n \n if (initialPrimaryColumn && initialPrimaryColumn.id !== primaryColumn?.id) {\n return true;\n }\n \n if (initialStateColumns.length !== currentStateColumns.length) {\n return true;\n }\n \n initialStateColumns.sort((a, b) => a.order - b.order);\n currentStateColumns.sort((a, b) => a.order - b.order);\n \n return initialStateColumns.some((col, index) => JSON.stringify(col) !== JSON.stringify(currentStateColumns[index]));\n }\n \n const CancelEditModalContent: React.FC = () => {\n return (\n <div className={classes.cancelModalContainer}>\n <Typography style={{marginBottom: 8}} className={classes.modalHeader}>\n {selectedReport ? t(\"Cancel custom report editing?\") : t(\"Cancel custom report creation?\")}\n </Typography>\n <Typography className={classes.cancelModalContent}>\n {t(\"Unsaved changes will be lost.\")}\n </Typography>\n </div>);\n };\n \n const ColumnNotFoundContent: React.FC = () => {\n return (\n <div className={classes.columnNotFoundContainer}>\n <SearchIcon style={{ color: \"#919CA5\", height: 50, width: 50 }}/>\n <div className={classes.columnNotFoundCaptionBold}>{t(\"Column not found...\")}</div>\n <div className={classes.columnNotFoundCaption}>{t(\"Try again with a different column\")}</div>\n </div>);\n };\n \n const mapItemsToComponents = (items: any[]) => {\n return items.sort((i1, i2) => i1.order! - i2.order!).map(i =>\n <div>\n <DraggableBase\n key={i.id.toString()}\n className={classes.draggableClassName}\n innerContainerClass={classes.draggableInnerContainer}\n height={48}\n isRemovable={true}\n mainBoxClass={classes.mainBoxClass}\n draggableId={i.id.toString()}\n index={i.order - 1}\n onDeleteClick={() => onDeleteClick(i.id!)}\n isEditable={true}\n isShowActionOnMouseHover={true}\n closeIcon={<CloseIcon style={{ color: \"#5C6477\" }} viewBox={\"0 0 14 5\"}/>}\n >\n {i.name}\n </DraggableBase>\n </div>\n )\n }\n\n const getColumnLabel = (column: ReportColumn) => {\n if (!column.tooltip) return column.name;\n\n const checked = selectedColumns.some(selectedColumn => selectedColumn.id === column.id) || column.id === primaryColumn?.id;\n\n return (\n <div className={classes.columnWithTooltipLabel}>\n <span>{column.name}</span>\n <IconTooltip\n placement={\"right\"}\n arrowPlacement={\"right\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginLeft: 2, color: \"#6462F3\" }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(column.tooltip)}\n />\n </div>\n )\n }\n \n return (\n <div className={classes.root}>\n <ReportsNavTabs/>\n <EstablishmentsToolbar />\n <div className={classes.mainContainer}>\n <div className={classes.inputsBlock}>\n <div className={classes.controlWithLabel}>\n <StartDateLabel/>\n <DateInput\n width={158}\n placeholder={t(dateFormatPlaceholder)}\n format={dateFormat}\n value={startDate}\n onChange={setStartDate}\n maxDate={todayDate}\n inputTextClass={classes.dateInputText}\n iconColor={\"#ACB7C0\"}\n />\n </div>\n <div className={classes.controlWithLabel}>\n <EndDateLabel/>\n <DateInput\n width={158}\n placeholder={t(dateFormatPlaceholder)}\n format={dateFormat}\n value={endDate}\n onChange={setEndDate}\n minDate={startDate}\n maxDate={todayDate}\n inputTextClass={classes.dateInputText}\n iconColor={\"#ACB7C0\"}\n />\n </div>\n <div className={classes.reportTypeSelect}>\n <SelectKeyEditable\n key={selectedReport?.id}\n value={selectedReport?.id}\n onSave={onSaveReportName}\n deleteModal={<DeleteModalContent/>}\n onDelete={onDeleteReport}\n setValue={handleSetSelectedReport}\n itemRootClass={classes.itemRootClass}\n onChange={handleOnChangeSelectedReport}\n setDeletableItemName={setDeletableReportName}\n items={selectItems}\n width={348}\n dropDownWidth={348}\n placeholder={t(\"Select a report\")}\n textButtonConfirmDelete={t(\"Delete report\")}\n />\n </div>\n \n </div>\n <div className={classes.downloadReportButtonBlock}>\n <Button\n className={classes.downloadReportButton}\n disabled={isDownloading || !primaryColumn}\n onClick={handleDownloadReportClick}\n >\n {\n <span className={classes.downloadReportButtonLabel}>\n {isDownloading\n ? <CircularProgress size=\"1rem\" style={{ color: \"#FFFFFF\" }}/>\n : null\n }\n {t(\"Download report\")}\n </span>\n }\n </Button>\n <span>\n <span >\n <DotsVerticalIcon\n color=\"#5C6477\"\n style={{ cursor: primaryColumn ? \"pointer\" : \"auto\" }}\n onClick={() => {\n if (!primaryColumn) return\n setOpenModalActionDots(true)\n }}\n />\n <Modal\n open={openModalActionDots}\n onClose={() => setOpenModalActionDots(false)}\n aria-labelledby=\"modal-modal-title\"\n aria-describedby=\"modal-modal-description\"\n BackdropProps={{ style: { backgroundColor: \"transparent\" } }}\n disablePortal={true}\n style={{ position: \"relative\", top: 0 }}>\n <div className={classes.modalActionsAppt}>\n <div className={`${classes.modalActionFont} ${!isColumnStateChanged() && classes.disabledButton}`} \n onClick={isColumnStateChanged() ? handleSaveReportButtonClick : undefined}>\n {selectedReport ? t(\"Save changes\") : t(\"Save report\")} \n </div>\n <div className={`${classes.modalActionFont} ${selectedColumns.length === 0 && !primaryColumn && classes.disabledButton}`} \n onClick={handleNewReportButtonClick}>\n {t(\"New report\")}\n </div>\n <div className={`${classes.modalActionFont} ${!isColumnStateChanged() && classes.disabledButton}`} \n onClick={isColumnStateChanged() ? handleCancelButtonClick : undefined}>\n {t(\"Cancel\")}\n </div>\n </div>\n </Modal>\n </span>\n </span>\n </div>\n </div>\n <div className={classes.bottomRoot}>\n <div className={classes.columnsContainer}>\n <div className={classes.columnsHeader}>\n {t(\"COLUMNS\")}\n </div>\n <div className={classes.inputSearchContainer}>\n <InputSearch\n value={columnSearchQuery}\n inputSearchClass={classes.inputSearchClass}\n placeholder={t(\"Search column\")}\n rootClass={classes.inputSearchRoot}\n onReset={() => setColumnSearchQuery(\"\")}\n onChange={(e: any) => setColumnSearchQuery(e.target.value)}\n />\n </div>\n {searchInputResultNotFound() && <ColumnNotFoundContent/>}\n <div className={classes.scrollColumnsArea}>\n {!searchInputResultNotFound() && <div className={classes.selectedColumnsBox}>\n {primaryColumn &&\n <div style={{ marginTop: 10 }} className={classes.groupHeader}>\n <div style={{ width: \"max-content\" }}>{t(\"Selected columns\")}</div>\n <IconTooltip\n key={\"selectedColumnsTooltip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"bottom\"}\n arrowPlacement={\"top\"}\n icon={<InfoIcon style={{ width: 17, height: 16, marginLeft: 5, color: \"#6462F3\" }}\n viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"These columns will appear in the personalized report you create\")}\n />\n </div>\n }\n <DragDropContext onDragEnd={dragEndHandler}>\n <Droppable key={\"drop_selected_columns_id\"} droppableId={\"drop_selected_columns_id\"}>\n {(provided) => (\n <Box style={{ width: \"100%\" }}>\n <div className={classes.sectionContainer}>\n <Grid\n container\n justifyContent=\"center\"\n className={classes.sectionLayout}\n ref={provided.innerRef}\n {...provided.droppableProps}\n >\n {primaryColumn?.name && (\n <span style={{ marginLeft: 6, marginBottom: 5 }}> {primaryColumn?.name}{' '}\n <span style={{ color: '#6462F3' }}> {\"(\" + t(\"Primary\") + \")\"}\n </span>\n </span>\n )}\n {mapItemsToComponents(selectedColumns)}\n {provided.placeholder}\n </Grid>\n </div>\n </Box>\n )}\n </Droppable>\n </DragDropContext>\n </div>}\n \n \n <div>\n {columnGroups.filter(group => group.columns.filter(x => x.isPrimary)\n .some(column => column.name.toLowerCase().includes(columnSearchQuery.toLowerCase()))\n ).length > 0 &&\n <div className={classes.groupHeader}>\n <div style={{ width: \"max-content\" }}>{t(\"Primary column\")}</div>\n <IconTooltip\n key={\"primaryColumnTooltip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"bottom\"}\n arrowPlacement={\"top\"}\n icon={<InfoIcon style={{ width: 17, height: 16, marginLeft: 5, color: \"#6462F3\" }}\n viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"You must select a primary column\")}\n />\n </div>\n }\n <RadioGroup\n className={classes.radioGroup}\n defaultValue={-1}\n value={primaryColumn?.id ?? -1}\n aria-label={\"Primary column\"}\n name={\"Primary column\"}\n onChange={(event) => handlePrimaryColumnCheck(event.target.value)}\n >\n {columnGroups\n .filter(group => group.columns.some(column => column.isPrimary))\n .filter(group => group.columns.filter(x => x.isPrimary).some(column => column.name.toLowerCase().includes(columnSearchQuery.toLowerCase())))\n .sort((a, b) => a.order - b.order)\n .map((group) => {\n const primaryColumn = group.columns.find((column) => column.isPrimary);\n \n return (\n <FormControlLabel\n classes={{\n root: classes.radioLabelRoot,\n label: classes.radioLabel,\n }}\n key={primaryColumn?.id}\n value={primaryColumn?.id}\n control={\n <Radio\n className={classes.radioOption}\n />\n }\n label={primaryColumn?.name}\n />\n );\n })\n }\n </RadioGroup>\n </div>\n \n \n {columnGroups\n .filter(group => group.columns.some(column => column.name.toLowerCase().includes(columnSearchQuery.toLowerCase())))\n .sort((a, b) => a.order - b.order)\n .map((group) => (\n <div className={classes.columnsContent}>\n <div className={classes.groupHeader}>{group.name}</div>\n {group.columns\n .filter(column => column.name.toLowerCase().includes(columnSearchQuery.toLowerCase()))\n .sort((a, b) => a.order - b.order)\n .map((column) => (\n <CheckboxWithLabel\n checkboxClass={classes.columnCheckbox}\n labelClass={classes.checkboxLabel}\n disableRippleEffect={true}\n key={column.id}\n disabled={!primaryColumn || column.id === primaryColumn?.id}\n checked={selectedColumns.some(selectedColumn => selectedColumn.id === column.id) || column.id === primaryColumn?.id}\n label={getColumnLabel(column)}\n setChecked={() => handleCheckColumn(column)}\n />\n ))}\n </div>\n ))\n }\n </div>\n </div>\n <div className={classes.previewRoot}>\n <div className={classes.informativeBoxContainer}>\n <Trans\n i18nKey=\"ReportInformativeBox\"\n t={t}\n />\n </div>\n <div className={classes.previewContainer}>\n {!primaryColumn\n ? <div className={classes.emptyPreviewBox}>\n <div><ReportPersonIcon/></div>\n <div className={classes.emptyPreviewBoxTitle}>{t(\"Create a report!\")}</div>\n <div className={classes.emptyPreviewBoxCaption}>{t(\"Please select columns.\")}</div>\n </div> \n : <GridList\n columns={previewGridColumns}\n items={previewGridData ?? []}\n classTableContainer={classes.classTableContainer}\n classTableBody={classes.classTableBody}\n height={\"100%\"}\n tooltipIsVisible={true}\n totalItems={20}\n pageSize={20}\n />\n }\n \n </div>\n </div>\n </div>\n <SaveReportModal \n open={saveReportModalIsOpen}\n checkNameIsInvalid={(stringName: string) => nameAlreadyExist(stringName)}\n onClose={() => {\n setOpenModalActionDots(false);\n setSaveReportModalIsOpen(false);\n }}\n onConfirm={saveCustomReport}\n />\n <ConfirmActionModal\n open={cancelEditReportModalIsOpen}\n content={<CancelEditModalContent/>}\n onClose={() => {\n setCancelEditReportModalIsOpen(false);\n setOpenModalActionDots(false);\n }}\n onConfirm={handleCancel}\n confirmButtonText={t(\"Yes, cancel\")}\n buttonClass={classes.cancelButton}\n />\n </div>\n );\n}","import React from 'react';\n\nimport { BrowserRouter, Redirect, Route } from \"react-router-dom\";\n\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectUserInfo } from \"../../../redux/store\";\n\nimport { Url } from \"../../../constants/url\";\nimport PredeterminedReportsPage from \"../sections/PredeterminedReports/PredeterminedReportsPage\";\nimport CustomReportsPage from \"../sections/CustomReports/CustomReportsPage\";\n\n\nexport default function ReportsRouter() {\n const userInfo = useAppSelector(selectUserInfo);\n \n return (\n <>\n <Route exact path={Url.Reports.Main}>\n {userInfo.hasAccessToReports \n ? <PredeterminedReportsPage />\n : <Redirect to={Url.Appointments.Main} />}\n </Route>\n \n <Route exact path={Url.Reports.CustomReport}>\n {userInfo.hasAccessToReports \n ? <CustomReportsPage /> \n : <Redirect to={Url.Appointments.Main} />}\n </Route>\n </>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\nexport const useStyles = makeStyles((theme) => ({\n messengerLayout: {\n width: \"100vw\",\n position: \"relative\",\n left: \"50%\",\n right: \"50%\",\n marginLeft: \"-50vw\",\n marginRight: \"-50vw\",\n marginTop: \"-20px\",\n },\n disableYScroll: {\n overflow: \"hidden\",\n },\n scrollable: {\n overflow: \"scroll !important\"\n },\n loader: {\n height: 80,\n\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n hideScrollbars: {\n \"&::-webkit-scrollbar\": {\n \"display\": \"none\",\n },\n scrollbarWidth: \"none\",\n \"&::-ms-overflow-style\": \"none\",\n },\n buildScrollbars: {\n \"&::-webkit-scrollbar\": {\n \"display\": \"none\",\n },\n scrollbarWidth: \"none\",\n \"&::-ms-overflow-style\": \"none\",\n overflowY: \"auto\", \n maxHeight: \"calc(100vh - 120px)\"\n },\n noConversationsContainer: {\n width: \"360px\",\n maxWidth: \"360px\",\n height: \"100px\",\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n textAlign: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n },\n noConversation: {\n width: \"calc(100vw - 360px)\",\n height: \"100vh\",\n maxHeight: \"100vh\",\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"stretch\",\n backgroundColor: \"#ffffff\",\n textAlign: \"center\"\n },\n noConversationImage: {\n marginTop: \"20vh\",\n },\n noConversationText1: {\n marginTop: 40,\n fontFamily: 'Inter, sans-serif',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 18,\n alignItems: \"center\",\n textAlign: \"center\",\n letterSpacing: \"0.08em\",\n color: \"#7175FA\"\n },\n noConversationText2: {\n marginTop: 20,\n fontFamily: 'Inter, sans-serif',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 14,\n alignItems: \"center\",\n textAlign: \"center\",\n color: \"#919CA5\",\n margin: \"auto\",\n maxWidth: 280\n },\n availableCaption: {\n display: \"block\",\n \n fontSize: 10,\n fontFamily: \"Inter\",\n \n marginLeft: '19px',\n color: 'gray',\n whiteSpace: 'pre-line',\n },\n availabilityStatusContainer: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginRight: 27\n },\n availableCircle: {\n fontSize: '12px',\n marginRight: '8px'\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"8px 0px 8px 15px\",\n color: theme.colors.clearMain\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 70,\n width: 150,\n display: \"flex\",\n alignItems: \"center\",\n },\n select: {\n ...theme.typography.txtBody2,\n height: 32,\n backgroundColor: theme.colors.grey1,\n width: 150,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \"& .MuiPaper-rounded\": {\n borderRadius: 10,\n marginTop: 5\n },\n \"& .MuiPaper-rounded .MuiListItem-root.Mui-selected:not(:hover)\": {\n backgroundColor: \"white\",\n },\n \"& .MuiPaper-rounded .MuiListItem-root\": {\n fontSize: 12,\n },\n \"& .MuiPaper-rounded .MuiListItem-root:hover\": {\n backgroundColor: theme.colors.grey1\n },\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n position: 'relative',\n },\n toolbarContainer: {\n width: 360,\n height: 64,\n backgroundColor: Color.white,\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\"\n }\n}));","import { ConversationMessageType } from \"./enums/conversation-message-type\";\n\nexport class ConversationPreview {\n lastMessageId: string;\n customerId?: string;\n customerName: string;\n customerMobile: string;\n lastMessageText: string | null;\n lastMessageTime?: Date;\n lastMessageType: ConversationMessageType;\n isDisabledActivity: boolean;\n isDisabledNotContactable: boolean;\n isCustomerBlocked: boolean;\n unreadMessagesCount: number;\n wasSendMore1DayAgo: boolean;\n canScheduleFollowUp: boolean;\n hasScheduledFollowUp: boolean;\n hasUnpaidAppointment: boolean;\n establishmentId: string | null;\n establishmentName: string | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\") {\n this.lastMessageId = x.lastMessageId;\n this.customerId = x.customerId;\n this.customerName = x.customerName;\n this.customerMobile = x.customerMobile;\n this.lastMessageText = x.lastMessageText;\n this.lastMessageTime = x.lastMessageTime;\n this.lastMessageType = x.lastMessageType;\n this.isDisabledActivity = x.isDisabledActivity;\n this.isDisabledNotContactable = x.isDisabledNotContactable;\n this.isCustomerBlocked = x.isCustomerBlocked;\n this.unreadMessagesCount = x.unreadMessagesCount;\n this.wasSendMore1DayAgo = x.wasSendMore1DayAgo;\n this.canScheduleFollowUp = x.canScheduleFollowUp;\n this.hasScheduledFollowUp = x.hasScheduledFollowUp;\n this.hasUnpaidAppointment = x.hasUnpaidAppointment;\n this.establishmentId = x.establishmentId;\n this.establishmentName = x.establishmentName;\n } else {\n this.lastMessageId = \"\";\n this.customerId = undefined;\n this.customerName = \"\";\n this.customerMobile = \"\";\n this.lastMessageText = \"\";\n this.lastMessageTime = undefined;\n this.lastMessageType = ConversationMessageType.Text;\n this.isDisabledActivity = false;\n this.isDisabledNotContactable = false;\n this.isCustomerBlocked = false;\n this.unreadMessagesCount = 0;\n this.wasSendMore1DayAgo = false;\n this.canScheduleFollowUp = false;\n this.hasScheduledFollowUp = false;\n this.hasUnpaidAppointment = false;\n this.establishmentId = null;\n this.establishmentName = null;\n }\n }\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\nexport const useStyles = makeStyles((theme) => ({\n windowContainer: {\n width: \"calc(100vw - 360px)\",\n height: \"100vh\",\n maxHeight: \"100vh\",\n \n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"stretch\",\n \n backgroundColor: \"#FFFFFF\"\n },\n header: {\n display: \"flex\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n backgroundColor: theme.colors.grey1,\n height: \"48px\",\n paddingRight: 39,\n zIndex: 2\n },\n headerTitle: {\n display: \"flex\",\n alignItems: \"center\",\n \n padding: \"15px 16px 16px 40px\",\n \n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \n \"& svg\": {\n marginRight: 10\n }\n },\n headerActions: {\n \n },\n headerTitleWithEstablishmentName: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n gap: 2,\n \n padding: \"8px 16px 8px 40px\",\n \n ...theme.typography.txtBody1,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n establishmentName: {\n ...theme.typography.txtBody3,\n color: theme.colors.grey5,\n },\n buildScrollbars: {\n overflow: \"auto\",\n overflowAnchor: \"none\",\n overflowX: \"hidden\"\n },\n messageWindow: {\n height: \"calc(100vh - 175px) !important\",\n marginTop: \"48px\",\n display: \"flex\", \n flexDirection: \"column-reverse\",\n position: \"sticky\",\n bottom: \"300px\",\n },\n dayLabel: {\n display: \"flex\", \n justifyContent: \"center\"\n },\n inputLayout: {\n width: \"100%\",\n \n bottom: \"0%\",\n position: \"sticky\",\n \n display: \"flex\",\n justifySelf: \"flex-end\",\n\n backgroundColor: \"#FFFFFF\",\n },\n inputItemsLayout: {\n width: \"100%\",\n minHeight: \"72px\",\n \n margin: \"0px !important\",\n padding: \"12px 5%\"\n },\n inputAreaContainer: {\n height: 40,\n \n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n messageInputArea: {\n width: \"75%\",\n height: 40,\n marginRight: \"2%\",\n // does not change this element's position,\n // used to absolutely position toolbarWrapper within it\n position: \"relative\",\n },\n sendMessageButton: {\n display: \"flex\",\n width: \"120px\",\n height: 40\n },\n inputArea: {\n backgroundColor: theme.colors.grey1,\n border: \"0px\",\n borderRadius: \"6px !important\",\n \n width: \"100% !important\",\n height: \"100% !important\",\n \n resize: \"none\",\n \"&::-webkit-scrollbar\": {\n \"display\": \"none\",\n },\n scrollbarWidth: \"none\",\n \"&::-ms-overflow-style\": \"none\",\n \"&:focus\": {\n outline: \"none\",\n boxShadow: 0,\n border: \"solid 1px #6462F3\",\n },\n \"&::placeholder\": {\n color: \"#B5B9C1\",\n },\n },\n inputText: {\n fontFamily: \"Inter, sans-serif !important\",\n fontStyle: \"normal !important\",\n fontWeight: \"bold\",\n fontSize: \"14px !important\",\n color: theme.colors.grey4 + \" !important\",\n // padding-right accommodates the copy link button,\n // please remember to update after adding new buttons\n padding: \"11px 40px 12px 16px !important\"\n },\n disabledInputLayout: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\"\n },\n disabledInput: {\n display: \"flex\",\n justifyContent: \"center\"\n },\n enabledSendButton: {\n backgroundColor: theme.colors.clearGreen,\n width: \"100%\",\n height: \"100%\",\n borderRadius: \"6px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n color: \"#FFFFFF\",\n transition: \"color 0.5s, background-color 0.5s\",\n \"&:hover\": {\n color: theme.colors.clearGreen\n },\n \"&.Mui-disabled\": {\n color: \"#FFFFFF\",\n opacity: 0.3,\n },\n },\n enabledSendButtonWithDropdown: {\n width: \"60%\",\n borderTopRightRadius: \"0\",\n borderBottomRightRadius: \"0\"\n },\n enabledSendDropdownButton: {\n width: \"40%\",\n minWidth: \"auto\",\n borderTopLeftRadius: \"0\",\n borderBottomLeftRadius: \"0\",\n marginLeft: \"1px\"\n },\n menuItem:{\n padding: \"0 20px 0 10px\",\n },\n listItemIcon: {\n minWidth: \"25px\",\n },\n listItemText: {\n '& span': {fontSize: \"14px\"}\n },\n alternativeNotificationSendButton: {\n backgroundColor: theme.colors.clearGreen,\n width: \"100%\",\n maxWidth: \"200px\",\n height: \"100%\",\n borderRadius: \"50px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n color: \"#FFFFFF\",\n transition: \"color 0.5s, background-color 0.5s\",\n \"&:hover\": {\n color: theme.colors.clearGreen\n },\n \"&.Mui-disabled\": {\n color: \"#FFFFFF\",\n opacity: 0.3,\n },\n },\n dayLabelBox: {\n background: \"rgba(11, 203, 224, 0.1)\",\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n // display: \"flex\",\n // justifyContent: \"center\",\n whiteSpace: \"break-spaces\",\n margin: \"10px 40px 10px 40px\",\n },\n dayLabelText: {\n color: Color.blue,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n },\n templateTextAreaContainer: {\n backgroundColor: theme.colors.grey1,\n borderRadius: 10,\n overflowY: \"auto\",\n maxHeight: 130,\n width: \"593px\",\n paddingLeft: \"10px\",\n position: \"relative\",\n \"&::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"&::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"10px\",\n marginBottom: \"10px\",\n },\n \"&::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"&::-webkit-scrollbar-thumb:hover\": {\n background: Color.gray4\n },\n },\n closeWindowButton: {\n position: \"sticky\",\n top: 0,\n right: 0,\n padding: \"5px\",\n cursor: \"pointer\",\n marginLeft: 542,\n textAlign: \"right\",\n zIndex: 1,\n },\n closeIcon: {\n color: theme.colors.grey4\n },\n templateWindowArea: {\n display: \"flex\",\n gap: 12\n },\n textArea: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n fontWeight: \"normal\",\n opacity: 0.8,\n },\n },\n buttonContainer: {\n display: \"flex\",\n alignSelf: \"end\",\n height: 40,\n width: 103,\n marginTop: \"10px\", \n },\n templateTextContainer: {\n marginTop: -40,\n padding: 17,\n paddingRight: 25,\n color: theme.colors.grey3\n },\n tooltipBlock: {\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n borderRadius: 5,\n boxShadow: \"0px 4px 4px 0px\",\n },\n infiniteScrollOverrides: {\n \"overflow-x\": \"hidden !important\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"33px\",\n marginBottom: \"33px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: Color.gray4\n },\n }\n}));","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n\n position: \"relative\",\n\n width: 296,\n height: 70,\n\n paddingTop: 3,\n paddingBottom: 3,\n paddingLeft: 14,\n paddingRight: 14,\n },\n container: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n width: 296,\n\n \"& #waveform\": {\n width: 180,\n paddingLeft: 10,\n paddingRight: 10,\n },\n\n \"& #waveform ::part(cursor)\": {\n height: 15,\n borderRadius: \"50%\",\n backgroundColor: theme.colors.clearMain,\n top: 49,\n },\n\n \"& #waveform ::part(progress)\": {\n height: 25,\n borderRadius: 4,\n top: 44,\n },\n },\n duration: {\n position: \"absolute\",\n bottom: 1,\n\n ...theme.typography.txtBody3,\n fontFamily: \"Roboto, sans-serif\",\n color: theme.colors.grey5\n },\n avatarContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n position: \"relative\",\n\n width: 45,\n height: 42,\n\n borderRadius: 50,\n },\n avatarWithInitials: {\n backgroundColor: theme.colors.grey4,\n },\n avatarWithLogo: {\n backgroundColor: theme.colors.clearMain,\n },\n accountLogo: {\n width: 45,\n height: 42,\n\n borderRadius: 50,\n },\n avatarInitials: {\n ...theme.typography.txtBody1,\n fontWeight: 700,\n color: \"#FFFFFF\",\n },\n avatarMicrophone: {\n position: \"absolute\",\n bottom: -5\n }\n}));\n\nexport default useStyles;\n","import React, { useState, useRef, useEffect } from 'react';\n\n// @ts-ignore\nimport { useWavesurfer } from '@wavesurfer/react'\n\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectAccountSettings } from \"../../../redux/store\";\n\nimport { MessageAudioPlayerProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Color } from \"../../../constants/colors\";\nimport { WhatsAppAudioLogo, WhatsAppMicrophoneIcon, WhatsAppPlayAudioIcon } from \"../../../assets/icons\";\n\n\nexport default function MessageAudioPlayer(props: MessageAudioPlayerProps) {\n\n const { url, isInbound, customerName } = props;\n\n const classes = useStyles();\n const elementOrder: ('player' | 'avatar')[] = isInbound ? ['player', 'avatar'] : ['avatar', 'player'];\n\n const accountSettings = useAppSelector(selectAccountSettings);\n\n const containerRef = useRef<any>();\n\n const [currentTimeDisplayed, setCurrentTimeDisplayed] = useState<string>('0:00');\n const [maxTimeDisplayed, setMaxTimeDisplayed] = useState<string>('0:00');\n\n const { wavesurfer, isReady, isPlaying, currentTime } = useWavesurfer({\n container: containerRef,\n url: url,\n normalize: true,\n hideScrollbar: true,\n\n width: 160,\n height: 25,\n\n waveColor: Color.gray2,\n progressColor: Color.clear1,\n\n barWidth: 3,\n barGap: 1,\n barRadius: 4,\n\n cursorWidth: 15,\n })\n\n useEffect(() => {\n if (isReady) {\n setMaxTimeDisplayed(secondsToDisplayedTime(wavesurfer!.getDuration()))\n }\n }, [isReady])\n\n useEffect(() => {\n setCurrentTimeDisplayed(secondsToDisplayedTime(currentTime))\n }, [currentTime])\n\n function onPlayPause() {\n wavesurfer && wavesurfer.playPause()\n }\n\n function padLeft(str: number, pad: string, length: number) {\n return (new Array(length+1).join(pad)+str).slice(-length);\n }\n\n function secondsToDisplayedTime(durationInSeconds: number) {\n const minutes = Math.floor(durationInSeconds / 60);\n const seconds = Math.floor(durationInSeconds - minutes * 60);\n const timeToDisplay = padLeft(minutes,'0',1) + ':' + padLeft(seconds,'0',2);\n return timeToDisplay;\n }\n\n function getInitials() {\n if (!customerName) return '';\n\n const splitFullName = customerName.split(' ');\n if (splitFullName.length === 1) {\n return `${splitFullName[0][0]}${splitFullName[0][1]}`\n }\n return `${splitFullName[0][0]}${splitFullName[1][0]}`;\n }\n \n function mapElement(element: 'player' | 'avatar') {\n switch (element) {\n case \"player\":\n return (\n <>\n <div\n onClick={onPlayPause}\n >\n <WhatsAppPlayAudioIcon />\n </div>\n\n <div id=\"waveform\" ref={containerRef} />\n </>\n );\n case \"avatar\":\n return (\n <div\n className={`${classes.avatarContainer} ${isInbound && classes.avatarWithInitials}`}\n >\n {isInbound\n ? <span className={classes.avatarInitials}>{getInitials()}</span>\n : accountSettings.accountLogo && accountSettings.accountLogo !== \"\"\n ? <img alt={'logo'} className={classes.accountLogo} src={accountSettings.accountLogo} />\n : <WhatsAppAudioLogo />\n }\n <div className={classes.avatarMicrophone} style={isInbound ? { left: -5 } : { right: -5 }}>\n <WhatsAppMicrophoneIcon />\n </div>\n </div>\n )\n }\n }\n\n return (\n <div className={classes.root}>\n <div className={classes.container}>\n {\n elementOrder.map(mapElement)\n }\n </div>\n <span className={classes.duration} style={{ left: isInbound ? 60 : 115 }}>{currentTime === 0 ? maxTimeDisplayed : currentTimeDisplayed}</span>\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Interweave from \"interweave\";\n\nimport moment from \"moment\";\nimport \"moment-timezone\";\n\nimport { CircularProgress, Tooltip } from \"@material-ui/core\";\nimport Typography from '@material-ui/core/Typography';\n\nimport { useStyles } from \"./css\";\nimport {\n DownloadFileCloud,\n ImageIcon,\n WhatsAppDocumentIcon,\n WhatsAppPDFIcon,\n WhatsAppPlayVideoIcon,\n WhatsAppVideoIcon\n} from \"../../../assets/icons\"\nimport { MessageProps } from \"./props\";\nimport { Message as MessageModel } from \"./../../../models/message\"\nimport { ConversationMessageType } from \"../../../models/enums/conversation-message-type\";\nimport { Color } from \"../../../constants/colors\";\nimport MessageAudioPlayer from \"../MessageAudioPlayer\";\n\n\nconst Message = React.memo((props: MessageProps) => {\n\n const {\n message,\n openCarousel,\n setClickedMessageId,\n isCustomerRegistered,\n customerName,\n ...otherProps\n } = props;\n\n const { t } = useTranslation([\"general\"]);\n const maxImageWidth = 600;\n const [imageWidth, setImageWidth] = useState<number>(maxImageWidth / 2);\n const [isLoading, setIsLoading] = useState(false);\n const [isPlayIconDisplayed, setPlayIconDisplayed] = useState(false);\n\n const classes = useStyles(imageWidth)();\n const linkRegex = new RegExp(\"[Hh]ttps?:\\\\/\\\\/(www\\\\.)?[-a-zA-Z0-9@:%._\\+~#=]{2,256}\\\\.[a-z]{2,4}\\\\b([-a-zA-Z0-9@:%_\\+.~#?&/=]*)\");\n\n useEffect(() => {\n if (!message.previewFileUrl || message.type === ConversationMessageType.Image) {\n setIsLoading(false);\n return;\n }\n\n const abortController = new AbortController();\n const onAbort = () => {\n // Nothing. Any logic can be added\n // This function will be triggered at abortController.signal on abortController.abort()\n };\n abortController.signal.addEventListener('abort', onAbort);\n\n checkImageUrl(message.previewFileHeadUrl, abortController);\n\n return () => {\n abortController.abort(); // Abort any ongoing fetch and stop recursive execution on unmount\n abortController.signal.removeEventListener('abort', onAbort);\n };\n }, [message.previewFileUrl]);\n\n const handleOnImageLoad = (i: React.SyntheticEvent<HTMLImageElement, Event>) => {\n let imageWidth = i.currentTarget.clientWidth;\n imageWidth = imageWidth > maxImageWidth ? maxImageWidth : imageWidth;\n setImageWidth(imageWidth);\n };\n\n const checkImageUrl = (headUrl: string | undefined, abortController: AbortController) => {\n fetch(headUrl!, { method: 'HEAD', signal: abortController.signal })\n .then(res => {\n if (res.ok) {\n setIsLoading(false);\n } else {\n if (!abortController.signal.aborted) {\n setIsLoading(true);\n setTimeout(() => checkImageUrl(headUrl, abortController), 5000);\n }\n }\n })\n .catch(() => {/*Swallowing \"Unhandled Rejection (AbortError): The operation was aborted\"*/ });\n };\n\n const getMessageTimeString = (messageTime: Date) => {\n const messageMoment = moment(messageTime);\n return messageMoment.format(\"hh:mm[hrs]\");\n };\n\n const encaseLinksWithTags = (str: string) => {\n if (str === null) return str;\n const matches = str.match(linkRegex);\n if (matches && matches.length > 0) {\n let newStr = str;\n newStr = newStr.replace(matches[0], `<a target=\"_blank\" href=\"${matches[0]}\">${matches[0]}</a>`)\n return newStr;\n } else {\n return str;\n }\n }\n\n const getMessageTextComponent = () => {\n const text = (message.text && message.text !== message.originalFileName) ? message.text : \"\";\n\n if (message.type === ConversationMessageType.Document ||\n message.type === ConversationMessageType.Pdf ||\n message.type === ConversationMessageType.Video ||\n message.type === ConversationMessageType.Image) {\n return <Tooltip title={text}>\n <Typography className={`${getTextComponentClassName()} ${classes.mediaCaption}`}>\n <Interweave content={encaseLinksWithTags(text)} />\n </Typography>\n </Tooltip>\n }\n else {\n return <Typography className={getTextComponentClassName()}>\n <Interweave content={encaseLinksWithTags(text)} />\n </Typography>\n }\n };\n\n const getFileCaptionComponent = () => {\n if (message.type === ConversationMessageType.Document ||\n message.type === ConversationMessageType.Pdf ||\n message.type === ConversationMessageType.Video ||\n message.type === ConversationMessageType.Image) {\n const fileName = message.originalFileName ?? \"\";\n return (\n <Tooltip title={fileName}>\n <Typography className={classes.fileCaptionText}>\n {fileName}\n </Typography>\n </Tooltip>\n );\n }\n };\n\n const getTextComponentClassName = () => {\n return message.isInbound\n ? classes.inboundMessageText\n : classes.outboundMessageText;\n };\n\n const downloadDocument = () => {\n const link = document.createElement(\"a\");\n link.setAttribute(\"href\", message.fileUrl!);\n link.setAttribute(\"download\", message.originalFileName!);\n link.setAttribute(\"target\", \"_blank\");\n link.setAttribute(\"rel\", \"noopener\");\n document.body.appendChild(link);\n link.click();\n link.parentNode?.removeChild(link);\n };\n\n const openCarouselModal = (messageId: string) => {\n setClickedMessageId(messageId);\n openCarousel();\n }\n\n const getInnerContent = (message: MessageModel) => {\n if (message.type === ConversationMessageType.Image) {\n return <div className={classes.fileMessageBox}>\n <img\n loading=\"lazy\"\n onLoad={i => handleOnImageLoad(i)}\n className={classes.image}\n src={message.previewFileUrl}\n alt={\"image\"}\n onClick={() => openCarouselModal(message.id!)}>\n </img>\n <div className={`${classes.previewMessageFooter}`}>\n <ImageIcon width={40} height={40} style={{ color: Color.gray5 }} />\n {getFileCaptionComponent()}\n <DownloadFileCloud onClick={downloadDocument} className={classes.downloadFileIcon} style={{ marginRight: \"8px\" }} />\n </div>\n {getMessageTextComponent()}\n </div>\n }\n else if (message.type === ConversationMessageType.Pdf) {\n return <div className={classes.fileMessageBox}>\n {isLoading\n ? <div className={classes.circularLoaderContainer}><CircularProgress size={\"2rem\"} /></div>\n : <img\n loading=\"lazy\"\n onLoad={i => handleOnImageLoad(i)}\n className={classes.pdfPreviewImage}\n src={message.previewFileUrl}\n alt={\"image\"}>\n </img>}\n <div className={`${classes.previewMessageFooter}`}>\n <WhatsAppPDFIcon />\n {getFileCaptionComponent()}\n <DownloadFileCloud onClick={downloadDocument} className={classes.downloadFileIcon} style={{ marginRight: \"8px\" }} />\n </div>\n {getMessageTextComponent()}\n </div>\n }\n else if (message.type === ConversationMessageType.Video) {\n return (\n <div className={classes.fileMessageBox}>\n {isLoading\n ? <div className={classes.circularLoaderContainer}><CircularProgress size={\"2rem\"} /></div>\n :\n <div className={classes.videoPreviewImage}\n onMouseEnter={() => setPlayIconDisplayed(true)}\n onMouseLeave={() => setPlayIconDisplayed(false)}\n >\n <img\n loading=\"lazy\"\n onLoad={i => handleOnImageLoad(i)}\n className={classes.pdfPreviewImage}\n src={message.previewFileUrl}\n alt={\"image\"}\n />\n {\n isPlayIconDisplayed &&\n <div className={classes.videoPreviewPlayIcon}\n onClick={() => openCarouselModal(message.id!)}\n >\n <WhatsAppPlayVideoIcon />\n </div>\n }\n </div>\n }\n <div className={`${classes.previewMessageFooter}`}>\n <WhatsAppVideoIcon />\n {getFileCaptionComponent()}\n <DownloadFileCloud onClick={downloadDocument} className={classes.downloadFileIcon} style={{ marginRight: \"8px\" }} />\n </div>\n {getMessageTextComponent()}\n </div>\n )\n }\n else if (message.type === ConversationMessageType.Voice) {\n {\n return isLoading\n ? <div className={classes.circularLoaderContainer}><CircularProgress size={\"2rem\"} /></div>\n : <MessageAudioPlayer\n url={message.fileUrl!}\n isInbound={message.isInbound}\n customerName={customerName}\n />\n }\n }\n else if (message.type === ConversationMessageType.Document) {\n return <div className={classes.fileMessageBox}>\n <div className={`${classes.documentMessageContainer}`}>\n <WhatsAppDocumentIcon style={{ marginRight: \"5px\", marginLeft: \"5px\" }} />\n {getFileCaptionComponent()}\n <DownloadFileCloud onClick={downloadDocument} className={classes.downloadFileIcon} style={{ marginRight: \"8px\" }} />\n </div>\n {getMessageTextComponent()}\n </div>\n }\n\n return getMessageTextComponent();\n }\n\n return (\n <>\n {message.isBlock === null &&\n <div id={`target${message.id}`}>\n <div className={message.isInbound ? classes.inboundMessageLayout : classes.outboundMessageLayout}>\n <div className={message.isInbound ? classes.inboundMessageContainer : classes.outboundMessageContainer}>\n {getInnerContent(message)}\n </div>\n </div>\n <div style={{ marginTop: \"-2px\" }} className={message.isInbound ? classes.inboundMessageLayout : classes.outboundMessageLayout}>\n <Typography className={classes.messageTimeText}>\n {getMessageTimeString(message.time!)}\n </Typography>\n </div>\n </div>\n }\n {message.isBlock === true &&\n <div id={`target-block-${ message.id}`}>\n <div className={classes.blockLabel}>\n <div className={classes.blockLabelBox}>\n <Typography className={classes.blockLabelText}>\n {isCustomerRegistered &&\n t(\"You have blocked this customer.\")\n }\n {!isCustomerRegistered &&\n t(\"You have blocked this number.\")\n }\n </Typography>\n </div>\n </div>\n </div>\n }\n {message.isBlock === false &&\n <div id={`target-unblock-${ message.id}`}>\n <div className={classes.blockLabel}>\n <div className={classes.unblockLabelBox}>\n <Typography className={classes.unblockLabelText}>\n {isCustomerRegistered &&\n t(\"You have unblocked this customer.\")\n }\n {!isCustomerRegistered &&\n t(\"You have unblocked this number.\")\n }\n </Typography>\n </div>\n </div>\n </div>\n }\n </>\n );\n})\n\nexport default Message;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"./../../../constants/colors\"\n\nexport const useStyles = (imageWidth: number) => makeStyles((theme) => ({\n outboundMessageContainer: {\n maxWidth: \"48%\",\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: \"#EAFFD7\",\n },\n inboundMessageContainer: {\n maxWidth: \"48%\",\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: Color.gray1,\n },\n outboundMessageLayout: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n whiteSpace: \"break-spaces\",\n margin: \"10px 40px 10px 40px\",\n '& a': {\n '&:link': {\n color: theme.colors.clearMain + \" !important\"\n },\n '&:visited': {\n color: theme.colors.clearMain + \" !important\"\n }\n }\n },\n inboundMessageLayout: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n whiteSpace: \"break-spaces\",\n margin: \"10px 40px 10px 40px\",\n '& a': {\n '&:link': {\n color: theme.colors.clearMain + \" !important\"\n },\n '&:visited': {\n color: theme.colors.clearMain + \" !important\"\n }\n }\n },\n inboundMessageText: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey5,\n overflowWrap: \"break-word\",\n alignSelf: \"flex-start\"\n },\n outboundMessageText: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey6,\n overflowWrap: \"break-word\"\n },\n messageTimeContainer: {\n\n },\n messageTimeText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"11px\",\n color: Color.gray5,\n },\n image: {\n maxWidth: \"100%\",\n maxHeight: \"50vh\",\n borderRadius: \"10px 10px 0 0\",\n cursor: \"pointer\",\n objectFit: \"cover\",\n display: \"block\"\n },\n pdfPreviewImage: {\n maxWidth: \"300px\",\n maxHeight: \"50vh\",\n borderRadius: \"10px 10px 0 0\",\n objectFit: \"cover\",\n display: \"block\"\n },\n documentMessageFooter: {\n backgroundColor: \"#ECECEC\",\n padding: \"20px 0px 15px 0px\",\n display: \"flex\",\n gap: \"10px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n borderRadius: \"0px 0px 10px 10px\"\n },\n documentMessageFileNameText: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\"\n },\n documentContentBox: {\n paddingBottom: 5,\n paddingTop: 4\n },\n pdfPage: {\n display: \"flex\",\n justifyContent: \"space-around\",\n },\n downloadFileIcon: {\n width: \"24px !important\",\n height: \"18px !important\",\n cursor: \"pointer\",\n color: theme.colors.grey5 + \" !important\"\n },\n fileCaptionText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n color: theme.colors.grey5,\n whiteSpace: \"normal\",\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n display: \"-webkit-box\",\n WebkitBoxOrient: \"vertical\",\n WebkitLineClamp: 2,\n maxHeight: \"2.8em\",\n marginRight: \"10px\",\n flexGrow: 1,\n overflowWrap: \"break-word\"\n },\n fileMessageBox: {\n padding: 5,\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n },\n previewMessageFooter: {\n backgroundColor: \"#ECECEC\",\n display: \"flex\",\n alignItems: \"center\",\n paddingLeft: 5,\n paddingRight: 5,\n gap: 5,\n borderRadius: \"0px 0px 10px 10px\",\n height: \"60px\",\n width: imageWidth + \"px\",\n minWidth: \"102px\",\n maxWidth: \"100%\",\n marginBottom: 20\n },\n documentMessageContainer: {\n backgroundColor: \"#ECECEC\",\n display: \"flex\",\n alignItems: \"center\",\n paddingLeft: 5,\n paddingRight: 5,\n gap: 5,\n borderRadius: \"0px 0px 10px 10px\",\n height: \"60px\",\n minWidth: \"102px\",\n maxWidth: \"100%\"\n },\n circularLoaderContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\",\n height: \"200px\",\n width: \"300px\"\n },\n blockLabel: {\n display: \"flex\",\n justifyContent: \"center\"\n },\n blockLabelBox: {\n background: \"rgba(237, 76, 92, 0.1)\",\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n whiteSpace: \"break-spaces\",\n margin: \"10px 40px 10px 40px\",\n },\n blockLabelText: {\n color: Color.red,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n },\n unblockLabelBox: {\n background: \"rgba(54, 206, 145, 0.1)\",\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n whiteSpace: \"break-spaces\",\n margin: \"10px 40px 10px 40px\",\n },\n unblockLabelText: {\n color: Color.green,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"12px\",\n },\n videoPreviewImage: {\n position: \"relative\"\n },\n videoPreviewPlayIcon: {\n position: \"absolute\",\n top: \"calc(50% - 50px)\",\n left: \"calc(50% - 50px)\",\n },\n mediaCaption: {\n width: 400\n }\n}));","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ArrowDropDownIcon = (props: any) => {\n const { style, viewBox, ...otherProps } = props;\n return (\n <SvgIcon\n {...otherProps}\n style={{ width: 7, height: 4, ...style }}\n viewBox={viewBox || \"0 0 7 4\"}\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path d=\"M0.600842 0C0.0633791 0 -0.205352 0.620896 0.18553 0.979105L3.09272 3.8209C3.31259 4.0597 3.67904 4.0597 3.92334 3.8209L6.83053 0.979105C7.19698 0.620896 6.92825 0 6.41521 0H0.600842Z\" fill=\"#F6F6F6\"/>\n </SvgIcon>\n );\n};\n\nexport default ArrowDropDownIcon;\n","import React from \"react\"\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ScheduledSendIcon = (props: any) => {\n const { width = 19, height = 18, ...otherProps } = props;\n return (\n <SvgIcon\n {...otherProps}\n style={{width: width, height: height}}\n viewBox=\"0 0 19 18\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path d=\"M0 15.3307V0.664062L14.3 6.16406H14C13.4167 6.16406 12.8667 6.22517 12.35 6.3474C11.8333 6.46962 11.3333 6.63767 10.85 6.85156L2 3.41406V6.6224L8 7.9974L2 9.3724V12.5807L7.4 10.4724C7.26667 10.8238 7.16667 11.1712 7.1 11.5146C7.03333 11.8587 7 12.2141 7 12.5807V12.6266L0 15.3307ZM14 17.1641C12.6167 17.1641 11.4377 16.7173 10.463 15.8239C9.48767 14.9298 9 13.8488 9 12.5807C9 11.3127 9.48767 10.2316 10.463 9.33756C11.4377 8.44412 12.6167 7.9974 14 7.9974C15.3833 7.9974 16.5627 8.44412 17.538 9.33756C18.5127 10.2316 19 11.3127 19 12.5807C19 13.8488 18.5127 14.9298 17.538 15.8239C16.5627 16.7173 15.3833 17.1641 14 17.1641ZM15.65 14.7349L16.35 14.0932L14.5 12.3974V9.83073H13.5V12.7641L15.65 14.7349ZM2 10.4724V3.41406V12.5807V10.4724Z\" fill=\"#36CE91\"/>\n </SvgIcon>\n )\n};\nexport default ScheduledSendIcon;","import React from \"react\"\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\nconst ScheduledSendIcon = (props: any) => {\n return (\n <SvgIcon\n {...props}\n width=\"24\"\n height=\"22\"\n viewBox=\"0 0 24 22\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <path d=\"M22 10.615C22 6.97085 17.5232 4 12.0003 4C6.47796 4 2.00113 6.97085 2.00113 10.615C2.00113 10.7095 2 10.9696 2 11.0026C2 14.8687 5.91301 18 11.9992 18C18.123 18 22 14.8698 22 11.0031C22 10.8682 22 10.7903 22 10.615Z\" fill=\"#5C6477\"/>\n <path d=\"M8.8096 8.64961C8.80453 8.65929 8.70888 8.76002 8.77077 8.84027C8.9227 9.03662 9.39143 9.14874 9.86522 9.04117C10.1471 8.97743 10.5089 8.6866 10.8595 8.40489C11.2388 8.09983 11.6158 7.79478 11.9945 7.67299C12.3951 7.54379 12.6523 7.59957 12.8222 7.65136C13.0085 7.70713 13.2273 7.8312 13.5768 8.09642C14.2346 8.59668 16.8798 10.9324 17.3367 11.3359C17.7053 11.1674 19.3411 10.4555 21.5643 9.95975C21.3713 8.76116 20.6499 7.66388 19.5566 6.76579C18.0328 7.41346 16.1703 7.75153 14.3494 6.85173C14.3398 6.84775 13.354 6.37594 12.3822 6.39928C10.9366 6.43285 10.3109 7.06573 9.64858 7.73502L8.8096 8.64961Z\" fill=\"white\"/>\n <path d=\"M17.2297 11.5919C17.1987 11.564 14.1191 8.83845 13.4219 8.30859C13.0179 8.0024 12.7934 7.92386 12.5576 7.89369C12.4349 7.87719 12.265 7.90052 12.1468 7.93353C11.8221 8.02288 11.3979 8.30973 11.0209 8.61193C10.6309 8.92609 10.2629 9.22204 9.92191 9.29944C9.48582 9.39847 8.9535 9.28123 8.71042 9.11561C8.61195 9.04845 8.54273 8.97105 8.50953 8.89251C8.4195 8.68194 8.58494 8.51347 8.61251 8.48559L9.46218 7.55563C9.56122 7.45603 9.66025 7.35643 9.7621 7.25798C9.48807 7.2944 9.23429 7.36497 8.98783 7.43441C8.68003 7.52205 8.38405 7.60514 8.08413 7.60514C7.95922 7.60514 7.28904 7.49416 7.16187 7.45888C6.39266 7.24602 5.71742 7.03886 4.70963 6.5625C3.50152 7.47254 2.69348 8.60966 2.45996 9.86231C2.63383 9.90898 2.9135 9.99321 3.0311 10.0194C5.76469 10.634 6.61605 11.2675 6.7708 11.4001C6.93792 11.2117 7.17932 11.0928 7.44885 11.0928C7.75102 11.0933 8.02393 11.2464 8.18936 11.4843C8.34579 11.3591 8.56187 11.2527 8.84096 11.2527C8.96757 11.2527 9.09924 11.2766 9.23204 11.3221C9.5404 11.4291 9.69964 11.6369 9.78236 11.8247C9.8859 11.7774 10.0131 11.7427 10.1627 11.7433C10.3102 11.7433 10.4632 11.7769 10.6174 11.8446C11.1216 12.0631 11.1998 12.564 11.1542 12.9413C11.1902 12.9373 11.2262 12.9356 11.2628 12.9356C11.8604 12.9362 12.3466 13.4273 12.3466 14.0323C12.3466 14.2196 12.2993 14.3954 12.2166 14.5497C12.3792 14.6424 12.7939 14.8513 13.158 14.8046C13.4489 14.7676 13.5592 14.6669 13.5986 14.6106C13.6256 14.5718 13.6543 14.5263 13.6278 14.4939L12.8564 13.6271C12.8564 13.6271 12.7292 13.5053 12.7714 13.4586C12.8147 13.4103 12.8935 13.4797 12.9487 13.5264C13.3414 13.8582 13.8208 14.3584 13.8208 14.3584C13.8287 14.3641 13.8608 14.4273 14.038 14.4597C14.1905 14.4871 14.4606 14.4711 14.6475 14.3157C14.6947 14.2765 14.742 14.2275 14.7814 14.1769C14.7786 14.1792 14.7757 14.1831 14.7729 14.1843C14.9699 13.9287 14.751 13.6704 14.751 13.6704L13.8501 12.6476C13.8501 12.6476 13.7218 12.527 13.7651 12.4786C13.8045 12.4365 13.8872 12.5002 13.9441 12.5475C14.2288 12.7888 14.6317 13.1974 15.0183 13.5799C15.0931 13.6362 15.433 13.8485 15.882 13.5497C16.1549 13.3687 16.2095 13.1468 16.2016 12.9789C16.1831 12.7569 16.0114 12.5987 16.0114 12.5987L14.7814 11.3477C14.7814 11.3477 14.6514 11.2356 14.6975 11.1787C14.7352 11.1309 14.8196 11.1998 14.8748 11.2464C15.2664 11.5782 16.3277 12.5623 16.3277 12.5623C16.3429 12.5731 16.7092 12.8371 17.1622 12.5452C17.3242 12.4405 17.4277 12.2828 17.4367 12.099C17.4519 11.7808 17.2297 11.5919 17.2297 11.5919Z\" fill=\"white\"/>\n <path d=\"M11.2622 13.1788C11.0714 13.1765 10.8627 13.2909 10.8357 13.2744C10.8205 13.2641 10.8469 13.1867 10.8649 13.1418C10.8835 13.0974 11.1345 12.3331 10.5223 12.0673C10.0535 11.8641 9.76711 12.0929 9.66864 12.1965C9.64276 12.2238 9.6315 12.2215 9.62812 12.1868C9.61912 12.0491 9.55779 11.6768 9.15377 11.5516C8.57588 11.3729 8.20393 11.781 8.1094 11.9284C8.0672 11.5949 7.78923 11.3365 7.44767 11.3359C7.07685 11.3359 6.77637 11.6393 6.77637 12.0143C6.77581 12.3888 7.07629 12.6927 7.4471 12.6927C7.62717 12.6933 7.79035 12.6205 7.91077 12.5038C7.91471 12.5072 7.9164 12.5135 7.91414 12.5266C7.88601 12.6939 7.83424 13.304 8.46559 13.5527C8.7188 13.6517 8.93432 13.5777 9.11269 13.4514C9.16559 13.4133 9.17459 13.4292 9.16671 13.4798C9.1442 13.6369 9.1729 13.9727 9.63882 14.1634C9.99275 14.3091 10.2026 14.16 10.3399 14.0319C10.3996 13.9767 10.4159 13.9852 10.4187 14.0706C10.4356 14.5248 10.8087 14.885 11.2611 14.8856C11.7276 14.8856 12.1057 14.5043 12.1057 14.033C12.1062 13.5612 11.7287 13.1839 11.2622 13.1788Z\" fill=\"white\"/>\n <path d=\"M11.2626 14.8251C10.84 14.8245 10.4962 14.4921 10.4804 14.0693C10.4799 14.0328 10.4759 13.9361 10.3955 13.9361C10.3617 13.9361 10.333 13.9566 10.2998 13.9867C10.207 14.0738 10.0888 14.1626 9.91606 14.1626C9.83728 14.1626 9.75232 14.1438 9.66285 14.1068C9.21606 13.9241 9.20987 13.614 9.22788 13.4893C9.23294 13.4557 9.23463 13.421 9.21212 13.3943L9.18455 13.3698H9.15698C9.13447 13.3698 9.11084 13.3789 9.07933 13.4017C8.94991 13.4933 8.82611 13.5377 8.70007 13.5377C8.63086 13.5377 8.55996 13.5235 8.48849 13.4956C7.90104 13.2645 7.94774 12.7034 7.97644 12.5349C7.98038 12.5002 7.97194 12.474 7.95055 12.4564L7.90891 12.4216L7.87009 12.4592C7.75586 12.5707 7.60562 12.6322 7.44863 12.6322C7.11157 12.6316 6.83754 12.355 6.8381 12.0147C6.8381 11.6738 7.11269 11.3978 7.44919 11.3978C7.75361 11.3978 8.01245 11.6294 8.05128 11.9367L8.0721 12.1024L8.16213 11.9623C8.17226 11.9458 8.41872 11.5685 8.87225 11.5691C8.95835 11.5691 9.04725 11.5827 9.13729 11.6112C9.49854 11.7227 9.55987 12.054 9.56944 12.1923C9.57563 12.2725 9.63246 12.2765 9.64371 12.2765C9.67466 12.2765 9.69773 12.2566 9.71405 12.2389C9.78214 12.1672 9.93069 12.0477 10.1631 12.0477C10.2694 12.0477 10.3831 12.0733 10.4996 12.124C11.0741 12.3733 10.8136 13.1114 10.8108 13.1194C10.7612 13.2418 10.759 13.2958 10.8057 13.3271L10.8282 13.3379H10.8451C10.871 13.3379 10.903 13.3266 10.9559 13.3083C11.0341 13.281 11.1523 13.24 11.2626 13.24H11.2632C11.6953 13.2452 12.047 13.6009 12.047 14.0334C12.0464 14.4699 11.6948 14.8251 11.2626 14.8251ZM17.3487 11.2669C16.4 10.4297 14.2078 8.50204 13.6141 8.05073C13.2748 7.79291 13.0435 7.65632 12.8404 7.59542C12.7492 7.56754 12.6226 7.53566 12.46 7.53566C12.3092 7.53566 12.1472 7.56298 11.9778 7.61762C11.594 7.74055 11.212 8.04788 10.8417 8.34497L10.8226 8.36033C10.4782 8.6375 10.1226 8.92377 9.85304 8.98467C9.73543 9.01142 9.61445 9.02507 9.49404 9.02507C9.19187 9.02507 8.92121 8.93686 8.81936 8.80596C8.80248 8.78376 8.81317 8.74905 8.85256 8.69839L8.85819 8.69156L9.69267 7.7821C10.346 7.12077 10.9632 6.497 12.3846 6.46399C12.4077 6.46343 12.4319 6.46286 12.4555 6.46286C13.3401 6.46343 14.2241 6.86409 14.3231 6.91019C15.1525 7.3194 16.009 7.52713 16.8693 7.5277C17.7663 7.52827 18.6919 7.30346 19.6648 6.85043C19.5562 6.75823 19.4431 6.66831 19.3266 6.5801C18.4719 6.95458 17.6577 7.1441 16.8721 7.1441C16.0692 7.14297 15.2679 6.94832 14.4891 6.56416C14.448 6.54424 13.4718 6.07869 12.4555 6.07812C12.4291 6.07812 12.4021 6.07869 12.3756 6.07926C11.1821 6.10715 10.5097 6.53627 10.0573 6.9119C9.61783 6.92271 9.23801 7.02971 8.90095 7.12532C8.59935 7.20955 8.33938 7.28297 8.0856 7.28297C7.98094 7.28297 7.793 7.2733 7.77612 7.27273C7.48464 7.26362 6.01431 6.89938 4.84502 6.45147C4.72573 6.53684 4.61094 6.62506 4.49896 6.71498C5.72058 7.22151 7.20723 7.61307 7.67652 7.6438C7.80707 7.6529 7.94605 7.6677 8.08504 7.6677C8.39565 7.6677 8.70513 7.58006 9.00505 7.49526C9.18174 7.4446 9.37699 7.38997 9.58294 7.35013C9.5278 7.40476 9.47322 7.45997 9.41807 7.51518L8.57065 8.44286C8.50369 8.51115 8.35851 8.69327 8.45417 8.91694C8.49243 9.00743 8.56952 9.09394 8.67756 9.16736C8.87901 9.30509 9.24082 9.39785 9.57732 9.39842C9.70449 9.39842 9.82547 9.38533 9.93632 9.36029C10.2914 9.27948 10.6644 8.97898 11.0595 8.6614C11.374 8.40871 11.8208 8.08772 12.1635 7.99324C12.2591 7.96706 12.3767 7.95056 12.4707 7.95056C12.4988 7.95113 12.5259 7.9517 12.5506 7.95568C12.7768 7.98414 12.9951 8.06211 13.3857 8.35862C14.0817 8.88735 17.1614 11.6123 17.1918 11.6397C17.1934 11.6414 17.3898 11.8121 17.3763 12.0972C17.369 12.256 17.2818 12.3972 17.1304 12.4951C16.9987 12.5793 16.8631 12.622 16.7264 12.622C16.5205 12.622 16.3787 12.5241 16.3691 12.5178C16.3578 12.5081 15.3028 11.5298 14.9145 11.2009C14.8526 11.1491 14.7924 11.1024 14.7316 11.1024C14.6996 11.1024 14.6709 11.1161 14.6512 11.1411C14.5904 11.2174 14.6585 11.3226 14.7395 11.3921L15.9718 12.6447C15.9735 12.6464 16.1254 12.7904 16.1418 12.9828C16.1519 13.1905 16.0534 13.3641 15.8492 13.4996C15.704 13.5963 15.5566 13.6458 15.4125 13.6458C15.2234 13.6458 15.0901 13.5582 15.0608 13.5377L14.8841 13.3613C14.5611 13.0397 14.2275 12.7073 13.9832 12.5013C13.9236 12.4512 13.86 12.4051 13.7992 12.4051C13.7694 12.4051 13.7424 12.4159 13.7216 12.4381C13.694 12.4694 13.6743 12.5258 13.7441 12.6191C13.7722 12.6573 13.806 12.6891 13.806 12.6891L14.7058 13.7113C14.7131 13.7204 14.8909 13.9344 14.726 14.1472L14.6939 14.1876C14.6675 14.2178 14.6382 14.2457 14.6107 14.2696C14.457 14.3971 14.2522 14.4107 14.1712 14.4107C14.1279 14.4107 14.0857 14.4068 14.0496 14.3999C13.9607 14.384 13.9011 14.359 13.8718 14.3242L13.8611 14.3129C13.8122 14.2616 13.3587 13.7932 12.9833 13.4768C12.9344 13.4347 12.8725 13.3818 12.8089 13.3818C12.7774 13.3818 12.7492 13.3943 12.7273 13.4187C12.653 13.5007 12.7644 13.6236 12.8117 13.6692L13.5792 14.5246C13.5781 14.532 13.5685 14.5496 13.55 14.5769C13.5224 14.6151 13.4296 14.7095 13.151 14.7448C13.1178 14.7494 13.0835 14.7511 13.0492 14.7511C12.7622 14.7511 12.4561 14.6099 12.2985 14.5257C12.3706 14.372 12.4077 14.203 12.4077 14.034C12.4077 13.3948 11.8951 12.8752 11.2637 12.8752C11.2502 12.8752 11.2362 12.8752 11.2226 12.8758C11.2429 12.5844 11.2024 12.0324 10.6419 11.7893C10.4804 11.7188 10.3195 11.6829 10.1636 11.6829C10.041 11.6829 9.92338 11.704 9.81309 11.7466C9.69661 11.5184 9.50416 11.3522 9.25264 11.2657C9.11365 11.2174 8.97523 11.1923 8.84187 11.1923C8.60835 11.1923 8.39396 11.2618 8.20208 11.3995C8.01864 11.169 7.74123 11.0318 7.44919 11.0318C7.19372 11.0318 6.94782 11.1354 6.76607 11.3181C6.52693 11.1337 5.5799 10.5247 3.04438 9.94251C2.92171 9.91462 2.64037 9.83267 2.46762 9.78202C2.43892 9.92031 2.41697 10.0609 2.40234 10.2026C2.40234 10.2026 2.86995 10.3159 2.96223 10.3369C5.55233 10.9186 6.40763 11.5236 6.55281 11.6379C6.50329 11.7569 6.47797 11.8849 6.47797 12.0147C6.47741 12.5554 6.91294 12.9965 7.44806 12.997C7.50827 12.997 7.56792 12.9913 7.62588 12.9805C7.7069 13.3789 7.96462 13.6811 8.35795 13.8359C8.4733 13.8803 8.58978 13.9036 8.70401 13.9036C8.77772 13.9036 8.85256 13.8945 8.92515 13.8758C8.99774 14.0624 9.16148 14.2952 9.52724 14.4455C9.65553 14.4978 9.78383 14.5251 9.90818 14.5251C10.01 14.5251 10.1096 14.5069 10.2047 14.4716C10.3797 14.9036 10.7972 15.1893 11.262 15.1893C11.5704 15.1899 11.8664 15.063 12.0825 14.8382C12.267 14.9423 12.657 15.1301 13.0509 15.1307C13.1021 15.1307 13.1499 15.1267 13.1977 15.121C13.5894 15.0715 13.7711 14.9161 13.855 14.796C13.8701 14.775 13.8836 14.7528 13.8955 14.7295C13.9877 14.7568 14.089 14.7784 14.2055 14.779C14.4193 14.779 14.6247 14.705 14.8318 14.5519C15.0355 14.4039 15.1801 14.1905 15.2009 14.0089C15.2015 14.0061 15.2021 14.0038 15.2026 14.001C15.2707 14.0152 15.3416 14.0226 15.4119 14.0226C15.632 14.0226 15.848 13.9532 16.0551 13.816C16.4541 13.5519 16.5233 13.2065 16.5171 12.98C16.5863 12.9947 16.6578 13.0021 16.7287 13.0021C16.9352 13.0021 17.1383 12.9395 17.3313 12.8149C17.5789 12.655 17.7274 12.4103 17.75 12.1251C17.7657 11.9316 17.7184 11.7364 17.6172 11.5685C18.2856 11.2771 19.8134 10.7137 21.6123 10.3033C21.6016 10.1622 21.5814 10.0228 21.5566 9.88389C19.3801 10.3728 17.7556 11.0836 17.3487 11.2669Z\" fill=\"#5C6477\"/>\n </SvgIcon>\n )\n};\nexport default ScheduledSendIcon;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\nexport const useStyles = makeStyles((theme) => ({\n root: {},\n popper:{\n [`& .MuiTooltip-tooltip`]: {\n padding: \"4px 8px\",\n borderRadius: \"5px\",\n backgroundColor: Color.gray1,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n color: theme.colors.grey5,\n boxShadow: \"0px 0px 4px #00000034\"\n }\n }\n}));","import React from \"react\"\nimport ScheduledSendIcon from \"../../../assets/icons/ScheduledSendIcon\";\nimport {Tooltip} from \"@material-ui/core\";\nimport {useStyles} from \"./css\";\n\nconst ScheduledSendIconWithTooltip = (props: any) => {\n const { title, ...otherProps } = props;\n const classes = useStyles();\n const style = {\n display: \"flex\"\n }\n return (\n <Tooltip title={title} classes={{popper: classes.popper}}>\n <span style={style}>\n <ScheduledSendIcon {...otherProps} />\n </span>\n </Tooltip>\n )\n};\nexport default ScheduledSendIconWithTooltip;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n\n backgroundColor: Color.gray6,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n\n position: \"relative\",\n height: \"80vh\",\n width: \"65vw\"\n },\n indicatorContainer: {\n backgroundColor: Color.gray1,\n borderRadius: \"0px 0px 10px 10px\",\n height: \"48px\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n marginTop: \"0px\",\n position: \"absolute\",\n bottom: 0,\n width: \"100%\"\n },\n indicatorBulletInactive: {\n color: Color.gray2,\n \"&:hover\": {\n color: Color.clear3\n },\n },\n indicatorBulletActive: {\n color: Color.clear1\n },\n exitButton: {\n position: \"absolute\",\n top: 10,\n right: 10,\n height: 47,\n width: 47,\n borderRadius: \"50%\",\n backgroundColor: \"black\",\n filter: \"brightness(120%)\",\n opacity: \"0.4\",\n zIndex: 998,\n transition: \"200ms\",\n cursor: \"pointer\",\n \"&:hover\": {\n opacity: \"0.6 !important\"\n },\n },\n crossIcon: {\n position: \"absolute\",\n top: 17,\n left: 16,\n color: Color.gray1,\n zIndex: 999\n },\n carouselItem: {\n display: \"block\",\n marginLeft: \"auto\",\n marginRight: \"auto\",\n maxHeight: \"calc(80vh - 48px)\",\n maxWidth: \"calc(65vw - 140px)\",\n width: \"auto\",\n transition: \"transform 0.3s ease\",\n zIndex: 998,\n },\n zoomInCursor: {\n cursor: \"zoom-in\",\n },\n zoomedImage: {\n transform: \"scale(1.6)\",\n cursor: \"zoom-out\",\n zIndex: 999,\n },\n carouselRoot: {\n position: \"relative\",\n height: \"80vh\",\n width: \"65vw\",\n overflow: \"unset !important\"\n },\n mediaWrapper: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n position: \"relative\",\n height: \"calc(80vh - 48px)\",\n },\n hidden: {\n visibility: \"hidden\"\n },\n carouselItemText: {\n ...theme.typography.txtBody1,\n display: \"-webkit-box\",\n WebkitLineClamp: 2,\n WebkitBoxOrient: \"vertical\",\n whiteSpace: \"normal\",\n textOverflow: \"ellipsis\",\n overflow: \"hidden\",\n maxWidth: \"50%\"\n }\n}));","import React, { useEffect, useState } from \"react\";\n\nimport Carousel from \"react-material-ui-carousel\";\n\nimport { Backdrop, Fade, Modal, Tooltip, Typography } from \"@material-ui/core\";\n\nimport { CrossIcon } from \"../../../assets/icons\";\nimport { Message } from \"../../../models/message\";\nimport { useStyles } from \"./css\";\nimport { ConversationMessageType } from \"../../../models/enums/conversation-message-type\";\nimport Interweave from \"interweave\";\n\n\nexport default function ImageCarousel(props: any) {\n\n const classes = useStyles();\n const {\n messages,\n carouselIsOpen,\n closeCarousel,\n activeImageIndex,\n imagesCount,\n ...otherProps\n } = props;\n\n const [zoomedIn, setZoomedIn] = useState(false);\n const [activeChildIndex, setActiveChildIndex] = useState<number>(activeImageIndex);\n const [changedFromArrowKeys, setChangedFromArrowKeys] = useState(false);\n const carouselItems = getMappedObjects();\n const linkRegex = new RegExp(\"[Hh]ttps?:\\\\/\\\\/(www\\\\.)?[-a-zA-Z0-9@:%._\\+~#=]{2,256}\\\\.[a-z]{2,4}\\\\b([-a-zA-Z0-9@:%_\\+.~#?&/=]*)\");\n //HACK: need to prevent the second(and loop-like) Carousel rerender when using keys to navigate - it's a carousel package bug\n\n function encaseLinksWithTags(str: string) {\n if (str === null) return str;\n const matches = str.match(linkRegex);\n if (matches && matches.length > 0) {\n let newStr = str;\n newStr = newStr.replace(matches[0], `<a target=\"_blank\" href=\"${matches[0]}\">${matches[0]}</a>`)\n return newStr;\n } else {\n return str;\n }\n }\n\n useEffect(() => {\n setActiveChildIndex(activeChildIndex);\n document.addEventListener(\"keydown\", changeChild);\n\n return function cleanup() {\n document.removeEventListener(\"keydown\", changeChild);\n };\n }, []);\n\n const handleIndexChange = (curIndex: number, prevIndex: number) => {\n if (curIndex === prevIndex)\n return; //HACK: is described above\n if (changedFromArrowKeys) { //HACK: is described above\n setChangedFromArrowKeys(false);\n return;\n }\n setActiveChildIndex(curIndex);\n setZoomedIn(false);\n };\n\n const handleZoom = () => {\n setZoomedIn(prev => !prev);\n };\n\n function getMappedObjects() {\n const mappedObjs = messages\n .filter((m: Message) =>\n m.originalFileName &&\n m.previewFileUrl &&\n (m.type === ConversationMessageType.Image || m.type === ConversationMessageType.Video))\n .map((m: Message) => ({ id: m.id, time: m.time, type: m.type, fileUrl: m.fileUrl!, originalFileName: m.originalFileName, text: m.text || \"\" }))\n .sort((o: { time: any; }) => o.time);\n\n return mappedObjs;\n };\n\n const changeChild = (e: KeyboardEvent) => {\n if (e.key === \"ArrowLeft\") {\n setChangedFromArrowKeys(true);\n setActiveChildIndex((i: number) => (i <= 0 ? i : i - 1));\n } else if (e.key === \"ArrowRight\") {\n setChangedFromArrowKeys(true);\n setActiveChildIndex((i: number) => (i >= imagesCount - 1 ? i : i + 1));\n }\n setZoomedIn(false);\n };\n\n function mapComponents() {\n return carouselItems.map(mapCarouselItem)\n }\n\n function mapCarouselItem(item: Message) {\n const { type, fileUrl, text, originalFileName } = item;\n const cleanText = text.replace(/<[^<>]+>/g, \" \");\n if (type === ConversationMessageType.Video) {\n return (\n <>\n <div className={classes.mediaWrapper}>\n <video\n className={classes.carouselItem}\n src={fileUrl}\n controls\n />\n </div>\n <div className={`${classes.indicatorContainer}`}>\n <Tooltip title={(text && text !== originalFileName) ?\n <Interweave content={(text && text !== originalFileName) ? encaseLinksWithTags(text) : \"\"} /> : \"\"}\n >\n <Typography className={`${classes.carouselItemText}`}>\n <Interweave content={(text && text !== originalFileName) ? encaseLinksWithTags(text) : \"\"}/>\n </Typography>\n </Tooltip>\n </div>\n </>\n )\n }\n\n return (\n <>\n <div className={classes.mediaWrapper}>\n <img\n src={fileUrl}\n className={`${classes.carouselItem} ${classes.zoomInCursor} ${zoomedIn ? classes.zoomedImage : \"\"}`}\n onClick={handleZoom}\n alt=\"image\"\n />\n </div>\n \n <div className={`${classes.indicatorContainer}`}>\n <Tooltip title={(text && text !== originalFileName) ? \n <Interweave content={(text && text !== originalFileName) ? encaseLinksWithTags(text) : \"\"} /> : \"\"}\n >\n <Typography className={`${classes.carouselItemText}`}>\n <Interweave content={(text && text !== originalFileName) ? encaseLinksWithTags(text) : \"\"} />\n </Typography>\n </Tooltip>\n </div>\n\n </>\n );\n }\n\n function getIndicatorContainerProps(index: number) {\n const carouselItem = carouselItems[index];\n\n if (!carouselItem) return;\n\n const { type, text, originalFileName } = carouselItem;\n const showIndicator = !((type === ConversationMessageType.Image || type === ConversationMessageType.Video) && text && text !== originalFileName);\n\n return {\n className: showIndicator\n ? classes.indicatorContainer\n : classes.hidden\n };\n };\n\n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={carouselIsOpen}\n onClose={closeCarousel}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade\n in={carouselIsOpen}\n >\n <div className={classes.paper}>\n <div\n onClick={closeCarousel}\n className={classes.exitButton}>\n <CrossIcon className={classes.crossIcon} />\n </div>\n <Carousel\n index={activeChildIndex}\n onChange={handleIndexChange}\n autoPlay={false}\n indicators={true}\n swipe={false}\n cycleNavigation={false}\n className={classes.carouselRoot}\n navButtonsWrapperProps={{\n }}\n indicatorContainerProps={getIndicatorContainerProps(activeChildIndex)}\n indicatorIconButtonProps={{\n className: `${classes.indicatorBulletInactive}`\n }}\n activeIndicatorIconButtonProps={{\n className: `${classes.indicatorBulletActive}`\n }}\n >\n {mapComponents()}\n </Carousel>\n </div>\n\n </Fade>\n </Modal>\n </>\n}","export enum SnackbarNotificationKind {\n // these require some extra positioning\n whatsappChatWindowLinkCopied\n}\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles(theme => ({\n snackbarChatWindow: {\n marginBottom: \"58px\",\n // center it in the message window rather than entire screen,\n // chat list sidebar is 360px\n left: \"calc(50% + 180px)\",\n },\n}));\n","import React from \"react\";\nimport { Button, Snackbar } from \"@material-ui/core\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { useStyles } from \"./css\";\nimport { SnackbarNotificationProps } from \"./props\";\nimport { SnackbarNotificationKind } from \"./snackbar-notification-kind\";\n\nconst SnackbarNotification = (props: SnackbarNotificationProps) => {\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n const {\n isOpen,\n onClose,\n message,\n notificationKind\n } = props;\n\n const classToUse = notificationKind === SnackbarNotificationKind.whatsappChatWindowLinkCopied\n ? classes.snackbarChatWindow\n : \"\";\n\n const handleClose = (event: React.SyntheticEvent | Event, reason?: string) => {\n if (reason === \"clickaway\") {\n return;\n }\n if (onClose) {\n onClose();\n }\n };\n\n const closeAction = (\n <Button\n color={\"primary\"}\n size={\"small\"}\n onClick={handleClose}\n >\n {t(\"Close\").toUpperCase()}\n </Button>\n );\n\n return (\n <Snackbar\n open={isOpen}\n autoHideDuration={5000}\n onClose={handleClose}\n anchorOrigin={{horizontal: \"center\", vertical: \"bottom\"}}\n key={message}\n className={classToUse}\n action={closeAction}\n message={message}\n />\n );\n};\n\nexport default SnackbarNotification;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n select: {\n ...theme.typography.subtitle1,\n backgroundColor: theme.colors.clearGreen,\n height: 40,\n justifyContent: \"center\",\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 100,\n cursor: \"pointer\",\n width: 600,\n \"& .MuiSvgIcon-root\": {\n right: \"unset\",\n left: 190,\n top: 14\n },\n \n \"&.Mui-disabled\": {\n opacity: 0.5,\n border: \"solid 1px rgba(0, 0, 0, 0.05)\",\n }\n },\n tooltipBlock: {\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n boxShadow: \"0px 4px 4px 0px\",\n borderRadius: 5,\n \"& .MuiTooltip-arrow\": {\n color: theme.colors.grey1,\n },\n },\n selected: {\n fontWeight: \"bold\",\n textAlign: \"center\",\n width: 450,\n padding: \"11px 0px 12px 12px\",\n },\n tooltipContainer: {\n width: \"100%\",\n height: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n },\n selectContainer: {\n display: \"flex\",\n alignItems: \"center\",\n position: \"relative\",\n },\n arrowIcon: {\n position: \"absolute\",\n zIndex: 5,\n color: \"#F6F6F6\",\n left: \"8px\",\n },\n focused: {\n color: theme.colors.grey1,\n textAlign: \"center\",\n \"&:focus\": {\n backgroundColor: theme.colors.clearGreen,\n },\n \"& .MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 100,\n },\n },\n },\n menuPaper: {\n maxHeight: 300,\n marginTop: 6,\n },\n itemRoot: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey5,\n height: 40,\n display: \"flex\",\n gap: 12,\n alignItems: \"center\",\n \"&.Mui-focusVisible\": {\n backgroundColor: \"inherit\",\n \"&:hover\": {\n backgroundColor: \"#F6F6F6 !important\",\n },\n },\n \"&.Mui-disabled\": {\n opacity: \"1!important\",\n backgroundColor: \"#F6F6F6\",\n },\n },\n itemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain,\n },\n}));\n\nexport default useStyles;\n","import React, { useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Input from \"@material-ui/core/Input\";\nimport MuiSelect from \"@material-ui/core/Select\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\nimport Tooltip from \"@material-ui/core/Tooltip\";\n\nimport ArrowDropDownIcon from \"./../../../assets/icons/ArrowDropDownIcon\";\nimport SheetIcon from \"../../../assets/icons/SheetIcon\";\nimport { SelectWhatsAppTemplateProps } from \"./props\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\"\nimport { WhatsAppTemplateType } from \"../../../models/enums/whatsapp-template-type\";\nimport useStyles from \"./css\";\n\nexport default function SelectWhatsappTemplate(props: SelectWhatsAppTemplateProps) {\n const {\n value,\n setValue,\n name,\n items,\n onOpen,\n styleClass,\n classes,\n availableTemplates,\n disabled\n } = props;\n const useClasses = useStyles();\n const { t } = useTranslation([\"general\"]);\n \n const [isOpen, setIsOpen] = useState<boolean>(false);\n \n function handleOnChange(key: WhatsAppTemplateType) {\n setValue(key);\n };\n \n function handleOnOpen() {\n setIsOpen(true);\n onOpen();\n }\n \n function getTitleByKey(key: any) {\n const availableTemplate = availableTemplates.find(template => template.templateType === key);\n return availableTemplate ? availableTemplate.templateText : \"\";\n }\n\n const ArrowIcon = (props: any) => (\n <ArrowDropDownIcon\n {...props}\n style={{ right: 12, top: 6, height: \"22px!important\", color: \"#F6F6F6\" }}\n />\n );\n\n return (\n <MuiSelect\n disabled={disabled === true}\n disableUnderline\n classes={\n classes || {\n root: `${useClasses.focused} ${useClasses.selected}`,\n }\n }\n name={name}\n className={styleClass ?? useClasses.select}\n input={<Input />}\n MenuProps={\n { \n style: { position: \"absolute\", top: -47 },\n classes: { paper: useClasses.menuPaper },\n }}\n displayEmpty\n renderValue={(selected) => (\n <span>\n {t(\"Send WhatsApp template\")}\n </span>\n )}\n onOpen={handleOnOpen}\n onClose={() => setIsOpen(false)}\n value={value === undefined || value === null ? \"\" : value}\n IconComponent={ArrowIcon}\n \n >\n <MenuItem classes={{ root: `${useClasses.itemRoot}`, }} value=\"\" disabled>\n <SheetIcon/> {t(\"WhatsApp templates\")}\n </MenuItem>\n {items.map((item: SelectItem) => (\n <MenuItem\n classes={{\n root: `${ useClasses.itemRoot}`,\n selected: useClasses.itemSelected,\n }}\n value={item.key}\n onClick={() => handleOnChange(item.key)}\n disabled={item?.disabled ?? false}\n >\n <Tooltip\n key={item.key}\n title={isOpen\n ? (<div dangerouslySetInnerHTML={{ __html: getTitleByKey(item.key) }}/>)\n : \"\"}\n classes={{ tooltip: useClasses.tooltipBlock }}\n >\n <div className={useClasses.tooltipContainer} key={item.key}>\n {item.value}\n </div>\n </Tooltip>\n </MenuItem>\n ))}\n </MuiSelect>\n );\n};","export enum WhatsAppTemplateType {\n AfterGivingAQuote = 1,\n AfterAppointmentNoShow,\n AfterNotAnsweringCustomerQuestion,\n OnPendingPaymentWithMercadoPagoLink,\n SiteForAppointmentsLink\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles(theme => ({\n toolbarWrapper: {\n position: \"absolute\",\n top: \"0\",\n right: \"14px\",\n width: \"fit-content\",\n height: \"100%\",\n // the IconButton itself has 3px of padding, we need 8px in total\n padding: \"5px 0\",\n display: \"flex\",\n flexDirection: \"row\",\n // currently unused as there is only one button\n gap: \"14px\",\n },\n}));\n","import React, { useEffect, useState } from \"react\";\nimport { IconButton, Tooltip } from \"@material-ui/core\";\nimport { CopyToClipboard } from \"react-copy-to-clipboard\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { AccountService } from \"../../../api/account-service\";\nimport { LinkIcon } from \"../../../assets/icons\";\nimport { useStyles } from \"./css\";\nimport { ChatToolbarProps } from \"./props\";\n\nconst ChatToolbar = (props: ChatToolbarProps) => {\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const {\n onCopyLinkClick\n } = props;\n\n const [siteLink, setSiteLink] = useState<string>(\"\");\n\n useEffect(() => {\n AccountService.getAccountSubdomain().then(businessNameUrl => {\n setSiteLink(\"https://sitiodereservas.somosclear.com/\" + businessNameUrl);\n });\n }, [siteLink]);\n\n const CopyToClipboardMemo = React.memo(() => {\n return <CopyToClipboard text={siteLink}>\n <IconButton\n size={\"small\"}\n disabled={!siteLink}\n onClick={onCopyLinkClick}\n >\n <LinkIcon />\n </IconButton>\n </CopyToClipboard>\n });\n\n return (\n <div className={classes.toolbarWrapper}>\n <Tooltip arrow={true} placement={\"top\"} title={`${t(\"Copy link from my Site for appointments\")}`}>\n <CopyToClipboardMemo/>\n </Tooltip>\n </div>\n );\n}\n\nexport default ChatToolbar;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n iconButton: {\n width: 40,\n height: 40,\n backgroundColor: \"#FFF\",\n \"&:hover\": {\n color: \"#fff\",\n backgroundColor: theme.colors.clearRed,\n },\n \"&.blocked:hover\": {\n color: \"#fff\",\n backgroundColor: theme.colors.clearGreen,\n },\n },\n tooltipBlock: {\n backgroundColor: theme.colors.grey1,\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n borderRadius: 5,\n boxShadow: \"0px 4px 4px 0px\",\n },\n })\n);\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport IconButton from \"@material-ui/core/IconButton\";\n\nimport useStyles from \"./css\";\nimport { BlockCustomerIconProps } from \"./props\";\nimport { BlockIcon } from \"../../../assets/icons\";\nimport CloseIcon from \"@material-ui/icons/Close\";\nimport { Tooltip } from \"@material-ui/core\";\nimport { useTranslation } from \"react-i18next\";\n\n\nexport default function BlockCustomerIcon(props: BlockCustomerIconProps) {\n\n const { isBlocked, isRegistered, onClick } = props;\n \n const { t } = useTranslation([\"general\"]);\n \n const [isHovered, setIsHovered] = useState<boolean>(false);\n \n const classes = useStyles();\n \n return (\n <Tooltip placement={\"bottom\"}\n title={`${isBlocked\n ? isRegistered\n ? t(\"Unblock customer\")\n : t(\"Unblock number\")\n : isRegistered\n ? t(\"Block customer\")\n : t(\"Block number\")}`}\n classes={{ tooltip: classes.tooltipBlock }}>\n <IconButton\n className={`${classes.iconButton} ${isBlocked ? 'blocked' : ''}`}\n onClick={onClick}\n onMouseEnter={() => setIsHovered(true)}\n onMouseLeave={() => setIsHovered(false)}\n >\n <BlockIcon\n viewBox={\"0 0 16 16\"}\n style={{\n width: 16,\n height: 16,\n marginLeft: 1,\n fontSize: '16px',\n }}\n color={isHovered ? \"#FFFFFF\" : \"#919CA5\"}\n />\n </IconButton>\n </Tooltip>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalPaper: {\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid red\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"18px 24px 24px 24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid red\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontFamily: \"Inter, sans-serif\",\n color: \"#26292B\",\n },\n modalSubTitleText: {\n fontSize: \"14px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontFamily: \"Inter, sans-serif\",\n color: \"#5C6477\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid #F15857\",\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#5C6477\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continue: {\n background: \"#F15857\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#F15857\",\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { TrashIcon, CrossIcon } from \"../../../assets/icons\";\n\nimport useStyles from \"./css\";\nimport { BlockCustomerModalProps } from \"./props\";\n\nconst BlockCustomerModal = (props: BlockCustomerModalProps) => {\n const { open, customerName, onClose, onContinue } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <TrashIcon />\n </div>\n </div>\n </div>\n <div className={classes.modalContent}>\n {isNaN(+customerName) &&\n <>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {t(\"Do you want to block this customer?\")}\n </Typography>\n </div>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalSubTitleText}>\n {customerName}\n </Typography>\n </div>\n </>\n }\n {!isNaN(+customerName) &&\n <>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {t(\"Do you want to block\")} \n +{customerName}?\n </Typography>\n </div>\n </>\n }\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {isNaN(+customerName)\n ? t(\"If you proceed, you will not be able to send or receive messages from this customer. You can unblock this number at any time.\")\n : t(\"If you proceed, you will not be able to send or receive messages from this number. You can unblock this number at any time.\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.continue}`}\n onClick={onContinue}\n >\n {t(\"Yes, block\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default BlockCustomerModal;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modalYellow: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n },\n modalPaperYellow: {\n backgroundColor: theme.palette.background.paper,\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"#FFC626\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n padding: \"24px\",\n width: 464,\n \"&:focus:not(:focus-visible)\": {\n outline: \"none\",\n },\n \"&:focus-visible\": {\n outline: \"none\",\n border: \"1px solid #FFC626\",\n },\n },\n modalHeader: {\n // display: \"flex\",\n alignItems: \"center\",\n },\n modalHeaderContent: {\n display: \"flex\",\n justifyContent: \"center\",\n width: \"100%\",\n },\n modalClose: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n width: \"100%\",\n },\n closeButton: {\n cursor: \"pointer\",\n color: \"#919CA5\",\n height: 14,\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontFamily: \"Inter, sans-serif\",\n color: \"#26292B\",\n },\n modalSubTitleText: {\n fontSize: \"14px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontFamily: \"Inter, sans-serif\",\n color: \"#5C6477\",\n },\n modalContent: {},\n modalCircle: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: \"50%\",\n border: \"1px solid \" + theme.colors.clearYellow,\n width: \"50px\",\n height: \"50px\",\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n marginTop: 24,\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#5C6477\",\n },\n modalDateText: {\n ...theme.typography.txtBody2,\n paddingTop: 7,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n marginTop: 32,\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continue: {\n background: theme.colors.clearYellow,\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: theme.colors.clearYellow,\n },\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n}));\n\nexport default useStyles;\n","import React from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { CrossIcon, StopHandIcon } from \"../../../assets/icons\";\n\nimport useStyles from \"./css\";\nimport { UnblockCustomerModalProps } from \"./props\";\n\nconst UnblockCustomerModal = (props: UnblockCustomerModalProps) => {\n const { open, customerName, onClose, onContinue } = props;\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modalYellow}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.modalPaperYellow}>\n <div className={classes.modalHeader}>\n <div className={classes.modalClose}>\n <CrossIcon\n className={classes.closeButton}\n onClick={onClose}\n viewBox=\"0 0 14 14\"\n style={{ width: 14, height: 14 }}\n />\n </div>\n <div className={classes.modalHeaderContent}>\n <div className={classes.modalCircle}>\n <StopHandIcon />\n </div>\n </div>\n </div>\n <div className={classes.modalContent}>\n {isNaN(+customerName) &&\n <>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {t(\"Unblock this customer?\")}\n </Typography>\n </div>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalSubTitleText}>\n {customerName}\n </Typography>\n </div>\n </>\n }\n {!isNaN(+customerName) &&\n <>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`}>\n <Typography className={classes.modalTitleText}>\n {t(\"Unblock\")} \n +{customerName}?\n </Typography>\n </div>\n </>\n }\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }}></div>\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {isNaN(+customerName)\n ? t(\"If you proceed, you will be able to send and receive messages from this customer. You can block the customer again at any time.\")\n : t(\"If you proceed, you will be able to send and receive messages from this number. You can block the number again at any time.\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={onClose}\n >\n {t(\"Go back\")}\n </Button>\n <Button\n className={`${classes.button} ${classes.continue}`}\n onClick={onContinue}\n >\n {t(\"Unblock\")}\n </Button>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n};\n\nexport default UnblockCustomerModal;\n","import React, { ReactNode, forwardRef, useCallback, useEffect, useImperativeHandle, useRef, useState } from \"react\";\nimport { Button, Grid, Tooltip, TextareaAutosize, Typography, Menu, MenuItem, ListItemText, ListItemIcon } from \"@material-ui/core\";\nimport CloseIcon from \"@material-ui/icons/Close\";\n\nimport { useDispatch } from 'react-redux';\nimport { alertsActions } from \"../../../redux/alerts-slice\";\nimport { useStyles } from \"./css\";\nimport { WhatsAppService } from \"../../../api/whatsapp-service\"\n\nimport { Message as MessageModel } from \"../../../models/message\";\n\nimport Message from \"./../Message\";\nimport ArrowDropDownTriangleIcon from \"../../../assets/icons/ArrowDropDownTriangleIcon\";\nimport ScheduledSendIcon from \"../../../assets/icons/ScheduledSendIcon\";\nimport MercadoPagoLinkIcon from \"../../../assets/icons/MercadoPagoLinkIcon\";\nimport ScheduledSendIconWithTooltip from \"../common/ScheduledSendIconWithTooltip\"\nimport { useTranslation } from \"react-i18next\";\nimport moment from \"moment\";\nimport \"moment-timezone\";\nimport ImageCarousel from \"../ImageCarousel\";\n\nimport SnackbarNotification, { SnackbarNotificationKind } from \"../../common/notifications/SnackbarNotification\";\nimport SelectWhatsappTemplate from \"../SelectWhatsAppTemplate\";\nimport ChatToolbar from \"../ChatToolbar\";\nimport { Markup } from \"interweave\";\nimport MessengerRefs from \"../Messenger/messenger-refs\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\";\nimport { WhatsAppTemplateType } from \"../../../models/enums/whatsapp-template-type\";\nimport { WhatsAppTemplate } from \"../../../models/whatsapp-template\";\nimport { ConversationMessageType } from \"../../../models/enums/conversation-message-type\";\nimport { GetSpecificConversationMessagesResponse } from \"../../../models/get-specific-conversation-messages-response\";\nimport BlockCustomerIcon from \"../BlockCustomerIcon/block-customer-icon\";\nimport BlockCustomerModal from \"../BlockCustomerModal/block-customer-modal\";\nimport UnblockCustomerModal from \"../UnblockCustomerModal\";\nimport ButtonWithSpinner from \"../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsBorderSide } from \"../../../models/enums/button-props-border-side\";\nimport { ButtonPropsColor } from \"../../../models/enums/button-props-color\";\n\nconst ConversationWindowMemo = forwardRef<MessengerRefs, any>((props: any, ref) => {\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n const {\n selectedConversation,\n lastMessageId,\n customerId,\n customerName,\n customerMobile,\n isDisabledActivity,\n isDisabledNotContactable,\n isCustomerBlocked,\n unreadMessagesCount,\n canScheduleFollowUp,\n hasScheduledFollowUp,\n hasUnpaidAppointment,\n markConversationAsRead,\n isSearch,\n foundMessageText,\n establishmentId,\n establishmentName,\n onBlockCustomer\n } = props;\n const isCustomerRegistered= isNaN(+customerName);\n \n const dispatch = useDispatch();\n const { enqueueAlert } = alertsActions;\n const [outMessage, setOutMessage] = useState<string>(\"\");\n const [carouselIsOpen, setCarouselIsOpen] = useState<boolean>(false);\n const [clickedMessageId, setClickedMessageId] = useState<string>(\"\");\n const [anchorSendDropdown, setAnchorSendDropdown] = useState<null | HTMLElement>(null);\n const openSendDropdown = Boolean(anchorSendDropdown);\n const [linkCopiedSnackbarShown, setLinkCopiedSnackbarShown] = useState<boolean>(false);\n const [currentChatMessages, setCurrentChatMessages] = useState<MessageModel[]>([]);\n const [availableTemplates, setAvailableTemplates] = useState<WhatsAppTemplate[]>([]);\n const [templateType, setTemplateType] = useState<WhatsAppTemplateType | null>(null);\n const [openBlockCustomerModal, setOpenBlockCustomerModal] = useState<boolean>(false);\n\n const domObserver = useRef<MutationObserver | null>(null);\n const textInput = useRef<HTMLTextAreaElement>(null);\n const chatWindowRef = useRef<HTMLDivElement>(null);\n const isLoadingRef = useRef<boolean>(false);\n const currentPageNumberRef = useRef<number>(1);\n const messagesOffsetRef = useRef<number>(0);\n const hasMoreRef = useRef<boolean>(true);\n\n const pageSize = 50;\n const templateTypes: SelectItem[] =\n [\n { key: WhatsAppTemplateType.AfterGivingAQuote, value: t(\"Follow-up after giving a quote\") },\n { key: WhatsAppTemplateType.AfterAppointmentNoShow, value: t(\"Follow-up after appointment no show\") },\n { key: WhatsAppTemplateType.SiteForAppointmentsLink, value: t(\"Site for appointments link\") },\n { key: WhatsAppTemplateType.AfterNotAnsweringCustomerQuestion, value: t(\"Follow-up after not answering a customer's question\") },\n { key: WhatsAppTemplateType.OnPendingPaymentWithMercadoPagoLink, value: t(\"Follow-up on pending payment with Mercado Pago link\") },\n ]\n\n const availableTemplateTypes = templateTypes\n .filter(({ key }) => availableTemplates.some(template => template.templateType === key) || key === WhatsAppTemplateType.SiteForAppointmentsLink)\n .sort((a, b) => a.value.localeCompare(b.value));\n\n useImperativeHandle(ref, () => ({\n addNewMessages: (messages) => {\n messagesOffsetRef.current += messages.length;\n setCurrentChatMessages([...currentChatMessages, ...messages]);\n }\n }));\n\n useEffect(() => {\n if (isSearch) {\n const messagesWithHighlightedOne = getMessagesWithHighlightedOne(currentChatMessages);\n setCurrentChatMessages(messagesWithHighlightedOne);\n }\n }, [lastMessageId]);\n\n useEffect(() => {\n resetChatWindowState();\n if (!selectedConversation.customerPhoneNumber)\n return;\n\n (async () => {\n if (customerMobile && customerMobile !== \"\") {\n const response = await fetchFirstPageMessages();\n if (response.messages.length < pageSize)\n hasMoreRef.current = false;\n if (isSearch) {\n const messagesWithHighlightedOne = getMessagesWithHighlightedOne(response.messages);\n currentPageNumberRef.current = response.currentPageNumber;\n setCurrentChatMessages(messagesWithHighlightedOne);\n }\n else {\n setCurrentChatMessages(response.messages);\n }\n }\n })().then(() => {\n if (isSearch) {\n scrollToMessage();\n }\n else {\n scrollToBottom();\n }\n });\n }, [selectedConversation]);\n\n useEffect(() => {\n (async () => {\n if (unreadMessagesCount > 0) {\n await markConversationAsRead(customerMobile);\n }\n })();\n }, [unreadMessagesCount]);\n\n useEffect(() => {\n scrollToMessage();\n }, [lastMessageId]);\n\n useEffect(() => {\n const chatWindowElement = chatWindowRef.current;\n chatWindowElement?.addEventListener(\"scroll\", handleScrollReachTop);\n\n return () => {\n chatWindowElement?.removeEventListener(\"scroll\", handleScrollReachTop);\n };\n }, [customerMobile]);\n\n async function handleScrollReachTop() {\n if (isLoadingRef.current)\n return;\n\n const chatWindow = chatWindowRef.current!;\n const maxScrollTop = 0 - (chatWindow.scrollHeight - chatWindow.clientHeight);\n const hasScrollTrackAtVisualTop = chatWindow.scrollTop - 1 <= maxScrollTop;\n const hasScroll = maxScrollTop !== 0;\n if (hasScroll && hasScrollTrackAtVisualTop) {\n await loadMoreMessages();\n }\n\n };\n\n async function fetchFirstPageMessages(): Promise<GetSpecificConversationMessagesResponse> {\n switch (true) {\n case (!isSearch && !establishmentId):\n return await WhatsAppService.getSpecificConversationMessages(\n customerMobile,\n 0,\n null,\n 1,\n null);\n case (isSearch && !establishmentId):\n return await WhatsAppService.getSpecificConversationMessages(\n customerMobile,\n 0,\n null,\n null,\n lastMessageId);\n case (!isSearch && !!establishmentId):\n return await WhatsAppService.getSpecificConversationMessages(\n customerMobile,\n 0,\n establishmentId,\n 1,\n null);\n case (isSearch && establishmentId):\n return await WhatsAppService.getSpecificConversationMessages(\n customerMobile,\n 0,\n establishmentId,\n null,\n lastMessageId);\n }\n\n return Promise.resolve(new GetSpecificConversationMessagesResponse());\n }\n\n async function loadMoreMessages() {\n if (isLoadingRef.current || !hasMoreRef.current)\n return;\n\n isLoadingRef.current = true;\n\n // Need to prevent search result message following on paginating while search\n if (isSearch)\n removeDomObserver();\n\n await WhatsAppService.getSpecificConversationMessages(\n customerMobile,\n messagesOffsetRef.current,\n establishmentId,\n currentPageNumberRef.current + 1,\n null)\n .then(response => {\n if (response.messages.length < pageSize)\n hasMoreRef.current = false;\n setCurrentChatMessages(prevMessages => response.messages.concat(prevMessages));\n });\n\n currentPageNumberRef.current++;;\n isLoadingRef.current = false;\n };\n\n function scrollToBottom() {\n domObserver.current?.disconnect();\n domObserver.current = null;\n chatWindowRef.current!.scrollTo(0, chatWindowRef.current!.scrollHeight);\n }\n\n function scrollToMessage() {\n if (!isSearch || !lastMessageId)\n return;\n\n const messageElement = document?.getElementById(`target${lastMessageId}`);\n if (!messageElement)\n return;\n\n messageElement.scrollIntoView({ behavior: \"auto\", block: 'nearest', inline: 'end' });\n messageElement.focus({ preventScroll: true });\n const messageRect = messageElement.getBoundingClientRect();\n\n // Set up a MutationObserver to detect changes to the DOM\n domObserver.current?.disconnect();\n domObserver.current = null;\n domObserver.current = new MutationObserver(() => {\n // Calculate the new position of the message element relative to the viewport\n const newRect = messageElement!.getBoundingClientRect();\n const scrollPosition = chatWindowRef.current!.scrollTop + newRect.top - messageRect.top;\n\n // Adjust the scroll position to keep the message element fixed in place\n chatWindowRef.current!.scrollTop = scrollPosition;\n });\n\n // Start observing changes to the DOM within the scrollable container\n domObserver.current.observe(chatWindowRef.current!, { childList: true, subtree: true });\n }\n\n function removeDomObserver() {\n if (domObserver.current) {\n domObserver.current.disconnect();\n domObserver.current = null;\n }\n }\n\n function resetChatWindowState() {\n currentPageNumberRef.current = 1;\n messagesOffsetRef.current = 0;\n isLoadingRef.current = false;\n hasMoreRef.current = true;\n }\n\n function getMessagesWithHighlightedOne(messages: MessageModel[]): MessageModel[] {\n const messagesWithHighlightedOne = messages = messages.map(m => {\n if (m.id === lastMessageId) {\n return {\n ...m, text: foundMessageText\n .replace(\"color: #7175FA\", \"background-color: #7175FA; color: white\")\n };\n }\n return m;\n });\n\n return messagesWithHighlightedOne;\n }\n\n async function sendTemplate() {\n const cleanedCustomerName = customerName.replace(/<\\/?[^>]+(>|$)/g, ''); // remove HTML tags\n await WhatsAppService.sendTemplate(customerId, cleanedCustomerName, customerMobile, templateType!);\n setTemplateType(null);\n handleSendDropdownClose();\n }\n\n async function handleOnSelectTemplateOpen() {\n const availableTemplatesData = await WhatsAppService.getAvailableTemplates(customerId);\n setAvailableTemplates(availableTemplatesData);\n }\n\n const openCarousel = useCallback(() => {\n setCarouselIsOpen(true);\n }, []);\n\n const setClickedMessageIdCallback = useCallback((messageId: string) => {\n setClickedMessageId(messageId);\n }, []);\n\n const setOutboundMessageText = useCallback((event: React.ChangeEvent<HTMLTextAreaElement>) => {\n setOutMessage(event.target.value);\n }, []);\n\n const handleKeyDown = useCallback((event: React.KeyboardEvent<{ value: unknown }>) => {\n const keyCode = event.key;\n if (keyCode === \"Enter\" && !event.shiftKey) {\n event.preventDefault();\n event.stopPropagation();\n sendMessage();\n }\n }, [outMessage]);\n\n const mapMessagesToComponents = (messages: MessageModel[]) => {\n let daysByMessages: Map<string, boolean> = new Map<string, boolean>();\n const timeNow = moment().utc();\n const messagesComponents: ReactNode[] = messages.map((m) => {\n const messageMoment = moment(m.time);\n const dayKey = messageMoment.format(\"DDMMYYYY\")\n let dayLabel: string;\n if (daysByMessages.get(dayKey) === true) {\n return <Message\n key={m.id}\n message={m}\n openCarousel={openCarousel}\n setClickedMessageId={setClickedMessageIdCallback}\n isCustomerRegistered={isCustomerRegistered}\n customerName={customerName}\n />\n }\n else {\n daysByMessages.set(dayKey, true);\n switch (true) {\n case moment(m.time).isSame(timeNow, \"day\"): {\n dayLabel = t(\"Today\").toUpperCase();\n break;\n }\n case moment(m.time).add(1, \"days\").isSame(timeNow, \"day\"): {\n dayLabel = t(\"Yesterday\").toUpperCase();\n break;\n }\n case moment(m.time).add(2, \"days\").isSame(timeNow, \"day\"): {\n dayLabel = t(messageMoment.format(\"dddd\")).toUpperCase();\n break;\n }\n case moment(m.time).add(3, \"days\").isSame(timeNow, \"day\"): {\n dayLabel = t(messageMoment.format(\"dddd\")).toUpperCase();\n break;\n }\n case moment(m.time).add(4, \"days\").isSame(timeNow, \"day\"): {\n dayLabel = t(messageMoment.format(\"dddd\")).toUpperCase();\n break;\n }\n case moment(m.time).add(5, \"days\").isSame(timeNow, \"day\"): {\n dayLabel = t(messageMoment.format(\"dddd\")).toUpperCase();\n break;\n }\n case moment(m.time).add(6, \"days\").isSame(timeNow, \"day\"): {\n dayLabel = t(messageMoment.format(\"dddd\")).toUpperCase();\n break;\n }\n default: {\n dayLabel = messageMoment.format(\"DD/MM/yyyy\");\n break;\n }\n }\n return <div key={`dateLabel${m.id}`}>\n <div className={classes.dayLabel} key={`dateLabelInner${m.id}`}>\n <div className={classes.dayLabelBox}>\n <Typography className={classes.dayLabelText}>\n {dayLabel}\n </Typography>\n </div>\n </div>\n <Message\n key={m.id}\n message={m}\n openCarousel={openCarousel}\n setClickedMessageId={setClickedMessageIdCallback}\n isCustomerRegistered={isCustomerRegistered}\n customerName={customerName}\n />\n </div>\n }\n\n })\n return messagesComponents;\n };\n\n const handleSendDropdownClick = (event: React.MouseEvent<HTMLButtonElement>) => {\n setAnchorSendDropdown(event.currentTarget);\n };\n\n const handleSendDropdownClose = () => {\n setAnchorSendDropdown(null);\n };\n\n const sendMessage = () => {\n (async () => {\n establishmentId\n ? await WhatsAppService.sendTextMessageAsEstablishment(customerId, establishmentId, customerMobile, outMessage)\n : await WhatsAppService.sendTextMessage(customerId, customerMobile, outMessage)\n })();\n setOutMessage(\"\");\n };\n\n const scheduleFollowUp = () => {\n (async () => {\n await WhatsAppService.scheduleFollowUp(customerId, customerMobile)\n })();\n handleSendDropdownClose();\n };\n\n const sendMercadoPagoLink = () => {\n (async () => {\n await WhatsAppService.sendMercadoPagoLink(customerId, customerName, customerMobile)\n })();\n handleSendDropdownClose();\n };\n\n const formatCustomerNameWithPlusSign = (customerName: string) => {\n if (!isNaN(+customerName)) {\n customerName = \"+\" + customerName;\n }\n return customerName;\n };\n\n const handleCopyLinkClick = () => {\n // actual copying is done by CopyToClipboard inside the toolbar\n setLinkCopiedSnackbarShown(true);\n // re-focus the input\n textInput.current?.focus();\n };\n\n const getActiveCarouselIndex = () => {\n const mappedObjs = currentChatMessages\n .filter((m: MessageModel) =>\n m.originalFileName &&\n m.previewFileUrl &&\n (m.type === ConversationMessageType.Image || m.type === ConversationMessageType.Video))\n .map((m: MessageModel) => ({ id: m.id, time: m.time, type: m.type, url: m.fileUrl! }))\n .sort((o: { time: any; }) => o.time);\n\n const openedItemIndex = mappedObjs.findIndex((o: { id: any; }) => o.id === clickedMessageId);\n\n return openedItemIndex;\n }\n\n const getCarouselItemsCount = (messages: MessageModel[]) => {\n return messages\n .filter((m: MessageModel) =>\n m.originalFileName &&\n (m.originalFileName.endsWith(\".jpeg\") ||\n m.originalFileName.endsWith(\".jpg\") ||\n m.originalFileName.endsWith(\".png\") ||\n m.originalFileName.endsWith(\".mp4\")\n )).length;\n }\n \n const handleBlockCustomerModalClick = async (block: boolean) => {\n setOpenBlockCustomerModal(false);\n await onBlockCustomer(customerId, customerMobile, block);\n if (block) {\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: formatCustomerNameWithPlusSign(customerName),\n description: t(isCustomerRegistered ? \"The customer has been blocked\" : \"The number has been blocked\"),\n }));\n } else {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: formatCustomerNameWithPlusSign(customerName),\n description: t(isCustomerRegistered ? \"The customer has been unblocked\" : \"The number has been unblocked\"),\n }));\n }\n }\n \n const BlockIcon = () =>\n <BlockCustomerIcon\n onClick={() => setOpenBlockCustomerModal(true)}\n isBlocked={isCustomerBlocked}\n isRegistered={isCustomerRegistered}\n />\n\n return (\n <>\n <div className={classes.windowContainer}>\n <div className={classes.header} id=\"header\">\n <>\n {\n establishmentName\n ?\n <Typography className={classes.headerTitleWithEstablishmentName}>\n <Markup content={formatCustomerNameWithPlusSign(customerName)} />\n <Typography className={classes.establishmentName}>{establishmentName}</Typography>\n </Typography>\n :\n <Typography className={classes.headerTitle}>\n {hasScheduledFollowUp ? <ScheduledSendIconWithTooltip title={t(\"Send scheduled message\")} /> : <></>}\n <Markup content={formatCustomerNameWithPlusSign(customerName)} />\n </Typography>\n }\n <div className={classes.headerActions}>\n <BlockIcon />\n </div>\n </>\n </div>\n <div\n ref={chatWindowRef}\n className={`${classes.buildScrollbars} ${classes.messageWindow}`}\n >\n <div>\n {mapMessagesToComponents(currentChatMessages)}\n </div>\n </div>\n <div className={classes.inputLayout} id=\"input\">\n <div className={classes.inputItemsLayout}>\n {isDisabledActivity || isDisabledNotContactable\n ?\n <Grid className={classes.disabledInputLayout}>\n {templateType == null && (\n <div className={`${classes.disabledInput} ${classes.inputText}`}>\n {t(\"Unable to send a free text\")}\n </div>\n )}\n {templateType == null && (\n <div>\n <SelectWhatsappTemplate\n value={templateType}\n onOpen={handleOnSelectTemplateOpen}\n setValue={setTemplateType}\n items={availableTemplateTypes}\n availableTemplates={availableTemplates}\n disabled={isCustomerBlocked}\n />\n <SnackbarNotification\n isOpen={linkCopiedSnackbarShown}\n onClose={() => setLinkCopiedSnackbarShown(false)}\n message={t(\"Link copied\")}\n notificationKind={SnackbarNotificationKind.whatsappChatWindowLinkCopied}\n />\n </div>\n )}\n \n {templateType !== null && (\n <div className={classes.templateWindowArea}>\n <Tooltip placement={\"top\"}\n title={`${t(\"Unable to send a free tooltip\")}`}\n classes={{ tooltip: classes.tooltipBlock }}>\n <div className={classes.templateTextAreaContainer}>\n <div className={classes.closeWindowButton}>\n <CloseIcon onClick={() => setTemplateType(null)} className={classes.closeIcon} />\n </div>\n <div className={classes.templateTextContainer}\n dangerouslySetInnerHTML={{ __html: availableTemplates.find(x => x.templateType === templateType)!.templateText }}>\n </div>\n </div>\n </Tooltip>\n <div className={classes.buttonContainer}>\n <Button\n className={`${classes.enabledSendButton}`}\n onClick={sendTemplate}\n >\n {t(\"SendWhatsappTemplate\")}\n </Button>\n </div>\n </div>\n \n )}\n </Grid>\n :\n <div className={classes.inputAreaContainer}>\n <div className={classes.messageInputArea}>\n <TextareaAutosize\n className={`${classes.inputArea} ${classes.inputText}`}\n placeholder={t(\"Type a message...\")}\n maxLength={2048}\n maxRows={1}\n value={outMessage}\n onKeyDown={handleKeyDown}\n onChange={setOutboundMessageText}\n disabled={isCustomerBlocked}\n />\n <ChatToolbar onCopyLinkClick={handleCopyLinkClick} />\n </div>\n <div className={classes.sendMessageButton}>\n <ButtonWithSpinner\n width={70}\n height={40}\n borderRadius={ButtonPropsBorderRadius.Small}\n borderSide={canScheduleFollowUp || hasUnpaidAppointment ? ButtonPropsBorderSide.Left : ButtonPropsBorderSide.All}\n backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Send\")}\n onClick={sendMessage}\n disabled={outMessage.length === 0 || isCustomerBlocked}\n />\n <SnackbarNotification\n isOpen={linkCopiedSnackbarShown}\n onClose={() => setLinkCopiedSnackbarShown(false)}\n message={t(\"Link copied\")}\n notificationKind={SnackbarNotificationKind.whatsappChatWindowLinkCopied}\n />\n {canScheduleFollowUp || hasUnpaidAppointment\n ? <>\n <Button\n id=\"send-dropdown-button\"\n className={`${classes.enabledSendButton} ${classes.enabledSendDropdownButton}`}\n aria-controls={openSendDropdown ? 'send-dropdown-menu' : undefined}\n aria-haspopup=\"true\"\n aria-expanded={openSendDropdown ? 'true' : undefined}\n onClick={handleSendDropdownClick}\n disabled={isCustomerBlocked}\n >\n <ArrowDropDownTriangleIcon />\n </Button>\n <Menu\n id=\"send-dropdown-menu\"\n anchorEl={anchorSendDropdown}\n open={openSendDropdown}\n onClose={handleSendDropdownClose}\n MenuListProps={{\n 'aria-labelledby': 'send-dropdown-button',\n }}\n anchorOrigin={{\n vertical: 'top',\n horizontal: 'right',\n }}\n transformOrigin={{\n vertical: 'bottom',\n horizontal: 'right',\n }}\n >\n {hasUnpaidAppointment &&\n <MenuItem\n className={classes.menuItem}\n onClick={sendMercadoPagoLink}>\n <ListItemIcon className={classes.listItemIcon}>\n <MercadoPagoLinkIcon />\n </ListItemIcon>\n <ListItemText className={classes.listItemText}>\n {t(\"Mercado Pago link\")}\n </ListItemText>\n </MenuItem>\n }\n {canScheduleFollowUp &&\n <MenuItem\n className={classes.menuItem}\n onClick={scheduleFollowUp}>\n <ListItemIcon className={classes.listItemIcon}>\n <ScheduledSendIcon />\n </ListItemIcon>\n <ListItemText className={classes.listItemText}>\n {t(\"Schedule follow-up\")}\n </ListItemText>\n </MenuItem>\n }\n </Menu>\n </>\n : <></>}\n </div>\n </div>\n }\n </div>\n </div>\n {carouselIsOpen\n ?\n <ImageCarousel\n carouselIsOpen={carouselIsOpen}\n closeCarousel={() => setCarouselIsOpen(false)}\n messages={currentChatMessages}\n activeImageIndex={getActiveCarouselIndex()}\n imagesCount={getCarouselItemsCount(currentChatMessages)}\n />\n :\n <></>\n }\n \n </div>\n <BlockCustomerModal\n open={openBlockCustomerModal && !isCustomerBlocked}\n customerName={customerName}\n onContinue={() => handleBlockCustomerModalClick(true)}\n onClose={() => setOpenBlockCustomerModal(false)}/>\n <UnblockCustomerModal\n open={openBlockCustomerModal && isCustomerBlocked}\n customerName={customerName}\n onContinue={() => handleBlockCustomerModalClick(false)}\n onClose={() => setOpenBlockCustomerModal(false)}/>\n </>\n );\n});\n\nconst ConversationWindow = React.memo(ConversationWindowMemo);\nexport default ConversationWindow;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../constants/colors\";\nexport const useStyles = makeStyles((theme) => ({\n root: {},\n conversationBox: {\n width: \"360px\",\n maxWidth: \"360px\",\n height: \"80px\",\n\n borderBottom: \"1px solid\",\n borderBottomColor: theme.colors.grey2,\n padding: \"16px 16px 16px 40px\",\n },\n conversationSelected: {\n backgroundColor: theme.colors.clear5,\n },\n conversationNotSelected: {\n backgroundColor: theme.colors.grey1 + \" !important\",\n \"&:hover\": {\n backgroundColor: theme.colors.clear5 + \" !important\",\n },\n },\n conversationEnabled: {\n backgroundColor: theme.colors.clear5,\n color: theme.colors.grey5\n },\n conversationDisabled: {\n color: theme.colors.grey3\n },\n customerContactName: {\n display: \"flex\",\n alignItems: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n \"& svg\": {\n marginRight: \"5px\"\n }\n },\n establishmentName: {\n ...theme.typography.txtBody2,\n paddingLeft: 2,\n },\n messagePreview: {\n ...theme.typography.txtBody2,\n },\n dateTime: {\n ...theme.typography.txtBody3,\n },\n messageCounter: {\n backgroundColor: theme.colors.clearBlue,\n color: theme.colors.grey1,\n },\n messageSentIcon: {\n color: theme.colors.grey5,\n width: \"14px\",\n },\n messageDeliveredIcon: {\n color: theme.colors.grey5,\n width: \"20px\",\n },\n messageReadIcon: {\n color: theme.colors.clearBlue,\n width: \"20px\",\n }\n}));","import React from \"react\";\nimport Grid from '@material-ui/core/Grid';\nimport Typography from '@material-ui/core/Typography';\nimport Badge from '@material-ui/core/Badge';\nimport { Box } from \"@material-ui/core\";\n// import MessageSentIcon from \"../../../assets/icons/MessageSentIcon\";\n// import MessageDeliveredIcon from \"../../../assets/icons/MessageDeliveredIcon\";\n// import { MessageStatus } from \"../../../models/enums/message-status\";\nimport moment from \"moment\";\nimport \"moment-timezone\";\nimport { useStyles } from \"./css\";\n\nimport ScheduledSendIconWithTooltip from \"../common/ScheduledSendIconWithTooltip\"\nimport { useTranslation } from \"react-i18next\";\nimport { Markup } from \"interweave\";\nimport { ConversationMessageType } from \"../../../models/enums/conversation-message-type\";\nimport {\n CaptionDocumentMediaIcon,\n CaptionImageMediaIcon,\n VideoCameraFilledIcon,\n WhatsAppMicrophoneIcon\n} from \"../../../assets/icons\";\n\n\nconst ConversationsListItem = (props: any) => {\n\n const {\n customerName,\n lastMessageText,\n lastMessageFileName,\n lastMessageTime,\n lastMessageType,\n isDisabledActivity,\n isDisabledNotContactable,\n isSelected,\n wasSendMore1DayAgo,\n unreadMessagesCount,\n hasScheduledFollowUp,\n onSelect,\n establishmentName,\n ...otherProps\n } = props;\n\n const classes = useStyles();\n const { t } = useTranslation([\"general\"]);\n\n const getText = (text: string | null, messageType: ConversationMessageType): string => {\n if (text)\n return formatText(text)\n\n switch (messageType) {\n case ConversationMessageType.Image:\n return t(\"Photo\");\n case ConversationMessageType.Video:\n return t(\"Video\");\n case ConversationMessageType.Voice:\n return t(\"Voice message\");\n case ConversationMessageType.Document:\n case ConversationMessageType.Pdf:\n return t(\"Document\");\n default:\n return formatText(text ?? \"\");\n }\n }\n \n const formatText = (text: string) =>\n text.replaceAll(\"\\n\", \" \").replaceAll(\"<br>\", \" \").replaceAll(new RegExp('<(?!span|/span).*?\\>', 'g'), '');\n\n const getFormattedTime = (messageTime: Date, wasSendMore1DayAgo: boolean) => {\n const messageMoment = moment(messageTime);\n const datetimeString = wasSendMore1DayAgo ?\n messageMoment.format(\"DD/MM/yyyy\") :\n messageMoment.format(\"HH:mm[hrs]\")\n return datetimeString;\n }\n const getChatPreviewIndicator = (unreadMessagesCount: number) => {\n if (unreadMessagesCount > 0) {\n return (<Badge\n classes={{ badge: classes.messageCounter }}\n style={{ paddingRight: \"10px\" }}\n badgeContent={unreadMessagesCount}\n max={99}\n anchorOrigin={{\n vertical: 'bottom',\n horizontal: 'left',\n }}> </Badge>);\n }\n // if (!lastMessage.isInbound && lastMessage.messageStatus === MessageStatus.Sent){\n // return (<MessageSentIcon className={classes.messageSentIcon}/>)\n // }\n // if (!lastMessage.isInbound && lastMessage.messageStatus === MessageStatus.Delivered){\n // return (<MessageDeliveredIcon className={classes.messageDeliveredIcon}/>)\n // }\n // if (!lastMessage.isInbound && lastMessage.messageStatus === MessageStatus.Read){\n // return (<MessageDeliveredIcon className={classes.messageReadIcon}/>)\n // }\n }\n\n const getMessageMediaContentIcon = (type: ConversationMessageType) => {\n switch (type) {\n case ConversationMessageType.Image:\n return <CaptionImageMediaIcon width={14} viewBox={\"0 0 14 11\"} style={{ marginRight: \"6px\", marginBottom: \"2px\" }} />\n case ConversationMessageType.Video:\n return <VideoCameraFilledIcon style={{ marginRight: \"6px\", marginBottom: \"2px\" }} />\n case ConversationMessageType.Voice:\n return <WhatsAppMicrophoneIcon style={{ marginRight: \"6px\", marginBottom: \"2px\" }} />\n case ConversationMessageType.Document:\n case ConversationMessageType.Pdf:\n return <CaptionDocumentMediaIcon style={{ marginRight: \"6px\", marginBottom: \"2px\" }} />\n default:\n return <></>;\n }\n }\n\n const formatCustomerNameWithPlusSign = (customerName: string) => {\n if (!isNaN(+customerName)) {\n customerName = \"+\" + customerName;\n }\n return customerName;\n }\n return (\n <div\n className={\n `${classes.conversationBox} ${isSelected ? classes.conversationSelected : classes.conversationNotSelected} ${isDisabledActivity ? classes.conversationDisabled : classes.conversationEnabled}`\n }\n onClick={onSelect}>\n <Grid container>\n <Grid item xs={9}>\n <Typography noWrap className={classes.customerContactName}>\n {hasScheduledFollowUp ? <ScheduledSendIconWithTooltip title={t(\"Send scheduled message\")} width=\"14px\" height=\"13px\" /> : <></>}\n <Markup content={formatCustomerNameWithPlusSign(customerName)} />\n </Typography>\n </Grid>\n <Grid item xs={3} container justifyContent=\"flex-end\">\n <Typography className={classes.dateTime}>{getFormattedTime(lastMessageTime, wasSendMore1DayAgo)}</Typography>\n </Grid>\n <Box width=\"100%\" />\n {\n establishmentName\n ?\n <Grid item xs={10} zeroMinWidth>\n <Typography className={classes.establishmentName}>\n {establishmentName}\n </Typography>\n </Grid>\n : null\n }\n <Grid item xs={10} zeroMinWidth>\n <Typography noWrap className={classes.messagePreview}>\n {getMessageMediaContentIcon(lastMessageType)}\n <Markup content={getText(lastMessageText, lastMessageType)} />\n </Typography>\n </Grid>\n <Grid item xs={2} container justifyContent=\"flex-end\" style={{ paddingBottom: 10 }}>\n {getChatPreviewIndicator(unreadMessagesCount)}\n </Grid>\n </Grid>\n </div>\n );\n};\n\nexport default ConversationsListItem;\n","function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport React from \"react\";\n\nvar _ref2 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.2,\n d: \"M124.348 119.09C124.888 119.251 125.429 119.384 125.971 119.501C124.461 122.013 123.731 124.914 123.871 127.839C124.012 130.764 125.018 133.582 126.762 135.937C128.506 138.293 130.91 140.081 133.671 141.076C136.432 142.071 139.427 142.229 142.277 141.529C143.172 143.304 144.46 144.853 146.044 146.058C147.628 147.263 149.465 148.094 151.418 148.486C153.371 148.878 155.388 148.822 157.316 148.322C159.244 147.822 161.032 146.891 162.546 145.6C164.558 148.917 167.755 151.351 171.493 152.413C175.231 153.475 179.233 153.086 182.695 151.325C186.158 149.563 188.823 146.559 190.155 142.918C191.488 139.276 191.389 135.266 189.878 131.694C190.334 131.865 190.798 132.028 191.273 132.17C194.347 133.091 197.589 133.314 200.762 132.824C203.934 132.334 206.956 131.143 209.607 129.337C212.259 127.532 214.472 125.158 216.085 122.39C217.698 119.621 218.669 116.528 218.929 113.337C219.189 110.145 218.73 106.936 217.587 103.944C216.443 100.952 214.643 98.2535 212.318 96.0451C209.994 93.8366 207.204 92.1745 204.152 91.1802C201.101 90.186 197.865 89.8848 194.682 90.2987C194.268 87.0677 193.013 84.001 191.042 81.4034C189.072 78.8058 186.454 76.7678 183.449 75.4918C180.445 74.2158 177.157 73.7463 173.914 74.1299C170.671 74.5135 167.586 75.7369 164.963 77.6785C161.455 75.2585 157.187 74.1889 152.949 74.6676C148.711 75.1464 144.79 77.1412 141.914 80.2823C139.309 78.665 136.387 77.6216 133.345 77.2222C130.303 76.8227 127.21 77.0763 124.274 77.9661C121.338 78.8559 118.627 80.3612 116.321 82.3813C114.016 84.4013 112.17 86.8895 110.908 89.679C109.645 92.4685 108.995 95.4949 109 98.5556C109.005 101.616 109.667 104.64 110.939 107.425C112.212 110.21 114.066 112.692 116.378 114.704C118.691 116.716 121.407 118.212 124.347 119.091L124.348 119.09Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.2,\n d: \"M125.451 20.3881C124.887 20.3881 124.33 20.4167 123.777 20.4578C124.5 17.6292 124.364 14.6513 123.386 11.8993C122.409 9.1474 120.633 6.74461 118.283 4.99385C115.933 3.24308 113.114 2.22269 110.181 2.06129C107.249 1.89989 104.333 2.60471 101.803 4.0869C100.434 2.64789 98.7534 1.53718 96.8884 0.838828C95.0234 0.140477 93.023 -0.127215 91.0385 0.0560095C89.054 0.239235 87.1375 0.868576 85.4339 1.89641C83.7304 2.92423 82.2845 4.32362 81.2056 5.98865C78.3217 3.39723 74.5573 1.98661 70.6693 2.04039C66.7813 2.09417 63.058 3.60835 60.2477 6.27854C57.4375 8.94872 55.7489 12.5769 55.5212 16.4337C55.2936 20.2905 56.5438 24.09 59.0206 27.0683C58.533 27.0355 58.0426 27.0128 57.5472 27.0128C54.3359 27.0125 51.165 27.7254 48.2667 29.0995C45.3684 30.4735 42.8159 32.474 40.7959 34.9545C38.776 37.4349 37.3396 40.3327 36.592 43.4358C35.8444 46.5388 35.8044 49.7687 36.4749 52.8892C37.1454 56.0096 38.5096 58.9416 40.4675 61.4707C42.4254 63.9998 44.9276 66.0621 47.791 67.5066C50.6544 68.9511 53.8066 69.7414 57.017 69.8195C60.2274 69.8977 63.4147 69.2618 66.3459 67.9584C67.674 70.9244 69.7602 73.4935 72.397 75.4104C75.0339 77.3273 78.1297 78.5253 81.3768 78.8853C84.624 79.2452 87.9094 78.7547 90.9066 77.4625C93.9039 76.1702 96.5087 74.1211 98.4621 71.5189C102.521 72.8272 106.92 72.6294 110.843 70.962C114.767 69.2947 117.949 66.2708 119.801 62.4507C122.763 63.2514 125.864 63.4137 128.895 62.9266C131.926 62.4395 134.817 61.3143 137.375 59.6265C139.933 57.9387 142.098 55.7272 143.725 53.1403C145.352 50.5533 146.404 47.6506 146.811 44.6267C147.217 41.6029 146.968 38.5276 146.08 35.6072C145.193 32.6867 143.687 29.9884 141.665 27.6932C139.642 25.3979 137.149 23.5588 134.353 22.2989C131.557 21.039 128.521 20.3875 125.451 20.3881Z\",\n fill: \"#BDC7F8\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M199.911 127.185V170.879C199.91 172.715 199.18 174.475 197.881 175.773C196.583 177.071 194.822 177.8 192.986 177.8H50.9566C49.1207 177.8 47.36 177.071 46.0616 175.773C44.7631 174.475 44.0332 172.715 44.0322 170.879V127.185H104.457C104.478 131.817 106.332 136.252 109.615 139.52C112.897 142.788 117.34 144.622 121.972 144.622C126.604 144.622 131.047 142.788 134.329 139.52C137.612 136.252 139.466 131.817 139.487 127.185H199.911Z\",\n fill: \"white\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M192.987 178.152H50.9566C49.028 178.15 47.1789 177.383 45.8149 176.02C44.4508 174.656 43.6833 172.807 43.6807 170.879V127.185C43.6807 127.092 43.7178 127.003 43.7837 126.937C43.8496 126.871 43.939 126.834 44.0322 126.834H104.457C104.55 126.834 104.64 126.871 104.705 126.937C104.771 127.003 104.808 127.092 104.808 127.185C104.808 131.737 106.617 136.103 109.835 139.322C113.054 142.54 117.42 144.349 121.972 144.349C126.524 144.349 130.889 142.54 134.108 139.322C137.327 136.103 139.135 131.737 139.135 127.185C139.135 127.092 139.172 127.003 139.238 126.937C139.304 126.871 139.393 126.834 139.486 126.834H199.911C200.004 126.834 200.093 126.871 200.159 126.937C200.225 127.003 200.262 127.092 200.262 127.185V170.879C200.26 172.807 199.492 174.656 198.128 176.02C196.764 177.383 194.915 178.15 192.987 178.152ZM44.3834 127.537V170.879C44.3858 172.621 45.0792 174.291 46.3114 175.523C47.5436 176.754 49.214 177.447 50.9562 177.449H192.987C194.729 177.447 196.399 176.754 197.632 175.523C198.864 174.291 199.557 172.621 199.56 170.879V127.537H139.834C139.744 132.215 137.822 136.67 134.482 139.946C131.142 143.223 126.65 145.058 121.972 145.058C117.293 145.058 112.801 143.223 109.461 139.946C106.121 136.67 104.199 132.215 104.109 127.537H44.3834Z\",\n fill: \"#292A2E\"\n});\n\nvar _ref6 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M199.911 127.185H139.486C139.466 131.817 137.611 136.252 134.329 139.52C131.046 142.788 126.603 144.622 121.972 144.622C117.34 144.622 112.897 142.788 109.614 139.52C106.332 136.252 104.477 131.817 104.457 127.185H44.0319L88.2072 99.3962H157.504L199.911 127.185Z\",\n fill: \"#367CFF\"\n});\n\nvar _ref7 = /*#__PURE__*/React.createElement(\"path\", {\n opacity: 0.6,\n d: \"M200.038 127.073H139.613C139.593 131.705 137.738 136.139 134.456 139.407C131.173 142.675 126.73 144.51 122.098 144.51C117.467 144.51 113.024 142.675 109.741 139.407C106.459 136.139 104.604 131.705 104.583 127.073H44.1588L88.3341 99.2838H157.63L200.038 127.073Z\",\n fill: \"#7175FA\"\n});\n\nvar _ref8 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M121.972 145.052C117.296 145.047 112.808 143.21 109.469 139.937C106.13 136.663 104.206 132.212 104.109 127.537H44.0319C43.9556 127.537 43.8814 127.512 43.8204 127.466C43.7595 127.42 43.7151 127.356 43.694 127.283C43.6729 127.209 43.6762 127.131 43.7034 127.06C43.7306 126.989 43.7803 126.928 43.8449 126.888L88.0202 99.0989C88.0762 99.0636 88.141 99.0448 88.2072 99.0447H157.504C157.572 99.0448 157.639 99.0648 157.696 99.1024L200.103 126.892C200.167 126.933 200.215 126.994 200.241 127.065C200.267 127.136 200.269 127.213 200.247 127.286C200.226 127.358 200.181 127.422 200.121 127.467C200.06 127.512 199.986 127.537 199.911 127.537H139.834C139.737 132.212 137.813 136.663 134.474 139.937C131.136 143.21 126.648 145.046 121.972 145.052ZM45.2508 126.834H104.457C104.55 126.834 104.64 126.871 104.705 126.937C104.771 127.003 104.808 127.092 104.808 127.185C104.808 131.737 106.617 136.103 109.835 139.322C113.054 142.54 117.42 144.349 121.972 144.349C126.524 144.349 130.889 142.54 134.108 139.322C137.327 136.103 139.135 131.737 139.135 127.185C139.135 127.092 139.172 127.003 139.238 126.937C139.304 126.871 139.393 126.834 139.486 126.834H198.733L157.398 99.7477H88.3084L45.2508 126.834Z\",\n fill: \"#292A2E\"\n});\n\nvar _ref9 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M100.626 31.6501L170.92 63.7042L149.547 110.576C149.215 111.304 148.607 111.871 147.856 112.151C147.106 112.432 146.275 112.402 145.547 112.07L80.7475 82.5217C80.0188 82.1894 79.452 81.5813 79.1717 80.8311C78.8914 80.0809 78.9206 79.2501 79.2529 78.5214L100.626 31.6501Z\",\n fill: \"#367CFF\"\n});\n\nvar _ref10 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M100.626 31.6501L170.92 63.7042L149.547 110.576C149.215 111.304 148.607 111.871 147.856 112.151C147.106 112.432 146.275 112.402 145.547 112.07L80.7475 82.5217C80.0188 82.1894 79.452 81.5813 79.1717 80.8311C78.8914 80.0809 78.9206 79.2501 79.2529 78.5214L100.626 31.6501Z\",\n fill: \"white\"\n});\n\nvar _ref11 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M146.798 112.695C146.316 112.694 145.839 112.59 145.401 112.389L80.602 82.8416C79.7891 82.4699 79.1568 81.791 78.844 80.9537C78.5312 80.1163 78.5634 79.1891 78.9335 78.3755L100.307 31.5039C100.326 31.4619 100.353 31.424 100.387 31.3925C100.421 31.361 100.46 31.3365 100.504 31.3203C100.547 31.3041 100.593 31.2967 100.639 31.2983C100.685 31.3 100.731 31.3107 100.773 31.3299L171.066 63.3834C171.108 63.4024 171.146 63.4295 171.178 63.4632C171.21 63.4969 171.234 63.5365 171.251 63.5798C171.267 63.6231 171.275 63.6691 171.273 63.7153C171.272 63.7616 171.261 63.807 171.242 63.8491L149.867 110.721C149.598 111.309 149.166 111.808 148.622 112.158C148.078 112.507 147.445 112.694 146.798 112.695ZM100.801 32.1166L79.5732 78.6673C79.2804 79.3112 79.255 80.0451 79.5025 80.7078C79.7501 81.3705 80.2504 81.9079 80.8937 82.2022L145.692 111.75C146.011 111.895 146.356 111.976 146.706 111.989C147.056 112.001 147.405 111.944 147.733 111.822C148.062 111.699 148.362 111.513 148.619 111.274C148.875 111.035 149.082 110.748 149.227 110.429L170.455 63.8772L100.801 32.1166Z\",\n fill: \"#292A2E\"\n});\n\nvar _ref12 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M171.23 63.537L149.249 22.621C148.928 22.0289 148.423 21.5574 147.811 21.2783C147.198 20.9992 146.511 20.9276 145.854 21.0745L100.549 31.3081C100.491 31.3213 100.436 31.3493 100.392 31.3894C100.347 31.4295 100.313 31.4803 100.294 31.5371C100.274 31.5938 100.27 31.6546 100.281 31.7137C100.291 31.7727 100.317 31.828 100.355 31.8744L125.181 62.0453C125.898 62.9403 126.807 63.6632 127.841 64.1609C128.875 64.6586 130.007 64.9185 131.154 64.9215H131.274L170.928 64.0568C170.988 64.0556 171.047 64.0389 171.098 64.0084C171.15 63.9779 171.194 63.9346 171.224 63.8827C171.254 63.8307 171.271 63.7718 171.272 63.7117C171.273 63.6515 171.258 63.5921 171.23 63.5391V63.537Z\",\n fill: \"#5C6477\"\n});\n\nvar _ref13 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M175.118 85.9946C175.014 85.9946 174.912 85.961 174.828 85.8987C174.744 85.8364 174.682 85.7487 174.651 85.6485C173.03 79.5847 172.597 73.2635 173.377 67.0348C174.64 57.9288 179.652 45.9781 196.357 40.7451C198.708 39.9881 201.118 39.4344 203.563 39.0899C204.35 34.1644 207.345 28.8213 214.041 25.1373C229.951 16.378 240.699 24.237 240.805 24.3173C240.856 24.3559 240.899 24.4042 240.932 24.4595C240.965 24.5148 240.986 24.5761 240.995 24.6397C241.004 24.7033 241.001 24.7682 240.985 24.8304C240.969 24.8927 240.941 24.9512 240.902 25.0027C240.864 25.0541 240.816 25.0974 240.76 25.1302C240.705 25.1629 240.644 25.1845 240.58 25.1936C240.517 25.2027 240.452 25.1991 240.39 25.1832C240.328 25.1672 240.27 25.1392 240.218 25.1006C240.117 25.0242 229.846 17.5535 214.512 25.996C208.254 29.4411 205.39 34.3857 204.576 38.9758C211.944 38.2488 215.472 40.7113 217.055 42.5717C218.035 43.69 218.665 45.0725 218.867 46.547C219.068 48.0214 218.831 49.5226 218.187 50.8634C217.678 51.9472 216.852 52.8507 215.82 53.4546C214.788 54.0585 213.597 54.3344 212.404 54.2458C208.29 54.0045 204.885 50.5359 203.731 45.4102C203.35 43.6751 203.248 41.8901 203.43 40.1229C201.131 40.4538 198.863 40.9761 196.65 41.6846C183.631 45.7636 176.128 54.3398 174.346 67.1748C173.582 73.2621 174.003 79.4402 175.586 85.367C175.609 85.4402 175.614 85.5176 175.601 85.5931C175.588 85.6685 175.557 85.7399 175.512 85.8015C175.466 85.863 175.407 85.9131 175.339 85.9475C175.271 85.982 175.195 86 175.119 86L175.118 85.9946ZM204.426 39.9976C204.223 41.7311 204.31 43.4865 204.684 45.1913C205.74 49.8804 208.792 53.0494 212.461 53.2653C213.461 53.3371 214.46 53.1044 215.325 52.5976C216.191 52.0909 216.883 51.3338 217.312 50.4258C217.87 49.2566 218.073 47.9487 217.895 46.6648C217.717 45.381 217.167 44.1779 216.312 43.2052C214.026 40.5189 209.857 39.4341 204.426 39.9976Z\",\n fill: \"#292A2E\"\n});\n\nvar _ref14 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M62.0841 103C61.9818 103 61.8815 102.972 61.7942 102.918C61.7069 102.865 61.6359 102.788 61.5889 102.697C61.542 102.606 61.5209 102.503 61.5281 102.401C61.5352 102.299 61.5702 102.2 61.6294 102.116C61.7326 101.97 71.8166 87.3383 60.5592 73.9999C58.5666 71.6261 56.0808 69.7185 53.2759 68.411C50.4711 67.1034 47.4152 66.4275 44.3225 66.4306H44.1741C45.2432 70.1584 45.0523 73.4724 43.5386 76.0142C42.8936 77.1631 41.9418 78.1084 40.7904 78.7437C39.639 79.379 38.3337 79.679 37.0216 79.6099C35.9355 79.5204 34.8989 79.115 34.0389 78.4433C33.1788 77.7717 32.5325 76.8629 32.1791 75.8283C30.9409 72.5871 32.2349 69.4444 35.6451 67.419C37.8054 66.2231 40.2061 65.5303 42.6693 65.3918C41.8681 63.2595 40.8261 61.2264 39.5637 59.3322C35.4989 53.1018 28.0909 48.7887 19.2377 47.4991C11.7359 46.406 4.54603 47.6928 0.91872 50.7761C0.805811 50.8721 0.659522 50.9192 0.512035 50.907C0.364547 50.8948 0.227943 50.8242 0.132274 50.7109C0.0366046 50.5976 -0.0102926 50.4507 0.00189772 50.3027C0.014088 50.1547 0.0843678 50.0176 0.197277 49.9216C4.05781 46.6401 11.5942 45.253 19.3984 46.3937C28.5674 47.7292 36.2572 52.2226 40.4977 58.7212C41.8726 60.782 42.9909 63.0039 43.8276 65.3375C47.1632 65.2573 50.4742 65.929 53.5168 67.3033C56.5595 68.6775 59.2562 70.7192 61.4084 73.2781C73.2333 87.289 62.6454 102.614 62.5372 102.766C62.4855 102.839 62.4175 102.898 62.3387 102.938C62.2599 102.979 62.1727 103 62.0841 103ZM43.0308 66.472C40.6427 66.5743 38.3104 67.2284 36.2153 68.3833C33.2715 70.1321 32.1813 72.6996 33.223 75.4279C33.5051 76.2639 34.024 76.9993 34.7161 77.5439C35.4082 78.0886 36.2435 78.4189 37.1198 78.4944C38.223 78.544 39.3183 78.2846 40.2831 77.7452C41.2478 77.2059 42.0441 76.4078 42.5828 75.4402C43.9738 73.1051 44.101 70.0011 43.0308 66.472Z\",\n fill: \"#292A2E\"\n});\n\nvar SvgNoConversations = function SvgNoConversations(_ref) {\n var svgRef = _ref.svgRef,\n title = _ref.title,\n props = _objectWithoutProperties(_ref, [\"svgRef\", \"title\"]);\n\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n width: 241,\n height: 179,\n viewBox: \"0 0 241 179\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5, _ref6, _ref7, _ref8, _ref9, _ref10, _ref11, _ref12, _ref13, _ref14);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgNoConversations, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/no-conversations.b1419f21.svg\";\nexport { ForwardRef as ReactComponent };","export enum AvailabilityStatus {\n Away = 1,\n Available\n}\n","import React, { useState, useEffect, useCallback, useRef } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport InfiniteScroll from 'react-infinite-scroller';\n\nimport { useDispatch, useSelector } from \"react-redux\";\nimport { RootState, selectAccountSettings } from \"../../../redux/store\";\nimport { connect } from \"../../../redux/whatsapp-hub-slice\";\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\n\nimport CircularProgress from \"@material-ui/core/CircularProgress\";\nimport { Grid, Box } from \"@material-ui/core\";\nimport FiberManualRecordIcon from \"@material-ui/icons/FiberManualRecord\";\n\nimport { useStyles } from \"./css\";\nimport { WhatsAppService } from \"../../../api/whatsapp-service\"\nimport { ConversationPreview } from \"../../../models/conversation-preview\";\nimport ConversationWindow from \"./../ConversationWindow\"\nimport ConversationsListItem from \"./../ConversationsListItem\";\nimport { Message } from \"../../../models/message\";\nimport { MessagesByCustomer } from \"../../../models/messages-by-customer\";\nimport { ReactComponent as NoConversationsImage } from \"../../../assets/images/no-conversations.svg\";\nimport InputSearch from \"../../common/InputSearch/input-search\";\nimport useDebounce from \"../../../hooks/useDebounce\";\nimport MessengerRefs from \"./messenger-refs\";\nimport EstablishmentsToolbar from \"../../common/EstablishmentsToolbar\";\nimport { SelectedConversation } from \"../../../models/interfaces/selected-conversation\";\nimport Select, { SelectItem } from \"../../common/Select\";\nimport { AvailabilityStatus } from \"../../../models/enums/availability-status\";\n\n\nexport default function Messenger(props: any) {\n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const firstPageSize = 10;\n const pageSize = 10;\n\n const [refresh, setRefresh] = useState<any>();\n const [nextPageNumber, setNextPageNumber] = useState<number>(2);\n const [isLoading, setIsLoading] = useState<boolean>(true);\n const [hasMore, setHasMore] = useState<boolean>(false);\n const [conversations, setConversations] = useState<ConversationPreview[]>([]);\n const [currentChat, setCurrentChat] = useState<ConversationPreview>();\n const [isSearchMode, setIsSearchMode] = useState<boolean>(false);\n const [searchQuery, setSearchQuery] = useState<string>(\"\");\n const [selectedConversation, setSelectedConversation] = useState<SelectedConversation>({ customerPhoneNumber: null, establishmentId: null })\n const [searchWasRun, setSearchWasRun] = useState<boolean>(false);\n \n const [availabilityStatus, setAvailabilityStatus] = useState<AvailabilityStatus>(AvailabilityStatus.Away);\n\n const debouncedSearchQuery = useDebounce(searchQuery, 400);\n\n const messengerRef = useRef<MessengerRefs>(null);\n \n const accountSettings = useAppSelector(selectAccountSettings);\n const selectedEstablishments = useAppSelector(state => state.enterprise.selectedEstablishments);\n \n const availabilityStatuses: SelectItem[] = [\n {\n key: AvailabilityStatus.Available,\n value:\n <div style={{ whiteSpace: \"pre-line\" }}>\n <FiberManualRecordIcon className={classes.availableCircle} style={{color: '#36CE91'}}/>\n {t(\"Available\")}\n <br/>\n <span className={classes.availableCaption}>\n {t(\"You can respond to your customers\")}\n </span>\n </div>\n } as SelectItem,\n {\n key: AvailabilityStatus.Away,\n value:\n <div style={{ whiteSpace: \"pre-line\" }}>\n <FiberManualRecordIcon className={classes.availableCircle} style={{color: '#F15857'}}/>\n {t(\"Away\")}\n <br/>\n <span className={classes.availableCaption}>\n {t(\"The chatbot will respond to your customers\")}\n </span>\n </div>\n } as SelectItem\n ];\n\n async function fetchSearchData() {\n if (debouncedSearchQuery.length < 3)\n return;\n\n setIsLoading(true);\n dispatch(navbarActions.setShowLoader(true));\n \n if (accountSettings.isEnterprise === null) return;\n const searchPreviews = accountSettings.isEnterprise\n ? await WhatsAppService.getSearchByEstablishments(debouncedSearchQuery, 1, firstPageSize, selectedEstablishments)\n : await WhatsAppService.getSearch(debouncedSearchQuery, 1, firstPageSize); \n \n if (searchPreviews.length < firstPageSize)\n setHasMore(false);\n else\n setHasMore(true)\n\n dispatch(navbarActions.setShowLoader(false));\n\n setConversations(searchPreviews);\n const curConv = getCurrentConversation(searchPreviews);\n\n if (curConv)\n setCurrentChat(new ConversationPreview(curConv));\n else if (searchPreviews.length > 0) {\n setCurrentChat(new ConversationPreview(searchPreviews[0]));\n setSelectedConversation({ customerPhoneNumber: searchPreviews[0].customerMobile, establishmentId: searchPreviews[0].establishmentId })\n }\n else {\n setCurrentChat(undefined);\n setSelectedConversation({ customerPhoneNumber: null, establishmentId: null })\n }\n\n setIsLoading(false);\n }\n\n const getCurrentConversation = (conversations: ConversationPreview[]) => {\n const mobile = props.location?.state?.mobile;\n if (mobile === undefined || mobile === null) return;\n const curConv = conversations.find(c => c.customerMobile.includes(mobile));\n if (curConv === undefined) return;\n return curConv;\n }\n\n async function fetchData() {\n setIsLoading(true);\n dispatch(navbarActions.setShowLoader(true));\n \n if (accountSettings.isEnterprise === null) return;\n const conversationsPreviewList = accountSettings.isEnterprise \n ? await WhatsAppService.getConversationsPreviewByEstablishments(1, firstPageSize, selectedEstablishments)\n : await WhatsAppService.getConversationsPreview(1, firstPageSize);\n \n dispatch(navbarActions.setShowLoader(false));\n \n const conversationsPreviews = conversationsPreviewList.conversationPreviews;\n setHasMore(conversationsPreviewList.hasMore);\n setAvailabilityStatus(conversationsPreviewList.availabilityStatus);\n setConversations(conversationsPreviews);\n\n if (currentChat === undefined || searchWasRun) {\n if (searchWasRun)\n setSearchWasRun(false);\n //if page is just loading, load chat from routing or first chat in list\n const curConv = getCurrentConversation(conversationsPreviews);\n\n if (curConv) {\n setCurrentChat(new ConversationPreview(curConv));\n setSelectedConversation({ customerPhoneNumber: curConv.customerMobile, establishmentId: curConv.establishmentId })\n }\n else if (conversationsPreviews.length > 0) {\n setCurrentChat(new ConversationPreview(conversationsPreviews[0]));\n setSelectedConversation({ customerPhoneNumber: conversationsPreviews[0].customerMobile, establishmentId: conversationsPreviews[0].establishmentId })\n }\n\n } else if (currentChat && selectedEstablishments && currentChat.establishmentId) {\n if (!selectedEstablishments.includes(currentChat.establishmentId)) {\n if (conversationsPreviews[0]) {\n setCurrentChat(new ConversationPreview(conversationsPreviews[0]));\n setSelectedConversation({ customerPhoneNumber: conversationsPreviews[0].customerMobile, establishmentId: conversationsPreviews[0].establishmentId })\n } else {\n setCurrentChat(undefined);\n setSelectedConversation({ customerPhoneNumber: null, establishmentId: null })\n }\n }\n } else if (currentChat)\n //if we received new chat list and current chat is not in the list, add it to list\n {\n if (!isDialogPresentInNewList(currentChat, conversationsPreviews)) {\n setConversations([...conversationsPreviews, currentChat])\n }\n }\n setIsLoading(false);\n }\n\n async function fetchMoreData() {\n if (isLoading) return;\n if (!hasMore) return;\n setIsLoading(true);\n\n dispatch(navbarActions.setShowLoader(true));\n \n if (accountSettings.isEnterprise === null) return;\n const conversationsPreviewsList = accountSettings.isEnterprise\n ? await WhatsAppService.getConversationsPreviewByEstablishments(nextPageNumber, pageSize, selectedEstablishments)\n : await WhatsAppService.getConversationsPreview(nextPageNumber, pageSize);\n \n dispatch(navbarActions.setShowLoader(false));\n \n setConversations([...conversations, ...conversationsPreviewsList.conversationPreviews])\n setHasMore(conversationsPreviewsList.hasMore);\n setNextPageNumber((prev) => prev + 1);\n \n setIsLoading(false);\n }\n async function fetchMoreSearchData() {\n if (isLoading) return;\n if (!hasMore) return;\n setIsLoading(true);\n\n dispatch(navbarActions.setShowLoader(true));\n\n if (accountSettings.isEnterprise === null) return;\n const searchPreviews = accountSettings.isEnterprise\n ? await WhatsAppService.getSearchByEstablishments(debouncedSearchQuery, nextPageNumber, firstPageSize, selectedEstablishments)\n : await WhatsAppService.getSearch(debouncedSearchQuery, nextPageNumber, firstPageSize);\n \n dispatch(navbarActions.setShowLoader(false));\n \n if (searchPreviews.length < firstPageSize)\n setHasMore(false);\n else\n setHasMore(true)\n setConversations([...conversations, ...searchPreviews])\n setNextPageNumber((prev) => prev + 1);\n\n setIsLoading(false);\n }\n \n async function handleSelectAvailabilityStatus(event: any) {\n let value = event.target.value;\n setAvailabilityStatus(value);\n await WhatsAppService.updateAvailabilityStatus(value);\n }\n \n function handleOnSelectAvailabilityRender(key: any) {\n return (\n <div>\n <FiberManualRecordIcon\n className={classes.availableCircle}\n style={{ marginBottom: 1, color: availabilityStatus === AvailabilityStatus.Available ? '#36CE91' : '#F15857' }}/>\n {t(AvailabilityStatus[key])}\n </div>\n );\n }\n \n async function onBlockCustomer(customerId: string, customerMobile: string, block: boolean) {\n await WhatsAppService.blockCustomer(customerId, customerMobile, block);\n \n const conversationIndex = conversations.findIndex(c => c.customerMobile === customerMobile);\n if (conversationIndex === -1) return;\n const newConversations = [...conversations];\n newConversations[conversationIndex].isCustomerBlocked = block;\n setConversations(newConversations);\n \n if (currentChat?.customerMobile === customerMobile) {\n const updatedChat = new ConversationPreview(currentChat);\n updatedChat.isCustomerBlocked = block;\n setCurrentChat(updatedChat);\n }\n };\n \n function onAvailabilityStatusUpdate(availabilityStatus: AvailabilityStatus) {\n setAvailabilityStatus(availabilityStatus);\n }\n\n useEffect(() => {\n document.body.classList.add(classes.hideScrollbars);\n let element = document.getElementById('root');\n element?.classList.add(classes.disableYScroll);\n return () => {\n document.body.classList.remove(classes.hideScrollbars);\n element?.classList.remove(classes.disableYScroll);\n };\n }, []);\n\n useEffect(() => {\n if (debouncedSearchQuery !== \"\") {\n return;\n }\n if (refresh) {\n setNextPageNumber(2)\n }\n fetchData();\n }, [refresh, debouncedSearchQuery, accountSettings.isEnterprise, selectedEstablishments]);\n\n useEffect(() => {\n setHasMore(false);\n setNextPageNumber(2);\n setConversations([]);\n if (debouncedSearchQuery.trim().length > 2) {\n setIsSearchMode(true);\n setSearchWasRun(true);\n fetchSearchData();\n }\n else {\n setIsSearchMode(false);\n }\n }, [debouncedSearchQuery]);\n \n useEffect(() => {\n if (accountSettings.isEnterprise === false) {\n dispatch(navbarActions.setExternalContent(<AvailabilityStatusSelect />));\n }\n }, [accountSettings.isEnterprise, availabilityStatus]);\n \n const AvailabilityStatusSelect = () => {\n return (\n <div className={classes.availabilityStatusContainer}>\n <Select\n items={availabilityStatuses}\n value={availabilityStatus}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.select}\n itemRootClass={classes.itemRoot}\n width={400}\n onRender={handleOnSelectAvailabilityRender}\n onChange={handleSelectAvailabilityStatus}\n />\n </div>\n );\n }\n\n const receiveMessages = async (messagesByCustomers: MessagesByCustomer[] | undefined) => {\n if (messagesByCustomers !== undefined) {\n if (currentChat) {\n //if all updated dialogs are present in current list, just update their order and last message\n if (messagesByCustomers.every(x => isDialogPresentInInboundMessageList(x, conversations))) {\n let newConversations = [...conversations];\n\n for (let i = 0; i < messagesByCustomers.length; i++) {\n const conversationIndex = newConversations.findIndex(c => c.customerMobile == messagesByCustomers[i].customerMobile && c.establishmentId === messagesByCustomers[i].establishmentId);\n const lastMessageInList = findLastMessage(messagesByCustomers[i]);\n newConversations[conversationIndex].lastMessageTime = lastMessageInList.time;\n newConversations[conversationIndex].lastMessageText = lastMessageInList.text;\n newConversations[conversationIndex].lastMessageType = lastMessageInList.type\n if (lastMessageInList.isInbound) {\n newConversations[conversationIndex].isDisabledActivity = false;\n newConversations[conversationIndex].unreadMessagesCount += messagesByCustomers[i].messages.filter(x => x.isInbound).length;\n }\n }\n\n newConversations = newConversations.sort(sortConversationsByLastMessageTimeDesc);\n setConversations(newConversations);\n\n }\n else { //download new list of dialogues\n setRefresh(messagesByCustomers);\n }\n\n //if messages for current chat are present, add them to conversation\n const currentChatIndexInNewMessages = messagesByCustomers.findIndex(x => x.customerMobile === currentChat.customerMobile);\n\n await tryAddNewMessages(currentChatIndexInNewMessages, messagesByCustomers);\n }\n }\n }\n\n const tryAddNewMessages = async (currentChatIndexInNewMessages: number, messagesByCustomers: MessagesByCustomer[]) => {\n if (currentChatIndexInNewMessages !== -1) {\n messengerRef.current?.addNewMessages(messagesByCustomers[currentChatIndexInNewMessages].messages.sort(sortMessagesByTime));\n if (messagesByCustomers[currentChatIndexInNewMessages].messages.some(i => i.isInbound)) {\n const updatedChat = new ConversationPreview(currentChat);\n updatedChat.isDisabledActivity = false;\n setCurrentChat(updatedChat);\n }\n await WhatsAppService.markConversationAsRead(currentChat!.customerMobile);\n }\n }\n\n const onMarkConversationAsRead = (customerMobile: string) => {\n const conversationIndex = conversations.findIndex(c => c.customerMobile === customerMobile);\n if (conversationIndex === -1) return;\n const newConversations = [...conversations];\n newConversations[conversationIndex].unreadMessagesCount = 0;\n setConversations(newConversations);\n }\n\n const onChangeScheduledFollowUpState = (customerMobile: string, hasScheduledFollowUp: boolean) => {\n const conversationIndex = conversations.findIndex(c => c.customerMobile === customerMobile);\n if (conversationIndex === -1) return;\n const newConversations = [...conversations];\n newConversations[conversationIndex].hasScheduledFollowUp = hasScheduledFollowUp;\n setConversations(newConversations);\n\n if (currentChat?.customerMobile === customerMobile) {\n const updatedChat = new ConversationPreview(currentChat);\n updatedChat.hasScheduledFollowUp = hasScheduledFollowUp;\n setCurrentChat(updatedChat);\n }\n }\n\n const isDialogPresentInInboundMessageList = (dialog: MessagesByCustomer, array: ConversationPreview[]) => {\n return array.findIndex(e => e.customerMobile === dialog.customerMobile && e.establishmentId === dialog.establishmentId) !== -1;\n }\n\n const isDialogPresentInNewList = (dialog: ConversationPreview, array: ConversationPreview[]) => {\n return array.findIndex(e => e.customerMobile === dialog.customerMobile && e.establishmentId === dialog.establishmentId) !== -1;\n }\n\n const sortConversationsByLastMessageTimeDesc = (firstEl: ConversationPreview, secondEl: ConversationPreview) => {\n if (firstEl.lastMessageTime! > secondEl.lastMessageTime!) return -1;\n if (firstEl.lastMessageTime! < secondEl.lastMessageTime!) return 1;\n return 0;\n }\n\n const sortMessagesByTime = (firstEl: Message, secondEl: Message) => {\n if (firstEl.time! > secondEl.time!) return -1;\n if (firstEl.time! < secondEl.time!) return 1;\n return 0;\n }\n\n const findLastMessage = (msg: MessagesByCustomer) => {\n return msg.messages.reduce((a, b) => a.time! > b.time! ? a : b);\n }\n\n const markConversationAsRead = useCallback(async (customerMobile: string) => {\n const i = conversations.findIndex(c => c.customerMobile === customerMobile);\n if (conversations[i]?.unreadMessagesCount > 0) {\n currentChat?.establishmentId \n ? await WhatsAppService.markConversationAsReadAsEstablishment(currentChat?.establishmentId, customerMobile)\n : await WhatsAppService.markConversationAsRead(customerMobile);\n }\n }, [currentChat?.customerMobile]);\n\n const dispatch = useDispatch();\n const whatsAppHubConnection = useSelector(\n (state: RootState) => state.whatsAppHub.connection\n );\n dispatch(connect());\n\n //unsubscribe first so subscriptions does not duplicate\n whatsAppHubConnection?.off(\"receiveMessages\")\n whatsAppHubConnection?.off(\"markConversationsAsRead\")\n whatsAppHubConnection?.off(\"updateAvailabilityStatus\")\n whatsAppHubConnection?.off(\"changeScheduledFollowUpState\")\n\n whatsAppHubConnection?.on(\"receiveMessages\", (messages) => receiveMessages(messages))\n whatsAppHubConnection?.on(\"markConversationsAsRead\", (customerMobile) => onMarkConversationAsRead(customerMobile))\n whatsAppHubConnection?.on(\"updateAvailabilityStatus\", (availabilityStatus) => onAvailabilityStatusUpdate(availabilityStatus))\n whatsAppHubConnection?.on(\"changeScheduledFollowUpState\", (customerMobile, hasScheduledFollowUp) => onChangeScheduledFollowUpState(customerMobile, hasScheduledFollowUp))\n\n\n return (\n <>\n <EstablishmentsToolbar />\n <div className={classes.messengerLayout}>\n <Grid container>\n <div>\n <div className={classes.toolbarContainer}>\n <InputSearch\n style={{ width: 280, marginTop: 7 }}\n placeholder={t(\"Search conversation\")}\n onSearch={fetchSearchData}\n value={searchQuery}\n onReset={() => setSearchQuery(\"\")}\n onChange={(e: any) => setSearchQuery(e.target.value)}\n />\n </div>\n <Grid item className={classes.buildScrollbars} style={{ overflow: \"auto\" }}>\n <InfiniteScroll\n pageStart={0}\n loadMore={isSearchMode ? fetchMoreSearchData : fetchMoreData}\n hasMore={hasMore}\n useWindow={false}\n loader={<Box className={classes.loader}><CircularProgress /></Box>}\n >\n {\n conversations.length === 0 && !isLoading\n ? <div className={classes.noConversationsContainer}>\n {isSearchMode ? t(\"No chats, messages or customers found\") : \"\"}\n </div>\n :\n conversations.map((conversation) =>\n <ConversationsListItem\n key={conversation.lastMessageId}\n customerName={conversation.customerName}\n lastMessageText={conversation.lastMessageText}\n lastMessageTime={conversation.lastMessageTime}\n lastMessageType={conversation.lastMessageType}\n wasSendMore1DayAgo={conversation.wasSendMore1DayAgo}\n isDisabledActivity={conversation.isDisabledActivity}\n isDisabledNotContactable={conversation.isDisabledNotContactable}\n isSelected={currentChat && currentChat.lastMessageId === conversation.lastMessageId}\n unreadMessagesCount={conversation.unreadMessagesCount}\n hasScheduledFollowUp={conversation.hasScheduledFollowUp}\n onSelect={() => {\n setSelectedConversation({ customerPhoneNumber: conversation.customerMobile, establishmentId: conversation.establishmentId });\n setCurrentChat(new ConversationPreview(conversation));\n }}\n establishmentName={conversation.establishmentName}\n />)\n }\n </InfiniteScroll>\n </Grid>\n </div>\n <Grid item>\n {currentChat?.customerMobile === undefined || currentChat.customerMobile === \"\"\n ? isLoading\n ? <div></div>\n : <div className={classes.noConversation}>\n <div className={classes.noConversationImage}>\n <NoConversationsImage />\n </div>\n <div className={classes.noConversationText1}>\n {t(\"Ooops! There's nothing here\")}\n </div>\n {isSearchMode\n ? <></>\n : <div className={classes.noConversationText2} >\n {t(\"At the moment, there are no conversations to show.\")}\n </div>}\n </div>\n : <ConversationWindow\n ref={messengerRef}\n lastMessageId={currentChat?.lastMessageId}\n customerId={currentChat?.customerId}\n customerName={currentChat?.customerName}\n customerMobile={currentChat.customerMobile}\n wasSendMore1DayAgo={currentChat?.wasSendMore1DayAgo}\n isDisabledActivity={currentChat?.isDisabledActivity}\n isDisabledNotContactable={currentChat?.isDisabledNotContactable}\n isCustomerBlocked={currentChat?.isCustomerBlocked}\n unreadMessagesCount={currentChat.unreadMessagesCount}\n canScheduleFollowUp={currentChat?.canScheduleFollowUp}\n hasScheduledFollowUp={currentChat?.hasScheduledFollowUp}\n hasUnpaidAppointment={currentChat?.hasUnpaidAppointment}\n markConversationAsRead={markConversationAsRead}\n isSearch={isSearchMode}\n selectedConversation={selectedConversation}\n foundMessageText={currentChat?.lastMessageText}\n establishmentId={currentChat?.establishmentId}\n establishmentName={currentChat?.establishmentName}\n onBlockCustomer={onBlockCustomer}\n />}\n </Grid>\n </Grid>\n </div>\n </>\n );\n}","import * as React from \"react\";\nimport { Redirect } from \"react-router-dom\";\nimport { Url } from \"../../../constants/url\";\nimport { useParams } from \"react-router-dom\";\n\nconst WhatsAppConversationRouter = (props:any) =>{\n const history = useParams<any>();\n return (\n <Redirect to={{pathname: Url.WhatsApp.Main, state: {mobile: history.mobile}}} />\n )\n}\n\nexport default WhatsAppConversationRouter;\n","import MassiveSendingServiceModel from \"./massive-sending-service-model\";\n\n\nexport class MassiveSendingEntity {\n id: string | null;\n name: string;\n type: number;\n customerFrequency: number;\n customerGender: number;\n prospectedServices: MassiveSendingServiceModel[];\n prospectedServicesAppointmentStartDate: Date | null;\n prospectedServicesAppointmentEndDate: Date | null;\n dateOfSending: Date | null;\n timeOfSending: string;\n terminationDate: Date | null;\n birthdaySendingType: number | null;\n status: number;\n contentType: number;\n text: string;\n image: File | undefined;\n imageUrl: string | undefined;\n imageFileName: string | undefined;\n sendImmediately: boolean;\n \n constructor(x?: any) {\n const newDate = new Date();\n const currentYear = newDate.getFullYear();\n const currentMonth = newDate.getMonth();\n const nextDay = newDate.getDate() + 1;\n const tomorrowDate = new Date(currentYear, currentMonth, nextDay);\n if (typeof x === \"object\") {\n this.id = x.id;\n this.name = x.name;\n this.type = x.type;\n this.customerFrequency = x.customerFrequency;\n this.customerGender = x.customerGender;\n this.prospectedServices = x.prospectedServices;\n this.prospectedServicesAppointmentStartDate = x.prospectedServicesAppointmentStartDate;\n this.prospectedServicesAppointmentEndDate = x.prospectedServicesAppointmentEndDate;\n this.dateOfSending = x.dateOfSending !== null ? new Date(x.dateOfSending) : null;\n this.timeOfSending = x.timeOfSending;\n this.terminationDate = x.terminationDate !== null ? new Date(x.terminationDate) : null;\n this.birthdaySendingType = x.birthdaySendingType;\n this.status = x.status;\n this.contentType = x.contentType;\n this.text = x.text;\n this.image = x.image;\n this.imageUrl = x.imageUrl;\n this.imageFileName = x.imageFileName;\n this.sendImmediately = x.sendImmediately;\n } else {\n this.id = null;\n this.name = \"\";\n this.type = 0;\n this.customerFrequency = 0;\n this.customerGender = 0;\n this.prospectedServices = [];\n this.prospectedServicesAppointmentStartDate = null;\n this.prospectedServicesAppointmentEndDate = null;\n this.dateOfSending = tomorrowDate;\n this.timeOfSending = \"12:00\";\n this.terminationDate = null;\n this.birthdaySendingType = 0;\n this.status = 0;\n this.contentType = 0;\n this.text = \"\";\n this.image = undefined;\n this.imageUrl = undefined;\n this.imageFileName = undefined;\n this.sendImmediately = false;\n }\n }\n}","export default class MassiveSendingServiceModel {\n id: string;\n name: string;\n\n constructor(x?: MassiveSendingServiceModel) {\n if (typeof x === \"object\" && x) {\n this.id = x.id;\n this.name = x.name;\n }\n else {\n this.id = \"\";\n this.name = \"\";\n }\n }\n}\n\n","import { ApiClient } from \"./api-client\";\nimport { Response } from \"../models/response\";\nimport { GridInfoModel } from \"../models/helpers/grid-info.model\";\nimport { MassiveSendingEntity } from \"../models/massive-sending-entity\";\nimport MassiveSendingServiceModel from \"../models/massive-sending-service-model\";\nimport { FileUploadResponse } from \"../models/file-upload-response\";\n\n\nexport class MassiveSendingService {\n\n private static baseUrl: string = \"/massivesending\";\n private static isoDate(date: Date): string {\n const year = date.toLocaleString(\"en-US\", {\n year: \"numeric\",\n });\n const month = date.toLocaleString(\"en-US\", {\n month: \"2-digit\",\n });\n const day = date.toLocaleString(\"en-US\", {\n day: \"2-digit\",\n });\n \n return `${year}-${month}-${day}`;\n }\n \n private static handleTime(date: Date): Date {\n const time = date.toLocaleString(\"en-US\", {\n hour: \"2-digit\",\n minute: \"2-digit\",\n second: \"2-digit\",\n hour12: false,\n });\n \n return new Date(`${this.isoDate(date)}`);\n }\n static getSendings( \n gridInfo: GridInfoModel, \n customerFilter: number | null,\n statusFilter: number | null\n ): Promise<Response> {\n\n let urlEndpoint = `${this.baseUrl}/GetByAccount`;\n\n urlEndpoint += `?page=${gridInfo.page}&pageSize=${gridInfo.pageSize}`\n\n if (gridInfo.order && gridInfo.orderBy) {\n urlEndpoint += `&order=${gridInfo.order}&orderBy=${gridInfo.orderBy}`;\n }\n\n if (gridInfo.value && gridInfo.properties && gridInfo.properties.length > 0) {\n urlEndpoint += `&value=${gridInfo.value}`;\n for (const property of gridInfo.properties) {\n urlEndpoint += `&Properties=${property}`;\n }\n }\n\n if (customerFilter !== undefined)\n urlEndpoint += `&frequency=${customerFilter}`;\n \n if (statusFilter !== undefined)\n urlEndpoint += `&status=${statusFilter}`;\n\n return ApiClient.get(urlEndpoint, undefined).then((data) => {\n return new Response(data.massiveSending, data.total);\n });\n }\n \n static getServicesByAccount(): Promise<MassiveSendingServiceModel[]> {\n return ApiClient.get(`${this.baseUrl}/GetServicesByAccount`, undefined).then(\n (data) => data.services.map((service: MassiveSendingServiceModel) => new MassiveSendingServiceModel(service))\n );\n }\n\n static getSendingById(id: string): Promise<MassiveSendingEntity> {\n return ApiClient.get(`${this.baseUrl}/get?id=${id}`, undefined).then(\n (data) => new MassiveSendingEntity(data.massiveSending)\n );\n }\n\n static getSendingsNamesByAccount(): Promise<string[]> {\n return ApiClient.get(`${this.baseUrl}/GetSendingsNameByAccount`, undefined).then((data) => {\n return data.massiveSendingsNames;\n });\n }\n\n static createSendingWithImage(massiveSending: MassiveSendingEntity): Promise<MassiveSendingEntity> {\n let formData = new FormData();\n if (massiveSending.dateOfSending !== null)\n massiveSending.dateOfSending = this.handleTime(massiveSending.dateOfSending as Date);\n formData.append(\"command\", JSON.stringify(massiveSending));\n if (massiveSending.image) {\n formData.append(\"image\", massiveSending.image, massiveSending.image.name);\n }\n return ApiClient.post(`${this.baseUrl}/createWithImage`, formData, {\n headers: { \"Content-Type\": \"multipart/form-data\" }\n }).then(\n (data) => new MassiveSendingEntity(data.massiveSending)\n );\n }\n\n static createSending(massiveSending: MassiveSendingEntity): Promise<MassiveSendingEntity> {\n if (massiveSending.dateOfSending !== null)\n massiveSending.dateOfSending = this.handleTime(massiveSending.dateOfSending as Date);\n return ApiClient.post(`${this.baseUrl}/create`, { massiveSending }, undefined).then(\n (data) => new MassiveSendingEntity(data.massiveSending)\n );\n }\n\n static updateSendingWithImage(massiveSending: MassiveSendingEntity): Promise<MassiveSendingEntity> {\n let formData = new FormData();\n if (massiveSending.dateOfSending !== null)\n massiveSending.dateOfSending = this.handleTime(massiveSending.dateOfSending as Date);\n formData.append(\"command\", JSON.stringify(massiveSending));\n if (massiveSending.image) {\n formData.append(\"image\", massiveSending.image, massiveSending.image.name);\n }\n return ApiClient.post(`${this.baseUrl}/updateWithImage`, formData, {\n headers: { \"Content-Type\": \"multipart/form-data\" }\n }).then(\n (data) => new MassiveSendingEntity(data.massiveSending)\n );\n }\n\n static updateSending(massiveSending: MassiveSendingEntity): Promise<MassiveSendingEntity> {\n if (massiveSending.dateOfSending !== null)\n massiveSending.dateOfSending = this.handleTime(massiveSending.dateOfSending as Date);\n return ApiClient.put(`${this.baseUrl}/update`, { massiveSending }, undefined).then(\n (data) => new MassiveSendingEntity(data.massiveSending)\n );\n }\n\n static deleteSending(sendingId: string) : Promise<any> {\n return ApiClient.remove(`${this.baseUrl}/delete?id=${sendingId}`, undefined);\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../constants/colors\";\n\nexport const useStyles = makeStyles((theme) => ({\n buttonRow: {\n width: 32,\n height: 32,\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\",\n borderRadius: 20,\n padding: 10,\n display: \"inline\",\n cursor: \"pointer\",\n \"&:hover\": {\n background: \"#ebebeb\"\n }\n },\n iconTrash: {\n fill: Color.gray5\n },\n icon: {\n paddingTop: 5,\n height: 30,\n width: 30,\n fontWeight: \"bold\"\n },\n classRow: {\n // cursor: \"pointer\",\n \"& div.buttonRow\": {\n visibility: \"hidden\",\n },\n \"&:hover\": {\n \"& div.buttonRow\": {\n visibility: \"visible\"\n }\n }\n },\n classHead: {\n color: theme.colors.grey5,\n textAlign: \"left\"\n },\n classCell: {\n color: theme.colors.grey5,\n },\n divStatus: {\n borderRadius: 5,\n color: \"#FFFFFF\",\n padding: \"5px 10px\",\n width: \"fit-content\",\n fontFamily: \"Roboto\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12\n },\n statusActive: {\n color: \"#6462F3\",\n backgroundColor: \"rgba(100, 98, 243, 0.2)\"\n },\n statusDone: {\n marginLeft: -2,\n color: \"#36CE91\",\n backgroundColor: \"rgba(54, 206, 145, 0.2)\"\n },\n modalCenter: {\n display: \"flex\",\n justifyContent: \"center\",\n },\n modalTitleSpace: {\n margin: \"24px 0px 8px 0px\",\n },\n modalContentText: {\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n textAlign: \"center\",\n color: \"#4A4D51\",\n },\n modalTitleText: {\n fontSize: \"18px\",\n lineHeight: \"22px\",\n textAlign: \"center\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n },\n modalDelete: {\n height: 280\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n },\n impactedCustomersContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\"\n }\n}));\n\n\nexport default useStyles;\n","export enum MassiveSendingType\n{\n SingleSending = 0,\n Annual,\n Birthdays\n}\n ","export enum MassiveSendingBirthdayType\n{\n SameDay = 0,\n OneDayBefore,\n OneWeekBefore,\n TwoWeeksBefore,\n OneMonthBefore\n}\n\n\nexport const GetSendingBirthdayStringEnum = (num: MassiveSendingBirthdayType | number): string => {\n \n const birthdaySendingRules: { [key: number] : string } = {\n 0: \"Same day of the birthday\",\n 1: \"One day before the birthday\",\n 2: \"One week before the birthday\",\n 3: \"Two weeks before the birthday\",\n 4: \"One month before the birthday\",\n };\n\n return birthdaySendingRules[num] || \"\";\n}\n\n","export class GridInfoModel {\n\n page: number | null;\n pageSize: number;\n order: string | null;\n orderBy: string | null;\n value: any | null; // searchValue\n properties?: string[] | null;\n total: number | null;\n\n constructor(x?: any) {\n if (typeof x === \"object\" && x !== null && x !== undefined) {\n this.page = x.page;\n this.pageSize = x.pageSize;\n this.order = x.order;\n this.orderBy = x.orderBy;\n this.value = x.value;\n this.total = x.total;\n this.properties = x.properties;\n } else {\n this.page = 0;\n this.pageSize = 20;\n this.order = \"asc\";\n this.orderBy = \"\";\n this.value = \"\";\n this.total = 0;\n this.properties = null;\n }\n }\n\n}\n\n\n\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n container: {\n display: \"flex\",\n flexDirection: \"row\",\n gap: \"3px\"\n },\n count: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: theme.colors.clearMain\n }\n})\n);\n\nexport default useStyles;","import React, { useState } from \"react\";\n\nimport { IconCounterProps } from \"./props\";\nimport useStyles from \"./css\";\n\nexport default function IconCounter(props: IconCounterProps) {\n\n const { count, icon } = props;\n\n const classes = useStyles();\n\n return (\n <div className={classes.container}>\n {icon}\n <div className={classes.count}>\n {count}\n </div>\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from 'react-i18next';\nimport moment from 'moment';\n\nimport { CalendarCheckmarkIcon, EditIcon, PersonCheckmarkIcon, PersonSpeechBalloonIcon, TrashIcon } from \"../../../../assets/icons\";\nimport GridList, { OnChangeEvent } from \"../../../common/grid/GridList\";\nimport { TableColumn } from \"../../../common/grid/table-column\";\nimport { Color } from \"../../../../constants/colors\";\n\nimport { ApiClient } from \"../../../../api/api-client\";\nimport { MassiveSendingService } from \"../../../../api/massive-sending-service\";\nimport SendingModel from \"../../../../models/massive-sending-model\";\n\nimport { MassiveSendingListProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { SelectItem } from \"../../../common/Select\";\nimport { GridInfoModel } from \"../../../../models/helpers/grid-info.model\";\nimport ConfirmDeleteModal from \"../../../common/ConfirmDeleteModal\";\nimport { Typography } from \"@material-ui/core\";\nimport { GetMonthStringEnum } from \"../../../../models/enums/months\";\nimport { MassiveSendingType } from \"../../../../models/enums/massive-sending-type\";\nimport { GetSendingBirthdayStringEnum, MassiveSendingBirthdayType } from \"../../../../models/enums/massive-sending-birthday-type\";\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport IconCounter from \"../../../common/IconCounter\";\nimport IconTooltip from \"../../../common/IconTooltip\";\nimport useCustomerTerminology from \"../../../../hooks/useCustomerTerminology\";\nimport { navbarActions } from \"../../../../redux/navbar-slice\";\n\n\nconst MassiveSendingList = (props: MassiveSendingListProps) => {\n\n const { t } = useTranslation([\"massivesendings\", \"general\"]);\n const localeApp = useAppSelector(state => state.applicationInterface.locale);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const hasMassiveSendings = ApiClient.getUserInfo().hasMassiveSendings;\n\n const {\n isRefresh,\n onRowClick,\n onDelete,\n handleModalDetailOpen,\n setTotalRecords\n } = props;\n\n const pageSize: number = 20;\n const [entityList, setEntityList] = useState<SendingModel[]>([]);\n const [total, setTotal] = useState<number>(0);\n\n const [openDeleteDialog, setOpenDeleteDialog] = useState<boolean>(false);\n const [itemToDelete, setItemToDelete] = useState<SendingModel | null>(null);\n\n const [filterCustomer, setFilterCustomer] = useState<SelectItem>({ key: 0, value: useCustomerTerminology(t(\"All customers\"), \"customers\") });\n const [filterStatus, setFilterStatus] = useState<SelectItem | null>(null);\n \n const sentToCustomersIconTooltipRecently = useCustomerTerminology(t(\"Customers to whom the WhatsApp message was sent\"), \"Customers\");\n const sentToCustomersIconTooltipThisYear = useCustomerTerminology(t(\"Customers to whom the WhatsApp message was sent this year\"), \"Customers\");\n const sentToCustomersIconTooltipThisMonth = useCustomerTerminology(t(\"Customers to whom the WhatsApp message was sent this month\"), \"Customers\");\n const customersRespondedTooltip = useCustomerTerminology(t(\"Customers responded to the massive sending\"), \"Customers\")\n const customersTypeAllCustomers = useCustomerTerminology(t(\"AllCustomers\"), \"AllCustomers\")\n const customersTypeFrequent = useCustomerTerminology(t(\"Frequent\"), \"Frequent\")\n const customersTypeInfrequent = useCustomerTerminology(t(\"Infrequent\"), \"Infrequent\")\n const customersTypeInactive = useCustomerTerminology(t(\"Inactive\"), \"Inactive\")\n\n const getTerminologyForFrequencyType = (str: string) => {\n switch (str) {\n case \"AllCustomers\": {\n return customersTypeAllCustomers;\n }\n case \"Frequent\": {\n return customersTypeFrequent;\n }\n case \"Infrequent\": {\n return customersTypeInfrequent;\n }\n case \"Inactive\": {\n return customersTypeInactive;\n }\n default: return \"AllCustomers\";\n }\n }\n \n const [gridInfo, setGridInfo] = useState<GridInfoModel>(new GridInfoModel({\n page: 1,\n pageSize,\n order: \"asc\",\n orderBy: \"name\",\n value: null,\n properties: [],\n total: 0\n }));\n\n\n useEffect(() => {\n (async () => {\n await loadData();\n })();\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [gridInfo, isRefresh, filterCustomer, filterStatus]);\n\n\n const loadData = async () => {\n dispatch(navbarActions.setShowLoader(true));\n const data = await MassiveSendingService.getSendings(\n gridInfo, filterCustomer?.key, filterStatus?.key\n );\n dispatch(navbarActions.setShowLoader(false));\n setEntityList(data.entity || []);\n setTotal(data.total || 0);\n if (setTotalRecords) setTotalRecords(data.total || 0);\n };\n\n const StatusStylized = (status: string) => {\n if (status === \"Active\") {\n return (<div className={`${classes.divStatus} ${classes.statusActive}`}>\n {t(status)}\n </div>)\n }\n else if (status === \"Finalized\") {\n return (<div className={`${classes.divStatus} ${classes.statusDone}`}>\n {t(status)}\n </div>)\n }\n else {\n return null\n }\n };\n\n const DateStylizedStart = (dateParam: Date, stringTimeOfSending: string, sendingType: MassiveSendingType, birthdayType: MassiveSendingBirthdayType | number) => {\n\n const date = new Date(dateParam);\n\n return <>{\n (sendingType === MassiveSendingType.Birthdays)\n ?\n t(GetSendingBirthdayStringEnum(birthdayType)) + \" \" + stringTimeOfSending + \"hrs\"\n :\n <>\n <div>\n {\n localeApp === \"es\"\n ?\n date.getDate().toString().padStart(2, \"0\") + \"/\" + t(GetMonthStringEnum(date.getMonth())) + \"/\" + date.getFullYear()\n :\n t(GetMonthStringEnum(date.getMonth())) + \"/\" + date.getDate().toString().padStart(2, \"0\") + \"/\" + date.getFullYear()\n }\n </div>\n <div>\n {stringTimeOfSending + \"hrs\"}\n </div>\n </>\n }</>\n };\n\n\n const DateStylizedEnd = (dateStartParam: Date, stringTimeOfSending: string, dateEndParam: Date, sendingType: MassiveSendingType) => {\n\n const dateStart = new Date(dateStartParam);\n const dateEnd = new Date(dateEndParam);\n\n return <>{\n (sendingType === MassiveSendingType.SingleSending)\n ?\n <>\n <div>\n {\n localeApp === \"es\"\n ?\n dateStart.getDate().toString().padStart(2, \"0\") + \"/\" + t(GetMonthStringEnum(dateStart.getMonth())) + \"/\" + dateStart.getFullYear()\n :\n t(GetMonthStringEnum(dateStart.getMonth())) + \"/\" + dateStart.getDate().toString().padStart(2, \"0\") + \"/\" + dateStart.getFullYear()\n }\n </div>\n <div>\n {stringTimeOfSending + \"hrs\"}\n </div>\n </>\n :\n dateEndParam\n ?\n <>{\n localeApp === \"es\"\n ?\n dateEnd.getDate().toString().padStart(2, \"0\") + \"/\" + t(GetMonthStringEnum(dateEnd.getMonth())) + \"/\" + dateEnd.getFullYear()\n :\n t(GetMonthStringEnum(dateEnd.getMonth())) + \"/\" + dateEnd.getDate().toString().padStart(2, \"0\") + \"/\" + dateEnd.getFullYear()\n }\n <div>\n {stringTimeOfSending + \"hrs\"}\n </div></>\n :\n <>{t(\"Never ends\")}</>\n }</>\n };\n\n const GetImpactedCustomerComponent = (massiveSendingType: number, sentToCustomersCount: number, responsesReceivedCount: number, appointmentsScheduledCount: number) => {\n let sentToCustomersIconTooltip;\n switch (massiveSendingType) {\n case 0: {\n sentToCustomersIconTooltip = sentToCustomersIconTooltipRecently;\n break;\n } \n case 1: {\n sentToCustomersIconTooltip = sentToCustomersIconTooltipThisYear;\n break;\n } \n case 2: {\n sentToCustomersIconTooltip = sentToCustomersIconTooltipThisMonth;\n break;\n } \n default: sentToCustomersIconTooltip = \"\";\n }\n return <div className={classes.impactedCustomersContainer}>\n <IconTooltip\n icon={<IconCounter count={sentToCustomersCount} icon={<PersonCheckmarkIcon />} />}\n tooltipText={sentToCustomersIconTooltip} />\n <IconTooltip\n icon={<IconCounter count={responsesReceivedCount} icon={<PersonSpeechBalloonIcon />} />}\n tooltipText={customersRespondedTooltip} />\n <IconTooltip\n icon={<IconCounter count={appointmentsScheduledCount} icon={<CalendarCheckmarkIcon />} />}\n tooltipText={t(\"Appointments scheduled 72 hours after massive sending\")} />\n </div>\n }\n\n const filterListCustomer: SelectItem[] = [\n { key: 0, value: useCustomerTerminology(t(\"All customers\"), \"customers\") },\n { key: 1, value: useCustomerTerminology(t(\"Frequents customers\"), (\"Frequents customers\"))},\n { key: 2, value: useCustomerTerminology(t(\"Infrequents customers\"), \"Infrequents customers\")},\n { key: 3, value: useCustomerTerminology(t(\"Inactives customers\"), \"Inactives customers\") }\n ];\n\n\n const filterListStatus: SelectItem[] = [\n { key: 0, value: t(\"Active\") },\n { key: 1, value: t(\"Finalized\") },\n ];\n\n const columns: TableColumn[] = [\n {\n id: \"name\",\n label: t(\"SENDING NAME\"),\n sorting: false,\n width: 180,\n },\n {\n id: \"customerFrequency\",\n label: useCustomerTerminology( t(\"CUSTOMERS\"), \"CUSTOMERS\"),\n sorting: false,\n width: 170,\n completeObject: true,\n component: (item: any) => <>\n <div style={{ fontWeight: 700 }}>\n { getTerminologyForFrequencyType(item.customerFrequency) }\n </div>\n <div>\n {t(item.customerGender)}\n </div>\n </>,\n filtering: true,\n filterList: filterListCustomer,\n setFilter: setFilterCustomer\n },\n {\n id: \"type\",\n label: t(\"TYPE OF SENDING\"),\n sorting: false,\n width: 130,\n completeObject: true,\n component: (item: any) => <>{t(item.type)}</>\n },\n {\n id: \"dateOfSending\",\n label: t(\"SEND DATE\"),\n sorting: true,\n width: 130,\n completeObject: true,\n component: (item: any) => DateStylizedStart(item.dateOfSending, item.stringTimeOfSending, item.typeId, item.birthdaySendingType),\n },\n {\n id: \"terminationDate\",\n label: t(\"ENDING DATE\"),\n sorting: false,\n width: 130,\n completeObject: true,\n component: (item: any) => DateStylizedEnd(item.dateOfSending, item.stringTimeOfSending, item.terminationDate, item.typeId),\n },\n {\n id: \"impactedCustomers\",\n label: useCustomerTerminology(t(\"IMPACTED CUSTOMERS\"), \"CUSTOMERS\"),\n sorting: false,\n width: 150,\n completeObject: true,\n component: (item: any) => GetImpactedCustomerComponent(item.typeId, item.sentToCustomersCount, item.responsesReceivedCount, item.appointmentsScheduledCount)\n },\n {\n id: \"status\",\n label: t(\"STATUS\"),\n sorting: false,\n width: 80,\n completeObject: true,\n headerTextAlign: \"center\",\n textAlign: \"center\",\n filtering: true,\n filterList: filterListStatus,\n setFilter: setFilterStatus,\n component: (item: any) => StatusStylized(item.status)\n },\n {\n id: \"id\",\n label: \"\",\n sorting: false,\n completeObject: true,\n component: (item: any) =>\n item.status === \"Finalized\"\n ? null\n :\n <>\n <div className={`${classes.buttonRow} buttonRow`} style={{ marginRight: 10 }} onClick={(e) => { e.stopPropagation(); handleOnEdit(item); }} >\n <EditIcon style={{ color: Color.gray4, width: 13, height: 17, }} />\n </div>\n <div className={`${classes.buttonRow} buttonRow`} onClick={(e) => { e.stopPropagation(); handleDeleteButtonClick(item); }} >\n <TrashIcon style={{ color: Color.gray4, width: 13, height: 17, }} />\n </div>\n </>,\n width: 100,\n headerTextAlign: \"center\",\n textAlign: \"center\",\n visible: hasMassiveSendings\n },\n ];\n\n\n const handleOnChangeGrid = (event: OnChangeEvent) => {\n\n const page = event.page;\n\n if (event.sorting) {\n const order = event.sorting.direction;\n const orderBy = event.sorting.orderBy;\n\n setGridInfo({\n ...gridInfo,\n page,\n order,\n orderBy\n });\n\n } else if (gridInfo.page !== page) {\n setGridInfo({\n ...gridInfo,\n page\n });\n }\n\n };\n\n\n const handleOnEdit = (item: any) => {\n if (onRowClick && hasMassiveSendings) onRowClick(item.id);\n };\n\n function handleDeleteButtonClick(item: SendingModel) {\n if (hasMassiveSendings) {\n setItemToDelete(item);\n setOpenDeleteDialog(true);\n }\n }\n\n const handleOnDelete = (item: any) => {\n if (onDelete) onDelete(item);\n setItemToDelete(null);\n setOpenDeleteDialog(false);\n };\n\n const DivInfoDelete: React.FC = () => {\n return (<>\n <div className={`${classes.modalCenter} ${classes.modalTitleSpace}`} >\n <Typography className={classes.modalTitleText}>\n {t(\"Delete massive sending?\")}\n </Typography>\n </div>\n <div className={classes.modalCenter}>\n <div className={classes.separator} style={{ width: 217 }} />\n </div>\n <div className={classes.modalCenter}>\n <Typography className={classes.modalContentText}>\n {t(\"If you delete the massive sending, its delivery will be canceled.\")}\n </Typography>\n </div>\n </>);\n };\n\n return (<>\n <GridList\n columns={columns}\n items={entityList}\n totalItems={total}\n pageSize={pageSize}\n onChange={handleOnChangeGrid}\n classRow={classes.classRow}\n showPaginationAlways={true}\n onRowClick={handleModalDetailOpen}\n />\n <ConfirmDeleteModal\n textButtonConfirm={t(\"Yes, delete\")}\n classModal={classes.modalDelete}\n open={openDeleteDialog}\n item={itemToDelete}\n componentInfo={<DivInfoDelete />}\n onClose={() => setOpenDeleteDialog(false)}\n onDelete={handleOnDelete}\n />\n </>);\n};\n\nexport default MassiveSendingList;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nexport const useStyles = makeStyles((theme) => ({\n header: {\n marginBottom: 10,\n paddingTop: 5\n },\n headerRight: {\n textAlign: \"right\"\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n textTransform: \"none\"\n },\n btnNewWorkArea: {\n background: \"#7175FA\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#6462F3\",\n },\n },\n titles: {\n color: theme.colors.grey4,\n fontSize: 12,\n fontWeight: \"bold\",\n marginBottom: 10\n },\n icons: {\n color: theme.colors.grey5,\n fontSize: 18\n },\n icon: {\n paddingTop: 5,\n height: 30,\n width: 30,\n fontWeight: \"bold\"\n }\n}));\n\n\nexport default useStyles;\n","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n container: {\n width: 812,\n height: 550,\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n paper: {\n margin: 0,\n width: 812,\n maxWidth: 812,\n maxHeight: 550,\n padding: \"40px 40px 18px\"\n },\n dialogHeader: {\n padding: \"0 0 12px\",\n },\n dialogContent: {\n padding: 0,\n overflowX: \"hidden\"\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n modalTitleRequiredFields: {\n ...theme.typography.buttons,\n color: theme.colors.grey4,\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n dot: {\n ...theme.typography.buttons,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n tabs: {\n ...theme.typography.txtBody2,\n \"& .MuiTabs-indicator\": {\n backgroundColor: \"#7175FA\"\n },\n \"& .Mui-selected\": {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: \"bold !important\"\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n alignItems: \"left\",\n marginRight: 25,\n },\n \"& .MuiTab-root\": {\n paddingLeft: 0,\n paddingRight: 0,\n textTransform: \"none\",\n ...theme.typography.txtBody2,\n },\n },\n tab: {\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n }\n },\n tabPanelRoot: {\n padding: \"0 !important\"\n }\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n label: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n margin: 0,\n marginBottom: 5\n },\n controlRow: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n width: 650,\n },\n annualControlRow: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"flex-end\",\n justifyContent: \"space-between\",\n width: 670\n },\n inputWithLabel: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n },\n controlLabel: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n disabledControlLabel: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8,\n opacity: 0.8\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n dateText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n },\n divider: {\n width: 731,\n marginTop: 24,\n marginBottom: 24,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey1\n },\n dividerCustomersServices: {\n width: 731,\n marginTop: 15,\n marginBottom: 15,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey1\n },\n customerTypes: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-between\",\n alignItems: \"flex-start\"\n },\n customerTypeSelectors: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\"\n },\n customerTypeSelector: {\n marginRight: 12\n },\n servicesSelector: {\n minWidth: 206,\n marginLeft: -5\n },\n services: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-between\",\n alignItems: \"flex-start\"\n },\n servicesInputIcon: {\n width: 12,\n height: 12,\n scale: 1,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n multiSelect: {\n display: 'flex',\n minWidth: 150,\n padding: '0px 8px',\n alignItems: 'center',\n gap: 4,\n borderRadius: 5,\n ...theme.typography.txtBody2,\n \"& .MuiSelect-select\": {\n minWidth: 150,\n paddingBottom: 3,\n paddingRight: 5,\n marginLeft: - 20,\n paddingLeft: 20,\n background: theme.colors.clear5,\n borderRadius: 5\n },\n \"& .MuiSelect-nativeInput\": {\n minWidth: 150\n }\n },\n selected: {\n fontWeight: 700,\n maxHeight: 210,\n color: theme.colors.clearMain,\n },\n tooltipBlockServices: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n maxWidth: 380,\n padding: 8,\n backgroundColor: theme.colors.grey1,\n ...theme.typography.subtitle2,\n color: theme.colors.grey5,\n borderRadius: 5,\n zIndex: 2,\n boxShadow: \"0px 4px 4px rgba(166, 166, 166, 0.25)\",\n },\n iconTooltip: {\n display: \"inline-block\",\n marginLeft: 2,\n \"&>div\": {\n maxWidth: 200,\n textAlign: 'start',\n fontSize: 9,\n lineHeight: 'normal',\n fontFamily: 'Inter'\n }\n },\n sendingTypes: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\"\n },\n sendingTypeEditText: {\n ...theme.typography.buttons,\n color: theme.colors.grey4,\n fontWeight: 700\n },\n sendingTypeName: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: 700,\n marginRight: 3,\n marginLeft: 3\n },\n radios: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n marginLeft: -5\n },\n radio: {\n width: 150,\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\"\n },\n singleSendingSettings: {\n marginTop: 8,\n height: 100,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n },\n servicesDates: {\n marginTop: 8,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n },\n annualSendingSettings: {\n height: 200,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-around\",\n alignItems: \"flex-start\",\n },\n birthdaySettings: {\n height: 200,\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-around\",\n alignItems: \"flex-start\",\n },\n switchBase: {\n padding: 1,\n opacity: 1,\n height: \"100%\",\n border: \"3px solid #323947\",\n \"&.Mui-checked\": {\n transform: \"translateX(13px)\",\n border: \"0px\",\n color: theme.palette.common.white,\n \"& + .MuiSwitch-track\": {\n backgroundColor: \"#36ce91\",\n opacity: 1,\n border: \"none\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 15,\n },\n //\n },\n \"&$focusVisible .MuiSwitch-thumb\": {\n color: \"#6462F3\",\n border: \"6px solid #fff\",\n },\n \"& * .MuiSwitch-thumb\": {\n width: 12,\n height: 15,\n boxShadow: \"none\",\n },\n },\n controlRowSwitch: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n width: 650,\n paddingTop: \"20px\"\n },\n switchLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: 400,\n marginRight: 7,\n marginLeft: 9\n },\n switchLabelActive: {\n color: theme.colors.clearMain,\n fontWeight: 700,\n },\n})\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n \"&:focus\": {\n borderColor: theme.colors.clearMain,\n },\n \"&.MuiSelect-select.MuiSelect-select\": {\n padding: \"6px 6px 3px 3px\"\n }\n },\n menuItem: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n padding: 12,\n height: 32\n },\n menuItemSelected: {\n fontWeight: \"bold\",\n color: theme.colors.clearMain\n },\n })\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n icon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n \n width: 12,\n height: 12,\n },\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport InputBase, { InputBaseProps } from \"@material-ui/core/InputBase\";\n\nimport useStyles from \"./css\";\nimport { MenuIcon } from \"../../../assets/icons\";\nimport { styled } from \"@material-ui/core\";\n\nexport default function Chip(props: InputBaseProps) {\n\n const classes = useStyles();\n \n const useChipStyles = (({ theme } : any) => ({\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"center\",\n\n ...theme?.typography?.subtitle1,\n fontWeight: 700,\n color: theme?.colors?.clear2,\n padding: 4,\n\n height: 22,\n width: \"fit-content\",\n backgroundColor: theme?.colors?.clear5,\n borderRadius: 5,\n \"&:focus\": {\n borderColor: theme?.colors?.clearMain,\n },\n })\n );\n \n const StyledInputBase = styled(InputBase)<InputBaseProps>(useChipStyles);\n \n return (\n <StyledInputBase \n {...props}\n startAdornment={\n <div className={classes.icon}>\n <MenuIcon />\n </div>\n }\n />\n )\n}","import React from \"react\";\n\nimport { Select } from \"@material-ui/core\";\nimport MenuItem from \"@material-ui/core/MenuItem\";\n\nimport useStyles from \"./css\";\nimport { ChipSelectProps } from \"./props\";\nimport Chip from \"../Chip\";\nimport { SelectItem } from \"../../../models/interfaces/select-item\";\n\n\nexport default function ChipSelect(props: ChipSelectProps) {\n \n const { items, item, setItem } = props;\n \n const classes = useStyles();\n\n const handleOnChange = (event: any) => {\n setItem(event.target.value);\n };\n \n return (\n <Select\n disableUnderline\n IconComponent={() => null}\n classes={{ root: classes.root }}\n onChange={handleOnChange}\n value={item || 0}\n input={<Chip />}\n inputProps={{ style: { padding: '0!important'}}}\n MenuProps={{\n anchorOrigin: {\n vertical: \"bottom\",\n horizontal: \"left\"\n },\n transformOrigin: {\n vertical: \"top\",\n horizontal: 17\n },\n getContentAnchorEl: null\n }}\n >\n {items.map((item: SelectItem) =>\n <MenuItem\n key={item.key}\n value={item.key}\n classes={{\n root: classes.menuItem,\n selected: classes.menuItemSelected\n }}\n >\n {item.value}\n </MenuItem>\n )}\n </Select>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n ...theme.typography.subtitle2,\n \n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n },\n radio: {\n color: theme.colors.grey5,\n paddingRight: 9,\n \"& svg\": {\n width: 14,\n height: 14\n }\n },\n checked: {\n color: theme.colors.clearMain,\n fontWeight: 700\n },\n text: {\n paddingRight: 3\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { FormControlLabel, Radio } from \"@material-ui/core\";\n\nimport useStyles from \"./css\";\nimport { RadioWithTextProps } from \"./props\";\n\n\nexport default function RadioWithText(props: RadioWithTextProps) {\n \n const { value, checked, onCheck, text, disabled } = props;\n const classes = useStyles();\n \n function handleChecking() {\n onCheck();\n }\n \n return (\n <div className={classes.root}>\n <Radio\n checked={checked}\n onChange={handleChecking}\n color={checked ? \"primary\" : \"default\"}\n classes={{\n root: classes.radio,\n checked: classes.checked\n }}\n disabled={disabled}\n />\n {typeof text === \"string\" \n ? <div className={`${classes.text} ${checked ? classes.checked : ''}`}>{text}</div>\n : text ?? null\n }\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n justifyContent: \"space-between\",\n height: 75\n },\n controlRow: {\n display: \"flex\",\n flexDirection: \"row\",\n alignItems: \"center\",\n justifyContent: \"flex-start\",\n }\n })\n);\n\nexport default useStyles;","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport { TerminationDateProps } from \"./props\";\nimport useStyles from \"./css\";\nimport RadioWithText from \"../../../common/RadioWithText\";\nimport DateInput from \"../../../common/DateInput\";\n\n\nexport default function TerminationDate(props: TerminationDateProps) {\n \n const { date, setDate, nullText, minDate } = props;\n const classes = useStyles();\n const { t } = useTranslation(\"general\");\n \n const neverEndsState = \"null\";\n const dateState = \"date\";\n const innerMinDate = minDate ?? new Date(new Date().setDate(new Date().getDate() + 1));\n \n const [innerValue, setInnerValue] = useState<\"null\" | \"date\">(\"null\");\n const [innerDate, setInnerDate] = useState<Date>(innerMinDate);\n \n useEffect(() => {\n if (date === null) {\n setInnerValue(neverEndsState)\n setInnerDate(innerMinDate);\n } else {\n setInnerValue(dateState);\n setInnerDate(date);\n }\n }, [])\n \n function handleNullCheck() {\n setInnerValue(neverEndsState);\n setDate(null);\n }\n \n function handleDateCheck() {\n setInnerValue(dateState);\n }\n \n function handleInnerDateChange(date: Date) {\n setInnerDate(date);\n }\n \n useEffect(() => {\n if (innerValue === neverEndsState) return;\n setDate(innerDate);\n }, [innerDate, innerValue])\n \n return (\n <div className={classes.root}>\n {nullText &&\n <div className={classes.controlRow}>\n <RadioWithText \n value={neverEndsState}\n checked={innerValue === neverEndsState}\n onCheck={handleNullCheck}\n text={nullText}\n />\n </div>\n }\n <div className={classes.controlRow}>\n <RadioWithText\n value={dateState}\n checked={innerValue === dateState}\n onCheck={handleDateCheck}\n text={\n <DateInput\n disabled={innerValue === neverEndsState}\n placeholder={t(\"dd/mm/yy\")}\n format={\"dd/MMMM/yyyy\"}\n value={innerDate}\n onChange={handleInnerDateChange}\n minDate={minDate}\n width={140}\n />\n }\n />\n </div>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number) =>\n makeStyles((theme) => ({\n timePickerInput: {\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n width: width || 300,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: 5,\n paddingRight: 10,\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\"\n },\n \"& * input\": {\n color: theme.colors.grey5,\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n borderRadius: \"5px\",\n height: 24,\n transition: \"0.0s !important\",\n },\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: 33,\n marginBottom: 1,\n position: \"absolute\",\n color: theme.colors.grey5,\n },\n },\n timePickerInputDisabled: {\n color: theme.colors.grey4,\n fontWeight: \"bold\",\n fontSize: 12,\n height: 40,\n width: width || 300,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n backgroundColor: \"#F6F6F6\",\n borderRadius: 5,\n paddingRight: 10,\n cursor: \"default !important\",\n \"& * .ant-picker-suffix, .ant-picker-clear\": {\n display: \"none\"\n },\n \"& * input\": {\n color: theme.colors.grey4 + \" !important\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n borderRadius: \"5px\",\n height: 24,\n transition: \"0.0s !important\",\n cursor: \"default !important\",\n },\n \"& div:after\": {\n content: \"'hrs'\",\n marginLeft: 33,\n marginBottom: 1,\n position: \"absolute\",\n color: theme.colors.grey4,\n cursor: \"default !important\",\n },\n },\n timePickerPopup: {\n zIndex: 2500\n },\n }),\n );\n\nexport default useStyles;","import React from \"react\";\n\nimport moment, { Moment } from \"moment\";\nimport { TimePicker } from \"antd\";\n\nimport useStyles from \"./css\";\nimport { TimeOfSendingProps } from \"./props\";\nimport { ClockIcon } from \"../../../../assets/icons\";\n\nexport default function TimeOfSending(props: TimeOfSendingProps) {\n\n const format = 'HH:mm';\n \n const { time, setTime, disabled, width } = props;\n const classes = useStyles(width)();\n\n const handleTimeChange = (value: Moment) => {\n setTime(value.format(format))\n }\n \n return (\n <div>\n <TimePicker\n key={`timeOfSending`}\n className={disabled ? classes.timePickerInputDisabled : classes.timePickerInput}\n popupClassName={classes.timePickerPopup}\n onOk={(time) => handleTimeChange(time)}\n inputReadOnly={true}\n showNow={false}\n value={moment(time, format)}\n defaultValue={moment(time, format)}\n disabled={disabled ?? false}\n format={format}\n />\n <ClockIcon\n style={{\n top: \"inherit\",\n right: 25,\n pointerEvents: \"none\",\n color: \"#919CA5\",\n position: \"relative\"\n }}\n />\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = (width?: number) =>\n makeStyles((theme) => ({\n root: {},\n label: {\n display: \"block\",\n color: \"#4a4d51\",\n fontFamily: \"Roboto\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n marginBottom: \"0.5rem\",\n },\n date: {\n display: \"flex\",\n justifyContent: \"space-between\",\n width: width || 370,\n },\n controlWithLabel: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\"\n },\n controlLabel: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n dateText: {\n ...theme.typography.txtBody2,\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n \"&::placeholder\": {\n fontWeight: \"normal\",\n color: \"#676767\",\n },\n }\n }));\n\nexport default useStyles;","import React, { useState, useEffect } from \"react\";\n\nimport { SelectItem } from \"../../../models/interfaces/select-item\";\nimport useStyles from \"./css\";\nimport { SelectMonthDayDateProps } from \"./props\";\nimport SelectKey from \"../SelectKey\";\nimport Typography from \"@material-ui/core/Typography\";\nimport DateInput from \"../DateInput\";\nimport { useTranslation } from \"react-i18next\";\n\nexport default function SelectMonthDayDate(props: SelectMonthDayDateProps) {\n \n const { date, setDate, width, minDate } = props;\n const { t } = useTranslation(\"massivesendings\")\n \n const newDate = new Date();\n const currentYear = newDate.getFullYear();\n const currentMonth = newDate.getMonth();\n const nextYear = newDate.getFullYear() + 1;\n \n const [innerDate, setInnerDate] = useState<Date>(date ?? minDate);\n const [month, setMonth] = useState<number>(innerDate.getMonth());\n const [minDayDate, setMinDayDate] = useState<Date>(getFirstDayOfMonthDate(date ?? minDate));\n const [maxDayDate, setMaxDayDate] = useState<Date>(getLastDayOfMonthDate(date ?? minDate));\n \n const classes = useStyles(width)();\n\n useEffect(() => {\n if (date !== innerDate) {\n const validDate = date ?? minDate;\n setInnerDate(validDate);\n setMonth(validDate.getMonth());\n setMinDayDate(getFirstDayOfMonthDate(validDate));\n setMaxDayDate(getLastDayOfMonthDate(validDate));\n }\n }, [date]);\n\n useEffect(() => {\n setDate(innerDate);\n }, [innerDate]);\n\n useEffect(() => {\n const year = getCorrectYear(innerDate);\n const day = innerDate.getDate();\n const newInnerDate = new Date(year, month || 0, day || 1);\n setInnerDate(newInnerDate);\n setMinDayDate(getFirstDayOfMonthDate(newInnerDate));\n setMaxDayDate(getLastDayOfMonthDate(newInnerDate));\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [month]);\n \n function getCorrectYear(date: Date) : number {\n const innerDateYear = date.getFullYear();\n if (innerDateYear > newDate.getFullYear()) {\n return innerDateYear;\n }\n if (month < currentMonth || (month == currentMonth && innerDate.getDate() <= newDate.getDate())) {\n return nextYear;\n }\n return currentYear;\n }\n \n function getFirstDayOfMonthDate(date: Date) : Date {\n const year = getCorrectYear(date);\n const month = date.getMonth();\n return new Date(year, month, 1);\n }\n\n function getLastDayOfMonthDate(date: Date) : Date {\n const year = getCorrectYear(date);\n const month = date.getMonth();\n return new Date(year, month + 1, 0);\n }\n\n const months: SelectItem[] = [\n { key: 0, value: t(\"January\") },\n { key: 1, value: t(\"February\") },\n { key: 2, value: t(\"March\") },\n { key: 3, value: t(\"April\") },\n { key: 4, value: t(\"May\") },\n { key: 5, value: t(\"June\") },\n { key: 6, value: t(\"July\") },\n { key: 7, value: t(\"August\") },\n { key: 8, value: t(\"September\") },\n { key: 9, value: t(\"October\") },\n { key: 10, value: t(\"November\") },\n { key: 11, value: t(\"December\") },\n ];\n \n const LabelWithDot = (props: any) => \n <div>\n <Typography className={classes.controlLabel}>\n {props.label}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n\n return (\n <div className={classes.root}>\n <div className={classes.date}>\n <div className={classes.controlWithLabel}>\n <LabelWithDot label={t(\"Month\")} />\n <SelectKey\n value={month}\n setValue={setMonth}\n items={months}\n width={200}\n itemHeight={32}\n />\n </div>\n <div className={classes.controlWithLabel}>\n <LabelWithDot label={t(\"Day\")} />\n <DateInput\n format=\"dd\"\n value={innerDate}\n onChange={setInnerDate}\n minDate={minDayDate}\n maxDate={maxDayDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={200}\n />\n </div>\n </div>\n </div>\n );\n};\n","import React, { useState, useRef } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport { Input, Popper } from \"@material-ui/core\";\nimport { useAppSelector } from \"../../../../redux/hooks\";\n\nimport InputWithLabel from \"../../../common/InputWithLabel\";\nimport useStyles from \"./css\";\nimport { MassiveSettingsGeneralSettingsProps } from \"./props\";\nimport ChipSelect from \"../../../common/ChipSelect\";\nimport IconTooltip from \"../../../common/IconTooltip\";\nimport { InfoIcon, MenuIcon } from \"../../../../assets/icons\";\nimport RadioWithText from \"../../../common/RadioWithText\";\nimport TerminationDate from \"../TerminationDate\";\nimport TimeOfSending from \"../TimeOfSending\";\nimport SelectKey from \"../../../common/SelectKey\";\nimport DateInput from \"../../../common/DateInput\";\nimport SelectMonthDayDate from \"../../../common/SelectMonthDayDate\";\nimport Switch from \"../../../common/Switch\";\nimport useCustomerTerminology from \"../../../../hooks/useCustomerTerminology\";\nimport MultiSelect, { MultiselectOverflowRenderType } from \"../../../common/MultiSelect\";\nimport MassiveSendingServiceModel from \"../../../../models/massive-sending-service-model\";\n\n\nexport default function MassiveSendingGeneralSettings(props: MassiveSettingsGeneralSettingsProps) {\n\n const {\n mode,\n massiveSending,\n setMassiveSending,\n sendingTypeNames,\n customerFrequencyTypes,\n customerGenders,\n services,\n birthdaySendingRules,\n existingMassiveSendingsNames\n } = props;\n const { t } = useTranslation(\"massivesendings\");\n\n const locale = useAppSelector(state => state.applicationInterface.locale);\n const dateFormatPlaceholder = locale === \"en\" ? \"mm/dd/yyyy\" : \"dd/mm/yyyy\";\n const dateFormat = locale === \"en\" ? \"MM/dd/yyyy\" : \"dd/MM/yyyy\";\n const newDate = new Date();\n const currentYear = newDate.getFullYear();\n const currentMonth = newDate.getMonth();\n const nextDay = newDate.getDate() + 1;\n const tomorrowDate = new Date(currentYear, currentMonth, nextDay);\n\n const classes = useStyles();\n\n const [isServicesTooltipOpen, setIsServicesTooltipOpen] = useState<boolean>(false);\n const anchorEl = useRef<HTMLDivElement | null>(null);\n\n const [startDateChanged, setStartDateChanged] = useState<boolean>(false);\n const [endDateChanged, setEndDateChanged] = useState<boolean>(false);\n\n const [nameChanged, setNameChanged] = useState<boolean>(false);\n\n const sendingTypeTooltips = [\n t(\"Send the message once\"),\n t(\"Send the message every year\"),\n t(\"Send the message according the birthday date\")\n ]\n\n function nameChangeHandler(event: any) {\n setNameChanged(true);\n const name = event.target.value;\n setMassiveSending({ ...massiveSending, name });\n }\n\n function setCustomerFrequency(customerFrequency: number) {\n setMassiveSending({ ...massiveSending, customerFrequency });\n }\n\n function setCustomerGender(customerGender: number) {\n setMassiveSending({ ...massiveSending, customerGender });\n }\n\n function setServices(newServiceIds: string[]) {\n const prospectedServices: MassiveSendingServiceModel[] = newServiceIds.map(serviceId => ({\n id: serviceId,\n name: services.find(service => service.key === serviceId)?.value || \"\",\n }));\n\n setMassiveSending({ ...massiveSending, prospectedServices });\n }\n\n function setProspectedServicesAppointmentStartDate(prospectedServicesAppointmentStartDate: Date | null) {\n setMassiveSending({ ...massiveSending, prospectedServicesAppointmentStartDate });\n }\n\n function setProspectedServicesAppointmentEndDate(prospectedServicesAppointmentEndDate: Date | null) {\n setMassiveSending({ ...massiveSending, prospectedServicesAppointmentEndDate });\n }\n\n function setTerminationDate(terminationDate: Date | null) {\n setMassiveSending({ ...massiveSending, terminationDate });\n }\n\n function setSendingDate(dateOfSending: Date | null) {\n setMassiveSending({ ...massiveSending, dateOfSending });\n }\n\n function setDateOfSingleOrAnnualSending(date: Date) {\n setSendingDate(date);\n }\n\n function setTimeOfSending(timeOfSending: string) {\n setMassiveSending({ ...massiveSending, timeOfSending });\n }\n\n function setBirthdaySendingType(value: number | null) {\n setMassiveSending({ ...massiveSending, birthdaySendingType: value });\n }\n\n function setSendImmediately(event: any) {\n setMassiveSending({ ...massiveSending, sendImmediately: event.target.checked });\n }\n\n function handleSingleSendingCheck() {\n setMassiveSending({\n ...massiveSending,\n type: 0,\n terminationDate: null,\n birthdaySendingType: null,\n dateOfSending: massiveSending.dateOfSending === null ? tomorrowDate : massiveSending.dateOfSending\n });\n }\n\n function handleYearlySendingCheck() {\n setMassiveSending({\n ...massiveSending,\n type: 1,\n birthdaySendingType: null,\n dateOfSending: massiveSending.dateOfSending === null ? tomorrowDate : massiveSending.dateOfSending\n });\n }\n\n function handleBirthdaySendingCheck() {\n setMassiveSending({\n ...massiveSending,\n type: 2,\n birthdaySendingType: massiveSending.birthdaySendingType === null ? 0 : massiveSending.birthdaySendingType,\n dateOfSending: null\n });\n }\n\n function handleSelectServices(newServices: any) {\n setServices(newServices);\n }\n\n function resetServices() {\n setServices([]);\n setStartDateChanged(false);\n setEndDateChanged(false);\n }\n\n function handleOpenPopper(event: React.MouseEvent<HTMLDivElement>) {\n if (massiveSending.prospectedServices.length > 0) {\n anchorEl.current = event.currentTarget;\n setIsServicesTooltipOpen(true);\n }\n }\n\n function handleClosePopper(event: React.MouseEvent<HTMLDivElement>) {\n anchorEl.current = null;\n setIsServicesTooltipOpen(false);\n }\n\n function validateProspectedServicesAppointmentEndDate(): boolean {\n if (massiveSending.prospectedServices.length === 0)\n return true;\n\n if (massiveSending.prospectedServicesAppointmentStartDate && !massiveSending.prospectedServicesAppointmentEndDate)\n return false;\n\n if (!endDateChanged)\n return true;\n\n if (massiveSending.prospectedServicesAppointmentStartDate &&\n massiveSending.prospectedServicesAppointmentEndDate &&\n (massiveSending.prospectedServicesAppointmentStartDate > massiveSending.prospectedServicesAppointmentEndDate))\n return false;\n\n if (!massiveSending.prospectedServicesAppointmentEndDate || massiveSending.prospectedServicesAppointmentEndDate.toString() === 'Invalid Date')\n return false;\n\n return true;\n }\n\n function validateProspectedServicesAppointmentStartDate(): boolean {\n if (massiveSending.prospectedServices.length === 0)\n return true;\n\n if (massiveSending.prospectedServicesAppointmentEndDate && !massiveSending.prospectedServicesAppointmentStartDate)\n return false;\n\n if (!startDateChanged)\n return true;\n\n if (massiveSending.prospectedServicesAppointmentStartDate &&\n massiveSending.prospectedServicesAppointmentEndDate &&\n (massiveSending.prospectedServicesAppointmentStartDate > massiveSending.prospectedServicesAppointmentEndDate))\n return false;\n\n if (!massiveSending.prospectedServicesAppointmentStartDate || massiveSending.prospectedServicesAppointmentStartDate.toString() === 'Invalid Date')\n return false;\n\n return true;\n }\n\n function validateName(): boolean {\n return !nameChanged || (massiveSending.name !== \"\" && !existingMassiveSendingsNames.includes(massiveSending.name));\n }\n\n return (\n <div className={classes.root}>\n <InputWithLabel\n label={() => (<>\n <Typography className={classes.label}>\n {t(\"Sending name\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </>)}\n placeholder={t(\"Enter the name of you new massive sending\")}\n value={massiveSending.name || \"\"}\n onChange={nameChangeHandler}\n isValid={validateName}\n width={700}\n onBlurInput={() => setNameChanged(true)}\n />\n <div className={classes.divider} />\n <div className={classes.customerTypes}>\n <div>\n <Typography className={classes.controlLabel}>\n {useCustomerTerminology(t(\"Type of customers to send\"), \"customers\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div className={classes.customerTypeSelectors}>\n <div className={classes.customerTypeSelector}>\n <ChipSelect\n items={customerFrequencyTypes}\n item={massiveSending.customerFrequency}\n setItem={setCustomerFrequency}\n />\n </div>\n <div className={classes.customerTypeSelector}>\n <ChipSelect\n items={customerGenders}\n item={massiveSending.customerGender}\n setItem={setCustomerGender}\n />\n </div>\n </div>\n </div>\n <div className={classes.dividerCustomersServices} />\n <div className={classes.services}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Service to prospect\")}\n </Typography>\n </div>\n\n <Popper\n open={isServicesTooltipOpen && massiveSending.prospectedServices.length > 0}\n anchorEl={anchorEl.current}\n placement={\"left\"}\n className={classes.tooltipBlockServices}\n disablePortal\n >\n <div ref={anchorEl} />\n <div>\n {massiveSending.prospectedServices\n .map(service => service.name)\n .join(\", \")\n }\n </div>\n </Popper>\n\n <div\n className={classes.servicesSelector}\n onMouseEnter={handleOpenPopper}\n onMouseLeave={handleClosePopper}\n >\n <MultiSelect\n allItemsPlaceholder={t(\"None\")}\n filterPlaceholder={t(\"Search service\")}\n items={services}\n sort={true}\n values={massiveSending.prospectedServices.map(s => s.id)}\n input={<Input startAdornment={\n <div className={classes.servicesInputIcon}>\n <MenuIcon />\n </div>}\n />}\n classes={{ root: `${classes.selected}` }}\n styleClass={classes.multiSelect}\n width={150}\n height={210}\n onChange={handleSelectServices}\n onReset={resetServices}\n overflowRenderType={MultiselectOverflowRenderType.Dots}\n overflowRenderCap={51}\n showSearch={true}\n showIconComponent={false}\n onOpen={() => setIsServicesTooltipOpen(false)}\n />\n </div>\n\n <div className={classes.servicesDates}>\n <div className={classes.controlRow}>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={\n massiveSending.prospectedServices.length > 0\n ? classes.controlLabel\n : classes.disabledControlLabel\n }>\n {t(\"Start date\")}\n </Typography>\n <span className={classes.dot}>*</span>\n <IconTooltip\n key={\"gapFromSiteTooltip\"}\n classNameRoot={classes.iconTooltip}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"Start date of the period for scheduled appointments with the selected services.\")}\n />\n </div>\n <DateInput\n placeholder={dateFormatPlaceholder}\n format={dateFormat}\n value={massiveSending.prospectedServicesAppointmentStartDate}\n onChange={setProspectedServicesAppointmentStartDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={300}\n disabled={massiveSending.prospectedServices.length < 1}\n isValid={validateProspectedServicesAppointmentStartDate}\n allowManualInput={true}\n onBlur={() => setStartDateChanged(true)}\n />\n </div>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={\n massiveSending.prospectedServices.length > 0\n ? classes.controlLabel\n : classes.disabledControlLabel\n }>\n {t(\"End date\")}\n </Typography>\n <span className={classes.dot}>*</span>\n <IconTooltip\n key={\"gapFromSiteTooltip\"}\n classNameRoot={classes.iconTooltip}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"End date of the period for scheduled appointments with the selected services.\")}\n />\n </div>\n <DateInput\n placeholder={dateFormatPlaceholder}\n format={dateFormat}\n value={massiveSending.prospectedServicesAppointmentEndDate}\n minDate={massiveSending.prospectedServicesAppointmentStartDate || new Date()}\n onChange={setProspectedServicesAppointmentEndDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={300}\n disabled={massiveSending.prospectedServices.length < 1}\n isValid={validateProspectedServicesAppointmentEndDate}\n allowManualInput={true}\n onBlur={() => setEndDateChanged(true)}\n />\n </div>\n </div>\n </div>\n\n </div>\n <div className={classes.divider} />\n <div>\n {\n mode === \"new\"\n ?\n <div>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Sending type\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div className={classes.radios}>\n <div className={classes.radio}>\n <RadioWithText\n value={0}\n checked={massiveSending.type === 0}\n onCheck={handleSingleSendingCheck}\n text={sendingTypeNames[0]}\n />\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={sendingTypeTooltips[0]}\n />\n </div>\n <div className={classes.radio}>\n <RadioWithText\n value={1}\n checked={massiveSending.type === 1}\n onCheck={handleYearlySendingCheck}\n text={sendingTypeNames[1]}\n />\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={sendingTypeTooltips[1]}\n />\n </div>\n <div className={classes.radio}>\n <RadioWithText\n value={2}\n checked={massiveSending.type === 2}\n onCheck={handleBirthdaySendingCheck}\n text={sendingTypeNames[2]}\n />\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={sendingTypeTooltips[2]}\n />\n </div>\n </div>\n </div>\n :\n <div className={classes.sendingTypes}>\n <span className={classes.sendingTypeEditText}>{t(\"Sending type\") + \" |\"}</span>\n <span className={classes.sendingTypeName}>{sendingTypeNames[massiveSending.type]}</span>\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={sendingTypeTooltips[massiveSending.type]}\n />\n </div>\n }\n\n {\n massiveSending.type === 0 &&\n <div className={classes.singleSendingSettings}>\n <div className={classes.controlRow}>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Date of sending\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <DateInput\n placeholder={t(\"dd/mm/yy\")}\n format={\"dd/MMMM/yyyy\"}\n value={massiveSending.dateOfSending}\n onChange={setDateOfSingleOrAnnualSending}\n minDate={tomorrowDate}\n inputTextClass={classes.dateText}\n iconColor={\"#919CA5\"}\n width={300}\n disabled={massiveSending.sendImmediately}\n />\n </div>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Time of sending\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <TimeOfSending\n time={massiveSending.timeOfSending}\n setTime={setTimeOfSending}\n disabled={massiveSending.sendImmediately}\n />\n </div>\n </div>\n <div className={classes.controlRowSwitch}>\n <Switch\n value={massiveSending.sendImmediately ?? false}\n onChange={setSendImmediately}\n baseClass={classes.switchBase} />\n <Typography className={`${classes.switchLabel} ${massiveSending.sendImmediately ? classes.switchLabelActive : null}`}>\n {t(\"Send right now\")}\n </Typography>\n <IconTooltip\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 5 }} viewBox={\"0 0 12 12\"} />}\n tooltipText={t(\"The sending will be made at the end of the massive sending creation\")}\n />\n </div>\n </div>\n }\n\n {\n massiveSending.type === 1 &&\n <div className={classes.annualSendingSettings}>\n <div className={classes.annualControlRow}>\n <SelectMonthDayDate\n date={massiveSending.dateOfSending}\n setDate={setDateOfSingleOrAnnualSending}\n minDate={tomorrowDate}\n width={430}\n />\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Time of sending\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <TimeOfSending\n time={massiveSending.timeOfSending}\n setTime={setTimeOfSending}\n width={200}\n />\n </div>\n </div>\n <div className={classes.controlRow}>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Termination of sending\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div style={{ marginLeft: -5 }}>\n <TerminationDate\n date={massiveSending.terminationDate}\n setDate={setTerminationDate}\n nullText={t(\"Never ends\")}\n minDate={tomorrowDate}\n />\n </div>\n </div>\n </div>\n </div>\n }\n {\n massiveSending.type === 2 &&\n <div className={classes.birthdaySettings}>\n <div className={classes.controlRow}>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Sending rules\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <SelectKey\n value={massiveSending.birthdaySendingType}\n setValue={setBirthdaySendingType}\n name={\"birthdaySendingType\"}\n items={birthdaySendingRules}\n width={300}\n />\n </div>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Time of sending\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <TimeOfSending\n time={massiveSending.timeOfSending}\n setTime={setTimeOfSending}\n />\n </div>\n </div>\n <div className={classes.inputWithLabel}>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Termination of sending\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div style={{ marginLeft: -5 }}>\n <TerminationDate\n date={massiveSending.terminationDate}\n setDate={setTerminationDate}\n nullText={t(\"Never ends\")}\n minDate={tomorrowDate}\n />\n </div>\n </div>\n\n </div>\n }\n </div>\n </div >\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n labelAlternativeLabel: {\n ...theme.typography.txtBody2,\n color: `${theme.colors.grey4} !important`,\n \"& .MuiStepLabel-active\": {\n color: `${theme.colors.clearMain} !important`\n }\n },\n labelCompleted: {\n color: `${theme.colors.clearGreen} !important`\n },\n })\n);\n\nexport const useStepIconStyles = makeStyles((theme) => ({\n root: {\n color: theme.colors.grey2,\n display: 'flex',\n height: 22,\n alignItems: 'center',\n },\n circle: {\n width: 14,\n height: 14,\n borderRadius: '50%',\n border: `1px solid ${theme.colors.grey2}`\n },\n activeCircle: {\n width: 14,\n height: 14,\n borderRadius: '50%',\n border: `1px solid ${theme.colors.clearMain}`,\n backgroundColor: theme.colors.clearMain\n },\n completed: {\n color: theme.colors.clearGreen,\n zIndex: 1,\n fontSize: 22,\n fontWeight: \"bold\"\n }})\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { Step, StepConnector, StepLabel, Stepper, withStyles } from \"@material-ui/core\";\nimport { Check } from \"@material-ui/icons\";\n\nimport { CustomStepperProps } from \"../../../../models/interfaces/custom-stepper-props\";\nimport useStyles, { useStepIconStyles } from \"./css\";\n\nexport default function MassiveSendingStepper(props: CustomStepperProps) {\n\n const classes = useStyles();\n const { t } = useTranslation(\"massivesendings\");\n const { activeStep } = props;\n\n const StyledStepperConnector = withStyles((theme) => ({\n alternativeLabel: {\n top: 10,\n left: 'calc(-50% + 16px)',\n right: 'calc(50% + 16px)',\n },\n active: {\n '& $line': {\n borderColor: theme.colors.clearGreen,\n },\n },\n completed: {\n '& $line': {\n borderColor: theme.colors.clearGreen,\n },\n },\n line: {\n borderColor: theme.colors.grey2,\n borderTopWidth: 1,\n borderRadius: 1,\n },\n }))(StepConnector);\n\n function StepIcon(props: any) {\n const classes = useStepIconStyles();\n const { active, completed } = props;\n\n return (\n <div\n className={classes.root}\n >\n {completed ? <Check className={classes.completed} /> : active ? <div className={classes.activeCircle} /> : <div className={classes.circle} />}\n </div>\n );\n }\n \n return (\n <Stepper\n alternativeLabel\n activeStep={activeStep}\n connector={<StyledStepperConnector />}\n >\n <Step key={0}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"Sending rules\")}\n </StepLabel>\n </Step>\n <Step key={1}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"WhatsApp template\")}\n </StepLabel>\n </Step>\n <Step key={2}>\n <StepLabel\n StepIconComponent={StepIcon}\n classes={{\n alternativeLabel: classes.labelAlternativeLabel,\n completed: classes.labelCompleted\n }}\n >\n {t(\"Preview\")}\n </StepLabel>\n </Step>\n </Stepper>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {},\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n position: \"relative\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 472,\n height: 153,\n },\n content: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\"\n },\n modalTitle: {\n ...theme.typography.h4,\n fontFamily: \"Inter\",\n fontWeight: \"bold\",\n color: \"#26292B\",\n marginTop: 40,\n marginBottom: 40,\n justifySelf: \"center\"\n },\n modalFooter: {\n display: \"flex\",\n justifyContent: \"space-evenly\",\n },\n goBackButton: {\n marginRight: 16,\n background: theme.colors.grey1,\n color: theme.colors.grey3,\n },\n cancelButton: {\n background: theme.colors.clearGreen,\n color: \"#FFFFFF\",\n \"&:hover\": {\n background: theme.colors.clearGreen,\n },\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport Fade from \"@material-ui/core/Fade\";\nimport Typography from \"@material-ui/core/Typography\";\nimport Modal from \"@material-ui/core/Modal\";\nimport Button from \"@material-ui/core/Button\";\n\nimport useStyles from \"./css\";\nimport { CancelModalProps } from \"./props\";\n\n\nexport default function CancelModal(props: CancelModalProps) {\n\n const { open, setOpen, onSubmit, title } = props;\n\n const classes = useStyles();\n const { t } = useTranslation(\"settings\");\n\n const handleCloseModal = () => {\n setOpen(false);\n };\n\n const handleSubmit = () => {\n onSubmit();\n handleCloseModal();\n }\n\n const GoBackButton = () =>\n <Button\n className={`${classes.button} ${classes.goBackButton}`}\n onClick={handleCloseModal}\n >\n {t(\"Go back\")}\n </Button>\n\n const CancelButton = () =>\n <Button\n className={`${classes.button} ${classes.cancelButton}`}\n onClick={handleSubmit}\n >\n {t(\"Cancel\")}\n </Button>\n\n return (\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={open}\n onClose={handleCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n >\n <Fade in={open}>\n <div className={classes.paper}>\n <div className={classes.content}>\n <Typography className={classes.modalTitle}>\n {title}\n </Typography>\n <div className={classes.modalFooter}>\n <GoBackButton />\n <CancelButton />\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\"\n },\n label: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n margin: 0,\n marginBottom: 5\n },\n inputWithLabel: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"flex-start\",\n },\n controlLabel: {\n ...theme.typography.txtBody2,\n fontFamily: \"Inter, sans-serif\",\n fontWeight: \"bold\",\n display: \"inline-flex\",\n color: theme.colors.grey4,\n marginBottom: 8\n },\n dot: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n marginLeft: 5\n },\n divider: {\n width: 731,\n marginTop: 24,\n marginBottom: 24,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey1\n },\n radios: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\"\n },\n radio: {\n width: 150,\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"flex-start\",\n alignItems: \"center\"\n },\n imageBlock: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n alignItems: \"flex-start\"\n },\n imageBlockNotes: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n marginLeft: 24,\n\n ...theme.typography.txtBody2,\n color: theme.colors.grey5\n },\n uploadedImage: {\n width: 250,\n height: 120,\n backgroundColor: \"#FFF\",\n borderRadius: 15,\n backgroundRepeat: \"no-repeat\",\n backgroundSize: \"cover\",\n backgroundPosition: \"center top\",\n },\n emptyImage: {\n width: 250,\n height: 120,\n backgroundColor: \"rgba(100, 98, 243, 0.1)\",\n borderRadius: 15,\n border: \"1px dashed\",\n borderColor: theme.colors.clearMain,\n cursor: \"pointer\",\n },\n plusIcon: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: theme.colors.clearMain\n },\n addImageLabel: {\n marginTop: 3,\n fontSize: 12,\n textAlign: \"center\",\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: 700\n },\n labelAddPhotoIns: {\n marginTop: 3,\n ...theme.typography.caption2,\n color: theme.colors.clearMain,\n textAlign: \"center\",\n },\n textBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"space-evenly\",\n alignItems: \"flex-start\",\n\n height: 304,\n padding: \"16px 29px 16px 16px\",\n backgroundColor: theme.colors.grey1,\n\n border: \"1px solid\",\n borderColor: theme.colors.grey2,\n borderRadius: 14,\n\n ...theme.typography.txtBody1,\n color: theme.colors.grey3,\n },\n goToSiteButton: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n paddingTop: 7\n },\n goToSiteButtonInnerContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n color: theme.colors.grey2,\n fontWeight: 700,\n\n width: 680,\n height: 32,\n border: \"1px solid\",\n borderColor: theme.colors.grey2,\n borderRadius: 5,\n },\n goToSiteIcon: {\n marginRight: 4\n },\n tinyMceOverrides: {\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n position: \"relative\",\n padding: \"15px 0px 15px 0px\"\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n tinyMceInvalid: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: Color.red +\" !important\"\n }\n },\n charCounter: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"10px\",\n lineHeight: \"12px\",\n position: \"absolute\",\n paddingLeft: \"629px\",\n marginTop: \"-18px\",\n color: theme.colors.grey5\n },\n charCounterInvalid: {\n color: theme.colors.clearRed\n },\n urlWarning: {\n position: \"absolute\",\n paddingLeft: \"656px\",\n marginTop: \"-198px\",\n }\n})\n);\n\nexport default useStyles;","export enum MassiveSendingContentType {\n Text = 0,\n ImageAndText\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport { Editor } from \"@tinymce/tinymce-react\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport { MassiveSendingMessageSettingsProps } from \"./props\";\nimport useStyles from \"./css\";\nimport RadioWithText from \"../../../common/RadioWithText\";\nimport { MassiveSendingContentType } from \"../../../../models/enums/massive-sending-content-type\";\nimport { ExportIcon, PlusIcon, WarningIcon } from \"../../../../assets/icons\";\nimport ImageDropzone from \"../../../common/ImageDropzone\";\nimport { MassiveSendingUrlRegex } from \"../../../../constants/validator\";\nimport IconTooltip from \"../../../common/IconTooltip\";\nimport useCustomerTerminology from \"../../../../hooks/useCustomerTerminology\";\n\n\nexport default function MassiveSendingMessageSettings(props: MassiveSendingMessageSettingsProps) {\n\n const classes = useStyles();\n const { t } = useTranslation(\"massivesendings\");\n\n const validMimeTypes = [\"jpg\", \"jpeg\", \"png\"];\n const massiveSendingTemplates = [t(\"single_sending_template\"), t(\"annual_sending_template\"), t(\"birthday_sending_template\")]\n const maxFileSize: number = 800 * 1024; //800KB\n const greetingMessage = <span>{t(\"Hello\")} <b>{useCustomerTerminology(t(\"[Customer name]\"), \"[Customer name]\")}</b>,</span>;\n const scheduleAppointments = t(\"To schedule your appointment on our Site for appointments click on the following button.\");\n const goToSite = t(\"GO TO APPT SITE\");\n\n const { massiveSending, setMassiveSending, textLength, setTextLength, maxTextLength, textContainsUrl, setTextContainsUrl } = props;\n const [focused, setFocused] = useState<boolean>(false);\n\n function getTextInitialValue(): string {\n if (massiveSending.text === \"\" || massiveSendingTemplates.indexOf(massiveSending.text) !== -1) {\n return massiveSendingTemplates[massiveSending.type];\n }\n return massiveSending.text;\n }\n\n useEffect(() => {\n setMassiveSendingText(\"\"); //need to initialize text length of default template message\n setMassiveSendingText(getTextInitialValue())\n }, [])\n\n function setMassiveSendingText(text: string) {\n setMassiveSending({ ...massiveSending, text });\n }\n\n function setMassiveSendingContentType(contentType: MassiveSendingContentType) {\n setMassiveSending({ ...massiveSending, contentType });\n }\n\n function setMassiveSendingImage(image: File, imageUrl: string) {\n setMassiveSending({ ...massiveSending, image, imageUrl });\n }\n\n function handleTextTypeCheck() {\n setMassiveSendingContentType(MassiveSendingContentType.Text)\n }\n\n function handleImageAndTextTypeCheck() {\n setMassiveSendingContentType(MassiveSendingContentType.ImageAndText);\n }\n\n const validateFile = (file: File) => {\n if (validMimeTypes.indexOf(file.name.split('.').pop()!) === -1) {\n return false;\n }\n return file.size < maxFileSize;\n }\n\n const handleFileUpload = (file: File) => {\n const fileIsInvalid = validateFile(file);\n if (!fileIsInvalid) return;\n\n const imageUrl = URL.createObjectURL(file);\n setMassiveSendingImage(file, imageUrl);\n }\n\n const setLength = (evt: any, editor: any) => {\n setTextLength(editor.getContent({ format: \"text\" }).length);\n };\n\n const handleEditorChange = (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n\n let newText: string;\n newText = contentText.replace(/\\r?\\n|\\r/g, \" \"); //Removing line breaks\n newText = newText.replace(/\\s{3,}/g, \" \"); //Removing 3+ whitespaces\n newText = newText.replace(/[•\\t]/g, \"\"); //Removing bullet points\n\n let newHtml: string;\n newHtml = contentHtml.replace(/\\r?\\n|\\r/g, \" \"); //Removing line breaks\n newHtml = newHtml.replace(/\\s{3,}/g, \" \"); //Removing 3+ whitespaces\n newHtml = newHtml.replace(/[•\\t]/g, \"\"); //Removing bullet points\n\n setMassiveSendingText(newHtml)\n setTextLength(newText.length);\n\n setTextContainsUrl(newText.search(MassiveSendingUrlRegex) !== -1)\n }\n\n const EmptyImageComponent: React.FC = () => {\n return (\n <>\n <div className={classes.plusIcon}>\n <PlusIcon style={{ color: \"#6462F3\" }} />\n </div>\n <div className={classes.addImageLabel}>\n {t(\"Add image\")}\n </div>\n <div className={classes.labelAddPhotoIns}>\n {t(\"Recommended size\") + \": 430px x 240px\"}\n </div>\n </>\n );\n };\n\n return (\n <div className={classes.root}>\n <div className={classes.radios}>\n <div>\n <RadioWithText\n value={MassiveSendingContentType.Text}\n checked={massiveSending.contentType === MassiveSendingContentType.Text}\n onCheck={handleTextTypeCheck}\n text={t(\"Text\")}\n />\n </div>\n <div>\n <RadioWithText\n value={MassiveSendingContentType.ImageAndText}\n checked={massiveSending.contentType === MassiveSendingContentType.ImageAndText}\n onCheck={handleImageAndTextTypeCheck}\n text={t(\"Image and text\")}\n />\n </div>\n </div>\n <div className={classes.divider} />\n {massiveSending.contentType === MassiveSendingContentType.ImageAndText &&\n <div>\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Template image\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div className={classes.imageBlock}>\n <ImageDropzone\n key={\"massive-sending-image\"}\n imageUrl={massiveSending.imageUrl}\n emptyFileComponent={<EmptyImageComponent />}\n onChange={handleFileUpload}\n validationFunction={validateFile}\n invalidImageTitleModal={t(\"It is not possible to upload the selected image\")}\n invalidImageBodyModal={t(\"We suggest you use an image with a maximum weight of 800kb\")}\n dropzoneClass={massiveSending.imageUrl ? classes.uploadedImage : classes.emptyImage}\n />\n <div className={classes.imageBlockNotes}>\n <span><b>{t(\"Notes\") + \":\"}</b></span>\n <span>{t(\"This image will be sent to the customer by WhatsApp message. Allowed formats for the image: \")}<b>{t(\".png or .jpg\")}</b></span>\n </div>\n </div>\n <div className={classes.divider} />\n </div>\n }\n <div>\n <Typography className={classes.controlLabel}>\n {t(\"Template text\")}\n </Typography>\n <span className={classes.dot}>*</span>\n </div>\n <div className={classes.textBlock}>\n <span>{greetingMessage}</span>\n <div className={`\n ${classes.tinyMceOverrides} \n ${textContainsUrl || textLength > maxTextLength\n ? classes.tinyMceInvalid\n : (focused\n ? classes.tinyMceFocused\n : classes.tinyMceUnfocused)}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: 680,\n menubar: false,\n statusbar: false,\n plugins: 'wordcount paste',\n toolbar: 'bold italic strikethrough | styleselect ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n strikethrough: { inline: 's' }\n },\n paste_as_text: true,\n paste_preprocess: (plugin: any, args: any) => {\n let newText: string;\n newText = args.content.replace(/(<|<)\\s*br\\s*\\/*(>|>)/g, \" \"); //Removing br tags\n newText = newText.replace(/(<|<)\\s*\\/?\\s*p[^>]*(>|>)/g, \"\"); //Removing p tags\n newText = newText.replace(/\\r?\\n|\\r/g, \" \"); //Removing other line breaks\n newText = newText.replace(/\\s{3,}/g, \" \"); //Removing 3+ whitespaces\n newText = newText.replace(/[•\\t]/g, \"\"); //Removing bullet points and tabs\n args.content = newText;\n },\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\",\n remove_linebreaks: true,\n setup: (editor) => {\n editor.on(\"init\", (e) => {\n editor.focus();\n editor.selection.select(editor.getBody(), true);\n editor.selection.collapse(false);\n });\n editor.on(\"keydown\", (e) => {\n if (e.key === \"Enter\" || e.key === \"Tab\") {\n e.preventDefault();\n e.stopPropagation();\n return false;\n }\n //without the next block, the cursor will lose its position immediately after the text becomes invalid\n if (textContainsUrl) {\n editor.focus();\n editor.selection.select(editor.getBody(), true);\n editor.selection.collapse(false);\n }\n });\n }\n }}\n value={massiveSending.text}\n onFocusIn={() => setFocused(true)}\n onFocusOut={() => setFocused(false)}\n onInit={setLength}\n onEditorChange={handleEditorChange}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLength >= maxTextLength) {\n e.preventDefault();\n }\n }}\n />\n {textContainsUrl\n ? <div className={classes.urlWarning}>\n <IconTooltip\n key={\"urlWarningTooltip\"}\n placement={\"right\"}\n icon={<WarningIcon />}\n tooltipText={t(\"The message must not contain links. We suggest you modify it.\")}\n arrowPlacement={\"right\"}\n />\n </div>\n : <></>}\n <span className={`${classes.charCounter} ${textLength > maxTextLength ? classes.charCounterInvalid : \"\"}`}>{textLength + \"/\" + maxTextLength}</span>\n </div>\n <span>{scheduleAppointments}</span>\n <div className={classes.goToSiteButton}>\n <div className={classes.goToSiteButtonInnerContainer}>\n <div className={classes.goToSiteIcon}>\n <ExportIcon />\n </div>\n {goToSite}\n </div>\n </div>\n </div>\n </div>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n },\n header: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4,\n \n marginTop: 16,\n marginBottom: 16\n },\n blocks: {\n width: \"100%\",\n display: \"flex\",\n justifyContent: \"space-between\",\n },\n valuesBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n padding: 16,\n minWidth: 362\n },\n value: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n marginBottom: 16\n },\n valueLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n valueText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey6\n },\n divider: {\n width: \"100%\",\n marginTop: 20,\n marginBottom: 20,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey1\n },\n previewBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: 5,\n padding: 24,\n backgroundPosition: \"center\",\n minWidth: 346\n },\n messageBlock: {\n width: 285,\n backgroundColor: \"#FFFFFF\",\n borderRadius: \"0 5px 5px 5px\",\n padding: 8,\n position: \"relative\"\n },\n imageBlock: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n width: \"max-content\",\n maxWidth: 269,\n height: \"max-content\",\n maxHeight: 152,\n marginBottom: 16\n },\n image: {\n width: 269,\n height: 152,\n objectFit: \"cover\",\n objectPosition: \"center\",\n borderRadius: 15\n },\n text: {\n width: 269,\n \n ...theme.typography.txtBody2,\n color: theme.colors.grey6,\n paddingBottom: 12,\n wordBreak: \"break-word\"\n },\n arrow: {\n position: \"absolute\",\n top: 0,\n left: -11\n },\n timeBlock: {\n position: \"absolute\",\n bottom: 8,\n right: 8,\n \n ...theme.typography.caption1,\n color: theme.colors.grey5\n },\n goToSiteButton: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n width: 285,\n backgroundColor: \"#FFFFFF\",\n borderRadius: 5,\n marginTop: 3\n },\n goToSiteButtonInnerContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n color: theme.colors.clearBlue,\n fontWeight: 700,\n\n width: 677,\n height: 32,\n borderRadius: 5,\n },\n goToSiteIcon: {\n margin: \"0px 5px 4px 0px\"\n },\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport Interweave from \"interweave\";\nimport moment from \"moment\";\n\nimport { MassiveSendingPreviewProps } from \"./props\";\nimport useStyles from \"./css\";\nimport WhatsappBackground from \"../../../../assets/images/whatsapp-background.jpg\"\nimport { ExportIcon, SideArrowForMessageIcon } from \"../../../../assets/icons\";\nimport useCustomerTerminology from \"../../../../hooks/useCustomerTerminology\";\n\n\nexport default function MassiveSendingPreview(props: MassiveSendingPreviewProps) {\n\n const { massiveSending, customerFrequencyTypes, sendingTypeNames, customerGenders, birthdaySendingRules } = props;\n const { t } = useTranslation(\"massivesendings\");\n const classes = useStyles();\n\n const greetingMessage = <span>{t(\"Hello\")} <b>{useCustomerTerminology(t(\"[Customer name]\"), \"[Customer name]\")}</b>,</span>;\n const scheduleAppointments = t(\"To schedule your appointment on our Site for appointments click on the following button.\");\n const goToSite = t(\"GO TO APPT SITE\");\n const sendingCustomerGender = customerGenders.find(x => x.key == massiveSending.customerGender)!.value;\n const sendingCustomerFrequencyType = customerFrequencyTypes.find(x => x.key == massiveSending.customerFrequency)!.value;\n const sendingBirthdaySendingRules = massiveSending.birthdaySendingType === null ? \"\" : birthdaySendingRules.find(x => x.key == massiveSending.birthdaySendingType)!.value;\n\n const sendingRules = [\n `${formattedDate(massiveSending.dateOfSending!)} - ${formattedTime(massiveSending.timeOfSending)}`,\n `${formattedDate(massiveSending.dateOfSending!)} - ${formattedTime(massiveSending.timeOfSending)}`,\n `${sendingBirthdaySendingRules} - ${formattedTime(massiveSending.timeOfSending)}`\n ];\n \n function formattedDate(date: Date) : string {\n return `${moment(date).format(\"DD\")}/${t(moment(date).format(\"MMMM\"))}/${moment(date).format(\"yyyy\")}`;\n }\n \n function formattedTime(time: string) : string {\n return `${time}hrs`;\n }\n \n interface ValueBlockProps {\n label: string;\n value: string;\n }\n \n function ValueBlock(props: ValueBlockProps) {\n return (\n <div className={classes.value}>\n <div className={classes.valueLabel}>{props.label}</div>\n <div className={classes.valueText}>{props.value}</div>\n </div>\n )\n }\n \n return (\n <div className={classes.root}>\n <div className={classes.header}>{t(\"Verify that all the data of your massive sending are correct\")}</div>\n <div className={classes.blocks}>\n <div className={classes.valuesBlock}>\n \n <ValueBlock label={t(\"Name of the sending\")} value={massiveSending.name} />\n <ValueBlock label={useCustomerTerminology(t(\"Type of customers to send\"), \"customers\")} value={`${sendingCustomerFrequencyType} / ${sendingCustomerGender}`} />\n \n <div className={classes.divider} />\n \n <ValueBlock label={t(\"Sending type\")} value={sendingTypeNames[massiveSending.type]} />\n <ValueBlock label={t(\"Sending rules\")} value={sendingRules[massiveSending.type]} />\n \n <div className={classes.divider} />\n {\n (massiveSending.type === 1 || massiveSending.type === 2) && \n <ValueBlock label={t(\"Termination of sending\")} value={massiveSending.terminationDate === null\n ? t(\"Never ends\")\n : formattedDate(massiveSending.terminationDate)} \n />\n }\n </div>\n <div className={classes.previewBlock} style={{ backgroundImage: `url(${WhatsappBackground})` }}>\n <div className={classes.messageBlock}>\n {\n massiveSending.imageUrl && massiveSending.contentType === 1 && \n <div className={classes.imageBlock}>\n <img src={massiveSending.imageUrl} alt=\"image\" className={classes.image} />\n </div>\n }\n <div className={classes.text}>\n <span>{greetingMessage}</span>\n <p></p>\n <Interweave content={massiveSending.text} />\n <span>{scheduleAppointments}</span>\n </div>\n \n <SideArrowForMessageIcon className={classes.arrow} />\n <div className={classes.timeBlock}>\n {formattedTime(massiveSending.timeOfSending)}\n </div>\n </div>\n <div className={classes.goToSiteButton}>\n <div className={classes.goToSiteButtonInnerContainer}>\n <div className={classes.goToSiteIcon}>\n <ExportIcon color={\"#0BCBE0\"} />\n </div>\n {goToSite}\n </div>\n </div>\n </div>\n </div>\n </div>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport { Dialog, DialogContent, DialogTitle, Fade, Tab, Tabs } from \"@material-ui/core\";\n\nimport { MassiveSendingModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport MassiveSendingGeneralSettings from \"../MassiveSendingGeneralSettings\";\nimport MassiveSendingStepper from \"../MassiveSendingStepper\";\nimport { TabContext, TabPanel } from \"@material-ui/lab\";\nimport { MassiveSendingEntity } from \"../../../../models/massive-sending-entity\";\nimport CancelModal from \"../../../common/CancelModal\";\nimport MassiveSendingMessageSettings from \"../MassiveSendingMessageSettings\";\nimport MassiveSendingPreview from \"../MassiveSendingPreview\";\nimport { MassiveSendingContentType } from \"../../../../models/enums/massive-sending-content-type\";\nimport useCustomerTerminology from \"../../../../hooks/useCustomerTerminology\";\n\n\nexport default function MassiveSendingModal(props: MassiveSendingModalProps) {\n\n const {\n open,\n setOpen,\n onClose,\n onCreate,\n mode,\n itemId,\n massiveSending,\n services,\n setMassiveSending,\n oldMassiveSending,\n existingMassiveSendingsNames\n } = props;\n\n const [cancelModalOpen, setCancelModalOpen] = useState<boolean>(false);\n const [activeStep, setActiveStep] = useState<number>(0);\n const [activeTab, setActiveTab] = useState<\"first\" | \"second\" | \"third\">(\"first\");\n const [firstStepCompleted, setFirstStepCompleted] = useState<boolean>(false);\n const [secondStepCompleted, setSecondStepCompleted] = useState<boolean>(false);\n\n const [textLength, setTextLength] = useState<number>(0);\n const maxTextLength: number = 900;\n const [textContainsUrl, setTextContainsUrl] = useState<boolean>(false);\n\n const { t } = useTranslation(\"massivesendings\");\n const classes = useStyles();\n\n useEffect(() => {\n async function duplicateMassiveSending() {\n const duplicatedSending = { ...massiveSending, id: null, name: \"\" };\n setMassiveSending(duplicatedSending);\n }\n\n if (mode === \"new\" && itemId) {\n duplicateMassiveSending()\n }\n }, [mode, itemId]);\n\n const sendingTypeNames = [\n t(\"SingleSending\"),\n t(\"Annual sending\"),\n t(\"Birthdays\")\n ]\n\n const servicesValues = [\n ...services\n .map((service) => ({\n key: service.id, \n value: service.name \n }))\n ];\n\n const customerFrequencyTypes = [\n { key: 0, value: useCustomerTerminology(t(\"All customers\"), \"customers\") },\n { key: 1, value: useCustomerTerminology(t(\"Frequent customers\"), \"Frequent customers\") },\n { key: 2, value: useCustomerTerminology(t(\"Infrequent customers\"), \"Infrequent customers\") },\n { key: 3, value: useCustomerTerminology(t(\"Inactive customers\"), \"Inactive customers\") }\n ];\n\n const customerGenders = [\n { key: 0, value: t(\"AllGenders\") },\n { key: 256, value: t(\"MaleAndFemale\") },\n { key: 1, value: t(\"Male\") },\n { key: 2, value: t(\"Female\") },\n { key: 3, value: t(\"PreferNotToSay\") },\n { key: 4, value: t(\"Custom\") },\n ];\n\n const birthdaySendingRules = [\n { key: 0, value: t(\"Same day of the birthday\") },\n { key: 1, value: t(\"One day before the birthday\") },\n { key: 2, value: t(\"One week before the birthday\") },\n { key: 3, value: t(\"Two weeks before the birthday\") },\n { key: 4, value: t(\"One month before the birthday\") },\n ];\n\n const handleTabChange = (event: any, newValue: \"first\" | \"second\" | \"third\") => {\n setActiveTab(newValue);\n };\n\n function resetForm() {\n setMassiveSending(new MassiveSendingEntity());\n setActiveStep(0);\n setActiveTab(\"first\");\n setFirstStepCompleted(false);\n setSecondStepCompleted(false);\n }\n\n function handleCloseModal() {\n setOpen(false);\n resetForm();\n if (onClose) {\n onClose();\n }\n }\n\n function onCloseHandler(event: any, reason: any) {\n if (reason === \"backdropClick\") {\n if (mode === \"edit\") {\n if (sendingHasNotBeenEdited()) {\n handleCloseModal();\n } else {\n setCancelModalOpen(true);\n }\n } else {\n if (sendingIsEmpty()) {\n handleCloseModal();\n } else {\n setCancelModalOpen(true);\n }\n }\n }\n }\n\n const handleFormSubmit = async () => {\n if (!isFormValid()) return;\n if (mode === \"new\") {\n executeSubmitAndCloseModal();\n }\n\n if (!massiveSending.id) return;\n executeSubmitAndCloseModal();\n }\n\n function sendingIsEmpty() {\n return JSON.stringify(massiveSending) == JSON.stringify(new MassiveSendingEntity());\n }\n\n function sendingHasNotBeenEdited() {\n return JSON.stringify(massiveSending) == JSON.stringify(oldMassiveSending);\n }\n\n function executeSubmitAndCloseModal() {\n if (onCreate) {\n onCreate(massiveSending);\n }\n handleCloseModal();\n }\n\n function handleGoBackButtonClick() {\n if (mode === \"edit\") {\n if (sendingHasNotBeenEdited()) {\n handleCloseModal();\n } else {\n setCancelModalOpen(true);\n }\n }\n else {\n if (activeStep === 0) {\n if (sendingIsEmpty()) {\n handleCloseModal();\n } else {\n setCancelModalOpen(true);\n }\n } else {\n setActiveStep((prev) => prev - 1);\n }\n }\n }\n\n function handleContinueButtonClick() {\n if (mode === \"edit\" || activeStep === 2) {\n handleFormSubmit();\n }\n else {\n setActiveStep((prev) => prev + 1);\n }\n }\n\n function isContinueButtonDisabled() {\n if (mode === \"new\") {\n switch (activeStep) {\n case 0:\n return !validateGeneralSettings();\n case 1:\n return !validateMessageSettings();\n case 2:\n return !isFormValid();\n default:\n return false;\n }\n } else {\n return !isFormValid() || sendingHasNotBeenEdited()\n }\n }\n\n function validateGeneralSettings() {\n const isNameValid = massiveSending.name !== \"\" && !existingMassiveSendingsNames.includes(massiveSending.name);\n const isServiceSelected = massiveSending.prospectedServices && massiveSending.prospectedServices.length > 0;\n const areDatesValid = massiveSending.prospectedServicesAppointmentStartDate\n && massiveSending.prospectedServicesAppointmentEndDate\n && massiveSending.prospectedServicesAppointmentStartDate <= massiveSending.prospectedServicesAppointmentEndDate;\n\n if (isServiceSelected && !areDatesValid) {\n return false;\n }\n\n return isNameValid;\n }\n\n function validateMessageSettings() {\n return !(massiveSending.text === \"\"\n || (massiveSending.contentType === MassiveSendingContentType.ImageAndText && !massiveSending.imageUrl)\n || textLength > maxTextLength\n || textContainsUrl)\n }\n\n function isFormValid() {\n return validateGeneralSettings() && validateMessageSettings();\n }\n\n const getContinueButtonTitle: string =\n mode === \"edit\"\n ? t('Save changes')\n : activeStep === 2\n ? t('Confirm sending')\n : t('Continue')\n\n const LabelWithDot = (props: any) => {\n return (\n <span>\n {props.label} <span className={classes.dot}>*</span>\n </span>\n );\n }\n\n const FirstStepContent = () =>\n <MassiveSendingGeneralSettings\n mode={mode}\n massiveSending={massiveSending}\n setMassiveSending={setMassiveSending}\n sendingTypeNames={sendingTypeNames}\n customerFrequencyTypes={customerFrequencyTypes}\n customerGenders={customerGenders}\n services={servicesValues}\n birthdaySendingRules={birthdaySendingRules}\n existingMassiveSendingsNames={existingMassiveSendingsNames}\n />\n\n const SecondStepContent = () =>\n <MassiveSendingMessageSettings\n massiveSending={massiveSending}\n setMassiveSending={setMassiveSending}\n textLength={textLength}\n setTextLength={setTextLength}\n maxTextLength={maxTextLength}\n textContainsUrl={textContainsUrl}\n setTextContainsUrl={setTextContainsUrl}\n />\n\n const ThirdStepContent = () =>\n <MassiveSendingPreview\n massiveSending={massiveSending}\n sendingTypeNames={sendingTypeNames}\n customerFrequencyTypes={customerFrequencyTypes}\n customerGenders={customerGenders}\n birthdaySendingRules={birthdaySendingRules}\n />\n\n return (\n <Dialog\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n classes={{\n root: classes.modal,\n container: classes.container\n }}\n open={open}\n onClose={onCloseHandler}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n PaperProps={{\n className: classes.paper,\n elevation: 0,\n square: false\n }}\n maxWidth={false}\n scroll=\"paper\"\n >\n <DialogTitle\n className={classes.dialogHeader}\n >\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {mode === \"new\"\n ? t(\"New massive sending\")\n : t(\"Edit massive sending\")\n }\n </Typography>\n <Typography className={classes.modalTitleRequiredFields}>\n <LabelWithDot label={t('Required fields')} />\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleGoBackButtonClick}\n >\n {t('Go back')}\n </Button>\n <Button\n className={`${classes.button} ${classes.continueButton}`}\n disabled={isContinueButtonDisabled()}\n classes={{ disabled: classes.createDisabled }}\n onClick={handleContinueButtonClick}\n >\n {getContinueButtonTitle}\n </Button>\n </div>\n </div>\n {\n mode === \"new\"\n ?\n <MassiveSendingStepper\n activeStep={activeStep}\n />\n :\n <TabContext\n value={activeTab}\n >\n <Tabs\n className={classes.tabs}\n value={activeTab}\n onChange={handleTabChange}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n >\n <Tab\n className={classes.tab}\n label={t('Sending rules')}\n value=\"first\"\n />\n <Tab\n className={classes.tab}\n label={t('WhatsApp template')}\n value=\"second\"\n />\n <Tab\n className={classes.tab}\n label={t('Preview')}\n value=\"third\"\n />\n </Tabs>\n </TabContext>\n }\n </DialogTitle>\n <DialogContent\n className={classes.dialogContent}\n >\n <Fade in={open}>\n <div>\n {\n mode === \"new\"\n ?\n <>\n {activeStep === 0 && FirstStepContent()}\n {activeStep === 1 && SecondStepContent()}\n {activeStep === 2 && ThirdStepContent()}\n </>\n :\n <>\n <TabContext\n value={activeTab}\n >\n <TabPanel\n classes={{\n root: classes.tabPanelRoot\n }}\n value=\"first\"\n >\n {FirstStepContent()}\n </TabPanel>\n <TabPanel\n value=\"second\"\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {SecondStepContent()}\n </TabPanel>\n <TabPanel\n value=\"third\"\n classes={{\n root: classes.tabPanelRoot\n }}\n >\n {ThirdStepContent()}\n </TabPanel>\n </TabContext>\n </>\n }\n <CancelModal\n open={cancelModalOpen}\n setOpen={setCancelModalOpen}\n title={mode === \"new\" ? t(\"Cancel massive sending?\") : t(\"Cancel massive sending edition?\")}\n onSubmit={handleCloseModal}\n />\n </div>\n </Fade>\n </DialogContent>\n </Dialog>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n },\n blocks: {\n width: \"100%\",\n display: \"flex\",\n justifyContent: \"space-between\",\n },\n valuesBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n padding: 16,\n minWidth: 362\n },\n value: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n marginBottom: 16\n },\n valueLabel: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey4\n },\n valueText: {\n ...theme.typography.txtBody1,\n color: theme.colors.grey6\n },\n divider: {\n width: \"100%\",\n marginTop: 20,\n marginBottom: 20,\n height: 0,\n border: \"1px solid\",\n borderColor: theme.colors.grey1\n },\n previewBlock: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n alignItems: \"center\",\n borderRadius: 5,\n padding: 24,\n backgroundPosition: \"center\",\n minWidth: 346\n },\n messageBlock: {\n width: 285,\n backgroundColor: \"#FFFFFF\",\n borderRadius: \"0 5px 5px 5px\",\n padding: 8,\n position: \"relative\"\n },\n imageBlock: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"flex-start\",\n \n width: \"max-content\",\n maxWidth: 269,\n height: \"max-content\",\n maxHeight: 152,\n marginBottom: 16\n },\n image: {\n width: 269,\n height: 152,\n objectFit: \"cover\",\n objectPosition: \"center\",\n borderRadius: 15\n },\n text: {\n width: 269,\n \n ...theme.typography.txtBody2,\n color: theme.colors.grey6,\n paddingBottom: 12,\n wordBreak: \"break-word\"\n },\n arrow: {\n position: \"absolute\",\n top: 0,\n left: -11\n },\n timeBlock: {\n position: \"absolute\",\n bottom: 8,\n right: 8,\n \n ...theme.typography.caption1,\n color: theme.colors.grey5\n },\n goToSiteButton: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n width: 285,\n backgroundColor: \"#FFFFFF\",\n borderRadius: 5,\n marginTop: 3\n },\n goToSiteButtonInnerContainer: {\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n\n color: theme.colors.clearBlue,\n fontWeight: 700,\n\n width: 677,\n height: 32,\n borderRadius: 5,\n },\n goToSiteIcon: {\n margin: \"0px 5px 4px 0px\"\n },\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n },\n modalTitle: {\n width: \"100%\",\n },\n container: {\n width: 812,\n height: 550,\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n paper: {\n margin: 0,\n width: 812,\n maxWidth: 812,\n maxHeight: 570,\n padding: \"40px 40px 18px\"\n },\n dialogHeader: {\n padding: \"0 0 40px\",\n },\n modalTitleText: {\n fontSize: \"14px\",\n fontWeight: \"bold\",\n color: theme.colors.grey5,\n },\n dialogContent: {\n padding: 0,\n overflowX: \"hidden\"\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n goBack: {\n marginRight: 16,\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n buttonsContainer: {\n width: \"100%\",\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"space-between\",\n alignItems: \"center\",\n marginTop: 15\n },\n buttonWithIcon: {\n height: 24,\n borderRadius: 51,\n gap: 4,\n padding: \"11px 4px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n downloadReport: {\n color: theme.colors.clearGreen\n },\n duplicate: {\n color: theme.colors.clearMain\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function DuplicateIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n <SvgIcon\n {...otherProps}\n style={style || { width: 24, height: 24 }}\n viewBox={viewBox || \"0 0 24 24\"}\n >\n <path d=\"M17.6875 5H9.8125C9.07422 5 8.5 5.60156 8.5 6.3125V14.1875C8.5 14.9258 9.07422 15.5 9.8125 15.5H17.6875C18.3984 15.5 19 14.9258 19 14.1875V6.3125C19 5.60156 18.3984 5 17.6875 5ZM9.8125 16.375C8.58203 16.375 7.625 15.418 7.625 14.1875V8.5H6.3125C5.57422 8.5 5 9.10156 5 9.8125V17.6875C5 18.4258 5.57422 19 6.3125 19H14.1875C14.8984 19 15.5 18.4258 15.5 17.6875V16.375H9.8125Z\"\n fill=\"#6462F3\"\n />\n\n </SvgIcon>\n );\n};\n","import React from \"react\";\nimport SvgIcon from \"@material-ui/core/SvgIcon\";\n\n\nexport default function DownloadFileIcon(props: any) {\n const { style, viewBox, ...otherProps } = props;\n return (\n <SvgIcon\n {...otherProps}\n style={style || { width: 24, height: 24 }}\n viewBox={viewBox || \"0 0 24 24\"}\n >\n <path d=\"M5.55897 6.15357L13.7291 5.00325C13.7752 4.99673 13.8222 5.00005 13.8669 5.013C13.9115 5.02596 13.9529 5.04823 13.9881 5.07831C14.0233 5.1084 13.9478 5.013 14.0709 5.18737C14.1002 5.27114 14.1002 5.54564 14.1002 5.59157V18.6796C14.1002 18.7255 14.0902 18.7708 14.0709 18.8125C14.0516 18.8543 14.0234 18.8914 13.9883 18.9215C13.9532 18.9516 13.9119 18.9739 13.8673 18.9869C13.8227 18.9999 13.7758 19.0033 13.7297 18.9968L5.55832 17.8465C5.40338 17.8248 5.26161 17.7486 5.15904 17.6321C5.05647 17.5155 5 17.3664 5 17.2121V6.94155C5 6.78724 5.00063 6.55284 5.15904 6.36803C5.32562 6.23242 5.40403 6.17533 5.55897 6.15357ZM6.30058 7.34427V16.6558L12.8003 17.5716V6.4285L6.30058 7.34427ZM14.7502 16.486H16.7001V7.5141H14.7502V6.2324H17.35C17.5224 6.2324 17.6877 6.29991 17.8096 6.4201C17.9315 6.54028 18 6.70328 18 6.87325V17.1268C18 17.2968 17.9315 17.4598 17.8096 17.58C17.6877 17.7002 17.5224 17.7677 17.35 17.7677H14.7502V16.486ZM10.3304 12L12.1503 14.5634H10.5904L9.55042 13.0985L8.51047 14.5634H6.95055L8.77046 12L6.95055 9.43665H8.51047L9.55042 10.9016L10.5904 9.43665H12.1503L10.3304 12Z\"\n fill=\"#36CE91\"\n />\n </SvgIcon>\n );\n};\n","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport Interweave from \"interweave\";\nimport moment from \"moment\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Button from \"@material-ui/core/Button\";\nimport Backdrop from \"@material-ui/core/Backdrop\";\nimport { Dialog, DialogContent, DialogTitle, Fade } from \"@material-ui/core\";\n\nimport { MassiveSendingDetailProps } from \"./props\";\nimport useStyles from \"./css\";\nimport WhatsappBackground from \"../../../../assets/images/whatsapp-background.jpg\"\nimport { ExportIcon, SideArrowForMessageIcon } from \"../../../../assets/icons\";\nimport useCustomerTerminology from \"../../../../hooks/useCustomerTerminology\";\nimport DuplicateIcon from \"../../../../assets/icons/DuplicateIcon\";\nimport DownloadFileIcon from \"../../../../assets/icons/DownloadFileIcon\";\nimport ButtonWithSpinner from \"../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsBorderSide } from \"../../../../models/enums/button-props-border-side\";\nimport { ButtonPropsFill } from \"../../../../models/enums/button-props-fill\";\nimport { ButtonPropsColor } from \"../../../../models/enums/button-props-color\";\nimport { useAppSelector } from \"../../../../redux/hooks\";\nimport { selectUserInfo } from \"../../../../redux/store\";\n\n\nexport default function MassiveSendingDetail(props: MassiveSendingDetailProps) {\n\n const { massiveSending, open, setOpen, onClose, onReportDownload, onDuplicate } = props;\n const { t } = useTranslation(\"massivesendings\");\n const classes = useStyles();\n\n const userInfo = useAppSelector(selectUserInfo);\n\n const goToSite = t(\"GO TO APPT SITE\");\n\n const sendingTypeNames = [\n { key: 0, value: t(\"SingleSending\") },\n { key: 1, value: t(\"Annual sending\") },\n { key: 2, value: t(\"Birthdays\") }\n ]\n\n const customerFrequencyTypes = [\n { key: 0, value: useCustomerTerminology(t(\"All customers\"), \"customers\") },\n { key: 1, value: useCustomerTerminology(t(\"Frequent customers\"), \"Frequent customers\") },\n { key: 2, value: useCustomerTerminology(t(\"Infrequent customers\"), \"Infrequent customers\") },\n { key: 3, value: useCustomerTerminology(t(\"Inactive customers\"), \"Inactive customers\") }\n ];\n\n const customerGenders = [\n { key: 0, value: t(\"AllGenders\") },\n { key: 256, value: t(\"MaleAndFemale\") },\n { key: 1, value: t(\"Male\") },\n { key: 2, value: t(\"Female\") },\n { key: 3, value: t(\"PreferNotToSay\") },\n { key: 4, value: t(\"Custom\") },\n ];\n\n const birthdaySendingRules = [\n { key: 0, value: t(\"Same day of the birthday\") },\n { key: 1, value: t(\"One day before the birthday\") },\n { key: 2, value: t(\"One week before the birthday\") },\n { key: 3, value: t(\"Two weeks before the birthday\") },\n { key: 4, value: t(\"One month before the birthday\") },\n ];\n\n const sendingType = sendingTypeNames.find(x => x.key === massiveSending.type)!.value;\n const sendingCustomerGender = customerGenders.find(x => x.key === massiveSending.customerGender)!.value;\n const sendingCustomerFrequencyType = customerFrequencyTypes.find(x => x.key === massiveSending.customerFrequency)!.value;\n const prospectedServices = massiveSending.prospectedServices.length > 0\n ? massiveSending.prospectedServices.sort((a, b) => a.name.localeCompare(b.name)).map(s => s.name).join(\", \")\n : t(\"None\");\n const sendingBirthdaySendingRules = massiveSending.birthdaySendingType === null ? \"\" : birthdaySendingRules.find(x => x.key === massiveSending.birthdaySendingType)!.value;\n\n const sendingRules = [\n { key: 0, value: `${formattedDate(massiveSending.dateOfSending!)} - ${formattedTime(massiveSending.timeOfSending)}` },\n { key: 1, value: `${formattedDate(massiveSending.dateOfSending!)} - ${formattedTime(massiveSending.timeOfSending)}` },\n { key: 2, value: `${sendingBirthdaySendingRules} - ${formattedTime(massiveSending.timeOfSending)}` }\n ];\n\n const sendingRule = sendingRules.find(x => x.key === massiveSending.type)!.value;\n\n function formattedDate(date: Date) : string {\n return `${moment(date).format(\"DD\")}/${t(moment(date).format(\"MMMM\"))}/${moment(date).format(\"yyyy\")}`;\n }\n \n function formattedTime(time: string) : string {\n const formatted = time.split(\":\").slice(0, 2).join(\":\");\n return `${formatted}hrs`;\n }\n \n interface ValueBlockProps {\n label: string;\n value: string;\n }\n \n function ValueBlock(props: ValueBlockProps) {\n return (\n <div className={classes.value}>\n <div className={classes.valueLabel}>{props.label}</div>\n <div className={classes.valueText}>{props.value}</div>\n </div>\n )\n }\n\n function handleCloseModal() {\n setOpen(false);\n if (onClose) {\n onClose();\n }\n }\n\n function handleGoBackButtonClick() {\n handleCloseModal();\n }\n\n async function handleDownloadReportClick() {\n if (!massiveSending.id) return;\n await onReportDownload(massiveSending.id);\n }\n\n return (\n <Dialog\n aria-labelledby=\"massive-sending-details-title\"\n aria-describedby=\"massive-sending-details-description\"\n classes={{\n root: classes.modal,\n container: classes.container\n }}\n open={open}\n onClose={onClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }}\n PaperProps={{\n className: classes.paper,\n elevation: 0,\n square: false\n }}\n maxWidth={false}\n scroll=\"paper\"\n >\n <DialogTitle className={classes.dialogHeader}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <Typography className={classes.modalTitleText} variant=\"h1\">\n {t(\"Massive sending detail\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <Button\n className={`${classes.button} ${classes.goBack}`}\n onClick={handleGoBackButtonClick}\n >\n {t('Go back')}\n </Button> \n </div>\n </div>\n </DialogTitle>\n <DialogContent className={classes.dialogContent}>\n <Fade in={open}>\n <div className={classes.root}>\n <div className={classes.blocks}>\n <div className={classes.valuesBlock}>\n <ValueBlock label={t(\"Sending name\")} value={massiveSending.name} />\n <ValueBlock label={useCustomerTerminology(t(\"Type of customers to send\"), \"customers\")} value={`${sendingCustomerFrequencyType} / ${sendingCustomerGender}`} />\n <ValueBlock label={t(\"Service to prospect\")} value={prospectedServices} />\n <div className={classes.divider} />\n <ValueBlock label={t(\"Sending type\")} value={sendingType} />\n <ValueBlock label={t(\"Sending date\")} value={sendingRule} />\n <div className={classes.divider} />\n {massiveSending.type !== 0 && (\n <ValueBlock\n label={t(\"Termination of sending\")}\n value={massiveSending.terminationDate ? formattedDate(massiveSending.terminationDate) : t(\"Never ends\")}\n />\n )}\n </div>\n <div className={classes.previewBlock} style={{ backgroundImage: `url(${WhatsappBackground})` }}>\n <div className={classes.messageBlock}>\n {massiveSending.imageUrl && (\n <div className={classes.imageBlock}>\n <img src={massiveSending.imageUrl} alt=\"Preview\" className={classes.image} />\n </div>\n )}\n <div className={classes.text}>\n <Interweave content={massiveSending.text} />\n </div>\n <SideArrowForMessageIcon className={classes.arrow} />\n <div className={classes.timeBlock}>\n {formattedTime(massiveSending.timeOfSending)}\n </div>\n </div>\n <div className={classes.goToSiteButton}>\n <div className={classes.goToSiteButtonInnerContainer}>\n <div className={classes.goToSiteIcon}>\n <ExportIcon color=\"#0BCBE0\" />\n </div>\n {goToSite}\n </div>\n </div>\n </div>\n </div>\n <div className={classes.buttonsContainer}>\n {userInfo.hasAccessToReports\n ? (\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n borderSide={ButtonPropsBorderSide.All}\n fill={ButtonPropsFill.Outlined}\n backgroundOrBorderColor={ButtonPropsColor.None}\n innerText={t('Download report of impacted customers')}\n textColor={ButtonPropsColor.Green}\n innerIcon={<DownloadFileIcon color=\"#36CE91\" />}\n onClick={handleDownloadReportClick}\n />\n ): <div />\n }\n <Button\n className={`${classes.buttonWithIcon} ${classes.duplicate}`}\n onClick={() => onDuplicate(massiveSending)}\n >\n <DuplicateIcon color=\"#6462F3\" />\n {t('Duplicate and create new sending')}\n </Button> \n </div>\n </div>\n </Fade>\n </DialogContent>\n </Dialog>\n );\n}","import React, { useEffect, useState } from \"react\";\n\nimport { useTranslation } from 'react-i18next';\nimport { Grid, Typography } from \"@material-ui/core\";\nimport Button from \"@material-ui/core/Button\";\n\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../redux/alerts-slice\";\nimport { selectAccountSettings } from \"../../../../redux/store\";\n\nimport { MegaphoneIcon } from \"../../../../assets/icons\";\nimport MassiveSendingList from \"../MassiveSendingsList\";\nimport { useStyles } from \"./css\";\nimport MassiveSendingModal from \"../MassiveSendingModal\";\nimport { MassiveSendingEntity } from \"../../../../models/massive-sending-entity\";\nimport { EditableItemProps } from \"../../../../models/interfaces/editable-item-props\";\nimport { MassiveSendingService } from \"../../../../api/massive-sending-service\";\nimport { ApiClient } from \"../../../../api/api-client\";\nimport ButtonWithSpinner from \"../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../models/enums/button-props-border-radius\";\nimport MassiveSendingServiceModel from \"../../../../models/massive-sending-service-model\";\nimport MassiveSendingDetail from \"../MassiveSendingDetail\";\nimport { ReportsService } from \"../../../../api/reports-service\";\n\n\nconst MassiveSengingsMain = (props: any) => {\n\n const { t } = useTranslation([\"massivesendings\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const hasMassiveSendings = ApiClient.getUserInfo().hasMassiveSendings;\n\n const { enqueueAlert } = alertsActions;\n \n const [massiveSending, setMassiveSending] = useState<MassiveSendingEntity>(new MassiveSendingEntity());\n const [oldMassiveSending, setOldMassiveSending] = useState<MassiveSendingEntity>(new MassiveSendingEntity());\n const [services, setServices] = useState<MassiveSendingServiceModel[]>([]);\n const [modalMode, setModalMode] = useState<EditableItemProps>({ mode: \"new\", itemId: null });\n const [modalOpen, setModalOpen] = useState<boolean>(false);\n const [modalDetailOpen, setModalDetailOpen] = useState<boolean>(false);\n const [isRefresh, setRefresh] = useState<any>();\n const [total, setTotal] = useState<number>(0);\n const [existingMassiveSendingsNames, setExistingMassiveSendingsNames] = useState<string[]>([]);\n\n const accountSettings = useAppSelector(selectAccountSettings);\n\n async function handleListRowClick(itemId: string) {\n await handleOpenModal(itemId);\n }\n \n const handleConfirmDelete = async (item: any) => {\n const result = await MassiveSendingService.deleteSending(item.id);\n if (result && result.isDeleted) {\n setRefresh(result)\n }\n }\n\n const handleTotal = (total: number) => {\n setTotal(total);\n }\n\n async function handleOpenModal(itemId?: string | null) {\n const services = await MassiveSendingService.getServicesByAccount();\n setServices(services);\n\n const names = await MassiveSendingService.getSendingsNamesByAccount();\n setExistingMassiveSendingsNames(names);\n\n if (itemId) {\n const ms = await MassiveSendingService.getSendingById(itemId)\n setMassiveSending(ms);\n setOldMassiveSending(ms);\n setModalMode({ mode: \"edit\", itemId });\n } else {\n setModalMode({ mode: \"new\", itemId: null });\n }\n \n setModalOpen(true);\n }\n \n function displaySuccessfulCreationAlert(massiveSendingName: string) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Massive sending successfully created\"),\n description: `${massiveSendingName}`\n })\n )\n }\n \n function displaySuccessfulEditionAlert(massiveSendingName: string) {\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Massive sending modified\"),\n description: `${massiveSendingName}`\n })\n )\n }\n \n async function createNewSending(massiveSending: MassiveSendingEntity) {\n return massiveSending.image\n ? await MassiveSendingService.createSendingWithImage(massiveSending)\n .then(() => displaySuccessfulCreationAlert(massiveSending.name))\n .catch((e) => {\n console.log(e)\n })\n : await MassiveSendingService.createSending(massiveSending)\n .then(() => displaySuccessfulCreationAlert(massiveSending.name))\n .catch((e) => {\n console.log(e)\n });\n }\n \n async function updateSending(massiveSending: MassiveSendingEntity) {\n return massiveSending.image \n ? await MassiveSendingService.updateSendingWithImage(massiveSending)\n .then(() => displaySuccessfulEditionAlert(massiveSending.name))\n .catch((e) => { console.log(e)})\n : await MassiveSendingService.updateSending(massiveSending)\n .then(() => displaySuccessfulEditionAlert(massiveSending.name))\n .catch((e) => { console.log(e)})\n }\n \n async function handleCompleteModal(massiveSending: MassiveSendingEntity) {\n const response = modalMode.mode === \"new\"\n ? await createNewSending(massiveSending)\n : await updateSending(massiveSending)\n\n setRefresh({ massiveSending });\n }\n \n async function handleCloseModal() {\n setModalMode({ mode: \"new\", itemId: null });\n setModalOpen(false);\n }\n\n async function handleModalDetailOpen(massiveSending: MassiveSendingEntity) {\n if (!massiveSending.id) return;\n\n const detailedSending = await MassiveSendingService.getSendingById(massiveSending.id);\n setMassiveSending(detailedSending);\n\n setModalDetailOpen(true);\n }\n\n async function handleMassiveSendingDuplicate(massiveSending: MassiveSendingEntity) {\n setModalDetailOpen(false);\n\n const services = await MassiveSendingService.getServicesByAccount();\n setServices(services);\n\n const names = await MassiveSendingService.getSendingsNamesByAccount();\n setExistingMassiveSendingsNames(names);\n\n setModalMode({ mode: \"new\", itemId: massiveSending.id });\n\n setModalOpen(true);\n }\n\n async function handleReportDownload(massiveSendingId: string) {\n const newDate = new Date();\n const year = newDate.getFullYear();\n const month = newDate.getMonth() + 1;\n const today = newDate.getDate();\n\n const fileName = `${accountSettings.accountName} - ${t('Impacted customers report')} - ${today}-${month}-${year}.xlsx`;\n\n const blob = await ReportsService.getImpactedCustomersReport(massiveSendingId);\n\n const url = window.URL.createObjectURL(new Blob([blob], {\n type: \"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml\"\n }));\n\n const link = document.createElement('a');\n link.href = url;\n link.setAttribute('download', `${fileName}.xlsx`);\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n }\n\n function handleModalDetailClose() {\n setModalDetailOpen(false);\n setModalMode({ mode: \"new\", itemId: null }); \n setMassiveSending(new MassiveSendingEntity());\n }\n\n useEffect(() => {\n if (props.match.params?.sendingId) {\n handleOpenModal(props.match.params?.sendingId)\n }\n }, [])\n\n\n return (<>\n <div>\n <div className={classes.header}>\n <Grid container spacing={2}>\n <Grid item xs={6}>\n <div>\n <Typography className={classes.titles} variant=\"subtitle1\">\n {t('Massive sendings lists')}\n </Typography>\n <Typography className={classes.icons} variant=\"h4\">\n <MegaphoneIcon className={classes.icon} />\n {total}\n </Typography>\n </div>\n </Grid>\n <Grid item xs={6}>\n {\n hasMassiveSendings && \n <div className={classes.headerRight}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t('New massive sending')}\n onClick={() => handleOpenModal()}\n />\n </div>\n }\n </Grid>\n </Grid>\n </div>\n \n <MassiveSendingList \n isRefresh={isRefresh} \n onRowClick={handleListRowClick} \n onDelete={handleConfirmDelete}\n handleModalDetailOpen={handleModalDetailOpen}\n setTotalRecords={handleTotal} \n />\n\n <MassiveSendingModal \n massiveSending={massiveSending} \n services={services}\n setMassiveSending={setMassiveSending} \n oldMassiveSending={oldMassiveSending}\n mode={modalMode.mode}\n itemId={modalMode.itemId}\n open={modalOpen}\n setOpen={setModalOpen}\n onCreate={handleCompleteModal}\n onClose={handleCloseModal}\n existingMassiveSendingsNames={existingMassiveSendingsNames}\n />\n\n <MassiveSendingDetail \n massiveSending={massiveSending}\n open={modalDetailOpen}\n setOpen={setModalDetailOpen}\n onClose={handleModalDetailClose}\n onReportDownload={handleReportDownload}\n onDuplicate={handleMassiveSendingDuplicate}\n />\n \n </div>\n </>);\n}\n\nexport default MassiveSengingsMain;","import * as React from \"react\";\nimport { Redirect, Route, Switch } from \"react-router-dom\";\nimport { Url } from \"../../../constants/url\";\nimport Messenger from \"../Messenger\";\nimport WhatsAppConversationRouter from \"../WhatsAppConversationRouter\"\nimport MassiveSengingsMain from \"../massivesendings/MassiveSendingsMain\"\nimport { useAppSelector } from \"../../../redux/hooks\";\nimport { selectUserInfo } from \"../../../redux/store\";\n\n\nexport default function WhatsAppRouter() {\n\n const userInfo = useAppSelector(selectUserInfo);\n\n return (\n <Switch>\n <Route path={Url.WhatsApp.MassiveSendings} component={MassiveSengingsMain} />\n <Route path={Url.WhatsApp.MassiveSendings + \"/:sendingId\"} component={MassiveSengingsMain} />\n <Route path={Url.WhatsApp.Main + \"/:mobile\"} component={\n userInfo.hasAccessToWhatsAppConversationsAndNotifications \n ? WhatsAppConversationRouter\n : () => <Redirect to={Url.Appointments.Main}/>}/>\n <Route path={Url.WhatsApp.Main} component={\n userInfo.hasAccessToWhatsAppConversationsAndNotifications \n ? Messenger\n : () => <Redirect to={Url.Appointments.Main}/>}/>\n </Switch>\n );\n}","import * as React from \"react\";\n\nimport Typography from \"@material-ui/core/Typography\";\nimport Box from \"@material-ui/core/Box\";\n\nexport default function AppointmentDetails() {\n return (\n <Box>\n <Typography variant=\"h3\">TODO</Typography>\n </Box>\n );\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n notification: {\n background: \"#FFFFFF\",\n boxShadow: \"0px 4px 4px rgba(0,0,0,0.1)\",\n borderRadius: \"10px\",\n width: \"282px\",\n minHeight: \"74px\",\n display: \"flex\",\n alignItems: \"center\"\n },\n notificationLink: {\n background: \"#FFFFFF\",\n boxShadow: \"0px 4px 4px rgba(0,0,0,0.1)\",\n borderRadius: \"10px\",\n width: \"282px\",\n // minHeight: \"96px\",\n display: \"flex\"\n },\n notificationType: {\n alignSelf: \"flex-start\",\n borderRadius: \"10px 0px 0px 10px\",\n minHeight: \"74px\",\n height: \"100%\",\n width: 5,\n },\n notificationSuccess: {\n backgroundColor: \"#36CE91\",\n },\n notificationError: {\n backgroundColor: \"#F15857\",\n },\n notificationWarning: {\n backgroundColor: \"#FFC626\",\n },\n notificationBody: {\n position: \"relative\",\n display: \"flex\",\n alignItems: \"center\",\n height: \"100%\",\n width: \"100%\",\n },\n notificationIconContainer: {\n width: 56,\n height: \"100%\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\"\n },\n notificationIcon: {\n width: 28,\n height: 28,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\"\n },\n notificationContent: {\n display: \"flex\",\n alignItems: \"center\",\n width: \"100%\",\n height: \"100%\",\n },\n notificationText: {\n height: \"100%\",\n width: \"100%\",\n padding: \"16px 0px\",\n },\n notificationTitle: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"bold\"\n },\n notificationDescription: {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n whiteSpace: \"pre-wrap\",\n wordBreak: \"break-word\"\n },\n notificationClose: {\n padding: \"8px 8px 0 8px\",\n height: \"100%\",\n color: theme.colors.grey4,\n display: \"flex\",\n alignSelf: \"flex-start\"\n },\n closeIconButton: {\n alignSelf: \"flex-start\",\n },\n notificationCloseIcon: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n link: {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n \"&:hover\": {\n color: theme.colors.clearMain,\n },\n },\n}));\n\nexport default useStyles;\n","import React, { useEffect } from \"react\";\nimport { useSnackbar } from \"notistack\";\n\nimport IconButton from \"@material-ui/core/IconButton\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport {\n SuccessIcon,\n ErrorIcon,\n ExclamationIcon, CrossIcon,\n} from \"./../../../../assets/icons\";\nimport { useAppDispatch, useAppSelector } from \"./../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../redux/alerts-slice\";\n\nimport { AlertProps } from \"./props\";\nimport useStyles from \"./css\";\n\nconst Alert = (props: AlertProps) => {\n const { closeSnackbar } = useSnackbar();\n const { key, title, description, link, type } = props;\n const classes = useStyles();\n return (\n <div className={link ? classes.notificationLink : classes.notification}>\n <div\n className={`${classes.notificationType} ${\n type === \"Error\"\n ? classes.notificationError\n : type === \"Success\"\n ? classes.notificationSuccess\n : classes.notificationWarning\n }`}\n />\n <div className={classes.notificationBody}>\n <div className={classes.notificationIconContainer}>\n <div className={classes.notificationIcon}>\n {type === \"Error\" ? (\n <ErrorIcon />\n ) : type === \"Success\" ? (\n <SuccessIcon />\n ) : (\n <ExclamationIcon viewBox=\"0 0 1 20\" />\n )}\n </div>\n </div>\n <div className={classes.notificationContent}>\n <div className={classes.notificationText}>\n <Typography className={classes.notificationTitle}>\n {title}\n </Typography>\n <Typography className={classes.notificationDescription}>\n {description}\n </Typography>\n {link && link.title &&\n <a\n href={link?.url || \"#\"}\n onClick={link?.onClick}\n className={classes.link}\n >\n {link?.title}\n </a>\n }\n </div>\n </div>\n </div>\n <div className={classes.notificationClose}>\n <IconButton\n size=\"small\"\n aria-label=\"close\"\n color=\"inherit\"\n onClick={() => {\n closeSnackbar(key);\n }}\n className={classes.closeIconButton}\n >\n <div className={classes.notificationCloseIcon}>\n <CrossIcon style={{ width: 16, height: 16 }} viewBox=\"0 0 16 16\" />\n </div>\n </IconButton>\n </div>\n </div>\n );\n};\n\nlet displayed: any[] = [];\n\nconst useAlert = () => {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const dispatch = useAppDispatch();\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const alerts = useAppSelector((state) => state.alerts.alerts);\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const { enqueueSnackbar, closeSnackbar } = useSnackbar();\n\n const { removeAlert } = alertsActions;\n\n const storeDisplayed = (id: any) => {\n displayed = [...displayed, id];\n };\n\n const removeDisplayed = (id: any) => {\n displayed = [...displayed.filter((key) => id !== key)];\n };\n\n const classes = useStyles();\n\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useEffect(() => {\n alerts.forEach((alert) => {\n const { key, title, description, link, type } = alert;\n\n if (alert.dismissed) {\n closeSnackbar(key);\n return;\n }\n\n // do nothing if snackbar is already displayed\n if (displayed.includes(key)) return;\n\n // display snackbar using notistack\n enqueueSnackbar(alert.title, {\n key: key,\n content: (key: any, message: any) => (\n <div className={link ? classes.notificationLink : classes.notification}>\n <div\n className={`${classes.notificationType} ${\n type === \"Error\"\n ? classes.notificationError\n : type === \"Success\"\n ? classes.notificationSuccess\n : classes.notificationWarning\n }`}\n />\n <div className={classes.notificationBody}>\n <div className={classes.notificationIconContainer}>\n <div className={classes.notificationIcon}>\n {type === \"Error\" ? (\n <ErrorIcon />\n ) : type === \"Success\" ? (\n <SuccessIcon />\n ) : (\n <ExclamationIcon viewBox=\"0 0 1 20\" />\n )}\n </div>\n </div>\n <div className={classes.notificationContent}>\n <div className={classes.notificationText}>\n <Typography className={classes.notificationTitle}>\n {title}\n </Typography>\n <Typography className={classes.notificationDescription}>\n {description}\n </Typography>\n {link && link.title &&\n <a\n href={link?.url || \"#\"}\n onClick={link?.onClick}\n className={classes.link}\n >\n {link?.title}\n </a>\n }\n </div>\n </div>\n </div>\n <div className={classes.notificationClose}>\n <IconButton\n size=\"small\"\n aria-label=\"close\"\n color=\"inherit\"\n onClick={() => {\n closeSnackbar(key);\n }}\n className={classes.closeIconButton}\n >\n <div className={classes.notificationCloseIcon}>\n <CrossIcon style={{ width: 16, height: 16 }} viewBox=\"0 0 16 16\" />\n </div>\n </IconButton>\n </div>\n </div>\n ),\n // onClose: (event, reason, myKey) => {\n // if (options.onClose) {\n // options.onClose(event, reason, myKey);\n // }\n // },\n onExited: (event, myKey) => {\n // remove this snackbar from redux store\n dispatch(removeAlert(myKey));\n removeDisplayed(myKey);\n },\n });\n\n // keep track of snackbars that we've displayed\n storeDisplayed(key);\n });\n \n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [alerts]);\n};\n\nexport default useAlert;\n","import React from \"react\";\nimport { SnackbarProvider } from \"notistack\";\nimport Collapse from \"@material-ui/core/Collapse\";\n\nimport { AlertProviderProps } from \"./props\";\n\nconst AlertProvider = (props: AlertProviderProps) => {\n const { children } = props;\n return (\n <SnackbarProvider\n maxSnack={4}\n autoHideDuration={6000}\n anchorOrigin={{ vertical: \"bottom\", horizontal: \"left\" }}\n TransitionComponent={Collapse}\n >\n {children}\n </SnackbarProvider>\n );\n};\n\nexport default AlertProvider;\n","import { ApiClient } from \"./api-client\";\n\nexport default class CountryService {\n\n private static baseUrl: string = \"/country\";\n \n static getCountries(locale?: string): Promise<any> {\n let urlEndpoint = `${this.baseUrl}/getlist?locale=${locale ?? \"es\"}`;\n return ApiClient.get(urlEndpoint)\n .then((data) => {\n return ({country: data.country, countryInSettings: data.countryInSettings });\n });\n }\n\n}\n","import React, { useEffect } from 'react';\n\nimport { useTranslation } from \"react-i18next\";\nimport { useSelector } from 'react-redux';\n\nimport { useAppDispatch, useAppSelector } from \"../../../../redux/hooks\";\nimport { RootState, selectAccountSettings, selectUserInfo } from \"../../../../redux/store\";\nimport { applicationInterfaceActions } from \"../../../../redux/application-interface-slice\";\nimport { navbarActions } from \"../../../../redux/navbar-slice\";\nimport { setAccountSettings } from \"../../../../redux/account-settings-slice\";\nimport { setEstablishmentSettings } from '../../../../redux/establishment-settings-slice';\nimport { setUserInfo } from \"../../../../redux/user-info-slice\";\n\nimport { AccountService } from \"../../../../api/account-service\";\nimport { ApiClient } from \"../../../../api/api-client\";\nimport CountryService from \"../../../../api/country-service\";\n\n\nexport default function AccountSettingsProvider() {\n \n const { t } = useTranslation([\"general\"]);\n \n const dispatch = useAppDispatch();\n\n const selectedAccountId = useSelector((state: RootState) => state.enterprise.settingsEstablishmentId);\n const userInfo = useAppSelector(selectUserInfo);\n const isEnterprise = userInfo.accountId === selectedAccountId;\n\n const accountSettings = useAppSelector(selectAccountSettings);\n \n const localeStorage = localStorage.getItem('locale') ?? process.env.REACT_APP_DEFAULT_LANGUAGE ?? 'es';\n \n async function requestAccountSettings() {\n\n dispatch(navbarActions.setShowLoader(true));\n\n const accountSettingsResponse = await AccountService.getAccountSettings();\n const countriesResponse = await CountryService.getCountries(localeStorage);\n\n dispatch(navbarActions.setShowLoader(false));\n\n accountSettingsResponse.paymentMethods = accountSettingsResponse.paymentMethods.map(x => {\n return { key: x.key, value: t(x.value) }\n });\n accountSettingsResponse.countries = countriesResponse.country;\n accountSettingsResponse.countryInSettings = countriesResponse.countryInSettings;\n\n dispatch(setAccountSettings(accountSettingsResponse));\n }\n\n async function requestEstablishmentSettings(establishmentId: string) {\n\n dispatch(navbarActions.setShowLoader(true));\n\n const establishmentSettingsResponse = await AccountService.getEstablishmentSettings(establishmentId);\n dispatch(navbarActions.setShowLoader(false));\n\n dispatch(setEstablishmentSettings(establishmentSettingsResponse));\n }\n \n useEffect(() => {\n if (accountSettings.accountName === \"\") {\n requestAccountSettings();\n }\n \n if (!isEnterprise && selectedAccountId) {\n requestEstablishmentSettings(selectedAccountId);\n }\n\n AccountService.getAccountOverdue().then(isOverdue => {\n dispatch(applicationInterfaceActions.updateAccountOverdue(isOverdue));\n });\n \n if (!userInfo.email || !userInfo.fullName) {\n dispatch(setUserInfo(ApiClient.getUserInfo()))\n }\n\n }, [selectedAccountId])\n \n return null;\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 15,\n gap: 20,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n newSectionButtonContainer: {\n display: \"flex\",\n marginBottom: 24,\n },\n newButton: {\n marginLeft: \"auto\",\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n copyNotes:{\n backgroundColor: theme.colors.clearLilac,\n borderRadius: 5,\n padding: \"20px 30px\",\n marginBottom: 32\n },\n copyNotesTitle: {\n color: theme.colors.clearMain,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 700,\n wordWrap: \"break-word\"\n },\n copyNotesDescription: {\n color: theme.colors.grey5,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 400,\n wordWrap: \"break-word\"\n },\n copyControls:{\n display: \"flex\",\n },\n copyButton:{\n marginLeft: 16,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n cancelButton:{\n marginLeft: 16,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.gray1,\n color: Color.clear2,\n borderColor: Color.clear2,\n borderWidth: 1,\n borderStyle: \"solid\",\n \"&:hover\": {\n background: Color.white,\n },\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n select: {\n ...theme.typography.txtBody2,\n height: 32,\n width: 205,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \"& .MuiPaper-rounded\": {\n borderRadius: 10,\n marginTop: 8\n },\n \"& .MuiPaper-rounded .MuiListItem-root.Mui-selected:not(:hover)\": {\n backgroundColor: \"white\",\n },\n \"& .MuiPaper-rounded .MuiListItem-root\": {\n fontSize: 12,\n },\n \"& .MuiPaper-rounded .MuiListItem-root:hover\": {\n backgroundColor: theme.colors.grey1\n },\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"8px 0px 8px 15px\",\n color: theme.colors.clearMain\n },\n multiSelect: {\n ...theme.typography.txtBody2,\n height: 32,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 250,\n marginLeft: 16,\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n \"& .MuiMenu-list\": {\n borderRadius: \"0 0 10px 10px\",\n marginTop: 8\n },\n },\n sectionsContainer: {\n border: \"1px solid\",\n borderColor: \"#DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"auto\",\n overflow: \"hidden\"\n },\n communicationSettingsContainer: {\n border: \"1px solid\",\n borderColor: \"#DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"auto\",\n backgroundColor: \"#FFFFFF\",\n overflow: \"hidden\"\n },\n mainTitle: {\n fontWeight: 700,\n fontSize: 14,\n color: \"#919CA5\"\n },\n iconTooltipRoot: {\n display: \"inline-block\"\n },\n checkboxTitle: {\n fontWeight: 400,\n fontSize: 14,\n color: \"#919CA5\"\n },\n tinyMceOverrides: {\n \"& svg\": {\n fill: \"#919CA5 !important\"\n },\n \"& button.tox-tbtn--select\": {\n visibility: \"hidden\"\n },\n position: \"relative\",\n padding: \"15px 0px 23px 47px\"\n },\n tinyMceUnfocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#C9CDD3 !important\"\n }\n },\n tinyMceFocused: {\n \"& div.tox-tinymce\": {\n borderRadius: 5,\n borderColor: \"#6462F3 !important\"\n }\n },\n charCounter: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"10px\",\n lineHeight: \"12px\",\n position: \"absolute\",\n paddingRight: 15,\n marginTop: \"-18px\",\n marginRight: \"15px\",\n color: theme.colors.grey5\n },\n communicationSettingsMainTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"14px\",\n marginBottom: \"13px\",\n color: \"#919CA5\"\n },\n communicationSettingsCheckboxGroupTitle: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n marginBottom: \"20px\",\n color: \"#919CA5\"\n },\n communicationSettingsHeader: {\n fontFamily: 'Inter',\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n marginBottom: \"16px\",\n color: \"#5C6477\"\n },\n previewButton: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n border: \"1px solid \" + Color.clear1,\n color: Color.clear1,\n },\n counterWrapper: {\n display: \"flex\",\n justifyContent: \"flex-end\"\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n paper: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: theme.palette.background.paper,\n border: \"1px solid #dbdcdd\",\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 720,\n height: 210,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n padding: \"26px 40px 22px 40px\"\n },\n modalTitle: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 5,\n width: \"100%\",\n \"& svg path\": {\n fill: theme.colors.grey5\n }\n },\n modalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n gap: 16\n },\n goBack: {\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n content: {\n backgroundColor: \"#FAFAFA\",\n height: \"100%\",\n padding: \"33px 40px\",\n borderRadius: \"10px\",\n },\n requiredAsterisk: {\n color: Color.clear1,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n closeConfirmationModal: {\n height: \"234px + !important\"\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n}));\n\nexport default useStyles;","import React, { useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { SectionNewModalProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Backdrop, Button, Fade, Modal, Typography } from \"@material-ui/core\";\nimport { SectionNewIcon } from \"../../../../../assets/icons\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport ConfirmActionModal from \"../../../../common/ConfirmActionModal\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\nexport default function SectionNewModal(props: SectionNewModalProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n\n const { sections, isOpen, setOpen, onCreate } = props;\n const classes = useStyles();\n\n const maxTextFieldLength = 200;\n\n const [justOpened, setJustOpened] = useState<boolean>(true); //need to make input look valid on open\n const [dataIsValid, setDataIsValid] = useState<boolean>(false);\n const [name, setName] = useState<string>(\"\");\n const [closeConfirmationModalIsOpen, setCloseConfirmationModalIsOpen] = useState<boolean>(false);\n\n const handleOnClose = () => {\n setCloseConfirmationModalIsOpen(false);\n setOpen(false);\n setDataIsValid(false);\n setName(\"\");\n setJustOpened(true);\n };\n\n const handleAddButtonClick = async () => {\n if (!dataIsValid)\n return;\n\n await onCreate(name);\n handleOnClose();\n };\n\n const tryCloseModal = () => {\n if (name === \"\") {\n handleOnClose()\n }\n else {\n setCloseConfirmationModalIsOpen(true);\n }\n };\n\n const handleOnChange = (event: React.ChangeEvent<{ value: string }>) => {\n const localName = event.target.value;\n if (localName.length > maxTextFieldLength ||\n localName.trim().length === 0 ||\n (sections && !nameIsAlreadyUsed(localName))) {\n setDataIsValid(false);\n setName(localName);\n return;\n }\n\n if (justOpened)\n setJustOpened(false);\n\n setName(localName);\n setDataIsValid(true);\n };\n \n const nameIsAlreadyUsed = (localName: any) => {\n let newSectionName = localName\n .trim()\n .toLowerCase()\n .normalize('NFD')\n .replace(/\\p{Diacritic}/gu, '');\n \n let currentSectionNames = sections!.map(s => t(s.name!, { ns: sectionTNamespace })\n .trim()\n .toLowerCase()\n .normalize('NFD')\n .replace(/\\p{Diacritic}/gu, ''));\n \n return !currentSectionNames.includes(newSectionName);\n };\n\n const CloseModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {t(\"Are you sure you want to cancel the creation of the new section?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {t(\"The changes made will not be saved\")}\n </Typography>\n </div>);\n };\n\n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={tryCloseModal}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n <Fade in={isOpen}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n <SectionNewIcon />\n <Typography className={classes.modalTitleText}>\n {t(\"New section\")}\n </Typography>\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t\t backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={tryCloseModal}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t \t backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={t(\"Add\")}\n onClick={handleAddButtonClick}\n\t\t \t disabled={!dataIsValid}\n />\n </div>\n </div>\n <div className={classes.content}>\n <InputWithLabel\n label={() => <>{t(\"Name\")} <span className={classes.requiredAsterisk}>*</span></>}\n placeholder={t(\"Enter the name of the section\")}\n value={name}\n width={637}\n name=\"name\"\n onChange={(e) => handleOnChange(e)}\n isValid={() => justOpened || dataIsValid}\n />\n </div>\n </div>\n </Fade>\n </Modal>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<CloseModalContent />}\n open={closeConfirmationModalIsOpen}\n onClose={() => setCloseConfirmationModalIsOpen(false)}\n onConfirm={handleOnClose}\n />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n sectionsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n }\n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n paddingBottom: 32\n },\n sectionContainer: {\n border: \"1px solid\",\n borderColor: \"#DBDCDD\",\n boxSizing: \"border-box\",\n borderRadius: \"12px 12px 12px 12px\",\n height: \"auto\",\n overflow: \"hidden\",\n },\n headerContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n backgroundColor: Color.gray1,\n height: 57,\n width: \"100%\",\n paddingLeft: 32,\n paddingRight: 22\n },\n headerTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray7\n },\n headerButtonsContainer: {\n\n },\n headerButton: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n },\n headerButtonDisabled: {\n \"&.MuiButton-root\": {\n minWidth: 0\n },\n \"& svg path\": {\n fill: Color.gray2\n }\n },\n innerLayout: {\n width: \"100%\",\n padding: 16\n },\n fieldsContainer: {\n\n },\n noItemsBox: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n height: 80,\n width: \"100%\",\n backgroundColor: Color.gray1,\n borderRadius: 10,\n },\n noItemsLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"21px\",\n lineHeight: \"25px\",\n color: Color.gray4\n },\n footerContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n paddingTop: 24,\n paddingBottom: 8\n },\n newButton: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n deleteConfirmationModal: {\n height: \"auto !important\"\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\"\n },\n deleteModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n textAlign: \"center\"\n },\n deleteModalContentBoldText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n sectionEditNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\" ,\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5 + \" !important\"\n },\n \n}));\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n sectionContainer: {\n boxSizing: \"border-box\",\n borderRadius: \"12px\",\n overflow: \"hidden\",\n backgroundColor: Color.gray1,\n },\n sectionLayout: {\n display: \"flex\",\n flexDirection: \"column\",\n padding: \"8px 12px\"\n },\n draggableClassName: {\n padding: \"4px 0px\"\n },\n innerFieldContentContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"baseline\",\n gap: 10,\n flexWrap: \"wrap\"\n },\n fieldItemsContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n flexDirection: \"column\",\n gap: 13,\n flex: \"1 1 100%\"\n },\n fieldTypeContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"baseline\",\n gap: 5,\n marginRight: 9\n },\n fieldItemBox: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 7\n },\n fieldNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n maxWidth: \"300px\",\n overflow: \"hidden\",\n whiteSpace: \"nowrap\",\n textOverflow: \"ellipsis\"\n },\n fieldInnerComponentDivider: {\n fontSize: \"21px\",\n lineHeight: \"23px\",\n color: Color.gray4,\n padding: \"0 7px\"\n },\n fieldTypeNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"15px\",\n color: Color.gray4\n },\n fieldItemNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5,\n overflow: 'hidden',\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis',\n maxWidth: 980\n },\n}));\n\nexport default useStyles;","import React, { CSSProperties } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { FieldListProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Box, Grid, Typography } from \"@material-ui/core\";\nimport { DragDropContext, Droppable, DropResult } from \"react-beautiful-dnd\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport DraggableBase from \"../../../../common/DraggableBase\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport {\n SectionFieldCheckboxIcon,\n SectionFieldCheckboxItemIcon,\n SectionFieldDateIcon,\n SectionFieldDropdownIcon,\n SectionFieldDropdownItemIcon,\n SectionFieldEmailIcon,\n SectionFieldNumericIcon,\n SectionFieldOptionalTextFieldIcon,\n SectionFieldPhoneIcon,\n SectionFieldRadioIcon,\n SectionFieldRadioItemIcon,\n SectionFieldTextIcon\n} from \"../../../../../assets/icons\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionFieldUpdateOrderRequest } from \"../../../../../models/section-field-update-order-request\";\n\nexport default function FieldList(props: FieldListProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { accountId, section, onEditClick, onDeleteClick } = props;\n const classes = useStyles();\n\n const getReorderedFields = (fields: SectionFieldModel[], prevOrder: number, newOrder: number, movedFieldId: string) => {\n const result = Array.from(fields);\n\n const positionsMoved = newOrder - prevOrder;\n const isMovedDown = positionsMoved > 0;\n const affectedFieldIds = isMovedDown\n ? fields.filter(f => f.id === movedFieldId ||\n f.order! <= newOrder &&\n f.order! >= prevOrder)\n .map(f => f.id)\n : fields.filter(f => f.id === movedFieldId ||\n f.order! >= newOrder &&\n f.order! <= prevOrder)\n .map(f => f.id);\n\n result.forEach(f => {\n if (!affectedFieldIds.includes(f.id!))\n return;\n if (f.id === movedFieldId) {\n f.order = newOrder;\n return;\n }\n f.order = isMovedDown ? f.order! - 1 : f.order! + 1;\n });\n\n return result;\n };\n\n const dragEndHandler = async (result: DropResult) => {\n const { destination, source, draggableId } = result;\n\n //dropped not at droppable\n if (!destination)\n return;\n\n //dropped at other field list\n if (destination.droppableId !== source.droppableId)\n return;\n\n //dropped at the same spot\n if (destination.droppableId === source.droppableId && destination.index === source.index)\n return;\n\n const prevOrder = source.index + 1;\n const newOrder = destination.index + 1;\n\n section.fields = getReorderedFields(section.fields, prevOrder, newOrder, draggableId);\n\n await SettingsPatientFormsService.reorderSectionFields(new SectionFieldUpdateOrderRequest(\n {\n establishmentAccountId: accountId,\n id: draggableId,\n sectionId: section.id,\n newOrder: newOrder,\n previousOrder: prevOrder\n }));\n };\n\n const fieldContentDividerComponent =\n <Typography className={classes.fieldInnerComponentDivider}>\n |\n </Typography>;\n\n const getFieldTypeNameComponent = (typeName: string) => {\n return <Typography className={classes.fieldTypeNameLabel}>\n {t(typeName)}\n </Typography>\n };\n\n const getFieldTypeComponent = (type: SectionFieldType) => {\n switch (type) {\n case SectionFieldType.PhoneNumber:\n return <>\n <SectionFieldPhoneIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"PhoneNumberPatientFormsSections\")}\n </>\n case SectionFieldType.Email:\n return <>\n <SectionFieldEmailIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"Email\")}\n </>\n case SectionFieldType.Radio:\n return <>\n <SectionFieldRadioIcon style={{ position: \"relative\", top: 4 }}/>\n {getFieldTypeNameComponent(\"Multiple choice\")}\n </>\n case SectionFieldType.Checkbox:\n return <>\n <SectionFieldCheckboxIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"Checkboxes\")}\n </>\n case SectionFieldType.Dropdown:\n return <>\n <SectionFieldDropdownIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"Dropdown list\")}\n </>\n case SectionFieldType.Text:\n return <>\n <SectionFieldTextIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"Free text\")}\n </>\n case SectionFieldType.Numeric:\n return <>\n <SectionFieldNumericIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"Numeric field\")}\n </>\n case SectionFieldType.Date:\n return <>\n <SectionFieldDateIcon style={{ position: \"relative\", top: 6 }}/>\n {getFieldTypeNameComponent(\"Date\")}\n </>\n };\n };\n\n const tryGetFieldItemComponents = (field: SectionFieldModel) => {\n let iconComponent: JSX.Element;\n \n switch (field.type) {\n case SectionFieldType.Checkbox:\n iconComponent = <SectionFieldCheckboxItemIcon/>;\n break;\n case SectionFieldType.Radio:\n iconComponent = <SectionFieldRadioItemIcon/>;\n break;\n case SectionFieldType.Dropdown:\n iconComponent = <SectionFieldDropdownItemIcon/>;\n break;\n default:\n return <>\n \n </>\n }\n\n return <>\n {field.items.sort((i1, i2) => i1.order! - i2.order!).map(i =>\n <div className={classes.fieldItemBox}>\n {iconComponent}\n <Typography className={classes.fieldItemNameLabel}>\n {t(i.name!, { ns: sectionTNamespace })}\n </Typography>\n </div>)\n }\n </>\n\n };\n \n const getOptionalFreeTextComponent = (field: SectionFieldModel) => {\n let optionalFreeTextComponent: JSX.Element;\n\n if (field.isAdditionalTextareaEnabled) {\n optionalFreeTextComponent = <>\n <div>\n {fieldContentDividerComponent}\n </div>\n <div className={classes.fieldItemBox} style={{ marginLeft: \"14px\", paddingTop: 6 }}>\n <SectionFieldOptionalTextFieldIcon />\n <Typography className={classes.fieldItemNameLabel}>\n {t(\"Free text\")}\n </Typography>\n </div>\n </>\n }\n else {\n optionalFreeTextComponent = <></>\n }\n \n return <>\n {optionalFreeTextComponent}\n </>\n\n };\n\n const getInnerFieldContent = (field: SectionFieldModel) => {\n return <div className={classes.innerFieldContentContainer}>\n <Typography className={classes.fieldNameLabel}>\n {t(field.name!, { ns: sectionTNamespace })}\n </Typography>\n <div style={{ padding: \"0px 7px\" }}>\n {fieldContentDividerComponent}\n </div>\n <div className={classes.fieldTypeContainer}>\n {getFieldTypeComponent(field.type!)}\n </div>\n <div style={{display: \"flex\"}}>\n {getOptionalFreeTextComponent(field)} \n </div>\n \n <div className={classes.fieldItemsContainer}>\n {tryGetFieldItemComponents(field)}\n </div>\n </div>\n };\n \n const getInnerContainerStyle = (type: SectionFieldType) : CSSProperties => {\n if (type === SectionFieldType.Radio) {\n return {\n minHeight: 48\n }; \n }\n return {\n height: 48\n }\n };\n \n\n const mapFieldsToComponents = (fields: SectionFieldModel[]) => {\n return fields.sort((f1, f2) => f1.order! - f2.order!).map(f =>\n <DraggableBase\n key={f.id!}\n className={classes.draggableClassName}\n height={48}\n innerContainerStyle={getInnerContainerStyle(f.type)}\n draggableId={f.id!}\n index={f.order! - 1}\n isEditable={f.isEditable!}\n isEditableByButton={f.isEditable!}\n isRemovable={f.isRemovable!}\n onEditClick={() => onEditClick(f.id!)}\n onDeleteClick={() => onDeleteClick(f.id!)}\n >\n {getInnerFieldContent(f)}\n </DraggableBase>)\n };\n\n return <>\n <DragDropContext onDragEnd={dragEndHandler}>\n <Droppable key={section.id!} droppableId={section.id!}>\n {(provided) => (\n <Box>\n <div className={classes.sectionContainer} style={{ height: (48 + 8 + 1) * section.fields.length + 16 + (section.fields.reduce((total, field) => total + field.items?.length, 0) * 37) }}>\n <Grid\n container\n justifyContent=\"center\"\n className={classes.sectionLayout}\n ref={provided.innerRef}\n {...provided.droppableProps}\n >\n {mapFieldsToComponents(section.fields)}\n </Grid>\n </div>\n </Box>\n )}\n </Droppable>\n </DragDropContext>\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n modal: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n overflowY: \"auto\",\n \"& ::-webkit-scrollbar\": {\n width: \"6px\",\n },\n \"& ::-webkit-scrollbar-track\": {\n borderRadius: \"10px\",\n background: \"#EFEFEF\",\n marginTop: \"33px\",\n marginBottom: \"33px\"\n },\n \"& ::-webkit-scrollbar-thumb\": {\n borderRadius: \"10px\",\n background: \"#ACB7C0\",\n },\n \"& ::-webkit-scrollbar-thumb:hover\": {\n background: Color.gray4\n },\n },\n paper: {\n display: \"flex\",\n flexDirection: \"column\",\n backgroundColor: theme.palette.background.paper,\n borderRadius: \"10px\",\n boxShadow: theme.shadows[5],\n width: 720,\n maxHeight: 500,\n },\n modalHeader: {\n display: \"flex\",\n alignItems: \"center\",\n padding: \"24px 40px\",\n },\n modalTitle: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 5,\n width: \"100%\",\n \"& svg path\": {\n fill: theme.colors.grey5\n }\n },\n modalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n modalActions: {\n display: \"flex\",\n justifyContent: \"flex-end\",\n gap: 16\n },\n goBack: {\n background: \"#F6F6F6\",\n color: \"#ACB7C0\",\n },\n continueButton: {\n background: \"#36CE91\",\n color: \"#F6F6F6\",\n \"&:hover\": {\n background: \"#36CE91\",\n },\n },\n createDisabled: {\n color: \"#F6F6F6 !important\",\n opacity: \"0.4\",\n },\n button: {\n width: 200,\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"center\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n },\n scrollbarWrapper: {\n width: \"100%\",\n borderRadius: \"0 0 10px 10px\",\n backgroundColor: \"#FAFAFA\",\n },\n content: {\n backgroundColor: \"#FAFAFA\",\n maxHeight: 420,\n padding: \"24px 25px 16px 40px\",\n borderRadius: \"0 0 10px 10px\",\n display: \"flex\",\n flexDirection: \"column\",\n gap: 25,\n overflowY: \"auto\",\n width: \"calc(100% - 15px)\",\n },\n requiredAsterisk: {\n color: Color.clear1,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n contentRowContainer: {\n display: \"flex\",\n alignItems: \"flex-end\",\n gap: 30\n },\n fieldTypeSelectItemContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 10\n },\n fieldItemsContainer: {\n boxSizing: \"border-box\",\n overflow: \"hidden\",\n },\n fieldItemsLayout: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n draggableClassName: {\n padding: \"4px 0px\",\n cursor: \"text !important\",\n },\n innerItemContentContainer: {\n display: \"flex\",\n justifyContent: \"flex-start\",\n alignItems: \"center\",\n gap: 3,\n },\n itemNameLabel: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: theme.colors.grey5\n },\n addItemButton: {\n justifyContent: \"space-around\",\n \n marginTop: -17,\n height: 32,\n \n ...theme.typography.buttons,\n fontWeight: 700,\n color: theme.colors.clearMain,\n \n borderRadius: 51,\n border: `1px solid ${theme.colors.clearMain}`,\n \n \"&.Mui-disabled\": {\n color: theme.colors.clearMain,\n }\n },\n itemEditNameInput: {\n backgroundColor: Color.white + \" !important\",\n border: \"1px solid \" + Color.gray2,\n borderRadius: \"5px !important\",\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"12px\",\n lineHeight: \"14px\",\n color: Color.gray5 + \" !important\"\n },\n closeConfirmationModal: {\n height: \"234px + !important\"\n },\n closeModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n },\n closeModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\",\n textAlign: \"center\",\n maxWidth: \"80%\"\n },\n closeModalContentText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"14px\",\n lineHeight: \"17px\",\n color: Color.gray5\n },\n separator: {\n height: 0,\n borderTop: \"1px solid rgba(201, 205, 211, 0.38)\",\n margin: \"16px 0px 16px 0px\",\n width: 217\n },\n deleteConfirmationModal: {\n height: 194\n },\n deleteModalContentContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n flexDirection: \"column\",\n paddingTop: 15\n },\n deleteModalTitleText: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: \"#26292B\"\n },\n}));\n\nexport default useStyles;","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { DragDropContext, Droppable, DropResult } from \"react-beautiful-dnd\";\n\nimport { Backdrop, Box, Button, ClickAwayListener, Fade, Grid, Modal, Typography } from \"@material-ui/core\";\nimport { SectionFieldModalProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport { PlusIcon, SectionEditIcon, SectionFieldEmailIcon, SectionFieldNewIcon, SectionFieldPhoneIcon, SectionFieldRadioIcon, SectionFieldRadioItemIcon, SectionFieldTextIcon } from \"../../../../../assets/icons\";\nimport InputWithLabel from \"../../../../common/InputWithLabel\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport SelectWithLabel from \"../../../../common/SelectWithLabel\";\nimport { SelectItem } from \"../../../../common/Select\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport { Color } from \"../../../../../constants/colors\";\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport { SectionFieldItemModel } from \"../../../../../models/section-field-item-model\";\nimport DraggableBase from \"../../../../common/DraggableBase/draggable-base\";\nimport Input from \"../../../../common/Input\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport ConfirmActionModal from \"../../../../common/ConfirmActionModal\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\nimport { ButtonPropsColor } from \"../../../../../models/enums/button-props-color\";\n\nexport default function SectionFieldModal(props: SectionFieldModalProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { isOpen, section, sections, mode, field, setOpen, onSave } = props;\n const classes = useStyles();\n const isNew = mode === \"new\";\n const maxNameLength = 200;\n\n const fieldTypeSelectItems: SelectItem[] = section.type === SectionType.ClinicHistory \n ? [\n {\n key: SectionFieldType.Radio, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldRadioIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Multiple choice\")}\n </Typography>\n </div>\n },\n {\n key: SectionFieldType.Text, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldTextIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Free text\")}\n </Typography>\n </div>\n }\n ]\n : [\n {\n key: SectionFieldType.Email, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldEmailIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Email\")}\n </Typography>\n </div>\n },\n {\n key: SectionFieldType.PhoneNumber, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldPhoneIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"PhoneNumberPatientFormsSections\")}\n </Typography>\n </div >\n },\n {\n key: SectionFieldType.Radio, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldRadioIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Multiple choice\")}\n </Typography>\n </div>\n },\n {\n key: SectionFieldType.Text, value:\n <div className={classes.fieldTypeSelectItemContainer}>\n <SectionFieldTextIcon style={{ color: Color.gray5 }} />\n <Typography>\n {t(\"Free text\")}\n </Typography>\n </div>\n }\n ];\n\n const defaultSectionField = new SectionFieldModel();\n const defaultControlTypeFieldItems: SectionFieldItemModel[] = [\n new SectionFieldItemModel({ id: 1, name: t(\"Option\") + \" \" + 1, order: 1 }),\n new SectionFieldItemModel({ id: 2, name: t(\"Option\") + \" \" + 2, order: 2 }),\n ];\n defaultSectionField.items = defaultControlTypeFieldItems;\n\n const [nameIsValid, setNameIsValid] = useState<boolean>(isNew ? false : true);\n const [formIsValid, setFormIsValid] = useState<boolean>(false);\n\n const [sectionSelectItems, setSectionSelectItems] = useState<SelectItem[]>([]);\n const [selectedSectionId, setSelectedSectionId] = useState<string>(section.id!);\n\n const [localField, setLocalField] = useState<SectionFieldModel>(isNew ? new SectionFieldModel() : new SectionFieldModel({ ...field, items: field!.items.map(i => ({ ...i })) }));\n const [editingItem, setEditingItem] = useState<SectionFieldItemModel | null>(null);\n const [deletingItem, setDeletingItem] = useState<SectionFieldItemModel | null>(null);\n\n const [deleteConfirmationModalIsOpen, setDeleteConfirmationModalIsOpen] = useState<boolean>(false);\n const [closeConfirmationModalIsOpen, setCloseConfirmationModalIsOpen] = useState<boolean>(false);\n\n const [validationCaller, forceValidation] = useState<number>(-1);\n\n const itemInputRef = useRef<HTMLInputElement>();\n\n const fieldIdStub = localField.id ?? \"fieldId\";\n\n useEffect(() => {\n //when edit and nothing changed\n if (!isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(field, Object.keys(field!).sort())) {\n setFormIsValid(false);\n return;\n }\n //when new and default state and options are default\n if (isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(defaultSectionField, Object.keys(defaultSectionField).sort())\n && localField.type === SectionFieldType.Radio && JSON.stringify(localField.items) === JSON.stringify(defaultControlTypeFieldItems)) {\n setFormIsValid(false);\n return;\n }\n //when <2 items when control component\n if (localField.type === SectionFieldType.Radio && localField.items.length < 2) {\n setFormIsValid(false);\n return;\n }\n //when name isn't valid\n if (!nameIsValid) {\n setFormIsValid(false);\n return;\n }\n\n setFormIsValid(true);\n }, [localField, ...localField.items, validationCaller]);\n\n useEffect(() => {\n if (!isOpen)\n return;\n if (field) {\n const existingFieldCopy = new SectionFieldModel({ ...field, items: field!.items.map(i => ({ ...i })) })\n setLocalField(existingFieldCopy);\n setNameIsValid(true);\n }\n else {\n const newSectionField = new SectionFieldModel();\n newSectionField.items = defaultControlTypeFieldItems.map(i => ({ ...i }));\n setLocalField(newSectionField);\n setNameIsValid(false);\n }\n }, [field, mode, isOpen]);\n\n useEffect(() => {\n if (isNew && localField.type === SectionFieldType.Radio)\n setLocalField({ ...localField, items: defaultControlTypeFieldItems.map(i => ({ ...i })) });\n else if (isNew && localField.type !== SectionFieldType.Radio)\n setLocalField({ ...localField, items: [] })\n else if (!isNew && localField.type === SectionFieldType.Radio && field?.type !== SectionFieldType.Radio)\n setLocalField({ ...localField, items: defaultControlTypeFieldItems.map(i => ({ ...i })), isAdditionalTextareaEnabled: true })\n else if (!isNew && localField.type !== SectionFieldType.Radio && field?.type === SectionFieldType.Radio)\n setLocalField({ ...localField, items: field!.items.map(i => ({ ...i })) })\n }, [localField.type]);\n\n useEffect(() => {\n const selectItems: SelectItem[] = sections.sort((s1, s2) => s1.order! - s2.order!).map((s) => ({\n key: s.id,\n value: t(s.name!, { ns: sectionTNamespace })\n }));\n setSectionSelectItems(selectItems);\n }, [sections]);\n\n useEffect(() => {\n if (editingItem)\n itemInputRef?.current?.focus();\n }, [editingItem]);\n\n const getReorderedFieldItems = (items: SectionFieldItemModel[], prevOrder: number, newOrder: number, movedItemId: string) => {\n const result = Array.from(items);\n\n const positionsMoved = newOrder - prevOrder;\n const isMovedDown = positionsMoved > 0;\n const affectedItemsIds = isMovedDown\n ? items.filter(i => i.id === movedItemId ||\n i.order! <= newOrder &&\n i.order! >= prevOrder)\n .map(i => i.id)\n : items.filter(i => i.id === movedItemId ||\n i.order! >= newOrder &&\n i.order! <= prevOrder)\n .map(i => i.id);\n\n result.forEach(i => {\n if (!affectedItemsIds.includes(i.id!))\n return;\n if (i.order.toString() === movedItemId) {\n i.order = newOrder;\n return;\n }\n i.order = isMovedDown ? i.order! - 1 : i.order! + 1;\n });\n\n return result;\n };\n\n const handleOnClose = () => {\n setOpen(false);\n setNameIsValid(false);\n setFormIsValid(false);\n setCloseConfirmationModalIsOpen(false);\n };\n\n const handleAddButtonClick = async () => {\n if (!nameIsValid)\n return;\n\n await onSave(localField, selectedSectionId);\n handleOnClose();\n };\n\n const tryClose = () => {\n if (!isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(field, Object.keys(field!).sort())) {\n handleOnClose();\n return;\n }\n if (isNew && JSON.stringify(localField, Object.keys(localField).sort()) === JSON.stringify(defaultSectionField, Object.keys(defaultSectionField).sort())) {\n handleOnClose();\n return;\n }\n setCloseConfirmationModalIsOpen(true);\n };\n\n const handleNewItemButtonClick = () => {\n const newItems = Array.from(localField.items);\n const lastItemOrder = newItems.length;\n newItems.push(new SectionFieldItemModel({\n id: lastItemOrder + 1,\n name: t(\"Option\") + \" \" + (lastItemOrder + 1).toString(),\n order: lastItemOrder + 1\n }));\n\n setLocalField({ ...localField, items: newItems });\n };\n\n const handleItemEditClicked = (item: SectionFieldItemModel) => {\n if (editingItem) {\n return;\n }\n const itemCopy = new SectionFieldItemModel({ id: item.id, name: item.name, order: item.order });\n setEditingItem(itemCopy);\n };\n \n function handleItemFocus(event: any) {\n event.target.select();\n }\n \n function handleItemKeyDown(event: any) {\n if (event.keyCode === 13)\n event.target.blur();\n }\n \n function handleItemInputClickAway() {\n handleItemEditBlur()\n }\n\n const handleItemEditBlur = () => {\n if (editingItem!.name.length === 0 || editingItem!.name.length > maxNameLength) {\n setEditingItem(null);\n return;\n }\n\n const updatedItems = Array.from(localField.items);\n const itemToUpdate = updatedItems.find(i => i.id === editingItem?.id)\n if (itemToUpdate && editingItem) {\n itemToUpdate.name = editingItem.name;\n setLocalField({ ...localField, items: updatedItems });\n setEditingItem(null);\n }\n };\n\n const handleItemNameChange = (event: React.ChangeEvent<{ value: string }>) => {\n const name = event.target.value;\n if (name.length > maxNameLength) {\n return;\n }\n\n if (editingItem)\n setEditingItem((prev) => (prev ? {\n ...prev,\n name: name\n } : null));\n };\n\n const handleDeleteItemButtonClicked = (item: SectionFieldItemModel) => {\n const itemToDelete = localField.items.find(i => i.id === item.id)\n if (itemToDelete) {\n setDeletingItem(itemToDelete);\n setDeleteConfirmationModalIsOpen(true);\n }\n };\n\n const handleDeleteItem = (item: SectionFieldItemModel) => {\n const itemOrder = item.order;\n const updatedItems = localField.items.filter(i => i.id !== item.id);\n updatedItems.forEach(i => {\n if (i.order! < itemOrder!)\n return;\n i.order = i.order! - 1;\n });\n\n setLocalField({ ...localField, items: updatedItems });\n setDeletingItem(null);\n setDeleteConfirmationModalIsOpen(false);\n };\n\n const handleNameChange = (event: React.ChangeEvent<{ value: string }>) => {\n const newName = event.target.value;\n if (newName.length > maxNameLength || newName.trim().length == 0) {\n setNameIsValid(false);\n setLocalField((prev) => ({\n ...prev,\n name: newName\n }));\n return;\n }\n\n setLocalField((prev) => ({\n ...prev,\n name: newName\n }));\n setNameIsValid(true);\n };\n\n const dragEndHandler = async (result: DropResult) => {\n const { destination, source, draggableId } = result;\n\n //dropped not at droppable\n if (!destination)\n return;\n\n //dropped at other item list\n if (destination.droppableId !== source.droppableId)\n return;\n\n //dropped at the same spot\n if (destination.droppableId === source.droppableId && destination.index === source.index)\n return;\n\n const prevOrder = source.index + 1;\n const newOrder = destination.index + 1;\n\n localField.items = getReorderedFieldItems(localField.items, prevOrder, newOrder, draggableId);\n forceValidation(Math.random());\n };\n\n const getItemIcon = (fieldType: SectionFieldType) => {\n switch (fieldType) {\n case SectionFieldType.Radio:\n return <SectionFieldRadioItemIcon />;\n default:\n return <></>;\n }\n };\n\n const getInnerItemContent = (item: SectionFieldItemModel) => {\n return <>\n {editingItem && editingItem.id === item.id\n ?\n <ClickAwayListener onClickAway={handleItemInputClickAway}>\n <div className={classes.innerItemContentContainer}>\n <Input\n inputClass={classes.itemEditNameInput}\n value={t(editingItem.name, { ns: sectionTNamespace })}\n isValid={() => { return editingItem.name.length > 0 && editingItem.name.length <= maxNameLength }}\n onChange={(event) => handleItemNameChange(event)}\n onFocus={(event: any) => handleItemFocus(event)}\n onKeyDown={(event: any) => handleItemKeyDown(event)}\n onBlur={() => handleItemEditBlur()}\n disabled={!editingItem || !localField.isEditable}\n maxLength={maxNameLength}\n width={500}\n ref={itemInputRef}\n autoFocus\n />\n </div>\n </ClickAwayListener>\n :\n <div\n className={classes.innerItemContentContainer}\n onClick={() => handleItemEditClicked(item)}\n >\n {getItemIcon(localField.type)}\n <Typography className={classes.itemNameLabel}>\n {t(item.name!, { ns: sectionTNamespace })}\n </Typography>\n </div>}\n </>\n };\n\n const mapItemsToComponents = (items: SectionFieldItemModel[]) => {\n return items.sort((i1, i2) => i1.order! - i2.order!).map(i =>\n <div onClick={() => handleItemEditClicked(i)}>\n <DraggableBase\n key={i.order!.toString()}\n className={classes.draggableClassName}\n height={48}\n draggableId={i.order!.toString()}\n index={i.order! - 1}\n isEditable={true}\n isEditableByButton={false}\n isRemovable={true}\n onEditClick={() => { }}\n onDeleteClick={() => { handleDeleteItemButtonClicked(i) }}\n >\n {getInnerItemContent(i)}\n </DraggableBase>\n </div>\n )\n };\n\n const DeleteModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete item response?\")}\n </Typography>\n </div>);\n };\n\n const CloseModalContent: React.FC = () => {\n return (<div className={classes.closeModalContentContainer}>\n <Typography className={classes.closeModalTitleText}>\n {isNew\n ? t(\"Are you sure you want to cancel the creation of the new item?\")\n : t(\"Are you sure you want to cancel the edition of the item?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.closeModalContentText}>\n {t(\"The changes made will not be saved\")}\n </Typography>\n </div>);\n };\n\n return <>\n <Modal\n aria-labelledby=\"transition-modal-title\"\n aria-describedby=\"transition-modal-description\"\n className={classes.modal}\n open={isOpen}\n onClose={tryClose}\n closeAfterTransition\n BackdropComponent={Backdrop}\n BackdropProps={{\n timeout: 500,\n }} >\n <Fade in={isOpen}>\n <div className={classes.paper}>\n <div className={classes.modalHeader}>\n <div className={classes.modalTitle}>\n {isNew\n ? <>\n <SectionFieldNewIcon />\n <Typography className={classes.modalTitleText}>\n {t(\"New item\")}\n </Typography>\n </>\n : <>\n <SectionEditIcon fill={Color.gray5} />\n <Typography className={classes.modalTitleText}>\n {t(\"Edit item\")}\n </Typography>\n </>}\n\n </div>\n <div className={classes.modalActions}>\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t\t backgroundOrBorderColor={ButtonPropsColor.Gray1}\n innerText={t(\"Go back\")}\n onClick={tryClose}\n />\n <ButtonWithSpinner\n width={200}\n borderRadius={ButtonPropsBorderRadius.Large}\n\t\t \t backgroundOrBorderColor={ButtonPropsColor.Green}\n innerText={isNew ? t(\"Add\") : t(\"Save changes\")}\n onClick={handleAddButtonClick}\n\t\t \t disabled={!formIsValid}\n />\n </div>\n </div>\n <div className={classes.scrollbarWrapper}>\n <div className={classes.content}>\n <div className={classes.contentRowContainer}>\n <InputWithLabel\n label={() => (<>{t(\"Name\")} <span className={classes.requiredAsterisk}>*</span></>)}\n placeholder={t(\"Enter the name of the item\")}\n value={t(localField.name, { ns: sectionTNamespace })}\n width={isNew ? 305 : 637}\n name=\"name\"\n onChange={(e) => handleNameChange(e)}\n isValid={() => true}\n />\n {isNew\n ? <SelectWithLabel\n label={() => (<>{t(\"Add to\")} <span className={classes.requiredAsterisk}>*</span></>)}\n items={sectionSelectItems}\n value={selectedSectionId}\n name={\"sections\"}\n width={305}\n isValid={() => true}\n onChange={(event) => setSelectedSectionId(event.target.value)} />\n : <></>}\n\n </div>\n <div className={classes.contentRowContainer}>\n <SelectWithLabel\n label={() => (<>{t(\"Type\")} <span className={classes.requiredAsterisk}>*</span></>)}\n items={fieldTypeSelectItems}\n value={localField.type}\n name={\"fieldTypes\"}\n width={305}\n isValid={() => true}\n onChange={(event) => setLocalField((prev) => ({\n ...prev,\n type: event.target.value\n }))} />\n {localField.type === SectionFieldType.Radio\n ? <SwitchWithLabel\n value={localField.isAdditionalTextareaEnabled}\n setValue={(value) => setLocalField((prev) => ({\n ...prev,\n isAdditionalTextareaEnabled: value\n }))}\n label={t(\"Add free text area at the end\")}\n />\n : <></>}\n </div>\n {localField.type === SectionFieldType.Radio\n ? <>\n <div className={classes.contentRowContainer}>\n <DragDropContext onDragEnd={dragEndHandler}>\n <Droppable key={fieldIdStub} droppableId={fieldIdStub}>\n {(provided) => (\n <Box style={{ width: \"100%\" }}>\n <div className={classes.fieldItemsContainer} >\n <Grid\n container\n justifyContent=\"center\"\n className={classes.fieldItemsLayout}\n ref={provided.innerRef}\n {...provided.droppableProps}\n >\n {mapItemsToComponents(localField.items)}\n {provided.placeholder}\n </Grid>\n </div>\n </Box>\n )}\n </Droppable>\n </DragDropContext>\n </div>\n <div className={classes.contentRowContainer}>\n <Button\n className={classes.addItemButton}\n onClick={handleNewItemButtonClick}\n >\n <PlusIcon style={{ paddingRight: 10 }} />\n {t(\"Add another option\")}\n </Button>\n </div>\n </>\n : <></>}\n <div className={classes.contentRowContainer}>\n <SwitchWithLabel\n value={localField.isRequired}\n setValue={(value) => setLocalField((prev) => ({\n ...prev,\n isRequired: value\n }))}\n label={t(\"Required\")} />\n </div>\n </div>\n </div>\n </div>\n </Fade>\n </Modal>\n <ConfirmActionModal\n classModal={classes.closeConfirmationModal}\n content={<CloseModalContent />}\n open={closeConfirmationModalIsOpen}\n onClose={() => setCloseConfirmationModalIsOpen(false)}\n onConfirm={handleOnClose}\n />\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteConfirmationModalIsOpen}\n item={deletingItem}\n componentInfo={<DeleteModalContent />}\n onClose={() => { setDeleteConfirmationModalIsOpen(false); setDeletingItem(null); }}\n onDelete={() => deletingItem && handleDeleteItem(deletingItem)}\n />\n </>\n};","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\n\nimport { SectionProps } from \"./props\";\nimport useStyles from \"./css\";\n\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionFieldCreateRequest } from \"../../../../../models/section-field-create-request\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport { SectionFieldItemModel } from \"../../../../../models/section-field-item-model\";\nimport { SectionFieldUpdateRequest } from \"../../../../../models/section-field-update-request\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\n\nimport { Box, Button, Grid, Typography } from \"@material-ui/core\";\nimport { SectionArrowIcon, SectionDeleteIcon, SectionEditIcon, SectionExitEditIcon, SectionFieldNewIcon, SectionSaveIcon } from \"../../../../../assets/icons\";\nimport FieldList from \"../FieldList\";\nimport ConfirmDeleteModal from \"../../../../common/ConfirmDeleteModal\";\nimport SectionFieldModal from \"../SectionFieldModal\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport Input from \"../../../../common/Input\";\nimport { SectionFieldDeleteRequest } from \"../../../../../models/section-field-delete-request\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default function Section(props: SectionProps) {\n const sectionTNamespace = \"sections\";\n const maxTextFieldLength = 200;\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { accountId, section, sections, setSection, onEdit, onDelete, onMoveDown, onMoveUp } = props;\n const classes = useStyles();\n\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n\n const sectionInputRef = useRef<HTMLInputElement>();\n\n const [deleteSectionConfirmationModalIsOpen, setDeleteSectionConfirmationModalIsOpen] = useState<boolean>(false);\n const [sectionFieldModalIsOpen, setSectionFieldModalIsOpen] = useState<boolean>(false);\n const [headerHover, setHeaderHover] = useState<boolean>(false);\n const [deleteFieldConfirmationModalIsOpen, setDeleteFieldConfirmationModalIsOpen] = useState<boolean>(false);\n\n const [fieldMode, setFieldMode] = useState<\"new\" | \"edit\">(\"new\");\n const [isSectionEditMode, setSectionEditMode] = useState<boolean>(false);\n\n const [modalField, setModalField] = useState<SectionFieldModel | undefined>(undefined);\n const [deleteModalField, setDeleteModalField] = useState<SectionFieldModel | undefined>(undefined);\n\n const [name, setName] = useState<string>(section.name!);\n\n useEffect(() => {\n if (section.name)\n setName(section.name);\n }, [section]);\n\n useEffect(() => {\n if (isSectionEditMode)\n sectionInputRef?.current?.focus();\n }, [isSectionEditMode]);\n\n const handleEditButtonClick = () => {\n setSectionEditMode(true);\n }\n\n const handleDeleteSection = (section: SectionModel) => {\n setDeleteSectionConfirmationModalIsOpen(false);\n if (onDelete)\n onDelete(section);\n }\n\n const handleNewFieldButtonClick = () => {\n setFieldMode(\"new\");\n setModalField(undefined);\n setSectionFieldModalIsOpen(true);\n };\n\n const handleEditFieldClick = (fieldId: string) => {\n const selectedField = section.fields.filter(f => f.id === fieldId)[0];\n setFieldMode(\"edit\");\n setModalField(selectedField);\n setSectionFieldModalIsOpen(true);\n };\n\n const handleDeleteFieldClick = (fieldId: string) => {\n const fieldToDelete = section.fields.filter(f => f.id === fieldId)[0];\n setDeleteModalField(fieldToDelete);\n setDeleteFieldConfirmationModalIsOpen(true);\n }\n\n const handleOnChange = (event: React.ChangeEvent<{ value: string }>) => {\n const name = event.target.value;\n if (name.length > maxTextFieldLength) {\n return;\n }\n setName(name);\n };\n\n const handleEditSection = async () => {\n if (!onEdit)\n return;\n setSectionEditMode(false);\n if (section.name === name.trim() || name.trim().length === 0) {\n setName(section.name!);\n return;\n }\n section.name = name;\n await onEdit(section);\n };\n\n const handleSectionFieldSave = async (newField: SectionFieldModel, sectionIdToSave: string) => {\n if (!sections || !setSection)\n return;\n\n const sectionToSave = sections.filter(s => s.id === sectionIdToSave)[0];\n \n if (!sectionToSave)\n return;\n\n let sectionFields = [...sectionToSave.fields];\n\n if (fieldMode === \"new\") {\n const response = await SettingsPatientFormsService.createSectionField(new SectionFieldCreateRequest({\n establishmentAccountId: accountId,\n sectionId: sectionToSave.id,\n name: newField.name,\n type: newField.type,\n isRequired: newField.isRequired,\n isAdditionalTextareaEnabled: newField.type === SectionFieldType.Radio\n ? newField.isAdditionalTextareaEnabled\n : false,\n itemsNames: newField.items.sort((i1, i2) => i1.order - i2.order).map(i => i.name)\n }));\n\n if (!response)\n return;\n\n const afterResponseField = { ...newField }\n afterResponseField.id = response.id\n afterResponseField.order = sectionToSave.fields.length + 1;\n afterResponseField.isAdditionalTextareaEnabled = afterResponseField.type === SectionFieldType.Radio\n ? afterResponseField.isAdditionalTextareaEnabled\n : false;\n\n for (let i = 0; i < response.fieldItemIds.length; i++) {\n afterResponseField.items[i].id = response.fieldItemIds[i];\n }\n\n sectionFields.push(afterResponseField);\n }\n else {\n const response = await SettingsPatientFormsService.updateSectionField(new SectionFieldUpdateRequest({\n establishmentAccountId: accountId,\n id: newField.id,\n sectionId: sectionToSave.id,\n name: newField.name,\n type: newField.type,\n isRequired: newField.isRequired,\n isAdditionalTextareaEnabled: newField.type === SectionFieldType.Radio\n ? newField.isAdditionalTextareaEnabled\n : false,\n items: newField.items.sort((i1, i2) => i1.order - i2.order).map(i => new SectionFieldItemModel({\n id: i.id?.length === 36 ? i.id : null, //is guid?\n name: i.name,\n order: i.order\n }))\n }));\n\n if (!response)\n return;\n\n for (let i = 0; i < response.fieldItemIds.length; i++) {\n newField.items[i].id = response.fieldItemIds[i];\n }\n\n newField.isAdditionalTextareaEnabled = newField.type === SectionFieldType.Radio\n ? newField.isAdditionalTextareaEnabled\n : false;\n const fieldIndexToUpdate = sectionFields.findIndex(i => i.id === newField.id);\n sectionFields[fieldIndexToUpdate] = newField;\n }\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: fieldMode === \"new\" ? t(\"Item created\") : t(\"Item edited\"),\n description: t(newField.name, { ns: sectionTNamespace })\n })\n );\n\n sectionFields = sectionFields.sort((f1, f2) => f1.order - f2.order)\n setSection({ ...sectionToSave, fields: sectionFields })\n }\n\n const handleSectionFieldDelete = async (field: SectionFieldModel) => {\n if (!setSection)\n return;\n \n const sectionFields = [...section.fields];\n const fieldIndexToDelete = sectionFields.findIndex(i => i.id === field.id);\n\n if (fieldIndexToDelete === -1)\n return;\n\n const isSuccessful = await SettingsPatientFormsService.deleteSectionField(new SectionFieldDeleteRequest({\n establishmentAccountId: accountId,\n id: field.id,\n sectionId: section.id,\n order: field.order\n }));\n\n if (!isSuccessful)\n return;\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Item deleted\"),\n description: t(field.name, { ns: sectionTNamespace })\n })\n );\n\n let updatedSectionFields = sectionFields.filter((_, i) => i !== fieldIndexToDelete);\n updatedSectionFields = updatedSectionFields.sort((f1, f2) => f1.order - f2.order)\n setSection({ ...section, fields: updatedSectionFields })\n\n setDeleteModalField(undefined);\n setDeleteFieldConfirmationModalIsOpen(false);\n }\n\n const handleExitEdit = () => {\n setName(section.name!);\n setSectionEditMode(false);\n }\n\n const getTabName = (sectionType: SectionType) => {\n switch (sectionType) {\n case SectionType.ClinicHistory:\n return t(\"of the Clinic history\");\n case SectionType.VitalSigns:\n return t(\"of the Evolution notes\");\n case SectionType.PatientForm:\n return t(\"of the Patient form\");\n }\n }\n\n const getEditButton = (section: SectionModel) => {\n if (section.isEditable)\n return (<Button\n key={\"editButton\"}\n onClick={() => handleEditButtonClick()}\n className={classes.headerButton}\n >\n <SectionEditIcon />\n </Button>);\n return <></>;\n };\n\n const getSaveButton = (section: SectionModel) => {\n if (section.isEditable && isSectionEditMode)\n return (<Button\n key={\"saveButton\"}\n onClick={async () => await handleEditSection()}\n className={classes.headerButton}\n >\n <SectionSaveIcon />\n </Button>);\n return <></>;\n };\n\n const getExitEditButton = (section: SectionModel) => {\n if (section.isEditable && isSectionEditMode)\n return (<Button\n onMouseDown={() => handleExitEdit()}\n className={classes.headerButton}\n >\n <SectionExitEditIcon />\n </Button>);\n return <></>;\n };\n\n const getDeleteSectionButton = (section: SectionModel) => {\n if (section.isRemovable && section.type !== SectionType.VitalSigns)\n return (<Button\n onClick={() => setDeleteSectionConfirmationModalIsOpen(true)}\n className={classes.headerButton}\n >\n <SectionDeleteIcon />\n </Button>);\n return <></>;\n };\n\n const getMoveDownButton = (section: SectionModel) => {\n if (onMoveDown && section.type !== SectionType.VitalSigns) {\n const isDisabled = section.order === sections?.length ?? 0;\n return (<Button\n onClick={() => onMoveDown && onMoveDown()}\n disabled={section.order === sections?.length ?? 0}\n className={isDisabled ? classes.headerButtonDisabled : classes.headerButton}\n >\n <SectionArrowIcon />\n </Button>);\n }\n return <></>;\n };\n\n const getMoveUpButton = (section: SectionModel) => {\n if (onMoveUp && section.type !== SectionType.VitalSigns) {\n const isDisabled = section.order === 1;\n return (<Button\n onClick={() => onMoveUp && onMoveUp()}\n disabled={isDisabled}\n className={isDisabled ? classes.headerButtonDisabled : classes.headerButton}\n >\n <SectionArrowIcon style={{ transform: \"rotate(180deg)\" }} />\n </Button>);\n }\n return <></>;\n };\n\n const getHeaderButtons = (section: SectionModel) => {\n if (isSectionEditMode) {\n return (\n <>\n {getSaveButton(section)}\n {getExitEditButton(section)}\n </>\n );\n }\n return (\n <>\n {getEditButton(section)}\n {getDeleteSectionButton(section)}\n {getMoveDownButton(section)}\n {getMoveUpButton(section)}\n </>\n );\n };\n\n const getSectionFooterComponent = (section: SectionModel) => {\n if (section.isEditable) {\n return <Grid item className={classes.footerContainer}>\n <ButtonWithSpinner\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New item\")}\n innerIcon={<SectionFieldNewIcon />}\n onClick={handleNewFieldButtonClick}\n />\n </Grid>\n }\n\n return <></>\n }\n \n const getSectionContent = (section: SectionModel) => {\n if (section.fields.length === 0)\n return (\n <div className={classes.noItemsBox}>\n <Typography className={classes.noItemsLabel}>\n {t(\"Section without items\")}\n </Typography>\n </div>);\n else\n return (<FieldList\n accountId={accountId}\n section={section}\n onEditClick={handleEditFieldClick}\n onDeleteClick={handleDeleteFieldClick}\n />)\n };\n\n const DeleteSectionModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete this section\") + \" \" + getTabName(section.type!) + \"?\"}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentBoldText}>\n {t(section.name!, { ns: sectionTNamespace })}\n </Typography>\n </div>);\n };\n\n const DeleteFieldModalContent: React.FC = () => {\n return (<div className={classes.deleteModalContentContainer}>\n <Typography className={classes.deleteModalTitleText}>\n {t(\"Delete this item?\")}\n </Typography>\n <div className={classes.separator} />\n <Typography className={classes.deleteModalContentText}>\n {t(\"Delete the\") + \" \"}\n <span className={classes.deleteModalContentBoldText}>\n {\"\\\"\" + t(deleteModalField?.name ?? \"\", { ns: sectionTNamespace }) + \"\\\"\"}\n </span>\n {\" \" + t(\"item from the\") + \" \"}\n <span className={classes.deleteModalContentBoldText}>\n {\"\\\"\" + t(section.name!, { ns: sectionTNamespace }) + \"\\\"\" + \"?\"}\n </span>\n </Typography>\n </div>);\n };\n\n return <>\n <div className={classes.root}>\n <Box>\n <Grid container justifyContent=\"center\" className={classes.sectionContainer}>\n <Grid item\n className={classes.headerContainer}\n onMouseEnter={() => { setHeaderHover(true) }}\n onMouseLeave={() => { setHeaderHover(false) }} >\n {!isSectionEditMode\n ? <Typography className={classes.headerTitle}>\n {t(section.name!, { ns: sectionTNamespace })}\n </Typography>\n\n : <Input\n inputClass={classes.sectionEditNameInput}\n value={t(name, { ns: sectionTNamespace })}\n isValid={() => { return name.trim().length > 0 && name.length <= 200 }}\n onChange={(event) => handleOnChange(event)}\n onBlur={async () => await handleEditSection()}\n disabled={!isSectionEditMode || !section.isEditable}\n maxLength={maxTextFieldLength}\n width={\"91%\"}\n ref={sectionInputRef}\n autoFocus\n />}\n {headerHover || isSectionEditMode\n ? <div className={classes.headerButtonsContainer}>\n {getHeaderButtons(section)}\n </div>\n : <></>}\n </Grid>\n <div className={classes.innerLayout}>\n <Grid item className={classes.fieldsContainer}>\n {getSectionContent(section)}\n </Grid>\n {getSectionFooterComponent(section)}\n </div>\n </Grid>\n </Box>\n </div>\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteSectionConfirmationModalIsOpen}\n item={section}\n componentInfo={<DeleteSectionModalContent />}\n onClose={() => setDeleteSectionConfirmationModalIsOpen(false)}\n onDelete={() => handleDeleteSection(section)}\n />\n <ConfirmDeleteModal\n classModal={classes.deleteConfirmationModal}\n open={deleteFieldConfirmationModalIsOpen}\n item={deleteModalField}\n componentInfo={<DeleteFieldModalContent />}\n onClose={() => setDeleteFieldConfirmationModalIsOpen(false)}\n onDelete={async () => await handleSectionFieldDelete(deleteModalField!)}\n />\n <SectionFieldModal\n isOpen={sectionFieldModalIsOpen}\n setOpen={setSectionFieldModalIsOpen}\n mode={fieldMode}\n field={modalField}\n section={section}\n sections={sections ?? []}\n onSave={async (newField, sectionIdToSave) => await handleSectionFieldSave(newField, sectionIdToSave)} />\n </>\n\n};","import React, { forwardRef, useEffect, useImperativeHandle } from \"react\";\nimport { useAppDispatch } from \"../../../../../redux/hooks\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { SectionListProps } from \"./props\";\nimport SectionListRefs from \"./section-list-refs\";\nimport useStyles from \"./css\";\n\nimport Section from \"../Section\";\n\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport { SectionUpdateRequest } from \"../../../../../models/section-update-request\";\nimport { SectionDeleteRequest } from \"../../../../../models/section-delete-request\";\nimport { SectionCreateRequest } from \"../../../../../models/section-create-request\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\n\n\nconst SectionList = forwardRef<SectionListRefs, any>((props: SectionListProps, ref) => {\n const { accountId, sectionType, sections, setSections } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n const { t } = useTranslation([\"general\"]);\n\n //to make the \"createSection\" function callable from the parent component\n useImperativeHandle(ref, () => ({\n createSection: async (name: string) => {\n const resultId = await SettingsPatientFormsService.createSection(new SectionCreateRequest({\n establishmentAccountId: accountId,\n type: sectionType,\n name: name,\n }));\n\n const newSections = [...sections];\n newSections.forEach(s => {\n s.order = s.order! + 1;\n });\n\n newSections.push(new SectionModel({\n id: resultId,\n name: name,\n order: 1,\n type: sectionType,\n fields: [],\n isEditable: true,\n isRemovable: true\n }));\n\n setSections(newSections);\n\n dispatch(\n enqueueAlert({\n type: \"Success\",\n title: t(\"Section created\"),\n description: name\n })\n );\n }\n }));\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n dispatch(navbarActions.setShowLoader(false));\n }\n fetchData();\n }, []);\n\n const handleEditSection = async (section: SectionModel) => {\n await SettingsPatientFormsService.updateSection(new SectionUpdateRequest({\n establishmentAccountId: accountId,\n id: section.id,\n type: section.type,\n newName: section.name,\n newOrder: section.order,\n previousOrder: null\n }))\n .then(() => {\n setSection(section)\n })\n };\n\n const handleDeleteSection = async (section: SectionModel) => {\n const sectionOrder = section.order;\n await SettingsPatientFormsService.deleteSection(new SectionDeleteRequest({\n establishmentAccountId: accountId,\n id: section.id,\n type: sectionType,\n order: sectionOrder\n }));\n\n const updatedSections = sections.filter(s => s.id !== section.id);\n\n updatedSections.forEach(s => {\n if (s.order! < sectionOrder!)\n return;\n s.order = s.order! - 1;\n });\n\n setSections(updatedSections);\n };\n\n const handleMove = async (sectionId: string, isUp: boolean) => {\n const step = isUp ? -1 : 1;\n const targetSection = sections.find(s => s.id === sectionId);\n const targetSectionIndex = sections.findIndex(s => s.id === sectionId);\n const pairedSectionIndex = sections.findIndex(s => s.order === targetSection!.order! + step);\n\n const newSections = [...sections];\n newSections[pairedSectionIndex].order = targetSection!.order!;\n newSections[targetSectionIndex].order = targetSection!.order! + step;\n setSections(newSections);\n\n await SettingsPatientFormsService.updateSection(new SectionUpdateRequest({\n establishmentAccountId: accountId,\n id: targetSection!.id!,\n type: sectionType,\n newName: targetSection!.name!,\n newOrder: targetSection?.order,\n previousOrder: targetSection!.order! - step\n }));\n };\n\n const setSection = (section: SectionModel) => {\n const targetSection = sections.find(s => s.id === section.id);\n if (!targetSection)\n return;\n\n const targetSectionIndex = sections.findIndex(s => s.id === section.id);\n const updatedSections = [...sections];\n\n updatedSections[targetSectionIndex].fields = [...section.fields];\n\n setSections(updatedSections);\n };\n\n const loadData = async () => {\n const sectionsData =\n await SettingsPatientFormsService.getAccountSettingsTabSections(sectionType, accountId);\n setSections(sectionsData);\n };\n\n const mapSections = () => {\n return sections.sort((s1, s2) => s1.order! - s2.order!).map(s =>\n <Section\n accountId={accountId}\n key={s.id!}\n section={s}\n sections={sections}\n setSection={(updatedSection) => setSection(updatedSection)}\n onEdit={async () => { await handleEditSection(s) }}\n onDelete={async () => { await handleDeleteSection(s) }}\n onMoveDown={async () => { await handleMove(s.id!, false) }}\n onMoveUp={async () => { await handleMove(s.id!, true) }} />)\n };\n\n return <div className={classes.sectionsContainer}>\n {mapSections()}\n </div>\n});\n\nexport default SectionList;","export class CopyEstablishmentSettingsModel {\n fromEstablishmentAccountId: string;\n toEstablishmentAccountIds: string[];\n\n constructor(fromEstablishmentAccountId: string, toEstablishmentAccountIds: string[]) {\n this.fromEstablishmentAccountId = fromEstablishmentAccountId;\n this.toEstablishmentAccountIds = toEstablishmentAccountIds;\n }\n}","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n backdrop: {\n opacity: 0,\n visibility : \"hidden\",\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"center\",\n backgroundColor: \"rgba(0, 0, 0, 0.5)\",\n position: \"fixed\",\n top: 0,\n left: 0,\n right: 0,\n bottom: 0,\n zIndex: 10000,\n transition: \"all 500ms cubic-bezier(0.4, 0, 0.2, 1) 0ms\",\n \"&>p\": {\n color: theme.colors.white,\n fontSize: 18,\n fontWeight: 700,\n fontFamily: \"Inter, sans-serif\"\n }\n },\n fadeIn: {\n visibility: \"visible\",\n opacity: 1,\n }\n })\n);\n\nexport default useStyles;","import React from \"react\";\n\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"@material-ui/core/Typography\";\n\nimport useStyles from \"./css\";\nimport { BackdropProps } from \"./props\";\n\n\nexport default function Backdrop(props: BackdropProps) {\n\n const { show, text } = props;\n\n const classes = useStyles();\n\n \n return (\n <>\n \n <div className={`${classes.backdrop} ${show ? classes.fadeIn : \"\"}`}>\n <Typography>{text}</Typography>\n </div>\n \n </>\n );\n}","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { ClinicHistoryProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { InfoIcon, SectionNewIcon } from \"../../../../../assets/icons\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport SectionNewModal from \"../SectionNewModal\";\nimport SectionList from \"../SectionList\";\nimport SectionListRefs from \"../SectionList/section-list-refs\";\nimport SwitchWithLabel from \"../../../../common/SwitchWithLabel\";\nimport IconTooltip from \"../../../../common/IconTooltip\";\nimport { ClinicalHistoryCommunicationSettingsService } from \"../../../../../api/service-сlinical-history-communication-settings\";\nimport { ClinicalHistoryCommunicationSettings } from \"../../../../../models/clinical-history-communication-settings-model\";\nimport { ClinicalHistoryCommunicationSettingType } from \"../../../../../models/enums/clinical-history-communication-setting-type\";\nimport { Editor } from \"@tinymce/tinymce-react\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../../redux/store\";\nimport Select from \"../../../../common/Select\";\nimport { LocalStorageKey } from \"../../../../../constants/local-storage-key\";\nimport CopyIcon from \"../../../../../assets/icons/CopyIcon\";\nimport MultiSelect from \"../../../../common/MultiSelect\";\nimport { CopyEstablishmentSettingsModel } from \"../../../../../models/copy-establishment-settings-model\";\nimport Backdrop from \"../../../../common/Backdrop\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport SectionNote from \"../SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default function ClinicHistory(props: ClinicHistoryProps) {\n \n const { t } = useTranslation([\"general\"]);\n const {settingsSelectedEstablishmentId} = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const currentTabSectionType = SectionType.ClinicHistory;\n const maxTextLength: number = 25000;\n const [currentEstablishmentId, setCurrentEstablishmentId] = useState<string|null|undefined>(undefined);\n const [copyToEstablishments, setCopyToEstablishments] = useState<string[]>([]);\n const [isCopyMode, setIsCopyMode] = useState<boolean>(false);\n const [isCopying, setIsCopying] = useState<boolean>(false);\n const [sections, setSections] = useState<SectionModel[]>([]);\n const [newSectionModalIsOpen, setNewSectionModalIsOpen] = useState<boolean>(false);\n const [entity, setEntity] = useState<ClinicalHistoryCommunicationSettings>(new ClinicalHistoryCommunicationSettings());\n const [focusedPrivacyNotice, setFocusedPrivacyNotice] = useState<boolean>(false);\n const [focusedConsentLetter, setFocusedConsentLetter] = useState<boolean>(false);\n const [textLengthPrivacyNotice, setTextLengthPrivacyNotice] = useState<number>(0);\n const [textLengthConsentLetter, setTextLengthConsentLetter] = useState<number>(0);\n const [originalPrivacyNoticeValue, setOriginalPrivacyNoticeValue] = useState<string>(\"\");\n const [originalConsentLetterValue, setOriginalConsentLetterValue] = useState<string>(\"\");\n const accountSettings = useAppSelector(selectAccountSettings);\n const { enqueueAlert } = alertsActions;\n \n const sectionListRef = useRef<SectionListRefs>(null);\n\n const userInfo = useAppSelector(selectUserInfo);\n const [enterpriseSelected, setEnterpriseSelected] = useState<boolean>(false);\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n await loadClinicalHistoryCommunicationSettings();\n dispatch(navbarActions.setShowLoader(false));\n }\n if (currentEstablishmentId !== undefined){\n void fetchData();\n }\n }, [currentEstablishmentId]);\n \n useEffect(() => {\n const enterpriseSelected = userInfo.accountId === settingsSelectedEstablishmentId;\n setEnterpriseSelected(enterpriseSelected);\n if (settingsSelectedEstablishmentId && !enterpriseSelected) \n setCurrentEstablishmentId(settingsSelectedEstablishmentId);\n else{\n if (accountSettings?.establishments?.length){\n setCurrentEstablishmentId(accountSettings.establishments[0].key)\n } else {\n setCurrentEstablishmentId(null);\n }\n }\n }, [settingsSelectedEstablishmentId, accountSettings.establishments]);\n \n const copyToEstablishmentsItems = () => {\n return accountSettings.establishments.filter(x => x.key !== currentEstablishmentId);\n }\n \n const handleCreateSection = async (name: string) => {\n await sectionListRef?.current?.createSection(name);\n }\n \n const loadData = async () => {\n const sectionsData = await SettingsPatientFormsService.getAccountSettingsTabSections(currentTabSectionType, currentEstablishmentId);\n setSections(sectionsData);\n };\n\n const setPrivacyNoticeTextLength = (evt: any, editor: any) => {\n setTextLengthPrivacyNotice(editor.getContent({ format: \"text\" }).length);\n };\n const setConsentLetterTextLength = (evt: any, editor: any) => {\n setTextLengthConsentLetter(editor.getContent({ format: \"text\" }).length);\n };\n const updatePrivacyNotice = async () => {\n setFocusedPrivacyNotice(false);\n if (entity.privacyNotice != originalPrivacyNoticeValue) {\n await saveClinicalHistoryCommunicationSettings(entity);\n setOriginalPrivacyNoticeValue(entity.privacyNotice);\n }\n \n };\n const updateConsentLetter = async () => {\n setFocusedConsentLetter(false);\n if (entity.consentLetter != originalConsentLetterValue) {\n await saveClinicalHistoryCommunicationSettings(entity);\n setOriginalConsentLetterValue(entity.consentLetter);\n }\n };\n \n const handleEditorPrivacyNoticeChange = async (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n \n if (contentText.length <= maxTextLength) {\n let updating: ClinicalHistoryCommunicationSettings;\n updating = {\n ...entity,\n privacyNotice: contentHtml\n };\n setEntity(updating);\n setTextLengthPrivacyNotice(contentText.length);\n }\n }\n \n const handleEditorConsentLetterChange = async (c: string, editor: any) => {\n const contentText = editor.getContent({ format: \"text\" });\n const contentHtml = editor.getContent();\n if (contentText.length <= maxTextLength) {\n let updating: ClinicalHistoryCommunicationSettings;\n updating = {\n ...entity,\n consentLetter: contentHtml\n };\n setEntity(updating);\n setTextLengthConsentLetter(contentText.length);\n }\n }\n \n const saveClinicalHistoryCommunicationSettings = async (updating: ClinicalHistoryCommunicationSettings) => {\n const result = await ClinicalHistoryCommunicationSettingsService.updateClinicalHistoryCommunicationSettings(updating);\n if (result) {\n setEntity(result);\n }\n }\n \n const loadClinicalHistoryCommunicationSettings = async () => {\n \n const info = await ClinicalHistoryCommunicationSettingsService.getClinicalHistoryCommunicationSetting(currentEstablishmentId);\n \n const regex = /(<([^>]+)>)/ig;\n \n setTextLengthPrivacyNotice(info.privacyNotice?.replace(regex, \"\").length);\n setTextLengthConsentLetter(info.consentLetter?.replace(regex, \"\").length);\n setOriginalPrivacyNoticeValue(info.privacyNotice);\n setOriginalConsentLetterValue(info.consentLetter);\n setEntity(info);\n }\n \n const handleSetClinicalHistoryCommunicationSettings = async (value: boolean, settingType: ClinicalHistoryCommunicationSettingType) => {\n let updating: ClinicalHistoryCommunicationSettings;\n updating = {\n ...entity\n };\n switch (settingType) {\n case ClinicalHistoryCommunicationSettingType.SendConfirmationToPatientWithoutHistory:\n updating = {\n ...entity,\n sendFormOnConfirmationNoHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.SendReminderToPatientWithoutHistory:\n updating = {\n ...entity,\n sendFormOnReminderNoHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.SendConfirmationToPatient:\n updating = {\n ...entity,\n sendFormOnConfirmationIncompleteHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.SendReminderToPatient:\n updating = {\n ...entity,\n sendFormOnReminderIncompleteHistory: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.ConsentLetterEnable:\n updating = {\n ...entity,\n isConsentLetterEnabled: value\n };\n break;\n case ClinicalHistoryCommunicationSettingType.PrivacyNoticeEnable:\n updating = {\n ...entity,\n isPrivacyNoticeEnabled: value\n };\n break;\n }\n await saveClinicalHistoryCommunicationSettings(updating);\n }\n \n const handleCopyClick = async () => {\n if (isCopyMode) {\n setIsCopying(true);\n await ClinicalHistoryCommunicationSettingsService.copyClinicalHistorySetting(\n new CopyEstablishmentSettingsModel(currentEstablishmentId!, copyToEstablishments));\n setIsCopying(false);\n setIsCopyMode(false);\n dispatch(enqueueAlert({\n type: \"Success\",\n title: t(\"Clinical history copied\"),\n description: t(\"To the selected establishments\")\n }));\n } else {\n setIsCopyMode(true);\n }\n }\n \n const handleSelectEstablishment = (event: any) => {\n setCurrentEstablishmentId(event.target.value);\n }\n \n const handleSaveCopyToEstablishments = (establishments: string[]) => {\n setCopyToEstablishments(establishments);\n }\n \n const getClinicalHistoryCommunicationSettingsContent = () => {\n return <div style={{ paddingBottom: 32 }}>\n <div className={classes.communicationSettingsContainer}>\n <div style={{ padding: 36, display: \"flex\", flexDirection: \"column\" }}>\n <Typography className={classes.communicationSettingsMainTitle}>\n {t(\"Send form by WhatsApp\")}\n </Typography>\n \n <Typography className={classes.communicationSettingsCheckboxGroupTitle}>\n {t(\"To patients without Clinical history\")}\n </Typography>\n <div style={{ marginBottom: 14 }}>\n <SwitchWithLabel\n value={entity.sendFormOnConfirmationNoHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendConfirmationToPatientWithoutHistory)}\n label={t(\"Appointment confirmation\")}\n />\n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form when creating the appointment\")}\n />\n </div>\n <div style={{ marginBottom: 26 }}>\n <SwitchWithLabel\n value={entity.sendFormOnReminderNoHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendReminderToPatientWithoutHistory)}\n label={t(\"Appointment reminder\")}\n />\n \n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form on the appointment reminder\")}\n />\n </div>\n \n <Typography className={classes.communicationSettingsCheckboxGroupTitle}>\n {t(\"To patients with incomplete Clinical history\")}\n </Typography>\n <div style={{ marginBottom: 14 }}>\n <SwitchWithLabel\n value={entity.sendFormOnConfirmationIncompleteHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendConfirmationToPatient)}\n label={t(\"Appointment confirmation\")}\n />\n \n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form when creating the appointment\")}\n />\n </div>\n <div style={{ marginBottom: 31 }}>\n <SwitchWithLabel\n value={entity.sendFormOnReminderIncompleteHistory}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.SendReminderToPatient)}\n label={t(\"Appointment reminder\")}\n />\n \n <IconTooltip\n key={\"cardToolTip\"}\n classNameRoot={classes.iconTooltipRoot}\n placement={\"right\"}\n arrowPlacement={\"left\"}\n icon={<InfoIcon style={{ width: 12, height: 12, marginBottom: 10 }} viewBox={\"0 0 12 12\"}/>}\n tooltipText={t(\"Send the patient form on the appointment reminder\")}\n />\n </div>\n \n <Typography className={classes.mainTitle} style={{ marginBottom: 13 }}>\n {t(\"Privacy notice\")}\n </Typography>\n \n <SwitchWithLabel\n value={entity.isPrivacyNoticeEnabled}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.PrivacyNoticeEnable)}\n label={t(\"Include privacy notice in the form\")}\n />\n <div className={`${classes.tinyMceOverrides} ${focusedPrivacyNotice ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"Write here.\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\"\n }}\n value={entity.privacyNotice}\n onFocusIn={() => setFocusedPrivacyNotice(true)}\n onBlur={updatePrivacyNotice}\n onInit={setPrivacyNoticeTextLength}\n onEditorChange={handleEditorPrivacyNoticeChange}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLengthPrivacyNotice >= maxTextLength) {\n e.preventDefault();\n }\n }}\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{textLengthPrivacyNotice + \"/\" + maxTextLength}</span>\n </div>\n \n </div>\n \n <Typography className={classes.mainTitle} style={{ marginBottom: 13 }}>\n {t(\"Consent letter\")}\n </Typography>\n \n <SwitchWithLabel\n value={entity.isConsentLetterEnabled}\n setValue={(value: boolean) => handleSetClinicalHistoryCommunicationSettings(value,\n ClinicalHistoryCommunicationSettingType.ConsentLetterEnable)}\n label={t(\"Include informed consent letter in the form\")}\n />\n <div className={`${classes.tinyMceOverrides} ${focusedConsentLetter ? classes.tinyMceFocused : classes.tinyMceUnfocused}`}>\n <Editor\n apiKey=\"k8euxnsm83b9ddwer6ard3pp5tb1h1sh4dq0ciqs1q60mo1k\"\n init={{\n height: 160,\n width: \"auto\",\n menubar: false,\n statusbar: false,\n placeholder: t(\"Write here.\"),\n plugins: 'wordcount paste lists',\n toolbar: 'bold italic underline | numlist bullist ',\n content_style: \"body {fontFamily: Inter, sans-serif; font-weight: 400; font-size: 14px; color: #323947 }\",\n entity_encoding: \"raw\",\n formats: {\n bold: { inline: 'b' },\n italic: { inline: 'i' },\n underline: { inline: 'u' }\n },\n paste_as_text: true,\n extended_valid_elements: \"b, i, s\",\n invalid_elements: \"strong, em, span\"\n }}\n value={entity.consentLetter}\n onFocusIn={() => setFocusedConsentLetter(true)}\n onBlur={updateConsentLetter}\n onInit={setConsentLetterTextLength}\n onEditorChange={handleEditorConsentLetterChange}\n outputFormat=\"html\"\n onChange={(e) => {\n if (textLengthConsentLetter >= maxTextLength) {\n e.preventDefault();\n }\n }}\n />\n <div className={classes.counterWrapper}>\n <span className={classes.charCounter}>{textLengthConsentLetter + \"/\" + maxTextLength}</span>\n </div>\n </div>\n </div>\n </div>\n </div>\n };\n \n return <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Clinical history\")}\n </Typography>\n </div>\n {settingsSelectedEstablishmentId && (\n <SectionNote\n sectionData={SectionNoteData.ClinicalHistory}\n />\n )}\n {enterpriseSelected && <>\n <div className={classes.copyControls}>\n <Select\n items={accountSettings.establishments}\n value={currentEstablishmentId}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.select}\n onChange={handleSelectEstablishment}\n />\n {accountSettings.establishments.length > 1 &&\n <>\n {isCopyMode &&\n <MultiSelect\n allItemsPlaceholder={t(\"Copy to all establishments\")}\n filterPlaceholder={t(\"Select destination establishment\")}\n items={copyToEstablishmentsItems()}\n values={copyToEstablishments}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.multiSelect}\n width={250}\n height={372}\n onChange={(x: any) => handleSaveCopyToEstablishments(x)}\n onReset={() => handleSaveCopyToEstablishments([])}\n />\n }\n <Button\n className={classes.copyButton}\n onClick={handleCopyClick}\n >\n <CopyIcon style={{ paddingRight: 5 }} />\n {t(\"Copy clinical history\")}\n </Button>\n <Button\n hidden={!isCopyMode}\n className={classes.cancelButton}\n onClick={() => setIsCopyMode(false)}\n >\n {t(\"Cancel\")}\n </Button>\n </>\n }\n </div>\n <div className={classes.newSectionButtonContainer} />\n </>\n }\n {!enterpriseSelected &&\n <>\n <div className={classes.newSectionButtonContainer}>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Clinical history\")}\n </Typography>\n <ButtonWithSpinner\n margin={\"0px 0px 0px auto\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New section\")}\n innerIcon={<SectionNewIcon />}\n onClick={() => setNewSectionModalIsOpen(true)}\n />\n </div >\n </div >\n </>\n }\n {currentEstablishmentId !== undefined &&\n <>\n <SectionList\n accountId={currentEstablishmentId!}\n ref={sectionListRef}\n sectionType={currentTabSectionType}\n sections={sections}\n setSections={setSections}/>\n <SectionNewModal\n accountId={currentEstablishmentId!}\n sections={sections}\n isOpen={newSectionModalIsOpen}\n setOpen={setNewSectionModalIsOpen}\n onCreate={handleCreateSection} />\n </>\n }\n \n {getClinicalHistoryCommunicationSettingsContent()}\n \n <Backdrop show={isCopying} text={t(\"Copying\")+\"...\"} />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n width: \"100%\",\n justifyContent: \"space-between\",\n },\n newSectionButtonContainer: {\n display: \"flex\",\n marginBottom: 24,\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n sectionsContainer: {\n display: \"flex\",\n flexDirection: \"column\",\n },\n copySection: {\n marginBottom: 60\n },\n copyNotes:{\n backgroundColor: theme.colors.clearLilac,\n borderRadius: 5,\n padding: \"20px 30px\",\n marginBottom: 32\n },\n copyNotesTitle: {\n color: theme.colors.clearMain,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 700,\n wordWrap: \"break-word\"\n },\n copyNotesDescription: {\n color: theme.colors.grey5,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 400,\n wordWrap: \"break-word\"\n },\n copyControls:{\n display: \"flex\",\n },\n copyButton:{\n marginLeft: 16,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n cancelButton:{\n marginLeft: 16,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.gray1,\n color: Color.clear2,\n borderColor: Color.clear2,\n borderWidth: 1,\n borderStyle: \"solid\",\n \"&:hover\": {\n background: Color.white,\n },\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n select: {\n ...theme.typography.txtBody2,\n height: 32,\n width: 205,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \"& .MuiPaper-rounded\": {\n borderRadius: 10,\n marginTop: 8\n },\n \"& .MuiPaper-rounded .MuiListItem-root.Mui-selected:not(:hover)\": {\n backgroundColor: \"white\",\n },\n \"& .MuiPaper-rounded .MuiListItem-root\": {\n fontSize: 12,\n },\n \"& .MuiPaper-rounded .MuiListItem-root:hover\": {\n backgroundColor: theme.colors.grey1\n },\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"8px 0px 8px 15px\",\n color: theme.colors.clearMain\n },\n multiSelect: {\n ...theme.typography.txtBody2,\n height: 32,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 250,\n marginLeft: 16,\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n \"& .MuiMenu-list\": {\n borderRadius: \"0 0 10px 10px\",\n marginTop: 8\n },\n },\n}));\n\nexport default useStyles;","import { ApiClient } from \"./api-client\";\nimport { ClinicalHistoryCommunicationSettings } from \"../models/clinical-history-communication-settings-model\";\nimport { CopyEstablishmentSettingsModel } from \"../models/copy-establishment-settings-model\";\n\nexport class SettingsEvolutionNotesCommunicationService {\n \n private static baseUrl: string = \"/account\";\n \n static async copyEvolutionNotesSetting(copyModel: CopyEstablishmentSettingsModel): Promise<boolean> {\n return await ApiClient.post(`${this.baseUrl}/copyevolutionnotessetting`, copyModel).then(\n (data) => (data.succeeded)\n );\n }\n}\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { EvolutionNotesProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport SectionList from \"../SectionList\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../../redux/store\";\nimport Select from \"../../../../common/Select\";\nimport MultiSelect from \"../../../../common/MultiSelect\";\nimport CopyIcon from \"../../../../../assets/icons/CopyIcon\";\nimport { CopyEstablishmentSettingsModel } from \"../../../../../models/copy-establishment-settings-model\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport Backdrop from \"../../../../common/Backdrop\";\nimport { SettingsEvolutionNotesCommunicationService } from \"../../../../../api/settings-evolution-notes-communication-service\";\nimport SectionNote from \"../SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\n\n\nconst EvolutionNotes = (props: EvolutionNotesProps) => {\n\n const { t } = useTranslation([\"general\"]);\n const { settingsSelectedEstablishmentId } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const { enqueueAlert } = alertsActions;\n const currentTabSectionType = SectionType.VitalSigns;\n const accountSettings = useAppSelector(selectAccountSettings);\n \n const [currentEstablishmentId, setCurrentEstablishmentId] = useState<string|null|undefined>(undefined);\n const [copyToEstablishments, setCopyToEstablishments] = useState<string[]>([]);\n const [isCopyMode, setIsCopyMode] = useState<boolean>(false);\n const [isCopying, setIsCopying] = useState<boolean>(false);\n const [sections, setSections] = useState<SectionModel[]>([]);\n\n const userInfo = useAppSelector(selectUserInfo);\n const [enterpriseSelected, setEnterpriseSelected] = useState<boolean>(false);\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n dispatch(navbarActions.setShowLoader(false));\n }\n if (currentEstablishmentId !== undefined){\n void fetchData();\n }\n }, [currentEstablishmentId]);\n \n useEffect(() => {\n const enterpriseSelected = userInfo.accountId === settingsSelectedEstablishmentId;\n setEnterpriseSelected(enterpriseSelected);\n if (settingsSelectedEstablishmentId && !enterpriseSelected)\n setCurrentEstablishmentId(settingsSelectedEstablishmentId);\n else {\n if (accountSettings?.establishments?.length) {\n setCurrentEstablishmentId(accountSettings.establishments[0].key)\n } else {\n setCurrentEstablishmentId(null);\n }\n }\n }, [settingsSelectedEstablishmentId, accountSettings.establishments]);\n \n const loadData = async () => {\n const sectionsData =\n await SettingsPatientFormsService.getAccountSettingsTabSections(currentTabSectionType, currentEstablishmentId);\n setSections(sectionsData);\n };\n \n const handleCopyClick = async () => {\n if (isCopyMode) {\n setIsCopying(true);\n await SettingsEvolutionNotesCommunicationService.copyEvolutionNotesSetting(\n new CopyEstablishmentSettingsModel(currentEstablishmentId!, copyToEstablishments));\n setIsCopying(false);\n setIsCopyMode(false);\n dispatch(enqueueAlert({\n type: \"Success\",\n title: t(\"Vital signs copied\"),\n description: t(\"To the selected establishments\")\n }));\n } else {\n setIsCopyMode(true);\n }\n }\n \n const handleSelectEstablishment = (event: any) => {\n setCurrentEstablishmentId(event.target.value);\n }\n \n const handleSaveCopyToEstablishments = (establishments: string[]) => {\n setCopyToEstablishments(establishments);\n }\n \n const copyToEstablishmentsItems = () => {\n return accountSettings.establishments.filter(x => x.key !== currentEstablishmentId);\n }\n\n return <>\n <div className={classes.copySection}>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Evolution notes\")}\n </Typography>\n </div>\n {settingsSelectedEstablishmentId && (\n <SectionNote\n sectionData={SectionNoteData.EvolutionNotes}\n />\n )}\n </div>\n {enterpriseSelected && <>\n <div className={classes.copyControls}>\n <Select\n items={accountSettings.establishments}\n value={currentEstablishmentId}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.select}\n onChange={handleSelectEstablishment}\n />\n {accountSettings.establishments.length > 1 &&\n <>\n {isCopyMode &&\n <MultiSelect\n allItemsPlaceholder={t(\"Copy to all establishments\")}\n filterPlaceholder={t(\"Select destination establishment\")}\n items={copyToEstablishmentsItems()}\n values={copyToEstablishments}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.multiSelect}\n width={250}\n height={372}\n onChange={(x: any) => handleSaveCopyToEstablishments(x)}\n onReset={() => handleSaveCopyToEstablishments([])}\n />\n }\n <Button\n className={classes.copyButton}\n onClick={handleCopyClick}\n >\n <CopyIcon style={{ paddingRight: 5 }} />\n {t(\"Copy vital signs\")}\n </Button>\n <Button\n hidden={!isCopyMode}\n className={classes.cancelButton}\n onClick={() => setIsCopyMode(false)}\n >\n {t(\"Cancel\")}\n </Button>\n </>\n }\n </div>\n <div className={classes.newSectionButtonContainer} />\n </>}\n {!enterpriseSelected &&\n <>\n <div className={classes.newSectionButtonContainer}>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Evolution notes\")}\n </Typography>\n </div >\n </div >\n </>\n }\n {currentEstablishmentId !== undefined &&\n <SectionList\n accountId={currentEstablishmentId}\n sectionType={currentTabSectionType}\n sections={sections}\n setSections={setSections} />\n }\n \n <Backdrop show={isCopying} text={t(\"Copying\")+\"...\"} />\n </>\n};\n\nexport default EvolutionNotes;\n","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Clear } from \"@material-ui/icons\";\nimport { Color } from \"../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n header: {\n display: \"flex\",\n alignItems: \"center\",\n marginBottom: 24,\n width: \"100%\",\n gap: 20\n },\n tabTitle: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: \"18px\",\n lineHeight: \"22px\",\n color: Color.gray5\n },\n newButton: {\n marginLeft: \"auto\",\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n footerContainer: {\n paddingTop: 10,\n paddingBottom: 80\n },\n footerNoteLabel: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 400,\n fontSize: 12,\n lineHeight: \"14px\",\n color: Color.gray5,\n },\n footerNoteLabelBold: {\n fontWeight: 700,\n },\n footerNoteLabelLink: {\n textDecoration: \"underline\",\n fontWeight: 700,\n color: Color.clear1,\n \"&:hover\": {\n color: Color.blue\n }\n },\n previewButton: {\n height: 32,\n borderRadius: 51,\n padding: \"11px 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n border: \"1px solid \" + Color.clear1,\n color: Color.clear1,\n },\n copyNotes:{\n backgroundColor: theme.colors.clearLilac,\n borderRadius: 5,\n padding: \"20px 30px\",\n marginBottom: 32\n },\n copyNotesTitle: {\n color: theme.colors.clearMain,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 700,\n wordWrap: \"break-word\"\n },\n copyNotesDescription: {\n color: theme.colors.grey5,\n fontSize: 12,\n fontFamily: \"Roboto, sans-serif\",\n fontWeight: 400,\n wordWrap: \"break-word\"\n },\n copyControls:{\n display: \"flex\",\n },\n copyButton:{\n marginLeft: 16,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.clear2,\n color: Color.gray1,\n \"&:hover\": {\n background: Color.clear1,\n },\n },\n cancelButton:{\n marginLeft: 16,\n height: 32,\n borderRadius: 5,\n padding: \"11px 16px\",\n alignItems: \"center\",\n justifyContent: \"space-between\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n fontSize: 12,\n background: Color.gray1,\n color: Color.clear2,\n borderColor: Color.clear2,\n borderWidth: 1,\n borderStyle: \"solid\",\n \"&:hover\": {\n background: Color.white,\n },\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n select: {\n ...theme.typography.txtBody2,\n height: 32,\n width: 205,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \"& .MuiPaper-rounded\": {\n borderRadius: 10,\n marginTop: 8\n },\n \"& .MuiPaper-rounded .MuiListItem-root.Mui-selected:not(:hover)\": {\n backgroundColor: \"white\",\n },\n \"& .MuiPaper-rounded .MuiListItem-root\": {\n fontSize: 12,\n },\n \"& .MuiPaper-rounded .MuiListItem-root:hover\": {\n backgroundColor: theme.colors.grey1\n },\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"8px 0px 8px 15px\",\n color: theme.colors.clearMain\n },\n multiSelect: {\n ...theme.typography.txtBody2,\n height: 32,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n width: 250,\n marginLeft: 16,\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n \"& .MuiMenu-list\": {\n borderRadius: \"0 0 10px 10px\",\n marginTop: 8\n },\n },\n newSectionButtonContainer: {\n display: \"flex\",\n marginBottom: 24,\n },\n}));\n\nexport default useStyles;","import React, { useEffect, useRef, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\nimport { Link } from \"react-router-dom\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../redux/hooks\";\n\nimport { PatientFormProps } from \"./props\";\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { SectionNewIcon } from \"../../../../../assets/icons\";\nimport { SectionType } from \"../../../../../models/enums/section-type\";\nimport { SettingsPatientFormsService } from \"../../../../../api/settings-patient-forms-service\";\nimport { SectionModel } from \"../../../../../models/section-model\";\nimport SectionNewModal from \"../SectionNewModal\";\nimport SectionList from \"../SectionList\";\nimport SectionListRefs from \"../SectionList/section-list-refs\";\nimport { Url } from \"../../../../../constants/url\";\nimport Section from \"../Section\";\nimport { SectionFieldModel } from \"../../../../../models/section-field-model\";\nimport { SectionFieldType } from \"../../../../../models/enums/section-field-type\";\nimport { SectionFieldItemModel } from \"../../../../../models/section-field-item-model\";\nimport { selectAccountSettings, selectUserInfo } from \"../../../../../redux/store\";\nimport { navbarActions } from \"../../../../../redux/navbar-slice\";\nimport { alertsActions } from \"../../../../../redux/alerts-slice\";\nimport Select from \"../../../../common/Select\";\nimport MultiSelect from \"../../../../common/MultiSelect\";\nimport CopyIcon from \"../../../../../assets/icons/CopyIcon\";\nimport Backdrop from \"../../../../common/Backdrop\";\nimport { CopyEstablishmentSettingsModel } from \"../../../../../models/copy-establishment-settings-model\";\nimport { AccountService } from \"../../../../../api/account-service\";\nimport SectionNote from \"../SectionNote\";\nimport { SectionNoteData } from \"../../../../../models/enums/section-note-data\";\nimport ButtonWithSpinner from \"../../../../common/ButtonWithSpinner\";\nimport { ButtonPropsBorderRadius } from \"../../../../../models/enums/button-props-border-radius\";\n\n\nexport default function PatientForm(props: PatientFormProps) {\n const sectionTNamespace = \"sections\";\n const { t } = useTranslation([\"general\", sectionTNamespace]);\n const { settingsSelectedEstablishmentId } = props;\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const currentTabSectionType = SectionType.PatientForm;\n const accountSettings = useAppSelector(selectAccountSettings);\n const { enqueueAlert } = alertsActions;\n \n const [currentEstablishmentId, setCurrentEstablishmentId] = useState<string|null|undefined>(undefined);\n const [copyToEstablishments, setCopyToEstablishments] = useState<string[]>([]);\n const [isCopyMode, setIsCopyMode] = useState<boolean>(false);\n const [isCopying, setIsCopying] = useState<boolean>(false);\n const [sections, setSections] = useState<SectionModel[]>([]);\n const [newSectionModalIsOpen, setNewSectionModalIsOpen] = useState<boolean>(false);\n const [businessNameUrl, setBusinessNameUrl] = useState<string>();\n\n const sectionListRef = useRef<SectionListRefs>(null);\n\n const pacientBasicInfoSectionStaticModel = new SectionModel({\n id: \"patientBasicInfoId\",\n name: t(\"default_section_name_Basic patient information\", { ns: sectionTNamespace }),\n order: 0,\n type: SectionType.PatientForm,\n fields: [\n new SectionFieldModel({\n id: \"firstName\",\n name: t(\"default_field_name_First name(s)\", { ns: sectionTNamespace }),\n order: 1,\n type: SectionFieldType.Text,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"lastName\",\n name: t(\"default_field_name_Last name\", { ns: sectionTNamespace }),\n order: 2,\n type: SectionFieldType.Text,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"mobile\",\n name: t(\"default_field_name_Mobile\", { ns: sectionTNamespace }),\n order: 3,\n type: SectionFieldType.PhoneNumber,\n isRequired: true,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"email\",\n name: t(\"default_field_name_Email\", { ns: sectionTNamespace }),\n order: 4,\n type: SectionFieldType.Email,\n isRequired: false,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n new SectionFieldModel({\n id: \"gender\",\n name: t(\"default_field_name_Gender\", { ns: sectionTNamespace }),\n order: 5,\n type: SectionFieldType.Radio,\n isRequired: false,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false,\n items: [\n new SectionFieldItemModel({\n id: \"male\",\n name: t(\"default_field_item_name_Male\", { ns: sectionTNamespace }),\n order: 1\n }),\n new SectionFieldItemModel({\n id: \"Female\",\n name: t(\"default_field_item_name_Female\", { ns: sectionTNamespace }),\n order: 2\n }),\n ]\n }),\n new SectionFieldModel({\n id: \"dateOfBirth\",\n name: t(\"default_field_name_Date of Birth\", { ns: sectionTNamespace }),\n order: 6,\n type: SectionFieldType.Date,\n isRequired: false,\n isAdditionalTextareaEnabled: false,\n isEditable: false,\n isRemovable: false\n }),\n ],\n isEditable: false,\n isRemovable: false\n });\n\n const userInfo = useAppSelector(selectUserInfo);\n const [enterpriseSelected, setEnterpriseSelected] = useState<boolean>(false);\n\n useEffect(() => {\n async function fetchData() {\n dispatch(navbarActions.setShowLoader(true));\n await loadData();\n dispatch(navbarActions.setShowLoader(false));\n }\n if (currentEstablishmentId){\n void fetchData();\n }\n }, [currentEstablishmentId]);\n \n useEffect(() => {\n const enterpriseSelected = userInfo.accountId === settingsSelectedEstablishmentId;\n setEnterpriseSelected(enterpriseSelected);\n if (settingsSelectedEstablishmentId && !enterpriseSelected)\n setCurrentEstablishmentId(settingsSelectedEstablishmentId);\n else {\n if (accountSettings?.establishments?.length) {\n setCurrentEstablishmentId(accountSettings.establishments[0].key)\n } else {\n setCurrentEstablishmentId(null);\n }\n }\n }, [settingsSelectedEstablishmentId, accountSettings.establishments]);\n\n const handleCreateSection = async (name: string) => {\n await sectionListRef?.current?.createSection(name);\n }\n\n const loadData = async () => {\n const sectionsData =\n await SettingsPatientFormsService.getAccountSettingsTabSections(currentTabSectionType, currentEstablishmentId);\n setSections(sectionsData);\n const businessNameUrl = await AccountService.getAccountSubdomain(currentEstablishmentId!);\n setBusinessNameUrl(businessNameUrl);\n };\n \n const handleCopyClick = async () => {\n if (isCopyMode) {\n setIsCopying(true);\n await SettingsPatientFormsService.copyPatientFormSetting(\n new CopyEstablishmentSettingsModel(currentEstablishmentId!, copyToEstablishments))\n setIsCopying(false);\n setIsCopyMode(false);\n dispatch(enqueueAlert({\n type: \"Success\",\n title: t(\"Patient form copied\"),\n description: t(\"To the selected establishments\")\n }));\n } else {\n setIsCopyMode(true);\n }\n }\n \n const handleSelectEstablishment = (event: any) => {\n setCurrentEstablishmentId(event.target.value);\n }\n \n const handleSaveCopyToEstablishments = (establishments: string[]) => {\n setCopyToEstablishments(establishments);\n }\n \n const copyToEstablishmentsItems = () => {\n return accountSettings.establishments.filter(x => x.key !== currentEstablishmentId);\n }\n\n const handleOpenPreview = () => {\n window.open(`https://sitiodereservas.somosclear.com/${businessNameUrl}/patient-form?previewStep=first`, '_blank', 'noopener,noreferrer');\n }\n\n return <>\n {settingsSelectedEstablishmentId && (\n <>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Patient form\")}\n </Typography>\n </div>\n <SectionNote\n sectionData={SectionNoteData.PatientForm}\n />\n </>\n )}\n {enterpriseSelected &&\n <>\n <div className={classes.copyControls}>\n <Select\n items={accountSettings.establishments}\n value={currentEstablishmentId}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.select}\n onChange={handleSelectEstablishment}\n />\n {accountSettings.establishments.length > 1 &&\n <>\n {isCopyMode &&\n <MultiSelect\n allItemsPlaceholder={t(\"Copy to all establishments\")}\n filterPlaceholder={t(\"Select destination establishment\")}\n items={copyToEstablishmentsItems()}\n values={copyToEstablishments}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.multiSelect}\n width={250}\n height={372}\n onChange={(x: any) => handleSaveCopyToEstablishments(x)}\n onReset={() => handleSaveCopyToEstablishments([])}\n />\n }\n <Button\n className={classes.copyButton}\n onClick={handleCopyClick}\n >\n <CopyIcon style={{ paddingRight: 5 }} />\n {t(\"Copy form\")}\n </Button>\n <Button\n hidden={!isCopyMode}\n className={classes.cancelButton}\n onClick={() => setIsCopyMode(false)}\n >\n {t(\"Cancel\")}\n </Button>\n </>\n }\n </div>\n <div className={classes.newSectionButtonContainer}>\n <ButtonWithSpinner\n margin={\"0px 0px 0px auto\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New section\")}\n innerIcon={<SectionNewIcon />}\n onClick={() => setNewSectionModalIsOpen(true)}\n />\n </div >\n </>\n } \n {!enterpriseSelected &&\n <>\n <div className={classes.newSectionButtonContainer}>\n <div className={classes.header}>\n <Typography className={classes.tabTitle}>\n {t(\"Patient form\")}\n </Typography>\n <Button\n className={classes.previewButton}\n onClick={handleOpenPreview}\n >\n {t(\"Preview\")}\n </Button>\n <ButtonWithSpinner\n margin={\"0px 0px 0px auto\"}\n borderRadius={ButtonPropsBorderRadius.Large}\n innerText={t(\"New section\")}\n innerIcon={<SectionNewIcon />}\n onClick={() => setNewSectionModalIsOpen(true)}\n />\n\n </div >\n </div >\n </>\n }\n {currentEstablishmentId !== undefined &&\n <>\n <Section\n accountId={currentEstablishmentId!}\n key={\"patientBasicInfo\"}\n section={pacientBasicInfoSectionStaticModel}\n />\n <SectionList\n accountId={currentEstablishmentId}\n ref={sectionListRef}\n sectionType={currentTabSectionType}\n sections={sections}\n setSections={setSections}\n />\n <div className={classes.footerContainer}>\n <Typography className={classes.footerNoteLabel}>\n <span className={classes.footerNoteLabelBold}>\n {t(\"Note\") + \": \"}\n </span>\n {t(\"The customization of the Clinical History to be displayed in the form is done in the\") + \" \"}\n <Link\n to={Url.Settings.ClinicHistory}\n className={classes.footerNoteLabelLink}\n >\n {t(\"Clinical History\")}\n </Link>\n {\" \" + t(\"tab of the Settings screen\") + \".\"}\n </Typography>\n </div>\n <SectionNewModal\n accountId={currentEstablishmentId!}\n sections={sections}\n isOpen={newSectionModalIsOpen}\n setOpen={setNewSectionModalIsOpen}\n onCreate={handleCreateSection}\n />\n </>\n }\n <Backdrop show={isCopying} text={t(\"Copying\")+\"...\"} />\n </>\n};","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n tabBar: {\n width: \"100%\",\n height: 47,\n marginTop: -20\n },\n tabs: {\n ...theme.typography.txtBody2,\n \"& .MuiTabs-indicator\": {\n backgroundColor: \"#7175FA\"\n },\n \"& .Mui-selected\": {\n ...theme.typography.txtBody2,\n color: theme.colors.clearMain,\n fontWeight: \"bold\"\n },\n \"& .MuiButtonBase-root\": {\n minWidth: 0,\n alignItems: \"left\",\n marginRight: 25\n },\n \"& .MuiTab-root\": {\n paddingLeft: 0,\n paddingRight: 0,\n },\n },\n tab: {\n ...theme.typography.txtBody2,\n textTransform: \"none\",\n root: {\n ...theme.typography.txtBody2,\n },\n selected: {\n fontWeight: \"bold\",\n },\n \"&:hover\": {\n color: theme.colors.clearMain\n }\n },\n mainTab: {\n paddingTop: 0,\n paddingBottom: 20,\n backgroundColor: \"#ffffff\",\n height: 50,\n marginBottom: 30\n },\n headerBack: {\n height: 50,\n width: \"100%\",\n backgroundColor: \"#ffffff\",\n position: \"absolute\",\n left: 0\n }\n})\n);\n\nexport default useStyles;","import { makeStyles } from \"@material-ui/core/styles\";\n\nconst useStyles = makeStyles((theme) => ({\n container: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"end\",\n },\n focused: {\n \"&:focus\": {\n backgroundColor: theme.colors.grey1,\n },\n \"&.MuiSelect-select\": {\n \"&:focus\": {\n borderRadius: 5,\n },\n },\n },\n select: {\n ...theme.typography.txtBody2,\n height: 32,\n width: 205,\n border: \"solid 1px rgba(0, 0, 0, 0.1)\",\n borderRadius: 5,\n \"& .MuiPaper-rounded\": {\n borderRadius: 10,\n marginTop: 8\n },\n \"& .MuiPaper-rounded .MuiListItem-root.Mui-selected:not(:hover)\": {\n backgroundColor: \"white\",\n },\n \"& .MuiPaper-rounded .MuiListItem-root\": {\n fontSize: 12,\n },\n \"& .MuiPaper-rounded .MuiListItem-root:hover\": {\n backgroundColor: theme.colors.grey1\n },\n \"& .MuiSelect-select\": {\n paddingRight: 34\n },\n },\n selected: {\n fontWeight: \"bold\",\n padding: \"8px 0px 8px 15px\",\n color: theme.colors.clearMain\n },\n}));\n\nexport default useStyles;\n","import * as React from \"react\";\nimport { useEffect, useState } from \"react\";\nimport { useAppDispatch, useAppSelector } from \"../../../redux/hooks\";\n\nimport useStyles from \"./css\";\nimport { navbarActions } from \"../../../redux/navbar-slice\";\n\nimport Select from \"../../common/Select\";\nimport { LocalStorageKey } from \"../../../constants/local-storage-key\";\nimport useLocalStorageState from \"../../../hooks/useLocalStorageState\";\nimport { enterpriseActions } from \"../../../redux/enterprise-slice\";\nimport { useTranslation } from \"react-i18next\";\n\nexport default function SettingsEstablishmentSelector() {\n \n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const { t } = useTranslation([\"general\"]);\n\n const userInfo = useAppSelector(state => state.userInfo)\n const accountId = userInfo.accountId;\n const accountSettings = useAppSelector((state) => state.accountSettings);\n\n const settingsEstablishmentStorageKey = LocalStorageKey.SettingsEstablishment + accountId;\n const { setSettingsEstablishmentId } = enterpriseActions;\n // @ts-ignore\n const [currentEstablishmentId, setCurrentEstablishmentId] = useLocalStorageState({ itemKey: settingsEstablishmentStorageKey, dispatchFunction: setSettingsEstablishmentId });\n\n const enterpriseWithEstablishments = [\n ...(accountId\n ? [{ \n key: accountId,\n value: `${accountSettings.accountName} (${t(\"Enterprise account\")})`\n }]\n : []),\n ...accountSettings.establishments\n ];\n\n const handleSelectEstablishment = (event: any) => {\n if (event.target == accountId)\n setCurrentEstablishmentId(event.target);\n else\n setCurrentEstablishmentId(event.target.value);\n }\n\n useEffect(() => {\n if (!currentEstablishmentId && accountSettings?.isEnterprise !== false) {\n if (accountSettings?.establishments?.length) {\n setCurrentEstablishmentId(accountId)\n } else {\n setCurrentEstablishmentId(null);\n }\n }\n },[accountSettings.establishments, userInfo.accountId]);\n\n useEffect(() => {\n const externalContent = (\n accountSettings.isEnterprise ? (\n <div className={classes.container}>\n <Select\n items={enterpriseWithEstablishments}\n value={currentEstablishmentId}\n classes={{ root: `${classes.focused} ${classes.selected}` }}\n styleClass={classes.select}\n onChange={handleSelectEstablishment}\n />\n </div>\n ) : null\n );\n\n dispatch(navbarActions.setExternalContent(externalContent));\n },[accountSettings.establishments, currentEstablishmentId]);\n\n return null;\n}\n","import React from 'react';\n\nimport { Link, useRouteMatch } from \"react-router-dom\";\nimport { useTranslation } from \"react-i18next\";\nimport { useAppSelector } from '../../../redux/hooks';\nimport { RootState, selectAccountSettings } from '../../../redux/store';\nimport { Tab, Tabs } from \"@material-ui/core\";\nimport { Url } from \"../../../constants/url\";\nimport useStyles from \"./css\";\nimport EstablishmentSelector from '../SettingsEstablishmentSelector';\n\nimport { useSelector } from 'react-redux';\nimport { selectUserInfo } from '../../../redux/store';\n\n\nexport default function EstablishmentSettingsNavTabs() {\n \n const routeMatch = useRouteMatch({\n path: [\n Url.EstablishmentSettings.General,\n Url.EstablishmentSettings.ClinicHistory,\n Url.EstablishmentSettings.EvolutionNotes,\n Url.EstablishmentSettings.PatientForm,\n Url.EstablishmentSettings.CustomerCommunications,\n Url.EstablishmentSettings.WorkAreas,\n Url.EstablishmentSettings.Users,\n Url.EstablishmentSettings.Services,\n Url.EstablishmentSettings.Commissions,\n Url.EstablishmentSettings.Payments,\n ],\n exact: true\n });\n \n const currentTab = routeMatch?.path;\n \n const { t } = useTranslation([\"settings\"]);\n \n const classes = useStyles();\n \n const accountSettings = useAppSelector(selectAccountSettings);\n\n const userInfo = useAppSelector(selectUserInfo);\n const settingsSelectedAccountId = useSelector((state: RootState) => state.enterprise.settingsEstablishmentId);\n const enterpriseSelected = userInfo.accountId === settingsSelectedAccountId; \n\n return (\n <>\n <div className={classes.headerBack} />\n <EstablishmentSelector />\n <div className={classes.mainTab}>\n <div className={classes.tabBar}>\n <Tabs\n value={currentTab}\n indicatorColor=\"primary\"\n textColor=\"primary\"\n className={classes.tabs}\n >\n <Tab\n className={classes.tab}\n label={t(\"General\")}\n value={Url.EstablishmentSettings.General}\n to={Url.EstablishmentSettings.General}\n component={Link}\n />\n {(settingsSelectedAccountId && !enterpriseSelected) ?\n <Tab\n className={classes.tab}\n label={t(\"Communication with the customer\")}\n value={Url.EstablishmentSettings.CustomerCommunications}\n to={Url.EstablishmentSettings.CustomerCommunications}\n component={Link}\n /> : \n <div/>\n }\n {(settingsSelectedAccountId && !enterpriseSelected) ?\n <Tab\n className={classes.tab}\n label={t(\"Work areas\")}\n value={Url.EstablishmentSettings.WorkAreas}\n to={Url.EstablishmentSettings.WorkAreas}\n component={Link} \n /> : \n <div/>\n }\n {(settingsSelectedAccountId && !enterpriseSelected) ?\n <Tab\n className={classes.tab}\n label={t(\"Services\")}\n value={Url.EstablishmentSettings.Services}\n to={Url.EstablishmentSettings.Services}\n component={Link} \n /> : \n <div/>\n }\n {(settingsSelectedAccountId && !enterpriseSelected) ?\n <Tab\n className={classes.tab}\n label={t(\"Users\")}\n value={Url.EstablishmentSettings.Users}\n to={Url.EstablishmentSettings.Users}\n component={Link} \n /> : \n <div/>\n }\n {(settingsSelectedAccountId && !enterpriseSelected) ?\n <Tab\n className={classes.tab}\n label={t(\"Payments\")}\n value={Url.EstablishmentSettings.Payments}\n to={Url.EstablishmentSettings.Payments}\n component={Link}\n /> : \n <div/>\n }\n {(accountSettings.hasEstablishmentsInClinicMode) ?\n <Tab\n className={classes.tab}\n label={t(\"Clinical history\")}\n value={Url.EstablishmentSettings.ClinicHistory}\n to={Url.EstablishmentSettings.ClinicHistory}\n component={Link}\n /> :\n <div/>\n }\n {(accountSettings.hasEstablishmentsInClinicMode) ?\n <Tab\n className={classes.tab}\n label={t(\"Evolution notes\")}\n value={Url.EstablishmentSettings.EvolutionNotes}\n to={Url.EstablishmentSettings.EvolutionNotes}\n component={Link}\n /> :\n <div/>\n }\n {(accountSettings.hasEstablishmentsInClinicMode) ?\n <Tab\n className={classes.tab}\n label={t(\"Patient Form\")}\n value={Url.EstablishmentSettings.PatientForm}\n to={Url.EstablishmentSettings.PatientForm}\n component={Link}\n /> :\n <div/>\n }\n {(settingsSelectedAccountId && !enterpriseSelected) ?\n <Tab\n className={classes.tab}\n label={t(\"Commissions\")}\n value={Url.EstablishmentSettings.Commissions}\n to={Url.EstablishmentSettings.Commissions}\n component={Link} \n /> : \n <div/>\n }\n </Tabs>\n </div>\n </div>\n </>);\n}","import { makeStyles } from \"@material-ui/core/styles\";\nimport { Color } from \"../../../../../../constants/colors\";\n\nconst useStyles = makeStyles((theme) => ({\n title: {\n fontFamily: \"Inter\",\n fontSize: \"14px\",\n color: Color.gray5,\n marginBottom: 10,\n fontStyle: \"normal\",\n fontWeight: \"bold\",\n },\n divArea: {\n backgroundColor: \"#fff\",\n borderRadius: 20,\n border: \"1px solid #dbdcdd\",\n padding: \"35px 40px 75px 40px\",\n margin: \"10px 0\"\n },\n enterpriseInformationContainer: {\n display: \"flex\"\n },\n enterpriseLeftContainer: {\n flexBasis: \"23%\"\n },\n enterpriseRightContainer: {\n flexBasis: \"77%\"\n },\n copyLinkButtonContainer: {\n width: \"32%\"\n },\n required: {\n color: \"#6462F3\",\n marginLeft: 5,\n fontWeight: \"bold\",\n fontSize: 14,\n },\n copyLinkButton: {\n height: 32,\n width: \"100%\",\n \n marginTop: 43,\n \n borderRadius: 51,\n padding: \"16px 16px\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: 700,\n fontSize: 12,\n border: \"1px solid \" + Color.clear1,\n color: Color.clear1,\n },\n titleSection: {\n fontFamily: \"Inter\",\n fontSize: \"14px\",\n color: Color.gray4,\n marginBottom: 20,\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n },\n inputClass: {\n ...theme.typography.body2,\n color: theme.colors.grey5,\n fontWeight: \"bold\",\n \"&::placeholder\": {\n ...theme.typography.txtBody2,\n color: theme.colors.grey5,\n fontWeight: \"normal\",\n opacity: 0.4,\n }\n },\n label: {\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#919CA5\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n labelSecondary: {\n fontFamily: \"Roboto,sans serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: 12,\n color: \"#919CA5\"\n },\n logoSection: {\n width: \"100%\",\n paddingTop: 10,\n height: 150\n },\n divLogo: {\n width: 120,\n height: 120,\n borderRadius: \"50%\",\n backgroundColor: \"#6462F3\",\n marginLeft: 30,\n position: \"relative\",\n cursor: \"pointer\"\n },\n divLogoIcon: {\n display: \"flex\",\n alignItems: \"center\",\n zIndex: 2,\n position: \"absolute\",\n height: \"100%\"\n },\n logoIconClear: {\n width: \"70%\",\n height: \"100%\",\n margin: \"auto\",\n fontSize: 70,\n color: \"#F6F6F6\",\n },\n iconCam: {\n marginTop: 40,\n height: 25,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n },\n labelChangePhoto: {\n marginTop: 5,\n fontWeight: \"bold\",\n fontSize: 12,\n textAlign: \"center\",\n color: \"#FFFFFF\",\n opacity: 1\n },\n optional: {\n marginLeft: 3,\n fontFamily: \"Inter\",\n display: \"inline-flex\",\n margin: 0,\n color: \"#919CA5\",\n fontSize: 12,\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n fontStyle: \"normal\",\n marginBottom: 5,\n },\n divLogoIconHover: {\n zIndex: 3,\n position: \"absolute\",\n width: 120,\n height: 120,\n borderRadius: \"50%\",\n margin: \"auto\",\n opacity: 0,\n \"&:hover\": {\n background: \"rgba(29, 32, 39, 0.7)\",\n display: \"flow-root\",\n opacity: 0.7\n }\n },\n}));\n\nexport default useStyles;","export enum EnterpriseSettingsFieldUpdate {\n None = -1,\n All = 0,\n Name = 1,\n Logo = 2\n\n}\n\nexport const getEnum = (field: string) => {\n let e: { [key: string]: EnterpriseSettingsFieldUpdate } = {};\n e[\"name\"] = EnterpriseSettingsFieldUpdate.Name;\n e[\"logo\"] = EnterpriseSettingsFieldUpdate.Logo;\n return e[field.toLowerCase()];\n}","import { SettingsFieldUpdate } from \"./enums/settings-field-update\";\nimport { EnterpriseSettingsFieldUpdate } from \"./enums/enterprise-settings-field-update\";\n\nexport class EnterpriseInfo {\n name: string;\n logo?: string;\n fieldUpd: EnterpriseSettingsFieldUpdate;\n constructor(x?: EnterpriseInfo) {\n if (typeof x === \"object\" && x !== null) {\n this.name = x.name || \"\";\n this.logo = x.logo || \"\";\n this.fieldUpd = x.fieldUpd || EnterpriseSettingsFieldUpdate.None;\n }\n else {\n this.name = \"\";\n this.logo = \"\";\n this.fieldUpd = EnterpriseSettingsFieldUpdate.None;\n }\n }\n}\n","import { ApiClient } from \"./api-client\";\nimport { EnterpriseInfo } from \"../models/enterpriseinfo\";\n\nexport class EnterpriseInfoService {\n\n private static baseUrl: string = \"/account\";\n\n static async updateEnterpriseInfo(enterpriseInfo: EnterpriseInfo): Promise<EnterpriseInfo> {\n return ApiClient.post(`${this.baseUrl}/updateenterpriseinfo`, enterpriseInfo)\n .then(data => new EnterpriseInfo(data.enterpriseInfoDto)\n );\n }\n\n static async getEnterpriseInfo(): Promise<EnterpriseInfo> {\n const data = await ApiClient.get(`${this.baseUrl}/getenterpriseinfo`);\n return new EnterpriseInfo(data.enterpriseInfoDto);\n }\n\n}\n","import React, { useEffect, useState } from \"react\";\nimport { useTranslation } from \"react-i18next\";\n\nimport useStyles from \"./css\";\nimport { Button, Typography } from \"@material-ui/core\";\nimport { CameraIcon, LogoIcon } from \"../../../../../../assets/icons\";\nimport { useAppDispatch, useAppSelector } from \"../../../../../../redux/hooks\";\nimport { navbarActions } from \"../../../../../../redux/navbar-slice\";\nimport { selectAccountSettings } from \"../../../../../../redux/store\";\nimport { alertsActions } from \"../../../../../../redux/alerts-slice\";\nimport DropImage from \"../../../../../common/DropImage\";\nimport ServicesService from \"../../../../../../api/settings-services-service\";\nimport { ControlInput } from \"../../../../../../models/establishmentinfo\";\n\nimport { EnterpriseInfo } from \"../../../../../../models/enterpriseinfo\";\nimport { EnterpriseInfoService } from \"../../../../../../api/settings-enterpriseinfo-service\";\nimport { EnterpriseSettingsFieldUpdate, getEnum } from \"../../../../../../models/enums/enterprise-settings-field-update\";\nimport InputWithLabel from \"../../../../../common/InputWithLabel\";\n\n\nexport default function General() {\n \n const { t } = useTranslation([\"general\"]);\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const [establishmentInfoShadow, setEstablishmentInfoShadow] = useState<EnterpriseInfo>(new EnterpriseInfo());\n \n const [readOnlyControl, setReadOnlyControl] = useState<ControlInput>(new ControlInput(true));\n const [enterpriseInfo, setEnterpriseInfo] = useState<EnterpriseInfo>(new EnterpriseInfo());\n \n const [logoURL, setLogoURL] = useState<string>(\"\");\n const accountSettings = useAppSelector(selectAccountSettings);\n const { enqueueAlert } = alertsActions;\n \n useEffect(() => {\n \n (async () => {\n dispatch(navbarActions.setShowLoader(true));\n let enterprise = await EnterpriseInfoService.getEnterpriseInfo();\n setEnterpriseInfo(enterprise);\n setEstablishmentInfoShadow(enterprise);\n await getImage(enterprise.logo);\n dispatch(navbarActions.setShowLoader(false));\n })();\n \n }, [])\n \n const saveByEnter = (newInfo: EnterpriseInfo) => {\n (async () => {\n await EnterpriseInfoService.updateEnterpriseInfo(newInfo);\n })();\n };\n \n async function getImage(fileId: string | null = \"\") {\n if (!fileId) return;\n const data = await ServicesService.getImage(fileId);\n \n if (data)\n setLogoURL(data.fileURL);\n }\n \n function onKeyPress(e: any) {\n if (e.which === 13) {\n e.target.blur();\n }\n }\n \n function handleInputChange(e: any) {\n const { name, value } = e.target;\n setEnterpriseInfo({\n ...enterpriseInfo,\n [name]: value\n });\n }\n \n async function handleLogoUpload(files: any) {\n if (files && files.length > 0) {\n let data: any = await ServicesService.saveImage(files[0]);\n if (data) {\n let newInfo: EnterpriseInfo = {\n ...enterpriseInfo,\n logo: data.fileName,\n fieldUpd: EnterpriseSettingsFieldUpdate.Logo\n };\n \n saveByEnter(newInfo);\n }\n }\n }\n \n function clickTextbox(e: any) {\n const { name } = e.target;\n \n setReadOnlyControl({\n ...readOnlyControl,\n [name]: false\n });\n }\n \n const DivLogoEmpty: React.FC = () => {\n return (\n <div className={classes.divLogoIcon}>\n <LogoIcon className={classes.logoIconClear}/>\n </div>);\n };\n \n function handleEmptyRequired(name: string, value: any): boolean {\n switch (name) {\n case \"name\": {\n if (value === \"\") {\n setEnterpriseInfo({\n ...enterpriseInfo,\n [name]: establishmentInfoShadow.name\n });\n dispatch(\n enqueueAlert({\n type: \"Error\",\n title: t(\"Error\"),\n description: t(\"Enter establishment name is required\")\n })\n );\n return false;\n } else if (value === establishmentInfoShadow.name)\n return false;\n \n return true;\n }\n default: {\n return false;\n }\n }\n }\n \n function updateOnBlur(e: any) {\n const { name, value } = e.target;\n \n setReadOnlyControl({\n ...readOnlyControl,\n [name]: true\n });\n \n let newInfo: EnterpriseInfo = {\n ...enterpriseInfo,\n fieldUpd: getEnum(name)\n };\n \n return newInfo;\n }\n \n function handleCopyLink() {\n navigator.clipboard.writeText(`https://sitiodereservas.somosclear.com/${accountSettings.siteForFinalCustomersSmbName}`);\n }\n \n function onBlur(e: any) {\n const { name, value } = e.target;\n \n const newInfo = updateOnBlur(e);\n \n const canSave = handleEmptyRequired(name, value);\n \n if (canSave)\n saveByEnter(newInfo);\n }\n \n const DivLogoEmptyHover: React.FC = () => {\n return (\n <>\n <div className={classes.divLogoIconHover}>\n <div className={classes.iconCam}>\n <CameraIcon/>\n </div>\n <div className={classes.labelChangePhoto}>\n {t(\"upload photo\")}\n </div>\n </div>\n </>);\n };\n \n \n return (\n <>\n <Typography className={classes.title}>\n {t(\"General settings\")}\n </Typography>\n <div className={classes.divArea}>\n <div className={classes.titleSection}>\n <Typography className={classes.titleSection}>\n {t(\"Enterprise information\")}\n </Typography>\n </div>\n <div className={classes.enterpriseInformationContainer}>\n <div className={classes.enterpriseLeftContainer}>\n <Typography className={classes.label}>\n {t(\"Enterprise logo\")}\n </Typography>\n \n <span className={classes.optional}>({t(\"Optional\")})</span>\n <br/>\n \n <div className={classes.logoSection}>\n <DropImage\n classDivUploadImage={classes.divLogo}\n onChange={handleLogoUpload}\n imageURL={logoURL}\n componentShowEmptyHover={<DivLogoEmptyHover/>}\n componentShowEmpty={<DivLogoEmpty/>}\n />\n <div style={{ marginTop: 10, marginLeft: 14 }} className={classes.labelSecondary}>\n {t(\"Max size\")}: <b>800px x 800px</b>\n </div>\n </div>\n </div>\n <div className={classes.enterpriseRightContainer}>\n <InputWithLabel\n name=\"name\"\n showCounter={true}\n value={enterpriseInfo.name}\n onChange={handleInputChange}\n onKeyPress={onKeyPress}\n onBlurInput={onBlur}\n inputReadOnly={readOnlyControl.name}\n onClickInput={clickTextbox}\n width=\"100%\"\n inputClass={classes.inputClass}\n label={() => (\n <>\n <Typography className={classes.label}>\n {t(\"Enterprise name\")}\n </Typography>\n <span className={classes.required}>*</span>\n </>)}\n labelClass={classes.label}\n placeholder={t(\"Enter the name of the establishment\")}\n maxLength={60}\n />\n <div className={classes.copyLinkButtonContainer}>\n <Button\n className={classes.copyLinkButton}\n onClick={handleCopyLink}\n >\n {t(\"Copy enterprise site for appointments link\")}\n </Button>\n </div>\n </div>\n </div>\n </div>\n </>\n )\n};","import React from \"react\";\n\nimport { useSelector } from \"react-redux\";\nimport { useAppSelector } from \"../../../../../redux/hooks\";\n\nimport GeneralEnterprise from \"./Enterprise/general\";\nimport GeneralEstablishment from \"../../../../settings/Sections/General/GeneralMain\";\nimport { RootState } from \"../../../../../redux/store\";\n\nexport default function GeneralPage() {\n const settingsSelectedAccountId = useSelector((state: RootState) => state.enterprise.settingsEstablishmentId);\n const userInfo = useAppSelector(state => state.userInfo)\n const enterpriseSelected = userInfo.accountId === settingsSelectedAccountId;\n\n return (\n <>\n {\n enterpriseSelected\n ? <GeneralEnterprise />\n : <GeneralEstablishment\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />\n }\n </>\n )\n};","import React from 'react';\nimport { Redirect, Route, Switch, BrowserRouter } from \"react-router-dom\";\nimport { Url } from \"../../../constants/url\";\nimport ClinicHistory from '../Sections/FormsSettingsTabs/ClinicHistory';\nimport EvolutionNotes from '../Sections/FormsSettingsTabs/EvolutionNotes';\nimport PatientForm from '../Sections/FormsSettingsTabs/PatientForm';\nimport EstablishmentSettingsNavTabs from \"../EstablismentSettingsNavTabs\";\nimport General from \"../Sections/FormsSettingsTabs/General/general-page\";\nimport CustomerCommunications from \"../../settings/Sections/CustomerCommunications/CustomerCommunicationsMain\";\nimport { useSelector } from 'react-redux';\nimport { RootState, selectUserInfo } from '../../../redux/store';\nimport PaymentMain from '../../settings/Sections/Payments/PaymentMain';\nimport Workareas from \"../../settings/Sections/WorkArea/WorkAreaMain\";\nimport Users from \"../../settings/Sections/Users/UsersMainPage\";\nimport Services from \"../../settings/Sections/Services/ServiceMain\";\nimport Commissions from '../../settings/Sections/Commissions/CommissionsMain';\nimport { useAppSelector } from '../../../redux/hooks';\n\n\nexport default function EstablishmentSettingsRouter() {\n\n const userInfo = useAppSelector(selectUserInfo);\n const settingsSelectedAccountId = useSelector((state: RootState) => state.enterprise.settingsEstablishmentId);\n const enterpriseSelected = userInfo.accountId === settingsSelectedAccountId; \n\n return (\n <>\n {\n userInfo.isAdministrator ?\n <BrowserRouter>\n {enterpriseSelected && <Redirect from=\"*\" to={Url.EstablishmentSettings.General} />}\n <EstablishmentSettingsNavTabs />\n <Switch>\n <Route exact path={Url.EstablishmentSettings.General} component={General} />\n <Route exact \n path={Url.EstablishmentSettings.ClinicHistory} \n render={(props) => \n <ClinicHistory {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />}\n />\n <Route exact \n path={Url.EstablishmentSettings.EvolutionNotes} \n render={(props) => \n <EvolutionNotes {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />} \n />\n <Route exact \n path={Url.EstablishmentSettings.PatientForm} \n render={(props) => \n <PatientForm {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />} \n />\n <Route path={Url.Settings.ClinicHistory}>\n <Redirect to={Url.Settings.ClinicHistory} />\n </Route>\n <Route exact \n path={Url.EstablishmentSettings.CustomerCommunications} \n render={(props) => \n <CustomerCommunications {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />}\n />\n <Route exact \n path={Url.EstablishmentSettings.WorkAreas} \n render={(props) => \n <Workareas {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />} \n />\n <Route exact \n path={Url.EstablishmentSettings.Users} \n render={(props) => \n <Users {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />} \n />\n <Route exact \n path={Url.EstablishmentSettings.Services} \n render={(props) => \n <Services {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />} \n />\n <Route exact \n path={Url.EstablishmentSettings.Payments} \n render={(props) => \n <PaymentMain {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />}\n />\n <Route exact \n path={Url.EstablishmentSettings.Commissions} \n render={(props) => \n <Commissions {...props}\n settingsSelectedEstablishmentId={settingsSelectedAccountId}\n />} \n />\n </Switch>\n </BrowserRouter>\n :\n <Redirect to={Url.Appointments.Main} />\n }\n </>\n );\n}\n","import React from 'react';\n\nimport Interweave from \"interweave\";\n\nimport { InterweaveComponentProps } from \"./props\";\n\n\nexport default function InterweaveComponent(props: InterweaveComponentProps) {\n \n const { text } = props;\n \n const linkRegex = new RegExp(\"[Hh]ttps?:\\\\/\\\\/(www\\\\.)?[-a-zA-Z0-9@:%._\\+~#=]{2,256}\\\\.[a-z]{2,4}\\\\b([-a-zA-Z0-9@:%_\\+.~#?&/=]*)\");\n \n const encaseLinksWithTags = (str: string) => {\n if (str === null) return str;\n const matches = str.match(linkRegex);\n if (matches && matches.length > 0) {\n let newStr = str;\n newStr = newStr.replace(matches[0], `<a target=\"_blank\" href=\"${matches[0]}\">${matches[0]}</a>`)\n return newStr;\n } else {\n return str;\n }\n }\n \n return (\n <Interweave content={encaseLinksWithTags(text)} />\n );\n}","import React, { useEffect, useState } from 'react';\n\nimport { Redirect } from \"react-router-dom\";\n\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport InterweaveComponent from \"../../common/InterweaveComponent\";\nimport { Url } from \"../../../constants/url\";\nimport { CustomerService } from \"../../../api/customer-service\";\n\n\nexport default function PrivacyNoticePage() {\n \n const [privacyNoticeEnabled, setPrivacyNoticeEnabled] = useState<boolean>(true);\n const [privacyNotice, setPrivacyNotice] = useState<string>(\"\");\n\n const userInfo = useAppSelector((state) => state.userInfo);\n \n useEffect(() => {\n (async () => loadPrivacyNotice()\n )();\n }, [userInfo.accountId])\n \n async function loadPrivacyNotice() {\n if (userInfo && userInfo.accountId) {\n const response = await CustomerService.getPrivacyNotice();\n setPrivacyNotice(response.privacyNotice);\n setPrivacyNoticeEnabled(response.privacyNoticeEnabled);\n }\n }\n \n return (\n <>\n {\n privacyNoticeEnabled\n ? \n <InterweaveComponent\n text={privacyNotice}\n /> \n :\n <Redirect to={Url.Appointments.Main} />\n }\n </>\n );\n}","import React, { useEffect, useState } from 'react';\n\nimport { Redirect } from \"react-router-dom\";\n\nimport { useAppSelector } from \"../../../redux/hooks\";\n\nimport InterweaveComponent from \"../../common/InterweaveComponent\";\nimport { Url } from \"../../../constants/url\";\nimport { CustomerService } from \"../../../api/customer-service\";\n\n\nexport default function InformedConsentLetterPage() {\n \n const [consentLetterEnabled, setConsentLetterEnabled] = useState<boolean>(true);\n const [consentLetter, setConsentLetter] = useState<string>(\"\");\n \n const userInfo = useAppSelector((state) => state.userInfo);\n \n useEffect(() => {\n (async () => loadPrivacyNotice()\n )();\n }, [userInfo.accountId])\n \n async function loadPrivacyNotice() {\n if (userInfo && userInfo.accountId) {\n const response = await CustomerService.getInformedConsentLetter();\n setConsentLetter(response.consentLetter);\n setConsentLetterEnabled(response.consentLetterEnabled);\n }\n }\n \n \n return (\n <>\n {\n consentLetterEnabled\n ?\n <InterweaveComponent\n text={consentLetter}\n />\n :\n <Redirect to={Url.Appointments.Main} />\n }\n </>\n );\n}","import { makeStyles, Theme } from '@material-ui/core';\nimport { createTheme } from \"@material-ui/core/styles\";\nimport { scrollbarStyle } from \"../components/common/Scheduler/styles/ScrollbarStyles\";\n\nexport const ThemeStyles = createTheme({\n palette: {\n primary: {\n main: \"#6462F3\",\n light: \"#a697df\",\n },\n },\n colors: {\n clearMain: \"#6462F3\",\n clear2: \"#7175FA\",\n clear3: \"#9FA9E6\",\n clear4: \"#BDC7F8\",\n clear5: \"#E1E9FE\",\n clear6: \"#E9F1FE\",\n grey7: \"#1D2027\",\n grey6: \"#323947\",\n grey5: \"#5C6477\",\n grey4: \"#919CA5\",\n grey3: \"#ACB7C0\",\n grey2: \"#C9CDD3\",\n grey1: \"#F6F6F6\",\n white: \"#FFFFFF\",\n clearGreen: \"#36CE91\",\n clearRed: \"#F15857\",\n clearYellow: \"#FFC626\",\n clearBlue: \"#0BCBE0\",\n clearLilac: \"#EAE9FF\",\n },\n typography: {\n fontFamily: [\"Roboto\", \"sans-serif\"].join(\",\"),\n h4: {\n fontStyle: \"normal\",\n fontSize: \"18px\",\n lineHeight: \"22px\",\n },\n subtitle1: {\n fontSize: \"12px\",\n lineHeight: \"14px\",\n fontWeight: \"bold\",\n fontStyle: \"normal\",\n },\n subtitle2: {\n fontSize: \"12px\",\n lineHeight: \"14px\",\n fontWeight: \"normal\",\n fontStyle: \"normal\",\n },\n header1: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"34px\",\n lineHeight: \"41px\",\n },\n header2: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"24px\",\n lineHeight: \"29px\",\n },\n header3: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"21px\",\n lineHeight: \"25px\",\n },\n header4: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"18px\",\n lineHeight: \"22px\",\n },\n header5: {\n fontFamily: 'Inter, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'bold',\n fontSize: '14px',\n lineHeight: '17px',\n },\n header6: {\n fontFamily: 'Inter, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'bold',\n fontSize: '12px',\n lineHeight: '15px',\n },\n txtBody1: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n },\n txtBody2: {\n fontFamily: \"Roboto, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"14px\",\n },\n txtBody3: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"11px\",\n lineHeight: \"13px\",\n },\n caption1: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"10px\",\n lineHeight: \"12px\",\n },\n caption2: {\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"9px\",\n lineHeight: \"11px\",\n },\n buttons: {\n fontFamily: \"Inter\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"12px\",\n lineHeight: \"15px\",\n },\n },\n overrides: {\n MuiAppBar: {\n root: {\n boxShadow: \"none\",\n },\n },\n MuiToolbar: {\n dense: {\n minHeight: 54,\n },\n },\n MuiPopover: {\n root: {\n zIndex: 1150,\n },\n },\n MuiButtonBase: {\n root: {\n \"&:focus\": {\n outline: \"none\",\n },\n },\n },\n MuiButton: {\n root: {\n fontSize: \"0.725rem\",\n textTransform: \"none\",\n },\n contained: {\n boxShadow: \"none\",\n \"&:hover\": {\n boxShadow: \"none\",\n },\n \"&:disabled\": {\n boxShadow: \"none\",\n backgroundColor: \"#6462F3\",\n color: \"#fff\",\n opacity: 0.3,\n },\n },\n },\n MuiIconButton: {\n root: {\n \"&:focus\": {\n outline: \"none\",\n },\n },\n },\n MuiInputBase: {\n root: {\n fontSize: \"0.9rem\",\n },\n },\n MuiOutlinedInput: {\n input: {\n textOverflow: \"ellipsis\",\n borderRadius: 4,\n position: \"relative\",\n backgroundColor: \"#fff\",\n border: \"1px #9ea3a8\",\n \"&focus\": {\n borderColor: \"#593ea3\",\n },\n padding: \"8px 10px\",\n },\n inputMarginDense: {\n paddingTop: 8,\n paddingBottom: 8,\n },\n multiline: {\n padding: \"8px 10px\",\n },\n adornedStart: {\n paddingLeft: 8,\n },\n },\n MuiInputLabel: {\n root: {\n marginBottom: 0,\n },\n },\n MuiTab: {\n root: {\n textTransform: \"capitalize\",\n },\n },\n MuiTableCell: {\n stickyHeader: {\n backgroundColor: \"white\",\n },\n },\n MuiPickersBasePicker: {\n container: {\n border: `1px solid #F6F6F6`,\n boxSizing: \"border-box\",\n borderRadius: 8,\n boxShadow: \"0px 3px 20px rgba(229, 231, 234, 0.56)\",\n },\n },\n MuiPickersCalendarHeader: {\n iconButton: {\n color: \"#7175FA\",\n },\n transitionContainer: {\n color: \"#7175FA\",\n textTransform: \"capitalize\",\n fontFamily: \"Inter, sans-serif\",\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n fontSize: \"14px\",\n lineHeight: \"17px\",\n },\n dayLabel: {\n textTransform: \"capitalize\",\n },\n },\n },\n });\n\nconst generateVariables = (theme: Theme) => {\n let vars: Record<string, string> = {};\n \n const addColors = (colors: Record<string, string>) => {\n const addition = Object.fromEntries(Object.entries(colors).map(([k, v]) => [`--${k}`, v]));\n for (let k in addition) vars[k] = addition[k];\n };\n \n addColors(theme.colors);\n \n return vars;\n};\n\nexport const useGlobalThemeCss = makeStyles((theme) => ({\n '@global': {\n ':root': generateVariables(theme),\n '.custom-scrollbar': scrollbarStyle(),\n },\n}));","import React, { useEffect } from \"react\";\nimport { Switch, Route, Redirect } from \"react-router-dom\";\nimport { useSelector } from \"react-redux\";\nimport { RootState, selectAccountSettings } from \"./redux/store\";\nimport { useAppSelector } from \"./redux/hooks\";\nimport i18n from \"./i18n\";\n\nimport Layout from \"./components/Layout\";\nimport AuthenticationRouter from \"./components/authentication/AuthenticationRouter\";\nimport AppointmentRouter from \"./components/appointments/AppointmentRouter\";\nimport CustomerRouter from \"./components/customers/CustomerRouter\";\nimport SettingsRouter from \"./components/settings/SettingsRouter\";\nimport ReportsRouter from \"./components/reports/ReportsRouter\";\nimport WhatsAppRouter from \"./components/whatsapp/WhatsAppRouter\"\n\n\nimport Todo from \"./components/Todo\";\nimport { Url } from \"./constants/url\";\nimport { useAlert } from \"./components/common/notifications/AlertProvider\";\n\nimport \"./custom.css\";\nimport AccountSettingsProvider from \"./components/common/infrastructure/AccountSettingsProvider\";\nimport EstablishmentSettingsRouter from \"./components/establishment-settings/EstablismentSettingsRouter\";\nimport PrivacyNoticePage from \"./components/customers/PrivacyNoticePage\";\nimport InformedConsentLetterPage from \"./components/customers/InformedConsentLetterPage\";\nimport { useGlobalThemeCss } from \"./constants/styles\";\n\nfunction App() {\n const dotenv = require(\"dotenv\");\n dotenv.config();\n const isAuthenticated = useSelector((state: RootState) => state.authentication.value);\n let localeApp = useAppSelector(state => state.applicationInterface.locale);\n if (!isAuthenticated) {\n const language = navigator.language;\n switch (language) {\n case 'en':\n case 'en-US':\n //case 'ru-RU':\n localeApp = 'en';\n break;\n default:\n localeApp = 'es';\n }\n }\n if (i18n.language != localeApp) {\n // sometimes useEffect calls to late, so set locale with first run\n void i18n.changeLanguage(localeApp);\n }\n \n const accountSettings = useAppSelector(selectAccountSettings);\n \n useGlobalThemeCss();\n useAlert();\n\n return isAuthenticated ? (\n <Layout>\n <AccountSettingsProvider />\n <Switch>\n <Route path={Url.Appointments.Main} component={AppointmentRouter} />\n <Route path={Url.Customers.Main} component={CustomerRouter} />\n <Route path={Url.FollowUps.Main} component={Todo} />\n <Route \n path={[\n Url.WhatsApp.Main, \n Url.WhatsApp.MassiveSendings\n ]}\n component={WhatsAppRouter}\n />\n <Route \n path={[\n Url.Reports.Main,\n Url.Reports.CustomReport\n ]}\n component={ReportsRouter}\n />\n {!accountSettings.isEnterprise &&\n <Route\n path={[\n Url.Settings.Main,\n Url.Settings.CustomerCommunications,\n Url.Settings.WorkAreas,\n Url.Settings.Services,\n Url.Settings.Users,\n Url.Settings.Payments,\n Url.Settings.ClinicHistory,\n Url.Settings.EvolutionNotes,\n Url.Settings.PatientForm,\n Url.Settings.Commissions,\n ]}\n component={SettingsRouter}\n />\n }\n {accountSettings.isEnterprise &&\n <Route\n path={[\n Url.EstablishmentSettings.General,\n Url.EstablishmentSettings.ClinicHistory,\n Url.EstablishmentSettings.EvolutionNotes,\n Url.EstablishmentSettings.PatientForm,\n ]}\n component={EstablishmentSettingsRouter}\n />\n }\n <Route path={Url.PrivacyNotice} component={PrivacyNoticePage} />\n <Route path={Url.InformedConsentLetter} component={InformedConsentLetterPage} />\n <Route path={Url.Default}>\n <Redirect to={Url.Appointments.Main} />\n </Route>\n </Switch>\n </Layout>\n ) : (\n <AuthenticationRouter />\n );\n}\n\nexport default App;\n","import * as React from \"react\"\nimport { useEffect } from \"react\";\nimport { matchPath, useHistory } from \"react-router-dom\";\n\nimport { useDispatch } from 'react-redux';\nimport { authenticate, deauthenticate } from '../../../redux/authentication-slice';\n\nimport { ApiClient } from \"../../../api/api-client\";\nimport { Url } from \"../../../constants/url\";\n\nexport function AuthenticationProvider() {\n\n const dispatch = useDispatch();\n const history = useHistory();\n\n useEffect(() => {\n ApiClient.initialize().then((result) => result ? authenticateUser() : redirectToLogin());\n }, []);\n \n function authenticateUser() {\n dispatch(authenticate());\n }\n \n function redirectToLogin() {\n dispatch(deauthenticate());\n const location = window.location.pathname;\n const isViableRoute = matchPath(\n location, \n {\n path: [Url.Authentication.Login, Url.Authentication.Recovery, Url.Authentication.ResetPassword, Url.Authentication.Join]\n })?.isExact\n \n if (!isViableRoute) {\n history.push(Url.Authentication.Login);\n }\n }\n\n return null;\n}","// import './wdyr';\n\nimport \"bootstrap/dist/css/bootstrap.css\";\nimport React, { Suspense } from \"react\";\nimport ReactDOM from \"react-dom\";\nimport { BrowserRouter } from \"react-router-dom\";\nimport {unregister} from \"./registerServiceWorker\";\n\nimport { ThemeProvider } from \"@material-ui/core/styles\";\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nimport * as customTypes from \"./material-ui\";\n\nimport store from \"./redux/store\";\nimport { Provider } from \"react-redux\";\n\nimport App from \"./App\";\nimport { AuthenticationProvider } from \"./components/authentication/AuthenticationProvider\";\nimport AlertProvider from \"./components/common/notifications/AlertProvider\";\nimport { ThemeStyles } from \"./constants/styles\";\n\nimport \"./i18n\";\n\nconst baseUrl = document.getElementsByTagName(\"base\")[0].getAttribute(\"href\");\nconst rootElement = document.getElementById(\"root\");\n\nReactDOM.render(\n <BrowserRouter basename={baseUrl || \"/\"}>\n <Provider store={store}>\n <AuthenticationProvider />\n <ThemeProvider theme={ThemeStyles}>\n <Suspense fallback=\"\">\n <AlertProvider>\n <App />\n </AlertProvider>\n </Suspense>\n </ThemeProvider>\n </Provider>\n </BrowserRouter>,\n rootElement\n);\n\nunregister();\n"],"sourceRoot":""}