{"version":3,"sources":["registerServiceWorker.ts","../../../src/types/enums.ts","../../../src/utils/colors.ts","../../../src/hooks/useFocusOnMount.ts","../../../../src/components/buttons/Button.tsx","../../../../src/components/buttons/SecondaryButton.tsx","../../../src/hooks/useUUID.ts","../../../../src/components/icons/LoginIcon.tsx","../../../src/utils/constants.ts","../../../src/styles/Typography.tsx","../../../../src/components/login/Login.tsx","../../../src/components/Loading.tsx","../../../src/types/types.ts","../../../src/components/NuliaTheme.tsx","../../../src/utils/authConfig.ts","../../../src/enums/ResultCode.ts","../../../src/contexts/HomeContext.tsx","../../../../src/components/buttons/BackButton.tsx","../../../src/components/Tabs.tsx","../../../../src/components/icons/OutcomesIcon.tsx","../../../../src/components/buttons/TextButton.tsx","../../../../src/components/icons/HowToIcon.tsx","../../../../src/components/navigation/NavigationLink.tsx","../../../src/contexts/UserContext.tsx","../../../src/utils/hasAdminRole.ts","../../../../src/components/navigation/NavigationLinks.tsx","../../../../src/components/navigation/NavigationLogo.tsx","../../../../src/components/navigation/MobileCloseNavigation.tsx","../../../src/contexts/NavigationContext.tsx","../../../../src/components/navigation/MobileOpenNavigation.tsx","../../../src/contexts/SnackbarContext.tsx","../../../src/utils/logError.ts","../../../src/enums/Status.ts","../../../src/contexts/TokenContext.tsx","../../../src/utils/getToken.ts","../../../src/types/MessageText.ts","../../../src/services/ApiServiceProvider.tsx","../../../src/utils/isValidBlobToken.ts","../../../src/components/DefaultUserImage.tsx","../../../../src/components/icons/EngagementPointsIcon.tsx","../../../src/utils/numberUtils.ts","../../../src/components/UserInfo.tsx","../../../src/contexts/HeaderContext.tsx","../../../src/utils/mapper.ts","../../../src/data/HelperApi.ts","../../../src/data/HomeApi.ts","../../../src/services/HomeService.ts","../../../src/data/SkillApi.ts","../../../src/services/SkillService.ts","../../../src/data/Api.ts","../../../src/services/UserService.ts","../../../src/hooks/useGetUser.ts","../../../src/hooks/useGetHomeData.ts","../../../../src/components/icons/AchievementIcon.tsx","../../../../src/components/home/AchievementCard.tsx","../../../../src/components/home/BadgeCard.tsx","../../../src/components/ContentRater.tsx","../../../../src/components/video/VideoPlayer.tsx","../../../../src/components/video/VideoDialog.tsx","../../../../src/components/audio/AudioPlayer.tsx","../../../../src/components/audio/AudioDialog.tsx","../../../../src/components/pdf/PdfDialog.tsx","../../../src/components/HtmlDialog.tsx","../../../src/components/Dialog.tsx","../../../src/contexts/DialogContext.tsx","../../../../src/components/icons/BestPracticeVideoIcon.tsx","../../../src/components/NewUpdatedLabel.tsx","../../../src/components/Resource.tsx","../../../src/components/ResourceAccordion.tsx","../../../src/components/Activity.tsx","../../../src/components/RecommendedActivity.tsx","../../../src/contexts/LockContext.tsx","../../../src/components/Tooltip.tsx","../../../src/data/OutcomeApi.ts","../../../src/services/OutcomeService.ts","../../../src/utils/isOutcome.ts","../../../../src/components/buttons/AddButton.tsx","../../../../src/components/buttons/UpgradeButton.tsx","../../../../src/components/icons/UserUnachievedIcon.tsx","../../../../src/components/icons/UserAchievedIcon.tsx","../../../src/components/RecommendedOutcomeOrSkill.tsx","../../../src/components/HomeRecommendation.tsx","../../../../src/components/charts/DoughnutChart.tsx","../../../../src/components/home/SnapShot.tsx","../../../../src/components/icons/BigStreakIcon.tsx","../../../../src/components/icons/StreakIcon.tsx","../../../../src/components/home/StreaksCard.tsx","../../../../src/components/motd/MotdVideo.tsx","../../../../src/components/motd/MotdImageText.tsx","../../../../src/components/motd/MotdTextOnly.tsx","../../../../src/components/motd/MotdImageTextAction.tsx","../../../../src/components/motd/Motd.tsx","../../../../src/components/icons/CalendarIcon.tsx","../../../src/utils/getDaysToNextUpdate.ts","../../../../src/components/home/MeasurementCard.tsx","../../../src/components/NextLastUpdated.tsx","../../../../src/components/home/Home.tsx","../../../src/contexts/SkillsContext.tsx","../../../src/hooks/useGetSkillsData.ts","../../../../src/components/buttons/RemoveButton.tsx","../../../../src/components/icons/ProducerAchievedIcon.tsx","../../../../src/components/icons/MasterAchievedIcon.tsx","../../../../src/components/icons/ProducerUnachievedIcon.tsx","../../../../src/components/icons/MasterUnachievedIcon.tsx","../../../../src/components/skills/SkillIconContainer.tsx","../../../../src/components/outcomes/OutcomeLevelIconContainer.tsx","../../../src/components/LevelIcon.tsx","../../../../src/components/outcomes/OutcomeImage.tsx","../../../src/utils/isUnavailable.ts","../../../src/utils/isUnassigned.ts","../../../src/utils/toStateString.ts","../../../src/utils/toStreakString.ts","../../../../src/components/outcomes/Outcome.tsx","../../../src/components/SkillProgressBar.tsx","../../../../src/components/skills/Skill.tsx","../../../../src/components/icons/ComingSoonIcon.tsx","../../../../src/components/popovers/HardhatPopover.tsx","../../../../src/components/popovers/EduPopover.tsx","../../../../src/components/popovers/CollectorPopover.tsx","../../../../src/components/popovers/StarterPopover.tsx","../../../../src/components/buttons/UnavailableButton.tsx","../../../src/contexts/OutcomesContext.tsx","../../../src/hooks/useGetOutcomesData.ts","../../../src/utils/replaceAll.ts","../../../src/utils/isStarterCustomer.ts","../../../src/components/CardSkillsOrOutcomes.tsx","../../../../src/components/filters/Filter.tsx","../../../../src/components/filters/FilterSet.tsx","../../../../src/components/filters/Filters.tsx","../../../src/components/Search.tsx","../../../src/components/AllSkillsOrOutcomes.tsx","../../../../src/components/skills/AllSkills.tsx","../../../src/components/InfoCard.tsx","../../../src/components/Header.tsx","../../../../src/components/skills/RecommendedSkill.tsx","../../../src/utils/isUpgradeSkillRecommendation.ts","../../../../src/components/skills/RecommendedSkillCard.tsx","../../../../src/components/skills/YourSkills.tsx","../../../src/components/MeasurementBanner.tsx","../../../../src/components/skills/Skills.tsx","../../../src/data/PreferencesApi.ts","../../../src/services/PreferencesService.ts","../../../src/services/HelperService.ts","../../../../src/components/preferences/PreferencesForm.tsx","../../../../src/components/preferences/FeedbackForm.tsx","../../../../src/components/preferences/Preferences.tsx","../../../../src/components/notifications/NotificationIcon.tsx","../../../../src/components/notifications/Notification.tsx","../../../../src/components/notifications/NotificationCard.tsx","../../../src/contexts/NotificationsProvider.tsx","../../../src/data/NotificationsApi.ts","../../../src/data/ShowcaseApi.ts","../../../src/services/NotificationService.ts","../../../../src/components/notifications/Notifications.tsx","../../../src/hooks/useGetNotifications.ts","../../../src/hooks/useViewedNotifications.ts","../../../src/components/ChangeTargetLevel.tsx","../../../src/components/DetailsOverviewSkillsOrOutcomes.tsx","../../../src/components/UnavailablePanel.tsx","../../../src/components/Accordion.tsx","../../../../src/components/skills/SkillLockedIcon.tsx","../../../src/utils/levelToName.ts","../../../../src/components/skills/SkillLevel.tsx","../../../../src/components/skills/SkillDetails.tsx","../../../src/hooks/useGetSkillDetails.ts","../../../../src/components/outcomes/AllOutcomes.tsx","../../../../src/components/outcomes/RecommendedOutcome.tsx","../../../src/utils/isUpgradeOutcomeRecommendation.ts","../../../../src/components/outcomes/RecommendedOutcomesCard.tsx","../../../../src/components/outcomes/YourOutcomes.tsx","../../../../src/components/outcomes/Outcomes.tsx","../../../src/hooks/useTelemetry.ts","../../../../src/components/icons/LinkedInIcon.tsx","../../../../src/components/showcase/BadgeDialog.tsx","../../../../src/components/showcase/Badge.tsx","../../../../src/components/outcomes/OutcomeSkill.tsx","../../../src/utils/clampNumber.ts","../../../src/hooks/useRovingTabIndex.tsx","../../../../src/components/outcomes/OutcomeDetails.tsx","../../../src/hooks/useGetOutcomeDetails.ts","../../../src/contexts/ShowcaseContext.tsx","../../../src/services/ShowcaseService.ts","../../../src/hooks/useGetShowcaseData.ts","../../../../src/components/showcase/Achievement.tsx","../../../src/utils/getEarnedBadges.ts","../../../src/utils/getInProgressBadges.ts","../../../src/utils/getNonSeriesAchievements.ts","../../../src/utils/getSeriesAchievements.ts","../../../src/utils/getEarnedAchievements.ts","../../../src/utils/routeClientProvider.ts","../../../../src/components/showcase/Showcase.tsx","../../../src/utils/getUnearnedAchivements.ts","../../../../src/components/showcase/YourAchievements.tsx","../../../../src/components/showcase/YourBadges.tsx","../../../src/components/Instructions.tsx","../../../../src/components/insights/UserGraph.tsx","../../../src/contexts/InsightsProvider.tsx","../../../../src/components/select/Select.tsx","../../../../src/components/bulk/BulkUnassignOutcomeDialog.tsx","../../../../src/components/icons/BadgeCheckIcon.tsx","../../../../src/components/icons/NeedAttentionIcon.tsx","../../../../src/components/icons/ReadyForMoreIcon.tsx","../../../../../src/components/insights/Users/DotUserTable.tsx","../../../src/hooks/useFocusOnFirstFocusable.ts","../../../src/utils/getKeyboardFocusableElements.ts","../../../../src/components/insights/InsightsMenu.tsx","../../../../../src/components/insights/Users/AssignOutcomeDialog.tsx","../../../../../src/components/insights/Users/UserReportOverflow.tsx","../../../../src/components/icons/LastLoginIcon.tsx","../../../../src/components/insights/TableSortCell.tsx","../../../../../src/components/insights/Users/UserTableHead.tsx","../../../../../src/components/insights/Users/UserTableToolbar.tsx","../../../src/utils/stableSort.ts","../../../src/utils/descendingComparator.ts","../../../src/utils/getComparator.ts","../../../src/enums/BulkAction.ts","../../../../../src/components/insights/Users/InsightUsersTable.tsx","../../../../../src/components/insights/Users/UsersFilters.tsx","../../../src/utils/hasManagerRole.ts","../../../src/utils/isAllFilter.ts","../../../../src/components/insights/Filters.tsx","../../../src/utils/levelFilterOptions.ts","../../../src/data/InsightsApi.ts","../../../src/services/InsightsService.ts","../../../../src/components/icons/ArrowIcon.tsx","../../../src/utils/formatCsvDate.ts","../../../../../src/components/insights/ReportsDownloader/ReportList.tsx","../../../../../src/components/insights/ReportsDownloader/ReportsDownloader.tsx","../../../src/utils/calculateBuckets.ts","../../../src/utils/reduceAndFilterInsights.ts","../../../../src/components/insights/Constants.tsx","../../../../../src/components/insights/Users/InsightUsers.tsx","../../../../src/components/icons/ReadyForCompleteLargeIcon.tsx","../../../../src/components/icons/RequestLargeIcon.tsx","../../../../src/components/bulk/BulkAssignLicensesDialog.tsx","../../../../../src/components/insights/Licenses/LicenseData.tsx","../../../../../src/components/insights/Licenses/LicenseTableToolbar.tsx","../../../../../src/components/insights/Licenses/AssignLicensesDialog.tsx","../../../../../src/components/insights/Licenses/RemoveLicensesDialog.tsx","../../../src/utils/isStarter.ts","../../../src/utils/hasSync.ts","../../../../../src/components/insights/Licenses/NotEnoughLicensesDialog.tsx","../../../../../src/components/insights/Licenses/LicenseReportOverflow.tsx","../../../../../src/components/insights/Licenses/LicenseTableHead.tsx","../../../../src/components/bulk/BulkRemoveLicenseDialog.tsx","../../../../../src/components/insights/Licenses/InsightLicensesTable.tsx","../../../../../src/components/insights/Licenses/InsightLicenses.tsx","../../../src/hooks/useGetInsightsData.ts","../../../../../src/components/insights/User/Filters.tsx","../../../../../src/components/insights/User/OutcomeTableHead.tsx","../../../../../src/components/insights/User/InsightsOutcomeTable.tsx","../../../../../src/components/insights/User/InsightUser.tsx","../../../src/data/BulkApi.ts","../../../src/utils/formatBulkHistoryAction.ts","../../../src/enums/BulkStatus.ts","../../../src/services/BulkService.ts","../../../src/utils/getStatusColor.ts","../../../../../../src/components/insights/Assessments/charts/AdoptionChart.tsx","../../../src/utils/getStatusString.ts","../../../../../src/components/insights/History/History.tsx","../../../../src/components/icons/InfoIcon.tsx","../../../../../../src/components/insights/Assessments/table/AssessmentTableHead.tsx","../../../../../../src/components/insights/Assessments/charts/ScoreChart.tsx","../../../../../../src/components/insights/Assessments/table/InsightAssessmentTable.tsx","../../../../../src/components/insights/Assessments/InsightsAssessments.tsx","../../../../src/components/insights/Insights.tsx","../../../src/utils/hasUserRole.ts","../../../src/hooks/usePrevious.ts","../../../../../src/components/insights/Details/ChangeTargetLevel.tsx","../../../../../src/components/insights/Details/OutcomeOptions.tsx","../../../../../src/components/insights/Details/ReportOutcome.tsx","../../../src/utils/isMaintained.ts","../../../../../src/components/insights/Details/OutcomesCard.tsx","../../../../../src/components/insights/Details/InsightsDetailsOutcomes.tsx","../../../../../src/components/insights/Details/SkillsCard.tsx","../../../../../src/components/insights/Details/InsightsDetailsSkills.tsx","../../../../../src/components/insights/Details/InsightsDetail.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomesDetailOutcomeTableToolbar.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomeDetailOutcomeTableHead.tsx","../../../../../src/components/insights/OutcomesDetail/ChangeTargetLevel.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomeOptions.tsx","../../../../src/components/bulk/BulkAssignOutcomeDialog.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomesDetailOutcomesTable.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomeDetailSkillsTableHead.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomesDetailSkillsTable.tsx","../../../../../src/components/insights/OutcomesDetail/OutcomesGraph.tsx","../../../src/utils/calculateBucketsOutcomeDetail.ts","../../../src/utils/reduceAndFilterOutcomeDetail.ts","../../../../../src/components/insights/OutcomesDetail/InsightOutcomeDetail.tsx","../../../../src/components/buttons/CheckIconButton.tsx","../../../../src/components/buttons/PlusIconButton.tsx","../../../../src/components/bulk/BulkAccordion.tsx","../../../../src/components/bulk/BulkOutcomePicker.tsx","../../../../src/components/bulk/BulkTargetLevelPicker.tsx","../../../../src/components/bulk/BulkAssignConfirm.tsx","../../../../src/components/bulk/BulkDetailOverview.tsx","../../../../src/components/bulk/BulkOutcomeDrawer.tsx","../../../../src/components/bulk/BulkAssignOutcomes.tsx","../../../src/components/NoAccess.tsx","../../../src/components/NoAccount.tsx","../../../src/components/TokenExpired.tsx","../../../src/components/NoNulia.tsx","../../../src/data/HowToApi.ts","../../../src/services/HowToService.ts","../../../src/contexts/HowToContext.tsx","../../../../src/components/howTo/HowTo.tsx","../../../../src/components/howTo/HowToBreadcrumbs.tsx","../../../../src/components/howTo/HowToCategory.tsx","../../../src/hooks/useGetHowToPlaylist.ts","../../../../src/components/select/SelectItem.tsx","../../../../src/components/Stepper/SelectStepper.tsx","../../../../src/components/pdf/PdfViewer.tsx","../../../../src/components/howTo/HowToPlaylist.tsx","../../../src/hooks/useGetHowTos.ts","../../../src/hooks/useViewedHowTo.ts","../../../../../src/components/insights/History/HistoryDetails.tsx","../../../src/components/CookiesDialog.tsx","../../../src/components/Analytics.tsx","../../../src/components/ScrollToTop.tsx","../../../src/components/ErrorBoundary.tsx","Routes.tsx","../../../src/hooks/useGetUserId.ts","Token.tsx","App.tsx","index.tsx"],"names":["isLocalhost","Boolean","window","location","hostname","match","registerValidSW","swUrl","navigator","serviceWorker","register","then","registration","onupdatefound","installingWorker","installing","onstatechange","state","controller","console","log","catch","error","boxShadow","border","LicenseType","LicenseClass","Level","RecommendType","OutcomeSkillState","CompetenceState","ProgressColor","AssignmentType","ResourceType","ActivityType","FeedbackTypes","MotdPages","Pages","PageIds","NotificationType","ClientType","UpgradeRequestType","MotdDisplayType","MotdType","MotdArchetype","MotdActionType","GroupType","HowToType","Colors","light","main","dark","contrastText","root","height","ResultCode","Status","decodedToken","isAfter","Date","se","get","this","resourceData","icon","label","fileType","resource","url","activity","_a","width","NeedsAttention","Maintain","type","classes","alignItems","borderRadius","textAlign","skillOrOutcome","newStr","str","i","e","filteredSkills","newFilteredSkills","afterSearchSkills","filter","sorted","sort","page","HelperService","newFilteredOutcomes","afterSearchOutcomes","filteredOutcomes","a","list","setAttribute","display","setLevelFilter","TableSortCell","search","stableSort","b","setReadyApplied","includes","bucket","newFilter","row","marginTop","labels","flexDirection","justifyContent","id","runFilters","BulkAction","BulkStatus","renderCell","sortable","disableColumnMenu","numeric","disablePadding","tooltipText","backgroundColor","d","append","style","svg","account","setSelected","key","text","attr","legendText","dataArray","response","value","selfStatus","InsightsOutcomesDetailStatus","NotAssigned","oid","name","forEach","setFilter","IconButton","mouseDown","marginBottom","Routes","useContext","UserContext","user","noNulia","expire","TokenContext","useState","didExpire","setDidExpire","receivedData","setReceivedData","getUser","useGetUser","accounts","useMsal","useAccount","getUserId","useGetUserId","useEffect","TokenExpired","licenseType","None","hasAdminRole","exact","path","clientType","platform","from","to","licenseClass","Complete","Unknown","SkillDetails","Token","instance","propOid","localAccountId","prodTid","tenantId","propClientType","MainContent","inProgress","App","msalInstance","PublicClientApplication","msalConfig","ReactDOM","render","StrictMode","document","getElementById","URL","process","toString","origin","addEventListener","fetch","status","headers","indexOf","ready","unregister","reload","check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AkBA,SAElB,MAAmB,UAFnB,EAA4B4B,WAGjB,cAAC,GAAD,IAIP,gCACI,cAAC,IAAD,UACI,cAAC,GAAD,CAAOP,SAAUA,EAAUrB,SAAUA,MAGzC,cAAC,IAAD,UACI,cAAC,GAAD,UAMD,SAAS6B,KACpB,IAAMC,EAAe,IAAIC,IAAwBC,IAEjD,OACI,cAAC,IAAD,CAAcX,SAAUS,EAAxB,SACI,cAAC,GAAD,CAAYlB,WAAYrI,EAAWsI,SAAnC,SACI,cAAC,GAAD,CAAWD,WAAYrI,EAAWsI,SAAlC,SACI,cAAC,GAAD,U,+BCzBpBoB,KAASC,OACL,cAAC,IAAMC,WAAP,UACI,cAACN,GAAD,MAEJO,SAASC,eAAe,SpUMrB,WACH,GAA6C,kBAAmB9L,UAAW,CAGvE,GADkB,IAAI+L,IAAIC,GAAyBtM,OAAOC,SAASsM,YACrDC,SAAWxM,OAAOC,SAASuM,OAIrC,OAGJxM,OAAOyM,iBAAiB,QAAQ,WAC5B,IAAMpM,EAAK,UAAMiM,GAAN,sBAEPxM,IAmDhB,SAAiCO,GAE7BqM,MAAMrM,GACDI,MAAK,SAAC4H,GAEqB,MAApBA,EAASsE,SAAmF,IAAjEtE,EAASuE,QAAQjJ,IAAI,gBAAiBkJ,QAAQ,cAEzEvM,UAAUC,cAAcuM,MAAMrM,MAAK,SAACC,GAChCA,EAAaqM,aAAatM,MAAK,WAC3BT,OAAOC,SAAS+M,eAKxB5M,EAAgBC,MAGvBc,OAAM,WACHF,QAAQC,IAAI,oEAnER+L,CAAwB5M,GAIxBC,UAAUC,cAAcuM,MAAMrM,MAAK,WAC/BQ,QAAQC,IACJ,gHAMRd,EAAgBC,OoUzBhC6M,I","file":"static/js/main.135e5b2d.chunk.js","sourcesContent":["// In production, we register a service worker to serve assets from local cache.\r\n\r\n// This lets the app load faster on subsequent visits in production, and gives\r\n// it offline capabilities. However, it also means that developers (and users)\r\n// will only see deployed updates on the 'N+1' visit to a page, since previously\r\n// cached resources are updated in the background.\r\n\r\n// To learn more about the benefits of this model, read https://goo.gl/KwvDNy.\r\n// This link also includes instructions on opting out of this behavior.\r\n\r\nconst isLocalhost = Boolean(\r\n window.location.hostname === 'localhost' ||\r\n // [::1] is the IPv6 localhost address.\r\n window.location.hostname === '[::1]' ||\r\n // 127.0.0.1/8 is considered localhost for IPv4.\r\n window.location.hostname.match(/^127(?:\\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/)\r\n);\r\n\r\nexport function register() {\r\n if (process.env.NODE_ENV === 'production' && 'serviceWorker' in navigator) {\r\n // The URL constructor is available in all browsers that support SW.\r\n const publicUrl = new URL(process.env.PUBLIC_URL!, window.location.toString());\r\n if (publicUrl.origin !== window.location.origin) {\r\n // Our service worker won't work if PUBLIC_URL is on a different origin\r\n // from what our page is served on. This might happen if a CDN is used to\r\n // serve assets; see https://github.com/facebookincubator/create-react-app/issues/2374\r\n return;\r\n }\r\n\r\n window.addEventListener('load', () => {\r\n const swUrl = `${process.env.PUBLIC_URL}/service-worker.js`;\r\n\r\n if (isLocalhost) {\r\n // This is running on localhost. Lets check if a service worker still exists or not.\r\n checkValidServiceWorker(swUrl);\r\n\r\n // Add some additional logging to localhost, pointing developers to the\r\n // service worker/PWA documentation.\r\n navigator.serviceWorker.ready.then(() => {\r\n console.log(\r\n 'This web app is being served cache-first by a service ' +\r\n 'worker. To learn more, visit https://goo.gl/SC7cgQ'\r\n );\r\n });\r\n } else {\r\n // Is not local host. Just register service worker\r\n registerValidSW(swUrl);\r\n }\r\n });\r\n }\r\n}\r\n\r\nfunction registerValidSW(swUrl: string) {\r\n navigator.serviceWorker\r\n .register(swUrl)\r\n .then((registration) => {\r\n registration.onupdatefound = () => {\r\n const installingWorker = registration.installing;\r\n if (installingWorker) {\r\n installingWorker.onstatechange = () => {\r\n if (installingWorker.state === 'installed') {\r\n if (navigator.serviceWorker.controller) {\r\n // At this point, the old content will have been purged and\r\n // the fresh content will have been added to the cache.\r\n // It's the perfect time to display a 'New content is\r\n // available; please refresh.' message in your web app.\r\n console.log('New content is available; please refresh.');\r\n } else {\r\n // At this point, everything has been precached.\r\n // It's the perfect time to display a\r\n // 'Content is cached for offline use.' message.\r\n console.log('Content is cached for offline use.');\r\n }\r\n }\r\n };\r\n }\r\n };\r\n })\r\n .catch((error) => {\r\n console.error('Error during service worker registration:', error);\r\n });\r\n}\r\n\r\nfunction checkValidServiceWorker(swUrl: string) {\r\n // Check if the service worker can be found. If it can't reload the page.\r\n fetch(swUrl)\r\n .then((response) => {\r\n // Ensure service worker exists, and that we really are getting a JS file.\r\n if (response.status === 404 || response.headers.get('content-type')!.indexOf('javascript') === -1) {\r\n // No service worker found. Probably a different app. Reload the page.\r\n navigator.serviceWorker.ready.then((registration) => {\r\n registration.unregister().then(() => {\r\n window.location.reload();\r\n });\r\n });\r\n } else {\r\n // Service worker found. Proceed as normal.\r\n registerValidSW(swUrl);\r\n }\r\n })\r\n .catch(() => {\r\n console.log('No internet connection found. App is running in offline mode.');\r\n });\r\n}\r\n\r\nexport function unregister() {\r\n if ('serviceWorker' in navigator) {\r\n navigator.serviceWorker.ready.then((registration) => {\r\n registration.unregister();\r\n });\r\n }\r\n}\r\n","export var LicenseType;\n(function (LicenseType) {\n LicenseType[\"None\"] = \"None\";\n LicenseType[\"Complete\"] = \"Complete\";\n LicenseType[\"Starter\"] = \"Starter\";\n})(LicenseType || (LicenseType = {}));\nexport var LicenseClass;\n(function (LicenseClass) {\n LicenseClass[\"Unknown\"] = \"Unknown\";\n LicenseClass[\"Complete\"] = \"Complete\";\n LicenseClass[\"Starter\"] = \"Starter\";\n LicenseClass[\"StarterCompleteSync\"] = \"StarterCompleteSync\";\n LicenseClass[\"CompleteSync\"] = \"CompleteSync\";\n})(LicenseClass || (LicenseClass = {}));\nexport var Level;\n(function (Level) {\n Level[Level[\"None\"] = 0] = \"None\";\n Level[Level[\"User\"] = 1] = \"User\";\n Level[Level[\"Producer\"] = 2] = \"Producer\";\n Level[Level[\"Master\"] = 3] = \"Master\";\n})(Level || (Level = {}));\nexport var RecommendType;\n(function (RecommendType) {\n RecommendType[\"Activity\"] = \"Activity\";\n RecommendType[\"NewOutcome\"] = \"NewOutcome\";\n RecommendType[\"UpgradeOutcome\"] = \"UpgradeOutcome\";\n RecommendType[\"NewSkill\"] = \"NewSkill\";\n RecommendType[\"UpgradeSkill\"] = \"UpgradeSkill\";\n})(RecommendType || (RecommendType = {}));\nexport var OutcomeSkillState;\n(function (OutcomeSkillState) {\n OutcomeSkillState[\"Inactive\"] = \"Inactive\";\n OutcomeSkillState[\"Active\"] = \"Active\";\n OutcomeSkillState[\"Hardhat\"] = \"Hardhat\";\n OutcomeSkillState[\"Preview\"] = \"Preview\";\n})(OutcomeSkillState || (OutcomeSkillState = {}));\nexport var CompetenceState;\n(function (CompetenceState) {\n CompetenceState[\"Locked\"] = \"Locked\";\n CompetenceState[\"Unassigned\"] = \"Unassigned\";\n CompetenceState[\"InProgress\"] = \"InProgress\";\n CompetenceState[\"Maintain\"] = \"Maintain\";\n CompetenceState[\"NeedsAttention\"] = \"NeedsAttention\";\n CompetenceState[\"LockedCollectorVersion\"] = \"LockedCollectorVersion\";\n CompetenceState[\"LockedStarter\"] = \"LockedStarter\";\n CompetenceState[\"LockedEdu\"] = \"LockedEdu\";\n CompetenceState[\"LockedHardhat\"] = \"LockedHardhat\";\n})(CompetenceState || (CompetenceState = {}));\nexport var ProgressColor;\n(function (ProgressColor) {\n ProgressColor[\"Decrease\"] = \"Red\";\n ProgressColor[\"Flat\"] = \"Yellow\";\n ProgressColor[\"Increase\"] = \"Green\";\n})(ProgressColor || (ProgressColor = {}));\nexport var AssignmentType;\n(function (AssignmentType) {\n AssignmentType[\"Nulia\"] = \"Nulia\";\n AssignmentType[\"Self\"] = \"Self\";\n AssignmentType[\"Manager\"] = \"Manager\";\n})(AssignmentType || (AssignmentType = {}));\nexport var ResourceType;\n(function (ResourceType) {\n ResourceType[\"StepByStepPdf\"] = \"StepByStepPdf\";\n ResourceType[\"StepByStepVideo\"] = \"StepByStepVideo\";\n ResourceType[\"StoryPdf\"] = \"StoryPdf\";\n ResourceType[\"StoryVideo\"] = \"StoryVideo\";\n ResourceType[\"StoryPodcast\"] = \"StoryPodcast\";\n ResourceType[\"InfographicPdf\"] = \"InfographicPdf\";\n ResourceType[\"InfographicVideo\"] = \"InfographicVideo\";\n ResourceType[\"PhotoGuidePdf\"] = \"PhotoGuidePdf\";\n ResourceType[\"LightheartedPdf\"] = \"LightheartedPdf\";\n ResourceType[\"LightheartedVideo\"] = \"LightheartedVideo\";\n ResourceType[\"LightheartedPodcast\"] = \"LightheartedPodcast\";\n ResourceType[\"StepByStepHtml\"] = \"StepByStepHtml\";\n ResourceType[\"StoryHtml\"] = \"StoryHtml\";\n ResourceType[\"InfographicHtml\"] = \"InfographicHtml\";\n ResourceType[\"PhotoGuideHtml\"] = \"PhotoGuideHtml\";\n ResourceType[\"LightheartedHtml\"] = \"LightheartedHtml\";\n ResourceType[\"MixedMediaHtml\"] = \"MixedMediaHtml\";\n})(ResourceType || (ResourceType = {}));\nexport var ActivityType;\n(function (ActivityType) {\n ActivityType[\"Unknown\"] = \"Unknown\";\n ActivityType[\"TryIt\"] = \"TryIt\";\n ActivityType[\"Watch\"] = \"Watch\";\n ActivityType[\"View\"] = \"View\";\n})(ActivityType || (ActivityType = {}));\nexport var FeedbackTypes;\n(function (FeedbackTypes) {\n FeedbackTypes[\"Technical\"] = \"Technical\";\n FeedbackTypes[\"OutcomeSkillSuggestion\"] = \"OutcomeSkillSuggestion\";\n FeedbackTypes[\"FeatureQuestion\"] = \"FeatureQuestion\";\n FeedbackTypes[\"SomethingElse\"] = \"SomethingElse\";\n})(FeedbackTypes || (FeedbackTypes = {}));\nexport var MotdPages;\n(function (MotdPages) {\n MotdPages[\"HomePage\"] = \"home\";\n MotdPages[\"SkillsPage\"] = \"skills\";\n MotdPages[\"OutcomesPage\"] = \"outcomes\";\n MotdPages[\"ShowcasePage\"] = \"showcase\";\n MotdPages[\"InsightsPage\"] = \"insights\";\n MotdPages[\"PreferencesPage\"] = \"preferences\";\n MotdPages[\"HowToPage\"] = \"howTo\";\n})(MotdPages || (MotdPages = {}));\nexport var Pages;\n(function (Pages) {\n Pages[\"None\"] = \"\";\n Pages[\"HomePage\"] = \"/homeTab\";\n Pages[\"SkillsPage\"] = \"/skillsTab\";\n Pages[\"OutcomesPage\"] = \"/outcomesTab\";\n Pages[\"ShowcasePage\"] = \"/showcaseTab\";\n Pages[\"InsightsPage\"] = \"/insightsTab\";\n Pages[\"PreferencesPage\"] = \"/preferencesTab\";\n Pages[\"HowToPage\"] = \"/howToTab\";\n})(Pages || (Pages = {}));\nexport var PageIds;\n(function (PageIds) {\n PageIds[\"HomePage\"] = \"26cc9b45-41b4-4759-88d6-a21f17e3f4f8\";\n PageIds[\"SkillsPage\"] = \"ef9b5db3-e49a-4fdd-8e29-ccedda0ffbc7\";\n PageIds[\"OutcomesPage\"] = \"b7220f97-2970-49dc-b5f7-d357d69fd1e3\";\n PageIds[\"ShowcasePage\"] = \"d945c449-fa18-4984-b15c-dcd59ee677c0\";\n PageIds[\"InsightsPage\"] = \"b7029381-f444-4594-8916-ec345d36625b\";\n PageIds[\"PreferencesPage\"] = \"05b62b17-fdaa-4185-b2b8-f92b225cd489\";\n PageIds[\"HowToPage\"] = \"7b2e929a-88e0-4bb0-826d-5a822376c263\";\n})(PageIds || (PageIds = {}));\nexport var NotificationType;\n(function (NotificationType) {\n NotificationType[\"Badge\"] = \"Badge\";\n NotificationType[\"Outcome\"] = \"Outcome\";\n NotificationType[\"Skill\"] = \"Skill\";\n NotificationType[\"Achievement\"] = \"Achievement\";\n NotificationType[\"General\"] = \"General\";\n NotificationType[\"Video\"] = \"Video\";\n})(NotificationType || (NotificationType = {}));\nexport var ClientType;\n(function (ClientType) {\n ClientType[\"platform\"] = \"platform\";\n ClientType[\"desktop\"] = \"desktop\";\n ClientType[\"web\"] = \"web\";\n ClientType[\"android\"] = \"android\";\n ClientType[\"ios\"] = \"ios\";\n ClientType[\"rigel\"] = \"rigel\";\n})(ClientType || (ClientType = {}));\nexport var UpgradeRequestType;\n(function (UpgradeRequestType) {\n UpgradeRequestType[\"Requested\"] = \"Requested\";\n UpgradeRequestType[\"Granted\"] = \"Granted\";\n})(UpgradeRequestType || (UpgradeRequestType = {}));\nexport var MotdDisplayType;\n(function (MotdDisplayType) {\n MotdDisplayType[\"Unknown\"] = \"Unknown\";\n MotdDisplayType[\"Text\"] = \"Text\";\n MotdDisplayType[\"ImageAndTextSideBySide\"] = \"ImageAndTextSideBySide\";\n MotdDisplayType[\"ImageTopTextBottom\"] = \"ImageTopTextBottom\";\n MotdDisplayType[\"TextWithAction\"] = \"TextWithAction\";\n MotdDisplayType[\"ImageAndTextSideBySideWithAction\"] = \"ImageAndTextSideBySideWithAction\";\n MotdDisplayType[\"ImageTopTextBottomWithAction\"] = \"ImageTopTextBottomWithAction\";\n MotdDisplayType[\"Video\"] = \"Video\";\n MotdDisplayType[\"OrangeText\"] = \"OrangeText\";\n MotdDisplayType[\"OrangeImageAndTextSideBySide\"] = \"OrangeImageAndTextSideBySide\";\n MotdDisplayType[\"OrangeImageAndTextSideBySideWithAction\"] = \"OrangeImageAndTextSideBySideWithAction\";\n})(MotdDisplayType || (MotdDisplayType = {}));\nexport var MotdType;\n(function (MotdType) {\n MotdType[\"Unknown\"] = \"Unknown\";\n MotdType[\"ViewOnce\"] = \"ViewOnce\";\n MotdType[\"ExpirationTime\"] = \"ExpirationTime\";\n MotdType[\"Permanent\"] = \"Permanent\";\n})(MotdType || (MotdType = {}));\nexport var MotdArchetype;\n(function (MotdArchetype) {\n MotdArchetype[\"Unknown\"] = \"Unknown\";\n MotdArchetype[\"Lover\"] = \"Lover\";\n MotdArchetype[\"Dreamer\"] = \"Dreamer\";\n MotdArchetype[\"Warrior\"] = \"Warrior\";\n MotdArchetype[\"Thinker\"] = \"Thinker\";\n})(MotdArchetype || (MotdArchetype = {}));\nexport var MotdActionType;\n(function (MotdActionType) {\n MotdActionType[\"Unknown\"] = \"Unknown\";\n MotdActionType[\"RequestUpgrade\"] = \"RequestUpgrade\";\n MotdActionType[\"Content\"] = \"Content\";\n MotdActionType[\"Path\"] = \"Path\";\n})(MotdActionType || (MotdActionType = {}));\nexport var GroupType;\n(function (GroupType) {\n GroupType[\"Unknown\"] = \"Unkown\";\n GroupType[\"ConsecutiveLogin\"] = \"ConsecutiveLogin\";\n GroupType[\"SkillsMaintained\"] = \"SkillsMaintained\";\n GroupType[\"EarnedBadge\"] = \"EarnedBadge\";\n GroupType[\"WeeksMaintainedBadge\"] = \"WeeksMaintainedBadge\";\n GroupType[\"EngagementPoints\"] = \"EngagementPoints\";\n GroupType[\"AvoidNeedsAttention\"] = \"AvoidNeedsAttention\";\n GroupType[\"Hidden\"] = \"Hidden\";\n GroupType[\"EngagementPointsSpent\"] = \"EngagementPointsSpent\";\n GroupType[\"CommunicationSkills\"] = \"CommunicationSkills\";\n GroupType[\"CollaborationSkills\"] = \"CollaborationSkills\";\n GroupType[\"TimeManagementSkills\"] = \"TimeManagementSkills\";\n GroupType[\"LeadershipSkills\"] = \"LeadershipSkills\";\n GroupType[\"FundamentalSkills\"] = \"FundamentalSkills\";\n GroupType[\"AchievementsEarned\"] = \"AchievementsEarned\";\n GroupType[\"UnlockDescription\"] = \"UnlockDescription\";\n})(GroupType || (GroupType = {}));\nexport var HowToType;\n(function (HowToType) {\n HowToType[\"HTML\"] = \"HTML\";\n HowToType[\"PDF\"] = \"PDF\";\n HowToType[\"MP4\"] = \"MP4\";\n})(HowToType || (HowToType = {}));\n//# sourceMappingURL=enums.js.map","export var Colors = {\n purple: '#654ea3',\n lightPurple: '#f3f1f8',\n darkPurple: '#45356f',\n purpleHover: '#c2beda',\n background: '#fafafa',\n white: '#ffffff',\n textPrimary: '#333333',\n textSecondary: '#666666',\n green: '#b0cb3e',\n yellow: '#ffcc55',\n red: '#FE6C6C',\n progressUnassigned: '#d6d6d6',\n disabled: 'rgba(0,0,0,0.16)',\n iconDefault: '#8C8C8C',\n iconHover: '#f3f1f8',\n unachievedSkill: '#d6d6d6',\n userSkill: '#ff955e',\n producerSkill: '#dd6862',\n masterSkill: '#349fee',\n black: '#000',\n low: '#023BC6',\n moderate: '#0278E5',\n high: '#349FEE',\n mediumPurple: '#45356f',\n};\n//# sourceMappingURL=colors.js.map","import { useEffect, useRef } from 'react';\nexport var useFocusOnMount = function (active) {\n var focusRef = useRef(null);\n useEffect(function () {\n if (active && focusRef.current) {\n focusRef.current.focus();\n }\n }, [active]);\n return focusRef;\n};\n//# sourceMappingURL=useFocusOnMount.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { Button as MuiButton, makeStyles } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { useFocusOnMount } from '../../hooks/useFocusOnMount';\nvar useStyles = makeStyles({\n button: {\n width: 95,\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '20px',\n letterSpacing: 1.25,\n textTransform: 'uppercase',\n color: Colors.white,\n backgroundColor: Colors.purple,\n boxShadow: '0 1.5px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.16)',\n cursor: 'pointer',\n elevation: 1,\n border: 0,\n '&:disabled': {\n elevation: 0,\n backgroundColor: Colors.disabled,\n boxShadow: 'none',\n cursor: 'not-allowed',\n },\n '&:hover': {\n backgroundColor: Colors.purple,\n boxShadow: '0 6.5px 16px 1px rgba(0,0,0,0.12), 0 4px 8px 0 rgba(0,0,0,0.08)',\n elevation: 3,\n },\n '&:focus': {\n border: \"1px solid \" + Colors.darkPurple,\n backgroundColor: Colors.purple,\n },\n '&:active': {\n backgroundColor: Colors.darkPurple,\n boxShadow: 'none',\n },\n },\n disabled: {\n width: 95,\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '20px',\n letterSpacing: 1.25,\n textTransform: 'uppercase',\n color: '#000',\n border: 0,\n backgroundColor: '#aaa',\n boxShadow: 'none',\n elevation: 0,\n cursor: 'not-allowed',\n },\n});\nvar Button = function (_a) {\n var id = _a.id, onClick = _a.onClick, type = _a.type, disabled = _a.disabled, title = _a.title, key = _a.key, style = _a.style, children = _a.children, focusOnMount = _a.focusOnMount, tabIndex = _a.tabIndex;\n var classes = useStyles();\n var focusRef = useFocusOnMount(focusOnMount);\n return (_jsx(MuiButton, __assign({ id: id, onClick: onClick, type: type, disabled: disabled, title: title, className: disabled ? classes.disabled : classes.button, style: style, tabIndex: tabIndex, ref: focusRef }, { children: children }), key));\n};\nexport default Button;\n//# sourceMappingURL=Button.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { Button, makeStyles } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { useFocusOnMount } from '../../hooks/useFocusOnMount';\nimport clsx from 'clsx';\nvar useStyles = makeStyles({\n button: {\n width: 95,\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '20px',\n textTransform: 'uppercase',\n letterSpacing: 1.25,\n color: Colors.purple,\n backgroundColor: Colors.white,\n boxShadow: '0 1.5px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.16)',\n cursor: 'pointer',\n elevation: 1,\n border: 0,\n '&:disabled': {\n color: 'rgba(0, 0, 0, 0.2)',\n backgroundColor: Colors.white,\n border: '1px solid rgba(0, 0, 0, 0.16)',\n boxShadow: 'none',\n cursor: 'not-allowed',\n elevation: 0,\n },\n '&:focus': {\n outline: 0,\n boxShadow: \"0px 0px 0px 1px \" + Colors.purple,\n background: 'linear-gradient(0deg, rgba(101, 78, 163, 0.08), rgba(101, 78, 163, 0.08)), #FFFFFF',\n },\n '&:active': {\n background: 'linear-gradient(0deg, rgba(101, 78, 163, 0.32), rgba(101, 78, 163, 0.32)), #FFFFFF',\n boxShadow: 'none',\n },\n '&:hover': {\n elevation: 3,\n background: Colors.white,\n boxShadow: '0 6.5px 16px 1px rgba(0,0,0,0.12), 0 4px 8px 0 rgba(0,0,0,0.08)',\n },\n },\n disabled: {\n width: 95,\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '20px',\n letterSpacing: 0.15,\n textTransform: 'uppercase',\n color: 'rgba(0, 0, 0, 0.2)',\n backgroundColor: Colors.white,\n border: '1px solid rgba(0, 0, 0, 0.16)',\n boxShadow: 'none',\n cursor: 'not-allowed',\n elevation: 0,\n },\n reportButton: {\n textTransform: 'capitalize',\n justifyContent: 'space-around',\n fontWeight: 500,\n },\n});\nvar SecondaryButton = function (_a) {\n var id = _a.id, onClick = _a.onClick, type = _a.type, disabled = _a.disabled, title = _a.title, key = _a.key, style = _a.style, children = _a.children, focusOnMount = _a.focusOnMount, tabIndex = _a.tabIndex, className = _a.className;\n var classes = useStyles();\n var focusRef = useFocusOnMount(focusOnMount);\n var getButtonClass = function () {\n switch (className) {\n case 'reportButton': {\n return clsx(classes.button, classes.reportButton);\n }\n default: {\n return classes.button;\n }\n }\n };\n return (_jsx(Button, __assign({ id: id, ref: focusRef, onClick: onClick, type: type, disabled: disabled, title: title, className: disabled ? classes.disabled : getButtonClass(), style: style, tabIndex: tabIndex }, { children: children }), key));\n};\nexport default SecondaryButton;\n//# sourceMappingURL=SecondaryButton.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { useState } from 'react';\nimport { nanoid } from 'nanoid/non-secure';\nexport var useUUID = function (prefix) {\n var _a = __read(useState(\"\" + (prefix ? prefix + '-' : '') + nanoid(10)), 1), id = _a[0];\n return id;\n};\n//# sourceMappingURL=useUUID.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar LoginIcon = function () {\n var id = useUUID('loginIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"220\", height: \"46\", viewBox: \"0 0 220 46\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Login\" }), void 0), _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M33 44.3389H27.3577V13.0972L48.5517 33.6535C52.3922 36.9118 55.9957 38.493 59.5517 38.493C67.8017 38.493 74.5345 31.6889 74.5345 23.3514C74.5345 15.0139 67.8017 8.20971 59.5517 8.20971H54.8577V2.55554H59.5517C70.931 2.55554 80.1767 11.8993 80.1767 23.3993C80.1767 34.8993 70.931 44.243 59.5517 44.243C54.5733 44.243 49.7845 42.1826 44.8534 37.966L44.7112 37.8701L33 26.5139V44.3389ZM24.3707 44.291H20.625C9.24569 44.291 0 34.9472 0 23.4472C0 11.9472 9.24569 2.60346 20.625 2.60346C21.2471 2.60346 21.8693 2.64555 22.5305 2.69028L22.6638 2.69929C26.4095 3.08263 29.9655 4.47221 33 6.77221L33.1897 6.91596L35.2759 8.78471L46.4181 19.2305V2.60346H52.1078V32.2639L31.4353 13.0014L29.4914 11.2764C27.3103 9.64721 24.75 8.68888 22.0948 8.40137C21.6207 8.35346 21.0991 8.30554 20.625 8.30554C12.375 8.35346 5.64224 15.1576 5.64224 23.4951C5.64224 31.8326 12.375 38.6368 20.625 38.6368H24.3707V44.291ZM98.431 8.73679L108.625 26.8014L108.388 8.73679H113.746V33.893H107.677L96.9612 14.8701L97.1983 33.893H91.8405V8.73679H98.431ZM134.75 30.1555C130.435 30.1555 129.155 28.2868 129.155 23.8305V8.73679H123.94V23.9264C123.94 27.0889 124.224 29.293 125.362 30.6826C127.401 33.1264 130.435 34.1326 134.75 34.1326C139.065 34.1326 142.052 33.1264 144.09 30.6826C145.228 29.341 145.56 27.1368 145.56 23.9264V8.73679H140.345V23.8305C140.345 28.2868 139.065 30.1555 134.75 30.1555ZM157.509 31.3055C155.612 29.293 155.233 27.0889 155.233 23.7347V8.73679H160.448V22.5368V23.4951C160.448 25.5555 160.496 27.0889 161.302 28.0472C162.392 29.3889 163.909 29.6764 166.138 29.6764H172.302V33.8451H165.664C162.108 33.941 159.737 33.6535 157.509 31.3055ZM180.362 8.73679V33.941L185.815 33.893V8.73679H180.362ZM208.905 8.73679L219.526 33.893H213.694L211.418 27.9035H200.608L198.379 33.893H192.832L203.358 8.73679H208.905ZM202.267 23.4472H209.711L205.918 13.768L202.267 23.4472Z\", fill: \"white\", \"aria-labelledby\": id, role: \"img\" }, void 0), _jsx(\"mask\", __assign({ id: \"mask0\", maskUnits: \"userSpaceOnUse\", x: \"0\", y: \"2\", width: \"220\", height: \"43\" }, { children: _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M33 44.3389H27.3577V13.0972L48.5517 33.6535C52.3922 36.9118 55.9957 38.493 59.5517 38.493C67.8017 38.493 74.5345 31.6889 74.5345 23.3514C74.5345 15.0139 67.8017 8.20971 59.5517 8.20971H54.8577V2.55554H59.5517C70.931 2.55554 80.1767 11.8993 80.1767 23.3993C80.1767 34.8993 70.931 44.243 59.5517 44.243C54.5733 44.243 49.7845 42.1826 44.8534 37.966L44.7112 37.8701L33 26.5139V44.3389ZM24.3707 44.291H20.625C9.24569 44.291 0 34.9472 0 23.4472C0 11.9472 9.24569 2.60346 20.625 2.60346C21.2471 2.60346 21.8693 2.64555 22.5305 2.69028L22.6638 2.69929C26.4095 3.08263 29.9655 4.47221 33 6.77221L33.1897 6.91596L35.2759 8.78471L46.4181 19.2305V2.60346H52.1078V32.2639L31.4353 13.0014L29.4914 11.2764C27.3103 9.64721 24.75 8.68888 22.0948 8.40137C21.6207 8.35346 21.0991 8.30554 20.625 8.30554C12.375 8.35346 5.64224 15.1576 5.64224 23.4951C5.64224 31.8326 12.375 38.6368 20.625 38.6368H24.3707V44.291ZM98.431 8.73679L108.625 26.8014L108.388 8.73679H113.746V33.893H107.677L96.9612 14.8701L97.1983 33.893H91.8405V8.73679H98.431ZM134.75 30.1555C130.435 30.1555 129.155 28.2868 129.155 23.8305V8.73679H123.94V23.9264C123.94 27.0889 124.224 29.293 125.362 30.6826C127.401 33.1264 130.435 34.1326 134.75 34.1326C139.065 34.1326 142.052 33.1264 144.09 30.6826C145.228 29.341 145.56 27.1368 145.56 23.9264V8.73679H140.345V23.8305C140.345 28.2868 139.065 30.1555 134.75 30.1555ZM157.509 31.3055C155.612 29.293 155.233 27.0889 155.233 23.7347V8.73679H160.448V22.5368V23.4951C160.448 25.5555 160.496 27.0889 161.302 28.0472C162.392 29.3889 163.909 29.6764 166.138 29.6764H172.302V33.8451H165.664C162.108 33.941 159.737 33.6535 157.509 31.3055ZM180.362 8.73679V33.941L185.815 33.893V8.73679H180.362ZM208.905 8.73679L219.526 33.893H213.694L211.418 27.9035H200.608L198.379 33.893H192.832L203.358 8.73679H208.905ZM202.267 23.4472H209.711L205.918 13.768L202.267 23.4472Z\", fill: \"white\" }, void 0) }), void 0), _jsx(\"g\", { mask: \"url(#mask0)\" }, void 0)] }), void 0));\n};\nexport default LoginIcon;\n//# sourceMappingURL=LoginIcon.js.map","import config from '../config.json';\nexport var VERSION = 'v2.5.2';\nexport var APPLICATION_ID = config.APPLICATION_ID;\nexport var PUBLISH_URL = config.PUBLISH_URL;\nexport var BADGE_URL = config.BADGE_URL;\nexport var BASE_API_URL = config.API_URL;\nexport var IMAGE_API_URL = config.IMAGE_API_URL;\nexport var CDN_URL = config.CDN_URL;\nexport var BLOB_CONTAINER = 'content';\nexport var BLOB_SAS_KEY = 'blob-sas';\nexport var MARKETING_URL = 'https://www.nulia.com/privacy/';\nexport var IMAGE_PATH = CDN_URL + 'appimages/';\nexport var ICON_PATH = IMAGE_PATH + 'icons/';\nexport var OUTCOMES_PATH = IMAGE_PATH + 'outcomes/';\nexport var SKILLS_PATH = IMAGE_PATH + 'skills/';\nexport var LOGOS_PATH = IMAGE_PATH + 'logos/';\nexport var BADGES_PATH = IMAGE_PATH + 'badges/';\nexport var ACHIEVEMENTS_PATH = IMAGE_PATH + 'achievements/';\nexport var OTHER_PATH = IMAGE_PATH + 'other/';\nexport var MOTD_PATH = IMAGE_PATH + 'motd/';\nexport var MARKETING_PATH = IMAGE_PATH + 'marketing/';\nexport var TEAMS_PATH = IMAGE_PATH + 'teams/';\nexport var targetLevels = [\n { name: 'User', level: 1 },\n { name: 'Producer', level: 2 },\n { name: 'Master', level: 3 },\n];\nexport var ENABLE_ANALYTICS = 'enable-analytics';\nexport var ACCEPTED_COOKIES = 'accepted-cookies';\nexport var GUIDED_TOUR_ID = 24658;\n//# sourceMappingURL=constants.js.map","import { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../utils/colors';\nexport var useTypography = makeStyles(function (theme) { return ({\n h1: {\n fontFamily: 'Ubuntu',\n fontSize: 96,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '104px',\n letterSpacing: -1.5,\n color: Colors.textPrimary,\n margin: 0,\n },\n h2: {\n fontFamily: 'Ubuntu',\n fontSize: 60,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '64px',\n letterSpacing: -0.5,\n color: Colors.textPrimary,\n margin: 0,\n },\n h3: {\n fontFamily: 'Ubuntu',\n fontSize: 48,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '56px',\n color: Colors.textPrimary,\n margin: 0,\n },\n h4: {\n fontFamily: 'Ubuntu',\n fontSize: 32,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '40px',\n letterSpacing: 0.25,\n color: Colors.textPrimary,\n margin: 0,\n },\n h5: {\n fontFamily: 'Ubuntu',\n fontSize: 24,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '28px',\n letterSpacing: 'normal',\n color: Colors.textPrimary,\n margin: 0,\n },\n h6: {\n fontFamily: 'Ubuntu',\n fontWeight: 400,\n fontStyle: 'normal',\n fontSize: 20,\n lineHeight: '24px',\n letterSpacing: 0.25,\n color: Colors.textPrimary,\n margin: 0,\n },\n body1: {\n fontFamily: 'Open Sans',\n fontSize: 16,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0,\n color: Colors.textSecondary,\n margin: 0,\n },\n body2: {\n fontFamily: 'Open Sans',\n fontSize: 14,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '21px',\n letterSpacing: 0.25,\n color: Colors.textSecondary,\n margin: 0,\n },\n subtitle1: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 500,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0.15,\n color: Colors.textPrimary,\n margin: 0,\n },\n subtitle2: {\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0.1,\n color: Colors.textPrimary,\n margin: 0,\n },\n overline: {\n fontFamily: 'Ubuntu',\n fontSize: 12,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '16px',\n letterSpacing: 2,\n color: Colors.textSecondary,\n textTransform: 'uppercase',\n margin: 0,\n },\n overlineMini: {\n fontFamily: 'Ubuntu',\n fontSize: 10,\n fontWeight: 500,\n fontStyle: 'normal',\n lineHeight: '40px',\n letterSpacing: 1.25,\n color: Colors.textSecondary,\n textTransform: 'uppercase',\n margin: 0,\n },\n caption: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '20px',\n letterSpacing: 0.5,\n color: Colors.textSecondary,\n margin: 0,\n },\n label: {\n fontFamily: 'Open Sans',\n fontSize: 10,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '20px',\n letterSpacing: 0.5,\n color: Colors.textSecondary,\n margin: 0,\n },\n button: {\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 500,\n fontStyle: 'normal',\n lineHeight: '16px',\n letterSpacing: 1.25,\n color: Colors.textPrimary,\n textTransform: 'uppercase',\n margin: 0,\n },\n}); });\n//# sourceMappingURL=Typography.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport LoginIcon from '../icons/LoginIcon';\nimport { useMsal } from '@azure/msal-react';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { MARKETING_PATH } from '../../utils/constants';\nimport { Colors } from '../../utils/colors';\nimport { useTypography } from '../../styles/Typography';\nimport clsx from 'clsx';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n root: (_a = {\n height: '100vh',\n backgroundColor: Colors.purple,\n backgroundImage: \"url(\" + MARKETING_PATH + \"teams_no_access.png)\",\n backgroundRepeat: 'no-repeat',\n backgroundSize: 'contain',\n backgroundPosition: 'right top',\n padding: 32\n },\n _a[theme.breakpoints.down('md')] = {\n backgroundImage: 'none',\n },\n _a),\n main: {\n height: '100%',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start',\n justifyContent: 'center',\n },\n text: {\n color: Colors.white,\n marginBottom: 16,\n },\n });\n});\nvar Login = function () {\n var classes = useStyles();\n var typo = useTypography();\n var msalInstance = useMsal();\n var login = function () {\n msalInstance.instance.loginPopup();\n };\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsx(\"header\", { children: _jsx(LoginIcon, {}, void 0) }, void 0), _jsxs(\"main\", __assign({ className: classes.main }, { children: [_jsx(\"h1\", __assign({ className: clsx(typo.h4, classes.text) }, { children: \"Welcome to Nulia Works!\" }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.body1, classes.text) }, { children: \"Unlocking the Value of Digital Productivity Suites\" }), void 0), _jsx(SecondaryButton, __assign({ onClick: login }, { children: \"Login\" }), void 0)] }), void 0)] }), void 0));\n};\nexport default Login;\n//# sourceMappingURL=Login.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { CircularProgress } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { Colors } from '../utils/colors';\nvar useStyles = makeStyles({\n loading: {\n height: '100vh',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n colorPrimary: {\n backgroundColor: Colors.purple,\n },\n});\nvar Loading = function (_a) {\n var smallHeight = _a.smallHeight;\n var classes = useStyles();\n return (_jsx(\"div\", __assign({ className: clsx(classes.loading), style: { height: smallHeight ? 'unset' : 'inherit' } }, { children: _jsx(CircularProgress, { \"aria-label\": \"loading\", classes: {\n colorSecondary: classes.colorPrimary,\n } }, void 0) }), void 0));\n};\nexport default Loading;\n//# sourceMappingURL=Loading.js.map","export var LicenseDataType;\n(function (LicenseDataType) {\n LicenseDataType[\"Complete\"] = \"Complete\";\n LicenseDataType[\"Starter\"] = \"Starter\";\n LicenseDataType[\"StarterComplete\"] = \"StarterComplete\";\n LicenseDataType[\"CompleteWithTerm\"] = \"CompleteWithTerm\";\n LicenseDataType[\"StarterWithTerm\"] = \"StarterWithTerm\";\n LicenseDataType[\"StarterCompleteWithTerm\"] = \"StarterCompleteWithTerm\";\n})(LicenseDataType || (LicenseDataType = {}));\nexport var TelemetryCode;\n(function (TelemetryCode) {\n TelemetryCode[\"Unknown\"] = \"Unknown\";\n TelemetryCode[\"PLI\"] = \"PLI\";\n})(TelemetryCode || (TelemetryCode = {}));\nexport var TelemetryStatus;\n(function (TelemetryStatus) {\n TelemetryStatus[\"Unknown\"] = \"Unknown\";\n TelemetryStatus[\"Success\"] = \"Success\";\n TelemetryStatus[\"Error\"] = \"Error\";\n})(TelemetryStatus || (TelemetryStatus = {}));\nexport var TabName;\n(function (TabName) {\n TabName[\"Yours\"] = \"Yours\";\n TabName[\"All\"] = \"All\";\n})(TabName || (TabName = {}));\nexport var InsightsTabName;\n(function (InsightsTabName) {\n InsightsTabName[\"Assessment\"] = \"Assess\";\n InsightsTabName[\"Users\"] = \"Users\";\n InsightsTabName[\"Outcomes\"] = \"Outcomes\";\n InsightsTabName[\"Licenses\"] = \"Licenses\";\n InsightsTabName[\"History\"] = \"History\";\n})(InsightsTabName || (InsightsTabName = {}));\nexport var BulkAssignPanel;\n(function (BulkAssignPanel) {\n BulkAssignPanel[\"Unknown\"] = \"Unknown\";\n BulkAssignPanel[\"OutcomePicker\"] = \"OutcomePicker\";\n BulkAssignPanel[\"TargetLevelPicker\"] = \"TargetLevelPicker\";\n BulkAssignPanel[\"Confirm\"] = \"Confirm\";\n})(BulkAssignPanel || (BulkAssignPanel = {}));\nexport var LicenseChangeType;\n(function (LicenseChangeType) {\n LicenseChangeType[\"Unknown\"] = \"Unknown\";\n LicenseChangeType[\"SystemRemove\"] = \"SystemRemove\";\n LicenseChangeType[\"AddCompleteUserPortal\"] = \"AddCompleteUserPortal\";\n LicenseChangeType[\"UpgradeUserPortal\"] = \"UpgradeUserPortal\";\n LicenseChangeType[\"AddSystemStarter\"] = \"AddSystemStarter\";\n LicenseChangeType[\"AddSystemComplete\"] = \"AddSystemComplete\";\n LicenseChangeType[\"UpgradeSystem\"] = \"UpgradeSystem\";\n LicenseChangeType[\"PortalRemoveComplete\"] = \"PortalRemoveComplete\";\n LicenseChangeType[\"PortalDowngradeToStarter\"] = \"PortalDowngradeToStarter\";\n})(LicenseChangeType || (LicenseChangeType = {}));\nexport var InsightsStatus;\n(function (InsightsStatus) {\n InsightsStatus[InsightsStatus[\"NeedsAttention\"] = -1] = \"NeedsAttention\";\n InsightsStatus[InsightsStatus[\"Steady\"] = 0] = \"Steady\";\n InsightsStatus[InsightsStatus[\"ReadyForMore\"] = 1] = \"ReadyForMore\";\n})(InsightsStatus || (InsightsStatus = {}));\nexport var InsightsOutcomeStatus;\n(function (InsightsOutcomeStatus) {\n InsightsOutcomeStatus[InsightsOutcomeStatus[\"Locked\"] = 0] = \"Locked\";\n InsightsOutcomeStatus[InsightsOutcomeStatus[\"Unassigned\"] = 1] = \"Unassigned\";\n InsightsOutcomeStatus[InsightsOutcomeStatus[\"InProgress\"] = 2] = \"InProgress\";\n InsightsOutcomeStatus[InsightsOutcomeStatus[\"Maintain\"] = 3] = \"Maintain\";\n InsightsOutcomeStatus[InsightsOutcomeStatus[\"NeedAttention\"] = 4] = \"NeedAttention\";\n})(InsightsOutcomeStatus || (InsightsOutcomeStatus = {}));\nexport var InsightsAssignmentType;\n(function (InsightsAssignmentType) {\n InsightsAssignmentType[InsightsAssignmentType[\"NotAssigned\"] = 0] = \"NotAssigned\";\n InsightsAssignmentType[InsightsAssignmentType[\"SelfAssigned\"] = 1] = \"SelfAssigned\";\n InsightsAssignmentType[InsightsAssignmentType[\"OrgAssigned\"] = 2] = \"OrgAssigned\";\n})(InsightsAssignmentType || (InsightsAssignmentType = {}));\nexport var InsightsOutcomesDetailStatus;\n(function (InsightsOutcomesDetailStatus) {\n InsightsOutcomesDetailStatus[InsightsOutcomesDetailStatus[\"NotAssigned\"] = 0] = \"NotAssigned\";\n InsightsOutcomesDetailStatus[InsightsOutcomesDetailStatus[\"InProgress\"] = 1] = \"InProgress\";\n InsightsOutcomesDetailStatus[InsightsOutcomesDetailStatus[\"Maintained\"] = 2] = \"Maintained\";\n InsightsOutcomesDetailStatus[InsightsOutcomesDetailStatus[\"NeedAttention\"] = 3] = \"NeedAttention\";\n})(InsightsOutcomesDetailStatus || (InsightsOutcomesDetailStatus = {}));\n//# sourceMappingURL=types.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { createTheme, ThemeProvider } from '@material-ui/core';\nimport { Colors } from '../utils/colors';\nimport { CssBaseline } from '@material-ui/core';\nimport { ClientType } from '../types/enums';\nvar NuliaTheme = function (_a) {\n var clientType = _a.clientType, children = _a.children;\n var theme = createTheme({\n breakpoints: {\n values: clientType === ClientType.platform\n ? {\n xs: 0,\n sm: 600,\n md: 720,\n lg: 1200,\n xl: 1920,\n }\n : {\n xs: 0,\n sm: 600,\n md: 700,\n lg: 1080,\n xl: 1920,\n },\n },\n typography: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n button: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 500,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0.15,\n color: Colors.textPrimary,\n margin: 0,\n },\n h1: {\n fontFamily: 'Ubuntu',\n fontSize: 96,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '104px',\n letterSpacing: -1.5,\n color: Colors.textPrimary,\n margin: 0,\n },\n h2: {\n fontFamily: 'Ubuntu',\n fontSize: 60,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '64px',\n letterSpacing: -0.5,\n color: Colors.textPrimary,\n margin: 0,\n },\n h3: {\n fontFamily: 'Ubuntu',\n fontSize: 48,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '56px',\n color: Colors.textPrimary,\n margin: 0,\n },\n h4: {\n fontFamily: 'Ubuntu',\n fontSize: 32,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '40px',\n letterSpacing: 0.25,\n color: Colors.textPrimary,\n margin: 0,\n },\n h5: {\n fontFamily: 'Ubuntu',\n fontSize: 24,\n fontWeight: 600,\n fontStyle: 'normal',\n lineHeight: '28px',\n letterSpacing: 'normal',\n color: Colors.textPrimary,\n margin: 0,\n },\n h6: {\n fontFamily: 'Ubuntu',\n fontWeight: 400,\n fontStyle: 'normal',\n fontSize: 20,\n lineHeight: '24px',\n letterSpacing: 0.25,\n color: Colors.textPrimary,\n margin: 0,\n },\n body1: {\n fontFamily: 'Open Sans',\n fontSize: 16,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0,\n color: Colors.textSecondary,\n margin: 0,\n },\n body2: {\n fontFamily: 'Open Sans',\n fontSize: 14,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '21px',\n letterSpacing: 0.25,\n color: Colors.textSecondary,\n margin: 0,\n },\n subtitle1: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 500,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0.15,\n color: Colors.textPrimary,\n margin: 0,\n },\n subtitle2: {\n fontFamily: 'Ubuntu',\n fontSize: 14,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '24px',\n letterSpacing: 0.1,\n color: Colors.textPrimary,\n margin: 0,\n },\n overline: {\n fontFamily: 'Ubuntu',\n fontSize: 12,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '16px',\n letterSpacing: 2,\n color: Colors.textSecondary,\n textTransform: 'uppercase',\n margin: 0,\n },\n caption: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 400,\n fontStyle: 'normal',\n lineHeight: '20px',\n letterSpacing: 0.5,\n color: Colors.textSecondary,\n margin: 0,\n },\n },\n palette: {\n primary: {\n light: Colors.lightPurple,\n main: Colors.purple,\n dark: Colors.darkPurple,\n contrastText: '#fff',\n },\n secondary: {\n light: Colors.lightPurple,\n main: Colors.purple,\n dark: Colors.darkPurple,\n contrastText: '#fff',\n },\n },\n overrides: {\n MuiIconButton: {\n root: {\n padding: 0,\n },\n },\n MuiButtonBase: {\n root: {\n '&$focusVisible': {\n outline: 0,\n boxShadow: \"0px 0px 0px 1px \" + Colors.purple,\n },\n },\n },\n MuiLink: {\n root: {\n '&$focusVisible': {\n background: 'linear-gradient(0deg, rgba(101, 78, 163, 0.08), rgba(101, 78, 163, 0.08)), #FFFFFF',\n boxShadow: \"0px 0px 0px 1px \" + Colors.purple,\n borderRadius: 2,\n outline: 0,\n },\n },\n },\n MuiAccordionSummary: {\n root: {\n padding: '2px 16px',\n '&$focused': {\n backgroundColor: 'initial',\n borderRadius: 2,\n },\n },\n },\n MuiTableCell: {\n root: {\n padding: 0,\n },\n },\n MuiInputBase: {\n root: {\n '&$focused': {\n outline: Colors.purple + \" auto 1px;\",\n },\n },\n },\n },\n props: {\n MuiButtonBase: {\n disableRipple: true,\n },\n },\n });\n return (_jsxs(ThemeProvider, __assign({ theme: theme }, { children: [_jsx(CssBaseline, {}, void 0), children] }), void 0));\n};\nexport default NuliaTheme;\n//# sourceMappingURL=NuliaTheme.js.map","import config from '../config.json';\nexport var msalConfig = {\n auth: {\n clientId: config.PLATFORM_APP_ID,\n redirectUri: location.hostname === 'localhost' ? undefined : \"https://\" + location.hostname + \"/\",\n },\n};\n//# sourceMappingURL=authConfig.js.map","export var ResultCode;\n(function (ResultCode) {\n ResultCode[ResultCode[\"Success\"] = 0] = \"Success\";\n ResultCode[ResultCode[\"UnknownError\"] = 1] = \"UnknownError\";\n ResultCode[ResultCode[\"NotAuthorized\"] = 2] = \"NotAuthorized\";\n ResultCode[ResultCode[\"AuthenticateFailure\"] = 3] = \"AuthenticateFailure\";\n ResultCode[ResultCode[\"ClaimNotFound\"] = 4] = \"ClaimNotFound\";\n ResultCode[ResultCode[\"ApiTokenFailure\"] = 5] = \"ApiTokenFailure\";\n ResultCode[ResultCode[\"NotFound\"] = 6] = \"NotFound\";\n ResultCode[ResultCode[\"RecordExists\"] = 7] = \"RecordExists\";\n ResultCode[ResultCode[\"MissingNotification\"] = 10] = \"MissingNotification\";\n ResultCode[ResultCode[\"NoLicenseAvailable\"] = 11] = \"NoLicenseAvailable\";\n ResultCode[ResultCode[\"WithinTwoWeekPeriod\"] = 12] = \"WithinTwoWeekPeriod\";\n ResultCode[ResultCode[\"NotInstalledTenant\"] = 13] = \"NotInstalledTenant\";\n ResultCode[ResultCode[\"InvalidParent\"] = 50] = \"InvalidParent\";\n ResultCode[ResultCode[\"InvalidRelationship\"] = 51] = \"InvalidRelationship\";\n ResultCode[ResultCode[\"InvalidLicense\"] = 52] = \"InvalidLicense\";\n ResultCode[ResultCode[\"InvalidCustomer\"] = 53] = \"InvalidCustomer\";\n ResultCode[ResultCode[\"InvalidApplication\"] = 54] = \"InvalidApplication\";\n ResultCode[ResultCode[\"InvalidTenant\"] = 55] = \"InvalidTenant\";\n ResultCode[ResultCode[\"InvalidReseller\"] = 56] = \"InvalidReseller\";\n ResultCode[ResultCode[\"InvalidResellerData\"] = 57] = \"InvalidResellerData\";\n ResultCode[ResultCode[\"InvalidUser\"] = 58] = \"InvalidUser\";\n ResultCode[ResultCode[\"InvalidOrder\"] = 59] = \"InvalidOrder\";\n ResultCode[ResultCode[\"InvalidHeader\"] = 60] = \"InvalidHeader\";\n ResultCode[ResultCode[\"InvalidKey\"] = 61] = \"InvalidKey\";\n ResultCode[ResultCode[\"InvalidData\"] = 62] = \"InvalidData\";\n ResultCode[ResultCode[\"UserNotFound\"] = 100] = \"UserNotFound\";\n ResultCode[ResultCode[\"UserInactive\"] = 101] = \"UserInactive\";\n ResultCode[ResultCode[\"UserMeasureOnly\"] = 102] = \"UserMeasureOnly\";\n ResultCode[ResultCode[\"NotEnoughEngagementPoints\"] = 103] = \"NotEnoughEngagementPoints\";\n ResultCode[ResultCode[\"NoImageFound\"] = 104] = \"NoImageFound\";\n ResultCode[ResultCode[\"UserLicenseTypeNotStarter\"] = 105] = \"UserLicenseTypeNotStarter\";\n ResultCode[ResultCode[\"UserDataNotComplete\"] = 106] = \"UserDataNotComplete\";\n ResultCode[ResultCode[\"NoLicense\"] = 107] = \"NoLicense\";\n ResultCode[ResultCode[\"UserExists\"] = 108] = \"UserExists\";\n ResultCode[ResultCode[\"UserIsStarter\"] = 109] = \"UserIsStarter\";\n ResultCode[ResultCode[\"UserBadgeNotFound\"] = 110] = \"UserBadgeNotFound\";\n ResultCode[ResultCode[\"UserBadgeUrlMissing\"] = 111] = \"UserBadgeUrlMissing\";\n ResultCode[ResultCode[\"UserBadgeInvalidAssertion\"] = 112] = \"UserBadgeInvalidAssertion\";\n ResultCode[ResultCode[\"LowerCollectorVersion\"] = 113] = \"LowerCollectorVersion\";\n ResultCode[ResultCode[\"NoEduLicense\"] = 114] = \"NoEduLicense\";\n ResultCode[ResultCode[\"InvalidSkill\"] = 200] = \"InvalidSkill\";\n ResultCode[ResultCode[\"SkillLevelLocked\"] = 201] = \"SkillLevelLocked\";\n ResultCode[ResultCode[\"PreviousSkillLevelLocked\"] = 202] = \"PreviousSkillLevelLocked\";\n ResultCode[ResultCode[\"SkillNotActive\"] = 203] = \"SkillNotActive\";\n ResultCode[ResultCode[\"MissingSkillLevels\"] = 204] = \"MissingSkillLevels\";\n ResultCode[ResultCode[\"MissingUserSkill\"] = 205] = \"MissingUserSkill\";\n ResultCode[ResultCode[\"MustUnlockLowerSkillLevel\"] = 210] = \"MustUnlockLowerSkillLevel\";\n ResultCode[ResultCode[\"SkillLevelNotAvailable\"] = 211] = \"SkillLevelNotAvailable\";\n ResultCode[ResultCode[\"MissingUserOutcome\"] = 301] = \"MissingUserOutcome\";\n ResultCode[ResultCode[\"OutcomeAlreadySet\"] = 302] = \"OutcomeAlreadySet\";\n ResultCode[ResultCode[\"CustomerNotFound\"] = 400] = \"CustomerNotFound\";\n ResultCode[ResultCode[\"TenantNotFound\"] = 401] = \"TenantNotFound\";\n ResultCode[ResultCode[\"ResellerNotFound\"] = 402] = \"ResellerNotFound\";\n ResultCode[ResultCode[\"CustomerConnected\"] = 403] = \"CustomerConnected\";\n ResultCode[ResultCode[\"CustomerNotStarter\"] = 404] = \"CustomerNotStarter\";\n ResultCode[ResultCode[\"CustomerExists\"] = 405] = \"CustomerExists\";\n ResultCode[ResultCode[\"ResellerExists\"] = 406] = \"ResellerExists\";\n ResultCode[ResultCode[\"MissingTenant\"] = 407] = \"MissingTenant\";\n ResultCode[ResultCode[\"TenantNotActive\"] = 408] = \"TenantNotActive\";\n ResultCode[ResultCode[\"NoInvoice\"] = 409] = \"NoInvoice\";\n ResultCode[ResultCode[\"CustomerIsLicenseSync\"] = 410] = \"CustomerIsLicenseSync\";\n ResultCode[ResultCode[\"MustAcceptTrial\"] = 411] = \"MustAcceptTrial\";\n ResultCode[ResultCode[\"TenantExists\"] = 412] = \"TenantExists\";\n ResultCode[ResultCode[\"DuplicateTenantId\"] = 413] = \"DuplicateTenantId\";\n ResultCode[ResultCode[\"CannotUnassignManagerAssignedSkill\"] = 501] = \"CannotUnassignManagerAssignedSkill\";\n ResultCode[ResultCode[\"SkillAssignmentNotFound\"] = 502] = \"SkillAssignmentNotFound\";\n ResultCode[ResultCode[\"CannotUnassignOutcomeAssignedSkill\"] = 503] = \"CannotUnassignOutcomeAssignedSkill\";\n ResultCode[ResultCode[\"ManagerSkillAssignmentNotFound\"] = 504] = \"ManagerSkillAssignmentNotFound\";\n ResultCode[ResultCode[\"CannotUnassignManagerAssignedOutcome\"] = 505] = \"CannotUnassignManagerAssignedOutcome\";\n ResultCode[ResultCode[\"OutcomeAssignmentNotFound\"] = 506] = \"OutcomeAssignmentNotFound\";\n ResultCode[ResultCode[\"ManagerOutcomeAssignmentNotFound\"] = 507] = \"ManagerOutcomeAssignmentNotFound\";\n ResultCode[ResultCode[\"CannotUnassignUserSelectedOutcome\"] = 508] = \"CannotUnassignUserSelectedOutcome\";\n ResultCode[ResultCode[\"NoHigherOutcomeLevels\"] = 509] = \"NoHigherOutcomeLevels\";\n ResultCode[ResultCode[\"NoHigherSkillLevel\"] = 510] = \"NoHigherSkillLevel\";\n ResultCode[ResultCode[\"CannotUnassignSystemAssignedOutcome\"] = 511] = \"CannotUnassignSystemAssignedOutcome\";\n ResultCode[ResultCode[\"NoMotd\"] = 600] = \"NoMotd\";\n ResultCode[ResultCode[\"NotMatchingLicenseTypes\"] = 700] = \"NotMatchingLicenseTypes\";\n ResultCode[ResultCode[\"NoBadge\"] = 800] = \"NoBadge\";\n ResultCode[ResultCode[\"NoStreaks\"] = 801] = \"NoStreaks\";\n ResultCode[ResultCode[\"NoAchievements\"] = 802] = \"NoAchievements\";\n ResultCode[ResultCode[\"GroupAlreadyExists\"] = 900] = \"GroupAlreadyExists\";\n ResultCode[ResultCode[\"NotPartOfGroupOrAdmin\"] = 901] = \"NotPartOfGroupOrAdmin\";\n ResultCode[ResultCode[\"UserAlreadyPartOfGroup\"] = 902] = \"UserAlreadyPartOfGroup\";\n})(ResultCode || (ResultCode = {}));\n//# sourceMappingURL=ResultCode.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var HomeContext = createContext({});\nexport var HomeProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), skills = _b[0], setSkills = _b[1];\n var _c = __read(useState(undefined), 2), homeActivities = _c[0], setHomeActivities = _c[1];\n var _d = __read(useState(undefined), 2), motds = _d[0], setMotds = _d[1];\n var _e = __read(useState(undefined), 2), badges = _e[0], setBadges = _e[1];\n var _f = __read(useState(undefined), 2), achievements = _f[0], setAchievements = _f[1];\n var _g = __read(useState(undefined), 2), streaks = _g[0], setStreaks = _g[1];\n var homeContext = {\n skills: skills,\n setSkills: setSkills,\n homeActivities: homeActivities,\n setHomeActivities: setHomeActivities,\n motds: motds,\n setMotds: setMotds,\n badges: badges,\n setBadges: setBadges,\n achievements: achievements,\n setAchievements: setAchievements,\n streaks: streaks,\n setStreaks: setStreaks,\n };\n return _jsx(HomeContext.Provider, __assign({ value: homeContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=HomeContext.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { IconButton } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../../utils/colors';\nimport { ArrowLeft } from 'react-feather';\nvar useStyles = makeStyles({\n helpButton: {\n height: 24,\n width: 24,\n color: Colors.textSecondary,\n '&:hover': {\n color: Colors.purple,\n },\n '&:focus': {\n color: Colors.textSecondary,\n outline: 0,\n backgroundColor: Colors.lightPurple,\n },\n '&:active': {\n color: Colors.purple,\n },\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n cursor: 'pointer',\n },\n});\nvar BackButton = function (_a) {\n var onClick = _a.onClick, style = _a.style, label = _a.label;\n var classes = useStyles();\n return (_jsx(IconButton, __assign({ style: style, className: classes.helpButton, onClick: onClick, \"aria-label\": label }, { children: _jsx(ArrowLeft, {}, void 0) }), void 0));\n};\nexport default BackButton;\n//# sourceMappingURL=BackButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { Tab, Tabs as MuiTabs } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useEffect, useRef } from 'react';\nimport { Link } from 'react-router-dom';\nimport { Colors } from '../utils/colors';\nimport { useTeams } from 'msteams-react-base-component';\nvar useStyles = makeStyles(function (theme) { return ({\n tabs: {\n height: '100%',\n },\n root: {\n height: '100%',\n },\n flexContainer: {\n height: '100%',\n alignItems: 'center',\n },\n margin: {\n margin: 8,\n },\n tabRoot: {\n width: 96,\n maxWidth: 96,\n minWidth: 96,\n height: 48,\n fontSize: 12,\n color: Colors.textSecondary,\n opacity: 1,\n fontWeight: 600,\n letterSpacing: 1,\n lineHeight: '16px',\n '&:hover': {\n color: Colors.textPrimary,\n backgroundColor: 'rgba(0, 0, 0, 0.04)',\n },\n '&:focus': {\n color: Colors.purple,\n outline: 0,\n backgroundColor: Colors.lightPurple,\n },\n '&:active': {\n color: Colors.purple,\n },\n },\n selected: {\n color: Colors.purple,\n },\n indicator: {\n display: 'flex',\n justifyContent: 'center',\n height: 4,\n backgroundColor: 'transparent',\n '& > span': {\n maxWidth: 32,\n width: '100%',\n backgroundColor: Colors.purple,\n borderRadius: 4,\n },\n },\n detailedTab: {\n display: 'flex',\n alignItems: 'end',\n paddingBottom: 0,\n },\n detailedTabNameBox: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'space-between',\n },\n detailedTabNameDescriptionBox: {\n color: Colors.iconDefault,\n fontWeight: 500,\n fontSize: 10,\n },\n}); });\nvar Tabs = function (_a) {\n var tabs = _a.tabs, style = _a.style;\n var classes = useStyles();\n var tabsRef = useRef(null);\n var _b = __read(useTeams(), 1), inTeams = _b[0].inTeams;\n useEffect(function () {\n if (tabsRef.current && inTeams) {\n var indicators = tabsRef.current.getElementsByClassName('MuiButtonBase-root');\n if (indicators && indicators[0]) {\n indicators[0].click();\n }\n }\n }, [inTeams]);\n if (tabs[0].to === undefined && tabs[0].onClick !== undefined) {\n return (_jsx(MuiTabs, __assign({ color: \"primary\", value: true, TabIndicatorProps: { children: _jsx(\"span\", {}, void 0) }, classes: { root: classes.root, flexContainer: classes.flexContainer, indicator: classes.indicator } }, { children: tabs.map(function (tab, index) { return (_jsx(Tab, { className: classes.margin, onClick: tab.onClick, value: tab.selected, label: tab.name, classes: {\n root: classes.tabRoot,\n selected: classes.selected,\n } }, tab.name + \"-\" + index)); }) }), void 0));\n }\n return (_jsx(\"nav\", __assign({ className: classes.tabs }, { children: _jsx(MuiTabs, __assign({ ref: tabsRef, color: \"primary\", value: location.pathname, TabIndicatorProps: { children: _jsx(\"span\", {}, void 0) }, classes: { root: classes.root, flexContainer: classes.flexContainer, indicator: classes.indicator } }, { children: tabs.map(function (tab, index) {\n return (tab === null || tab === void 0 ? void 0 : tab.to) !== undefined ? (_jsx(Tab, { className: classes.margin, component: Link, selected: tab.selected, value: tab.to, to: tab.to, label: tab.name, classes: {\n root: classes.tabRoot,\n selected: classes.selected,\n } }, tab.name + \"-\" + index)) : undefined;\n }) }), void 0) }), void 0));\n};\nexport default Tabs;\n//# sourceMappingURL=Tabs.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar OutcomesIcon = function () {\n var id = useUUID('outcomesIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"24px\", height: \"20px\", viewBox: \"0 0 24 20\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Outcomes\" }), void 0), _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-36.000000, -274.000000)\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(0.000000, 252.000000)\" }, { children: _jsxs(\"g\", __assign({ transform: \"translate(36.000000, 20.000000)\" }, { children: [_jsx(\"rect\", { id: \"frame\", x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M20.5,10.2 C19.9477153,10.2 19.5,9.75228475 19.5,9.2 C19.5,8.64771525 19.9477153,8.2 20.5,8.2 L21.5,8.2 C22.0522847,8.2 22.5,8.64771525 22.5,9.2 C22.5,9.75228475 22.0522847,10.2 21.5,10.2 L20.5,10.2 Z M1.5,10.2 C0.94771525,10.2 0.5,9.75228475 0.5,9.2 C0.5,8.64771525 0.94771525,8.2 1.5,8.2 L12.5,8.2 C13.0522847,8.2 13.5,8.64771525 13.5,9.2 C13.5,9.75228475 13.0522847,10.2 12.5,10.2 L1.5,10.2 Z M1.5,4.2 C0.94771525,4.2 0.5,3.75228475 0.5,3.2 C0.5,2.64771525 0.94771525,2.2 1.5,2.2 L21.5,2.2 C22.0522847,2.2 22.5,2.64771525 22.5,3.2 C22.5,3.75228475 22.0522847,4.2 21.5,4.2 L1.5,4.2 Z M1.5,16.2 C0.94771525,16.2 0.5,15.7522847 0.5,15.2 C0.5,14.6477153 0.94771525,14.2 1.5,14.2 L7.5,14.2 C8.05228475,14.2 8.5,14.6477153 8.5,15.2 C8.5,15.7522847 8.05228475,16.2 7.5,16.2 L1.5,16.2 Z M15.6099216,9.26419249 C15.9814949,8.5386025 17.0185051,8.5386025 17.3900784,9.26419249 L19.0074892,12.4225925 L22.6395103,12.9343009 C23.4708423,13.0514257 23.7965285,14.0789398 23.1844595,14.6535725 L20.5794475,17.0992523 L21.1925357,20.5448161 C21.3370362,21.3569107 20.4915922,21.9848927 19.7558667,21.6119504 L16.5,19.9615382 L13.2441333,21.6119504 C12.5084078,21.9848927 11.6629638,21.3569107 11.8074643,20.5448161 L12.4205525,17.0992523 L9.81554053,14.6535725 C9.20347148,14.0789398 9.52915765,13.0514257 10.3604897,12.9343009 L13.9925108,12.4225925 L15.6099216,9.26419249 Z M15.5360784,13.7962071 C15.3877479,14.0858596 15.1077514,14.2852203 14.7855103,14.3306202 L12.7056761,14.623644 L14.1844595,16.0119796 C14.4308649,16.2433139 14.5437446,16.5834599 14.4845357,16.9162144 L14.12767,18.9218048 L16.0478667,17.9484492 C16.3320746,17.804383 16.6679254,17.804383 16.9521333,17.9484492 L18.87233,18.9218048 L18.5154643,16.9162144 C18.4562554,16.5834599 18.5691351,16.2433139 18.8155405,16.0119796 L20.2943239,14.623644 L18.2144897,14.3306202 C17.8922486,14.2852203 17.6122521,14.0858596 17.4639216,13.7962071 L16.5,11.9139086 L15.5360784,13.7962071 Z\", fill: \"currentColor\", fillRule: \"nonzero\" }, void 0)] }), void 0) }), void 0) }), void 0) }), void 0)] }), void 0));\n};\nexport default OutcomesIcon;\n//# sourceMappingURL=OutcomesIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/styles';\nimport { Colors } from '../../utils/colors';\nimport { Button } from '@material-ui/core';\nimport clsx from 'clsx';\nvar useStyles = makeStyles({\n button: {\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontSize: 14,\n letterSpacing: 1.25,\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n lineHeight: '16px',\n textTransform: 'uppercase',\n color: Colors.textSecondary,\n backgroundColor: 'transparent',\n boxShadow: 'none',\n cursor: 'pointer',\n border: 0,\n outline: 0,\n display: 'flex',\n alignItems: 'center',\n '&:hover': {\n color: Colors.textPrimary,\n },\n '&:focus': {\n backgroundColor: 'rgba(101,78,163,0.08)',\n boxShadow: \"0px 0px 0px 1px \" + Colors.purple,\n },\n '&:active': {\n color: Colors.purple,\n },\n },\n purple: {\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontSize: 14,\n letterSpacing: 1.25,\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n lineHeight: '16px',\n textTransform: 'uppercase',\n color: Colors.purple,\n backgroundColor: 'transparent',\n boxShadow: 'none',\n cursor: 'pointer',\n border: 0,\n outline: 0,\n display: 'flex',\n alignItems: 'center',\n '&:hover': {\n color: 'rgba(101,78,163,0.88)',\n },\n '&:focus': {\n backgroundColor: \"linear-gradient(0deg, \" + Colors.lightPurple + \",\" + Colors.lightPurple + \"), #FFFFFF\",\n boxShadow: \"0px 0px 0px 1px \" + Colors.purple,\n },\n '&:active': {\n color: Colors.darkPurple,\n },\n },\n disabled: {\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n borderRadius: 4,\n fontSize: 14,\n letterSpacing: 1.25,\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n lineHeight: '16px',\n textTransform: 'uppercase',\n backgroundColor: 'transparent',\n boxShadow: 'none',\n border: 0,\n outline: 0,\n color: Colors.disabled,\n cursor: 'not-allowed',\n display: 'flex',\n alignItems: 'center',\n },\n reportButton: {\n textDecoration: 'underline',\n textTransform: 'capitalize',\n border: 'none',\n outline: 'none',\n '&:focus': {\n backgroundColor: 'transparent !important',\n boxShadow: 'none !important',\n },\n '&:hover': {\n backgroundColor: 'transparent !important',\n },\n },\n});\nvar TextButton = function (_a) {\n var id = _a.id, onClick = _a.onClick, disabled = _a.disabled, title = _a.title, key = _a.key, style = _a.style, children = _a.children, variant = _a.variant, tabIndex = _a.tabIndex, className = _a.className;\n var classes = useStyles();\n var getButtonClass = function () {\n switch (className) {\n case 'reportButton': {\n if (variant === 'purple') {\n return clsx(classes.purple, classes.reportButton);\n }\n else {\n return classes.reportButton;\n }\n }\n default: {\n return classes.button;\n }\n }\n };\n return (_jsx(Button, __assign({ id: id, onClick: onClick, title: title, className: disabled ? classes.disabled : getButtonClass(), style: style, tabIndex: tabIndex }, { children: children }), key));\n};\nexport default TextButton;\n//# sourceMappingURL=TextButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar HowToIcon = function (_a) {\n var width = _a.width, height = _a.height;\n var id = useUUID('howToIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"24\", height: \"24\", viewBox: \"0 0 24 24\", fill: \"none\", stroke: \"currentColor\", strokeWidth: \"1.6\", strokeLinecap: \"round\", strokeLinejoin: \"round\", className: \"feather feather-grid\", version: \"1.1\", id: id, xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"How To\" }), void 0), _jsx(\"rect\", { x: \"9.181344\", y: \"9.1506939\", width: \"5.6717939\", height: \"5.6104913\" }, void 0), _jsx(\"rect\", { x: \"9.1506929\", y: \"1.089391\", width: \"5.6717939\", height: \"5.6104913\" }, void 0), _jsx(\"rect\", { x: \"9.181344\", y: \"17.211998\", width: \"5.6717939\", height: \"5.6104913\" }, void 0)] }), void 0));\n};\nexport default HowToIcon;\n//# sourceMappingURL=HowToIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { useHistory, useLocation } from 'react-router-dom';\nimport { useTheme, makeStyles } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport OutcomesIcon from '../icons/OutcomesIcon';\nimport { NavigationContext } from '../../contexts/NavigationContext';\nimport { Award, BarChart2, Home, Settings, Star } from 'react-feather';\nimport TextButton from '../buttons/TextButton';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport HowToIcon from '../icons/HowToIcon';\nvar useStyles = makeStyles(function (theme) { return ({\n listItem: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n position: 'relative',\n zIndex: 4,\n marginBottom: 8,\n },\n unselectedIcon: {\n height: 24,\n },\n selectedIcon: {\n height: 24,\n },\n mouseOverText: {\n color: 'rgba(0,0,0,0.8)',\n },\n unselectedText: {\n color: 'rgba(0,0,0,0.4)',\n },\n selectedText: {\n color: '#654ea3',\n },\n content: {\n textAlign: 'center',\n },\n iconContainer: {\n display: 'flex',\n },\n selector: {\n borderRadius: 4,\n backgroundColor: '#654EA3',\n position: 'absolute',\n width: 4,\n height: 56,\n left: 106,\n zIndex: 999999,\n },\n}); });\nvar NavigationLink = function (_a) {\n var title = _a.title, iconName = _a.iconName, paths = _a.paths, primaryPath = _a.primaryPath, id = _a.id;\n var classes = useStyles();\n var typo = useTypography();\n var setShowNav = useContext(NavigationContext).setShowNav;\n var _b = __read(useState(false), 2), selected = _b[0], setSelected = _b[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var history = useHistory();\n var location = useLocation();\n useEffect(function () {\n setSelected(paths.includes(location.pathname.split('/')[1]));\n }, [paths, location.pathname]);\n var openLink = function () {\n if (isMdDown) {\n setShowNav(false);\n }\n history.push(primaryPath);\n };\n var icons = new Map([\n ['home', _jsx(Home, {}, \"home-icon\")],\n ['outcomes', _jsx(OutcomesIcon, {}, \"outcomes-icon\")],\n ['skills', _jsx(Star, {}, \"skills-icon\")],\n ['insights', _jsx(BarChart2, {}, \"insights-icon\")],\n ['showcase', _jsx(Award, {}, \"showcase-icon\")],\n ['preferences', _jsx(Settings, {}, \"preferences-icon\")],\n ['howTo', _jsx(HowToIcon, {}, \"howTo-icon\")],\n ]);\n var icon = icons.get(iconName);\n return (_jsxs(\"li\", __assign({ id: id, className: classes.listItem, title: title }, { children: [selected && _jsx(\"div\", { className: classes.selector }, void 0), _jsx(TextButton, __assign({ onClick: openLink, style: { width: '100%', height: '100%', minHeight: 62 } }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n width: '100%',\n height: '100%',\n color: selected ? Colors.purple : Colors.textSecondary,\n } }, { children: [icon, _jsx(\"span\", __assign({ className: typo.overlineMini, style: {\n fontWeight: 'bold',\n lineHeight: '20px',\n color: selected ? Colors.purple : Colors.textSecondary,\n } }, { children: title }), void 0)] }), void 0) }), void 0)] }), location.pathname));\n};\nexport default NavigationLink;\n//# sourceMappingURL=NavigationLink.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var UserContext = createContext({});\nexport var UserProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), user = _b[0], setUser = _b[1];\n var _c = __read(useState(false), 2), noNulia = _c[0], setNoNulia = _c[1];\n var userContext = {\n user: user,\n setUser: setUser,\n noNulia: noNulia,\n setNoNulia: setNoNulia,\n };\n return _jsx(UserContext.Provider, __assign({ value: userContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=UserContext.js.map","export var hasAdminRole = function (user) { return user !== undefined && user.role.includes('a'); };\n//# sourceMappingURL=hasAdminRole.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core';\nimport { useContext } from 'react';\nimport NavigationLink from './NavigationLink';\nimport { LicenseType } from '../../types/enums';\nimport { UserContext } from '../../contexts/UserContext';\nimport { hasAdminRole } from '../../utils/hasAdminRole';\nvar useStyles = makeStyles({\n root: {\n flex: 1,\n position: 'relative',\n zIndex: 3,\n },\n});\nvar NavigationLinks = function () {\n var classes = useStyles();\n var _a = useContext(UserContext), user = _a.user, noNulia = _a.noNulia;\n if ((user === null || user === void 0 ? void 0 : user.licenseType) === LicenseType.None && hasAdminRole(user)) {\n return (_jsxs(\"ul\", __assign({ className: classes.root }, { children: [_jsx(NavigationLink, { id: \"navigation-insights-button\", title: \"Insights\", iconName: \"insights\", paths: [\n 'assessments',\n 'user-insights',\n 'licenses-insights',\n 'history-insights',\n 'bulk',\n 'insights-detail',\n 'insights-outcome-detail',\n ], primaryPath: \"/assessments\" }, void 0), _jsx(NavigationLink, { id: \"navigation-preferences-button\", title: \"Preferences\", iconName: \"preferences\", paths: ['preferences'], primaryPath: \"/preferences\" }, void 0)] }), void 0));\n }\n else if ((user === null || user === void 0 ? void 0 : user.licenseType) === LicenseType.None || noNulia) {\n return null;\n }\n return (_jsxs(\"ul\", __assign({ className: classes.root }, { children: [_jsx(NavigationLink, { id: \"navigation-home-button\", title: \"Home\", iconName: \"home\", paths: [''], primaryPath: \"/\" }, void 0), _jsx(NavigationLink, { id: \"navigation-skills-button\", title: \"Skills\", iconName: \"skills\", paths: ['your-skills', 'all-skills', 'skill-details'], primaryPath: \"/your-skills\" }, void 0), _jsx(NavigationLink, { id: \"navigation-outcomes-button\", title: \"Outcomes\", iconName: \"outcomes\", paths: ['your-outcomes', 'all-outcomes', 'outcome-details'], primaryPath: \"/your-outcomes\" }, void 0), _jsx(NavigationLink, { id: \"navigation-showcase-button\", title: \"Showcase\", iconName: \"showcase\", paths: ['showcase', 'your-badges', 'your-achievements'], primaryPath: \"/showcase\" }, void 0), _jsx(NavigationLink, { id: \"navigation-howTo-button\", title: \"How To's\", iconName: \"howTo\", paths: ['how-to', 'how-to-playlist'], primaryPath: \"/how-to\" }, void 0), _jsx(NavigationLink, { id: \"navigation-insights-button\", title: \"Insights\", iconName: \"insights\", paths: [\n 'assessments',\n 'user-insights',\n 'licenses-insights',\n 'history-insights',\n 'bulk',\n 'insights-detail',\n 'insights-outcome-detail',\n ], primaryPath: hasAdminRole(user) ? '/assessments' : '/user-insights' }, void 0), _jsx(NavigationLink, { id: \"navigation-preferences-button\", title: \"Preferences\", iconName: \"preferences\", paths: ['preferences'], primaryPath: \"/preferences\" }, void 0)] }), void 0));\n};\nexport default NavigationLinks;\n//# sourceMappingURL=NavigationLinks.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { LOGOS_PATH } from '../../utils/constants';\nimport { makeStyles } from '@material-ui/core/styles';\nvar useStyles = makeStyles(function (theme) { return ({\n logo: {\n width: 42,\n },\n}); });\nvar NavigationLogo = function () {\n var classes = useStyles();\n return _jsx(\"img\", { alt: \"logo\", src: LOGOS_PATH + \"nulia_logo_small.svg\", className: classes.logo }, void 0);\n};\nexport default NavigationLogo;\n//# sourceMappingURL=NavigationLogo.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { NavigationContext } from '../../contexts/NavigationContext';\nimport TextButton from '../buttons/TextButton';\nimport { X } from 'react-feather';\nimport NavigationLogo from './NavigationLogo';\nvar MobileCloseNavigation = function () {\n var setShowNav = useContext(NavigationContext).setShowNav;\n var onClick = function () { return setShowNav(false); };\n return (_jsxs(TextButton, __assign({ onClick: onClick, \"aria-label\": \"close navigation tray\" }, { children: [_jsx(X, {}, void 0), _jsx(NavigationLogo, {}, void 0)] }), void 0));\n};\nexport default MobileCloseNavigation;\n//# sourceMappingURL=MobileCloseNavigation.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core';\nimport { createContext, useState } from 'react';\nimport NavigationLinks from '../components/navigation/NavigationLinks';\nimport NavigationLogo from '../components/navigation/NavigationLogo';\nimport MobileCloseNavigation from '../components/navigation/MobileCloseNavigation';\nimport { useTheme } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport { VERSION } from '../utils/constants';\nexport var NavigationContext = createContext({});\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n navigation: {\n backgroundColor: '#ffffff',\n boxShadow: '0 2.5px 8px 0.5px rgba(0,0,0,0.08), 0 1px 4px 0 rgba(0,0,0,0.08)',\n display: 'flex',\n flexDirection: 'column',\n height: '100vh',\n width: 110,\n paddingTop: 16,\n position: 'fixed',\n zIndex: 99,\n flex: 1,\n },\n logo: {\n margin: '0 auto',\n paddingBottom: 32,\n },\n links: {\n overflow: 'auto',\n overflowX: 'hidden',\n marginBottom: 'auto',\n },\n version: {\n width: '100%',\n textAlign: 'center',\n marginTop: 25,\n marginBottom: 25,\n },\n body: (_a = {\n marginLeft: 110\n },\n _a[theme.breakpoints.down('md')] = {\n marginLeft: 0,\n },\n _a),\n });\n});\nexport var NavigationProvider = function (_a) {\n var children = _a.children;\n var classes = useStyles();\n var _b = __read(useState(true), 2), showNav = _b[0], setShowNav = _b[1];\n var theme = useTheme();\n var isLgUp = useMediaQuery(theme.breakpoints.up('lg'));\n var navigationContext = {\n showNav: showNav,\n setShowNav: setShowNav,\n };\n return (_jsxs(NavigationContext.Provider, __assign({ value: navigationContext }, { children: [(showNav || isLgUp) && (_jsxs(\"div\", __assign({ className: classes.navigation }, { children: [_jsx(\"div\", __assign({ className: classes.logo }, { children: isLgUp ? _jsx(NavigationLogo, {}, void 0) : _jsx(MobileCloseNavigation, {}, void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.links }, { children: _jsx(NavigationLinks, {}, void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.version }, { children: _jsx(\"span\", __assign({ className: \"body2\" }, { children: VERSION }), void 0) }), void 0)] }), void 0)), _jsx(\"div\", __assign({ className: classes.body }, { children: children }), void 0)] }), void 0));\n};\n//# sourceMappingURL=NavigationContext.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { makeStyles } from '@material-ui/styles';\nimport { NavigationContext } from '../../contexts/NavigationContext';\nimport { IconButton } from '@material-ui/core';\nimport { Menu } from 'react-feather';\nvar useStyles = makeStyles({\n root: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n height: 56,\n width: 56,\n minWidth: 56,\n borderRight: '1px solid rgba(0,0,0,0.08)',\n borderRadius: 0,\n },\n});\nvar MobileOpenNavigation = function () {\n var setShowNav = useContext(NavigationContext).setShowNav;\n var classes = useStyles();\n var onClick = function () { return setShowNav(true); };\n return (_jsx(IconButton, __assign({ className: classes.root, onClick: onClick, \"aria-label\": \"open navigation tray\" }, { children: _jsx(Menu, {}, void 0) }), void 0));\n};\nexport default MobileOpenNavigation;\n//# sourceMappingURL=MobileOpenNavigation.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { IconButton, makeStyles, Snackbar } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { createContext, useState } from 'react';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport { X } from 'react-feather';\nexport var SnackbarContext = createContext({});\nvar useStyles = makeStyles({\n root: {\n width: '95%',\n },\n snackbarContent: {\n width: '100%',\n backgroundColor: Colors.purple,\n color: Colors.white,\n },\n});\nexport var SnackbarProvider = function (_a) {\n var children = _a.children;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState(''), 2), snackbarMessage = _b[0], setSnackbarMessage = _b[1];\n var _c = __read(useState(false), 2), openSnackbar = _c[0], setOpenSnackbar = _c[1];\n var vertical = 'bottom';\n var horizontal = 'center';\n var snackbarContext = {\n snackbarMessage: snackbarMessage,\n setSnackbarMessage: setSnackbarMessage,\n openSnackbar: openSnackbar,\n setOpenSnackbar: setOpenSnackbar,\n };\n var onCloseSnackbar = function () { return setOpenSnackbar(false); };\n return (_jsxs(SnackbarContext.Provider, __assign({ value: snackbarContext }, { children: [children, _jsx(Snackbar, { anchorOrigin: { vertical: vertical, horizontal: horizontal }, open: openSnackbar, onClose: onCloseSnackbar, classes: { root: classes.root }, ContentProps: { className: clsx(classes.snackbarContent, typo.body1) }, message: snackbarMessage, autoHideDuration: 6000, action: _jsx(IconButton, __assign({ \"aria-label\": \"Close alert\", onClick: onCloseSnackbar, style: { color: Colors.white } }, { children: _jsx(X, {}, void 0) }), void 0) }, vertical + horizontal)] }), void 0));\n};\n//# sourceMappingURL=SnackbarContext.js.map","import * as Sentry from '@sentry/browser';\nexport var logError = function (error) {\n if (window.location.hostname === 'localhost') {\n console.error(error.message);\n }\n Sentry.captureException(error);\n};\n//# sourceMappingURL=logError.js.map","export var Status;\n(function (Status) {\n Status[Status[\"Error\"] = -1] = \"Error\";\n Status[Status[\"Success\"] = 0] = \"Success\";\n Status[Status[\"Warning\"] = 1] = \"Warning\";\n})(Status || (Status = {}));\n//# sourceMappingURL=Status.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var TokenContext = createContext({});\nexport var TokenProvider = function (_a) {\n var propToken = _a.propToken, propOid = _a.propOid, prodTid = _a.prodTid, propClientType = _a.propClientType, children = _a.children;\n var _b = __read(useState(propToken), 2), ssoToken = _b[0], setSsoToken = _b[1];\n var _c = __read(useState(null), 2), expire = _c[0], setExpire = _c[1];\n var _d = __read(useState(propOid !== null && propOid !== void 0 ? propOid : ''), 2), oid = _d[0], setOid = _d[1];\n var _e = __read(useState(prodTid !== null && prodTid !== void 0 ? prodTid : ''), 2), tid = _e[0], setTid = _e[1];\n var _f = __read(useState(propClientType), 2), clientType = _f[0], setClientType = _f[1];\n var tokenContext = {\n ssoToken: ssoToken,\n setSsoToken: setSsoToken,\n expire: expire,\n setExpire: setExpire,\n oid: oid,\n setOid: setOid,\n tid: tid,\n setTid: setTid,\n clientType: clientType,\n setClientType: setClientType,\n };\n return _jsx(TokenContext.Provider, __assign({ value: tokenContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=TokenContext.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { InteractionRequiredAuthError } from '@azure/msal-browser';\nimport config from '../config.json';\nexport var getToken = function (instance, account, ssoToken) { return __awaiter(void 0, void 0, void 0, function () {\n var response, error_1;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (ssoToken) {\n return [2, ssoToken];\n }\n if (!account) return [3, 6];\n _a.label = 1;\n case 1:\n _a.trys.push([1, 3, , 6]);\n return [4, instance.acquireTokenSilent({\n scopes: [config.PLATFORM_APP_URI],\n account: account,\n })];\n case 2:\n response = _a.sent();\n return [2, response.idToken];\n case 3:\n error_1 = _a.sent();\n if (!(error_1 instanceof InteractionRequiredAuthError)) return [3, 5];\n return [4, instance\n .acquireTokenPopup({\n scopes: [config.PLATFORM_APP_URI],\n account: account,\n })\n .catch(function (error) {\n console.error(error);\n })];\n case 4:\n _a.sent();\n _a.label = 5;\n case 5: return [3, 6];\n case 6: return [2, ''];\n }\n });\n}); };\n//# sourceMappingURL=getToken.js.map","export var messageText = {\n NotEnoughEngagementPoints: 'You do not have enough engagement points to do this action.',\n UserDataNotComplete: 'It looks like some of your user data is unavailable and we can’t continue. ' +\n 'Our automated data recovery process will run overnight to correct this problem. Please try back ' +\n 'in 24 hours. If you continue to experience this problem, please use the feedback button so we can ' +\n 'identify who you are and put a specialist on it.',\n NoLicense: 'Sorry, you do not currently have a Nulia Works license. Please contact your Nulia ' +\n 'Administrator, or your manager and ask them to assign you one.',\n MissingUserOutcome: ' It looks like some of your outcome data is unavailable and we can’t continue. ' +\n 'Our automated data recovery process will run overnight to correct this problem. Please try back ' +\n 'in 24 hours. If you continue to experience this problem, please use the feedback button so we can ' +\n 'identify who you are and put a specialist on it.',\n CannotUnassignManagerAssignedSkill: 'Sorry, you can’t remove a skill that was assigned to you by somebody else in your organization.',\n SkillAssignmentNotFound: 'Sorry, we could not unassign that skill. It looks like that skill was not assigned to you.',\n CannotUnassignOutcomeAssignedSkill: \"Sorry, you can't remove or lower the target level of a skill since it is part of another outcome that you are currently working on or maintaining.\",\n ManagerSkillAssignmentNotFound: 'Sorry, that user doesn’t seem to have that skill assigned to them.',\n CannotUnassignManagerAssignedOutcome: 'Sorry, you can’t remove an outcome that your manager or champion assigned to you. Please contact them if ' +\n 'you would like to have this outcome removed.',\n OutcomeAssignmentNotFound: 'Sorry, we could not unassign that outcome. It looks like that outcome was not assigned to you.',\n ManagerOutcomeAssignmentNotFound: 'Sorry, we could not unassign that outcome. It looks like that outcome was not assigned to that user.',\n CannotUnassignUserSelectedOutcome: 'Sorry, you can’t remove an outcome that the user self-assigned. Please contact them if you would like to ' +\n 'have this outcome removed.',\n NoHigherOutcomes: 'Sorry, that outcome does not have a higher level to work towards.',\n CannotUnassignSystemAssignedOutcome: 'Sorry, you can’t remove default outcomes.',\n};\n//# sourceMappingURL=MessageText.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport axios from 'axios';\nimport { createContext, useContext } from 'react';\nimport { SnackbarContext } from '../contexts/SnackbarContext';\nimport { BASE_API_URL, BLOB_SAS_KEY, CDN_URL, IMAGE_API_URL } from '../utils/constants';\nimport { Level } from '../types/enums';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { logError } from '../utils/logError';\nimport { ResultCode } from '../enums/ResultCode';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { getToken } from '../utils/getToken';\nimport { isValidBlobToken } from '../utils/isValidBlobToken';\nimport * as d3 from 'd3';\nimport { Status } from '../enums/Status';\nimport { messageText } from '../types/MessageText';\nexport var ApiServiceContext = createContext({});\nexport var useApiService = function () { return useContext(ApiServiceContext); };\nexport var ApiServiceProvider = function (_a) {\n var children = _a.children;\n var ssoToken = useContext(TokenContext).ssoToken;\n var _b = useContext(SnackbarContext), setSnackbarMessage = _b.setSnackbarMessage, setOpenSnackbar = _b.setOpenSnackbar;\n var _c = useMsal(), instance = _c.instance, accounts = _c.accounts;\n var account = useAccount(accounts[0]);\n var handleStatus = function (code) {\n var message = '';\n switch (code) {\n case ResultCode.NotEnoughEngagementPoints:\n message = messageText.NotEnoughEngagementPoints;\n break;\n case ResultCode.CannotUnassignManagerAssignedSkill:\n message = messageText.CannotUnassignManagerAssignedSkill;\n break;\n case ResultCode.SkillAssignmentNotFound:\n message = messageText.SkillAssignmentNotFound;\n break;\n case ResultCode.CannotUnassignOutcomeAssignedSkill:\n message = messageText.CannotUnassignOutcomeAssignedSkill;\n break;\n case ResultCode.ManagerSkillAssignmentNotFound:\n message = messageText.ManagerSkillAssignmentNotFound;\n break;\n case ResultCode.CannotUnassignManagerAssignedOutcome:\n message = messageText.CannotUnassignManagerAssignedOutcome;\n break;\n case ResultCode.OutcomeAssignmentNotFound:\n message = messageText.OutcomeAssignmentNotFound;\n break;\n case ResultCode.ManagerOutcomeAssignmentNotFound:\n message = messageText.ManagerOutcomeAssignmentNotFound;\n break;\n case ResultCode.CannotUnassignUserSelectedOutcome:\n message = messageText.CannotUnassignUserSelectedOutcome;\n break;\n case ResultCode.NoHigherOutcomeLevels:\n message = messageText.NoHigherOutcomes;\n break;\n case ResultCode.CannotUnassignSystemAssignedOutcome:\n message = messageText.CannotUnassignSystemAssignedOutcome;\n break;\n case ResultCode.NotAuthorized:\n break;\n case ResultCode.UserNotFound:\n break;\n case ResultCode.NoLicense:\n break;\n default:\n break;\n }\n if (message) {\n setSnackbarMessage(message);\n setOpenSnackbar(true);\n }\n };\n var handleError = function (code) {\n switch (code) {\n case ResultCode.NotAuthorized:\n break;\n case ResultCode.UserNotFound:\n break;\n case ResultCode.NoLicense:\n break;\n default:\n break;\n }\n };\n var get = function (url, config) { return __awaiter(void 0, void 0, void 0, function () {\n var response, error_1;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2, , 3]);\n return [4, axios.get(url, config)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n if (response.data.status < 0) {\n handleStatus(response.data.code);\n }\n else {\n return [2, response.data];\n }\n return [3, 3];\n case 2:\n error_1 = _a.sent();\n handleError(error_1.response.data.code);\n logError(error_1);\n return [2];\n case 3: return [2];\n }\n });\n }); };\n var post = function (url, body, config) { return __awaiter(void 0, void 0, void 0, function () {\n var response, error_2;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2, , 3]);\n return [4, axios.post(url, body, config)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n if (response.data.status < 0) {\n handleStatus(response.data.code);\n }\n else {\n return [2, response.data];\n }\n return [3, 3];\n case 2:\n error_2 = _a.sent();\n handleError(error_2.response.data.code);\n logError(error_2);\n return [2];\n case 3: return [2];\n }\n });\n }); };\n var del = function (url, body, config) { return __awaiter(void 0, void 0, void 0, function () {\n var newHeaders, response, error_3;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2, , 3]);\n newHeaders = __assign(__assign({}, config), { data: body });\n return [4, axios.delete(url, newHeaders)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n if (response.data.status < 0) {\n handleStatus(response.data.code);\n }\n else {\n return [2, response.data];\n }\n return [3, 3];\n case 2:\n error_3 = _a.sent();\n handleError(error_3.response.data.code);\n logError(error_3);\n return [2];\n case 3: return [2];\n }\n });\n }); };\n var changeTargetLevel = function (user, oid, newLevel, id, type, recommended, admin) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n url = BASE_API_URL + \"/ChangeTargetLevel\";\n body = {\n oid: oid,\n newLevel: newLevel,\n id: id,\n type: type,\n recommended: recommended,\n adminAction: admin,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2:\n response = _a.sent();\n if (response) {\n if (newLevel === Level.None) {\n setSnackbarMessage(type === 'outcome'\n ? 'We have successfully removed your Outcome. Note that you might still see this Outcome at a different target level if someone else in your organization assigned you this Outcome'\n : 'We have successfully removed your Skill. Note that you might still see this Skill at a different target level if it was part of an Outcome you are currently working on, or if someone else in your organization assigned you this Skill');\n }\n else {\n setSnackbarMessage(type === 'outcome'\n ? 'You have successfully assigned the Outcome'\n : 'You have successfully assigned the Skill');\n }\n setOpenSnackbar(true);\n }\n return [2, response];\n }\n });\n }); };\n var getBlobToken = function (user, container, blobName) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, key, storedToken, headers, response, tokenResponse;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetBlobToken\";\n body = {\n container: container,\n blobName: blobName,\n };\n key = BLOB_SAS_KEY + container + blobName;\n storedToken = sessionStorage.getItem(key);\n if (!(storedToken && isValidBlobToken(storedToken))) return [3, 1];\n return [2, \"\" + CDN_URL + container + \"/\" + blobName + \"?\" + storedToken + \"&random=\" + Math.random()];\n case 1: return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 2:\n headers = _a.sent();\n return [4, post(url, body, headers)];\n case 3:\n response = _a.sent();\n tokenResponse = response;\n if (!tokenResponse || (tokenResponse && tokenResponse.status < 0)) {\n return [2];\n }\n sessionStorage.setItem(key, tokenResponse.data);\n return [2, \"\" + CDN_URL + container + \"/\" + blobName + \"?\" + tokenResponse.data + \"&random=\" + Math.random()];\n }\n });\n }); };\n var viewedContent = function (user, contentId) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/ViewedContent\";\n body = {\n contentId: contentId,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n var requestStarterUpgrade = function (user, targetOid) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/RequestStarterUpgrade\";\n body = {\n targetOid: targetOid,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var buyHint = function (user, skillId, level) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BuyHint\";\n body = {\n skillId: skillId,\n level: level,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var rateContent = function (user, contentId, rating) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/RateContent\";\n body = {\n contentId: contentId,\n rating: rating,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n var telemetry = function (user, code, status, reason, data) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/Telemetry\";\n body = {\n code: code,\n status: status,\n reason: reason,\n data: data,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var sendHint = function (user, targetOid, outcomeId) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/SendHint\";\n body = {\n targetOid: targetOid,\n outcomeId: outcomeId,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var changeCompleteLicensedUser = function (user, oid, changeType) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/ChangeCompleteLicensedUser\";\n body = {\n oids: [oid],\n changeType: changeType,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var bulkLicenseAssign = function (user, oids) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BulkLicense\";\n body = {\n guids: oids,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var bulkLicenseRemove = function (user, oids) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BulkLicense\";\n body = {\n guids: oids,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, del(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var bulkOutcomeAssign = function (user, oids, outcomes) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BulkOutcomes\";\n body = {\n guids: oids,\n outcomes: outcomes,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var bulkOutcomeRemove = function (user, oids, outcomes) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BulkOutcomes\";\n body = {\n guids: oids,\n outcomes: outcomes,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, del(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getLicenseData = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetLicenseReport\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getInsightsDetail = function (user, oid) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetInsightsDetail\";\n return [4, getHeaders(oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getInsightOutcomes = function (user, oid) { return __awaiter(void 0, void 0, void 0, function () {\n var headers, url, body;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n url = BASE_API_URL + \"/GetInsightsUserDetailOutcomes\";\n body = { oid: oid };\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getInsightSkills = function (user, oid) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAssignedUserSkills\";\n return [4, getHeaders(oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getWeeklyInsightsUserOutcomes = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/WeeklyInsightsUserOutcomes\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonUserOutcome(response),\n }];\n }\n });\n }); };\n var getInsightsUserOutcomes = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/WeeklyInsightsUserOutcomes\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonUserOutcome(response),\n }];\n }\n });\n }); };\n var csvToJsonUserOutcome = function (csv) {\n var parsedJson = JSON.parse(JSON.stringify(d3.csvParse(csv)));\n var output = [];\n parsedJson.forEach(function (item) {\n output.push({\n badges: parseInt(item['badges'], 10),\n country: item['country'],\n department: item['department'],\n direct: parseInt(item['direct'], 10),\n image: item['image'],\n inProgress: parseInt(item['inProgress'], 10),\n lastLogin: parseInt(item['lastLogin'], 10),\n licenseType: item['licenseType'],\n maintained: parseInt(item['maintained'], 10),\n name: item['name'],\n needsAttention: parseInt(item['needsAttention'], 10),\n oid: item['oid'],\n points: parseInt(item['points'], 10),\n status: parseInt(item['status'], 10),\n total: parseInt(item['total'], 10),\n });\n });\n return output;\n };\n var getWeeklyInsightsUserGraph = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/WeeklyInsightsUserGraph\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonUserGraphWeekly(response),\n }];\n }\n });\n }); };\n var csvToJsonUserGraphWeekly = function (csv) {\n var parsedJson = JSON.parse(JSON.stringify(d3.csvParse(csv)));\n var output = [];\n parsedJson.forEach(function (item) {\n output.push({\n year: item['year'],\n month: item['month'],\n oid: item['oid'],\n name: item['name'],\n direct: parseInt(item['direct'], 10),\n country: item['country'],\n department: item['department'],\n inProgress: parseInt(item['inProgress'], 10),\n maintaining: parseInt(item['maintaining'], 10),\n needsAttention: parseInt(item['needsAttention'], 10),\n status: parseInt(item['status'], 10),\n licenseType: item['licenseType'],\n weekString: item['year'] + \"-\" + item['month'] + \"-\" + item['weekOfMonth'],\n });\n });\n return output;\n };\n var getInsightsOutcomeOverview = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/InsightsOutcomeOverview\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getInsightsOutcomeDetail = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/InsightsOutcomeDetail\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonOutcomeDetail(response),\n }];\n }\n });\n }); };\n var csvToJsonOutcomeDetail = function (csv) {\n var parsedJson = JSON.parse(JSON.stringify(d3.csvParse(csv)));\n var output = [];\n parsedJson.forEach(function (item) {\n output.push({\n country: item['country'],\n department: item['department'],\n direct: parseInt(item['direct'], 10),\n oid: item['oid'],\n outcomeId: parseInt(item['outcomeId'], 10),\n performance: parseInt(item['performance'], 10),\n state: parseInt(item['state'], 10),\n });\n });\n return output;\n };\n var getInsightsUserLicenses = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/InsightsUserLicenses\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonUserLicenses(response),\n }];\n }\n });\n }); };\n var csvToJsonUserLicenses = function (csv) {\n var parsedJson = JSON.parse(JSON.stringify(d3.csvParse(csv)));\n var output = [];\n parsedJson.forEach(function (item) {\n output.push({\n completedStarter: parseInt(item['completedStarter'], 10),\n country: item['country'],\n department: item['department'],\n image: item['image'],\n licenseType: item['licenseType'],\n name: item['name'],\n oid: item['oid'],\n upgradeRequested: parseInt(item['upgradeRequested'], 10),\n });\n });\n return output;\n };\n var getInsightsOutcomeUsers = function (user, id) { return __awaiter(void 0, void 0, void 0, function () {\n var body, url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n body = {\n id: id,\n };\n url = BASE_API_URL + \"/WeeklyInsightsOutcomeUsers\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonOutcomeUsers(response),\n }];\n }\n });\n }); };\n var csvToJsonOutcomeUsers = function (csv) {\n var parsedJson = JSON.parse(JSON.stringify(d3.csvParse(csv)));\n var output = [];\n parsedJson.forEach(function (item) {\n output.push({\n allAssignmentType: parseInt(item['allAssignmentType'], 10),\n country: item['country'],\n department: item['department'],\n direct: parseInt(item['direct'], 10),\n image: item['image'],\n name: item['name'],\n oid: item['oid'],\n orgLevel: parseInt(item['orgLevel'], 10),\n orgProgress: parseInt(item['orgProgress'], 10),\n orgStatus: parseInt(item['orgStatus'], 10),\n outcomeId: parseInt(item['outcomeId'], 10),\n selfLevel: parseInt(item['selfLevel'], 10),\n selfProgress: parseInt(item['selfProgress'], 10),\n selfStatus: parseInt(item['selfStatus'], 10),\n });\n });\n return output;\n };\n var getInsightsOutcomeSkills = function (user, id) { return __awaiter(void 0, void 0, void 0, function () {\n var body, url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n body = {\n id: id,\n };\n url = BASE_API_URL + \"/InsightsOutcomeSkills\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getInsightsOutcomeGraph = function (user, id) { return __awaiter(void 0, void 0, void 0, function () {\n var body, url, headers, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n body = {\n id: id,\n };\n url = BASE_API_URL + \"/WeeklyInsightsOutcomeGraph\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, post(url, body, headers)];\n case 2:\n response = _a.sent();\n return [2, {\n code: ResultCode.Success,\n sessionId: '',\n status: Status.Success,\n data: csvToJsonOutcomeGraph(response),\n }];\n }\n });\n }); };\n var csvToJsonOutcomeGraph = function (csv) {\n var parsedJson = JSON.parse(JSON.stringify(d3.csvParse(csv)));\n var output = [];\n parsedJson.forEach(function (item) {\n output.push({\n year: item['year'],\n month: item['month'],\n oid: item['oid'],\n name: item['name'],\n outcomeId: parseInt(item['outcomeId'], 10),\n department: item['department'],\n country: item['country'],\n allAssignmentType: parseInt(item['allAssignmentType'], 10),\n selfLevel: parseInt(item['selfLevel'], 10),\n selfProgress: parseInt(item['selfProgress'], 10),\n selfStatus: parseInt(item['selfStatus'], 10),\n orgLevel: parseInt(item['orgLevel'], 10),\n orgProgress: parseInt(item['orgProgress'], 10),\n orgStatus: parseInt(item['orgStatus'], 10),\n direct: parseInt(item['direct'], 10),\n weekString: item['year'] + \"-\" + item['month'] + \"-\" + item['weekOfMonth'],\n });\n });\n return output;\n };\n var getAssignableOutcomeDetails = function (user) { return __awaiter(void 0, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetBulkAssignableOutcomes\";\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n var getUserImages = function (user, oids) { return __awaiter(void 0, void 0, void 0, function () {\n var url, body, headers, response, error_4;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = IMAGE_API_URL + \"/GetUserImageList\";\n body = {\n oids: oids,\n };\n return [4, getHeaders(user.oid, user.tid, user.sid)];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n _a.label = 2;\n case 2:\n _a.trys.push([2, 4, , 5]);\n return [4, axios.post(url, body, headers)];\n case 3:\n response = _a.sent();\n if (!response || (response && response.status < 0)) {\n return [2, { data: [] }];\n }\n return [2, response.data];\n case 4:\n error_4 = _a.sent();\n return [2, { data: [] }];\n case 5: return [2];\n }\n });\n }); };\n var getHeaders = function (oid, tid, sid) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n return [2, {\n headers: {\n Authorization: \"Bearer \" + newToken,\n 'NULIA-OID': oid,\n 'NULIA-TID': tid,\n 'NULIA-SID': sid !== null && sid !== void 0 ? sid : '',\n 'NULIA-SRC': 'teams',\n 'NULIA-TZ': new Date().getTimezoneOffset().toString(),\n },\n }];\n }\n });\n }); };\n var apiService = {\n changeTargetLevel: changeTargetLevel,\n getBlobToken: getBlobToken,\n viewedContent: viewedContent,\n requestStarterUpgrade: requestStarterUpgrade,\n buyHint: buyHint,\n rateContent: rateContent,\n telemetry: telemetry,\n sendHint: sendHint,\n changeCompleteLicensedUser: changeCompleteLicensedUser,\n bulkLicenseAssign: bulkLicenseAssign,\n bulkLicenseRemove: bulkLicenseRemove,\n bulkOutcomeAssign: bulkOutcomeAssign,\n bulkOutcomeRemove: bulkOutcomeRemove,\n getLicenseData: getLicenseData,\n getInsightsDetail: getInsightsDetail,\n getInsightOutcomes: getInsightOutcomes,\n getInsightSkills: getInsightSkills,\n getInsightsUserOutcomes: getInsightsUserOutcomes,\n getWeeklyInsightsUserOutcomes: getWeeklyInsightsUserOutcomes,\n getWeeklyInsightsUserGraph: getWeeklyInsightsUserGraph,\n getInsightsOutcomeOverview: getInsightsOutcomeOverview,\n getInsightsOutcomeDetail: getInsightsOutcomeDetail,\n getInsightsUserLicenses: getInsightsUserLicenses,\n getInsightsOutcomeUsers: getInsightsOutcomeUsers,\n getInsightsOutcomeSkills: getInsightsOutcomeSkills,\n getInsightsOutcomeGraph: getInsightsOutcomeGraph,\n getAssignableOutcomeDetails: getAssignableOutcomeDetails,\n getUserImages: getUserImages,\n };\n return _jsx(ApiServiceContext.Provider, __assign({ value: apiService }, { children: children }), void 0);\n};\n//# sourceMappingURL=ApiServiceProvider.js.map","import * as queryString from 'query-string';\nimport { isAfter } from 'date-fns';\nexport var isValidBlobToken = function (token) {\n if (!token) {\n return false;\n }\n else {\n var decodedToken = queryString.parse(token);\n if (decodedToken && isAfter(new Date(decodedToken.se), new Date())) {\n return true;\n }\n }\n return false;\n};\n//# sourceMappingURL=isValidBlobToken.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Person } from '@material-ui/icons';\nvar useStyles = makeStyles({\n root: {\n backgroundColor: 'DarkGray',\n color: 'White',\n borderRadius: '50%',\n height: 40,\n minHeight: 40,\n width: 40,\n minWidth: 40,\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n});\nvar DefaultUserImage = function (_a) {\n var size = _a.size, fontSize = _a.fontSize;\n var classes = useStyles();\n return (_jsx(\"div\", __assign({ className: classes.root, style: size ? { height: size, minHeight: size, width: size, minWidth: size } : undefined }, { children: _jsx(Person, { style: fontSize ? { fontSize: fontSize } : undefined }, void 0) }), void 0));\n};\nexport default DefaultUserImage;\n//# sourceMappingURL=DefaultUserImage.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar EngagementPointsIcon = function (_a) {\n var large = _a.large, small = _a.small, width = _a.width, height = _a.height;\n var id = useUUID('engagementPointsIconTitleId');\n return (_jsx(_Fragment, { children: large ? (_jsxs(\"svg\", __assign({ \"aria-labelledby\": id, width: \"52\", height: \"52\", viewBox: \"0 0 52 52\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Engagement Points\" }), void 0), _jsx(\"path\", { opacity: \"0.4\", d: \"M26.0003 8.66666C16.4453 8.66666 8.66699 16.445 8.66699 26C8.66699 35.555 16.4453 43.3333 26.0003 43.3333C35.5553 43.3333 43.3337 35.555 43.3337 26C43.3337 16.445 35.5553 8.66666 26.0003 8.66666Z\", fill: \"#FFCC55\" }, void 0), _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M4.3335 26C4.3335 14.04 14.0402 4.33333 26.0002 4.33333C37.9602 4.33333 47.6668 14.04 47.6668 26C47.6668 37.96 37.9602 47.6667 26.0002 47.6667C14.0402 47.6667 4.3335 37.96 4.3335 26ZM8.66683 26C8.66683 35.555 16.4452 43.3333 26.0002 43.3333C35.5552 43.3333 43.3335 35.555 43.3335 26C43.3335 16.445 35.5552 8.66666 26.0002 8.66666C16.4452 8.66666 8.66683 16.445 8.66683 26Z\", fill: \"#FFCC55\" }, void 0), _jsx(\"path\", { d: \"M23.8765 22.5647L26.0021 17.2941L28.1247 22.5365L28.3536 23.102L28.9612 23.1571L34.4828 23.6584L30.2532 27.5161L29.8266 27.9053L29.9504 28.4693L31.1998 34.1632L26.5355 31.2078L26.0003 30.8687L25.4651 31.2078L20.803 34.1618L22.0501 28.4995L22.1744 27.9351L21.7474 27.5456L17.5178 23.6879L23.0395 23.1866L23.648 23.1313L23.8765 22.5647Z\", fill: \"#FFCC55\", stroke: \"#FFCC55\", strokeWidth: \"2\" }, void 0)] }), void 0)) : (_jsxs(\"svg\", __assign({ \"aria-labelledby\": id, width: width !== null && width !== void 0 ? width : 24, height: height !== null && height !== void 0 ? height : 24, viewBox: \"0 0 24 24\", style: small ? { height: 16, width: 16 } : undefined, fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Engagement Points\" }), void 0), _jsx(\"path\", { opacity: \"0.4\", d: \"M12 4C7.59 4 4 7.59 4 12C4 16.41 7.59 20 12 20C16.41 20 20 16.41 20 12C20 7.59 16.41 4 12 4Z\", fill: \"#FFCC55\" }, void 0), _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M2 12C2 6.48 6.48 2 12 2C17.52 2 22 6.48 22 12C22 17.52 17.52 22 12 22C6.48 22 2 17.52 2 12ZM4 12C4 16.41 7.59 20 12 20C16.41 20 20 16.41 20 12C20 7.59 16.41 4 12 4C7.59 4 4 7.59 4 12Z\", fill: \"#FFCC55\" }, void 0), _jsx(\"path\", { d: \"M11.5191 10.6159L12.0018 9.41911L12.4814 10.6035L12.7103 11.169L13.3179 11.2242L14.6492 11.345L13.6 12.3019L13.1734 12.6911L13.2971 13.2551L13.597 14.6215L12.5352 13.9488L12 13.6096L11.4648 13.9488L10.4052 14.6201L10.7027 13.2694L10.827 12.705L10.4 12.3155L9.35085 11.3586L10.6821 11.2378L11.2906 11.1825L11.5191 10.6159Z\", stroke: \"#FFCC55\", strokeWidth: \"2\" }, void 0)] }), void 0)) }, void 0));\n};\nexport default EngagementPointsIcon;\n//# sourceMappingURL=EngagementPointsIcon.js.map","import commaNumber from 'comma-number';\nexport var isInt = function (n) {\n return Number(n) === n && n % 1 === 0;\n};\nexport var isFloat = function (n) {\n return Number(n) === n && n % 1 !== 0;\n};\nexport var numberShortener = function (n) {\n if (n < 10000) {\n return commaNumber(n);\n }\n else if (n < 1000000) {\n return Math.floor(n / 1000).toString() + 'k';\n }\n else {\n return Math.floor(n / 1000000).toString() + 'm';\n }\n};\n//# sourceMappingURL=numberUtils.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { Colors } from '../utils/colors';\nimport { makeStyles } from '@material-ui/styles';\nimport { UserContext } from '../contexts/UserContext';\nimport { useApiService } from '../services/ApiServiceProvider';\nimport { Avatar, ButtonBase, Popover } from '@material-ui/core';\nimport DefaultUserImage from './DefaultUserImage';\nimport EngagementPointsIcon from './icons/EngagementPointsIcon';\nimport TextButton from './buttons/TextButton';\nimport { useMsal } from '@azure/msal-react';\nimport { ClientType } from '../types/enums';\nimport { numberShortener } from '../utils/numberUtils';\nvar useStyles = makeStyles({\n userInfo: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n flex: 1,\n height: 36,\n width: 110,\n position: 'relative',\n cursor: 'pointer',\n },\n avatar: {\n height: 36,\n width: 36,\n border: '2px solid #ffffff',\n position: 'absolute',\n zIndex: 2,\n right: 64,\n },\n defaultImage: {\n border: '2px solid #ffffff',\n position: 'absolute',\n zIndex: 2,\n right: 64,\n borderRadius: '50%',\n },\n count: {\n backgroundColor: Colors.white,\n borderTopRightRadius: 12,\n borderBottomRightRadius: 12,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n paddingLeft: 12,\n paddingRight: 10,\n height: 28,\n width: 70,\n position: 'absolute',\n zIndex: 1,\n },\n countNumber: {\n marginLeft: 4,\n fontSize: 12,\n fontFamily: 'Open Sans',\n color: Colors.textSecondary,\n },\n popover: {\n width: 275,\n backgroundColor: Colors.white,\n padding: 16,\n borderRadius: 4,\n boxShadow: '0 12.5px 128px 4px rgba(0,0,0,0.08), 0 24px 32px 2px rgba(0,0,0,0.08)',\n display: 'flex',\n flexDirection: 'column',\n },\n});\nvar UserInfo = function (_a) {\n var clientType = _a.clientType;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = __read(useState(false), 2), openPopover = _b[0], setOpenPopover = _b[1];\n var _c = __read(useState(null), 2), anchorEl = _c[0], setAnchorEl = _c[1];\n var _d = __read(useState(''), 2), userImage = _d[0], setUserImage = _d[1];\n var _e = __read(useState(false), 2), receivedImage = _e[0], setReceivedImage = _e[1];\n var ApiService = useApiService();\n var msalInstance = useMsal();\n var getUserImage = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response, imageData, image;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getUserImages(user, [user.oid])];\n case 1:\n response = _a.sent();\n imageData = response === null || response === void 0 ? void 0 : response.data[0];\n if ((imageData === null || imageData === void 0 ? void 0 : imageData.contentType) && (imageData === null || imageData === void 0 ? void 0 : imageData.data)) {\n image = \"data:\" + imageData.contentType + \";base64,\" + imageData.data;\n setUserImage(image);\n }\n setReceivedImage(true);\n return [2];\n }\n });\n }); }, [ApiService, user]);\n useEffect(function () {\n if (!receivedImage) {\n getUserImage();\n }\n }, [getUserImage, receivedImage]);\n if (!user) {\n return null;\n }\n var toggleOpenPopover = function () {\n if (clientType !== ClientType.platform) {\n return;\n }\n setOpenPopover(!openPopover);\n };\n var onOpenPopover = function (event) {\n setAnchorEl(event.currentTarget);\n toggleOpenPopover();\n };\n var logOut = function () {\n msalInstance.instance.logout();\n };\n var terms = function () {\n window.open('https://nulia.com/terms', '_blank');\n };\n var privacy = function () {\n window.open('https://nulia.com/privacy', '_blank');\n };\n var id = openPopover ? 'user-info-popover' : undefined;\n return (_jsxs(_Fragment, { children: [_jsxs(ButtonBase, __assign({ \"aria-describedby\": id, className: classes.userInfo, onClick: onOpenPopover, style: clientType !== ClientType.platform ? { cursor: 'auto' } : undefined }, { children: [userImage ? (_jsx(Avatar, { alt: \"User\", src: userImage, className: classes.avatar }, void 0)) : (_jsx(\"div\", __assign({ className: classes.defaultImage }, { children: _jsx(DefaultUserImage, { size: 36, fontSize: 32 }, void 0) }), void 0)), _jsxs(\"div\", __assign({ className: classes.count }, { children: [_jsx(EngagementPointsIcon, {}, void 0), _jsx(\"div\", __assign({ className: classes.countNumber }, { children: numberShortener(user.engagementPoints) }), void 0)] }), void 0)] }), void 0), _jsxs(Popover, __assign({ id: id, open: openPopover, anchorEl: anchorEl, onClose: toggleOpenPopover, anchorOrigin: {\n vertical: 'bottom',\n horizontal: 'center',\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n }, classes: {\n paper: classes.popover,\n } }, { children: [_jsx(TextButton, __assign({ variant: \"purple\", onClick: terms, style: { width: '100%', marginBottom: 16, justifyContent: 'flex-start', textAlign: 'right' } }, { children: \"TERMS AND CONDITIONS\" }), void 0), _jsx(TextButton, __assign({ variant: \"purple\", onClick: privacy, style: { width: '100%', marginBottom: 16, justifyContent: 'flex-start', textAlign: 'right' } }, { children: \"PRIVACY POLICY\" }), void 0), _jsx(TextButton, __assign({ variant: \"purple\", onClick: logOut, style: { width: '100%', justifyContent: 'flex-start', textAlign: 'right' } }, { children: \"LOGOUT\" }), void 0)] }), void 0)] }, void 0));\n};\nexport default UserInfo;\n//# sourceMappingURL=UserInfo.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Badge, IconButton, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { createContext, useState, useContext } from 'react';\nimport { useHistory } from 'react-router';\nimport { Link } from 'react-router-dom';\nimport BackButton from '../components/buttons/BackButton';\nimport Tabs from '../components/Tabs';\nimport { useTypography } from '../styles/Typography';\nimport { Pages } from '../types/enums';\nimport MobileOpenNavigation from '../components/navigation/MobileOpenNavigation';\nimport { Bell } from 'react-feather';\nimport UserInfo from '../components/UserInfo';\nimport { UserContext } from './UserContext';\nexport var HeaderContext = createContext({});\nvar useStyles = makeStyles(function (theme) { return ({\n header: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n marginBottom: 24,\n borderBottom: '1px solid rgba(0,0,0,0.08)',\n paddingLeft: 16,\n paddingRight: 16,\n },\n root: {\n width: '100%',\n maxWidth: 1080,\n height: 61,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n title: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n },\n titleColumn: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-start',\n },\n}); });\nexport var pageTitleId = 'pageTitle';\nexport var HeaderProvider = function (_a) {\n var children = _a.children, defaultTitle = _a.defaultTitle, clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = __read(useState(defaultTitle !== null && defaultTitle !== void 0 ? defaultTitle : ''), 2), title = _b[0], setTitle = _b[1];\n var _c = __read(useState(false), 2), goBack = _c[0], setGoBack = _c[1];\n var _d = __read(useState(undefined), 2), tabs = _d[0], setTabs = _d[1];\n var _e = __read(useState(''), 2), page = _e[0], setPage = _e[1];\n var history = useHistory();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var isXsDown = useMediaQuery(theme.breakpoints.down('xs'));\n var back = function () {\n history.goBack();\n };\n var notificationURL = page + \"/notifications\";\n var headerContext = {\n title: title,\n setTitle: setTitle,\n goBack: goBack,\n setGoBack: setGoBack,\n tabs: tabs,\n setTabs: setTabs,\n page: page,\n setPage: setPage,\n };\n return (_jsxs(HeaderContext.Provider, __assign({ value: headerContext }, { children: [_jsxs(\"header\", __assign({ className: classes.header }, { children: [_jsxs(\"div\", __assign({ className: classes.root }, { children: [page === Pages.None && isMdDown ? (_jsxs(\"nav\", __assign({ className: classes.title }, { children: [_jsx(MobileOpenNavigation, {}, void 0), goBack && !isXsDown && (_jsxs(\"div\", __assign({ className: classes.title, style: { marginLeft: 50 } }, { children: [_jsx(BackButton, { onClick: back, style: { marginRight: 8 }, label: \"Back to \" + title }, void 0), _jsx(\"div\", __assign({ className: classes.titleColumn }, { children: _jsx(\"h1\", __assign({ \"aria-hidden\": true, id: pageTitleId, className: typo.h6 }, { children: title }), void 0) }), void 0)] }), void 0))] }), void 0)) : goBack ? (_jsxs(\"nav\", __assign({ className: classes.title }, { children: [_jsx(BackButton, { onClick: back, style: { marginRight: 8 }, label: \"Back to \" + title }, void 0), _jsx(\"div\", __assign({ className: classes.titleColumn }, { children: _jsx(\"h1\", __assign({ \"aria-hidden\": true, id: pageTitleId, className: typo.h6 }, { children: title }), void 0) }), void 0)] }), void 0)) : (_jsx(\"div\", __assign({ className: classes.titleColumn }, { children: _jsx(\"h1\", __assign({ id: pageTitleId, className: typo.h6 }, { children: title }), void 0) }), void 0)), tabs && !isXsDown && _jsx(Tabs, { tabs: tabs }, void 0), _jsxs(\"div\", __assign({ className: classes.title }, { children: [_jsx(IconButton, __assign({ component: Link, to: notificationURL, \"aria-label\": \"Go to notifications\" }, { children: _jsx(Badge, __assign({ color: \"primary\", variant: \"dot\", overlap: \"circular\", invisible: !(user === null || user === void 0 ? void 0 : user.newNotifications) }, { children: _jsx(Bell, {}, void 0) }), void 0) }), void 0), _jsx(UserInfo, { clientType: clientType }, void 0)] }), void 0)] }), void 0), tabs && isXsDown && _jsx(Tabs, { tabs: tabs }, void 0)] }), void 0), children] }), void 0));\n};\n//# sourceMappingURL=HeaderContext.js.map","import { MotdPages, PageIds } from '../types/enums';\nexport var toPreferences = function (preferences) {\n return {\n alternateEmail: preferences.alternateEmail,\n emailImportant: preferences.emailImportant,\n emailWeekly: preferences.emailWeekly,\n preferredName: preferences.preferredName,\n workEmail: preferences.workEmail,\n };\n};\nexport var toPreferencesModel = function (preferences) {\n return {\n alternateEmail: preferences.alternateEmail,\n emailImportant: preferences.emailImportant,\n emailWeekly: preferences.emailWeekly,\n preferredName: preferences.preferredName,\n workEmail: preferences.workEmail,\n };\n};\nexport var toPreferencesDTO = function (preferences) {\n return {\n alternateEmail: preferences.alternateEmail,\n emailImportant: preferences.emailImportant,\n emailWeekly: preferences.emailWeekly,\n preferredName: preferences.preferredName,\n workEmail: preferences.workEmail,\n };\n};\nexport var toTip = function (tip) {\n return {\n image: tip.image,\n message: tip.message,\n motdId: tip.motdId,\n title: tip.title,\n };\n};\nexport var toTipModel = function (tip) {\n return {\n image: tip.image,\n message: tip.message,\n motdId: tip.motdId,\n title: tip.title,\n };\n};\nexport var toSkills = function (skills) {\n return {\n inProgress: skills.inProgress,\n maintain: skills.maintain,\n needsImprovement: skills.needsImprovement,\n };\n};\nexport var toSkillsModel = function (skills) {\n return {\n inProgress: skills.inProgress,\n maintain: skills.maintain,\n needsImprovement: skills.needsImprovement,\n };\n};\nexport var toRecommendedActivity = function (activity) {\n return {\n accepted: activity.accepted,\n activityId: activity.activityId,\n contentCreated: activity.contentCreated,\n contentUpdated: activity.contentUpdated,\n description: activity.description,\n icon: activity.icon,\n id: activity.id,\n oid: activity.oid,\n priority: activity.priority,\n targetId: activity.targetId,\n text: activity.text,\n tid: activity.tid,\n type: activity.type,\n url: activity.url,\n };\n};\nexport var toRecommendedActivityModel = function (activity) {\n return {\n accepted: activity.accepted,\n activityId: activity.activityId,\n contentCreated: activity.contentCreated,\n contentUpdated: activity.contentUpdated,\n description: activity.description,\n icon: activity.icon,\n id: activity.id,\n oid: activity.oid,\n priority: activity.priority,\n targetId: activity.targetId,\n text: activity.text,\n tid: activity.tid,\n type: activity.type,\n url: activity.url,\n };\n};\nexport var toHomeBadge = function (badge) {\n return {\n assertionId: badge.assertionId,\n badgeImage: badge.badgeImage,\n badgeName: badge.badgeName,\n numBadges: badge.numBadges,\n outcomeId: badge.outcomeId,\n };\n};\nexport var toHomeBadgeModel = function (badge) {\n return {\n assertionId: badge.assertionId,\n badgeImage: badge.badgeImage,\n badgeName: badge.badgeName,\n numBadges: badge.numBadges,\n outcomeId: badge.outcomeId,\n };\n};\nexport var toHomeAchievement = function (achievement) {\n return {\n achievementImage: achievement.achievementImage,\n achievementName: achievement.achievementName,\n };\n};\nexport var toHomeAchievementModel = function (achievement) {\n return {\n achievementImage: achievement.achievementImage,\n achievementName: achievement.achievementName,\n };\n};\nexport var toStreak = function (streak) {\n return {\n skillStreakId: streak.skillStreakId,\n skillStreakLength: streak.skillStreakLength,\n skillStreakName: streak.skillStreakName,\n skillStreakTime: streak.skillStreakTime,\n };\n};\nexport var toStreakModel = function (streak) {\n return {\n skillStreakId: streak.skillStreakId,\n skillStreakLength: streak.skillStreakLength,\n skillStreakName: streak.skillStreakName,\n skillStreakTime: streak.skillStreakTime,\n };\n};\nexport var toFeedbackDataDTO = function (type, text) {\n return {\n Feedback: text,\n FeedbackType: type,\n QotwAnswerId: undefined,\n ShareAnalytics: false,\n };\n};\nexport var toNotification = function (notification) {\n return {\n created: notification.created,\n id: notification.id,\n priority: notification.priority,\n targetId: notification.targetId,\n text: notification.text,\n title: notification.title,\n type: notification.type,\n viewed: notification.viewed,\n img: notification.img,\n };\n};\nexport var toNotificationModel = function (notification) {\n return {\n created: notification.created,\n id: notification.id,\n priority: notification.priority,\n targetId: notification.targetId,\n text: notification.text,\n title: notification.title,\n type: notification.type,\n viewed: notification.viewed,\n };\n};\nexport var toNotifications = function (notifications) {\n return {\n newer: notifications.newer.map(function (value) { return toNotification(value); }),\n older: notifications.older.map(function (value) { return toNotification(value); }),\n };\n};\nexport var toNotificationsModel = function (notifications) {\n return {\n newer: notifications.newer.map(function (value) { return toNotification(value); }),\n older: notifications.older.map(function (value) { return toNotification(value); }),\n };\n};\nexport var toUserInsightOutcome = function (outcome) {\n var mappedOutcome = {\n apps: outcome.apps,\n assignment: outcome.assignment,\n categories: outcome.categories,\n contentCreated: outcome.contentCreated,\n contentUpdated: outcome.contentUpdated,\n created: outcome.created,\n currentStreak: outcome.current.currentStreak,\n id: outcome.id,\n image: outcome.image,\n isAssigned: outcome.isAssigned,\n keywords: outcome.keywords,\n level: outcome.current.level,\n name: outcome.name,\n outcomeSkillState: outcome.outcomeSkillState,\n progress: outcome.current.progress,\n progressColor: outcome.current.progressColor,\n skillCount: outcome.skillCount,\n state: outcome.current.state,\n targetLevel: outcome.current.targetLevel,\n totalSkillCount: outcome.totalSkillCount,\n };\n return mappedOutcome;\n};\nexport var toPageId = function (motdPage) {\n switch (motdPage) {\n case MotdPages.HomePage:\n return PageIds.HomePage;\n case MotdPages.SkillsPage:\n return PageIds.SkillsPage;\n case MotdPages.OutcomesPage:\n return PageIds.OutcomesPage;\n case MotdPages.ShowcasePage:\n return PageIds.ShowcasePage;\n case MotdPages.InsightsPage:\n return PageIds.InsightsPage;\n case MotdPages.PreferencesPage:\n return PageIds.PreferencesPage;\n case MotdPages.HowToPage:\n return PageIds.HowToPage;\n default:\n return PageIds.HomePage;\n }\n};\n//# sourceMappingURL=mapper.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport axios from 'axios';\nvar HelperApi = (function () {\n function HelperApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.get = function (url, headers) { return __awaiter(_this, void 0, void 0, function () {\n var response, error_1;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2, , 3]);\n return [4, axios.get(url, headers)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n else {\n return [2, response.data];\n }\n return [3, 3];\n case 2:\n error_1 = _a.sent();\n console.error(error_1);\n return [2];\n case 3: return [2];\n }\n });\n }); };\n this.post = function (url, body, headers) { return __awaiter(_this, void 0, void 0, function () {\n var response, error_2;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2, , 3]);\n return [4, axios.post(url, body, headers)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n else {\n return [2, response.data];\n }\n return [3, 3];\n case 2:\n error_2 = _a.sent();\n console.error(error_2);\n return [2];\n case 3: return [2];\n }\n });\n }); };\n this.download = function (url, body, headers, fileName) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n axios({\n url: url,\n data: body,\n method: 'POST',\n responseType: 'blob',\n headers: headers.headers,\n }).then(function (response) {\n var url = window.URL.createObjectURL(new Blob([response.data]));\n var link = document.createElement('a');\n link.href = url;\n link.setAttribute('download', fileName);\n document.body.appendChild(link);\n link.click();\n });\n return [2];\n });\n }); };\n this.getHeaders = function () {\n var _a;\n return {\n headers: {\n Authorization: \"Bearer \" + _this.token,\n 'NULIA-OID': _this.oid,\n 'NULIA-TID': _this.tid,\n 'NULIA-SID': (_a = _this.sid) !== null && _a !== void 0 ? _a : '',\n 'NULIA-SRC': 'teams',\n 'NULIA-TZ': new Date().getTimezoneOffset().toString(),\n },\n };\n };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n }\n return HelperApi;\n}());\nexport { HelperApi };\n//# sourceMappingURL=HelperApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar HomeApi = (function () {\n function HomeApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getMotds = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetMotd\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getUserSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAssignedUserSkills\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getActivityRecommendations = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetHomeRecommendations\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getTeamsBadges = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetTeamsBadges\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getTeamsAchievements = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetTeamsAchievements\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getTeamsStreaks = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetTeamsStreaks\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return HomeApi;\n}());\nexport { HomeApi };\n//# sourceMappingURL=HomeApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { toHomeAchievementModel, toHomeBadgeModel, toRecommendedActivityModel, toStreakModel } from '../utils/mapper';\nimport { HomeApi } from '../data/HomeApi';\nvar HomeService = (function () {\n function HomeService(token, oid, tid, clientType) {\n var _this = this;\n this.getMotds = function () { return __awaiter(_this, void 0, void 0, function () {\n var motds;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.homeApi.getMotds()];\n case 1:\n motds = _a.sent();\n if (!(motds === null || motds === void 0 ? void 0 : motds.data)) {\n return [2, undefined];\n }\n return [2, motds.data];\n }\n });\n }); };\n this.getActivityRecommendations = function () { return __awaiter(_this, void 0, void 0, function () {\n var activityRecommendationDto;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.homeApi.getActivityRecommendations()];\n case 1:\n activityRecommendationDto = _a.sent();\n if (!(activityRecommendationDto === null || activityRecommendationDto === void 0 ? void 0 : activityRecommendationDto.data)) {\n return [2, undefined];\n }\n return [2, activityRecommendationDto.data.map(function (value) { return toRecommendedActivityModel(value); })];\n }\n });\n }); };\n this.getBadge = function () { return __awaiter(_this, void 0, void 0, function () {\n var badge;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.homeApi.getTeamsBadges()];\n case 1:\n badge = _a.sent();\n if (!(badge === null || badge === void 0 ? void 0 : badge.data)) {\n return [2, undefined];\n }\n return [2, toHomeBadgeModel(badge.data)];\n }\n });\n }); };\n this.getAchievement = function () { return __awaiter(_this, void 0, void 0, function () {\n var achievement;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.homeApi.getTeamsAchievements()];\n case 1:\n achievement = _a.sent();\n if (!(achievement === null || achievement === void 0 ? void 0 : achievement.data)) {\n return [2, undefined];\n }\n return [2, toHomeAchievementModel(achievement.data)];\n }\n });\n }); };\n this.getStreaks = function () { return __awaiter(_this, void 0, void 0, function () {\n var streaks;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.homeApi.getTeamsStreaks()];\n case 1:\n streaks = _a.sent();\n if (!(streaks === null || streaks === void 0 ? void 0 : streaks.data)) {\n return [2, undefined];\n }\n return [2, streaks.data.map(function (value) { return toStreakModel(value); })];\n }\n });\n }); };\n this.homeApi = new HomeApi(token, oid, tid, clientType);\n }\n return HomeService;\n}());\nexport { HomeService };\n//# sourceMappingURL=HomeService.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nimport { logError } from '../utils/logError';\nvar SkillApi = (function () {\n function SkillApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getUserSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAssignedUserSkills\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getSkillDetails = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!id) {\n logError({\n name: '',\n message: 'getSkillDetails id is undefined',\n });\n }\n url = BASE_API_URL + \"/GetSkillDetails\";\n body = {\n id: id,\n };\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getAllSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAllUserSkills\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getRecommendedSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetRecommendedSkills\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getSkillUnlockCost = function (skillId, level) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetSkillUnlockCost\";\n body = {\n skillId: skillId,\n level: level,\n };\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return SkillApi;\n}());\nexport { SkillApi };\n//# sourceMappingURL=SkillApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { toSkillsModel } from '../utils/mapper';\nimport { SkillApi } from '../data/SkillApi';\nvar SkillService = (function () {\n function SkillService(token, oid, tid, clientType) {\n var _this = this;\n this.getUserSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var userSkillsDto;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.skillApi.getUserSkills()];\n case 1:\n userSkillsDto = _a.sent();\n if (!(userSkillsDto === null || userSkillsDto === void 0 ? void 0 : userSkillsDto.data)) {\n return [2, undefined];\n }\n return [2, toSkillsModel(userSkillsDto.data)];\n }\n });\n }); };\n this.getAllSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var userSkillsDto;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.skillApi.getAllSkills()];\n case 1:\n userSkillsDto = _a.sent();\n if (!(userSkillsDto === null || userSkillsDto === void 0 ? void 0 : userSkillsDto.data)) {\n return [2, undefined];\n }\n return [2, userSkillsDto.data];\n }\n });\n }); };\n this.getRecommendedSkills = function () { return __awaiter(_this, void 0, void 0, function () {\n var userSkillsDto;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.skillApi.getRecommendedSkills()];\n case 1:\n userSkillsDto = _a.sent();\n if (!(userSkillsDto === null || userSkillsDto === void 0 ? void 0 : userSkillsDto.data)) {\n return [2, undefined];\n }\n return [2, userSkillsDto.data];\n }\n });\n }); };\n this.getSkillDetails = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var skillDetailDTO;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.skillApi.getSkillDetails(id)];\n case 1:\n skillDetailDTO = _a.sent();\n if (!(skillDetailDTO === null || skillDetailDTO === void 0 ? void 0 : skillDetailDTO.data)) {\n return [2, undefined];\n }\n return [2, skillDetailDTO.data];\n }\n });\n }); };\n this.getSkillUnlockCost = function (id, level) { return __awaiter(_this, void 0, void 0, function () {\n var cost;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.skillApi.getSkillUnlockCost(id, level)];\n case 1:\n cost = _a.sent();\n if (!(cost === null || cost === void 0 ? void 0 : cost.data)) {\n return [2, undefined];\n }\n return [2, cost.data];\n }\n });\n }); };\n this.skillApi = new SkillApi(token, oid, tid, clientType);\n }\n return SkillService;\n}());\nexport { SkillService };\n//# sourceMappingURL=SkillService.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar Api = (function () {\n function Api(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getUser = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, date, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetTeamsUser\";\n date = new Date();\n body = {\n day: date.getDate(),\n month: date.getMonth() + 1,\n year: date.getFullYear(),\n clientType: this.clientType,\n };\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return Api;\n}());\nexport { Api };\n//# sourceMappingURL=Api.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { Api } from '../data/Api';\nimport { ResultCode } from '../enums/ResultCode';\nimport { LicenseClass, LicenseType } from '../types/enums';\nvar UserService = (function () {\n function UserService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getUser = function (setNoNulia) { return __awaiter(_this, void 0, void 0, function () {\n var userDto;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.api.getUser()];\n case 1:\n userDto = _a.sent();\n if (!userDto) {\n setNoNulia(true);\n }\n if ((userDto === null || userDto === void 0 ? void 0 : userDto.code) === ResultCode.NoLicense || (userDto === null || userDto === void 0 ? void 0 : userDto.code) === ResultCode.UserNotFound) {\n return [2, {\n dateAuthorized: '',\n engagementPoints: 0,\n firstName: '',\n licenseClass: LicenseClass.Complete,\n licenseType: LicenseType.None,\n newNotifications: false,\n nextScoreDate: '',\n numberLogins: 0,\n oid: '',\n role: '',\n sid: '',\n tid: '',\n }];\n }\n if ((userDto === null || userDto === void 0 ? void 0 : userDto.code) === ResultCode.NotInstalledTenant) {\n return [2, {\n dateAuthorized: '',\n engagementPoints: 0,\n firstName: '',\n licenseClass: LicenseClass.Unknown,\n licenseType: LicenseType.None,\n newNotifications: false,\n nextScoreDate: '',\n numberLogins: 0,\n oid: '',\n role: '',\n sid: '',\n tid: '',\n }];\n }\n if (!(userDto === null || userDto === void 0 ? void 0 : userDto.data)) {\n return [2];\n }\n return [2, userDto.data];\n }\n });\n }); };\n this.token = token;\n this.clientType = clientType;\n this.api = new Api(token, oid, tid, sid, clientType);\n }\n return UserService;\n}());\nexport { UserService };\n//# sourceMappingURL=UserService.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { UserContext } from '../contexts/UserContext';\nimport { UserService } from '../services/UserService';\nimport { getToken } from '../utils/getToken';\nexport var useGetUser = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var _c = useContext(UserContext), setUser = _c.setUser, setNoNulia = _c.setNoNulia;\n var getUser = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, userService, newUser;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n userService = new UserService(newToken, oid, tid, '', clientType);\n return [4, userService.getUser(setNoNulia)];\n case 2:\n newUser = _a.sent();\n if (!newUser) {\n return [2];\n }\n setUser(newUser);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetUser.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { UserContext } from '../contexts/UserContext';\nimport { HomeContext } from '../contexts/HomeContext';\nimport { HomeService } from '../services/HomeService';\nimport { SkillService } from '../services/SkillService';\nimport { toHomeAchievement, toHomeBadge, toRecommendedActivity, toSkills, toStreak } from '../utils/mapper';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nexport var useGetHomeData = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var user = useContext(UserContext).user;\n var homeContext = useContext(HomeContext);\n var getUser = useGetUser();\n var getMotd = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, homeService, motds;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n homeService = new HomeService(newToken, oid, tid, clientType);\n if (!user) {\n return [2, undefined];\n }\n return [4, homeService.getMotds()];\n case 2:\n motds = _a.sent();\n if (!motds) {\n return [2, undefined];\n }\n homeContext.setMotds(motds);\n return [2];\n }\n });\n }); };\n var getUserSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, skills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n if (!user) {\n return [2, undefined];\n }\n return [4, skillService.getUserSkills()];\n case 2:\n skills = _a.sent();\n if (!skills) {\n return [2, undefined];\n }\n homeContext.setSkills(toSkills(skills));\n return [2];\n }\n });\n }); };\n var getHomeActivityRecommendations = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, homeService, recommendations;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n homeService = new HomeService(newToken, oid, tid, clientType);\n if (!user) {\n return [2, undefined];\n }\n return [4, homeService.getActivityRecommendations()];\n case 2:\n recommendations = _a.sent();\n if (!recommendations) {\n return [2, undefined];\n }\n homeContext.setHomeActivities(recommendations.map(function (value) { return toRecommendedActivity(value); }));\n return [2];\n }\n });\n }); };\n var getBadge = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, homeService, badge;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n homeService = new HomeService(newToken, oid, tid, clientType);\n if (!user) {\n return [2, undefined];\n }\n return [4, homeService.getBadge()];\n case 2:\n badge = _a.sent();\n if (!badge) {\n return [2, undefined];\n }\n homeContext.setBadges(toHomeBadge(badge));\n return [2];\n }\n });\n }); };\n var getAchievement = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, homeService, achievement;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n homeService = new HomeService(newToken, oid, tid, clientType);\n if (!user) {\n return [2, undefined];\n }\n return [4, homeService.getAchievement()];\n case 2:\n achievement = _a.sent();\n if (!achievement) {\n return [2, undefined];\n }\n homeContext.setAchievements(toHomeAchievement(achievement));\n return [2];\n }\n });\n }); };\n var getTeamsStreaks = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, homeService, streaks;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n homeService = new HomeService(newToken, oid, tid, clientType);\n if (!user) {\n return [2, undefined];\n }\n return [4, homeService.getStreaks()];\n case 2:\n streaks = _a.sent();\n if (!streaks) {\n return [2, undefined];\n }\n homeContext.setStreaks(streaks.map(function (value) { return toStreak(value); }));\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([\n getUser(),\n getMotd(),\n getUserSkills(),\n getHomeActivityRecommendations(),\n getBadge(),\n getAchievement(),\n getTeamsStreaks(),\n ])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetHomeData.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar AchievementIcon = function (_a) {\n var width = _a.width, height = _a.height;\n var id = useUUID('achievementIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: width ? width : 125, height: height ? height : 125, viewBox: \"0 0 24 24\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Achievements\" }), void 0), _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M17.9913 22.8685C18.1014 23.6986 17.2036 24.2883 16.4855 23.8575L12 21.1662L7.5145 23.8575C6.79639 24.2884 5.89844 23.6985 6.00871 22.8683L7.1395 14.3547C5.23083 12.8926 4 10.59 4 8C4 3.58172 7.58172 0 12 0C16.4183 0 20 3.58172 20 8C20 10.5895 18.7696 12.8917 16.8616 14.3538L17.9913 22.8685ZM12 16C10.9448 16 9.93733 15.7957 9.01497 15.4245L8.26444 21.0751L11.4855 19.1425C11.8022 18.9525 12.1978 18.9525 12.5145 19.1425L15.7359 21.0753L14.9861 15.4241C14.0634 15.7956 13.0556 16 12 16ZM12 2C15.3137 2 18 4.68629 18 8C18 10.0815 16.9401 11.9154 15.3306 12.9915C15.2735 13.021 15.2198 13.0558 15.1701 13.0951C14.2503 13.6686 13.1638 14 12 14C8.68629 14 6 11.3137 6 8C6 4.68629 8.68629 2 12 2Z\", fill: \"black\", fillOpacity: \"0.32\" }, void 0)] }), void 0));\n};\nexport default AchievementIcon;\n//# sourceMappingURL=AchievementIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { IconButton, Paper } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport clsx from 'clsx';\nimport { useContext } from 'react';\nimport { HomeContext } from '../../contexts/HomeContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { ACHIEVEMENTS_PATH, APPLICATION_ID } from '../../utils/constants';\nimport AchievementIcon from '../icons/AchievementIcon';\nimport { ClientType } from '../../types/enums';\nimport { useHistory } from 'react-router-dom';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n width: 336,\n minWidth: 336,\n padding: 24,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n borderRadius: 4,\n backgroundColor: Colors.white,\n margin: 8,\n textAlign: 'center'\n },\n _a[theme.breakpoints.up('lg')] = {\n height: 378,\n },\n _a[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _a[theme.breakpoints.down('sm')] = {\n minWidth: 330,\n width: 330,\n },\n _a),\n achievement: {\n width: 154,\n height: 154,\n marginBottom: 16,\n },\n item: {\n marginBottom: 8,\n },\n focus: {\n borderRadius: 2,\n },\n hover: {\n borderRadius: 2,\n },\n });\n});\nvar AchievementCard = function (_a) {\n var clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var achievements = useContext(HomeContext).achievements;\n var history = useHistory();\n var onClick = function () {\n if (clientType === ClientType.platform) {\n history.push('/showcase');\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/d945c449-fa18-4984-b15c-dcd59ee677c0\");\n }\n };\n if (!achievements) {\n return (_jsxs(Paper, __assign({ className: classes.card }, { children: [_jsx(IconButton, __assign({ onClick: onClick, style: { marginBottom: 8 } }, { children: _jsx(AchievementIcon, {}, void 0) }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.subtitle1, classes.item) }, { children: \"Achievements\" }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.item) }, { children: \"To earn achievements, continue working on your Outcomes & Skills, and, remember, keep logging in because you never know when there could be a surprise achievement...\" }), void 0)] }), void 0));\n }\n return (_jsxs(Paper, __assign({ className: classes.card }, { children: [_jsx(IconButton, __assign({ onClick: onClick, focusVisibleClassName: classes.focus, className: classes.hover }, { children: _jsx(\"img\", { className: classes.achievement, src: \"\" + ACHIEVEMENTS_PATH + achievements.achievementImage + \".svg\", alt: \"Awarded Nulia Works Achievement\" }, void 0) }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.body1, classes.item) }, { children: achievements.achievementName }), void 0), _jsx(\"h3\", __assign({ className: clsx(typo.subtitle1, classes.item) }, { children: \"You earned an achievement\" }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.item) }, { children: \"Great job! Keep attaining Outcomes & Skills and logging in because you never know when there could be a surprise achievement...\" }), void 0)] }), void 0));\n};\nexport default AchievementCard;\n//# sourceMappingURL=AchievementCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { IconButton, Paper } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport clsx from 'clsx';\nimport { useContext } from 'react';\nimport { HomeContext } from '../../contexts/HomeContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { APPLICATION_ID, BADGES_PATH, PUBLISH_URL } from '../../utils/constants';\nimport Button from '../buttons/Button';\nimport { ClientType, PageIds } from '../../types/enums';\nimport { useHistory } from 'react-router-dom';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n width: 336,\n minWidth: 336,\n padding: 24,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n borderRadius: 4,\n backgroundColor: Colors.white,\n margin: 8,\n textAlign: 'center'\n },\n _a[theme.breakpoints.up('lg')] = {\n height: 378,\n },\n _a[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _a[theme.breakpoints.down('sm')] = {\n minWidth: 330,\n width: 330,\n },\n _a),\n placeholder: {\n width: 154,\n height: 154,\n marginBottom: 16,\n },\n badge: {\n width: 154,\n height: 154,\n marginBottom: 16,\n },\n item: {\n marginBottom: 8,\n },\n focus: {\n borderRadius: 2,\n },\n hover: {\n '&:hover': {\n borderRadius: 2,\n },\n },\n });\n});\nvar BadgeCard = function (_a) {\n var user = _a.user, clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var badges = useContext(HomeContext).badges;\n var history = useHistory();\n var post = function (e) {\n e.stopPropagation();\n window.open(PUBLISH_URL + \"/linkedin.html?oid=\" + user.oid + \"&assertionId=\" + (badges === null || badges === void 0 ? void 0 : badges.assertionId) + \"&clientType=\" + clientType);\n };\n var openOutcomeDetail = function () {\n if (clientType === ClientType.platform) {\n history.push(\"outcome-details/\" + (badges === null || badges === void 0 ? void 0 : badges.outcomeId));\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/\" + PageIds.OutcomesPage + \"?context={\\\"subEntityId\\\": \" + (badges === null || badges === void 0 ? void 0 : badges.outcomeId) + \"}\");\n }\n };\n if (!badges) {\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.card }, { children: [_jsx(\"img\", { className: classes.placeholder, src: BADGES_PATH + \"badge_empty.svg\", alt: \"Awarded Nulia Works Badge\" }, void 0), _jsx(\"h2\", __assign({ className: clsx(typo.subtitle1, classes.item) }, { children: \"Badges\" }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.item) }, { children: \"As you attain Outcomes in Nulia Works, you\\u2019ll see your badges appear here. These badges can be posted to sites like LinkedIn so you can show off your skills\" }), void 0)] }), void 0));\n }\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.card }, { children: [_jsx(IconButton, __assign({ onClick: openOutcomeDetail, focusVisibleClassName: classes.focus, className: classes.hover }, { children: _jsx(\"img\", { className: classes.badge, src: \"\" + BADGES_PATH + badges.badgeImage + \".svg\", alt: \"Awarded Nulia Works Badge\" }, void 0) }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.item) }, { children: \"Congrats!\" }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.subtitle1, classes.item) }, { children: \"You earned a badge!\" }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.item) }, { children: \"Post it on LinkedIn to show off your skills\" }), void 0), _jsx(Button, __assign({ onClick: post, style: { width: 178, height: 36, marginTop: 16 } }, { children: \"Post on LinkedIn\" }), void 0)] }), void 0));\n};\nexport default BadgeCard;\n//# sourceMappingURL=BadgeCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useEffect, useContext, useState } from 'react';\nimport { useApiService } from '../services/ApiServiceProvider';\nimport { UserContext } from '../contexts/UserContext';\nimport { Box } from '@material-ui/core';\nimport { Rating } from '@material-ui/lab';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../utils/colors';\nvar useStyles = makeStyles({\n root: {\n padding: 0,\n },\n rating: {\n color: Colors.purple,\n },\n});\nvar ContentRater = function (_a) {\n var contentId = _a.contentId, skillId = _a.skillId, _b = _a.currentRating, currentRating = _b === void 0 ? 0 : _b, getSkillOrOutcome = _a.getSkillOrOutcome;\n var classes = useStyles();\n var _c = __read(useState(0), 2), rating = _c[0], setRating = _c[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n useEffect(function () {\n setRating(currentRating);\n }, [currentRating]);\n var submitRating = function (newRating) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user || !skillId)\n return [2];\n return [4, ApiService.rateContent(user, contentId, newRating)];\n case 1:\n _a.sent();\n getSkillOrOutcome && getSkillOrOutcome();\n return [2];\n }\n });\n }); };\n var handleChange = function (event, newValue) {\n setRating(newValue !== null && newValue !== void 0 ? newValue : 0);\n submitRating(newValue !== null && newValue !== void 0 ? newValue : 0);\n };\n return (_jsx(Box, __assign({ className: classes.root, component: \"fieldset\", borderColor: \"transparent\" }, { children: _jsx(Rating, { className: classes.rating, name: \"Content Rating\", value: rating, onChange: handleChange }, void 0) }), void 0));\n};\nexport default ContentRater;\n//# sourceMappingURL=ContentRater.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useEffect, useRef, useState } from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useApiService } from '../../services/ApiServiceProvider';\nvar useStyles = makeStyles({\n video: {\n width: '100%',\n },\n});\nvar VideoPlayer = function (_a) {\n var user = _a.user, src = _a.src, contentData = _a.contentData, autoPlay = _a.autoPlay, _b = _a.watchDuration, watchDuration = _b === void 0 ? 15 : _b, disablePictureInPicture = _a.disablePictureInPicture, setVideoTime = _a.setVideoTime, finishVideo = _a.finishVideo, trackSrc = _a.trackSrc;\n var classes = useStyles();\n var videoRef = useRef(null);\n var interval = useRef(undefined);\n var ApiService = useApiService();\n var _c = __read(useState(false), 2), viewed = _c[0], setViewed = _c[1];\n var _d = __read(useState(false), 2), apiCalled = _d[0], setApiCalled = _d[1];\n useEffect(function () {\n if (!user || !setVideoTime) {\n return;\n }\n interval.current = setInterval(function () { return __awaiter(void 0, void 0, void 0, function () {\n var _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0:\n if (videoRef && videoRef.current) {\n setVideoTime(videoRef.current.currentTime);\n }\n if (!(videoRef && videoRef.current && !viewed)) return [3, 2];\n if (!(Math.floor(videoRef.current.currentTime) >=\n Math.floor(videoRef.current.duration) - watchDuration - 1)) return [3, 2];\n if (interval.current) {\n clearInterval(interval.current);\n }\n if (finishVideo) {\n finishVideo();\n }\n if (!!apiCalled) return [3, 2];\n setApiCalled(true);\n return [4, ApiService.viewedContent(user, (_a = contentData === null || contentData === void 0 ? void 0 : contentData.contentId) !== null && _a !== void 0 ? _a : -1)];\n case 1:\n _b.sent();\n setViewed(true);\n _b.label = 2;\n case 2: return [2];\n }\n });\n }); }, 1000);\n return function () {\n if (interval.current) {\n clearInterval(interval.current);\n }\n };\n });\n var onContextMenu = function (e) { return e.preventDefault(); };\n return (_jsxs(\"video\", __assign({ controls: true, controlsList: \"nodownload\", ref: videoRef, autoPlay: autoPlay === undefined ? true : autoPlay, className: classes.video, onContextMenu: onContextMenu, disablePictureInPicture: disablePictureInPicture, crossOrigin: \"anonymous\" }, { children: [_jsx(\"source\", { src: src, type: \"video/mp4\" }, void 0), _jsx(\"track\", { src: trackSrc, kind: \"captions\", srcLang: \"en\", label: \"English\" }, void 0), \"Your browser does not support the\", _jsx(\"code\", { children: \"video\" }, void 0), \" element.\"] }), void 0));\n};\nexport default VideoPlayer;\n//# sourceMappingURL=VideoPlayer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Dialog, DialogActions, DialogContent } from '@material-ui/core';\nimport * as queryString from 'query-string';\nimport { useContext, useEffect, useState } from 'react';\nimport ContentRater from '../ContentRater';\nimport VideoPlayer from './VideoPlayer';\nimport { useTheme, makeStyles } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport { isBefore } from 'date-fns';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport Button from '../buttons/Button';\nimport { UserContext } from '../../contexts/UserContext';\nimport { Colors } from '../../utils/colors';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n videoContainer: (_a = {\n padding: 0\n },\n _a[theme.breakpoints.up('md')] = {\n width: 720,\n },\n _a),\n contentRater: {\n marginRight: 16,\n },\n });\n});\nvar VideoDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, contentData = _a.contentData, finishVideo = _a.finishVideo, getSkillOrOutcome = _a.getSkillOrOutcome;\n var _b = __read(useState(undefined), 2), token = _b[0], setToken = _b[1];\n var _c = __read(useState(false), 2), hasToken = _c[0], setHasToken = _c[1];\n var _d = __read(useState(undefined), 2), trackToken = _d[0], setTrackToken = _d[1];\n var _e = __read(useState(0), 2), videoTime = _e[0], setVideoTime = _e[1];\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var theme = useTheme();\n var isSmallDown = useMediaQuery(theme.breakpoints.down('sm'));\n var ApiService = useApiService();\n useEffect(function () {\n var getBlobToken = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, newTrackToken;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!contentData || hasToken || !user) {\n return [2];\n }\n return [4, ApiService.getBlobToken(user, contentData.container, contentData.fileName)];\n case 1:\n newToken = _a.sent();\n if (!newToken) {\n return [2];\n }\n setToken(newToken);\n setHasToken(true);\n return [4, ApiService.getBlobToken(user, contentData.container, contentData.contentId + \".vtt\")];\n case 2:\n newTrackToken = _a.sent();\n if (!newTrackToken) {\n return [2];\n }\n setTrackToken(newTrackToken);\n return [2];\n }\n });\n }); };\n if (!token) {\n getBlobToken();\n }\n if (token && contentData) {\n var uriParams = queryString.parse(token);\n if (uriParams.se) {\n if (isBefore(new Date(uriParams.se), new Date())) {\n getBlobToken();\n }\n }\n }\n }, [ApiService, contentData, hasToken, token, user, videoTime]);\n if (!token || !user) {\n return null;\n }\n return (_jsxs(Dialog, __assign({ open: open, onClose: onClose, maxWidth: 'lg', fullScreen: isSmallDown }, { children: [_jsx(DialogContent, __assign({ className: classes.videoContainer, tabIndex: 0 }, { children: _jsx(VideoPlayer, { user: user, src: token, trackSrc: trackToken, contentData: contentData, setVideoTime: setVideoTime, finishVideo: finishVideo }, void 0) }), void 0), _jsxs(DialogActions, { children: [_jsx(\"div\", __assign({ className: classes.contentRater }, { children: _jsx(ContentRater, { contentId: contentData.contentId, skillId: contentData.skillId, currentRating: contentData.rating, getSkillOrOutcome: getSkillOrOutcome }, void 0) }), void 0), _jsx(Button, __assign({ style: { backgroundColor: Colors.purple, color: Colors.white, width: 100 }, onClick: onClose }, { children: 'Close' }), void 0)] }, void 0)] }), void 0));\n};\nexport default VideoDialog;\n//# sourceMappingURL=VideoDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core';\nimport { useEffect, useRef, useState } from 'react';\nimport { useApiService } from '../../services/ApiServiceProvider';\nvar useStyles = makeStyles({\n audioPlayer: {\n maxWidth: '100%',\n },\n});\nvar AudioPlayer = function (_a) {\n var user = _a.user, src = _a.src, contentData = _a.contentData;\n var audioRef = useRef(null);\n var classes = useStyles();\n var ApiService = useApiService();\n var _b = __read(useState(false), 2), apiCalled = _b[0], setApiCalled = _b[1];\n var _c = __read(useState(false), 2), viewed = _c[0], setViewed = _c[1];\n useEffect(function () {\n var interval;\n if (audioRef && audioRef.current && !viewed) {\n interval = setInterval(function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!(audioRef && audioRef.current && !audioRef.current.paused)) return [3, 2];\n if (!(Math.floor(audioRef.current.currentTime) >= Math.floor(audioRef.current.duration) - 15)) return [3, 2];\n if (interval) {\n clearInterval(interval);\n }\n if (!!apiCalled) return [3, 2];\n return [4, ApiService.viewedContent(user, contentData.contentId)];\n case 1:\n _a.sent();\n setViewed(true);\n setApiCalled(true);\n _a.label = 2;\n case 2: return [2];\n }\n });\n }); }, 1000);\n }\n return function () {\n if (interval) {\n clearInterval(interval);\n }\n };\n }, [\n ApiService,\n apiCalled,\n contentData.container,\n contentData.contentId,\n contentData.fileName,\n contentData.views,\n user,\n viewed,\n ]);\n return (_jsxs(\"audio\", __assign({ controls: true, autoPlay: true, src: src, className: classes.audioPlayer, controlsList: \"nodownload\", ref: audioRef }, { children: [\"Your browser does not support the\", _jsx(\"code\", { children: \"audio\" }, void 0), \" element.\"] }), void 0));\n};\nexport default AudioPlayer;\n//# sourceMappingURL=AudioPlayer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Dialog, DialogActions, DialogContent, makeStyles } from '@material-ui/core';\nimport { useTheme } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport { isBefore } from 'date-fns';\nimport * as queryString from 'query-string';\nimport { useContext, useEffect, useState } from 'react';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { Colors } from '../../utils/colors';\nimport Button from '../buttons/Button';\nimport ContentRater from '../ContentRater';\nimport AudioPlayer from './AudioPlayer';\nvar useStyles = makeStyles({\n root: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n contentRater: {\n marginRight: 16,\n },\n});\nvar AudioDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, contentData = _a.contentData;\n var _b = __read(useState(undefined), 2), token = _b[0], setToken = _b[1];\n var _c = __read(useState(false), 2), hasToken = _c[0], setHasToken = _c[1];\n var user = useContext(UserContext).user;\n var theme = useTheme();\n var isSmallDown = useMediaQuery(theme.breakpoints.down('sm'));\n var classes = useStyles();\n var ApiService = useApiService();\n useEffect(function () {\n if (!token) {\n getBlobToken();\n }\n if (token && contentData) {\n var uriParams = queryString.parse(token);\n if (uriParams.se) {\n if (isBefore(new Date(uriParams.se), new Date())) {\n getBlobToken();\n }\n }\n }\n });\n var getBlobToken = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!contentData || hasToken || !user) {\n return [2];\n }\n setHasToken(true);\n return [4, ApiService.getBlobToken(user, contentData.container, contentData.fileName)];\n case 1:\n newToken = _a.sent();\n if (!newToken) {\n }\n setToken(newToken);\n return [2];\n }\n });\n }); };\n var close = function () {\n onClose();\n };\n if (!token || !user) {\n return null;\n }\n return (_jsxs(Dialog, __assign({ open: open, onClose: close, fullWidth: true, fullScreen: isSmallDown }, { children: [_jsx(DialogContent, __assign({ className: classes.root }, { children: _jsx(AudioPlayer, { user: user, src: token, contentData: contentData, viewed: contentData.views > 0 }, void 0) }), void 0), _jsxs(DialogActions, { children: [_jsx(\"div\", __assign({ className: classes.contentRater }, { children: _jsx(ContentRater, { contentId: contentData.contentId, skillId: contentData.skillId, currentRating: contentData.rating }, void 0) }), void 0), _jsx(Button, __assign({ style: { backgroundColor: Colors.purple, color: Colors.white, width: 100 }, onClick: close }, { children: 'Close' }), void 0), ' '] }, void 0)] }), void 0));\n};\nexport default AudioDialog;\n//# sourceMappingURL=AudioDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Dialog, DialogActions, DialogContent, IconButton, makeStyles } from '@material-ui/core';\nimport { useTheme } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport clsx from 'clsx';\nimport { isBefore } from 'date-fns';\nimport * as queryString from 'query-string';\nimport { useContext, useEffect, useRef, useState } from 'react';\nimport { pdfjs, Document, Page } from 'react-pdf';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { Colors } from '../../utils/colors';\nimport Button from '../buttons/Button';\nimport { ChevronLeft, ChevronRight, Maximize, Minimize, ZoomIn, ZoomOut } from 'react-feather';\nimport axios from 'axios';\nimport { logError } from '../../utils/logError';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n controls: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n height: 24,\n },\n pager: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n marginRight: 16,\n },\n pageText: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n letterSpacing: 0.1,\n lineHeight: '24px',\n },\n zoom: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n margin: {\n marginRight: '8px !important',\n },\n dialogContent: {\n padding: 0,\n position: 'relative',\n },\n document: {\n display: 'flex',\n justifyContent: 'center',\n },\n documentAbsolute: {\n position: 'absolute',\n top: 0,\n left: 0,\n },\n contentRater: (_a = {\n marginRight: 16\n },\n _a[theme.breakpoints.only('xs')] = {\n marginRight: 12,\n },\n _a),\n button: {\n border: 'none',\n padding: 0,\n margin: 0,\n textDecoration: 'none',\n background: 'transparent',\n color: Colors.textPrimary,\n fontFamily: 'Open Sans',\n fontSize: '1rem',\n cursor: 'pointer',\n textAlign: 'center',\n transition: 'background 250ms ease-in-out, transform 150ms ease',\n '-webkit-appearance': 'none',\n '-moz-appearance': 'none',\n '&:focus': {\n outline: 0,\n },\n '&:disabled': {\n color: Colors.disabled,\n boxShadow: 'none',\n cursor: 'not-allowed',\n },\n height: 24,\n width: 24,\n },\n srOnly: {\n position: 'absolute',\n right: 10000,\n },\n overflow: {\n overflow: 'auto',\n },\n });\n});\nvar PdfDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, contentData = _a.contentData;\n var classes = useStyles();\n var theme = useTheme();\n var isLargeUp = useMediaQuery(theme.breakpoints.up('lg'));\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n var _b = __read(useState(false), 2), hasToken = _b[0], setHasToken = _b[1];\n var _c = __read(useState(undefined), 2), token = _c[0], setToken = _c[1];\n var _d = __read(useState(isLargeUp ? 1.25 : 1), 2), scale = _d[0], setScale = _d[1];\n var _e = __read(useState(1), 2), pageNumber = _e[0], setPageNumber = _e[1];\n var _f = __read(useState(1), 2), currentNumPages = _f[0], setNumPages = _f[1];\n var _g = __read(useState(false), 2), fullScreen = _g[0], setFullScreen = _g[1];\n var pdfRef = useRef(null);\n var ApiService = useApiService();\n var _h = __read(useState(false), 2), apiCalled = _h[0], setApiCalled = _h[1];\n var _j = __read(useState(false), 2), viewed = _j[0], setViewed = _j[1];\n var _k = __read(useState(), 2), file = _k[0], setFile = _k[1];\n var user = useContext(UserContext).user;\n useEffect(function () {\n pdfjs.GlobalWorkerOptions.workerSrc = \"//cdnjs.cloudflare.com/ajax/libs/pdf.js/\" + pdfjs.version + \"/pdf.worker.js\";\n }, []);\n useEffect(function () {\n window.history.pushState(null, '', window.location.pathname);\n window.addEventListener('popstate', handleBrowserBackClick);\n return function () {\n window.removeEventListener('popstate', handleBrowserBackClick);\n };\n }, []);\n useEffect(function () {\n if (!token) {\n getBlobToken();\n }\n if (token && contentData) {\n var uriParams = queryString.parse(token);\n if (uriParams.se) {\n if (isBefore(new Date(uriParams.se), new Date())) {\n getBlobToken();\n }\n }\n }\n });\n var getFile = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newFile, error_1;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n _a.trys.push([0, 2, , 3]);\n return [4, axios.get(token, {\n responseType: 'arraybuffer',\n })];\n case 1:\n newFile = _a.sent();\n setFile(newFile.data);\n return [3, 3];\n case 2:\n error_1 = _a.sent();\n console.error(error_1);\n logError(error_1);\n return [3, 3];\n case 3: return [2];\n }\n });\n }); };\n useEffect(function () {\n if (token && !file) {\n getFile();\n }\n });\n var getBlobToken = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!contentData || hasToken || !user) {\n return [2];\n }\n setHasToken(true);\n return [4, ApiService.getBlobToken(user, contentData.container, contentData.fileName)];\n case 1:\n newToken = _a.sent();\n if (!newToken) {\n return [2];\n }\n setToken(newToken);\n return [2];\n }\n });\n }); };\n var onDocumentComplete = function (_a) {\n var numPages = _a.numPages;\n setNumPages(numPages);\n };\n var handleBack = function () { return setPageNumber(pageNumber === 1 ? 1 : pageNumber - 1); };\n var handleNext = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n setPageNumber(pageNumber === currentNumPages ? pageNumber : pageNumber + 1);\n if (!(pageNumber === currentNumPages - 1 && !viewed)) return [3, 2];\n if (!(!apiCalled && user)) return [3, 2];\n return [4, ApiService.viewedContent(user, contentData.contentId)];\n case 1:\n _a.sent();\n setViewed(true);\n setApiCalled(true);\n _a.label = 2;\n case 2: return [2];\n }\n });\n }); };\n var zoomIn = function () { return setScale(scale + 0.25); };\n var zoomOut = function () { return setScale(scale - 0.25); };\n var onFullScreen = function () { return setFullScreen(!fullScreen); };\n var handleAddPoints = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!(currentNumPages === 1)) return [3, 3];\n if (!(!apiCalled && user)) return [3, 2];\n return [4, ApiService.viewedContent(user, contentData.contentId)];\n case 1:\n _a.sent();\n setViewed(true);\n setApiCalled(true);\n _a.label = 2;\n case 2: return [3, 4];\n case 3: return [2];\n case 4: return [2];\n }\n });\n }); };\n var handleBrowserBackClick = function () {\n handleAddPoints();\n setFullScreen(false);\n onClose();\n };\n var close = function () {\n history.back();\n handleAddPoints();\n setFullScreen(false);\n onClose();\n };\n if (!file) {\n return null;\n }\n var useAbsolutePdf = pdfRef && pdfRef.current ? pdfRef.current.clientWidth > window.innerWidth : false;\n return (_jsxs(Dialog, __assign({ open: open, onClose: close, maxWidth: 'lg', fullScreen: isMediumDown || fullScreen }, { children: [_jsx(DialogContent, __assign({ className: classes.dialogContent, tabIndex: 0 }, { children: _jsx(\"div\", __assign({ className: useAbsolutePdf ? classes.documentAbsolute : classes.document }, { children: _jsx(Document, __assign({ className: classes.overflow, file: file, onLoadSuccess: onDocumentComplete, ref: pdfRef }, { children: _jsx(Page, { pageNumber: pageNumber, scale: scale, renderMode: \"canvas\", renderTextLayer: true }, void 0) }), void 0) }), void 0) }), void 0), _jsxs(DialogActions, { children: [_jsxs(\"div\", __assign({ className: classes.controls }, { children: [_jsxs(\"div\", __assign({ className: classes.pager }, { children: [_jsx(\"div\", __assign({ className: classes.margin }, { children: \"Page \" + pageNumber + \" of \" + currentNumPages }), void 0), _jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"left arrow\", onClick: handleBack, disabled: pageNumber === 1 }, { children: _jsx(ChevronLeft, {}, void 0) }), void 0), _jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"right arrow\", onClick: handleNext, disabled: pageNumber === currentNumPages }, { children: _jsx(ChevronRight, {}, void 0) }), void 0)] }), void 0), !isMediumDown && (_jsx(IconButton, __assign({ className: clsx(classes.margin, classes.button), \"aria-label\": !fullScreen ? 'maximize' : 'minimize', onClick: onFullScreen }, { children: !fullScreen ? _jsx(Maximize, {}, void 0) : _jsx(Minimize, {}, void 0) }), void 0)), (isMediumDown || fullScreen) && (_jsxs(\"div\", __assign({ className: classes.zoom }, { children: [_jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"zoom out\", onClick: zoomOut }, { children: _jsx(ZoomOut, {}, void 0) }), void 0), _jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"zoom in\", onClick: zoomIn }, { children: _jsx(ZoomIn, {}, void 0) }), void 0)] }), void 0))] }), void 0), _jsx(Button, __assign({ style: { backgroundColor: Colors.purple, color: Colors.white, width: 100 }, onClick: close }, { children: 'Close' }), void 0)] }, void 0)] }), void 0));\n};\nexport default PdfDialog;\n//# sourceMappingURL=PdfDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Dialog, DialogActions, DialogContent, IconButton, makeStyles } from '@material-ui/core';\nimport { Maximize, Minimize } from 'react-feather';\nimport { useTheme } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport clsx from 'clsx';\nimport { useState, useContext, useEffect } from 'react';\nimport { useApiService } from '../services/ApiServiceProvider';\nimport { Colors } from '../utils/colors';\nimport ContentRater from './ContentRater';\nimport Button from './buttons/Button';\nimport { CDN_URL } from '../utils/constants';\nimport { UserContext } from '../contexts/UserContext';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n controls: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n height: 24,\n },\n pager: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n marginRight: 16,\n },\n pageText: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n letterSpacing: 0.1,\n lineHeight: '24px',\n },\n zoom: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n margin: {\n marginRight: '8px !important',\n },\n dialogContent: {\n padding: 0,\n position: 'relative',\n },\n document: {\n display: 'flex',\n justifyContent: 'center',\n },\n documentAbsolute: {\n position: 'absolute',\n top: 0,\n left: 0,\n },\n contentRater: (_a = {\n marginRight: 16\n },\n _a[theme.breakpoints.only('xs')] = {\n marginRight: 12,\n },\n _a),\n button: {\n border: 'none',\n padding: 0,\n margin: 0,\n textDecoration: 'none',\n background: 'transparent',\n color: Colors.textPrimary,\n fontFamily: 'Open Sans',\n fontSize: '1rem',\n cursor: 'pointer',\n textAlign: 'center',\n transition: 'background 250ms ease-in-out, transform 150ms ease',\n '-webkit-appearance': 'none',\n '-moz-appearance': 'none',\n '&:focus': {\n outline: 0,\n },\n '&:disabled': {\n color: Colors.disabled,\n boxShadow: 'none',\n cursor: 'not-allowed',\n },\n height: 24,\n width: 24,\n },\n srOnly: {\n position: 'absolute',\n right: 10000,\n },\n overflow: {\n overflow: 'auto',\n },\n });\n});\nvar HtmlDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, contentData = _a.contentData;\n var classes = useStyles();\n var theme = useTheme();\n var isExtraSmall = useMediaQuery(theme.breakpoints.only('xs'));\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n var _b = __read(useState(false), 2), fullScreen = _b[0], setFullScreen = _b[1];\n var ApiService = useApiService();\n var user = useContext(UserContext).user;\n useEffect(function () {\n window.history.pushState(null, '', window.location.pathname);\n window.addEventListener('popstate', handleBrowserBackClick);\n return function () {\n window.removeEventListener('popstate', handleBrowserBackClick);\n };\n }, []);\n var onFullScreen = function () { return setFullScreen(function (fS) { return !fS; }); };\n var handleAddPoints = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user)\n return [2];\n return [4, ApiService.viewedContent(user, contentData.contentId)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n var handleBrowserBackClick = function () {\n handleAddPoints();\n setFullScreen(false);\n onClose();\n };\n var close = function () {\n history.back();\n handleAddPoints();\n setFullScreen(false);\n onClose();\n };\n return (_jsxs(Dialog, __assign({ open: open, onClose: close, maxWidth: 'lg', fullScreen: isMediumDown || fullScreen }, { children: [_jsx(DialogContent, __assign({ className: classes.dialogContent, tabIndex: 0 }, { children: _jsx(\"div\", __assign({ style: {\n width: isMediumDown || fullScreen ? '100%' : 1040,\n height: isMediumDown || fullScreen ? 'calc(100% - 12px)' : '80vh',\n } }, { children: _jsx(\"iframe\", { title: \"Html Knowledge Articles\", src: CDN_URL + \"/howto\" + contentData.htmlSrc, frameBorder: \"0\", style: {\n width: 1,\n minWidth: '100%',\n height: isMediumDown || fullScreen ? '100%' : 'calc(80vh - 20px)',\n } }, void 0) }), void 0) }), void 0), isExtraSmall && (_jsx(DialogActions, { children: _jsx(\"div\", __assign({ className: classes.contentRater }, { children: _jsx(ContentRater, { contentId: contentData.contentId, skillId: contentData.skillId, currentRating: contentData.rating }, void 0) }), void 0) }, void 0)), _jsxs(DialogActions, { children: [!isExtraSmall && (_jsx(\"div\", __assign({ className: classes.contentRater }, { children: _jsx(ContentRater, { contentId: contentData.contentId, skillId: contentData.skillId, currentRating: contentData.rating }, void 0) }), void 0)), _jsx(\"div\", __assign({ className: classes.controls }, { children: !isMediumDown && (_jsx(IconButton, __assign({ className: clsx(classes.margin, classes.button), \"aria-label\": !fullScreen ? 'maximize' : 'minimize', onClick: onFullScreen }, { children: !fullScreen ? _jsx(Maximize, {}, void 0) : _jsx(Minimize, {}, void 0) }), void 0)) }), void 0), _jsx(Button, __assign({ style: { backgroundColor: Colors.purple, color: Colors.white, width: 100 }, onClick: close }, { children: 'Close' }), void 0)] }, void 0)] }), void 0));\n};\nexport default HtmlDialog;\n//# sourceMappingURL=HtmlDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Dialog as MuiDialog, DialogActions, DialogContent } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { isMobile } from 'is-mobile';\nimport { useTypography } from '../styles/Typography';\nimport Button from './buttons/Button';\nimport SecondaryButton from './buttons/SecondaryButton';\nvar useStyles = makeStyles({\n dialogContent: {\n paddingTop: 24,\n paddingBottom: 24,\n paddingLeft: 32,\n paddingRight: 32,\n },\n dialogTitle: {\n paddingTop: 32,\n paddingLeft: 32,\n paddingRight: 32,\n },\n dialogButtonsContainer: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginTop: 32,\n },\n buttons: {\n paddingBottom: 24,\n paddingLeft: 32,\n paddingRight: 32,\n paddingTop: 32,\n },\n content: {\n paddingLeft: 32,\n paddingRight: 32,\n paddingBottom: 0,\n paddingTop: 16,\n },\n paper: {\n width: 400,\n },\n contentAndText: {\n marginTop: 16,\n },\n});\nvar Dialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, onAccept = _a.onAccept, title = _a.title, text = _a.text, content = _a.content, cancelText = _a.cancelText, acceptText = _a.acceptText, disabled = _a.disabled, cancelDisabled = _a.cancelDisabled, wide = _a.wide, height = _a.height;\n var typo = useTypography();\n var classes = useStyles();\n return (_jsxs(MuiDialog, __assign({ open: open, onClose: onClose, classes: {\n paperWidthSm: !wide ? classes.paper : undefined,\n }, fullScreen: isMobile(), \"aria-labelledby\": \"modal-title\", \"aria-describedby\": \"modal-description\", scroll: \"body\" }, { children: [_jsx(\"h3\", __assign({ id: \"modal-title\", className: clsx(typo.subtitle1, classes.dialogTitle) }, { children: title }), void 0), _jsxs(DialogContent, __assign({ className: classes.content, style: !wide && !isMobile() ? { height: height } : undefined }, { children: [content, text && (_jsx(\"p\", __assign({ id: \"modal-description\", className: clsx(typo.body1, content ? classes.contentAndText : undefined) }, { children: text }), void 0))] }), void 0), _jsx(DialogActions, __assign({ className: classes.buttons }, { children: _jsxs(\"div\", __assign({ className: clsx(cancelText && onClose && acceptText && onAccept && classes.dialogButtonsContainer) }, { children: [cancelText && onClose && (_jsx(SecondaryButton, __assign({ focusOnMount: disabled, disabled: cancelDisabled, onClick: onClose, style: { marginRight: 8, width: 108, height: 32 } }, { children: cancelText }), void 0)), acceptText && onAccept && (_jsx(Button, __assign({ focusOnMount: true, disabled: disabled, onClick: onAccept, style: !disabled\n ? {\n width: 108,\n height: 32,\n color: '#fff',\n backgroundColor: '#57599B',\n }\n : { width: 108, height: 32 } }, { children: acceptText }), void 0))] }), void 0) }), void 0)] }), void 0));\n};\nexport default Dialog;\n//# sourceMappingURL=Dialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nimport VideoDialog from '../components/video/VideoDialog';\nimport AudioDialog from '../components/audio/AudioDialog';\nimport PdfDialog from '../components/pdf/PdfDialog';\nimport HtmlDialog from '../components/HtmlDialog';\nimport Dialog from '../components/Dialog';\nimport { TEAMS_PATH } from '../utils/constants';\nimport { useTypography } from '../styles/Typography';\nexport var DialogContext = createContext({});\nexport var DialogProvider = function (_a) {\n var children = _a.children;\n var typo = useTypography();\n var _b = __read(useState(undefined), 2), videoDialogContent = _b[0], setVideoDialogContent = _b[1];\n var _c = __read(useState(false), 2), openVideoDialog = _c[0], setOpenVideoDialog = _c[1];\n var _d = __read(useState(undefined), 2), pdfDialogContent = _d[0], setPdfDialogContent = _d[1];\n var _e = __read(useState(false), 2), openPdfDialog = _e[0], setOpenPdfDialog = _e[1];\n var _f = __read(useState(undefined), 2), audioDialogContent = _f[0], setAudioDialogContent = _f[1];\n var _g = __read(useState(false), 2), openAudioDialog = _g[0], setOpenAudioDialog = _g[1];\n var _h = __read(useState(undefined), 2), htmlDialogContent = _h[0], setHtmlDialogContent = _h[1];\n var _j = __read(useState(false), 2), openHtmlDialog = _j[0], setOpenHtmlDialog = _j[1];\n var _k = __read(useState(undefined), 2), tryItContent = _k[0], setTryItContent = _k[1];\n var _l = __read(useState(false), 2), openTryItDialog = _l[0], setOpenTryItDialog = _l[1];\n var _m = __read(useState(undefined), 2), copyContent = _m[0], setCopyContent = _m[1];\n var _o = __read(useState(false), 2), openCopyDialog = _o[0], setOpenCopyDialog = _o[1];\n var dialogContext = {\n videoDialogContent: videoDialogContent,\n setVideoDialogContent: setVideoDialogContent,\n openVideoDialog: openVideoDialog,\n setOpenVideoDialog: setOpenVideoDialog,\n pdfDialogContent: pdfDialogContent,\n setPdfDialogContent: setPdfDialogContent,\n openPdfDialog: openPdfDialog,\n setOpenPdfDialog: setOpenPdfDialog,\n audioDialogContent: audioDialogContent,\n setAudioDialogContent: setAudioDialogContent,\n openAudioDialog: openAudioDialog,\n setOpenAudioDialog: setOpenAudioDialog,\n htmlDialogContent: htmlDialogContent,\n setHtmlDialogContent: setHtmlDialogContent,\n openHtmlDialog: openHtmlDialog,\n setOpenHtmlDialog: setOpenHtmlDialog,\n tryItContent: tryItContent,\n setTryItContent: setTryItContent,\n openTryItDialog: openTryItDialog,\n setOpenTryItDialog: setOpenTryItDialog,\n copyContent: copyContent,\n setCopyContent: setCopyContent,\n openCopyDialog: openCopyDialog,\n setOpenCopyDialog: setOpenCopyDialog,\n };\n var onCloseVideoDialog = function () { return setOpenVideoDialog(false); };\n var onCloseAudioDialog = function () { return setOpenAudioDialog(false); };\n var onClosePdfDialog = function () { return setOpenPdfDialog(false); };\n var onCloseHtmlDialog = function () { return setOpenHtmlDialog(false); };\n var onCloseTryItDialog = function () { return setOpenTryItDialog(false); };\n var onCloseCopyDialog = function () { return setOpenCopyDialog(false); };\n var isLarge = function (str) {\n var regex = /lg/;\n return regex.test(str);\n };\n return (_jsxs(DialogContext.Provider, __assign({ value: dialogContext }, { children: [children, videoDialogContent && (_jsx(VideoDialog, { open: openVideoDialog, onClose: onCloseVideoDialog, contentData: videoDialogContent }, videoDialogContent === null || videoDialogContent === void 0 ? void 0 : videoDialogContent.contentId)), pdfDialogContent && openPdfDialog && (_jsx(PdfDialog, { contentData: pdfDialogContent, onClose: onClosePdfDialog, open: openPdfDialog }, pdfDialogContent === null || pdfDialogContent === void 0 ? void 0 : pdfDialogContent.contentId)), audioDialogContent && (_jsx(AudioDialog, { open: openAudioDialog, onClose: onCloseAudioDialog, contentData: audioDialogContent }, audioDialogContent === null || audioDialogContent === void 0 ? void 0 : audioDialogContent.contentId)), htmlDialogContent && openHtmlDialog && (_jsx(HtmlDialog, { open: openHtmlDialog, onClose: onCloseHtmlDialog, contentData: htmlDialogContent }, void 0)), tryItContent && (_jsx(Dialog, { open: openTryItDialog, onClose: onCloseTryItDialog, title: tryItContent.name, content: isLarge(tryItContent.icon) ? (_jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'column',\n width: '100%',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n } }, { children: [_jsx(\"img\", { src: \"\" + TEAMS_PATH + tryItContent.icon + \".svg\", alt: \"\" + tryItContent.icon, style: { width: 163, height: 55, marginBottom: 8 } }, void 0), _jsx(\"p\", __assign({ className: typo.body1 }, { children: tryItContent.description }), void 0)] }), void 0)) : (_jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n width: '100%',\n justifyContent: 'flex-start',\n alignItems: 'center',\n } }, { children: [_jsx(\"img\", { src: \"\" + TEAMS_PATH + tryItContent.icon + \".svg\", alt: \"\" + tryItContent.icon, style: { width: 65, height: 55, marginRight: 16 } }, void 0), _jsx(\"p\", __assign({ className: typo.body1 }, { children: tryItContent.description }), void 0)] }), void 0)), onAccept: onCloseTryItDialog, acceptText: 'Okay' }, void 0)), copyContent && (_jsx(Dialog, { open: openCopyDialog, onClose: onCloseCopyDialog, title: copyContent.name, content: _jsx(_Fragment, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n width: '100%',\n justifyContent: 'flex-start',\n alignItems: 'center',\n } }, { children: [_jsx(\"img\", { src: \"\" + TEAMS_PATH + copyContent.icon, alt: \"\", style: { width: 55, height: 55, marginRight: 16 } }, void 0), _jsx(\"p\", __assign({ className: typo.body1 }, { children: copyContent.description }), void 0)] }), void 0) }, void 0), onAccept: onCloseCopyDialog, acceptText: 'Okay' }, void 0))] }), void 0));\n};\n//# sourceMappingURL=DialogContext.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar BestPracticeVideoIcon = function () {\n var id = useUUID();\n return (_jsxs(\"svg\", __assign({ width: \"24\", height: \"24\", viewBox: \"0 0 24 24\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", style: { width: 48, height: 48 }, \"aria-labelledby\": \"bestPracticeVideoIconTitleId-\" + id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: \"bestPracticeVideoIconTitleId-\" + id }, { children: \"Best Practice Video\" }), void 0), _jsx(\"path\", { d: \"M19.82 2H4.18C2.97602 2 2 2.97602 2 4.18V19.82C2 21.024 2.97602 22 4.18 22H19.82C21.024 22 22 21.024 22 19.82V4.18C22 2.97602 21.024 2 19.82 2Z\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M7 2V22\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M17 2V22\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M2 12H22\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M2 7H7\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M2 17H7\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M17 17H22\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M17 7H22\", stroke: \"#ADADAD\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0)] }), void 0));\n};\nexport default BestPracticeVideoIcon;\n//# sourceMappingURL=BestPracticeVideoIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport addDays from 'date-fns/addDays';\nimport compareDesc from 'date-fns/compareDesc';\nimport { Colors } from '../utils/colors';\nvar useStyles = makeStyles({\n new: {\n fontFamily: 'Ubuntu',\n fontSize: 12,\n fontWeight: 'bold',\n fontStyle: 'normal',\n lineHeight: '16px',\n letterSpacing: '2px',\n color: Colors.purple,\n textAlign: 'left',\n margin: 0,\n },\n updated: {\n fontFamily: 'Ubuntu',\n fontSize: 12,\n fontWeight: 'bold',\n fontStyle: 'normal',\n lineHeight: '16px',\n letterSpacing: '2px',\n color: Colors.userSkill,\n textAlign: 'left',\n margin: 0,\n },\n});\nvar NewUpdatedLabel = function (_a) {\n var createdDate = _a.createdDate, updatedDate = _a.updatedDate;\n var classes = useStyles();\n var isNew = createdDate ? compareDesc(new Date(createdDate), addDays(new Date(), -14)) : undefined;\n var isUpdated = updatedDate ? compareDesc(new Date(updatedDate), addDays(new Date(), -14)) : undefined;\n if (isNew === -1) {\n return _jsx(\"p\", __assign({ className: classes.new }, { children: \"NEW\" }), void 0);\n }\n else if (isUpdated === -1) {\n return _jsx(\"p\", __assign({ className: classes.updated }, { children: \"UPDATED\" }), void 0);\n }\n else {\n return null;\n }\n};\nexport default NewUpdatedLabel;\n//# sourceMappingURL=NewUpdatedLabel.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { ButtonBase } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useState } from 'react';\nimport { DialogContext } from '../contexts/DialogContext';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport NewUpdatedLabel from './NewUpdatedLabel';\nimport { ResourceType } from '../types/enums';\nimport { Book, Image, List, PieChart, Play, Volume1, Monitor } from 'react-feather';\nvar useStyles = makeStyles({\n resource: {\n padding: '8px 0',\n width: '100%',\n justifyContent: 'left',\n },\n icon: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n marginRight: 16,\n },\n label: {\n marginRight: 8,\n },\n});\nvar Resource = function (_a) {\n var resource = _a.resource, skillId = _a.skillId, tabIndex = _a.tabIndex;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState(false), 2), mouseOver = _b[0], setMouseOver = _b[1];\n var _c = __read(useState(false), 2), mouseDown = _c[0], setMouseDown = _c[1];\n var _d = useContext(DialogContext), setOpenPdfDialog = _d.setOpenPdfDialog, setVideoDialogContent = _d.setVideoDialogContent, setAudioDialogContent = _d.setAudioDialogContent, setPdfDialogContent = _d.setPdfDialogContent, setOpenAudioDialog = _d.setOpenAudioDialog, setOpenVideoDialog = _d.setOpenVideoDialog, setOpenHtmlDialog = _d.setOpenHtmlDialog, setHtmlDialogContent = _d.setHtmlDialogContent;\n var resourceData;\n switch (resource.type) {\n case ResourceType.MixedMediaHtml: {\n resourceData = {\n icon: _jsx(Monitor, {}, void 0),\n label: 'Multimedia',\n fileType: 'html',\n };\n break;\n }\n case ResourceType.StepByStepPdf: {\n resourceData = {\n icon: _jsx(List, {}, void 0),\n label: 'Step by Step',\n fileType: 'pdf',\n };\n break;\n }\n case ResourceType.PhotoGuidePdf: {\n resourceData = {\n icon: _jsx(Image, {}, void 0),\n label: 'Picture Guide',\n fileType: 'pdf',\n };\n break;\n }\n case ResourceType.StepByStepVideo: {\n resourceData = {\n icon: _jsx(Play, {}, void 0),\n label: 'Step by Step',\n fileType: 'mp4',\n };\n break;\n }\n case ResourceType.InfographicPdf: {\n resourceData = {\n icon: _jsx(PieChart, {}, void 0),\n label: 'Infographic',\n fileType: 'pdf',\n };\n break;\n }\n case ResourceType.InfographicVideo: {\n resourceData = {\n icon: _jsx(Play, {}, void 0),\n label: 'Infographic',\n fileType: 'mp4',\n };\n break;\n }\n case ResourceType.StoryVideo: {\n resourceData = {\n icon: _jsx(Play, {}, void 0),\n label: 'Story',\n fileType: 'mp4',\n };\n break;\n }\n case ResourceType.LightheartedPodcast: {\n resourceData = {\n icon: _jsx(Volume1, {}, void 0),\n label: 'Lighthearted',\n fileType: 'mp3',\n };\n break;\n }\n case ResourceType.LightheartedPdf: {\n resourceData = {\n icon: _jsx(Book, {}, void 0),\n label: 'Lighthearted',\n fileType: 'pdf',\n };\n break;\n }\n case ResourceType.LightheartedVideo: {\n resourceData = {\n icon: _jsx(Play, {}, void 0),\n label: 'Lighthearted',\n fileType: 'mp4',\n };\n break;\n }\n case ResourceType.StoryPdf: {\n resourceData = {\n icon: _jsx(Book, {}, void 0),\n label: 'Story',\n fileType: 'pdf',\n };\n break;\n }\n case ResourceType.StoryPodcast: {\n resourceData = {\n icon: _jsx(Volume1, {}, void 0),\n label: 'Story',\n fileType: 'mp3',\n };\n break;\n }\n case ResourceType.StepByStepHtml: {\n resourceData = {\n icon: _jsx(List, {}, void 0),\n label: 'Step by Step',\n fileType: 'html',\n };\n break;\n }\n case ResourceType.StoryHtml: {\n resourceData = {\n icon: _jsx(Book, {}, void 0),\n label: 'Story',\n fileType: 'html',\n };\n break;\n }\n case ResourceType.InfographicHtml: {\n resourceData = {\n icon: _jsx(PieChart, {}, void 0),\n label: 'Infographic',\n fileType: 'html',\n };\n break;\n }\n case ResourceType.PhotoGuideHtml: {\n resourceData = {\n icon: _jsx(Image, {}, void 0),\n label: 'Picture Guide',\n fileType: 'html',\n };\n break;\n }\n case ResourceType.LightheartedHtml: {\n resourceData = {\n icon: _jsx(Book, {}, void 0),\n label: 'Lighthearted',\n fileType: 'html',\n };\n break;\n }\n default: {\n resourceData = {\n icon: _jsx(List, {}, void 0),\n label: 'Step by Step',\n fileType: 'pdf',\n };\n break;\n }\n }\n var onMouseOver = function () { return setMouseOver(true); };\n var onMouseOut = function () {\n setMouseOver(false);\n setMouseDown(false);\n };\n var onMouseDown = function () { return setMouseDown(true); };\n var onMouseUp = function () { return setMouseDown(false); };\n var viewContent = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (resourceData.fileType) {\n case 'mp4': {\n setVideoDialogContent({\n container: 'content',\n fileName: resource.id + \".\" + resourceData.fileType,\n contentId: resource.id,\n views: resource.views,\n rating: resource.rating,\n skillId: skillId,\n });\n setOpenVideoDialog(true);\n break;\n }\n case 'pdf': {\n setPdfDialogContent({\n container: 'content',\n fileName: resource.id + \".\" + resourceData.fileType,\n contentId: resource.id,\n views: resource.views,\n rating: resource.rating,\n skillId: skillId,\n });\n setOpenPdfDialog(true);\n break;\n }\n case 'mp3': {\n setAudioDialogContent({\n container: 'content',\n fileName: resource.id + \".\" + resourceData.fileType,\n contentId: resource.id,\n views: resource.views,\n rating: resource.rating,\n skillId: skillId,\n });\n setOpenAudioDialog(true);\n break;\n }\n case 'html': {\n setHtmlDialogContent({\n container: 'content',\n fileName: resource.id + \".\" + resourceData.fileType,\n contentId: resource.id,\n views: resource.views,\n rating: resource.rating,\n htmlSrc: resource.url,\n });\n setOpenHtmlDialog(true);\n break;\n }\n default: {\n break;\n }\n }\n return [2];\n });\n }); };\n return (_jsxs(ButtonBase, __assign({ className: classes.resource, onMouseOver: onMouseOver, onMouseOut: onMouseOut, onMouseDown: onMouseDown, onMouseUp: onMouseUp, onClick: viewContent, tabIndex: tabIndex }, { children: [_jsx(\"span\", __assign({ className: classes.icon }, { children: resourceData.icon }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.body1, classes.label), style: {\n color: mouseOver && !mouseDown ? Colors.textPrimary : mouseDown ? Colors.purple : Colors.textSecondary,\n } }, { children: resourceData.label }), void 0), _jsx(NewUpdatedLabel, { createdDate: resource.contentCreated, updatedDate: resource.contentUpdated }, void 0)] }), void 0));\n};\nexport default Resource;\n//# sourceMappingURL=Resource.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Accordion, AccordionDetails, AccordionSummary } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useState } from 'react';\nimport { useTypography } from '../styles/Typography';\nimport { useUUID } from '../hooks/useUUID';\nimport { ChevronDown, Lock } from 'react-feather';\nvar useStyles = makeStyles({\n header: {\n display: 'grid',\n gridAutoFlow: 'column',\n justifyContent: 'left',\n gridGap: 8,\n textTransform: 'uppercase',\n },\n rootExpanded: {\n margin: 0,\n padding: 0,\n '&.MuiAccordionSummary-root.Mui-expanded': {\n minHeight: 'unset',\n },\n },\n expanded: {\n margin: 0,\n padding: 0,\n '&$expanded': {\n margin: 0,\n },\n },\n root: {\n margin: 0,\n padding: 0,\n },\n});\nvar ResourceAccordion = function (_a) {\n var locked = _a.locked, children = _a.children;\n var typo = useTypography();\n var classes = useStyles();\n var id = useUUID();\n var _b = __read(useState(false), 2), expanded = _b[0], setExpanded = _b[1];\n var handleExpand = function () { return setExpanded(!expanded); };\n return (_jsxs(Accordion, __assign({ expanded: expanded, onChange: handleExpand, elevation: 0 }, { children: [_jsx(AccordionSummary, __assign({ className: classes.header, classes: { content: classes.expanded, root: classes.rootExpanded }, expandIcon: locked ? _jsx(Lock, {}, void 0) : _jsx(ChevronDown, {}, void 0), \"aria-controls\": id + \"-content\", id: id + \"-header\" }, { children: _jsx(\"p\", __assign({ className: typo.overlineMini }, { children: \"Resources\" }), void 0) }), void 0), _jsx(AccordionDetails, __assign({ classes: { root: classes.root } }, { children: children }), void 0)] }), void 0));\n};\nexport default ResourceAccordion;\n//# sourceMappingURL=ResourceAccordion.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Box, Grid, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { format } from 'date-fns';\nimport { useContext } from 'react';\nimport { DialogContext } from '../contexts/DialogContext';\nimport { useTypography } from '../styles/Typography';\nimport { BLOB_CONTAINER } from '../utils/constants';\nimport Button from './buttons/Button';\nimport BestPracticeVideoIcon from './icons/BestPracticeVideoIcon';\nimport NewUpdatedLabel from './NewUpdatedLabel';\nimport Resource from './Resource';\nimport ResourceAccordion from './ResourceAccordion';\nimport { ActivityType, ClientType } from '../types/enums';\nimport { Book, ExternalLink, File, Play } from 'react-feather';\nimport { detect } from 'detect-browser';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n header: (_a = {\n display: 'grid',\n gridGap: 16\n },\n _a[theme.breakpoints.up('md')] = {\n gridTemplateColumns: '1fr auto',\n },\n _a),\n resources: {\n marginTop: 8,\n },\n viewResources: {\n marginRight: 16,\n padding: 2,\n },\n resourceList: {\n marginTop: 8,\n width: '100%',\n },\n gridItem: (_b = {\n width: '50%'\n },\n _b[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _b),\n watchedDate: {\n fontSize: 10,\n lineHeight: '20px',\n letterSpacing: 0.416667,\n },\n newUpdated: {\n display: 'grid',\n gridAutoFlow: 'column',\n gridGap: 16,\n alignItems: 'center',\n justifyContent: 'left',\n },\n });\n});\nvar Activity = function (_a) {\n var _b, _c, _d;\n var activity = _a.activity, skillId = _a.skillId, withoutAccordion = _a.withoutAccordion, _e = _a.headingLevel, headingLevel = _e === void 0 ? 2 : _e, home = _a.home, clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var _f = useContext(DialogContext), setTryItContent = _f.setTryItContent, setOpenTryItDialog = _f.setOpenTryItDialog, setVideoDialogContent = _f.setVideoDialogContent, setOpenVideoDialog = _f.setOpenVideoDialog, setPdfDialogContent = _f.setPdfDialogContent, setOpenPdfDialog = _f.setOpenPdfDialog, setCopyContent = _f.setCopyContent, setOpenCopyDialog = _f.setOpenCopyDialog;\n var theme = useTheme();\n var isSmallDown = useMediaQuery(theme.breakpoints.down('sm'));\n var openEdge = function (url) {\n var browser = detect();\n if ((browser === null || browser === void 0 ? void 0 : browser.name) === 'chrome' || clientType === ClientType.android || clientType === ClientType.desktop) {\n window.open(\"microsoft-edge:\" + url, '_blank');\n }\n else {\n window.open(\"\" + url, '_blank');\n }\n };\n var openApp = function () {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2;\n if (activity.type === ActivityType.Watch) {\n var contentData = {\n container: BLOB_CONTAINER,\n fileName: ((_c = (_b = (_a = activity.resources) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.id) !== null && _c !== void 0 ? _c : -1) + \".mp4\",\n contentId: (_f = (_e = (_d = activity.resources) === null || _d === void 0 ? void 0 : _d[0]) === null || _e === void 0 ? void 0 : _e.id) !== null && _f !== void 0 ? _f : -1,\n views: (_j = (_h = (_g = activity.resources) === null || _g === void 0 ? void 0 : _g[0]) === null || _h === void 0 ? void 0 : _h.views) !== null && _j !== void 0 ? _j : 0,\n rating: (_m = (_l = (_k = activity.resources) === null || _k === void 0 ? void 0 : _k[0]) === null || _l === void 0 ? void 0 : _l.rating) !== null && _m !== void 0 ? _m : 0,\n skillId: skillId,\n };\n setVideoDialogContent(contentData);\n setOpenVideoDialog(true);\n }\n else if (activity.type === ActivityType.View) {\n var contentData = {\n container: BLOB_CONTAINER,\n fileName: ((_q = (_p = (_o = activity.resources) === null || _o === void 0 ? void 0 : _o[0]) === null || _p === void 0 ? void 0 : _p.id) !== null && _q !== void 0 ? _q : -1) + \".pdf\",\n contentId: (_t = (_s = (_r = activity.resources) === null || _r === void 0 ? void 0 : _r[0]) === null || _s === void 0 ? void 0 : _s.id) !== null && _t !== void 0 ? _t : -1,\n views: (_w = (_v = (_u = activity.resources) === null || _u === void 0 ? void 0 : _u[0]) === null || _v === void 0 ? void 0 : _v.views) !== null && _w !== void 0 ? _w : 0,\n rating: (_z = (_y = (_x = activity.resources) === null || _x === void 0 ? void 0 : _x[0]) === null || _y === void 0 ? void 0 : _y.rating) !== null && _z !== void 0 ? _z : 0,\n skillId: skillId,\n };\n setPdfDialogContent(contentData);\n setOpenPdfDialog(true);\n }\n else if (activity.flags === 2) {\n setCopyContent({\n name: activity.text,\n description: (_0 = activity === null || activity === void 0 ? void 0 : activity.description) !== null && _0 !== void 0 ? _0 : '',\n icon: (_1 = activity === null || activity === void 0 ? void 0 : activity.icon) !== null && _1 !== void 0 ? _1 : '',\n url: (_2 = activity === null || activity === void 0 ? void 0 : activity.app.url) !== null && _2 !== void 0 ? _2 : '',\n });\n setOpenCopyDialog(true);\n }\n else if (activity.icon && activity.description && clientType !== ClientType.platform) {\n setTryItContent({\n name: activity.text,\n description: activity.description,\n icon: activity.icon,\n });\n setOpenTryItDialog(true);\n }\n else {\n var url = activity.app && activity.app.url ? activity.app.url : undefined;\n if (activity.app && activity.app.url && activity.app.name === 'SharePoint') {\n url += '/_layouts/15/sharepoint.aspx';\n }\n if (activity.flags === 1) {\n openEdge(url);\n }\n else {\n window.open(url, '_blank');\n }\n }\n };\n return (_jsxs(\"div\", { children: [_jsxs(\"div\", __assign({ className: classes.header }, { children: [_jsxs(\"div\", __assign({ className: classes.newUpdated }, { children: [activity.type === ActivityType.Watch && _jsx(BestPracticeVideoIcon, {}, void 0), activity.type === ActivityType.View && (_jsx(Book, { style: { width: 48, height: 48, color: '#ADADAD' } }, void 0)), _jsxs(\"div\", { children: [home && (_jsx(\"p\", __assign({ className: typo.overline, style: { marginBottom: 8 } }, { children: \"Here's your next step\" }), void 0)), _jsx(\"h2\", __assign({ \"aria-level\": headingLevel, className: typo.subtitle1 }, { children: activity.text }), void 0)] }, void 0), _jsx(NewUpdatedLabel, { createdDate: activity.contentCreated, updatedDate: activity.contentUpdated }, void 0)] }), void 0), _jsxs(Button, __assign({ style: {\n width: 108,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n }, onClick: openApp }, { children: [_jsx(Box, __assign({ \"aria-hidden\": true, marginRight: 1, component: \"span\", display: \"flex\", alignItems: \"center\", justifyContent: \"center\" }, { children: activity.type === ActivityType.TryIt ? (_jsx(ExternalLink, {}, void 0)) : activity.type === ActivityType.Watch ? (_jsx(Play, {}, void 0)) : activity.type === ActivityType.View ? (_jsx(File, {}, void 0)) : undefined }), void 0), activity.type === ActivityType.TryIt\n ? 'Try It'\n : activity.type === ActivityType.Watch\n ? 'Watch'\n : activity.type === ActivityType.View\n ? 'View'\n : undefined] }), void 0)] }), void 0), activity.type !== ActivityType.TryIt &&\n ((_b = activity.resources) === null || _b === void 0 ? void 0 : _b[0].lastViewed) &&\n (isSmallDown ? (_jsx(\"span\", __assign({ className: clsx(typo.caption, classes.watchedDate) }, { children: format(new Date((_c = activity.resources) === null || _c === void 0 ? void 0 : _c[0].lastViewed), 'PP') }), void 0)) : (_jsx(\"div\", __assign({ className: classes.watchedDate }, { children: \" \" + (activity.type === ActivityType.Watch ? 'Watched on' : 'Viewed on') + \" \" + format(new Date((_d = activity.resources) === null || _d === void 0 ? void 0 : _d[0].lastViewed), 'PP') }), void 0))), activity.resources && activity.type === ActivityType.TryIt && (_jsx(_Fragment, { children: withoutAccordion ? (_jsx(\"div\", __assign({ className: classes.resources }, { children: _jsx(\"div\", __assign({ className: classes.viewResources }, { children: _jsx(\"div\", __assign({ className: classes.resourceList }, { children: _jsx(Grid, __assign({ container: true }, { children: activity.resources.map(function (resource) { return (_jsx(Grid, __assign({ item: true, className: classes.gridItem }, { children: _jsx(Resource, { resource: resource, skillId: skillId }, void 0) }), resource.id)); }) }), void 0) }), void 0) }), void 0) }), void 0)) : (_jsx(\"div\", __assign({ className: classes.resources }, { children: _jsx(\"div\", __assign({ className: classes.viewResources }, { children: _jsx(ResourceAccordion, { children: _jsx(\"div\", __assign({ className: classes.resourceList }, { children: _jsx(Grid, __assign({ container: true }, { children: activity.resources.map(function (resource) { return (_jsx(Grid, __assign({ item: true, className: classes.gridItem }, { children: _jsx(Resource, { resource: resource, skillId: skillId }, void 0) }), resource.id)); }) }), void 0) }), void 0) }, void 0) }), void 0) }), void 0)) }, void 0))] }, void 0));\n};\nexport default Activity;\n//# sourceMappingURL=Activity.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport clsx from 'clsx';\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { Colors } from '../utils/colors';\nimport TextButton from './buttons/TextButton';\nimport Activity from './Activity';\nimport { ClientType } from '../types/enums';\nimport { useHistory } from 'react-router-dom';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { SkillService } from '../services/SkillService';\nimport { Paper } from '@material-ui/core';\nimport { getToken } from '../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { APPLICATION_ID } from '../utils/constants';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f;\n return ({\n card: (_a = {\n width: 510,\n padding: 24,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column'\n },\n _a[theme.breakpoints.up('lg')] = {\n minHeight: 204,\n },\n _a[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n largeCard: (_b = {\n width: 1040,\n padding: 24,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column'\n },\n _b[theme.breakpoints.up('lg')] = {\n height: 204,\n },\n _b[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 330,\n minHeight: 348,\n },\n _b),\n title: (_c = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'flex-start',\n minHeight: 48\n },\n _c[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n },\n _c),\n button: (_d = {},\n _d[theme.breakpoints.down('sm')] = {\n marginTop: 8,\n },\n _d),\n resourceList: (_e = {\n minWidth: 350\n },\n _e[theme.breakpoints.down('sm')] = {\n width: 282,\n },\n _e),\n gridItem: (_f = {\n width: '50%'\n },\n _f[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _f),\n innerGridItem: {},\n });\n});\nvar RecommendedActivity = function (_a) {\n var recommendedActivity = _a.recommendedActivity, large = _a.large, home = _a.home;\n var classes = useStyles();\n var clientType = useContext(TokenContext).clientType;\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid;\n var _d = __read(useState(undefined), 2), details = _d[0], setDetails = _d[1];\n var _e = __read(useState(undefined), 2), activity = _e[0], setActivity = _e[1];\n var _f = __read(useState(false), 2), receivedData = _f[0], setReceivedData = _f[1];\n var history = useHistory();\n var getDetails = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, response, activities;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getSkillDetails(recommendedActivity.targetId)];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setDetails(response);\n activities = [];\n if (response.userLevel) {\n activities.push.apply(activities, __spreadArray([], __read(response.userLevel.activities), false));\n }\n if (response.producerLevel) {\n activities.push.apply(activities, __spreadArray([], __read(response.producerLevel.activities), false));\n }\n if (response.masterLevel) {\n activities.push.apply(activities, __spreadArray([], __read(response.masterLevel.activities), false));\n }\n activities.forEach(function (value) {\n if (value.id === recommendedActivity.activityId) {\n setActivity(value);\n return;\n }\n });\n setReceivedData(true);\n return [2];\n }\n });\n }); }, [\n account,\n clientType,\n instance,\n oid,\n recommendedActivity.activityId,\n recommendedActivity.targetId,\n ssoToken,\n tid,\n ]);\n useEffect(function () {\n if (!receivedData) {\n getDetails();\n }\n }, [receivedData, getDetails]);\n var openSkillDetail = function () {\n if (clientType === ClientType.platform) {\n history.push(\"/skill-details/\" + recommendedActivity.targetId);\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/ef9b5db3-e49a-4fdd-8e29-ccedda0ffbc7?context={\\\"subEntityId\\\": \" + recommendedActivity.targetId + \"}\");\n }\n };\n if (!activity) {\n return null;\n }\n return (_jsxs(Paper, __assign({ className: clsx(large ? classes.largeCard : classes.card) }, { children: [_jsx(Activity, { activity: activity, skillId: recommendedActivity.targetId, withoutAccordion: true, home: home, clientType: clientType }, void 0), _jsx(TextButton, __assign({ variant: \"purple\", onClick: openSkillDetail, style: {\n fontSize: 12,\n lineHeight: '14px',\n fontWeight: 'normal',\n textTransform: 'none',\n letterSpacing: 'normal',\n padding: 0,\n textAlign: 'left',\n justifyContent: 'flex-start',\n } }, { children: _jsxs(\"span\", { children: [_jsx(\"span\", __assign({ style: { color: Colors.black, marginRight: 4 } }, { children: \"Part of\" }), void 0), details === null || details === void 0 ? void 0 : details.name] }, void 0) }), void 0)] }), void 0));\n};\nexport default RecommendedActivity;\n//# sourceMappingURL=RecommendedActivity.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var LockContext = createContext({});\nexport var LockProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(false), 2), disabled = _b[0], setDisabled = _b[1];\n var userContext = {\n disabled: disabled,\n setDisabled: setDisabled,\n };\n return _jsx(LockContext.Provider, __assign({ value: userContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=LockContext.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles, Tooltip as MuiTooltip } from '@material-ui/core';\nimport { Colors } from '../utils/colors';\nvar useStyles = makeStyles(function (theme) { return ({\n tooltip: {\n boxShadow: theme.shadows[1],\n backgroundColor: Colors.white,\n color: Colors.black,\n fontSize: 12,\n fontFamily: 'Ubuntu',\n fontStyle: 'normal',\n fontWeight: 'normal',\n },\n span: {\n margin: 0,\n padding: 0,\n display: 'flex',\n },\n}); });\nexport var Tooltip = function (_a) {\n var title = _a.title, children = _a.children;\n var classes = useStyles();\n return (_jsx(MuiTooltip, __assign({ classes: { tooltip: classes.tooltip }, title: title, interactive: true }, { children: _jsx(\"div\", __assign({ className: classes.span }, { children: children }), void 0) }), void 0));\n};\n//# sourceMappingURL=Tooltip.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar OutcomeApi = (function () {\n function OutcomeApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getOutcomeUnlockCost = function (outcomeId, level) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetOutcomeUnlockCost\";\n body = {\n outcomeId: outcomeId,\n level: level,\n };\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getUserOutcomes = function () { return __awaiter(_this, void 0, void 0, function () {\n var headers, url;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n url = BASE_API_URL + \"/GetAssignedUserOutcomes\";\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getRecommendedOutcomes = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetRecommendedOutcomes\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getAllOutcomes = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAllUserOutcomes\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getOutcomeDetails = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetOutcomeDetails\";\n body = {\n id: id,\n };\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getOutcomeActivityRecommendations = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetOutcomeActivityRecommendations\";\n body = {\n id: id,\n };\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return OutcomeApi;\n}());\nexport { OutcomeApi };\n//# sourceMappingURL=OutcomeApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { OutcomeApi } from '../data/OutcomeApi';\nvar OutcomeService = (function () {\n function OutcomeService(token, oid, tid, clientType) {\n var _this = this;\n this.getUserOutcomes = function () { return __awaiter(_this, void 0, void 0, function () {\n var userOutcomes;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.outcomeApi.getUserOutcomes()];\n case 1:\n userOutcomes = _a.sent();\n if (!(userOutcomes === null || userOutcomes === void 0 ? void 0 : userOutcomes.data)) {\n return [2, undefined];\n }\n return [2, userOutcomes.data];\n }\n });\n }); };\n this.getRecommendedOutcomes = function () { return __awaiter(_this, void 0, void 0, function () {\n var recommendedOutcomes;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.outcomeApi.getRecommendedOutcomes()];\n case 1:\n recommendedOutcomes = _a.sent();\n if (!(recommendedOutcomes === null || recommendedOutcomes === void 0 ? void 0 : recommendedOutcomes.data)) {\n return [2, undefined];\n }\n return [2, recommendedOutcomes.data];\n }\n });\n }); };\n this.getAllOutcomes = function () { return __awaiter(_this, void 0, void 0, function () {\n var allOutcomes;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.outcomeApi.getAllOutcomes()];\n case 1:\n allOutcomes = _a.sent();\n if (!(allOutcomes === null || allOutcomes === void 0 ? void 0 : allOutcomes.data)) {\n return [2, undefined];\n }\n return [2, allOutcomes.data];\n }\n });\n }); };\n this.getOutcomeDetails = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var outcomeDetails;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.outcomeApi.getOutcomeDetails(id)];\n case 1:\n outcomeDetails = _a.sent();\n if (!(outcomeDetails === null || outcomeDetails === void 0 ? void 0 : outcomeDetails.data)) {\n return [2, undefined];\n }\n return [2, outcomeDetails.data];\n }\n });\n }); };\n this.getOutcomeActivityRecommendations = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var recommendations;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.outcomeApi.getOutcomeActivityRecommendations(id)];\n case 1:\n recommendations = _a.sent();\n if (!(recommendations === null || recommendations === void 0 ? void 0 : recommendations.data)) {\n return [2, undefined];\n }\n return [2, recommendations.data];\n }\n });\n }); };\n this.getOutcomeUnlockCost = function (id, level) { return __awaiter(_this, void 0, void 0, function () {\n var cost;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.outcomeApi.getOutcomeUnlockCost(id, level)];\n case 1:\n cost = _a.sent();\n if (!(cost === null || cost === void 0 ? void 0 : cost.data)) {\n return [2, undefined];\n }\n return [2, cost.data];\n }\n });\n }); };\n this.outcomeApi = new OutcomeApi(token, oid, tid, '', clientType);\n }\n return OutcomeService;\n}());\nexport { OutcomeService };\n//# sourceMappingURL=OutcomeService.js.map","export var isOutcome = function (skillOrOutcome) {\n return skillOrOutcome.skillCount !== undefined;\n};\n//# sourceMappingURL=isOutcome.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { IconButton } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useState } from 'react';\nimport { LockContext } from '../../contexts/LockContext';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { Colors } from '../../utils/colors';\nimport Dialog from '../Dialog';\nimport { Tooltip } from '../Tooltip';\nimport TextButton from './TextButton';\nimport Button from './Button';\nimport { Plus } from 'react-feather';\nimport { getToken } from '../../utils/getToken';\nimport { OutcomeService } from '../../services/OutcomeService';\nimport { SkillService } from '../../services/SkillService';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n addButton: {\n height: 38,\n minHeight: 38,\n width: 38,\n minWidth: 38,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: '50%',\n backgroundColor: 'transparent',\n color: Colors.purple,\n },\n disabled: {\n color: Colors.textSecondary,\n backgroundColor: Colors.background,\n },\n clickable: {\n '&:hover': {\n backgroundColor: Colors.iconHover,\n cursor: 'pointer',\n },\n '&:focus': {\n backgroundColor: Colors.iconHover,\n },\n },\n large: {\n height: 48,\n width: 48,\n },\n});\nvar AddButton = function (_a) {\n var _b, _c, _d;\n var user = _a.user, level = _a.level, skillOrOutcome = _a.skillOrOutcome, recommended = _a.recommended, onAccept = _a.onAccept, large = _a.large, describedById = _a.describedById, textFormat = _a.textFormat, starter = _a.starter, variant = _a.variant;\n var classes = useStyles();\n var _e = useMsal(), instance = _e.instance, accounts = _e.accounts;\n var account = useAccount(accounts[0]);\n var _f = useContext(TokenContext), ssoToken = _f.ssoToken, oid = _f.oid, tid = _f.tid, clientType = _f.clientType;\n var _g = __read(useState(false), 2), mouseOver = _g[0], setMouseOver = _g[1];\n var _h = __read(useState(false), 2), mouseDown = _h[0], setMouseDown = _h[1];\n var _j = __read(useState(false), 2), open = _j[0], setOpen = _j[1];\n var _k = __read(useState(0), 2), cost = _k[0], setCost = _k[1];\n var _l = useContext(LockContext), disabled = _l.disabled, setDisabled = _l.setDisabled;\n var ApiService = useApiService();\n var type = isOutcome(skillOrOutcome) ? 'outcome' : 'skill';\n var onMouseOver = function () { return setMouseOver(true); };\n var onMouseOut = function () {\n setMouseOver(false);\n setMouseDown(false);\n };\n var onMouseDown = function () { return setMouseDown(true); };\n var onMouseUp = function () { return setMouseDown(false); };\n var onClick = function () { return __awaiter(void 0, void 0, void 0, function () {\n var _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0:\n if (!isOutcome(skillOrOutcome)) return [3, 2];\n return [4, getOutcomeCost()];\n case 1:\n _a = _b.sent();\n return [3, 4];\n case 2: return [4, getSkillCost()];\n case 3:\n _a = _b.sent();\n _b.label = 4;\n case 4:\n _a;\n setOpen(true);\n return [2];\n }\n });\n }); };\n var closeDialog = function () {\n setOpen(false);\n };\n var accepted = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n closeDialog();\n setDisabled(true);\n return [4, ApiService.changeTargetLevel(user, user.oid, level, skillOrOutcome.id, type, recommended, false)];\n case 1:\n _a.sent();\n if (!onAccept) return [3, 3];\n return [4, onAccept()];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3:\n setDisabled(false);\n return [2];\n }\n });\n }); };\n var getSkillCost = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getSkillUnlockCost(skillOrOutcome.id, level)];\n case 2:\n response = _a.sent();\n setCost(response !== null && response !== void 0 ? response : 0);\n return [2];\n }\n });\n }); };\n var getOutcomeCost = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getOutcomeUnlockCost(skillOrOutcome.id, level)];\n case 2:\n response = _a.sent();\n setCost(response !== null && response !== void 0 ? response : 0);\n return [2];\n }\n });\n }); };\n var title = \"Add \" + (type === 'outcome' ? 'Outcome' : 'Skill');\n return (_jsxs(_Fragment, { children: [!textFormat ? (_jsx(Tooltip, __assign({ title: title }, { children: _jsx(IconButton, __assign({ className: clsx(classes.addButton, large ? classes.large : undefined, !disabled ? classes.clickable : undefined, (disabled || starter) && classes.disabled), onClick: !disabled ? onClick : undefined, onMouseOver: !disabled ? onMouseOver : undefined, onMouseOut: !disabled ? onMouseOut : undefined, onMouseDown: !disabled ? onMouseDown : undefined, onMouseUp: !disabled ? onMouseUp : undefined, style: {\n border: disabled\n ? ''\n : mouseOver && !mouseDown\n ? \"1px solid \" + Colors.textPrimary\n : mouseDown\n ? '1px solid rgba(101,78,163,0.24)'\n : '1px solid rgba(101, 78, 163, 0.24)',\n }, \"aria-label\": title, \"aria-describedby\": describedById }, { children: _jsx(Plus, {}, void 0) }), void 0) }), void 0)) : variant === 'home' ? (_jsx(Button, __assign({ disabled: disabled || starter, onClick: !disabled && !starter ? onClick : undefined, style: type === 'outcome' ? { width: 136 } : { width: 100 } }, { children: \"Add \" + (type === 'outcome' ? 'Outcome' : 'Skill') }), void 0)) : (_jsx(TextButton, __assign({ disabled: disabled || starter, onClick: !disabled && !starter ? onClick : undefined, variant: \"purple\", style: { lineHeight: '40px', fontSize: 10, paddingLeft: 0, paddingRight: 0 } }, { children: \"Add \" + (type === 'outcome' ? 'Outcome' : 'Skill') }), void 0)), _jsx(Dialog, { open: open, onClose: closeDialog, onAccept: accepted, title: \"Assign \" + (type === 'outcome' ? 'Outcome' : 'Skill'), text: ((_b = user === null || user === void 0 ? void 0 : user.engagementPoints) !== null && _b !== void 0 ? _b : 0) < cost && !recommended\n ? \"You do not have enough engagement points to assign \" + skillOrOutcome.name\n : cost === 0 || recommended\n ? \"Assign \" + skillOrOutcome.name + \"?\"\n : \"Assign \" + skillOrOutcome.name + \" for \" + cost + \" engagement points?\", cancelText: 'Cancel', acceptText: ((_c = user === null || user === void 0 ? void 0 : user.engagementPoints) !== null && _c !== void 0 ? _c : 0) < cost ? undefined : 'Assign', disabled: ((_d = user === null || user === void 0 ? void 0 : user.engagementPoints) !== null && _d !== void 0 ? _d : 0) < cost || disabled || starter, cancelDisabled: disabled || starter }, void 0)] }, void 0));\n};\nexport default AddButton;\n//# sourceMappingURL=AddButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useState } from 'react';\nimport { LockContext } from '../../contexts/LockContext';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { Colors } from '../../utils/colors';\nimport Dialog from '../Dialog';\nimport { Tooltip } from '../Tooltip';\nimport TextButton from './TextButton';\nimport Button from './Button';\nimport { Level } from '../../types/enums';\nimport { ArrowUp } from 'react-feather';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n addButton: {\n height: 38,\n minHeight: 38,\n width: 38,\n minWidth: 38,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: '50%',\n backgroundColor: 'transparent',\n color: Colors.purple,\n },\n disabled: {\n color: Colors.textSecondary,\n backgroundColor: Colors.background,\n },\n clickable: {\n '&:hover': {\n backgroundColor: Colors.iconHover,\n cursor: 'pointer',\n },\n '&:focus': {\n backgroundColor: Colors.iconHover,\n },\n },\n large: {\n height: 48,\n width: 48,\n },\n});\nvar UpgradeButton = function (_a) {\n var user = _a.user, skillOrOutcome = _a.skillOrOutcome, recommended = _a.recommended, onAccept = _a.onAccept, large = _a.large, describedById = _a.describedById, textFormat = _a.textFormat, variant = _a.variant, customText = _a.customText;\n var classes = useStyles();\n var _b = __read(useState(false), 2), mouseOver = _b[0], setMouseOver = _b[1];\n var _c = __read(useState(false), 2), mouseDown = _c[0], setMouseDown = _c[1];\n var _d = __read(useState(false), 2), open = _d[0], setOpen = _d[1];\n var _e = useContext(LockContext), disabled = _e.disabled, setDisabled = _e.setDisabled;\n var ApiService = useApiService();\n var type = isOutcome(skillOrOutcome) ? 'outcome' : 'skill';\n var onMouseOver = function () { return setMouseOver(true); };\n var onMouseOut = function () {\n setMouseOver(false);\n setMouseDown(false);\n };\n var onMouseDown = function () { return setMouseDown(true); };\n var onMouseUp = function () { return setMouseDown(false); };\n var onClick = function () {\n setOpen(true);\n };\n var closeDialog = function () { return setOpen(false); };\n var accepted = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n closeDialog();\n setDisabled(true);\n return [4, ApiService.changeTargetLevel(user, user.oid, skillOrOutcome.current.level + 1, skillOrOutcome.id, type, recommended, false)];\n case 1:\n _a.sent();\n if (!onAccept) return [3, 3];\n return [4, onAccept()];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3:\n setDisabled(false);\n return [2];\n }\n });\n }); };\n var title = \"Upgrade \" + (type === 'outcome' ? 'Outcome' : 'Skill');\n return (_jsxs(_Fragment, { children: [!textFormat ? (_jsx(Tooltip, __assign({ title: title }, { children: _jsx(\"button\", __assign({ className: clsx(classes.addButton, large ? classes.large : undefined, !disabled ? classes.clickable : undefined, disabled && classes.disabled), onClick: !disabled ? onClick : undefined, onMouseOver: !disabled ? onMouseOver : undefined, onMouseOut: !disabled ? onMouseOut : undefined, onMouseDown: !disabled ? onMouseDown : undefined, onMouseUp: !disabled ? onMouseUp : undefined, style: {\n border: disabled\n ? ''\n : mouseOver && !mouseDown\n ? \"1px solid \" + Colors.textPrimary\n : mouseDown\n ? '1px solid rgba(101,78,163,0.24)'\n : '1px solid rgba(101, 78, 163, 0.24)',\n }, \"aria-label\": title, \"aria-describedby\": describedById }, { children: _jsx(ArrowUp, {}, void 0) }), void 0) }), void 0)) : variant === 'home' ? (_jsx(Button, __assign({ disabled: disabled, onClick: !disabled ? onClick : undefined }, { children: customText ? customText : \"Advance \" + (type === 'outcome' ? 'Outcome' : 'Skill') }), void 0)) : (_jsx(TextButton, __assign({ disabled: disabled, onClick: !disabled ? onClick : undefined, variant: \"purple\", style: { lineHeight: '40px', fontSize: 10, paddingLeft: 0, paddingRight: 0 } }, { children: customText ? customText : \"Advance \" + (type === 'outcome' ? 'Outcome' : 'Skill') }), void 0)), _jsx(Dialog, { open: open, onClose: closeDialog, onAccept: accepted, title: \"Advance \" + (type === 'outcome' ? 'Outcome' : 'Skill'), text: \"Your target level for \" + skillOrOutcome.name + \" will change from \" + Level[skillOrOutcome.current.level] + \" to \" + Level[skillOrOutcome.current.level + 1] + \".\", cancelText: 'Cancel', acceptText: 'Advance', disabled: disabled, cancelDisabled: disabled }, void 0)] }, void 0));\n};\nexport default UpgradeButton;\n//# sourceMappingURL=UpgradeButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar UserUnachievedIcon = function () {\n var id = useUUID('userUnachievedIconTitleId');\n return (_jsx(\"svg\", __assign({ width: \"28px\", height: \"28px\", viewBox: \"0 0 28 28\", version: \"1.1\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-98.000000, -1046.000000)\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(100.000000, 1048.000000)\" }, { children: _jsxs(\"g\", { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M0.707106781,11.2928932 L11.2928932,0.707106781 C11.6834175,0.316582489 12.3165825,0.316582489 12.7071068,0.707106781 L23.2928932,11.2928932 C23.6834175,11.6834175 23.6834175,12.3165825 23.2928932,12.7071068 L12.7071068,23.2928932 C12.3165825,23.6834175 11.6834175,23.6834175 11.2928932,23.2928932 L0.707106781,12.7071068 C0.316582489,12.3165825 0.316582489,11.6834175 0.707106781,11.2928932 Z\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M1.02329256e-12,10.5857864 L10.5857864,1.22124533e-15 C11.366835,-0.781048584 12.633165,-0.781048584 13.4142136,8.8817842e-16 L24,10.5857864 C24.7810486,11.366835 24.7810486,12.633165 24,13.4142136 L13.4142136,24 C12.633165,24.7810486 11.366835,24.7810486 10.5857864,24 L1.02406972e-12,13.4142136 C-0.781048584,12.633165 -0.781048584,11.366835 1.0239587e-12,10.5857864 Z\", stroke: \"#FFFFFF\", strokeWidth: \"2\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M0.707106781,11.2928932 L11.2928932,0.707106781 C11.6834175,0.316582489 12.3165825,0.316582489 12.7071068,0.707106781 L23.2928932,11.2928932 C23.6834175,11.6834175 23.6834175,12.3165825 23.2928932,12.7071068 L12.7071068,23.2928932 C12.3165825,23.6834175 11.6834175,23.6834175 11.2928932,23.2928932 L0.707106781,12.7071068 C0.316582489,12.3165825 0.316582489,11.6834175 0.707106781,11.2928932 Z\", fill: Colors.unachievedSkill }, void 0)] }, void 0) }), void 0) }), void 0) }), void 0) }), void 0));\n};\nexport default UserUnachievedIcon;\n//# sourceMappingURL=UserUnachievedIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar UserAchievedIcon = function () {\n var id = useUUID('userAchievedIconTitleId');\n return (_jsx(\"svg\", __assign({ width: \"28px\", height: \"28px\", viewBox: \"0 0 28 28\", version: \"1.1\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-98.000000, -1046.000000)\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(100.000000, 1048.000000)\" }, { children: _jsxs(\"g\", { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M0.707106781,11.2928932 L11.2928932,0.707106781 C11.6834175,0.316582489 12.3165825,0.316582489 12.7071068,0.707106781 L23.2928932,11.2928932 C23.6834175,11.6834175 23.6834175,12.3165825 23.2928932,12.7071068 L12.7071068,23.2928932 C12.3165825,23.6834175 11.6834175,23.6834175 11.2928932,23.2928932 L0.707106781,12.7071068 C0.316582489,12.3165825 0.316582489,11.6834175 0.707106781,11.2928932 Z\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M1.02329256e-12,10.5857864 L10.5857864,1.22124533e-15 C11.366835,-0.781048584 12.633165,-0.781048584 13.4142136,8.8817842e-16 L24,10.5857864 C24.7810486,11.366835 24.7810486,12.633165 24,13.4142136 L13.4142136,24 C12.633165,24.7810486 11.366835,24.7810486 10.5857864,24 L1.02406972e-12,13.4142136 C-0.781048584,12.633165 -0.781048584,11.366835 1.0239587e-12,10.5857864 Z\", stroke: \"#FFFFFF\", strokeWidth: \"2\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M0.707106781,11.2928932 L11.2928932,0.707106781 C11.6834175,0.316582489 12.3165825,0.316582489 12.7071068,0.707106781 L23.2928932,11.2928932 C23.6834175,11.6834175 23.6834175,12.3165825 23.2928932,12.7071068 L12.7071068,23.2928932 C12.3165825,23.6834175 11.6834175,23.6834175 11.2928932,23.2928932 L0.707106781,12.7071068 C0.316582489,12.3165825 0.316582489,11.6834175 0.707106781,11.2928932 Z\", fill: Colors.userSkill }, void 0)] }, void 0) }), void 0) }), void 0) }), void 0) }), void 0));\n};\nexport default UserAchievedIcon;\n//# sourceMappingURL=UserAchievedIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport { useState, useEffect, useContext } from 'react';\nimport { useHistory } from 'react-router-dom';\nimport { Paper } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../utils/colors';\nimport { Level, ClientType, PageIds } from '../types/enums';\nimport AddButton from './buttons/AddButton';\nimport TextButton from './buttons/TextButton';\nimport { TokenContext } from '../contexts/TokenContext';\nimport UpgradeButton from './buttons/UpgradeButton';\nimport { APPLICATION_ID, OUTCOMES_PATH } from '../utils/constants';\nimport UserUnachievedIcon from './icons/UserUnachievedIcon';\nimport UserAchievedIcon from './icons/UserAchievedIcon';\nimport { useTypography } from '../styles/Typography';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n card: (_a = {\n width: 510,\n padding: 24,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column'\n },\n _a[theme.breakpoints.up('lg')] = {\n minHeight: 204,\n },\n _a[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n largeCard: (_b = {\n width: 1040,\n padding: 24,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column'\n },\n _b[theme.breakpoints.up('lg')] = {\n height: 204,\n },\n _b[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 330,\n minHeight: 348,\n },\n _b),\n cardIntro: {\n marginBottom: 16,\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n cardBody: {\n display: 'flex',\n alignItems: 'center',\n background: '#FAFAFA',\n minHeight: 88,\n },\n cardGraphic: {\n marginRight: 17,\n },\n image: function (_a) {\n var type = _a.type;\n return ({\n height: type === 'outcome' ? 64 : 107,\n minHeight: type === 'outcome' ? 64 : 107,\n width: type === 'outcome' ? 64 : 107,\n minWidth: type === 'outcome' ? 64 : 107,\n });\n },\n });\n});\nvar RecommendedOutcomeOrSkill = function (_a) {\n var user = _a.user, large = _a.large, getDetails = _a.getDetails, message = _a.message, isOutcome = _a.isOutcome, advance = _a.advance, onAccept = _a.onAccept, targetId = _a.targetId;\n var type = large ? 'outcome large' : 'outcome';\n var classes = useStyles({ type: type });\n var _b = __read(useState(undefined), 2), details = _b[0], setDetails = _b[1];\n var typo = useTypography();\n var clientType = useContext(TokenContext).clientType;\n var history = useHistory();\n useEffect(function () {\n var getDetailsData = function () { return __awaiter(void 0, void 0, void 0, function () {\n var data;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getDetails()];\n case 1:\n data = _a.sent();\n setDetails(data);\n return [2];\n }\n });\n }); };\n getDetailsData();\n }, [getDetails]);\n if (!details) {\n return null;\n }\n var openRecommendationDetails = function () {\n var recommendationDetailsLink = (isOutcome ? 'outcome-details' : 'skill-details') + \"/\" + targetId;\n var recommendationDetailsDeepLink = \"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/\" + (isOutcome ? PageIds.OutcomesPage : PageIds.SkillsPage) + \"?context={\\\"subEntityId\\\": \" + targetId + \"}\";\n if (clientType === ClientType.platform) {\n history.push(recommendationDetailsLink);\n }\n else {\n microsoftTeams.executeDeepLink(recommendationDetailsDeepLink);\n }\n };\n return (_jsxs(Paper, __assign({ className: clsx(large ? classes.largeCard : classes.card) }, { children: [_jsxs(\"div\", __assign({ className: classes.cardIntro }, { children: [_jsx(\"span\", __assign({ className: typo.body2, style: { lineHeight: '16px', fontSize: 13 } }, { children: message }), void 0), advance ? (_jsx(UpgradeButton, { user: user, skillOrOutcome: details, recommended: true, describedById: details.id.toString(), onAccept: onAccept, textFormat: true, variant: \"home\", customText: \"Advance\" }, void 0)) : (_jsx(AddButton, { user: user, skillOrOutcome: details, level: Level.User, recommended: true, describedById: details.id.toString(), onAccept: onAccept, textFormat: true, variant: \"home\" }, void 0))] }), void 0), _jsx(TextButton, __assign({ onClick: openRecommendationDetails, style: {\n display: 'block',\n padding: 0,\n textTransform: 'none',\n minHeight: 88,\n } }, { children: _jsxs(\"div\", __assign({ className: classes.cardBody }, { children: [isOutcome ? (_jsx(\"span\", __assign({ className: classes.cardGraphic }, { children: _jsx(\"img\", { className: classes.image, alt: \"\", src: \"\" + OUTCOMES_PATH + details.image + \".svg\", loading: \"lazy\" }, void 0) }), void 0)) : advance ? (_jsx(\"span\", __assign({ className: classes.cardGraphic, style: { paddingLeft: 24 } }, { children: _jsx(UserAchievedIcon, {}, void 0) }), void 0)) : (_jsx(\"span\", __assign({ className: classes.cardGraphic, style: { paddingLeft: 24 } }, { children: _jsx(UserUnachievedIcon, {}, void 0) }), void 0)), _jsxs(\"span\", __assign({ className: typo.subtitle2 }, { children: [details.name, \" \"] }), void 0)] }), void 0) }), void 0)] }), void 0));\n};\nexport default RecommendedOutcomeOrSkill;\n//# sourceMappingURL=RecommendedOutcomeOrSkill.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useCallback } from 'react';\nimport { RecommendType } from '../types/enums';\nimport RecommendedActivity from './RecommendedActivity';\nimport RecommendedOutcomeOrSkill from './RecommendedOutcomeOrSkill';\nimport { SkillService } from '../services/SkillService';\nimport { OutcomeService } from '../services/OutcomeService';\nimport { getToken } from '../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { useGetHomeData } from '../hooks/useGetHomeData';\nvar HomeRecommendation = function (_a) {\n var user = _a.user, value = _a.value, large = _a.large, home = _a.home;\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var getData = useGetHomeData();\n var accept = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getData()];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n var getSkillDetails = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getSkillDetails(value.targetId)];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n return [2, response];\n }\n });\n }); }, [instance, account, ssoToken, oid, tid, clientType, value.targetId]);\n var getOutcomeDetails = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getOutcomeDetails(value.targetId)];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n return [2, response];\n }\n });\n }); }, [instance, account, ssoToken, oid, tid, clientType, value.targetId]);\n if (value.type === RecommendType.Activity) {\n return _jsx(RecommendedActivity, { recommendedActivity: value, large: large, home: home }, void 0);\n }\n if (value.type === RecommendType.NewSkill) {\n return (_jsx(RecommendedOutcomeOrSkill, { user: user, large: large, getDetails: getSkillDetails, message: \"Ready for Something New?\", isOutcome: false, onAccept: accept, targetId: value.targetId }, void 0));\n }\n if (value.type === RecommendType.NewOutcome) {\n return (_jsx(RecommendedOutcomeOrSkill, { user: user, large: large, getDetails: getOutcomeDetails, message: \"Ready for Something New?\", isOutcome: true, onAccept: accept, targetId: value.targetId }, void 0));\n }\n if (value.type === RecommendType.UpgradeSkill) {\n return (_jsx(RecommendedOutcomeOrSkill, { user: user, large: large, getDetails: getSkillDetails, message: \"Let\\u2019s Advance to the Next Level\", isOutcome: false, advance: true, onAccept: accept, targetId: value.targetId }, void 0));\n }\n if (value.type === RecommendType.UpgradeOutcome) {\n return (_jsx(RecommendedOutcomeOrSkill, { user: user, large: large, getDetails: getOutcomeDetails, message: \"Let\\u2019s Advance to the Next Level\", isOutcome: true, advance: true, onAccept: accept, targetId: value.targetId }, void 0));\n }\n return null;\n};\nexport default HomeRecommendation;\n//# sourceMappingURL=HomeRecommendation.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useMemo } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { Doughnut } from 'react-chartjs-2';\nvar DoughnutChart = function (_a) {\n var maintain = _a.maintain, inProgress = _a.inProgress, needsImprovement = _a.needsImprovement;\n return useMemo(function () {\n return (_jsx(Doughnut, { data: {\n datasets: [\n {\n data: [\n maintain,\n inProgress,\n needsImprovement,\n maintain + inProgress + needsImprovement === 0 ? 1 : 0,\n ],\n backgroundColor: [Colors.green, Colors.yellow, Colors.red, Colors.disabled],\n },\n ],\n }, options: {\n responsive: true,\n maintainAspectRatio: false,\n } }, void 0));\n }, [maintain, inProgress, needsImprovement]);\n};\nexport default DoughnutChart;\n//# sourceMappingURL=DoughnutChart.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Divider, Paper, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport { useContext } from 'react';\nimport DoughnutChart from '../charts/DoughnutChart';\nimport { HomeContext } from '../../contexts/HomeContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport { ClientType } from '../../types/enums';\nimport { useHistory } from 'react-router-dom';\nimport { APPLICATION_ID } from '../../utils/constants';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n minHeight: 270,\n minWidth: 355,\n width: 355,\n height: 270,\n display: 'flex',\n flexDirection: 'column',\n backgroundColor: Colors.white,\n borderRadius: 4,\n margin: 8\n },\n _a[theme.breakpoints.down('md')] = {\n minWidth: 670,\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n minWidth: 330,\n width: 330,\n },\n _a),\n body: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n padding: 16,\n },\n graph: {\n width: 105,\n height: 105,\n marginRight: 24,\n },\n text: {\n display: 'flex',\n flexDirection: 'column',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n paddingTop: 8,\n paddingBottom: 8,\n },\n box: {\n width: 12,\n height: 12,\n borderRadius: 25,\n marginRight: 8,\n },\n });\n});\nvar SnapShot = function (_a) {\n var _b, _c, _d;\n var clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var skills = useContext(HomeContext).skills;\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var history = useHistory();\n var onClick = function () {\n if (clientType === ClientType.platform) {\n history.push('/your-skills');\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/ef9b5db3-e49a-4fdd-8e29-ccedda0ffbc7\");\n }\n };\n if (!skills)\n return null;\n return (_jsxs(Paper, __assign({ elevation: 1, \"aria-labelledby\": \"snapshotLabel\", className: classes.card }, { children: [_jsx(\"h2\", __assign({ id: \"snapshotLabel\", className: typo.subtitle1, style: { margin: 16 } }, { children: \"Snapshot of Your Skills\" }), void 0), _jsx(Divider, {}, void 0), _jsxs(\"div\", __assign({ className: classes.body }, { children: [_jsx(\"div\", __assign({ \"aria-hidden\": true, className: classes.graph }, { children: _jsx(DoughnutChart, { maintain: skills === null || skills === void 0 ? void 0 : skills.maintain.length, inProgress: skills === null || skills === void 0 ? void 0 : skills.inProgress.length, needsImprovement: skills === null || skills === void 0 ? void 0 : skills.needsImprovement.length }, void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.text }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.box, style: { backgroundColor: '#FE6C6C' } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: ((_b = skills === null || skills === void 0 ? void 0 : skills.needsImprovement.length) !== null && _b !== void 0 ? _b : 0) + \" \" + ((skills === null || skills === void 0 ? void 0 : skills.needsImprovement.length) === 1 ? 'Skill' : 'Skills') + \" \" + ((skills === null || skills === void 0 ? void 0 : skills.needsImprovement.length) === 1 ? 'Needs Attention' : 'Need Attention') }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.box, style: { backgroundColor: '#FFCC55' } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: ((_c = skills === null || skills === void 0 ? void 0 : skills.inProgress.length) !== null && _c !== void 0 ? _c : 0) + \" \" + ((skills === null || skills === void 0 ? void 0 : skills.inProgress.length) === 1 ? 'Skill' : 'Skills') + \" In Progress\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.box, style: { backgroundColor: '#B0CB3E' } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: ((_d = skills === null || skills === void 0 ? void 0 : skills.maintain.length) !== null && _d !== void 0 ? _d : 0) + \" \" + ((skills === null || skills === void 0 ? void 0 : skills.maintain.length) === 1 ? 'Skill' : 'Skills') + \" Attained\" }), void 0)] }), void 0), _jsx(SecondaryButton, __assign({ onClick: onClick, style: isSmDown\n ? { marginTop: 8, width: '100%', height: 32 }\n : { marginTop: 24, width: 161, height: 32 } }, { children: \"See Your Skills\" }), void 0)] }), void 0)] }), void 0)] }), void 0));\n};\nexport default SnapShot;\n//# sourceMappingURL=SnapShot.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar BigStreakIcon = function () {\n var id = useUUID();\n return (_jsxs(\"svg\", __assign({ width: \"128\", height: \"125\", viewBox: \"0 0 128 125\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": \"bigStreakIconTitleId-\" + id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: \"bigStreakIconTitleId-\" + id }, { children: \"Streak\" }), void 0), _jsx(\"path\", { d: \"M121.292 31.25L71.8125 80.7292L45.7708 54.6875L6.70831 93.75\", stroke: \"#654EA3\", strokeWidth: \"12\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M90.0416 31.25H121.292V62.5\", stroke: \"#654EA3\", strokeWidth: \"12\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0)] }), void 0));\n};\nexport default BigStreakIcon;\n//# sourceMappingURL=BigStreakIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar StreakIcon = function () {\n var id = useUUID('streakIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"25\", height: \"24\", viewBox: \"0 0 25 24\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Streak\" }), void 0), _jsx(\"path\", { d: \"M23.5 6L14 15.5L9 10.5L1.5 18\", stroke: \"#654EA3\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M17.5 6H23.5V12\", stroke: \"#654EA3\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0)] }), void 0));\n};\nexport default StreakIcon;\n//# sourceMappingURL=StreakIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { ButtonBase, Divider, Link, Paper } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport clsx from 'clsx';\nimport { useContext, Fragment } from 'react';\nimport { HomeContext } from '../../contexts/HomeContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport BigStreakIcon from '../icons/BigStreakIcon';\nimport StreakIcon from '../icons/StreakIcon';\nimport { ClientType } from '../../types/enums';\nimport { useHistory } from 'react-router-dom';\nimport { APPLICATION_ID } from '../../utils/constants';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n card: (_a = {\n width: 336,\n minWidth: 336,\n padding: 16,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-start',\n borderRadius: 4,\n backgroundColor: Colors.white,\n margin: 8\n },\n _a[theme.breakpoints.up('lg')] = {\n height: 378,\n },\n _a[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n minWidth: 330,\n },\n _a),\n emptyCard: (_b = {\n width: 336,\n minWidth: 336,\n height: 378,\n padding: 16,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n borderRadius: 4,\n backgroundColor: Colors.white,\n margin: 8\n },\n _b[theme.breakpoints.down('md')] = {\n width: 673,\n },\n _b[theme.breakpoints.down('sm')] = {\n minWidth: 330,\n width: 330,\n },\n _b),\n item: {\n display: 'block',\n },\n icon: {\n width: 128,\n height: 125,\n marginBottom: 8,\n },\n streak: {\n width: '100%',\n display: 'flex',\n textAlign: 'left',\n },\n streakItem: {\n width: '100%',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n backgroundColor: Colors.green,\n marginTop: 5,\n marginRight: 8,\n },\n divider: {\n marginBottom: 12,\n marginTop: 8,\n display: 'block',\n width: '100%',\n },\n hover: {\n '&:hover': {\n textDecoration: 'underline',\n },\n },\n });\n});\nvar StreaksCard = function (_a) {\n var clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var streaks = useContext(HomeContext).streaks;\n var history = useHistory();\n var openStreakSkill = function (id) {\n if (clientType === ClientType.platform) {\n history.push(\"/skill-details/\" + id);\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/ef9b5db3-e49a-4fdd-8e29-ccedda0ffbc7?context={\\\"subEntityId\\\": \" + id + \"}\");\n }\n };\n if (!streaks) {\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.emptyCard }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: _jsx(BigStreakIcon, {}, void 0) }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.body2, classes.item) }, { children: \"Streaks\" }), void 0), _jsx(\"p\", __assign({ className: typo.body2, style: { marginBottom: 32 } }, { children: \"You\\u2019re just getting started, so don\\u2019t worry if you don\\u2019t see any streaks yet. As you attain & maintain Skills & Outcomes, you\\u2019ll be able to check out your longest streaks here\" }), void 0)] }), void 0));\n }\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.card }, { children: [_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(StreakIcon, {}, void 0) }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.caption, classes.item) }, { children: \"Good job keeping those Skills maintained\" }), void 0), _jsx(\"h2\", __assign({ className: typo.body2, style: { marginBottom: 16 } }, { children: \"Here are your longest streaks\" }), void 0), streaks === null || streaks === void 0 ? void 0 : streaks.map(function (value) { return (_jsxs(Fragment, { children: [_jsxs(Link, __assign({ component: ButtonBase, className: classes.streak, onClick: function () { return openStreakSkill(value.skillStreakId); }, style: { textDecoration: 'none' } }, { children: [_jsx(\"span\", { className: classes.dot }, void 0), _jsxs(\"span\", __assign({ className: classes.streakItem }, { children: [_jsx(\"span\", __assign({ className: clsx(typo.body2, classes.item, classes.hover) }, { children: value.skillStreakName }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.item) }, { children: value.skillStreakLength + \" \" + value.skillStreakTime }), void 0)] }), void 0)] }), value.skillStreakId), _jsx(Divider, { className: classes.divider }, void 0)] }, value.skillStreakId)); })] }), void 0));\n};\nexport default StreaksCard;\n//# sourceMappingURL=StreaksCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { makeStyles, useMediaQuery, useTheme } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { Book, Play, Volume1 } from 'react-feather';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport { MOTD_PATH } from '../../utils/constants';\nimport { useTypography } from '../../styles/Typography';\nimport Button from '../buttons/Button';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n motd: (_a = {\n padding: 16,\n paddingLeft: 24,\n paddingRight: 24,\n display: 'flex',\n flexDirection: 'column'\n },\n _a[theme.breakpoints.down('md')] = {\n justifyContent: 'center',\n alignItems: 'center',\n },\n _a),\n videoMotd: (_b = {\n display: 'flex'\n },\n _b[theme.breakpoints.up('md')] = {\n justifyContent: 'space-between',\n },\n _b[theme.breakpoints.down('sm')] = {\n justifyContent: 'center',\n flexDirection: 'column',\n },\n _b.alignItems = 'center',\n _b.marginBottom = 16,\n _b),\n textContainer: {\n width: '60%',\n display: 'flex',\n alignItems: 'center',\n flexDirection: 'column',\n },\n button: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n color: Colors.purple,\n },\n icon: {\n marginRight: 8,\n },\n video: function (_a) {\n var image = _a.image;\n return ({\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n backgroundImage: \"url(\" + image + \")\",\n height: 154,\n width: 299,\n });\n },\n });\n});\nvar MotdVideo = function (_a) {\n var _b;\n var motd = _a.motd;\n var typo = useTypography();\n var classes = useStyles({ image: (_b = \"\" + MOTD_PATH + motd.image) !== null && _b !== void 0 ? _b : '' });\n var _c = __read(useState(undefined), 2), content = _c[0], setContent = _c[1];\n var _d = useContext(DialogContext), setOpenVideoDialog = _d.setOpenVideoDialog, setOpenAudioDialog = _d.setOpenAudioDialog, setOpenPdfDialog = _d.setOpenPdfDialog, setVideoDialogContent = _d.setVideoDialogContent, setAudioDialogContent = _d.setAudioDialogContent, setPdfDialogContent = _d.setPdfDialogContent;\n var theme = useTheme();\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n useEffect(function () {\n if (motd.contentId) {\n setContent({\n container: 'content',\n fileName: motd.contentId + \".\" + motd.fileType,\n contentId: motd.contentId,\n views: 1,\n });\n }\n }, [motd]);\n var openDialog = function () {\n if (!content) {\n return;\n }\n switch (motd.fileType) {\n case 'mp3': {\n setAudioDialogContent(content);\n setOpenAudioDialog(true);\n break;\n }\n case 'mp4': {\n setVideoDialogContent(content);\n setOpenVideoDialog(true);\n break;\n }\n case 'pdf': {\n setPdfDialogContent(content);\n setOpenPdfDialog(true);\n break;\n }\n default: {\n break;\n }\n }\n };\n return (_jsx(\"div\", __assign({ className: classes.motd }, { children: _jsxs(\"div\", __assign({ className: classes.videoMotd }, { children: [_jsxs(\"div\", __assign({ className: classes.textContainer }, { children: [_jsx(\"div\", { children: motd.message.map(function (value, index) {\n return (_jsx(\"p\", __assign({ className: typo.subtitle1 }, { children: value }), index));\n }) }, void 0), _jsx(SecondaryButton, __assign({ onClick: openDialog, style: {\n width: 283,\n minWidth: 283,\n backgroundColor: Colors.white,\n marginBottom: isMediumDown ? 16 : undefined,\n display: 'flex',\n justifyContent: 'center',\n } }, { children: _jsxs(\"div\", __assign({ className: classes.button }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: motd.fileType === 'mp4' ? (_jsx(Play, {}, void 0)) : motd.fileType === 'mp3' ? (_jsx(Volume1, {}, void 0)) : motd.fileType === 'pdf' ? (_jsx(Book, {}, void 0)) : undefined }), void 0), motd.actionLabel] }), void 0) }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.video }, { children: _jsx(Button, __assign({ onClick: openDialog }, { children: _jsx(Play, {}, void 0) }), void 0) }), void 0)] }), void 0) }), void 0));\n};\nexport default MotdVideo;\n//# sourceMappingURL=MotdVideo.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport { useTheme } from '@material-ui/core/styles';\nimport { makeStyles, useMediaQuery } from '@material-ui/core';\nimport { MOTD_PATH } from '../../utils/constants';\nimport clsx from 'clsx';\nimport { useTypography } from '../../styles/Typography';\nimport { MotdActionType } from '../../types/enums';\nimport { Book, Play, Volume1 } from 'react-feather';\nimport SecondaryButton from '../buttons/SecondaryButton';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d;\n return ({\n motd: (_a = {\n padding: 16,\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n position: 'relative'\n },\n _a[theme.breakpoints.down('sm')] = {\n alignItems: 'center',\n justifyContent: 'center',\n flexDirection: 'column',\n },\n _a),\n content: (_b = {\n display: 'flex',\n justifyContent: 'center',\n justifySelf: 'center',\n flexDirection: 'column',\n alignItems: 'center',\n flex: 1\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 'auto',\n },\n _b),\n like: {\n height: 37,\n width: 37,\n position: 'absolute',\n top: 12,\n right: 0,\n },\n imageContainer: {\n width: 'auto',\n height: '100%',\n display: 'inline-block',\n },\n image: (_c = {\n width: 299,\n height: 'auto',\n marginRight: 32,\n boxShadow: '0 1px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.08)'\n },\n _c[theme.breakpoints.down('sm')] = {\n width: 200,\n marginBottom: 16,\n marginRight: 0,\n },\n _c),\n button: (_d = {\n width: 283,\n display: 'flex',\n alignItems: 'center',\n margin: 'auto',\n color: Colors.purple\n },\n _d[theme.breakpoints.down('sm')] = {\n width: 283,\n },\n _d),\n icon: {\n marginRight: 8,\n },\n });\n});\nvar MotdImageText = function (_a) {\n var motd = _a.motd;\n var classes = useStyles();\n var typo = useTypography();\n var _b = __read(useState(undefined), 2), content = _b[0], setContent = _b[1];\n var _c = useContext(DialogContext), setOpenVideoDialog = _c.setOpenVideoDialog, setOpenAudioDialog = _c.setOpenAudioDialog, setOpenPdfDialog = _c.setOpenPdfDialog, setVideoDialogContent = _c.setVideoDialogContent, setAudioDialogContent = _c.setAudioDialogContent, setPdfDialogContent = _c.setPdfDialogContent;\n var theme = useTheme();\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n useEffect(function () {\n if (motd.contentId) {\n setContent({\n container: 'content',\n fileName: motd.contentId + \".\" + motd.fileType,\n contentId: motd.contentId,\n views: 1,\n });\n }\n }, [motd]);\n var openDialog = function () {\n if (!content) {\n return;\n }\n switch (motd.fileType) {\n case 'mp3': {\n setAudioDialogContent(content);\n setOpenAudioDialog(true);\n break;\n }\n case 'mp4': {\n setVideoDialogContent(content);\n setOpenVideoDialog(true);\n break;\n }\n case 'pdf': {\n setPdfDialogContent(content);\n setOpenPdfDialog(true);\n break;\n }\n default: {\n break;\n }\n }\n };\n return (_jsxs(\"div\", __assign({ className: classes.motd }, { children: [_jsx(\"div\", __assign({ className: classes.imageContainer }, { children: _jsx(\"img\", { className: classes.image, src: \"\" + MOTD_PATH + motd.image, alt: \"motd \" + motd.title }, void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.content }, { children: [motd.title ? (_jsxs(_Fragment, { children: [_jsx(\"h3\", __assign({ className: clsx(typo.h6), style: {\n fontWeight: 600,\n marginBottom: 8,\n width: '100%',\n textAlign: 'left',\n } }, { children: motd.title }), void 0), motd.message.map(function (value, index, array) { return (_jsx(\"p\", __assign({ className: typo.body1, style: index < array.length - 1\n ? { marginBottom: 12, width: '100%', textAlign: 'left' }\n : { width: '100%', textAlign: 'left' } }, { children: value }), value + index)); })] }, void 0)) : (_jsx(_Fragment, { children: motd.message.map(function (value, index) { return (_jsx(\"p\", __assign({ className: clsx(typo.body1), style: {\n color: Colors.textSecondary,\n lineHeight: '20px',\n width: '100%',\n textAlign: 'left',\n } }, { children: value }), value + index)); }) }, void 0)), motd.actionType === MotdActionType.Content && (_jsx(\"div\", __assign({ style: { marginTop: 8 } }, { children: _jsx(SecondaryButton, __assign({ onClick: openDialog, style: {\n width: 172,\n minWidth: 172,\n marginBottom: isMediumDown ? 16 : undefined,\n display: 'flex',\n justifyContent: 'center',\n } }, { children: _jsxs(\"div\", __assign({ className: classes.button }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: motd.fileType === 'mp4' ? (_jsx(Play, {}, void 0)) : motd.fileType === 'mp3' ? (_jsx(Volume1, {}, void 0)) : motd.fileType === 'pdf' ? (_jsx(Book, {}, void 0)) : undefined }), void 0), motd.actionLabel] }), void 0) }), void 0) }), void 0))] }), void 0)] }), void 0));\n};\nexport default MotdImageText;\n//# sourceMappingURL=MotdImageText.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { makeStyles, useMediaQuery, useTheme } from '@material-ui/core';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport { Colors } from '../../utils/colors';\nimport { useTypography } from '../../styles/Typography';\nimport { MotdActionType } from '../../types/enums';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport { Book, Play, Volume1 } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n motd: (_a = {\n padding: 16,\n paddingLeft: 24,\n paddingRight: 24,\n display: 'flex',\n flexDirection: 'column'\n },\n _a[theme.breakpoints.down('sm')] = {\n justifyContent: 'center',\n alignItems: 'center',\n },\n _a),\n content: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n justifySelf: 'center',\n flexDirection: 'column',\n flex: 1,\n textAlign: 'center',\n },\n button: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n color: Colors.purple,\n },\n icon: {\n marginRight: 8,\n },\n });\n});\nvar MotdTextOnly = function (_a) {\n var motd = _a.motd;\n var classes = useStyles();\n var typo = useTypography();\n var _b = __read(useState(undefined), 2), content = _b[0], setContent = _b[1];\n var _c = useContext(DialogContext), setOpenVideoDialog = _c.setOpenVideoDialog, setOpenAudioDialog = _c.setOpenAudioDialog, setOpenPdfDialog = _c.setOpenPdfDialog, setVideoDialogContent = _c.setVideoDialogContent, setAudioDialogContent = _c.setAudioDialogContent, setPdfDialogContent = _c.setPdfDialogContent;\n var theme = useTheme();\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n useEffect(function () {\n if (motd.contentId) {\n setContent({\n container: 'content',\n fileName: motd.contentId + \".\" + motd.fileType,\n contentId: motd.contentId,\n views: 1,\n });\n }\n }, [motd]);\n var openDialog = function () {\n if (!content) {\n return;\n }\n switch (motd.fileType) {\n case 'mp3': {\n setAudioDialogContent(content);\n setOpenAudioDialog(true);\n break;\n }\n case 'mp4': {\n setVideoDialogContent(content);\n setOpenVideoDialog(true);\n break;\n }\n case 'pdf': {\n setPdfDialogContent(content);\n setOpenPdfDialog(true);\n break;\n }\n default: {\n break;\n }\n }\n };\n return (_jsx(\"div\", __assign({ className: classes.motd }, { children: _jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(\"h3\", __assign({ className: typo.h6, style: {\n fontWeight: 600,\n marginBottom: 8,\n } }, { children: motd.title }), void 0), motd.message.map(function (value, index, array) { return (_jsx(\"p\", __assign({ className: typo.body1, style: index < array.length - 1 ? { marginBottom: 12 } : undefined }, { children: value }), value + index)); }), motd.actionType === MotdActionType.Content && (_jsx(\"div\", __assign({ style: { marginTop: 8 } }, { children: _jsx(SecondaryButton, __assign({ onClick: openDialog, style: {\n width: 283,\n minWidth: 283,\n marginBottom: isMediumDown ? 16 : undefined,\n display: 'flex',\n justifyContent: 'center',\n } }, { children: _jsxs(\"div\", __assign({ className: classes.button }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: motd.fileType === 'mp4' ? (_jsx(Play, {}, void 0)) : motd.fileType === 'mp3' ? (_jsx(Volume1, {}, void 0)) : motd.fileType === 'pdf' ? (_jsx(Book, {}, void 0)) : undefined }), void 0), motd.actionLabel] }), void 0) }), void 0) }), void 0))] }), void 0) }), void 0));\n};\nexport default MotdTextOnly;\n//# sourceMappingURL=MotdTextOnly.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { makeStyles, useMediaQuery, useTheme } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { useHistory } from 'react-router-dom';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport { ClientType, MotdActionType, MotdPages } from '../../types/enums';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport { Book, Play, Volume1 } from 'react-feather';\nimport { APPLICATION_ID, MOTD_PATH } from '../../utils/constants';\nimport { useTypography } from '../../styles/Typography';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport { toPageId } from '../../utils/mapper';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d;\n return ({\n motd: (_a = {\n padding: 16,\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n position: 'relative'\n },\n _a[theme.breakpoints.down('sm')] = {\n alignItems: 'center',\n justifyContent: 'center',\n flexDirection: 'column',\n },\n _a),\n content: (_b = {\n display: 'flex',\n justifyContent: 'center',\n justifySelf: 'center',\n flexDirection: 'column',\n alignItems: 'center',\n flex: 1\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 'auto',\n },\n _b),\n imageContainer: {\n width: 'auto',\n height: '100%',\n display: 'inline-block',\n },\n textContainer: (_c = {\n width: '60%',\n display: 'flex',\n alignItems: 'center',\n flexDirection: 'column',\n textAlign: 'center'\n },\n _c[theme.breakpoints.down('sm')] = {\n width: 'auto',\n },\n _c),\n button: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n color: Colors.purple,\n },\n icon: {\n marginRight: 8,\n },\n image: (_d = {\n width: 299,\n height: 'auto',\n marginRight: 32,\n boxShadow: '0 1px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.08)'\n },\n _d[theme.breakpoints.down('sm')] = {\n width: 200,\n marginBottom: 16,\n marginRight: 0,\n },\n _d),\n });\n});\nvar MotdImageTextAction = function (_a) {\n var user = _a.user, motd = _a.motd;\n var classes = useStyles();\n var typo = useTypography();\n var theme = useTheme();\n var clientType = useContext(TokenContext).clientType;\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n var history = useHistory();\n var _b = useContext(DialogContext), setOpenVideoDialog = _b.setOpenVideoDialog, setOpenAudioDialog = _b.setOpenAudioDialog, setOpenPdfDialog = _b.setOpenPdfDialog, setVideoDialogContent = _b.setVideoDialogContent, setAudioDialogContent = _b.setAudioDialogContent, setPdfDialogContent = _b.setPdfDialogContent;\n var _c = __read(useState(undefined), 2), content = _c[0], setContent = _c[1];\n useEffect(function () {\n if (motd.contentId) {\n setContent({\n container: 'content',\n fileName: motd.contentId + \".\" + motd.fileType,\n contentId: motd.contentId,\n views: 1,\n });\n }\n }, [motd]);\n var takeAction = function () {\n var _a, _b, _c, _d;\n if (motd.actionType === MotdActionType.Content) {\n if (!content) {\n return;\n }\n switch (motd.fileType) {\n case 'mp3': {\n setAudioDialogContent(content);\n setOpenAudioDialog(true);\n break;\n }\n case 'mp4': {\n setVideoDialogContent(content);\n setOpenVideoDialog(true);\n break;\n }\n case 'pdf': {\n setPdfDialogContent(content);\n setOpenPdfDialog(true);\n break;\n }\n default: {\n break;\n }\n }\n }\n else if (motd.actionType === MotdActionType.Path) {\n var split = (_b = (_a = motd.path) === null || _a === void 0 ? void 0 : _a.split(':')) !== null && _b !== void 0 ? _b : [];\n if (clientType === ClientType.platform) {\n history.push(\"\" + ((_c = split[1]) !== null && _c !== void 0 ? _c : ''));\n }\n else\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/\" + toPageId((_d = split[0]) !== null && _d !== void 0 ? _d : MotdPages.HomePage));\n }\n };\n return (_jsxs(\"div\", __assign({ className: classes.motd }, { children: [_jsx(\"div\", __assign({ className: classes.imageContainer }, { children: _jsx(\"img\", { className: classes.image, src: \"\" + MOTD_PATH + motd.image, alt: \"motd \" + motd.title }, void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(\"h3\", __assign({ className: typo.h6, style: {\n fontWeight: 600,\n marginBottom: 8,\n width: '100%',\n textAlign: 'left',\n } }, { children: motd.title }), void 0), _jsx(\"div\", __assign({ style: { marginBottom: 16 } }, { children: motd.message.map(function (value, index, array) { return (_jsx(\"p\", __assign({ className: typo.body1, style: {\n color: Colors.textSecondary,\n lineHeight: '20px',\n width: '100%',\n textAlign: 'left',\n } }, { children: value }), value + index)); }) }), void 0), _jsx(SecondaryButton, __assign({ onClick: takeAction, style: {\n width: 172,\n minWidth: 172,\n marginBottom: isMediumDown ? 16 : undefined,\n display: 'flex',\n justifyContent: 'center',\n } }, { children: _jsxs(\"div\", __assign({ className: classes.button }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: motd.fileType === 'mp4' ? (_jsx(Play, {}, void 0)) : motd.fileType === 'mp3' ? (_jsx(Volume1, {}, void 0)) : motd.fileType === 'pdf' ? (_jsx(Book, {}, void 0)) : undefined }), void 0), motd.actionLabel] }), void 0) }), void 0)] }), void 0)] }), void 0));\n};\nexport default MotdImageTextAction;\n//# sourceMappingURL=MotdImageTextAction.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport MotdVideo from './MotdVideo';\nimport MotdImageText from './MotdImageText';\nimport MotdTextOnly from './MotdTextOnly';\nimport MotdImageTextAction from './MotdImageTextAction';\nimport { MotdDisplayType } from '../../types/enums';\nimport { UserContext } from '../../contexts/UserContext';\nimport { Divider, IconButton, makeStyles, MobileStepper, Paper } from '@material-ui/core';\nimport { useTypography } from '../../styles/Typography';\nimport { ChevronLeft, ChevronRight } from 'react-feather';\nimport { Colors } from '../../utils/colors';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n motd: (_a = {\n width: 665,\n height: 270,\n margin: 8\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n height: 'auto',\n },\n _a),\n title: {\n display: 'flex',\n justifyContent: 'space-between',\n },\n dots: {\n display: 'none',\n },\n });\n});\nvar Motd = function (_a) {\n var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;\n var motds = _a.motds;\n var classes = useStyles();\n var typo = useTypography();\n var user = useContext(UserContext).user;\n var _p = __read(useState(0), 2), activeStep = _p[0], setActiveStep = _p[1];\n var maxSteps = (_b = motds === null || motds === void 0 ? void 0 : motds.length) !== null && _b !== void 0 ? _b : 0;\n var handleNext = function () {\n setActiveStep(activeStep > maxSteps ? maxSteps : activeStep - 1);\n };\n var handleBack = function () {\n setActiveStep(activeStep < 0 ? 0 : activeStep + 1);\n };\n if (!motds) {\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.motd }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: _jsx(\"h2\", __assign({ className: typo.subtitle1, style: { margin: 16 } }, { children: ((_c = user === null || user === void 0 ? void 0 : user.numberLogins) !== null && _c !== void 0 ? _c : 0) < 2\n ? \"Welcome back \" + ((user === null || user === void 0 ? void 0 : user.firstName) ? \", \" + user.firstName : '')\n : \"Welcome \" + ((_d = user === null || user === void 0 ? void 0 : user.firstName) !== null && _d !== void 0 ? _d : '') }), void 0) }), void 0), _jsx(Divider, {}, void 0)] }), void 0));\n }\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.motd }, { children: [_jsxs(\"div\", __assign({ className: classes.title }, { children: [_jsx(\"h2\", __assign({ className: typo.subtitle1, style: { margin: 16 } }, { children: ((_e = user === null || user === void 0 ? void 0 : user.numberLogins) !== null && _e !== void 0 ? _e : 0) < 2\n ? \"Welcome back \" + ((user === null || user === void 0 ? void 0 : user.firstName) ? \", \" + user.firstName : '')\n : \"Welcome \" + ((_f = user === null || user === void 0 ? void 0 : user.firstName) !== null && _f !== void 0 ? _f : '') }), void 0), motds.length > 1 && (_jsx(MobileStepper, { steps: maxSteps, position: \"static\", activeStep: activeStep, style: { backgroundColor: Colors.white }, classes: { dots: classes.dots }, nextButton: _jsx(IconButton, __assign({ \"aria-label\": \"next\", size: \"small\", onClick: handleNext, disabled: activeStep === 0 }, { children: _jsx(ChevronRight, {}, void 0) }), void 0), backButton: _jsx(IconButton, __assign({ \"aria-label\": \"previous\", size: \"small\", onClick: handleBack, disabled: activeStep === maxSteps - 1 }, { children: _jsx(ChevronLeft, {}, void 0) }), void 0) }, void 0))] }), void 0), _jsx(Divider, {}, void 0), ((_g = motds[activeStep]) === null || _g === void 0 ? void 0 : _g.displayType) === MotdDisplayType.Video ? (_jsx(MotdVideo, { motd: motds[activeStep] }, void 0)) : ((_h = motds[activeStep]) === null || _h === void 0 ? void 0 : _h.displayType) === MotdDisplayType.OrangeImageAndTextSideBySide ? (_jsx(MotdImageText, { motd: motds[activeStep] }, void 0)) : ((_j = motds[activeStep]) === null || _j === void 0 ? void 0 : _j.displayType) === MotdDisplayType.OrangeText ? (_jsx(MotdTextOnly, { motd: motds[activeStep] }, void 0)) : ((_k = motds[activeStep]) === null || _k === void 0 ? void 0 : _k.displayType) === MotdDisplayType.ImageAndTextSideBySideWithAction ? (_jsx(MotdImageTextAction, { user: user, motd: motds[activeStep] }, void 0)) : ((_l = motds[activeStep]) === null || _l === void 0 ? void 0 : _l.displayType) === MotdDisplayType.OrangeImageAndTextSideBySideWithAction ? (_jsx(MotdImageTextAction, { user: user, motd: motds[activeStep] }, void 0)) : ((_m = motds[activeStep]) === null || _m === void 0 ? void 0 : _m.displayType) === MotdDisplayType.ImageAndTextSideBySide ? (_jsx(MotdImageText, { motd: motds[activeStep] }, void 0)) : ((_o = motds[activeStep]) === null || _o === void 0 ? void 0 : _o.displayType) === MotdDisplayType.Text ? (_jsx(MotdTextOnly, { motd: motds[activeStep] }, void 0)) : null] }), void 0));\n};\nexport default Motd;\n//# sourceMappingURL=Motd.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar CalendarIcon = function (_a) {\n var days = _a.days;\n var id = useUUID();\n return (_jsxs(\"svg\", __assign({ width: \"48\", height: \"44\", viewBox: \"0 0 36 33\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": \"calendarIconTitleId-\" + id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: \"calendarIconTitleId-\" + id }, { children: days }), void 0), _jsx(\"path\", { d: \"M0 1.8C0 0.805888 0.805887 0 1.8 0H34.2C35.1941 0 36 0.805887 36 1.8V6H0V1.8Z\", fill: \"#44356F\" }, void 0), _jsx(\"path\", { d: \"M0 6H36V31.2C36 32.1941 35.1941 33 34.2 33H1.8C0.805886 33 0 32.1941 0 31.2V6Z\", fill: \"#FAFAFA\" }, void 0)] }), void 0));\n};\nexport default CalendarIcon;\n//# sourceMappingURL=CalendarIcon.js.map","import { differenceInDays } from 'date-fns';\nexport var getDaysToNextUpdate = function (nextScoreDate) {\n var difference = nextScoreDate ? differenceInDays(new Date(nextScoreDate), new Date().setHours(0, 0, 0, 0)) : 0;\n if (difference < 0) {\n return 0;\n }\n return difference;\n};\n//# sourceMappingURL=getDaysToNextUpdate.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { Divider, Paper } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/styles';\nimport { Colors } from '../../utils/colors';\nimport { BLOB_CONTAINER, GUIDED_TOUR_ID } from '../../utils/constants';\nimport { useTypography } from '../../styles/Typography';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport { Play } from 'react-feather';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport CalendarIcon from '../icons/CalendarIcon';\nimport clsx from 'clsx';\nimport { UserContext } from '../../contexts/UserContext';\nimport { getDaysToNextUpdate } from '../../utils/getDaysToNextUpdate';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n color: Colors.white,\n backgroundColor: Colors.purple,\n minHeight: 270,\n minWidth: 355,\n width: 355,\n height: 270,\n margin: 8\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n minWidth: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n minWidth: 330,\n },\n _a),\n cardTitle: {\n padding: 16,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n cardTitleLabel: {\n margin: 16,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n },\n days: {\n color: Colors.purple,\n fontWeight: 700,\n zIndex: 1,\n position: 'relative',\n left: 38,\n top: 4,\n },\n cardBody: {\n padding: 16,\n paddingTop: 0,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n });\n});\nvar MeasurementCard = function () {\n var classes = useStyles();\n var typo = useTypography();\n var user = useContext(UserContext).user;\n var _a = useContext(DialogContext), setVideoDialogContent = _a.setVideoDialogContent, setOpenVideoDialog = _a.setOpenVideoDialog;\n var daysToNextUpdate = getDaysToNextUpdate(user === null || user === void 0 ? void 0 : user.nextScoreDate);\n var openTour = function () {\n setVideoDialogContent({\n container: BLOB_CONTAINER,\n fileName: GUIDED_TOUR_ID + \".mp4\",\n contentId: GUIDED_TOUR_ID,\n views: 1,\n });\n setOpenVideoDialog(true);\n };\n return (_jsxs(Paper, __assign({ elevation: 1, className: classes.card }, { children: [_jsx(\"div\", __assign({ className: classes.cardTitle }, { children: _jsx(\"h2\", __assign({ className: typo.subtitle1, style: { color: Colors.white, marginLeft: 16 } }, { children: \"Getting to know you\" }), void 0) }), void 0), _jsx(Divider, {}, void 0), _jsxs(\"div\", __assign({ className: classes.cardBody }, { children: [_jsxs(\"div\", __assign({ className: classes.cardTitleLabel }, { children: [_jsx(\"span\", __assign({ className: clsx(typo.h5, classes.days), style: daysToNextUpdate < 10 ? { left: 32 } : undefined }, { children: daysToNextUpdate }), void 0), _jsx(CalendarIcon, { days: daysToNextUpdate }, void 0), _jsx(\"span\", __assign({ className: typo.overlineMini, style: { color: Colors.white, marginLeft: 8 } }, { children: \"Days Left\" }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.subtitle2, style: { color: Colors.white, textAlign: 'center', marginBottom: 16 } }, { children: \"It takes some time to prepare Nulia Works for you, but don\\u2019t wait to get started working on your Skills & Outcomes.\" }), void 0), _jsxs(SecondaryButton, __assign({ onClick: openTour, style: { width: 312, height: 36 } }, { children: [_jsx(Play, { style: { marginRight: 12 } }, void 0), \"Watch Your Guided Tour\"] }), void 0)] }), void 0)] }), void 0));\n};\nexport default MeasurementCard;\n//# sourceMappingURL=MeasurementCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { format } from 'date-fns';\nimport clsx from 'clsx';\nimport { AlertCircle, AlertTriangle, Calendar } from 'react-feather';\nimport { useTypography } from '../styles/Typography';\nimport { UserContext } from '../contexts/UserContext';\nimport { makeStyles } from '@material-ui/styles';\nimport { getDaysToNextUpdate } from '../utils/getDaysToNextUpdate';\nimport { Colors } from '../utils/colors';\nimport { Tooltip } from './Tooltip';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n section: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n margin: 8,\n },\n card: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n text: (_b = {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start'\n },\n _b[theme.breakpoints.down('sm')] = {\n alignItems: 'flex-start',\n },\n _b),\n });\n});\nvar NextLastUpdated = function () {\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var daysToNextUpdate = getDaysToNextUpdate(user === null || user === void 0 ? void 0 : user.nextScoreDate);\n var lastUpdated = (user === null || user === void 0 ? void 0 : user.previousScoreDate)\n ? \"Your progress was updated \" + format(new Date(user === null || user === void 0 ? void 0 : user.previousScoreDate), 'MMM do')\n : '';\n var nextUpdated = \"Next update \" + (daysToNextUpdate === 0 ? 'Today' : daysToNextUpdate === 1 ? 'Tomorrow' : \"in \" + daysToNextUpdate + \" Days\");\n var updated = lastUpdated !== '' ? lastUpdated + \", \" + nextUpdated : \"\" + nextUpdated;\n return (_jsx(\"section\", __assign({ className: classes.section }, { children: _jsx(\"div\", __assign({ className: classes.card }, { children: _jsx(\"span\", __assign({ className: clsx(typo.overline, classes.text) }, { children: (user === null || user === void 0 ? void 0 : user.isTenantAnonymized) ? (_jsxs(_Fragment, { children: [_jsx(AlertTriangle, { style: {\n fill: Colors.userSkill,\n color: Colors.white,\n width: 20,\n height: 20,\n marginRight: 8,\n } }, void 0), \"We are unable to update your progress due to a global tenant setting.\", _jsx(Tooltip, __assign({ title: \"We are working with your admin to address the issue\" }, { children: _jsx(AlertCircle, { style: { width: 14, height: 14, marginLeft: 8 } }, void 0) }), void 0)] }, void 0)) : (_jsxs(_Fragment, { children: [_jsx(Calendar, { style: { width: 14, height: 14, marginRight: 8 } }, void 0), updated] }, void 0)) }), void 0) }), void 0) }), void 0));\n};\nexport default NextLastUpdated;\n//# sourceMappingURL=NextLastUpdated.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useContext, useEffect, useState } from 'react';\nimport { HomeContext } from '../../contexts/HomeContext';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useGetHomeData } from '../../hooks/useGetHomeData';\nimport Loading from '../Loading';\nimport AchievementCard from './AchievementCard';\nimport BadgeCard from './BadgeCard';\nimport HomeRecommendation from '../HomeRecommendation';\nimport SnapShot from './SnapShot';\nimport StreaksCard from './StreaksCard';\nimport { Pages } from '../../types/enums';\nimport Motd from '../motd/Motd';\nimport MeasurementCard from './MeasurementCard';\nimport NextLastUpdated from '../NextLastUpdated';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n row: (_a = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n margin: 8\n },\n _a[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n '& > *': {\n marginTop: 8,\n marginBottom: 8,\n },\n },\n _a),\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridAutoRows: '1fr',\n gridColumnGap: 16,\n },\n });\n});\nvar Home = function (_a) {\n var page = _a.page, clientType = _a.clientType;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = useContext(HomeContext), homeActivities = _b.homeActivities, motds = _b.motds;\n var _c = useContext(HeaderContext), setTitle = _c.setTitle, setGoBack = _c.setGoBack, setTabs = _c.setTabs, setPage = _c.setPage;\n var _d = __read(useState(false), 2), receivedData = _d[0], setReceivedData = _d[1];\n var getData = useGetHomeData();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n useEffect(function () {\n setTitle('Home');\n setGoBack(false);\n setTabs(undefined);\n setPage(page !== null && page !== void 0 ? page : Pages.HomePage);\n }, [page, setGoBack, setPage, setTabs, setTitle]);\n useEffect(function () {\n if (!receivedData) {\n getData();\n setReceivedData(true);\n }\n }, [receivedData, getData]);\n if (!user) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"main\", { children: [(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) ? null : _jsx(NextLastUpdated, {}, void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(Motd, { motds: motds }, void 0), user.inTwoWeekMeasurement ? _jsx(MeasurementCard, {}, void 0) : _jsx(SnapShot, { clientType: clientType }, void 0)] }), void 0), _jsx(\"section\", __assign({ className: classes.row, \"aria-label\": \"Recommended Activities\" }, { children: (homeActivities === null || homeActivities === void 0 ? void 0 : homeActivities.length) === 1 ? (homeActivities &&\n homeActivities.map(function (value, index) { return (_jsx(HomeRecommendation, { user: user, value: value, large: homeActivities.length === 1, home: true }, index)); })) : isMdDown ? (homeActivities &&\n homeActivities\n .slice(0, 2)\n .map(function (value, index) { return (_jsx(HomeRecommendation, { user: user, value: value, large: homeActivities.length === 1, home: true }, index)); })) : (_jsx(\"div\", __assign({ className: classes.grid }, { children: homeActivities &&\n homeActivities\n .slice(0, 2)\n .map(function (value, index) { return (_jsx(HomeRecommendation, { user: user, value: value, large: homeActivities.length === 1, home: true }, index)); }) }), void 0)) }), void 0), _jsxs(\"section\", __assign({ className: classes.row, \"aria-label\": \"Showcase\" }, { children: [_jsx(BadgeCard, { user: user, clientType: clientType }, void 0), _jsx(AchievementCard, { clientType: clientType }, void 0), _jsx(StreaksCard, { clientType: clientType }, void 0)] }), void 0)] }, void 0));\n};\nexport default Home;\n//# sourceMappingURL=Home.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var SkillsContext = createContext({});\nexport var SkillsProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), skills = _b[0], setSkills = _b[1];\n var _c = __read(useState(undefined), 2), allSkills = _c[0], setAllSkills = _c[1];\n var _d = __read(useState(undefined), 2), skill = _d[0], setSkill = _d[1];\n var _e = __read(useState(undefined), 2), recommendedSkills = _e[0], setRecommendedSkills = _e[1];\n var _f = __read(useState(false), 2), deepLink = _f[0], setDeepLink = _f[1];\n var _g = __read(useState({\n mythings: false,\n notmythings: false,\n all: false,\n sharepoint: false,\n onedrive: false,\n yammer: false,\n onenote: false,\n word: false,\n excel: false,\n powerpoint: false,\n teams: false,\n outlook: false,\n office365: false,\n delve: false,\n planner: false,\n todo: false,\n forms: false,\n powerautomate: false,\n bookings: false,\n edge: false,\n collaboration: false,\n communication: false,\n datamanagementandautomation: false,\n fundamentals: false,\n leadership: false,\n timeandtaskmanagement: false,\n education: false,\n intune: false,\n myapps: false,\n }), 2), filtersSkills = _g[0], setFiltersSkills = _g[1];\n var _h = __read(useState(undefined), 2), allOutcomes = _h[0], setAllOutcomes = _h[1];\n var skillsContext = {\n skills: skills,\n setSkills: setSkills,\n allSkills: allSkills,\n setAllSkills: setAllSkills,\n skill: skill,\n setSkill: setSkill,\n recommendedSkills: recommendedSkills,\n setRecommendedSkills: setRecommendedSkills,\n deepLink: deepLink,\n setDeepLink: setDeepLink,\n filtersSkills: filtersSkills,\n setFiltersSkills: setFiltersSkills,\n allOutcomes: allOutcomes,\n setAllOutcomes: setAllOutcomes,\n };\n return _jsx(SkillsContext.Provider, __assign({ value: skillsContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=SkillsContext.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { SkillsContext } from '../contexts/SkillsContext';\nimport { SkillService } from '../services/SkillService';\nimport { OutcomeService } from '../services/OutcomeService';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nexport var useGetSkillsData = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var skillsContext = useContext(SkillsContext);\n var getUser = useGetUser();\n var getUserSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, userSkills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getUserSkills()];\n case 2:\n userSkills = _a.sent();\n if (!userSkills) {\n return [2];\n }\n skillsContext.setSkills(userSkills);\n return [2];\n }\n });\n }); };\n var getAllSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, allSkills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getAllSkills()];\n case 2:\n allSkills = _a.sent();\n if (!allSkills) {\n return [2];\n }\n skillsContext.setAllSkills(allSkills);\n return [2];\n }\n });\n }); };\n var getRecommendedSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, recommendedSkills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getRecommendedSkills()];\n case 2:\n recommendedSkills = _a.sent();\n if (!recommendedSkills) {\n return [2];\n }\n skillsContext.setRecommendedSkills(recommendedSkills);\n return [2];\n }\n });\n }); };\n var getAllOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, allOutcomes;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getAllOutcomes()];\n case 2:\n allOutcomes = _a.sent();\n if (!allOutcomes) {\n return [2];\n }\n skillsContext.setAllOutcomes(allOutcomes);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser(), getUserSkills(), getAllSkills(), getRecommendedSkills(), getAllOutcomes()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetSkillsData.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { IconButton } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useState } from 'react';\nimport { LockContext } from '../../contexts/LockContext';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { Colors } from '../../utils/colors';\nimport Dialog from '../Dialog';\nimport { Tooltip } from '../Tooltip';\nimport { Check } from 'react-feather';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n removeButton: {\n height: 38,\n minHeight: 38,\n width: 38,\n minWidth: 38,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: '50%',\n backgroundColor: 'transparent',\n color: Colors.purple,\n },\n disabled: {\n color: Colors.textSecondary,\n backgroundColor: Colors.background,\n },\n clickable: {\n '&:hover': {\n backgroundColor: Colors.iconHover,\n cursor: 'pointer',\n },\n '&:focus': {\n backgroundColor: Colors.iconHover,\n },\n },\n large: {\n height: 48,\n width: 48,\n },\n});\nvar RemoveButton = function (_a) {\n var user = _a.user, level = _a.level, skillOrOutcome = _a.skillOrOutcome, recommended = _a.recommended, onAccept = _a.onAccept, large = _a.large, describedById = _a.describedById, starter = _a.starter;\n var classes = useStyles();\n var _b = __read(useState(false), 2), mouseOver = _b[0], setMouseOver = _b[1];\n var _c = __read(useState(false), 2), mouseDown = _c[0], setMouseDown = _c[1];\n var _d = __read(useState(false), 2), open = _d[0], setOpen = _d[1];\n var _e = useContext(LockContext), disabled = _e.disabled, setDisabled = _e.setDisabled;\n var ApiService = useApiService();\n var type = isOutcome(skillOrOutcome) ? 'outcome' : 'skill';\n var onMouseOver = function () { return setMouseOver(true); };\n var onMouseOut = function () {\n setMouseOver(false);\n setMouseDown(false);\n };\n var onMouseDown = function () { return setMouseDown(true); };\n var onMouseUp = function () { return setMouseDown(false); };\n var onClick = function () { return setOpen(true); };\n var closeDialog = function () { return setOpen(false); };\n var accepted = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n closeDialog();\n setDisabled(true);\n return [4, ApiService.changeTargetLevel(user, user.oid, level, skillOrOutcome.id, type, recommended, false)];\n case 1:\n _a.sent();\n if (!onAccept) return [3, 3];\n return [4, onAccept()];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3:\n setDisabled(false);\n return [2];\n }\n });\n }); };\n var title = \"Remove \" + (type === 'outcome' ? 'Outcome' : 'Skill');\n return (_jsxs(_Fragment, { children: [_jsx(Tooltip, __assign({ title: title }, { children: _jsx(IconButton, __assign({ className: clsx(classes.removeButton, large ? classes.large : undefined, !(disabled || starter) ? classes.clickable : undefined, (disabled || starter) && classes.disabled), onClick: !(disabled || starter) ? onClick : undefined, onMouseOver: !(disabled || starter) ? onMouseOver : undefined, onMouseOut: !(disabled || starter) ? onMouseOut : undefined, onMouseDown: !(disabled || starter) ? onMouseDown : undefined, onMouseUp: !(disabled || starter) ? onMouseUp : undefined, style: {\n border: disabled || starter\n ? ''\n : mouseOver && !mouseDown\n ? \"1px solid \" + Colors.textPrimary\n : mouseDown\n ? '1px solid rgba(101,78,163,0.24)'\n : '1px solid rgba(101,78,163,0.24)',\n }, \"aria-label\": title, \"aria-describedby\": describedById }, { children: _jsx(Check, {}, void 0) }), void 0) }), void 0), _jsx(Dialog, { open: open, onClose: closeDialog, onAccept: accepted, title: \"Remove \" + (type === 'outcome' ? 'Outcome' : 'Skill'), text: type === 'outcome'\n ? \"Remove the Outcome \" + skillOrOutcome.name + \" from your assigned Outcomes?\"\n : \"Remove the Skill \" + skillOrOutcome.name + \" from your assigned Skills?\", cancelText: 'Cancel', acceptText: 'Remove', disabled: disabled || starter, cancelDisabled: disabled || starter }, void 0)] }, void 0));\n};\nexport default RemoveButton;\n//# sourceMappingURL=RemoveButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar ProducerAchievedIcon = function () {\n var id = useUUID('producerAchievedIconTitleId');\n return (_jsx(\"svg\", __assign({ width: \"24px\", height: \"28px\", viewBox: \"0 0 24 28\", version: \"1.1\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-177.000000, -1046.000000)\" }, { children: _jsxs(\"g\", __assign({ transform: \"translate(177.000000, 1048.000000)\" }, { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M21.75,17.0474394 L21.75,6.95256059 C21.75,6.5951823 21.5592818,6.26496901 21.2497268,6.0863775 L12.4998336,1.03830391 C12.1905745,0.859883149 11.8096496,0.859881245 11.5003887,1.03829892 L2.75028188,6.08637917 C2.44072196,6.26496937 2.25,6.59518539 2.25,6.95256726 L2.25,17.0474327 C2.25,17.4048146 2.44072196,17.7350306 2.75028188,17.9136208 L11.5003887,22.9617011 C11.8096496,23.1401188 12.1905745,23.1401169 12.4998336,22.9616961 L21.2497268,17.9136225 C21.5592818,17.735031 21.75,17.4048177 21.75,17.0474394 Z\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M22.75,17.0474394 C22.75,17.762196 22.3685636,18.4226226 21.7494536,18.7798056 L12.9995604,23.8278792 C12.3810422,24.1847207 11.6191923,24.1847245 11.0006706,23.8278892 L2.25056375,18.7798089 C1.63144393,18.4226285 1.25,17.7621965 1.25,17.0474327 L1.25,6.95256726 C1.25,6.23780353 1.63144393,5.57737148 2.25056375,5.22019109 L11.0006706,0.172110834 C11.6191923,-0.184724512 12.3810422,-0.184720704 12.9995604,0.172120825 L21.7494536,5.22019442 C22.3685636,5.57737743 22.75,6.237804 22.75,6.95256059 L22.75,17.0474394 Z\", stroke: \"#FFFFFF\", strokeWidth: \"2\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M21.75,17.0474394 L21.75,6.95256059 C21.75,6.5951823 21.5592818,6.26496901 21.2497268,6.0863775 L12.4998336,1.03830391 C12.1905745,0.859883149 11.8096496,0.859881245 11.5003887,1.03829892 L2.75028188,6.08637917 C2.44072196,6.26496937 2.25,6.59518539 2.25,6.95256726 L2.25,17.0474327 C2.25,17.4048146 2.44072196,17.7350306 2.75028188,17.9136208 L11.5003887,22.9617011 C11.8096496,23.1401188 12.1905745,23.1401169 12.4998336,22.9616961 L21.2497268,17.9136225 C21.5592818,17.735031 21.75,17.4048177 21.75,17.0474394 Z\", fill: Colors.producerSkill }, void 0)] }), void 0) }), void 0) }), void 0) }), void 0));\n};\nexport default ProducerAchievedIcon;\n//# sourceMappingURL=ProducerAchievedIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar MasterAchievedIcon = function () {\n var id = useUUID('masterAchievedIconTitleId');\n return (_jsx(\"svg\", __assign({ width: \"28px\", height: \"28px\", viewBox: \"0 0 28 28\", version: \"1.1\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-261.000000, -1046.000000)\" }, { children: _jsxs(\"g\", __assign({ transform: \"translate(263.000000, 1048.000000)\" }, { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M20.7811242,7.95259587 L20.7811242,4.2188752 C20.7811242,3.66659045 20.3334089,3.2188752 19.7811242,3.2188752 L16.0474035,3.2188752 C15.782187,3.2188752 15.5278331,3.11351836 15.3402967,2.92598198 L12.7071065,0.292791721 C12.3165822,-0.0977325703 11.6834172,-0.0977325703 11.2928929,0.292791721 L8.65970265,2.92598198 C8.47216627,3.11351836 8.21781236,3.2188752 7.95259587,3.2188752 L4.2188752,3.2188752 C3.66659045,3.2188752 3.2188752,3.66659045 3.2188752,4.2188752 L3.2188752,7.95259587 C3.2188752,8.21781236 3.11351836,8.47216627 2.92598198,8.65970265 L0.292791721,11.2928929 C-0.0977325703,11.6834172 -0.0977325703,12.3165822 0.292791721,12.7071065 L2.92598198,15.3402967 C3.11351836,15.5278331 3.2188752,15.782187 3.2188752,16.0474035 L3.2188752,19.7811242 C3.2188752,20.3334089 3.66659045,20.7811242 4.2188752,20.7811242 L7.95259587,20.7811242 C8.21781236,20.7811242 8.47216627,20.886481 8.65970265,21.0740174 L11.2928929,23.7072077 C11.6834172,24.0977319 12.3165822,24.0977319 12.7071065,23.7072077 L15.3402967,21.0740174 C15.5278331,20.886481 15.782187,20.7811242 16.0474035,20.7811242 L19.7811242,20.7811242 C20.3334089,20.7811242 20.7811242,20.3334089 20.7811242,19.7811242 L20.7811242,16.0474035 C20.7811242,15.782187 20.886481,15.5278331 21.0740174,15.3402967 L23.7072077,12.7071065 C24.0977319,12.3165822 24.0977319,11.6834172 23.7072077,11.2928929 L21.0740174,8.65970265 C20.886481,8.47216627 20.7811242,8.21781236 20.7811242,7.95259587 Z\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M21.7811242,7.95259587 L24.4143144,10.5857861 C25.195363,11.3668347 25.195363,12.6331647 24.4143144,13.4142132 L21.7811242,16.0474035 L21.7811242,19.7811242 C21.7811242,20.8856937 20.8856937,21.7811242 19.7811242,21.7811242 L16.0474035,21.7811242 L13.4142132,24.4143144 C12.6331647,25.195363 11.3668347,25.195363 10.5857861,24.4143144 L7.95259587,21.7811242 L4.2188752,21.7811242 C3.1143057,21.7811242 2.2188752,20.8856937 2.2188752,19.7811242 L2.2188752,16.0474035 L-0.41431506,13.4142132 C-1.19536364,12.6331647 -1.19536364,11.3668347 -0.41431506,10.5857861 L2.2188752,7.95259587 L2.2188752,4.2188752 C2.2188752,3.1143057 3.1143057,2.2188752 4.2188752,2.2188752 L7.95259587,2.2188752 L10.5857861,-0.41431506 C11.3668347,-1.19536364 12.6331647,-1.19536364 13.4142132,-0.41431506 L16.0474035,2.2188752 L19.7811242,2.2188752 C20.8856937,2.2188752 21.7811242,3.1143057 21.7811242,4.2188752 L21.7811242,7.95259587 Z\", stroke: \"#FFFFFF\", strokeWidth: \"2\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M20.7811242,8.36680943 L20.7811242,3.7188752 C20.7811242,3.44273282 20.5572666,3.2188752 20.2811242,3.2188752 L15.6331899,3.2188752 L12.3535531,-0.0607616692 C12.1582909,-0.256023815 11.8417084,-0.256023815 11.6464463,-0.0607616692 L8.36680943,3.2188752 L3.7188752,3.2188752 C3.44273282,3.2188752 3.2188752,3.44273282 3.2188752,3.7188752 L3.2188752,8.36680943 L-0.0607616692,11.6464463 C-0.256023815,11.8417084 -0.256023815,12.1582909 -0.0607616692,12.3535531 L3.2188752,15.6331899 L3.2188752,20.2811242 C3.2188752,20.5572666 3.44273282,20.7811242 3.7188752,20.7811242 L8.36680943,20.7811242 L11.6464463,24.060761 C11.8417084,24.2560232 12.1582909,24.2560232 12.3535531,24.060761 L15.6331899,20.7811242 L20.2811242,20.7811242 C20.5572666,20.7811242 20.7811242,20.5572666 20.7811242,20.2811242 L20.7811242,16.0474035 C20.7811242,15.782187 20.886481,15.5278331 21.0740174,15.3402967 L24.060761,12.3535531 C24.2560232,12.1582909 24.2560232,11.8417084 24.060761,11.6464463 L20.7811242,8.36680943 Z\", fill: Colors.masterSkill }, void 0)] }), void 0) }), void 0) }), void 0) }), void 0));\n};\nexport default MasterAchievedIcon;\n//# sourceMappingURL=MasterAchievedIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar ProducerUnachievedIcon = function () {\n var id = useUUID('producerUnachievedIconTitleId');\n return (_jsx(\"svg\", __assign({ width: \"24px\", height: \"28px\", viewBox: \"0 0 24 28\", version: \"1.1\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-177.000000, -1046.000000)\" }, { children: _jsxs(\"g\", __assign({ transform: \"translate(177.000000, 1048.000000)\" }, { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M21.75,17.0474394 L21.75,6.95256059 C21.75,6.5951823 21.5592818,6.26496901 21.2497268,6.0863775 L12.4998336,1.03830391 C12.1905745,0.859883149 11.8096496,0.859881245 11.5003887,1.03829892 L2.75028188,6.08637917 C2.44072196,6.26496937 2.25,6.59518539 2.25,6.95256726 L2.25,17.0474327 C2.25,17.4048146 2.44072196,17.7350306 2.75028188,17.9136208 L11.5003887,22.9617011 C11.8096496,23.1401188 12.1905745,23.1401169 12.4998336,22.9616961 L21.2497268,17.9136225 C21.5592818,17.735031 21.75,17.4048177 21.75,17.0474394 Z\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M22.75,17.0474394 C22.75,17.762196 22.3685636,18.4226226 21.7494536,18.7798056 L12.9995604,23.8278792 C12.3810422,24.1847207 11.6191923,24.1847245 11.0006706,23.8278892 L2.25056375,18.7798089 C1.63144393,18.4226285 1.25,17.7621965 1.25,17.0474327 L1.25,6.95256726 C1.25,6.23780353 1.63144393,5.57737148 2.25056375,5.22019109 L11.0006706,0.172110834 C11.6191923,-0.184724512 12.3810422,-0.184720704 12.9995604,0.172120825 L21.7494536,5.22019442 C22.3685636,5.57737743 22.75,6.237804 22.75,6.95256059 L22.75,17.0474394 Z\", stroke: \"#FFFFFF\", strokeWidth: \"2\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M21.75,17.0474394 L21.75,6.95256059 C21.75,6.5951823 21.5592818,6.26496901 21.2497268,6.0863775 L12.4998336,1.03830391 C12.1905745,0.859883149 11.8096496,0.859881245 11.5003887,1.03829892 L2.75028188,6.08637917 C2.44072196,6.26496937 2.25,6.59518539 2.25,6.95256726 L2.25,17.0474327 C2.25,17.4048146 2.44072196,17.7350306 2.75028188,17.9136208 L11.5003887,22.9617011 C11.8096496,23.1401188 12.1905745,23.1401169 12.4998336,22.9616961 L21.2497268,17.9136225 C21.5592818,17.735031 21.75,17.4048177 21.75,17.0474394 Z\", fill: Colors.unachievedSkill }, void 0)] }), void 0) }), void 0) }), void 0) }), void 0));\n};\nexport default ProducerUnachievedIcon;\n//# sourceMappingURL=ProducerUnachievedIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar MasterUnachievedIcon = function () {\n var id = useUUID('masterUnachievedIconTitleId');\n return (_jsx(\"svg\", __assign({ width: \"28px\", height: \"28px\", viewBox: \"0 0 28 28\", version: \"1.1\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-261.000000, -1046.000000)\" }, { children: _jsxs(\"g\", __assign({ id: \"icone-level-master\", transform: \"translate(263.000000, 1048.000000)\" }, { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"24\", height: \"24\" }, void 0), _jsx(\"path\", { d: \"M20.7811242,7.95259587 L20.7811242,4.2188752 C20.7811242,3.66659045 20.3334089,3.2188752 19.7811242,3.2188752 L16.0474035,3.2188752 C15.782187,3.2188752 15.5278331,3.11351836 15.3402967,2.92598198 L12.7071065,0.292791721 C12.3165822,-0.0977325703 11.6834172,-0.0977325703 11.2928929,0.292791721 L8.65970265,2.92598198 C8.47216627,3.11351836 8.21781236,3.2188752 7.95259587,3.2188752 L4.2188752,3.2188752 C3.66659045,3.2188752 3.2188752,3.66659045 3.2188752,4.2188752 L3.2188752,7.95259587 C3.2188752,8.21781236 3.11351836,8.47216627 2.92598198,8.65970265 L0.292791721,11.2928929 C-0.0977325703,11.6834172 -0.0977325703,12.3165822 0.292791721,12.7071065 L2.92598198,15.3402967 C3.11351836,15.5278331 3.2188752,15.782187 3.2188752,16.0474035 L3.2188752,19.7811242 C3.2188752,20.3334089 3.66659045,20.7811242 4.2188752,20.7811242 L7.95259587,20.7811242 C8.21781236,20.7811242 8.47216627,20.886481 8.65970265,21.0740174 L11.2928929,23.7072077 C11.6834172,24.0977319 12.3165822,24.0977319 12.7071065,23.7072077 L15.3402967,21.0740174 C15.5278331,20.886481 15.782187,20.7811242 16.0474035,20.7811242 L19.7811242,20.7811242 C20.3334089,20.7811242 20.7811242,20.3334089 20.7811242,19.7811242 L20.7811242,16.0474035 C20.7811242,15.782187 20.886481,15.5278331 21.0740174,15.3402967 L23.7072077,12.7071065 C24.0977319,12.3165822 24.0977319,11.6834172 23.7072077,11.2928929 L21.0740174,8.65970265 C20.886481,8.47216627 20.7811242,8.21781236 20.7811242,7.95259587 Z\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M21.7811242,7.95259587 L24.4143144,10.5857861 C25.195363,11.3668347 25.195363,12.6331647 24.4143144,13.4142132 L21.7811242,16.0474035 L21.7811242,19.7811242 C21.7811242,20.8856937 20.8856937,21.7811242 19.7811242,21.7811242 L16.0474035,21.7811242 L13.4142132,24.4143144 C12.6331647,25.195363 11.3668347,25.195363 10.5857861,24.4143144 L7.95259587,21.7811242 L4.2188752,21.7811242 C3.1143057,21.7811242 2.2188752,20.8856937 2.2188752,19.7811242 L2.2188752,16.0474035 L-0.41431506,13.4142132 C-1.19536364,12.6331647 -1.19536364,11.3668347 -0.41431506,10.5857861 L2.2188752,7.95259587 L2.2188752,4.2188752 C2.2188752,3.1143057 3.1143057,2.2188752 4.2188752,2.2188752 L7.95259587,2.2188752 L10.5857861,-0.41431506 C11.3668347,-1.19536364 12.6331647,-1.19536364 13.4142132,-0.41431506 L16.0474035,2.2188752 L19.7811242,2.2188752 C20.8856937,2.2188752 21.7811242,3.1143057 21.7811242,4.2188752 L21.7811242,7.95259587 Z\", stroke: \"#FFFFFF\", strokeWidth: \"2\", fill: \"#FFFFFF\" }, void 0), _jsx(\"path\", { d: \"M20.7811242,8.36680943 L20.7811242,3.7188752 C20.7811242,3.44273282 20.5572666,3.2188752 20.2811242,3.2188752 L15.6331899,3.2188752 L12.3535531,-0.0607616692 C12.1582909,-0.256023815 11.8417084,-0.256023815 11.6464463,-0.0607616692 L8.36680943,3.2188752 L3.7188752,3.2188752 C3.44273282,3.2188752 3.2188752,3.44273282 3.2188752,3.7188752 L3.2188752,8.36680943 L-0.0607616692,11.6464463 C-0.256023815,11.8417084 -0.256023815,12.1582909 -0.0607616692,12.3535531 L3.2188752,15.6331899 L3.2188752,20.2811242 C3.2188752,20.5572666 3.44273282,20.7811242 3.7188752,20.7811242 L8.36680943,20.7811242 L11.6464463,24.060761 C11.8417084,24.2560232 12.1582909,24.2560232 12.3535531,24.060761 L15.6331899,20.7811242 L20.2811242,20.7811242 C20.5572666,20.7811242 20.7811242,20.5572666 20.7811242,20.2811242 L20.7811242,16.0474035 C20.7811242,15.782187 20.886481,15.5278331 21.0740174,15.3402967 L24.060761,12.3535531 C24.2560232,12.1582909 24.2560232,11.8417084 24.060761,11.6464463 L20.7811242,8.36680943 Z\", fill: Colors.unachievedSkill }, void 0)] }), void 0) }), void 0) }), void 0) }), void 0));\n};\nexport default MasterUnachievedIcon;\n//# sourceMappingURL=MasterUnachievedIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nvar useStyles = makeStyles({\n skillIcon: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n height: 28,\n width: 28,\n backgroundColor: 'transparent',\n },\n});\nvar SkillIconContainer = function (_a) {\n var children = _a.children;\n var classes = useStyles();\n return _jsx(\"span\", __assign({ className: classes.skillIcon }, { children: children }), void 0);\n};\nexport default SkillIconContainer;\n//# sourceMappingURL=SkillIconContainer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles, createStyles } from '@material-ui/core/styles';\nvar useStyles = makeStyles(createStyles({\n icon: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n height: 20,\n width: 20,\n backgroundColor: 'transparent',\n },\n}));\nvar OutcomeLevelIconContainer = function (_a) {\n var children = _a.children, large = _a.large;\n var classes = useStyles();\n return (_jsx(\"span\", __assign({ className: classes.icon, style: large ? { height: 36, width: 36 } : undefined }, { children: children }), void 0));\n};\nexport default OutcomeLevelIconContainer;\n//# sourceMappingURL=OutcomeLevelIconContainer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport UserUnachievedIcon from './icons/UserUnachievedIcon';\nimport UserAchievedIcon from './icons/UserAchievedIcon';\nimport ProducerAchievedIcon from './icons/ProducerAchievedIcon';\nimport MasterAchievedIcon from './icons/MasterAchievedIcon';\nimport ProducerUnachievedIcon from './icons/ProducerUnachievedIcon';\nimport MasterUnachievedIcon from './icons/MasterUnachievedIcon';\nimport SkillIconContainer from './skills/SkillIconContainer';\nimport OutcomeLevelIconContainer from './outcomes/OutcomeLevelIconContainer';\nimport { Tooltip } from './Tooltip';\nimport { CompetenceState, Level } from '../types/enums';\nvar LevelIcon = function (_a) {\n var progress = _a.progress, level = _a.level, state = _a.state, type = _a.type;\n var icon;\n if ((level === Level.None || level === Level.User) && state === CompetenceState.Unassigned) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. User level not assigned\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(UserUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(UserUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.User && state === CompetenceState.InProgress) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. In Progress.\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(UserUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(UserUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.User &&\n (state === CompetenceState.NeedsAttention || state === CompetenceState.Maintain)) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. \" + (state === CompetenceState.NeedsAttention ? 'In needs attention.' : 'Attained.') }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(UserAchievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(UserAchievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.Producer && state === CompetenceState.Unassigned) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. Producer level not assigned\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(ProducerUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(ProducerUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.Producer && state === CompetenceState.InProgress) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. In Progress.\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(ProducerUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(ProducerUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.Producer &&\n (state === CompetenceState.NeedsAttention || state === CompetenceState.Maintain)) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. \" + (state === CompetenceState.NeedsAttention ? 'In needs attention.' : 'Attained.') }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(ProducerAchievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(ProducerAchievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.Master && state === CompetenceState.Unassigned) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. Master level not assigned\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(MasterUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(MasterUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.Master && state === CompetenceState.InProgress) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. In Progress.\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(MasterUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(MasterUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else if (level === Level.Master &&\n (state === CompetenceState.NeedsAttention || state === CompetenceState.Maintain)) {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete.\" + (state === CompetenceState.NeedsAttention ? 'In needs attention.' : 'Attained.') }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(MasterAchievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(MasterAchievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n else {\n icon = (_jsx(Tooltip, __assign({ title: progress + \"% complete. User level not yet achieved\" }, { children: type === 'skill' ? (_jsx(SkillIconContainer, { children: _jsx(UserUnachievedIcon, {}, void 0) }, void 0)) : (_jsx(OutcomeLevelIconContainer, __assign({ large: type === 'outcome large' }, { children: _jsx(UserUnachievedIcon, {}, void 0) }), void 0)) }), void 0));\n }\n return icon;\n};\nexport default LevelIcon;\n//# sourceMappingURL=LevelIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { CircularProgress } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useCallback, useEffect, useState, useContext } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { OUTCOMES_PATH } from '../../utils/constants';\nimport LevelIcon from '../LevelIcon';\nimport { CompetenceState } from '../../types/enums';\nimport { UserContext } from '../../contexts/UserContext';\nvar useStyles = makeStyles({\n outcomeImage: function (_a) {\n var type = _a.type;\n return ({\n border: type === 'outcome' ? '4px solid #ebebeb' : '6px solid #ebebeb',\n position: 'relative',\n backgroundColor: 'transparent',\n borderRadius: '50%',\n height: type === 'outcome' ? 76 : 123,\n minHeight: type === 'outcome' ? 76 : 123,\n width: type === 'outcome' ? 76 : 123,\n minWidth: type === 'outcome' ? 76 : 123,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n });\n },\n unavailableOutcomeImage: function (_a) {\n var type = _a.type;\n return ({\n border: 'none',\n position: 'relative',\n backgroundColor: 'transparent',\n height: type === 'outcome' ? 76 : 123,\n minHeight: type === 'outcome' ? 76 : 123,\n width: type === 'outcome' ? 76 : 123,\n minWidth: type === 'outcome' ? 76 : 123,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n });\n },\n progress: function (_a) {\n var type = _a.type;\n return ({\n transform: 'rotate(45deg) !important',\n position: 'absolute',\n top: type === 'outcome' ? -4 : -6,\n left: type === 'outcome' ? -4 : -6,\n });\n },\n progressCircle: {\n transitionDelay: '1s',\n },\n increase: {\n color: Colors.green,\n },\n decrease: {\n color: Colors.red,\n },\n flat: {\n color: Colors.yellow,\n },\n unassigned: {\n color: Colors.progressUnassigned,\n },\n image: function (_a) {\n var type = _a.type;\n return ({\n height: type === 'outcome' ? 64 : 107,\n minHeight: type === 'outcome' ? 64 : 107,\n width: type === 'outcome' ? 64 : 107,\n minWidth: type === 'outcome' ? 64 : 107,\n });\n },\n icon: function (_a) {\n var type = _a.type;\n return ({\n top: type === 'outcome' ? 48 : 72,\n left: type === 'outcome' ? 50 : 85,\n height: type === 'outcome' ? 20 : 36,\n minHeight: type === 'outcome' ? 20 : 36,\n width: type === 'outcome' ? 20 : 36,\n minWidth: type === 'outcome' ? 20 : 36,\n position: 'absolute',\n display: 'flex',\n });\n },\n});\nvar OutcomeImage = function (_a) {\n var outcome = _a.outcome, type = _a.type, maintain = _a.maintain, unavailable = _a.unavailable, describedById = _a.describedById;\n var classes = useStyles({ type: type });\n var _b = __read(useState(0), 2), progress = _b[0], setProgress = _b[1];\n var user = useContext(UserContext).user;\n var getProgressColor = useCallback(function () {\n return maintain\n ? classes.increase\n : [CompetenceState.Locked, CompetenceState.Unassigned].includes(outcome.current.state)\n ? classes.unassigned\n : outcome.current.state === CompetenceState.NeedsAttention\n ? classes.decrease\n : outcome.current.state === CompetenceState.InProgress\n ? classes.flat\n : classes.increase;\n }, [classes.decrease, classes.flat, classes.increase, classes.unassigned, maintain, outcome]);\n useEffect(function () {\n var timeout = setTimeout(function () {\n setProgress(outcome.current.progress);\n clearTimeout(timeout);\n }, 1);\n return function () {\n clearTimeout(timeout);\n };\n }, [outcome]);\n var value = outcome.current.state !== CompetenceState.Maintain ? progress : 100;\n if (user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) {\n return _jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + outcome.image + \".svg\", loading: \"lazy\" }, void 0);\n }\n return (_jsxs(\"div\", __assign({ className: clsx(!unavailable ? classes.outcomeImage : classes.unavailableOutcomeImage) }, { children: [!unavailable && (_jsx(CircularProgress, { variant: \"determinate\", value: value, thickness: 2, size: type === 'outcome' ? 76 : 123, classes: {\n root: clsx(classes.progress, getProgressColor()),\n circle: classes.progressCircle,\n }, \"aria-describedby\": describedById, \"aria-valuetext\": value + \"% complete\", \"aria-label\": \"Outcome Progress Bar\" }, void 0)), _jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + outcome.image + \".svg\", loading: \"lazy\" }, void 0), !unavailable && (_jsx(\"div\", __assign({ className: classes.icon }, { children: _jsx(LevelIcon, { progress: outcome.current.progress, level: outcome.current.level, state: outcome.current.state, type: type }, void 0) }), void 0))] }), void 0));\n};\nexport default OutcomeImage;\n//# sourceMappingURL=OutcomeImage.js.map","import { CompetenceState } from '../types/enums';\nexport var isUnavailable = function (state) {\n return (state === CompetenceState.LockedCollectorVersion ||\n state === CompetenceState.LockedStarter ||\n state === CompetenceState.LockedEdu ||\n state === CompetenceState.LockedHardhat);\n};\n//# sourceMappingURL=isUnavailable.js.map","import { CompetenceState } from '../types/enums';\nexport var isUnassigned = function (state) {\n return state === CompetenceState.Unassigned || state === CompetenceState.Locked;\n};\n//# sourceMappingURL=isUnassigned.js.map","import { CompetenceState } from '../types/enums';\nexport var toStateString = function (state) {\n if (state === CompetenceState.Maintain) {\n return 'Maintained';\n }\n else if (state === CompetenceState.InProgress) {\n return 'In Progress';\n }\n else if (state === CompetenceState.NeedsAttention) {\n return 'Needs Attention';\n }\n else {\n return '';\n }\n};\n//# sourceMappingURL=toStateString.js.map","import { isUnassigned } from './isUnassigned';\nimport { toStateString } from './toStateString';\nexport var toStreakString = function (state, length) {\n if (!length || isUnassigned(state)) {\n return '';\n }\n else if (length === 1) {\n return toStateString(state) + \" for \" + length + \" day\";\n }\n else if (length === 0 || length < 14) {\n return toStateString(state) + \" for \" + length + \" days\";\n }\n else {\n return toStateString(state) + \" for \" + Math.floor(length / 7) + \" weeks\";\n }\n};\n//# sourceMappingURL=toStreakString.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Link as MuiLink, makeStyles, useMediaQuery, useTheme } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { useEffect, useRef } from 'react';\nimport { Link } from 'react-router-dom';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport NewUpdatedLabel from '../NewUpdatedLabel';\nimport OutcomeImage from './OutcomeImage';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { toStreakString } from '../../utils/toStreakString';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n outcome: {\n display: 'flex',\n alignItems: 'center',\n flexDirection: 'row-reverse',\n padding: '16px 0',\n width: '100%',\n textDecoration: 'none',\n '&:focus, &:hover, &:visited, &:link, &:active': {\n textDecoration: 'none',\n },\n color: Colors.black,\n },\n title: (_a = {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between'\n },\n _a[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-start',\n },\n _a),\n innerOutcome: {\n borderBottom: '1px solid rgba(0,0,0,0.12)',\n },\n content: (_b = {\n width: '100%',\n marginLeft: 16,\n marginRight: 16\n },\n _b[theme.breakpoints.down('md')] = {\n display: 'flex',\n flexDirection: 'column',\n },\n _b),\n clickable: {\n cursor: 'pointer',\n },\n label: (_c = {},\n _c[theme.breakpoints.up('lg')] = {\n textAlign: 'right',\n },\n _c),\n });\n});\nvar Outcome = function (_a) {\n var outcome = _a.outcome, describedById = _a.describedById, noLink = _a.noLink, noStreak = _a.noStreak, page = _a.page, tabIndex = _a.tabIndex, isAllSkillsOrOutcomes = _a.isAllSkillsOrOutcomes, currentlySelected = _a.currentlySelected;\n var typo = useTypography();\n var classes = useStyles();\n var theme = useTheme();\n var isLgUp = useMediaQuery(theme.breakpoints.up('lg'));\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var muiLinkRef = useRef();\n useEffect(function () {\n var _a;\n if (isAllSkillsOrOutcomes)\n return;\n if (tabIndex === 0 && currentlySelected !== -1) {\n (_a = muiLinkRef.current) === null || _a === void 0 ? void 0 : _a.focus();\n }\n }, [tabIndex, isAllSkillsOrOutcomes, currentlySelected]);\n var content = (_jsxs(_Fragment, { children: [_jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(NewUpdatedLabel, { createdDate: outcome.contentCreated, updatedDate: outcome.contentUpdated }, void 0), _jsxs(\"div\", __assign({ className: classes.title }, { children: [_jsx(\"h3\", __assign({ className: typo.subtitle2, id: describedById }, { children: outcome.name }), void 0), isLgUp && !noStreak && (_jsx(\"span\", __assign({ className: clsx(typo.label, classes.label) }, { children: toStreakString(outcome.current.state, outcome.current.currentStreak) }), void 0))] }), void 0), _jsx(\"span\", __assign({ className: typo.body2 }, { children: outcome.totalSkillCount &&\n outcome.totalSkillCount + \" \" + (Number(outcome.totalSkillCount) === 1 ? 'Skill' : 'Skills') }), void 0), isMdDown && !noStreak && (_jsx(\"span\", __assign({ className: clsx(typo.label, classes.label) }, { children: toStreakString(outcome.current.state, outcome.current.currentStreak) }), void 0))] }), void 0), _jsx(OutcomeImage, { outcome: outcome, unavailable: isUnavailable(outcome.current.state), type: \"outcome\", describedById: describedById }, void 0)] }, void 0));\n return (_jsx(_Fragment, { children: !noLink ? (_jsx(MuiLink, __assign({ ref: muiLinkRef, component: Link, to: page + \"/outcome-details/\" + outcome.id, className: classes.outcome, tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : undefined }, { children: content }), void 0)) : (_jsx(\"div\", __assign({ className: classes.outcome }, { children: content }), void 0)) }, void 0));\n};\nexport default Outcome;\n//# sourceMappingURL=Outcome.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { LinearProgress, makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { useState, useContext, useLayoutEffect } from 'react';\nimport { UserContext } from '../contexts/UserContext';\nimport { Colors } from '../utils/colors';\nimport { CompetenceState } from '../types/enums';\nvar useStyles = makeStyles(function (theme) { return ({\n progress: {\n width: '100%',\n marginTop: 8,\n },\n progressRoot: {\n height: 6,\n borderRadius: 8,\n },\n progressBar: {\n borderRadius: 8,\n transitionDelay: '1s',\n },\n colorPrimary: {\n backgroundColor: 'rgba(0, 0, 0, 0.08) !important',\n },\n barColorPrimaryGreen: {\n backgroundColor: Colors.green + \" !important\",\n },\n barColorPrimaryYellow: {\n backgroundColor: Colors.yellow + \" !important\",\n },\n barColorPrimaryRed: {\n backgroundColor: Colors.red + \" !important\",\n },\n label: {\n minWidth: 150,\n width: 150,\n },\n}); });\nexport var SkillProgressBar = function (_a) {\n var progress = _a.progress, currentState = _a.currentState;\n var classes = useStyles();\n var _b = __read(useState(0), 2), newProgress = _b[0], setNewProgress = _b[1];\n var _c = __read(useState(false), 2), isLoaded = _c[0], setIsLoaded = _c[1];\n var user = useContext(UserContext).user;\n useLayoutEffect(function () {\n var subscribed = true;\n setTimeout(function () {\n if (subscribed) {\n setNewProgress(progress);\n setIsLoaded(true);\n }\n }, 1);\n return function () {\n subscribed = false;\n };\n }, [progress]);\n if (user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) {\n return null;\n }\n return (_jsx(LinearProgress, { \"aria-hidden\": !isLoaded, \"aria-valuetext\": newProgress + \"% complete\", \"aria-label\": newProgress + \"% complete\", color: \"primary\", variant: \"determinate\", value: newProgress, className: classes.progress, classes: {\n root: classes.progressRoot,\n colorPrimary: classes.colorPrimary,\n bar: classes.progressBar,\n barColorPrimary: clsx(currentState === CompetenceState.NeedsAttention\n ? classes.barColorPrimaryRed\n : currentState === CompetenceState.InProgress\n ? classes.barColorPrimaryYellow\n : currentState === CompetenceState.Maintain\n ? classes.barColorPrimaryGreen\n : classes.colorPrimary),\n } }, void 0));\n};\n//# sourceMappingURL=SkillProgressBar.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Link as MuiLink } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useEffect, useRef } from 'react';\nimport { Link } from 'react-router-dom';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport LevelIcon from '../LevelIcon';\nimport NewUpdatedLabel from '../NewUpdatedLabel';\nimport { SkillProgressBar } from '../SkillProgressBar';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { toStreakString } from '../../utils/toStreakString';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n skill: {\n marginTop: 24,\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n textDecoration: 'none',\n marginBottom: 24,\n padding: '0 4px',\n '&:focus, &:hover, &:visited, &:link, &:active': {\n textDecoration: 'none',\n },\n color: Colors.black,\n },\n topBar: {\n width: '100%',\n height: '100%',\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n margin: 4,\n },\n info: {\n display: 'flex',\n width: '100%',\n },\n icon: {\n marginRight: 20,\n height: '100%',\n display: 'flex',\n alignItems: 'flex-start',\n },\n detail: (_a = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _a[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-start',\n },\n _a),\n label: (_b = {},\n _b[theme.breakpoints.up('lg')] = {\n textAlign: 'right',\n },\n _b),\n });\n});\nvar Skill = function (_a) {\n var skill = _a.skill, describedById = _a.describedById, noProgress = _a.noProgress, noLink = _a.noLink, tabIndex = _a.tabIndex, page = _a.page, isAllSkillsOrOutcomes = _a.isAllSkillsOrOutcomes, currentlySelected = _a.currentlySelected;\n var typo = useTypography();\n var classes = useStyles();\n var muiLinkRef = useRef();\n useEffect(function () {\n var _a;\n if (isAllSkillsOrOutcomes)\n return;\n if (tabIndex === 0 && currentlySelected !== -1) {\n (_a = muiLinkRef.current) === null || _a === void 0 ? void 0 : _a.focus();\n }\n }, [tabIndex, isAllSkillsOrOutcomes, currentlySelected]);\n var unavailable = isUnavailable(skill.current.state);\n var content = (_jsxs(_Fragment, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: _jsx(LevelIcon, { progress: skill.current.progress, state: skill.current.state, level: skill.current.level, type: \"skill\" }, void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.topBar }, { children: [_jsxs(\"div\", __assign({ className: classes.detail }, { children: [_jsxs(\"div\", { children: [_jsx(NewUpdatedLabel, { createdDate: skill.contentCreated, updatedDate: skill.contentUpdated }, void 0), _jsx(\"p\", __assign({ id: describedById, className: typo.subtitle2, style: { marginRight: 8 } }, { children: skill.name }), void 0)] }, void 0), !noProgress && !unavailable && (_jsx(\"span\", __assign({ className: clsx(typo.label, classes.label) }, { children: toStreakString(skill.current.state, skill.current.currentStreak) }), void 0))] }), void 0), !noProgress && !unavailable && (_jsx(SkillProgressBar, { currentState: skill.current.state, progress: skill.current.progress }, void 0))] }), void 0)] }, void 0));\n return (_jsx(_Fragment, { children: !noLink ? (_jsx(MuiLink, __assign({ ref: muiLinkRef, component: Link, to: page + \"/skill-details/\" + skill.id, className: classes.skill, tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : undefined }, { children: content }), void 0)) : (_jsx(\"div\", __assign({ className: classes.skill }, { children: content }), void 0)) }, void 0));\n};\nexport default Skill;\n//# sourceMappingURL=Skill.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nvar ComingSoonIcon = function (_a) {\n var large = _a.large;\n var size = !large ? 24 : 28;\n var id = useUUID('comingSoonIconTitleId');\n return (_jsx(\"div\", __assign({ style: { display: 'flex', height: size, minHeight: size, width: size, minWidth: size } }, { children: _jsxs(\"svg\", __assign({ style: { width: size, minWidth: size }, viewBox: \"0 0 498.94293 399.92615\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Coming Soon\" }), void 0), _jsxs(\"g\", __assign({ transform: \"translate(-0.60701532)\" }, { children: [_jsx(\"path\", { fill: Colors.iconDefault, d: \"m 200.8125,399.31689 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 96.9375,0.0208 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m -111.9375,-1.02083 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 129,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 13,-1 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 27.872445,370.25 c -1.243871,-1.58606 -1.208501,-1.62143 0.377555,-0.37756 0.9625,0.75485 1.75,1.54235 1.75,1.75 0,0.82304 -0.821186,0.29331 -2.127555,-1.37244 z M 474,368.5 c 1.29175,-1.375 2.57363,-2.5 2.84863,-2.5 0.275,0 -0.55688,1.125 -1.84863,2.5 -1.29175,1.375 -2.57363,2.5 -2.84863,2.5 -0.275,0 0.55688,-1.125 1.84863,-2.5 z M 22.404988,364.75 20.5,362.5 l 2.25,1.90499 C 24.864445,366.19521 25.455241,367 24.654988,367 c -0.189757,0 -1.202257,-1.0125 -2.25,-2.25 z m 23.032103,-27 L 42.5,334.5 l 3.25,2.93709 C 48.779455,340.17487 49.459652,341 48.687091,341 c -0.1721,0 -1.6346,-1.4625 -3.25,-3.25 z M 457,340.62244 c 0,-0.20765 0.7875,-0.99515 1.75,-1.75 1.58606,-1.24387 1.62143,-1.2085 0.37756,0.37756 C 457.82119,340.91575 457,341.44548 457,340.62244 Z m -132.1875,-3.30555 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -135,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 123,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 204.75,335.33772 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m 93.0625,-0.0208 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 19.404988,332.75 17.5,330.5 l 2.25,1.90499 C 21.864445,334.19521 22.455241,335 21.654988,335 c -0.189757,0 -1.202257,-1.0125 -2.25,-2.25 z m 206.864042,1.55701 c 0.97297,-0.25354 2.32297,-0.23687 3,0.0371 0.67703,0.27393 -0.11903,0.48137 -1.76903,0.46099 -1.65,-0.0204 -2.20394,-0.2445 -1.23097,-0.49804 z m 48,0 c 0.97297,-0.25354 2.32297,-0.23687 3,0.0371 0.67703,0.27393 -0.11903,0.48137 -1.76903,0.46099 -1.65,-0.0204 -2.20394,-0.2445 -1.23097,-0.49804 z M 87.078947,331.41667 c 0.04798,-1.16495 0.284941,-1.4019 0.604167,-0.60417 0.288871,0.72187 0.253344,1.58438 -0.07895,1.91667 -0.332292,0.33229 -0.568641,-0.25834 -0.52522,-1.3125 z M 32.404988,323.75 30.5,321.5 l 2.25,1.90499 C 34.864445,325.19521 35.455241,326 34.654988,326 c -0.189757,0 -1.202257,-1.0125 -2.25,-2.25 z M 170.8125,322.31689 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 13,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 133,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -119,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 20.9375,-0.97917 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m 67,0 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z M 22.404988,312.75 20.5,310.5 l 2.25,1.90499 C 24.864445,314.19521 25.455241,315 24.654988,315 c -0.189757,0 -1.202257,-1.0125 -2.25,-2.25 z M 485.43007,282 c 0,-12.925 0.14251,-18.2125 0.3167,-11.75 0.17418,6.4625 0.17418,17.0375 0,23.5 -0.17419,6.4625 -0.3167,1.175 -0.3167,-11.75 z M 13.427512,281 c 0,-12.375 0.143548,-17.4375 0.318995,-11.25 0.175447,6.1875 0.175447,16.3125 0,22.5 -0.175447,6.1875 -0.318995,1.125 -0.318995,-11.25 z M 467.15789,232 c 0,-1.375 0.22698,-1.9375 0.50439,-1.25 0.27741,0.6875 0.27741,1.8125 0,2.5 -0.27741,0.6875 -0.50439,0.125 -0.50439,-1.25 z M 30.078947,231.41667 c 0.04798,-1.16495 0.284941,-1.4019 0.604167,-0.60417 0.288871,0.72187 0.253344,1.58437 -0.07895,1.91667 -0.332292,0.33229 -0.568641,-0.25834 -0.52522,-1.3125 z M 172.87244,128.25 c -1.24387,-1.58606 -1.2085,-1.62143 0.37756,-0.37756 0.9625,0.75485 1.75,1.54235 1.75,1.75 0,0.82304 -0.82119,0.29331 -2.12756,-1.37244 z M 94,88.5 C 95.291745,87.125 96.573628,86 96.848628,86 97.123628,86 96.291745,87.125 95,88.5 93.708255,89.875 92.426372,91 92.151372,91 91.876372,91 92.708255,89.875 94,88.5 Z m 71.32814,-13 c 0.004,-3.85 0.18518,-5.302463 0.40166,-3.227696 0.21647,2.074768 0.21284,5.224768 -0.008,7 -0.22098,1.775233 -0.3981,0.0777 -0.39366,-3.772304 z m 168,-3 c 0.004,-3.85 0.18518,-5.302463 0.40166,-3.227696 0.21647,2.074768 0.21284,5.224768 -0.008,7 -0.22098,1.775233 -0.3981,0.0777 -0.39366,-3.772304 z\" }, void 0), _jsx(\"path\", { fill: Colors.iconDefault, d: \"m 292.25,399.31067 c 0.9625,-0.25152 2.5375,-0.25152 3.5,0 0.9625,0.25153 0.175,0.45733 -1.75,0.45733 -1.925,0 -2.7125,-0.2058 -1.75,-0.45733 z m -83.4375,-63.99378 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 86,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 231.75,334.29427 c 1.2375,-0.23836 3.2625,-0.23836 4.5,0 1.2375,0.23835 0.225,0.43337 -2.25,0.43337 -2.475,0 -3.4875,-0.19502 -2.25,-0.43337 z m 35,0 c 1.2375,-0.23836 3.2625,-0.23836 4.5,0 1.2375,0.23835 0.225,0.43337 -2.25,0.43337 -2.475,0 -3.4875,-0.19502 -2.25,-0.43337 z m -52,-14.95655 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m 252.23173,-80.63603 0.48173,-5.20169 0.33241,4.38586 c 0.18282,2.41223 -0.034,4.75299 -0.48173,5.20169 -0.44778,0.4487 -0.59736,-1.52494 -0.33241,-4.38586 z M 244.28651,164.25992 c 3.18258,-0.19905 8.13258,-0.1972 11,0.004 2.86742,0.20131 0.26349,0.36417 -5.78651,0.36191 -6.05,-0.002 -8.39607,-0.16696 -5.21349,-0.36601 z m 71.79244,-55.84325 c 0.048,-1.16495 0.28494,-1.4019 0.60416,-0.60417 0.28887,0.72187 0.25335,1.58437 -0.0789,1.91667 -0.33229,0.33229 -0.56864,-0.25834 -0.52522,-1.3125 z M 165.28601,86.5 c 0.008,-2.75 0.20172,-3.756313 0.43157,-2.23625 0.22986,1.520062 0.22371,3.770062 -0.0136,5 C 165.46657,90.493687 165.27851,89.25 165.28601,86.5 Z m 168,-3 c 0.008,-2.75 0.20172,-3.756313 0.43157,-2.23625 0.22986,1.520062 0.22371,3.770062 -0.0136,5 C 333.46657,87.493687 333.27851,86.25 333.28601,83.5 Z M 316.3605,36 c 0,-5.225 0.16854,-7.3625 0.37454,-4.75 0.206,2.6125 0.206,6.8875 0,9.5 -0.206,2.6125 -0.37454,0.475 -0.37454,-4.75 z M 182.34281,31.5 c 0.004,-4.4 0.17944,-6.075605 0.39069,-3.723567 0.21124,2.352038 0.20827,5.952038 -0.007,8 C 182.51202,37.824395 182.33918,35.9 182.34281,31.5 Z\" }, void 0), _jsx(\"path\", { fill: Colors.iconDefault, d: \"m 206.26903,399.30701 c 0.97297,-0.25354 2.32297,-0.23687 3,0.0371 0.67703,0.27393 -0.11903,0.48137 -1.76903,0.46099 -1.65,-0.0204 -2.20394,-0.2445 -1.23097,-0.49804 z m 79.49263,-0.0143 c 1.24391,-0.23919 3.04391,-0.23011 4,0.0202 0.95609,0.25029 -0.0617,0.446 -2.26166,0.4349 -2.2,-0.0111 -2.98225,-0.21589 -1.73834,-0.45508 z m -94.94916,-0.97585 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 119,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -145,-2 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 35.872445,350.25 c -1.243871,-1.58606 -1.208501,-1.62143 0.377555,-0.37756 0.9625,0.75485 1.75,1.54235 1.75,1.75 0,0.82304 -0.821186,0.29331 -2.127555,-1.37244 z m -8,-8 c -1.243871,-1.58606 -1.208501,-1.62143 0.377555,-0.37756 0.9625,0.75485 1.75,1.54235 1.75,1.75 0,0.82304 -0.821186,0.29331 -2.127555,-1.37244 z M 180.8125,337.31689 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 140,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -126,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 113,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 211.75,335.33772 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m 79,0 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m -46.54375,-1.07827 c 3.68844,-0.19186 9.98844,-0.19314 14,-0.003 4.01156,0.1903 0.99375,0.34727 -6.70625,0.34883 -7.7,0.002 -10.98219,-0.15414 -7.29375,-0.34599 z m 175.8727,-3.84278 c 0.048,-1.16495 0.28494,-1.4019 0.60416,-0.60417 0.28887,0.72187 0.25335,1.58438 -0.0789,1.91667 -0.33229,0.33229 -0.56864,-0.25834 -0.52522,-1.3125 z M 12.437091,325.75 9.5,322.5 l 3.25,2.93709 C 15.779455,328.17487 16.459652,329 15.687091,329 c -0.1721,0 -1.6346,-1.4625 -3.25,-3.25 z M 178.8125,321.31689 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 142,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -128,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 115,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -96,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 79.9375,0.0208 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m -42.5,-1.07927 c 3.7125,-0.19241 9.7875,-0.19241 13.5,0 3.7125,0.19241 0.675,0.34983 -6.75,0.34983 -7.425,0 -10.4625,-0.15742 -6.75,-0.34983 z M 30.078947,235.41667 c 0.04798,-1.16495 0.284941,-1.4019 0.604167,-0.60417 0.288871,0.72187 0.253344,1.58437 -0.07895,1.91667 -0.332292,0.33229 -0.568641,-0.25834 -0.52522,-1.3125 z M 316.29966,102 c 0,-3.025 0.18747,-4.2625 0.41659,-2.75 0.22913,1.5125 0.22913,3.9875 0,5.5 -0.22912,1.5125 -0.41659,0.275 -0.41659,-2.75 z m -151,-6 c 0,-3.025 0.18747,-4.2625 0.41659,-2.75 0.22913,1.5125 0.22913,3.9875 0,5.5 -0.22912,1.5125 -0.41659,0.275 -0.41659,-2.75 z m 168.01021,-2.5 c 0.006,-3.3 0.1923,-4.529441 0.41486,-2.732091 0.22256,1.79735 0.21797,4.49735 -0.0102,6 C 333.48635,98.270559 333.30426,96.8 333.30987,93.5 Z m -16.88373,-27 c 7.5e-4,-12.1 0.14515,-16.912559 0.32089,-10.694576 0.17573,6.217983 0.17511,16.117983 -10e-4,22 C 316.56916,83.687441 316.42538,78.6 316.42614,66.5 Z M 182.39739,53 c 0,-7.975 0.1553,-11.2375 0.34512,-7.25 0.18981,3.9875 0.18981,10.5125 0,14.5 -0.18982,3.9875 -0.34512,0.725 -0.34512,-7.25 z M 305.92431,9.25 303.5,6.5 l 2.75,2.424314 c 1.5125,1.333373 2.75,2.570873 2.75,2.75 0,0.784274 -0.8098,0.145975 -3.07569,-2.424314 z\" }, void 0), _jsx(\"path\", { fill: Colors.iconDefault, d: \"m 212.75,399.2766 c 1.7875,-0.22182 4.7125,-0.22182 6.5,0 1.7875,0.22183 0.325,0.40333 -3.25,0.40333 -3.575,0 -5.0375,-0.1815 -3.25,-0.40333 z m 53,-0.017 c 3.4375,-0.19527 9.0625,-0.19527 12.5,0 3.4375,0.19527 0.625,0.35504 -6.25,0.35504 -6.875,0 -9.6875,-0.15977 -6.25,-0.35504 z m -72,-0.92188 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m 113.0625,-0.0208 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -127,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 141,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -164,-2 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 187,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 476,365.62244 c 0,-0.20765 0.7875,-0.99515 1.75,-1.75 1.58606,-1.24387 1.62143,-1.2085 0.37756,0.37756 C 476.82119,365.91575 476,366.44548 476,365.62244 Z M 19.872445,361.25 c -1.243871,-1.58606 -1.208501,-1.62143 0.377555,-0.37756 0.9625,0.75485 1.75,1.54235 1.75,1.75 0,0.82304 -0.821186,0.29331 -2.127555,-1.37244 z m 30.889214,-3.95726 c 1.243913,-0.23919 3.043913,-0.23011 4,0.0202 0.956088,0.25029 -0.06166,0.446 -2.261659,0.4349 -2.2,-0.0111 -2.982253,-0.21589 -1.738341,-0.45508 z m 402.050841,0.0242 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 473,346.62244 c 0,-0.20765 0.7875,-0.99515 1.75,-1.75 1.58606,-1.24387 1.62143,-1.2085 0.37756,0.37756 C 473.82119,346.91575 473,347.44548 473,346.62244 Z M 23.924314,338.25 21.5,335.5 l 2.75,2.42431 c 1.5125,1.33338 2.75,2.57088 2.75,2.75 0,0.78428 -0.809799,0.14598 -3.075686,-2.42431 z M 183.8125,337.31689 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 14,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 107,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 215.75,335.33772 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m 71,0 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z M 40.924314,332.25 38.5,329.5 l 2.75,2.42431 C 43.820289,334.1902 44.458588,335 43.674314,335 c -0.179127,0 -1.416627,-1.2375 -2.75,-2.75 z M 4,327.62244 c 0,-0.20765 0.7875,-0.99515 1.75,-1.75 1.5860556,-1.24387 1.6214259,-1.2085 0.3775553,0.37756 C 4.8211855,327.91575 4,328.44548 4,327.62244 Z m 160.8125,-5.30555 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z M 29.404988,319.75 27.5,317.5 l 2.25,1.90499 C 31.864445,321.19521 32.455241,322 31.654988,322 c -0.189757,0 -1.202257,-1.0125 -2.25,-2.25 z m 146.407512,1.56689 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 14,-1 c 0.72187,-0.28887 1.58437,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m 121,0 c 0.72187,-0.28887 1.58438,-0.25335 1.91667,0.0789 0.33229,0.33229 -0.25834,0.56864 -1.3125,0.52522 -1.16495,-0.048 -1.4019,-0.28494 -0.60417,-0.60416 z m -103.54347,-1.00988 c 0.97297,-0.25354 2.32297,-0.23687 3,0.0371 0.67703,0.27393 -0.11903,0.48137 -1.76903,0.46099 -1.65,-0.0204 -2.20394,-0.2445 -1.23097,-0.49804 z m 88.48097,0.0307 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z m -62,-1.06112 c 1.7875,-0.22182 4.7125,-0.22182 6.5,0 1.7875,0.22183 0.325,0.40333 -3.25,0.40333 -3.575,0 -5.0375,-0.1815 -3.25,-0.40333 z m 37.5,0.007 c 1.5125,-0.22913 3.9875,-0.22913 5.5,0 1.5125,0.22912 0.275,0.41659 -2.75,0.41659 -3.025,0 -4.2625,-0.18747 -2.75,-0.41659 z M 19.404988,308.75 17.5,306.5 l 2.25,1.90499 C 21.864445,310.19521 22.455241,311 21.654988,311 c -0.189757,0 -1.202257,-1.0125 -2.25,-2.25 z M 426,283.62244 c 0,-0.20765 0.7875,-0.99515 1.75,-1.75 1.58606,-1.24387 1.62143,-1.2085 0.37756,0.37756 C 426.82119,283.91575 426,284.44548 426,283.62244 Z M 31.078947,226.41667 c 0.04798,-1.16495 0.284941,-1.4019 0.604167,-0.60417 0.288871,0.72187 0.253344,1.58437 -0.07895,1.91667 -0.332292,0.33229 -0.568641,-0.25834 -0.52522,-1.3125 z M 248.75,148.33772 c 0.6875,-0.27741 1.8125,-0.27741 2.5,0 0.6875,0.27741 0.125,0.50439 -1.25,0.50439 -1.375,0 -1.9375,-0.22698 -1.25,-0.50439 z M 186.87244,118.25 c -1.24387,-1.58606 -1.2085,-1.62143 0.37756,-0.37756 1.66575,1.30637 2.19548,2.12756 1.37244,2.12756 -0.20765,0 -0.99515,-0.7875 -1.75,-1.75 z M 165.232,104 c 0,-1.925 0.2058,-2.7125 0.45733,-1.75 0.25152,0.9625 0.25152,2.5375 0,3.5 -0.25153,0.9625 -0.45733,0.175 -0.45733,-1.75 z m 168,-2 c 0,-1.925 0.2058,-2.7125 0.45733,-1.75 0.25152,0.9625 0.25152,2.5375 0,3.5 -0.25153,0.9625 -0.45733,0.175 -0.45733,-1.75 z M 182.40479,82.5 c 0.001,-8.8 0.15425,-12.266133 0.33996,-7.702518 0.18572,4.563614 0.18468,11.763614 -0.002,16 C 182.55547,95.033867 182.40352,91.3 182.40479,82.5 Z M 87,96.687091 c 0,-0.1721 1.4625,-1.6346 3.25,-3.25 L 93.5,90.5 90.562909,93.75 C 87.825128,96.779455 87,97.459652 87,96.687091 Z M 316.25218,93.5 c 0.0111,-2.2 0.21589,-2.982253 0.45508,-1.738341 0.23919,1.243913 0.23011,3.043913 -0.0202,4 -0.25029,0.956088 -0.446,-0.06166 -0.4349,-2.261659 z m 92.15281,0.25 -1.90499,-2.25 2.25,1.904988 C 410.86444,95.195206 411.45524,96 410.65499,96 c -0.18976,0 -1.20226,-1.0125 -2.25,-2.25 z m -7.95204,-8 -3.95295,-4.25 4.25,3.952948 c 2.3375,2.174121 4.25,4.086621 4.25,4.25 0,0.756577 -0.87085,-4.9e-4 -4.54705,-3.952948 z M 100,83.5 c 1.29175,-1.375 2.57363,-2.5 2.84863,-2.5 0.275,0 -0.55688,1.125 -1.84863,2.5 -1.291745,1.375 -2.573628,2.5 -2.848628,2.5 -0.275,0 0.556883,-1.125 1.848628,-2.5 z m 63.84651,-36.500622 c -0.19058,-2.750342 -0.009,-5.000342 0.40349,-5 C 164.6625,41.99972 165,44.25 165,47 c 0,6.4514 -0.70643,6.451019 -1.15349,-6.22e-4 z M 334.232,45 c 0,-1.925 0.2058,-2.7125 0.45733,-1.75 0.25152,0.9625 0.25152,2.5375 0,3.5 C 334.4378,47.7125 334.232,46.925 334.232,45 Z\" }, void 0), _jsx(\"path\", { fill: Colors.iconDefault, d: \"M 213.5,399.36007 C 183.21201,398.20279 133.90109,393.3745 102.5,388.49149 76.838019,384.50093 41.457372,377.29591 36.282237,375.0067 30.77478,372.57049 21.638342,363.36325 10.391992,348.91581 -0.67314691,334.70117 -0.71272906,334.61168 2.3284436,330.68566 3.6856654,328.93355 5.81796,326.42477 7.0668761,325.11061 l 2.2707566,-2.38939 15.0811833,15.58336 c 8.294651,8.57085 16.405972,16.39253 18.025158,17.3815 4.747387,2.89963 15.286405,2.16274 36.829531,-2.57513 C 131.08342,341.71667 179.69531,336.29865 239,335.30869 c 62.50648,-1.04341 119.26982,4.18062 182.5,16.79578 13.75,2.74329 27.7,5.03264 31,5.08744 10.83747,0.18 15.39023,-3.01788 29.55271,-20.75793 l 9.1043,-11.40414 2.91208,1.50589 c 1.60164,0.82824 3.63186,2.60442 4.51159,3.94706 2.38794,3.64445 0.67612,7.40344 -8.6603,19.01721 -11.55619,14.37499 -18.91867,21.94832 -23.71703,24.39626 -14.37537,7.33377 -96.54425,20.26407 -152.70335,24.0298 -15.61656,1.04716 -84.33437,2.03258 -100,1.43401 z m 223.11916,-61.19494 -15.88085,-3.59923 0.65411,-8.53295 c 0.35975,-4.69312 1.54541,-15.95795 2.63479,-25.03295 1.91231,-15.93034 2.08171,-16.58631 4.9066,-19 1.60925,-1.375 13.19982,-7.61352 25.75683,-13.86337 l 22.83093,-11.36337 3.73921,1.56234 3.73922,1.56235 v 22.24068 22.24068 l -11.38874,15.06035 c -12.15867,16.07849 -17.9728,22.63237 -19.9094,22.44252 -0.66102,-0.0648 -8.34824,-1.73748 -17.0827,-3.71705 z M 31.742535,321.75 14.078602,302.5 14.039301,281.26603 14,260.03206 l 5.739614,-2.90228 5.739615,-2.90228 15.010385,7.48369 c 23.847558,11.88961 37.657108,19.58172 39.075926,21.76583 1.114551,1.71573 4.553613,23.26072 6.969427,43.66198 l 0.667742,5.639 -3.351354,1.05439 C 79.701345,335.13805 52.650666,341 50.775529,341 50.022545,341 41.457698,332.3375 31.742535,321.75 Z M 392.5,329.9315 c -17.30751,-3.6281 -69.14223,-9.08114 -105,-11.04605 -44.98039,-2.4648 -116.93434,1.35659 -164.79989,8.75234 -9.23994,1.42767 -17.01925,2.3764 -17.28736,2.10829 -0.26811,-0.26811 -1.85443,-11.23316 -3.52515,-24.36678 C 98.373365,277.75368 96.87912,273.11499 89.837072,267.96997 87.451682,266.22717 73.35,258.72092 58.5,251.28941 43.65,243.8579 31.307206,237.59733 31.07157,237.37702 c -0.235637,-0.2203 0.126418,-5.90775 0.804567,-12.63878 C 38.794476,156.06962 73.837535,97.51342 130,60.775361 c 12.28091,-8.033421 32.53971,-18.568987 33.62306,-17.485635 0.41315,0.413152 1.0412,16.829481 1.39565,36.48073 0.61339,34.006054 0.75166,35.970734 2.8665,40.729544 4.45995,10.0358 10.31854,14.10851 45.8571,31.87841 L 238.98462,165 H 249.5 260.01538 l 25.24231,-12.62159 c 35.53375,-17.76749 41.38979,-21.83796 45.86236,-31.87841 2.11547,-4.74902 2.2448,-6.53096 2.57643,-35.5 0.19203,-16.775 0.60148,-33.329126 0.90989,-36.786946 l 0.56073,-6.286945 12.55676,6.554151 c 43.84125,22.883466 75.33866,54.51479 96.20574,96.61477 13.53734,27.31201 23.08033,65.21304 23.06761,91.61556 l -0.003,5.78941 -25.36556,12.71804 c -27.02035,13.54774 -30.59136,16.12922 -32.53397,23.51883 -1.09446,4.16329 -5.61274,34.91623 -6.68688,45.51313 -0.76446,7.54181 -0.8365,7.58312 -9.90801,5.6815 z M 233.94508,142.68395 C 216.98347,134.87881 190.85546,121.17903 188.15499,118.6747 182.48996,113.42112 182.57331,114.23945 182.89212,67 l 0.29358,-43.5 3.41096,-5.637076 C 190.68922,11.099393 196.159,5.9665987 202.93085,2.5350399 L 207.93351,0 h 41.64327 41.64327 l 5.89207,3.1404418 c 6.90623,3.6809843 12.74077,9.6623312 16.32532,16.7361012 L 316,24.933513 v 43.082903 c 0,48.301964 0.22394,46.703244 -7.2513,51.767874 C 295.97379,128.43958 254.75808,148 249.29547,148 c -2.47217,0 -7.83053,-1.85567 -15.35039,-5.31605 z\" }, void 0)] }), void 0)] }), void 0) }), void 0));\n};\nexport default ComingSoonIcon;\n//# sourceMappingURL=ComingSoonIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles, Popover } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n popover: {\n width: 312,\n boxShadow: '0 24px 32px 2px rgba(0, 0, 0, 0.08), 0 12.5px 128px 4px rgba(0, 0, 0, 0.08)',\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n textAlign: 'center',\n overflow: 'visible',\n },\n arrow: {\n width: 0,\n height: 0,\n borderLeft: '10px solid transparent',\n borderRight: '10px solid transparent',\n borderBottom: '10px solid white',\n position: 'absolute',\n top: -10,\n left: 242,\n },\n title: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 600,\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.15,\n textAlign: 'center',\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 16,\n },\n text: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n textAlign: 'center',\n color: 'rgba(0, 0, 0, 0.88)',\n },\n});\nvar HardhatPopover = function (_a) {\n var open = _a.open, toggle = _a.toggle, anchorEl = _a.anchorEl, large = _a.large, skillOrOutcome = _a.skillOrOutcome;\n var classes = useStyles();\n return (_jsxs(Popover, __assign({ open: open, anchorEl: anchorEl, onClose: toggle, anchorOrigin: {\n vertical: large ? 82 : 46,\n horizontal: large ? -60 : -78,\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n }, classes: {\n paper: classes.popover,\n } }, { children: [_jsx(\"div\", { className: classes.arrow }, void 0), _jsx(\"div\", __assign({ className: classes.title }, { children: isOutcome(skillOrOutcome) ? 'This Outcome is under construction' : 'This Skill is under construction' }), void 0), _jsx(\"div\", __assign({ className: classes.text }, { children: isOutcome(skillOrOutcome)\n ? 'Get a sneak peek of what this Outcome has to offer by watching its overview video and seeing what Skills are included. Check back to see when it’s ready to be assigned '\n : 'Get a sneak peek of what this Skill has to offer by watching its overview video. Check back to see when it’s ready to be assigned ' }), void 0)] }), void 0));\n};\nexport default HardhatPopover;\n//# sourceMappingURL=HardhatPopover.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles, Popover } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n popover: {\n width: 312,\n boxShadow: '0 24px 32px 2px rgba(0, 0, 0, 0.08), 0 12.5px 128px 4px rgba(0, 0, 0, 0.08)',\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n textAlign: 'center',\n overflow: 'visible',\n },\n arrow: {\n width: 0,\n height: 0,\n borderLeft: '10px solid transparent',\n borderRight: '10px solid transparent',\n borderBottom: '10px solid white',\n position: 'absolute',\n top: -10,\n left: 242,\n },\n title: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 600,\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.15,\n textAlign: 'center',\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 16,\n },\n text: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n textAlign: 'center',\n color: 'rgba(0, 0, 0, 0.88)',\n },\n});\nvar EduPopover = function (_a) {\n var open = _a.open, toggle = _a.toggle, anchorEl = _a.anchorEl, large = _a.large, skillOrOutcome = _a.skillOrOutcome;\n var classes = useStyles();\n return (_jsxs(Popover, __assign({ open: open, anchorEl: anchorEl, onClose: toggle, anchorOrigin: {\n vertical: large ? 82 : 46,\n horizontal: large ? -60 : -78,\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n }, classes: {\n paper: classes.popover,\n } }, { children: [_jsx(\"div\", { className: classes.arrow }, void 0), _jsxs(\"div\", __assign({ className: classes.title }, { children: [' ', isOutcome(skillOrOutcome) ? 'This Outcome is unavailable' : 'This Skill is unavailable'] }), void 0), _jsx(\"div\", __assign({ className: classes.text }, { children: isOutcome(skillOrOutcome)\n ? 'To access this Outcome, you need a specific Microsoft 365 license. Reach out to your Nulia Works admin to find out more. '\n : 'To access this Skill, you need a specific Microsoft 365 license. Reach out to your Nulia Works admin to find out more. ' }), void 0)] }), void 0));\n};\nexport default EduPopover;\n//# sourceMappingURL=EduPopover.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles, Popover } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n popover: {\n width: 312,\n boxShadow: '0 24px 32px 2px rgba(0, 0, 0, 0.08), 0 12.5px 128px 4px rgba(0, 0, 0, 0.08)',\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n textAlign: 'center',\n overflow: 'visible',\n },\n arrow: {\n width: 0,\n height: 0,\n borderLeft: '10px solid transparent',\n borderRight: '10px solid transparent',\n borderBottom: '10px solid white',\n position: 'absolute',\n top: -10,\n left: 242,\n },\n title: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 600,\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.15,\n textAlign: 'center',\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 16,\n },\n text: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n textAlign: 'center',\n color: 'rgba(0, 0, 0, 0.88)',\n },\n});\nvar CollectorPopover = function (_a) {\n var open = _a.open, toggle = _a.toggle, anchorEl = _a.anchorEl, large = _a.large, skillOrOutcome = _a.skillOrOutcome;\n var classes = useStyles();\n return (_jsxs(Popover, __assign({ open: open, anchorEl: anchorEl, onClose: toggle, anchorOrigin: {\n vertical: large ? 82 : 46,\n horizontal: large ? -60 : -78,\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n }, classes: {\n paper: classes.popover,\n } }, { children: [_jsx(\"div\", { className: classes.arrow }, void 0), _jsx(\"div\", __assign({ className: classes.title }, { children: isOutcome(skillOrOutcome) ? 'This Outcome is unavailable' : 'This Skill is unavailable' }), void 0), _jsx(\"div\", __assign({ className: classes.text }, { children: isOutcome(skillOrOutcome)\n ? 'To access this Outcome, you must be working on the most-current version of Nulia Works. Reach out to your Nulia Works admin to find out more.'\n : 'To access this Skill, you must be working on the most-current version of Nulia Works. Reach out to your Nulia Works admin to find out more.' }), void 0)] }), void 0));\n};\nexport default CollectorPopover;\n//# sourceMappingURL=CollectorPopover.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { makeStyles, Popover } from '@material-ui/core';\nimport { useGetUser } from '../../hooks/useGetUser';\nimport { UserContext } from '../../contexts/UserContext';\nimport { UpgradeRequestType } from '../../types/enums';\nimport Button from '../buttons/Button';\nimport { Colors } from '../../utils/colors';\nvar useStyles = makeStyles({\n popover: {\n width: 312,\n boxShadow: '0 24px 32px 2px rgba(0, 0, 0, 0.08), 0 12.5px 128px 4px rgba(0, 0, 0, 0.08)',\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n textAlign: 'center',\n overflow: 'visible',\n },\n arrow: {\n width: 0,\n height: 0,\n borderLeft: '10px solid transparent',\n borderRight: '10px solid transparent',\n borderBottom: '10px solid white',\n position: 'absolute',\n top: -10,\n left: 242,\n },\n title: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 600,\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.15,\n textAlign: 'center',\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 16,\n },\n text: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n textAlign: 'center',\n color: 'rgba(0, 0, 0, 0.88)',\n },\n});\nvar StarterPopover = function (_a) {\n var open = _a.open, toggle = _a.toggle, anchorEl = _a.anchorEl, large = _a.large;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var getUser = useGetUser();\n var requestUpgrade = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, getUser()];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n return (_jsx(_Fragment, { children: (user === null || user === void 0 ? void 0 : user.upgradeRequest) !== UpgradeRequestType.Requested ? (_jsxs(Popover, __assign({ open: open, anchorEl: anchorEl, onClose: toggle, anchorOrigin: {\n vertical: large ? 82 : 46,\n horizontal: large ? -60 : -78,\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n }, classes: {\n paper: classes.popover,\n } }, { children: [_jsx(\"div\", { className: classes.arrow }, void 0), _jsx(\"div\", __assign({ className: classes.title }, { children: \"There's more waiting for you in Nulia Works Complete\" }), void 0), _jsx(\"div\", __assign({ className: classes.text }, { children: \"Continue to move closer to your goals & unlock more Outcomes and badges by adding your voice to request Nulia Works Complete.\" }), void 0), _jsx(Button, __assign({ onClick: requestUpgrade, style: { width: 219, marginTop: 24 } }, { children: \"Request Complete Access\" }), void 0)] }), void 0)) : (_jsxs(Popover, __assign({ open: open, anchorEl: anchorEl, onClose: toggle, anchorOrigin: {\n vertical: large ? 82 : 46,\n horizontal: large ? -60 : -78,\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n }, classes: {\n paper: classes.popover,\n } }, { children: [_jsx(\"div\", { className: classes.arrow }, void 0), _jsx(\"div\", __assign({ className: classes.title }, { children: \"Your Request for Nulia Complete is Pending\" }), void 0), _jsx(\"div\", __assign({ className: classes.text }, { children: \"Your request for Nulia Works Complete has been submitted.\" }), void 0)] }), void 0)) }, void 0));\n};\nexport default StarterPopover;\n//# sourceMappingURL=StarterPopover.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useState } from 'react';\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nimport ComingSoonIcon from '../icons/ComingSoonIcon';\nimport HardhatPopover from '../popovers/HardhatPopover';\nimport EduPopover from '../popovers/EduPopover';\nimport CollectorPopover from '../popovers/CollectorPopover';\nimport { Colors } from '../../utils/colors';\nimport { Tooltip } from '../Tooltip';\nimport { CompetenceState } from '../../types/enums';\nimport StarterPopover from '../popovers/StarterPopover';\nimport { Lock } from 'react-feather';\nimport { isOutcome } from '../../utils/isOutcome';\nvar useStyles = makeStyles({\n lockedButton: {\n width: 36,\n height: 36,\n minWidth: 36,\n minHeight: 36,\n backgroundColor: 'rgba(0, 0, 0, 0.02)',\n borderRadius: '50%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n position: 'relative',\n border: 'none',\n color: Colors.textSecondary,\n },\n largeButton: {\n width: 72,\n height: 72,\n minWidth: 72,\n minHeight: 72,\n },\n popover: {\n width: 312,\n boxShadow: '0 24px 32px 2px rgba(0, 0, 0, 0.08), 0 12.5px 128px 4px rgba(0, 0, 0, 0.08)',\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n textAlign: 'center',\n overflow: 'visible',\n },\n arrowContainer: {\n background: 'transparent',\n boxShadow: 'none',\n borderRadius: 0,\n },\n arrow: {\n width: 0,\n height: 0,\n borderLeft: '10px solid transparent',\n borderRight: '10px solid transparent',\n borderBottom: '10px solid white',\n position: 'absolute',\n top: -10,\n left: 242,\n },\n title: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n fontWeight: 600,\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.15,\n textAlign: 'center',\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 16,\n },\n text: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n textAlign: 'center',\n color: 'rgba(0, 0, 0, 0.88)',\n },\n dialogText: {\n fontFamily: 'Open Sans',\n fontSize: 16,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.5,\n color: 'rgba(0, 0, 0, 0.64)',\n },\n});\nvar UnavailableButton = function (_a) {\n var skillOrOutcome = _a.skillOrOutcome, large = _a.large;\n var classes = useStyles();\n var _b = __read(useState(false), 2), openPopover = _b[0], setOpenPopover = _b[1];\n var _c = __read(useState(null), 2), anchorEl = _c[0], setAnchorEl = _c[1];\n var toggleOpenPopover = function () { return setOpenPopover(!openPopover); };\n var onOpenPopover = function (event) {\n setAnchorEl(event.currentTarget);\n toggleOpenPopover();\n };\n return (_jsx(Tooltip, __assign({ title: skillOrOutcome.current.state === CompetenceState.LockedHardhat\n ? isOutcome(skillOrOutcome)\n ? 'This Outcome is under construction'\n : 'This Skill is under construction'\n : isOutcome(skillOrOutcome)\n ? 'This Outcome is unavailable'\n : 'This Skill is unavailable' }, { children: _jsxs(_Fragment, { children: [_jsx(\"button\", __assign({ className: clsx(classes.lockedButton, large && classes.largeButton), onClick: onOpenPopover }, { children: skillOrOutcome.current.state === CompetenceState.LockedHardhat ? (_jsx(ComingSoonIcon, { large: large }, void 0)) : skillOrOutcome.current.state === CompetenceState.LockedStarter ? (_jsx(Lock, {}, void 0)) : skillOrOutcome.current.state === CompetenceState.LockedEdu ? (_jsx(Lock, {}, void 0)) : skillOrOutcome.current.state === CompetenceState.LockedCollectorVersion ? (_jsx(Lock, {}, void 0)) : (_jsx(Lock, {}, void 0)) }), void 0), skillOrOutcome.current.state === CompetenceState.LockedHardhat ? (_jsx(HardhatPopover, { open: openPopover, anchorEl: anchorEl, toggle: toggleOpenPopover, large: large, skillOrOutcome: skillOrOutcome }, void 0)) : skillOrOutcome.current.state === CompetenceState.LockedStarter ? (_jsx(StarterPopover, { open: openPopover, anchorEl: anchorEl, toggle: toggleOpenPopover, large: large }, void 0)) : skillOrOutcome.current.state === CompetenceState.LockedEdu ? (_jsx(EduPopover, { open: openPopover, anchorEl: anchorEl, toggle: toggleOpenPopover, large: large, skillOrOutcome: skillOrOutcome }, void 0)) : skillOrOutcome.current.state === CompetenceState.LockedCollectorVersion ? (_jsx(CollectorPopover, { open: openPopover, anchorEl: anchorEl, toggle: toggleOpenPopover, large: large, skillOrOutcome: skillOrOutcome }, void 0)) : undefined] }, void 0) }), void 0));\n};\nexport default UnavailableButton;\n//# sourceMappingURL=UnavailableButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var OutcomesContext = createContext({});\nexport var OutcomesProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), outcomes = _b[0], setOutcomes = _b[1];\n var _c = __read(useState(undefined), 2), allOutcomes = _c[0], setAllOutcomes = _c[1];\n var _d = __read(useState(undefined), 2), recommendedOutcomes = _d[0], setRecommendedOutcomes = _d[1];\n var _e = __read(useState(undefined), 2), allSkills = _e[0], setAllSkills = _e[1];\n var _f = __read(useState(false), 2), deepLink = _f[0], setDeepLink = _f[1];\n var _g = __read(useState(undefined), 2), badge = _g[0], setBadge = _g[1];\n var _h = __read(useState({\n mythings: false,\n notmythings: false,\n all: false,\n sharepoint: false,\n onedrive: false,\n yammer: false,\n onenote: false,\n word: false,\n excel: false,\n powerpoint: false,\n teams: false,\n outlook: false,\n office365: false,\n delve: false,\n planner: false,\n todo: false,\n forms: false,\n powerautomate: false,\n bookings: false,\n edge: false,\n collaboration: false,\n communication: false,\n datamanagementandautomation: false,\n fundamentals: false,\n leadership: false,\n timeandtaskmanagement: false,\n education: false,\n intune: false,\n myapps: false,\n }), 2), filtersOutcomes = _h[0], setFiltersOutcomes = _h[1];\n var outcomesContext = {\n outcomes: outcomes,\n setOutcomes: setOutcomes,\n allOutcomes: allOutcomes,\n setAllOutcomes: setAllOutcomes,\n recommendedOutcomes: recommendedOutcomes,\n setRecommendedOutcomes: setRecommendedOutcomes,\n allSkills: allSkills,\n setAllSkills: setAllSkills,\n deepLink: deepLink,\n setDeepLink: setDeepLink,\n badge: badge,\n setBadge: setBadge,\n filtersOutcomes: filtersOutcomes,\n setFiltersOutcomes: setFiltersOutcomes,\n };\n return _jsx(OutcomesContext.Provider, __assign({ value: outcomesContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=OutcomesContext.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { OutcomesContext } from '../contexts/OutcomesContext';\nimport { OutcomeService } from '../services/OutcomeService';\nimport { SkillService } from '../services/SkillService';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nexport var useGetOutcomesData = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var outcomesContext = useContext(OutcomesContext);\n var getUser = useGetUser();\n var getUserOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getUserOutcomes()];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n outcomesContext.setOutcomes(response);\n return [2];\n }\n });\n }); };\n var getAllOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getAllOutcomes()];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n outcomesContext.setAllOutcomes(response);\n return [2];\n }\n });\n }); };\n var getRecommendedOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getRecommendedOutcomes()];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n outcomesContext.setRecommendedOutcomes(response);\n return [2];\n }\n });\n }); };\n var getAllSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, allSkills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getAllSkills()];\n case 2:\n allSkills = _a.sent();\n if (!allSkills) {\n return [2];\n }\n outcomesContext.setAllSkills(allSkills);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser(), getUserOutcomes(), getAllOutcomes(), getRecommendedOutcomes(), getAllSkills()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetOutcomesData.js.map","export var replaceAll = function (str, search, replace) {\n var newStr = '';\n for (var i = 0; i < str.length; ++i) {\n if (str[i] === search) {\n newStr += replace;\n }\n else {\n newStr += str[i];\n }\n }\n return newStr;\n};\n//# sourceMappingURL=replaceAll.js.map","import { LicenseClass } from '../types/enums';\nexport var isStarterCustomer = function (licenseClass) {\n return licenseClass === LicenseClass.Starter || licenseClass === LicenseClass.StarterCompleteSync;\n};\n//# sourceMappingURL=isStarterCustomer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Divider, Paper, Select } from '@material-ui/core';\nimport InputBase from '@material-ui/core/InputBase';\nimport MenuItem from '@material-ui/core/MenuItem';\nimport { createStyles, makeStyles, withStyles } from '@material-ui/core/styles';\nimport { useContext, Fragment, useState, useEffect } from 'react';\nimport { UserContext } from '../contexts/UserContext';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport AddButton from './buttons/AddButton';\nimport RemoveButton from './buttons/RemoveButton';\nimport Outcome from './outcomes/Outcome';\nimport Skill from './skills/Skill';\nimport { pageTitleId } from '../contexts/HeaderContext';\nimport UnavailableButton from './buttons/UnavailableButton';\nimport { Level } from '../types/enums';\nimport { useGetOutcomesData } from '../hooks/useGetOutcomesData';\nimport { useGetSkillsData } from '../hooks/useGetSkillsData';\nimport { replaceAll } from '../utils/replaceAll';\nimport { isStarterCustomer } from '../utils/isStarterCustomer';\nimport { isUnavailable } from '../utils/isUnavailable';\nvar BootstrapInput = withStyles(function (theme) {\n return createStyles({\n input: {\n borderRadius: 4,\n position: 'relative',\n backgroundColor: Colors.background,\n fontSize: 16,\n padding: '10px 26px 10px 12px',\n transition: theme.transitions.create(['border-color', 'box-shadow']),\n fontFamily: 'Ubuntu',\n '&:focus': {\n borderRadius: 4,\n borderColor: Colors.purple,\n boxShadow: '0 0 0 0.2rem rgba(0,123,255,.25)',\n },\n },\n });\n})(InputBase);\nvar useStyles = makeStyles(function (theme) { return ({\n card: {\n background: function (props) {\n return \"linear-gradient(to right, \" + props.color + \" 0, \" + props.color + \" 8px, \" +\n (Colors.white + \" 8px, \" + Colors.white + \" 100%)\");\n },\n backgroundSize: 'cover',\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n borderRadius: 4,\n padding: 24,\n paddingTop: 0,\n },\n cards: {\n width: '100%',\n },\n titleRow: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n title: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n eachSkill: {\n width: '100%',\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n addRemoveToggle: {\n marginLeft: 25,\n },\n sort: {\n display: 'flex',\n alignItems: 'center',\n marginRight: 16,\n },\n}); });\nvar CardSkillsOrOutcomes = function (_a) {\n var title = _a.title, color = _a.color, cards = _a.cards, button = _a.button, sortOrder = _a.sortOrder, onChangeSort = _a.onChangeSort, isOutcome = _a.isOutcome, page = _a.page;\n var typo = useTypography();\n var user = useContext(UserContext).user;\n var getData = isOutcome ? useGetOutcomesData() : useGetSkillsData();\n var _b = __read(useState(-1), 2), selectedItem = _b[0], setSelectedItem = _b[1];\n var accept = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getData()];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n var classes = useStyles({ color: color });\n var ariaTextId = replaceAll(title, ' ', '-');\n var ariaNumSkillsId = cards.length + \"-\" + ariaTextId;\n var starter = isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass);\n var isAllSkillsOrOutcomes = button;\n var handleKeyDown = function (e) {\n if (selectedItem === -1) {\n setSelectedItem(0);\n }\n var keyDownName = e.key;\n if (keyDownName === 'ArrowDown') {\n e.preventDefault();\n setSelectedItem(function (currentItem) { return (selectedItem < cards.length - 1 ? currentItem + 1 : 0); });\n }\n else if (keyDownName === 'ArrowUp') {\n e.preventDefault();\n setSelectedItem(function (currentItem) { return (selectedItem > 0 ? currentItem - 1 : cards.length - 1); });\n }\n };\n var determineTabIndex = function (cardIndex) {\n return isAllSkillsOrOutcomes || (cardIndex === 0 && selectedItem === -1) ? 0 : cardIndex === selectedItem ? 0 : -1;\n };\n var tabEventListener = function (keyName) {\n if (keyName === 'Tab') {\n setSelectedItem(-1);\n }\n };\n useEffect(function () {\n addEventListener('keydown', function (event) { return tabEventListener(event.key); });\n return function () { return removeEventListener('keydown', function (event) { return tabEventListener(event.key); }); };\n }, []);\n return (_jsx(Paper, __assign({ component: \"section\", elevation: 1, \"aria-labelledby\": [ariaNumSkillsId, pageTitleId, ariaTextId].join(' '), className: classes.card, onKeyDown: function (e) {\n handleKeyDown(e);\n } }, { children: _jsxs(\"div\", __assign({ className: classes.cards }, { children: [_jsxs(\"div\", __assign({ className: classes.titleRow }, { children: [_jsxs(\"h2\", __assign({ \"aria-live\": \"polite\", \"aria-atomic\": \"true\", className: classes.title }, { children: [_jsx(\"span\", __assign({ id: ariaTextId, className: typo.subtitle1, style: { fontWeight: 600 } }, { children: title }), void 0), _jsxs(\"span\", __assign({ id: ariaNumSkillsId, className: typo.caption, style: { marginLeft: 8 } }, { children: [\"(\", cards.length, \")\"] }), void 0)] }), void 0), sortOrder && (_jsxs(\"div\", __assign({ className: classes.sort }, { children: [_jsx(\"label\", __assign({ id: \"sort-order-select-label\", className: typo.caption, style: { marginRight: 8 }, htmlFor: \"sort-order-select\" }, { children: \"Sort By:\" }), void 0), _jsxs(Select, __assign({ style: { width: 115 }, id: \"sort-order-select\", labelId: \"sort-order-select-label\", value: sortOrder, onChange: onChangeSort, input: _jsx(BootstrapInput, {}, void 0) }, { children: [_jsx(MenuItem, __assign({ value: \"name\" }, { children: \"Name\" }), void 0), _jsx(MenuItem, __assign({ value: \"newest\" }, { children: \"Newest\" }), void 0), _jsx(MenuItem, __assign({ value: \"progress\" }, { children: \"Progress\" }), void 0)] }), void 0)] }), void 0))] }), void 0), cards.map(function (card, index) { return (_jsx(Fragment, { children: _jsxs(\"div\", __assign({ className: classes.eachSkill }, { children: [_jsxs(\"div\", __assign({ style: { width: '100%' } }, { children: [isOutcome ? (_jsx(Outcome, { page: page, outcome: card, describedById: card.id.toString(), tabIndex: determineTabIndex(index), isAllSkillsOrOutcomes: isAllSkillsOrOutcomes, currentlySelected: selectedItem }, void 0)) : (_jsx(Skill, { page: page, skill: card, describedById: card.id.toString(), tabIndex: determineTabIndex(index), isAllSkillsOrOutcomes: isAllSkillsOrOutcomes, currentlySelected: selectedItem }, void 0)), index !== cards.length - 1 && _jsx(Divider, {}, void 0)] }), void 0), button && (_jsx(\"div\", __assign({ className: classes.addRemoveToggle }, { children: isUnavailable(card.current.state) ? (_jsx(UnavailableButton, { skillOrOutcome: card }, void 0)) : card.isAssigned ? (_jsx(RemoveButton, { user: user, skillOrOutcome: card, level: Level.None, recommended: false, onAccept: accept, describedById: card.id.toString(), starter: starter }, void 0)) : (_jsx(AddButton, { user: user, skillOrOutcome: card, level: Level.User, recommended: false, onAccept: accept, describedById: card.id.toString(), starter: starter }, void 0)) }), void 0))] }), void 0) }, card.id)); })] }), void 0) }), void 0));\n};\nexport default CardSkillsOrOutcomes;\n//# sourceMappingURL=CardSkillsOrOutcomes.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { Checkbox, FormControlLabel } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../../utils/colors';\nimport { CheckBoxOutlineBlank, CheckBox as CheckBoxIcon } from '@material-ui/icons';\nvar useStyles = makeStyles({\n root: {\n display: 'grid',\n gridAutoFlow: 'column',\n gridGap: 8,\n marginBottom: 8,\n justifyContent: 'left',\n marginLeft: 0,\n },\n label: {\n color: Colors.textSecondary,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '24px',\n fontWeight: 500,\n },\n});\nvar Filter = function (_a) {\n var label = _a.label, onClick = _a.onClick, checked = _a.checked;\n var classes = useStyles();\n return (_jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: checked, onChange: onClick, icon: _jsx(CheckBoxOutlineBlank, {}, void 0), checkedIcon: _jsx(CheckBoxIcon, {}, void 0), name: label }, void 0), label: label, classes: {\n root: classes.root,\n label: classes.label,\n } }, void 0));\n};\nexport default Filter;\n//# sourceMappingURL=Filter.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Accordion, AccordionDetails, AccordionSummary } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useState } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { useUUID } from '../../hooks/useUUID';\nimport { ChevronDown } from 'react-feather';\nvar useStyles = makeStyles({\n accordion: {\n background: 'none',\n padding: 0,\n borderBottom: '1px solid rgba(0, 0, 0, 0.14)',\n '&::before': {\n background: 'none',\n },\n },\n content: {\n display: 'grid',\n },\n contentRoot: {\n padding: 0,\n },\n title: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontWeight: 600,\n fontSize: 16,\n letterSpacing: 0.15,\n lineHeight: '24px',\n },\n header: {\n display: 'grid',\n gridAutoFlow: 'column',\n justifyContent: 'left',\n gridGap: 8,\n textTransform: 'uppercase',\n '& .MuiAccordionSummary-content': {\n margin: 0,\n },\n },\n});\nvar FilterSet = function (_a) {\n var children = _a.children, title = _a.title, initialOpenState = _a.initialOpenState;\n var classes = useStyles();\n var id = useUUID();\n var _b = __read(useState(initialOpenState), 2), open = _b[0], setOpen = _b[1];\n var onClick = function () { return setOpen(!open); };\n return (_jsxs(Accordion, __assign({ className: classes.accordion, onChange: onClick, expanded: open, elevation: 0 }, { children: [_jsx(AccordionSummary, __assign({ className: classes.header, classes: { root: classes.contentRoot }, expandIcon: _jsx(ChevronDown, {}, void 0), \"aria-controls\": id + \"-content\", id: id + \"-header\" }, { children: _jsx(\"h3\", __assign({ className: classes.title }, { children: title }), void 0) }), void 0), _jsx(AccordionDetails, __assign({ className: classes.content, classes: { root: classes.contentRoot } }, { children: children }), void 0)] }), void 0));\n};\nexport default FilterSet;\n//# sourceMappingURL=FilterSet.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { makeStyles, useMediaQuery, useTheme } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport TextButton from '../buttons/TextButton';\nimport Filter from './Filter';\nimport FilterSet from './FilterSet';\nvar useStyles = makeStyles({\n filtersControl: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n borderBottom: '1px solid rgba(0,0,0,0.08)',\n paddingBottom: 4,\n margin: '16px 0px',\n },\n filtersLabel: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n letterSpacing: 2,\n lineHeight: '16px',\n textTransform: 'uppercase',\n },\n noFilters: {\n height: 36,\n },\n title: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 20,\n letterSpacing: 0.25,\n lineHeight: '24px',\n },\n});\nvar Filters = function (_a) {\n var onChangeFilters = _a.onChangeFilters, clearFilters = _a.clearFilters, filters = _a.filters, isOutcome = _a.isOutcome, title = _a.title, visibleFilters = _a.visibleFilters;\n var classes = useStyles();\n var theme = useTheme();\n var isSmallDown = useMediaQuery(theme.breakpoints.down('sm'));\n var hasFilters = false;\n for (var key in filters) {\n if (filters[key]) {\n hasFilters = true;\n break;\n }\n }\n return (_jsxs(_Fragment, { children: [_jsxs(\"div\", __assign({ className: classes.filtersControl }, { children: [isSmallDown ? (_jsx(\"h2\", __assign({ className: classes.title }, { children: \"Filters\" }), void 0)) : (_jsx(\"h2\", __assign({ className: classes.filtersLabel }, { children: \"Filter By\" }), void 0)), hasFilters ? (_jsx(TextButton, __assign({ onClick: clearFilters }, { children: \"Clear Filters\" }), void 0)) : (_jsx(\"div\", { className: classes.noFilters }, void 0))] }), void 0), _jsxs(FilterSet, __assign({ title: title, initialOpenState: true }, { children: [_jsx(Filter, { label: \"Assigned\", onClick: function () { return onChangeFilters('mythings'); }, checked: filters.mythings }, void 0), _jsx(Filter, { label: \"Not Assigned\", onClick: function () { return onChangeFilters('notmythings'); }, checked: filters.notmythings }, void 0)] }), void 0), !isOutcome && (_jsxs(FilterSet, __assign({ title: \"Category\", initialOpenState: true }, { children: [visibleFilters.collaboration && (_jsx(Filter, { label: \"Collaboration\", onClick: function () { return onChangeFilters('collaboration'); }, checked: filters.collaboration }, void 0)), visibleFilters.communication && (_jsx(Filter, { label: \"Communication\", onClick: function () { return onChangeFilters('communication'); }, checked: filters.communication }, void 0)), visibleFilters.datamanagementandautomation && (_jsx(Filter, { label: \"Data Management\", onClick: function () { return onChangeFilters('datamanagementandautomation'); }, checked: filters.datamanagementandautomation }, void 0)), visibleFilters.fundamentals && (_jsx(Filter, { label: \"Fundamentals\", onClick: function () { return onChangeFilters('fundamentals'); }, checked: filters.fundamentals }, void 0)), visibleFilters.leadership && (_jsx(Filter, { label: \"Leadership\", onClick: function () { return onChangeFilters('leadership'); }, checked: filters.leadership }, void 0)), visibleFilters.timeandtaskmanagement && (_jsx(Filter, { label: \"Time and Task Management\", onClick: function () { return onChangeFilters('timeandtaskmanagement'); }, checked: filters.timeandtaskmanagement }, void 0)), visibleFilters.education && (_jsx(Filter, { label: \"Education\", onClick: function () { return onChangeFilters('education'); }, checked: filters.education }, void 0))] }), void 0)), _jsxs(FilterSet, __assign({ title: \"Workload\", initialOpenState: false }, { children: [visibleFilters.bookings && (_jsx(Filter, { label: \"Bookings\", onClick: function () { return onChangeFilters('bookings'); }, checked: filters.bookings }, void 0)), visibleFilters.delve && (_jsx(Filter, { label: \"Delve\", onClick: function () { return onChangeFilters('delve'); }, checked: filters.delve }, void 0)), visibleFilters.edge && (_jsx(Filter, { label: \"Edge\", onClick: function () { return onChangeFilters('edge'); }, checked: filters.edge }, void 0)), visibleFilters.excel && (_jsx(Filter, { label: \"Excel\", onClick: function () { return onChangeFilters('excel'); }, checked: filters.excel }, void 0)), visibleFilters.powerautomate && (_jsx(Filter, { label: \"Power Automate\", onClick: function () { return onChangeFilters('powerautomate'); }, checked: filters.powerautomate }, void 0)), visibleFilters.forms && (_jsx(Filter, { label: \"Forms\", onClick: function () { return onChangeFilters('forms'); }, checked: filters.forms }, void 0)), visibleFilters.intune && (_jsx(Filter, { label: \"Intune\", onClick: function () { return onChangeFilters('intune'); }, checked: filters.intune }, void 0)), visibleFilters.microsoft365 && (_jsx(Filter, { label: \"Microsoft 365\", onClick: function () { return onChangeFilters('microsoft365'); }, checked: filters.microsoft365 }, void 0)), visibleFilters.myapps && (_jsx(Filter, { label: \"My Apps\", onClick: function () { return onChangeFilters('myapps'); }, checked: filters.myapps }, void 0)), visibleFilters.office365 && (_jsx(Filter, { label: \"Office 365\", onClick: function () { return onChangeFilters('office365'); }, checked: filters.office365 }, void 0)), visibleFilters.onedrive && (_jsx(Filter, { label: \"OneDrive\", onClick: function () { return onChangeFilters('onedrive'); }, checked: filters.onedrive }, void 0)), visibleFilters.onenote && (_jsx(Filter, { label: \"OneNote\", onClick: function () { return onChangeFilters('onenote'); }, checked: filters.onenote }, void 0)), visibleFilters.outlook && (_jsx(Filter, { label: \"Outlook\", onClick: function () { return onChangeFilters('outlook'); }, checked: filters.outlook }, void 0)), visibleFilters.planner && (_jsx(Filter, { label: \"Planner\", onClick: function () { return onChangeFilters('planner'); }, checked: filters.planner }, void 0)), visibleFilters.powerpoint && (_jsx(Filter, { label: \"PowerPoint\", onClick: function () { return onChangeFilters('powerpoint'); }, checked: filters.powerpoint }, void 0)), visibleFilters.sharepoint && (_jsx(Filter, { label: \"SharePoint\", onClick: function () { return onChangeFilters('sharepoint'); }, checked: filters.sharepoint }, void 0)), visibleFilters.teams && (_jsx(Filter, { label: \"Teams\", onClick: function () { return onChangeFilters('teams'); }, checked: filters.teams }, void 0)), visibleFilters.todo && (_jsx(Filter, { label: \"To Do\", onClick: function () { return onChangeFilters('todo'); }, checked: filters.todo }, void 0)), visibleFilters.word && (_jsx(Filter, { label: \"Word\", onClick: function () { return onChangeFilters('word'); }, checked: filters.word }, void 0)), visibleFilters.yammer && (_jsx(Filter, { label: \"Yammer\", onClick: function () { return onChangeFilters('yammer'); }, checked: filters.yammer }, void 0))] }), void 0)] }, void 0));\n};\nexport default Filters;\n//# sourceMappingURL=Filters.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { Colors } from '../utils/colors';\nimport { Search as SearchIcon } from 'react-feather';\nvar useStyles = makeStyles({\n search: {\n backgroundColor: Colors.white,\n height: 36,\n borderTopLeftRadius: 20,\n borderBottomLeftRadius: 20,\n borderTopRightRadius: 20,\n borderBottomRightRadius: 20,\n display: 'flex',\n alignItems: 'center',\n paddingLeft: 10,\n paddingRight: 10,\n '&:focus-within': {\n boxShadow: \"0px 0px 0px 1px \" + Colors.purple,\n },\n },\n searchIcon: {\n height: 24,\n marginRight: 8,\n color: Colors.textSecondary,\n },\n input: {\n width: '100%',\n border: 0,\n margin: 0,\n padding: 0,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '24px',\n color: Colors.textPrimary,\n '&:focus': {\n outline: 'none',\n },\n '&::placeholder': {\n color: Colors.textSecondary,\n },\n },\n});\nvar Search = function (_a) {\n var value = _a.value, onChange = _a.onChange, placeholder = _a.placeholder, style = _a.style, className = _a.className;\n var classes = useStyles();\n return (_jsxs(\"div\", __assign({ className: clsx(classes.search, className), style: style, role: \"search\" }, { children: [_jsx(\"div\", __assign({ className: classes.searchIcon, \"aria-hidden\": true }, { children: _jsx(SearchIcon, {}, void 0) }), void 0), _jsx(\"input\", { \"aria-label\": placeholder, className: classes.input, style: style && style.backgroundColor ? { backgroundColor: style.backgroundColor } : undefined, value: value, onChange: onChange, placeholder: placeholder }, void 0)] }), void 0));\n};\nexport default Search;\n//# sourceMappingURL=Search.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Drawer, IconButton, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useState } from 'react';\nimport { TabName } from '../types/types';\nimport { Colors } from '../utils/colors';\nimport CardSkillsOrOutcomes from './CardSkillsOrOutcomes';\nimport Filters from './filters/Filters';\nimport Search from './Search';\nimport { Filter, X } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n skills: (_a = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n alignItems: 'center',\n },\n _a),\n item: {\n marginTop: 8,\n marginBottom: 8,\n width: '100%',\n borderRadius: 4,\n backgroundColor: Colors.white,\n },\n mainColumn: (_b = {\n width: 720\n },\n _b[theme.breakpoints.down('md')] = {\n width: 492,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _b),\n mobileSearchContainer: {\n width: '100%',\n display: 'grid',\n gridAutoFlow: 'column',\n gridTemplateColumns: '1fr 36px',\n gap: '24px',\n padding: '8px 16px',\n },\n closeButton: {\n position: 'absolute',\n top: 16,\n right: 16,\n },\n drawerPaper: (_c = {\n minWidth: 312\n },\n _c[theme.breakpoints.up('md')] = {\n background: 'none',\n border: 'none',\n position: 'relative',\n width: 'fit-content',\n },\n _c),\n drawerContainer: {\n overflow: 'auto',\n msOverflowStyle: '-ms-autohiding-scrollbar',\n padding: 24,\n paddingTop: 16,\n },\n });\n});\nvar AllSkillsOrOutcomes = function (_a) {\n var filteredSkills = _a.filteredSkills, filteredOutcomes = _a.filteredOutcomes, filters = _a.filters, setFilters = _a.setFilters, visibleFilters = _a.visibleFilters, onChangeSearch = _a.onChangeSearch, search = _a.search, onChangeSort = _a.onChangeSort, sortOrder = _a.sortOrder, page = _a.page, isOutcome = _a.isOutcome;\n var classes = useStyles();\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var _b = __read(useState(), 2), openFilters = _b[0], setOpenFilters = _b[1];\n var onChangeFilters = function (key) {\n var _a;\n setFilters(__assign(__assign({}, filters), (_a = { mythings: key === 'notmythings' ? false : filters.mythings, notmythings: key === 'mythings' ? false : filters.notmythings }, _a[key] = !filters[key], _a)));\n };\n var clearFilters = function () {\n var clearedFilters = __assign({}, filters);\n for (var key in filters) {\n clearedFilters[key] = false;\n }\n setFilters(clearedFilters);\n };\n var toggleFilters = function () { return setOpenFilters(!openFilters); };\n if (!filteredSkills && !filteredOutcomes) {\n return null;\n }\n var title = filteredSkills ? 'Skills' : 'Outcomes';\n return (_jsxs(\"main\", __assign({ id: TabName.All, className: classes.skills }, { children: [isSmDown && (_jsxs(\"div\", __assign({ className: classes.mobileSearchContainer }, { children: [_jsx(Search, { value: search, onChange: onChangeSearch, placeholder: \"Search \" + title }, void 0), _jsx(IconButton, __assign({ \"aria-label\": \"toggle filter menu\", onClick: toggleFilters }, { children: _jsx(Filter, {}, void 0) }), void 0)] }), void 0)), _jsx(\"div\", __assign({ className: classes.mainColumn }, { children: _jsxs(\"div\", __assign({ className: classes.item }, { children: [filteredSkills && (_jsx(CardSkillsOrOutcomes, { title: 'All Skills', page: page, color: 'transparent', cards: filteredSkills, button: true, sortOrder: sortOrder, onChangeSort: onChangeSort }, void 0)), filteredOutcomes && (_jsx(CardSkillsOrOutcomes, { title: \"All Outcomes\", page: page, color: Colors.white, cards: filteredOutcomes, button: true, sortOrder: sortOrder, onChangeSort: onChangeSort, isOutcome: true }, void 0))] }), void 0) }), void 0), _jsx(Drawer, __assign({ variant: isSmDown ? 'temporary' : 'permanent', anchor: \"right\", classes: { paper: classes.drawerPaper }, open: openFilters, onClose: toggleFilters }, { children: _jsxs(\"div\", __assign({ className: classes.drawerContainer }, { children: [isSmDown ? (_jsx(IconButton, __assign({ \"aria-label\": \"close filter menu\", onClick: toggleFilters, className: classes.closeButton }, { children: _jsx(X, {}, void 0) }), void 0)) : (_jsx(Search, { value: search, onChange: onChangeSearch, placeholder: \"Search \" + title }, void 0)), _jsx(Filters, { title: title, onChangeFilters: onChangeFilters, clearFilters: clearFilters, filters: filters, isOutcome: isOutcome, visibleFilters: visibleFilters }, void 0)] }), void 0) }), void 0)] }), void 0));\n};\nexport default AllSkillsOrOutcomes;\n//# sourceMappingURL=AllSkillsOrOutcomes.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { isAfter, isBefore } from 'date-fns';\nimport { useContext, useState } from 'react';\nimport { SkillsContext } from '../../contexts/SkillsContext';\nimport AllSkillsOrOutcomes from '../AllSkillsOrOutcomes';\nimport Loading from '../Loading';\nimport { OutcomeSkillState } from '../../types/enums';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { isUnassigned } from '../../utils/isUnassigned';\nvar getSortedSkills = function (sortOrder, skills) {\n var sorted = __spreadArray([], __read(skills), false);\n switch (sortOrder) {\n case 'newest': {\n sorted.sort(function (a, b) {\n if (isBefore(new Date(a.created), new Date(b.created))) {\n return 1;\n }\n else if (isAfter(new Date(a.created), new Date(b.created))) {\n return -1;\n }\n else {\n return 0;\n }\n });\n break;\n }\n case 'name': {\n sorted.sort(function (a, b) {\n if (a.name < b.name) {\n return -1;\n }\n else if (a.name > b.name) {\n return 1;\n }\n else {\n return 0;\n }\n });\n break;\n }\n case 'progress': {\n sorted.sort(function (a, b) {\n if (a.current.progress > b.current.progress) {\n return -1;\n }\n else if (a.current.progress < b.current.progress) {\n return 1;\n }\n else {\n return 0;\n }\n });\n break;\n }\n default: {\n break;\n }\n }\n return sorted;\n};\nvar getFilteredSkills = function (search, filters, skills) {\n var allSkills = __spreadArray([], __read(skills), false).filter(function (skill) { return (skill === null || skill === void 0 ? void 0 : skill.outcomeSkillState) !== OutcomeSkillState.Hardhat; });\n var searchedByName = allSkills.filter(function (skill) {\n return skill.name.toLowerCase().trim().includes(search.toLowerCase().trim());\n });\n var searchedByKeywords = allSkills.filter(function (skill) {\n return skill.keywords.toLowerCase().trim().includes(search.toLowerCase().trim());\n });\n var filteredSkills = [];\n var afterSearchSkills = __spreadArray(__spreadArray([], __read(searchedByName), false), __read(searchedByKeywords), false);\n if (filters['mythings']) {\n afterSearchSkills = afterSearchSkills.filter(function (skill) { return !isUnavailable(skill.current.state) && !isUnassigned(skill.current.state); });\n }\n else if (filters['notmythings']) {\n afterSearchSkills = afterSearchSkills.filter(function (skill) { return isUnavailable(skill.current.state) || isUnassigned(skill.current.state); });\n }\n for (var key in filters) {\n if (!filters[key]) {\n continue;\n }\n var newFilteredSkills = [];\n switch (key) {\n case 'sharepoint': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'SharePoint'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'onedrive': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'OneDrive'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'yammer': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Yammer'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'onenote': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'OneNote'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'word': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'Word'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'excel': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'Excel'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'powerpoint': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'PowerPoint'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'teams': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'Teams'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'outlook': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Outlook'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'office365': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Office 365'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'microsoft365': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Microsoft 365'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'delve': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'Delve'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'planner': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Planner'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'todo': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'To-Do'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'forms': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'Forms'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'powerautomate': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Power Automate'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'bookings': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.apps.find(function (app) { return app.name === 'Bookings'; });\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'edge': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.apps.find(function (app) { return app.name === 'Edge'; }); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'collaboration': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('Collaboration'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'communication': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('Communication'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'datamanagementandautomation': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.categories.includes('Data Management and Automation');\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'fundamentals': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('Fundamentals'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'leadership': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('Leadership'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'timeandtaskmanagement': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) {\n return skill.categories.includes('Time and Task Management');\n });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'education': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('Education'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'intune': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('Intune'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n case 'myapps': {\n newFilteredSkills = afterSearchSkills.filter(function (skill) { return skill.categories.includes('My Apps'); });\n filteredSkills = __spreadArray(__spreadArray([], __read(filteredSkills), false), __read(newFilteredSkills), false);\n break;\n }\n default: {\n break;\n }\n }\n }\n var seenSkills = new Set();\n var finalFilteredSkills = [];\n var hasFilters = false;\n for (var key in filters) {\n if (filters[key] && !['mythings', 'notmythings'].includes(key)) {\n hasFilters = true;\n break;\n }\n }\n if (filteredSkills.length === 0 && !hasFilters) {\n filteredSkills = __spreadArray([], __read(afterSearchSkills), false);\n }\n filteredSkills.forEach(function (skill) {\n if (!seenSkills.has(skill)) {\n seenSkills.add(skill);\n finalFilteredSkills.push(skill);\n }\n });\n return finalFilteredSkills;\n};\nvar AllSkills = function (_a) {\n var page = _a.page;\n var _b = useContext(SkillsContext), allSkills = _b.allSkills, filtersSkills = _b.filtersSkills, setFiltersSkills = _b.setFiltersSkills;\n var _c = __read(useState('name'), 2), sortOrder = _c[0], setSortOrder = _c[1];\n var _d = __read(useState(''), 2), search = _d[0], setSearch = _d[1];\n var _e = __read(useState({\n mythings: true,\n notmythings: true,\n all: true,\n sharepoint: true,\n onedrive: true,\n yammer: true,\n onenote: true,\n word: true,\n excel: true,\n powerpoint: true,\n teams: true,\n outlook: true,\n office365: true,\n microsoft365: true,\n delve: true,\n planner: true,\n todo: true,\n forms: true,\n powerautomate: true,\n bookings: true,\n edge: true,\n collaboration: true,\n communication: true,\n datamanagementandautomation: true,\n fundamentals: true,\n leadership: true,\n timeandtaskmanagement: true,\n education: true,\n intune: true,\n myapps: true,\n }), 1), visibleFilters = _e[0];\n var onChangeSort = function (event) {\n return setSortOrder(event.target.value);\n };\n var onChangeSearch = function (event) { return setSearch(event.target.value); };\n var sortedSkills = getSortedSkills(sortOrder, allSkills !== null && allSkills !== void 0 ? allSkills : []);\n var filteredSkills = getFilteredSkills(search, filtersSkills, sortedSkills);\n if (!allSkills) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsx(AllSkillsOrOutcomes, { filteredSkills: filteredSkills, filters: filtersSkills, setFilters: setFiltersSkills, visibleFilters: visibleFilters, onChangeSearch: onChangeSearch, search: search, onChangeSort: onChangeSort, sortOrder: sortOrder, page: page, isOutcome: false }, void 0));\n};\nexport default AllSkills;\n//# sourceMappingURL=AllSkills.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Paper, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport { pageTitleId } from '../contexts/HeaderContext';\nimport { replaceAll } from '../utils/replaceAll';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n width: 171,\n height: 122,\n backgroundColor: Colors.white,\n borderRadius: 4,\n margin: 12,\n marginTop: 0,\n marginBottom: 16\n },\n _a[theme.breakpoints.down('md')] = {\n margin: 8,\n marginTop: 0,\n marginBottom: 16,\n width: '100%',\n height: 120,\n },\n _a[theme.breakpoints.down('sm')] = {\n flex: 1,\n height: 122,\n margin: 0,\n borderRadius: 0,\n background: 'none',\n },\n _a),\n item: {\n height: '100%',\n marginLeft: 15,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-start',\n },\n dot: {\n marginLeft: 8,\n width: 12,\n height: 12,\n borderRadius: 25,\n },\n info: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n });\n});\nvar InfoCard = function (_a) {\n var skillNumber = _a.skillNumber, color = _a.color, text = _a.text, style = _a.style;\n var typo = useTypography();\n var classes = useStyles();\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var ariaTextId = replaceAll(text, ' ', '-').concat('-info');\n var ariaNumSkillsId = \"numSkills-\" + ariaTextId;\n return (_jsx(Paper, __assign({ elevation: 1, \"aria-labelledby\": [ariaNumSkillsId, pageTitleId, ariaTextId].join(' '), className: classes.card, style: style }, { children: _jsxs(\"div\", __assign({ className: classes.item }, { children: [_jsxs(\"div\", __assign({ className: classes.info }, { children: [_jsx(\"span\", __assign({ id: ariaNumSkillsId, className: typo.h3 }, { children: skillNumber }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: color } }, void 0)] }), void 0), _jsx(\"p\", __assign({ id: ariaTextId, className: typo.body1, style: { fontSize: isSmDown ? 12 : '' } }, { children: text }), void 0)] }), void 0) }), void 0));\n};\nexport default InfoCard;\n//# sourceMappingURL=InfoCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Divider, useMediaQuery, useTheme } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../utils/colors';\nimport InfoCard from './InfoCard';\nimport DoughnutChart from './charts/DoughnutChart';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n header: (_a = {\n width: 715\n },\n _a[theme.breakpoints.down('md')] = {\n width: 422,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n items: (_b = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _b[theme.breakpoints.down('sm')] = {\n background: Colors.white,\n borderRadius: 4,\n },\n _b),\n graph: (_c = {\n width: 122,\n height: 122,\n marginRight: 20,\n marginBottom: 16\n },\n _c[theme.breakpoints.down('sm')] = {\n width: 200,\n height: 200,\n marginRight: 0,\n marginBottom: 20,\n },\n _c),\n small: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n },\n });\n});\nvar Header = function (_a) {\n var maintain = _a.maintain, inProgress = _a.inProgress, needsImprovement = _a.needsImprovement, isOutcomes = _a.isOutcomes;\n var classes = useStyles();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n return (_jsxs(\"section\", __assign({ \"aria-label\": (isOutcomes ? 'Outcomes' : 'Skills') + \" summary\", className: classes.header }, { children: [isMdDown ? (_jsx(\"div\", __assign({ className: classes.small }, { children: _jsxs(\"div\", __assign({ className: classes.items }, { children: [_jsx(InfoCard, { skillNumber: needsImprovement, color: Colors.red, text: needsImprovement === 1 ? 'Needs Attention' : 'Need Attention', style: { marginLeft: 0 } }, void 0), _jsx(InfoCard, { skillNumber: inProgress, color: Colors.yellow, text: 'In Progress' }, void 0), _jsx(InfoCard, { skillNumber: maintain, color: Colors.green, text: 'Attained', style: { marginRight: 0 } }, void 0)] }), void 0) }), void 0)) : (_jsxs(\"div\", __assign({ className: classes.items }, { children: [_jsx(\"div\", __assign({ \"aria-hidden\": true, className: classes.graph }, { children: _jsx(DoughnutChart, { maintain: maintain, inProgress: inProgress, needsImprovement: needsImprovement }, void 0) }), void 0), _jsx(InfoCard, { skillNumber: needsImprovement, color: Colors.red, text: needsImprovement === 1 ? 'Needs Attention' : 'Need Attention', style: { marginLeft: 0 } }, void 0), _jsx(InfoCard, { skillNumber: inProgress, color: Colors.yellow, text: 'In Progress' }, void 0), _jsx(InfoCard, { skillNumber: maintain, color: Colors.green, text: 'Attained', style: { marginRight: 0 } }, void 0)] }), void 0)), _jsx(Divider, {}, void 0)] }), void 0));\n};\nexport default Header;\n//# sourceMappingURL=Header.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Link as MuiLink, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useContext, useEffect, useState } from 'react';\nimport { Link } from 'react-router-dom';\nimport { SkillsContext } from '../../contexts/SkillsContext';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { useGetSkillsData } from '../../hooks/useGetSkillsData';\nimport AddButton from '../buttons/AddButton';\nimport UpgradeButton from '../buttons/UpgradeButton';\nimport LevelIcon from '../LevelIcon';\nimport { SkillProgressBar } from '../SkillProgressBar';\nimport { Level } from '../../types/enums';\nimport { isUpgradeSkillRecommendation } from '../../utils/isUpgradeSkillRecommendation';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d;\n return ({\n skill: (_a = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n paddingBottom: 24,\n marginBottom: 24,\n borderBottom: '1px solid rgba(0, 0, 0, 0.12)',\n '&&:last-child': {\n borderBottom: 'none',\n }\n },\n _a[theme.breakpoints.only('md')] = {\n flexDirection: 'column',\n alignItems: 'flex-start',\n },\n _a),\n link: {\n textDecoration: 'none',\n '&:focus, &:hover, &:visited, &:link, &:active': {\n textDecoration: 'none',\n },\n color: Colors.black,\n width: '100%',\n },\n info: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n },\n topBar: (_b = {\n width: '100%',\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center'\n },\n _b[theme.breakpoints.only('md')] = {\n alignItems: 'flex-start',\n },\n _b),\n icon: (_c = {\n marginRight: 20\n },\n _c[theme.breakpoints.down('md')] = {\n marginRight: 10,\n },\n _c[theme.breakpoints.down('sm')] = {\n marginRight: 20,\n },\n _c),\n detail: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n button: (_d = {\n marginLeft: 20\n },\n _d[theme.breakpoints.only('md')] = {\n marginLeft: 40,\n },\n _d),\n });\n});\nvar RecommendedSkill = function (_a) {\n var recommendedSkill = _a.recommendedSkill, page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var allSkills = useContext(SkillsContext).allSkills;\n var _b = __read(useState(undefined), 2), skill = _b[0], setSkill = _b[1];\n var getData = useGetSkillsData();\n var theme = useTheme();\n var isMd = useMediaQuery(theme.breakpoints.only('md'));\n useEffect(function () {\n allSkills === null || allSkills === void 0 ? void 0 : allSkills.forEach(function (value) {\n if (value.id === recommendedSkill.targetId) {\n setSkill(value);\n }\n });\n }, [allSkills, recommendedSkill.targetId]);\n if (!skill) {\n return null;\n }\n var describedById = skill.id.toString() + '-recommended';\n return (_jsxs(\"div\", __assign({ className: classes.skill }, { children: [_jsx(MuiLink, __assign({ component: Link, to: page + \"/skill-details/\" + skill.id, className: classes.link }, { children: _jsxs(\"div\", __assign({ className: classes.info }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: _jsx(LevelIcon, { progress: skill.current.progress, state: skill.current.state, level: skill.current.level, type: \"skill\" }, void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.topBar }, { children: [_jsx(\"div\", __assign({ className: classes.detail }, { children: _jsx(\"h3\", __assign({ id: describedById, className: typo.subtitle2, style: { marginRight: 8 } }, { children: skill.name }), void 0) }), void 0), _jsx(SkillProgressBar, { currentState: skill.current.state, progress: skill.current.progress }, void 0)] }), void 0)] }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.button }, { children: isUpgradeSkillRecommendation(recommendedSkill) ? (_jsx(UpgradeButton, { user: user, recommended: true, skillOrOutcome: skill, onAccept: getData, describedById: describedById, textFormat: isMd }, void 0)) : (_jsx(AddButton, { user: user, recommended: true, skillOrOutcome: skill, level: Level.User, onAccept: getData, describedById: describedById, textFormat: isMd }, void 0)) }), void 0)] }), void 0));\n};\nexport default RecommendedSkill;\n//# sourceMappingURL=RecommendedSkill.js.map","import { RecommendType } from '../types/enums';\nexport var isUpgradeSkillRecommendation = function (recommendation) {\n return [RecommendType.UpgradeSkill].includes(recommendation.type);\n};\n//# sourceMappingURL=isUpgradeSkillRecommendation.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport RecommendedSkill from './RecommendedSkill';\nimport { Paper } from '@material-ui/core';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n width: 326,\n backgroundColor: Colors.white,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n borderRadius: 4\n },\n _a[theme.breakpoints.down('md')] = {\n width: 236,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n borderRadius: 0,\n },\n _a),\n content: {\n width: '100%',\n padding: 16,\n paddingBottom: 0,\n },\n });\n});\nvar RecommendedSkillCard = function (_a) {\n var _b;\n var recommendedSkills = _a.recommendedSkills, page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n return (_jsx(Paper, __assign({ component: \"section\", elevation: 1, \"aria-labelledby\": \"recommended-title\", className: classes.card }, { children: _jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(\"h2\", __assign({ id: \"recommended-title\", className: typo.subtitle2, style: { fontWeight: 600 } }, { children: \"Discover More\" }), void 0), ((_b = recommendedSkills === null || recommendedSkills === void 0 ? void 0 : recommendedSkills.length) !== null && _b !== void 0 ? _b : 0) === 0 ? (_jsx(\"p\", __assign({ className: typo.caption, style: { marginBottom: 16 } }, { children: \"There aren\\u2019t any new recommendations for you right now - but keep using your skills in Microsoft 365 and check back soon. But, if you\\u2019re ready for a new challenge, try advancing to the next level or adding a new Skill or Outcome\" }), void 0)) : (_jsxs(_Fragment, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { marginBottom: 16 } }, { children: \"Here are some Skills we think would be great for you.\" }), void 0), recommendedSkills === null || recommendedSkills === void 0 ? void 0 : recommendedSkills.map(function (value, index) { return (_jsx(RecommendedSkill, { page: page, recommendedSkill: value }, value.id)); })] }, void 0))] }), void 0) }), void 0));\n};\nexport default RecommendedSkillCard;\n//# sourceMappingURL=RecommendedSkillCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useContext } from 'react';\nimport { useHistory } from 'react-router';\nimport { SkillsContext } from '../../contexts/SkillsContext';\nimport { TabName } from '../../types/types';\nimport { Colors } from '../../utils/colors';\nimport CardSkillsOrOutcomes from '../CardSkillsOrOutcomes';\nimport Header from '../Header';\nimport Loading from '../Loading';\nimport RecommendedSkillCard from './RecommendedSkillCard';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n skills: (_a = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n alignItems: 'center',\n },\n _a),\n item: {\n marginTop: 16,\n width: '100%',\n borderRadius: 4,\n backgroundColor: Colors.white,\n },\n mainColumn: (_b = {\n width: 720\n },\n _b[theme.breakpoints.down('md')] = {\n width: 422,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _b),\n secondColumn: (_c = {\n marginLeft: 16\n },\n _c[theme.breakpoints.down('md')] = {\n marginLeft: 11,\n },\n _c[theme.breakpoints.down('sm')] = {\n marginTop: 12,\n marginLeft: 0,\n width: 330,\n },\n _c),\n });\n});\nvar YourSkills = function (_a) {\n var _b, _c, _d;\n var page = _a.page, skillDetailId = _a.skillDetailId;\n var classes = useStyles();\n var _e = useContext(SkillsContext), skills = _e.skills, recommendedSkills = _e.recommendedSkills, deepLink = _e.deepLink, setDeepLink = _e.setDeepLink;\n var history = useHistory();\n if (skillDetailId && !deepLink) {\n setDeepLink(true);\n history.push(\"/skillsTab/skill-details/\" + skillDetailId);\n }\n if (!skills) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"main\", __assign({ id: TabName.Yours, className: classes.skills }, { children: [_jsxs(\"div\", __assign({ className: classes.mainColumn }, { children: [_jsx(Header, { maintain: (_b = skills === null || skills === void 0 ? void 0 : skills.maintain.length) !== null && _b !== void 0 ? _b : 0, inProgress: (_c = skills === null || skills === void 0 ? void 0 : skills.inProgress.length) !== null && _c !== void 0 ? _c : 0, needsImprovement: (_d = skills === null || skills === void 0 ? void 0 : skills.needsImprovement.length) !== null && _d !== void 0 ? _d : 0 }, void 0), (skills === null || skills === void 0 ? void 0 : skills.needsImprovement) && skills.needsImprovement.length > 0 && (_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(CardSkillsOrOutcomes, { page: page, title: \"Need Attention\", color: Colors.red, cards: skills.needsImprovement, button: false }, \"skills-need-attention\") }), void 0)), (skills === null || skills === void 0 ? void 0 : skills.inProgress) && skills.inProgress.length > 0 && (_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(CardSkillsOrOutcomes, { page: page, title: \"In Progress\", color: Colors.yellow, cards: skills.inProgress, button: false }, \"skills-in-progress\") }), void 0)), (skills === null || skills === void 0 ? void 0 : skills.maintain) && skills.maintain.length > 0 && (_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(CardSkillsOrOutcomes, { page: page, title: \"Attained\", color: Colors.green, cards: skills.maintain, button: false }, \"skills-maintain\") }), void 0)), _jsx(\"div\", { style: { height: 24 } }, void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.secondColumn }, { children: _jsx(RecommendedSkillCard, { page: page, recommendedSkills: recommendedSkills }, void 0) }), void 0)] }), void 0));\n};\nexport default YourSkills;\n//# sourceMappingURL=YourSkills.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { Paper } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/styles';\nimport { Colors } from '../utils/colors';\nimport { useTypography } from '../styles/Typography';\nimport clsx from 'clsx';\nimport CalendarIcon from './icons/CalendarIcon';\nimport { UserContext } from '../contexts/UserContext';\nimport { getDaysToNextUpdate } from '../utils/getDaysToNextUpdate';\nvar useStyles = makeStyles(function (theme) { return ({\n section: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n margin: 24,\n },\n card: {\n color: Colors.white,\n backgroundColor: Colors.purple,\n width: 1080,\n height: 64,\n },\n cardTitle: {\n height: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n cardTitleLabel: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n },\n days: {\n color: Colors.purple,\n fontWeight: 700,\n zIndex: 1,\n position: 'relative',\n left: 38,\n top: 4,\n },\n}); });\nvar MeasurementBanner = function () {\n var classes = useStyles();\n var typo = useTypography();\n var user = useContext(UserContext).user;\n var daysToNextUpdate = getDaysToNextUpdate(user === null || user === void 0 ? void 0 : user.nextScoreDate);\n return (_jsx(\"section\", __assign({ className: classes.section }, { children: _jsx(Paper, __assign({ elevation: 1, className: classes.card }, { children: _jsxs(\"div\", __assign({ className: classes.cardTitle }, { children: [_jsxs(\"div\", __assign({ className: classes.cardTitleLabel }, { children: [_jsx(\"span\", __assign({ className: clsx(typo.h5, classes.days), style: daysToNextUpdate < 10 ? { left: 32 } : undefined }, { children: daysToNextUpdate }), void 0), _jsx(CalendarIcon, { days: daysToNextUpdate }, void 0)] }), void 0), _jsx(\"span\", __assign({ className: typo.subtitle1, style: { color: Colors.white, marginLeft: 8 } }, { children: \"days until we reveal your progress\" }), void 0)] }), void 0) }), void 0) }), void 0));\n};\nexport default MeasurementBanner;\n//# sourceMappingURL=MeasurementBanner.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { TabName } from '../../types/types';\nimport { useGetSkillsData } from '../../hooks/useGetSkillsData';\nimport AllSkills from './AllSkills';\nimport YourSkills from './YourSkills';\nimport { Pages } from '../../types/enums';\nimport { UserContext } from '../../contexts/UserContext';\nimport MeasurementBanner from '../MeasurementBanner';\nimport NextLastUpdated from '../NextLastUpdated';\nvar Skills = function (_a) {\n var page = _a.page, skillDetailId = _a.skillDetailId;\n var user = useContext(UserContext).user;\n var _b = useContext(HeaderContext), setTitle = _b.setTitle, setGoBack = _b.setGoBack, setTabs = _b.setTabs, setPage = _b.setPage;\n var _c = __read(useState(false), 2), receivedData = _c[0], setReceivedData = _c[1];\n var getData = useGetSkillsData();\n useEffect(function () {\n if (!receivedData) {\n getData();\n setReceivedData(true);\n }\n }, [receivedData, getData]);\n useEffect(function () {\n setTitle('Skills');\n setGoBack(false);\n setTabs([\n {\n name: TabName.Yours,\n selected: location.pathname !== (page !== null && page !== void 0 ? page : Pages.SkillsPage) + \"/all-skills\",\n to: (page !== null && page !== void 0 ? page : Pages.SkillsPage) + \"/your-skills\",\n },\n {\n name: TabName.All,\n selected: location.pathname === page + \"/all-skills\",\n to: (page !== null && page !== void 0 ? page : Pages.SkillsPage) + \"/all-skills\",\n },\n ]);\n setPage(page !== null && page !== void 0 ? page : Pages.SkillsPage);\n }, [location.pathname]);\n return (_jsxs(_Fragment, { children: [(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) ? _jsx(MeasurementBanner, {}, void 0) : _jsx(NextLastUpdated, {}, void 0), location.pathname === page + \"/all-skills\" ? (_jsx(AllSkills, { page: page !== null && page !== void 0 ? page : Pages.SkillsPage }, void 0)) : (_jsx(YourSkills, { page: page !== null && page !== void 0 ? page : Pages.SkillsPage, skillDetailId: skillDetailId }, void 0))] }, void 0));\n};\nexport default Skills;\n//# sourceMappingURL=Skills.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar PreferencesApi = (function () {\n function PreferencesApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.submitFeedback = function (feedbackData) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/SendFeedback\";\n body = __assign({}, feedbackData);\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.updatePreferences = function (preferenceData) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/UpdatePreferences\";\n body = {\n emailWeekly: preferenceData.emailWeekly,\n emailImportant: preferenceData.emailImportant,\n alternateEmail: preferenceData.alternateEmail,\n preferredName: preferenceData.preferredName,\n };\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return PreferencesApi;\n}());\nexport { PreferencesApi };\n//# sourceMappingURL=PreferencesApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { toFeedbackDataDTO, toPreferencesDTO } from '../utils/mapper';\nimport { ENABLE_ANALYTICS } from '../utils/constants';\nimport { PreferencesApi } from '../data/PreferencesApi';\nvar PreferencesService = (function () {\n function PreferencesService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.sendFeedback = function (type, text) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.preferencesApi.submitFeedback(toFeedbackDataDTO(type, text))];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.selectedAnalytics = function () {\n var value = localStorage.getItem(ENABLE_ANALYTICS);\n return value !== null;\n };\n this.setAnalytics = function (value) {\n localStorage.setItem(ENABLE_ANALYTICS, value.toString());\n };\n this.updatePreferences = function (preferences) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.preferencesApi.updatePreferences(toPreferencesDTO(preferences))];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.token = token;\n this.clientType = clientType;\n this.preferencesApi = new PreferencesApi(token, oid, tid, sid, clientType);\n }\n PreferencesService.getAnalytics = function () {\n var value = localStorage.getItem(ENABLE_ANALYTICS);\n return value === 'true';\n };\n PreferencesService.selectedAnalytics = function () {\n var value = localStorage.getItem(ENABLE_ANALYTICS);\n return value !== null;\n };\n PreferencesService.setAnalytics = function (value) {\n localStorage.setItem(ENABLE_ANALYTICS, value.toString());\n };\n return PreferencesService;\n}());\nexport { PreferencesService };\n//# sourceMappingURL=PreferencesService.js.map","var HelperService = (function () {\n function HelperService() {\n }\n HelperService.verifyEmail = function (email) {\n if (!email) {\n return true;\n }\n return /\\S+@\\S+\\.\\S+/.test(email);\n };\n return HelperService;\n}());\nexport { HelperService };\n//# sourceMappingURL=HelperService.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Checkbox, Divider, FormControl, FormControlLabel, FormGroup, Paper, TextField } from '@material-ui/core';\nimport { useContext, useState } from 'react';\nimport { UserContext } from '../../contexts/UserContext';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { PreferencesService } from '../../services/PreferencesService';\nimport { HelperService } from '../../services/HelperService';\nimport { toPreferencesModel } from '../../utils/mapper';\nimport { getToken } from '../../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useTypography } from '../../styles/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../../utils/colors';\nvar useStyles = makeStyles(function (theme) { return ({\n paper: {\n background: Colors.white,\n borderRadius: 4,\n boxShadow: '0 1px 4px rgba(0, 0, 0, 0.08), 0 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n padding: 24,\n flex: 5,\n margin: 8,\n },\n input: {\n width: '100%',\n marginBottom: 32,\n },\n}); });\nvar PreferencesForm = function () {\n var _a, _b;\n var classes = useStyles();\n var typo = useTypography();\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var user = useContext(UserContext).user;\n var _d = useMsal(), instance = _d.instance, accounts = _d.accounts;\n var account = useAccount(accounts[0]);\n var _e = __read(useState((_a = user === null || user === void 0 ? void 0 : user.preferences) !== null && _a !== void 0 ? _a : {\n alternateEmail: undefined,\n emailImportant: false,\n emailWeekly: false,\n preferredName: '',\n workEmail: '',\n }), 2), preferences = _e[0], setPreferences = _e[1];\n var _f = __read(useState(preferences.emailWeekly), 2), weeklyEmails = _f[0], setWeeklyEmails = _f[1];\n var _g = __read(useState(preferences.emailImportant), 2), importantEmails = _g[0], setImportantEmails = _g[1];\n var _h = __read(useState(preferences.preferredName), 2), preferredName = _h[0], setPreferredName = _h[1];\n var _j = __read(useState((_b = preferences.alternateEmail) !== null && _b !== void 0 ? _b : ''), 2), alternateEmail = _j[0], setAlternateEmail = _j[1];\n var _k = __read(useState(false), 2), alternateEmailError = _k[0], setAlternateEmailError = _k[1];\n var onChangeWeeklyEmails = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newPreferences, newToken, preferencesService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n newPreferences = {\n alternateEmail: preferences.alternateEmail,\n emailImportant: preferences.emailImportant,\n emailWeekly: !weeklyEmails,\n preferredName: preferences.preferredName,\n workEmail: preferences.workEmail,\n };\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n preferencesService = new PreferencesService(newToken, oid, tid, '', clientType);\n return [4, preferencesService.updatePreferences(toPreferencesModel(newPreferences))];\n case 2:\n _a.sent();\n setWeeklyEmails(!weeklyEmails);\n setPreferences(newPreferences);\n return [2];\n }\n });\n }); };\n var onChangeImportantEmails = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newPreferences, newToken, preferencesService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n newPreferences = {\n alternateEmail: preferences.alternateEmail,\n emailImportant: !importantEmails,\n emailWeekly: preferences.emailWeekly,\n preferredName: preferences.preferredName,\n workEmail: preferences.workEmail,\n };\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n preferencesService = new PreferencesService(newToken, oid, tid, '', clientType);\n return [4, preferencesService.updatePreferences(toPreferencesModel(newPreferences))];\n case 2:\n _a.sent();\n setImportantEmails(!importantEmails);\n setPreferences(newPreferences);\n return [2];\n }\n });\n }); };\n var onChangePreferredName = function (event) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n setPreferredName(event.target.value);\n return [2];\n });\n }); };\n var onChangeAlternateEmail = function (event) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n setAlternateEmail(event.target.value);\n return [2];\n });\n }); };\n var onBlur = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newPreferences, newToken, preferencesService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!HelperService.verifyEmail(alternateEmail)) {\n setAlternateEmailError(true);\n return [2];\n }\n else {\n setAlternateEmailError(false);\n }\n newPreferences = {\n alternateEmail: alternateEmail,\n emailImportant: preferences.emailImportant,\n emailWeekly: preferences.emailWeekly,\n preferredName: preferredName,\n workEmail: preferences.workEmail,\n };\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n preferencesService = new PreferencesService(newToken, oid, tid, '', clientType);\n return [4, preferencesService.updatePreferences(toPreferencesModel(newPreferences))];\n case 2:\n _a.sent();\n setPreferences(newPreferences);\n return [2];\n }\n });\n }); };\n return (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.paper }, { children: [_jsx(\"h2\", __assign({ className: typo.overline, style: { marginBottom: 8 } }, { children: \"Notification Preferences\" }), void 0), _jsx(FormControl, __assign({ component: \"fieldset\" }, { children: _jsxs(FormGroup, { children: [_jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: weeklyEmails, onChange: onChangeWeeklyEmails, name: \"weekly emails\" }, void 0), label: \"Receive Weekly Email\" }, void 0), _jsx(FormControlLabel, { control: _jsx(Checkbox, { checked: importantEmails, onChange: onChangeImportantEmails, name: \"important emails\" }, void 0), label: \"Receive Important Emails\" }, void 0)] }, void 0) }), void 0), _jsx(Divider, { style: { marginTop: 16, marginBottom: 16 } }, void 0), _jsx(\"h2\", __assign({ className: typo.overline, style: { marginBottom: 8 } }, { children: \"Badge Identification Preferences\" }), void 0), _jsxs(\"p\", __assign({ className: typo.body2, style: { marginBottom: 32 } }, { children: [\"When you show off your Skills on sites like LinkedIn by posting your badge, others can verify the badge belongs to you by the name or emails you list below\", ' '] }), void 0), _jsxs(\"form\", __assign({ noValidate: true, autoComplete: \"off\" }, { children: [_jsx(TextField, { className: classes.input, id: \"work-email\", label: \"Work Email (Not Editable)\", type: \"email\", defaultValue: preferences.workEmail, disabled: true, error: false }, void 0), _jsx(TextField, { className: classes.input, id: \"preferred-name\", label: \"Name\", type: \"name\", value: preferredName, onChange: onChangePreferredName, onBlur: onBlur, error: false }, void 0), _jsx(TextField, { className: classes.input, id: \"personal-email\", label: \"Personal Email\", type: \"email\", value: alternateEmail, onChange: onChangeAlternateEmail, onBlur: onBlur, error: alternateEmailError }, void 0)] }), void 0)] }), void 0));\n};\nexport default PreferencesForm;\n//# sourceMappingURL=PreferencesForm.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { FormControl, InputLabel, MenuItem, Paper, Select, TextField } from '@material-ui/core';\nimport Button from '../buttons/Button';\nimport { useContext, useState } from 'react';\nimport { FeedbackTypes } from '../../types/enums';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { PreferencesService } from '../../services/PreferencesService';\nimport { getToken } from '../../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../../utils/colors';\nimport { useTypography } from '../../styles/Typography';\nvar useStyles = makeStyles(function (theme) { return ({\n paper: {\n background: Colors.white,\n borderRadius: 4,\n boxShadow: '0 1px 4px rgba(0, 0, 0, 0.08), 0 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n padding: 24,\n flex: 3,\n margin: 8,\n },\n}); });\nvar FeedbackForm = function () {\n var classes = useStyles();\n var typo = useTypography();\n var _a = useContext(TokenContext), oid = _a.oid, tid = _a.tid, clientType = _a.clientType;\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = __read(useState(''), 2), feedbackType = _c[0], setFeedbackType = _c[1];\n var _d = __read(useState(''), 2), feedbackText = _d[0], setFeedbackText = _d[1];\n var _e = __read(useState(false), 2), typeError = _e[0], setTypeError = _e[1];\n var _f = __read(useState(false), 2), textError = _f[0], setTextError = _f[1];\n var _g = __read(useState(false), 2), submitted = _g[0], setSubmitted = _g[1];\n var handleSubmitted = function () { return setSubmitted(true); };\n var onFeedbackTypeChange = function (event) {\n var selectValue = event.target.value;\n setFeedbackType(selectValue);\n };\n var onFeedbackTextChange = function (event) { return setFeedbackText(event.target.value); };\n var submit = function (event) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, preferencesService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n event.preventDefault();\n if (!feedbackType) {\n setTypeError(true);\n }\n if (!feedbackText) {\n setTextError(true);\n }\n if (!feedbackType || !feedbackText) {\n return [2];\n }\n handleSubmitted();\n setFeedbackType('');\n setFeedbackText('');\n return [4, getToken(instance, account)];\n case 1:\n newToken = _a.sent();\n preferencesService = new PreferencesService(newToken, oid, tid, '', clientType);\n return [4, preferencesService.sendFeedback(feedbackType, feedbackText)];\n case 2:\n _a.sent();\n setTypeError(false);\n setTextError(false);\n return [2];\n }\n });\n }); };\n if (submitted) {\n return (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.paper, style: { minHeight: 490 } }, { children: [_jsx(\"h2\", __assign({ className: typo.subtitle1, style: { marginBottom: 16 } }, { children: \"Thank you for providing some feedback!\" }), void 0), _jsx(\"p\", __assign({ className: typo.body2, style: { marginBottom: 16 } }, { children: \"Your questions and comments enable us to improve, and we appreciate the help.\" }), void 0)] }), void 0));\n }\n return (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.paper, style: { minHeight: 490 } }, { children: [_jsx(\"h2\", __assign({ className: typo.subtitle1, style: { marginBottom: 16 } }, { children: \"Tell us what you think!\" }), void 0), _jsx(\"p\", __assign({ className: typo.body2, style: { marginBottom: 16 } }, { children: \"Give some feedback! Tell me if you have any questions or comments about Skills, Outcomes, or are having a technical issue\" }), void 0), _jsx(\"h2\", __assign({ className: typo.subtitle1, style: { marginBottom: 16 } }, { children: \"I Have...\" }), void 0), _jsxs(\"form\", { children: [_jsxs(FormControl, __assign({ style: { width: '100%' }, variant: \"filled\" }, { children: [_jsx(\"div\", __assign({ style: { marginBottom: 6 } }, { children: _jsx(InputLabel, __assign({ id: \"feedback-type-label\" }, { children: \"Select your feedback type\" }), void 0) }), void 0), _jsxs(Select, __assign({ labelId: \"feedback-type-label\", id: \"feedback-type\", value: feedbackType, onChange: onFeedbackTypeChange, style: { width: '100%', minWidth: 250, marginBottom: 32 }, error: typeError }, { children: [_jsx(MenuItem, __assign({ value: FeedbackTypes.Technical }, { children: \"Technical Issues\" }), void 0), _jsx(MenuItem, __assign({ value: FeedbackTypes.FeatureQuestion }, { children: \"Feature Question\" }), void 0), _jsx(MenuItem, __assign({ value: FeedbackTypes.OutcomeSkillSuggestion }, { children: \"Outcome & Skill Ideas\" }), void 0), _jsx(MenuItem, __assign({ value: FeedbackTypes.SomethingElse }, { children: \"Something Else\" }), void 0)] }), void 0)] }), void 0), typeError && (_jsx(\"p\", __assign({ className: typo.caption, style: { color: Colors.red, marginBottom: 16 } }, { children: \"Please select type of feedback\" }), void 0)), _jsx(TextField, { style: { width: '100%' }, onChange: onFeedbackTextChange, value: feedbackText, id: \"tell-me-more\", label: \"Tell me more\", multiline: true, rows: \"4\", variant: \"filled\", error: textError }, void 0), textError && (_jsx(\"p\", __assign({ className: typo.caption, style: { color: Colors.red, marginBottom: 16 } }, { children: \"Please leave me some feedback\" }), void 0)), _jsx(\"div\", __assign({ style: { marginTop: 32 } }, { children: _jsx(Button, __assign({ style: { width: 158, marginRight: 16 }, onClick: submit }, { children: \"Send Feedback\" }), void 0) }), void 0)] }, void 0)] }), void 0));\n};\nexport default FeedbackForm;\n//# sourceMappingURL=FeedbackForm.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext, useEffect } from 'react';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport PreferencesForm from './PreferencesForm';\nimport FeedbackForm from './FeedbackForm';\nimport { Pages } from '../../types/enums';\nimport MeasurementBanner from '../MeasurementBanner';\nimport { UserContext } from '../../contexts/UserContext';\nimport NextLastUpdated from '../NextLastUpdated';\nimport { makeStyles } from '@material-ui/core/styles';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n root: {\n display: 'flex',\n justifyContent: 'center',\n },\n container: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n body: (_b = {\n display: 'flex',\n justifyContent: 'space-between'\n },\n _b[theme.breakpoints.down('sm')] = {\n display: 'block',\n },\n _b),\n });\n});\nvar Preferences = function (_a) {\n var page = _a.page;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = useContext(HeaderContext), setGoBack = _b.setGoBack, setTitle = _b.setTitle, setTabs = _b.setTabs, setPage = _b.setPage;\n useEffect(function () {\n setGoBack(false);\n setTitle('Preferences');\n setTabs(undefined);\n setPage(page !== null && page !== void 0 ? page : Pages.PreferencesPage);\n });\n return (_jsxs(_Fragment, { children: [(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) ? _jsx(MeasurementBanner, {}, void 0) : _jsx(NextLastUpdated, {}, void 0), _jsx(\"main\", __assign({ className: classes.root }, { children: _jsx(\"div\", __assign({ className: classes.container }, { children: _jsxs(\"div\", __assign({ className: classes.body }, { children: [_jsx(PreferencesForm, {}, void 0), _jsx(FeedbackForm, {}, void 0)] }), void 0) }), void 0) }), void 0)] }, void 0));\n};\nexport default Preferences;\n//# sourceMappingURL=Preferences.js.map","import { jsx as _jsx, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { ACHIEVEMENTS_PATH, BADGES_PATH, ICON_PATH, OUTCOMES_PATH } from '../../utils/constants';\nimport { CompetenceState, Level, NotificationType } from '../../types/enums';\nimport LevelIcon from '../LevelIcon';\nimport { makeStyles } from '@material-ui/core/styles';\nvar useStyles = makeStyles(function (theme) { return ({\n image: {\n width: 28,\n height: 28,\n },\n}); });\nvar NotificationIcon = function (_a) {\n var type = _a.type, targetId = _a.targetId, img = _a.img, level = _a.level, state = _a.state, progress = _a.progress;\n var classes = useStyles();\n return (_jsx(_Fragment, { children: type === NotificationType.Skill ? (_jsx(LevelIcon, { progress: progress !== null && progress !== void 0 ? progress : 0, level: level !== null && level !== void 0 ? level : Level.None, state: state !== null && state !== void 0 ? state : CompetenceState.Locked, type: \"skill\" }, targetId)) : type === NotificationType.Outcome ? (_jsx(\"img\", { className: classes.image, alt: \"\", src: \"\" + OUTCOMES_PATH + img + \".svg\" }, targetId)) : type === NotificationType.Badge ? (_jsx(\"img\", { className: classes.image, alt: \"\", src: \"\" + BADGES_PATH + img + \".svg\" }, targetId)) : type === NotificationType.Achievement ? (_jsx(\"img\", { className: classes.image, alt: \"\", src: \"\" + ACHIEVEMENTS_PATH + img + \".svg\" }, targetId)) : type === NotificationType.General ? (_jsx(\"img\", { className: classes.image, alt: \"\", src: ICON_PATH + \"general_notification.svg\" }, targetId)) : NotificationType.Video ? (_jsx(\"img\", { className: classes.image, alt: \"\", src: ICON_PATH + \"video_notification_icon.svg\" }, targetId)) : null }, void 0));\n};\nexport default NotificationIcon;\n//# sourceMappingURL=NotificationIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { ClientType, NotificationType, PageIds } from '../../types/enums';\nimport { ButtonBase, Link, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { formatDistanceToNow } from 'date-fns';\nimport NotificationIcon from './NotificationIcon';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport { APPLICATION_ID, BLOB_CONTAINER } from '../../utils/constants';\nimport { useHistory } from 'react-router-dom';\nimport { useTypography } from '../../styles/Typography';\nvar useStyles = makeStyles(function (theme) { return ({\n link: {\n width: '100%',\n marginTop: 16,\n marginBottom: 16,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'flex-start',\n justifyContent: 'space-between',\n textAlign: 'left',\n },\n contents: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'flex-start',\n justifyContent: 'flex-start',\n },\n}); });\nvar Notification = function (_a) {\n var clientType = _a.clientType, type = _a.type, targetId = _a.targetId, title = _a.title, body = _a.body, date = _a.date, img = _a.img, level = _a.level, state = _a.state, progress = _a.progress;\n var classes = useStyles();\n var typo = useTypography();\n var _b = useContext(DialogContext), setOpenVideoDialog = _b.setOpenVideoDialog, setVideoDialogContent = _b.setVideoDialogContent;\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var history = useHistory();\n var typeToPageId = function (type) {\n switch (type) {\n case NotificationType.Achievement:\n return PageIds.ShowcasePage;\n case NotificationType.Badge:\n return PageIds.ShowcasePage;\n case NotificationType.General:\n return PageIds.HomePage;\n case NotificationType.Outcome:\n return PageIds.OutcomesPage;\n case NotificationType.Skill:\n return PageIds.SkillsPage;\n }\n };\n var typeToRoute = function (type) {\n switch (type) {\n case NotificationType.Achievement:\n return '/showcase';\n case NotificationType.Badge:\n return '/showcase';\n case NotificationType.General:\n return '/';\n case NotificationType.Outcome:\n return \"/outcome-details/\" + targetId;\n case NotificationType.Skill:\n return \"/skill-details/\" + targetId;\n default:\n return '/';\n }\n };\n var openPage = function () {\n if (type === NotificationType.Video) {\n setVideoDialogContent({\n container: BLOB_CONTAINER,\n fileName: targetId + \".mp4\",\n contentId: targetId,\n views: 1,\n });\n setOpenVideoDialog(true);\n }\n else {\n if (clientType === ClientType.platform) {\n history.push(typeToRoute(type));\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/\" + typeToPageId(type) + \"?context={\\\"subEntityId\\\": \" + targetId + \"}\");\n }\n }\n };\n return (_jsxs(Link, __assign({ component: ButtonBase, onClick: openPage, className: classes.link }, { children: [_jsxs(\"div\", __assign({ className: classes.contents }, { children: [_jsx(\"div\", __assign({ style: { marginRight: 16, width: 28, height: 28 } }, { children: _jsx(NotificationIcon, { type: type, targetId: targetId, img: img, level: level, state: state, progress: progress }, void 0) }), void 0), _jsxs(\"div\", __assign({ style: { marginRight: 16 } }, { children: [_jsx(\"h3\", __assign({ className: typo.subtitle1 }, { children: title }), void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: body }), void 0), isSmDown && (_jsx(\"p\", __assign({ className: typo.label, style: { minWidth: 100 } }, { children: formatDistanceToNow(new Date(date), { addSuffix: true }) }), void 0))] }), void 0)] }), void 0), !isSmDown && (_jsx(\"p\", __assign({ className: typo.label, style: { minWidth: 100 } }, { children: formatDistanceToNow(new Date(date), { addSuffix: true }) }), void 0))] }), void 0));\n};\nexport default Notification;\n//# sourceMappingURL=Notification.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport Notification from './Notification';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Paper } from '@material-ui/core';\nimport { useTypography } from '../../styles/Typography';\nvar useStyles = makeStyles(function (theme) { return ({\n card: {\n padding: 24,\n },\n}); });\nvar NotificationCard = function (_a) {\n var clientType = _a.clientType, title = _a.title, notifications = _a.notifications;\n var classes = useStyles();\n var typo = useTypography();\n return (_jsxs(\"section\", { children: [_jsx(\"h2\", __assign({ className: typo.button, style: { marginTop: 16, marginBottom: 16 } }, { children: title }), void 0), _jsx(Paper, __assign({ elevation: 1, className: classes.card }, { children: notifications.map(function (value, index) { return (_jsx(Notification, { clientType: clientType, type: value.type, targetId: value.targetId, title: value.title, body: value.text, date: value.created, img: value.img, state: value.state, level: value.level, progress: value.progress }, index)); }) }), void 0)] }, void 0));\n};\nexport default NotificationCard;\n//# sourceMappingURL=NotificationCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var NotificationsContext = createContext({});\nexport var NotificationsProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), notifications = _b[0], setNotifications = _b[1];\n var notificationsContext = {\n notifications: notifications,\n setNotifications: setNotifications,\n };\n return _jsx(NotificationsContext.Provider, __assign({ value: notificationsContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=NotificationsProvider.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar NotificationsApi = (function () {\n function NotificationsApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getNotifications = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetUserNotifications\";\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.viewedNotifications = function (ids) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/ViewedNotifications\";\n body = {\n ids: ids,\n };\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return NotificationsApi;\n}());\nexport { NotificationsApi };\n//# sourceMappingURL=NotificationsApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { HelperApi } from './HelperApi';\nimport { BASE_API_URL } from '../utils/constants';\nvar ShowcaseApi = (function () {\n function ShowcaseApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getRewards = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetPersonalReport\";\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.get(url, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.unlockAchievementDescription = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/UnlockAchievementDescription\";\n body = {\n id: id,\n };\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return ShowcaseApi;\n}());\nexport { ShowcaseApi };\n//# sourceMappingURL=ShowcaseApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __values = (this && this.__values) || function(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { NotificationType } from '../types/enums';\nimport { isAfter, isBefore } from 'date-fns';\nimport { NotificationsApi } from '../data/NotificationsApi';\nimport { OutcomeApi } from '../data/OutcomeApi';\nimport { SkillApi } from '../data/SkillApi';\nimport { ShowcaseApi } from '../data/ShowcaseApi';\nvar NotificationService = (function () {\n function NotificationService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getNotifications = function () { return __awaiter(_this, void 0, void 0, function () {\n var notifications, skills, outcomes, rewards, newer, older, sortedNewer, sortedOlder;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.notificationsApi.getNotifications()];\n case 1:\n notifications = _a.sent();\n return [4, this.skillApi.getUserSkills()];\n case 2:\n skills = _a.sent();\n return [4, this.outcomeApi.getAllOutcomes()];\n case 3:\n outcomes = _a.sent();\n return [4, this.showcaseApi.getRewards()];\n case 4:\n rewards = _a.sent();\n if (!(notifications === null || notifications === void 0 ? void 0 : notifications.data)) {\n return [2];\n }\n return [4, this.setupNotifications(notifications.data.newer, skills === null || skills === void 0 ? void 0 : skills.data, outcomes === null || outcomes === void 0 ? void 0 : outcomes.data, rewards === null || rewards === void 0 ? void 0 : rewards.data.badges, rewards === null || rewards === void 0 ? void 0 : rewards.data.achievements)];\n case 5:\n newer = _a.sent();\n return [4, this.setupNotifications(notifications.data.older, skills === null || skills === void 0 ? void 0 : skills.data, outcomes === null || outcomes === void 0 ? void 0 : outcomes.data, rewards === null || rewards === void 0 ? void 0 : rewards.data.badges, rewards === null || rewards === void 0 ? void 0 : rewards.data.achievements)];\n case 6:\n older = _a.sent();\n sortedNewer = newer.sort(this.notificationSort);\n sortedOlder = older.sort(this.notificationSort);\n return [2, { newer: sortedNewer, older: sortedOlder }];\n }\n });\n }); };\n this.setupNotifications = function (notifications, skills, outcomes, badges, achievements) { return __awaiter(_this, void 0, void 0, function () {\n var newNotifications, notifications_1, notifications_1_1, notification;\n var e_1, _a;\n return __generator(this, function (_b) {\n newNotifications = [];\n try {\n for (notifications_1 = __values(notifications), notifications_1_1 = notifications_1.next(); !notifications_1_1.done; notifications_1_1 = notifications_1.next()) {\n notification = notifications_1_1.value;\n switch (notification.type) {\n case NotificationType.Achievement:\n newNotifications.push(this.setupAchievementNotification(notification, achievements));\n break;\n case NotificationType.Badge:\n newNotifications.push(this.setupBadgeNotification(notification, badges));\n break;\n case NotificationType.General:\n newNotifications.push(notification);\n break;\n case NotificationType.Outcome:\n newNotifications.push(this.setupOutcomeNotification(notification, outcomes));\n break;\n case NotificationType.Skill:\n newNotifications.push(this.setupSkillNotification(notification, skills));\n break;\n case NotificationType.Video:\n newNotifications.push(notification);\n break;\n }\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (notifications_1_1 && !notifications_1_1.done && (_a = notifications_1.return)) _a.call(notifications_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n return [2, newNotifications];\n });\n }); };\n this.setupSkillNotification = function (notification, skills) {\n var e_2, _a;\n var _b, _c, _d;\n var concatSkills = __spreadArray(__spreadArray(__spreadArray([], __read(((_b = skills === null || skills === void 0 ? void 0 : skills.inProgress) !== null && _b !== void 0 ? _b : [])), false), __read(((_c = skills === null || skills === void 0 ? void 0 : skills.maintain) !== null && _c !== void 0 ? _c : [])), false), __read(((_d = skills === null || skills === void 0 ? void 0 : skills.needsImprovement) !== null && _d !== void 0 ? _d : [])), false);\n try {\n for (var concatSkills_1 = __values(concatSkills), concatSkills_1_1 = concatSkills_1.next(); !concatSkills_1_1.done; concatSkills_1_1 = concatSkills_1.next()) {\n var skill = concatSkills_1_1.value;\n if (skill.id === notification.targetId) {\n return {\n created: notification.created,\n id: notification.id,\n level: skill.current.level,\n priority: notification.priority,\n state: skill.current.state,\n targetId: notification.targetId,\n text: notification.title + \" \" + notification.text,\n title: skill.name,\n type: notification.type,\n viewed: notification.viewed,\n progress: skill.current.progress,\n };\n }\n }\n }\n catch (e_2_1) { e_2 = { error: e_2_1 }; }\n finally {\n try {\n if (concatSkills_1_1 && !concatSkills_1_1.done && (_a = concatSkills_1.return)) _a.call(concatSkills_1);\n }\n finally { if (e_2) throw e_2.error; }\n }\n return notification;\n };\n this.setupOutcomeNotification = function (notification, outcomes) {\n var e_3, _a;\n try {\n for (var _b = __values(outcomes !== null && outcomes !== void 0 ? outcomes : []), _c = _b.next(); !_c.done; _c = _b.next()) {\n var outcome = _c.value;\n if (outcome.id === notification.targetId) {\n return {\n created: notification.created,\n id: notification.id,\n priority: notification.priority,\n targetId: notification.targetId,\n text: notification.title + \" \" + notification.text,\n title: outcome.name,\n type: notification.type,\n viewed: notification.viewed,\n img: outcome.image,\n };\n }\n }\n }\n catch (e_3_1) { e_3 = { error: e_3_1 }; }\n finally {\n try {\n if (_c && !_c.done && (_a = _b.return)) _a.call(_b);\n }\n finally { if (e_3) throw e_3.error; }\n }\n return notification;\n };\n this.setupBadgeNotification = function (notification, badges) {\n var e_4, _a;\n try {\n for (var _b = __values(badges !== null && badges !== void 0 ? badges : []), _c = _b.next(); !_c.done; _c = _b.next()) {\n var badge = _c.value;\n if (badge.id === notification.targetId) {\n return {\n created: notification.created,\n id: notification.id,\n priority: notification.priority,\n targetId: notification.targetId,\n text: notification.title + \" \" + notification.text,\n title: badge.name,\n type: notification.type,\n viewed: notification.viewed,\n img: badge.image,\n };\n }\n }\n }\n catch (e_4_1) { e_4 = { error: e_4_1 }; }\n finally {\n try {\n if (_c && !_c.done && (_a = _b.return)) _a.call(_b);\n }\n finally { if (e_4) throw e_4.error; }\n }\n return notification;\n };\n this.setupAchievementNotification = function (notification, achievements) {\n var e_5, _a;\n try {\n for (var _b = __values(achievements !== null && achievements !== void 0 ? achievements : []), _c = _b.next(); !_c.done; _c = _b.next()) {\n var achievement = _c.value;\n if (achievement.id === notification.targetId) {\n return {\n created: notification.created,\n id: notification.id,\n priority: notification.priority,\n targetId: notification.targetId,\n text: notification.title + \" \" + notification.text,\n title: achievement.name,\n type: notification.type,\n viewed: notification.viewed,\n img: achievement.image,\n };\n }\n }\n }\n catch (e_5_1) { e_5 = { error: e_5_1 }; }\n finally {\n try {\n if (_c && !_c.done && (_a = _b.return)) _a.call(_b);\n }\n finally { if (e_5) throw e_5.error; }\n }\n return notification;\n };\n this.notificationSort = function (a, b) {\n if (a.priority > b.priority) {\n return -1;\n }\n else if (a.priority < b.priority) {\n return 1;\n }\n else {\n if (isBefore(new Date(a.created), new Date(b.created))) {\n return 1;\n }\n else if (isAfter(new Date(a.created), new Date(b.created))) {\n return -1;\n }\n else {\n return 0;\n }\n }\n };\n this.viewedNotifications = function (notifications) { return __awaiter(_this, void 0, void 0, function () {\n var ids;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n ids = __spreadArray(__spreadArray([], __read(notifications.newer), false), __read(notifications.older), false).map(function (notification) { return notification.id; });\n return [4, this.notificationsApi.viewedNotifications(ids)];\n case 1:\n _a.sent();\n return [2, undefined];\n }\n });\n }); };\n this.notificationsApi = new NotificationsApi(token, oid, tid, sid, clientType);\n this.skillApi = new SkillApi(token, oid, tid, sid, clientType);\n this.outcomeApi = new OutcomeApi(token, oid, tid, sid, clientType);\n this.showcaseApi = new ShowcaseApi(token, oid, tid, sid, clientType);\n }\n return NotificationService;\n}());\nexport { NotificationService };\n//# sourceMappingURL=NotificationService.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport NotificationCard from './NotificationCard';\nimport { NotificationsContext } from '../../contexts/NotificationsProvider';\nimport Loading from '../Loading';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useGetNotifications } from '../../hooks/useGetNotifications';\nimport { useViewedNotifications } from '../../hooks/useViewedNotifications';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n main: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n container: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n });\n});\nvar Notifications = function (_a) {\n var clientType = _a.clientType;\n var classes = useStyles();\n var _b = useContext(HeaderContext), setTitle = _b.setTitle, setTabs = _b.setTabs, setGoBack = _b.setGoBack;\n var notifications = useContext(NotificationsContext).notifications;\n var _c = __read(useState(false), 2), recivedData = _c[0], setRecievedData = _c[1];\n var _d = __read(useState(false), 2), viewed = _d[0], setViewed = _d[1];\n var getNotifications = useGetNotifications();\n var viewedNotifications = useViewedNotifications();\n useEffect(function () {\n setTitle('Notifications');\n setTabs(undefined);\n setGoBack(true);\n }, [setGoBack, setTabs, setTitle]);\n useEffect(function () {\n if (!recivedData) {\n getNotifications();\n setRecievedData(true);\n }\n }, [recivedData, getNotifications]);\n useEffect(function () {\n if (!viewed && notifications) {\n viewedNotifications();\n setViewed(true);\n }\n }, [viewed, notifications, viewedNotifications]);\n if (!notifications) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsx(\"main\", __assign({ className: classes.main }, { children: _jsxs(\"div\", __assign({ className: classes.container }, { children: [(notifications === null || notifications === void 0 ? void 0 : notifications.newer) && notifications.newer.length > 0 && (_jsx(NotificationCard, { clientType: clientType, title: \"New\", notifications: notifications.newer }, void 0)), (notifications === null || notifications === void 0 ? void 0 : notifications.older) && notifications.older.length > 0 && (_jsx(NotificationCard, { clientType: clientType, title: \"Earlier\", notifications: notifications.older }, void 0))] }), void 0) }), void 0));\n};\nexport default Notifications;\n//# sourceMappingURL=Notifications.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { NotificationsContext } from '../contexts/NotificationsProvider';\nimport { NotificationService } from '../services/NotificationService';\nimport { getToken } from '../utils/getToken';\nexport var useGetNotifications = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var setNotifications = useContext(NotificationsContext).setNotifications;\n var getNotifications = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, notificationService, notifications;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n notificationService = new NotificationService(newToken, oid, tid, '', clientType);\n return [4, notificationService.getNotifications()];\n case 2:\n notifications = _a.sent();\n if (!notifications) {\n return [2];\n }\n setNotifications(notifications);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getNotifications()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetNotifications.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { NotificationsContext } from '../contexts/NotificationsProvider';\nimport { NotificationService } from '../services/NotificationService';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nexport var useViewedNotifications = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var notifications = useContext(NotificationsContext).notifications;\n var getUser = useGetUser();\n var viewedNotifications = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, notificationService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!notifications) {\n return [2];\n }\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n notificationService = new NotificationService(newToken, oid, tid, '', clientType);\n return [4, notificationService.viewedNotifications(notifications)];\n case 2:\n _a.sent();\n return [4, getUser()];\n case 3:\n _a.sent();\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([viewedNotifications()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useViewedNotifications.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nimport { Box, FormLabel } from '@material-ui/core';\nimport FormControl from '@material-ui/core/FormControl';\nimport InputBase from '@material-ui/core/InputBase';\nimport MenuItem from '@material-ui/core/MenuItem';\nimport Select from '@material-ui/core/Select';\nimport { createStyles, makeStyles, withStyles } from '@material-ui/core/styles';\nimport { useContext, useState } from 'react';\nimport { LockContext } from '../contexts/LockContext';\nimport { useApiService } from '../services/ApiServiceProvider';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport Dialog from './Dialog';\nimport { Level } from '../types/enums';\nimport { OutcomeService } from '../services/OutcomeService';\nimport { SkillService } from '../services/SkillService';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { getToken } from '../utils/getToken';\nimport { useGetOutcomesData } from '../hooks/useGetOutcomesData';\nimport { useGetSkillsData } from '../hooks/useGetSkillsData';\nimport { isOutcome } from '../utils/isOutcome';\nvar BootstrapInput = withStyles(function (theme) {\n return createStyles({\n input: {\n borderRadius: 4,\n position: 'relative',\n backgroundColor: Colors.white,\n border: '1px solid #ced4da',\n fontSize: 16,\n padding: '10px 26px 10px 12px',\n transition: theme.transitions.create(['border-color', 'box-shadow']),\n fontFamily: 'Ubuntu',\n '&:focus': {\n borderRadius: 4,\n borderColor: '#80bdff',\n boxShadow: '0 0 0 0.2rem rgba(0,123,255,.25)',\n },\n },\n });\n})(InputBase);\nvar useStyles = makeStyles(function (theme) { return ({\n changeTargetLevel: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n}); });\nvar ChangeTargetLevel = function (_a) {\n var _b, _c, _d, _e, _f;\n var user = _a.user, skillOrOutcome = _a.skillOrOutcome, onAccept = _a.onAccept, changeTargetStyle = _a.changeTargetStyle;\n var typo = useTypography();\n var classes = useStyles();\n var _g = useMsal(), instance = _g.instance, accounts = _g.accounts;\n var account = useAccount(accounts[0]);\n var _h = useContext(TokenContext), ssoToken = _h.ssoToken, oid = _h.oid, tid = _h.tid, clientType = _h.clientType;\n var _j = __read(useState(false), 2), open = _j[0], setOpen = _j[1];\n var _k = __read(useState(skillOrOutcome.level), 2), level = _k[0], setLevel = _k[1];\n var _l = __read(useState(0), 2), unlockCost = _l[0], setUnlockCost = _l[1];\n var _m = useContext(LockContext), disabled = _m.disabled, setDisabled = _m.setDisabled;\n var ApiService = useApiService();\n var getSkillsData = useGetSkillsData();\n var getOutcomeDate = useGetOutcomesData();\n var type = isOutcome(skillOrOutcome) ? 'outcome' : 'skill';\n var handleChange = function (event) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, skillService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n setLevel(event.target.value);\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n skillService = new SkillService(newToken, oid, tid, clientType);\n if (!(type === 'outcome')) return [3, 3];\n return [4, outcomeService.getOutcomeUnlockCost(skillOrOutcome.id, event.target.value)];\n case 2:\n response = _a.sent();\n return [3, 5];\n case 3: return [4, skillService.getSkillUnlockCost(skillOrOutcome.id, event.target.value)];\n case 4:\n response = _a.sent();\n _a.label = 5;\n case 5:\n setUnlockCost(response !== null && response !== void 0 ? response : 0);\n setOpen(true);\n return [2];\n }\n });\n }); };\n var closeDialog = function () {\n setLevel(skillOrOutcome.level);\n setOpen(false);\n };\n var accepted = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setOpen(false);\n setDisabled(true);\n return [4, ApiService.changeTargetLevel(user, user.oid, level, skillOrOutcome.id, type, false, false)];\n case 1:\n _a.sent();\n if (!(type === 'outcome')) return [3, 3];\n return [4, getOutcomeDate()];\n case 2:\n _a.sent();\n return [3, 5];\n case 3: return [4, getSkillsData()];\n case 4:\n _a.sent();\n _a.label = 5;\n case 5:\n if (!onAccept) return [3, 7];\n return [4, onAccept()];\n case 6:\n _a.sent();\n _a.label = 7;\n case 7:\n setDisabled(false);\n return [2];\n }\n });\n }); };\n var hasAvailableTargetLevel = function (newTargetLevel) {\n if (isOutcome(skillOrOutcome)) {\n switch (newTargetLevel) {\n case Level.User:\n return skillOrOutcome.availableTargetLevels.includes(Level.User);\n case Level.Producer:\n return skillOrOutcome.availableTargetLevels.includes(Level.Producer);\n case Level.Master:\n return skillOrOutcome.availableTargetLevels.includes(Level.Master);\n }\n }\n else {\n switch (newTargetLevel) {\n case Level.User:\n return skillOrOutcome.userLevel !== undefined;\n case Level.Producer:\n return skillOrOutcome.producerLevel !== undefined;\n case Level.Master:\n return skillOrOutcome.masterLevel !== undefined;\n }\n }\n return false;\n };\n return (_jsxs(Box, __assign({ marginTop: 2 }, { children: [_jsxs(FormControl, __assign({ className: classes.changeTargetLevel, style: changeTargetStyle }, { children: [_jsxs(FormLabel, __assign({ \"aria-hidden\": true, id: \"target-label\", className: typo.caption, style: { marginRight: 8 } }, { children: [\"Your Target Level:\", ' '] }), void 0), _jsxs(Select, __assign({ style: { minWidth: 115 }, labelId: \"target-label\", id: \"change-target-level-select\", value: level, onChange: handleChange, input: _jsx(BootstrapInput, {}, void 0), disabled: disabled }, { children: [_jsx(MenuItem, __assign({ value: Level.User }, { children: \"User\" }), void 0), hasAvailableTargetLevel(Level.Producer) && _jsx(MenuItem, __assign({ value: Level.Producer }, { children: \"Producer\" }), void 0), hasAvailableTargetLevel(Level.Master) && _jsx(MenuItem, __assign({ value: Level.Master }, { children: \"Master\" }), void 0)] }), void 0)] }), void 0), _jsx(Dialog, { open: open, onClose: closeDialog, onAccept: accepted, title: 'Change Target Level', text: ((_b = user === null || user === void 0 ? void 0 : user.engagementPoints) !== null && _b !== void 0 ? _b : 0) < (unlockCost !== null && unlockCost !== void 0 ? unlockCost : 0)\n ? \"You do not have enough engagement points.\"\n : \"Your target level will change from \" + Level[(_c = skillOrOutcome.level) !== null && _c !== void 0 ? _c : Level.None] + \" to \" + Level[level] + \". \" + (level > ((_d = skillOrOutcome.level) !== null && _d !== void 0 ? _d : 0) && unlockCost !== 0\n ? \"Making this change will cost you \" + (unlockCost !== null && unlockCost !== void 0 ? unlockCost : 0) + \" engagement points, but by completing this target level you will earn even more points!\"\n : ''), cancelText: \"Cancel\", acceptText: ((_e = user === null || user === void 0 ? void 0 : user.engagementPoints) !== null && _e !== void 0 ? _e : 0) < (unlockCost !== null && unlockCost !== void 0 ? unlockCost : 0) ? undefined : 'Change', disabled: ((_f = user === null || user === void 0 ? void 0 : user.engagementPoints) !== null && _f !== void 0 ? _f : 0) < (unlockCost !== null && unlockCost !== void 0 ? unlockCost : 0) }, void 0)] }), void 0));\n};\nexport default ChangeTargetLevel;\n//# sourceMappingURL=ChangeTargetLevel.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Box, makeStyles, Paper } from '@material-ui/core';\nimport { format } from 'date-fns';\nimport { useState } from 'react';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport { BLOB_CONTAINER, OTHER_PATH } from '../utils/constants';\nimport Button from './buttons/Button';\nimport VideoDialog from './video/VideoDialog';\nimport { Play } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n detailOverview: (_a = {\n display: 'grid',\n gridTemplateColumns: 'auto auto',\n gridGap: 16,\n justifyItems: 'center',\n gridAutoFlow: 'dense',\n justifyContent: 'space-between',\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n marginTop: 32,\n marginBottom: 32\n },\n _a[theme.breakpoints.down('md')] = {\n gridTemplateColumns: 'auto',\n justifyContent: 'center',\n },\n _a),\n textContent: (_b = {\n marginRight: 60\n },\n _b[theme.breakpoints.down('md')] = {\n marginRight: 0,\n },\n _b),\n descriptionAssigned: (_c = {\n marginRight: 32\n },\n _c[theme.breakpoints.down('md')] = {\n marginRight: 0,\n },\n _c),\n video: function (_a) {\n var _b;\n var url = _a.url;\n return (_b = {\n backgroundImage: \"url(\" + url + \")\",\n backgroundSize: 'cover',\n backgroundRepeat: 'no-repeat',\n backgroundPosition: 'center',\n backgroundColor: '#EEEEF8',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n width: 433,\n minWidth: 433,\n height: 246,\n boxShadow: '0 5px 16px 1px rgba(0,0,0,0.08), 0 2px 8px 0 rgba(0,0,0,0.08)',\n gridColumn: 2\n },\n _b[theme.breakpoints.down('md')] = {\n width: 440,\n minWidth: 440,\n height: 250,\n gridColumn: 1,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: '100%',\n minWidth: 280,\n },\n _b);\n },\n videoButton: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n color: Colors.white,\n justifyContent: 'center',\n },\n videoIcon: {\n marginRight: 8,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n });\n});\nvar DetailsOverviewSkillsOrOutcomes = function (_a) {\n var videoOverviewId = _a.videoOverviewId, overviewImage = _a.overviewImage, assignerName = _a.assignerName, assignedDate = _a.assignedDate, description = _a.description, isAssigned = _a.isAssigned, rating = _a.rating, skillId = _a.skillId, getSkillOrOutcome = _a.getSkillOrOutcome, isOutcome = _a.isOutcome;\n var skillOrOutcomeText = isOutcome ? 'Outcome' : 'Skill';\n var url = overviewImage\n ? \"\" + OTHER_PATH + overviewImage\n : \"\" + OTHER_PATH + skillOrOutcomeText.toLowerCase() + \"_detail_video_thumbnail.jpg\";\n var typo = useTypography();\n var classes = useStyles({ url: url });\n var _b = __read(useState(false), 2), openVideoDialog = _b[0], setOpenVideoDialog = _b[1];\n var toggleVideoDialog = function () { return setOpenVideoDialog(!openVideoDialog); };\n var overviewContentData = {\n container: BLOB_CONTAINER,\n fileName: videoOverviewId + \".mp4\",\n contentId: videoOverviewId,\n views: 1,\n rating: rating,\n skillId: skillId,\n };\n return (_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: classes.detailOverview }, { children: [_jsx(\"div\", __assign({ className: classes.video }, { children: _jsx(Button, __assign({ onClick: toggleVideoDialog, style: { width: 225, minWidth: 225 } }, { children: _jsxs(\"span\", __assign({ className: classes.videoButton }, { children: [_jsx(\"span\", __assign({ \"aria-hidden\": true, className: classes.videoIcon }, { children: _jsx(Play, {}, void 0) }), void 0), \"Watch Overview\"] }), void 0) }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.textContent }, { children: [_jsx(Box, __assign({ marginBottom: 2 }, { children: _jsx(\"h2\", __assign({ className: typo.subtitle1, style: { marginBottom: 16 } }, { children: \"About this \" + skillOrOutcomeText }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.descriptionAssigned }, { children: [_jsx(\"p\", __assign({ className: typo.body1, style: { color: Colors.textPrimary, marginBottom: 16 } }, { children: description }), void 0), isAssigned ? (_jsx(_Fragment, { children: assignerName && assignedDate && (_jsx(\"span\", __assign({ className: typo.caption, style: { marginTop: 16 } }, { children: \"Assigned by \" + assignerName + \" on \" + format(new Date(assignedDate), 'PP') }), void 0)) }, void 0)) : (_jsx(\"span\", __assign({ className: typo.caption, style: { marginTop: 16 } }, { children: \"This \" + skillOrOutcomeText + \" is not currently part of your \" + skillOrOutcomeText + \"s.\" }), void 0))] }), void 0)] }), void 0), overviewContentData && (_jsx(VideoDialog, { open: openVideoDialog, onClose: toggleVideoDialog, contentData: overviewContentData, getSkillOrOutcome: getSkillOrOutcome }, void 0))] }), void 0));\n};\nexport default DetailsOverviewSkillsOrOutcomes;\n//# sourceMappingURL=DetailsOverviewSkillsOrOutcomes.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { makeStyles, Paper } from '@material-ui/core';\nimport { CompetenceState, UpgradeRequestType } from '../types/enums';\nimport { UserContext } from '../contexts/UserContext';\nimport Button from './buttons/Button';\nimport { useGetUser } from '../hooks/useGetUser';\nimport { isOutcome } from '../utils/isOutcome';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n requestCompleteNotification: (_a = {\n borderRadius: 4,\n border: 'solid 1px rgba(101,78,163,0.12)',\n backgroundImage: 'linear-gradient(to bottom, #ffffff, #fafafa), linear-gradient(to bottom, #ffffff, #ffffff)',\n textAlign: 'center',\n padding: 32\n },\n _a[theme.breakpoints.down('md')] = {\n padding: 16,\n },\n _a),\n title: (_b = {\n fontFamily: 'Ubuntu',\n fontSize: 24,\n fontWeight: 600,\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.17,\n letterSpacing: 'normal',\n textAlign: 'center',\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 16\n },\n _b[theme.breakpoints.down('md')] = {\n marginBottom: 8,\n fontSize: 16,\n lineHeight: '24px',\n letterSpacing: 0.15,\n },\n _b),\n subtitle: (_c = {\n fontFamily: 'Open Sans',\n fontSize: 16,\n fontWeight: 'normal',\n fontStyle: 'normal',\n fontStretch: 'normal',\n lineHeight: 1.5,\n letterSpacing: 0.5,\n textAlign: 'center',\n color: 'rgba(0, 0, 0, 0.88)'\n },\n _c[theme.breakpoints.down('md')] = {\n fontSize: 14,\n lineHeight: '20px',\n letterSpacing: 0.1,\n },\n _c),\n });\n});\nvar UnavailablePanel = function (_a) {\n var skillOrOutcome = _a.skillOrOutcome, noBorder = _a.noBorder;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var getUser = useGetUser();\n var requestUpgrade = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, getUser()];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n return (_jsx(_Fragment, { children: skillOrOutcome.current.state === CompetenceState.LockedCollectorVersion ? (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.requestCompleteNotification, style: noBorder ? { border: 'none' } : undefined }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: isOutcome(skillOrOutcome) ? 'This Outcome is unavailable' : 'This Skill is unavailable' }), void 0), _jsx(\"div\", __assign({ className: classes.subtitle }, { children: isOutcome(skillOrOutcome)\n ? 'To access this Outcome, you must be working on the most-current version of Nulia Works. Reach out to your Nulia Works admin to find out more.'\n : 'To access this Skill, you must be working on the most-current version of Nulia Works. Reach out to your Nulia Works admin to find out more.' }), void 0)] }), void 0)) : skillOrOutcome.current.state === CompetenceState.LockedHardhat ? (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.requestCompleteNotification, style: noBorder ? { border: 'none' } : undefined }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: isOutcome(skillOrOutcome)\n ? 'This Outcome is under construction'\n : 'This Skill is under construction' }), void 0), _jsx(\"div\", __assign({ className: classes.subtitle }, { children: isOutcome(skillOrOutcome)\n ? 'Get a sneak peek of what this Outcome has to offer by watching its overview video and seeing what Skills are included. Check back to see when it’s ready to be assigned '\n : 'Get a sneak peek of what this Skill has to offer by watching its overview video. Check back to see when it’s ready to be assigned ' }), void 0)] }), void 0)) : skillOrOutcome.current.state === CompetenceState.LockedEdu ? (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.requestCompleteNotification, style: noBorder ? { border: 'none' } : undefined }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: isOutcome(skillOrOutcome) ? 'This Outcome is unavailable' : 'This Skill is unavailable' }), void 0), _jsx(\"div\", __assign({ className: classes.subtitle }, { children: isOutcome(skillOrOutcome)\n ? 'To access this Outcome, you need a specific Microsoft 365 license. Reach out to your Nulia Works admin to find out more. '\n : 'To access this Skill, you need a specific Microsoft 365 license. Reach out to your Nulia Works admin to find out more. ' }), void 0)] }), void 0)) : skillOrOutcome.current.state === CompetenceState.LockedStarter ? (_jsx(Paper, __assign({ elevation: 1, component: \"section\", className: classes.requestCompleteNotification, style: noBorder ? { border: 'none' } : undefined }, { children: (user === null || user === void 0 ? void 0 : user.upgradeRequest) !== UpgradeRequestType.Requested ? (_jsxs(_Fragment, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: \"There's more waiting for you in Nulia Works Complete\" }), void 0), _jsx(\"div\", __assign({ className: classes.subtitle }, { children: \"Continue to move closer to your goals & unlock more Outcomes and badges by adding your voice to request Nulia Works Complete.\" }), void 0), _jsx(Button, __assign({ onClick: requestUpgrade, style: { width: 219, marginTop: 24 } }, { children: \"Request Complete Access\" }), void 0)] }, void 0)) : (_jsxs(_Fragment, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: \"Your Request for Nulia Complete is Pending\" }), void 0), _jsx(\"div\", __assign({ className: classes.subtitle }, { children: \"Your request for Nulia Works Complete has been submitted.\" }), void 0)] }, void 0)) }), void 0)) : undefined }, void 0));\n};\nexport default UnavailablePanel;\n//# sourceMappingURL=UnavailablePanel.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Accordion as MuiAccordion, AccordionDetails, AccordionSummary } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { forwardRef, useState } from 'react';\nimport { useTypography } from '../styles/Typography';\nimport { Colors } from '../utils/colors';\nimport SkillIconContainer from './skills/SkillIconContainer';\nimport { ChevronDown } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n accordion: (_a = {\n backgroundColor: Colors.white,\n borderRadius: 4\n },\n _a[theme.breakpoints.up('md')] = {\n padding: '0 8px',\n },\n _a),\n header: {\n height: 72,\n '& .MuiAccordionSummary-content': {\n display: 'grid',\n gridTemplateColumns: 'auto 1fr auto',\n gridGap: 16,\n alignItems: 'center',\n paddingRight: 16,\n },\n },\n content: {\n paddingBottom: 24,\n },\n });\n});\nvar Accordion = forwardRef(function (_a, ref) {\n var title = _a.title, subtitle = _a.subtitle, children = _a.children, startExpanded = _a.startExpanded, icon = _a.icon, noChevron = _a.noChevron;\n var typo = useTypography();\n var _b = __read(useState(!!startExpanded), 2), expanded = _b[0], setExpanded = _b[1];\n var classes = useStyles();\n var handleExpand = function () { return setExpanded(!expanded); };\n return (_jsxs(MuiAccordion, __assign({ ref: ref, expanded: expanded, onChange: handleExpand, className: classes.accordion }, { children: [_jsxs(AccordionSummary, __assign({ expandIcon: !noChevron && _jsx(ChevronDown, {}, void 0), IconButtonProps: { edge: 'start' }, className: classes.header, \"aria-controls\": title + \"-content\", id: title + \"-header\" }, { children: [_jsx(SkillIconContainer, { children: icon }, void 0), _jsx(\"h3\", __assign({ className: typo.subtitle2 }, { children: title }), void 0), subtitle && (_jsx(\"span\", __assign({ className: typo.caption, style: {\n color: 'rgba(0, 0, 0, 0.6)',\n textTransform: 'uppercase',\n } }, { children: subtitle }), void 0))] }), void 0), _jsx(AccordionDetails, __assign({ className: classes.content }, { children: children }), void 0)] }), void 0));\n});\nAccordion.displayName = 'Accordion';\nexport default Accordion;\n//# sourceMappingURL=Accordion.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Lock } from 'react-feather';\nimport { Colors } from '../../utils/colors';\nvar useStyles = makeStyles({\n skillLockedIcon: {\n position: 'relative',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n skillIcon: {\n position: 'absolute',\n },\n lockIcon: {\n position: 'absolute',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n height: 28,\n width: 28,\n },\n});\nvar SkillLockedIcon = function (_a) {\n var skillIcon = _a.skillIcon;\n var classes = useStyles();\n return (_jsxs(\"div\", __assign({ className: classes.skillLockedIcon }, { children: [_jsx(\"div\", __assign({ className: classes.skillIcon }, { children: skillIcon }), void 0), _jsx(\"div\", __assign({ className: classes.lockIcon }, { children: _jsx(Lock, { style: { width: 14, height: 14, color: Colors.textSecondary } }, void 0) }), void 0)] }), void 0));\n};\nexport default SkillLockedIcon;\n//# sourceMappingURL=SkillLockedIcon.js.map","export var levelToName = new Map([\n [0, 'None'],\n [1, 'User'],\n [2, 'Producer'],\n [3, 'Master'],\n]);\n//# sourceMappingURL=levelToName.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { differenceInDays } from 'date-fns';\nimport { forwardRef, useContext, useEffect, useState } from 'react';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport Accordion from '../Accordion';\nimport Activity from '../Activity';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport Dialog from '../Dialog';\nimport EngagementPointsIcon from '../icons/EngagementPointsIcon';\nimport SkillLockedIcon from './SkillLockedIcon';\nimport LevelIcon from '../LevelIcon';\nimport Loading from '../Loading';\nimport { CompetenceState } from '../../types/enums';\nimport { levelToName } from '../../utils/levelToName';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n levelContent: (_a = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n _a),\n levelActivities: (_b = {\n width: 647\n },\n _b[theme.breakpoints.down('md')] = {\n width: 622,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _b),\n levelHints: (_c = {\n width: 318,\n backgroundColor: Colors.background,\n paddingTop: 16,\n paddingLeft: 24,\n paddingRight: 24,\n paddingBottom: 24\n },\n _c[theme.breakpoints.down('md')] = {\n marginTop: 16,\n width: 622,\n },\n _c[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _c),\n hintText: {\n fontFamily: 'Open Sans',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: 14,\n lineHeight: '20px',\n color: 'rgba(0,0,0,0.8)',\n listStyle: 'disc',\n },\n innerHint: {\n marginBottom: 24,\n },\n hintList: {\n margin: 0,\n },\n activity: {\n border: '1px solid rgba(0,0,0,0.12)',\n borderRadius: 4,\n padding: 24,\n },\n innerActivity: {\n marginBottom: 16,\n },\n hintIconContainer: {\n paddingRight: 10,\n },\n hintLockedButton: {\n height: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n },\n });\n});\nvar DaysInAWeek = 7;\nvar SkillLevel = forwardRef(function (_a, ref) {\n var skill = _a.skill, levelData = _a.levelData, level = _a.level, startOpen = _a.startOpen, clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = __read(useState(false), 2), openBuyHintDialog = _b[0], setOpenBuyHintDialog = _b[1];\n var _c = __read(useState(levelData.hints), 2), hint = _c[0], setHint = _c[1];\n var _d = __read(useState(false), 2), disabled = _d[0], setDisabled = _d[1];\n var theme = useTheme();\n var isMediumDown = useMediaQuery(theme.breakpoints.down('md'));\n var ApiService = useApiService();\n useEffect(function () {\n setHint(levelData.hints);\n }, [skill.id, levelData.hints]);\n useEffect(function () {\n if ([CompetenceState.InProgress, CompetenceState.NeedsAttention].includes(levelData.state)) {\n setDisabled(false);\n }\n }, [levelData.state, levelData.level, skill]);\n var name = levelToName.get(levelData.level);\n var locked = levelData.state === CompetenceState.Locked;\n var daysSinceAchieved = differenceInDays(new Date(), new Date(levelData.achieved)) + 1;\n var progress = skill.current.targetLevel !== levelData.level ? 0 : skill.current.progress;\n var hintCost = Math.floor(200 * (1 - progress / 100) + 50);\n var hintUnlockText = \"Need some help? Unlock action items on how to complete this level with \" + hintCost + \" engagement points.\";\n var longestStreak = levelData.longestStreak <= DaysInAWeek\n ? \"Longest Streak was \" + levelData.longestStreak + \" \" + (levelData.longestStreak === 1 ? 'day' : 'days')\n : \"Longest Streak was \" + Math.floor(levelData.longestStreak / DaysInAWeek) + \" \" + (Math.floor(levelData.longestStreak / DaysInAWeek) === 1 ? 'week' : 'weeks');\n var demonstrationStreak = daysSinceAchieved <= DaysInAWeek\n ? \"Maintaining for \" + daysSinceAchieved + \" \" + (daysSinceAchieved === 1 ? 'day' : 'days')\n : \"Maintaining for \" + Math.floor(daysSinceAchieved / DaysInAWeek) + \" \" + (Math.floor(daysSinceAchieved / DaysInAWeek) === 1 ? 'week' : 'weeks');\n var toggleBuyHintDialog = function () { return setOpenBuyHintDialog(!openBuyHintDialog); };\n var buyHint = function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n var _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0:\n if (!user) {\n return [2];\n }\n toggleBuyHintDialog();\n return [4, ApiService.buyHint(user, skill.id, levelData.level)];\n case 1:\n response = _b.sent();\n if (!response) {\n return [2];\n }\n setHint((_a = response.data[level]) === null || _a === void 0 ? void 0 : _a.hints);\n return [2];\n }\n });\n }); };\n if (!user) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(_Fragment, { children: [_jsx(Accordion, __assign({ ref: ref, title: name ? name : '', subtitle: !isMediumDown\n ? levelData.achieved && levelData.state === CompetenceState.Maintain\n ? demonstrationStreak\n : levelData.state === CompetenceState.NeedsAttention\n ? longestStreak\n : levelData.level === skill.current.targetLevel\n ? 'Target Level'\n : undefined\n : undefined, icon: !locked ? (_jsx(LevelIcon, { progress: levelData.progress, level: levelData.level, state: levelData.state, type: \"skill\" }, void 0)) : (_jsx(SkillLockedIcon, { skillIcon: _jsx(LevelIcon, { progress: 0, level: levelData.level, state: CompetenceState.Unassigned, type: \"skill\" }, void 0) }, void 0)), startExpanded: startOpen }, { children: _jsxs(\"div\", __assign({ className: classes.levelContent }, { children: [_jsx(\"div\", __assign({ className: classes.levelActivities }, { children: levelData.activities.map(function (activity, index, array) { return (_jsx(\"div\", __assign({ className: clsx(classes.activity, index < array.length - 1 ? classes.innerActivity : undefined) }, { children: _jsx(Activity, { activity: activity, skillId: skill.id, headingLevel: 4, home: false, clientType: clientType }, void 0) }), activity.text)); }) }), void 0), _jsxs(\"div\", __assign({ className: classes.levelHints }, { children: [_jsx(\"h4\", __assign({ className: typo.caption }, { children: \"ACTION ITEMS\" }), void 0), !hint ? (_jsxs(\"div\", { children: [_jsx(\"span\", __assign({ className: typo.subtitle2 }, { children: hintUnlockText }), void 0), _jsx(SecondaryButton, __assign({ \"aria-label\": \"Unlock \" + name + \" action item for \" + hintCost + \" engagement points\", onClick: toggleBuyHintDialog, style: { width: '100%', marginTop: 16 }, disabled: locked || disabled }, { children: _jsxs(\"span\", __assign({ className: classes.hintLockedButton }, { children: [_jsx(EngagementPointsIcon, { small: true }, void 0), _jsxs(\"span\", __assign({ className: typo.subtitle2, style: { marginLeft: 8 } }, { children: [\"Unlock Action Items (\", hintCost, \")\"] }), void 0)] }), void 0) }), void 0)] }, void 0)) : (_jsx(\"ul\", __assign({ className: classes.hintList }, { children: hint.hints.map(function (hint, index, array) { return (_jsx(\"li\", __assign({ className: clsx(classes.hintText, index < array.length - 1 ? classes.innerHint : undefined) }, { children: hint }), hint)); }) }), void 0))] }), void 0)] }), void 0) }), void 0), _jsx(Dialog, { open: openBuyHintDialog, onClose: toggleBuyHintDialog, onAccept: user.engagementPoints >= hintCost ? buyHint : toggleBuyHintDialog, title: 'Unlock action items?', text: user.engagementPoints >= hintCost\n ? \"Do you want to unlock this level's action items for \" + hintCost + \" engagement points?\"\n : \"You do not have enough engagement points to unlock this level's action items.\", cancelText: user.engagementPoints >= hintCost ? 'NO' : undefined, acceptText: user.engagementPoints >= hintCost ? 'YES' : 'OKAY' }, void 0)] }, void 0));\n});\nSkillLevel.displayName = 'SkillLevel';\nexport default SkillLevel;\n//# sourceMappingURL=SkillLevel.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { ButtonBase, Paper, useTheme, useMediaQuery } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useEffect, useRef, useState } from 'react';\nimport { useHistory, useParams } from 'react-router';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useTypography } from '../../styles/Typography';\nimport AddButton from '../buttons/AddButton';\nimport RemoveButton from '../buttons/RemoveButton';\nimport UnavailableButton from '../buttons/UnavailableButton';\nimport ChangeTargetLevel from '../ChangeTargetLevel';\nimport DetailsOverviewSkillsOrOutcomes from '../DetailsOverviewSkillsOrOutcomes';\nimport LevelIcon from '../LevelIcon';\nimport Loading from '../Loading';\nimport { SkillProgressBar } from '../SkillProgressBar';\nimport UnavailablePanel from '../UnavailablePanel';\nimport SkillLevel from './SkillLevel';\nimport { Colors } from '../../utils/colors';\nimport { SkillsContext } from '../../contexts/SkillsContext';\nimport Outcome from '../outcomes/Outcome';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport { ClientType, CompetenceState, Level, Pages } from '../../types/enums';\nimport NextLastUpdated from '../NextLastUpdated';\nimport { useGetSkillDetails } from '../../hooks/useGetSkillDetails';\nimport { useGetSkillsData } from '../../hooks/useGetSkillsData';\nimport { isStarterCustomer } from '../../utils/isStarterCustomer';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { APPLICATION_ID } from '../../utils/constants';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f, _g;\n return ({\n skillDetails: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n root: (_a = {\n width: 1040,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center'\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n name: (_b = {\n marginLeft: 16\n },\n _b[theme.breakpoints.down('md')] = {\n lineHeight: '40px',\n },\n _b[theme.breakpoints.down('sm')] = {\n fontSize: 16,\n lineHeight: 1,\n },\n _b),\n iconTitlePace: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n width: '100%',\n },\n iconTitle: {\n display: 'flex',\n alignItems: 'flex-start',\n },\n progressPercent: (_c = {\n display: 'flex',\n alignItems: 'center',\n marginTop: 20\n },\n _c[theme.breakpoints.down('sm')] = {\n marginTop: 12,\n },\n _c),\n section: (_d = {\n width: 1040\n },\n _d[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _d[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _d),\n top: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n titleProgress: (_e = {\n width: 714,\n minWidth: 714\n },\n _e[theme.breakpoints.down('md')] = {\n width: '80%',\n minWidth: 500,\n },\n _e[theme.breakpoints.down('sm')] = {\n width: '100%',\n minWidth: 250,\n maxWidth: 350,\n },\n _e),\n addSkill: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n marginLeft: 24,\n },\n addText: (_f = {\n marginTop: 8,\n textAlign: 'center'\n },\n _f[theme.breakpoints.up('sm')] = {\n fontSize: 12,\n lineHeight: '14px',\n },\n _f),\n activities: {\n display: 'grid',\n gridGap: 16,\n marginBottom: 32,\n },\n requestComplete: {\n padding: 0,\n borderRadius: 4,\n marginTop: 24,\n marginBottom: 24,\n },\n textButton: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n },\n unavailablePanel: {\n padding: 0,\n borderRadius: 4,\n marginTop: 24,\n marginBottom: 24,\n },\n outcomes: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n padding: 24,\n paddingTop: 16,\n marginTop: 8,\n marginBottom: 32,\n },\n outcomeList: (_g = {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-start'\n },\n _g[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n },\n _g),\n });\n});\nvar SkillDetail = function (_a) {\n var _b, _c, _d, _e, _f, _g, _h;\n var clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var skillId = useParams().skillId;\n var user = useContext(UserContext).user;\n var _j = useContext(HeaderContext), setTitle = _j.setTitle, setGoBack = _j.setGoBack, setTabs = _j.setTabs;\n var allOutcomes = useContext(SkillsContext).allOutcomes;\n var _k = __read(useState(false), 2), fetchedSkill = _k[0], setFetchedSkill = _k[1];\n var _l = __read(useState(undefined), 2), skill = _l[0], setSkill = _l[1];\n var userLevelRef = useRef(null);\n var producerLevelRef = useRef(null);\n var masterLevelRef = useRef(null);\n var activitiesRef = useRef(null);\n var getData = useGetSkillsData();\n var history = useHistory();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var getSkillDetails = useGetSkillDetails();\n var accept = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getSkillDetails(Number(skillId), setSkill)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n useEffect(function () {\n setTitle('Back');\n setTabs(undefined);\n setGoBack(true);\n }, [setGoBack, setTabs, setTitle]);\n useEffect(function () {\n if (!fetchedSkill) {\n getSkillDetails(Number(skillId), setSkill);\n setFetchedSkill(true);\n }\n }, [skill, getSkillDetails, skillId, fetchedSkill]);\n useEffect(function () {\n if (window.location.href.includes('#user-level') && userLevelRef.current) {\n userLevelRef.current.scrollIntoView();\n }\n else if (window.location.href.includes('#producer-level') && producerLevelRef.current) {\n producerLevelRef.current.scrollIntoView();\n }\n else if (window.location.href.includes('#master-level') && masterLevelRef.current) {\n masterLevelRef.current.scrollIntoView();\n }\n else if (window.location.href.includes('#activities') && activitiesRef.current) {\n activitiesRef.current.scrollIntoView();\n }\n });\n if (!skill) {\n return _jsx(Loading, {}, void 0);\n }\n var unavailable = isUnavailable(skill.current.state);\n var starter = isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass);\n var openOutcome = function (id) {\n if (clientType === ClientType.platform) {\n history.push(\"/outcome-details/\" + id);\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/b7220f97-2970-49dc-b5f7-d357d69fd1e3?context={\\\"subEntityId\\\": \" + id + \"}\");\n }\n };\n return (_jsx(\"main\", __assign({ className: classes.skillDetails }, { children: _jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsx(NextLastUpdated, {}, void 0), _jsxs(\"header\", __assign({ className: clsx(classes.top, classes.section) }, { children: [_jsxs(\"div\", __assign({ className: classes.titleProgress }, { children: [_jsx(\"div\", __assign({ className: classes.iconTitlePace }, { children: _jsxs(\"div\", __assign({ className: classes.iconTitle }, { children: [_jsx(\"div\", __assign({ style: { marginTop: 6 } }, { children: _jsx(LevelIcon, { progress: skill.current.progress, level: skill.current.level, state: skill.current.state, type: \"skill\" }, void 0) }), void 0), _jsx(\"h1\", __assign({ id: skill.id.toString(), className: clsx(typo.h4, classes.name) }, { children: skill.name }), void 0)] }), void 0) }), void 0), !unavailable && !(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) && (_jsxs(\"div\", __assign({ className: classes.progressPercent }, { children: [_jsx(SkillProgressBar, { currentState: skill.current.state, progress: skill.current.progress }, void 0), !isSmDown && !(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) && (_jsx(\"p\", __assign({ \"aria-hidden\": true, className: typo.body1, style: { marginLeft: 8 } }, { children: skill.current.progress + \"%\" }), void 0))] }), void 0))] }), void 0), _jsxs(\"div\", __assign({ className: classes.addSkill }, { children: [unavailable ? (_jsx(UnavailableButton, { skillOrOutcome: skill }, void 0)) : skill.isAssigned ? (_jsx(RemoveButton, { user: user, skillOrOutcome: skill, level: Level.None, recommended: false, onAccept: accept, describedById: skill.id.toString(), starter: starter }, void 0)) : (_jsx(AddButton, { user: user, skillOrOutcome: skill, level: Level.User, recommended: false, onAccept: accept, describedById: skill.id.toString(), starter: starter }, void 0)), !unavailable && !isMdDown && (_jsx(\"span\", __assign({ className: clsx(typo.caption, classes.addText) }, { children: skill.current.state === CompetenceState.Unassigned ||\n skill.current.state === CompetenceState.Locked\n ? 'ADD TO YOUR SKILLS'\n : 'IN YOUR SKILLS' }), void 0))] }), void 0)] }), void 0), skill.isAssigned && (_jsx(\"div\", __assign({ className: classes.section }, { children: _jsx(ChangeTargetLevel, { user: user, skillOrOutcome: skill, onAccept: function () { return getSkillDetails(Number(skillId), setSkill); }, changeTargetStyle: isSmDown ? { justifyContent: 'space-between' } : undefined }, void 0) }), void 0)), _jsx(\"section\", __assign({ className: classes.section }, { children: _jsx(DetailsOverviewSkillsOrOutcomes, { videoOverviewId: skill.videoOverviewId, overviewImage: (_b = skill.overviewImage) !== null && _b !== void 0 ? _b : '', description: skill.challenge + \" \" + skill.mission, assignerName: (_e = (_d = (_c = skill.userLevel) === null || _c === void 0 ? void 0 : _c.assignment) === null || _d === void 0 ? void 0 : _d.assignerName) !== null && _e !== void 0 ? _e : '', assignedDate: (_h = (_g = (_f = skill.userLevel) === null || _f === void 0 ? void 0 : _f.assignment) === null || _g === void 0 ? void 0 : _g.dateTime) !== null && _h !== void 0 ? _h : '', isAssigned: skill === null || skill === void 0 ? void 0 : skill.isAssigned, rating: skill.videoOverviewRating, skillId: skill.id, getSkillOrOutcome: function () { return getSkillDetails(Number(skillId), setSkill); } }, void 0) }), void 0), unavailable && (_jsx(\"div\", __assign({ className: clsx(classes.section, classes.unavailablePanel) }, { children: _jsx(UnavailablePanel, { skillOrOutcome: skill, noBorder: true }, void 0) }), void 0)), !unavailable && (skill.userLevel || skill.producerLevel || skill.masterLevel) && (_jsxs(\"section\", __assign({ \"aria-labelledby\": \"activities\", className: clsx(classes.activities, classes.section), ref: activitiesRef }, { children: [_jsx(\"h2\", __assign({ className: typo.subtitle2, id: \"activities\" }, { children: \"ACTIVITIES\" }), void 0), skill.userLevel && (_jsx(SkillLevel, { ref: userLevelRef, skill: skill, levelData: skill.userLevel, level: 'userLevel', startOpen: skill.current.level === 1, clientType: clientType }, void 0)), skill.producerLevel && (_jsx(SkillLevel, { ref: producerLevelRef, skill: skill, levelData: skill.producerLevel, level: 'producerLevel', startOpen: skill.current.level === 2, clientType: clientType }, void 0)), skill.masterLevel && (_jsx(SkillLevel, { ref: masterLevelRef, skill: skill, levelData: skill.masterLevel, level: 'masterLevel', startOpen: skill.current.level === 3, clientType: clientType }, void 0))] }), void 0)), !unavailable && skill.outcomes.length > 0 && allOutcomes && (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: clsx(classes.section, classes.outcomes) }, { children: [_jsx(\"p\", __assign({ className: typo.overline }, { children: \"INCLUDED IN THESE OUTCOMES\" }), void 0), _jsx(\"div\", __assign({ className: classes.outcomeList }, { children: skill.outcomes.map(function (outcomeId, index, array) {\n var outcome = allOutcomes === null || allOutcomes === void 0 ? void 0 : allOutcomes.find(function (outcome) { return outcome.id === outcomeId; });\n if (!outcome) {\n return undefined;\n }\n else {\n return (_jsx(ButtonBase, __assign({ onClick: function () { return openOutcome(outcome.id); }, style: { width: '100%', textAlign: 'left' } }, { children: _jsx(Outcome, { outcome: outcome, describedById: '', noLink: true, noStreak: true, page: Pages.None }, void 0) }), outcome.id));\n }\n }) }), void 0)] }), void 0))] }), void 0) }), void 0));\n};\nexport default SkillDetail;\n//# sourceMappingURL=SkillDetails.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { SkillsContext } from '../contexts/SkillsContext';\nimport { SkillService } from '../services/SkillService';\nimport { OutcomeService } from '../services/OutcomeService';\nimport { getToken } from '../utils/getToken';\nexport var useGetSkillDetails = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var skillsContext = useContext(SkillsContext);\n var getSkillDetails = function (skillId, setSkill) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getSkillDetails(skillId)];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setSkill(response);\n return [2];\n }\n });\n }); };\n var getAllOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, allOutcomes;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (skillsContext.allOutcomes) {\n return [2];\n }\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getAllOutcomes()];\n case 2:\n allOutcomes = _a.sent();\n if (!allOutcomes) {\n return [2];\n }\n skillsContext.setAllOutcomes(allOutcomes);\n return [2];\n }\n });\n }); };\n return function (skillId, setSkill) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getSkillDetails(skillId, setSkill), getAllOutcomes()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetSkillDetails.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { isAfter, isBefore } from 'date-fns';\nimport { useContext, useState } from 'react';\nimport { OutcomesContext } from '../../contexts/OutcomesContext';\nimport AllSkillsOrOutcomes from '../AllSkillsOrOutcomes';\nimport Loading from '../Loading';\nimport { CompetenceState } from '../../types/enums';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { isUnassigned } from '../../utils/isUnassigned';\nexport var getSortedOutcomes = function (sortOrder, outcomes) {\n var sorted = __spreadArray([], __read(outcomes), false);\n switch (sortOrder) {\n case 'newest': {\n sorted.sort(function (a, b) {\n if (a.current.state === CompetenceState.LockedHardhat &&\n b.current.state !== CompetenceState.LockedHardhat) {\n return 1;\n }\n else if (a.current.state !== CompetenceState.LockedHardhat &&\n b.current.state === CompetenceState.LockedHardhat) {\n return -1;\n }\n if (isBefore(new Date(a.created), new Date(b.created))) {\n return 1;\n }\n else if (isAfter(new Date(a.created), new Date(b.created))) {\n return -1;\n }\n else {\n return 0;\n }\n });\n break;\n }\n case 'name': {\n sorted.sort(function (a, b) {\n if (a.name < b.name) {\n return -1;\n }\n else if (a.name > b.name) {\n return 1;\n }\n else {\n return 0;\n }\n });\n break;\n }\n case 'progress': {\n sorted.sort(function (a, b) {\n if (a.current.progress > b.current.progress) {\n return -1;\n }\n else if (a.current.progress < b.current.progress) {\n return 1;\n }\n else {\n return 0;\n }\n });\n break;\n }\n default: {\n break;\n }\n }\n return sorted;\n};\nexport var getFilteredOutcomes = function (search, filters, outcomes) {\n var allOutcomes = __spreadArray([], __read(outcomes), false);\n var searchedByName = allOutcomes.filter(function (outcome) {\n return outcome.name.toLowerCase().trim().includes(search.toLowerCase().trim());\n });\n var searchedByKeywords = allOutcomes.filter(function (outcome) {\n return outcome.keywords.toLowerCase().trim().includes(search.toLowerCase().trim());\n });\n var filteredOutcomes = [];\n var afterSearchOutcomes = __spreadArray(__spreadArray([], __read(searchedByName), false), __read(searchedByKeywords), false);\n if (filters['mythings']) {\n afterSearchOutcomes = afterSearchOutcomes.filter(function (outcome) { return !isUnavailable(outcome.current.state) && !isUnassigned(outcome.current.state); });\n }\n else if (filters['notmythings']) {\n afterSearchOutcomes = afterSearchOutcomes.filter(function (outcome) { return isUnavailable(outcome.current.state) || isUnassigned(outcome.current.state); });\n }\n for (var key in filters) {\n if (!filters[key]) {\n continue;\n }\n var newFilteredOutcomes = [];\n switch (key) {\n case 'sharepoint': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'SharePoint'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'onedrive': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'OneDrive'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'yammer': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Yammer'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'onenote': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'OneNote'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'word': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Word'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'excel': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Excel'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'powerpoint': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'PowerPoint'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'teams': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Teams'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'outlook': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Outlook'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'office365': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Office 365'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'microsoft365': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Microsoft 365'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'delve': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Delve'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'planner': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Planner'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'todo': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'To-Do'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'forms': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Forms'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'powerAutomate': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Power Automate'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'bookings': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Bookings'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'edge': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Edge'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'intune': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'Intune'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n case 'myapps': {\n newFilteredOutcomes = afterSearchOutcomes.filter(function (outcome) {\n return outcome.apps.find(function (app) { return app.name === 'My Apps'; });\n });\n filteredOutcomes = __spreadArray(__spreadArray([], __read(filteredOutcomes), false), __read(newFilteredOutcomes), false);\n break;\n }\n default: {\n break;\n }\n }\n }\n var seenOutcomes = new Set();\n var finalFilteredOutcomes = [];\n var hasFilters = false;\n for (var key in filters) {\n if (filters[key] && !['mythings', 'notmythings'].includes(key)) {\n hasFilters = true;\n break;\n }\n }\n if (filteredOutcomes.length === 0 && !hasFilters) {\n filteredOutcomes = __spreadArray([], __read(afterSearchOutcomes), false);\n }\n filteredOutcomes.forEach(function (outcome) {\n if (!seenOutcomes.has(outcome)) {\n seenOutcomes.add(outcome);\n finalFilteredOutcomes.push(outcome);\n }\n });\n return finalFilteredOutcomes;\n};\nvar AllOutcomes = function (_a) {\n var page = _a.page;\n var _b = useContext(OutcomesContext), allOutcomes = _b.allOutcomes, filtersOutcomes = _b.filtersOutcomes, setFiltersOutcomes = _b.setFiltersOutcomes;\n var _c = __read(useState('name'), 2), sortOrder = _c[0], setSortOrder = _c[1];\n var _d = __read(useState(''), 2), search = _d[0], setSearch = _d[1];\n var _e = __read(useState({\n mythings: true,\n notmythings: true,\n all: true,\n sharepoint: true,\n onedrive: true,\n yammer: true,\n onenote: true,\n word: true,\n excel: true,\n powerpoint: true,\n teams: true,\n outlook: true,\n office365: true,\n microsoft365: true,\n delve: true,\n planner: true,\n todo: true,\n forms: true,\n powerautomate: true,\n bookings: true,\n edge: true,\n intune: true,\n myapps: true,\n collaboration: false,\n communication: false,\n datamanagementandautomation: false,\n fundamentals: false,\n leadership: false,\n timeandtaskmanagement: false,\n education: false,\n }), 1), visibleFilters = _e[0];\n var onChangeSort = function (event) {\n return setSortOrder(event.target.value);\n };\n var onChangeSearch = function (event) { return setSearch(event.target.value); };\n var sortedOutcomes = getSortedOutcomes(sortOrder, allOutcomes !== null && allOutcomes !== void 0 ? allOutcomes : []);\n var filteredOutcomes = getFilteredOutcomes(search, filtersOutcomes, sortedOutcomes);\n if (!allOutcomes) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsx(AllSkillsOrOutcomes, { filteredOutcomes: filteredOutcomes, filters: filtersOutcomes, setFilters: setFiltersOutcomes, visibleFilters: visibleFilters, search: search, onChangeSearch: onChangeSearch, sortOrder: sortOrder, onChangeSort: onChangeSort, page: page, isOutcome: true }, void 0));\n};\nexport default AllOutcomes;\n//# sourceMappingURL=AllOutcomes.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useTheme } from '@material-ui/core/styles';\nimport { useMediaQuery } from '@material-ui/core';\nimport { useContext, useEffect, useState } from 'react';\nimport { Link } from 'react-router-dom';\nimport { OutcomesContext } from '../../contexts/OutcomesContext';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { useGetOutcomesData } from '../../hooks/useGetOutcomesData';\nimport AddButton from '../buttons/AddButton';\nimport UpgradeButton from '../buttons/UpgradeButton';\nimport NewUpdatedLabel from '../NewUpdatedLabel';\nimport OutcomeImage from './OutcomeImage';\nimport { CompetenceState, Level, OutcomeSkillState } from '../../types/enums';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { isUpgradeOutcomeRecommendation } from '../../utils/isUpgradeOutcomeRecommendation';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n outcome: (_a = {\n height: 112,\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n borderBottom: '1px solid rgba(0, 0, 0, 0.12)',\n marginBottom: 16,\n marginTop: 16,\n '&&:last-child': {\n borderBottom: 'none',\n }\n },\n _a[theme.breakpoints.only('md')] = {\n flexDirection: 'column',\n height: '100%',\n },\n _a),\n link: (_b = {\n textDecoration: 'none',\n '&:focus, &:hover, &:visited, &:link, &:active': {\n textDecoration: 'none',\n },\n color: Colors.black,\n width: '100%'\n },\n _b[theme.breakpoints.down('md')] = {\n width: '100%',\n },\n _b[theme.breakpoints.down('sm')] = {\n maxWidth: 330,\n width: 330,\n },\n _b),\n info: (_c = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center'\n },\n _c[theme.breakpoints.only('md')] = {\n justifyContent: 'center',\n alignItems: 'flex-start',\n },\n _c),\n details: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n innerOutcome: {\n borderBottom: '1px solid rgba(0,0,0,0.12)',\n },\n content: {\n marginLeft: 16,\n },\n clickable: {\n cursor: 'pointer',\n },\n button: {\n marginLeft: 20,\n },\n });\n});\nvar RecommendedOutcome = function (_a) {\n var recommendedOutcome = _a.recommendedOutcome, page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var allOutcomes = useContext(OutcomesContext).allOutcomes;\n var _b = __read(useState(undefined), 2), outcome = _b[0], setOutcome = _b[1];\n var getData = useGetOutcomesData();\n var theme = useTheme();\n var isMd = useMediaQuery(theme.breakpoints.only('md'));\n useEffect(function () {\n allOutcomes === null || allOutcomes === void 0 ? void 0 : allOutcomes.forEach(function (value) {\n if (value.id === recommendedOutcome.targetId) {\n setOutcome(value);\n }\n });\n });\n if (!outcome) {\n return null;\n }\n return (_jsxs(\"div\", __assign({ className: classes.outcome }, { children: [_jsx(Link, __assign({ to: page + \"/outcome-details/\" + outcome.id, className: classes.link }, { children: _jsxs(\"div\", __assign({ className: classes.info }, { children: [_jsx(OutcomeImage, { outcome: outcome, unavailable: isUnavailable(outcome.current.state), type: \"outcome\", describedById: outcome.id.toString() }, void 0), _jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(NewUpdatedLabel, { createdDate: outcome.contentCreated, updatedDate: outcome.contentUpdated }, void 0), _jsx(\"h3\", __assign({ className: typo.subtitle2, id: outcome.id.toString() }, { children: outcome.name }), void 0), outcome.outcomeSkillState !== OutcomeSkillState.Hardhat && (_jsx(\"p\", __assign({ className: typo.subtitle2 }, { children: outcome.current.state === CompetenceState.NeedsAttention\n ? (outcome === null || outcome === void 0 ? void 0 : outcome.skillCount.toString()) + \" / \" + outcome.totalSkillCount + \" Skills Need Attention\"\n : outcome.current.state !== CompetenceState.Maintain\n ? (outcome === null || outcome === void 0 ? void 0 : outcome.skillCount.toString()) + \" / \" + outcome.totalSkillCount + \" Skills Attained\"\n : undefined }), void 0))] }), void 0)] }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.button }, { children: isUpgradeOutcomeRecommendation(recommendedOutcome) ? (_jsx(UpgradeButton, { user: user, recommended: true, skillOrOutcome: outcome, onAccept: getData, textFormat: isMd, describedById: outcome.id.toString() }, void 0)) : (_jsx(AddButton, { user: user, recommended: true, skillOrOutcome: outcome, level: Level.User, onAccept: getData, textFormat: isMd, describedById: outcome.id.toString() }, void 0)) }), void 0)] }), void 0));\n};\nexport default RecommendedOutcome;\n//# sourceMappingURL=RecommendedOutcome.js.map","import { RecommendType } from '../types/enums';\nexport var isUpgradeOutcomeRecommendation = function (recommendation) {\n return [RecommendType.UpgradeOutcome].includes(recommendation.type);\n};\n//# sourceMappingURL=isUpgradeOutcomeRecommendation.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport RecommendedOutcome from './RecommendedOutcome';\nimport { Paper } from '@material-ui/core';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n width: 326,\n backgroundColor: Colors.white,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n borderRadius: 4\n },\n _a[theme.breakpoints.down('md')] = {\n width: 236,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n borderRadius: 0,\n },\n _a),\n content: {\n padding: 16,\n width: '100%',\n paddingBottom: 0,\n },\n });\n});\nvar RecommendedOutcomesCard = function (_a) {\n var _b;\n var recommendedOutcomes = _a.recommendedOutcomes, page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n return (_jsx(Paper, __assign({ component: \"section\", elevation: 1, \"aria-labelledby\": \"recommended-title\", className: classes.card }, { children: _jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(\"h2\", __assign({ id: \"recommended-title\", className: typo.subtitle2, style: { fontWeight: 600 } }, { children: \"Discover More\" }), void 0), ((_b = recommendedOutcomes === null || recommendedOutcomes === void 0 ? void 0 : recommendedOutcomes.length) !== null && _b !== void 0 ? _b : 0) === 0 ? (_jsx(\"p\", __assign({ className: typo.caption, style: { marginBottom: 16 } }, { children: \"There aren\\u2019t any new recommendations for you right now - but keep using your skills in Microsoft 365 and check back soon. But, if you\\u2019re ready for a new challenge, try advancing to the next level or adding a new Skill or Outcome\" }), void 0)) : (_jsxs(_Fragment, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { marginBottom: 16 } }, { children: \"Here are some Outcomes we think would be great for you.\" }), void 0), recommendedOutcomes === null || recommendedOutcomes === void 0 ? void 0 : recommendedOutcomes.map(function (value, index) { return (_jsx(RecommendedOutcome, { recommendedOutcome: value, page: page }, \"recommendedOutcome-\" + index)); })] }, void 0))] }), void 0) }), void 0));\n};\nexport default RecommendedOutcomesCard;\n//# sourceMappingURL=RecommendedOutcomesCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useContext } from 'react';\nimport { useHistory } from 'react-router';\nimport { OutcomesContext } from '../../contexts/OutcomesContext';\nimport { TabName } from '../../types/types';\nimport { Colors } from '../../utils/colors';\nimport CardSkillsOrOutcomes from '../CardSkillsOrOutcomes';\nimport Header from '../Header';\nimport Loading from '../Loading';\nimport RecommendedOutcomesCard from './RecommendedOutcomesCard';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n skills: (_a = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n alignItems: 'center',\n },\n _a),\n item: {\n marginTop: 16,\n width: '100%',\n borderRadius: 4,\n backgroundColor: Colors.white,\n },\n mainColumn: (_b = {\n width: 720\n },\n _b[theme.breakpoints.down('md')] = {\n width: 422,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _b),\n secondColumn: (_c = {\n marginLeft: 16\n },\n _c[theme.breakpoints.down('md')] = {\n marginLeft: 11,\n },\n _c[theme.breakpoints.down('sm')] = {\n marginTop: 12,\n marginLeft: 0,\n width: 330,\n },\n _c),\n });\n});\nvar YourOutcomes = function (_a) {\n var _b, _c, _d;\n var page = _a.page, outcomesDetailId = _a.outcomesDetailId;\n var classes = useStyles();\n var _e = useContext(OutcomesContext), outcomes = _e.outcomes, recommendedOutcomes = _e.recommendedOutcomes, deepLink = _e.deepLink, setDeepLink = _e.setDeepLink;\n var history = useHistory();\n if (outcomesDetailId && !deepLink) {\n setDeepLink(true);\n history.push(\"/outcomesTab/outcome-details/\" + outcomesDetailId);\n }\n if (!outcomes) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"main\", __assign({ id: TabName.Yours, className: classes.skills }, { children: [_jsxs(\"div\", __assign({ className: classes.mainColumn }, { children: [_jsx(Header, { inProgress: (_b = outcomes === null || outcomes === void 0 ? void 0 : outcomes.inProgress.length) !== null && _b !== void 0 ? _b : 0, maintain: (_c = outcomes === null || outcomes === void 0 ? void 0 : outcomes.maintain.length) !== null && _c !== void 0 ? _c : 0, needsImprovement: (_d = outcomes === null || outcomes === void 0 ? void 0 : outcomes.needsImprovement.length) !== null && _d !== void 0 ? _d : 0, isOutcomes: true }, void 0), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.needsImprovement) && outcomes.needsImprovement.length > 0 && (_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(CardSkillsOrOutcomes, { page: page, title: \"Need Attention\", color: Colors.red, cards: outcomes.needsImprovement, button: false, isOutcome: true }, \"outcomes-need-attention\") }), void 0)), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.inProgress) && outcomes.inProgress.length > 0 && (_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(CardSkillsOrOutcomes, { page: page, title: \"In Progress\", color: Colors.yellow, cards: outcomes.inProgress, button: false, isOutcome: true }, \"outcomes-in-progress\") }), void 0)), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.maintain) && outcomes.maintain.length > 0 && (_jsx(\"div\", __assign({ className: classes.item }, { children: _jsx(CardSkillsOrOutcomes, { page: page, title: \"Attained\", color: Colors.green, cards: outcomes.maintain, button: false, isOutcome: true }, \"outcomes-maintain\") }), void 0)), _jsx(\"div\", { style: { height: 24 } }, void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.secondColumn }, { children: _jsx(RecommendedOutcomesCard, { page: page, recommendedOutcomes: recommendedOutcomes }, void 0) }), void 0)] }), void 0));\n};\nexport default YourOutcomes;\n//# sourceMappingURL=YourOutcomes.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { TabName } from '../../types/types';\nimport { useGetOutcomesData } from '../../hooks/useGetOutcomesData';\nimport AllOutcomes from './AllOutcomes';\nimport YourOutcomes from './YourOutcomes';\nimport { Pages } from '../../types/enums';\nimport MeasurementBanner from '../MeasurementBanner';\nimport { UserContext } from '../../contexts/UserContext';\nimport NextLastUpdated from '../NextLastUpdated';\nvar Outcomes = function (_a) {\n var page = _a.page, outcomeDetailId = _a.outcomeDetailId;\n var user = useContext(UserContext).user;\n var _b = useContext(HeaderContext), setTitle = _b.setTitle, setGoBack = _b.setGoBack, setTabs = _b.setTabs, setPage = _b.setPage;\n var _c = __read(useState(false), 2), receivedData = _c[0], setReceivedData = _c[1];\n var getData = useGetOutcomesData();\n useEffect(function () {\n setTitle('Outcomes');\n setGoBack(false);\n setTabs([\n {\n name: TabName.Yours,\n selected: location.pathname !== (page !== null && page !== void 0 ? page : Pages.OutcomesPage) + \"/all-outcomes\",\n to: (page !== null && page !== void 0 ? page : Pages.OutcomesPage) + \"/your-outcomes\",\n },\n {\n name: TabName.All,\n selected: location.pathname === (page !== null && page !== void 0 ? page : Pages.OutcomesPage) + \"/all-outcomes\",\n to: (page !== null && page !== void 0 ? page : Pages.OutcomesPage) + \"/all-outcomes\",\n },\n ]);\n setPage(page !== null && page !== void 0 ? page : Pages.OutcomesPage);\n }, [location.pathname]);\n useEffect(function () {\n if (!receivedData) {\n getData();\n setReceivedData(true);\n }\n }, [receivedData, getData]);\n return (_jsxs(_Fragment, { children: [(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) ? _jsx(MeasurementBanner, {}, void 0) : _jsx(NextLastUpdated, {}, void 0), location.pathname === (page !== null && page !== void 0 ? page : Pages.OutcomesPage) + \"/all-outcomes\" ? (_jsx(AllOutcomes, { page: page !== null && page !== void 0 ? page : Pages.OutcomesPage }, void 0)) : (_jsx(YourOutcomes, { page: page !== null && page !== void 0 ? page : Pages.OutcomesPage, outcomesDetailId: outcomeDetailId }, void 0))] }, void 0));\n};\nexport default Outcomes;\n//# sourceMappingURL=Outcomes.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useApiService } from '../services/ApiServiceProvider';\nimport { useContext } from 'react';\nimport { UserContext } from '../contexts/UserContext';\nexport var useTelemetry = function () {\n var ApiService = useApiService();\n var user = useContext(UserContext).user;\n return function (code, status, reason, data) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.telemetry(user, code, status, reason, data)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useTelemetry.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar LinkedInIcon = function () {\n var id = useUUID('linkedinIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"16px\", height: \"16px\", viewBox: \"0 0 16 16\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"LinkedIn\" }), void 0), _jsx(\"g\", __assign({ stroke: \"none\", strokeWidth: \"1\", fill: \"none\", fillRule: \"evenodd\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(-169.000000, -285.000000)\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(103.000000, 91.000000)\" }, { children: _jsx(\"g\", __assign({ transform: \"translate(50.000000, 184.000000)\" }, { children: _jsxs(\"g\", __assign({ transform: \"translate(16.000000, 10.000000)\" }, { children: [_jsx(\"rect\", { x: \"0\", y: \"0\", width: \"16\", height: \"16\" }, void 0), _jsx(\"path\", { d: \"M14.8571429,0 L1.13928571,0 C0.510714286,0 0,0.517857143 0,1.15357143 L0,14.8464286 C0,15.4821429 0.510714286,16 1.13928571,16 L14.8571429,16 C15.4857143,16 16,15.4821429 16,14.8464286 L16,1.15357143 C16,0.517857143 15.4857143,0 14.8571429,0 Z M4.83571426,13.7142855 L2.46428569,13.7142855 L2.46428569,6.07857132 L4.83928569,6.07857132 L4.83928569,13.7142855 L4.83571426,13.7142855 Z M3.64999994,5.03571431 C2.88928565,5.03571431 2.27499994,4.41785717 2.27499994,3.66071431 C2.27499994,2.90357145 2.88928565,2.28571431 3.64999994,2.28571431 C4.40714279,2.28571431 5.02499994,2.90357145 5.02499994,3.66071431 C5.02499994,4.42142859 4.41071422,5.03571431 3.64999994,5.03571431 L3.64999994,5.03571431 Z M13.7250004,13.7142855 L11.3535717,13.7142855 L11.3535717,9.99999976 C11.3535717,9.11428546 11.3357146,7.97499973 10.1214288,7.97499973 C8.8857145,7.97499973 8.69642878,8.93928546 8.69642878,9.93571404 L8.69642878,13.7142855 L6.32500013,13.7142855 L6.32500013,6.07857112 L8.60000021,6.07857112 L8.60000021,7.12142828 L8.63214306,7.12142828 C8.95000022,6.52142827 9.72500024,5.88928541 10.8785717,5.88928541 C13.2785718,5.88928541 13.7250004,7.47142829 13.7250004,9.52857118 L13.7250004,13.7142855 L13.7250004,13.7142855 Z\", fill: \"#FFFFFF\", fillRule: \"nonzero\" }, void 0)] }), void 0) }), void 0) }), void 0) }), void 0) }), void 0)] }), void 0));\n};\nexport default LinkedInIcon;\n//# sourceMappingURL=LinkedInIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../../utils/colors';\nimport { TelemetryCode, TelemetryStatus } from '../../types/types';\nimport { UserContext } from '../../contexts/UserContext';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport Button from '../buttons/Button';\nimport { Dialog, DialogContent, IconButton } from '@material-ui/core';\nimport clsx from 'clsx';\nimport isMobile from 'is-mobile';\nimport { BADGES_PATH, PUBLISH_URL } from '../../utils/constants';\nimport LinkedInIcon from '../icons/LinkedInIcon';\nimport { useTelemetry } from '../../hooks/useTelemetry';\nimport { useTypography } from '../../styles/Typography';\nimport { useHistory } from 'react-router';\nimport { X } from 'react-feather';\nvar useStyles = makeStyles({\n paper: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n boxShadow: '0 12.5px 128px 4px rgba(0,0,0,0.08), 0 24px 32px 2px rgba(0,0,0,0.08)',\n width: 380,\n },\n awarded: {},\n image: {\n marginBottom: 32,\n },\n inProgressBadge: {\n filter: 'opacity(0.5)',\n },\n content: {\n textAlign: 'center',\n position: 'relative',\n padding: 24,\n },\n buttonContent: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n});\nvar BadgeDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, badge = _a.badge, disabled = _a.disabled, route = _a.route;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var clientType = useContext(TokenContext).clientType;\n var linkedInTelemetry = useTelemetry();\n var history = useHistory();\n if (!user) {\n return null;\n }\n var post = function () {\n var _a;\n window.open(PUBLISH_URL + \"/linkedin.html?oid=\" + user.oid + \"&assertionId=\" + getAssertion((_a = badge === null || badge === void 0 ? void 0 : badge.url) !== null && _a !== void 0 ? _a : '') + \"&clientType=\" + clientType);\n };\n var getAssertion = function (phrase) {\n var myRegexp = /assertions\\/(.*)/;\n var match = myRegexp.exec(phrase);\n return match ? match[1] : '';\n };\n var copyUrl = function () { return __awaiter(void 0, void 0, void 0, function () {\n var e_1, data;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!badge.url)\n return [2];\n _a.label = 1;\n case 1:\n _a.trys.push([1, 3, 4, 6]);\n return [4, navigator.clipboard.writeText(badge.url)];\n case 2:\n _a.sent();\n return [3, 6];\n case 3:\n e_1 = _a.sent();\n console.error('cannot copy to clipboard in chrome');\n return [3, 6];\n case 4:\n data = [\n { name: 'oid', value: \"\" + (user === null || user === void 0 ? void 0 : user.oid) },\n { name: 'badgeId', value: \"\" + badge.id },\n ];\n return [4, linkedInTelemetry(TelemetryCode.PLI, TelemetryStatus.Success, 'Copy badge URL button', data)];\n case 5:\n _a.sent();\n history.push(route + \"/\" + getAssertion(badge.url));\n return [7];\n case 6: return [2];\n }\n });\n }); };\n return (_jsx(_Fragment, { children: _jsx(Dialog, __assign({ open: open, onClose: onClose, classes: {\n paperWidthSm: clsx(classes.paper, badge.awarded ? classes.awarded : undefined),\n }, fullScreen: isMobile() }, { children: _jsxs(DialogContent, __assign({ className: classes.content }, { children: [_jsx(IconButton, __assign({ onClick: onClose, style: { position: 'absolute', top: 16, right: 16 } }, { children: _jsx(X, {}, void 0) }), void 0), _jsx(\"img\", { alt: badge.name, className: clsx(classes.image, !badge.dateAwarded && classes.inProgressBadge), src: \"\" + BADGES_PATH + badge.image + \".svg\" }, void 0), badge.awarded ? (_jsxs(_Fragment, { children: [_jsx(Button, __assign({ disabled: disabled, onClick: post, style: {\n width: 225,\n backgroundColor: disabled ? Colors.disabled : '#0077B5',\n marginBottom: 16,\n } }, { children: _jsxs(\"div\", __assign({ className: classes.buttonContent }, { children: [_jsx(LinkedInIcon, {}, void 0), _jsx(\"div\", __assign({ style: { marginLeft: 8 } }, { children: \"Post on LinkedIn\" }), void 0)] }), void 0) }), void 0), _jsx(Button, __assign({ disabled: disabled, onClick: copyUrl, style: {\n width: 225,\n marginBottom: 16,\n } }, { children: _jsxs(\"div\", __assign({ className: classes.buttonContent }, { children: [_jsx(LinkedInIcon, {}, void 0), _jsx(\"div\", __assign({ style: { marginLeft: 8 } }, { children: \"Add Certification\" }), void 0)] }), void 0) }), void 0)] }, void 0)) : (_jsx(\"p\", __assign({ className: typo.body1 }, { children: \"You will be able to share this badge on sites like LinkedIn once you earn it.\" }), void 0))] }), void 0) }), void 0) }, void 0));\n};\nexport default BadgeDialog;\n//# sourceMappingURL=BadgeDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { ButtonBase, Chip } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { format } from 'date-fns';\nimport { useContext, useState } from 'react';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useTypography } from '../../styles/Typography';\nimport { TelemetryCode, TelemetryStatus } from '../../types/types';\nimport { BADGES_PATH } from '../../utils/constants';\nimport { useTelemetry } from '../../hooks/useTelemetry';\nimport BadgeDialog from './BadgeDialog';\nimport { CompetenceState, Level } from '../../types/enums';\nimport { Share } from 'react-feather';\nvar useStyles = makeStyles({\n badge: {\n height: '100%',\n cursor: 'pointer',\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n badgeImage: {\n height: 208,\n },\n inProgressBadge: {\n filter: 'opacity(0.5)',\n },\n chip: {\n borderRadius: 16,\n height: 16,\n marginTop: 4,\n marginBottom: 6,\n paddingLeft: 16,\n paddingRight: 16,\n fontFamily: 'Ubuntu',\n fontSize: 10,\n fontWeight: 600,\n lineHeight: '12px',\n letterSpacing: 0.5,\n textTransform: 'uppercase',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n notStartedChip: {\n background: 'rgba(0, 0, 0, 0.08)',\n color: 'rgba(0, 0, 0, 0.64)',\n },\n inProgressChip: {\n background: 'rgba(101, 78, 163, 0.08)',\n color: '#654EA3',\n marginBottom: 28,\n },\n needsAttentionChip: {\n background: 'rgba(250, 208, 70, 0.32)',\n color: '#AC5521',\n },\n maintainChip: {\n background: 'rgba(142, 194, 11, 0.2)',\n color: '#4E6B05',\n },\n maintainChipNotAwarded: {\n background: 'rgba(142, 194, 11, 0.2)',\n color: '#4E6B05',\n marginBottom: 11.8,\n },\n shareIcon: {\n cursor: 'pointer',\n position: 'relative',\n top: 16,\n display: 'flex',\n justifyContent: 'flex-end',\n alignItems: 'flex-end',\n },\n noShareIcon: {\n paddingTop: 30,\n },\n});\nfunction getBadgeLevel(level) {\n if (level === Level.None)\n return;\n return \"for \" + Level[level] + \" \";\n}\nvar Badge = function (_a) {\n var badge = _a.badge, route = _a.route, tabIndex = _a.tabIndex;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = __read(useState(false), 2), open = _b[0], setOpen = _b[1];\n var linkedInTelemetry = useTelemetry();\n var onOpen = function () { return __awaiter(void 0, void 0, void 0, function () {\n var data;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!badge.dateAwarded) return [3, 2];\n data = [\n { name: 'oid', value: \"\" + (user === null || user === void 0 ? void 0 : user.oid) },\n { name: 'badgeId', value: \"\" + badge.id },\n ];\n return [4, linkedInTelemetry(TelemetryCode.PLI, TelemetryStatus.Success, 'Click on badge card', data)];\n case 1:\n _a.sent();\n _a.label = 2;\n case 2:\n setOpen(true);\n return [2];\n }\n });\n }); };\n var onClose = function () { return setOpen(false); };\n return (_jsxs(_Fragment, { children: [_jsxs(ButtonBase, __assign({ className: classes.badge, onClick: onOpen, tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : undefined }, { children: [_jsxs(\"span\", { children: [_jsx(\"span\", __assign({ className: classes.shareIcon, style: !badge.awarded ? { height: 24 } : {} }, { children: badge.awarded && _jsx(Share, {}, void 0) }), void 0), _jsx(\"img\", { className: clsx(classes.badgeImage, !badge.dateAwarded && classes.inProgressBadge), alt: \"\", src: \"\" + BADGES_PATH + badge.image + \".svg\", loading: \"lazy\" }, void 0)] }, void 0), _jsx(\"span\", { children: badge.state === CompetenceState.Locked ||\n badge.state === CompetenceState.Unassigned ? null : badge.state === CompetenceState.InProgress ? (_jsx(Chip, { className: clsx(classes.inProgressChip, classes.chip), label: \"In Progress\", \"aria-label\": \"badge \" + badge.name + \" \" + getBadgeLevel(badge.level) + \"is currently in progress\" }, void 0)) : badge.state === CompetenceState.NeedsAttention ? (_jsx(Chip, { className: clsx(classes.needsAttentionChip, classes.chip), label: \"Needs Attention\", \"aria-label\": \"badge \" + badge.name + \" \" + getBadgeLevel(badge.level) + \"needs attention\" }, void 0)) : badge.state === CompetenceState.Maintain && badge.dateAwarded ? (_jsx(Chip, { className: clsx(classes.maintainChip, classes.chip), label: \"Maintaining\", \"aria-label\": \"badge \" + badge.name + \" \" + getBadgeLevel(badge.level) + \"is being maintained\" }, void 0)) : badge.state === CompetenceState.Maintain && !badge.dateAwarded ? (_jsx(Chip, { className: clsx(classes.maintainChipNotAwarded, classes.chip), label: \"Maintaining\", \"aria-label\": \"badge \" + badge.name + \" \" + getBadgeLevel(badge.level) + \"is being maintained\" }, void 0)) : null }, void 0), _jsxs(\"span\", { children: [badge.dateAwarded && badge.state === null && (_jsxs(\"span\", __assign({ className: typo.caption, style: { marginTop: 11.8 } }, { children: [\"Earned: \", format(new Date(badge.dateAwarded), 'PP')] }), void 0)), badge.dateAwarded && badge.state !== null && (_jsxs(\"span\", __assign({ className: typo.caption }, { children: [\"Earned: \", format(new Date(badge.dateAwarded), 'PP')] }), void 0))] }, void 0), _jsx(\"span\", { children: badge.shared && badge.sharedDate && (_jsxs(\"span\", __assign({ className: typo.caption }, { children: [\"Shared: \", format(new Date(badge.sharedDate), 'PP')] }), void 0)) }, void 0)] }), void 0), _jsx(BadgeDialog, { open: open, onClose: onClose, badge: badge, route: route }, void 0)] }, void 0));\n};\nexport default Badge;\n//# sourceMappingURL=Badge.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Link } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport clsx from 'clsx';\nimport { useContext } from 'react';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport LevelIcon from '../LevelIcon';\nimport NewUpdatedLabel from '../NewUpdatedLabel';\nimport { SkillProgressBar } from '../SkillProgressBar';\nimport { ClientType } from '../../types/enums';\nimport { useHistory } from 'react-router-dom';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { toStreakString } from '../../utils/toStreakString';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { APPLICATION_ID } from '../../utils/constants';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n skillContainer: {\n marginTop: 24,\n marginBottom: 24,\n },\n skill: (_a = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n textDecoration: 'none',\n '&:focus, &:hover, &:visited, &:link, &:active': {\n textDecoration: 'none',\n },\n cursor: 'pointer',\n color: Colors.black\n },\n _a[theme.breakpoints.down('sm')] = {\n height: 110,\n },\n _a),\n topBar: {\n width: '100%',\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n icon: {\n marginRight: 20,\n },\n detail: (_b = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _b[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-start',\n },\n _b),\n label: (_c = {},\n _c[theme.breakpoints.up('lg')] = {\n textAlign: 'right',\n },\n _c),\n progressContainer: {\n maxWidth: '90%',\n marginLeft: 'auto',\n },\n alignLeft: {\n textAlign: 'left',\n },\n });\n});\nvar OutcomeSkill = function (_a) {\n var skill = _a.skill, tabIndex = _a.tabIndex;\n var typo = useTypography();\n var classes = useStyles();\n var clientType = useContext(TokenContext).clientType;\n var history = useHistory();\n var openSkillDetail = function () {\n if (clientType === ClientType.platform) {\n history.push(\"/skill-details/\" + skill.id);\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/ef9b5db3-e49a-4fdd-8e29-ccedda0ffbc7?context={\\\"subEntityId\\\": \" + skill.id + \"}\");\n }\n };\n return (_jsxs(\"div\", __assign({ className: classes.skillContainer }, { children: [_jsxs(Link, __assign({ \"aria-labelledby\": \"skill-\" + skill.id, component: \"button\", onClick: openSkillDetail, className: classes.skill, tabIndex: tabIndex }, { children: [_jsx(\"span\", __assign({ className: classes.icon }, { children: _jsx(LevelIcon, { progress: skill.current.progress, state: skill.current.state, level: skill.current.level, type: \"skill\" }, void 0) }), void 0), _jsx(\"span\", __assign({ className: classes.topBar }, { children: _jsxs(\"span\", __assign({ className: classes.detail }, { children: [_jsxs(\"span\", __assign({ className: classes.alignLeft }, { children: [_jsx(NewUpdatedLabel, { createdDate: skill.contentCreated, updatedDate: skill.contentUpdated }, void 0), _jsx(\"span\", __assign({ className: typo.subtitle2, style: { marginRight: 8 }, id: \"skill-\" + skill.id }, { children: skill.name }), void 0)] }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.label, classes.label) }, { children: toStreakString(skill.current.state, skill.current.currentStreak) }), void 0)] }), void 0) }), void 0)] }), void 0), !isUnavailable(skill.current.state) && (_jsx(\"div\", __assign({ className: classes.progressContainer }, { children: _jsx(SkillProgressBar, { currentState: skill.current.state, progress: skill.current.progress }, void 0) }), void 0))] }), void 0));\n};\nexport default OutcomeSkill;\n//# sourceMappingURL=OutcomeSkill.js.map","export var clampNumber = function (num, a, b) {\n return Math.max(Math.min(num, Math.max(a, b)), Math.min(a, b));\n};\n//# sourceMappingURL=clampNumber.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport React from 'react';\nimport { useUUID } from './useUUID';\nimport { clampNumber } from '../utils/clampNumber';\nexport var useRovingTabIndex = function (opts) {\n var instructionsId = useUUID();\n var horizontalIndex = React.useRef();\n var listRef = React.useCallback(function (list) {\n var cleanUpFns = [];\n if (list === null || list === void 0 ? void 0 : list.parentElement) {\n var instructions_1 = document.createElement('span');\n instructions_1.id = instructionsId;\n instructions_1.innerText =\n 'Use the up and down arrow keys to navigate the list and use the left and right arrow keys to navigate inside of the item';\n instructions_1.style.border = 'none';\n instructions_1.style.clip = 'rect(0 0 0 0)';\n instructions_1.style.height = '1px';\n instructions_1.style.margin = '-1px';\n instructions_1.style.overflow = 'hidden';\n instructions_1.style.padding = '0';\n instructions_1.style.position = 'absolute';\n instructions_1.style.top = '20px';\n instructions_1.style.width = '1px';\n instructions_1.setAttribute('data-useRovingTabIndex', 'true');\n if (list.parentElement instanceof HTMLTableElement) {\n var existingCaption = list.parentElement.querySelector('caption');\n if (existingCaption) {\n var existingInstructions = existingCaption.querySelector('[data-useRovingTabIndex]');\n if (existingInstructions) {\n instructions_1.id = existingInstructions.id;\n }\n else {\n existingCaption.append(instructions_1);\n }\n }\n else {\n var newCaption = document.createElement('caption');\n newCaption.append(instructions_1);\n list.parentElement.prepend(newCaption);\n }\n }\n else {\n list.parentElement.insertBefore(instructions_1, list);\n }\n list.setAttribute('aria-describedby', \"\" + (list.getAttribute('aria-describedby') ? list.getAttribute('aria-describedby') + ' ' : '') + instructions_1.id);\n cleanUpFns.push(function () {\n var _a;\n list.setAttribute('aria-describedby', ((_a = list.getAttribute('aria-describedby')) === null || _a === void 0 ? void 0 : _a.replace(instructions_1.id, '')) + \" \" + instructions_1.id);\n instructions_1.remove();\n });\n }\n if (list) {\n var onKeydown_1 = function (e) {\n var listItemWithFocus = __spreadArray([], __read(list.childNodes), false).find(function (item) {\n return item.querySelector('[tabindex]:not([tabindex=\"-1\"])');\n });\n var changeFocus = function (nextFocusItem) {\n if (listItemWithFocus && nextFocusItem) {\n var oldFocusItem = listItemWithFocus.querySelector('[tabindex=\"0\"]');\n if (oldFocusItem)\n oldFocusItem.tabIndex = -1;\n nextFocusItem.tabIndex = 0;\n nextFocusItem.focus();\n }\n };\n var verticalNav = function (sibling) {\n var _a, _b;\n e.preventDefault();\n var allFocusItems = sibling === null || sibling === void 0 ? void 0 : sibling.querySelectorAll('[tabindex]');\n var nextFocusRowItemIndex = clampNumber((_a = horizontalIndex.current) !== null && _a !== void 0 ? _a : 0, 0, (_b = allFocusItems === null || allFocusItems === void 0 ? void 0 : allFocusItems.length) !== null && _b !== void 0 ? _b : 1);\n var nextFocusItem = __spreadArray([], __read((allFocusItems !== null && allFocusItems !== void 0 ? allFocusItems : [])), false)[nextFocusRowItemIndex];\n changeFocus(nextFocusItem);\n };\n var horizontalNav = function (direction) {\n var _a;\n e.preventDefault();\n var allFocusItems = Array.from((_a = listItemWithFocus === null || listItemWithFocus === void 0 ? void 0 : listItemWithFocus.querySelectorAll('[tabindex]')) !== null && _a !== void 0 ? _a : []);\n var focusedIndex = allFocusItems === null || allFocusItems === void 0 ? void 0 : allFocusItems.findIndex(function (item) { return item.tabIndex === 0; });\n var nextFocusIndex = clampNumber(focusedIndex + direction, 0, allFocusItems.length - 1);\n var nextFocusItem = allFocusItems[nextFocusIndex];\n horizontalIndex.current = nextFocusIndex;\n changeFocus(nextFocusItem);\n };\n switch (e.key) {\n case 'ArrowDown': {\n verticalNav(listItemWithFocus === null || listItemWithFocus === void 0 ? void 0 : listItemWithFocus.nextSibling);\n break;\n }\n case 'ArrowUp': {\n verticalNav(listItemWithFocus === null || listItemWithFocus === void 0 ? void 0 : listItemWithFocus.previousSibling);\n break;\n }\n case 'ArrowRight': {\n horizontalNav(1);\n break;\n }\n case 'ArrowLeft': {\n horizontalNav(-1);\n break;\n }\n }\n };\n var onFocus_1 = function (e) {\n var element = e.target;\n if (element instanceof HTMLElement) {\n var focusedItems = list.querySelectorAll('[tabindex]:not([tabindex=\"-1\"])');\n focusedItems.forEach(function (item) { return (item.tabIndex = -1); });\n element.tabIndex = 0;\n }\n };\n list.addEventListener('keydown', onKeydown_1);\n list.addEventListener('focusin', onFocus_1);\n cleanUpFns.push(function () {\n list.removeEventListener('keydown', onKeydown_1);\n list.removeEventListener('focusin', onFocus_1);\n });\n }\n return function () { return cleanUpFns.forEach(function (fn) { return fn(); }); };\n }, [instructionsId]);\n return listRef;\n};\n//# sourceMappingURL=useRovingTabIndex.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Divider, Grid, Paper, useMediaQuery, useTheme } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { OutcomesContext } from '../../contexts/OutcomesContext';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport AddButton from '../buttons/AddButton';\nimport RemoveButton from '../buttons/RemoveButton';\nimport UnavailableButton from '../buttons/UnavailableButton';\nimport ChangeTargetLevel from '../ChangeTargetLevel';\nimport DetailsOverviewSkillsOrOutcomes from '../DetailsOverviewSkillsOrOutcomes';\nimport Loading from '../Loading';\nimport Badge from '../showcase/Badge';\nimport UnavailablePanel from '../UnavailablePanel';\nimport OutcomeImage from './OutcomeImage';\nimport OutcomeSkill from './OutcomeSkill';\nimport RecommendedActivity from '../RecommendedActivity';\nimport { CompetenceState, Level, Pages } from '../../types/enums';\nimport { useRovingTabIndex } from '../../hooks/useRovingTabIndex';\nimport { useParams } from 'react-router';\nimport NextLastUpdated from '../NextLastUpdated';\nimport { OutcomeService } from '../../services/OutcomeService';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useGetOutcomesData } from '../../hooks/useGetOutcomesData';\nimport { useGetOutcomeDetails } from '../../hooks/useGetOutcomeDetails';\nimport { getToken } from '../../utils/getToken';\nimport { isUnavailable } from '../../utils/isUnavailable';\nimport { isStarterCustomer } from '../../utils/isStarterCustomer';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;\n return ({\n main: {\n width: '100%',\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n outcomeDetail: (_a = {\n width: 1040,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n top: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginTop: 16,\n },\n iconTitle: {\n display: 'flex',\n alignItems: 'center',\n },\n addSkill: (_b = {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n marginLeft: 32\n },\n _b[theme.breakpoints.up('sm')] = {\n width: 128,\n minWidth: 128,\n },\n _b),\n addText: {\n color: Colors.textSecondary,\n marginTop: 8,\n textAlign: 'center',\n },\n titleSkills: (_c = {\n marginLeft: 24,\n width: '100%'\n },\n _c[theme.breakpoints.down('sm')] = {\n marginLeft: 16,\n },\n _c),\n name: (_d = {\n color: Colors.textPrimary\n },\n _d[theme.breakpoints.down('md')] = {\n fontSize: 20,\n letterSpacing: 0.25,\n lineHeight: '24px',\n },\n _d[theme.breakpoints.down('sm')] = {\n fontSize: 16,\n letterSpacing: 0.15,\n lineHeight: '24px',\n },\n _d),\n skillsAchieved: (_e = {\n color: Colors.textSecondary\n },\n _e[theme.breakpoints.down('sm')] = {\n fontSize: 12,\n letterSpacing: 0.15,\n lineHeight: '16px',\n },\n _e),\n descriptionVideo: (_f = {\n marginTop: 32\n },\n _f[theme.breakpoints.up('md')] = {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n _f),\n description: (_g = {\n width: 714,\n color: Colors.textPrimary,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '22px'\n },\n _g[theme.breakpoints.down('md')] = {\n width: 488,\n marginBottom: 24,\n },\n _g[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _g),\n overviewButton: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n },\n overviewIcon: {\n marginRight: 8,\n },\n skillsActivities: (_h = {\n width: '100%',\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'flex-start',\n marginBottom: 32\n },\n _h[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n },\n _h),\n skills: (_j = {\n borderRadius: 4,\n backgroundColor: Colors.white\n },\n _j[theme.breakpoints.up('lg')] = {\n width: 512,\n },\n _j[theme.breakpoints.down('md')] = {\n width: '100%',\n marginRight: 0,\n marginBottom: 32,\n },\n _j),\n skillItems: {\n marginLeft: 24,\n marginRight: 24,\n marginBottom: 24,\n listStyleType: 'none',\n padding: 0,\n },\n skillsTitle: {\n padding: 24,\n borderBottom: '1px solid rgba(0,0,0,0.08)',\n },\n recommendations: (_k = {},\n _k[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _k),\n activity: (_l = {\n borderRadius: 4,\n backgroundColor: Colors.white,\n paddingTop: 16,\n paddingBottom: 16,\n paddingLeft: 24,\n paddingRight: 24\n },\n _l[theme.breakpoints.up('md')] = {\n width: 528,\n },\n _l),\n innerRecommendation: {\n marginBottom: 16,\n },\n badgeCard: {\n width: '100%',\n backgroundColor: Colors.white,\n borderRadius: 4,\n marginBottom: 32,\n },\n badge: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n padding: 24,\n },\n badgeContent: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n paddingTop: 16,\n paddingLeft: 24,\n paddingRight: 24,\n paddingBottom: 16,\n maxWidth: 422,\n },\n badgeTitle: {\n padding: 24,\n borderBottom: '1px solid rgba(0,0,0,0.08)',\n },\n badgeNotMain: {\n boxShadow: '0 0 0 0',\n },\n unavailablePanel: (_m = {\n padding: 0,\n boxShadow: '0 5px 16px 1px rgba(0,0,0,0.08), 0 2px 8px 0 rgba(0,0,0,0.08)',\n borderRadius: 4,\n height: 'fit-content'\n },\n _m[theme.breakpoints.up('lg')] = {\n width: 496,\n },\n _m),\n date: {\n marginBottom: 8,\n },\n title: (_o = {},\n _o[theme.breakpoints.down('sm')] = {\n fontSize: 16,\n lineHeight: 1,\n },\n _o),\n });\n});\nvar OutcomeDetails = function (_a) {\n var _b, _c, _d, _e, _f, _g;\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var _h = useMsal(), instance = _h.instance, accounts = _h.accounts;\n var account = useAccount(accounts[0]);\n var _j = useContext(TokenContext), ssoToken = _j.ssoToken, oid = _j.oid, tid = _j.tid, clientType = _j.clientType;\n var outcomeId = useParams().outcomeId;\n var user = useContext(UserContext).user;\n var allSkills = useContext(OutcomesContext).allSkills;\n var _k = useContext(HeaderContext), setTitle = _k.setTitle, setGoBack = _k.setGoBack, setTabs = _k.setTabs;\n var _l = __read(useState(false), 2), fetchedOutcome = _l[0], setFetchedOutcome = _l[1];\n var _m = __read(useState(undefined), 2), outcome = _m[0], setOutcome = _m[1];\n var _o = __read(useState(undefined), 2), recommendations = _o[0], setRecommendations = _o[1];\n var _p = __read(useState(false), 2), fetchedRecommendations = _p[0], setFetchedRecommendations = _p[1];\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var getData = useGetOutcomesData();\n var skillsRef = useRovingTabIndex();\n var badgesRef = useRovingTabIndex();\n var getOutcomeDetails = useGetOutcomeDetails();\n useEffect(function () {\n setTitle('Back');\n setGoBack(true);\n setTabs(undefined);\n }, [setGoBack, setTabs, setTitle]);\n var accept = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getOutcomeDetails(Number(outcomeId), setOutcome)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n var getRecommendations = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!outcome) {\n return [2];\n }\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getOutcomeActivityRecommendations(outcome.id)];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setRecommendations(response);\n setFetchedRecommendations(true);\n return [2];\n }\n });\n }); }, [account, clientType, instance, oid, outcome, ssoToken, tid]);\n useEffect(function () {\n if (!fetchedOutcome) {\n getOutcomeDetails(Number(outcomeId), setOutcome);\n setFetchedOutcome(true);\n }\n }, [fetchedOutcome, getOutcomeDetails, outcomeId]);\n useEffect(function () {\n if (!fetchedRecommendations) {\n getRecommendations();\n }\n }, [outcome, fetchedOutcome, fetchedRecommendations, getRecommendations]);\n if (!outcome) {\n return _jsx(Loading, {}, void 0);\n }\n var unavailable = isUnavailable(outcome.current.state);\n var starter = isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass);\n return (_jsx(\"main\", __assign({ className: classes.main }, { children: _jsxs(\"div\", __assign({ className: classes.outcomeDetail }, { children: [_jsx(NextLastUpdated, {}, void 0), _jsxs(\"header\", __assign({ className: classes.top }, { children: [_jsxs(\"div\", __assign({ className: classes.iconTitle }, { children: [_jsx(OutcomeImage, { outcome: outcome, unavailable: unavailable, type: !isSmDown ? 'outcome large' : 'outcome', describedById: outcome.id.toString() }, void 0), _jsxs(\"div\", __assign({ className: classes.titleSkills }, { children: [_jsx(\"h1\", __assign({ id: outcome.id.toString(), className: clsx(typo.h4, classes.title) }, { children: outcome.name }), void 0), !unavailable && !isSmDown && outcome.isAssigned && (_jsx(ChangeTargetLevel, { user: user, skillOrOutcome: outcome }, void 0))] }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.addSkill }, { children: [unavailable ? (_jsx(UnavailableButton, { skillOrOutcome: outcome }, void 0)) : outcome.isAssigned ? (_jsx(RemoveButton, { user: user, skillOrOutcome: outcome, level: Level.None, recommended: false, onAccept: accept, describedById: outcome.id.toString(), starter: starter }, void 0)) : (_jsx(AddButton, { user: user, skillOrOutcome: outcome, level: Level.User, recommended: false, onAccept: accept, describedById: outcome.id.toString(), starter: starter }, void 0)), !unavailable && !isSmDown && (_jsx(\"span\", __assign({ className: typo.caption, style: { textAlign: 'center' } }, { children: outcome.current.state === CompetenceState.Unassigned ||\n outcome.current.state === CompetenceState.Locked\n ? 'ADD TO YOUR OUTCOMES'\n : 'IN YOUR OUTCOMES' }), void 0))] }), void 0)] }), void 0), !unavailable && isSmDown && outcome.isAssigned && (_jsx(ChangeTargetLevel, { user: user, skillOrOutcome: outcome }, void 0)), _jsx(DetailsOverviewSkillsOrOutcomes, { videoOverviewId: (_b = outcome === null || outcome === void 0 ? void 0 : outcome.videoOverviewId) !== null && _b !== void 0 ? _b : -1, overviewImage: (_c = outcome.overviewImage) !== null && _c !== void 0 ? _c : '', description: outcome.description, assignerName: (_e = (_d = outcome.assignment) === null || _d === void 0 ? void 0 : _d.assignerName) !== null && _e !== void 0 ? _e : '', assignedDate: (_g = (_f = outcome.assignment) === null || _f === void 0 ? void 0 : _f.dateTime) !== null && _g !== void 0 ? _g : '', isAssigned: outcome === null || outcome === void 0 ? void 0 : outcome.isAssigned, rating: outcome.videoOverviewRating, skillId: outcome.id, getSkillOrOutcome: function () { return getOutcomeDetails(Number(outcomeId), setOutcome); }, isOutcome: true }, void 0), _jsxs(\"div\", __assign({ className: classes.skillsActivities }, { children: [_jsxs(Paper, __assign({ elevation: 1, className: classes.skills }, { children: [_jsx(\"h2\", __assign({ className: typo.h6, style: { padding: '16px 24px', borderBottom: '1px solid rgba(0, 0, 0, 0.08)' } }, { children: \"Skills\" }), void 0), _jsx(\"ul\", __assign({ className: classes.skillItems, ref: skillsRef }, { children: outcome.skillIds.map(function (skillId, index) {\n var skill = allSkills === null || allSkills === void 0 ? void 0 : allSkills.find(function (skill) { return skill.id === skillId; });\n if (!skill) {\n return null;\n }\n return (_jsxs(\"li\", { children: [_jsx(OutcomeSkill, { skill: skill, tabIndex: index === 0 ? 0 : -1 }, void 0), index !== outcome.skillIds.length - 1 && (_jsx(Divider, { style: { marginBottom: '20px' } }, void 0))] }, skill.name + skill.current.targetLevel));\n }) }), void 0)] }), void 0), unavailable && (_jsx(\"div\", __assign({ className: classes.unavailablePanel }, { children: _jsx(UnavailablePanel, { skillOrOutcome: outcome, noBorder: true }, void 0) }), void 0)), !unavailable && recommendations && (_jsx(\"div\", __assign({ className: classes.recommendations }, { children: recommendations.map(function (recommendation, index, array) { return (_jsx(\"div\", __assign({ className: index < array.length - 1 ? classes.innerRecommendation : undefined }, { children: _jsx(RecommendedActivity, { recommendedActivity: recommendation, home: false }, void 0) }), recommendation.id)); }) }), void 0))] }), void 0), !unavailable && (_jsxs(Paper, __assign({ elevation: 1, component: \"section\", className: classes.badgeCard }, { children: [_jsx(\"h2\", __assign({ className: typo.h6, style: { margin: '16px 24px' }, id: 'Badges' }, { children: \"Badges\" }), void 0), _jsx(\"div\", __assign({ className: classes.badge }, { children: _jsx(Grid, __assign({ \"aria-labelledby\": 'Badges', container: true, spacing: isSmDown ? 2 : 4, justify: isSmDown ? 'center' : undefined, component: 'ul', ref: badgesRef, style: { listStyleType: 'none' } }, { children: outcome.badges.map(function (badge, index) { return (_jsx(Grid, __assign({ item: true, component: 'li' }, { children: _jsx(Badge, { badge: badge, route: (page !== null && page !== void 0 ? page : Pages.OutcomesPage) + \"/instructions\", tabIndex: index === 0 ? 0 : -1 }, void 0) }), \"\" + badge.name + badge.level)); }) }), void 0) }), void 0)] }), void 0))] }), void 0) }), void 0));\n};\nexport default OutcomeDetails;\n//# sourceMappingURL=OutcomeDetails.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { OutcomesContext } from '../contexts/OutcomesContext';\nimport { OutcomeService } from '../services/OutcomeService';\nimport { SkillService } from '../services/SkillService';\nimport { getToken } from '../utils/getToken';\nexport var useGetOutcomeDetails = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var outcomesContext = useContext(OutcomesContext);\n var getOutcomeDetails = function (outcomeId, setOutcome) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getOutcomeDetails(outcomeId)];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setOutcome(response);\n return [2];\n }\n });\n }); };\n var getAllSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, allSkills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (outcomesContext.allSkills) {\n return [2];\n }\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getAllSkills()];\n case 2:\n allSkills = _a.sent();\n if (!allSkills) {\n return [2];\n }\n outcomesContext.setAllSkills(allSkills);\n return [2];\n }\n });\n }); };\n return function (skillId, setOutcome) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getOutcomeDetails(skillId, setOutcome), getAllSkills()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetOutcomeDetails.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var ShowcaseContext = createContext({});\nexport var ShowcaseProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), rewards = _b[0], setRewards = _b[1];\n var showcaseContext = {\n rewards: rewards,\n setRewards: setRewards,\n };\n return _jsx(ShowcaseContext.Provider, __assign({ value: showcaseContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=ShowcaseContext.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { ShowcaseApi } from '../data/ShowcaseApi';\nvar ShowcaseService = (function () {\n function ShowcaseService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getRewards = function () { return __awaiter(_this, void 0, void 0, function () {\n var rewards;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.showcaseApi.getRewards()];\n case 1:\n rewards = _a.sent();\n if (!(rewards === null || rewards === void 0 ? void 0 : rewards.data)) {\n return [2, undefined];\n }\n return [2, rewards.data];\n }\n });\n }); };\n this.unlockAchievementDescription = function (id) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.showcaseApi.unlockAchievementDescription(id)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.token = token;\n this.clientType = clientType;\n this.showcaseApi = new ShowcaseApi(token, oid, tid, sid, clientType);\n }\n return ShowcaseService;\n}());\nexport { ShowcaseService };\n//# sourceMappingURL=ShowcaseService.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { ShowcaseContext } from '../contexts/ShowcaseContext';\nimport { ShowcaseService } from '../services/ShowcaseService';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nexport var useGetShowcaseData = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var showcaseContext = useContext(ShowcaseContext);\n var getUser = useGetUser();\n var getRewards = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, showcaseService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n showcaseService = new ShowcaseService(newToken, oid, tid, clientType);\n return [4, showcaseService.getRewards()];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n showcaseContext.setRewards(response);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser(), getRewards()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetShowcaseData.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Button } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useRef, useState } from 'react';\nimport { UserContext } from '../../contexts/UserContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { ACHIEVEMENTS_PATH } from '../../utils/constants';\nimport Dialog from '../Dialog';\nimport EngagementPointsIcon from '../icons/EngagementPointsIcon';\nimport { ShowcaseService } from '../../services/ShowcaseService';\nimport { getToken } from '../../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { GroupType } from '../../types/enums';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n achievement: (_a = {\n display: 'flex',\n alignItems: 'flex-start',\n marginBottom: 24,\n width: 300\n },\n _a[theme.breakpoints.down('md')] = {\n width: 270,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _a),\n achievementImage: {\n width: 70,\n marginRight: 16,\n },\n achievementBody: (_b = {},\n _b[theme.breakpoints.up('sm')] = {\n width: 190,\n },\n _b),\n achievementPoints: {\n display: 'flex',\n alignItems: 'center',\n },\n achievementPointsIcon: {\n marginRight: 4,\n height: 16,\n },\n unlockButton: {\n color: Colors.purple,\n fontFace: 'bold',\n cursor: 'pointer',\n },\n filter: {\n filter: 'opacity(75%) grayscale(1)',\n webkitFilter: 'opacity(75%) grayscale(1)',\n },\n });\n});\nvar Achievement = function (_a) {\n var achievement = _a.achievement;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var _d = __read(useState(false), 2), openBuyDescriptionDialog = _d[0], setOpenBuyDescriptionDialog = _d[1];\n var _e = __read(useState(false), 2), disabled = _e[0], setDisabled = _e[1];\n var cost = useRef(Math.floor(achievement.points / 2));\n var unlockDescription = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, showcaseService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n setDisabled(true);\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n showcaseService = new ShowcaseService(newToken, oid, tid, clientType);\n return [4, showcaseService.unlockAchievementDescription(achievement.id)];\n case 2:\n _a.sent();\n setDisabled(false);\n toggleDialog();\n return [2];\n }\n });\n }); };\n var toggleDialog = function () {\n setOpenBuyDescriptionDialog(!openBuyDescriptionDialog);\n };\n if (!user) {\n return null;\n }\n return (_jsxs(_Fragment, { children: [_jsxs(\"div\", __assign({ className: classes.achievement }, { children: [_jsx(\"img\", { alt: '', className: clsx(classes.achievementImage, !achievement.receivedOn && classes.filter), src: \"\" + ACHIEVEMENTS_PATH + achievement.image + \".svg\", loading: \"lazy\" }, void 0), _jsxs(\"div\", __assign({ className: classes.achievementBody }, { children: [_jsx(\"h3\", __assign({ className: typo.subtitle1 }, { children: achievement.name }), void 0), achievement.groupType !== GroupType.UnlockDescription || achievement.unlockDescription ? (_jsx(\"span\", __assign({ className: typo.label }, { children: achievement.description }), void 0)) : (_jsx(\"span\", __assign({ className: typo.label }, { children: _jsxs(Button, __assign({ variant: \"text\", onClick: toggleDialog, className: classes.unlockButton }, { children: [\"Unlock Description (\", cost.current, \" points)\"] }), void 0) }), void 0)), _jsxs(\"div\", __assign({ className: classes.achievementPoints }, { children: [_jsx(\"div\", __assign({ className: classes.achievementPointsIcon }, { children: _jsx(EngagementPointsIcon, { small: true }, void 0) }), void 0), _jsx(\"span\", __assign({ className: typo.label }, { children: achievement.receivedOn\n ? \"+\" + achievement.points + \" Earned\"\n : \"Earn \" + achievement.points + \" Points\" }), void 0)] }), void 0)] }), void 0)] }), void 0), _jsx(Dialog, { open: openBuyDescriptionDialog, onClose: toggleDialog, onAccept: user.engagementPoints >= cost.current ? unlockDescription : toggleDialog, title: \"\", text: user.engagementPoints >= cost.current ? '' : '', cancelText: user.engagementPoints >= cost.current ? 'No' : undefined, acceptText: user.engagementPoints >= cost.current ? 'Yes' : 'Okay', disabled: disabled, cancelDisabled: disabled }, void 0)] }, void 0));\n};\nexport default Achievement;\n//# sourceMappingURL=Achievement.js.map","export var getEarnedBadges = function (badges) {\n var newFilteredBadges = [];\n badges === null || badges === void 0 ? void 0 : badges.forEach(function (value) {\n if (value.awarded && value.dateAwarded) {\n newFilteredBadges.push(value);\n }\n });\n return newFilteredBadges.sort(function (a, b) {\n return a.dateAwarded < b.dateAwarded ? 1 : a.dateAwarded > b.dateAwarded ? -1 : 0;\n });\n};\n//# sourceMappingURL=getEarnedBadges.js.map","import { CompetenceState } from '../types/enums';\nexport var getInProgressBadges = function (badges) {\n var newFilteredBadges = [];\n badges === null || badges === void 0 ? void 0 : badges.forEach(function (value) {\n if (!value.awarded && value.state === CompetenceState.InProgress) {\n newFilteredBadges.push(value);\n }\n });\n return newFilteredBadges;\n};\n//# sourceMappingURL=getInProgressBadges.js.map","import { GroupType } from '../types/enums';\nexport var getNonSeriesAchievements = function (achievements) {\n var newFilteredAchievements = [];\n achievements === null || achievements === void 0 ? void 0 : achievements.forEach(function (value) {\n if (!value.groupType || value.groupType === GroupType.UnlockDescription) {\n newFilteredAchievements.push(value);\n }\n else if (value.groupType === GroupType.Hidden && value.receivedOn) {\n newFilteredAchievements.push(value);\n }\n });\n return newFilteredAchievements;\n};\n//# sourceMappingURL=getNonSeriesAchievements.js.map","import { GroupType } from '../types/enums';\nexport var getSeriesAchievements = function (achievements) {\n var newFilteredAchievements = [];\n achievements === null || achievements === void 0 ? void 0 : achievements.forEach(function (value) {\n if (value.groupType &&\n value.groupType !== GroupType.Hidden &&\n value.groupType !== GroupType.UnlockDescription) {\n if (value.receivedOn) {\n newFilteredAchievements.push(value);\n }\n else {\n var series = newFilteredAchievements.filter(function (element) { return element.groupType === value.groupType; });\n if (series.length === 0) {\n newFilteredAchievements.push(value);\n }\n else {\n var filteredSeries = series.filter(function (element) { return !element.receivedOn; });\n if (filteredSeries.length === 0) {\n newFilteredAchievements.push(value);\n }\n }\n }\n }\n });\n return newFilteredAchievements;\n};\n//# sourceMappingURL=getSeriesAchievements.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { getNonSeriesAchievements } from './getNonSeriesAchievements';\nimport { getSeriesAchievements } from './getSeriesAchievements';\nexport var getEarnedAchievements = function (achievements) {\n var filteredAchievements = [];\n var preFilteredAchievements = __spreadArray(__spreadArray([], __read(getNonSeriesAchievements(achievements)), false), __read(getSeriesAchievements(achievements)), false);\n preFilteredAchievements === null || preFilteredAchievements === void 0 ? void 0 : preFilteredAchievements.forEach(function (value) {\n if (value.receivedOn) {\n filteredAchievements.push(value);\n }\n });\n return filteredAchievements.sort(function (a, b) {\n return a.receivedOn > b.receivedOn ? -1 : a.receivedOn < b.receivedOn ? 1 : 0;\n });\n};\n//# sourceMappingURL=getEarnedAchievements.js.map","import { ClientType } from '../types/enums';\nexport var provideShowcaseRouteBasedOnClient = function (clientType, page, baseSubrout) {\n var finalRoute = baseSubrout;\n if (clientType !== ClientType.platform) {\n finalRoute = \"\" + page + baseSubrout;\n }\n return finalRoute;\n};\n//# sourceMappingURL=routeClientProvider.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Grid, Link as MuiLink, Paper, useMediaQuery } from '@material-ui/core';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext, useEffect, useState } from 'react';\nimport { Link } from 'react-router-dom';\nimport commaNumber from 'comma-number';\nimport { ShowcaseContext } from '../../contexts/ShowcaseContext';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { BADGES_PATH } from '../../utils/constants';\nimport { useGetShowcaseData } from '../../hooks/useGetShowcaseData';\nimport EngagementPointsIcon from '../icons/EngagementPointsIcon';\nimport Achievement from './Achievement';\nimport Badge from './Badge';\nimport Loading from '../Loading';\nimport { Pages } from '../../types/enums';\nimport MeasurementBanner from '../MeasurementBanner';\nimport { UserContext } from '../../contexts/UserContext';\nimport NextLastUpdated from '../NextLastUpdated';\nimport { getEarnedBadges } from '../../utils/getEarnedBadges';\nimport { getInProgressBadges } from '../../utils/getInProgressBadges';\nimport { getEarnedAchievements } from '../../utils/getEarnedAchievements';\nimport { provideShowcaseRouteBasedOnClient } from '../../utils/routeClientProvider';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f;\n return ({\n showcase: (_a = {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('sm')] = {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n },\n _a),\n box: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n },\n boxTitle: {\n height: 55,\n paddingLeft: 24,\n paddingRight: 24,\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n boxContent: {\n padding: 16,\n margin: 0,\n overflow: 'auto',\n },\n badges: {\n display: 'flex',\n overflowY: 'auto',\n padding: 0,\n listStyleType: 'none',\n },\n badgesBox: (_b = {\n width: 712,\n marginRight: 32,\n marginBottom: 32\n },\n _b[theme.breakpoints.down('md')] = {\n width: 431,\n marginBottom: 24,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 330,\n marginBottom: 24,\n marginRight: 0,\n },\n _b),\n achievementsPoints: (_c = {\n width: 338\n },\n _c[theme.breakpoints.down('md')] = {\n width: 305,\n },\n _c[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _c),\n achievementsBox: (_d = {\n marginBottom: 32,\n height: 484\n },\n _d[theme.breakpoints.down('md')] = {\n height: 'fit-content',\n },\n _d),\n achievementsBoxContent: (_e = {\n height: 429,\n listStyleType: 'none'\n },\n _e[theme.breakpoints.down('sm')] = {\n height: 'fit-content',\n },\n _e),\n pointsBoxContent: {\n display: 'flex',\n alignItems: 'center',\n padding: 16,\n },\n pointsBigNumber: {\n fontFamily: 'Ubuntu',\n fontWeight: 500,\n fontSize: 24,\n lineHeight: '28px',\n color: 'rgba(0, 0, 0, 0.8)',\n },\n pointsSmallNumber: {\n fontFamily: 'Ubuntu',\n fontSize: 16,\n lineHeight: '24px',\n color: 'rgba(0, 0, 0, 0.88)',\n },\n mobileButton: {\n marginTop: 24,\n display: 'flex',\n justifyContent: 'center',\n },\n link: {\n margin: 0,\n padding: 0,\n fontFamily: 'Ubuntu',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: 14,\n lineHeight: '20px',\n color: Colors.purple,\n textDecoration: 'none',\n textTransform: 'uppercase',\n },\n badgeEmptyState: (_f = {\n width: '100%',\n height: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n paddingLeft: 24,\n paddingRight: 24\n },\n _f[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n textAlign: 'center',\n },\n _f),\n });\n});\nvar Showcase = function (_a) {\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState(0), 2), count = _b[0], setCount = _b[1];\n var user = useContext(UserContext).user;\n var rewards = useContext(ShowcaseContext).rewards;\n var _c = useContext(HeaderContext), setTitle = _c.setTitle, setGoBack = _c.setGoBack, setTabs = _c.setTabs, setPage = _c.setPage;\n var clientType = useContext(TokenContext).clientType;\n var _d = __read(useState(false), 2), receivedData = _d[0], setReceivedData = _d[1];\n var getData = useGetShowcaseData();\n useEffect(function () {\n setTitle('Showcase');\n setGoBack(false);\n setTabs(undefined);\n setPage(page !== null && page !== void 0 ? page : Pages.ShowcasePage);\n }, [page, setGoBack, setPage, setTabs, setTitle]);\n useEffect(function () {\n if (!receivedData) {\n getData();\n setReceivedData(true);\n }\n }, [receivedData, getData]);\n var theme = useTheme();\n var isXsDown = useMediaQuery(theme.breakpoints.down('xs'));\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n useEffect(function () {\n if (rewards) {\n var newCount_1 = 0;\n rewards.achievements.forEach(function (achievement) {\n if (achievement.receivedOn) {\n newCount_1++;\n }\n });\n setCount(newCount_1);\n }\n }, [rewards]);\n if (!rewards) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(_Fragment, { children: [(user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) ? _jsx(MeasurementBanner, {}, void 0) : _jsx(NextLastUpdated, {}, void 0), _jsxs(\"main\", __assign({ className: classes.showcase }, { children: [_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: clsx(classes.box, classes.badgesBox) }, { children: [_jsxs(\"div\", __assign({ className: classes.boxTitle }, { children: [_jsxs(\"h2\", __assign({ className: typo.subtitle1 }, { children: [\"Your Badges (\", getEarnedBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length, \")\"] }), void 0), _jsx(MuiLink, __assign({ component: Link, to: (page !== null && page !== void 0 ? page : Pages.ShowcasePage) + \"/your-badges\", className: classes.link, \"aria-label\": 'View all of your badges' }, { children: \"View All\" }), void 0)] }), void 0), _jsxs(Grid, __assign({ component: 'ul', className: classes.badges, container: true, wrap: \"wrap\", spacing: 3, justify: isMdDown ? 'center' : 'flex-start', alignItems: \"flex-start\", style: { margin: 0, width: '100%' } }, { children: [getEarnedBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length === 0 &&\n getInProgressBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length === 0 && (_jsxs(\"li\", __assign({ className: classes.badgeEmptyState }, { children: [_jsx(\"img\", { src: BADGES_PATH + \"badge.png\", alt: \"\", style: { filter: 'opacity(0.5)' } }, void 0), _jsxs(\"div\", { children: [_jsx(\"h2\", __assign({ className: typo.subtitle1 }, { children: \"You don\\u2019t have any badges!\" }), void 0), _jsx(\"p\", __assign({ className: typo.subtitle2 }, { children: \"Once you have Outcomes, you will see badges you can earn here.\" }), void 0)] }, void 0)] }), void 0)), getEarnedBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges)\n .concat(getInProgressBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges))\n .slice(0, 9)\n .map(function (badge) { return (_jsx(Grid, __assign({ component: 'li', item: true, style: { padding: 0, paddingLeft: 12, paddingRight: 12, height: 288 } }, { children: _jsx(Badge, { badge: badge, route: provideShowcaseRouteBasedOnClient(clientType, Pages.ShowcasePage, '/instructions') }, void 0) }), \"\" + badge.name + badge.level)); })] }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.achievementsPoints }, { children: [_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: clsx(classes.box, classes.achievementsBox) }, { children: [_jsxs(\"div\", __assign({ className: classes.boxTitle }, { children: [_jsxs(\"h2\", __assign({ className: typo.subtitle1 }, { children: [\"Your Achievements (\", count, \")\"] }), void 0), _jsx(MuiLink, __assign({ component: Link, to: (page !== null && page !== void 0 ? page : Pages.ShowcasePage) + \"/your-achievements\", className: classes.link, \"aria-label\": 'View all achievements' }, { children: \"View All\" }), void 0)] }), void 0), _jsx(\"ul\", __assign({ className: clsx(classes.boxContent, classes.achievementsBoxContent) }, { children: getEarnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements)\n .slice(0, 6)\n .map(function (achievement, index) { return (_jsx(\"li\", { children: _jsx(Achievement, { achievement: achievement }, void 0) }, achievement.name + index)); }) }), void 0)] }), void 0), _jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: classes.box, style: { marginBottom: 24 } }, { children: [_jsx(\"div\", __assign({ className: classes.boxTitle }, { children: _jsx(\"h2\", __assign({ className: typo.subtitle1 }, { children: \"Engagement Points Earned\" }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.pointsBoxContent }, { children: [_jsx(\"div\", __assign({ style: { marginRight: 16, height: 52 } }, { children: _jsx(EngagementPointsIcon, { large: true }, void 0) }), void 0), _jsx(\"div\", __assign({ style: !isSmDown && !isXsDown ? { marginRight: 64 } : { marginRight: 32 } }, { children: _jsx(\"div\", __assign({ className: classes.pointsBigNumber }, { children: (rewards === null || rewards === void 0 ? void 0 : rewards.engagementPoints.total) ? commaNumber(rewards.engagementPoints.total) : 0 }), void 0) }), void 0)] }), void 0)] }), void 0)] }), void 0)] }), void 0)] }, void 0));\n};\nexport default Showcase;\n//# sourceMappingURL=Showcase.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { GroupType } from '../types/enums';\nimport { getNonSeriesAchievements } from './getNonSeriesAchievements';\nimport { getSeriesAchievements } from './getSeriesAchievements';\nexport var getUnearnedAchievements = function (achievements) {\n var filteredAchievements = [];\n var preFilteredAchievements = __spreadArray(__spreadArray([], __read(getNonSeriesAchievements(achievements)), false), __read(getSeriesAchievements(achievements)), false);\n preFilteredAchievements === null || preFilteredAchievements === void 0 ? void 0 : preFilteredAchievements.forEach(function (value) {\n if (!value.receivedOn && value.groupType !== GroupType.Hidden) {\n filteredAchievements.push(value);\n }\n });\n return filteredAchievements;\n};\n//# sourceMappingURL=getUnearnedAchivements.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nimport { ShowcaseContext } from '../../contexts/ShowcaseContext';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useContext, useEffect, useState } from 'react';\nimport clsx from 'clsx';\nimport { Grid, Paper, useMediaQuery } from '@material-ui/core';\nimport Achievement from './Achievement';\nimport { Colors } from '../../utils/colors';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { useTypography } from '../../styles/Typography';\nimport { getEarnedAchievements } from '../../utils/getEarnedAchievements';\nimport { getUnearnedAchievements } from '../../utils/getUnearnedAchivements';\nimport { useGetShowcaseData } from '../../hooks/useGetShowcaseData';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n yourAchievements: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n box: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n },\n boxTitle: {\n height: 55,\n paddingLeft: 24,\n paddingRight: 24,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08);',\n },\n achievements: {\n display: 'flex',\n listStyleType: 'none',\n paddingTop: 24,\n },\n achievementsBox: (_a = {\n width: 1080,\n marginBottom: 16\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n });\n});\nvar YourAchievements = function () {\n var _a, _b;\n var typo = useTypography();\n var classes = useStyles();\n var rewards = useContext(ShowcaseContext).rewards;\n var _c = useContext(HeaderContext), setTitle = _c.setTitle, setGoBack = _c.setGoBack;\n var _d = __read(useState(false), 2), receivedData = _d[0], setReceivedData = _d[1];\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var getData = useGetShowcaseData();\n useEffect(function () {\n setTitle('Back');\n setGoBack(true);\n }, [setGoBack, setTitle]);\n useEffect(function () {\n if (!rewards && !receivedData) {\n getData();\n setReceivedData(true);\n }\n }, [getData, receivedData, rewards]);\n return (_jsxs(\"main\", __assign({ className: classes.yourAchievements }, { children: [getEarnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements).length > 0 && (_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: clsx(classes.box, classes.achievementsBox) }, { children: [_jsx(\"div\", __assign({ className: classes.boxTitle }, { children: _jsxs(\"h2\", __assign({ className: typo.subtitle1 }, { children: [\"Earned Achievements (\", getEarnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements).length, \")\"] }), void 0) }), void 0), _jsx(Grid, __assign({ component: 'ul', className: classes.achievements, container: true, wrap: \"wrap\", spacing: 3, justify: 'flex-start', alignItems: \"flex-start\", style: { width: '100%', margin: 0 } }, { children: (_a = getEarnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements)) === null || _a === void 0 ? void 0 : _a.map(function (achievement, index) { return (_jsx(Grid, __assign({ component: 'li', item: true, style: isSmDown\n ? {\n padding: 0,\n width: '100%',\n }\n : {\n padding: 0,\n paddingLeft: 16,\n paddingRight: 16,\n } }, { children: _jsx(Achievement, { achievement: achievement }, achievement.name) }), \"\" + achievement.name + index)); }) }), void 0)] }), void 0)), getUnearnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements).length > 0 && (_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: clsx(classes.box, classes.achievementsBox) }, { children: [_jsx(\"div\", __assign({ className: classes.boxTitle }, { children: _jsxs(\"h2\", __assign({ className: typo.subtitle1 }, { children: [\"Other Achievements (\", getUnearnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements).length, \")\"] }), void 0) }), void 0), _jsx(Grid, __assign({ component: 'ul', className: classes.achievements, container: true, wrap: \"wrap\", spacing: 3, justify: 'flex-start', alignItems: \"flex-start\", style: { width: '100%', margin: 0 } }, { children: (_b = getUnearnedAchievements(rewards === null || rewards === void 0 ? void 0 : rewards.achievements)) === null || _b === void 0 ? void 0 : _b.map(function (achievement, index) { return (_jsx(Grid, __assign({ component: 'li', item: true, style: isSmDown\n ? {\n padding: 0,\n width: '100%',\n }\n : {\n padding: 0,\n paddingLeft: 16,\n paddingRight: 16,\n } }, { children: _jsx(Achievement, { achievement: achievement }, achievement.name) }), \"\" + achievement.name + index)); }) }), void 0)] }), void 0))] }), void 0));\n};\nexport default YourAchievements;\n//# sourceMappingURL=YourAchievements.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { Colors } from '../../utils/colors';\nimport { useContext, useEffect, useState } from 'react';\nimport { ShowcaseContext } from '../../contexts/ShowcaseContext';\nimport { Grid, Paper, useMediaQuery } from '@material-ui/core';\nimport clsx from 'clsx';\nimport Badge from './Badge';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { useTypography } from '../../styles/Typography';\nimport { getEarnedBadges } from '../../utils/getEarnedBadges';\nimport { getInProgressBadges } from '../../utils/getInProgressBadges';\nimport { provideShowcaseRouteBasedOnClient } from '../../utils/routeClientProvider';\nimport { useGetShowcaseData } from '../../hooks/useGetShowcaseData';\nimport { Pages } from '../../types/enums';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n yourBadges: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n box: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n },\n boxTitle: {\n height: 55,\n paddingLeft: 24,\n paddingRight: 24,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08);',\n },\n badges: {\n display: 'flex',\n listStyleType: 'none',\n padding: 0,\n },\n badgesBox: (_a = {\n width: 1080,\n marginBottom: 16,\n paddingBottom: 24\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n });\n});\nvar YourBadges = function () {\n var typo = useTypography();\n var classes = useStyles();\n var theme = useTheme();\n var rewards = useContext(ShowcaseContext).rewards;\n var _a = useContext(HeaderContext), setTitle = _a.setTitle, setGoBack = _a.setGoBack;\n var clientType = useContext(TokenContext).clientType;\n var _b = __read(useState(false), 2), receivedData = _b[0], setReceivedData = _b[1];\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var getData = useGetShowcaseData();\n useEffect(function () {\n setTitle('Back');\n setGoBack(true);\n }, [setGoBack, setTitle]);\n useEffect(function () {\n if (!rewards && !receivedData) {\n getData();\n setReceivedData(true);\n }\n }, [getData, receivedData, rewards]);\n return (_jsxs(\"main\", __assign({ className: classes.yourBadges }, { children: [getEarnedBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length > 0 && (_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: clsx(classes.box, classes.badgesBox) }, { children: [_jsx(\"div\", __assign({ className: classes.boxTitle }, { children: _jsxs(\"h2\", __assign({ className: typo.subtitle1 }, { children: [\"Earned Badges (\", getEarnedBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length, \")\"] }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.badges }, { children: _jsx(Grid, __assign({ component: 'ul', container: true, wrap: \"wrap\", spacing: 3, justify: isMdDown ? 'center' : 'flex-start', alignItems: \"flex-start\", style: { width: '100%', margin: 0 } }, { children: getEarnedBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).map(function (badge) { return (_jsx(Grid, __assign({ component: 'li', item: true, style: {\n padding: 0,\n paddingLeft: 32,\n paddingRight: 32,\n height: 288,\n } }, { children: _jsx(Badge, { badge: badge, route: provideShowcaseRouteBasedOnClient(clientType, Pages.ShowcasePage, '/instructions') }, void 0) }), \"\" + badge.name + badge.level)); }) }), void 0) }), void 0)] }), void 0)), getInProgressBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length > 0 && (_jsxs(Paper, __assign({ component: \"section\", elevation: 1, className: clsx(classes.box, classes.badgesBox) }, { children: [_jsx(\"div\", __assign({ className: classes.boxTitle }, { children: _jsxs(\"h2\", __assign({ className: typo.subtitle1 }, { children: [\"In Progress Badges (\", getInProgressBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).length, \")\"] }), void 0) }), void 0), _jsx(Grid, __assign({ component: 'ul', className: classes.badges, container: true, wrap: \"wrap\", spacing: 3, justify: isMdDown ? 'center' : 'flex-start', alignItems: \"flex-start\", style: { width: '100%', margin: 0 } }, { children: getInProgressBadges(rewards === null || rewards === void 0 ? void 0 : rewards.badges).map(function (badge) { return (_jsx(Grid, __assign({ component: 'li', item: true, style: {\n padding: 0,\n paddingLeft: 32,\n paddingRight: 32,\n height: 288,\n } }, { children: _jsx(Badge, { badge: badge, route: \"/instructions\" }, void 0) }), \"\" + badge.name + badge.level)); }) }), void 0)] }), void 0))] }), void 0));\n};\nexport default YourBadges;\n//# sourceMappingURL=YourBadges.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { IconButton, makeStyles } from '@material-ui/core';\nimport { BADGE_URL, OTHER_PATH } from '../utils/constants';\nimport clsx from 'clsx';\nimport { HeaderContext } from '../contexts/HeaderContext';\nimport { Colors } from '../utils/colors';\nimport { Copy } from 'react-feather';\nimport { useParams } from 'react-router';\nimport { useTeams } from 'msteams-react-base-component';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f, _g;\n return ({\n root: {\n display: 'flex',\n justifyContent: 'center',\n },\n image: (_a = {\n maxHeight: 500,\n boxShadow: '0 1px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.08)',\n borderRadius: 5\n },\n _a[theme.breakpoints.down('sm')] = {\n maxHeight: 300,\n },\n _a[theme.breakpoints.down('xs')] = {\n maxHeight: 200,\n },\n _a),\n imageContainer: (_b = {\n display: 'flex',\n justifyContent: 'space-between',\n padding: 15,\n width: '100%',\n gap: '8px'\n },\n _b[theme.breakpoints.down('md')] = {\n display: 'block',\n textAlign: 'center',\n flexDirection: 'column',\n },\n _b),\n imageFirstBox: (_c = {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: '8px',\n maxWidth: '50%',\n paddingBottom: '8px'\n },\n _c[theme.breakpoints.down('md')] = {\n display: 'block',\n maxWidth: '100%',\n },\n _c),\n imageFirst: (_d = {\n maxWidth: 300\n },\n _d[theme.breakpoints.down('sm')] = {\n maxWidth: '100%',\n },\n _d),\n imageSecond: (_e = {\n maxWidth: 400\n },\n _e[theme.breakpoints.down('sm')] = {\n maxWidth: '100%',\n },\n _e),\n document: (_f = {\n backgroundColor: '#fff',\n boxShadow: '0 1px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.08)',\n borderRadius: 5,\n padding: '15px 30px',\n width: 1040\n },\n _f[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _f[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _f),\n items: {\n display: 'flex',\n justifyContent: 'space-between',\n borderBottom: \"2px solid \" + Colors.purple,\n margin: 0,\n padding: 0,\n },\n item: {\n listStyle: 'disc',\n },\n titleRow: {\n display: 'flex',\n justifyContent: 'space-between',\n },\n primaryTitle: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontWeight: 600,\n fontSize: 24,\n lineHeight: '32px',\n },\n secondaryTitle: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontWeight: 600,\n fontSize: 16,\n lineHeight: '12px',\n },\n paragraph: (_g = {\n color: Colors.textSecondary,\n fontFamily: 'Open Sans',\n fontSize: 14,\n letterSpacing: 0.25,\n lineHeight: '30px',\n paddingBottom: 10\n },\n _g[theme.breakpoints.down('md')] = {\n display: 'block',\n },\n _g),\n stack: {\n display: 'block',\n width: '100%',\n },\n body: {\n padding: 0,\n margin: 0,\n },\n bold: {\n fontWeight: 600,\n },\n });\n});\nvar Instructions = function () {\n var classes = useStyles();\n var assertionId = useParams().assertionId;\n var _a = __read(useState(false), 2), didSetHeader = _a[0], setDidSetHeader = _a[1];\n var _b = useContext(HeaderContext), setTitle = _b.setTitle, setGoBack = _b.setGoBack, setTabs = _b.setTabs;\n var _c = __read(useTeams(), 1), inTeams = _c[0].inTeams;\n useEffect(function () {\n if (!didSetHeader) {\n setTitle('Linkedin Instructions');\n setGoBack(true);\n setTabs(undefined);\n setDidSetHeader(true);\n }\n }, [didSetHeader, setGoBack, setTabs, setTitle]);\n var copyUrl = function () {\n if (!assertionId) {\n return;\n }\n navigator.clipboard.writeText(BADGE_URL + \"/\" + assertionId);\n };\n return (_jsx(\"main\", __assign({ className: classes.root }, { children: _jsxs(\"div\", __assign({ className: classes.document }, { children: [_jsx(\"div\", __assign({ className: classes.titleRow }, { children: _jsx(\"h3\", __assign({ className: classes.primaryTitle }, { children: \"How to Post a Badge to LinkedIn Certifications\" }), void 0) }), void 0), _jsx(\"p\", __assign({ className: clsx(classes.items, classes.paragraph) }, { children: \"Now that you have earned an Outcome Badge, you can post it to your LinkedIn profile under Certifications. This can be done in addition to sharing a post to your LinkedIn feed. Posting to certifications allows others to see your verified skills in using Microsoft 365 to its full potential.\" }), void 0), _jsx(\"ul\", __assign({ className: classes.body }, { children: _jsx(\"li\", __assign({ className: clsx(classes.items, classes.paragraph) }, { children: _jsxs(\"div\", __assign({ className: classes.stack }, { children: [_jsxs(\"ul\", __assign({ className: classes.item }, { children: [_jsxs(\"li\", { children: [\"Login to\", ' ', _jsx(\"a\", __assign({ href: \"https://linkedin.com\", target: \"_blank\", rel: \"noreferrer\" }, { children: \"LinkedIn\" }), void 0), ' ', \"and go to your Profile page\"] }, void 0), _jsxs(\"li\", { children: [\"Click \", _jsx(\"span\", __assign({ className: classes.bold }, { children: \"Add profile section\" }), void 0)] }, void 0), _jsxs(\"li\", { children: [\"Choose \", _jsx(\"span\", __assign({ className: classes.bold }, { children: \"Recommended\" }), void 0)] }, void 0), _jsxs(\"li\", { children: [\"Click on \", _jsx(\"span\", __assign({ className: classes.bold }, { children: \"Add licenses & certifications\" }), void 0)] }, void 0), _jsx(\"li\", { children: \"Enter the name of your Nulia badge in the Name field\" }, void 0), _jsxs(\"li\", { children: [\"Enter \", _jsx(\"span\", __assign({ className: classes.bold }, { children: \"Nulia\" }), void 0), \" as the Issuing organization, and chose Nulia from the drop-down list of companies\"] }, void 0), _jsx(\"li\", { children: \"Enter the date you received the Badge or leave the date fields blank\" }, void 0), _jsx(\"li\", { children: \"Leave the Credential Id box blank\" }, void 0), _jsxs(\"li\", { children: [\"Copy the URL below into the Credential URL box then click\", ' ', _jsx(\"span\", __assign({ className: classes.bold }, { children: \"Save\" }), void 0)] }, void 0), _jsx(\"li\", { children: \"URL Link line goes here\" }, void 0), _jsxs(\"li\", { children: [BADGE_URL + \"/\" + assertionId, !inTeams && (_jsx(IconButton, __assign({ onClick: copyUrl, style: {\n marginLeft: 4,\n } }, { children: _jsx(Copy, { width: 16, height: 16 }, void 0) }), void 0))] }, void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.imageContainer }, { children: [_jsxs(\"div\", __assign({ className: classes.imageFirstBox }, { children: [_jsx(\"img\", { className: classes.imageFirst, src: OTHER_PATH + \"linkedin-1.png\", alt: \"part 1-1\" }, void 0), _jsx(\"img\", { className: classes.imageSecond, src: OTHER_PATH + \"linkedin-2.png\", alt: \"part 1-2\" }, void 0)] }), void 0), _jsx(\"img\", { className: classes.image, src: OTHER_PATH + \"linkedin-3.png\", alt: \"part 2-1\" }, void 0)] }), void 0)] }), void 0) }), void 0) }), void 0)] }), void 0) }), void 0));\n};\nexport default Instructions;\n//# sourceMappingURL=Instructions.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useMediaQuery, useTheme } from '@material-ui/core';\nimport * as d3 from 'd3';\nimport { useEffect } from 'react';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { isFloat } from '../../utils/numberUtils';\nvar color = function (key) {\n if (!key) {\n console.warn('error: key not set');\n }\n if (key === 'inProgress') {\n return Colors.yellow;\n }\n else if (key === 'needsAttention') {\n return Colors.red;\n }\n else {\n return Colors.green;\n }\n};\nvar keyToString = function (key) {\n if (!key) {\n console.warn('error: key not set');\n }\n if (key === 'inProgress') {\n return 'In Progress';\n }\n else if (key === 'needsAttention') {\n return 'Need Attention';\n }\n else {\n return 'Attained';\n }\n};\nvar UserGraph = function (_a) {\n var dataset = _a.dataset;\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var typo = useTypography();\n var svg_width = isSmDown ? 330 : isMdDown ? 628 : 718;\n var svg_height = isSmDown ? 350 : isMdDown ? 380 : 350;\n var margin = { top: 20, right: isSmDown ? 16 : 30, bottom: 50, left: isSmDown ? 60 : 80 };\n var innerWidth = svg_width - margin.right - margin.left;\n var innerHeight = svg_height - margin.top - margin.bottom;\n var labelFormat = function (d) {\n var values = d.split('-');\n if (values[2] !== '1')\n return '';\n var date = new Date(+values[0], +values[1] - 1, +values[2]);\n return date.toLocaleString('default', { month: 'short' });\n };\n useEffect(function () {\n var _a;\n var svg = d3.select('#user-graph');\n d3.selectAll('#user-graph > *').remove();\n if (!dataset || dataset.length === 0) {\n return;\n }\n var legend = svg.append('g').attr('aria-label', 'Legend');\n var legendY = svg_height - margin.bottom / 2;\n var dotX = function (index) {\n return (index * svg_width * (isSmDown && index === 1 ? 1.1 : 1)) / 3 + (isSmDown ? 24 : margin.left);\n };\n var textX = function (index) { return dotX(index) + 12; };\n legend.append('circle').attr('fill', Colors.red).attr('cx', dotX(0));\n legend.append('text').text('Needs Attention').attr('x', textX(0));\n legend.append('circle').attr('fill', Colors.yellow).attr('cx', dotX(1));\n legend.append('text').text('In Progress').attr('x', textX(1));\n legend.append('circle').attr('fill', Colors.green).attr('cx', dotX(2));\n legend.append('text').text('Attained').attr('x', textX(2));\n legend.selectAll('circle').attr('r', 7).attr('cy', legendY);\n legend\n .selectAll('text')\n .attr('alignment-baseline', 'middle')\n .attr('y', legendY)\n .attr('class', typo.caption)\n .attr('fill', Colors.textSecondary);\n var newDataset = dataset.map(function (item) {\n return {\n weekString: item.weekString,\n inProgress: item.inProgress,\n needsAttention: item.needsAttention,\n maintaining: item.maintaining,\n };\n });\n var stack = d3\n .stack()\n .keys(['needsAttention', 'inProgress', 'maintaining'])\n .order(function (d) { return d.keys(); });\n var series = stack(newDataset).map(function (d) { return (d.forEach(function (p) { return (p.key = d.key); }), d); });\n var xValue = function (d) { return d.weekString; };\n var xScale = d3.scaleBand().domain(newDataset.map(xValue)).range([0, innerWidth]).padding(0.1);\n var yScale = d3\n .scaleLinear()\n .domain([0, (_a = d3.max(series, function (d) { return d3.max(d, function (d) { return d[1]; }); })) !== null && _a !== void 0 ? _a : 0])\n .range([innerHeight, 0]);\n var x_axis = d3.axisBottom(xScale).tickFormat(labelFormat).scale(xScale);\n svg.append('text')\n .text('# Demonstrated')\n .attr('aria-label', 'y-axis: number of outcomes demonstrated')\n .attr('class', typo.overlineMini)\n .attr('fill', Colors.textSecondary)\n .attr('transform', 'rotate(90)')\n .attr('text-anchor', 'middle')\n .attr('x', svg_height / 2)\n .attr('y', -15);\n var y_axis = d3\n .axisLeft(yScale)\n .tickFormat(function (interval) {\n return isFloat(interval.valueOf()) ? '' : interval.toString();\n })\n .scale(yScale);\n svg.append('g')\n .attr('stroke-width', 0)\n .attr('transform', \"translate(\" + margin.left + \", 5)\")\n .attr('aria-hidden', 'true')\n .call(y_axis);\n svg.append('g')\n .attr('stroke-width', 0)\n .attr('transform', \"translate(\" + margin.left + \", \" + innerHeight + \")\")\n .attr('aria-hidden', 'true')\n .call(x_axis);\n var xAxis = svg.append('g').attr('stroke-width', 0).attr('class', 'x-axis');\n xAxis.insert('text').text('x-axis: month / day').style('opacity', '0');\n xAxis\n .call(x_axis)\n .attr('transform', \"translate(\" + margin.left + \", \" + innerHeight + \")\")\n .selectAll('.x-axis .tick')\n .attr('transform', \"translate(-\" + margin.left + \", -\" + innerHeight + \")\")\n .data(newDataset)\n .selectAll('.x-axis .tick text')\n .style('opacity', '0');\n d3.map(series, function (s) {\n return svg\n .selectAll('.x-axis .tick')\n .data(s)\n .insert('rect')\n .attr('fill', function (d) { return color(d.key); })\n .attr('x', function (d) { var _a; return ((_a = xScale(d.data.weekString)) !== null && _a !== void 0 ? _a : 0) + margin.left; })\n .attr('y', function (d) { return yScale(d[1]); })\n .attr('height', function (d) { return yScale(d[0]) - yScale(d[1]); })\n .attr('width', xScale.bandwidth());\n });\n d3.map(series, function (s) {\n return svg\n .selectAll('.x-axis .tick')\n .data(s)\n .insert('text')\n .attr('class', 'title')\n .text(function (d) { return keyToString(d.key) + \": \" + (d[1] - d[0]); });\n });\n }, [\n dataset,\n innerHeight,\n innerWidth,\n isMdDown,\n isSmDown,\n margin.bottom,\n margin.left,\n svg_height,\n svg_width,\n typo.caption,\n typo.overlineMini,\n ]);\n return _jsx(\"svg\", { id: \"user-graph\", className: 'bar-chart', width: svg_width, height: svg_height }, void 0);\n};\nexport default UserGraph;\n//# sourceMappingURL=UserGraph.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { createContext, useState } from 'react';\nimport { BulkAssignPanel, } from '../types/types';\nexport var InsightsContext = createContext({});\nexport var InsightsProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(false), 2), openOutcomeDetailDrawer = _b[0], setOpenOutcomeDetailDrawer = _b[1];\n var _c = __read(useState([]), 2), reports = _c[0], setReports = _c[1];\n var _d = __read(useState(BulkAssignPanel.Unknown), 2), panel = _d[0], setPanel = _d[1];\n var _e = __read(useState(false), 2), outcomeDrawerOpen = _e[0], setOutcomeDrawerOpen = _e[1];\n var _f = __read(useState(undefined), 2), assignableOutcomes = _f[0], setAssignableOutcomes = _f[1];\n var _g = __read(useState(undefined), 2), outcome = _g[0], setOutcome = _g[1];\n var _h = __read(useState(undefined), 2), allSkills = _h[0], setAllSkills = _h[1];\n var _j = __read(useState(undefined), 2), direct = _j[0], setDirect = _j[1];\n var _k = __read(useState(undefined), 2), regionFilter = _k[0], setRegionFilter = _k[1];\n var _l = __read(useState(undefined), 2), departmentFilter = _l[0], setDepartmentFilter = _l[1];\n var _m = __read(useState(undefined), 2), licenseFilter = _m[0], setLicenseFilter = _m[1];\n var _o = __read(useState(undefined), 2), levelFilter = _o[0], setLevelFilter = _o[1];\n var _p = __read(useState(undefined), 2), assignmentFilter = _p[0], setAssignmentFilter = _p[1];\n var _q = __read(useState({\n search: '',\n department: '',\n region: '',\n direct: '',\n assignmentType: '',\n level: '',\n status: '',\n time: 16,\n license: '',\n }), 2), filter = _q[0], setFilter = _q[1];\n var _r = __read(useState(''), 2), searchValue = _r[0], setSearchValue = _r[1];\n var _s = __read(useState('desc'), 2), orderOutcomes = _s[0], setOrderOutcomes = _s[1];\n var _t = __read(useState('assigned'), 2), orderByOutcomes = _t[0], setOrderByOutcomes = _t[1];\n var _u = __read(useState('asc'), 2), orderUsers = _u[0], setOrderUsers = _u[1];\n var _v = __read(useState('name'), 2), orderByUsers = _v[0], setOrderByUsers = _v[1];\n var _w = __read(useState(0), 2), usersTablePage = _w[0], setUsersTablePage = _w[1];\n var _x = __read(useState(10), 2), usersTableRowsPerPage = _x[0], setUsersTableRowsPerPage = _x[1];\n var _y = __read(useState(), 2), availableLevelOptions = _y[0], setAvailableLevelOptions = _y[1];\n var insightsContext = {\n openOutcomeDetailDrawer: openOutcomeDetailDrawer,\n setOpenOutcomeDetailDrawer: setOpenOutcomeDetailDrawer,\n reports: reports,\n setReports: setReports,\n panel: panel,\n setPanel: setPanel,\n outcomeDrawerOpen: outcomeDrawerOpen,\n setOutcomeDrawerOpen: setOutcomeDrawerOpen,\n assignableOutcomes: assignableOutcomes,\n setAssignableOutcomes: setAssignableOutcomes,\n outcome: outcome,\n setOutcome: setOutcome,\n allSkills: allSkills,\n setAllSkills: setAllSkills,\n direct: direct,\n setDirect: setDirect,\n regionFilter: regionFilter,\n setRegionFilter: setRegionFilter,\n departmentFilter: departmentFilter,\n setDepartmentFilter: setDepartmentFilter,\n licenseFilter: licenseFilter,\n setLicenseFilter: setLicenseFilter,\n levelFilter: levelFilter,\n setLevelFilter: setLevelFilter,\n assignmentFilter: assignmentFilter,\n setAssignmentFilter: setAssignmentFilter,\n filter: filter,\n setFilter: setFilter,\n searchValue: searchValue,\n setSearchValue: setSearchValue,\n orderOutcomes: orderOutcomes,\n setOrderOutcomes: setOrderOutcomes,\n orderByOutcomes: orderByOutcomes,\n setOrderByOutcomes: setOrderByOutcomes,\n orderUsers: orderUsers,\n setOrderUsers: setOrderUsers,\n orderByUsers: orderByUsers,\n setOrderByUsers: setOrderByUsers,\n usersTablePage: usersTablePage,\n setUsersTablePage: setUsersTablePage,\n usersTableRowsPerPage: usersTableRowsPerPage,\n setUsersTableRowsPerPage: setUsersTableRowsPerPage,\n availableLevelOptions: availableLevelOptions,\n setAvailableLevelOptions: setAvailableLevelOptions,\n };\n return _jsx(InsightsContext.Provider, __assign({ value: insightsContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=InsightsProvider.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles, withStyles } from '@material-ui/core/styles';\nimport { InputBase, Select as MuiSelect } from '@material-ui/core';\nimport { Colors } from '../../utils/colors';\nimport { ChevronDown } from 'react-feather';\nvar useStyles = makeStyles({\n selectPaper: {\n backgroundColor: Colors.white,\n boxShadow: '0 5px 16px 1px rgba(0,0,0,0.08), 0 2px 8px 0 rgba(0,0,0,0.08)',\n },\n select: {\n borderRadius: 4,\n '&:focus': {\n borderRadius: 4,\n backgroundColor: 'rgba(101,78,163,0.08) !important',\n },\n },\n error: {\n border: '1px solid red !important',\n },\n icon: {\n top: 'calc(50% - 8px)',\n right: 4,\n height: 16,\n width: 16,\n },\n});\nvar DarkInput = withStyles({\n root: {\n height: 36,\n width: 166,\n },\n input: {\n backgroundColor: Colors.background,\n border: 0,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '24px',\n paddingLeft: 16,\n color: Colors.textSecondary,\n },\n})(InputBase);\nvar LightInput = withStyles({\n root: {\n height: 36,\n width: 166,\n },\n input: {\n backgroundColor: Colors.white,\n border: 0,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '24px',\n paddingLeft: 16,\n color: Colors.textSecondary,\n },\n})(InputBase);\nvar Select = function (_a) {\n var children = _a.children, id = _a.id, labelId = _a.labelId, value = _a.value, onChange = _a.onChange, light = _a.light, style = _a.style, error = _a.error, disabled = _a.disabled, displayEmpty = _a.displayEmpty, renderValue = _a.renderValue;\n var classes = useStyles();\n return (_jsx(MuiSelect, __assign({ id: id, labelId: labelId, value: value, onChange: onChange, input: light ? _jsx(LightInput, {}, void 0) : _jsx(DarkInput, {}, void 0), MenuProps: {\n classes: {\n paper: classes.selectPaper,\n },\n }, classes: {\n root: error ? classes.error : undefined,\n select: classes.select,\n icon: classes.icon,\n }, style: style, disabled: disabled, displayEmpty: displayEmpty, renderValue: renderValue, IconComponent: function (props) { return _jsx(ChevronDown, __assign({}, props), void 0); } }, { children: children }), void 0));\n};\nexport default Select;\n//# sourceMappingURL=Select.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport Dialog from '../Dialog';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { InsightsContext } from '../../contexts/InsightsProvider';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { UserContext } from '../../contexts/UserContext';\nimport Select from '../select/Select';\nimport { MenuItem } from '@material-ui/core';\nimport { Level } from '../../types/enums';\nimport { useHistory } from 'react-router-dom';\nvar useStyles = makeStyles({\n select: {\n marginTop: 8,\n },\n label: {\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n marginBottom: 4,\n },\n dialog: {},\n});\nvar BulkUnassignOutcomeDialog = function (_a) {\n var page = _a.page, open = _a.open, onClose = _a.onClose, reports = _a.reports, outcomeId = _a.outcomeId;\n var classes = useStyles();\n var _b = __read(useState(false), 2), disableButton = _b[0], setDisableButton = _b[1];\n var user = useContext(UserContext).user;\n var assignableOutcomes = useContext(InsightsContext).assignableOutcomes;\n var _c = __read(useState(0), 2), outcome = _c[0], setOutcome = _c[1];\n var _d = __read(useState(false), 2), outcomeError = _d[0], setOutcomeError = _d[1];\n var ApiService = useApiService();\n var history = useHistory();\n var selectOutcome = function (event) {\n setOutcomeError(false);\n setOutcome(Number(event.target.value));\n };\n var removeOutcome = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setDisableButton(true);\n if (!outcomeId) return [3, 2];\n return [4, ApiService.bulkOutcomeRemove(user, reports, [{ id: outcomeId, level: Level.None }])];\n case 1:\n _a.sent();\n return [3, 4];\n case 2: return [4, ApiService.bulkOutcomeRemove(user, reports, [{ id: outcome, level: Level.None }])];\n case 3:\n _a.sent();\n _a.label = 4;\n case 4:\n onClose();\n setDisableButton(false);\n history.push(page + \"/history-insights\");\n return [2];\n }\n });\n }); };\n return (_jsx(Dialog, { open: open, onClose: onClose, onAccept: removeOutcome, cancelText: \"Cancel\", acceptText: \"Remove\", title: \"Bulk Remove Outcome\", content: _jsx(\"div\", __assign({ className: classes.dialog, style: !outcomeId ? { height: 96 } : { height: 36 } }, { children: _jsx(\"div\", __assign({ className: classes.select }, { children: !outcomeId && (_jsx(Select, __assign({ value: outcome, onChange: selectOutcome, style: { width: '100%' }, error: outcomeError }, { children: assignableOutcomes &&\n assignableOutcomes.map(function (o) { return (_jsx(MenuItem, __assign({ value: o.id }, { children: o.name }), o.name)); }) }), void 0)) }), void 0) }), void 0), disabled: disableButton, cancelDisabled: disableButton }, void 0));\n};\nexport default BulkUnassignOutcomeDialog;\n//# sourceMappingURL=BulkUnassignOutcomeDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar BadgeCheckIcon = function (_a) {\n var width = _a.width, height = _a.height;\n var id = useUUID();\n return (_jsxs(\"svg\", __assign({ width: width !== null && width !== void 0 ? width : 20, height: height !== null && height !== void 0 ? height : 20, viewBox: \"0 0 20 20\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Badge Check\" }), void 0), _jsx(\"path\", { opacity: \"0.3\", d: \"M15 7.93359V5.00026H12.0667L9.99999 2.93359L7.93332 5.00026H4.99999V7.93359L2.93332 10.0003L4.99999 12.0669V15.0003H7.93332L9.99999 17.0669L12.0667 15.0003H15V12.0669L17.0667 10.0003L15 7.93359Z\", fill: \"#99BD3E\" }, void 0), _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M16.6667 3.33353V7.24186L19.425 10.0002L16.6667 12.7585V16.6669H12.7583L10 19.4252L7.24168 16.6669H3.33335V12.7585L0.575012 10.0002L3.33335 7.24186V3.33353H7.24168L10 0.575195L12.7583 3.33353H16.6667ZM15 15.0002V12.0669L17.0667 10.0002L15 7.93353V5.00019H12.0667L10 2.93353L7.93333 5.00019H5V7.93353L2.93333 10.0002L5 12.0669V15.0002H7.93333L10 17.0669L12.0667 15.0002H15Z\", fill: \"#99BD3E\" }, void 0), _jsx(\"path\", { d: \"M6.33856 10.1935C7.23904 11.1389 8.61935 12.3935 8.61935 12.3935C8.61935 12.3935 13.2843 7.90082 13.6584 7.51221\", stroke: \"#99BD3E\", strokeWidth: \"2\" }, void 0)] }), void 0));\n};\nexport default BadgeCheckIcon;\n//# sourceMappingURL=BadgeCheckIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar NeedAttentionIcon = function (_a) {\n var width = _a.width, height = _a.height;\n var id = useUUID('needAttentionIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: width !== null && width !== void 0 ? width : 20, height: height !== null && height !== void 0 ? height : 20, viewBox: \"0 0 20 21\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Need Attention\" }), void 0), _jsx(\"path\", { d: \"M2.66663 7.23505L6.96417 2.9375H13.0357L17.3333 7.23505V13.3066L13.0357 17.6042H6.96417L2.66663 13.3066V7.23505Z\", fill: \"#FE6C6C\", fillOpacity: \"0.1\", stroke: \"#FE6C6C\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M10 6.9375V10.2708\", stroke: \"#FE6C6C\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M10 13.6045H10.0083\", stroke: \"#FE6C6C\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0)] }), void 0));\n};\nexport default NeedAttentionIcon;\n//# sourceMappingURL=NeedAttentionIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar ReadyForMore = function (_a) {\n var width = _a.width, height = _a.height;\n var id = useUUID('readyForMoreIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: width !== null && width !== void 0 ? width : 20, height: height !== null && height !== void 0 ? height : 20, viewBox: \"0 0 20 21\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Ready for More\" }), void 0), _jsx(\"path\", { d: \"M4.16667 3.771H15.8333C16.2015 3.771 16.5 4.06947 16.5 4.43766V16.1043C16.5 16.4725 16.2015 16.771 15.8333 16.771H4.16667C3.79848 16.771 3.5 16.4725 3.5 16.1043V4.43766C3.5 4.06947 3.79848 3.771 4.16667 3.771Z\", fill: \"#B0CB3E\", fillOpacity: \"0.1\", stroke: \"#B0CB3E\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M10 6.9375V13.6042\", stroke: \"#B0CB3E\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M6.66663 10.271H13.3333\", stroke: \"#B0CB3E\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0)] }), void 0));\n};\nexport default ReadyForMore;\n//# sourceMappingURL=ReadyForMoreIcon.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { Colors } from '../../../utils/colors';\nexport var DotUserTable = function (_a) {\n var competenceState = _a.competenceState;\n var color;\n var label;\n switch (competenceState) {\n case 'needsAttention':\n color = Colors.red;\n label = 'Needs Attention';\n break;\n case 'inProgress':\n color = Colors.yellow;\n label = 'In Progress';\n break;\n case 'maintained':\n color = Colors.green;\n label = 'Maintained';\n break;\n default:\n break;\n }\n return (_jsx(\"span\", { style: {\n width: 12,\n height: 12,\n backgroundColor: color,\n borderRadius: 25,\n marginRight: 4,\n }, \"aria-label\": label }, void 0));\n};\n//# sourceMappingURL=DotUserTable.js.map","import React from 'react';\nimport { getKeyboardFocusableElements } from '../utils/getKeyboardFocusableElements';\nexport var useFocusOnFirstFocusable = function () {\n return React.useCallback(function (node) {\n if (node) {\n var firstElement = getKeyboardFocusableElements(node)[0];\n firstElement.focus();\n }\n }, []);\n};\n//# sourceMappingURL=useFocusOnFirstFocusable.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nexport var getKeyboardFocusableElements = function (element) {\n return __spreadArray([], __read(element.querySelectorAll('a, button, input, textarea, select, details,[tabindex]:not([tabindex=\"-1\"])')), false).filter(function (el) { return !el.hasAttribute('disabled'); });\n};\n//# sourceMappingURL=getKeyboardFocusableElements.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { IconButton, makeStyles, Menu, Popover } from '@material-ui/core';\nimport { useState, Children } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { useFocusOnFirstFocusable } from '../../hooks/useFocusOnFirstFocusable';\nimport { MoreVertical } from 'react-feather';\nvar useStyles = makeStyles({\n reportOverflowMenu: {\n display: 'flex',\n },\n popover: {\n boxShadow: '0 5px 16px 1px rgba(0,0,0,0.08), 0 2px 8px 0 rgba(0,0,0,0.08)',\n borderRadius: 4,\n backgroundColor: Colors.white,\n minWidth: 202,\n paddingRight: 4,\n paddingTop: 4,\n paddingBottom: 4,\n paddingLeft: 16,\n },\n list: {\n listStyle: 'none',\n padding: 'initial',\n margin: 'initial',\n },\n});\nexport var InsightsMenu = function (_a) {\n var children = _a.children, ariaLabel = _a.ariaLabel, tabIndex = _a.tabIndex, isOnlyMenuItems = _a.isOnlyMenuItems, _b = _a.popoverAlign, popoverAlign = _b === void 0 ? 'center' : _b;\n var classes = useStyles();\n var _c = __read(useState(null), 2), anchorEl = _c[0], setAnchorEl = _c[1];\n var focusRef = useFocusOnFirstFocusable();\n var onClick = function (event) {\n event.stopPropagation();\n setAnchorEl(event.currentTarget);\n };\n var onClose = function () { return setAnchorEl(null); };\n var openMore = Boolean(anchorEl);\n var id = openMore ? 'more' : undefined;\n return (_jsxs(_Fragment, { children: [_jsx(IconButton, __assign({ \"aria-label\": ariaLabel, \"aria-controls\": id, \"aria-haspopup\": \"true\", className: classes.reportOverflowMenu, onClick: onClick, tabIndex: tabIndex }, { children: _jsx(MoreVertical, {}, void 0) }), void 0), isOnlyMenuItems ? (_jsx(Menu, __assign({ id: id, open: openMore, onClose: onClose, onBlur: onClose, anchorEl: anchorEl, classes: {\n paper: classes.popover,\n } }, { children: children }), void 0)) : (_jsx(Popover, __assign({ id: id, open: openMore, anchorEl: anchorEl, onClose: onClose, anchorOrigin: {\n vertical: 'bottom',\n horizontal: popoverAlign,\n }, transformOrigin: {\n vertical: 'top',\n horizontal: popoverAlign,\n }, classes: {\n paper: classes.popover,\n } }, { children: _jsx(\"ul\", __assign({ ref: focusRef, className: classes.list }, { children: Children.map(children, function (child) { return (_jsx(\"li\", { children: child }, void 0)); }) }), void 0) }), void 0))] }, void 0));\n};\n//# sourceMappingURL=InsightsMenu.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport { makeStyles, MenuItem } from '@material-ui/core';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { UserContext } from '../../../contexts/UserContext';\nimport Dialog from '../../Dialog';\nimport Select from '../../select/Select';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nvar useStyles = makeStyles({\n select: {\n marginTop: 8,\n },\n label: {\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n marginBottom: 4,\n },\n dialog: {},\n});\nvar targetLevels = [\n {\n name: 'User',\n value: 1,\n },\n {\n name: 'Producer',\n value: 2,\n },\n {\n name: 'Master',\n value: 3,\n },\n];\nvar AssignOutcomeDialog = function (_a) {\n var report = _a.report, open = _a.open, onClose = _a.onClose, getReports = _a.getReports, updateUser = _a.updateUser, type = _a.type, admin = _a.admin;\n var classes = useStyles();\n var _b = __read(useState(-1), 2), outcome = _b[0], setOutcome = _b[1];\n var _c = __read(useState(-1), 2), targetLevel = _c[0], setTargetLevel = _c[1];\n var _d = __read(useState(false), 2), outcomeError = _d[0], setOutcomeError = _d[1];\n var _e = __read(useState(false), 2), targetLevelError = _e[0], setTargetLevelError = _e[1];\n var user = useContext(UserContext).user;\n var assignableOutcomes = useContext(InsightsContext).assignableOutcomes;\n var ApiService = useApiService();\n var selectOutcome = function (event) {\n setOutcomeError(false);\n setOutcome(Number(event.target.value));\n };\n var selectTargetLevel = function (event) {\n setTargetLevelError(false);\n setTargetLevel(Number(event.target.value));\n };\n var assignOutcome = function () { return __awaiter(void 0, void 0, void 0, function () {\n var hasOutcomeError, hasTargetLevelError;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n hasOutcomeError = false;\n hasTargetLevelError = false;\n if (outcome === -1) {\n hasOutcomeError = true;\n }\n if (targetLevel === -1) {\n hasTargetLevelError = true;\n }\n if (!(!hasOutcomeError && !hasTargetLevelError)) return [3, 5];\n onClose();\n return [4, ApiService.changeTargetLevel(user, report.oid, targetLevel, outcome, 'outcome', false, admin)];\n case 1:\n _a.sent();\n if (!user.role.includes('u')) return [3, 3];\n return [4, updateUser()];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3: return [4, getReports(true)];\n case 4:\n _a.sent();\n resetForm();\n _a.label = 5;\n case 5:\n setOutcomeError(hasOutcomeError);\n setTargetLevelError(hasTargetLevelError);\n return [2];\n }\n });\n }); };\n var resetForm = function () {\n setOutcome(-1);\n setTargetLevel(-1);\n setOutcomeError(false);\n setTargetLevelError(false);\n };\n var handleClose = function () {\n resetForm();\n onClose();\n };\n var outcomeSort = function (a, b) {\n return a.name > b.name ? 1 : b.name > a.name ? -1 : 0;\n };\n return (_jsx(_Fragment, { children: _jsx(Dialog, { open: open, onClose: handleClose, onAccept: assignOutcome, cancelText: 'Cancel', acceptText: 'Accept', title: 'Assign Outcome', content: _jsxs(\"div\", __assign({ className: classes.dialog, style: { height: 145 } }, { children: [_jsxs(\"div\", __assign({ className: classes.select }, { children: [_jsx(\"div\", __assign({ className: classes.label }, { children: \"Outcomes\" }), void 0), _jsx(Select, __assign({ value: outcome, onChange: selectOutcome, style: { width: '100%' }, error: outcomeError }, { children: assignableOutcomes &&\n assignableOutcomes.sort(outcomeSort).map(function (o) { return (_jsx(MenuItem, __assign({ value: o.id }, { children: o.name }), o.name)); }) }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.select }, { children: [_jsx(\"div\", __assign({ className: classes.label }, { children: 'Target Level' }), void 0), _jsx(Select, __assign({ value: targetLevel, onChange: selectTargetLevel, style: { width: '100%' }, error: targetLevelError }, { children: targetLevels.map(function (l) { return (_jsx(MenuItem, __assign({ value: l.value }, { children: l.name }), l.name)); }) }), void 0)] }), void 0)] }), void 0) }, void 0) }, void 0));\n};\nexport default AssignOutcomeDialog;\n//# sourceMappingURL=AssignOutcomeDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { MenuItem } from '@material-ui/core';\nimport { useContext, useState } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { InsightsMenu } from '../InsightsMenu';\nimport AssignOutcomeDialog from './AssignOutcomeDialog';\nvar UserReportOverflow = function (_a) {\n var report = _a.report, getReports = _a.getReports, tabIndex = _a.tabIndex, children = _a.children;\n var _b = __read(useState(false), 2), openOutcomeDialog = _b[0], setOpenOutcomeDialog = _b[1];\n var user = useContext(UserContext).user;\n var toggleOutcomeDialog = function () {\n setOpenOutcomeDialog(!openOutcomeDialog);\n };\n if (!user) {\n return null;\n }\n var canAssignOutcome = true;\n var doNothing = function () {\n return undefined;\n };\n return (_jsxs(_Fragment, { children: [_jsx(InsightsMenu, __assign({ ariaLabel: \"Open user report overflow menu\", tabIndex: tabIndex, isOnlyMenuItems: true }, { children: _jsx(MenuItem, __assign({ onClick: canAssignOutcome ? toggleOutcomeDialog : undefined, disabled: !canAssignOutcome }, { children: \"Assign Outcome\" }), void 0) }), void 0), _jsx(AssignOutcomeDialog, { open: openOutcomeDialog, onClose: toggleOutcomeDialog, report: report, getReports: getReports, updateUser: doNothing, type: \"not selected\", admin: true }, void 0)] }, void 0));\n};\nexport default UserReportOverflow;\n//# sourceMappingURL=UserReportOverflow.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar LastLoginIcon = function () {\n var id = useUUID('lastLoginIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"20\", height: \"20\", viewBox: \"0 0 20 20\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Last Login\" }), void 0), _jsx(\"path\", { opacity: \"0.4\", d: \"M10 2C5.59 2 2 5.59 2 10C2 14.41 5.59 18 10 18C14.41 18 18 14.41 18 10C18 5.59 14.41 2 10 2Z\", fill: \"#349FEE\" }, void 0), _jsx(\"path\", { d: \"M11 13L14 10L11 7\", stroke: \"#349FEE\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { d: \"M14 10H6\", stroke: \"#349FEE\", strokeWidth: \"2\", strokeLinecap: \"round\", strokeLinejoin: \"round\" }, void 0), _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M0 10C0 4.48 4.48 0 10 0C15.52 0 20 4.48 20 10C20 15.52 15.52 20 10 20C4.48 20 0 15.52 0 10ZM2 10C2 14.41 5.59 18 10 18C14.41 18 18 14.41 18 10C18 5.59 14.41 2 10 2C5.59 2 2 5.59 2 10Z\", fill: \"#349FEE\" }, void 0)] }), void 0));\n};\nexport default LastLoginIcon;\n//# sourceMappingURL=LastLoginIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles, TableCell, TableSortLabel } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { useTypography } from '../../styles/Typography';\nimport { useRef } from 'react';\nvar useSortCellStyles = makeStyles(function () { return ({\n label: {\n display: 'grid',\n gridAutoFlow: 'column',\n gap: 4,\n '&: hover .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n '&:focus .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n },\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n}); });\nexport function TableSortCell(_a) {\n var orderByCurr = _a.orderByCurr, order = _a.order, onClick = _a.onClick, orderByKey = _a.orderByKey, label = _a.label, icon = _a.icon;\n var typo = useTypography();\n var classes = useSortCellStyles();\n var isActive = orderByCurr === orderByKey;\n var cellRef = useRef(null);\n return (_jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: isActive ? order : false }, { children: _jsxs(TableSortLabel, __assign({ active: isActive, direction: order, onClick: onClick, className: classes.label, tabIndex: isActive ? 0 : -1, ref: cellRef }, { children: [icon, _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.label) }, { children: label }), void 0), isActive && (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0))] }), void 0) }), void 0));\n}\n//# sourceMappingURL=TableSortCell.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useMediaQuery } from '@material-ui/core';\nimport Checkbox from '@material-ui/core/Checkbox';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableHead from '@material-ui/core/TableHead';\nimport TableRow from '@material-ui/core/TableRow';\nimport { useTypography } from '../../../styles/Typography';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport BadgeCheckIcon from '../../icons/BadgeCheckIcon';\nimport EngagementPointsIcon from '../../icons/EngagementPointsIcon';\nimport LastLoginIcon from '../../icons/LastLoginIcon';\nimport { TableSortCell } from '../TableSortCell';\nimport { DotUserTable } from './DotUserTable';\nvar useStyles = makeStyles(function () { return ({\n filters: {\n width: '100%',\n height: '100%',\n display: 'grid',\n gridTemplateRows: 'repeat(2, 1fr)',\n gridTemplateColumns: 'repeat(2, 1fr)',\n },\n itemTopLeft: {\n borderRight: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderBottom: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n groupRow: {\n '& > *': {\n border: 0,\n },\n },\n groupItem: {\n display: 'flex',\n alignItems: 'center',\n paddingRight: 10,\n },\n groupLine: {\n background: 'rgba(0, 0, 0, 0.08)',\n flex: 1,\n height: 1,\n },\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n}); });\nvar UserTableHead = function (_a) {\n var classes = _a.classes, onSelectAllClick = _a.onSelectAllClick, order = _a.order, orderBy = _a.orderBy, numSelected = _a.numSelected, rowCount = _a.rowCount, onRequestSort = _a.onRequestSort;\n var createSortHandler = function (property) { return function (event) {\n onRequestSort(event, property);\n }; };\n var typo = useTypography();\n var styles = useStyles();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var headerRef = useRovingTabIndex();\n return (_jsxs(TableHead, __assign({ ref: headerRef }, { children: [!isMdDown && (_jsxs(TableRow, __assign({ className: styles.groupRow }, { children: [_jsx(TableCell, { style: { padding: 0 }, colSpan: 3, component: \"th\", role: undefined }, void 0), _jsx(TableCell, __assign({ style: { padding: 0 }, colSpan: 4 }, { children: _jsxs(\"span\", __assign({ className: styles.groupItem }, { children: [_jsx(\"span\", __assign({ className: typo.overlineMini, style: { marginRight: 16 } }, { children: \"OUTCOMES\" }), void 0), _jsx(\"span\", { className: styles.groupLine }, void 0)] }), void 0) }), void 0), _jsx(TableCell, __assign({ colSpan: 3 }, { children: _jsxs(\"span\", __assign({ className: styles.groupItem }, { children: [_jsx(\"span\", __assign({ className: typo.overlineMini, style: { marginRight: 16 } }, { children: \"ENGAGEMENT\" }), void 0), _jsx(\"span\", { className: styles.groupLine }, void 0)] }), void 0) }), void 0), _jsx(TableCell, {}, void 0)] }), void 0)), _jsxs(TableRow, { children: [_jsx(TableCell, __assign({ padding: \"checkbox\" }, { children: _jsx(Checkbox, { indeterminate: numSelected > 0 && numSelected < rowCount, checked: rowCount > 0 && numSelected === rowCount, onChange: onSelectAllClick, inputProps: { 'aria-label': 'select all users' }, tabIndex: -1 }, void 0) }), void 0), !isMdDown && (_jsxs(_Fragment, { children: [_jsx(TableCell, { align: \"left\", padding: 'none', sortDirection: false }, 'alert'), _jsx(TableSortCell, { label: \"Display Name\", orderByCurr: orderBy, orderByKey: \"name\", order: order, onClick: createSortHandler('name') }, void 0), _jsx(TableSortCell, { label: \"TOTAL\", orderByCurr: orderBy, orderByKey: \"total\", order: order, onClick: createSortHandler('total') }, void 0), _jsx(TableSortCell, { label: \"\", icon: _jsx(DotUserTable, { competenceState: \"needsAttention\" }, void 0), orderByCurr: orderBy, orderByKey: \"needsAttention\", order: order, onClick: createSortHandler('needsAttention') }, void 0), _jsx(TableSortCell, { label: \"\", icon: _jsx(DotUserTable, { competenceState: \"inProgress\" }, void 0), orderByCurr: orderBy, orderByKey: \"inProgress\", order: order, onClick: createSortHandler('inProgress') }, void 0), _jsx(TableSortCell, { label: \"\", icon: _jsx(DotUserTable, { competenceState: \"maintained\" }, void 0), orderByCurr: orderBy, orderByKey: \"maintained\", order: order, onClick: createSortHandler('maintained') }, void 0), _jsx(TableSortCell, { label: \"Badges\", icon: _jsx(BadgeCheckIcon, {}, void 0), orderByCurr: orderBy, orderByKey: \"badges\", order: order, onClick: createSortHandler('badges') }, void 0), _jsx(TableSortCell, { label: \"Last Login\", icon: _jsx(LastLoginIcon, {}, void 0), orderByCurr: orderBy, orderByKey: \"lastLogin\", order: order, onClick: createSortHandler('lastLogin') }, void 0), _jsx(TableSortCell, { label: \"EP\", icon: _jsx(EngagementPointsIcon, {}, void 0), orderByCurr: orderBy, orderByKey: \"points\", order: order, onClick: createSortHandler('points') }, void 0)] }, void 0)), _jsx(TableCell, { align: \"left\", padding: 'none', sortDirection: false }, 'none')] }, void 0)] }), void 0));\n};\nexport default UserTableHead;\n//# sourceMappingURL=UserTableHead.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport Toolbar from '@material-ui/core/Toolbar';\nimport { useContext } from 'react';\nimport Search from '../../Search';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nvar useStyles = makeStyles({\n search: {\n width: '100%',\n },\n});\nvar UserTableToolbar = function (_a) {\n var search = _a.search;\n var classes = useStyles();\n var _b = useContext(InsightsContext), searchValue = _b.searchValue, setSearchValue = _b.setSearchValue;\n var onChange = function (event) {\n setSearchValue(event.target.value);\n search(event.target.value);\n };\n return (_jsx(Toolbar, { children: _jsx(Search, { value: searchValue, onChange: onChange, placeholder: \"Search Users\", className: classes.search, style: { backgroundColor: '#FAFAFA' } }, void 0) }, void 0));\n};\nexport default UserTableToolbar;\n//# sourceMappingURL=UserTableToolbar.js.map","export function stableSort(array, comparator) {\n var stabilizedThis = array.map(function (el, index) { return [el, index]; });\n stabilizedThis.sort(function (a, b) {\n var order = comparator(a[0], b[0]);\n if (order !== 0)\n return order;\n return a[1] - b[1];\n });\n return stabilizedThis.map(function (el) { return el[0]; });\n}\n//# sourceMappingURL=stableSort.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nexport function descendingComparator(a, b, orderBy) {\n if (typeof orderBy === 'string' && orderBy.includes('.')) {\n var _a = __read(orderBy.split('.'), 2), preDot = _a[0], postDot = _a[1];\n if (b[preDot][postDot] < a[preDot][postDot]) {\n return -1;\n }\n if (b[preDot][postDot] > a[preDot][postDot]) {\n return 1;\n }\n }\n else {\n if (b[orderBy] < a[orderBy]) {\n return -1;\n }\n if (b[orderBy] > a[orderBy]) {\n return 1;\n }\n }\n return 0;\n}\n//# sourceMappingURL=descendingComparator.js.map","import { descendingComparator } from './descendingComparator';\nexport function getComparator(order, orderBy) {\n return order === 'asc'\n ? function (a, b) { return -descendingComparator(a, b, orderBy); }\n : function (a, b) { return descendingComparator(a, b, orderBy); };\n}\n//# sourceMappingURL=getComparator.js.map","export var BulkAction;\n(function (BulkAction) {\n BulkAction[\"OutcomeAssign\"] = \"OutcomeAssign\";\n BulkAction[\"OutcomeRemove\"] = \"OutcomeRemove\";\n BulkAction[\"LicenseAssign\"] = \"LicenseAssign\";\n BulkAction[\"LicenseRemove\"] = \"LicenseRemove\";\n})(BulkAction || (BulkAction = {}));\n//# sourceMappingURL=BulkAction.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Avatar, Link, Typography, useMediaQuery } from '@material-ui/core';\nimport Checkbox from '@material-ui/core/Checkbox';\nimport Paper from '@material-ui/core/Paper';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport Table from '@material-ui/core/Table';\nimport TableBody from '@material-ui/core/TableBody';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableContainer from '@material-ui/core/TableContainer';\nimport TablePagination from '@material-ui/core/TablePagination';\nimport TableRow from '@material-ui/core/TableRow';\nimport clsx from 'clsx';\nimport { useContext, useState } from 'react';\nimport { Link as RouterLink, useHistory } from 'react-router-dom';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nimport { useTypography } from '../../../styles/Typography';\nimport { InsightsStatus } from '../../../types/types';\nimport { Colors } from '../../../utils/colors';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport BulkUnassignOutcomeDialog from '../../bulk/BulkUnassignOutcomeDialog';\nimport TextButton from '../../buttons/TextButton';\nimport DefaultUserImage from '../../DefaultUserImage';\nimport BadgeCheckIcon from '../../icons/BadgeCheckIcon';\nimport EngagementPointsIcon from '../../icons/EngagementPointsIcon';\nimport NeedAttentionIcon from '../../icons/NeedAttentionIcon';\nimport ReadyForMore from '../../icons/ReadyForMoreIcon';\nimport { DotUserTable } from './DotUserTable';\nimport UserReportOverflow from './UserReportOverflow';\nimport UserTableHead from './UserTableHead';\nimport UserTableToolbar from './UserTableToolbar';\nimport { ChevronDown, ChevronUp } from 'react-feather';\nimport { stableSort } from '../../../utils/stableSort';\nimport { getComparator } from '../../../utils/getComparator';\nvar useStyles = makeStyles(function (theme) { return ({\n root: {\n width: '100%',\n },\n paper: {\n width: '100%',\n marginBottom: theme.spacing(2),\n },\n table: {},\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n icon: {\n width: 20,\n height: 20,\n marginRight: 8,\n },\n image: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n margin: 'auto',\n },\n avatar: {\n height: 24,\n width: 24,\n minHeight: 24,\n minWidth: 24,\n },\n mobileToolbar: {\n height: 42,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n },\n mobileButton: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n mobileList: {\n listStyle: 'none',\n display: 'inline',\n },\n mobileOutcome: {\n height: 108,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n '&:focus-within': {\n outline: 0,\n backgroundColor: Colors.lightPurple,\n },\n },\n evenBackground: {\n backgroundColor: '#fafafa',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridTemplateRows: 'repeat(3, 1fr)',\n },\n context: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n backgroundColor: Colors.white,\n borderRadius: 4,\n padding: '12px 24px',\n },\n contextButtons: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n },\n pagination: {\n '& > *': {\n fontSize: 14,\n },\n },\n}); });\nvar InsightUsersTable = function (_a) {\n var reports = _a.reports, getReports = _a.getReports, search = _a.search, order = _a.order, orderBy = _a.orderBy, handleRequestSort = _a.handleRequestSort, page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var _b = useContext(InsightsContext), setReports = _b.setReports, usersTablePage = _b.usersTablePage, setUsersTablePage = _b.setUsersTablePage, usersTableRowsPerPage = _b.usersTableRowsPerPage, setUsersTableRowsPerPage = _b.setUsersTableRowsPerPage;\n var _c = __read(useState([]), 2), selected = _c[0], setSelected = _c[1];\n var _d = __read(useState(false), 2), bulkUnassignOpen = _d[0], setBulkUnassignOpen = _d[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var history = useHistory();\n var handleSelectAllClick = function (event) {\n if (event.target.checked) {\n var newSelecteds = reports.map(function (n) { return n.oid; });\n setSelected(newSelecteds);\n return;\n }\n setSelected([]);\n };\n var toggleSelection = function (event, oid) {\n event.stopPropagation();\n var selectedIndex = selected.indexOf(oid);\n var newSelected = [];\n if (selectedIndex === -1) {\n newSelected = newSelected.concat(selected, oid);\n }\n else if (selectedIndex === 0) {\n newSelected = newSelected.concat(selected.slice(1));\n }\n else if (selectedIndex === selected.length - 1) {\n newSelected = newSelected.concat(selected.slice(0, -1));\n }\n else if (selectedIndex > 0) {\n newSelected = newSelected.concat(selected.slice(0, selectedIndex), selected.slice(selectedIndex + 1));\n }\n setSelected(newSelected);\n };\n var openDetail = function (report) {\n return page + \"/insights-detail/\" + report.oid;\n };\n var handleChangePage = function (event, newPage) {\n setUsersTablePage(newPage);\n };\n var handleChangeRowsPerPage = function (event) {\n setUsersTableRowsPerPage(parseInt(event.target.value, 10));\n setUsersTablePage(0);\n };\n var isSelected = function (oid) { return selected.indexOf(oid) !== -1; };\n var bulkAssignOutcomes = function () {\n setReports(selected);\n history.push(page + \"/bulk\");\n };\n var toggleBulkUnassignDialog = function () {\n setBulkUnassignOpen(!bulkUnassignOpen);\n };\n var cancel = function () {\n setSelected([]);\n };\n var listRef = useRovingTabIndex();\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [!isMdDown ? (_jsxs(Paper, __assign({ className: classes.paper }, { children: [_jsx(UserTableToolbar, { search: search }, void 0), selected.length > 0 && (_jsx(\"section\", { children: _jsxs(\"div\", __assign({ className: classes.context }, { children: [_jsxs(\"div\", __assign({ className: classes.contextButtons }, { children: [_jsxs(Typography, __assign({ variant: \"caption\", style: { marginRight: 16 } }, { children: [selected.length, \" Selected\"] }), void 0), _jsx(TextButton, __assign({ onClick: bulkAssignOutcomes, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Assign Outcome(s)\" }), void 0), _jsx(TextButton, __assign({ onClick: toggleBulkUnassignDialog, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Unassign Outcome(s)\" }), void 0)] }), void 0), _jsx(TextButton, __assign({ onClick: cancel, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Cancel\" }), void 0)] }), void 0) }, void 0)), _jsx(TableContainer, { children: _jsxs(Table, __assign({ className: classes.table, \"aria-label\": \"Users' Outcomes and Engagements\", size: 'medium' }, { children: [_jsx(UserTableHead, { classes: classes, order: order, orderBy: orderBy, onSelectAllClick: handleSelectAllClick, onRequestSort: handleRequestSort, rowCount: reports.length, numSelected: selected.length }, void 0), _jsx(TableBody, __assign({ ref: listRef }, { children: stableSort(reports, getComparator(order, orderBy))\n .sort(function (a, b) {\n if (orderBy === 'lastLogin') {\n if (order === 'asc') {\n if (a.lastLogin === -1 && b.lastLogin !== -1)\n return 1;\n else if (a.lastLogin !== -1 && b.lastLogin === -1)\n return -1;\n }\n if (order === 'desc') {\n if (a.lastLogin === -1 && b.lastLogin !== -1)\n return -1;\n else if (a.lastLogin !== -1 && b.lastLogin === -1)\n return 1;\n }\n }\n return 0;\n })\n .slice(usersTablePage * usersTableRowsPerPage, usersTablePage * usersTableRowsPerPage + usersTableRowsPerPage)\n .map(function (row, index) {\n var isItemSelected = isSelected(row.oid);\n var labelId = \"enhanced-table-checkbox-\" + row.oid;\n return (_jsxs(TableRow, __assign({ hover: true, \"aria-selected\": isItemSelected, selected: isItemSelected, style: { cursor: 'pointer' }, onClick: function (event) { return toggleSelection(event, row.oid); } }, { children: [_jsx(TableCell, __assign({ padding: \"checkbox\" }, { children: _jsx(Checkbox, { onClick: function (event) { return toggleSelection(event, row.oid); }, checked: isItemSelected, inputProps: { 'aria-labelledby': labelId }, tabIndex: index === 0 ? 0 : -1 }, void 0) }), void 0), _jsx(TableCell, __assign({ padding: \"none\" }, { children: _jsx(\"div\", __assign({ className: classes.icon }, { children: row.status === InsightsStatus.NeedsAttention ? (_jsx(NeedAttentionIcon, {}, void 0)) : row.status === InsightsStatus.ReadyForMore ? (_jsx(ReadyForMore, {}, void 0)) : undefined }), void 0) }), void 0), _jsx(TableCell, __assign({ component: \"th\", id: labelId, padding: \"none\", scope: \"row\" }, { children: _jsxs(Link, __assign({ tabIndex: -1, component: RouterLink, to: openDetail(row), style: {\n width: isMdDown ? 150 : 225,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n }, \"aria-label\": \"Go to \" + row.name + \" details\" }, { children: [_jsx(\"div\", __assign({ style: { marginRight: 8 } }, { children: _jsx(UserTableAvatar, { image: row.image }, void 0) }), void 0), _jsx(\"p\", __assign({ id: row.oid, className: typo.body2 }, { children: row.name }), void 0)] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.total }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.needsAttention }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.inProgress }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.maintained }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.badges }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.lastLogin === -1\n ? 'Never'\n : row.lastLogin === 0\n ? 'Today'\n : row.lastLogin === 1\n ? 'Yesterday'\n : row.lastLogin < 13\n ? row.lastLogin + \" days ago\"\n : Math.ceil(row.lastLogin / 7) + \" weeks ago\" }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsx(\"p\", __assign({ className: typo.body2 }, { children: row.points }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"right\" }, { children: _jsx(UserReportOverflow, { report: row, getReports: getReports, tabIndex: -1 }, void 0) }), void 0)] }), row.oid));\n }) }), void 0)] }), void 0) }, void 0), _jsx(TablePagination, { className: classes.pagination, rowsPerPageOptions: [10, 25, 100, 250, 1000], component: \"div\", count: reports.length, rowsPerPage: usersTableRowsPerPage, page: usersTablePage, onPageChange: handleChangePage, onRowsPerPageChange: handleChangeRowsPerPage }, void 0)] }), void 0)) : (_jsxs(_Fragment, { children: [_jsx(\"section\", { children: selected.length > 0 && (_jsxs(\"div\", __assign({ className: classes.context }, { children: [_jsxs(\"div\", __assign({ className: classes.contextButtons }, { children: [_jsxs(Typography, __assign({ variant: \"caption\", style: { marginRight: 16 } }, { children: [selected.length, \" Selected\"] }), void 0), _jsx(TextButton, __assign({ onClick: bulkAssignOutcomes }, { children: \"Assign Outcome(s)\" }), void 0), _jsx(TextButton, __assign({ onClick: toggleBulkUnassignDialog }, { children: \"Unassign Outcome(s)\" }), void 0)] }), void 0), _jsx(TextButton, __assign({ onClick: cancel }, { children: \"Cancel\" }), void 0)] }), void 0)) }, void 0), _jsxs(Paper, __assign({ className: classes.paper }, { children: [_jsx(UserTableToolbar, { search: search }, void 0), _jsx(\"div\", __assign({ className: classes.mobileToolbar }, { children: _jsxs(\"div\", __assign({ className: classes.mobileButton }, { children: [_jsx(\"p\", __assign({ className: typo.body1 }, { children: \"Display Name\" }), void 0), _jsx(\"button\", __assign({ style: { background: 'none', border: 'none' }, onClick: function (event) { return handleRequestSort(event, 'name'); } }, { children: order === 'desc' ? _jsx(ChevronDown, {}, void 0) : _jsx(ChevronUp, {}, void 0) }), void 0)] }), void 0) }), void 0), _jsx(\"ul\", __assign({ ref: listRef, role: \"listbox\", \"aria-multiselectable\": true, className: classes.mobileList }, { children: stableSort(reports, getComparator(order, orderBy))\n .sort(function (a, b) {\n if (orderBy === 'lastLogin') {\n if (order === 'asc') {\n if (a.lastLogin === -1 && b.lastLogin !== -1)\n return 1;\n else if (a.lastLogin !== -1 && b.lastLogin === -1)\n return -1;\n }\n if (order === 'desc') {\n if (a.lastLogin === -1 && b.lastLogin !== -1)\n return -1;\n else if (a.lastLogin !== -1 && b.lastLogin === -1)\n return 1;\n }\n }\n return 0;\n })\n .map(function (row, index) {\n var isItemSelected = isSelected(row.oid);\n var labelId = \"enhanced-table-checkbox-\" + index;\n return (_jsxs(\"li\", __assign({ role: \"option\", \"aria-selected\": isItemSelected, className: clsx(classes.mobileOutcome, index % 2 === 0 && classes.evenBackground) }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'space-between' } }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'flex-start' } }, { children: [_jsx(Checkbox, { tabIndex: index === 0 ? 0 : -1, onClick: function (event) { return toggleSelection(event, row.oid); }, checked: isItemSelected, inputProps: { 'aria-labelledby': labelId } }, void 0), _jsx(UserTableAvatar, { image: row.image }, void 0), _jsx(Link, __assign({ component: RouterLink, to: openDetail(row), id: labelId, className: typo.subtitle2, style: { marginLeft: 8 }, tabIndex: -1 }, { children: row.name }), void 0)] }), void 0), _jsx(\"div\", { children: _jsx(UserReportOverflow, { report: row, getReports: getReports, tabIndex: -1 }, void 0) }, void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Outcomes\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(DotUserTable, { competenceState: \"needsAttention\" }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.needsAttention }), void 0), _jsx(DotUserTable, { competenceState: \"inProgress\" }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.inProgress }), void 0), _jsx(DotUserTable, { competenceState: \"maintained\" }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.maintained }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Badges\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", __assign({ style: { marginRight: 4, marginLeft: 4 } }, { children: _jsx(BadgeCheckIcon, { width: 12, height: 12 }, void 0) }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.badges }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Engagement Points (EP)\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", __assign({ style: { marginRight: 4, marginLeft: 4 } }, { children: _jsx(EngagementPointsIcon, { width: 12, height: 12 }, void 0) }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.points }), void 0)] }), void 0)] }), void 0)] }), row.oid));\n }) }), void 0)] }), void 0)] }, void 0)), _jsx(BulkUnassignOutcomeDialog, { page: page, onClose: toggleBulkUnassignDialog, open: bulkUnassignOpen, reports: selected }, void 0)] }), void 0));\n};\nvar UserTableAvatar = function (_a) {\n var image = _a.image;\n var classes = useStyles();\n return image ? (_jsx(Avatar, { src: image, className: classes.avatar, imgProps: { loading: 'lazy', alt: '' } }, void 0)) : (_jsx(DefaultUserImage, { size: 24, fontSize: 20 }, void 0));\n};\nexport default InsightUsersTable;\n//# sourceMappingURL=InsightUsersTable.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useEffect, useState } from 'react';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { Paper, useMediaQuery } from '@material-ui/core';\nimport clsx from 'clsx';\nimport EngagementPointsIcon from '../../icons/EngagementPointsIcon';\nimport { InsightsStatus } from '../../../types/types';\nimport { Colors } from '../../../utils/colors';\nimport { Tooltip } from '../../Tooltip';\nimport TextButton from '../../buttons/TextButton';\nimport BadgeCheckIcon from '../../icons/BadgeCheckIcon';\nimport ReadyForMore from '../../icons/ReadyForMoreIcon';\nimport NeedAttentionIcon from '../../icons/NeedAttentionIcon';\nimport { useTypography } from '../../../styles/Typography';\nimport { numberShortener } from '../../../utils/numberUtils';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d;\n return ({\n filters: {\n width: '100%',\n height: '100%',\n display: 'grid',\n gridTemplateRows: 'repeat(2, 1fr)',\n gridTemplateColumns: 'repeat(2, 1fr)',\n },\n itemTopLeft: {\n borderRight: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderBottom: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n itemTopRight: {\n borderLeft: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderBottom: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n itemBottomLeft: {\n borderRight: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderTop: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n itemBottomRight: {\n borderLeft: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderTop: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n item: (_a = {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n textAlign: 'center',\n padding: 4\n },\n _a[theme.breakpoints.down('md')] = {\n width: 150,\n },\n _a),\n horizontalFilters: {\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n textAlign: 'center',\n },\n mobileCard: (_b = {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start'\n },\n _b[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n },\n _b),\n mobileItem: (_c = {\n width: '100%',\n height: 178,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n backgroundColor: Colors.white,\n padding: 12\n },\n _c[theme.breakpoints.down('sm')] = {\n marginBottom: 8,\n height: 120,\n '&:last-child': {\n marginBottom: 0,\n },\n },\n _c),\n mobileTitle: {\n width: '100%',\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n },\n dot: (_d = {\n width: 12,\n height: 12,\n borderRadius: 25\n },\n _d[theme.breakpoints.down('sm')] = {\n marginRight: 12,\n },\n _d),\n text: {\n textAlign: 'center',\n },\n });\n});\nvar UsersFilters = function (_a) {\n var reports = _a.reports, readyFilter = _a.readyFilter, needAttentionFilter = _a.needAttentionFilter;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState(0), 2), badgeCount = _b[0], setBadgeCount = _b[1];\n var _c = __read(useState(0), 2), epCount = _c[0], setEpCount = _c[1];\n var _d = __read(useState(0), 2), readyCount = _d[0], setReadyCount = _d[1];\n var _e = __read(useState(0), 2), needAttentionCount = _e[0], setNeedAttentionCount = _e[1];\n var _f = __read(useState(false), 2), readyApplied = _f[0], setReadyApplied = _f[1];\n var _g = __read(useState(false), 2), attentionApplied = _g[0], setAttentionApplied = _g[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n useEffect(function () {\n var newBadgeCount = 0;\n var newEpCount = 0;\n var newReadyCount = 0;\n var newNeedAttentionCount = 0;\n reports.forEach(function (value) {\n newBadgeCount += value.badges;\n newEpCount += value.points;\n if (value.status === InsightsStatus.ReadyForMore) {\n newReadyCount++;\n }\n if (value.status === InsightsStatus.NeedsAttention) {\n newNeedAttentionCount++;\n }\n });\n setBadgeCount(newBadgeCount);\n setEpCount(newEpCount);\n setReadyCount(newReadyCount);\n setNeedAttentionCount(newNeedAttentionCount);\n }, [reports]);\n return (_jsx(_Fragment, { children: !isMdDown ? (_jsxs(\"div\", __assign({ className: classes.filters }, { children: [_jsxs(\"div\", __assign({ className: clsx(classes.itemTopLeft, classes.item) }, { children: [_jsx(Tooltip, __assign({ title: \"Badges certify that a user has achieved a specific Outcome target level\" }, { children: _jsx(BadgeCheckIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: badgeCount }), void 0), _jsx(\"p\", __assign({ className: typo.overline }, { children: badgeCount === 1 ? 'Badge Earned' : 'Badges Earned' }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: clsx(classes.itemTopRight, classes.item) }, { children: [_jsx(Tooltip, __assign({ title: \"Users earn points for engaging with Nulia Works as well as achieving Skills and Outcomes\" }, { children: _jsx(EngagementPointsIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: numberShortener(epCount) }), void 0), _jsx(\"p\", __assign({ className: typo.overline }, { children: epCount === 1 ? 'Engagement Point (EP)' : 'Engagement Points (EP)' }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: clsx(classes.itemBottomLeft, classes.item) }, { children: [_jsx(Tooltip, __assign({ title: \"Users who are maintaining all assigned Outcomes and are ready for their next step\" }, { children: _jsx(ReadyForMore, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: readyCount }), void 0), _jsx(\"p\", __assign({ className: typo.overline }, { children: readyCount === 1 ? 'User Ready for Next Step' : 'Users Ready for Next Step' }), void 0), _jsx(TextButton, __assign({ onClick: function () {\n setReadyApplied(!readyApplied);\n setAttentionApplied(false);\n readyFilter();\n } }, { children: _jsx(\"span\", __assign({ className: typo.overlineMini, style: { color: Colors.purple } }, { children: readyApplied ? 'Clear Filter' : 'Filter Users' }), void 0) }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: clsx(classes.itemBottomRight, classes.item) }, { children: [_jsx(Tooltip, __assign({ title: \"Users who need to reattain an Outcome\" }, { children: _jsx(NeedAttentionIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: needAttentionCount }), void 0), _jsx(\"p\", __assign({ className: typo.overline }, { children: needAttentionCount === 1 ? 'User Needs Attention' : 'Users Need Attention' }), void 0), _jsx(TextButton, __assign({ onClick: function () {\n setAttentionApplied(!attentionApplied);\n setReadyApplied(false);\n needAttentionFilter();\n } }, { children: _jsx(\"span\", __assign({ className: typo.overlineMini, style: { color: Colors.purple } }, { children: attentionApplied ? 'Clear Filter' : 'Filter Users' }), void 0) }), void 0)] }), void 0)] }), void 0)) : (_jsxs(\"section\", __assign({ className: classes.mobileCard }, { children: [_jsxs(Paper, __assign({ elevation: 1, className: classes.mobileItem }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileTitle }, { children: [_jsx(Tooltip, __assign({ title: \"Badges certify that a user has achieved a specific Outcome target level\" }, { children: _jsx(BadgeCheckIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: badgeCount }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.text) }, { children: badgeCount === 1 ? 'Badge Earned' : 'Badges Earned' }), void 0)] }), void 0), _jsxs(Paper, __assign({ elevation: 1, className: classes.mobileItem }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileTitle }, { children: [_jsx(Tooltip, __assign({ title: \"Users earn points for engaging with Nulia Works as well as achieving Skills and Outcomes\" }, { children: _jsx(EngagementPointsIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: numberShortener(epCount) }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.text) }, { children: epCount === 1 ? 'Engagement Point (EP)' : 'Engagement Points (EP)' }), void 0)] }), void 0), _jsxs(Paper, __assign({ elevation: 1, className: classes.mobileItem }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileTitle }, { children: [_jsx(Tooltip, __assign({ title: \"Users who are maintaining all assigned Outcomes and are ready for their next step\" }, { children: _jsx(ReadyForMore, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: readyCount }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.text) }, { children: readyCount === 1 ? 'User Ready for More' : 'Users Ready for More' }), void 0), _jsx(TextButton, __assign({ onClick: function () {\n setReadyApplied(!readyApplied);\n setAttentionApplied(false);\n readyFilter();\n } }, { children: _jsx(\"p\", __assign({ className: typo.overlineMini, style: { color: Colors.purple } }, { children: readyApplied ? 'Clear Filter' : 'Filter Users' }), void 0) }), void 0)] }), void 0), _jsxs(Paper, __assign({ elevation: 1, className: classes.mobileItem }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileTitle }, { children: [_jsx(Tooltip, __assign({ title: \"Users who need to reattain an Outcome\" }, { children: _jsx(NeedAttentionIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5 }, { children: needAttentionCount }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.text) }, { children: needAttentionCount === 1 ? 'User Needs Attention' : 'Users Need Attention' }), void 0), _jsx(TextButton, __assign({ onClick: function () {\n setAttentionApplied(!attentionApplied);\n setReadyApplied(false);\n needAttentionFilter();\n } }, { children: _jsx(\"p\", __assign({ className: typo.overlineMini, style: { color: Colors.purple } }, { children: attentionApplied ? 'Clear Filter' : 'Filter Users' }), void 0) }), void 0)] }), void 0)] }), void 0)) }, void 0));\n};\nexport default UsersFilters;\n//# sourceMappingURL=UsersFilters.js.map","export var hasManagerRole = function (user) { return user !== undefined && user.role.includes('m'); };\n//# sourceMappingURL=hasManagerRole.js.map","export var isAllFilter = function (filter) {\n return ['All Departments', 'All Users', 'All Regions', 'All Levels', 'All License Types'].includes(filter);\n};\n//# sourceMappingURL=isAllFilter.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __values = (this && this.__values) || function(o) {\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\n if (m) return m.call(o);\n if (o && typeof o.length === \"number\") return {\n next: function () {\n if (o && i >= o.length) o = void 0;\n return { value: o && o[i++], done: !o };\n }\n };\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useMemo, useState } from 'react';\nimport Select from '../select/Select';\nimport { IconButton, MenuItem, useMediaQuery, makeStyles, useTheme } from '@material-ui/core';\nimport { UserContext } from '../../contexts/UserContext';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport TextButton from '../buttons/TextButton';\nimport { Colors } from '../../utils/colors';\nimport { Filter, X } from 'react-feather';\nimport { hasManagerRole } from '../../utils/hasManagerRole';\nimport { hasAdminRole } from '../../utils/hasAdminRole';\nimport { isAllFilter } from '../../utils/isAllFilter';\nimport { LicenseType } from '../../types/enums';\nimport { useTypography } from '../../styles/Typography';\nimport clsx from 'clsx';\nimport { levelFilterOptions } from '../../utils/levelFilterOptions';\nvar useStyles = makeStyles(function () { return ({\n filtersTitle: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginBottom: 16,\n },\n rowCenterStart: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n iconButton: {\n alignItems: 'center',\n display: 'flex',\n justifyContent: 'center',\n },\n chit: {\n backgroundColor: 'rgba(101, 78, 163, 0.08)',\n borderRadius: 32,\n margin: 4,\n padding: 6,\n },\n}); });\nexport var Filters = function (_a) {\n var filteredLength = _a.filteredLength, clearAll = _a.clearAll, departmentFilter = _a.departmentFilter, onChangeDepartments = _a.onChangeDepartments, departmentOptions = _a.departmentOptions, clearDepartment = _a.clearDepartment, licenseFilter = _a.licenseFilter, onChangeLicenses = _a.onChangeLicenses, clearLicense = _a.clearLicense, assignmentFilter = _a.assignmentFilter, onChangeAssignment = _a.onChangeAssignment, clearAssignment = _a.clearAssignment, regionFilter = _a.regionFilter, onChangeRegion = _a.onChangeRegion, regionOptions = _a.regionOptions, clearRegion = _a.clearRegion, levelOptions = _a.levelOptions, levelFilter = _a.levelFilter, onChangeLevel = _a.onChangeLevel, clearLevel = _a.clearLevel, reportsFilter = _a.reportsFilter, onChangeReports = _a.onChangeReports, clearReports = _a.clearReports, statusFilter = _a.statusFilter, clearStatus = _a.clearStatus;\n var classes = useStyles();\n var typo = useTypography();\n var user = useContext(UserContext).user;\n var _b = __read(useState(false), 2), openFilters = _b[0], setOpenFilters = _b[1];\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var filters = [\n { filter: departmentFilter, clear: clearDepartment },\n { filter: licenseFilter, clear: clearLicense },\n { filter: assignmentFilter, clear: clearAssignment },\n { filter: regionFilter, clear: clearRegion },\n { filter: levelFilter, clear: clearLevel },\n { filter: reportsFilter, clear: clearReports },\n { filter: statusFilter, clear: clearStatus },\n ];\n var allLevelOptions = useMemo(function () { return levelFilterOptions(); }, []);\n var anyFilters = function () {\n var e_1, _a;\n var count = 0;\n try {\n for (var filters_1 = __values(filters), filters_1_1 = filters_1.next(); !filters_1_1.done; filters_1_1 = filters_1.next()) {\n var filter = filters_1_1.value;\n if (filter.filter && filter.clear && !isAllFilter(filter.filter)) {\n ++count;\n }\n }\n }\n catch (e_1_1) { e_1 = { error: e_1_1 }; }\n finally {\n try {\n if (filters_1_1 && !filters_1_1.done && (_a = filters_1.return)) _a.call(filters_1);\n }\n finally { if (e_1) throw e_1.error; }\n }\n return count;\n };\n var toggleFilters = function () {\n setOpenFilters(!openFilters);\n };\n return (_jsxs(\"section\", __assign({ style: { marginBottom: 16 } }, { children: [_jsxs(\"div\", __assign({ className: classes.filtersTitle }, { children: [_jsxs(\"div\", __assign({ className: classes.rowCenterStart }, { children: [!isSmDown &&\n filters.map(function (value, index) {\n if (value.filter && value.clear && !isAllFilter(value.filter)) {\n return (_jsxs(\"span\", __assign({ className: clsx(classes.chit, classes.iconButton) }, { children: [_jsx(\"p\", __assign({ className: typo.caption }, { children: value.filter }), void 0), _jsx(IconButton, __assign({ onClick: value.clear }, { children: _jsx(X, { style: { color: Colors.purple } }, void 0) }), void 0)] }), \"chit-\" + index));\n }\n }), _jsxs(\"div\", __assign({ className: classes.rowCenterStart }, { children: [_jsxs(\"span\", __assign({ className: typo.body2 }, { children: [filteredLength, \" Users\"] }), void 0), anyFilters() > 0 && (_jsx(TextButton, __assign({ onClick: clearAll, style: { color: Colors.purple, fontSize: 10 }, \"aria-label\": 'Clear Filters', role: \"switch\", \"aria-checked\": \"true\", type: \"button\" }, { children: \"Clear Filters\" }), void 0))] }), void 0)] }), void 0), _jsx(SecondaryButton, __assign({ onClick: toggleFilters, style: { width: 136 }, role: \"switch\", \"aria-checked\": \"true\", type: \"button\" }, { children: _jsxs(\"span\", __assign({ className: classes.iconButton }, { children: [_jsx(Filter, {}, void 0), _jsxs(\"span\", __assign({ className: typo.button }, { children: [\"Filters \", anyFilters() > 0 && \"(\" + anyFilters() + \")\"] }), void 0)] }), void 0) }), void 0)] }), void 0), isSmDown && (_jsx(\"div\", __assign({ className: classes.rowCenterStart, style: { marginBottom: 16 } }, { children: filters.map(function (value, index) {\n if (value.filter && value.clear && !isAllFilter(value.filter)) {\n return (_jsxs(\"span\", __assign({ className: clsx(classes.chit, classes.iconButton) }, { children: [_jsx(\"p\", __assign({ className: typo.caption }, { children: value.filter }), void 0), _jsx(IconButton, __assign({ onClick: value.clear }, { children: _jsx(X, { style: { color: Colors.purple } }, void 0) }), void 0)] }), \"chit-\" + index));\n }\n }) }), void 0)), openFilters && (_jsxs(\"div\", { children: [onChangeDepartments && (_jsxs(Select, __assign({ value: departmentFilter !== null && departmentFilter !== void 0 ? departmentFilter : 'All Departments', onChange: onChangeDepartments, light: true, style: !isSmDown\n ? { width: 200, marginRight: 16, marginBottom: 16 }\n : { width: '100%', marginBottom: 16 } }, { children: [_jsx(MenuItem, __assign({ value: \"All Departments\" }, { children: 'All Departments' }), void 0), departmentOptions === null || departmentOptions === void 0 ? void 0 : departmentOptions.map(function (department, index) { return (_jsx(MenuItem, __assign({ value: department }, { children: department }), index)); })] }), void 0)), (user === null || user === void 0 ? void 0 : user.licenseType) === LicenseType.Complete && onChangeLicenses && (_jsxs(Select, __assign({ value: licenseFilter !== null && licenseFilter !== void 0 ? licenseFilter : 'All License Types', onChange: onChangeLicenses, light: true, style: !isSmDown ? { width: 200, marginRight: 16 } : { width: '100%', marginBottom: 16 } }, { children: [_jsx(MenuItem, __assign({ value: \"All License Types\" }, { children: 'All License Types' }), void 0), _jsx(MenuItem, __assign({ value: \"Complete\" }, { children: 'Complete' }), void 0), _jsx(MenuItem, __assign({ value: \"None\" }, { children: 'None' }), void 0)] }), void 0)), onChangeAssignment && (_jsxs(Select, __assign({ value: assignmentFilter !== null && assignmentFilter !== void 0 ? assignmentFilter : 'All Users', onChange: onChangeAssignment, light: true, style: !isSmDown ? { width: 250, marginRight: 16 } : { width: '100%', marginBottom: 16 } }, { children: [_jsx(MenuItem, __assign({ value: 'All Users' }, { children: \"All Users\" }), void 0), _jsx(MenuItem, __assign({ value: 'All Assigned' }, { children: \"All Assigned\" }), void 0), _jsx(MenuItem, __assign({ value: 'Self Assigned' }, { children: \"Self Assigned\" }), void 0), _jsx(MenuItem, __assign({ value: 'Organization Assigned' }, { children: \"Organization Assigned\" }), void 0), _jsx(MenuItem, __assign({ value: 'Unassigned' }, { children: \"Unassigned\" }), void 0)] }), void 0)), onChangeRegion && (_jsxs(Select, __assign({ value: regionFilter !== null && regionFilter !== void 0 ? regionFilter : 'All Regions', onChange: onChangeRegion, light: true, style: !isSmDown ? { width: 200, marginRight: 16 } : { width: '100%', marginBottom: 16 } }, { children: [_jsx(MenuItem, __assign({ value: \"All Regions\" }, { children: 'All Regions' }), void 0), regionOptions === null || regionOptions === void 0 ? void 0 : regionOptions.map(function (region, index) { return (_jsx(MenuItem, __assign({ value: region }, { children: region }), index)); })] }), void 0)), onChangeLevel && (_jsx(Select, __assign({ value: levelFilter !== null && levelFilter !== void 0 ? levelFilter : 'All Levels', onChange: onChangeLevel, light: true, style: !isSmDown ? { width: 200, marginRight: 16 } : { width: '100%', marginBottom: 16 } }, { children: levelOptions\n ? levelOptions.map(function (level) {\n var levelOption = allLevelOptions[level];\n if (levelOption) {\n return (_jsx(MenuItem, __assign({ value: levelOption.value }, { children: levelOption.text }), levelOption.key));\n }\n })\n : allLevelOptions.map(function (levelOption) { return (_jsx(MenuItem, __assign({ value: levelOption.value }, { children: levelOption.text }), levelOption.key)); }) }), void 0)), hasManagerRole(user) && onChangeReports && (_jsxs(Select, __assign({ value: reportsFilter !== null && reportsFilter !== void 0 ? reportsFilter : 'All Users', onChange: onChangeReports, light: true, style: !isSmDown ? { width: 200, marginRight: 16 } : { width: '100%', marginBottom: 16 } }, { children: [_jsx(MenuItem, __assign({ value: \"All Users\" }, { children: 'All Users' }), void 0), _jsx(MenuItem, __assign({ value: \"Direct Reports\" }, { children: 'Direct Reports' }), void 0), hasAdminRole(user) && _jsx(MenuItem, __assign({ value: \"All Reports\" }, { children: 'All Reports' }), void 0)] }), void 0))] }, void 0))] }), void 0));\n};\n//# sourceMappingURL=Filters.js.map","export var levelFilterOptions = function () {\n return [\n {\n key: 0,\n value: 'All Levels',\n text: 'All Levels',\n },\n {\n key: 1,\n value: 'User Level',\n text: 'User',\n },\n {\n key: 2,\n value: 'Producer Level',\n text: 'Producer',\n },\n {\n key: 3,\n value: 'Master Level',\n text: 'Master',\n },\n ];\n};\n//# sourceMappingURL=levelFilterOptions.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar InsightsApi = (function () {\n function InsightsApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getCsvReportNames = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetCsvReportNames\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.getAssessmentCsvReportNames = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAssessmentCsvReportNames \";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.downloadUserCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetUserCsvReport\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.download(url, { fileName: fileName }, headers, fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.downloadSkillsCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetSkillCsvReport\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.download(url, { fileName: fileName }, headers, fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.downloadOutcomesCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetOutcomeCsvReport\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.download(url, { fileName: fileName }, headers, fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.downloadMetricsCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAssessmentCsvReport\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.download(url, { fileName: fileName }, headers, fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.getMetricsCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/GetAssessmentCsvReport\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.post(url, { fileName: fileName }, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return InsightsApi;\n}());\nexport { InsightsApi };\n//# sourceMappingURL=InsightsApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { InsightsApi } from '../data/InsightsApi';\nvar InsightsService = (function () {\n function InsightsService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.getCsvReportNames = function () { return __awaiter(_this, void 0, void 0, function () {\n var _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0: return [4, this.insightsApi.getCsvReportNames()];\n case 1: return [2, (_a = (_b.sent())) === null || _a === void 0 ? void 0 : _a.data];\n }\n });\n }); };\n this.getAssessmentCsvReportNames = function () { return __awaiter(_this, void 0, void 0, function () {\n var _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0: return [4, this.insightsApi.getAssessmentCsvReportNames()];\n case 1: return [2, (_a = (_b.sent())) === null || _a === void 0 ? void 0 : _a.data];\n }\n });\n }); };\n this.downloadUserCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.insightsApi.downloadUserCsvReport(fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.downloadSkillsCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.insightsApi.downloadSkillsCsvReport(fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.downloadOutcomesCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.insightsApi.downloadOutcomesCsvReport(fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.downloadMetricsCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.insightsApi.downloadMetricsCsvReport(fileName)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.getMetricsCsvReport = function (fileName) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.insightsApi.getMetricsCsvReport(fileName)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.clientType = clientType;\n this.insightsApi = new InsightsApi(token, oid, tid, sid, clientType);\n }\n return InsightsService;\n}());\nexport { InsightsService };\n//# sourceMappingURL=InsightsService.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nimport { makeStyles } from '@material-ui/core/styles';\nvar useStyles = makeStyles(function () { return ({\n rotate: {\n transform: 'rotate(180deg)',\n },\n revert: {\n transform: 'none',\n },\n}); });\nvar ArrowIcon = function (_a) {\n var width = _a.width, height = _a.height, rotate = _a.rotate;\n var id = useUUID();\n var classes = useStyles();\n return (_jsx(\"svg\", __assign({ className: rotate ? classes.revert : classes.rotate, width: width, height: height, viewBox: \"0 0 10 7\", fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id }, { children: _jsx(\"path\", { d: \"M8.59992 6.11694C8.85888 6.3855 9.27875 6.3855 9.53771 6.11694C9.79667 5.84838 9.79667 5.41295 9.53771 5.14439L5.55899 1.0182C5.30002 0.749641 4.88016 0.749641 4.62119 1.0182L0.642468 5.14439C0.383504 5.41295 0.383504 5.84838 0.642468 6.11694C0.901433 6.3855 1.3213 6.3855 1.58026 6.11694L5.09009 2.47703L8.59992 6.11694Z\", fill: \"#8C8C8C\" }, void 0) }), void 0));\n};\nexport default ArrowIcon;\n//# sourceMappingURL=ArrowIcon.js.map","import { format } from 'date-fns';\nexport var formatCsvDate = function (index, date, sectionName) {\n if (sectionName !== 'metrics' && index === 0) {\n return 'This Week';\n }\n else {\n return \"Week of \" + format(new Date(date), 'MMM d');\n }\n};\n//# sourceMappingURL=formatCsvDate.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { useTypography } from '../../../styles/Typography';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { getToken } from '../../../utils/getToken';\nimport { InsightsService } from '../../../services/InsightsService';\nimport { List, ListItem, ListItemText } from '@material-ui/core';\nimport TextButton from '../../buttons/TextButton';\nimport { formatCsvDate } from '../../../utils/formatCsvDate';\nvar ReportList = function (_a) {\n var expandedKey = _a.expandedKey, expanded = _a.expanded, title = _a.title, setExpanded = _a.setExpanded, reports = _a.reports;\n var typo = useTypography();\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var downloadSelectedReport = function (fileName) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, insightsService, _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _b.sent();\n insightsService = new InsightsService(newToken, oid, tid, '', clientType);\n _a = expandedKey;\n switch (_a) {\n case 'user': return [3, 2];\n case 'outcomes': return [3, 4];\n case 'skills': return [3, 6];\n }\n return [3, 8];\n case 2: return [4, insightsService.downloadUserCsvReport(fileName)];\n case 3:\n _b.sent();\n return [3, 9];\n case 4: return [4, insightsService.downloadOutcomesCsvReport(fileName)];\n case 5:\n _b.sent();\n return [3, 9];\n case 6: return [4, insightsService.downloadSkillsCsvReport(fileName)];\n case 7:\n _b.sent();\n return [3, 9];\n case 8: return [3, 9];\n case 9: return [2];\n }\n });\n }); };\n if (reports && (expanded === '' || expanded === expandedKey)) {\n return (_jsxs(_Fragment, { children: [_jsx(\"span\", __assign({ className: typo.body1 }, { children: title }), void 0), _jsxs(List, { children: [reports.slice(0, expanded === expandedKey ? reports.length : 3).map(function (text, index) { return (_jsx(ListItem, __assign({ style: { paddingTop: 0, paddingBottom: 0 }, button: true, onClick: function () { return downloadSelectedReport(text.fileName); } }, { children: _jsx(ListItemText, { primary: formatCsvDate(index, text.date, expandedKey) }, void 0) }), text.fileName)); }), _jsx(TextButton, __assign({ style: { fontSize: 12, marginLeft: 12 }, variant: \"purple\", className: \"reportButton\", onClick: function () { return setExpanded(expanded === expandedKey ? '' : expandedKey); } }, { children: expanded === expandedKey ? 'See Less' : 'See More' }), void 0)] }, void 0)] }, void 0));\n }\n return null;\n};\nexport default ReportList;\n//# sourceMappingURL=ReportList.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { getToken } from '../../../utils/getToken';\nimport { InsightsService } from '../../../services/InsightsService';\nimport { Popover, useMediaQuery } from '@material-ui/core';\nimport { useTheme } from '@material-ui/core/styles';\nimport SecondaryButton from '../../buttons/SecondaryButton';\nimport ArrowIcon from '../../icons/ArrowIcon';\nimport { Colors } from '../../../utils/colors';\nimport ReportList from './ReportList';\nvar ReportsDownloader = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var _c = __read(useState(undefined), 2), csvReports = _c[0], setCsvReports = _c[1];\n var _d = __read(useState(null), 2), anchorEl = _d[0], setAnchorEl = _d[1];\n var _e = __read(useState(''), 2), expanded = _e[0], setExpanded = _e[1];\n var _f = __read(useState(false), 2), rotateArrow = _f[0], setRotateArrow = _f[1];\n var open = Boolean(anchorEl);\n var id = open ? 'csv-reports-download-popover' : undefined;\n var getCsvReportNames = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, insightsService, reports;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n insightsService = new InsightsService(newToken, oid, tid, '', clientType);\n return [4, insightsService.getCsvReportNames()];\n case 2:\n reports = _a.sent();\n setCsvReports(reports);\n return [2];\n }\n });\n }); }, [account, clientType, instance, oid, ssoToken, tid]);\n useEffect(function () {\n getCsvReportNames();\n }, [getCsvReportNames]);\n var handleClick = function (event) {\n setAnchorEl(event.currentTarget);\n setRotateArrow(true);\n };\n var handleClose = function () {\n setAnchorEl(null);\n setRotateArrow(false);\n };\n return (_jsxs(_Fragment, { children: [_jsxs(SecondaryButton, __assign({ className: \"reportButton\", \"aria-describedby\": id, onClick: handleClick, style: !isSmDown ? { width: 200, color: Colors.textSecondary } : { color: Colors.textSecondary } }, { children: [isSmDown ? 'Reports' : 'Download Reports', _jsx(ArrowIcon, { width: 10, height: 10, rotate: rotateArrow }, void 0)] }), void 0), _jsx(Popover, __assign({ id: id, open: open, anchorEl: anchorEl, onClose: handleClose, anchorOrigin: {\n vertical: 'bottom',\n horizontal: 'center',\n }, transformOrigin: {\n vertical: 'top',\n horizontal: 'center',\n } }, { children: _jsxs(\"div\", __assign({ style: { padding: 12, minWidth: 186 } }, { children: [_jsx(ReportList, { expanded: expanded, expandedKey: \"user\", title: \"Logins\", setExpanded: setExpanded, reports: csvReports === null || csvReports === void 0 ? void 0 : csvReports.userFileNames }, void 0), _jsx(ReportList, { expanded: expanded, expandedKey: \"skills\", title: \"Skills\", setExpanded: setExpanded, reports: csvReports === null || csvReports === void 0 ? void 0 : csvReports.skillFileNames }, void 0), _jsx(ReportList, { expanded: expanded, expandedKey: \"outcomes\", title: \"Outcomes\", setExpanded: setExpanded, reports: csvReports === null || csvReports === void 0 ? void 0 : csvReports.outcomeFileNames }, void 0)] }), void 0) }), void 0)] }, void 0));\n};\nexport default ReportsDownloader;\n//# sourceMappingURL=ReportsDownloader.js.map","var dayInMillis = 24 * 60 * 60 * 1000;\nvar weekInMillis = 7 * dayInMillis;\nvar getBucketForDate = function (date) {\n var sunday = new Date(date.getTime() - date.getUTCDay() * dayInMillis);\n var firstDayOfMonth = new Date(Date.UTC(sunday.getUTCFullYear(), sunday.getUTCMonth(), 1));\n var firstSundayOfMonth = new Date(firstDayOfMonth.getTime() - firstDayOfMonth.getUTCDay() * dayInMillis);\n if (firstSundayOfMonth.getUTCMonth() !== firstDayOfMonth.getUTCMonth()) {\n firstSundayOfMonth.setTime(firstSundayOfMonth.getTime() + weekInMillis);\n }\n var dayCount = sunday.getUTCDate() - firstSundayOfMonth.getUTCDate();\n var year = sunday.getUTCFullYear();\n var month = sunday.getUTCMonth() + 1;\n var weekOfMonth = Math.floor(dayCount / 7) + 1;\n return {\n year: 0,\n month: 0,\n oid: '',\n name: '',\n direct: 0,\n country: '',\n department: '',\n status: 0,\n licenseType: '',\n weekString: year + \"-\" + month + \"-\" + weekOfMonth,\n inProgress: 0,\n maintaining: 0,\n needsAttention: 0,\n };\n};\nexport var calculateBucketsForOutcomes = function (weeksBack) {\n var now = new Date();\n var date = new Date(now.getTime() - now.getUTCDay() * dayInMillis);\n date.setTime(date.getTime() - (weeksBack - 1) * weekInMillis);\n var results = {\n dict: {},\n list: [],\n };\n for (var i = 0; i < weeksBack; i++) {\n var bucket = getBucketForDate(date);\n results.dict[bucket.weekString] = bucket;\n results.list.push(bucket);\n date.setTime(date.getTime() + weekInMillis);\n }\n return results;\n};\n//# sourceMappingURL=calculateBuckets.js.map","import { calculateBucketsForOutcomes } from './calculateBuckets';\nexport var reduceAndFilter = function (dataArray, numberOfWeeks) {\n var buckets = calculateBucketsForOutcomes(numberOfWeeks);\n var bucketDict = buckets.dict;\n dataArray.forEach(function (item) {\n var bucket = bucketDict[item.weekString];\n if (bucket) {\n bucket.inProgress += item.inProgress;\n bucket.maintaining += item.maintaining;\n bucket.needsAttention += item.needsAttention;\n }\n });\n return buckets.list;\n};\n//# sourceMappingURL=reduceAndFilterInsights.js.map","export var defaultFilterValues = {\n time: 16,\n};\n//# sourceMappingURL=Constants.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\nimport UserGraph from '../UserGraph';\nimport InsightUsersTable from './InsightUsersTable';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { InsightsStatus } from '../../../types/types';\nimport { MenuItem, Paper, useTheme, useMediaQuery } from '@material-ui/core';\nimport UsersFilters from './UsersFilters';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nimport { Colors } from '../../../utils/colors';\nimport { UserContext } from '../../../contexts/UserContext';\nimport Select from '../../select/Select';\nimport { useTypography } from '../../../styles/Typography';\nimport { Filters } from '../Filters';\nimport ReportsDownloader from '../ReportsDownloader/ReportsDownloader';\nimport { hasAdminRole } from '../../../utils/hasAdminRole';\nimport { reduceAndFilter } from '../../../utils/reduceAndFilterInsights';\nimport { defaultFilterValues } from '../Constants';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e;\n return ({\n root: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n filters: (_b = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'flex-start',\n marginBottom: 16\n },\n _b[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n },\n _b),\n top: {\n marginBottom: 16,\n display: 'flex',\n flexDirection: 'column',\n },\n selectors: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n marginBottom: 16,\n },\n cards: (_c = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between'\n },\n _c[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n marginBottom: 0,\n },\n _c),\n graphCard: (_d = {\n width: 760,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _d[theme.breakpoints.down('md')] = {\n width: 670,\n marginBottom: 16,\n },\n _d[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _d),\n row: {\n width: '100%',\n paddingLeft: 24,\n paddingRight: 24,\n paddingTop: 16,\n paddingBottom: 16,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n text: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-end',\n alignItems: 'flex-end',\n },\n filtersCard: (_e = {\n width: 256,\n backgroundColor: Colors.white,\n borderRadius: 4\n },\n _e[theme.breakpoints.down('md')] = {\n width: '100%',\n background: 'none',\n marginBottom: 0,\n },\n _e),\n mobileFilters: {\n position: 'fixed',\n top: 0,\n right: 0,\n zIndex: 100,\n width: 312,\n minWidth: 312,\n backgroundColor: Colors.white,\n boxShadow: '0 12.5px 128px 4px rgba(0,0,0,0.08), 0 24px 32px 2px rgba(0,0,0,0.08)',\n display: 'flex',\n flexDirection: 'column',\n },\n filterScrollArea: {\n overflow: 'auto',\n msOverflowStyle: '-ms-autohiding-scrollbar',\n padding: 24,\n paddingTop: 16,\n '& > *': {\n marginBottom: 16,\n },\n },\n filtersInner: {\n flex: 7,\n width: '100%',\n },\n });\n});\nvar InsightUser = function (_a) {\n var _b;\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _c = useContext(InsightsContext), direct = _c.direct, setDirect = _c.setDirect, regionFilter = _c.regionFilter, setRegionFilter = _c.setRegionFilter, departmentFilter = _c.departmentFilter, setDepartmentFilter = _c.setDepartmentFilter, filter = _c.filter, setFilter = _c.setFilter, orderUsers = _c.orderUsers, setOrderUsers = _c.setOrderUsers, orderByUsers = _c.orderByUsers, setOrderByUsers = _c.setOrderByUsers;\n var _d = __read(useState(undefined), 2), dataset = _d[0], setDataset = _d[1];\n var _e = __read(useState(undefined), 2), filteredDataset = _e[0], setFilteredDataset = _e[1];\n var _f = __read(useState(false), 2), receivedData = _f[0], setReceivedData = _f[1];\n var _g = __read(useState([]), 2), reports = _g[0], setReports = _g[1];\n var _h = __read(useState([]), 2), filteredReports = _h[0], setFilteredReports = _h[1];\n var _j = __read(useState([]), 2), departmentOptions = _j[0], setDepartmentOptions = _j[1];\n var _k = __read(useState([]), 2), regions = _k[0], setRegions = _k[1];\n var _l = __read(useState(false), 2), setupFilters = _l[0], setSetupFilters = _l[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var ApiService = useApiService();\n var getImages = useCallback(function (reports) { return __awaiter(void 0, void 0, void 0, function () {\n var oids, response, images_1, newReports;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n oids = reports.map(function (report) { return report.oid; });\n if (!(oids.length > 0)) return [3, 2];\n return [4, ApiService.getUserImages(user, oids)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n images_1 = response.data;\n newReports = __spreadArray([], __read(reports), false);\n newReports.forEach(function (report) {\n var image = images_1.find(function (i) { return i.oid === report.oid; });\n if (image && image.contentType && image.data) {\n report.image = \"data:\" + image.contentType + \";base64,\" + image.data;\n }\n });\n setReports(newReports);\n setFilteredReports(newReports);\n _a.label = 2;\n case 2: return [2];\n }\n });\n }); }, [ApiService, user]);\n var getInsightsReport = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getWeeklyInsightsUserOutcomes(user)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setReports(response.data);\n setFilteredReports(response.data);\n return [4, getImages(response.data)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); }, [ApiService, getImages, user]);\n var getCsv = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getWeeklyInsightsUserGraph(user)];\n case 1:\n response = _a.sent();\n if (!response || response.data.length === 0) {\n return [2];\n }\n setDataset(response.data);\n setFilteredDataset(response.data);\n return [2];\n }\n });\n }); }, [ApiService, user]);\n var getDepartmentOptions = useCallback(function () {\n if (!reports || reports.length === 0) {\n return [];\n }\n var seenDepartments = new Set();\n var options = [];\n reports.forEach(function (report) {\n if (!seenDepartments.has(report.department)) {\n seenDepartments.add(report.department);\n options.push(report.department === 0 ? 'None' : report.department);\n }\n });\n setDepartmentOptions(options.sort(function (a, b) { return (a < b ? -1 : a > b ? 1 : 0); }));\n setSetupFilters(true);\n }, [reports]);\n var getRegions = useCallback(function () {\n if (!reports || reports.length === 0) {\n return [];\n }\n var seenRegions = new Set();\n var options = [];\n reports.forEach(function (report) {\n if (!seenRegions.has(report.country)) {\n seenRegions.add(report.country);\n options.push(report.country);\n }\n });\n setRegions(options.sort(function (a, b) { return (a < b ? -1 : a > b ? 1 : 0); }));\n }, [reports]);\n var runFilters = useCallback(function () {\n var newReports = reports;\n var newDataset = dataset;\n if (!newReports || !dataset || reports.length === 0 || dataset.length === 0) {\n return;\n }\n if (filter.search !== '') {\n newReports = newReports.filter(function (report) { return report.name.toUpperCase().includes(filter.search.toUpperCase()); });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) {\n return report.name.toUpperCase().includes(filter.search.toUpperCase());\n });\n }\n if (filter.department !== '') {\n newReports = newReports.filter(function (report) { return report.department === filter.department; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.department === filter.department; });\n }\n if (filter.region !== '') {\n newReports = newReports.filter(function (report) { return report.country === filter.region; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.country === filter.region; });\n }\n if (filter.direct !== '') {\n if (filter.direct === 'Direct Reports') {\n newReports = newReports.filter(function (report) { return report.direct === 1; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.direct === 1; });\n }\n else if (filter.direct === 'All Reports') {\n newReports = newReports.filter(function (report) { return report.direct >= 1; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.direct >= 1; });\n }\n }\n if (filter.status !== '') {\n newReports = newReports.filter(function (report) { return report.status === +filter.status; });\n var oids_1 = newReports.map(function (reports) { return reports.oid; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return oids_1.includes(report.oid); });\n }\n if (filter.time) {\n newDataset = reduceAndFilter(newDataset !== null && newDataset !== void 0 ? newDataset : [], filter.time);\n }\n setFilteredReports(newReports);\n setFilteredDataset(newDataset);\n setSetupFilters(true);\n }, [dataset, filter.department, filter.direct, filter.region, filter.search, filter.status, filter.time, reports]);\n useEffect(function () {\n if (!receivedData) {\n getInsightsReport();\n getCsv();\n setReceivedData(true);\n }\n if (!setupFilters) {\n getDepartmentOptions();\n getRegions();\n }\n runFilters();\n }, [getCsv, getDepartmentOptions, getInsightsReport, getRegions, receivedData, reports, runFilters, setupFilters]);\n useEffect(function () {\n if (isMdDown) {\n var newFilter = filter;\n newFilter.time = defaultFilterValues.time;\n setFilter(newFilter);\n runFilters();\n }\n }, [isMdDown, filter, runFilters, setFilter]);\n useEffect(function () {\n var setDefaultTime = function () {\n filter.time = defaultFilterValues.time;\n };\n return function () { return setDefaultTime(); };\n }, [filter]);\n var handleRequestSort = function (event, property) {\n var isAsc = orderByUsers === property && orderUsers === 'asc';\n setOrderUsers(isAsc ? 'desc' : 'asc');\n setOrderByUsers(property);\n };\n var clear = function () {\n setDepartmentFilter(undefined);\n setRegionFilter(undefined);\n setDirect(undefined);\n setFilter({\n search: '',\n department: '',\n region: '',\n direct: '',\n assignmentType: '',\n level: '',\n status: '',\n time: defaultFilterValues.time,\n });\n runFilters();\n };\n var search = function (name) {\n var newFilter = filter;\n newFilter.search = name;\n setFilter(newFilter);\n runFilters();\n };\n var readyFilter = function () {\n var newFilter = filter;\n if (newFilter.status === '') {\n newFilter.status = InsightsStatus.ReadyForMore.toString();\n }\n else if (newFilter.status === InsightsStatus.NeedsAttention.toString()) {\n newFilter.status = InsightsStatus.ReadyForMore.toString();\n }\n else {\n newFilter.status = '';\n }\n setFilter(newFilter);\n runFilters();\n };\n var needAttentionFilter = function () {\n var newFilter = filter;\n if (newFilter.status === '') {\n newFilter.status = InsightsStatus.NeedsAttention.toString();\n }\n else if (newFilter.status === InsightsStatus.ReadyForMore.toString()) {\n newFilter.status = InsightsStatus.NeedsAttention.toString();\n }\n else {\n newFilter.status = '';\n }\n setFilter(newFilter);\n runFilters();\n };\n var onChangeDepartments = function (event) {\n setDepartmentFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Departments') {\n newFilter.department = '';\n }\n else {\n newFilter.department = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearDepartments = function () {\n setDepartmentFilter(undefined);\n var newFilter = filter;\n newFilter.department = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeRegion = function (event) {\n setRegionFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Regions') {\n newFilter.region = '';\n }\n else {\n newFilter.region = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearRegions = function () {\n setRegionFilter(undefined);\n var newFilter = filter;\n newFilter.region = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeReports = function (event) {\n setDirect(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Users') {\n newFilter.direct = '';\n }\n else {\n newFilter.direct = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearReports = function () {\n setDirect(undefined);\n var newFilter = filter;\n newFilter.direct = '';\n setFilter(newFilter);\n runFilters();\n };\n var clearStatus = function () {\n setFilter(__assign(__assign({}, filter), { status: '' }));\n };\n var onGraphTime = function (event) {\n var newFilter = filter;\n newFilter.time = event.target.value;\n setFilter(newFilter);\n runFilters();\n };\n var getStatusPileTitle = function (statusFilter) {\n if (statusFilter) {\n switch (statusFilter) {\n case InsightsStatus.NeedsAttention.toString():\n return 'In Needs Attention';\n case InsightsStatus.ReadyForMore.toString():\n return 'Ready for Next Step';\n default:\n return statusFilter;\n }\n }\n return statusFilter;\n };\n if (!setupFilters) {\n return null;\n }\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsxs(\"div\", __assign({ className: classes.filters }, { children: [_jsx(\"div\", __assign({ className: classes.filtersInner }, { children: _jsx(Filters, { filteredLength: filteredReports.length, clearAll: clear, departmentFilter: departmentFilter, onChangeDepartments: onChangeDepartments, departmentOptions: departmentOptions, clearDepartment: clearDepartments, regionFilter: regionFilter, onChangeRegion: onChangeRegion, regionOptions: regions, clearRegion: clearRegions, reportsFilter: direct, onChangeReports: onChangeReports, clearReports: clearReports, statusFilter: getStatusPileTitle(filter.status), clearStatus: clearStatus }, void 0) }), void 0), hasAdminRole(user) && (_jsx(\"div\", __assign({ style: {\n flex: 3,\n display: 'flex',\n justifyContent: 'flex-end',\n alignItems: 'flex-end',\n } }, { children: _jsx(ReportsDownloader, {}, void 0) }), void 0))] }), void 0), _jsx(\"section\", __assign({ className: classes.top }, { children: _jsxs(\"div\", __assign({ className: classes.cards }, { children: [_jsxs(Paper, __assign({ elevation: 1, className: classes.graphCard }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsxs(\"div\", __assign({ className: classes.text }, { children: [_jsx(\"h2\", __assign({ className: typo.subtitle1, style: { fontWeight: 500, marginRight: 8 } }, { children: \"Outcome Progress\" }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: \"of Assigned Target Levels\" }), void 0)] }), void 0), _jsxs(Select, __assign({ value: (_b = filter.time) !== null && _b !== void 0 ? _b : defaultFilterValues.time, onChange: onGraphTime, light: true, style: { width: 150 }, disabled: isMdDown }, { children: [_jsx(MenuItem, __assign({ value: defaultFilterValues.time }, { children: '4-Months' }), void 0), _jsx(MenuItem, __assign({ value: 52 }, { children: '1-Year' }), void 0)] }), void 0)] }), void 0), _jsx(\"div\", __assign({ style: { display: 'flex', flexDirection: 'row', alignItems: 'center' } }, { children: _jsx(UserGraph, { dataset: filteredDataset }, void 0) }), void 0)] }), void 0), _jsx(Paper, __assign({ elevation: 1, className: classes.filtersCard }, { children: _jsx(UsersFilters, { reports: filteredReports, readyFilter: readyFilter, needAttentionFilter: needAttentionFilter }, void 0) }), void 0)] }), void 0) }), void 0), _jsx(\"section\", { children: _jsx(InsightUsersTable, { reports: filteredReports, getReports: getInsightsReport, search: search, order: orderUsers, orderBy: orderByUsers, handleRequestSort: handleRequestSort, page: page }, void 0) }, void 0)] }), void 0));\n};\nexport default InsightUser;\n//# sourceMappingURL=InsightUsers.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar ReadyForCompleteLargeIcon = function () {\n var id = useUUID('readyForCompleteIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"24\", height: \"24\", viewBox: \"0 0 24 24\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Ready for Complete\" }), void 0), _jsx(\"path\", { d: \"M8.795 15.875l-3.47-3.47a.996.996 0 1 0-1.41 1.41l4.18 4.18c.39.39 1.02.39 1.41 0l10.58-10.58a.996.996 0 1 0-1.41-1.41l-9.88 9.87z\", fill: \"#B0CB3E\" }, void 0)] }), void 0));\n};\nexport default ReadyForCompleteLargeIcon;\n//# sourceMappingURL=ReadyForCompleteLargeIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useUUID } from '../../hooks/useUUID';\nvar RequestLargeIcon = function () {\n var id = useUUID('requestIconTitleId');\n return (_jsxs(\"svg\", __assign({ width: \"24\", height: \"24\", viewBox: \"0 0 24 24\", xmlns: \"http://www.w3.org/2000/svg\", \"aria-labelledby\": id, role: \"img\" }, { children: [_jsx(\"title\", __assign({ id: id }, { children: \"Request\" }), void 0), _jsx(\"path\", { d: \"M13 18.791V7.621l4.88 4.88c.39.39 1.03.39 1.42 0a.996.996 0 0 0 0-1.41l-6.59-6.59a.996.996 0 0 0-1.41 0l-6.6 6.58a.996.996 0 1 0 1.41 1.41L11 7.621v11.17c0 .55.45 1 1 1s1-.45 1-1z\", fill: \"#654EA3\" }, void 0)] }), void 0));\n};\nexport default RequestLargeIcon;\n//# sourceMappingURL=RequestLargeIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { makeStyles } from '@material-ui/core';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { Colors } from '../../utils/colors';\nimport { UserContext } from '../../contexts/UserContext';\nimport Dialog from '../Dialog';\nimport { isStarterCustomer } from '../../utils/isStarterCustomer';\nimport { useHistory } from 'react-router-dom';\nvar useStyles = makeStyles({\n dialog: {},\n dialogText: {\n color: Colors.textSecondary,\n fontFamily: 'Open Sans',\n fontSize: 14,\n letterSpacing: 0.25,\n lineHeight: '20px',\n },\n checkboxLabel: {\n marginLeft: 8,\n },\n checkbox: {\n marginTop: 8,\n },\n});\nvar BulkAssignLicensesDialog = function (_a) {\n var page = _a.page, open = _a.open, onClose = _a.onClose, reports = _a.reports, getReports = _a.getReports, updateUser = _a.updateUser, type = _a.type;\n var classes = useStyles();\n var _b = __read(useState(false), 2), disableButton = _b[0], setDisableButton = _b[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n var history = useHistory();\n useEffect(function () {\n if (!user) {\n return;\n }\n }, [user]);\n var assignLicenses = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setDisableButton(true);\n return [4, ApiService.bulkLicenseAssign(user, reports)];\n case 1:\n _a.sent();\n if (!reports.includes(user.oid)) return [3, 3];\n return [4, updateUser()];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3:\n onClose();\n setDisableButton(false);\n return [4, getReports(true)];\n case 4:\n _a.sent();\n history.push(page + \"/history-insights\");\n return [2];\n }\n });\n }); };\n if (!user) {\n return null;\n }\n return (_jsx(Dialog, { open: open, onClose: onClose, onAccept: assignLicenses, cancelText: \"Cancel\", acceptText: \"Assign\", title: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass) ? 'Upgrade' : 'Assign', content: _jsx(\"div\", __assign({ className: classes.dialog }, { children: _jsx(\"div\", __assign({ className: classes.dialogText }, { children: reports.length === 0\n ? 'No Users'\n : type === 'selected' && reports.length === 1\n ? \"Assign Nulia licenses to the selected user?\"\n : type === 'selected' && reports.length > 1\n ? \"Assign Nulia licenses to the selected users?\"\n : type === 'none' && reports.length === 1\n ? 'Assign Selected User'\n : type === 'starter upgrade' && reports.length === 1\n ? 'Upgrade to complete'\n : type === 'starter upgrade'\n ? 'Upgrade all to complete'\n : 'Assign all Licenses' }), void 0) }), void 0), disabled: disableButton, cancelDisabled: disableButton }, void 0));\n};\nexport default BulkAssignLicensesDialog;\n//# sourceMappingURL=BulkAssignLicensesDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useEffect, useState } from 'react';\nimport { makeStyles } from '@material-ui/core';\nimport { LicenseDataType } from '../../../types/types';\nimport clsx from 'clsx';\nimport commaNumber from 'comma-number';\nimport ReadyForCompleteLargeIcon from '../../icons/ReadyForCompleteLargeIcon';\nimport RequestLargeIcon from '../../icons/RequestLargeIcon';\nimport BulkAssignLicensesDialog from '../../bulk/BulkAssignLicensesDialog';\nimport { LicenseType } from '../../../types/enums';\nimport { Link2 } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f, _g, _h;\n return ({\n licensesData: (_a = {\n padding: 24,\n display: 'flex',\n flexWrap: 'wrap',\n alignItems: 'center',\n justifyContent: 'space-between'\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n },\n _a),\n leftCounts: (_b = {\n display: 'flex',\n flexDirection: 'column',\n marginRight: 16\n },\n _b[theme.breakpoints.down('sm')] = {\n width: '100%',\n marginRight: 0,\n },\n _b),\n defaultMonthlyLeftCount: (_c = {\n height: 116,\n borderRadius: 4,\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n padding: 16\n },\n _c[theme.breakpoints.up('md')] = {\n justifyContent: 'space-between',\n },\n _c[theme.breakpoints.up('lg')] = {\n width: 336,\n minWidth: 336,\n },\n _c),\n starterMonthlyLeftCount: (_d = {\n height: 72,\n borderRadius: 4,\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n padding: 16\n },\n _d[theme.breakpoints.up('lg')] = {\n width: 336,\n minWidth: 336,\n },\n _d),\n o365Count: (_e = {\n justifyContent: 'center',\n marginBottom: 16\n },\n _e[theme.breakpoints.up('md')] = {\n justifyContent: 'normal',\n },\n _e),\n noLicenseCount: {},\n noLicenseLabel: {\n width: 144,\n minWidth: 144,\n },\n narrowLabel: {\n width: 100,\n minWidth: 100,\n },\n requestCount: {\n marginBottom: 16,\n },\n completedCount: {},\n rightCounts: (_f = {\n borderRadius: 4,\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n paddingTop: 16,\n paddingLeft: 48,\n paddingRight: 48,\n paddingBottom: 32,\n minHeight: 248\n },\n _f[theme.breakpoints.down('md')] = {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n paddingLeft: 16,\n paddingRight: 16,\n },\n _f[theme.breakpoints.down('sm')] = {\n marginTop: 19,\n width: '100%',\n },\n _f),\n rightCountsContainer: {\n display: 'flex',\n flexWrap: 'wrap',\n justifyContent: 'center',\n },\n smallNumber: {\n fontFamily: 'Ubuntu',\n fontSize: 32,\n fontWeight: 600,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.25,\n letterSpacing: 0.25,\n color: 'rgba(0,0,0,0.8)',\n marginRight: 16,\n },\n largeNumber: {\n fontFamily: 'Ubuntu',\n fontSize: 60,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.07,\n letterSpacing: -0.5,\n color: 'rgba(0,0,0,0.8)',\n marginBottom: 8,\n },\n countLabel: {\n fontFamily: 'Open Sans',\n fontSize: 16,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.6,\n letterSpacing: 0.5,\n color: 'rgba(0,0,0,0.64)',\n maxWidth: 100,\n },\n smallCountLabel: {\n fontFamily: 'Open Sans',\n fontSize: 14,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.43,\n letterSpacing: 0.25,\n color: 'rgba(0,0,0,0.64)',\n },\n rightTitle: {\n fontFamily: 'Ubuntu',\n fontSize: 12,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.33,\n letterSpacing: 2,\n color: 'rgba(0,0,0,0.64)',\n textAlign: 'center',\n marginBottom: 24,\n },\n monthCreditTitle: {\n marginBottom: 0,\n },\n rightCount: (_g = {\n borderRadius: 4,\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n minWidth: 140,\n height: 160,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center'\n },\n _g[theme.breakpoints.up('lg')] = {\n width: 284,\n minWidth: 284,\n },\n _g),\n leftInnerContainer: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n rightInnerContainer: {\n textAlign: 'center',\n },\n licensesUsed: (_h = {\n marginRight: 16\n },\n _h[theme.breakpoints.down('xs')] = {\n marginRight: 0,\n marginBottom: 16,\n },\n _h),\n icon: {\n marginRight: 16,\n },\n monthlyCredits: {},\n monthCreditsLabel: {\n fontFamily: 'Open Sans',\n fontSize: 14,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.43,\n letterSpacing: 0.25,\n color: 'rgba(0,0,0,0.88)',\n },\n monthCreditsNumber: {\n fontFamily: 'Open Sans',\n fontSize: 14,\n fontWeight: 600,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.43,\n letterSpacing: 0.25,\n color: 'rgba(0,0,0,0.88)',\n },\n monthCreditEntry: {\n height: 52,\n width: 625,\n minWidth: 625,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n monthCreditBorder: {\n borderBottom: 'solid 1px rgba(0, 0, 0, 0.08)',\n },\n monthlyCreditContainer: {\n paddingLeft: 32,\n paddingRight: 32,\n },\n warningText: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n color: 'rgba(0,0,0,0.64)',\n marginLeft: 8,\n },\n warningDate: {\n fontWeight: 'bold',\n },\n warningContainer: {\n display: 'flex',\n },\n monthlyLicenseSync: {\n width: 1040,\n height: 248,\n borderRadius: 4,\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n paddingTop: 16,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n },\n monthlyLicenseSyncContainer: {\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n display: 'flex',\n alignItems: 'center',\n marginBottom: 6,\n borderRadius: 4,\n },\n monthlyLicenseSyncLeft: {\n width: 292,\n height: 120,\n borderRight: 'solid 1px rgba(0, 0, 0, 0.12)',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n monthlyLicenseSyncRight: {\n width: 292,\n height: 120,\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n smallText: {\n fontFamily: 'Open Sans',\n fontSize: 12,\n fontStretch: 'normal',\n fontStyle: 'normal',\n lineHeight: 1.67,\n letterSpacing: 0.5,\n color: 'rgba(0,0,0,0.64)',\n },\n linkIconContainer: {\n position: 'relative',\n },\n linkIconMonthly: {\n position: 'absolute',\n top: -90,\n left: -11,\n height: 24,\n width: 24,\n },\n annualLicenseSync: {\n height: 248,\n },\n annualLicenseSyncLeft: {\n border: 'solid 1px rgba(0, 0, 0, 0.12)',\n borderRadius: 4,\n marginRight: 16,\n marginBottom: 16,\n },\n annualLicenseSyncTop: {\n width: 336,\n height: 97,\n borderBottom: 'solid 1px rgba(0, 0, 0, 0.12)',\n display: 'flex',\n alignItems: 'center',\n paddingLeft: 16,\n },\n annualLicenseSyncBottom: {\n width: 336,\n height: 97,\n display: 'flex',\n alignItems: 'center',\n paddingLeft: 16,\n },\n linkIconAnnual: {\n position: 'absolute',\n top: -166,\n left: '50%',\n marginLeft: -24,\n height: 24,\n width: 24,\n },\n });\n});\nvar LicensesData = function (_a) {\n var page = _a.page, reports = _a.reports, licenseData = _a.licenseData, getReports = _a.getReports, updateUser = _a.updateUser;\n var classes = useStyles();\n var _b = __read(useState({ openAssignLicenses: false, type: 'none' }), 2), state = _b[0], setState = _b[1];\n var _c = __read(useState(0), 2), completeUsed = _c[0], setCompleteUsed = _c[1];\n var _d = __read(useState(0), 2), requestUpgrades = _d[0], setRequestUpgrades = _d[1];\n var _e = __read(useState(0), 2), starterCompleted = _e[0], setStarterCompleted = _e[1];\n var closeAssignLicenses = function () { return setState(__assign(__assign({}, state), { openAssignLicenses: false })); };\n var DefaultLicenses = function (_a) {\n var o365Licenses = _a.o365Licenses, noNuliaLicenses = _a.noNuliaLicenses;\n return (_jsxs(\"div\", __assign({ className: classes.leftCounts }, { children: [_jsxs(\"div\", __assign({ className: clsx(classes.defaultMonthlyLeftCount, classes.o365Count) }, { children: [_jsx(\"div\", __assign({ className: classes.smallNumber }, { children: commaNumber(o365Licenses) }), void 0), _jsx(\"div\", __assign({ className: classes.countLabel }, { children: \"Office 365 Licenses\" }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: clsx(classes.defaultMonthlyLeftCount, classes.noLicenseCount) }, { children: _jsxs(\"div\", __assign({ className: classes.leftInnerContainer }, { children: [_jsx(\"div\", __assign({ className: classes.smallNumber }, { children: commaNumber(noNuliaLicenses < 0 ? 0 : noNuliaLicenses) }), void 0), _jsx(\"div\", __assign({ className: clsx(classes.countLabel, classes.noLicenseLabel) }, { children: \"Users without a Nulia License\" }), void 0)] }), void 0) }), void 0)] }), void 0));\n };\n var StarterLicenses = function (_a) {\n var o365Licenses = _a.o365Licenses, requests = _a.requests, completed = _a.completed;\n return (_jsxs(\"div\", __assign({ className: classes.leftCounts }, { children: [_jsxs(\"div\", __assign({ className: clsx(classes.starterMonthlyLeftCount, classes.o365Count) }, { children: [_jsx(\"div\", __assign({ className: classes.smallNumber }, { children: commaNumber(o365Licenses) }), void 0), _jsx(\"div\", __assign({ className: classes.smallCountLabel }, { children: \"Office 365 Licenses\" }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: clsx(classes.starterMonthlyLeftCount, classes.requestCount) }, { children: _jsxs(\"div\", __assign({ className: classes.leftInnerContainer }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: _jsx(RequestLargeIcon, {}, void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.smallNumber }, { children: commaNumber(requests) }), void 0), _jsx(\"div\", __assign({ className: clsx(classes.smallCountLabel, classes.narrowLabel) }, { children: \"REQUESTED UPGRADES\" }), void 0)] }), void 0) }), void 0), _jsx(\"div\", __assign({ className: clsx(classes.starterMonthlyLeftCount, classes.completedCount) }, { children: _jsxs(\"div\", __assign({ className: classes.leftInnerContainer }, { children: [_jsx(\"div\", __assign({ className: classes.icon }, { children: _jsx(ReadyForCompleteLargeIcon, {}, void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.smallNumber }, { children: commaNumber(completed) }), void 0), _jsx(\"div\", __assign({ className: clsx(classes.smallCountLabel, classes.narrowLabel) }, { children: \"COMPLETED NULIA STARTER\" }), void 0)] }), void 0) }), void 0)] }), void 0));\n };\n var NuliaLicenses = function (_a) {\n var title = _a.title, used = _a.used, available = _a.available;\n return (_jsxs(\"div\", __assign({ className: classes.rightCounts }, { children: [_jsx(\"div\", __assign({ className: classes.rightTitle }, { children: title }), void 0), _jsxs(\"div\", __assign({ className: classes.rightCountsContainer }, { children: [_jsx(\"div\", __assign({ className: clsx(classes.rightCount, classes.licensesUsed) }, { children: _jsxs(\"div\", __assign({ className: classes.rightInnerContainer }, { children: [_jsx(\"div\", __assign({ className: classes.largeNumber }, { children: commaNumber(used) }), void 0), _jsx(\"div\", __assign({ className: classes.countLabel }, { children: \"LICENSES USED\" }), void 0)] }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.rightCount }, { children: _jsxs(\"div\", __assign({ className: classes.rightInnerContainer }, { children: [_jsx(\"div\", __assign({ className: classes.largeNumber }, { children: commaNumber(available) }), void 0), _jsx(\"div\", __assign({ className: classes.countLabel }, { children: \"AVAILABLE LICENSES\" }), void 0)] }), void 0) }), void 0)] }), void 0)] }), void 0));\n };\n var MonthlyLicenseSync = function (_a) {\n var o365Licenses = _a.o365Licenses, completeUsed = _a.completeUsed;\n return (_jsxs(\"div\", __assign({ className: classes.monthlyLicenseSync }, { children: [_jsx(\"div\", __assign({ className: classes.rightTitle }, { children: \"NULIA COMPOLETE LICNESES\" }), void 0), _jsxs(\"div\", __assign({ className: classes.monthlyLicenseSyncContainer }, { children: [_jsxs(\"div\", __assign({ className: classes.monthlyLicenseSyncLeft }, { children: [_jsx(\"div\", __assign({ className: classes.largeNumber }, { children: commaNumber(o365Licenses) }), void 0), _jsx(\"div\", __assign({ className: classes.countLabel }, { children: \"MICROSOFT 365 LICENSES\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.monthlyLicenseSyncRight }, { children: [_jsx(\"div\", __assign({ className: classes.largeNumber }, { children: commaNumber(completeUsed) }), void 0), _jsx(\"div\", __assign({ className: classes.countLabel }, { children: \"NULIA COMPLETE LICENSES\" }), void 0)] }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.smallText }, { children: \"LICENSE SYNC DATA\" }), void 0), _jsx(\"div\", __assign({ className: classes.linkIconContainer }, { children: _jsx(\"div\", __assign({ className: classes.linkIconMonthly }, { children: _jsx(Link2, {}, void 0) }), void 0) }), void 0)] }), void 0));\n };\n useEffect(function () {\n var newCompleteUsed = 0;\n var newRequestUpgrades = 0;\n var newStarterCompleted = 0;\n reports.forEach(function (value) {\n if (value.licenseType === LicenseType.Complete) {\n newCompleteUsed++;\n }\n if (value.upgradeRequested !== 0) {\n newRequestUpgrades++;\n }\n if (value.completedStarter !== 0) {\n newStarterCompleted++;\n }\n });\n setCompleteUsed(newCompleteUsed);\n setRequestUpgrades(newRequestUpgrades);\n setStarterCompleted(newStarterCompleted);\n }, [reports]);\n return (_jsxs(_Fragment, { children: [licenseData.reportType === LicenseDataType.Complete ? (_jsxs(\"div\", __assign({ className: classes.licensesData }, { children: [_jsx(DefaultLicenses, { o365Licenses: licenseData.o365Licenses, noNuliaLicenses: licenseData.o365Licenses - completeUsed }, void 0), _jsx(NuliaLicenses, { title: \"Nulia Complete Licenses\", used: completeUsed, available: licenseData.completeAvailable }, void 0)] }), void 0)) : licenseData.reportType === LicenseDataType.Starter ? (_jsxs(\"div\", __assign({ className: classes.licensesData }, { children: [_jsx(StarterLicenses, { o365Licenses: licenseData.o365Licenses, requests: requestUpgrades, completed: starterCompleted }, void 0), _jsx(NuliaLicenses, { title: \"Nulia Complete Licenses\", used: completeUsed, available: licenseData.completeAvailable }, void 0)] }), void 0)) : licenseData.reportType === LicenseDataType.StarterComplete ? (_jsx(\"div\", __assign({ className: classes.licensesData }, { children: _jsx(MonthlyLicenseSync, { o365Licenses: licenseData.o365Licenses, completeUsed: completeUsed }, void 0) }), void 0)) : null, _jsx(BulkAssignLicensesDialog, { page: page, open: state.openAssignLicenses, onClose: closeAssignLicenses, reports: reports.map(function (value) { return value.oid; }), getReports: getReports, updateUser: updateUser, type: state.type }, void 0)] }, void 0));\n};\nexport default LicensesData;\n//# sourceMappingURL=LicenseData.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport Toolbar from '@material-ui/core/Toolbar';\nimport { useContext } from 'react';\nimport Search from '../../Search';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nvar useStyles = makeStyles({\n search: {\n width: '100%',\n },\n row: {\n width: '100%',\n marginTop: 16,\n },\n labels: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n },\n label: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n },\n});\nvar LicenseTableToolbar = function (_a) {\n var search = _a.search;\n var classes = useStyles();\n var _b = useContext(InsightsContext), searchValue = _b.searchValue, setSearchValue = _b.setSearchValue;\n var onChange = function (event) {\n setSearchValue(event.target.value);\n search(event.target.value);\n };\n return (_jsx(Toolbar, { children: _jsx(Search, { value: searchValue, onChange: onChange, placeholder: \"Search Users\", className: classes.search, style: { backgroundColor: '#FAFAFA' } }, void 0) }, void 0));\n};\nexport default LicenseTableToolbar;\n//# sourceMappingURL=LicenseTableToolbar.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { makeStyles } from '@material-ui/core';\nimport { Colors } from '../../../utils/colors';\nimport { LicenseChangeType } from '../../../types/types';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport Dialog from '../../Dialog';\nimport { isStarterCustomer } from '../../../utils/isStarterCustomer';\nvar useStyles = makeStyles({\n dialog: {},\n dialogText: {\n color: Colors.textSecondary,\n fontFamily: 'Open Sans',\n fontSize: 14,\n letterSpacing: 0.25,\n lineHeight: '20px',\n },\n checkboxLabel: {\n marginLeft: 8,\n },\n checkbox: {\n marginTop: 8,\n },\n});\nvar AssignLicensesDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, report = _a.report, getReports = _a.getReports, updateUser = _a.updateUser, type = _a.type, licenseData = _a.licenseData;\n var classes = useStyles();\n var _b = __read(useState(false), 2), disableButton = _b[0], setDisableButton = _b[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n useEffect(function () {\n if (!user) {\n return;\n }\n }, [user]);\n var assignLicenses = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user || !licenseData) {\n return [2];\n }\n setDisableButton(true);\n return [4, ApiService.changeCompleteLicensedUser(user, report.oid, isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass)\n ? LicenseChangeType.UpgradeUserPortal\n : LicenseChangeType.AddCompleteUserPortal)];\n case 1:\n _a.sent();\n return [4, updateUser()];\n case 2:\n _a.sent();\n onClose();\n setDisableButton(false);\n return [4, getReports(true)];\n case 3:\n _a.sent();\n return [2];\n }\n });\n }); };\n if (!user || !licenseData) {\n return null;\n }\n return (_jsx(Dialog, { open: open, onClose: onClose, onAccept: assignLicenses, cancelText: \"Cancel\", acceptText: \"Assign\", title: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass) ? 'Upgrade License' : 'Assign License', content: _jsx(\"div\", __assign({ className: classes.dialog }, { children: _jsx(\"div\", __assign({ className: classes.dialogText }, { children: 'This will assign a Nulia License to the selected user' }), void 0) }), void 0), disabled: disableButton, cancelDisabled: disableButton }, void 0));\n};\nexport default AssignLicensesDialog;\n//# sourceMappingURL=AssignLicensesDialog.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport { LicenseChangeType } from '../../../types/types';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { UserContext } from '../../../contexts/UserContext';\nimport Dialog from '../../Dialog';\nimport { isStarterCustomer } from '../../../utils/isStarterCustomer';\nvar RemoveLicensesDialog = function (_a) {\n var open = _a.open, onClose = _a.onClose, report = _a.report, getReports = _a.getReports, updateUser = _a.updateUser;\n var _b = __read(useState(false), 2), disableButton = _b[0], setDisableButton = _b[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n var removeLicenses = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setDisableButton(true);\n if (!isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass)) return [3, 2];\n return [4, ApiService.changeCompleteLicensedUser(user, report.oid, LicenseChangeType.PortalDowngradeToStarter)];\n case 1:\n _a.sent();\n return [3, 4];\n case 2: return [4, ApiService.changeCompleteLicensedUser(user, report.oid, LicenseChangeType.PortalRemoveComplete)];\n case 3:\n _a.sent();\n _a.label = 4;\n case 4: return [4, updateUser()];\n case 5:\n _a.sent();\n onClose();\n setDisableButton(false);\n return [4, getReports(true)];\n case 6:\n _a.sent();\n return [2];\n }\n });\n }); };\n return (_jsx(Dialog, { open: open, onClose: onClose, onAccept: removeLicenses, cancelText: \"Cancel\", acceptText: \"Accept\", title: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass) ? 'Downgrade License' : 'Remove License', text: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass)\n ? 'this will downgrade the user license to starter'\n : 'this will remove the user license', disabled: disableButton, cancelDisabled: disableButton }, void 0));\n};\nexport default RemoveLicensesDialog;\n//# sourceMappingURL=RemoveLicensesDialog.js.map","import { LicenseType } from '../types/enums';\nexport var isStarter = function (licenseType) { return licenseType === LicenseType.Starter; };\n//# sourceMappingURL=isStarter.js.map","import { LicenseClass } from '../types/enums';\nexport var hasSync = function (licenseClass) {\n return [LicenseClass.CompleteSync, LicenseClass.StarterCompleteSync].includes(licenseClass);\n};\n//# sourceMappingURL=hasSync.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport Dialog from '../../Dialog';\nvar NotEnoughLicensesDialog = function (_a) {\n var open = _a.open, onAccept = _a.onAccept;\n return (_jsx(Dialog, { open: open, onAccept: onAccept, acceptText: \"Cancel\", title: \"Not Enough Licenses\", text: \"You do not have enough licenses to complete that action.\" }, void 0));\n};\nexport default NotEnoughLicensesDialog;\n//# sourceMappingURL=NotEnoughLicensesDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { MenuItem } from '@material-ui/core';\nimport { useContext, useState } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { LicenseType } from '../../../types/enums';\nimport { LicenseDataType } from '../../../types/types';\nimport { InsightsMenu } from '../InsightsMenu';\nimport AssignLicensesDialog from './AssignLicensesDialog';\nimport RemoveLicensesDialog from './RemoveLicensesDialog';\nimport { isStarter } from '../../../utils/isStarter';\nimport { hasSync } from '../../../utils/hasSync';\nimport { hasAdminRole } from '../../../utils/hasAdminRole';\nimport NotEnoughLicensesDialog from './NotEnoughLicensesDialog';\nvar LicenseReportOverflow = function (_a) {\n var report = _a.report, getReports = _a.getReports, updateUser = _a.updateUser, licenseData = _a.licenseData;\n var _b = __read(useState(false), 2), openAssignLicenses = _b[0], setOpenAssignLicenses = _b[1];\n var _c = __read(useState(false), 2), openRemoveLicenses = _c[0], setOpenRemoveLicenses = _c[1];\n var _d = __read(useState(false), 2), openNotEnoughLicenses = _d[0], setOpenNotEnoughLicenses = _d[1];\n var user = useContext(UserContext).user;\n var toggleAssignLicenses = function () {\n if (licenseData.reportType === LicenseDataType.Complete) {\n var completeLicenceData = licenseData;\n if (completeLicenceData.completeAvailable < 1) {\n setOpenNotEnoughLicenses(!openNotEnoughLicenses);\n }\n else {\n setOpenAssignLicenses(!openAssignLicenses);\n }\n }\n else\n setOpenAssignLicenses(!openAssignLicenses);\n };\n var toggleRemoveLicenses = function () {\n setOpenRemoveLicenses(!openRemoveLicenses);\n };\n var toggleNotEnoughLicenses = function () {\n setOpenNotEnoughLicenses(!openNotEnoughLicenses);\n };\n var closeAssignLicenses = function () { return setOpenAssignLicenses(false); };\n if (!user) {\n return null;\n }\n var type = isStarter(report.licenseType) ? 'starter upgrade' : 'none';\n return (_jsxs(_Fragment, { children: [_jsxs(InsightsMenu, __assign({ ariaLabel: \"Open license menu\", isOnlyMenuItems: true }, { children: [!hasSync(user === null || user === void 0 ? void 0 : user.licenseClass) && hasAdminRole(user) && report.licenseType !== LicenseType.Complete && (_jsx(MenuItem, __assign({ onClick: toggleAssignLicenses }, { children: isStarter(report.licenseType) ? 'Upgrade to Complete' : 'Assign' }), void 0)), !hasSync(user === null || user === void 0 ? void 0 : user.licenseClass) && hasAdminRole(user) && report.licenseType === LicenseType.Complete && (_jsx(MenuItem, __assign({ onClick: toggleRemoveLicenses }, { children: \"REMOVE LICENSES\" }), void 0))] }), void 0), _jsx(AssignLicensesDialog, { open: openAssignLicenses, onClose: closeAssignLicenses, report: report, getReports: getReports, updateUser: updateUser, type: type, licenseData: licenseData }, void 0), _jsx(RemoveLicensesDialog, { open: openRemoveLicenses, onClose: toggleRemoveLicenses, report: report, getReports: getReports, updateUser: updateUser }, void 0), _jsx(NotEnoughLicensesDialog, { open: openNotEnoughLicenses, onAccept: toggleNotEnoughLicenses }, void 0)] }, void 0));\n};\nexport default LicenseReportOverflow;\n//# sourceMappingURL=LicenseReportOverflow.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport TableHead from '@material-ui/core/TableHead';\nimport TableRow from '@material-ui/core/TableRow';\nimport TableCell from '@material-ui/core/TableCell';\nimport Checkbox from '@material-ui/core/Checkbox';\nimport TableSortLabel from '@material-ui/core/TableSortLabel';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport { isStarterCustomer } from '../../../utils/isStarterCustomer';\nvar completeHeadCells = [\n { id: 'image', numeric: false, disablePadding: false, label: '' },\n { id: 'name', numeric: false, disablePadding: false, label: 'Display Name' },\n { id: 'department', numeric: false, disablePadding: true, label: 'Department' },\n { id: 'licenseType', numeric: false, disablePadding: true, label: 'License Type' },\n];\nvar starterHeadCells = [\n { id: 'image', numeric: false, disablePadding: false, label: '' },\n { id: 'name', numeric: false, disablePadding: false, label: 'Display Name' },\n { id: 'department', numeric: false, disablePadding: false, label: 'Department' },\n { id: 'licenseType', numeric: false, disablePadding: false, label: 'License Type' },\n {\n id: 'upgradeRequested',\n numeric: false,\n disablePadding: false,\n label: 'Upgrade Request',\n },\n { id: 'completedStarter', numeric: false, disablePadding: false, label: 'Completed Starter' },\n];\nvar LicenseTableHead = function (_a) {\n var classes = _a.classes, onSelectAllClick = _a.onSelectAllClick, order = _a.order, orderBy = _a.orderBy, numSelected = _a.numSelected, rowCount = _a.rowCount, onRequestSort = _a.onRequestSort;\n var user = useContext(UserContext).user;\n var createSortHandler = function (property) { return function (event) {\n onRequestSort(event, property);\n }; };\n var starter = isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass);\n var headCells = starter ? starterHeadCells : completeHeadCells;\n var headerRef = useRovingTabIndex();\n return (_jsx(TableHead, __assign({ ref: headerRef }, { children: _jsxs(TableRow, { children: [_jsx(TableCell, __assign({ padding: \"checkbox\" }, { children: _jsx(Checkbox, { indeterminate: numSelected > 0 && numSelected < rowCount, checked: rowCount > 0 && numSelected === rowCount, onChange: onSelectAllClick, inputProps: { 'aria-label': 'select all users' }, tabIndex: -1 }, void 0) }), void 0), headCells.map(function (headCell) { return (_jsx(TableCell, __assign({ align: \"left\", padding: headCell.disablePadding ? 'none' : 'default', sortDirection: orderBy === headCell.id ? order : false, \"aria-hidden\": headCell.label ? undefined : true }, { children: headCell.label && (_jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === headCell.id, direction: orderBy === headCell.id ? order : 'asc', onClick: createSortHandler(headCell.id) }, { children: [headCell.label, orderBy === headCell.id ? (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)) : null] }), void 0)) }), headCell.id)); }), _jsx(TableCell, { align: \"left\", padding: 'none', sortDirection: false, \"aria-hidden\": \"true\" }, 'overflowMenu')] }, void 0) }), void 0));\n};\nexport default LicenseTableHead;\n//# sourceMappingURL=LicenseTableHead.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { UserContext } from '../../contexts/UserContext';\nimport Dialog from '../Dialog';\nimport { isStarterCustomer } from '../../utils/isStarterCustomer';\nimport { useHistory } from 'react-router-dom';\nvar BulkRemoveLicensesDialog = function (_a) {\n var page = _a.page, open = _a.open, onClose = _a.onClose, reports = _a.reports, getReports = _a.getReports, updateUser = _a.updateUser;\n var _b = __read(useState(false), 2), disableButton = _b[0], setDisableButton = _b[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n var history = useHistory();\n var removeLicenses = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setDisableButton(true);\n return [4, ApiService.bulkLicenseRemove(user, reports)];\n case 1:\n _a.sent();\n if (!reports.includes(user.oid)) return [3, 3];\n return [4, updateUser()];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3:\n onClose();\n setDisableButton(false);\n return [4, getReports(true)];\n case 4:\n _a.sent();\n history.push(page + \"/history-insights\");\n return [2];\n }\n });\n }); };\n return (_jsx(Dialog, { open: open, onClose: onClose, onAccept: removeLicenses, cancelText: \"Cancel\", acceptText: \"Accept\", title: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass) ? 'Downgrade' : 'Remove', text: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass)\n ? \"this will downgrade the selected users' license to starter\"\n : \"this will remove the selected users' license\", disabled: disableButton, cancelDisabled: disableButton }, void 0));\n};\nexport default BulkRemoveLicensesDialog;\n//# sourceMappingURL=BulkRemoveLicenseDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useState, useEffect } from 'react';\nimport { createStyles, makeStyles, useTheme } from '@material-ui/core/styles';\nimport Table from '@material-ui/core/Table';\nimport TableBody from '@material-ui/core/TableBody';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableContainer from '@material-ui/core/TableContainer';\nimport TablePagination from '@material-ui/core/TablePagination';\nimport TableRow from '@material-ui/core/TableRow';\nimport Paper from '@material-ui/core/Paper';\nimport Checkbox from '@material-ui/core/Checkbox';\nimport { LicenseDataType } from '../../../types/types';\nimport LicenseTableToolbar from './LicenseTableToolbar';\nimport { Avatar, useMediaQuery } from '@material-ui/core';\nimport LicenseReportOverflow from './LicenseReportOverflow';\nimport LicenseTableHead from './LicenseTableHead';\nimport clsx from 'clsx';\nimport { UserContext } from '../../../contexts/UserContext';\nimport TextButton from '../../buttons/TextButton';\nimport { Colors } from '../../../utils/colors';\nimport { useTypography } from '../../../styles/Typography';\nimport DefaultUserImage from '../../DefaultUserImage';\nimport BulkAssignLicensesDialog from '../../bulk/BulkAssignLicensesDialog';\nimport BulkRemoveLicensesDialog from '../../bulk/BulkRemoveLicenseDialog';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport { ChevronDown, ChevronUp } from 'react-feather';\nimport { isStarterCustomer } from '../../../utils/isStarterCustomer';\nimport { stableSort } from '../../../utils/stableSort';\nimport { getComparator } from '../../../utils/getComparator';\nimport { LicenseType } from '../../../types/enums';\nimport NotEnoughLicensesDialog from './NotEnoughLicensesDialog';\nvar useStyles = makeStyles(function (theme) {\n return createStyles({\n root: {\n width: '100%',\n },\n paper: {\n width: '100%',\n marginBottom: theme.spacing(2),\n },\n table: {},\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n image: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n margin: 'auto',\n },\n avatar: {\n height: 24,\n width: 24,\n minHeight: 24,\n minWidth: 24,\n },\n mobileToolbar: {\n height: 42,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n },\n mobileButton: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n mobileOutcome: {\n height: 128,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n },\n evenBackground: {\n backgroundColor: '#fafafa',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n mobileImage: {\n height: 24,\n width: 24,\n margin: '0px 6px',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n margin: '0px 4px',\n },\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridTemplateRows: 'repeat(3, 1fr)',\n },\n context: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n backgroundColor: Colors.white,\n borderRadius: 4,\n padding: 12,\n marginBottom: 16,\n },\n contextButtons: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n },\n label: {\n '&:hover .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n '&:focus .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n },\n });\n});\nvar InsightLicensesTable = function (_a) {\n var pageName = _a.pageName, reports = _a.reports, licenseData = _a.licenseData, getReports = _a.getReports, getUser = _a.getUser, search = _a.search;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = __read(useState('asc'), 2), order = _b[0], setOrder = _b[1];\n var _c = __read(useState('name'), 2), orderBy = _c[0], setOrderBy = _c[1];\n var _d = __read(useState([]), 2), selected = _d[0], setSelected = _d[1];\n var _e = __read(useState(0), 2), page = _e[0], setPage = _e[1];\n var _f = __read(useState(10), 2), rowsPerPage = _f[0], setRowsPerPage = _f[1];\n var _g = __read(useState(false), 2), openBulkAssign = _g[0], setOpenBulkAssign = _g[1];\n var _h = __read(useState(false), 2), openBulkRemove = _h[0], setOpenBulkRemove = _h[1];\n var _j = __read(useState(false), 2), openNotEnoughLicenses = _j[0], setOpenNotEnoughLicenses = _j[1];\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var licenseRef = useRovingTabIndex();\n useEffect(function () {\n setPage(0);\n }, [reports]);\n var handleRequestSort = function (event, property) {\n var isAsc = orderBy === property && order === 'asc';\n setOrder(isAsc ? 'desc' : 'asc');\n setOrderBy(property);\n };\n var handleSelectAllClick = function (event) {\n if (event.target.checked) {\n var newSelecteds = reports.map(function (n) { return n.oid; });\n setSelected(newSelecteds);\n return;\n }\n setSelected([]);\n };\n var handleClick = function (event, oid) {\n var selectedIndex = selected.indexOf(oid);\n var newSelected = [];\n if (selectedIndex === -1) {\n newSelected = newSelected.concat(selected, oid);\n }\n else if (selectedIndex === 0) {\n newSelected = newSelected.concat(selected.slice(1));\n }\n else if (selectedIndex === selected.length - 1) {\n newSelected = newSelected.concat(selected.slice(0, -1));\n }\n else if (selectedIndex > 0) {\n newSelected = newSelected.concat(selected.slice(0, selectedIndex), selected.slice(selectedIndex + 1));\n }\n setSelected(newSelected);\n };\n var handleChangePage = function (event, newPage) {\n setPage(newPage);\n };\n var handleChangeRowsPerPage = function (event) {\n setRowsPerPage(parseInt(event.target.value, 10));\n setPage(0);\n };\n var starter = isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass);\n var isSelected = function (oid) { return selected.indexOf(oid) !== -1; };\n var cancel = function () {\n setSelected([]);\n };\n var toggleBulkAssignLicenses = function () {\n var _a;\n var numberOfSelectedRows = ((_a = reports === null || reports === void 0 ? void 0 : reports.filter(function (r) { return isSelected(r.oid) && r.licenseType === LicenseType.None; })) === null || _a === void 0 ? void 0 : _a.length) || 0;\n if (licenseData.reportType === LicenseDataType.Complete) {\n var completeLicenceData = licenseData;\n if (numberOfSelectedRows > completeLicenceData.completeAvailable) {\n setOpenNotEnoughLicenses(!openNotEnoughLicenses);\n }\n else {\n setOpenBulkAssign(!openBulkAssign);\n }\n }\n else\n setOpenBulkAssign(!openBulkAssign);\n };\n var toggleBulkRemoveLicenses = function () {\n setOpenBulkRemove(!openBulkRemove);\n };\n var toggleNotEnoughLicenses = function () {\n setOpenNotEnoughLicenses(!openNotEnoughLicenses);\n };\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [selected.length > 0 && (_jsx(\"section\", { children: _jsxs(\"div\", __assign({ className: classes.context }, { children: [_jsxs(\"div\", __assign({ className: classes.contextButtons }, { children: [_jsxs(\"p\", __assign({ className: typo.caption, style: { marginRight: 16 } }, { children: [selected.length, \" Selected\"] }), void 0), _jsx(TextButton, __assign({ onClick: toggleBulkAssignLicenses, style: { marginRight: 12, color: Colors.purple, fontSize: 10 } }, { children: isStarterCustomer(user === null || user === void 0 ? void 0 : user.licenseClass) ? 'Upgrade License' : 'Assign Licenses' }), void 0), _jsx(TextButton, __assign({ onClick: toggleBulkRemoveLicenses, style: { marginRight: 12, color: Colors.purple, fontSize: 10 } }, { children: \"Remove Licenses\" }), void 0)] }), void 0), _jsx(TextButton, __assign({ onClick: cancel, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Cancel\" }), void 0)] }), void 0) }, void 0)), !isSmDown ? (_jsxs(Paper, __assign({ className: classes.paper }, { children: [_jsx(LicenseTableToolbar, { search: search }, void 0), _jsx(TableContainer, { children: _jsxs(Table, __assign({ className: classes.table, size: 'medium', \"aria-label\": \"enhanced table\" }, { children: [_jsx(LicenseTableHead, { classes: classes, numSelected: selected.length, order: order, orderBy: orderBy, onSelectAllClick: handleSelectAllClick, onRequestSort: handleRequestSort, rowCount: reports.length }, void 0), _jsx(TableBody, __assign({ ref: licenseRef }, { children: stableSort(reports, getComparator(order, orderBy))\n .slice(page * rowsPerPage, page * rowsPerPage + rowsPerPage)\n .map(function (report, index) {\n var isItemSelected = isSelected(report.oid);\n var labelId = \"enhanced-table-checkbox-\" + index;\n return (_jsxs(TableRow, __assign({ hover: true, tabIndex: -1, selected: isItemSelected }, { children: [_jsx(TableCell, __assign({ onClick: function (event) { return handleClick(event, report.oid); }, padding: \"checkbox\", role: \"checkbox\", \"aria-checked\": isItemSelected }, { children: _jsx(Checkbox, { checked: isItemSelected, tabIndex: index === 0 ? 0 : -1, inputProps: { 'aria-labelledby': labelId } }, void 0) }), void 0), _jsx(TableCell, __assign({ padding: \"none\" }, { children: _jsx(\"div\", __assign({ className: classes.image }, { children: report.image ? (_jsx(Avatar, { src: report.image, className: classes.avatar, imgProps: { loading: 'lazy' } }, void 0)) : (_jsx(DefaultUserImage, { size: 24, fontSize: 20 }, void 0)) }), void 0) }), void 0), _jsx(TableCell, __assign({ component: \"th\", id: labelId, scope: \"row\", padding: \"none\" }, { children: report.name }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: report.department ? report.department : 'None' }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: report.licenseType }), void 0), starter && (_jsx(TableCell, __assign({ align: \"left\" }, { children: report.upgradeRequested === 0 ? 'No' : 'Yes' }), void 0)), starter && (_jsx(TableCell, __assign({ align: \"left\" }, { children: report.completedStarter === 0 ? 'No' : 'Yes' }), void 0)), _jsx(TableCell, __assign({ align: \"right\" }, { children: _jsx(LicenseReportOverflow, { report: report, licenseData: licenseData, getReports: getReports, updateUser: getUser }, void 0) }), void 0)] }), report.oid));\n }) }), void 0)] }), void 0) }, void 0), _jsx(TablePagination, { rowsPerPageOptions: [10, 25, 100, 250, 1000], component: \"div\", count: reports.length, rowsPerPage: rowsPerPage, page: page, onPageChange: handleChangePage, onRowsPerPageChange: handleChangeRowsPerPage }, void 0)] }), void 0)) : (_jsxs(Paper, __assign({ className: classes.paper }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileToolbar }, { children: [_jsx(Checkbox, { indeterminate: selected.length > 0 && selected.length < reports.length, checked: reports.length > 0 && selected.length === reports.length, onChange: handleSelectAllClick, inputProps: { 'aria-label': 'select all users' } }, void 0), _jsxs(\"div\", __assign({ className: classes.mobileButton }, { children: [_jsx(\"p\", __assign({ className: typo.body1 }, { children: \"Display Name\" }), void 0), _jsx(\"button\", __assign({ style: { background: 'none', border: 'none' }, onClick: function (event) { return handleRequestSort(event, 'name'); } }, { children: order === 'desc' ? _jsx(ChevronDown, {}, void 0) : _jsx(ChevronUp, {}, void 0) }), void 0)] }), void 0)] }), void 0), _jsx(\"ul\", __assign({ ref: licenseRef, style: { listStyle: 'none', paddingInlineStart: 0 } }, { children: stableSort(reports, getComparator(order, orderBy)).map(function (row, index) {\n var isItemSelected = isSelected(row.oid);\n var labelId = \"list-\" + index;\n return (_jsx(\"li\", { children: _jsxs(\"div\", __assign({ className: clsx(classes.mobileOutcome, index % 2 === 0 && classes.evenBackground) }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'space-between' } }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'flex-start' } }, { children: [_jsx(Checkbox, { onClick: function (event) { return handleClick(event, row.oid); }, checked: isItemSelected, inputProps: { 'aria-labelledby': labelId }, tabIndex: index === 0 ? 0 : -1 }, void 0), row.image ? (_jsx(Avatar, { src: row.image, className: classes.avatar, imgProps: { loading: 'lazy' } }, void 0)) : (_jsx(DefaultUserImage, { size: 24, fontSize: 20 }, void 0)), _jsx(\"p\", __assign({ className: typo.subtitle2, style: { marginLeft: 8 } }, { children: row.name }), void 0)] }), void 0), _jsx(LicenseReportOverflow, { report: row, licenseData: licenseData, getReports: getReports, updateUser: getUser }, void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Department\" }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.department ? row.department : 'None' }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"License Type\" }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.licenseType }), void 0), starter && (_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Upgrade Requested\" }), void 0)), starter && (_jsx(\"p\", __assign({ className: typo.caption }, { children: row.upgradeRequested === 0 ? 'No' : 'Yes' }), void 0)), starter && (_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Completed Starter\" }), void 0)), starter && (_jsx(\"p\", __assign({ className: typo.caption }, { children: row.completedStarter === 0 ? 'No' : 'Yes' }), void 0))] }), void 0)] }), void 0) }, row.oid));\n }) }), void 0)] }), void 0)), _jsx(BulkAssignLicensesDialog, { page: pageName, getReports: getReports, onClose: toggleBulkAssignLicenses, open: openBulkAssign, reports: selected, type: \"selected\", updateUser: getUser }, void 0), _jsx(BulkRemoveLicensesDialog, { page: pageName, getReports: getReports, onClose: toggleBulkRemoveLicenses, open: openBulkRemove, reports: selected, updateUser: getUser }, void 0), _jsx(NotEnoughLicensesDialog, { open: openNotEnoughLicenses, onAccept: toggleNotEnoughLicenses }, void 0)] }), void 0));\n};\nexport default InsightLicensesTable;\n//# sourceMappingURL=InsightLicensesTable.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { LicenseType } from '../../../types/enums';\nimport LicensesData from './LicenseData';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { makeStyles } from '@material-ui/core/styles';\nimport InsightLicensesTable from './InsightLicensesTable';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nimport { Colors } from '../../../utils/colors';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { Filters } from '../Filters';\nimport { Paper } from '@material-ui/core';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n top: {\n marginBottom: 16,\n },\n selectors: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n marginBottom: 16,\n },\n card: (_a = {\n width: 1084,\n height: 296,\n backgroundColor: Colors.white,\n borderRadius: 4,\n marginBottom: 32\n },\n _a[theme.breakpoints.down('md')] = {\n width: 771,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 480,\n height: 560,\n },\n _a[theme.breakpoints.down('xs')] = {\n width: 330,\n height: 740,\n },\n _a),\n });\n});\nvar InsightLicenses = function (_a) {\n var page = _a.page;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = useContext(InsightsContext), regionFilter = _b.regionFilter, setRegionFilter = _b.setRegionFilter, departmentFilter = _b.departmentFilter, setDepartmentFilter = _b.setDepartmentFilter, licenseFilter = _b.licenseFilter, setLicenseFilter = _b.setLicenseFilter, filter = _b.filter, setFilter = _b.setFilter;\n var _c = __read(useState(false), 2), recievedData = _c[0], setRecievedData = _c[1];\n var _d = __read(useState([]), 2), reports = _d[0], setReports = _d[1];\n var _e = __read(useState([]), 2), filteredReports = _e[0], setFilteredReports = _e[1];\n var _f = __read(useState(undefined), 2), licenseData = _f[0], setLicenseData = _f[1];\n var _g = __read(useState([]), 2), departmentOptions = _g[0], setDepartmentOptions = _g[1];\n var _h = __read(useState([]), 2), regions = _h[0], setRegions = _h[1];\n var _j = __read(useState(false), 2), setupFilters = _j[0], setSetupFilters = _j[1];\n var ApiService = useApiService();\n var getImages = useCallback(function (reports) { return __awaiter(void 0, void 0, void 0, function () {\n var oids, response, images_1, newReports;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n oids = reports.map(function (report) { return report.oid; });\n if (!(oids.length > 0)) return [3, 2];\n return [4, ApiService.getUserImages(user, oids)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n images_1 = response.data;\n newReports = __spreadArray([], __read(reports), false);\n newReports.forEach(function (report) {\n var image = images_1.find(function (i) { return i.oid === report.oid; });\n if (image && image.contentType && image.data) {\n report.image = \"data:\" + image.contentType + \";base64,\" + image.data;\n }\n });\n setReports(newReports);\n setFilteredReports(newReports);\n _a.label = 2;\n case 2: return [2];\n }\n });\n }); }, [ApiService, user]);\n var getLicenseReport = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightsUserLicenses(user)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setReports(response.data);\n setFilteredReports(response.data);\n return [4, getImages(response.data)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); }, [ApiService, getImages, user]);\n var getLicenseData = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getLicenseData(user)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setLicenseData(response.data);\n return [2];\n }\n });\n }); }, [ApiService, user]);\n var getDepartmentOptions = useCallback(function () {\n if (!reports || reports.length === 0) {\n return [];\n }\n var seenDepartments = new Set();\n var options = [];\n reports.forEach(function (report) {\n if (!seenDepartments.has(report.department)) {\n seenDepartments.add(report.department);\n options.push(report.department === 0 ? 'None' : report.department.toString());\n }\n });\n setDepartmentOptions(options.sort(function (a, b) { return (a < b ? -1 : a > b ? 1 : 0); }));\n }, [reports]);\n var getRegions = useCallback(function () {\n if (!reports || reports.length === 0) {\n return [];\n }\n var seenRegions = new Set();\n var options = [];\n reports.forEach(function (report) {\n if (!seenRegions.has(report.country)) {\n seenRegions.add(report.country);\n options.push(report.country);\n }\n });\n setRegions(options.sort(function (a, b) { return (a < b ? -1 : a > b ? 1 : 0); }));\n setSetupFilters(true);\n }, [reports]);\n useEffect(function () {\n if (!recievedData) {\n getLicenseReport();\n getLicenseData();\n setRecievedData(true);\n }\n if (!setupFilters) {\n getDepartmentOptions();\n getRegions();\n }\n }, [getDepartmentOptions, getLicenseData, getLicenseReport, getRegions, recievedData, setupFilters]);\n var runFilters = useCallback(function () {\n var newReports = reports;\n if (filter.search !== '') {\n newReports = newReports.filter(function (report) { return report.name.toUpperCase().includes(filter.search.toUpperCase()); });\n }\n if (filter.department !== '') {\n newReports = newReports.filter(function (report) { return report.department === filter.department; });\n }\n if (filter.region !== '') {\n newReports = newReports.filter(function (report) { return report.country === filter.region; });\n }\n if (filter.license === 'Complete') {\n newReports = newReports.filter(function (report) { return report.licenseType === LicenseType.Complete; });\n }\n if (filter.license === 'None') {\n newReports = newReports.filter(function (report) { return report.licenseType === LicenseType.None; });\n }\n setFilteredReports(newReports);\n }, [reports, filter]);\n useEffect(function () {\n runFilters();\n }, [reports, runFilters]);\n var search = function (name) {\n var newFilter = filter;\n newFilter.search = name;\n setFilter(newFilter);\n runFilters();\n };\n var clear = function () {\n setDepartmentFilter(undefined);\n setRegionFilter(undefined);\n setLicenseFilter(undefined);\n setFilter({\n search: '',\n department: '',\n region: '',\n direct: '',\n assignmentType: '',\n level: '',\n status: '',\n time: 14,\n license: '',\n });\n runFilters();\n };\n var onChangeDepartments = function (event) {\n setDepartmentFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Departments') {\n newFilter.department = '';\n }\n else {\n newFilter.department = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearDepartments = function () {\n setDepartmentFilter(undefined);\n var newFilter = filter;\n newFilter.department = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeLicenses = function (event) {\n setLicenseFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All License Types') {\n newFilter.license = '';\n }\n else {\n newFilter.license = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearLicense = function () {\n setLicenseFilter(undefined);\n var newFilter = filter;\n newFilter.license = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeRegion = function (event) {\n setRegionFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Regions') {\n newFilter.region = '';\n }\n else {\n newFilter.region = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearRegions = function () {\n setRegionFilter(undefined);\n var newFilter = filter;\n newFilter.region = '';\n setFilter(newFilter);\n runFilters();\n };\n if (!licenseData) {\n return null;\n }\n return (_jsxs(\"div\", { children: [_jsx(Paper, __assign({ elevation: 1, component: \"section\", className: classes.card }, { children: _jsx(LicensesData, { page: page, reports: reports, getReports: getLicenseReport, licenseData: licenseData, updateUser: function () {\n getLicenseReport();\n getLicenseData();\n } }, void 0) }), void 0), _jsx(Filters, { filteredLength: filteredReports.length, clearAll: clear, departmentFilter: departmentFilter, onChangeDepartments: onChangeDepartments, departmentOptions: departmentOptions, clearDepartment: clearDepartments, regionFilter: regionFilter, onChangeRegion: onChangeRegion, regionOptions: regions, clearRegion: clearRegions, licenseFilter: licenseFilter, onChangeLicenses: onChangeLicenses, clearLicense: clearLicense }, void 0), _jsx(\"section\", { children: _jsx(InsightLicensesTable, { pageName: page, reports: filteredReports, licenseData: licenseData, getReports: getLicenseReport, getUser: function () {\n getLicenseReport();\n getLicenseData();\n }, search: search }, void 0) }, void 0)] }, void 0));\n};\nexport default InsightLicenses;\n//# sourceMappingURL=InsightLicenses.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { useApiService } from '../services/ApiServiceProvider';\nimport { UserContext } from '../contexts/UserContext';\nimport { InsightsContext } from '../contexts/InsightsProvider';\nimport { SkillService } from '../services/SkillService';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nexport var useGetInsightsData = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var ApiService = useApiService();\n var user = useContext(UserContext).user;\n var insightsContext = useContext(InsightsContext);\n var getUser = useGetUser();\n var getAssignableOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getAssignableOutcomeDetails(user)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n insightsContext.setAssignableOutcomes(response.data);\n return [2];\n }\n });\n }); };\n var getAllSkills = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, skillService, allSkills;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n skillService = new SkillService(newToken, oid, tid, clientType);\n return [4, skillService.getAllSkills()];\n case 2:\n allSkills = _a.sent();\n if (!allSkills) {\n return [2];\n }\n insightsContext.setAllSkills(allSkills);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser(), getAssignableOutcomes(), getAllSkills()])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetInsightsData.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useEffect, useState } from 'react';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useMediaQuery } from '@material-ui/core';\nimport clsx from 'clsx';\nimport EngagementPointsIcon from '../../icons/EngagementPointsIcon';\nimport { Colors } from '../../../utils/colors';\nimport { Tooltip } from '../../Tooltip';\nimport BadgeCheckIcon from '../../icons/BadgeCheckIcon';\nimport { useTypography } from '../../../styles/Typography';\nimport { numberShortener } from '../../../utils/numberUtils';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f, _g, _h, _j;\n return ({\n filters: {\n width: '100%',\n height: '50%',\n display: 'grid',\n gridTemplateRows: 'repeat(1, 1fr)',\n gridTemplateColumns: 'repeat(2, 1fr)',\n },\n itemTopLeft: {\n borderRight: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderBottom: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n itemTopRight: {\n borderLeft: '0.5px solid rgba(0, 0, 0, 0.08)',\n borderBottom: '0.5px solid rgba(0, 0, 0, 0.08)',\n },\n item: (_a = {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n textAlign: 'center',\n padding: 4\n },\n _a[theme.breakpoints.down('md')] = {\n width: 150,\n },\n _a),\n horizontalFilters: {\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n textAlign: 'center',\n },\n mobileCard: (_b = {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n marginBottom: 32\n },\n _b[theme.breakpoints.down('md')] = {\n marginBottom: 0,\n },\n _b[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n },\n _b),\n mobileItem: (_c = {\n width: '100%',\n height: 150,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n backgroundColor: Colors.white,\n borderRadius: 4,\n boxShadow: '0px 1px 4px rgba(0, 0, 0, 0.08), 0px 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n margin: '0px 4px',\n padding: 12\n },\n _c[theme.breakpoints.down('sm')] = {\n marginBottom: 8,\n },\n _c[theme.breakpoints.down('md')] = {\n paddingLeft: 9,\n paddingRight: 9,\n justifyContent: 'center',\n },\n _c),\n mobileItemDots: (_d = {\n width: '100%',\n height: 150,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n backgroundColor: Colors.white,\n borderRadius: 4,\n boxShadow: '0px 1px 4px rgba(0, 0, 0, 0.08), 0px 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n margin: '0px 4px',\n padding: 12\n },\n _d[theme.breakpoints.down('md')] = {\n paddingLeft: 18,\n paddingRight: 0,\n justifyContent: 'center',\n },\n _d[theme.breakpoints.down('sm')] = {\n marginBottom: 8,\n paddingLeft: 9,\n paddingRight: 9,\n justifyContent: 'center',\n },\n _d),\n mobileTitle: (_e = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center'\n },\n _e[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n },\n _e),\n dot: (_f = {\n width: 12,\n height: 12,\n borderRadius: 25\n },\n _f[theme.breakpoints.down('sm')] = {\n marginRight: 12,\n },\n _f),\n text: (_g = {},\n _g[theme.breakpoints.down('sm')] = {\n marginTop: 4,\n },\n _g),\n row: (_h = {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-start',\n paddingLeft: 32,\n '& h4': (_j = {\n textAlign: 'right',\n minWidth: 60\n },\n _j[theme.breakpoints.down('md')] = {\n minWidth: 48,\n },\n _j)\n },\n _h[theme.breakpoints.down('md')] = {\n paddingLeft: 0,\n },\n _h[theme.breakpoints.down('sm')] = {\n paddingLeft: 32,\n },\n _h),\n });\n});\nvar Filters = function (_a) {\n var _b, _c, _d, _e, _f, _g;\n var reports = _a.reports;\n var typo = useTypography();\n var classes = useStyles();\n var _h = __read(useState(0), 2), badgeCount = _h[0], setBadgeCount = _h[1];\n var _j = __read(useState(0), 2), epCount = _j[0], setEpCount = _j[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n useEffect(function () {\n var newBadgeCount = 0;\n var newEpCount = 0;\n reports.forEach(function (value) {\n newBadgeCount += value.badges;\n newEpCount += value.points;\n });\n setBadgeCount(newBadgeCount);\n setEpCount(newEpCount);\n }, [reports]);\n return (_jsx(_Fragment, { children: !isMdDown ? (_jsxs(\"section\", __assign({ style: { height: '100%' } }, { children: [_jsxs(\"div\", __assign({ className: classes.filters }, { children: [_jsxs(\"div\", __assign({ className: clsx(classes.itemTopLeft, classes.item) }, { children: [_jsx(Tooltip, __assign({ title: \"Badges certify that a user has achieved a specific Outcome target level\" }, { children: _jsx(BadgeCheckIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5, style: { fontWeight: 400 } }, { children: badgeCount }), void 0), _jsx(\"p\", __assign({ className: typo.overline }, { children: badgeCount === 1 ? 'Badge Earned' : 'Badges Earned' }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: clsx(classes.itemTopRight, classes.item) }, { children: [_jsx(Tooltip, __assign({ title: \"Users earn points for engaging with Nulia Works as well as achieving Skills and Outcomes\" }, { children: _jsx(EngagementPointsIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5, style: { fontWeight: 400 } }, { children: numberShortener(epCount) }), void 0), _jsx(\"p\", __assign({ className: typo.overline }, { children: epCount === 1 ? 'Engagement Point (EP)' : 'Engagement Points (EP)' }), void 0)] }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.item, style: { height: '50%', justifyContent: 'space-around' } }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"h4\", __assign({ className: typo.h4, style: { marginRight: 6 } }, { children: (_b = reports[reports.length - 1]) === null || _b === void 0 ? void 0 : _b.needsAttention }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.red, marginRight: 12 } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: \"Needs Attention\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"h4\", __assign({ className: typo.h4, style: { marginRight: 6 } }, { children: (_c = reports[reports.length - 1]) === null || _c === void 0 ? void 0 : _c.inProgress }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.yellow, marginRight: 12 } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: \"In Progress\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"h4\", __assign({ className: typo.h4, style: { marginRight: 6 } }, { children: (_d = reports[reports.length - 1]) === null || _d === void 0 ? void 0 : _d.maintained }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.green, marginRight: 12 } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: \"Attained\" }), void 0)] }), void 0)] }), void 0)] }), void 0)) : (_jsxs(\"section\", __assign({ className: classes.mobileCard }, { children: [_jsx(\"div\", __assign({ className: classes.mobileItem }, { children: _jsxs(\"div\", __assign({ className: classes.mobileTitle }, { children: [_jsx(Tooltip, __assign({ title: \"Badges certify that a user has achieved a specific Outcome target level\" }, { children: _jsx(BadgeCheckIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5, style: { fontWeight: 400 } }, { children: badgeCount }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.overline, classes.text) }, { children: badgeCount === 1 ? 'Badge Earned' : 'Badges Earned' }), void 0)] }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.mobileItem }, { children: _jsxs(\"div\", __assign({ className: classes.mobileTitle }, { children: [_jsx(Tooltip, __assign({ title: \"Users earn points for engaging with Nulia Works as well as achieving Skills and Outcomes\" }, { children: _jsx(EngagementPointsIcon, { width: 30, height: 30 }, void 0) }), void 0), _jsx(\"h3\", __assign({ className: typo.h5, style: { fontWeight: 400 } }, { children: numberShortener(epCount) }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.overline, classes.text) }, { children: epCount === 1 ? 'Engagement Point (EP)' : 'Engagement Points (EP)' }), void 0)] }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.mobileItemDots, style: { justifyContent: 'space-around' } }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"h4\", __assign({ className: typo.h4, style: { marginRight: 6, fontSize: 24 } }, { children: (_e = reports[reports.length - 1]) === null || _e === void 0 ? void 0 : _e.needsAttention }), void 0), _jsx(\"div\", { className: classes.dot, style: isSmDown\n ? { backgroundColor: Colors.red, marginRight: 24 }\n : { backgroundColor: Colors.red, marginRight: 12 } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: \"Needs Attention\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"h4\", __assign({ className: typo.h4, style: { marginRight: 6, fontSize: 24 } }, { children: (_f = reports[reports.length - 1]) === null || _f === void 0 ? void 0 : _f.inProgress }), void 0), _jsx(\"div\", { className: classes.dot, style: isSmDown\n ? { backgroundColor: Colors.yellow, marginRight: 24 }\n : { backgroundColor: Colors.yellow, marginRight: 12 } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: \"In Progress\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"h4\", __assign({ className: typo.h4, style: { marginRight: 6, fontSize: 24 } }, { children: (_g = reports[reports.length - 1]) === null || _g === void 0 ? void 0 : _g.maintained }), void 0), _jsx(\"div\", { className: classes.dot, style: isSmDown\n ? { backgroundColor: Colors.green, marginRight: 24 }\n : { backgroundColor: Colors.green, marginRight: 12 } }, void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: \"Attained\" }), void 0)] }), void 0)] }), void 0)] }), void 0)) }, void 0));\n};\nexport default Filters;\n//# sourceMappingURL=Filters.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport TableHead from '@material-ui/core/TableHead';\nimport TableRow from '@material-ui/core/TableRow';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableSortLabel from '@material-ui/core/TableSortLabel';\nvar OutcomeTableHead = function (_a) {\n var classes = _a.classes, order = _a.order, orderBy = _a.orderBy, onRequestSort = _a.onRequestSort;\n var createSortHandler = function (property) { return function (event) {\n onRequestSort(event, property);\n }; };\n return (_jsxs(TableHead, { children: [_jsx(TableRow, { style: { marginBottom: 24 } }, void 0), _jsxs(TableRow, { children: [_jsx(TableCell, __assign({ padding: \"normal\" }, { children: _jsxs(TableSortLabel, __assign({ active: orderBy === 'name', direction: orderBy === 'name' ? order : 'asc', onClick: createSortHandler('name'), style: { marginLeft: 16, paddingTop: 16, paddingBottom: 8 } }, { children: [\"Outcome Name\", orderBy === 'name' ? (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)) : null] }), void 0) }), void 0), _jsx(TableCell, __assign({ padding: \"normal\" }, { children: _jsxs(TableSortLabel, __assign({ active: orderBy === 'level', direction: orderBy === 'level' ? order : 'asc', onClick: createSortHandler('level'), style: { paddingTop: 16, paddingBottom: 8, marginRight: 16 } }, { children: [\"Target Level\", orderBy === 'level' ? (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)) : null] }), void 0) }), void 0), _jsx(TableCell, __assign({ padding: \"normal\" }, { children: _jsxs(TableSortLabel, __assign({ active: orderBy === 'progress', direction: orderBy === 'progress' ? order : 'asc', onClick: createSortHandler('progress'), style: { paddingTop: 16, paddingBottom: 8, marginRight: 16 } }, { children: [\"Progress\", orderBy === 'progress' ? (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)) : null] }), void 0) }), void 0), _jsx(TableCell, __assign({ padding: \"normal\" }, { children: _jsxs(TableSortLabel, __assign({ active: orderBy === 'state', direction: orderBy === 'state' ? order : 'asc', onClick: createSortHandler('state'), style: { paddingTop: 16, paddingBottom: 8, marginRight: 16 } }, { children: [\"Status\", orderBy === 'state' ? (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)) : null] }), void 0) }), void 0)] }, void 0)] }, void 0));\n};\nexport default OutcomeTableHead;\n//# sourceMappingURL=OutcomeTableHead.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useState } from 'react';\nimport { createStyles, makeStyles, useTheme } from '@material-ui/core/styles';\nimport Table from '@material-ui/core/Table';\nimport TableBody from '@material-ui/core/TableBody';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableContainer from '@material-ui/core/TableContainer';\nimport TableRow from '@material-ui/core/TableRow';\nimport Paper from '@material-ui/core/Paper';\nimport { APPLICATION_ID, OUTCOMES_PATH } from '../../../utils/constants';\nimport { Link, useMediaQuery } from '@material-ui/core';\nimport OutcomeTableHead from './OutcomeTableHead';\nimport { Colors } from '../../../utils/colors';\nimport { useTypography } from '../../../styles/Typography';\nimport LevelIcon from '../../LevelIcon';\nimport { ClientType, CompetenceState, Level, PageIds } from '../../../types/enums';\nimport { ChevronDown, ChevronUp } from 'react-feather';\nimport { useHistory } from 'react-router';\nimport clsx from 'clsx';\nimport * as microsoftTeams from '@microsoft/teams-js';\nimport { stableSort } from '../../../utils/stableSort';\nimport { getComparator } from '../../../utils/getComparator';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return createStyles({\n root: {\n width: '100%',\n },\n paper: {\n width: '100%',\n marginBottom: theme.spacing(2),\n },\n table: {},\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n title: (_a = {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start'\n },\n _a[theme.breakpoints.down('md')] = {\n width: 250,\n },\n _a),\n image: {\n height: 64,\n minHeight: 64,\n width: 64,\n minWidth: 64,\n margin: 16,\n },\n mobileToolbar: {\n height: 42,\n paddingLeft: 16,\n paddingRight: 16,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n },\n mobileOutcome: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n padding: '12px 4px',\n },\n evenBackground: {\n backgroundColor: '#fafafa',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n mobileImage: {\n height: 24,\n width: 24,\n margin: '0px 6px',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n margin: '0px 4px',\n },\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridTemplateRows: 'repeat(2, 1fr)',\n },\n });\n});\nvar InsightsOutcomeTable = function (_a) {\n var rows = _a.rows, clientType = _a.clientType;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState('desc'), 2), order = _b[0], setOrder = _b[1];\n var _c = __read(useState('name'), 2), orderBy = _c[0], setOrderBy = _c[1];\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var history = useHistory();\n var handleRequestSort = function (event, property) {\n var isAsc = orderBy === property && order === 'asc';\n setOrder(isAsc ? 'desc' : 'asc');\n setOrderBy(property);\n };\n var openOutcome = function (id) {\n if (clientType === ClientType.platform) {\n history.push(\"outcome-details/\" + id);\n }\n else {\n microsoftTeams.executeDeepLink(\"https://teams.microsoft.com/l/entity/\" + APPLICATION_ID + \"/\" + PageIds.OutcomesPage + \"?context={\\\"subEntityId\\\": \" + id + \"}\");\n }\n };\n return (_jsx(\"div\", __assign({ className: classes.root }, { children: !isSmDown ? (_jsx(Paper, __assign({ className: classes.paper }, { children: _jsx(TableContainer, { children: _jsxs(Table, __assign({ className: classes.table, size: 'medium', \"aria-label\": \"enhanced table\" }, { children: [_jsx(OutcomeTableHead, { classes: classes, order: order, orderBy: orderBy, onRequestSort: handleRequestSort }, void 0), _jsx(TableBody, { children: stableSort(rows, getComparator(order, orderBy)).map(function (row, index) {\n var labelId = \"enhanced-table-checkbox-\" + index;\n return (_jsxs(TableRow, __assign({ hover: true, role: \"checkbox\", tabIndex: -1 }, { children: [_jsx(TableCell, __assign({ component: \"th\", id: labelId, scope: \"row\" }, { children: _jsxs(Link, __assign({ onClick: function () { return openOutcome(row.id); }, tabIndex: -1, style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n color: Colors.textPrimary,\n } }, { children: [_jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + row.image + \".svg\", loading: \"lazy\" }, void 0), row.name] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(LevelIcon, { progress: row.progress, level: row.level, state: row.state, type: \"outcome\" }, void 0), _jsx(\"div\", { style: { width: 4 } }, void 0), Level[row.level]] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(\"div\", { className: classes.dot, style: row.progress < 34\n ? { backgroundColor: Colors.low }\n : row.progress < 75\n ? { backgroundColor: Colors.moderate }\n : row.progress < 100\n ? { backgroundColor: Colors.high }\n : { backgroundColor: Colors.green } }, void 0), row.progress, \"%\"] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n paddingRight: 24,\n } }, { children: [_jsx(\"div\", { className: classes.dot, style: row.state === CompetenceState.NeedsAttention\n ? { backgroundColor: Colors.red }\n : row.state === CompetenceState.InProgress\n ? { backgroundColor: Colors.yellow }\n : row.state === CompetenceState.Maintain\n ? { backgroundColor: Colors.green }\n : { backgroundColor: Colors.unachievedSkill } }, void 0), row.state === CompetenceState.NeedsAttention\n ? 'Need Attention'\n : row.state === CompetenceState.InProgress\n ? 'In Progress'\n : row.state === CompetenceState.Maintain\n ? 'Maintained'\n : row.state === CompetenceState.LockedHardhat\n ? 'Hardhat'\n : 'Not Assigned'] }), void 0) }), void 0)] }), row.name));\n }) }, void 0)] }), void 0) }, void 0) }), void 0)) : (_jsxs(Paper, __assign({ className: classes.paper }, { children: [_jsx(\"div\", __assign({ className: classes.mobileToolbar }, { children: _jsxs(\"div\", __assign({ style: { display: 'flex', flexDirection: 'row' } }, { children: [_jsx(\"h3\", __assign({ className: typo.body1 }, { children: \"Display Name\" }), void 0), _jsx(\"button\", __assign({ style: { background: 'none', border: 'none' }, onClick: function (event) { return handleRequestSort(event, 'name'); } }, { children: order === 'asc' ? _jsx(ChevronUp, {}, void 0) : _jsx(ChevronDown, {}, void 0) }), void 0)] }), void 0) }), void 0), stableSort(rows, getComparator(order, orderBy)).map(function (row, index) {\n return (_jsxs(\"div\", __assign({ className: clsx(classes.mobileOutcome, index % 2 === 0 && classes.evenBackground) }, { children: [_jsx(\"div\", __assign({ className: classes.row, style: { justifyContent: 'space-between' } }, { children: _jsxs(Link, __assign({ onClick: function () { return openOutcome(row.id); }, tabIndex: -1, style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n color: Colors.textPrimary,\n } }, { children: [_jsx(\"img\", { src: \"\" + OUTCOMES_PATH + row.image + \".svg\", alt: \"\", className: classes.mobileImage }, void 0), _jsx(\"p\", __assign({ className: typo.subtitle1 }, { children: row.name }), void 0)] }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Target Level\" }), void 0), _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(LevelIcon, { progress: row.progress, level: row.level, state: row.state, type: \"outcome\" }, void 0), _jsx(\"div\", { style: { width: 4 } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: Level[row.level] }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Progress\" }), void 0), _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(\"div\", { className: classes.dot, style: row.progress < 34\n ? { backgroundColor: Colors.low }\n : row.progress < 75\n ? { backgroundColor: Colors.moderate }\n : row.progress < 100\n ? { backgroundColor: Colors.high }\n : { backgroundColor: Colors.green } }, void 0), _jsxs(\"p\", __assign({ className: typo.caption }, { children: [row.progress, \"%\"] }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Status\" }), void 0), _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(\"div\", { className: classes.dot, style: row.state === CompetenceState.NeedsAttention\n ? { backgroundColor: Colors.red }\n : row.state === CompetenceState.InProgress\n ? { backgroundColor: Colors.yellow }\n : row.state === CompetenceState.Maintain\n ? { backgroundColor: Colors.green }\n : { backgroundColor: Colors.unachievedSkill } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.state === CompetenceState.NeedsAttention\n ? 'Need Attention'\n : row.state === CompetenceState.InProgress\n ? 'In Progress'\n : row.state === CompetenceState.Maintain\n ? 'Maintained'\n : row.state === CompetenceState.LockedHardhat\n ? 'Hardhat'\n : 'Not Assigned' }), void 0)] }), void 0)] }), void 0)] }), index));\n })] }), void 0)) }), void 0));\n};\nexport default InsightsOutcomeTable;\n//# sourceMappingURL=InsightsOutcomeTable.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { MenuItem, useTheme, useMediaQuery } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useCallback, useContext, useEffect, useState, useMemo } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { useTypography } from '../../../styles/Typography';\nimport { Colors } from '../../../utils/colors';\nimport { toUserInsightOutcome } from '../../../utils/mapper';\nimport Select from '../../select/Select';\nimport UserGraph from '../UserGraph';\nimport Filters from './Filters';\nimport InsightsOutcomeTable from './InsightsOutcomeTable';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { OutcomeService } from '../../../services/OutcomeService';\nimport { getToken } from '../../../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { hasManagerRole } from '../../../utils/hasManagerRole';\nimport { isUnavailable } from '../../../utils/isUnavailable';\nimport { isUnassigned } from '../../../utils/isUnassigned';\nimport { reduceAndFilter } from '../../../utils/reduceAndFilterInsights';\nimport { defaultFilterValues } from '../Constants';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d;\n return ({\n root: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n top: {\n marginBottom: 16,\n display: 'flex',\n flexDirection: 'column',\n },\n selectors: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n marginBottom: 16,\n },\n cards: (_b = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between'\n },\n _b[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n },\n _b),\n graphCard: (_c = {\n width: 760,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _c[theme.breakpoints.down('md')] = {\n width: 670,\n marginBottom: 16,\n },\n _c[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _c),\n row: {\n width: '100%',\n paddingLeft: 20,\n paddingRight: 20,\n paddingTop: 16,\n paddingBottom: 16,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n text: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-end',\n alignItems: 'center',\n },\n filtersCard: (_d = {\n width: 256,\n backgroundColor: Colors.white,\n borderRadius: 4\n },\n _d[theme.breakpoints.down('md')] = {\n width: '100%',\n background: 'none',\n },\n _d[theme.breakpoints.down('sm')] = {\n width: '100%',\n background: 'none',\n },\n _d),\n mobileFilters: {\n position: 'fixed',\n top: 0,\n right: 0,\n zIndex: 100,\n width: 312,\n minWidth: 312,\n backgroundColor: Colors.white,\n boxShadow: '0 12.5px 128px 4px rgba(0,0,0,0.08), 0 24px 32px 2px rgba(0,0,0,0.08)',\n display: 'flex',\n flexDirection: 'column',\n },\n filterScrollArea: {\n overflow: 'auto',\n msOverflowStyle: '-ms-autohiding-scrollbar',\n padding: 24,\n paddingTop: 16,\n '& > *': {\n marginBottom: 16,\n },\n },\n });\n});\nvar InsightUser = function () {\n var _a;\n var typo = useTypography();\n var classes = useStyles();\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var user = useContext(UserContext).user;\n var _d = __read(useState(undefined), 2), dataset = _d[0], setDataset = _d[1];\n var _e = __read(useState(undefined), 2), filteredDataset = _e[0], setFilteredDataset = _e[1];\n var _f = __read(useState([]), 2), reports = _f[0], setReports = _f[1];\n var _g = __read(useState([]), 2), outcomes = _g[0], setOutcomes = _g[1];\n var _h = __read(useState(false), 2), receivedData = _h[0], setReceivedData = _h[1];\n var _j = __read(useState({\n search: '',\n department: '',\n region: '',\n direct: hasManagerRole(user) ? '1' : '',\n assignmentType: '',\n level: '',\n status: '',\n time: defaultFilterValues.time,\n }), 2), filter = _j[0], setFilter = _j[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var filteredOutcomes = useMemo(function () {\n return outcomes.filter(function (value) {\n return !isUnavailable(value.state) && !isUnassigned(value.state);\n });\n }, [outcomes]);\n var ApiService = useApiService();\n var getInsightsReport = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightsUserOutcomes(user)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setReports(response.data);\n return [2];\n }\n });\n }); }, [ApiService, user]);\n var getOutcomeReport = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getAllOutcomes()];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setOutcomes(response.map(function (value) { return toUserInsightOutcome(value); }));\n return [2];\n }\n });\n }); }, [account, clientType, instance, oid, ssoToken, tid]);\n var getCsv = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getWeeklyInsightsUserGraph(user)];\n case 1:\n response = _a.sent();\n if (!response || response.data.length === 0) {\n return [2];\n }\n setDataset(response.data);\n return [2];\n }\n });\n }); }, [ApiService, user]);\n var runFilters = useCallback(function () {\n var newReports = reports;\n var newDataset = dataset;\n if (!newReports || !dataset || reports.length === 0 || dataset.length === 0) {\n return;\n }\n if (filter.time) {\n newDataset = reduceAndFilter(newDataset !== null && newDataset !== void 0 ? newDataset : [], filter.time);\n }\n setFilteredDataset(newDataset);\n }, [dataset, filter.time, reports]);\n var getData = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getInsightsReport()];\n case 1:\n _a.sent();\n return [4, getOutcomeReport()];\n case 2:\n _a.sent();\n return [4, getCsv()];\n case 3:\n _a.sent();\n return [2];\n }\n });\n }); }, [getCsv, getInsightsReport, getOutcomeReport]);\n useEffect(function () {\n if (!receivedData) {\n getData();\n setReceivedData(true);\n }\n runFilters();\n }, [getCsv, getInsightsReport, setReceivedData, reports, runFilters, receivedData, getData]);\n useEffect(function () {\n if (isMdDown) {\n var newFilter = filter;\n newFilter.time = defaultFilterValues.time;\n setFilter(newFilter);\n runFilters();\n }\n }, [isMdDown, filter, runFilters, setFilter]);\n useEffect(function () {\n var setDefaultTime = function () {\n filter.time = defaultFilterValues.time;\n };\n return function () { return setDefaultTime(); };\n }, [filter]);\n var onGraphTime = function (event) {\n var newFilter = filter;\n newFilter.time = event.target.value;\n setFilter(newFilter);\n runFilters();\n };\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsx(\"section\", __assign({ className: classes.top }, { children: _jsxs(\"div\", __assign({ className: classes.cards }, { children: [_jsxs(\"div\", __assign({ className: classes.graphCard }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsxs(\"div\", __assign({ className: classes.text }, { children: [_jsx(\"h2\", __assign({ className: typo.subtitle1, style: { fontWeight: 500, marginRight: 8 } }, { children: \"Outcome Progress\" }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: \"of Assigned Target Levels\" }), void 0)] }), void 0), _jsxs(Select, __assign({ value: (_a = filter.time) !== null && _a !== void 0 ? _a : defaultFilterValues.time, onChange: onGraphTime, light: true, style: { width: 150, marginRight: 16 }, disabled: isMdDown }, { children: [_jsx(MenuItem, __assign({ value: defaultFilterValues.time }, { children: '4-Months' }), void 0), _jsx(MenuItem, __assign({ value: 52 }, { children: '1-Year' }), void 0)] }), void 0)] }), void 0), _jsx(\"div\", __assign({ style: { display: 'flex', flexDirection: 'row', alignItems: 'center' } }, { children: _jsx(UserGraph, { dataset: filteredDataset }, void 0) }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.filtersCard }, { children: _jsx(Filters, { reports: reports }, void 0) }), void 0)] }), void 0) }), void 0), _jsx(\"section\", { children: _jsx(InsightsOutcomeTable, { rows: filteredOutcomes, clientType: clientType }, void 0) }, void 0)] }), void 0));\n};\nexport default InsightUser;\n//# sourceMappingURL=InsightUser.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar BulkApi = (function () {\n function BulkApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.bulkHistory = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BulkHistory\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.bulkHistoryDetail = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/BulkHistory/\" + id;\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return BulkApi;\n}());\nexport { BulkApi };\n//# sourceMappingURL=BulkApi.js.map","import { BulkAction } from '../enums/BulkAction';\nexport var formatBulkHistoryAction = function (bulkHistoryAction) {\n switch (bulkHistoryAction) {\n case BulkAction.LicenseAssign:\n return 'License Assign';\n case BulkAction.LicenseRemove:\n return 'License Remove';\n case BulkAction.OutcomeAssign:\n return 'Outcome Assign';\n case BulkAction.OutcomeRemove:\n return 'Outcome Remove';\n default:\n return 'License Assign';\n }\n};\n//# sourceMappingURL=formatBulkHistoryAction.js.map","export var BulkStatus;\n(function (BulkStatus) {\n BulkStatus[\"Success\"] = \"Success\";\n BulkStatus[\"InProgress\"] = \"InProgress\";\n BulkStatus[\"Error\"] = \"Error\";\n})(BulkStatus || (BulkStatus = {}));\n//# sourceMappingURL=BulkStatus.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BulkApi } from '../data/BulkApi';\nimport { format } from 'date-fns';\nimport { formatBulkHistoryAction } from '../utils/formatBulkHistoryAction';\nvar BulkService = (function () {\n function BulkService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.bulkHistory = function () { return __awaiter(_this, void 0, void 0, function () {\n var bulkHistory;\n var _this = this;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.bulkApi.bulkHistory()];\n case 1:\n bulkHistory = _a.sent();\n if (!(bulkHistory === null || bulkHistory === void 0 ? void 0 : bulkHistory.data)) {\n return [2, undefined];\n }\n return [2, bulkHistory.data.map(function (value) { return _this.toBulkHistory(value); })];\n }\n });\n }); };\n this.bulkHistoryDetail = function (id) { return __awaiter(_this, void 0, void 0, function () {\n var bulkHistory;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.bulkApi.bulkHistoryDetail(id)];\n case 1:\n bulkHistory = _a.sent();\n if (!(bulkHistory === null || bulkHistory === void 0 ? void 0 : bulkHistory.data)) {\n return [2, undefined];\n }\n return [2, this.toBulkHistoryDetail(bulkHistory.data)];\n }\n });\n }); };\n this.toBulkHistoryDetail = function (bulkHistoryDetail) {\n return {\n action: bulkHistoryDetail.action,\n created: format(new Date(bulkHistoryDetail.created), 'P'),\n failed: bulkHistoryDetail.failed,\n id: bulkHistoryDetail.id,\n initiator: bulkHistoryDetail.initiator,\n outcomes: bulkHistoryDetail.outcomes,\n succeeded: bulkHistoryDetail.succeeded,\n total: bulkHistoryDetail.total,\n users: bulkHistoryDetail.users.map(function (user) { return _this.toBulkHistoryUser(user); }),\n };\n };\n this.toBulkHistoryUser = function (bulkHistoryUser) {\n return {\n department: bulkHistoryUser.department,\n displayName: bulkHistoryUser.name,\n id: bulkHistoryUser.oid,\n status: bulkHistoryUser.status,\n };\n };\n this.toBulkHistory = function (bulkHistory) {\n return {\n id: bulkHistory.id,\n actionName: formatBulkHistoryAction(bulkHistory.action),\n status: bulkHistory.status,\n date: new Date(bulkHistory.created),\n createdBy: bulkHistory.initiator,\n succeeded: bulkHistory.succeeded,\n failed: bulkHistory.failed,\n processed: bulkHistory.failed + bulkHistory.succeeded + \"/\" + bulkHistory.total,\n };\n };\n this.token = token;\n this.clientType = clientType;\n this.bulkApi = new BulkApi(token, oid, tid, sid, clientType);\n }\n return BulkService;\n}());\nexport { BulkService };\n//# sourceMappingURL=BulkService.js.map","import { Colors } from './colors';\nimport { BulkStatus } from '../enums/BulkStatus';\nvar getStatusColor = function (status) {\n switch (status) {\n case BulkStatus.Error:\n return Colors.red;\n case BulkStatus.InProgress:\n return Colors.yellow;\n case BulkStatus.Success:\n return Colors.green;\n default:\n return Colors.green;\n }\n};\nexport default getStatusColor;\n//# sourceMappingURL=getStatusColor.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useCallback, useEffect, useRef } from 'react';\nimport * as d3 from 'd3';\nimport { makeStyles } from '@material-ui/core';\nimport clsx from 'clsx';\nvar Colors;\n(function (Colors) {\n Colors[\"PRIMARY\"] = \"#654EA3\";\n Colors[\"SECONDARY\"] = \"#EAE8F0\";\n})(Colors || (Colors = {}));\nvar ArraySlicePositions;\n(function (ArraySlicePositions) {\n ArraySlicePositions[ArraySlicePositions[\"REST\"] = 0] = \"REST\";\n ArraySlicePositions[ArraySlicePositions[\"COMPANY_AVERAGE\"] = 1] = \"COMPANY_AVERAGE\";\n ArraySlicePositions[ArraySlicePositions[\"INDUSTRY_AVERAGE\"] = 2] = \"INDUSTRY_AVERAGE\";\n})(ArraySlicePositions || (ArraySlicePositions = {}));\nvar defaultDimension = {\n height: 100,\n width: 100,\n margin: {\n top: 10,\n right: 10,\n bottom: 10,\n left: 10,\n },\n};\nvar useStyles = makeStyles(function () { return ({\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridAutoRows: '1fr',\n gridColumnGap: 4,\n },\n gridItem: {\n display: 'flex',\n alignItems: 'center',\n },\n labelBox: {\n fontSize: 14,\n color: Colors.PRIMARY,\n fontWeight: 500,\n },\n percentLabel: {\n paddingLeft: 4,\n },\n percentValueLabel: {\n letterSpacing: 1,\n },\n}); });\nvar AdoptionChart = function (_a) {\n var chartId = _a.chartId, companyAverage = _a.companyAverage, industryAverage = _a.industryAverage, dimension = _a.dimension;\n var chRef = useRef(null);\n var classes = useStyles();\n var setChartData = useCallback(function (companyAverage, industryAverage) {\n var svg = d3.select(\"#\" + chartId + \" > g\");\n var dataValues = [companyAverage, 100 - companyAverage, industryAverage];\n var chartDimension = __assign(__assign({}, defaultDimension), dimension);\n var colors = [Colors.PRIMARY, Colors.SECONDARY, Colors.PRIMARY];\n var radius = chartDimension.height / 2 - chartDimension.margin.top - chartDimension.margin.bottom;\n var pie = d3\n .pie()\n .sort(null)\n .value(function (d) {\n return d;\n })\n .padAngle(0);\n var startAngleOuter;\n var endAngleOuter;\n var middleAngle;\n svg.selectAll('allSlices')\n .data(pie(dataValues))\n .enter()\n .append('path')\n .attr('d', function (d, i) {\n var currentStart = 0;\n dataValues.forEach(function (item, index) {\n if (index < i)\n currentStart += item;\n });\n var startAngle = i === ArraySlicePositions.REST ? 0 : 0 + 2 * Math.PI * (currentStart / 100);\n var endAngle = i === ArraySlicePositions.COMPANY_AVERAGE\n ? 2 * Math.PI\n : startAngle + 2 * Math.PI * (d.value / 100);\n if (i === ArraySlicePositions.INDUSTRY_AVERAGE) {\n startAngle = startAngleOuter = 2 * Math.PI - 2 * Math.PI * ((100 - d.value - 0.75) / 100);\n endAngle = endAngleOuter = 2 * Math.PI - 2 * Math.PI * ((100 - d.value + 0.75) / 100);\n middleAngle = (startAngleOuter + endAngleOuter) / 2;\n return null;\n }\n return d3.arc()({\n innerRadius: radius * 0.5,\n outerRadius: radius,\n startAngle: startAngle,\n endAngle: endAngle,\n });\n })\n .attr('id', function (d, i) {\n return 'arc' + i;\n })\n .attr('fill', function (d, i) {\n if (i === ArraySlicePositions.INDUSTRY_AVERAGE) {\n return '#000';\n }\n return colors[i];\n })\n .attr('stroke-width', '1px')\n .style('stroke', function (d, i) {\n if (i === ArraySlicePositions.INDUSTRY_AVERAGE)\n return Colors.SECONDARY;\n return null;\n })\n .style('opacity', function (d, i) {\n if (i === ArraySlicePositions.INDUSTRY_AVERAGE)\n return 0.5;\n return 1;\n });\n svg.append('line')\n .attr('x1', function () {\n return 5 + Math.cos(middleAngle - Math.PI / 2) * (radius - 15);\n })\n .attr('y1', function () {\n return 0 + Math.sin(middleAngle - Math.PI / 2) * (radius - 15);\n })\n .attr('x2', function () {\n return 5 + Math.cos(middleAngle - Math.PI / 2) * (radius + 5);\n })\n .attr('y2', function () {\n return Math.sin(middleAngle - Math.PI / 2) * (radius + 5);\n })\n .style('stroke-width', 2)\n .style('stroke', '#808080')\n .style('fill', '#808080')\n .style('transform', 'translate(-5px, 0)')\n .style('opacity', '0.9');\n }, [dimension, chartId]);\n var drawChart = useCallback(function () {\n d3.selectAll(chRef.current).remove();\n d3.selectAll(\"#\" + chartId).remove();\n var chartDimension = dimension || defaultDimension;\n d3.select(chRef.current)\n .append('svg')\n .attr('id', \"\" + chartId)\n .attr('width', chartDimension.width)\n .attr('height', chartDimension.height)\n .append('g')\n .attr('transform', 'translate(' + chartDimension.width / 2 + ',' + chartDimension.height / 2 + ')');\n setChartData(companyAverage, industryAverage);\n }, [companyAverage, industryAverage, setChartData, dimension, chartId]);\n useEffect(function () {\n drawChart();\n }, [dimension, drawChart]);\n useEffect(function () {\n setChartData(companyAverage, industryAverage);\n }, [companyAverage, industryAverage, setChartData]);\n return (_jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"div\", { style: {\n width: (dimension === null || dimension === void 0 ? void 0 : dimension.width) || defaultDimension.width,\n height: (dimension === null || dimension === void 0 ? void 0 : dimension.height) || (defaultDimension === null || defaultDimension === void 0 ? void 0 : defaultDimension.height),\n }, ref: chRef }, void 0), _jsxs(\"div\", __assign({ className: clsx(classes.labelBox, classes.gridItem) }, { children: [_jsx(\"span\", __assign({ className: classes.percentValueLabel }, { children: companyAverage }), void 0), _jsx(\"span\", __assign({ className: classes.percentLabel }, { children: \"%\" }), void 0)] }), void 0)] }), void 0));\n};\nexport default AdoptionChart;\n//# sourceMappingURL=AdoptionChart.js.map","import { BulkStatus } from '../enums/BulkStatus';\nvar getStatusString = function (status) {\n switch (status) {\n case BulkStatus.Error:\n return 'Error';\n case BulkStatus.InProgress:\n return 'In Progress';\n case BulkStatus.Success:\n return 'Success';\n default:\n return 'Error';\n }\n};\nexport default getStatusString;\n//# sourceMappingURL=getStatusString.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { DataGrid, } from '@material-ui/data-grid';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Paper, useMediaQuery, useTheme } from '@material-ui/core';\nimport { ChevronDown, ChevronUp, RefreshCw } from 'react-feather';\nimport TextButton from '../../buttons/TextButton';\nimport { getToken } from '../../../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { BulkService } from '../../../services/BulkService';\nimport Loading from '../../Loading';\nimport { useHistory } from 'react-router';\nimport getStatusColor from '../../../utils/getStatusColor';\nimport { useTypography } from '../../../styles/Typography';\nimport clsx from 'clsx';\nimport { stableSort } from '../../../utils/stableSort';\nimport { getComparator } from '../../../utils/getComparator';\nimport { format } from 'date-fns';\nimport { Tooltip } from '../../Tooltip';\nimport getStatusString from '../../../utils/getStatusString';\nvar columns = [\n {\n field: 'status',\n width: 30,\n align: 'right',\n renderHeader: function () { return _jsx(\"div\", {}, void 0); },\n renderCell: function (params) { return (_jsx(Tooltip, __assign({ title: getStatusString(params.row.status) }, { children: _jsx(\"div\", { style: { width: 12, height: 12, borderRadius: 25, background: getStatusColor(params.row.status) } }, void 0) }), void 0)); },\n sortable: false,\n disableColumnMenu: true,\n },\n { field: 'actionName', headerName: 'Action Name', width: 160, disableColumnMenu: true },\n {\n field: 'date',\n headerName: 'Date',\n width: 120,\n disableColumnMenu: true,\n renderCell: function (params) { return _jsx(\"span\", { children: format(params.row.date, 'P') }, void 0); },\n },\n { field: 'createdBy', headerName: 'Created By', width: 140, disableColumnMenu: true },\n {\n field: 'succeeded',\n headerName: 'Succeeded',\n width: 140,\n headerAlign: 'right',\n align: 'right',\n disableColumnMenu: true,\n },\n {\n field: 'failed',\n headerName: 'Failed',\n width: 140,\n headerAlign: 'right',\n align: 'right',\n disableColumnMenu: true,\n },\n {\n field: 'processed',\n headerName: 'Processed',\n width: 140,\n headerAlign: 'right',\n align: 'right',\n disableColumnMenu: true,\n },\n {\n field: 'details',\n width: 145,\n align: 'right',\n headerAlign: 'right',\n renderHeader: function () { return _jsx(\"div\", {}, void 0); },\n renderCell: function () { return _jsx(TextButton, __assign({ variant: \"purple\" }, { children: \"Details\" }), void 0); },\n sortable: false,\n disableColumnMenu: true,\n },\n];\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n root: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n refreshButton: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n MuiGridRoot: {\n '& .MuiDataGrid-iconSeparator': {\n display: 'none',\n },\n '& .MuiDataGrid-columnHeaderTitleContainer': {\n padding: 0,\n },\n },\n mobileToolbar: {\n height: 42,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n paddingLeft: 12,\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n },\n mobileButton: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n card: {\n padding: 12,\n },\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n gridLabels: {\n textAlign: 'right',\n paddingRight: 8,\n },\n oddBackground: {\n background: 'linear-gradient(0deg, #F3F1F8, #F3F1F8), #FFFFFF;',\n },\n });\n});\nvar InsightsHistory = function (_a) {\n var page = _a.page;\n var classes = useStyles();\n var typo = useTypography();\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var _d = __read(useState(undefined), 2), rows = _d[0], setRows = _d[1];\n var _e = __read(useState(false), 2), receivedData = _e[0], setReceivedData = _e[1];\n var _f = __read(useState(10), 2), pageSize = _f[0], setPageSize = _f[1];\n var _g = __read(useState('asc'), 2), order = _g[0], setOrder = _g[1];\n var _h = __read(useState('actionName'), 2), orderBy = _h[0], setOrderBy = _h[1];\n var history = useHistory();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var _j = __read(useState([\n {\n field: 'date',\n sort: 'desc',\n },\n ]), 2), sortModel = _j[0], setSortModel = _j[1];\n var getHistory = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, bulkService, bulkHistory;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n bulkService = new BulkService(newToken, oid, tid, clientType);\n return [4, bulkService.bulkHistory()];\n case 2:\n bulkHistory = _a.sent();\n setRows(bulkHistory);\n setReceivedData(true);\n return [2];\n }\n });\n }); }, [account, clientType, instance, oid, ssoToken, tid]);\n useEffect(function () {\n if (!receivedData) {\n getHistory();\n }\n }, [receivedData, getHistory]);\n var handleRowClick = function (params) {\n history.push(page + \"/insights-history-details/\" + params.id);\n };\n var handleRequestSort = function (event, property) {\n var isAsc = orderBy === property && order === 'asc';\n setOrder(isAsc ? 'desc' : 'asc');\n setOrderBy(property);\n };\n if (!rows && !receivedData) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsx(\"div\", __assign({ className: classes.refreshButton }, { children: _jsx(TextButton, __assign({ onClick: getHistory, variant: \"purple\" }, { children: \"Refresh\" }), void 0) }), void 0), !isMdDown ? (_jsx(Paper, __assign({ elevation: 1, style: { height: 110 + 52 * pageSize, width: '100%' } }, { children: _jsx(DataGrid, { rows: rows !== null && rows !== void 0 ? rows : [], columns: columns, sortingOrder: ['asc', 'desc'], sortModel: sortModel, onSortModelChange: function (model) { return setSortModel(model); }, onRowClick: handleRowClick, pageSize: pageSize, onPageSizeChange: function (newPageSize) { return setPageSize(newPageSize); }, rowsPerPageOptions: [10, 25], classes: { root: classes.MuiGridRoot } }, void 0) }), void 0)) : (_jsxs(Paper, __assign({ elevation: 1 }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileToolbar }, { children: [_jsx(RefreshCw, {}, void 0), _jsxs(\"div\", __assign({ className: classes.mobileButton }, { children: [_jsx(\"p\", __assign({ className: typo.body1 }, { children: \"Display Name\" }), void 0), _jsx(\"button\", __assign({ style: { background: 'none', border: 'none' }, onClick: function (event) { return handleRequestSort(event, 'actionName'); } }, { children: order === 'asc' ? _jsx(ChevronUp, {}, void 0) : _jsx(ChevronDown, {}, void 0) }), void 0)] }), void 0)] }), void 0), _jsx(\"ul\", { children: stableSort(rows !== null && rows !== void 0 ? rows : [], getComparator(order, orderBy)).map(function (row, index) { return (_jsxs(\"li\", __assign({ className: clsx(classes.card, index % 2 === 1 && classes.oddBackground) }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'space-between' } }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { style: {\n width: 12,\n height: 12,\n borderRadius: 25,\n marginRight: 8,\n background: getStatusColor(row.status),\n } }, void 0), _jsx(\"span\", { children: row.actionName }, void 0)] }), void 0), _jsx(TextButton, __assign({ variant: \"purple\", onClick: function () { return handleRowClick({ id: row.id }); }, style: { marginLeft: 8 }, tabIndex: -1 }, { children: \"Details\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"span\", __assign({ className: clsx(typo.caption, classes.gridLabels) }, { children: \"Date:\" }), void 0), _jsx(\"span\", __assign({ className: typo.caption }, { children: format(row.date, 'P') }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.gridLabels) }, { children: \"Created by:\" }), void 0), _jsx(\"span\", __assign({ className: typo.caption }, { children: row.createdBy }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.gridLabels) }, { children: \"Succeeded:\" }), void 0), _jsx(\"span\", __assign({ className: typo.caption }, { children: row.succeeded }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.gridLabels) }, { children: \"Failed:\" }), void 0), _jsx(\"span\", __assign({ className: typo.caption }, { children: row.failed }), void 0), _jsx(\"span\", __assign({ className: clsx(typo.caption, classes.gridLabels) }, { children: \"Processed:\" }), void 0), _jsx(\"span\", __assign({ className: typo.caption }, { children: row.succeeded }), void 0)] }), void 0)] }), row.id)); }) }, void 0)] }), void 0))] }), void 0));\n};\nexport default InsightsHistory;\n//# sourceMappingURL=History.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nvar InfoIcon = function (_a) {\n var _b = _a.width, width = _b === void 0 ? 10 : _b, _c = _a.height, height = _c === void 0 ? 10 : _c;\n return (_jsx(\"svg\", __assign({ width: width, height: height, viewBox: \"0 0 \" + width + \" \" + height, fill: \"none\", xmlns: \"http://www.w3.org/2000/svg\" }, { children: _jsx(\"path\", { fillRule: \"evenodd\", clipRule: \"evenodd\", d: \"M5 0C2.24 0 0 2.24 0 5C0 7.76 2.24 10 5 10C7.76 10 10 7.76 10 5C10 2.24 7.76 0 5 0ZM5 9C2.795 9 1 7.205 1 5C1 2.795 2.795 1 5 1C7.205 1 9 2.795 9 5C9 7.205 7.205 9 5 9ZM4.5 3.5V2.5H5.5V3.5H4.5ZM4.5 7.5V4.5H5.5V7.5H4.5Z\", fill: \"black\", fillOpacity: \"0.4\" }, void 0) }), void 0));\n};\nexport default InfoIcon;\n//# sourceMappingURL=InfoIcon.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useCallback } from 'react';\nimport TableHead from '@material-ui/core/TableHead';\nimport TableRow from '@material-ui/core/TableRow';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableSortLabel from '@material-ui/core/TableSortLabel';\nimport { useRovingTabIndex } from '../../../../hooks/useRovingTabIndex';\nimport { Colors } from '../../../../utils/colors';\nimport { makeStyles, useMediaQuery } from '@material-ui/core';\nimport { createStyles } from '@material-ui/core/styles';\nimport InfoIcon from '../../../icons/InfoIcon';\nimport { Tooltip } from '../../../Tooltip';\nimport { useTheme } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nvar fullHeadCells = [\n { id: 'app', numeric: false, disablePadding: false, label: 'App', width: '10%' },\n { id: 'action', numeric: false, disablePadding: false, label: 'Action', width: '25%' },\n { id: 'skill', numeric: false, disablePadding: true, label: 'Skill - Level', width: '25%' },\n {\n id: 'score',\n numeric: false,\n disablePadding: true,\n label: 'Score',\n tooltipText: 'The normalized score, on a scale from 1 to 100, versus a benchmark range, for all users who are performing the action',\n width: '20%',\n },\n {\n id: 'adoption',\n numeric: false,\n disablePadding: true,\n label: 'Adoption',\n tooltipText: 'The percentage of users who have performed the action at least once',\n width: '20%',\n },\n];\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return createStyles({\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n label: {\n fontSize: 14,\n fontWeight: 500,\n color: 'rgba(0, 0, 0, 0.8)',\n fontFamily: 'Open Sans',\n '&:hover .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n '&:focus .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n },\n tableCell: {\n borderBottom: 0,\n padding: '10px 6px',\n },\n legendTableCell: {\n borderBottom: 0,\n verticalAlign: 'text-top',\n minWidth: 140,\n padding: '0 8px',\n '&:last-of-type': {\n padding: '4px 40px',\n },\n },\n legendBox: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n },\n legendItemBox: {\n display: 'flex',\n flex: 1,\n alignItems: 'center',\n gap: 1,\n },\n legendItemLabel: {\n fontSize: 10,\n paddingLeft: 8,\n lineHeight: '16px',\n fontFamily: 'Open Sans',\n },\n coloredSquare: {\n background: Colors.purple,\n width: 10,\n height: 10,\n borderRadius: 1,\n },\n fullLine: {\n color: Colors.white,\n backgroundColor: Colors.iconDefault,\n height: 2,\n width: 10,\n boxSizing: 'content-box',\n borderTop: '1px solid #EAE8F0',\n borderBottom: '1px solid #EAE8F0',\n },\n dotBox: {\n backgroundColor: Colors.iconDefault,\n height: 2,\n width: 2,\n marginRight: 1,\n },\n headerTableCell: {\n padding: '12px 12px',\n color: 'rgba(0, 0, 0, 0.8)',\n '&:first-of-type': (_a = {\n padding: '14px 28px'\n },\n _a[theme.breakpoints.down('sm')] = {\n padding: '14px 8px',\n },\n _a),\n '&:last-of-type': {\n padding: '14px 40px',\n },\n },\n infoIconBox: {\n paddingLeft: 4,\n position: 'relative',\n bottom: 2,\n },\n hideSort: {\n '&:hover': {\n color: 'unset',\n },\n '& .MuiSvgIcon-root': {\n display: 'none',\n },\n },\n });\n});\nvar AssessmentTableHead = function (_a) {\n var order = _a.order, orderBy = _a.orderBy, onRequestSort = _a.onRequestSort, tenantName = _a.tenantName, noReports = _a.noReports;\n var classes = useStyles();\n var createSortHandler = function (property) { return function (event) {\n onRequestSort(event, property);\n }; };\n var headerRef = useRovingTabIndex();\n var theme = useTheme();\n var isMobile = useMediaQuery(theme.breakpoints.down('sm'));\n var headCells = isMobile ? fullHeadCells.filter(function (headCell) { return headCell.id !== 'skill'; }) : fullHeadCells;\n var sortDirectionDecider = useCallback(function (headCellId) {\n if (orderBy === 'score.companyRating' && headCellId === 'score')\n return order;\n if (orderBy === 'adoption.companyAverage' && headCellId === 'adoption')\n return order;\n return orderBy === headCellId ? order : false;\n }, [orderBy, order]);\n var isSortedColumn = useCallback(function (headCellId) {\n if (orderBy === 'score.companyRating' && headCellId === 'score')\n return true;\n if (orderBy === 'adoption.companyAverage' && headCellId === 'adoption')\n return true;\n return orderBy === headCellId;\n }, [orderBy]);\n return (_jsxs(TableHead, __assign({ ref: headerRef }, { children: [_jsx(TableRow, { children: headCells.map(function (headCell) {\n var _a;\n return (_jsx(TableCell, __assign({ align: \"left\", className: classes.headerTableCell, padding: headCell.disablePadding ? 'none' : 'normal', sortDirection: sortDirectionDecider(headCell.id), \"aria-hidden\": headCell.label ? undefined : true, width: headCell.width }, { children: headCell.label && (_jsx(_Fragment, { children: _jsxs(TableSortLabel, __assign({ className: noReports ? clsx(classes.label, classes.hideSort) : classes.label, active: isSortedColumn(headCell.id), direction: isSortedColumn(headCell.id) ? order : 'asc', onClick: createSortHandler(headCell.id) }, { children: [_jsx(\"span\", { children: headCell.label }, void 0), (headCell.id === 'score' || headCell.id === 'adoption') && (_jsx(Tooltip, __assign({ title: (_a = headCell.tooltipText) !== null && _a !== void 0 ? _a : '' }, { children: _jsx(\"div\", __assign({ className: classes.infoIconBox }, { children: _jsx(InfoIcon, {}, void 0) }), void 0) }), void 0)), isSortedColumn(headCell.id) && !noReports ? (_jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)) : null] }), void 0) }, void 0)) }), headCell.id));\n }) }, void 0), _jsx(TableRow, { children: !noReports &&\n headCells.map(function (head) {\n if (head.id === 'score') {\n return (_jsx(TableCell, __assign({ className: classes.legendTableCell }, { children: _jsxs(\"div\", __assign({ className: classes.legendBox }, { children: [_jsxs(\"div\", __assign({ className: classes.legendItemBox }, { children: [_jsx(\"span\", { className: classes.dotBox }, void 0), _jsx(\"span\", { className: classes.dotBox }, void 0), _jsx(\"span\", { className: classes.dotBox }, void 0), _jsx(\"span\", __assign({ className: classes.legendItemLabel }, { children: \"Benchmark Range\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.legendItemBox }, { children: [_jsx(\"div\", { className: classes.coloredSquare }, void 0), _jsx(\"span\", __assign({ className: classes.legendItemLabel }, { children: tenantName }), void 0)] }), void 0)] }), void 0) }), head.id));\n }\n else if (head.id === 'adoption') {\n return (_jsx(TableCell, __assign({ className: classes.legendTableCell }, { children: _jsxs(\"div\", __assign({ className: classes.legendBox }, { children: [_jsxs(\"div\", __assign({ className: classes.legendItemBox }, { children: [_jsx(\"div\", { className: classes.fullLine }, void 0), _jsx(\"span\", __assign({ className: classes.legendItemLabel }, { children: \"Benchmark\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.legendItemBox }, { children: [_jsx(\"div\", { className: classes.coloredSquare }, void 0), _jsx(\"span\", __assign({ className: classes.legendItemLabel }, { children: tenantName }), void 0)] }), void 0)] }), void 0) }), head.id));\n }\n return _jsx(TableCell, { className: classes.tableCell }, head.id);\n }) }, void 0)] }), void 0));\n};\nexport default AssessmentTableHead;\n//# sourceMappingURL=AssessmentTableHead.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useEffect, useRef } from 'react';\nimport * as d3 from 'd3';\nimport { makeStyles } from '@material-ui/core';\nimport { Colors } from '../../../../utils/colors';\nvar defaultBottomFillColor = '#B1A6D0';\nvar defaultFrontFillColor = Colors.purple;\nvar defaultDimension = {\n height: 60,\n width: 20,\n margin: {\n top: 5,\n right: 10,\n bottom: 5,\n left: 10,\n },\n};\nvar useStyles = makeStyles(function () { return ({\n root: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n },\n ratingBox: {\n paddingRight: 4,\n color: Colors.purple,\n fontWeight: 500,\n minWidth: 34,\n fontSize: 14,\n letterSpacing: '1.25px',\n },\n}); });\nvar ScoreChart = function (_a) {\n var dimension = _a.dimension, chartId = _a.chartId, rating = _a.rating, benchmarkRange = _a.benchmarkRange, bottomFillColor = _a.bottomFillColor, frontFillColor = _a.frontFillColor;\n var chRef = useRef(null);\n var classes = useStyles();\n useEffect(function () {\n d3.selectAll(chRef.current).remove();\n d3.selectAll(\"#\" + chartId).remove();\n var bottomFillColorHex = bottomFillColor || defaultBottomFillColor;\n var frontFillColorHex = frontFillColor || defaultFrontFillColor;\n var data = [\n { name: '1', value: 100, color: bottomFillColorHex },\n { name: '2', value: rating, color: frontFillColorHex },\n ];\n var chartDimension = dimension || defaultDimension;\n var svg = d3\n .select(chRef.current)\n .append('svg')\n .attr('id', \"\" + chartId)\n .attr('width', chartDimension.width + chartDimension.margin.left + chartDimension.margin.right)\n .attr('height', chartDimension.height + chartDimension.margin.top + chartDimension.margin.bottom)\n .style('transform', 'rotate(90deg) translateX(8px)')\n .append('g')\n .style('transform', 'translate(5px, 0)');\n var x = d3.scaleBand().domain(['key1']).range([0, chartDimension.width]);\n svg.append('g')\n .attr('transform', 'translate(0,' + chartDimension.height + ')')\n .call(d3.axisBottom(x).tickSize(0))\n .style('display', 'none');\n var y = d3.scaleLinear().domain([0, 100]).range([chartDimension.height, 0]);\n svg.append('g').call(d3.axisLeft(y)).style('display', 'none');\n var stackedData = d3.stack().keys(data.map(function (item) { return item.name; }))(data.map(function (item) {\n var _a;\n return _a = {},\n _a[item.name] = item.value,\n _a;\n }));\n svg.selectAll('.tick').style('display', 'none');\n svg.append('g')\n .selectAll('g')\n .data(stackedData)\n .enter()\n .append('g')\n .attr('fill', function (d, index) {\n return data[index].color;\n })\n .selectAll('rect')\n .data(function (d) {\n return d;\n })\n .enter()\n .append('rect')\n .attr('y', function (d) {\n return y(d[1]);\n })\n .attr('height', function (d) {\n var y0 = y(d[0]);\n var y1 = y(d[1]);\n if (y0 && y1)\n return y0 - y1;\n return y0;\n })\n .attr('width', x.bandwidth());\n if (!!benchmarkRange[0] && !!benchmarkRange[1])\n svg.append('g')\n .selectAll('g')\n .data(benchmarkRange)\n .enter()\n .append('line')\n .attr('x1', -5)\n .attr('y1', function (d) {\n return (chartDimension.height * d) / 100;\n })\n .attr('x2', chartDimension.width + 10)\n .attr('y2', function (d) {\n return (chartDimension.height * d) / 100;\n })\n .style('stroke-width', 2)\n .style('stroke', Colors.black)\n .style('fill', 'none')\n .style('stroke-dasharray', '3, 3')\n .style('transform', 'translate(-5px, 0)')\n .style('opacity', '0.25');\n }, [rating, benchmarkRange]);\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsx(\"div\", __assign({ className: classes.ratingBox }, { children: rating }), void 0), _jsx(\"div\", { ref: chRef }, void 0)] }), void 0));\n};\nexport default ScoreChart;\n//# sourceMappingURL=ScoreChart.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useState } from 'react';\nimport { createStyles, makeStyles, useTheme } from '@material-ui/core/styles';\nimport Table from '@material-ui/core/Table';\nimport TableBody from '@material-ui/core/TableBody';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableContainer from '@material-ui/core/TableContainer';\nimport TableRow from '@material-ui/core/TableRow';\nimport Paper from '@material-ui/core/Paper';\nimport clsx from 'clsx';\nimport TextButton from '../../../buttons/TextButton';\nimport { Colors } from '../../../../utils/colors';\nimport { useTypography } from '../../../../styles/Typography';\nimport { useRovingTabIndex } from '../../../../hooks/useRovingTabIndex';\nimport { stableSort } from '../../../../utils/stableSort';\nimport { getComparator } from '../../../../utils/getComparator';\nimport AssessmentTableHead from './AssessmentTableHead';\nimport AdoptionChart from '../charts/AdoptionChart';\nimport ScoreChart from '../charts/ScoreChart';\nimport { useMediaQuery } from '@material-ui/core';\nimport config from '../../../../config.json';\nimport Loading from '../../../Loading';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return createStyles({\n root: {\n width: '100%',\n borderBottom: 0,\n },\n paper: {\n width: '100%',\n marginBottom: 0,\n },\n context: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n backgroundColor: Colors.white,\n borderRadius: 4,\n padding: 12,\n },\n contextButtons: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n },\n tableContainer: {\n padding: 0,\n display: 'flex',\n justifyContent: 'center',\n color: '#616063',\n },\n tableCell: {\n borderBottom: 0,\n padding: '2px 12px',\n color: '#616063',\n fontFamily: 'Open Sans',\n fontSize: 14,\n '&:first-of-type': (_a = {\n padding: '4px 28px'\n },\n _a[theme.breakpoints.down('sm')] = {\n padding: '4px 8px',\n fontSize: 12,\n },\n _a),\n },\n tableFullTableCell: {\n borderBottom: 0,\n padding: '44px 12px 12px 12px',\n fontSize: 14,\n textAlign: 'center',\n fontFamily: 'Open Sans',\n },\n verticalAlignMiddle: {\n verticalAlign: 'middle',\n },\n appIcon: {\n maxWidth: 32,\n maxHeight: 32,\n },\n noReports: {\n display: 'flex',\n justifyContent: 'center',\n width: '100%',\n },\n });\n});\nvar scoreSortColumnName = 'score.companyRating';\nvar adoptionSortColumnName = 'adoption.companyAverage';\nvar InsightAssessmentTable = function (_a) {\n var assessments = _a.assessments, isLoading = _a.isLoading, tenantName = _a.tenantName, noReports = _a.noReports;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState('asc'), 2), order = _b[0], setOrder = _b[1];\n var _c = __read(useState('action'), 2), orderBy = _c[0], setOrderBy = _c[1];\n var _d = __read(useState([]), 2), selected = _d[0], setSelected = _d[1];\n var licenseRef = useRovingTabIndex();\n var theme = useTheme();\n var isMobile = useMediaQuery(theme.breakpoints.down('sm'));\n var handleRequestSort = function (event, property) {\n var isAsc = (orderBy === property || orderBy === scoreSortColumnName || orderBy === adoptionSortColumnName) &&\n order === 'asc';\n setOrder(isAsc ? 'desc' : 'asc');\n var propertyColumn = property;\n if (property === 'score')\n propertyColumn = scoreSortColumnName;\n else if (property === 'adoption')\n propertyColumn = adoptionSortColumnName;\n setOrderBy(propertyColumn);\n };\n var handleSelectAllClick = function (event) {\n if (event.target.checked) {\n var newSelecteds = assessments.map(function (n) { return n.oid; });\n setSelected(newSelecteds);\n return;\n }\n setSelected([]);\n };\n var cancel = function () {\n setSelected([]);\n };\n var generateAppIcon = function (officeApp) {\n if (!officeApp)\n return _jsx(\"span\", { children: \"No image\" }, void 0);\n var preparedOfficeAppName = officeApp.toLowerCase() === 'exchange' ? 'Outlook' : officeApp;\n return (_jsx(\"img\", { alt: \"app-icon\", className: classes.appIcon, src: config.CDN_URL + \"appimages/icons/office365-color-\" + preparedOfficeAppName + \".svg\" }, void 0));\n };\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [selected.length > 0 && (_jsx(\"section\", { children: _jsxs(\"div\", __assign({ className: classes.context }, { children: [_jsx(\"div\", __assign({ className: classes.contextButtons }, { children: _jsxs(\"p\", __assign({ className: typo.caption, style: { marginRight: 16 } }, { children: [selected.length, \" Selected\"] }), void 0) }), void 0), _jsx(TextButton, __assign({ onClick: cancel, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Cancel\" }), void 0)] }), void 0) }, void 0)), _jsx(Paper, __assign({ className: classes.paper }, { children: _jsx(TableContainer, __assign({ className: classes.tableContainer }, { children: _jsxs(Table, __assign({ size: 'medium', \"aria-label\": \"enhanced table\" }, { children: [_jsx(AssessmentTableHead, { numSelected: selected.length, order: order, orderBy: orderBy, onSelectAllClick: handleSelectAllClick, onRequestSort: handleRequestSort, rowCount: assessments.length, tenantName: tenantName, noReports: noReports }, void 0), isLoading ? (_jsx(TableBody, __assign({ ref: licenseRef }, { children: _jsx(TableRow, { children: _jsx(TableCell, __assign({ className: clsx(classes.tableCell, classes.verticalAlignMiddle), colSpan: 5 }, { children: _jsx(Loading, { smallHeight: true }, void 0) }), void 0) }, void 0) }), void 0)) : (_jsxs(TableBody, __assign({ ref: licenseRef }, { children: [noReports && (_jsx(TableRow, { children: _jsx(TableCell, __assign({ className: clsx(classes.tableFullTableCell, classes.verticalAlignMiddle), colSpan: 5 }, { children: \"There are no reports available yet\" }), void 0) }, void 0)), stableSort(assessments, getComparator(order, orderBy)).map(function (assessment, index) {\n return (_jsxs(TableRow, { children: [_jsx(TableCell, __assign({ className: clsx(classes.tableCell, classes.verticalAlignMiddle) }, { children: generateAppIcon(assessment.app) }), void 0), _jsx(TableCell, __assign({ className: classes.tableCell, scope: \"row\", padding: \"none\" }, { children: assessment.action }), void 0), !isMobile && (_jsx(TableCell, __assign({ className: classes.tableCell, scope: \"row\", padding: \"none\" }, { children: assessment.skill }), void 0)), _jsx(TableCell, __assign({ className: classes.tableCell }, { children: _jsx(ScoreChart, { rating: assessment.score.companyRating, benchmarkRange: assessment.score.benchmarkRange, chartId: \"skill-chart-\" + index }, void 0) }), void 0), _jsx(TableCell, __assign({ className: classes.tableCell }, { children: _jsx(AdoptionChart, { companyAverage: assessment.adoption.companyAverage, industryAverage: assessment.adoption.industryAverage, dimension: {\n width: 80,\n height: 80,\n }, chartId: \"adoption-chart-\" + index }, void 0) }), void 0)] }, index));\n })] }), void 0))] }), void 0) }), void 0) }), void 0)] }), void 0));\n};\nexport default InsightAssessmentTable;\n//# sourceMappingURL=InsightAssessmentTable.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { createStyles, InputBase, makeStyles, MenuItem, Paper, Select, TableContainer, withStyles, } from '@material-ui/core';\nimport { useCallback, useContext, useEffect, useState, useMemo } from 'react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { InsightsService } from '../../../services/InsightsService';\nimport { Colors } from '../../../utils/colors';\nimport { formatCsvDate } from '../../../utils/formatCsvDate';\nimport { getToken } from '../../../utils/getToken';\nimport Button from '../../buttons/Button';\nimport TextButton from '../../buttons/TextButton';\nimport Loading from '../../Loading';\nimport InsightAssessmentTable from './table/InsightAssessmentTable';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n root: (_a = {\n width: 1040,\n fontFamily: 'Ubuntu'\n },\n _a[theme.breakpoints.down('md')] = {\n width: 720,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: '98%',\n },\n _a),\n paper: {\n width: '100%',\n marginBottom: theme.spacing(2),\n },\n table: {},\n assessmentHeaderTableCell: {\n padding: '10px 20px',\n fontWeight: 500,\n fontSize: 16,\n },\n configContainer: (_b = {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n padding: '20px 0 10px 0',\n flexWrap: 'wrap',\n gap: 16\n },\n _b[theme.breakpoints.down('sm')] = {\n padding: '12px',\n },\n _b),\n settingsBox: {\n flex: 2,\n gap: 16,\n display: 'flex',\n },\n reportActionBox: (_c = {\n flex: 1,\n display: 'flex',\n justifyContent: 'flex-end'\n },\n _c[theme.breakpoints.down('sm')] = {\n justifyContent: 'flex-start',\n },\n _c),\n select: {\n '& .MuiSelect-root': {\n background: Colors.white,\n minWidth: 145,\n color: 'rgba(0, 0, 0, 0.64)',\n },\n },\n downloadReportSpan: {\n textTransform: 'uppercase',\n fontSize: 14,\n fontWeight: 500,\n },\n usersNumberBox: {\n paddingBottom: 10,\n paddingLeft: 10,\n fontFamily: 'Open Sans',\n fontSize: 14,\n },\n userNumberSpan: {\n paddingRight: 4,\n },\n });\n});\nvar BootstrapInput = withStyles(function (theme) {\n return createStyles({\n input: {\n borderRadius: 4,\n position: 'relative',\n backgroundColor: Colors.background,\n fontSize: 16,\n padding: '10px 26px 10px 12px',\n transition: theme.transitions.create(['border-color', 'box-shadow']),\n fontFamily: 'Open Sans',\n '&:focus': {\n borderRadius: 4,\n borderColor: Colors.purple,\n boxShadow: '0 0 0 0.2rem rgba(0,123,255,.25)',\n },\n },\n });\n})(InputBase);\nvar InsightsAssessments = function (_a) {\n var page = _a.page;\n var classes = useStyles();\n var _b = __read(useState([]), 2), assessments = _b[0], setAssessments = _b[1];\n var _c = __read(useState([]), 2), reports = _c[0], setReports = _c[1];\n var _d = __read(useState(undefined), 2), selectedReport = _d[0], setSelectedReport = _d[1];\n var _e = __read(useState([]), 2), reportList = _e[0], setReportList = _e[1];\n var _f = __read(useState(undefined), 2), selectedCompanyDepartment = _f[0], setSelectedCompanyDepartment = _f[1];\n var _g = __read(useState([]), 2), companyDepartmentList = _g[0], setCompanyDepartmentList = _g[1];\n var _h = __read(useState(false), 2), isReportListExpanded = _h[0], setReportListExpanded = _h[1];\n var _j = __read(useState(false), 2), isReportSelectOpen = _j[0], setReportSelectOpen = _j[1];\n var _k = __read(useState(true), 2), isFirstLoading = _k[0], setFirstLoading = _k[1];\n var _l = __read(useState(false), 2), isLoading = _l[0], setLoading = _l[1];\n var _m = __read(useState(''), 2), tenantName = _m[0], setTenantName = _m[1];\n var _o = useMsal(), instance = _o.instance, accounts = _o.accounts;\n var account = useAccount(accounts[0]);\n var _p = useContext(TokenContext), ssoToken = _p.ssoToken, oid = _p.oid, tid = _p.tid, clientType = _p.clientType;\n var fetchAssessmentReportsList = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, insightsService, reports;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n insightsService = new InsightsService(newToken, oid, tid, '', clientType);\n return [4, insightsService.getAssessmentCsvReportNames()];\n case 2:\n reports = _a.sent();\n if (reports && reports.assessmentFileNames.length > 0) {\n setReportList(reports.assessmentFileNames);\n setTenantName(reports.tenantName);\n setSelectedReport(reports.assessmentFileNames[0].fileName);\n }\n else {\n setLoading(false);\n setFirstLoading(false);\n }\n return [2];\n }\n });\n }); }, []);\n useEffect(function () {\n if (selectedReport) {\n setLoading(true);\n fetchAssessmentReportData(selectedReport);\n }\n }, [selectedReport]);\n var fetchAssessmentReportData = function (fileName) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, insightsService, assessmentsArray, response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n insightsService = new InsightsService(newToken, oid, tid, '', clientType);\n assessmentsArray = [];\n return [4, insightsService.getMetricsCsvReport(fileName)];\n case 2:\n response = _a.sent();\n response.split('\\r\\n').forEach(function (d, i) {\n var propertyArray = d.split(',');\n if (i !== 0 && propertyArray.length >= 12) {\n var item = {\n reportDate: propertyArray[0],\n department: propertyArray[1],\n activityId: propertyArray[2],\n activity: propertyArray[3].replaceAll(/(^\"+|\"+$)/gm, '').trimEnd(),\n skill: propertyArray[4],\n application: propertyArray[5],\n category: propertyArray[6],\n score: propertyArray[7],\n adoptionPercentage: propertyArray[8],\n adoptionTarget: propertyArray[9],\n adoptionScore: propertyArray[10],\n headCount: propertyArray[11],\n };\n assessmentsArray.push(item);\n }\n });\n setReports(assessmentsArray);\n formatRawReportDataToAssessmentsData(assessmentsArray);\n getDepartmentOptions(assessmentsArray);\n return [2];\n }\n });\n }); };\n var formatRawReportDataToAssessmentsData = useCallback(function (report) {\n var formattedAssessments = report.map(function (rawAssessment) {\n return {\n app: rawAssessment.application,\n oid: rawAssessment.activityId,\n action: rawAssessment.activity,\n skill: rawAssessment.skill,\n score: {\n benchmarkRange: [33, 67],\n companyRating: rawAssessment.score && !isNaN(rawAssessment.score) ? Math.round(rawAssessment.score) : 0,\n },\n adoption: {\n companyAverage: rawAssessment.adoptionPercentage && !isNaN(+rawAssessment.adoptionPercentage)\n ? Math.round(parseFloat(rawAssessment.adoptionPercentage))\n : 0,\n industryAverage: rawAssessment.adoptionTarget && !isNaN(+rawAssessment.adoptionTarget)\n ? parseFloat(rawAssessment.adoptionTarget)\n : 0,\n companyScore: rawAssessment.adoptionScore && !isNaN(+rawAssessment.adoptionScore)\n ? parseFloat(rawAssessment.adoptionScore)\n : 0,\n },\n department: rawAssessment.department,\n };\n });\n setAssessments(formattedAssessments);\n }, []);\n var getDepartmentOptions = useCallback(function (assessments) {\n if (!assessments || assessments.length === 0) {\n return [];\n }\n var seenDepartments = new Set();\n var options = [];\n assessments.forEach(function (report) {\n if (!seenDepartments.has(report.department)) {\n seenDepartments.add(report.department);\n options.push(report.department.toString());\n }\n });\n var entireCompanyOption = options.find(function (o) { return o.trim().toLowerCase() === 'entire company'; });\n var presortedCompanyOptions = entireCompanyOption\n ? __spreadArray([entireCompanyOption], __read(options.filter(function (o) { return o.trim().toLowerCase() !== 'entire company'; })), false) : options;\n var companyDepartmentOptions = presortedCompanyOptions\n .sort(function (a, b) {\n if (b.trim().toLowerCase() === 'entire company')\n return 1;\n return a.toLowerCase() < b.toLowerCase() ? -1 : a.toLowerCase() > b.toLowerCase() ? 1 : 0;\n })\n .map(function (option) {\n return {\n name: option,\n oid: option,\n };\n });\n setCompanyDepartmentList(companyDepartmentOptions);\n if (options.length > 0)\n setSelectedCompanyDepartment(options[0]);\n setFirstLoading(false);\n setLoading(false);\n }, [reports]);\n useEffect(function () {\n fetchAssessmentReportsList();\n }, [fetchAssessmentReportsList]);\n var handleSelectedReportChange = useCallback(function (event) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (!event || !event.target.value)\n return [2];\n setSelectedReport(event.target.value);\n return [2];\n });\n }); }, []);\n var handleSelectedCompanyDepartmentChange = useCallback(function (event) { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n setSelectedCompanyDepartment(event.target.value);\n return [2];\n });\n }); }, []);\n var onDownloadReportClick = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, insightsService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!selectedReport) return [3, 3];\n return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n insightsService = new InsightsService(newToken, oid, tid, '', clientType);\n return [4, insightsService.downloadMetricsCsvReport(selectedReport)];\n case 2:\n _a.sent();\n _a.label = 3;\n case 3: return [2];\n }\n });\n }); };\n var reportSelectMemo = useMemo(function () {\n if ((reportList === null || reportList === void 0 ? void 0 : reportList.length) > 0) {\n return (_jsxs(Select, __assign({ className: classes.select, labelId: \"target-time-range-label\", id: \"change-time-range\", value: selectedReport, onChange: handleSelectedReportChange, input: _jsx(BootstrapInput, { onClick: function () { return setReportSelectOpen(function (isOpen) { return !isOpen; }); } }, void 0), open: isReportSelectOpen }, { children: [reportList.slice(0, isReportListExpanded ? reportList.length : 3).map(function (text, index) {\n return (_jsx(MenuItem, __assign({ value: text.fileName }, { children: formatCsvDate(index, text.date, 'metrics') }), text.fileName));\n }), _jsx(TextButton, __assign({ style: { fontSize: 12, marginLeft: 12 }, variant: \"purple\", className: \"reportButton\", onClick: function (e) {\n e.preventDefault();\n e.stopPropagation();\n setReportListExpanded(function (expanded) { return !expanded; });\n } }, { children: isReportListExpanded ? 'See Less' : 'See More' }), void 0)] }), void 0));\n }\n return null;\n }, [\n reportList,\n selectedReport,\n isReportListExpanded,\n handleSelectedReportChange,\n setReportSelectOpen,\n isReportSelectOpen,\n ]);\n var usersNumberMemo = useMemo(function () {\n var _a, _b;\n return ((_b = (_a = reports.find(function (r) {\n return r.department.trim().toLocaleLowerCase() === (selectedCompanyDepartment === null || selectedCompanyDepartment === void 0 ? void 0 : selectedCompanyDepartment.trim().toLowerCase()) &&\n r.headCount !== '';\n })) === null || _a === void 0 ? void 0 : _a.headCount) !== null && _b !== void 0 ? _b : undefined);\n }, [reports, selectedCompanyDepartment]);\n if (isFirstLoading)\n return _jsx(Loading, {}, void 0);\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsxs(\"div\", __assign({ className: classes.configContainer }, { children: [_jsxs(\"div\", __assign({ className: classes.settingsBox }, { children: [reportSelectMemo, (reportList === null || reportList === void 0 ? void 0 : reportList.length) > 0 && (_jsx(Select, __assign({ className: classes.select, labelId: \"target-company-department-label\", id: \"change-company-department\", value: selectedCompanyDepartment, onChange: handleSelectedCompanyDepartmentChange, input: _jsx(BootstrapInput, {}, void 0), disabled: isLoading || isFirstLoading }, { children: companyDepartmentList.map(function (department) { return (_jsx(MenuItem, __assign({ value: department.oid }, { children: department.name }), department.oid)); }) }), void 0))] }), void 0), _jsx(\"div\", __assign({ className: classes.reportActionBox }, { children: _jsx(Button, __assign({ disabled: isLoading || isFirstLoading || !selectedReport, onClick: onDownloadReportClick, style: { width: 200, minWidth: 200 } }, { children: _jsx(\"span\", __assign({ className: classes.downloadReportSpan }, { children: \"Download report\" }), void 0) }), void 0) }), void 0)] }), void 0), usersNumberMemo && (_jsxs(\"div\", __assign({ className: classes.usersNumberBox }, { children: [_jsx(\"span\", __assign({ className: classes.userNumberSpan }, { children: usersNumberMemo }), void 0), \"Users\"] }), void 0)), _jsx(Paper, __assign({ className: classes.paper }, { children: _jsx(TableContainer, { children: _jsx(InsightAssessmentTable, { noReports: reportList.length === 0, isLoading: isLoading, tenantName: tenantName, assessments: selectedCompanyDepartment\n ? assessments.filter(function (assessment) {\n return assessment.department === selectedCompanyDepartment;\n })\n : assessments }, void 0) }, void 0) }), void 0)] }), void 0));\n};\nexport default InsightsAssessments;\n//# sourceMappingURL=InsightsAssessments.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { InsightsTabName } from '../../types/types';\nimport InsightUsers from './Users/InsightUsers';\nimport InsightLicenses from './Licenses/InsightLicenses';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useGetInsightsData } from '../../hooks/useGetInsightsData';\nimport { UserContext } from '../../contexts/UserContext';\nimport InsightUser from './User/InsightUser';\nimport { Pages } from '../../types/enums';\nimport MeasurementBanner from '../MeasurementBanner';\nimport NextLastUpdated from '../NextLastUpdated';\nimport { hasUserRole } from '../../utils/hasUserRole';\nimport { hasManagerRole } from '../../utils/hasManagerRole';\nimport { hasAdminRole } from '../../utils/hasAdminRole';\nimport InsightsHistory from './History/History';\nimport InsightsAssessments from './Assessments/InsightsAssessments';\nvar useStyles = makeStyles(function () { return ({\n root: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n}); });\nvar Insights = function (_a) {\n var page = _a.page;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = useContext(HeaderContext), setTitle = _b.setTitle, setGoBack = _b.setGoBack, setTabs = _b.setTabs, setPage = _b.setPage;\n var _c = __read(useState(false), 2), receivedData = _c[0], setReceivedData = _c[1];\n var getInsightsData = useGetInsightsData();\n var userOnly = hasUserRole(user) && !hasManagerRole(user) && !hasAdminRole(user);\n useEffect(function () {\n setTitle('Insights');\n setGoBack(false);\n setPage(page !== null && page !== void 0 ? page : Pages.InsightsPage);\n userOnly\n ? setTabs(undefined)\n : hasAdminRole(user)\n ? setTabs([\n {\n name: InsightsTabName.Assessment,\n selected: location.pathname === page + \"/assessments\",\n to: page + \"/assessments\",\n },\n {\n name: InsightsTabName.Users,\n selected: location.pathname !== page + \"/outcome-insights\" &&\n location.pathname !== page + \"/licenses-insights\",\n to: page + \"/user-insights\",\n },\n {\n name: InsightsTabName.Licenses,\n selected: location.pathname === page + \"/licenses-insights\" || location.pathname === page + \"/\",\n to: page + \"/licenses-insights\",\n },\n {\n name: InsightsTabName.History,\n selected: location.pathname === page + \"/history-insights\",\n to: page + \"/history-insights\",\n },\n ])\n : hasManagerRole(user) &&\n setTabs([\n {\n name: InsightsTabName.Users,\n selected: location.pathname !== page + \"/outcome-insights\" &&\n location.pathname !== page + \"/licenses-insights\",\n to: page + \"/user-insights\",\n },\n {\n name: InsightsTabName.History,\n selected: location.pathname === page + \"/history-insights\",\n to: page + \"/history-insights\",\n },\n ]);\n }, [location.pathname]);\n useEffect(function () {\n if (!receivedData) {\n getInsightsData();\n setReceivedData(true);\n }\n }, [receivedData, getInsightsData]);\n return (_jsxs(_Fragment, { children: [location.pathname !== page + \"/history-insights\" && location.pathname !== page + \"/assessments\" ? ((user === null || user === void 0 ? void 0 : user.inTwoWeekMeasurement) ? (_jsx(MeasurementBanner, {}, void 0)) : (_jsx(NextLastUpdated, {}, void 0))) : null, _jsx(\"main\", __assign({ className: classes.root }, { children: userOnly ? (_jsx(InsightUser, {}, void 0)) : location.pathname === page + \"/licenses-insights\" ? (_jsx(InsightLicenses, { page: page }, void 0)) :\n location.pathname === page + \"/user-insights\" ? (_jsx(InsightUsers, { page: page }, void 0)) : location.pathname === page + \"/history-insights\" ? (_jsx(InsightsHistory, { page: page }, void 0)) : location.pathname === page + \"/assessments\" && hasAdminRole(user) ? (_jsx(InsightsAssessments, { page: page }, void 0)) : (_jsx(InsightUsers, { page: page }, void 0)) }), void 0)] }, void 0));\n};\nexport default Insights;\n//# sourceMappingURL=Insights.js.map","export var hasUserRole = function (user) { return user !== undefined && user.role.includes('u'); };\n//# sourceMappingURL=hasUserRole.js.map","import { useEffect, useRef } from 'react';\nexport var usePrevious = function (value) {\n var ref = useRef();\n useEffect(function () {\n ref.current = value;\n });\n return ref.current;\n};\n//# sourceMappingURL=usePrevious.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { InputLabel, MenuItem, Select } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useContext, useEffect, useState } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { Level } from '../../../types/enums';\nimport { Colors } from '../../../utils/colors';\nimport Dialog from '../../Dialog';\nimport { OutcomeService } from '../../../services/OutcomeService';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { getToken } from '../../../utils/getToken';\nimport { usePrevious } from '../../../hooks/usePrevious';\nimport { levelToName } from '../../../utils/levelToName';\nvar useStyles = makeStyles({\n targetLevel: {\n display: 'flex',\n alignItems: 'center',\n },\n targetLevelLabel: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n letterSpacing: 2,\n lineHeight: '16px',\n marginRight: 8,\n },\n});\nvar ChangeTargetLevel = function (_a) {\n var skillOrOutcome = _a.skillOrOutcome, getData = _a.getData, noLabel = _a.noLabel, dark = _a.dark, oid = _a.oid, admin = _a.admin, labelId = _a.labelId;\n var classes = useStyles();\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, tid = _c.tid, clientType = _c.clientType;\n var _d = __read(useState(skillOrOutcome.current.targetLevel ? skillOrOutcome.current.targetLevel : Level.None), 2), targetLevel = _d[0], setTargetLevel = _d[1];\n var prevTargetLevel = usePrevious(targetLevel);\n var _e = __read(useState(false), 2), open = _e[0], setOpen = _e[1];\n var _f = __read(useState(''), 2), dialogText = _f[0], setDialogText = _f[1];\n var _g = __read(useState(0), 2), producerCost = _g[0], setProducerCost = _g[1];\n var _h = __read(useState(0), 2), masterCost = _h[0], setMasterCost = _h[1];\n var _j = __read(useState(false), 2), acceptDisabled = _j[0], setAcceptDisabled = _j[1];\n var _k = __read(useState([]), 2), assignableLevels = _k[0], setAssignableLevels = _k[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n useEffect(function () {\n var setUnlockCosts = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, producerCost, masterCost, _a, producerResponse, masterResponse;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _b.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n producerCost = 0;\n masterCost = 0;\n return [4, Promise.all([\n outcomeService.getOutcomeUnlockCost(skillOrOutcome.id, Level.Producer),\n outcomeService.getOutcomeUnlockCost(skillOrOutcome.id, Level.Master),\n ])];\n case 2:\n _a = __read.apply(void 0, [_b.sent(), 2]), producerResponse = _a[0], masterResponse = _a[1];\n if (!producerResponse || !masterResponse) {\n return [2];\n }\n producerCost = producerResponse;\n masterCost = masterResponse;\n setProducerCost(producerCost);\n setMasterCost(masterCost);\n return [2];\n }\n });\n }); };\n if (!targetLevel && skillOrOutcome.current.targetLevel) {\n setTargetLevel(skillOrOutcome.current.targetLevel);\n }\n if ((!producerCost || !masterCost) && !oid) {\n setUnlockCosts();\n }\n }, [\n masterCost,\n producerCost,\n skillOrOutcome,\n targetLevel,\n user,\n oid,\n ApiService,\n instance,\n account,\n ssoToken,\n tid,\n clientType,\n ]);\n useEffect(function () {\n setTargetLevel(skillOrOutcome.current.targetLevel ? skillOrOutcome.current.targetLevel : Level.None);\n }, [skillOrOutcome]);\n useEffect(function () {\n var maxTargetLevel = skillOrOutcome.maxLevel ? skillOrOutcome.maxLevel : Level.None;\n setAssignableLevels(Array.from(Array(maxTargetLevel).keys(), function (_, i) { return i + 1; }));\n }, [skillOrOutcome]);\n if (!user) {\n return null;\n }\n if (!admin) {\n return null;\n }\n var openTargetLevelDialog = function (event) {\n var newTargetLevel = !isNaN(Number(event.target.value)) ? Number(event.target.value) : 0;\n if (skillOrOutcome.current.targetLevel === newTargetLevel) {\n setTargetLevel(skillOrOutcome.current.targetLevel);\n setOpen(false);\n return;\n }\n var producerCostText = newTargetLevel === Level.Producer && producerCost !== 0\n ? \"Making this change will cost you \" + producerCost + \" engagement points. But by completing this target level you will earn your points back!\"\n : '';\n var masterCostText = newTargetLevel === Level.Master && masterCost !== 0\n ? \"Making this change will cost you \" + masterCost + \" engagement points. But by completing this target level you will earn your points back!\"\n : '';\n var costText = newTargetLevel === Level.Producer\n ? producerCostText\n : newTargetLevel === Level.Master\n ? masterCostText\n : '';\n var outcomeLevel = skillOrOutcome.current.targetLevel\n ? levelToName.get(skillOrOutcome.current.targetLevel)\n : '';\n var currentLevel = outcomeLevel ? outcomeLevel : '';\n var selectedLevel = levelToName.get(newTargetLevel);\n var newLevel = selectedLevel ? selectedLevel : '';\n var newDialogText = !oid\n ? \"Your target level will change from \" + currentLevel + \" to \" + newLevel + \". Don't worry, you won't lose your progress if you want to work on this in the future. \" + costText\n : \"The user's target level will change from \" + currentLevel + \" to \" + newLevel + \". Don't worry, they won't lose their progress if they want to work on this in the future.\";\n setAcceptDisabled(false);\n if (selectedLevel === 'Producer' && user.engagementPoints < producerCost) {\n newDialogText = 'You do not have enough engagement points to unlock this level.';\n setAcceptDisabled(true);\n }\n else if (selectedLevel === 'Master' && user.engagementPoints < masterCost) {\n newDialogText = 'You do not have enough engagement points to unlock this level.';\n setAcceptDisabled(true);\n }\n setTargetLevel(newTargetLevel);\n setDialogText(newDialogText !== null && newDialogText !== void 0 ? newDialogText : '');\n setOpen(true);\n };\n var toggleDialog = function () { return setOpen(!open); };\n var cancelChangeTargetLevel = function () {\n if (prevTargetLevel) {\n setTargetLevel(prevTargetLevel);\n }\n toggleDialog();\n };\n var onAccept = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!targetLevel) {\n return [2];\n }\n toggleDialog();\n return [4, ApiService.changeTargetLevel(user, oid, targetLevel, skillOrOutcome.id, 'outcome', false, true)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n return (_jsxs(\"div\", __assign({ className: classes.targetLevel }, { children: [!noLabel && (_jsx(InputLabel, __assign({ id: \"targetLevelLabel\", className: classes.targetLevelLabel }, { children: \"YOUR TARGET LEVEL:\" }), void 0)), _jsx(Select, __assign({ id: \"targetLevel\", labelId: noLabel ? labelId : 'targetLevelLabel', value: targetLevel, onChange: openTargetLevelDialog, disabled: false }, { children: assignableLevels.map(function (item) { return (_jsx(MenuItem, __assign({ value: item }, { children: Level[item] }), item)); }) }), void 0), _jsx(Dialog, { open: open, onClose: cancelChangeTargetLevel, onAccept: acceptDisabled ? cancelChangeTargetLevel : onAccept, title: \"Change Target Level\", text: dialogText, cancelText: acceptDisabled ? undefined : 'No', acceptText: acceptDisabled ? 'Okay' : 'Yes' }, void 0)] }), void 0));\n};\nexport default ChangeTargetLevel;\n//# sourceMappingURL=ChangeTargetLevel.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { InputLabel, makeStyles } from '@material-ui/core';\nimport { useContext, useState } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { CompetenceState } from '../../../types/enums';\nimport { Colors } from '../../../utils/colors';\nimport TextButton from '../../buttons/TextButton';\nimport Dialog from '../../Dialog';\nimport { InsightsMenu } from '../InsightsMenu';\nimport ChangeTargetLevel from './ChangeTargetLevel';\nvar useStyles = makeStyles({\n targetLevelLabel: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n letterSpacing: 2,\n lineHeight: '16px',\n },\n});\nvar OutcomeOptions = function (_a) {\n var outcome = _a.outcome, reportOid = _a.reportOid, getData = _a.getData, unavailable = _a.unavailable, tabIndex = _a.tabIndex;\n var classes = useStyles();\n var _b = __read(useState(false), 2), openRemoveDialog = _b[0], setOpenRemoveDialog = _b[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n if (!user || !outcome) {\n return null;\n }\n var closeRemoveDialog = function () { return setOpenRemoveDialog(false); };\n var toggleRemoveDialog = function () {\n setOpenRemoveDialog(true);\n };\n var remove = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, ApiService.changeTargetLevel(user, reportOid, 0, outcome.id, 'outcome', false, true)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n closeRemoveDialog();\n return [2];\n }\n });\n }); };\n return (_jsxs(_Fragment, { children: [_jsxs(InsightsMenu, __assign({ ariaLabel: \"open outcome menu\", tabIndex: tabIndex }, { children: [!unavailable && (_jsx(TextButton, __assign({ onClick: toggleRemoveDialog, style: { marginBottom: 16, marginLeft: -8 } }, { children: \"REMOVE OUTCOME\" }), void 0)), ![CompetenceState.Locked, CompetenceState.Unassigned].includes(outcome.current.state) && (_jsxs(_Fragment, { children: [_jsx(InputLabel, __assign({ id: \"targetLevelLabel\", className: classes.targetLevelLabel }, { children: \"Change Target Level\" }), void 0), _jsx(ChangeTargetLevel, { labelId: \"targetLevelLabel\", skillOrOutcome: outcome, getData: getData, dark: true, noLabel: true, oid: reportOid, admin: true }, void 0)] }, void 0))] }), void 0), _jsx(Dialog, { open: openRemoveDialog, onAccept: remove, onClose: closeRemoveDialog, title: \"Remove Outcome\", text: \"Remove \" + outcome.name, cancelText: \"Cancel\", acceptText: \"Unassign\" }, void 0)] }, void 0));\n};\nexport default OutcomeOptions;\n//# sourceMappingURL=OutcomeOptions.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { makeStyles, Snackbar, SnackbarContent } from '@material-ui/core';\nimport React, { useContext, useRef, useState } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { CompetenceState, Level, Pages } from '../../../types/enums';\nimport { Colors } from '../../../utils/colors';\nimport SecondaryButton from '../../buttons/SecondaryButton';\nimport Dialog from '../../Dialog';\nimport Loading from '../../Loading';\nimport Outcome from '../../outcomes/Outcome';\nimport OutcomeOptions from './OutcomeOptions';\nimport { isUnassigned } from '../../../utils/isUnassigned';\nimport { isUnavailable } from '../../../utils/isUnavailable';\nimport { isMaintained } from '../../../utils/isMaintained';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n reportOutcome: {},\n top: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n innerOutcome: {\n borderBottom: '1px solid rgba(0,0,0,0.12)',\n },\n outcome: (_a = {\n display: 'flex',\n alignItems: 'center'\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n },\n _a),\n controls: {\n display: 'flex',\n alignItems: 'center',\n },\n statusNormal: {\n height: 12,\n minHeight: 12,\n width: 12,\n minWidth: 12,\n maxWidth: 12,\n borderRadius: '50%',\n backgroundColor: Colors.green,\n },\n statusNotAssigned: {\n height: 12,\n minHeight: 12,\n width: 12,\n minWidth: 12,\n maxWidth: 12,\n borderRadius: '50%',\n backgroundColor: Colors.background,\n },\n statusNeedsAttention: {\n height: 12,\n minHeight: 12,\n width: 12,\n minWidth: 12,\n maxWidth: 12,\n borderRadius: '50%',\n backgroundColor: Colors.red,\n },\n statusContainer: {\n width: 16,\n margin: 'auto',\n marginRight: 20,\n },\n skills: {\n marginRight: 72,\n marginLeft: 48,\n },\n skillsBorder: {\n borderTop: '1px solid rgba(0,0,0,0.12)',\n },\n snackbarRoot: {\n width: '100%',\n },\n snackbar: {\n backgroundColor: '#44346E',\n flexGrow: 1,\n maxWidth: 1024,\n height: 48,\n paddingLeft: 18,\n paddingRight: 40,\n paddingTop: 0,\n paddingBottom: 0,\n boxShadow: '0 1.5px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.16)',\n },\n snackbarButton: {\n color: Colors.white,\n backgroundColor: 'transparent',\n height: 36,\n minHeight: 36,\n maxHeight: 36,\n fontSize: 12,\n letterSpacing: 1,\n fontWeight: 600,\n lineHeight: '12px',\n fontFamily: 'Ubuntu',\n textTransform: 'uppercase',\n boxShadow: 'none',\n cursor: 'pointer',\n border: 0,\n outline: 0,\n },\n snackbarText: {\n color: Colors.white,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '24px',\n },\n select: {\n marginTop: 8,\n },\n label: {\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n marginBottom: 4,\n },\n dialog: {\n height: 98,\n },\n dialogText: {\n color: Colors.textSecondary,\n fontFamily: 'Open Sans',\n fontSize: 14,\n letterSpacing: 0.25,\n lineHeight: '20px',\n },\n button: {\n width: 115,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n color: '#654EA3',\n background: 'white',\n border: 0,\n boxShadow: '0px 1px 4px rgba(0, 0, 0, 0.08), 0px 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n fontWeight: 500,\n lineHeight: '16px',\n padding: '10px 16px',\n letterSpacing: '1.25px',\n },\n actions: (_b = {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n paddingRight: 10\n },\n _b[theme.breakpoints.down('sm')] = {\n paddingRight: 20,\n marginBottom: 16,\n },\n _b[theme.breakpoints.down('xs')] = {\n paddingRight: 10,\n },\n _b),\n });\n});\nvar ReportOutcome = function (_a) {\n var outcome = _a.outcome, oid = _a.oid, getDetail = _a.getDetail, firstCard = _a.firstCard;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = __read(useState(false), 2), sendingHint = _b[0], setSendingHint = _b[1];\n var _c = __read(useState(false), 2), assigning = _c[0], setAssigning = _c[1];\n var _d = __read(useState(false), 2), openOutcome = _d[0], setOpenOutcome = _d[1];\n var sendHintTimeout = useRef();\n var ApiService = useApiService();\n var sendHint = React.useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n setSendingHint(true);\n sendHintTimeout.current = setTimeout(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (sendHintTimeout.current) {\n clearTimeout(sendHintTimeout.current);\n }\n if (!user) return [3, 2];\n return [4, ApiService.sendHint(user, oid, outcome.id)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n _a.label = 2;\n case 2:\n setSendingHint(false);\n return [2];\n }\n });\n }); }, 5000);\n return [2];\n });\n }); }, [ApiService, oid, outcome.id, user]);\n var toggleOutcomeDialog = React.useCallback(function () { return setOpenOutcome(!openOutcome); }, [openOutcome]);\n if (!user) {\n return _jsx(Loading, {}, void 0);\n }\n var undoSendHint = function () {\n setSendingHint(false);\n if (sendHintTimeout.current) {\n clearTimeout(sendHintTimeout.current);\n }\n };\n var assign = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setOpenOutcome(false);\n setAssigning(true);\n return [4, ApiService.changeTargetLevel(user, oid, Level.User, outcome.id, 'outcome', false, true)];\n case 1:\n _a.sent();\n setAssigning(false);\n getDetail();\n return [2];\n }\n });\n }); };\n var unassigned = isUnassigned(outcome.current.state);\n return (_jsxs(_Fragment, { children: [_jsx(\"div\", __assign({ className: classes.reportOutcome }, { children: _jsxs(\"div\", __assign({ className: classes.outcome }, { children: [_jsx(Outcome, { page: Pages.None, outcome: outcome, describedById: outcome.id.toString(), noLink: true }, void 0), _jsxs(\"div\", __assign({ className: classes.actions }, { children: [isUnavailable(outcome.current.state) || isMaintained(outcome.current.state) ? null : (_jsx(SecondaryButton, __assign({ \"aria-describedby\": outcome.id.toString(), style: unassigned ? { width: 115, marginRight: 56 } : { width: 115, marginRight: 32 }, onClick: unassigned ? toggleOutcomeDialog : sendHint, disabled: assigning || sendingHint, tabIndex: firstCard ? 0 : -1 }, { children: unassigned ? 'ASSIGN' : 'SEND HINT' }), void 0)), !unassigned && !isUnavailable(outcome.current.state) && (_jsx(OutcomeOptions, { tabIndex: outcome.current.state === CompetenceState.Maintain && firstCard ? 0 : -1, getData: getDetail, outcome: outcome, reportOid: oid, unavailable: false }, void 0))] }), void 0)] }), void 0) }), void 0), _jsx(Dialog, { open: openOutcome, onClose: toggleOutcomeDialog, onAccept: assign, cancelText: \"Cancel\", acceptText: \"Assign\", title: \"Assign Outcome\", text: \"Do you want to add \" + outcome.name + \" to this user's Outcomes?\" }, void 0), _jsx(Snackbar, __assign({ anchorOrigin: {\n vertical: 'bottom',\n horizontal: 'center',\n }, open: sendingHint, className: classes.snackbarRoot }, { children: _jsx(SnackbarContent, { className: classes.snackbar, message: _jsx(\"span\", __assign({ className: classes.snackbarText }, { children: outcome.name }), void 0), action: [\n _jsx(\"button\", __assign({ onClick: undoSendHint, className: classes.snackbarButton }, { children: \"Undo\" }), 'undoHintButton'),\n ] }, void 0) }), void 0)] }, void 0));\n};\nexport default ReportOutcome;\n//# sourceMappingURL=ReportOutcome.js.map","import { CompetenceState } from '../types/enums';\nexport var isMaintained = function (state) {\n return state === CompetenceState.Maintain;\n};\n//# sourceMappingURL=isMaintained.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Divider, Paper, Typography } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { Colors } from '../../../utils/colors';\nimport { useUUID } from '../../../hooks/useUUID';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport ReportOutcome from './ReportOutcome';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n cardList: {\n listStyle: 'none',\n margin: 'auto',\n padding: 'initial',\n },\n card: {\n background: function (props) {\n return \"linear-gradient(to right, \" + props.color + \" 0, \" + props.color + \" 8px, \" +\n (Colors.white + \" 8px, \" + Colors.white + \" 100%)\");\n },\n backgroundSize: 'cover',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n borderRadius: 4,\n marginTop: 16,\n marginBottom: 16,\n },\n outcomes: {\n width: '100%',\n marginLeft: 24,\n marginBottom: 24,\n },\n title: (_a = {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n marginTop: 24\n },\n _a[theme.breakpoints.down('sm')] = {\n marginTop: 16,\n marginBottom: 25,\n },\n _a),\n });\n});\nvar OutcomesCard = function (_a) {\n var title = _a.title, color = _a.color, outcomes = _a.outcomes, oid = _a.oid, getDetail = _a.getDetail;\n var classes = useStyles({ color: color });\n var id = useUUID();\n var listRef = useRovingTabIndex();\n return (_jsx(Paper, __assign({ elevation: 1, component: \"section\", \"aria-labelledby\": id, className: classes.card }, { children: _jsxs(\"div\", __assign({ className: classes.outcomes }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: _jsx(Typography, __assign({ id: id, variant: \"h6\", component: \"h2\" }, { children: title }), void 0) }), void 0), _jsx(\"ul\", __assign({ ref: listRef, className: classes.cardList }, { children: outcomes.map(function (value, index) { return (_jsxs(\"li\", { children: [_jsx(ReportOutcome, { outcome: value, oid: oid, getDetail: getDetail, firstCard: index === 0 }, value.id), index !== outcomes.length - 1 && _jsx(Divider, { \"aria-hidden\": true }, void 0)] }, value.id)); }) }), void 0)] }), void 0) }), void 0));\n};\nexport default OutcomesCard;\n//# sourceMappingURL=OutcomesCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Typography } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { HeaderContext } from '../../../contexts/HeaderContext';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { Colors } from '../../../utils/colors';\nimport Loading from '../../Loading';\nimport OutcomesCard from './OutcomesCard';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n root: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 480,\n },\n _a[theme.breakpoints.down('xs')] = {\n width: 330,\n },\n _a),\n infoCard: {\n height: 96,\n backgroundColor: Colors.white,\n borderRadius: 4,\n boxShadow: '0px 1px 4px rgba(0, 0, 0, 0.08), 0px 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n infoCardItem: {\n width: '100%',\n height: 64,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n textAlign: 'center',\n },\n infoCardItemTitle: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n },\n });\n});\nvar InsightsDetailsOutcomes = function (_a) {\n var _b, _c, _d;\n var oid = _a.oid, getDetail = _a.getDetail;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _e = useContext(HeaderContext), setTitle = _e.setTitle, setGoBack = _e.setGoBack, setTabs = _e.setTabs;\n var _f = __read(useState(false), 2), didSetData = _f[0], setDidSetData = _f[1];\n var _g = __read(useState(undefined), 2), outcomes = _g[0], setOutcomes = _g[1];\n var ApiService = useApiService();\n var getOutcomes = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightOutcomes(user, oid)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setOutcomes(response.data);\n return [2];\n }\n });\n }); }, [ApiService, oid, user]);\n var update = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getDetail()];\n case 1:\n _a.sent();\n return [4, getOutcomes()];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n useEffect(function () {\n if (!didSetData) {\n setTitle('Insights');\n setGoBack(true);\n setTabs(undefined);\n getOutcomes();\n setDidSetData(true);\n }\n }, [didSetData, getOutcomes, setGoBack, setTabs, setTitle]);\n if (!outcomes) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsxs(\"section\", __assign({ className: classes.infoCard, \"aria-label\": \"Snapshot of outcomes\" }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItem, style: { borderRight: '1px solid rgba(0, 0, 0, 0.12)' } }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItemTitle }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.red } }, void 0), _jsx(Typography, __assign({ component: \"span\", variant: \"h5\", style: { marginLeft: 8 } }, { children: (_b = outcomes === null || outcomes === void 0 ? void 0 : outcomes.needsAttentionOutcomes.length) !== null && _b !== void 0 ? _b : 0 }), void 0)] }), void 0), _jsx(Typography, __assign({ variant: \"body2\" }, { children: \"Need Attention\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.infoCardItem, style: { borderRight: '1px solid rgba(0, 0, 0, 0.12)' } }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItemTitle }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.yellow } }, void 0), _jsx(Typography, __assign({ component: \"span\", variant: \"h5\", style: { marginLeft: 8 } }, { children: (_c = outcomes === null || outcomes === void 0 ? void 0 : outcomes.inProgressOutcomes.length) !== null && _c !== void 0 ? _c : 0 }), void 0)] }), void 0), _jsx(Typography, __assign({ variant: \"body2\" }, { children: \"In Progress\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.infoCardItem }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItemTitle }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.green } }, void 0), _jsx(Typography, __assign({ component: \"span\", variant: \"h5\", style: { marginLeft: 8 } }, { children: (_d = outcomes === null || outcomes === void 0 ? void 0 : outcomes.maintainOutcomes.length) !== null && _d !== void 0 ? _d : 0 }), void 0)] }), void 0), _jsx(Typography, __assign({ variant: \"body2\" }, { children: \"Attained\" }), void 0)] }), void 0)] }), void 0), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.needsAttentionOutcomes) && outcomes.needsAttentionOutcomes.length > 0 && (_jsx(OutcomesCard, { title: \"Need Attention\", color: Colors.red, outcomes: outcomes.needsAttentionOutcomes, oid: oid, getDetail: update }, \"outcomes-need-attention\")), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.inProgressOutcomes) && outcomes.inProgressOutcomes.length > 0 && (_jsx(OutcomesCard, { title: \"In Progress\", color: Colors.yellow, outcomes: outcomes.inProgressOutcomes, oid: oid, getDetail: update }, \"outcomes-in-progress\")), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.maintainOutcomes) && outcomes.maintainOutcomes.length > 0 && (_jsx(OutcomesCard, { title: \"Attained\", color: Colors.green, outcomes: outcomes.maintainOutcomes, oid: oid, getDetail: update }, \"outcomes-maintain\")), (outcomes === null || outcomes === void 0 ? void 0 : outcomes.unassignedOutcome) && outcomes.unassignedOutcome.length > 0 && (_jsx(OutcomesCard, { title: \"Unassigned\", color: Colors.unachievedSkill, outcomes: outcomes.unassignedOutcome, oid: oid, getDetail: update }, \"outcomes-unassigned\"))] }), void 0));\n};\nexport default InsightsDetailsOutcomes;\n//# sourceMappingURL=InsightsDetailsOutcomes.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Divider, Paper, Typography } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport Skill from '../../skills/Skill';\nimport { Colors } from '../../../utils/colors';\nimport { Pages } from '../../../types/enums';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n card: (_a = {\n background: function (props) {\n return \"linear-gradient(to right, \" + props.color + \" 0, \" + props.color + \" 8px, \" +\n (Colors.white + \" 8px, \" + Colors.white + \" 100%)\");\n },\n backgroundSize: 'cover',\n width: 1040,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n borderRadius: 4,\n marginTop: 16,\n marginBottom: 16,\n paddingRight: 24\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 480,\n },\n _a[theme.breakpoints.down('xs')] = {\n width: 330,\n },\n _a),\n outcomes: {\n width: 1040,\n marginLeft: 24,\n marginBottom: 24,\n },\n title: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n marginTop: 24,\n },\n });\n});\nvar SkillsCard = function (_a) {\n var title = _a.title, color = _a.color, skills = _a.skills;\n var classes = useStyles({ color: color });\n return (_jsx(Paper, __assign({ elevation: 1, className: classes.card }, { children: _jsxs(\"div\", __assign({ className: classes.outcomes }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: _jsx(Typography, __assign({ variant: \"h6\" }, { children: title }), void 0) }), void 0), _jsx(\"ul\", __assign({ style: { listStyle: 'none', paddingInlineStart: 0 } }, { children: skills.map(function (value, index) { return (_jsxs(\"li\", { children: [_jsx(Skill, { page: Pages.None, skill: value, describedById: \"skill-\" + value.id, noLink: true }, void 0), index !== skills.length - 1 && _jsx(Divider, {}, void 0)] }, value.id)); }) }), void 0)] }), void 0) }), void 0));\n};\nexport default SkillsCard;\n//# sourceMappingURL=SkillsCard.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { Typography } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport SkillsCard from './SkillsCard';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { HeaderContext } from '../../../contexts/HeaderContext';\nimport { Colors } from '../../../utils/colors';\nimport Loading from '../../Loading';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n root: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 480,\n },\n _a[theme.breakpoints.down('xs')] = {\n width: 330,\n },\n _a),\n infoCard: (_b = {\n width: 1040,\n height: 96,\n backgroundColor: Colors.white,\n borderRadius: 4,\n boxShadow: '0px 1px 4px rgba(0, 0, 0, 0.08), 0px 0.5px 1.5px rgba(0, 0, 0, 0.08)',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-evenly',\n alignItems: 'center'\n },\n _b[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 480,\n },\n _b[theme.breakpoints.down('xs')] = {\n width: 330,\n },\n _b),\n infoCardItem: {\n width: '100%',\n height: 64,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'center',\n textAlign: 'center',\n },\n infoCardItemTitle: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n },\n });\n});\nvar InsightsDetailsSkills = function (_a) {\n var _b, _c, _d;\n var oid = _a.oid;\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _e = useContext(HeaderContext), setTitle = _e.setTitle, setGoBack = _e.setGoBack, setTabs = _e.setTabs;\n var _f = __read(useState(false), 2), didSetData = _f[0], setDidSetData = _f[1];\n var _g = __read(useState(undefined), 2), skills = _g[0], setSkills = _g[1];\n var ApiService = useApiService();\n var getSkills = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightSkills(user, oid)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setSkills(response.data);\n return [2];\n }\n });\n }); }, [ApiService, oid, user]);\n useEffect(function () {\n if (!didSetData) {\n setTitle('Insights');\n setGoBack(true);\n setTabs(undefined);\n getSkills();\n setDidSetData(true);\n }\n }, [didSetData, getSkills, setGoBack, setTabs, setTitle]);\n if (!skills) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCard }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItem, style: { borderRight: '1px solid rgba(0, 0, 0, 0.12)' } }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItemTitle }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.red } }, void 0), _jsx(Typography, __assign({ variant: \"h5\", style: { marginLeft: 8 } }, { children: (_b = skills === null || skills === void 0 ? void 0 : skills.needsImprovement.length) !== null && _b !== void 0 ? _b : 0 }), void 0)] }), void 0), _jsx(Typography, __assign({ variant: \"body2\" }, { children: \"Need Attention\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.infoCardItem, style: { borderRight: '1px solid rgba(0, 0, 0, 0.12)' } }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItemTitle }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.yellow } }, void 0), _jsx(Typography, __assign({ variant: \"h5\", style: { marginLeft: 8 } }, { children: (_c = skills === null || skills === void 0 ? void 0 : skills.inProgress.length) !== null && _c !== void 0 ? _c : 0 }), void 0)] }), void 0), _jsx(Typography, __assign({ variant: \"body2\" }, { children: \"In Progress\" }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.infoCardItem }, { children: [_jsxs(\"div\", __assign({ className: classes.infoCardItemTitle }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.green } }, void 0), _jsx(Typography, __assign({ variant: \"h5\", style: { marginLeft: 8 } }, { children: (_d = skills === null || skills === void 0 ? void 0 : skills.maintain.length) !== null && _d !== void 0 ? _d : 0 }), void 0)] }), void 0), _jsx(Typography, __assign({ variant: \"body2\" }, { children: \"Attained\" }), void 0)] }), void 0)] }), void 0), (skills === null || skills === void 0 ? void 0 : skills.needsImprovement) && skills.needsImprovement.length > 0 && (_jsx(SkillsCard, { title: \"Need Attention\", color: Colors.red, skills: skills.needsImprovement }, \"skills-need-attention\")), (skills === null || skills === void 0 ? void 0 : skills.inProgress) && skills.inProgress.length > 0 && (_jsx(SkillsCard, { title: \"In Progress\", color: Colors.yellow, skills: skills.inProgress }, \"skills-in-progress\")), (skills === null || skills === void 0 ? void 0 : skills.maintain) && skills.maintain.length > 0 && (_jsx(SkillsCard, { title: \"Attained \", color: Colors.green, skills: skills.maintain }, \"skills-maintain\"))] }), void 0));\n};\nexport default InsightsDetailsSkills;\n//# sourceMappingURL=InsightsDetailsSkills.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Avatar } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { HeaderContext } from '../../../contexts/HeaderContext';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { useTypography } from '../../../styles/Typography';\nimport { Colors } from '../../../utils/colors';\nimport DefaultUserImage from '../../DefaultUserImage';\nimport AchievementIcon from '../../icons/AchievementIcon';\nimport BadgeCheckIcon from '../../icons/BadgeCheckIcon';\nimport EngagementPointsIcon from '../../icons/EngagementPointsIcon';\nimport Tabs from '../../Tabs';\nimport InsightsDetailsOutcomes from './InsightsDetailsOutcomes';\nimport InsightsDetailsSkills from './InsightsDetailsSkills';\nimport { useParams } from 'react-router';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n width: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n title: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n name: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n image: {\n width: 48,\n height: 48,\n marginRight: 16,\n },\n avatar: {},\n pills: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-evenly',\n },\n pill: {\n backgroundColor: Colors.white,\n borderRadius: 25,\n padding: 4,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-evenly',\n margin: 4,\n },\n tabs: (_b = {\n height: 56,\n marginTop: 16,\n marginBottom: 16,\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)'\n },\n _b[theme.breakpoints.down('md')] = {\n width: 771,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 480,\n },\n _b[theme.breakpoints.down('xs')] = {\n width: 360,\n },\n _b),\n });\n});\nvar InsightsDetail = function () {\n var typo = useTypography();\n var classes = useStyles();\n var oid = useParams().oid;\n var user = useContext(UserContext).user;\n var _a = useContext(HeaderContext), setTitle = _a.setTitle, setGoBack = _a.setGoBack, setTabs = _a.setTabs;\n var _b = __read(useState('OUTCOMES'), 2), tab = _b[0], setTab = _b[1];\n var _c = __read(useState(false), 2), didSetData = _c[0], setDidSetData = _c[1];\n var _d = __read(useState(undefined), 2), detail = _d[0], setDetail = _d[1];\n var ApiService = useApiService();\n var getImage = useCallback(function (detail) { return __awaiter(void 0, void 0, void 0, function () {\n var response, newDetail;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getUserImages(user, [detail.oid])];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n newDetail = detail;\n if (response.data[0]) {\n newDetail.image = \"data:\" + response.data[0].contentType + \";base64,\" + response.data[0].data;\n }\n setDetail(newDetail);\n return [2];\n }\n });\n }); }, [ApiService, user]);\n var getDetail = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightsDetail(user, oid)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n return [4, getImage(response.data)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); }, [ApiService, getImage, oid, user]);\n useEffect(function () {\n if (!didSetData) {\n setTitle('Back');\n setGoBack(true);\n setTabs(undefined);\n getDetail();\n setDidSetData(true);\n }\n }, [didSetData, getDetail, setGoBack, setTabs, setTitle, tab]);\n var changeTab = function (newTab) {\n setTab(newTab);\n };\n var tabs = [\n {\n name: 'OUTCOMES',\n onClick: function () { return changeTab('OUTCOMES'); },\n selected: tab === 'OUTCOMES',\n },\n {\n name: 'SKILLS',\n onClick: function () { return changeTab('SKILLS'); },\n selected: tab === 'SKILLS',\n },\n ];\n return (_jsx(\"main\", __assign({ className: classes.root }, { children: _jsxs(\"div\", __assign({ className: classes.width }, { children: [_jsxs(\"div\", __assign({ className: classes.title }, { children: [_jsxs(\"div\", __assign({ className: classes.name }, { children: [_jsx(\"div\", __assign({ className: classes.image }, { children: (detail === null || detail === void 0 ? void 0 : detail.image) ? (_jsx(Avatar, { src: detail === null || detail === void 0 ? void 0 : detail.image, className: classes.avatar, imgProps: { loading: 'lazy' } }, void 0)) : (_jsx(DefaultUserImage, { size: 48, fontSize: 40 }, void 0)) }), void 0), _jsxs(\"div\", { children: [_jsx(\"h1\", __assign({ className: typo.h5 }, { children: detail === null || detail === void 0 ? void 0 : detail.displayName }), void 0), _jsx(\"p\", __assign({ className: typo.body2 }, { children: detail === null || detail === void 0 ? void 0 : detail.jobTitle }), void 0)] }, void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.pills }, { children: [_jsxs(\"div\", __assign({ className: classes.pill }, { children: [_jsx(BadgeCheckIcon, { width: 16, height: 16 }, void 0), _jsx(\"span\", __assign({ className: typo.caption, style: { marginLeft: 8 } }, { children: detail === null || detail === void 0 ? void 0 : detail.badgesCount }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.pill }, { children: [_jsx(AchievementIcon, { width: 16, height: 16 }, void 0), _jsx(\"span\", __assign({ className: typo.caption, style: { marginLeft: 8 } }, { children: detail === null || detail === void 0 ? void 0 : detail.achievementsCount }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.pill }, { children: [_jsx(EngagementPointsIcon, { width: 16, height: 16 }, void 0), _jsx(\"span\", __assign({ className: typo.caption, style: { marginLeft: 8 } }, { children: detail === null || detail === void 0 ? void 0 : detail.engagementPoints }), void 0)] }), void 0)] }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.tabs }, { children: _jsx(Tabs, { tabs: tabs, style: { justifyContent: 'flex-start' } }, void 0) }), void 0), _jsx(\"div\", { children: tab === 'OUTCOMES' ? (_jsx(InsightsDetailsOutcomes, { oid: oid, getDetail: getDetail }, void 0)) : (_jsx(InsightsDetailsSkills, { oid: oid }, void 0)) }, void 0)] }), void 0) }), void 0));\n};\nexport default InsightsDetail;\n//# sourceMappingURL=InsightsDetail.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport Toolbar from '@material-ui/core/Toolbar';\nimport { useContext, useEffect, useState } from 'react';\nimport { InsightsOutcomesDetailStatus } from '../../../types/types';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nimport { Colors } from '../../../utils/colors';\nimport Search from '../../Search';\nimport { useTypography } from '../../../styles/Typography';\nvar useStyles = makeStyles(function (theme) { return ({\n root: {\n width: '100%',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n paddingTop: 16,\n },\n items: {\n width: '100%',\n height: 193,\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridTemplateRows: 'repeat(2, 1fr)',\n columnGap: 12,\n listStyle: 'none',\n paddingInlineStart: 0,\n },\n item: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n width: '100%',\n height: 72,\n border: '1px solid rgba(0, 0, 0, 0.12)',\n borderRadius: 4,\n padding: '16px 32px',\n '& > *': {\n marginRight: 12,\n },\n },\n search: {\n width: '100%',\n marginBottom: 16,\n },\n dot: {\n minWidth: 12,\n minHeight: 12,\n width: 12,\n height: 12,\n borderRadius: 25,\n backgroundColor: Colors.unachievedSkill,\n },\n bold: {\n fontWeight: 'bold',\n },\n}); });\nvar OutcomesDetailOutcomeTableToolbar = function (_a) {\n var reports = _a.reports, search = _a.search;\n var typo = useTypography();\n var classes = useStyles();\n var _b = useContext(InsightsContext), searchValue = _b.searchValue, setSearchValue = _b.setSearchValue;\n var _c = __read(useState(0), 2), maintained = _c[0], setMaintained = _c[1];\n var _d = __read(useState(0), 2), needsAttention = _d[0], setNeedsAttention = _d[1];\n var _e = __read(useState(0), 2), unassigned = _e[0], setUnassigned = _e[1];\n var _f = __read(useState(0), 2), inProgress = _f[0], setInProgress = _f[1];\n var onChange = function (event) {\n setSearchValue(event.target.value);\n search(event.target.value);\n };\n useEffect(function () {\n var total = reports.length;\n var newMaintained = 0;\n var newUnassigned = 0;\n var newInProgress = 0;\n var newNeedAttention = 0;\n reports.forEach(function (report) {\n switch (report.status) {\n case InsightsOutcomesDetailStatus.Maintained:\n newMaintained++;\n break;\n case InsightsOutcomesDetailStatus.NotAssigned:\n newUnassigned++;\n break;\n case InsightsOutcomesDetailStatus.InProgress:\n newInProgress++;\n break;\n case InsightsOutcomesDetailStatus.NeedAttention:\n newNeedAttention++;\n break;\n }\n });\n if (total !== 0) {\n setMaintained(Math.round((newMaintained / total) * 100));\n setNeedsAttention(Math.round((newNeedAttention / total) * 100));\n setUnassigned(Math.round((newUnassigned / total) * 100));\n setInProgress(Math.round((newInProgress / total) * 100));\n }\n else {\n setMaintained(0);\n setNeedsAttention(0);\n setUnassigned(0);\n setInProgress(0);\n }\n }, [reports]);\n return (_jsx(Toolbar, { children: _jsxs(\"div\", __assign({ className: classes.root }, { children: [_jsxs(\"ul\", __assign({ className: classes.items }, { children: [_jsxs(\"li\", __assign({ className: classes.item }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.red } }, void 0), _jsxs(\"h3\", __assign({ className: typo.h6 }, { children: [needsAttention, \"%\"] }), void 0), _jsxs(\"p\", __assign({ className: typo.subtitle1 }, { children: [\"of Users \", _jsx(\"strong\", __assign({ className: classes.bold }, { children: \"Need Attention\" }), void 0), \" for this Outcome\"] }), void 0)] }), void 0), _jsxs(\"li\", __assign({ className: classes.item }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.yellow } }, void 0), _jsxs(\"h3\", __assign({ className: typo.h6 }, { children: [inProgress, \"%\"] }), void 0), _jsxs(\"p\", __assign({ className: typo.subtitle2 }, { children: [\"of Users are \", _jsx(\"strong\", __assign({ className: classes.bold }, { children: \"In Progress\" }), void 0), \" for this Outcome\"] }), void 0)] }), void 0), _jsxs(\"li\", __assign({ className: classes.item }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.green } }, void 0), _jsxs(\"h3\", __assign({ className: typo.h6 }, { children: [maintained, \"%\"] }), void 0), _jsxs(\"p\", __assign({ className: typo.subtitle2 }, { children: [\"of Users are \", _jsx(\"strong\", __assign({ className: classes.bold }, { children: \"Maintaining\" }), void 0), \" assigned Target Level\"] }), void 0)] }), void 0), _jsxs(\"li\", __assign({ className: classes.item }, { children: [_jsx(\"div\", { className: classes.dot }, void 0), _jsxs(\"h3\", __assign({ className: typo.h6 }, { children: [unassigned, \"%\"] }), void 0), _jsxs(\"p\", __assign({ className: typo.subtitle2 }, { children: [\"of Users are \", _jsx(\"strong\", __assign({ className: classes.bold }, { children: \"Not Assigned\" }), void 0), \" this outcome\"] }), void 0)] }), void 0)] }), void 0), _jsx(Search, { value: searchValue, onChange: onChange, placeholder: \"Search Users\", className: classes.search, style: { backgroundColor: '#FAFAFA' } }, void 0)] }), void 0) }, void 0));\n};\nexport default OutcomesDetailOutcomeTableToolbar;\n//# sourceMappingURL=OutcomesDetailOutcomeTableToolbar.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport TableHead from '@material-ui/core/TableHead';\nimport TableRow from '@material-ui/core/TableRow';\nimport TableCell from '@material-ui/core/TableCell';\nimport Checkbox from '@material-ui/core/Checkbox';\nimport TableSortLabel from '@material-ui/core/TableSortLabel';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nvar OutcomeDetailOutcomeTableHead = function (_a) {\n var classes = _a.classes, onSelectAllClick = _a.onSelectAllClick, order = _a.order, orderBy = _a.orderBy, numSelected = _a.numSelected, rowCount = _a.rowCount, onRequestSort = _a.onRequestSort;\n var createSortHandler = function (property) { return function (event) {\n onRequestSort(event, property);\n }; };\n var headerRef = useRovingTabIndex();\n return (_jsx(TableHead, __assign({ ref: headerRef }, { children: _jsxs(TableRow, { children: [_jsx(TableCell, __assign({ padding: \"checkbox\" }, { children: _jsx(Checkbox, { indeterminate: numSelected > 0 && numSelected < rowCount, checked: rowCount > 0 && numSelected === rowCount, onChange: onSelectAllClick, inputProps: { 'aria-label': 'select all users' }, tabIndex: -1 }, void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'displayName' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'displayName', direction: order, onClick: createSortHandler('name') }, { children: [\"Display Name\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'displayName'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'level' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'level', direction: order, onClick: createSortHandler('level') }, { children: [\"Target Level\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'level'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'progress' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'progress', direction: order, onClick: createSortHandler('progress') }, { children: [\"Progress Towards Completion\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'progress'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'status' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'status', direction: order, onClick: createSortHandler('status') }, { children: [\"Status\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'status'), _jsx(TableCell, { align: \"left\", padding: 'none', sortDirection: false, \"aria-hidden\": \"true\" }, 'none')] }, void 0) }), void 0));\n};\nexport default OutcomeDetailOutcomeTableHead;\n//# sourceMappingURL=OutcomeDetailOutcomeTableHead.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useContext, useEffect, useState, useMemo } from 'react';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { Colors } from '../../../utils/colors';\nimport { UserContext } from '../../../contexts/UserContext';\nimport Select from '../../select/Select';\nimport { MenuItem } from '@material-ui/core';\nimport Dialog from '../../Dialog';\nimport { Level } from '../../../types/enums';\nimport { OutcomeService } from '../../../services/OutcomeService';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { usePrevious } from '../../../hooks/usePrevious';\nimport { getToken } from '../../../utils/getToken';\nimport { levelToName } from '../../../utils/levelToName';\nimport { levelFilterOptions } from '../../../utils/levelFilterOptions';\nvar useStyles = makeStyles({\n targetLevel: {\n display: 'flex',\n alignItems: 'center',\n },\n targetLevelLabel: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n letterSpacing: 2,\n lineHeight: '16px',\n marginRight: 8,\n },\n});\nvar ChangeTargetLevel = function (_a) {\n var outcomeId = _a.outcomeId, getData = _a.getData, oid = _a.oid, level = _a.level, availableLevelOptions = _a.availableLevelOptions;\n var classes = useStyles();\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, tid = _c.tid, clientType = _c.clientType;\n var _d = __read(useState(level), 2), targetLevel = _d[0], setTargetLevel = _d[1];\n var prevTargetLevel = usePrevious(targetLevel);\n var _e = __read(useState(false), 2), open = _e[0], setOpen = _e[1];\n var _f = __read(useState(''), 2), dialogText = _f[0], setDialogText = _f[1];\n var _g = __read(useState(0), 2), producerCost = _g[0], setProducerCost = _g[1];\n var _h = __read(useState(0), 2), masterCost = _h[0], setMasterCost = _h[1];\n var _j = __read(useState(false), 2), acceptDisabled = _j[0], setAcceptDisabled = _j[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n useEffect(function () {\n var setUnlockCosts = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, producerCost, masterCost, _a, producerResponse, masterResponse;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _b.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n producerCost = 0;\n masterCost = 0;\n return [4, Promise.all([\n outcomeService.getOutcomeUnlockCost(outcomeId, Level.Producer),\n outcomeService.getOutcomeUnlockCost(outcomeId, Level.Master),\n ])];\n case 2:\n _a = __read.apply(void 0, [_b.sent(), 2]), producerResponse = _a[0], masterResponse = _a[1];\n if (!producerResponse || !masterResponse) {\n return [2];\n }\n producerCost = producerResponse;\n masterCost = masterResponse;\n setProducerCost(producerCost);\n setMasterCost(masterCost);\n return [2];\n }\n });\n }); };\n if (!targetLevel) {\n setTargetLevel(Level.User);\n }\n if ((!producerCost || !masterCost) && !oid) {\n setUnlockCosts();\n }\n }, [masterCost, producerCost, targetLevel, user, oid, outcomeId, instance, account, ssoToken, tid, clientType]);\n useEffect(function () {\n setTargetLevel(Level.User);\n }, []);\n var allLevelOptions = useMemo(function () { return levelFilterOptions(); }, []);\n if (!user) {\n return null;\n }\n var openTargetLevelDialog = function (event) {\n var newTargetLevel = !isNaN(Number(event.target.value)) ? Number(event.target.value) : 0;\n var newDialogText = '';\n var selectedLevel = levelToName.get(newTargetLevel);\n setAcceptDisabled(false);\n if (selectedLevel === 'Producer' && user.engagementPoints < producerCost) {\n newDialogText = 'Not enought ep';\n setAcceptDisabled(true);\n }\n else if (selectedLevel === 'Master' && user.engagementPoints < masterCost) {\n newDialogText = 'Not enought ep';\n setAcceptDisabled(true);\n }\n setTargetLevel(newTargetLevel);\n setDialogText(newDialogText !== null && newDialogText !== void 0 ? newDialogText : '');\n setOpen(true);\n };\n var toggleDialog = function () { return setOpen(!open); };\n var cancelChangeTargetLevel = function () {\n if (prevTargetLevel) {\n setTargetLevel(prevTargetLevel);\n }\n toggleDialog();\n };\n var onAccept = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!targetLevel) {\n return [2];\n }\n toggleDialog();\n return [4, ApiService.changeTargetLevel(user, oid ? oid : user.oid, targetLevel, outcomeId, 'outcome', false, true)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n return (_jsxs(\"div\", __assign({ className: classes.targetLevel }, { children: [_jsx(Select, __assign({ value: targetLevel, onChange: openTargetLevelDialog, light: false }, { children: availableLevelOptions\n ? availableLevelOptions\n .filter(function (levelOption) { return levelOption && levelOption < 4 && levelOption > 0; })\n .map(function (levelOption) {\n if (levelOption === Level.User)\n return (_jsx(MenuItem, __assign({ value: Level.User }, { children: \"User\" }), Level.User));\n if (levelOption === Level.Producer)\n return (_jsx(MenuItem, __assign({ value: Level.Producer }, { children: \"Producer\" }), Level.Producer));\n if (levelOption === Level.Master)\n return (_jsx(MenuItem, __assign({ value: Level.Master }, { children: \"Master\" }), Level.Master));\n })\n : allLevelOptions\n .filter(function (levelOption) { return levelOption.key; })\n .map(function (levelOption) { return (_jsx(MenuItem, __assign({ value: levelOption.value }, { children: levelOption.text }), levelOption.key)); }) }), void 0), _jsx(Dialog, { open: open, onClose: cancelChangeTargetLevel, onAccept: acceptDisabled ? cancelChangeTargetLevel : onAccept, title: \"Change target level\", text: dialogText, cancelText: acceptDisabled ? undefined : 'No', acceptText: acceptDisabled ? 'Okay' : 'Yes' }, void 0)] }), void 0));\n};\nexport default ChangeTargetLevel;\n//# sourceMappingURL=ChangeTargetLevel.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { makeStyles } from '@material-ui/core';\nimport { useContext, useState } from 'react';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { InsightsOutcomesDetailStatus } from '../../../types/types';\nimport { Colors } from '../../../utils/colors';\nimport TextButton from '../../buttons/TextButton';\nimport Dialog from '../../Dialog';\nimport { InsightsMenu } from '../InsightsMenu';\nimport ChangeTargetLevel from './ChangeTargetLevel';\nvar useStyles = makeStyles({\n targetLevelLabel: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n letterSpacing: 2,\n lineHeight: '16px',\n },\n});\nvar OutcomeOptions = function (_a) {\n var outcomeId = _a.outcomeId, reportOid = _a.reportOid, getData = _a.getData, unavailable = _a.unavailable, level = _a.level, status = _a.status, availableLevelOptions = _a.availableLevelOptions;\n var classes = useStyles();\n var _b = __read(useState(false), 2), openRemoveDialog = _b[0], setOpenRemoveDialog = _b[1];\n var user = useContext(UserContext).user;\n var ApiService = useApiService();\n if (!user) {\n return null;\n }\n var closeRemoveDialog = function () { return setOpenRemoveDialog(false); };\n var toggleRemoveDialog = function () {\n setOpenRemoveDialog(true);\n };\n var remove = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, ApiService.changeTargetLevel(user, reportOid, 0, outcomeId, 'outcome', false, true)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n closeRemoveDialog();\n return [2];\n }\n });\n }); };\n var addUserLevel = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, ApiService.changeTargetLevel(user, reportOid, 1, outcomeId, 'outcome', false, true)];\n case 1:\n _a.sent();\n return [4, getData()];\n case 2:\n _a.sent();\n closeRemoveDialog();\n return [2];\n }\n });\n }); };\n return (_jsxs(_Fragment, { children: [_jsxs(InsightsMenu, __assign({ ariaLabel: \"Open outcome options\" }, { children: [!unavailable && (_jsx(TextButton, __assign({ onClick: toggleRemoveDialog, style: { marginBottom: 16, marginLeft: -8 } }, { children: status !== InsightsOutcomesDetailStatus.NotAssigned ? 'REMOVE OUTCOME' : 'ASSIGN OUTCOME' }), void 0)), _jsx(\"div\", __assign({ className: classes.targetLevelLabel }, { children: \"Change Target Level\" }), void 0), _jsx(ChangeTargetLevel, { outcomeId: outcomeId, getData: getData, oid: reportOid, level: level, availableLevelOptions: availableLevelOptions }, void 0)] }), void 0), _jsx(Dialog, { open: openRemoveDialog, onAccept: remove, onClose: closeRemoveDialog, title: \"Remove Outcome\", text: \"Change Target Level\", cancelText: \"Cancel\", acceptText: \"Unassign\" }, void 0), status !== InsightsOutcomesDetailStatus.NotAssigned ? (_jsx(Dialog, { open: openRemoveDialog, onAccept: remove, onClose: closeRemoveDialog, title: \"Remove Outcome\", text: \"Change Target Level\", cancelText: \"Cancel\", acceptText: \"Unassign\" }, void 0)) : (_jsx(Dialog, { open: openRemoveDialog, onAccept: addUserLevel, onClose: closeRemoveDialog, title: \"Assign Outcome\", text: \"Change Target Level\", cancelText: \"Cancel\", acceptText: \"Assign\" }, void 0))] }, void 0));\n};\nexport default OutcomeOptions;\n//# sourceMappingURL=OutcomeOptions.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { UserContext } from '../../contexts/UserContext';\nimport Dialog from '../Dialog';\nimport Select from '../select/Select';\nimport { MenuItem } from '@material-ui/core';\nimport { useHistory } from 'react-router-dom';\nvar useStyles = makeStyles({\n select: {\n marginTop: 8,\n },\n label: {\n fontWeight: 600,\n fontFamily: 'Ubuntu',\n marginBottom: 4,\n },\n dialog: {},\n});\nvar targetLevels = [\n {\n name: 'User',\n value: 1,\n },\n {\n name: 'Producer',\n value: 2,\n },\n {\n name: 'Master',\n value: 3,\n },\n];\nvar BulkAssignOutcomeDialog = function (_a) {\n var page = _a.page, open = _a.open, onClose = _a.onClose, reports = _a.reports, outcomeId = _a.outcomeId;\n var classes = useStyles();\n var _b = __read(useState(false), 2), disableButton = _b[0], setDisableButton = _b[1];\n var user = useContext(UserContext).user;\n var _c = __read(useState(1), 2), targetLevel = _c[0], setTargetLevel = _c[1];\n var _d = __read(useState(false), 2), targetLevelError = _d[0], setTargetLevelError = _d[1];\n var ApiService = useApiService();\n var history = useHistory();\n var selectTargetLevel = function (event) {\n setTargetLevelError(false);\n setTargetLevel(Number(event.target.value));\n };\n var assignOutcome = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n setDisableButton(true);\n if (!outcomeId) return [3, 2];\n return [4, ApiService.bulkOutcomeAssign(user, reports, [{ id: outcomeId, level: targetLevel }])];\n case 1:\n _a.sent();\n _a.label = 2;\n case 2:\n onClose();\n setDisableButton(false);\n history.push(page + \"/history-insights\");\n return [2];\n }\n });\n }); };\n return (_jsx(Dialog, { open: open, onClose: onClose, onAccept: assignOutcome, cancelText: \"Cancel\", acceptText: \"Assign\", title: \"Bulk Assign Outcome\", content: _jsxs(\"div\", __assign({ className: classes.dialog, style: { height: 96 } }, { children: [_jsx(\"div\", __assign({ className: classes.label }, { children: \"Target Level\" }), void 0), _jsx(Select, __assign({ value: targetLevel, onChange: selectTargetLevel, style: { width: '100%' }, error: targetLevelError }, { children: targetLevels.map(function (l) { return (_jsx(MenuItem, __assign({ value: l.value }, { children: l.name }), l.name)); }) }), void 0)] }), void 0), disabled: disableButton, cancelDisabled: disableButton }, void 0));\n};\nexport default BulkAssignOutcomeDialog;\n//# sourceMappingURL=BulkAssignOutcomeDialog.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext, useState } from 'react';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport Table from '@material-ui/core/Table';\nimport TableBody from '@material-ui/core/TableBody';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableContainer from '@material-ui/core/TableContainer';\nimport TableRow from '@material-ui/core/TableRow';\nimport Checkbox from '@material-ui/core/Checkbox';\nimport { InsightsOutcomesDetailStatus } from '../../../types/types';\nimport OutcomesDetailOutcomeTableToolbar from './OutcomesDetailOutcomeTableToolbar';\nimport OutcomeDetailOutcomeTableHead from './OutcomeDetailOutcomeTableHead';\nimport { Avatar, Paper, useMediaQuery } from '@material-ui/core';\nimport clsx from 'clsx';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nimport OutcomeOptions from './OutcomeOptions';\nimport TextButton from '../../buttons/TextButton';\nimport LevelIcon from '../../LevelIcon';\nimport { Colors } from '../../../utils/colors';\nimport BulkUnassignOutcomeDialog from '../../bulk/BulkUnassignOutcomeDialog';\nimport BulkAssignOutcomeDialog from '../../bulk/BulkAssignOutcomeDialog';\nimport { useTypography } from '../../../styles/Typography';\nimport DefaultUserImage from '../../DefaultUserImage';\nimport Loading from '../../Loading';\nimport { CompetenceState, Level } from '../../../types/enums';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport { ChevronDown, ChevronUp } from 'react-feather';\nimport { stableSort } from '../../../utils/stableSort';\nimport { getComparator } from '../../../utils/getComparator';\nvar useStyles = makeStyles(function (theme) { return ({\n root: {\n width: '100%',\n backgroundColor: Colors.white,\n borderRadius: 4,\n },\n paper: {\n width: '100%',\n marginBottom: theme.spacing(2),\n },\n table: {},\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n icon: {\n width: 20,\n height: 20,\n marginRight: 8,\n },\n image: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n margin: 'auto',\n },\n avatar: {\n height: 24,\n width: 24,\n minHeight: 24,\n minWidth: 24,\n },\n mobileToolbar: {\n height: 42,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n },\n mobileButton: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n mobileOutcome: {\n height: 108,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n },\n evenBackground: {\n backgroundColor: '#fafafa',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n mobileImage: {\n height: 24,\n width: 24,\n margin: '0px 6px',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n margin: '0px 4px',\n },\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridTemplateRows: 'repeat(3, 1fr)',\n },\n context: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n padding: '12px 24px',\n },\n contextButtons: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n },\n label: {\n '&:hover .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n '&:focus .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n },\n}); });\nvar OutcomesDetailOutcomesTable = function (_a) {\n var page = _a.page, outcomeId = _a.outcomeId, reports = _a.reports, getReports = _a.getReports, search = _a.search;\n var typo = useTypography();\n var classes = useStyles();\n var _b = useContext(InsightsContext), setReports = _b.setReports, availableLevelOptions = _b.availableLevelOptions;\n var _c = __read(useState('asc'), 2), order = _c[0], setOrder = _c[1];\n var _d = __read(useState('name'), 2), orderBy = _d[0], setOrderBy = _d[1];\n var _e = __read(useState([]), 2), selected = _e[0], setSelected = _e[1];\n var _f = __read(useState(false), 2), bulkUnassignOpen = _f[0], setBulkUnassignOpen = _f[1];\n var _g = __read(useState(false), 2), bulkAssignOpen = _g[0], setBulkAssignOpen = _g[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var userRef = useRovingTabIndex();\n var handleRequestSort = function (event, property) {\n var isAsc = orderBy === property && order === 'asc';\n setOrder(isAsc ? 'desc' : 'asc');\n setOrderBy(property);\n };\n var handleSelectAllClick = function (event) {\n if (event.target.checked) {\n var newSelecteds = reports === null || reports === void 0 ? void 0 : reports.map(function (n) { return n.oid; });\n setSelected(newSelecteds !== null && newSelecteds !== void 0 ? newSelecteds : []);\n return;\n }\n setSelected([]);\n };\n var handleClick = function (event, oid) {\n var selectedIndex = selected.indexOf(oid);\n var newSelected = [];\n if (selectedIndex === -1) {\n newSelected = newSelected.concat(selected, oid);\n }\n else if (selectedIndex === 0) {\n newSelected = newSelected.concat(selected.slice(1));\n }\n else if (selectedIndex === selected.length - 1) {\n newSelected = newSelected.concat(selected.slice(0, -1));\n }\n else if (selectedIndex > 0) {\n newSelected = newSelected.concat(selected.slice(0, selectedIndex), selected.slice(selectedIndex + 1));\n }\n setSelected(newSelected);\n };\n var isSelected = function (oid) { return selected.indexOf(oid) !== -1; };\n var bulkAssignOutcomes = function () {\n setReports(selected);\n toggleBulkAssignDialog();\n };\n var bulkUnassignOutcomes = function () {\n setReports(selected);\n toggleBulkUnassignDialog();\n };\n var toggleBulkUnassignDialog = function () { return setBulkUnassignOpen(!bulkUnassignOpen); };\n var toggleBulkAssignDialog = function () { return setBulkAssignOpen(!bulkAssignOpen); };\n var cancel = function () {\n setSelected([]);\n };\n var getCompetenceStateByStatus = function (status) {\n switch (status) {\n case InsightsOutcomesDetailStatus.NotAssigned: {\n return CompetenceState.Unassigned;\n }\n case InsightsOutcomesDetailStatus.InProgress: {\n return CompetenceState.InProgress;\n }\n case InsightsOutcomesDetailStatus.Maintained: {\n return CompetenceState.Maintain;\n }\n case InsightsOutcomesDetailStatus.NeedAttention: {\n return CompetenceState.NeedsAttention;\n }\n default: {\n return CompetenceState.Unassigned;\n }\n }\n };\n if (!reports) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [!isSmDown ? (_jsxs(Paper, __assign({ elevation: 1, className: classes.paper }, { children: [_jsx(OutcomesDetailOutcomeTableToolbar, { reports: reports, search: search }, void 0), _jsx(\"section\", { children: selected.length > 0 && (_jsxs(\"div\", __assign({ className: classes.context }, { children: [_jsxs(\"div\", __assign({ className: classes.contextButtons }, { children: [_jsxs(\"p\", __assign({ className: typo.caption, style: { marginRight: 16 } }, { children: [selected.length, \" Selected\"] }), void 0), _jsx(TextButton, __assign({ onClick: bulkAssignOutcomes, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Assign Outcome\" }), void 0), _jsx(TextButton, __assign({ onClick: bulkUnassignOutcomes, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Unassign Outcome\" }), void 0)] }), void 0), _jsx(TextButton, __assign({ onClick: cancel, style: { color: Colors.purple, fontSize: 10 } }, { children: \"Cancel\" }), void 0)] }), void 0)) }, void 0), _jsx(TableContainer, { children: _jsxs(Table, __assign({ className: classes.table, size: 'medium', \"aria-label\": \"enhanced table\" }, { children: [_jsx(OutcomeDetailOutcomeTableHead, { classes: classes, numSelected: selected.length, order: order, orderBy: orderBy, onSelectAllClick: handleSelectAllClick, onRequestSort: handleRequestSort, rowCount: reports.length }, void 0), _jsx(TableBody, __assign({ ref: userRef }, { children: stableSort(reports, getComparator(order, orderBy)).map(function (row, index) {\n var isItemSelected = isSelected(row.oid);\n var labelId = \"users-\" + row.oid;\n return (_jsxs(TableRow, __assign({ hover: true, tabIndex: -1, selected: isItemSelected }, { children: [_jsx(TableCell, __assign({ padding: \"checkbox\" }, { children: _jsx(Checkbox, { role: \"checkbox\", \"aria-checked\": isItemSelected, onClick: function (event) { return handleClick(event, row.oid); }, checked: isItemSelected, inputProps: { 'aria-labelledby': labelId } }, void 0) }), void 0), _jsx(TableCell, __assign({ component: \"th\", id: labelId, scope: \"row\", padding: \"none\" }, { children: _jsxs(\"div\", __assign({ style: {\n width: isMdDown ? 150 : 225,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(\"div\", __assign({ style: { marginRight: 8 } }, { children: row.image ? (_jsx(Avatar, { src: row.image, className: classes.avatar, imgProps: { loading: 'lazy' } }, void 0)) : (_jsx(DefaultUserImage, { size: 24, fontSize: 20 }, void 0)) }), void 0), row.name] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(LevelIcon, { progress: row.progress, level: row.level, state: getCompetenceStateByStatus(row.status), type: \"outcome\" }, void 0), _jsx(\"div\", { style: { width: 4 } }, void 0), row.level === Level.User\n ? 'User'\n : row.level === Level.Producer\n ? 'Producer'\n : row.level === Level.Master\n ? 'Master'\n : 'None'] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(\"div\", { className: classes.dot, style: row.progress < 34\n ? { backgroundColor: Colors.low }\n : row.progress < 75\n ? { backgroundColor: Colors.moderate }\n : row.progress < 100\n ? { backgroundColor: Colors.high }\n : { backgroundColor: Colors.green } }, void 0), row.progress, \"%\"] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: _jsxs(\"div\", __assign({ style: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n } }, { children: [_jsx(\"div\", { className: classes.dot, style: row.status === InsightsOutcomesDetailStatus.NeedAttention\n ? { backgroundColor: Colors.red }\n : row.status === InsightsOutcomesDetailStatus.InProgress\n ? { backgroundColor: Colors.yellow }\n : row.status === InsightsOutcomesDetailStatus.Maintained\n ? { backgroundColor: Colors.green }\n : { backgroundColor: Colors.unachievedSkill } }, void 0), row.status === InsightsOutcomesDetailStatus.NeedAttention\n ? 'Need Attention'\n : row.status === InsightsOutcomesDetailStatus.InProgress\n ? 'In Progress'\n : row.status === InsightsOutcomesDetailStatus.Maintained\n ? 'Maintained'\n : 'Not Assigned'] }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"right\" }, { children: _jsx(OutcomeOptions, { getData: getReports, outcomeId: outcomeId, reportOid: row.oid, unavailable: false, level: row.level, status: row.status, availableLevelOptions: availableLevelOptions }, void 0) }), void 0)] }), row.oid + index));\n }) }), void 0)] }), void 0) }, void 0)] }), void 0)) : (_jsxs(_Fragment, { children: [_jsx(\"section\", { children: selected.length > 0 && (_jsxs(\"div\", __assign({ className: classes.context }, { children: [_jsxs(\"div\", __assign({ className: classes.contextButtons }, { children: [_jsxs(\"p\", __assign({ className: typo.caption, style: { marginRight: 16 } }, { children: [selected.length, \" Selected\"] }), void 0), _jsx(TextButton, __assign({ onClick: bulkAssignOutcomes }, { children: \"Assign Outcome\" }), void 0), _jsx(TextButton, __assign({ onClick: bulkUnassignOutcomes }, { children: \"Unassign Outcome\" }), void 0)] }), void 0), _jsx(TextButton, __assign({ onClick: cancel }, { children: \"Cancel\" }), void 0)] }), void 0)) }, void 0), _jsxs(Paper, __assign({ elevation: 1, className: classes.paper }, { children: [_jsx(\"div\", __assign({ className: classes.mobileToolbar }, { children: _jsxs(\"div\", __assign({ className: classes.mobileButton }, { children: [_jsx(\"h3\", __assign({ className: typo.body1 }, { children: \"Display Name\" }), void 0), _jsx(\"button\", __assign({ style: { background: 'none', border: 'none' }, onClick: function (event) { return handleRequestSort(event, 'name'); } }, { children: order === 'asc' ? _jsx(ChevronDown, {}, void 0) : _jsx(ChevronUp, {}, void 0) }), void 0)] }), void 0) }), void 0), _jsx(\"ul\", __assign({ ref: userRef, style: { listStyle: 'none', paddingInlineStart: 0 } }, { children: stableSort(reports, getComparator(order, orderBy)).map(function (row, index) {\n var isItemSelected = isSelected(row.oid);\n var labelId = \"users-\" + index;\n return (_jsxs(\"li\", __assign({ className: clsx(classes.mobileOutcome, index % 2 === 0 && classes.evenBackground) }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'space-between' } }, { children: [_jsxs(\"div\", __assign({ className: classes.row, style: { justifyContent: 'flex-start' } }, { children: [_jsx(Checkbox, { onClick: function (event) { return handleClick(event, row.oid); }, checked: isItemSelected, inputProps: { 'aria-labelledby': labelId }, tabIndex: index === 0 ? 0 : -1 }, void 0), row.image ? (_jsx(Avatar, { src: row.image, className: classes.avatar, imgProps: { loading: 'lazy' } }, void 0)) : (_jsx(DefaultUserImage, { size: 24, fontSize: 20 }, void 0)), _jsx(\"p\", __assign({ id: labelId, className: typo.subtitle1, style: { marginLeft: 8 } }, { children: row.name }), void 0)] }), void 0), _jsx(OutcomeOptions, { getData: getReports, outcomeId: outcomeId, reportOid: row.oid, unavailable: false, level: row.level, status: row.status, availableLevelOptions: availableLevelOptions }, void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Target Level\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.yellow } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.level }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Progress\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.high } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.progress }), void 0)] }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Status\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.yellow } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.status }), void 0)] }), void 0)] }), void 0)] }), row.oid));\n }) }), void 0)] }), void 0)] }, void 0)), _jsx(BulkUnassignOutcomeDialog, { page: page, onClose: toggleBulkUnassignDialog, open: bulkUnassignOpen, reports: selected, outcomeId: outcomeId }, void 0), _jsx(BulkAssignOutcomeDialog, { page: page, onClose: toggleBulkAssignDialog, open: bulkAssignOpen, reports: selected, outcomeId: outcomeId }, void 0)] }), void 0));\n};\nexport default OutcomesDetailOutcomesTable;\n//# sourceMappingURL=OutcomesDetailOutcomesTable.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport TableHead from '@material-ui/core/TableHead';\nimport TableRow from '@material-ui/core/TableRow';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableSortLabel from '@material-ui/core/TableSortLabel';\nimport { Tooltip } from '../../Tooltip';\nimport { Colors } from '../../../utils/colors';\nimport { useRovingTabIndex } from '../../../hooks/useRovingTabIndex';\nimport { Info } from 'react-feather';\nvar OutcomeDetailSkillsTableHead = function (_a) {\n var classes = _a.classes, order = _a.order, orderBy = _a.orderBy, onRequestSort = _a.onRequestSort;\n var createSortHandler = function (property) { return function (event) {\n onRequestSort(event, property);\n }; };\n var headerRef = useRovingTabIndex();\n return (_jsx(TableHead, __assign({ ref: headerRef }, { children: _jsxs(TableRow, { children: [_jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'name' ? order : false, style: { paddingLeft: 16 } }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'name', direction: order, onClick: createSortHandler('name') }, { children: [\"Skill Name\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'name'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'assigned' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'assigned', direction: order, onClick: createSortHandler('assigned') }, { children: [_jsxs(\"span\", __assign({ style: { display: 'flex', flexDirection: 'row', alignItems: 'center' } }, { children: [\"# Assigned\", _jsx(Tooltip, __assign({ title: \"Certain team members may be assigned specific Skills based on their role within the organization\" }, { children: _jsx(Info, { style: { width: 16, height: 16 } }, void 0) }), void 0)] }), void 0), _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'assigned'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'low' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'low', direction: order, onClick: createSortHandler('low') }, { children: [_jsx(Tooltip, __assign({ title: \"Users who have completed 0-33% of this Outcome\" }, { children: _jsx(\"span\", { style: {\n width: 12,\n height: 12,\n backgroundColor: Colors.low,\n borderRadius: 25,\n marginRight: 4,\n } }, void 0) }), void 0), \"Low\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'low'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'moderate' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'moderate', direction: order, onClick: createSortHandler('moderate') }, { children: [_jsx(Tooltip, __assign({ title: \"Users who have completed 34-75% of this Outcome\" }, { children: _jsx(\"span\", { style: {\n width: 12,\n height: 12,\n backgroundColor: Colors.moderate,\n borderRadius: 25,\n marginRight: 4,\n } }, void 0) }), void 0), \"Moderate\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'moderate'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'high' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'high', direction: order, onClick: createSortHandler('high') }, { children: [_jsx(Tooltip, __assign({ title: \"Users who have completed 76-99% of this Outcome\" }, { children: _jsx(\"span\", { style: {\n width: 12,\n height: 12,\n backgroundColor: Colors.high,\n borderRadius: 25,\n marginRight: 4,\n } }, void 0) }), void 0), \"High\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'high'), _jsx(TableCell, __assign({ align: \"left\", padding: 'none', sortDirection: orderBy === 'maintained' ? order : false }, { children: _jsxs(TableSortLabel, __assign({ className: classes.label, active: orderBy === 'maintained', direction: order, onClick: createSortHandler('maintained') }, { children: [_jsx(Tooltip, __assign({ title: \"Users who have completed this Outcome and are maintaining it\" }, { children: _jsx(\"span\", { style: {\n width: 12,\n height: 12,\n backgroundColor: Colors.green,\n borderRadius: 25,\n marginRight: 4,\n } }, void 0) }), void 0), \"Maintained\", _jsx(\"span\", __assign({ className: classes.visuallyHidden }, { children: order === 'desc' ? 'sorted descending' : 'sorted ascending' }), void 0)] }), void 0) }), 'maintained')] }, void 0) }), void 0));\n};\nexport default OutcomeDetailSkillsTableHead;\n//# sourceMappingURL=OutcomeDetailSkillsTableHead.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useState } from 'react';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport Table from '@material-ui/core/Table';\nimport TableBody from '@material-ui/core/TableBody';\nimport TableContainer from '@material-ui/core/TableContainer';\nimport { IconButton, Paper, useMediaQuery } from '@material-ui/core';\nimport clsx from 'clsx';\nimport OutcomeDetailSkillsTableHead from './OutcomeDetailSkillsTableHead';\nimport TableCell from '@material-ui/core/TableCell';\nimport TableRow from '@material-ui/core/TableRow';\nimport { Colors } from '../../../utils/colors';\nimport { useTypography } from '../../../styles/Typography';\nimport Loading from '../../Loading';\nimport { ChevronDown, ChevronUp, Filter } from 'react-feather';\nimport { stableSort } from '../../../utils/stableSort';\nimport { getComparator } from '../../../utils/getComparator';\nvar useStyles = makeStyles(function (theme) { return ({\n root: {\n width: '100%',\n backgroundColor: Colors.white,\n borderRadius: 4,\n },\n paper: {\n width: '100%',\n marginBottom: theme.spacing(2),\n },\n table: {},\n visuallyHidden: {\n border: 0,\n clip: 'rect(0 0 0 0)',\n height: 1,\n margin: -1,\n overflow: 'hidden',\n padding: 0,\n position: 'absolute',\n top: 20,\n width: 1,\n },\n icon: {\n width: 20,\n height: 20,\n marginRight: 8,\n },\n image: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n margin: 'auto',\n },\n avatar: {\n height: 24,\n width: 24,\n minHeight: 24,\n minWidth: 24,\n },\n mobileToolbar: {\n height: 42,\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)',\n },\n mobileButton: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n mobileOutcome: {\n height: 108,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'center',\n },\n evenBackground: {\n backgroundColor: '#fafafa',\n },\n row: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n mobileImage: {\n height: 24,\n width: 24,\n margin: '0px 6px',\n },\n dot: {\n width: 12,\n height: 12,\n borderRadius: 25,\n margin: '0px 4px',\n },\n grid: {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gridTemplateRows: 'repeat(3, 1fr)',\n },\n label: {\n '&:hover .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n '&:focus .MuiTableSortLabel-icon': {\n opacity: 0.8,\n },\n },\n}); });\nvar OutcomesDetailSkillsTable = function (_a) {\n var rows = _a.rows, openFilters = _a.openFilters;\n var typo = useTypography();\n var classes = useStyles();\n var _b = __read(useState('asc'), 2), order = _b[0], setOrder = _b[1];\n var _c = __read(useState('name'), 2), orderBy = _c[0], setOrderBy = _c[1];\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var handleRequestSort = function (event, property) {\n var isAsc = orderBy === property && order === 'asc';\n setOrder(isAsc ? 'desc' : 'asc');\n setOrderBy(property);\n };\n if (!rows) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsx(\"div\", __assign({ className: classes.root }, { children: !isSmDown ? (_jsx(Paper, __assign({ elevation: 1, className: classes.paper }, { children: _jsx(TableContainer, { children: _jsxs(Table, __assign({ className: classes.table, size: 'medium', \"aria-label\": \"enhanced table\" }, { children: [_jsx(OutcomeDetailSkillsTableHead, { classes: classes, order: order, orderBy: orderBy, onRequestSort: handleRequestSort }, void 0), _jsx(TableBody, { children: stableSort(rows, getComparator(order, orderBy)).map(function (row) {\n return (_jsxs(TableRow, __assign({ tabIndex: -1 }, { children: [_jsx(TableCell, __assign({ component: \"th\", scope: \"row\", style: { paddingLeft: 16 } }, { children: _jsx(\"div\", __assign({ style: { marginTop: 16, marginBottom: 16 } }, { children: _jsx(\"p\", __assign({ className: typo.h6, style: { fontSize: 14 } }, { children: row.name }), void 0) }), void 0) }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: row.low + row.moderate + row.high + row.maintained }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: row.low }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: row.moderate }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: row.high }), void 0), _jsx(TableCell, __assign({ align: \"left\" }, { children: row.maintained }), void 0)] }), row.name));\n }) }, void 0)] }), void 0) }, void 0) }), void 0)) : (_jsxs(Paper, __assign({ elevation: 1, className: classes.paper }, { children: [_jsxs(\"div\", __assign({ className: classes.mobileToolbar }, { children: [_jsx(IconButton, __assign({ onClick: openFilters }, { children: _jsx(Filter, {}, void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.mobileButton }, { children: [_jsx(\"p\", __assign({ className: typo.body1 }, { children: \"Outcome Name\" }), void 0), _jsx(\"button\", __assign({ style: { background: 'none', border: 'none' }, onClick: function (event) { return handleRequestSort(event, 'name'); } }, { children: order === 'asc' ? _jsx(ChevronDown, {}, void 0) : _jsx(ChevronUp, {}, void 0) }), void 0)] }), void 0)] }), void 0), _jsx(\"ul\", __assign({ style: { listStyle: 'none', paddingInlineStart: 0 } }, { children: stableSort(rows, getComparator(order, orderBy)).map(function (row, index) {\n return (_jsxs(\"li\", __assign({ className: clsx(classes.mobileOutcome, index % 2 === 0 && classes.evenBackground) }, { children: [_jsx(\"div\", __assign({ className: classes.row, style: { justifyContent: 'space-between' } }, { children: _jsx(\"div\", __assign({ className: classes.row, style: { justifyContent: 'flex-start' } }, { children: _jsx(\"p\", __assign({ className: typo.subtitle1, style: { marginLeft: 8 } }, { children: row.name }), void 0) }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.grid }, { children: [_jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"# Assigned\" }), void 0), _jsx(\"div\", __assign({ className: classes.row }, { children: _jsx(\"p\", __assign({ className: typo.caption }, { children: row.low + row.moderate + row.high + row.maintained }), void 0) }), void 0), _jsx(\"p\", __assign({ className: typo.caption, style: { textAlign: 'right', marginRight: 4 } }, { children: \"Skill Progress\" }), void 0), _jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.low } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.low }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.moderate } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.moderate }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.high } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.high }), void 0), _jsx(\"div\", { className: classes.dot, style: { backgroundColor: Colors.green } }, void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: row.maintained }), void 0)] }), void 0)] }), void 0)] }), row.id));\n }) }), void 0)] }), void 0)) }), void 0));\n};\nexport default OutcomesDetailSkillsTable;\n//# sourceMappingURL=OutcomesDetailSkillsTable.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useMediaQuery, useTheme } from '@material-ui/core';\nimport * as d3 from 'd3';\nimport { useEffect } from 'react';\nimport { useTypography } from '../../../styles/Typography';\nimport { Colors } from '../../../utils/colors';\nimport { isFloat } from '../../../utils/numberUtils';\nvar color = function (key) {\n if (!key) {\n console.warn('error: key not set');\n }\n if (key === 'low') {\n return Colors.low;\n }\n else if (key === 'moderate') {\n return Colors.moderate;\n }\n else if (key === 'high') {\n return Colors.high;\n }\n else {\n return Colors.green;\n }\n};\nvar keyToString = function (key) {\n if (!key) {\n console.warn('error: key not set');\n }\n if (key === 'low') {\n return 'Low';\n }\n else if (key === 'moderate') {\n return 'Moderate';\n }\n else if (key === 'high') {\n return 'High';\n }\n else {\n return 'Maintained';\n }\n};\nvar OutcomesGraph = function (_a) {\n var dataset = _a.dataset;\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n var typo = useTypography();\n var svg_width = isSmDown ? 330 : isMdDown ? 640 : 1000;\n var svg_height = isSmDown ? 300 : isMdDown ? 339 : 359;\n var margin = { top: 20, right: isSmDown ? 16 : 30, bottom: isMdDown ? 80 : 50, left: isMdDown ? 60 : 80 };\n var innerWidth = svg_width - margin.right - margin.left;\n var innerHeight = svg_height - margin.top - margin.bottom;\n var labelFormat = function (d) {\n var values = d.split('-');\n if (values[2] !== '1')\n return '';\n var date = new Date(+values[0], +values[1] - 1, +values[2]);\n return date.toLocaleString('default', { month: 'short' });\n };\n useEffect(function () {\n var _a;\n var svg = d3.select('#outcome-graph');\n d3.selectAll('#outcome-graph > *').remove();\n if (!dataset || dataset.length === 0) {\n return;\n }\n var legendData = [\n {\n key: 'low',\n text: 'Low Progress (0-33%)',\n },\n {\n key: 'moderate',\n text: 'Moderate Progress (34-75%)',\n },\n {\n key: 'high',\n text: 'High Progress (76-99%)',\n },\n {\n key: 'maintained',\n text: 'Maintained (100%)',\n },\n ];\n var legendY = svg_height - margin.bottom / 2;\n var dotX = function (index) {\n return (index * svg_width * (isSmDown && index === 1 ? 0.9 : 1)) / legendData.length +\n (isSmDown ? 8 : margin.left);\n };\n var textX = function (index) { return dotX(index) + (isSmDown ? 8 : 12); };\n var legend = svg.append('g').attr('aria-label', 'Legend');\n legend\n .selectAll('circle')\n .data(legendData)\n .join('circle')\n .attr('r', 7)\n .attr('cy', legendY)\n .attr('fill', function (d) { return color(d.key); })\n .attr('cx', function (d, i) { return dotX(i); });\n var legendText = legend\n .selectAll('text')\n .data(legendData)\n .join('text')\n .attr('x', function (d, i) { return textX(i); })\n .attr('alignment-baseline', 'middle')\n .attr('y', legendY)\n .attr('class', typo.caption)\n .attr('fill', Colors.textSecondary);\n if (isMdDown) {\n legendText\n .attr('aria-label', function (d) { return d.text; })\n .selectAll('tspan')\n .data(function (d, i) { return d.text.split(' ').map(function (w) { return ({ text: w, pos: textX(i) }); }); })\n .join('tspan')\n .text(function (d) { return d.text; })\n .attr('x', function (d) { return d.pos; })\n .attr('dy', function (_, i) { return (i === 0 ? 0 : 14); })\n .attr('aria-hidden', 'true');\n }\n else {\n legendText.text(function (d) { return d.text; });\n }\n var stack = d3.stack().keys(['maintained', 'high', 'moderate', 'low']);\n var series = stack(dataset).map(function (d) { return (d.forEach(function (p) { return (p.key = d.key); }), d); });\n var xValue = function (d) { return d.weekString; };\n var xScale = d3.scaleBand().domain(dataset.map(xValue)).range([0, innerWidth]).padding(0.1);\n var yScale = d3\n .scaleLinear()\n .domain([0, (_a = d3.max(series, function (d) { return d3.max(d, function (d) { return d[1]; }); })) !== null && _a !== void 0 ? _a : 0])\n .range([innerHeight, 0]);\n var x_axis = d3.axisBottom(xScale).tickFormat(labelFormat).scale(xScale);\n svg.append('text')\n .text('# Demonstrated')\n .attr('aria-label', 'y-axis: number of outcomes demonstrated')\n .attr('class', typo.overlineMini)\n .attr('fill', Colors.textSecondary)\n .attr('transform', 'rotate(90)')\n .attr('text-anchor', 'middle')\n .attr('x', svg_height / 2)\n .attr('y', -15);\n var y_axis = d3\n .axisLeft(yScale)\n .tickFormat(function (interval) {\n return isFloat(interval.valueOf()) ? '' : interval.toString();\n })\n .scale(yScale);\n svg.append('g')\n .attr('stroke-width', 0)\n .attr('transform', \"translate(\" + margin.left + \", 5)\")\n .attr('aria-hidden', 'true')\n .call(y_axis);\n svg.append('g')\n .attr('stroke-width', 0)\n .attr('transform', \"translate(\" + margin.left + \", \" + innerHeight + \")\")\n .attr('aria-hidden', 'true')\n .call(x_axis);\n var xAxis = svg.append('g').attr('stroke-width', 0).attr('class', 'x-axis');\n xAxis.insert('text').text('x-axis: month / day').style('opacity', '0');\n xAxis\n .call(x_axis)\n .attr('transform', \"translate(\" + margin.left + \", \" + innerHeight + \")\")\n .selectAll('.x-axis .tick')\n .attr('transform', \"translate(-\" + margin.left + \", -\" + innerHeight + \")\")\n .data(dataset)\n .selectAll('.x-axis .tick text')\n .style('opacity', '0');\n d3.map(series, function (s) {\n return svg\n .selectAll('.x-axis .tick')\n .data(s)\n .insert('rect')\n .attr('fill', function (d) { return color(d.key); })\n .attr('x', function (d) { var _a; return ((_a = xScale(d.data.weekString)) !== null && _a !== void 0 ? _a : 0) + margin.left; })\n .attr('y', function (d) { return yScale(d[1]); })\n .attr('height', function (d) { return yScale(d[0]) - yScale(d[1]); })\n .attr('width', xScale.bandwidth());\n });\n d3.map(series, function (s) {\n return svg\n .selectAll('.x-axis .tick')\n .data(s)\n .insert('text')\n .attr('class', 'title')\n .text(function (d) { return keyToString(d.key) + \": \" + (d[1] - d[0]); });\n });\n }, [\n dataset,\n innerHeight,\n innerWidth,\n isMdDown,\n isSmDown,\n margin.bottom,\n margin.left,\n svg_height,\n svg_width,\n typo.caption,\n typo.overlineMini,\n ]);\n return _jsx(\"svg\", { id: \"outcome-graph\", className: 'bar-chart', width: svg_width, height: svg_height }, void 0);\n};\nexport default OutcomesGraph;\n//# sourceMappingURL=OutcomesGraph.js.map","var dayInMillis = 24 * 60 * 60 * 1000;\nvar weekInMillis = 7 * dayInMillis;\nvar getBucketForDate = function (date) {\n var sunday = new Date(date.getTime() - date.getUTCDay() * dayInMillis);\n var firstDayOfMonth = new Date(Date.UTC(sunday.getUTCFullYear(), sunday.getUTCMonth(), 1));\n var firstSundayOfMonth = new Date(firstDayOfMonth.getTime() - firstDayOfMonth.getUTCDay() * dayInMillis);\n if (firstSundayOfMonth.getUTCMonth() !== firstDayOfMonth.getUTCMonth()) {\n firstSundayOfMonth.setTime(firstSundayOfMonth.getTime() + weekInMillis);\n }\n var dayCount = sunday.getUTCDate() - firstSundayOfMonth.getUTCDate();\n var year = sunday.getUTCFullYear();\n var month = sunday.getUTCMonth() + 1;\n var weekOfMonth = Math.floor(dayCount / 7) + 1;\n return {\n weekString: year + \"-\" + month + \"-\" + weekOfMonth,\n weekOfMonth: weekOfMonth,\n month: month,\n year: year,\n low: 0,\n moderate: 0,\n high: 0,\n maintained: 0,\n };\n};\nexport var calculateBucketsForOutcomeDetail = function (weeksBack) {\n var now = new Date();\n var finalWeeksBack = weeksBack !== null && weeksBack !== void 0 ? weeksBack : 16;\n var date = new Date(now.getTime() - now.getUTCDay() * dayInMillis);\n date.setTime(date.getTime() - (finalWeeksBack - 1) * weekInMillis);\n var results = {\n dict: {},\n list: [],\n };\n for (var i = 0; i < finalWeeksBack; i++) {\n var bucket = getBucketForDate(date);\n results.dict[bucket.weekString] = bucket;\n results.list.push(bucket);\n date.setTime(date.getTime() + weekInMillis);\n }\n return results;\n};\n//# sourceMappingURL=calculateBucketsOutcomeDetail.js.map","import { calculateBucketsForOutcomeDetail } from './calculateBucketsOutcomeDetail';\nexport var reduceAndFilter = function (dataArray, numberOfWeeks) {\n var buckets = calculateBucketsForOutcomeDetail(numberOfWeeks);\n var bucketDict = buckets.dict;\n dataArray.forEach(function (item) {\n var bucket = bucketDict[item.weekString];\n if (bucket) {\n if (item.progress < 34) {\n bucket.low++;\n }\n else if (item.progress < 76) {\n bucket.moderate++;\n }\n else if (item.progress < 100) {\n bucket.high++;\n }\n else {\n bucket.maintained++;\n }\n }\n });\n return buckets.list;\n};\n//# sourceMappingURL=reduceAndFilterOutcomeDetail.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { MenuItem, Paper, useTheme, useMediaQuery } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { InsightsContext } from '../../../contexts/InsightsProvider';\nimport { HeaderContext } from '../../../contexts/HeaderContext';\nimport { UserContext } from '../../../contexts/UserContext';\nimport { useApiService } from '../../../services/ApiServiceProvider';\nimport { useTypography } from '../../../styles/Typography';\nimport { InsightsAssignmentType, InsightsOutcomesDetailStatus, } from '../../../types/types';\nimport { Colors } from '../../../utils/colors';\nimport { OUTCOMES_PATH } from '../../../utils/constants';\nimport Loading from '../../Loading';\nimport Select from '../../select/Select';\nimport Tabs from '../../Tabs';\nimport OutcomesDetailOutcomesTable from './OutcomesDetailOutcomesTable';\nimport OutcomesDetailSkillsTable from './OutcomesDetailSkillsTable';\nimport OutcomesGraph from './OutcomesGraph';\nimport { Filters } from '../Filters';\nimport { useParams } from 'react-router';\nimport { getToken } from '../../../utils/getToken';\nimport { OutcomeService } from '../../../services/OutcomeService';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { reduceAndFilter } from '../../../utils/reduceAndFilterOutcomeDetail';\nimport { defaultFilterValues } from '../Constants';\nimport { levelFilterOptions } from '../../../utils/levelFilterOptions';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f;\n return ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n contentDrawer: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n padding: 0,\n },\n _a),\n contentHeader: (_b = {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-start',\n marginBottom: 16,\n width: 1040\n },\n _b[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _b),\n closeButton: {\n width: '100%',\n paddingTop: 16,\n paddingRight: 16,\n },\n image: {\n width: 66,\n height: 66,\n marginRight: 20,\n },\n tabs: (_c = {\n width: 1040,\n height: 56,\n marginTop: 16,\n marginBottom: 16,\n borderBottom: '1px solid rgba(0, 0, 0, 0.08)'\n },\n _c[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _c[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _c),\n graphCard: (_d = {\n width: 1040,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _d[theme.breakpoints.down('md')] = {\n width: 670,\n marginBottom: 16,\n },\n _d[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _d.paddingBottom = 16,\n _d),\n row: {\n width: '100%',\n paddingLeft: 20,\n paddingRight: 20,\n paddingTop: 16,\n paddingBottom: 16,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n text: {\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n context: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'space-between',\n padding: 16,\n },\n contextButtons: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n },\n selectors: (_e = {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n marginBottom: 16\n },\n _e[theme.breakpoints.down('md')] = {\n flexWrap: 'wrap',\n '& > *': {\n marginBottom: 8,\n },\n },\n _e),\n detail: (_f = {\n width: 1040,\n display: 'flex',\n flexDirection: 'column'\n },\n _f[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _f[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _f),\n closeIcon: {\n display: 'flex',\n justifyContent: 'flex-end',\n marginBottom: 24,\n height: 24,\n minHeight: 24,\n paddingTop: 16,\n paddingRight: 24,\n },\n mobileFilters: {\n position: 'fixed',\n top: 0,\n right: 0,\n zIndex: 100,\n width: 312,\n minWidth: 312,\n backgroundColor: Colors.white,\n boxShadow: '0 12.5px 128px 4px rgba(0,0,0,0.08), 0 24px 32px 2px rgba(0,0,0,0.08)',\n display: 'flex',\n flexDirection: 'column',\n },\n filterScrollArea: {\n overflow: 'auto',\n msOverflowStyle: '-ms-autohiding-scrollbar',\n padding: 24,\n paddingTop: 16,\n '& > *': {\n marginBottom: 16,\n },\n },\n });\n});\nvar InsightOutcomeDetail = function (_a) {\n var _b, _c;\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var outcomeId = useParams().outcomeId;\n var user = useContext(UserContext).user;\n var _d = useContext(HeaderContext), setTitle = _d.setTitle, setGoBack = _d.setGoBack, setTabs = _d.setTabs;\n var _e = useContext(InsightsContext), direct = _e.direct, setDirect = _e.setDirect, regionFilter = _e.regionFilter, setRegionFilter = _e.setRegionFilter, departmentFilter = _e.departmentFilter, setDepartmentFilter = _e.setDepartmentFilter, levelFilter = _e.levelFilter, setLevelFilter = _e.setLevelFilter, assignmentFilter = _e.assignmentFilter, setAssignmentFilter = _e.setAssignmentFilter, filter = _e.filter, setFilter = _e.setFilter, setAvailableLevelOptions = _e.setAvailableLevelOptions;\n var _f = useMsal(), instance = _f.instance, accounts = _f.accounts;\n var account = useAccount(accounts[0]);\n var _g = useContext(TokenContext), ssoToken = _g.ssoToken, oid = _g.oid, tid = _g.tid, clientType = _g.clientType;\n var _h = __read(useState(undefined), 2), outcome = _h[0], setOutcome = _h[1];\n var _j = __read(useState(undefined), 2), reports = _j[0], setReports = _j[1];\n var _k = __read(useState('USERS'), 2), tab = _k[0], setTab = _k[1];\n var _l = __read(useState(undefined), 2), filteredReports = _l[0], setFilteredReports = _l[1];\n var _m = __read(useState(undefined), 2), skills = _m[0], setSkills = _m[1];\n var _o = __read(useState(false), 2), receivedData = _o[0], setReceivedData = _o[1];\n var _p = __read(useState([]), 2), departmentOptions = _p[0], setDepartmentOptions = _p[1];\n var _q = __read(useState([]), 2), regions = _q[0], setRegions = _q[1];\n var _r = __read(useState(false), 2), setupFilters = _r[0], setSetupFilters = _r[1];\n var _s = __read(useState(undefined), 2), dataset = _s[0], setDataset = _s[1];\n var _t = __read(useState(undefined), 2), filteredDataset = _t[0], setFilteredDataset = _t[1];\n var _u = __read(useState(0), 2), assigned = _u[0], setAssigned = _u[1];\n var _v = __read(useState(), 2), openFilters = _v[0], setOpenFilters = _v[1];\n var _w = __read(useState(false), 2), imagesLoadedRunFilters = _w[0], setImagesLoadedRunFilters = _w[1];\n var _x = __read(useState(), 2), levels = _x[0], setLevels = _x[1];\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n var ApiService = useApiService();\n useEffect(function () {\n setTitle('Back');\n setGoBack(true);\n setTabs(undefined);\n }, [setGoBack, setTabs, setTitle]);\n var getImages = useCallback(function (reports) { return __awaiter(void 0, void 0, void 0, function () {\n var oids, response, images_1, newReports;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n oids = reports.map(function (report) { return report.oid; });\n if (!(oids.length > 0)) return [3, 2];\n return [4, ApiService.getUserImages(user, oids)];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n images_1 = response.data;\n newReports = __spreadArray([], __read(reports), false);\n newReports.forEach(function (report) {\n var image = images_1.find(function (i) { return i.oid === report.oid; });\n if (image && image.contentType && image.data) {\n report.image = \"data:\" + image.contentType + \";base64,\" + image.data;\n }\n });\n setReports(newReports);\n _a.label = 2;\n case 2: return [2];\n }\n });\n }); }, [ApiService, user]);\n var getOutcomeUsers = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightsOutcomeUsers(user, Number(outcomeId))];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setReports(response.data);\n return [4, getImages(response.data)];\n case 2:\n _a.sent();\n setImagesLoadedRunFilters(true);\n return [2];\n }\n });\n }); }, [ApiService, getImages, outcomeId, user]);\n var getSkills = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightsOutcomeSkills(user, Number(outcomeId))];\n case 1:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n setSkills(response.data);\n return [2];\n }\n });\n }); }, [ApiService, outcomeId, user]);\n var getCsv = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var response;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!user) {\n return [2];\n }\n return [4, ApiService.getInsightsOutcomeGraph(user, Number(outcomeId))];\n case 1:\n response = _a.sent();\n if (!response || response.data.length === 0) {\n return [2];\n }\n setDataset(response.data);\n return [2];\n }\n });\n }); }, [ApiService, outcomeId, user]);\n var getDepartmentOptions = useCallback(function () {\n if (!reports || reports.length === 0) {\n return [];\n }\n var seenDepartments = new Set();\n var options = [];\n reports.forEach(function (report) {\n if (!seenDepartments.has(report.department)) {\n seenDepartments.add(report.department);\n options.push(report.department === 0 ? 'None' : report.department.toString());\n }\n });\n setDepartmentOptions(options.sort(function (a, b) { return (a < b ? -1 : a > b ? 1 : 0); }));\n }, [reports]);\n var getRegions = useCallback(function () {\n if (!reports || reports.length === 0) {\n return [];\n }\n var seenRegions = new Set();\n var options = [];\n reports.forEach(function (report) {\n if (!seenRegions.has(report.country)) {\n seenRegions.add(report.country);\n options.push(report.country);\n }\n });\n setRegions(options.sort(function (a, b) { return (a < b ? -1 : a > b ? 1 : 0); }));\n }, [reports]);\n var runFilters = useCallback(function () {\n var newReports = [];\n var newDataset = [];\n var filteredAndReducedDataset = [];\n if (!reports || !dataset || reports.length === 0 || dataset.length === 0) {\n return;\n }\n if (filter.assignmentType === 'All Users' || filter.assignmentType === '') {\n reports.forEach(function (value) {\n newReports.push({\n oid: value.oid,\n name: value.name,\n image: value.image,\n department: value.department.toString(),\n country: value.country,\n assignmentType: value.allAssignmentType,\n level: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgLevel\n : value.selfLevel,\n progress: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgProgress\n : value.selfProgress,\n status: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgStatus\n : value.selfStatus,\n direct: value.direct,\n });\n });\n dataset.forEach(function (value) {\n newDataset.push({\n year: value.year,\n month: value.month,\n oid: value.oid,\n name: value.name,\n assignmentType: value.allAssignmentType,\n level: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgLevel\n : value.selfLevel,\n progress: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgProgress\n : value.selfProgress,\n department: value.department,\n country: value.country,\n direct: value.direct,\n weekString: value.weekString,\n });\n });\n }\n else if (filter.assignmentType === 'All Assigned') {\n reports.forEach(function (value) {\n if (value.selfStatus !== InsightsOutcomesDetailStatus.NotAssigned ||\n value.orgStatus !== InsightsOutcomesDetailStatus.NotAssigned) {\n newReports.push({\n oid: value.oid,\n name: value.name,\n image: value.image,\n department: value.department.toString(),\n country: value.country,\n assignmentType: value.allAssignmentType,\n level: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgLevel\n : value.selfLevel,\n progress: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgProgress\n : value.selfProgress,\n status: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgStatus\n : value.selfStatus,\n direct: value.direct,\n });\n }\n });\n dataset.forEach(function (value) {\n if (value.selfStatus !== InsightsOutcomesDetailStatus.NotAssigned ||\n value.orgStatus !== InsightsOutcomesDetailStatus.NotAssigned) {\n newDataset.push({\n year: value.year,\n month: value.month,\n oid: value.oid,\n name: value.name,\n assignmentType: value.allAssignmentType,\n level: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgLevel\n : value.selfLevel,\n progress: value.allAssignmentType === InsightsAssignmentType.OrgAssigned\n ? value.orgProgress\n : value.selfProgress,\n department: value.department,\n country: value.country,\n direct: value.direct,\n weekString: value.weekString,\n });\n }\n });\n }\n else if (filter.assignmentType === 'Self Assigned') {\n reports.forEach(function (value) {\n if (value.selfStatus !== InsightsOutcomesDetailStatus.NotAssigned) {\n newReports.push({\n oid: value.oid,\n name: value.name,\n image: value.image,\n department: value.department.toString(),\n country: value.country,\n assignmentType: InsightsAssignmentType.SelfAssigned,\n level: value.selfLevel,\n progress: value.selfProgress,\n status: value.selfStatus,\n direct: value.direct,\n });\n }\n });\n dataset.forEach(function (value) {\n if (value.selfStatus !== InsightsOutcomesDetailStatus.NotAssigned) {\n newDataset.push({\n year: value.year,\n month: value.month,\n oid: value.oid,\n name: value.name,\n assignmentType: InsightsAssignmentType.SelfAssigned,\n level: value.selfLevel,\n progress: value.selfProgress,\n department: value.department,\n country: value.country,\n direct: value.direct,\n weekString: value.weekString,\n });\n }\n });\n }\n else if (filter.assignmentType === 'Organization Assigned') {\n reports.forEach(function (value) {\n if (value.orgStatus !== InsightsOutcomesDetailStatus.NotAssigned) {\n newReports.push({\n oid: value.oid,\n name: value.name,\n image: value.image,\n department: value.department.toString(),\n country: value.country,\n assignmentType: InsightsAssignmentType.OrgAssigned,\n level: value.orgLevel,\n progress: value.orgProgress,\n status: value.orgStatus,\n direct: value.direct,\n });\n }\n });\n dataset.forEach(function (value) {\n if (value.orgStatus !== InsightsOutcomesDetailStatus.NotAssigned) {\n newDataset.push({\n year: value.year,\n month: value.month,\n oid: value.oid,\n name: value.name,\n assignmentType: InsightsAssignmentType.OrgAssigned,\n level: value.orgLevel,\n progress: value.orgProgress,\n department: value.department,\n country: value.country,\n direct: value.direct,\n weekString: value.weekString,\n });\n }\n });\n }\n else if (filter.assignmentType === 'Unassigned') {\n reports.forEach(function (value) {\n if (value.selfStatus === InsightsOutcomesDetailStatus.NotAssigned &&\n value.orgStatus === InsightsOutcomesDetailStatus.NotAssigned) {\n newReports.push({\n oid: value.oid,\n name: value.name,\n image: value.image,\n department: value.department.toString(),\n country: value.country,\n assignmentType: InsightsAssignmentType.OrgAssigned,\n level: value.orgLevel,\n progress: value.orgProgress,\n status: value.orgStatus,\n direct: value.direct,\n });\n }\n });\n dataset.forEach(function (value) {\n if (value.selfStatus === InsightsOutcomesDetailStatus.NotAssigned &&\n value.orgStatus === InsightsOutcomesDetailStatus.NotAssigned) {\n newDataset.push({\n year: value.year,\n month: value.month,\n oid: value.oid,\n name: value.name,\n assignmentType: InsightsAssignmentType.OrgAssigned,\n level: value.orgLevel,\n progress: value.orgProgress,\n department: value.department,\n country: value.country,\n direct: value.direct,\n weekString: value.weekString,\n });\n }\n });\n }\n if (filter.search !== '') {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) {\n return report.name.toUpperCase().includes(filter.search.toUpperCase());\n });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) {\n return report.name.toUpperCase().includes(filter.search.toUpperCase());\n });\n }\n if (filter.department !== '') {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) { return report.department === filter.department; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.department === filter.department; });\n }\n if (filter.region !== '') {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) { return report.country === filter.region; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.country === filter.region; });\n }\n if (filter.level !== '') {\n if (filter.level === 'User Level') {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) { return report.level === 1; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.level === 1; });\n }\n else if (filter.level === 'Producer Level') {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) { return report.level === 2; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.level === 2; });\n }\n else if (filter.level === 'Master Level') {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) { return report.level === 3; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.level === 3; });\n }\n else {\n newReports = newReports === null || newReports === void 0 ? void 0 : newReports.filter(function (report) { return report.level === 0; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.level === 0; });\n }\n }\n if (filter.direct !== '') {\n if (filter.direct === 'Direct Reports') {\n newReports = newReports.filter(function (report) { return report.direct === 1; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.direct === 1; });\n }\n else if (filter.direct === 'All Reports') {\n newReports = newReports.filter(function (report) { return report.direct >= 1; });\n newDataset = newDataset === null || newDataset === void 0 ? void 0 : newDataset.filter(function (report) { return report.direct >= 1; });\n }\n }\n if (filter.time) {\n filteredAndReducedDataset = reduceAndFilter(newDataset !== null && newDataset !== void 0 ? newDataset : [], filter.time);\n }\n setFilteredReports(newReports);\n setFilteredDataset(filteredAndReducedDataset);\n setSetupFilters(true);\n }, [\n dataset,\n filter.assignmentType,\n filter.department,\n filter.direct,\n filter.level,\n filter.region,\n filter.search,\n filter.time,\n reports,\n ]);\n var clearLevel = useCallback(function () {\n setLevelFilter(undefined);\n var newFilter = filter;\n newFilter.level = '';\n setFilter(newFilter);\n runFilters();\n }, [filter, runFilters, setFilter, setLevelFilter]);\n var getOutcomeDetails = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, outcomeService, response, formattedAvailableTargetLevels, allLevelOptions, currentSelectedLevelOption;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n outcomeService = new OutcomeService(newToken, oid, tid, clientType);\n return [4, outcomeService.getOutcomeDetails(Number(outcomeId))];\n case 2:\n response = _a.sent();\n if (!response) {\n return [2];\n }\n if (response.maxLevel) {\n formattedAvailableTargetLevels = Array.from(Array(response.maxLevel + 1).keys());\n setLevels(formattedAvailableTargetLevels);\n setAvailableLevelOptions(formattedAvailableTargetLevels);\n if (levelFilter) {\n allLevelOptions = levelFilterOptions();\n currentSelectedLevelOption = allLevelOptions.find(function (levelOption) { return levelOption.value === levelFilter; });\n if (!currentSelectedLevelOption ||\n !formattedAvailableTargetLevels.includes(currentSelectedLevelOption.key)) {\n clearLevel();\n }\n }\n }\n else {\n clearLevel();\n }\n setOutcome(response);\n return [2];\n }\n });\n }); }, [\n account,\n clientType,\n instance,\n oid,\n outcomeId,\n ssoToken,\n tid,\n levelFilter,\n clearLevel,\n setAvailableLevelOptions,\n ]);\n var getAssigned = useCallback(function () {\n var count = 0;\n filteredReports === null || filteredReports === void 0 ? void 0 : filteredReports.forEach(function (value) {\n if (value.status !== InsightsOutcomesDetailStatus.NotAssigned) {\n count++;\n }\n });\n setAssigned(count);\n }, [filteredReports]);\n useEffect(function () {\n if (reports && dataset && imagesLoadedRunFilters) {\n runFilters();\n setImagesLoadedRunFilters(false);\n }\n }, [reports, dataset, imagesLoadedRunFilters, runFilters]);\n useEffect(function () {\n if (!receivedData) {\n getOutcomeDetails();\n getOutcomeUsers();\n getSkills();\n getCsv();\n setReceivedData(true);\n }\n if (!setupFilters) {\n getDepartmentOptions();\n getRegions();\n runFilters();\n }\n getAssigned();\n }, [\n receivedData,\n getOutcomeUsers,\n getSkills,\n setupFilters,\n getDepartmentOptions,\n getRegions,\n getCsv,\n runFilters,\n getAssigned,\n getOutcomeDetails,\n ]);\n useEffect(function () {\n if (isMdDown) {\n var newFilter = filter;\n newFilter.time = defaultFilterValues.time;\n setFilter(newFilter);\n runFilters();\n }\n }, [isMdDown, filter, runFilters, setFilter]);\n useEffect(function () {\n var setDefaultTime = function () {\n filter.time = defaultFilterValues.time;\n };\n return function () { return setDefaultTime(); };\n }, [filter]);\n var changeTab = function (newTab) {\n setTab(newTab);\n };\n var tabs = [\n {\n name: 'USERS',\n onClick: function () { return changeTab('USERS'); },\n selected: tab === 'USERS',\n },\n {\n name: 'SKILLS',\n onClick: function () { return changeTab('SKILLS'); },\n selected: tab === 'SKILLS',\n },\n ];\n var search = function (name) {\n var newFilter = filter;\n newFilter.search = name;\n setFilter(newFilter);\n runFilters();\n };\n var clear = function () {\n setDepartmentFilter(undefined);\n setRegionFilter(undefined);\n setAssignmentFilter(undefined);\n setLevelFilter(undefined);\n setDirect(undefined);\n setFilter({\n search: '',\n department: '',\n region: '',\n direct: '',\n assignmentType: '',\n level: '',\n status: '',\n time: defaultFilterValues.time,\n });\n runFilters();\n };\n var onChangeDepartments = function (event) {\n setDepartmentFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Departments') {\n newFilter.department = '';\n }\n else {\n newFilter.department = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearDepartments = function () {\n setDepartmentFilter(undefined);\n var newFilter = filter;\n newFilter.department = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeRegion = function (event) {\n setRegionFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Regions') {\n newFilter.region = '';\n }\n else {\n newFilter.region = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearRegions = function () {\n setRegionFilter(undefined);\n var newFilter = filter;\n newFilter.region = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeLevel = function (event) {\n setLevelFilter(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Levels') {\n newFilter.level = '';\n }\n else {\n newFilter.level = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var onChangeAssignment = function (event) {\n setAssignmentFilter(event.target.value);\n var newFilter = filter;\n newFilter.assignmentType = event.target.value.toString();\n setFilter(newFilter);\n runFilters();\n };\n var clearAssignment = function () {\n setAssignmentFilter(undefined);\n var newFilter = filter;\n newFilter.assignmentType = '';\n setFilter(newFilter);\n runFilters();\n };\n var onChangeReports = function (event) {\n setDirect(event.target.value);\n var newFilter = filter;\n if (event.target.value === 'All Users') {\n newFilter.direct = '';\n }\n else {\n newFilter.direct = event.target.value;\n }\n setFilter(newFilter);\n runFilters();\n };\n var clearReports = function () {\n setDirect(undefined);\n var newFilter = filter;\n newFilter.direct = '';\n setFilter(newFilter);\n runFilters();\n };\n var onGraphTime = function (event) {\n var newFilter = filter;\n newFilter.time = event.target.value;\n setFilter(newFilter);\n runFilters();\n };\n var toggleFilters = function () { return setOpenFilters(!openFilters); };\n if (!setupFilters || !outcome) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsx(\"main\", __assign({ className: classes.root }, { children: _jsxs(\"div\", __assign({ className: classes.detail }, { children: [_jsxs(\"div\", __assign({ className: classes.contentHeader }, { children: [_jsx(\"img\", { src: \"\" + OUTCOMES_PATH + outcome.image + \".svg\", alt: \"\", className: classes.image }, void 0), _jsxs(\"div\", { children: [_jsx(\"h2\", __assign({ className: typo.h6 }, { children: outcome.name }), void 0), _jsxs(\"p\", __assign({ className: typo.subtitle1 }, { children: [\"Assigned to: \", assigned, \" Users\"] }), void 0)] }, void 0)] }), void 0), _jsx(Filters, { filteredLength: (_b = filteredReports === null || filteredReports === void 0 ? void 0 : filteredReports.length) !== null && _b !== void 0 ? _b : 0, clearAll: clear, departmentFilter: departmentFilter, onChangeDepartments: onChangeDepartments, departmentOptions: departmentOptions, clearDepartment: clearDepartments, regionFilter: regionFilter, onChangeRegion: onChangeRegion, regionOptions: regions, clearRegion: clearRegions, levelOptions: levels, levelFilter: levelFilter, onChangeLevel: onChangeLevel, clearLevel: clearLevel, assignmentFilter: assignmentFilter, onChangeAssignment: onChangeAssignment, clearAssignment: clearAssignment, reportsFilter: direct, onChangeReports: onChangeReports, clearReports: clearReports }, void 0), _jsxs(Paper, __assign({ elevation: 1, className: classes.graphCard }, { children: [_jsxs(\"div\", __assign({ className: classes.row }, { children: [_jsxs(\"div\", __assign({ className: classes.text }, { children: [_jsx(\"h3\", __assign({ className: typo.subtitle1, style: { marginRight: 8 } }, { children: \"Progress Towards Completion\" }), void 0), _jsx(\"p\", __assign({ className: typo.caption }, { children: \"of Assigned Target Levels\" }), void 0)] }), void 0), _jsxs(Select, __assign({ value: (_c = filter.time) !== null && _c !== void 0 ? _c : defaultFilterValues.time, onChange: onGraphTime, light: true, style: { width: 150, marginRight: 16 }, disabled: isMdDown, displayEmpty: false }, { children: [_jsx(MenuItem, __assign({ value: defaultFilterValues.time }, { children: '4-Months' }), void 0), _jsx(MenuItem, __assign({ value: 52 }, { children: '1-Year' }), void 0)] }), void 0)] }), void 0), _jsx(OutcomesGraph, { dataset: filteredDataset }, void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.contentDrawer }, { children: [_jsx(\"div\", __assign({ className: classes.tabs }, { children: _jsx(Tabs, { tabs: tabs, style: { justifyContent: 'flex-start' } }, void 0) }), void 0), _jsx(\"div\", { children: tab === 'USERS' ? (_jsx(OutcomesDetailOutcomesTable, { outcomeId: Number(outcomeId), reports: filteredReports, getReports: getOutcomeUsers, search: search, page: page }, void 0)) : (_jsx(OutcomesDetailSkillsTable, { rows: skills, openFilters: toggleFilters }, void 0)) }, void 0)] }), void 0)] }), void 0) }), void 0));\n};\nexport default InsightOutcomeDetail;\n//# sourceMappingURL=InsightOutcomeDetail.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { IconButton } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useState } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { useFocusOnMount } from '../../hooks/useFocusOnMount';\nimport ComingSoonIcon from '../icons/ComingSoonIcon';\nimport { Check } from 'react-feather';\nvar useStyles = makeStyles({\n addButton: {\n height: 38,\n minHeight: 38,\n width: 38,\n minWidth: 38,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: '50%',\n backgroundColor: 'transparent',\n color: Colors.purple,\n },\n disabled: {\n color: Colors.textSecondary,\n backgroundColor: Colors.background,\n },\n clickable: {\n '&:hover': {\n backgroundColor: Colors.iconHover,\n cursor: 'pointer',\n },\n '&:focus': {\n backgroundColor: Colors.iconHover,\n },\n },\n large: {\n height: 48,\n width: 48,\n },\n});\nvar CheckIconButton = function (_a) {\n var onClick = _a.onClick, large = _a.large, disabled = _a.disabled, comingSoon = _a.comingSoon, buttonName = _a.buttonName, tabIndex = _a.tabIndex, focusOnMount = _a.focusOnMount;\n var classes = useStyles();\n var _b = __read(useState(false), 2), mouseOver = _b[0], setMouseOver = _b[1];\n var _c = __read(useState(false), 2), mouseDown = _c[0], setMouseDown = _c[1];\n var onMouseOver = function () { return setMouseOver(true); };\n var onMouseOut = function () {\n setMouseOver(false);\n setMouseDown(false);\n };\n var onMouseDown = function () { return setMouseDown(true); };\n var onMouseUp = function () { return setMouseDown(false); };\n var focusRef = useFocusOnMount(focusOnMount);\n return (_jsx(IconButton, __assign({ \"aria-label\": buttonName, className: clsx(classes.addButton, large ? classes.large : undefined, !disabled ? classes.clickable : undefined, disabled && classes.disabled), onClick: !disabled ? onClick : undefined, onMouseOver: !disabled ? onMouseOver : undefined, onMouseOut: !disabled ? onMouseOut : undefined, onMouseDown: !disabled ? onMouseDown : undefined, onMouseUp: !disabled ? onMouseUp : undefined, style: {\n border: disabled\n ? ''\n : mouseOver && !mouseDown\n ? \"1px solid \" + Colors.textPrimary\n : mouseDown\n ? '1px solid rgba(101,78,163,0.24)'\n : '1px solid rgba(101, 78, 163, 0.24)',\n }, tabIndex: tabIndex, ref: focusRef }, { children: comingSoon ? _jsx(ComingSoonIcon, { large: large }, void 0) : _jsx(Check, {}, void 0) }), void 0));\n};\nexport default CheckIconButton;\n//# sourceMappingURL=CheckIconButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { IconButton } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useState } from 'react';\nimport { Colors } from '../../utils/colors';\nimport { useFocusOnMount } from '../../hooks/useFocusOnMount';\nimport { Plus } from 'react-feather';\nvar useStyles = makeStyles({\n addButton: {\n height: 38,\n minHeight: 38,\n width: 38,\n minWidth: 38,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: '50%',\n backgroundColor: 'transparent',\n color: Colors.purple,\n },\n disabled: {\n color: Colors.textSecondary,\n backgroundColor: Colors.background,\n },\n clickable: {\n '&:hover': {\n backgroundColor: Colors.iconHover,\n cursor: 'pointer',\n },\n '&:focus': {\n backgroundColor: Colors.iconHover,\n },\n },\n large: {\n height: 48,\n width: 48,\n },\n});\nvar PlusIconButton = function (_a) {\n var onClick = _a.onClick, large = _a.large, disabled = _a.disabled, buttonName = _a.buttonName, tabIndex = _a.tabIndex, focusOnMount = _a.focusOnMount;\n var classes = useStyles();\n var _b = __read(useState(false), 2), mouseOver = _b[0], setMouseOver = _b[1];\n var _c = __read(useState(false), 2), mouseDown = _c[0], setMouseDown = _c[1];\n var onMouseOver = function () { return setMouseOver(true); };\n var onMouseOut = function () {\n setMouseOver(false);\n setMouseDown(false);\n };\n var onMouseDown = function () { return setMouseDown(true); };\n var onMouseUp = function () { return setMouseDown(false); };\n var focusRef = useFocusOnMount(focusOnMount);\n return (_jsx(IconButton, __assign({ \"aria-label\": buttonName, className: clsx(classes.addButton, large ? classes.large : undefined, !disabled ? classes.clickable : undefined, disabled && classes.disabled), onClick: !disabled ? onClick : undefined, onMouseOver: !disabled ? onMouseOver : undefined, onMouseOut: !disabled ? onMouseOut : undefined, onMouseDown: !disabled ? onMouseDown : undefined, onMouseUp: !disabled ? onMouseUp : undefined, style: {\n border: disabled\n ? ''\n : mouseOver && !mouseDown\n ? \"1px solid \" + Colors.textPrimary\n : mouseDown\n ? '1px solid rgba(101,78,163,0.24)'\n : '1px solid rgba(101, 78, 163, 0.24)',\n }, tabIndex: tabIndex, ref: focusRef }, { children: _jsx(Plus, {}, void 0) }), void 0));\n};\nexport default PlusIconButton;\n//# sourceMappingURL=PlusIconButton.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { createStyles, makeStyles } from '@material-ui/core/styles';\nimport Divider from '@material-ui/core/Divider';\nimport TextButton from '../buttons/TextButton';\nimport { Colors } from '../../utils/colors';\nimport SecondaryButton from '../buttons/SecondaryButton';\nimport Button from '../buttons/Button';\nimport { Accordion, AccordionActions, AccordionDetails, AccordionSummary } from '@material-ui/core';\nimport { useTypography } from '../../styles/Typography';\nimport { useUUID } from '../../hooks/useUUID';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return createStyles({\n root: {\n width: '100%',\n },\n summary: {\n height: '100%',\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n text: {\n height: '100%',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start',\n },\n details: {\n flexDirection: 'column',\n padding: 0,\n },\n footer: (_a = {\n height: 70,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _a[theme.breakpoints.down('sm')] = {\n width: '100%',\n },\n _a),\n divider: {\n marginRight: 33,\n marginLeft: 33,\n },\n span: {\n fontWeight: 'bold',\n },\n expansionAction: (_b = {\n paddingRight: 25\n },\n _b[theme.breakpoints.down('sm')] = {\n margin: 18,\n },\n _b[theme.breakpoints.down('sm')] = {\n display: 'flex',\n justifyContent: 'center',\n },\n _b),\n });\n});\nvar BulkAccordion = function (_a) {\n var expanded = _a.expanded, title = _a.title, subTitle = _a.subTitle, goBackText = _a.goBackText, details = _a.details, acceptText = _a.acceptText, acceptDisabled = _a.acceptDisabled, cancelText = _a.cancelText, onAccept = _a.onAccept, onCancel = _a.onCancel, goBack = _a.goBack;\n var classes = useStyles();\n var typo = useTypography();\n var id = useUUID();\n return (_jsx(\"div\", __assign({ className: classes.root }, { children: _jsxs(Accordion, __assign({ expanded: expanded }, { children: [_jsx(AccordionSummary, __assign({ \"aria-controls\": \"panel1c-content\" + id, id: \"panel1c-header-\" + id, role: \"region\" }, { children: _jsxs(\"div\", __assign({ className: classes.summary }, { children: [_jsxs(\"div\", __assign({ className: classes.text }, { children: [_jsx(\"h3\", __assign({ className: typo.h5, style: { fontWeight: 'normal' } }, { children: title }), void 0), subTitle && _jsx(\"p\", __assign({ className: typo.caption }, { children: subTitle }), void 0)] }), void 0), !expanded && goBack && (_jsx(TextButton, __assign({ onClick: goBack, style: { color: Colors.purple, fontSize: 10 } }, { children: goBackText }), void 0))] }), void 0) }), void 0), _jsx(Divider, {}, void 0), _jsx(AccordionDetails, __assign({ className: classes.details }, { children: details }), void 0), _jsx(Divider, {}, void 0), _jsx(\"div\", __assign({ className: classes.expansionAction }, { children: cancelText && onCancel ? (_jsxs(AccordionActions, __assign({ className: classes.footer }, { children: [_jsx(SecondaryButton, __assign({ onClick: onCancel, style: { width: 92, height: 36 } }, { children: cancelText }), void 0), _jsx(Button, __assign({ onClick: onAccept, style: { width: 174, height: 36 }, disabled: acceptDisabled }, { children: acceptText }), void 0)] }), void 0)) : (_jsx(AccordionActions, { children: _jsx(Button, __assign({ onClick: onAccept, style: { width: 174, height: 36 }, disabled: acceptDisabled }, { children: acceptText }), void 0) }, void 0)) }), void 0)] }), void 0) }), void 0));\n};\nexport default BulkAccordion;\n//# sourceMappingURL=BulkAccordion.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { Link, useMediaQuery, makeStyles, useTheme } from '@material-ui/core';\nimport Divider from '@material-ui/core/Divider';\nimport clsx from 'clsx';\nimport { useContext, useEffect, useState } from 'react';\nimport { InsightsContext } from '../../contexts/InsightsProvider';\nimport { useTypography } from '../../styles/Typography';\nimport { BulkAssignPanel } from '../../types/types';\nimport { Colors } from '../../utils/colors';\nimport { CDN_URL, OUTCOMES_PATH } from '../../utils/constants';\nimport { useRovingTabIndex } from '../../hooks/useRovingTabIndex';\nimport CheckIconButton from '../buttons/CheckIconButton';\nimport PlusIconButton from '../buttons/PlusIconButton';\nimport BulkAccordion from './BulkAccordion';\nimport { Tooltip } from '../Tooltip';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d, _e, _f, _g;\n return ({\n root: {\n width: '100%',\n },\n summary: {\n height: '100%',\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n text: {\n height: '100%',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'flex-start',\n },\n icon: {\n verticalAlign: 'bottom',\n height: 20,\n width: 20,\n },\n details: {\n height: 771,\n overflow: 'auto',\n overflowX: 'hidden',\n flexDirection: 'column',\n padding: 0,\n listStyleType: 'none',\n paddingInlineStart: 0,\n },\n outcome: (_a = {\n minHeight: 108,\n paddingLeft: 33,\n paddingRight: 33,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'flex-start'\n },\n _a[theme.breakpoints.down('md')] = {\n height: '100%',\n alignItems: 'flex-start',\n marginTop: 20,\n marginBottom: 12,\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n alignItems: 'center',\n paddingLeft: 0,\n paddingRight: 0,\n },\n _a),\n outcomeDescription: (_b = {\n display: 'flex',\n flexDirection: 'row'\n },\n _b[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n alignItems: 'center',\n padding: 14,\n },\n _b),\n outcomeText: (_c = {\n width: 779\n },\n _c[theme.breakpoints.down('md')] = {\n width: '100%',\n },\n _c),\n outcomeBody: (_d = {},\n _d[theme.breakpoints.down('md')] = {\n padding: 14,\n },\n _d[theme.breakpoints.down('sm')] = {\n padding: 0,\n },\n _d),\n seeDetail: (_e = {\n color: Colors.purple,\n fontFace: 'bold',\n cursor: 'pointer',\n fontWeight: 700\n },\n _e[theme.breakpoints.down('md')] = {\n display: 'flex',\n justifyContent: 'flex-end',\n },\n _e[theme.breakpoints.down('sm')] = {\n fontWeight: 700,\n },\n _e),\n image: {\n height: 64,\n minHeight: 64,\n width: 64,\n minWidth: 64,\n marginRight: 16,\n },\n footer: {\n height: 70,\n },\n divider: {\n marginRight: 33,\n marginLeft: 33,\n marginBottom: 24,\n },\n moreInfo: (_f = {\n display: 'flex',\n justifyContent: 'space-between',\n marginTop: 25,\n marginBottom: 15\n },\n _f[theme.breakpoints.down('sm')] = {\n justifyContent: 'flex-start',\n marginBottom: 8,\n },\n _f),\n iconImage: {\n height: 25,\n width: 25,\n marginRight: 15,\n marginTop: 8,\n },\n iconContainer: {\n display: 'flex',\n flexFlow: 'wrap',\n },\n buttonContainer: (_g = {\n marginTop: 15\n },\n _g[theme.breakpoints.down('md')] = {\n marginTop: 30,\n },\n _g[theme.breakpoints.down('sm')] = {\n marginTop: 0,\n },\n _g),\n smIntro: {\n display: 'flex',\n alignItems: 'center',\n marginBottom: 10,\n },\n smSeeDetailContainer: {\n display: 'flex',\n width: '100%',\n justifyContent: 'flex-end',\n marginRight: 12,\n },\n });\n});\nvar BulkOutcomePicker = function (_a) {\n var goBack = _a.goBack, onClose = _a.onClose, openDrawer = _a.openDrawer;\n var typo = useTypography();\n var classes = useStyles();\n var _b = useContext(InsightsContext), assignableOutcomes = _b.assignableOutcomes, setAssignableOutcomes = _b.setAssignableOutcomes;\n var panel = useContext(InsightsContext).panel;\n var _c = __read(useState([]), 2), selected = _c[0], setSelected = _c[1];\n var theme = useTheme();\n var isSmallDown = useMediaQuery(theme.breakpoints.down('sm'));\n useEffect(function () {\n var newSelected = [];\n if (assignableOutcomes) {\n assignableOutcomes.forEach(function (el) {\n if (el.selected) {\n newSelected.push(el);\n }\n });\n }\n setSelected(newSelected);\n }, [assignableOutcomes]);\n var seeDetail = function (outcome) {\n openDrawer(outcome);\n };\n var selectOutcome = function (outcome) {\n var newAssignableOutcomes = __spreadArray([], __read((assignableOutcomes !== null && assignableOutcomes !== void 0 ? assignableOutcomes : [])), false);\n if (newAssignableOutcomes) {\n newAssignableOutcomes.forEach(function (element) {\n if (element.id === outcome.id) {\n outcome.selected = !outcome.selected;\n }\n });\n setAssignableOutcomes(newAssignableOutcomes);\n }\n setChangedSelectedId(outcome.id);\n };\n var listRef = useRovingTabIndex({ reverseHorizontal: true });\n var _d = __read(useState(), 2), changedSelectedId = _d[0], setChangedSelectedId = _d[1];\n return (_jsx(_Fragment, { children: _jsx(BulkAccordion, { expanded: panel === BulkAssignPanel.OutcomePicker, title: \"Step 2: Select Outcomes\", goBackText: \"Edit Outcomes\", subTitle: selected.map(function (value) { return value.name + ', '; }).toString(), details: _jsx(\"ul\", __assign({ className: classes.details, ref: listRef }, { children: assignableOutcomes === null || assignableOutcomes === void 0 ? void 0 : assignableOutcomes.map(function (value, index) { return (_jsxs(\"li\", { children: [_jsxs(\"div\", __assign({ className: classes.outcome }, { children: [!isSmallDown ? (_jsxs(\"div\", __assign({ className: classes.outcomeDescription }, { children: [_jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + value.image + \".svg\" }, void 0), _jsxs(\"div\", __assign({ className: classes.outcomeText }, { children: [_jsx(\"h4\", __assign({ className: typo.subtitle1 }, { children: value.name }), void 0), _jsxs(\"p\", __assign({ className: clsx(typo.body1, classes.outcomeBody) }, { children: [value.description, _jsxs(\"div\", __assign({ className: classes.moreInfo }, { children: [_jsx(\"div\", __assign({ className: classes.iconContainer }, { children: value.apps.map(function (app) { return (_jsx(\"span\", { children: _jsx(Tooltip, __assign({ title: app.name }, { children: _jsx(\"img\", { className: classes.iconImage, src: CDN_URL + \"appimages/icons/\" + app.image, alt: app.name }, void 0) }), void 0) }, value.name)); }) }), void 0), _jsx(Link, __assign({ className: classes.seeDetail, id: value.id.toString(), onClick: function () { return seeDetail(value); }, component: \"button\", tabIndex: -1 }, { children: \"See Detail\" }), void 0)] }), void 0)] }), void 0)] }), void 0)] }), void 0)) : (_jsxs(\"div\", __assign({ className: classes.outcomeDescription }, { children: [_jsxs(\"div\", __assign({ className: classes.smIntro }, { children: [_jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + value.image + \".svg\" }, void 0), _jsx(\"h4\", __assign({ className: typo.subtitle1 }, { children: value.name }), void 0)] }), void 0), _jsx(\"div\", __assign({ className: classes.outcomeText }, { children: _jsxs(\"p\", __assign({ className: clsx(typo.body1, classes.outcomeBody) }, { children: [value.description, _jsx(\"div\", __assign({ className: classes.smSeeDetailContainer }, { children: _jsx(Link, __assign({ className: classes.seeDetail, id: value.id.toString(), onClick: function () { return seeDetail(value); }, component: \"button\", tabIndex: -1 }, { children: \"See Detail\" }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.moreInfo }, { children: _jsx(\"div\", __assign({ className: classes.iconContainer }, { children: value.apps.map(function (app) { return (_jsx(\"span\", { children: _jsx(Tooltip, __assign({ title: app.name }, { children: _jsx(\"img\", { className: classes.iconImage, src: CDN_URL + \"appimages/icons/\" + app.image, alt: app.name }, void 0) }), void 0) }, value.name)); }) }), void 0) }), void 0)] }), void 0) }), void 0)] }), void 0)), _jsxs(\"span\", __assign({ className: classes.buttonContainer }, { children: [' ', !value.selected ? (_jsx(PlusIconButton, { buttonName: 'Add ' + value.name, onClick: function () { return selectOutcome(value); }, tabIndex: index === 0 || changedSelectedId === value.id ? 0 : -1, focusOnMount: changedSelectedId === value.id }, void 0)) : (_jsx(CheckIconButton, { buttonName: 'Uncheck to remove ' + value.name, onClick: function () { return selectOutcome(value); }, tabIndex: index === 0 || changedSelectedId === value.id ? 0 : -1, focusOnMount: changedSelectedId === value.id }, void 0))] }), void 0)] }), void 0), index !== (assignableOutcomes === null || assignableOutcomes === void 0 ? void 0 : assignableOutcomes.length) - 1 && _jsx(Divider, { className: classes.divider }, void 0)] }, value.id)); }) }), void 0), acceptDisabled: selected.length < 1, acceptText: \"Assign \" + (selected.length === 0 ? '' : selected.length) + \" Outcomes\", onAccept: onClose, goBack: goBack }, void 0) }, void 0));\n};\nexport default BulkOutcomePicker;\n//# sourceMappingURL=BulkOutcomePicker.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { createStyles, makeStyles } from '@material-ui/core/styles';\nimport Divider from '@material-ui/core/Divider';\nimport { InsightsContext } from '../../contexts/InsightsProvider';\nimport { OUTCOMES_PATH, targetLevels } from '../../utils/constants';\nimport { BulkAssignPanel } from '../../types/types';\nimport BulkAccordion from './BulkAccordion';\nimport { Colors } from '../../utils/colors';\nimport Select from '../select/Select';\nimport { MenuItem } from '@material-ui/core';\nimport { useTypography } from '../../styles/Typography';\nimport clsx from 'clsx';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c, _d;\n return createStyles({\n root: {\n width: '100%',\n },\n summary: {\n height: '100%',\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n icon: {\n verticalAlign: 'bottom',\n height: 20,\n width: 20,\n },\n details: {\n flexDirection: 'column',\n padding: 0,\n },\n outcome: (_a = {\n height: 108,\n paddingLeft: 33,\n paddingRight: 33,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center'\n },\n _a[theme.breakpoints.down('md')] = {\n height: '100%',\n },\n _a[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n paddingLeft: 12,\n paddingRight: 25,\n height: '100%',\n },\n _a),\n outcomeDescription: (_b = {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start'\n },\n _b[theme.breakpoints.down('sm')] = {\n flexDirection: 'row',\n width: '100%',\n marginTop: 9,\n justifyContent: 'center',\n },\n _b),\n outcomeChange: (_c = {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-end'\n },\n _c[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n alignItems: 'flex-end',\n justifyContent: 'flex-end',\n },\n _c[theme.breakpoints.down('md')] = {\n marginBottom: 18,\n flexDirection: 'column',\n justifyContent: 'center',\n alignItems: 'flex-end',\n marginTop: 35,\n },\n _c[theme.breakpoints.down('sm')] = {\n width: '100%',\n flexDirection: 'row',\n marginBottom: 8,\n marginTop: 15,\n justifyContent: 'center',\n alignItems: 'center',\n },\n _c),\n outcomeText: {\n width: 779,\n },\n seeDetail: {\n color: Colors.purple,\n fontFace: 'bold',\n cursor: 'pointer',\n },\n image: {\n height: 64,\n minHeight: 64,\n width: 64,\n minWidth: 64,\n marginRight: 16,\n },\n footer: {\n height: 70,\n },\n divider: {\n marginRight: 33,\n marginLeft: 33,\n },\n setLevel: (_d = {},\n _d[theme.breakpoints.down('md')] = {\n marginBottom: 9,\n },\n _d[theme.breakpoints.down('sm')] = {\n marginRight: 8,\n marginTop: 0,\n marginBottom: 0,\n },\n _d),\n });\n});\nvar BulkTargetLevelPicker = function (_a) {\n var _b, _c;\n var onClose = _a.onClose, goBack = _a.goBack;\n var typo = useTypography();\n var classes = useStyles();\n var _d = useContext(InsightsContext), assignableOutcomes = _d.assignableOutcomes, setAssignableOutcomes = _d.setAssignableOutcomes;\n var panel = useContext(InsightsContext).panel;\n var selectTargetLevel = function (event, outcome) {\n var newAssignableOutcomes = __spreadArray([], __read((assignableOutcomes !== null && assignableOutcomes !== void 0 ? assignableOutcomes : [])), false);\n if (newAssignableOutcomes) {\n newAssignableOutcomes.forEach(function (element) {\n if (element.id === outcome.id) {\n element.level = event.target.value;\n }\n });\n setAssignableOutcomes(newAssignableOutcomes);\n }\n };\n return (_jsx(_Fragment, { children: _jsx(BulkAccordion, { expanded: panel === BulkAssignPanel.TargetLevelPicker, title: \"Step 3: Select Target Levels\", goBackText: \"Edit Target Levels\", details: _jsx(\"div\", __assign({ className: classes.details }, { children: assignableOutcomes === null || assignableOutcomes === void 0 ? void 0 : assignableOutcomes.map(function (value) {\n var _a;\n return value.selected && (_jsxs(\"div\", { children: [_jsxs(\"div\", __assign({ className: classes.outcome }, { children: [_jsxs(\"div\", __assign({ className: classes.outcomeDescription }, { children: [_jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + value.image + \".svg\" }, void 0), _jsx(\"p\", __assign({ className: typo.subtitle1 }, { children: value.name }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.outcomeChange }, { children: [_jsx(\"p\", __assign({ className: clsx(typo.overline, classes.setLevel) }, { children: \"Set Level\" }), void 0), _jsx(Select, __assign({ value: (_a = value.level) !== null && _a !== void 0 ? _a : 1, onChange: function (event) {\n return selectTargetLevel(event, value);\n } }, { children: targetLevels.map(function (l) { return (_jsx(MenuItem, __assign({ value: l.level }, { children: l.name }), l.name)); }) }), void 0)] }), void 0)] }), value.name + 'inner' + '-' + value.skillIds), _jsx(Divider, { className: classes.divider }, void 0)] }, value.name + '-' + value.skillIds));\n }) }), void 0), acceptDisabled: ((_c = (_b = assignableOutcomes === null || assignableOutcomes === void 0 ? void 0 : assignableOutcomes.filter(function (value) { return value.selected; })) === null || _b === void 0 ? void 0 : _b.length) !== null && _c !== void 0 ? _c : 0) < 1, acceptText: \"Accept\", onAccept: onClose, goBack: goBack }, void 0) }, void 0));\n};\nexport default BulkTargetLevelPicker;\n//# sourceMappingURL=BulkTargetLevelPicker.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { createStyles, makeStyles } from '@material-ui/core/styles';\nimport { InsightsContext } from '../../contexts/InsightsProvider';\nimport { BulkAssignPanel } from '../../types/types';\nimport { useApiService } from '../../services/ApiServiceProvider';\nimport BulkAccordion from './BulkAccordion';\nimport { UserContext } from '../../contexts/UserContext';\nimport { Colors } from '../../utils/colors';\nimport { useTypography } from '../../styles/Typography';\nimport { Level } from '../../types/enums';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return createStyles({\n root: {\n width: '100%',\n },\n icon: {\n verticalAlign: 'bottom',\n height: 20,\n width: 20,\n },\n details: {\n flexDirection: 'column',\n padding: 0,\n },\n detailList: {\n display: 'flex',\n flexDirection: 'column',\n marginBottom: 16,\n '& div': {\n display: 'flex',\n flexDirection: 'row',\n marginBottom: 16,\n },\n '& dt': {\n width: 110,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n lineHeight: '16px',\n textAlign: 'right',\n letterSpacing: '2px',\n textTransform: 'uppercase',\n },\n '& dd': (_a = {\n fontFamily: 'Open Sans',\n fontSize: 14,\n lineHeight: '16px',\n letterSpacing: '0.25px'\n },\n _a[theme.breakpoints.down('xs')] = {\n maxWidth: 150,\n },\n _a),\n },\n outcome: {\n height: 108,\n paddingLeft: 33,\n paddingRight: 33,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n outcomeDescription: {\n display: 'flex',\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n },\n outcomeText: {\n width: 779,\n },\n seeDetail: {\n color: Colors.purple,\n fontFace: 'bold',\n cursor: 'pointer',\n },\n image: {\n height: 64,\n minHeight: 64,\n width: 64,\n minWidth: 64,\n marginRight: 16,\n },\n footer: {\n height: 70,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n },\n divider: {\n marginRight: 33,\n marginLeft: 33,\n },\n span: {\n fontWeight: 'bold',\n },\n });\n});\nvar BulkAssignConfirm = function (_a) {\n var onClose = _a.onClose;\n var typo = useTypography();\n var classes = useStyles();\n var user = useContext(UserContext).user;\n var _b = useContext(InsightsContext), assignableOutcomes = _b.assignableOutcomes, panel = _b.panel, reports = _b.reports;\n var _c = __read(useState([]), 2), selectedOutcomes = _c[0], setSelectedOutcomes = _c[1];\n var ApiService = useApiService();\n useEffect(function () {\n if (assignableOutcomes) {\n setSelectedOutcomes(assignableOutcomes.filter(function (value) { return value.selected; }));\n }\n }, [assignableOutcomes, reports]);\n var bulkAssignOutcomes = function () { return __awaiter(void 0, void 0, void 0, function () {\n var outcomes;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n if (!(user && selectedOutcomes)) return [3, 2];\n outcomes = selectedOutcomes.map(function (value) {\n var _a;\n return { id: value.id, level: (_a = value.level) !== null && _a !== void 0 ? _a : Level.User };\n });\n if (!reports) return [3, 2];\n return [4, ApiService.bulkOutcomeAssign(user, reports, outcomes)];\n case 1:\n _a.sent();\n _a.label = 2;\n case 2:\n onClose();\n return [2];\n }\n });\n }); };\n return (_jsx(_Fragment, { children: _jsx(BulkAccordion, { expanded: panel === BulkAssignPanel.Confirm, title: \"Step 4: Confirm Assignments\", details: _jsxs(\"dl\", __assign({ className: classes.detailList }, { children: [_jsxs(\"div\", { children: [_jsx(\"dt\", { children: \"Who\" }, void 0), _jsx(\"dd\", { children: reports === null || reports === void 0 ? void 0 : reports.length }, void 0)] }, void 0), _jsxs(\"div\", { children: [_jsx(\"dt\", { children: \"What\" }, void 0), _jsxs(\"dd\", { children: [_jsx(\"span\", __assign({ className: classes.span }, { children: \"Confirm\" }), void 0), _jsx(\"br\", {}, void 0), selectedOutcomes.map(function (value) { return (_jsx(\"p\", __assign({ className: typo.body2 }, { children: value.name }), value.name + '-' + value.skillIds)); })] }, void 0)] }, void 0)] }), void 0), acceptDisabled: selectedOutcomes.length < 1, acceptText: \"Assign Outcomes\", onAccept: bulkAssignOutcomes, cancelText: \"Cancel\", onCancel: onClose }, void 0) }, void 0));\n};\nexport default BulkAssignConfirm;\n//# sourceMappingURL=BulkAssignConfirm.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { useState } from 'react';\nimport { Box, makeStyles } from '@material-ui/core';\nimport VideoDialog from '../video/VideoDialog';\nimport { BLOB_CONTAINER, OTHER_PATH } from '../../utils/constants';\nimport { Colors } from '../../utils/colors';\nimport Button from '../buttons/Button';\nimport { useTypography } from '../../styles/Typography';\nimport { Play } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n detailOverview: (_a = {\n alignItems: 'flex-start',\n justifyContent: 'space-between',\n borderRadius: 4,\n backgroundColor: Colors.white,\n boxShadow: '0 1px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.08)',\n padding: 24,\n marginTop: 32,\n marginBottom: 32\n },\n _a[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n justifyContent: 'center',\n },\n _a),\n textContent: (_b = {\n marginTop: 16\n },\n _b[theme.breakpoints.down('md')] = {\n marginRight: 0,\n },\n _b),\n descriptionAssigned: (_c = {},\n _c[theme.breakpoints.down('md')] = {\n marginRight: 0,\n },\n _c),\n video: function (_a) {\n var _b;\n var url = _a.url;\n return (_b = {\n backgroundImage: \"url(\" + url + \")\",\n backgroundSize: 'contain',\n backgroundColor: '#EEEEF8',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n width: 382,\n minWidth: 382,\n height: 218,\n boxShadow: '0 5px 16px 1px rgba(0,0,0,0.08), 0 2px 8px 0 rgba(0,0,0,0.08)'\n },\n _b[theme.breakpoints.down('md')] = {\n width: 440,\n minWidth: 440,\n height: 250.93069306930693,\n marginBottom: 16,\n margin: 'auto',\n },\n _b[theme.breakpoints.down('xs')] = {\n width: 280,\n minWidth: 280,\n height: 159.68316831683168,\n marginBottom: 16,\n margin: 'auto',\n },\n _b);\n },\n videoButton: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n color: Colors.white,\n justifyContent: 'center',\n },\n videoIcon: {\n marginRight: 8,\n },\n });\n});\nvar BulkDetailOverview = function (_a) {\n var videoOverviewId = _a.videoOverviewId, assignerName = _a.assignerName, assignedDate = _a.assignedDate, description = _a.description, type = _a.type, isAssigned = _a.isAssigned;\n var typo = useTypography();\n var classes = useStyles({ url: \"\" + OTHER_PATH + type + \"_detail_video_thumbnail.jpg\" });\n var _b = __read(useState(false), 2), openVideoDialog = _b[0], setOpenVideoDialog = _b[1];\n var toggleVideoDialog = function () { return setOpenVideoDialog(!openVideoDialog); };\n var overviewContentData = {\n container: BLOB_CONTAINER,\n fileName: videoOverviewId + \".mp4\",\n contentId: videoOverviewId,\n views: 1,\n };\n var Video = function () { return (_jsx(\"div\", __assign({ className: classes.video }, { children: _jsx(Button, __assign({ onClick: toggleVideoDialog, style: { width: 200, minWidth: 200 } }, { children: _jsxs(\"span\", __assign({ className: classes.videoButton }, { children: [_jsx(\"span\", __assign({ className: classes.videoIcon }, { children: _jsx(Play, {}, void 0) }), void 0), \"Watch Overview\"] }), void 0) }), void 0) }), void 0)); };\n return (_jsxs(\"div\", __assign({ className: classes.detailOverview }, { children: [_jsx(Video, {}, void 0), _jsxs(\"div\", __assign({ className: classes.textContent }, { children: [_jsx(Box, __assign({ marginBottom: 2 }, { children: _jsx(\"h2\", __assign({ className: typo.overline }, { children: \"About This Outcome\" }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.descriptionAssigned }, { children: [_jsx(\"p\", __assign({ className: typo.body1 }, { children: description }), void 0), isAssigned ? (_jsx(_Fragment, { children: assignerName && assignedDate && (_jsxs(\"p\", __assign({ className: typo.body2 }, { children: [assignerName, \" \", assignedDate] }), void 0)) }, void 0)) : null] }), void 0)] }), void 0), overviewContentData && (_jsx(VideoDialog, { open: openVideoDialog, onClose: toggleVideoDialog, contentData: overviewContentData }, void 0))] }), void 0));\n};\nexport default BulkDetailOverview;\n//# sourceMappingURL=BulkDetailOverview.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Drawer, IconButton } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport clsx from 'clsx';\nimport { useContext } from 'react';\nimport { InsightsContext } from '../../contexts/InsightsProvider';\nimport { useTypography } from '../../styles/Typography';\nimport { Colors } from '../../utils/colors';\nimport { OUTCOMES_PATH } from '../../utils/constants';\nimport { useRovingTabIndex } from '../../hooks/useRovingTabIndex';\nimport Button from '../buttons/Button';\nimport Skill from '../skills/Skill';\nimport BulkDetailOverview from './BulkDetailOverview';\nimport { Pages } from '../../types/enums';\nimport { X } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n name: (_a = {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontWeight: 600,\n fontSize: 32,\n letterSpacing: 0.25,\n lineHeight: '40px'\n },\n _a[theme.breakpoints.down('sm')] = {\n fontSize: 20,\n letterSpacing: 0.25,\n lineHeight: '24px',\n },\n _a[theme.breakpoints.down('xs')] = {\n fontSize: 16,\n letterSpacing: 0.15,\n lineHeight: '24px',\n },\n _a),\n skillsAchieved: (_b = {\n color: Colors.textSecondary,\n fontFamily: 'Open Sans',\n fontSize: 16,\n letterSpacing: 0.5,\n lineHeight: '24px',\n marginTop: 8\n },\n _b[theme.breakpoints.down('xs')] = {\n fontSize: 12,\n letterSpacing: 0.15,\n lineHeight: '16px',\n },\n _b),\n addText: {\n color: Colors.textSecondary,\n fontFamily: 'Ubuntu',\n fontSize: 12,\n letterSpacing: 2,\n lineHeight: '16px',\n marginTop: 8,\n },\n drawer: {\n width: 560,\n paddingTop: 24,\n paddingLeft: 16,\n paddingRight: 16,\n },\n skills: {\n borderRadius: 4,\n backgroundColor: Colors.white,\n boxShadow: '0 1px 4px 0.5px rgba(0,0,0,0.08), 0 0.5px 1.5px 0 rgba(0,0,0,0.08)',\n padding: 24,\n paddingTop: 16,\n },\n skillsUl: {\n listStyleType: 'none',\n },\n skillsTitle: {\n paddingBottom: 16,\n borderBottom: '1px solid rgba(0,0,0,0.08)',\n },\n skillsActivities: {\n marginTop: 32,\n marginBottom: 48,\n },\n contentDrawer: {\n paddingLeft: 16,\n paddingRight: 16,\n paddingTop: 24,\n paddingBottom: 24,\n width: 560,\n },\n contentHeader: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginBottom: 16,\n width: 560,\n paddingTop: 24,\n paddingLeft: 16,\n paddingRight: 16,\n },\n closeButton: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n paddingTop: 16,\n paddingRight: 16,\n },\n image: {\n height: 64,\n minHeight: 64,\n width: 64,\n minWidth: 64,\n marginRight: 16,\n },\n });\n});\nvar BulkOutcomeDrawer = function () {\n var _a, _b, _c, _d, _e;\n var typo = useTypography();\n var classes = useStyles();\n var _f = useContext(InsightsContext), outcome = _f.outcome, assignableOutcomes = _f.assignableOutcomes, setAssignableOutcomes = _f.setAssignableOutcomes, outcomeDrawerOpen = _f.outcomeDrawerOpen, setOutcomeDrawerOpen = _f.setOutcomeDrawerOpen;\n var togglePopover = function () { return setOutcomeDrawerOpen(!outcomeDrawerOpen); };\n var selectOutcome = function () {\n var newAssignableOutcomes = __spreadArray([], __read((assignableOutcomes !== null && assignableOutcomes !== void 0 ? assignableOutcomes : [])), false);\n if (newAssignableOutcomes) {\n newAssignableOutcomes.forEach(function (el) {\n if (el.id === (outcome === null || outcome === void 0 ? void 0 : outcome.id)) {\n outcome.selected = !outcome.selected;\n }\n });\n setAssignableOutcomes(newAssignableOutcomes);\n }\n };\n if (!outcome) {\n return null;\n }\n return (_jsxs(Drawer, __assign({ open: outcomeDrawerOpen, anchor: \"right\", role: \"complementary\", onClose: togglePopover }, { children: [_jsx(\"div\", __assign({ className: classes.closeButton }, { children: _jsx(IconButton, __assign({ onClick: togglePopover }, { children: _jsx(X, {}, void 0) }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.contentHeader }, { children: _jsxs(\"div\", __assign({ style: { display: 'flex' } }, { children: [_jsx(\"img\", { alt: \"\", className: classes.image, src: \"\" + OUTCOMES_PATH + (outcome === null || outcome === void 0 ? void 0 : outcome.image) + \".svg\" }, void 0), _jsxs(\"div\", __assign({ style: { marginLeft: 16 } }, { children: [_jsx(\"div\", __assign({ className: classes.name }, { children: outcome.name }), void 0), _jsx(\"div\", __assign({ className: classes.addText }, { children: _jsx(Button, __assign({ onClick: selectOutcome, style: { width: 275, height: 36 } }, { children: !outcome.selected ? 'Add Outcome to Assignment' : 'Remove from Assignment' }), void 0) }), void 0)] }), void 0)] }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.contentDrawer }, { children: [_jsx(BulkDetailOverview, { videoOverviewId: (_a = outcome === null || outcome === void 0 ? void 0 : outcome.videoOverviewId) !== null && _a !== void 0 ? _a : -1, description: outcome.description, type: \"outcome\", assignerName: (_c = (_b = outcome.assignment) === null || _b === void 0 ? void 0 : _b.assignerName) !== null && _c !== void 0 ? _c : '', assignedDate: (_e = (_d = outcome.assignment) === null || _d === void 0 ? void 0 : _d.dateTime) !== null && _e !== void 0 ? _e : '', isAssigned: outcome === null || outcome === void 0 ? void 0 : outcome.isAssigned, skillOrOutcome: outcome }, void 0), _jsx(\"div\", __assign({ className: classes.skillsActivities }, { children: _jsxs(\"div\", __assign({ className: classes.skills }, { children: [_jsx(\"h4\", __assign({ className: clsx(typo.h5, classes.skillsTitle) }, { children: \"All Skills\" }), void 0), _jsx(ListOfSkills, {}, void 0)] }), void 0) }), void 0)] }), void 0)] }), void 0));\n};\nvar ListOfSkills = function () {\n var _a, _b;\n var _c = useContext(InsightsContext), allSkills = _c.allSkills, outcome = _c.outcome;\n var listRef = useRovingTabIndex();\n if (!outcome) {\n return null;\n }\n return (_jsx(\"ul\", __assign({ style: { listStyleType: 'none', paddingInlineStart: 0 }, ref: listRef }, { children: (_b = (_a = outcome === null || outcome === void 0 ? void 0 : outcome.skills) === null || _a === void 0 ? void 0 : _a.map(function (skill) { return skill.id; })) === null || _b === void 0 ? void 0 : _b.map(function (skillId, index) {\n var skill = allSkills === null || allSkills === void 0 ? void 0 : allSkills.find(function (skill) { return skill.id === skillId; });\n if (!skill) {\n return null;\n }\n return (_jsx(\"li\", { children: _jsx(Skill, { noLink: true, page: Pages.None, skill: skill, describedById: \"Skill\", noProgress: true, tabIndex: index === 0 ? 0 : -1 }, skill.name + skill.current.targetLevel) }, 'skill-' + skillId));\n }) }), void 0));\n};\nexport default BulkOutcomeDrawer;\n//# sourceMappingURL=BulkOutcomeDrawer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nvar __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\n if (ar || !(i in from)) {\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\n ar[i] = from[i];\n }\n }\n return to.concat(ar || Array.prototype.slice.call(from));\n};\nimport { jsxs as _jsxs, jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { useHistory } from 'react-router-dom';\nimport { Accordion, AccordionSummary, makeStyles } from '@material-ui/core';\nimport BulkOutcomePicker from './BulkOutcomePicker';\nimport BulkTargetLevelPicker from './BulkTargetLevelPicker';\nimport BulkAssignConfirm from './BulkAssignConfirm';\nimport { InsightsContext } from '../../contexts/InsightsProvider';\nimport BulkOutcomeDrawer from './BulkOutcomeDrawer';\nimport { BulkAssignPanel } from '../../types/types';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { useTypography } from '../../styles/Typography';\nimport { useGetInsightsData } from '../../hooks/useGetInsightsData';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n root: {\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n accordion: (_a = {\n width: 1040,\n padding: 0,\n marginBottom: 32\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n text: {\n height: '100%',\n width: '100% ',\n display: 'flex',\n justifyContent: 'flex-start',\n alignItems: 'center',\n },\n });\n});\nvar BulkAssignOutcomes = function (_a) {\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var _b = useContext(InsightsContext), setOutcome = _b.setOutcome, assignableOutcomes = _b.assignableOutcomes, setAssignableOutcomes = _b.setAssignableOutcomes, reports = _b.reports, panel = _b.panel, setPanel = _b.setPanel, setOutcomeDrawerOpen = _b.setOutcomeDrawerOpen;\n var history = useHistory();\n var _c = __read(useState(false), 2), didSetHeader = _c[0], setDidSetHeader = _c[1];\n var _d = useContext(HeaderContext), setTitle = _d.setTitle, setGoBack = _d.setGoBack, setTabs = _d.setTabs;\n var getInsightsData = useGetInsightsData();\n useEffect(function () {\n if (!didSetHeader) {\n setTitle('Bulk Assign');\n setGoBack(true);\n setTabs(undefined);\n setDidSetHeader(true);\n }\n }, [didSetHeader, setGoBack, setTabs, setTitle]);\n useEffect(function () {\n if (!panel || panel === BulkAssignPanel.Unknown) {\n setPanel(BulkAssignPanel.OutcomePicker);\n }\n }, [panel, reports, setPanel]);\n useEffect(function () {\n if (!assignableOutcomes || assignableOutcomes.length === 0) {\n getInsightsData();\n }\n });\n var closeOutcomePicker = function () {\n setPanel(BulkAssignPanel.TargetLevelPicker);\n };\n var closeTargetLevelPicker = function () {\n setPanel(BulkAssignPanel.Confirm);\n };\n var closeConfirm = function () {\n setPanel(BulkAssignPanel.Unknown);\n var newAssignableOutcomes = __spreadArray([], __read((assignableOutcomes !== null && assignableOutcomes !== void 0 ? assignableOutcomes : [])), false);\n if (newAssignableOutcomes) {\n newAssignableOutcomes.forEach(function (el) {\n el.selected = false;\n });\n setAssignableOutcomes(newAssignableOutcomes);\n }\n history.push(page + \"/history-insights\");\n };\n var openOutcomePicker = function () {\n setPanel(BulkAssignPanel.OutcomePicker);\n };\n var openTargetLevelPicker = function () {\n setPanel(BulkAssignPanel.TargetLevelPicker);\n };\n var openDrawer = function (outcome) {\n setOutcome(outcome);\n setOutcomeDrawerOpen(true);\n };\n return (_jsxs(\"main\", __assign({ className: classes.root }, { children: [_jsx(\"div\", __assign({ className: classes.accordion }, { children: _jsx(Accordion, __assign({ expanded: false }, { children: _jsx(AccordionSummary, __assign({ \"aria-controls\": \"panel1c-content\", id: \"panel1c-header\", style: { height: 72 }, onClick: closeConfirm }, { children: _jsx(\"div\", __assign({ className: classes.text }, { children: _jsxs(\"h3\", __assign({ className: typo.h5, style: { fontWeight: 'normal' } }, { children: [\"Step 1: \", reports.length, \" Users Selected\"] }), void 0) }), void 0) }), void 0) }), void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.accordion }, { children: _jsx(BulkOutcomePicker, { onClose: closeOutcomePicker, goBack: openOutcomePicker, openDrawer: openDrawer }, void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.accordion }, { children: _jsx(BulkTargetLevelPicker, { onClose: closeTargetLevelPicker, goBack: openTargetLevelPicker }, void 0) }), void 0), _jsx(\"div\", __assign({ className: classes.accordion }, { children: _jsx(BulkAssignConfirm, { onClose: closeConfirm }, void 0) }), void 0), _jsx(BulkOutcomeDrawer, {}, void 0)] }), void 0));\n};\nexport default BulkAssignOutcomes;\n//# sourceMappingURL=BulkAssignOutcomes.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { Colors } from '../utils/colors';\nimport Button from './buttons/Button';\nimport { LOGOS_PATH, MARKETING_PATH } from '../utils/constants';\nimport { useMediaQuery } from '@material-ui/core';\nimport { useTypography } from '../styles/Typography';\nimport clsx from 'clsx';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n root: {\n width: '100%',\n height: '100%',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n card: (_a = {\n width: 1088,\n height: 700,\n backgroundColor: Colors.white,\n borderRadius: 4,\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'center',\n alignItems: 'center'\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n height: 580,\n flexDirection: 'column',\n alignItems: 'flex-start',\n justifyContent: 'flex-start',\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n height: 725,\n },\n _a),\n column: {\n height: '100%',\n padding: 24,\n display: 'flex',\n flexDirection: 'column',\n justifyContent: 'flex-start',\n alignItems: 'flex-start',\n },\n text: {\n marginBottom: 32,\n },\n });\n});\nvar NoAccess = function (_a) {\n var title = _a.title, subTitle = _a.subTitle, buttonText = _a.buttonText, onClick = _a.onClick;\n var typo = useTypography();\n var classes = useStyles();\n var theme = useTheme();\n var isMdDown = useMediaQuery(theme.breakpoints.down('md'));\n return (_jsx(\"main\", __assign({ className: classes.root }, { children: _jsx(\"div\", __assign({ className: classes.card }, { children: isMdDown ? (_jsxs(_Fragment, { children: [_jsx(\"img\", { style: { marginTop: 30, width: 187, height: 39, marginBottom: 30, marginLeft: 24 }, src: LOGOS_PATH + \"logoInlinePurple.svg\", alt: \"nulia logo inline purple\" }, void 0), _jsx(\"img\", { style: { height: 221, width: '100%', objectFit: 'cover' }, src: MARKETING_PATH + \"teams_no_access.png\", alt: \"people in a meeting sitting at a table with laptops\" }, void 0), _jsxs(\"div\", __assign({ style: { alignSelf: 'center', padding: 24 } }, { children: [_jsx(\"h1\", __assign({ className: clsx(typo.h4, classes.text) }, { children: title }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.subtitle1, classes.text) }, { children: subTitle }), void 0), buttonText && onClick && (_jsx(Button, __assign({ onClick: onClick, style: { width: 219, height: 38, color: '#fff', backgroundColor: '#57599B' } }, { children: buttonText }), void 0))] }), void 0)] }, void 0)) : (_jsxs(_Fragment, { children: [_jsxs(\"div\", __assign({ className: classes.column }, { children: [_jsx(\"img\", { style: { marginTop: 65, width: 187, height: 39, marginBottom: 150 }, src: LOGOS_PATH + \"logoInlinePurple.svg\", alt: \"nulia logo inline purple\" }, void 0), _jsxs(\"div\", __assign({ style: { alignSelf: 'center' } }, { children: [_jsx(\"h1\", __assign({ className: clsx(typo.h4, classes.text) }, { children: title }), void 0), _jsx(\"h2\", __assign({ className: clsx(typo.subtitle1, classes.text) }, { children: subTitle }), void 0), buttonText && onClick && (_jsx(Button, __assign({ onClick: onClick, style: { width: 219, height: 38, color: '#fff', backgroundColor: '#57599B' } }, { children: buttonText }), void 0))] }), void 0)] }), void 0), _jsx(\"div\", { children: _jsx(\"img\", { src: MARKETING_PATH + \"teams_no_access.png\", alt: \"people in a meeting sitting at a table with laptops\" }, void 0) }, void 0)] }, void 0)) }), void 0) }), void 0));\n};\nexport default NoAccess;\n//# sourceMappingURL=NoAccess.js.map","import { jsx as _jsx, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport NoAccess from './NoAccess';\nvar NoAccount = function () {\n return (_jsx(_Fragment, { children: _jsx(NoAccess, { title: \"You\\u2019re almost there!\", subTitle: \"It looks like your organization is ready to unlock the value of Office 365 with the Nulia Works. All you need now is a Nulia Works license. Reach out to your manager or IT Administrator to find out how.\" }, void 0) }, void 0));\n};\nexport default NoAccount;\n//# sourceMappingURL=NoAccount.js.map","import { jsx as _jsx } from \"react/jsx-runtime\";\nimport NoAccess from './NoAccess';\nvar NoNulia = function () {\n var onAccept = function () {\n sessionStorage.clear();\n window.location.reload();\n };\n return (_jsx(NoAccess, { title: \"Session Expired\", subTitle: \"Sorry, your login session has expired. Please log in again.\", buttonText: \"Login\", onClick: onAccept }, void 0));\n};\nexport default NoNulia;\n//# sourceMappingURL=TokenExpired.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport NoAccess from './NoAccess';\nvar NoNulia = function () {\n var demo = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n window.open('https://nulia.com', '_blank');\n return [2];\n });\n }); };\n return (_jsx(NoAccess, { title: \"Interested in Nulia Works?\", subTitle: \"Your organization needs to be subscribed to Nulia Works to access this app. To learn more, visit our website.\", buttonText: \"VISIT WEBSITE\", onClick: demo }, void 0));\n};\nexport default NoNulia;\n//# sourceMappingURL=NoNulia.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { BASE_API_URL } from '../utils/constants';\nimport { HelperApi } from './HelperApi';\nvar HowToApi = (function () {\n function HowToApi(token, oid, tid, sid, clientType) {\n var _this = this;\n this.howtoCategories = function () { return __awaiter(_this, void 0, void 0, function () {\n var url, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/HowtoCategories\";\n headers = this.helperApi.getHeaders();\n if (!headers) {\n return [2, undefined];\n }\n return [4, this.helperApi.get(url, headers)];\n case 1: return [2, _a.sent()];\n }\n });\n }); };\n this.howtoPlaylist = function (categoryId) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/HowtoPlaylist\";\n body = {\n id: categoryId,\n };\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.howtos = function (playlistId) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/HowtosByPlaylist\";\n body = {\n id: playlistId,\n };\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.viewedHowTo = function (playlistId) { return __awaiter(_this, void 0, void 0, function () {\n var url, body, headers;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n url = BASE_API_URL + \"/ViewedHowto\";\n body = {\n id: playlistId,\n };\n return [4, this.helperApi.getHeaders()];\n case 1:\n headers = _a.sent();\n if (!headers) {\n return [2];\n }\n return [4, this.helperApi.post(url, body, headers)];\n case 2: return [2, _a.sent()];\n }\n });\n }); };\n this.token = token;\n this.oid = oid;\n this.tid = tid;\n this.sid = sid;\n this.clientType = clientType;\n this.helperApi = new HelperApi(token, oid, tid, sid, clientType);\n }\n return HowToApi;\n}());\nexport { HowToApi };\n//# sourceMappingURL=HowToApi.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { HowToApi } from '../data/HowToApi';\nvar HowToService = (function () {\n function HowToService(token, oid, tid, sid, clientType) {\n var _this = this;\n this.howtoCategories = function () { return __awaiter(_this, void 0, void 0, function () {\n var howToSummary;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.howToApi.howtoCategories()];\n case 1:\n howToSummary = _a.sent();\n if (!(howToSummary === null || howToSummary === void 0 ? void 0 : howToSummary.data)) {\n return [2, undefined];\n }\n return [2, howToSummary.data];\n }\n });\n }); };\n this.howtoPlaylist = function (categoryId) { return __awaiter(_this, void 0, void 0, function () {\n var howToPlaylist;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.howToApi.howtoPlaylist(categoryId)];\n case 1:\n howToPlaylist = _a.sent();\n if (!(howToPlaylist === null || howToPlaylist === void 0 ? void 0 : howToPlaylist.data)) {\n return [2, undefined];\n }\n return [2, howToPlaylist.data];\n }\n });\n }); };\n this.howtos = function (playlistId) { return __awaiter(_this, void 0, void 0, function () {\n var howTo;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.howToApi.howtos(playlistId)];\n case 1:\n howTo = _a.sent();\n if (!(howTo === null || howTo === void 0 ? void 0 : howTo.data)) {\n return [2, undefined];\n }\n return [2, howTo.data];\n }\n });\n }); };\n this.viewedHowTo = function (playlistId) { return __awaiter(_this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, this.howToApi.viewedHowTo(playlistId)];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n this.token = token;\n this.clientType = clientType;\n this.howToApi = new HowToApi(token, oid, tid, sid, clientType);\n }\n return HowToService;\n}());\nexport { HowToService };\n//# sourceMappingURL=HowToService.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useState, createContext } from 'react';\nexport var HowToContext = createContext({});\nexport var HowToProvider = function (_a) {\n var children = _a.children;\n var _b = __read(useState(undefined), 2), playlists = _b[0], setPlaylists = _b[1];\n var _c = __read(useState(undefined), 2), howTos = _c[0], setHowTos = _c[1];\n var _d = __read(useState([]), 2), breadcrumbs = _d[0], setBreadcrumbs = _d[1];\n var howToContext = {\n playlists: playlists,\n setPlaylists: setPlaylists,\n howTos: howTos,\n setHowTos: setHowTos,\n breadcrumbs: breadcrumbs,\n setBreadcrumbs: setBreadcrumbs,\n };\n return _jsx(HowToContext.Provider, __assign({ value: howToContext }, { children: children }), void 0);\n};\n//# sourceMappingURL=HowToContext.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useContext, useEffect, useState } from 'react';\nimport { HowToService } from '../../services/HowToService';\nimport { TokenContext } from '../../contexts/TokenContext';\nimport { getToken } from '../../utils/getToken';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { Card, ButtonBase } from '@material-ui/core';\nimport { useTypography } from '../../styles/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport Button from '../buttons/Button';\nimport { Play } from 'react-feather';\nimport { Colors } from '../../utils/colors';\nimport { BLOB_CONTAINER, IMAGE_PATH, OTHER_PATH } from '../../utils/constants';\nimport { DialogContext } from '../../contexts/DialogContext';\nimport { useHistory } from 'react-router-dom';\nimport { Pages } from '../../types/enums';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { HowToContext } from '../../contexts/HowToContext';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n main: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n flexDirection: 'column',\n },\n card: (_a = {\n padding: 32,\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n videoSection: (_b = {\n display: 'flex',\n alignItems: 'flex-start',\n justifyContent: 'space-between',\n paddingBottom: 32\n },\n _b[theme.breakpoints.down('md')] = {\n flexDirection: 'column',\n },\n _b),\n video: function (_a) {\n var _b;\n var url = _a.url;\n return (_b = {\n marginLeft: 16,\n backgroundImage: \"url(\" + url + \")\",\n backgroundSize: 'cover',\n backgroundRepeat: 'no-repeat',\n backgroundPosition: 'center',\n backgroundColor: '#EEEEF8',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n width: 433,\n minWidth: 433,\n height: 246,\n boxShadow: '0 5px 16px 1px rgba(0,0,0,0.08), 0 2px 8px 0 rgba(0,0,0,0.08)',\n gridColumn: 2\n },\n _b[theme.breakpoints.down('md')] = {\n marginLeft: 0,\n width: 440,\n minWidth: 440,\n height: 250,\n gridColumn: 1,\n },\n _b[theme.breakpoints.down('sm')] = {\n width: '100%',\n minWidth: 280,\n },\n _b);\n },\n videoButton: {\n display: 'flex',\n alignItems: 'center',\n width: 'fit-content',\n margin: 'auto',\n color: Colors.white,\n justifyContent: 'center',\n },\n videoIcon: {\n marginRight: 8,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n categoryButton: {\n width: 180,\n height: 136,\n },\n article: {\n width: 180,\n display: 'flex',\n flexDirection: 'column',\n marginRight: 24,\n marginTop: 24,\n textAlign: 'center',\n },\n });\n});\nvar HowTo = function (_a) {\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles({ url: OTHER_PATH + \"outcome_detail_video_thumbnail.jpg\" });\n var _b = useMsal(), instance = _b.instance, accounts = _b.accounts;\n var account = useAccount(accounts[0]);\n var _c = useContext(TokenContext), ssoToken = _c.ssoToken, oid = _c.oid, tid = _c.tid, clientType = _c.clientType;\n var _d = useContext(HeaderContext), setTitle = _d.setTitle, setGoBack = _d.setGoBack, setTabs = _d.setTabs, setPage = _d.setPage;\n var setBreadcrumbs = useContext(HowToContext).setBreadcrumbs;\n var _e = useContext(DialogContext), openVideoDialog = _e.openVideoDialog, setOpenVideoDialog = _e.setOpenVideoDialog, setVideoDialogContent = _e.setVideoDialogContent;\n var _f = __read(useState(undefined), 2), howToCategory = _f[0], setHowToCategory = _f[1];\n var _g = __read(useState(false), 2), receivedData = _g[0], setReceivedData = _g[1];\n var history = useHistory();\n useEffect(function () {\n setTitle(\"How To's\");\n setGoBack(false);\n setTabs(undefined);\n setPage(page !== null && page !== void 0 ? page : Pages.HowToPage);\n }, [page, setGoBack, setPage, setTabs, setTitle]);\n useEffect(function () {\n setBreadcrumbs([\n {\n name: \"How To's\",\n route: \"\" + window.location.pathname,\n },\n ]);\n }, [setBreadcrumbs]);\n var toggleVideoDialog = function () { return setOpenVideoDialog(!openVideoDialog); };\n var getHowToCategories = function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, howToService, newHowToCategory, overviewContentData;\n var _a;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _b.sent();\n howToService = new HowToService(newToken, oid, tid, clientType);\n return [4, howToService.howtoCategories()];\n case 2:\n newHowToCategory = _b.sent();\n setHowToCategory(newHowToCategory);\n setReceivedData(true);\n overviewContentData = {\n container: BLOB_CONTAINER,\n fileName: (newHowToCategory === null || newHowToCategory === void 0 ? void 0 : newHowToCategory.videoId) + \".mp4\",\n contentId: parseInt((_a = newHowToCategory === null || newHowToCategory === void 0 ? void 0 : newHowToCategory.videoId) !== null && _a !== void 0 ? _a : '0', 10),\n views: 1,\n };\n setVideoDialogContent(overviewContentData);\n return [2];\n }\n });\n }); };\n var openCategory = function (categoryId) {\n history.push(page + \"/how-to/\" + categoryId);\n };\n useEffect(function () {\n if (!receivedData) {\n getHowToCategories();\n }\n });\n return (_jsx(\"main\", __assign({ className: classes.main }, { children: _jsxs(Card, __assign({ className: classes.card, elevation: 1, component: \"section\" }, { children: [_jsxs(\"div\", __assign({ className: classes.videoSection }, { children: [_jsx(\"div\", { children: howToCategory === null || howToCategory === void 0 ? void 0 : howToCategory.introduction.map(function (intro, index) { return (_jsx(\"p\", __assign({ className: typo.body1, style: { marginBottom: 16 } }, { children: intro }), index)); }) }, void 0), _jsx(\"div\", __assign({ className: classes.video }, { children: _jsx(Button, __assign({ onClick: toggleVideoDialog, style: { width: 225, minWidth: 225 } }, { children: _jsxs(\"span\", __assign({ className: classes.videoButton }, { children: [_jsx(\"span\", __assign({ \"aria-hidden\": true, className: classes.videoIcon }, { children: _jsx(Play, {}, void 0) }), void 0), \"Watch Overview\"] }), void 0) }), void 0) }), void 0)] }), void 0), _jsx(\"div\", __assign({ style: { display: 'flex', flexWrap: 'wrap' } }, { children: howToCategory === null || howToCategory === void 0 ? void 0 : howToCategory.categories.map(function (category, index) { return (_jsxs(\"article\", __assign({ className: classes.article }, { children: [_jsx(ButtonBase, __assign({ onClick: function () { return openCategory(category.id); }, className: classes.categoryButton }, { children: _jsx(\"img\", { width: \"100%\", height: \"100%\", src: \"\" + IMAGE_PATH + category.image, alt: \"\" }, void 0) }), void 0), _jsx(\"span\", { children: category.name }, void 0)] }), index)); }) }), void 0)] }), void 0) }), void 0));\n};\nexport default HowTo;\n//# sourceMappingURL=HowTo.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { useContext } from 'react';\nimport { makeStyles, Breadcrumbs, Link } from '@material-ui/core';\nimport { useHistory } from 'react-router-dom';\nimport clsx from 'clsx';\nimport { useTypography } from '../../styles/Typography';\nimport { HowToContext } from '../../contexts/HowToContext';\nimport { ChevronRight } from 'react-feather';\nimport { Colors } from '../../utils/colors';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n breadcrumbs: (_a = {\n display: 'flex',\n justifyContent: 'flex-start',\n alignItems: 'center',\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n text: {\n '&:hover': {\n color: Colors.textPrimary,\n },\n cursor: 'pointer',\n },\n chevron: {\n marginLeft: 8,\n marginRight: 8,\n marginBottom: -4,\n },\n breadcrumb: {\n display: 'flex',\n alignItems: 'center',\n },\n current: {\n '&:hover': {\n textDecoration: 'none',\n },\n },\n });\n});\nvar HowToBreadcrumbs = function () {\n var typo = useTypography();\n var classes = useStyles();\n var history = useHistory();\n var breadcrumbs = useContext(HowToContext).breadcrumbs;\n var isCurrent = function (breadcrumb) {\n return (breadcrumb === null || breadcrumb === void 0 ? void 0 : breadcrumb.route) === '' || (breadcrumb === null || breadcrumb === void 0 ? void 0 : breadcrumb.route) === window.location.pathname;\n };\n var onClick = function (breadcrumb) { return function (event) {\n if (breadcrumb) {\n if (isCurrent(breadcrumb)) {\n return;\n }\n history.push(breadcrumb.route);\n return;\n }\n history.push('/how-to');\n }; };\n return (_jsx(\"div\", __assign({ className: classes.breadcrumbs }, { children: _jsx(Breadcrumbs, __assign({ separator: _jsx(ChevronRight, {}, void 0), \"aria-label\": \"breadcrumb\" }, { children: breadcrumbs === null || breadcrumbs === void 0 ? void 0 : breadcrumbs.map(function (breadcrumb) { return (_jsx(Link, __assign({ className: clsx(classes.text, typo.body1), style: isCurrent(breadcrumb)\n ? { color: Colors.purple, fontWeight: 800, letterSpacing: '0.5px', cursor: 'default' }\n : { color: Colors.purple, fontWeight: 800, letterSpacing: '0.5px' }, onClick: onClick(breadcrumb), classes: isCurrent(breadcrumb) ? { underlineHover: classes.current } : undefined }, { children: breadcrumb === null || breadcrumb === void 0 ? void 0 : breadcrumb.name }), breadcrumb === null || breadcrumb === void 0 ? void 0 : breadcrumb.name)); }) }), void 0) }), void 0));\n};\nexport default HowToBreadcrumbs;\n//# sourceMappingURL=HowToBreadcrumbs.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Card, Divider, Link as MuiLink } from '@material-ui/core';\nimport { useContext, useEffect, useState } from 'react';\nimport { useTypography } from '../../styles/Typography';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useParams } from 'react-router';\nimport { IMAGE_PATH } from '../../utils/constants';\nimport { Pages } from '../../types/enums';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport { Link } from 'react-router-dom';\nimport { useGetHowToPlaylist } from '../../hooks/useGetHowToPlaylist';\nimport { HowToContext } from '../../contexts/HowToContext';\nimport HowToBreadcrumbs from './HowToBreadcrumbs';\nimport clsx from 'clsx';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b, _c;\n return ({\n main: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n flexDirection: 'column',\n },\n card: (_a = {\n padding: 32,\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n title: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n howTos: {\n display: 'flex',\n flexWrap: 'wrap',\n },\n howTo: (_b = {\n width: '50%',\n display: 'flex',\n padding: 16\n },\n _b[theme.breakpoints.down('md')] = {\n width: '100%',\n },\n _b),\n link: (_c = {\n display: 'flex',\n textAlign: 'left',\n alignItems: 'flex-start',\n textDecoration: 'none',\n justifyContent: 'center',\n '&:hover': {\n textDecoration: 'none',\n }\n },\n _c[theme.breakpoints.down('sm')] = {\n flexDirection: 'column',\n },\n _c),\n fiveLineEllipsis: {\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n display: '-webkit-box',\n '-webkit-line-clamp': 5,\n '-webkit-box-orient': 'vertical',\n },\n });\n});\nvar HowToCategory = function (_a) {\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var categoryId = useParams().categoryId;\n var _b = useContext(HowToContext), playlists = _b.playlists, setPlaylists = _b.setPlaylists;\n var _c = useContext(HeaderContext), setTitle = _c.setTitle, setGoBack = _c.setGoBack, setTabs = _c.setTabs, setPage = _c.setPage;\n var setBreadcrumbs = useContext(HowToContext).setBreadcrumbs;\n var _d = __read(useState(false), 2), receivedData = _d[0], setReceivedData = _d[1];\n var getHowToPlaylist = useGetHowToPlaylist(categoryId);\n useEffect(function () {\n return function () { return setPlaylists(undefined); };\n }, [setPlaylists]);\n useEffect(function () {\n setTitle(\"How To's\");\n setGoBack(true);\n setTabs(undefined);\n setPage(page !== null && page !== void 0 ? page : Pages.HowToPage);\n }, [page, setGoBack, setPage, setTabs, setTitle]);\n useEffect(function () {\n setBreadcrumbs([\n {\n name: \"How To's\",\n route: page + \"/how-to\",\n },\n {\n name: playlists ? playlists[0].categoryName : '',\n route: \"\" + window.location.pathname,\n },\n ]);\n }, [page, playlists, setBreadcrumbs]);\n useEffect(function () {\n if (!receivedData) {\n getHowToPlaylist();\n setReceivedData(true);\n }\n }, [getHowToPlaylist, receivedData]);\n return (_jsx(\"main\", __assign({ className: classes.main }, { children: _jsxs(Card, __assign({ className: classes.card, elevation: 1, component: \"section\" }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: _jsx(HowToBreadcrumbs, {}, void 0) }), void 0), _jsx(Divider, {}, void 0), _jsx(\"div\", __assign({ className: classes.howTos }, { children: playlists === null || playlists === void 0 ? void 0 : playlists.map(function (howTo, index) { return (_jsx(\"article\", __assign({ className: classes.howTo }, { children: _jsxs(MuiLink, __assign({ component: Link, to: page + \"/how-to-playlist/\" + howTo.id + \"/\" + howTo.title + \"/\" + howTo.categoryName + \"/\" + howTo.categoryId, className: classes.link }, { children: [_jsx(\"img\", { width: 180, height: 130, src: \"\" + IMAGE_PATH + howTo.image, alt: \"\", style: { marginRight: 16, minWidth: 180, minHeight: 130 } }, void 0), _jsxs(\"div\", { children: [_jsx(\"h3\", __assign({ className: typo.h6 }, { children: howTo.title }), void 0), _jsx(\"p\", __assign({ className: clsx(typo.body2, classes.fiveLineEllipsis) }, { children: howTo.description }), void 0)] }, void 0)] }), void 0) }), index)); }) }), void 0)] }), void 0) }), void 0));\n};\nexport default HowToCategory;\n//# sourceMappingURL=HowToCategory.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nimport { HowToService } from '../services/HowToService';\nimport { HowToContext } from '../contexts/HowToContext';\nexport var useGetHowToPlaylist = function (categoryId) {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var howToContext = useContext(HowToContext);\n var getUser = useGetUser();\n var getHowToPlaylist = function (categoryId) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, howToService, newPlaylists;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n howToService = new HowToService(newToken, oid, tid, clientType);\n return [4, howToService.howtoPlaylist(categoryId)];\n case 2:\n newPlaylists = _a.sent();\n if (!newPlaylists) {\n return [2];\n }\n howToContext.setPlaylists(newPlaylists);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser(), getHowToPlaylist(categoryId)])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetHowToPlaylist.js.map","import { default as SelectItem } from '@material-ui/core/MenuItem';\nexport default SelectItem;\n//# sourceMappingURL=SelectItem.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport Select from '../select/Select';\nimport SelectItem from '../select/SelectItem';\nimport { makeStyles, useTheme } from '@material-ui/core/styles';\nimport { useMediaQuery } from '@material-ui/core';\nvar useStyles = makeStyles(function (theme) { return ({\n root: {\n display: 'flex',\n justifyContent: 'space-between',\n alignItems: 'center',\n marginTop: 16,\n marginBottom: 16,\n },\n}); });\nvar SelectStepper = function (_a) {\n var maxSteps = _a.maxSteps, activeStep = _a.activeStep, titles = _a.titles, handleOnChange = _a.handleOnChange, nextButton = _a.nextButton, backButton = _a.backButton;\n var classes = useStyles();\n var theme = useTheme();\n var isSmDown = useMediaQuery(theme.breakpoints.down('sm'));\n return (_jsxs(\"div\", __assign({ className: classes.root }, { children: [backButton, _jsx(Select, __assign({ value: activeStep, onChange: handleOnChange, light: true, style: !isSmDown ? { width: 300 } : { width: 100 } }, { children: titles.map(function (value, index) { return (_jsx(SelectItem, __assign({ value: index }, { children: value }), index)); }) }), void 0), nextButton] }), void 0));\n};\nexport default SelectStepper;\n//# sourceMappingURL=SelectStepper.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from \"react/jsx-runtime\";\nimport { IconButton, makeStyles } from '@material-ui/core';\nimport { useTheme } from '@material-ui/core/styles';\nimport useMediaQuery from '@material-ui/core/useMediaQuery';\nimport { useEffect, useRef, useState } from 'react';\nimport { pdfjs, Document, Page } from 'react-pdf';\nimport { Colors } from '../../utils/colors';\nimport { ChevronLeft, ChevronRight, ZoomIn, ZoomOut } from 'react-feather';\nvar useStyles = makeStyles(function (theme) {\n var _a;\n return ({\n controls: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n height: 24,\n },\n pager: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n marginRight: 16,\n },\n pageText: {\n color: Colors.textPrimary,\n fontFamily: 'Ubuntu',\n fontSize: 14,\n letterSpacing: 0.1,\n lineHeight: '24px',\n },\n zoom: {\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n },\n margin: {\n marginRight: '8px !important',\n },\n dialogContent: {\n padding: 0,\n position: 'relative',\n },\n document: {\n display: 'flex',\n justifyContent: 'center',\n },\n documentAbsolute: {\n position: 'absolute',\n top: 0,\n left: 0,\n },\n contentRater: (_a = {\n marginRight: 16\n },\n _a[theme.breakpoints.only('xs')] = {\n marginRight: 12,\n },\n _a),\n button: {\n border: 'none',\n padding: 0,\n margin: 0,\n textDecoration: 'none',\n background: 'transparent',\n color: Colors.textPrimary,\n fontFamily: 'Open Sans',\n fontSize: '1rem',\n cursor: 'pointer',\n textAlign: 'center',\n transition: 'background 250ms ease-in-out, transform 150ms ease',\n '-webkit-appearance': 'none',\n '-moz-appearance': 'none',\n '&:focus': {\n outline: 0,\n },\n '&:disabled': {\n color: Colors.disabled,\n boxShadow: 'none',\n cursor: 'not-allowed',\n },\n height: 24,\n width: 24,\n },\n srOnly: {\n position: 'absolute',\n right: 10000,\n },\n overflow: {\n overflow: 'auto',\n },\n });\n});\nvar PdfViewer = function (_a) {\n var src = _a.src;\n var classes = useStyles();\n var theme = useTheme();\n var isLargeUp = useMediaQuery(theme.breakpoints.up('lg'));\n var _b = __read(useState(isLargeUp ? 1.25 : 1), 2), scale = _b[0], setScale = _b[1];\n var _c = __read(useState(1), 2), pageNumber = _c[0], setPageNumber = _c[1];\n var _d = __read(useState(1), 2), currentNumPages = _d[0], setNumPages = _d[1];\n var pdfRef = useRef(null);\n useEffect(function () {\n pdfjs.GlobalWorkerOptions.workerSrc = \"//cdnjs.cloudflare.com/ajax/libs/pdf.js/\" + pdfjs.version + \"/pdf.worker.js\";\n }, []);\n var onDocumentComplete = function (_a) {\n var numPages = _a.numPages;\n setNumPages(numPages);\n };\n var handleBack = function () { return setPageNumber(pageNumber === 1 ? 1 : pageNumber - 1); };\n var handleNext = function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n setPageNumber(pageNumber === currentNumPages ? pageNumber : pageNumber + 1);\n return [2];\n });\n }); };\n var zoomIn = function () { return setScale(scale + 0.25); };\n var zoomOut = function () { return setScale(scale - 0.25); };\n return (_jsxs(_Fragment, { children: [_jsx(\"div\", __assign({ className: classes.document }, { children: _jsx(Document, __assign({ className: classes.overflow, file: src, onLoadSuccess: onDocumentComplete, ref: pdfRef }, { children: _jsx(Page, { pageNumber: pageNumber, scale: scale, renderMode: \"canvas\", renderTextLayer: true, width: 970 }, void 0) }), void 0) }), void 0), _jsxs(\"div\", __assign({ className: classes.controls }, { children: [_jsxs(\"div\", __assign({ className: classes.pager }, { children: [_jsx(\"div\", __assign({ className: classes.margin }, { children: \"Page \" + pageNumber + \" of \" + currentNumPages }), void 0), _jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"left arrow\", onClick: handleBack, disabled: pageNumber === 1 }, { children: _jsx(ChevronLeft, {}, void 0) }), void 0), _jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"right arrow\", onClick: handleNext, disabled: pageNumber === currentNumPages }, { children: _jsx(ChevronRight, {}, void 0) }), void 0)] }), void 0), _jsxs(\"div\", __assign({ className: classes.zoom }, { children: [_jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"zoom out\", onClick: zoomOut }, { children: _jsx(ZoomOut, {}, void 0) }), void 0), _jsx(IconButton, __assign({ className: classes.button, \"aria-label\": \"zoom in\", onClick: zoomIn }, { children: _jsx(ZoomIn, {}, void 0) }), void 0)] }), void 0)] }), void 0)] }, void 0));\n};\nexport default PdfViewer;\n//# sourceMappingURL=PdfViewer.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Card, Divider } from '@material-ui/core';\nimport { useContext, useEffect, useState, useRef } from 'react';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useTypography } from '../../styles/Typography';\nimport { useParams } from 'react-router';\nimport { HowToType, Pages } from '../../types/enums';\nimport { HeaderContext } from '../../contexts/HeaderContext';\nimport Button from '../buttons/Button';\nimport { useGetHowTos } from '../../hooks/useGetHowTos';\nimport { HowToContext } from '../../contexts/HowToContext';\nimport Loading from '../Loading';\nimport SelectStepper from '../Stepper/SelectStepper';\nimport { useViewedHowTo } from '../../hooks/useViewedHowTo';\nimport HowToBreadcrumbs from './HowToBreadcrumbs';\nimport VideoPlayer from '../video/VideoPlayer';\nimport PdfViewer from '../pdf/PdfViewer';\nimport IframeResizer from 'iframe-resizer-react';\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n main: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n flexDirection: 'column',\n marginBottom: 16,\n height: '100%',\n },\n card: (_a = {\n display: 'flex',\n flexDirection: 'column',\n minHeight: 'calc(100vh - 115px)',\n padding: 32,\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n title: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n },\n howTos: {\n display: 'flex',\n flexWrap: 'wrap',\n },\n howTo: (_b = {\n width: '50%',\n display: 'flex',\n padding: 16\n },\n _b[theme.breakpoints.down('md')] = {\n width: '100%',\n },\n _b),\n });\n});\nvar HowToPlaylist = function (_a) {\n var _b, _c;\n var page = _a.page;\n var classes = useStyles();\n var typo = useTypography();\n var playlistId = useParams().playlistId;\n var playlistTitle = useParams().playlistTitle;\n var categoryName = useParams().categoryName;\n var categoryId = useParams().categoryId;\n var _d = useContext(HowToContext), breadcrumbs = _d.breadcrumbs, setBreadcrumbs = _d.setBreadcrumbs, howTos = _d.howTos, setHowTos = _d.setHowTos;\n var _e = useContext(HeaderContext), setTitle = _e.setTitle, setGoBack = _e.setGoBack, setTabs = _e.setTabs, setPage = _e.setPage;\n var _f = __read(useState(0), 2), selected = _f[0], setSelected = _f[1];\n var _g = __read(useState(false), 2), receivedData = _g[0], setReceivedData = _g[1];\n var _h = __read(useState(false), 2), updatedBreadcrumbs = _h[0], setUpdatedBreadcrumbs = _h[1];\n var getHowTos = useGetHowTos(playlistId);\n var telemetry = useViewedHowTo();\n var iframeRef = useRef(null);\n useEffect(function () {\n return function () { return setHowTos(undefined); };\n }, [setHowTos]);\n useEffect(function () {\n setTitle(\"How To's\");\n setGoBack(true);\n setTabs(undefined);\n setPage(page !== null && page !== void 0 ? page : Pages.HowToPage);\n }, [page, setGoBack, setPage, setTabs, setTitle]);\n useEffect(function () {\n if (!receivedData) {\n getHowTos();\n setReceivedData(true);\n }\n }, [getHowTos, howTos, receivedData]);\n useEffect(function () {\n if (!howTos) {\n return;\n }\n telemetry(howTos[selected].id);\n }, [selected]);\n useEffect(function () {\n var _a, _b;\n if (!howTos || updatedBreadcrumbs) {\n return;\n }\n if (!breadcrumbs || !breadcrumbs[0] || !breadcrumbs[1]) {\n setBreadcrumbs([\n {\n name: \"How To's\",\n route: page + \"/how-to\",\n },\n {\n name: categoryName,\n route: page + \"/how-to/\" + categoryId,\n },\n {\n name: howTos.length ? (_a = howTos[0]) === null || _a === void 0 ? void 0 : _a.playlistTitle : playlistTitle,\n route: '',\n },\n ]);\n }\n else {\n setBreadcrumbs([\n breadcrumbs[0],\n breadcrumbs[1],\n {\n name: howTos.length ? (_b = howTos[0]) === null || _b === void 0 ? void 0 : _b.playlistTitle : playlistTitle,\n route: '',\n },\n ]);\n }\n setUpdatedBreadcrumbs(true);\n }, [breadcrumbs, howTos, page, setBreadcrumbs, updatedBreadcrumbs, playlistTitle, categoryName, categoryId]);\n var maxSteps = (_b = howTos === null || howTos === void 0 ? void 0 : howTos.length) !== null && _b !== void 0 ? _b : 0;\n var handleNext = function (event) {\n event.preventDefault();\n setSelected(selected > maxSteps ? maxSteps : selected + 1);\n };\n var handleBack = function (event) {\n event.preventDefault();\n setSelected(selected < 0 ? 0 : selected - 1);\n };\n var handleChange = function (event) {\n setSelected(event.target.value);\n };\n return (_jsx(\"main\", __assign({ className: classes.main }, { children: _jsxs(Card, __assign({ className: classes.card, elevation: 1, component: \"section\" }, { children: [_jsx(\"div\", __assign({ className: classes.title }, { children: _jsx(HowToBreadcrumbs, {}, void 0) }), void 0), _jsx(Divider, {}, void 0), _jsx(SelectStepper, { maxSteps: maxSteps, activeStep: selected, titles: (_c = howTos === null || howTos === void 0 ? void 0 : howTos.map(function (value) { return value.title; })) !== null && _c !== void 0 ? _c : [], handleOnChange: handleChange, nextButton: _jsx(Button, __assign({ \"aria-label\": \"next\", onClick: handleNext, disabled: selected === maxSteps - 1 || maxSteps === 0 }, { children: \"Next\" }), void 0), backButton: _jsx(Button, __assign({ \"aria-label\": \"previous\", onClick: handleBack, disabled: selected === 0 }, { children: \"Back\" }), void 0) }, void 0), _jsx(Divider, {}, void 0), (howTos === null || howTos === void 0 ? void 0 : howTos.length) === 0 ? (_jsx(\"p\", __assign({ className: typo.body1, style: { marginTop: 10 } }, { children: \"Sorry, there are no associated topics.\" }), void 0)) : howTos === undefined || howTos[selected] === undefined ? (_jsx(Loading, {}, void 0)) : howTos[selected].type === HowToType.HTML ? (_jsx(IframeResizer, { forwardRef: iframeRef, title: \"Html Knowledge Articles\", src: howTos[selected].url, heightCalculationMethod: \"max\", inPageLinks: false, scrolling: true, autoResize: true, width: \"100%\", resizeFrom: \"child\", checkOrigin: false, sizeHeight: true, style: { width: '1px', minWidth: '100%', flex: 1, border: 'none', height: 'auto' } }, void 0)) : howTos[selected].type === HowToType.PDF ? (_jsx(PdfViewer, { src: howTos[selected].url }, void 0)) : howTos[selected].type === HowToType.MP4 ? (_jsx(VideoPlayer, { src: howTos[selected].url, autoPlay: false }, selected)) : (_jsx(Loading, {}, void 0))] }), void 0) }), void 0));\n};\nexport default HowToPlaylist;\n//# sourceMappingURL=HowToPlaylist.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { useGetUser } from './useGetUser';\nimport { getToken } from '../utils/getToken';\nimport { HowToService } from '../services/HowToService';\nimport { HowToContext } from '../contexts/HowToContext';\nexport var useGetHowTos = function (playlistId) {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n var howToContext = useContext(HowToContext);\n var getUser = useGetUser();\n var getHowTos = function (playlistId) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, howToService, newHowTos;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n howToService = new HowToService(newToken, oid, tid, clientType);\n return [4, howToService.howtos(playlistId)];\n case 2:\n newHowTos = _a.sent();\n if (!newHowTos) {\n return [2];\n }\n howToContext.setHowTos(newHowTos);\n return [2];\n }\n });\n }); };\n return function () { return __awaiter(void 0, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, Promise.all([getUser(), getHowTos(playlistId)])];\n case 1:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useGetHowTos.js.map","var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nimport { getToken } from '../utils/getToken';\nimport { HowToService } from '../services/HowToService';\nexport var useViewedHowTo = function () {\n var _a = useMsal(), instance = _a.instance, accounts = _a.accounts;\n var account = useAccount(accounts[0]);\n var _b = useContext(TokenContext), ssoToken = _b.ssoToken, oid = _b.oid, tid = _b.tid, clientType = _b.clientType;\n return function (playlistId) { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, howToService;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n howToService = new HowToService(newToken, oid, tid, '', clientType);\n return [4, howToService.viewedHowTo(playlistId)];\n case 2:\n _a.sent();\n return [2];\n }\n });\n }); };\n};\n//# sourceMappingURL=useViewedHowTo.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n return new (P || (P = Promise))(function (resolve, reject) {\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n step((generator = generator.apply(thisArg, _arguments || [])).next());\n });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n function verb(n) { return function (v) { return step([n, v]); }; }\n function step(op) {\n if (f) throw new TypeError(\"Generator is already executing.\");\n while (_) try {\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n if (y = 0, t) op = [op[0] & 2, t.value];\n switch (op[0]) {\n case 0: case 1: t = op; break;\n case 4: _.label++; return { value: op[1], done: false };\n case 5: _.label++; y = op[1]; op = [0]; continue;\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\n default:\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n if (t[2]) _.ops.pop();\n _.trys.pop(); continue;\n }\n op = body.call(thisArg, _);\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n }\n};\nvar __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useCallback, useContext, useEffect, useState } from 'react';\nimport { useTypography } from '../../../styles/Typography';\nimport { Paper } from '@material-ui/core';\nimport { DataGrid } from '@material-ui/data-grid';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { getToken } from '../../../utils/getToken';\nimport { BulkService } from '../../../services/BulkService';\nimport Loading from '../../Loading';\nimport { useAccount, useMsal } from '@azure/msal-react';\nimport { TokenContext } from '../../../contexts/TokenContext';\nimport { useParams } from 'react-router';\nimport getStatusColor from '../../../utils/getStatusColor';\nimport { BulkAction } from '../../../enums/BulkAction';\nimport { HeaderContext } from '../../../contexts/HeaderContext';\nimport { Tooltip } from '../../Tooltip';\nimport getStatusString from '../../../utils/getStatusString';\nvar columns = [\n { field: 'displayName', headerName: 'Display Name', width: 160, disableColumnMenu: true },\n { field: 'department', headerName: 'Department', width: 120, flex: 1, disableColumnMenu: true },\n {\n field: 'status',\n headerName: 'Status',\n width: 75,\n renderCell: function (params) { return (_jsx(Tooltip, __assign({ title: getStatusString(params.row.status) }, { children: _jsx(\"div\", { style: { width: 12, height: 12, borderRadius: 25, background: getStatusColor(params.row.status) } }, void 0) }), void 0)); },\n sortable: false,\n disableColumnMenu: true,\n },\n];\nvar useStyles = makeStyles(function (theme) {\n var _a, _b;\n return ({\n root: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n },\n content: (_a = {\n width: 1040\n },\n _a[theme.breakpoints.down('md')] = {\n width: 670,\n },\n _a[theme.breakpoints.down('sm')] = {\n width: 330,\n },\n _a),\n dataHeader: (_b = {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n marginBottom: 64\n },\n _b[theme.breakpoints.down('md')] = {\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n },\n _b),\n paper: {\n marginTop: 16,\n marginBottom: 16,\n padding: 24,\n },\n MuiGridRoot: {\n '& .MuiDataGrid-iconSeparator': {\n display: 'none',\n },\n '& .MuiDataGrid-columnHeaderTitleContainer': {\n padding: 0,\n },\n },\n });\n});\nvar HistoryDetails = function (_a) {\n var _b;\n var page = _a.page;\n var typo = useTypography();\n var classes = useStyles();\n var id = useParams().id;\n var _c = useMsal(), instance = _c.instance, accounts = _c.accounts;\n var account = useAccount(accounts[0]);\n var _d = useContext(HeaderContext), setTitle = _d.setTitle, setGoBack = _d.setGoBack, setTabs = _d.setTabs;\n var _e = useContext(TokenContext), ssoToken = _e.ssoToken, oid = _e.oid, tid = _e.tid, clientType = _e.clientType;\n var _f = __read(useState(undefined), 2), details = _f[0], setDetails = _f[1];\n var _g = __read(useState(false), 2), receivedData = _g[0], setReceivedData = _g[1];\n var _h = __read(useState(10), 2), pageSize = _h[0], setPageSize = _h[1];\n var _j = __read(useState([\n {\n field: 'displayName',\n sort: 'desc',\n },\n ]), 2), sortModel = _j[0], setSortModel = _j[1];\n useEffect(function () {\n setTitle('Back');\n setGoBack(true);\n setTabs(undefined);\n }, [setGoBack, setTabs, setTitle]);\n var getData = useCallback(function () { return __awaiter(void 0, void 0, void 0, function () {\n var newToken, bulkService, bulkHistory;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0: return [4, getToken(instance, account, ssoToken)];\n case 1:\n newToken = _a.sent();\n bulkService = new BulkService(newToken, oid, tid, clientType);\n return [4, bulkService.bulkHistoryDetail(Number(id))];\n case 2:\n bulkHistory = _a.sent();\n setDetails(bulkHistory);\n setReceivedData(true);\n return [2];\n }\n });\n }); }, [account, clientType, id, instance, oid, ssoToken, tid]);\n useEffect(function () {\n if (!receivedData) {\n getData();\n }\n }, [getData, receivedData]);\n if (!details || !receivedData) {\n return _jsx(Loading, {}, void 0);\n }\n return (_jsx(\"div\", __assign({ className: classes.root }, { children: _jsxs(\"div\", __assign({ className: classes.content }, { children: [_jsx(\"h2\", __assign({ className: typo.overline }, { children: details.action === BulkAction.OutcomeAssign\n ? 'Outcome Assign Details'\n : details.action === BulkAction.OutcomeRemove\n ? 'Outcome Unassign Details'\n : details.action === BulkAction.LicenseAssign\n ? 'License Assign Details'\n : details.action === BulkAction.LicenseRemove\n ? 'License Unassign Details'\n : '' }), void 0), _jsxs(Paper, __assign({ className: classes.paper }, { children: [_jsxs(\"dl\", __assign({ className: classes.dataHeader }, { children: [_jsx(\"dt\", __assign({ className: typo.button, style: { fontWeight: 600 } }, { children: \"Date:\" }), void 0), _jsx(\"dd\", __assign({ className: typo.body2 }, { children: details.created }), void 0), _jsx(\"dt\", __assign({ className: typo.button, style: { fontWeight: 600 } }, { children: \"Created By:\" }), void 0), _jsx(\"dd\", __assign({ className: typo.body2 }, { children: details.initiator }), void 0), _jsx(\"dt\", __assign({ className: typo.button, style: { fontWeight: 600 } }, { children: \"Progress:\" }), void 0), _jsx(\"dd\", __assign({ className: typo.body2 }, { children: details.succeeded + details.failed + \"/\" + details.total }), void 0), _jsx(\"dt\", __assign({ className: typo.button, style: { fontWeight: 600 } }, { children: \"Success:\" }), void 0), _jsx(\"dd\", __assign({ className: typo.body2 }, { children: details.succeeded }), void 0), _jsx(\"dt\", __assign({ className: typo.button, style: { fontWeight: 600 } }, { children: \"Failed:\" }), void 0), _jsx(\"dd\", __assign({ className: typo.body2 }, { children: details.failed }), void 0)] }), void 0), _jsxs(\"dl\", { children: [_jsx(\"dt\", __assign({ className: typo.button, style: { fontWeight: 600, marginBottom: 16 } }, { children: details.action === BulkAction.OutcomeAssign\n ? 'Action: Outcome(s) Assigned'\n : details.action === BulkAction.OutcomeRemove\n ? 'Action: Outcome(s) Removed'\n : details.action === BulkAction.LicenseAssign\n ? 'Action: License(s) Assigned'\n : details.action === BulkAction.LicenseRemove\n ? 'Action: License(s) Removed'\n : '' }), void 0), (_b = details.outcomes) === null || _b === void 0 ? void 0 : _b.map(function (outcome) { return (_jsx(\"dd\", __assign({ className: typo.body2 }, { children: outcome.name }), outcome.id)); })] }, void 0)] }), void 0), _jsx(Paper, __assign({ elevation: 1, style: { height: 110 + 52 * pageSize, width: '100%' } }, { children: _jsx(DataGrid, { rows: details.users, columns: columns, sortingOrder: ['desc', 'asc'], sortModel: sortModel, onSortModelChange: function (model) { return setSortModel(model); }, pageSize: pageSize, onPageSizeChange: function (newPageSize) { return setPageSize(newPageSize); }, rowsPerPageOptions: [10, 25], classes: { root: classes.MuiGridRoot } }, void 0) }), void 0)] }), void 0) }), void 0));\n};\nexport default HistoryDetails;\n//# sourceMappingURL=HistoryDetails.js.map","var __assign = (this && this.__assign) || function () {\n __assign = Object.assign || function(t) {\n for (var s, i = 1, n = arguments.length; i < n; i++) {\n s = arguments[i];\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n t[p] = s[p];\n }\n return t;\n };\n return __assign.apply(this, arguments);\n};\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { Dialog as MuiDialog, DialogActions, DialogContent } from '@material-ui/core';\nimport { makeStyles } from '@material-ui/core/styles';\nimport { useTypography } from '../styles/Typography';\nimport Button from './buttons/Button';\nimport { MARKETING_URL } from '../utils/constants';\nimport SecondaryButton from './buttons/SecondaryButton';\nvar useStyles = makeStyles({\n buttons: {\n paddingBottom: 24,\n paddingLeft: 32,\n paddingRight: 32,\n paddingTop: 32,\n },\n content: {\n paddingLeft: 32,\n paddingRight: 32,\n paddingBottom: 0,\n paddingTop: 16,\n },\n paper: {\n position: 'absolute',\n bottom: 0,\n maxWidth: '100%',\n },\n});\nvar CookiesDialog = function (_a) {\n var open = _a.open, onAccept = _a.onAccept;\n var typo = useTypography();\n var classes = useStyles();\n var openPrivacyPolicy = function () {\n window.open(MARKETING_URL, '_blank');\n };\n return (_jsxs(MuiDialog, __assign({ open: open, classes: {\n paperWidthSm: classes.paper,\n }, \"aria-labelledby\": \"cookie-permissions-title\", \"aria-describedby\": \"cookie-permissions-description\" }, { children: [_jsx(DialogContent, __assign({ className: classes.content }, { children: _jsx(\"p\", __assign({ className: typo.body1 }, { children: \"Nulia Works requires the use of cookies to support user identification and prevent authentication abuses. In order to use Nulia Works, you must agree to those cookies by selecting \\u201CACCEPT.\\u201D\" }), void 0) }), void 0), _jsxs(DialogActions, __assign({ className: classes.buttons }, { children: [_jsx(SecondaryButton, __assign({ onClick: openPrivacyPolicy, style: { width: 170, marginRight: 32 } }, { children: \"Privacy Policy\" }), void 0), _jsx(Button, __assign({ focusOnMount: true, onClick: onAccept }, { children: \"Accept\" }), void 0)] }), void 0)] }), void 0));\n};\nexport default CookiesDialog;\n//# sourceMappingURL=CookiesDialog.js.map","var __read = (this && this.__read) || function (o, n) {\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\n if (!m) return o;\n var i = m.call(o), r, ar = [], e;\n try {\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\n }\n catch (error) { e = { error: error }; }\n finally {\n try {\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\n }\n finally { if (e) throw e.error; }\n }\n return ar;\n};\nimport { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { useEffect, useState } from 'react';\nimport * as Sentry from '@sentry/browser';\nimport CookiesDialog from './CookiesDialog';\nimport { PreferencesService } from '../services/PreferencesService';\nimport { ClientType } from '../types/enums';\nvar Analytics = function (_a) {\n var clientType = _a.clientType, children = _a.children;\n var _b = __read(useState(false), 2), startedAnalytics = _b[0], setStartedAnalytics = _b[1];\n var _c = __read(useState(false), 2), cookieDialogOpen = _c[0], setCookieDialogOpen = _c[1];\n useEffect(function () {\n if (PreferencesService.getAnalytics())\n return;\n setCookieDialogOpen(true);\n }, []);\n useEffect(function () {\n if (!startedAnalytics) {\n Sentry.init({\n dsn: 'https://d35b53ba274b4429bdcf9b436074776c@o221410.ingest.sentry.io/1367953',\n environment: process.env.NODE_ENV,\n });\n setStartedAnalytics(true);\n }\n }, [startedAnalytics]);\n var handleDialogAccept = function () {\n PreferencesService.setAnalytics(true);\n setCookieDialogOpen(false);\n };\n return (_jsxs(_Fragment, { children: [clientType === ClientType.platform && (_jsx(CookiesDialog, { open: cookieDialogOpen, onAccept: handleDialogAccept }, void 0)), children] }, void 0));\n};\nexport default Analytics;\n//# sourceMappingURL=Analytics.js.map","import { useLayoutEffect } from 'react';\nimport { useLocation } from 'react-router-dom';\nvar ScrollToTop = function () {\n var pathname = useLocation().pathname;\n useLayoutEffect(function () {\n window.scrollTo(0, 0);\n }, [pathname]);\n return null;\n};\nexport default ScrollToTop;\n//# sourceMappingURL=ScrollToTop.js.map","var __extends = (this && this.__extends) || (function () {\n var extendStatics = function (d, b) {\n extendStatics = Object.setPrototypeOf ||\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\n return extendStatics(d, b);\n };\n return function (d, b) {\n if (typeof b !== \"function\" && b !== null)\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\n extendStatics(d, b);\n function __() { this.constructor = d; }\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n };\n})();\nimport { Component } from 'react';\nimport * as Sentry from '@sentry/browser';\nimport { withRouter } from 'react-router-dom';\nimport { VERSION } from '../utils/constants';\nimport { UserContext } from '../contexts/UserContext';\nimport { PreferencesService } from '../services/PreferencesService';\nvar _ErrorBoundary = (function (_super) {\n __extends(_ErrorBoundary, _super);\n function _ErrorBoundary(props) {\n var _this = _super.call(this, props) || this;\n _this.state = { hasError: false };\n return _this;\n }\n _ErrorBoundary.getDerivedStateFromError = function (error) {\n return { hasError: true };\n };\n _ErrorBoundary.prototype.componentDidCatch = function (error, errorInfo) {\n var _this = this;\n Sentry.withScope(function (scope) {\n var _a, _b, _c;\n scope.setExtra('stack', errorInfo.componentStack);\n scope.setExtra('version', VERSION);\n if (PreferencesService.getAnalytics()) {\n scope.setExtra('user', ((_a = _this.context.user) === null || _a === void 0 ? void 0 : _a.oid) + \" \" + ((_b = _this.context.user) === null || _b === void 0 ? void 0 : _b.tid) + \" \" + ((_c = _this.context.user) === null || _c === void 0 ? void 0 : _c.sid));\n }\n Sentry.captureException(error);\n });\n };\n _ErrorBoundary.prototype.render = function () {\n return this.props.children;\n };\n _ErrorBoundary.contextType = UserContext;\n return _ErrorBoundary;\n}(Component));\nvar ErrorBoundary = withRouter(_ErrorBoundary);\nexport default ErrorBoundary;\n//# sourceMappingURL=ErrorBoundary.js.map","import * as React from 'react';\r\nimport { FC, useContext, useEffect, useState } from 'react';\r\nimport { Redirect, Route, Switch } from 'react-router';\r\nimport { isAfter } from 'date-fns';\r\nimport { useAccount, useMsal } from '@azure/msal-react';\r\nimport {\r\n BulkAssignOutcomes,\r\n ClientType,\r\n hasAdminRole,\r\n HistoryDetails,\r\n Home,\r\n HowTo,\r\n HowToCategory,\r\n HowToPlaylist,\r\n InsightOutcomeDetail,\r\n Insights,\r\n InsightsDetail,\r\n Instructions,\r\n LicenseClass,\r\n LicenseType,\r\n Loading,\r\n NoAccount,\r\n NoNulia,\r\n Notifications,\r\n OutcomeDetails,\r\n Outcomes,\r\n Pages,\r\n Preferences,\r\n Showcase,\r\n SkillDetails,\r\n Skills,\r\n TokenContext,\r\n TokenExpired,\r\n useGetUser,\r\n useGetUserId,\r\n UserContext,\r\n YourAchievements,\r\n YourBadges,\r\n} from 'common-v2';\r\n\r\ninterface IProps {}\r\n\r\nconst Routes: FC = () => {\r\n const { user, noNulia } = useContext(UserContext);\r\n const { expire } = useContext(TokenContext);\r\n const [didExpire, setDidExpire] = useState(false);\r\n const [receivedData, setReceivedData] = useState(false);\r\n const getUser = useGetUser();\r\n const { accounts } = useMsal();\r\n const account = useAccount(accounts[0]);\r\n const getUserId = useGetUserId();\r\n\r\n useEffect(() => {\r\n getUserId(account);\r\n }, [account, getUserId]);\r\n\r\n useEffect(() => {\r\n if (!receivedData) {\r\n getUser();\r\n setReceivedData(true);\r\n }\r\n }, [receivedData, getUser]);\r\n\r\n useEffect(() => {\r\n if (expire && isAfter(new Date(), expire)) {\r\n setDidExpire(true);\r\n }\r\n }, [expire]);\r\n\r\n if (didExpire) {\r\n return ;\r\n }\r\n\r\n if (noNulia) {\r\n return ;\r\n }\r\n\r\n if (!user) {\r\n return ;\r\n }\r\n\r\n if (user.licenseType === LicenseType.None && hasAdminRole(user)) {\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {/* \r\n \r\n */}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n );\r\n } else if (user.licenseType === LicenseType.None && user.licenseClass === LicenseClass.Complete) {\r\n return ;\r\n } else if (user.licenseType === LicenseType.None && user.licenseClass === LicenseClass.Unknown) {\r\n return ;\r\n }\r\n\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {/* \r\n \r\n */}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default Routes;\r\n","import { useContext } from 'react';\nimport { TokenContext } from '../contexts/TokenContext';\nexport var useGetUserId = function () {\n var _a = useContext(TokenContext), setOid = _a.setOid, setTid = _a.setTid;\n return function (account) {\n if (account) {\n setOid(account.localAccountId);\n setTid(account.tenantId);\n }\n };\n};\n//# sourceMappingURL=useGetUserId.js.map","import React, { FC } from 'react';\r\nimport { IPublicClientApplication, AccountInfo } from '@azure/msal-browser';\r\nimport { useAccount } from '@azure/msal-react';\r\nimport Routes from './Routes';\r\nimport { BrowserRouter } from 'react-router-dom';\r\nimport {\r\n ClientType,\r\n HeaderProvider,\r\n HowToProvider,\r\n LockProvider,\r\n NavigationProvider,\r\n NotificationsProvider,\r\n OutcomesProvider,\r\n ScrollToTop,\r\n ShowcaseProvider,\r\n TokenProvider,\r\n UserProvider,\r\n DialogProvider,\r\n ApiServiceProvider,\r\n SnackbarProvider,\r\n InsightsProvider,\r\n SkillsProvider,\r\n HomeProvider,\r\n ErrorBoundary,\r\n} from 'common-v2';\r\n\r\ninterface IProps {\r\n instance: IPublicClientApplication;\r\n accounts: Partial>[];\r\n}\r\n\r\nconst Token: FC = ({ instance, accounts }) => {\r\n const account = useAccount(accounts[0]);\r\n\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n );\r\n};\r\n\r\nexport default Token;\r\n","import React from 'react';\r\nimport { MsalProvider, AuthenticatedTemplate, UnauthenticatedTemplate, useMsal } from '@azure/msal-react';\r\nimport { PublicClientApplication } from '@azure/msal-browser';\r\nimport { Analytics, ClientType, Loading, Login, msalConfig, NuliaTheme } from 'common-v2';\r\nimport Token from './Token';\r\n\r\nconst MainContent = () => {\r\n const { instance, accounts, inProgress } = useMsal();\r\n\r\n if (inProgress === 'login') {\r\n return ;\r\n }\r\n\r\n return (\r\n
\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n
\r\n );\r\n};\r\n\r\nexport default function App() {\r\n const msalInstance = new PublicClientApplication(msalConfig);\r\n\r\n return (\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n );\r\n}\r\n","import * as registerServiceWorker from './registerServiceWorker';\n\nimport App from './App';\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n// import reportWebVitals from './reportWebVitals';\nimport './index.scss';\n\nReactDOM.render(\n \n \n ,\n document.getElementById('root')\n);\n\n// TODO: Add backend endpoint\n// If you want to start measuring performance in your app, pass a function\n// to log results (for example: reportWebVitals(console.log))\n// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals\n// reportWebVitals(console.log);\n\nregisterServiceWorker.register();\n"],"sourceRoot":""}