@clickview/lite 0.15.4-rc.0 → 0.15.4-rc.1
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.
- package/dist/bundles.json +1 -1
- package/dist/scripts/{2323-c90b66fda8-lite.chunk.js → 2323-619b7455bd-lite.chunk.js} +1 -1
- package/dist/scripts/3696-c841b16883-lite.chunk.js +1 -0
- package/dist/scripts/{5370-d4c93ce919-lite.chunk.js → 5370-d25d2e5d60-lite.chunk.js} +1 -1
- package/dist/scripts/9304-8e1507b512-lite.chunk.js +1 -0
- package/dist/scripts/bundle-53dff3b335.min.js +2 -0
- package/package.json +2 -2
- package/dist/scripts/3696-4c9277b56d-lite.chunk.js +0 -1
- package/dist/scripts/9304-c8444423bf-lite.chunk.js +0 -1
- package/dist/scripts/bundle-13cd35aae4.min.js +0 -2
- /package/dist/scripts/{bundle-13cd35aae4.min.js.LICENSE.txt → bundle-53dff3b335.min.js.LICENSE.txt} +0 -0
package/dist/bundles.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[2323],{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}}}},43482:(e,t,a)=>{a.d(t,{z:()=>m});var n=a(1024),i=a.n(n),r=a(81886),o=a(23481),s=a(83345),c=a(53957),l=a(38502),d=a(65858),u=a(55460),p="discover.header";function m(e){var t,a,n,m;if(!e.type)return i().createElement(i().Fragment,null);if(e.type===c.DashboardUserType.Learner)return i().createElement("div",{className:"py-3"},i().createElement("h1",{className:"h2 mb-0"},i().createElement(s.x,{namespace:p,phrase:"heading"})));function v(){var t,a=r.Q.AppLinkHelper.getCurrentAppLink();return(null===(t=e.appLinks)||void 0===t?void 0:t.newReleases.action)===a.action?"newReleases":"forYou"}return i().createElement("div",{className:"py-3 text-center"},i().createElement(l.r,{tabs:[{name:o.T.getPhrase(p,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===v(),analyticsData:{name:o.T.getPhrase(p,"forYou"),url:u.AppLinkHelper.getHref(null===(a=e.appLinks)||void 0===a?void 0:a.forYou)},analyticsOptions:{actionType:d.UserAction.Click,entity:d.EntityType.Url,location:d.LocationContext.MagicTabs}},{name:o.T.getPhrase(p,"newReleases"),appLink:null===(n=e.appLinks)||void 0===n?void 0:n.newReleases,active:"newReleases"===v(),analyticsData:{name:o.T.getPhrase(p,"newReleases"),url:u.AppLinkHelper.getHref(null===(m=e.appLinks)||void 0===m?void 0:m.newReleases)},analyticsOptions:{actionType:d.UserAction.Click,entity:d.EntityType.Url,location:d.LocationContext.MagicTabs}}]}))}},38502:(e,t,a)=>{a.d(t,{r:()=>l});var n=a(1024),i=a.n(n),r=a(11607),o=a(8493),s=a(87432),c=a(49985);function l(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(s.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-block text-decoration-none text-reset px-2 ".concat(s.Z.pillItem)},e.name):i().createElement(r.L,{className:"".concat(s.Z.pillItem," px-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&c.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name))}))))}},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:()=>Te});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),g=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),y=a(31949),h=a(5281),E=a(96519),T=a(21750),C=a(38143),S=a(69454),I=a(54644),L=a(22902),A=a(16714),O=a(45739),k=a(97037),D=a(14070),U=a(97291),F=a(25925),N=a(39151),P=a(28400),w=a(87348),j=a(64628),x=a(41523),B=a(65203),_=a(93475),R=a(3865),H=a(83345),Y=a(10874),q=a(58130),M=a(99742);var V="shared.upgradeVideoBanner";function W(){return i.createElement("div",{className:"py-4 px-3 rounded h4 ".concat("Vqx6B"," border"),style:{backgroundImage:'url("'.concat(M.W.Upgrade.VIDEO_BANNER,'")')}},i.createElement(H.x,{namespace:V,phrase:"message"}),i.createElement(Y.h,{svgName:q.vn.Play,appLink:{application:U.O.DEFAULT,action:D.e.Default.LITE_UPGRADE_VIDEO},className:"btn btn-outline-dark ml-3 align-middle"},i.createElement(H.x,{namespace:V,phrase:"button"})))}var z=a(490),J=a(9408),Z=a(43482);function G(e){return function(e){if(Array.isArray(e))return $(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Q(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 Q(e,t){if(e){if("string"==typeof e)return $(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)?$(e,t):void 0}}function $(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 K=p.T.encloseNamespace("dashboard.dashboard"),X="explore-all-topics",ee={video:{application:U.O.VIDEOS,action:D.e.Videos.PLAY_VIDEO},collection:{application:U.O.DASHBOARD,action:D.e.Dashboard.DASHBOARD},series:{application:U.O.SERIES,action:D.e.Series.SERIES},classification:{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION},contentUpdates:{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES},allClassifications:{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION_ALL},discover:{application:U.O.DASHBOARD,action:D.e.Dashboard.HOME}};function te(e,t,a){return d.a.useBasicFetch(a?R._.playlist(e,null==t?void 0:t.id):null)}function ae(){var e,t,a,r,o,p,D,U,H=(0,k.c)(s.LocationContext.ExpandableVideoThumbnail),Y=H.setFavourite,q=H.canFavourite,M=d.a.useBasicFetch(N.L.config()),V=d.a.useBasicFetch(T.x.presentation()),$=d.a.useBasicFetch(T.x.availablePresentations(F.R.Subject)),ae=d.a.useBasicFetch(y.N.currentUser()),ne=(p=(null==(o=ae.data)?void 0:o.countryCode)&&R._.widgets(n.HostedLibrary),d.a.useBasicFetch(p).data),ie=function(e,t){var a,n=d.a.useBasicFetch(N.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)&&T.x.classification(i.id,null==e?void 0:e.id))}(ae.data,V.data),re=function(e){var t,a,n=null,i=!e.isFetching,r=d.a.useBasicFetch(i&&T.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})}(ie),oe=(D=l().subtract(1,"year").endOf("day").format("YYYY-MM-DD"),U=l().endOf("day").format("YYYY-MM-DD"),d.a.useBasicFetch(I.v.getContentUpdateVideos(D,U))),se=O.i.getPresentationLevelImage(null===(e=V.data)||void 0===e?void 0:e.learningLevel,"new-release-banner"),ce=f.m.last(se.split("/")),le=(0,L.T)().hasPermissions,de=(0,w.Q)();(0,m.o)(K("pageTitle"));var ue,pe,me=(ue=(0,u.D)(C.g.AUDIENCE_FILTER,void 0,{storage:v.Z1.SessionStorage}),pe=1,function(e){if(Array.isArray(e))return e}(ue)||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}}(ue,pe)||Q(ue,pe)||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 i.createElement("div",{className:"bg-white px-3"},de.isUpgrading&&!le(A.C.StudentExperience)&&i.createElement(W,null),i.createElement(Z.z,{type:le(A.C.StudentExperience)?g.DashboardUserType.Learner:g.DashboardUserType.Staff,appLinks:{forYou:ee.discover,newReleases:ee.contentUpdates}}),re.hasCompleted?i.createElement(j.f,{appLinks:{allTopics:function(){return ee.allClassifications},classification:function(e){return Object.assign(Object.assign({},ee.classification),{args:[e.id,P.m.slugify(e.name)],params:S.T.getAudienceParams(me)})}},name:le(A.C.StudentExperience)?K("topicsHeadingLearner"):K("topicsHeadingStaff"),content:[{id:X,name:O.i.getExploreAllTopicsTitle(null===(t=V.data)||void 0===t?void 0:t.name,null===(a=$.data)||void 0===a?void 0:a.length),tallPoster:{url:O.i.getPresentationLevelImage(null===(r=V.data)||void 0===r?void 0:r.learningLevel,"tall-poster")}}].concat(G(re.data))}):i.createElement(x.J,null),!!ie.data&&i.createElement("div",{className:"px-1"},i.createElement(z.U,{appLinks:{classification:function(){return Object.assign(Object.assign({},ee.classification),{args:[ie.data.id,ie.data.slug]})}},content:[ie.data],name:ie.data.name})),ie.isFetching&&i.createElement("div",{className:"px-1"},i.createElement(J.D,null)),!le(A.C.StudentExperience)&&i.createElement(i.Fragment,null,oe.hasCompleted?i.createElement(B.o,{content:oe.data,appLinks:{latestReleases:function(){return ee.contentUpdates},videoType:function(e){return Object.assign(Object.assign({},ee.video),{args:[e.id,P.m.slugify(e.name)]})},series:function(){return ee.series}},name:K("latestReleases"),setFavourite:Y,canFavourite:q,metadata:{appLink:g.CuratedDashboardAppLink.LatestReleases,imageId:ce},imageCdnUrl:M.data.imageCdnUrl,limitTotalItems:!0}):i.createElement(_.B,null)),ne&&i.createElement(i.Fragment,null,ne.map((function(e,t){return i.createElement(h.k,{key:t,type:e.type,contents:b.z.Videos,fetch:c.partial(te,e.collectionId.toString(),ae.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:ee.series,setFavourite:Y},appLink:ee.collection,getChildAppLink:function(e){return Object.assign(Object.assign({},ee.video),{args:[e.id,P.m.slugify(e.name)]})},minimumItemCount:3,limitTotalItems:!0})}))))}var ne=a(50008),ie=a(21366),re=a(23232),oe=a(36532),se="subjects.discoverDashboardEmptyState";function ce(e){var t,a,n=(null===(t=e.dashboard)||void 0===t?void 0:t.status)===g.DashboardStatus.Archived;return r().createElement(re.u,null,r().createElement(re.u.Image,{src:e.imageUrl}),r().createElement(re.u.Heading,null,r().createElement(H.x,{namespace:se,phrase:"heading"})),r().createElement(re.u.Info,null,r().createElement(H.x,{namespace:se,phrase:"info"})),r().createElement(oe.u,{title:n?p.T.getPhrase(se,"archivedCtaTooltip"):"",spanHack:!0},r().createElement(re.u.Cta,{text:p.T.getPhrase(se,"add"),appLink:null===(a=e.addWidgetApplink)||void 0===a?void 0:a.call(e),className:"btn btn-dark",icon:q.vn.Plus,disabled:n})))}function le(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=ie.S.getWidgetParams(a,n,ie.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}),r().createElement("div",{className:"px-1"},n.map((function(t){return r().createElement(ne.L,{key:t.id,id:t.id,imageCdnUrl:e.imageCdnUrl,getContentRequest:i,name:t.name,description:t.description,templateId:t.templateId,metadata:t.metadata,presentation:e.presentation,audiences:e.audiences,setFavourite:e.setFavourite,canFavourite:e.canFavourite,appLinks:e.widgetAppLinks,isScrollToTargetWidget:(null==e?void 0:e.scrollToWidgetId)===t.id,widgetTypeId:t.widgetId,canManageDiscoverPreferences:e.canManageDiscoverPreferences,updatePreferences:e.updatePreferences,onSubmitFeedback:e.onSubmitFeedback})}))),o&&r().createElement(ce,{dashboard:e.dashboard,isReadonly:e.isReadonly,imageUrl:e.emptyImageUrl,addWidgetApplink:e.widgetAppLinks.widgetWizard}))}var de=a(80889),ue=a(49985),pe=a(52333),me=a(42617),ve=a(89454),fe=a(22490),ge=a(51200),be=a(1666);function ye(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 he=p.T.encloseNamespace("dashboard.dashboard");function Ee(e){var t,a,n=d.a.useBasicFetch(N.L.config()),i=d.a.useBasicFetch(y.N.currentUser()),o=d.a.useBasicFetch(i.data&&be.h.customer(i.data.customerId)),c=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(A.C.StudentExperience),r=d.a.useBasicFetch(e&&n&&y.N.groups(e)),o=(0,ge.I)().presentation,s=d.a.useBasicFetch(t.presentationId&&T.x.presentationById(t.presentationId)),c=(!n||r.hasCompleted)&&!!o;function l(){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=[me.j.Curator,me.j.Content,me.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}}var u=l(),p=u.presentationId,m=u.dashboardId;function v(){if(!m)return i?g.DashboardUserType.Learner:g.DashboardUserType.Staff}function f(){return m?[g.DashboardStatus.Published,g.DashboardStatus.Draft,g.DashboardStatus.Archived]:[g.DashboardStatus.Published]}var b=d.a.useBasicFetch(c&&de._.discoverDashboard(p,v(),f(),m)),h=m?s.data:o,E=d.a.useBasicFetch(h&&ve.O.presentationAudiences(h.id));return{dashboard:b,presentation:h,audiences:E,isPreviewing:!!m}}(null===(t=i.data)||void 0===t?void 0:t.id,e.queryParams),l=c.dashboard,p=c.presentation,f=c.audiences,b=(0,w.Q)(),h=d.a.useGetFetchAsync(),E=(0,k.c)(s.LocationContext.Dashboard),I=E.setFavourite,O=E.canFavourite,F=(0,L.T)(),j=F.hasLocalPermissions,x=F.hasPermissions;(0,m.o)(he("pageTitle"));var B,_,R,H=(B=(0,u.D)(C.g.AUDIENCE_FILTER,void 0,{storage:v.Z1.SessionStorage}),_=1,function(e){if(Array.isArray(e))return e}(B)||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}}(B,_)||function(e,t){if(e){if("string"==typeof e)return ye(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)?ye(e,t):void 0}}(B,_)||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=(R=S.T.getAudienceParams(H),{classification:function(e){return{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION,args:[null==e?void 0:e.id,P.m.slugify(null==e?void 0:e.name)],params:R||{}}},classificationTopics:function(){return{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION_TOPICS,params:R||{}}},videoType:function(e){return fe.W.getAppLink(e)},series:function(e){return{application:U.O.SERIES,action:D.e.Series.SERIES,args:e?[e.id,P.m.slugify(e.name)]:[]}},playlist:function(e){return{application:U.O.PLAYLISTS,action:D.e.Playlists.PLAYLIST,args:[e.id,P.m.slugify(e.name)]}},latestReleases:function(){return{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES}},allTopics:function(){return{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION_ALL}},classificationLatestReleases:function(e){return"classification-latest-releases"===e.id?{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES}:{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CLASSIFICATION_UPDATE,args:[e.id,P.m.slugify(e.name)]}}});return r().createElement("div",{className:"bg-white px-3"},b.isUpgrading&&(null===(a=l.data)||void 0===a?void 0:a.userType)===g.DashboardUserType.Staff&&r().createElement(W,null),r().createElement(le,{currentUser:i.data,dashboard:l.data,widgetAppLinks:Y,headerAppLinks:{forYou:{application:U.O.DASHBOARD,action:D.e.Dashboard.HOME},newReleases:{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES}},presentation:p,imageCdnUrl:n.data.imageCdnUrl,getWidgetContentRequest:de._.dashboardWidgetContent,setFavourite:I,audiences:f.data,canFavourite:O,updatePreferences:function(e,t){return h(de._.updateWidgetPreferences(e,t,i.data))},canManageDiscoverPreferences:j(A.E.ManageDiscoverPreferences),onSubmitFeedback:j(A.E.CanSubmitFeedback)&&function(e){var t=h(pe.n.sendDiscoverFooterFeedback(e,i.data,o.data,p,l.data,x(A.C.StudentExperience)));return ue.k.logUserAction({feedbackType:e.type,content:e.content,presentationId:p.id,dashboardId:l.data.id},{actionType:s.UserAction.Submit,location:s.LocationContext.DiscoverFooter,entity:s.EntityType.Feedback,workflowPhase:s.WorkflowPhase.Complete}),t}}))}function Te(e){var t=(0,o.r)(s.LocationContext.Classification),a=t.hasCuratedDiscoverDashboards;return t.isLoadingSettings?r().createElement(r().Fragment,null):a?r().createElement(Ee,Object.assign({},e)):r().createElement(ae,null)}},87432:(e,t,a)=>{a.d(t,{Z:()=>n});const n={pillTabSelector:"Hdi6o",pillItem:"hUJx1"}}}]);
|
|
1
|
+
"use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[2323],{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}}}},43482:(e,t,a)=>{a.d(t,{z:()=>m});var n=a(1024),i=a.n(n),r=a(81886),o=a(23481),s=a(83345),c=a(53957),l=a(38502),d=a(65858),u=a(55460),p="discover.header";function m(e){var t,a,n,m;if(!e.type)return i().createElement(i().Fragment,null);if(e.type===c.DashboardUserType.Learner)return i().createElement("div",{className:"py-3"},i().createElement("h1",{className:"h2 mb-0"},i().createElement(s.x,{namespace:p,phrase:"heading"})));function v(){var t,a=r.Q.AppLinkHelper.getCurrentAppLink();return(null===(t=e.appLinks)||void 0===t?void 0:t.newReleases.action)===a.action?"newReleases":"forYou"}return i().createElement("div",{className:"py-3 text-center"},i().createElement(l.r,{tabs:[{name:o.T.getPhrase(p,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===v(),analyticsData:{name:o.T.getPhrase(p,"forYou"),url:u.AppLinkHelper.getHref(null===(a=e.appLinks)||void 0===a?void 0:a.forYou)},analyticsOptions:{actionType:d.UserAction.Click,entity:d.EntityType.Url,location:d.LocationContext.MagicTabs}},{name:o.T.getPhrase(p,"newReleases"),appLink:null===(n=e.appLinks)||void 0===n?void 0:n.newReleases,active:"newReleases"===v(),analyticsData:{name:o.T.getPhrase(p,"newReleases"),url:u.AppLinkHelper.getHref(null===(m=e.appLinks)||void 0===m?void 0:m.newReleases)},analyticsOptions:{actionType:d.UserAction.Click,entity:d.EntityType.Url,location:d.LocationContext.MagicTabs}}]}))}},38502:(e,t,a)=>{a.d(t,{r:()=>l});var n=a(1024),i=a.n(n),r=a(11607),o=a(8493),s=a(87432),c=a(49985);function l(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(s.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-block text-decoration-none text-reset px-2 ".concat(s.Z.pillItem)},e.name):i().createElement(r.L,{className:"".concat(s.Z.pillItem," px-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&c.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name))}))))}},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:()=>Te});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),g=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),y=a(31949),h=a(5281),E=a(96519),T=a(21750),C=a(38143),S=a(69454),I=a(54644),L=a(22902),A=a(16714),O=a(45739),k=a(97037),D=a(14070),U=a(97291),F=a(25925),N=a(39151),P=a(28400),w=a(87348),j=a(64628),x=a(41523),B=a(65203),_=a(93475),R=a(3865),H=a(83345),Y=a(10874),q=a(58130),M=a(99742);var V="shared.upgradeVideoBanner";function W(){return i.createElement("div",{className:"py-4 px-3 rounded h4 ".concat("Vqx6B"," border"),style:{backgroundImage:'url("'.concat(M.W.Upgrade.VIDEO_BANNER,'")')}},i.createElement(H.x,{namespace:V,phrase:"message"}),i.createElement(Y.h,{svgName:q.vn.Play,appLink:{application:U.O.DEFAULT,action:D.e.Default.LITE_UPGRADE_VIDEO},className:"btn btn-outline-dark ml-3 align-middle"},i.createElement(H.x,{namespace:V,phrase:"button"})))}var z=a(490),J=a(9408),Z=a(43482);function G(e){return function(e){if(Array.isArray(e))return $(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Q(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 Q(e,t){if(e){if("string"==typeof e)return $(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)?$(e,t):void 0}}function $(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 K=p.T.encloseNamespace("dashboard.dashboard"),X="explore-all-topics",ee={video:{application:U.O.VIDEOS,action:D.e.Videos.PLAY_VIDEO},collection:{application:U.O.DASHBOARD,action:D.e.Dashboard.DASHBOARD},series:{application:U.O.SERIES,action:D.e.Series.SERIES},classification:{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION},contentUpdates:{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES},allClassifications:{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION_ALL},discover:{application:U.O.DASHBOARD,action:D.e.Dashboard.HOME}};function te(e,t,a){return d.a.useBasicFetch(a?R._.playlist(e,null==t?void 0:t.id):null)}function ae(){var e,t,a,r,o,p,D,U,H=(0,k.c)(s.LocationContext.ExpandableVideoThumbnail),Y=H.setFavourite,q=H.canFavourite,M=d.a.useBasicFetch(N.L.config()),V=d.a.useBasicFetch(T.x.presentation()),$=d.a.useBasicFetch(T.x.availablePresentations(F.R.Subject)),ae=d.a.useBasicFetch(y.N.currentUser()),ne=(p=(null==(o=ae.data)?void 0:o.countryCode)&&R._.widgets(n.HostedLibrary),d.a.useBasicFetch(p).data),ie=function(e,t){var a,n=d.a.useBasicFetch(N.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)&&T.x.classification(i.id,null==e?void 0:e.id))}(ae.data,V.data),re=function(e){var t,a,n=null,i=!e.isFetching,r=d.a.useBasicFetch(i&&T.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})}(ie),oe=(D=l().subtract(1,"year").endOf("day").format("YYYY-MM-DD"),U=l().endOf("day").format("YYYY-MM-DD"),d.a.useBasicFetch(I.v.getContentUpdateVideos(D,U))),se=O.i.getPresentationLevelImage(null===(e=V.data)||void 0===e?void 0:e.learningLevel,"new-release-banner"),ce=f.m.last(se.split("/")),le=(0,L.T)().hasPermissions,de=(0,w.Q)();(0,m.o)(K("pageTitle"));var ue,pe,me=(ue=(0,u.D)(C.g.AUDIENCE_FILTER,void 0,{storage:v.Z1.SessionStorage}),pe=1,function(e){if(Array.isArray(e))return e}(ue)||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}}(ue,pe)||Q(ue,pe)||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 i.createElement("div",{className:"bg-white px-3"},de.isUpgrading&&!le(A.C.StudentExperience)&&i.createElement(W,null),i.createElement(Z.z,{type:le(A.C.StudentExperience)?g.DashboardUserType.Learner:g.DashboardUserType.Staff,appLinks:{forYou:ee.discover,newReleases:ee.contentUpdates}}),re.hasCompleted?i.createElement(j.f,{appLinks:{allTopics:function(){return ee.allClassifications},classification:function(e){return Object.assign(Object.assign({},ee.classification),{args:[e.id,P.m.slugify(e.name)],params:S.T.getAudienceParams(me)})}},name:le(A.C.StudentExperience)?K("topicsHeadingLearner"):K("topicsHeadingStaff"),content:[{id:X,name:O.i.getExploreAllTopicsTitle(null===(t=V.data)||void 0===t?void 0:t.name,null===(a=$.data)||void 0===a?void 0:a.length),tallPoster:{url:O.i.getPresentationLevelImage(null===(r=V.data)||void 0===r?void 0:r.learningLevel,"tall-poster")}}].concat(G(re.data))}):i.createElement(x.J,null),!!ie.data&&i.createElement("div",{className:"px-1"},i.createElement(z.U,{appLinks:{classification:function(){return Object.assign(Object.assign({},ee.classification),{args:[ie.data.id,ie.data.slug]})}},content:[ie.data],name:ie.data.name})),ie.isFetching&&i.createElement("div",{className:"px-1"},i.createElement(J.D,null)),!le(A.C.StudentExperience)&&i.createElement(i.Fragment,null,oe.hasCompleted?i.createElement(B.o,{content:oe.data,appLinks:{latestReleases:function(){return ee.contentUpdates},videoType:function(e){return Object.assign(Object.assign({},ee.video),{args:[e.id,P.m.slugify(e.name)]})},series:function(){return ee.series}},name:K("latestReleases"),setFavourite:Y,canFavourite:q,metadata:{appLink:g.CuratedDashboardAppLink.LatestReleases,imageId:ce},imageCdnUrl:M.data.imageCdnUrl,limitTotalItems:!0}):i.createElement(_.B,null)),ne&&i.createElement(i.Fragment,null,ne.map((function(e,t){return i.createElement(h.k,{key:t,type:e.type,contents:b.z.Videos,fetch:c.partial(te,e.collectionId.toString(),ae.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:ee.series,setFavourite:Y},appLink:ee.collection,getChildAppLink:function(e){return Object.assign(Object.assign({},ee.video),{args:[e.id,P.m.slugify(e.name)]})},minimumItemCount:3,limitTotalItems:!0})}))))}var ne=a(50008),ie=a(21366),re=a(23232),oe=a(36532),se="subjects.discoverDashboardEmptyState";function ce(e){var t,a,n=(null===(t=e.dashboard)||void 0===t?void 0:t.status)===g.DashboardStatus.Archived;return r().createElement(re.u,null,r().createElement(re.u.Image,{src:e.imageUrl}),r().createElement(re.u.Heading,null,r().createElement(H.x,{namespace:se,phrase:"heading"})),r().createElement(re.u.Info,null,r().createElement(H.x,{namespace:se,phrase:"info"})),r().createElement(oe.u,{title:n?p.T.getPhrase(se,"archivedCtaTooltip"):"",spanHack:!0},r().createElement(re.u.Cta,{text:p.T.getPhrase(se,"add"),appLink:null===(a=e.addWidgetApplink)||void 0===a?void 0:a.call(e),className:"btn btn-dark",icon:q.vn.Plus,disabled:n})))}function le(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=ie.S.getWidgetParams(a,n,ie.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}),r().createElement("div",{className:"px-1"},n.map((function(t){return r().createElement(ne.L,{key:t.id,id:t.id,imageCdnUrl:e.imageCdnUrl,getContentRequest:i,name:t.name,description:t.description,templateId:t.templateId,metadata:t.metadata,presentation:e.presentation,audiences:e.audiences,setFavourite:e.setFavourite,canFavourite:e.canFavourite,appLinks:e.widgetAppLinks,isScrollToTargetWidget:(null==e?void 0:e.scrollToWidgetId)===t.id,widgetTypeId:t.widgetId,canManageDiscoverPreferences:e.canManageDiscoverPreferences,updatePreferences:e.updatePreferences,onSubmitFeedback:e.onSubmitFeedback})}))),o&&r().createElement(ce,{dashboard:e.dashboard,isReadonly:e.isReadonly,imageUrl:e.emptyImageUrl,addWidgetApplink:e.widgetAppLinks.widgetWizard}))}var de=a(80889),ue=a(49985),pe=a(52333),me=a(42617),ve=a(89454),fe=a(22490),ge=a(51200),be=a(1666);function ye(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 he=p.T.encloseNamespace("dashboard.dashboard");function Ee(e){var t,a,n=d.a.useBasicFetch(N.L.config()),i=d.a.useBasicFetch(y.N.currentUser()),o=(0,L.T)(),c=o.hasLocalPermissions,l=o.hasPermissions,p=d.a.useBasicFetch(c(A.E.ManageDiscoverPreferences)&&i.data&&be.h.customer(i.data.customerId)),f=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(A.C.StudentExperience),r=d.a.useBasicFetch(e&&n&&y.N.groups(e)),o=(0,ge.I)().presentation,s=d.a.useBasicFetch(t.presentationId&&T.x.presentationById(t.presentationId)),c=(!n||r.hasCompleted)&&!!o;function l(){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=[me.j.Curator,me.j.Content,me.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}}var u=l(),p=u.presentationId,m=u.dashboardId;function v(){if(!m)return i?g.DashboardUserType.Learner:g.DashboardUserType.Staff}function f(){return m?[g.DashboardStatus.Published,g.DashboardStatus.Draft,g.DashboardStatus.Archived]:[g.DashboardStatus.Published]}var b=d.a.useBasicFetch(c&&de._.discoverDashboard(p,v(),f(),m)),h=m?s.data:o,E=d.a.useBasicFetch(h&&ve.O.presentationAudiences(h.id));return{dashboard:b,presentation:h,audiences:E,isPreviewing:!!m}}(null===(t=i.data)||void 0===t?void 0:t.id,e.queryParams),b=f.dashboard,h=f.presentation,E=f.audiences,I=(0,w.Q)(),O=d.a.useGetFetchAsync(),F=(0,k.c)(s.LocationContext.Dashboard),j=F.setFavourite,x=F.canFavourite;(0,m.o)(he("pageTitle"));var B,_,R,H=(B=(0,u.D)(C.g.AUDIENCE_FILTER,void 0,{storage:v.Z1.SessionStorage}),_=1,function(e){if(Array.isArray(e))return e}(B)||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}}(B,_)||function(e,t){if(e){if("string"==typeof e)return ye(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)?ye(e,t):void 0}}(B,_)||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=(R=S.T.getAudienceParams(H),{classification:function(e){return{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION,args:[null==e?void 0:e.id,P.m.slugify(null==e?void 0:e.name)],params:R||{}}},classificationTopics:function(){return{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION_TOPICS,params:R||{}}},videoType:function(e){return fe.W.getAppLink(e)},series:function(e){return{application:U.O.SERIES,action:D.e.Series.SERIES,args:e?[e.id,P.m.slugify(e.name)]:[]}},playlist:function(e){return{application:U.O.PLAYLISTS,action:D.e.Playlists.PLAYLIST,args:[e.id,P.m.slugify(e.name)]}},latestReleases:function(){return{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES}},allTopics:function(){return{application:U.O.SUBJECT,action:D.e.Subjects.CLASSIFICATION_ALL}},classificationLatestReleases:function(e){return"classification-latest-releases"===e.id?{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES}:{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CLASSIFICATION_UPDATE,args:[e.id,P.m.slugify(e.name)]}}});return r().createElement("div",{className:"bg-white px-3"},I.isUpgrading&&(null===(a=b.data)||void 0===a?void 0:a.userType)===g.DashboardUserType.Staff&&r().createElement(W,null),r().createElement(le,{currentUser:i.data,dashboard:b.data,widgetAppLinks:Y,headerAppLinks:{forYou:{application:U.O.DASHBOARD,action:D.e.Dashboard.HOME},newReleases:{application:U.O.CONTENT_UPDATES,action:D.e.ContentUpdates.CONTENT_UPDATES}},presentation:h,imageCdnUrl:n.data.imageCdnUrl,getWidgetContentRequest:de._.dashboardWidgetContent,setFavourite:j,audiences:E.data,canFavourite:x,updatePreferences:function(e,t){return O(de._.updateWidgetPreferences(e,t,i.data))},canManageDiscoverPreferences:c(A.E.ManageDiscoverPreferences),onSubmitFeedback:c(A.E.CanSubmitFeedback)&&function(e){var t=O(pe.n.sendDiscoverFooterFeedback(e,i.data,p.data,h,b.data,l(A.C.StudentExperience)));return ue.k.logUserAction({feedbackType:e.type,content:e.content,presentationId:h.id,dashboardId:b.data.id},{actionType:s.UserAction.Submit,location:s.LocationContext.DiscoverFooter,entity:s.EntityType.Feedback,workflowPhase:s.WorkflowPhase.Complete}),t}}))}function Te(e){var t=(0,o.r)(s.LocationContext.Classification),a=t.hasCuratedDiscoverDashboards;return t.isLoadingSettings?r().createElement(r().Fragment,null):a?r().createElement(Ee,Object.assign({},e)):r().createElement(ae,null)}},87432:(e,t,a)=>{a.d(t,{Z:()=>n});const n={pillTabSelector:"Hdi6o",pillItem:"hUJx1"}}}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[3696],{40955:(e,t,n)=>{n.d(t,{P:()=>r});var a=n(1024);function r(e){return e.audience?a.createElement("div",{className:"audience-label border rounded-pill d-inline-block px-2 mt-1 text-nowrap \n ".concat("border-"+e.border," ").concat(e.className?e.className:"")},e.audience.name):a.createElement(a.Fragment,null)}},99551:(e,t,n)=>{n.d(t,{c:()=>r});var a=n(1024);function r(e){var t="d-flex align-items-center badge-list ".concat("jEh7m");return e.className&&(t+=" ".concat(e.className)),a.createElement("div",{className:t},e.children)}},24900:(e,t,n)=>{n.d(t,{z:()=>o,O:()=>c});var a=n(1024),r=n(58130),i=n(83914);var c;function o(e){var t=e.type,n=function(e){return e===c.Video?"b8kJW":e===c.Playlist?"eo2p2":""}(t),o=function(e){return e===c.Video?r.vn.PlayCircle:e===c.Playlist?r.vn.AddToPlaylists:""}(t);return a.createElement("div",{className:"lpwag"},a.createElement("div",{className:"qpc7L"}),a.createElement(i.x,{svgName:o,className:n}))}!function(e){e[e.Video=0]="Video",e[e.Playlist=1]="Playlist",e[e.Series=2]="Series"}(c||(c={}))},16035:(e,t,n)=>{n.d(t,{z:()=>u});var a=n(1024),r=n.n(a),i=n(8493),c=n(44829),o=n(58130),l=n(83914),s=n(91807);function u(e){var t,n,a=e.tag,u=e.appLink,d=e.onClick,m=e.disabled,v=e.tagClass,g=void 0===v?"tag":v,f=a.name.toLowerCase(),p=null===(t=a.tagType)||void 0===t?void 0:t.toLowerCase(),y="badge-pill py-1 px-2 my-1 mr-1 ".concat(g," ").concat(function(e){switch(e){case c.Q.Pedagogy:case c.Q.Skill:return"pedagogy-tag text-white";case c.Q.Hidden:return"hidden-tag";case c.Q.Normal:default:return""}}(p)),h=p===c.Q.Normal&&!!(null===(n=e.themeColours)||void 0===n?void 0:n.secondary);h&&(y+=" text-white"),!u&&!d||m||(y+=" cursor-pointer"),m&&(y+=" "+s.Z.disabled),e.onRemove&&(y+=" "+s.Z.badge);var E=h?{backgroundColor:e.themeColours.secondary}:{};return u?r().createElement(i.F,{onClick:d,appLink:u,className:y,title:f,style:E},r().createElement("span",{className:"text-truncate text-nowrap"},f)):r().createElement("span",{onClick:d,className:y,title:f,style:E},r().createElement("span",{className:"text-truncate text-nowrap"},f,e.onRemove&&r().createElement("button",{onClick:e.onRemove,className:"".concat(s.Z.close," close font-size-normal")},r().createElement(l.x,{size:l.S.Small,svgName:o.vn.Close,className:"d-inline-block svg-container"}))))}},91743:(e,t,n)=>{n.d(t,{P:()=>u});var a=n(1024),r=n.n(a),i=n(16035),c=n(44829),o=n(91807);function l(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){var t;switch(null===(t=e.tagType)||void 0===t?void 0:t.toLowerCase()){case c.Q.Pedagogy:return 0;case c.Q.Skill:return 1;default:return 2}}function u(e){if(!e.tags)return r().createElement(r().Fragment,null);var t,n=(t=e.tags,function(e){if(Array.isArray(e))return l(e)}(t)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e,t){if(e){if("string"==typeof e)return l(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)?l(e,t):void 0}}(t)||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.")}()).sort((function(e,t){return s(e)-s(t)}));return r().createElement("div",{className:o.Z.tagList},n.map((function(t){var n="function"==typeof e.getAppLink?e.getAppLink(t):null,a="function"==typeof e.onRemove?function(){return e.onRemove(t)}:null;return r().createElement(i.z,{key:t.id,tag:t,appLink:n,themeColours:e.themeColours,onRemove:a})})))}},22843:(e,t,n)=>{n.d(t,{h:()=>v});var a=n(1024),r=n.n(a),i=n(40955),c=n(96022),o=n(65858),l=n(8493),s=n(80143),u=n(11025),d=n(76246);var m=function(e){var t=e.mergedAudience,n=e.video;return t?r().createElement("div",{className:"mt-n1 ".concat("hvsne")},r().createElement(i.P,{audience:t,border:"dark"})):u.M.isVideo(n)&&(null==n?void 0:n.rating)?r().createElement(d.C,{type:d.g.Rating,data:n.rating}):null};function v(e){var t,n=e.video,a=e.appLink,i=e.seriesAppLink,d=u.M.getCanBeConsumed(n),v=null===(t=null==n?void 0:n.subjectPresentationAudiences)||void 0===t?void 0:t.data,g=(0,s.n)(v,e.presentationAudiences);return r().createElement("div",{className:"mt-2 d-flex justify-content-between"},r().createElement("div",{className:"d-flex flex-column ".concat("rULXI")},u.M.isVideo(n)&&u.M.hasSeries(n)&&r().createElement(c.M,{className:"text-truncate ".concat("h9k1p"),video:n,appLink:i,analyticsOptions:{location:o.LocationContext.VideoThumbnail}}),r().createElement(l.F,{className:"h6 text-reset clamp-2",appLink:(null==d?void 0:d.value)?a:null},n.name)),r().createElement("div",{className:"".concat("QaDDX"," ml-2")},r().createElement(m,{video:n,mergedAudience:g})))}},93696:(e,t,n)=>{n.d(t,{u:()=>ge});var a=n(1024),r=n.n(a),i=n(65858),c=n(23481),o=n(79014),l=n(58130),s=n(83914),u=n(69883),d=n(1643),m=n(11025),v=n(11607);function g(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=c.T.encloseNamespace("shared.favouriteButton");function p(e){var t,n,r=(0,u.Z)(),i=d.h.isFavouritedByCurrentUser(e.video),c=(t=a.useState(i),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,i,c,o=[],l=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=i.call(n)).done)&&(o.push(a.value),o.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 o}}(t,n)||function(e,t){if(e){if("string"==typeof e)return g(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)?g(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.")}()),p=c[0],y=c[1];a.useEffect((function(){y(i)}),[i]);var h="cursor-pointer ".concat("CFRo3"," ").concat(p?"t0svX":"");return e.className&&(h+=" ".concat(e.className)),o.q.isFunction(e.setFavourite)&&o.q.isFunction(e.canFavourite)&&e.canFavourite(e.video)?a.createElement(v.L,{className:h,onClick:function(){var t=!p;y(t),e.setFavourite(e.video,t,null,(function(){r.error(f(m.M.isClip(e.video)?t?"favouriteClipError":"unfavouriteClipError":m.M.isInteractive(e.video)?t?"favouriteInteractiveError":"unfavouriteInteractiveError":t?"favouriteVideoError":"unfavouriteVideoError")),y(!t)}),e.analyticsData,e.analyticsOptions)}},a.createElement(s.x,{svgName:l.vn.Heart,size:s.S.Large,className:"svg-container ".concat("ZMMQu")}),a.createElement(s.x,{svgName:l.vn.HeartOutline,size:s.S.Large,className:"svg-container ".concat("truFo")})):a.createElement(a.Fragment,null)}var y=n(78276),h=n(54610),E=n(96022),b=n(99551),N=n(76246);function C(e){var t=m.M.getVideoProgress(e.video),n=t&&e.video.duration&&t/e.video.duration*1e5;return n?a.createElement("div",{className:"bg-primary h-100",style:{width:"".concat(n,"%")}}):a.createElement(a.Fragment,null)}function w(e){var t=e.clip,n=e.size;if(!t.video)return a.createElement(a.Fragment,null);var r=t.endTime-t.startTime,i=Math.floor(t.video.duration/1e3),c=t.startTime/i*100,o=r/i*100,l="".concat("ifCKp"," ").concat("lg"===n?"nHNts":"");return a.createElement("div",{className:"position-relative h-100"},a.createElement("div",{className:l},a.createElement("div",{className:"".concat("TAxd_"),style:{width:"".concat(o,"%"),left:"".concat(c,"%")}},a.createElement("div",{className:"position-relative h-100"},a.createElement("div",{className:"bg-info ".concat("ZFHSL")}),a.createElement("div",{className:"bg-info ".concat("iuR4H")})))))}const S="trhW1";function A(e){var t="L7yKq ";return t+="white"===e.color?"tNJTB":"ltvcb","lg"===e.size&&(t+=" Iyvjg"),a.createElement("div",{className:"position-relative h-100"},a.createElement("div",{className:t},a.createElement("div",{className:"bg-blue ".concat(S),style:{left:"10%"}}),a.createElement("div",{className:"bg-purple ".concat(S),style:{left:"20%"}}),a.createElement("div",{className:"bg-orange ".concat(S),style:{left:"25%"}}),a.createElement("div",{className:"bg-indigo ".concat(S),style:{left:"55%"}}),a.createElement("div",{className:"bg-green ".concat(S),style:{left:"70%"}})))}A.defaultProps={color:"white"};const O="YnXtZ",k="S9lm2";function x(e){return"none"===e.style?r().createElement(r().Fragment,null):m.M.isVideo(e.video)?r().createElement("div",{className:"".concat(O," ").concat("BdUh9")},r().createElement(C,{video:e.video})):m.M.isClip(e.video)?r().createElement("div",{className:"".concat(O," ").concat("KrLcn"," ").concat("lg"===e.style?k:"")},r().createElement(w,{clip:e.video,size:e.style})):m.M.isInteractive(e.video)?r().createElement("div",{className:"".concat(O," ").concat("zEClK"," ").concat("lg"===e.style?k:"")},r().createElement(A,{size:e.style})):r().createElement(r().Fragment,null)}function M(){return r().createElement("div",{className:"".concat("w4cg8"," bg-white cursor-default d-flex align-items-center justify-content-center")},r().createElement(s.x,{svgName:l.vn.Lock}))}var j=n(36532),I=n(5465);const T="XAfZW";function P(e){return"".concat("align-items-center",e?" mb-n1 mt-1":" mb-2")}function F(e,t){var n="";return t&&(n+="puKcM"),e||(n+=t?" mb-1":" mb-3"),n}function L(e){var t=e.video,n=e.appLink,a=e.imageOptions,c=e.setFavourite,o=e.canFavourite,u=e.preload,v=e.hovering,g=m.M.getCanBeConsumed(e.video).canNavigate,f=Object.assign(Object.assign({},e.analyticsOptions),{entity:m.M.getAnalyticsEntity(t)}),C=d.h.showFavouriteButton(e.video,v),w=m.M.isVideo(t);return r().createElement(j.u,{title:m.M.getPrivacyReasoning(e.video),spanHack:!0,spanHackClassName:""},r().createElement("div",{className:"position-relative rounded overflow-hidden"},C&&r().createElement("div",{className:T},r().createElement(p,{setFavourite:c,canFavourite:o,video:t,className:"rounded-circle ".concat("t6k1e"),analyticsData:e.analyticsData,analyticsOptions:f})),!g&&r().createElement("div",{className:T},r().createElement(M,null)),r().createElement(y.Z,{data:m.M.getThumbnail(t),appLink:g?n:null,imageType:h.__.Thumbnails,imageOptions:a,preload:u,className:"rXzR8",analyticsData:Object.assign(Object.assign({},e.analyticsData),{id:t.id,name:t.name}),analyticsOptions:Object.assign(Object.assign({},f),{actionType:i.UserAction.Click,descriptor:i.ClickDescriptor.Thumbnail})},!(!v||!g)&&r().createElement(s.x,{className:"dndOA",svgName:l.vn.PlayCircle}),r().createElement(I.oy,{type:I.mS.Video}),r().createElement("div",{className:"qu3A3"},r().createElement("div",{className:"NTrtm"},r().createElement("div",{className:"".concat(F(w,v))},w&&m.M.hasSeries(t)&&r().createElement(E.M,{className:"text-shadow clamp-1",video:t,appLink:null,analyticsOptions:null}),r().createElement("span",{className:"h6 text-reset text-shadow clamp-1"},m.M.getTitle(t))),r().createElement(x,{video:t,style:e.bottomBarStyle}),v&&r().createElement(b.c,{className:P(w)},m.M.isVideo(t)&&r().createElement(r().Fragment,null,r().createElement(N.C,{type:N.g.Rating,data:t.rating}),t.hasSubtitle&&r().createElement("span",{className:"badge p-0"},r().createElement(s.x,{svgName:l.vn.CloseCaptionBadge})),r().createElement(N.C,{type:N.g.Interactive,data:t.hasInteractives})),r().createElement(N.C,{type:N.g.Duration,data:m.M.getDuration(e.video)})))))))}var V=n(68626),R=n(24900),B=n(8493),D=n(11576),z=n(4594);const U={unchecked:"maxOx",checked:"k3CBB"};function _(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 H=c.T.encloseNamespace("shared.toggleActivityStatusButton");function Z(e){var t,n,r=(0,u.Z)(),i=(t=a.useState(e.activityStatus===D.T.Complete),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,i,c,o=[],l=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=i.call(n)).done)&&(o.push(a.value),o.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 o}}(t,n)||function(e,t){if(e){if("string"==typeof e)return _(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)?_(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.")}()),c=i[0],d=i[1];a.useEffect((function(){d(e.activityStatus===D.T.Complete)}),[e.activityStatus]);var m="cursor-pointer rounded-circle ".concat(c?U.checked:U.unchecked);return e.className&&(m+=" ".concat(e.className)),e.shareId&&e.activityStatus&&e.activityStatus!==D.T.None&&o.q.isFunction(e.setActivityStatus)?a.createElement("div",{className:m,onClick:function(){var t=!c;d(t);var n=t?D.T.Complete:D.T.Incomplete;e.setActivityStatus(e.shareId,e.sharedEntity,n,null,(function(){r.error(H(function(){switch(e.sharedEntity.typeId){case z.E.Video:return t?"completeVideoActivityError":"uncompleteVideoActivityError";case z.E.Clip:return t?"completeClipActivityError":"uncompleteClipActivityError";case z.E.Interactive:return t?"completeInteractiveActivityError":"uncompleteInteractiveActivityError";case z.E.Playlist:return t?"completePlaylistActivityError":"uncompletePlaylistActivityError";case z.E.Series:return t?"completeSeriesActivityError":"uncompleteSeriesActivityError"}}())),d(!t)}))}},a.createElement(s.x,{svgName:l.vn.Check,size:s.S.Large,className:"svg-container ".concat(U.checkMark)})):a.createElement(a.Fragment,null)}const Q="efxnE",X="vWvGn";function W(e){return m.M.getCanBeConsumed(e.video).canNavigate?function(e){var t;return!(null===(t=m.M.getCanBeConsumed(e.video))||void 0===t?void 0:t.canConsume)||!(!o.q.isFunction(e.setFavourite)||!o.q.isFunction(e.canFavourite))||!!o.q.isFunction(e.setActivityStatus)}(e)?r().createElement("div",{className:"".concat(Q," d-flex align-items-center")},r().createElement(p,{setFavourite:e.setFavourite,canFavourite:e.canFavourite,video:e.video,className:X,analyticsData:e.analyticsData,analyticsOptions:e.analyticsOptions}),r().createElement(Z,{activityStatus:e.activityStatus,setActivityStatus:e.setActivityStatus,sharedEntity:e.sharedEntity,shareId:e.shareId,className:X})):r().createElement(r().Fragment,null):r().createElement("div",{className:Q},r().createElement(M,null))}var K=n(49439),q=n(40955);function Y(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 G(e,t){var n="VAx36";return"none"===t||("lg"===t&&(n+=" g5_ww"),m.M.isVideo(e)?n+=" rwEAC":m.M.isClip(e)?n+=" MPRU6":m.M.isInteractive(e)&&(n+=" Zzo3e")),n}function $(e){var t,n=e.video,a=e.seriesAppLink,o=e.textPosition,l=e.appLink,s=e.bottomBarStyle,u=o===V.z.Overlay,d=m.M.getCanBeConsumed(e.video).canNavigate,v="";return u?(v="krg9f",d&&(m.M.isClip(n)&&(v+=" MPRU6"),m.M.isInteractive(n)&&(v+=" Zzo3e"),"lg"===s&&(v+=" g5_ww"))):v="tZjPt",r().createElement("div",{className:v},m.M.isVideo(n)&&m.M.hasSeries(n)&&r().createElement(E.M,{className:u?"text-shadow clamp-1":"clamp-2",video:n,appLink:u?null:a,analyticsOptions:{location:i.LocationContext.VideoThumbnail}}),u||!d?r().createElement("span",{className:"h6 text-reset text-shadow clamp-1"},null!==(t=n.name)&&void 0!==t?t:c.T.getPhrase("shared.staticVideoThumbnail","videoUnavailable")):r().createElement(B.F,{className:"h6 text-reset clamp-2",appLink:l},n.name))}function J(e){var t,n,a=e.video,c=e.appLink,o=e.textPosition,l=e.imageOptions,s=e.setFavourite,u=e.preload,v=(t=(0,K.X)(),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,i,c,o=[],l=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=i.call(n)).done)&&(o.push(a.value),o.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 o}}(t,n)||function(e,t){if(e){if("string"==typeof e)return Y(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)?Y(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.")}()),g=v[0],f=v[1],p=m.M.getCanBeConsumed(a).canNavigate,E="position-relative";E+=c&&p?" cursor-pointer":" cursor-default",e.extraClasses&&(E+=" ".concat(e.extraClasses)),o===V.z.Overlay&&(E+=" rounded overflow-hidden");var C=Object.assign(Object.assign({},e.analyticsOptions),{entity:m.M.getAnalyticsEntity(a)}),w="rounded overflow-hidden";o===V.z.Overlay&&(w+=" LS_EH");var S=!!c&&!e.hideMask&&p,A=m.M.getPrivacyReasoning(e.video),O=function(){if(!e.hideRating&&m.M.isVideo(e.video))return e.video.rating}();return r().createElement(j.u,{title:A,spanHack:!0,spanHackClassName:""},r().createElement("div",{className:E,ref:g},r().createElement(W,{video:a,shareId:e.shareId,sharedEntity:e.sharedEntity,activityStatus:e.activityStatus,setActivityStatus:e.setActivityStatus,setFavourite:s,canFavourite:function(){var t;return(null===(t=e.canFavourite)||void 0===t?void 0:t.call(e,e.video))&&d.h.showFavouriteButton(a,f)},analyticsData:e.analyticsData,analyticsOptions:C}),r().createElement(y.Z,{data:m.M.getThumbnail(a),appLink:p?c:null,imageType:h.__.Thumbnails,imageOptions:l,preload:u,className:w,analyticsData:Object.assign(Object.assign({},e.analyticsData),{id:a.id,name:a.name}),analyticsOptions:Object.assign(Object.assign({},C),{actionType:i.UserAction.Click,descriptor:i.ClickDescriptor.Thumbnail})},S&&r().createElement(R.z,{type:R.O.Video}),r().createElement(I.oy,{type:I.mS.Video}),r().createElement("div",{className:"EElm1"},o===V.z.Overlay&&r().createElement($,Object.assign({},e)),"none"!==e.bottomBarStyle&&r().createElement(x,{video:a,style:e.bottomBarStyle}),(!e.hideDuration||e.audience||!e.hideRating&&O)&&r().createElement(b.c,{className:"".concat(e.audienceSizeBadges?"OayBh":""," ").concat(G(e.video,e.bottomBarStyle))},r().createElement(q.P,{audience:e.audience,className:"bg-white text-dark mr-1",border:"dark"}),!e.hideRating&&O&&r().createElement(N.C,{type:N.g.Rating,data:O}),!e.hideDuration&&r().createElement(N.C,{type:N.g.Duration,data:m.M.getDuration(e.video)})))),o===V.z.Below&&r().createElement($,Object.assign({},e))))}var ee=n(54976),te=n.n(ee),ne=n(22843),ae=n(27867),re=n(6296),ie=n(16226),ce=n(38803),oe=n(75931);const le={badgeContainer:"Qx6jT",video:"ccWap",preview:"whbhf",details:"vMaXP",videoGuidanceTags:"KJrT1",dropdown:"oZXV7",show:"EiQ04",topRightContainer:"FAuzc",favouriteButton:"ESW9f"};function se(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,c,o=[],l=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(a=i.call(n)).done)&&(o.push(a.value),o.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 o}}(e,t)||function(e,t){if(e){if("string"==typeof e)return ue(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)?ue(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 ue(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 de(e,t){var n=le.badgeContainer;return"none"===t||("lg"===t&&(n+=" "+le.large),m.M.isVideo(e)&&(n+=" "+le.video)),n}var me=function(e){var t=e.video,n=e.appLink,a=e.imageOptions,c=e.preload,o=e.setFavourite,l=e.canFavourite,s=e.isHovering,u=e.hoverPositionConfig,v=m.M.getCanBeConsumed(t).canNavigate,g=se(r().useState("none"),2),f=g[0],E=g[1],C=se(r().useState(!1),2),w=C[0],S=C[1],A=se((0,K.X)(),2),O=A[0],k=A[1],T=se((0,K.X)(),2),P=T[0],F=T[1],L=r().useMemo((function(){return m.M.showWhyThisVideo(t)}),[t]),V=r().useMemo((function(){return m.M.showWhatsIncluded(t)}),[t]);r().useEffect((function(){k&&"why-this-video"!==f?E("why-this-video"):F&&"whats-included"!==f&&E("whats-included")}),[k,F,f]);var R="position-relative bg-white";e.extraClasses&&(R+=" ".concat(e.extraClasses)),s&&(R+=" rounded-lg shadow-lg");var B=Object.assign(Object.assign({},e.analyticsOptions),{entity:m.M.getAnalyticsEntity(t)}),D=d.h.showFavouriteButton(e.video,s),z=V||L,U="none"!==f;return r().createElement("div",{className:R},D&&r().createElement("div",{className:le.topRightContainer},r().createElement(p,{setFavourite:o,canFavourite:l,video:t,className:"rounded-circle ".concat(le.favouriteButton),analyticsData:e.analyticsData,analyticsOptions:B})),v&&r().createElement("div",{className:le.topRightContainer},r().createElement(j.u,{title:m.M.getPrivacyReasoning(e.video),spanHack:!0,spanHackClassName:""},r().createElement(M,null))),r().createElement("div",{style:{width:null==u?void 0:u.width,height:null==u?void 0:u.height,transform:"all 1s cubic-bezier(.86,0,.07,1)"}},r().createElement(y.Z,{data:m.M.getThumbnail(t),appLink:v?n:null,imageType:h.__.Thumbnails,imageOptions:a,preload:c,className:"overflow-hidden ".concat(s?le.preview:"rounded-lg ".concat(le.original)),analyticsData:Object.assign(Object.assign({},e.analyticsData),{id:t.id,name:t.name}),analyticsOptions:Object.assign(Object.assign({},B),{actionType:i.UserAction.Click,descriptor:i.ClickDescriptor.Thumbnail})},r().createElement(I.oy,{type:I.mS.Video}),r().createElement("div",{className:"p-absolute w-100 h-100 p-1 text-white"},"none"!==e.bottomBarStyle&&m.M.isVideo(t)&&r().createElement(x,{video:t,style:e.bottomBarStyle}),!e.hideDuration&&r().createElement(b.c,{className:de(e.video,e.bottomBarStyle)},r().createElement(N.C,{type:N.g.Duration,data:m.M.getDuration(e.video)}))))),s&&r().createElement("div",{className:"".concat(s?le.details:"")},r().createElement("div",{className:"".concat(w?"box-shadow":""," ").concat(s?le.videoGuidanceTags:"")},r().createElement(ne.h,Object.assign({},e)),z&&s&&r().createElement("div",{className:"d-flex justify-content-start align-items-center pt-2"},L&&r().createElement(ie.A,{ref:O,active:"why-this-video"===f}),V&&r().createElement(re.V,{ref:P,active:"whats-included"===f}))),z&&s&&r().createElement(te(),{autoHeight:!0,autoHeightMax:192,onUpdate:function(e){var t=e.top;w&&0===t?S(!1):!w&&t>0&&S(!0)}},r().createElement("div",{className:"".concat(le.dropdown," ").concat(U?le.show:"")},"why-this-video"===f&&r().createElement(ce.p,{video:e.video}),"whats-included"===f&&r().createElement(oe.V,{video:e.video,imageCdnUrl:e.imageCdnUrl})))))};function ve(e){return r().createElement(r().Fragment,null,r().createElement(ae.K,{hoverableComponent:me,componentProps:e,minHoverWidth:340}),r().createElement(ne.h,Object.assign({},e)))}function ge(e){var t,n=e.bottomBarStyle;(null===(t=m.M.getCanBeConsumed(e.video))||void 0===t?void 0:t.canNavigate)||(n="none");var r=Object.assign(Object.assign({},e),{bottomBarStyle:n});switch(e.type){case"static":return a.createElement(J,Object.assign({},r));case"expandable":return a.createElement(L,Object.assign({},r));case"popout":return a.createElement(ve,Object.assign({},r));default:return}}ge.defaultProps={bottomBarStyle:"sm",hideRating:!0}},65720:(e,t,n)=>{n.d(t,{m:()=>c});var a=n(1024),r=n.n(a),i=n(83914);function c(e){return r().createElement("div",{className:"p-1 pr-2 badge-pill d-inline-flex align-items-center mr-1 cursor-pointer ".concat("OjHQZ"," ").concat(e.active?"kD1xM":"")},r().createElement(i.x,{className:"".concat("SS2zL"," rounded-circle bg-").concat(e.iconVariant," text-white"),svgName:e.svgName}),r().createElement("span",{className:"pl-1 text-nowrap"},e.text))}},75931:(e,t,n)=>{n.d(t,{V:()=>m});var a=n(1024),r=n.n(a),i=n(23481),c=n(58130),o=n(73749),l=n(93566),s=n(83914);function u(e){return r().createElement("div",{className:"".concat("c4Hun"," p-2 rounded-lg")},r().createElement("div",{className:"d-flex align-items-center"},r().createElement("div",{className:"".concat("telfV"," bg-").concat(e.iconVariant," text-white rounded-circle")},r().createElement(s.x,{svgName:e.svgName})),r().createElement("div",{className:"pl-2 font-weight-500"},e.text)),e.children)}var d=i.T.encloseNamespace("shared.whatsIncluded");function m(e){var t,n,a,i,m,v,g,f=null===(n=null===(t=e.video.interactives)||void 0===t?void 0:t.data)||void 0===n?void 0:n.length,p=null===(i=null===(a=e.video.resources)||void 0===a?void 0:a.data)||void 0===i?void 0:i.length,y=null!==(g=null===(v=null===(m=e.video.subtitles)||void 0===m?void 0:m.data)||void 0===v?void 0:v.map((function(t){var n,a;return l.y.getEnglishName(t,null!==(a=null===(n=e.video.subtitles)||void 0===n?void 0:n.data)&&void 0!==a?a:[])})))&&void 0!==g?g:[];return r().createElement(r().Fragment,null,f>0&&r().createElement(u,{text:d("totalInteractives",{smartCount:f}),svgName:c.vn.Interactive,iconVariant:"green"}),p>0&&r().createElement(u,{text:d("totalResources",{smartCount:p}),svgName:c.vn.Resources,iconVariant:"indigo"},r().createElement("div",{className:"row no-gutters mx-n1 pt-2"},e.video.resources.data.slice(0,3).map((function(t){return r().createElement("div",{key:t.id,className:"col-4 px-1"},r().createElement(o.s,{data:t,imageCdnUrl:e.imageCdnUrl,theme:{containerClass:"bdBNU",thumbnailContainerClass:"QN5kl"},hideHeading:!0}))})))),!!(null==y?void 0:y.length)&&r().createElement(u,{text:d("videoSettings"),svgName:c.vn.Cog,iconVariant:"dark"},r().createElement("div",{className:"d-flex align-items-center pt-1"},r().createElement(s.x,{svgName:c.vn.CloseCaptionBadge}),r().createElement("div",{className:"pl-1"},y.join(", ")))))}},6296:(e,t,n)=>{n.d(t,{V:()=>l});var a=n(1024),r=n.n(a),i=n(23481),c=n(58130),o=n(65720),l=r().forwardRef((function(e,t){return r().createElement("div",{ref:t},r().createElement(o.m,{svgName:c.vn.Video,iconVariant:"blue",text:i.T.getPhrase("shared.whatsIncluded","whatsIncluded"),active:e.active}))}))},38803:(e,t,n)=>{n.d(t,{p:()=>d});var a=n(1024),r=n.n(a),i=n(44829),c=n(83345),o=n(91743),l=n(16035);const s="KQ5Wt";var u="shared.whyThisVideo";function d(e){var t,n,a,d,m,v,g=null!==(a=null===(n=null===(t=e.video.tags)||void 0===t?void 0:t.data)||void 0===n?void 0:n.filter((function(e){return e.tagType===i.Q.Pedagogy})))&&void 0!==a?a:[],f=null!==(v=null===(m=null===(d=e.video.tags)||void 0===d?void 0:d.data)||void 0===m?void 0:m.filter((function(e){return e.tagType===i.Q.Skill})))&&void 0!==v?v:[];return r().createElement(r().Fragment,null,!!g.length&&r().createElement("h3",{className:"font-size-normal font-weight-500"},r().createElement(c.x,{namespace:u,phrase:"pedagogy"})),g.map((function(e){return r().createElement("div",{key:e.name,className:"px-2 py-3 rounded-lg ".concat(s)},r().createElement(l.z,{tag:e}),e.description&&r().createElement("p",{className:"mb-n2 pt-2"},e.description))})),!!f.length&&r().createElement(r().Fragment,null,r().createElement("h3",{className:"font-size-normal font-weight-500"},r().createElement(c.x,{namespace:u,phrase:"skills"})),r().createElement("div",{className:"p-2 rounded-lg ".concat(s)},r().createElement(o.P,{tags:f}))))}},16226:(e,t,n)=>{n.d(t,{A:()=>l});var a=n(1024),r=n.n(a),i=n(23481),c=n(58130),o=n(65720),l=r().forwardRef((function(e,t){return r().createElement("div",{ref:t},r().createElement(o.m,{svgName:c.vn.StarOutline,iconVariant:"navy",text:i.T.getPhrase("shared.whyThisVideo","whyThisVideo"),active:e.active}))}))},68626:(e,t,n)=>{var a;n.d(t,{z:()=>a}),function(e){e[e.Below=1]="Below",e[e.Overlay=2]="Overlay",e[e.Independent=3]="Independent"}(a||(a={}))},80143:(e,t,n)=>{n.d(t,{n:()=>c});var a=n(1024),r=n.n(a),i=n(69454);function c(e,t){var n=r().useMemo((function(){return(null==e?void 0:e.length)&&t&&i.T.shouldShowAudiences(t)?i.T.getSortedPresentationAudiences(e,t):null}),[e]);return r().useMemo((function(){return(null==n?void 0:n.length)?i.T.getMergedPresentationAudienceString(n):null}),[n])}},93566:(e,t,n)=>{n.d(t,{y:()=>r});var a=n(23481),r={getEnglishName:function(e,t){var n,r,i=e.language;return r=(null==t?void 0:t.filter((function(e){return e.language!==i}))).length>0?CVLanguages.getFullEnglishName(i):CVLanguages.getEnglishName(i),(null===(n=e.metadata)||void 0===n?void 0:n.autoGenerated)?a.T.getPhrase("shared.shared-utils","autoGeneratedSubtitle",{name:r}):r}}},69454:(e,t,n)=>{n.d(t,{T:()=>s});var a=n(75896),r=n(1048),i=/\d/,c=n(55171),o=/([0-9]+)/gi,l=/\s|\+/gi,s={getSortedPresentationAudiences:function(e,t){var n=e.filter((function(e){return!!e})).map((function(e){return e.id.toString()}));return t.filter((function(e){return n.includes(e.masterId.toString())}))},getMergedPresentationAudienceString:function(e){if(1===e.length)return e[0];var t,n,r,o,l,s,u,d,m,v="";switch(+a.m.first(e).presentationId){case c.e.PresentationIds.DEFAULT:case c.e.PresentationIds.AU_SECONDARY:case c.e.PresentationIds.US_ELEMENTARY:case c.e.PresentationIds.AU_PRIMARY:v=function(e){var t=e.map((function(e){return e.name})).join(" "),n=t.split(" ").filter((function(e){return!isNaN(+e)})).map((function(e){return+e}))||[],a=t.split(" ").filter((function(e){return isNaN(+e)}))||[],r=e.find((function(e){return!i.test(e.name)})),c=a.find((function(e){return e!==(null==r?void 0:r.name)}));if(e.length>1&&(c+="s"),r&&n.length)return"".concat(c," ").concat(r.name.charAt(0)," - ").concat(n.pop());var o=function(e){var t,n,a,r,i=!1,c=[];for(e=e.sort((function(e,t){return e-t})),a=0;a<e.length;a++)r=a+1,i||(t=e[a]),n=e[r],e[a]+1===n?i=!0:i?(c.push("".concat(t," - ").concat(e[a])),i=!1):(c.push("".concat(e[a])),i=!1);return c}(n);return"".concat(c," ").concat(o.join(", "))}(e);break;case c.e.PresentationIds.SCOTLAND_PRIMARY:case c.e.PresentationIds.SCOTLAND_SECONDARY:case c.e.PresentationIds.INTERNATIONAL_PRIMARY:case c.e.PresentationIds.INTERNATIONAL_SECONDARY:v=function(e){var t=e.map((function(e){return e.name})),n={};t.forEach((function(e,t){if(0!==t){var a=e.split(" ");Object.keys(n).forEach((function(e){a.includes(e)||delete n[e]}))}else e.split(" ").forEach((function(e,t){n[e]=0===t?"start":"end"}))}));var a=Object.keys(n)[0],r=n[a];if(!a)return e[0].name;var i=e[0].name,c=e[e.length-1].name,o=function(e){return e.split(a)[0]},l="".concat(o(i)," - ").concat(o(c));return"start"===r?"".concat(a," ").concat(l):"".concat(l," ").concat(a)}(e);break;case c.e.PresentationIds.ENGLAND_PRIMARY:t=e,n=a.m.first(t),r=a.m.last(t),o=n.name.split(" ").find((function(e){return!isNaN(+e)})),l=r.name.split(" ").find((function(e){return!isNaN(+e)})),s="KS".concat(o),u="KS".concat(l),d=a.m.first(n.name.split(" ")),m=a.m.first(r.name.split(" ")),"key"!==d.toLowerCase()&&(s=o?"".concat(d," ").concat(s):n.name),"key"!==m.toLowerCase()&&(u="".concat(m," ").concat(u)),v="".concat(s," - ").concat(u);case c.e.PresentationIds.US_MIDDLE:case c.e.PresentationIds.US_HIGH:}return v?{name:v}:null},sortMembersWithDuplicateNamesByAudience:function(e){var t=function(e){return e.length?(e.forEach((function(e){var r=+a.m.first(e.name.match(o));if(!t)return t=e,void(n=r);r<n&&(t=e)})),t):null;var t,n},n={},r=[];return e.forEach((function(e){if(!n[e.name])return n[e.name]=1,void r.push(e);r.push(e),n[e.name]++;var a=r.splice(r.length-n[e.name]).sort((function(e,n){var a=t(e.subjectPresentationAudiences.data),r=t(n.subjectPresentationAudiences.data);if(!a&&r)return 1;if(!r)return-1;var i=a.name.localeCompare(r.name);return 0===i?i:i>0?-1:1}));r=r.concat(a)})),r},getActiveAudiencesFromParams:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(r.t.isObject(t)&&!r.t.isEmpty(t)&&e&&e.length&&s.shouldShowAudiences(e)){var n=t.a;if(n){"string"==typeof n&&(n=[n]);var a=function(e){return e.replace(l,"").toLowerCase()},i=n.reduce((function(e,t){return e[a(t)]=t,e}),{});return e.filter((function(e){return i[a(e.name)]}))}}},getAudienceParams:function(e){return(null==e?void 0:e.length)?{a:e.map((function(e){return e.name}))}:null},shouldShowAudiences:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return!!e&&e.length>1}}},91807:(e,t,n)=>{n.d(t,{Z:()=>a});const a={tagList:"Zw6d9",disabled:"jlL1c",partialTag:"too_N",badge:"OjtN8",close:"X9joI"}}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[5370],{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}}}},43482:(e,t,n)=>{n.d(t,{z:()=>f});var a=n(1024),r=n.n(a),i=n(81886),o=n(23481),l=n(83345),c=n(53957),s=n(38502),u=n(65858),p=n(55460),d="discover.header";function f(e){var t,n,a,f;if(!e.type)return r().createElement(r().Fragment,null);if(e.type===c.DashboardUserType.Learner)return r().createElement("div",{className:"py-3"},r().createElement("h1",{className:"h2 mb-0"},r().createElement(l.x,{namespace:d,phrase:"heading"})));function m(){var t,n=i.Q.AppLinkHelper.getCurrentAppLink();return(null===(t=e.appLinks)||void 0===t?void 0:t.newReleases.action)===n.action?"newReleases":"forYou"}return r().createElement("div",{className:"py-3 text-center"},r().createElement(s.r,{tabs:[{name:o.T.getPhrase(d,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===m(),analyticsData:{name:o.T.getPhrase(d,"forYou"),url:p.AppLinkHelper.getHref(null===(n=e.appLinks)||void 0===n?void 0:n.forYou)},analyticsOptions:{actionType:u.UserAction.Click,entity:u.EntityType.Url,location:u.LocationContext.MagicTabs}},{name:o.T.getPhrase(d,"newReleases"),appLink:null===(a=e.appLinks)||void 0===a?void 0:a.newReleases,active:"newReleases"===m(),analyticsData:{name:o.T.getPhrase(d,"newReleases"),url:p.AppLinkHelper.getHref(null===(f=e.appLinks)||void 0===f?void 0:f.newReleases)},analyticsOptions:{actionType:u.UserAction.Click,entity:u.EntityType.Url,location:u.LocationContext.MagicTabs}}]}))}},38502:(e,t,n)=>{n.d(t,{r:()=>s});var a=n(1024),r=n.n(a),i=n(11607),o=n(8493),l=n(87432),c=n(49985);function s(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(o.F,{appLink:e.appLink,analyticsData:e.analyticsData,analyticsOptions:e.analyticsOptions,className:"cursor-pointer d-block text-decoration-none text-reset px-2 ".concat(l.Z.pillItem)},e.name):r().createElement(i.L,{className:"".concat(l.Z.pillItem," px-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&c.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name))}))))}},74696:(e,t,n)=>{n.d(t,{S:()=>s});var a=n(1024),r=n.n(a),i=n(99910),o=n(86764),l=n(81514);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,l.V)(),n=t===o.r.XS,a=t===o.r.SM||t===o.r.MD,s=e.withReordering&&!n;return r().createElement(i.Row,{className:"py-2"},r().createElement(i.Col,{xs:n?12:a?4:3,className:"flex-column align-items-flex-start mb-1"},r().createElement(i.Row,null,!!s&&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:s?10:12},r().createElement("div",{className:"partial-loading-background rounded ".concat(c.partialThumbnail)})))),r().createElement(i.Col,{xs:n?12:a?8:9},r().createElement("div",{className:"partial-loading-background ".concat(c.partialSeriesLink)}),r().createElement("div",{className:"partial-loading-background mb-1 ".concat(c.partialName)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialDescription)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialBadges)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialActions)})))}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],p=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)})),p(t.filter((function(e){return e.length})))}}),[null==e?void 0:e.length]);var d=(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(d,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}))}}},37808:(e,t,n)=>{n.d(t,{aq:()=>f,YW:()=>v});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),p=n(10874);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}function f(e){var t,n,f=e.classification,m=e.backgroundUrl,v=e.followed,y=e.follow,b=e.showFollowSpinner,h=(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 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}}(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("B7jhq"),style:{backgroundImage:"url('".concat(m,"')")}},a.createElement(i.F,{className:"text-white text-shadow",appLink:e.getClassificationAppLink(f,h)},a.createElement("h2",{className:"h3 mb-0"},f.name)),e.canFollow&&a.createElement(p.h,{className:"btn follow-btn ".concat(v?"btn-outline-dark":"btn-dark"),svgName:v?u.vn.Check:u.vn.Bell,onClick:function(){return y(f.id,f.name,!v)}},b?a.createElement(o.Spinner,{as:"span",animation:"border",role:"status",size:"sm"}):a.createElement(r.x,{namespace:"contentUpdates.classificationBanner",phrase:v?"unfollow":"follow"})))}var m="playlists.liteClassificationUpdateBreadcrumbs";function v(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:m,phrase:"dashboard"}))),a.createElement("li",{className:"breadcrumb-item"},a.createElement(i.F,{appLink:e.contentUpdatesAppLink},a.createElement(r.x,{namespace:m,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:()=>_});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(49985),p=n(65858),d=n(53957),f=n(61699),m=n(39151),v=n(69883),y=n(39902),b=n(54644),h=n(51365),g=n(43482),k=n(83345),w=n(97816),E=n(97037),S=n(65986),C=n(8493),j=n(67453),A=n(54610),L=n(13231),N=n(37808);function O(e){var t=e.classification,n=e.videos,r=e.imageCdnUrl,i=e.showMore,o=e.followed,l=j.j.createBannerUrl(t.banner,{fallbackBaseUrl:r,fallbackCategoryName:t.name,type:A.__.Banners},{size:A.h2.Medium,resizeType:A.Nq.Cover});return a.createElement("div",{className:"mb-3"},a.createElement(N.aq,{classification:t,backgroundUrl:l,getClassificationAppLink:e.appLinks.getClassificationAppLink,followed:o,follow:e.follow,canFollow:e.canFollow,showFollowSpinner:e.showFollowSpinner}),a.createElement(L.E4,{videos:n,getVideoAppLink:e.appLinks.getVideoAppLink,getSeriesAppLink:e.appLinks.getSeriesAppLink,setFavourite:e.setFavourite,canFavourite:e.canFavourite}),i&&a.createElement("div",{className:"show-more"},a.createElement(C.F,{className:"info-link",appLink:e.appLinks.getClassificationUpdateAppLink(t)},a.createElement(k.x,{namespace:"contentUpdates.contentUpdatesView",phrase:"showMore",options:{classificationName:t.name}}))))}var U=n(74696);function F(){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("bxaA6")}),r().createElement(U.S,null),";")})))}var T=n(97291),x=n(14070),D=n(22902),I=n(16714),P=n(21750);function B(e){return B="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},B(e)}function M(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==B(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var a=n.call(e,t);if("object"!==B(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"===B(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function R(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 Y="contentUpdates.contentUpdatesView";function _(e){var t,n,r,j,A,L,N,U=(L=a.useState({}),N=2,function(e){if(Array.isArray(e))return e}(L)||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}}(L,N)||function(e,t){if(e){if("string"==typeof e)return R(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)?R(e,t):void 0}}(L,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.")}()),B=U[0],_=U[1],q=(0,o.useDispatch)(),V=(0,v.Z)();(0,s.o)(c.T.getPhrase(Y,"pageTitle"));var H=(0,D.T)().hasPermissions,z=H(I.C.FollowSubjects),Z=i().subtract(1,"year").endOf("day").format("YYYY-MM-DD"),W=i().endOf("day").format("YYYY-MM-DD"),$=l.a.useBasicFetch(m.L.config()),G=l.a.useBasicFetch(P.x.presentation()),Q=b.v.getContentUpdates(null===(t=G.data)||void 0===t?void 0:t.id,Z,W),J=l.a.useBasicFetch(G.data&&Q),X=l.a.useBasicFetch(z&&f.o.mySubjectPreferences()),K=[],ee=[];J.data&&J.data.forEach((function(e){K.push(e.id),ee=ee.concat(e.videos)}));var te=(0,y.f)(K,(function(e){return b.v.getClassifications(e)})).items,ne=(0,S._)(S.i.VideoItem);(0,w.V)(ee,{hasCurriculumLinks:!0,flightNamespace:null===(n=Q.normalizeOptions)||void 0===n?void 0:n.namespace});var ae=(0,E.c)(p.LocationContext.VideoThumbnail,null===(r=Q.normalizeOptions)||void 0===r?void 0:r.namespace),re=ae.setFavourite,ie=ae.canFavourite;function oe(e,t,n){_((function(t){return Object.assign(Object.assign({},t),M({},e,!0))}));var a=function(){var a;_((function(t){return Object.assign(Object.assign({},t),M({},e,!1))})),u.k.logUserAction({id:e,name:t},{location:p.LocationContext.ContentUpdatesClassificationBanner,workflowPhase:p.WorkflowPhase.Complete,descriptor:n?p.ToggleDescriptor.On:p.ToggleDescriptor.Off,actionType:p.UserAction.Follow,entity:p.EntityType.Classification}),V.success(c.T.getPhrase(Y,n?"followed":"unfollowed",{classification:null===(a=te[e])||void 0===a?void 0:a.name,escapeText:!0}))},r=function(){_((function(t){return Object.assign(Object.assign({},t),M({},e,!1))})),V.error(c.T.getPhrase(Y,"error"))},i=n?f.o.followSubjects([e],a,r):f.o.unfollowSubjects([e],a,r);l.a.fetch(q,i)}var le=!(!J.hasCompleted||!$.hasCompleted||z&&!X.hasCompleted||!te),ce=function(e,t){return e&&t?e.map((function(e){return{showMore:e.videos.length>5,classification:t[e.id],videos:e.videos.slice(0,5).map((function(e){return e.classification=t[e.id],e})).filter((function(e){return e}))}})):null}(J.data,te),se=null!==(A=null===(j=X.data)||void 0===j?void 0:j.map((function(e){return e.id})))&&void 0!==A?A:[];return a.createElement(h.M.Provider,{value:ne},a.createElement("div",{className:"bg-white px-3"},a.createElement(g.z,{type:d.DashboardUserType.Staff,appLinks:{forYou:e.appLinks.dashboardAppLink,newReleases:e.appLinks.contentUpdatesAppLink}}),a.createElement("h1",{className:"h4"},a.createElement(k.x,{namespace:Y,phrase:"newReleases"})),H(I.C.ManageSubjectPreferences)&&a.createElement("p",null,a.createElement(k.x,{namespace:Y,phrase:"onlyRelevant"})," ",a.createElement(C.F,{className:"info-link",appLink:{application:T.O.SETTINGS,action:x.e.Settings.TOPIC_PREFERENCES}},a.createElement(k.x,{namespace:Y,phrase:"updatePreferences"}))),le?a.createElement(a.Fragment,null,ce.map((function(t){return a.createElement(O,{classification:t.classification,videos:t.videos,imageCdnUrl:$.data.imageCdnUrl,showMore:t.showMore,key:t.classification.id,appLinks:e.appLinks,followed:se.includes(t.classification.id),follow:oe,showFollowSpinner:B[t.classification.id],canFollow:z,setFavourite:re,canFavourite:ie})}))):a.createElement(F,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}}}},97816:(e,t,n)=>{n.d(t,{V:()=>v});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 p(e){return function(e){if(Array.isArray(e))return d(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 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)||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 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 f={ratings:!1,favourites:!1,watchHistory:!1,hasCurriculumLinks:!1};function m(e,t){var n=i.a.useGetFetch();r().useEffect((function(){t&&e.length&&e.forEach((function(e){n(e)}))}),[e.length])}function v(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=Object.assign(Object.assign({},f),t),a=n.ratings,d=n.favourites,v=n.watchHistory,y=n.hasCurriculumLinks,b=i.a.useBasicFetch(o.N.currentUser()),h=e&&(Array.isArray(e)?e.filter(Boolean).map((function(e){return e.id})):e.data.filter(Boolean).map((function(e){return e.id}))),g=b.data;function k(){if(!(null==g?void 0:g.isAuthenticated))return[];var e=[];return a&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&l.R.videoRatings(h,t.flightNamespace)])),d&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&g&&u.P.isFavourited(g.id,h,t.flightNamespace)])),v&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&g&&s.p.videoHistory(h,t.flightNamespace)])),y&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&c.x.hasCurriculumLinks(h,t.flightNamespace)])),e.filter(Boolean)}var w=r().useMemo(k,[null==h?void 0:h.length]);m(w,!!e)}},87432:(e,t,n)=>{n.d(t,{Z:()=>a});const a={pillTabSelector:"Hdi6o",pillItem:"hUJx1"}}}]);
|
|
1
|
+
"use strict";(self.webpackChunk_clickview_lite=self.webpackChunk_clickview_lite||[]).push([[5370],{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}}}},43482:(e,t,n)=>{n.d(t,{z:()=>f});var a=n(1024),r=n.n(a),i=n(81886),o=n(23481),l=n(83345),c=n(53957),s=n(38502),u=n(65858),p=n(55460),d="discover.header";function f(e){var t,n,a,f;if(!e.type)return r().createElement(r().Fragment,null);if(e.type===c.DashboardUserType.Learner)return r().createElement("div",{className:"py-3"},r().createElement("h1",{className:"h2 mb-0"},r().createElement(l.x,{namespace:d,phrase:"heading"})));function m(){var t,n=i.Q.AppLinkHelper.getCurrentAppLink();return(null===(t=e.appLinks)||void 0===t?void 0:t.newReleases.action)===n.action?"newReleases":"forYou"}return r().createElement("div",{className:"py-3 text-center"},r().createElement(s.r,{tabs:[{name:o.T.getPhrase(d,"forYou"),appLink:null===(t=e.appLinks)||void 0===t?void 0:t.forYou,active:"forYou"===m(),analyticsData:{name:o.T.getPhrase(d,"forYou"),url:p.AppLinkHelper.getHref(null===(n=e.appLinks)||void 0===n?void 0:n.forYou)},analyticsOptions:{actionType:u.UserAction.Click,entity:u.EntityType.Url,location:u.LocationContext.MagicTabs}},{name:o.T.getPhrase(d,"newReleases"),appLink:null===(a=e.appLinks)||void 0===a?void 0:a.newReleases,active:"newReleases"===m(),analyticsData:{name:o.T.getPhrase(d,"newReleases"),url:p.AppLinkHelper.getHref(null===(f=e.appLinks)||void 0===f?void 0:f.newReleases)},analyticsOptions:{actionType:u.UserAction.Click,entity:u.EntityType.Url,location:u.LocationContext.MagicTabs}}]}))}},38502:(e,t,n)=>{n.d(t,{r:()=>s});var a=n(1024),r=n.n(a),i=n(11607),o=n(8493),l=n(87432),c=n(49985);function s(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(o.F,{appLink:e.appLink,analyticsData:e.analyticsData,analyticsOptions:e.analyticsOptions,className:"cursor-pointer d-block text-decoration-none text-reset px-2 ".concat(l.Z.pillItem)},e.name):r().createElement(i.L,{className:"".concat(l.Z.pillItem," px-2"),onClick:function(){return function(e){!e.active&&e.onSelect&&(e.onSelect(),e.analyticsData&&e.analyticsOptions&&c.k.logUserAction(e.analyticsData,e.analyticsOptions))}(e)}},e.name))}))))}},74696:(e,t,n)=>{n.d(t,{S:()=>s});var a=n(1024),r=n.n(a),i=n(99910),o=n(86764),l=n(81514);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,l.V)(),n=t===o.r.XS,a=t===o.r.SM||t===o.r.MD,s=e.withReordering&&!n;return r().createElement(i.Row,{className:"py-2"},r().createElement(i.Col,{xs:n?12:a?4:3,className:"flex-column align-items-flex-start mb-1"},r().createElement(i.Row,null,!!s&&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:s?10:12},r().createElement("div",{className:"partial-loading-background rounded ".concat(c.partialThumbnail)})))),r().createElement(i.Col,{xs:n?12:a?8:9},r().createElement("div",{className:"partial-loading-background ".concat(c.partialSeriesLink)}),r().createElement("div",{className:"partial-loading-background mb-1 ".concat(c.partialName)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialDescription)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialBadges)}),r().createElement("div",{className:"partial-loading-background ".concat(c.partialActions)})))}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],p=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)})),p(t.filter((function(e){return e.length})))}}),[null==e?void 0:e.length]);var d=(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(d,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}))}}},37808:(e,t,n)=>{n.d(t,{aq:()=>f,YW:()=>v});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),p=n(10874);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}function f(e){var t,n,f=e.classification,m=e.backgroundUrl,v=e.followed,y=e.follow,b=e.showFollowSpinner,h=(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 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}}(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("B7jhq"),style:{backgroundImage:"url('".concat(m,"')")}},a.createElement(i.F,{className:"text-white text-shadow",appLink:e.getClassificationAppLink(f,h)},a.createElement("h2",{className:"h3 mb-0"},f.name)),e.canFollow&&a.createElement(p.h,{className:"btn follow-btn ".concat(v?"btn-outline-dark":"btn-dark"),svgName:v?u.vn.Check:u.vn.Bell,onClick:function(){return y(f.id,f.name,!v)}},b?a.createElement(o.Spinner,{as:"span",animation:"border",role:"status",size:"sm"}):a.createElement(r.x,{namespace:"contentUpdates.classificationBanner",phrase:v?"unfollow":"follow"})))}var m="playlists.liteClassificationUpdateBreadcrumbs";function v(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:m,phrase:"dashboard"}))),a.createElement("li",{className:"breadcrumb-item"},a.createElement(i.F,{appLink:e.contentUpdatesAppLink},a.createElement(r.x,{namespace:m,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:()=>_});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),p=n(61699),d=n(39151),f=n(69883),m=n(39902),v=n(54644),y=n(51365),b=n(43482),h=n(83345),g=n(22902),k=n(16714),w=n(8493),E=n(97037),S=n(49985),C=n(65858),j=n(65986),A=n(97291),L=n(97816),N=n(14070),O=n(51200),U=n(67453),F=n(54610),T=n(13231),x=n(37808);function D(e){var t=e.classification,n=e.videos,r=e.imageCdnUrl,i=e.showMore,o=e.followed,l=U.j.createBannerUrl(t.banner,{fallbackBaseUrl:r,fallbackCategoryName:t.name,type:F.__.Banners},{size:F.h2.Medium,resizeType:F.Nq.Cover});return a.createElement("div",{className:"mb-3"},a.createElement(x.aq,{classification:t,backgroundUrl:l,getClassificationAppLink:e.appLinks.getClassificationAppLink,followed:o,follow:e.follow,canFollow:e.canFollow,showFollowSpinner:e.showFollowSpinner}),a.createElement(T.E4,{videos:n,getVideoAppLink:e.appLinks.getVideoAppLink,getSeriesAppLink:e.appLinks.getSeriesAppLink,setFavourite:e.setFavourite,canFavourite:e.canFavourite}),i&&a.createElement("div",{className:"show-more"},a.createElement(w.F,{className:"info-link",appLink:e.appLinks.getClassificationUpdateAppLink(t)},a.createElement(h.x,{namespace:"contentUpdates.contentUpdatesView",phrase:"showMore",options:{classificationName:t.name}}))))}var I=n(74696);function P(){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("bxaA6")}),r().createElement(I.S,null),";")})))}function B(e){return B="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},B(e)}function M(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==B(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var a=n.call(e,t);if("object"!==B(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"===B(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function R(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 Y="contentUpdates.contentUpdatesView";function _(e){var t,n,r,U,F,T,x=(F=a.useState({}),T=2,function(e){if(Array.isArray(e))return e}(F)||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}}(F,T)||function(e,t){if(e){if("string"==typeof e)return R(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)?R(e,t):void 0}}(F,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.")}()),I=x[0],B=x[1],_=(0,o.useDispatch)(),q=(0,f.Z)();(0,s.o)(c.T.getPhrase(Y,"pageTitle"));var V=(0,g.T)().hasPermissions,H=V(k.C.FollowSubjects),z=i().subtract(1,"year").endOf("day").format("YYYY-MM-DD"),Z=i().endOf("day").format("YYYY-MM-DD"),W=l.a.useBasicFetch(d.L.config()),$=(0,O.I)().presentation,G=v.v.getContentUpdates(null==$?void 0:$.id,z,Z),Q=l.a.useBasicFetch($&&G),J=l.a.useBasicFetch(H&&p.o.mySubjectPreferences()),X=[],K=[];Q.data&&Q.data.forEach((function(e){X.push(e.id),K=K.concat(e.videos)}));var ee=(0,m.f)(X,(function(e){return v.v.getClassifications(e)})).items,te=(0,j._)(j.i.VideoItem);(0,L.V)(K,{hasCurriculumLinks:!0,flightNamespace:null===(t=G.normalizeOptions)||void 0===t?void 0:t.namespace});var ne=(0,E.c)(C.LocationContext.VideoThumbnail,null===(n=G.normalizeOptions)||void 0===n?void 0:n.namespace),ae=ne.setFavourite,re=ne.canFavourite;function ie(e,t,n){B((function(t){return Object.assign(Object.assign({},t),M({},e,!0))}));var a=function(){var a;B((function(t){return Object.assign(Object.assign({},t),M({},e,!1))})),S.k.logUserAction({id:e,name:t},{location:C.LocationContext.ContentUpdatesClassificationBanner,workflowPhase:C.WorkflowPhase.Complete,descriptor:n?C.ToggleDescriptor.On:C.ToggleDescriptor.Off,actionType:C.UserAction.Follow,entity:C.EntityType.Classification}),q.success(c.T.getPhrase(Y,n?"followed":"unfollowed",{classification:null===(a=ee[e])||void 0===a?void 0:a.name,escapeText:!0}))},r=function(){B((function(t){return Object.assign(Object.assign({},t),M({},e,!1))})),q.error(c.T.getPhrase(Y,"error"))},i=n?p.o.followSubjects([e],a,r):p.o.unfollowSubjects([e],a,r);l.a.fetch(_,i)}var oe=!(!Q.hasCompleted||!W.hasCompleted||H&&!J.hasCompleted||!ee),le=function(e,t){return e&&t?e.map((function(e){return{showMore:e.videos.length>5,classification:t[e.id],videos:e.videos.slice(0,5).map((function(e){return e.classification=t[e.id],e})).filter((function(e){return e}))}})):null}(Q.data,ee),ce=null!==(U=null===(r=J.data)||void 0===r?void 0:r.map((function(e){return e.id})))&&void 0!==U?U:[];return a.createElement(y.M.Provider,{value:te},a.createElement("div",{className:"bg-white px-3"},a.createElement(b.z,{type:u.DashboardUserType.Staff,appLinks:{forYou:e.appLinks.dashboardAppLink,newReleases:e.appLinks.contentUpdatesAppLink}}),a.createElement("h1",{className:"h4"},a.createElement(h.x,{namespace:Y,phrase:"newReleases"})),V(k.C.ManageSubjectPreferences)&&a.createElement("p",null,a.createElement(h.x,{namespace:Y,phrase:"onlyRelevant"})," ",a.createElement(w.F,{className:"info-link",appLink:{application:A.O.SETTINGS,action:N.e.Settings.TOPIC_PREFERENCES}},a.createElement(h.x,{namespace:Y,phrase:"updatePreferences"}))),oe?a.createElement(a.Fragment,null,le.map((function(t){return a.createElement(D,{classification:t.classification,videos:t.videos,imageCdnUrl:W.data.imageCdnUrl,showMore:t.showMore,key:t.classification.id,appLinks:e.appLinks,followed:ce.includes(t.classification.id),follow:ie,showFollowSpinner:I[t.classification.id],canFollow:H,setFavourite:ae,canFavourite:re})}))):a.createElement(P,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}}}},97816:(e,t,n)=>{n.d(t,{V:()=>v});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 p(e){return function(e){if(Array.isArray(e))return d(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 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)||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 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 f={ratings:!1,favourites:!1,watchHistory:!1,hasCurriculumLinks:!1};function m(e,t){var n=i.a.useGetFetch();r().useEffect((function(){t&&e.length&&e.forEach((function(e){n(e)}))}),[e.length])}function v(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=Object.assign(Object.assign({},f),t),a=n.ratings,d=n.favourites,v=n.watchHistory,y=n.hasCurriculumLinks,b=i.a.useBasicFetch(o.N.currentUser()),h=e&&(Array.isArray(e)?e.filter(Boolean).map((function(e){return e.id})):e.data.filter(Boolean).map((function(e){return e.id}))),g=b.data;function k(){if(!(null==g?void 0:g.isAuthenticated))return[];var e=[];return a&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&l.R.videoRatings(h,t.flightNamespace)])),d&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&g&&u.P.isFavourited(g.id,h,t.flightNamespace)])),v&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&g&&s.p.videoHistory(h,t.flightNamespace)])),y&&(e=[].concat(p(e),[!!(null==h?void 0:h.length)&&c.x.hasCurriculumLinks(h,t.flightNamespace)])),e.filter(Boolean)}var w=r().useMemo(k,[null==h?void 0:h.length]);m(w,!!e)}},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([[9304],{92869:(e,t,n)=>{n.d(t,{t:()=>i});var r=n(48088),a=n(95846),i={preventScrollTop:function(){r.Radio.channel(a.G.SHELL).trigger("prevent:scroll:top")}}},30727:(e,t,n)=>{n.d(t,{U:()=>a});var r=n(1024);function a(e){var t=e.count,n=void 0===t?6:t;return r.createElement("div",{className:"d-flex"},r.createElement("div",{className:"d-flex pl-1"},Array(n).fill(null).map((function(e,t){return r.createElement("div",{key:t,className:"".concat("ThKam"," partial-loading-background mx-1")})}))))}},49935:(e,t,n)=>{n.d(t,{Oo:()=>c,b2:()=>l});var r=n(1024),a=n(8493),i=n(5859),o=function(e){var t=e.breadcrumb,n=t.name,i=t.appLink,o=t.active;return r.createElement("li",{className:"breadcrumb-item".concat(o?" active":"")},o?r.createElement("strong",null,n):r.createElement(a.F,{appLink:i},n))},c=function(e){var t=e.breadcrumbs;return(null==t?void 0:t.length)?r.createElement("ol",{className:"breadcrumb m-0 p-0"},t.map((function(e,t){return r.createElement(o,{key:t,breadcrumb:e})}))):r.createElement(r.Fragment,null)},l=r.memo((function(e){var t=e.numItems,n=void 0===t?3:t;return r.createElement("nav",{"aria-label":"breadcrumb"},r.createElement("ol",{className:"breadcrumb m-0 p-0"},i.u.getPartialLoadingItems({numItems:n}).map((function(e,t){var n=e.width;return r.createElement("li",{key:t,className:"breadcrumb-item"},r.createElement("span",{className:"d-inline-block partial-loading-background",style:{width:n},dangerouslySetInnerHTML:{__html:" "}}))}))))}))},37395:(e,t,n)=>{n.d(t,{t:()=>d});var r=n(1024),a=n(99910),i=n(92869),o=n(8493),c=n(83345),l=n(49985),u=n(65858);function s(e,t){var n;if(!t)return null;var r=null!==(n=e.params)&&void 0!==n?n:{};return{application:e.application,action:e.action,args:e.args,params:Object.assign(Object.assign({},r),{cursor:t})}}function d(e){var t=e.appLink,n=e.cursors,d=e.className,f=e.buttonVariant,v=e.onClick;function m(e){t&&i.t.preventScrollTop(),l.k.logUserAction({page:e},{location:u.LocationContext.Pagination,entity:u.EntityType.Pagination,actionType:u.UserAction.Navigate}),v&&v(n[e])}return t?r.createElement(c.D.Provider,{value:"shared.pagination"},r.createElement("div",{className:d},r.createElement(o.F,{appLink:s(t,n.previous),className:"btn btn-".concat(f," mr-1 ").concat(n.previous?"":"disabled"),onClick:function(){return m("previous")}},r.createElement(c.x,{phrase:"previous"})),r.createElement(o.F,{appLink:s(t,n.next),className:"btn btn-".concat(f," ").concat(n.next?"":"disabled"),onClick:function(){return m("next")}},r.createElement(c.x,{phrase:"next"})))):r.createElement(c.D.Provider,{value:"shared.pagination"},r.createElement("div",{className:d},r.createElement(a.Button,{variant:f,className:"mr-1 ".concat(n.previous?"":"disabled"),onClick:function(){return m("previous")}},r.createElement(c.x,{phrase:"previous"})),r.createElement(a.Button,{variant:f,className:"btn ".concat(n.next?"":"disabled"),onClick:function(){return m("next")}},r.createElement(c.x,{phrase:"next"}))))}d.defaultProps={className:"py-2",buttonVariant:"secondary"}},16035:(e,t,n)=>{n.d(t,{z:()=>s});var r=n(1024),a=n.n(r),i=n(8493),o=n(44829),c=n(58130),l=n(83914),u=n(91807);function s(e){var t,n,r=e.tag,s=e.appLink,d=e.onClick,f=e.disabled,v=e.tagClass,m=void 0===v?"tag":v,p=r.name.toLowerCase(),g=null===(t=r.tagType)||void 0===t?void 0:t.toLowerCase(),b="badge-pill py-1 px-2 my-1 mr-1 ".concat(m," ").concat(function(e){switch(e){case o.Q.Pedagogy:case o.Q.Skill:return"pedagogy-tag text-white";case o.Q.Hidden:return"hidden-tag";case o.Q.Normal:default:return""}}(g)),y=g===o.Q.Normal&&!!(null===(n=e.themeColours)||void 0===n?void 0:n.secondary);y&&(b+=" text-white"),!s&&!d||f||(b+=" cursor-pointer"),f&&(b+=" "+u.Z.disabled),e.onRemove&&(b+=" "+u.Z.badge);var h=y?{backgroundColor:e.themeColours.secondary}:{};return s?a().createElement(i.F,{onClick:d,appLink:s,className:b,title:p,style:h},a().createElement("span",{className:"text-truncate text-nowrap"},p)):a().createElement("span",{onClick:d,className:b,title:p,style:h},a().createElement("span",{className:"text-truncate text-nowrap"},p,e.onRemove&&a().createElement("button",{onClick:e.onRemove,className:"".concat(u.Z.close," close font-size-normal")},a().createElement(l.x,{size:l.S.Small,svgName:c.vn.Close,className:"d-inline-block svg-container"}))))}},43872:(e,t,n)=>{n.d(t,{V:()=>s});var r=n(1024),a=n(82182),i=n(31069),o=n(79014),c=new Image;c.src="data:image/gif;base64,R0lGODlhAQABAIAAAAUEBAAAACwAAAAAAQABAAACAkQBADs=";var l=function(e){e.dataTransfer.setDragImage&&o.q.isFunction(e.dataTransfer.setDragImage)&&e.dataTransfer.setDragImage(c,0,0)},u=a.V.isTouchScreen(),s=r.forwardRef((function(e,t){var n,a,o,c,s=e.children,d=e.positionType,f=e.onDrag,v=e.onDragEnd,m=e.onTouchMove,p=e.onTouchEnd,g=e.percentageDragged,b=e.position,y=void 0===b?0:b;return r.createElement("div",Object.assign({className:"d-flex flex-nowrap position-relative w-100",style:(a=y,o=d,c=g,o===i.C.Percentage&&c&&(a-=c),{transform:"translate3d(".concat(a).concat(o,", 0px, 0px)"),transition:"transform .4s ease-in-out"}),ref:t},(n={},f&&v&&(n.draggable=!0,n.onDragEnd=v,n.onDragStart=l,n.onDragOver=f),m&&p&&u&&(n.onTouchMoveCapture=m,n.onTouchEndCapture=p),n)),s)}))},31069:(e,t,n)=>{var r;n.d(t,{C:()=>r}),function(e){e.Percentage="%",e.Pixels="px"}(r||(r={}))},10841:(e,t,n)=>{var r;n.d(t,{n:()=>r}),function(e){e.Init="init",e.Next="next",e.Previous="previous",e.Resize="resize",e.Drag="drag",e.Update="update",e.JumpToIndex="jump-to-index"}(r||(r={}))},91286:(e,t,n)=>{n.d(t,{v:()=>o});var r=n(1024),a=n(94644);function i(e){return e.map((function(e){return e.statusCode})).join(":")}function o(e,t,n){var o=Array.isArray(e)?e:[e];(0,r.useEffect)((function(){o.forEach((function(e){(0,a.r)(e.statusCode,t,n)}))}),[i(o),t,n])}},299:(e,t,n)=>{n.d(t,{X:()=>c});var r=n(1024),a=n.n(r),i=n(94631),o=n(69217),c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.idField,r=void 0===n?"id":n,c=t.persistNamespace,l=t.initialState?t.initialState:new Map,u=a().useRef(l),s=(0,o.N)(),d=(0,i.D)(e),f=(0,i.D)(c);function v(){u.current.clear(),s()}function m(){var t=!A();e.forEach((function(e){t?u.current.set(e[r].toString(),!0):u.current.delete(e[r].toString())})),s()}function p(e){var t=!u.current.get(e.toString());t?u.current.set(e.toString(),t):u.current.delete(e.toString()),s()}function g(e){return"number"==typeof e?e=e.toString():"string"!=typeof e&&(e=e[r].toString()),u.current.get(e)}function b(){return Array.from(u.current.keys())}function y(){(null==e?void 0:e.length)&&(e.forEach((function(e){u.current.delete(e[r].toString())})),s())}function h(){return!!(null==e?void 0:e.length)&&!!e.find((function(e){return g(e)}))}function A(){return!!(null==e?void 0:e.length)&&e.every(g)}function E(e){e.forEach((function(e){u.current.set(e,!0)})),s()}function k(){return u.current.size}function S(){return u.current}return a().useEffect((function(){t.initialState||c&&f===c||(null==d?void 0:d.map((function(e){return e[r]})).join())!==(null==e?void 0:e.map((function(e){return e[r]})).join())&&v()}),[d,f,e,t.initialState]),a().useEffect((function(){var e;(null===(e=t.preselectedIds)||void 0===e?void 0:e.length)&&E(t.preselectedIds)}),[]),{onToggleBulk:m,onToggleItem:p,getSelected:b,isChecked:g,bulkChecked:A(),deselectAll:y,hasSomeSelections:h,setSelected:E,getSelectedCount:k,reset:v,getMap:S}}},69217:(e,t,n)=>{n.d(t,{N:()=>o});var r=n(1024),a=n.n(r);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var o=function(){var e,t,n=(e=a().useState(Date.now()),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 r,a,i,o,c=[],l=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=i.call(n)).done)&&(c.push(r.value),c.length!==t);l=!0);}catch(e){u=!0,a=e}finally{try{if(!l&&null!=n.return&&(o=n.return(),Object(o)!==o))return}finally{if(u)throw a}}return c}}(e,t)||function(e,t){if(e){if("string"==typeof e)return i(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)?i(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.")}())[1];return function(){n(Date.now())}}},94631:(e,t,n)=>{n.d(t,{D:()=>i});var r=n(1024),a=n.n(r);function i(e){var t=a().useRef();return a().useEffect((function(){t.current=e})),t.current}},49542:(e,t,n)=>{n.d(t,{d:()=>d});var r,a,i=n(1024),o=n.n(i),c=n(65858),l=n(53957);function u(e){return function(e){if(Array.isArray(e))return s(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 s(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)?s(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 s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}!function(e){e[e.Draft=0]="Draft",e[e.Published=1]="Published",e[e.Archived=2]="Archived"}(r||(r={})),function(e){e.Draft="Draft",e.Published="Published",e.Archived="Archived"}(a||(a={}));var d={getSliderAnalyticsOptions:function(){return{actionType:c.UserAction.Click,location:c.LocationContext.SlidingList,entity:c.EntityType.Widget,descriptor:c.ClickDescriptor.Slide}},getSliderItemAnalyticsOptions:function(){return{location:c.LocationContext.SlidingListItem}},getSliderHeadingAnalyticsOptions:function(){return{actionType:c.UserAction.Click,location:c.LocationContext.SlidingList,entity:c.EntityType.Widget,descriptor:c.ClickDescriptor.Title}},useGetContent:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return o().useMemo((function(){var r;if(!e)return null;var a="data"in e?e.data:e;if(!Array.isArray(a))return a;var i=null!==(r=null==t?void 0:t.reduce((function(e,t){return e[t.id]=t,e}),{}))&&void 0!==r?r:{};return a=u(a).sort((function(e,t){var n,r,o,c,l=null!==(r=null===(n=i[e.id])||void 0===n?void 0:n.index)&&void 0!==r?r:a.findIndex((function(t){return t.id===e.id})),u=null!==(c=null===(o=i[t.id])||void 0===o?void 0:o.index)&&void 0!==c?c:a.findIndex((function(e){return e.id===t.id}));return l<u?-1:l>u?1:0})),n?a:a.filter((function(e){var t;return!(null===(t=i[e.id])||void 0===t?void 0:t.hidden)}))}),[e,t,n])},getCustomAppLink:function(e){var t,n,r,a,i,o;return(null===(t=e.metadata)||void 0===t?void 0:t.appLink)===l.CuratedDashboardAppLink.LatestReleases?null===(r=null===(n=e.appLinks)||void 0===n?void 0:n.latestReleases)||void 0===r?void 0:r.call(n):(null===(a=e.metadata)||void 0===a?void 0:a.appLink)===l.CuratedDashboardAppLink.ExploreAllTopics?null===(o=null===(i=e.appLinks)||void 0===i?void 0:i.allTopics)||void 0===o?void 0:o.call(i):null},getWidgetStatus:function(e){var t=e.status;if("string"==typeof t)switch(t){case a.Archived:t=r.Archived;break;case a.Published:t=r.Published;break;case a.Draft:t=r.Draft}return t}}},91807:(e,t,n)=>{n.d(t,{Z:()=>r});const r={tagList:"Zw6d9",disabled:"jlL1c",partialTag:"too_N",badge:"OjtN8",close:"X9joI"}}}]);
|