@sunbird-cb/consumption 0.0.26 → 0.0.27
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 +589 -149
- 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/announcements/announcements.component.js +77 -9
- package/esm2015/lib/_common/calender/calender.component.js +1 -2
- package/esm2015/lib/_common/cards/card-karma-programs/card-karma-programs.component.js +2 -3
- package/esm2015/lib/_common/cards/card-karma-programs-v2/card-karma-programs-v2.component.js +167 -0
- package/esm2015/lib/_common/cards/card-mdo-channel/card-mdo-channel.component.js +48 -26
- package/esm2015/lib/_common/cards/card-portrait/card-portrait.component.js +1 -1
- package/esm2015/lib/_common/cards/card-wide-v2/card-wide-v2.component.js +11 -23
- package/esm2015/lib/_common/cards/cards.component.js +15 -4
- package/esm2015/lib/_common/cards/cards.module.js +6 -3
- package/esm2015/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.js +168 -64
- package/esm2015/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.model.js +1 -1
- package/esm2015/lib/_common/horizontal-scroller-v2/horizontal-scroller-v2.component.js +1 -2
- package/esm2015/lib/_services/insite-data.service.js +10 -2
- package/esm2015/lib/_services/widget-content.service.js +9 -1
- package/esm2015/sunbird-cb-consumption.js +23 -22
- package/esm5/lib/_common/announcements/announcements.component.js +77 -9
- package/esm5/lib/_common/calender/calender.component.js +1 -2
- package/esm5/lib/_common/cards/card-karma-programs/card-karma-programs.component.js +2 -3
- package/esm5/lib/_common/cards/card-karma-programs-v2/card-karma-programs-v2.component.js +177 -0
- package/esm5/lib/_common/cards/card-mdo-channel/card-mdo-channel.component.js +55 -26
- package/esm5/lib/_common/cards/card-portrait/card-portrait.component.js +1 -1
- package/esm5/lib/_common/cards/card-wide-v2/card-wide-v2.component.js +12 -23
- package/esm5/lib/_common/cards/cards.component.js +19 -4
- package/esm5/lib/_common/cards/cards.module.js +6 -3
- package/esm5/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.js +209 -65
- package/esm5/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.model.js +1 -1
- package/esm5/lib/_common/horizontal-scroller-v2/horizontal-scroller-v2.component.js +1 -2
- package/esm5/lib/_services/insite-data.service.js +14 -2
- package/esm5/lib/_services/widget-content.service.js +13 -1
- package/esm5/sunbird-cb-consumption.js +23 -22
- package/fesm2015/sunbird-cb-consumption.js +497 -127
- package/fesm2015/sunbird-cb-consumption.js.map +1 -1
- package/fesm5/sunbird-cb-consumption.js +567 -128
- package/fesm5/sunbird-cb-consumption.js.map +1 -1
- package/lib/_common/announcements/announcements.component.d.ts +7 -1
- package/lib/_common/cards/card-karma-programs-v2/card-karma-programs-v2.component.d.ts +23 -0
- package/lib/_common/cards/card-mdo-channel/card-mdo-channel.component.d.ts +10 -3
- package/lib/_common/cards/card-wide-v2/card-wide-v2.component.d.ts +2 -1
- package/lib/_common/cards/cards.component.d.ts +3 -1
- package/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.d.ts +5 -1
- package/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.model.d.ts +3 -1
- package/lib/_services/insite-data.service.d.ts +1 -0
- package/lib/_services/widget-content.service.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
|
@@ -246,7 +246,6 @@ var HorizontalScrollerV2Component = /** @class */ (function () {
|
|
|
246
246
|
* @return {?}
|
|
247
247
|
*/
|
|
248
248
|
function (elem) {
|
|
249
|
-
debugger;
|
|
250
249
|
this.enablePrev = true;
|
|
251
250
|
this.enableNext = true;
|
|
252
251
|
if (elem.scrollLeft === 0) {
|
|
@@ -2494,6 +2493,18 @@ var WidgetContentService = /** @class */ (function () {
|
|
|
2494
2493
|
req.query = req.query || '';
|
|
2495
2494
|
return this.http.post(apiUrl, req);
|
|
2496
2495
|
};
|
|
2496
|
+
/**
|
|
2497
|
+
* @param {?} apiUrl
|
|
2498
|
+
* @return {?}
|
|
2499
|
+
*/
|
|
2500
|
+
WidgetContentService.prototype.getApiMethod = /**
|
|
2501
|
+
* @param {?} apiUrl
|
|
2502
|
+
* @return {?}
|
|
2503
|
+
*/
|
|
2504
|
+
function (apiUrl) {
|
|
2505
|
+
// req.query = req.query || '';
|
|
2506
|
+
return this.http.get(apiUrl);
|
|
2507
|
+
};
|
|
2497
2508
|
WidgetContentService.decorators = [
|
|
2498
2509
|
{ type: Injectable, args: [{
|
|
2499
2510
|
providedIn: 'root',
|
|
@@ -3709,7 +3720,6 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
3709
3720
|
_this.translate.use(lang);
|
|
3710
3721
|
}
|
|
3711
3722
|
_this.environment = environment;
|
|
3712
|
-
console.log('plugin');
|
|
3713
3723
|
return _this;
|
|
3714
3724
|
}
|
|
3715
3725
|
/**
|
|
@@ -4121,10 +4131,15 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
4121
4131
|
}
|
|
4122
4132
|
else if (filters.organisation &&
|
|
4123
4133
|
filters.organisation.indexOf('<orgID>') >= 0) {
|
|
4124
|
-
|
|
4125
|
-
|
|
4126
|
-
|
|
4127
|
-
|
|
4134
|
+
if (this.providerId) {
|
|
4135
|
+
filters.organisation = this.providerId;
|
|
4136
|
+
}
|
|
4137
|
+
else {
|
|
4138
|
+
filters.organisation = userData && userData.rootOrgId;
|
|
4139
|
+
if (filters && filters.hasOwnProperty('designation')) {
|
|
4140
|
+
filters.designation = userData.professionalDetails.length > 0 ?
|
|
4141
|
+
userData.professionalDetails[0].designation : '';
|
|
4142
|
+
}
|
|
4128
4143
|
}
|
|
4129
4144
|
}
|
|
4130
4145
|
return filters;
|
|
@@ -4152,7 +4167,9 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
4152
4167
|
this.fetchAllCbpPlans(strip, calculateParentStatus);
|
|
4153
4168
|
this.fetchAllTopContent(strip, calculateParentStatus);
|
|
4154
4169
|
this.fetchAllFeaturedContent(strip, calculateParentStatus);
|
|
4155
|
-
this.
|
|
4170
|
+
this.fetchAllBookMarkData(strip, calculateParentStatus);
|
|
4171
|
+
this.fetchAllPlaylistSearch(strip, calculateParentStatus);
|
|
4172
|
+
this.fetchPlaylistReadData(strip, calculateParentStatus);
|
|
4156
4173
|
// this.enrollInterval = setInterval(() => {
|
|
4157
4174
|
// this.fetchAllCbpPlans(strip, calculateParentStatus)
|
|
4158
4175
|
// }, 1000)
|
|
@@ -4882,7 +4899,9 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
4882
4899
|
(strip.request.trendingSearch && Object.keys(strip.request.trendingSearch).length) ||
|
|
4883
4900
|
(strip.request.topContent && Object.keys(strip.request.topContent).length) ||
|
|
4884
4901
|
(strip.request.featureContent && Object.keys(strip.request.featureContent).length) ||
|
|
4885
|
-
(strip.request.
|
|
4902
|
+
(strip.request.bookmarkRead && Object.keys(strip.request.bookmarkRead).length) ||
|
|
4903
|
+
(strip.request.playlistSearch && Object.keys(strip.request.playlistSearch).length) ||
|
|
4904
|
+
(strip.request.playlistRead && Object.keys(strip.request.playlistRead).length))) {
|
|
4886
4905
|
return true;
|
|
4887
4906
|
}
|
|
4888
4907
|
return false;
|
|
@@ -5558,6 +5577,61 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5558
5577
|
});
|
|
5559
5578
|
});
|
|
5560
5579
|
};
|
|
5580
|
+
/**
|
|
5581
|
+
* @param {?} strip
|
|
5582
|
+
* @param {?} request
|
|
5583
|
+
* @param {?} apiUrl
|
|
5584
|
+
* @param {?} calculateParentStatus
|
|
5585
|
+
* @return {?}
|
|
5586
|
+
*/
|
|
5587
|
+
ContentStripWithTabsLibComponent.prototype.getRequestMethod = /**
|
|
5588
|
+
* @param {?} strip
|
|
5589
|
+
* @param {?} request
|
|
5590
|
+
* @param {?} apiUrl
|
|
5591
|
+
* @param {?} calculateParentStatus
|
|
5592
|
+
* @return {?}
|
|
5593
|
+
*/
|
|
5594
|
+
function (strip, request, apiUrl, calculateParentStatus) {
|
|
5595
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
5596
|
+
var originalFilters;
|
|
5597
|
+
var _this = this;
|
|
5598
|
+
return __generator(this, function (_a) {
|
|
5599
|
+
originalFilters = [];
|
|
5600
|
+
return [2 /*return*/, new Promise((/**
|
|
5601
|
+
* @param {?} resolve
|
|
5602
|
+
* @param {?} reject
|
|
5603
|
+
* @return {?}
|
|
5604
|
+
*/
|
|
5605
|
+
function (resolve, reject) {
|
|
5606
|
+
if (request && request) {
|
|
5607
|
+
_this.contentSvc.getApiMethod(apiUrl).subscribe((/**
|
|
5608
|
+
* @param {?} results
|
|
5609
|
+
* @return {?}
|
|
5610
|
+
*/
|
|
5611
|
+
function (results) {
|
|
5612
|
+
console.log(results, 'results=========');
|
|
5613
|
+
/** @type {?} */
|
|
5614
|
+
var showViewMore = Boolean(results.result.data && results.result.data.orgList.length > 5 && strip.stripConfig && strip.stripConfig.postCardForSearch);
|
|
5615
|
+
/** @type {?} */
|
|
5616
|
+
var viewMoreUrl = showViewMore
|
|
5617
|
+
? {
|
|
5618
|
+
path: strip.viewMoreUrl && strip.viewMoreUrl.path || '',
|
|
5619
|
+
}
|
|
5620
|
+
: null;
|
|
5621
|
+
resolve({ results: results, viewMoreUrl: viewMoreUrl });
|
|
5622
|
+
}), (/**
|
|
5623
|
+
* @param {?} error
|
|
5624
|
+
* @return {?}
|
|
5625
|
+
*/
|
|
5626
|
+
function (error) {
|
|
5627
|
+
_this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5628
|
+
reject(error);
|
|
5629
|
+
}));
|
|
5630
|
+
}
|
|
5631
|
+
}))];
|
|
5632
|
+
});
|
|
5633
|
+
});
|
|
5634
|
+
};
|
|
5561
5635
|
/**
|
|
5562
5636
|
* @param {?} filters
|
|
5563
5637
|
* @return {?}
|
|
@@ -5573,6 +5647,28 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5573
5647
|
}
|
|
5574
5648
|
return filters;
|
|
5575
5649
|
};
|
|
5650
|
+
/**
|
|
5651
|
+
* @param {?} apiUrl
|
|
5652
|
+
* @param {?} id
|
|
5653
|
+
* @return {?}
|
|
5654
|
+
*/
|
|
5655
|
+
ContentStripWithTabsLibComponent.prototype.getFullUrl = /**
|
|
5656
|
+
* @param {?} apiUrl
|
|
5657
|
+
* @param {?} id
|
|
5658
|
+
* @return {?}
|
|
5659
|
+
*/
|
|
5660
|
+
function (apiUrl, id) {
|
|
5661
|
+
/** @type {?} */
|
|
5662
|
+
var formedUrl = '';
|
|
5663
|
+
if (apiUrl.indexOf('<bookmarkId>') >= 0) {
|
|
5664
|
+
formedUrl = apiUrl.replace('<bookmarkId>', this.environment.mdoChannelsBookmarkId);
|
|
5665
|
+
}
|
|
5666
|
+
else if (apiUrl.indexOf('<playlistKey>') >= 0 && apiUrl.indexOf('<orgID>') >= 0) {
|
|
5667
|
+
formedUrl = apiUrl.replace('<playlistKey>', this.providerId + id);
|
|
5668
|
+
formedUrl = formedUrl.replace('<orgID>', this.providerId);
|
|
5669
|
+
}
|
|
5670
|
+
return formedUrl;
|
|
5671
|
+
};
|
|
5576
5672
|
/**
|
|
5577
5673
|
* @param {?} stripData
|
|
5578
5674
|
* @param {?} path
|
|
@@ -5598,7 +5694,7 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5598
5694
|
* @param {?=} calculateParentStatus
|
|
5599
5695
|
* @return {?}
|
|
5600
5696
|
*/
|
|
5601
|
-
ContentStripWithTabsLibComponent.prototype.
|
|
5697
|
+
ContentStripWithTabsLibComponent.prototype.fetchAllBookMarkData = /**
|
|
5602
5698
|
* @param {?} strip
|
|
5603
5699
|
* @param {?=} calculateParentStatus
|
|
5604
5700
|
* @return {?}
|
|
@@ -5606,74 +5702,27 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5606
5702
|
function (strip, calculateParentStatus) {
|
|
5607
5703
|
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5608
5704
|
return __awaiter(this, void 0, void 0, function () {
|
|
5609
|
-
var originalFilters,
|
|
5705
|
+
var originalFilters, response, content, error_7;
|
|
5610
5706
|
return __generator(this, function (_a) {
|
|
5611
5707
|
switch (_a.label) {
|
|
5612
5708
|
case 0:
|
|
5613
|
-
if (!(strip.request && strip.request.
|
|
5709
|
+
if (!(strip.request && strip.request.bookmarkRead && Object.keys(strip.request.bookmarkRead).length)) return [3 /*break*/, 4];
|
|
5614
5710
|
originalFilters = [];
|
|
5615
5711
|
if (strip.request &&
|
|
5616
|
-
strip.request.
|
|
5617
|
-
strip.request.
|
|
5618
|
-
strip.request.
|
|
5619
|
-
originalFilters = strip.request.channels.request.filters;
|
|
5620
|
-
strip.request.channels.request.filters = this.postMethodFilters(strip.request.channels.request.filters);
|
|
5712
|
+
strip.request.bookmarkRead &&
|
|
5713
|
+
strip.request.bookmarkRead.bookmarkId) {
|
|
5714
|
+
strip.request.apiUrl = this.getFullUrl(strip.request.apiUrl, strip.request.bookmarkRead.bookmarkId);
|
|
5621
5715
|
}
|
|
5622
5716
|
_a.label = 1;
|
|
5623
5717
|
case 1:
|
|
5624
5718
|
_a.trys.push([1, 3, , 4]);
|
|
5625
|
-
|
|
5626
|
-
{
|
|
5627
|
-
// tslint:disable-next-line: max-line-length
|
|
5628
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5629
|
-
appIcon: '',
|
|
5630
|
-
name: 'Ministry of Consumer Affairs, Food and Public Distribution',
|
|
5631
|
-
programCount: '10',
|
|
5632
|
-
},
|
|
5633
|
-
{
|
|
5634
|
-
// tslint:disable-next-line: max-line-length
|
|
5635
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5636
|
-
appIcon: '',
|
|
5637
|
-
name: 'Ministry of Railways',
|
|
5638
|
-
programCount: '10',
|
|
5639
|
-
},
|
|
5640
|
-
{
|
|
5641
|
-
// tslint:disable-next-line: max-line-length
|
|
5642
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5643
|
-
appIcon: '',
|
|
5644
|
-
name: 'Department of Post',
|
|
5645
|
-
programCount: '10',
|
|
5646
|
-
},
|
|
5647
|
-
{
|
|
5648
|
-
// tslint:disable-next-line: max-line-length
|
|
5649
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5650
|
-
appIcon: '',
|
|
5651
|
-
name: 'NLC India Limited',
|
|
5652
|
-
programCount: '30',
|
|
5653
|
-
},
|
|
5654
|
-
{
|
|
5655
|
-
// tslint:disable-next-line: max-line-length
|
|
5656
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5657
|
-
appIcon: '',
|
|
5658
|
-
name: 'Mission Karmayogi',
|
|
5659
|
-
programCount: '24',
|
|
5660
|
-
},
|
|
5661
|
-
{
|
|
5662
|
-
// tslint:disable-next-line: max-line-length
|
|
5663
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5664
|
-
appIcon: '',
|
|
5665
|
-
name: 'Mission Karmayogi',
|
|
5666
|
-
programCount: '50',
|
|
5667
|
-
},
|
|
5668
|
-
];
|
|
5669
|
-
return [4 /*yield*/, data
|
|
5670
|
-
// console.log('calling after - response, ', response)
|
|
5671
|
-
];
|
|
5719
|
+
return [4 /*yield*/, this.getRequestMethod(strip, strip.request.bookmarkRead, strip.request.apiUrl, calculateParentStatus)];
|
|
5672
5720
|
case 2:
|
|
5673
5721
|
response = _a.sent();
|
|
5674
|
-
|
|
5722
|
+
console.log('calling after - response, ', response);
|
|
5723
|
+
content = response.results.result.data.orgList;
|
|
5675
5724
|
if (response) {
|
|
5676
|
-
this.processStrip(strip, this.transformAllContentsToWidgets(
|
|
5725
|
+
this.processStrip(strip, this.transformAllContentsToWidgets(content, strip), 'done', calculateParentStatus, response);
|
|
5677
5726
|
}
|
|
5678
5727
|
else {
|
|
5679
5728
|
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
@@ -5719,6 +5768,112 @@ var ContentStripWithTabsLibComponent = /** @class */ (function (_super) {
|
|
|
5719
5768
|
widgetData: {},
|
|
5720
5769
|
}); }));
|
|
5721
5770
|
};
|
|
5771
|
+
/**
|
|
5772
|
+
* @param {?} strip
|
|
5773
|
+
* @param {?=} calculateParentStatus
|
|
5774
|
+
* @return {?}
|
|
5775
|
+
*/
|
|
5776
|
+
ContentStripWithTabsLibComponent.prototype.fetchAllPlaylistSearch = /**
|
|
5777
|
+
* @param {?} strip
|
|
5778
|
+
* @param {?=} calculateParentStatus
|
|
5779
|
+
* @return {?}
|
|
5780
|
+
*/
|
|
5781
|
+
function (strip, calculateParentStatus) {
|
|
5782
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5783
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
5784
|
+
var originalFilters, response, error_8;
|
|
5785
|
+
return __generator(this, function (_a) {
|
|
5786
|
+
switch (_a.label) {
|
|
5787
|
+
case 0:
|
|
5788
|
+
if (!(strip.request && strip.request.playlistSearch && Object.keys(strip.request.playlistSearch).length)) return [3 /*break*/, 4];
|
|
5789
|
+
originalFilters = [];
|
|
5790
|
+
if (strip.request &&
|
|
5791
|
+
strip.request.playlistSearch &&
|
|
5792
|
+
strip.request.playlistSearch.request &&
|
|
5793
|
+
strip.request.playlistSearch.request.filters) {
|
|
5794
|
+
originalFilters = strip.request.playlistSearch.request.filters;
|
|
5795
|
+
strip.request.playlistSearch.request.filters = this.postMethodFilters(strip.request.playlistSearch.request.filters);
|
|
5796
|
+
}
|
|
5797
|
+
_a.label = 1;
|
|
5798
|
+
case 1:
|
|
5799
|
+
_a.trys.push([1, 3, , 4]);
|
|
5800
|
+
return [4 /*yield*/, this.postRequestMethod(strip, strip.request.playlistSearch.request, strip.request.apiUrl, calculateParentStatus)];
|
|
5801
|
+
case 2:
|
|
5802
|
+
response = _a.sent();
|
|
5803
|
+
// console.log('calling after - response, ', response)
|
|
5804
|
+
if (response && response.results) {
|
|
5805
|
+
// console.log('calling after-- ')
|
|
5806
|
+
if (response.results.result.data && response.results.result.data.length) {
|
|
5807
|
+
this.processStrip(strip, this.transformContentsToWidgets(response.results.result.data, strip), 'done', calculateParentStatus, response.viewMoreUrl);
|
|
5808
|
+
}
|
|
5809
|
+
else {
|
|
5810
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5811
|
+
this.emptyResponse.emit(true);
|
|
5812
|
+
}
|
|
5813
|
+
}
|
|
5814
|
+
else {
|
|
5815
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5816
|
+
this.emptyResponse.emit(true);
|
|
5817
|
+
}
|
|
5818
|
+
return [3 /*break*/, 4];
|
|
5819
|
+
case 3:
|
|
5820
|
+
error_8 = _a.sent();
|
|
5821
|
+
this.emptyResponse.emit(true);
|
|
5822
|
+
return [3 /*break*/, 4];
|
|
5823
|
+
case 4: return [2 /*return*/];
|
|
5824
|
+
}
|
|
5825
|
+
});
|
|
5826
|
+
});
|
|
5827
|
+
};
|
|
5828
|
+
/**
|
|
5829
|
+
* @param {?} strip
|
|
5830
|
+
* @param {?=} calculateParentStatus
|
|
5831
|
+
* @return {?}
|
|
5832
|
+
*/
|
|
5833
|
+
ContentStripWithTabsLibComponent.prototype.fetchPlaylistReadData = /**
|
|
5834
|
+
* @param {?} strip
|
|
5835
|
+
* @param {?=} calculateParentStatus
|
|
5836
|
+
* @return {?}
|
|
5837
|
+
*/
|
|
5838
|
+
function (strip, calculateParentStatus) {
|
|
5839
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5840
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
5841
|
+
var originalFilters, response, content, error_9;
|
|
5842
|
+
return __generator(this, function (_a) {
|
|
5843
|
+
switch (_a.label) {
|
|
5844
|
+
case 0:
|
|
5845
|
+
if (!(strip.request && strip.request.playlistRead && Object.keys(strip.request.playlistRead).length)) return [3 /*break*/, 4];
|
|
5846
|
+
originalFilters = [];
|
|
5847
|
+
if (strip.request &&
|
|
5848
|
+
strip.request.playlistRead &&
|
|
5849
|
+
strip.request.playlistRead.type) {
|
|
5850
|
+
strip.request.apiUrl = this.getFullUrl(strip.request.apiUrl, strip.request.playlistRead.type);
|
|
5851
|
+
}
|
|
5852
|
+
_a.label = 1;
|
|
5853
|
+
case 1:
|
|
5854
|
+
_a.trys.push([1, 3, , 4]);
|
|
5855
|
+
return [4 /*yield*/, this.getRequestMethod(strip, strip.request.playlistRead, strip.request.apiUrl, calculateParentStatus)];
|
|
5856
|
+
case 2:
|
|
5857
|
+
response = _a.sent();
|
|
5858
|
+
console.log('calling after - response, ', response);
|
|
5859
|
+
if (response && response.results.result.content) {
|
|
5860
|
+
content = response.results.result.content;
|
|
5861
|
+
this.processStrip(strip, this.transformAllContentsToWidgets(content, strip), 'done', calculateParentStatus, response);
|
|
5862
|
+
}
|
|
5863
|
+
else {
|
|
5864
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5865
|
+
this.emptyResponse.emit(true);
|
|
5866
|
+
}
|
|
5867
|
+
return [3 /*break*/, 4];
|
|
5868
|
+
case 3:
|
|
5869
|
+
error_9 = _a.sent();
|
|
5870
|
+
this.emptyResponse.emit(true);
|
|
5871
|
+
return [3 /*break*/, 4];
|
|
5872
|
+
case 4: return [2 /*return*/];
|
|
5873
|
+
}
|
|
5874
|
+
});
|
|
5875
|
+
});
|
|
5876
|
+
};
|
|
5722
5877
|
ContentStripWithTabsLibComponent.decorators = [
|
|
5723
5878
|
{ type: Component, args: [{
|
|
5724
5879
|
selector: 'sb-uic-content-strip-with-tabs',
|
|
@@ -6400,7 +6555,8 @@ var SlidersLibModule = /** @class */ (function () {
|
|
|
6400
6555
|
/** @type {?} */
|
|
6401
6556
|
var API_END_POINTS$2 = {
|
|
6402
6557
|
PROVIDER_INSIGHTS: "/apis/proxies/v8/microsite/read/insights",
|
|
6403
|
-
TRAINING_DETAILS: "apis/proxies/v8/sunbirdigot/search"
|
|
6558
|
+
TRAINING_DETAILS: "apis/proxies/v8/sunbirdigot/search",
|
|
6559
|
+
ANNOUNCEMENTS_DETAILS: "apis/proxies/v8/announcements/v1/search"
|
|
6404
6560
|
};
|
|
6405
6561
|
var InsiteDataService = /** @class */ (function () {
|
|
6406
6562
|
function InsiteDataService(http) {
|
|
@@ -6417,6 +6573,17 @@ var InsiteDataService = /** @class */ (function () {
|
|
|
6417
6573
|
function (request) {
|
|
6418
6574
|
return this.http.post(API_END_POINTS$2.PROVIDER_INSIGHTS, request);
|
|
6419
6575
|
};
|
|
6576
|
+
/**
|
|
6577
|
+
* @param {?} request
|
|
6578
|
+
* @return {?}
|
|
6579
|
+
*/
|
|
6580
|
+
InsiteDataService.prototype.fetchAnnouncementsData = /**
|
|
6581
|
+
* @param {?} request
|
|
6582
|
+
* @return {?}
|
|
6583
|
+
*/
|
|
6584
|
+
function (request) {
|
|
6585
|
+
return this.http.post(API_END_POINTS$2.ANNOUNCEMENTS_DETAILS, request);
|
|
6586
|
+
};
|
|
6420
6587
|
/**
|
|
6421
6588
|
* @param {?} request
|
|
6422
6589
|
* @return {?}
|
|
@@ -6705,7 +6872,6 @@ var CalenderComponent = /** @class */ (function () {
|
|
|
6705
6872
|
this.currentMonthAndYear = this.datePipe.transform(this.currentDate, 'MMMM y');
|
|
6706
6873
|
this.selectedMonth = this.datePipe.transform(this.currentDate, 'LLLL yyyy');
|
|
6707
6874
|
if (this.fullCalendor) {
|
|
6708
|
-
console.log("this.currentDate ", this.currentDate);
|
|
6709
6875
|
this.days = this.getDaysInMonth(this.currentDate.getFullYear(), this.currentDate.getMonth());
|
|
6710
6876
|
this.getMonthsDropdownData();
|
|
6711
6877
|
}
|
|
@@ -8000,11 +8166,13 @@ var CommonStripModule = /** @class */ (function () {
|
|
|
8000
8166
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
8001
8167
|
*/
|
|
8002
8168
|
var AnnouncementsComponent = /** @class */ (function () {
|
|
8003
|
-
function AnnouncementsComponent() {
|
|
8169
|
+
function AnnouncementsComponent(insightSvc) {
|
|
8170
|
+
this.insightSvc = insightSvc;
|
|
8004
8171
|
this.mobileHeight = false;
|
|
8172
|
+
this.fetchDataFromApi = false;
|
|
8005
8173
|
this.openDialog = new EventEmitter();
|
|
8006
8174
|
this.isLoading = false;
|
|
8007
|
-
this.
|
|
8175
|
+
this.announcements = [];
|
|
8008
8176
|
}
|
|
8009
8177
|
/**
|
|
8010
8178
|
* @return {?}
|
|
@@ -8012,14 +8180,67 @@ var AnnouncementsComponent = /** @class */ (function () {
|
|
|
8012
8180
|
AnnouncementsComponent.prototype.ngOnInit = /**
|
|
8013
8181
|
* @return {?}
|
|
8014
8182
|
*/
|
|
8183
|
+
function () {
|
|
8184
|
+
if (this.fetchDataFromApi) {
|
|
8185
|
+
this.isLoading = true;
|
|
8186
|
+
this.fetchData();
|
|
8187
|
+
}
|
|
8188
|
+
};
|
|
8189
|
+
/**
|
|
8190
|
+
* @return {?}
|
|
8191
|
+
*/
|
|
8192
|
+
AnnouncementsComponent.prototype.fetchData = /**
|
|
8193
|
+
* @return {?}
|
|
8194
|
+
*/
|
|
8015
8195
|
function () {
|
|
8016
8196
|
var _this = this;
|
|
8017
|
-
|
|
8197
|
+
/** @type {?} */
|
|
8198
|
+
var request = {
|
|
8199
|
+
filterCriteriaMap: {
|
|
8200
|
+
channel: [this.channelId],
|
|
8201
|
+
},
|
|
8202
|
+
requestedFields: [
|
|
8203
|
+
"name",
|
|
8204
|
+
"description",
|
|
8205
|
+
"createdOn",
|
|
8206
|
+
"updatedOn",
|
|
8207
|
+
"category"
|
|
8208
|
+
],
|
|
8209
|
+
orderBy: "createdOn",
|
|
8210
|
+
orderDirection: "ASC",
|
|
8211
|
+
facets: [
|
|
8212
|
+
"channel"
|
|
8213
|
+
],
|
|
8214
|
+
pageSize: this.objectData.pageSize
|
|
8215
|
+
};
|
|
8216
|
+
this.insightSvc.fetchAnnouncementsData(request).subscribe((/**
|
|
8217
|
+
* @param {?} res
|
|
8018
8218
|
* @return {?}
|
|
8019
8219
|
*/
|
|
8020
|
-
function () {
|
|
8220
|
+
function (res) {
|
|
8221
|
+
if (res && res.result && res.result.data) {
|
|
8222
|
+
res.result.data.forEach((/**
|
|
8223
|
+
* @param {?} resp
|
|
8224
|
+
* @return {?}
|
|
8225
|
+
*/
|
|
8226
|
+
function (resp) {
|
|
8227
|
+
_this.announcements.push({
|
|
8228
|
+
value: resp.description,
|
|
8229
|
+
expanded: false
|
|
8230
|
+
});
|
|
8231
|
+
}));
|
|
8232
|
+
}
|
|
8233
|
+
_this.objectData.list = _this.announcements;
|
|
8234
|
+
_this.isLoading = false;
|
|
8235
|
+
}), (/**
|
|
8236
|
+
* @param {?} error
|
|
8237
|
+
* @return {?}
|
|
8238
|
+
*/
|
|
8239
|
+
function (error) {
|
|
8240
|
+
console.log(error);
|
|
8241
|
+
_this.objectData.list = [];
|
|
8021
8242
|
_this.isLoading = false;
|
|
8022
|
-
})
|
|
8243
|
+
}));
|
|
8023
8244
|
};
|
|
8024
8245
|
/**
|
|
8025
8246
|
* @param {?} item
|
|
@@ -8046,16 +8267,20 @@ var AnnouncementsComponent = /** @class */ (function () {
|
|
|
8046
8267
|
AnnouncementsComponent.decorators = [
|
|
8047
8268
|
{ type: Component, args: [{
|
|
8048
8269
|
selector: 'sb-uic-announcements',
|
|
8049
|
-
template: "<div class=\"w-full\" *ngIf=\"layoutType === 'web' && !isLoading\">\n <div class=\"flex item-center key-logo\">\n <img class=\"\" [src]=\"objectData?.logoUrl\">\n </div>\n <div class=\"flex item-center key-logo\">\n <div class=\"key-heading\"\n [style.backgroundColor]=\"objectData?.header?.background\"\n [style.color]=\"objectData?.header?.color\">\n {{objectData?.title}}\n </div>\n </div>\n <div class=\"key-list-container\"\n [style.borderColor]=\"objectData?.panelborder\"\n [style.backgroundColor]=\"objectData?.panelBackground\">\n <div class=\"{{mobileHeight ? 'mob-key-list' : 'key-list'}}\" >\n <div *ngFor=\"let item of objectData?.list; let i = index\">\n <div class=\"key-list-item mb-{{ objectData?.list?.length === (i+1) ? '' : '4'}}\" \n [style.borderColor]=\"objectData?.listItem?.border\"\n [style.backgroundColor]=\"objectData?.listItem?.background\">\n <div class=\"key-list-item-content {{item?.value?.length > 152 && !item?.expanded ? 'expand' : 'un-expand'}}\" [innerHTML]=\"item?.value\"></div>\n <div class=\"more-or-less\" *ngIf=\"item?.value?.length > 152\" [style.color]=\"objectData?.panelborder\">\n <div class=\"cursor-pointer\" (click)=\"viewMoreOrLess(item)\" *ngIf=\"!item?.expanded\">View more</div>\n <div class=\"cursor-pointer\" (click)=\"viewMoreOrLess(item)\" *ngIf=\"item?.expanded\">View less</div>\n </div>\n </div>\n </div> \n </div
|
|
8050
|
-
styles: [".key-logo{align-items:center;justify-content:center}.key-list-container{border:1px solid #ccc;padding:45px 15px 15px;border-radius:12px;margin-top:-20px}.key-list{
|
|
8270
|
+
template: "<div class=\"w-full\" *ngIf=\"layoutType === 'web' && !isLoading\">\n <div class=\"flex item-center key-logo\">\n <img class=\"\" [src]=\"objectData?.logoUrl\">\n </div>\n <div class=\"flex item-center key-logo\">\n <div class=\"key-heading\"\n [style.backgroundColor]=\"objectData?.header?.background\"\n [style.color]=\"objectData?.header?.color\">\n {{objectData?.title}}\n </div>\n </div>\n <div class=\"key-list-container\"\n [style.borderColor]=\"objectData?.panelborder\"\n [style.backgroundColor]=\"objectData?.panelBackground\">\n <div class=\"{{mobileHeight ? 'mob-key-list' : 'key-list'}}\" *ngIf=\"objectData?.list?.length\">\n <div *ngFor=\"let item of objectData?.list; let i = index\">\n <div class=\"key-list-item mb-{{ objectData?.list?.length === (i+1) ? '' : '4'}}\" \n [style.borderColor]=\"objectData?.listItem?.border\"\n [style.backgroundColor]=\"objectData?.listItem?.background\">\n <div class=\"key-list-item-content {{item?.value?.length > 152 && !item?.expanded ? 'expand' : 'un-expand'}}\" [innerHTML]=\"item?.value\"></div>\n <div class=\"more-or-less\" *ngIf=\"item?.value?.length > 152\" [style.color]=\"objectData?.panelborder\">\n <div class=\"cursor-pointer\" (click)=\"viewMoreOrLess(item)\" *ngIf=\"!item?.expanded\">View more</div>\n <div class=\"cursor-pointer\" (click)=\"viewMoreOrLess(item)\" *ngIf=\"item?.expanded\">View less</div>\n </div>\n </div>\n </div> \n </div>\n <div class=\"{{mobileHeight ? 'mob-key-list' : 'key-list'}}\" *ngIf=\"!objectData?.list?.length\">\n <div class=\"text-center\">No announcements yet!</div>\n </div>\n </div>\n</div>\n\n<div class=\"w-full\" *ngIf=\"layoutType === 'mobile'\">\n <div class=\"flex item-center key-logo \">\n <div class=\"mob-key-heading\" (click)=\"openAnnouncements()\"\n [style.backgroundColor]=\"objectData?.header?.background\"\n [style.color]=\"objectData?.header?.color\">\n <div class=\"flex key-button gap-3\">\n <div>\n <img [src]=\"objectData?.mobileIcon\">\n </div>\n <div>{{objectData?.title}}</div> \n <div><mat-icon class=\"key-mob-icon\">arrow_forward_ios</mat-icon></div>\n </div> \n </div>\n </div>\n</div>\n\n<div class=\"w-full\" *ngIf=\"layoutType === 'web' && isLoading\">\n <div class=\"flex item-center key-logo\">\n <img class=\"\" [src]=\"objectData?.logoUrl\">\n </div>\n <div class=\"flex item-center key-logo pt-1\">\n <div class=\"key-heading\"\n [style.backgroundColor]=\"objectData?.header?.background\"\n [style.color]=\"objectData?.header?.color\">\n {{objectData?.title}}\n </div>\n </div>\n <div class=\"key-list-container\"\n [style.borderColor]=\"objectData?.panelborder\"\n [style.backgroundColor]=\"objectData?.panelBackground\">\n <div class=\"{{mobileHeight ? 'mob-key-list' : 'key-list'}}\" > \n <div class=\"key-list-item mb-4\" \n *ngFor=\"let item of[0,1,2,3,4]; let i = index\"\n [style.borderColor]=\"objectData?.listItem?.border\"\n [style.backgroundColor]=\"objectData?.listItem?.background\">\n <div class=\"key-list-item-content un-expand\">\n <div class=\"py-1\">\n <sb-uic-skeleton-loader [bindingClass]=\"'flex rounded objIcon '\" [width]=\"'350px'\" [height]=\"'24px'\">\n </sb-uic-skeleton-loader>\n </div>\n <div class=\"py-1\">\n <sb-uic-skeleton-loader [bindingClass]=\"'flex rounded objIcon '\" [width]=\"'350px'\" [height]=\"'24px'\">\n </sb-uic-skeleton-loader>\n </div>\n </div>\n </div>\n </div> \n </div>\n</div>\n",
|
|
8271
|
+
styles: [".key-logo{align-items:center;justify-content:center}.key-list-container{border:1px solid #ccc;padding:45px 15px 15px;border-radius:12px;margin-top:-20px}.key-list{height:600px;overflow:auto}.mob-key-list{height:calc(100vh - 252px);overflow:auto}.key-list::-webkit-scrollbar{display:none}.key-list-item{padding:16px;border:1px solid #ccc;border-radius:12px;min-height:56px}::ng-deep .key-list-item-content a{color:#1b4ca1!important}.key-list-item-content{font-family:Lato;font-size:14px;font-weight:400;line-height:20px;text-align:left;white-space:initial;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical}.expand{-webkit-line-clamp:3}.un-expand{-webkit-line-clamp:0}.more-or-less{font-family:Lato;font-size:14px;line-height:20px;font-weight:600}.mob-key-heading{font-family:Montserrat;font-size:16px;font-weight:600;line-height:19.5px;text-align:center;padding:7px 25px;border-radius:20px;animation:.9s infinite mobPaddingAnimation;cursor:pointer}.key-mob-icon{font-size:12px;width:12px;height:12px}.key-button{align-items:center;justify-content:center}.key-heading{font-family:Montserrat;font-size:16px;font-weight:600;line-height:19.5px;text-align:center;padding:10px 50px;border-radius:20px;margin-top:-3px;animation:.9s infinite paddingAnimation}@keyframes mobPaddingAnimation{0%,100%{padding:7px 25px}25%,75%{padding:7px 30px}50%{padding:7px 35px}}@keyframes paddingAnimation{0%,100%{padding:10px 50px}25%,75%{padding:10px 55px}50%{padding:10px 60px}}"]
|
|
8051
8272
|
}] }
|
|
8052
8273
|
];
|
|
8053
8274
|
/** @nocollapse */
|
|
8054
|
-
AnnouncementsComponent.ctorParameters = function () { return [
|
|
8275
|
+
AnnouncementsComponent.ctorParameters = function () { return [
|
|
8276
|
+
{ type: InsiteDataService }
|
|
8277
|
+
]; };
|
|
8055
8278
|
AnnouncementsComponent.propDecorators = {
|
|
8056
8279
|
objectData: [{ type: Input }],
|
|
8057
8280
|
layoutType: [{ type: Input }],
|
|
8058
8281
|
mobileHeight: [{ type: Input }],
|
|
8282
|
+
fetchDataFromApi: [{ type: Input }],
|
|
8283
|
+
channelId: [{ type: Input }],
|
|
8059
8284
|
openDialog: [{ type: Output }]
|
|
8060
8285
|
};
|
|
8061
8286
|
return AnnouncementsComponent;
|
|
@@ -8068,9 +8293,17 @@ if (false) {
|
|
|
8068
8293
|
/** @type {?} */
|
|
8069
8294
|
AnnouncementsComponent.prototype.mobileHeight;
|
|
8070
8295
|
/** @type {?} */
|
|
8296
|
+
AnnouncementsComponent.prototype.fetchDataFromApi;
|
|
8297
|
+
/** @type {?} */
|
|
8298
|
+
AnnouncementsComponent.prototype.channelId;
|
|
8299
|
+
/** @type {?} */
|
|
8071
8300
|
AnnouncementsComponent.prototype.openDialog;
|
|
8072
8301
|
/** @type {?} */
|
|
8073
8302
|
AnnouncementsComponent.prototype.isLoading;
|
|
8303
|
+
/** @type {?} */
|
|
8304
|
+
AnnouncementsComponent.prototype.announcements;
|
|
8305
|
+
/** @type {?} */
|
|
8306
|
+
AnnouncementsComponent.prototype.insightSvc;
|
|
8074
8307
|
}
|
|
8075
8308
|
|
|
8076
8309
|
/**
|
|
@@ -8214,6 +8447,7 @@ var CardsComponent = /** @class */ (function (_super) {
|
|
|
8214
8447
|
_this.configSvc = configSvc;
|
|
8215
8448
|
_this.contSvc = contSvc;
|
|
8216
8449
|
_this.router = router;
|
|
8450
|
+
_this.triggerTelemetry = new EventEmitter();
|
|
8217
8451
|
_this.isIntranetAllowedSettings = false;
|
|
8218
8452
|
return _this;
|
|
8219
8453
|
}
|
|
@@ -8310,10 +8544,21 @@ var CardsComponent = /** @class */ (function (_super) {
|
|
|
8310
8544
|
clearInterval(this.cbPlanInterval);
|
|
8311
8545
|
}
|
|
8312
8546
|
};
|
|
8547
|
+
/**
|
|
8548
|
+
* @param {?} data
|
|
8549
|
+
* @return {?}
|
|
8550
|
+
*/
|
|
8551
|
+
CardsComponent.prototype.raiseCardClick = /**
|
|
8552
|
+
* @param {?} data
|
|
8553
|
+
* @return {?}
|
|
8554
|
+
*/
|
|
8555
|
+
function (data) {
|
|
8556
|
+
this.triggerTelemetry.emit(data);
|
|
8557
|
+
};
|
|
8313
8558
|
CardsComponent.decorators = [
|
|
8314
8559
|
{ type: Component, args: [{
|
|
8315
8560
|
selector: 'sb-uic-cards',
|
|
8316
|
-
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>\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 (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\" [isCardLoading]=\"true\"></sb-uic-card-landscape>\n</ng-template>\n<ng-template #cardLandscapeLib>\n <sb-uic-card-landscape (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\" [isCardLoading]=\"false\"></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
|
|
8561
|
+
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 (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\" [isCardLoading]=\"true\"></sb-uic-card-landscape>\n</ng-template>\n<ng-template #cardLandscapeLib>\n <sb-uic-card-landscape (contentData)=\"getRedirectUrlData($event)\" [widgetData]=\"widgetData\" [isCardLoading]=\"false\"></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>",
|
|
8317
8562
|
styles: [""]
|
|
8318
8563
|
}] }
|
|
8319
8564
|
];
|
|
@@ -8325,7 +8570,8 @@ var CardsComponent = /** @class */ (function (_super) {
|
|
|
8325
8570
|
{ type: Router }
|
|
8326
8571
|
]; };
|
|
8327
8572
|
CardsComponent.propDecorators = {
|
|
8328
|
-
widgetData: [{ type: Input }]
|
|
8573
|
+
widgetData: [{ type: Input }],
|
|
8574
|
+
triggerTelemetry: [{ type: Output }]
|
|
8329
8575
|
};
|
|
8330
8576
|
return CardsComponent;
|
|
8331
8577
|
}(WidgetBaseComponent));
|
|
@@ -8333,6 +8579,8 @@ if (false) {
|
|
|
8333
8579
|
/** @type {?} */
|
|
8334
8580
|
CardsComponent.prototype.widgetData;
|
|
8335
8581
|
/** @type {?} */
|
|
8582
|
+
CardsComponent.prototype.triggerTelemetry;
|
|
8583
|
+
/** @type {?} */
|
|
8336
8584
|
CardsComponent.prototype.isIntranetAllowedSettings;
|
|
8337
8585
|
/** @type {?} */
|
|
8338
8586
|
CardsComponent.prototype.cbPlanMapData;
|
|
@@ -8477,7 +8725,7 @@ var CardPortraitComponent = /** @class */ (function () {
|
|
|
8477
8725
|
{ type: Component, args: [{
|
|
8478
8726
|
selector: 'sb-uic-card-portrait',
|
|
8479
8727
|
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-standard-container mr-5 padding-remove cursor-pointer \" [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>",
|
|
8480
|
-
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:
|
|
8728
|
+
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}"]
|
|
8481
8729
|
}] }
|
|
8482
8730
|
];
|
|
8483
8731
|
/** @nocollapse */
|
|
@@ -9449,13 +9697,16 @@ if (false) {
|
|
|
9449
9697
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
9450
9698
|
*/
|
|
9451
9699
|
var CardMDOChannelComponent = /** @class */ (function () {
|
|
9452
|
-
function CardMDOChannelComponent(events, translate, langtranslations, configSvc) {
|
|
9700
|
+
function CardMDOChannelComponent(events, translate, langtranslations, configSvc, contSvc, router) {
|
|
9453
9701
|
var _this = this;
|
|
9454
9702
|
this.events = events;
|
|
9455
9703
|
this.translate = translate;
|
|
9456
9704
|
this.langtranslations = langtranslations;
|
|
9457
9705
|
this.configSvc = configSvc;
|
|
9458
|
-
this.
|
|
9706
|
+
this.contSvc = contSvc;
|
|
9707
|
+
this.router = router;
|
|
9708
|
+
this.channelData = new EventEmitter();
|
|
9709
|
+
this.emitTelemetry = new EventEmitter();
|
|
9459
9710
|
this.widgetType = '';
|
|
9460
9711
|
this.widgetSubType = '';
|
|
9461
9712
|
this.langtranslations.languageSelectedObservable.subscribe((/**
|
|
@@ -9490,34 +9741,47 @@ var CardMDOChannelComponent = /** @class */ (function () {
|
|
|
9490
9741
|
}
|
|
9491
9742
|
};
|
|
9492
9743
|
/**
|
|
9744
|
+
* @param {?} contentData
|
|
9493
9745
|
* @return {?}
|
|
9494
9746
|
*/
|
|
9495
9747
|
CardMDOChannelComponent.prototype.raiseTelemetry = /**
|
|
9748
|
+
* @param {?} contentData
|
|
9496
9749
|
* @return {?}
|
|
9497
9750
|
*/
|
|
9498
|
-
function () {
|
|
9499
|
-
|
|
9500
|
-
|
|
9501
|
-
|
|
9502
|
-
|
|
9503
|
-
|
|
9504
|
-
|
|
9505
|
-
|
|
9506
|
-
|
|
9507
|
-
|
|
9508
|
-
|
|
9509
|
-
|
|
9510
|
-
|
|
9511
|
-
|
|
9512
|
-
|
|
9513
|
-
|
|
9514
|
-
|
|
9751
|
+
function (contentData) {
|
|
9752
|
+
this.emitTelemetry.emit(contentData);
|
|
9753
|
+
if (this.widgetData) {
|
|
9754
|
+
contentData['typeOfTelemetry'] = 'mdo-channel';
|
|
9755
|
+
}
|
|
9756
|
+
this.contSvc.changeTelemetryData(contentData);
|
|
9757
|
+
};
|
|
9758
|
+
/**
|
|
9759
|
+
* @param {?} channeldata
|
|
9760
|
+
* @return {?}
|
|
9761
|
+
*/
|
|
9762
|
+
CardMDOChannelComponent.prototype.channelClick = /**
|
|
9763
|
+
* @param {?} channeldata
|
|
9764
|
+
* @return {?}
|
|
9765
|
+
*/
|
|
9766
|
+
function (channeldata) {
|
|
9767
|
+
this.channelData.emit(channeldata);
|
|
9768
|
+
};
|
|
9769
|
+
/**
|
|
9770
|
+
* @param {?} content
|
|
9771
|
+
* @return {?}
|
|
9772
|
+
*/
|
|
9773
|
+
CardMDOChannelComponent.prototype.redirectTo = /**
|
|
9774
|
+
* @param {?} content
|
|
9775
|
+
* @return {?}
|
|
9776
|
+
*/
|
|
9777
|
+
function (content) {
|
|
9778
|
+
this.router.navigate(["/app/learn/mdo-channels/" + content.orgName + "/" + content.identifier + "/micro-sites"]);
|
|
9515
9779
|
};
|
|
9516
9780
|
CardMDOChannelComponent.decorators = [
|
|
9517
9781
|
{ type: Component, args: [{
|
|
9518
9782
|
selector: 'sb-uic-card-mdo-channel',
|
|
9519
|
-
template: "<mat-card class=\"channels-card card-channels-container mr-5 padding-remove cursor-pointer\">\n <div class=\"display-contents\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"raiseTelemetry()
|
|
9520
|
-
styles: [".card-channels-container{position:relative;width:282px;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;min-height:156px;height:156px;max-height:156px;margin:0 8px;background:#7faeff!important;border-radius:12px;padding:4px!important}.card-channels-container .min-top{background:inherit;margin-bottom:0;height:inherit}.card-channels-container .image-container{background-color:#fff;width:inherit;height:86px;max-height:86px;overflow:hidden;display:flex;align-items:center;justify-content:center;border-radius:12px}.card-channels-container .card-img{max-height:62px;min-height:62px;display:block;-o-object-fit:fill;object-fit:contain}.card-channels-container .mat-subheading-1{font:600 14px/24px Montserrat}.card-channels-container .title-container{background:inherit}.card-channels-container .description-text{position:relative;overflow:hidden;height:51px}.card-channels-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}"]
|
|
9783
|
+
template: "<mat-card class=\"channels-card card-channels-container mr-5 padding-remove cursor-pointer\">\n <div class=\"display-contents\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"raiseTelemetry(widgetData.content); redirectTo(widgetData.content); $event.stopPropagation()\"\n i18n-aria-label>\n <ng-container>\n <mat-card-content class=\"min-top\">\n <div class=\"flex flex-col h-full\">\n <div class=\"image-container\">\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.imgUrl; else defaultImg\">\n <img mat-card-image [src]=\"widgetData.content.imgUrl | 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>\n <div class=\"flex title-container px-2\">\n <div [id]=\"'m-c-'+ widgetData.content?.identifier\"\n class=\"flex-1 text-center mat-subheading-2 title-text ws-mat-black-text\">\n {{ widgetData?.content?.orgName }}\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </a>\n </ng-container>\n </div>\n</mat-card>",
|
|
9784
|
+
styles: [".card-channels-container{position:relative;width:282px;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;min-height:156px;height:156px;max-height:156px;margin:0 8px;background:#7faeff!important;border-radius:12px;padding:4px!important}.card-channels-container .min-top{background:inherit;margin-bottom:0;height:inherit}.card-channels-container .image-container{background-color:#fff;width:inherit;height:86px;max-height:86px;overflow:hidden;display:flex;align-items:center;justify-content:center;border-radius:12px}.card-channels-container .card-img{max-height:62px;min-height:62px;display:block;-o-object-fit:fill;object-fit:contain}.card-channels-container .mat-subheading-1{font:600 14px/24px Montserrat}.card-channels-container .title-container{background:inherit}.card-channels-container .description-text{position:relative;overflow:hidden;height:51px}.card-channels-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}@media screen and (max-width:768px){.card-channels-container{width:100%;margin:0}}"]
|
|
9521
9785
|
}] }
|
|
9522
9786
|
];
|
|
9523
9787
|
/** @nocollapse */
|
|
@@ -9525,11 +9789,14 @@ var CardMDOChannelComponent = /** @class */ (function () {
|
|
|
9525
9789
|
{ type: EventService },
|
|
9526
9790
|
{ type: TranslateService },
|
|
9527
9791
|
{ type: MultilingualTranslationsService$1 },
|
|
9528
|
-
{ type: ConfigurationsService$1 }
|
|
9792
|
+
{ type: ConfigurationsService$1 },
|
|
9793
|
+
{ type: WidgetContentService },
|
|
9794
|
+
{ type: Router }
|
|
9529
9795
|
]; };
|
|
9530
9796
|
CardMDOChannelComponent.propDecorators = {
|
|
9531
9797
|
widgetData: [{ type: Input }],
|
|
9532
|
-
|
|
9798
|
+
channelData: [{ type: Output }],
|
|
9799
|
+
emitTelemetry: [{ type: Output }]
|
|
9533
9800
|
};
|
|
9534
9801
|
return CardMDOChannelComponent;
|
|
9535
9802
|
}());
|
|
@@ -9537,7 +9804,9 @@ if (false) {
|
|
|
9537
9804
|
/** @type {?} */
|
|
9538
9805
|
CardMDOChannelComponent.prototype.widgetData;
|
|
9539
9806
|
/** @type {?} */
|
|
9540
|
-
CardMDOChannelComponent.prototype.
|
|
9807
|
+
CardMDOChannelComponent.prototype.channelData;
|
|
9808
|
+
/** @type {?} */
|
|
9809
|
+
CardMDOChannelComponent.prototype.emitTelemetry;
|
|
9541
9810
|
/** @type {?} */
|
|
9542
9811
|
CardMDOChannelComponent.prototype.defaultThumbnail;
|
|
9543
9812
|
/** @type {?} */
|
|
@@ -9568,6 +9837,13 @@ if (false) {
|
|
|
9568
9837
|
* @private
|
|
9569
9838
|
*/
|
|
9570
9839
|
CardMDOChannelComponent.prototype.configSvc;
|
|
9840
|
+
/**
|
|
9841
|
+
* @type {?}
|
|
9842
|
+
* @private
|
|
9843
|
+
*/
|
|
9844
|
+
CardMDOChannelComponent.prototype.contSvc;
|
|
9845
|
+
/** @type {?} */
|
|
9846
|
+
CardMDOChannelComponent.prototype.router;
|
|
9571
9847
|
}
|
|
9572
9848
|
|
|
9573
9849
|
/**
|
|
@@ -9584,6 +9860,7 @@ var CardWideV2Component = /** @class */ (function () {
|
|
|
9584
9860
|
this.configSvc = configSvc;
|
|
9585
9861
|
this.isCardLoading = false;
|
|
9586
9862
|
this.contentData = new EventEmitter();
|
|
9863
|
+
this.triggerTelemetry = new EventEmitter();
|
|
9587
9864
|
this.isCardFlipped = false;
|
|
9588
9865
|
this.acbpConstants = NsCardContent$1.ACBPConst;
|
|
9589
9866
|
this.showFlip = false;
|
|
@@ -9646,35 +9923,21 @@ var CardWideV2Component = /** @class */ (function () {
|
|
|
9646
9923
|
this.contentData.emit(contentData);
|
|
9647
9924
|
};
|
|
9648
9925
|
/**
|
|
9926
|
+
* @param {?} contentData
|
|
9649
9927
|
* @return {?}
|
|
9650
9928
|
*/
|
|
9651
9929
|
CardWideV2Component.prototype.raiseTelemetry = /**
|
|
9930
|
+
* @param {?} contentData
|
|
9652
9931
|
* @return {?}
|
|
9653
9932
|
*/
|
|
9654
|
-
function () {
|
|
9655
|
-
|
|
9656
|
-
// return
|
|
9657
|
-
// }
|
|
9658
|
-
this.events.raiseInteractTelemetry({
|
|
9659
|
-
type: 'click',
|
|
9660
|
-
subType: this.widgetType + "-" + this.widgetSubType,
|
|
9661
|
-
id: camelCase(this.widgetData.content.primaryCategory) + "-card",
|
|
9662
|
-
}, {
|
|
9663
|
-
id: this.widgetData.content.identifier,
|
|
9664
|
-
type: this.widgetData.content.primaryCategory,
|
|
9665
|
-
//context: this.widgetData.context,
|
|
9666
|
-
rollup: {},
|
|
9667
|
-
ver: "" + this.widgetData.content.version + '',
|
|
9668
|
-
}, {
|
|
9669
|
-
pageIdExt: camelCase(this.widgetData.content.primaryCategory) + "-card",
|
|
9670
|
-
module: camelCase(this.widgetData.content.primaryCategory),
|
|
9671
|
-
});
|
|
9933
|
+
function (contentData) {
|
|
9934
|
+
this.triggerTelemetry.emit(contentData);
|
|
9672
9935
|
};
|
|
9673
9936
|
CardWideV2Component.decorators = [
|
|
9674
9937
|
{ type: Component, args: [{
|
|
9675
9938
|
selector: 'sb-uic-card-wide-v2',
|
|
9676
|
-
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-wide-v2 padding-remove position-relative flex\">\n <div class=\"imageholder \">\n <img mat-card-image class=\"margin-remove\"\n [src]=\"widgetData?.content?.posterImage || widgetData?.content?.appIcon | pipePublicURL\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\">\n <div class=\"source-div\" [hidden]=\"true\">\n <img [src]=\"widgetData?.content?.creatorLogo\" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n </div>\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\"> {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}</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 <mat-card-content class=\"mat-text-box\">\n <div class=\"course_widget flex flex-between margin-remove\">\n <div class=\"flex flex-end course_v2\">\n <ng-container *ngIf=\"widgetData?.content?.contentType === 'Resource' || widgetData?.content?.contentType === 'Course' || widgetData?.content?.contentType === 'Module'\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <span class=\"ws-mat-black60-text font-normal mat-caption \">\n {{widgetData?.content?.primaryCategory || widgetData?.content?.contentType}}\n <!-- {{ translateLabel(widgetData.content.primaryCategory || widgetData.content.contentType, 'searchfilters') }} -->\n </span>\n </ng-container>\n </div>\n </div>\n\n <div class=\"flex main_title_box\">\n <p class=\"mat-subheading-1 title-text font-bold-imp cursor-pointer content-title\">\n <a (click)=\"raiseTelemetry();getRedirectUrlData(widgetData?.content); $event.stopPropagation()\">\n {{widgetData?.content?.name}}\n </a>\n </p>\n </div>\n\n <div class=\"bottomsection\">\n <div class=\"flex w-full flex-wrap flex-middle provider\">\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\">By \n <!-- {{'cardcontentv2.by' | translate}} -->\n {{widgetData?.content?.organisation[0] }}</span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-xs\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon>star</mat-icon>\n <span class=\"rating-number\">{{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\">{{ '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 </mat-card-content>\n </mat-card>\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</ng-container>\n
|
|
9677
|
-
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}.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}.card-wide-v2{border-radius:12px;max-width:100%;min-width:784px;display:flex}.card-wide-v2 .title-text{word-break:break-all;white-space:initial;margin:8px 0 4px;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-height:40px}.card-wide-v2 .course_logo_box{width:30px;height:30px;background:#fff;border-radius:4px;box-sizing:border-box;border:1px solid rgba(0,0,0,.16)}.card-wide-v2 .course_logo_box img{height:28px;width:28px;display:inline-block;-o-object-fit:cover;object-fit:cover}.card-wide-v2 .course_logo_box p{display:inline-block;vertical-align:top}.card-wide-v2 .org-text{font-size:14px;font-weight:400;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-wide-v2 .rating-session mat-icon{font-size:20px;height:20px;width:20px;color:#ef951e}.card-wide-v2 .rating-session .rating-number{font-size:14px}.card-wide-v2 .rating-session .most-enrolled-text{font-size:12px;padding:0 10px;background:#ffea9e;border-radius:4px}.card-wide-v2 .highlight_point_text{margin-top:15px}.card-wide-v2 ul.highlighting_list li{display:inline-block;padding-right:10px}.card-wide-v2 ul.highlighting_list li .rating-number{letter-spacing:0;color:#f69953}.card-wide-v2 ul.highlighting_list li.rating .mat-icon{width:16px;height:16px;display:inline-table;color:#f69953;font-size:18px;vertical-align:text-bottom}.card-wide-v2 img.text_seperator{vertical-align:middle}.card-wide-v2 .mat-text-box{padding:12px;box-sizing:border-box;width:calc(100% - 315px)}@media (max-width:992px){.card-wide-v2 .mat-text-box{width:66%;padding:8px;position:relative;height:auto}}.card-wide-v2 .mat-text-box p.mat-caption .mat-icon{vertical-align:middle;height:18px!important;width:16px!important;font-size:16px!important;line-height:1.2}.card-wide-v2 .mat-text-box p.mat-caption .title_icon{vertical-align:middle}.card-wide-v2 .imageholder{width:310px;overflow:hidden;position:relative;display:flex;align-items:center;justify-content:center}.card-wide-v2 .imageholder img{width:100%;display:block;border-radius:10px 0 0 10px;height:100%;max-height:172px;-o-object-fit:cover;object-fit:cover;vertical-align:middle}@media (max-width:992px){.card-wide-v2 .imageholder{width:34%;height:auto}.card-wide-v2 .imageholder img{height:auto}}.card-wide-v2 .imageholder .source-div{position:absolute;top:12px;right:12px;background:#fff;z-index:3;border:1px solid #dedfe0;min-width:98px;min-height:32px;max-width:98px;max-height:32px;display:flex;border-radius:16px;display:inline-flex}.card-wide-v2 .imageholder .source-div .source-icon{border-radius:8px;display:block;margin:auto;max-width:58px;max-height:-webkit-fill-available}.card-wide-v2 .main_title_box{height:60px}.card-wide-v2 p.actionbtns{margin-bottom:0}.card-wide-v2 .contenticon{vertical-align:middle;margin-right:6px;width:16px;max-height:16px}@media only screen and (min-width:600px) and (max-width:959px){.card-wide-v2{min-width:auto;display:flex;flex-direction:column;min-width:calc(100vw - 32px)}.card-wide-v2 .imageholder,.card-wide-v2 .mat-text-box{width:100%}.card-wide-v2 .provider{flex-wrap:nowrap}}@media only screen and (max-width:599px){.card-wide-v2{min-width:auto;display:flex;flex-direction:column;min-width:calc(100vw - 32px)}.card-wide-v2 .imageholder,.card-wide-v2 .mat-text-box{width:100%}.card-wide-v2 .provider{flex-wrap:nowrap}}.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}"]
|
|
9939
|
+
template: "<ng-container *ngIf=\"!isCardLoading\">\n <mat-card class=\"card-wide-v2 padding-remove position-relative flex {{widgetData?.cardCustomeClass}}\">\n <div class=\"imageholder \">\n <img mat-card-image class=\"margin-remove\"\n [src]=\"widgetData?.content?.posterImage || widgetData?.content?.appIcon | pipePublicURL\" [wsUtilsDefaultThumbnail]=\"defaultThumbnail\"\n [alt]=\"widgetData?.content?.name\">\n <div class=\"source-div\" [hidden]=\"true\">\n <img [src]=\"widgetData?.content?.creatorLogo\" class=\"source-icon\" [wsUtilsDefaultThumbnail]=\"defaultSLogo\"\n [alt]=\"(widgetData?.content?.sourceName + '_' + widgetData?.content?.identifier)\" />\n </div>\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\"> {{ (widgetData?.content?.duration || 120)| pipeDurationTransform: 'hms' }}</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 <mat-card-content class=\"mat-text-box\">\n <div class=\"course_widget flex flex-between margin-remove\">\n <div class=\"flex flex-end course_v2\">\n <ng-container *ngIf=\"widgetData?.content?.contentType === 'Resource' || widgetData?.content?.contentType === 'Course' || widgetData?.content?.contentType === 'Module'\">\n <mat-icon class=\"mat-icon main_icon ws-mat-default-text margin-right-xs\">video_library</mat-icon>\n <span class=\"ws-mat-black60-text font-normal mat-caption \">\n {{widgetData?.content?.primaryCategory || widgetData?.content?.contentType}}\n <!-- {{ translateLabel(widgetData.content.primaryCategory || widgetData.content.contentType, 'searchfilters') }} -->\n </span>\n </ng-container>\n </div>\n </div>\n\n <div class=\"flex main_title_box\">\n <p class=\"mat-subheading-1 title-text font-bold-imp cursor-pointer content-title\">\n <a (click)=\"raiseTelemetry(widgetData?.content);getRedirectUrlData(widgetData?.content); $event.stopPropagation()\">\n {{widgetData?.content?.name}}\n </a>\n </p>\n </div>\n\n <div class=\"bottomsection\">\n <div class=\"flex w-full flex-wrap flex-middle provider\">\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\">By \n <!-- {{'cardcontentv2.by' | translate}} -->\n {{widgetData?.content?.organisation[0] }}</span>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-xs\">\n <div class=\"flex flex-middle\" *ngIf=\"widgetData?.content?.avgRating\">\n <mat-icon>star</mat-icon>\n <span class=\"rating-number\">{{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\">{{ '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 </mat-card-content>\n </mat-card>\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</ng-container>\n <ng-container *ngIf=\"isCardLoading\">\n <mat-card class=\"card-wide-v2 padding-remove position-relative flex\">\n <div class=\"\">\n <sb-uic-skeleton-loader [width]=\"'300px'\" [height]=\"'100%'\" class=\"h-full\" [bindingClass]=\"'flex rounded h-full min-height-width'\"></sb-uic-skeleton-loader>\n </div>\n <mat-card-content class=\"mat-text-box\">\n <div class=\"course_widget flex margin-remove\">\n <div class=\"flex flex-end \">\n <sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'21px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n \n <div class=\"flex main_title_box\">\n <!-- <p class=\"mat-subheading-1 title-text font-bold-imp cursor-pointer content-title\"> -->\n <sb-uic-skeleton-loader [width]=\"'100%'\" [height]=\"'21px'\" class=\"w-full h-full mt-2\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n <!-- </p> -->\n </div>\n \n <div class=\"bottomsection\">\n <div class=\"flex w-full flex-wrap flex-middle\">\n <div class=\"course_logo_box mr-2\">\n <sb-uic-skeleton-loader [width]=\"'28px'\" [height]=\"'28px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <sb-uic-skeleton-loader [width]=\"'100px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <div class=\"flex flex-middle rating-session margin-top-xs\">\n <div class=\"flex flex-middle mr-2\">\n <sb-uic-skeleton-loader [width]=\"'50px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n <sb-uic-skeleton-loader [width]=\"'80px'\" [height]=\"'16px'\" [bindingClass]=\"'flex rounded'\"></sb-uic-skeleton-loader>\n </div>\n </div>\n </mat-card-content>\n </mat-card>\n </ng-container>",
|
|
9940
|
+
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}.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}.card-wide-v2{border-radius:12px;max-width:100%;min-width:784px;display:flex;background-color:#fff}.card-wide-v2 .title-text{word-break:break-all;white-space:initial;margin:8px 0 4px;position:relative;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;min-height:40px}.card-wide-v2 .course_logo_box{width:30px;height:30px;background:#fff;border-radius:4px;box-sizing:border-box;border:1px solid rgba(0,0,0,.16)}.card-wide-v2 .course_logo_box img{height:28px;width:28px;display:inline-block;-o-object-fit:cover;object-fit:cover}.card-wide-v2 .course_logo_box p{display:inline-block;vertical-align:top}.card-wide-v2 .org-text{font-size:14px;font-weight:400;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-wide-v2 .rating-session mat-icon{font-size:20px;height:20px;width:20px;color:#ef951e}.card-wide-v2 .rating-session .rating-number{font-size:14px}.card-wide-v2 .rating-session .most-enrolled-text{font-size:12px;padding:0 10px;background:#ffea9e;border-radius:4px}.card-wide-v2 .highlight_point_text{margin-top:15px}.card-wide-v2 ul.highlighting_list li{display:inline-block;padding-right:10px}.card-wide-v2 ul.highlighting_list li .rating-number{letter-spacing:0;color:#f69953}.card-wide-v2 ul.highlighting_list li.rating .mat-icon{width:16px;height:16px;display:inline-table;color:#f69953;font-size:18px;vertical-align:text-bottom}.card-wide-v2 img.text_seperator{vertical-align:middle}.card-wide-v2 .mat-text-box{padding:12px;box-sizing:border-box;width:calc(100% - 315px)}@media (max-width:992px){.card-wide-v2 .mat-text-box{width:66%;padding:8px;position:relative;height:auto}}.card-wide-v2 .mat-text-box p.mat-caption .mat-icon{vertical-align:middle;height:18px!important;width:16px!important;font-size:16px!important;line-height:1.2}.card-wide-v2 .mat-text-box p.mat-caption .title_icon{vertical-align:middle}.card-wide-v2 .imageholder{width:310px;overflow:hidden;position:relative;display:flex;align-items:center;justify-content:center}.card-wide-v2 .imageholder img{width:100%;display:block;border-radius:10px 0 0 10px;height:100%;max-height:172px;-o-object-fit:cover;object-fit:cover;vertical-align:middle}@media (max-width:992px){.card-wide-v2 .imageholder{width:34%;height:auto}.card-wide-v2 .imageholder img{height:auto}}.card-wide-v2 .imageholder .source-div{position:absolute;top:12px;right:12px;background:#fff;z-index:3;border:1px solid #dedfe0;min-width:98px;min-height:32px;max-width:98px;max-height:32px;display:flex;border-radius:16px;display:inline-flex}.card-wide-v2 .imageholder .source-div .source-icon{border-radius:8px;display:block;margin:auto;max-width:58px;max-height:-webkit-fill-available}.card-wide-v2 .main_title_box{height:60px}.card-wide-v2 p.actionbtns{margin-bottom:0}.card-wide-v2 .contenticon{vertical-align:middle;margin-right:6px;width:16px;max-height:16px}@media only screen and (min-width:600px) and (max-width:959px){.card-wide-v2{min-width:auto;display:flex;flex-direction:column;min-width:calc(100vw - 32px)}.card-wide-v2 .imageholder,.card-wide-v2 .mat-text-box{width:100%}.card-wide-v2 .provider{flex-wrap:nowrap}}@media only screen and (max-width:599px){.card-wide-v2{min-width:auto;display:flex;flex-direction:column;min-width:calc(100vw - 32px)}.card-wide-v2 .imageholder,.card-wide-v2 .mat-text-box{width:100%}.card-wide-v2 .provider{flex-wrap:nowrap}}.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}.min-width-763{min-width:763px;background-color:#fff}"]
|
|
9678
9941
|
}] }
|
|
9679
9942
|
];
|
|
9680
9943
|
/** @nocollapse */
|
|
@@ -9692,7 +9955,8 @@ var CardWideV2Component = /** @class */ (function () {
|
|
|
9692
9955
|
isIntranetAllowedSettings: [{ type: Input }],
|
|
9693
9956
|
cbPlanMapData: [{ type: Input }],
|
|
9694
9957
|
isCardLoading: [{ type: Input }],
|
|
9695
|
-
contentData: [{ type: Output }]
|
|
9958
|
+
contentData: [{ type: Output }],
|
|
9959
|
+
triggerTelemetry: [{ type: Output }]
|
|
9696
9960
|
};
|
|
9697
9961
|
return CardWideV2Component;
|
|
9698
9962
|
}());
|
|
@@ -9712,6 +9976,8 @@ if (false) {
|
|
|
9712
9976
|
/** @type {?} */
|
|
9713
9977
|
CardWideV2Component.prototype.contentData;
|
|
9714
9978
|
/** @type {?} */
|
|
9979
|
+
CardWideV2Component.prototype.triggerTelemetry;
|
|
9980
|
+
/** @type {?} */
|
|
9715
9981
|
CardWideV2Component.prototype.isCardFlipped;
|
|
9716
9982
|
/** @type {?} */
|
|
9717
9983
|
CardWideV2Component.prototype.acbpConstants;
|
|
@@ -9827,7 +10093,6 @@ var CardKarmaProgramsComponent = /** @class */ (function () {
|
|
|
9827
10093
|
this.widgetData.content['bgColor'] = '#1a4ca1';
|
|
9828
10094
|
}
|
|
9829
10095
|
}
|
|
9830
|
-
console.log(this.widgetData.content, this.randomColorApply);
|
|
9831
10096
|
};
|
|
9832
10097
|
/**
|
|
9833
10098
|
* @return {?}
|
|
@@ -9868,7 +10133,7 @@ var CardKarmaProgramsComponent = /** @class */ (function () {
|
|
|
9868
10133
|
CardKarmaProgramsComponent.decorators = [
|
|
9869
10134
|
{ type: Component, args: [{
|
|
9870
10135
|
selector: 'sb-uic-card-karma-programs',
|
|
9871
|
-
template: "<mat-card class=\"channels-card card-channels-container mr-5 padding-remove cursor-pointer\" [ngStyle]=\"{'background': widgetData?.content?.bgColor}\">\n <div class=\"display-contents\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"raiseTelemetry();$event.stopPropagation()\" \n
|
|
10136
|
+
template: "<mat-card class=\"channels-card card-channels-container mr-5 padding-remove cursor-pointer\" [ngStyle]=\"{'background': widgetData?.content?.bgColor}\">\n <div class=\"display-contents\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"raiseTelemetry();$event.stopPropagation()\" \n [routerLink]=\"'/app/learn/karma-programs/'+ widgetData?.content?.title+ '/' + widgetData?.content?.playListKey+ '/' +widgetData?.content?.orgId+'/micro-sites'\" role=\"link\"\n i18n-aria-label>\n <ng-container>\n <mat-card-content class=\"min-top\">\n <div class=\"flex flex-col h-full\">\n <div class=\"image-container\">\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?.title\" />\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?.title\" />\n </ng-template>\n </ng-container>\n </div>\n <div class=\"title-container\">\n <div class=\"flex px-2\">\n <div [id]=\"'m-c-'+ widgetData.content?.identifier\"\n class=\"flex-1 text-start mat-subheading-2 title-text ws-mat-white-text\">\n {{ widgetData?.content?.title }}\n </div>\n </div>\n <div class=\"flex px-2\">\n <div [id]=\"'m-c-'+ widgetData?.content?.identifier\"\n class=\"flex-1 text-start margin-remove margin-top-xxs mat-subheading-2 title-text ws-mat-white-text\">\n {{ widgetData?.content?.children?.length}} Programs\n </div>\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </a>\n </ng-container>\n </div>\n</mat-card>",
|
|
9872
10137
|
styles: [".card-channels-container{position:relative;width:245px;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;min-height:217px;height:217px;max-height:217px;margin:0 8px;background:#1a4ca1;border-radius:12px}.card-channels-container .min-top{background:inherit;margin-bottom:0;height:inherit}.card-channels-container .image-container{background-color:#fff;width:inherit;height:139px;max-height:139px;overflow:hidden;display:flex;align-items:center;justify-content:center;border-top-left-radius:12px;border-top-right-radius:12px}.card-channels-container .card-img{max-height:100%;min-height:100%;display:block;-o-object-fit:fill;object-fit:fill}.card-channels-container .mat-subheading-1{font:600 14px/24px Montserrat}.card-channels-container .title-container{background:inherit}.card-channels-container .description-text{position:relative;overflow:hidden;height:51px}.card-channels-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:1;-webkit-box-orient:vertical;min-height:24px}"]
|
|
9873
10138
|
}] }
|
|
9874
10139
|
];
|
|
@@ -9927,6 +10192,178 @@ if (false) {
|
|
|
9927
10192
|
CardKarmaProgramsComponent.prototype.configSvc;
|
|
9928
10193
|
}
|
|
9929
10194
|
|
|
10195
|
+
/**
|
|
10196
|
+
* @fileoverview added by tsickle
|
|
10197
|
+
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
10198
|
+
*/
|
|
10199
|
+
var CardKarmaProgramsV2Component = /** @class */ (function () {
|
|
10200
|
+
function CardKarmaProgramsV2Component(events, translate, langtranslations, configSvc) {
|
|
10201
|
+
var _this = this;
|
|
10202
|
+
this.events = events;
|
|
10203
|
+
this.translate = translate;
|
|
10204
|
+
this.langtranslations = langtranslations;
|
|
10205
|
+
this.configSvc = configSvc;
|
|
10206
|
+
this.randomColorApply = false;
|
|
10207
|
+
this.userData = new EventEmitter();
|
|
10208
|
+
this.widgetType = '';
|
|
10209
|
+
this.widgetSubType = '';
|
|
10210
|
+
this.randomColors = [
|
|
10211
|
+
'#EF941D',
|
|
10212
|
+
'#F97440',
|
|
10213
|
+
'#35B5B0',
|
|
10214
|
+
'#9988FF',
|
|
10215
|
+
'#254092',
|
|
10216
|
+
'#926525',
|
|
10217
|
+
'#4F72DF'
|
|
10218
|
+
];
|
|
10219
|
+
this.langtranslations.languageSelectedObservable.subscribe((/**
|
|
10220
|
+
* @return {?}
|
|
10221
|
+
*/
|
|
10222
|
+
function () {
|
|
10223
|
+
if (localStorage.getItem('websiteLanguage')) {
|
|
10224
|
+
_this.translate.setDefaultLang('en');
|
|
10225
|
+
/** @type {?} */
|
|
10226
|
+
var lang = (/** @type {?} */ (localStorage.getItem('websiteLanguage')));
|
|
10227
|
+
_this.translate.use(lang);
|
|
10228
|
+
}
|
|
10229
|
+
}));
|
|
10230
|
+
}
|
|
10231
|
+
/**
|
|
10232
|
+
* @return {?}
|
|
10233
|
+
*/
|
|
10234
|
+
CardKarmaProgramsV2Component.prototype.ngOnInit = /**
|
|
10235
|
+
* @return {?}
|
|
10236
|
+
*/
|
|
10237
|
+
function () {
|
|
10238
|
+
/** @type {?} */
|
|
10239
|
+
var instanceConfig = this.configSvc.instanceConfig;
|
|
10240
|
+
if (instanceConfig) {
|
|
10241
|
+
this.defaultThumbnail = instanceConfig.logos.defaultContent || '';
|
|
10242
|
+
this.sourceLogos = instanceConfig.sources;
|
|
10243
|
+
this.defaultSLogo = instanceConfig.logos.defaultSourceLogo || '';
|
|
10244
|
+
}
|
|
10245
|
+
else {
|
|
10246
|
+
this.defaultThumbnail = '/assets/instances/eagle/app_logos/default.png';
|
|
10247
|
+
this.defaultSLogo = '/assets/instances/eagle/app_logos/KarmayogiBharat_Logo.svg';
|
|
10248
|
+
}
|
|
10249
|
+
this.setRandomColor();
|
|
10250
|
+
};
|
|
10251
|
+
/**
|
|
10252
|
+
* @return {?}
|
|
10253
|
+
*/
|
|
10254
|
+
CardKarmaProgramsV2Component.prototype.setRandomColor = /**
|
|
10255
|
+
* @return {?}
|
|
10256
|
+
*/
|
|
10257
|
+
function () {
|
|
10258
|
+
if (this.widgetData && this.widgetData.content) {
|
|
10259
|
+
if (this.randomColorApply) {
|
|
10260
|
+
/** @type {?} */
|
|
10261
|
+
var randomIndex1 = Math.floor(Math.random() * Math.floor(this.randomColors.length));
|
|
10262
|
+
this.widgetData.content['bgColor'] = this.randomColors[randomIndex1];
|
|
10263
|
+
}
|
|
10264
|
+
else {
|
|
10265
|
+
this.widgetData.content['bgColor'] = '#1a4ca1';
|
|
10266
|
+
}
|
|
10267
|
+
}
|
|
10268
|
+
};
|
|
10269
|
+
/**
|
|
10270
|
+
* @return {?}
|
|
10271
|
+
*/
|
|
10272
|
+
CardKarmaProgramsV2Component.prototype.raiseTelemetry = /**
|
|
10273
|
+
* @return {?}
|
|
10274
|
+
*/
|
|
10275
|
+
function () {
|
|
10276
|
+
// if(this.forPreview){
|
|
10277
|
+
// return
|
|
10278
|
+
// }
|
|
10279
|
+
this.events.raiseInteractTelemetry({
|
|
10280
|
+
type: 'click',
|
|
10281
|
+
subType: this.widgetType + "-" + this.widgetSubType,
|
|
10282
|
+
id: camelCase(this.widgetData.content.userId) + "-card",
|
|
10283
|
+
}, {
|
|
10284
|
+
id: this.widgetData.content.userId,
|
|
10285
|
+
// type: this.widgetData.user.primaryCategory,
|
|
10286
|
+
//context: this.widgetData.context,
|
|
10287
|
+
rollup: {},
|
|
10288
|
+
}, {
|
|
10289
|
+
pageIdExt: camelCase('user') + "-card",
|
|
10290
|
+
module: camelCase('user'),
|
|
10291
|
+
});
|
|
10292
|
+
};
|
|
10293
|
+
Object.defineProperty(CardKarmaProgramsV2Component.prototype, "getRandomColors", {
|
|
10294
|
+
get: /**
|
|
10295
|
+
* @return {?}
|
|
10296
|
+
*/
|
|
10297
|
+
function () {
|
|
10298
|
+
/** @type {?} */
|
|
10299
|
+
var randomIndex1 = Math.floor(Math.random() * Math.floor(this.randomColors.length));
|
|
10300
|
+
return this.randomColors[randomIndex1];
|
|
10301
|
+
},
|
|
10302
|
+
enumerable: true,
|
|
10303
|
+
configurable: true
|
|
10304
|
+
});
|
|
10305
|
+
CardKarmaProgramsV2Component.decorators = [
|
|
10306
|
+
{ type: Component, args: [{
|
|
10307
|
+
selector: 'sb-uic-card-karma-programs-v2',
|
|
10308
|
+
template: "<mat-card class=\"channels-card card-channels-container mr-5 padding-remove cursor-pointer\" [ngStyle]=\"{'background': widgetData?.content?.bgColor}\">\n <div class=\"display-contents\">\n <ng-container *ngIf=\"widgetData.content\">\n <a (click)=\"raiseTelemetry();$event.stopPropagation()\" \n [routerLink]=\"['/app/learn/karma-programs/asdfghj/123456/micro-sites']\" role=\"link\"\n i18n-aria-label>\n <ng-container>\n <mat-card-content class=\"min-top\">\n <div class=\"flex flex-row md:flex-col h-full\">\n <div class=\"image-container\">\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>\n <div class=\"flex items-center\">\n <div class=\"title-container\">\n <div class=\"flex px-2\">\n <div [id]=\"'m-c-'+ widgetData.content?.identifier\"\n class=\"flex-1 text-start mat-subheading-2 title-text ws-mat-white-text\">\n {{ widgetData?.content?.name }}\n </div>\n </div>\n <div class=\"flex px-2\">\n <div [id]=\"'m-c-'+ widgetData?.content?.identifier\"\n class=\"flex-1 text-start margin-remove margin-top-xxs mat-subheading-2 title-text ws-mat-white-text\">\n {{ widgetData?.content?.programCount}} Programs\n </div>\n </div>\n </div>\n </div>\n </div>\n </mat-card-content>\n </ng-container>\n </a>\n </ng-container>\n </div>\n</mat-card>",
|
|
10309
|
+
styles: [".card-channels-container{position:relative;width:282px;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;min-height:233px;height:233px;max-height:233px;margin:0 8px;background:#1a4ca1;border-radius:12px}.card-channels-container .min-top{background:inherit;margin-bottom:0;height:inherit}.card-channels-container .image-container{background-color:#fff;width:inherit;height:156px;max-height:156px;overflow:hidden;display:flex;align-items:center;justify-content:center;border-top-left-radius:12px;border-top-right-radius:12px}.card-channels-container .card-img{max-height:100%;min-height:100%;display:block;-o-object-fit:fill;object-fit:fill}.card-channels-container .mat-subheading-1{font:600 14px/24px Montserrat}.card-channels-container .title-container{background:inherit}.card-channels-container .description-text{position:relative;overflow:hidden;height:51px}.card-channels-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:1;-webkit-box-orient:vertical;min-height:24px}@media screen and (max-width:768px){.card-channels-container{width:100%;box-sizing:border-box;box-shadow:0 10px 30px rgba(153,153,153,.2);overflow:hidden;min-height:unset;height:unset;max-height:unset;margin:0;padding:8px!important}.image-container{background-color:#fff;width:190px;height:106px;max-height:106px;border-radius:12px}}"]
|
|
10310
|
+
}] }
|
|
10311
|
+
];
|
|
10312
|
+
/** @nocollapse */
|
|
10313
|
+
CardKarmaProgramsV2Component.ctorParameters = function () { return [
|
|
10314
|
+
{ type: EventService },
|
|
10315
|
+
{ type: TranslateService },
|
|
10316
|
+
{ type: MultilingualTranslationsService$1 },
|
|
10317
|
+
{ type: ConfigurationsService$1 }
|
|
10318
|
+
]; };
|
|
10319
|
+
CardKarmaProgramsV2Component.propDecorators = {
|
|
10320
|
+
widgetData: [{ type: Input }],
|
|
10321
|
+
randomColorApply: [{ type: Input }],
|
|
10322
|
+
userData: [{ type: Output }]
|
|
10323
|
+
};
|
|
10324
|
+
return CardKarmaProgramsV2Component;
|
|
10325
|
+
}());
|
|
10326
|
+
if (false) {
|
|
10327
|
+
/** @type {?} */
|
|
10328
|
+
CardKarmaProgramsV2Component.prototype.widgetData;
|
|
10329
|
+
/** @type {?} */
|
|
10330
|
+
CardKarmaProgramsV2Component.prototype.randomColorApply;
|
|
10331
|
+
/** @type {?} */
|
|
10332
|
+
CardKarmaProgramsV2Component.prototype.userData;
|
|
10333
|
+
/** @type {?} */
|
|
10334
|
+
CardKarmaProgramsV2Component.prototype.defaultThumbnail;
|
|
10335
|
+
/** @type {?} */
|
|
10336
|
+
CardKarmaProgramsV2Component.prototype.sourceLogos;
|
|
10337
|
+
/** @type {?} */
|
|
10338
|
+
CardKarmaProgramsV2Component.prototype.defaultSLogo;
|
|
10339
|
+
/** @type {?} */
|
|
10340
|
+
CardKarmaProgramsV2Component.prototype.widgetType;
|
|
10341
|
+
/** @type {?} */
|
|
10342
|
+
CardKarmaProgramsV2Component.prototype.widgetSubType;
|
|
10343
|
+
/** @type {?} */
|
|
10344
|
+
CardKarmaProgramsV2Component.prototype.randomColors;
|
|
10345
|
+
/**
|
|
10346
|
+
* @type {?}
|
|
10347
|
+
* @private
|
|
10348
|
+
*/
|
|
10349
|
+
CardKarmaProgramsV2Component.prototype.events;
|
|
10350
|
+
/**
|
|
10351
|
+
* @type {?}
|
|
10352
|
+
* @private
|
|
10353
|
+
*/
|
|
10354
|
+
CardKarmaProgramsV2Component.prototype.translate;
|
|
10355
|
+
/**
|
|
10356
|
+
* @type {?}
|
|
10357
|
+
* @private
|
|
10358
|
+
*/
|
|
10359
|
+
CardKarmaProgramsV2Component.prototype.langtranslations;
|
|
10360
|
+
/**
|
|
10361
|
+
* @type {?}
|
|
10362
|
+
* @private
|
|
10363
|
+
*/
|
|
10364
|
+
CardKarmaProgramsV2Component.prototype.configSvc;
|
|
10365
|
+
}
|
|
10366
|
+
|
|
9930
10367
|
/**
|
|
9931
10368
|
* @fileoverview added by tsickle
|
|
9932
10369
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
@@ -9944,7 +10381,8 @@ var CardsModule = /** @class */ (function () {
|
|
|
9944
10381
|
CardWideComponent,
|
|
9945
10382
|
CardMDOChannelComponent,
|
|
9946
10383
|
CardWideV2Component,
|
|
9947
|
-
CardKarmaProgramsComponent
|
|
10384
|
+
CardKarmaProgramsComponent,
|
|
10385
|
+
CardKarmaProgramsV2Component
|
|
9948
10386
|
],
|
|
9949
10387
|
imports: [
|
|
9950
10388
|
CommonModule,
|
|
@@ -9969,7 +10407,8 @@ var CardsModule = /** @class */ (function () {
|
|
|
9969
10407
|
CardWideComponent,
|
|
9970
10408
|
CardMDOChannelComponent,
|
|
9971
10409
|
CardWideV2Component,
|
|
9972
|
-
CardKarmaProgramsComponent
|
|
10410
|
+
CardKarmaProgramsComponent,
|
|
10411
|
+
CardKarmaProgramsV2Component
|
|
9973
10412
|
],
|
|
9974
10413
|
},] }
|
|
9975
10414
|
];
|
|
@@ -11601,5 +12040,5 @@ var UserContentRatingLibModule = /** @class */ (function () {
|
|
|
11601
12040
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
11602
12041
|
*/
|
|
11603
12042
|
|
|
11604
|
-
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,
|
|
12043
|
+
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, PipePublicURLModule as ɵbd, PipePublicURL as ɵbe, DisplayContentTypeLibModule as ɵbf, DisplayContentTypeLibComponent as ɵbg, DefaultThumbnailModule as ɵbh, DefaultThumbnailDirective as ɵbi, PipeDurationTransformModule as ɵbj, PipeDurationTransformPipe as ɵbk, CompetencyPassbookComponent as ɵbl, CompetencyPassbookService as ɵbm, PillsModule as ɵbn, PillsComponent as ɵbo, UserContentRatingLibComponent as ɵbp, ScrollableItemDirective as ɵbq, RatingService as ɵbr, UserContentRatingLibService as ɵbs, AvatarPhotoLibModule as ɵbt, AvatarPhotoLibComponent as ɵbu, MyHammerConfig$1 as ɵbv, SlidersNgContentLibModule as ɵbw, SlidersNgContentLibComponent as ɵbx, ScrollableItemModule as ɵby, 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 };
|
|
11605
12044
|
//# sourceMappingURL=sunbird-cb-consumption.js.map
|