{"version":3,"sources":["components/Dialogs/SimpleDialog.tsx","hooks/useAuth.tsx","api/scheduleApi.ts","shared/matrix/ui/horizontalLabelWeekDay/index.tsx","components/buttons/StyledButtonLink.tsx","redux/modules/sessionLog.ts","webpack:///./src/assets/info-circle-blue-filled.svg?2371","components/buttons/ActionsControlButton.tsx","utils/StatusInfo.ts","hooks/useGtag.tsx","components/HintText/BTAvailabilityInfoDialog.tsx","components/HintText/ClientCanAddSessionHint.tsx","components/HintText/ClientCanNotAddSessionHint.tsx","components/HintText/ClientHasNotAvailableTimeBlocksHint.tsx","components/HintText/IsPausedHint.tsx","components/HintText/BadAuthorizationHint.tsx","components/HintText/ClientActiveDTAuthHint.tsx","components/HintText/HintText.tsx","hooks/useAddSessions.ts","components/FiltersList.tsx","components/styledMultipleDatePicker/StyledMultipleDatePicker.tsx","clientPortal/sessions/AddSessionFIlters.tsx","clientPortal/sessions/SessionsSubmitted.tsx","clientPortal/sessions/dialogs/SelectTimesDialog.tsx","clientPortal/sessions/matrix/AvailableCell.tsx","clientPortal/sessions/matrix/CellInfo.tsx","clientPortal/sessions/matrix/SelectedCell.tsx","clientPortal/sessions/BookedOptionDetails.tsx","clientPortal/sessions/dialogs/BookDetailsDialog.tsx","clientPortal/sessions/matrix/BookedCell.tsx","clientPortal/sessions/matrix/EmptyCell.tsx","clientPortal/sessions/matrix/AddSessionsMatrix.tsx","clientPortal/sessions/AddSessionsWeekSelector.tsx","clientPortal/sessions/SelectedBookingOptions.tsx","clientPortal/sessions/matrix/AddSessionsMatrixInfo.tsx","clientPortal/sessions/NewSessions.tsx","clientPortal/sessions/dialogs/InfoPopup.tsx","hooks/useSessionTrackerId.tsx","clientPortal/sessions/AddSessions.tsx","hooks/useMaintenanceCheck.tsx","components/Maintenance.tsx","api/socketApi.ts","chat/TeamChannelList/TeamChannelList.tsx","chat/TeamChannelPreview/TeamChannelPreview.tsx","chat/ChannelListContainer/ChannelListContainer.tsx","components/ProviderMobileNumber.tsx","chat/TeamChannelHeader/ProviderInfo.tsx","chat/TeamChannelHeader/ChatMembersModal.tsx","chat/TeamChannelHeader/TeamChannelHeader.tsx","chat/chat-assets/BoldIcon.tsx","chat/chat-assets/HashIcon.tsx","chat/chat-assets/ItalicsIcon.tsx","chat/chat-assets/LightningBoltSmall.tsx","chat/chat-assets/SendButton.tsx","chat/chat-assets/SmileyFace.tsx","chat/chat-assets/StrikeThroughIcon.tsx","chat/TeamMessageInput/ThreadMessageInput.tsx","chat/ChannelContainer/ChannelInner.tsx","chat/ChannelEmptyState/ChannelEmptyState.tsx","chat/TeamMessage/TeamMessage.tsx","chat/TeamTypingIndicator/TeamTypeingIndicator.tsx","chat/TeamMessageInput/TeamMessageInput.tsx","chat/CustomAvatar/CustomAvatar.tsx","chat/ChannelContainer/ChannelContainer.tsx","chat/AttainChat.tsx","components/ErrorBoundry/ErrorBoundry.tsx","api/chatApi.ts","hooks/useAttainChat.tsx","assets/person-bounding-box.svg","assets/person-lines-fill.svg","assets/climb_icon.svg","assets/my-schedule-icon.svg","components/DrawerItemsList.tsx","components/StyledPopper/StyledPopper.tsx","components/ClientSelectionComponent.tsx","components/ProviderRoleSelectionComponent.tsx","hooks/useGroups.tsx","components/PopupMenu.tsx","components/AvatarIconMenu.tsx","components/ChatIconHeader.tsx","components/AppHeader.tsx","hooks/useApiVersionCheck.tsx","api/versionApi.ts","components/AppErrors/AppErrors.tsx","hooks/usePreviousPath.ts","hooks/useActivityTracker.tsx","hooks/useInitializeTimezone.ts","App.tsx","serviceWorker.ts","index.tsx","utils/helpers.ts","api/requestsApi.ts","shared/types.ts","redux/modules/provider.ts","commonPages/MySchedule/utils/helpers.ts","api/admin/usersApi.ts","redux/modules/users.ts","shared/matrix/ui/cell/index.tsx","api/requester.ts","api/admin/adminSettingsApi.ts","api/admin/timeBlocksApi.ts","redux/modules/adminSettings.ts","assets/my-team-badge.svg","components/badges/MyCaseTeamBadge/MyCaseTeamBadgeIcon.tsx","components/table/ProviderCell.tsx","api/bookingApi.ts","redux/modules/chat.ts","api/clientApi.ts","hooks/useSettings.tsx","utils/sessions.ts","api/cancellationApi.ts","redux/modules/sessionRemoval.ts","redux/modules/requests.ts","shared/matrix/ui/horizontalLabelWeekDay/lib.ts","assets/covid-badge.svg","components/badges/CovidBadge/CovidBadgeIcon.tsx","hooks/usePermission.tsx","assets/BCBA-badge.svg","components/badges/BCBABadge/BCBABadgeIcon.tsx","components/badges/BCBABadge/ProviderBCBABadge.tsx","api/maintenanceApi.ts","redux/modules/maintenance.ts","api/notificationsApi.ts","types/sessionUpdates.types.ts","components/CustomLoading/CustomLoading.tsx","redux/modules/schedule.ts","shared/lib/availability.ts","components/ConfirmationDialogTemplate.tsx","commonPages/help/HelpPageContext.ts","components/table/Pagination.tsx","components/table/CustomTableFooter.tsx","redux/modules/menteeProviders.ts","hooks/useNoShowButtonsVisibility.ts","api/googleApiWrapper.ts","api/openSessionsApi.ts","redux/modules/openSessions.ts","shared/constants.ts","redux/modules/feed.ts","redux/modules/action.ts","clientPortal/home/ratingProviders/unrated-suspended-sessions.ts","components/buttons/StyledButton.tsx","hooks/useNoShowTimeLIne.ts","assets/defaultOpenSessionCalendarIcon.svg","redux/modules/alert.ts","api/billingApi.ts","redux/modules/billing.ts","redux/modules/rootReducer.ts","redux/middleware/HandleErrorResponses.ts","redux/middleware/namePropertyMiddleware.ts","redux/store.ts","components/StyledSwitch/StyledSwitch.tsx","components/CalenderEvent/CalendarEvent.tsx","utils/constants.ts","commonPages/MySchedule/types/types.ts","assets/bookingDetails/shortTermType.svg","redux/modules/availability.ts","api/availabilityApi.ts","components/ScreenTitle.tsx","commonPages/MySchedule/layers/sessionLayer/SessionTitleByStatus.tsx","api/sessionUpdatesApi.ts","redux/modules/sessionUpdates.ts","providerPortal/requests/hooks/useOptOutAllowedUntil.ts","assets/optOutAllowedBadge.svg","components/badges/OptOutAllowedBadge/OptOutAllowedBadgeIcon.tsx","assets/info-circle.svg","shared/matrix/ui/index.tsx","shared/matrix/ui/horizontalLabelWeekDay/styles.ts","hooks/useMinutesTimer.ts","utils/geolocation.ts","components/NoShowed/components/DialogMessages/NotHereConfirmationDialogText.tsx","components/NoShowed/components/DialogMessages/StillNotHereConfirmationDialogText.tsx","components/NoShowed/components/Dialogs/ConfirmationDialog.tsx","assets/location_access_icon.svg","components/LocationAccessWarningDialog.tsx","components/NoShowed/components/DialogMessages/RemovedSessionDialogText.tsx","components/NoShowed/components/DialogMessages/ClassroomSupportNoticeDialogText.tsx","components/NoShowed/components/Dialogs/ClassroomSupportNoticeDialog .tsx","components/NoShowed/components/DialogMessages/WaitConfirmationDialogText.tsx","assets/stopwatch.svg","assets/participant_absent.svg","components/NoShowed/NoShowedTrigger.tsx","assets/observation.svg","assets/training.svg","assets/mentorship.svg","providerPortal/sessions/SessionBadge.tsx","components/SessionCard/ClientSessionDetails.tsx","shared/matrix/ui/verticalLabelTimeBlock/index.tsx","components/SessionProviderProfilePicture/SessionProviderProfilePicture.tsx","assets/participant_absent_red.svg","components/NoShowed/NoShowedLauncher.tsx","components/SessionCard/SessionCard.tsx","assets/files.svg","components/JiraStatusBadge/JiraStatusBadge.tsx","assets/flag-icon.svg","shared/matrix/ui/cell/styles.tsx","components/FormContainer/FormContainer.tsx","components/SearchForSub/SearchForSubDialogs.tsx","assets/searchPlus.svg","components/SearchForSub/SearchForSub.tsx","components/SearchForSub/SearchForSubButton.tsx","assets/confirm_icon.svg","redux/modules/notifications.ts","components/badges/Badge.tsx","components/ProviderCardHeader.tsx","components/ProviderCardLanguages.tsx","components/ProviderCardBio.tsx","components/DividerText/DividerText.tsx","configs.ts","accessControl/acl.ts","redux/modules/newSessions.ts","types/types.ts","components/table/OverlappingProvidersCell.tsx","commonPages/MySchedule/layers/sessionLayer/SessionStatusText.tsx","assets/search-for-sub-title-icon.svg","api/jiraApi.ts","redux/modules/jira.ts","api/helpApi.ts","redux/modules/help.ts","api/statesApi.ts","redux/modules/states.ts","api/noticesApi.ts","redux/modules/notices.ts","api/feedbackTagsApi.ts","redux/modules/feedbackTags.ts","api/ratingsApi.ts","redux/modules/ratings.ts","assets/warning-diamond-icon.svg","assets/bookingDetails/booked.svg","assets/bookingDetails/longTermType.svg","assets/bookingDetails/time.svg","assets/bookingDetails/date.svg","assets/bookingDetails/bookedWith.svg","api/providerApi.ts","assets/maintenance-icon.svg","assets/Kyo-care-logo.svg","assets/kyo_rectangles.svg","analytics/AnalyticsTracker.tsx","analytics/useAnalyticsData.tsx","api/analyticsApi.ts","assets/remove_icon.svg","assets/pending_icon.svg","commonPages/MySchedule/utils/statusHelpers.ts","redux/modules/client.ts","theme/theme.ts"],"names":["useStyles","makeStyles","theme","dialog","maxWidth","spacing","margin","dialogPaper","borderRadius","title","padding","display","justifyContent","alignItems","backgroundColor","palette","kyoGray","main","closeIcon","color","justifySelf","content","width","light","SimpleDialog","onClose","children","classNames","dialogProps","open","classes","useTheme","isMobile","useMediaQuery","breakpoints","down","className","root","paper","clsx","fullScreen","disableTypography","variant","onClick","aria-label","AuthContext","React","createContext","useAuth","useContext","clearAllCookies","document","cookie","split","forEach","eqPos","indexOf","name","substring","AuthProvider","dispatch","useDispatch","useState","isAuthenticated","setIsAuthenticated","user","setUser","initialLoading","setInitialLoading","loading","setLoading","authStage","setAuthStage","userInfo","setUserInfo","signInError","registrationError","confirmationError","errors","setErrors","handleChallenge","cognitoUser","challengeName","useEffect","Hub","listen","data","payload","event","Auth","currentAuthenticatedUser","then","catch","finally","signOut","useCallback","a","console","log","signIn","federatedSignIn","provider","CognitoHostedUIIdentityProvider","Google","signInForClients","username","password","curr","message","changeTemporaryPassword","newPassword","firstName","lastName","mobileNumber","completeNewPassword","family_name","phone_number","updatedUser","forgotPassword","resetPassword","verificationCode","forgotPasswordSubmit","confirmSignIn","code","trim","loggedUser","fetchAndUpdateCurrentUser","clearError","errorName","setLastLoggedInUserType","userType","localStorage","setItem","LocalStorageKeys","LAST_LOGGED_IN_USER_TYPE","Provider","value","lastLoggedInUserType","storedUserType","getItem","UserType","Client","getLastLoggedInUserType","fetchUnratedSessions","params","query","queryString","stringify","requester","get","headers","response","json","fetchClientFullSchedule","clientId","startDate","endDate","nestOverlaps","timeBlockDayOfWeekIds","isCancellableByClient","filterCancelled","arrayFormat","fetchProviderFullSchedule","providerId","isCancellableByProvider","createSessionLog","args","post","body","JSON","StyleClassNames","HorizontalLabelWeekDay","labels","DayOfWeekLabelsVariant1","disableWeekends","styles","isDisabled","WeekendIds","includes","momentStartDate","moment","DATE_FORMAT_US","disabled","normal","label","day","add","date","styledButtonLink","kyoBlue","textTransform","fontSize","StyledButtonLink","props","otherProps","createAsyncThunk","scheduleApi","sessionLogSlice","createSlice","initialState","logLoading","logError","actionState","reducers","setSessionLogAction","state","action","clearSessionLogState","extraReducers","builder","addCase","pending","fulfilled","rejected","actions","_extends","Object","assign","target","i","arguments","length","source","key","prototype","hasOwnProperty","call","apply","this","_objectWithoutProperties","excluded","sourceKeys","keys","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","propertyIsEnumerable","_ref2","createElement","clipPath","d","fill","_ref3","id","height","SvgInfoCircleBlueFilled","_ref","svgRef","viewBox","ref","ForwardRef","forwardRef","actionButtons","marginTop","cancelButton","kyoLightGreen","borderColor","successButton","boxShadow","opacity","ActionsControlButton","handleClick","hideButtons","buttonWrapper","buttonRoot","PENDING_COLOR","themeWithOverrides","kyoBurntOrange","RETRACTED_COLOR","kyoGray63","CONFIRMED_COLOR","kyoPastelGreen","DECLINED_COLOR","kyoRed","declinedStatusInfo","pendingStatusInfo","acceptedStatusInfo","retractedStatusInfo","confirmedStatusInfo","holdStatusInfo","pendingOsStatusInfo","pendingSearchingForSubStatusInfo","LongAndShortTermStatusesInfo","RequestStatus","PENDING","DECLINED","EXPIRED","RETRACTED","CONFIRMED","ACCEPTED","DENIED","getSessionsCount","sessions","filter","s","statusId","REMOVED","hasAnyAcceptedOrConfirmedSession","relatedSessions","some","rs","statusColorMap","statuses","CLOSED","getSessionColor","session","statusMapping","find","mapping","getSessionStatusTitle","validSessions","closedStatusInfo","claimedSessionsCount","sessionsCount","OpenSessionStatusesInfo","confirmedSessionsCount","SubOfferStatusesInfo","getStatusInfo","request","type","statusInfoCreator","RequestType","OpenSession","SubOffer","getSessionStatus","bookRequestType","overlappingSessions","os","status","SessionStatus","Confirmed","Cancelled","Pending","gtagId","configs","useGtag","pathname","useLocation","gtagScript","src","setAttribute","dataLayerScript","innerHTML","firstChild","head","insertBefore","gtag","page_path","learnAboutAvailability","dialogTitle","kyoGray2","dialogCloseIcon","cursor","dialogContent","paddingInline","infoIconContainer","marginBottom","availInfo","dark","closeButtonContainer","closeButton","BTAvailabilityInfoDialog","availInfoDialogOpen","setAvailInfoDialogOpen","handleClose","StyledButton","customColor","size","Dialog","DialogTitle","DialogContent","Typography","ListItem","hintTextContainer","ClientCanAddSession","description","assignmentApprovalRequired","includeEnoughOptionsHint","ClientCanNotAddSession","Link","href","SCH_EMAIL","ClientHasNotAvailableBlocks","noSessionsText","IsPausedHint","SCH_PHONE_NUMBER","BadAuthorizationHint","ClientActiveDTAuth","HintText","clientCanRebook","notEnoughAvailableBlocks","clientSTBRAvailability","maxNumberOfSessionsCanBooked","forbidReason","ClientCanAddSessionHint","SINGLE_SESSION_FORBID_REASON","clientPaused","badAuthPeriod","clientActiveDTAuth","ClientCanNotAddSessionHint","useAddSessions","singleSessionProviders","useSelector","newSessions","singleSessionProvidersLoading","getSingleSessionProviders","filters","fetchSingleSessionProviders","getButtonHoverCss","openButton","closed","FiltersList","useButton","buttonClassName","setOpen","IconButton","StyledMultipleDatePicker","style","showOtherDays","background","border","fontWeight","lineHeight","textAlign","gridTemplateColumns","rootMobile","preferredDateCaptionMobile","gap","collapseMobile","gridColumn","filtersWrapper","filtersWrapperMobile","flexDirection","row","preferredRowMobile","filterRow","mobileSwitch","transform","AddSessionFilters","clientAttributes","preferredDates","setPreferredDates","showOptionsOutsideOfMyAvailability","setShowOptionsOutsideOfMyAvailability","isShowMyTeam","setShowMyTeam","filtersListOpen","setFiltersListOpen","isTabletScreen","isMobileScreen","confirm","useConfirm","calendarDefaultCurrentDate","DateObject","calendarMinDate","startOf","toDate","maxDate","Box","multiple","placeholder","format","weekDays","SHORT_WEEK_DAYS","onChange","array","Array","isArray","portal","currentDate","minDate","Collapse","in","StyledSwitch","checked","_","isChecked","container","topContainer","sessionItems","marginLeft","divider","buttonContainer","subTitle","sessionsContainer","flexWrap","sessionCardContainer","marginRight","sessionCardDivider","link","textDecoration","SessionsSubmitted","isShowDetails","setShowDetails","selectedBookingOptions","selectedProvider","AnalyticsTracker","TrackerNames","AddSessionsResultScreen","Divider","map","rebookOption","index","scheduledDate","timeBlockId","to","endIcon","PendingSession","pendingSession","segmentStartUtc","getUtcDateFromSTBRSession","segmentEndUtc","sessionPlacement","duration","undefined","SessionCard","ClientSessionDetails","profilePhoto","covidVaccinatedDate","selectTimeTheme","createMuiTheme","overrides","MUIDataTableHeadCell","MuiPaper","borderBottom","MuiTableBody","paddingLeft","MuiTableCell","radioButton","kyoBlue2","overflowX","durationIcon","contentHeader","scheduleDate","time","SelectTimesDialog","bookOption","handleSave","disabledSessionPlacementIds","selectedSessionPlacement","setSelectedSessionPlacement","columns","options","customBodyRenderLite","dataIndex","sessionPlacements","Radio","startTime","TIME_FORMAT_24HR","TIME_FORMAT_2","humanizedDuration","humanizeDuration","CalendarSrc","alt","DATE_FORMAT","DATE_FORMAT_WEEKDAY_MONTH_YEAR","ThemeProvider","viewColumns","selectableRows","search","print","sort","pagination","download","elevation","responsive","rowHover","icon","AvailableCell","selectedOptionAfter","selectedOptionBefore","disable","useAppDispatch","selected","setSelected","getPlacementEndDate","sessionPlacementGreaterThan","sessionPlacementSmallerThan","endTime","selectedBookOption","cloneDeep","addSelectedBookingOption","CellInfo","useSelectedCellStyles","paddingRight","zIndex","overflow","smallImage","stripedBackground","position","stripe","stripeMobile","SelectedCell","selectedBookingOption","isSmallScreen","from","x","statusIcon","rowWrapper","minHeight","rowTitle","typography","body2","flex","subtitle1","timelapseIcon","confirmedStatusDetails","statusDetails","Accepted","BookedOptionDetails","bookedOption","bookingWith","requestTypeInfo","LongTerm","LongTermTypeSrc","SingleTerm","ShortTermTypeSrc","OpenSessionTypeSrc","rows","DateSrc","BookedWithSrc","TimeSrc","TIME_FORMAT","splice","unshift","header","BookDetailsDialog","bookedOptions","BookedSrc","toISOString","useBookedCellCellStyles","bookedOptionDetailsWrapper","bookedOptionDetailsRow","bookingOptionsWrapper","BookedCell","anchorEl","setAnchorEl","hoverCheckTimeOut","setTimeout","clearTimeout","sortedBookedOptions","sortBy","diff","rootProps","onMouseEnter","currentTarget","onMouseLeave","Popper","placement","transition","disablePortal","TransitionProps","Fade","timeout","Paper","useEmptyCellStyles","kyoSilver","EmptyCell","matrixVerticalLabel","minWidth","matrixVerticalLabelName","subtitle2","matrixVerticalLabelContent","AddSessionsMatrix","cellSizes","weekRange","availableCells","bookedCells","selectedCells","disableAvailableCells","matrixProps","timeBlocks","adminSettings","timeBlocksById","keyBy","cellClasses","useCellStyles","addMainStyles","maxHeight","horizontalLabelStyles","useHorizontalLabelStylesVariant3","horizontalValues","DayOfWeekValues","verticalValues","HorizontalLabel","DayOfWeekLabelsVariant3","weekStart","VerticalLabel","timeBlock","periodNameLength","render","horizontalValue","verticalValue","getTimeBlockDayOfWeekKey","dayOfWeekId","selectedOption","dayStartTimeBlockDayOfWeekId","nextDayTimeBlockDayOfWeekId","someDaySelectedCellsTimeBlockDayOfWeekIds","range","b","n","beforeCells","afterCells","weekSelectorWithButtonsWrapper","weekPicker","weekIcon","firstIcon","borderLeft","borderRight","AddSessionsWeekSelector","weekEnd","handleChange","handleDirectedWeekChange","weeksCount","newWeek","clone","endOf","editable","getFormattedWeekPickerDates","subtract","weeks","indicator","mainContent","paddingBottom","footer","removeButton","SelectedBooingOptions","sortedSelectedBookingOptions","DATE_FORMAT_WEEKDAY_MONTH","Button","removeSelectedBookingOption","info","kyoGray3","availableIcon","bookedIcon","AddSessionsMatrixInfo","avatar","up","providerCard","providerCardText","provideName","letterSpacing","addSessionHeader","matrixCustomContent","gridColumnStart","selectedBookingOptionsWrapper","flexFlow","countAndMatrixInfo","countInfo","getMaxSessionsCount","potentialSessions","numOfAllowedSessions","extraSessions","Math","min","NewSessions","goBack","preferredDate","handleSuccess","currentClient","client","createSessionInProgress","createSessionSuccess","clientSessions","clearSelectedBookingOptions","bookOptionsCount","bookDetails","bookOptions","lastSessionDate","firstSessionDate","minWeekDate","useMemo","maxWeekDate","fetchClientSessions","clearClientSessions","setBookedOptions","tempBookedOptions","blocks","block","push","timeBlockDayOfWeekId","segmentDuration","defaultDate","setWeekRange","inWeekBookOptions","setInWeekBookOptions","inWeekSelectedBookOptions","setInWeekSelectedBookingOptions","inWeekBookedOptions","setInWeekBookedOptions","mapOptionsByTimeBlockDayOfWeekId","mappedOptions","option","weekday","momentWeekStart","momentWeekEnd","inRangeOptionsFilter","blockOption","isBetween","reduce","groupBy","minNumberOfSessionsCanBooked","extraSessionsNumberToSelect","isSubmitDisabled","handleSubmit","createSingleTermBookRequest","maxSessionsCount","numOfPotentialSessions","matrixCustomElements","AddSessionsSelectTime","delay","startIcon","KeyboardBackspace","Avatar","imgProps","referrerPolicy","useVerticalLabelsInsideRows","customElements","LinearProgress","enoughOptions","showTimesButton","filterIcon","InfoPopup","text","handleShowOutsideMyAvailabilityTimes","useSessionTrackerId","interceptorRef","useRef","unregister","startTracking","sessionTrackerId","uuid","current","fetchIntercept","register","url","config","updatedConfig","stopTracking","expandedTableCell","paddingTop","section","warningText","infoSection","getColumns","providers","expandedRow","onExpand","handleAddSession","showPreferredDates","isExpanded","ProviderCell","isToggled","onToggle","isMyTeam","inCaseTeam","preferredDatesAvailability","utc","DATE_FORMAT_MONTH_NAME","join","schedDate","earliest","orderBy","AddSessions","firstRender","isBetweenSmallScreen","only","currentClientLoading","clientSTBRAvailabilityLoading","showInfo","setShowInfo","allProviders","providersOnOtherDates","providersOnPreferredDates","expandedRows","setExpandedRows","setProvidersOnPreferredDates","setProvidersOnOtherDates","useDebounce","debouncedShowOptionsOutsideOfMyAvailability","canClientBook","currentClientId","attributes","pause","debouncedShowMyTeam","clientCanBook","caseTeam","ignoreAvailability","setToInitialState","fetchClientSingleTermBookingAvailability","filteredProviders","otherProviders","handleRowExpand","currentState","newState","setSelectedProvider","getTableOptions","providerList","rowsPerPage","rowsPerPageOptions","expandableRows","expandableRowsHeader","renderExpandableRow","rowMeta","languages","spanish","mandarin","cantonese","languageString","Boolean","TableRow","TableCell","colSpan","bio","rowsExpanded","showLoading","clientSTBRAvailabilityLoaded","showPreferredDateSection","infoIcon","infoCircleSrc","hintText","matchedPreferredDates","smallestPreferredDate","valueOf","setCreateSessionSuccess","AddSessionsSelectProvider","AddSessionsTryLater","ScreenTitle","Comp","CustomLoading","components","TableFooter","CustomTableFooter","warningDiamondIcon","useMaintenanceCheck","maintenanceStatusOn","maintenance","setMaintenance","maintenanceForm","dividerEnd","Maintenance","timer","setInterval","fetchMaintenance","clearInterval","FormContainer","SCH_PHONE_NUMBER_FORMATTED","socket","wait","ms","Promise","resolve","closeSocketConnection","close","openSocketConnection","currentSession","io","apiUrl","token","getIdToken","getJwtToken","transports","reconnection","on","connected","store","fetchUnhandledRequests","fetchFeed","TeamChannelList","memo","error","Hidden","smDown","implementation","mdUp","TeamChannelPreview","channel","setActiveChannel","onChannelChange","isFrozen","frozen","channelName","activeChannel","useChatContext","channelLastMessage","messages","role","onKeyDown","tabIndex","unreadCount","lastMessageAuthor","lastMessageText","slice","renderMessageText","lastMessageDate","created_at","messageDate","isAfter","fromNow","renderMessageTime","customChannelTeamFilter","channels","ChannelListContainer","channelRenderFilterFn","List","listProps","Preview","previewProps","grey","ProviderMobileNumber","mobile","pl","PhoneOutlined","pb","phoneFormat","contents","providerInfoHeader","flexGrow","mentionName","bottom","left","ProviderInfo","pt","ProviderCardHeader","providerAttributes","providerLanguages","ProviderCardBio","useStyle","modalBodyWrapper","enhanceProvider","team","fullProviderInfo","ChatMembersModal","isOpen","members","ConfirmationDialogTemplate","isLast","chatUserId","TeamChannelHeader","useChannelStateContext","isModalOpen","setIsModalOpen","teamHeader","memberList","values","profilePhotos","m","numOfMembers","memberProfiles","prev","attainProviderId","user_id","AvatarGroup","photo","BoldIcon","boldState","resetIconState","setBoldState","bold","xmlns","fillOpacity","HashIcon","cx","cy","r","ItalicsIcon","italicState","setItalicState","italic","LightningBoltSmall","SendButton","SmileyFace","openEmojiPicker","fillRule","clipRule","StrikeThroughIcon","strikeThroughState","setStrikeThroughState","strikeThrough","ThreadMessageInput","GiphyContext","giphyState","setGiphyState","messageInput","useMessageInputContext","deletePressed","nativeEvent","InputEvent","inputType","startsWith","replace","GiphyIcon","ChatAutoComplete","aria-roledescription","EmojiPicker","thirtyDaysAgo","chatHistoryDays","ChannelInner","hasMore","filteredMessages","hasMoreToLoad","earliestMessage","giphyStateObj","sendMessage","useChannelActionContext","teamPermissions","defaultPinPermissions","messagingPermissions","messaging","pinnedPermissions","Alert","severity","Window","MessageList","disableQuotedMessages","pinPermissions","messageActions","MessageInput","grow","overrideSubmitHandler","updatedMessage","attachments","mentioned_users","parent_id","parent","updatedText","sendMessagePromise","logChatPromiseExecution","Thread","additionalMessageInputProps","Input","ChannelEmptyState","userID","member","image","memberString","getUserText","TeamMessage","useMessageContext","pinned","MessageSimple","TeamTypingIndicator","typing","useTypingContext","users","TeamMessageInput","pinsOpen","acceptedFiles","maxNumberOfFiles","multipleUploads","thread","codeState","setCodeState","numberOfUploads","accept","handleFiles","uploadNewFiles","UploadsPreview","stringToColor","string","hash","charCodeAt","toString","substr","CustomAvatar","onMouseOver","shape","setError","loaded","setLoaded","imageSrc","nameStr","initials","getWholeChar","data-testid","flexBasis","onError","onLoad","objectFit","LoadingErrorIndicator","paddingY","ChannelContainer","channelId","queryChannels","existingChannel","setChannel","Channel","EmptyStateIndicator","Message","messageProps","TypingIndicator","customStyles","watch","presence","last_message_at","updated_at","AttainChat","chatClient","channelFilters","showChannels","isChannelListEmpty","showChannelList","setShowChannelList","TeamChat","Chat","ch","closeChannelList","ErrorBoundary","hasError","errorInfo","Component","getToken","getClientIdFromChannelId","pop","StreamChat","getInstance","chatToken","_ref4","_ref5","_ref6","_ref7","y","createStyles","drawerToolbar","borderTopRightRadius","toolbar","listSubHeaderRoot","secondary","overline","pxToRem","addTimeBox","addTimeText","scheduleBox","scheduleText","scheduleHr","kyoBlue1","scheduleTitle","scheduleItemText","useDrawerItemStyles","selectedItem","borderBottomRightRadius","unselectedItem","selectedIcon","unselectedIcon","DrawerItem","location","isActiveRoute","button","component","ListItemIcon","ListItemText","primary","DrawerItemsList","setIsDrawerOpen","checkPermission","usePermission","navigate","useNavigate","clientRoutesAccess","Resources","clientRoutes","providerRoutesAccess","providerRoutes","menteeProviders","unhandledRequestCount","requests","unhandledRequestsCount","currentProvider","isShowClimb","isBT","lgUp","subheader","ListSubheader","disableSticky","HomeOutlined","mdDown","Badge","badgeContent","overlap","DescriptionOutlined","PageMode","schedule","remove","temporary","standard","AddBoxOutlined","MailOutline","HelpOutline","ExitToApp","styledPopper","drawer","arrow","borderWidth","borderStyle","borderLeftColor","top","ARROW_SIZE","borderTopColor","right","StyledPopper","hideArrow","placementDirection","modifiers","element","kyoTeal","withBadge","clientListContainer","overflowY","ClientSelectionComponent","onAction","currentUser","unreadMessagesCountPerClient","chat","validAssociations","associations","assoc","dateRevoked","isVerified","dateVerified","isSelectedClient","hasUnreadMessage","SvgIcon","VisibilityOffOutlined","Visibility","VisibilityOutlined","fetchCurrentClientById","handleSelect","align","providerCellContainer","ProviderRoleSelectionComponent","dialogOpen","setDialogOpen","window","oldUIUrl","useGroups","groups","getSignInUserSession","popupMenu","common","black","rolesAllowedToSwitch","Role","CS","SCH","UserMgr","admin","PopupMenu","closePopup","userGroups","switchRoleAccess","DividerText","AvatarIconMenu","avatarSrc","popupMenuAnchor","setPopupMenuAnchor","ClickAwayListener","onClickAway","aria-controls","aria-haspopup","e","popperOptions","positionFixed","Backdrop","chatIcon","ChatIconHeader","count","unreadMessagesCount","selectTotalUnreadCount","Tooltip","showZero","ChatBubbleOutline","appBar","white","borderBottomStyle","borderBottomWidth","borderBottomColor","appBarZIndex","menuButton","logo","rectangles","navBarControls","AppHeader","isDrawerOpen","idTokenPayload","AppBar","Container","Toolbar","disableGutters","picture","prevState","Menu","useApiVersionCheck","version","setVersion","err","reload","AppErrors","alertMessage","alert","visible","setVisible","Snackbar","anchorOrigin","vertical","horizontal","autoHideDuration","usePreviousPathByRoutesAccess","previousPath","providerPreviousPath","sessionStorage","getPreviousPathByRoutesAccess","setPreviousPath","currentPath","setPreviousPathByRoutesAccess","removePreviousPath","removeItem","useActivityTracker","timerRef","shouldSkipTrackActivity","handleReAuthentication","resetTimer","updateLastActivity","now","Date","LAST_ACTIVITY_KEY","throttledHandleActivity","throttle","throttledHandleStorageChange","addEventListener","removeEventListener","updateLocale","relativeTime","h","Home","lazy","ProviderProfile","Requests","OpenSessions","MyRequests","VerificationForm","Login","ForgotPasswordForm","SessionsRemovalResults","MyUserProfile","HomeForProvider","Alerts","MyClientProfile","HelpPage","Contact","ClientHelpPage","ProviderHelpPage","SwitchToSpanishPage","ClientSettingsPage","ProviderSettingsPage","Climb","MenteeProviders","MyScheduleProvider","MyScheduleClient","SessionUpdatePage","Amplify","configure","cognito","flexShrink","drawerPaper","contentBox","sideBar","suspenseLoading","NotFound","navigateTo","SessionsHOC","resetSessionRemoval","App","initialLocationRef","setChannelId","setIsChannelListEmpty","setClientUnreadCount","setUnreadMessageCountPerClient","listeners","initChat","String","tokenProvider","chatApi","connectUser","countUnread","channelListener","RegExp","test","resetMessageCounts","l","unsubscribe","disconnectUser","useAttainChat","educatorPortalAccess","educatorPortal","reAuthenticationThreshold","useSettings","reAuthenticationTimeout","minutesToMilliseconds","useAppSelector","timezoneIANA","tz","setDefault","setInitialStartTime","useInitializeTimezone","educatorPortalUrl","fetchMenteeProviders","fetchProviderKyoClimbSettings","fetchClientCaseTeam","fetchAttendanceStatusThresholds","fetchSettings","fetchTimeBlocks","fetchCurrentUser","fetchProvider","fetchAttendanceAwards","setCurrentUser","setCurrentClient","scrollTo","useLayoutEffect","selectedClient","nonRevokedAssociations","parse","c","verifiedClient","isOnSpanishPage","Drawer","BackdropProps","invisible","anchor","ModalProps","keepMounted","p","fallback","CircularProgress","path","reloadOnNavigate","backTitle","Number","getFullYear","rel","hostname","match","require","default","ReactDOM","StrictMode","customTheme","CssBaseline","maxSnack","getElementById","navigator","serviceWorker","ready","registration","daysMap","DATE_TIME_FORMAT","NEW_UI_DATE_TIME_FORMAT","NEW_UI_DATE_FORMAT","NEW_UI_DATE_FORMAT_WEEKDAY_FIRST","DATE_FORMAT_MONTH_NAME_SHORT","DATE_FORMAT_MONTH_NAME_WITH_HOUR","DATE_FORMAT_MONTH_NAME_WITH_DAY","DATE_FORMAT_ABBR_MONTH_NAME_WITH_DAY","DATE_FORMAT_MONTH_YEAR","DATE_FORMAT_WEEKDAY_MONTH_YEAR_SHORT","DATE_FORMAT_TIME_MONTH_WITH_DAY","TIME_FORMAT_12HR","MS_IN_HOUR","convert24hrToAmPm","timeString","parseZone","stripCountryCode","phoneNumber","countryCode","regex","prependCountryCode","millisecondsToTime","minutes","floor","hours","newDate","schedDateMoment","sortArrayByDateKey","arr","str","isNaN","charAt","Error","next","phone","configureNotificationDataById","requestData","configuredDataById","item","categoryId","isEnabled","enabledIds","methodId","atLeastOneIsMandatory","category","checkIsPreferenceSelectDisabled","availabilityBlocks","hasAvailability","availabilityBlock","isAvailable","daysToMilliseconds","days","diffOfDatesInDayMilliseconds","date1","date2","momentDate1","momentDate2","datesDiff","ModifiedAvailabilityTimeOffMinStartDate","ModifiedAvailabilityTimeOffMaxStartDate","getFirstSessionAfter","after","asDays","getDiffInDays","toUTCString","getCurrentAvail","sch","DayOfWeekId","Sunday","Saturday","getNumberOfHoursBelowRequiredAvail","minHrsTarget","max","calcAcceptanceRates","defaultText","acceptanceRate","ltAcceptanceRate","round","stAcceptanceRate","isBCBA","getAddressString","street","city","zip","createWeekString","startDateFormat","endDateFormat","start","end","getDurationPartNames","hoursLabel","minutesLabel","humanizedMinutes","toAbsolutePath","URL","portalUrl","toRevenuePortal","revenuePortalUrl","getFullAddress","addressLine1","addressLine2","normalizeSessionLocation","locationCity","locationState","locationAddressLine1","locationAddressLine2","locationZip","el","scrollIntoView","behavior","isTodayBetween5thAndEndOfMonth","today","fifthDayOfMonth","lastDayOfMonth","getProviderProjectedTenur","providerStartDate","formatTenureYearMonth","tenureDays","years","months","getNoticeText","result","isNoShowParticipantRequester","participant","sessionLogs","isProviderRequester","requesterId","isUserRequester","userId","shouldReturnForClient","NoShowParticipant","shouldReturnForProvider","fetchAllRequests","onlyMyRequests","onlyIncompleteRequests","bookingType","limit","offset","sortOrder","page","direction","updateRequestStatus","requestId","newStatus","shouldNotify","updateAvailability","put","updateRequestSessionStatus","actionId","sessionIds","updateSubOfferSessionStatus","AvailabilityStatus","isLoading","providerAttributesLoading","providerFullSchedule","providerFullScheduleLoading","notificationPreferences","notificationPreferencesLoading","notificationPreferencesError","saveNotificationPreferencesLoading","providerAttendanceAwardsLoading","relatedClientIds","providerProjectedLevelLoading","providerProjectedLevel","providerAttendanceAwards","providerKyoClimbSettings","providerKyoClimbSettingsLoading","providerKyoClimbSettingsError","fetchProviderNotificationPreferences","providerApi","res","replaceProviderNotificationPreferences","arg","rejectWithValue","updateProviderAttendanceAward","fetchCurrentProvider","fetchProviderAttributes","updateProviderAttributes","newAttributes","fetchRelatedClients","fetchRelatedClientIds","updateProviderAddress","newProviderAddress","fetchProviderProjectedLevel","fetchProviderAttendanceAwards","providerSlice","providerLoading","setProviderAttributes","clearSearchResult","preference","NotificationMethodId","isSeen","currentProviderAttendanceAward","attendanceAwards","address","firstTimeOffSession","TWO_WEEKS","removeSessionVariant","getRemoveSessionVariant","sessionStart","sessionEnd","isActiveSession","isFirstTimeOff","segmentId","selectNumberOfHoursBelowRequiredAvail","createSelector","preferredBlock3EndValidation","block3Start","block3End","time1","time2","PREFERRED_BLOCK_MIN_INTERVAL","findTempAvailabilityByWeek","stAvail","startOfWeek","weekStartDate","findStandardAvailabilityByWeek","ltAvail","upcomingAvail","Upcoming","currentAvail","Current","findStandardAvailability","findSessionForCellRendering","confirmedSession","TimeOff","getMatrixCellStyle","isSmallGrid","isAvailMode","colors","smallGrid","bigGrid","isCellClickable","pageMode","isPast","scheduleLength","isCancelMode","isChangedAvailability","availability","availabilityByWeek","availabilityForCompare","originalId","preferences","preferredBlock1Start","preferredBlock3Start","preferredBlock3End","isEqual","availabilityWithoutStatus","isChangedAvailabilityStartDate","currentStartDate","initialStartDate","getWeekRange","getPreferredBlockTime","preferenceTime","timeBlockOption","fetchRelationships","updateUser","verifyUserClient","dob","updateUserRelationship","relationshipId","getUserNotificationPreferences","replaceUserNotificationPreferences","usersApi","setUserClientRelationship","fetchUserNotificationPreferences","currentUserLoading","currentUserUpdating","currentUserRequestId","relationships","relationshipsLoading","verificationState","relationshipUpdatedState","updateCurrentUser","getState","usersSlice","setCurrentUserUpdating","setRelationships","setRelationshipsLoading","setVerificationFailed","verificationFailed","resetVerificationState","resetRelationshipUpdatedState","meta","handleClientVerification","verifyAction","isRejected","MatrixCell","onKeyPress","ResponseError","statusText","defaultRequestInit","recoursePath","init","merge","method","patch","delete","getAuthorizationHeader","makeUrl","createRequestInit","requestInit","fetch","ok","authHeader","Authorization","fetchKyoClimbSettings","attendanceAwardsLoading","attendanceAwardsError","attendanceStatusThresholds","settings","isSettingsLoading","isTimeBlocksLoading","adminSettingsApi","adminSettingsSlice","setSettingsLoading","setSettings","timeBlocksLoading","timeBlocksReceived","timeBlocksApi","rx","MyCaseTeamBadgeIcon","CovidBadge","providerCell","viewDetails","badgeContainer","cancelled","whiteSpace","sessionStatus","CovidBadgeIcon","ProviderBCBABadge","fetchBookings","typedStatuses","resp","selectedOptions","retractOSSessions","openSessionId","retractSTSessions","chatSlice","currentChannel","setCurrentChannel","total","clientUnreadCount","fetchClientById","fetchClientGoals","updateClientAttributes","tBlocks","thresholds","minOccupiedLength","setMinOccupiedLength","futureSearchPeriod","setFutureSearchPeriod","swapSessionCount","setSwapSessionCount","btwSessionBuffer","setBtwSessionBuffer","upcomingAvailabilityMinPeriod","setUpcomingAvailabilityMinPeriod","inDemandMinScore","setInDemandMinScore","inDemandMaxRank","setInDemandMaxRank","setTimeBlocks","setAttendanceStatusThresholds","setReAuthenticationThreshold","noShowDelayMinutes","clientNoShowWaitMinutes","providerNoShowWaitMinutes","noShowExtensionMinutes","preNoShowExtensionMinutes","noShowSettings","setNoShowSettings","subOfferOptOutAllowedInHours","setSubOfferOptOutAllowedInHours","settingsByKey","reAuthenticationThresholdInMinutes","isSessionCancellable","isBookRequest","isCancellable","isSessionCancelled","canSearchForSub","cancellationEvent","isEligibleForOS","bookRequestSession","removedBy","RemovedBy","Admin","roundHalf","num","formatSessionDuration","timeUnitFormat","asHours","halfRoundedDuration","unit","pluralSuffix","getSessionTimes","getSessionWith","getProviderSessionsInfo","sessionIsWith","segmentIds","cancelSessions","fetchCancellationEvents","sorting","paging","selectedSessions","cancellationInProgress","retractionInProgress","cancellationError","retractionError","cancellationEvents","cancellationPaidEvents","loadingCancellationEvents","loadingCancellationPaidEvents","cancellationEventsPage","cancellationPaidEventsPage","cancellationEventsTotalCount","cancellationPaidEventsTotalCount","cancelScheduledSegments","thunkAPI","sessionCancellation","scheduleSegments","cancellationApi","retractBookingSessions","api","sessionsByRequest","bookRequestId","all","entries","brId","items","_err","flatMap","cancelBookingSessions","stSessions","mtSessions","bookingApi","stResult","mtResult","createdFromDate","CANCELLATIONS_LAST_DAYS","providerTitles","apiFilters","createdFrom","CancellationEventsSort","SessionStart","SortingDirection","DESC","CANCELLTION_EVENTS_PER_PAGE","fetchCancellationPaidEvents","sessionCancellationSlice","setSessionsToRemove","selectSessionForRemoval","uniqBy","unselectSessionForRemoval","setCancellationEventPage","setCancellationPaidEventPage","resetCancellationEvents","updatedSessions","update","updatedOverlapings","v","updateSegment","isRTO","cancellationEventId","retractedSessions","retractedUpdate","totalItems","previousEvents","concat","isInitial","requestsList","requestsLoading","totalCount","requestsListRequestId","updatingSubOfferSessions","requestsApi","fetchRequestsList","onlyMyRequest","requestType","fetchClientRequests","requestsListSlice","addMatcher","isAnyOf","filterOnlyUpdatingSessionsList","sessionId","isInteger","Monday","Tuesday","Wednesday","Thursday","Friday","getPermission","permissionType","resource","ac","can","readOwn","updateAny","updateOwn","readAny","permissionAttributes","permission","every","attr","granted","BCBABadgeIcon","BCBABadge","rest","maintenanceSlice","setMaintenanceStatus","maintenanceApi","underMaintenance","fetchNotifications","fetchUnreadCount","bulkUpdateIsSeen","ids","SessionUpdateTypeId","ChangeFrequency","ChangedBy","JiraTicketStasusId","loadingContainer","viewMode","PREFERRED_VIEW_MODE_STORAGE_KEY","MyScheduleViewMode","list","showDetails","sessionsToPreviewIds","pickerValue","scheduleByWeek","scheduleByWeekLoading","fetchClientScheduleForWeek","fetchProviderScheduleForWeek","scheduleSlice","local","setSchedePageMode","grid","setScheduleViewMode","showSessionsDetails","hideSessionsDetails","shiftScheduleWeek","week","setScheduleStartOfWeek","setScheduleWeekRange","formattedStartDate","setScheduleMaxDate","sortAvailabilityBlocks","sortedAvailabilityBlocks","getDefaultAvailabilityBlocks","editMatrixBlock","matrixBlocks","matrixBlocksCopy","getLastPastBlock","startDateMoment","weekDay","timeBlockIds","isPastBlock","lastPastBlock","withStyles","other","MuiDialogContent","DialogActions","MuiDialogActions","aria-labelledby","dialogActionStyles","ConfirmationDialogActionsTemplate","cancel","confirmLabel","cancelLabel","HelpPageContext","HelpPageProvider","Pagination","changePage","currentPage","maxShownPages","numOfPages","firstShownPage","isCurrentPage","cell","select","arrowButton","desktopOnly","pageControls","rowCount","changeRowsPerPage","ceil","shownRows","Table","TextField","SelectProps","MenuProps","getContentAnchorEl","InputProps","disableUnderline","opt","MenuItem","KeyboardArrowLeft","KeyboardArrowRight","fetchSelectedMentee","fetchProviderById","fetchSelectedMenteeAttendanceAwards","menteeProvidersSlice","menteeProvidersLoading","selectedMentee","selectedMenteeLoading","selectedMenteeAttendanceAwards","selectedMenteeAttendanceAwardsLoading","selectMenteesCurrentAvailabilities","acc","numberOfHoursBelowRequiredAvail","DEFAULT_BUTTON_VISIBILITY_STATE","canShowIsNotHereButton","canShowStopWatchButton","canShowStillIsNotHereButton","canShowArrivedButton","canShowDisabledArrivedButton","canShowReminderSentButton","hideWaitLongerButton","useNoShowButtonsVisibility","useNoShowTimeLine","showIsNotHere","showStopWatch","showStillIsNotHere","noShowedEnd","preNoShowedEnd","noEligibleActionForDistrictClient","payerType","DISTRICT_PAYER_TYPE","isConfirmedSession","hasLog","actionIds","isNotHereLog","scheduledSessionsLogActions","NotHereActions","stillIsNotHereLog","StillNotHereActions","arrivedLog","ArrivedActions","noArrivedOrStillIsNotHereLogs","GoogleApiWrapper","distanceMatrixService","approvedForTolls","loader","load","google","maps","DistanceMatrixService","getDistanceMatrix","travelMode","TravelMode","DRIVING","avoidFerries","avoidTolls","unitSystem","UnitSystem","IMPERIAL","instance","Loader","apiKey","googleApiKey","googleWrapperInstance","extendWithDriveTimes","originalZipCode","destinations","origins","lat","latitude","lng","longitude","distances","driveTime","elements","fetchOpenSessions","isFromCaseTeam","considerAvailability","zipCodeData","clients","updateOpenSessionRequest","createOpenSessionFromCancellation","openSessionsApi","fetchNumOfPendingRequests","fetchSelectedClientOpenSessions","openSessionsSlice","openSessionsList","openSessionsLoading","updatedSuccess","updatedError","selectedClientOpenSessions","selectedClientOpenSessionsLoading","selectedClientId","requestIdentifier","searchForSubCompletedAt","numOfPendingRequests","numOfPendingRequestsLoading","resetAcceptedState","openSessionsListWithBlocks","openSessionBlocks","tb","AvailabilityType","availabilityPreferredBlocks","RemoveSessionVariantText","RemoveSessionVariant","cancellation","timeOff","retraction","ScheduledSessionsLogActionIds","ClientReportNotHere","ProviderReportNotHere","ClientReportStillNotHere","ProviderReportStillNotHere","ClientReportArrived","ProviderReportArrived","NoShowActionsByReporter","NotHere","StillNotHere","Arrived","thunkApi","bookRequestData","notificationsApi","notificationData","bookRequestFeedItems","br","notificationFeedItems","unsortedFeed","sortedFeed","f","createdAt","slicedFeed","feedSlice","feed","feedLoading","createAction","UnratedSuspendedSessions","storageKey","clientSuspectedSessions","getValue","pullToStorage","newUnratedSessions","without","generateKey","styledButton","sizeLarge","useCustomColor","contrastText","colorClasses","isNotHereAvaiablelEnd","waitStart","sessionStartUtc","waitDuration","waitUntil","waitInMinutes","module","exports","errorSlice","setAlertMessage","fetchInvoices","restFilters","getInvoiceAttachmentUrl","invoiceId","billingApi","fetchInvoiceAttachmentUrl","billingSlice","invoices","invoicesMeta","invoicesLoading","attachmentUrls","attachmentUrlsLoading","isStatusChanging","clearAttachmentUrls","rootReducer","combineReducers","providerReducer","clientReducer","usersReducer","requestsReducer","adminSettingsReducer","sessionCancellationReducer","notifications","notificationReducer","newSessionReducer","maintenanceReducer","chatReducer","availabilityReducer","alertReducer","jira","jiraReducer","help","helpReducer","menteeProvidersReducer","openSessions","openSessionsReducer","states","statesReducer","notices","noticesReducer","feedbackTags","feedbackTagsReducer","ratings","ratingsReducer","billing","billingReducer","sessionLog","sessionLogReducer","scheduleReducer","feedReducer","sessionUpdates","sessionUpdatesReducer","HandleErrorResponses","isRejectedWithValue","namePropertyMiddleware","modifiedData","addNameProperty","defineProperty","enumerable","configurable","middleware","getDefaultMiddleware","immutableCheck","serializableCheck","configureStore","reducer","devTools","process","preloadedState","switchBase","thumb","track","pad","formatDate","getUTCFullYear","getUTCMonth","getUTCDate","getUTCHours","getUTCMinutes","buildUrl","calendarUrl","encodeURIComponent","userAgent","vendor","opera","encodeURI","CalendarEvent","calendarType","blob","Blob","msSaveBlob","icsURL","createObjectURL","tempLink","click","saveCalInvite","SUPPORT_EMAIL","KYO_EMAIL","PROVIDER_MIN_NEW_SESSIONS","SCHEDULING_POLICIES_AND_PROCEDURES_URL","CHANGE_INSURANCE_PLAN_LINK","KYO_CARE_APP","KYO_CLIENT_INSURANCE_SWITCH","ABA_INFO_FOR_FAMILIES","CAREGIVER_RESOURCES","KYO_WEB_AND_APP_PRIVACY_POLICY","CONTACT_BILLING","KYO_CARE_WEB","CENTRAL_REACH_URL","OPEN_SESSION_REQUEST","KYO_CLIMB_INTRANET","REPORT_SESSION_UPDATE_URL","AVAILABILITY_ACTION_STATUS","fetchAvailability","deleteAvailability","createAvailability","createTimeOff","timeOffData","createSTAvailability","updateSTAvailability","fetchPreferredTimeBlockOptions","updateWeeklyAvailabilityState","isPreferredBlock1Disabled","isPreferredBlock3Disabled","preferredTimeBlockOptions","block1StartOptions","block3StartOptions","block3EndOptions","ADD","EDIT","ADD_TEMPORARY","EDIT_TEMPORARY","initialActionState","PASSIVE","succeeded","failed","stAvailability","ltAvailability","availabilityIdentifier","Symbol","preferredTimeBlockOptionsLoading","preferredTimeBlockOptionsError","standardStartDate","lastSelectedBlock","sessionsToRemove","sessionsToRemoveLoading","sessionsToRemoveError","isAvailabilityChanged","isReviewChanges","isStandardUpdate","availabilityApi","fetchSessionsToRemoveClient","fetchSessionsToRemoveProvider","availabilitySlice","setActionStatus","clearSessionsToRemove","setAvailabilityChanged","setReviewChanges","setStandardUpdate","setAvailabilityByWeek","avail","updateAvailabilityByWeek","setStandardStartDate","setLastSelectedBlock","ShortTerm","sessionsWithRemoveVariant","heading","statusTitle","SessionTitleByStatus","StatusIcon","getIconForStatus","visibleToClient","createSessionUpdate","sessionUpdatesDto","getSessionUpdateTypes","scheduledSession","sessionUpdateTypes","sessionUpdateTypesLoading","selectedSessionUpdateTypeId","sessionUpdateSubmitting","submittedSessionUpdate","submitSessionUpdate","sessionUpdatesApi","fetchSessionUpdateTypes","sessionUpdatesSlice","setScheduledSession","selectSessionUpdateTypeId","resetSessionUpdateState","refreshedScheduleSession","useOptOutAllowedUntil","stroke","strokeLinejoin","OptOutAllowedBadgeIcon","labelsJss","horizontalLabels","hasVerticalLabels","verticalLabels","hasHorizontalLabels","gridRowStart","insideRowsLabel","matrix","columnLength","placeItems","Matrix","InsideRowsLabel","rowsLength","InsideRowsLabelLocal","hv","hvi","vv","vvi","Fragment","commonStyles","MAIN","DISABLED","useHorizontalLabelStylesVariant1","LABEL","DAY","useMinutesTimer","prevMinutes","getGeolocationPermission","permissions","getGeolocationCoords","reject","geolocation","getCurrentPosition","pos","coords","enableHighAccuracy","NotHereConfirmationDialogText","DistrictClient","StillNotHereConfirmationDialogText","participantTypeLabel","toLowerCase","ConfirmationDialog","onCreateSessionLog","hideSuccessButton","strokeWidth","strokeMiterlimit","strokeLinecap","x1","y1","x2","y2","gradientUnits","stopColor","instructions","Chrome","Firefox","Safari","Edge","Other","contentTitle","LocationAccessWarningDialog","detectBrowser","infoText","RemovedSessionDialogText","toLocaleLowerCase","ClassroomSupportNoticeDialogText","ClassroomSupportNoticeDialog","WaitConfirmationDialogText","providerName","stillAbsentLabel","stopwatchTitle","stopwatchTime","buttonHr","hr","infoTextWrapper","notHereButton","stillNotHere","arrivedButton","kyoDollarBill","disabledArrivedButton","stopWatchButton","kyoRed3","NoShowedTrigger","clientFullScheduleLoading","fullScheduleLoading","useNoShowedButtonsVisibility","waitInterval","setWaitInterval","openClassroomSupportNoticeDialog","setOpenClassroomSupportNoticeDialog","geolocationLoading","setGeolocationLoading","actionParams","abs","showNotHereConfirmationDialog","showStillNotHereConfirmationDialog","fetchGeolocationCoords","geolocationCoordsResult","handleActionLogCreation","shouldFetchGeolocation","geolocationCoords","handleSetShowDetails","handleNoShowedButtonClick","reassignAllowed","executeGeolocationAndDispatchAction","GeolocationPromptAction","ShowWarning","pRetry","retries","locationAccessWarningDialog","orientation","handleArrivedButtonClick","SessionBadge","Icon","textColor","billingCode","kyoPurple","providerInfo","sessionExpandedDetailsLinks","overlapProviderInfo","hideProviders","segmentStart","segmentEnd","currentClientName","clientName","sessionsStatus","uniqueProviders","labelContainer","timeText","labelName","TimeText","suffix","momentDate","toUpperCase","VerticalLabelTimeBlock","profilePicture","small","large","SessionProviderProfilePicture","uniqProviders","OverlappingProvidersCell","showCount","noShow","reminderSendedLabel","reminderSentButton","NoShowedLauncher","boxProps","sessionCard","sessionViewDetails","sessionCancel","sessionTimes","sessionWith","avatarContainer","badge","noShowParticipant","onCancel","hideSessionWith","hideProviderProfilePicture","viewDetailsButtonText","isSubOfferSession","optOutAllowedUntil","showOptOutAllowed","isSameOrBefore","SearchForSub","showButton","sessionUpdate","jiraItem","JiraStatusBadge","jiraTicketStatusId","marginY","closeDialog","SvgFiles","yellow","fade","red","green","Open","ResponseReceived","colorClass","WaitingOnResponse","Done","getStatusConfig","SvgFlagIcon","restStyles","formContainer","innerContainer","wrapper","titleIcon","textWithBullet","orangeText","SearchForSubDialogWrapper","SearchForSubInfoTitleIcon","mt","SearchForSubConfirmDialog","confirmHandler","declineHandler","mb","SearchForSubEnableAttributeDialog","SearchForSubAttributeEnabledDialog","SearchForSubCompleteDialog","SearchForSubSteps","SearchForSubButton","updatingClientAttributes","isSearchForSubAttributeEnabled","searchForSub","step","setStep","ConfirmSearch","requestStatus","SearchComplete","EnablePreference","EnablePreferenceComplete","SvgConfirmIcon","notificationsLoading","notificationsRequestId","selectedRows","isSelectMode","isSelectAll","notificationApi","notificationsSlice","setTotal","setSelectedRows","setUnreadCount","setIsSelectMode","setIsSelectAll","selectRow","rowId","deselectRow","ProviderLanguages","attrLanguages","REACT_APP_CHAT_TOKEN","REACT_APP_API_URL","REACT_APP_PORTAL_URL","REACT_APP_EDUCATOR_PORTAL_URL","REACT_APP_COGNITO_REGION","REACT_APP_COGNITO_USERPOOL","REACT_APP_COGNITO_CLIENT_ID","REACT_APP_COGNITO_USERPOOL_BASE_URI","REACT_APP_COGNITO_TOKEN_SCOPES","REACT_APP_COGNITO_AUTH_FLOW_TYPE","REACT_APP_SCH_PORTAL_URL","REACT_APP_COGNITO_COOKIE_DOMAIN","REACT_APP_REVENUE_PORTAL_URL","REACT_APP_CHAT_HISTORY_DAYS","region","userPoolId","userPoolWebClientId","oauth","domain","scope","redirectSignIn","redirectSignOut","responseType","authenticationFlowType","appBarColor","cookieStorage","sameSite","secure","BookingAttr","AttributePermission","grantsObject","userAttributes","general","telehealthWaiver","preferredServiceZip","singleBookingAvailability","switchRole","RevenueTeam","AccessControl","singleSessionProvidersAbortController","fetchProvidersForSingleBook","signal","clientApi","createSessionFailed","cancellationIds","osStartDate","osEndDate","clientSTBRAvailabilityError","AbortController","sessionsLoading","unratedSessions","unratedSessionsLoading","sessionsToRate","showSuspectedSessions","noLatestSessionsToRate","newSessionsSlice","removeOptionIndex","findIndex","clonedSelectedBookingOptions","removeSessionFromRatingQueue","restSessions","setShowSuspectedSessions","abort","scheduledDates","bo","excludeRemovedSessions","fetchedSessions","fs","unratedSuspendedSessions","oldUnratedSessions","suspendedSessionId","SingleTermRequestType","RequestAction","LanguagePreference","NotificationTab","RequestsTab","JiraTicketTypeId","SingleBookingAvailabilityType","ClimbLevels","InvoiceStatus","ClientInvoiceStatus","JiraTicketTypeCategory","SessionStatusText","getStatusColors","isRemovedByYou","hasCancellationEvent","Hold","getSessionStatusText","fetchJiraTicketTypes","queryParams","URLSearchParams","append","jiraApi","jiraSlice","loadingJiraTicketTypes","jiraTicketTypes","createHelpRequest","jiraTicketTypeId","helpWith","helpApi","helpSlice","creatingHelpRequest","creatingHelpRequestSucceed","resetHelpRequestState","fetchStates","stateApi","statesSlice","loadingStates","fetchNotice","noticesApi","noticesSlice","notice","noticeLoading","jwtDecode","fetchFeedbackTags","feedbackTagsApi","loadingFeedbackTags","createRating","ratingDto","creating","success","ratingsApi","resetState","fetchSwapProviders","subjectProviderId","radius","awardId","mentorId","includeSchedule","includeCalculations","includeStats","includeLevel","providerAddress","useAnalyticsData","isReady","storeAnalytics","tracked","trackedState","visitedPage","statusColors","confirmed","available","simplifyStatus","formattedStatus","iconByStatus","RemoveIcon","PendingIcon","ConfirmIcon","scheduleSegment","caseTeamLoading","clientFullSchedule","clientFullScheduleRequestId","goals","goalsLoading","clientsSlice","setCaseTeamLoading","setCaseTeam","setClientFullScheduleLoading","setCurrentClientLoading","setGoals","setGoalsLoading","skipLoading","SessionRemovalModule","statusCode","kyoGreen","kyoYellow","kyoRed2","kyoMagenta","kyoDarkGreen","kyoDarkestGreen","kyoLightRed","kyoOrange","kyoPastelOrange","kyoOrangeRed","kyoSkyBlue","kyoPastelRed","kyoBondiBlue","kyoPink","kyoGray4","kyoLavender","xs","sm","md","lg","xl","fontFamily","h1","h2","h3","h4","h5","h6","body1","caption","MuiCssBaseline","MUIDataTableToolbar","titleText","MUIDataTableBodyCell","overflowWrap","borderTop","MuiCircularProgress","colorPrimary","MuiLinearProgress","barColorPrimary","MuiPickersToolbar","MuiPickersToolbarText","toolbarTxt","toolbarBtnSelected","MuiPickersDay","daySelected","MuiPickersBasePicker","pickerView","MUIDataTableSelectCell","headerCell","MUIDataTable","tableRoot","tbody","borderTopWidth","MuiDialog","getMenteesTableTheme","MuiTableHead","MuiDivider"],"mappings":"oHAAA,yGAeMA,EAAYC,aAAW,SAACC,GAAD,MAAmB,CAC9CC,OAAQ,CACNC,SAAUF,EAAMG,QAAQ,IACxBC,OAAQ,QAEVC,YAAa,CACXC,aAAcN,EAAMG,QAAQ,MAE9BI,MAAO,CACLC,QAASR,EAAMG,QAAQ,GACvBM,QAAS,OACTC,eAAgB,gBAChBC,WAAY,SACZC,gBAAiBZ,EAAMa,QAAQC,QAAQC,MAEzCC,UAAW,CACTR,QAAS,EACTS,MAAO,QACPC,YAAa,YAEfC,QAAS,CACPX,QAASR,EAAMG,QAAQ,GACvB,uBAAwB,CACtBiB,MAAOpB,EAAMG,QAAQ,OAEvB,6BAA8B,CAC5BS,gBAAiBZ,EAAMa,QAAQC,QAAQO,OAEzC,6BAA8B,CAC5BT,gBAAiBZ,EAAMa,QAAQC,QAAQC,WA4D9BO,IA9CM,SAAC,GAOI,IANxBC,EAMuB,EANvBA,QAMuB,IALvBhB,aAKuB,MALf,GAKe,EAJvBiB,EAIuB,EAJvBA,SACAC,EAGuB,EAHvBA,WACAC,EAEuB,EAFvBA,YAEuB,IADvBC,YACuB,SACjBC,EAAU9B,IACVE,E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nB,gBAAiB,CACfz0C,MAAO,aAOJoP,O","file":"static/js/main.c404394e.chunk.js","sourcesContent":["import React from 'react';\nimport {\n Dialog,\n DialogProps,\n DialogTitle,\n IconButton,\n Theme,\n Typography,\n makeStyles,\n useMediaQuery,\n useTheme,\n} from '@material-ui/core';\nimport CloseIcon from '@material-ui/icons/Close';\nimport clsx from 'clsx';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n dialog: {\n maxWidth: theme.spacing(70),\n margin: 'auto',\n },\n dialogPaper: {\n borderRadius: theme.spacing(1.5),\n },\n title: {\n padding: theme.spacing(2),\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n backgroundColor: theme.palette.kyoGray.main,\n },\n closeIcon: {\n padding: 0,\n color: 'black',\n justifySelf: 'flex-end',\n },\n content: {\n padding: theme.spacing(2),\n '&::-webkit-scrollbar': {\n width: theme.spacing(1.25),\n },\n '&::-webkit-scrollbar-track': {\n backgroundColor: theme.palette.kyoGray.light,\n },\n '&::-webkit-scrollbar-thumb': {\n backgroundColor: theme.palette.kyoGray.main,\n },\n },\n}));\n\ninterface SimpleDialogProps {\n onClose: () => void;\n title?: string;\n children: React.ReactNode;\n classNames?: Partial>;\n dialogProps?: Omit;\n open?: boolean;\n}\n\nconst SimpleDialog = ({\n onClose,\n title = '',\n children,\n classNames,\n dialogProps,\n open = true,\n}: SimpleDialogProps) => {\n const classes = useStyles();\n const theme = useTheme();\n const isMobile = useMediaQuery(theme.breakpoints.down('xs'));\n\n return (\n \n \n \n {title}\n \n \n \n \n \n
\n {children}\n
\n \n );\n};\n\nexport default SimpleDialog;\n","import React, { useCallback, useContext, useEffect, useState } from 'react';\nimport { useDispatch } from 'react-redux';\nimport { Auth, CognitoUser } from '@aws-amplify/auth';\nimport { Hub } from '@aws-amplify/core';\nimport { CognitoHostedUIIdentityProvider } from '@aws-amplify/auth/lib/types';\nimport { fetchAndUpdateCurrentUser } from '../redux/modules/users';\nimport { LocalStorageKeys, UserType } from '../types/types';\n\ntype AuthStage =\n | 'SignedIn'\n | 'SignedOut'\n | 'ForgotPassword'\n | 'NewPassword'\n | 'ConfirmSignIn';\n\ninterface CognitoUserWithChallenge extends CognitoUser {\n challengeName: string;\n challengeParam: { CODE_DELIVERY_DESTINATION: string };\n}\n\ntype UserInfo = {\n firstName: string;\n lastName: string;\n mobileNumber: string;\n};\n\ninterface AuthErrors {\n signInError: string | null;\n registrationError: string | null;\n confirmationError: string | null;\n}\n\ninterface AuthContext {\n isAuthenticated: boolean;\n user: CognitoUserWithChallenge | null;\n initialLoading: boolean;\n loading: boolean;\n signOut: () => void;\n signIn: () => void;\n signInForClients: (username: string, password: string) => void;\n authStage: string;\n changeTemporaryPassword: (\n newPassword: string,\n firstName: string,\n lastName: string,\n mobileNumber: string\n ) => Promise;\n forgotPassword: (username: string) => void;\n resetPassword: (\n username: string,\n verificationCode: string,\n newPassword: string\n ) => void;\n confirmSignIn: (code: string) => void;\n errors: AuthErrors;\n clearError: (err: keyof AuthErrors) => void;\n lastLoggedInUserType: UserType;\n setLastLoggedInUserType: (userType: UserType) => void;\n}\n\ntype Props = {\n children: React.ReactNode;\n};\n\nexport const AuthContext = React.createContext({} as AuthContext);\n\nexport const useAuth = () => useContext(AuthContext);\n\nconst clearAllCookies = () => {\n const cookies = document.cookie.split(';');\n\n cookies.forEach((cookie) => {\n const eqPos = cookie.indexOf('=');\n const name = eqPos > -1 ? cookie.substring(0, eqPos) : cookie;\n\n document.cookie = `${name}=;Max-Age=0;path=/`;\n });\n};\n\nexport const AuthProvider = ({ children }: Props) => {\n const dispatch = useDispatch();\n // TODO REMOVE isAuthenticated and use authStage to track auth state\n const [isAuthenticated, setIsAuthenticated] = useState(false);\n const [user, setUser] = useState(null);\n const [initialLoading, setInitialLoading] = useState(true);\n const [loading, setLoading] = useState(true);\n const [authStage, setAuthStage] = useState('SignedOut');\n const [userInfo, setUserInfo] = useState(null);\n const [errors, setErrors] = useState({\n signInError: null,\n registrationError: null,\n confirmationError: null,\n });\n\n const handleChallenge = (cognitoUser: CognitoUserWithChallenge) => {\n if (cognitoUser.challengeName === 'NEW_PASSWORD_REQUIRED') {\n setUser(cognitoUser);\n setAuthStage('NewPassword');\n } else if (cognitoUser.challengeName === 'SMS_MFA') {\n setUser(cognitoUser);\n setAuthStage('ConfirmSignIn');\n } else {\n setUser(cognitoUser);\n setAuthStage('SignedIn');\n setIsAuthenticated(true);\n setLoading(false);\n }\n };\n\n useEffect(() => {\n Hub.listen('auth', (data) => {\n switch (data.payload.event) {\n case 'signIn_failure':\n setIsAuthenticated(false);\n setAuthStage('SignedOut');\n setUser(null);\n break;\n case 'signOut':\n setIsAuthenticated(false);\n setAuthStage('SignedOut');\n setUser(null);\n break;\n case 'tokenRefresh_failure':\n setIsAuthenticated(false);\n setAuthStage('SignedOut');\n setUser(null);\n break;\n default:\n break;\n }\n });\n setInitialLoading(true);\n\n Auth.currentAuthenticatedUser()\n .then((cognitoUser) => {\n handleChallenge(cognitoUser);\n })\n .catch(() => {\n setIsAuthenticated(false);\n setAuthStage('SignedOut');\n })\n .finally(() => {\n setLoading(false);\n setInitialLoading(false);\n });\n }, []);\n\n const signOut = useCallback(async () => {\n try {\n await Auth.signOut();\n setErrors({\n signInError: null,\n registrationError: null,\n confirmationError: null,\n });\n } catch (error) {\n console.log('error signing out: ', error);\n }\n }, []);\n\n const signIn = async () => {\n clearAllCookies(); // make sure cookies are removed before sign-in;\n await Auth.federatedSignIn({\n provider: CognitoHostedUIIdentityProvider.Google,\n });\n };\n\n const signInForClients = async (username: string, password: string) => {\n setLoading(true);\n setErrors((curr) => ({ ...curr, signInError: null }));\n try {\n clearAllCookies(); // make sure cookies are removed before sign-in\n const cognitoUser = await Auth.signIn(username, password);\n handleChallenge(cognitoUser);\n } catch (e: any) {\n setErrors((curr) => ({ ...curr, signInError: e.message }));\n } finally {\n setLoading(false);\n }\n };\n\n const changeTemporaryPassword = async (\n newPassword: string,\n firstName: string,\n lastName: string,\n mobileNumber: string\n ) => {\n setLoading(true);\n setErrors((curr) => ({ ...curr, registrationError: null }));\n setUserInfo({ firstName, lastName, mobileNumber });\n\n try {\n /* eslint-disable @typescript-eslint/camelcase */\n const updatedUser = await Auth.completeNewPassword(user, newPassword, {\n name: `${firstName} ${lastName}`,\n family_name: lastName,\n phone_number: mobileNumber,\n });\n /* eslint-enable @typescript-eslint/camelcase */\n handleChallenge(updatedUser);\n setLoading(false);\n } catch (e: any) {\n setErrors((curr) => ({ ...curr, registrationError: e.message }));\n }\n };\n\n const forgotPassword = async (username: string) => {\n try {\n await Auth.forgotPassword(username);\n } catch (e: any) {\n console.log(e);\n throw e;\n }\n };\n\n const resetPassword = async (\n username: string,\n verificationCode: string,\n newPassword: string\n ) => {\n try {\n await Auth.forgotPasswordSubmit(username, verificationCode, newPassword);\n } catch (e: any) {\n console.log(e);\n throw e;\n }\n };\n\n const confirmSignIn = async (code: string) => {\n setLoading(true);\n try {\n const loggedUser = await Auth.confirmSignIn(\n user,\n code.trim(), // Confirmation code\n 'SMS_MFA' // MFA Type e.g. SMS_MFA, SOFTWARE_TOKEN_MFA\n );\n delete loggedUser.challengeName;\n if (userInfo) {\n const { firstName, lastName, mobileNumber } = userInfo;\n await dispatch(\n fetchAndUpdateCurrentUser({ firstName, lastName, mobileNumber })\n );\n setUserInfo(null);\n }\n handleChallenge(loggedUser);\n } catch (e: any) {\n setErrors((curr) => ({ ...curr, confirmationError: e.message }));\n\n if (e.code === 'NotAuthorizedException') {\n setAuthStage('SignedOut');\n setIsAuthenticated(false);\n setUserInfo(null);\n }\n } finally {\n setLoading(false);\n }\n };\n\n const clearError = useCallback((errorName: keyof AuthErrors) => {\n setErrors((curr) => ({ ...curr, [errorName]: null }));\n }, []);\n\n const setLastLoggedInUserType = useCallback((userType: UserType) => {\n localStorage.setItem(LocalStorageKeys.LAST_LOGGED_IN_USER_TYPE, userType);\n }, []);\n\n const getLastLoggedInUserType = () => {\n const storedUserType = localStorage.getItem(\n LocalStorageKeys.LAST_LOGGED_IN_USER_TYPE\n );\n\n if (storedUserType) {\n return storedUserType as UserType;\n }\n return UserType.Client;\n };\n\n return (\n \n {children}\n \n );\n};\n","import queryString from 'query-string';\n\nimport requester from './requester';\nimport {\n ScheduledSessionsLogActionIds,\n ScheduledSession,\n UnratedSession,\n} from '../types/types';\n\nexport interface FetchFullScheduleParams {\n startDate?: string;\n endDate?: string;\n timeBlockDayOfWeekIds?: number[];\n isCancellableByProvider?: boolean;\n filterCancelled?: boolean;\n}\n\nexport interface FetchProviderFullScheduleParams\n extends FetchFullScheduleParams {\n providerId: number;\n}\n\nexport interface CreateSessionLog {\n actionId: ScheduledSessionsLogActionIds;\n segmentId: number;\n clientId: number;\n providerId: number;\n latitude?: number;\n longitude?: number;\n}\n\nexport interface FetchUnratedSessionsFilters {\n clientId: number;\n}\n\nconst fetchUnratedSessions = async (params: FetchUnratedSessionsFilters) => {\n const query = queryString.stringify(params);\n return requester\n .get(`scheduled-sessions/unrated?${query}`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n })\n .then((response) => response.json() as Promise<{ data: UnratedSession[] }>)\n .then((response) => response.data);\n};\n\nconst fetchClientFullSchedule = async (\n clientId: number,\n startDate: string,\n endDate: string,\n nestOverlaps: boolean,\n timeBlockDayOfWeekIds?: number[],\n isCancellableByClient?: boolean,\n filterCancelled?: boolean\n): Promise => {\n const query = queryString.stringify(\n {\n startDate,\n endDate,\n nestOverlaps,\n timeBlockDayOfWeekIds,\n isCancellableByClient,\n filterCancelled,\n },\n { arrayFormat: 'bracket' }\n );\n return requester\n .get(`user-api/sessions/clients/${clientId}?${query}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchProviderFullSchedule = async ({\n providerId,\n startDate,\n endDate,\n timeBlockDayOfWeekIds,\n isCancellableByProvider,\n filterCancelled,\n}: FetchProviderFullScheduleParams): Promise => {\n const query = queryString.stringify(\n {\n startDate,\n endDate,\n timeBlockDayOfWeekIds,\n isCancellableByProvider,\n filterCancelled,\n },\n { arrayFormat: 'bracket' }\n );\n return requester\n .get(`user-api/sessions/providers/${providerId}?${query}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst createSessionLog = async (args: CreateSessionLog) => {\n return requester\n .post('scheduled-sessions-logs', {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(args),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n fetchUnratedSessions,\n fetchClientFullSchedule,\n fetchProviderFullSchedule,\n createSessionLog,\n};\n","import clsx from 'clsx';\nimport React from 'react';\nimport moment from 'moment';\n\nimport { DayOfWeekId } from '../../../constants';\nimport { DayOfWeekLabels, DayOfWeekLabelsVariant1, WeekendIds } from './lib';\nimport { DATE_FORMAT_US } from '../../../../utils/helpers';\n\nexport enum StyleClassNames {\n MAIN = 'main',\n NORMAL = 'normal',\n DISABLED = 'disabled',\n LABEL = 'label',\n DAY = 'day',\n}\n\ninterface HorizontalLabelWeekDayProps {\n value: DayOfWeekId;\n labels?: DayOfWeekLabels;\n disableWeekends?: boolean;\n styles?: Partial<{\n [StyleClassNames.MAIN]: string;\n [StyleClassNames.NORMAL]: string;\n [StyleClassNames.DISABLED]: string;\n [StyleClassNames.LABEL]: string;\n [StyleClassNames.DAY]: string;\n }>;\n startDate?: string;\n}\n\nconst HorizontalLabelWeekDay = ({\n value,\n labels = DayOfWeekLabelsVariant1,\n disableWeekends = false,\n styles,\n startDate,\n}: HorizontalLabelWeekDayProps) => {\n const isDisabled = disableWeekends && WeekendIds.includes(value);\n const momentStartDate = moment(startDate, DATE_FORMAT_US);\n\n return (\n \n
{labels[value]}
\n {startDate && (\n
\n {momentStartDate.add(value, 'days').date()}\n
\n )}\n \n );\n};\n\nexport default HorizontalLabelWeekDay;\n","import React from 'react';\nimport { Button, ButtonProps, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n styledButtonLink: {\n color: theme.palette.kyoBlue.main,\n padding: 0,\n textTransform: 'none',\n fontSize: 14,\n },\n}));\n\nconst StyledButtonLink = (\n props: ButtonProps\n) => {\n const { className, ...otherProps } = props;\n const classes = useStyles();\n\n return (\n \n );\n};\n\nexport default StyledButtonLink;\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport {\n GeolocationPromptAction,\n ScheduledSessionLog,\n ScheduledSessionsLogActionIds,\n} from '../../types/types';\nimport scheduleApi, { CreateSessionLog } from '../../api/scheduleApi';\n\nexport const createSessionLog = createAsyncThunk(\n 'sessioLog/createSessionLog',\n (payload: CreateSessionLog) => scheduleApi.createSessionLog(payload)\n);\n\ninterface SessionLog {\n logLoading: boolean;\n logError: boolean;\n log: ScheduledSessionLog | null;\n actionState: (ScheduledSessionsLogActionIds & GeolocationPromptAction) | null;\n}\n\nconst initialState: SessionLog = {\n logLoading: false,\n logError: false,\n log: null,\n actionState: null,\n};\n\nexport const sessionLogSlice = createSlice({\n name: 'sessionLog',\n initialState,\n reducers: {\n setSessionLogAction: (state, action) => {\n state.actionState = action.payload;\n },\n clearSessionLogState: (state) => {\n state.logLoading = false;\n state.logError = false;\n state.log = null;\n state.actionState = null;\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(createSessionLog.pending, (state) => {\n state.logLoading = true;\n state.logError = false;\n })\n .addCase(createSessionLog.fulfilled, (state, action) => {\n state.logLoading = false;\n state.log = action.payload;\n })\n .addCase(createSessionLog.rejected, (state) => {\n state.logError = true;\n state.logLoading = false;\n state.log = null;\n });\n },\n});\n\nexport const {\n setSessionLogAction,\n clearSessionLogState,\n} = sessionLogSlice.actions;\n\nexport default sessionLogSlice.reducer;\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(\"g\", {\n clipPath: \"url(#clip0_14956_307728)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M24 48C37.2548 48 48 37.2548 48 24C48 10.7452 37.2548 0 24 0C10.7452 0 0 10.7452 0 24C0 37.2548 10.7452 48 24 48Z\",\n fill: \"#72CEE5\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M48.001 23.9997C48.001 22.9425 47.9235 21.9019 47.7907 20.8779L24.9309 12.0938V34.245L20.8516 35.889L40.0637 41.8281C44.9346 37.4332 48.001 31.0735 48.001 23.9997Z\",\n fill: \"#44C0DD\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M21.9025 33.095V22.6061H20.8563C20.2752 22.6061 19.8047 22.1356 19.8047 21.56V20.8626C19.8047 20.2814 20.2752 19.8109 20.8563 19.8109H25.0519C25.6331 19.8109 26.1036 20.2814 26.1036 20.8626V33.1006H27.1497C27.7309 33.1006 28.2014 33.5711 28.2014 34.1467V34.8441C28.2014 35.4253 27.7309 35.8958 27.1497 35.8958H20.8563C20.2752 35.8958 19.8047 35.4253 19.8047 34.8441V34.1467C19.8047 33.5655 20.2752 33.1006 20.8563 33.1006H21.9025V33.095ZM26.801 14.9124C26.801 16.4567 25.5501 17.7076 24.0058 17.7076C22.4615 17.7076 21.2106 16.4567 21.2106 14.9124C21.2106 13.3681 22.4615 12.1172 24.0058 12.1172C25.5501 12.1172 26.801 13.3681 26.801 14.9124Z\",\n fill: \"white\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_14956_307728\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 48,\n height: 48,\n fill: \"white\"\n})));\n\nvar SvgInfoCircleBlueFilled = function SvgInfoCircleBlueFilled(_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: 48,\n height: 48,\n viewBox: \"0 0 48 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(SvgInfoCircleBlueFilled, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/info-circle-blue-filled.ad49bab4.svg\";\nexport { ForwardRef as ReactComponent };","import { Button, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\nimport React, { ReactNode } from 'react';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n actionButtons: {\n width: '100%',\n textTransform: 'capitalize',\n marginTop: theme.spacing(2),\n display: 'block',\n borderRadius: theme.spacing(1),\n },\n cancelButton: {\n color: theme.palette.kyoLightGreen.main,\n borderColor: theme.palette.kyoLightGreen.main,\n },\n successButton: {\n '&, &:hover': {\n backgroundColor: theme.palette.kyoLightGreen.main,\n boxShadow: 'none',\n },\n '&:hover': {\n opacity: 0.9,\n },\n color: 'white',\n },\n}));\n\ntype CommonButtonProps = { [key in 'successButton' | 'cancelButton']?: T };\n\ninterface ActionsControlButtonProps {\n hideButtons?: CommonButtonProps;\n disabled?: CommonButtonProps;\n handleClick?: CommonButtonProps<() => void>;\n label?: CommonButtonProps;\n styles?: CommonButtonProps &\n Partial<{\n buttonRoot: string;\n buttonWrapper: string;\n }>;\n}\n\nconst ActionsControlButton = ({\n disabled,\n handleClick,\n label,\n styles,\n hideButtons,\n}: ActionsControlButtonProps) => {\n const classes = useStyles();\n\n return (\n
\n {!hideButtons?.successButton && (\n \n {label?.successButton}\n \n )}\n {!hideButtons?.cancelButton && (\n \n {label?.cancelButton}\n \n )}\n
\n );\n};\n\nexport default ActionsControlButton;\n","import themeWithOverrides from '../theme/theme';\nimport {\n Request,\n RequestSession,\n RequestStatus,\n RequestType,\n ScheduledSession,\n SessionStatus,\n StatusesInfo,\n StatusInfo,\n} from '../types/types';\n\nconst PENDING_COLOR = themeWithOverrides.palette.kyoBurntOrange.main;\nconst RETRACTED_COLOR = themeWithOverrides.palette.kyoGray63.main;\nconst CONFIRMED_COLOR = themeWithOverrides.palette.kyoPastelGreen.main;\nconst DECLINED_COLOR = themeWithOverrides.palette.kyoRed.main;\n\nconst declinedStatusInfo = {\n title: 'Declined',\n color: DECLINED_COLOR,\n};\n\nexport const pendingStatusInfo = {\n title: 'Pending Provider Response',\n color: PENDING_COLOR,\n};\n\nexport const acceptedStatusInfo = {\n title: 'Pending Scheduling Review',\n color: PENDING_COLOR,\n};\n\nconst retractedStatusInfo = {\n title: 'Retracted',\n color: RETRACTED_COLOR,\n};\n\nexport const confirmedStatusInfo = {\n title: 'Confirmed',\n color: CONFIRMED_COLOR,\n};\n\nexport const holdStatusInfo = {\n title: 'Pending',\n color: PENDING_COLOR,\n};\n\nexport const pendingOsStatusInfo = {\n title: 'Pending - OpenSession',\n color: PENDING_COLOR,\n};\n\nexport const pendingSearchingForSubStatusInfo = {\n title: 'Pending - Searching for Sub',\n color: PENDING_COLOR,\n};\n\nconst LongAndShortTermStatusesInfo: StatusesInfo = {\n [RequestStatus.PENDING]: pendingStatusInfo,\n [RequestStatus.DECLINED]: declinedStatusInfo,\n [RequestStatus.EXPIRED]: declinedStatusInfo,\n [RequestStatus.RETRACTED]: retractedStatusInfo,\n [RequestStatus.CONFIRMED]: confirmedStatusInfo,\n [RequestStatus.ACCEPTED]: acceptedStatusInfo,\n [RequestStatus.DENIED]: {\n title: 'Scheduling Declined',\n color: RETRACTED_COLOR,\n },\n};\n\nconst getSessionsCount = (sessions: RequestSession[]) => {\n return sessions.filter((s) => s.statusId !== RequestStatus.REMOVED).length;\n};\n\nexport const hasAnyAcceptedOrConfirmedSession = (\n relatedSessions: Pick[] | null\n): boolean => {\n if (!relatedSessions) {\n return false;\n }\n\n return relatedSessions.some((rs) =>\n [RequestStatus.ACCEPTED, RequestStatus.CONFIRMED].includes(rs.statusId)\n );\n};\n\nconst statusColorMap: {\n statuses: RequestStatus[];\n color: string;\n}[] = [\n {\n statuses: [RequestStatus.PENDING, RequestStatus.ACCEPTED],\n color: PENDING_COLOR,\n },\n {\n statuses: [RequestStatus.CONFIRMED],\n color: CONFIRMED_COLOR,\n },\n {\n statuses: [\n RequestStatus.EXPIRED,\n RequestStatus.CLOSED,\n RequestStatus.REMOVED,\n RequestStatus.RETRACTED,\n RequestStatus.DENIED,\n ],\n color: RETRACTED_COLOR,\n },\n {\n statuses: [RequestStatus.DECLINED],\n color: DECLINED_COLOR,\n },\n];\n\nexport const getSessionColor = (session: RequestSession): string => {\n if (\n hasAnyAcceptedOrConfirmedSession(session.relatedSessions) &&\n session.statusId === RequestStatus.CLOSED\n ) {\n return CONFIRMED_COLOR;\n }\n\n if (\n hasAnyAcceptedOrConfirmedSession(session.relatedSessions) &&\n session.statusId === RequestStatus.PENDING\n ) {\n return '#6fa8dc';\n }\n\n const statusMapping = statusColorMap.find((mapping) =>\n mapping.statuses.includes(session.statusId)\n );\n\n return statusMapping?.color || '';\n};\n\nexport const getSessionStatusTitle = (session: RequestSession): string => {\n const { statusId, relatedSessions } = session;\n\n if (statusId === RequestStatus.CLOSED && relatedSessions) {\n return hasAnyAcceptedOrConfirmedSession(relatedSessions)\n ? 'Confirmed'\n : 'Removed';\n }\n\n if (statusId === RequestStatus.PENDING) {\n const validSessions = relatedSessions?.filter((rs) => {\n return ![\n RequestStatus.DENIED,\n RequestStatus.CLOSED,\n RequestStatus.RETRACTED,\n RequestStatus.EXPIRED,\n ].includes(rs.statusId);\n });\n\n if (validSessions?.some((rs) => rs.statusId === RequestStatus.CONFIRMED)) {\n return 'Confirmed';\n }\n\n if (validSessions?.some((rs) => rs.statusId === RequestStatus.PENDING)) {\n return 'Pending';\n }\n }\n\n return RequestStatus[statusId] || '';\n};\n\nconst closedStatusInfo = ({ sessions, claimedSessionsCount }: Request) => {\n const sessionsCount = getSessionsCount(sessions);\n const title = `Closed - ${claimedSessionsCount} of ${sessionsCount} Claimed`;\n\n return {\n title,\n color: claimedSessionsCount === 0 ? RETRACTED_COLOR : CONFIRMED_COLOR,\n };\n};\n\nconst OpenSessionStatusesInfo: StatusesInfo = {\n [RequestStatus.PENDING]: ({ sessions, confirmedSessionsCount }) => {\n const sessionsCount = getSessionsCount(sessions);\n return {\n title: `Posted - ${confirmedSessionsCount} of ${sessionsCount} Confirmed`,\n color: '#6fa8dc',\n };\n },\n [RequestStatus.RETRACTED]: retractedStatusInfo,\n [RequestStatus.CLOSED]: closedStatusInfo,\n [RequestStatus.EXPIRED]: closedStatusInfo, // acts same as closed\n};\n\nconst SubOfferStatusesInfo: StatusesInfo = {\n [RequestStatus.PENDING]: confirmedStatusInfo,\n [RequestStatus.DECLINED]: {\n title: `Opted Out`,\n color: RETRACTED_COLOR,\n },\n [RequestStatus.ACCEPTED]: confirmedStatusInfo,\n [RequestStatus.CONFIRMED]: confirmedStatusInfo,\n [RequestStatus.RETRACTED]: retractedStatusInfo,\n};\n\nexport const getStatusInfo = (request: Request): StatusInfo | undefined => {\n const { type, statusId } = request;\n\n const statusesInfo = (() => {\n switch (type) {\n case RequestType.OpenSession:\n return OpenSessionStatusesInfo;\n case RequestType.SubOffer:\n return SubOfferStatusesInfo;\n default:\n return LongAndShortTermStatusesInfo;\n }\n })();\n\n const statusInfoCreator = statusesInfo[statusId];\n\n if (typeof statusInfoCreator === 'function') {\n return statusInfoCreator(request);\n }\n return statusInfoCreator;\n};\n\nexport const getSessionStatus = (session: ScheduledSession) => {\n if (session.bookRequestType === RequestType.SubOffer) {\n return SessionStatus.Confirmed;\n }\n const hasConfirmed = session.overlappingSessions?.some(\n (os) => os.status === SessionStatus.Confirmed\n );\n if (hasConfirmed) {\n return SessionStatus.Confirmed;\n }\n\n if (\n session.bookRequestType === RequestType.OpenSession &&\n session.status !== SessionStatus.Cancelled\n ) {\n return SessionStatus.Pending;\n }\n\n return session.status || SessionStatus.Confirmed;\n};\n\nexport default getStatusInfo;\n","import { useEffect } from 'react';\nimport { useLocation } from 'react-router';\nimport configs from '../configs';\n\nconst { gtagId } = configs;\n\ndeclare function gtag(\n key: string,\n id: string,\n params?: Record\n): void;\n\nconst useGtag = () => {\n const { pathname } = useLocation();\n\n useEffect(() => {\n if (!gtagId) {\n return;\n }\n const gtagScript = document.createElement('script');\n gtagScript.src = `https://www.googletagmanager.com/gtag/js?id=${gtagId}`;\n gtagScript.setAttribute('async', '');\n\n const dataLayerScript = document.createElement('script');\n dataLayerScript.innerHTML = `\n window.dataLayer = window.dataLayer || [];\n function gtag() {dataLayer.push(arguments);}\n gtag('js', new Date());\n \n gtag('config', '${gtagId}');\n `;\n\n const { firstChild } = document.head;\n\n document.head.insertBefore(gtagScript, firstChild);\n document.head.insertBefore(dataLayerScript, firstChild);\n }, []);\n\n useEffect(() => {\n if (gtagId && gtag) {\n // eslint-disable-next-line @typescript-eslint/camelcase\n gtag('config', gtagId, { page_path: pathname });\n }\n }, [pathname]);\n};\n\nexport default useGtag;\n","import React, { useState } from 'react';\nimport {\n Dialog,\n DialogContent,\n DialogTitle,\n List,\n ListItem,\n Theme,\n Typography,\n makeStyles,\n} from '@material-ui/core';\nimport CloseIcon from '@material-ui/icons/Close';\nimport { ReactComponent as InfoCircle } from '../../assets/info-circle-blue-filled.svg';\nimport StyledButton from '../buttons/StyledButton';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n learnAboutAvailability: {\n fontSize: 14,\n padding: 0,\n },\n dialogTitle: {\n backgroundColor: theme.palette.kyoGray2.main,\n '& h2': {\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n fontSize: theme.spacing(2),\n },\n },\n dialogCloseIcon: {\n fontSize: theme.spacing(3),\n cursor: 'pointer',\n },\n dialogContent: {\n paddingInline: theme.spacing(6),\n [theme.breakpoints.down('sm')]: {\n paddingInline: theme.spacing(2),\n },\n },\n infoIconContainer: {\n display: 'flex',\n justifyContent: 'center',\n marginTop: theme.spacing(6),\n marginBottom: theme.spacing(4),\n },\n availInfo: {\n color: theme.palette.kyoGray63.dark,\n fontSize: 14,\n },\n closeButtonContainer: {\n display: 'flex',\n justifyContent: 'center',\n marginTop: theme.spacing(4),\n marginBottom: theme.spacing(6),\n },\n closeButton: {\n width: '80%',\n },\n}));\n\nconst BTAvailabilityInfoDialog = () => {\n const classes = useStyles();\n const [availInfoDialogOpen, setAvailInfoDialogOpen] = useState(false);\n\n const handleClose = () => setAvailInfoDialogOpen(false);\n\n return (\n <>\n setAvailInfoDialogOpen(true)}\n >\n Learn more about BT availability\n \n \n \n BT Availability\n \n \n \n
\n \n
\n \n Several factors may affect the number of providers available in your\n area or the times they are available to be scheduled. The options\n you are provided are filtered to adhere to the following:\n \n \n Provider Availability\n Insurer Requirements\n State Meal and Rest Break Regulations\n \n Client Specific Requirements (ie, language requirements, pets in\n home, specific trainings)\n \n Client and Provider Location\n \n \n Please review your profile and availability to ensure it is up to\n date.\n \n
\n \n Close\n \n
\n
\n
\n \n );\n};\n\nexport default BTAvailabilityInfoDialog;\n","import React from 'react';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\nimport BTAvailabilityInfoDialog from './BTAvailabilityInfoDialog';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n hintTextContainer: {\n marginTop: theme.spacing(2),\n },\n}));\n\ninterface ClientCanAddSessionProps {\n description: string;\n assignmentApprovalRequired?: boolean;\n includeEnoughOptionsHint?: boolean;\n}\n\nconst ClientCanAddSession = ({\n description,\n assignmentApprovalRequired,\n includeEnoughOptionsHint = true,\n}: ClientCanAddSessionProps) => {\n const classes = useStyles();\n\n return (\n <>\n \n We can help you book additional sessions or rebook your cancelled\n sessions.\n \n {assignmentApprovalRequired && (\n \n You may book only with providers in your current Care Team. For\n more information please contact your BCBA.\n \n )}\n \n {description}\n \n {includeEnoughOptionsHint && (\n <>\n \n Not seeing enough options? Turn on{' '}\n Show Times Outside My Availability to find therapists and\n times outside of your regular availability.\n \n \n \n )}\n \n );\n};\n\nexport default ClientCanAddSession;\n","import React from 'react';\nimport { Typography, Link } from '@material-ui/core';\nimport { SCH_EMAIL } from '../../utils/constants';\n\nconst ClientCanNotAddSession = () => {\n return (\n <>\n \n Good news - you are fully booked! The Add Sessions feature is only\n available to clients who are receiving services significantly less than\n their authorized amount, or to clients who have recently cancelled a\n session. Please come back to this page if you ever need to rebook a\n cancelled session or add sessions to reach your authorization.\n \n \n If you have any questions or if you'd like to open up more\n availability, please contact{' '}\n {SCH_EMAIL}.\n \n \n );\n};\n\nexport default ClientCanNotAddSession;\n","import React from 'react';\nimport { Typography, Link } from '@material-ui/core';\nimport { SCH_EMAIL } from '../../utils/constants';\n\nconst ClientHasNotAvailableBlocks = () => {\n return (\n \n We'd like to help you add sessions but it looks like you have no\n available time blocks that are not already occupied. Please contact{' '}\n {SCH_EMAIL} to increase your\n availability.\n \n );\n};\n\nexport default ClientHasNotAvailableBlocks;\n","import React from 'react';\nimport { Typography, makeStyles, Theme, Link } from '@material-ui/core';\nimport { SCH_PHONE_NUMBER } from '../../utils/constants';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n noSessionsText: {\n marginTop: theme.spacing(2.75),\n marginBottom: theme.spacing(2),\n },\n}));\n\nconst IsPausedHint = () => {\n const classes = useStyles();\n return (\n <>\n \n You have been temporarily paused from using this feature.\n \n Please contact scheduling for further assistance.\n
\n \n Call: {SCH_PHONE_NUMBER}.\n \n \n );\n};\n\nexport default IsPausedHint;\n","import React from 'react';\nimport { Typography, makeStyles, Theme } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n noSessionsText: {\n marginTop: theme.spacing(2.75),\n marginBottom: theme.spacing(2),\n },\n}));\n\nconst BadAuthorizationHint = () => {\n const classes = useStyles();\n return (\n <>\n \n Because of the way your insurer authorizes your services, you are unable\n to book your own sessions in Care. Please contact Scheduling directly.\n \n \n );\n};\n\nexport default BadAuthorizationHint;\n","import React from 'react';\nimport { Typography, makeStyles, Theme } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n noSessionsText: {\n marginTop: theme.spacing(2.75),\n marginBottom: theme.spacing(2),\n },\n}));\n\nconst ClientActiveDTAuth = () => {\n const classes = useStyles();\n return (\n <>\n \n It looks like we are working on retrieving your new authorization.\n \n Please check back later to use Add Sessions.\n \n );\n};\n\nexport default ClientActiveDTAuth;\n","import React from 'react';\n\nimport ClientCanAddSessionHint from './ClientCanAddSessionHint';\nimport ClientCanNotAddSessionHint from './ClientCanNotAddSessionHint';\nimport ClientHasNotAvailableBlocksHint from './ClientHasNotAvailableTimeBlocksHint';\nimport IsPausedHint from './IsPausedHint';\nimport BadAuthorizationHint from './BadAuthorizationHint';\nimport ClientActiveDTAuth from './ClientActiveDTAuthHint';\nimport {\n ClientSTBRAvailability,\n SINGLE_SESSION_FORBID_REASON,\n} from '../../types/types';\n\ninterface HintTextProps {\n clientCanRebook: boolean;\n notEnoughAvailableBlocks: boolean;\n clientSTBRAvailability: Pick<\n ClientSTBRAvailability,\n 'maxNumberOfSessionsCanBooked' | 'forbidReason'\n >;\n assignmentApprovalRequired?: boolean;\n includeEnoughOptionsHint?: boolean;\n}\n\nconst HintText = ({\n clientCanRebook,\n notEnoughAvailableBlocks,\n clientSTBRAvailability: { maxNumberOfSessionsCanBooked, forbidReason },\n assignmentApprovalRequired,\n includeEnoughOptionsHint = true,\n}: HintTextProps) => {\n if (clientCanRebook) {\n return (\n \n );\n }\n\n if (clientCanRebook && notEnoughAvailableBlocks) {\n return ;\n }\n\n if (forbidReason === SINGLE_SESSION_FORBID_REASON.clientPaused) {\n return ;\n }\n\n if (forbidReason === SINGLE_SESSION_FORBID_REASON.badAuthPeriod) {\n return ;\n }\n\n if (forbidReason === SINGLE_SESSION_FORBID_REASON.clientActiveDTAuth) {\n return ;\n }\n\n if (!clientCanRebook) {\n return ;\n }\n\n return <>;\n};\n\nexport default HintText;\n","import { useCallback } from 'react';\nimport { useSelector, useDispatch } from 'react-redux';\nimport { RootState } from '../redux/modules/rootReducer';\nimport { fetchSingleSessionProviders } from '../redux/modules/newSessions';\nimport { SingleSessionProviderFilters } from '../types/types';\n\nconst useAddSessions = () => {\n const dispatch = useDispatch();\n\n const singleSessionProviders = useSelector(\n (state: RootState) => state.newSessions.singleSessionProviders\n );\n\n const singleSessionProvidersLoading = useSelector(\n (state: RootState) => state.newSessions.singleSessionProvidersLoading\n );\n\n const getSingleSessionProviders = useCallback(\n (filters: SingleSessionProviderFilters) => {\n dispatch(fetchSingleSessionProviders(filters));\n },\n [dispatch]\n );\n\n return {\n singleSessionProviders,\n singleSessionProvidersLoading,\n getSingleSessionProviders,\n };\n};\n\nexport default useAddSessions;\n","import React from 'react';\nimport { IconButton, makeStyles } from '@material-ui/core';\nimport FilterListIcon from '@material-ui/icons/FilterList';\nimport clsx from 'clsx';\n\nconst getButtonHoverCss = (backgroundColor: string) => {\n return {\n '&:hover': {\n backgroundColor,\n opacity: 0.8,\n },\n };\n};\n\nconst useStyles = makeStyles((theme) => ({\n openButton: {\n borderRadius: theme.spacing(1),\n padding: theme.spacing(0.75),\n },\n closed: {\n backgroundColor: `${theme.palette.kyoGray.main}`,\n color: theme.palette.kyoGray.dark,\n ...getButtonHoverCss(`${theme.palette.kyoGray.main}`),\n },\n open: {\n backgroundColor: '#C5DCFA',\n color: theme.palette.kyoBlue.main,\n ...getButtonHoverCss('#C5DCFA'),\n },\n}));\n\ninterface FiltersListProps {\n children: (open: boolean) => React.ReactNode;\n useButton?: boolean;\n buttonClassName?: string;\n open: boolean;\n setOpen: (isOpen: boolean) => void;\n}\n\nconst FiltersList = ({\n children,\n useButton,\n buttonClassName,\n open,\n setOpen,\n}: FiltersListProps) => {\n const classes = useStyles();\n\n return (\n <>\n {useButton && (\n setOpen(!open)}\n aria-label=\"Filters List\"\n >\n \n \n )}\n {children(useButton ? open : true)}\n \n );\n};\n\nexport default FiltersList;\n","import React from 'react';\n\nimport DatePicker, {\n CalendarProps,\n DatePickerProps,\n} from 'react-multi-date-picker';\nimport './rmdp.css';\n\nconst StyledMultipleDatePicker = (props: CalendarProps & DatePickerProps) => {\n const { style } = props;\n return (\n \n );\n};\n\nexport default StyledMultipleDatePicker;\n","import moment from 'moment';\nimport {\n Box,\n Collapse,\n Theme,\n Typography,\n makeStyles,\n useMediaQuery,\n} from '@material-ui/core';\nimport React from 'react';\nimport { DateObject } from 'react-multi-date-picker';\nimport { useConfirm } from 'material-ui-confirm';\nimport { useSelector } from 'react-redux';\nimport clsx from 'clsx';\nimport FiltersList from '../../components/FiltersList';\nimport StyledMultipleDatePicker from '../../components/styledMultipleDatePicker/StyledMultipleDatePicker';\nimport { DATE_FORMAT_US } from '../../utils/helpers';\nimport StyledSwitch from '../../components/StyledSwitch/StyledSwitch';\nimport { RootState } from '../../redux/modules/rootReducer';\nimport { ClientAttributes } from '../../types/types';\nimport { SHORT_WEEK_DAYS } from '../../utils/constants';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n display: 'grid',\n gridTemplateColumns: '1fr max-content',\n alignItems: 'center',\n marginTop: theme.spacing(2),\n padding: theme.spacing(1.75),\n backgroundColor: theme.palette.kyoGray.light,\n borderRadius: theme.spacing(1.5),\n },\n rootMobile: {\n backgroundColor: 'transparent',\n padding: 0,\n alignItems: 'end',\n },\n preferredDateCaptionMobile: {\n display: 'flex',\n gap: theme.spacing(0.5),\n alignItems: 'flex-end',\n },\n collapseMobile: {\n gridColumn: '1 / 3',\n },\n filtersWrapper: {\n display: 'flex',\n gap: theme.spacing(2),\n },\n filtersWrapperMobile: {\n flexDirection: 'column',\n marginTop: theme.spacing(0.75),\n gap: theme.spacing(0.75),\n },\n row: {\n display: 'flex',\n gap: theme.spacing(0.75),\n alignItems: 'center',\n },\n preferredRowMobile: {\n flexDirection: 'column',\n alignItems: 'flex-start',\n },\n filterRow: {\n justifyContent: 'space-between',\n },\n mobileSwitch: {\n transform: 'translateX(9px)',\n },\n}));\n\ntype PreferredDatesValue = DateObject[];\n\ninterface AddSessionFiltersProps {\n preferredDates: PreferredDatesValue;\n setPreferredDates: (value: PreferredDatesValue) => void;\n showOptionsOutsideOfMyAvailability: boolean;\n setShowOptionsOutsideOfMyAvailability: (value: boolean) => void;\n isShowMyTeam: boolean;\n setShowMyTeam: (value: boolean) => void;\n filtersListOpen: boolean;\n setFiltersListOpen: (value: boolean) => void;\n clientAttributes?: Pick;\n}\n\nconst AddSessionFilters = ({\n clientAttributes,\n preferredDates,\n setPreferredDates,\n showOptionsOutsideOfMyAvailability,\n setShowOptionsOutsideOfMyAvailability,\n isShowMyTeam,\n setShowMyTeam,\n filtersListOpen,\n setFiltersListOpen,\n}: AddSessionFiltersProps) => {\n const classes = useStyles();\n\n const isTabletScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('sm')\n );\n\n const isMobileScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('xs')\n );\n\n const confirm = useConfirm();\n\n const calendarDefaultCurrentDate = new DateObject().add(2, 'days');\n\n const calendarMinDate = moment().startOf('day').add(2, 'day').toDate();\n const maxDate = useSelector((state: RootState) => state.newSessions.maxDate);\n\n const handleShowMyTeamCheck = (isChecked: boolean) => {\n if (clientAttributes?.assignmentApprovalRequired) {\n confirm({\n title: 'Sorry!',\n description:\n 'You may book only with providers in your current Care Team. For more' +\n ' information please contact your BCBA.',\n });\n } else {\n setShowMyTeam(isChecked);\n }\n };\n\n return (\n
\n \n \n Preferred dates\n (optional, up to 2)\n \n {\n if (Array.isArray(array) && array.length <= 2) {\n setPreferredDates([...array]);\n } else {\n setPreferredDates([...preferredDates]);\n }\n }}\n portal\n currentDate={calendarDefaultCurrentDate}\n minDate={calendarMinDate}\n maxDate={maxDate}\n style={{\n backgroundColor: 'white',\n border: '1px solid #C0C0C0',\n }}\n />\n
\n \n {(open) => (\n \n \n
\n Show My Team only\n {\n handleShowMyTeamCheck(value);\n }}\n />\n
\n
\n \n Show Times Outside My Availability\n \n {\n setShowOptionsOutsideOfMyAvailability(value);\n }}\n />\n
\n \n \n )}\n \n \n );\n};\n\nexport default AddSessionFilters;\n","import { Divider, makeStyles, Theme, Typography } from '@material-ui/core';\nimport React, { useState } from 'react';\nimport ArrowRightAltIcon from '@material-ui/icons/ArrowRightAlt';\nimport { useSelector } from 'react-redux';\nimport moment from 'moment';\nimport { Link } from 'react-router-dom';\nimport { ReactComponent as FilesIcon } from '../../assets/files.svg';\nimport StyledButton from '../../components/buttons/StyledButton';\nimport StyledButtonLink from '../../components/buttons/StyledButtonLink';\nimport { RootState } from '../../redux/modules/rootReducer';\nimport SessionCard from '../../components/SessionCard/SessionCard';\nimport ClientSessionDetails from '../../components/SessionCard/ClientSessionDetails';\nimport { SelectedBookingOption } from '../../redux/modules/newSessions';\nimport { getUtcDateFromSTBRSession } from '../../utils/helpers';\nimport {\n ProviderWithBookDetails,\n ScheduledSession,\n SessionStatus,\n UserType,\n} from '../../types/types';\nimport AnalyticsTracker, {\n TrackerNames,\n} from '../../analytics/AnalyticsTracker';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n container: { marginTop: theme.spacing(3) },\n topContainer: { display: 'flex' },\n sessionItems: { marginLeft: theme.spacing(1) },\n divider: {\n maxWidth: 318,\n },\n buttonContainer: {\n marginTop: 10,\n width: '100%',\n display: 'flex',\n justifyContent: 'flex-end',\n },\n subTitle: { fontWeight: 700, marginTop: theme.spacing(2) },\n sessionsContainer: { display: 'flex', flexWrap: 'wrap' },\n sessionCardContainer: { marginRight: 20 },\n sessionCardDivider: { height: 1, width: 327, marginLeft: 22 },\n link: { textDecoration: 'none' },\n}));\n\nconst SessionsSubmitted = () => {\n const classes = useStyles();\n const [isShowDetails, setShowDetails] = useState(false);\n\n const selectedBookingOptions = useSelector(\n (state: RootState) => state.newSessions.selectedBookingOptions\n );\n\n const selectedProvider = useSelector(\n (state: RootState) => state.newSessions.selectedProvider\n );\n\n return (\n <>\n
\n \n
\n \n
\n {`${selectedBookingOptions.length} sessions submitted`}\n setShowDetails(!isShowDetails)}>\n {isShowDetails ? 'Hide Details' : 'View Details'}\n \n
\n
\n\n {!isShowDetails && }\n
\n\n {isShowDetails && (\n
\n {selectedBookingOptions.map((rebookOption, index) => {\n return (\n \n );\n })}\n
\n )}\n\n \n Thank you for your request!\n \n \n We are checking with your provider to confirm which times work for them.\n We will be in touch as soon as we can confirm the sessions.\n \n
\n \n }\n >\n Go to schedule\n \n \n
\n \n );\n};\n\nexport default SessionsSubmitted;\n\ninterface PendingSessionProps {\n session: SelectedBookingOption;\n selectedProvider: ProviderWithBookDetails | null;\n}\n\nconst PendingSession = (props: PendingSessionProps) => {\n const classes = useStyles();\n const { session, selectedProvider } = props;\n\n const pendingSession: Partial = {\n segmentStartUtc: getUtcDateFromSTBRSession(session),\n segmentEndUtc: `${moment(getUtcDateFromSTBRSession(session)).add(\n session?.sessionPlacement.duration,\n 'hours'\n )}`,\n status: SessionStatus.Pending,\n provider: selectedProvider || undefined,\n };\n\n return (\n
\n \n {() => (\n \n )}\n \n \n
\n );\n};\n","import React, { useState } from 'react';\nimport {\n Radio,\n Theme,\n ThemeProvider,\n Typography,\n createMuiTheme,\n makeStyles,\n} from '@material-ui/core';\nimport TimelapseIcon from '@material-ui/icons/Timelapse';\nimport moment from 'moment';\nimport MUIDataTable, {\n MUIDataTableColumn,\n MUIDataTableOptions,\n} from 'mui-datatables';\nimport clsx from 'clsx';\n\nimport { STBRBlockOption } from '../../../types/types';\nimport {\n TIME_FORMAT_24HR,\n TIME_FORMAT_2,\n humanizeDuration,\n DATE_FORMAT_WEEKDAY_MONTH_YEAR,\n DATE_FORMAT,\n} from '../../../utils/helpers';\nimport { SessionPlacement } from '../../../redux/modules/adminSettings';\nimport ActionsControlButton from '../../../components/buttons/ActionsControlButton';\nimport SimpleDialog from '../../../components/Dialogs/SimpleDialog';\nimport CalendarSrc from '../../../assets/defaultOpenSessionCalendarIcon.svg';\n\nconst selectTimeTheme = (theme: Theme) =>\n createMuiTheme({\n overrides: {\n MUIDataTableHeadCell: {\n root: {\n color: theme.palette.kyoGray63.main,\n },\n },\n MuiPaper: {\n root: {\n '& table tbody': {\n borderBottom: 'none',\n },\n },\n },\n MuiTableBody: {\n root: {\n '& tr td:first-child': {\n paddingLeft: 0,\n },\n },\n },\n MuiTableCell: {\n root: {\n padding: theme.spacing(0.5, 2),\n },\n },\n },\n });\n\nconst useStyles = makeStyles((theme: Theme) => ({\n radioButton: {\n color: '#D9D9D9',\n\n '&.Mui-checked': {\n color: theme.palette.kyoBlue2.main,\n },\n },\n dialog: {\n '& .MuiPaper-root': {\n width: theme.spacing(50),\n },\n },\n dialogContent: {\n padding: theme.spacing(2, 6),\n overflowX: 'auto',\n },\n duration: {\n display: 'flex',\n gap: theme.spacing(0.25),\n color: theme.palette.kyoGray63.main,\n },\n durationIcon: {\n fontSize: theme.spacing(2),\n transform: 'translateY(2px)',\n },\n contentHeader: {\n display: 'flex',\n gap: theme.spacing(1.5),\n marginBottom: theme.spacing(2.5),\n\n '& img': {\n width: theme.spacing(2),\n },\n },\n scheduleDate: {\n color: 'black',\n },\n time: {\n fontWeight: 700,\n color: theme.palette.kyoGray.dark,\n },\n disabled: {\n opacity: 0.4,\n },\n}));\n\ninterface SelectTimeDialogProps {\n bookOption: STBRBlockOption;\n onClose: () => void;\n handleSave: (sessionPlacement: SessionPlacement) => void;\n disabledSessionPlacementIds: number[];\n}\n\nconst SelectTimesDialog = ({\n bookOption,\n onClose,\n handleSave,\n disabledSessionPlacementIds,\n}: SelectTimeDialogProps) => {\n const classes = useStyles();\n\n const [\n selectedSessionPlacement,\n setSelectedSessionPlacement,\n ] = useState(null);\n\n const options: MUIDataTableOptions = {\n viewColumns: false,\n selectableRows: 'none',\n search: false,\n print: false,\n filter: false,\n sort: false,\n pagination: false,\n download: false,\n elevation: 0,\n responsive: 'standard',\n rowHover: false,\n };\n\n const columns: MUIDataTableColumn[] = [\n {\n name: '',\n label: '',\n options: {\n customBodyRenderLite: (dataIndex) => {\n const sessionPlacement = bookOption.sessionPlacements[dataIndex];\n const isDisabled = disabledSessionPlacementIds.includes(\n sessionPlacement.id\n );\n\n return (\n {\n setSelectedSessionPlacement(sessionPlacement);\n }}\n />\n );\n },\n },\n },\n {\n name: '',\n label: 'Time',\n options: {\n customBodyRenderLite: (dataIndex) => {\n const sessionPlacement = bookOption.sessionPlacements[dataIndex];\n const isDisabled = disabledSessionPlacementIds.includes(\n sessionPlacement.id\n );\n\n return (\n
\n {moment(sessionPlacement.startTime, TIME_FORMAT_24HR).format(\n TIME_FORMAT_2\n )}\n
\n );\n },\n },\n },\n {\n name: 'Duration',\n label: '',\n options: {\n customBodyRenderLite: (dataIndex) => {\n const sessionPlacement = bookOption.sessionPlacements[dataIndex];\n\n const humanizedDuration = humanizeDuration(sessionPlacement.duration);\n\n const isDisabled = disabledSessionPlacementIds.includes(\n sessionPlacement.id\n );\n\n return (\n \n \n {humanizedDuration}\n \n );\n },\n },\n },\n ];\n\n return (\n \n
\n \"calendar\n \n {/**\n * moment parses scheduledDate (2023-05-07T00:00:00.000Z) to client timezone and day is changed\n * now we specify scheduleDate format to avoid timeZone change.\n * TODO: wen eed to return dates in utc or in 'YYYY-MM-DD' format to avoid misunderstanding types like this\n */}\n {moment(bookOption.scheduledDate, DATE_FORMAT).format(\n DATE_FORMAT_WEEKDAY_MONTH_YEAR\n )}\n \n
\n \n \n \n {\n if (selectedSessionPlacement) {\n handleSave(selectedSessionPlacement);\n }\n\n onClose();\n },\n cancelButton: () => {\n onClose();\n },\n }}\n label={{\n successButton: 'Add This Time',\n cancelButton: 'Cancel',\n }}\n />\n \n );\n};\n\nexport default SelectTimesDialog;\n","import React, { useState } from 'react';\nimport { makeStyles } from '@material-ui/core';\nimport AddCircleOutlineIcon from '@material-ui/icons/AddCircleOutline';\nimport clsx from 'clsx';\nimport { cloneDeep } from 'lodash';\nimport moment from 'moment';\n\nimport MatrixCell, { MatrixCellProps } from '../../../shared/matrix/ui/cell';\nimport SelectTimesDialog from '../dialogs/SelectTimesDialog';\nimport { STBRBlockOption } from '../../../types/types';\nimport { SessionPlacement } from '../../../redux/modules/adminSettings';\nimport { useAppDispatch } from '../../../redux/store';\nimport {\n SelectedBookingOption,\n addSelectedBookingOption,\n} from '../../../redux/modules/newSessions';\nimport { TIME_FORMAT_24HR } from '../../../utils/helpers';\n\nexport const AVAILABLE_ICON_COLOR = '#3D90FB';\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n backgroundColor: '#E5EFFD',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n cursor: 'pointer',\n },\n icon: {\n color: AVAILABLE_ICON_COLOR,\n },\n disabled: {\n opacity: 0.5,\n cursor: 'initial',\n },\n}));\n\nconst AvailableCell = ({\n className,\n bookOption,\n selectedOptionAfter,\n selectedOptionBefore,\n disable = false,\n}: Omit & {\n bookOption: STBRBlockOption;\n selectedOptionAfter?: SelectedBookingOption;\n selectedOptionBefore?: SelectedBookingOption;\n disable?: boolean;\n}) => {\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const [selected, setSelected] = useState(false);\n\n const handleSave = (sessionPlacement: SessionPlacement) => {\n const selectedBookOption: SelectedBookingOption = cloneDeep({\n ...bookOption,\n sessionPlacement,\n sessionPlacements: undefined,\n });\n\n dispatch(addSelectedBookingOption(selectedBookOption));\n };\n\n const getPlacementEndDate = (\n startTime: string | null,\n duration: number | null\n ) => {\n return moment(startTime, TIME_FORMAT_24HR)\n .add((duration || 0) * 60, 'minutes')\n .format(TIME_FORMAT_24HR);\n };\n\n const sessionPlacementGreaterThan =\n selectedOptionBefore &&\n getPlacementEndDate(\n selectedOptionBefore.sessionPlacement.startTime,\n selectedOptionBefore.sessionPlacement.duration\n );\n\n const sessionPlacementSmallerThan =\n selectedOptionAfter && selectedOptionAfter.sessionPlacement.startTime;\n\n const disabledSessionPlacementIds = bookOption.sessionPlacements\n .filter((sessionPlacement) => {\n const { startTime, duration } = sessionPlacement;\n const endTime = getPlacementEndDate(startTime, duration);\n\n if (\n sessionPlacementGreaterThan &&\n startTime &&\n startTime < sessionPlacementGreaterThan\n ) {\n return true;\n }\n\n if (\n sessionPlacementSmallerThan &&\n endTime > sessionPlacementSmallerThan\n ) {\n return true;\n }\n\n return false;\n })\n .map((sessionPlacement) => sessionPlacement.id);\n\n return (\n <>\n !disable && setSelected(true)}\n >\n \n \n {selected && (\n setSelected(false)}\n handleSave={handleSave}\n disabledSessionPlacementIds={disabledSessionPlacementIds}\n />\n )}\n \n );\n};\n\nexport default AvailableCell;\n","import React from 'react';\nimport { makeStyles } from '@material-ui/core';\n\nimport { humanizeDuration } from '../../../utils/helpers';\n\ninterface CellInfoProps {\n startTime: string;\n duration: number;\n}\n\nconst useStyles = makeStyles((theme) => ({\n time: {\n fontWeight: 700,\n },\n duration: {\n fontWeight: 600,\n fontSize: '12px',\n },\n}));\n\nconst CellInfo = ({ startTime, duration }: CellInfoProps) => {\n const classes = useStyles();\n\n return (\n <>\n
{startTime}
\n
{humanizeDuration(duration)}
\n \n );\n};\n\nexport default CellInfo;\n","import React from 'react';\nimport { Theme, makeStyles, useMediaQuery } from '@material-ui/core';\nimport AccessTimeIcon from '@material-ui/icons/AccessTime';\nimport clsx from 'clsx';\nimport moment from 'moment';\n\nimport MatrixCell, { MatrixCellProps } from '../../../shared/matrix/ui/cell';\nimport { SelectedBookingOption } from '../../../redux/modules/newSessions';\nimport CellInfo from './CellInfo';\nimport { TIME_FORMAT_2, TIME_FORMAT_24HR } from '../../../utils/helpers';\n\nconst useSelectedCellStyles = makeStyles((theme) => ({\n root: {\n backgroundColor: theme.palette.kyoBlue2.main,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-end',\n justifyContent: 'center',\n paddingRight: theme.spacing(2),\n zIndex: 1,\n overflow: 'hidden',\n color: 'white',\n },\n rootMobile: {\n alignItems: 'center',\n paddingRight: 0,\n },\n smallImage: {\n width: '100%',\n },\n\n stripedBackground: {\n position: 'absolute',\n width: '100%',\n height: '100%',\n zIndex: -1,\n },\n stripe: {\n transform: 'rotate(-45deg) translateY(-110px)',\n width: '250%',\n backgroundColor: 'rgba(255, 255, 255, 0.3)',\n height: '1px',\n margin: theme.spacing(0.75),\n },\n stripeMobile: {\n transform: 'rotate(-45deg) translateY(-80px)',\n },\n icon: {\n backgroundColor: theme.palette.kyoBlue2.main,\n color: 'white',\n position: 'relative',\n borderRadius: '50%',\n },\n}));\n\nconst SelectedCell = ({\n className,\n selectedBookingOption,\n}: Omit & {\n selectedBookingOption: SelectedBookingOption;\n}) => {\n const classes = useSelectedCellStyles();\n\n const isSmallScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('sm')\n );\n\n const { startTime, duration } = selectedBookingOption.sessionPlacement;\n\n return (\n \n \n {!isSmallScreen && (\n \n )}\n
\n {Array.from({ length: 30 }, (x, i) => i).map((id) => (\n \n ))}\n
\n \n );\n};\n\nexport default SelectedCell;\n","import React from 'react';\nimport { Typography, makeStyles } from '@material-ui/core';\nimport TimelapseIcon from '@material-ui/icons/Timelapse';\nimport moment from 'moment';\nimport clsx from 'clsx';\n\nimport {\n MainRequestTypes,\n RequestType,\n SessionStatus,\n} from '../../types/types';\nimport {\n DATE_FORMAT,\n DATE_FORMAT_WEEKDAY_MONTH_YEAR,\n TIME_FORMAT,\n humanizeDuration,\n} from '../../utils/helpers';\nimport LongTermTypeSrc from '../../assets/bookingDetails/longTermType.svg';\nimport OpenSessionTypeSrc from '../../assets/defaultOpenSessionCalendarIcon.svg';\nimport ShortTermTypeSrc from '../../assets/bookingDetails/shortTermType.svg';\nimport TimeSrc from '../../assets/bookingDetails/time.svg';\nimport DateSrc from '../../assets/bookingDetails/date.svg';\nimport BookedWithSrc from '../../assets/bookingDetails/bookedWith.svg';\nimport { BookedOption } from './NewSessions';\nimport themeWithOverrides from '../../theme/theme';\n\ninterface BookedOptionRow {\n icon: React.ReactNode;\n title: string;\n content: React.ReactNode;\n}\n\nconst useStyles = makeStyles((theme) => ({\n statusIcon: {\n borderRadius: '50%',\n width: theme.spacing(1.75),\n height: theme.spacing(1.75),\n },\n rowWrapper: {\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n gap: theme.spacing(1),\n minHeight: theme.spacing(7.5),\n padding: theme.spacing(0, 0.5),\n borderBottom: `1px solid ${theme.palette.kyoGray.main}`,\n },\n rowTitle: {\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(1.4),\n color: theme.palette.kyoGray63.main,\n ...theme.typography.body2,\n },\n content: {\n flex: 1,\n textAlign: 'right',\n color: theme.palette.kyoGray.dark,\n ...theme.typography.subtitle1,\n },\n timelapseIcon: {\n fontSize: '17.5px',\n transform: 'translateX(-2px)',\n },\n}));\n\nconst confirmedStatusDetails = {\n color: themeWithOverrides.palette.kyoPastelGreen.main,\n title: 'Confirmed',\n};\n\nconst statusDetails: Record> = {\n [SessionStatus.Pending]: {\n color: themeWithOverrides.palette.kyoBurntOrange.main,\n title: 'Pending',\n },\n [SessionStatus.Accepted]: confirmedStatusDetails,\n [SessionStatus.Confirmed]: confirmedStatusDetails,\n};\n\nconst BookedOptionDetails = ({\n bookedOption: {\n type,\n startTime,\n endTime,\n duration,\n status,\n scheduledDate,\n bookingWith,\n },\n classNames,\n}: {\n bookedOption: BookedOption;\n classNames?: Partial>;\n}) => {\n const classes = useStyles();\n\n const requestTypeInfo: Record = {\n [RequestType.LongTerm]: {\n icon: LongTermTypeSrc,\n title: 'Type',\n content: <>Long Term,\n },\n [RequestType.SingleTerm]: {\n icon: ShortTermTypeSrc,\n title: 'Type',\n content: <>Short Term,\n },\n [RequestType.OpenSession]: {\n icon: OpenSessionTypeSrc,\n title: 'Type',\n content: (\n <>\n OpenSession\n \n Contact scheduling to change\n \n \n ),\n },\n [RequestType.SubOffer]: {\n icon: ShortTermTypeSrc,\n title: 'Type',\n content: <>SubOffer,\n },\n };\n\n const rows: BookedOptionRow[] = [\n {\n icon: DateSrc,\n title: 'Date',\n content: (\n <>\n {moment(scheduledDate, DATE_FORMAT).format(\n DATE_FORMAT_WEEKDAY_MONTH_YEAR\n )}\n \n ),\n },\n {\n icon: BookedWithSrc,\n title: 'Booked with',\n content: bookingWith,\n },\n {\n icon: TimeSrc,\n title: 'Time',\n content: (\n <>\n {startTime.format(TIME_FORMAT)} - {endTime.format(TIME_FORMAT)}\n \n ),\n },\n {\n icon: ,\n title: 'Duration',\n content: <>{humanizeDuration(duration)},\n },\n {\n icon: (\n \n ),\n title: 'Status',\n content: (\n \n {statusDetails[status].title}\n \n ),\n },\n ];\n\n if (!bookingWith) {\n rows.splice(1, 1);\n }\n\n if (type) {\n rows.unshift(requestTypeInfo[type]);\n }\n\n return (\n
\n {rows.map(({ icon, title, content }) => (\n
\n
\n {typeof icon === 'string' ? \"row\" : icon}\n {title}\n
\n
{content}
\n
\n ))}\n
\n );\n};\n\nexport default BookedOptionDetails;\n","import React from 'react';\nimport { Theme, Typography, makeStyles } from '@material-ui/core';\n\nimport ActionsControlButton from '../../../components/buttons/ActionsControlButton';\nimport SimpleDialog from '../../../components/Dialogs/SimpleDialog';\nimport BookedSrc from '../../../assets/bookingDetails/booked.svg';\nimport { BookedOption } from '../NewSessions';\nimport BookedOptionDetails from '../BookedOptionDetails';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n dialog: {\n '& .MuiPaper-root': {\n width: theme.spacing(50),\n },\n },\n dialogContent: {\n padding: theme.spacing(2, 4),\n overflowX: 'auto',\n },\n header: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n color: '#F7716E',\n gap: theme.spacing(1),\n marginBottom: theme.spacing(2),\n },\n}));\n\ninterface SelectTimeDialogProps {\n bookedOptions: BookedOption[];\n onClose: () => void;\n}\n\nconst BookDetailsDialog = ({\n bookedOptions,\n onClose,\n}: SelectTimeDialogProps) => {\n const classes = useStyles();\n\n return (\n \n
\n \"calendar\n Booked\n
\n\n
\n {bookedOptions.map((bookedOption) => {\n return (\n \n );\n })}\n
\n\n {\n onClose();\n },\n }}\n label={{\n cancelButton: 'Cancel',\n }}\n hideButtons={{ successButton: true }}\n />\n \n );\n};\n\nexport default BookDetailsDialog;\n","import React, { useEffect, useState } from 'react';\nimport {\n Fade,\n Paper,\n Popper,\n Theme,\n makeStyles,\n useMediaQuery,\n} from '@material-ui/core';\nimport EventAvailableIcon from '@material-ui/icons/EventAvailable';\nimport clsx from 'clsx';\nimport { sortBy } from 'lodash';\n\nimport MatrixCell, { MatrixCellProps } from '../../../shared/matrix/ui/cell';\nimport BookDetailsDialog from '../dialogs/BookDetailsDialog';\nimport { BookedOption } from '../NewSessions';\nimport CellInfo from './CellInfo';\nimport BookedOptionDetails from '../BookedOptionDetails';\nimport { TIME_FORMAT_2 } from '../../../utils/helpers';\n\nexport const BOOKED_ICON_COLOR = '#F7716E';\n\nconst useBookedCellCellStyles = makeStyles((theme) => ({\n root: {\n backgroundColor: '#f7716e26',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-end',\n justifyContent: 'center',\n cursor: 'pointer',\n color: BOOKED_ICON_COLOR,\n paddingRight: theme.spacing(2),\n },\n rootMobile: {\n alignItems: 'center',\n paddingRight: 0,\n },\n icon: {\n color: BOOKED_ICON_COLOR,\n },\n bookedOptionDetailsWrapper: {\n margin: theme.spacing(1, 2),\n },\n bookedOptionDetailsRow: { '&:last-child': { borderBottom: 'none' } },\n bookingOptionsWrapper: {\n display: 'flex',\n boxShadow: '0px 0px 14px rgba(0, 0, 0, 0.25)',\n borderRadius: theme.spacing(1.5),\n },\n}));\n\nconst BookedCell = ({\n className,\n bookedOptions,\n}: Omit & { bookedOptions: BookedOption[] }) => {\n const [anchorEl, setAnchorEl] = useState(null);\n const [selected, setSelected] = useState(false);\n\n const classes = useBookedCellCellStyles();\n\n const isMobileScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('xs')\n );\n\n const isSmallScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('sm')\n );\n\n const handlePopoverOpen = (event: React.MouseEvent) => {\n setAnchorEl(event.currentTarget);\n };\n\n useEffect(() => {\n const selectCellIfStillHovering = () => {\n if (anchorEl) {\n setSelected(true);\n }\n };\n const hoverCheckTimeOut = setTimeout(selectCellIfStillHovering, 200);\n\n return () => {\n clearTimeout(hoverCheckTimeOut);\n };\n }, [anchorEl]);\n\n const handlePopoverClose = () => {\n setAnchorEl(null);\n setSelected(false);\n };\n\n const sortedBookedOptions = sortBy(bookedOptions, [\n (bookedOption) => {\n return bookedOption.startTime.toISOString();\n },\n ]);\n const { startTime } = sortedBookedOptions[0];\n const { endTime } = sortedBookedOptions[bookedOptions.length - 1];\n const duration = endTime.diff(startTime, 'minutes') / 60;\n\n return (\n <>\n setSelected(true) }\n : {\n rootProps: {\n onMouseEnter: handlePopoverOpen,\n onMouseLeave: handlePopoverClose,\n },\n })}\n className={clsx(\n classes.root,\n isSmallScreen && classes.rootMobile,\n className\n )}\n >\n \n {!isSmallScreen && (\n \n )}\n {!isMobileScreen && (\n \n {({ TransitionProps }) => (\n \n \n {bookedOptions.map((bookedOption) => {\n return (\n \n );\n })}\n \n \n )}\n \n )}\n \n\n {isMobileScreen && selected && (\n setSelected(false)}\n />\n )}\n \n );\n};\n\nexport default BookedCell;\n","import React from 'react';\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\n\nimport MatrixCell, { MatrixCellProps } from '../../../shared/matrix/ui/cell';\n\nconst useEmptyCellStyles = makeStyles((theme) => ({\n root: {\n backgroundColor: theme.palette.kyoSilver.light,\n },\n}));\n\nconst EmptyCell = ({ className }: Omit) => {\n const classes = useEmptyCellStyles();\n\n return ;\n};\n\nexport default EmptyCell;\n","import React from 'react';\nimport { Theme, makeStyles, useMediaQuery } from '@material-ui/core';\nimport { useSelector } from 'react-redux';\nimport { keyBy, range } from 'lodash';\n\nimport Matrix, { MatrixProps } from '../../../shared/matrix/ui';\nimport { DayOfWeekId, STBRBlockOption } from '../../../types/types';\nimport useCellStyles from '../../../shared/matrix/ui/cell/styles';\nimport { getTimeBlockDayOfWeekKey } from '../../../shared/lib/availability';\nimport { useHorizontalLabelStylesVariant3 } from '../../../shared/matrix/ui/horizontalLabelWeekDay/styles';\nimport {\n DayOfWeekLabelsVariant3,\n DayOfWeekValues,\n} from '../../../shared/matrix/ui/horizontalLabelWeekDay/lib';\nimport HorizontalLabelWeekDay from '../../../shared/matrix/ui/horizontalLabelWeekDay';\nimport { BookedOption, WeekRange } from '../NewSessions';\nimport { RootState } from '../../../redux/modules/rootReducer';\nimport VerticalLabelTimeBlock from '../../../shared/matrix/ui/verticalLabelTimeBlock';\nimport AvailableCell from './AvailableCell';\nimport SelectedCell from './SelectedCell';\nimport BookedCell from './BookedCell';\nimport EmptyCell from './EmptyCell';\nimport { SelectedBookingOption } from '../../../redux/modules/newSessions';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n matrixVerticalLabel: {\n margin: theme.spacing(1, 0),\n minWidth: theme.spacing(6.5),\n\n [theme.breakpoints.down('xs')]: {\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(2),\n marginLeft: '2.5vw',\n },\n },\n matrixVerticalLabelName: {\n ...theme.typography.subtitle2,\n },\n matrixVerticalLabelContent: {\n fontSize: 12,\n fontWeight: 600,\n },\n}));\n\ninterface AddSessionsMatrixProps extends Partial> {\n cellSizes: number;\n availableCells: Record;\n bookedCells: Record;\n selectedCells: Record;\n weekRange: WeekRange;\n disableAvailableCells?: boolean;\n}\n\nconst AddSessionsMatrix = ({\n cellSizes,\n weekRange,\n availableCells,\n bookedCells,\n selectedCells,\n disableAvailableCells = false,\n ...matrixProps\n}: AddSessionsMatrixProps) => {\n const classes = useStyles();\n\n const timeBlocks = useSelector(\n (state: RootState) => state.adminSettings.timeBlocks\n );\n\n const isSmallScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('xs')\n );\n\n const isTabletScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('sm')\n );\n\n const timeBlocksById = keyBy(timeBlocks, 'id');\n\n const cellClasses = useCellStyles({\n cellSizes,\n addMainStyles: (theme) => {\n return {\n margin: theme.spacing(0.375),\n borderRadius: theme.spacing(1.25),\n\n ...(!isTabletScreen && {\n width: '10vw',\n height: '6.5vw',\n maxWidth: theme.spacing(16),\n maxHeight: theme.spacing(10.375),\n }),\n\n ...(isTabletScreen &&\n !isSmallScreen && {\n width: '9vw',\n height: '7vw',\n }),\n };\n },\n })();\n const horizontalLabelStyles = useHorizontalLabelStylesVariant3();\n\n const availabilityRenderer = (\n horizontalValue: DayOfWeekId,\n verticalValue: number\n ): React.ReactNode => {\n const key = getTimeBlockDayOfWeekKey({\n timeBlockId: verticalValue,\n dayOfWeekId: horizontalValue,\n });\n\n const selectedOption = selectedCells[key];\n const bookOption = availableCells[key];\n const bookedOptions = bookedCells[key];\n\n if (selectedOption) {\n return (\n \n );\n }\n\n if (bookOption) {\n const dayStartTimeBlockDayOfWeekId = horizontalValue * 3;\n const nextDayTimeBlockDayOfWeekId = dayStartTimeBlockDayOfWeekId + 3;\n\n const someDaySelectedCellsTimeBlockDayOfWeekIds = range(\n dayStartTimeBlockDayOfWeekId,\n nextDayTimeBlockDayOfWeekId\n )\n .sort((a, b) => a - b)\n .filter((n) => selectedCells[n]);\n\n const beforeCells = someDaySelectedCellsTimeBlockDayOfWeekIds.filter(\n (n) => n < key\n );\n const afterCells = someDaySelectedCellsTimeBlockDayOfWeekIds.filter(\n (n) => n > key\n );\n\n return (\n \n );\n }\n\n if (bookedOptions) {\n return (\n \n );\n }\n\n return ;\n };\n\n return (\n (\n \n )}\n VerticalLabel={({ value }) => (\n \n )}\n render={availabilityRenderer}\n {...matrixProps}\n />\n );\n};\n\nexport default AddSessionsMatrix;\n","import React from 'react';\nimport { IconButton, makeStyles } from '@material-ui/core';\nimport DateRangeIcon from '@material-ui/icons/DateRange';\nimport KeyboardArrowLeftRoundedIcon from '@material-ui/icons/KeyboardArrowLeftRounded';\nimport KeyboardArrowRightRoundedIcon from '@material-ui/icons/KeyboardArrowRightRounded';\nimport moment from 'moment';\n\nimport {\n DATE_FORMAT_US,\n getFormattedWeekPickerDates,\n} from '../../utils/helpers';\nimport StyledMultipleDatePicker from '../../components/styledMultipleDatePicker/StyledMultipleDatePicker';\nimport { WeekRange } from './NewSessions';\n\nconst useStyles = makeStyles((theme) => ({\n weekSelectorWithButtonsWrapper: {\n display: 'flex',\n border: `1px solid ${theme.palette.kyoGray.main}`,\n borderRadius: theme.spacing(0.5),\n\n [theme.breakpoints.down('xs')]: {\n width: '100%',\n },\n },\n weekPicker: {\n display: 'flex',\n alignItems: 'center',\n marginRight: theme.spacing(2),\n\n [theme.breakpoints.down('xs')]: {\n width: '100%',\n justifyContent: 'space-between',\n },\n },\n weekIcon: {\n color: theme.palette.kyoBlue2.main,\n },\n firstIcon: {\n borderRadius: 0,\n borderLeft: `1px solid #F0F0F0`,\n borderRight: `1px solid #F0F0F0`,\n },\n}));\n\nconst AddSessionsWeekSelector = ({\n weekRange: { weekStart, weekEnd },\n handleChange,\n minDate,\n maxDate,\n}: {\n weekRange: WeekRange;\n handleChange: (values: string[]) => void;\n minDate: moment.Moment;\n maxDate: moment.Moment;\n}) => {\n const classes = useStyles();\n\n const handleDirectedWeekChange = (weeksCount: number) => {\n const newWeek = moment(weekStart, DATE_FORMAT_US).add(weeksCount, 'weeks');\n\n handleChange([\n newWeek.clone().startOf('week').format(DATE_FORMAT_US),\n newWeek.clone().endOf('week').format(DATE_FORMAT_US),\n ]);\n };\n\n return (\n
\n
\n {\n handleChange(\n getFormattedWeekPickerDates(value, DATE_FORMAT_US) || []\n );\n }}\n portal\n style={{\n backgroundColor: 'transparent',\n height: '52px',\n borderRadius: 0,\n }}\n minDate={minDate.clone().toDate()}\n maxDate={maxDate.clone().subtract(1, 'day').toDate()}\n />\n \n
\n {\n handleDirectedWeekChange(-1);\n }}\n aria-label=\"arrowLeft\"\n >\n \n \n {\n handleDirectedWeekChange(1);\n }}\n aria-label=\"arrowRight\"\n >\n \n \n
\n );\n};\n\nexport default AddSessionsWeekSelector;\n","import { Button, Typography, makeStyles } from '@material-ui/core';\nimport React from 'react';\nimport { useSelector } from 'react-redux';\nimport moment from 'moment';\nimport TimelapseIcon from '@material-ui/icons/Timelapse';\nimport { sortBy } from 'lodash';\n\nimport { RootState } from '../../redux/modules/rootReducer';\nimport {\n DATE_FORMAT,\n DATE_FORMAT_WEEKDAY_MONTH,\n TIME_FORMAT_2,\n humanizeDuration,\n} from '../../utils/helpers';\nimport { TIME_FORMAT } from '../../shared/constants';\nimport { useAppDispatch } from '../../redux/store';\nimport { removeSelectedBookingOption } from '../../redux/modules/newSessions';\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: 'flex',\n\n [theme.breakpoints.down('xs')]: {\n width: '100%',\n },\n },\n indicator: {\n width: theme.spacing(1),\n borderRadius: theme.spacing(0.5),\n backgroundColor: theme.palette.kyoBlue2.main,\n marginBottom: theme.spacing(1),\n },\n mainContent: {\n borderBottom: `1px solid ${theme.palette.kyoGray.main}`,\n paddingLeft: theme.spacing(1.5),\n paddingBottom: theme.spacing(0.75),\n width: '100%',\n },\n scheduledDate: { color: theme.palette.kyoGray.dark },\n footer: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n color: theme.palette.kyoGray63.main,\n },\n duration: {\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(0.25),\n\n '& svg': {\n fontSize: '1rem',\n },\n },\n removeButton: { padding: 0, color: 'inherit' },\n}));\n\nconst SelectedBooingOptions = () => {\n const classes = useStyles();\n\n const dispatch = useAppDispatch();\n\n const selectedBookingOptions = useSelector(\n (state: RootState) => state.newSessions.selectedBookingOptions\n );\n\n const sortedSelectedBookingOptions = sortBy(selectedBookingOptions, [\n 'scheduledDate',\n 'timeBlockId',\n ]);\n\n return (\n <>\n {sortedSelectedBookingOptions.map(\n ({\n scheduledDate,\n sessionPlacement: { startTime, duration, timeBlockId },\n }) => (\n
\n
\n
\n \n {moment(scheduledDate, DATE_FORMAT).format(\n DATE_FORMAT_WEEKDAY_MONTH\n )}\n , {moment(startTime, TIME_FORMAT).format(TIME_FORMAT_2)}\n \n
\n
\n \n \n {humanizeDuration(duration)}\n \n
\n {\n dispatch(\n removeSelectedBookingOption({\n scheduledDate,\n timeBlockId,\n })\n );\n }}\n >\n Remove\n \n
\n
\n
\n )\n )}\n \n );\n};\n\nexport default SelectedBooingOptions;\n","import React from 'react';\nimport EventAvailableIcon from '@material-ui/icons/EventAvailable';\nimport AddCircleOutlineIcon from '@material-ui/icons/AddCircleOutline';\nimport { Typography, makeStyles } from '@material-ui/core';\nimport { AVAILABLE_ICON_COLOR } from './AvailableCell';\nimport { BOOKED_ICON_COLOR } from './BookedCell';\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: 'flex',\n gap: theme.spacing(0.5),\n },\n info: {\n display: 'flex',\n gap: theme.spacing(0.25),\n alignItems: 'center',\n color: theme.palette.kyoGray3.light,\n\n '& svg': {\n fontSize: '1rem',\n },\n },\n availableIcon: {\n color: AVAILABLE_ICON_COLOR,\n },\n bookedIcon: {\n color: BOOKED_ICON_COLOR,\n },\n}));\n\nconst AddSessionsMatrixInfo = () => {\n const classes = useStyles();\n\n return (\n
\n
\n \n Available\n
\n
\n \n Booked\n
\n
\n );\n};\n\nexport default AddSessionsMatrixInfo;\n","import {\n Avatar,\n Divider,\n LinearProgress,\n makeStyles,\n Theme,\n Typography,\n useMediaQuery,\n} from '@material-ui/core';\nimport { KeyboardBackspace } from '@material-ui/icons';\nimport React, { useEffect, useMemo, useState } from 'react';\nimport { useDispatch, useSelector } from 'react-redux';\nimport moment from 'moment';\nimport { DateObject } from 'react-multi-date-picker';\nimport { groupBy } from 'lodash';\n\nimport StyledButtonLink from '../../components/buttons/StyledButtonLink';\nimport { RootState } from '../../redux/modules/rootReducer';\nimport {\n clearSelectedBookingOptions,\n createSingleTermBookRequest,\n SelectedBookingOption,\n fetchClientSessions,\n clearClientSessions,\n} from '../../redux/modules/newSessions';\nimport {\n DayOfWeekId,\n MainRequestTypes,\n SessionStatus,\n STBRBlockOption,\n} from '../../types/types';\nimport SessionsSubmitted from './SessionsSubmitted';\nimport { DATE_FORMAT, DATE_FORMAT_US } from '../../utils/helpers';\nimport AddSessionsMatrix from './matrix/AddSessionsMatrix';\nimport { getTimeBlockDayOfWeekKey } from '../../shared/lib/availability';\nimport AddSessionsWeekSelector from './AddSessionsWeekSelector';\nimport ActionsControlButton from '../../components/buttons/ActionsControlButton';\n\nimport SelectedBooingOptions from './SelectedBookingOptions';\nimport AddSessionsMatrixInfo from './matrix/AddSessionsMatrixInfo';\nimport BTAvailabilityInfoDialog from '../../components/HintText/BTAvailabilityInfoDialog';\nimport AnalyticsTracker, {\n TrackerNames,\n} from '../../analytics/AnalyticsTracker';\n\nexport interface BookedOption {\n timeBlockDayOfWeekId: number;\n type?: MainRequestTypes;\n scheduledDate: string;\n bookingWith: string;\n startTime: moment.Moment;\n endTime: moment.Moment;\n duration: number;\n status: SessionStatus;\n}\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {},\n avatar: {\n width: theme.spacing(5),\n height: theme.spacing(5),\n marginRight: 8,\n },\n description: {\n color: theme.palette.kyoGray63.dark,\n marginTop: theme.spacing(2),\n },\n buttonWrapper: {\n [theme.breakpoints.up('sm')]: {\n display: 'flex',\n gap: theme.spacing(2),\n flexDirection: 'row-reverse',\n width: '50%',\n marginLeft: 'auto',\n },\n },\n\n providerCard: {\n display: 'flex',\n alignItems: 'center',\n },\n providerCardText: {\n paddingLeft: theme.spacing(1),\n },\n provideName: {\n lineHeight: '138%',\n letterSpacing: '0.0075em',\n },\n addSessionHeader: {\n display: 'flex',\n alignItems: 'flex-end',\n justifyContent: 'space-between',\n margin: theme.spacing(2, 0),\n gap: theme.spacing(2),\n\n [theme.breakpoints.down('sm')]: {\n flexDirection: 'column',\n alignItems: 'flex-start',\n },\n },\n matrixCustomContent: {\n gridColumnStart: 2,\n\n [theme.breakpoints.down('xs')]: {\n gridColumnStart: 1,\n },\n },\n selectedBookingOptionsWrapper: {\n display: 'flex',\n flexFlow: 'wrap',\n gap: theme.spacing(3.74),\n marginTop: theme.spacing(2),\n },\n countAndMatrixInfo: {\n display: 'flex',\n justifyContent: 'space-between',\n marginBottom: theme.spacing(1.75),\n },\n countInfo: {\n opacity: 0.5,\n },\n loading: {\n marginTop: theme.spacing(4),\n },\n}));\n\ninterface NewSessionsProps {\n goBack: () => void;\n handleSuccess?: () => void;\n preferredDate?: DateObject;\n}\n\nexport interface WeekRange {\n weekStart: string;\n weekEnd: string;\n}\n\nconst getMaxSessionsCount = (\n potentialSessions: number,\n numOfAllowedSessions: number,\n extraSessions: number\n) => {\n return Math.min(potentialSessions, numOfAllowedSessions + extraSessions);\n};\n\nconst getAddSessionWithProviderText = (\n potentialSessions: number,\n numOfAllowedSessions: number,\n extraSessions: number\n) => {\n return (\n <>\n Select a block and a time. You can request up to{' '}\n \n {getMaxSessionsCount(\n potentialSessions,\n numOfAllowedSessions,\n extraSessions\n )}\n {' '}\n additional sessions.\n \n );\n};\n\nconst NewSessions = ({\n goBack,\n preferredDate,\n handleSuccess,\n}: NewSessionsProps) => {\n const classes = useStyles();\n const dispatch = useDispatch();\n\n const isSmallScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('xs')\n );\n\n const selectedProvider = useSelector(\n (state: RootState) => state.newSessions.selectedProvider\n );\n\n const currentClient = useSelector(\n (state: RootState) => state.client.currentClient\n );\n\n const selectedBookingOptions = useSelector(\n (state: RootState) => state.newSessions.selectedBookingOptions\n );\n\n const createSessionInProgress = useSelector(\n (state: RootState) => state.newSessions.createSessionInProgress\n );\n\n const createSessionSuccess = useSelector(\n (state: RootState) => state.newSessions.createSessionSuccess\n );\n const clientSTBRAvailability = useSelector(\n (state: RootState) => state.newSessions.clientSTBRAvailability\n );\n\n const clientSessions = useSelector(\n (state: RootState) => state.newSessions.sessions\n );\n\n useEffect(() => {\n return () => {\n dispatch(clearSelectedBookingOptions());\n };\n }, [dispatch]);\n\n const bookOptionsCount =\n selectedProvider?.bookDetails.bookOptions.length || 0;\n\n const lastSessionDate =\n selectedProvider?.bookDetails.bookOptions[bookOptionsCount - 1]\n .scheduledDate;\n\n const firstSessionDate =\n selectedProvider?.bookDetails.bookOptions[0].scheduledDate;\n\n const minWeekDate = useMemo(\n () => moment(firstSessionDate, DATE_FORMAT).startOf('week'),\n [firstSessionDate]\n );\n const maxWeekDate = useMemo(\n () => moment(lastSessionDate, DATE_FORMAT).endOf('week'),\n [lastSessionDate]\n );\n\n useEffect(() => {\n const { id: clientId } = currentClient || {};\n if (!clientId) {\n return () => null;\n }\n dispatch(\n fetchClientSessions({\n clientId,\n startDate: minWeekDate.format(DATE_FORMAT),\n endDate: maxWeekDate.format(DATE_FORMAT),\n })\n );\n\n return () => {\n dispatch(clearClientSessions());\n };\n }, [dispatch, currentClient, minWeekDate, maxWeekDate]);\n\n const [bookedOptions, setBookedOptions] = useState([]);\n\n useEffect(() => {\n const tempBookedOptions: BookedOption[] = [];\n\n (clientSessions || []).forEach((session) => {\n session.blocks.forEach((block) => {\n tempBookedOptions.push({\n timeBlockDayOfWeekId: block.id,\n scheduledDate: session.scheduledDate,\n type: session.bookRequestType as MainRequestTypes,\n bookingWith: session.provider?.name || '',\n startTime: moment(session.segmentStartUtc),\n endTime: moment(session.segmentEndUtc),\n duration: session.segmentDuration,\n status: session.status,\n });\n });\n });\n\n setBookedOptions(tempBookedOptions);\n }, [clientSessions]);\n\n const [weekRange, setWeekRange] = useState(\n (() => {\n const defaultDate = (() => {\n if (preferredDate) {\n return moment(preferredDate.toDate());\n }\n return minWeekDate;\n })();\n\n return {\n weekStart: defaultDate.clone().startOf('week').format(DATE_FORMAT_US),\n weekEnd: defaultDate.clone().endOf('week').format(DATE_FORMAT_US),\n };\n })()\n );\n\n const [inWeekBookOptions, setInWeekBookOptions] = useState<\n Record\n >({});\n\n const [inWeekSelectedBookOptions, setInWeekSelectedBookingOptions] = useState<\n Record\n >({});\n\n const [inWeekBookedOptions, setInWeekBookedOptions] = useState<\n Record\n >({});\n\n const getFindInRangeOptionsFilter = (\n weekStart: moment.Moment,\n weekEnd: moment.Moment\n ) => >(blockOption: T) => {\n const { scheduledDate } = blockOption;\n const momentScheduledDate = moment(scheduledDate, DATE_FORMAT);\n const isBookOptionInRange = momentScheduledDate.isBetween(\n weekStart,\n weekEnd,\n undefined,\n '[]'\n );\n\n return isBookOptionInRange;\n };\n\n const mapOptionsByTimeBlockDayOfWeekId = <\n T extends Pick\n >(\n mappedOptions: Record,\n option: T\n ) => {\n const { scheduledDate, timeBlockId } = option;\n\n const timeBlockDayOfWeekId = getTimeBlockDayOfWeekKey({\n dayOfWeekId: moment(scheduledDate, DATE_FORMAT).weekday() as DayOfWeekId,\n timeBlockId,\n });\n\n return { ...mappedOptions, [timeBlockDayOfWeekId]: option };\n };\n\n useEffect(() => {\n const momentWeekStart = moment(weekRange.weekStart, DATE_FORMAT_US);\n const momentWeekEnd = moment(weekRange.weekEnd, DATE_FORMAT_US);\n\n const inRangeOptionsFilter = getFindInRangeOptionsFilter(\n momentWeekStart,\n momentWeekEnd\n );\n\n setInWeekBookOptions(\n selectedProvider?.bookDetails.bookOptions\n .filter(inRangeOptionsFilter)\n .reduce(\n mapOptionsByTimeBlockDayOfWeekId,\n {} as Record\n ) || {}\n );\n\n setInWeekSelectedBookingOptions(\n selectedBookingOptions\n .filter(inRangeOptionsFilter)\n .reduce(\n mapOptionsByTimeBlockDayOfWeekId,\n {} as Record\n ) || {}\n );\n\n setInWeekBookedOptions(\n groupBy(\n bookedOptions.filter(inRangeOptionsFilter),\n 'timeBlockDayOfWeekId'\n ) as Record\n );\n }, [\n weekRange.weekStart,\n weekRange.weekEnd,\n selectedProvider,\n selectedBookingOptions,\n bookedOptions,\n ]);\n\n const handleWeekPickerChange = (range: string[]) => {\n setWeekRange({ weekStart: range[0], weekEnd: range[1] });\n };\n\n const {\n minNumberOfSessionsCanBooked,\n maxNumberOfSessionsCanBooked,\n extraSessionsNumberToSelect,\n } = clientSTBRAvailability;\n\n const isSubmitDisabled = useMemo(() => {\n if (selectedProvider) {\n const selectedBookingOptionsCount = selectedBookingOptions.length;\n\n return selectedBookingOptionsCount < minNumberOfSessionsCanBooked;\n }\n return false;\n }, [selectedProvider, selectedBookingOptions, minNumberOfSessionsCanBooked]);\n\n const handleSubmit = async () => {\n if (!currentClient || !selectedProvider) {\n return;\n }\n await dispatch(\n createSingleTermBookRequest({\n clientId: currentClient.id,\n providerId: selectedProvider?.id,\n })\n );\n if (handleSuccess) {\n handleSuccess();\n }\n };\n\n const maxSessionsCount = selectedProvider\n ? getMaxSessionsCount(\n selectedProvider.bookDetails.numOfPotentialSessions,\n maxNumberOfSessionsCanBooked,\n extraSessionsNumberToSelect\n )\n : 0;\n\n const matrixCustomElements = (\n
\n
\n \n {selectedBookingOptions.length} of {maxSessionsCount} are selected\n \n \n
\n
\n \n
\n
\n );\n\n return (\n
\n \n }>\n Add Sessions\n \n \n {createSessionSuccess ? 'Sessions submitted' : 'Select Time'}\n \n \n {createSessionSuccess ? (\n \n ) : (\n <>\n
\n
\n
\n \n
\n Book with\n \n {`${selectedProvider?.firstName} ${selectedProvider?.lastName}`}\n \n
\n
\n\n \n {selectedProvider &&\n getAddSessionWithProviderText(\n selectedProvider.bookDetails.numOfPotentialSessions,\n maxNumberOfSessionsCanBooked,\n extraSessionsNumberToSelect\n )}\n \n \n
\n\n \n
\n = maxSessionsCount\n }\n />\n \n {createSessionInProgress && (\n
\n \n
\n )}\n \n )}\n
\n );\n};\n\nexport default NewSessions;\n","import React from 'react';\nimport { Typography, makeStyles } from '@material-ui/core';\nimport FilterListIcon from '@material-ui/icons/FilterList';\nimport SimpleDialog from '../../../components/Dialogs/SimpleDialog';\nimport StyledButtonLink from '../../../components/buttons/StyledButtonLink';\nimport BTAvailabilityInfoDialog from '../../../components/HintText/BTAvailabilityInfoDialog';\n\nconst useStyles = makeStyles((theme) => ({\n enoughOptions: {\n marginTop: theme.spacing(2),\n },\n row: {\n display: 'flex',\n alignItems: 'center',\n margin: theme.spacing(1.5, 0),\n },\n showTimesButton: {\n marginLeft: theme.spacing(0.5),\n },\n filterIcon: {\n display: 'flex',\n alignItems: 'center',\n padding: theme.spacing(0.25),\n backgroundColor: '#F0F0F0',\n borderRadius: theme.spacing(1),\n marginLeft: theme.spacing(0.5),\n },\n}));\n\nconst InfoPopup = ({\n text,\n handleClose,\n handleShowOutsideMyAvailabilityTimes,\n}: {\n text: React.ReactNode;\n handleClose: () => void;\n handleShowOutsideMyAvailabilityTimes: () => void;\n}) => {\n const classes = useStyles();\n\n return (\n \n {text}\n \n Not seeing enough options?
Search for therapists and times\n outside of your regular availability:\n
\n
\n 1. Click on Filters icon{' '}\n
\n \n
\n
\n
\n 2. Turn on\n \n Show Times Outside My Availability\n \n
\n \n
\n );\n};\n\nexport default InfoPopup;\n","import { useCallback, useRef } from 'react';\nimport fetchIntercept from 'fetch-intercept';\nimport { uuid } from 'uuidv4';\n\nconst SESSION_TRACKER_HEADER = 'x-session-tracker';\n\nconst useSessionTrackerId = () => {\n const interceptorRef = useRef({\n unregister: () => {\n // this function will clear the fetch interceptor\n },\n });\n\n const startTracking = useCallback(() => {\n const sessionTrackerId = uuid();\n\n // clean up old tracking\n interceptorRef.current.unregister();\n\n interceptorRef.current.unregister = fetchIntercept.register({\n request: (url, config) => {\n const updatedConfig = {\n ...config,\n };\n updatedConfig.headers[SESSION_TRACKER_HEADER] = sessionTrackerId;\n return [url, updatedConfig];\n },\n });\n }, []);\n\n const stopTracking = useCallback(() => {\n interceptorRef.current.unregister();\n }, []);\n\n return { startTracking, stopTracking };\n};\n\nexport default useSessionTrackerId;\n","import {\n Box,\n Button,\n makeStyles,\n TableCell,\n TableRow,\n Theme,\n Typography,\n useMediaQuery,\n} from '@material-ui/core';\nimport MUIDataTable, {\n MUIDataTableColumn,\n MUIDataTableOptions,\n} from 'mui-datatables';\nimport React, { useCallback, useEffect, useRef, useState } from 'react';\nimport { useDispatch, useSelector } from 'react-redux';\nimport moment from 'moment';\nimport { orderBy, some } from 'lodash';\nimport { useDebounce } from 'use-debounce';\nimport ArrowRightAltIcon from '@material-ui/icons/ArrowRightAlt';\nimport { Link } from 'react-router-dom';\nimport { DateObject } from 'react-multi-date-picker';\nimport clsx from 'clsx';\n\nimport StyledButton from '../../components/buttons/StyledButton';\nimport CustomTableFooter from '../../components/table/CustomTableFooter';\nimport ProviderCell from '../../components/table/ProviderCell';\nimport HintText from '../../components/HintText/HintText';\nimport { RootState } from '../../redux/modules/rootReducer';\nimport infoCircleSrc from '../../assets/info-circle.svg';\nimport {\n DATE_FORMAT,\n DATE_FORMAT_MONTH_NAME,\n TIME_FORMAT,\n TIME_FORMAT_24HR,\n} from '../../utils/helpers';\nimport ScreenTitle from '../../components/ScreenTitle';\nimport {\n fetchClientSingleTermBookingAvailability,\n setCreateSessionSuccess,\n setSelectedProvider,\n setToInitialState,\n} from '../../redux/modules/newSessions';\nimport useAddSessions from '../../hooks/useAddSessions';\nimport { ProviderWithBookDetails } from '../../types/types';\nimport CustomLoading from '../../components/CustomLoading/CustomLoading';\nimport warningDiamondIcon from '../../assets/warning-diamond-icon.svg';\nimport AddSessionFilters from './AddSessionFIlters';\nimport NewSessions from './NewSessions';\nimport InfoPopup from './dialogs/InfoPopup';\nimport useSessionTrackerId from '../../hooks/useSessionTrackerId';\nimport AnalyticsTracker, {\n TrackerNames,\n} from '../../analytics/AnalyticsTracker';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n expandedTableCell: {\n paddingTop: 0,\n [theme.breakpoints.down('sm')]: {\n paddingLeft: 0,\n paddingRight: 0,\n },\n },\n cancelButton: {\n marginTop: theme.spacing(2),\n },\n section: {\n margin: theme.spacing(2, 0),\n },\n warningText: {\n display: 'flex',\n gap: theme.spacing(1.5),\n },\n infoSection: {\n display: 'flex',\n alignItems: 'flex-start',\n gap: theme.spacing(1.5),\n },\n title: {\n display: 'flex',\n },\n}));\n\nconst getColumns = (\n providers: ProviderWithBookDetails[],\n expandedRow: number | null,\n onExpand: (dataIndex: number, isExpanded: boolean) => void,\n isSmallScreen: boolean,\n handleAddSession: (provider: ProviderWithBookDetails) => void,\n showPreferredDates = false\n): MUIDataTableColumn[] => [\n {\n name: 'ProviderName',\n label: 'Provider',\n options: {\n display: isSmallScreen ? 'excluded' : true,\n customBodyRenderLite: (dataIndex) => {\n const provider = providers[dataIndex];\n const isExpanded = expandedRow === dataIndex;\n return (\n
\n {\n onExpand(dataIndex, isExpanded);\n }}\n isMyTeam={provider.bookDetails.inCaseTeam}\n />\n
\n );\n },\n },\n },\n {\n name: 'rebookOptions',\n label: showPreferredDates ? 'Preferred Date Avail.' : 'Next Avail. Date',\n options: {\n display: isSmallScreen ? 'excluded' : true,\n sort: false,\n customBodyRenderLite: (dataIndex) => {\n const provider = providers[dataIndex];\n\n if (\n showPreferredDates &&\n provider.bookDetails.preferredDatesAvailability\n ) {\n const { preferredDatesAvailability } = provider.bookDetails;\n const text = preferredDatesAvailability\n .map((d: string) => moment.utc(d).format(DATE_FORMAT_MONTH_NAME))\n .join(', ');\n return (\n
\n {text}\n
\n );\n }\n\n const { bookOptions } = provider.bookDetails;\n let sessionPlacement;\n let schedDate;\n if (bookOptions && bookOptions.length > 0) {\n const earliest = orderBy(bookOptions, 'timeBlockStartTime', 'asc')[0];\n schedDate = earliest.scheduledDate;\n const { sessionPlacements } = earliest;\n\n if (sessionPlacements && sessionPlacements.length > 0) {\n [sessionPlacement] = sessionPlacements;\n }\n }\n\n return (\n
\n \n {moment.utc(schedDate).format(DATE_FORMAT_MONTH_NAME)}\n \n {sessionPlacement && (\n \n {moment\n .utc(sessionPlacement.startTime, TIME_FORMAT_24HR)\n .format(TIME_FORMAT)}\n \n )}\n
\n );\n },\n },\n },\n {\n name: 'potentialSessions',\n label: 'Potential Sessions',\n options: {\n display: isSmallScreen ? 'excluded' : true,\n sort: false,\n customBodyRenderLite: (dataIndex) => {\n const provider = providers[dataIndex];\n return (\n
\n \n {provider.bookDetails.numOfPotentialSessions}\n \n
\n );\n },\n },\n },\n {\n name: '',\n label: 'Add Sessions',\n options: {\n sort: false,\n display: isSmallScreen ? 'excluded' : true,\n customBodyRenderLite: (dataIndex: number) => {\n const provider = providers[dataIndex];\n return (\n handleAddSession(provider)}>\n \n Add Sessions\n \n \n );\n },\n },\n },\n {\n name: '',\n label: '',\n options: {\n sort: false,\n display: isSmallScreen ? true : 'excluded',\n customBodyRenderLite: (dataIndex: number) => {\n const provider = providers[dataIndex];\n const isExpanded = expandedRow === dataIndex;\n return (\n \n {\n onExpand(dataIndex, isExpanded);\n }}\n isMyTeam={provider.bookDetails.inCaseTeam}\n />\n handleAddSession(provider)}\n style={{ padding: 0, minHeight: 'unset' }}\n >\n \n Add Sessions\n \n \n
\n );\n },\n },\n },\n];\n\nconst AddSessions = () => {\n const classes = useStyles();\n const dispatch = useDispatch();\n const ref = useRef(true);\n const firstRender = ref.current;\n\n const { startTracking, stopTracking } = useSessionTrackerId();\n\n const isMobileScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('xs')\n );\n\n const isSmallScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('sm')\n );\n const isBetweenSmallScreen = useMediaQuery((theme: Theme) =>\n theme.breakpoints.only('sm')\n );\n\n const currentClient = useSelector(\n (state: RootState) => state.client.currentClient\n );\n\n const currentClientLoading = useSelector(\n (state: RootState) => state.client.currentClientLoading\n );\n\n const clientSTBRAvailability = useSelector(\n (state: RootState) => state.newSessions.clientSTBRAvailability\n );\n const clientSTBRAvailabilityLoading = useSelector(\n (state: RootState) => state.newSessions.clientSTBRAvailabilityLoading\n );\n\n const selectedProvider = useSelector(\n (state: RootState) => state.newSessions.selectedProvider\n );\n\n const createSessionSuccess = useSelector(\n (state: RootState) => state.newSessions.createSessionSuccess\n );\n\n const [showInfo, setShowInfo] = useState(false);\n\n const [expandedRows, setExpandedRows] = useState<{\n allProviders: number | null;\n providersOnPreferredDates: number | null;\n providersOnOtherDates: number | null;\n }>({\n allProviders: null,\n providersOnOtherDates: null,\n providersOnPreferredDates: null,\n });\n\n const [preferredDates, setPreferredDates] = useState([]);\n\n const [\n showOptionsOutsideOfMyAvailability,\n setShowOptionsOutsideOfMyAvailability,\n ] = useState(false);\n\n const [filtersListOpen, setFiltersListOpen] = useState(false);\n\n const [providersOnPreferredDates, setProvidersOnPreferredDates] = useState<\n ProviderWithBookDetails[]\n >([]);\n\n const [providersOnOtherDates, setProvidersOnOtherDates] = useState<\n ProviderWithBookDetails[]\n >([]);\n\n const [debouncedShowOptionsOutsideOfMyAvailability] = useDebounce(\n showOptionsOutsideOfMyAvailability,\n 800\n );\n const {\n singleSessionProviders,\n getSingleSessionProviders,\n singleSessionProvidersLoading,\n } = useAddSessions();\n\n const { canClientBook } = clientSTBRAvailability;\n const {\n id: currentClientId,\n attributes: { pause = false, assignmentApprovalRequired = false } = {},\n } = currentClient || {};\n\n const [isShowMyTeam, setShowMyTeam] = useState(assignmentApprovalRequired);\n\n const [debouncedShowMyTeam] = useDebounce(isShowMyTeam, 800);\n\n const clientCanBook = !!canClientBook && !pause;\n\n const notEnoughAvailableBlocks = !singleSessionProviders?.length;\n\n const fetchSingleSessionProviders = useCallback(() => {\n if (currentClientId && clientCanBook) {\n getSingleSessionProviders({\n caseTeam: debouncedShowMyTeam ? 'only' : undefined,\n ignoreAvailability: debouncedShowOptionsOutsideOfMyAvailability,\n });\n }\n }, [\n currentClientId,\n clientCanBook,\n getSingleSessionProviders,\n debouncedShowMyTeam,\n debouncedShowOptionsOutsideOfMyAvailability,\n ]);\n\n const handleGoBack = () => {\n dispatch(setSelectedProvider(null));\n dispatch(setCreateSessionSuccess(false));\n };\n\n useEffect(\n () => () => {\n dispatch(setToInitialState());\n },\n [dispatch]\n );\n\n useEffect(() => {\n startTracking();\n\n return () => {\n stopTracking();\n };\n }, [startTracking, stopTracking]);\n\n useEffect(() => {\n if (currentClientId && !createSessionSuccess) {\n // dont make this request on success screen\n dispatch(fetchClientSingleTermBookingAvailability(currentClientId));\n const isShowTeam = assignmentApprovalRequired;\n setShowMyTeam(isShowTeam);\n }\n }, [\n dispatch,\n currentClientId,\n assignmentApprovalRequired,\n createSessionSuccess,\n ]);\n\n useEffect(() => {\n if (\n currentClientId &&\n !currentClientLoading &&\n !firstRender &&\n !clientSTBRAvailabilityLoading\n ) {\n fetchSingleSessionProviders();\n }\n\n if (currentClientLoading) {\n setPreferredDates([]);\n setShowOptionsOutsideOfMyAvailability(false);\n }\n }, [\n firstRender,\n fetchSingleSessionProviders,\n currentClientId,\n currentClientLoading,\n clientSTBRAvailabilityLoading,\n ]);\n\n useEffect(() => {\n if (!currentClient) {\n dispatch(setToInitialState());\n }\n ref.current = false;\n }, [currentClient, dispatch]);\n\n useEffect(() => {\n if (preferredDates.length && singleSessionProviders) {\n const filteredProviders: ProviderWithBookDetails[] = [];\n const otherProviders: ProviderWithBookDetails[] = [];\n singleSessionProviders.forEach((provider) => {\n const preferredDatesAvailability: string[] = [];\n preferredDates.forEach((preferredDate) => {\n const dateIsAvailable = some(\n provider.bookDetails.bookOptions,\n (bookOption) => {\n return (\n moment(bookOption.scheduledDate.split('T')[0]).format(\n DATE_FORMAT\n ) === preferredDate.format(DATE_FORMAT)\n );\n }\n );\n if (dateIsAvailable) {\n preferredDatesAvailability.push(preferredDate.format(DATE_FORMAT));\n }\n });\n\n if (preferredDatesAvailability.length) {\n filteredProviders.push({\n ...provider,\n bookDetails: {\n ...provider.bookDetails,\n preferredDatesAvailability,\n },\n });\n } else {\n otherProviders.push({\n ...provider,\n bookDetails: {\n ...provider.bookDetails,\n preferredDatesAvailability: [],\n },\n });\n }\n });\n\n setProvidersOnPreferredDates(filteredProviders);\n setProvidersOnOtherDates(otherProviders);\n }\n }, [preferredDates, singleSessionProviders]);\n\n const handleRowExpand = (type: keyof typeof expandedRows) => (\n dataIndex: number\n ) => {\n setExpandedRows((currentState) => {\n const newState = { ...currentState };\n if (currentState[type] === dataIndex) {\n newState[type] = null;\n } else {\n newState[type] = dataIndex;\n }\n return newState;\n });\n };\n\n const handleAddSession = (provider: ProviderWithBookDetails) => {\n dispatch(setSelectedProvider(provider));\n };\n\n const getTableOptions: (\n providerList: ProviderWithBookDetails[] | null,\n expandedRow: number | null\n ) => MUIDataTableOptions = (providerList, expandedRow) => ({\n viewColumns: false,\n selectableRows: 'none',\n search: false,\n print: false,\n filter: false,\n download: false,\n elevation: 0,\n responsive: 'standard',\n rowsPerPage: 10,\n rowsPerPageOptions: [5, 10, 15],\n rowHover: false,\n expandableRows: true,\n expandableRowsHeader: false,\n renderExpandableRow: (_, rowMeta) => {\n const { dataIndex } = rowMeta;\n if (!providerList) {\n return null;\n }\n\n const provider = providerList[dataIndex];\n\n const languages = [\n 'English',\n provider.attributes?.spanish && 'Spanish',\n provider.attributes?.mandarin && 'Mandarin',\n provider.attributes?.cantonese && 'Cantonese',\n ];\n\n const languageString = `Languages: ${languages\n .filter(Boolean)\n .join(', ')}`;\n\n return (\n \n \n \n {languageString}\n {provider.attributes?.bio && (\n \n {provider.attributes.bio}\n \n )}\n \n \n \n );\n },\n rowsExpanded: [expandedRow],\n });\n\n const showLoading =\n singleSessionProvidersLoading ||\n currentClientLoading ||\n clientSTBRAvailabilityLoading;\n\n const clientSTBRAvailabilityLoaded =\n !currentClientLoading && !clientSTBRAvailabilityLoading;\n\n const showPreferredDateSection = !!preferredDates.length;\n\n const infoIcon = \"infoIcon\";\n\n const hintText = (\n \n );\n\n if (selectedProvider) {\n const matchedPreferredDates = preferredDates.filter((preferredDate) =>\n selectedProvider.bookDetails.bookOptions.some(\n (bookOption) =>\n preferredDate.format(DATE_FORMAT) ===\n bookOption.scheduledDate.split('T')[0]\n )\n );\n\n const smallestPreferredDate = (() => {\n if (!matchedPreferredDates.length) {\n return undefined;\n }\n\n if (\n matchedPreferredDates.length === 1 ||\n matchedPreferredDates[0].valueOf() < matchedPreferredDates[1].valueOf()\n ) {\n return matchedPreferredDates[0];\n }\n\n return matchedPreferredDates[1];\n })();\n\n return (\n \n );\n }\n\n return (\n <>\n \n {clientSTBRAvailabilityLoaded && clientCanBook && (\n \n )}\n {clientSTBRAvailabilityLoaded &&\n (!clientCanBook || notEnoughAvailableBlocks) && (\n \n )}\n setShowInfo(true)}>{infoIcon}\n ) : (\n <>\n )\n }\n className={classes.title}\n />\n {clientSTBRAvailabilityLoaded && (!isMobileScreen || !clientCanBook) && (\n
\n {clientCanBook && infoIcon}\n
{hintText}
\n
\n )}\n {clientSTBRAvailabilityLoaded && clientCanBook && (\n \n )}\n {showLoading ? (\n \n ) : (\n <>\n {clientCanBook ? (\n <>\n {showPreferredDateSection && (\n <>\n
\n {providersOnPreferredDates.length ? (\n <>\n \n These therapists are available on your preferred\n date:\n \n \n \n ) : (\n
\n \n \n Sorry - no therapists are available on your\n preferred day\n \n
\n )}\n
\n
\n \n Therapists with availability on other dates:\n \n \n
\n \n )}\n {!showPreferredDateSection && (\n \n )}\n \n ) : (\n
\n \n }\n >\n Return Home\n \n \n
\n )}\n \n )}\n
\n {showInfo && clientCanBook && (\n setShowInfo(false)}\n handleShowOutsideMyAvailabilityTimes={() => {\n setShowInfo(false);\n setFiltersListOpen(true);\n }}\n />\n )}\n \n );\n};\n\nexport default AddSessions;\n","import { useEffect } from 'react';\nimport { useSelector, useDispatch } from 'react-redux';\nimport fetchIntercept from 'fetch-intercept';\nimport { setMaintenance } from '../redux/modules/maintenance';\nimport { RootState } from '../redux/modules/rootReducer';\n\nconst useMaintenanceCheck = () => {\n const dispatch = useDispatch();\n const maintenanceStatusOn = useSelector(\n (state: RootState) => state.maintenance.status\n );\n useEffect(() => {\n fetchIntercept.register({\n response: (response) => {\n const { status } = response;\n const isMaintenance = status === 503;\n if (isMaintenance) {\n dispatch(setMaintenance(true));\n }\n return response;\n },\n });\n }, [dispatch]);\n\n return {\n maintenanceStatusOn,\n };\n};\n\nexport default useMaintenanceCheck;\n","import React, { useEffect } from 'react';\nimport { useDispatch } from 'react-redux';\nimport {\n makeStyles,\n Theme,\n Divider,\n Typography,\n Link,\n} from '@material-ui/core';\nimport FormContainer from './FormContainer/FormContainer';\nimport icon from '../assets/maintenance-icon.svg';\nimport { fetchMaintenance } from '../redux/modules/maintenance';\nimport { SCH_EMAIL, SCH_PHONE_NUMBER_FORMATTED } from '../utils/constants';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n maintenanceForm: {\n textAlign: 'center',\n margin: theme.spacing(2, 'auto'),\n },\n title: {\n marginBottom: theme.spacing(2),\n },\n divider: {\n marginBottom: theme.spacing(0),\n },\n icon: {\n width: 100,\n height: 100,\n marginBottom: theme.spacing(1),\n },\n dividerEnd: {\n margin: theme.spacing(3, 0),\n },\n}));\n\nconst Maintenance = () => {\n const classes = useStyles();\n const dispatch = useDispatch();\n\n useEffect(() => {\n const timer = setInterval(() => {\n dispatch(fetchMaintenance());\n }, 30000);\n\n return () => clearInterval(timer);\n }, [dispatch]);\n\n return (\n \n <>\n \n Website under Maintenance!\n \n\n \n\n <>\n \"maintenanceIcon\"\n We are currently down for maintenance.\n Please check back soon.\n \n\n \n\n \n If you require assistance with removing a session or communicating\n with your Care Team, please contact the Scheduling Team via phone at{' '}\n \n {`${SCH_PHONE_NUMBER_FORMATTED}`}{' '}\n \n ext 2. If you have a non urgent request, please email us at{' '}\n {`${SCH_EMAIL}`}\n \n \n \n );\n};\n\nexport default Maintenance;\n","import { Auth } from '@aws-amplify/auth';\nimport { io, Socket } from 'socket.io-client';\n\nimport store from '../redux/store';\nimport configs from '../configs';\nimport { fetchUnhandledRequests } from '../redux/modules/requests';\nimport { fetchFeed } from '../redux/modules/feed';\n\nexport const socket: { main: Socket | null } = {\n main: null,\n};\n\nconst wait = (ms = 10000) => new Promise((resolve) => setTimeout(resolve, ms));\n\nexport const closeSocketConnection = () => {\n if (socket.main) {\n socket.main.close();\n }\n};\n\nexport const openSocketConnection = async () => {\n closeSocketConnection();\n\n const session = await Auth.currentSession();\n\n socket.main = await io(configs.apiUrl, {\n query: {\n token: session?.getIdToken().getJwtToken(),\n },\n transports: ['websocket'],\n reconnection: false,\n });\n\n if (!socket.main) {\n return;\n }\n\n socket.main.on('connect_error', async () => {\n await wait();\n await openSocketConnection();\n });\n\n socket.main.on('disconnect', async () => {\n await wait();\n if (!socket.main?.connected) {\n await openSocketConnection();\n }\n });\n\n socket.main.on('providerAlert', () => {\n store.dispatch(fetchUnhandledRequests());\n store.dispatch(fetchFeed());\n });\n};\n","import React from 'react';\nimport type { ChannelListMessengerProps } from 'stream-chat-react';\nimport './TeamChannelList.css';\nimport { Hidden, Typography } from '@material-ui/core';\nimport CustomLoading from '../../components/CustomLoading/CustomLoading';\n\nexport type TeamChannelListProps = ChannelListMessengerProps & {\n type: string;\n children?: React.ReactNode;\n};\n\nconst ChannelList: React.FC = (\n props: TeamChannelListProps\n) => {\n const { children, error = false, loading, type } = props;\n\n if (error) {\n return type === 'team' ? (\n
\n

\n Connection error, please wait a moment and try again.\n

\n
\n ) : null;\n }\n\n if (loading) {\n return ;\n }\n\n return (\n
\n
\n \n Channels\n \n \n \n CHANNELS\n \n \n
\n {children}\n
\n );\n};\n\nexport const TeamChannelList = React.memo(ChannelList);\n","import React, { useEffect } from 'react';\nimport { Channel } from 'stream-chat';\nimport moment from 'moment';\nimport {\n ChannelPreviewUIComponentProps,\n useChatContext,\n} from 'stream-chat-react';\nimport './TeamChannelPreview.css';\n\nimport type {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\n\ntype Props = ChannelPreviewUIComponentProps & {\n type: string;\n onChannelChange?: (channel: Channel, closeChannelList?: boolean) => void;\n};\n\nexport const TeamChannelPreview: React.FC = (props: Props) => {\n const { channel, setActiveChannel, onChannelChange } = props;\n\n const { data } = channel;\n const isFrozen = data?.frozen;\n const channelName = isFrozen ? `[disabled]${data?.name}` : data?.name;\n\n const { channel: activeChannel } = useChatContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n useEffect(() => {\n if (activeChannel && activeChannel.id === channel.id && onChannelChange) {\n onChannelChange(channel, false);\n }\n }, [activeChannel, channel, onChannelChange]);\n\n const channelLastMessage =\n channel.state.messages[channel.state.messages.length - 1];\n const renderMessageText = () => {\n if (!channelLastMessage) {\n return null;\n }\n const lastMessageAuthor = channelLastMessage?.user?.name;\n const lastMessageText = channelLastMessage?.text;\n\n const text = lastMessageText || 'message text';\n\n return (\n
\n
{lastMessageAuthor}:
\n
\n {text?.length < 60 ? lastMessageText : `${text.slice(0, 70)}...`}\n
\n
\n );\n };\n const renderMessageTime = () => {\n const lastMessageDate = moment(channelLastMessage?.created_at);\n const isMessageDateOnFeature = lastMessageDate.isAfter();\n const messageDate = isMessageDateOnFeature ? moment() : lastMessageDate;\n return channelLastMessage ? messageDate.fromNow() : '';\n };\n const selected = channel?.id === activeChannel?.id;\n return (\n {\n if (setActiveChannel) {\n setActiveChannel(channel);\n if (onChannelChange) {\n onChannelChange(channel);\n }\n }\n }}\n role=\"button\"\n onKeyDown={() => null}\n tabIndex={0}\n >\n \n
#
\n
\n
\n {channelName || 'Care Team'}\n {!!channel?.state.unreadCount && !selected && (\n
\n {channel?.state.unreadCount}\n
\n )}\n
\n
\n {renderMessageText()}\n
\n
\n {renderMessageTime()}\n
\n
\n \n \n );\n};\n","import React from 'react';\nimport { ChannelList, ChannelListProps } from 'stream-chat-react';\nimport type { Channel, ChannelFilters } from 'stream-chat';\nimport clsx from 'clsx';\nimport './ChannelListContainer.css';\nimport { TeamChannelList } from '../TeamChannelList/TeamChannelList';\nimport { TeamChannelPreview } from '../TeamChannelPreview/TeamChannelPreview';\n\ntype Props = Omit & {\n filters: ChannelFilters;\n className: string;\n onChannelChange?: (channel: Channel, closeChannelList?: boolean) => void;\n};\n\nconst customChannelTeamFilter = (channels: Channel[]) => {\n return channels.filter((channel) => channel.type === 'team');\n};\n\nexport const ChannelListContainer: React.FC = (props: Props) => {\n const { filters, options, sort, className, onChannelChange } = props;\n return (\n
\n
\n }\n Preview={(previewProps) => (\n \n )}\n />\n
\n
\n );\n};\n","import React from 'react';\nimport { Box, Link, makeStyles, Theme, Typography } from '@material-ui/core';\nimport { PhoneOutlined } from '@material-ui/icons';\nimport { phoneFormat } from '../utils/helpers';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n icon: {\n color: theme.palette.grey[400],\n },\n link: {\n '&:hover': {\n textDecoration: 'none',\n },\n },\n}));\n\ninterface ProviderMobileNumberProps {\n mobile?: string | null;\n}\n\nconst ProviderMobileNumber = (props: ProviderMobileNumberProps) => {\n const { mobile } = props;\n const classes = useStyles();\n\n if (!mobile) {\n return null;\n }\n\n return (\n \n \n \n \n \n \n \n {phoneFormat(mobile)}\n \n \n \n \n );\n};\n\nexport default ProviderMobileNumber;\n","import React from 'react';\nimport { Box, makeStyles, Typography } from '@material-ui/core';\nimport ProviderCardHeader from '../../components/ProviderCardHeader';\nimport ProviderLanguages from '../../components/ProviderCardLanguages';\nimport ProviderCardBio from '../../components/ProviderCardBio';\nimport { ProviderChatUserType } from '../types';\nimport ProviderMobileNumber from '../../components/ProviderMobileNumber';\n\nconst useStyles = makeStyles((theme) => ({\n contents: {\n [theme.breakpoints.up('sm')]: {\n display: 'flex',\n },\n [theme.breakpoints.down('sm')]: {\n display: 'block',\n },\n },\n providerInfoHeader: {\n [theme.breakpoints.up('sm')]: {\n position: 'relative',\n\n '& .MuiAvatar-root+div': {\n display: 'flex',\n\n '& .MuiBox-root': {\n margin: theme.spacing(0.5, 0.5),\n },\n },\n },\n [theme.breakpoints.down('sm')]: {\n display: 'flex',\n '&>div:first-child': {\n flexGrow: 1,\n },\n },\n },\n mentionName: {\n [theme.breakpoints.up('sm')]: {\n position: 'absolute',\n bottom: theme.spacing(0.5),\n left: theme.spacing(6),\n },\n },\n}));\n\ninterface ProviderInfoProps {\n provider: ProviderChatUserType;\n}\n\nconst ProviderInfo = (props: ProviderInfoProps) => {\n const classes = useStyles();\n const { provider } = props;\n\n return (\n \n \n \n \n\n \n \n {`@${provider.name}`}\n \n \n \n \n\n \n\n \n \n \n \n \n );\n};\n\nexport default ProviderInfo;\n","import React from 'react';\nimport { Box, Divider, makeStyles } from '@material-ui/core';\nimport { useSelector } from 'react-redux';\nimport { find } from 'lodash';\nimport ConfirmationDialogTemplate from '../../components/ConfirmationDialogTemplate';\nimport ProviderInfo from './ProviderInfo';\nimport { Provider } from '../../types/types';\nimport { RootState } from '../../redux/modules/rootReducer';\nimport { ProviderChatUserType } from '../types';\n\ninterface ChatMembersModalProps {\n isOpen: boolean;\n members?: ProviderChatUserType[];\n onClose: () => void;\n}\n\nconst useStyle = makeStyles((theme) => ({\n modalBodyWrapper: {\n width: 518,\n [theme.breakpoints.down('sm')]: {\n width: 280,\n },\n },\n}));\n\nconst enhanceProvider = (\n team: Provider[] | null,\n provider: ProviderChatUserType\n) => {\n if (!team) {\n return provider;\n }\n\n const fullProviderInfo = find(team, { id: provider.id });\n\n if (!fullProviderInfo) {\n return provider;\n }\n\n return {\n ...provider,\n attributes: fullProviderInfo.attributes,\n mobile: fullProviderInfo.mobile,\n };\n};\n\nconst ChatMembersModal: React.FC = (\n props: ChatMembersModalProps\n) => {\n const caseTeam = useSelector((state: RootState) => state.client.caseTeam);\n const { isOpen, members, onClose } = props;\n const classes = useStyle();\n\n if (!members || !members.length) {\n return null;\n }\n\n return (\n \n \n {members.map((provider, index) => {\n const isLast = members.length === index + 1;\n return (\n \n \n {!isLast && }\n \n );\n })}\n \n \n );\n};\n\nexport default ChatMembersModal;\n","import React, { useState } from 'react';\nimport { Avatar, Typography, Box } from '@material-ui/core';\nimport { AvatarGroup } from '@material-ui/lab';\nimport { useChannelStateContext } from 'stream-chat-react';\n\nimport './TeamChannelHeader.css';\nimport type {\n ProviderChatUserType,\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\nimport ChatMembersModal from './ChatMembersModal';\n\nexport const TeamChannelHeader: React.FC = () => {\n const { channel, members } = useChannelStateContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const [isModalOpen, setIsModalOpen] = useState(false);\n\n const teamHeader = `${\n channel?.data?.name || channel?.data?.id || 'Care team'\n }`;\n const memberList = members ? Object.values(members) : [];\n const profilePhotos = memberList.map((m) => m?.user?.profilePhoto || '');\n const numOfMembers = memberList.length;\n const memberProfiles = memberList\n .reduce((prev, current) => {\n if (current.user) {\n prev.push({\n id: current.user.attainProviderId || +current.user.id,\n name: current.user.name || '',\n firstName: current.user.firstName || current.user.name || '',\n lastName: current.user.lastName || '',\n title: current.user.title || '',\n covidVaccinatedDate: current.user.covidVaccinatedDate || '',\n attributes: current.user.attributes,\n profilePhoto: current.user.profilePhoto || '',\n chatUserId: current.user_id!,\n userType: current.user.userType,\n });\n }\n return prev;\n }, [])\n .sort((a, _) => {\n if (a.userType === 'clientUser') {\n return -1;\n }\n if (a.userType === 'provider') {\n return 1;\n }\n\n return 0;\n });\n\n return (\n <>\n
\n
\n {teamHeader}\n setIsModalOpen(true)}\n >\n \n {profilePhotos.map((photo, i) =>\n photo ? (\n \n ) : null\n )}\n \n \n {numOfMembers ? `${numOfMembers} members` : ''}\n \n \n
\n
\n\n setIsModalOpen(false)}\n />\n \n );\n};\n","import React from 'react';\n\ntype Props = {\n boldState: boolean;\n resetIconState: () => void;\n setBoldState: React.Dispatch>;\n};\n\nexport const BoldIcon = (props: Props) => {\n const { boldState, resetIconState, setBoldState } = props;\n\n return (\n {\n const bold = boldState;\n resetIconState();\n setBoldState(!bold);\n }}\n >\n \n \n \n \n );\n};\n","import React from 'react';\n\nexport const HashIcon = () => (\n \n \n \n \n);\nexport default HashIcon;\n","import React from 'react';\n\ntype Props = {\n italicState: boolean;\n resetIconState: () => void;\n setItalicState: React.Dispatch>;\n};\n\nexport const ItalicsIcon = (props: Props) => {\n const { italicState, resetIconState, setItalicState } = props;\n\n return (\n {\n const italic = italicState;\n resetIconState();\n setItalicState(!italic);\n }}\n >\n \n \n \n \n );\n};\n","import React from 'react';\n\nexport const LightningBoltSmall = () => (\n \n \n \n);\n","import React from 'react';\n\nexport const SendButton = () => (\n \n \n \n);\n","import React from 'react';\n\nexport const SmileyFace = (props: {\n openEmojiPicker: React.MouseEventHandler;\n}) => {\n const { openEmojiPicker } = props;\n\n return (\n
\n \n \n \n
\n );\n};\n","import React from 'react';\n\ntype Props = {\n resetIconState: () => void;\n setStrikeThroughState: React.Dispatch>;\n strikeThroughState: boolean;\n};\n\nexport const StrikeThroughIcon = (props: Props) => {\n const { resetIconState, strikeThroughState, setStrikeThroughState } = props;\n\n return (\n {\n const strikeThrough = strikeThroughState;\n resetIconState();\n setStrikeThroughState(!strikeThrough);\n }}\n >\n \n \n \n \n );\n};\n","import React, { useCallback, useContext } from 'react';\nimport {\n ChatAutoComplete,\n EmojiPicker,\n useMessageInputContext,\n} from 'stream-chat-react';\n\nimport { GiphyContext } from '../ChannelContainer/ChannelInner';\n\nimport './ThreadMessageInput.css';\n\nimport { Props } from './TeamMessageInput';\n\nimport { LightningBoltSmall, SendButton, SmileyFace } from '../chat-assets';\n\nimport type {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\n\nexport const ThreadMessageInput: React.FC = (props) => {\n const { giphyState, setGiphyState } = useContext(GiphyContext);\n\n const messageInput = useMessageInputContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const onChange: React.ChangeEventHandler = useCallback(\n (event) => {\n const deletePressed =\n event.nativeEvent instanceof InputEvent &&\n event.nativeEvent.inputType === 'deleteContentBackward'\n ? true\n : false;\n\n if (messageInput.text.length === 1 && deletePressed) {\n setGiphyState(false);\n }\n\n if (messageInput.text.startsWith('/giphy') && !giphyState) {\n event.target.value = event.target.value.replace('/giphy', '');\n setGiphyState(true);\n }\n\n messageInput.handleChange(event);\n },\n [giphyState, messageInput, setGiphyState]\n );\n\n const GiphyIcon = () => (\n
\n \n

GIPHY

\n
\n );\n\n return (\n
\n
\n {giphyState && }\n \n
\n \n
\n \n \n
\n
\n \n \n );\n};\n","import React, { useState } from 'react';\nimport moment from 'moment';\nimport { MessageResponse, logChatPromiseExecution } from 'stream-chat';\n\nimport {\n defaultPinPermissions,\n MessageList,\n MessageInput,\n PinEnabledUserRoles,\n Thread,\n useChannelActionContext,\n Window,\n MessageToSend,\n useChannelStateContext,\n} from 'stream-chat-react';\nimport { Alert } from '@material-ui/lab';\nimport configs from '../../configs';\n\nimport { TeamChannelHeader } from '../TeamChannelHeader/TeamChannelHeader';\nimport { ThreadMessageInput } from '../TeamMessageInput/ThreadMessageInput';\n\nimport type {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\nimport { DATE_FORMAT } from '../../utils/helpers';\n\ntype GiphyStateObj = {\n giphyState: boolean;\n setGiphyState: React.Dispatch>;\n};\n\nexport const GiphyContext = React.createContext(\n {} as GiphyStateObj\n);\n\nconst thirtyDaysAgo = moment()\n .subtract(+configs.chatHistoryDays, 'days')\n .format(DATE_FORMAT);\n\nexport const ChannelInner = () => {\n const [giphyState, setGiphyState] = useState(false);\n const { messages, channel, hasMore } = useChannelStateContext();\n\n const filteredMessages = messages?.filter((message) => {\n const messageDate = moment(message.created_at as Date).format(DATE_FORMAT);\n return messageDate >= thirtyDaysAgo;\n });\n\n let hasMoreToLoad = true;\n const [earliestMessage] = messages || [];\n const earliestMessageDate = moment(earliestMessage?.created_at).format(\n DATE_FORMAT\n );\n\n if (earliestMessageDate < thirtyDaysAgo || !hasMore) {\n hasMoreToLoad = false;\n }\n\n const giphyStateObj = {\n giphyState,\n setGiphyState,\n };\n\n const { sendMessage } = useChannelActionContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const teamPermissions: PinEnabledUserRoles = {\n ...defaultPinPermissions.team,\n user: true,\n };\n const messagingPermissions: PinEnabledUserRoles = {\n ...defaultPinPermissions.messaging,\n user: true,\n };\n const pinnedPermissions = {\n ...defaultPinPermissions,\n team: teamPermissions,\n messaging: messagingPermissions,\n };\n\n const overrideSubmitHandler = (message: MessageToSend) => {\n let updatedMessage = {\n attachments: message.attachments,\n mentioned_users: message.mentioned_users,\n parent_id: message.parent?.id,\n parent: message.parent as MessageResponse,\n text: message.text,\n };\n\n if (giphyState) {\n const updatedText = `/giphy ${message.text}`;\n updatedMessage = { ...updatedMessage, text: updatedText };\n }\n\n if (sendMessage) {\n const sendMessagePromise = sendMessage(updatedMessage);\n logChatPromiseExecution(sendMessagePromise, 'send message');\n setGiphyState(false);\n }\n };\n\n if (channel?.data?.frozen) {\n return (\n
\n \n This channel has been temporarily suspended. Please use the features\n available in Care for schedule updates, refer to the Help page or send\n a request through Contact Us for further assistance.\n \n
\n );\n }\n\n return (\n \n
\n \n \n \n \n \n \n
\n
\n );\n};\n","import React from 'react';\nimport { Avatar, useChatContext } from 'stream-chat-react';\n\nimport './ChannelEmptyState.css';\n\nimport { HashIcon } from '../chat-assets';\n\nimport type {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\n\nexport const ChannelEmptyState = () => {\n const { channel, client } = useChatContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const members = Object.values(channel?.state?.members || {}).filter(\n ({ user }) => user?.id !== client.userID\n );\n\n const getAvatarGroup = () => {\n if (!members.length) return ;\n\n return (\n
\n {members.map((member, i) => {\n if (i > 2) return null;\n return (\n \n );\n })}\n
\n );\n };\n\n const getUserText = () => {\n if (members.length === 1) {\n return (\n \n {`@${members[0].user?.name || members[0].user?.id}`}\n \n );\n }\n\n if (members.length === 2) {\n return (\n \n {`@${members[0].user?.name || members[0].user?.id} and @${\n members[1].user?.name || members[1].user?.id\n }`}\n \n );\n }\n\n let memberString = '';\n\n members.forEach((member, i) => {\n if (i !== members.length - 1) {\n memberString = `${memberString}@${\n member?.user?.name || member?.user?.id\n }, `;\n } else {\n memberString = `${memberString} and @${\n member?.user?.name || member?.user?.id\n }`;\n }\n });\n\n return (\n \n {memberString || 'the Universe'}\n \n );\n };\n\n return (\n
\n {channel?.type === 'team' ? : getAvatarGroup()}\n

\n This is the beginning of your chat history\n {channel?.type === 'team' ? ' in ' : ' with '}\n {channel?.type === 'team'\n ? `#${channel?.data?.name || channel?.data?.id}`\n : getUserText()}\n .\n

\n

\n Send messages, attachments, links, emojis, and more.\n

\n
\n );\n};\n","import React from 'react';\nimport {\n MessageUIComponentProps,\n useMessageContext,\n MessageSimple,\n} from 'stream-chat-react';\n\nimport './TeamMessage.css';\n\nexport const TeamMessage: React.FC = (props) => {\n const { message } = useMessageContext();\n\n return (\n
\n \n {/** potentially add replies component here */}\n
\n );\n};\n","import React from 'react';\nimport { useChatContext, useTypingContext } from 'stream-chat-react';\n\nimport './TeamTypingIndicator.css';\n\nimport type {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\n\nexport const TeamTypingIndicator: React.FC<{ type: string }> = (props: {\n type: string;\n}) => {\n const { type } = props;\n\n const { client } = useChatContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const { typing } = useTypingContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n if (!client || !typing) return null;\n // const a = 'true';\n if (type === 'list') {\n return (\n
\n
\n
\n
\n
\n
\n
\n );\n }\n\n const users = Object.values(typing)\n .filter(({ user }) => user?.id !== client.user?.id)\n .map(({ user }) => user?.name || user?.id);\n\n if (!users.length) return null;\n\n let text = 'Someone is typing';\n\n if (users.length === 1) {\n text = `${users[0]} is typing`;\n } else if (users.length === 2) {\n text = `${users[0]} and ${users[1]} are typing`;\n } else if (users.length > 2) {\n text = `${users[0]} and ${users.length - 1} more are typing`;\n }\n\n return (\n
\n
\n
\n
\n
\n
\n
{text}
\n
\n );\n};\n","import React, { useCallback, useContext, useState } from 'react';\nimport { FileUploadButton, ImageDropzone } from 'react-file-utils';\nimport {\n ChatAutoComplete,\n EmojiPicker,\n MessageInputProps,\n UploadsPreview,\n useChannelStateContext,\n useMessageInputContext,\n} from 'stream-chat-react';\n\nimport './TeamMessageInput.css';\n\nimport { TeamTypingIndicator } from '../TeamTypingIndicator/TeamTypeingIndicator';\n\nimport { GiphyContext } from '../ChannelContainer/ChannelInner';\n\nimport {\n BoldIcon,\n ItalicsIcon,\n LightningBoltSmall,\n SendButton,\n SmileyFace,\n StrikeThroughIcon,\n} from '../chat-assets';\n\nimport type {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\n\nexport type Props = MessageInputProps & {\n pinsOpen?: boolean;\n};\n\nexport const TeamMessageInput: React.FC = (props: Props) => {\n const { pinsOpen } = props;\n\n const { giphyState, setGiphyState } = useContext(GiphyContext);\n\n const {\n acceptedFiles,\n maxNumberOfFiles,\n multipleUploads,\n thread,\n } = useChannelStateContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const [boldState, setBoldState] = useState(false);\n const [codeState, setCodeState] = useState(false);\n const [italicState, setItalicState] = useState(false);\n const [strikeThroughState, setStrikeThroughState] = useState(false);\n\n const resetIconState = () => {\n setBoldState(false);\n setCodeState(false);\n setItalicState(false);\n setStrikeThroughState(false);\n };\n\n const messageInput = useMessageInputContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n\n const onChange: React.ChangeEventHandler = useCallback(\n (event) => {\n const { value } = event.target;\n\n const deletePressed =\n event.nativeEvent instanceof InputEvent &&\n event.nativeEvent.inputType === 'deleteContentBackward';\n\n if (messageInput.text.length === 1 && deletePressed) {\n setGiphyState(false);\n }\n\n if (\n !giphyState &&\n messageInput.text.startsWith('/giphy') &&\n !messageInput.numberOfUploads\n ) {\n event.target.value = value.replace('/giphy', '');\n setGiphyState(true);\n }\n\n if (boldState) {\n if (deletePressed) {\n event.target.value = `${value.slice(0, value.length - 2)}**`;\n } else {\n event.target.value = `**${value.replace(/\\**/g, '')}**`;\n }\n } else if (codeState) {\n if (deletePressed) {\n event.target.value = `${value.slice(0, value.length - 1)}\\``;\n } else {\n event.target.value = `\\`${value.replace(/`/g, '')}\\``;\n }\n } else if (italicState) {\n if (deletePressed) {\n event.target.value = `${value.slice(0, value.length - 1)}*`;\n } else {\n event.target.value = `*${value.replace(/\\*/g, '')}*`;\n }\n } else if (strikeThroughState) {\n if (deletePressed) {\n event.target.value = `${value.slice(0, value.length - 2)}~~`;\n } else {\n event.target.value = `~~${value.replace(/~~/g, '')}~~`;\n }\n }\n\n messageInput.handleChange(event);\n },\n [\n boldState,\n codeState,\n giphyState,\n italicState,\n messageInput,\n setGiphyState,\n strikeThroughState,\n ]\n );\n\n const GiphyIcon = () => (\n
\n \n

GIPHY

\n
\n );\n\n return (\n \n = maxNumberOfFiles) ||\n giphyState\n }\n >\n
\n
\n {giphyState && !messageInput.numberOfUploads && }\n \n \n
\n = maxNumberOfFiles) ||\n giphyState\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, { useEffect, useState } from 'react';\nimport { getWholeChar } from '../../utils/helpers';\nimport type { UserResponse } from 'stream-chat';\nimport type { TeamUserType } from '../types';\n\nfunction stringToColor(string: string) {\n let hash = 0;\n let i;\n\n /* eslint-disable no-bitwise */\n for (i = 0; i < string.length; i += 1) {\n hash = string.charCodeAt(i) + ((hash << 5) - hash);\n }\n\n let color = '#';\n\n for (i = 0; i < 3; i += 1) {\n const value = (hash >> (i * 8)) & 0xff;\n color += `00${value.toString(16)}`.substr(-2);\n }\n /* eslint-enable no-bitwise */\n\n return color;\n}\nexport type AvatarProps = {\n /** Image URL or default is an image of the first initial of the name if there is one */\n image?: string | null;\n /** Name of the image, used for title tag fallback */\n name?: string;\n /** click event handler */\n onClick?: (event: React.BaseSyntheticEvent) => void;\n /** mouseOver event handler */\n onMouseOver?: (event: React.BaseSyntheticEvent) => void;\n /** Shape of the avatar - circle, rounded or square\n * @default circle\n */\n shape?: 'circle' | 'rounded' | 'square';\n /** Size in pixels\n * @default 32px\n */\n size?: number;\n /** The entire user object for the chat user displayed in the component */\n user?: UserResponse;\n};\n\n/**\n * A round avatar image with fallback to username's first letter\n */\nexport const CustomAvatar = (props: AvatarProps) => {\n const {\n image,\n name,\n onClick = () => undefined,\n onMouseOver = () => undefined,\n shape = 'circle',\n size = 32,\n user,\n } = props;\n\n const [error, setError] = useState(false);\n const [loaded, setLoaded] = useState(false);\n\n const imageSrc = image || user?.profilePhoto;\n\n useEffect(() => {\n setError(false);\n setLoaded(false);\n }, [image]);\n\n const nameStr = name?.toString() || '';\n const initials = getWholeChar(nameStr, 0);\n\n return (\n \n {imageSrc && !error ? (\n setError(true)}\n onLoad={() => setLoaded(true)}\n src={imageSrc}\n style={{\n flexBasis: `${size}px`,\n height: `${size}px`,\n objectFit: 'cover',\n width: `${size}px`,\n }}\n />\n ) : (\n \n {initials}\n
\n )}\n
\n );\n};\n","import React, { useEffect } from 'react';\nimport { Channel, useChatContext } from 'stream-chat-react';\nimport { Box, Typography } from '@material-ui/core';\nimport clsx from 'clsx';\n\nimport './ChannelContainer.css';\nimport { ChannelInner } from './ChannelInner';\nimport { ChannelEmptyState } from '../ChannelEmptyState/ChannelEmptyState';\nimport { TeamMessage } from '../TeamMessage/TeamMessage';\nimport { TeamMessageInput } from '../TeamMessageInput/TeamMessageInput';\nimport {\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType,\n} from '../types';\nimport { CustomAvatar } from '../CustomAvatar/CustomAvatar';\n\ntype Props = {\n className: string;\n channelId?: string;\n};\n\nconst LoadingErrorIndicator = () => {\n return (\n \n \n You don't have a Team Chat channel yet. Please check back later.\n \n \n );\n};\n\nexport const ChannelContainer: React.FC = (props: Props) => {\n const { className, channelId } = props;\n const { client, setActiveChannel } = useChatContext<\n TeamAttachmentType,\n TeamChannelType,\n TeamCommandType,\n TeamEventType,\n TeamMessageType,\n TeamReactionType,\n TeamUserType\n >();\n useEffect(() => {\n const setChannel = async () => {\n if (channelId) {\n const [existingChannel] = await client.queryChannels({\n type: 'team',\n id: channelId,\n });\n setActiveChannel(existingChannel);\n }\n };\n setChannel();\n }, [channelId, client, setActiveChannel]);\n\n return (\n
\n }\n TypingIndicator={() => null}\n LoadingErrorIndicator={LoadingErrorIndicator}\n >\n \n \n
\n );\n};\n","import React, { useState } from 'react';\nimport { Channel, ChannelFilters, ChannelSort, StreamChat } from 'stream-chat';\nimport { Hidden, Typography } from '@material-ui/core';\nimport { KeyboardBackspace } from '@material-ui/icons';\nimport { Chat, CustomStyles } from 'stream-chat-react';\nimport 'stream-chat-react/dist/css/index.css';\nimport { ChannelListContainer } from './ChannelListContainer/ChannelListContainer';\nimport { ChannelContainer } from './ChannelContainer/ChannelContainer';\nimport './chat.css';\nimport StyledButtonLink from '../components/buttons/StyledButtonLink';\nimport AnalyticsTracker, { TrackerNames } from '../analytics/AnalyticsTracker';\n\nconst customStyles: CustomStyles = {\n '--main-font': 'Manrope\", \"Roboto\", \"Helvetica\", \"Arial\", sans-serif',\n '--second-font': 'Manrope\", \"Roboto\", \"Helvetica\", \"Arial\", sans-serif',\n};\n\nconst options = { state: true, watch: true, presence: true };\n// eslint-disable-next-line @typescript-eslint/camelcase\nconst sort = { last_message_at: -1, updated_at: -1 } as ChannelSort;\ntype AttainChatProps = {\n showChannels: boolean;\n chatClient: StreamChat;\n channelFilters: ChannelFilters;\n channelId?: string | null;\n isChannelListEmpty: boolean;\n onChannelChange?: (channel: Channel) => void;\n};\n\nconst AttainChat: React.FC = (props: AttainChatProps) => {\n const {\n chatClient,\n channelId,\n channelFilters,\n showChannels,\n isChannelListEmpty,\n onChannelChange,\n } = props;\n const [showChannelList, setShowChannelList] = useState(false);\n\n const handleChannelChange = (ch: Channel, closeChannelList = true) => {\n if (closeChannelList) {\n setShowChannelList(false);\n }\n\n if (onChannelChange) {\n onChannelChange(ch);\n }\n };\n\n if (isChannelListEmpty) {\n return (\n <>\n \n \n You don't have a Team Chat channel yet. Please check back later.\n \n \n );\n }\n\n return (\n <>\n \n {!showChannelList && showChannels && (\n
\n {\n setShowChannelList(true);\n }}\n startIcon={}\n >\n Team Chat\n \n
\n )}\n
\n \n
\n \n Team Chat connects clients to their care team. Type @name to send an\n alert to a specific person. Do not discuss health information in\n chat.\n \n {showChannels && (\n \n Contact Scheduling if your client's channel is missing.\n \n )}\n
\n
\n\n
\n \n \n {channelId && !showChannels ? (\n \n ) : (\n <>\n \n \n \n )}\n \n
\n \n );\n};\n\nexport default AttainChat;\n","import React, { Component, ErrorInfo, ReactNode } from 'react';\n\ninterface Props {\n children: ReactNode;\n}\n\ninterface State {\n hasError: boolean;\n}\n\nclass ErrorBoundary extends Component {\n constructor(props: Props) {\n super(props);\n this.state = {\n hasError: false,\n };\n }\n\n public static getDerivedStateFromError(_: Error): State {\n // Update state so the next render will show the fallback UI.\n return { hasError: true };\n }\n\n public componentDidCatch(error: Error, errorInfo: ErrorInfo) {\n console.error('Uncaught error:', error, errorInfo);\n }\n\n public render() {\n // eslint-disable-next-line react/destructuring-assignment\n if (this.state.hasError) {\n return

Sorry.. there was an error

;\n }\n\n // eslint-disable-next-line react/destructuring-assignment\n return this.props.children;\n }\n}\n\nexport default ErrorBoundary;\n","import requester from './requester';\n\nconst getToken = async (): Promise => {\n const url = `chat/token`;\n return requester\n .post(url, { headers: { 'Content-Type': 'application/json' } })\n .then((response) => response.text());\n};\n\nexport default {\n getToken,\n};\n","import { useCallback, useEffect, useState } from 'react';\nimport { useSelector } from 'react-redux';\nimport { StreamChat } from 'stream-chat';\nimport { RootState } from '../redux/modules/rootReducer';\nimport chatApi from '../api/chatApi';\nimport configs from '../configs';\nimport { useAppDispatch } from '../redux/store';\nimport {\n resetMessageCounts,\n setUnreadMessageCountPerClient,\n} from '../redux/modules/chat';\n\nconst getClientIdFromChannelId = (channelId: string) => {\n // example channel id - general_team_11111\n const clientId = channelId.split('_').pop() || '';\n return +clientId;\n};\n\nconst chatClient = StreamChat.getInstance(configs.chatToken);\nconst channelFilters = {\n type: 'team',\n};\nexport type ChatEventListener = { unsubscribe: () => void };\n\nexport default function useAttainChat() {\n const dispatch = useAppDispatch();\n const [channelId, setChannelId] = useState(null);\n const [isChannelListEmpty, setIsChannelListEmpty] = useState(true);\n\n const currentUser = useSelector(\n (state: RootState) => state.users.currentUser\n );\n const currentClient = useSelector(\n (state: RootState) => state.client.currentClient\n );\n const { id: providerId } =\n useSelector((state: RootState) => state.provider.provider) || {};\n\n const setClientUnreadCount = useCallback(\n (clientId: number, unreadCount: number) => {\n dispatch(\n setUnreadMessageCountPerClient({ id: clientId, count: unreadCount })\n );\n },\n [dispatch]\n );\n\n useEffect(() => {\n if (currentUser && currentClient && chatClient) {\n setChannelId(`general_team_${currentClient.id}`);\n }\n }, [currentUser, currentClient]);\n\n useEffect(() => {\n const listeners: ChatEventListener[] = [];\n\n const initChat = async () => {\n let id = '';\n if (currentUser) {\n id = String(`user_${currentUser.id}`);\n }\n if (providerId) {\n id = String(`provider_${providerId}`);\n }\n const tokenProvider = async () => {\n // make a request to your own backend to get the token\n try {\n return await chatApi.getToken();\n } catch (e: any) {\n console.log(e);\n }\n return '';\n };\n try {\n await chatClient.connectUser(\n {\n id,\n },\n tokenProvider\n );\n const channels = await chatClient.queryChannels(\n channelFilters,\n {},\n { watch: true }\n );\n\n setIsChannelListEmpty(channels.length === 0);\n\n channels.forEach((channel) => {\n if (!channel.id) {\n return;\n }\n\n const clientId = getClientIdFromChannelId(channel.id);\n setClientUnreadCount(clientId, channel.countUnread());\n\n const channelListener = channel.on((e) => {\n const messageRegex = new RegExp('message*|notification*');\n\n if (messageRegex.test(e.type)) {\n setClientUnreadCount(clientId, channel.countUnread());\n }\n });\n\n listeners.push(channelListener);\n });\n } catch (e: any) {\n console.log(e);\n }\n };\n if (currentUser || providerId) {\n console.log('Init chat ...');\n initChat();\n }\n return () => {\n dispatch(resetMessageCounts());\n listeners.forEach((l) => l.unsubscribe());\n chatClient.disconnectUser();\n };\n }, [currentUser, providerId, setClientUnreadCount, dispatch]);\n\n return {\n chatClient,\n channelId,\n channelFilters,\n isChannelListEmpty,\n };\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 fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M2.25 1.5C1.83579 1.5 1.5 1.83579 1.5 2.25V6.75C1.5 7.16421 1.16421 7.5 0.75 7.5C0.335786 7.5 0 7.16421 0 6.75V2.25C0 1.00736 1.00736 0 2.25 0H6.75C7.16421 0 7.5 0.335786 7.5 0.75C7.5 1.16421 7.16421 1.5 6.75 1.5H2.25ZM16.5 0.75C16.5 0.335786 16.8358 0 17.25 0H21.75C22.9926 0 24 1.00736 24 2.25V6.75C24 7.16421 23.6642 7.5 23.25 7.5C22.8358 7.5 22.5 7.16421 22.5 6.75V2.25C22.5 1.83579 22.1642 1.5 21.75 1.5H17.25C16.8358 1.5 16.5 1.16421 16.5 0.75ZM0.75 16.5C1.16421 16.5 1.5 16.8358 1.5 17.25V21.75C1.5 22.1642 1.83579 22.5 2.25 22.5H6.75C7.16421 22.5 7.5 22.8358 7.5 23.25C7.5 23.6642 7.16421 24 6.75 24H2.25C1.00736 24 0 22.9926 0 21.75V17.25C0 16.8358 0.335786 16.5 0.75 16.5ZM23.25 16.5C23.6642 16.5 24 16.8358 24 17.25V21.75C24 22.9926 22.9926 24 21.75 24H17.25C16.8358 24 16.5 23.6642 16.5 23.25C16.5 22.8358 16.8358 22.5 17.25 22.5H21.75C22.1642 22.5 22.5 22.1642 22.5 21.75V17.25C22.5 16.8358 22.8358 16.5 23.25 16.5Z\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M4.5 21C4.5 21 3 21 3 19.5C3 18 4.5 13.5 12 13.5C19.5 13.5 21 18 21 19.5C21 21 19.5 21 19.5 21H4.5Z\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M12 12C14.4853 12 16.5 9.98528 16.5 7.5C16.5 5.01472 14.4853 3 12 3C9.51472 3 7.5 5.01472 7.5 7.5C7.5 9.98528 9.51472 12 12 12Z\"\n});\n\nvar SvgPersonBoundingBox = function SvgPersonBoundingBox(_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: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"currentColor\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgPersonBoundingBox, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/person-bounding-box.9069edb2.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 fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M1.5 21C1.5 21 0 21 0 19.5C0 18 1.5 13.5 9 13.5C16.5 13.5 18 18 18 19.5C18 21 16.5 21 16.5 21H1.5Z\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M9 12C11.4853 12 13.5 9.98528 13.5 7.5C13.5 5.01472 11.4853 3 9 3C6.51472 3 4.5 5.01472 4.5 7.5C4.5 9.98528 6.51472 12 9 12Z\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M19.5 14.25C19.5 13.8358 19.8358 13.5 20.25 13.5H23.25C23.6642 13.5 24 13.8358 24 14.25C24 14.6642 23.6642 15 23.25 15H20.25C19.8358 15 19.5 14.6642 19.5 14.25Z\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M16.5 9.75C16.5 9.33579 16.8358 9 17.25 9H23.25C23.6642 9 24 9.33579 24 9.75C24 10.1642 23.6642 10.5 23.25 10.5H17.25C16.8358 10.5 16.5 10.1642 16.5 9.75Z\"\n});\n\nvar _ref6 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M16.5 5.25C16.5 4.83579 16.8358 4.5 17.25 4.5H23.25C23.6642 4.5 24 4.83579 24 5.25C24 5.66421 23.6642 6 23.25 6H17.25C16.8358 6 16.5 5.66421 16.5 5.25Z\"\n});\n\nvar _ref7 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M19.5 18.75C19.5 18.3358 19.8358 18 20.25 18H23.25C23.6642 18 24 18.3358 24 18.75C24 19.1642 23.6642 19.5 23.25 19.5H20.25C19.8358 19.5 19.5 19.1642 19.5 18.75Z\"\n});\n\nvar SvgPersonLinesFill = function SvgPersonLinesFill(_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: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"currentColor\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5, _ref6, _ref7);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgPersonLinesFill, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/person-lines-fill.79583e03.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(\"g\", {\n clipPath: \"url(#clip0_24129_358180)\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n x: 1,\n y: 10,\n width: 4,\n height: 6,\n fill: \"#818181\"\n}), /*#__PURE__*/React.createElement(\"rect\", {\n x: 7,\n y: 7,\n width: 4,\n height: 9,\n fill: \"#818181\"\n}), /*#__PURE__*/React.createElement(\"rect\", {\n x: 13,\n y: 4,\n width: 4,\n height: 12,\n fill: \"#818181\"\n}), /*#__PURE__*/React.createElement(\"rect\", {\n x: 19,\n width: 4,\n height: 16,\n fill: \"#818181\"\n}), /*#__PURE__*/React.createElement(\"rect\", {\n y: 17,\n width: 24,\n height: 2,\n fill: \"#818181\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_24129_358180\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 24,\n height: 19,\n fill: \"white\"\n})));\n\nvar SvgClimbIcon = function SvgClimbIcon(_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: 24,\n height: 19,\n viewBox: \"0 0 24 19\",\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(SvgClimbIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/climb_icon.b7bd17b4.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: \"M7 14V16H10.61C10.74 15.29 10.97 14.62 11.29 14H7Z\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M10.68 19H5V8H19V10.1C19.71 10.22 20.38 10.43 21 10.73V4.99C21 3.89 20.1 2.99 19 2.99H18V1H16V3H8V1H6V3H5C3.89 3 3.01 3.9 3.01 5V19C3 20.1 3.89 21 5 21H11.48C11.12 20.38 10.85 19.71 10.69 19H10.68Z\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M7 12H12.79C13.92 10.94 15.38 10.23 17 10.05V10H7V12Z\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M23.62 17.33C23.62 20.54 21.02 23.14 17.81 23.14C14.6 23.14 12 20.54 12 17.33C12 14.12 14.6 11.52 17.81 11.52C21.02 11.52 23.62 14.12 23.62 17.33ZM19.54 19.66L20.2 18.75C20.29 18.62 20.27 18.45 20.14 18.36L18.65 17.28V14.05C18.65 13.9 18.52 13.77 18.37 13.77H17.25C17.1 13.77 16.97 13.9 16.97 14.05V17.99C16.97 18.08 17.01 18.16 17.09 18.22L19.16 19.72C19.29 19.81 19.46 19.78 19.55 19.66H19.54Z\"\n});\n\nvar SvgMyScheduleIcon = function SvgMyScheduleIcon(_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: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"currentColor\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgMyScheduleIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/my-schedule-icon.c9c42fe3.svg\";\nexport { ForwardRef as ReactComponent };","import React, { useEffect } from 'react';\nimport {\n ListSubheader,\n Box,\n Typography,\n Hidden,\n Divider,\n List,\n ListItem,\n ListItemIcon,\n ListItemText,\n Badge,\n} from '@material-ui/core';\n\nimport { makeStyles, Theme, createStyles } from '@material-ui/core/styles';\nimport { Link } from 'react-router-dom';\nimport { useLocation, useNavigate } from 'react-router';\nimport {\n HomeOutlined as HomeOutlinedIcon,\n AddBoxOutlined as AddBoxOutlinedIcon,\n ExitToApp as ExitToAppIcon,\n HelpOutline as HelpOutlineIcon,\n DescriptionOutlined as DescriptionOutlinedIcon,\n ChatBubbleOutlineOutlined as ChatBubbleIcon,\n NotificationsNone as AlertIcon,\n SettingsOutlined as SettingsIcon,\n DateRangeOutlined as AvailabilityIcon,\n AccountCircle as UserMyProfileIcon,\n MailOutline as MailOutlineIcon,\n DateRange as DateRangeOutlinedIcon,\n InsertInvitationOutlined as StandardIcon,\n EventBusy as CancelIcon,\n} from '@material-ui/icons';\nimport 'moment-timezone';\n\nimport { useDispatch, useSelector } from 'react-redux';\nimport clsx from 'clsx';\nimport { ReactComponent as ProfileIcon } from '../assets/person-bounding-box.svg';\nimport { ReactComponent as ProvidersIcon } from '../assets/person-lines-fill.svg';\nimport { ReactComponent as ClimbIcon } from '../assets/climb_icon.svg';\nimport { ReactComponent as ScheduleIcon } from '../assets/my-schedule-icon.svg';\nimport { Resources } from '../accessControl/acl';\nimport usePermission from '../hooks/usePermission';\nimport { RootState } from '../redux/modules/rootReducer';\nimport { fetchUnhandledRequests } from '../redux/modules/requests';\nimport { isBT } from '../utils/helpers';\nimport { PageMode } from '../commonPages/MySchedule/types/types';\n\nconst drawerWidth = 240;\n\nconst useStyles = makeStyles((theme: Theme) => {\n return createStyles({\n drawerToolbar: {\n width: drawerWidth,\n background: theme.palette.grey[100],\n height: '100%',\n [theme.breakpoints.up('lg')]: {\n borderTopRightRadius: theme.spacing(2),\n },\n },\n toolbar: {\n minHeight: theme.spacing(20),\n [theme.breakpoints.down('md')]: {\n paddingTop: theme.spacing(3.5),\n minHeight: theme.spacing(11.5),\n justifyContent: 'space-between',\n },\n justifyContent: 'space-around',\n },\n listSubHeaderRoot: {\n /* To change the font, use the fontFamily rule */\n color: theme.palette.text.secondary,\n fontWeight: theme.typography.overline.fontWeight,\n fontSize: theme.typography.pxToRem(10),\n },\n addTimeBox: {\n backgroundColor: '#e8e8e8',\n padding: theme.spacing(1.25, 0),\n },\n addTimeText: {\n padding: theme.spacing(2),\n paddingTop: theme.spacing(1),\n letterSpacing: '0.1em',\n textTransform: 'uppercase',\n },\n scheduleBox: {\n padding: theme.spacing(1.25, 0),\n },\n scheduleText: {\n padding: theme.spacing(0, 0, 1, 2),\n letterSpacing: '0.1em',\n textTransform: 'uppercase',\n },\n scheduleHr: {\n width: '96%',\n backgroundColor: theme.palette.kyoBlue1.main,\n },\n scheduleTitle: {\n fontSize: 14,\n fontWeight: 600,\n },\n scheduleItemText: {\n margin: 0,\n },\n });\n});\ninterface Props {\n signOut: () => void;\n setIsDrawerOpen: React.Dispatch>;\n isDrawerOpen: boolean;\n}\n\nconst DrawerItemsList: React.FC = (props: Props) => {\n const { setIsDrawerOpen, signOut } = props;\n const classes = useStyles();\n const dispatch = useDispatch();\n const checkPermission = usePermission();\n const navigate = useNavigate();\n const clientRoutesAccess = checkPermission(Resources.clientRoutes);\n const providerRoutesAccess = checkPermission(Resources.providerRoutes);\n const menteeProviders = useSelector(\n (state: RootState) => state.menteeProviders.menteeProviders\n );\n const unhandledRequestCount = useSelector(\n (state: RootState) => state.requests.unhandledRequestsCount\n );\n\n const currentProvider = useSelector(\n (state: RootState) => state.provider.provider\n );\n\n const isShowClimb = isBT(currentProvider);\n\n useEffect(() => {\n if (providerRoutesAccess) {\n dispatch(fetchUnhandledRequests());\n }\n }, [providerRoutesAccess, dispatch]);\n\n return (\n <>\n \n
\n \n
\n \n \n \n \n MY KYO\n \n }\n >\n \n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n \n \n } />\n \n\n {providerRoutesAccess && (\n <>\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n
\n \n Add Time\n \n \n \n \n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n \n
\n \n )}\n\n {providerRoutesAccess && (\n
\n \n Manage Schedule\n \n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.schedule}`);\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.remove}`);\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.temporary}`);\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.standard}`);\n setIsDrawerOpen(false);\n }}\n />\n
\n )}\n {clientRoutesAccess && (\n
\n \n Manage Schedule\n \n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.schedule}`);\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.remove}`);\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.temporary}`);\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n navigate(`/schedule?page-mode=${PageMode.standard}`);\n setIsDrawerOpen(false);\n }}\n />\n
\n )}\n {clientRoutesAccess && (\n <>\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n \n )}\n {providerRoutesAccess && (\n <>\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n \n )}\n {clientRoutesAccess && (\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n )}\n {isShowClimb && (\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n )}\n {!!menteeProviders.length && (\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n )}\n \n \n \n {(clientRoutesAccess || providerRoutesAccess) && (\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n )}\n {clientRoutesAccess && (\n <>\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n \n )}\n {clientRoutesAccess && (\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n )}\n }\n onClick={() => {\n setIsDrawerOpen(false);\n }}\n />\n }\n onClick={() => {\n setIsDrawerOpen(false);\n signOut();\n }}\n />\n \n
\n \n );\n};\n\ninterface DrawerItemProps {\n to?: string;\n title: string;\n icon: JSX.Element;\n onClick?: () => void;\n}\n\nconst useDrawerItemStyles = makeStyles((theme: Theme) => ({\n selectedItem: {\n backgroundColor: '#C5DCFA',\n borderTopRightRadius: 12,\n borderBottomRightRadius: 12,\n color: theme.palette.kyoBlue1.dark,\n '&:hover': {\n backgroundColor: '#C5DCFA',\n },\n },\n unselectedItem: {\n backgroundColor: 'unset',\n color: theme.palette.kyoGray63.dark,\n '&:hover': {\n borderTopRightRadius: 12,\n borderBottomRightRadius: 12,\n },\n },\n icon: { display: 'flex' },\n selectedIcon: {\n color: theme.palette.kyoBlue1.dark,\n },\n unselectedIcon: { color: 'unset' },\n title: {\n fontSize: 14,\n },\n}));\n\nconst DrawerItem: React.FC = (props: DrawerItemProps) => {\n const classes = useDrawerItemStyles();\n const location = useLocation();\n const { to, title, icon, onClick } = props;\n\n const { pathname, search } = location;\n const isActiveRoute = to === location.pathname || to === pathname + search;\n\n return (\n \n \n \n {icon}\n
\n \n \n {title}\n \n }\n />\n \n );\n};\n\nexport default DrawerItemsList;\n","import React from 'react';\nimport { Popper, PopperProps, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\nconst ARROW_SIZE = 12;\n\nconst useStyles = makeStyles((theme: Theme) => ({\n styledPopper: {\n zIndex: theme.zIndex.drawer + 1,\n position: 'relative',\n backgroundColor: theme.palette.grey[50],\n borderRadius: theme.shape.borderRadius * 2,\n '&$bottom': {\n marginTop: ARROW_SIZE,\n },\n '&$up': {\n marginBottom: ARROW_SIZE,\n },\n '&$left': {\n marginRight: ARROW_SIZE,\n },\n '&$right': {\n marginLeft: ARROW_SIZE,\n },\n },\n arrow: {\n position: 'absolute',\n borderWidth: ARROW_SIZE,\n borderColor: 'transparent',\n borderStyle: 'solid',\n zIndex: 1,\n '&$bottom': {\n borderLeftColor: theme.palette.grey[50],\n top: -ARROW_SIZE,\n marginLeft: ARROW_SIZE * 2,\n },\n '&$up': {\n borderLeftColor: theme.palette.grey[50],\n bottom: -ARROW_SIZE,\n marginLeft: ARROW_SIZE * 2,\n },\n '&$left': {\n borderTopColor: theme.palette.grey[50],\n right: -ARROW_SIZE,\n marginTop: ARROW_SIZE * 2,\n },\n '&$right': {\n borderTopColor: theme.palette.grey[50],\n left: -ARROW_SIZE,\n marginTop: ARROW_SIZE * 2,\n },\n },\n bottom: {},\n up: {},\n left: {},\n right: {},\n}));\n\ninterface StyledPopperProps extends PopperProps {\n hideArrow?: boolean;\n}\n\nconst StyledPopper = (props: StyledPopperProps) => {\n const { children, className, placement = 'bottom-end', hideArrow } = props;\n const classes = useStyles();\n\n const placementDirection = placement.split('-')[0] as\n | 'bottom'\n | 'up'\n | 'left'\n | 'right';\n\n return (\n \n {!hideArrow && (\n \n )}\n {children}\n \n );\n};\n\nexport default StyledPopper;\n","import React from 'react';\nimport { useDispatch, useSelector } from 'react-redux';\nimport { useNavigate } from 'react-router';\nimport { Box, Typography, makeStyles, Theme, SvgIcon } from '@material-ui/core';\nimport {\n VisibilityOffOutlined,\n VisibilityOutlined,\n Visibility,\n} from '@material-ui/icons';\nimport clsx from 'clsx';\n\nimport { RootState } from '../redux/modules/rootReducer';\nimport { fetchCurrentClientById } from '../redux/modules/client';\nimport StyledButton from './buttons/StyledButton';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n button: {\n backgroundColor: '#fff',\n color: theme.palette.kyoTeal.main,\n borderColor: theme.palette.kyoTeal.main,\n borderWidth: 1,\n borderStyle: 'solid',\n width: '100%',\n margin: theme.spacing(0.5, 0),\n position: 'relative',\n paddingRight: 50,\n },\n withBadge: {\n '&::after': {\n content: '\"\"',\n display: 'block',\n width: theme.spacing(1.5),\n height: theme.spacing(1.5),\n borderRadius: '50%',\n backgroundColor: '#f44336',\n position: 'absolute',\n top: theme.spacing(-0.75),\n right: theme.spacing(-0.75),\n },\n },\n icon: {\n position: 'absolute',\n right: 0,\n marginRight: 10,\n marginLeft: 10,\n },\n clientListContainer: {\n padding: theme.spacing(0.1, 0.6),\n maxHeight: 270,\n overflowY: 'auto',\n overflowX: 'hidden',\n },\n}));\n\ninterface ClientSelectionComponentProps {\n onAction: Function;\n}\n\nconst ClientSelectionComponent = (props: ClientSelectionComponentProps) => {\n const dispatch = useDispatch();\n const navigate = useNavigate();\n const classes = useStyles();\n\n const { onAction } = props;\n\n const currentUser = useSelector(\n (state: RootState) => state.users.currentUser\n );\n const currentClient = useSelector(\n (state: RootState) => state.client.currentClient\n );\n\n const unreadMessagesCountPerClient = useSelector(\n (state: RootState) => state.chat.unreadMessagesCountPerClient\n );\n\n const handleSelect = (clientId: number) => {\n dispatch(fetchCurrentClientById(clientId));\n };\n\n const handleVerify = (clientId: number) => {\n navigate(`/verify-client/${clientId}`);\n };\n\n const validAssociations = currentUser\n ? currentUser.associations.filter((assoc) => !assoc.dateRevoked)\n : [];\n\n if (!currentUser || validAssociations.length === 0) {\n return (\n \n No clients to show\n \n );\n }\n\n return (\n \n {validAssociations.map((assoc) => {\n const isVerified = !!assoc.dateVerified;\n const isSelectedClient = +assoc.clientId === currentClient?.id;\n const hasUnreadMessage = unreadMessagesCountPerClient[assoc.clientId];\n\n const icon = (\n \n {!isVerified && }\n {isVerified && isSelectedClient ? (\n \n ) : (\n \n )}\n \n );\n\n return (\n {\n if (!isSelectedClient) {\n if (!isVerified) {\n handleVerify(+assoc.clientId);\n } else if (!isSelectedClient) {\n handleSelect(+assoc.clientId);\n }\n }\n onAction();\n }}\n >\n <>\n {assoc.client ? assoc.client.name : assoc.clientId}\n {icon}\n \n \n );\n })}\n \n );\n};\n\nexport default ClientSelectionComponent;\n","import React, { useState } from 'react';\nimport { useSelector } from 'react-redux';\nimport { Box, Typography, makeStyles, Theme } from '@material-ui/core';\nimport { ArrowRightAlt } from '@material-ui/icons';\n\nimport { RootState } from '../redux/modules/rootReducer';\nimport StyledButton from './buttons/StyledButton';\nimport ConfirmationDialogTemplate from './ConfirmationDialogTemplate';\nimport ProviderCell from './table/ProviderCell';\nimport configs from '../configs';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n button: {\n width: '100%',\n },\n dialogContent: {\n padding: theme.spacing(1),\n overflow: 'hidden',\n },\n providerCellContainer: {\n marginTop: theme.spacing(1),\n padding: theme.spacing(1),\n backgroundColor: theme.palette.grey[100],\n borderRadius: 16,\n width: '80%',\n minWidth: 280,\n },\n}));\n\ninterface ProviderRoleSelectionComponentProps {\n onAction?: () => any;\n}\n\nconst ProviderRoleSelectionComponent = (\n props: ProviderRoleSelectionComponentProps\n) => {\n const classes = useStyles();\n const { onAction } = props;\n\n const [dialogOpen, setDialogOpen] = useState(false);\n\n const currentProvider = useSelector(\n (state: RootState) => state.provider.provider\n );\n\n const redirectToOldUI = () => {\n window.open(configs.oldUIUrl, '_blank');\n };\n\n return (\n \n {\n setDialogOpen(true);\n }}\n customColor=\"kyoTeal\"\n >\n Switch Role\n \n {\n setDialogOpen(false);\n if (onAction) {\n onAction();\n }\n }}\n actions={\n <>\n }\n customColor=\"kyoLightGreen\"\n onClick={() => {\n redirectToOldUI();\n }}\n >\n Switch to Scheduler\n \n \n }\n >\n \n \n You are logged in as a Provider. Switch to the Scheduler portal for\n Scheduling, RD/Con, or other role functions.\n \n {currentProvider && (\n \n \n \n )}\n \n \n \n );\n};\n\nexport default ProviderRoleSelectionComponent;\n","import { useAuth } from './useAuth';\n\nconst useGroups = () => {\n const { user } = useAuth();\n\n const groups = user?.getSignInUserSession()?.getIdToken().payload[\n 'cognito:groups'\n ];\n\n if(!groups) {\n return [];\n }\n\n return groups;\n};\n\nexport default useGroups;","import React from 'react';\nimport { Box, Typography, Divider, makeStyles, Theme } from '@material-ui/core';\nimport { useNavigate } from 'react-router-dom';\n\nimport StyledButton from './buttons/StyledButton';\nimport DividerText from './DividerText/DividerText';\nimport { useAuth } from '../hooks/useAuth';\nimport ClientSelectionComponent from './ClientSelectionComponent';\nimport usePermission from '../hooks/usePermission';\nimport { Resources, Role } from '../accessControl/acl';\nimport ProviderRoleSelectionComponent from './ProviderRoleSelectionComponent';\nimport useGroups from '../hooks/useGroups';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n popupMenu: {\n width: 260,\n padding: theme.spacing(1, 2),\n color: theme.palette.common.black,\n },\n button: {\n width: '100%',\n margin: theme.spacing(1, 0),\n height: theme.spacing(5),\n },\n divider: {\n margin: theme.spacing(1, 0),\n },\n}));\n\ninterface PopupMenuProps {\n closePopup: Function;\n}\n\nconst rolesAllowedToSwitch = [\n Role['CLIN-BCBA'],\n Role['CLIN-RD/Con'],\n Role['HR/CRED/CS'],\n Role.CS,\n Role.SCH,\n Role.UserMgr,\n Role.admin,\n];\n\nconst PopupMenu = (props: PopupMenuProps) => {\n const { closePopup } = props;\n const classes = useStyles();\n const navigate = useNavigate();\n const { signOut } = useAuth();\n const checkPermission = usePermission();\n\n const clientRoutesAccess = checkPermission(Resources.clientRoutes);\n const providerRoutesAccess = checkPermission(Resources.providerRoutes);\n const userGroups = useGroups();\n\n const switchRoleAccess = rolesAllowedToSwitch.some((role) =>\n userGroups?.includes(role)\n );\n\n return (\n \n {\n navigate(clientRoutesAccess ? '/user-profile' : '/my-profile');\n closePopup();\n }}\n >\n {clientRoutesAccess ? 'User' : 'My'} Profile\n \n\n {clientRoutesAccess && (\n <>\n \n Clients\n \n {\n closePopup();\n }}\n />\n \n )}\n\n \n\n {providerRoutesAccess && switchRoleAccess && (\n {\n closePopup();\n }}\n />\n )}\n\n {\n signOut();\n closePopup();\n }}\n >\n Sign out\n \n \n );\n};\n\nexport default PopupMenu;\n","import React from 'react';\nimport {\n ClickAwayListener,\n IconButton,\n Avatar,\n Backdrop,\n Box,\n} from '@material-ui/core';\n\nimport StyledPopper from './StyledPopper/StyledPopper';\nimport PopupMenu from './PopupMenu';\n\ninterface AvatarIconMenuProps {\n avatarSrc?: string;\n onClick?: Function;\n}\n\nconst AvatarIconMenu = (props: AvatarIconMenuProps) => {\n const { avatarSrc, onClick } = props;\n const [\n popupMenuAnchor,\n setPopupMenuAnchor,\n ] = React.useState(null);\n\n return (\n <>\n {\n setPopupMenuAnchor(null);\n }}\n >\n \n ) => {\n setPopupMenuAnchor((curr) => (curr ? null : e.currentTarget));\n if (onClick) {\n onClick();\n }\n }}\n >\n \n \n\n \n {\n setPopupMenuAnchor(null);\n }}\n />\n \n \n \n \n \n );\n};\n\nexport default AvatarIconMenu;\n","import React from 'react';\nimport { useSelector } from 'react-redux';\nimport { useNavigate } from 'react-router-dom';\nimport {\n IconButton,\n makeStyles,\n Theme,\n Badge,\n Tooltip,\n} from '@material-ui/core';\nimport { ChatBubbleOutline } from '@material-ui/icons';\n\nimport { selectTotalUnreadCount } from '../redux/modules/chat';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n position: 'relative',\n },\n chatIcon: {\n color: theme.palette.common.black,\n },\n}));\n\nfunction notificationsLabel(count: number) {\n if (count === 0) {\n return 'no notifications';\n }\n if (count > 99) {\n return 'more than 99 notifications';\n }\n return `${count} notifications`;\n}\n\nconst ChatIconHeader = () => {\n const classes = useStyles();\n const navigate = useNavigate();\n\n const unreadMessagesCount = useSelector(selectTotalUnreadCount);\n\n return (\n
\n
\n \n navigate('/chat')}\n aria-label={notificationsLabel(100)}\n >\n \n \n \n \n \n
\n
\n );\n};\n\nexport default ChatIconHeader;\n","import React from 'react';\nimport {\n Container,\n useMediaQuery,\n AppBar,\n Toolbar,\n IconButton,\n} from '@material-ui/core';\nimport { makeStyles, Theme, createStyles } from '@material-ui/core/styles';\nimport { Link } from 'react-router-dom';\nimport { Menu as MenuIcon, Close as CloseIcon } from '@material-ui/icons';\nimport 'moment-timezone';\n\nimport { useAuth } from '../hooks/useAuth';\nimport logo from '../assets/Kyo-care-logo.svg';\nimport rectangles from '../assets/kyo_rectangles.svg';\nimport AvatarIconMenu from './AvatarIconMenu';\nimport useMaintenanceCheck from '../hooks/useMaintenanceCheck';\nimport ChatIconHeader from './ChatIconHeader';\n\nconst useStyles = makeStyles((theme: Theme) => {\n return createStyles({\n appBar: {\n background: theme.palette.common.white,\n [theme.breakpoints.down('md')]: {\n borderBottomStyle: 'solid',\n borderBottomWidth: 1,\n borderBottomColor: theme.palette.grey[300],\n },\n },\n appBarZIndex: {\n zIndex: theme.zIndex.drawer + 1,\n },\n grey: {\n [theme.breakpoints.down('md')]: {\n background: theme.palette.grey[100],\n },\n },\n menuButton: {\n color: theme.palette.common.black,\n [theme.breakpoints.up('lg')]: {\n display: 'none',\n },\n },\n toolbar: {\n minHeight: theme.spacing(20),\n [theme.breakpoints.down('md')]: {\n paddingTop: theme.spacing(3.5),\n minHeight: theme.spacing(11.5),\n justifyContent: 'space-between',\n },\n justifyContent: 'space-around',\n },\n logo: {\n width: theme.spacing(23),\n [theme.breakpoints.down('md')]: {\n width: theme.spacing(12.5),\n },\n },\n rectangles: {\n paddingLeft: theme.spacing(2),\n width: theme.spacing(86),\n height: theme.spacing(16),\n [theme.breakpoints.down('md')]: {\n display: 'none',\n },\n },\n navBarControls: {\n display: 'flex',\n alignItems: 'center',\n },\n });\n});\n\ninterface Props {\n setIsDrawerOpen: React.Dispatch>;\n isDrawerOpen: boolean;\n}\n\nconst AppHeader: React.FC = (props: Props) => {\n const { isDrawerOpen, setIsDrawerOpen } = props;\n const classes = useStyles();\n const { isAuthenticated, user } = useAuth();\n const { maintenanceStatusOn } = useMaintenanceCheck();\n\n const isMobile = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('lg')\n );\n\n const idTokenPayload = user?.getSignInUserSession()?.getIdToken()?.payload;\n\n return (\n \n \n \n \n \"logo\"\n \n \n {isAuthenticated && !maintenanceStatusOn && (\n
\n \n {\n setIsDrawerOpen(false);\n }}\n />\n {\n setIsDrawerOpen((prevState) => !prevState);\n }}\n className={classes.menuButton}\n >\n {isDrawerOpen ? : }\n \n
\n )}\n
\n
\n \n );\n};\n\nexport default AppHeader;\n","import { useEffect, useState } from 'react';\nimport fetchIntercept from 'fetch-intercept';\nimport { getVersion } from '../api/versionApi';\nimport configs from '../configs';\n\nconst useApiVersionCheck = () => {\n const [version, setVersion] = useState();\n\n useEffect(() => {\n getVersion()\n .then((data) => {\n setVersion(data.version);\n })\n .catch((err) => console.log(err));\n }, []);\n\n useEffect(() => {\n if (!version) {\n return;\n }\n\n fetchIntercept.register({\n response: (response) => {\n if (!response.url.includes(configs.apiUrl)) {\n return response;\n }\n\n if (response.headers.get('x-api-version') !== version) {\n window.location.reload();\n }\n\n return response;\n },\n });\n }, [version]);\n};\n\nexport default useApiVersionCheck;\n","import requester from './requester';\n\nexport const getVersion = () => {\n return requester.get(`api-version`).then((response) => response.json());\n};\n","import * as React from 'react';\nimport Alert from '@material-ui/lab/Alert';\nimport Snackbar from '@material-ui/core/Snackbar';\nimport { useSelector } from 'react-redux';\nimport { useEffect, useState } from 'react';\nimport { RootState } from '../../redux/modules/rootReducer';\nimport { AlertMessage } from '../../redux/modules/alert';\n\nconst AppErrors = () => {\n const alertMessage: AlertMessage = useSelector(\n (state: RootState) => state.alert.alertMessage\n );\n const [visible, setVisible] = useState(false);\n\n useEffect(() => {\n if (typeof alertMessage !== undefined) {\n setVisible(true);\n } else {\n setVisible(false);\n }\n }, [alertMessage]);\n\n if (!alertMessage) {\n return null;\n }\n return (\n setVisible(false)}\n open={visible}\n >\n {alertMessage.message}\n \n );\n};\n\nexport default AppErrors;\n","import { useCallback } from 'react';\n\nconst PROVIDER_PREVIOUS_PATH_KEY = 'providerPreviousPath';\n\nconst getPreviousPathByRoutesAccess = (\n providerRoutesAccess: boolean\n): string | undefined => {\n const providerPreviousPath = sessionStorage.getItem(\n PROVIDER_PREVIOUS_PATH_KEY\n );\n if (providerRoutesAccess && providerPreviousPath) {\n return providerPreviousPath;\n }\n\n return undefined;\n};\n\nconst setPreviousPathByRoutesAccess = (\n providerRoutesAccess: boolean,\n currentPath: string\n): void => {\n if (providerRoutesAccess) {\n sessionStorage.setItem(PROVIDER_PREVIOUS_PATH_KEY, currentPath);\n }\n};\n\nconst usePreviousPathByRoutesAccess = (providerRoutesAccess: boolean) => {\n const previousPath = getPreviousPathByRoutesAccess(providerRoutesAccess);\n\n const removePreviousPath = useCallback(() => {\n sessionStorage.removeItem(PROVIDER_PREVIOUS_PATH_KEY);\n }, []);\n\n const setPreviousPath = (currentPath: string) => {\n setPreviousPathByRoutesAccess(providerRoutesAccess, currentPath);\n };\n\n return {\n previousPath,\n setPreviousPath,\n removePreviousPath,\n };\n};\n\nexport default usePreviousPathByRoutesAccess;\n","import { useEffect, useRef } from 'react';\nimport { throttle } from 'lodash';\nimport { useAuth } from './useAuth';\nimport usePreviousPathByRoutesAccess from './usePreviousPath';\nimport { LocalStorageKeys } from '../types/types';\n\nconst useActivityTracker = (timeout: number, providerRoutesAccess: boolean) => {\n const timerRef = useRef(null);\n const shouldSkipTrackActivity = !timeout || !providerRoutesAccess;\n\n const { signOut } = useAuth();\n const { setPreviousPath } = usePreviousPathByRoutesAccess(\n providerRoutesAccess\n );\n\n useEffect(() => {\n if (shouldSkipTrackActivity) {\n return;\n }\n\n const handleReAuthentication = () => {\n if (providerRoutesAccess) {\n const currentPath = window.location.pathname;\n setPreviousPath(currentPath);\n signOut();\n }\n };\n\n const resetTimer = () => {\n if (timerRef.current) {\n clearTimeout(timerRef.current);\n }\n timerRef.current = setTimeout(handleReAuthentication, timeout);\n };\n\n const updateLastActivity = () => {\n const now = Date.now();\n localStorage.setItem(LocalStorageKeys.LAST_ACTIVITY_KEY, now.toString());\n resetTimer();\n };\n\n const handleStorageChange = (event: StorageEvent) => {\n if (event.key === LocalStorageKeys.LAST_ACTIVITY_KEY) {\n resetTimer();\n }\n };\n\n const throttledHandleActivity = throttle(updateLastActivity, 1000);\n\n const throttledHandleStorageChange = throttle(handleStorageChange, 1000);\n\n window.addEventListener('mousemove', throttledHandleActivity);\n window.addEventListener('keydown', throttledHandleActivity);\n window.addEventListener('click', throttledHandleActivity);\n window.addEventListener('scroll', throttledHandleActivity);\n window.addEventListener('storage', throttledHandleStorageChange);\n\n updateLastActivity();\n\n return () => {\n if (timerRef.current) {\n clearTimeout(timerRef.current);\n }\n window.removeEventListener('mousemove', throttledHandleActivity);\n window.removeEventListener('keydown', throttledHandleActivity);\n window.removeEventListener('click', throttledHandleActivity);\n window.removeEventListener('scroll', throttledHandleActivity);\n window.removeEventListener('storage', throttledHandleStorageChange);\n };\n }, [\n timeout,\n providerRoutesAccess,\n shouldSkipTrackActivity,\n signOut,\n setPreviousPath,\n ]);\n\n return null;\n};\n\nexport default useActivityTracker;\n","import { useEffect } from 'react';\nimport moment from 'moment';\nimport 'moment-timezone';\n\nimport { useAppDispatch, useAppSelector } from '../redux/store';\nimport { setInitialStartTime } from '../redux/modules/schedule';\n\nmoment.updateLocale('precise-en', { relativeTime: { h: '1 hour' } });\n\nexport default function useInitializeTimezone() {\n const dispatch = useAppDispatch();\n const currentClient = useAppSelector((state) => state.client.currentClient);\n const currentProvider = useAppSelector((state) => state.provider.provider);\n const timezoneIANA =\n currentProvider?.timezoneIANA || currentClient?.timezoneIANA;\n\n useEffect(() => {\n if (!timezoneIANA) {\n return;\n }\n moment.tz.setDefault(timezoneIANA);\n\n // init timezone sensitive data\n dispatch(setInitialStartTime());\n }, [timezoneIANA, dispatch]);\n}\n","import React, {\n useEffect,\n useRef,\n Suspense,\n lazy,\n useLayoutEffect,\n} from 'react';\nimport {\n Container,\n Box,\n Typography,\n Link as MuiLink,\n CircularProgress,\n Hidden,\n Drawer,\n} from '@material-ui/core';\nimport { makeStyles, Theme, createStyles } from '@material-ui/core/styles';\nimport { Route, Routes, Navigate } from 'react-router-dom';\nimport Amplify from '@aws-amplify/auth';\nimport { useDispatch, useSelector } from 'react-redux';\nimport { useLocation, Location, useNavigate } from 'react-router';\nimport './App.css';\nimport queryString from 'query-string';\n\nimport { Channel } from 'stream-chat';\nimport configs from './configs';\nimport useGtag from './hooks/useGtag';\nimport {\n fetchAttendanceAwards,\n fetchAttendanceStatusThresholds,\n fetchSettings,\n fetchTimeBlocks,\n} from './redux/modules/adminSettings';\nimport {\n fetchClientCaseTeam,\n fetchCurrentClientById,\n setCurrentClient,\n} from './redux/modules/client';\nimport { useAuth } from './hooks/useAuth';\n\nimport { fetchCurrentUser, setCurrentUser } from './redux/modules/users';\nimport { RootState } from './redux/modules/rootReducer';\nimport { useAppDispatch } from './redux/store';\nimport usePermission from './hooks/usePermission';\nimport { Resources } from './accessControl/acl';\nimport AddSessions from './clientPortal/sessions/AddSessions';\nimport useMaintenanceCheck from './hooks/useMaintenanceCheck';\nimport Maintenance from './components/Maintenance';\nimport { closeSocketConnection, openSocketConnection } from './api/socketApi';\nimport { resetSessionRemoval } from './redux/modules/sessionRemoval';\nimport AttainChat from './chat/AttainChat';\nimport ErrorBoundary from './components/ErrorBoundry/ErrorBoundry';\nimport useAttainChat from './hooks/useAttainChat';\nimport DrawerItemsList from './components/DrawerItemsList';\nimport AppHeader from './components/AppHeader';\nimport useApiVersionCheck from './hooks/useApiVersionCheck';\nimport AppErrors from './components/AppErrors/AppErrors';\nimport {\n fetchProvider,\n fetchProviderKyoClimbSettings,\n} from './redux/modules/provider';\nimport { UserAssociation, UserType } from './types/types';\nimport { fetchMenteeProviders } from './redux/modules/menteeProviders';\nimport { HelpPageProvider } from './commonPages/help/HelpPageContext';\nimport useActivityTracker from './hooks/useActivityTracker';\nimport useSettings from './hooks/useSettings';\nimport { isBT, minutesToMilliseconds } from './utils/helpers';\nimport usePreviousPathByRoutesAccess from './hooks/usePreviousPath';\nimport useInitializeTimezone from './hooks/useInitializeTimezone';\n\nconst Home = lazy(() => import('./clientPortal/home/Home'));\n\nconst ProviderProfile = lazy(\n () => import('./providerPortal/providerProfile/ProviderProfile')\n);\n\nconst Requests = lazy(() => import('./providerPortal/requests/Requests'));\n\nconst OpenSessions = lazy(\n () => import('./providerPortal/requests/openSessions/OpenSessions')\n);\nconst MyRequests = lazy(() => import('./clientPortal/requests/MyRequests'));\nconst VerificationForm = lazy(\n () => import('./clientPortal/verificationForm/VerificationForm')\n);\nconst Login = lazy(() => import('./commonPages/login/Login'));\nconst ForgotPasswordForm = lazy(\n () => import('./commonPages/login/ForgotPasswordForm')\n);\nconst SessionsRemovalResults = lazy(\n () => import('./commonPages/SessionsRemovalResults/SessionsRemovalResults')\n);\nconst MyUserProfile = lazy(\n () => import('./clientPortal/myUserProfile/MyUserProfile')\n);\n\nconst HomeForProvider = lazy(\n () => import('./providerPortal/home/HomeForProvider')\n);\nconst Alerts = lazy(() => import('./commonPages/messages/Messages'));\nconst MyClientProfile = lazy(() => import('./clientPortal/myProfile'));\nconst HelpPage = lazy(() => import('./commonPages/help/HelpPage'));\nconst Contact = lazy(\n () => import('./clientPortal/contactScheduling/ContactScheduling')\n);\n\nconst ClientHelpPage = lazy(\n () => import('./commonPages/help/client/ClientHelpPage')\n);\nconst ProviderHelpPage = lazy(\n () => import('./commonPages/help/provider/ProviderHelpPage')\n);\n\nconst SwitchToSpanishPage = lazy(\n () => import('./commonPages/languages/SwitchToSpanishPage')\n);\n\nconst ClientSettingsPage = lazy(\n () => import('./clientPortal/ClientSettingsPage')\n);\n\nconst ProviderSettingsPage = lazy(\n () => import('./providerPortal/ProviderSettingsPage')\n);\nconst Climb = lazy(() => import('./providerPortal/climb/Climb'));\nconst MenteeProviders = lazy(\n () => import('./providerPortal/menteeProviders/MenteeProviders')\n);\nconst MyScheduleProvider = lazy(\n () => import('./providerPortal/MySchedule/MyScheduleProvider')\n);\nconst MyScheduleClient = lazy(\n () => import('./clientPortal/MySchedule/MyScheduleClient')\n);\nconst SessionUpdatePage = lazy(\n () => import('./providerPortal/sessionUpdate/SessionUpdatePage')\n);\n\nAmplify.configure(configs.cognito);\nconst drawerWidth = 240;\n\nconst useStyles = makeStyles((theme: Theme) => {\n return createStyles({\n drawer: {\n [theme.breakpoints.up('lg')]: {\n width: drawerWidth,\n flexShrink: 0,\n },\n },\n drawerPaper: {\n width: drawerWidth,\n [theme.breakpoints.down('md')]: {\n width: '100%',\n },\n border: 'none',\n background: theme.palette.grey[100],\n [theme.breakpoints.down('md')]: {\n height: '100%',\n width: '100%',\n },\n },\n content: {\n display: 'flex',\n flexGrow: 1,\n minHeight: `calc(100vh - ${theme.spacing(12)}px)`,\n [theme.breakpoints.up('lg')]: {\n minHeight: `calc(100vh - ${theme.spacing(20)}px)`,\n },\n background: theme.palette.common.white,\n minWidth: 320,\n },\n contentBox: {\n paddingTop: theme.spacing(2),\n },\n toolbar: {\n minHeight: theme.spacing(20),\n [theme.breakpoints.down('md')]: {\n paddingTop: theme.spacing(3.5),\n minHeight: theme.spacing(11.5),\n justifyContent: 'space-between',\n },\n justifyContent: 'space-around',\n },\n logo: {\n width: theme.spacing(23),\n [theme.breakpoints.down('md')]: {\n width: theme.spacing(12.5),\n },\n },\n rectangles: {\n paddingLeft: theme.spacing(2),\n width: theme.spacing(86),\n height: theme.spacing(16),\n [theme.breakpoints.down('md')]: {\n display: 'none',\n },\n },\n navBarControls: {\n display: 'flex',\n alignItems: 'center',\n },\n sideBar: {\n height: '100%',\n },\n suspenseLoading: {\n display: 'flex',\n '& > * + *': {\n marginLeft: theme.spacing(2),\n },\n width: '100%',\n height: '100%',\n justifyContent: 'center',\n alignItems: 'center',\n },\n });\n});\n\nconst NotFound = ({ previousPath }: { previousPath?: string }) => {\n const { isAuthenticated } = useAuth();\n\n let navigateTo = '/login';\n if (isAuthenticated && previousPath) {\n navigateTo = previousPath;\n } else if (isAuthenticated) {\n navigateTo = '/home';\n }\n\n return ;\n};\n\nconst SessionsHOC = ({ children }: { children: JSX.Element }) => {\n const dispatch = useDispatch();\n useEffect(\n () => () => {\n dispatch(resetSessionRemoval());\n },\n [dispatch]\n );\n\n return children;\n};\n\nconst App: React.FC = () => {\n useApiVersionCheck();\n const classes = useStyles();\n const dispatch = useAppDispatch();\n const [isDrawerOpen, setIsDrawerOpen] = React.useState(false);\n const {\n isAuthenticated,\n initialLoading,\n loading,\n setLastLoggedInUserType,\n signOut,\n } = useAuth();\n const { maintenanceStatusOn } = useMaintenanceCheck();\n const location = useLocation();\n const navigate = useNavigate();\n const checkPermission = usePermission();\n const initialLocationRef = useRef(location);\n const {\n chatClient,\n channelFilters,\n channelId,\n isChannelListEmpty,\n } = useAttainChat();\n\n const clientRoutesAccess = checkPermission(Resources.clientRoutes);\n const providerRoutesAccess = checkPermission(Resources.providerRoutes);\n const educatorPortalAccess = checkPermission(Resources.educatorPortal);\n const { previousPath, removePreviousPath } = usePreviousPathByRoutesAccess(\n providerRoutesAccess\n );\n\n const { reAuthenticationThreshold } = useSettings();\n const reAuthenticationTimeout = minutesToMilliseconds(\n reAuthenticationThreshold\n );\n\n const currentUser = useSelector(\n (state: RootState) => state.users.currentUser\n );\n const currentClient = useSelector(\n (state: RootState) => state.client.currentClient\n );\n const { id: currentClientId } = currentClient || {};\n\n const currentClientLoading = useSelector(\n (state: RootState) => state.client.currentClientLoading\n );\n\n const currentProvider = useSelector(\n (state: RootState) => state.provider.provider\n );\n\n useInitializeTimezone();\n\n useEffect(() => {\n if (educatorPortalAccess && configs.educatorPortalUrl) {\n window.location.replace(configs.educatorPortalUrl);\n }\n }, [educatorPortalAccess]);\n\n useEffect(() => {\n if (currentProvider) {\n dispatch(fetchMenteeProviders(currentProvider.id));\n\n if (isBT(currentProvider)) {\n dispatch(fetchProviderKyoClimbSettings(currentProvider.id));\n }\n }\n if (currentClientId) {\n dispatch(fetchClientCaseTeam(currentClientId));\n }\n }, [currentProvider, currentClientId, dispatch]);\n\n useEffect(() => {\n if (isAuthenticated && !maintenanceStatusOn) {\n dispatch(fetchAttendanceStatusThresholds());\n dispatch(fetchSettings());\n dispatch(fetchTimeBlocks());\n removePreviousPath();\n\n if (clientRoutesAccess) {\n dispatch(fetchCurrentUser());\n setLastLoggedInUserType(UserType.Client);\n }\n\n if (providerRoutesAccess) {\n dispatch(fetchProvider());\n dispatch(fetchAttendanceAwards());\n setLastLoggedInUserType(UserType.Provider);\n }\n if (providerRoutesAccess) {\n openSocketConnection();\n }\n }\n\n return () => {\n closeSocketConnection();\n };\n }, [\n dispatch,\n isAuthenticated,\n providerRoutesAccess,\n clientRoutesAccess,\n maintenanceStatusOn,\n removePreviousPath,\n setLastLoggedInUserType,\n ]);\n\n useEffect(() => {\n if (!isAuthenticated) {\n dispatch(setCurrentUser(null));\n dispatch(setCurrentClient(null));\n }\n }, [dispatch, isAuthenticated]);\n\n useEffect(() => {\n if (\n !loading &&\n !initialLoading &&\n isAuthenticated &&\n initialLocationRef.current?.pathname &&\n initialLocationRef.current?.pathname !== '/'\n ) {\n // once auth loading is finished, attempt to go to initial route\n navigate({\n pathname: initialLocationRef.current.pathname,\n search: initialLocationRef.current.search,\n });\n initialLocationRef.current = null;\n }\n }, [loading, initialLoading, isAuthenticated, navigate]);\n\n useEffect(() => {\n window.scrollTo(0, 0);\n }, [location.pathname]);\n\n useLayoutEffect(() => {\n if (currentUser && !currentClient && !currentClientLoading) {\n const nonRevokedAssociations = currentUser.associations.filter(\n (assoc) => !assoc.dateRevoked\n );\n if (nonRevokedAssociations.length === 0) {\n return;\n }\n\n let selectedClient: UserAssociation | undefined;\n\n if (location.search) {\n const { currentClientId: id } = queryString.parse(location.search);\n\n if (id) {\n selectedClient = nonRevokedAssociations.find(\n (c) => c.clientId === +id\n );\n }\n }\n\n if (!selectedClient) {\n const verifiedClient = nonRevokedAssociations.find(\n (assoc) => assoc.dateVerified\n );\n if (verifiedClient) {\n selectedClient = verifiedClient;\n } else {\n [selectedClient] = nonRevokedAssociations;\n }\n }\n\n if (selectedClient && selectedClient.dateVerified) {\n dispatch(fetchCurrentClientById(+selectedClient.clientId));\n dispatch(fetchClientCaseTeam(+selectedClient.clientId));\n } else if (selectedClient) {\n navigate(`/verify-client/${selectedClient.clientId}`);\n }\n }\n }, [\n dispatch,\n currentUser,\n currentClient,\n currentClientLoading,\n navigate,\n location.pathname,\n location.search,\n ]);\n\n useGtag();\n\n useActivityTracker(reAuthenticationTimeout, providerRoutesAccess);\n\n const handleChannelChange = (channel: Channel) => {\n if (!channel.id) {\n return;\n }\n\n const clientId = Number(channel.id.split('_')[2]);\n dispatch(fetchClientCaseTeam(clientId));\n };\n\n const isOnSpanishPage = location.pathname === '/public/spanish';\n\n return (\n <>\n \n {isAuthenticated && !maintenanceStatusOn && (\n \n )}\n \n {isAuthenticated && !maintenanceStatusOn && !isOnSpanishPage && (\n \n \n \n \n \n )}\n \n \n \n \n
\n }\n >\n {maintenanceStatusOn ? (\n \n ) : (\n \n {/* /public/help routes are for the mobile app */}\n \n \n \n }\n key=\"/public/help\"\n />\n \n \n \n }\n key=\"/public/help/client\"\n />\n \n \n \n }\n key=\"/public/help/provider\"\n />\n \n\n {!isAuthenticated && [\n ,\n ,\n ]}\n {isAuthenticated &&\n providerRoutesAccess && [\n }\n key=\"/home\"\n />,\n }\n key=\"/my-profile\"\n />,\n }\n key=\"/alerts\"\n />,\n }\n key=\"/requests\"\n />,\n \n \n \n \n }\n />\n \n \n }\n />,\n }\n key=\"/openSessions\"\n />,\n }\n key=\"settings\"\n />,\n } key=\"Climb\" />,\n \n }\n />,\n }\n key=\"sessionUpdate\"\n />,\n ]}\n {providerRoutesAccess && [\n }\n />,\n }\n />,\n ]}\n {isAuthenticated &&\n clientRoutesAccess && [\n } key=\"/home\" />,\n }\n key=\"/verify-client\"\n />,\n }\n key=\"/add-sessions\"\n />,\n }\n key=\"/alerts\"\n />,\n \n \n \n \n }\n />\n \n \n }\n />,\n }\n key=\"/requests\"\n />,\n }\n key=\"/user-profile\"\n />,\n }\n key=\"/my-profile\"\n />,\n }\n key=\"settings\"\n />,\n \n }\n />,\n }\n />,\n ]}\n \n }\n />\n \n )}\n {(maintenanceStatusOn ||\n (!isAuthenticated && !loading && !initialLoading)) && (\n \n © {new Date().getFullYear()} Kyo Autism Therapy, LLC |{' '}\n \n Privacy Notice\n \n \n )}\n \n \n \n \n \n \n );\n};\n\nexport default App;\n","// This optional code is used to register a service worker.\n// register() is not called by default.\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 subsequent visits to a page, after all the\n// existing tabs open on the page have been closed, since previously cached\n// resources are updated in the background.\n\n// To learn more about the benefits of this model and instructions on how to\n// opt-in, read https://bit.ly/CRA-PWA\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.0/8 are 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\ntype Config = {\n onSuccess?: (registration: ServiceWorkerRegistration) => void;\n onUpdate?: (registration: ServiceWorkerRegistration) => void;\n};\n\nexport function register(config?: Config) {\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(\n process.env.PUBLIC_URL,\n window.location.href\n );\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/facebook/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. Let's check if a service worker still exists or not.\n checkValidServiceWorker(swUrl, config);\n\n // Add some additional logging to localhost, pointing developers to the\n // service worker/PWA documentation.\n navigator.serviceWorker.ready.then(() => {\n console.log(\n 'This web app is being served cache-first by a service ' +\n 'worker. To learn more, visit https://bit.ly/CRA-PWA'\n );\n });\n } else {\n // Is not localhost. Just register service worker\n registerValidSW(swUrl, config);\n }\n });\n }\n}\n\nfunction registerValidSW(swUrl: string, config?: Config) {\n navigator.serviceWorker\n .register(swUrl)\n .then(registration => {\n registration.onupdatefound = () => {\n const installingWorker = registration.installing;\n if (installingWorker == null) {\n return;\n }\n installingWorker.onstatechange = () => {\n if (installingWorker.state === 'installed') {\n if (navigator.serviceWorker.controller) {\n // At this point, the updated precached content has been fetched,\n // but the previous service worker will still serve the older\n // content until all client tabs are closed.\n console.log(\n 'New content is available and will be used when all ' +\n 'tabs for this page are closed. See https://bit.ly/CRA-PWA.'\n );\n\n // Execute callback\n if (config && config.onUpdate) {\n config.onUpdate(registration);\n }\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 // Execute callback\n if (config && config.onSuccess) {\n config.onSuccess(registration);\n }\n }\n }\n };\n };\n })\n .catch(error => {\n console.error('Error during service worker registration:', error);\n });\n}\n\nfunction checkValidServiceWorker(swUrl: string, config?: Config) {\n // Check if the service worker can be found. If it can't reload the page.\n fetch(swUrl, {\n headers: { 'Service-Worker': 'script' }\n })\n .then(response => {\n // Ensure service worker exists, and that we really are getting a JS file.\n const contentType = response.headers.get('content-type');\n if (\n response.status === 404 ||\n (contentType != null && contentType.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, config);\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\n .then(registration => {\n registration.unregister();\n })\n .catch(error => {\n console.error(error.message);\n });\n }\n}\n","import React from 'react';\nimport ReactDOM from 'react-dom';\nimport { Provider } from 'react-redux';\nimport { BrowserRouter } from 'react-router-dom';\nimport { CssBaseline, MuiThemeProvider } from '@material-ui/core';\nimport { ConfirmProvider } from 'material-ui-confirm';\nimport { SnackbarProvider } from 'notistack';\n\nimport * as serviceWorker from './serviceWorker';\nimport 'fetch-intercept'; // should be imported before fetch\n\nimport './index.css';\nimport store from './redux/store';\nimport { AuthProvider } from './hooks/useAuth';\nimport customTheme from './theme/theme';\n\nconst render = () => {\n const App = require('./App').default;\n ReactDOM.render(\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n ,\n document.getElementById('root')\n );\n};\n\nrender();\n\nif (process.env.NODE_ENV === 'development' && module.hot) {\n module.hot.accept('./App', render);\n}\n// If you want your app to work offline and load faster, you can change\n// unregister() to register() below. Note this comes with some pitfalls.Ò\n// Learn more about service workers: https://bit.ly/CRA-PWA\nserviceWorker.unregister();\n","import moment from 'moment';\nimport { DateObject } from 'react-multi-date-picker';\nimport {\n DayOfWeekId,\n DecimalNumber,\n NoShowParticipant,\n NoticeRequestType,\n NotificationPreference,\n Provider,\n ProviderAcceptanceRate,\n ScheduledSessionLog,\n ScheduledSession,\n} from '../types/types';\nimport { AvailabilityBlock } from '../redux/modules/availability';\nimport { SelectedBookingOption } from '../redux/modules/newSessions';\nimport configs from '../configs';\n\nexport const daysMap: { [key: string]: string } = {\n '0': 'Sun',\n '1': 'Mon',\n '2': 'Tue',\n '3': 'Wed',\n '4': 'Thu',\n '5': 'Fri',\n '6': 'Sat',\n};\n\nexport const DATE_TIME_FORMAT = 'YYYY-MM-DD hh:mm A';\nexport const DATE_TIME_FORMAT_WITH_DAY_NAME = 'YYYY-MM-DD ddd hh:mm A';\nexport const DATE_FORMAT = 'YYYY-MM-DD';\nexport const DATE_FORMAT_WITH_DAY_NAME = 'YYYY-MM-DD ddd';\nexport const DATE_FORMAT_US = 'MM/DD/YYYY';\nexport const NEW_UI_DATE_TIME_FORMAT = 'ddd MMM D, h:mm A';\nexport const NEW_UI_DATE_FORMAT = 'ddd MMM D';\nexport const NEW_UI_DATE_FORMAT_WEEKDAY_FIRST = 'ddd, MMM D'; // Sun, Mar 14\nexport const DATE_FORMAT_MONTH_NAME = 'MMM D, YYYY'; // Mar 14, 2021\nexport const DATE_FORMAT_MONTH_NAME_2 = 'MMM Do, YYYY'; // Mar 1st, 2021\nexport const DATE_FORMAT_MONTH_NAME_SHORT = 'MMM D';\nexport const DATE_FORMAT_MONTH_NAME_WITH_HOUR = 'MMM D h:mmA';\nexport const DATE_FORMAT_MONTH_NAME_WITH_YEAR = 'MMMM YYYY';\nexport const DATE_FORMAT_MONTH_NAME_WITH_DAY = 'MMMM DD';\nexport const DATE_FORMAT_ABBR_MONTH_NAME_WITH_DAY = 'MMM DD';\nexport const DATE_FORMAT_MONTH_NAME_DAY_YEAR = 'MMMM DD, YYYY';\nexport const DATE_FORMAT_WEEKDAY_MONTH_YEAR = 'dddd, MMMM D, YYYY'; // Tuesday, March 28, 2023\nexport const DATE_FORMAT_MONTH_YEAR = 'MMMM D, YYYY';\nexport const DATE_FORMAT_WEEKDAY_MONTH_YEAR_SHORT = 'ddd MMM DD, YYYY'; // Mon Sep 25, 2024\nexport const DATE_FORMAT_WEEKDAY_MONTH = 'ddd, MMMM D'; // Tue, March 28\n\nexport const DATE_FORMAT_TIME_MONTH_WITH_DAY = 'h:mmA MMM D';\n\nexport const TIME_FORMAT = 'h:mm A';\nexport const TIME_FORMAT_2 = 'hh:mm A';\nexport const TIME_FORMAT_24HR = 'HH:mm:ss';\nexport const TIME_FORMAT_12HR = 'h:mm';\n\nexport const MS_IN_HOUR = 3600000;\n\nexport const convert24hrToAmPm = (timeString: string) => {\n return moment.parseZone(timeString, TIME_FORMAT_24HR).format(TIME_FORMAT);\n};\n\nexport const stripCountryCode = (phoneNumber = '', countryCode = 1) => {\n const regex = new RegExp(`^\\\\+${countryCode}`);\n return phoneNumber.replace(regex, '');\n};\n\nexport const prependCountryCode = (phoneNumber = '', countryCode = 1) =>\n `+${countryCode}${phoneNumber.trim()}`;\n\nexport const millisecondsToTime = (duration: number) => {\n let minutes: number | string = Math.floor((duration / (1000 * 60)) % 60);\n const hours: number | string = Math.floor((duration / (1000 * 60 * 60)) % 24);\n\n minutes = minutes <= 0 ? '' : `${minutes}m`;\n\n return `${hours}h ${minutes}`;\n};\n\nexport const getUtcDateFromSTBRSession = (\n rebookOption: SelectedBookingOption\n) => {\n const { scheduledDate } = rebookOption;\n const time = rebookOption.sessionPlacement.startTime;\n const newDate = moment.utc(scheduledDate);\n\n const schedDateMoment = moment.utc(newDate);\n const localTime = moment(`${schedDateMoment.format('YYYY-MM-DD')} ${time}`);\n\n const dateInUtc = localTime.utc().toISOString();\n return dateInUtc;\n};\n\nexport const sortArrayByDateKey = (\n arr: Array = [],\n key: keyof T\n) => [...arr].sort((a, b): number => moment(a[key]).diff(moment(b[key])));\n\nexport const getWholeChar = (str: string, i: number) => {\n const code = str.charCodeAt(i);\n\n if (Number.isNaN(code)) return '';\n\n if (code < 0xd800 || code > 0xdfff) return str.charAt(i);\n\n if (code >= 0xd800 && code <= 0xdbff) {\n if (str.length <= i + 1) {\n throw new Error('High surrogate without following low surrogate');\n }\n\n const next = str.charCodeAt(i + 1);\n\n if (next < 0xdc00 || next > 0xdfff) {\n throw new Error('High surrogate without following low surrogate');\n }\n\n return str.charAt(i) + str.charAt(i + 1);\n }\n\n if (i === 0) {\n throw new Error('Low surrogate without preceding high surrogate');\n }\n\n const prev = str.charCodeAt(i - 1);\n\n if (prev < 0xd800 || prev > 0xdbff) {\n throw new Error('Low surrogate without preceding high surrogate');\n }\n\n return '';\n};\n\nexport function phoneFormat(phone: string) {\n const cleaned = `${phone}`.replace(/\\D/g, '');\n const match = cleaned.match(/^(\\d{3})(\\d{3})(\\d{4})$/);\n\n if (match) {\n return `+1 (${match[1]}) ${match[2]}-${match[3]}`;\n }\n\n return phone;\n}\n\nexport const configureNotificationDataById = (\n requestData: NotificationPreference[]\n) => {\n const configuredDataById: {\n [key: string]: {\n atLeastOneIsMandatory: boolean;\n enabledIds: number[];\n };\n } = {};\n requestData.forEach((item) => {\n if (!configuredDataById[item.categoryId]) {\n configuredDataById[item.categoryId] = {\n atLeastOneIsMandatory: Boolean(item.category?.atLeastOneIsMandatory),\n enabledIds: item.isEnabled ? [item.methodId] : [],\n };\n } else if (item.isEnabled) {\n configuredDataById[item.categoryId].enabledIds.push(item.methodId);\n }\n });\n\n return configuredDataById;\n};\n\nexport const checkIsPreferenceSelectDisabled = (\n timeBlockId: number,\n availabilityBlocks: Partial[]\n) => {\n const timeBlocksCount = 3;\n let hasAvailability = false;\n for (\n let i = timeBlockId - 1;\n i < availabilityBlocks.length;\n i += timeBlocksCount\n ) {\n const availabilityBlock = availabilityBlocks[i];\n\n if (availabilityBlock?.isAvailable) {\n hasAvailability = true;\n break;\n }\n }\n\n return !hasAvailability;\n};\n\nexport const daysToMilliseconds = (days: number) => {\n // days * hoursInDay * minutesInHour * secondsInMinute * 1000\n return days * 24 * 60 * 60 * 1000;\n};\n\nexport const minutesToMilliseconds = (minutes: number) => {\n return minutes * 60 * 1000;\n};\n\nexport const diffOfDatesInDayMilliseconds = (\n date1: string,\n date2: string,\n format = DATE_FORMAT_US\n) => {\n const momentDate1 = moment(date1, format).utc().startOf('day');\n const momentDate2 = moment(date2, format).utc().startOf('day');\n const datesDiff = momentDate2.diff(momentDate1);\n return datesDiff;\n};\n\nexport const ModifiedAvailabilityTimeOffMinStartDate = moment()\n .add(1, 'week')\n .startOf('week');\n\nexport const ModifiedAvailabilityTimeOffMaxStartDate = moment()\n .add(8, 'months')\n .startOf('day');\n\nexport const getDiffInDays = ({ from, to }: { from: string; to: string }) => {\n return moment.duration(moment(to).diff(from, 'day'), 'day').asDays() + 1;\n};\n\nexport const getFirstSessionAfter = ({\n sessions,\n after,\n}: {\n sessions: ScheduledSession[];\n after: number;\n}) => {\n return sessions.find((s: ScheduledSession) => {\n const { segmentStartUtc } = s;\n const diff = getDiffInDays({\n from: new Date().toUTCString(),\n to: segmentStartUtc,\n });\n\n return diff > after;\n });\n};\n\nexport const getCurrentAvail = (\n schedule: {\n dayOfWeekId: number;\n isAvailable: boolean;\n }[]\n) =>\n // Current avail = available weekday blocks * 3\n schedule.filter(\n (sch) =>\n sch.dayOfWeekId !== DayOfWeekId.Sunday &&\n sch.dayOfWeekId !== DayOfWeekId.Saturday &&\n sch.isAvailable\n ).length * 3;\n\nexport const getNumberOfHoursBelowRequiredAvail = ({\n schedule,\n minHrsTarget,\n}: {\n schedule: {\n dayOfWeekId: number;\n isAvailable: boolean;\n }[];\n minHrsTarget: number;\n}) =>\n // Min avail required = BTMin * 1.25\n Math.max(minHrsTarget * 1.25 - getCurrentAvail(schedule), 0);\n\nexport const calcAcceptanceRates = ({\n defaultText,\n acceptanceRate,\n}: {\n defaultText: string;\n acceptanceRate?: ProviderAcceptanceRate;\n}) => {\n const ltAcceptanceRate =\n !acceptanceRate || acceptanceRate.ltAcceptanceRate === null\n ? defaultText\n : `${Math.round(acceptanceRate.ltAcceptanceRate * 100)}%`;\n const stAcceptanceRate =\n !acceptanceRate || acceptanceRate.stAcceptanceRate === null\n ? defaultText\n : `${Math.round(acceptanceRate.stAcceptanceRate * 100)}%`;\n\n return {\n ltAcceptanceRate,\n stAcceptanceRate,\n };\n};\n\nexport const isBCBA = (provider: Pick | null) =>\n !!provider && ['BCBA', 'CD'].includes(provider.title);\n\nexport const isBT = (provider: Pick | null) =>\n !!provider && ['BT', 'SBT'].includes(provider.title);\n\nexport const getAddressString = (\n street?: string | null,\n city?: string | null,\n state?: string | null,\n zip?: string | null\n) => {\n let text = '';\n text += street ? `${street}, ` : '';\n text += city ? `${city}, ` : '';\n text += state ? `${state}, ` : '';\n text += zip;\n\n return text;\n};\n\nexport const createWeekString = (\n startDate: string,\n endDate: string,\n startDateFormat: string,\n endDateFormat?: string\n) => {\n const start = moment(startDate).format(startDateFormat);\n const end = moment(endDate).format(endDateFormat || startDateFormat);\n return `${start} - ${end}`;\n};\n\nexport const getFormattedWeekPickerDates = (\n value: DateObject | DateObject[] | null,\n format: string\n) => {\n if (!value || !Array.isArray(value)) {\n return undefined;\n }\n\n return value.map((date) => date.format(format));\n};\n\nexport const humanizeDuration = (\n duration: number | null,\n getDurationPartNames: (\n hours: number,\n minutes: number\n ) => { h: string; m: string } = () => ({ h: 'h', m: 'm' })\n) => {\n if (!duration) {\n return '';\n }\n\n const hours = Math.floor(duration);\n const minutes = Math.round((duration - hours) * 60);\n const { h: hoursLabel, m: minutesLabel } = getDurationPartNames(\n hours,\n minutes\n );\n const humanizedMinutes = minutes ? ` ${minutes}${minutesLabel}` : '';\n\n return `${hours}${hoursLabel}${humanizedMinutes}`;\n};\n\nexport const toAbsolutePath = (url: string) =>\n new URL(url, configs.portalUrl).toString();\n\nexport const toRevenuePortal = (url: string) => {\n return new URL(url, configs.revenuePortalUrl).toString();\n};\n\nconst getFullAddress = (\n addressLine1: string | null,\n addressLine2: string | null\n) => {\n let street: string | null;\n\n if (!addressLine1 && addressLine2) {\n street = addressLine2;\n return street;\n }\n\n street = addressLine1;\n if (addressLine2) {\n street += ` ${addressLine2}`;\n }\n return street;\n};\n\nexport const normalizeSessionLocation = (session: ScheduledSession) => {\n const {\n locationCity,\n locationState,\n locationAddressLine1,\n locationAddressLine2,\n locationZip,\n } = session;\n\n return {\n street: getFullAddress(locationAddressLine1, locationAddressLine2),\n city: locationCity,\n zip: locationZip,\n state: locationState,\n };\n};\n\nexport const scrollTo = (el: HTMLDivElement) => {\n el.scrollIntoView({ behavior: 'smooth' });\n};\n\nexport const isTodayBetween5thAndEndOfMonth = (): boolean => {\n const today = moment();\n const fifthDayOfMonth = moment().startOf('month').add(4, 'days');\n const lastDayOfMonth = moment().endOf('month');\n\n return today.isBetween(fifthDayOfMonth, lastDayOfMonth, 'day', '[]');\n};\n\nexport const getProviderProjectedTenur = (\n providerStartDate: string\n): number => {\n const startDate = moment(providerStartDate);\n const nextLevelDate = moment().add(1, 'month').startOf('month');\n\n return nextLevelDate.diff(startDate, 'days');\n};\n\nexport const formatTenureYearMonth = (tenureDays: number): string => {\n if (tenureDays <= 100) {\n return `${tenureDays}d`;\n }\n const years = Math.floor(tenureDays / 365);\n const months = Math.floor(tenureDays / (365 / 12)) % 12;\n let time = '';\n\n if (years) {\n time += `${years}yr `;\n }\n if (months) {\n time += `${months}mo`;\n }\n\n return time.trim();\n};\n\n/**\n * Formats a DecimalNumber object into a string representation with two decimal places.\n *\n * @param {DecimalNumber} amountObj - The object representing the decimal number.\n * @param {1 | -1} amountObj.s - The sign of the number (1 for positive, -1 for negative).\n * @param {number} amountObj.e - The exponent indicating the position of the decimal point.\n * @param {number[]} amountObj.d - The array of digits representing the number.\n * @returns {string} - The formatted number as a string with two decimal places.\n */\nexport const formatDecimalNumber = (amountObj: DecimalNumber): string => {\n const { s: sign, e: exponent, d: digits } = amountObj;\n\n // Combine the array of digits into a single string\n const numberStr = digits.map((n) => n.toString()).join('');\n\n // Calculate where the decimal point should be placed\n const integerPart = numberStr.slice(0, exponent + 1);\n let fractionalPart = numberStr.slice(exponent + 1);\n\n // Ensure at least two decimal places\n fractionalPart = fractionalPart.padEnd(2, '0');\n\n // If the fractional part is more than two digits, trim it to two\n fractionalPart = fractionalPart.slice(0, 2);\n\n // Construct the formatted number\n let formattedNumber = `${integerPart}.${fractionalPart}`;\n\n // If there's no fractional part, ensure to display '.00'\n if (fractionalPart.length === 0) {\n formattedNumber += '00';\n }\n\n // Adjust for sign\n if (sign === -1) {\n formattedNumber = `-${formattedNumber}`;\n }\n\n return formattedNumber;\n};\n\nexport const downloadFileByUrl = async (url: string, fileName: string) => {\n const response = await fetch(url);\n const blob = await response.blob();\n const blobUrl = URL.createObjectURL(blob);\n const link = document.createElement('a');\n link.href = blobUrl;\n link.download = fileName;\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n};\n\nexport const getNoticeText = (type?: NoticeRequestType) => {\n let result = '';\n\n if (!type) {\n return result;\n }\n\n switch (type) {\n case 'cc_expiration':\n result =\n 'The credit card we have on file has expired or will soon expire. ';\n break;\n case 'cc_declined':\n result = 'The credit card we have on file was declined. ';\n break;\n case 'cc_missing':\n result = 'We do not have a credit card on file. ';\n break;\n default:\n throw new Error('Unknown Notice type');\n }\n\n result += 'Please update your payment information';\n\n return result;\n};\n\nexport const isNoShowParticipantRequester = (\n participant: NoShowParticipant,\n sessionLogs: ScheduledSessionLog[]\n) => {\n const isProviderRequester =\n !!sessionLogs?.length && !!sessionLogs[0].requesterId;\n const isUserRequester = !!sessionLogs?.length && !!sessionLogs[0].userId;\n\n const shouldReturnForClient =\n participant === NoShowParticipant.Provider && isProviderRequester;\n const shouldReturnForProvider =\n participant === NoShowParticipant.Client && isUserRequester;\n return { shouldReturnForClient, shouldReturnForProvider };\n};\n","import { MUISortOptions } from 'mui-datatables';\nimport queryString from 'query-string';\nimport requester from './requester';\nimport {\n RequestAction,\n RequestStatus,\n RequestType,\n Request,\n} from '../types/types';\n\nconst fetchAllRequests = async (\n filters: { statusId: RequestStatus[] },\n onlyMyRequests: boolean,\n onlyIncompleteRequests: boolean,\n bookingType: RequestType | RequestType[] | null,\n limit: PaginationType,\n offset: PaginationType,\n sortOrder: MUISortOptions\n) => {\n const query = queryString.stringify(\n {\n limit,\n page: offset,\n orderBy: sortOrder.name,\n direction: sortOrder.direction,\n onlyMyRequests,\n onlyIncompleteRequests,\n ...filters,\n bookingType,\n },\n { arrayFormat: 'bracket' }\n );\n\n return requester\n .get(`v2/bookings/myBookings?${query}`)\n .then((response) => response.json())\n .then(\n (response) =>\n response.data as PaginationType extends number\n ? {\n rows: Request[];\n count: number;\n }\n : Request[]\n );\n};\n\nconst updateRequestStatus = async (\n requestId: number,\n newStatus: RequestStatus,\n shouldNotify: boolean,\n selectedOption?: number,\n updateAvailability?: boolean\n) => {\n return requester\n .put(`v2/bookings/${requestId}/requestStatus`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n newStatus,\n shouldNotify,\n selectedOption,\n updateAvailability,\n }),\n })\n .then((response) => response.json());\n};\n\nexport type UpdateRequestSessionStatusArgs = {\n requestId: number;\n actionId: RequestAction;\n sessionIds: number[];\n updateAvailability?: boolean;\n};\n\nconst updateRequestSessionStatus = async ({\n requestId,\n actionId,\n sessionIds,\n updateAvailability,\n}: UpdateRequestSessionStatusArgs) => {\n return requester\n .put(`v2/bookings/single-term-book-requests/${requestId}/sessions`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n actionId,\n sessionIds,\n updateAvailability,\n }),\n })\n .then((response) => response.json());\n};\n\nexport type UpdateSubOfferSessionStatusArgs = {\n requestId: number;\n statusId: RequestStatus;\n sessionIds: number[];\n};\n\nconst updateSubOfferSessionStatus = async ({\n requestId,\n statusId,\n sessionIds,\n}: UpdateSubOfferSessionStatusArgs) => {\n return requester\n .put(`v2/bookings/sub-offer-book-requests/${requestId}/status`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n statusId,\n sessionIds,\n }),\n })\n .then((response) => response.json());\n};\n\nexport default {\n fetchAllRequests,\n updateRequestStatus,\n updateRequestSessionStatus,\n updateSubOfferSessionStatus,\n};\n","export interface AvailabilityBlock {\n id: number;\n timeBlockDayOfWeekId: number;\n isAvailable: boolean;\n timeOff: boolean;\n timeBlockDayOfWeek: {\n timeBlockId: number;\n dayOfWeekId: number;\n };\n}\n\nexport enum AvailabilityStatus {\n Expired = 'Expired',\n Overridden = 'Overridden',\n Removed = 'Removed',\n Current = 'Current',\n Upcoming = 'Upcoming',\n Discarded = 'Discarded',\n}\n","import {\n createAsyncThunk,\n createSelector,\n createSlice,\n PayloadAction,\n SerializedError,\n} from '@reduxjs/toolkit';\nimport moment from 'moment';\nimport providerApi from '../../api/providerApi';\nimport { clearSearchResult } from './action';\nimport {\n NotificationMethodId,\n NotificationPreference,\n Provider,\n ProviderAddress,\n ProviderAttendanceAwards,\n ProviderAttendanceAwardVisibilityStatus,\n ProviderAttributes,\n ProviderLevel,\n ScheduledSession,\n} from '../../types/types';\nimport {\n getFirstSessionAfter,\n getNumberOfHoursBelowRequiredAvail,\n} from '../../utils/helpers';\nimport { TWO_WEEKS } from '../../utils/constants';\nimport { RootState } from './rootReducer';\nimport { KyoClimbSettings } from './adminSettings';\nimport { getRemoveSessionVariant } from '../../commonPages/MySchedule/utils/statusHelpers';\nimport scheduleApi from '../../api/scheduleApi';\n\nexport interface ProviderState {\n isLoading: boolean;\n provider: Provider | null;\n providerAttributes: ProviderAttributes | null;\n providerAttributesLoading: boolean;\n providerFullSchedule: ScheduledSession[] | null;\n providerFullScheduleLoading: boolean;\n notificationPreferences: NotificationPreference[];\n notificationPreferencesLoading: boolean;\n notificationPreferencesError: SerializedError | null;\n saveNotificationPreferencesLoading: boolean;\n providerAttendanceAwardsLoading: boolean;\n relatedClientIds: number[];\n providerProjectedLevelLoading: boolean;\n providerProjectedLevel: ProviderLevel | null;\n providerAttendanceAwards: ProviderAttendanceAwards | null;\n providerKyoClimbSettings: KyoClimbSettings[];\n providerKyoClimbSettingsLoading: boolean;\n providerKyoClimbSettingsError: boolean;\n}\n\nconst initialState: ProviderState = {\n provider: null,\n isLoading: false,\n providerAttributes: null,\n providerAttributesLoading: false,\n providerFullSchedule: null,\n providerFullScheduleLoading: false,\n notificationPreferences: [],\n notificationPreferencesLoading: false,\n notificationPreferencesError: null,\n saveNotificationPreferencesLoading: false,\n providerAttendanceAwardsLoading: false,\n relatedClientIds: [],\n providerProjectedLevelLoading: false,\n providerProjectedLevel: null,\n providerAttendanceAwards: null,\n providerKyoClimbSettings: [],\n providerKyoClimbSettingsLoading: false,\n providerKyoClimbSettingsError: false,\n};\n\nexport const fetchProviderNotificationPreferences = createAsyncThunk(\n 'provider/fetchProviderNotificationPreferences',\n (providerId: number) =>\n providerApi\n .fetchProviderNotificationPreferences(providerId)\n .then((res) => res)\n);\n\nexport const replaceProviderNotificationPreferences = createAsyncThunk(\n 'provider/saveProviderNotificationPreferences',\n (\n arg: {\n notificationPreferences: NotificationPreference[];\n providerId: number;\n },\n { rejectWithValue }\n ) =>\n providerApi\n .replaceProviderNotificationPreferences(\n arg.notificationPreferences,\n arg.providerId\n )\n .catch((e) => rejectWithValue(e))\n);\n\nexport const updateProviderAttendanceAward = createAsyncThunk(\n 'provider/updateProviderAttendanceAward',\n (id: number, { rejectWithValue }) =>\n providerApi\n .updateProviderAttendanceAward(id)\n .catch((e) => rejectWithValue(e))\n);\n\nexport const fetchProvider = createAsyncThunk(\n 'providers/fetchProvider',\n async () => {\n return providerApi.fetchCurrentProvider();\n }\n);\n\nexport const fetchProviderAttributes = createAsyncThunk(\n 'providers/fetchProviderAttributes',\n (providerId: number) => {\n return providerApi.fetchProviderAttributes(providerId);\n }\n);\n\nexport const updateProviderAttributes = createAsyncThunk(\n 'providers/updateProviderAttributes',\n (\n arg: { providerId: number; newAttributes: Partial },\n { rejectWithValue }\n ) => {\n const { providerId, newAttributes } = arg;\n\n return providerApi\n .updateProviderAttributes(providerId, newAttributes)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const fetchRelatedClients = createAsyncThunk(\n 'providers/fetchRelatedClients',\n async (arg: { providerId: number }) => {\n const { providerId } = arg;\n\n return (await providerApi.fetchRelatedClientIds(providerId)).data;\n }\n);\n\nexport const updateProviderAddress = createAsyncThunk(\n 'providers/updateProviderAddress',\n async (arg: { providerId: number; newProviderAddress: ProviderAddress }) => {\n return providerApi.updateProviderAddress(\n arg.providerId,\n arg.newProviderAddress\n );\n }\n);\n\nexport const fetchProviderProjectedLevel = createAsyncThunk(\n 'providers/fetchProviderProjectedLevel',\n (providerId: number) => {\n return providerApi.fetchProviderProjectedLevel(providerId);\n }\n);\n\nexport const fetchProviderAttendanceAwards = createAsyncThunk(\n 'providers/fetchProviderAttendanceAwards',\n (providerId: number) => providerApi.fetchProviderAttendanceAwards(providerId)\n);\n\nexport const fetchProviderKyoClimbSettings = createAsyncThunk(\n 'providers/fetchProviderKyoClimbSettings',\n (providerId: number) => providerApi.fetchProviderKyoClimbSettings(providerId)\n);\n\nexport const fetchProviderFullSchedule = createAsyncThunk(\n 'providers/fetchProviderFullSchedule',\n async (arg: { providerId: number; startDate: string; endDate: string }) => {\n return scheduleApi.fetchProviderFullSchedule({\n providerId: arg.providerId,\n startDate: arg.startDate,\n endDate: arg.endDate,\n });\n }\n);\n\nconst providerSlice = createSlice({\n name: 'provider',\n initialState,\n reducers: {\n providerLoading: (state, action: PayloadAction) => ({\n ...state,\n isLoading: action.payload,\n }),\n setProviderAttributes: (\n state,\n action: PayloadAction\n ) => ({\n ...state,\n providerAttributes: action.payload,\n }),\n },\n extraReducers: (builder) => {\n builder\n .addCase(clearSearchResult, (state) => {\n return {\n ...initialState,\n provider: state.provider,\n };\n })\n .addCase(fetchProviderNotificationPreferences.pending, (state) => {\n return {\n ...state,\n notificationPreferencesLoading: true,\n };\n })\n .addCase(\n fetchProviderNotificationPreferences.fulfilled,\n (state, action) => {\n const notificationPreferences = action.payload.filter(\n (preference) => NotificationMethodId[preference.methodId]\n );\n return {\n ...state,\n notificationPreferencesLoading: false,\n notificationPreferences,\n };\n }\n )\n .addCase(\n fetchProviderNotificationPreferences.rejected,\n (state, action) => {\n return {\n ...state,\n notificationPreferencesLoading: false,\n notificationPreferencesError: action.error,\n };\n }\n )\n .addCase(\n replaceProviderNotificationPreferences.fulfilled,\n (state, action) => {\n return {\n ...state,\n saveNotificationPreferencesLoading: false,\n };\n }\n )\n .addCase(replaceProviderNotificationPreferences.pending, (state) => {\n return {\n ...state,\n saveNotificationPreferencesLoading: true,\n };\n })\n .addCase(\n replaceProviderNotificationPreferences.rejected,\n (state, action) => {\n return {\n ...state,\n saveNotificationPreferencesLoading: false,\n notificationPreferencesError: action.error,\n };\n }\n )\n .addCase(updateProviderAttendanceAward.pending, (state) => {\n state.providerAttendanceAwardsLoading = true;\n })\n .addCase(updateProviderAttendanceAward.rejected, (state) => {\n state.providerAttendanceAwardsLoading = false;\n })\n .addCase(\n updateProviderAttendanceAward.fulfilled,\n (\n state,\n action: PayloadAction\n ) => {\n const { id, isSeen } = action.payload;\n state.providerAttendanceAwardsLoading = false;\n const currentProviderAttendanceAward = state.providerAttendanceAwards?.attendanceAwards.find(\n (a) => a.id === id\n );\n\n if (currentProviderAttendanceAward) {\n currentProviderAttendanceAward.isSeen = isSeen;\n }\n }\n )\n .addCase(fetchProvider.pending, (state, action) => {\n return {\n ...state,\n isLoading: true,\n };\n })\n .addCase(fetchProvider.rejected, (state, action) => {\n return {\n ...state,\n isLoading: false,\n };\n })\n .addCase(fetchProvider.fulfilled, (state, action) => {\n return {\n ...state,\n isLoading: false,\n provider: action.payload,\n };\n })\n .addCase(fetchProviderAttributes.pending, (state, action) => {\n return {\n ...state,\n providerAttributesLoading: true,\n };\n })\n .addCase(fetchProviderAttributes.rejected, (state) => {\n return {\n ...state,\n providerAttributesLoading: false,\n };\n })\n .addCase(fetchProviderAttributes.fulfilled, (state, action) => {\n return {\n ...state,\n providerAttributesLoading: false,\n providerAttributes: action.payload,\n };\n })\n .addCase(updateProviderAttributes.pending, (state, action) => {\n return {\n ...state,\n providerAttributesLoading: true,\n };\n })\n .addCase(updateProviderAttributes.rejected, (state) => {\n return {\n ...state,\n providerAttributesLoading: false,\n };\n })\n .addCase(updateProviderAttributes.fulfilled, (state, action) => {\n return {\n ...state,\n providerAttributesLoading: false,\n providerAttributes: action.payload,\n };\n })\n .addCase(fetchRelatedClients.fulfilled, (state, action) => {\n state.relatedClientIds = action.payload;\n })\n .addCase(fetchRelatedClients.rejected, (state) => {\n state.relatedClientIds = [];\n })\n .addCase(updateProviderAddress.fulfilled, (state, action) => {\n if (\n state.provider &&\n state.provider?.id === action.payload.providerId\n ) {\n state.provider.address = action.payload;\n }\n })\n .addCase(fetchProviderProjectedLevel.pending, (state, action) => {\n return {\n ...state,\n providerProjectedLevelLoading: true,\n };\n })\n .addCase(fetchProviderProjectedLevel.rejected, (state) => {\n return {\n ...state,\n providerProjectedLevelLoading: false,\n };\n })\n .addCase(fetchProviderProjectedLevel.fulfilled, (state, action) => {\n return {\n ...state,\n providerProjectedLevelLoading: false,\n providerProjectedLevel: action.payload,\n };\n })\n .addCase(fetchProviderAttendanceAwards.pending, (state, action) => {\n return {\n ...state,\n providerAttendanceAwardsLoading: true,\n };\n })\n .addCase(fetchProviderAttendanceAwards.fulfilled, (state, action) => {\n return {\n ...state,\n providerAttendanceAwardsLoading: false,\n providerAttendanceAwards: action.payload,\n };\n })\n .addCase(fetchProviderAttendanceAwards.rejected, (state) => {\n return {\n ...state,\n providerAttendanceAwardsLoading: false,\n };\n })\n .addCase(fetchProviderKyoClimbSettings.pending, (state) => {\n state.providerKyoClimbSettingsLoading = true;\n state.providerKyoClimbSettingsError = false;\n })\n .addCase(fetchProviderKyoClimbSettings.fulfilled, (state, action) => {\n state.providerKyoClimbSettingsLoading = false;\n state.providerKyoClimbSettingsError = false;\n state.providerKyoClimbSettings = action.payload;\n })\n .addCase(fetchProviderKyoClimbSettings.rejected, (state) => {\n state.providerKyoClimbSettingsLoading = false;\n state.providerKyoClimbSettingsError = true;\n })\n .addCase(fetchProviderFullSchedule.pending, (state) => {\n state.providerFullScheduleLoading = true;\n })\n .addCase(fetchProviderFullSchedule.fulfilled, (state, action) => {\n if (action.payload === null) {\n state.providerFullSchedule = null;\n } else {\n const firstTimeOffSession = getFirstSessionAfter({\n sessions: action.payload,\n after: TWO_WEEKS,\n });\n\n state.providerFullSchedule = action.payload.map((session) => {\n const removeSessionVariant = getRemoveSessionVariant(session);\n\n const { segmentStartUtc, segmentEndUtc } = session;\n const sessionStart = moment(segmentStartUtc);\n const sessionEnd = moment(segmentEndUtc);\n const now = moment().utc();\n\n const isActiveSession = now.isBetween(sessionStart, sessionEnd);\n\n return {\n ...session,\n removeSessionVariant,\n isFirstTimeOff:\n firstTimeOffSession?.segmentId === session.segmentId,\n isActiveSession,\n };\n });\n }\n state.providerFullScheduleLoading = false;\n })\n .addCase(fetchProviderFullSchedule.rejected, (state) => {\n state.providerFullScheduleLoading = false;\n state.providerFullSchedule = null;\n });\n },\n});\n\nexport const { setProviderAttributes } = providerSlice.actions;\n\nexport default providerSlice.reducer;\n\nexport const selectNumberOfHoursBelowRequiredAvail = createSelector(\n (state: RootState) => state.provider.provider,\n (provider: Provider | null) => {\n return provider?.schedule\n ? getNumberOfHoursBelowRequiredAvail({\n schedule: provider.schedule,\n minHrsTarget: provider.minHrsTarget,\n })\n : 0;\n }\n);\n","import moment, { Moment } from 'moment';\nimport { isEqual } from 'lodash';\nimport { DATE_FORMAT, TIME_FORMAT } from '../../../utils/helpers';\nimport { AvailabilityStatus } from '../../../shared/types';\nimport { Availability } from '../../../redux/modules/availability';\nimport { PREFERRED_BLOCK_MIN_INTERVAL } from '../../../utils/constants';\nimport { ScheduledSession, SessionStatus } from '../../../types/types';\nimport { AvailabilityByWeek, PageMode } from '../types/types';\n\nexport const preferredBlock3EndValidation = (\n block3Start: string | undefined,\n block3End: string | undefined\n) => {\n if (!block3Start || !block3End) {\n return true;\n }\n const time1 = moment(block3End, TIME_FORMAT);\n const time2 = moment(block3Start, TIME_FORMAT);\n const difference = time1.diff(time2, 'minutes');\n\n return difference >= PREFERRED_BLOCK_MIN_INTERVAL * 60;\n};\n\nexport const findTempAvailabilityByWeek = (\n stAvail: Availability[],\n startOfWeek: Moment\n) => {\n const weekStartDate = moment(startOfWeek).format(DATE_FORMAT);\n\n const tempAvail = stAvail.find((item) => item.startDate === weekStartDate);\n\n return tempAvail || null;\n};\n\nexport const findStandardAvailabilityByWeek = (\n ltAvail: Availability[],\n startOfWeek: Moment\n) => {\n const weekStartDate = moment(startOfWeek).format(DATE_FORMAT);\n\n const upcomingAvail = ltAvail.find(\n (item) =>\n item.status === AvailabilityStatus.Upcoming &&\n moment(item.startDate).format(DATE_FORMAT) <= weekStartDate\n );\n\n if (upcomingAvail) {\n return upcomingAvail;\n }\n\n const currentAvail = ltAvail.find(\n (item) => item.status === AvailabilityStatus.Current\n );\n\n if (currentAvail) {\n return currentAvail;\n }\n\n return null;\n};\n\nexport const findStandardAvailability = (ltAvail: Availability[]) => {\n const upcomingAvail = ltAvail.find(\n (item) => item.status === AvailabilityStatus.Upcoming\n );\n\n if (upcomingAvail) {\n return upcomingAvail;\n }\n\n const currentAvail = ltAvail.find(\n (item) => item.status === AvailabilityStatus.Current\n );\n\n if (currentAvail) {\n return currentAvail;\n }\n\n return null;\n};\n\nexport const findSessionForCellRendering = (sessions: ScheduledSession[]) => {\n const confirmedSession = sessions.find(\n (session) => session?.status === SessionStatus.Confirmed\n );\n const pendingSession = sessions.find(\n (session) =>\n session &&\n ![\n SessionStatus.Confirmed,\n SessionStatus.Cancelled,\n SessionStatus.TimeOff,\n ].includes(session.status)\n );\n return confirmedSession || pendingSession || sessions[0];\n};\n\ntype GetMatrixCellStyleArgs = {\n isSmallGrid: boolean;\n isAvailMode: boolean;\n colors?: {\n main: string;\n background: {\n bigGrid: string;\n smallGrid: string;\n };\n };\n};\n\nexport const getMatrixCellStyle = (args: GetMatrixCellStyleArgs) => {\n const { isSmallGrid, isAvailMode, colors } = args;\n\n if (isAvailMode || !colors) return undefined;\n\n const background = isSmallGrid\n ? colors.background.smallGrid\n : colors.background.bigGrid;\n const color = colors.main;\n\n return { background, color };\n};\n\ntype IsCellClickableArgs = {\n pageMode: PageMode;\n isSmallGrid: boolean;\n isPast: boolean;\n scheduleLength: number;\n};\n\nexport const isCellClickable = (args: IsCellClickableArgs) => {\n const { pageMode, isSmallGrid, isPast, scheduleLength } = args;\n\n const isCancelMode = pageMode === PageMode.remove;\n const isAvailMode = [PageMode.temporary, PageMode.standard].includes(\n pageMode\n );\n\n if (pageMode === PageMode.standard) {\n return false;\n }\n\n return (\n (isSmallGrid || (isAvailMode && !isPast)) &&\n !isCancelMode &&\n (!!scheduleLength || (isAvailMode && !isPast && !!scheduleLength))\n );\n};\n\nexport const isChangedAvailability = (\n availability: Availability,\n availabilityByWeek: AvailabilityByWeek\n): boolean => {\n const availabilityForCompare: AvailabilityByWeek = {\n blocks: availability.availabilityBlocks,\n originalId: availability.id,\n preferences: {\n preferredBlock1Start: availability.preferredBlock1Start,\n preferredBlock3Start: availability.preferredBlock3Start,\n preferredBlock3End: availability.preferredBlock3End,\n },\n type: availability.type,\n };\n const availabilityWithoutStatus = () => {\n const { status, ...rest } = availabilityByWeek;\n return rest;\n };\n\n return !isEqual(availabilityForCompare, availabilityWithoutStatus());\n};\n\nexport const isChangedAvailabilityStartDate = ({\n currentStartDate,\n initialStartDate,\n}: {\n currentStartDate: moment.Moment;\n initialStartDate: moment.Moment;\n}) => {\n return currentStartDate.toISOString() !== initialStartDate.toISOString();\n};\n\nexport const getWeekRange = (date: Moment): Date[] => {\n const weekStart = date.clone().startOf('week').toDate();\n const weekEnd = moment(weekStart).add(6, 'days').toDate();\n\n return [weekStart, weekEnd];\n};\n\nexport const getPreferredBlockTime = (\n isDisabled: boolean,\n preferenceTime: string | null | undefined,\n timeBlockOption: string[] | undefined\n) =>\n !isDisabled && !preferenceTime && timeBlockOption\n ? timeBlockOption[0]\n : preferenceTime;\n","import requester from '../requester';\nimport { NotificationPreference, User } from '../../types/types';\n\nconst fetchCurrentUser = async () => {\n return requester\n .get(`users/me`)\n .then((response) => response.json() as Promise<{ data: User }>);\n};\n\nconst fetchRelationships = async () => {\n return requester\n .get(`users/relationships?type=client`)\n .then((response) => response.json());\n};\n\nconst updateUser = async (\n userId: number,\n firstName: string,\n lastName: string,\n mobileNumber: string\n) => {\n return requester\n .put(`users/${userId}`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ firstName, lastName, mobileNumber }),\n })\n .then((response) => response.json());\n};\n\nconst verifyUserClient = async (\n userId: number,\n clientId: number,\n dob: string\n) => {\n return requester\n .put(`users/${userId}/clients/${clientId}/verified`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ dob }),\n })\n .then((response) => response.json());\n};\n\nconst updateUserRelationship = async (\n userId: number,\n clientId: number,\n relationshipId: number\n) => {\n return requester\n .put(`users/${userId}/clients/${clientId}/relationship`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ relationshipId }),\n })\n .then((response) => response.json());\n};\n\nconst getUserNotificationPreferences = async (\n userId: number\n): Promise => {\n return requester\n .get(`notificationPreferences/user/${userId}`, {\n headers: { 'Content-Type': 'application/json' },\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst replaceUserNotificationPreferences = async (\n userId: number,\n notificationPreferences: NotificationPreference[]\n): Promise => {\n return requester\n .put(`notificationPreferences/user/${userId}`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ notificationPreferences }),\n })\n .then((response) => response.json());\n};\n\nexport default {\n fetchCurrentUser,\n fetchRelationships,\n updateUser,\n verifyUserClient,\n updateUserRelationship,\n getUserNotificationPreferences,\n replaceUserNotificationPreferences,\n};\n","import {\n createAsyncThunk,\n createSlice,\n Dispatch,\n isRejected,\n PayloadAction,\n SerializedError,\n} from '@reduxjs/toolkit';\nimport usersApi from '../../api/admin/usersApi';\nimport { AppThunk, AsyncState } from '../store';\nimport {\n NotificationMethodId,\n NotificationPreference,\n Relationship,\n User,\n} from '../../types/types';\nimport { RootState } from './rootReducer';\n\nexport const fetchCurrentUser = createAsyncThunk(\n 'users/fetchCurrentUser',\n async () => {\n const response = await usersApi.fetchCurrentUser();\n return response.data;\n }\n);\n\nexport const setUserClientRelationship = createAsyncThunk(\n 'users/setUserClientRelationship',\n async (\n arg: { userId: number; clientId: number; relationshipId: number },\n { rejectWithValue }\n ) => {\n const { userId, clientId, relationshipId } = arg;\n return usersApi\n .updateUserRelationship(userId, clientId, relationshipId)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const verifyUserClient = createAsyncThunk(\n 'users/verifyUserClient',\n async (\n arg: { userId: number; clientId: number; dob: string },\n { rejectWithValue }\n ) => {\n const { userId, clientId, dob } = arg;\n return usersApi\n .verifyUserClient(userId, clientId, dob)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const fetchUserNotificationPreferences = createAsyncThunk(\n 'users/fetchUserNotificationPreferences',\n (userId: number) =>\n usersApi.getUserNotificationPreferences(userId).then((res) => res)\n);\n\nexport const replaceUserNotificationPreferences = createAsyncThunk(\n 'users/replaceUserNotificationPreferences',\n (\n arg: {\n userId: number;\n notificationPreferences: NotificationPreference[];\n },\n { rejectWithValue }\n ) =>\n usersApi\n .replaceUserNotificationPreferences(\n arg.userId,\n arg.notificationPreferences\n )\n .catch((e) => rejectWithValue(e))\n);\n\nexport interface UsersState {\n currentUser: User | null;\n currentUserLoading: boolean;\n currentUserUpdating: boolean;\n currentUserRequestId: string | undefined;\n relationships: Relationship[];\n relationshipsLoading: boolean;\n verificationState: AsyncState | null;\n relationshipUpdatedState: AsyncState | null;\n notificationPreferences: NotificationPreference[];\n notificationPreferencesLoading: boolean;\n notificationPreferencesError: SerializedError | null;\n saveNotificationPreferencesLoading: boolean;\n}\n\nconst initialState: UsersState = {\n currentUser: null,\n currentUserLoading: false,\n currentUserUpdating: false,\n currentUserRequestId: undefined,\n relationships: [],\n relationshipsLoading: false,\n verificationState: null,\n relationshipUpdatedState: null,\n notificationPreferences: [],\n notificationPreferencesLoading: false,\n notificationPreferencesError: null,\n saveNotificationPreferencesLoading: false,\n};\n\nexport const updateCurrentUser = createAsyncThunk<\n Promise | null,\n {\n firstName: string;\n lastName: string;\n mobileNumber: string;\n },\n { state: RootState }\n>(\n 'users/updateCurrentUser',\n (\n arg: {\n firstName: string;\n lastName: string;\n mobileNumber: string;\n },\n { getState, rejectWithValue }\n ) => {\n const { currentUser } = getState().users;\n const { firstName, lastName, mobileNumber } = arg;\n\n if (!currentUser) {\n return null;\n }\n\n return usersApi\n .updateUser(currentUser.id, firstName, lastName, mobileNumber)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const fetchAndUpdateCurrentUser = createAsyncThunk<\n Promise | null,\n {\n firstName: string;\n lastName: string;\n mobileNumber: string;\n },\n { state: RootState }\n>('users/fetchAndUpdateCurrentUser', async (arg, { rejectWithValue }) => {\n try {\n const currentUser = await usersApi\n .fetchCurrentUser()\n .then((res) => res.data);\n const { firstName, lastName, mobileNumber } = arg;\n\n return await usersApi.updateUser(\n currentUser.id,\n firstName,\n lastName,\n mobileNumber\n );\n } catch (e) {\n return rejectWithValue(e);\n }\n});\n\nconst usersSlice = createSlice({\n name: 'users',\n initialState,\n reducers: {\n setCurrentUser: (state, action: PayloadAction) => ({\n ...state,\n currentUser: action.payload,\n }),\n setCurrentUserUpdating: (state, action: PayloadAction) => ({\n ...state,\n currentUserUpdating: action.payload,\n }),\n setRelationships: (state, action: PayloadAction) => ({\n ...state,\n relationships: action.payload,\n }),\n setRelationshipsLoading: (state, action: PayloadAction) => ({\n ...state,\n relationshipsLoading: action.payload,\n }),\n setVerificationFailed: (state, action: PayloadAction) => ({\n ...state,\n verificationFailed: action.payload,\n }),\n resetVerificationState: (state) => ({\n ...state,\n verificationState: null,\n }),\n resetRelationshipUpdatedState: (state) => ({\n ...state,\n relationshipUpdatedState: null,\n }),\n },\n extraReducers: (builder) => {\n builder\n .addCase(fetchCurrentUser.pending, (state, action) => {\n if (!state.currentUserLoading) {\n return {\n ...state,\n currentUserLoading: true,\n currentUserRequestId: action.meta.requestId,\n };\n }\n return state;\n })\n .addCase(fetchCurrentUser.fulfilled, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.currentUserLoading &&\n state.currentUserRequestId === requestId\n ) {\n return {\n ...state,\n currentUserLoading: false,\n currentUserRequestId: undefined,\n currentUser: action.payload,\n };\n }\n return state;\n })\n .addCase(fetchCurrentUser.rejected, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.currentUserLoading &&\n state.currentUserRequestId === requestId\n ) {\n return {\n ...state,\n currentUserLoading: false,\n currentUserRequestId: undefined,\n currentUser: null,\n };\n }\n return state;\n })\n .addCase(verifyUserClient.pending, (state) => {\n return {\n ...state,\n verificationState: 'pending',\n };\n })\n .addCase(verifyUserClient.fulfilled, (state) => {\n if (state.verificationState === 'pending') {\n return {\n ...state,\n verificationState: 'success',\n };\n }\n return state;\n })\n .addCase(verifyUserClient.rejected, (state) => {\n if (state.verificationState === 'pending') {\n return {\n ...state,\n verificationState: 'failed',\n };\n }\n return state;\n })\n .addCase(setUserClientRelationship.pending, (state) => {\n return {\n ...state,\n relationshipUpdatedState: 'pending',\n };\n })\n .addCase(setUserClientRelationship.fulfilled, (state) => {\n if (state.relationshipUpdatedState === 'pending') {\n return {\n ...state,\n relationshipUpdatedState: 'success',\n };\n }\n return state;\n })\n .addCase(setUserClientRelationship.rejected, (state) => {\n if (state.relationshipUpdatedState === 'pending') {\n return {\n ...state,\n relationshipUpdatedState: 'failed',\n };\n }\n return state;\n })\n .addCase(fetchUserNotificationPreferences.pending, (state) => {\n return {\n ...state,\n notificationPreferencesLoading: true,\n };\n })\n .addCase(fetchUserNotificationPreferences.rejected, (state, action) => {\n return {\n ...state,\n notificationPreferencesLoading: false,\n notificationPreferencesError: action.error,\n };\n })\n .addCase(fetchUserNotificationPreferences.fulfilled, (state, action) => {\n const notificationPreferences = action.payload.filter(\n (preference) => NotificationMethodId[preference.methodId]\n );\n return {\n ...state,\n notificationPreferencesLoading: false,\n notificationPreferences,\n };\n })\n .addCase(\n replaceUserNotificationPreferences.fulfilled,\n (state, action) => {\n return {\n ...state,\n saveNotificationPreferencesLoading: false,\n };\n }\n )\n .addCase(replaceUserNotificationPreferences.pending, (state) => {\n return {\n ...state,\n saveNotificationPreferencesLoading: true,\n };\n })\n .addCase(replaceUserNotificationPreferences.rejected, (state, action) => {\n return {\n ...state,\n saveNotificationPreferencesLoading: false,\n notificationPreferencesError: action.error,\n };\n })\n .addCase(updateCurrentUser.pending, (state, action) => {\n return {\n ...state,\n currentUserUpdating: true,\n };\n })\n .addCase(updateCurrentUser.rejected, (state, action) => {\n return {\n ...state,\n currentUserUpdating: false,\n };\n })\n .addCase(updateCurrentUser.fulfilled, (state, action) => {\n return {\n ...state,\n currentUserUpdating: false,\n };\n });\n },\n});\n\nexport const {\n setCurrentUser,\n setCurrentUserUpdating,\n setRelationships,\n setRelationshipsLoading,\n resetVerificationState,\n resetRelationshipUpdatedState,\n} = usersSlice.actions;\n\nexport default usersSlice.reducer;\n\nexport const fetchRelationships = () => async (dispatch: Dispatch) => {\n dispatch(setRelationshipsLoading(true));\n let response;\n try {\n response = await usersApi.fetchRelationships();\n } catch (e: any) {\n console.log(e);\n }\n\n if (response && response.data) {\n dispatch(setRelationships(response.data));\n }\n\n dispatch(setRelationshipsLoading(false));\n};\n\nexport const handleClientVerification = (\n clientId: number,\n dob: string,\n relationshipId: number\n): AppThunk => async (dispatch, getState) => {\n const { currentUser } = getState().users;\n if (currentUser) {\n const userId = currentUser.id;\n\n const verifyAction = await dispatch(\n verifyUserClient({ userId, clientId, dob })\n );\n\n if (!isRejected(verifyAction)) {\n await dispatch(\n setUserClientRelationship({ userId, clientId, relationshipId })\n );\n }\n }\n};\n","import React, { HTMLAttributes } from 'react';\n\nexport interface MatrixCellProps {\n className?: string;\n onClick?: () => void;\n children?: React.ReactNode;\n rootProps?: HTMLAttributes;\n}\n\nconst MatrixCell = ({\n className,\n onClick,\n children,\n rootProps,\n}: MatrixCellProps) => (\n \n {children}\n
\n);\n\nexport default MatrixCell;\n","import { Auth } from '@aws-amplify/auth';\nimport { merge } from 'lodash';\nimport configs from '../configs';\n\nexport class ResponseError extends Error {\n public response: Response;\n\n constructor(response: Response) {\n super(response.statusText);\n this.response = response;\n }\n}\n\nclass Requester {\n constructor(\n private apiUrl: string,\n private defaultRequestInit?: RequestInit\n ) {}\n\n get = (recoursePath: string, init?: RequestInit) => {\n return this.request(recoursePath, merge(init, { method: 'get' }));\n };\n\n post = (recoursePath: string, init?: RequestInit) => {\n return this.request(recoursePath, merge(init, { method: 'post' }));\n };\n\n put = (recoursePath: string, init?: RequestInit) => {\n return this.request(recoursePath, merge(init, { method: 'put' }));\n };\n\n patch = (recoursePath: string, init?: RequestInit) => {\n return this.request(recoursePath, merge(init, { method: 'patch' }));\n };\n\n delete = (recoursePath: string, init?: RequestInit) => {\n return this.request(recoursePath, merge(init, { method: 'delete' }));\n };\n\n async request(recoursePath: string, init?: RequestInit) {\n const requestInit = await this.createRequestInit(init);\n const url = this.makeUrl(recoursePath);\n\n const response = await fetch(url, requestInit);\n\n if (!response.ok) {\n throw new ResponseError(response);\n }\n\n return response;\n }\n\n private async createRequestInit(\n requestInit?: RequestInit\n ): Promise {\n let init: RequestInit = {};\n const authHeader = await this.getAuthorizationHeader();\n\n if (authHeader) {\n init.headers = { Authorization: authHeader };\n }\n\n if (this.defaultRequestInit) {\n init = merge(init, this.defaultRequestInit);\n }\n\n if (requestInit) {\n init = merge(init, requestInit);\n }\n\n return init;\n }\n\n private getAuthorizationHeader = async (): Promise => {\n const session = await Auth.currentSession();\n const token = session.getIdToken().getJwtToken();\n\n if (!token) {\n return undefined;\n }\n\n return `Bearer ${token}`;\n };\n\n private makeUrl = (path: string): string => {\n return `${this.apiUrl}/${path}`;\n };\n}\n\nconst requester = new Requester(configs.apiUrl);\n\nexport default requester;\n","import requester from '../requester';\nimport { AttendanceAward } from '../../redux/modules/adminSettings';\nimport { AttendanceStatusThreshold } from '../../types/types';\n\nconst fetchAttendanceAwards = async () => {\n return requester\n .get(`settings/attendance-awards`)\n .then((response) => response.json() as Promise<{ data: AttendanceAward[] }>)\n .then((data) => data.data);\n};\n\nconst fetchAttendanceStatusThresholds = async () => {\n return requester\n .get(`settings/attendance-status-thresholds`)\n .then(\n (response) =>\n response.json() as Promise<{ data: AttendanceStatusThreshold[] }>\n )\n .then((data) => data.data);\n};\n\nconst fetchSettings = async () => {\n return requester.get(`settings`).then((response) => response.json());\n};\n\nconst fetchKyoClimbSettings = async () => {\n return requester\n .get(`settings/kyo-climb-settings`)\n .then((response) => response.json());\n};\n\nexport default {\n fetchAttendanceAwards,\n fetchAttendanceStatusThresholds,\n fetchSettings,\n fetchKyoClimbSettings,\n};\n","import requester from '../requester';\n\nconst fetchTimeBlocks = async () => {\n return requester.get(`timeBlocks`).then((response) => response.json());\n};\n\nexport default {\n fetchTimeBlocks,\n};\n","import {\n createSlice,\n Dispatch,\n PayloadAction,\n createAsyncThunk,\n} from '@reduxjs/toolkit';\nimport adminSettingsApi from '../../api/admin/adminSettingsApi';\nimport timeBlocksApi from '../../api/admin/timeBlocksApi';\nimport { AttendanceStatusThreshold } from '../../types/types';\n\nexport interface AttendanceAward {\n id: number;\n name: string;\n streak: number;\n amount: number;\n changerId: number;\n}\n\nexport interface AdminSetting {\n key: string;\n value: string | number | number[];\n}\n\nexport interface SessionPlacement {\n id: number;\n timeBlockId: number;\n startTime: string | null;\n duration: number | null;\n}\nexport interface TimeBlock {\n id: number;\n start: string;\n end: string;\n}\n\nexport interface KyoClimbSettings {\n id: number;\n name: string;\n minRating: number;\n minImpactHours: number;\n maxCancelRate: number;\n climbCash: number;\n changerId: number | null;\n}\n\nexport interface AdminSettingsState {\n attendanceAwards: AttendanceAward[];\n attendanceAwardsLoading: boolean;\n attendanceAwardsError: boolean;\n attendanceStatusThresholds?: AttendanceStatusThreshold[];\n settings: AdminSetting[];\n isSettingsLoading: boolean;\n timeBlocks: TimeBlock[];\n isTimeBlocksLoading: boolean;\n}\n\nconst initialState: AdminSettingsState = {\n attendanceAwards: [],\n attendanceAwardsLoading: false,\n attendanceAwardsError: false,\n attendanceStatusThresholds: undefined,\n settings: [],\n isSettingsLoading: false,\n timeBlocks: [],\n isTimeBlocksLoading: false,\n};\n\nexport const fetchAttendanceAwards = createAsyncThunk(\n 'adminSettings/fetchAttendanceAwards',\n () => adminSettingsApi.fetchAttendanceAwards()\n);\n\nexport const fetchAttendanceStatusThresholds = createAsyncThunk(\n 'adminSettings/fetchAttendanceStatusThresholds',\n () => adminSettingsApi.fetchAttendanceStatusThresholds()\n);\n\nconst adminSettingsSlice = createSlice({\n name: 'adminSettings',\n initialState,\n reducers: {\n setSettingsLoading: (\n state,\n action: PayloadAction\n ): AdminSettingsState => ({\n ...state,\n isSettingsLoading: action.payload,\n }),\n setSettings: (\n state,\n action: PayloadAction\n ): AdminSettingsState => ({\n ...state,\n settings: action.payload,\n }),\n timeBlocksLoading: (state) => ({ ...state, isTimeBlocksLoading: true }),\n timeBlocksReceived: (state, action: PayloadAction) => ({\n ...state,\n isTimeBlocksLoading: false,\n timeBlocks: action.payload,\n }),\n },\n extraReducers: (builder) => {\n builder\n .addCase(fetchAttendanceAwards.pending, (state) => {\n state.attendanceAwardsLoading = true;\n state.attendanceAwardsError = false;\n })\n .addCase(fetchAttendanceAwards.fulfilled, (state, action) => {\n state.attendanceAwardsLoading = false;\n state.attendanceAwardsError = false;\n state.attendanceAwards = action.payload;\n })\n .addCase(fetchAttendanceAwards.rejected, (state) => {\n state.attendanceAwardsLoading = false;\n state.attendanceAwardsError = true;\n })\n .addCase(fetchAttendanceStatusThresholds.fulfilled, (state, action) => {\n state.attendanceStatusThresholds = action.payload;\n });\n },\n});\n\nexport const {\n setSettings,\n setSettingsLoading,\n timeBlocksLoading,\n timeBlocksReceived,\n} = adminSettingsSlice.actions;\n\nexport default adminSettingsSlice.reducer;\n\nexport const fetchSettings = () => async (dispatch: Dispatch) => {\n dispatch(setSettingsLoading(true));\n let response;\n try {\n response = await adminSettingsApi.fetchSettings();\n } catch (e: any) {\n console.log(e);\n }\n if (response) {\n dispatch(setSettings(response.data));\n }\n dispatch(setSettingsLoading(false));\n};\n\nexport const fetchTimeBlocks = () => async (dispatch: Dispatch) => {\n dispatch(timeBlocksLoading());\n let response;\n try {\n response = await timeBlocksApi.fetchTimeBlocks();\n } catch (e: any) {\n console.log(e);\n }\n if (response) {\n dispatch(timeBlocksReceived(response));\n }\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(\"rect\", {\n width: 73,\n height: 17,\n rx: 8,\n fill: \"#EDEDED\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M7.77 13H8.8535V7.577L11.4165 13H11.939L14.4965 7.577V12.9945H15.5855V5.08H14.535L11.6805 11.0365L8.8095 5.08H7.77V13ZM19.1449 13H20.3109V9.7275L22.9894 5.08H21.6474L19.7279 8.4075L17.8084 5.08H16.4664L19.1449 9.7275V13ZM27.7132 13H28.8627V6.1635H31.4972V5.08H25.0787V6.1635H27.7132V13ZM32.4873 13H37.5473V11.9165H33.6368V9.469H36.8873V8.3855H33.6368V6.1635H37.5473V5.08H32.4873V13ZM38.4282 13H39.6217L40.1992 11.2125H43.4497L44.0382 13H45.2317L42.6577 5.08H41.0022L38.4282 13ZM40.5512 10.1345L41.8162 6.2295L43.0977 10.1345H40.5512ZM46.3284 13H47.4119V7.577L49.9749 13H50.4974L53.0549 7.577V12.9945H54.1439V5.08H53.0934L50.2389 11.0365L47.3679 5.08H46.3284V13Z\",\n fill: \"#1F8B24\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M70.1602 4.05826C70.2554 4.12209 70.3125 4.22915 70.3125 4.34375V9.5C70.3125 9.64056 70.2269 9.76696 70.0964 9.81916L69.9688 9.5C70.0964 9.81916 70.0964 9.81916 70.0964 9.81916L70.0946 9.81987L70.0904 9.82156L70.0747 9.82774C70.0611 9.83308 70.0413 9.84077 70.016 9.85049C69.9653 9.86993 69.8923 9.89749 69.8016 9.93048C69.6204 9.99637 69.3677 10.0843 69.0816 10.1723C68.521 10.3448 67.7904 10.5312 67.2188 10.5312C66.6366 10.5312 66.1543 10.3382 65.7352 10.1706L65.7161 10.1629C65.2802 9.98855 64.909 9.84375 64.4688 9.84375C63.9874 9.84375 63.3423 10.0014 62.793 10.172C62.5236 10.2557 62.2865 10.3395 62.1169 10.4024C62.0979 10.4094 62.0797 10.4162 62.0625 10.4227V14.6562C62.0625 14.8461 61.9086 15 61.7188 15C61.5289 15 61.375 14.8461 61.375 14.6562V4.34375C61.375 4.1539 61.5289 4 61.7188 4C61.9086 4 62.0625 4.1539 62.0625 4.34375V4.5378C62.2179 4.48341 62.4036 4.42121 62.6059 4.35895C63.1665 4.18647 63.8971 4 64.4688 4C65.0468 4 65.5164 4.19039 65.9269 4.35679C65.9369 4.36084 65.9469 4.36487 65.9568 4.36889C66.384 4.54193 66.7566 4.6875 67.2188 4.6875C67.7001 4.6875 68.3452 4.52988 68.8945 4.35923C69.1639 4.27554 69.401 4.19172 69.5706 4.12885C69.6553 4.09745 69.723 4.07137 69.7691 4.05328C69.7922 4.04423 69.8098 4.03719 69.8216 4.03248L69.8346 4.02722L69.8376 4.02598L69.8383 4.02572\",\n fill: \"#1F8B24\"\n});\n\nvar SvgMyTeamBadge = function SvgMyTeamBadge(_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: 77,\n height: 17,\n viewBox: \"0 0 77 17\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgMyTeamBadge, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/my-team-badge.3adac9da.svg\";\nexport { ForwardRef as ReactComponent };","import React from 'react';\nimport { makeStyles, SvgIcon, SvgIconProps, Theme } from '@material-ui/core';\nimport { ReactComponent as CovidBadge } from '../../../assets/my-team-badge.svg';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n icon: {\n height: 17,\n width: 77,\n },\n}));\n\nconst MyCaseTeamBadgeIcon = (props: SvgIconProps) => {\n const classes = useStyles();\n return (\n \n );\n};\n\nexport default MyCaseTeamBadgeIcon;\n","import React from 'react';\nimport { Avatar, Box, Typography, makeStyles, Theme } from '@material-ui/core';\nimport CovidBadgeIcon from '../badges/CovidBadge/CovidBadgeIcon';\nimport StyledButtonLink from '../buttons/StyledButtonLink';\nimport MyCaseTeamBadgeIcon from '../badges/MyCaseTeamBadge/MyCaseTeamBadgeIcon';\nimport { Provider, SessionStatus } from '../../types/types';\nimport ProviderBCBABadge from '../badges/BCBABadge/ProviderBCBABadge';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n providerCell: {\n display: 'flex',\n alignItems: 'center',\n },\n avatar: {\n marginTop: theme.spacing(0.5),\n marginRight: theme.spacing(1),\n },\n viewDetails: {\n fontWeight: 400,\n },\n badgeContainer: {\n display: 'flex',\n flexWrap: 'wrap',\n '& > *:not(:last-child)': {\n marginRight: theme.spacing(1),\n },\n '& > *': {\n marginTop: 2,\n },\n },\n cancelled: {\n whiteSpace: 'nowrap',\n color: theme.palette.kyoGray63.main,\n fontSize: 10,\n },\n}));\n\ninterface ProviderCellProps {\n provider: Pick<\n Provider,\n 'firstName' | 'lastName' | 'profilePhoto' | 'covidVaccinatedDate' | 'title'\n >;\n isToggled?: boolean;\n onToggle?: Function;\n isMyTeam?: boolean;\n sessionStatus?: SessionStatus;\n}\n\nconst ProviderCell = (props: ProviderCellProps) => {\n const { provider, isToggled, onToggle, isMyTeam, sessionStatus } = props;\n const classes = useStyles();\n return (\n \n \n \n {`${provider.firstName} ${provider.lastName}`}\n
\n {provider.covidVaccinatedDate && }\n {isMyTeam && }\n {sessionStatus && sessionStatus === SessionStatus.Cancelled && (\n Cancelled\n )}\n \n
\n {onToggle && (\n
\n {\n onToggle();\n }}\n className={classes.viewDetails}\n >\n {isToggled ? 'Hide details' : 'View details'}\n \n
\n )}\n
\n
\n );\n};\n\nexport default ProviderCell;\n","import queryString from 'query-string';\nimport requester from './requester';\nimport {\n FetchBookingFilters,\n Request,\n RequestStatus,\n RetractedSessionsResponseType,\n} from '../types/types';\nimport { SessionPlacement } from '../redux/modules/adminSettings';\n\nconst fetchBookings = async (\n filters: FetchBookingFilters\n): Promise<{ rows: Request[]; count: number } | Request[]> => {\n const query = queryString.stringify(\n {\n ...filters,\n typedStatuses: JSON.stringify(filters.typedStatuses),\n },\n { arrayFormat: 'bracket' }\n );\n\n return requester\n .get(`v2/bookings?${query}`)\n .then((resp) => resp.json())\n .then((resp) => resp.data);\n};\n\nconst createSingleTermBookRequest = async (\n clientId: number,\n providerId: number,\n selectedOptions: {\n schedDate: string;\n sessionPlacement: SessionPlacement;\n }[]\n) => {\n return requester\n .post(`v2/bookings/single-term-book-requests`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n clientId,\n providerId,\n selectedOptions,\n }),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst retractOSSessions = async (\n openSessionId: number,\n sessionIds?: number[]\n) => {\n return requester\n .put(`v2/bookings/open-session-book-requests/${openSessionId}`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ statusId: RequestStatus.RETRACTED, sessionIds }),\n })\n .then((response) => response.json())\n .then((response) => response.data as RetractedSessionsResponseType);\n};\n\nconst retractSTSessions = async (requestId: number, sessionIds: number[]) => {\n return requester\n .put(`v2/bookings/${requestId}/requestStatus`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n newStatus: RequestStatus.RETRACTED,\n sessionIds,\n shouldNotify: true,\n }),\n })\n .then((response) => response.json())\n .then((response) => response.data as RetractedSessionsResponseType);\n};\n\nexport default {\n fetchBookings,\n createSingleTermBookRequest,\n retractOSSessions,\n retractSTSessions,\n};\n","import { createSelector, createSlice, PayloadAction } from '@reduxjs/toolkit';\nimport { Channel } from 'stream-chat';\nimport { RootState } from './rootReducer';\n\nexport interface ChatState {\n unreadMessagesCountPerClient: { [key: number]: number };\n currentChannel: Channel | null;\n}\n\nconst initialState: ChatState = {\n unreadMessagesCountPerClient: {},\n currentChannel: null,\n};\n\nconst chatSlice = createSlice({\n name: 'chat',\n initialState,\n reducers: {\n setUnreadMessageCountPerClient: (\n state,\n action: PayloadAction<{ id: number; count: number }>\n ) => {\n const { id, count } = action.payload;\n state.unreadMessagesCountPerClient[id] = count;\n },\n resetMessageCounts: (state) => {\n state.unreadMessagesCountPerClient = {};\n },\n setCurrentChannel: (state, action: PayloadAction) => ({\n ...state,\n currentChannel: action.payload,\n }),\n },\n});\n\nexport const {\n setUnreadMessageCountPerClient,\n resetMessageCounts,\n setCurrentChannel,\n} = chatSlice.actions;\n\nexport const selectTotalUnreadCount = createSelector(\n (state: RootState) => state.chat.unreadMessagesCountPerClient,\n (unreadMessagesCountPerClient) => {\n return Object.values(unreadMessagesCountPerClient).reduce(\n (total, clientUnreadCount) => {\n return total + clientUnreadCount;\n },\n 0\n );\n }\n);\n\nexport default chatSlice.reducer;\n","import queryString from 'query-string';\nimport {\n Client,\n ClientAttributes,\n ClientSTBRAvailability,\n Goal,\n Provider,\n} from '../types/types';\nimport requester from './requester';\n\nconst fetchClientCaseTeam = async (clientId: number): Promise => {\n return requester\n .get(`v2/clients/${clientId}/care-team`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchClientById = async (clientId: number): Promise => {\n return requester\n .get(`v2/clients/${clientId}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchClientGoals = async (\n clientId: number,\n limit?: number\n): Promise => {\n const query = queryString.stringify({ limit });\n\n return requester\n .get(`clients/${clientId}/goals?${query}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchClientSingleTermBookingAvailability = async (\n clientId: number\n): Promise => {\n return requester\n .get(`v2/clients/${clientId}/single-term-booking-availability`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst updateClientAttributes = async (\n clientId: number,\n attributes: ClientAttributes\n): Promise => {\n return requester\n .post(`v2/clients/${clientId}/attributes`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ newAttributes: attributes }),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n fetchClientCaseTeam,\n fetchClientById,\n fetchClientGoals,\n fetchClientSingleTermBookingAvailability,\n updateClientAttributes,\n};\n","import { useEffect, useState } from 'react';\nimport { useSelector } from 'react-redux';\nimport { keyBy } from 'lodash';\nimport { RootState } from '../redux/modules/rootReducer';\nimport { TimeBlock } from '../redux/modules/adminSettings';\nimport { AttendanceStatusThreshold } from '../types/types';\n\nexport default function useSettings() {\n const settings = useSelector(\n (state: RootState) => state.adminSettings.settings\n );\n const tBlocks = useSelector(\n (state: RootState) => state.adminSettings.timeBlocks\n );\n const thresholds = useSelector(\n (state: RootState) => state.adminSettings.attendanceStatusThresholds\n );\n\n const [minOccupiedLength, setMinOccupiedLength] = useState(0);\n const [futureSearchPeriod, setFutureSearchPeriod] = useState(3);\n const [swapSessionCount, setSwapSessionCount] = useState(3);\n const [btwSessionBuffer, setBtwSessionBuffer] = useState(60);\n const [\n upcomingAvailabilityMinPeriod,\n setUpcomingAvailabilityMinPeriod,\n ] = useState(2);\n const [inDemandMinScore, setInDemandMinScore] = useState(0);\n const [inDemandMaxRank, setInDemandMaxRank] = useState(0);\n\n const [timeBlocks, setTimeBlocks] = useState([]);\n const [attendanceStatusThresholds, setAttendanceStatusThresholds] = useState<\n AttendanceStatusThreshold[]\n >([]);\n const [\n reAuthenticationThreshold,\n setReAuthenticationThreshold,\n ] = useState(5);\n const [noShowSettings, setNoShowSettings] = useState({\n noShowDelayMinutes: 0,\n clientNoShowWaitMinutes: 0,\n providerNoShowWaitMinutes: 0,\n noShowExtensionMinutes: 0,\n preNoShowExtensionMinutes: 0,\n });\n const [\n subOfferOptOutAllowedInHours,\n setSubOfferOptOutAllowedInHours,\n ] = useState(24);\n\n useEffect(() => {\n if (settings) {\n const settingsByKey = keyBy(settings, 'key');\n\n if (settingsByKey.minOccupiedLength) {\n setMinOccupiedLength(+settingsByKey.minOccupiedLength.value);\n }\n\n if (settingsByKey.futureSearchPeriod) {\n setFutureSearchPeriod(+settingsByKey.futureSearchPeriod.value);\n }\n\n if (settingsByKey.swapSessionCount) {\n setSwapSessionCount(+settingsByKey.swapSessionCount.value);\n }\n\n if (settingsByKey.btwSessionBuffer) {\n setBtwSessionBuffer(+settingsByKey.btwSessionBuffer.value);\n }\n\n if (settingsByKey.upcomingAvailabilityMinPeriod) {\n setUpcomingAvailabilityMinPeriod(\n +settingsByKey.upcomingAvailabilityMinPeriod.value\n );\n }\n\n if (tBlocks) {\n setTimeBlocks(tBlocks);\n }\n\n if (settingsByKey.inDemandMinScore) {\n setInDemandMinScore(+settingsByKey.inDemandMinScore.value);\n }\n\n if (settingsByKey.inDemandMaxRank) {\n setInDemandMaxRank(+settingsByKey.inDemandMaxRank.value);\n }\n\n if (thresholds) {\n setAttendanceStatusThresholds(thresholds);\n }\n\n if (settingsByKey.reAuthenticationThresholdInMinutes) {\n setReAuthenticationThreshold(\n +settingsByKey.reAuthenticationThresholdInMinutes.value\n );\n }\n\n const {\n noShowDelayMinutes,\n clientNoShowWaitMinutes,\n providerNoShowWaitMinutes,\n noShowExtensionMinutes,\n preNoShowExtensionMinutes,\n } = settingsByKey;\n if (\n noShowDelayMinutes &&\n clientNoShowWaitMinutes &&\n providerNoShowWaitMinutes &&\n noShowExtensionMinutes &&\n preNoShowExtensionMinutes\n ) {\n setNoShowSettings({\n noShowDelayMinutes: +noShowDelayMinutes.value,\n clientNoShowWaitMinutes: +clientNoShowWaitMinutes.value,\n providerNoShowWaitMinutes: +providerNoShowWaitMinutes.value,\n noShowExtensionMinutes: +noShowExtensionMinutes.value,\n preNoShowExtensionMinutes: +preNoShowExtensionMinutes.value,\n });\n }\n\n if (settingsByKey.subOfferOptOutAllowedInHours) {\n setSubOfferOptOutAllowedInHours(\n +settingsByKey.subOfferOptOutAllowedInHours.value\n );\n }\n }\n }, [settings, tBlocks, thresholds]);\n\n return {\n futureSearchPeriod,\n setFutureSearchPeriod,\n minOccupiedLength,\n setMinOccupiedLength,\n swapSessionCount,\n setSwapSessionCount,\n btwSessionBuffer,\n setBtwSessionBuffer,\n upcomingAvailabilityMinPeriod,\n timeBlocks,\n inDemandMinScore,\n inDemandMaxRank,\n attendanceStatusThresholds,\n reAuthenticationThreshold,\n noShowSettings,\n subOfferOptOutAllowedInHours,\n };\n}\n","import moment from 'moment';\nimport {\n RemovedBy,\n ScheduledSession,\n SessionStatus,\n UserType,\n} from '../types/types';\nimport { NEW_UI_DATE_TIME_FORMAT, TIME_FORMAT } from './helpers';\nimport { getProviderSessionsInfo } from '../commonPages/MySchedule/utils/statusHelpers';\n\nexport const isSessionCancellable = (\n session: ScheduledSession,\n userType: UserType\n) => {\n if (session.sessionLogs?.length) {\n return false;\n }\n\n if (session.isBookRequest && userType === UserType.Client) {\n return !!session.id && session.isCancellableByClient;\n }\n\n const isCancellable =\n userType === UserType.Client\n ? session.isCancellableByClient\n : session.isCancellableByProvider;\n\n return session.status === SessionStatus.Confirmed && isCancellable;\n};\n\nexport const isSessionCancelled = (sessionStatus: SessionStatus) =>\n [SessionStatus.Cancelled, SessionStatus.TimeOff].includes(sessionStatus);\n\nexport const canSearchForSub = (session: ScheduledSession) => {\n return Boolean(\n session.cancellationEvent?.isEligibleForOS &&\n !session.cancellationEvent.bookRequestSession &&\n session.removedBy &&\n [RemovedBy.Provider, RemovedBy.Admin].includes(session.removedBy)\n );\n};\n\nconst roundHalf = (num: number) => {\n return Math.round(num * 2) / 2;\n};\n\nexport const formatSessionDuration = (\n session: ScheduledSession,\n timeUnitFormat: 'short' | 'long' = 'long'\n) => {\n const startTime = moment(session.segmentStartUtc);\n const endTime = moment(session.segmentEndUtc);\n\n const segmentDuration =\n session.segmentDuration ||\n moment.duration(moment(endTime).diff(moment(startTime))).asHours();\n const halfRoundedDuration = roundHalf(segmentDuration);\n\n const unit = timeUnitFormat === 'long' ? 'hour' : 'hr';\n const pluralSuffix = halfRoundedDuration > 1 ? 's' : '';\n\n return `${halfRoundedDuration} ${unit}${pluralSuffix}`;\n};\n\nexport const getSessionTimes = (session: ScheduledSession) => {\n const { segmentStartUtc, segmentEndUtc } = session;\n\n return `${moment(segmentStartUtc).format(NEW_UI_DATE_TIME_FORMAT)} - ${moment(\n segmentEndUtc\n ).format(TIME_FORMAT)} (${formatSessionDuration(session, 'short')})`;\n};\n\nexport const getSessionWith = (\n session: ScheduledSession,\n userType: UserType\n) => {\n const { clientId } = session;\n\n if (userType === UserType.Provider) {\n if (clientId) {\n return `with ${clientId}`;\n }\n return '';\n }\n\n const { sessionIsWith } = getProviderSessionsInfo(session);\n\n return sessionIsWith;\n};\n","import queryString from 'query-string';\nimport requester from './requester';\nimport {\n ApiPagination,\n ApiSorting,\n CancellationEvent,\n CancellationEventsFilters,\n CancellationEventsSort,\n CancelledSegmentsResponseType,\n PaginatedData,\n ScheduledSession,\n} from '../types/types';\n\n// for cancelling multiple sessions\nasync function cancelSessions(\n clientId: number | null,\n providerId: number | null,\n sessions: ScheduledSession[]\n): Promise> {\n const body = {\n segmentIds: sessions.map((s) => s.segmentId),\n clientId,\n providerId,\n };\n\n return requester\n .post(`v2/cancellation`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify(body),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n}\n\nconst fetchCancellationEvents = async (\n filters: Partial,\n sorting: ApiSorting,\n paging: ApiPagination\n): Promise> => {\n const query = queryString.stringify({ ...filters, ...paging, ...sorting });\n const url = `v2/cancellation/events?${query}`;\n\n return requester\n .get(url, {\n headers: { 'Content-Type': 'application/json' },\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n cancelSessions,\n fetchCancellationEvents,\n};\n","import {\n createAsyncThunk,\n createSlice,\n PayloadAction,\n SerializedError,\n} from '@reduxjs/toolkit';\nimport moment from 'moment';\nimport { groupBy, uniqBy } from 'lodash';\nimport cancellationApi from '../../api/cancellationApi';\nimport { RootState } from './rootReducer';\nimport {\n ApiSorting,\n CancellationEvent,\n CancellationEventsFilters,\n CancellationEventsSort,\n CancelledSegmentsResponseType,\n PaginatedData,\n RequestStatus,\n RequestType,\n RetractedSessionsResponseType,\n ScheduledSession,\n SessionStatus,\n SortingDirection,\n} from '../../types/types';\nimport { DATE_FORMAT } from '../../utils/helpers';\nimport { CANCELLATIONS_LAST_DAYS } from '../../utils/constants';\nimport { CANCELLTION_EVENTS_PER_PAGE } from '../../shared/constants';\nimport bookingApi from '../../api/bookingApi';\n\nexport interface UserSessionCancellationState {\n selectedSessions: ScheduledSession[];\n cancellationInProgress: boolean;\n retractionInProgress: boolean;\n cancellationError: SerializedError | null;\n retractionError: SerializedError | null;\n cancellationEvents: Array;\n cancellationPaidEvents: Array;\n loadingCancellationEvents: boolean;\n loadingCancellationPaidEvents: boolean;\n cancellationEventsPage: number;\n cancellationPaidEventsPage: number;\n cancellationEventsTotalCount: number;\n cancellationPaidEventsTotalCount: number;\n}\n\nconst cancellationState = {\n cancellationEvents: [],\n cancellationPaidEvents: [],\n loadingCancellationEvents: false,\n loadingCancellationPaidEvents: false,\n cancellationEventsPage: 1,\n cancellationPaidEventsPage: 1,\n cancellationEventsTotalCount: 0,\n cancellationPaidEventsTotalCount: 0,\n};\n\nconst initialState: UserSessionCancellationState = {\n selectedSessions: [],\n cancellationInProgress: false,\n retractionInProgress: false,\n cancellationError: null,\n retractionError: null,\n ...cancellationState,\n};\n\nexport const cancelScheduledSegments = createAsyncThunk<\n Array,\n void,\n { state: RootState }\n>('sessionCancellation/cancelScheduledSegments', async (_, thunkAPI) => {\n const state = thunkAPI.getState();\n const clientId = state.client?.currentClient?.id || null;\n const providerId = state.provider.provider?.id || null;\n\n const { [RequestType.LongTerm]: scheduleSegments = [] } = groupBy(\n state.sessionCancellation.selectedSessions,\n (item) => item.bookRequestType || RequestType.LongTerm\n );\n\n if (!scheduleSegments.length) {\n return [];\n }\n\n return cancellationApi\n .cancelSessions(clientId, providerId, scheduleSegments)\n .catch((e) => thunkAPI.rejectWithValue(e));\n});\n\nasync function retractBookingSessions(\n api: typeof bookingApi.retractSTSessions,\n sessions: Array\n) {\n if (!sessions.length) {\n return [];\n }\n\n const sessionsByRequest = groupBy(sessions, (item) => item.bookRequestId);\n\n const response = await Promise.all(\n Object.entries(sessionsByRequest).map(([brId, items]) =>\n api(\n +brId,\n items.map((s) => s.id as number)\n // NOTE: catching and returning an empty array of sessions\n // to show exact result of what was successfully retracted and what was failed\n // otherwise SessionsRemovalResults component will show an error for all cancellations if any fail\n ).catch((_err) => ({ sessions: [] }))\n )\n );\n\n return response\n .flatMap((item) => item.sessions)\n .filter((s) => s.statusId === RequestStatus.RETRACTED);\n}\n\nexport const cancelBookingSessions = createAsyncThunk<\n RetractedSessionsResponseType['sessions'],\n void,\n { state: RootState }\n>('sessionCancellation/cancelBookingSessions', async (_, thunkAPI) => {\n const {\n [RequestType.SingleTerm]: stSessions = [],\n [RequestType.OpenSession]: mtSessions = [],\n } = groupBy(\n thunkAPI.getState().sessionCancellation.selectedSessions,\n (item) => item.bookRequestType || RequestType.LongTerm\n );\n\n const [stResult, mtResult] = await Promise.all([\n retractBookingSessions(bookingApi.retractSTSessions, stSessions),\n retractBookingSessions(bookingApi.retractOSSessions, mtSessions),\n ]);\n\n return [...stResult, ...mtResult];\n});\n\nexport const fetchCancellationEvents = createAsyncThunk<\n PaginatedData,\n {\n filters: Partial;\n sorting?: Partial>;\n },\n { state: RootState }\n>(\n 'sessionCancellation/fetchCancellationEvents',\n async ({ filters, sorting }, { getState, rejectWithValue }) => {\n const { providerId, clientId } = filters;\n\n if (!providerId && !clientId) {\n return rejectWithValue(null);\n }\n\n const { cancellationEventsPage: page } = getState().sessionCancellation;\n\n const createdFromDate = moment().subtract(CANCELLATIONS_LAST_DAYS, 'days');\n const providerTitles = ['BT', 'SBT'];\n\n const apiFilters = {\n createdFrom: createdFromDate.format(DATE_FORMAT),\n ...filters,\n };\n\n if (clientId) {\n apiFilters.providerTitles = providerTitles;\n }\n\n return cancellationApi.fetchCancellationEvents(\n apiFilters,\n {\n orderBy: CancellationEventsSort.SessionStart,\n direction: SortingDirection.DESC,\n ...sorting,\n },\n {\n page,\n limit: CANCELLTION_EVENTS_PER_PAGE,\n }\n );\n }\n);\n\nexport const fetchCancellationPaidEvents = createAsyncThunk<\n PaginatedData,\n {\n filters: Partial;\n sorting?: Partial>;\n },\n { state: RootState }\n>(\n 'sessionCancellation/fetchCancellationPaidEvents',\n async ({ filters, sorting }, { getState, rejectWithValue }) => {\n const { providerId } = filters;\n\n if (!providerId) {\n return rejectWithValue(null);\n }\n\n const { cancellationPaidEventsPage: page } = getState().sessionCancellation;\n\n const createdFromDate = moment().subtract(CANCELLATIONS_LAST_DAYS, 'days');\n\n const apiFilters = {\n createdFrom: createdFromDate.format(DATE_FORMAT),\n ...filters,\n };\n\n return cancellationApi.fetchCancellationEvents(\n apiFilters,\n {\n orderBy: CancellationEventsSort.SessionStart,\n direction: SortingDirection.DESC,\n ...sorting,\n },\n {\n page,\n limit: CANCELLTION_EVENTS_PER_PAGE,\n }\n );\n }\n);\n\nconst sessionCancellationSlice = createSlice({\n name: 'sessionCancellation',\n initialState,\n reducers: {\n setSessionsToRemove: (\n state,\n action: PayloadAction\n ) => ({\n ...state,\n selectedSessions: action.payload,\n }),\n selectSessionForRemoval: (\n state,\n action: PayloadAction\n ) => {\n state.selectedSessions = uniqBy(\n [...state.selectedSessions, action.payload],\n (s) => s.segmentId\n );\n },\n unselectSessionForRemoval: (\n state,\n action: PayloadAction<{ segmentId: number }>\n ) => {\n state.selectedSessions = state.selectedSessions.filter(\n (s) => s.segmentId !== action.payload.segmentId\n );\n },\n resetSessionRemoval: () => ({\n ...initialState,\n }),\n setCancellationEventPage: (state, action: PayloadAction) => {\n state.cancellationEventsPage = action.payload;\n },\n setCancellationPaidEventPage: (state, action: PayloadAction) => {\n state.cancellationPaidEventsPage = action.payload;\n },\n resetCancellationEvents: (state) => {\n state.cancellationEvents = [];\n state.cancellationPaidEvents = [];\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(cancelScheduledSegments.pending, (state) => {\n return {\n ...state,\n cancellationInProgress: true,\n cancellationError: null,\n };\n })\n .addCase(cancelScheduledSegments.fulfilled, (state, action) => {\n const { selectedSessions } = state;\n\n const updatedSessions = selectedSessions.map((s) => {\n const update = action.payload.find(\n (result) => result.segmentId === s.segmentId\n );\n\n const updatedOverlapings = s.overlappingSessions?.map(\n (v): ScheduledSession => {\n const updateSegment = action.payload.find(\n (result) => result.segmentId === v.segmentId\n );\n const { isRTO } = updateSegment || {};\n if (updateSegment) {\n return {\n ...v,\n status: isRTO\n ? SessionStatus.TimeOff\n : SessionStatus.Cancelled,\n };\n }\n return { ...v };\n }\n );\n if (update) {\n const { isRTO } = update;\n return {\n ...s,\n cancellationEvent: { id: update.cancellationEventId },\n status: isRTO ? SessionStatus.TimeOff : SessionStatus.Cancelled,\n overlappingSessions: updatedOverlapings || s.overlappingSessions,\n removedBy: update.removedBy,\n };\n }\n return {\n ...s,\n };\n });\n return {\n ...state,\n cancellationInProgress: false,\n selectedSessions: updatedSessions,\n };\n })\n .addCase(cancelScheduledSegments.rejected, (state, action) => {\n return {\n ...state,\n cancellationInProgress: false,\n cancellationError: action.error,\n };\n })\n .addCase(cancelBookingSessions.pending, (state) => {\n return {\n ...state,\n retractionInProgress: true,\n retractionError: null,\n };\n })\n .addCase(cancelBookingSessions.fulfilled, (state, action) => {\n const { selectedSessions } = state;\n const retractedSessions = action.payload;\n\n const updatedSessions = selectedSessions.map((s) => {\n if (!s.isBookRequest || !s.id) {\n return {\n ...s,\n };\n }\n\n const retractedUpdate = retractedSessions.find(\n (item) => item.id === s.id\n );\n return {\n ...s,\n status:\n retractedUpdate &&\n retractedUpdate.statusId === RequestStatus.RETRACTED\n ? SessionStatus.Cancelled\n : SessionStatus.Pending,\n };\n });\n\n return {\n ...state,\n retractionInProgress: false,\n selectedSessions: updatedSessions,\n };\n })\n .addCase(cancelBookingSessions.rejected, (state, action) => {\n return {\n ...state,\n retractionInProgress: false,\n retractionError: action.error,\n };\n })\n .addCase(fetchCancellationEvents.pending, (state) => {\n state.loadingCancellationEvents = true;\n })\n .addCase(fetchCancellationEvents.fulfilled, (state, action) => {\n const {\n items,\n meta: { totalItems },\n } = action.payload;\n\n const page = state.cancellationEventsPage;\n const previousEvents = state.cancellationEvents;\n\n state.cancellationEvents =\n page === 1 ? items : previousEvents.concat(items);\n state.cancellationEventsTotalCount = totalItems;\n state.loadingCancellationEvents = false;\n })\n .addCase(fetchCancellationEvents.rejected, (state) => {\n state.loadingCancellationEvents = false;\n })\n .addCase(fetchCancellationPaidEvents.pending, (state) => {\n state.loadingCancellationPaidEvents = true;\n })\n .addCase(fetchCancellationPaidEvents.fulfilled, (state, action) => {\n const {\n items,\n meta: { totalItems },\n } = action.payload;\n\n const page = state.cancellationPaidEventsPage;\n const previousEvents = state.cancellationPaidEvents;\n\n state.cancellationPaidEvents =\n page === 1 ? items : previousEvents.concat(items);\n state.cancellationPaidEventsTotalCount = totalItems;\n state.loadingCancellationPaidEvents = false;\n })\n .addCase(fetchCancellationPaidEvents.rejected, (state) => {\n state.loadingCancellationPaidEvents = false;\n });\n },\n});\n\nexport const {\n setSessionsToRemove,\n resetSessionRemoval,\n setCancellationEventPage,\n setCancellationPaidEventPage,\n resetCancellationEvents,\n selectSessionForRemoval,\n unselectSessionForRemoval,\n} = sessionCancellationSlice.actions;\n\nexport default sessionCancellationSlice.reducer;\n","import { createAsyncThunk, createSlice, isAnyOf } from '@reduxjs/toolkit';\nimport { MUISortOptions } from 'mui-datatables';\nimport requestsApi, {\n UpdateSubOfferSessionStatusArgs,\n UpdateRequestSessionStatusArgs,\n} from '../../api/requestsApi';\nimport bookingApi from '../../api/bookingApi';\nimport {\n FetchBookingFilters,\n Request,\n RequestStatus,\n RequestType,\n} from '../../types/types';\n\ninterface RequestsListState {\n isInitial: boolean;\n requestsList: Request[];\n requestsLoading: boolean;\n totalCount: number;\n unhandledRequestsCount: number;\n requestsListRequestId: string | undefined;\n updatingSubOfferSessions: number[];\n}\n\nconst initialState: RequestsListState = {\n isInitial: true,\n requestsList: [],\n requestsLoading: false,\n totalCount: 0,\n unhandledRequestsCount: 0,\n requestsListRequestId: undefined,\n updatingSubOfferSessions: [],\n};\n\nexport const fetchUnhandledRequests = createAsyncThunk(\n 'requests/fetchUnhandledRequests',\n () => {\n // in order to show a badge next to the sidebar menu item when there are unhandled requests\n\n const limit = null;\n const offset = null;\n const filters = {\n statusId: [RequestStatus.PENDING],\n };\n return requestsApi.fetchAllRequests(\n filters,\n false,\n true,\n [RequestType.SingleTerm, RequestType.LongTerm],\n limit,\n offset,\n {\n name: 'createdAt',\n direction: 'desc',\n }\n );\n }\n);\n\nexport const fetchRequestsList = createAsyncThunk(\n 'requests/fetchRequestsList',\n (arg: {\n filters: { statusId: RequestStatus[]; excludeStatus?: RequestStatus[] };\n onlyMyRequest: boolean;\n onlyIncompleteRequests: boolean;\n requestType?: RequestType | RequestType[] | null;\n limit?: number;\n offset?: number;\n sortOrder?: MUISortOptions;\n }) => {\n const {\n filters,\n onlyMyRequest,\n onlyIncompleteRequests,\n requestType = null,\n limit = 10,\n offset = 0,\n sortOrder = {\n name: 'statusUpdatedAt',\n direction: 'desc',\n },\n } = arg;\n\n return requestsApi.fetchAllRequests(\n filters,\n onlyMyRequest,\n onlyIncompleteRequests,\n requestType,\n limit,\n offset,\n sortOrder\n );\n }\n);\n\nexport const fetchClientRequests = createAsyncThunk(\n 'requests/fetchClientRequests',\n async (filters: FetchBookingFilters) => {\n return bookingApi.fetchBookings(filters);\n }\n);\n\nexport const updateRequestStatus = createAsyncThunk(\n 'requests/updateRequestStatus',\n async (\n arg: {\n requestId: number;\n newStatus: RequestStatus;\n shouldNotify: boolean;\n selectedOption?: number;\n updateAvailability?: boolean;\n },\n { rejectWithValue }\n ) => {\n const {\n requestId,\n newStatus,\n shouldNotify,\n selectedOption,\n updateAvailability,\n } = arg;\n return requestsApi\n .updateRequestStatus(\n requestId,\n newStatus,\n shouldNotify,\n selectedOption,\n updateAvailability\n )\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const updateRequestSessionStatus = createAsyncThunk(\n 'requests/updateRequestSessionStatus',\n async (arg: UpdateRequestSessionStatusArgs, { rejectWithValue }) => {\n return requestsApi\n .updateRequestSessionStatus(arg)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const updateSubOfferSessionStatus = createAsyncThunk(\n 'requests/updateSubOfferSessionStatus',\n async (arg: UpdateSubOfferSessionStatusArgs, { rejectWithValue }) => {\n return requestsApi\n .updateSubOfferSessionStatus(arg)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nconst requestsListSlice = createSlice({\n name: 'requests',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchUnhandledRequests.fulfilled, (state, action) => {\n return {\n ...state,\n unhandledRequestsCount: action.payload?.length,\n };\n })\n .addCase(fetchClientRequests.pending, (state, action) => {\n return {\n ...state,\n isInitial: false,\n requestsLoading: true,\n };\n })\n .addCase(fetchClientRequests.rejected, (state, action) => {\n return {\n ...state,\n requestsLoading: false,\n };\n })\n .addCase(fetchClientRequests.fulfilled, (state, action) => {\n const { payload } = action;\n state.requestsLoading = false;\n\n if (Array.isArray(payload)) {\n state.requestsList = payload;\n state.totalCount = payload.length;\n } else {\n state.requestsList = payload.rows;\n state.totalCount = payload.count;\n }\n })\n .addCase(updateRequestStatus.pending, (state, action) => {\n return {\n ...state,\n requestsLoading: true,\n };\n })\n .addCase(updateRequestStatus.rejected, (state, action) => {\n return {\n ...state,\n requestsLoading: false,\n };\n })\n .addCase(updateRequestStatus.fulfilled, (state, action) => {\n return {\n ...state,\n requestsLoading: false,\n };\n })\n .addCase(fetchRequestsList.pending, (state, action) => {\n return {\n ...state,\n isInitial: false,\n requestsLoading: true,\n requestsListRequestId: action.meta.requestId,\n totalCount: 0,\n };\n })\n .addCase(fetchRequestsList.rejected, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.requestsListRequestId &&\n state.requestsListRequestId === requestId\n ) {\n return {\n ...state,\n requestsLoading: false,\n };\n }\n return state;\n })\n .addCase(fetchRequestsList.fulfilled, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.requestsListRequestId &&\n state.requestsListRequestId === requestId\n ) {\n return {\n ...state,\n requestsLoading: false,\n requestsList: action.payload.rows,\n totalCount: action.payload.count,\n };\n }\n return state;\n })\n .addCase(updateRequestSessionStatus.pending, (state) => {\n return {\n ...state,\n requestsLoading: true,\n };\n })\n .addCase(updateRequestSessionStatus.fulfilled, (state, action) => {\n return {\n ...state,\n requestsLoading: false,\n };\n })\n .addCase(updateRequestSessionStatus.rejected, (state) => {\n return {\n ...state,\n requestsLoading: false,\n };\n })\n .addCase(updateSubOfferSessionStatus.pending, (state, action) => {\n state.updatingSubOfferSessions = [\n ...state.updatingSubOfferSessions,\n ...action.meta.arg.sessionIds,\n ];\n })\n .addMatcher(\n isAnyOf(\n updateSubOfferSessionStatus.fulfilled,\n updateSubOfferSessionStatus.rejected\n ),\n (state, action) => {\n const filterOnlyUpdatingSessionsList = state.updatingSubOfferSessions.filter(\n (sessionId) => !action.meta.arg.sessionIds.includes(sessionId)\n );\n\n state.updatingSubOfferSessions = [...filterOnlyUpdatingSessionsList];\n }\n );\n },\n});\n\nexport default requestsListSlice.reducer;\n","import { DayOfWeekId } from '../../../constants';\n\nexport type DayOfWeekLabels = Record;\nexport const DayOfWeekValues = Object.values(\n DayOfWeekId\n).filter((id): id is DayOfWeekId => Number.isInteger(id));\nexport const WeekendIds = [DayOfWeekId.Sunday, DayOfWeekId.Saturday];\n\nexport const DayOfWeekLabelsVariant1: DayOfWeekLabels = {\n [DayOfWeekId.Sunday]: 'SU',\n [DayOfWeekId.Monday]: 'MO',\n [DayOfWeekId.Tuesday]: 'TU',\n [DayOfWeekId.Wednesday]: 'WE',\n [DayOfWeekId.Thursday]: 'TH',\n [DayOfWeekId.Friday]: 'FR',\n [DayOfWeekId.Saturday]: 'SA',\n};\n\nexport const DayOfWeekLabelsVariant2: DayOfWeekLabels = {\n [DayOfWeekId.Sunday]: 'S',\n [DayOfWeekId.Monday]: 'M',\n [DayOfWeekId.Tuesday]: 'T',\n [DayOfWeekId.Wednesday]: 'W',\n [DayOfWeekId.Thursday]: 'T',\n [DayOfWeekId.Friday]: 'F',\n [DayOfWeekId.Saturday]: 'S',\n};\n\nexport const DayOfWeekLabelsVariant3: DayOfWeekLabels = {\n [DayOfWeekId.Sunday]: 'Sun',\n [DayOfWeekId.Monday]: 'Mon',\n [DayOfWeekId.Tuesday]: 'Tue',\n [DayOfWeekId.Wednesday]: 'Wed',\n [DayOfWeekId.Thursday]: 'Thu',\n [DayOfWeekId.Friday]: 'Fri',\n [DayOfWeekId.Saturday]: 'Sat',\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(\"rect\", {\n width: 74,\n height: 17,\n rx: 8,\n fill: \"#E0E0E0\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M7.3345 12.135C8.0815 12.135 8.6995 11.946 9.1885 11.568C9.6805 11.19 10.0225 10.6815 10.2145 10.0425L9.2605 9.786C9.1315 10.239 8.9065 10.5945 8.5855 10.8525C8.2645 11.1105 7.8475 11.2395 7.3345 11.2395C6.8755 11.2395 6.4915 11.136 6.1825 10.929C5.8765 10.722 5.6455 10.4325 5.4895 10.0605C5.3365 9.6885 5.2615 9.255 5.2645 8.76C5.2675 8.265 5.3455 7.8315 5.4985 7.4595C5.6515 7.0875 5.881 6.798 6.187 6.591C6.493 6.384 6.8755 6.2805 7.3345 6.2805C7.8475 6.2805 8.2645 6.4095 8.5855 6.6675C8.9065 6.9255 9.1315 7.281 9.2605 7.734L10.2145 7.4775C10.0225 6.8385 9.6805 6.33 9.1885 5.952C8.6995 5.574 8.0815 5.385 7.3345 5.385C6.6865 5.385 6.1345 5.5275 5.6785 5.8125C5.2225 6.0975 4.873 6.4935 4.63 7.0005C4.39 7.5045 4.27 8.091 4.27 8.76C4.27 9.429 4.39 10.017 4.63 10.524C4.873 11.028 5.2225 11.4225 5.6785 11.7075C6.1345 11.9925 6.6865 12.135 7.3345 12.135ZM13.9987 12.135C14.6467 12.135 15.1987 11.9925 15.6547 11.7075C16.1107 11.4225 16.4587 11.028 16.6987 10.524C16.9387 10.017 17.0587 9.429 17.0587 8.76C17.0587 8.091 16.9387 7.5045 16.6987 7.0005C16.4587 6.4935 16.1107 6.0975 15.6547 5.8125C15.1987 5.5275 14.6467 5.385 13.9987 5.385C13.3507 5.385 12.7987 5.5275 12.3427 5.8125C11.8867 6.0975 11.5372 6.4935 11.2942 7.0005C11.0542 7.5045 10.9342 8.091 10.9342 8.76C10.9342 9.429 11.0542 10.017 11.2942 10.524C11.5372 11.028 11.8867 11.4225 12.3427 11.7075C12.7987 11.9925 13.3507 12.135 13.9987 12.135ZM13.9987 11.2395C13.3117 11.2335 12.7942 11.004 12.4462 10.551C12.1012 10.098 11.9302 9.501 11.9332 8.76C11.9362 8.265 12.0127 7.8315 12.1627 7.4595C12.3157 7.0845 12.5452 6.7935 12.8512 6.5865C13.1572 6.3765 13.5397 6.2745 13.9987 6.2805C14.6887 6.2835 15.2047 6.5115 15.5467 6.9645C15.8887 7.4175 16.0597 8.016 16.0597 8.76C16.0597 9.255 15.9832 9.69 15.8302 10.065C15.6802 10.437 15.4522 10.7265 15.1462 10.9335C14.8402 11.1405 14.4577 11.2425 13.9987 11.2395ZM19.2949 12H20.6494L22.7554 5.52H21.7789L19.9609 11.0505L18.1654 5.52H17.1889L19.2949 12ZM23.614 12H24.5545V5.52H23.614V12ZM25.9959 12H28.0254C28.0854 12 28.1964 11.9985 28.3584 11.9955C28.5234 11.9925 28.6809 11.9805 28.8309 11.9595C29.3379 11.8935 29.7639 11.712 30.1089 11.415C30.4569 11.115 30.7194 10.7355 30.8964 10.2765C31.0734 9.8145 31.1619 9.309 31.1619 8.76C31.1619 8.208 31.0734 7.7025 30.8964 7.2435C30.7194 6.7815 30.4569 6.402 30.1089 6.105C29.7639 5.805 29.3379 5.6235 28.8309 5.5605C28.6809 5.5395 28.5234 5.5275 28.3584 5.5245C28.1964 5.5215 28.0854 5.52 28.0254 5.52H25.9959V12ZM26.9589 11.1045V6.4155H28.0254C28.1244 6.4155 28.2444 6.4185 28.3854 6.4245C28.5294 6.4275 28.6554 6.4395 28.7634 6.4605C29.0874 6.5205 29.3514 6.6615 29.5554 6.8835C29.7624 7.1025 29.9154 7.3755 30.0144 7.7025C30.1134 8.0265 30.1629 8.379 30.1629 8.76C30.1629 9.129 30.1149 9.477 30.0189 9.804C29.9229 10.131 29.7714 10.407 29.5644 10.632C29.3604 10.854 29.0934 10.9965 28.7634 11.0595C28.6554 11.0805 28.5309 11.094 28.3899 11.1C28.2519 11.103 28.1304 11.1045 28.0254 11.1045H26.9589ZM35.7125 12H37.067L39.173 5.52H38.1965L36.3785 11.0505L34.583 5.52H33.6065L35.7125 12ZM38.8588 12H39.8353L40.3078 10.5375H42.9673L43.4488 12H44.4253L42.3193 5.52H40.9648L38.8588 12ZM40.5958 9.6555L41.6308 6.4605L42.6793 9.6555H40.5958ZM47.8514 12.135C48.5984 12.135 49.2164 11.946 49.7054 11.568C50.1974 11.19 50.5394 10.6815 50.7314 10.0425L49.7774 9.786C49.6484 10.239 49.4234 10.5945 49.1024 10.8525C48.7814 11.1105 48.3644 11.2395 47.8514 11.2395C47.3924 11.2395 47.0084 11.136 46.6994 10.929C46.3934 10.722 46.1624 10.4325 46.0064 10.0605C45.8534 9.6885 45.7784 9.255 45.7814 8.76C45.7844 8.265 45.8624 7.8315 46.0154 7.4595C46.1684 7.0875 46.3979 6.798 46.7039 6.591C47.0099 6.384 47.3924 6.2805 47.8514 6.2805C48.3644 6.2805 48.7814 6.4095 49.1024 6.6675C49.4234 6.9255 49.6484 7.281 49.7774 7.734L50.7314 7.4775C50.5394 6.8385 50.1974 6.33 49.7054 5.952C49.2164 5.574 48.5984 5.385 47.8514 5.385C47.2034 5.385 46.6514 5.5275 46.1954 5.8125C45.7394 6.0975 45.3899 6.4935 45.1469 7.0005C44.9069 7.5045 44.7869 8.091 44.7869 8.76C44.7869 9.429 44.9069 10.017 45.1469 10.524C45.3899 11.028 45.7394 11.4225 46.1954 11.7075C46.6514 11.9925 47.2034 12.135 47.8514 12.135Z\",\n fill: \"#3C1053\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M63.5296 5.28027C63.8408 4.96908 64.3454 4.96908 64.6566 5.28027C64.964 5.58766 64.9677 6.08368 64.6679 6.39569L60.4262 11.6978C60.42 11.7055 60.4135 11.7128 60.4066 11.7197C60.0954 12.0309 59.5908 12.0309 59.2796 11.7197L56.4678 8.90788C56.1566 8.59668 56.1566 8.09212 56.4678 7.78092C56.779 7.46973 57.2835 7.46973 57.5947 7.78092L59.8191 10.0053L63.5085 5.30411C63.5151 5.29575 63.5221 5.28779 63.5296 5.28027Z\",\n fill: \"#3C1053\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M62.5517 10.7418L63.5296 11.7197C63.8408 12.0309 64.3454 12.0309 64.6566 11.7197C64.6635 11.7128 64.67 11.7055 64.6762 11.6978L68.9179 6.39569C69.2177 6.08368 69.214 5.58766 68.9066 5.28027C68.5954 4.96908 68.0908 4.96908 67.7796 5.28027C67.7721 5.28779 67.7651 5.29575 67.7585 5.30411L64.0691 10.0053L63.5534 9.48961L62.5517 10.7418Z\",\n fill: \"#3C1053\"\n});\n\nvar SvgCovidBadge = function SvgCovidBadge(_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: 74,\n height: 17,\n viewBox: \"0 0 74 17\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgCovidBadge, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/covid-badge.e579f8c6.svg\";\nexport { ForwardRef as ReactComponent };","import React from 'react';\nimport { makeStyles, SvgIcon, SvgIconProps, Theme } from '@material-ui/core';\nimport { ReactComponent as CovidBadge } from '../../../assets/covid-badge.svg';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n icon: { height: 17, width: 74 },\n}));\n\nconst CovidBadgeIcon = (props: SvgIconProps) => {\n const classes = useStyles();\n return (\n \n );\n};\n\nexport default CovidBadgeIcon;\n","import { useAuth } from './useAuth';\nimport { ac, Resources } from '../accessControl/acl';\n\ntype PermissionType = 'readAny' | 'readOwn' | 'updateAny' | 'updateOwn';\n\nconst getPermission = (\n permissionType: PermissionType,\n groups: string[],\n resource: Resources\n) => {\n switch (permissionType) {\n case 'readOwn':\n return ac.can(groups).readOwn(resource);\n case 'updateAny':\n return ac.can(groups).updateAny(resource);\n case 'updateOwn':\n return ac.can(groups).updateOwn(resource);\n case 'readAny':\n default:\n return ac.can(groups).readAny(resource);\n }\n};\n\nexport default function usePermission() {\n const { user } = useAuth();\n const checkPermission = (\n resource: Resources,\n permissionType: PermissionType = 'readAny',\n permissionAttributes?: string[]\n ) => {\n const groups = user?.getSignInUserSession()?.getIdToken().payload[\n 'cognito:groups'\n ];\n\n if (!groups) {\n return false;\n }\n\n const permission = getPermission(permissionType, groups, resource);\n\n if (!permission) {\n return false;\n }\n\n if (permissionAttributes) {\n return permissionAttributes.every(\n (attr) => permission && permission.attributes.includes(attr)\n );\n }\n\n return permission.granted;\n };\n\n return checkPermission;\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(\"rect\", {\n x: 1,\n y: 1,\n width: 56,\n height: 16,\n rx: 8,\n fill: \"#EDEDED\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M7.77 13H11.18C11.9353 13 12.5183 12.7892 12.929 12.3675C13.3433 11.9458 13.5505 11.3867 13.5505 10.69C13.5505 10.2683 13.446 9.8925 13.237 9.5625C13.028 9.2325 12.7273 8.98317 12.335 8.8145C12.5953 8.66417 12.8007 8.44967 12.951 8.171C13.1013 7.89233 13.1765 7.5715 13.1765 7.2085C13.1765 6.84917 13.0903 6.50817 12.918 6.1855C12.7457 5.85917 12.489 5.59333 12.148 5.388C11.8107 5.18267 11.389 5.08 10.883 5.08H7.77V13ZM8.936 8.314V6.1635H10.8665C11.2112 6.1635 11.4862 6.2625 11.6915 6.4605C11.8968 6.6585 11.9995 6.9115 11.9995 7.2195C11.9995 7.56417 11.8895 7.83367 11.6695 8.028C11.4532 8.21867 11.1855 8.314 10.8665 8.314H8.936ZM8.936 11.9055V9.3975H11.0755C11.4715 9.3975 11.7868 9.52033 12.0215 9.766C12.2562 10.008 12.3735 10.3087 12.3735 10.668C12.3735 11.053 12.2433 11.3555 11.983 11.5755C11.7227 11.7955 11.3963 11.9055 11.004 11.9055H8.936ZM18.0605 13.165C18.9735 13.165 19.7288 12.934 20.3265 12.472C20.9278 12.01 21.3458 11.3885 21.5805 10.6075L20.4145 10.294C20.2568 10.8477 19.9818 11.2822 19.5895 11.5975C19.1972 11.9128 18.6875 12.0705 18.0605 12.0705C17.4995 12.0705 17.0302 11.944 16.6525 11.691C16.2785 11.438 15.9962 11.0842 15.8055 10.6295C15.6185 10.1748 15.5268 9.645 15.5305 9.04C15.5342 8.435 15.6295 7.90517 15.8165 7.4505C16.0035 6.99583 16.284 6.642 16.658 6.389C17.032 6.136 17.4995 6.0095 18.0605 6.0095C18.6875 6.0095 19.1972 6.16717 19.5895 6.4825C19.9818 6.79783 20.2568 7.23233 20.4145 7.786L21.5805 7.4725C21.3458 6.6915 20.9278 6.07 20.3265 5.608C19.7288 5.146 18.9735 4.915 18.0605 4.915C17.2685 4.915 16.5938 5.08917 16.0365 5.4375C15.4792 5.78583 15.052 6.26983 14.755 6.8895C14.4617 7.5055 14.315 8.22233 14.315 9.04C14.315 9.85767 14.4617 10.5763 14.755 11.196C15.052 11.812 15.4792 12.2942 16.0365 12.6425C16.5938 12.9908 17.2685 13.165 18.0605 13.165ZM22.9002 13H26.3102C27.0655 13 27.6485 12.7892 28.0592 12.3675C28.4735 11.9458 28.6807 11.3867 28.6807 10.69C28.6807 10.2683 28.5762 9.8925 28.3672 9.5625C28.1582 9.2325 27.8575 8.98317 27.4652 8.8145C27.7255 8.66417 27.9308 8.44967 28.0812 8.171C28.2315 7.89233 28.3067 7.5715 28.3067 7.2085C28.3067 6.84917 28.2205 6.50817 28.0482 6.1855C27.8758 5.85917 27.6192 5.59333 27.2782 5.388C26.9408 5.18267 26.5192 5.08 26.0132 5.08H22.9002V13ZM24.0662 8.314V6.1635H25.9967C26.3413 6.1635 26.6163 6.2625 26.8217 6.4605C27.027 6.6585 27.1297 6.9115 27.1297 7.2195C27.1297 7.56417 27.0197 7.83367 26.7997 8.028C26.5833 8.21867 26.3157 8.314 25.9967 8.314H24.0662ZM24.0662 11.9055V9.3975H26.2057C26.6017 9.3975 26.917 9.52033 27.1517 9.766C27.3863 10.008 27.5037 10.3087 27.5037 10.668C27.5037 11.053 27.3735 11.3555 27.1132 11.5755C26.8528 11.7955 26.5265 11.9055 26.1342 11.9055H24.0662ZM29.3352 13H30.5287L31.1062 11.2125H34.3567L34.9452 13H36.1387L33.5647 5.08H31.9092L29.3352 13ZM31.4582 10.1345L32.7232 6.2295L34.0047 10.1345H31.4582Z\",\n fill: \"#5096F1\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M45.0005 3L46.252 3.64822L47.6455 3.85942L48.277 5.11947L49.2802 6.10942L49.0505 7.5L49.2802 8.89058L48.277 9.88053L47.6455 11.1406L46.252 11.3518L45.0005 12L43.7489 11.3518L42.3554 11.1406L41.7239 9.88053L40.7207 8.89058L40.9505 7.5L40.7207 6.10942L41.7239 5.11947L42.3554 3.85942L43.7489 3.64822L45.0005 3Z\",\n fill: \"#5096F1\"\n});\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M42 11.8455V15.0001L45 14.2501L48 15.0001V11.8455L46.4864 12.0749L45 12.8447L43.5136 12.0749L42 11.8455Z\",\n fill: \"#5096F1\"\n});\n\nvar _ref6 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M9 2H49V0H9V2ZM49 16H9V18H49V16ZM9 16C5.13401 16 2 12.866 2 9H0C0 13.9706 4.02944 18 9 18V16ZM56 9C56 12.866 52.866 16 49 16V18C53.9706 18 58 13.9706 58 9H56ZM49 2C52.866 2 56 5.13401 56 9H58C58 4.02944 53.9706 0 49 0V2ZM9 0C4.02944 0 0 4.02944 0 9H2C2 5.13401 5.13401 2 9 2V0Z\",\n fill: \"#E0E0E0\"\n});\n\nvar SvgBcbaBadge = function SvgBcbaBadge(_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: 58,\n height: 18,\n viewBox: \"0 0 58 18\",\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(SvgBcbaBadge, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/BCBA-badge.76f0a110.svg\";\nexport { ForwardRef as ReactComponent };","import React from 'react';\nimport { makeStyles, SvgIcon, SvgIconProps, Theme } from '@material-ui/core';\nimport { ReactComponent as BCBABadge } from '../../../assets/BCBA-badge.svg';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n icon: { height: 17, width: 74 },\n}));\n\nconst BCBABadgeIcon = (props: SvgIconProps) => {\n const classes = useStyles();\n return (\n \n );\n};\n\nexport default BCBABadgeIcon;\n","import React from 'react';\nimport { SvgIconProps } from '@material-ui/core';\nimport { Provider } from '../../../types/types';\nimport BCBABadgeIcon from './BCBABadgeIcon';\nimport { isBCBA } from '../../../utils/helpers';\n\ninterface ProviderBCBABadgeProps extends SvgIconProps {\n provider: Pick;\n}\n\nconst ProviderBCBABadge = (props: ProviderBCBABadgeProps) => {\n const { provider, ...rest } = props;\n const showBadge = isBCBA(provider);\n\n return showBadge ? : null;\n};\n\nexport default ProviderBCBABadge;\n","import requester from './requester';\n\nconst fetchMaintenance = async () => {\n return requester.get(`maintenance`).then((response) => response.json());\n};\n\nexport default { fetchMaintenance };\n","import { createSlice, PayloadAction } from '@reduxjs/toolkit';\nimport { AppThunk } from '../store';\nimport maintenanceApi from '../../api/maintenanceApi';\n\nexport interface MaintenanceState {\n status: boolean;\n}\n\nconst initialState: MaintenanceState = {\n status: false,\n};\n\nconst maintenanceSlice = createSlice({\n name: 'maintenance',\n initialState,\n reducers: {\n setMaintenanceStatus: (state, action: PayloadAction) => ({\n ...state,\n status: action.payload,\n }),\n },\n});\n\nexport const { setMaintenanceStatus } = maintenanceSlice.actions;\n\nexport default maintenanceSlice.reducer;\n\nexport const setMaintenance = (status: boolean): AppThunk => (\n dispatch,\n getState\n) => {\n const isMaintenanceOn = getState().maintenance.status;\n if (isMaintenanceOn !== status) {\n dispatch(setMaintenanceStatus(status));\n }\n};\n\nexport const fetchMaintenance = (): AppThunk => async (dispatch) => {\n try {\n const { underMaintenance } = await maintenanceApi.fetchMaintenance();\n dispatch(setMaintenanceStatus(underMaintenance));\n } catch (e: any) {\n console.error(e);\n }\n};\n","import queryString from 'query-string';\nimport requester from './requester';\nimport { Notification, NotificationPaginatedData } from '../types/types';\n\nconst fetchNotifications = async (\n filters: {\n isSeen?: boolean;\n },\n paging?: {\n page: number;\n rowsPerPage: number;\n }\n): Promise => {\n const query = queryString.stringify(\n {\n isSeen: filters.isSeen,\n page: paging?.page,\n limit: paging?.rowsPerPage,\n },\n { arrayFormat: 'bracket' }\n );\n\n return requester\n .get(`notifications?${query}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchUnreadCount = async (): Promise => {\n const query = queryString.stringify(\n { isSeen: false },\n { arrayFormat: 'bracket' }\n );\n\n return requester\n .get(`notifications/count?${query}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst bulkUpdateIsSeen = async (\n isSeen: boolean,\n ids: number[]\n): Promise[]> => {\n return requester\n .put(`notifications`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ isSeen, ids }),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n fetchNotifications,\n fetchUnreadCount,\n bulkUpdateIsSeen,\n};\n","export enum SessionUpdateTypeId {\n ProviderCancel = 1,\n ClientCancel = 2,\n ProviderNotCleared = 3,\n InformedByBCBA = 4,\n TimeChange = 5,\n LocationChange = 6,\n Other = 7,\n}\n\nexport enum ChangeFrequency {\n OneTime = 'oneTime',\n Recurring = 'recurring',\n}\n\nexport enum ChangedBy {\n client = 'client',\n provider = 'provider',\n}\n\nexport interface SessionUpdateClientCancelData {\n notifiedDate: Date;\n}\n\nexport interface SessionUpdateProviderNotClearedData {\n notifiedDate: Date;\n}\n\nexport interface SessionUpdateInformedByBCBAData {\n notifiedDate: Date;\n}\n\nexport type SessionUpdateLocationChangeData =\n | {\n isLocationChangedForEntireDuration: true;\n newLocationAddress: string;\n notifiedDate: Date;\n }\n | {\n isLocationChangedForEntireDuration: false;\n firstLocationAddress: string;\n firstLocationStartTime: string;\n firstLocationEndTime: string;\n secondLocationAddress: string;\n secondLocationStartTime: string;\n secondLocationEndTime: string;\n notifiedDate: Date;\n };\n\nexport interface SessionUpdateTimeChangeData {\n changedBy: ChangedBy;\n startTime: string;\n endTime: string;\n changeFrequency: ChangeFrequency;\n changeAppliedFrom: Date | undefined;\n notifiedDate: Date | undefined;\n}\n\nexport interface SessionUpdateOtherData {\n details: string;\n}\n\nexport type SessionUpdateDataByType =\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.ClientCancel;\n updateData: SessionUpdateClientCancelData;\n }\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.ProviderNotCleared;\n updateData: SessionUpdateProviderNotClearedData;\n }\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.InformedByBCBA;\n updateData: SessionUpdateInformedByBCBAData;\n }\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.TimeChange;\n updateData: SessionUpdateTimeChangeData;\n }\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.LocationChange;\n updateData: SessionUpdateLocationChangeData;\n }\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.Other;\n updateData: SessionUpdateOtherData;\n }\n | {\n sessionUpdateTypeId: SessionUpdateTypeId.ProviderCancel;\n updateData: null;\n };\n\nexport enum JiraTicketStasusId {\n Open = '1',\n ResponseReceived = '10402',\n WaitingOnResponse = '10218',\n Done = '10001',\n}\ninterface JiraItemWithIssue {\n jiraTicketId?: string;\n jiraTicketStatusId?: JiraTicketStasusId;\n}\n\nexport type SessionUpdate = {\n id: number;\n segmentId: number;\n sessionUpdateType?: {\n name: string;\n };\n jiraItem?: JiraItemWithIssue;\n} & SessionUpdateDataByType;\n\nexport type SessionUpdatePayload = Pick<\n SessionUpdate,\n 'sessionUpdateTypeId' | 'updateData'\n>;\n","import React from 'react';\nimport { Box, CircularProgress, makeStyles, Theme } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n loadingContainer: {\n display: 'flex',\n height: '100%',\n '& > * + *': {\n marginLeft: theme.spacing(2),\n },\n width: '100%',\n justifyContent: 'center',\n alignItems: 'center',\n paddingTop: theme.spacing(2),\n paddingBottom: theme.spacing(2),\n },\n}));\n\nconst CustomLoading = () => {\n const classes = useStyles();\n return (\n \n \n \n );\n};\n\nexport default CustomLoading;\n","import {\n createAsyncThunk,\n createSlice,\n isAnyOf,\n PayloadAction,\n} from '@reduxjs/toolkit';\nimport moment from 'moment';\nimport {\n MyScheduleViewMode,\n PageMode,\n} from '../../commonPages/MySchedule/types/types';\nimport { LocalStorageKeys, ScheduledSession } from '../../types/types';\nimport { getWeekRange } from '../../commonPages/MySchedule/utils/helpers';\nimport { DATE_FORMAT, getFirstSessionAfter } from '../../utils/helpers';\nimport scheduleApi from '../../api/scheduleApi';\nimport { TWO_WEEKS } from '../../utils/constants';\nimport { getRemoveSessionVariant } from '../../commonPages/MySchedule/utils/statusHelpers';\n\ninterface ScheduleState {\n pageMode: PageMode;\n viewMode: MyScheduleViewMode;\n showDetails: boolean;\n sessionsToPreviewIds: Array;\n minDate: moment.Moment;\n maxDate: moment.Moment;\n startOfWeek: moment.Moment;\n pickerValue: { startDate: Date; endDate: Date };\n scheduleByWeek: ScheduledSession[] | null;\n scheduleByWeekLoading: boolean;\n}\n\nconst initialState: ScheduleState = {\n pageMode: PageMode.schedule,\n viewMode:\n (localStorage.getItem(\n LocalStorageKeys.PREFERRED_VIEW_MODE_STORAGE_KEY\n ) as MyScheduleViewMode) || MyScheduleViewMode.list,\n showDetails: false,\n sessionsToPreviewIds: [],\n minDate: moment(),\n maxDate: moment(),\n startOfWeek: moment().startOf('week'),\n pickerValue: {\n startDate: moment().startOf('week').toDate(),\n endDate: moment().endOf('week').toDate(),\n },\n scheduleByWeek: null,\n scheduleByWeekLoading: false,\n};\n\nexport const fetchClientScheduleForWeek = createAsyncThunk(\n 'schedule/fetchClientScheduleForWeek',\n async (arg: { clientId: number; startDate: string }) => {\n return scheduleApi.fetchClientFullSchedule(\n arg.clientId,\n arg.startDate,\n moment(arg.startDate).endOf('week').format(DATE_FORMAT),\n true\n );\n }\n);\n\n// Placeholder for provider's weekly schedule API.\nexport const fetchProviderScheduleForWeek = createAsyncThunk(\n 'schedule/fetchProviderScheduleForWeek',\n async (arg: { providerId: number; startDate: string }) => {\n return scheduleApi.fetchProviderFullSchedule({\n providerId: arg.providerId,\n startDate: arg.startDate,\n endDate: moment(arg.startDate).endOf('week').format(DATE_FORMAT),\n });\n }\n);\n\nexport const scheduleSlice = createSlice({\n name: 'sessionLog',\n initialState,\n reducers: {\n setInitialStartTime(state) {\n state.startOfWeek = moment().local().startOf('week');\n },\n setSchedePageMode: (\n state,\n action: PayloadAction\n ) => {\n state.pageMode = action.payload;\n if (action.payload === PageMode.temporary) {\n state.viewMode = MyScheduleViewMode.grid;\n }\n },\n setScheduleViewMode: (\n state,\n action: PayloadAction\n ) => {\n localStorage.setItem(\n LocalStorageKeys.PREFERRED_VIEW_MODE_STORAGE_KEY,\n action.payload\n );\n state.viewMode = action.payload;\n },\n showSessionsDetails: (\n state,\n action: PayloadAction\n ) => {\n state.sessionsToPreviewIds = action.payload;\n state.showDetails = true;\n },\n hideSessionsDetails: (state) => {\n state.showDetails = false;\n },\n shiftScheduleWeek: (state, action: PayloadAction<1 | -1>) => {\n const [weekStart, weekEnd] = getWeekRange(\n state.startOfWeek.clone().add({ week: action.payload })\n );\n state.startOfWeek = state.startOfWeek\n .clone()\n .add({ week: action.payload });\n state.pickerValue = {\n startDate: weekStart,\n endDate: weekEnd,\n };\n },\n setScheduleStartOfWeek: (state, action: PayloadAction) => {\n const startOfWeek = moment(action.payload).startOf('week');\n state.startOfWeek = startOfWeek;\n state.pickerValue = {\n startDate: getWeekRange(startOfWeek)[0],\n endDate: getWeekRange(startOfWeek)[1],\n };\n },\n setScheduleWeekRange: (\n state,\n action: PayloadAction\n ) => {\n const formattedStartDate = moment(action.payload.startDate)\n .local()\n .format(DATE_FORMAT);\n\n state.pickerValue = action.payload;\n state.startOfWeek = moment(formattedStartDate);\n },\n setScheduleMaxDate: (\n state,\n action: PayloadAction\n ) => {\n state.maxDate = action.payload;\n },\n },\n extraReducers: (builder) =>\n builder\n .addMatcher(\n isAnyOf(\n fetchClientScheduleForWeek.pending,\n fetchProviderScheduleForWeek.pending\n ),\n (state) => {\n state.scheduleByWeekLoading = true;\n }\n )\n .addMatcher(\n isAnyOf(\n fetchClientScheduleForWeek.fulfilled,\n fetchProviderScheduleForWeek.fulfilled\n ),\n (state, action) => {\n if (action.payload === null) {\n state.scheduleByWeek = null;\n } else {\n const firstTimeOffSession = getFirstSessionAfter({\n sessions: action.payload,\n after: TWO_WEEKS,\n });\n\n state.scheduleByWeek = action.payload.map((session) => {\n const removeSessionVariant = getRemoveSessionVariant(session);\n\n const { segmentStartUtc, segmentEndUtc } = session;\n const sessionStart = moment(segmentStartUtc);\n const sessionEnd = moment(segmentEndUtc);\n const now = moment().utc();\n\n const isActiveSession = now.isBetween(sessionStart, sessionEnd);\n\n return {\n ...session,\n removeSessionVariant,\n isFirstTimeOff:\n firstTimeOffSession?.segmentId === session.segmentId,\n isActiveSession,\n };\n });\n }\n state.scheduleByWeekLoading = false;\n }\n )\n .addMatcher(\n isAnyOf(\n fetchClientScheduleForWeek.rejected,\n fetchProviderScheduleForWeek.rejected\n ),\n (state) => {\n state.scheduleByWeekLoading = false;\n }\n ),\n});\n\nexport const {\n setSchedePageMode,\n showSessionsDetails,\n hideSessionsDetails,\n setScheduleStartOfWeek,\n shiftScheduleWeek,\n setScheduleWeekRange,\n setScheduleMaxDate,\n setScheduleViewMode,\n setInitialStartTime,\n} = scheduleSlice.actions;\n\nexport default scheduleSlice.reducer;\n","import { cloneDeep, max } from 'lodash';\nimport moment from 'moment';\nimport { TimeBlock } from '../../redux/modules/adminSettings';\nimport { BlockCoords } from '../../types/types';\nimport {\n DATE_FORMAT,\n DATE_FORMAT_US,\n TIME_FORMAT_24HR,\n} from '../../utils/helpers';\nimport { DayOfWeekId } from '../constants';\nimport { AvailabilityBlock, AvailabilityStatus } from '../types';\n\nexport const getTimeBlockDayOfWeekKey = ({\n timeBlockId,\n dayOfWeekId,\n}: BlockCoords) => {\n return dayOfWeekId * 3 + (timeBlockId - 1);\n};\n\nexport const sortAvailabilityBlocks = (\n availabilityBlocks: Partial[]\n) => {\n const sortedAvailabilityBlocks: Partial[] = Array(21);\n\n availabilityBlocks.forEach((block) => {\n if (typeof block.timeBlockDayOfWeekId === 'number') {\n sortedAvailabilityBlocks[block.timeBlockDayOfWeekId] = block;\n }\n });\n\n return sortedAvailabilityBlocks;\n};\n\nexport const getDefaultAvailabilityBlocks = () => {\n const matrixCellCount = 21;\n return Array.from(Array(matrixCellCount), (_, index) => {\n return {\n timeBlockDayOfWeekId: index,\n isAvailable: false,\n };\n });\n};\n\nexport const getStartDateAllowedPoint = (\n futureSearchPeriod: number,\n status: AvailabilityStatus\n) => {\n const weekDaysCount = 7;\n return moment()\n .add(\n futureSearchPeriod * weekDaysCount +\n (status === AvailabilityStatus.Upcoming ? 1 : 0),\n 'days'\n )\n .format(DATE_FORMAT);\n};\n\nexport const editMatrixBlock = (\n key: number,\n isAvailable: boolean,\n matrixBlocks: Partial[]\n) => {\n const matrixBlocksCopy = cloneDeep(matrixBlocks);\n const block = matrixBlocksCopy[key];\n block.isAvailable = isAvailable;\n return matrixBlocksCopy;\n};\n\nexport type LastPastBlockFinder = (\n startDate: string,\n timeBlocks: TimeBlock[]\n) => BlockCoords;\n\nexport const getLastPastBlock: LastPastBlockFinder = (\n startDate,\n timeBlocks\n) => {\n const startDateMoment = moment(startDate, DATE_FORMAT_US).startOf('week');\n\n if (moment().startOf('week') < startDateMoment) {\n return { dayOfWeekId: 0, timeBlockId: 0 };\n }\n\n const weekDay = moment().weekday();\n\n const matchedTimeBlocks =\n timeBlocks.filter((timeBlock) => {\n return moment().format(TIME_FORMAT_24HR) >= timeBlock.start;\n }) || [];\n\n const timeBlockIds = matchedTimeBlocks.map((timeBlock) => timeBlock.id);\n\n return { dayOfWeekId: weekDay, timeBlockId: max(timeBlockIds) || 0 };\n};\n\nexport const isPastBlock = (\n startDate: string,\n timeBlocks: TimeBlock[],\n {\n horizontalValue,\n verticalValue,\n }: {\n horizontalValue: DayOfWeekId;\n verticalValue: number;\n }\n) => {\n const lastPastBlock = getLastPastBlock(startDate, timeBlocks);\n\n if (horizontalValue > lastPastBlock.dayOfWeekId) {\n return false;\n }\n\n if (horizontalValue < lastPastBlock.dayOfWeekId) {\n return true;\n }\n\n if (verticalValue <= lastPastBlock.timeBlockId) {\n return true;\n }\n\n return false;\n};\n\nexport const resetPastBlocksToInitial = (\n startDate: string,\n availabilityBlocks: Array> | undefined,\n initialAvailabilityBlocks: Array>,\n timeBlocks: Array\n) => {\n const newAvailabilityBlocks: Array> = [];\n\n if (!availabilityBlocks || !startDate) {\n return;\n }\n for (const block of availabilityBlocks) {\n if (\n block.timeBlockDayOfWeek &&\n isPastBlock(startDate, timeBlocks, {\n horizontalValue: block.timeBlockDayOfWeek.dayOfWeekId,\n verticalValue: block.timeBlockDayOfWeek.timeBlockId,\n })\n ) {\n const initialBlock = initialAvailabilityBlocks.find(\n (b) => b.timeBlockDayOfWeekId === block.timeBlockDayOfWeekId\n );\n newAvailabilityBlocks.push({\n ...block,\n isAvailable: initialBlock?.isAvailable,\n });\n } else {\n newAvailabilityBlocks.push({ ...block });\n }\n }\n\n return newAvailabilityBlocks;\n};\n","import React from 'react';\nimport {\n createStyles,\n makeStyles,\n Theme,\n withStyles,\n WithStyles,\n} from '@material-ui/core/styles';\nimport Dialog, { DialogProps } from '@material-ui/core/Dialog';\nimport MuiDialogTitle from '@material-ui/core/DialogTitle';\nimport MuiDialogContent from '@material-ui/core/DialogContent';\nimport MuiDialogActions from '@material-ui/core/DialogActions';\nimport IconButton from '@material-ui/core/IconButton';\nimport CloseIcon from '@material-ui/icons/Close';\nimport Typography from '@material-ui/core/Typography';\nimport StyledButton from './buttons/StyledButton';\n\nconst styles = (theme: Theme) =>\n createStyles({\n root: {\n margin: 0,\n padding: theme.spacing(1.5),\n background: 'rgba(230, 230, 230, 0.5)',\n minHeight: '60px',\n },\n closeButton: {\n position: 'absolute',\n right: theme.spacing(1),\n top: 5,\n color: theme.palette.common.black,\n },\n });\n\nexport interface DialogTitleProps extends WithStyles {\n id: string;\n children: React.ReactNode;\n onClose?: () => void;\n}\n\nexport const DialogTitle = withStyles(styles)((props: DialogTitleProps) => {\n const { children, classes, onClose, ...other } = props;\n return (\n \n \n {children}\n \n {onClose ? (\n \n \n \n ) : null}\n \n );\n});\n\nconst DialogContent = withStyles((theme: Theme) => ({\n root: {\n padding: theme.spacing(2),\n },\n}))(MuiDialogContent);\n\nconst DialogActions = withStyles((theme: Theme) => ({\n root: {\n margin: 0,\n padding: theme.spacing(1),\n },\n}))(MuiDialogActions);\n\nexport interface ConfirmationDialogTemplateProps extends DialogProps {\n open: boolean;\n handleClose: () => void;\n title?: string;\n children?: React.ReactNode;\n actions?: React.ReactNode;\n}\n\nconst useStyles = makeStyles((theme) => ({\n paper: { maxWidth: 550 },\n}));\n\nexport default function ConfirmationDialogTemplate(\n props: ConfirmationDialogTemplateProps\n) {\n const classes = useStyles();\n const { open, handleClose, title, children, actions } = props;\n return (\n \n \n {title}\n \n {children && {children}}\n {actions}\n \n );\n}\n\nconst dialogActionStyles = makeStyles((theme: Theme) => ({\n button: {\n minWidth: 127,\n },\n}));\n\nexport const ConfirmationDialogActionsTemplate = (props: {\n confirm: () => void;\n confirmLabel: string;\n cancel: () => void;\n cancelLabel: string;\n}) => {\n const { confirm, cancel, confirmLabel, cancelLabel } = props;\n const classes = dialogActionStyles();\n\n return (\n <>\n \n {cancelLabel}\n \n \n {confirmLabel}\n \n \n );\n};\n","import { createContext } from 'react';\n\nexport const HelpPageContext = createContext({ reloadOnNavigate: false });\n\nexport const HelpPageProvider = HelpPageContext.Provider;\n","import React from 'react';\nimport { IconButton, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n button: {\n fontSize: 16,\n padding: 16,\n margin: theme.spacing(0, 0.5),\n border: '1px solid transparent',\n width: 20,\n height: 20,\n color: 'inherit',\n },\n current: {\n borderColor: theme.palette.grey[300],\n },\n}));\n\ninterface PaginationProps {\n numOfPages: number;\n currentPage: number;\n changePage: Function;\n maxShownPages?: number;\n className?: string;\n}\n\nconst Pagination = (props: PaginationProps) => {\n const {\n changePage,\n currentPage,\n maxShownPages,\n className,\n numOfPages,\n } = props;\n const classes = useStyles();\n\n let firstShownPage = 1;\n if (maxShownPages && maxShownPages < numOfPages) {\n firstShownPage = Math.max(currentPage - maxShownPages / 2, 1);\n }\n\n if (numOfPages <= 1) {\n return null;\n }\n\n return (\n \n {Array(numOfPages)\n .fill({})\n .map((_, i) => firstShownPage + i)\n .filter((p) =>\n maxShownPages\n ? p <= firstShownPage + (maxShownPages || 0) && p <= numOfPages\n : true\n )\n .map((p) => {\n const isCurrentPage = p === currentPage + 1;\n return (\n {\n if (!isCurrentPage) {\n changePage(p - 1);\n }\n }}\n >\n {p}\n \n );\n })}\n \n );\n};\n\nexport default Pagination;\n","import React from 'react';\nimport {\n Table,\n TableFooter,\n TableRow,\n TableCell,\n makeStyles,\n Theme,\n Box,\n TextField,\n MenuItem,\n IconButton,\n} from '@material-ui/core';\nimport { KeyboardArrowLeft, KeyboardArrowRight } from '@material-ui/icons';\nimport { MUIDataTableOptions } from 'mui-datatables';\nimport clsx from 'clsx';\n\nimport Pagination from './Pagination';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n cell: {\n borderBottom: 'none',\n },\n container: {\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n borderBottom: 'none',\n fontSize: 16,\n },\n select: {\n marginRight: theme.spacing(2),\n minWidth: 140,\n '& > div': {\n color: 'inherit',\n fontSize: 'inherit',\n\n '& > div': {\n paddingBottom: 0,\n },\n },\n [theme.breakpoints.down('sm')]: {\n marginBottom: theme.spacing(2),\n },\n },\n arrowButton: {\n padding: 0,\n backgroundColor: theme.palette.grey[200],\n margin: theme.spacing(0, 0.5),\n [theme.breakpoints.down('sm')]: {\n width: 35,\n height: 35,\n margin: theme.spacing(0, 1.5),\n },\n },\n bold: {\n fontWeight: 700,\n },\n pagination: {\n color: '#000',\n },\n desktopOnly: {\n [theme.breakpoints.down('sm')]: {\n display: 'none',\n },\n },\n pageControls: {\n [theme.breakpoints.down('sm')]: {\n display: 'flex',\n flexWrap: 'wrap',\n justifyContent: 'center',\n width: '100%',\n },\n },\n}));\n\ninterface CustomTableFooterProps {\n options: MUIDataTableOptions;\n rowCount?: number;\n page?: number;\n rowsPerPage?: number;\n changeRowsPerPage?: Function;\n changePage?: Function;\n}\n\nconst CustomTableFooter = (props: CustomTableFooterProps) => {\n const classes = useStyles();\n const {\n options,\n rowCount,\n page,\n rowsPerPage,\n changeRowsPerPage,\n changePage,\n } = props;\n\n const { pagination } = options;\n\n if (\n !pagination ||\n !rowsPerPage ||\n !rowCount ||\n page === undefined ||\n !changePage ||\n !changeRowsPerPage\n ) {\n return null;\n }\n\n const handleRowsPerPageChange = (e: React.ChangeEvent) => {\n const { value } = e.target;\n changeRowsPerPage(value);\n };\n\n const numOfPages = Math.ceil(rowCount / rowsPerPage);\n\n const shownRows =\n numOfPages > 1 && page === numOfPages - 1\n ? rowCount - rowsPerPage * (numOfPages - 1)\n : Math.min(rowsPerPage, rowCount);\n\n return (\n \n \n \n \n \n \n Showing\n {shownRows} \n of {rowCount} records\n \n \n \n {options.rowsPerPageOptions && (\n \n \n {options.rowsPerPageOptions.map((opt) => (\n \n {`Show ${opt} rows`}\n \n ))}\n \n \n )}\n \n {\n changePage(page - 1);\n }}\n disabled={page === 0}\n >\n \n \n {\n changePage(page + 1);\n }}\n disabled={page === numOfPages - 1}\n >\n \n \n \n \n \n \n \n \n
\n );\n};\n\nexport default CustomTableFooter;\n","import {\n createAsyncThunk,\n createSelector,\n createSlice,\n} from '@reduxjs/toolkit';\nimport providerApi from '../../api/providerApi';\n\nimport { Provider, ProviderAttendanceAwards } from '../../types/types';\nimport { getNumberOfHoursBelowRequiredAvail } from '../../utils/helpers';\nimport { RootState } from './rootReducer';\n\nexport interface MenteeProvidersState {\n menteeProviders: Array;\n menteeProvidersLoading: boolean;\n selectedMentee: Provider | null;\n selectedMenteeLoading: boolean;\n selectedMenteeAttendanceAwards: ProviderAttendanceAwards | null;\n selectedMenteeAttendanceAwardsLoading: boolean;\n}\n\nconst initialState: MenteeProvidersState = {\n menteeProviders: [],\n menteeProvidersLoading: false,\n selectedMentee: null,\n selectedMenteeLoading: false,\n selectedMenteeAttendanceAwards: null,\n selectedMenteeAttendanceAwardsLoading: false,\n};\n\nexport const fetchMenteeProviders = createAsyncThunk(\n 'menteeProviders/fetchMenteeProviders',\n (providerId: number) => {\n return providerApi.fetchMenteeProviders(providerId);\n }\n);\n\nexport const fetchSelectedMentee = createAsyncThunk(\n 'menteeProviders/fetchSelectedMentee',\n (providerId: number) => providerApi.fetchProviderById(providerId)\n);\n\nexport const fetchSelectedMenteeAttendanceAwards = createAsyncThunk(\n 'menteeProviders/fetchSelectedMenteeAttendanceAwards',\n (providerId: number) => {\n return providerApi\n .fetchProviderAttendanceAwards(providerId)\n .then((res) => res);\n }\n);\n\nconst menteeProvidersSlice = createSlice({\n name: 'menteeProviders',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchMenteeProviders.pending, (state) => {\n state.menteeProvidersLoading = true;\n })\n .addCase(fetchMenteeProviders.fulfilled, (state, action) => {\n state.menteeProviders = action.payload;\n state.menteeProvidersLoading = false;\n })\n .addCase(fetchMenteeProviders.rejected, (state) => {\n state.menteeProvidersLoading = false;\n state.menteeProviders = [];\n })\n .addCase(fetchSelectedMentee.pending, (state) => {\n state.selectedMenteeLoading = true;\n })\n .addCase(fetchSelectedMentee.fulfilled, (state, action) => {\n state.selectedMentee = action.payload;\n state.selectedMenteeLoading = false;\n })\n .addCase(fetchSelectedMentee.rejected, (state) => {\n state.selectedMenteeLoading = false;\n })\n .addCase(fetchSelectedMenteeAttendanceAwards.pending, (state) => {\n state.selectedMenteeAttendanceAwardsLoading = true;\n })\n .addCase(\n fetchSelectedMenteeAttendanceAwards.fulfilled,\n (state, action) => {\n state.selectedMenteeAttendanceAwardsLoading = false;\n state.selectedMenteeAttendanceAwards = action.payload;\n }\n )\n .addCase(fetchSelectedMenteeAttendanceAwards.rejected, (state) => {\n state.selectedMenteeAttendanceAwardsLoading = false;\n });\n },\n});\n\nexport const selectNumberOfHoursBelowRequiredAvail = createSelector(\n (state: RootState) => state.menteeProviders.selectedMentee,\n (provider: Provider | null) =>\n provider?.schedule\n ? getNumberOfHoursBelowRequiredAvail({\n schedule: provider.schedule,\n minHrsTarget: provider.minHrsTarget,\n })\n : 0\n);\n\nexport const selectMenteesCurrentAvailabilities = createSelector(\n (state: RootState) => state.menteeProviders.menteeProviders,\n (menteeProviders) => {\n return menteeProviders.reduce((acc, provider) => {\n const numberOfHoursBelowRequiredAvail = provider.schedule\n ? getNumberOfHoursBelowRequiredAvail({\n schedule: provider.schedule,\n minHrsTarget: provider.minHrsTarget,\n })\n : 0;\n acc[provider.id] = numberOfHoursBelowRequiredAvail > 0;\n\n return acc;\n }, {} as Record);\n }\n);\n\nexport default menteeProvidersSlice.reducer;\n","import useNoShowTimeLine from './useNoShowTimeLIne';\nimport {\n NoShowParticipant,\n ScheduledSessionsLogActionIds,\n ScheduledSession,\n SessionStatus,\n} from '../types/types';\nimport { DISTRICT_PAYER_TYPE } from '../utils/constants';\nimport { isNoShowParticipantRequester } from '../utils/helpers';\nimport { scheduledSessionsLogActions } from '../shared/constants';\n\nconst DEFAULT_BUTTON_VISIBILITY_STATE = {\n canShowIsNotHereButton: false,\n canShowStopWatchButton: false,\n canShowStillIsNotHereButton: false,\n canShowArrivedButton: false,\n canShowDisabledArrivedButton: false,\n canShowReminderSentButton: false,\n hideWaitLongerButton: false,\n};\n\ninterface NoShowButtonsVisibility {\n canShowIsNotHereButton?: boolean;\n canShowStopWatchButton?: boolean;\n canShowStillIsNotHereButton?: boolean;\n canShowArrivedButton?: boolean;\n canShowDisabledArrivedButton?: boolean;\n canShowReminderSentButton?: boolean;\n hideWaitLongerButton?: boolean;\n}\n\nconst useNoShowButtonsVisibility = (\n session: ScheduledSession,\n participant: NoShowParticipant\n): NoShowButtonsVisibility => {\n const {\n now,\n showIsNotHere,\n showStopWatch,\n showStillIsNotHere,\n noShowedEnd,\n preNoShowedEnd,\n } = useNoShowTimeLine(session, participant);\n\n const { sessionLogs } = session;\n const {\n shouldReturnForClient,\n shouldReturnForProvider,\n } = isNoShowParticipantRequester(participant, session?.sessionLogs || []);\n const isDistrictClient = session.client?.payerType === DISTRICT_PAYER_TYPE;\n const noEligibleActionForDistrictClient =\n isDistrictClient && participant === NoShowParticipant.Provider;\n\n const isConfirmedSession = session.status === SessionStatus.Confirmed;\n\n if (\n now.isAfter(noShowedEnd) ||\n noEligibleActionForDistrictClient ||\n shouldReturnForClient ||\n shouldReturnForProvider ||\n shouldReturnForProvider ||\n !isConfirmedSession\n ) {\n return DEFAULT_BUTTON_VISIBILITY_STATE;\n }\n\n const hasLog = (actionIds: ScheduledSessionsLogActionIds[]) =>\n sessionLogs?.some((item) => actionIds.includes(item.actionId));\n\n const isNotHereLog = hasLog(scheduledSessionsLogActions.NotHereActions);\n const stillIsNotHereLog = hasLog(\n scheduledSessionsLogActions.StillNotHereActions\n );\n const arrivedLog = hasLog(scheduledSessionsLogActions.ArrivedActions);\n\n const noArrivedOrStillIsNotHereLogs = !arrivedLog && !stillIsNotHereLog;\n\n const canShowIsNotHereButton = !isNotHereLog && showIsNotHere;\n\n const canShowStopWatchButton =\n isNotHereLog && noArrivedOrStillIsNotHereLogs && showStopWatch;\n\n const canShowStillIsNotHereButton =\n isNotHereLog && noArrivedOrStillIsNotHereLogs && showStillIsNotHere;\n\n const canShowArrivedButton =\n !arrivedLog && (canShowStopWatchButton || canShowStillIsNotHereButton);\n\n const canShowDisabledArrivedButton = !!arrivedLog;\n\n const canShowReminderSentButton =\n canShowStopWatchButton || canShowStillIsNotHereButton;\n\n const hideWaitLongerButton = now.isAfter(preNoShowedEnd);\n\n return {\n canShowIsNotHereButton,\n canShowStopWatchButton,\n canShowStillIsNotHereButton,\n canShowArrivedButton,\n canShowDisabledArrivedButton,\n canShowReminderSentButton,\n hideWaitLongerButton,\n };\n};\n\nexport default useNoShowButtonsVisibility;\n","import { Loader } from '@googlemaps/js-api-loader';\nimport configs from '../configs';\n\nexport default class GoogleApiWrapper {\n private static instance: GoogleApiWrapper;\n\n private static loader = new Loader({\n apiKey: configs.googleApiKey,\n });\n\n private distanceMatrixService: google.maps.DistanceMatrixService | null = null;\n\n public static getInstance(): GoogleApiWrapper {\n if (!GoogleApiWrapper.instance) {\n GoogleApiWrapper.instance = new GoogleApiWrapper();\n }\n return GoogleApiWrapper.instance;\n }\n\n async getDistanceMatrix(\n params: {\n origins: google.maps.LatLngLiteral[];\n destinations: google.maps.LatLngLiteral[];\n },\n approvedForTolls: boolean\n ): Promise {\n if (this.distanceMatrixService === null) {\n const google = await GoogleApiWrapper.loader.load();\n this.distanceMatrixService = new google.maps.DistanceMatrixService();\n }\n return this.distanceMatrixService.getDistanceMatrix({\n ...params,\n travelMode: google.maps.TravelMode.DRIVING,\n avoidFerries: true,\n avoidTolls: !approvedForTolls,\n unitSystem: google.maps.UnitSystem.IMPERIAL,\n });\n }\n}\n","import queryString from 'query-string';\nimport GoogleApiWrapper from './googleApiWrapper';\nimport requester from './requester';\nimport {\n Client,\n OpenSessionBookRequest,\n PaginatedData,\n Provider,\n RequestStatus,\n ZipCodeData,\n} from '../types/types';\n\nconst googleWrapperInstance = GoogleApiWrapper.getInstance();\n\nconst extendWithDriveTimes = async >({\n data,\n originalZipCode,\n destinations,\n approvedForTolls,\n}: {\n data: T;\n originalZipCode?: ZipCodeData;\n destinations: google.maps.LatLngLiteral[];\n approvedForTolls: boolean;\n}) => {\n if (!originalZipCode) {\n return data;\n }\n\n const distances = await googleWrapperInstance.getDistanceMatrix(\n {\n origins: [\n {\n lat: Number(originalZipCode.latitude),\n lng: Number(originalZipCode.longitude),\n },\n ],\n destinations,\n },\n approvedForTolls\n );\n\n const { items, ...rest } = data;\n\n return {\n ...rest,\n items: items.map((item, index) => {\n return { ...item, driveTime: distances.rows[0]?.elements[index] };\n }),\n };\n};\n\nconst getClientsLatLng = (clients: Client[]) => {\n return clients.reduce((acc: google.maps.LatLngLiteral[], client) => {\n const { latitude, longitude } = client.zipCodeData || {};\n\n if (!latitude || !longitude) {\n return acc;\n }\n\n return acc.concat({\n lat: +latitude,\n lng: +longitude,\n });\n }, []);\n};\n\nconst fetchOpenSessions = async (\n provider: Provider,\n isFromCaseTeam: boolean,\n ignoreAvailability: boolean,\n page: number,\n limit: number,\n clientId?: number\n) => {\n const query = queryString.stringify({\n limit,\n page,\n isFromCaseTeam,\n considerAvailability: !ignoreAvailability,\n clientId,\n providerId: provider.id,\n });\n\n const url = `v2/bookings/open-session-book-requests-search?${query}`;\n\n const data = await requester\n .get(url)\n .then((resp) => resp.json())\n .then((resp) => resp.data);\n\n return extendWithDriveTimes>({\n data,\n originalZipCode: provider?.address?.zipCodeData,\n destinations: getClientsLatLng(\n data.items.map((i: OpenSessionBookRequest) => i.client)\n ),\n approvedForTolls: !!provider.attributes?.approvedForTolls,\n });\n};\n\nconst updateOpenSessionRequest = async (\n requestId: number,\n sessionIds: number[],\n statusId: RequestStatus,\n providerId?: number\n) => {\n const url = `v2/bookings/open-session-book-requests/${requestId}`;\n\n const response = await requester.put(url, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ statusId, providerId, sessionIds }),\n });\n const res = await response.json();\n return res.data;\n};\n\nexport const createOpenSessionFromCancellation = async (\n cancellationEventId: number\n): Promise<{ createdOpenSessions: OpenSessionBookRequest[] }> => {\n const url = `v2/bookings/open-session-book-requests/from-cancellation`;\n\n return requester\n .post(url, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n cancellationEventId,\n }),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n fetchOpenSessions,\n updateOpenSessionRequest,\n createOpenSessionFromCancellation,\n};\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport openSessionsApi from '../../api/openSessionsApi';\nimport {\n OpenSessionBookRequest,\n Provider,\n RequestStatus,\n RequestType,\n} from '../../types/types';\nimport { RootState } from './rootReducer';\nimport requestsApi from '../../api/requestsApi';\n\ninterface OpenSesionsState {\n openSessionsList: OpenSessionBookRequest[];\n openSessionsLoading: boolean;\n totalCount: number;\n updatedSuccess: boolean;\n updatedError: boolean;\n selectedClientOpenSessions: OpenSessionBookRequest[];\n selectedClientOpenSessionsLoading: boolean;\n selectedClientId: number | null;\n requestIdentifier: string | null;\n searchForSubCompletedAt: string | null;\n numOfPendingRequests: number;\n numOfPendingRequestsLoading: boolean;\n}\n\nconst initialState: OpenSesionsState = {\n openSessionsList: [],\n openSessionsLoading: false,\n totalCount: 0,\n updatedSuccess: false,\n updatedError: false,\n selectedClientOpenSessions: [],\n selectedClientOpenSessionsLoading: false,\n selectedClientId: null,\n requestIdentifier: null,\n searchForSubCompletedAt: null,\n numOfPendingRequests: 0,\n numOfPendingRequestsLoading: false,\n};\n\nexport const fetchOpenSessions = createAsyncThunk(\n 'openSessions/fetchOpenSessions',\n async (arg: {\n page: number;\n rowsPerPage: number;\n isFromCaseTeam: boolean;\n ignoreAvailability: boolean;\n currentProvider: Provider;\n }) => {\n const {\n page,\n rowsPerPage,\n isFromCaseTeam,\n ignoreAvailability,\n currentProvider,\n } = arg;\n return openSessionsApi.fetchOpenSessions(\n currentProvider,\n isFromCaseTeam,\n ignoreAvailability,\n page,\n rowsPerPage\n );\n }\n);\n\nexport const fetchNumOfPendingRequests = createAsyncThunk(\n 'openSessions/fetchNumOfPendingRequests',\n async () => {\n const requests = await requestsApi.fetchAllRequests(\n {\n statusId: [RequestStatus.PENDING],\n },\n false,\n true,\n [RequestType.LongTerm, RequestType.SingleTerm],\n null,\n null,\n {\n name: 'statusUpdatedAt',\n direction: 'desc',\n }\n );\n\n return requests.length;\n }\n);\n\nexport const fetchSelectedClientOpenSessions = createAsyncThunk(\n 'openSessions/fetchSelectedClientOpenSessions',\n async (arg: {\n page: number;\n rowsPerPage: number;\n isFromCaseTeam: boolean;\n ignoreAvailability: boolean;\n currentProvider: Provider;\n clientId: number;\n }) => {\n const {\n page,\n rowsPerPage,\n isFromCaseTeam,\n ignoreAvailability,\n currentProvider,\n clientId,\n } = arg;\n return openSessionsApi.fetchOpenSessions(\n currentProvider,\n isFromCaseTeam,\n ignoreAvailability,\n page,\n rowsPerPage,\n clientId\n );\n }\n);\n\nexport const updateOpenSessionRequest = createAsyncThunk<\n OpenSessionBookRequest,\n {\n requestId: number;\n sessionIds: Array;\n statusId: RequestStatus;\n },\n { state: RootState }\n>(\n 'openSessions/updateOpenSessionRequest',\n async ({ requestId, sessionIds, statusId }, { getState }) => {\n const currentProvider = getState().provider?.provider;\n return openSessionsApi.updateOpenSessionRequest(\n requestId,\n sessionIds,\n statusId,\n currentProvider?.id\n );\n }\n);\n\nexport const createOpenSessionFromCancellation = createAsyncThunk<\n { createdOpenSessions: OpenSessionBookRequest[] },\n {\n cancellationEventId: number;\n },\n { state: RootState }\n>(\n 'openSessions/createOpenSessionFromCancellation',\n async ({ cancellationEventId }, { rejectWithValue }) => {\n try {\n return await openSessionsApi.createOpenSessionFromCancellation(\n cancellationEventId\n );\n } catch (e) {\n return rejectWithValue(e);\n }\n }\n);\n\nconst openSessionsSlice = createSlice({\n name: 'openSessions',\n initialState,\n reducers: {\n resetAcceptedState: (state) => ({\n ...state,\n updatedError: false,\n updatedSuccess: false,\n selectedClientId: null,\n }),\n },\n extraReducers: (builder) => {\n builder\n .addCase(fetchOpenSessions.pending, (state) => {\n state.openSessionsLoading = true;\n state.openSessionsList = [];\n state.totalCount = 0;\n })\n .addCase(fetchOpenSessions.fulfilled, (state, action) => {\n const openSessionsListWithBlocks = action.payload.items?.map(\n (request: OpenSessionBookRequest) => {\n const openSessionBlocks: {\n dayOfWeekId: number;\n timeBlockId: number;\n }[] = [];\n request.sessions.forEach((s) => {\n if (s.blocks.length) {\n s.blocks.forEach((tb) => {\n openSessionBlocks.push({\n timeBlockId: tb.timeBlockId,\n dayOfWeekId: tb.dayOfWeekId,\n });\n });\n }\n });\n return {\n ...request,\n openSessionBlocks,\n };\n }\n );\n\n state.openSessionsLoading = false;\n state.openSessionsList = openSessionsListWithBlocks;\n state.totalCount = action.payload.meta.totalItems;\n })\n .addCase(fetchOpenSessions.rejected, (state) => {\n state.openSessionsLoading = false;\n })\n .addCase(updateOpenSessionRequest.pending, (state) => {\n state.openSessionsLoading = true;\n })\n .addCase(updateOpenSessionRequest.fulfilled, (state, action) => {\n state.updatedSuccess = true;\n state.updatedError = false;\n state.openSessionsLoading = false;\n state.selectedClientId = action.payload.clientId || null;\n state.requestIdentifier = action.meta.requestId;\n })\n .addCase(updateOpenSessionRequest.rejected, (state) => {\n state.updatedError = true;\n state.updatedSuccess = false;\n state.openSessionsLoading = false;\n state.selectedClientId = null;\n })\n .addCase(fetchSelectedClientOpenSessions.pending, (state) => {\n state.selectedClientOpenSessionsLoading = true;\n state.selectedClientOpenSessions = [];\n })\n .addCase(fetchSelectedClientOpenSessions.fulfilled, (state, action) => {\n const openSessionsListWithBlocks = action.payload.items?.map(\n (request: OpenSessionBookRequest) => {\n const openSessionBlocks: {\n dayOfWeekId: number;\n timeBlockId: number;\n }[] = [];\n request.sessions.forEach((s) => {\n if (s.blocks.length) {\n s.blocks.forEach((tb) => {\n openSessionBlocks.push({\n timeBlockId: tb.timeBlockId,\n dayOfWeekId: tb.dayOfWeekId,\n });\n });\n }\n });\n return {\n ...request,\n openSessionBlocks,\n };\n }\n );\n\n state.selectedClientOpenSessionsLoading = false;\n state.selectedClientOpenSessions = openSessionsListWithBlocks;\n })\n .addCase(createOpenSessionFromCancellation.pending, (state) => {\n state.openSessionsLoading = true;\n })\n .addCase(createOpenSessionFromCancellation.fulfilled, (state) => {\n state.openSessionsLoading = false;\n state.searchForSubCompletedAt = Date.now().toString();\n })\n .addCase(createOpenSessionFromCancellation.rejected, (state) => {\n state.openSessionsLoading = false;\n })\n .addCase(fetchSelectedClientOpenSessions.rejected, (state) => {\n state.selectedClientOpenSessionsLoading = false;\n })\n .addCase(fetchNumOfPendingRequests.pending, (state) => {\n state.numOfPendingRequestsLoading = true;\n })\n .addCase(fetchNumOfPendingRequests.fulfilled, (state, action) => {\n state.numOfPendingRequestsLoading = false;\n state.numOfPendingRequests = action.payload;\n })\n .addCase(fetchNumOfPendingRequests.rejected, (state) => {\n state.numOfPendingRequestsLoading = false;\n });\n },\n});\n\nexport const { resetAcceptedState } = openSessionsSlice.actions;\n\nexport default openSessionsSlice.reducer;\n","import {\n RemoveSessionVariant,\n ScheduledSessionsLogActionIds,\n} from '../types/types';\n\nexport const TIME_FORMAT = 'HH:mm:ss';\n\nexport enum DayOfWeekId {\n Sunday = 0,\n Monday = 1,\n Tuesday = 2,\n Wednesday = 3,\n Thursday = 4,\n Friday = 5,\n Saturday = 6,\n}\n\nexport enum AvailabilityType {\n ShortTerm = 'ShortTerm',\n LongTerm = 'LongTerm',\n}\n\nexport enum availabilityPreferredBlocks {\n start1 = '08:00:00',\n start3 = '15:00:00',\n end3 = '19:00:00',\n}\n\nexport const CANCELLTION_EVENTS_PER_PAGE = 15;\n\nexport const RemoveSessionVariantText: Record = {\n [RemoveSessionVariant.cancellation]: 'Remove',\n [RemoveSessionVariant.timeOff]: 'Time Off',\n [RemoveSessionVariant.retraction]: 'Retract',\n};\n\nexport const scheduledSessionsLogActions = {\n NotHereActions: [\n ScheduledSessionsLogActionIds.ClientReportNotHere,\n ScheduledSessionsLogActionIds.ProviderReportNotHere,\n ],\n StillNotHereActions: [\n ScheduledSessionsLogActionIds.ClientReportStillNotHere,\n ScheduledSessionsLogActionIds.ProviderReportStillNotHere,\n ],\n ArrivedActions: [\n ScheduledSessionsLogActionIds.ClientReportArrived,\n ScheduledSessionsLogActionIds.ProviderReportArrived,\n ],\n};\n\nexport const NoShowActionsByReporter = {\n client: {\n NotHere: ScheduledSessionsLogActionIds.ClientReportNotHere,\n StillNotHere: ScheduledSessionsLogActionIds.ClientReportStillNotHere,\n Arrived: ScheduledSessionsLogActionIds.ClientReportArrived,\n },\n provider: {\n NotHere: ScheduledSessionsLogActionIds.ProviderReportNotHere,\n StillNotHere: ScheduledSessionsLogActionIds.ProviderReportStillNotHere,\n Arrived: ScheduledSessionsLogActionIds.ProviderReportArrived,\n },\n};\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport { orderBy } from 'lodash';\nimport { RootState } from './rootReducer';\nimport {\n Notification,\n RequestStatus,\n RequestType,\n Request,\n} from '../../types/types';\nimport requestsApi from '../../api/requestsApi';\nimport notificationsApi from '../../api/notificationsApi';\n\ntype FeedNotificationItem = {\n type: 'notification';\n item: Notification;\n};\n\ntype FeedBookRequestItem = { type: 'bookRequest'; item: Request };\n\ntype FeedItem = FeedNotificationItem | FeedBookRequestItem;\n\ninterface FeedState {\n feed: FeedItem[];\n feedLoading: boolean;\n}\n\nconst initialState: FeedState = {\n feed: [],\n feedLoading: false,\n};\n\nexport const fetchFeed = createAsyncThunk<\n FeedItem[],\n void,\n { state: RootState }\n>('feed/fetchFeed', async (_, thunkApi) => {\n const { getState } = thunkApi;\n const currentProviderId = getState().provider?.provider?.id;\n\n if (currentProviderId) {\n const bookRequestData = await requestsApi.fetchAllRequests(\n {\n statusId: [RequestStatus.PENDING],\n },\n false,\n true,\n [RequestType.LongTerm, RequestType.SingleTerm],\n 10,\n 0,\n {\n name: 'statusUpdatedAt',\n direction: 'desc',\n }\n );\n\n const notificationData = await notificationsApi.fetchNotifications(\n {\n isSeen: false,\n },\n {\n page: 0,\n rowsPerPage: 10,\n }\n );\n const bookRequestFeedItems: FeedBookRequestItem[] = bookRequestData.rows.map(\n (br) => ({\n item: br,\n type: 'bookRequest',\n })\n );\n const notificationFeedItems: FeedNotificationItem[] = notificationData.items.map(\n (n) => ({\n item: n,\n type: 'notification',\n })\n );\n\n const unsortedFeed = [...bookRequestFeedItems, ...notificationFeedItems];\n const sortedFeed = orderBy(unsortedFeed, (f) => f.item.createdAt, ['desc']);\n const slicedFeed = sortedFeed.slice(0, 10);\n return slicedFeed;\n }\n return [];\n});\n\nconst feedSlice = createSlice({\n name: 'feed',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchFeed.pending, (state) => {\n state.feedLoading = true;\n })\n .addCase(fetchFeed.fulfilled, (state, action) => {\n state.feedLoading = false;\n state.feed = action.payload;\n })\n .addCase(fetchFeed.rejected, (state) => {\n state.feedLoading = false;\n });\n },\n});\n\nexport default feedSlice.reducer;\n","import { createAction } from '@reduxjs/toolkit';\n\nexport const clearSearchResult = createAction('clearSearchResult');\nexport default clearSearchResult;\n","import { without } from 'lodash';\n\nclass UnratedSuspendedSessions {\n private static instance: UnratedSuspendedSessions;\n\n private storageKey = 'unratedSuspendedSessions';\n\n public static getInstance() {\n if (!UnratedSuspendedSessions.instance) {\n return new UnratedSuspendedSessions();\n }\n return UnratedSuspendedSessions.instance;\n }\n\n public add(segmentId: number, clientId: number) {\n const clientSuspectedSessions = this.getValue(clientId);\n\n if (clientSuspectedSessions.includes(segmentId)) {\n return this;\n }\n\n clientSuspectedSessions.push(segmentId);\n this.pullToStorage(clientId, clientSuspectedSessions);\n return this;\n }\n\n public remove(segmentIds: number[], clientId: number) {\n const clientSuspectedSessions = this.getValue(clientId);\n\n const newUnratedSessions = without(clientSuspectedSessions, ...segmentIds);\n\n if (newUnratedSessions.length === 0) {\n localStorage.removeItem(this.generateKey(clientId));\n return this;\n }\n\n this.pullToStorage(clientId, newUnratedSessions);\n return this;\n }\n\n public getValue(clientId: number) {\n return (\n localStorage\n .getItem(this.generateKey(clientId))\n ?.split(',')\n .map(Number) || []\n );\n }\n\n private pullToStorage(clientId: number, ids: number[]) {\n localStorage.setItem(this.generateKey(clientId), ids.toString());\n }\n\n private generateKey(clientId: number) {\n return `${this.storageKey}_${clientId}`;\n }\n}\n\nexport default UnratedSuspendedSessions.getInstance();\n","import React from 'react';\nimport { Button, ButtonProps, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\ninterface ButtonPropsWithCustomColors extends ButtonProps {\n customColor?:\n | 'kyoGreen'\n | 'kyoTeal'\n | 'kyoYellow'\n | 'kyoRed'\n | 'kyoMagenta'\n | 'kyoPurple'\n | 'kyoDarkGreen'\n | 'kyoDarkestGreen'\n | 'kyoLightRed'\n | 'kyoOrange'\n | 'kyoBlue'\n | 'kyoLightGreen'\n | 'kyoRed2'\n | 'kyoRed3'\n | 'kyoBlue2'\n | 'kyoBondiBlue'\n | 'kyoDollarBill';\n}\n\nconst useStyles = makeStyles((theme: Theme) => ({\n styledButton: {\n minHeight: 40,\n borderRadius: 8,\n textTransform: 'none',\n },\n sizeLarge: {\n minHeight: 48,\n },\n}));\n\nconst useCustomColor = makeStyles((theme: Theme) => ({\n customColor: (props: ButtonPropsWithCustomColors) => {\n if (props.variant === 'outlined') {\n return props.customColor\n ? {\n borderColor: theme.palette[props.customColor].main,\n color: theme.palette[props.customColor].main,\n '&:hover': {\n borderColor: theme.palette[props.customColor].main,\n },\n }\n : {};\n }\n if (props.variant === 'text') {\n return props.customColor\n ? {\n color: theme.palette[props.customColor].main,\n }\n : {};\n }\n return props.customColor\n ? {\n color: theme.palette[props.customColor].contrastText,\n backgroundColor: theme.palette[props.customColor].main,\n '&:hover': {\n backgroundColor: theme.palette[props.customColor].dark,\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n backgroundColor: theme.palette[props.customColor].main,\n },\n },\n '&:disabled': {\n backgroundColor: theme.palette.grey[100],\n },\n }\n : {};\n },\n}));\n\nconst StyledButton = (props: ButtonPropsWithCustomColors) => {\n const { className, customColor, ...otherProps } = props;\n const classes = useStyles(props);\n const colorClasses = useCustomColor(props);\n return (\n \n );\n};\n\nexport default StyledButton;\n","import moment from 'moment';\nimport useSettings from './useSettings';\nimport { NoShowParticipant, ScheduledSession } from '../types/types';\nimport { scheduledSessionsLogActions } from '../shared/constants';\n\ninterface NoShowTimeLineResult {\n now: moment.Moment;\n isNotHereAvaiablelEnd?: moment.Moment;\n showIsNotHere?: boolean;\n waitUntil?: moment.Moment;\n waitInMinutes?: number;\n showStopWatch?: boolean;\n noShowedEnd?: moment.Moment;\n preNoShowedEnd?: moment.Moment;\n showStillIsNotHere?: boolean;\n}\n\nconst useNoShowTimeLine = (\n session: ScheduledSession,\n participant: NoShowParticipant\n): NoShowTimeLineResult => {\n const { segmentStartUtc, segmentEndUtc, sessionLogs } = session;\n const { noShowSettings } = useSettings();\n const {\n noShowDelayMinutes,\n clientNoShowWaitMinutes,\n providerNoShowWaitMinutes,\n noShowExtensionMinutes,\n preNoShowExtensionMinutes,\n } = noShowSettings;\n\n const now = moment();\n\n if (now.isAfter(moment(segmentEndUtc))) {\n return {\n now,\n };\n }\n\n const isNotHereLog = sessionLogs?.find((l) =>\n scheduledSessionsLogActions.NotHereActions.includes(l.actionId)\n );\n\n const sessionStart = moment(segmentStartUtc);\n const isNotHereAvaiablelEnd = sessionStart\n .clone()\n .add(noShowDelayMinutes, 'minutes');\n\n const showIsNotHere = now.isBetween(sessionStart, isNotHereAvaiablelEnd);\n\n if (!isNotHereLog && showIsNotHere) {\n return {\n now,\n isNotHereAvaiablelEnd,\n showIsNotHere,\n };\n }\n\n if (!isNotHereLog && !showIsNotHere) {\n return {\n now,\n };\n }\n\n const waitStart =\n participant === NoShowParticipant.Provider\n ? moment(isNotHereLog?.createdAt)\n : moment(isNotHereLog?.sessionStartUtc);\n\n const stillIsNotHereLog = sessionLogs?.find((l) =>\n scheduledSessionsLogActions.StillNotHereActions.includes(l.actionId)\n );\n\n const waitDuration =\n participant === NoShowParticipant.Provider\n ? clientNoShowWaitMinutes\n : providerNoShowWaitMinutes;\n const waitUntil = waitStart.clone().add(waitDuration, 'minutes');\n\n const showStopWatch = now\n .startOf('minute')\n .isBetween(\n waitStart.startOf('minute'),\n waitUntil.startOf('minute'),\n null,\n '[)'\n );\n\n const waitInMinutes = waitUntil.diff(now, 'minutes');\n\n if (\n !stillIsNotHereLog &&\n isNotHereLog &&\n showStopWatch &&\n waitInMinutes > 0\n ) {\n return {\n now,\n waitUntil,\n waitInMinutes,\n showStopWatch,\n };\n }\n\n const noShowedEnd = waitUntil.clone().add(noShowExtensionMinutes, 'minutes');\n const preNoShowedEnd = waitUntil\n .clone()\n .add(preNoShowExtensionMinutes, 'minutes');\n\n const showStillIsNotHere = now\n .startOf('minute')\n .isBetween(\n waitUntil.startOf('minute'),\n noShowedEnd.startOf('minute'),\n null,\n '[)'\n );\n\n if (!stillIsNotHereLog && isNotHereLog && showStillIsNotHere) {\n return {\n now,\n noShowedEnd,\n preNoShowedEnd,\n showStillIsNotHere,\n };\n }\n\n return { now };\n};\n\nexport default useNoShowTimeLine;\n","module.exports = __webpack_public_path__ + \"static/media/defaultOpenSessionCalendarIcon.d2ee2791.svg\";","import { createSlice, PayloadAction } from '@reduxjs/toolkit';\n\nexport type AlertMessage =\n | {\n message: string;\n autoHideDuration: number;\n }\n | undefined;\n\nexport interface AlertState {\n alertMessage?: AlertMessage;\n}\n\nconst initialState: AlertState = {\n alertMessage: undefined,\n};\n\nconst errorSlice = createSlice({\n name: 'alertMessage',\n initialState,\n reducers: {\n setAlertMessage: (state, action: PayloadAction) => ({\n ...state,\n alertMessage: action.payload,\n }),\n },\n});\n\nexport const { setAlertMessage } = errorSlice.actions;\n\nexport default errorSlice.reducer;\n","import queryString from 'query-string';\nimport requester from './requester';\nimport { Invoice, PaginatedData, PaginationDataMeta } from '../types/types';\n\nexport interface FetchInvoicesFilters {\n clientId?: number;\n page?: number;\n rowsPerPage?: number;\n}\n\nexport interface InvoicesPaginatedData\n extends Omit, 'items'> {\n data: T[];\n}\n\nexport interface InvoicesDataMeta\n extends Omit {\n total: number;\n}\n\nconst fetchInvoices = async (\n filters: FetchInvoicesFilters\n): Promise> => {\n const { clientId, ...restFilters } = filters;\n\n const query = queryString.stringify(restFilters);\n const url = `v2/clients/${clientId}/invoices?${query}`;\n\n return requester\n .get(url, {\n headers: { 'Content-Type': 'application/json' },\n })\n .then((response) => response.json())\n .then((response) => response);\n};\n\nconst getInvoiceAttachmentUrl = async (clientId: number, invoiceId: number) => {\n const url = `v2/clients/${clientId}/invoices/${invoiceId}/attachments`;\n\n return requester\n .get(url, {\n headers: { 'Content-Type': 'application/json' },\n })\n .then((response) => response.json())\n .then((response) => response);\n};\n\nexport default { fetchInvoices, getInvoiceAttachmentUrl };\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport billingApi, {\n FetchInvoicesFilters,\n InvoicesDataMeta,\n} from '../../api/billingApi';\nimport { Invoice } from '../../types/types';\n\nexport interface BillingState {\n invoices: Invoice[];\n invoicesMeta: InvoicesDataMeta | null;\n invoicesLoading: boolean;\n attachmentUrls: string[];\n attachmentUrlsLoading: boolean;\n isStatusChanging: boolean;\n}\n\nconst initialState: BillingState = {\n invoices: [],\n invoicesMeta: null,\n invoicesLoading: false,\n attachmentUrls: [],\n attachmentUrlsLoading: false,\n isStatusChanging: false,\n};\n\nexport const fetchInvoices = createAsyncThunk(\n 'invoices/fetchInvoices',\n (filters: FetchInvoicesFilters) => billingApi.fetchInvoices(filters)\n);\n\nexport const fetchInvoiceAttachmentUrl = createAsyncThunk(\n 'invoices/fetchInvoiceAttachmentUrl',\n ({ clientId, invoiceId }: { clientId: number; invoiceId: number }) =>\n billingApi.getInvoiceAttachmentUrl(clientId, invoiceId)\n);\n\nconst billingSlice = createSlice({\n name: 'billing',\n initialState,\n reducers: {\n clearAttachmentUrls: (state) => {\n state.attachmentUrls = [];\n },\n },\n extraReducers: (builder) => {\n builder\n // fetch invoices\n .addCase(fetchInvoices.pending, (state) => {\n state.invoicesLoading = true;\n })\n .addCase(fetchInvoices.rejected, (state) => {\n state.invoicesLoading = false;\n })\n .addCase(fetchInvoices.fulfilled, (state, action) => {\n const { data, meta } = action.payload;\n\n state.invoicesLoading = false;\n state.invoices = data;\n state.invoicesMeta = (meta as unknown) as InvoicesDataMeta;\n })\n\n // fetch invoice attachment url\n .addCase(fetchInvoiceAttachmentUrl.pending, (state) => {\n state.attachmentUrlsLoading = true;\n })\n .addCase(fetchInvoiceAttachmentUrl.rejected, (state) => {\n state.attachmentUrlsLoading = false;\n })\n .addCase(fetchInvoiceAttachmentUrl.fulfilled, (state, action) => {\n state.attachmentUrlsLoading = false;\n state.attachmentUrls = action.payload;\n });\n },\n});\n\nexport const { clearAttachmentUrls } = billingSlice.actions;\n\nexport default billingSlice.reducer;\n","import { combineReducers } from '@reduxjs/toolkit';\nimport providerReducer from './provider';\nimport clientReducer from './client';\nimport usersReducer from './users';\nimport requestsReducer from './requests';\nimport sessionCancellationReducer from './sessionRemoval';\nimport adminSettingsReducer from './adminSettings';\nimport notificationReducer from './notifications';\nimport newSessionReducer from './newSessions';\nimport maintenanceReducer from './maintenance';\nimport chatReducer from './chat';\nimport availabilityReducer from './availability';\nimport alertReducer from './alert';\nimport jiraReducer from './jira';\nimport helpReducer from './help';\nimport menteeProvidersReducer from './menteeProviders';\nimport openSessionsReducer from './openSessions';\nimport statesReducer from './states';\nimport noticesReducer from './notices';\nimport feedbackTagsReducer from './feedbackTags';\nimport ratingsReducer from './ratings';\nimport billingReducer from './billing';\nimport sessionLogReducer from './sessionLog';\nimport scheduleReducer from './schedule';\nimport feedReducer from './feed';\nimport sessionUpdatesReducer from './sessionUpdates';\n\nconst rootReducer = combineReducers({\n provider: providerReducer,\n client: clientReducer,\n users: usersReducer,\n requests: requestsReducer,\n adminSettings: adminSettingsReducer,\n sessionCancellation: sessionCancellationReducer,\n notifications: notificationReducer,\n newSessions: newSessionReducer,\n maintenance: maintenanceReducer,\n chat: chatReducer,\n availability: availabilityReducer,\n alert: alertReducer,\n jira: jiraReducer,\n help: helpReducer,\n menteeProviders: menteeProvidersReducer,\n openSessions: openSessionsReducer,\n states: statesReducer,\n notices: noticesReducer,\n feedbackTags: feedbackTagsReducer,\n ratings: ratingsReducer,\n billing: billingReducer,\n sessionLog: sessionLogReducer,\n schedule: scheduleReducer,\n feed: feedReducer,\n sessionUpdates: sessionUpdatesReducer,\n});\n\nexport type RootState = ReturnType;\n\nexport default rootReducer;\n","import { Middleware, MiddlewareAPI } from 'redux';\nimport { isRejectedWithValue } from '@reduxjs/toolkit';\nimport { setAlertMessage } from '../modules/alert';\n\nconst HandleErrorResponses: Middleware = (api: MiddlewareAPI) => (\n next\n) => async (action) => {\n if (isRejectedWithValue(action)) {\n api.dispatch(\n setAlertMessage({\n message:\n 'An unexpected error occurred, please contact support to resolve the issue',\n autoHideDuration: 6000,\n })\n );\n }\n\n next(action);\n};\n\nexport default HandleErrorResponses;\n","import { Middleware } from 'redux';\nimport { forEach } from 'lodash';\n\nconst addNameProperty = (data: any): any => {\n if (Array.isArray(data)) {\n return data.map((item) => addNameProperty(item));\n }\n\n if (\n typeof data === 'object' &&\n data !== null &&\n data.firstName &&\n data.lastName &&\n !('name' in data)\n ) {\n Object.defineProperty(data, 'name', {\n get() {\n return `${this.firstName} ${this.lastName}`;\n },\n enumerable: true,\n configurable: true,\n });\n }\n\n if (typeof data === 'object' && data !== null) {\n forEach(data, (item) => {\n if (typeof item === 'object' && item !== null) {\n addNameProperty(item);\n }\n });\n }\n\n return data;\n};\n\nconst namePropertyMiddleware: Middleware = () => (next) => (action) => {\n const modifiedData = addNameProperty(action.payload);\n\n return next({ ...action, payload: modifiedData });\n};\n\nexport default namePropertyMiddleware;\n","import {\n configureStore,\n getDefaultMiddleware,\n Action,\n ThunkAction,\n} from '@reduxjs/toolkit';\nimport { TypedUseSelectorHook, useDispatch, useSelector } from 'react-redux';\n\nimport rootReducer, { RootState } from './modules/rootReducer';\nimport HandleErrorResponses from './middleware/HandleErrorResponses';\nimport namePropertyMiddleware from './middleware/namePropertyMiddleware';\n\nconst middleware = [\n ...getDefaultMiddleware({\n immutableCheck: false,\n serializableCheck: false,\n }),\n HandleErrorResponses,\n namePropertyMiddleware,\n] as const;\nconst preloadedState = {};\n\nconst store = configureStore({\n reducer: rootReducer,\n middleware,\n devTools: process.env.NODE_ENV !== 'production',\n preloadedState,\n});\n\nif (process.env.NODE_ENV === 'development' && module.hot) {\n module.hot.accept('./modules/rootReducer', () => {\n const newRootReducer = require('./modules/rootReducer').default;\n store.replaceReducer(newRootReducer);\n });\n}\nexport default store;\nexport type AppThunk = ThunkAction<\n ReturnType,\n RootState,\n unknown,\n Action\n>;\nexport type AppDispatch = typeof store.dispatch;\nexport const useAppDispatch = () => useDispatch();\nexport const useAppSelector: TypedUseSelectorHook = useSelector;\nexport type AsyncState = 'pending' | 'success' | 'failed';\n","import React from 'react';\nimport { makeStyles, Theme, Switch, SwitchProps } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n width: 64,\n height: 'unset',\n padding: 10,\n },\n switchBase: {\n padding: 10,\n },\n thumb: {\n width: 24,\n height: 24,\n border: `0.5px solid ${theme.palette.grey[300]}`,\n borderRadius: 10,\n boxShadow:\n '0px 2px 4px rgba(97, 97, 97, 0.18), 0px 4px 8px rgba(97, 97, 97, 0.18);',\n\n '$checked &': {\n border: 'none',\n },\n },\n track: {\n height: 24,\n borderRadius: 10,\n backgroundColor: theme.palette.grey[500],\n '$switchBase$checked + &': {\n backgroundColor: theme.palette.kyoBlue.main,\n opacity: 0.3,\n },\n },\n checked: {\n color: theme.palette.kyoBlue.main,\n '&$disabled': {\n color: theme.palette.kyoBlue.main,\n opacity: 0.4,\n },\n },\n disabled: {\n color: theme.palette.grey[300],\n },\n}));\n\nconst StyledSwitch = (props: SwitchProps) => {\n const classes = useStyles();\n return ;\n};\n\nexport default StyledSwitch;\n","import React from 'react';\n\nimport { Link, LinkProps } from '@material-ui/core'; // Import using relative path\n\ndeclare global {\n interface Navigator {\n msSaveBlob?: (blob: any, defaultName?: string) => boolean;\n }\n\n interface Window {\n opera: any;\n }\n}\n\nfunction pad(num: number) {\n // Ensure date values are double digits\n return num < 10 ? `0${num}` : num;\n}\nfunction formatDate(date: Date) {\n return [\n date.getUTCFullYear(),\n pad(date.getUTCMonth() + 1),\n pad(date.getUTCDate()),\n 'T',\n pad(date.getUTCHours()),\n `${pad(date.getUTCMinutes())}00Z`,\n ].join('');\n}\n// determine if a mobile browser is being used\nfunction isMobile() {\n let mobile = false;\n\n (function (a) {\n if (\n /(android|bb\\d+|meego).+mobile|avantgo|bada\\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(\n a\n ) ||\n // eslint-disable-next-line no-useless-escape\n /1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\\-(n|u)|c55\\/|capi|ccwa|cdm\\-|cell|chtm|cldc|cmd\\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\\-s|devi|dica|dmob|do(c|p)o|ds(12|\\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\\-|_)|g1 u|g560|gene|gf\\-5|g\\-mo|go(\\.w|od)|gr(ad|un)|haie|hcit|hd\\-(m|p|t)|hei\\-|hi(pt|ta)|hp( i|ip)|hs\\-c|ht(c(\\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\\-(20|go|ma)|i230|iac( |\\-|\\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\\/)|klon|kpt |kwc\\-|kyo(c|k)|le(no|xi)|lg( g|\\/(k|l|u)|50|54|\\-[a-w])|libw|lynx|m1\\-w|m3ga|m50\\/|ma(te|ui|xo)|mc(01|21|ca)|m\\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\\-2|po(ck|rt|se)|prox|psio|pt\\-g|qa\\-a|qc(07|12|21|32|60|\\-[2-7]|i\\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\\-|oo|p\\-)|sdk\\/|se(c(\\-|0|1)|47|mc|nd|ri)|sgh\\-|shar|sie(\\-|m)|sk\\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\\-|v\\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\\-|tdg\\-|tel(i|m)|tim\\-|t\\-mo|to(pl|sh)|ts(70|m\\-|m3|m5)|tx\\-9|up(\\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\\-|your|zeto|zte\\-/i.test(\n a.substr(0, 4)\n )\n )\n mobile = true;\n })(window.navigator.userAgent || window.navigator.vendor || window.opera);\n\n return mobile;\n}\n\nfunction buildUrl(\n event: {\n title: string;\n description?: string;\n location?: string;\n startDate: Date;\n endDate: Date;\n calendarType?: 'google';\n },\n type?: 'google'\n) {\n const { startDate, endDate, title, description = '', location = '' } = event;\n let calendarUrl = '';\n\n // allow mobile browsers to open the gmail data URI within native calendar app\n // type = (type == \"google\" && this.isMobile()) ? \"outlook\" : type;\n\n switch (type) {\n case 'google':\n calendarUrl = 'https://calendar.google.com/calendar/render';\n calendarUrl += '?action=TEMPLATE';\n calendarUrl += `&dates=${formatDate(startDate)}`;\n calendarUrl += `/${formatDate(endDate)}`;\n calendarUrl += `&location=${encodeURIComponent(location)}`;\n calendarUrl += `&text=${encodeURIComponent(title)}`;\n calendarUrl += `&details=${encodeURIComponent(description)}`;\n break;\n default:\n calendarUrl = [\n 'BEGIN:VCALENDAR',\n 'VERSION:2.0',\n 'BEGIN:VEVENT',\n `DTSTART:${formatDate(startDate)}`,\n `DTEND:${formatDate(endDate)}`,\n `SUMMARY:${title}`,\n `DESCRIPTION:${description}`,\n `LOCATION:${location}`,\n 'BEGIN:VALARM',\n 'TRIGGER:-PT15M',\n 'REPEAT:1',\n 'DURATION:PT15M',\n 'ACTION:DISPLAY',\n 'DESCRIPTION:Reminder',\n 'END:VALARM',\n 'END:VEVENT',\n 'END:VCALENDAR',\n ].join('\\n');\n\n if (isMobile()) {\n calendarUrl = encodeURI(\n `data:text/calendar;charset=utf8,${calendarUrl}`\n );\n }\n }\n\n return calendarUrl;\n}\ninterface CalendarEventProps {\n title: string;\n description?: string;\n location?: string;\n startDate: Date | undefined | '';\n endDate: Date | undefined | '';\n calendarType?: 'google';\n}\nconst CalendarEvent = (\n props: CalendarEventProps & LinkProps<'button', { component: 'button' }>\n) => {\n const {\n title,\n description,\n location,\n startDate,\n endDate,\n calendarType,\n children,\n ...rest\n } = props;\n\n if (!startDate || !endDate) {\n return null;\n }\n const saveCalInvite = () => {\n // Create the .ics URL\n const url = buildUrl(\n { title, description, location, startDate, endDate },\n calendarType\n );\n if (url.startsWith('data') || url.startsWith('BEGIN')) {\n const blob = new Blob([url], { type: 'text/calendar;charset=utf-8' });\n\n if (/msie\\s|trident\\/|edge\\//i.test(window.navigator.userAgent)) {\n // Open/Save link in IE and Edge\n window.navigator.msSaveBlob?.(blob, 'download.ics');\n } else {\n // Open/Save link in Modern Browsers\n const icsURL = window.URL.createObjectURL(blob);\n const tempLink = document.createElement('a');\n tempLink.href = icsURL;\n tempLink.setAttribute('download', 'download.ics');\n tempLink.click();\n }\n } else {\n window.open(url, '_blank');\n }\n };\n\n return (\n {\n saveCalInvite();\n }}\n >\n {children}\n \n );\n};\n\nexport default CalendarEvent;\n","export const SCH_PHONE_NUMBER = '18772646747';\n\nexport const SCH_PHONE_NUMBER_FORMATTED = '1 (877) 264 6747';\n\nexport const SCH_EMAIL = 'scheduling@kyocare.com';\n\nexport const SCH_KYOCARE = 'sch@kyocare.com';\n\nexport const SUPPORT_EMAIL = 'portal-support@kyocare.com';\n\nexport const KYO_EMAIL = 'cs@kyocare.com';\n\nexport const PROVIDER_MIN_NEW_SESSIONS = 1;\n\nexport const SCHEDULING_POLICIES_AND_PROCEDURES_URL =\n 'https://sites.google.com/kyocare.com/portal/scheduling-policies-and-procedures';\n\nexport const REQUEST_TIME_OFF_URL =\n 'https://jira.kyocare.com/servicedesk/customer/portal/5/create/62';\n\nexport const CHANGE_INSURANCE_PLAN_LINK =\n 'https://docs.google.com/forms/d/15i8KcxHQq9n-g02oN-Ut7LJ5EL9KQzsXgGI_sED7H0E/viewform?edit_requested=true';\n\nexport const CANCELLATIONS_LAST_DAYS = 90;\n\nexport const PREFERRED_BLOCK_MIN_INTERVAL = 3;\n\nexport const TWO_WEEKS = 14;\n\nexport const KYO_CARE_APP = 'https://kyocare.com/about-us/kyo-care-app/';\n\nexport const KYO_CLIENT_INSURANCE_SWITCH =\n 'https://docs.google.com/forms/d/e/1FAIpQLSe6imLyceOW5aWCY5Ltd5WNNecMSNqma3hI96qzAH91PGeG_w/viewform';\n\nexport const ABA_INFO_FOR_FAMILIES =\n 'https://kyocare.com/autism-aba-therapy-faqs';\n\nexport const CAREGIVER_RESOURCES =\n 'https://kyocare.com/autism-resources-for-caregivers/';\n\nexport const KYO_WEB_AND_APP_PRIVACY_POLICY =\n 'https://kyocare.com/privacy-policy/';\n\nexport const CONTACT_BILLING = 'clientbilling@kyocare.com';\n\nexport const KYO_CARE_WEB = 'https://portal.kyocare.com';\n\nexport const CENTRAL_REACH_URL =\n 'https://members.centralreach.com/#scheduling/manage/';\n\nexport const OPEN_SESSION_REQUEST = 'https://forms.gle/4npfw4idYSYVeyPg6';\n\nexport const KYO_CLIMB_INTRANET =\n 'https://sites.google.com/kyocare.com/portal/kyo-climb';\n\nexport const SHORT_WEEK_DAYS = ['S', 'M', 'T', 'W', 'T', 'F', 'S'];\nexport const DISTRICT_PAYER_TYPE = 'District';\n\nexport const REPORT_SESSION_UPDATE_URL =\n 'https://docs.google.com/forms/d/e/1FAIpQLSd00Jtw51-LMwsiu3mnNeLtqZy1rmVfvNSZL43eIsWeeoLrBQ/viewform';\n","import { MUIDataTableOptions } from 'mui-datatables';\nimport { AvailabilityBlock } from '../../../redux/modules/availability';\nimport { AvailabilityType } from '../../../shared/constants';\nimport { ScheduledSession } from '../../../types/types';\nimport { AvailabilityStatus } from '../../../shared/types';\nimport { ClientSessionDetailProvider } from '../../../components/SessionCard/ClientSessionDetails';\n\nexport enum PageMode {\n schedule = 'schedule',\n remove = 'remove',\n temporary = 'temporary',\n standard = 'standard',\n}\n\nexport type PreferencesKeys =\n | 'preferredBlock1Start'\n | 'preferredBlock3Start'\n | 'preferredBlock3End';\n\nexport enum MyScheduleViewMode {\n grid = 'grid',\n list = 'list',\n /** `mobileGrid` must be set only depending on the screen size */\n mobileGrid = 'mobileGrid',\n}\n\nexport type AvailabilityByWeek = {\n blocks: AvailabilityBlock[];\n originalId: number;\n preferences: {\n preferredBlock1Start?: string | null;\n preferredBlock3Start?: string | null;\n preferredBlock3End?: string | null;\n };\n type: AvailabilityType;\n status?: AvailabilityStatus;\n};\n\nexport interface UserSpecificMatrixCardProps {\n session: ScheduledSession;\n children: React.ReactNode;\n cancelMode: boolean;\n}\n\nexport interface UserSpecificDialogContentProps {\n session: ScheduledSession;\n closeDialog?: () => void;\n}\n\nexport interface UserSpecificSessionsTableProps {\n data: Array;\n selectMode: boolean;\n sessionsToRemove: ScheduledSession[];\n onRowSelection: (\n scheduledSession: ScheduledSession,\n checked: boolean\n ) => void;\n options?: MUIDataTableOptions;\n isSmallScreen: boolean;\n}\n\nexport interface UserSpecificSessionToRemoveCardProps {\n session: ScheduledSession;\n}\n\nexport interface SessionDetailsProps {\n session: ScheduledSession;\n hideButtons?: boolean;\n extendedDetails?: boolean;\n provider?: ClientSessionDetailProvider;\n styles?: Partial<\n Record<'root' | 'subOfferAllowedUntil' | 'title' | 'detail', string>\n >;\n}\n","module.exports = __webpack_public_path__ + \"static/media/shortTermType.400bea52.svg\";","import {\n createAsyncThunk,\n createSlice,\n isAnyOf,\n PayloadAction,\n SerializedError,\n} from '@reduxjs/toolkit';\nimport { Moment } from 'moment';\nimport availabilityApi, {\n GetAvailabilityFilter,\n} from '../../api/availabilityApi';\nimport scheduleApi from '../../api/scheduleApi';\nimport { AvailabilityType } from '../../shared/constants';\nimport { AvailabilityStatus } from '../../shared/types';\nimport { ScheduledSession } from '../../types/types';\nimport { fetchCurrentClientById } from './client';\nimport {\n AvailabilityByWeek,\n PageMode,\n} from '../../commonPages/MySchedule/types/types';\nimport { checkIsPreferenceSelectDisabled } from '../../utils/helpers';\nimport { getRemoveSessionVariant } from '../../commonPages/MySchedule/utils/statusHelpers';\nimport {\n findStandardAvailability,\n findStandardAvailabilityByWeek,\n findTempAvailabilityByWeek,\n} from '../../commonPages/MySchedule/utils/helpers';\n\nconst updateWeeklyAvailabilityState = (\n state: AvailabilityState,\n availabilityByWeek: AvailabilityByWeek | null\n) => {\n if (!availabilityByWeek) {\n state.availabilityByWeek = null;\n return;\n }\n\n const { blocks, preferences } = availabilityByWeek;\n\n const isPreferredBlock1Disabled =\n blocks && checkIsPreferenceSelectDisabled(1, blocks);\n\n const isPreferredBlock3Disabled =\n blocks && checkIsPreferenceSelectDisabled(3, blocks);\n\n state.isPreferredBlock1Disabled = !!isPreferredBlock1Disabled;\n state.isPreferredBlock3Disabled = !!isPreferredBlock3Disabled;\n\n state.availabilityByWeek = {\n ...availabilityByWeek,\n preferences: {\n preferredBlock1Start: isPreferredBlock1Disabled\n ? null\n : preferences.preferredBlock1Start ||\n state.preferredTimeBlockOptions?.block1StartOptions[0],\n preferredBlock3Start: isPreferredBlock3Disabled\n ? null\n : preferences.preferredBlock3Start ||\n state.preferredTimeBlockOptions?.block3StartOptions[0],\n preferredBlock3End: isPreferredBlock3Disabled\n ? null\n : preferences.preferredBlock3End ||\n state.preferredTimeBlockOptions?.block3EndOptions[0],\n },\n };\n};\n\nexport interface AvailabilityBlock {\n id: number;\n timeBlockDayOfWeekId: number;\n isAvailable: boolean;\n timeBlockDayOfWeek: {\n id: number;\n timeBlockId: number;\n dayOfWeekId: number;\n timeBlock: {\n id: number;\n start: string;\n end: string;\n };\n dayOfWeek: {\n id: number;\n name: string;\n };\n };\n postOS?: boolean;\n}\n\nexport interface Availability {\n id: number;\n type: AvailabilityType;\n submittedByProviderId: number;\n submittedByUserId: number;\n clientId: number;\n providerId: number;\n startDate: string;\n endDate: string;\n effectiveDate: string;\n createdAt: string;\n status: AvailabilityStatus;\n availabilityBlocks: AvailabilityBlock[];\n submittedByProvider: {\n id: number;\n email: string;\n };\n preferredBlock1Start?: string;\n preferredBlock3Start?: string;\n preferredBlock3End?: string;\n}\n\nexport type PartialAvailability = Partial<\n Omit & {\n availabilityBlocks: Partial[];\n }\n>;\n\nexport type CreateTimeOffParams = {\n providerId: number | undefined;\n clientId: number | undefined;\n startDate: string;\n endDate: string;\n};\n\nexport interface PreferredTimeBlockOptions {\n block1StartOptions: string[];\n block3StartOptions: string[];\n block3EndOptions: string[];\n}\n\nexport enum AVAILABILITY_ACTION_STATUS {\n EDIT = 'EDIT',\n ADD = 'ADD',\n PASSIVE = 'PASSIVE',\n ADD_TEMPORARY = 'ADD_TEMPORARY',\n EDIT_TEMPORARY = 'EDIT_TEMPORARY',\n}\n\nexport const AvailabilityLongTermActions = [\n AVAILABILITY_ACTION_STATUS.ADD,\n AVAILABILITY_ACTION_STATUS.EDIT,\n];\n\nexport const AvailabilityShortTermActions = [\n AVAILABILITY_ACTION_STATUS.ADD_TEMPORARY,\n AVAILABILITY_ACTION_STATUS.EDIT_TEMPORARY,\n];\n\ninterface AvailabilityState {\n stAvailability: Availability[];\n ltAvailability: Availability[];\n loading: boolean;\n availabilityIdentifier: symbol;\n action: {\n status: AVAILABILITY_ACTION_STATUS;\n availability?: Availability;\n loading: boolean;\n succeeded: boolean;\n failed: boolean;\n };\n preferredTimeBlockOptions: PreferredTimeBlockOptions | null;\n preferredTimeBlockOptionsLoading: boolean;\n preferredTimeBlockOptionsError: SerializedError | null;\n\n sessionsToRemove: ScheduledSession[] | null;\n sessionsToRemoveLoading: boolean;\n sessionsToRemoveError: SerializedError | null;\n\n availabilityByWeek: AvailabilityByWeek | null;\n standardStartDate?: string;\n lastSelectedBlock: number | null;\n\n isAvailabilityChanged: boolean;\n isReviewChanges: boolean;\n isStandardUpdate: boolean;\n isPreferredBlock1Disabled: boolean;\n isPreferredBlock3Disabled: boolean;\n}\n\nconst initialActionState = {\n status: AVAILABILITY_ACTION_STATUS.PASSIVE,\n loading: false,\n succeeded: false,\n failed: false,\n};\n\nconst initialState: AvailabilityState = {\n stAvailability: [],\n ltAvailability: [],\n availabilityIdentifier: Symbol(undefined),\n loading: false,\n action: initialActionState,\n preferredTimeBlockOptions: null,\n preferredTimeBlockOptionsLoading: false,\n preferredTimeBlockOptionsError: null,\n\n availabilityByWeek: null,\n standardStartDate: undefined,\n lastSelectedBlock: null,\n\n sessionsToRemove: null,\n sessionsToRemoveLoading: false,\n sessionsToRemoveError: null,\n\n isAvailabilityChanged: false,\n isReviewChanges: false,\n isStandardUpdate: false,\n isPreferredBlock1Disabled: false,\n isPreferredBlock3Disabled: false,\n};\n\nexport const fetchPreferredTimeBlockOptions = createAsyncThunk(\n 'availability/fetchPreferredTimeBlockOptions',\n () => availabilityApi.fetchPreferredTimeBlockOptions()\n);\n\nexport const fetchAvailability = createAsyncThunk(\n 'availability/fetchAvailability',\n (filters: GetAvailabilityFilter) => availabilityApi.fetchAvailability(filters)\n);\n\nexport const deleteAvailability = createAsyncThunk(\n 'availability/deleteAvailability',\n ({ id }: { id: number }) => availabilityApi.deleteAvailability(id)\n);\n\nexport const createAvailability = createAsyncThunk(\n 'availability/createAvailability',\n (payload: PartialAvailability, { rejectWithValue }) =>\n availabilityApi\n .createAvailability(payload)\n .catch((e) => rejectWithValue('Creating availability fails'))\n);\n\nexport const createTimeOff = createAsyncThunk(\n 'availability/createTimeOff',\n (payload: CreateTimeOffParams, { rejectWithValue }) =>\n availabilityApi\n .createTimeOff(payload)\n .catch((e) => rejectWithValue('Creating availability fails'))\n);\n\nexport const updateAvailability = createAsyncThunk(\n 'availability/updateAvailability',\n (\n payload: { id: number; availability: PartialAvailability },\n { rejectWithValue }\n ) =>\n availabilityApi\n .updateAvailability(payload.id, payload.availability)\n .catch((e) => rejectWithValue('Updating availability fails'))\n);\n\nexport const createSTAvailability = createAsyncThunk(\n 'availability/createSTAvailability',\n (payload: PartialAvailability, { rejectWithValue }) =>\n availabilityApi\n .createSTAvailability(payload)\n .catch((e) => rejectWithValue('Creating availability fails'))\n);\n\nexport const updateSTAvailability = createAsyncThunk(\n 'availability/updateSTAvailability',\n (\n payload: { id: number; availability: PartialAvailability },\n { rejectWithValue }\n ) =>\n availabilityApi\n .updateSTAvailability(payload.id, payload.availability)\n .catch((e) => rejectWithValue('Updating availability fails'))\n);\n\nexport const fetchSessionsToRemoveClient = createAsyncThunk(\n 'availability/fetchSessionsToRemoveClient',\n async (arg: {\n clientId: number;\n startDate: string;\n endDate: string;\n timeBlockDayOfWeekIds: number[];\n isCancellableByClient?: boolean;\n filterCancelled?: boolean;\n }) => {\n return scheduleApi.fetchClientFullSchedule(\n arg.clientId,\n arg.startDate,\n arg.endDate,\n true,\n arg.timeBlockDayOfWeekIds,\n arg.isCancellableByClient,\n arg.filterCancelled\n );\n }\n);\n\nexport const fetchSessionsToRemoveProvider = createAsyncThunk(\n 'availability/fetchSessionsToRemoveProvider',\n async (arg: {\n providerId: number;\n startDate: string;\n endDate: string;\n timeBlockDayOfWeekIds: number[];\n isCancellableByProvider?: boolean;\n filterCancelled?: boolean;\n }) => {\n return scheduleApi.fetchProviderFullSchedule({\n ...arg,\n });\n }\n);\n\nconst availabilitySlice = createSlice({\n name: 'availability',\n initialState,\n reducers: {\n setActionStatus: (\n state,\n action: PayloadAction<{\n status: AVAILABILITY_ACTION_STATUS;\n availability?: Availability;\n }>\n ) => {\n if (action.payload.status === AVAILABILITY_ACTION_STATUS.PASSIVE) {\n state.action = initialActionState;\n } else {\n state.action.status = action.payload.status;\n state.action.availability = action.payload.availability;\n }\n },\n clearSessionsToRemove: (state) => {\n state.sessionsToRemove = null;\n state.sessionsToRemoveLoading = false;\n },\n setAvailabilityChanged: (\n state,\n action: PayloadAction\n ) => {\n state.isAvailabilityChanged = action.payload;\n },\n setReviewChanges: (\n state,\n action: PayloadAction\n ) => {\n state.isReviewChanges = action.payload;\n },\n setStandardUpdate: (\n state,\n action: PayloadAction\n ) => {\n state.isStandardUpdate = action.payload;\n },\n\n setAvailabilityByWeek: (\n state,\n action: PayloadAction<{ pageMode: PageMode; startOfWeek: Moment }>\n ) => {\n const { pageMode, startOfWeek } = action.payload;\n let avail = null;\n if (pageMode === PageMode.temporary) {\n avail =\n findTempAvailabilityByWeek(state.stAvailability, startOfWeek) ||\n findStandardAvailabilityByWeek(state.ltAvailability, startOfWeek) ||\n findStandardAvailability(state.ltAvailability);\n }\n\n if (pageMode === PageMode.standard) {\n if (state.isStandardUpdate) {\n avail = findStandardAvailability(state.ltAvailability);\n } else {\n avail = state.ltAvailability.find(\n (item) => item.status === AvailabilityStatus.Current\n );\n }\n }\n\n if (!avail) {\n updateWeeklyAvailabilityState(state, null);\n return;\n }\n\n const availabilityByWeek: AvailabilityByWeek = {\n blocks: avail.availabilityBlocks,\n originalId: avail.id,\n preferences: {\n preferredBlock1Start: avail?.preferredBlock1Start,\n preferredBlock3Start: avail?.preferredBlock3Start,\n preferredBlock3End: avail?.preferredBlock3End,\n },\n type: avail.type,\n status: avail.status,\n };\n\n updateWeeklyAvailabilityState(state, availabilityByWeek);\n },\n updateAvailabilityByWeek: (\n state,\n action: PayloadAction\n ) => {\n updateWeeklyAvailabilityState(state, action.payload);\n },\n setStandardStartDate: (state, action) => {\n state.standardStartDate = action.payload;\n },\n setLastSelectedBlock: (state, action) => {\n state.lastSelectedBlock = action.payload;\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(fetchAvailability.pending, (state) => {\n state.loading = true;\n })\n .addCase(fetchAvailability.rejected, (state) => {\n state.loading = false;\n })\n .addCase(fetchAvailability.fulfilled, (state, action) => {\n const stAvailability = action.payload.filter(\n (avail) => avail.type === AvailabilityType.ShortTerm\n );\n const ltAvailability = action.payload.filter(\n (avail) => avail.type === AvailabilityType.LongTerm\n );\n\n state.loading = false;\n state.stAvailability = stAvailability;\n state.ltAvailability = ltAvailability;\n })\n .addCase(fetchPreferredTimeBlockOptions.pending, (state) => {\n state.preferredTimeBlockOptionsLoading = true;\n })\n .addCase(fetchPreferredTimeBlockOptions.fulfilled, (state, action) => {\n state.preferredTimeBlockOptionsLoading = false;\n state.preferredTimeBlockOptions = action.payload;\n })\n .addCase(fetchPreferredTimeBlockOptions.rejected, (state, action) => {\n state.preferredTimeBlockOptionsLoading = false;\n state.preferredTimeBlockOptionsError = action.error;\n })\n .addCase(deleteAvailability.fulfilled, (state, { meta }) => {\n state.availabilityIdentifier = Symbol(meta.requestId);\n })\n .addCase(fetchCurrentClientById.pending, () => initialState)\n .addMatcher(\n isAnyOf(\n fetchSessionsToRemoveClient.pending,\n fetchSessionsToRemoveProvider.pending\n ),\n (state) => {\n state.sessionsToRemove = null;\n state.sessionsToRemoveLoading = true;\n }\n )\n .addMatcher(\n isAnyOf(\n fetchSessionsToRemoveClient.fulfilled,\n fetchSessionsToRemoveProvider.fulfilled\n ),\n (state, action) => {\n state.sessionsToRemoveLoading = false;\n\n const sessionsWithRemoveVariant = action.payload.map((s) => {\n const removeSessionVariant = getRemoveSessionVariant(s);\n return {\n ...s,\n removeSessionVariant,\n };\n });\n\n state.sessionsToRemove = sessionsWithRemoveVariant;\n }\n )\n .addMatcher(\n isAnyOf(\n fetchSessionsToRemoveClient.rejected,\n fetchSessionsToRemoveProvider.rejected\n ),\n (state, action) => {\n state.sessionsToRemoveLoading = false;\n state.sessionsToRemoveError = action.error;\n }\n )\n .addMatcher(\n isAnyOf(\n createAvailability.pending,\n updateAvailability.pending,\n createSTAvailability.pending,\n updateSTAvailability.pending,\n createTimeOff.pending\n ),\n (state) => {\n state.action.loading = true;\n }\n )\n .addMatcher(\n isAnyOf(\n createAvailability.fulfilled,\n updateAvailability.fulfilled,\n createSTAvailability.fulfilled,\n updateSTAvailability.fulfilled,\n createTimeOff.fulfilled\n ),\n (state) => {\n state.action.succeeded = true;\n state.action.loading = false;\n }\n )\n .addMatcher(\n isAnyOf(\n createAvailability.rejected,\n updateAvailability.rejected,\n createSTAvailability.rejected,\n updateSTAvailability.rejected,\n createTimeOff.rejected\n ),\n (state) => {\n state.action.failed = true;\n state.action.loading = false;\n }\n );\n },\n});\nexport const {\n setActionStatus,\n clearSessionsToRemove,\n setAvailabilityChanged,\n setReviewChanges,\n setStandardUpdate,\n setAvailabilityByWeek,\n updateAvailabilityByWeek,\n setStandardStartDate,\n setLastSelectedBlock,\n} = availabilitySlice.actions;\n\nexport default availabilitySlice.reducer;\n","import queryString from 'query-string';\n\nimport {\n Availability,\n PartialAvailability,\n CreateTimeOffParams,\n} from '../redux/modules/availability';\nimport { AvailabilityType } from '../shared/constants';\nimport { AvailabilityStatus } from '../shared/types';\nimport requester from './requester';\n\nexport interface GetAvailabilityFilter {\n providerId?: number;\n clientId?: number;\n type?: AvailabilityType;\n excludeStatuses?: AvailabilityStatus[];\n}\n\nconst fetchAvailability = async (\n filters: GetAvailabilityFilter\n): Promise => {\n const query = queryString.stringify(filters, {\n arrayFormat: 'bracket',\n });\n\n return requester\n .get(`availability?${query}`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst deleteAvailability = async (id: number) => {\n return requester\n .delete(`availability/${id}`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst createAvailability = async (availability: PartialAvailability) => {\n return requester\n .post(`availability`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(availability),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst createTimeOff = async (timeOffData: CreateTimeOffParams) => {\n return requester\n .post(`availability/time-off`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(timeOffData),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst updateAvailability = async (\n id: number,\n availability: PartialAvailability\n) => {\n return requester\n .put(`availability/${id}`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(availability),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst createSTAvailability = async (availability: PartialAvailability) => {\n return requester\n .post('availability/short-term', {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(availability),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst updateSTAvailability = async (\n id: number,\n availability: PartialAvailability\n) => {\n return requester\n .put(`availability/short-term/${id}`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(availability),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchPreferredTimeBlockOptions = async () => {\n return requester\n .get(`availability/preferred-time-block-options`, {\n headers: { 'Content-Type': 'application/json' },\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n fetchAvailability,\n deleteAvailability,\n createAvailability,\n createTimeOff,\n createSTAvailability,\n updateSTAvailability,\n updateAvailability,\n fetchPreferredTimeBlockOptions,\n};\n","import { Divider, Typography } from '@material-ui/core';\nimport { makeStyles, Theme } from '@material-ui/core/styles';\nimport clsx from 'clsx';\n\nimport React from 'react';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n heading: {\n marginBottom: theme.spacing(2),\n color: theme.palette.grey[700],\n },\n divider: {\n width: '100%',\n [theme.breakpoints.down('xs')]: {\n display: 'none',\n },\n },\n}));\n\ninterface ScreenTitleProps {\n title: string;\n Comp?: React.ReactElement;\n className?: string;\n}\n\nconst ScreenTitle = (props: ScreenTitleProps) => {\n const { title, Comp, className } = props;\n const classes = useStyles();\n\n return (\n <>\n \n {title} {Comp}\n \n \n \n );\n};\n\nexport default ScreenTitle;\n","import React from 'react';\nimport { makeStyles, Theme } from '@material-ui/core';\nimport { ScheduledSession, UserType } from '../../../../types/types';\nimport { getIconForStatus } from '../../utils/statusHelpers';\nimport SessionStatusText from './SessionStatusText';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n statusTitle: {\n display: 'flex',\n },\n statusText: {\n fontSize: 14,\n fontWeight: 700,\n marginLeft: theme.spacing(0.5),\n lineHeight: 1.2,\n },\n statusIcon: {\n width: '16px',\n height: '16px',\n },\n}));\n\ninterface SessionTitleByStatusProps {\n session: ScheduledSession;\n userType: UserType;\n fontSize?: number;\n}\n\nconst SessionTitleByStatus = ({\n fontSize,\n session,\n userType,\n}: SessionTitleByStatusProps) => {\n const classes = useStyles();\n const StatusIcon = getIconForStatus(session);\n\n return (\n
\n \n
\n \n {session.visibleToClient === false ? ' (Not Visible to Client)' : ''}\n
\n
\n );\n};\n\nexport default SessionTitleByStatus;\n","import {\n SessionUpdate,\n SessionUpdatePayload,\n} from '../types/sessionUpdates.types';\nimport requester from './requester';\n\ninterface CreateSessionUpdateDto extends SessionUpdatePayload {\n segmentId: number;\n providerId: number;\n}\n\nexport const createSessionUpdate = async (\n sessionUpdatesDto: CreateSessionUpdateDto\n) => {\n return requester\n .post(`session-updates`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(sessionUpdatesDto),\n })\n .then((response) => response.json())\n .then((response) => response.data as SessionUpdate);\n};\n\nexport const getSessionUpdateTypes = async () => {\n return requester\n .get(`session-updates/types`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n","import { createAsyncThunk, createSlice, PayloadAction } from '@reduxjs/toolkit';\nimport { ScheduledSession } from '../../types/types';\nimport * as sessionUpdatesApi from '../../api/sessionUpdatesApi';\nimport {\n SessionUpdate,\n SessionUpdatePayload,\n SessionUpdateTypeId,\n} from '../../types/sessionUpdates.types';\nimport { RootState } from './rootReducer';\nimport { fetchProviderFullSchedule } from './provider';\n\nexport interface SessionUpdateType {\n id: SessionUpdateTypeId;\n name: string;\n}\n\nexport interface SessionUpdatesState {\n scheduledSession: ScheduledSession | null;\n sessionUpdateTypes: SessionUpdateType[];\n sessionUpdateTypesLoading: boolean;\n selectedSessionUpdateTypeId: SessionUpdateTypeId | null;\n sessionUpdateSubmitting: boolean;\n submittedSessionUpdate: SessionUpdate | null;\n}\n\nconst initialState: SessionUpdatesState = {\n scheduledSession: null,\n sessionUpdateTypes: [],\n sessionUpdateTypesLoading: false,\n selectedSessionUpdateTypeId: null,\n sessionUpdateSubmitting: false,\n submittedSessionUpdate: null,\n};\n\nexport const submitSessionUpdate = createAsyncThunk<\n SessionUpdate | null,\n SessionUpdatePayload,\n { state: RootState }\n>('sessionUpdates/submitSessionUpdate', async (payload, { getState }) => {\n const { scheduledSession } = getState().sessionUpdates;\n const { provider } = getState().provider;\n\n if (!scheduledSession || !provider) {\n return null;\n }\n\n return sessionUpdatesApi.createSessionUpdate({\n segmentId: scheduledSession.segmentId,\n providerId: provider.id,\n ...payload,\n });\n});\n\nexport const fetchSessionUpdateTypes = createAsyncThunk(\n 'sessionUpdates/fetchSessionUpdateTypes',\n async () => {\n return sessionUpdatesApi.getSessionUpdateTypes();\n }\n);\n\nconst sessionUpdatesSlice = createSlice({\n name: 'sessionUpdates',\n initialState,\n reducers: {\n setScheduledSession: (\n state,\n action: PayloadAction\n ) => {\n state.scheduledSession = action.payload;\n },\n selectSessionUpdateTypeId: (\n state,\n action: PayloadAction\n ) => {\n state.selectedSessionUpdateTypeId = action.payload;\n },\n resetSessionUpdateState: () => initialState,\n },\n extraReducers: (builder) => {\n builder\n .addCase(fetchSessionUpdateTypes.pending, (state) => {\n state.sessionUpdateTypesLoading = true;\n })\n .addCase(fetchSessionUpdateTypes.fulfilled, (state, action) => {\n state.sessionUpdateTypes = action.payload;\n state.sessionUpdateTypesLoading = false;\n })\n .addCase(fetchSessionUpdateTypes.rejected, (state) => {\n state.sessionUpdateTypesLoading = false;\n })\n .addCase(submitSessionUpdate.pending, (state) => {\n state.sessionUpdateSubmitting = true;\n })\n .addCase(submitSessionUpdate.fulfilled, (state, action) => {\n state.submittedSessionUpdate = action.payload;\n state.sessionUpdateSubmitting = false;\n })\n .addCase(submitSessionUpdate.rejected, (state) => {\n state.sessionUpdateSubmitting = false;\n })\n .addCase(fetchProviderFullSchedule.fulfilled, (state, action) => {\n if (state.scheduledSession) {\n const refreshedScheduleSession = action.payload.find(\n (s) => s.segmentId === state.scheduledSession?.id\n );\n\n if (refreshedScheduleSession) {\n state.scheduledSession = refreshedScheduleSession;\n }\n }\n });\n },\n});\n\nexport const {\n setScheduledSession,\n selectSessionUpdateTypeId,\n resetSessionUpdateState,\n} = sessionUpdatesSlice.actions;\n\nexport default sessionUpdatesSlice.reducer;\n","import moment from 'moment/moment';\nimport useSettings from '../../../hooks/useSettings';\n\nconst useOptOutAllowedUntil = (createdAt: string) => {\n const { subOfferOptOutAllowedInHours } = useSettings();\n\n return moment(createdAt).add({\n hours: subOfferOptOutAllowedInHours,\n });\n};\n\nexport default useOptOutAllowedUntil;\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(\"rect\", {\n x: 0.5,\n y: 0.5,\n width: 138,\n height: 17,\n rx: 8.5,\n fill: \"white\",\n stroke: \"#E0E0E0\",\n strokeLinejoin: \"round\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M12.0755 13.165C11.2835 13.165 10.6088 12.9927 10.0515 12.648C9.49417 12.2997 9.067 11.8157 8.77 11.196C8.47667 10.5763 8.33 9.85767 8.33 9.04C8.33 8.22233 8.47667 7.50367 8.77 6.884C9.067 6.26433 9.49417 5.78217 10.0515 5.4375C10.6088 5.08917 11.2835 4.915 12.0755 4.915C12.8638 4.915 13.5367 5.08917 14.094 5.4375C14.655 5.78217 15.0822 6.26433 15.3755 6.884C15.6688 7.50367 15.8155 8.22233 15.8155 9.04C15.8155 9.85767 15.6688 10.5763 15.3755 11.196C15.0822 11.8157 14.655 12.2997 14.094 12.648C13.5367 12.9927 12.8638 13.165 12.0755 13.165ZM12.0755 12.0705C12.6365 12.0778 13.1022 11.955 13.4725 11.702C13.8465 11.4453 14.127 11.0897 14.314 10.635C14.501 10.1767 14.5945 9.645 14.5945 9.04C14.5945 8.435 14.501 7.907 14.314 7.456C14.127 7.00133 13.8465 6.6475 13.4725 6.3945C13.1022 6.1415 12.6365 6.01317 12.0755 6.0095C11.5145 6.00217 11.047 6.125 10.673 6.378C10.3027 6.631 10.024 6.98667 9.837 7.445C9.65 7.90333 9.55467 8.435 9.551 9.04C9.54733 9.645 9.639 10.1748 9.826 10.6295C10.013 11.0805 10.2935 11.4325 10.6675 11.6855C11.0452 11.9385 11.5145 12.0668 12.0755 12.0705ZM17.1326 13V5.08H20.3336C20.4106 5.08 20.5059 5.08367 20.6196 5.091C20.7332 5.09467 20.8414 5.10567 20.9441 5.124C21.3841 5.19367 21.7507 5.344 22.0441 5.575C22.3411 5.806 22.5629 6.0975 22.7096 6.4495C22.8562 6.8015 22.9296 7.19017 22.9296 7.6155C22.9296 8.0445 22.8562 8.435 22.7096 8.787C22.5629 9.139 22.3411 9.4305 22.0441 9.6615C21.7507 9.8925 21.3841 10.0428 20.9441 10.1125C20.8414 10.1272 20.7314 10.1382 20.6141 10.1455C20.5004 10.1528 20.4069 10.1565 20.3336 10.1565H18.2821V13H17.1326ZM18.2821 9.0675H20.2896C20.3629 9.0675 20.4436 9.06383 20.5316 9.0565C20.6232 9.04917 20.7094 9.03633 20.7901 9.018C21.0247 8.963 21.2136 8.86217 21.3566 8.7155C21.4996 8.56517 21.6022 8.39283 21.6646 8.1985C21.7269 8.00417 21.7581 7.80983 21.7581 7.6155C21.7581 7.42117 21.7269 7.22867 21.6646 7.038C21.6022 6.84367 21.4996 6.67317 21.3566 6.5265C21.2136 6.37617 21.0247 6.2735 20.7901 6.2185C20.7094 6.1965 20.6232 6.18183 20.5316 6.1745C20.4436 6.16717 20.3629 6.1635 20.2896 6.1635H18.2821V9.0675ZM26.2236 13V6.1635H23.5891V5.08H30.0076V6.1635H27.3731V13H26.2236ZM30.9977 9.4965V8.5725H34.2977V9.4965H30.9977ZM39.2524 13.165C38.4604 13.165 37.7857 12.9927 37.2284 12.648C36.671 12.2997 36.2439 11.8157 35.9469 11.196C35.6535 10.5763 35.5069 9.85767 35.5069 9.04C35.5069 8.22233 35.6535 7.50367 35.9469 6.884C36.2439 6.26433 36.671 5.78217 37.2284 5.4375C37.7857 5.08917 38.4604 4.915 39.2524 4.915C40.0407 4.915 40.7135 5.08917 41.2709 5.4375C41.8319 5.78217 42.259 6.26433 42.5524 6.884C42.8457 7.50367 42.9924 8.22233 42.9924 9.04C42.9924 9.85767 42.8457 10.5763 42.5524 11.196C42.259 11.8157 41.8319 12.2997 41.2709 12.648C40.7135 12.9927 40.0407 13.165 39.2524 13.165ZM39.2524 12.0705C39.8134 12.0778 40.279 11.955 40.6494 11.702C41.0234 11.4453 41.3039 11.0897 41.4909 10.635C41.6779 10.1767 41.7714 9.645 41.7714 9.04C41.7714 8.435 41.6779 7.907 41.4909 7.456C41.3039 7.00133 41.0234 6.6475 40.6494 6.3945C40.279 6.1415 39.8134 6.01317 39.2524 6.0095C38.6914 6.00217 38.2239 6.125 37.8499 6.378C37.4795 6.631 37.2009 6.98667 37.0139 7.445C36.8269 7.90333 36.7315 8.435 36.7279 9.04C36.7242 9.645 36.8159 10.1748 37.0029 10.6295C37.1899 11.0805 37.4704 11.4325 37.8444 11.6855C38.222 11.9385 38.6914 12.0668 39.2524 12.0705ZM47.4665 13.165C46.8468 13.165 46.2986 13.0385 45.822 12.7855C45.349 12.5288 44.9786 12.1713 44.711 11.713C44.4433 11.251 44.3095 10.7083 44.3095 10.085V5.0855L45.4755 5.08V10.0245C45.4755 10.3618 45.5323 10.6588 45.646 10.9155C45.7596 11.1722 45.9118 11.3867 46.1025 11.559C46.2931 11.7313 46.5058 11.8615 46.7405 11.9495C46.9788 12.0375 47.2208 12.0815 47.4665 12.0815C47.7158 12.0815 47.9578 12.0375 48.1925 11.9495C48.4308 11.8578 48.6453 11.7258 48.836 11.5535C49.0266 11.3812 49.177 11.1667 49.287 10.91C49.4006 10.6533 49.4575 10.3582 49.4575 10.0245V5.08H50.6235V10.085C50.6235 10.7047 50.4896 11.2455 50.222 11.7075C49.9543 12.1695 49.5821 12.5288 49.1055 12.7855C48.6325 13.0385 48.0861 13.165 47.4665 13.165ZM54.3565 13V6.1635H51.722V5.08H58.1405V6.1635H55.506V13H54.3565ZM60.7798 13L63.3538 5.08H65.0093L67.5833 13H66.3898L64.0193 5.773H64.3163L61.9733 13H60.7798ZM62.1163 11.2125V10.1345H66.2523V11.2125H62.1163ZM68.9 13V5.08H70.0495V11.9165H73.6355V13H68.9ZM74.8993 13V5.08H76.0488V11.9165H79.6348V13H74.8993ZM83.8793 13.165C83.0873 13.165 82.4126 12.9927 81.8553 12.648C81.298 12.2997 80.8708 11.8157 80.5738 11.196C80.2805 10.5763 80.1338 9.85767 80.1338 9.04C80.1338 8.22233 80.2805 7.50367 80.5738 6.884C80.8708 6.26433 81.298 5.78217 81.8553 5.4375C82.4126 5.08917 83.0873 4.915 83.8793 4.915C84.6676 4.915 85.3405 5.08917 85.8978 5.4375C86.4588 5.78217 86.886 6.26433 87.1793 6.884C87.4726 7.50367 87.6193 8.22233 87.6193 9.04C87.6193 9.85767 87.4726 10.5763 87.1793 11.196C86.886 11.8157 86.4588 12.2997 85.8978 12.648C85.3405 12.9927 84.6676 13.165 83.8793 13.165ZM83.8793 12.0705C84.4403 12.0778 84.906 11.955 85.2763 11.702C85.6503 11.4453 85.9308 11.0897 86.1178 10.635C86.3048 10.1767 86.3983 9.645 86.3983 9.04C86.3983 8.435 86.3048 7.907 86.1178 7.456C85.9308 7.00133 85.6503 6.6475 85.2763 6.3945C84.906 6.1415 84.4403 6.01317 83.8793 6.0095C83.3183 6.00217 82.8508 6.125 82.4768 6.378C82.1065 6.631 81.8278 6.98667 81.6408 7.445C81.4538 7.90333 81.3585 8.435 81.3548 9.04C81.3511 9.645 81.4428 10.1748 81.6298 10.6295C81.8168 11.0805 82.0973 11.4325 82.4713 11.6855C82.849 11.9385 83.3183 12.0668 83.8793 12.0705ZM90.2809 13L87.9819 5.08H89.1864L90.8529 11.0695L92.5194 5.0855L93.7294 5.08L95.3959 11.0695L97.0624 5.08H98.2724L95.9679 13H94.8239L93.1244 7.0765L91.4249 13H90.2809ZM99.4152 13V5.08H104.475V6.1635H100.565V8.3855H103.815V9.469H100.565V11.9165H104.475V13H99.4152ZM106.016 13V5.08H108.497C108.57 5.08 108.706 5.08183 108.904 5.0855C109.105 5.08917 109.298 5.10383 109.481 5.1295C110.101 5.2065 110.621 5.42833 111.043 5.795C111.468 6.16167 111.789 6.62733 112.006 7.192C112.222 7.753 112.33 8.369 112.33 9.04C112.33 9.71467 112.222 10.3343 112.006 10.899C111.789 11.46 111.468 11.9238 111.043 12.2905C110.621 12.6535 110.101 12.8735 109.481 12.9505C109.298 12.9762 109.105 12.9908 108.904 12.9945C108.706 12.9982 108.57 13 108.497 13H106.016ZM107.193 11.9055H108.497C108.621 11.9055 108.77 11.9018 108.942 11.8945C109.114 11.8872 109.267 11.8725 109.399 11.8505C109.802 11.7735 110.128 11.5993 110.378 11.328C110.631 11.053 110.816 10.7157 110.933 10.316C111.05 9.91633 111.109 9.491 111.109 9.04C111.109 8.57433 111.049 8.1435 110.928 7.7475C110.807 7.34783 110.62 7.01417 110.367 6.7465C110.117 6.47517 109.795 6.30283 109.399 6.2295C109.267 6.20383 109.113 6.18917 108.937 6.1855C108.764 6.17817 108.618 6.1745 108.497 6.1745H107.193V11.9055Z\",\n fill: \"#9444FB\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"g\", {\n clipPath: \"url(#clip0_22923_134949)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M126 6.45312V9.91692L128.324 12.4496C129.014 11.7949 129.406 10.8767 129.406 9.91692C129.406 8.01665 127.869 6.45312 126 6.45312Z\",\n fill: \"#9444FB\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M128.781 5.69002L129.106 5.1175C129.239 4.8829 129.16 4.58278 128.929 4.44728C128.699 4.31178 128.403 4.39209 128.27 4.62693L127.931 5.22481C127.6 5.08391 127.252 4.978 126.889 4.91202V4.42074H126.722C127.108 4.42074 127.42 4.10278 127.42 3.71037C127.42 3.31796 127.108 3 126.722 3H125.278C124.892 3 124.58 3.31796 124.58 3.71037C124.58 4.10278 124.892 4.42074 125.278 4.42074H125.111V4.91202C122.774 5.33847 121 7.41652 121 9.91585C121 12.7238 123.239 15 126 15C128.761 15 131 12.7238 131 9.91585C131 8.15436 130.119 6.60235 128.781 5.69002ZM125.18 3.71037C125.18 3.60329 125.265 3.51663 125.371 3.51663H125.936C126.042 3.51663 126.127 3.60329 126.127 3.71037C126.127 3.81746 126.042 3.90411 125.936 3.90411H125.371C125.265 3.90411 125.18 3.81746 125.18 3.71037ZM128.882 12.8466C128.112 13.6295 127.089 14.0607 126 14.0607C124.911 14.0607 123.888 13.6295 123.118 12.8466C122.348 12.0636 121.924 11.0229 121.924 9.91585C121.924 8.80885 122.348 7.76783 123.118 6.98513C123.888 6.20219 124.911 5.77104 126 5.77104C127.089 5.77104 128.112 6.20219 128.882 6.98513C129.652 7.76806 130.076 8.80885 130.076 9.91585C130.076 11.0229 129.652 12.0639 128.882 12.8466Z\",\n fill: \"#9444FB\"\n}));\n\nvar _ref5 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_22923_134949\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 10,\n height: 12,\n fill: \"white\",\n transform: \"translate(121 3)\"\n})));\n\nvar SvgOptOutAllowedBadge = function SvgOptOutAllowedBadge(_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: 139,\n height: 18,\n viewBox: \"0 0 139 18\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4, _ref5);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgOptOutAllowedBadge, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/optOutAllowedBadge.c52e878d.svg\";\nexport { ForwardRef as ReactComponent };","import React from 'react';\nimport { ReactComponent as OpuOutAllowedBadge } from '../../../assets/optOutAllowedBadge.svg';\nimport { RequestStatus, SessionStatus } from '../../../types/types';\n\nconst OptOutAllowedBadgeIcon = ({\n className,\n statusId,\n}: {\n className?: string;\n statusId: SessionStatus | RequestStatus;\n}) => {\n return [RequestStatus.PENDING, SessionStatus.Pending].includes(statusId) ? (\n \n ) : (\n <>\n );\n};\n\nexport default OptOutAllowedBadgeIcon;\n","module.exports = __webpack_public_path__ + \"static/media/info-circle.b152b4f4.svg\";","import { makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\nimport React, { ComponentType, Fragment } from 'react';\n\ntype StyleProps = {\n columnLength: number;\n rowsLength: number;\n hasHorizontalLabels: boolean;\n hasVerticalLabels: boolean;\n};\n\nconst labelsJss = {\n display: 'flex',\n '& > div': {\n flex: 1,\n },\n};\n\nconst useStyles = makeStyles((theme) => ({\n root: {\n display: 'grid',\n },\n horizontalLabels: ({ hasVerticalLabels }) => ({\n gridColumnStart: hasVerticalLabels ? 2 : 1,\n ...labelsJss,\n }),\n verticalLabels: ({ hasHorizontalLabels }) => ({\n gridRowStart: hasHorizontalLabels ? 2 : 1,\n ...labelsJss,\n flexDirection: 'column',\n }),\n insideRowsLabel: {\n gridColumn: '1/-1',\n width: '100%',\n },\n matrix: ({ hasHorizontalLabels, hasVerticalLabels, columnLength }) => ({\n gridRowStart: hasHorizontalLabels ? 2 : 1,\n gridColumnStart: hasVerticalLabels ? 2 : 1,\n display: 'grid',\n gridTemplateColumns: `repeat(${columnLength}, 1fr)`,\n placeItems: 'center',\n }),\n}));\n\nexport type LabelRenderFunc = ComponentType<{ value: Value }>;\ntype MatrixRenderFunc = (\n horizontalValue: X,\n verticalValue: Y\n) => React.ReactNode;\n\nexport type MatrixProps = {\n render: MatrixRenderFunc;\n\n horizontalValues: Array;\n verticalValues: Array;\n\n HorizontalLabel?: LabelRenderFunc;\n VerticalLabel?: LabelRenderFunc;\n InsideRowsLabel?: LabelRenderFunc;\n useVerticalLabelsInsideRows?: boolean;\n\n styles?: Partial<{\n root: string;\n horizontalLabels: string;\n verticalLabels: string;\n insideRowsLabel: string;\n matrix: string;\n }>;\n\n customElements?: React.ReactNode;\n};\n\nexport const Matrix = (props: MatrixProps) => {\n const {\n horizontalValues,\n verticalValues,\n render = () => null,\n HorizontalLabel,\n VerticalLabel,\n InsideRowsLabel,\n styles,\n useVerticalLabelsInsideRows = false,\n customElements,\n } = props;\n\n const classes = useStyles({\n columnLength: horizontalValues.length,\n rowsLength: verticalValues.length,\n hasHorizontalLabels: !!HorizontalLabel,\n hasVerticalLabels: !!(VerticalLabel && !useVerticalLabelsInsideRows),\n });\n const generateKey = (value: X | Y, index: number) => `${value}_${index}`;\n\n const InsideRowsLabelLocal = useVerticalLabelsInsideRows\n ? VerticalLabel\n : InsideRowsLabel;\n\n return (\n
\n {HorizontalLabel && (\n
\n {horizontalValues.map((hv, hvi) => (\n \n ))}\n
\n )}\n {VerticalLabel && !useVerticalLabelsInsideRows && (\n
\n {verticalValues.map((vv, vvi) => (\n \n ))}\n
\n )}\n
\n {verticalValues.map((vv) => (\n \n {horizontalValues.map((hv, hvi) => {\n return (\n \n {render(hv, vv)}\n \n );\n })}\n {InsideRowsLabelLocal && (\n \n \n
\n )}\n \n ))}\n
\n {customElements}\n
\n );\n};\n\nexport default Matrix;\n","import { makeStyles } from '@material-ui/core';\nimport { StyleClassNames } from '.';\n\nconst commonStyles = {\n [StyleClassNames.MAIN]: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n [StyleClassNames.DISABLED]: {},\n};\n\nexport const useHorizontalLabelStylesVariant1 = makeStyles((theme) => ({\n [StyleClassNames.MAIN]: {\n ...commonStyles[StyleClassNames.MAIN],\n fontSize: theme.spacing(2),\n fontWeight: 600,\n },\n [StyleClassNames.DISABLED]: {\n opacity: 0.5,\n },\n}));\n\nexport const useHorizontalLabelStylesVariant2 = makeStyles((theme) => ({\n [StyleClassNames.MAIN]: {\n ...commonStyles[StyleClassNames.MAIN],\n fontSize: theme.spacing(1.75),\n },\n}));\n\nexport const useHorizontalLabelStylesVariant3 = makeStyles((theme) => ({\n [StyleClassNames.MAIN]: {\n ...commonStyles[StyleClassNames.MAIN],\n gap: theme.spacing(0.25),\n\n [theme.breakpoints.down('xs')]: {\n flexDirection: 'column',\n },\n },\n [StyleClassNames.LABEL]: {\n opacity: 0.5,\n fontSize: theme.spacing(1.75),\n fontWeight: 600,\n },\n [StyleClassNames.DAY]: {\n fontSize: theme.spacing(1.75),\n fontWeight: 700,\n },\n}));\n","import { useEffect } from 'react';\n\nconst useMinutesTimer = (\n value: number,\n onChange: React.Dispatch>\n) => {\n useEffect(() => {\n const timer = setTimeout(() => {\n onChange((prevMinutes) => prevMinutes - 1);\n }, 60000); // 1 minute interval (60000 ms)\n\n if (value < 0) {\n return () => clearTimeout(timer);\n }\n return () => clearTimeout(timer);\n }, [value, onChange]);\n\n return value;\n};\n\nexport default useMinutesTimer;\n","export const getGeolocationPermission = async () => {\n return navigator.permissions\n .query({\n name: 'geolocation',\n })\n .then((res) => res.state)\n .catch((e) => console.error(e));\n};\n\nexport const getGeolocationCoords = () => {\n return new Promise((resolve, reject) => {\n navigator.geolocation.getCurrentPosition(\n (pos) => {\n resolve(pos.coords);\n },\n (err) => {\n reject(err.message);\n },\n {\n enableHighAccuracy: true,\n }\n );\n });\n};\n","import React from 'react';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\nimport { NoShowParticipant } from '../../../../types/types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n typography: {\n maxWidth: 330,\n textAlign: 'center',\n margin: theme.spacing(0, 2),\n },\n}));\n\nconst NotHereConfirmationDialogText = ({\n participant,\n}: {\n participant: NoShowParticipant;\n}) => {\n const classes = useStyles();\n\n return (\n \n {participant === NoShowParticipant.Provider &&\n `Please confirm that you are at the session location and that your \n provider has not yet arrived (it is okay to confirm even if the provider \n has told you that they will be late). We will remind your provider.`}\n {participant === NoShowParticipant.Client &&\n `Please confirm that you are at the session location and that your\n client has not yet arrived (it is okay to confirm even if the client\n has told you that they will be late). Your location will be recorded and we will remind your client.`}\n {participant === NoShowParticipant.DistrictClient &&\n `Please confirm that you are at the session location \n and that the client has not yet arrived (it is okay to confirm even if the client will be late). \n Your location will be recorded.`}\n \n );\n};\n\nexport default NotHereConfirmationDialogText;\n","import React from 'react';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\nimport { NoShowParticipant } from '../../../../types/types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n typography: {\n maxWidth: 330,\n textAlign: 'center',\n margin: theme.spacing(0, 2),\n },\n}));\nconst StillNotHereConfirmationDialogText = ({\n participant,\n}: {\n participant: NoShowParticipant;\n}) => {\n const classes = useStyles();\n\n const participantTypeLabel =\n participant === NoShowParticipant.Provider\n ? NoShowParticipant.Provider\n : NoShowParticipant.Client;\n\n return (\n \n {participant === NoShowParticipant.Provider &&\n `Tired of waiting? We can remove the session and it will not affect your cancel rate.\n The provider and supervisor will be notified.`}\n {participant === NoShowParticipant.Client &&\n `Tired of waiting? We can remove the session and it will not affect your cancel rate.\n The client and supervisor will be notified. `}\n {participant === NoShowParticipant.DistrictClient &&\n `Tired of waiting? We can remove the session and it will not affect your cancel rate. The supervisor will be notified. `}\n
\n {`Or you can continue to wait for your ${participantTypeLabel.toLowerCase()}.`}\n
\n );\n};\n\nexport default StillNotHereConfirmationDialogText;\n","import React from 'react';\nimport { makeStyles, Theme } from '@material-ui/core';\nimport { useAppSelector } from '../../../../redux/store';\n\nimport { NoShowParticipant } from '../../../../types/types';\n\nimport SimpleDialog from '../../../Dialogs/SimpleDialog';\nimport ActionsControlButton from '../../../buttons/ActionsControlButton';\nimport { scheduledSessionsLogActions } from '../../../../shared/constants';\nimport NotHereConfirmationDialogText from '../DialogMessages/NotHereConfirmationDialogText';\nimport StillNotHereConfirmationDialogText from '../DialogMessages/StillNotHereConfirmationDialogText';\n\nimport { ReactComponent as InfoIcon } from '../../../../assets/info-circle-blue-filled.svg';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n title: {\n background: 'transparent',\n },\n content: {\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(2.5),\n },\n icon: {\n margin: 'auto',\n display: 'block',\n width: 'max-content',\n },\n cancelButton: {\n border: `1px solid ${theme.palette.kyoRed.main}`,\n color: theme.palette.kyoRed.main,\n },\n}));\n\ninterface ConfirmationDialogProps {\n onCreateSessionLog: () => void;\n onClose: () => void;\n hideSuccessButton?: boolean;\n participant: NoShowParticipant;\n}\n\nconst ConfirmationDialog = (props: ConfirmationDialogProps) => {\n const {\n onCreateSessionLog,\n onClose,\n hideSuccessButton = false,\n participant,\n } = props;\n\n const classes = useStyles();\n\n const actionState = useAppSelector((state) => state.sessionLog.actionState);\n const includesNotHereActions =\n actionState &&\n scheduledSessionsLogActions.NotHereActions.includes(actionState);\n\n if (includesNotHereActions) {\n return (\n \n \n \n {\n onCreateSessionLog();\n onClose();\n },\n cancelButton: () => {\n onClose();\n },\n }}\n label={{\n successButton: 'Confirm - Send a reminder',\n cancelButton: 'Nevermind',\n }}\n />\n \n );\n }\n\n return (\n \n \n \n {\n onClose();\n }\n : undefined,\n cancelButton: () => {\n onCreateSessionLog();\n onClose();\n },\n }}\n label={{\n successButton: 'Wait a little longer',\n cancelButton: 'Remove Session',\n }}\n />\n \n );\n};\n\nexport default ConfirmationDialog;\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(\"g\", {\n clipPath: \"url(#clip0_18531_21787)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M30.3207 8.77738C30.1846 8.77738 30.0485 8.78314 29.9124 8.7889C28.6758 5.10195 25.1775 2.44043 21.0537 2.44043C16.9299 2.44043 13.4316 5.09907 12.195 8.7889C12.0589 8.78314 11.9228 8.77738 11.7867 8.77738C6.62901 8.77738 2.44727 12.9367 2.44727 18.0668C2.44727 23.1968 6.58847 27.3159 11.7143 27.3533C11.7143 27.3533 30.2976 27.3533 30.3207 27.3533C35.4784 27.3533 39.6602 23.194 39.6602 18.0639C39.6602 12.9338 35.4784 8.7745 30.3207 8.7745V8.77738Z\",\n stroke: \"#EDEDED\",\n strokeWidth: 3,\n strokeMiterlimit: 10\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M97.8735 35.337C97.7374 35.337 97.6013 35.3427 97.4651 35.3485C96.2286 31.6615 92.7303 29 88.6064 29C84.4826 29 80.9843 31.6586 79.7478 35.3485C79.6116 35.3427 79.4755 35.337 79.3394 35.337C74.1817 35.337 70 39.4963 70 44.6264C70 49.7564 74.1412 53.8754 79.267 53.9129C79.267 53.9129 97.8503 53.9129 97.8735 53.9129C103.031 53.9129 107.213 49.7535 107.213 44.6235C107.213 39.4934 103.031 35.3341 97.8735 35.3341V35.337Z\",\n stroke: \"#EDEDED\",\n strokeWidth: 3,\n strokeMiterlimit: 10\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M19.1729 113.193H9.85156\",\n stroke: \"#EDEDED\",\n strokeWidth: 3,\n strokeMiterlimit: 10,\n strokeLinecap: \"round\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M45.2631 113.193H27.2539\",\n stroke: \"#EDEDED\",\n strokeWidth: 3,\n strokeMiterlimit: 10,\n strokeLinecap: \"round\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M116 113H66\",\n stroke: \"#EDEDED\",\n strokeWidth: 3,\n strokeMiterlimit: 10,\n strokeLinecap: \"round\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M56.6193 109.2C59.4156 105.711 66.1541 97.0832 72.2008 87.6273C75.2234 82.9006 78.0925 77.9371 80.2109 73.2851C82.3113 68.6725 83.7508 64.2035 83.7508 60.5158C83.7508 44.2291 70.4801 31.041 54.1254 31.041C37.7707 31.041 24.5 44.2291 24.5 60.5158C24.5 64.2028 25.9396 68.6713 28.04 73.2835C30.1584 77.9351 33.0275 82.8985 36.05 87.6251C42.0968 97.081 48.8352 105.71 51.6313 109.2C51.6311 109.199 51.631 109.199 51.6308 109.199L52.802 108.262L56.6193 109.2Z\",\n fill: \"#EDEDED\",\n stroke: \"white\",\n strokeWidth: 3\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M54.125 32.541V108.898C54.6173 108.898 55.1096 108.688 55.4484 108.265C61.0145 101.317 82.2504 73.9415 82.2504 60.5187C82.2504 45.068 69.6589 32.5439 54.125 32.5439V32.541Z\",\n fill: \"#E6E6E6\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M66.1706 60.5154C66.1706 67.1247 60.7824 72.4918 54.1244 72.4918C47.4663 72.4918 42.0781 67.1247 42.0781 60.5154C42.0781 53.9061 47.4663 48.5391 54.1244 48.5391C60.7824 48.5391 66.1706 53.9061 66.1706 60.5154Z\",\n fill: \"white\",\n stroke: \"#E6E6E6\",\n strokeWidth: 2\n}), /*#__PURE__*/React.createElement(\"rect\", {\n x: 62.5,\n y: 69.5,\n width: 66,\n height: 38,\n rx: 19,\n fill: \"#2BDB38\",\n stroke: \"white\",\n strokeWidth: 3\n}), /*#__PURE__*/React.createElement(\"rect\", {\n x: 64,\n y: 71,\n width: 63,\n height: 35,\n rx: 17.5,\n fill: \"url(#paint0_linear_18531_21787)\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M122.5 88.5C122.5 95.6977 116.886 101.5 110 101.5C103.114 101.5 97.5 95.6977 97.5 88.5C97.5 81.3023 103.114 75.5 110 75.5C116.886 75.5 122.5 81.3023 122.5 88.5Z\",\n fill: \"white\",\n stroke: \"#03F114\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M107.336 96.7611L102.209 91.5487C102.065 91.4027 102 91.2169 102 90.9913C102 90.7657 102.065 90.5799 102.209 90.4339L103.197 89.4412C103.34 89.282 103.523 89.1891 103.732 89.1891C103.941 89.1891 104.137 89.2687 104.293 89.4412L107.884 93.1025L115.606 85.2521C115.763 85.0929 115.959 85 116.168 85C116.377 85 116.559 85.0796 116.703 85.2521L117.916 86.4513C118.145 86.9999 117.85 87.2014 117.706 87.3474L108.433 96.7479C108.29 96.9071 108.107 97 107.885 97C107.663 97 107.48 96.9204 107.336 96.7479V96.7611Z\",\n fill: \"#EAEAEA\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M107.336 94.7611L102.209 89.5487C102.065 89.4027 102 89.2169 102 88.9913C102 88.7657 102.065 88.5799 102.209 88.4339L103.197 87.4412C103.34 87.282 103.523 87.1891 103.732 87.1891C103.941 87.1891 104.137 87.2687 104.293 87.4412L107.884 91.1025L115.606 83.2521C115.763 83.0929 115.959 83 116.168 83C116.377 83 116.559 83.0796 116.703 83.2521L117.916 84.4513C118.145 84.9999 117.85 85.2014 117.706 85.3474L108.433 94.7479C108.29 94.9071 108.107 95 107.885 95C107.663 95 107.48 94.9204 107.336 94.7479V94.7611Z\",\n fill: \"#1FCC2C\"\n}), /*#__PURE__*/React.createElement(\"rect\", {\n x: 65,\n y: 72,\n width: 61,\n height: 33,\n rx: 16.5,\n stroke: \"#1FCC2C\",\n strokeWidth: 2\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"linearGradient\", {\n id: \"paint0_linear_18531_21787\",\n x1: 127,\n y1: 89,\n x2: 64,\n y2: 89,\n gradientUnits: \"userSpaceOnUse\"\n}, /*#__PURE__*/React.createElement(\"stop\", {\n stopColor: \"#00F212\"\n}), /*#__PURE__*/React.createElement(\"stop\", {\n offset: 1,\n stopColor: \"#2BDB38\"\n})), /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_18531_21787\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 130,\n height: 115,\n fill: \"white\"\n})));\n\nvar SvgLocationAccessIcon = function SvgLocationAccessIcon(_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: 130,\n height: 115,\n viewBox: \"0 0 130 115\",\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(SvgLocationAccessIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/location_access_icon.b425f4b7.svg\";\nexport { ForwardRef as ReactComponent };","import React, { FC } from 'react';\nimport {\n Theme,\n Typography,\n makeStyles,\n useMediaQuery,\n} from '@material-ui/core';\nimport { getGeolocationCoords } from '../utils/geolocation';\n\nimport SimpleDialog from './Dialogs/SimpleDialog';\nimport ActionsControlButton from './buttons/ActionsControlButton';\n\nimport { ReactComponent as LocationAccessIcon } from '../assets/location_access_icon.svg';\n\nfunction detectBrowser() {\n const { userAgent } = navigator;\n if (userAgent.includes('Edg')) return 'Edge';\n if (\n userAgent.includes('Chrome') &&\n !userAgent.includes('Edg') &&\n !userAgent.includes('OPR')\n )\n return 'Chrome';\n if (userAgent.includes('Safari') && !userAgent.includes('Chrome'))\n return 'Safari';\n if (userAgent.includes('Firefox')) return 'Firefox';\n return 'Other';\n}\n\nconst instructions = {\n Chrome: `\n Go to Settings > Privacy and security > Site settings > Location.\n Find this site and select \"Allow\".\n `,\n Firefox: `\n Go to Preferences > Privacy & Security > Permissions > Location.\n Click \"Settings...\" and allow this site.\n `,\n Safari: `\n On macOS, go to Safari > Settings > Websites > Location. Find\n this site in the list and set it to \"Allow\". On iOS, go to Settings > Privacy > Location Services, and make sure\n Safari has access.\n `,\n Edge: `\n Go to Settings > Cookies and site permissions > Location. Find this\n site and select \"Allow\".\n `,\n Other: 'Allow location access for this site from the browser settings.',\n};\n\nconst useStyles = makeStyles((theme: Theme) => ({\n title: {\n background: 'transparent',\n paddingBottom: 0,\n },\n content: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: theme.spacing(4),\n padding: theme.spacing(4, 5),\n },\n contentTitle: {\n textAlign: 'center',\n padding: theme.spacing(0, 8),\n [theme.breakpoints.down('xs')]: {\n padding: theme.spacing(0, 4),\n },\n },\n buttonWrapper: {\n width: '100%',\n [theme.breakpoints.up('sm')]: {\n display: 'flex',\n gap: theme.spacing(2),\n },\n },\n}));\n\ninterface LocationAccessWarningDialogProps {\n open: boolean;\n onClose: () => void;\n}\n\nconst LocationAccessWarningDialog: FC = (\n props\n) => {\n const { open, onClose } = props;\n const classes = useStyles();\n\n const isMobile = useMediaQuery((theme: Theme) =>\n theme.breakpoints.down('xs')\n );\n\n return (\n \n \n\n \n Kyo Care needs access to your location.\n \n \n This feature requires access to your location.\n

\n Kyo Providers are required to share their location to use certain\n features in Care.{' '}\n \n Care will only record your location when needed during scheduled\n sessions. You will be notified when your location is recorded.{' '}\n \n

\n If no prompt appears please follow these steps:
\n {instructions[detectBrowser()]}\n
\n {\n getGeolocationCoords();\n onClose();\n },\n cancelButton: () => onClose(),\n }}\n label={{\n successButton: 'Continue',\n cancelButton: 'Close',\n }}\n />\n \n );\n};\n\nexport default LocationAccessWarningDialog;\n","import React from 'react';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\nimport { NoShowParticipant } from '../../../../types/types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n infoText: {\n width: '84%',\n },\n}));\n\nconst RemovedSessionDialogText = ({\n participant,\n}: {\n participant: NoShowParticipant;\n}) => {\n const classes = useStyles();\n const participantTypeLabel =\n participant === NoShowParticipant.Provider\n ? NoShowParticipant.Provider\n : NoShowParticipant.Client;\n\n if (participant === NoShowParticipant.DistrictClient) {\n return (\n \n We are very sorry your client didn’t show up. The session has been\n removed from your schedule and will not affect your cancel rate. The\n supervisor has been notified.\n \n );\n }\n return (\n \n {`We are very sorry your ${participantTypeLabel.toLocaleLowerCase()} didn't show up. The session has been\n removed from your schedule and will not affect your cancel rate. The\n ${participantTypeLabel.toLocaleLowerCase()} and supervisor have been notified.`}\n \n );\n};\n\nexport default RemovedSessionDialogText;\n","import React from 'react';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: theme.spacing(1.5),\n marginTop: theme.spacing(2),\n },\n title: {\n fontSize: theme.spacing(2),\n marginBottom: theme.spacing(2),\n },\n typography: {\n maxWidth: 330,\n textAlign: 'center',\n margin: theme.spacing(0, 2),\n },\n}));\n\nconst ClassroomSupportNoticeDialogText = () => {\n const classes = useStyles();\n\n return (\n
\n \n Stay to provide classroom support!\n \n \n When a student is absent at this district, Kyo staff stays to support\n the school.\n \n \n Please connect with school personnel and support as directed.\n \n
\n );\n};\n\nexport default ClassroomSupportNoticeDialogText;\n","import React from 'react';\nimport { makeStyles, Theme } from '@material-ui/core';\nimport SimpleDialog from '../../../Dialogs/SimpleDialog';\n\nimport { ReactComponent as InfoIcon } from '../../../../assets/info-circle-blue-filled.svg';\nimport StyledButton from '../../../buttons/StyledButton';\nimport ClassroomSupportNoticeDialogText from '../DialogMessages/ClassroomSupportNoticeDialogText';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n title: {\n background: 'transparent',\n },\n content: {\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(2.5),\n paddingTop: 0,\n paddingBottom: theme.spacing(4),\n },\n icon: {\n margin: 'auto',\n display: 'block',\n width: 'max-content',\n },\n}));\n\nconst ClassroomSupportNoticeDialog = ({ onClose }: { onClose: () => void }) => {\n const classes = useStyles();\n\n return (\n \n \n \n \n OK, Got It\n \n \n );\n};\n\nexport default ClassroomSupportNoticeDialog;\n","import React from 'react';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\nimport { NoShowParticipant } from '../../../../types/types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n infoText: {\n width: '84%',\n },\n}));\n\nconst WaitConfirmationDialogText = (props: {\n participant: NoShowParticipant;\n waitUntil: string;\n providerName?: string;\n}) => {\n const { participant, waitUntil, providerName } = props;\n const classes = useStyles();\n\n if (participant === NoShowParticipant.Provider && providerName) {\n return (\n \n We’ve sent {providerName} a reminder. Please wait until{' '}\n {waitUntil}. If they don’t arrive or send a Team Chat, let\n us know.\n \n );\n }\n\n if (participant === NoShowParticipant.Client) {\n return (\n \n We’ve sent them a reminder. Please wait until {waitUntil}.\n If they don’t arrive or send a Team Chat, let us know.\n \n );\n }\n\n if (participant === NoShowParticipant.DistrictClient) {\n return (\n \n Please wait until {waitUntil}. You must wait the full time even\n if the client is absent.\n \n );\n }\n\n return null;\n};\n\nexport default WaitConfirmationDialogText;\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(\"g\", {\n clipPath: \"url(#clip0_29754_103945)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M10.1201 7.5791C6.62564 7.5791 3.75 10.4302 3.75 13.8949C3.75 17.3596 6.62564 20.2107 10.1201 20.2107C12.0022 20.2107 13.7902 19.3838 15 17.9546L10.1201 13.8949V7.5791Z\",\n fill: \"#616161\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M18.3456 6.90566L18.4993 7.06173C18.6121 7.17626 18.7954 7.17626 18.9082 7.06173L19.9153 6.03929C20.0281 5.92476 20.0281 5.7387 19.9153 5.62417L18.2783 3.96224C18.1655 3.84772 17.9822 3.84772 17.8694 3.96224L16.8623 4.98469C16.7495 5.09922 16.7495 5.28528 16.8623 5.39981L17.016 5.55589L16.4541 6.12636C15.0221 4.89112 13.2431 4.05835 11.2861 3.80075V2.61067H11.7722C12.0135 2.61067 12.2089 2.41232 12.2089 2.16737V0.4433C12.2089 0.198347 12.0135 0 11.7722 0H8.20712C7.96584 0 7.77046 0.198347 7.77046 0.4433V2.16737C7.77046 2.41232 7.96584 2.61067 8.20712 2.61067H8.69324V3.80075C6.75196 4.05618 4.98577 4.87775 3.55979 6.09637L3.0274 5.55589L3.18114 5.39981C3.29395 5.28528 3.29395 5.09922 3.18114 4.98469L2.17402 3.96224C2.06121 3.84772 1.87794 3.84772 1.76512 3.96224L0.12847 5.62453C0.0156584 5.73906 0.0156584 5.92512 0.12847 6.03965L1.13559 7.0621C1.2484 7.17662 1.43167 7.17662 1.54448 7.0621L1.69822 6.90602L2.24128 7.45735C0.840569 9.20273 0 11.4304 0 13.8579C0 19.459 4.4726 23.9996 9.98968 23.9996C15.5068 23.9996 19.9794 19.459 19.9794 13.8579C19.9794 11.447 19.1502 9.23344 17.7666 7.49311L18.3452 6.90566H18.3456ZM9.98968 22.0642C5.52527 22.0642 1.90641 18.3899 1.90641 13.8579C1.90641 9.32593 5.52562 5.65163 9.98968 5.65163C14.4537 5.65163 18.073 9.32593 18.073 13.8579C18.073 18.3899 14.4537 22.0642 9.98968 22.0642Z\",\n fill: \"#616161\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_29754_103945\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 20,\n height: 24,\n fill: \"white\"\n})));\n\nvar SvgStopwatch = function SvgStopwatch(_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: 20,\n height: 24,\n viewBox: \"0 0 20 24\",\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(SvgStopwatch, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/stopwatch.9d18d283.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(\"g\", {\n clipPath: \"url(#clip0_29197_297564)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M9.81854 11C11.3898 10.9633 12.7178 10.45 13.8027 9.405C14.8502 8.34167 15.3926 7.04 15.4301 5.5C15.3926 3.96 14.8689 2.65833 13.8027 1.595C12.7178 0.568333 11.3898 0.0366667 9.81854 0C8.24732 0.0366667 6.91926 0.55 5.83437 1.595C4.78689 2.65833 4.24444 3.96 4.20703 5.5C4.24444 7.04 4.76818 8.34167 5.83437 9.405C6.91926 10.4317 8.24732 10.9633 9.81854 11ZM7.31207 3.04333C7.98545 2.42 8.80847 2.09 9.81854 2.05333C10.8099 2.09 11.6516 2.42 12.325 3.04333C12.961 3.70333 13.2977 4.51 13.3351 5.5C13.2977 6.47167 12.961 7.29667 12.325 7.95667C11.6516 8.58 10.8286 8.91 9.81854 8.94667C8.82718 8.91 7.98545 8.58 7.31207 7.95667C6.6761 7.29667 6.33941 6.49 6.302 5.5C6.33941 4.52833 6.6761 3.70333 7.31207 3.04333Z\",\n fill: \"white\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M9.35169 19.9466H2.15025C2.35601 18.5716 2.97327 17.4166 3.98335 16.4999C5.01212 15.6199 6.24666 15.1616 7.70565 15.1249H11.9143C11.9143 15.1249 12.0826 15.1432 12.1574 15.1432L13.2985 13.1999C12.8495 13.1266 12.4006 13.0532 11.9143 13.0532H7.70565C5.51716 13.1082 3.70277 13.8599 2.26248 15.2899C0.80349 16.7016 0.0365839 18.4616 -0.0195312 20.6249C-0.0195312 21.0282 0.111404 21.3582 0.373275 21.6149C0.635145 21.8716 0.971836 21.9999 1.38335 21.9999H8.11716L9.33299 19.9466H9.35169Z\",\n fill: \"white\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M25.8314 20.2583C26.0558 20.6617 26.0558 21.0467 25.8314 21.4133C25.6256 21.78 25.2702 21.9817 24.7839 22H12.794C12.3076 22 11.9522 21.78 11.7465 21.4133C11.522 21.0467 11.522 20.6617 11.7465 20.2583L17.7508 10.2117C18.0127 9.82667 18.3681 9.625 18.7983 9.625C19.2285 9.625 19.5839 9.82667 19.8457 10.2117L25.8501 20.2583H25.8314ZM18.7983 20.24C19.0414 20.24 19.2472 20.1483 19.4155 19.9833C19.5839 19.8183 19.6774 19.6167 19.6774 19.3783C19.6774 19.1217 19.5839 18.9017 19.4155 18.7367C19.2472 18.5717 19.0414 18.48 18.7983 18.48C18.5551 18.48 18.3493 18.5717 18.181 18.7367C18.0127 18.9017 17.9191 19.1217 17.9191 19.3783C17.9191 19.6167 18.0127 19.8183 18.181 19.9833C18.3493 20.1483 18.5551 20.24 18.7983 20.24ZM18.1249 13.3833V16.9217C18.1249 17.105 18.1997 17.27 18.3493 17.3983C18.4803 17.5267 18.6486 17.6 18.8357 17.6C19.2285 17.5633 19.4529 17.3433 19.4904 16.94V13.4017C19.4529 12.9983 19.2285 12.7783 18.817 12.7417C18.4055 12.7783 18.181 12.9983 18.1436 13.4017L18.1249 13.3833Z\",\n fill: \"white\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_29197_297564\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 26,\n height: 22,\n fill: \"white\"\n})));\n\nvar SvgParticipantAbsent = function SvgParticipantAbsent(_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: 26,\n height: 22,\n viewBox: \"0 0 26 22\",\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(SvgParticipantAbsent, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/participant_absent.7aab2ff9.svg\";\nexport { ForwardRef as ReactComponent };","import React, { FC, useState } from 'react';\nimport {\n Divider,\n LinearProgress,\n makeStyles,\n Theme,\n Typography,\n useTheme,\n} from '@material-ui/core';\nimport pRetry from 'p-retry';\nimport moment from 'moment';\nimport { useAppDispatch, useAppSelector } from '../../redux/store';\nimport { fetchClientFullSchedule } from '../../redux/modules/client';\nimport { fetchProviderFullSchedule } from '../../redux/modules/provider';\nimport {\n createSessionLog,\n setSessionLogAction,\n} from '../../redux/modules/sessionLog';\nimport {\n DATE_FORMAT,\n isNoShowParticipantRequester,\n TIME_FORMAT_2,\n} from '../../utils/helpers';\nimport { CreateSessionLog } from '../../api/scheduleApi';\nimport useMinutesTimer from '../../hooks/useMinutesTimer';\nimport useNoShowTimeLine from '../../hooks/useNoShowTimeLIne';\nimport {\n GeolocationPromptAction,\n NoShowParticipant,\n ScheduledSessionsLogActionIds,\n ScheduledSession,\n SessionStatus,\n} from '../../types/types';\nimport {\n getGeolocationCoords,\n getGeolocationPermission,\n} from '../../utils/geolocation';\nimport { scheduledSessionsLogActions } from '../../shared/constants';\nimport useNoShowedButtonsVisibility from '../../hooks/useNoShowButtonsVisibility';\nimport StyledButton from '../buttons/StyledButton';\nimport ConfirmationDialog from './components/Dialogs/ConfirmationDialog';\nimport LocationAccessWarningDialog from '../LocationAccessWarningDialog';\nimport RemovedSessionDialogText from './components/DialogMessages/RemovedSessionDialogText';\nimport ClassroomSupportNoticeDialog from './components/Dialogs/ClassroomSupportNoticeDialog ';\nimport WaitConfirmationDialogText from './components/DialogMessages/WaitConfirmationDialogText';\n\nimport { ReactComponent as Stopwatch } from '../../assets/stopwatch.svg';\nimport { ReactComponent as Icon } from '../../assets/participant_absent.svg';\nimport { ReactComponent as InfoIcon } from '../../assets/info-circle-blue-filled.svg';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n gap: theme.spacing(1.5),\n },\n stillAbsentLabel: {\n display: 'flex',\n alignItems: 'center',\n gap: theme.spacing(0.75),\n },\n stopwatchTitle: {\n display: 'flex',\n flexDirection: 'column',\n fontSize: 12,\n fontWeight: 600,\n color: theme.palette.kyoBlue1.contrastText,\n },\n stopwatchTime: {\n fontSize: 16,\n lineHeight: 0.8,\n paddingBottom: theme.spacing(0.5),\n },\n buttonHr: {\n width: 2,\n height: 34,\n margin: theme.spacing(0, 2),\n background: '#FFCECC',\n },\n hr: {\n marginBottom: theme.spacing(1.5),\n },\n infoTextWrapper: {\n maxWidth: '320px',\n display: 'flex',\n gap: theme.spacing(2),\n marginBottom: theme.spacing(1.5),\n },\n infoText: {\n width: '84%',\n },\n notHereButton: {\n padding: theme.spacing(1, 2),\n },\n stillNotHere: {\n padding: theme.spacing(0.5, 2),\n },\n arrivedButton: {\n padding: theme.spacing(0.5, 2),\n border: `1px solid ${theme.palette.kyoDollarBill.main}`,\n },\n disabledArrivedButton: {\n padding: theme.spacing(0.5, 2),\n border: `1px solid ${theme.palette.kyoDollarBill.main}`,\n opacity: 0.6,\n cursor: 'no-drop',\n },\n stopWatchButton: {\n border: `1px solid ${theme.palette.kyoRed3.light}`,\n padding: theme.spacing(0.25, 2),\n cursor: 'no-drop',\n },\n}));\n\ninterface NoShowedTriggerProps {\n participant: NoShowParticipant;\n session: ScheduledSession;\n actions: Record<\n 'NotHere' | 'StillNotHere' | 'Arrived',\n ScheduledSessionsLogActionIds\n >;\n setShowDetails?: (segmentId: number) => void;\n}\n\nconst NoShowedTrigger: FC = (props) => {\n const { participant, session, actions, setShowDetails } = props;\n\n const theme = useTheme();\n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const { logLoading, logError, actionState } = useAppSelector(\n (state) => state.sessionLog\n );\n const clientFullScheduleLoading = useAppSelector(\n (state) => state.client.clientFullScheduleLoading\n );\n const providerFullScheduleLoading = useAppSelector(\n (state) => state.provider.providerFullScheduleLoading\n );\n const fullScheduleLoading =\n clientFullScheduleLoading || providerFullScheduleLoading;\n const {\n canShowIsNotHereButton,\n canShowStopWatchButton,\n canShowStillIsNotHereButton,\n canShowArrivedButton,\n canShowDisabledArrivedButton,\n hideWaitLongerButton,\n } = useNoShowedButtonsVisibility(session, participant);\n\n const { waitUntil, noShowedEnd, waitInMinutes } = useNoShowTimeLine(\n session,\n participant\n );\n\n const [waitInterval, setWaitInterval] = useState(waitInMinutes || 0);\n const [\n openClassroomSupportNoticeDialog,\n setOpenClassroomSupportNoticeDialog,\n ] = useState(false);\n\n useMinutesTimer(waitInterval, setWaitInterval);\n\n const { clientId, providerId, sessionLogs = [] } = session;\n\n const {\n shouldReturnForClient,\n shouldReturnForProvider,\n } = isNoShowParticipantRequester(participant, sessionLogs);\n\n const [geolocationLoading, setGeolocationLoading] = useState(false);\n\n if (!providerId || shouldReturnForClient || shouldReturnForProvider) {\n return null;\n }\n\n const actionParams: Omit = {\n segmentId: Math.abs(session.segmentId),\n clientId,\n providerId,\n };\n\n const participantTypeLabel =\n participant === NoShowParticipant.Provider\n ? NoShowParticipant.Provider\n : NoShowParticipant.Client;\n\n const showNotHereConfirmationDialog =\n actionState &&\n scheduledSessionsLogActions.NotHereActions.includes(actionState);\n\n const showStillNotHereConfirmationDialog =\n actionState &&\n scheduledSessionsLogActions.StillNotHereActions.includes(actionState);\n\n const fetchGeolocationCoords = async () => {\n let geolocationCoordsResult;\n setGeolocationLoading(true);\n\n try {\n geolocationCoordsResult = await getGeolocationCoords();\n } catch (err) {\n console.log(err);\n }\n setGeolocationLoading(false);\n return geolocationCoordsResult;\n };\n\n const handleActionLogCreation = async (\n actionId: ScheduledSessionsLogActionIds\n ) => {\n let geolocationCoords;\n const shouldFetchGeolocation = participant !== NoShowParticipant.Provider;\n if (shouldFetchGeolocation) {\n geolocationCoords = await fetchGeolocationCoords();\n }\n\n dispatch(\n createSessionLog({\n ...actionParams,\n latitude: shouldFetchGeolocation\n ? geolocationCoords?.latitude\n : undefined,\n longitude: shouldFetchGeolocation\n ? geolocationCoords?.longitude\n : undefined,\n actionId,\n })\n ).finally(() => {\n if (participant === NoShowParticipant.Provider) {\n dispatch(\n fetchClientFullSchedule({\n clientId,\n startDate: moment().format(DATE_FORMAT),\n endDate: moment().add(8, 'weeks').format(DATE_FORMAT),\n })\n );\n } else {\n dispatch(\n fetchProviderFullSchedule({\n providerId,\n startDate: moment().toISOString(),\n endDate: moment().add(8, 'weeks').toISOString(),\n })\n );\n }\n });\n };\n\n const handleSetShowDetails = () => {\n if (setShowDetails) {\n setShowDetails(session.segmentId);\n }\n };\n\n const handleNoShowedButtonClick = (\n actionId: ScheduledSessionsLogActionIds\n ) => {\n if (participant === NoShowParticipant.Provider) {\n return dispatch(setSessionLogAction(actionId));\n }\n\n if (\n participant === NoShowParticipant.DistrictClient &&\n session.client.attributes.reassignAllowed\n ) {\n return setOpenClassroomSupportNoticeDialog(true);\n }\n\n const executeGeolocationAndDispatchAction = async () => {\n return getGeolocationPermission().then((permission) => {\n if (permission === 'granted') {\n dispatch(setSessionLogAction(actionId));\n } else {\n dispatch(setSessionLogAction(GeolocationPromptAction.ShowWarning));\n }\n });\n };\n return pRetry(executeGeolocationAndDispatchAction, { retries: 1 });\n };\n\n const handleArrivedButtonClick = (\n actionId: ScheduledSessionsLogActionIds\n ) => {\n if (participant === NoShowParticipant.Provider) {\n return handleActionLogCreation(actionId);\n }\n\n const executeGeolocationAndDispatchAction = async () => {\n return getGeolocationPermission().then((permission) => {\n if (permission === 'granted') {\n handleActionLogCreation(actionId);\n } else {\n dispatch(setSessionLogAction(GeolocationPromptAction.ShowWarning));\n }\n });\n };\n return pRetry(executeGeolocationAndDispatchAction, { retries: 1 });\n };\n\n if ((logLoading && !logError) || fullScheduleLoading || geolocationLoading) {\n return ;\n }\n\n if (\n session?.sessionLogs?.some((l) =>\n scheduledSessionsLogActions.StillNotHereActions.includes(l.actionId)\n ) &&\n session.status === SessionStatus.Cancelled\n ) {\n return (\n <>\n \n
\n \n \n
\n \n );\n }\n\n if (canShowDisabledArrivedButton) {\n return (\n <>\n \n
\n \n \n Thanks for letting us know!\n \n
\n \n \n {`My ${participantTypeLabel} arrived!`}\n \n \n );\n }\n\n const locationAccessWarningDialog = (\n {\n dispatch(setSessionLogAction(null));\n }}\n />\n );\n\n if (canShowIsNotHereButton) {\n return (\n <>\n {\n handleNoShowedButtonClick(actions.NotHere);\n }}\n >\n \n {`My ${participantTypeLabel} Isn't Here`}\n \n {openClassroomSupportNoticeDialog && (\n setOpenClassroomSupportNoticeDialog(false)}\n />\n )}\n {showNotHereConfirmationDialog && (\n {\n handleActionLogCreation(actionState);\n handleSetShowDetails();\n }}\n onClose={() => {\n dispatch(setSessionLogAction(null));\n }}\n participant={participant}\n />\n )}\n {locationAccessWarningDialog}\n \n );\n }\n\n return (\n
\n {canShowStopWatchButton && waitUntil && (\n <>\n \n
\n \n \n
\n \n
\n \n {!!waitInMinutes && (\n \n Wait{' '}\n \n {`${waitInMinutes}min`}\n \n \n )}\n
\n \n {`My ${participantTypeLabel} Still Isn't Here`}\n \n \n )}\n {canShowStillIsNotHereButton && noShowedEnd && (\n <>\n \n
\n \n \n You can let us know they still haven’t arrived and remove\n the session, or you can continue to wait. Please make a selection\n by {noShowedEnd.format(TIME_FORMAT_2)}\n \n
\n {\n handleNoShowedButtonClick(actions.StillNotHere);\n }}\n >\n \n {`My ${participantTypeLabel} Still Isn't Here`}\n \n {showStillNotHereConfirmationDialog && (\n {\n handleActionLogCreation(actionState);\n handleSetShowDetails();\n }}\n onClose={() => {\n dispatch(setSessionLogAction(null));\n }}\n hideSuccessButton={hideWaitLongerButton}\n participant={participant}\n />\n )}\n \n )}\n {canShowArrivedButton && (\n {\n handleArrivedButtonClick(actions.Arrived);\n }}\n >\n \n {`My ${participantTypeLabel} arrived!`}\n \n )}\n {locationAccessWarningDialog}\n
\n );\n};\n\nexport default NoShowedTrigger;\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 d: \"M15.4988 3.06785L13.2557 1.14687C12.8126 0.716953 12.199 0.450684 11.5211 0.450684C10.366 0.450684 9.39833 1.22341 9.14136 2.2624C8.98075 2.09752 8.75285 1.99441 8.49996 1.99441C8.24707 1.99441 8.00157 2.10564 7.84045 2.28159C7.59088 1.233 6.61832 0.450684 5.45635 0.450684C4.78486 0.450684 4.17685 0.711785 3.73455 1.13457L1.16231 3.31665C1.16231 3.31665 1.16001 3.31861 1.15899 3.3196L1.15491 3.32304C0.449779 3.91563 0.00390625 4.78876 0.00390625 5.76229C0.00390625 7.54841 1.50366 8.99615 3.35394 8.99615C4.9034 8.99615 5.65341 8.12869 6.38353 7.14359C6.73661 6.66716 7.60872 5.99558 8.49996 5.99558C9.39119 5.99558 10.2501 6.6364 10.5983 7.10594C11.3381 8.10309 12.0397 8.99615 13.6462 8.99615C15.4963 8.99615 16.9963 7.54841 16.9963 5.76229C16.9963 4.63766 16.4013 3.64715 15.4988 3.06785ZM3.35394 8.20202C1.9582 8.20202 0.82682 7.10988 0.82682 5.76253C0.82682 4.41519 1.9582 3.32304 3.35394 3.32304C4.74968 3.32304 5.88106 4.41519 5.88106 5.76253C5.88106 7.10988 4.74968 8.20202 3.35394 8.20202ZM8.50021 5.4436C8.0138 5.4436 7.61968 5.06315 7.61968 4.59361C7.61968 4.12407 8.0138 3.74361 8.50021 3.74361C8.98662 3.74361 9.38074 4.12407 9.38074 4.59361C9.38074 5.06315 8.98662 5.4436 8.50021 5.4436ZM13.6465 8.20202C12.2507 8.20202 11.1194 7.10988 11.1194 5.76253C11.1194 4.41519 12.2507 3.32304 13.6465 3.32304C15.0422 3.32304 16.1736 4.41519 16.1736 5.76253C16.1736 7.10988 15.0422 8.20202 13.6465 8.20202Z\",\n fill: \"#3384EE\"\n});\n\nvar SvgObservation = function SvgObservation(_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: 17,\n height: 9,\n viewBox: \"0 0 17 9\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgObservation, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/observation.38305bc7.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: \"M15.0419 3.15986L8.50354 5.16819C8.02688 5.31486 7.61854 5.23319 7.40687 5.16819L2.82354 3.75986C2.53687 3.95652 2.35687 4.26819 2.33854 4.61986C2.55354 4.75152 2.70521 4.97819 2.70521 5.24986C2.70521 5.50319 2.57187 5.71486 2.38021 5.85152L2.97854 8.54319C3.03021 8.77819 2.85187 8.99986 2.61187 8.99986H1.29687C1.05687 8.99986 0.878542 8.77819 0.930208 8.54319L1.52854 5.85152C1.33687 5.71486 1.20354 5.50319 1.20354 5.24986C1.20354 4.97152 1.36187 4.73819 1.58854 4.60819C1.60354 4.19486 1.75687 3.81819 2.00687 3.50819L0.866875 3.15819C0.315208 2.98819 0.315208 2.25986 0.866875 2.08986L7.40687 0.0815234C7.76354 -0.0284766 8.14687 -0.0284766 8.50354 0.0815234L15.0419 2.08986C15.5935 2.25986 15.5935 2.98819 15.0419 3.15819V3.15986ZM12.1235 4.84152L12.4552 7.50152C12.4552 8.32986 10.4402 9.00152 7.95521 9.00152C5.47021 9.00152 3.45521 8.32986 3.45521 7.50152L3.78687 4.84152L7.18521 5.88486C7.48354 5.97652 8.05354 6.08986 8.72187 5.88486L12.1202 4.83986L12.1235 4.84152Z\",\n fill: \"#18BECF\"\n});\n\nvar SvgTraining = function SvgTraining(_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: 16,\n height: 9,\n viewBox: \"0 0 16 9\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgTraining, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/training.f994d527.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(\"g\", {\n clipPath: \"url(#clip0_9360_45453)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M15.9993 10.4203C15.9993 11.0622 15.5163 11.5832 14.9194 11.5832H10.9493C10.9513 11.5332 10.9629 11.4811 10.9629 11.4269V10.4954C10.9629 9.55961 10.619 8.71349 10.0703 8.07576C10.4412 7.84443 10.8643 7.70272 11.3222 7.70272H11.4072C11.7202 7.81942 12.0505 7.89653 12.4002 7.89653C12.7499 7.89653 13.0821 7.81942 13.3932 7.70272H13.4782C14.8692 7.70272 15.9955 8.91772 15.9955 10.4182L15.9993 10.4203ZM10.2442 5.01637C10.2442 3.73051 11.2101 2.68848 12.4021 2.68848C13.5941 2.68848 14.56 3.73051 14.56 5.01637C14.56 6.30223 13.5941 7.34426 12.4021 7.34426C11.2101 7.34426 10.2442 6.30223 10.2442 5.01637Z\",\n fill: \"#4D08A4\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M10.071 10.6037V10.8371C10.071 11.479 9.58802 12 8.99107 12H1.07993C0.484907 12 0 11.479 0 10.8371V10.6037C0 8.85307 1.28278 7.43383 2.89012 7.35881L5.03453 9.67211L7.17894 7.35881C8.78628 7.43383 10.0691 8.85307 10.0691 10.6037H10.071ZM0.30524 1.16916L4.5902 0.0562695C4.88191 -0.0187565 5.19102 -0.0187565 5.48273 0.0562695L9.76383 1.17124C10.1734 1.27753 10.1734 1.82772 9.76383 1.93609L7.59817 2.49878C7.79329 2.9156 7.91306 3.38242 7.91306 3.88051C7.91306 5.59569 6.62449 6.98367 5.03647 6.98367C3.44844 6.98367 2.15986 5.59361 2.15986 3.88051C2.15986 3.38034 2.28157 2.9156 2.47476 2.49878L0.991065 2.11323V3.38868C1.14755 3.4908 1.26153 3.66794 1.26153 3.88051C1.26153 4.09309 1.15721 4.25356 1.01232 4.35776L1.36392 5.8687C1.40256 6.03543 1.31756 6.20841 1.19391 6.20841H0.249215C0.125574 6.20841 0.0405699 6.03543 0.0792079 5.8687L0.430814 4.35776C0.283989 4.25356 0.181599 4.08475 0.181599 3.88051C0.181599 3.67628 0.293649 3.4908 0.452065 3.38868V1.97152L0.307172 1.93609C-0.100459 1.8298 -0.100459 1.27544 0.307172 1.16916H0.30524Z\",\n fill: \"#4D08A4\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_9360_45453\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 16,\n height: 12,\n fill: \"white\"\n})));\n\nvar SvgMentorship = function SvgMentorship(_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: 16,\n height: 12,\n viewBox: \"0 0 16 12\",\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(SvgMentorship, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/mentorship.99fbb3d3.svg\";\nexport { ForwardRef as ReactComponent };","import React from 'react';\nimport { useTheme } from '@material-ui/core';\n\nimport { ReactComponent as Observation } from '../../assets/observation.svg';\nimport { ReactComponent as Training } from '../../assets/training.svg';\nimport { ReactComponent as Mentorship } from '../../assets/mentorship.svg';\nimport Badge from '../../components/badges/Badge';\n\ntype Props = {\n billingCode?: string;\n};\n\nconst SessionBadge = ({ billingCode }: Props) => {\n let text: string;\n let Icon: JSX.Element;\n let textColor: string;\n\n const theme = useTheme();\n\n switch (billingCode) {\n case '026':\n text = 'Observation';\n Icon = ;\n textColor = theme.palette.kyoBlue.main;\n break;\n case '020':\n case '120':\n case '021':\n text = 'Training';\n Icon = ;\n textColor = theme.palette.kyoTeal.main;\n break;\n case 'M101':\n case 'M102':\n text = 'Mentorship';\n Icon = ;\n textColor = theme.palette.kyoPurple.main;\n break;\n default: {\n return null;\n }\n }\n\n return ;\n};\n\nexport default SessionBadge;\n","import React from 'react';\nimport moment from 'moment';\nimport {\n Avatar,\n makeStyles,\n Paper,\n Theme,\n Typography,\n} from '@material-ui/core';\n\nimport { uniqBy } from 'lodash';\nimport CovidBadgeIcon from '../badges/CovidBadge/CovidBadgeIcon';\nimport CalendarEvent from '../CalenderEvent/CalendarEvent';\nimport { Provider, ScheduledSession, SessionStatus } from '../../types/types';\nimport ProviderBCBABadge from '../badges/BCBABadge/ProviderBCBABadge';\nimport ProviderCell from '../table/ProviderCell';\nimport { useAppSelector } from '../../redux/store';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n providerInfo: {\n background: 'rgba(230, 230, 230, 0.5)',\n borderRadius: 8,\n display: 'flex',\n padding: theme.spacing(1, 0, 1, 0),\n '& > div': {\n margin: theme.spacing(1),\n },\n marginBottom: theme.spacing(1),\n },\n sessionExpandedDetailsLinks: {\n display: 'flex',\n },\n link: {\n color: theme.palette.kyoBlue.main,\n marginTop: theme.spacing(1),\n marginRight: theme.spacing(2),\n },\n badgeContainer: {\n '& > *:not(:last-child)': {\n marginRight: theme.spacing(1),\n },\n },\n overlapProviderInfo: {\n paddingBottom: theme.spacing(1.5),\n background: 'rgba(230, 230, 230, 0.5)',\n borderRadius: 8,\n marginBottom: theme.spacing(1),\n },\n providerCell: {\n paddingTop: theme.spacing(1),\n paddingLeft: theme.spacing(1),\n },\n}));\n\nexport type ClientSessionDetailProvider = Pick<\n Provider,\n | 'id'\n | 'firstName'\n | 'lastName'\n | 'profilePhoto'\n | 'covidVaccinatedDate'\n | 'title'\n>;\ninterface ClientSessionDetailsProps {\n session: ScheduledSession;\n provider?: ClientSessionDetailProvider;\n hideButtons?: boolean;\n hideProviders?: boolean;\n styles?: Partial>;\n}\n\nconst ClientSessionDetails = (props: ClientSessionDetailsProps) => {\n const { session, provider, hideButtons, hideProviders, styles } = props;\n const { segmentStartUtc, segmentEndUtc } = session;\n const classes = useStyles();\n\n const segmentStart = moment(segmentStartUtc);\n const segmentEnd = moment(segmentEndUtc);\n\n const currentClientName =\n useAppSelector((state) => state.client.currentClient?.clientName) || '';\n\n const providers: ClientSessionDetailProvider[] = [];\n const sessionsStatus: { [key: number]: SessionStatus } = {};\n if (provider && session.overlappingSessions?.length) {\n providers[0] = provider;\n if (session.status) {\n sessionsStatus[provider.id] = session.status;\n }\n session.overlappingSessions.forEach((os) => {\n if (os.provider) {\n providers.push(os.provider);\n sessionsStatus[os.provider.id] = os.status;\n }\n });\n }\n\n const uniqueProviders = uniqBy(providers, (p) => p.id);\n\n return (\n
\n {currentClientName && (\n \n Session for {currentClientName}{' '}\n {!hideProviders && provider ? 'with:' : ''}\n \n )}\n {!hideProviders && uniqueProviders.length === 0 && provider && (\n \n \n
\n {`${provider.firstName} ${provider.lastName}`}\n
\n {provider.covidVaccinatedDate && }\n \n
\n
\n
\n )}\n {!hideProviders && uniqueProviders.length > 0 && (\n \n {uniqueProviders.map((p) => (\n
\n \n
\n ))}\n
\n )}\n {!hideButtons && (\n <>\n
\n \n Add to iCal\n \n \n Add to Google\n \n
\n \n )}\n
\n );\n};\n\nexport default ClientSessionDetails;\n","import React from 'react';\nimport { makeStyles, Typography } from '@material-ui/core';\nimport moment from 'moment';\nimport clsx from 'clsx';\n\nimport { TimeBlock } from '../../../../redux/modules/adminSettings';\nimport { TIME_FORMAT_12HR, TIME_FORMAT_24HR } from '../../../../utils/helpers';\n\nconst useStyles = makeStyles((theme) => ({\n labelContainer: {\n minWidth: 96,\n margin: theme.spacing(1.5),\n [theme.breakpoints.down('xs')]: {\n margin: theme.spacing(1.5, 0.5),\n minWidth: 64,\n },\n },\n timeText: {\n color: theme.palette.kyoGray63.main,\n },\n labelName: {\n fontSize: 16,\n fontWeight: 700,\n },\n}));\n\ninterface VerticalLabelTimeBlockProps {\n value: number;\n timeBlock?: TimeBlock;\n styles?: Partial>;\n periodNameLength?: number;\n}\n\nconst VerticalLabelTimeBlock = (props: VerticalLabelTimeBlockProps) => {\n const { timeBlock, value, styles, periodNameLength = 1 } = props;\n const classes = useStyles();\n\n return (\n
\n \n Block {value}\n \n {!!timeBlock && (\n \n \n \n \n )}\n
\n );\n};\n\ninterface TimeTextProps {\n time: string;\n suffix?: string;\n periodNameLength?: number;\n}\n\nconst TimeText = (props: TimeTextProps) => {\n const { time, suffix, periodNameLength = 1 } = props;\n const momentDate = moment(time, TIME_FORMAT_24HR);\n\n return (\n <>\n {momentDate.format(TIME_FORMAT_12HR)}\n \n \n {momentDate.format('a').substring(0, periodNameLength).toUpperCase()}\n \n \n {suffix}\n \n );\n};\n\nexport default VerticalLabelTimeBlock;\n","import React from 'react';\nimport { Avatar, Box, makeStyles, Theme } from '@material-ui/core';\nimport { uniqBy } from 'lodash';\nimport clsx from 'clsx';\nimport { ScheduledSession, Provider } from '../../types/types';\nimport OverlappingProvidersCell from '../table/OverlappingProvidersCell';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n profilePicture: {\n marginRight: theme.spacing(1.7),\n marginBottom: theme.spacing(0.5),\n },\n small: {\n transform: 'scale(0.8)',\n },\n large: {\n transform: 'scale(1.2)',\n },\n left: {\n marginRight: 'auto',\n },\n right: {\n marginLeft: 'auto',\n },\n}));\n\ninterface SessionProviderProfilePictureProps {\n provider: Provider;\n overlappingSessions: ScheduledSession[] | undefined;\n size?: 'small' | 'large';\n offset?: 'left' | 'right';\n}\n\nconst SessionProviderProfilePicture = ({\n provider,\n overlappingSessions,\n size,\n offset,\n}: SessionProviderProfilePictureProps) => {\n const classes = useStyles();\n const providers = [];\n\n if (overlappingSessions && overlappingSessions?.length > 0) {\n providers[0] = provider;\n overlappingSessions.forEach((os) => {\n if (os.provider) {\n providers.push(os.provider);\n }\n });\n }\n\n const uniqProviders = uniqBy(providers, (p) => p.id);\n\n return (\n \n {uniqProviders.length > 0 ? (\n \n ) : (\n \n )}\n \n );\n};\n\nexport default SessionProviderProfilePicture;\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(\"g\", {\n clipPath: \"url(#clip0_28973_264514)\"\n}, /*#__PURE__*/React.createElement(\"path\", {\n d: \"M9.81854 11C11.3898 10.9633 12.7178 10.45 13.8027 9.405C14.8502 8.34167 15.3926 7.04 15.4301 5.5C15.3926 3.96 14.8689 2.65833 13.8027 1.595C12.7178 0.568333 11.3898 0.0366667 9.81854 0C8.24732 0.0366667 6.91926 0.55 5.83437 1.595C4.78689 2.65833 4.24444 3.96 4.20703 5.5C4.24444 7.04 4.76818 8.34167 5.83437 9.405C6.91926 10.4317 8.24732 10.9633 9.81854 11ZM7.31207 3.04333C7.98545 2.42 8.80847 2.09 9.81854 2.05333C10.8099 2.09 11.6516 2.42 12.325 3.04333C12.961 3.70333 13.2977 4.51 13.3351 5.5C13.2977 6.47167 12.961 7.29667 12.325 7.95667C11.6516 8.58 10.8286 8.91 9.81854 8.94667C8.82718 8.91 7.98545 8.58 7.31207 7.95667C6.6761 7.29667 6.33941 6.49 6.302 5.5C6.33941 4.52833 6.6761 3.70333 7.31207 3.04333Z\",\n fill: \"#F7716E\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M9.35169 19.9466H2.15025C2.35601 18.5716 2.97327 17.4166 3.98335 16.4999C5.01212 15.6199 6.24666 15.1616 7.70565 15.1249H11.9143C11.9143 15.1249 12.0826 15.1432 12.1574 15.1432L13.2985 13.1999C12.8495 13.1266 12.4006 13.0532 11.9143 13.0532H7.70565C5.51716 13.1082 3.70277 13.8599 2.26248 15.2899C0.80349 16.7016 0.0365839 18.4616 -0.0195312 20.6249C-0.0195312 21.0282 0.111404 21.3582 0.373275 21.6149C0.635145 21.8716 0.971836 21.9999 1.38335 21.9999H8.11716L9.33299 19.9466H9.35169Z\",\n fill: \"#F7716E\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M25.8314 20.2583C26.0558 20.6617 26.0558 21.0467 25.8314 21.4133C25.6256 21.78 25.2702 21.9817 24.7839 22H12.794C12.3076 22 11.9522 21.78 11.7465 21.4133C11.522 21.0467 11.522 20.6617 11.7465 20.2583L17.7508 10.2117C18.0127 9.82667 18.3681 9.625 18.7983 9.625C19.2285 9.625 19.5839 9.82667 19.8457 10.2117L25.8501 20.2583H25.8314ZM18.7983 20.24C19.0414 20.24 19.2472 20.1483 19.4155 19.9833C19.5839 19.8183 19.6774 19.6167 19.6774 19.3783C19.6774 19.1217 19.5839 18.9017 19.4155 18.7367C19.2472 18.5717 19.0414 18.48 18.7983 18.48C18.5551 18.48 18.3493 18.5717 18.181 18.7367C18.0127 18.9017 17.9191 19.1217 17.9191 19.3783C17.9191 19.6167 18.0127 19.8183 18.181 19.9833C18.3493 20.1483 18.5551 20.24 18.7983 20.24ZM18.1249 13.3833V16.9217C18.1249 17.105 18.1997 17.27 18.3493 17.3983C18.4803 17.5267 18.6486 17.6 18.8357 17.6C19.2285 17.5633 19.4529 17.3433 19.4904 16.94V13.4017C19.4529 12.9983 19.2285 12.7783 18.817 12.7417C18.4055 12.7783 18.181 12.9983 18.1436 13.4017L18.1249 13.3833Z\",\n fill: \"#F7716E\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_28973_264514\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 26,\n height: 22,\n fill: \"white\"\n})));\n\nvar SvgParticipantAbsentRed = function SvgParticipantAbsentRed(_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: 26,\n height: 22,\n viewBox: \"0 0 26 22\",\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(SvgParticipantAbsentRed, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/participant_absent_red.9619f849.svg\";\nexport { ForwardRef as ReactComponent };","import React, { useEffect } from 'react';\nimport { Box, BoxProps, makeStyles } from '@material-ui/core';\n\nimport { useAppDispatch } from '../../redux/store';\nimport { setSessionLogAction } from '../../redux/modules/sessionLog';\nimport {\n NoShowParticipant,\n ScheduledSession,\n ScheduledSessionsLogActionIds,\n} from '../../types/types';\nimport useNoShowButtonsVisibility from '../../hooks/useNoShowButtonsVisibility';\n\nimport NoShowedTrigger from './NoShowedTrigger';\nimport StyledButton from '../buttons/StyledButton';\n\nimport { ReactComponent as ParticipantIcon } from '../../assets/participant_absent_red.svg';\nimport { isNoShowParticipantRequester } from '../../utils/helpers';\n\nconst useStyles = makeStyles((theme) => ({\n noShow: {\n '& > button': {\n width: '100%',\n maxWidth: 400,\n },\n },\n reminderSendedLabel: {\n fontSize: 14,\n fontWeight: 600,\n },\n reminderSentButton: {\n border: `1px solid ${theme.palette.kyoRed3.light}`,\n padding: theme.spacing(0.25, 2),\n display: 'flex',\n },\n}));\n\ninterface NoShowedLauncherProps {\n participant: NoShowParticipant;\n session: ScheduledSession;\n actions: Record<\n 'NotHere' | 'StillNotHere' | 'Arrived',\n ScheduledSessionsLogActionIds\n >;\n setShowDetails?: (segmentId: number | null) => void;\n boxProps?: BoxProps;\n}\n\nconst NoShowedLauncher: React.FC = (props) => {\n const {\n participant,\n session,\n actions,\n setShowDetails,\n boxProps = {},\n } = props;\n\n const classes = useStyles();\n const dispatch = useAppDispatch();\n\n const {\n canShowIsNotHereButton,\n canShowReminderSentButton,\n } = useNoShowButtonsVisibility(session as ScheduledSession, participant);\n\n useEffect(() => {\n if (!canShowIsNotHereButton && !canShowReminderSentButton) {\n dispatch(setSessionLogAction(null));\n }\n }, [canShowIsNotHereButton, canShowReminderSentButton, dispatch]);\n\n const {\n shouldReturnForClient,\n shouldReturnForProvider,\n } = isNoShowParticipantRequester(participant, session?.sessionLogs || []);\n\n if (shouldReturnForClient || shouldReturnForProvider) {\n return null;\n }\n\n if (!canShowIsNotHereButton && !canShowReminderSentButton) {\n return null;\n }\n\n return (\n \n {canShowIsNotHereButton && (\n \n )}\n {canShowReminderSentButton && (\n {\n if (setShowDetails) {\n setShowDetails(session.segmentId);\n }\n }}\n >\n \n \n Reminder Sent - View Details\n \n \n )}\n \n );\n};\n\nexport default NoShowedLauncher;\n","import React, { useState } from 'react';\nimport moment from 'moment';\nimport { makeStyles, Theme, Typography } from '@material-ui/core';\n\nimport StyledButtonLink from '../buttons/StyledButtonLink';\nimport {\n NoShowParticipant,\n RequestType,\n ScheduledSession,\n UserType,\n} from '../../types/types';\nimport useOptOutAllowedUntil from '../../providerPortal/requests/hooks/useOptOutAllowedUntil';\nimport OptOutAllowedBadgeIcon from '../badges/OptOutAllowedBadge/OptOutAllowedBadgeIcon';\nimport {\n RemoveSessionVariantText,\n NoShowActionsByReporter,\n} from '../../shared/constants';\nimport SessionProviderProfilePicture from '../SessionProviderProfilePicture/SessionProviderProfilePicture';\nimport SimpleDialog from '../Dialogs/SimpleDialog';\nimport SessionTitleByStatus from '../../commonPages/MySchedule/layers/sessionLayer/SessionTitleByStatus';\nimport {\n canSearchForSub,\n getSessionTimes,\n getSessionWith,\n isSessionCancellable,\n} from '../../utils/sessions';\nimport SessionBadge from '../../providerPortal/sessions/SessionBadge';\nimport NoShowedLauncher from '../NoShowed/NoShowedLauncher';\nimport SearchForSub from '../SearchForSub/SearchForSub';\nimport JiraStatusBadge from '../JiraStatusBadge/JiraStatusBadge';\nimport { DISTRICT_PAYER_TYPE } from '../../utils/constants';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n sessionCard: {\n paddingTop: theme.spacing(1.5),\n paddingBottom: theme.spacing(0.5),\n },\n sessionViewDetails: {\n marginRight: theme.spacing(2.5),\n fontWeight: 400,\n },\n sessionCancel: {\n fontWeight: 400,\n },\n sessionTimes: {\n color: theme.palette.kyoGray.dark,\n },\n sessionWith: {\n marginRight: theme.spacing(1),\n color: theme.palette.kyoGray3.main,\n },\n row: {\n display: 'flex',\n alignItems: 'center',\n marginBottom: theme.spacing(0.5),\n position: 'relative',\n },\n avatarContainer: {\n position: 'absolute',\n right: 0,\n },\n dialogTitle: {\n padding: 0,\n background: 'none',\n paddingRight: theme.spacing(2),\n paddingTop: theme.spacing(1),\n },\n dialogContent: {\n [theme.breakpoints.up('sm')]: {\n minWidth: 400,\n },\n },\n badge: {\n // Add styles for the badge if needed\n },\n}));\n\ninterface SessionCardProps {\n session: ScheduledSession;\n onCancel?: (session: ScheduledSession) => void;\n children?: (props: { closeDialog: () => void }) => React.ReactNode;\n userType: UserType;\n hideSessionWith?: boolean;\n hideProviderProfilePicture?: boolean;\n viewDetailsButtonText?: string;\n}\n\nconst SessionCard = (props: SessionCardProps) => {\n const {\n session,\n userType,\n onCancel,\n hideSessionWith = false,\n hideProviderProfilePicture = false,\n viewDetailsButtonText = 'View Details',\n children,\n } = props;\n\n const [showDetails, setShowDetails] = useState(false);\n\n const {\n billingCode,\n bookRequestType,\n createdAt,\n status,\n removeSessionVariant,\n provider,\n overlappingSessions,\n isActiveSession,\n } = session;\n\n const classes = useStyles();\n\n const isSubOfferSession = bookRequestType === RequestType.SubOffer;\n\n const optOutAllowedUntil = useOptOutAllowedUntil(createdAt || '');\n const showOptOutAllowed =\n isSubOfferSession &&\n userType === UserType.Provider &&\n moment().isSameOrBefore(optOutAllowedUntil) &&\n !!status;\n\n const sessionTimes = getSessionTimes(session);\n\n let noShowParticipant;\n\n if (userType === UserType.Client) {\n noShowParticipant = NoShowParticipant.Provider;\n } else if (session.client.payerType === DISTRICT_PAYER_TYPE) {\n noShowParticipant = NoShowParticipant.DistrictClient;\n } else {\n noShowParticipant = NoShowParticipant.Client;\n }\n\n return (\n
\n
\n \n
\n
\n \n {sessionTimes}\n \n
\n
\n {!hideSessionWith && (\n \n {getSessionWith(session, userType)}\n \n )}\n {userType === UserType.Provider && (\n \n )}\n
\n
\n
\n {\n setShowDetails((curr) => !curr);\n }}\n >\n {viewDetailsButtonText}\n \n {onCancel && isSessionCancellable(session, userType) && (\n {\n if (onCancel) {\n onCancel(session as ScheduledSession);\n }\n }}\n >\n {removeSessionVariant &&\n RemoveSessionVariantText[removeSessionVariant]}\n \n )}\n
\n {!hideProviderProfilePicture &&\n userType === UserType.Client &&\n provider &&\n !canSearchForSub(session) && (\n
\n \n
\n )}\n\n \n
\n {session.sessionUpdate?.jiraItem && (\n \n )}\n {showOptOutAllowed && }\n {isActiveSession && (\n {\n setShowDetails(true);\n }}\n boxProps={{\n marginY: 2,\n }}\n />\n )}\n {\n setShowDetails(false);\n }}\n classNames={{\n title: classes.dialogTitle,\n content: classes.dialogContent,\n }}\n >\n {children?.({\n closeDialog: () => {\n setShowDetails(false);\n },\n })}\n \n
\n );\n};\n\nexport default SessionCard;\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 fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M6 3H16.5C18.1569 3 19.5 4.34315 19.5 6V21C19.5 22.6569 18.1569 24 16.5 24H6C4.34315 24 3 22.6569 3 21V6C3 4.34314 4.34315 3 6 3ZM6 4.5C5.17157 4.5 4.5 5.17157 4.5 6V21C4.5 21.8284 5.17157 22.5 6 22.5H16.5C17.3284 22.5 18 21.8284 18 21V6C18 5.17157 17.3284 4.5 16.5 4.5H6Z\",\n fill: \"#616161\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M9 0H19.5C21.1569 0 22.5 1.34315 22.5 3V18C22.5 19.6569 21.1569 21 19.5 21V19.5C20.3284 19.5 21 18.8284 21 18V3C21 2.17157 20.3284 1.5 19.5 1.5H9C8.17157 1.5 7.5 2.17157 7.5 3H6C6 1.34315 7.34315 0 9 0Z\",\n fill: \"#616161\"\n});\n\nvar SvgFiles = function SvgFiles(_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: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\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(SvgFiles, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/files.66a10bb2.svg\";\nexport { ForwardRef as ReactComponent };","import React from 'react';\nimport clsx from 'clsx';\nimport { fade, makeStyles, Theme } from '@material-ui/core';\nimport { ReactComponent as FlagIcon } from '../../assets/flag-icon.svg';\n\nimport { JiraTicketStasusId } from '../../types/sessionUpdates.types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n display: 'inline-flex',\n alignItems: 'center',\n padding: theme.spacing(0.5, 1.5),\n borderRadius: 16,\n gap: theme.spacing(0.5),\n },\n icon: {\n fontSize: 16,\n },\n text: {\n fontSize: 12,\n fontWeight: 700,\n },\n yellow: {\n backgroundColor: fade(theme.palette.kyoBurntOrange.main, 0.1),\n '& $icon, & $text': {\n color: theme.palette.kyoBurntOrange.main,\n backgroundColor: 'transparent',\n },\n },\n red: {\n backgroundColor: fade(theme.palette.kyoRed.main, 0.1),\n '& $icon, & $text': {\n color: theme.palette.kyoRed.main,\n backgroundColor: 'transparent',\n },\n },\n green: {\n backgroundColor: fade(theme.palette.kyoPastelGreen.main, 0.1),\n '& $icon, & $text': {\n color: theme.palette.kyoPastelGreen.main,\n backgroundColor: 'transparent',\n },\n },\n}));\n\ninterface JiraStatusBadgeProps {\n statusId?: JiraTicketStasusId;\n className?: string;\n}\n\nconst getStatusConfig = (\n statusId?: JiraTicketStasusId\n): { colorClass: 'red' | 'green' | 'yellow'; text: string } => {\n switch (statusId) {\n case JiraTicketStasusId.Open:\n case JiraTicketStasusId.ResponseReceived:\n default:\n return {\n colorClass: 'yellow',\n text: 'Update Reported - In Process',\n };\n case JiraTicketStasusId.WaitingOnResponse:\n return {\n colorClass: 'red',\n text: 'Update Reported - Needs Your Response',\n };\n case JiraTicketStasusId.Done:\n return {\n colorClass: 'green',\n text: 'Update Reported - Completed',\n };\n }\n};\n\nconst JiraStatusBadge = ({ statusId, className }: JiraStatusBadgeProps) => {\n const classes = useStyles();\n const { colorClass, text } = getStatusConfig(statusId);\n\n return (\n
\n \n {text}\n
\n );\n};\n\nexport default JiraStatusBadge;\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 fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M0.740242 16L0.740243 2.702C-0.339789 2.08556 -0.227869 0.432099 1.00978 0.0745824C2.74269 -0.42683 3.76909 1.73071 2.28801 2.64471L2.28055 16H0.740242ZM14 11.0207V2C12.8784 2.91648 11.5489 3.12956 10.1594 2.94379C9.4941 2.85495 8.82234 2.68084 8.1484 2.50616C6.42293 2.05895 4.68307 1.608 3 2.57456V11.5952C4.68456 10.6053 6.42035 11.0498 8.1672 11.4972C9.66449 11.8806 11.1699 12.2662 12.6582 11.7523C13.1413 11.5855 13.5774 11.31 14 11.0207Z\",\n fill: \"currentColor\"\n});\n\nvar SvgFlagIcon = function SvgFlagIcon(_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: 14,\n height: 16,\n viewBox: \"0 0 14 16\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgFlagIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/flag-icon.70e3a2a4.svg\";\nexport { ForwardRef as ReactComponent };","import { makeStyles, Theme } from '@material-ui/core';\n\nexport type JSS = { [key: string]: string | number | JSS };\n\ninterface MakeStylesProps {\n cellSizes: number;\n addMainStyles?: (theme: Theme) => JSS;\n restStyles?: (theme: Theme) => { [key: string]: JSS };\n}\n\nconst useCellStyles = ({\n cellSizes,\n addMainStyles,\n restStyles,\n}: MakeStylesProps) =>\n makeStyles((theme) => ({\n main: {\n width: theme.spacing(cellSizes),\n height: theme.spacing(cellSizes),\n position: 'relative',\n borderRadius: '50%',\n margin: theme.spacing(1),\n ...(addMainStyles && addMainStyles(theme)),\n },\n ...(restStyles && restStyles(theme)),\n }));\n\nexport default useCellStyles;\n","import React from 'react';\nimport { Box, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n formContainer: {\n borderRadius: 16,\n padding: theme.spacing(3, 0, 6),\n backgroundColor: theme.palette.grey['50'],\n maxWidth: 560,\n minWidth: 280,\n [theme.breakpoints.down('md')]: {\n backgroundColor: '#fff',\n padding: theme.spacing(1, 0, 2),\n },\n },\n innerContainer: {\n width: '90%',\n margin: 'auto',\n maxWidth: 350,\n },\n}));\n\ninterface FormContainerProps {\n children: JSX.Element;\n className?: string;\n}\n\nconst FormContainer = (props: FormContainerProps) => {\n const { children, className } = props;\n const classes = useStyles();\n\n return (\n \n {children}\n \n );\n};\n\nexport default FormContainer;\n","import React from 'react';\nimport {\n Box,\n Dialog,\n DialogContent,\n DialogProps,\n Divider,\n LinearProgress,\n makeStyles,\n Theme,\n Typography,\n} from '@material-ui/core';\n\nimport SearchForSubInfoTitleIcon from '../../assets/search-for-sub-title-icon.svg';\nimport StyledButton from '../buttons/StyledButton';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n paper: {\n borderRadius: 20,\n paddingTop: theme.spacing(4),\n },\n wrapper: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n padding: theme.spacing(5),\n maxWidth: 500,\n textAlign: 'justify',\n },\n titleIcon: {\n marginBottom: theme.spacing(2),\n },\n title: {\n fontSize: 20,\n marginBottom: theme.spacing(3),\n textAlign: 'center',\n },\n textWithBullet: {\n position: 'relative',\n '&:before': {\n content: \"'•'\",\n position: 'absolute',\n left: '-18px',\n fontSize: '24px',\n lineHeight: 0.75,\n },\n },\n bold: {\n fontWeight: 'bold',\n marginRight: theme.spacing(1),\n },\n orangeText: {\n color: theme.palette.kyoBurntOrange.main,\n fontWeight: 'bold',\n },\n buttonContainer: {\n marginTop: theme.spacing(2),\n width: '100%',\n display: 'flex',\n flexDirection: 'column',\n '& > button': {\n marginBottom: theme.spacing(3),\n },\n },\n}));\n\nconst SearchForSubDialogWrapper = (\n props: { loading?: boolean } & DialogProps\n) => {\n const classes = useStyles();\n\n const { children, loading } = props;\n\n return (\n \n \n \n\n {children}\n\n \n {loading && }\n \n \n \n );\n};\n\ninterface SearchForSubConfirmDialogProps extends DialogProps {\n confirmHandler: () => void;\n declineHandler: () => void;\n loading?: boolean;\n}\n\nexport const SearchForSubConfirmDialog = (\n props: SearchForSubConfirmDialogProps\n) => {\n const { confirmHandler, declineHandler, loading } = props;\n const classes = useStyles();\n\n return (\n \n Search for Sub\n \n \n Care can help locate a substitute BT for this canceled session. You\n will be notified if a sub is found.\n \n \n \n \n What sessions are eligible\n This option is available for canceled sessions in the next 3 to 30\n days.\n \n \n \n \n How to manage these sessions\n These sessions will appear as{' '}\n \n Pending - Searching for Sub\n {' '}\n until a provider is confirmed or the request expires. If you change\n your mind, you can remove these pending sessions directly from your\n schedule.\n \n \n\n \n \n Yes - Search For Sub\n \n \n Nevermind\n \n \n \n );\n};\n\nexport const SearchForSubEnableAttributeDialog = (\n props: SearchForSubConfirmDialogProps\n) => {\n const { confirmHandler, declineHandler, loading } = props;\n const classes = useStyles();\n\n return (\n \n \n Thank you - we will notify you if a provider is confirmed.\n \n \n \n \n \n \n Want to Search for Subs automatically?\n \n \n \n \n Care can help staff more of your session opportunities. If you turn on\n the Search for Sub{' '}\n preference, Care will automatically search for a sub for any session\n removed by a BTs 3 to 30 days in advance.\n \n \n \n \n You can manage this preference at any time from My Profile.\n \n \n\n \n \n Yes - Turn on Search for Sub preference\n \n \n No Thanks\n \n \n \n );\n};\n\nexport const SearchForSubAttributeEnabledDialog = (\n props: Omit\n) => {\n const { confirmHandler } = props;\n const classes = useStyles();\n\n return (\n \n \n \n Great! The Search for Sub preference has been activated. Care will\n start searching for subs for removals submitted going forward.{' '}\n \n \n \n You can manage this preference at any time in My Profile.\n \n\n \n \n Close\n \n \n \n );\n};\n\nexport const SearchForSubCompleteDialog = (\n props: Omit\n) => {\n const { confirmHandler } = props;\n const classes = useStyles();\n\n return (\n \n \n Thank you - we will notify you if a provider is confirmed.\n \n \n \n \n \n \n How to manage these sessions\n \n \n \n \n These sessions will appear as{' '}\n \n Pending - Searching for Sub\n {' '}\n until a provider is confirmed or the request expires.{' '}\n \n \n \n If you change your mind, you can remove these pending sessions directly\n from your schedule.\n \n\n \n \n Close\n \n \n \n );\n};\n\nexport default SearchForSubDialogWrapper;\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 d: \"M7.74874 1.42039C6.74142 1.42039 5.84102 1.8793 5.24219 2.60055V0.733156C5.96663 0.268904 6.82656 0 7.74874 0C10.3296 0 12.4234 2.10674 12.4234 4.70719C12.4234 7.30766 10.3299 9.41439 7.74874 9.41439C6.82656 9.41439 5.96663 9.14549 5.24219 8.68123V6.81384C5.84102 7.53509 6.74142 7.994 7.74874 7.994C9.55286 7.994 11.014 6.52195 11.014 4.70719C11.014 2.89244 9.55286 1.42039 7.74874 1.42039Z\",\n fill: \"white\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M7 4.07699C7 3.8454 6.81218 3.65758 6.58059 3.65758H4.24232V1.31931C4.24232 1.08772 4.0545 0.899902 3.82291 0.899902H3.17709C2.9455 0.899902 2.75768 1.08772 2.75768 1.31931V3.65758H0.419407C0.18782 3.65758 0 3.8454 0 4.07699V4.72282C0 4.9544 0.18782 5.14222 0.419407 5.14222H2.75768V7.4805C2.75768 7.71208 2.9455 7.8999 3.17709 7.8999H3.82291C4.0545 7.8999 4.24232 7.71208 4.24232 7.4805V5.14222H6.58059C6.81218 5.14222 7 4.9544 7 4.72282V4.07699Z\",\n fill: \"white\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M10.8691 9.26954C11.4629 8.85697 11.9721 8.3303 12.3656 7.7207L14.6785 10.0497C14.9729 10.3461 14.9729 10.8265 14.6785 11.1229L14.2263 11.5783C13.9323 11.8743 13.4562 11.8743 13.1622 11.5783L10.8691 9.26954Z\",\n fill: \"white\"\n});\n\nvar SvgSearchPlus = function SvgSearchPlus(_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: 15,\n height: 12,\n viewBox: \"0 0 15 12\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgSearchPlus, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/searchPlus.638bee88.svg\";\nexport { ForwardRef as ReactComponent };","import React, { useState } from 'react';\n\nimport {\n SearchForSubConfirmDialog,\n SearchForSubEnableAttributeDialog,\n SearchForSubAttributeEnabledDialog,\n SearchForSubCompleteDialog,\n} from './SearchForSubDialogs';\nimport { useAppDispatch, useAppSelector } from '../../redux/store';\nimport { updateClientAttributes } from '../../redux/modules/client';\nimport { ScheduledSession } from '../../types/types';\nimport { createOpenSessionFromCancellation } from '../../redux/modules/openSessions';\nimport SearchForSubButton from './SearchForSubButton';\n\ntype Props = {\n session: ScheduledSession;\n showButton: boolean;\n buttonClassName?: string;\n};\n\nenum SearchForSubSteps {\n ConfirmSearch = 'ConfirmSearch',\n SearchComplete = 'SearchComplete',\n EnablePreference = 'EnablePreference',\n EnablePreferenceComplete = 'EnablePreferenceComplete',\n}\n\nconst SearchForSub = (props: Props) => {\n const dispatch = useAppDispatch();\n const { session, buttonClassName, showButton } = props;\n\n const currentClient = useAppSelector((state) => state.client.currentClient);\n const updatingClientAttributes = useAppSelector(\n (state) => state.client.updatingClientAttributes\n );\n const isSearchForSubAttributeEnabled =\n currentClient?.attributes?.searchForSub;\n\n const openSessionsLoading = useAppSelector(\n (state) => state.openSessions.openSessionsLoading\n );\n\n const [step, setStep] = useState(null);\n\n return (\n <>\n {showButton && (\n {\n setStep(SearchForSubSteps.ConfirmSearch);\n }}\n className={buttonClassName}\n />\n )}\n {step === SearchForSubSteps.ConfirmSearch && (\n {\n setStep(null);\n }}\n open\n confirmHandler={async () => {\n if (session.cancellationEvent?.id) {\n const result = await dispatch(\n createOpenSessionFromCancellation({\n cancellationEventId: session.cancellationEvent.id,\n })\n );\n if (result.meta.requestStatus === 'fulfilled') {\n if (!isSearchForSubAttributeEnabled) {\n setStep(SearchForSubSteps.EnablePreference);\n } else {\n setStep(SearchForSubSteps.SearchComplete);\n }\n }\n }\n }}\n declineHandler={() => {\n setStep(null);\n }}\n loading={openSessionsLoading}\n />\n )}\n {step === SearchForSubSteps.EnablePreference && (\n {\n setStep(null);\n }}\n open\n confirmHandler={async () => {\n if (currentClient?.attributes) {\n const result = await dispatch(\n updateClientAttributes({\n clientId: currentClient.id,\n attributes: {\n ...currentClient.attributes,\n searchForSub: true,\n },\n })\n );\n if (result.meta.requestStatus === 'fulfilled') {\n setStep(SearchForSubSteps.EnablePreferenceComplete);\n }\n }\n }}\n declineHandler={() => {\n setStep(null);\n }}\n loading={updatingClientAttributes}\n />\n )}\n {step === SearchForSubSteps.EnablePreferenceComplete && (\n {\n setStep(null);\n }}\n open\n confirmHandler={() => {\n setStep(null);\n }}\n />\n )}\n {step === SearchForSubSteps.SearchComplete && (\n {\n setStep(null);\n }}\n open\n confirmHandler={() => {\n setStep(null);\n }}\n />\n )}\n \n );\n};\n\nexport default SearchForSub;\n","import React from 'react';\nimport { makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\nimport StyledButton from '../buttons/StyledButton';\nimport { ReactComponent as SearchPlusIcon } from '../../assets/searchPlus.svg';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n button: {\n backgroundColor: theme.palette.kyoBlue2.main,\n color: '#fff',\n fontSize: 14,\n border: `2px solid ${theme.palette.kyoBlue.main}`,\n boxShadow: 'none',\n '&:hover': {\n backgroundColor: theme.palette.kyoBlue2.dark,\n },\n },\n}));\n\ntype Props = {\n onClick: () => void;\n className?: string;\n};\n\nconst SearchForSubButton = (props: Props) => {\n const classes = useStyles();\n const { onClick, className } = props;\n\n return (\n }\n onClick={onClick}\n >\n Search for Sub?\n \n );\n};\n\nexport default SearchForSubButton;\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(\"rect\", {\n x: 6,\n y: 17,\n width: 23,\n height: 15,\n fill: \"white\"\n});\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M3.79238 13.0083C3.33959 13.0083 3 12.6614 3 12.2611V10.0192C3 8.36447 4.41497 7.03003 6.16952 7.03003H9.33905V3.74729C9.33905 3.32027 9.70694 3 10.1314 3H12.7916C13.2444 3 13.5839 3.34696 13.5839 3.74729V7.00334H22.0737V3.74729C22.0737 3.32027 22.4416 3 22.8661 3H25.5263C25.979 3 26.3186 3.34696 26.3186 3.74729V7.00334H29.4882C31.2427 7.00334 32.6577 8.33778 32.6577 9.99249V12.2344C32.6577 12.6614 32.2898 12.9817 31.8653 12.9817H3.79238V13.0083ZM31.9219 15.01C32.3747 15.01 32.7143 15.357 32.7143 15.7573V32.0108C32.7143 33.6656 31.2993 35 29.5448 35H6.16952C4.41497 35 3 33.6656 3 32.0108V15.7573C3 15.3303 3.36789 15.01 3.79238 15.01H31.9219ZM24.0264 19.2269C23.7151 18.9333 23.2057 18.9333 22.8944 19.2269L15.8479 25.819L12.7916 22.9099C12.4803 22.6163 11.9709 22.6163 11.6596 22.9099L9.76354 24.6714C9.45225 24.965 9.45225 25.4454 9.76354 25.739L15.2536 30.9433C15.5649 31.2369 16.0743 31.2369 16.3856 30.9433L25.8659 22.0826C26.1771 21.789 26.1771 21.3086 25.8659 21.015L23.9981 19.2269H24.0264Z\",\n fill: \"#3AD449\"\n});\n\nvar _ref4 = /*#__PURE__*/React.createElement(\"path\", {\n d: \"M34.2143 15.7573C34.2143 15.0163 33.8572 14.3782 33.3163 13.9733C33.8132 13.5817 34.1577 12.9814 34.1577 12.2344V9.99249C34.1577 7.42777 31.9871 5.50334 29.4882 5.50334H27.8186V3.74729C27.8186 2.47101 26.7591 1.5 25.5263 1.5H22.8661C21.7333 1.5 20.5737 2.37667 20.5737 3.74729V5.50334H15.0839V3.74729C15.0839 2.47101 14.0245 1.5 12.7916 1.5H10.1314C8.99857 1.5 7.83905 2.37668 7.83905 3.74729V5.53003H6.16952C3.67055 5.53003 1.5 7.45446 1.5 10.0192V12.2611C1.5 12.9809 1.83706 13.6037 2.35218 14.0098C1.84949 14.4012 1.5 15.0048 1.5 15.7573V32.0108C1.5 34.5756 3.67055 36.5 6.16952 36.5H29.5448C32.0437 36.5 34.2143 34.5756 34.2143 32.0108V15.7573ZM16.8726 26.9144L23.4407 20.7698L24.2474 21.5421L15.8229 29.4161L11.3867 25.2108L12.22 24.4367L14.8137 26.9055L15.839 27.8814L16.8726 26.9144ZM10.7927 24.6477C10.7936 24.6486 10.7946 24.6495 10.7955 24.6503L10.7927 24.6477Z\"\n});\n\nvar SvgConfirmIcon = function SvgConfirmIcon(_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: 36,\n height: 38,\n viewBox: \"0 0 36 38\",\n fill: \"none\",\n ref: svgRef\n }, props), title ? /*#__PURE__*/React.createElement(\"title\", null, title) : null, _ref2, _ref3, _ref4);\n};\n\nvar ForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {\n return /*#__PURE__*/React.createElement(SvgConfirmIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/confirm_icon.df3a428c.svg\";\nexport { ForwardRef as ReactComponent };","import {\n createAsyncThunk,\n createSlice,\n Dispatch,\n PayloadAction,\n} from '@reduxjs/toolkit';\nimport notificationApi from '../../api/notificationsApi';\nimport { RootState } from './rootReducer';\nimport { Notification } from '../../types/types';\n\nexport interface NotificationsState {\n notifications: Notification[];\n notificationsLoading: boolean;\n notificationsRequestId: string | undefined;\n total: number;\n selectedRows: number[];\n unreadCount: number;\n isSelectMode: boolean;\n isSelectAll: boolean;\n}\n\nconst initialState: NotificationsState = {\n notifications: [],\n notificationsLoading: false,\n notificationsRequestId: undefined,\n total: 0,\n selectedRows: [],\n unreadCount: 0,\n isSelectMode: false,\n isSelectAll: false,\n};\n\nexport const fetchUnreadCount = createAsyncThunk(\n 'notifications/fetchUnreadCount',\n () => {\n return notificationApi.fetchUnreadCount();\n }\n);\n\nexport const fetchNotifications = createAsyncThunk(\n 'notifications/fetchNotifications',\n (arg: {\n filters: {\n isSeen?: boolean;\n };\n paging?: { page: number; rowsPerPage: number };\n }) => {\n const { filters, paging } = arg;\n return notificationApi.fetchNotifications(filters, paging);\n }\n);\n\nexport const bulkUpdateIsSeen = createAsyncThunk(\n 'notifications/bulkUpdateIsSeen',\n (\n arg: {\n isSeen: boolean;\n ids: number[];\n },\n thunkAPI\n ) => {\n const { isSeen, ids } = arg;\n return notificationApi\n .bulkUpdateIsSeen(isSeen, ids)\n .catch((err) => thunkAPI.rejectWithValue(err));\n }\n);\n\nconst notificationsSlice = createSlice({\n name: 'notifications',\n initialState,\n reducers: {\n setTotal: (state, action: PayloadAction) => ({\n ...state,\n total: action.payload,\n }),\n setSelectedRows: (state, action: PayloadAction) => ({\n ...state,\n selectedRows: action.payload,\n }),\n setUnreadCount: (state, action: PayloadAction) => ({\n ...state,\n unreadCount: action.payload,\n }),\n setIsSelectMode: (state, action: PayloadAction) => ({\n ...state,\n isSelectMode: action.payload,\n }),\n setIsSelectAll: (state, action: PayloadAction) => ({\n ...state,\n isSelectAll: action.payload,\n }),\n },\n extraReducers: (builder) => {\n builder\n .addCase(fetchNotifications.pending, (state, action) => {\n return {\n ...state,\n notificationsLoading: true,\n notificationsRequestId: action.meta.requestId,\n };\n })\n .addCase(fetchNotifications.fulfilled, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.notificationsRequestId &&\n state.notificationsRequestId === requestId\n ) {\n return {\n ...state,\n notifications: action.payload.items,\n notificationsLoading: false,\n total: action.payload.meta.totalItems,\n };\n }\n return state;\n })\n .addCase(fetchNotifications.rejected, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.notificationsRequestId &&\n state.notificationsRequestId === requestId\n ) {\n return {\n ...state,\n notificationsLoading: false,\n };\n }\n return state;\n })\n\n .addCase(fetchUnreadCount.fulfilled, (state, action) => {\n return {\n ...state,\n unreadCount: action.payload,\n };\n });\n },\n});\n\nexport const {\n setTotal,\n setSelectedRows,\n setIsSelectMode,\n setIsSelectAll,\n} = notificationsSlice.actions;\n\nexport default notificationsSlice.reducer;\n\nexport const selectRow = (rowId: number) => (\n dispatch: Dispatch,\n getState: () => RootState\n) => {\n const { selectedRows } = getState().notifications;\n return dispatch(setSelectedRows([...selectedRows, rowId]));\n};\n\nexport const deselectRow = (rowId: number) => (\n dispatch: Dispatch,\n getState: () => RootState\n) => {\n const { selectedRows } = getState().notifications;\n return dispatch(\n setSelectedRows(selectedRows.filter((r: number) => r !== rowId))\n );\n};\n","import React from 'react';\nimport { makeStyles, Theme } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n badge: {\n backgroundColor: theme.palette.kyoGray.light,\n borderRadius: theme.spacing(1),\n border: `1px solid ${theme.palette.kyoGray.main}`,\n display: 'inline-flex',\n alignItems: 'center',\n gap: 5,\n fontSize: theme.spacing(1.375),\n fontWeight: 600,\n padding: theme.spacing(0, 1),\n },\n}));\n\ninterface BadgeProps {\n text: string;\n icon: React.ReactNode;\n textColor: string;\n}\n\nconst Badge = ({ text, icon, textColor }: BadgeProps) => {\n const classes = useStyles();\n\n return (\n
\n {text} {icon}\n
\n );\n};\n\nexport default Badge;\n","import React from 'react';\nimport { Avatar, Box, makeStyles, Theme, Typography } from '@material-ui/core';\nimport { Provider } from '../types/types';\nimport CovidBadgeIcon from './badges/CovidBadge/CovidBadgeIcon';\nimport ProviderBCBABadge from './badges/BCBABadge/ProviderBCBABadge';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n avatarContainer: {\n display: 'flex',\n alignItems: 'flex-start',\n marginBottom: theme.spacing(1),\n },\n avatar: {\n marginRight: theme.spacing(1),\n },\n title: {\n marginBottom: theme.spacing(2),\n },\n badgeContainer: {\n '& > *:not(:last-child)': {\n marginRight: theme.spacing(1),\n },\n },\n}));\n\ninterface ProviderCardHeaderProps {\n provider: Pick<\n Provider,\n 'firstName' | 'lastName' | 'profilePhoto' | 'covidVaccinatedDate' | 'title'\n >;\n title?: string;\n}\n\nconst ProviderCardHeader = (props: ProviderCardHeaderProps) => {\n const classes = useStyles();\n const { provider, title } = props;\n\n return (\n <>\n {title && (\n \n {title}\n \n )}\n \n \n \n {`${provider.firstName} ${provider.lastName}`}\n \n {provider.covidVaccinatedDate && }\n \n \n \n \n \n );\n};\n\nexport default ProviderCardHeader;\n","import React from 'react';\nimport { Box, makeStyles, Theme, Typography } from '@material-ui/core';\nimport { Language, ProviderAttributes } from '../types/types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n padding: theme.spacing(1, 0),\n color: theme.palette.grey[800],\n },\n}));\n\ninterface ProviderLanguagesProps {\n providerAttributes: ProviderAttributes | undefined;\n providerLanguages?: Language[];\n}\n\nconst ProviderLanguages = (props: ProviderLanguagesProps) => {\n const { providerAttributes, providerLanguages } = props;\n const classes = useStyles();\n\n let languageString = `Languages: `;\n\n if (providerLanguages) {\n const languages = ['English'];\n providerLanguages.forEach((l) => {\n languages.push(l.name);\n });\n languageString += `${languages.join(', ')}`;\n } else {\n const attrLanguages = [\n 'English',\n providerAttributes?.spanish && 'Spanish',\n providerAttributes?.mandarin && 'Mandarin',\n providerAttributes?.cantonese && 'Cantonese',\n ];\n languageString += `${attrLanguages.filter(Boolean).join(', ')}`;\n }\n\n return (\n \n {languageString}\n \n );\n};\n\nexport default ProviderLanguages;\n","import React from 'react';\nimport { Box, makeStyles, Theme, Typography } from '@material-ui/core';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n padding: theme.spacing(1, 0),\n color: theme.palette.grey[800],\n },\n}));\n\ninterface ProviderCardBioProps {\n text: string | null | undefined;\n}\n\nconst ProviderCardBio = (props: ProviderCardBioProps) => {\n const { text } = props;\n const classes = useStyles();\n\n if (!text) {\n return null;\n }\n\n return (\n \n {text}\n \n );\n};\n\nexport default ProviderCardBio;\n","import React from 'react';\nimport { Box, Divider, makeStyles, Theme } from '@material-ui/core';\nimport clsx from 'clsx';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n root: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n content: {\n margin: theme.spacing(0, 1),\n flexShrink: 0,\n },\n divider: {\n width: '100%',\n flexShrink: 1,\n },\n}));\n\ninterface DividerTextProps {\n children: JSX.Element | string;\n className?: string;\n}\n\nconst DividerText = (props: DividerTextProps) => {\n const { children, className } = props;\n const classes = useStyles();\n\n return (\n \n \n {children}\n \n \n );\n};\n\nexport default DividerText;\n","type AppBarColor =\n | 'primary'\n | 'default'\n | 'inherit'\n | 'transparent'\n | 'secondary'\n | undefined;\n\ninterface Config {\n apiUrl: string;\n googleApiKey: string;\n cognito: { Auth: any };\n appBarColor: AppBarColor;\n oldUIUrl: string;\n gtagId: string | null;\n chatToken: string;\n portalUrl: string;\n educatorPortalUrl: string;\n revenuePortalUrl: string;\n chatHistoryDays: string;\n}\n\nconst {\n REACT_APP_CHAT_TOKEN = '',\n REACT_APP_API_URL = 'http://localhost:3001',\n REACT_APP_PORTAL_URL = 'http://localhost:3000/',\n REACT_APP_EDUCATOR_PORTAL_URL = '',\n REACT_APP_COGNITO_REGION,\n REACT_APP_COGNITO_USERPOOL,\n REACT_APP_COGNITO_CLIENT_ID,\n REACT_APP_COGNITO_USERPOOL_BASE_URI,\n REACT_APP_COGNITO_TOKEN_SCOPES,\n REACT_APP_COGNITO_AUTH_FLOW_TYPE,\n REACT_APP_SCH_PORTAL_URL,\n REACT_APP_COGNITO_COOKIE_DOMAIN,\n REACT_APP_REVENUE_PORTAL_URL = '',\n REACT_APP_CHAT_HISTORY_DAYS = '30',\n} = process.env;\n\nconst local: Config = {\n apiUrl: 'http://localhost:3001',\n googleApiKey: 'AIzaSyCOwZFM7lnTZ4RcXQE_MQCHz6eMZHk0Djg',\n chatHistoryDays: REACT_APP_CHAT_HISTORY_DAYS,\n cognito: {\n Auth: {\n region: 'us-east-1',\n userPoolId: 'us-east-1_j49Qvd6UR',\n userPoolWebClientId: '45u0sa1o2qm3tg89dqq5qemkff',\n oauth: {\n domain: 'kyo-attain-dev.auth.us-east-1.amazoncognito.com',\n scope: ['email', 'profile', 'openid'],\n redirectSignIn: REACT_APP_PORTAL_URL,\n redirectSignOut: REACT_APP_PORTAL_URL,\n responseType: 'code', // or 'token', note that REFRESH token will only be generated when the responseType is code\n },\n authenticationFlowType: REACT_APP_COGNITO_AUTH_FLOW_TYPE,\n },\n },\n appBarColor: 'primary',\n oldUIUrl: REACT_APP_SCH_PORTAL_URL || '',\n gtagId: null,\n chatToken: REACT_APP_CHAT_TOKEN,\n portalUrl: REACT_APP_PORTAL_URL,\n educatorPortalUrl: REACT_APP_EDUCATOR_PORTAL_URL,\n revenuePortalUrl: REACT_APP_REVENUE_PORTAL_URL,\n};\n\nconst dev: Config = {\n apiUrl: REACT_APP_API_URL || '',\n googleApiKey: 'AIzaSyCOwZFM7lnTZ4RcXQE_MQCHz6eMZHk0Djg',\n chatHistoryDays: REACT_APP_CHAT_HISTORY_DAYS,\n cognito: {\n Auth: {\n region: REACT_APP_COGNITO_REGION,\n userPoolId: REACT_APP_COGNITO_USERPOOL,\n userPoolWebClientId: REACT_APP_COGNITO_CLIENT_ID,\n oauth: {\n domain: REACT_APP_COGNITO_USERPOOL_BASE_URI,\n scope: REACT_APP_COGNITO_TOKEN_SCOPES?.split(',') || [],\n redirectSignIn: REACT_APP_PORTAL_URL,\n redirectSignOut: REACT_APP_PORTAL_URL,\n responseType: 'code', // or 'token', note that REFRESH token will only be generated when the responseType is code\n },\n authenticationFlowType: REACT_APP_COGNITO_AUTH_FLOW_TYPE,\n },\n },\n appBarColor: 'default',\n oldUIUrl: REACT_APP_SCH_PORTAL_URL || '',\n gtagId: null,\n chatToken: REACT_APP_CHAT_TOKEN,\n portalUrl: REACT_APP_PORTAL_URL,\n educatorPortalUrl: REACT_APP_EDUCATOR_PORTAL_URL,\n revenuePortalUrl: REACT_APP_REVENUE_PORTAL_URL,\n};\n\nconst prod: Config = {\n apiUrl: 'https://api.attain.kyocare.com',\n googleApiKey: 'AIzaSyCOwZFM7lnTZ4RcXQE_MQCHz6eMZHk0Djg',\n chatHistoryDays: REACT_APP_CHAT_HISTORY_DAYS,\n cognito: {\n Auth: {\n region: 'us-east-1',\n userPoolId: 'us-east-1_DEP9DvC1P',\n userPoolWebClientId: '4eqhlthm9ci87lpl36rnl637la',\n oauth: {\n domain: 'auth.kyocare.com',\n scope: ['email', 'profile', 'openid'],\n redirectSignIn: 'https://portal.kyocare.com/',\n redirectSignOut: 'https://portal.kyocare.com/',\n responseType: 'code', // or 'token', note that REFRESH token will only be generated when the responseType is code\n },\n authenticationFlowType: REACT_APP_COGNITO_AUTH_FLOW_TYPE,\n },\n },\n appBarColor: 'primary',\n oldUIUrl: 'https://attain.gatewaylg.com/',\n gtagId: 'G-CVDF88DBRF',\n chatToken: REACT_APP_CHAT_TOKEN,\n portalUrl: REACT_APP_PORTAL_URL,\n educatorPortalUrl: REACT_APP_EDUCATOR_PORTAL_URL,\n revenuePortalUrl: REACT_APP_REVENUE_PORTAL_URL,\n};\n\n// Default to local if not set\nlet config = local;\nif (process.env.REACT_APP_STAGE === 'prod') {\n config = prod;\n} else if (process.env.REACT_APP_STAGE === 'dev') {\n config = dev;\n}\n\nif (\n REACT_APP_COGNITO_COOKIE_DOMAIN &&\n REACT_APP_COGNITO_COOKIE_DOMAIN !== 'null'\n) {\n config.cognito.Auth.cookieStorage = {\n domain: REACT_APP_COGNITO_COOKIE_DOMAIN,\n sameSite: 'strict',\n secure: true,\n };\n}\n\nexport default {\n ...config,\n};\n","import { AccessControl } from 'accesscontrol';\n\nexport enum Role {\n admin = 'admin',\n UserMgr = 'UserMgr',\n SCH = 'SCH',\n 'HR/CRED/CS' = 'HR/CRED/CS',\n 'CLIN-RD/Con' = 'CLIN-RD/Con',\n 'CLIN-Staff' = 'CLIN-Staff',\n Client = 'Client',\n 'CLIN-BCBA' = 'CLIN-BCBA',\n 'CRED/CS' = 'CRED/CS',\n CS = 'CS',\n 'SCH-BTonly' = 'SCH-BTonly',\n RevenueTeam = 'RevenueTeam',\n 'Educator-Admin' = 'Educator-Admin',\n 'TAL/HR' = 'TAL/HR',\n}\n\nexport enum Resources {\n userAttributes = 'userAttributes',\n clientRoutes = 'clientRoutes',\n providerRoutes = 'providerRoutes',\n educatorPortal = 'educatorPortal',\n switchRole = 'switchRole',\n}\n\nexport enum BookingAttr {\n action = 'action',\n completion = 'completion',\n}\n\nexport enum AttributePermission {\n general = 'general',\n telehealthWaiver = 'telehealthWaiver',\n bio = 'bio',\n preferredServiceZip = 'preferredServiceZip',\n singleBookingAvailability = 'singleBookingAvailability',\n}\n\nconst grantsObject: { [key in Role]: object } = {\n admin: {\n [Resources.userAttributes]: {\n 'read:any': ['*'],\n 'update:any': [\n AttributePermission.general,\n AttributePermission.telehealthWaiver,\n AttributePermission.preferredServiceZip,\n AttributePermission.singleBookingAvailability,\n ],\n },\n [Resources.providerRoutes]: {\n 'read:any': ['*'],\n },\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n },\n UserMgr: {\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n },\n SCH: {\n [Resources.userAttributes]: {\n 'read:any': ['*'],\n 'update:any': [\n AttributePermission.general,\n AttributePermission.preferredServiceZip,\n AttributePermission.singleBookingAvailability,\n ],\n },\n [Resources.providerRoutes]: {\n 'read:any': ['*'],\n },\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n },\n CS: {\n [Resources.userAttributes]: {\n 'read:any': ['*'],\n 'update:any': [\n AttributePermission.general,\n AttributePermission.telehealthWaiver,\n AttributePermission.preferredServiceZip,\n ],\n },\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n },\n 'CLIN-RD/Con': {\n [Resources.userAttributes]: {\n 'read:any': ['*'],\n 'update:any': [\n AttributePermission.general,\n AttributePermission.preferredServiceZip,\n AttributePermission.singleBookingAvailability,\n ],\n },\n [Resources.providerRoutes]: {\n 'read:any': ['*'],\n },\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n },\n 'CLIN-Staff': {\n [Resources.userAttributes]: {\n 'update:own': [\n AttributePermission.bio,\n AttributePermission.preferredServiceZip,\n AttributePermission.singleBookingAvailability,\n ],\n },\n [Resources.providerRoutes]: {\n 'read:any': ['*'],\n },\n },\n Client: {\n [Resources.clientRoutes]: {\n 'read:any': ['*'],\n },\n },\n 'CLIN-BCBA': {\n [Resources.userAttributes]: {\n 'update:own': [\n AttributePermission.bio,\n AttributePermission.preferredServiceZip,\n ],\n },\n [Resources.providerRoutes]: {\n 'read:any': ['*'],\n },\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n },\n 'TAL/HR': {\n [Resources.switchRole]: {\n 'read:any': ['*'],\n },\n [Resources.userAttributes]: {\n 'read:any': ['*'],\n 'update:any': [\n AttributePermission.general,\n AttributePermission.bio,\n AttributePermission.preferredServiceZip,\n ],\n },\n },\n 'CRED/CS': {},\n 'HR/CRED/CS': {},\n 'SCH-BTonly': {},\n RevenueTeam: {},\n 'Educator-Admin': {\n [Resources.educatorPortal]: {\n 'read:any': ['*'],\n },\n },\n};\n\nexport const ac = new AccessControl(grantsObject);\n","import {\n createAsyncThunk,\n createSlice,\n PayloadAction,\n SerializedError,\n} from '@reduxjs/toolkit';\nimport moment from 'moment';\nimport { filter, max } from 'lodash';\nimport bookingApi from '../../api/bookingApi';\nimport providerApi from '../../api/providerApi';\nimport clientApi from '../../api/clientApi';\nimport { RootState } from './rootReducer';\nimport {\n ClientSTBRAvailability,\n ProviderWithBookDetails,\n ScheduledSession,\n SingleSessionProviderFilters,\n STBRBlockOption,\n UnratedSession,\n} from '../../types/types';\nimport { SessionPlacement } from './adminSettings';\nimport scheduleApi, {\n FetchUnratedSessionsFilters,\n} from '../../api/scheduleApi';\nimport unratedSuspendedSessions from '../../clientPortal/home/ratingProviders/unrated-suspended-sessions';\nimport { excludeRemovedSessions } from '../../commonPages/MySchedule/utils/statusHelpers';\n\nexport type SelectedBookingOption = Omit<\n STBRBlockOption,\n 'sessionPlacements'\n> & { sessionPlacement: SessionPlacement };\n\nexport const createSingleTermBookRequest = createAsyncThunk<\n void,\n {\n clientId: number;\n providerId: number;\n },\n { state: RootState }\n>(\n 'newSessions/createSingleTermBookRequest',\n (arg, { rejectWithValue, getState }) => {\n const { selectedBookingOptions } = getState().newSessions;\n const { clientId, providerId } = arg;\n\n return bookingApi\n .createSingleTermBookRequest(\n clientId,\n providerId,\n selectedBookingOptions.map((selectedOption) => ({\n schedDate: selectedOption.scheduledDate,\n sessionPlacement: selectedOption.sessionPlacement,\n }))\n )\n .then((response) => response)\n .catch((e) => rejectWithValue(e));\n }\n);\n\nexport const fetchSingleSessionProviders = createAsyncThunk<\n ProviderWithBookDetails[],\n SingleSessionProviderFilters,\n { state: RootState }\n>(\n 'newSessions/fetchSingleSessionProviders',\n async (filters: SingleSessionProviderFilters, thunkAPI) => {\n const state = thunkAPI.getState();\n const { currentClient } = state.client;\n const { singleSessionProvidersAbortController } = state.newSessions;\n\n if (!currentClient) {\n return thunkAPI.rejectWithValue(null);\n }\n\n return providerApi\n .fetchProvidersForSingleBook(\n currentClient.id,\n filters,\n singleSessionProvidersAbortController.signal\n )\n .catch((e) => {\n console.log(e);\n throw new Error(e.name);\n });\n }\n);\nexport const fetchClientSingleTermBookingAvailability = createAsyncThunk(\n 'newSessions/fetchClientSingleTermBookingAvailability',\n (clientId: number) => {\n return clientApi.fetchClientSingleTermBookingAvailability(clientId);\n }\n);\n\nexport const fetchClientSessions = createAsyncThunk(\n 'newSessions/fetchScheduledSessions',\n (\n payload: {\n clientId: number;\n startDate: string;\n endDate: string;\n },\n { rejectWithValue }\n ) =>\n scheduleApi\n .fetchClientFullSchedule(\n payload.clientId,\n payload.startDate,\n payload.endDate,\n true\n )\n .catch((e) => rejectWithValue('Failed to load scheduled sessions'))\n);\n\nexport const fetchUnratedSessions = createAsyncThunk(\n 'newSessions/fetchUnratedSessions',\n (payload: FetchUnratedSessionsFilters, { rejectWithValue }) =>\n scheduleApi\n .fetchUnratedSessions(payload)\n .catch((e) => rejectWithValue('Failed to load unrated sessions'))\n);\n\ninterface NewSessions {\n selectedProvider: ProviderWithBookDetails | null;\n selectedBookingOptions: SelectedBookingOption[];\n createSessionInProgress: boolean;\n createSessionSuccess: boolean;\n createSessionFailed: boolean;\n singleSessionProvidersLoading: boolean;\n singleSessionProviders: ProviderWithBookDetails[] | null;\n clientSTBRAvailability: ClientSTBRAvailability;\n clientSTBRAvailabilityLoading: boolean;\n clientSTBRAvailabilityError: SerializedError | null;\n maxDate: Date;\n singleSessionProvidersAbortController: AbortController;\n sessions: ScheduledSession[] | null;\n sessionsLoading: boolean;\n unratedSessions: UnratedSession[];\n unratedSessionsLoading: boolean;\n sessionsToRate: UnratedSession[];\n showSuspectedSessions: boolean;\n noLatestSessionsToRate: boolean;\n}\n\nconst initialState: NewSessions = {\n selectedProvider: null,\n selectedBookingOptions: [],\n createSessionInProgress: false,\n createSessionSuccess: false,\n createSessionFailed: false,\n singleSessionProviders: null,\n singleSessionProvidersLoading: false,\n clientSTBRAvailability: {\n canClientBook: false,\n forbidReason: '',\n maxNumberOfSessionsCanBooked: 0,\n minNumberOfSessionsCanBooked: 0,\n cancellationIds: [],\n extraSessionsNumberToSelect: 1,\n osStartDate: '',\n osEndDate: '',\n },\n clientSTBRAvailabilityLoading: false,\n clientSTBRAvailabilityError: null,\n maxDate: moment().startOf('day').add(30, 'day').toDate(),\n singleSessionProvidersAbortController: new AbortController(),\n sessions: null,\n sessionsLoading: false,\n unratedSessions: [],\n unratedSessionsLoading: false,\n sessionsToRate: [],\n showSuspectedSessions: false,\n noLatestSessionsToRate: false,\n};\n\nexport const newSessionsSlice = createSlice({\n name: 'newSessions',\n initialState,\n reducers: {\n setSelectedProvider: (\n state,\n action: PayloadAction\n ) => ({\n ...state,\n selectedProvider: action.payload,\n }),\n addSelectedBookingOption: (\n state,\n action: PayloadAction\n ) => {\n state.selectedBookingOptions = [\n ...state.selectedBookingOptions,\n action.payload,\n ];\n },\n removeSelectedBookingOption: (\n state,\n action: PayloadAction<{ scheduledDate: string; timeBlockId: number }>\n ) => {\n const { selectedBookingOptions } = state;\n const { scheduledDate, timeBlockId } = action.payload;\n\n const removeOptionIndex = selectedBookingOptions.findIndex(\n (option) =>\n option.scheduledDate === scheduledDate &&\n option.timeBlockId === timeBlockId\n );\n\n const clonedSelectedBookingOptions = [...selectedBookingOptions];\n clonedSelectedBookingOptions.splice(removeOptionIndex, 1);\n\n state.selectedBookingOptions = clonedSelectedBookingOptions;\n },\n clearSelectedBookingOptions: (state) => {\n state.selectedBookingOptions = [];\n },\n setCreateSessionSuccess: (state, action: PayloadAction) => {\n state.createSessionSuccess = action.payload;\n },\n setToInitialState: (state) => ({\n ...initialState,\n singleSessionProvidersLoading: state.singleSessionProvidersLoading,\n singleSessionProvidersAbortController:\n state.singleSessionProvidersAbortController,\n }),\n clearClientSessions: (state) => {\n state.sessions = null;\n state.sessionsLoading = false;\n },\n removeSessionFromRatingQueue: (state, action: PayloadAction) => {\n const restSessions = state.sessionsToRate.filter(\n (s) => s.segmentId !== action.payload\n );\n state.sessionsToRate = restSessions;\n if (restSessions.length === 0) {\n state.showSuspectedSessions = false;\n }\n },\n setShowSuspectedSessions: (state, action: PayloadAction) => {\n state.showSuspectedSessions = action.payload;\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(createSingleTermBookRequest.pending, (state) => {\n return {\n ...state,\n createSessionInProgress: true,\n };\n })\n .addCase(createSingleTermBookRequest.fulfilled, (state) => {\n return {\n ...state,\n createSessionInProgress: false,\n createSessionSuccess: true,\n createSessionFailed: false,\n };\n })\n .addCase(createSingleTermBookRequest.rejected, (state) => {\n return {\n ...state,\n createSessionInProgress: false,\n createSessionSuccess: false,\n createSessionFailed: true,\n };\n })\n .addCase(fetchSingleSessionProviders.pending, (state) => {\n if (state.singleSessionProvidersLoading) {\n state.singleSessionProvidersAbortController.abort();\n }\n\n return {\n ...state,\n singleSessionProvidersLoading: true,\n singleSessionProvidersAbortController: new AbortController(),\n };\n })\n .addCase(fetchSingleSessionProviders.fulfilled, (state, action) => {\n const scheduledDates: Date[] = [];\n\n action.payload.forEach((p) => {\n p.bookDetails.bookOptions.forEach((bo) =>\n scheduledDates.push(moment(bo.scheduledDate).toDate())\n );\n });\n\n const maxDate = max(scheduledDates);\n\n return {\n ...state,\n singleSessionProviders: action.payload,\n singleSessionProvidersLoading: false,\n maxDate: maxDate || moment().startOf('day').add(30, 'day').toDate(),\n };\n })\n .addCase(fetchSingleSessionProviders.rejected, (state, action) => {\n if (action.error.message === 'AbortError') {\n return { ...state };\n }\n\n return {\n ...state,\n singleSessionProvidersLoading: false,\n };\n })\n .addCase(fetchClientSingleTermBookingAvailability.pending, (state) => {\n return {\n ...state,\n clientSTBRAvailabilityLoading: true,\n };\n })\n .addCase(\n fetchClientSingleTermBookingAvailability.fulfilled,\n (state, action) => {\n return {\n ...state,\n clientSTBRAvailability: action.payload,\n clientSTBRAvailabilityLoading: false,\n };\n }\n )\n .addCase(\n fetchClientSingleTermBookingAvailability.rejected,\n (state, action) => {\n return {\n ...state,\n clientSTBRAvailabilityLoading: false,\n clientSTBRAvailabilityError: action.error,\n };\n }\n )\n .addCase(fetchClientSessions.pending, (state) => {\n state.sessions = null;\n state.sessionsLoading = true;\n })\n .addCase(fetchClientSessions.fulfilled, (state, action) => {\n state.sessionsLoading = false;\n state.sessions = excludeRemovedSessions(action.payload);\n })\n .addCase(fetchClientSessions.rejected, (state) => {\n state.sessionsLoading = false;\n })\n .addCase(fetchUnratedSessions.pending, (state) => {\n state.unratedSessions = [];\n state.sessionsToRate = [];\n state.unratedSessionsLoading = true;\n })\n .addCase(fetchUnratedSessions.fulfilled, (state, action) => {\n const fetchedSessions = action.payload;\n const { clientId } = action.meta.arg;\n\n state.unratedSessionsLoading = false;\n state.unratedSessions = fetchedSessions;\n\n if (!state.showSuspectedSessions) {\n state.sessionsToRate = filter(fetchedSessions, (fs) => {\n return !unratedSuspendedSessions\n .getValue(clientId)\n .includes(fs.segmentId);\n });\n } else {\n state.sessionsToRate = fetchedSessions;\n }\n\n state.noLatestSessionsToRate = fetchedSessions.length === 0;\n\n const oldUnratedSessions = unratedSuspendedSessions\n .getValue(clientId)\n .filter((suspendedSessionId) => {\n return !fetchedSessions.find(\n (fs) => fs.segmentId === suspendedSessionId\n );\n });\n\n unratedSuspendedSessions.remove(oldUnratedSessions, clientId);\n })\n .addCase(fetchUnratedSessions.rejected, (state) => {\n state.unratedSessionsLoading = false;\n });\n },\n});\n\nexport const {\n setSelectedProvider,\n setCreateSessionSuccess,\n setToInitialState,\n addSelectedBookingOption,\n clearSelectedBookingOptions,\n removeSelectedBookingOption,\n clearClientSessions,\n removeSessionFromRatingQueue,\n setShowSuspectedSessions,\n} = newSessionsSlice.actions;\n\nexport default newSessionsSlice.reducer;\n","import { SessionPlacement } from '../redux/modules/adminSettings';\nimport {\n ClientAttendanceStatusId,\n ProviderAttendanceStatusId,\n} from '../components/AttendanceStatus/constants/constants';\nimport { SessionUpdate } from './sessionUpdates.types';\n\nexport interface STBRBlockOption {\n providerId: number;\n scheduledDate: string;\n timeBlockId: number;\n rto: boolean;\n sessionPlacements: SessionPlacement[];\n isClientOccupied: boolean;\n dayOfWeekId: number;\n}\n\nexport interface ProviderSchedule {\n timeBlockId: number;\n providerId: number;\n dayOfWeekId: number;\n isAvailable: boolean;\n occupied1: number;\n occupied2: number;\n id: number;\n demandScore: number;\n demandRank: number;\n}\n\nexport interface ProviderCalculations {\n applicableCancelRate: number;\n providerAttendanceStatus: string;\n providerAttendanceStatusId: ProviderAttendanceStatusId;\n consecutiveEventsSinceCancelEvent: number;\n impactHours: number;\n ratingAverage: number | null;\n}\n\nexport interface BookDetails {\n inCaseTeam: boolean;\n bookOptions: STBRBlockOption[];\n preferredDatesAvailability?: string[];\n numOfPotentialSessions: number;\n}\n\nexport interface ProviderAttendanceAwards {\n attendanceAwards: AttendanceAward[];\n totalAmount: number;\n}\n\nexport interface AttendanceAward {\n id: number;\n providerId: number;\n isSeen: boolean;\n amount: number;\n streak: number;\n createdAt: Date;\n}\n\nexport type ProviderAttendanceAwardVisibilityStatus = Pick<\n AttendanceAward,\n 'id' | 'isSeen'\n>;\n\nexport type AtFaultParty = 'Client' | 'Provider' | 'None';\n\nexport interface ProviderAcceptanceRate {\n ltAcceptanceRate: number | null;\n stAcceptanceRate: number | null;\n}\n\nexport interface ProviderLevel {\n cancels: number;\n hours: number;\n level: ClimbLevels | null;\n level1Reason: string;\n providerId: number;\n rating: number | null;\n ratingsClientCount: number;\n}\n\nexport interface Provider {\n id: number;\n name: string;\n lastName: string;\n firstName: string;\n email: string;\n providerZip: string;\n department: string;\n office: string;\n region: string;\n profilePhoto: string;\n title: string;\n homeZip: string;\n futureBTHrsWorked: number;\n minHrsTarget: number;\n maxHrsTarget: number;\n btFulfillmentThreshold: number;\n calculations: ProviderCalculations;\n mobile: string;\n isActive: boolean;\n termAnnounceDate: string;\n availSubmissionMostRecent: string | null;\n startDate: string | null;\n isSupervisor: boolean;\n availUpcomingChangeDate: string | null;\n btCredLabelAdjusted: string;\n covidVaccinatedDate: string;\n timezoneIANA: string;\n attributes?: ProviderAttributes;\n schedule?: ProviderSchedule[];\n tenure: number | null;\n mentorId?: number;\n rbtExpirationDate: string | null;\n rbaiOregonExpirationDate: string | null;\n cbtWashingtonExpirationDate: string | null;\n restraintTrainingExpirationDate: string | null;\n acceptanceRate?: ProviderAcceptanceRate;\n languages?: Language[];\n address: ProviderAddress;\n homeAddressStreet: string;\n homeAddressCity: string;\n homeAddressState: string;\n level: ProviderLevel;\n level1Reason?: string;\n}\n\nexport type Address = {\n zip: string | null;\n street: string | null;\n city: string | null;\n state: string | null;\n};\n\nexport interface ProviderAddress extends Address {\n zipCodeData?: ZipCodeData;\n providerId?: number;\n}\n\nexport interface ProviderWithMentees extends Provider {\n mentees: Array;\n}\n\nexport interface User {\n id: number;\n username: string;\n mobileNumber: string;\n firstName: string;\n lastName: string;\n associations: UserAssociation[];\n adminActionLogs: AdminActionLog[];\n notificationPreferences: NotificationPreference[];\n}\n\nexport interface RequestActionLog {\n id: number;\n createdAt: Date;\n bookRequestId: number;\n action: { id: number; name: string }; // ActionType = action.name\n requester?: { id: number; name: string }; // Initiator\n notification?: {\n message: string;\n status?: { name: string };\n recipients: any;\n };\n}\n\nexport interface ZipCodeData {\n latitude: string;\n longitude: string;\n zipCode: string;\n distance?: string;\n timezoneNameIANA: string;\n}\n\nexport interface ProviderAttributes {\n spanish: boolean;\n mandarin: boolean;\n cantonese: boolean;\n dogAllergy: boolean;\n catAllergy: boolean;\n locationAnomaly: boolean;\n locationNotes: string;\n bio: string | null;\n singleBookingAvailability: SingleBookingAvailabilityType;\n pause: boolean;\n approvedForTolls: boolean;\n zipCodeData?: ZipCodeData;\n}\n\nexport interface ProviderWithBookDetails extends Provider {\n bookDetails: BookDetails;\n}\n\nexport interface SingleSessionProviderFilters {\n caseTeam?: 'excluded' | 'only';\n ignoreAvailability?: boolean;\n}\n\nexport interface TimeDayBlock {\n id: number;\n timeBlockId: number;\n dayOfWeekId: number;\n}\n\nexport enum RequestStatus {\n QUEUED = 1,\n PENDING = 2,\n ACCEPTED = 3,\n DECLINED = 4,\n CONFIRMED = 5,\n RETRACTED = 6,\n EXPIRED = 7,\n WAITING_APPROVAL = 8,\n REJECTED = 9,\n DENIED = 11,\n CLOSED = 12,\n REMOVED = 13,\n}\n\nexport enum SingleTermRequestType {\n Proactive = 'Proactive',\n Credit = 'Credit',\n Rebook = 'Rebook',\n}\n\nexport interface CancellationEventMapped {\n id: number;\n sessionStart: string;\n sessionEnd: string;\n providerId: number;\n clientId: number;\n isComplete: boolean;\n provider: Provider;\n}\n\nexport interface ClientSTBRAvailability {\n canClientBook: boolean;\n forbidReason: string;\n cancellationIds: number[];\n maxNumberOfSessionsCanBooked: number;\n minNumberOfSessionsCanBooked: number;\n extraSessionsNumberToSelect: number;\n osStartDate: string;\n osEndDate: string;\n}\n\nexport enum SINGLE_SESSION_FORBID_REASON {\n clientPaused = 'clientPaused',\n badAuthPeriod = 'badAuthPeriod',\n clientActiveDTAuth = 'clientActiveDTAuth',\n}\n\nexport enum RequestAction {\n Create = 0,\n Accept = 1,\n Decline = 2,\n Confirm = 3,\n Retract = 4,\n Approve = 5,\n Reject = 6,\n Resend = 7,\n UpdateReferenceInfo = 9,\n SetExpirationDate = 10,\n SendSmsNotification = 11,\n SendEmailNotification = 12,\n SendAlertNotification = 13,\n MarkComplete = 14,\n MarkIncomplete = 15,\n Unknown = 16,\n Processed = 17,\n RemindAfterCreation = 18,\n RemindBeforeExpiration = 19,\n RemindBeforeExpirationMultipleRequests = 20,\n MarkExpired = 21,\n MarkExpiredMultiple = 22,\n Respond = 23,\n RetractWithoutNotification = 24,\n MarkSub = 25,\n MarkOff = 26,\n}\n\nexport interface SessionMembersInfo {\n providerId: number;\n provider?: {\n name: string;\n address: { zipCode: string; zipCodeData: ZipCodeData };\n }; // old - BookedProviderName, Provider.zipCodeData\n clientId: number;\n clientName?: string | null;\n zipCode: string;\n zipCodeData?: ZipCodeData;\n driveDistance: number;\n}\n\nexport interface RequestSession extends SessionMembersInfo {\n id: number;\n statusId: RequestStatus;\n createdAt: string;\n sessionStart: string;\n sessionEnd: string;\n duration: number;\n timeBlockIds: string; // opensession\n dayOfWeekId: number; // opensession\n blocks: { id: number; timeBlockId: number; dayOfWeekId: DayOfWeekId }[];\n bookRequestId: number;\n originalSessionId?: number | null;\n relatedSessions: Pick[] | null;\n}\n\nexport interface BookRequestBlock {\n timeBlockDayOfWeekId: number;\n timeBlockDayOfWeek: TimeDayBlock;\n startTime: string;\n duration: number;\n}\n\nexport interface Request extends Partial {\n requester: {\n name: string;\n }; // old - RequestorName\n createdAt: string;\n id: number;\n // RequestStatus: RequestStatuses;\n statusId: RequestStatus; // RequestStatus\n referenceInfo: string;\n isComplete: boolean; // RequestComplete\n status: string;\n expirationDate: string | null;\n logs: RequestActionLog[];\n sessions: RequestSession[];\n userId: number | null;\n user?: User;\n type: string;\n subtype: SingleTermRequestType;\n inCaseTeam: boolean;\n cancellationEvent?: CancellationEventMapped;\n cancellationEvents?: CancellationEventMapped[];\n sessionsAllowed: number | null;\n providerStatuses?: { providerId: number; statusId: number }[];\n originalBookRequestId?: number;\n confirmedSessionsCount?: number;\n claimedSessionsCount?: number;\n blocks: BookRequestBlock[];\n}\n\nexport enum NotificationMethodId {\n SMS = 1,\n Email = 2,\n}\n\nexport interface NotificationCategory {\n id: number;\n atLeastOneIsMandatory: boolean;\n name: string;\n topics?: { id: number; name: string }[];\n}\n\nexport interface NotificationPreference {\n id?: number;\n categoryId: number;\n category?: NotificationCategory;\n methodId: NotificationMethodId;\n method?: { id: number; name: string };\n isEnabled: boolean;\n isEditable?: boolean;\n userId?: number | null;\n providerId?: number | null;\n createdAt?: string;\n}\n\nexport enum SessionStatus {\n Pending = 'pending',\n Accepted = 'accepted',\n Confirmed = 'confirmed',\n Cancelled = 'cancelled',\n TimeOff = 'timeOff',\n Hold = 'hold',\n}\n\nexport enum RemovedBy {\n Admin = 'admin',\n Provider = 'provider',\n Client = 'client',\n}\n\nexport enum RemoveSessionVariant {\n cancellation = 'cancel',\n timeOff = 'timeOff',\n retraction = 'retract',\n}\n\nexport enum UserType {\n Client = 'Client',\n Provider = 'Provider',\n}\n\nexport interface ScheduledSession {\n blocks: { id: number }[];\n segmentId: number;\n id?: number;\n bookRequestType?: RequestType;\n bookRequestId?: number;\n createdAt: string;\n providerId?: number;\n scheduledDate: string;\n segmentStart: string;\n segmentEnd: string;\n segmentStartUtc: string;\n segmentEndUtc: string;\n segmentDuration: number;\n clientId: number;\n validBillable: boolean;\n isCancellableByProvider: boolean;\n isCancellableByClient: boolean;\n isRetractableByClient: boolean;\n isFirstTimeOff?: boolean;\n /** this filed value is set locally (in redux file for client) */\n removeSessionVariant?: RemoveSessionVariant;\n distanceInMiles?: number;\n provider?: Provider;\n client: {\n zipCode: number;\n supervisor?: { name?: string; email?: string };\n zipCodeData?: { latitude?: string; longitude?: string };\n attributes: { locationNotes?: string; reassignAllowed?: boolean };\n payerType?: string;\n };\n clientName?: string;\n cancellationEvent?: {\n id?: number;\n isEligibleForOS?: boolean;\n bookRequestSession?: { id: number };\n };\n status: SessionStatus;\n visibleToClient: boolean;\n overlappingSessions: ScheduledSession[];\n removedBy?: RemovedBy;\n billingCode?: string;\n isBookRequest?: boolean;\n pendingLongTermBookRequestWithZipCode?: boolean;\n locationAddressLine1: string | null;\n locationAddressLine2: string | null;\n locationCity: string | null;\n locationState: string | null;\n locationZip: string | null;\n sessionLogs?: ScheduledSessionLog[];\n isActiveSession: boolean;\n sessionUpdate?: SessionUpdate;\n eventId: number;\n}\n\nexport interface ClientAttributes {\n assignmentApprovalRequired: boolean;\n cantonese: LanguagePreference;\n expectedWeeklyAuth: number | 'NULL';\n hasCat: boolean;\n hasDog: boolean;\n locationAnomaly: boolean;\n mandarin: LanguagePreference;\n overrideCR: boolean;\n overrideReason: string;\n shortSession: boolean;\n spanish: LanguagePreference;\n center: boolean;\n homeSchool: boolean;\n telehealth: boolean;\n restraintTrainingRequired: boolean;\n locationNotes: string;\n telehealthWaiver: boolean;\n pause: boolean;\n suspendedChat: boolean;\n searchForSub: boolean;\n disableAutoOSPostingOnAvailabilityChange: boolean;\n}\n\nexport interface AttendanceStatusThreshold {\n id: number;\n lower: number;\n upper: number;\n status: string;\n type: 'Provider' | 'Client';\n}\n\nexport interface Client {\n id: number;\n payer: string;\n gwClientId: string;\n confirmed: boolean;\n nameChange: boolean;\n crcDateC: string;\n isActive: boolean;\n currentClinicalDirectorId: number;\n zipCode: string;\n clientEmail: string;\n clientCity: string;\n distanceInMiles?: number;\n region: string;\n weeklyAuthSize: number;\n attributes?: ClientAttributes;\n authCurrentMonthBTAdj: number;\n authPriorMonthBTAdj: number;\n hrsWorkedBTCurrentMonth: number;\n hrsWorkedBTPriorMonth: number;\n availability: AvailabilityRecord[];\n schedOccupied?: any[];\n applicableCancelRate: number;\n attendanceStatusId: ClientAttendanceStatusId;\n schedule: ClientSchedule[];\n matchedSchedule?: ClientSchedule[];\n futureBTHrsWorked: number;\n futureBTHrsWorkedCurrMonth: number;\n futureAuthFulfillPercentage?: number;\n termAnnounceDate: string | null;\n isAccelerator?: boolean;\n clientSupervisorNameCurrent: string;\n btAuthFrequency: string;\n clientName: string;\n zipCodeData?: ZipCodeData;\n expectedAuthFulfillment: number;\n timezoneIANA: string;\n ClientDischargeDate: string | null;\n DTDischargeDate: string | null;\n payerType: string;\n}\n\nexport interface Relationship {\n id: number;\n name: string;\n}\n\nexport interface UserAssociation {\n id: number;\n userId: number;\n clientId: number;\n dateAdded: string;\n addedBy: string;\n dateRevoked: string | null;\n revokedBy: string | null;\n dateVerified: string | null;\n verified: boolean;\n relationship?: Relationship | null;\n client?: { name: string };\n}\n\nexport interface AdminActionLog {\n id: number;\n performedBy: string;\n actionDate: string;\n action: {\n name: 'invite' | 'enable' | 'disable';\n };\n}\n\nexport interface AvailabilityRecord {\n ClientId: number;\n dayOfWeekId: number;\n EndDate: string;\n EndTime: string;\n Name: string;\n StartDate: string;\n StartTime: string;\n id: number;\n}\n\nexport interface ClientSchedule {\n timeBlockId: number;\n clientId: number;\n dayOfWeekId: number;\n isAvailable: boolean;\n occupied1: number;\n occupied2: number;\n id: number;\n preferredStartTime: string;\n preferredEndTime: string;\n}\n\nexport interface Goal {\n id: number;\n metDate: string | null;\n name: string;\n}\n\nexport interface ApiPagination {\n page: number;\n limit: number;\n}\n\nexport enum SortingDirection {\n ASC = 'ASC',\n DESC = 'DESC',\n}\n\nexport interface ApiSorting {\n orderBy: T;\n direction: SortingDirection;\n}\n\nexport interface PaginatedData {\n items: T[];\n meta: PaginationDataMeta;\n}\n\nexport interface PaginationDataMeta {\n totalItems: number;\n itemCount: number;\n itemsPerPage: number;\n totalPages: number;\n currentPage: number;\n}\n\nexport interface CancellationEvent {\n id: number;\n clientId: number;\n providerId: number;\n provider?: Provider;\n sessionStart: string;\n createdAt: string;\n atFaultParty: string;\n isLateCancellation: boolean;\n isSameDayCancellation: boolean;\n cancelSubmissionOn: string;\n}\n\nexport enum DayOfWeekId {\n Sunday = 0,\n Monday = 1,\n Tuesday = 2,\n Wednesday = 3,\n Thursday = 4,\n Friday = 5,\n Saturday = 6,\n}\n\nexport enum LanguagePreference {\n None = 'None',\n Preferred = 'Preferred',\n Only = 'Only',\n}\n\nexport interface FetchBookingFilters {\n providerId?: number;\n userId?: number;\n clientId?: number;\n status?: RequestStatus[];\n excludeStatus?: RequestStatus[];\n excludeSessionStatus?: RequestStatus[];\n type?: RequestType[];\n subtype?: SingleTermRequestType[];\n typedStatuses?: TypedStatus[];\n creationDateFrom?: string;\n creationDateTill?: string;\n sessionStartFrom?: string;\n sessionStartTo?: string;\n limit?: number;\n page?: number;\n transformKeys?: boolean;\n}\n\nexport interface TypedStatus {\n type: RequestType;\n statuses?: RequestStatus[];\n excludeStatuses?: RequestStatus[];\n hasOriginalBookRequestId?: boolean;\n}\n\nexport type CancelledSegmentsResponseType = {\n segmentId: number;\n isRTO: boolean;\n cancellationEventId: number;\n removedBy: RemovedBy;\n};\n\nexport type RetractedSessionsResponseType = {\n id: number;\n sessions: Array<{ id: number; statusId: RequestStatus }>;\n};\n\nexport interface CancellationEventsFilters {\n providerId: number;\n clientId: number;\n atFaultParty: AtFaultParty;\n createdFrom: string;\n providerTitles: string[];\n isRetracted: boolean;\n isPaid?: boolean;\n}\n\nexport enum CancellationEventsSort {\n SessionStart = 'sessionStart',\n CreatedAt = 'createdAt',\n}\nexport interface Notification {\n id: number;\n message: string;\n isSeen: boolean;\n createdAt: string;\n}\nexport interface NotificationPaginatedData {\n items: Notification[];\n meta: {\n currentPage: number;\n itemCount: number;\n itemsPerPage: number;\n totalItems: number;\n totalPages: number;\n };\n}\n\nexport enum NotificationTab {\n all = 'all',\n unread = 'unread',\n read = 'read',\n}\n\nexport enum RequestsTab {\n Requests = 'My Requests',\n OpenSessions = 'OpenSessions',\n}\n\nexport enum JiraTicketTypeId {\n ChangingAvailability = 1,\n ChangeSessionLocation = 2,\n OneTimeChangetoaSession = 3,\n PermanentChangetomySchedule = 4,\n CarePortalOrAppSupport = 5,\n InsuranceSwitch = 6,\n Other = 7,\n}\n\nexport interface JiraTicketType {\n id: JiraTicketTypeId;\n name: string;\n}\n\nexport interface Week {\n start: string;\n end: string;\n}\n\nexport type OpenSessionBookRequest = Request & {\n week: Week;\n client: Client;\n driveTime?: google.maps.DistanceMatrixResponseElement;\n openSessionBlocks: BlockCoords[];\n};\n\nexport interface Language {\n id: number;\n name: string;\n}\n\nexport interface BlockCoords {\n dayOfWeekId: DayOfWeekId;\n timeBlockId: number;\n}\n\nexport interface State {\n name: string;\n abbreviation: string;\n}\n\nexport enum RequestType {\n AllRequests = 'all',\n LongTerm = 'LongTermBookRequest',\n SingleTerm = 'SingleTermBookRequest',\n OpenSession = 'OpenSessionBookRequest',\n SubOffer = 'SubOfferBookRequest',\n}\n\nexport type CheckedSessions = { [sessionId: number]: boolean };\n\nexport interface StatusInfo {\n readonly title: string;\n readonly color: string;\n}\n\nexport type StatusesInfo = {\n [status in RequestStatus]?: ((request: Request) => StatusInfo) | StatusInfo;\n};\n\nexport type MainRequestTypes = Exclude;\n\nexport type NoticeRequestType = 'cc_expiration' | 'cc_declined' | 'cc_missing';\n\nexport type Notice = {\n requestType: NoticeRequestType;\n token: string;\n};\n\nexport enum SingleBookingAvailabilityType {\n AllClients = 'All Clients',\n LTClientsOnly = 'LT Clients Only',\n NoSTBookings = 'No Short Term Bookings',\n}\n\nexport interface FeedbackTag {\n id: number;\n name: string;\n conflictingTagIds: Array | null;\n}\n\nexport interface UnratedSession {\n clientId: number;\n providerId: number;\n segmentId: number;\n segmentEndUtc: string;\n segmentStartUtc: string;\n profilePhoto: string;\n firstName: string;\n lastName: string;\n}\n\nexport enum ClimbLevels {\n builder = 1,\n maker = 2,\n achiever = 3,\n leader = 4,\n}\n\nexport interface InvoiceLog {\n id: number;\n invoiceId: number;\n action: string;\n params: { [key: string]: any } | null;\n createdAt: string;\n createdById: string;\n createdByName: string;\n updatedAt: string;\n}\n\nexport interface Invoice {\n id: number;\n clientId: number;\n note: string;\n removedById: number | null;\n removedByName: string | null;\n logs: InvoiceLog[];\n status: InvoiceStatus;\n}\n\nexport enum InvoiceStatus {\n Paid = 'paid',\n Retracted = 'retracted',\n Scheduled = 'scheduled',\n Review = 'review',\n}\n\nexport enum ClientInvoiceStatus {\n Paid = 'Paid',\n PaymentScheduled = 'Payment Scheduled',\n ClientQuestion = 'Client Question',\n}\n\nexport type DecimalNumber = {\n s: 1 | -1; // sign\n e: number; // exponent\n d: number[]; // digits\n};\n\nexport enum JiraTicketTypeCategory {\n SCHEDULING = 'scheduling',\n BILLING = 'billing',\n}\n\nexport enum ScheduledSessionsLogActionIds {\n ClientReportNotHere = 1,\n ProviderReportNotHere = 2,\n ClientReportStillNotHere = 3,\n ProviderReportStillNotHere = 4,\n ClientReportArrived = 5,\n ProviderReportArrived = 6,\n}\n\nexport type ScheduledSessionLog = {\n id: number;\n actionId: ScheduledSessionsLogActionIds;\n segmentId: number;\n clientId: number;\n providerId: number;\n userId: number | null;\n requesterId: number | null;\n sessionStartUtc: Date;\n createdAt: Date;\n};\n\nexport enum GeolocationPromptAction {\n ShowWarning = 'ShowWarning',\n}\n\nexport enum NoShowParticipant {\n Client = 'Client',\n DistrictClient = 'DistrictClient',\n Provider = 'Provider',\n}\n\nexport enum LocalStorageKeys {\n LAST_ACTIVITY_KEY = 'lastActivity',\n LAST_LOGGED_IN_USER_TYPE = 'lastLoggedInUserType',\n PREFERRED_VIEW_MODE_STORAGE_KEY = 'my-schedule-preferred-view-mode',\n}\n","import React from 'react';\nimport { Avatar, Box, Typography, makeStyles, Theme } from '@material-ui/core';\nimport { AvatarGroup } from '@material-ui/lab';\nimport { Provider } from '../../types/types';\n\nconst useStyles = makeStyles((theme: Theme) => ({\n providerCell: {\n display: 'flex',\n alignItems: 'center',\n },\n avatar: {\n marginTop: theme.spacing(0.5),\n marginRight: theme.spacing(1),\n },\n}));\n\ninterface OverlappingProvidersCellProps {\n providers: Pick<\n Provider,\n 'firstName' | 'lastName' | 'profilePhoto' | 'covidVaccinatedDate' | 'title'\n >[];\n showCount?: boolean;\n}\n\nconst OverlappingProvidersCell = ({\n providers,\n showCount = true,\n}: OverlappingProvidersCellProps) => {\n const classes = useStyles();\n return (\n \n \n {providers.map((p, i) => {\n return (\n \n );\n })}\n \n {showCount && (\n \n {providers.length} providers \n \n )}\n \n );\n};\n\nexport default OverlappingProvidersCell;\n","import React from 'react';\nimport { Typography } from '@material-ui/core';\nimport {\n RemovedBy,\n RequestType,\n ScheduledSession,\n SessionStatus,\n UserType,\n} from '../../../../types/types';\nimport { getStatusColors } from '../../utils/statusHelpers';\nimport {\n acceptedStatusInfo,\n confirmedStatusInfo,\n getSessionStatus,\n holdStatusInfo,\n pendingOsStatusInfo,\n pendingSearchingForSubStatusInfo,\n pendingStatusInfo,\n} from '../../../../utils/StatusInfo';\n\ntype Props = {\n session: ScheduledSession;\n userType: UserType;\n fontSize?: number | string;\n className?: string;\n};\n\ntype GetSessionStatusTextProps = {\n sessionStatus: SessionStatus;\n removedBy?: RemovedBy;\n isRemovedByYou?: boolean;\n requestType?: RequestType;\n isBookRequest?: boolean;\n hasCancellationEvent?: boolean;\n};\n\nconst getSessionStatusText = ({\n sessionStatus,\n removedBy,\n isRemovedByYou,\n requestType,\n isBookRequest,\n hasCancellationEvent,\n}: GetSessionStatusTextProps) => {\n const getPendingOsTitle = () => {\n return hasCancellationEvent\n ? pendingSearchingForSubStatusInfo.title\n : pendingOsStatusInfo.title;\n };\n\n switch (sessionStatus) {\n case SessionStatus.Confirmed:\n return confirmedStatusInfo.title;\n case SessionStatus.Pending:\n return requestType === RequestType.OpenSession\n ? getPendingOsTitle()\n : pendingStatusInfo.title;\n case SessionStatus.Accepted:\n return acceptedStatusInfo.title;\n case SessionStatus.Cancelled:\n if (isBookRequest) {\n return 'Retracted';\n }\n if (isRemovedByYou) {\n return 'Cancelled by you';\n }\n if (removedBy) {\n return `Removed by ${removedBy}`;\n }\n return '';\n case SessionStatus.TimeOff:\n if (isRemovedByYou) {\n return 'Time Off requested by you';\n }\n if (removedBy) {\n return `Removed by ${removedBy}`;\n }\n return '';\n case SessionStatus.Hold:\n return holdStatusInfo.title;\n default:\n return confirmedStatusInfo.title;\n }\n};\n\nconst SessionStatusText = ({\n session,\n userType,\n fontSize,\n className,\n}: Props) => {\n const sessionStatus = getSessionStatus(session);\n const colors = getStatusColors(session);\n\n return (\n \n {getSessionStatusText({\n sessionStatus,\n removedBy: session.removedBy,\n requestType: session.bookRequestType,\n isBookRequest: session.isBookRequest,\n isRemovedByYou:\n [SessionStatus.Cancelled, SessionStatus.TimeOff].includes(\n sessionStatus\n ) &&\n (userType === UserType.Client\n ? session.removedBy === RemovedBy.Client\n : session.removedBy === RemovedBy.Provider),\n hasCancellationEvent: !!session.cancellationEvent,\n })}\n \n );\n};\n\nexport default SessionStatusText;\n","module.exports = __webpack_public_path__ + \"static/media/search-for-sub-title-icon.80ae039d.svg\";","import { FetchJiraTicketTypeFilters } from '../redux/modules/jira';\nimport { JiraTicketType } from '../types/types';\nimport requester from './requester';\n\nconst fetchJiraTicketTypes = async (\n filters: FetchJiraTicketTypeFilters\n): Promise => {\n const queryParams = new URLSearchParams();\n const { category } = filters;\n\n if (category) {\n queryParams.append('category', category);\n }\n\n const url = `jira-ticket-types?${queryParams}`;\n\n return requester\n .get(url)\n .then((response) => response.json())\n .then((response) => response?.data);\n};\n\nexport default { fetchJiraTicketTypes };\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport jiraApi from '../../api/jiraApi';\nimport { JiraTicketTypeCategory, JiraTicketType } from '../../types/types';\n\nexport interface JiraState {\n loadingJiraTicketTypes: boolean;\n jiraTicketTypes: JiraTicketType[];\n}\nexport interface FetchJiraTicketTypeFilters {\n category?: JiraTicketTypeCategory;\n}\n\nconst initialState: JiraState = {\n loadingJiraTicketTypes: false,\n jiraTicketTypes: [],\n};\n\nexport const fetchJiraTicketTypes = createAsyncThunk(\n 'jira/fetchJiraTicketTypes',\n async (filters: FetchJiraTicketTypeFilters) => {\n return jiraApi.fetchJiraTicketTypes(filters);\n }\n);\n\nconst jiraSlice = createSlice({\n name: 'jira',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchJiraTicketTypes.pending, (state) => {\n state.loadingJiraTicketTypes = true;\n })\n .addCase(fetchJiraTicketTypes.fulfilled, (state, action) => {\n state.jiraTicketTypes = action.payload;\n state.loadingJiraTicketTypes = false;\n })\n .addCase(fetchJiraTicketTypes.rejected, (state) => {\n state.loadingJiraTicketTypes = false;\n });\n },\n});\n\nexport default jiraSlice.reducer;\n","import requester from './requester';\n\nexport interface HelpRequestBody {\n helpWith: number | '';\n relatedToSchedule: boolean;\n details: string;\n clientId: number;\n}\n\nconst createHelpRequest = async (body: HelpRequestBody) => {\n return requester\n .post('help-requests', {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({\n ...body,\n jiraTicketTypeId: body.helpWith,\n helpWith: undefined,\n }),\n })\n .then((response) => response.json())\n .then((response) => response?.data);\n};\n\nexport default { createHelpRequest };\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport helpApi, { HelpRequestBody } from '../../api/helpApi';\nimport { RootState } from './rootReducer';\n\nexport interface HelpState {\n creatingHelpRequest: boolean;\n creatingHelpRequestSucceed: boolean;\n}\n\nconst initialState: HelpState = {\n creatingHelpRequest: false,\n creatingHelpRequestSucceed: false,\n};\n\nexport const createHelpRequest = createAsyncThunk<\n void,\n Omit,\n { state: RootState }\n>('help/createHelpRequest', async (data, thunkApi) => {\n const clientId = thunkApi.getState().client.currentClient?.id;\n\n if (clientId) {\n return helpApi.createHelpRequest({ ...data, clientId });\n }\n return undefined;\n});\n\nconst helpSlice = createSlice({\n name: 'help',\n initialState,\n reducers: {\n resetHelpRequestState: (state) => {\n state.creatingHelpRequest = false;\n state.creatingHelpRequestSucceed = false;\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(createHelpRequest.pending, (state) => {\n state.creatingHelpRequest = true;\n state.creatingHelpRequestSucceed = false;\n })\n .addCase(createHelpRequest.fulfilled, (state) => {\n state.creatingHelpRequest = false;\n state.creatingHelpRequestSucceed = true;\n })\n .addCase(createHelpRequest.rejected, (state) => {\n state.creatingHelpRequest = false;\n });\n },\n});\n\nexport const { resetHelpRequestState } = helpSlice.actions;\n\nexport default helpSlice.reducer;\n","import { State } from '../types/types';\nimport requester from './requester';\n\nconst fetchStates = async (): Promise => {\n return requester\n .get('states')\n .then((response) => response.json())\n .then((response) => response?.data);\n};\n\nexport default { fetchStates };\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport stateApi from '../../api/statesApi';\nimport { State } from '../../types/types';\n\nexport interface StatesState {\n loadingStates: boolean;\n states: State[];\n}\n\nconst initialState: StatesState = {\n loadingStates: false,\n states: [],\n};\n\nexport const fetchStates = createAsyncThunk('states/fetchStates', async () => {\n return stateApi.fetchStates();\n});\n\nconst statesSlice = createSlice({\n name: 'states',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchStates.pending, (state) => {\n state.loadingStates = true;\n })\n .addCase(fetchStates.fulfilled, (state, action) => {\n state.states = action.payload;\n state.loadingStates = false;\n })\n .addCase(fetchStates.rejected, (state) => {\n state.loadingStates = false;\n });\n },\n});\n\nexport default statesSlice.reducer;\n","import requester from './requester';\n\nconst fetchNotice = ({ clientId }: { clientId: number }): Promise => {\n return requester\n .get(`revenue-requests/notices/${clientId}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default { fetchNotice };\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport jwtDecode from 'jwt-decode';\n\nimport noticesApi from '../../api/noticesApi';\nimport { Notice, NoticeRequestType } from '../../types/types';\n\nexport type NoticesState = {\n notice: Notice | null;\n noticeLoading: boolean;\n};\n\nconst initialState: NoticesState = {\n notice: null,\n noticeLoading: false,\n};\n\nexport const fetchNotice = createAsyncThunk(\n 'notices/fetchNotices',\n (args: { clientId: number }) => {\n const { clientId } = args;\n return noticesApi.fetchNotice({ clientId });\n }\n);\n\nconst noticesSlice = createSlice({\n name: 'notices',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchNotice.fulfilled, (state, action) => {\n const token = action.payload;\n\n state.noticeLoading = false;\n\n if (!token) {\n state.notice = null;\n } else {\n const { requestType }: { requestType: NoticeRequestType } = jwtDecode(\n token\n );\n\n state.notice = { requestType, token };\n }\n })\n .addCase(fetchNotice.rejected, (state) => {\n state.noticeLoading = false;\n state.notice = null;\n })\n .addCase(fetchNotice.pending, (state) => {\n state.noticeLoading = true;\n });\n },\n});\n\nexport default noticesSlice.reducer;\n","import { FeedbackTag } from '../types/types';\nimport requester from './requester';\n\nconst fetchFeedbackTags = async (): Promise => {\n return requester\n .get('feedback-tags')\n .then((response) => response.json())\n .then((response) => response?.data);\n};\n\nexport default { fetchFeedbackTags };\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport { FeedbackTag } from '../../types/types';\nimport feedbackTagsApi from '../../api/feedbackTagsApi';\n\nexport interface StatesState {\n loadingFeedbackTags: boolean;\n feedbackTags: FeedbackTag[];\n}\n\nconst initialState: StatesState = {\n loadingFeedbackTags: false,\n feedbackTags: [],\n};\n\nexport const fetchFeedbackTags = createAsyncThunk(\n 'feedbackTags/fetchFeedbackTags',\n async () => {\n return feedbackTagsApi.fetchFeedbackTags();\n }\n);\n\nconst statesSlice = createSlice({\n name: 'feedbackTags',\n initialState,\n reducers: {},\n extraReducers: (builder) => {\n builder\n .addCase(fetchFeedbackTags.pending, (state) => {\n state.loadingFeedbackTags = true;\n })\n .addCase(fetchFeedbackTags.fulfilled, (state, action) => {\n state.feedbackTags = action.payload;\n state.loadingFeedbackTags = false;\n })\n .addCase(fetchFeedbackTags.rejected, (state) => {\n state.loadingFeedbackTags = false;\n });\n },\n});\n\nexport default statesSlice.reducer;\n","import requester from './requester';\n\nexport interface CreateRatingDto {\n clientId: number;\n providerId: number;\n segmentId: number;\n value: number;\n feedbackTagIds: number[];\n}\n\nconst createRating = async (ratingDto: CreateRatingDto) => {\n return requester\n .post(`ratings`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(ratingDto),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default {\n createRating,\n};\n","import { createAsyncThunk, createSlice } from '@reduxjs/toolkit';\nimport ratingsApi, { CreateRatingDto } from '../../api/ratingsApi';\n\nexport interface StatesState {\n creating: boolean;\n success: boolean;\n}\n\nconst initialState: StatesState = {\n creating: false,\n success: false,\n};\n\nexport const createRating = createAsyncThunk(\n 'ratings/createRating',\n (payload: CreateRatingDto, { rejectWithValue }) =>\n ratingsApi\n .createRating(payload)\n .catch((e) => rejectWithValue('Creating rating fails'))\n);\n\nconst statesSlice = createSlice({\n name: 'ratings',\n initialState,\n reducers: {\n resetState: (state) => {\n return initialState;\n },\n },\n extraReducers: (builder) => {\n builder\n .addCase(createRating.pending, (state) => {\n state.creating = true;\n state.success = false;\n })\n .addCase(createRating.fulfilled, (state, action) => {\n state.creating = false;\n state.success = true;\n })\n .addCase(createRating.rejected, (state) => {\n state.creating = false;\n state.success = false;\n });\n },\n});\n\nexport const { resetState } = statesSlice.actions;\n\nexport default statesSlice.reducer;\n","module.exports = __webpack_public_path__ + \"static/media/warning-diamond-icon.efd36877.svg\";","module.exports = __webpack_public_path__ + \"static/media/booked.8d80f2a3.svg\";","module.exports = __webpack_public_path__ + \"static/media/longTermType.e2e478c6.svg\";","module.exports = __webpack_public_path__ + \"static/media/time.9a83fbe2.svg\";","module.exports = __webpack_public_path__ + \"static/media/date.4cc9c22a.svg\";","module.exports = __webpack_public_path__ + \"static/media/bookedWith.e60dae8d.svg\";","import queryString from 'query-string';\n\nimport {\n NotificationPreference,\n Provider,\n ProviderAddress,\n ProviderAttendanceAwards,\n ProviderAttendanceAwardVisibilityStatus,\n ProviderAttributes,\n ProviderLevel,\n ProviderWithBookDetails,\n ProviderWithMentees,\n SingleSessionProviderFilters,\n} from '../types/types';\nimport requester from './requester';\n\nconst fetchCurrentProvider = async (): Promise => {\n return requester\n .get(`v2/providers/me`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchProviderAttributes = async (\n providerId: number\n): Promise => {\n const url = `providers/${providerId}/attributes`;\n\n return requester\n .get(url)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst updateProviderAttributes = async (\n providerId: number,\n newAttributes: Partial\n): Promise => {\n const url = `providers/${providerId}/attributes`;\n\n return requester\n .post(url, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ newAttributes }),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchSwapProviders = async (\n subjectProviderId: number,\n radius: string\n) => {\n const query = queryString.stringify({ radius });\n return requester\n .get(`providers/${subjectProviderId}/swaps?${query}`)\n .then((response) => response.json());\n};\n\nconst fetchProviderNotificationPreferences = async (\n providerId: number\n): Promise => {\n return requester\n .get(`notificationPreferences/provider/${providerId}`)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst replaceProviderNotificationPreferences = async (\n notificationPreferences: NotificationPreference[],\n providerId: number\n): Promise => {\n return requester\n .put(`notificationPreferences/provider/${providerId}`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ notificationPreferences }),\n })\n .then((response) => response.json());\n};\n\nconst updateProviderAttendanceAward = async (\n awardId: number\n): Promise => {\n return requester\n .put(`provider-attendance-awards/${awardId}`, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ isSeen: true }),\n })\n .then((response) => response.json())\n .then((res) => res.data);\n};\n\n// TODO move from here\nconst fetchProvidersForSingleBook = async (\n clientId: number,\n filters: SingleSessionProviderFilters = {},\n signal?: AbortSignal\n): Promise => {\n const query = queryString.stringify({\n ...filters,\n clientId,\n });\n const url = `short-term-book-request/user-api/clients/${clientId}?${query}`;\n return requester\n .get(url, { signal })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchMenteeProviders = async (\n providerId: number\n): Promise> => {\n const query = queryString.stringify({\n mentorId: providerId,\n includeSchedule: true,\n includeCalculations: true,\n includeStats: true,\n includeLevel: true,\n });\n\n const url = `providers?${query}`;\n\n return requester\n .get(url)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchProviderById = (providerId: number): Promise =>\n requester\n .get(`providers/${providerId}`)\n .then((response) => response.json())\n .then((response) => response.data);\n\nconst fetchRelatedClientIds = async (providerId: number) => {\n const url = `providers/${providerId}/related-clients`;\n\n return requester.get(url).then((response) => {\n if (!response.ok) {\n throw new Error(response.statusText);\n }\n return response.json() as Promise<{ data: number[] }>;\n });\n};\n\nconst updateProviderAddress = async (\n providerId: number,\n providerAddress: ProviderAddress\n) => {\n const { zip, city, state, street } = providerAddress;\n\n const url = `v2/providers/${providerId}/address`;\n\n return requester\n .put(url, {\n headers: { 'Content-Type': 'application/json' },\n body: JSON.stringify({ zip, city, state, street }),\n })\n .then((response) => response.json() as Promise<{ data: ProviderAddress }>)\n .then((res) => res.data);\n};\n\nconst fetchProviderProjectedLevel = async (\n providerId: number\n): Promise => {\n const url = `v2/providers/${providerId}/projected-level`;\n\n return requester\n .get(url)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchProviderAttendanceAwards = async (\n providerId: number\n): Promise => {\n const url = `provider-attendance-awards/${providerId}`;\n\n return requester\n .get(url)\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nconst fetchProviderKyoClimbSettings = async (providerId: number) => {\n const url = `settings/kyo-climb-settings/providers/${providerId}`;\n return requester.get(url).then((response) => response.json());\n};\n\nexport default {\n fetchCurrentProvider,\n fetchProviderAttributes,\n updateProviderAttributes,\n fetchSwapProviders,\n fetchProviderNotificationPreferences,\n replaceProviderNotificationPreferences,\n updateProviderAttendanceAward,\n fetchProvidersForSingleBook,\n fetchMenteeProviders,\n fetchProviderById,\n fetchRelatedClientIds,\n updateProviderAddress,\n fetchProviderProjectedLevel,\n fetchProviderAttendanceAwards,\n fetchProviderKyoClimbSettings,\n};\n","module.exports = __webpack_public_path__ + \"static/media/maintenance-icon.82472428.svg\";","module.exports = __webpack_public_path__ + \"static/media/Kyo-care-logo.e7049a2a.svg\";","module.exports = __webpack_public_path__ + \"static/media/kyo_rectangles.6a37f440.svg\";","import { useRef, useEffect } from 'react';\nimport useAnalyticsData from './useAnalyticsData';\nimport { storeAnalytics } from '../api/analyticsApi';\n\ntype Props = {\n name: TrackerNames;\n delay?: number; // milliseconds\n};\n\nconst AnalyticsTracker = (props: Props) => {\n const { name, delay = 0 } = props;\n const ref = useRef({ tracked: false });\n\n const data = useAnalyticsData();\n\n useEffect(() => {\n const trackedState = ref.current;\n const { isReady, selectedClientId, providerId } = data;\n let timer: NodeJS.Timeout;\n\n if (!trackedState.tracked && isReady) {\n trackedState.tracked = true;\n\n timer = setTimeout(() => {\n storeAnalytics({\n visitedPage: name,\n clientId: selectedClientId,\n providerId,\n }).catch((e) => {\n console.error(e);\n });\n }, delay);\n }\n\n return () => {\n if (timer) {\n clearTimeout(timer);\n }\n trackedState.tracked = false;\n };\n }, [name, data, delay]);\n\n return null;\n};\n\nexport enum TrackerNames {\n Home = 'Home',\n MyScheduleViewSessions = 'MySchedule/ViewSessions',\n MyScheduleRemoveSessions = 'MySchedule/RemoveSessions',\n MyScheduleShortTermAvailability = 'MySchedule/ShortTermAvailability',\n MyScheduleStandardAvailability = 'MySchedule/StandardAvailability',\n AddSessionsSelectProvider = 'AddSessions/SelectProvider',\n AddSessionsSelectTime = 'AddSessions/SelectTime',\n AddSessionsResultScreen = 'AddSessions/ResultScreen',\n AddSessionsTryLater = 'AddSessions/TryLater',\n Availability = 'Availability',\n TeamChat = 'TeamChat',\n Alerts = 'Alerts',\n MyRequests = 'MyRequests',\n Settings = 'Settings',\n ContactUs = 'ContactUs',\n Help = 'Help',\n MyProfile = 'MyProfile',\n MyUserProfile = 'MyUserProfile',\n KyoClimb = 'KyoClimb',\n MenteeList = 'MenteeList',\n MenteeProfile = 'MenteeProfile',\n OpenSessions = 'OpenSessions',\n Billing = 'Billing',\n}\n\nexport default AnalyticsTracker;\n","import { useMemo } from 'react';\nimport { useAppSelector } from '../redux/store';\n\ninterface AnalyticsData {\n isReady: boolean;\n selectedClientId: number | null;\n providerId: number | null;\n}\n\nconst useAnalyticsData = (): AnalyticsData => {\n // provides data needed for every analytics request\n\n const selectedClientId = useAppSelector(\n (state) => state.client.currentClient?.id\n );\n const providerId = useAppSelector((state) => state.provider.provider?.id);\n\n const isReady = !!selectedClientId || !!providerId;\n\n const data = useMemo(\n () => ({\n isReady,\n selectedClientId: selectedClientId || null,\n providerId: providerId || null,\n }),\n [selectedClientId, providerId, isReady]\n );\n\n return data;\n};\n\nexport default useAnalyticsData;\n","import { TrackerNames } from '../analytics/AnalyticsTracker';\nimport requester from './requester';\n\ninterface AnalyticsApiParams {\n clientId: number | null;\n providerId: number | null;\n visitedPage: TrackerNames;\n}\n\nexport const storeAnalytics = (params: AnalyticsApiParams) => {\n return requester\n .post(`analytics`, {\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(params),\n })\n .then((response) => response.json())\n .then((response) => response.data);\n};\n\nexport default storeAnalytics;\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(\"g\", {\n clipPath: \"url(#clip0_27109_248307)\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n x: 7,\n y: 13,\n width: 23,\n height: 15,\n fill: \"white\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M35 19C35 27.8383 27.8383 35 19 35C10.1617 35 3 27.8383 3 19C3 10.1617 10.1617 3 19 3C27.8383 3 35 10.1617 35 19ZM27.518 21.5824C27.9434 21.5824 28.2937 21.2321 28.2937 20.8067V17.1933C28.2937 16.7679 27.9434 16.4176 27.518 16.4176H10.482C10.0566 16.4176 9.70629 16.7679 9.70629 17.1933V20.8067C9.70629 21.2321 10.0566 21.5824 10.482 21.5824H27.513H27.518Z\",\n fill: \"#797F84\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M19 36.5C28.6667 36.5 36.5 28.6667 36.5 19C36.5 9.33329 28.6667 1.5 19 1.5C9.33329 1.5 1.5 9.33329 1.5 19C1.5 28.6667 9.33329 36.5 19 36.5ZM27.518 20.0824H27.513C27.5146 20.0824 27.5163 20.0824 27.518 20.0824ZM26.7937 20.0824H11.2063V17.9176H26.7937V20.0824Z\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_27109_248307\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 38,\n height: 38,\n fill: \"white\"\n})));\n\nvar SvgRemoveIcon = function SvgRemoveIcon(_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: 38,\n height: 38,\n viewBox: \"0 0 38 38\",\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(SvgRemoveIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/remove_icon.7996c1fd.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(\"g\", {\n clipPath: \"url(#clip0_27109_248295)\"\n}, /*#__PURE__*/React.createElement(\"circle\", {\n cx: 19,\n cy: 19,\n r: 14,\n fill: \"white\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M35 19.0023C35 27.843 27.8384 35.0046 18.9977 35.0046C10.157 35.0046 3 27.8384 3 19.0023C3 10.1662 10.1616 3 19.0023 3C27.843 3 35.0046 10.1616 35.0046 19.0023H35ZM23.769 25.4206L25.5904 22.9157C25.8427 22.567 25.7693 22.0853 25.4206 21.833L21.3237 18.8509V9.96889C21.3237 9.54222 20.9751 9.19355 20.5484 9.19355H17.4516C17.0249 9.19355 16.6763 9.54222 16.6763 9.96889V20.8282C16.6763 21.0714 16.791 21.3054 16.9928 21.4522L22.6817 25.5858C23.0304 25.8381 23.5121 25.7601 23.7644 25.4161L23.769 25.4206Z\",\n fill: \"#F2B05C\"\n}), /*#__PURE__*/React.createElement(\"path\", {\n d: \"M36.4367 20.5023H36.5046V19.0023C36.5046 9.33315 28.6714 1.5 19.0023 1.5C9.33287 1.5 1.5 9.33802 1.5 19.0023C1.5 28.666 9.32772 36.5046 18.9977 36.5046C28.1616 36.5046 35.6763 29.4688 36.4367 20.5023ZM23.4855 23.2599L22.9804 23.9487L18.1763 20.4579V10.6935H19.8237V18.8509V19.6144L20.441 20.0636L23.9516 22.6189L23.4855 23.2599Z\"\n}));\n\nvar _ref3 = /*#__PURE__*/React.createElement(\"defs\", null, /*#__PURE__*/React.createElement(\"clipPath\", {\n id: \"clip0_27109_248295\"\n}, /*#__PURE__*/React.createElement(\"rect\", {\n width: 39,\n height: 39,\n fill: \"white\"\n})));\n\nvar SvgPendingIcon = function SvgPendingIcon(_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: 39,\n height: 39,\n viewBox: \"0 0 39 39\",\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(SvgPendingIcon, _extends({\n svgRef: ref\n }, props));\n});\nexport default __webpack_public_path__ + \"static/media/pending_icon.a94b9200.svg\";\nexport { ForwardRef as ReactComponent };","import { uniqBy } from 'lodash';\nimport moment from 'moment';\n\nimport themeWithOverrides from '../../../theme/theme';\nimport { getSessionStatus } from '../../../utils/StatusInfo';\n\nimport { ReactComponent as RemoveIcon } from '../../../assets/remove_icon.svg';\nimport { ReactComponent as ConfirmIcon } from '../../../assets/confirm_icon.svg';\nimport { ReactComponent as PendingIcon } from '../../../assets/pending_icon.svg';\n\nimport {\n Provider,\n RemoveSessionVariant,\n ScheduledSession,\n SessionStatus,\n} from '../../../types/types';\n\nexport const statusColors = {\n confirmed: {\n main: themeWithOverrides.palette.kyoPastelGreen.main,\n background: {\n bigGrid: '#E2F6E9',\n smallGrid: 'rgba(58, 212, 73, 0.30)',\n },\n },\n cancelled: {\n main: themeWithOverrides.palette.kyoGray3.main,\n background: {\n bigGrid: themeWithOverrides.palette.kyoGray.main,\n smallGrid: themeWithOverrides.palette.kyoGray2.dark,\n },\n },\n pending: {\n main: themeWithOverrides.palette.kyoBurntOrange.main,\n background: {\n bigGrid: '#F6F0E2',\n smallGrid: 'rgba(242, 176, 92, 0.40)',\n },\n },\n available: {\n main: '',\n background: {\n bigGrid: '#5096F1',\n smallGrid: '#5096F1',\n },\n },\n};\n\nconst simplifyStatus = (session: ScheduledSession) => {\n const sessionStatus = getSessionStatus(session);\n switch (sessionStatus) {\n case SessionStatus.Cancelled:\n case SessionStatus.TimeOff: {\n return SessionStatus.Cancelled;\n }\n case SessionStatus.Confirmed: {\n return SessionStatus.Confirmed;\n }\n default: {\n return SessionStatus.Pending;\n }\n }\n};\n\nexport const getStatusColors = (session: ScheduledSession) => {\n const formattedStatus = simplifyStatus(session);\n\n return formattedStatus && statusColors[formattedStatus];\n};\n\nconst iconByStatus = {\n [SessionStatus.Cancelled]: RemoveIcon,\n [SessionStatus.Pending]: PendingIcon,\n [SessionStatus.Confirmed]: ConfirmIcon,\n};\n\nexport const getIconForStatus = (session: ScheduledSession) => {\n const formattedStatus = simplifyStatus(session);\n return iconByStatus[formattedStatus];\n};\n\nexport const getProviderSessionsInfo = (scheduleSegment: ScheduledSession) => {\n const { overlappingSessions = [], provider, status } = scheduleSegment;\n\n const providers = [provider];\n const sessionsStatus = provider ? { [provider.id]: status } : {};\n\n if (overlappingSessions?.length > 0) {\n overlappingSessions.forEach((os) => {\n providers.push(os.provider);\n if (!os.provider) {\n return;\n }\n\n sessionsStatus[os.provider.id] = os.status;\n });\n }\n\n const uniqProviders = uniqBy(\n providers.filter(Boolean) as Array,\n (p) => p.id\n );\n\n const sessionIsWith = !uniqProviders.length\n ? ''\n : `with ${\n uniqProviders.length === 1\n ? uniqProviders[0].firstName\n : `${uniqProviders.length} providers`\n }`;\n\n return { sessionIsWith, sessionsStatus, providers: uniqProviders };\n};\n\nexport const excludeRemovedSessions = (sessions: ScheduledSession[]) => {\n return (\n sessions?.filter((s) => {\n return ![SessionStatus.Cancelled, SessionStatus.TimeOff].includes(\n s.status\n );\n }) || []\n );\n};\n\nexport const getRemoveSessionVariant = (session: ScheduledSession) => {\n let removeSessionVariant;\n\n if (session.isBookRequest) {\n removeSessionVariant = RemoveSessionVariant.retraction;\n } else if (\n moment(session.segmentStartUtc).isAfter(moment.utc().add(2, 'weeks'))\n ) {\n removeSessionVariant = RemoveSessionVariant.timeOff;\n } else {\n removeSessionVariant = RemoveSessionVariant.cancellation;\n }\n\n return removeSessionVariant;\n};\n","import { createAsyncThunk, createSlice, PayloadAction } from '@reduxjs/toolkit';\nimport moment from 'moment';\nimport clientApi from '../../api/clientApi';\nimport { clearSearchResult } from './action';\nimport { fetchCurrentUser } from './users';\nimport * as SessionRemovalModule from './sessionRemoval';\nimport {\n Client,\n ClientAttributes,\n Goal,\n Provider,\n ScheduledSession,\n} from '../../types/types';\nimport { getFirstSessionAfter } from '../../utils/helpers';\nimport { TWO_WEEKS } from '../../utils/constants';\nimport { getRemoveSessionVariant } from '../../commonPages/MySchedule/utils/statusHelpers';\nimport scheduleApi from '../../api/scheduleApi';\n\nexport interface ClientState {\n caseTeam: Provider[] | null;\n caseTeamLoading: boolean;\n clientFullSchedule: ScheduledSession[] | null;\n clientFullScheduleLoading: boolean;\n clientFullScheduleRequestId: string | undefined;\n currentClient: Client | null;\n currentClientLoading: boolean;\n goals: Goal[];\n goalsLoading: boolean;\n updatingClientAttributes: boolean;\n}\n\nconst initialState: ClientState = {\n caseTeam: null,\n caseTeamLoading: false,\n clientFullSchedule: null,\n clientFullScheduleLoading: false,\n clientFullScheduleRequestId: undefined,\n currentClient: null,\n currentClientLoading: false,\n goals: [],\n goalsLoading: false,\n updatingClientAttributes: false,\n};\n\nexport const updateClientAttributes = createAsyncThunk(\n 'clients/updateClientAttributes',\n async (arg: { clientId: number; attributes: ClientAttributes }) => {\n return clientApi.updateClientAttributes(arg.clientId, arg.attributes);\n }\n);\n\nexport const fetchClientFullSchedule = createAsyncThunk(\n 'clients/fetchClientFullSchedule',\n async (arg: {\n clientId: number;\n startDate: string;\n endDate: string;\n skipLoading?: boolean;\n }) => {\n return scheduleApi.fetchClientFullSchedule(\n arg.clientId,\n arg.startDate,\n arg.endDate,\n true\n );\n }\n);\n\nexport const fetchClientCaseTeam = createAsyncThunk(\n 'clients/fetchClientCaseTeam',\n async (clientId: number) => {\n return clientApi.fetchClientCaseTeam(clientId);\n }\n);\n\nexport const fetchClientGoals = createAsyncThunk(\n 'client/fetchClientGoals',\n (arg: { clientId: number; limit?: number }, { rejectWithValue }) => {\n return clientApi.fetchClientGoals(arg.clientId, arg.limit);\n }\n);\n\nconst clientsSlice = createSlice({\n name: 'clients',\n initialState,\n reducers: {\n setCaseTeamLoading: (state, action: PayloadAction) => ({\n ...state,\n caseTeamLoading: action.payload,\n }),\n setCaseTeam: (state, action: PayloadAction) => ({\n ...state,\n caseTeamLoading: false,\n caseTeam: action.payload,\n }),\n setClientFullScheduleLoading: (state, action: PayloadAction) => ({\n ...state,\n clientFullScheduleLoading: action.payload,\n }),\n setCurrentClient: (state, action: PayloadAction) => ({\n ...state,\n currentClient: action.payload,\n }),\n setCurrentClientLoading: (state, action: PayloadAction) => ({\n ...state,\n currentClient: action.payload ? null : state.currentClient,\n currentClientLoading: action.payload,\n }),\n setGoals: (state, action: PayloadAction) => ({\n ...state,\n goals: action.payload,\n }),\n setGoalsLoading: (state, action: PayloadAction) => ({\n ...state,\n goalsLoading: action.payload,\n }),\n },\n extraReducers: (builder) =>\n builder\n .addCase(clearSearchResult, (state, action) => {\n return {\n ...initialState,\n currentClient: state.currentClient,\n };\n })\n .addCase(fetchClientFullSchedule.pending, (state, action) => {\n return {\n ...state,\n clientFullScheduleLoading: !action.meta.arg.skipLoading,\n clientFullScheduleRequestId: action.meta.requestId,\n };\n })\n .addCase(fetchClientFullSchedule.fulfilled, (state, action) => {\n const { requestId } = action.meta;\n if (state.clientFullScheduleRequestId === requestId) {\n const firstTimeOffSession = getFirstSessionAfter({\n sessions: action.payload,\n after: TWO_WEEKS,\n });\n\n return {\n ...state,\n clientFullScheduleLoading: false,\n clientFullScheduleRequestId: undefined,\n clientFullSchedule: action.payload.map((session) => {\n const removeSessionVariant = getRemoveSessionVariant(session);\n const { segmentStartUtc, segmentEndUtc } = session;\n const sessionStart = moment(segmentStartUtc);\n const sessionEnd = moment(segmentEndUtc);\n const now = moment().utc();\n\n const isActiveSession = now.isBetween(sessionStart, sessionEnd);\n\n return {\n ...session,\n removeSessionVariant,\n isFirstTimeOff:\n session.segmentId === firstTimeOffSession?.segmentId,\n isActiveSession,\n };\n }),\n };\n }\n return state;\n })\n .addCase(fetchClientFullSchedule.rejected, (state, action) => {\n const { requestId } = action.meta;\n if (\n state.clientFullScheduleLoading &&\n state.clientFullScheduleRequestId === requestId\n ) {\n return {\n ...state,\n clientFullScheduleLoading: false,\n clientFullScheduleRequestId: undefined,\n clientFullSchedule: [],\n currentClient: null,\n };\n }\n return state;\n })\n .addCase(fetchClientCaseTeam.pending, (state, action) => {\n return {\n ...state,\n caseTeamLoading: true,\n };\n })\n .addCase(fetchClientCaseTeam.fulfilled, (state, action) => {\n return {\n ...state,\n caseTeamLoading: false,\n caseTeam: action.payload,\n };\n })\n .addCase(fetchClientCaseTeam.rejected, (state, action) => {\n return {\n ...state,\n caseTeamLoading: false,\n };\n })\n .addCase(fetchClientGoals.pending, (state, action) => {\n return {\n ...state,\n goalsLoading: true,\n };\n })\n .addCase(fetchClientGoals.fulfilled, (state, action) => {\n return {\n ...state,\n goalsLoading: false,\n goals: action.payload,\n };\n })\n .addCase(fetchClientGoals.rejected, (state, action) => {\n return {\n ...state,\n goalsLoading: false,\n };\n })\n .addCase(updateClientAttributes.pending, (state, action) => {\n state.updatingClientAttributes = true;\n })\n .addCase(updateClientAttributes.fulfilled, (state, action) => {\n if (!state.currentClient) {\n return state;\n }\n\n state.currentClient.attributes = action.payload;\n state.updatingClientAttributes = false;\n return state;\n })\n .addCase(updateClientAttributes.rejected, (state, action) => {\n state.updatingClientAttributes = false;\n }),\n});\n\nexport const {\n setCaseTeamLoading,\n setClientFullScheduleLoading,\n setCurrentClient,\n setCurrentClientLoading,\n setGoals,\n} = clientsSlice.actions;\n\nexport default clientsSlice.reducer;\n\nexport const fetchCurrentClientById = createAsyncThunk(\n 'clients/fetchCurrentClientById',\n async (clientId: number, { dispatch }) => {\n dispatch(setCurrentClientLoading(true));\n dispatch(SessionRemovalModule.resetSessionRemoval());\n\n try {\n const client = await clientApi.fetchClientById(clientId);\n dispatch(setCurrentClient(client));\n } catch (e: any) {\n if (e.statusCode === 403) {\n dispatch(setCurrentClient(null));\n dispatch(fetchCurrentUser());\n }\n }\n\n dispatch(setCurrentClientLoading(false));\n }\n);\n","import { createMuiTheme, Theme } from '@material-ui/core/styles';\nimport { fade } from '@material-ui/core/styles/colorManipulator';\n\ndeclare module '@material-ui/core/styles/createPalette' {\n interface Palette {\n kyoGreen: PaletteColor;\n kyoLightGreen: PaletteColor;\n kyoTeal: PaletteColor;\n kyoYellow: PaletteColor;\n kyoRed: PaletteColor;\n kyoRed2: PaletteColor;\n kyoRed3: PaletteColor;\n kyoMagenta: PaletteColor;\n kyoPurple: PaletteColor;\n kyoDarkGreen: PaletteColor;\n kyoDarkestGreen: PaletteColor;\n kyoLightRed: PaletteColor;\n kyoOrange: PaletteColor;\n kyoBlue: PaletteColor;\n kyoBlue1: PaletteColor;\n kyoBlue2: PaletteColor;\n kyoSilver: PaletteColor;\n kyoDollarBill: PaletteColor;\n kyoPastelOrange: PaletteColor;\n kyoOrangeRed: PaletteColor;\n kyoGray: PaletteColor;\n kyoGray2: PaletteColor;\n kyoGray3: PaletteColor;\n kyoGray63: PaletteColor;\n kyoPastelGreen: PaletteColor;\n kyoBurntOrange: PaletteColor;\n kyoSkyBlue: PaletteColor;\n kyoPastelRed: PaletteColor;\n kyoBondiBlue: PaletteColor;\n kyoPink: PaletteColor;\n kyoGray4: PaletteColor;\n kyoLavender: PaletteColor;\n }\n interface PaletteOptions {\n kyoGreen: PaletteColor;\n kyoLightGreen: PaletteColor;\n kyoTeal: PaletteColor;\n kyoYellow: PaletteColor;\n kyoRed: PaletteColor;\n kyoRed2: PaletteColor;\n kyoRed3: PaletteColor;\n kyoMagenta: PaletteColor;\n kyoPurple: PaletteColor;\n kyoDarkGreen: PaletteColor;\n kyoDarkestGreen: PaletteColor;\n kyoLightRed: PaletteColor;\n kyoOrange: PaletteColor;\n kyoBlue: PaletteColor;\n kyoBlue1: PaletteColor;\n kyoBlue2: PaletteColor;\n kyoSilver: PaletteColor;\n kyoDollarBill: PaletteColor;\n kyoPastelOrange: PaletteColor;\n kyoOrangeRed: PaletteColor;\n kyoGray: PaletteColor;\n kyoGray2: PaletteColor;\n kyoGray3: PaletteColor;\n kyoGray63: PaletteColor;\n kyoPastelGreen: PaletteColor;\n kyoBurntOrange: PaletteColor;\n kyoSkyBlue: PaletteColor;\n kyoPastelRed: PaletteColor;\n kyoBondiBlue: PaletteColor;\n kyoPink: PaletteColor;\n kyoGray4: PaletteColor;\n kyoLavender: PaletteColor;\n }\n}\n\ndeclare module '@material-ui/core/styles/overrides' {\n interface ComponentNameToClassKey {\n // MUIDataTableToolbar: {\n // root: React.CSSProperties;\n // titleText: React.CSSProperties;\n // };\n // MUIDataTableHead: {\n // main: React.CSSProperties;\n // };\n // MUIDataTableHeadCell: {\n // root: React.CSSProperties;\n // data: React.CSSProperties;\n // };\n // MUIDataTableBodyCell: {\n // root: React.CSSProperties;\n // };\n // MUIDataTableSelectCell: {\n // root: React.CSSProperties;\n // headerCell: React.CSSProperties;\n // };\n // MUIDataTable: {\n // tableRoot: React.CSSProperties;\n // };\n MuiPickersToolbar: {\n toolbar: React.CSSProperties;\n };\n MuiPickersToolbarText: {\n toolbarTxt: React.CSSProperties;\n toolbarBtnSelected: React.CSSProperties;\n };\n MuiPickersBasePicker: {\n pickerView: React.CSSProperties;\n };\n }\n}\n\nconst theme = createMuiTheme({\n palette: {\n kyoGreen: {\n main: '#78D64B',\n light: '#acff7c',\n dark: '#43a414',\n contrastText: '#fff',\n },\n kyoLightGreen: {\n main: '#56bdce',\n light: '#8cf0ff',\n dark: '#0d8d9d',\n contrastText: '#fff',\n },\n kyoTeal: {\n main: '#00c0d3',\n light: '#63f3ff',\n dark: '#008fa2',\n contrastText: '#fff',\n },\n kyoYellow: {\n main: '#fbde40',\n light: '#ffff75',\n dark: '#c4ad00',\n contrastText: '#000',\n },\n kyoRed: {\n main: '#f4364c',\n light: '#ff6f78',\n dark: '#ba0024',\n contrastText: '#fff',\n },\n kyoRed2: {\n main: '#F7716E',\n light: '#F7716EB2',\n dark: '#EA2A50',\n contrastText: '#fff',\n },\n kyoRed3: {\n main: '#FFF0EF',\n light: '#FFCECC',\n dark: '#FFF0EF', // same with main\n contrastText: '#F7716E', // #F7716E F7716EB2\n },\n kyoMagenta: {\n main: '#E31C79',\n light: '#ff5fa8',\n dark: '#ab004d',\n contrastText: '#000',\n },\n kyoPurple: {\n main: '#3C1053',\n light: '#693b80',\n dark: '#1b002a',\n contrastText: '#fff',\n },\n kyoDarkGreen: {\n main: '#005F61',\n light: '#418d8e',\n dark: '#003537',\n contrastText: '#fff',\n },\n kyoDarkestGreen: {\n main: '#07272d',\n light: '#324f56',\n dark: '#000002',\n contrastText: '#fff',\n },\n kyoLightRed: {\n main: '#fa9370',\n light: '#ffc49f',\n dark: '#c36444',\n contrastText: '#fff',\n },\n kyoOrange: {\n main: '#edc8a3',\n light: '#fffbd4',\n dark: '#ba9774',\n contrastText: '#000',\n },\n kyoBlue: {\n main: '#1672ec',\n light: '#69a0ff',\n dark: '#0048b9',\n contrastText: '#fff',\n },\n kyoBlue1: {\n main: '#8ab9f6',\n light: '#e1edfb',\n dark: '#0F56B3',\n contrastText: '#000',\n },\n kyoBlue2: {\n main: '#5096f1',\n light: '#8ac6ff',\n dark: '#0069be',\n contrastText: '#000',\n },\n kyoSilver: {\n main: '#c0c0c0',\n light: '#f3f3f3',\n dark: '#909090',\n contrastText: '#000',\n },\n kyoDollarBill: {\n main: '#87C652',\n light: '#F6FCF1',\n dark: '#446329',\n contrastText: '#fff',\n },\n kyoPastelOrange: {\n main: '#FFAD4D',\n light: '#FFFAF3',\n dark: '#99682E',\n contrastText: '#fff',\n },\n kyoOrangeRed: {\n main: '#FF4D4D',\n light: '#FFF2F2',\n dark: '#992E2E',\n contrastText: '#000',\n },\n kyoGray: {\n main: '#E0E0E0',\n light: '#F2F2F2',\n dark: '#616161',\n contrastText: '#000',\n },\n kyoGray2: {\n main: '#E5E5E580',\n light: '#EDEDED',\n dark: '#E5E5E54D',\n contrastText: '#616161',\n },\n kyoGray3: {\n main: '#797F84',\n light: '#818181',\n dark: '#DCDCDC',\n contrastText: '#616161', // same as in kyoGray2\n },\n kyoGray63: {\n main: '#A1A1A1',\n light: '#d0d0d0',\n dark: '#414141',\n contrastText: '#000',\n },\n kyoPastelGreen: {\n main: '#2AB930',\n light: '#FBFFF9',\n dark: '#155d18',\n contrastText: '#000',\n },\n kyoBurntOrange: {\n main: '#F2B05C',\n light: '#f9d8ae',\n dark: '#79582e',\n contrastText: '#000',\n },\n kyoSkyBlue: {\n main: '#3acbf2',\n light: '#D4EAF0',\n dark: '#1C6D7A',\n contrastText: '#000',\n },\n kyoPastelRed: {\n main: '#fcd0cf',\n light: '#FFF4F6',\n dark: '#FF6C6C',\n contrastText: '#000',\n },\n kyoBondiBlue: {\n main: '#24A9D9',\n light: '#CCEAEC',\n dark: '#197697',\n contrastText: '#fff',\n },\n kyoPink: {\n main: '#E4287C',\n light: '#F9D2E4',\n dark: '#E31D79',\n contrastText: '#000',\n },\n kyoGray4: {\n main: '#999A9E',\n light: '#DBDCDD',\n dark: '#999A9E',\n contrastText: '#000',\n },\n kyoLavender: {\n main: '#734F96',\n light: '#E1D6E8',\n dark: '#7E40AA',\n contrastText: '#000',\n },\n },\n breakpoints: {\n values: {\n xs: 0,\n sm: 600,\n md: 960,\n lg: 1280,\n xl: 1440,\n },\n },\n typography: {\n fontFamily: `\"Manrope\", \"Roboto\", \"Helvetica\", \"Arial\", sans-serif`,\n fontSize: 16,\n h1: {\n fontSize: 96,\n fontWeight: 700,\n },\n h2: {\n fontSize: 60,\n fontWeight: 700,\n },\n h3: {\n fontSize: 48,\n fontWeight: 700,\n },\n h4: {\n fontSize: 32,\n fontWeight: 600,\n },\n h5: {\n fontSize: 24,\n fontWeight: 600,\n },\n h6: {\n fontSize: 20,\n fontWeight: 600,\n },\n subtitle1: {\n fontSize: 16,\n fontWeight: 700,\n },\n subtitle2: {\n fontSize: 14,\n fontWeight: 700,\n },\n body1: {\n fontSize: 16,\n fontWeight: 400,\n },\n body2: {\n fontSize: 14,\n fontWeight: 400,\n },\n button: {\n fontSize: 16,\n fontWeight: 700,\n },\n caption: {\n fontSize: 12,\n fontWeight: 400,\n },\n overline: {\n fontSize: 10,\n fontWeight: 800,\n },\n },\n});\n\nconst themeWithOverrides = createMuiTheme(theme, {\n overrides: {\n MuiCssBaseline: {\n '@global': {\n body: {\n backgroundColor: '#fff',\n },\n },\n },\n MUIDataTableToolbar: {\n root: {\n padding: 0,\n color: theme.palette.grey[700],\n borderBottom: `1px solid ${theme.palette.grey[300]}`,\n },\n titleText: {\n '&.MuiTypography-h6': {\n [theme.breakpoints.down('xs')]: {\n textAlign: 'left',\n },\n },\n },\n },\n MUIDataTableHeadCell: {\n root: {\n paddingTop: theme.spacing(1),\n paddingBottom: theme.spacing(1),\n borderBottomWidth: 2,\n '&[aria-sort=\"ascending\"], &[aria-sort=\"descending\"]': {\n borderBottomColor: theme.palette.kyoBlue.main,\n },\n fontSize: 14,\n color: theme.palette.grey[400],\n fontWeight: 700,\n },\n data: {\n fontSize: 14,\n color: theme.palette.grey[400],\n fontWeight: 700,\n },\n },\n MUIDataTableBodyCell: {\n root: {\n overflowWrap: 'anywhere',\n paddingTop: theme.spacing(1),\n paddingBottom: theme.spacing(1),\n 'td&': {\n borderTop: `1px solid ${theme.palette.grey[300]}`,\n borderBottomWidth: 0,\n },\n [theme.breakpoints.down('xs')]: {\n paddingLeft: 0,\n paddingRight: 0,\n },\n },\n },\n MuiCircularProgress: {\n colorPrimary: {\n color: theme.palette.kyoBlue.main,\n },\n },\n MuiLinearProgress: {\n colorPrimary: {\n backgroundColor: `${theme.palette.kyoBlue.main}50`,\n },\n barColorPrimary: {\n backgroundColor: theme.palette.kyoBlue.main,\n },\n },\n MuiPickersToolbar: {\n toolbar: {\n backgroundColor: theme.palette.grey[100],\n },\n },\n MuiPickersToolbarText: {\n toolbarTxt: {\n color: theme.palette.common.black,\n },\n toolbarBtnSelected: {\n color: theme.palette.common.black,\n },\n },\n MuiPickersDay: {\n daySelected: {\n color: 'unset',\n border: `1px solid ${theme.palette.kyoBlue.main}`,\n backgroundColor: fade('#C5DCFA', 0.5),\n '&:hover': {\n backgroundColor: '#C5DCFA',\n },\n '&:focus': {\n backgroundColor: fade('#C5DCFA', 0.5),\n },\n },\n },\n MuiPickersBasePicker: {\n pickerView: {\n margin: 'auto',\n },\n },\n MUIDataTableSelectCell: {\n root: {\n display: 'none',\n },\n headerCell: {\n display: 'none',\n },\n },\n MUIDataTable: {\n tableRoot: {\n '@global': {\n tbody: {\n borderBottom: `2px solid ${theme.palette.grey[300]}`,\n '& > tr:first-child > td': {\n borderTopWidth: 0,\n },\n },\n },\n },\n },\n MuiDialog: {\n root: {\n '&:not(:last-of-type)': {\n display: 'none',\n },\n },\n },\n },\n});\n\nexport const getMenteesTableTheme = (theme: Theme) =>\n createMuiTheme(theme, {\n overrides: {\n MuiTableHead: {\n root: {\n whiteSpace: 'nowrap',\n },\n },\n MuiPaper: {\n root: {\n backgroundColor: 'unset',\n },\n },\n MuiDivider: {\n root: {\n backgroundColor: theme.palette.kyoGray2.dark,\n },\n },\n MUIDataTableHeadCell: {\n root: {\n textAlign: 'center',\n [theme.breakpoints.down('md')]: {\n whiteSpace: 'nowrap',\n fontSize: 12,\n letterSpacing: '-0.5px',\n },\n },\n },\n MuiTableCell: {\n root: {\n textAlign: 'center',\n '&.center-cell': {\n textAlign: 'center',\n },\n '&:first-child': {\n width: '23%',\n },\n '&:nth-child(2)': {\n width: '10%',\n },\n },\n head: {\n fontSize: 14,\n color: theme.palette.grey[400],\n fontWeight: 700,\n borderBottomWidth: 0,\n '&:first-child': {\n width: '20%',\n },\n },\n },\n },\n });\n\nexport default themeWithOverrides;\n"],"sourceRoot":""}