@sunbird-cb/consumption 0.0.34 → 0.0.36
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 +318 -49
- 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-portrait-ext/card-portrait-ext.component.js +167 -0
- package/esm2015/lib/_common/cards/card-wide/card-wide.component.js +3 -3
- package/esm2015/lib/_common/cards/cards.component.js +25 -8
- package/esm2015/lib/_common/cards/cards.module.js +4 -2
- package/esm2015/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.js +98 -18
- package/esm2015/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.model.js +1 -1
- package/esm2015/sunbird-cb-consumption.js +23 -22
- package/esm5/lib/_common/cards/card-portrait-ext/card-portrait-ext.component.js +173 -0
- package/esm5/lib/_common/cards/card-wide/card-wide.component.js +3 -3
- package/esm5/lib/_common/cards/cards.component.js +19 -8
- package/esm5/lib/_common/cards/cards.module.js +4 -2
- package/esm5/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.js +109 -19
- package/esm5/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.model.js +1 -1
- package/esm5/sunbird-cb-consumption.js +23 -22
- package/fesm2015/sunbird-cb-consumption.js +286 -27
- package/fesm2015/sunbird-cb-consumption.js.map +1 -1
- package/fesm5/sunbird-cb-consumption.js +296 -28
- package/fesm5/sunbird-cb-consumption.js.map +1 -1
- package/lib/_common/cards/card-portrait-ext/card-portrait-ext.component.d.ts +33 -0
- package/lib/_common/cards/cards.component.d.ts +1 -2
- package/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.d.ts +1 -0
- package/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.model.d.ts +1 -0
- package/package.json +1 -1
- package/sunbird-cb-consumption.d.ts +22 -21
- package/sunbird-cb-consumption.metadata.json +1 -1
|
@@ -4185,6 +4185,7 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
4185
4185
|
this.fetchAllBookMarkData(strip, calculateParentStatus);
|
|
4186
4186
|
this.fetchAllPlaylistSearch(strip, calculateParentStatus);
|
|
4187
4187
|
this.fetchPlaylistReadData(strip, calculateParentStatus);
|
|
4188
|
+
this.fetchCiosContentData(strip, calculateParentStatus);
|
|
4188
4189
|
// this.enrollInterval = setInterval(() => {
|
|
4189
4190
|
// this.fetchAllCbpPlans(strip, calculateParentStatus)
|
|
4190
4191
|
// }, 1000)
|
|
@@ -4921,7 +4922,8 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
4921
4922
|
(strip.request.featureContent && Object.keys(strip.request.featureContent).length) ||
|
|
4922
4923
|
(strip.request.bookmarkRead && Object.keys(strip.request.bookmarkRead).length) ||
|
|
4923
4924
|
(strip.request.playlistSearch && Object.keys(strip.request.playlistSearch).length) ||
|
|
4924
|
-
(strip.request.playlistRead && Object.keys(strip.request.playlistRead).length)
|
|
4925
|
+
(strip.request.playlistRead && Object.keys(strip.request.playlistRead).length) ||
|
|
4926
|
+
(strip.request.ciosContent && Object.keys(strip.request.ciosContent).length))) {
|
|
4925
4927
|
return true;
|
|
4926
4928
|
}
|
|
4927
4929
|
return false;
|
|
@@ -5549,10 +5551,8 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5549
5551
|
*/
|
|
5550
5552
|
function (strip, request, apiUrl, calculateParentStatus) {
|
|
5551
5553
|
return __awaiter(this, void 0, void 0, function () {
|
|
5552
|
-
var originalFilters;
|
|
5553
5554
|
var _this = this;
|
|
5554
5555
|
return __generator(this, function (_a) {
|
|
5555
|
-
originalFilters = [];
|
|
5556
5556
|
return [2 /*return*/, new Promise((/**
|
|
5557
5557
|
* @param {?} resolve
|
|
5558
5558
|
* @param {?} reject
|
|
@@ -5565,25 +5565,37 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5565
5565
|
* @return {?}
|
|
5566
5566
|
*/
|
|
5567
5567
|
function (results) {
|
|
5568
|
-
|
|
5569
|
-
|
|
5570
|
-
|
|
5571
|
-
|
|
5572
|
-
|
|
5568
|
+
if (results.result && results.result.content) {
|
|
5569
|
+
/** @type {?} */
|
|
5570
|
+
var showViewMore = Boolean(results.result.content && results.result.content.length > 5 && strip.stripConfig && strip.stripConfig.postCardForSearch);
|
|
5571
|
+
/** @type {?} */
|
|
5572
|
+
var viewMoreUrl = showViewMore
|
|
5573
|
+
? {
|
|
5574
|
+
path: strip.viewMoreUrl && strip.viewMoreUrl.path || '',
|
|
5575
|
+
queryParams: {
|
|
5576
|
+
tab: 'Learn',
|
|
5577
|
+
q: strip.viewMoreUrl && strip.viewMoreUrl.queryParams,
|
|
5578
|
+
f: {},
|
|
5579
|
+
},
|
|
5580
|
+
}
|
|
5581
|
+
: null;
|
|
5582
|
+
resolve({ results: results, viewMoreUrl: viewMoreUrl });
|
|
5583
|
+
}
|
|
5584
|
+
else if (results && results.data) {
|
|
5585
|
+
/** @type {?} */
|
|
5586
|
+
var showViewMore = Boolean(results.data && results.data.length > 5 && strip.stripConfig && strip.stripConfig.postCardForSearch);
|
|
5587
|
+
/** @type {?} */
|
|
5588
|
+
var viewMoreUrl = showViewMore ? {
|
|
5573
5589
|
path: strip.viewMoreUrl && strip.viewMoreUrl.path || '',
|
|
5574
5590
|
queryParams: {
|
|
5575
5591
|
tab: 'Learn',
|
|
5576
5592
|
q: strip.viewMoreUrl && strip.viewMoreUrl.queryParams,
|
|
5577
|
-
f:
|
|
5578
|
-
request.searchV6 &&
|
|
5579
|
-
request.searchV6.request &&
|
|
5580
|
-
request.searchV6.request.filters
|
|
5581
|
-
? JSON.stringify(_this.transformSearchV6FiltersV2(originalFilters))
|
|
5582
|
-
: {},
|
|
5593
|
+
f: {},
|
|
5583
5594
|
},
|
|
5584
5595
|
}
|
|
5585
|
-
|
|
5586
|
-
|
|
5596
|
+
: null;
|
|
5597
|
+
resolve({ results: results, viewMoreUrl: viewMoreUrl });
|
|
5598
|
+
}
|
|
5587
5599
|
}), (/**
|
|
5588
5600
|
* @param {?} error
|
|
5589
5601
|
* @return {?}
|
|
@@ -5801,7 +5813,7 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5801
5813
|
function (strip, calculateParentStatus) {
|
|
5802
5814
|
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5803
5815
|
return __awaiter(this, void 0, void 0, function () {
|
|
5804
|
-
var originalFilters, response, error_8;
|
|
5816
|
+
var originalFilters, response, finalPlaylistData_1, programData, error_8;
|
|
5805
5817
|
return __generator(this, function (_a) {
|
|
5806
5818
|
switch (_a.label) {
|
|
5807
5819
|
case 0:
|
|
@@ -5824,7 +5836,23 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5824
5836
|
if (response && response.results) {
|
|
5825
5837
|
// console.log('calling after-- ')
|
|
5826
5838
|
if (response.results.result.data && response.results.result.data.length) {
|
|
5827
|
-
|
|
5839
|
+
finalPlaylistData_1 = [];
|
|
5840
|
+
programData = response.results.result.data;
|
|
5841
|
+
programData.forEach((/**
|
|
5842
|
+
* @param {?} prgData
|
|
5843
|
+
* @return {?}
|
|
5844
|
+
*/
|
|
5845
|
+
function (prgData) {
|
|
5846
|
+
if (prgData.children && prgData.children.length) {
|
|
5847
|
+
finalPlaylistData_1.push(prgData);
|
|
5848
|
+
}
|
|
5849
|
+
}));
|
|
5850
|
+
if (finalPlaylistData_1.length) {
|
|
5851
|
+
this.processStrip(strip, this.transformContentsToWidgets(finalPlaylistData_1, strip), 'done', calculateParentStatus, response.viewMoreUrl);
|
|
5852
|
+
}
|
|
5853
|
+
else {
|
|
5854
|
+
this.emptyResponse.emit(true);
|
|
5855
|
+
}
|
|
5828
5856
|
}
|
|
5829
5857
|
else {
|
|
5830
5858
|
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
@@ -5894,6 +5922,68 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5894
5922
|
});
|
|
5895
5923
|
});
|
|
5896
5924
|
};
|
|
5925
|
+
/**
|
|
5926
|
+
* @param {?} strip
|
|
5927
|
+
* @param {?=} calculateParentStatus
|
|
5928
|
+
* @return {?}
|
|
5929
|
+
*/
|
|
5930
|
+
ContentStripWithTabsLibComponent.prototype.fetchCiosContentData = /**
|
|
5931
|
+
* @param {?} strip
|
|
5932
|
+
* @param {?=} calculateParentStatus
|
|
5933
|
+
* @return {?}
|
|
5934
|
+
*/
|
|
5935
|
+
function (strip, calculateParentStatus) {
|
|
5936
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5937
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
5938
|
+
var originalFilters, response, extContentData, error_10;
|
|
5939
|
+
return __generator(this, function (_a) {
|
|
5940
|
+
switch (_a.label) {
|
|
5941
|
+
case 0:
|
|
5942
|
+
if (!(strip.request && strip.request.ciosContent && Object.keys(strip.request.ciosContent).length)) return [3 /*break*/, 4];
|
|
5943
|
+
originalFilters = [];
|
|
5944
|
+
if (strip.request &&
|
|
5945
|
+
strip.request.ciosContent &&
|
|
5946
|
+
strip.request.ciosContent.filterCriteriaMap) {
|
|
5947
|
+
originalFilters = strip.request.ciosContent.filterCriteriaMap;
|
|
5948
|
+
strip.request.ciosContent.filterCriteriaMap = this.postMethodFilters(strip.request.ciosContent.filterCriteriaMap);
|
|
5949
|
+
}
|
|
5950
|
+
_a.label = 1;
|
|
5951
|
+
case 1:
|
|
5952
|
+
_a.trys.push([1, 3, , 4]);
|
|
5953
|
+
return [4 /*yield*/, this.postRequestMethod(strip, strip.request.ciosContent, strip.request.apiUrl, calculateParentStatus)];
|
|
5954
|
+
case 2:
|
|
5955
|
+
response = _a.sent();
|
|
5956
|
+
// console.log('calling after - response, ', response)
|
|
5957
|
+
if (response && response.results) {
|
|
5958
|
+
// console.log('calling after-- ')
|
|
5959
|
+
if (response.results.data && response.results.data.length) {
|
|
5960
|
+
extContentData = response.results.data;
|
|
5961
|
+
if (extContentData.length) {
|
|
5962
|
+
this.processStrip(strip, this.transformContentsToWidgets(extContentData, strip), 'done', calculateParentStatus, response.viewMoreUrl);
|
|
5963
|
+
}
|
|
5964
|
+
else {
|
|
5965
|
+
this.emptyResponse.emit(true);
|
|
5966
|
+
}
|
|
5967
|
+
}
|
|
5968
|
+
else {
|
|
5969
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5970
|
+
this.emptyResponse.emit(true);
|
|
5971
|
+
}
|
|
5972
|
+
}
|
|
5973
|
+
else {
|
|
5974
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5975
|
+
this.emptyResponse.emit(true);
|
|
5976
|
+
}
|
|
5977
|
+
return [3 /*break*/, 4];
|
|
5978
|
+
case 3:
|
|
5979
|
+
error_10 = _a.sent();
|
|
5980
|
+
this.emptyResponse.emit(true);
|
|
5981
|
+
return [3 /*break*/, 4];
|
|
5982
|
+
case 4: return [2 /*return*/];
|
|
5983
|
+
}
|
|
5984
|
+
});
|
|
5985
|
+
});
|
|
5986
|
+
};
|
|
5897
5987
|
ContentStripWithTabsLibComponent.decorators = [
|
|
5898
5988
|
{ type: Component, args: [{
|
|
5899
5989
|
selector: 'sb-uic-content-strip-with-tabs',
|
|
@@ -8524,16 +8614,28 @@ var CardsComponent = /** @class */ (function (_super) {
|
|
|
8524
8614
|
*/
|
|
8525
8615
|
function (content) {
|
|
8526
8616
|
return __awaiter(this, void 0, void 0, function () {
|
|
8527
|
-
var urlData;
|
|
8617
|
+
var userProfile, extUrl, urlData;
|
|
8528
8618
|
return __generator(this, function (_a) {
|
|
8529
8619
|
switch (_a.label) {
|
|
8530
|
-
case 0:
|
|
8531
|
-
|
|
8620
|
+
case 0:
|
|
8621
|
+
userProfile = this.configSvc.userProfile;
|
|
8622
|
+
debugger;
|
|
8623
|
+
if (!content.externalId) return [3 /*break*/, 1];
|
|
8624
|
+
extUrl = content.redirectUrl.replace('<username>', userProfile.userId);
|
|
8625
|
+
// const url = this.router.serializeUrl(
|
|
8626
|
+
// this.router.createUrlTree([extUrl])
|
|
8627
|
+
// );
|
|
8628
|
+
window.open(extUrl, '_blank');
|
|
8629
|
+
window.open(content.redirectUrl);
|
|
8630
|
+
return [3 /*break*/, 3];
|
|
8631
|
+
case 1: return [4 /*yield*/, this.contSvc.getResourseLink(content)];
|
|
8632
|
+
case 2:
|
|
8532
8633
|
urlData = _a.sent();
|
|
8533
8634
|
this.router.navigate([urlData.url], {
|
|
8534
8635
|
queryParams: urlData.queryParams
|
|
8535
8636
|
});
|
|
8536
|
-
|
|
8637
|
+
_a.label = 3;
|
|
8638
|
+
case 3: return [2 /*return*/];
|
|
8537
8639
|
}
|
|
8538
8640
|
});
|
|
8539
8641
|
});
|
|
@@ -8578,14 +8680,14 @@ var CardsComponent = /** @class */ (function (_super) {
|
|
|
8578
8680
|
CardsComponent.decorators = [
|
|
8579
8681
|
{ type: Component, args: [{
|
|
8580
8682
|
selector: 'sb-uic-cards',
|
|
8581
|
-
template: "<div class=\"widget-card-content-new\">\n <ng-container *ngIf=\"widgetData && (((widgetData?.deletedMode || 'none') === 'hide' && !!!isLiveOrMarkForDeletion)\n ? false\n : !((widgetData?.intranetMode || 'none') === 'hide' && !!showIntranetContent))\"\n [ngSwitch]=\"( (widgetData && widgetData?.cardSubType) || 'cardPortraitLib')\">\n <ng-container *ngSwitchDefault [ngTemplateOutlet]=\"cardPortraitLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'user-card'\" [ngTemplateOutlet]=\"cardUser\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-portrait-lib-skeleton'\" [ngTemplateOutlet]=\"cardPortraitLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-portrait-lib'\" [ngTemplateOutlet]=\"cardPortraitLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-landscape-lib-skeleton'\" [ngTemplateOutlet]=\"cardLandscapeLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-landscape-lib'\" [ngTemplateOutlet]=\"cardLandscapeLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-lib-skeleton'\" [ngTemplateOutlet]=\"cardWideLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-lib'\" [ngTemplateOutlet]=\"cardWideLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-v2'\" [ngTemplateOutlet]=\"cardWideV2\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-v2-skeleton'\" [ngTemplateOutlet]=\"cardWideV2Skeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-mdo-lib'\" [ngTemplateOutlet]=\"cardMdo\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-mdo-lib-skeleton'\" [ngTemplateOutlet]=\"cardMdoSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib'\" [ngTemplateOutlet]=\"cardKarmaProgram\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib-skeleton'\" [ngTemplateOutlet]=\"cardKarmaProgram\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib-v2'\" [ngTemplateOutlet]=\"cardKarmaProgramV2\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib-v2-skeleton'\" [ngTemplateOutlet]=\"cardKarmaProgramV2\"></ng-container>\n </ng-container>\n</div>\n\n<ng-template #cardPortraitLibSkeleton>\n <sb-uic-card-portrait [widgetData]=\"widgetData\" [isCardLoading]=\"true\"></sb-uic-card-portrait>\n</ng-template>\n<ng-template #cardPortraitLib>\n <sb-uic-card-portrait \n [cbPlanMapData]=\"cbPlanMapData\"\n (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\" [isCardLoading]=\"false\"></sb-uic-card-portrait>\n</ng-template>\n<ng-template #cardLandscapeLibSkeleton>\n <sb-uic-card-landscape [widgetData]=\"widgetData\" \n [cbPlanMapData]=\"cbPlanMapData\" [isCardLoading]=\"true\"></sb-uic-card-landscape>\n</ng-template>\n<ng-template #cardLandscapeLib>\n <sb-uic-card-landscape\n (contentData)=\"getRedirectUrlData($event)\"\n (triggerTelemetry)=\"raiseCardClick($event)\"\n [widgetData]=\"widgetData\"\n [cbPlanMapData]=\"cbPlanMapData\"\n [isCardLoading]=\"false\">\n </sb-uic-card-landscape>\n</ng-template>\n\n<ng-template #cardWideLib>\n <sb-uic-card-wide (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\"></sb-uic-card-wide>\n</ng-template>\n<ng-template #cardWideLibSkeleton>\n <sb-uic-card-wide [widgetData]=\"widgetData\"></sb-uic-card-wide>\n</ng-template>\n\n<ng-template #cardWideV2Skeleton>\n <sb-uic-card-wide-v2 [widgetData]=\"widgetData\" [isCardLoading]=\"true\" ></sb-uic-card-wide-v2>\n</ng-template>\n<ng-template #cardWideV2>\n <sb-uic-card-wide-v2\n (contentData)=\"getRedirectUrlData($event)\"\n (triggerTelemetry)=\"raiseCardClick($event)\"\n [cbPlanMapData]=\"cbPlanMapData\"\n [isCardLoading]=\"false\"\n [widgetData]=\"widgetData\">\n </sb-uic-card-wide-v2>\n</ng-template>\n\n<ng-template #cardUser>\n <sb-uic-card-user [widgetData]=\"widgetData\"></sb-uic-card-user>\n</ng-template>\n<ng-template #cardMdo>\n <sb-uic-card-mdo-channel [widgetData]=\"widgetData\"></sb-uic-card-mdo-channel>\n</ng-template>\n<ng-template #cardMdoSkeleton>\n <sb-uic-card-mdo-channel [widgetData]=\"widgetData\"></sb-uic-card-mdo-channel>\n</ng-template>\n<ng-template #cardKarmaProgram>\n <sb-uic-card-karma-programs [randomColorApply]=\"true\" [widgetData]=\"widgetData\"></sb-uic-card-karma-programs>\n</ng-template>\n<ng-template #cardKarmaProgramV2>\n <!-- <sb-uic-card-karma-programs-v2 [widgetData]=\"widgetData\"><sb-uic-card-karma-programs-v2> -->\n</ng-template>",
|
|
8683
|
+
template: "<div class=\"widget-card-content-new\">\n <ng-container *ngIf=\"widgetData && (((widgetData?.deletedMode || 'none') === 'hide' && !!!isLiveOrMarkForDeletion)\n ? false\n : !((widgetData?.intranetMode || 'none') === 'hide' && !!showIntranetContent))\"\n [ngSwitch]=\"( (widgetData && widgetData?.cardSubType) || 'cardPortraitLib')\">\n <ng-container *ngSwitchDefault [ngTemplateOutlet]=\"cardPortraitLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'user-card'\" [ngTemplateOutlet]=\"cardUser\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-portrait-lib-skeleton'\" [ngTemplateOutlet]=\"cardPortraitLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-portrait-lib'\" [ngTemplateOutlet]=\"cardPortraitLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-landscape-lib-skeleton'\" [ngTemplateOutlet]=\"cardLandscapeLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-landscape-lib'\" [ngTemplateOutlet]=\"cardLandscapeLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-lib-skeleton'\" [ngTemplateOutlet]=\"cardWideLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-lib'\" [ngTemplateOutlet]=\"cardWideLib\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-v2'\" [ngTemplateOutlet]=\"cardWideV2\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-wide-v2-skeleton'\" [ngTemplateOutlet]=\"cardWideV2Skeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-mdo-lib'\" [ngTemplateOutlet]=\"cardMdo\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-mdo-lib-skeleton'\" [ngTemplateOutlet]=\"cardMdoSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib'\" [ngTemplateOutlet]=\"cardKarmaProgram\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib-skeleton'\" [ngTemplateOutlet]=\"cardKarmaProgram\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib-v2'\" [ngTemplateOutlet]=\"cardKarmaProgramV2\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-karma-program-lib-v2-skeleton'\" [ngTemplateOutlet]=\"cardKarmaProgramV2\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-portrait-ext-lib-skeleton'\" [ngTemplateOutlet]=\"cardPortraitExtLibSkeleton\"></ng-container>\n <ng-container *ngSwitchCase=\"'card-portrait-ext-lib'\" [ngTemplateOutlet]=\"cardPortraitExtLib\"></ng-container>\n </ng-container>\n</div>\n\n<ng-template #cardPortraitLibSkeleton>\n <sb-uic-card-portrait [widgetData]=\"widgetData\" [isCardLoading]=\"true\"></sb-uic-card-portrait>\n</ng-template>\n<ng-template #cardPortraitLib>\n <sb-uic-card-portrait \n [cbPlanMapData]=\"cbPlanMapData\"\n (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\" [isCardLoading]=\"false\"></sb-uic-card-portrait>\n</ng-template>\n<ng-template #cardLandscapeLibSkeleton>\n <sb-uic-card-landscape [widgetData]=\"widgetData\" \n [cbPlanMapData]=\"cbPlanMapData\" [isCardLoading]=\"true\"></sb-uic-card-landscape>\n</ng-template>\n<ng-template #cardLandscapeLib>\n <sb-uic-card-landscape\n (contentData)=\"getRedirectUrlData($event)\"\n (triggerTelemetry)=\"raiseCardClick($event)\"\n [widgetData]=\"widgetData\"\n [cbPlanMapData]=\"cbPlanMapData\"\n [isCardLoading]=\"false\">\n </sb-uic-card-landscape>\n</ng-template>\n\n<ng-template #cardWideLib>\n <sb-uic-card-wide (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\"></sb-uic-card-wide>\n</ng-template>\n<ng-template #cardWideLibSkeleton>\n <sb-uic-card-wide [widgetData]=\"widgetData\"></sb-uic-card-wide>\n</ng-template>\n\n<ng-template #cardWideV2Skeleton>\n <sb-uic-card-wide-v2 [widgetData]=\"widgetData\" [isCardLoading]=\"true\" ></sb-uic-card-wide-v2>\n</ng-template>\n<ng-template #cardWideV2>\n <sb-uic-card-wide-v2\n (contentData)=\"getRedirectUrlData($event)\"\n (triggerTelemetry)=\"raiseCardClick($event)\"\n [cbPlanMapData]=\"cbPlanMapData\"\n [isCardLoading]=\"false\"\n [widgetData]=\"widgetData\">\n </sb-uic-card-wide-v2>\n</ng-template>\n\n<ng-template #cardUser>\n <sb-uic-card-user [widgetData]=\"widgetData\"></sb-uic-card-user>\n</ng-template>\n<ng-template #cardMdo>\n <sb-uic-card-mdo-channel [widgetData]=\"widgetData\"></sb-uic-card-mdo-channel>\n</ng-template>\n<ng-template #cardMdoSkeleton>\n <sb-uic-card-mdo-channel [widgetData]=\"widgetData\"></sb-uic-card-mdo-channel>\n</ng-template>\n<ng-template #cardKarmaProgram>\n <sb-uic-card-karma-programs [randomColorApply]=\"true\" [widgetData]=\"widgetData\"></sb-uic-card-karma-programs>\n</ng-template>\n<ng-template #cardKarmaProgramV2>\n <!-- <sb-uic-card-karma-programs-v2 [widgetData]=\"widgetData\"><sb-uic-card-karma-programs-v2> -->\n</ng-template>\n\n<!-- cios card -->\n<ng-template #cardPortraitExtLibSkeleton>\n <sb-uic-card-portrait-ext [widgetData]=\"widgetData\" [isCardLoading]=\"true\"></sb-uic-card-portrait-ext>\n</ng-template>\n<ng-template #cardPortraitExtLib>\n <sb-uic-card-portrait-ext \n [cbPlanMapData]=\"cbPlanMapData\"\n (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\" [isCardLoading]=\"false\"></sb-uic-card-portrait-ext>\n</ng-template>",
|
|
8582
8684
|
styles: [""]
|
|
8583
8685
|
}] }
|
|
8584
8686
|
];
|
|
8585
8687
|
/** @nocollapse */
|
|
8586
8688
|
CardsComponent.ctorParameters = function () { return [
|
|
8587
8689
|
{ type: UtilityService },
|
|
8588
|
-
{ type: ConfigurationsService },
|
|
8690
|
+
{ type: ConfigurationsService$1 },
|
|
8589
8691
|
{ type: WidgetContentService },
|
|
8590
8692
|
{ type: Router }
|
|
8591
8693
|
]; };
|
|
@@ -9637,8 +9739,8 @@ var CardWideComponent = /** @class */ (function () {
|
|
|
9637
9739
|
CardWideComponent.decorators = [
|
|
9638
9740
|
{ type: Component, args: [{
|
|
9639
9741
|
selector: 'sb-uic-card-wide',
|
|
9640
|
-
template: "<mat-card class=\"card-wide-lib\">\n <a (click)=\"raiseTelemetry();getRedirectUrlData(widgetData?.content); $event.stopPropagation()\" \n role=\"link\" i18n-aria-label>\n <div class=\"flex\">\n <div>\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <img mat-card-image [src]=\"widgetData?.content?.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-wide-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-wide-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-wide-img ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n </div>\n <div>\n <div class=\"pl-4 pr-4 w-full\">\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 </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\n <div class=\"flex w-full
|
|
9641
|
-
styles: [".card-wide-lib{width:inherit;padding:16px;border-radius:12px;background:#fff;border:1px solid rgba(0,0,0,.16)}.card-wide-lib .card-wide-img{width:190px;height:107px;border-radius:12px}.card-wide-lib .course_widget{margin-top:10px}.card-wide-lib .course_widget .mat-icon{vertical-align:middle;color:#ef951e!important}.card-wide-lib .course_widget .course_v2{border:1px solid #ef951e;padding:4px 8px;align-items:end;border-radius:16px}.card-wide-lib .course_widget .main_icon{font-size:16px;width:16px;height:16px}.card-wide-lib .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-wide-lib .course_logo_box img{height:28px;width:28px;padding:5px;display:inline-block}.card-wide-lib .course_logo_box p{display:inline-block;vertical-align:top}.card-wide-lib .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}@media screen and (max-width:768px){.card-wide-img{width:147px;height:117px;border-radius:12px}}"]
|
|
9742
|
+
template: "<mat-card class=\"card-wide-lib\">\n <a (click)=\"raiseTelemetry();getRedirectUrlData(widgetData?.content); $event.stopPropagation()\" \n role=\"link\" i18n-aria-label>\n <div class=\"flex\">\n <div>\n <ng-container *ngIf=\"widgetData?.content?.posterImage\">\n <img mat-card-image [src]=\"widgetData?.content?.posterImage | pipePublicURL\" loading=\"lazy\"\n class=\"card-wide-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-wide-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-wide-img ws-mat-primary-lite-background margin-remove\"\n [alt]=\"widgetData?.content?.name\" />\n </ng-template>\n </ng-container>\n </div>\n <div>\n <div class=\"pl-4 pr-4 w-full\">\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 </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\n <div class=\"flex w-full 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>\n </div>\n </div>\n </a>\n</mat-card>\n",
|
|
9743
|
+
styles: [".card-wide-lib{width:inherit;padding:16px;border-radius:12px;background:#fff;border:1px solid rgba(0,0,0,.16)}.card-wide-lib .card-wide-img{width:190px;height:107px;border-radius:12px}.card-wide-lib .course_widget{margin-top:10px}.card-wide-lib .course_widget .mat-icon{vertical-align:middle;color:#ef951e!important}.card-wide-lib .course_widget .course_v2{border:1px solid #ef951e;padding:4px 8px;align-items:end;border-radius:16px}.card-wide-lib .course_widget .main_icon{font-size:16px;width:16px;height:16px}.card-wide-lib .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-wide-lib .course_logo_box img{height:28px;width:28px;padding:5px;display:inline-block}.card-wide-lib .course_logo_box p{display:inline-block;vertical-align:top}.card-wide-lib .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}@media screen and (max-width:768px){.card-wide-img{width:147px!important;height:117px!important;border-radius:12px!important}}"]
|
|
9642
9744
|
}] }
|
|
9643
9745
|
];
|
|
9644
9746
|
/** @nocollapse */
|
|
@@ -10389,6 +10491,171 @@ if (false) {
|
|
|
10389
10491
|
CardKarmaProgramsV2Component.prototype.router;
|
|
10390
10492
|
}
|
|
10391
10493
|
|
|
10494
|
+
/**
|
|
10495
|
+
* @fileoverview added by tsickle
|
|
10496
|
+
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
10497
|
+
*/
|
|
10498
|
+
var CardPortraitExtComponent = /** @class */ (function () {
|
|
10499
|
+
function CardPortraitExtComponent(snackBar, translate, langtranslations, configSvc, contSvc) {
|
|
10500
|
+
var _this = this;
|
|
10501
|
+
this.snackBar = snackBar;
|
|
10502
|
+
this.translate = translate;
|
|
10503
|
+
this.langtranslations = langtranslations;
|
|
10504
|
+
this.configSvc = configSvc;
|
|
10505
|
+
this.contSvc = contSvc;
|
|
10506
|
+
this.isCardLoading = false;
|
|
10507
|
+
this.contentData = new EventEmitter();
|
|
10508
|
+
this.isCardFlipped = false;
|
|
10509
|
+
this.acbpConstants = NsCardContent$1.ACBPConst;
|
|
10510
|
+
this.showFlip = false;
|
|
10511
|
+
this.widgetType = 'df';
|
|
10512
|
+
this.widgetSubType = 'sdf';
|
|
10513
|
+
this.langtranslations.languageSelectedObservable.subscribe((/**
|
|
10514
|
+
* @return {?}
|
|
10515
|
+
*/
|
|
10516
|
+
function () {
|
|
10517
|
+
if (localStorage.getItem('websiteLanguage')) {
|
|
10518
|
+
_this.translate.setDefaultLang('en');
|
|
10519
|
+
/** @type {?} */
|
|
10520
|
+
var lang = (/** @type {?} */ (localStorage.getItem('websiteLanguage')));
|
|
10521
|
+
_this.translate.use(lang);
|
|
10522
|
+
}
|
|
10523
|
+
}));
|
|
10524
|
+
}
|
|
10525
|
+
/**
|
|
10526
|
+
* @return {?}
|
|
10527
|
+
*/
|
|
10528
|
+
CardPortraitExtComponent.prototype.ngOnInit = /**
|
|
10529
|
+
* @return {?}
|
|
10530
|
+
*/
|
|
10531
|
+
function () {
|
|
10532
|
+
/** @type {?} */
|
|
10533
|
+
var instanceConfig = this.configSvc.instanceConfig;
|
|
10534
|
+
if (instanceConfig) {
|
|
10535
|
+
this.defaultThumbnail = instanceConfig.logos.defaultContent || '';
|
|
10536
|
+
this.sourceLogos = instanceConfig.sources;
|
|
10537
|
+
this.defaultSLogo = instanceConfig.logos.defaultSourceLogo || '';
|
|
10538
|
+
}
|
|
10539
|
+
else {
|
|
10540
|
+
this.defaultThumbnail = '/assets/instances/eagle/app_logos/default.png';
|
|
10541
|
+
this.defaultSLogo = '/assets/instances/eagle/app_logos/KarmayogiBharat_Logo.svg';
|
|
10542
|
+
}
|
|
10543
|
+
};
|
|
10544
|
+
/**
|
|
10545
|
+
* @return {?}
|
|
10546
|
+
*/
|
|
10547
|
+
CardPortraitExtComponent.prototype.showSnackbar = /**
|
|
10548
|
+
* @return {?}
|
|
10549
|
+
*/
|
|
10550
|
+
function () {
|
|
10551
|
+
if (this.showIntranetContent) {
|
|
10552
|
+
this.snackBar.open('Content is only available in intranet', 'X', { duration: 2000 });
|
|
10553
|
+
}
|
|
10554
|
+
else if (!this.isLiveOrMarkForDeletion) {
|
|
10555
|
+
this.snackBar.open('Content may be expired or deleted', 'X', { duration: 2000 });
|
|
10556
|
+
}
|
|
10557
|
+
};
|
|
10558
|
+
/**
|
|
10559
|
+
* @param {?} contentData
|
|
10560
|
+
* @return {?}
|
|
10561
|
+
*/
|
|
10562
|
+
CardPortraitExtComponent.prototype.getRedirectUrlData = /**
|
|
10563
|
+
* @param {?} contentData
|
|
10564
|
+
* @return {?}
|
|
10565
|
+
*/
|
|
10566
|
+
function (contentData) {
|
|
10567
|
+
// for telemetry
|
|
10568
|
+
if (this.widgetData && this.widgetData.context && this.widgetData.context.pageSection) {
|
|
10569
|
+
contentData['typeOfTelemetry'] = this.widgetData.context.pageSection;
|
|
10570
|
+
}
|
|
10571
|
+
this.contSvc.changeTelemetryData(contentData);
|
|
10572
|
+
// for redirection
|
|
10573
|
+
this.contentData.emit(contentData);
|
|
10574
|
+
};
|
|
10575
|
+
CardPortraitExtComponent.decorators = [
|
|
10576
|
+
{ type: Component, args: [{
|
|
10577
|
+
selector: 'sb-uic-card-portrait-ext',
|
|
10578
|
+
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>",
|
|
10579
|
+
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}"]
|
|
10580
|
+
}] }
|
|
10581
|
+
];
|
|
10582
|
+
/** @nocollapse */
|
|
10583
|
+
CardPortraitExtComponent.ctorParameters = function () { return [
|
|
10584
|
+
{ type: MatSnackBar },
|
|
10585
|
+
{ type: TranslateService },
|
|
10586
|
+
{ type: MultilingualTranslationsService },
|
|
10587
|
+
{ type: ConfigurationsService$1 },
|
|
10588
|
+
{ type: WidgetContentService }
|
|
10589
|
+
]; };
|
|
10590
|
+
CardPortraitExtComponent.propDecorators = {
|
|
10591
|
+
widgetData: [{ type: Input }],
|
|
10592
|
+
isLiveOrMarkForDeletion: [{ type: Input }],
|
|
10593
|
+
showIntranetContent: [{ type: Input }],
|
|
10594
|
+
isIntranetAllowedSettings: [{ type: Input }],
|
|
10595
|
+
isCardLoading: [{ type: Input }],
|
|
10596
|
+
contentData: [{ type: Output }],
|
|
10597
|
+
cbPlanMapData: [{ type: Input }]
|
|
10598
|
+
};
|
|
10599
|
+
return CardPortraitExtComponent;
|
|
10600
|
+
}());
|
|
10601
|
+
if (false) {
|
|
10602
|
+
/** @type {?} */
|
|
10603
|
+
CardPortraitExtComponent.prototype.widgetData;
|
|
10604
|
+
/** @type {?} */
|
|
10605
|
+
CardPortraitExtComponent.prototype.isLiveOrMarkForDeletion;
|
|
10606
|
+
/** @type {?} */
|
|
10607
|
+
CardPortraitExtComponent.prototype.showIntranetContent;
|
|
10608
|
+
/** @type {?} */
|
|
10609
|
+
CardPortraitExtComponent.prototype.isIntranetAllowedSettings;
|
|
10610
|
+
/** @type {?} */
|
|
10611
|
+
CardPortraitExtComponent.prototype.isCardLoading;
|
|
10612
|
+
/** @type {?} */
|
|
10613
|
+
CardPortraitExtComponent.prototype.contentData;
|
|
10614
|
+
/** @type {?} */
|
|
10615
|
+
CardPortraitExtComponent.prototype.cbPlanMapData;
|
|
10616
|
+
/** @type {?} */
|
|
10617
|
+
CardPortraitExtComponent.prototype.isCardFlipped;
|
|
10618
|
+
/** @type {?} */
|
|
10619
|
+
CardPortraitExtComponent.prototype.acbpConstants;
|
|
10620
|
+
/** @type {?} */
|
|
10621
|
+
CardPortraitExtComponent.prototype.defaultThumbnail;
|
|
10622
|
+
/** @type {?} */
|
|
10623
|
+
CardPortraitExtComponent.prototype.sourceLogos;
|
|
10624
|
+
/** @type {?} */
|
|
10625
|
+
CardPortraitExtComponent.prototype.defaultSLogo;
|
|
10626
|
+
/** @type {?} */
|
|
10627
|
+
CardPortraitExtComponent.prototype.showFlip;
|
|
10628
|
+
/** @type {?} */
|
|
10629
|
+
CardPortraitExtComponent.prototype.widgetType;
|
|
10630
|
+
/** @type {?} */
|
|
10631
|
+
CardPortraitExtComponent.prototype.widgetSubType;
|
|
10632
|
+
/**
|
|
10633
|
+
* @type {?}
|
|
10634
|
+
* @private
|
|
10635
|
+
*/
|
|
10636
|
+
CardPortraitExtComponent.prototype.snackBar;
|
|
10637
|
+
/**
|
|
10638
|
+
* @type {?}
|
|
10639
|
+
* @private
|
|
10640
|
+
*/
|
|
10641
|
+
CardPortraitExtComponent.prototype.translate;
|
|
10642
|
+
/**
|
|
10643
|
+
* @type {?}
|
|
10644
|
+
* @private
|
|
10645
|
+
*/
|
|
10646
|
+
CardPortraitExtComponent.prototype.langtranslations;
|
|
10647
|
+
/**
|
|
10648
|
+
* @type {?}
|
|
10649
|
+
* @private
|
|
10650
|
+
*/
|
|
10651
|
+
CardPortraitExtComponent.prototype.configSvc;
|
|
10652
|
+
/**
|
|
10653
|
+
* @type {?}
|
|
10654
|
+
* @private
|
|
10655
|
+
*/
|
|
10656
|
+
CardPortraitExtComponent.prototype.contSvc;
|
|
10657
|
+
}
|
|
10658
|
+
|
|
10392
10659
|
/**
|
|
10393
10660
|
* @fileoverview added by tsickle
|
|
10394
10661
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
@@ -10407,7 +10674,8 @@ var CardsModule = /** @class */ (function () {
|
|
|
10407
10674
|
CardMDOChannelComponent,
|
|
10408
10675
|
CardWideV2Component,
|
|
10409
10676
|
CardKarmaProgramsComponent,
|
|
10410
|
-
CardKarmaProgramsV2Component
|
|
10677
|
+
CardKarmaProgramsV2Component,
|
|
10678
|
+
CardPortraitExtComponent
|
|
10411
10679
|
],
|
|
10412
10680
|
imports: [
|
|
10413
10681
|
CommonModule,
|
|
@@ -12065,5 +12333,5 @@ var UserContentRatingLibModule = /** @class */ (function () {
|
|
|
12065
12333
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
12066
12334
|
*/
|
|
12067
12335
|
|
|
12068
|
-
export { AnnouncementsModule, CalenderModule, CardsModule, CommonMethodsService, CommonStripModule, CompetencyPassbookModule, ConsumptionComponent, ConsumptionModule, ConsumptionService, ContentStripWithTabsLibModule, DataPointsModule, HttpLoaderFactory, MyHammerConfig, ROOT_WIDGET_CONFIG, SlidersLibModule, UserContentRatingLibModule, WIDGET_REGISTERED_LIB_MODULES, WIDGET_REGISTRATION_LIB_CONFIG, WidgetContentService, ContentStripWithTabsLibComponent as ɵa, WidgetUserService as ɵb, CardWideV2Component as ɵba, CardKarmaProgramsComponent as ɵbb, CardKarmaProgramsV2Component as ɵbc,
|
|
12336
|
+
export { AnnouncementsModule, CalenderModule, CardsModule, CommonMethodsService, CommonStripModule, CompetencyPassbookModule, ConsumptionComponent, ConsumptionModule, ConsumptionService, ContentStripWithTabsLibModule, DataPointsModule, HttpLoaderFactory, MyHammerConfig, ROOT_WIDGET_CONFIG, SlidersLibModule, UserContentRatingLibModule, WIDGET_REGISTERED_LIB_MODULES, WIDGET_REGISTRATION_LIB_CONFIG, WidgetContentService, ContentStripWithTabsLibComponent as ɵa, WidgetUserService as ɵb, CardWideV2Component as ɵba, CardKarmaProgramsComponent as ɵbb, CardKarmaProgramsV2Component as ɵbc, CardPortraitExtComponent as ɵbd, PipePublicURLModule as ɵbe, PipePublicURL as ɵbf, DisplayContentTypeLibModule as ɵbg, DisplayContentTypeLibComponent as ɵbh, DefaultThumbnailModule as ɵbi, DefaultThumbnailDirective as ɵbj, PipeDurationTransformModule as ɵbk, PipeDurationTransformPipe as ɵbl, CompetencyPassbookComponent as ɵbm, CompetencyPassbookService as ɵbn, PillsModule as ɵbo, PillsComponent as ɵbp, UserContentRatingLibComponent as ɵbq, ScrollableItemDirective as ɵbr, RatingService as ɵbs, UserContentRatingLibService as ɵbt, AvatarPhotoLibModule as ɵbu, AvatarPhotoLibComponent as ɵbv, MyHammerConfig$1 as ɵbw, SlidersNgContentLibModule as ɵbx, SlidersNgContentLibComponent as ɵby, ScrollableItemModule as ɵbz, MultilingualTranslationsService as ɵc, ConfigurationsService as ɵd, HorizontalScrollerV2Module as ɵe, HorizontalScrollerV2Component as ɵf, SlidersLibComponent as ɵg, NavigationModule as ɵh, NavigationDirective as ɵi, ImageResponsiveModule as ɵj, ImageResponsiveDirective as ɵk, DataPointsComponent as ɵl, InsiteDataService as ɵm, SkeletonLoaderLibModule as ɵn, SkeletonLoaderLibComponent as ɵo, CalenderComponent as ɵp, CalenderDayComponent as ɵq, CommonStripComponent as ɵr, AnnouncementsComponent as ɵs, CardResourceComponent as ɵt, CardsComponent as ɵu, CardPortraitComponent as ɵv, CardUserComponent as ɵw, CardLandscapeComponent as ɵx, CardWideComponent as ɵy, CardMDOChannelComponent as ɵz };
|
|
12069
12337
|
//# sourceMappingURL=sunbird-cb-consumption.js.map
|