@clickview/lite 0.21.0-rc.2 → 0.21.0-rc.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[2199],{2284:(e,t,n)=>{var a;n.d(t,{W:()=>a}),function(e){e.Draft="Draft",e.ComingSoon="ComingSoon",e.Published="Published"}(a||(a={}))},29917:(e,t,n)=>{n.d(t,{r:()=>d});var a=n(1024),o=n.n(a),c=n(23481),i=n(58130),r=n(83914),l=n(36532);const s={tag:"k1Yjy",tooltip:"Cgeav"};var m="specialEventCalendar.comingSoonTag";function d(e){return o().createElement(l.u,{title:c.T.getPhrase(m,"tooltip"),spanHackClassName:"d-block ".concat(s.tooltip),spanHack:!0},o().createElement("div",{className:"d-flex text-dark align-items-center ".concat(s.tag," ").concat(e.className)},o().createElement(r.x,{svgName:i.vn.Timer}),!e.onlyIcon&&c.T.getPhrase(m,"comingSoon")))}},13037:(e,t,n)=>{n.d(t,{b:()=>k});var a=n(1024),o=n.n(a),c=n(23481),i=n(110),r=n(49985),l=n(65858),s=n(8493),m=n(42735),d=n(54610),p=n(67453),u=n(79967),v=n(2284),g=n(61557),f=n(29917);const D={modalWidth:"v5TkI",banner:"LlPSp",bannerContent:"upY3A",pill:"B7ypp"};var E="specialEventCalendar.eventsListItem";function k(e){var t,n=(0,u.k)(),a=e.getAppLink(e.event.content.id,e.event.name),k=e.event.content.metadata.backgroundColor,M=p.j.createUrl(null===(t=e.event.content.banner)||void 0===t?void 0:t.url,{size:d.h2.Large}),b=!!e.event.endDate,C=e.event.content.status===v.W.ComingSoon,h={actionType:l.UserAction.Click,entity:l.EntityType.SpecialEvent,location:e.inPopup?l.LocationContext.CalendarPopup:l.LocationContext.CalendarDay},Y={topicId:e.event.content.id,eventId:e.event.specialEventId,presentationId:e.presentationId,date:i.O.format(new Date(e.event.startDate),"YYYY-MM-DD"),status:e.event.content.status};return o().createElement("div",{onClick:function(){C&&r.k.logUserAction(Y,h)}},o().createElement(s.F,{appLink:!C&&a,className:"".concat(C?"":"cursor-pointer"," text-decoration-none"),onClick:e.onClick,analyticsOptions:h,analyticsData:Y},o().createElement("div",{className:"banner rounded-lg position-relative ".concat(D.banner),style:{backgroundColor:k,backgroundImage:"url('".concat(M,"')")}},o().createElement("div",{className:"".concat(D.bannerContent," px-3")},o().createElement("div",{className:"text-white"},C&&o().createElement(f.r,{className:"pr-2 font-weight-500 mb-1 rounded-pill justify-content-start ".concat(D.pill)}),b&&o().createElement("div",{className:"mb-1"},g.T.getDisplayDate(e.event.startDate,e.event.endDate)),o().createElement("h2",{className:"h4 clamp-1 text-white text-shadow",title:e.event.name},e.event.name)),o().createElement("div",{className:"flex-shrink-0"},!C&&o().createElement(m.K,{className:"btn btn-outline-dark font-weight-500"},c.T.getPhrase(E,n.xs?"mobileButtonLabel":"buttonLabel")))))),o().createElement("div",{className:"mt-2 mb-3"},e.event.description||e.event.content.description))}},39780:(e,t,n)=>{n.d(t,{N:()=>o});var a=n(97395),o={calendarEvents:function(e,t,n){return{url:a._.urlBuilder("{gateway}/v1/discover/special-events/content",{from:e,to:t,presentationId:n}),key:"presentation:".concat(n,":events:from:").concat(e,":to").concat(t)}}}},61557:(e,t,n)=>{n.d(t,{T:()=>r});var a=n(28400),o=n(110),c=n(97291),i=n(14070),r={getTopicAppLink:function(e,t){return{application:c.O.SUBJECT,action:i.e.Subjects.CLASSIFICATION,args:[e,a.m.slugify(t)]}},getDisplayDate:function(e,t){return t?e.slice(5,7)!==t.slice(5,7)?"".concat(o.O.format(e,"D MMM")," - ").concat(o.O.format(t,"D MMM")):"".concat(o.O.format(e,"D")," - ").concat(o.O.format(t,"D")," ").concat(o.O.format(e,"MMM")):o.O.format(e,"D MMM")},getEventsInMonth:function(e,t){return e.filter((function(e){return o.O.format(e.startDate,"YYYY-MM")===o.O.format(t,"YYYY-MM")}))},getOrdinalDate:function(e){return"".concat(o.O.localeData().ordinal(o.O.get(e,"date"))," ").concat(o.O.format(e,"MMMM"))}}},72199:(e,t,n)=>{n.r(t),n.d(t,{SpecialEventListView:()=>b});var a=n(1024),o=n.n(a),c=n(20354),i=n(54976),r=n.n(i),l=n(23481),s=n(110),m=n(9111),d=n(13876),p=n(25925),u=n(13037),v=n(39780),g=n(61557),f=n(86698);const D={modalWidth:"LrMq0",buttons:"jAfM0"};var E="specialEventCalendar.eventListPopup",k=400,M=300;function b(e){var t,n=(0,f.y)(p.R.Subject).presentation,a=new Date(e.from),i=new Date(e.to),b=c.a.useBasicFetch((null==n?void 0:n.id)&&v.N.calendarEvents(s.O.format(a,"YYYY-MM-DD"),s.O.format(i,"YYYY-MM-DD"),n.id)),C=(null===(t=b.data)||void 0===t?void 0:t.filter((function(t){return t.startDate===s.O.format(new Date(e.date),"YYYY-MM-DD")})))||[];return(null==n?void 0:n.id)?o().createElement(m.G,{title:"Events on ".concat(g.T.getOrdinalDate(e.date)),closePopup:e.closePopup,dialogClassName:D.modalWidth,bodyClassName:"p-0",showLoadingSpinner:!b.data},o().createElement(r(),{autoHeight:!0,autoHeightMin:M,autoHeightMax:k},o().createElement("div",{className:"px-3 pt-2"},C.map((function(t){return o().createElement(u.b,{key:t.content.id,getAppLink:g.T.getTopicAppLink,event:t,onClick:e.closePopup,inPopup:!0,presentationId:n.id})})))),o().createElement("div",{className:"ml-3"},o().createElement(d.u,{className:D.buttons},o().createElement(d.u.Cancel,{variant:"outline-dark",className:"mb-3",onClick:e.closePopup,text:l.T.getPhrase(E,"close")})))):o().createElement(o().Fragment,null)}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[4898],{54644:(e,t,n)=>{n.d(t,{v:()=>r});var a=n(97395),r={getContentUpdates:function(e,t,n){return{url:a._.urlBuilder("/api/domain/v1/subjects/content-updates",{from:t,to:n,limit:6,query:"(videoCollection)"}),publicUrl:a._.urlBuilder("/api/subjects/presentations/".concat(e,"/content-updates"),{from:t,to:n,limit:6,query:"(videoCollection)"}),key:"content:updates",normalizeOptions:{namespace:"contentupdates"},formatData:function(e){return e.map((function(e){return{id:e.classificationId,videos:e.videos}}))}}},getClassifications:function(e){return{url:a._.urlBuilder("/api/domain/v1/subjects",{id:e,query:"banner"}),publicUrl:a._.urlBuilder("/api/subjects/classifications",{id:e,query:"banner"}),key:"classifications:".concat(e.join(","))}},getClassification:function(e){return{url:"/api/domain/v1/subjects/".concat(e,"?query=banner"),publicUrl:"/api/subjects/classifications/".concat(e,"?query=banner"),key:"classification:".concat(e)}},getClassificationUpdates:function(e,t,n){return{url:a._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/content-updates"),{from:t,to:n,query:"(videoCollection)"}),publicUrl:a._.urlBuilder("/api/subjects/classifications/".concat(e,"/content-updates"),{from:t,to:n,query:"(videoCollection)"}),key:"classification:update:".concat(e,":").concat(t,":").concat(n)}},getContentUpdateVideos:function(e,t){return{url:a._.urlBuilder("/api/domain/v1/subjects/content-updates/videos",{from:e,to:t,query:"(videoCollection)"}),publicUrl:a._.urlBuilder("/api/subjects/content-updates/videos",{from:e,to:t,query:"(videoCollection)"}),key:"content:update:videos:".concat(e,":").concat(t)}},videos:function(e,t){return{url:"/api/domain/v1/videos?ids=".concat(e.join(","),"&with=(videoCollection)"),key:"videos:by:id:".concat(e.join(",")),success:t}}}},3278:(e,t,n)=>{n.d(t,{z:()=>f});var a=n(1024),r=n.n(a),i=n(23481),o=n(83345),l=n(53957),c=n(38502),s=n(65858),u=n(55460);const d={pillTab:"bMJM0"};var p="discover.header";function f(e){var t,n,a,f,m,v;if(!e.type)return r().createElement(r().Fragment,null);if(e.type===l.DashboardUserType.Learner||e.hasStudentExperience)return r().createElement("div",{className:"py-3"},r().createElement("h1",{className:"h2 mb-0"},r().createElement(o.x,{namespace:p,phrase:"heading"})));var y=[{name:i.T.getPhrase(p,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===e.active,analyticsData:{name:i.T.getPhrase(p,"forYou"),url:u.AppLinkHelper.getHref(null===(n=e.appLinks)||void 0===n?void 0:n.forYou)},analyticsOptions:{actionType:s.UserAction.Click,entity:s.EntityType.Url,location:s.LocationContext.MagicTabs}},{name:i.T.getPhrase(p,"whatsNew"),appLink:null===(a=e.appLinks)||void 0===a?void 0:a.whatsNew,active:"whatsNew"===e.active,analyticsData:{name:i.T.getPhrase(p,"whatsNew"),url:u.AppLinkHelper.getHref(null===(f=e.appLinks)||void 0===f?void 0:f.whatsNew)},analyticsOptions:{actionType:s.UserAction.Click,entity:s.EntityType.Url,location:s.LocationContext.MagicTabs}}];return e.showCalendar&&y.push({name:i.T.getPhrase(p,"calendar"),appLink:null===(m=e.appLinks)||void 0===m?void 0:m.calendar,active:"calendar"===e.active,analyticsData:{name:i.T.getPhrase(p,"calendar"),url:u.AppLinkHelper.getHref(null===(v=e.appLinks)||void 0===v?void 0:v.calendar)},analyticsOptions:{actionType:s.UserAction.Click,entity:s.EntityType.Url,location:s.LocationContext.MagicTabs}}),r().createElement("div",{className:"py-3 text-center"},r().createElement(c.r,{tabs:y,className:d.pillTab}))}},38502:(e,t,n)=>{n.d(t,{r:()=>u});var a=n(1024),r=n.n(a),i=n(11607),o=n(8493),l=n(49985),c=n(87432),s=n(76246);function u(e){var t;return r().createElement("nav",{className:null!==(t=e.className)&&void 0!==t?t:""},r().createElement("ul",{className:"list-unstyled d-inline-block m-0 ".concat(c.Z.pillTabSelector)},e.tabs.map((function(e){return r().createElement("li",{className:"p-0 ".concat(e.active?"btn btn-dark":"btn btn-outline-dark"),key:e.name},e.appLink?r().createElement(o.F,{appLink:e.appLink,analyticsData:e.analyticsData,analyticsOptions:e.analyticsOptions,className:"cursor-pointer d-flex justify-content-center text-decoration-none text-reset px-2 ".concat(c.Z.pillItem)},e.name,"number"==typeof e.count&&r().createElement("div",{className:"pl-2"},r().createElement(s.C,{type:s.g.Count,data:e.count}))):r().createElement(i.L,{className:"".concat(c.Z.pillItem," d-flex justify-content-center p-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&l.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name,"number"==typeof e.count&&r().createElement("div",{className:"pl-2"},r().createElement(s.C,{type:s.g.Count,data:e.count}))))}))))}},74696:(e,t,n)=>{n.d(t,{S:()=>s});var a=n(1024),r=n.n(a),i=n(99910),o=n(79967),l=n(9977);const c={partialName:"SicQQ",partialDescription:"dPGMq",partialThumbnail:"vZrnb",partialDragHandle:"iq73R"};function s(e){return r().createElement(r().Fragment,null,Array(e.numVideos).fill(null).map((function(t,n){return r().createElement(u,Object.assign({key:n},e))})))}function u(e){var t=(0,o.k)(),n="sm"===l.O.getSize(t,"md"),a=e.withReordering&&!t.xs;return r().createElement(i.Row,{noGutters:!0,className:"".concat(n?"":"py-2")},r().createElement(i.Col,Object.assign({},l.O.getThumbnailColumns(),{className:"flex-column align-items-flex-start ".concat(n?"pb-2 pr-2":"mb-1 px-2")}),r().createElement(i.Row,null,!!a&&r().createElement("div",{className:"d-flex align-items-center justify-content-center col-2"},r().createElement("div",{className:"partial-loading-background ".concat(c.partialDragHandle)})),r().createElement(i.Col,{xs:l.O.getThumbnailColSize(a)},r().createElement("div",{className:"partial-loading-background ".concat(n?"rounded":"rounded-lg"," ").concat(c.partialThumbnail)})))),r().createElement(i.Col,Object.assign({},l.O.getDetailsColumns(),{className:n?"pb-2":"px-2"}),r().createElement("div",{className:"partial-loading-background mb-1 ".concat(c.partialName)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialDescription)})))}s.defaultProps={numVideos:15}},39902:(e,t,n)=>{n.d(t,{f:()=>s});var a=n(1024),r=n.n(a),i=n(58566),o=n(20354);function l(e,t){if(e){if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?c(e,t):void 0}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}function s(e,t){var n,a,s=(n=r().useState([]),a=2,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,i,o,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(a=i.call(n)).done)&&(l.push(a.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(s)throw r}}return l}}(n,a)||l(n,a)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),u=s[0],d=s[1];r().useEffect((function(){if(null==e?void 0:e.length){var t=function(e){return function(e){if(Array.isArray(e))return c(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||l(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(u);t.push([]),e.forEach((function(e){t.find((function(t){return t.find((function(t){return t===e}))}))||t[t.length-1].push(e)})),d(t.filter((function(e){return e.length})))}}),[e?e.join(","):null]);var p=(0,i.useDispatch)(),f=(0,i.useSelector)((function(e){return e}));if(r().useEffect((function(){u.forEach((function(e){var n=t(e);o.a.getResponse(f,n.key).shouldFetch&&o.a.fetch(p,n)}))}),[null==u?void 0:u.length]),!(null==u?void 0:u.length))return{items:null,isFetching:!1};var m={},v={};return u.forEach((function(e,n){var a=t(e),r=o.a.getResponse(f,a.key);v[n]=r,r.data&&r.data.forEach((function(e){return m[e.id]=e}))})),{items:Object.keys(v).some((function(e){return!!v[e].data}))?m:null,isFetching:!!Object.keys(v).some((function(e){return v[e].isFetching}))}}},74590:(e,t,n)=>{n.d(t,{N:()=>f});var a=n(1024),r=n.n(a),i=n(35242),o=n(55171),l=n(25925),c=n(37802),s=n(86698);function u(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,i,o,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(a=i.call(n)).done)&&(l.push(a.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(s)throw r}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var p=[o.e.PresentationIds.AU_PRIMARY,o.e.PresentationIds.US_ELEMENTARY,o.e.PresentationIds.ENGLAND_PRIMARY];function f(){var e=(0,c.r)(null),t=e.hasSpecialEventCalendar,n=e.isLoadingSettings,a=(0,s.y)(l.R.Subject).presentation,o=!n&&!t,d=(null==a?void 0:a.id)&&!p.includes(+a.id),f=u(r().useState(!o&&!d),2),m=f[0],v=f[1],y=u(r().useState(n||!(null==a?void 0:a.id)),2),b=y[0],h=y[1];return r().useEffect((function(){o||d?v(!1):b||v(!0),h(n||!(null==a?void 0:a.id))}),[t,null==a?void 0:a.id,b]),i.h.isDevelopment?{showCalendar:!0,isLoading:!1}:{showCalendar:m,isLoading:b}}},37808:(e,t,n)=>{n.d(t,{aq:()=>v,YW:()=>b});var a=n(1024),r=n(83345),i=n(8493),o=n(99910),l=n(2948),c=n(57900),s=n(38143),u=n(58130),d=n(10874);const p={banner:"B7jhq"};function f(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var m="contentUpdates.classificationBanner";function v(e){var t,n,v=e.classification,y=e.backgroundUrl,b=e.followed,h=e.follow,g=e.showFollowSpinner,E=(t=(0,l.D)(s.g.AUDIENCE_FILTER,void 0,{storage:c.Z1.SessionStorage}),n=1,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,i,o,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(a=i.call(n)).done)&&(l.push(a.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(s)throw r}}return l}}(t,n)||function(e,t){if(e){if("string"==typeof e)return f(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?f(e,t):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0];return a.createElement("div",{className:"banner mb-2 d-flex justify-content-between align-items-center rounded ".concat(p.banner),style:{backgroundImage:"url('".concat(y,"')")}},a.createElement(i.F,{className:"text-white text-shadow",appLink:e.getClassificationAppLink(v,E)},a.createElement("h2",{className:"h3 mb-0"},v.name)),e.canFollow&&a.createElement(d.h,{className:"btn follow-btn ".concat(b?"btn-outline-dark":"btn-dark"),svgName:b?u.vn.Check:u.vn.Bell,onClick:function(){return h(v.id,v.name,!b)}},g?a.createElement(o.Spinner,{as:"span",animation:"border",role:"status",size:"sm"}):a.createElement(r.x,{namespace:m,phrase:b?"unfollow":"follow"})))}var y="playlists.liteClassificationUpdateBreadcrumbs";function b(e){var t=e.classification;return a.createElement(a.Fragment,null,a.createElement("nav",{"aria-label":"breadcrumb"},a.createElement("ol",{className:"breadcrumb p-0 mb-0"},a.createElement("li",{className:"breadcrumb-item"},a.createElement(i.F,{appLink:e.dashboardAppLink},a.createElement(r.x,{namespace:y,phrase:"dashboard"}))),a.createElement("li",{className:"breadcrumb-item"},a.createElement(i.F,{appLink:e.contentUpdatesAppLink},a.createElement(r.x,{namespace:y,phrase:"whatsNew"}))),a.createElement("li",{className:"breadcrumb-item active","aria-current":"page"},t.name))))}},80004:(e,t,n)=>{n.r(t),n.d(t,{ContentUpdatesView:()=>J});var a=n(1024),r=n.n(a),i=n(33192),o=n(58566),l=n(20354),c=n(23481),s=n(23049),u=n(53957),d=n(61699),p=n(39151),f=n(69883),m=n(39902),v=n(54644),y=n(51365),b=n(3278),h=n(83345),g=n(22902),E=n(16714),w=n(8493),k=n(97037),S=n(31949),C=n(1666),j=n(25925),A=n(49985),N=n(65858),L=n(65986),O=n(97291),T=n(97816),U=n(14070),F=n(86698),x=n(44110),I=n(41063),P=n(74590),D=n(67453),M=n(54610),B=n(4632),R=n(37808),Y="contentUpdates.contentUpdatesView";function _(e){var t=e.classification,n=e.videos,r=e.imageCdnUrl,i=e.showMore,o=e.followed;if(!t)return a.createElement(a.Fragment,null);var l=D.j.createBannerUrl(t.banner,{fallbackBaseUrl:r,fallbackCategoryName:t.name,type:M.__.Banners},{size:M.h2.Medium,resizeType:M.Nq.Cover});return a.createElement("div",{className:"mb-3"},a.createElement(R.aq,{classification:t,backgroundUrl:l,getClassificationAppLink:e.appLinks.getClassificationAppLink,followed:o,follow:e.follow,canFollow:e.canFollow,showFollowSpinner:e.showFollowSpinner}),a.createElement(B.E4,{videos:n,yearGroups:e.yearGroups,getVideoAppLink:e.appLinks.getVideoAppLink,getSeriesAppLink:e.appLinks.getSeriesAppLink,setFavourite:e.setFavourite,canFavourite:e.canFavourite,presentationAudiences:e.audiences}),i&&a.createElement("div",{className:"show-more"},a.createElement(w.F,{className:"info-link",appLink:e.appLinks.getClassificationUpdateAppLink(t)},a.createElement(h.x,{namespace:Y,phrase:"showMore",options:{classificationName:t.name}}))))}var q=n(74696);const H={partialBanner:"bxaA6"};function V(){return r().createElement(r().Fragment,null,Array(4).fill(null).map((function(e,t){return r().createElement("div",{key:t,className:"mb-3"},r().createElement("div",{className:"partial-loading-background mb-2 ".concat(H.partialBanner)}),r().createElement(q.S,null),";")})))}function z(e){return z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},z(e)}function G(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==z(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var a=n.call(e,"string");if("object"!==z(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===z(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Z(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var W=5,$="contentUpdates.contentUpdatesView";function J(e){var t,n,r,D,M,B,R,Y=(B=a.useState({}),R=2,function(e){if(Array.isArray(e))return e}(B)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,i,o,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(a=i.call(n)).done)&&(l.push(a.value),l.length!==t);c=!0);}catch(e){s=!0,r=e}finally{try{if(!c&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(s)throw r}}return l}}(B,R)||function(e,t){if(e){if("string"==typeof e)return Z(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Z(e,t):void 0}}(B,R)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),q=Y[0],H=Y[1],z=(0,o.useDispatch)(),J=(0,f.Z)();(0,s.o)(c.T.getPhrase($,"pageTitle"));var Q=(0,g.T)().hasPermissions,K=Q(E.C.FollowSubjects),X=i().subtract(1,"year").endOf("day").format("YYYY-MM-DD"),ee=i().endOf("day").format("YYYY-MM-DD"),te=l.a.useBasicFetch(p.L.config()),ne=l.a.useBasicFetch(S.N.currentUser()),ae=l.a.useBasicFetch((null===(t=ne.data)||void 0===t?void 0:t.isAuthenticated)&&C.h.yearGroups(ne.data.customerId)),re=(0,F.y)(j.R.Subject).presentation,ie=v.v.getContentUpdates(null==re?void 0:re.id,X,ee),oe=l.a.useBasicFetch(re&&ie),le=l.a.useBasicFetch(K&&d.o.mySubjectPreferences()),ce=(0,x.i)(),se=[],ue=[];oe.data&&oe.data.forEach((function(e){se.push(e.id),ue=ue.concat(e.videos)}));var de=(0,m.f)(se,(function(e){return v.v.getClassifications(e)})).items,pe=(0,L._)(L.i.VideoItem);(0,T.V)(ue,{hasCurriculumLinks:!0,flightNamespace:null===(n=ie.normalizeOptions)||void 0===n?void 0:n.namespace});var fe=(0,k.c)(N.LocationContext.VideoThumbnail,null===(r=ie.normalizeOptions)||void 0===r?void 0:r.namespace),me=fe.setFavourite,ve=fe.canFavourite;function ye(e,t,n){H((function(t){return Object.assign(Object.assign({},t),G({},e,!0))}));var a=function(){var a;H((function(t){return Object.assign(Object.assign({},t),G({},e,!1))})),A.k.logUserAction({id:e,name:t},{location:N.LocationContext.ContentUpdatesClassificationBanner,workflowPhase:N.WorkflowPhase.Complete,descriptor:n?N.ToggleDescriptor.On:N.ToggleDescriptor.Off,actionType:N.UserAction.Follow,entity:N.EntityType.Classification}),J.success(c.T.getPhrase($,n?"followed":"unfollowed",{classification:null===(a=de[e])||void 0===a?void 0:a.name,escapeText:!0}))},r=function(){H((function(t){return Object.assign(Object.assign({},t),G({},e,!1))})),J.error(c.T.getPhrase($,"error"))},i=n?d.o.followSubjects([e],a,r):d.o.unfollowSubjects([e],a,r);l.a.fetch(z,i)}var be=(0,P.N)(),he=be.showCalendar,ge=be.isLoading,Ee=!(!(oe.hasCompleted&&te.hasCompleted&&ce.hasCompleted)||K&&!le.hasCompleted||!de||ge),we=function(e,t){return e&&t?e.map((function(e){return{showMore:e.videos.length>W,classification:t[e.id],videos:e.videos.slice(0,W).map((function(e){return e.classification=t[e.id],e})).filter((function(e){return e}))}})).filter((function(e){return e.classification})):null}(oe.data,de),ke=null!==(M=null===(D=le.data)||void 0===D?void 0:D.map((function(e){return e.id})))&&void 0!==M?M:[],Se=Q(E.C.ManageSubjectPreferences),Ce=(0,I.b)();return a.createElement(y.M.Provider,{value:pe},a.createElement("div",{className:"bg-white px-3"},!ge&&a.createElement(b.z,{type:u.DashboardUserType.Staff,appLinks:{forYou:e.appLinks.dashboardAppLink,whatsNew:e.appLinks.whatsNewAppLink,calendar:e.appLinks.calendarAppLink},showCalendar:he,active:"whatsNew"}),a.createElement("h1",null,a.createElement(h.x,{namespace:$,phrase:"heading"})),(Se||Ce)&&a.createElement("p",null,Se&&a.createElement(a.Fragment,null,a.createElement(h.x,{namespace:$,phrase:"onlyRelevant"})," ",a.createElement(w.F,{className:"info-link",appLink:{application:O.O.SETTINGS,action:U.e.Settings.TOPIC_PREFERENCES}},a.createElement(h.x,{namespace:$,phrase:"updatePreferences"}))),Ce&&a.createElement("span",{className:"d-block"},a.createElement(w.F,{className:"info-link",appLink:{application:O.O.SETTINGS,action:U.e.Settings.CONTENT_REVIEW}},a.createElement(h.x,{namespace:$,phrase:"contentReview"})))),Ee?a.createElement(a.Fragment,null,we.map((function(t,n){var r,i;return a.createElement(_,{key:n,classification:t.classification,videos:t.videos,yearGroups:ae.data,imageCdnUrl:te.data.imageCdnUrl,showMore:t.showMore,appLinks:e.appLinks,followed:ke.includes(null===(r=t.classification)||void 0===r?void 0:r.id),follow:ye,showFollowSpinner:q[null===(i=t.classification)||void 0===i?void 0:i.id],canFollow:K,setFavourite:me,canFavourite:ve,audiences:ce.data})}))):a.createElement(V,null)))}},87821:(e,t,n)=>{n.d(t,{p:()=>r});var a=n(33192),r={userVideoHistory:function(e,t,n,r){var i="video:history",o="{gateway}/v1/users/me/watch-history";return e&&(i+=":".concat(e),o+="?cursor=".concat(e)),{key:i,url:o,formatData:function(e){return{data:e.data.map((function(e){var t=a.utc(e.lastTimeWatched).local().format(),n=a(t).format("YYYY-MM-DD");return Object.assign(Object.assign({},e),{lastTimeWatched:t,lastDateWatched:n})})),pagination:e.pagination}},success:t,error:n,always:r}},videoHistory:function(e,t,n,a,r){var i=e.sort().map((function(e){return"videoId=".concat(e)}));return{key:"video:history:videos:".concat(i.join("&")),url:"{gateway}/v1/videos/history?".concat(i.join("&")),normalizeOptions:{namespace:t},formatData:function(e){return(null==e?void 0:e.length)?e.map((function(e){return{id:e.videoId,lastProgressPoint:e.lastProgressPoint}})):e},success:n,error:a,always:r}}}},44110:(e,t,n)=>{n.d(t,{i:()=>l});var a=n(20354),r=n(25925),i=n(89454),o=n(86698),l=function(){var e=(0,o.y)(r.R.Subject).presentation;return a.a.useBasicFetch(!!e&&i.O.presentationAudiences(e.id))}},97816:(e,t,n)=>{n.d(t,{V:()=>m});var a=n(1024),r=n.n(a),i=n(20354),o=n(31949),l=n(1575),c=n(21750),s=n(87821),u=n(63419);function d(e){return function(e){if(Array.isArray(e))return p(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return p(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var f={ratings:!1,favourites:!1,watchHistory:!1,hasCurriculumLinks:!1};function m(e){var t,n,a,p=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},m=Object.assign(Object.assign({},f),p),v=m.ratings,y=m.favourites,b=m.watchHistory,h=m.hasCurriculumLinks,g=i.a.useBasicFetch(o.N.currentUser()),E=e&&(Array.isArray(e)?e.filter(Boolean).map((function(e){return e.id})):e.data.filter(Boolean).map((function(e){return e.id}))),w=g.data;t=r().useMemo((function(){if(!(null==w?void 0:w.isAuthenticated))return[];var e=[];return v&&(e=[].concat(d(e),[!!(null==E?void 0:E.length)&&l.R.videoRatings(E,p.flightNamespace)])),y&&(e=[].concat(d(e),[!!(null==E?void 0:E.length)&&w&&u.P.isFavourited(w.id,E,p.flightNamespace)])),b&&(e=[].concat(d(e),[!!(null==E?void 0:E.length)&&w&&s.p.videoHistory(E,p.flightNamespace)])),h&&(e=[].concat(d(e),[!!(null==E?void 0:E.length)&&c.x.hasCurriculumLinks(E,null,p.flightNamespace)])),e.filter(Boolean)}),[null==E?void 0:E.length]),n=!!e,a=i.a.useGetFetch(),r().useEffect((function(){n&&t.length&&t.forEach((function(e){a(e)}))}),[t.length])}},87432:(e,t,n)=>{n.d(t,{Z:()=>a});const a={pillTabSelector:"Hdi6o",pillItem:"hUJx1"}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[834],{3278:(e,t,n)=>{n.d(t,{z:()=>p});var a=n(1024),r=n.n(a),o=n(23481),c=n(83345),i=n(53957),l=n(38502),s=n(65858),u=n(55460);const d={pillTab:"bMJM0"};var m="discover.header";function p(e){var t,n,a,p,f,v;if(!e.type)return r().createElement(r().Fragment,null);if(e.type===i.DashboardUserType.Learner||e.hasStudentExperience)return r().createElement("div",{className:"py-3"},r().createElement("h1",{className:"h2 mb-0"},r().createElement(c.x,{namespace:m,phrase:"heading"})));var h=[{name:o.T.getPhrase(m,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===e.active,analyticsData:{name:o.T.getPhrase(m,"forYou"),url:u.AppLinkHelper.getHref(null===(n=e.appLinks)||void 0===n?void 0:n.forYou)},analyticsOptions:{actionType:s.UserAction.Click,entity:s.EntityType.Url,location:s.LocationContext.MagicTabs}},{name:o.T.getPhrase(m,"whatsNew"),appLink:null===(a=e.appLinks)||void 0===a?void 0:a.whatsNew,active:"whatsNew"===e.active,analyticsData:{name:o.T.getPhrase(m,"whatsNew"),url:u.AppLinkHelper.getHref(null===(p=e.appLinks)||void 0===p?void 0:p.whatsNew)},analyticsOptions:{actionType:s.UserAction.Click,entity:s.EntityType.Url,location:s.LocationContext.MagicTabs}}];return e.showCalendar&&h.push({name:o.T.getPhrase(m,"calendar"),appLink:null===(f=e.appLinks)||void 0===f?void 0:f.calendar,active:"calendar"===e.active,analyticsData:{name:o.T.getPhrase(m,"calendar"),url:u.AppLinkHelper.getHref(null===(v=e.appLinks)||void 0===v?void 0:v.calendar)},analyticsOptions:{actionType:s.UserAction.Click,entity:s.EntityType.Url,location:s.LocationContext.MagicTabs}}),r().createElement("div",{className:"py-3 text-center"},r().createElement(l.r,{tabs:h,className:d.pillTab}))}},38502:(e,t,n)=>{n.d(t,{r:()=>u});var a=n(1024),r=n.n(a),o=n(11607),c=n(8493),i=n(49985),l=n(87432),s=n(76246);function u(e){var t;return r().createElement("nav",{className:null!==(t=e.className)&&void 0!==t?t:""},r().createElement("ul",{className:"list-unstyled d-inline-block m-0 ".concat(l.Z.pillTabSelector)},e.tabs.map((function(e){return r().createElement("li",{className:"p-0 ".concat(e.active?"btn btn-dark":"btn btn-outline-dark"),key:e.name},e.appLink?r().createElement(c.F,{appLink:e.appLink,analyticsData:e.analyticsData,analyticsOptions:e.analyticsOptions,className:"cursor-pointer d-flex justify-content-center text-decoration-none text-reset px-2 ".concat(l.Z.pillItem)},e.name,"number"==typeof e.count&&r().createElement("div",{className:"pl-2"},r().createElement(s.C,{type:s.g.Count,data:e.count}))):r().createElement(o.L,{className:"".concat(l.Z.pillItem," d-flex justify-content-center p-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&i.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name,"number"==typeof e.count&&r().createElement("div",{className:"pl-2"},r().createElement(s.C,{type:s.g.Count,data:e.count}))))}))))}},2284:(e,t,n)=>{var a;n.d(t,{W:()=>a}),function(e){e.Draft="Draft",e.ComingSoon="ComingSoon",e.Published="Published"}(a||(a={}))},29917:(e,t,n)=>{n.d(t,{r:()=>d});var a=n(1024),r=n.n(a),o=n(23481),c=n(58130),i=n(83914),l=n(36532);const s={tag:"k1Yjy",tooltip:"Cgeav"};var u="specialEventCalendar.comingSoonTag";function d(e){return r().createElement(l.u,{title:o.T.getPhrase(u,"tooltip"),spanHackClassName:"d-block ".concat(s.tooltip),spanHack:!0},r().createElement("div",{className:"d-flex text-dark align-items-center ".concat(s.tag," ").concat(e.className)},r().createElement(i.x,{svgName:c.vn.Timer}),!e.onlyIcon&&o.T.getPhrase(u,"comingSoon")))}},13037:(e,t,n)=>{n.d(t,{b:()=>b});var a=n(1024),r=n.n(a),o=n(23481),c=n(110),i=n(49985),l=n(65858),s=n(8493),u=n(42735),d=n(54610),m=n(67453),p=n(79967),f=n(2284),v=n(61557),h=n(29917);const y={modalWidth:"v5TkI",banner:"LlPSp",bannerContent:"upY3A",pill:"B7ypp"};var g="specialEventCalendar.eventsListItem";function b(e){var t,n=(0,p.k)(),a=e.getAppLink(e.event.content.id,e.event.name),b=e.event.content.metadata.backgroundColor,E=m.j.createUrl(null===(t=e.event.content.banner)||void 0===t?void 0:t.url,{size:d.h2.Large}),D=!!e.event.endDate,O=e.event.content.status===f.W.ComingSoon,k={actionType:l.UserAction.Click,entity:l.EntityType.SpecialEvent,location:e.inPopup?l.LocationContext.CalendarPopup:l.LocationContext.CalendarDay},M={topicId:e.event.content.id,eventId:e.event.specialEventId,presentationId:e.presentationId,date:c.O.format(new Date(e.event.startDate),"YYYY-MM-DD"),status:e.event.content.status};return r().createElement("div",{onClick:function(){O&&i.k.logUserAction(M,k)}},r().createElement(s.F,{appLink:!O&&a,className:"".concat(O?"":"cursor-pointer"," text-decoration-none"),onClick:e.onClick,analyticsOptions:k,analyticsData:M},r().createElement("div",{className:"banner rounded-lg position-relative ".concat(y.banner),style:{backgroundColor:b,backgroundImage:"url('".concat(E,"')")}},r().createElement("div",{className:"".concat(y.bannerContent," px-3")},r().createElement("div",{className:"text-white"},O&&r().createElement(h.r,{className:"pr-2 font-weight-500 mb-1 rounded-pill justify-content-start ".concat(y.pill)}),D&&r().createElement("div",{className:"mb-1"},v.T.getDisplayDate(e.event.startDate,e.event.endDate)),r().createElement("h2",{className:"h4 clamp-1 text-white text-shadow",title:e.event.name},e.event.name)),r().createElement("div",{className:"flex-shrink-0"},!O&&r().createElement(u.K,{className:"btn btn-outline-dark font-weight-500"},o.T.getPhrase(g,n.xs?"mobileButtonLabel":"buttonLabel")))))),r().createElement("div",{className:"mt-2 mb-3"},e.event.description||e.event.content.description))}},39780:(e,t,n)=>{n.d(t,{N:()=>r});var a=n(97395),r={calendarEvents:function(e,t,n){return{url:a._.urlBuilder("{gateway}/v1/discover/special-events/content",{from:e,to:t,presentationId:n}),key:"presentation:".concat(n,":events:from:").concat(e,":to").concat(t)}}}},74590:(e,t,n)=>{n.d(t,{N:()=>p});var a=n(1024),r=n.n(a),o=n(35242),c=n(55171),i=n(25925),l=n(37802),s=n(86698);function u(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,c,i=[],l=!0,s=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=o.call(n)).done)&&(i.push(a.value),i.length!==t);l=!0);}catch(e){s=!0,r=e}finally{try{if(!l&&null!=n.return&&(c=n.return(),Object(c)!==c))return}finally{if(s)throw r}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var m=[c.e.PresentationIds.AU_PRIMARY,c.e.PresentationIds.US_ELEMENTARY,c.e.PresentationIds.ENGLAND_PRIMARY];function p(){var e=(0,l.r)(null),t=e.hasSpecialEventCalendar,n=e.isLoadingSettings,a=(0,s.y)(i.R.Subject).presentation,c=!n&&!t,d=(null==a?void 0:a.id)&&!m.includes(+a.id),p=u(r().useState(!c&&!d),2),f=p[0],v=p[1],h=u(r().useState(n||!(null==a?void 0:a.id)),2),y=h[0],g=h[1];return r().useEffect((function(){c||d?v(!1):y||v(!0),g(n||!(null==a?void 0:a.id))}),[t,null==a?void 0:a.id,y]),o.h.isDevelopment?{showCalendar:!0,isLoading:!1}:{showCalendar:f,isLoading:y}}},61557:(e,t,n)=>{n.d(t,{T:()=>i});var a=n(28400),r=n(110),o=n(97291),c=n(14070),i={getTopicAppLink:function(e,t){return{application:o.O.SUBJECT,action:c.e.Subjects.CLASSIFICATION,args:[e,a.m.slugify(t)]}},getDisplayDate:function(e,t){return t?e.slice(5,7)!==t.slice(5,7)?"".concat(r.O.format(e,"D MMM")," - ").concat(r.O.format(t,"D MMM")):"".concat(r.O.format(e,"D")," - ").concat(r.O.format(t,"D")," ").concat(r.O.format(e,"MMM")):r.O.format(e,"D MMM")},getEventsInMonth:function(e,t){return e.filter((function(e){return r.O.format(e.startDate,"YYYY-MM")===r.O.format(t,"YYYY-MM")}))},getOrdinalDate:function(e){return"".concat(r.O.localeData().ordinal(r.O.get(e,"date"))," ").concat(r.O.format(e,"MMMM"))}}},20834:(e,t,n)=>{n.r(t),n.d(t,{CalendarView:()=>De});var a=n(1024),r=n.n(a),o=n(81886),c=n(23049),i=n(23481),l=n(25925),s=n(53957),u=n(3278),d=n(97291),m=n(14070),p=n(86698),f=n(110),v=n(79967),h=n(8493),y=n(75795),g=n(65858),b=n(83914),E=n(58130),D=n(11607);const O={actions:"DpKMU",chevron:"IE4Ui",left:"AFmnx",right:"N1Rz_"};var k="specialEventCalendar.calendarNav",M=6,N=12;function C(e){var t="previous"===e.action?E.vn.ChevronLeft:E.vn.ChevronRight,n="previous"===e.action?O.left:O.right;return r().createElement(D.L,{className:"".concat(O.chevron," ").concat(n," border border-dark rounded-circle bg-white d-flex align-items-center justify-content-center"),onClick:e.onClick},r().createElement(b.x,{svgName:t,size:b.S.Medium,className:"svg-container d-inline-block ".concat(O.svg)}))}var w=new Date;function Y(e){var t=(0,v.k)();function n(e){var t=y.O.getCurrentRoute().appLink,n=t.params?Object.assign({},t.params):{};return n.monthDate=f.O.format(e,"MM-DD-YYYY"),Object.assign(Object.assign({},t),{params:n})}var a=f.O.diffBetween(f.O.startOf(e.monthDate,"month"),f.O.startOf(w,"month"),"months"),o=a>-1*M,c=a<N,l={actionType:g.UserAction.Click,entity:g.EntityType.SpecialEvent,location:g.LocationContext.CalendarNav};function s(e){return f.O.format(e,"YYYY-MM-DD")}return r().createElement("div",{className:"d-flex justify-content-between align-items-center"},r().createElement("h1",{className:"mb-0 h2"},f.O.format(e.monthDate,t.xs?"MMM YYYY":"MMMM YYYY")),r().createElement("div",{className:"d-flex ".concat(O.actions)},o&&r().createElement(h.F,{appLink:n(f.O.startOf(f.O.subtract(e.monthDate,1,"month"),"month")),className:"d-flex",analyticsOptions:l,analyticsData:{action:"previous",date:s(f.O.startOf(f.O.add(e.monthDate,1,"month"),"month"))}},r().createElement(C,{action:"previous",onClick:function(){var t=f.O.subtract(e.monthDate,1,"month");e.setViewingMonthDate(t)}})),r().createElement(h.F,{appLink:n(w),className:"d-flex",analyticsOptions:l,analyticsData:{action:"today",date:s(f.O.startOf(w,"month"))}},r().createElement(D.L,{className:"".concat(O.todayWrapper," btn btn-outline-dark font-weight-500"),onClick:function(){f.O.format(w,"YYYY-MM-DD")!==f.O.format(e.monthDate,"YYYY-MM-DD")&&e.setViewingMonthDate(w)}},i.T.getPhrase(k,"today"))),c&&r().createElement(h.F,{appLink:n(f.O.startOf(f.O.add(e.monthDate,1,"month"),"month")),className:"d-flex",analyticsOptions:l,analyticsData:{action:"next",date:s(f.O.startOf(f.O.add(e.monthDate,1,"month"),"month"))}},r().createElement(C,{action:"next",onClick:function(){var t=f.O.add(e.monthDate,1,"month");e.setViewingMonthDate(t)}}))))}var A=n(99910),S=n(49985),I=n(54610),T=n(67453),x=n(2284),L=n(61557);const j={cellDate:"MvrIK",label:"UFPJm",numberWrapper:"PyWl_"};var U=i.T.encloseNamespace("specialEventCalendar.calendarCellDate");function P(e){var t=f.O.isToday(e.date),n="".concat(j.cellDate," d-flex flex-nowrap");return t&&(n+=" bg-dark text-white"),e.notCurrentMonth&&(n+=" text-secondary"),e.hasEvent&&(n+=" text-white"),e.className&&(n+=" ".concat(e.className)),r().createElement("div",{className:n},r().createElement("div",{className:"".concat(j.numberWrapper," ").concat("d-flex text-center justify-content-center align-items-center flex-shrink-0")},f.O.format(e.date,"D")),t&&r().createElement("div",{className:"".concat(j.label," justify-content-start align-items-center")},U("today")))}var H=n(29917);const R={tag:"UIeoi",date:"p1FoI",backgroundImage:"_33D7",eventCard:"MPgib",wrapper:"yvPrI",left:"KBv2n",right:"dowd6",noAnimation:"HWvit",cover:"hoJcZ",tagWrap:"VKCBZ",appear:"zh9Ja",comingSoon:"_VwjY",displayDate:"i5dV5",title:"od2i9",circle:"Y9ovs",active:"DSUJW",arrow:"RjkfI",bottomBar:"RlRw7",bottomPlaceholder:"Hs06S"};function _(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,c,i=[],l=!0,s=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=o.call(n)).done)&&(i.push(a.value),i.length!==t);l=!0);}catch(e){s=!0,r=e}finally{try{if(!l&&null!=n.return&&(c=n.return(),Object(c)!==c))return}finally{if(s)throw r}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return W(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?W(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function W(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}function F(e){var t,n,a=_(r().useState(0),2),o=a[0],c=a[1],i=e.eventsOnDay.length>1,l=e.eventsOnDay.find((function(e,t){return t===o})),s=!!l.endDate,u=l.content.metadata.backgroundColor,p=null===(t=l.content.icon)||void 0===t?void 0:t.url,v=T.j.createUrl(p,{size:I.h2.Small}),y=T.j.createUrl(null===(n=l.content.cover)||void 0===n?void 0:n.url,{size:I.h2.Small}),O=L.T.getTopicAppLink(l.content.id,l.name),k=l.content.status===x.W.ComingSoon,M={application:d.O.CALENDAR,action:m.e.Calendar.SPECIAL_EVENT_LIST,params:Object.assign(Object.assign({},e.monthQuery),{date:e.date.toString()})},N=_(r().useState(e.hasInited?R.appear:""),2),C=N[0],w=N[1];r().useEffect((function(){if(!e.hasInited){var t=Math.floor(600*Math.random()+400);window.setTimeout((function(){w(R.appear),e.setHasInited(!0)}),t)}}),[e.hasInited]);var Y=null;i?Y=M:k||(Y=O);var A=function(){var t={date:f.O.format(e.date,"YYYY-MM-DD"),presentationId:e.presentationId,eventCount:e.eventsOnDay.length};return i?(t.eventId=e.eventsOnDay.map((function(e){return e.specialEventId})).join(","),t.topicId=e.eventsOnDay.map((function(e){return e.content.id})).join(",")):(t.eventId=l.specialEventId,t.topicId=l.content.id,t.eventStatus=l.content.status),t}(),j={actionType:g.UserAction.Click,entity:g.EntityType.SpecialEvent,location:g.LocationContext.CalendarDay};function U(e){return f.O.format(e,"YYYY-MM-DD")}return r().createElement("div",{onClick:function(){k&&S.k.logUserAction(A,j)}},r().createElement(h.F,{appLink:Y,className:"d-flex justify-content-end",analyticsOptions:j,analyticsData:A},r().createElement("div",{className:"".concat(R.tagWrap," p-1")},k&&r().createElement(H.r,{className:"justify-content-center p-0 rounded-circle ".concat(R.tag," ").concat(C),onlyIcon:!0})),r().createElement(P,{date:e.date,notCurrentMonth:e.notCurrentMonth,className:"".concat(R.date," ").concat(C),hasEvent:!0}),r().createElement("div",{className:"postion-relative ".concat(R.wrapper)},r().createElement("div",{style:{backgroundImage:"url('".concat(v||y,"')")},className:"position-absolute ".concat(R.backgroundImage," ").concat(v?"":R.cover," ").concat(k?R.comingSoon:""," ").concat(C," ").concat(e.hasInited?R.noAnimation:"")}),r().createElement("div",{style:{backgroundColor:u},className:"position-absolute d-flex flex-column justify-content-end align-items-center text-white px-1 py-2 ".concat(R.eventCard," ").concat(C)},s&&r().createElement("div",{className:"".concat(R.displayDate," mb-1")},L.T.getDisplayDate(l.startDate,l.endDate)),r().createElement("div",{className:"text-center ".concat(R.title," mb-1")},s?r().createElement("div",{className:"clamp-1 h6",title:l.name},l.name):r().createElement("div",{className:"clamp-2 h6",title:l.name},l.name)),i&&0!==o&&r().createElement("div",{className:"position-absolute bg-white rounded-circle ".concat(R.left)},r().createElement(D.L,{onClick:function(t){t.stopPropagation(),t.preventDefault(),c((function(e){return e-1})),S.k.logUserAction({date:U(e.date),action:"previous",eventCount:e.eventsOnDay.length},j)}},r().createElement(b.x,{svgName:E.vn.ChevronLeft,className:"d-inline-block svg-container text-dark ".concat(R.arrow)}))),i&&o!==e.eventsOnDay.length-1&&r().createElement("div",{className:"position-absolute bg-white rounded-circle ".concat(R.right)},r().createElement(D.L,{onClick:function(t){t.stopPropagation(),t.preventDefault(),c((function(e){return e+1})),S.k.logUserAction({date:U(e.date),action:"next",eventCount:e.eventsOnDay.length},j)}},r().createElement(b.x,{svgName:E.vn.ChevronRight,className:"d-inline-block svg-container text-dark ".concat(R.arrow)}))),r().createElement("div",{className:"d-flex ".concat(R.bottomBar," ").concat(i?"":R.bottomPlaceholder)},e.eventsOnDay.map((function(t,n){var a=n===o;return r().createElement(D.L,{key:n,className:"".concat(R.circle," ").concat(a?R.active:""),onClick:function(t){t.stopPropagation(),t.preventDefault(),c(n),S.k.logUserAction({date:U(e.date),action:"jump",eventCount:e.eventsOnDay.length},j)}})})))))))}const B={wrapper:"ID5BX",notCurrentMonth:"KThJz",weekend:"Le3vK",cell:"GY1K5"};function V(e){var t=e.date,n=e.notCurrentMonth,a=e.eventsOnDay,o="position-relative border border-light-blue ".concat(B.wrapper);(function(e){return 0===f.O.getWeekday(e)||6===f.O.getWeekday(e)})(t)&&(o+=" ".concat(B.weekend)),n&&(o+=" ".concat(B.notCurrentMonth));var c=a.length>0;return r().createElement("td",{className:o},r().createElement("div",{className:B.cell},r().createElement(P,{date:t,notCurrentMonth:n}),c&&r().createElement(F,Object.assign({},e))))}var z=n(83345),J=n(23232),K=n(99742),Q="specialEvent.eventsEmptyState",Z=i.T.encloseNamespace(Q);function $(e){return r().createElement(z.D.Provider,{value:Q},r().createElement(J.u,null,r().createElement(J.u.Image,{src:K.W.EmptyStates.CALENDAR.NO_EVENTS}),r().createElement(J.u.Heading,null,r().createElement(z.x,{phrase:"heading"})),r().createElement(J.u.Info,null,r().createElement(z.x,{namespace:Q,phrase:"info"}),r().createElement(h.F,{appLink:e.appLink},r().createElement("span",{className:"text-blue"},Z("link"))))))}var G=n(13037);const X={date:"dn7Hd",first:"axdj4"};function q(e){var t={};e.events.forEach((function(e){var n=e.startDate;t[n]?t[n].push(e):t[n]=[e]}));var n=Object.keys(t);return n.sort((function(e,t){return f.O.isBefore(e,t)?-1:0})),r().createElement("div",{className:"py-1"},n.map((function(n,a){return r().createElement("div",{key:n},r().createElement("div",{className:"h4 mt-4 ".concat(X.date," ").concat(0===a?X.first:"")},L.T.getOrdinalDate(n)),t[n].map((function(t){return r().createElement(G.b,{key:t.content.id,getAppLink:L.T.getTopicAppLink,event:t,presentationId:e.presentationId})})))})))}const ee={header:"xLOrx",thead:"ef_XJ"};function te(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}function ne(e){var t,n,a=(0,v.k)(),o=L.T.getEventsInMonth(e.events||[],e.viewingMonth),c=(t=r().useState(!1),n=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,c,i=[],l=!0,s=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=o.call(n)).done)&&(i.push(a.value),i.length!==t);l=!0);}catch(e){s=!0,r=e}finally{try{if(!l&&null!=n.return&&(c=n.return(),Object(c)!==c))return}finally{if(s)throw r}}return i}}(t,n)||function(e,t){if(e){if("string"==typeof e)return te(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?te(e,t):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),i=c[0],l=c[1];return a.xs||a.sm||a.md?e.eventsLoaded?(null==o?void 0:o.length)?r().createElement(q,{events:o,presentationId:e.presentationId}):r().createElement($,{appLink:{application:d.O.CONTENT_UPDATES,action:m.e.ContentUpdates.CONTENT_UPDATES}}):r().createElement("div",{className:"d-flex justify-content-center align-items-center"},r().createElement(A.Spinner,{as:"div",animation:"border",role:"status"})):r().createElement("table",{className:"user-select-none w-100 mt-3 overflow-hidden rounded-top-lg"},r().createElement("thead",{className:"border border-light-blue ".concat(ee.thead)},r().createElement("tr",{className:"font-weight-500 bg-light-blue ".concat(ee.header)},e.weekDaysHeader.map((function(e){return r().createElement("th",{key:e,className:"px-2 h4"},e)})))),r().createElement("tbody",null,e.weekDays.map((function(t){return r().createElement("tr",{key:t[0].toString(),className:"font-weight-500"},t.map((function(t){var n,a=(null===(n=e.events)||void 0===n?void 0:n.filter((function(e){return e.startDate===f.O.format(t,"YYYY-MM-DD")})))||[];return r().createElement(V,{key:t.toString(),date:t,notCurrentMonth:!!t.notCurrentMonth,eventsOnDay:a,monthQuery:e.monthQuery,hasInited:i,setHasInited:l,presentationId:e.presentationId})})))}))))}var ae=n(75896);function re(e,t){for(var n=f.O.startOf(e,"month"),a=f.O.getWeekday(n),r=[],o=t?0===a?6:a-1:a,c=t?1:0;c<=o;c++){var i=n,l=f.O.weekday(i,a-c);r.push(Object.assign(l,{notCurrentMonth:!0}))}return r.reverse()}function oe(e,t){for(var n=f.O.endOf(e,"month"),a=f.O.getWeekday(n),r=[],o=t?7-(0===a?7:a):7-a,c=1;c<=o;c+=1){var i=f.O.add(n,c,"days");r.push(Object.assign(i,{notCurrentMonth:!0}))}return r}function ce(e){var t=f.O.startOf(e,"month");return 1===f.O.getWeekday(t)?t:ae.m.first(re(e,!0))}function ie(e){var t=f.O.endOf(e,"month");return 0===f.O.getWeekday(t)?t:ae.m.last(oe(e,!0))}function le(e){return[ce(e),ie(e)]}function se(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var ue=new Date;function de(){var e,t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ue,a=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],c=function(e){var t=e?[1,2,3,4,5,6,0]:[0,1,2,3,4,5,6],n=new Date;return t.map((function(e){return f.O.format(f.O.weekday(n,e),"ddd")}))}(a),i=r().useRef({}),l=(e=r().useState([]),t=2,function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,c,i=[],l=!0,s=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=o.call(n)).done)&&(i.push(a.value),i.length!==t);l=!0);}catch(e){s=!0,r=e}finally{try{if(!l&&null!=n.return&&(c=n.return(),Object(c)!==c))return}finally{if(s)throw r}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return se(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?se(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),s=l[0],u=l[1],p=f.O.format(n,"YYYY-MM");r().useEffect((function(){var e=i.current[p];if(e)u(e.weeksTable);else{var t=function(e,t){for(var n=[],a={},r=re(e,t).concat(function(e){for(var t=f.O.daysInMonth(e),n=[],a=1;a<=t;a++){var r=f.O.set(e,"date",a);n.push(Object.assign(r,{notCurrentMonth:!1}))}return n}(e)).concat(oe(e,t)),o=function(e){var t=r.slice(c,c+7);t.forEach((function(t,n){a[f.O.format(t,"YYYY-MM-DD")]={row:e,col:n}})),n.push(t),e++,i=e},c=0,i=0;c<r.length;c+=7)o(i);return{datePositionMap:a,weeksTable:n}}(n,a),r=t.weeksTable,o=t.datePositionMap;i.current[p]={weeksTable:r,datePositionMap:o},u(r)}}),[f.O.format(n,"YYYY-MM")]);var v=ae.m.first(ae.m.first(s)),h=ae.m.last(ae.m.last(s));return{weekDaysHeader:c,weekDays:s,monthDate:n,setMonthDate:function(e){p!==f.O.format(e,"YYYY-MM")&&o.Q.AppLinkHelper.trigger({application:d.O.CALENDAR,action:m.e.Calendar.CALENDAR,params:{monthDate:f.O.format(n,"MM-DD-YYYY")}})},startDate:v,endDate:h}}var me=n(20354),pe=n(39780);function fe(e){return function(e){if(Array.isArray(e))return ye(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||he(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ve(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,c,i=[],l=!0,s=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=o.call(n)).done)&&(i.push(a.value),i.length!==t);l=!0);}catch(e){s=!0,r=e}finally{try{if(!l&&null!=n.return&&(c=n.return(),Object(c)!==c))return}finally{if(s)throw r}}return i}}(e,t)||he(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function he(e,t){if(e){if("string"==typeof e)return ye(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ye(e,t):void 0}}function ye(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var ge=n(74590),be={whatsNew:{application:d.O.CONTENT_UPDATES,action:m.e.ContentUpdates.CONTENT_UPDATES},forYou:{application:d.O.DASHBOARD,action:m.e.Dashboard.HOME},calendar:{application:d.O.CALENDAR,action:m.e.Calendar.CALENDAR}},Ee=i.T.encloseNamespace("specialEventCalendar.calendarView");function De(e){(0,c.o)(Ee("pageTitle"));var t=(0,p.y)(l.R.Subject).presentation,n=(0,ge.N)(),a=n.showCalendar,i=n.isLoading;r().useEffect((function(){i||a||o.Q.AppLinkHelper.trigger(be.forYou,{replace:!0})}),[a,i]);var d=e.monthDate?new Date(e.monthDate):new Date,m=de(d),v=m.monthDate,h=m.setMonthDate,y=m.weekDays,g=m.weekDaysHeader,b=m.startDate,E=m.endDate,D=function(e){var t=(0,p.y)(l.R.Subject).presentation,n=null==t?void 0:t.id,a=ve(le(e),2),r=a[0],o=a[1],c=ve(le(f.O.add(e,1,"month")),2),i=c[0],s=c[1],u=ve(le(f.O.subtract(e,1,"month")),2),d=u[0],m=u[1],v=me.a.useBasicFetch(r&&o&&n&&pe.N.calendarEvents(f.O.format(r,"YYYY-MM-DD"),f.O.format(o,"YYYY-MM-DD"),n)),h=me.a.useBasicFetch(i&&s&&n&&pe.N.calendarEvents(f.O.format(i,"YYYY-MM-DD"),f.O.format(s,"YYYY-MM-DD"),n)),y=me.a.useBasicFetch(d&&m&&n&&pe.N.calendarEvents(f.O.format(d,"YYYY-MM-DD"),f.O.format(m,"YYYY-MM-DD"),n));return{events:ae.m.uniq([].concat(fe(y.data||[]),fe(v.data||[]),fe(h.data||[])),(function(e){return e.specialEventId})),loaded:v.hasCompleted}}(d),O=D.events,k=D.loaded;return i||!(null==t?void 0:t.id)?r().createElement(r().Fragment,null):r().createElement("div",{className:"bg-white px-3"},r().createElement(u.z,{type:s.DashboardUserType.Staff,appLinks:be,showCalendar:a,active:"calendar"}),r().createElement(Y,{monthDate:v,setViewingMonthDate:h}),r().createElement(ne,{weekDays:y,weekDaysHeader:g,events:O,monthQuery:{from:null==b?void 0:b.toString(),to:null==E?void 0:E.toString()},viewingMonth:d,eventsLoaded:k,presentationId:t.id}))}},87432:(e,t,n)=>{n.d(t,{Z:()=>a});const a={pillTabSelector:"Hdi6o",pillItem:"hUJx1"}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[8359],{54644:(e,t,a)=>{a.d(t,{v:()=>i});var n=a(97395),i={getContentUpdates:function(e,t,a){return{url:n._.urlBuilder("/api/domain/v1/subjects/content-updates",{from:t,to:a,limit:6,query:"(videoCollection)"}),publicUrl:n._.urlBuilder("/api/subjects/presentations/".concat(e,"/content-updates"),{from:t,to:a,limit:6,query:"(videoCollection)"}),key:"content:updates",normalizeOptions:{namespace:"contentupdates"},formatData:function(e){return e.map((function(e){return{id:e.classificationId,videos:e.videos}}))}}},getClassifications:function(e){return{url:n._.urlBuilder("/api/domain/v1/subjects",{id:e,query:"banner"}),publicUrl:n._.urlBuilder("/api/subjects/classifications",{id:e,query:"banner"}),key:"classifications:".concat(e.join(","))}},getClassification:function(e){return{url:"/api/domain/v1/subjects/".concat(e,"?query=banner"),publicUrl:"/api/subjects/classifications/".concat(e,"?query=banner"),key:"classification:".concat(e)}},getClassificationUpdates:function(e,t,a){return{url:n._.urlBuilder("/api/domain/v1/subjects/".concat(e,"/content-updates"),{from:t,to:a,query:"(videoCollection)"}),publicUrl:n._.urlBuilder("/api/subjects/classifications/".concat(e,"/content-updates"),{from:t,to:a,query:"(videoCollection)"}),key:"classification:update:".concat(e,":").concat(t,":").concat(a)}},getContentUpdateVideos:function(e,t){return{url:n._.urlBuilder("/api/domain/v1/subjects/content-updates/videos",{from:e,to:t,query:"(videoCollection)"}),publicUrl:n._.urlBuilder("/api/subjects/content-updates/videos",{from:e,to:t,query:"(videoCollection)"}),key:"content:update:videos:".concat(e,":").concat(t)}},videos:function(e,t){return{url:"/api/domain/v1/videos?ids=".concat(e.join(","),"&with=(videoCollection)"),key:"videos:by:id:".concat(e.join(",")),success:t}}}},3278:(e,t,a)=>{a.d(t,{z:()=>m});var n=a(1024),i=a.n(n),r=a(23481),o=a(83345),s=a(53957),c=a(38502),l=a(65858),d=a(55460);const u={pillTab:"bMJM0"};var p="discover.header";function m(e){var t,a,n,m,v,f;if(!e.type)return i().createElement(i().Fragment,null);if(e.type===s.DashboardUserType.Learner||e.hasStudentExperience)return i().createElement("div",{className:"py-3"},i().createElement("h1",{className:"h2 mb-0"},i().createElement(o.x,{namespace:p,phrase:"heading"})));var y=[{name:r.T.getPhrase(p,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===e.active,analyticsData:{name:r.T.getPhrase(p,"forYou"),url:d.AppLinkHelper.getHref(null===(a=e.appLinks)||void 0===a?void 0:a.forYou)},analyticsOptions:{actionType:l.UserAction.Click,entity:l.EntityType.Url,location:l.LocationContext.MagicTabs}},{name:r.T.getPhrase(p,"whatsNew"),appLink:null===(n=e.appLinks)||void 0===n?void 0:n.whatsNew,active:"whatsNew"===e.active,analyticsData:{name:r.T.getPhrase(p,"whatsNew"),url:d.AppLinkHelper.getHref(null===(m=e.appLinks)||void 0===m?void 0:m.whatsNew)},analyticsOptions:{actionType:l.UserAction.Click,entity:l.EntityType.Url,location:l.LocationContext.MagicTabs}}];return e.showCalendar&&y.push({name:r.T.getPhrase(p,"calendar"),appLink:null===(v=e.appLinks)||void 0===v?void 0:v.calendar,active:"calendar"===e.active,analyticsData:{name:r.T.getPhrase(p,"calendar"),url:d.AppLinkHelper.getHref(null===(f=e.appLinks)||void 0===f?void 0:f.calendar)},analyticsOptions:{actionType:l.UserAction.Click,entity:l.EntityType.Url,location:l.LocationContext.MagicTabs}}),i().createElement("div",{className:"py-3 text-center"},i().createElement(c.r,{tabs:y,className:u.pillTab}))}},38502:(e,t,a)=>{a.d(t,{r:()=>d});var n=a(1024),i=a.n(n),r=a(11607),o=a(8493),s=a(49985),c=a(87432),l=a(76246);function d(e){var t;return i().createElement("nav",{className:null!==(t=e.className)&&void 0!==t?t:""},i().createElement("ul",{className:"list-unstyled d-inline-block m-0 ".concat(c.Z.pillTabSelector)},e.tabs.map((function(e){return i().createElement("li",{className:"p-0 ".concat(e.active?"btn btn-dark":"btn btn-outline-dark"),key:e.name},e.appLink?i().createElement(o.F,{appLink:e.appLink,analyticsData:e.analyticsData,analyticsOptions:e.analyticsOptions,className:"cursor-pointer d-flex justify-content-center text-decoration-none text-reset px-2 ".concat(c.Z.pillItem)},e.name,"number"==typeof e.count&&i().createElement("div",{className:"pl-2"},i().createElement(l.C,{type:l.g.Count,data:e.count}))):i().createElement(r.L,{className:"".concat(c.Z.pillItem," d-flex justify-content-center p-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&s.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name,"number"==typeof e.count&&i().createElement("div",{className:"pl-2"},i().createElement(l.C,{type:l.g.Count,data:e.count}))))}))))}},74590:(e,t,a)=>{a.d(t,{N:()=>m});var n=a(1024),i=a.n(n),r=a(35242),o=a(55171),s=a(25925),c=a(37802),l=a(86698);function d(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var a=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var n,i,r,o,s=[],c=!0,l=!1;try{if(r=(a=a.call(e)).next,0===t){if(Object(a)!==a)return;c=!1}else for(;!(c=(n=r.call(a)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&null!=a.return&&(o=a.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?u(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,n=new Array(t);a<t;a++)n[a]=e[a];return n}var p=[o.e.PresentationIds.AU_PRIMARY,o.e.PresentationIds.US_ELEMENTARY,o.e.PresentationIds.ENGLAND_PRIMARY];function m(){var e=(0,c.r)(null),t=e.hasSpecialEventCalendar,a=e.isLoadingSettings,n=(0,l.y)(s.R.Subject).presentation,o=!a&&!t,u=(null==n?void 0:n.id)&&!p.includes(+n.id),m=d(i().useState(!o&&!u),2),v=m[0],f=m[1],y=d(i().useState(a||!(null==n?void 0:n.id)),2),b=y[0],g=y[1];return i().useEffect((function(){o||u?f(!1):b||f(!0),g(a||!(null==n?void 0:n.id))}),[t,null==n?void 0:n.id,b]),r.h.isDevelopment?{showCalendar:!0,isLoading:!1}:{showCalendar:v,isLoading:b}}},3865:(e,t,a)=>{a.d(t,{_:()=>l});var n=a(97395),i=a(62803),r=a(4434),o=function(e,t){return"widget:".concat(e,":").concat(t)},s=function(e){return n._.urlBuilder("/api/domain/v3/dashboards/widgets",{libraryType:e})},c=function(e){return"{gateway}/v1/objects/".concat(e,"?query=videos[").concat(r.H.WIDGET_VIDEO_COLLECTION,"]{orderBy:orderindex}")},l={widgets:function(e){return{url:s(e),key:"widgets:v3:".concat(e)}},playlist:function(e,t){return{url:c(e),key:o(e,t)}},getPlaylistVideos:function(e,t){var a={query:"(videos[".concat(i.v.VIDEO_COLLECTION,"]){orderBy:orderindex,limit:100}")};return t&&(a.cursor=t),{url:n._.urlBuilder("{gateway}/v1/objects/".concat(e,"/members"),a),key:"widget:videos:".concat(e,":").concat(t)}}}},40286:(e,t,a)=>{a.r(t),a.d(t,{DiscoverViewWrapper:()=>Ie});var n,i=a(1024),r=a.n(i),o=a(37802),s=a(65858),c=a(39479),l=a(33192),d=a(20354),u=a(2948),p=a(23481),m=a(23049),v=a(57900),f=a(75896),y=a(53957);!function(e){e[e.HostedLibrary=0]="HostedLibrary",e[e.Exchange=1]="Exchange",e[e.MoviesAndTvLibrary=2]="MoviesAndTvLibrary"}(n||(n={}));var b=a(58704),g=a(31949),h=a(5281),E=a(96519),C=a(21750),S=a(38143),T=a(69454),A=a(54644),L=a(22902),I=a(16714),O=a(45739),D=a(97037),k=a(14070),N=a(97291),U=a(25925),w=a(39151),F=a(28400),P=a(87348),j=a(64628),x=a(41523),B=a(65203),_=a(93475),R=a(3865),M=a(83345),H=a(10874),Y=a(58130),q=a(99742);const V={banner:"Vqx6B"};var W="shared.upgradeVideoBanner";function G(){return i.createElement("div",{className:"py-4 px-3 rounded h4 ".concat(V.banner," border"),style:{backgroundImage:'url("'.concat(q.W.Upgrade.VIDEO_BANNER,'")')}},i.createElement(M.x,{namespace:W,phrase:"message"}),i.createElement(H.h,{svgName:Y.vn.Play,appLink:{application:N.O.DEFAULT,action:k.e.Default.LITE_UPGRADE_VIDEO},className:"btn btn-outline-dark ml-3 align-middle"},i.createElement(M.x,{namespace:W,phrase:"button"})))}var z=a(490),J=a(9408),Z=a(3278),$=a(1666),Q=a(74590);function K(e){return function(e){if(Array.isArray(e))return ee(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||X(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function X(e,t){if(e){if("string"==typeof e)return ee(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?ee(e,t):void 0}}function ee(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,n=new Array(t);a<t;a++)n[a]=e[a];return n}var te=p.T.encloseNamespace("dashboard.dashboard"),ae="explore-all-topics",ne={video:{application:N.O.VIDEOS,action:k.e.Videos.PLAY_VIDEO},collection:{application:N.O.DASHBOARD,action:k.e.Dashboard.DASHBOARD},series:{application:N.O.SERIES,action:k.e.Series.SERIES},classification:{application:N.O.SUBJECT,action:k.e.Subjects.CLASSIFICATION},contentUpdates:{application:N.O.CONTENT_UPDATES,action:k.e.ContentUpdates.CONTENT_UPDATES},allClassifications:{application:N.O.SUBJECT,action:k.e.Subjects.CLASSIFICATION_ALL},discover:{application:N.O.DASHBOARD,action:k.e.Dashboard.HOME},calendar:{application:N.O.CALENDAR,action:k.e.Calendar.CALENDAR}};function ie(e,t,a){return d.a.useBasicFetch(a?R._.playlist(e,null==t?void 0:t.id):null)}function re(){var e,t,a,r,o,p,k,N,M,H=(0,D.c)(s.LocationContext.ExpandableVideoThumbnail),Y=H.setFavourite,q=H.canFavourite,V=d.a.useBasicFetch(w.L.config()),W=d.a.useBasicFetch(C.x.presentation(U.R.Subject)),ee=d.a.useBasicFetch(C.x.availablePresentations(U.R.Subject)),re=d.a.useBasicFetch(g.N.currentUser()),oe=d.a.useBasicFetch((null===(e=re.data)||void 0===e?void 0:e.isAuthenticated)&&$.h.yearGroups(re.data.customerId)),se=(k=(null==(p=re.data)?void 0:p.countryCode)&&R._.widgets(n.HostedLibrary),d.a.useBasicFetch(k).data),ce=function(e,t){var a,n=d.a.useBasicFetch(w.L.config()),i=O.i.getFeaturedTopic(null==t?void 0:t.id,null===(a=n.data)||void 0===a?void 0:a.featuredTopics);return d.a.useBasicFetch((null==i?void 0:i.id)&&C.x.classification(i.id,null==e?void 0:e.id))}(re.data,W.data),le=function(e){var t,a,n=null,i=!e.isFetching,r=d.a.useBasicFetch(i&&C.x.classifications());return(null===(t=r.data)||void 0===t?void 0:t.length)&&(n=(null===(a=e.data)||void 0===a?void 0:a.id)?r.data.filter((function(t){return t.id!==e.data.id})):r.data),Object.assign(Object.assign({},r),{data:n})}(ce),de=(N=l().subtract(1,"year").endOf("day").format("YYYY-MM-DD"),M=l().endOf("day").format("YYYY-MM-DD"),d.a.useBasicFetch(A.v.getContentUpdateVideos(N,M))),ue=O.i.getPresentationLevelImage(null===(t=W.data)||void 0===t?void 0:t.learningLevel,"new-release-banner"),pe=f.m.last(ue.split("/")),me=(0,L.T)().hasPermissions,ve=(0,P.Q)();(0,m.o)(te("pageTitle"));var fe,ye,be=(fe=(0,u.D)(S.g.AUDIENCE_FILTER,void 0,{storage:v.Z1.SessionStorage}),ye=1,function(e){if(Array.isArray(e))return e}(fe)||function(e,t){var a=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var n,i,r,o,s=[],c=!0,l=!1;try{if(r=(a=a.call(e)).next,0===t){if(Object(a)!==a)return;c=!1}else for(;!(c=(n=r.call(a)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&null!=a.return&&(o=a.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}(fe,ye)||X(fe,ye)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],ge=(0,Q.N)(),he=ge.showCalendar,Ee=ge.isLoading;return i.createElement("div",{className:"bg-white px-3"},ve.isUpgrading&&!me(I.C.StudentExperience)&&i.createElement(G,null),!Ee&&i.createElement(Z.z,{type:me(I.C.StudentExperience)?y.DashboardUserType.Learner:y.DashboardUserType.Staff,appLinks:{forYou:ne.discover,whatsNew:ne.contentUpdates,calendar:ne.calendar},showCalendar:he,active:"forYou"}),i.createElement("div",{className:"pb-3"},le.hasCompleted?i.createElement(j.f,{appLinks:{allTopics:function(){return ne.allClassifications},classification:function(e){return Object.assign(Object.assign({},ne.classification),{args:[e.id,F.m.slugify(e.name)],params:T.T.getAudienceParams(be)})}},name:me(I.C.StudentExperience)?te("topicsHeadingLearner"):te("topicsHeadingStaff"),content:[{id:ae,name:O.i.getExploreAllTopicsTitle(null===(a=W.data)||void 0===a?void 0:a.name,null===(r=ee.data)||void 0===r?void 0:r.length),tallPoster:{url:O.i.getPresentationLevelImage(null===(o=W.data)||void 0===o?void 0:o.learningLevel,"tall-poster")}}].concat(K(le.data))}):i.createElement(x.J,null)),!!ce.data&&i.createElement("div",{className:"pb-3"},i.createElement(z.U,{appLinks:{classification:function(){return Object.assign(Object.assign({},ne.classification),{args:[ce.data.id,ce.data.slug]})}},content:[ce.data],name:ce.data.name,yearGroups:oe.data})),ce.isFetching&&i.createElement("div",{className:"pb-3"},i.createElement(J.D,null)),!me(I.C.StudentExperience)&&i.createElement("div",{className:"pb-3"},de.hasCompleted?i.createElement(B.o,{content:de.data,appLinks:{latestReleases:function(){return ne.contentUpdates},videoType:function(e){return Object.assign(Object.assign({},ne.video),{args:[e.id,F.m.slugify(e.name)]})},series:function(){return ne.series}},name:te("latestReleases"),setFavourite:Y,canFavourite:q,metadata:{appLink:y.CuratedDashboardAppLink.LatestReleases,imageId:pe},imageCdnUrl:V.data.imageCdnUrl,limitTotalItems:!0,yearGroups:oe.data}):i.createElement(_.B,null)),se&&i.createElement(i.Fragment,null,se.map((function(e,t){return i.createElement("div",{key:t,className:"pb-3"},i.createElement(h.k,{type:e.type,contents:b.z.Videos,fetch:c.partial(ie,e.collectionId.toString(),re.data),setData:function(e){var t;return null===(t=null==e?void 0:e.videos)||void 0===t?void 0:t.data},lazyLoad:!0,childComponent:E.E,extraChildComponentProps:{seriesAppLink:ne.series,setFavourite:Y,canFavourite:q},appLink:ne.collection,getChildAppLink:function(e){return Object.assign(Object.assign({},ne.video),{args:[e.id,F.m.slugify(e.name)]})},minimumItemCount:3,limitTotalItems:!0}))}))))}var oe=a(61226),se=a(21366),ce=a(23232),le=a(36532),de="subjects.discoverDashboardEmptyState";function ue(e){var t,a,n=(null===(t=e.dashboard)||void 0===t?void 0:t.status)===y.DashboardStatus.Archived;return r().createElement(ce.u,null,r().createElement(ce.u.Image,{src:e.imageUrl}),r().createElement(ce.u.Heading,null,r().createElement(M.x,{namespace:de,phrase:"heading"})),r().createElement(ce.u.Info,null,r().createElement(M.x,{namespace:de,phrase:"info"})),r().createElement(le.u,{title:n?p.T.getPhrase(de,"archivedCtaTooltip"):"",spanHack:!0},r().createElement(ce.u.Cta,{text:p.T.getPhrase(de,"add"),appLink:null===(a=e.addWidgetApplink)||void 0===a?void 0:a.call(e),className:"btn btn-dark",icon:Y.vn.Plus,disabled:n})))}function pe(e){var t,a,n=f.m.sortBy(null===(t=e.dashboard)||void 0===t?void 0:t.widgets,"index");function i(t,a,n){var i=se.S.getWidgetParams(a,n,se.S.getDashboardTargetType(e.dashboard));return e.getWidgetContentRequest(t,i)}var o=e.isReadonly&&!(null==n?void 0:n.length);return r().createElement(r().Fragment,null,r().createElement(Z.z,{type:null===(a=e.dashboard)||void 0===a?void 0:a.userType,appLinks:e.headerAppLinks,hasStudentExperience:e.hasStudentExperience,showCalendar:e.showCalendar,active:"forYou"}),n.map((function(t){return r().createElement(oe.L,{key:t.id,id:t.id,imageCdnUrl:e.imageCdnUrl,getContentRequest:i,audiences:e.audiences,name:t.name,description:t.description,templateId:t.templateId,metadata:t.metadata,presentation:e.presentation,setFavourite:e.setFavourite,canFavourite:e.canFavourite,appLinks:e.widgetAppLinks,isScrollToTargetWidget:(null==e?void 0:e.scrollToWidgetId)===t.id,widgetTypeId:t.widgetId,canManageDiscoverPreferences:e.canManageDiscoverPreferences,onSubmitFeedback:e.onSubmitFeedback,updatePreferences:e.updatePreferences,yearGroups:e.yearGroups,lazyLoad:e.lazyLoad})})),o&&r().createElement(ue,{dashboard:e.dashboard,isReadonly:e.isReadonly,imageUrl:e.emptyImageUrl,addWidgetApplink:e.widgetAppLinks.widgetWizard}))}var me=a(80889),ve=a(49985),fe=a(52333),ye=a(18921),be=a(42617),ge=a(89454),he=a(67753),Ee=a(86698),Ce="classification-latest-releases",Se=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=(0,L.T)().hasPermissions,n=t.presentationId&&t.dashboardId&&"true"===t.preview,i=a(I.C.StudentExperience),r=d.a.useBasicFetch(e&&n&&g.N.groups(e)),o=(0,Ee.y)(U.R.Subject).presentation,s=d.a.useBasicFetch(t.presentationId&&C.x.presentationById(t.presentationId)),c=(!n||r.hasCompleted)&&!!o,l=function(){var e,a;if(!c)return{presentationId:null==o?void 0:o.id};if(!n)return{presentationId:null==o?void 0:o.id};var i=[be.j.Curator,be.j.Content,be.j.Developer];return(null===(a=null===(e=r.data)||void 0===e?void 0:e.data)||void 0===a?void 0:a.find((function(e){return i.includes(e.name)})))?{dashboardId:t.dashboardId,presentationId:t.presentationId}:{presentationId:null==o?void 0:o.id}}(),u=l.presentationId,p=l.dashboardId,m=d.a.useBasicFetch(c&&me._.discoverDashboard(u,function(){if(!p)return i?y.DashboardUserType.Learner:y.DashboardUserType.Staff}(),p?[y.DashboardStatus.Published,y.DashboardStatus.Draft,y.DashboardStatus.Archived]:[y.DashboardStatus.Published],p)),v=p?s.data:o;return{dashboard:m,presentation:v,audiences:d.a.useBasicFetch(v&&ge.O.presentationAudiences(v.id)),isPreviewing:!!p}};function Te(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,n=new Array(t);a<t;a++)n[a]=e[a];return n}var Ae=p.T.encloseNamespace("dashboard.dashboard");function Le(e){var t,a,n,i=d.a.useBasicFetch(w.L.config()),o=d.a.useBasicFetch(g.N.currentUser()),c=(0,L.T)(),l=c.hasLocalPermissions,p=c.hasPermissions,f=d.a.useBasicFetch(l(I.E.ManageDiscoverPreferences)&&o.data&&$.h.customer(o.data.customerId)),b=d.a.useBasicFetch((null===(t=o.data)||void 0===t?void 0:t.isAuthenticated)&&$.h.yearGroups(o.data.customerId)),h=Se(null===(a=o.data)||void 0===a?void 0:a.id,e.queryParams),E=h.dashboard,C=h.presentation,A=h.audiences,O=(0,P.Q)(),U=d.a.useGetFetchAsync(),j=(0,D.c)(s.LocationContext.Dashboard),x=j.setFavourite,B=j.canFavourite;(0,m.o)(Ae("pageTitle"));var _,R,M,H=(_=(0,u.D)(S.g.AUDIENCE_FILTER,void 0,{storage:v.Z1.SessionStorage}),R=1,function(e){if(Array.isArray(e))return e}(_)||function(e,t){var a=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var n,i,r,o,s=[],c=!0,l=!1;try{if(r=(a=a.call(e)).next,0===t){if(Object(a)!==a)return;c=!1}else for(;!(c=(n=r.call(a)).done)&&(s.push(n.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&null!=a.return&&(o=a.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}(_,R)||function(e,t){if(e){if("string"==typeof e)return Te(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?Te(e,t):void 0}}(_,R)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],Y=(M=T.T.getAudienceParams(H),{classification:function(e){return{application:N.O.SUBJECT,action:k.e.Subjects.CLASSIFICATION,args:[null==e?void 0:e.id,F.m.slugify(null==e?void 0:e.name)],params:M||{}}},classificationTopics:function(){return{application:N.O.SUBJECT,action:k.e.Subjects.CLASSIFICATION_TOPICS,params:M||{}}},videoType:function(e){return he.W.getAppLink(e)},series:function(e){return{application:N.O.SERIES,action:k.e.Series.SERIES,args:e?[e.id,F.m.slugify(e.name)]:[]}},playlist:function(e){return{application:N.O.PLAYLISTS,action:k.e.Playlists.PLAYLIST,args:[e.id,F.m.slugify(e.name)]}},latestReleases:function(){return{application:N.O.CONTENT_UPDATES,action:k.e.ContentUpdates.CONTENT_UPDATES}},allTopics:function(){return{application:N.O.SUBJECT,action:k.e.Subjects.CLASSIFICATION_ALL}},classificationLatestReleases:function(e){return e.id===Ce?{application:N.O.CONTENT_UPDATES,action:k.e.ContentUpdates.CONTENT_UPDATES}:{application:N.O.CONTENT_UPDATES,action:k.e.ContentUpdates.CLASSIFICATION_UPDATE,args:[e.id,F.m.slugify(e.name)]}},widgetVideoList:function(e,t){return{application:N.O.DASHBOARD,action:k.e.Dashboard.DASHBOARD,args:[e,F.m.slugify(t)]}}}),q=(0,Q.N)().showCalendar;return r().createElement("div",{className:"bg-white px-4"},O.isUpgrading&&(null===(n=E.data)||void 0===n?void 0:n.userType)===y.DashboardUserType.Staff&&r().createElement(G,null),r().createElement(pe,{currentUser:o.data,dashboard:E.data,widgetAppLinks:Y,headerAppLinks:{forYou:{application:N.O.DASHBOARD,action:k.e.Dashboard.HOME},whatsNew:{application:N.O.CONTENT_UPDATES,action:k.e.ContentUpdates.CONTENT_UPDATES},calendar:{application:N.O.CALENDAR,action:k.e.Calendar.CALENDAR}},presentation:C,imageCdnUrl:i.data.imageCdnUrl,getWidgetContentRequest:me._.dashboardWidgetContent,setFavourite:x,audiences:A.data,canFavourite:B,updatePreferences:function(e,t){return U(me._.updateWidgetPreferences(e,t,o.data))},canManageDiscoverPreferences:l(I.E.ManageDiscoverPreferences),onSubmitFeedback:p(I.C.CanSubmitFeedback)&&function(e){var t=U(fe.n.sendDiscoverFooterFeedback(e,o.data,f.data,C,E.data,p(I.C.StudentExperience)));return ve.k.logUserAction({feedbackType:e.type,content:e.content,presentationId:C.id,dashboardId:E.data.id},{actionType:s.UserAction.Submit,location:s.LocationContext.DiscoverFooter,entity:s.EntityType.Feedback,workflowPhase:s.WorkflowPhase.Complete}),t},hasStudentExperience:p(I.C.StudentExperience),yearGroups:b.data,lazyLoad:!ye.f.isBot(),showCalendar:q}))}function Ie(e){var t=(0,o.r)(s.LocationContext.Classification),a=t.hasCuratedDiscoverDashboards;return t.isLoadingSettings?r().createElement(r().Fragment,null):a?r().createElement(Le,Object.assign({},e)):r().createElement(re,null)}},87432:(e,t,a)=>{a.d(t,{Z:()=>n});const n={pillTabSelector:"Hdi6o",pillItem:"hUJx1"}}}]);