@sunbird-cb/consumption 0.0.45 → 0.0.47
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/bundles/sunbird-cb-consumption.umd.js +2004 -47
- package/bundles/sunbird-cb-consumption.umd.js.map +1 -1
- package/bundles/sunbird-cb-consumption.umd.min.js +1 -1
- package/bundles/sunbird-cb-consumption.umd.min.js.map +1 -1
- package/esm2015/lib/_common/cards/card-assessment/card-assessment/card-assessment.component.js +34 -24
- package/esm2015/lib/_common/cards/card-landscape/card-landscape.component.js +2 -2
- package/esm2015/lib/_common/cards/card-portrait/card-portrait.component.js +2 -2
- package/esm2015/lib/_common/cards/card-portrait-ext/card-portrait-ext.component.js +2 -2
- package/esm2015/lib/_common/cards/card-progress-portrait-lib/card-progress-portrait-lib.component.js +2 -2
- package/esm2015/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.component.js +1613 -0
- package/esm2015/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.model.js +218 -0
- package/esm2015/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.module.js +69 -0
- package/esm2015/public-api.js +2 -1
- package/esm2015/sunbird-cb-consumption.js +16 -15
- package/esm5/lib/_common/cards/card-assessment/card-assessment/card-assessment.component.js +46 -30
- package/esm5/lib/_common/cards/card-landscape/card-landscape.component.js +2 -2
- package/esm5/lib/_common/cards/card-portrait/card-portrait.component.js +2 -2
- package/esm5/lib/_common/cards/card-portrait-ext/card-portrait-ext.component.js +2 -2
- package/esm5/lib/_common/cards/card-progress-portrait-lib/card-progress-portrait-lib.component.js +2 -2
- package/esm5/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.component.js +1892 -0
- package/esm5/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.model.js +218 -0
- package/esm5/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.module.js +73 -0
- package/esm5/public-api.js +2 -1
- package/esm5/sunbird-cb-consumption.js +16 -15
- package/fesm2015/sunbird-cb-consumption.js +1695 -28
- package/fesm2015/sunbird-cb-consumption.js.map +1 -1
- package/fesm5/sunbird-cb-consumption.js +1988 -34
- package/fesm5/sunbird-cb-consumption.js.map +1 -1
- package/lib/_common/cards/card-assessment/card-assessment/card-assessment.component.d.ts +4 -3
- package/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.component.d.ts +161 -0
- package/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.model.d.ts +149 -0
- package/lib/_common/strips/content-strip-with-tabs-pills/content-strip-with-tabs-pills.module.d.ts +5 -0
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
- package/sunbird-cb-consumption.d.ts +14 -13
- package/sunbird-cb-consumption.metadata.json +1 -1
|
@@ -9172,7 +9172,7 @@
|
|
|
9172
9172
|
CardPortraitComponent.decorators = [
|
|
9173
9173
|
{ type: core.Component, args: [{
|
|
9174
9174
|
selector: 'sb-uic-card-portrait',
|
|
9175
|
-
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove cursor-pointer {{widgetData?.cardCustomeClass}}\" [ngClass]=\"{\n greyOut:\n widgetData.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\" (click)=\"(showIntranetContent || !isLiveOrMarkForDeletion) && showSnackbar()\">\n <div class=\"display-contents\" [ngClass]=\"{\n disableClick:\n widgetData.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"getRedirectUrlData(widgetData?.content); $event.stopPropagation()\"\n role=\"link\" i18n-aria-label>\n <ng-container *ngIf=\"!isCardFlipped\">\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Content expired or deleted\" i18n-matTooltip\n matTooltip=\"Content may be expired or deleted\" *ngIf=\"!isLiveOrMarkForDeletion\"></div>\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Intranet content\" i18n-matTooltip\n matTooltip=\"Available only in Company's network\"\n *ngIf=\"widgetData?.intranetMode === 'greyOut' && showIntranetContent\"></div>\n <button *ngIf=\"showFlip\" class=\"detail-button ws-mat-primary-lite-background-op30\" mat-icon-button\n (click)=\"isCardFlipped = true\" aria-label=\"Details\" i18n-aria-label=\"Details | Click to see details\">\n <mat-icon>flip_to_back</mat-icon>\n </button>\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container *ngIf=\"widgetData.content.posterImage\">\n <img mat-card-image [src]=\"widgetData.content.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-container *ngIf=\"!widgetData.content.posterImage\">\n <ng-container *ngIf=\"widgetData.content.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.appIcon | pipePublicURL\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData.content.name\" />\n </ng-template>\n </ng-container>\n <div class=\"source-div\" style=\"display: none;\">\n <img [src]=\"widgetData.content.creatorLogo\" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData.content.sourceName + '_' + widgetData.content.identifier)\" />\n </div>\n <ng-container *ngIf=\"widgetData?.content?.cbPlanEndDate\">\n <div class=\"cbp-mark\">\n <span>{{widgetData?.content?.cbPlanEndDate | date: 'd MMM, y'}}</span>\n </div>\n </ng-container>\n <!-- <ng-container *ngIf=\"widgetData?.content?.endDate\">\n <div class=\"cbp-mark\">\n <p *ngIf=\"widgetData?.content?.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{widgetData?.content?.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"widgetData?.content?.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{widgetData?.content?.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"widgetData?.content?.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">Over due</p>\n </div>\n </ng-container> -->\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.identifier]\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.identifier]\n }}\"></ng-container>\n </ng-container>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end course_v2\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type i18n-title title=\"Content Type\" *ngIf=\"widgetData.content?.primaryCategory\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [displayContentType]=\"widgetData.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData.content?.primaryCategory\">\n\n </sb-uic-display-content-type>\n </div>\n </div>\n <div [id]=\"'m-c-'+ widgetData.content?.identifier\"\n class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n {{ widgetData.content.name }}\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\"course_logo_box\">\n <img [src]=\"widgetData.content.creatorLogo | pipePublicURL \" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData.content.sourceName + '_' + widgetData.content.identifier)\" />\n </div>\n <!-- <span class=\"org-text\">{{'cardcontentv2.by' | translate}} -->\n <span class=\"org-text\">By {{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ? widgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}</span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon class=\"mr-1\">star</mat-icon>\n <span>{{widgetData.content.avgRating}}</span>\n </div>\n <!-- <span class=\"most-enrolled-text margin-left-m\">{{ 'cardcontentv2.mostEnrolled' | translate }}</span> -->\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostEnrolled')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostEnrolled' | translate }} -->\n </span>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostTrending')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostTrending' | translate }} -->\n </span>\n </ng-container>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n <ng-container *ngIf=\"isCardFlipped\">\n <div class=\"flex items-center\">\n <!-- <h2 class=\"mat-subheading-2 flex-1 min-w-0 margin-remove-bottom\" i18n>{{'cardcontentv2.reason' | translate}}</h2> -->\n <button mat-icon-button (click)=\"isCardFlipped = false\">\n <mat-icon>close</mat-icon>\n </button>\n </div>\n <p class=\"text-justify mat-body-1\">\n {{ widgetData.content.reason }}\n </p>\n </ng-container>\n </a>\n </ng-container>\n </div>\n</mat-card>\n</ng-container>\n\n<ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove\" >\n <div class=\"display-contents\" >\n <ng-container *ngIf=\"!isCardFlipped\">\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'140px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n <div class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded margin-top-s'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle margin-top-m\">\n <div class=\"\">\n <sb-uic-skeleton-loader [width]=\"'28px'\" [height]=\"'28px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <span class=\"org-text\"> <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader></span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'45px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded margin-top-m'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </div>\n </mat-card>\n</ng-container>\n\n<ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n</ng-template>",
|
|
9175
|
+
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove cursor-pointer {{widgetData?.cardCustomeClass}}\" [ngClass]=\"{\n greyOut:\n widgetData.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\" (click)=\"(showIntranetContent || !isLiveOrMarkForDeletion) && showSnackbar()\">\n <div class=\"display-contents\" [ngClass]=\"{\n disableClick:\n widgetData.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"getRedirectUrlData(widgetData?.content); $event.stopPropagation()\"\n role=\"link\" i18n-aria-label>\n <ng-container *ngIf=\"!isCardFlipped\">\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Content expired or deleted\" i18n-matTooltip\n matTooltip=\"Content may be expired or deleted\" *ngIf=\"!isLiveOrMarkForDeletion\"></div>\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Intranet content\" i18n-matTooltip\n matTooltip=\"Available only in Company's network\"\n *ngIf=\"widgetData?.intranetMode === 'greyOut' && showIntranetContent\"></div>\n <button *ngIf=\"showFlip\" class=\"detail-button ws-mat-primary-lite-background-op30\" mat-icon-button\n (click)=\"isCardFlipped = true\" aria-label=\"Details\" i18n-aria-label=\"Details | Click to see details\">\n <mat-icon>flip_to_back</mat-icon>\n </button>\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container *ngIf=\"widgetData.content.posterImage\">\n <img mat-card-image [src]=\"widgetData.content.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-container *ngIf=\"!widgetData.content.posterImage\">\n <ng-container *ngIf=\"widgetData.content.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.appIcon | pipePublicURL\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData.content.name\" />\n </ng-template>\n </ng-container>\n <div class=\"source-div\" style=\"display: none;\">\n <img [src]=\"widgetData.content.creatorLogo\" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData.content.sourceName + '_' + widgetData.content.identifier)\" />\n </div>\n <ng-container *ngIf=\"widgetData?.content?.cbPlanEndDate\">\n <div class=\"cbp-mark\">\n <span>{{widgetData?.content?.cbPlanEndDate | date: 'd MMM, y'}}</span>\n </div>\n </ng-container>\n <!-- <ng-container *ngIf=\"widgetData?.content?.endDate\">\n <div class=\"cbp-mark\">\n <p *ngIf=\"widgetData?.content?.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{widgetData?.content?.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"widgetData?.content?.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{widgetData?.content?.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"widgetData?.content?.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">Over due</p>\n </div>\n </ng-container> -->\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.identifier] && cbPlanMapData[widgetData?.content?.identifier]?.contentStatus < 2\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.identifier]\n }}\"></ng-container>\n </ng-container>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end course_v2\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type i18n-title title=\"Content Type\" *ngIf=\"widgetData.content?.primaryCategory\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [displayContentType]=\"widgetData.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData.content?.primaryCategory\">\n\n </sb-uic-display-content-type>\n </div>\n </div>\n <div [id]=\"'m-c-'+ widgetData.content?.identifier\"\n class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n {{ widgetData.content.name }}\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\"course_logo_box\">\n <img [src]=\"widgetData.content.creatorLogo | pipePublicURL \" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData.content.sourceName + '_' + widgetData.content.identifier)\" />\n </div>\n <!-- <span class=\"org-text\">{{'cardcontentv2.by' | translate}} -->\n <span class=\"org-text\">By {{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ? widgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}</span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon class=\"mr-1\">star</mat-icon>\n <span>{{widgetData.content.avgRating}}</span>\n </div>\n <!-- <span class=\"most-enrolled-text margin-left-m\">{{ 'cardcontentv2.mostEnrolled' | translate }}</span> -->\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostEnrolled')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostEnrolled' | translate }} -->\n </span>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostTrending')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostTrending' | translate }} -->\n </span>\n </ng-container>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n <ng-container *ngIf=\"isCardFlipped\">\n <div class=\"flex items-center\">\n <!-- <h2 class=\"mat-subheading-2 flex-1 min-w-0 margin-remove-bottom\" i18n>{{'cardcontentv2.reason' | translate}}</h2> -->\n <button mat-icon-button (click)=\"isCardFlipped = false\">\n <mat-icon>close</mat-icon>\n </button>\n </div>\n <p class=\"text-justify mat-body-1\">\n {{ widgetData.content.reason }}\n </p>\n </ng-container>\n </a>\n </ng-container>\n </div>\n</mat-card>\n</ng-container>\n\n<ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove\" >\n <div class=\"display-contents\" >\n <ng-container *ngIf=\"!isCardFlipped\">\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'140px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n <div class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded margin-top-s'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle margin-top-m\">\n <div class=\"\">\n <sb-uic-skeleton-loader [width]=\"'28px'\" [height]=\"'28px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <span class=\"org-text\"> <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader></span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'45px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded margin-top-m'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </div>\n </mat-card>\n</ng-container>\n\n<ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n</ng-template>",
|
|
9176
9176
|
styles: [".course_widget{margin-top:10px}.course_widget .mat-icon{vertical-align:middle;color:#ef951e!important}.course_widget .course_v2{border:1px solid #ef951e;padding:4px 8px;align-items:end;border-radius:16px}.course_widget .main_icon{font-size:16px;width:16px;height:16px}.rating-session mat-icon{font-size:16px;height:16px;width:12px;padding-right:3px;color:#ef951e}.rating-session span{font-size:11px}.rating-session .most-enrolled-text{padding:0 8px;background:#ffea9e;border-radius:4px}.card-standard-container{position:relative;width:245px;min-height:346px;border-radius:8px;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;height:346px;margin:20px 8px}.card-standard-container .progress-bar{width:101%;margin-left:-15px;display:flex;margin-top:0;background:bisque;position:absolute;bottom:0}.card-standard-container ::ng-deep .mat-progress-bar{height:8px!important}.card-standard-container .icon_text{font-size:12px;line-height:16px;text-transform:uppercase}.card-standard-container .course_logo_box{width:38px;height:38px;background:#fff;border-radius:8px;box-sizing:border-box;box-shadow:0 2px 1px -1px rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 1px 3px 0 rgba(0,0,0,.12)}.card-standard-container .course_logo_box img{height:28px;width:28px;padding:5px;display:inline-block}.card-standard-container .course_logo_box p{display:inline-block;vertical-align:top}.card-standard-container .org-text{font-size:12px;font-weight:400;width:75%;padding-left:10px;word-break:break-all;white-space:initial;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical}.card-standard-container .source-div{position:relative;top:100px;background:#fff;z-index:3;border:1px solid #dedfe0;min-width:72px;min-height:72px;max-width:72px;max-height:72px;display:flex;border-radius:8px}.card-standard-container .source-div .source-icon{border-radius:8px;display:block;margin:auto;max-width:58px;max-height:-webkit-fill-available}.card-standard-container mat-card-content{background:#fff}.card-standard-container .card-img{min-width:245px;max-height:140px;min-height:140px;display:block;-o-object-fit:fill;object-fit:fill;border-top-left-radius:8px;border-top-right-radius:8px;width:100%}.card-standard-container .mat-subheading-1{font:600 14px/24px Montserrat}.card-standard-container .complexity{padding-top:70px;display:flex;font-size:14px;line-height:21px;padding-bottom:10px}.card-standard-container .complexity .mode-tag{border-radius:5px;order:2;margin-left:auto;color:#fff;font-size:10px}.card-standard-container .complexity .duration{display:flex;margin-left:auto;order:3;font-weight:700}.card-standard-container .complexity .time-text{margin:0 5px 0 6px;font-weight:700}.card-standard-container .basic{margin:auto 0}.card-standard-container .title-text{word-break:break-all;white-space:initial;margin:8px 0;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-height:48px}.card-standard-container .description-text{position:relative;overflow:hidden;height:42px;white-space:normal;text-overflow:ellipsis}.duration-box{background:#000;position:absolute;border:none;display:flex;align-items:center;padding:4px;border-radius:4px}.duration-box.right-corner{right:4px;bottom:4px}.duration-box .mat-icon{vertical-align:middle;color:#fff!important;height:14px!important;width:14px!important;font-size:14px}.duration-box .duration{font:700 12px/16px Lato;display:inline-block;margin:0;padding:0}.width-238{width:238px!important}.cbp-mark{border-radius:12px 0;opacity:1;background-image:linear-gradient(90deg,rgba(0,0,0,.6) 0,rgba(0,0,0,0) 100%);position:absolute;top:0;padding:8px}.cbp-mark p{opacity:1;background-color:#fff;padding:4px;opacity:1;color:#1b2133;font-family:Lato-Regular;font-size:10px;font-weight:400;font-style:Regular;letter-spacing:.5px;text-align:left;line-height:12px;margin-bottom:0}.cbpwidth{width:340px}.cbp-plan{border-radius:4px;opacity:1;background-color:#1b4ca1;top:4px;left:4px;opacity:1;color:rgba(255,255,255,.95);font-family:Lato-Bold;font-size:12px;font-weight:700;font-style:normal;letter-spacing:.25px;text-align:center;line-height:16px;padding:4px}.cbp-info{opacity:1;color:#fff;font-family:Lato-Regular;font-size:10px;font-weight:400;font-style:normal;letter-spacing:.5px;text-align:left;line-height:12px;padding:2px}.cbp-danger{border-radius:2px;border:1px solid rgba(0,0,0,.08);background-color:#d13924!important;color:#fff!important;opacity:1}.cbp-success{border-radius:2px;border:1px solid #1d8922;background-color:#1d8922!important;color:#fff!important;opacity:1}.cbp-warning{border-radius:2px;border:1px solid #ef951e;background-color:#ef951e!important;color:#fff!important;opacity:1}"]
|
|
9177
9177
|
}] }
|
|
9178
9178
|
];
|
|
@@ -9964,7 +9964,7 @@
|
|
|
9964
9964
|
CardLandscapeComponent.decorators = [
|
|
9965
9965
|
{ type: core.Component, args: [{
|
|
9966
9966
|
selector: 'sb-uic-card-landscape',
|
|
9967
|
-
template: "<ng-container *ngIf=\"!isCardLoading\">\n <a class=\"cursor-pointer\" (click)=\"raiseTelemetry(widgetData?.content);getRedirectUrlData(widgetData?.content); $event.stopPropagation()\" \n role=\"link\" i18n-aria-label>\n <mat-card class=\"card-portrait mr-2 card-portrait-clickable min-height-remove\" [ngClass]=\"widgetData.cardCustomeClass ? widgetData.cardCustomeClass : ''\">\n <div class=\"course_widget portrait_widget flex margin-bottom-xs\">\n <div class=\"flex flex-end flex-middle course_port\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type i18n-title title=\"Content Type\" *ngIf=\"widgetData.content?.primaryCategory\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [useTranslation]=\"false\" [displayContentType]=\"widgetData.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData.content?.primaryCategory\">\n </sb-uic-display-content-type>\n </div>\n </div>\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <div class=\" img-block-portrait position-relative\">\n <img mat-card-image [src]=\"widgetData?.content?.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.identifier]\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.identifier]\n }}\"></ng-container>\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngIf=\"!widgetData?.content?.posterImage\">\n <ng-container *ngIf=\"widgetData?.content?.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.appIcon | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div [id]=\"'m-c-'+ widgetData?.content?.identifier\"\n class=\"portrait-subheading mat-subheading-2 title-text\">\n {{ widgetData?.content?.name }}\n </div>\n <div class=\"flex w-full flex-middle\">\n <div class=\"portrait_course_logo_box margin-right-xs\">\n <img [src]=\"widgetData?.content?.creatorLogo | pipePublicURL \" class=\"source-icon\" loading=\"lazy\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n </div>\n <span class=\"portrait-org-name font-normal mat-caption\">By {{ (widgetData.content.organisation && widgetData.content.organisation[0]) ? widgetData.content.organisation[0] : 'Karmayogi Bharat' }}</span>\n <!-- <span class=\"portrait-org-name font-normal mat-caption\">{{'cardcontentv2.by' | translate}} {{ (widgetData.content.organisation && widgetData.content.organisation[0]) ? widgetData.content.organisation[0] : 'Karmayogi Bharat' }}</span> -->\n </div>\n\n <div class=\"flex flex-middle rating-session margin-top-xs\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon class=\"mr-1\">star</mat-icon>\n <span>{{widgetData.content.avgRating}}</span>\n </div>\n <!-- <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostEnrolled')\">\n <span class=\"most-enrolled-text margin-left-xs\">{{ 'cardcontentv2.mostEnrolled' | translate }}</span>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostTrending')\">\n <span class=\"most-enrolled-text margin-left-xs\">{{ 'cardcontentv2.mostTrending' | translate }}</span>\n </ng-container> -->\n </div>\n </div>\n </div>\n </mat-card>\n </a>\n</ng-container>\n\n<ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n </ng-template>\n\n<ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-portrait mr-2 card-portrait-clickable\" [ngClass]=\"widgetData.cardCustomeClass ? widgetData.cardCustomeClass : ''\">\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'147px'\" [height]=\"'100px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div class=\"portrait-subheading title-text\">\n <sb-uic-skeleton-loader [bindingClass]=\"'flex rounded width-1-1'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'24px'\" [height]=\"'24px'\" [bindingClass]=\"'flex rounded margin-right-xs'\"></sb-uic-skeleton-loader>\n <sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"portrait_widget flex margin-top-xs\">\n <div class=\"flex flex-end flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </div>\n </mat-card>\n</ng-container>",
|
|
9967
|
+
template: "<ng-container *ngIf=\"!isCardLoading\">\n <a class=\"cursor-pointer\" (click)=\"raiseTelemetry(widgetData?.content);getRedirectUrlData(widgetData?.content); $event.stopPropagation()\" \n role=\"link\" i18n-aria-label>\n <mat-card class=\"card-portrait mr-2 card-portrait-clickable min-height-remove\" [ngClass]=\"widgetData.cardCustomeClass ? widgetData.cardCustomeClass : ''\">\n <div class=\"course_widget portrait_widget flex margin-bottom-xs\">\n <div class=\"flex flex-end flex-middle course_port\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type i18n-title title=\"Content Type\" *ngIf=\"widgetData.content?.primaryCategory\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [useTranslation]=\"false\" [displayContentType]=\"widgetData.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData.content?.primaryCategory\">\n </sb-uic-display-content-type>\n </div>\n </div>\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <div class=\" img-block-portrait position-relative\">\n <img mat-card-image [src]=\"widgetData?.content?.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.identifier] && cbPlanMapData[widgetData?.content?.identifier]?.contentStatus < 2\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.identifier]\n }}\"></ng-container>\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngIf=\"!widgetData?.content?.posterImage\">\n <ng-container *ngIf=\"widgetData?.content?.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.appIcon | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div [id]=\"'m-c-'+ widgetData?.content?.identifier\"\n class=\"portrait-subheading mat-subheading-2 title-text\">\n {{ widgetData?.content?.name }}\n </div>\n <div class=\"flex w-full flex-middle\">\n <div class=\"portrait_course_logo_box margin-right-xs\">\n <img [src]=\"widgetData?.content?.creatorLogo | pipePublicURL \" class=\"source-icon\" loading=\"lazy\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n </div>\n <span class=\"portrait-org-name font-normal mat-caption\">By {{ (widgetData.content.organisation && widgetData.content.organisation[0]) ? widgetData.content.organisation[0] : 'Karmayogi Bharat' }}</span>\n <!-- <span class=\"portrait-org-name font-normal mat-caption\">{{'cardcontentv2.by' | translate}} {{ (widgetData.content.organisation && widgetData.content.organisation[0]) ? widgetData.content.organisation[0] : 'Karmayogi Bharat' }}</span> -->\n </div>\n\n <div class=\"flex flex-middle rating-session margin-top-xs\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon class=\"mr-1\">star</mat-icon>\n <span>{{widgetData.content.avgRating}}</span>\n </div>\n <!-- <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostEnrolled')\">\n <span class=\"most-enrolled-text margin-left-xs\">{{ 'cardcontentv2.mostEnrolled' | translate }}</span>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostTrending')\">\n <span class=\"most-enrolled-text margin-left-xs\">{{ 'cardcontentv2.mostTrending' | translate }}</span>\n </ng-container> -->\n </div>\n </div>\n </div>\n </mat-card>\n </a>\n</ng-container>\n\n<ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n </ng-template>\n\n<ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-portrait mr-2 card-portrait-clickable\" [ngClass]=\"widgetData.cardCustomeClass ? widgetData.cardCustomeClass : ''\">\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'147px'\" [height]=\"'100px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div class=\"portrait-subheading title-text\">\n <sb-uic-skeleton-loader [bindingClass]=\"'flex rounded width-1-1'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'24px'\" [height]=\"'24px'\" [bindingClass]=\"'flex rounded margin-right-xs'\"></sb-uic-skeleton-loader>\n <sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"portrait_widget flex margin-top-xs\">\n <div class=\"flex flex-end flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </div>\n </mat-card>\n</ng-container>",
|
|
9968
9968
|
styles: [".card-portrait{border-radius:12px;border:1px solid rgba(0,0,0,.08);opacity:1;width:350px;min-height:154px;padding:16px}.card-portrait .img-block-portrait{line-height:10px}.card-portrait .card-image{border-radius:8px;opacity:1;background-size:100%;width:147px;height:100px}.card-portrait .portrait-subheading{opacity:1;color:rgba(0,0,0,.87);font-weight:700;font-style:normal;letter-spacing:.25px;text-align:left;word-break:break-word;white-space:initial;margin:0 0 8px;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-height:40px}.card-portrait .portrait_course_logo_box img{padding:3px;display:inline-block;width:24px;height:24px;border:1px solid #d6d6d6;border-radius:4px;box-sizing:border-box}.card-portrait span.portrait-org-name{width:75%;word-break:break-all;white-space:initial;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical}.card-portrait .portrait_widget{align-items:center;margin-top:0}.card-portrait .portrait_widget .course_port{border:1px solid #ef951e;padding:4px 8px;align-items:center;border-radius:16px}.card-portrait .portrait_widget .video-icon{opacity:1;color:#ef951e;width:15px;height:15px;font-size:15px}.card-portrait .portrait_widget .portrait-category{color:rgba(0,0,0,.6)!important;font-size:.75rem;opacity:1;font-family:Lato-Regular;font-weight:400;font-style:normal;letter-spacing:.25px;text-align:left;line-height:20px}.card-portrait .progress-wrapper .progress-block{width:60%}.card-portrait .progress-wrapper .progress-block .completed-time{color:#ef951e;display:flex;padding:8px 0}.card-portrait .progress-wrapper .progress-block .completed-time mat-icon{width:1rem;height:1rem;font-size:1rem}.card-portrait .progress-wrapper .progress-block .completed-time span{opacity:1;color:rgba(0,0,0,.87);font-family:Lato-Regular;font-size:.75rem;font-weight:400;font-style:normal;letter-spacing:.25px;text-align:left;line-height:16px}.card-portrait .progress-wrapper .progress-btn .resume-btn{opacity:1;color:#fff;font-family:Lato-Bold;font-size:14px;font-weight:700;font-style:normal;letter-spacing:.5px;text-align:left;line-height:20px;background:#1a4ca1;border-radius:63px;padding:6px 16px;border:none;width:100%;cursor:pointer}.card-portrait .progress-wrapper .progress-btn .resume-btn .textwrap{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:82px}.card-portrait .progress-wrapper .progress-btn .resume-btn:hover{background-color:#253379}.card-portrait .progress-bar-new{color:#ef951e!important;height:10px;border-radius:5px}.card-portrait .rating-session mat-icon{font-size:20px;height:20px;width:20px;color:#ef951e}.card-portrait .rating-session .rating-number{font-size:14px}.card-portrait .rating-session .most-enrolled-text{font-size:10px;font-weight:400;padding:4px;background:#ffea9e;border-radius:4px;line-height:12px}.card-portrait .right-corner-portrait{right:8px;bottom:8px}.card-portrait-clickable{min-height:146px!important}.card-portrait-clickable .right-corner-portrait{right:8px;bottom:8px}.card-portrait-clickable:hover{transform:scale(1.02)}.course_widget{margin-top:10px}.course_widget .mat-icon{vertical-align:middle;color:#ef951e!important}.course_widget .course_v2{border:1px solid #ef951e;padding:4px 8px;align-items:end;border-radius:16px}.course_widget .main_icon{font-size:16px;width:16px;height:16px}.rating-session mat-icon{font-size:16px;height:16px;width:12px;padding-right:3px;color:#ef951e}.rating-session span{font-size:11px}.rating-session .most-enrolled-text{padding:0 8px;background:#ffea9e;border-radius:4px}.duration-box{background:#000;position:absolute;border:none;display:flex;align-items:center;padding:4px;border-radius:4px}.duration-box.right-corner{right:4px;bottom:4px}.duration-box .mat-icon{vertical-align:middle;color:#fff!important;height:14px!important;width:14px!important;font-size:14px}.duration-box .duration{font:700 12px/16px Lato;display:inline-block;margin:0;padding:0}@media only screen and (max-width:768px){.card-portrait{width:calc(100vw - 66px)}.card-wide-v2{min-height:356px}.card-wide-v2 .imageholder img{border-radius:12px 12px 0 0!important}.cbpwidth{width:calc(100vw - 100px)}}.cbp-mark{border-radius:12px 0;opacity:1;background-image:linear-gradient(90deg,rgba(0,0,0,.6) 0,rgba(0,0,0,0) 100%);position:absolute;top:0;padding:8px}.cbp-mark p{opacity:1;background-color:#fff;padding:4px;opacity:1;color:#1b2133;font-family:Lato-Regular;font-size:10px;font-weight:400;font-style:Regular;letter-spacing:.5px;text-align:left;line-height:12px;margin-bottom:0}.cbpwidth{width:340px}.cbp-plan{border-radius:4px;opacity:1;background-color:#1b4ca1;top:4px;left:4px;opacity:1;color:rgba(255,255,255,.95);font-family:Lato-Bold;font-size:12px;font-weight:700;font-style:normal;letter-spacing:.25px;text-align:center;line-height:16px;padding:4px}.cbp-info{opacity:1;color:#fff;font-family:Lato-Regular;font-size:10px;font-weight:400;font-style:normal;letter-spacing:.5px;text-align:left;line-height:12px;padding:2px}.cbp-danger{border-radius:2px;border:1px solid rgba(0,0,0,.08);background-color:#d13924!important;color:#fff!important;opacity:1}.cbp-success{border-radius:2px;border:1px solid #1d8922;background-color:#1d8922!important;color:#fff!important;opacity:1}.cbp-warning{border-radius:2px;border:1px solid #ef951e;background-color:#ef951e!important;color:#fff!important;opacity:1}"]
|
|
9969
9969
|
}] }
|
|
9970
9970
|
];
|
|
@@ -11153,7 +11153,7 @@
|
|
|
11153
11153
|
CardPortraitExtComponent.decorators = [
|
|
11154
11154
|
{ type: core.Component, args: [{
|
|
11155
11155
|
selector: 'sb-uic-card-portrait-ext',
|
|
11156
|
-
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove cursor-pointer {{widgetData?.cardCustomeClass}}\" [ngClass]=\"{\n greyOut:\n widgetData?.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\" (click)=\"(showIntranetContent || !isLiveOrMarkForDeletion) && showSnackbar()\">\n <div class=\"display-contents\" [ngClass]=\"{\n disableClick:\n widgetData?.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\">\n <ng-container *ngIf=\"widgetData?.content\">\n <a (click)=\"getRedirectUrlData(widgetData?.content); $event.stopPropagation()\"\n role=\"link\" i18n-aria-label>\n <ng-container *ngIf=\"!isCardFlipped\">\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Content expired or deleted\" i18n-matTooltip\n matTooltip=\"Content may be expired or deleted\" *ngIf=\"!isLiveOrMarkForDeletion\"></div>\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Intranet content\" i18n-matTooltip\n matTooltip=\"Available only in Company's network\"\n *ngIf=\"widgetData?.intranetMode === 'greyOut' && showIntranetContent\"></div>\n <button *ngIf=\"showFlip\" class=\"detail-button ws-mat-primary-lite-background-op30\" mat-icon-button\n (click)=\"isCardFlipped = true\" aria-label=\"Details\" i18n-aria-label=\"Details | Click to see details\">\n <mat-icon>flip_to_back</mat-icon>\n </button>\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <img mat-card-image [src]=\"widgetData.content.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-container *ngIf=\"!widgetData.content.posterImage\">\n <ng-container *ngIf=\"widgetData.content.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.appIcon \" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n <div class=\"source-div\" style=\"display: none;\">\n <img [src]=\"widgetData?.content.creatorLogo\" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData.content?.contentId)\" />\n </div>\n <ng-container *ngIf=\"widgetData?.content?.cbPlanEndDate\">\n <div class=\"cbp-mark\">\n <span>{{widgetData?.content?.cbPlanEndDate | date: 'd MMM, y'}}</span>\n </div>\n </ng-container>\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.contentId]\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.contentId]\n }}\"></ng-container>\n </ng-container>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end course_v2\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type [useTranslation]=\"false\" i18n-title title=\"Content Type\" *ngIf=\"widgetData.content?.topic\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [displayContentType]=\"widgetData?.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData?.content?.primaryCategory? widgetData?.content?.primaryCategory : 'Course'\">\n \n </sb-uic-display-content-type>\n </div>\n </div>\n <div [id]=\"'m-c-'+ widgetData.content?.contentId\"\n class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n {{ widgetData.content.name }}\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\"course_logo_box\">\n <img [src]=\"widgetData.content.creatorLogo | pipePublicURL \" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData.content.sourceName + '_' + widgetData.content.contentId)\" />\n </div>\n <!-- <span class=\"org-text\">{{'cardcontentv2.by' | translate}} -->\n <span class=\"org-text\">By {{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ? widgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}</span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon class=\"mr-1\">star</mat-icon>\n <span>{{widgetData.content.avgRating}}</span>\n </div>\n <!-- <span class=\"most-enrolled-text margin-left-m\">{{ 'cardcontentv2.mostEnrolled' | translate }}</span> -->\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostEnrolled')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostEnrolled' | translate }} -->\n </span>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostTrending')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostTrending' | translate }} -->\n </span>\n </ng-container>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n <ng-container *ngIf=\"isCardFlipped\">\n <div class=\"flex items-center\">\n <!-- <h2 class=\"mat-subheading-2 flex-1 min-w-0 margin-remove-bottom\" i18n>{{'cardcontentv2.reason' | translate}}</h2> -->\n <button mat-icon-button (click)=\"isCardFlipped = false\">\n <mat-icon>close</mat-icon>\n </button>\n </div>\n <p class=\"text-justify mat-body-1\">\n {{ widgetData.content.reason }}\n </p>\n </ng-container>\n </a>\n </ng-container>\n </div>\n </mat-card>\n </ng-container>\n \n <ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove\" >\n <div class=\"display-contents\" >\n <ng-container *ngIf=\"!isCardFlipped\">\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'140px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n <div class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded margin-top-s'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle margin-top-m\">\n <div class=\"\">\n <sb-uic-skeleton-loader [width]=\"'28px'\" [height]=\"'28px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <span class=\"org-text\"> <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader></span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'45px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded margin-top-m'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </div>\n </mat-card>\n </ng-container>\n \n <ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n </ng-template>",
|
|
11156
|
+
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove cursor-pointer {{widgetData?.cardCustomeClass}}\" [ngClass]=\"{\n greyOut:\n widgetData?.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\" (click)=\"(showIntranetContent || !isLiveOrMarkForDeletion) && showSnackbar()\">\n <div class=\"display-contents\" [ngClass]=\"{\n disableClick:\n widgetData?.deletedMode === 'greyOut' && !isLiveOrMarkForDeletion\n ? true\n : widgetData?.intranetMode === 'greyOut' && showIntranetContent\n }\">\n <ng-container *ngIf=\"widgetData?.content\">\n <a (click)=\"getRedirectUrlData(widgetData?.content); $event.stopPropagation()\"\n role=\"link\" i18n-aria-label>\n <ng-container *ngIf=\"!isCardFlipped\">\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Content expired or deleted\" i18n-matTooltip\n matTooltip=\"Content may be expired or deleted\" *ngIf=\"!isLiveOrMarkForDeletion\"></div>\n <div class=\"status-danger\" role=\"note\" i18n-aria-label aria-label=\"Intranet content\" i18n-matTooltip\n matTooltip=\"Available only in Company's network\"\n *ngIf=\"widgetData?.intranetMode === 'greyOut' && showIntranetContent\"></div>\n <button *ngIf=\"showFlip\" class=\"detail-button ws-mat-primary-lite-background-op30\" mat-icon-button\n (click)=\"isCardFlipped = true\" aria-label=\"Details\" i18n-aria-label=\"Details | Click to see details\">\n <mat-icon>flip_to_back</mat-icon>\n </button>\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <img mat-card-image [src]=\"widgetData.content.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData.content.name\" />\n </ng-container>\n <ng-container *ngIf=\"!widgetData.content.posterImage\">\n <ng-container *ngIf=\"widgetData.content.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.appIcon \" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-img ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n <div class=\"source-div\" style=\"display: none;\">\n <img [src]=\"widgetData?.content.creatorLogo\" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData.content?.contentId)\" />\n </div>\n <ng-container *ngIf=\"widgetData?.content?.cbPlanEndDate\">\n <div class=\"cbp-mark\">\n <span>{{widgetData?.content?.cbPlanEndDate | date: 'd MMM, y'}}</span>\n </div>\n </ng-container>\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.contentId] && cbPlanMapData[widgetData?.content?.identifier]?.contentStatus < 2 \">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.contentId]\n }}\"></ng-container>\n </ng-container>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end course_v2\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type [useTranslation]=\"false\" i18n-title title=\"Content Type\" *ngIf=\"widgetData.content?.topic\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [displayContentType]=\"widgetData?.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData?.content?.primaryCategory? widgetData?.content?.primaryCategory : 'Course'\">\n \n </sb-uic-display-content-type>\n </div>\n </div>\n <div [id]=\"'m-c-'+ widgetData.content?.contentId\"\n class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n {{ widgetData.content.name }}\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\"course_logo_box\">\n <img [src]=\"widgetData.content.creatorLogo | pipePublicURL \" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData.content.sourceName + '_' + widgetData.content.contentId)\" />\n </div>\n <!-- <span class=\"org-text\">{{'cardcontentv2.by' | translate}} -->\n <span class=\"org-text\">By {{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ? widgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}</span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon class=\"mr-1\">star</mat-icon>\n <span>{{widgetData.content.avgRating}}</span>\n </div>\n <!-- <span class=\"most-enrolled-text margin-left-m\">{{ 'cardcontentv2.mostEnrolled' | translate }}</span> -->\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostEnrolled')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostEnrolled' | translate }} -->\n </span>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.additionalTags && widgetData?.content?.additionalTags.includes('mostTrending')\">\n <span class=\"most-enrolled-text margin-left-xs\">\n <!-- {{ 'cardcontentv2.mostTrending' | translate }} -->\n </span>\n </ng-container>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n <ng-container *ngIf=\"isCardFlipped\">\n <div class=\"flex items-center\">\n <!-- <h2 class=\"mat-subheading-2 flex-1 min-w-0 margin-remove-bottom\" i18n>{{'cardcontentv2.reason' | translate}}</h2> -->\n <button mat-icon-button (click)=\"isCardFlipped = false\">\n <mat-icon>close</mat-icon>\n </button>\n </div>\n <p class=\"text-justify mat-body-1\">\n {{ widgetData.content.reason }}\n </p>\n </ng-container>\n </a>\n </ng-container>\n </div>\n </mat-card>\n </ng-container>\n \n <ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove\" >\n <div class=\"display-contents\" >\n <ng-container *ngIf=\"!isCardFlipped\">\n <mat-card-content class=\"min-top\">\n <div style=\"position: relative; z-index: 1;\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'140px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"padding-m\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n <div class=\"mat-subheading-1 title-text ws-mat-text-block-fade-gradient\">\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded margin-top-s'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle margin-top-m\">\n <div class=\"\">\n <sb-uic-skeleton-loader [width]=\"'28px'\" [height]=\"'28px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <span class=\"org-text\"> <sb-uic-skeleton-loader [width]=\"'111px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader></span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-m\">\n <div class=\"flex flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'45px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded margin-top-m'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </div>\n </mat-card>\n </ng-container>\n \n <ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n </ng-template>",
|
|
11157
11157
|
styles: [".course_widget{margin-top:10px}.course_widget .mat-icon{vertical-align:middle;color:#ef951e!important}.course_widget .course_v2{border:1px solid #ef951e;padding:4px 8px;align-items:end;border-radius:16px}.course_widget .main_icon{font-size:16px;width:16px;height:16px}.rating-session mat-icon{font-size:16px;height:16px;width:12px;padding-right:3px;color:#ef951e}.rating-session span{font-size:11px}.rating-session .most-enrolled-text{padding:0 8px;background:#ffea9e;border-radius:4px}.card-standard-container{position:relative;width:245px;min-height:346px;border-radius:8px;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;height:346px;margin:20px 8px}.card-standard-container .progress-bar{width:101%;margin-left:-15px;display:flex;margin-top:0;background:bisque;position:absolute;bottom:0}.card-standard-container ::ng-deep .mat-progress-bar{height:8px!important}.card-standard-container .icon_text{font-size:12px;line-height:16px;text-transform:uppercase}.card-standard-container .course_logo_box{width:38px;height:38px;background:#fff;border-radius:8px;box-sizing:border-box;box-shadow:0 2px 1px -1px rgba(0,0,0,.2),0 1px 1px 0 rgba(0,0,0,.14),0 1px 3px 0 rgba(0,0,0,.12)}.card-standard-container .course_logo_box img{height:28px;width:28px;padding:5px;display:inline-block}.card-standard-container .course_logo_box p{display:inline-block;vertical-align:top}.card-standard-container .org-text{font-size:12px;font-weight:400;width:75%;padding-left:10px;word-break:break-all;white-space:initial;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical}.card-standard-container .source-div{position:relative;top:100px;background:#fff;z-index:3;border:1px solid #dedfe0;min-width:72px;min-height:72px;max-width:72px;max-height:72px;display:flex;border-radius:8px}.card-standard-container .source-div .source-icon{border-radius:8px;display:block;margin:auto;max-width:58px;max-height:-webkit-fill-available}.card-standard-container mat-card-content{background:#fff}.card-standard-container .card-img{min-width:245px;max-height:140px;min-height:140px;display:block;-o-object-fit:fill;object-fit:fill;border-top-left-radius:8px;border-top-right-radius:8px;width:100%}.card-standard-container .mat-subheading-1{font:600 14px/24px Montserrat}.card-standard-container .complexity{padding-top:70px;display:flex;font-size:14px;line-height:21px;padding-bottom:10px}.card-standard-container .complexity .mode-tag{border-radius:5px;order:2;margin-left:auto;color:#fff;font-size:10px}.card-standard-container .complexity .duration{display:flex;margin-left:auto;order:3;font-weight:700}.card-standard-container .complexity .time-text{margin:0 5px 0 6px;font-weight:700}.card-standard-container .basic{margin:auto 0}.card-standard-container .title-text{word-break:break-all;white-space:initial;margin:8px 0;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-height:48px}.card-standard-container .description-text{position:relative;overflow:hidden;height:42px;white-space:normal;text-overflow:ellipsis}.duration-box{background:#000;position:absolute;border:none;display:flex;align-items:center;padding:4px;border-radius:4px}.duration-box.right-corner{right:4px;bottom:4px}.duration-box .mat-icon{vertical-align:middle;color:#fff!important;height:14px!important;width:14px!important;font-size:14px}.duration-box .duration{font:700 12px/16px Lato;display:inline-block;margin:0;padding:0}.width-238{width:238px!important}.cbp-mark{border-radius:12px 0;opacity:1;background-image:linear-gradient(90deg,rgba(0,0,0,.6) 0,rgba(0,0,0,0) 100%);position:absolute;top:0;padding:8px}.cbp-mark p{opacity:1;background-color:#fff;padding:4px;opacity:1;color:#1b2133;font-family:Lato-Regular;font-size:10px;font-weight:400;font-style:Regular;letter-spacing:.5px;text-align:left;line-height:12px;margin-bottom:0}.cbpwidth{width:340px}.cbp-plan{border-radius:4px;opacity:1;background-color:#1b4ca1;top:4px;left:4px;opacity:1;color:rgba(255,255,255,.95);font-family:Lato-Bold;font-size:12px;font-weight:700;font-style:normal;letter-spacing:.25px;text-align:center;line-height:16px;padding:4px}.cbp-info{opacity:1;color:#fff;font-family:Lato-Regular;font-size:10px;font-weight:400;font-style:normal;letter-spacing:.5px;text-align:left;line-height:12px;padding:2px}.cbp-danger{border-radius:2px;border:1px solid rgba(0,0,0,.08);background-color:#d13924!important;color:#fff!important;opacity:1}.cbp-success{border-radius:2px;border:1px solid #1d8922;background-color:#1d8922!important;color:#fff!important;opacity:1}.cbp-warning{border-radius:2px;border:1px solid #ef951e;background-color:#ef951e!important;color:#fff!important;opacity:1}"]
|
|
11158
11158
|
}] }
|
|
11159
11159
|
];
|
|
@@ -11249,6 +11249,7 @@
|
|
|
11249
11249
|
this.activeResource = [];
|
|
11250
11250
|
this.daysRemaining = 0;
|
|
11251
11251
|
this.daysPending = false;
|
|
11252
|
+
this.daysFinish = false;
|
|
11252
11253
|
}
|
|
11253
11254
|
/**
|
|
11254
11255
|
* @return {?}
|
|
@@ -11261,65 +11262,69 @@
|
|
|
11261
11262
|
var instanceConfig = this.configSvc.instanceConfig;
|
|
11262
11263
|
if (instanceConfig) {
|
|
11263
11264
|
this.defaultThumbnail = instanceConfig.logos.defaultContent || '';
|
|
11264
|
-
this.defaultSLogo = instanceConfig.logos.defaultSourceLogo || '
|
|
11265
|
-
}
|
|
11266
|
-
else {
|
|
11267
|
-
this.defaultThumbnail = '/assets/instances/eagle/app_logos/default.png';
|
|
11268
|
-
this.defaultSLogo = '/assets/instances/eagle/app_logos/KarmayogiBharat_Logo.svg';
|
|
11265
|
+
this.defaultSLogo = instanceConfig.logos.defaultSourceLogo || '';
|
|
11269
11266
|
}
|
|
11267
|
+
// console.log( this.daysPending, " this.daysPending===")
|
|
11270
11268
|
};
|
|
11269
|
+
// updateStartDate(data: any ):void {
|
|
11270
|
+
// // this.startDate = startDate;
|
|
11271
|
+
// this.startCountdown(data)
|
|
11272
|
+
// }
|
|
11273
|
+
// updateStartDate(data: any ):void {
|
|
11274
|
+
// // this.startDate = startDate;
|
|
11275
|
+
// this.startCountdown(data)
|
|
11276
|
+
// }
|
|
11271
11277
|
/**
|
|
11272
|
-
* @param {?}
|
|
11273
|
-
* @return {?}
|
|
11274
|
-
*/
|
|
11275
|
-
CardAssessmentComponent.prototype.updateStartDate = /**
|
|
11276
|
-
* @param {?} startDate
|
|
11278
|
+
* @param {?} data
|
|
11277
11279
|
* @return {?}
|
|
11278
11280
|
*/
|
|
11279
|
-
|
|
11280
|
-
|
|
11281
|
-
|
|
11282
|
-
|
|
11281
|
+
CardAssessmentComponent.prototype.startCountdown =
|
|
11282
|
+
// updateStartDate(data: any ):void {
|
|
11283
|
+
// // this.startDate = startDate;
|
|
11284
|
+
// this.startCountdown(data)
|
|
11285
|
+
// }
|
|
11283
11286
|
/**
|
|
11284
|
-
* @param {?}
|
|
11285
|
-
* @return {?}
|
|
11286
|
-
*/
|
|
11287
|
-
CardAssessmentComponent.prototype.startCountdown = /**
|
|
11288
|
-
* @param {?} date
|
|
11287
|
+
* @param {?} data
|
|
11289
11288
|
* @return {?}
|
|
11290
11289
|
*/
|
|
11291
|
-
function (
|
|
11290
|
+
function (data) {
|
|
11292
11291
|
var _this = this;
|
|
11293
|
-
|
|
11294
|
-
this.updateCountdown(date);
|
|
11292
|
+
this.updateCountdown(data.startDate, data.endDate);
|
|
11295
11293
|
// Update the countdown every second
|
|
11296
11294
|
this.intervalId = setInterval((/**
|
|
11297
11295
|
* @return {?}
|
|
11298
11296
|
*/
|
|
11299
11297
|
function () {
|
|
11300
|
-
_this.updateCountdown(
|
|
11298
|
+
_this.updateCountdown(data.startDate, data.endDate);
|
|
11301
11299
|
}), 1000);
|
|
11302
11300
|
};
|
|
11303
11301
|
// Method to update the countdown values
|
|
11304
11302
|
// Method to update the countdown values
|
|
11305
11303
|
/**
|
|
11306
|
-
* @param {?}
|
|
11304
|
+
* @param {?} startDate
|
|
11305
|
+
* @param {?} endDate
|
|
11307
11306
|
* @return {?}
|
|
11308
11307
|
*/
|
|
11309
11308
|
CardAssessmentComponent.prototype.updateCountdown =
|
|
11310
11309
|
// Method to update the countdown values
|
|
11311
11310
|
/**
|
|
11312
|
-
* @param {?}
|
|
11311
|
+
* @param {?} startDate
|
|
11312
|
+
* @param {?} endDate
|
|
11313
11313
|
* @return {?}
|
|
11314
11314
|
*/
|
|
11315
|
-
function (
|
|
11315
|
+
function (startDate, endDate) {
|
|
11316
11316
|
/** @type {?} */
|
|
11317
11317
|
var now = new Date().getTime();
|
|
11318
11318
|
// Current time in milliseconds
|
|
11319
11319
|
/** @type {?} */
|
|
11320
|
-
var targetTime = new Date(
|
|
11320
|
+
var targetTime = new Date(startDate).getTime();
|
|
11321
|
+
/** @type {?} */
|
|
11322
|
+
var targetEndDate = new Date(endDate).getTime();
|
|
11321
11323
|
/** @type {?} */
|
|
11322
11324
|
var distance = targetTime - now;
|
|
11325
|
+
// Distance in milliseconds
|
|
11326
|
+
/** @type {?} */
|
|
11327
|
+
var endDistance = now - targetEndDate;
|
|
11323
11328
|
if (distance > 0) {
|
|
11324
11329
|
this.daysRemaining = Math.ceil(distance / (1000 * 60 * 60 * 24));
|
|
11325
11330
|
this.daysPending = true;
|
|
@@ -11329,6 +11334,13 @@
|
|
|
11329
11334
|
this.daysPending = false;
|
|
11330
11335
|
this.clearTimer();
|
|
11331
11336
|
}
|
|
11337
|
+
if (endDistance > 0) {
|
|
11338
|
+
this.daysFinish = true;
|
|
11339
|
+
this.clearTimer();
|
|
11340
|
+
}
|
|
11341
|
+
else {
|
|
11342
|
+
this.daysFinish = false;
|
|
11343
|
+
}
|
|
11332
11344
|
};
|
|
11333
11345
|
// Method to clear the interval
|
|
11334
11346
|
// Method to clear the interval
|
|
@@ -11372,8 +11384,8 @@
|
|
|
11372
11384
|
CardAssessmentComponent.decorators = [
|
|
11373
11385
|
{ type: core.Component, args: [{
|
|
11374
11386
|
selector: 'sb-uic-card-assessment',
|
|
11375
|
-
template: "<ng-container *ngIf=\"!isCardLoading\">\n<ng-container >\n\t<mat-card class=\"card-assessment card-scheduled-assessment card-users-container padding-remove cursor-pointer mr-4\">\n\t<a (click)=\"getRedirectUrlData(widgetData?.content); $event.stopPropagation()\">\n\t\t<div class=\"display-contents\">\n\t\t\t<ng-container *ngIf=\"widgetData\">\n\t\t\t\t<mat-card-content>\n\t\t\t\t\t<div class=\"flex flex-col h-full\">\n\t\t\t\t\t\t<div class=\"flex flex-1 flex-row padding-s\">\n\t\t\t\t\t\t\t<div class=\"flex image-container\">\n\t\t\t\t\t\t\t\t<ng-container *ngIf=\"widgetData?.content?.posterImage\">\n\t\t\t\t\t\t\t\t\t<img mat-card-image class=\"margin-remove assess-img\" [src]=\"widgetData?.content?.posterImage | pipePublicURL\"\n\t\t\t\t\t\t\t\t\t\t[alt]=\"widgetData?.content?.name\">\n\t\t\t\t\t\t\t\t</ng-container>\n\t\t\t\t\t\t\t\t<ng-container *ngIf=\"!widgetData?.content?.posterImage\">\n\t\t\t\t\t\t\t\t\t<ng-template #defaultImg>\n\t\t\t\t\t\t\t\t\t\t<img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n\t\t\t\t\t\t\t\t\t\t\tclass=\"card-wide-img ws-mat-primary-lite-background margin-remove assess-img\"\n\t\t\t\t\t\t\t\t\t\t\t[alt]=\"widgetData?.content?.name\" />\n\t\t\t\t\t\t\t\t\t</ng-template>\n\t\t\t\t\t\t\t\t</ng-container>\n\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"flex title-container flex-col\">\n\t\t\t\t\t\t\t\t<div class=\"flex title-text mat-subheading-1\">\n\t\t\t\t\t\t\t\t\t{{ widgetData?.content?.name }}\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class=\"flex margin-remove margin-top-s font-normal mat-caption sub-title-text\">\n\t\t\t\t\t\t\t\t\t<div class=\"course_logo_box\">\n\t\t\t\t\t\t\t\t\t\t<img [src]=\"widgetData?.content?.creatorLogo | pipePublicURL \" class=\"source-icon\"\n\t\t\t\t\t\t\t\t\t\t\t[wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n\t\t\t\t\t\t\t\t\t\t\t[alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<span class=\"sub-title-text\">\n\t\t\t\t\t\t\t\t\t\t{{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ?\n\t\t\t\t\t\t\t\t\t\twidgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<span class=\"start-span\">Assessment starts in </span>\n\t\t\t\t\t\t<mat-card-footer class=\"assessment-card-footer padding-m\">\n\t\t\t\t\t\t\t<div class=\"flex flex-1 items-center justify-center col-row margin-top-m\">\n\t\t\t\t\t\t\t\t<div class=\"flex margin-right-m\">\n\t\t\t\t\t\t\t\t\t<span *ngIf=\"daysPending\"> {{ startCountdown(widgetData?.content?.batch?.startDate) }}<div id=\"demo\"></div> </span>\n\t\t\t\t\t\t\t\t\t<span *ngIf=\"!daysPending\" class=\"start-btn\"> Start Assessment
|
|
11376
|
-
styles: [".card-assessment{width:100%;min-height:190px;box-sizing:border-box;min-width:
|
|
11387
|
+
template: "\n<ng-container *ngIf=\"!isCardLoading\">\n\t<ng-container *ngIf=\"!daysFinish\">\n\t<mat-card class=\"card-assessment card-scheduled-assessment card-users-container padding-remove cursor-pointer mr-4\">\n\t<a (click)=\"getRedirectUrlData(widgetData?.content); $event.stopPropagation()\">\n\t\t<div class=\"display-contents\">\n\t\t\t<ng-container *ngIf=\"widgetData\">\n\t\t\t\t<mat-card-content>\n\t\t\t\t\t<div class=\"flex flex-col h-full\">\n\t\t\t\t\t\t<div class=\"flex flex-1 flex-row padding-s\">\n\t\t\t\t\t\t\t<div class=\"flex image-container\">\n\t\t\t\t\t\t\t\t<ng-container *ngIf=\"widgetData?.content?.posterImage\">\n\t\t\t\t\t\t\t\t\t<img mat-card-image class=\"margin-remove assess-img\" [src]=\"widgetData?.content?.posterImage | pipePublicURL\"\n\t\t\t\t\t\t\t\t\t\t[alt]=\"widgetData?.content?.name\">\n\t\t\t\t\t\t\t\t</ng-container>\n\t\t\t\t\t\t\t\t<ng-container *ngIf=\"!widgetData?.content?.posterImage\">\n\t\t\t\t\t\t\t\t\t<ng-template #defaultImg>\n\t\t\t\t\t\t\t\t\t\t<img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n\t\t\t\t\t\t\t\t\t\t\tclass=\"card-wide-img ws-mat-primary-lite-background margin-remove assess-img\"\n\t\t\t\t\t\t\t\t\t\t\t[alt]=\"widgetData?.content?.name\" />\n\t\t\t\t\t\t\t\t\t</ng-template>\n\t\t\t\t\t\t\t\t</ng-container>\n\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<div class=\"flex title-container flex-col\">\n\t\t\t\t\t\t\t\t<div class=\"flex title-text mat-subheading-1\">\n\t\t\t\t\t\t\t\t\t{{ widgetData?.content?.name }}\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class=\"flex margin-remove margin-top-s font-normal mat-caption sub-title-text\">\n\t\t\t\t\t\t\t\t\t<div class=\"course_logo_box\">\n\t\t\t\t\t\t\t\t\t\t<img [src]=\"widgetData?.content?.creatorLogo | pipePublicURL \" class=\"source-icon\"\n\t\t\t\t\t\t\t\t\t\t\t[wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n\t\t\t\t\t\t\t\t\t\t\t[alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<span class=\"sub-title-text\">\n\t\t\t\t\t\t\t\t\t\t{{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ?\n\t\t\t\t\t\t\t\t\t\twidgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<span class=\"start-span\">Assessment starts in </span>\n\t\t\t\t\t\t<mat-card-footer class=\"assessment-card-footer padding-m\">\n\t\t\t\t\t\t\t<div class=\"flex flex-1 items-center justify-center col-row margin-top-m\">\n\t\t\t\t\t\t\t\t<div class=\"flex margin-right-m\">\n\t\t\t\t\t\t\t\t\t<span *ngIf=\"daysPending\"> {{ startCountdown(widgetData?.content?.batch?.startDate) }}<div id=\"demo\"></div> </span>\n\t\t\t\t\t\t\t\t\t<span *ngIf=\"!daysPending\" class=\"start-btn\"> Start Assessment </span>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class=\"flex\">\n\t\t\t\t\t\t\t\t\t<span class=\"time-span flex items-center justify-center\">{{widgetData?.content?.batch?.startDate | date: 'd MMM, y' }}</span>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</mat-card-footer>\n\t\t\t\t\t</div>\n\t\t\t\t</mat-card-content>\n\t\t\t</ng-container>\n\t\t</div>\n\t</a>\n</mat-card>\n</ng-container>\n</ng-container>\n\n\n\n<ng-container *ngIf=\"isCardLoading\">\n\t<ng-container [ngTemplateOutlet]=\"skeltonLoader\"></ng-container>\n</ng-container>\n\n<ng-template #skeltonLoader>\n\n\t<mat-card class=\"card-assessment card-scheduled-assessment card-users-container padding-remove cursor-pointer mr-4\">\n\t\t<a>\n\t\t\t<div class=\"display-contents\">\n\t\t\t\t<ng-container>\n\t\t\t\t\t<mat-card-content>\n\t\t\t\t\t\t<div class=\"flex flex-col h-full\">\n\t\t\t\t\t\t\t<div class=\"flex flex-1 flex-row padding-s\">\n\t\t\t\t\t\t\t\t<div class=\"flex image-container\">\n\t\t\t\t\t\t\t\t\t<ng-container>\n\t\t\t\t\t\t\t\t\t\t<sb-uic-skeleton-loader [width]=\"'300px'\" [height]=\"'155px'\"\n\t\t\t\t\t\t\t\t\t\t\t></sb-uic-skeleton-loader>\n\t\t\t\t\t\t\t\t\t</ng-container>\n\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class=\"flex title-container flex-col margin-top-m\">\n\t\t\t\t\t\t\t\t\t<div class=\"flex\">\n\t\t\t\t\t\t\t\t\t\t<sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'16px'\"\n\t\t\t\t\t\t\t\t\t\t\t[bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t<div class=\"flex margin-remove margin-top-l font-normal\">\n\t\t\t\t\t\t\t\t\t\t<sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'16px'\"\n\t\t\t\t\t\t\t\t\t\t\t[bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<!-- <span class=\"text-center\"><sb-uic-skeleton-loader [width]=\"'90px'\" [height]=\"'16px'\"\n\t\t\t\t\t\t\t\t\t[bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader> </span> -->\n\t\t\t\t\t\t\t<mat-card-footer\n\t\t\t\t\t\t\t\tclass=\"assessment-card-footer col-row padding-l\">\n\t\t\t\t\t\t\t\t<div class=\"flex flex-1 items-center justify-center col-row margin-top-m\">\n\t\t\t\t\t\t\t\t<div class=\"flex margin-right-m\">\n\t\t\t\t\t\t\t\t\t<sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'16px'\"\n\t\t\t\t\t\t\t\t\t\t[bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class=\"flex\">\n\t\t\t\t\t\t\t\t\t<sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'16px'\"\n\t\t\t\t\t\t\t\t\t\t[bindingClass]=\"'flex rounded br-8'\"></sb-uic-skeleton-loader>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t</mat-card-footer>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</mat-card-content>\n\t\t\t\t</ng-container>\n\t\t\t</div>\n\t\t</a>\n\t</mat-card>\n</ng-template>\n\n",
|
|
11388
|
+
styles: [".card-assessment{width:100%;min-height:190px;box-sizing:border-box;min-width:340px;margin-top:16px;margin-right:12px;border-radius:12px}.image-container{width:145px;height:120px;border-radius:8px;overflow:hidden;border:1px solid rgba(0,0,0,.08)}.image-container img{border-radius:8px;opacity:1;background-size:100%;width:145px!important;height:120px!important;display:flex}.title-container{width:155px;margin-left:12px}.title-text{word-break:break-word;white-space:initial;margin:8px 0;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;max-height:48px;font:600 14px/24px Montserrat}.sub-title-text{width:75%;word-break:break-word;white-space:initial;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.course_logo_box{width:38px;height:38px;background:#fff;border-radius:8px;box-sizing:border-box;margin-right:4px;box-shadow:0 2px 1px -1px rgb(0 0 0 / 20%),0 1px 1px 0 rgb(0 0 0 / 14%),0 1px 3px 0 rgb(0 0 0 / 12%)}.course_logo_box img.source-icon{height:28px;width:28px;padding:5px;display:inline-block}.mat-card-footer{margin:0!important}.time-span{padding:2px 8px;color:#fff;border-radius:4px;text-align:center;font-size:12px;background-color:green;width:75px}span.start-span{border-radius:50px;border:2px solid rgba(0,0,0,.08);font-size:12px;text-align:center;position:absolute;bottom:0;width:140px;left:50%;margin-left:-70px;background-color:#fff;margin-bottom:62px;margin-right:8px}.assessment-card-footer{background:rgba(239,149,30,.16)!important;text-align:center;box-sizing:border-box;border-radius:0 0 8px 8px}.start-btn{background:#1b4ca1!important;color:#fff;font-size:14px;font-weight:600;border-radius:25px;text-align:center;padding:4px 12px}.dots-container{display:none}"]
|
|
11377
11389
|
}] }
|
|
11378
11390
|
];
|
|
11379
11391
|
/** @nocollapse */
|
|
@@ -11413,7 +11425,11 @@
|
|
|
11413
11425
|
/** @type {?} */
|
|
11414
11426
|
CardAssessmentComponent.prototype.startDate;
|
|
11415
11427
|
/** @type {?} */
|
|
11428
|
+
CardAssessmentComponent.prototype.endDate;
|
|
11429
|
+
/** @type {?} */
|
|
11416
11430
|
CardAssessmentComponent.prototype.daysPending;
|
|
11431
|
+
/** @type {?} */
|
|
11432
|
+
CardAssessmentComponent.prototype.daysFinish;
|
|
11417
11433
|
/**
|
|
11418
11434
|
* @type {?}
|
|
11419
11435
|
* @private
|
|
@@ -11902,7 +11918,7 @@
|
|
|
11902
11918
|
CardProgressPortraitLibComponent.decorators = [
|
|
11903
11919
|
{ type: core.Component, args: [{
|
|
11904
11920
|
selector: 'sb-uic-card-progress-portrait-lib',
|
|
11905
|
-
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-portrait card-progress-portrait-lib cursor-pointer\" [ngClass]=\"widgetData?.cardCustomeClass ? widgetData?.cardCustomeClass : ''\" (click)=\"raiseTelemetry();getRedirectUrlData(widgetData?.content); $event.stopPropagation()\" >\n <div class=\"course_widget portrait_widget flex margin-bottom-xs\">\n <div class=\"flex flex-end flex-middle course_port\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type i18n-title title=\"Content Type\" *ngIf=\"widgetData?.content?.primaryCategory\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [displayContentType]=\"widgetData?.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData?.content?.primaryCategory\">\n </sb-uic-display-content-type>\n </div>\n </div>\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <div class=\" img-block-portrait position-relative\">\n <img mat-card-image [src]=\"widgetData?.content?.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\" />\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.identifier]\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.identifier]\n }}\"></ng-container>\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngIf=\"!widgetData?.content?.posterImage\">\n <ng-container *ngIf=\"widgetData?.content?.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData?.content?.appIcon | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div [id]=\"'m-c-'+ widgetData?.content?.identifier\"\n class=\"portrait-subheading mat-subheading-2 title-text\">\n {{ widgetData?.content?.name }}\n </div>\n <div class=\"flex w-full flex-middle\">\n <div class=\"portrait_course_logo_box margin-right-xs\">\n <img [src]=\"widgetData?.content?.creatorLogo | pipePublicURL \" class=\"source-icon\" loading=\"lazy\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n </div>\n <span class=\"portrait-org-name font-normal mat-caption\">{{'cardcontentv2.by' | translate}} {{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ? widgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}</span>\n </div>\n\n </div>\n </div>\n <ng-container *ngIf=\"widgetData?.content?.completionPercentage < 100\">\n <div class=\"flex flex-align-end progress-wrapper flex-between\" >\n <div class=\"progress-block\" >\n <div class=\"completed-time\">\n <mat-icon class=\"mat-icon schedule margin-right-xs\">schedule</mat-icon>\n <span>{{widgetData?.content?.completionPercentage}}%</span>\n </div>\n <div>\n <ng-container *ngIf=\"widgetData?.content?.completionStatus < 2\">\n <sb-uic-content-progress class=\"progress-bar-new\" [customClassName]=\"'course-progress-bar'\" *ngIf=\"widgetData?.content?.identifier\"\n [contentId]=\"widgetData?.content?.identifier\" [progress]=\"widgetData?.content?.completionPercentage\"\n [progressType]=\"'percentage'\">\n </sb-uic-content-progress>\n </ng-container>\n </div>\n </div>\n <div class=\"progress-btn\">\n <button class=\"resume-btn flex flex-middle flex-between\" [routerLink]=\"['/app/toc/',widgetData?.content?.identifier,'overview']\"\n [queryParams]=\"{primaryCategory: widgetData?.content?.primaryCategory}\" [state]=\"widgetData?.stateData\" \n [matTooltipPosition]=\"'below'\"\n [matTooltipDisabled]=\"(!widgetData?.content?.completionPercentage ? translateLabels('start', 'cardcontentv2') : translateLabels('resume', 'cardcontentv2')).length < 11\"\n matTooltip=\"{{!widgetData?.content?.completionPercentage ? translateLabels('start', 'cardcontentv2') : translateLabels('resume', 'cardcontentv2')}}\">\n <span class=\"textwrap margin-right-xs\">\n {{!widgetData?.content?.completionPercentage ? translateLabels('start', 'cardcontentv2') : translateLabels('resume', 'cardcontentv2')}}</span>\n <img class=\"stats-icon\" height=\"20\" width=\"20\" src=\"/assets/icons/home/play.svg\">\n </button>\n </div>\n </div>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.completionPercentage === 100\">\n <div class=\"flex flex-align-end progress-wrapper flex-end mt-1\">\n <div class=\"progress-btn\">\n <button class=\"resume-btn flex flex-middle flex-between view-btn\" [ngClass]=\"{'disable-btn': downloadCertificateLoading || widgetData?.content?.issuedCertificates?.length === 0}\" (click)=\"!downloadCertificateLoading && downloadCertificate(widgetData?.content);$event.stopPropagation()\" \n [matTooltipPosition]=\"'below'\"\n [matTooltipDisabled]=\"(translateLabels('viewCertificate', 'cardcontentv2')).length < 11\"\n matTooltip=\"{{'cardcontentv2.viewCertificate' | translate }}\">\n <span class=\"margin-right-xs textwrap\">{{'cardcontentv2.viewCertificate' | translate }}</span>\n <img class=\"stats-icon\" *ngIf=\"!downloadCertificateLoading\" height=\"20\" width=\"20\" src=\"/assets/icons/home/eye-white.svg\">\n <div class=\"center flex flex-middle\" *ngIf=\"downloadCertificateLoading\">\n <mat-spinner strokeWidth=\"2\" stroke=\"'red'\" class=\"white-spinner\" [diameter]=\"16\"></mat-spinner>\n </div>\n </button>\n </div>\n </div>\n </ng-container>\n </mat-card>\n</ng-container>\n\n\n<ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n</ng-template>\n\n<ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-portrait\" [ngClass]=\"widgetData.cardCustomeClass ? widgetData.cardCustomeClass : ''\">\n <div class=\"margin-bottom-xs\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'147px'\" [height]=\"'26px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'147px'\" [height]=\"'98px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div class=\"portrait-subheading title-text\">\n <sb-uic-skeleton-loader [bindingClass]=\"'flex rounded width-1-1'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\" margin-right-xs\">\n <sb-uic-skeleton-loader [width]=\"'24px'\" [height]=\"'24px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <span class=\"\"><sb-uic-skeleton-loader [width]=\"'133px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader></span>\n </div>\n <div class=\"portrait_widget flex margin-top-xs\">\n <div class=\"flex flex-end flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </div>\n <div class=\"flex flex-align-end progress-wrapper flex-between\">\n <div class=\"progress-block\">\n <div class=\"completed-time\">\n <sb-uic-skeleton-loader [width]=\"'211px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded margin-top-xs md:w-211'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n <div class=\"progress-btn\">\n <sb-uic-skeleton-loader [width]=\"'117px'\" [height]=\"'32px'\" [bindingClass]=\"'flex rounded margin-top-xs'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </mat-card>\n</ng-container>",
|
|
11921
|
+
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-portrait card-progress-portrait-lib cursor-pointer\" [ngClass]=\"widgetData?.cardCustomeClass ? widgetData?.cardCustomeClass : ''\" (click)=\"raiseTelemetry();getRedirectUrlData(widgetData?.content); $event.stopPropagation()\" >\n <div class=\"course_widget portrait_widget flex margin-bottom-xs\">\n <div class=\"flex flex-end flex-middle course_port\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <sb-uic-display-content-type i18n-title title=\"Content Type\" *ngIf=\"widgetData?.content?.primaryCategory\"\n class=\"ws-mat-black60-text font-normal mat-caption \" [displayContentType]=\"widgetData?.content?.primaryCategory==='Course Unit'\n ?'Module'\n :widgetData?.content?.primaryCategory\">\n </sb-uic-display-content-type>\n </div>\n </div>\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <div class=\" img-block-portrait position-relative\">\n <img mat-card-image [src]=\"widgetData?.content?.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\" />\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.duration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}\n </span>\n </div>\n <div class=\"duration-box right-corner-portrait\" *ngIf=\"widgetData?.content?.programDuration > 0\">\n <mat-icon class=\"mat-icon main_icon mr-1\">access_time</mat-icon>\n <span class=\" ws-mat-white-text duration\">\n {{widgetData?.content?.programDuration}} {{widgetData?.content?.programDuration === 1 ? 'day' : 'days'}}\n </span>\n </div>\n <ng-container *ngIf=\"cbPlanMapData && cbPlanMapData[widgetData?.content?.identifier] && cbPlanMapData[widgetData?.content?.identifier]?.contentStatus < 2\">\n <ng-container [ngTemplateOutlet]=\"cbpPlan\" [ngTemplateOutletContext]=\"{data: {\n cbpData: cbPlanMapData[widgetData?.content?.identifier]\n }}\"></ng-container>\n </ng-container>\n </div>\n </ng-container>\n <ng-container *ngIf=\"!widgetData?.content?.posterImage\">\n <ng-container *ngIf=\"widgetData?.content?.appIcon; else defaultImg\">\n <img mat-card-image [src]=\"widgetData?.content?.appIcon | pipePublicURL\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-container>\n <ng-template #defaultImg>\n <img mat-card-image [src]=\"defaultThumbnail\" loading=\"lazy\"\n class=\"card-image ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div [id]=\"'m-c-'+ widgetData?.content?.identifier\"\n class=\"portrait-subheading mat-subheading-2 title-text\">\n {{ widgetData?.content?.name }}\n </div>\n <div class=\"flex w-full flex-middle\">\n <div class=\"portrait_course_logo_box margin-right-xs\">\n <img [src]=\"widgetData?.content?.creatorLogo | pipePublicURL \" class=\"source-icon\" loading=\"lazy\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n </div>\n <span class=\"portrait-org-name font-normal mat-caption\">{{'cardcontentv2.by' | translate}} {{ (widgetData?.content?.organisation && widgetData?.content?.organisation[0]) ? widgetData?.content?.organisation[0] : 'Karmayogi Bharat' }}</span>\n </div>\n\n </div>\n </div>\n <ng-container *ngIf=\"widgetData?.content?.completionPercentage < 100\">\n <div class=\"flex flex-align-end progress-wrapper flex-between\" >\n <div class=\"progress-block\" >\n <div class=\"completed-time\">\n <mat-icon class=\"mat-icon schedule margin-right-xs\">schedule</mat-icon>\n <span>{{widgetData?.content?.completionPercentage}}%</span>\n </div>\n <div>\n <ng-container *ngIf=\"widgetData?.content?.completionStatus < 2\">\n <sb-uic-content-progress class=\"progress-bar-new\" [customClassName]=\"'course-progress-bar'\" *ngIf=\"widgetData?.content?.identifier\"\n [contentId]=\"widgetData?.content?.identifier\" [progress]=\"widgetData?.content?.completionPercentage\"\n [progressType]=\"'percentage'\">\n </sb-uic-content-progress>\n </ng-container>\n </div>\n </div>\n <div class=\"progress-btn\">\n <button class=\"resume-btn flex flex-middle flex-between\" [routerLink]=\"['/app/toc/',widgetData?.content?.identifier,'overview']\"\n [queryParams]=\"{primaryCategory: widgetData?.content?.primaryCategory}\" [state]=\"widgetData?.stateData\" \n [matTooltipPosition]=\"'below'\"\n [matTooltipDisabled]=\"(!widgetData?.content?.completionPercentage ? translateLabels('start', 'cardcontentv2') : translateLabels('resume', 'cardcontentv2')).length < 11\"\n matTooltip=\"{{!widgetData?.content?.completionPercentage ? translateLabels('start', 'cardcontentv2') : translateLabels('resume', 'cardcontentv2')}}\">\n <span class=\"textwrap margin-right-xs\">\n {{!widgetData?.content?.completionPercentage ? translateLabels('start', 'cardcontentv2') : translateLabels('resume', 'cardcontentv2')}}</span>\n <img class=\"stats-icon\" height=\"20\" width=\"20\" src=\"/assets/icons/home/play.svg\">\n </button>\n </div>\n </div>\n </ng-container>\n <ng-container *ngIf=\"widgetData?.content?.completionPercentage === 100\">\n <div class=\"flex flex-align-end progress-wrapper flex-end mt-1\">\n <div class=\"progress-btn\">\n <button class=\"resume-btn flex flex-middle flex-between view-btn\" [ngClass]=\"{'disable-btn': downloadCertificateLoading || widgetData?.content?.issuedCertificates?.length === 0}\" (click)=\"!downloadCertificateLoading && downloadCertificate(widgetData?.content);$event.stopPropagation()\" \n [matTooltipPosition]=\"'below'\"\n [matTooltipDisabled]=\"(translateLabels('viewCertificate', 'cardcontentv2')).length < 11\"\n matTooltip=\"{{'cardcontentv2.viewCertificate' | translate }}\">\n <span class=\"margin-right-xs textwrap\">{{'cardcontentv2.viewCertificate' | translate }}</span>\n <img class=\"stats-icon\" *ngIf=\"!downloadCertificateLoading\" height=\"20\" width=\"20\" src=\"/assets/icons/home/eye-white.svg\">\n <div class=\"center flex flex-middle\" *ngIf=\"downloadCertificateLoading\">\n <mat-spinner strokeWidth=\"2\" stroke=\"'red'\" class=\"white-spinner\" [diameter]=\"16\"></mat-spinner>\n </div>\n </button>\n </div>\n </div>\n </ng-container>\n </mat-card>\n</ng-container>\n\n\n<ng-template #cbpPlan let-data=\"data\">\n <div class=\"cbp-mark left-0 border-top-radius\">\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.UPCOMING\" class=\"cbp-warning\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.SUCCESS\" class=\"cbp-success\">{{data.cbpData.endDate | date: 'd MMM, y'}}</p>\n <p *ngIf=\"data.cbpData.planDuration === acbpConstants?.OVERDUE\" class=\"cbp-danger\">{{'OverDue' }}</p>\n </div>\n</ng-template>\n\n<ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-portrait\" [ngClass]=\"widgetData.cardCustomeClass ? widgetData.cardCustomeClass : ''\">\n <div class=\"margin-bottom-xs\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'147px'\" [height]=\"'26px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"flex\">\n <div class=\"margin-right-s\">\n <ng-container>\n <sb-uic-skeleton-loader [width]=\"'147px'\" [height]=\"'98px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </ng-container>\n </div>\n <div class=\"width-1-1\">\n <div class=\"portrait-subheading title-text\">\n <sb-uic-skeleton-loader [bindingClass]=\"'flex rounded width-1-1'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\" margin-right-xs\">\n <sb-uic-skeleton-loader [width]=\"'24px'\" [height]=\"'24px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <span class=\"\"><sb-uic-skeleton-loader [width]=\"'133px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader></span>\n </div>\n <div class=\"portrait_widget flex margin-top-xs\">\n <div class=\"flex flex-end flex-middle\">\n <sb-uic-skeleton-loader [width]=\"'65px'\" [height]=\"'12px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </div>\n <div class=\"flex flex-align-end progress-wrapper flex-between\">\n <div class=\"progress-block\">\n <div class=\"completed-time\">\n <sb-uic-skeleton-loader [width]=\"'211px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded margin-top-xs md:w-211'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n <div class=\"progress-btn\">\n <sb-uic-skeleton-loader [width]=\"'117px'\" [height]=\"'32px'\" [bindingClass]=\"'flex rounded margin-top-xs'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </mat-card>\n</ng-container>",
|
|
11906
11922
|
styles: [".card-portrait{border-radius:12px;border:1px solid rgba(0,0,0,.08);opacity:1;width:318px;min-height:154px;padding:16px}.card-portrait .img-block-portrait{line-height:10px}.card-portrait .card-image{border-radius:8px;opacity:1;background-size:100%;width:147px;height:100px}.card-portrait .portrait-subheading{opacity:1;color:rgba(0,0,0,.87);font-weight:700;font-style:normal;letter-spacing:.25px;text-align:left;word-break:break-word;white-space:initial;margin:0 0 8px;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-height:40px}.card-portrait .portrait_course_logo_box img{padding:3px;display:inline-block;width:24px;height:24px;border:1px solid #d6d6d6;border-radius:4px;box-sizing:border-box}.card-portrait span.portrait-org-name{width:75%;word-break:break-all;white-space:initial;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical}.card-portrait .portrait_widget{align-items:center;margin-top:0}.card-portrait .portrait_widget .course_port{border:1px solid #ef951e;padding:4px 8px;align-items:center;border-radius:16px}.card-portrait .portrait_widget .video-icon{opacity:1;color:#ef951e;width:15px;height:15px;font-size:15px}.card-portrait .portrait_widget .portrait-category{color:rgba(0,0,0,.6)!important;font-size:.75rem;opacity:1;font-family:Lato-Regular;font-weight:400;font-style:normal;letter-spacing:.25px;text-align:left;line-height:20px}.card-portrait .progress-wrapper .progress-block{width:60%}.card-portrait .progress-wrapper .progress-block .completed-time{color:#ef951e;display:flex;padding:8px 0}.card-portrait .progress-wrapper .progress-block .completed-time mat-icon{width:1rem;height:1rem;font-size:1rem}.card-portrait .progress-wrapper .progress-block .completed-time span{opacity:1;color:rgba(0,0,0,.87);font-family:Lato-Regular;font-size:.75rem;font-weight:400;font-style:normal;letter-spacing:.25px;text-align:left;line-height:16px}.card-portrait .progress-wrapper .progress-btn .resume-btn{opacity:1;color:#fff;font-family:Lato-Bold;font-size:14px;font-weight:700;font-style:normal;letter-spacing:.5px;text-align:left;line-height:20px;background:#1a4ca1;border-radius:63px;padding:6px 16px;border:none;width:100%;cursor:pointer}.card-portrait .progress-wrapper .progress-btn .resume-btn .textwrap{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:82px}.card-portrait .progress-wrapper .progress-btn .resume-btn:hover{background-color:#253379}.card-portrait .progress-bar-new{color:#ef951e!important;height:10px;border-radius:5px}.card-portrait .rating-session mat-icon{font-size:20px;height:20px;width:20px;color:#ef951e}.card-portrait .rating-session .rating-number{font-size:14px}.card-portrait .rating-session .most-enrolled-text{font-size:10px;font-weight:400;padding:4px;background:#ffea9e;border-radius:4px;line-height:12px}.card-portrait .right-corner-portrait{right:8px;bottom:8px}.course_widget{margin-top:10px}.course_widget .mat-icon{vertical-align:middle;color:#ef951e!important}.course_widget .course_v2{border:1px solid #ef951e;padding:4px 8px;align-items:end;border-radius:16px}.course_widget .main_icon{font-size:16px;width:16px;height:16px}.rating-session mat-icon{font-size:16px;height:16px;width:12px;padding-right:3px;color:#ef951e}.rating-session span{font-size:11px}.rating-session .most-enrolled-text{padding:0 8px;background:#ffea9e;border-radius:4px}.duration-box{background:#000;position:absolute;border:none;display:flex;align-items:center;padding:4px;border-radius:4px}.duration-box.right-corner{right:4px;bottom:4px}.duration-box .mat-icon{vertical-align:middle;color:#fff!important;height:14px!important;width:14px!important;font-size:14px}.duration-box .duration{font:700 12px/16px Lato;display:inline-block;margin:0;padding:0}"]
|
|
11907
11923
|
}] }
|
|
11908
11924
|
];
|
|
@@ -12593,6 +12609,1944 @@
|
|
|
12593
12609
|
}
|
|
12594
12610
|
];
|
|
12595
12611
|
|
|
12612
|
+
/**
|
|
12613
|
+
* @fileoverview added by tsickle
|
|
12614
|
+
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
12615
|
+
*/
|
|
12616
|
+
/**
|
|
12617
|
+
* @record
|
|
12618
|
+
*/
|
|
12619
|
+
function IStripUnitContentData$1() { }
|
|
12620
|
+
if (false) {
|
|
12621
|
+
/** @type {?} */
|
|
12622
|
+
IStripUnitContentData$1.prototype.key;
|
|
12623
|
+
/** @type {?} */
|
|
12624
|
+
IStripUnitContentData$1.prototype.canHideStrip;
|
|
12625
|
+
/** @type {?|undefined} */
|
|
12626
|
+
IStripUnitContentData$1.prototype.mode;
|
|
12627
|
+
/** @type {?} */
|
|
12628
|
+
IStripUnitContentData$1.prototype.showStrip;
|
|
12629
|
+
/** @type {?} */
|
|
12630
|
+
IStripUnitContentData$1.prototype.disableTranslate;
|
|
12631
|
+
/** @type {?|undefined} */
|
|
12632
|
+
IStripUnitContentData$1.prototype.widgets;
|
|
12633
|
+
/** @type {?} */
|
|
12634
|
+
IStripUnitContentData$1.prototype.stripTitle;
|
|
12635
|
+
/** @type {?|undefined} */
|
|
12636
|
+
IStripUnitContentData$1.prototype.stripTitleLink;
|
|
12637
|
+
/** @type {?|undefined} */
|
|
12638
|
+
IStripUnitContentData$1.prototype.sliderConfig;
|
|
12639
|
+
/** @type {?} */
|
|
12640
|
+
IStripUnitContentData$1.prototype.stripConfig;
|
|
12641
|
+
/** @type {?|undefined} */
|
|
12642
|
+
IStripUnitContentData$1.prototype.tabs;
|
|
12643
|
+
/** @type {?|undefined} */
|
|
12644
|
+
IStripUnitContentData$1.prototype.stripName;
|
|
12645
|
+
/** @type {?|undefined} */
|
|
12646
|
+
IStripUnitContentData$1.prototype.stripLogo;
|
|
12647
|
+
/** @type {?|undefined} */
|
|
12648
|
+
IStripUnitContentData$1.prototype.description;
|
|
12649
|
+
/** @type {?|undefined} */
|
|
12650
|
+
IStripUnitContentData$1.prototype.stripInfo;
|
|
12651
|
+
/** @type {?|undefined} */
|
|
12652
|
+
IStripUnitContentData$1.prototype.noDataWidget;
|
|
12653
|
+
/** @type {?|undefined} */
|
|
12654
|
+
IStripUnitContentData$1.prototype.errorWidget;
|
|
12655
|
+
/** @type {?} */
|
|
12656
|
+
IStripUnitContentData$1.prototype.showOnNoData;
|
|
12657
|
+
/** @type {?} */
|
|
12658
|
+
IStripUnitContentData$1.prototype.showOnLoader;
|
|
12659
|
+
/** @type {?} */
|
|
12660
|
+
IStripUnitContentData$1.prototype.showOnError;
|
|
12661
|
+
/** @type {?|undefined} */
|
|
12662
|
+
IStripUnitContentData$1.prototype.loaderWidgets;
|
|
12663
|
+
/** @type {?|undefined} */
|
|
12664
|
+
IStripUnitContentData$1.prototype.stripBackground;
|
|
12665
|
+
/** @type {?|undefined} */
|
|
12666
|
+
IStripUnitContentData$1.prototype.secondaryHeading;
|
|
12667
|
+
/** @type {?} */
|
|
12668
|
+
IStripUnitContentData$1.prototype.viewMoreUrl;
|
|
12669
|
+
/** @type {?|undefined} */
|
|
12670
|
+
IStripUnitContentData$1.prototype.request;
|
|
12671
|
+
}
|
|
12672
|
+
var ContentStripWithTabsPillsComponent = /** @class */ (function (_super) {
|
|
12673
|
+
__extends(ContentStripWithTabsPillsComponent, _super);
|
|
12674
|
+
function ContentStripWithTabsPillsComponent(
|
|
12675
|
+
// private contentStripSvc: ContentStripNewMultipleService,
|
|
12676
|
+
environment, contentSvc, loggerSvc, eventSvc, configSvc, utilitySvc, router, userSvc, translate, langtranslations) {
|
|
12677
|
+
var _this = _super.call(this) || this;
|
|
12678
|
+
_this.contentSvc = contentSvc;
|
|
12679
|
+
_this.loggerSvc = loggerSvc;
|
|
12680
|
+
_this.eventSvc = eventSvc;
|
|
12681
|
+
_this.configSvc = configSvc;
|
|
12682
|
+
_this.utilitySvc = utilitySvc;
|
|
12683
|
+
_this.router = router;
|
|
12684
|
+
_this.userSvc = userSvc;
|
|
12685
|
+
_this.translate = translate;
|
|
12686
|
+
_this.langtranslations = langtranslations;
|
|
12687
|
+
_this.emptyResponse = new core.EventEmitter();
|
|
12688
|
+
_this.viewAllResponse = new core.EventEmitter();
|
|
12689
|
+
_this.telemtryResponse = new core.EventEmitter();
|
|
12690
|
+
_this.providerId = '';
|
|
12691
|
+
_this.emitViewAll = false;
|
|
12692
|
+
_this.channnelName = '';
|
|
12693
|
+
_this.id = "ws-strip-miltiple_" + Math.random();
|
|
12694
|
+
_this.stripsResultDataMap = {};
|
|
12695
|
+
_this.stripsKeyOrder = [];
|
|
12696
|
+
_this.showAccordionData = true;
|
|
12697
|
+
_this.showParentLoader = false;
|
|
12698
|
+
_this.showParentError = false;
|
|
12699
|
+
_this.showParentNoData = false;
|
|
12700
|
+
_this.errorDataCount = 0;
|
|
12701
|
+
_this.noDataCount = 0;
|
|
12702
|
+
_this.successDataCount = 0;
|
|
12703
|
+
_this.contentAvailable = true;
|
|
12704
|
+
_this.baseUrl = _this.configSvc.sitePath || '';
|
|
12705
|
+
_this.veifiedKarmayogi = false;
|
|
12706
|
+
_this.changeEventSubscription = null;
|
|
12707
|
+
_this.defaultMaxWidgets = 12;
|
|
12708
|
+
_this.todaysEvents = [];
|
|
12709
|
+
if (localStorage.getItem('websiteLanguage')) {
|
|
12710
|
+
_this.translate.setDefaultLang('en');
|
|
12711
|
+
/** @type {?} */
|
|
12712
|
+
var lang = JSON.stringify(localStorage.getItem('websiteLanguage'));
|
|
12713
|
+
lang = lang.replace(/\"/g, '');
|
|
12714
|
+
_this.translate.use(lang);
|
|
12715
|
+
}
|
|
12716
|
+
_this.environment = environment;
|
|
12717
|
+
return _this;
|
|
12718
|
+
}
|
|
12719
|
+
/**
|
|
12720
|
+
* @return {?}
|
|
12721
|
+
*/
|
|
12722
|
+
ContentStripWithTabsPillsComponent.prototype.ngOnInit = /**
|
|
12723
|
+
* @return {?}
|
|
12724
|
+
*/
|
|
12725
|
+
function () {
|
|
12726
|
+
var _this = this;
|
|
12727
|
+
// const url = window.location.href
|
|
12728
|
+
this.initData();
|
|
12729
|
+
this.contentSvc.telemetryData$.subscribe((/**
|
|
12730
|
+
* @param {?} data
|
|
12731
|
+
* @return {?}
|
|
12732
|
+
*/
|
|
12733
|
+
function (data) {
|
|
12734
|
+
_this.telemtryResponse.emit(data);
|
|
12735
|
+
}));
|
|
12736
|
+
};
|
|
12737
|
+
/**
|
|
12738
|
+
* @return {?}
|
|
12739
|
+
*/
|
|
12740
|
+
ContentStripWithTabsPillsComponent.prototype.ngOnDestroy = /**
|
|
12741
|
+
* @return {?}
|
|
12742
|
+
*/
|
|
12743
|
+
function () {
|
|
12744
|
+
if (this.changeEventSubscription) {
|
|
12745
|
+
this.changeEventSubscription.unsubscribe();
|
|
12746
|
+
}
|
|
12747
|
+
};
|
|
12748
|
+
/**
|
|
12749
|
+
* @param {?} key
|
|
12750
|
+
* @return {?}
|
|
12751
|
+
*/
|
|
12752
|
+
ContentStripWithTabsPillsComponent.prototype.showAccordion = /**
|
|
12753
|
+
* @param {?} key
|
|
12754
|
+
* @return {?}
|
|
12755
|
+
*/
|
|
12756
|
+
function (key) {
|
|
12757
|
+
if (this.utilitySvc.isMobile && this.stripsResultDataMap[key].mode === 'accordion') {
|
|
12758
|
+
return this.showAccordionData;
|
|
12759
|
+
}
|
|
12760
|
+
return true;
|
|
12761
|
+
};
|
|
12762
|
+
/**
|
|
12763
|
+
* @param {?} key
|
|
12764
|
+
* @return {?}
|
|
12765
|
+
*/
|
|
12766
|
+
ContentStripWithTabsPillsComponent.prototype.setHiddenForStrip = /**
|
|
12767
|
+
* @param {?} key
|
|
12768
|
+
* @return {?}
|
|
12769
|
+
*/
|
|
12770
|
+
function (key) {
|
|
12771
|
+
this.stripsResultDataMap[key].showStrip = false;
|
|
12772
|
+
sessionStorage.setItem("cstrip_" + key, '1');
|
|
12773
|
+
};
|
|
12774
|
+
/**
|
|
12775
|
+
* @private
|
|
12776
|
+
* @param {?} key
|
|
12777
|
+
* @return {?}
|
|
12778
|
+
*/
|
|
12779
|
+
ContentStripWithTabsPillsComponent.prototype.getIfStripHidden = /**
|
|
12780
|
+
* @private
|
|
12781
|
+
* @param {?} key
|
|
12782
|
+
* @return {?}
|
|
12783
|
+
*/
|
|
12784
|
+
function (key) {
|
|
12785
|
+
/** @type {?} */
|
|
12786
|
+
var storageItem = sessionStorage.getItem("cstrip_" + key);
|
|
12787
|
+
return Boolean(storageItem !== '1');
|
|
12788
|
+
};
|
|
12789
|
+
/**
|
|
12790
|
+
* @private
|
|
12791
|
+
* @return {?}
|
|
12792
|
+
*/
|
|
12793
|
+
ContentStripWithTabsPillsComponent.prototype.initData = /**
|
|
12794
|
+
* @private
|
|
12795
|
+
* @return {?}
|
|
12796
|
+
*/
|
|
12797
|
+
function () {
|
|
12798
|
+
var e_1, _a;
|
|
12799
|
+
var _this = this;
|
|
12800
|
+
this.stripsKeyOrder = this.widgetData && this.widgetData.strips && this.widgetData.strips.map((/**
|
|
12801
|
+
* @param {?} strip
|
|
12802
|
+
* @return {?}
|
|
12803
|
+
*/
|
|
12804
|
+
function (strip) { return strip.key; })) || [];
|
|
12805
|
+
if (this.widgetData.loader && this.widgetData.strips.length) {
|
|
12806
|
+
this.showParentLoader = true;
|
|
12807
|
+
}
|
|
12808
|
+
try {
|
|
12809
|
+
// Fetch the data
|
|
12810
|
+
for (var _b = __values(this.widgetData.strips), _c = _b.next(); !_c.done; _c = _b.next()) {
|
|
12811
|
+
var strip = _c.value;
|
|
12812
|
+
if (this.checkForEmptyWidget(strip)) {
|
|
12813
|
+
this.fetchStripFromRequestData(strip, false);
|
|
12814
|
+
}
|
|
12815
|
+
else {
|
|
12816
|
+
this.processStrip(strip, [], 'done', true, null);
|
|
12817
|
+
}
|
|
12818
|
+
}
|
|
12819
|
+
}
|
|
12820
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
12821
|
+
finally {
|
|
12822
|
+
try {
|
|
12823
|
+
if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
|
|
12824
|
+
}
|
|
12825
|
+
finally { if (e_1) throw e_1.error; }
|
|
12826
|
+
}
|
|
12827
|
+
// Subscription for changes
|
|
12828
|
+
/** @type {?} */
|
|
12829
|
+
var keyAndEvent = this.widgetData.strips
|
|
12830
|
+
.map((/**
|
|
12831
|
+
* @param {?} strip
|
|
12832
|
+
* @return {?}
|
|
12833
|
+
*/
|
|
12834
|
+
function (strip) { return ({
|
|
12835
|
+
key: strip.key,
|
|
12836
|
+
type: (strip.refreshEvent && strip.refreshEvent.eventType) || '',
|
|
12837
|
+
from: (strip.refreshEvent && strip.refreshEvent.from.toString()) || '',
|
|
12838
|
+
}); }))
|
|
12839
|
+
.filter((/**
|
|
12840
|
+
* @param {?} __0
|
|
12841
|
+
* @return {?}
|
|
12842
|
+
*/
|
|
12843
|
+
function (_a) {
|
|
12844
|
+
var key = _a.key, type = _a.type, from = _a.from;
|
|
12845
|
+
return key && type && from;
|
|
12846
|
+
}));
|
|
12847
|
+
/** @type {?} */
|
|
12848
|
+
var eventTypeSet = new Set(keyAndEvent.map((/**
|
|
12849
|
+
* @param {?} e
|
|
12850
|
+
* @return {?}
|
|
12851
|
+
*/
|
|
12852
|
+
function (e) { return e.type; })));
|
|
12853
|
+
this.changeEventSubscription = this.eventSvc.events$
|
|
12854
|
+
.pipe(operators.filter((/**
|
|
12855
|
+
* @param {?} event
|
|
12856
|
+
* @return {?}
|
|
12857
|
+
*/
|
|
12858
|
+
function (event) { return eventTypeSet.has(event.eventType); })))
|
|
12859
|
+
.subscribe((/**
|
|
12860
|
+
* @param {?} event
|
|
12861
|
+
* @return {?}
|
|
12862
|
+
*/
|
|
12863
|
+
function (event) {
|
|
12864
|
+
keyAndEvent
|
|
12865
|
+
.filter((/**
|
|
12866
|
+
* @param {?} e
|
|
12867
|
+
* @return {?}
|
|
12868
|
+
*/
|
|
12869
|
+
function (e) { return e.type === event.eventType && e.from === event.from; }))
|
|
12870
|
+
.map((/**
|
|
12871
|
+
* @param {?} e
|
|
12872
|
+
* @return {?}
|
|
12873
|
+
*/
|
|
12874
|
+
function (e) { return e.key; }))
|
|
12875
|
+
.forEach((/**
|
|
12876
|
+
* @param {?} k
|
|
12877
|
+
* @return {?}
|
|
12878
|
+
*/
|
|
12879
|
+
function (k) { return _this.fetchStripFromKey(k, false); }));
|
|
12880
|
+
}));
|
|
12881
|
+
};
|
|
12882
|
+
/**
|
|
12883
|
+
* @private
|
|
12884
|
+
* @param {?} key
|
|
12885
|
+
* @param {?=} calculateParentStatus
|
|
12886
|
+
* @return {?}
|
|
12887
|
+
*/
|
|
12888
|
+
ContentStripWithTabsPillsComponent.prototype.fetchStripFromKey = /**
|
|
12889
|
+
* @private
|
|
12890
|
+
* @param {?} key
|
|
12891
|
+
* @param {?=} calculateParentStatus
|
|
12892
|
+
* @return {?}
|
|
12893
|
+
*/
|
|
12894
|
+
function (key, calculateParentStatus) {
|
|
12895
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
12896
|
+
/** @type {?} */
|
|
12897
|
+
var stripData = this.widgetData.strips.find((/**
|
|
12898
|
+
* @param {?} strip
|
|
12899
|
+
* @return {?}
|
|
12900
|
+
*/
|
|
12901
|
+
function (strip) { return strip.key === key; }));
|
|
12902
|
+
if (stripData) {
|
|
12903
|
+
this.fetchStripFromRequestData(stripData, calculateParentStatus);
|
|
12904
|
+
}
|
|
12905
|
+
};
|
|
12906
|
+
/**
|
|
12907
|
+
* @param {?} data
|
|
12908
|
+
* @return {?}
|
|
12909
|
+
*/
|
|
12910
|
+
ContentStripWithTabsPillsComponent.prototype.isStripShowing = /**
|
|
12911
|
+
* @param {?} data
|
|
12912
|
+
* @return {?}
|
|
12913
|
+
*/
|
|
12914
|
+
function (data) {
|
|
12915
|
+
var _this = this;
|
|
12916
|
+
/** @type {?} */
|
|
12917
|
+
var count = 0;
|
|
12918
|
+
if (data && data.key === this.environment.programStripKey && (!data.tabs || !data.tabs.length) &&
|
|
12919
|
+
data.stripTitle === this.environment.programStripName && data.widgets.length > 0) {
|
|
12920
|
+
data.widgets.forEach((/**
|
|
12921
|
+
* @param {?} key
|
|
12922
|
+
* @return {?}
|
|
12923
|
+
*/
|
|
12924
|
+
function (key) {
|
|
12925
|
+
if (key && key.widgetData.content.primaryCategory === _this.environment.programStripPrimaryCategory) {
|
|
12926
|
+
count = count + 1;
|
|
12927
|
+
}
|
|
12928
|
+
}));
|
|
12929
|
+
if (count > 0) {
|
|
12930
|
+
data.showStrip = true;
|
|
12931
|
+
}
|
|
12932
|
+
else {
|
|
12933
|
+
data.showStrip = false;
|
|
12934
|
+
}
|
|
12935
|
+
}
|
|
12936
|
+
// console.log('data.key', data, data.key, data.widgets);
|
|
12937
|
+
return data.showStrip;
|
|
12938
|
+
};
|
|
12939
|
+
Object.defineProperty(ContentStripWithTabsPillsComponent.prototype, "isMobile", {
|
|
12940
|
+
get: /**
|
|
12941
|
+
* @return {?}
|
|
12942
|
+
*/
|
|
12943
|
+
function () {
|
|
12944
|
+
return this.utilitySvc.isMobile || false;
|
|
12945
|
+
},
|
|
12946
|
+
enumerable: true,
|
|
12947
|
+
configurable: true
|
|
12948
|
+
});
|
|
12949
|
+
/**
|
|
12950
|
+
* @param {?} data
|
|
12951
|
+
* @return {?}
|
|
12952
|
+
*/
|
|
12953
|
+
ContentStripWithTabsPillsComponent.prototype.getdata = /**
|
|
12954
|
+
* @param {?} data
|
|
12955
|
+
* @return {?}
|
|
12956
|
+
*/
|
|
12957
|
+
function (data) {
|
|
12958
|
+
if (data.stripInfo) {
|
|
12959
|
+
return data.stripInfo.widget;
|
|
12960
|
+
}
|
|
12961
|
+
return {};
|
|
12962
|
+
};
|
|
12963
|
+
/**
|
|
12964
|
+
* @param {?} wData
|
|
12965
|
+
* @param {?} data
|
|
12966
|
+
* @return {?}
|
|
12967
|
+
*/
|
|
12968
|
+
ContentStripWithTabsPillsComponent.prototype.checkCondition = /**
|
|
12969
|
+
* @param {?} wData
|
|
12970
|
+
* @param {?} data
|
|
12971
|
+
* @return {?}
|
|
12972
|
+
*/
|
|
12973
|
+
function (wData, data) {
|
|
12974
|
+
if (wData.strips[0].stripConfig && wData.strips[0].stripConfig.hideShowAll) {
|
|
12975
|
+
return !wData.strips[0].stripConfig.hideShowAll;
|
|
12976
|
+
}
|
|
12977
|
+
return wData.strips[0].viewMoreUrl && data.widgets && data.widgets.length >= 4;
|
|
12978
|
+
};
|
|
12979
|
+
/**
|
|
12980
|
+
* @param {?} data
|
|
12981
|
+
* @return {?}
|
|
12982
|
+
*/
|
|
12983
|
+
ContentStripWithTabsPillsComponent.prototype.checkVisible = /**
|
|
12984
|
+
* @param {?} data
|
|
12985
|
+
* @return {?}
|
|
12986
|
+
*/
|
|
12987
|
+
function (data) {
|
|
12988
|
+
return data.stripInfo && data.stripInfo.visibilityMode === 'visible';
|
|
12989
|
+
};
|
|
12990
|
+
/**
|
|
12991
|
+
* @param {?} data
|
|
12992
|
+
* @return {?}
|
|
12993
|
+
*/
|
|
12994
|
+
ContentStripWithTabsPillsComponent.prototype.getContineuLearningLenth = /**
|
|
12995
|
+
* @param {?} data
|
|
12996
|
+
* @return {?}
|
|
12997
|
+
*/
|
|
12998
|
+
function (data) {
|
|
12999
|
+
return data.widgets ? data.widgets.length : 0;
|
|
13000
|
+
};
|
|
13001
|
+
/**
|
|
13002
|
+
* @param {?} data
|
|
13003
|
+
* @return {?}
|
|
13004
|
+
*/
|
|
13005
|
+
ContentStripWithTabsPillsComponent.prototype.getLength = /**
|
|
13006
|
+
* @param {?} data
|
|
13007
|
+
* @return {?}
|
|
13008
|
+
*/
|
|
13009
|
+
function (data) {
|
|
13010
|
+
if (!data.tabs || !data.tabs.length) {
|
|
13011
|
+
return data.widgets ? data.widgets.length : 0;
|
|
13012
|
+
}
|
|
13013
|
+
{
|
|
13014
|
+
// if tabs are there check if each tab has widgets and get the tab with max widgets
|
|
13015
|
+
/** @type {?} */
|
|
13016
|
+
var tabWithMaxWidgets_1 = {};
|
|
13017
|
+
data.tabs.forEach((/**
|
|
13018
|
+
* @param {?} tab
|
|
13019
|
+
* @return {?}
|
|
13020
|
+
*/
|
|
13021
|
+
function (tab) {
|
|
13022
|
+
if (tab.pillsData && tab.pillsData.length) {
|
|
13023
|
+
tabWithMaxWidgets_1 = tab.pillsData.reduce((/**
|
|
13024
|
+
* @param {?} prev
|
|
13025
|
+
* @param {?} current
|
|
13026
|
+
* @return {?}
|
|
13027
|
+
*/
|
|
13028
|
+
function (prev, current) {
|
|
13029
|
+
if (!prev.widgets && !current.widgets) {
|
|
13030
|
+
return current;
|
|
13031
|
+
}
|
|
13032
|
+
if (prev.widgets && current.widgets) {
|
|
13033
|
+
return (prev.widgets.length > current.widgets.length) ? prev : current;
|
|
13034
|
+
}
|
|
13035
|
+
if (current.widgets && !prev.widgets) {
|
|
13036
|
+
return current;
|
|
13037
|
+
}
|
|
13038
|
+
if (!current.widgets && prev.widgets) {
|
|
13039
|
+
return prev;
|
|
13040
|
+
}
|
|
13041
|
+
return current;
|
|
13042
|
+
// return (prev.widgets && current.widgets && (prev.widgets.length > current.widgets.length) ) ? prev : current
|
|
13043
|
+
// tslint:disable-next-line: align
|
|
13044
|
+
}), data.tabs[0]);
|
|
13045
|
+
}
|
|
13046
|
+
}));
|
|
13047
|
+
// if tabs has atleast 1 widgets then strip will show or else not
|
|
13048
|
+
return tabWithMaxWidgets_1.widgets ? tabWithMaxWidgets_1.widgets.length : 0;
|
|
13049
|
+
}
|
|
13050
|
+
};
|
|
13051
|
+
/**
|
|
13052
|
+
* @private
|
|
13053
|
+
* @param {?} v6filters
|
|
13054
|
+
* @return {?}
|
|
13055
|
+
*/
|
|
13056
|
+
ContentStripWithTabsPillsComponent.prototype.getFiltersFromArray = /**
|
|
13057
|
+
* @private
|
|
13058
|
+
* @param {?} v6filters
|
|
13059
|
+
* @return {?}
|
|
13060
|
+
*/
|
|
13061
|
+
function (v6filters) {
|
|
13062
|
+
/** @type {?} */
|
|
13063
|
+
var filters = {};
|
|
13064
|
+
if (v6filters.constructor === Array) {
|
|
13065
|
+
v6filters.forEach(((/**
|
|
13066
|
+
* @param {?} f
|
|
13067
|
+
* @return {?}
|
|
13068
|
+
*/
|
|
13069
|
+
function (f) {
|
|
13070
|
+
Object.keys(f).forEach((/**
|
|
13071
|
+
* @param {?} key
|
|
13072
|
+
* @return {?}
|
|
13073
|
+
*/
|
|
13074
|
+
function (key) {
|
|
13075
|
+
filters[key] = f[key];
|
|
13076
|
+
}));
|
|
13077
|
+
})));
|
|
13078
|
+
return filters;
|
|
13079
|
+
}
|
|
13080
|
+
return v6filters;
|
|
13081
|
+
};
|
|
13082
|
+
/**
|
|
13083
|
+
* @private
|
|
13084
|
+
* @param {?} v6filters
|
|
13085
|
+
* @return {?}
|
|
13086
|
+
*/
|
|
13087
|
+
ContentStripWithTabsPillsComponent.prototype.transformSearchV6FiltersV2 = /**
|
|
13088
|
+
* @private
|
|
13089
|
+
* @param {?} v6filters
|
|
13090
|
+
* @return {?}
|
|
13091
|
+
*/
|
|
13092
|
+
function (v6filters) {
|
|
13093
|
+
/** @type {?} */
|
|
13094
|
+
var filters = {};
|
|
13095
|
+
if (v6filters.constructor === Array) {
|
|
13096
|
+
v6filters.forEach(((/**
|
|
13097
|
+
* @param {?} f
|
|
13098
|
+
* @return {?}
|
|
13099
|
+
*/
|
|
13100
|
+
function (f) {
|
|
13101
|
+
Object.keys(f).forEach((/**
|
|
13102
|
+
* @param {?} key
|
|
13103
|
+
* @return {?}
|
|
13104
|
+
*/
|
|
13105
|
+
function (key) {
|
|
13106
|
+
filters[key] = f[key];
|
|
13107
|
+
}));
|
|
13108
|
+
})));
|
|
13109
|
+
return filters;
|
|
13110
|
+
}
|
|
13111
|
+
return v6filters;
|
|
13112
|
+
};
|
|
13113
|
+
/**
|
|
13114
|
+
* @param {?} filters
|
|
13115
|
+
* @return {?}
|
|
13116
|
+
*/
|
|
13117
|
+
ContentStripWithTabsPillsComponent.prototype.checkForDateFilters = /**
|
|
13118
|
+
* @param {?} filters
|
|
13119
|
+
* @return {?}
|
|
13120
|
+
*/
|
|
13121
|
+
function (filters) {
|
|
13122
|
+
/** @type {?} */
|
|
13123
|
+
var userData;
|
|
13124
|
+
if (this.configSvc.userProfile) {
|
|
13125
|
+
userData = this.configSvc.userProfile;
|
|
13126
|
+
}
|
|
13127
|
+
if (filters && filters.hasOwnProperty('batches.endDate')) {
|
|
13128
|
+
// tslint:disable-next-line
|
|
13129
|
+
filters['batches.endDate']['>='] = eval(filters['batches.endDate']['>=']);
|
|
13130
|
+
}
|
|
13131
|
+
else if (filters && filters.hasOwnProperty('batches.enrollmentEndDate')) {
|
|
13132
|
+
// tslint:disable-next-line
|
|
13133
|
+
filters['batches.enrollmentEndDate']['>='] = eval(filters['batches.enrollmentEndDate']['>=']);
|
|
13134
|
+
}
|
|
13135
|
+
else if (filters.organisation &&
|
|
13136
|
+
filters.organisation.indexOf('<orgID>') >= 0) {
|
|
13137
|
+
if (this.providerId) {
|
|
13138
|
+
filters.organisation = this.providerId;
|
|
13139
|
+
}
|
|
13140
|
+
else {
|
|
13141
|
+
filters.organisation = userData && userData.rootOrgId;
|
|
13142
|
+
if (filters && filters.hasOwnProperty('designation')) {
|
|
13143
|
+
filters.designation = userData.professionalDetails.length > 0 ?
|
|
13144
|
+
userData.professionalDetails[0].designation : '';
|
|
13145
|
+
}
|
|
13146
|
+
}
|
|
13147
|
+
}
|
|
13148
|
+
return filters;
|
|
13149
|
+
};
|
|
13150
|
+
/**
|
|
13151
|
+
* @private
|
|
13152
|
+
* @param {?} strip
|
|
13153
|
+
* @param {?=} calculateParentStatus
|
|
13154
|
+
* @return {?}
|
|
13155
|
+
*/
|
|
13156
|
+
ContentStripWithTabsPillsComponent.prototype.fetchStripFromRequestData = /**
|
|
13157
|
+
* @private
|
|
13158
|
+
* @param {?} strip
|
|
13159
|
+
* @param {?=} calculateParentStatus
|
|
13160
|
+
* @return {?}
|
|
13161
|
+
*/
|
|
13162
|
+
function (strip, calculateParentStatus) {
|
|
13163
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
13164
|
+
// setting initial values
|
|
13165
|
+
strip.loaderWidgets = this.transformSkeletonToWidgets(strip);
|
|
13166
|
+
this.processStrip(strip, [], 'fetching', false, null);
|
|
13167
|
+
this.fetchFromSearchV6(strip, calculateParentStatus);
|
|
13168
|
+
this.fetchForYouData(strip, calculateParentStatus);
|
|
13169
|
+
this.fetchAllCbpPlans(strip, calculateParentStatus);
|
|
13170
|
+
// this.enrollInterval = setInterval(() => {
|
|
13171
|
+
// this.fetchAllCbpPlans(strip, calculateParentStatus)
|
|
13172
|
+
// }, 1000)
|
|
13173
|
+
};
|
|
13174
|
+
/**
|
|
13175
|
+
* @param {?} data
|
|
13176
|
+
* @return {?}
|
|
13177
|
+
*/
|
|
13178
|
+
ContentStripWithTabsPillsComponent.prototype.toggleInfo = /**
|
|
13179
|
+
* @param {?} data
|
|
13180
|
+
* @return {?}
|
|
13181
|
+
*/
|
|
13182
|
+
function (data) {
|
|
13183
|
+
/** @type {?} */
|
|
13184
|
+
var stripInfo = this.stripsResultDataMap[data.key].stripInfo;
|
|
13185
|
+
if (stripInfo) {
|
|
13186
|
+
if (stripInfo.mode !== 'below') {
|
|
13187
|
+
this.loggerSvc.warn("strip info mode: " + stripInfo.mode + " not implemented yet");
|
|
13188
|
+
stripInfo.mode = 'below';
|
|
13189
|
+
}
|
|
13190
|
+
if (stripInfo.mode === 'below') {
|
|
13191
|
+
this.stripsResultDataMap[data.key].stripInfo = __assign({}, stripInfo, { visibilityMode: stripInfo.visibilityMode === 'hidden' ? 'visible' : 'hidden' });
|
|
13192
|
+
}
|
|
13193
|
+
}
|
|
13194
|
+
};
|
|
13195
|
+
/**
|
|
13196
|
+
* @private
|
|
13197
|
+
* @param {?} contents
|
|
13198
|
+
* @param {?} strip
|
|
13199
|
+
* @return {?}
|
|
13200
|
+
*/
|
|
13201
|
+
ContentStripWithTabsPillsComponent.prototype.transformContentsToWidgets = /**
|
|
13202
|
+
* @private
|
|
13203
|
+
* @param {?} contents
|
|
13204
|
+
* @param {?} strip
|
|
13205
|
+
* @return {?}
|
|
13206
|
+
*/
|
|
13207
|
+
function (contents, strip) {
|
|
13208
|
+
return (contents || []).map((/**
|
|
13209
|
+
* @param {?} content
|
|
13210
|
+
* @param {?} idx
|
|
13211
|
+
* @return {?}
|
|
13212
|
+
*/
|
|
13213
|
+
function (content, idx) { return (content ? {
|
|
13214
|
+
widgetType: 'cardLib',
|
|
13215
|
+
widgetSubType: 'cardContentLib',
|
|
13216
|
+
widgetHostClass: 'mb-2',
|
|
13217
|
+
widgetData: __assign({ content: content }, (content.batch && { batch: content.batch }), { cardSubType: strip.stripConfig && strip.stripConfig.cardSubType, cardCustomeClass: strip.customeClass ? strip.customeClass : '', context: { pageSection: strip.key, position: idx }, intranetMode: strip.stripConfig && strip.stripConfig.intranetMode, deletedMode: strip.stripConfig && strip.stripConfig.deletedMode, contentTags: strip.stripConfig && strip.stripConfig.contentTags }),
|
|
13218
|
+
} : {
|
|
13219
|
+
widgetType: 'card',
|
|
13220
|
+
widgetSubType: 'cardContent',
|
|
13221
|
+
widgetHostClass: 'mb-2',
|
|
13222
|
+
widgetData: {},
|
|
13223
|
+
}); }));
|
|
13224
|
+
};
|
|
13225
|
+
/**
|
|
13226
|
+
* @private
|
|
13227
|
+
* @param {?} contents
|
|
13228
|
+
* @param {?} strip
|
|
13229
|
+
* @return {?}
|
|
13230
|
+
*/
|
|
13231
|
+
ContentStripWithTabsPillsComponent.prototype.transformEventsToWidgets = /**
|
|
13232
|
+
* @private
|
|
13233
|
+
* @param {?} contents
|
|
13234
|
+
* @param {?} strip
|
|
13235
|
+
* @return {?}
|
|
13236
|
+
*/
|
|
13237
|
+
function (contents, strip) {
|
|
13238
|
+
this.eventSvc.setEventListData(contents);
|
|
13239
|
+
return (this.eventSvc.todaysEvents || []).map((/**
|
|
13240
|
+
* @param {?} content
|
|
13241
|
+
* @param {?} idx
|
|
13242
|
+
* @return {?}
|
|
13243
|
+
*/
|
|
13244
|
+
function (content, idx) { return (content ? {
|
|
13245
|
+
widgetType: 'card',
|
|
13246
|
+
widgetSubType: 'eventHubCard',
|
|
13247
|
+
widgetHostClass: 'mb-2',
|
|
13248
|
+
widgetData: {
|
|
13249
|
+
content: content,
|
|
13250
|
+
cardSubType: strip.stripConfig && strip.stripConfig.cardSubType,
|
|
13251
|
+
cardCustomeClass: strip.customeClass ? strip.customeClass : '',
|
|
13252
|
+
context: { pageSection: strip.key, position: idx },
|
|
13253
|
+
intranetMode: strip.stripConfig && strip.stripConfig.intranetMode,
|
|
13254
|
+
deletedMode: strip.stripConfig && strip.stripConfig.deletedMode,
|
|
13255
|
+
contentTags: strip.stripConfig && strip.stripConfig.contentTags,
|
|
13256
|
+
},
|
|
13257
|
+
} : {
|
|
13258
|
+
widgetType: 'card',
|
|
13259
|
+
widgetSubType: 'eventHubCard',
|
|
13260
|
+
widgetHostClass: 'mb-2',
|
|
13261
|
+
widgetData: {},
|
|
13262
|
+
}); }));
|
|
13263
|
+
};
|
|
13264
|
+
/**
|
|
13265
|
+
* @private
|
|
13266
|
+
* @param {?} strip
|
|
13267
|
+
* @return {?}
|
|
13268
|
+
*/
|
|
13269
|
+
ContentStripWithTabsPillsComponent.prototype.transformSkeletonToWidgets = /**
|
|
13270
|
+
* @private
|
|
13271
|
+
* @param {?} strip
|
|
13272
|
+
* @return {?}
|
|
13273
|
+
*/
|
|
13274
|
+
function (strip) {
|
|
13275
|
+
return [1, 2, 3, 4, 5, 6, 7, 7, 8, 9, 10].map((/**
|
|
13276
|
+
* @param {?} _content
|
|
13277
|
+
* @return {?}
|
|
13278
|
+
*/
|
|
13279
|
+
function (_content) { return ({
|
|
13280
|
+
widgetType: 'cardLib',
|
|
13281
|
+
widgetSubType: 'cardContentLib',
|
|
13282
|
+
widgetHostClass: 'mb-2',
|
|
13283
|
+
widgetData: {
|
|
13284
|
+
cardSubType: strip.loaderConfig && strip.loaderConfig.cardSubType || 'card-standard-skeleton',
|
|
13285
|
+
cardCustomeClass: strip.customeClass ? strip.customeClass : '',
|
|
13286
|
+
},
|
|
13287
|
+
}); }));
|
|
13288
|
+
};
|
|
13289
|
+
/**
|
|
13290
|
+
* @private
|
|
13291
|
+
* @param {?} strip
|
|
13292
|
+
* @param {?=} results
|
|
13293
|
+
* @param {?=} fetchStatus
|
|
13294
|
+
* @param {?=} calculateParentStatus
|
|
13295
|
+
* @param {?=} _viewMoreUrl
|
|
13296
|
+
* @param {?=} tabsResults
|
|
13297
|
+
* @return {?}
|
|
13298
|
+
*/
|
|
13299
|
+
ContentStripWithTabsPillsComponent.prototype.processStrip = /**
|
|
13300
|
+
* @private
|
|
13301
|
+
* @param {?} strip
|
|
13302
|
+
* @param {?=} results
|
|
13303
|
+
* @param {?=} fetchStatus
|
|
13304
|
+
* @param {?=} calculateParentStatus
|
|
13305
|
+
* @param {?=} _viewMoreUrl
|
|
13306
|
+
* @param {?=} tabsResults
|
|
13307
|
+
* @return {?}
|
|
13308
|
+
*/
|
|
13309
|
+
function (strip, results, fetchStatus, calculateParentStatus, _viewMoreUrl, tabsResults) {
|
|
13310
|
+
if (results === void 0) { results = []; }
|
|
13311
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
13312
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
13313
|
+
var stripData;
|
|
13314
|
+
var _a;
|
|
13315
|
+
return __generator(this, function (_b) {
|
|
13316
|
+
stripData = {
|
|
13317
|
+
viewMoreUrl: strip.viewMoreUrl,
|
|
13318
|
+
key: strip.key,
|
|
13319
|
+
canHideStrip: Boolean(strip.canHideStrip),
|
|
13320
|
+
showStrip: this.getIfStripHidden(strip.key),
|
|
13321
|
+
noDataWidget: strip.noDataWidget,
|
|
13322
|
+
errorWidget: strip.errorWidget,
|
|
13323
|
+
stripInfo: strip.info,
|
|
13324
|
+
stripTitle: strip.title,
|
|
13325
|
+
stripTitleLink: strip.stripTitleLink,
|
|
13326
|
+
disableTranslate: strip.disableTranslate,
|
|
13327
|
+
sliderConfig: strip.sliderConfig,
|
|
13328
|
+
tabs: tabsResults ? tabsResults : strip.tabs,
|
|
13329
|
+
stripName: strip.name,
|
|
13330
|
+
mode: strip.mode,
|
|
13331
|
+
stripConfig: strip.stripConfig,
|
|
13332
|
+
stripBackground: strip.stripBackground,
|
|
13333
|
+
secondaryHeading: strip.secondaryHeading,
|
|
13334
|
+
loaderWidgets: strip.loaderWidgets || [],
|
|
13335
|
+
widgets: fetchStatus === 'done'
|
|
13336
|
+
? __spread((strip.preWidgets || []).map((/**
|
|
13337
|
+
* @param {?} w
|
|
13338
|
+
* @return {?}
|
|
13339
|
+
*/
|
|
13340
|
+
function (w) { return (__assign({}, w, { widgetHostClass: "mb-2 " + w.widgetHostClass })); })), results, (strip.postWidgets || []).map((/**
|
|
13341
|
+
* @param {?} w
|
|
13342
|
+
* @return {?}
|
|
13343
|
+
*/
|
|
13344
|
+
function (w) { return (__assign({}, w, { widgetHostClass: "mb-2 " + w.widgetHostClass })); }))) : [],
|
|
13345
|
+
showOnNoData: Boolean(strip.noDataWidget &&
|
|
13346
|
+
!((strip.preWidgets || []).length + results.length + (strip.postWidgets || []).length) &&
|
|
13347
|
+
fetchStatus === 'done'),
|
|
13348
|
+
showOnLoader: Boolean(strip.loader && fetchStatus === 'fetching'),
|
|
13349
|
+
showOnError: Boolean(strip.errorWidget && fetchStatus === 'error'),
|
|
13350
|
+
};
|
|
13351
|
+
// const stripData = this.stripsResultDataMap[strip.key]
|
|
13352
|
+
this.stripsResultDataMap = __assign({}, this.stripsResultDataMap, (_a = {}, _a[strip.key] = stripData, _a));
|
|
13353
|
+
if (!tabsResults) {
|
|
13354
|
+
if (calculateParentStatus &&
|
|
13355
|
+
(fetchStatus === 'done' || fetchStatus === 'error') &&
|
|
13356
|
+
stripData.widgets) {
|
|
13357
|
+
this.checkParentStatus(fetchStatus, stripData.widgets.length);
|
|
13358
|
+
}
|
|
13359
|
+
if (calculateParentStatus && !(results && results.length > 0)) {
|
|
13360
|
+
this.contentAvailable = false;
|
|
13361
|
+
}
|
|
13362
|
+
else if (results && results.length > 0) {
|
|
13363
|
+
this.contentAvailable = true;
|
|
13364
|
+
}
|
|
13365
|
+
}
|
|
13366
|
+
else {
|
|
13367
|
+
this.contentAvailable = true;
|
|
13368
|
+
}
|
|
13369
|
+
return [2 /*return*/];
|
|
13370
|
+
});
|
|
13371
|
+
});
|
|
13372
|
+
};
|
|
13373
|
+
/**
|
|
13374
|
+
* @private
|
|
13375
|
+
* @param {?} fetchStatus
|
|
13376
|
+
* @param {?} stripWidgetsCount
|
|
13377
|
+
* @return {?}
|
|
13378
|
+
*/
|
|
13379
|
+
ContentStripWithTabsPillsComponent.prototype.checkParentStatus = /**
|
|
13380
|
+
* @private
|
|
13381
|
+
* @param {?} fetchStatus
|
|
13382
|
+
* @param {?} stripWidgetsCount
|
|
13383
|
+
* @return {?}
|
|
13384
|
+
*/
|
|
13385
|
+
function (fetchStatus, stripWidgetsCount) {
|
|
13386
|
+
if (fetchStatus === 'done' && !stripWidgetsCount) {
|
|
13387
|
+
this.noDataCount += 1;
|
|
13388
|
+
}
|
|
13389
|
+
else if (fetchStatus === 'done' && stripWidgetsCount) {
|
|
13390
|
+
this.successDataCount += 1;
|
|
13391
|
+
}
|
|
13392
|
+
else if (fetchStatus === 'error') {
|
|
13393
|
+
this.errorDataCount += 1;
|
|
13394
|
+
}
|
|
13395
|
+
/** @type {?} */
|
|
13396
|
+
var settledCount = this.noDataCount + this.successDataCount + this.errorDataCount;
|
|
13397
|
+
/** @type {?} */
|
|
13398
|
+
var totalCount = this.widgetData.strips.length;
|
|
13399
|
+
if (this.successDataCount > 0 && settledCount < totalCount) {
|
|
13400
|
+
return;
|
|
13401
|
+
}
|
|
13402
|
+
this.showParentLoader = settledCount !== totalCount;
|
|
13403
|
+
this.showParentNoData =
|
|
13404
|
+
this.noDataCount > 0 && this.noDataCount + this.errorDataCount === totalCount;
|
|
13405
|
+
this.showParentError = this.errorDataCount === totalCount;
|
|
13406
|
+
};
|
|
13407
|
+
/**
|
|
13408
|
+
* @param {?} strip
|
|
13409
|
+
* @return {?}
|
|
13410
|
+
*/
|
|
13411
|
+
ContentStripWithTabsPillsComponent.prototype.checkForEmptyWidget = /**
|
|
13412
|
+
* @param {?} strip
|
|
13413
|
+
* @return {?}
|
|
13414
|
+
*/
|
|
13415
|
+
function (strip) {
|
|
13416
|
+
if (strip.request &&
|
|
13417
|
+
((strip.request.api && Object.keys(strip.request.api).length) ||
|
|
13418
|
+
(strip.request.search && Object.keys(strip.request.search).length) ||
|
|
13419
|
+
(strip.request.searchRegionRecommendation &&
|
|
13420
|
+
Object.keys(strip.request.searchRegionRecommendation).length) ||
|
|
13421
|
+
(strip.request.cbpList && Object.keys(strip.request.cbpList).length) ||
|
|
13422
|
+
(strip && strip.tabs.length))) {
|
|
13423
|
+
return true;
|
|
13424
|
+
}
|
|
13425
|
+
return false;
|
|
13426
|
+
};
|
|
13427
|
+
/**
|
|
13428
|
+
* @param {?} strip
|
|
13429
|
+
* @param {?} currentTab
|
|
13430
|
+
* @param {?} calculateParentStatus
|
|
13431
|
+
* @return {?}
|
|
13432
|
+
*/
|
|
13433
|
+
ContentStripWithTabsPillsComponent.prototype.getTabDataByfilter = /**
|
|
13434
|
+
* @param {?} strip
|
|
13435
|
+
* @param {?} currentTab
|
|
13436
|
+
* @param {?} calculateParentStatus
|
|
13437
|
+
* @return {?}
|
|
13438
|
+
*/
|
|
13439
|
+
function (strip, currentTab, calculateParentStatus) {
|
|
13440
|
+
// tslint:disable:no-console
|
|
13441
|
+
console.log('strip -- ', strip);
|
|
13442
|
+
// tslint:disable:no-console
|
|
13443
|
+
console.log('currentTab -- ', currentTab);
|
|
13444
|
+
// tslint:disable:no-console
|
|
13445
|
+
console.log('calculateParentStatus-- ', calculateParentStatus);
|
|
13446
|
+
// TODO: Write logic for individual filter if passed in config
|
|
13447
|
+
// add switch case based on config key passed
|
|
13448
|
+
};
|
|
13449
|
+
/**
|
|
13450
|
+
* @param {?} stripsResultDataMap
|
|
13451
|
+
* @param {?} key
|
|
13452
|
+
* @return {?}
|
|
13453
|
+
*/
|
|
13454
|
+
ContentStripWithTabsPillsComponent.prototype.getSelectedIndex = /**
|
|
13455
|
+
* @param {?} stripsResultDataMap
|
|
13456
|
+
* @param {?} key
|
|
13457
|
+
* @return {?}
|
|
13458
|
+
*/
|
|
13459
|
+
function (stripsResultDataMap, key) {
|
|
13460
|
+
/** @type {?} */
|
|
13461
|
+
var returnValue = 0;
|
|
13462
|
+
return returnValue;
|
|
13463
|
+
};
|
|
13464
|
+
/**
|
|
13465
|
+
* @param {?} label
|
|
13466
|
+
* @param {?} type
|
|
13467
|
+
* @return {?}
|
|
13468
|
+
*/
|
|
13469
|
+
ContentStripWithTabsPillsComponent.prototype.translateLabels = /**
|
|
13470
|
+
* @param {?} label
|
|
13471
|
+
* @param {?} type
|
|
13472
|
+
* @return {?}
|
|
13473
|
+
*/
|
|
13474
|
+
function (label, type) {
|
|
13475
|
+
return this.langtranslations.translateLabel(label, type, '');
|
|
13476
|
+
};
|
|
13477
|
+
/**
|
|
13478
|
+
* @param {?} index
|
|
13479
|
+
* @param {?} item
|
|
13480
|
+
* @return {?}
|
|
13481
|
+
*/
|
|
13482
|
+
ContentStripWithTabsPillsComponent.prototype.identify = /**
|
|
13483
|
+
* @param {?} index
|
|
13484
|
+
* @param {?} item
|
|
13485
|
+
* @return {?}
|
|
13486
|
+
*/
|
|
13487
|
+
function (index, item) {
|
|
13488
|
+
if (index >= 0) { }
|
|
13489
|
+
return item;
|
|
13490
|
+
};
|
|
13491
|
+
/**
|
|
13492
|
+
* @param {?} index
|
|
13493
|
+
* @param {?} item
|
|
13494
|
+
* @return {?}
|
|
13495
|
+
*/
|
|
13496
|
+
ContentStripWithTabsPillsComponent.prototype.tracker = /**
|
|
13497
|
+
* @param {?} index
|
|
13498
|
+
* @param {?} item
|
|
13499
|
+
* @return {?}
|
|
13500
|
+
*/
|
|
13501
|
+
function (index, item) {
|
|
13502
|
+
if (index >= 0) { }
|
|
13503
|
+
return lodash.get(item, 'widgetData.content.identifier');
|
|
13504
|
+
};
|
|
13505
|
+
/**
|
|
13506
|
+
* @param {?} stripData
|
|
13507
|
+
* @return {?}
|
|
13508
|
+
*/
|
|
13509
|
+
ContentStripWithTabsPillsComponent.prototype.raiseTelemetry = /**
|
|
13510
|
+
* @param {?} stripData
|
|
13511
|
+
* @return {?}
|
|
13512
|
+
*/
|
|
13513
|
+
function (stripData) {
|
|
13514
|
+
this.telemtryResponse.emit(stripData);
|
|
13515
|
+
};
|
|
13516
|
+
/**
|
|
13517
|
+
* @param {?} stripData
|
|
13518
|
+
* @param {?} path
|
|
13519
|
+
* @param {?} queryParamsData
|
|
13520
|
+
* @return {?}
|
|
13521
|
+
*/
|
|
13522
|
+
ContentStripWithTabsPillsComponent.prototype.redirectViewAll = /**
|
|
13523
|
+
* @param {?} stripData
|
|
13524
|
+
* @param {?} path
|
|
13525
|
+
* @param {?} queryParamsData
|
|
13526
|
+
* @return {?}
|
|
13527
|
+
*/
|
|
13528
|
+
function (stripData, path, queryParamsData) {
|
|
13529
|
+
if (this.emitViewAll) {
|
|
13530
|
+
this.viewAllResponse.emit(stripData);
|
|
13531
|
+
}
|
|
13532
|
+
else {
|
|
13533
|
+
this.router.navigate([path], { queryParams: queryParamsData });
|
|
13534
|
+
}
|
|
13535
|
+
};
|
|
13536
|
+
// new code writting from here====new====
|
|
13537
|
+
// new code writting from here====new====
|
|
13538
|
+
/**
|
|
13539
|
+
* @param {?} strip
|
|
13540
|
+
* @param {?=} calculateParentStatus
|
|
13541
|
+
* @return {?}
|
|
13542
|
+
*/
|
|
13543
|
+
ContentStripWithTabsPillsComponent.prototype.fetchForYouData =
|
|
13544
|
+
// new code writting from here====new====
|
|
13545
|
+
/**
|
|
13546
|
+
* @param {?} strip
|
|
13547
|
+
* @param {?=} calculateParentStatus
|
|
13548
|
+
* @return {?}
|
|
13549
|
+
*/
|
|
13550
|
+
function (strip, calculateParentStatus) {
|
|
13551
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
13552
|
+
if (strip && strip.type === 'forYou') {
|
|
13553
|
+
if (strip.tabs && strip.tabs.length) {
|
|
13554
|
+
/** @type {?} */
|
|
13555
|
+
var firstTab = strip.tabs[0];
|
|
13556
|
+
/** @type {?} */
|
|
13557
|
+
var pillData = firstTab.pillsData[0];
|
|
13558
|
+
if (pillData.requestRequired) {
|
|
13559
|
+
if (this.stripsResultDataMap[strip.key] && this.stripsResultDataMap[strip.key].tabs) {
|
|
13560
|
+
/** @type {?} */
|
|
13561
|
+
var allPills = this.stripsResultDataMap[strip.key].tabs[0].pillsData;
|
|
13562
|
+
/** @type {?} */
|
|
13563
|
+
var currenPillsFromMap = (/** @type {?} */ ((allPills && allPills.length && allPills[0])));
|
|
13564
|
+
this.getTabDataByNewReqTrending(strip, 0, 0, currenPillsFromMap, calculateParentStatus);
|
|
13565
|
+
if (this.stripsResultDataMap[strip.key] && currenPillsFromMap) {
|
|
13566
|
+
this.stripsResultDataMap[strip.key].viewMoreUrl.queryParams = __assign({}, this.stripsResultDataMap[strip.key].viewMoreUrl.queryParams, { key: strip.key, tabSelected: firstTab.value, pillSelected: pillData.value });
|
|
13567
|
+
}
|
|
13568
|
+
}
|
|
13569
|
+
}
|
|
13570
|
+
}
|
|
13571
|
+
}
|
|
13572
|
+
};
|
|
13573
|
+
/**
|
|
13574
|
+
* @param {?} strip
|
|
13575
|
+
* @param {?=} calculateParentStatus
|
|
13576
|
+
* @return {?}
|
|
13577
|
+
*/
|
|
13578
|
+
ContentStripWithTabsPillsComponent.prototype.fetchFromSearchV6 = /**
|
|
13579
|
+
* @param {?} strip
|
|
13580
|
+
* @param {?=} calculateParentStatus
|
|
13581
|
+
* @return {?}
|
|
13582
|
+
*/
|
|
13583
|
+
function (strip, calculateParentStatus) {
|
|
13584
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
13585
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
13586
|
+
var originalFilters, firstTab, allTabs, currentTabFromMap, response, error_1;
|
|
13587
|
+
return __generator(this, function (_a) {
|
|
13588
|
+
switch (_a.label) {
|
|
13589
|
+
case 0:
|
|
13590
|
+
if (!(strip.request && strip.request.searchV6 && Object.keys(strip.request.searchV6).length)) return [3 /*break*/, 4];
|
|
13591
|
+
// if (!(strip.request.searchV6.locale && strip.request.searchV6.locale.length > 0)) {
|
|
13592
|
+
// if (this.configSvc.activeLocale) {
|
|
13593
|
+
// strip.request.searchV6.locale = [this.configSvc.activeLocale.locals[0]]
|
|
13594
|
+
// } else {
|
|
13595
|
+
// strip.request.searchV6.locale = ['en']
|
|
13596
|
+
// }
|
|
13597
|
+
// }
|
|
13598
|
+
originalFilters = [];
|
|
13599
|
+
// tslint:disable:no-console
|
|
13600
|
+
if (strip.request &&
|
|
13601
|
+
strip.request.searchV6 &&
|
|
13602
|
+
strip.request.searchV6.request &&
|
|
13603
|
+
strip.request.searchV6.request.filters) {
|
|
13604
|
+
originalFilters = strip.request.searchV6.request.filters;
|
|
13605
|
+
strip.request.searchV6.request.filters = this.checkForDateFilters(strip.request.searchV6.request.filters);
|
|
13606
|
+
strip.request.searchV6.request.filters = this.getFiltersFromArray(strip.request.searchV6.request.filters);
|
|
13607
|
+
}
|
|
13608
|
+
if (!(strip.tabs && strip.tabs.length)) return [3 /*break*/, 1];
|
|
13609
|
+
// TODO: Have to extract requestRequired to outer level of tabs config
|
|
13610
|
+
firstTab = strip.tabs[0];
|
|
13611
|
+
if (firstTab.requestRequired) {
|
|
13612
|
+
if (this.stripsResultDataMap[strip.key] && this.stripsResultDataMap[strip.key].tabs) {
|
|
13613
|
+
allTabs = this.stripsResultDataMap[strip.key].tabs;
|
|
13614
|
+
currentTabFromMap = (/** @type {?} */ ((allTabs && allTabs.length && allTabs[0])));
|
|
13615
|
+
this.getTabDataByNewReqSearchV6(strip, 0, 0, currentTabFromMap, calculateParentStatus);
|
|
13616
|
+
}
|
|
13617
|
+
}
|
|
13618
|
+
return [3 /*break*/, 4];
|
|
13619
|
+
case 1:
|
|
13620
|
+
_a.trys.push([1, 3, , 4]);
|
|
13621
|
+
return [4 /*yield*/, this.searchV6Request(strip, strip.request, calculateParentStatus)];
|
|
13622
|
+
case 2:
|
|
13623
|
+
response = _a.sent();
|
|
13624
|
+
// console.log('calling after - response, ', response)
|
|
13625
|
+
if (response && response.results) {
|
|
13626
|
+
// console.log('calling after-- ')
|
|
13627
|
+
if (response.results.result.content) {
|
|
13628
|
+
this.processStrip(strip, this.transformContentsToWidgets(response.results.result.content, strip), 'done', calculateParentStatus, response.viewMoreUrl);
|
|
13629
|
+
}
|
|
13630
|
+
else if (response.results.result.Event) {
|
|
13631
|
+
this.processStrip(strip, this.transformEventsToWidgets(response.results.result.Event, strip), 'done', calculateParentStatus, response.viewMoreUrl);
|
|
13632
|
+
}
|
|
13633
|
+
else {
|
|
13634
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
13635
|
+
}
|
|
13636
|
+
}
|
|
13637
|
+
else {
|
|
13638
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
13639
|
+
}
|
|
13640
|
+
return [3 /*break*/, 4];
|
|
13641
|
+
case 3:
|
|
13642
|
+
error_1 = _a.sent();
|
|
13643
|
+
return [3 /*break*/, 4];
|
|
13644
|
+
case 4: return [2 /*return*/];
|
|
13645
|
+
}
|
|
13646
|
+
});
|
|
13647
|
+
});
|
|
13648
|
+
};
|
|
13649
|
+
/**
|
|
13650
|
+
* @param {?} strip
|
|
13651
|
+
* @param {?} tabIndex
|
|
13652
|
+
* @param {?} pillIndex
|
|
13653
|
+
* @param {?} currentTab
|
|
13654
|
+
* @param {?} calculateParentStatus
|
|
13655
|
+
* @return {?}
|
|
13656
|
+
*/
|
|
13657
|
+
ContentStripWithTabsPillsComponent.prototype.getTabDataByNewReqTrending = /**
|
|
13658
|
+
* @param {?} strip
|
|
13659
|
+
* @param {?} tabIndex
|
|
13660
|
+
* @param {?} pillIndex
|
|
13661
|
+
* @param {?} currentTab
|
|
13662
|
+
* @param {?} calculateParentStatus
|
|
13663
|
+
* @return {?}
|
|
13664
|
+
*/
|
|
13665
|
+
function (strip, tabIndex, pillIndex, currentTab, calculateParentStatus) {
|
|
13666
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
13667
|
+
var response, tabResults, content, widgets, allTabs, allPills, allTabs, allPills, error_2;
|
|
13668
|
+
return __generator(this, function (_a) {
|
|
13669
|
+
switch (_a.label) {
|
|
13670
|
+
case 0:
|
|
13671
|
+
_a.trys.push([0, 2, , 3]);
|
|
13672
|
+
return [4 /*yield*/, this.trendingSearchRequest(strip, currentTab.request, calculateParentStatus)];
|
|
13673
|
+
case 1:
|
|
13674
|
+
response = _a.sent();
|
|
13675
|
+
tabResults = [];
|
|
13676
|
+
if (response && response.results && response.results.response) {
|
|
13677
|
+
content = response.results.response[currentTab.value] || [];
|
|
13678
|
+
widgets = this.transformContentsToWidgets(content, strip);
|
|
13679
|
+
if (this.stripsResultDataMap[strip.key] && this.stripsResultDataMap[strip.key].tabs) {
|
|
13680
|
+
allTabs = this.stripsResultDataMap[strip.key].tabs;
|
|
13681
|
+
allPills = this.stripsResultDataMap[strip.key].tabs[tabIndex].pillsData;
|
|
13682
|
+
this.resetSelectedPill(allPills);
|
|
13683
|
+
if (allTabs && allTabs.length && allTabs[tabIndex]) {
|
|
13684
|
+
if (allPills && allPills.length && allPills[pillIndex]) {
|
|
13685
|
+
allPills[pillIndex] = __assign({}, allPills[pillIndex], { widgets: widgets, fetchTabStatus: 'done', selected: true });
|
|
13686
|
+
}
|
|
13687
|
+
allTabs[tabIndex] = __assign({}, allTabs[tabIndex], { widgets: widgets, fetchTabStatus: 'done' });
|
|
13688
|
+
tabResults = allTabs;
|
|
13689
|
+
}
|
|
13690
|
+
}
|
|
13691
|
+
this.processStrip(strip, widgets, 'done', calculateParentStatus, response.viewMoreUrl, tabResults // tabResults as widgets
|
|
13692
|
+
);
|
|
13693
|
+
}
|
|
13694
|
+
else {
|
|
13695
|
+
if (this.stripsResultDataMap[strip.key] && this.stripsResultDataMap[strip.key].tabs) {
|
|
13696
|
+
allTabs = this.stripsResultDataMap[strip.key].tabs;
|
|
13697
|
+
allPills = this.stripsResultDataMap[strip.key].tabs[tabIndex].pillsData;
|
|
13698
|
+
this.resetSelectedPill(allPills);
|
|
13699
|
+
if (allTabs && allTabs.length && allTabs[tabIndex]) {
|
|
13700
|
+
if (allPills && allPills.length && allPills[pillIndex]) {
|
|
13701
|
+
allPills[pillIndex] = __assign({}, allPills[pillIndex], { widgets: [], fetchTabStatus: 'done', selected: true });
|
|
13702
|
+
}
|
|
13703
|
+
allTabs[tabIndex] = __assign({}, allTabs[tabIndex], { widgets: [], fetchTabStatus: 'done' });
|
|
13704
|
+
tabResults = allTabs;
|
|
13705
|
+
}
|
|
13706
|
+
}
|
|
13707
|
+
this.processStrip(strip, [], 'done', calculateParentStatus, null);
|
|
13708
|
+
}
|
|
13709
|
+
return [3 /*break*/, 3];
|
|
13710
|
+
case 2:
|
|
13711
|
+
error_2 = _a.sent();
|
|
13712
|
+
// Handle errors
|
|
13713
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
13714
|
+
return [3 /*break*/, 3];
|
|
13715
|
+
case 3: return [2 /*return*/];
|
|
13716
|
+
}
|
|
13717
|
+
});
|
|
13718
|
+
});
|
|
13719
|
+
};
|
|
13720
|
+
/**
|
|
13721
|
+
* @param {?} strip
|
|
13722
|
+
* @param {?} tabIndex
|
|
13723
|
+
* @param {?} pillIndex
|
|
13724
|
+
* @param {?} currentTab
|
|
13725
|
+
* @param {?} calculateParentStatus
|
|
13726
|
+
* @return {?}
|
|
13727
|
+
*/
|
|
13728
|
+
ContentStripWithTabsPillsComponent.prototype.getTabDataByNewReqSearchV6 = /**
|
|
13729
|
+
* @param {?} strip
|
|
13730
|
+
* @param {?} tabIndex
|
|
13731
|
+
* @param {?} pillIndex
|
|
13732
|
+
* @param {?} currentTab
|
|
13733
|
+
* @param {?} calculateParentStatus
|
|
13734
|
+
* @return {?}
|
|
13735
|
+
*/
|
|
13736
|
+
function (strip, tabIndex, pillIndex, currentTab, calculateParentStatus) {
|
|
13737
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
13738
|
+
var response, widgets, tabResults, allTabs, allPills, error_3;
|
|
13739
|
+
return __generator(this, function (_a) {
|
|
13740
|
+
switch (_a.label) {
|
|
13741
|
+
case 0:
|
|
13742
|
+
_a.trys.push([0, 2, , 3]);
|
|
13743
|
+
return [4 /*yield*/, this.searchV6Request(strip, currentTab.request, calculateParentStatus)];
|
|
13744
|
+
case 1:
|
|
13745
|
+
response = _a.sent();
|
|
13746
|
+
if (response && response.results) {
|
|
13747
|
+
widgets = this.transformContentsToWidgets(response.results.result.content, strip);
|
|
13748
|
+
tabResults = [];
|
|
13749
|
+
if (this.stripsResultDataMap[strip.key] && this.stripsResultDataMap[strip.key].tabs) {
|
|
13750
|
+
allTabs = this.stripsResultDataMap[strip.key].tabs;
|
|
13751
|
+
allPills = this.stripsResultDataMap[strip.key].tabs[tabIndex].pillsData;
|
|
13752
|
+
this.resetSelectedPill(allPills);
|
|
13753
|
+
if (allTabs && allTabs.length && allTabs[tabIndex]) {
|
|
13754
|
+
if (allPills && allPills.length && allPills[pillIndex]) {
|
|
13755
|
+
allPills[pillIndex] = __assign({}, allPills[pillIndex], { widgets: widgets, fetchTabStatus: 'done', selected: true });
|
|
13756
|
+
}
|
|
13757
|
+
allTabs[tabIndex] = __assign({}, allTabs[tabIndex], { widgets: widgets, fetchTabStatus: 'done' });
|
|
13758
|
+
tabResults = allTabs;
|
|
13759
|
+
}
|
|
13760
|
+
}
|
|
13761
|
+
this.processStrip(strip, widgets, 'done', calculateParentStatus, response.viewMoreUrl, tabResults // tabResults as widgets
|
|
13762
|
+
);
|
|
13763
|
+
}
|
|
13764
|
+
else {
|
|
13765
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
13766
|
+
}
|
|
13767
|
+
return [3 /*break*/, 3];
|
|
13768
|
+
case 2:
|
|
13769
|
+
error_3 = _a.sent();
|
|
13770
|
+
return [3 /*break*/, 3];
|
|
13771
|
+
case 3: return [2 /*return*/];
|
|
13772
|
+
}
|
|
13773
|
+
});
|
|
13774
|
+
});
|
|
13775
|
+
};
|
|
13776
|
+
/**
|
|
13777
|
+
* @param {?} strip
|
|
13778
|
+
* @param {?} request
|
|
13779
|
+
* @param {?} calculateParentStatus
|
|
13780
|
+
* @return {?}
|
|
13781
|
+
*/
|
|
13782
|
+
ContentStripWithTabsPillsComponent.prototype.trendingSearchRequest = /**
|
|
13783
|
+
* @param {?} strip
|
|
13784
|
+
* @param {?} request
|
|
13785
|
+
* @param {?} calculateParentStatus
|
|
13786
|
+
* @return {?}
|
|
13787
|
+
*/
|
|
13788
|
+
function (strip, request, calculateParentStatus) {
|
|
13789
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
13790
|
+
var originalFilters;
|
|
13791
|
+
var _this = this;
|
|
13792
|
+
return __generator(this, function (_a) {
|
|
13793
|
+
originalFilters = [];
|
|
13794
|
+
return [2 /*return*/, new Promise((/**
|
|
13795
|
+
* @param {?} resolve
|
|
13796
|
+
* @param {?} reject
|
|
13797
|
+
* @return {?}
|
|
13798
|
+
*/
|
|
13799
|
+
function (resolve, reject) {
|
|
13800
|
+
if (request && request.trendingSearch) {
|
|
13801
|
+
// check for the request if it has dynamic values]
|
|
13802
|
+
if (request.trendingSearch.request.filters.organisation &&
|
|
13803
|
+
request.trendingSearch.request.filters.organisation.indexOf('<orgID>') >= 0) {
|
|
13804
|
+
/** @type {?} */
|
|
13805
|
+
var userRootOrgId = void 0;
|
|
13806
|
+
if (_this.configSvc.userProfile) {
|
|
13807
|
+
userRootOrgId = _this.configSvc.userProfile.rootOrgId;
|
|
13808
|
+
}
|
|
13809
|
+
request.trendingSearch.request.filters.organisation = userRootOrgId;
|
|
13810
|
+
}
|
|
13811
|
+
_this.contentSvc.trendingContentSearch(request.trendingSearch).subscribe((/**
|
|
13812
|
+
* @param {?} results
|
|
13813
|
+
* @return {?}
|
|
13814
|
+
*/
|
|
13815
|
+
function (results) {
|
|
13816
|
+
/** @type {?} */
|
|
13817
|
+
var showViewMore = Boolean(results.result &&
|
|
13818
|
+
strip.request &&
|
|
13819
|
+
results.result[strip.request.trendingSearch.responseKey] &&
|
|
13820
|
+
results.result[strip.request.trendingSearch.responseKey].length > 5 &&
|
|
13821
|
+
strip.stripConfig && strip.stripConfig.postCardForSearch);
|
|
13822
|
+
/** @type {?} */
|
|
13823
|
+
var viewMoreUrl = showViewMore
|
|
13824
|
+
? {
|
|
13825
|
+
path: strip.viewMoreUrl && strip.viewMoreUrl.path || '',
|
|
13826
|
+
queryParams: {
|
|
13827
|
+
tab: 'Learn',
|
|
13828
|
+
q: strip.viewMoreUrl && strip.viewMoreUrl.queryParams,
|
|
13829
|
+
f: request &&
|
|
13830
|
+
request.trendingSearch &&
|
|
13831
|
+
request.trendingSearch.request &&
|
|
13832
|
+
request.trendingSearch.request.filters
|
|
13833
|
+
? JSON.stringify(_this.transformSearchV6FiltersV2(originalFilters))
|
|
13834
|
+
: {},
|
|
13835
|
+
},
|
|
13836
|
+
}
|
|
13837
|
+
: null;
|
|
13838
|
+
/** @type {?} */
|
|
13839
|
+
var proccesedResult = [];
|
|
13840
|
+
if (results && results.response && results.response.certifications) {
|
|
13841
|
+
results.response.certifications.map((/**
|
|
13842
|
+
* @param {?} result
|
|
13843
|
+
* @return {?}
|
|
13844
|
+
*/
|
|
13845
|
+
function (result) {
|
|
13846
|
+
if (result.source === _this.channnelName) {
|
|
13847
|
+
proccesedResult.push(result);
|
|
13848
|
+
}
|
|
13849
|
+
}));
|
|
13850
|
+
results = { response: { certifications: proccesedResult } };
|
|
13851
|
+
}
|
|
13852
|
+
resolve({ results: results, viewMoreUrl: viewMoreUrl });
|
|
13853
|
+
}), (/**
|
|
13854
|
+
* @param {?} error
|
|
13855
|
+
* @return {?}
|
|
13856
|
+
*/
|
|
13857
|
+
function (error) {
|
|
13858
|
+
if (error.error && error.error.status === 400) {
|
|
13859
|
+
_this.processStrip(strip, [], 'done', calculateParentStatus, null);
|
|
13860
|
+
}
|
|
13861
|
+
// this.processStrip(strip, [], 'done', calculateParentStatus, null)
|
|
13862
|
+
reject(error);
|
|
13863
|
+
}));
|
|
13864
|
+
}
|
|
13865
|
+
}))];
|
|
13866
|
+
});
|
|
13867
|
+
});
|
|
13868
|
+
};
|
|
13869
|
+
/**
|
|
13870
|
+
* @param {?} tabEvent
|
|
13871
|
+
* @param {?} pillIndex
|
|
13872
|
+
* @param {?} stripMap
|
|
13873
|
+
* @param {?} stripKey
|
|
13874
|
+
* @return {?}
|
|
13875
|
+
*/
|
|
13876
|
+
ContentStripWithTabsPillsComponent.prototype.tabClicked = /**
|
|
13877
|
+
* @param {?} tabEvent
|
|
13878
|
+
* @param {?} pillIndex
|
|
13879
|
+
* @param {?} stripMap
|
|
13880
|
+
* @param {?} stripKey
|
|
13881
|
+
* @return {?}
|
|
13882
|
+
*/
|
|
13883
|
+
function (tabEvent, pillIndex, stripMap, stripKey) {
|
|
13884
|
+
if (stripMap && stripMap.tabs && stripMap.tabs[tabEvent.index]) {
|
|
13885
|
+
stripMap.tabs[tabEvent.index].pillsData[pillIndex].fetchTabStatus = 'inprogress';
|
|
13886
|
+
stripMap.tabs[tabEvent.index].pillsData[pillIndex].tabLoading = true;
|
|
13887
|
+
stripMap.showOnLoader = true;
|
|
13888
|
+
}
|
|
13889
|
+
/** @type {?} */
|
|
13890
|
+
var data = {
|
|
13891
|
+
label: "" + tabEvent.tab.textLabel,
|
|
13892
|
+
index: tabEvent.index,
|
|
13893
|
+
};
|
|
13894
|
+
this.eventSvc.raiseInteractTelemetry({
|
|
13895
|
+
type: utilsV2.WsEvents.EnumInteractTypes.CLICK,
|
|
13896
|
+
subType: utilsV2.WsEvents.EnumInteractSubTypes.HOME_PAGE_STRIP_TABS,
|
|
13897
|
+
id: lodash.camelCase(data.label) + "-tab",
|
|
13898
|
+
}, {}, {
|
|
13899
|
+
module: utilsV2.WsEvents.EnumTelemetrymodules.HOME,
|
|
13900
|
+
});
|
|
13901
|
+
/** @type {?} */
|
|
13902
|
+
var currentTabFromMap = stripMap.tabs && stripMap.tabs[tabEvent.index];
|
|
13903
|
+
/** @type {?} */
|
|
13904
|
+
var currentPillFromMap = stripMap.tabs && stripMap.tabs[tabEvent.index].pillsData[pillIndex];
|
|
13905
|
+
/** @type {?} */
|
|
13906
|
+
var currentStrip = this.widgetData.strips.find((/**
|
|
13907
|
+
* @param {?} s
|
|
13908
|
+
* @return {?}
|
|
13909
|
+
*/
|
|
13910
|
+
function (s) { return s.key === stripKey; }));
|
|
13911
|
+
if (this.stripsResultDataMap[stripKey] && currentTabFromMap) {
|
|
13912
|
+
this.stripsResultDataMap[stripKey].viewMoreUrl.queryParams = __assign({}, this.stripsResultDataMap[stripKey].viewMoreUrl.queryParams, { tabSelected: currentTabFromMap.value, pillSelected: currentPillFromMap.value });
|
|
13913
|
+
}
|
|
13914
|
+
if (currentStrip && currentTabFromMap && !currentTabFromMap.computeDataOnClick && currentPillFromMap) {
|
|
13915
|
+
if (currentPillFromMap.requestRequired && currentPillFromMap.request) {
|
|
13916
|
+
// call API to get tab data and process
|
|
13917
|
+
// this.processStrip(currentStrip, [], 'fetching', true, null)
|
|
13918
|
+
if (currentPillFromMap.request.searchV6) {
|
|
13919
|
+
this.getTabDataByNewReqSearchV6(currentStrip, tabEvent.index, 0, currentPillFromMap, true);
|
|
13920
|
+
}
|
|
13921
|
+
else if (currentPillFromMap.request.trendingSearch) {
|
|
13922
|
+
this.getTabDataByNewReqTrending(currentStrip, tabEvent.index, 0, currentPillFromMap, true);
|
|
13923
|
+
}
|
|
13924
|
+
// if (stripMap && stripMap.tabs && stripMap.tabs[tabEvent.index]) {
|
|
13925
|
+
// stripMap.tabs[tabEvent.index].tabLoading = false;
|
|
13926
|
+
// }
|
|
13927
|
+
stripMap.tabs[tabEvent.index].pillsData[pillIndex].tabLoading = false;
|
|
13928
|
+
}
|
|
13929
|
+
else {
|
|
13930
|
+
// this.getTabDataByfilter(currentStrip, currentTabFromMap, true);
|
|
13931
|
+
// setTimeout(() => {
|
|
13932
|
+
// if (stripMap && stripMap.tabs && stripMap.tabs[tabEvent.index]) {
|
|
13933
|
+
// stripMap.tabs[tabEvent.index].tabLoading = false;
|
|
13934
|
+
// stripMap.tabs[tabEvent.index].fetchTabStatus = 'done';
|
|
13935
|
+
// stripMap.showOnLoader = false;
|
|
13936
|
+
// }
|
|
13937
|
+
// }, 200);
|
|
13938
|
+
}
|
|
13939
|
+
}
|
|
13940
|
+
};
|
|
13941
|
+
/**
|
|
13942
|
+
* @param {?} event
|
|
13943
|
+
* @param {?} stripMap
|
|
13944
|
+
* @param {?} stripKey
|
|
13945
|
+
* @param {?} pillIndex
|
|
13946
|
+
* @param {?} tabIndex
|
|
13947
|
+
* @return {?}
|
|
13948
|
+
*/
|
|
13949
|
+
ContentStripWithTabsPillsComponent.prototype.pillClicked = /**
|
|
13950
|
+
* @param {?} event
|
|
13951
|
+
* @param {?} stripMap
|
|
13952
|
+
* @param {?} stripKey
|
|
13953
|
+
* @param {?} pillIndex
|
|
13954
|
+
* @param {?} tabIndex
|
|
13955
|
+
* @return {?}
|
|
13956
|
+
*/
|
|
13957
|
+
function (event, stripMap, stripKey, pillIndex, tabIndex) {
|
|
13958
|
+
var _this = this;
|
|
13959
|
+
if (stripMap && stripMap.tabs && stripMap.tabs[tabIndex]) {
|
|
13960
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].fetchTabStatus = 'inprogress';
|
|
13961
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].tabLoading = true;
|
|
13962
|
+
stripMap.showOnLoader = true;
|
|
13963
|
+
}
|
|
13964
|
+
/** @type {?} */
|
|
13965
|
+
var currentTabFromMap = stripMap.tabs && stripMap.tabs[tabIndex];
|
|
13966
|
+
/** @type {?} */
|
|
13967
|
+
var currentPillFromMap = stripMap.tabs && stripMap.tabs[tabIndex].pillsData[pillIndex];
|
|
13968
|
+
/** @type {?} */
|
|
13969
|
+
var currentStrip = this.widgetData.strips.find((/**
|
|
13970
|
+
* @param {?} s
|
|
13971
|
+
* @return {?}
|
|
13972
|
+
*/
|
|
13973
|
+
function (s) { return s.key === stripKey; }));
|
|
13974
|
+
if (this.stripsResultDataMap[stripKey] && currentTabFromMap) {
|
|
13975
|
+
this.stripsResultDataMap[stripKey].viewMoreUrl.queryParams = __assign({}, this.stripsResultDataMap[stripKey].viewMoreUrl.queryParams, { tabSelected: currentTabFromMap.value, pillSelected: currentPillFromMap.value });
|
|
13976
|
+
}
|
|
13977
|
+
if (currentStrip && currentTabFromMap && !currentTabFromMap.computeDataOnClick && currentPillFromMap) {
|
|
13978
|
+
if (currentPillFromMap.requestRequired && currentPillFromMap.request) {
|
|
13979
|
+
// call API to get tab data and process
|
|
13980
|
+
// this.processStrip(currentStrip, [], 'fetching', true, null)
|
|
13981
|
+
if (currentPillFromMap.request.searchV6) {
|
|
13982
|
+
this.getTabDataByNewReqSearchV6(currentStrip, tabIndex, pillIndex, currentPillFromMap, true);
|
|
13983
|
+
}
|
|
13984
|
+
else if (currentPillFromMap.request.trendingSearch) {
|
|
13985
|
+
this.getTabDataByNewReqTrending(currentStrip, tabIndex, pillIndex, currentPillFromMap, true);
|
|
13986
|
+
}
|
|
13987
|
+
// if (stripMap && stripMap.tabs && stripMap.tabs[tabEvent.index]) {
|
|
13988
|
+
// stripMap.tabs[tabEvent.index].tabLoading = false;
|
|
13989
|
+
// }
|
|
13990
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].tabLoading = false;
|
|
13991
|
+
}
|
|
13992
|
+
else {
|
|
13993
|
+
this.getTabDataByfilter(currentStrip, currentTabFromMap, true);
|
|
13994
|
+
if (stripMap && stripMap.tabs && stripMap.tabs[tabIndex]) {
|
|
13995
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].fetchTabStatus = 'inprogress';
|
|
13996
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].tabLoading = false;
|
|
13997
|
+
stripMap.showOnLoader = true;
|
|
13998
|
+
}
|
|
13999
|
+
setTimeout((/**
|
|
14000
|
+
* @return {?}
|
|
14001
|
+
*/
|
|
14002
|
+
function () {
|
|
14003
|
+
if (stripMap && stripMap.tabs && stripMap.tabs[tabIndex]) {
|
|
14004
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].fetchTabStatus = 'done';
|
|
14005
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex].tabLoading = false;
|
|
14006
|
+
stripMap.showOnLoader = false;
|
|
14007
|
+
_this.resetSelectedPill(stripMap.tabs[tabIndex].pillsData);
|
|
14008
|
+
stripMap.tabs[tabIndex].pillsData[pillIndex]['selected'] = true;
|
|
14009
|
+
}
|
|
14010
|
+
}), 200);
|
|
14011
|
+
}
|
|
14012
|
+
}
|
|
14013
|
+
};
|
|
14014
|
+
/**
|
|
14015
|
+
* @param {?} strip
|
|
14016
|
+
* @param {?} request
|
|
14017
|
+
* @param {?} calculateParentStatus
|
|
14018
|
+
* @return {?}
|
|
14019
|
+
*/
|
|
14020
|
+
ContentStripWithTabsPillsComponent.prototype.searchV6Request = /**
|
|
14021
|
+
* @param {?} strip
|
|
14022
|
+
* @param {?} request
|
|
14023
|
+
* @param {?} calculateParentStatus
|
|
14024
|
+
* @return {?}
|
|
14025
|
+
*/
|
|
14026
|
+
function (strip, request, calculateParentStatus) {
|
|
14027
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
14028
|
+
var originalFilters;
|
|
14029
|
+
var _this = this;
|
|
14030
|
+
return __generator(this, function (_a) {
|
|
14031
|
+
originalFilters = [];
|
|
14032
|
+
return [2 /*return*/, new Promise((/**
|
|
14033
|
+
* @param {?} resolve
|
|
14034
|
+
* @param {?} reject
|
|
14035
|
+
* @return {?}
|
|
14036
|
+
*/
|
|
14037
|
+
function (resolve, reject) {
|
|
14038
|
+
if (request && request.searchV6) {
|
|
14039
|
+
_this.contentSvc.searchV6(request.searchV6).subscribe((/**
|
|
14040
|
+
* @param {?} results
|
|
14041
|
+
* @return {?}
|
|
14042
|
+
*/
|
|
14043
|
+
function (results) {
|
|
14044
|
+
/** @type {?} */
|
|
14045
|
+
var showViewMore = Boolean(results.result.content && results.result.content.length > 5 && strip.stripConfig && strip.stripConfig.postCardForSearch);
|
|
14046
|
+
/** @type {?} */
|
|
14047
|
+
var viewMoreUrl = showViewMore
|
|
14048
|
+
? {
|
|
14049
|
+
path: strip.viewMoreUrl && strip.viewMoreUrl.path || '',
|
|
14050
|
+
queryParams: {
|
|
14051
|
+
tab: 'Learn',
|
|
14052
|
+
q: strip.viewMoreUrl && strip.viewMoreUrl.queryParams,
|
|
14053
|
+
f: request &&
|
|
14054
|
+
request.searchV6 &&
|
|
14055
|
+
request.searchV6.request &&
|
|
14056
|
+
request.searchV6.request.filters
|
|
14057
|
+
? JSON.stringify(_this.transformSearchV6FiltersV2(originalFilters))
|
|
14058
|
+
: {},
|
|
14059
|
+
},
|
|
14060
|
+
}
|
|
14061
|
+
: null;
|
|
14062
|
+
// if (viewMoreUrl && viewMoreUrl.queryParams) {
|
|
14063
|
+
// viewMoreUrl.queryParams = viewMoreUrl.queryParams
|
|
14064
|
+
// }
|
|
14065
|
+
resolve({ results: results, viewMoreUrl: viewMoreUrl });
|
|
14066
|
+
}), (/**
|
|
14067
|
+
* @param {?} error
|
|
14068
|
+
* @return {?}
|
|
14069
|
+
*/
|
|
14070
|
+
function (error) {
|
|
14071
|
+
_this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
14072
|
+
reject(error);
|
|
14073
|
+
}));
|
|
14074
|
+
}
|
|
14075
|
+
}))];
|
|
14076
|
+
});
|
|
14077
|
+
});
|
|
14078
|
+
};
|
|
14079
|
+
/**
|
|
14080
|
+
* @param {?} tabdata
|
|
14081
|
+
* @param {?} tabIndex
|
|
14082
|
+
* @return {?}
|
|
14083
|
+
*/
|
|
14084
|
+
ContentStripWithTabsPillsComponent.prototype.getSelectedPillIndex = /**
|
|
14085
|
+
* @param {?} tabdata
|
|
14086
|
+
* @param {?} tabIndex
|
|
14087
|
+
* @return {?}
|
|
14088
|
+
*/
|
|
14089
|
+
function (tabdata, tabIndex) {
|
|
14090
|
+
if (tabdata.pillsData && tabdata.pillsData.length) {
|
|
14091
|
+
/** @type {?} */
|
|
14092
|
+
var index = tabdata.pillsData.findIndex((/**
|
|
14093
|
+
* @param {?} pill
|
|
14094
|
+
* @return {?}
|
|
14095
|
+
*/
|
|
14096
|
+
function (pill) {
|
|
14097
|
+
return pill.selected;
|
|
14098
|
+
}));
|
|
14099
|
+
return index;
|
|
14100
|
+
}
|
|
14101
|
+
return 0;
|
|
14102
|
+
};
|
|
14103
|
+
// cbp plans
|
|
14104
|
+
// cbp plans
|
|
14105
|
+
/**
|
|
14106
|
+
* @param {?} strip
|
|
14107
|
+
* @param {?=} calculateParentStatus
|
|
14108
|
+
* @return {?}
|
|
14109
|
+
*/
|
|
14110
|
+
ContentStripWithTabsPillsComponent.prototype.fetchAllCbpPlans =
|
|
14111
|
+
// cbp plans
|
|
14112
|
+
/**
|
|
14113
|
+
* @param {?} strip
|
|
14114
|
+
* @param {?=} calculateParentStatus
|
|
14115
|
+
* @return {?}
|
|
14116
|
+
*/
|
|
14117
|
+
function (strip, calculateParentStatus) {
|
|
14118
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
14119
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
14120
|
+
var courses, tabResults, response, countOfWidget_1;
|
|
14121
|
+
return __generator(this, function (_a) {
|
|
14122
|
+
switch (_a.label) {
|
|
14123
|
+
case 0:
|
|
14124
|
+
if (!(strip.request && strip.request.cbpList && Object.keys(strip.request.cbpList).length)) return [3 /*break*/, 5];
|
|
14125
|
+
courses = void 0;
|
|
14126
|
+
tabResults = [];
|
|
14127
|
+
return [4 /*yield*/, this.userSvc.fetchCbpPlanList().toPromise()];
|
|
14128
|
+
case 1:
|
|
14129
|
+
response = _a.sent();
|
|
14130
|
+
if (!response) return [3 /*break*/, 4];
|
|
14131
|
+
courses = response;
|
|
14132
|
+
if (!(strip.tabs && strip.tabs.length)) return [3 /*break*/, 3];
|
|
14133
|
+
tabResults = this.splitCbpTabsData(courses, strip);
|
|
14134
|
+
countOfWidget_1 = true;
|
|
14135
|
+
if (strip && strip.tabs && strip.tabs.length) {
|
|
14136
|
+
strip.tabs.forEach((/**
|
|
14137
|
+
* @param {?} tab
|
|
14138
|
+
* @return {?}
|
|
14139
|
+
*/
|
|
14140
|
+
function (tab) {
|
|
14141
|
+
if (tab.pillsData && tab.pillsData.length) {
|
|
14142
|
+
tab.pillsData.forEach((/**
|
|
14143
|
+
* @param {?} pill
|
|
14144
|
+
* @return {?}
|
|
14145
|
+
*/
|
|
14146
|
+
function (pill) {
|
|
14147
|
+
if (pill && pill.widgets && pill.widgets.length) {
|
|
14148
|
+
if (countOfWidget_1) {
|
|
14149
|
+
pill.selected = true;
|
|
14150
|
+
countOfWidget_1 = false;
|
|
14151
|
+
}
|
|
14152
|
+
}
|
|
14153
|
+
}));
|
|
14154
|
+
}
|
|
14155
|
+
}));
|
|
14156
|
+
}
|
|
14157
|
+
return [4 /*yield*/, this.processStrip(strip, this.transformContentsToWidgets(courses, strip), 'done', calculateParentStatus, '', tabResults)];
|
|
14158
|
+
case 2:
|
|
14159
|
+
_a.sent();
|
|
14160
|
+
return [3 /*break*/, 4];
|
|
14161
|
+
case 3:
|
|
14162
|
+
this.processStrip(strip, this.transformContentsToWidgets(courses, strip), 'done', calculateParentStatus, 'viewMoreUrl');
|
|
14163
|
+
_a.label = 4;
|
|
14164
|
+
case 4:
|
|
14165
|
+
clearInterval(this.enrollInterval);
|
|
14166
|
+
_a.label = 5;
|
|
14167
|
+
case 5: return [2 /*return*/];
|
|
14168
|
+
}
|
|
14169
|
+
});
|
|
14170
|
+
});
|
|
14171
|
+
};
|
|
14172
|
+
/**
|
|
14173
|
+
* @param {?} contentNew
|
|
14174
|
+
* @param {?} strip
|
|
14175
|
+
* @return {?}
|
|
14176
|
+
*/
|
|
14177
|
+
ContentStripWithTabsPillsComponent.prototype.splitCbpTabsData = /**
|
|
14178
|
+
* @param {?} contentNew
|
|
14179
|
+
* @param {?} strip
|
|
14180
|
+
* @return {?}
|
|
14181
|
+
*/
|
|
14182
|
+
function (contentNew, strip) {
|
|
14183
|
+
/** @type {?} */
|
|
14184
|
+
var tabResults = [];
|
|
14185
|
+
/** @type {?} */
|
|
14186
|
+
var splitData = this.getTabsList(contentNew, strip);
|
|
14187
|
+
if (strip.tabs && strip.tabs.length) {
|
|
14188
|
+
var _loop_1 = function (i) {
|
|
14189
|
+
if (strip.tabs[i].value === "myIgotPlans") {
|
|
14190
|
+
/** @type {?} */
|
|
14191
|
+
var checkWidgetAndActivePill = true;
|
|
14192
|
+
if (strip.tabs[i].pillsData && strip.tabs[i].pillsData.length) {
|
|
14193
|
+
var _loop_2 = function (j) {
|
|
14194
|
+
// if(j === 0 ){
|
|
14195
|
+
// if(strip.tabs[i].pillsData[j].widgets && strip.tabs[i].pillsData[j].widgets.length ) {
|
|
14196
|
+
// strip.tabs[i].pillsData[j].selected = true
|
|
14197
|
+
// checkWidgetAndActivePill = false
|
|
14198
|
+
// }
|
|
14199
|
+
// strip.tabs[i].pillsData[j].selected = true
|
|
14200
|
+
// }
|
|
14201
|
+
if (strip.tabs[i].pillsData[j]) {
|
|
14202
|
+
tabResults.push(__assign({}, strip.tabs[i].pillsData[j], { fetchTabStatus: 'done' }, (splitData.find((/**
|
|
14203
|
+
* @param {?} itmInner
|
|
14204
|
+
* @return {?}
|
|
14205
|
+
*/
|
|
14206
|
+
function (itmInner) {
|
|
14207
|
+
if (strip.tabs[i].pillsData && strip.tabs[i].pillsData[j] && itmInner.value === strip.tabs[i].pillsData[j].value) {
|
|
14208
|
+
return itmInner;
|
|
14209
|
+
}
|
|
14210
|
+
return undefined;
|
|
14211
|
+
})))));
|
|
14212
|
+
}
|
|
14213
|
+
};
|
|
14214
|
+
for (var j = 0; j < strip.tabs[i].pillsData.length; j += 1) {
|
|
14215
|
+
_loop_2(j);
|
|
14216
|
+
}
|
|
14217
|
+
strip.tabs[i].pillsData = tabResults;
|
|
14218
|
+
}
|
|
14219
|
+
}
|
|
14220
|
+
};
|
|
14221
|
+
for (var i = 0; i < strip.tabs.length; i += 1) {
|
|
14222
|
+
_loop_1(i);
|
|
14223
|
+
}
|
|
14224
|
+
}
|
|
14225
|
+
return strip.tabs;
|
|
14226
|
+
};
|
|
14227
|
+
/**
|
|
14228
|
+
* @param {?} array
|
|
14229
|
+
* @param {?} strip
|
|
14230
|
+
* @return {?}
|
|
14231
|
+
*/
|
|
14232
|
+
ContentStripWithTabsPillsComponent.prototype.getTabsList = /**
|
|
14233
|
+
* @param {?} array
|
|
14234
|
+
* @param {?} strip
|
|
14235
|
+
* @return {?}
|
|
14236
|
+
*/
|
|
14237
|
+
function (array, strip) {
|
|
14238
|
+
/** @type {?} */
|
|
14239
|
+
var all = [];
|
|
14240
|
+
/** @type {?} */
|
|
14241
|
+
var upcoming = [];
|
|
14242
|
+
/** @type {?} */
|
|
14243
|
+
var overdue = [];
|
|
14244
|
+
array.forEach((/**
|
|
14245
|
+
* @param {?} e
|
|
14246
|
+
* @return {?}
|
|
14247
|
+
*/
|
|
14248
|
+
function (e) {
|
|
14249
|
+
all.push(e);
|
|
14250
|
+
if (e.planDuration === NsCardContent.ACBPConst.OVERDUE) {
|
|
14251
|
+
overdue.push(e);
|
|
14252
|
+
}
|
|
14253
|
+
else if (e.planDuration === NsCardContent.ACBPConst.UPCOMING) {
|
|
14254
|
+
upcoming.push(e);
|
|
14255
|
+
}
|
|
14256
|
+
}));
|
|
14257
|
+
/** @type {?} */
|
|
14258
|
+
var allCompleted = all.filter((/**
|
|
14259
|
+
* @param {?} allData
|
|
14260
|
+
* @return {?}
|
|
14261
|
+
*/
|
|
14262
|
+
function (allData) { return allData.contentStatus === 2; }));
|
|
14263
|
+
/** @type {?} */
|
|
14264
|
+
var allInCompleted = all.filter((/**
|
|
14265
|
+
* @param {?} allData
|
|
14266
|
+
* @return {?}
|
|
14267
|
+
*/
|
|
14268
|
+
function (allData) { return allData.contentStatus < 2; }));
|
|
14269
|
+
/** @type {?} */
|
|
14270
|
+
var allCompletedOverDue = allCompleted.filter((/**
|
|
14271
|
+
* @param {?} allData
|
|
14272
|
+
* @return {?}
|
|
14273
|
+
*/
|
|
14274
|
+
function (allData) { return allData.planDuration === NsCardContent.ACBPConst.OVERDUE; }));
|
|
14275
|
+
/** @type {?} */
|
|
14276
|
+
var allCompletedAll = allCompleted.filter((/**
|
|
14277
|
+
* @param {?} allData
|
|
14278
|
+
* @return {?}
|
|
14279
|
+
*/
|
|
14280
|
+
function (allData) { return allData.planDuration !== NsCardContent.ACBPConst.OVERDUE; }));
|
|
14281
|
+
allCompletedOverDue = allCompletedOverDue.sort((/**
|
|
14282
|
+
* @param {?} a
|
|
14283
|
+
* @param {?} b
|
|
14284
|
+
* @return {?}
|
|
14285
|
+
*/
|
|
14286
|
+
function (a, b) {
|
|
14287
|
+
if (a.planDuration === NsCardContent.ACBPConst.OVERDUE && b.planDuration === NsCardContent.ACBPConst.OVERDUE) {
|
|
14288
|
+
/** @type {?} */
|
|
14289
|
+
var firstDate = new Date(a.endDate);
|
|
14290
|
+
/** @type {?} */
|
|
14291
|
+
var secondDate = new Date(b.endDate);
|
|
14292
|
+
return firstDate > secondDate ? -1 : 1;
|
|
14293
|
+
}
|
|
14294
|
+
}));
|
|
14295
|
+
allInCompleted = allInCompleted.sort((/**
|
|
14296
|
+
* @param {?} a
|
|
14297
|
+
* @param {?} b
|
|
14298
|
+
* @return {?}
|
|
14299
|
+
*/
|
|
14300
|
+
function (a, b) {
|
|
14301
|
+
if (a.planDuration === NsCardContent.ACBPConst.OVERDUE && b.planDuration === NsCardContent.ACBPConst.OVERDUE) {
|
|
14302
|
+
/** @type {?} */
|
|
14303
|
+
var firstDate = new Date(a.endDate);
|
|
14304
|
+
/** @type {?} */
|
|
14305
|
+
var secondDate = new Date(b.endDate);
|
|
14306
|
+
return firstDate > secondDate ? -1 : 1;
|
|
14307
|
+
}
|
|
14308
|
+
}));
|
|
14309
|
+
all = __spread(allInCompleted, allCompletedAll, allCompletedOverDue);
|
|
14310
|
+
overdue = overdue.filter((/**
|
|
14311
|
+
* @param {?} data
|
|
14312
|
+
* @return {?}
|
|
14313
|
+
*/
|
|
14314
|
+
function (data) {
|
|
14315
|
+
return data.contentStatus < 2;
|
|
14316
|
+
}));
|
|
14317
|
+
overdue = overdue.sort((/**
|
|
14318
|
+
* @param {?} a
|
|
14319
|
+
* @param {?} b
|
|
14320
|
+
* @return {?}
|
|
14321
|
+
*/
|
|
14322
|
+
function (a, b) {
|
|
14323
|
+
/** @type {?} */
|
|
14324
|
+
var firstDate = new Date(a.endDate);
|
|
14325
|
+
/** @type {?} */
|
|
14326
|
+
var secondDate = new Date(b.endDate);
|
|
14327
|
+
return firstDate > secondDate ? -1 : 1;
|
|
14328
|
+
}));
|
|
14329
|
+
upcoming = upcoming.filter((/**
|
|
14330
|
+
* @param {?} data
|
|
14331
|
+
* @return {?}
|
|
14332
|
+
*/
|
|
14333
|
+
function (data) {
|
|
14334
|
+
return data.contentStatus < 2;
|
|
14335
|
+
}));
|
|
14336
|
+
return [
|
|
14337
|
+
{ value: 'all', widgets: this.transformContentsToWidgets(all, strip) },
|
|
14338
|
+
{ value: 'upcoming', widgets: this.transformContentsToWidgets(upcoming, strip) },
|
|
14339
|
+
{ value: 'completed', widgets: this.transformContentsToWidgets(allCompleted, strip) },
|
|
14340
|
+
{ value: 'overdue', widgets: this.transformContentsToWidgets(overdue, strip) }
|
|
14341
|
+
];
|
|
14342
|
+
};
|
|
14343
|
+
/**
|
|
14344
|
+
* @param {?} pillData
|
|
14345
|
+
* @return {?}
|
|
14346
|
+
*/
|
|
14347
|
+
ContentStripWithTabsPillsComponent.prototype.resetSelectedPill = /**
|
|
14348
|
+
* @param {?} pillData
|
|
14349
|
+
* @return {?}
|
|
14350
|
+
*/
|
|
14351
|
+
function (pillData) {
|
|
14352
|
+
if (pillData && pillData.length) {
|
|
14353
|
+
pillData.forEach((/**
|
|
14354
|
+
* @param {?} pill
|
|
14355
|
+
* @return {?}
|
|
14356
|
+
*/
|
|
14357
|
+
function (pill) {
|
|
14358
|
+
pill['selected'] = false;
|
|
14359
|
+
}));
|
|
14360
|
+
}
|
|
14361
|
+
};
|
|
14362
|
+
ContentStripWithTabsPillsComponent.decorators = [
|
|
14363
|
+
{ type: core.Component, args: [{
|
|
14364
|
+
selector: 'sb-uic-content-strip-with-tabs-pills',
|
|
14365
|
+
template: "<ng-container *ngIf=\"!contentAvailable; else otherTemplate\"></ng-container>\n<ng-template #otherTemplate>\n <!-- <div *ngIf=\"showParentLoader\" class=\"text-center my-2\">\n <mat-spinner class=\"inline-block\"></mat-spinner>\n </div> -->\n <ng-container *ngIf=\"showParentError\" [sbUiResolverWidget]=\"widgetData.errorWidget\"></ng-container>\n <ng-container *ngIf=\"showParentNoData\" [sbUiResolverWidget]=\"widgetData.noDataWidget\"></ng-container>\n <ng-container *ngFor=\"let key of stripsKeyOrder; let i = index; trackBy: identify\">\n <ng-container *ngIf=\"isStripShowing(stripsResultDataMap[key])\">\n <a name=\"{{stripsResultDataMap[key]?.stripTitle}}\" [class]=\"key\">\n <div *ngIf=\"stripsResultDataMap && (getLength(stripsResultDataMap[key]) ||\n stripsResultDataMap[key]?.showOnNoData ||\n stripsResultDataMap[key]?.showOnLoader ||\n stripsResultDataMap[key]?.showOnError)\n \" [ngClass]=\"\n !widgetData?.isChannelStrip ? 'xs:px-8 sx:px-10ss' : i > 0 ? 'mt-12' : ''\n \" [id]=\"key\" [ngClass]=\"!widgetData?.isChannelStrip ? margin-bottom-custom : margin-bottom-xs\">\n <div [ngClass]=\"{ pad: stripsResultDataMap[key]?.stripBackground }\"\n [ngStyle]=\"{ 'background-color': stripsResultDataMap[key]?.stripBackground }\">\n <div class=\"flex flex-col pl-4 pr-4 md:pr-0 md:pl-0 \" [ngClass]=\"\n !widgetData?.isChannelStrip\n ? ''\n : stripsResultDataMap[key]?.stripTitle\n ? 'mb-8'\n : ''\n \">\n <div class=\"flex flex-1 items-center\">\n <p class=\"mat-subheading-1 margin-remove inline-block \" *ngIf=\"stripsResultDataMap[key]?.stripTitle\">\n <span class=\"capitalize\" *ngIf=\"stripsResultDataMap[key]?.disableTranslate\">\n {{stripsResultDataMap[key]?.stripTitle}}\n </span>\n <span *ngIf=\"!stripsResultDataMap[key]?.disableTranslate\">\n {{ translateLabels(stripsResultDataMap[key]?.stripTitle, 'home') }}\n </span>\n </p>\n\n <button *ngIf=\"stripsResultDataMap[key]?.stripInfo?.icon\" type=\"button\" mat-icon-button\n (click)=\"toggleInfo(stripsResultDataMap[key])\" i18n-matTooltip matTooltip=\"info\"\n class=\"margin-left-xs\">\n <mat-icon>{{ stripsResultDataMap[key]?.stripInfo?.icon.icon }}</mat-icon>\n </button>\n <a *ngIf=\"stripsResultDataMap[key]?.stripTitleLink?.link\"\n [routerLink]=\"stripsResultDataMap[key]?.stripTitleLink?.link\"\n [queryParams]=\"stripsResultDataMap[key]?.stripTitleLink?.link?.queryParams\">\n <mat-icon class=\"ws-mat-primary-primary-text ws-mat-default-text\" [color]=\"'accent'\">{{\n stripsResultDataMap[key]?.stripTitleLink?.icon }}</mat-icon>\n </a>\n <span class=\"spacer\"></span>\n <!-- viewAll start-->\n <!-- <div *ngIf=\"checkCondition(widgetData , stripsResultDataMap[key])\"\n class=\"ml-4 pl-2 view-more ws-mat-default-text\">\n <a class=\"flex ws-mat-default-text items-center justify-center mat-body-1 cursor-pointer\" \n (click)=\"raiseTelemetry(stripsResultDataMap[key]);redirectViewAll(stripsResultDataMap[key], stripsResultDataMap[key]?.viewMoreUrl?.path, stripsResultDataMap[key]?.viewMoreUrl?.queryParams )\">\n <span i18n class=\"ws-mat-default-text\">{{translateLabels(widgetData.strips[0].viewMoreUrl.viewMoreText,'home') || 'See all'}}</span>\n <mat-icon class=\"ws-mat-default-text mat-icon notranslate material-icons mat-icon-no-color\" color=\"accent\">navigate_next</mat-icon>\n </a>\n </div> -->\n <!-- viewAll end-->\n </div>\n <button mat-icon-button (click)=\"setHiddenForStrip(key)\" *ngIf=\"stripsResultDataMap[key]?.canHideStrip\">\n <mat-icon>close</mat-icon>\n </button>\n <mat-icon class=\"cursor-pointer\" *ngIf=\"stripsResultDataMap[key]?.mode === 'accordion' && isMobile\"\n (click)=\"showAccordionData = !showAccordionData\">{{ showAccordionData ? 'expand_less' : 'expand_more' }}\n </mat-icon>\n </div>\n\n <div class=\"mb-4\" *ngIf=\"checkVisible(stripsResultDataMap[key])\">\n <ng-container [sbUiResolverWidget]=\"getdata(stripsResultDataMap[key])\">\n </ng-container>\n </div>\n <ng-container *ngIf=\"stripsResultDataMap[key]?.showOnNoData\"\n [sbUiResolverWidget]=\"stripsResultDataMap[key]?.noDataWidget\"></ng-container>\n <ng-container *ngIf=\"stripsResultDataMap[key]?.showOnError\"\n [sbUiResolverWidget]=\"stripsResultDataMap[key]?.errorWidget\"></ng-container>\n <!-- IF no errors then proceed to show tabs or non tabs strip -->\n <ng-container *ngIf=\"!stripsResultDataMap[key]?.showOnNoData && !stripsResultDataMap[key]?.showOnError\">\n <ng-container *ngIf=\"stripsResultDataMap[key].tabs && stripsResultDataMap[key].tabs.length\">\n <mat-tab-group animationDuration=\"0ms\" [selectedIndex]=\"getSelectedIndex(stripsResultDataMap[key], key)\"\n class=\"mat-tab-labels w-full strips-tabgroup\" dynamicHeight\n (selectedTabChange)=\"tabClicked($event, 0, stripsResultDataMap[key], key)\">\n <mat-tab label=\"{{tab?.label}}\" *ngFor=\"let tab of stripsResultDataMap[key].tabs; let last = last;let tabIndex = index\">\n <ng-template mat-tab-label>\n <span>{{ translateLabels(tab?.label, 'home') }} </span>\n <span *ngIf=\"tab?.showTabDataCount && tab?.widgets?.length\">({{tab?.widgets?.length}})</span>\n </ng-template>\n\n <div class=\"wfull\" *ngIf=\"tab?.pillsData && tab?.pillsData?.length\">\n <div class=\"flex justify-between\">\n <div>\n <ng-container >\n <mat-chip-list class=\"content-pill\" aria-label=\"Fish selection\">\n <ng-container *ngFor=\"let pill of tab?.pillsData;let p = index\">\n <mat-chip [selected]=\"pill?.selected\" (click)=\"pillClicked($event, stripsResultDataMap[key], key, p, tabIndex)\">\n <span class=\"pill-name\">{{pill?.label}}</span></mat-chip>\n </ng-container>\n </mat-chip-list>\n </ng-container>\n </div>\n <!-- viewAll start-->\n <div *ngIf=\"checkCondition(widgetData , stripsResultDataMap[key])\"\n class=\"ml-4 pl-2 view-more ws-mat-default-text\">\n <a class=\"flex ws-mat-default-text items-center justify-center mat-body-1 cursor-pointer\" \n (click)=\"raiseTelemetry(stripsResultDataMap[key]);redirectViewAll(stripsResultDataMap[key], stripsResultDataMap[key]?.viewMoreUrl?.path, stripsResultDataMap[key]?.viewMoreUrl?.queryParams )\">\n <span i18n class=\"ws-mat-default-text\">{{translateLabels(widgetData.strips[0].viewMoreUrl.viewMoreText,'home') || 'See all'}}</span>\n <mat-icon class=\"ws-mat-default-text mat-icon notranslate material-icons mat-icon-no-color\" color=\"accent\">navigate_next</mat-icon>\n </a>\n </div>\n <!-- viewAll end-->\n </div>\n <div *ngIf=\"stripsResultDataMap && stripsResultDataMap[key]?.showOnLoader ||\n !tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.fetchTabStatus\"\n class=\"text-center my-2\">\n <sb-uic-horizontal-scroller-v2 [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\" [id]=\"key+'-scroller'\"\n [loadStatus]=\"'fetching'\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.loaderWidgets; trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n <ng-container *ngIf=\"tab?.pillsData && tab?.pillsData.length && tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]\">\n <div *ngIf=\"((tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.fetchTabStatus && tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.fetchTabStatus === 'done') &&\n (!tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.widgets || !tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.widgets?.length))\">\n <ng-container *ngIf=\"tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.value === 'inprogress'; else msgTemp\">\n <div class=\"w-full flex flex-col items-center justify-center\">\n <img alt=\"\" class=\"mt-4 mb-4\" src=\"assets/icons/home/nodataDefault.svg\">\n <div class=\"mat-subheading-1 text-center info-content\">{{ 'contentstripmultiple.getReadyForLearningAdventure' | translate }} -\n <a class=\"click-here\" [routerLink]=\"'/page/learn'\">{{ 'contentstripmultiple.clickHere' | translate }}</a> {{ 'contentstripmultiple.toEnrollNextCourse' | translate }}</div>\n </div>\n </ng-container>\n <ng-template #msgTemp>\n <div class=\"w-full flex flex-col items-center justify-center\">\n <img alt=\"\" class=\"mt-4 mb-4\" src=\"assets/icons/home/nodataDefault.png\">\n <div class=\"mat-subheading-1 text-center\">{{ translateLabels(tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.nodataMsg, 'home') }}</div>\n </div>\n </ng-template>\n </div>\n </ng-container>\n <ng-container *ngIf=\"(tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.fetchTabStatus === 'done' || tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.widgets?.length)\">\n <ng-container *ngIf=\"!tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.tabLoading\">\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\" [widgetsLength]=\"tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.widgets?.length\"\n *ngIf=\"getContineuLearningLenth(stripsResultDataMap[key]) && showAccordion(key)\"\n [loadStatus]=\"'done'\" [defaultMaxWidgets]=\"tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.maxWidgets ||\n stripsResultDataMap[key]?.sliderConfig?.maxWidgets || defaultMaxWidgets\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.widgets| slice:0:(tab?.pillsData[getSelectedPillIndex(tab ,tabIndex)]?.maxWidgets ||\n stripsResultDataMap[key]?.sliderConfig?.maxWidgets || defaultMaxWidgets); trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </ng-container>\n </ng-container>\n </div>\n </mat-tab>\n </mat-tab-group>\n </ng-container>\n </ng-container>\n </div>\n </div>\n </a>\n\n </ng-container>\n </ng-container>\n</ng-template>",
|
|
14366
|
+
styles: [".view-more{display:flex;align-items:center;text-align:center;height:40px;justify-content:center}.view-more .icon{font-size:24px;width:24px;height:24px;border:1px solid;border-radius:50%;padding:8px;margin-bottom:8px}.margin-bottom-custom{margin-bottom:60px}.view-more:hover{background-color:#dcdfe5}::ng-deep.strips-tabgroup .mat-tab-header{border-bottom:2px solid rgba(0,0,0,.12)}::ng-deep.strips-tabgroup .mat-tab-body{padding:20px 0!important;box-sizing:border-box;overflow-y:initial!important}::ng-deep.strips-tabgroup .mat-tab-body-wrapper{overflow:inherit!important}::ng-deep.strips-tabgroup .mat-tab-label{border-bottom:0 solid rgba(0,0,0,.1);margin-right:0;opacity:1}::ng-deep.strips-tabgroup .mat-tab-label .mat-tab-label-content{text-transform:inherit;font:400 14px/20px Lato}::ng-deep.strips-tabgroup .mat-tab-label-active .mat-tab-label-content{font-weight:700!important}.click-here{color:#1b4ca1}.info-content{opacity:1;color:rgba(0,0,0,.87);font:700 14px/20px Lato-Bold;text-align:center}.active{background:#1b4ca1!important}.active .pill-name{color:#fff!important}::ng-deep .content-pill .mat-chip-selected{background-color:#1b4ca1!important}::ng-deep .content-pill .mat-chip-selected .pill-name{color:#fff!important}"]
|
|
14367
|
+
}] }
|
|
14368
|
+
];
|
|
14369
|
+
/** @nocollapse */
|
|
14370
|
+
ContentStripWithTabsPillsComponent.ctorParameters = function () { return [
|
|
14371
|
+
{ type: undefined, decorators: [{ type: core.Inject, args: ['environment',] }] },
|
|
14372
|
+
{ type: WidgetContentService },
|
|
14373
|
+
{ type: utilsV2.LoggerService },
|
|
14374
|
+
{ type: utilsV2.EventService },
|
|
14375
|
+
{ type: utilsV2.ConfigurationsService },
|
|
14376
|
+
{ type: utilsV2.UtilityService },
|
|
14377
|
+
{ type: router.Router },
|
|
14378
|
+
{ type: WidgetUserService },
|
|
14379
|
+
{ type: core$1.TranslateService },
|
|
14380
|
+
{ type: MultilingualTranslationsService }
|
|
14381
|
+
]; };
|
|
14382
|
+
ContentStripWithTabsPillsComponent.propDecorators = {
|
|
14383
|
+
widgetData: [{ type: core.Input }],
|
|
14384
|
+
emptyResponse: [{ type: core.Output }],
|
|
14385
|
+
viewAllResponse: [{ type: core.Output }],
|
|
14386
|
+
telemtryResponse: [{ type: core.Output }],
|
|
14387
|
+
providerId: [{ type: core.Input }],
|
|
14388
|
+
emitViewAll: [{ type: core.Input }],
|
|
14389
|
+
channnelName: [{ type: core.Input }],
|
|
14390
|
+
id: [{ type: core.HostBinding, args: ['id',] }]
|
|
14391
|
+
};
|
|
14392
|
+
return ContentStripWithTabsPillsComponent;
|
|
14393
|
+
}(resolverV2.WidgetBaseComponent));
|
|
14394
|
+
if (false) {
|
|
14395
|
+
/** @type {?} */
|
|
14396
|
+
ContentStripWithTabsPillsComponent.prototype.widgetData;
|
|
14397
|
+
/** @type {?} */
|
|
14398
|
+
ContentStripWithTabsPillsComponent.prototype.emptyResponse;
|
|
14399
|
+
/** @type {?} */
|
|
14400
|
+
ContentStripWithTabsPillsComponent.prototype.viewAllResponse;
|
|
14401
|
+
/** @type {?} */
|
|
14402
|
+
ContentStripWithTabsPillsComponent.prototype.telemtryResponse;
|
|
14403
|
+
/** @type {?} */
|
|
14404
|
+
ContentStripWithTabsPillsComponent.prototype.providerId;
|
|
14405
|
+
/** @type {?} */
|
|
14406
|
+
ContentStripWithTabsPillsComponent.prototype.emitViewAll;
|
|
14407
|
+
/** @type {?} */
|
|
14408
|
+
ContentStripWithTabsPillsComponent.prototype.channnelName;
|
|
14409
|
+
/** @type {?} */
|
|
14410
|
+
ContentStripWithTabsPillsComponent.prototype.id;
|
|
14411
|
+
/** @type {?} */
|
|
14412
|
+
ContentStripWithTabsPillsComponent.prototype.stripsResultDataMap;
|
|
14413
|
+
/** @type {?} */
|
|
14414
|
+
ContentStripWithTabsPillsComponent.prototype.stripsKeyOrder;
|
|
14415
|
+
/** @type {?} */
|
|
14416
|
+
ContentStripWithTabsPillsComponent.prototype.showAccordionData;
|
|
14417
|
+
/** @type {?} */
|
|
14418
|
+
ContentStripWithTabsPillsComponent.prototype.showParentLoader;
|
|
14419
|
+
/** @type {?} */
|
|
14420
|
+
ContentStripWithTabsPillsComponent.prototype.showParentError;
|
|
14421
|
+
/** @type {?} */
|
|
14422
|
+
ContentStripWithTabsPillsComponent.prototype.showParentNoData;
|
|
14423
|
+
/** @type {?} */
|
|
14424
|
+
ContentStripWithTabsPillsComponent.prototype.errorDataCount;
|
|
14425
|
+
/** @type {?} */
|
|
14426
|
+
ContentStripWithTabsPillsComponent.prototype.noDataCount;
|
|
14427
|
+
/** @type {?} */
|
|
14428
|
+
ContentStripWithTabsPillsComponent.prototype.successDataCount;
|
|
14429
|
+
/** @type {?} */
|
|
14430
|
+
ContentStripWithTabsPillsComponent.prototype.contentAvailable;
|
|
14431
|
+
/** @type {?} */
|
|
14432
|
+
ContentStripWithTabsPillsComponent.prototype.baseUrl;
|
|
14433
|
+
/** @type {?} */
|
|
14434
|
+
ContentStripWithTabsPillsComponent.prototype.veifiedKarmayogi;
|
|
14435
|
+
/** @type {?} */
|
|
14436
|
+
ContentStripWithTabsPillsComponent.prototype.environment;
|
|
14437
|
+
/** @type {?} */
|
|
14438
|
+
ContentStripWithTabsPillsComponent.prototype.changeEventSubscription;
|
|
14439
|
+
/** @type {?} */
|
|
14440
|
+
ContentStripWithTabsPillsComponent.prototype.defaultMaxWidgets;
|
|
14441
|
+
/** @type {?} */
|
|
14442
|
+
ContentStripWithTabsPillsComponent.prototype.enrollInterval;
|
|
14443
|
+
/** @type {?} */
|
|
14444
|
+
ContentStripWithTabsPillsComponent.prototype.todaysEvents;
|
|
14445
|
+
/** @type {?} */
|
|
14446
|
+
ContentStripWithTabsPillsComponent.prototype.enrollmentMapData;
|
|
14447
|
+
/**
|
|
14448
|
+
* @type {?}
|
|
14449
|
+
* @private
|
|
14450
|
+
*/
|
|
14451
|
+
ContentStripWithTabsPillsComponent.prototype.contentSvc;
|
|
14452
|
+
/**
|
|
14453
|
+
* @type {?}
|
|
14454
|
+
* @private
|
|
14455
|
+
*/
|
|
14456
|
+
ContentStripWithTabsPillsComponent.prototype.loggerSvc;
|
|
14457
|
+
/**
|
|
14458
|
+
* @type {?}
|
|
14459
|
+
* @private
|
|
14460
|
+
*/
|
|
14461
|
+
ContentStripWithTabsPillsComponent.prototype.eventSvc;
|
|
14462
|
+
/**
|
|
14463
|
+
* @type {?}
|
|
14464
|
+
* @private
|
|
14465
|
+
*/
|
|
14466
|
+
ContentStripWithTabsPillsComponent.prototype.configSvc;
|
|
14467
|
+
/** @type {?} */
|
|
14468
|
+
ContentStripWithTabsPillsComponent.prototype.utilitySvc;
|
|
14469
|
+
/** @type {?} */
|
|
14470
|
+
ContentStripWithTabsPillsComponent.prototype.router;
|
|
14471
|
+
/**
|
|
14472
|
+
* @type {?}
|
|
14473
|
+
* @private
|
|
14474
|
+
*/
|
|
14475
|
+
ContentStripWithTabsPillsComponent.prototype.userSvc;
|
|
14476
|
+
/**
|
|
14477
|
+
* @type {?}
|
|
14478
|
+
* @private
|
|
14479
|
+
*/
|
|
14480
|
+
ContentStripWithTabsPillsComponent.prototype.translate;
|
|
14481
|
+
/**
|
|
14482
|
+
* @type {?}
|
|
14483
|
+
* @private
|
|
14484
|
+
*/
|
|
14485
|
+
ContentStripWithTabsPillsComponent.prototype.langtranslations;
|
|
14486
|
+
}
|
|
14487
|
+
|
|
14488
|
+
/**
|
|
14489
|
+
* @fileoverview added by tsickle
|
|
14490
|
+
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
14491
|
+
*/
|
|
14492
|
+
// tslint:disable-next-line:function-name
|
|
14493
|
+
/**
|
|
14494
|
+
* @param {?} http
|
|
14495
|
+
* @return {?}
|
|
14496
|
+
*/
|
|
14497
|
+
function HttpLoaderFactory1(http) {
|
|
14498
|
+
return new httpLoader.TranslateHttpLoader(http);
|
|
14499
|
+
}
|
|
14500
|
+
var ContentStripWithTabsPillsModule = /** @class */ (function () {
|
|
14501
|
+
function ContentStripWithTabsPillsModule() {
|
|
14502
|
+
}
|
|
14503
|
+
ContentStripWithTabsPillsModule.decorators = [
|
|
14504
|
+
{ type: core.NgModule, args: [{
|
|
14505
|
+
declarations: [ContentStripWithTabsPillsComponent],
|
|
14506
|
+
imports: [
|
|
14507
|
+
resolverV2.SbUiResolverModule,
|
|
14508
|
+
common.CommonModule,
|
|
14509
|
+
router.RouterModule,
|
|
14510
|
+
HorizontalScrollerV2Module,
|
|
14511
|
+
material.MatProgressSpinnerModule,
|
|
14512
|
+
material.MatToolbarModule,
|
|
14513
|
+
material.MatIconModule,
|
|
14514
|
+
material.MatButtonModule,
|
|
14515
|
+
material.MatTooltipModule,
|
|
14516
|
+
material.MatListModule,
|
|
14517
|
+
material.MatSidenavModule,
|
|
14518
|
+
material.MatCardModule,
|
|
14519
|
+
material.MatExpansionModule,
|
|
14520
|
+
material.MatRadioModule,
|
|
14521
|
+
material.MatChipsModule,
|
|
14522
|
+
material.MatInputModule,
|
|
14523
|
+
material.MatFormFieldModule,
|
|
14524
|
+
material.MatDialogModule,
|
|
14525
|
+
material.MatSnackBarModule,
|
|
14526
|
+
material.MatSelectModule,
|
|
14527
|
+
material.MatDatepickerModule,
|
|
14528
|
+
material.MatNativeDateModule,
|
|
14529
|
+
material.MatTableModule,
|
|
14530
|
+
material.MatCheckboxModule,
|
|
14531
|
+
material.MatProgressSpinnerModule,
|
|
14532
|
+
material.MatButtonToggleModule,
|
|
14533
|
+
material.MatTabsModule,
|
|
14534
|
+
material.MatAutocompleteModule,
|
|
14535
|
+
core$1.TranslateModule.forRoot({
|
|
14536
|
+
loader: {
|
|
14537
|
+
provide: core$1.TranslateLoader,
|
|
14538
|
+
useFactory: HttpLoaderFactory1,
|
|
14539
|
+
deps: [http.HttpClient],
|
|
14540
|
+
},
|
|
14541
|
+
}),
|
|
14542
|
+
],
|
|
14543
|
+
entryComponents: [ContentStripWithTabsPillsComponent],
|
|
14544
|
+
exports: [ContentStripWithTabsPillsComponent],
|
|
14545
|
+
},] }
|
|
14546
|
+
];
|
|
14547
|
+
return ContentStripWithTabsPillsModule;
|
|
14548
|
+
}());
|
|
14549
|
+
|
|
12596
14550
|
/**
|
|
12597
14551
|
* @fileoverview added by tsickle
|
|
12598
14552
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
@@ -14457,8 +16411,10 @@
|
|
|
14457
16411
|
exports.ConsumptionService = ConsumptionService;
|
|
14458
16412
|
exports.ContentProgressModule = ContentProgressModule;
|
|
14459
16413
|
exports.ContentStripWithTabsLibModule = ContentStripWithTabsLibModule;
|
|
16414
|
+
exports.ContentStripWithTabsPillsModule = ContentStripWithTabsPillsModule;
|
|
14460
16415
|
exports.DataPointsModule = DataPointsModule;
|
|
14461
16416
|
exports.HttpLoaderFactory = HttpLoaderFactory;
|
|
16417
|
+
exports.HttpLoaderFactory1 = HttpLoaderFactory1;
|
|
14462
16418
|
exports.MyHammerConfig = MyHammerConfig;
|
|
14463
16419
|
exports.ROOT_WIDGET_CONFIG = ROOT_WIDGET_CONFIG;
|
|
14464
16420
|
exports.SlidersLibModule = SlidersLibModule;
|
|
@@ -14492,21 +16448,22 @@
|
|
|
14492
16448
|
exports.ɵbv = CertificateDialogComponent;
|
|
14493
16449
|
exports.ɵbw = AvatarPhotoLibModule;
|
|
14494
16450
|
exports.ɵbx = AvatarPhotoLibComponent;
|
|
14495
|
-
exports.ɵby =
|
|
14496
|
-
exports.ɵbz =
|
|
16451
|
+
exports.ɵby = ContentStripWithTabsPillsComponent;
|
|
16452
|
+
exports.ɵbz = CompetencyPassbookComponent;
|
|
14497
16453
|
exports.ɵc = MultilingualTranslationsService;
|
|
14498
|
-
exports.ɵca =
|
|
14499
|
-
exports.ɵcb =
|
|
14500
|
-
exports.ɵcc =
|
|
14501
|
-
exports.ɵcd =
|
|
14502
|
-
exports.ɵce =
|
|
14503
|
-
exports.ɵcf =
|
|
14504
|
-
exports.ɵcg =
|
|
14505
|
-
exports.ɵch =
|
|
14506
|
-
exports.ɵci =
|
|
14507
|
-
exports.ɵcj =
|
|
14508
|
-
exports.ɵck =
|
|
14509
|
-
exports.ɵcl =
|
|
16454
|
+
exports.ɵca = CompetencyPassbookService;
|
|
16455
|
+
exports.ɵcb = PillsModule;
|
|
16456
|
+
exports.ɵcc = PillsComponent;
|
|
16457
|
+
exports.ɵcd = CompetencyPassbookMdoComponent;
|
|
16458
|
+
exports.ɵce = CompetencyPassbookMdoService;
|
|
16459
|
+
exports.ɵcf = UserContentRatingLibComponent;
|
|
16460
|
+
exports.ɵcg = ScrollableItemDirective;
|
|
16461
|
+
exports.ɵch = RatingService;
|
|
16462
|
+
exports.ɵci = UserContentRatingLibService;
|
|
16463
|
+
exports.ɵcj = MyHammerConfig$1;
|
|
16464
|
+
exports.ɵck = SlidersNgContentLibModule;
|
|
16465
|
+
exports.ɵcl = SlidersNgContentLibComponent;
|
|
16466
|
+
exports.ɵcm = ScrollableItemModule;
|
|
14510
16467
|
exports.ɵd = ConfigurationsService;
|
|
14511
16468
|
exports.ɵe = HorizontalScrollerV2Module;
|
|
14512
16469
|
exports.ɵf = HorizontalScrollerV2Component;
|