@sunbird-cb/consumption 0.0.25 → 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 +566 -144
- 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 +7 -2
- 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 +5 -4
- package/esm2015/lib/_common/competency-passbook/competency-passbook.component.js +8 -2
- package/esm2015/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.js +172 -68
- 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 +2 -2
- 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 +7 -2
- 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 +5 -4
- package/esm5/lib/_common/competency-passbook/competency-passbook.component.js +8 -2
- package/esm5/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.js +215 -71
- 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 +2 -2
- package/fesm2015/sunbird-cb-consumption.js +497 -139
- package/fesm2015/sunbird-cb-consumption.js.map +1 -1
- package/fesm5/sunbird-cb-consumption.js +566 -144
- 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/competency-passbook/competency-passbook.component.d.ts +1 -0
- package/lib/_common/content-strip-with-tabs-lib/content-strip-with-tabs-lib.component.d.ts +6 -2
- 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 +1 -1
- package/sunbird-cb-consumption.metadata.json +1 -1
- package/esm2015/lib/_common/cards/card-karma-program-v2/card-karma-program-v2.component.js +0 -23
- package/esm5/lib/_common/cards/card-karma-program-v2/card-karma-program-v2.component.js +0 -29
- package/lib/_common/cards/card-karma-program-v2/card-karma-program-v2.component.d.ts +0 -5
|
@@ -452,7 +452,6 @@
|
|
|
452
452
|
* @return {?}
|
|
453
453
|
*/
|
|
454
454
|
function (elem) {
|
|
455
|
-
debugger;
|
|
456
455
|
this.enablePrev = true;
|
|
457
456
|
this.enableNext = true;
|
|
458
457
|
if (elem.scrollLeft === 0) {
|
|
@@ -2700,6 +2699,18 @@
|
|
|
2700
2699
|
req.query = req.query || '';
|
|
2701
2700
|
return this.http.post(apiUrl, req);
|
|
2702
2701
|
};
|
|
2702
|
+
/**
|
|
2703
|
+
* @param {?} apiUrl
|
|
2704
|
+
* @return {?}
|
|
2705
|
+
*/
|
|
2706
|
+
WidgetContentService.prototype.getApiMethod = /**
|
|
2707
|
+
* @param {?} apiUrl
|
|
2708
|
+
* @return {?}
|
|
2709
|
+
*/
|
|
2710
|
+
function (apiUrl) {
|
|
2711
|
+
// req.query = req.query || '';
|
|
2712
|
+
return this.http.get(apiUrl);
|
|
2713
|
+
};
|
|
2703
2714
|
WidgetContentService.decorators = [
|
|
2704
2715
|
{ type: core.Injectable, args: [{
|
|
2705
2716
|
providedIn: 'root',
|
|
@@ -3915,7 +3926,6 @@
|
|
|
3915
3926
|
_this.translate.use(lang);
|
|
3916
3927
|
}
|
|
3917
3928
|
_this.environment = environment;
|
|
3918
|
-
console.log('plugin');
|
|
3919
3929
|
return _this;
|
|
3920
3930
|
}
|
|
3921
3931
|
/**
|
|
@@ -4327,10 +4337,15 @@
|
|
|
4327
4337
|
}
|
|
4328
4338
|
else if (filters.organisation &&
|
|
4329
4339
|
filters.organisation.indexOf('<orgID>') >= 0) {
|
|
4330
|
-
|
|
4331
|
-
|
|
4332
|
-
|
|
4333
|
-
|
|
4340
|
+
if (this.providerId) {
|
|
4341
|
+
filters.organisation = this.providerId;
|
|
4342
|
+
}
|
|
4343
|
+
else {
|
|
4344
|
+
filters.organisation = userData && userData.rootOrgId;
|
|
4345
|
+
if (filters && filters.hasOwnProperty('designation')) {
|
|
4346
|
+
filters.designation = userData.professionalDetails.length > 0 ?
|
|
4347
|
+
userData.professionalDetails[0].designation : '';
|
|
4348
|
+
}
|
|
4334
4349
|
}
|
|
4335
4350
|
}
|
|
4336
4351
|
return filters;
|
|
@@ -4358,7 +4373,9 @@
|
|
|
4358
4373
|
this.fetchAllCbpPlans(strip, calculateParentStatus);
|
|
4359
4374
|
this.fetchAllTopContent(strip, calculateParentStatus);
|
|
4360
4375
|
this.fetchAllFeaturedContent(strip, calculateParentStatus);
|
|
4361
|
-
this.
|
|
4376
|
+
this.fetchAllBookMarkData(strip, calculateParentStatus);
|
|
4377
|
+
this.fetchAllPlaylistSearch(strip, calculateParentStatus);
|
|
4378
|
+
this.fetchPlaylistReadData(strip, calculateParentStatus);
|
|
4362
4379
|
// this.enrollInterval = setInterval(() => {
|
|
4363
4380
|
// this.fetchAllCbpPlans(strip, calculateParentStatus)
|
|
4364
4381
|
// }, 1000)
|
|
@@ -5088,7 +5105,9 @@
|
|
|
5088
5105
|
(strip.request.trendingSearch && Object.keys(strip.request.trendingSearch).length) ||
|
|
5089
5106
|
(strip.request.topContent && Object.keys(strip.request.topContent).length) ||
|
|
5090
5107
|
(strip.request.featureContent && Object.keys(strip.request.featureContent).length) ||
|
|
5091
|
-
(strip.request.
|
|
5108
|
+
(strip.request.bookmarkRead && Object.keys(strip.request.bookmarkRead).length) ||
|
|
5109
|
+
(strip.request.playlistSearch && Object.keys(strip.request.playlistSearch).length) ||
|
|
5110
|
+
(strip.request.playlistRead && Object.keys(strip.request.playlistRead).length))) {
|
|
5092
5111
|
return true;
|
|
5093
5112
|
}
|
|
5094
5113
|
return false;
|
|
@@ -5689,6 +5708,17 @@
|
|
|
5689
5708
|
});
|
|
5690
5709
|
});
|
|
5691
5710
|
};
|
|
5711
|
+
/**
|
|
5712
|
+
* @param {?} stripData
|
|
5713
|
+
* @return {?}
|
|
5714
|
+
*/
|
|
5715
|
+
ContentStripWithTabsLibComponent.prototype.raiseTelemetry = /**
|
|
5716
|
+
* @param {?} stripData
|
|
5717
|
+
* @return {?}
|
|
5718
|
+
*/
|
|
5719
|
+
function (stripData) {
|
|
5720
|
+
this.telemtryResponse.emit(stripData);
|
|
5721
|
+
};
|
|
5692
5722
|
/**
|
|
5693
5723
|
* @param {?} strip
|
|
5694
5724
|
* @param {?} request
|
|
@@ -5753,6 +5783,61 @@
|
|
|
5753
5783
|
});
|
|
5754
5784
|
});
|
|
5755
5785
|
};
|
|
5786
|
+
/**
|
|
5787
|
+
* @param {?} strip
|
|
5788
|
+
* @param {?} request
|
|
5789
|
+
* @param {?} apiUrl
|
|
5790
|
+
* @param {?} calculateParentStatus
|
|
5791
|
+
* @return {?}
|
|
5792
|
+
*/
|
|
5793
|
+
ContentStripWithTabsLibComponent.prototype.getRequestMethod = /**
|
|
5794
|
+
* @param {?} strip
|
|
5795
|
+
* @param {?} request
|
|
5796
|
+
* @param {?} apiUrl
|
|
5797
|
+
* @param {?} calculateParentStatus
|
|
5798
|
+
* @return {?}
|
|
5799
|
+
*/
|
|
5800
|
+
function (strip, request, apiUrl, calculateParentStatus) {
|
|
5801
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
5802
|
+
var originalFilters;
|
|
5803
|
+
var _this = this;
|
|
5804
|
+
return __generator(this, function (_a) {
|
|
5805
|
+
originalFilters = [];
|
|
5806
|
+
return [2 /*return*/, new Promise((/**
|
|
5807
|
+
* @param {?} resolve
|
|
5808
|
+
* @param {?} reject
|
|
5809
|
+
* @return {?}
|
|
5810
|
+
*/
|
|
5811
|
+
function (resolve, reject) {
|
|
5812
|
+
if (request && request) {
|
|
5813
|
+
_this.contentSvc.getApiMethod(apiUrl).subscribe((/**
|
|
5814
|
+
* @param {?} results
|
|
5815
|
+
* @return {?}
|
|
5816
|
+
*/
|
|
5817
|
+
function (results) {
|
|
5818
|
+
console.log(results, 'results=========');
|
|
5819
|
+
/** @type {?} */
|
|
5820
|
+
var showViewMore = Boolean(results.result.data && results.result.data.orgList.length > 5 && strip.stripConfig && strip.stripConfig.postCardForSearch);
|
|
5821
|
+
/** @type {?} */
|
|
5822
|
+
var viewMoreUrl = showViewMore
|
|
5823
|
+
? {
|
|
5824
|
+
path: strip.viewMoreUrl && strip.viewMoreUrl.path || '',
|
|
5825
|
+
}
|
|
5826
|
+
: null;
|
|
5827
|
+
resolve({ results: results, viewMoreUrl: viewMoreUrl });
|
|
5828
|
+
}), (/**
|
|
5829
|
+
* @param {?} error
|
|
5830
|
+
* @return {?}
|
|
5831
|
+
*/
|
|
5832
|
+
function (error) {
|
|
5833
|
+
_this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
5834
|
+
reject(error);
|
|
5835
|
+
}));
|
|
5836
|
+
}
|
|
5837
|
+
}))];
|
|
5838
|
+
});
|
|
5839
|
+
});
|
|
5840
|
+
};
|
|
5756
5841
|
/**
|
|
5757
5842
|
* @param {?} filters
|
|
5758
5843
|
* @return {?}
|
|
@@ -5768,6 +5853,28 @@
|
|
|
5768
5853
|
}
|
|
5769
5854
|
return filters;
|
|
5770
5855
|
};
|
|
5856
|
+
/**
|
|
5857
|
+
* @param {?} apiUrl
|
|
5858
|
+
* @param {?} id
|
|
5859
|
+
* @return {?}
|
|
5860
|
+
*/
|
|
5861
|
+
ContentStripWithTabsLibComponent.prototype.getFullUrl = /**
|
|
5862
|
+
* @param {?} apiUrl
|
|
5863
|
+
* @param {?} id
|
|
5864
|
+
* @return {?}
|
|
5865
|
+
*/
|
|
5866
|
+
function (apiUrl, id) {
|
|
5867
|
+
/** @type {?} */
|
|
5868
|
+
var formedUrl = '';
|
|
5869
|
+
if (apiUrl.indexOf('<bookmarkId>') >= 0) {
|
|
5870
|
+
formedUrl = apiUrl.replace('<bookmarkId>', this.environment.mdoChannelsBookmarkId);
|
|
5871
|
+
}
|
|
5872
|
+
else if (apiUrl.indexOf('<playlistKey>') >= 0 && apiUrl.indexOf('<orgID>') >= 0) {
|
|
5873
|
+
formedUrl = apiUrl.replace('<playlistKey>', this.providerId + id);
|
|
5874
|
+
formedUrl = formedUrl.replace('<orgID>', this.providerId);
|
|
5875
|
+
}
|
|
5876
|
+
return formedUrl;
|
|
5877
|
+
};
|
|
5771
5878
|
/**
|
|
5772
5879
|
* @param {?} stripData
|
|
5773
5880
|
* @param {?} path
|
|
@@ -5793,7 +5900,7 @@
|
|
|
5793
5900
|
* @param {?=} calculateParentStatus
|
|
5794
5901
|
* @return {?}
|
|
5795
5902
|
*/
|
|
5796
|
-
ContentStripWithTabsLibComponent.prototype.
|
|
5903
|
+
ContentStripWithTabsLibComponent.prototype.fetchAllBookMarkData = /**
|
|
5797
5904
|
* @param {?} strip
|
|
5798
5905
|
* @param {?=} calculateParentStatus
|
|
5799
5906
|
* @return {?}
|
|
@@ -5801,74 +5908,27 @@
|
|
|
5801
5908
|
function (strip, calculateParentStatus) {
|
|
5802
5909
|
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5803
5910
|
return __awaiter(this, void 0, void 0, function () {
|
|
5804
|
-
var originalFilters,
|
|
5911
|
+
var originalFilters, response, content, error_7;
|
|
5805
5912
|
return __generator(this, function (_a) {
|
|
5806
5913
|
switch (_a.label) {
|
|
5807
5914
|
case 0:
|
|
5808
|
-
if (!(strip.request && strip.request.
|
|
5915
|
+
if (!(strip.request && strip.request.bookmarkRead && Object.keys(strip.request.bookmarkRead).length)) return [3 /*break*/, 4];
|
|
5809
5916
|
originalFilters = [];
|
|
5810
5917
|
if (strip.request &&
|
|
5811
|
-
strip.request.
|
|
5812
|
-
strip.request.
|
|
5813
|
-
strip.request.
|
|
5814
|
-
originalFilters = strip.request.channels.request.filters;
|
|
5815
|
-
strip.request.channels.request.filters = this.postMethodFilters(strip.request.channels.request.filters);
|
|
5918
|
+
strip.request.bookmarkRead &&
|
|
5919
|
+
strip.request.bookmarkRead.bookmarkId) {
|
|
5920
|
+
strip.request.apiUrl = this.getFullUrl(strip.request.apiUrl, strip.request.bookmarkRead.bookmarkId);
|
|
5816
5921
|
}
|
|
5817
5922
|
_a.label = 1;
|
|
5818
5923
|
case 1:
|
|
5819
5924
|
_a.trys.push([1, 3, , 4]);
|
|
5820
|
-
|
|
5821
|
-
{
|
|
5822
|
-
// tslint:disable-next-line: max-line-length
|
|
5823
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5824
|
-
appIcon: '',
|
|
5825
|
-
name: 'Ministry of Consumer Affairs, Food and Public Distribution',
|
|
5826
|
-
programCount: '10',
|
|
5827
|
-
},
|
|
5828
|
-
{
|
|
5829
|
-
// tslint:disable-next-line: max-line-length
|
|
5830
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5831
|
-
appIcon: '',
|
|
5832
|
-
name: 'Ministry of Railways',
|
|
5833
|
-
programCount: '10',
|
|
5834
|
-
},
|
|
5835
|
-
{
|
|
5836
|
-
// tslint:disable-next-line: max-line-length
|
|
5837
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5838
|
-
appIcon: '',
|
|
5839
|
-
name: 'Department of Post',
|
|
5840
|
-
programCount: '10',
|
|
5841
|
-
},
|
|
5842
|
-
{
|
|
5843
|
-
// tslint:disable-next-line: max-line-length
|
|
5844
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5845
|
-
appIcon: '',
|
|
5846
|
-
name: 'NLC India Limited',
|
|
5847
|
-
programCount: '30',
|
|
5848
|
-
},
|
|
5849
|
-
{
|
|
5850
|
-
// tslint:disable-next-line: max-line-length
|
|
5851
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5852
|
-
appIcon: '',
|
|
5853
|
-
name: 'Mission Karmayogi',
|
|
5854
|
-
programCount: '24',
|
|
5855
|
-
},
|
|
5856
|
-
{
|
|
5857
|
-
// tslint:disable-next-line: max-line-length
|
|
5858
|
-
posterImage: 'https://portal.karmayogi.nic.in/content-store/content/do_114051411119235072127/artifact/do_114051411119235072127_1715260168985_default-provider.svg',
|
|
5859
|
-
appIcon: '',
|
|
5860
|
-
name: 'Mission Karmayogi',
|
|
5861
|
-
programCount: '50',
|
|
5862
|
-
},
|
|
5863
|
-
];
|
|
5864
|
-
return [4 /*yield*/, data
|
|
5865
|
-
// console.log('calling after - response, ', response)
|
|
5866
|
-
];
|
|
5925
|
+
return [4 /*yield*/, this.getRequestMethod(strip, strip.request.bookmarkRead, strip.request.apiUrl, calculateParentStatus)];
|
|
5867
5926
|
case 2:
|
|
5868
5927
|
response = _a.sent();
|
|
5869
|
-
|
|
5928
|
+
console.log('calling after - response, ', response);
|
|
5929
|
+
content = response.results.result.data.orgList;
|
|
5870
5930
|
if (response) {
|
|
5871
|
-
this.processStrip(strip, this.transformAllContentsToWidgets(
|
|
5931
|
+
this.processStrip(strip, this.transformAllContentsToWidgets(content, strip), 'done', calculateParentStatus, response);
|
|
5872
5932
|
}
|
|
5873
5933
|
else {
|
|
5874
5934
|
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
@@ -5915,20 +5975,115 @@
|
|
|
5915
5975
|
}); }));
|
|
5916
5976
|
};
|
|
5917
5977
|
/**
|
|
5918
|
-
* @param {?}
|
|
5978
|
+
* @param {?} strip
|
|
5979
|
+
* @param {?=} calculateParentStatus
|
|
5919
5980
|
* @return {?}
|
|
5920
5981
|
*/
|
|
5921
|
-
ContentStripWithTabsLibComponent.prototype.
|
|
5922
|
-
* @param {?}
|
|
5982
|
+
ContentStripWithTabsLibComponent.prototype.fetchAllPlaylistSearch = /**
|
|
5983
|
+
* @param {?} strip
|
|
5984
|
+
* @param {?=} calculateParentStatus
|
|
5923
5985
|
* @return {?}
|
|
5924
5986
|
*/
|
|
5925
|
-
function (
|
|
5926
|
-
|
|
5987
|
+
function (strip, calculateParentStatus) {
|
|
5988
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
5989
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
5990
|
+
var originalFilters, response, error_8;
|
|
5991
|
+
return __generator(this, function (_a) {
|
|
5992
|
+
switch (_a.label) {
|
|
5993
|
+
case 0:
|
|
5994
|
+
if (!(strip.request && strip.request.playlistSearch && Object.keys(strip.request.playlistSearch).length)) return [3 /*break*/, 4];
|
|
5995
|
+
originalFilters = [];
|
|
5996
|
+
if (strip.request &&
|
|
5997
|
+
strip.request.playlistSearch &&
|
|
5998
|
+
strip.request.playlistSearch.request &&
|
|
5999
|
+
strip.request.playlistSearch.request.filters) {
|
|
6000
|
+
originalFilters = strip.request.playlistSearch.request.filters;
|
|
6001
|
+
strip.request.playlistSearch.request.filters = this.postMethodFilters(strip.request.playlistSearch.request.filters);
|
|
6002
|
+
}
|
|
6003
|
+
_a.label = 1;
|
|
6004
|
+
case 1:
|
|
6005
|
+
_a.trys.push([1, 3, , 4]);
|
|
6006
|
+
return [4 /*yield*/, this.postRequestMethod(strip, strip.request.playlistSearch.request, strip.request.apiUrl, calculateParentStatus)];
|
|
6007
|
+
case 2:
|
|
6008
|
+
response = _a.sent();
|
|
6009
|
+
// console.log('calling after - response, ', response)
|
|
6010
|
+
if (response && response.results) {
|
|
6011
|
+
// console.log('calling after-- ')
|
|
6012
|
+
if (response.results.result.data && response.results.result.data.length) {
|
|
6013
|
+
this.processStrip(strip, this.transformContentsToWidgets(response.results.result.data, strip), 'done', calculateParentStatus, response.viewMoreUrl);
|
|
6014
|
+
}
|
|
6015
|
+
else {
|
|
6016
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
6017
|
+
this.emptyResponse.emit(true);
|
|
6018
|
+
}
|
|
6019
|
+
}
|
|
6020
|
+
else {
|
|
6021
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
6022
|
+
this.emptyResponse.emit(true);
|
|
6023
|
+
}
|
|
6024
|
+
return [3 /*break*/, 4];
|
|
6025
|
+
case 3:
|
|
6026
|
+
error_8 = _a.sent();
|
|
6027
|
+
this.emptyResponse.emit(true);
|
|
6028
|
+
return [3 /*break*/, 4];
|
|
6029
|
+
case 4: return [2 /*return*/];
|
|
6030
|
+
}
|
|
6031
|
+
});
|
|
6032
|
+
});
|
|
6033
|
+
};
|
|
6034
|
+
/**
|
|
6035
|
+
* @param {?} strip
|
|
6036
|
+
* @param {?=} calculateParentStatus
|
|
6037
|
+
* @return {?}
|
|
6038
|
+
*/
|
|
6039
|
+
ContentStripWithTabsLibComponent.prototype.fetchPlaylistReadData = /**
|
|
6040
|
+
* @param {?} strip
|
|
6041
|
+
* @param {?=} calculateParentStatus
|
|
6042
|
+
* @return {?}
|
|
6043
|
+
*/
|
|
6044
|
+
function (strip, calculateParentStatus) {
|
|
6045
|
+
if (calculateParentStatus === void 0) { calculateParentStatus = true; }
|
|
6046
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
6047
|
+
var originalFilters, response, content, error_9;
|
|
6048
|
+
return __generator(this, function (_a) {
|
|
6049
|
+
switch (_a.label) {
|
|
6050
|
+
case 0:
|
|
6051
|
+
if (!(strip.request && strip.request.playlistRead && Object.keys(strip.request.playlistRead).length)) return [3 /*break*/, 4];
|
|
6052
|
+
originalFilters = [];
|
|
6053
|
+
if (strip.request &&
|
|
6054
|
+
strip.request.playlistRead &&
|
|
6055
|
+
strip.request.playlistRead.type) {
|
|
6056
|
+
strip.request.apiUrl = this.getFullUrl(strip.request.apiUrl, strip.request.playlistRead.type);
|
|
6057
|
+
}
|
|
6058
|
+
_a.label = 1;
|
|
6059
|
+
case 1:
|
|
6060
|
+
_a.trys.push([1, 3, , 4]);
|
|
6061
|
+
return [4 /*yield*/, this.getRequestMethod(strip, strip.request.playlistRead, strip.request.apiUrl, calculateParentStatus)];
|
|
6062
|
+
case 2:
|
|
6063
|
+
response = _a.sent();
|
|
6064
|
+
console.log('calling after - response, ', response);
|
|
6065
|
+
if (response && response.results.result.content) {
|
|
6066
|
+
content = response.results.result.content;
|
|
6067
|
+
this.processStrip(strip, this.transformAllContentsToWidgets(content, strip), 'done', calculateParentStatus, response);
|
|
6068
|
+
}
|
|
6069
|
+
else {
|
|
6070
|
+
this.processStrip(strip, [], 'error', calculateParentStatus, null);
|
|
6071
|
+
this.emptyResponse.emit(true);
|
|
6072
|
+
}
|
|
6073
|
+
return [3 /*break*/, 4];
|
|
6074
|
+
case 3:
|
|
6075
|
+
error_9 = _a.sent();
|
|
6076
|
+
this.emptyResponse.emit(true);
|
|
6077
|
+
return [3 /*break*/, 4];
|
|
6078
|
+
case 4: return [2 /*return*/];
|
|
6079
|
+
}
|
|
6080
|
+
});
|
|
6081
|
+
});
|
|
5927
6082
|
};
|
|
5928
6083
|
ContentStripWithTabsLibComponent.decorators = [
|
|
5929
6084
|
{ type: core.Component, args: [{
|
|
5930
6085
|
selector: 'sb-uic-content-strip-with-tabs',
|
|
5931
|
-
template: "<ng-container *ngIf=\"!contentAvailable; else otherTemplate\"></ng-container>\n<ng-template #otherTemplate>\n <!-- <div *ngIf=\"showParentLoader\" class=\"text-center my-2\">\n <mat-spinner class=\"inline-block\"></mat-spinner>\n </div> -->\n <ng-container *ngIf=\"showParentError\" [sbUiResolverWidget]=\"widgetData.errorWidget\"></ng-container>\n <ng-container *ngIf=\"showParentNoData\" [sbUiResolverWidget]=\"widgetData.noDataWidget\"></ng-container>\n <ng-container *ngFor=\"let key of stripsKeyOrder; let i = index; trackBy: identify\">\n <ng-container *ngIf=\"isStripShowing(stripsResultDataMap[key])\">\n <a name=\"{{stripsResultDataMap[key]?.stripTitle}}\" [class]=\"key\">\n <div *ngIf=\"stripsResultDataMap && (getLength(stripsResultDataMap[key]) ||\n stripsResultDataMap[key]?.showOnNoData ||\n stripsResultDataMap[key]?.showOnLoader ||\n stripsResultDataMap[key]?.showOnError)\n \" [ngClass]=\"\n !widgetData?.isChannelStrip ? 'xs:px-8 sx:px-10ss' : i > 0 ? 'mt-12' : ''\n \" [id]=\"key\" [ngClass]=\"!widgetData?.isChannelStrip ? margin-bottom-custom : margin-bottom-xs\">\n <div [ngClass]=\"{ pad: stripsResultDataMap[key]?.stripBackground }\"\n [ngStyle]=\"{ 'background-color': stripsResultDataMap[key]?.stripBackground }\">\n <div class=\"flex flex-col pl-4 pr-4 md:pr-0 md:pl-0 \" [ngClass]=\"\n !widgetData?.isChannelStrip\n ? ''\n : stripsResultDataMap[key]?.stripTitle\n ? 'mb-8'\n : ''\n \">\n <div class=\"flex flex-1 items-center\">\n <p class=\"mat-subheading-1 margin-remove inline-block \" *ngIf=\"stripsResultDataMap[key]?.stripTitle\">\n <span class=\"capitalize\" *ngIf=\"stripsResultDataMap[key]?.disableTranslate\">\n {{stripsResultDataMap[key]?.stripTitle}}\n </span>\n <span *ngIf=\"!stripsResultDataMap[key]?.disableTranslate\">\n {{ translateLabels(stripsResultDataMap[key]?.stripTitle, 'home') }}\n </span>\n </p>\n\n <button *ngIf=\"stripsResultDataMap[key]?.stripInfo?.icon\" type=\"button\" mat-icon-button\n (click)=\"toggleInfo(stripsResultDataMap[key])\" i18n-matTooltip matTooltip=\"info\"\n class=\"margin-left-xs\">\n <mat-icon>{{ stripsResultDataMap[key]?.stripInfo?.icon.icon }}</mat-icon>\n </button>\n <a *ngIf=\"stripsResultDataMap[key]?.stripTitleLink?.link\"\n [routerLink]=\"stripsResultDataMap[key]?.stripTitleLink?.link\"\n [queryParams]=\"stripsResultDataMap[key]?.stripTitleLink?.link?.queryParams\">\n <mat-icon class=\"ws-mat-primary-primary-text ws-mat-default-text\" [color]=\"'accent'\">{{\n stripsResultDataMap[key]?.stripTitleLink?.icon }}</mat-icon>\n </a>\n <span class=\"spacer\"></span>\n <!-- viewAll start-->\n <div *ngIf=\"checkCondition(widgetData , stripsResultDataMap[key])\"\n class=\"ml-4 view-more ws-mat-default-text\">\n <a class=\"flex ws-mat-default-text items-center justify-center mat-body-1\" (click)=\"redirectViewAll(stripsResultDataMap[key], stripsResultDataMap[key]?.viewMoreUrl?.path, stripsResultDataMap[key]?.viewMoreUrl?.queryParams )\">\n <span i18n class=\"ws-mat-default-text\">{{translateLabels(widgetData.strips[0].viewMoreUrl.viewMoreText,'home') || 'See all'}}</span>\n <mat-icon class=\"ws-mat-default-text mat-icon notranslate material-icons mat-icon-no-color\" color=\"accent\">navigate_next</mat-icon>\n </a>\n </div>\n <!-- viewAll end-->\n </div>\n <button mat-icon-button (click)=\"setHiddenForStrip(key)\" *ngIf=\"stripsResultDataMap[key]?.canHideStrip\">\n <mat-icon>close</mat-icon>\n </button>\n <mat-icon class=\"cursor-pointer\" *ngIf=\"stripsResultDataMap[key]?.mode === 'accordion' && isMobile\"\n (click)=\"showAccordionData = !showAccordionData\">{{ showAccordionData ? 'expand_less' : 'expand_more' }}\n </mat-icon>\n </div>\n\n <div class=\"mb-4\" *ngIf=\"checkVisible(stripsResultDataMap[key])\">\n <ng-container [sbUiResolverWidget]=\"getdata(stripsResultDataMap[key])\">\n </ng-container>\n </div>\n\n <ng-container *ngIf=\"stripsResultDataMap[key]?.showOnNoData\"\n [sbUiResolverWidget]=\"stripsResultDataMap[key]?.noDataWidget\"></ng-container>\n <ng-container *ngIf=\"stripsResultDataMap[key]?.showOnError\"\n [sbUiResolverWidget]=\"stripsResultDataMap[key]?.errorWidget\"></ng-container>\n <!-- IF no errors then proceed to show tabs or non tabs strip -->\n <ng-container *ngIf=\"!stripsResultDataMap[key]?.showOnNoData && !stripsResultDataMap[key]?.showOnError\">\n <ng-container *ngIf=\"stripsResultDataMap[key].tabs && stripsResultDataMap[key].tabs.length\">\n <mat-tab-group animationDuration=\"0ms\" [selectedIndex]=\"getSelectedIndex(stripsResultDataMap[key], key)\"\n class=\"mat-tab-labels w-full strips-tabgroup\" dynamicHeight\n (selectedTabChange)=\"tabClicked($event, stripsResultDataMap[key], key)\">\n <mat-tab label=\"{{tab?.label}}\" *ngFor=\"let tab of stripsResultDataMap[key].tabs; let last = last;\">\n <ng-template mat-tab-label>\n <span>{{ translateLabels(tab?.label, 'home') }} </span>\n <span *ngIf=\"tab?.showTabDataCount && tab?.widgets?.length\">({{tab?.widgets?.length}})</span>\n </ng-template>\n <div>\n <!-- <ng-container [ngTemplateOutlet]=\"loader\" *ngIf=\"stripsResultDataMap[key]?.showOnLoader\">\n </ng-container> -->\n <div *ngIf=\"stripsResultDataMap && stripsResultDataMap[key]?.showOnLoader ||\n !tab.fetchTabStatus\"\n class=\"text-center my-2\">\n <sb-uic-horizontal-scroller-v2 [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\" [id]=\"key+'-scroller'\"\n [loadStatus]=\"'fetching'\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.loaderWidgets; trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n <div *ngIf=\"((tab?.fetchTabStatus && tab?.fetchTabStatus === 'done') &&\n (!tab?.widgets || !tab?.widgets?.length))\">\n <ng-container *ngIf=\"tab?.value === 'inprogress'; else msgTemp\">\n <div class=\"w-full flex flex-col items-center justify-center\">\n <img alt=\"\" class=\"mt-4 mb-4\" src=\"assets/icons/home/nodataDefault.svg\">\n <div class=\"mat-subheading-1 text-center info-content\">{{ 'contentstripmultiple.getReadyForLearningAdventure' | translate }} -\n <a class=\"click-here\" [routerLink]=\"'/page/learn'\">{{ 'contentstripmultiple.clickHere' | translate }}</a> {{ 'contentstripmultiple.toEnrollNextCourse' | translate }}</div>\n </div>\n </ng-container>\n <ng-template #msgTemp>\n <div class=\"w-full flex flex-col items-center justify-center\">\n <img alt=\"\" class=\"mt-4 mb-4\" src=\"assets/icons/home/nodataDefault.png\">\n <div class=\"mat-subheading-1 text-center\">{{ translateLabels(tab.nodataMsg, 'home') }}</div>\n </div>\n </ng-template>\n </div>\n <ng-container *ngIf=\"(tab?.fetchTabStatus === 'done' || tab?.widgets?.length)\">\n <ng-container *ngIf=\"!tab?.tabLoading\">\n\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\" [widgetsLength]=\"tab?.widgets?.length\"\n *ngIf=\"getContineuLearningLenth(stripsResultDataMap[key]) && showAccordion(key)\"\n [loadStatus]=\"'done'\" [defaultMaxWidgets]=\"tab?.maxWidgets ||\n stripsResultDataMap[key]?.sliderConfig?.maxWidgets || defaultMaxWidgets\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of tab?.widgets| slice:0:(tab?.maxWidgets ||\n stripsResultDataMap[key]?.sliderConfig?.maxWidgets || defaultMaxWidgets); trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </ng-container>\n </ng-container>\n </div>\n </mat-tab>\n </mat-tab-group>\n </ng-container>\n <ng-container *ngIf=\"!stripsResultDataMap[key].tabs || !stripsResultDataMap[key].tabs.length\">\n <div *ngIf=\"stripsResultDataMap && stripsResultDataMap[key]?.showOnLoader\" class=\"text-center my-2\">\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\"\n [loadStatus]=\"'fetching'\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.loaderWidgets; trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n <div class=\"\">\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\"\n *ngIf=\"getContineuLearningLenth(stripsResultDataMap[key]) && showAccordion(key)\" [widgetsLength]=\"stripsResultDataMap[key]?.widgets?.length\" [loadStatus]=\"'done'\" [defaultMaxWidgets]=\"stripsResultDataMap[key].sliderConfig?.maxWidgets || defaultMaxWidgets\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.widgets| slice:0:(stripsResultDataMap[key].sliderConfig?.maxWidgets || defaultMaxWidgets); trackBy: tracker\">\n <!-- <ng-container *ngIf=\"widget.widgetData.context.pageSection === 'continueLearning' \"> -->\n <!-- <ng-container *ngIf=\"widget.widgetData.content.completionPercentage !== 100\"\n [sbUiResolverWidget]=\"widget\"></ng-container> -->\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n <!-- </ng-container> -->\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n </ng-container>\n </ng-container>\n </div>\n </div>\n </a>\n\n </ng-container>\n </ng-container>\n</ng-template>",
|
|
6086
|
+
template: "<ng-container *ngIf=\"!contentAvailable; else otherTemplate\"></ng-container>\n<ng-template #otherTemplate>\n <!-- <div *ngIf=\"showParentLoader\" class=\"text-center my-2\">\n <mat-spinner class=\"inline-block\"></mat-spinner>\n </div> -->\n <ng-container *ngIf=\"showParentError\" [sbUiResolverWidget]=\"widgetData.errorWidget\"></ng-container>\n <ng-container *ngIf=\"showParentNoData\" [sbUiResolverWidget]=\"widgetData.noDataWidget\"></ng-container>\n <ng-container *ngFor=\"let key of stripsKeyOrder; let i = index; trackBy: identify\">\n <ng-container *ngIf=\"isStripShowing(stripsResultDataMap[key])\">\n <a name=\"{{stripsResultDataMap[key]?.stripTitle}}\" [class]=\"key\">\n <div *ngIf=\"stripsResultDataMap && (getLength(stripsResultDataMap[key]) ||\n stripsResultDataMap[key]?.showOnNoData ||\n stripsResultDataMap[key]?.showOnLoader ||\n stripsResultDataMap[key]?.showOnError)\n \" [ngClass]=\"\n !widgetData?.isChannelStrip ? 'xs:px-8 sx:px-10ss' : i > 0 ? 'mt-12' : ''\n \" [id]=\"key\" [ngClass]=\"!widgetData?.isChannelStrip ? margin-bottom-custom : margin-bottom-xs\">\n <div [ngClass]=\"{ pad: stripsResultDataMap[key]?.stripBackground }\"\n [ngStyle]=\"{ 'background-color': stripsResultDataMap[key]?.stripBackground }\">\n <div class=\"flex flex-col pl-4 pr-4 md:pr-0 md:pl-0 \" [ngClass]=\"\n !widgetData?.isChannelStrip\n ? ''\n : stripsResultDataMap[key]?.stripTitle\n ? 'mb-8'\n : ''\n \">\n <div class=\"flex flex-1 items-center\">\n <p class=\"mat-subheading-1 margin-remove inline-block \" *ngIf=\"stripsResultDataMap[key]?.stripTitle\">\n <span class=\"capitalize\" *ngIf=\"stripsResultDataMap[key]?.disableTranslate\">\n {{stripsResultDataMap[key]?.stripTitle}}\n </span>\n <span *ngIf=\"!stripsResultDataMap[key]?.disableTranslate\">\n {{ translateLabels(stripsResultDataMap[key]?.stripTitle, 'home') }}\n </span>\n </p>\n\n <button *ngIf=\"stripsResultDataMap[key]?.stripInfo?.icon\" type=\"button\" mat-icon-button\n (click)=\"toggleInfo(stripsResultDataMap[key])\" i18n-matTooltip matTooltip=\"info\"\n class=\"margin-left-xs\">\n <mat-icon>{{ stripsResultDataMap[key]?.stripInfo?.icon.icon }}</mat-icon>\n </button>\n <a *ngIf=\"stripsResultDataMap[key]?.stripTitleLink?.link\"\n [routerLink]=\"stripsResultDataMap[key]?.stripTitleLink?.link\"\n [queryParams]=\"stripsResultDataMap[key]?.stripTitleLink?.link?.queryParams\">\n <mat-icon class=\"ws-mat-primary-primary-text ws-mat-default-text\" [color]=\"'accent'\">{{\n stripsResultDataMap[key]?.stripTitleLink?.icon }}</mat-icon>\n </a>\n <span class=\"spacer\"></span>\n <!-- viewAll start-->\n <div *ngIf=\"checkCondition(widgetData , stripsResultDataMap[key])\"\n class=\"ml-4 view-more ws-mat-default-text\">\n <a class=\"flex ws-mat-default-text items-center justify-center mat-body-1 cursor-pointer\" \n (click)=\"raiseTelemetry(stripsResultDataMap[key]);redirectViewAll(stripsResultDataMap[key], stripsResultDataMap[key]?.viewMoreUrl?.path, stripsResultDataMap[key]?.viewMoreUrl?.queryParams )\">\n <span i18n class=\"ws-mat-default-text\">{{translateLabels(widgetData.strips[0].viewMoreUrl.viewMoreText,'home') || 'See all'}}</span>\n <mat-icon class=\"ws-mat-default-text mat-icon notranslate material-icons mat-icon-no-color\" color=\"accent\">navigate_next</mat-icon>\n </a>\n </div>\n <!-- viewAll end-->\n </div>\n <button mat-icon-button (click)=\"setHiddenForStrip(key)\" *ngIf=\"stripsResultDataMap[key]?.canHideStrip\">\n <mat-icon>close</mat-icon>\n </button>\n <mat-icon class=\"cursor-pointer\" *ngIf=\"stripsResultDataMap[key]?.mode === 'accordion' && isMobile\"\n (click)=\"showAccordionData = !showAccordionData\">{{ showAccordionData ? 'expand_less' : 'expand_more' }}\n </mat-icon>\n </div>\n\n <div class=\"mb-4\" *ngIf=\"checkVisible(stripsResultDataMap[key])\">\n <ng-container [sbUiResolverWidget]=\"getdata(stripsResultDataMap[key])\">\n </ng-container>\n </div>\n\n <ng-container *ngIf=\"stripsResultDataMap[key]?.showOnNoData\"\n [sbUiResolverWidget]=\"stripsResultDataMap[key]?.noDataWidget\"></ng-container>\n <ng-container *ngIf=\"stripsResultDataMap[key]?.showOnError\"\n [sbUiResolverWidget]=\"stripsResultDataMap[key]?.errorWidget\"></ng-container>\n <!-- IF no errors then proceed to show tabs or non tabs strip -->\n <ng-container *ngIf=\"!stripsResultDataMap[key]?.showOnNoData && !stripsResultDataMap[key]?.showOnError\">\n <ng-container *ngIf=\"stripsResultDataMap[key].tabs && stripsResultDataMap[key].tabs.length\">\n <mat-tab-group animationDuration=\"0ms\" [selectedIndex]=\"getSelectedIndex(stripsResultDataMap[key], key)\"\n class=\"mat-tab-labels w-full strips-tabgroup\" dynamicHeight\n (selectedTabChange)=\"tabClicked($event, stripsResultDataMap[key], key)\">\n <mat-tab label=\"{{tab?.label}}\" *ngFor=\"let tab of stripsResultDataMap[key].tabs; let last = last;\">\n <ng-template mat-tab-label>\n <span>{{ translateLabels(tab?.label, 'home') }} </span>\n <span *ngIf=\"tab?.showTabDataCount && tab?.widgets?.length\">({{tab?.widgets?.length}})</span>\n </ng-template>\n <div>\n <!-- <ng-container [ngTemplateOutlet]=\"loader\" *ngIf=\"stripsResultDataMap[key]?.showOnLoader\">\n </ng-container> -->\n <div *ngIf=\"stripsResultDataMap && stripsResultDataMap[key]?.showOnLoader ||\n !tab.fetchTabStatus\"\n class=\"text-center my-2\">\n <sb-uic-horizontal-scroller-v2 [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\" [id]=\"key+'-scroller'\"\n [loadStatus]=\"'fetching'\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.loaderWidgets; trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n <div *ngIf=\"((tab?.fetchTabStatus && tab?.fetchTabStatus === 'done') &&\n (!tab?.widgets || !tab?.widgets?.length))\">\n <ng-container *ngIf=\"tab?.value === 'inprogress'; else msgTemp\">\n <div class=\"w-full flex flex-col items-center justify-center\">\n <img alt=\"\" class=\"mt-4 mb-4\" src=\"assets/icons/home/nodataDefault.svg\">\n <div class=\"mat-subheading-1 text-center info-content\">{{ 'contentstripmultiple.getReadyForLearningAdventure' | translate }} -\n <a class=\"click-here\" [routerLink]=\"'/page/learn'\">{{ 'contentstripmultiple.clickHere' | translate }}</a> {{ 'contentstripmultiple.toEnrollNextCourse' | translate }}</div>\n </div>\n </ng-container>\n <ng-template #msgTemp>\n <div class=\"w-full flex flex-col items-center justify-center\">\n <img alt=\"\" class=\"mt-4 mb-4\" src=\"assets/icons/home/nodataDefault.png\">\n <div class=\"mat-subheading-1 text-center\">{{ translateLabels(tab.nodataMsg, 'home') }}</div>\n </div>\n </ng-template>\n </div>\n <ng-container *ngIf=\"(tab?.fetchTabStatus === 'done' || tab?.widgets?.length)\">\n <ng-container *ngIf=\"!tab?.tabLoading\">\n\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\" [widgetsLength]=\"tab?.widgets?.length\"\n *ngIf=\"getContineuLearningLenth(stripsResultDataMap[key]) && showAccordion(key)\"\n [loadStatus]=\"'done'\" [defaultMaxWidgets]=\"tab?.maxWidgets ||\n stripsResultDataMap[key]?.sliderConfig?.maxWidgets || defaultMaxWidgets\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of tab?.widgets| slice:0:(tab?.maxWidgets ||\n stripsResultDataMap[key]?.sliderConfig?.maxWidgets || defaultMaxWidgets); trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </ng-container>\n </ng-container>\n </div>\n </mat-tab>\n </mat-tab-group>\n </ng-container>\n <ng-container *ngIf=\"!stripsResultDataMap[key].tabs || !stripsResultDataMap[key].tabs.length\">\n <div *ngIf=\"stripsResultDataMap && stripsResultDataMap[key]?.showOnLoader\" class=\"text-center my-2\">\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\"\n [loadStatus]=\"'fetching'\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.loaderWidgets; trackBy: tracker\">\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n <div class=\"\">\n <sb-uic-horizontal-scroller-v2 [id]=\"key+'-scroller'\" [sliderConfig]=\"stripsResultDataMap[key]?.sliderConfig\"\n *ngIf=\"getContineuLearningLenth(stripsResultDataMap[key]) && showAccordion(key)\" [widgetsLength]=\"stripsResultDataMap[key]?.widgets?.length\" [loadStatus]=\"'done'\" [defaultMaxWidgets]=\"stripsResultDataMap[key].sliderConfig?.maxWidgets || defaultMaxWidgets\" [stripConfig]=\"stripsResultDataMap[key]?.stripConfig\">\n <ng-container *ngFor=\"let widget of stripsResultDataMap[key]?.widgets| slice:0:(stripsResultDataMap[key].sliderConfig?.maxWidgets || defaultMaxWidgets); trackBy: tracker\">\n <!-- <ng-container *ngIf=\"widget.widgetData.context.pageSection === 'continueLearning' \"> -->\n <!-- <ng-container *ngIf=\"widget.widgetData.content.completionPercentage !== 100\"\n [sbUiResolverWidget]=\"widget\"></ng-container> -->\n <ng-container [sbUiResolverWidget]=\"widget\"></ng-container>\n <!-- </ng-container> -->\n </ng-container>\n </sb-uic-horizontal-scroller-v2>\n </div>\n </ng-container>\n </ng-container>\n </div>\n </div>\n </a>\n\n </ng-container>\n </ng-container>\n</ng-template>",
|
|
5932
6087
|
styles: [".view-more{display:flex;align-items:center;text-align:center;height:40px;justify-content:center}.view-more .icon{font-size:24px;width:24px;height:24px;border:1px solid;border-radius:50%;padding:8px;margin-bottom:8px}.margin-bottom-custom{margin-bottom:60px}.view-more:hover{background-color:#dcdfe5}::ng-deep.strips-tabgroup .mat-tab-header{border-bottom:2px solid rgba(0,0,0,.12)}::ng-deep.strips-tabgroup .mat-tab-body{padding:20px 0!important;box-sizing:border-box;overflow-y:initial!important}::ng-deep.strips-tabgroup .mat-tab-body-wrapper{overflow:inherit!important}::ng-deep.strips-tabgroup .mat-tab-label{border-bottom:0 solid rgba(0,0,0,.1);margin-right:0;opacity:1}::ng-deep.strips-tabgroup .mat-tab-label .mat-tab-label-content{text-transform:inherit;font:400 14px/20px Lato}::ng-deep.strips-tabgroup .mat-tab-label-active .mat-tab-label-content{font-weight:700!important}.click-here{color:#1b4ca1}.info-content{opacity:1;color:rgba(0,0,0,.87);font:700 14px/20px Lato-Bold;text-align:center}"]
|
|
5933
6088
|
}] }
|
|
5934
6089
|
];
|
|
@@ -6606,7 +6761,8 @@
|
|
|
6606
6761
|
/** @type {?} */
|
|
6607
6762
|
var API_END_POINTS$2 = {
|
|
6608
6763
|
PROVIDER_INSIGHTS: "/apis/proxies/v8/microsite/read/insights",
|
|
6609
|
-
TRAINING_DETAILS: "apis/proxies/v8/sunbirdigot/search"
|
|
6764
|
+
TRAINING_DETAILS: "apis/proxies/v8/sunbirdigot/search",
|
|
6765
|
+
ANNOUNCEMENTS_DETAILS: "apis/proxies/v8/announcements/v1/search"
|
|
6610
6766
|
};
|
|
6611
6767
|
var InsiteDataService = /** @class */ (function () {
|
|
6612
6768
|
function InsiteDataService(http) {
|
|
@@ -6623,6 +6779,17 @@
|
|
|
6623
6779
|
function (request) {
|
|
6624
6780
|
return this.http.post(API_END_POINTS$2.PROVIDER_INSIGHTS, request);
|
|
6625
6781
|
};
|
|
6782
|
+
/**
|
|
6783
|
+
* @param {?} request
|
|
6784
|
+
* @return {?}
|
|
6785
|
+
*/
|
|
6786
|
+
InsiteDataService.prototype.fetchAnnouncementsData = /**
|
|
6787
|
+
* @param {?} request
|
|
6788
|
+
* @return {?}
|
|
6789
|
+
*/
|
|
6790
|
+
function (request) {
|
|
6791
|
+
return this.http.post(API_END_POINTS$2.ANNOUNCEMENTS_DETAILS, request);
|
|
6792
|
+
};
|
|
6626
6793
|
/**
|
|
6627
6794
|
* @param {?} request
|
|
6628
6795
|
* @return {?}
|
|
@@ -6911,7 +7078,6 @@
|
|
|
6911
7078
|
this.currentMonthAndYear = this.datePipe.transform(this.currentDate, 'MMMM y');
|
|
6912
7079
|
this.selectedMonth = this.datePipe.transform(this.currentDate, 'LLLL yyyy');
|
|
6913
7080
|
if (this.fullCalendor) {
|
|
6914
|
-
console.log("this.currentDate ", this.currentDate);
|
|
6915
7081
|
this.days = this.getDaysInMonth(this.currentDate.getFullYear(), this.currentDate.getMonth());
|
|
6916
7082
|
this.getMonthsDropdownData();
|
|
6917
7083
|
}
|
|
@@ -8206,11 +8372,13 @@
|
|
|
8206
8372
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
8207
8373
|
*/
|
|
8208
8374
|
var AnnouncementsComponent = /** @class */ (function () {
|
|
8209
|
-
function AnnouncementsComponent() {
|
|
8375
|
+
function AnnouncementsComponent(insightSvc) {
|
|
8376
|
+
this.insightSvc = insightSvc;
|
|
8210
8377
|
this.mobileHeight = false;
|
|
8378
|
+
this.fetchDataFromApi = false;
|
|
8211
8379
|
this.openDialog = new core.EventEmitter();
|
|
8212
8380
|
this.isLoading = false;
|
|
8213
|
-
this.
|
|
8381
|
+
this.announcements = [];
|
|
8214
8382
|
}
|
|
8215
8383
|
/**
|
|
8216
8384
|
* @return {?}
|
|
@@ -8218,14 +8386,67 @@
|
|
|
8218
8386
|
AnnouncementsComponent.prototype.ngOnInit = /**
|
|
8219
8387
|
* @return {?}
|
|
8220
8388
|
*/
|
|
8389
|
+
function () {
|
|
8390
|
+
if (this.fetchDataFromApi) {
|
|
8391
|
+
this.isLoading = true;
|
|
8392
|
+
this.fetchData();
|
|
8393
|
+
}
|
|
8394
|
+
};
|
|
8395
|
+
/**
|
|
8396
|
+
* @return {?}
|
|
8397
|
+
*/
|
|
8398
|
+
AnnouncementsComponent.prototype.fetchData = /**
|
|
8399
|
+
* @return {?}
|
|
8400
|
+
*/
|
|
8221
8401
|
function () {
|
|
8222
8402
|
var _this = this;
|
|
8223
|
-
|
|
8403
|
+
/** @type {?} */
|
|
8404
|
+
var request = {
|
|
8405
|
+
filterCriteriaMap: {
|
|
8406
|
+
channel: [this.channelId],
|
|
8407
|
+
},
|
|
8408
|
+
requestedFields: [
|
|
8409
|
+
"name",
|
|
8410
|
+
"description",
|
|
8411
|
+
"createdOn",
|
|
8412
|
+
"updatedOn",
|
|
8413
|
+
"category"
|
|
8414
|
+
],
|
|
8415
|
+
orderBy: "createdOn",
|
|
8416
|
+
orderDirection: "ASC",
|
|
8417
|
+
facets: [
|
|
8418
|
+
"channel"
|
|
8419
|
+
],
|
|
8420
|
+
pageSize: this.objectData.pageSize
|
|
8421
|
+
};
|
|
8422
|
+
this.insightSvc.fetchAnnouncementsData(request).subscribe((/**
|
|
8423
|
+
* @param {?} res
|
|
8224
8424
|
* @return {?}
|
|
8225
8425
|
*/
|
|
8226
|
-
function () {
|
|
8426
|
+
function (res) {
|
|
8427
|
+
if (res && res.result && res.result.data) {
|
|
8428
|
+
res.result.data.forEach((/**
|
|
8429
|
+
* @param {?} resp
|
|
8430
|
+
* @return {?}
|
|
8431
|
+
*/
|
|
8432
|
+
function (resp) {
|
|
8433
|
+
_this.announcements.push({
|
|
8434
|
+
value: resp.description,
|
|
8435
|
+
expanded: false
|
|
8436
|
+
});
|
|
8437
|
+
}));
|
|
8438
|
+
}
|
|
8439
|
+
_this.objectData.list = _this.announcements;
|
|
8227
8440
|
_this.isLoading = false;
|
|
8228
|
-
}),
|
|
8441
|
+
}), (/**
|
|
8442
|
+
* @param {?} error
|
|
8443
|
+
* @return {?}
|
|
8444
|
+
*/
|
|
8445
|
+
function (error) {
|
|
8446
|
+
console.log(error);
|
|
8447
|
+
_this.objectData.list = [];
|
|
8448
|
+
_this.isLoading = false;
|
|
8449
|
+
}));
|
|
8229
8450
|
};
|
|
8230
8451
|
/**
|
|
8231
8452
|
* @param {?} item
|
|
@@ -8252,16 +8473,20 @@
|
|
|
8252
8473
|
AnnouncementsComponent.decorators = [
|
|
8253
8474
|
{ type: core.Component, args: [{
|
|
8254
8475
|
selector: 'sb-uic-announcements',
|
|
8255
|
-
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
|
|
8256
|
-
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{
|
|
8476
|
+
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",
|
|
8477
|
+
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}}"]
|
|
8257
8478
|
}] }
|
|
8258
8479
|
];
|
|
8259
8480
|
/** @nocollapse */
|
|
8260
|
-
AnnouncementsComponent.ctorParameters = function () { return [
|
|
8481
|
+
AnnouncementsComponent.ctorParameters = function () { return [
|
|
8482
|
+
{ type: InsiteDataService }
|
|
8483
|
+
]; };
|
|
8261
8484
|
AnnouncementsComponent.propDecorators = {
|
|
8262
8485
|
objectData: [{ type: core.Input }],
|
|
8263
8486
|
layoutType: [{ type: core.Input }],
|
|
8264
8487
|
mobileHeight: [{ type: core.Input }],
|
|
8488
|
+
fetchDataFromApi: [{ type: core.Input }],
|
|
8489
|
+
channelId: [{ type: core.Input }],
|
|
8265
8490
|
openDialog: [{ type: core.Output }]
|
|
8266
8491
|
};
|
|
8267
8492
|
return AnnouncementsComponent;
|
|
@@ -8274,9 +8499,17 @@
|
|
|
8274
8499
|
/** @type {?} */
|
|
8275
8500
|
AnnouncementsComponent.prototype.mobileHeight;
|
|
8276
8501
|
/** @type {?} */
|
|
8502
|
+
AnnouncementsComponent.prototype.fetchDataFromApi;
|
|
8503
|
+
/** @type {?} */
|
|
8504
|
+
AnnouncementsComponent.prototype.channelId;
|
|
8505
|
+
/** @type {?} */
|
|
8277
8506
|
AnnouncementsComponent.prototype.openDialog;
|
|
8278
8507
|
/** @type {?} */
|
|
8279
8508
|
AnnouncementsComponent.prototype.isLoading;
|
|
8509
|
+
/** @type {?} */
|
|
8510
|
+
AnnouncementsComponent.prototype.announcements;
|
|
8511
|
+
/** @type {?} */
|
|
8512
|
+
AnnouncementsComponent.prototype.insightSvc;
|
|
8280
8513
|
}
|
|
8281
8514
|
|
|
8282
8515
|
/**
|
|
@@ -8420,6 +8653,7 @@
|
|
|
8420
8653
|
_this.configSvc = configSvc;
|
|
8421
8654
|
_this.contSvc = contSvc;
|
|
8422
8655
|
_this.router = router;
|
|
8656
|
+
_this.triggerTelemetry = new core.EventEmitter();
|
|
8423
8657
|
_this.isIntranetAllowedSettings = false;
|
|
8424
8658
|
return _this;
|
|
8425
8659
|
}
|
|
@@ -8516,10 +8750,21 @@
|
|
|
8516
8750
|
clearInterval(this.cbPlanInterval);
|
|
8517
8751
|
}
|
|
8518
8752
|
};
|
|
8753
|
+
/**
|
|
8754
|
+
* @param {?} data
|
|
8755
|
+
* @return {?}
|
|
8756
|
+
*/
|
|
8757
|
+
CardsComponent.prototype.raiseCardClick = /**
|
|
8758
|
+
* @param {?} data
|
|
8759
|
+
* @return {?}
|
|
8760
|
+
*/
|
|
8761
|
+
function (data) {
|
|
8762
|
+
this.triggerTelemetry.emit(data);
|
|
8763
|
+
};
|
|
8519
8764
|
CardsComponent.decorators = [
|
|
8520
8765
|
{ type: core.Component, args: [{
|
|
8521
8766
|
selector: 'sb-uic-cards',
|
|
8522
|
-
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
|
|
8767
|
+
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>",
|
|
8523
8768
|
styles: [""]
|
|
8524
8769
|
}] }
|
|
8525
8770
|
];
|
|
@@ -8531,7 +8776,8 @@
|
|
|
8531
8776
|
{ type: router.Router }
|
|
8532
8777
|
]; };
|
|
8533
8778
|
CardsComponent.propDecorators = {
|
|
8534
|
-
widgetData: [{ type: core.Input }]
|
|
8779
|
+
widgetData: [{ type: core.Input }],
|
|
8780
|
+
triggerTelemetry: [{ type: core.Output }]
|
|
8535
8781
|
};
|
|
8536
8782
|
return CardsComponent;
|
|
8537
8783
|
}(resolverV2.WidgetBaseComponent));
|
|
@@ -8539,6 +8785,8 @@
|
|
|
8539
8785
|
/** @type {?} */
|
|
8540
8786
|
CardsComponent.prototype.widgetData;
|
|
8541
8787
|
/** @type {?} */
|
|
8788
|
+
CardsComponent.prototype.triggerTelemetry;
|
|
8789
|
+
/** @type {?} */
|
|
8542
8790
|
CardsComponent.prototype.isIntranetAllowedSettings;
|
|
8543
8791
|
/** @type {?} */
|
|
8544
8792
|
CardsComponent.prototype.cbPlanMapData;
|
|
@@ -8671,14 +8919,19 @@
|
|
|
8671
8919
|
* @return {?}
|
|
8672
8920
|
*/
|
|
8673
8921
|
function (contentData) {
|
|
8922
|
+
// for telemetry
|
|
8923
|
+
if (this.widgetData && this.widgetData.context && this.widgetData.context.pageSection) {
|
|
8924
|
+
contentData['typeOfTelemetry'] = this.widgetData.context.pageSection;
|
|
8925
|
+
}
|
|
8674
8926
|
this.contSvc.changeTelemetryData(contentData);
|
|
8927
|
+
// for redirection
|
|
8675
8928
|
this.contentData.emit(contentData);
|
|
8676
8929
|
};
|
|
8677
8930
|
CardPortraitComponent.decorators = [
|
|
8678
8931
|
{ type: core.Component, args: [{
|
|
8679
8932
|
selector: 'sb-uic-card-portrait',
|
|
8680
8933
|
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>",
|
|
8681
|
-
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:
|
|
8934
|
+
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}"]
|
|
8682
8935
|
}] }
|
|
8683
8936
|
];
|
|
8684
8937
|
/** @nocollapse */
|
|
@@ -9650,13 +9903,16 @@
|
|
|
9650
9903
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
9651
9904
|
*/
|
|
9652
9905
|
var CardMDOChannelComponent = /** @class */ (function () {
|
|
9653
|
-
function CardMDOChannelComponent(events, translate, langtranslations, configSvc) {
|
|
9906
|
+
function CardMDOChannelComponent(events, translate, langtranslations, configSvc, contSvc, router) {
|
|
9654
9907
|
var _this = this;
|
|
9655
9908
|
this.events = events;
|
|
9656
9909
|
this.translate = translate;
|
|
9657
9910
|
this.langtranslations = langtranslations;
|
|
9658
9911
|
this.configSvc = configSvc;
|
|
9659
|
-
this.
|
|
9912
|
+
this.contSvc = contSvc;
|
|
9913
|
+
this.router = router;
|
|
9914
|
+
this.channelData = new core.EventEmitter();
|
|
9915
|
+
this.emitTelemetry = new core.EventEmitter();
|
|
9660
9916
|
this.widgetType = '';
|
|
9661
9917
|
this.widgetSubType = '';
|
|
9662
9918
|
this.langtranslations.languageSelectedObservable.subscribe((/**
|
|
@@ -9691,34 +9947,47 @@
|
|
|
9691
9947
|
}
|
|
9692
9948
|
};
|
|
9693
9949
|
/**
|
|
9950
|
+
* @param {?} contentData
|
|
9694
9951
|
* @return {?}
|
|
9695
9952
|
*/
|
|
9696
9953
|
CardMDOChannelComponent.prototype.raiseTelemetry = /**
|
|
9954
|
+
* @param {?} contentData
|
|
9697
9955
|
* @return {?}
|
|
9698
9956
|
*/
|
|
9699
|
-
function () {
|
|
9700
|
-
|
|
9701
|
-
|
|
9702
|
-
|
|
9703
|
-
|
|
9704
|
-
|
|
9705
|
-
|
|
9706
|
-
|
|
9707
|
-
|
|
9708
|
-
|
|
9709
|
-
|
|
9710
|
-
|
|
9711
|
-
|
|
9712
|
-
|
|
9713
|
-
|
|
9714
|
-
|
|
9715
|
-
|
|
9957
|
+
function (contentData) {
|
|
9958
|
+
this.emitTelemetry.emit(contentData);
|
|
9959
|
+
if (this.widgetData) {
|
|
9960
|
+
contentData['typeOfTelemetry'] = 'mdo-channel';
|
|
9961
|
+
}
|
|
9962
|
+
this.contSvc.changeTelemetryData(contentData);
|
|
9963
|
+
};
|
|
9964
|
+
/**
|
|
9965
|
+
* @param {?} channeldata
|
|
9966
|
+
* @return {?}
|
|
9967
|
+
*/
|
|
9968
|
+
CardMDOChannelComponent.prototype.channelClick = /**
|
|
9969
|
+
* @param {?} channeldata
|
|
9970
|
+
* @return {?}
|
|
9971
|
+
*/
|
|
9972
|
+
function (channeldata) {
|
|
9973
|
+
this.channelData.emit(channeldata);
|
|
9974
|
+
};
|
|
9975
|
+
/**
|
|
9976
|
+
* @param {?} content
|
|
9977
|
+
* @return {?}
|
|
9978
|
+
*/
|
|
9979
|
+
CardMDOChannelComponent.prototype.redirectTo = /**
|
|
9980
|
+
* @param {?} content
|
|
9981
|
+
* @return {?}
|
|
9982
|
+
*/
|
|
9983
|
+
function (content) {
|
|
9984
|
+
this.router.navigate(["/app/learn/mdo-channels/" + content.orgName + "/" + content.identifier + "/micro-sites"]);
|
|
9716
9985
|
};
|
|
9717
9986
|
CardMDOChannelComponent.decorators = [
|
|
9718
9987
|
{ type: core.Component, args: [{
|
|
9719
9988
|
selector: 'sb-uic-card-mdo-channel',
|
|
9720
|
-
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()
|
|
9721
|
-
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}"]
|
|
9989
|
+
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>",
|
|
9990
|
+
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}}"]
|
|
9722
9991
|
}] }
|
|
9723
9992
|
];
|
|
9724
9993
|
/** @nocollapse */
|
|
@@ -9726,11 +9995,14 @@
|
|
|
9726
9995
|
{ type: utilsV2.EventService },
|
|
9727
9996
|
{ type: core$1.TranslateService },
|
|
9728
9997
|
{ type: utilsV2.MultilingualTranslationsService },
|
|
9729
|
-
{ type: utilsV2.ConfigurationsService }
|
|
9998
|
+
{ type: utilsV2.ConfigurationsService },
|
|
9999
|
+
{ type: WidgetContentService },
|
|
10000
|
+
{ type: router.Router }
|
|
9730
10001
|
]; };
|
|
9731
10002
|
CardMDOChannelComponent.propDecorators = {
|
|
9732
10003
|
widgetData: [{ type: core.Input }],
|
|
9733
|
-
|
|
10004
|
+
channelData: [{ type: core.Output }],
|
|
10005
|
+
emitTelemetry: [{ type: core.Output }]
|
|
9734
10006
|
};
|
|
9735
10007
|
return CardMDOChannelComponent;
|
|
9736
10008
|
}());
|
|
@@ -9738,7 +10010,9 @@
|
|
|
9738
10010
|
/** @type {?} */
|
|
9739
10011
|
CardMDOChannelComponent.prototype.widgetData;
|
|
9740
10012
|
/** @type {?} */
|
|
9741
|
-
CardMDOChannelComponent.prototype.
|
|
10013
|
+
CardMDOChannelComponent.prototype.channelData;
|
|
10014
|
+
/** @type {?} */
|
|
10015
|
+
CardMDOChannelComponent.prototype.emitTelemetry;
|
|
9742
10016
|
/** @type {?} */
|
|
9743
10017
|
CardMDOChannelComponent.prototype.defaultThumbnail;
|
|
9744
10018
|
/** @type {?} */
|
|
@@ -9769,6 +10043,13 @@
|
|
|
9769
10043
|
* @private
|
|
9770
10044
|
*/
|
|
9771
10045
|
CardMDOChannelComponent.prototype.configSvc;
|
|
10046
|
+
/**
|
|
10047
|
+
* @type {?}
|
|
10048
|
+
* @private
|
|
10049
|
+
*/
|
|
10050
|
+
CardMDOChannelComponent.prototype.contSvc;
|
|
10051
|
+
/** @type {?} */
|
|
10052
|
+
CardMDOChannelComponent.prototype.router;
|
|
9772
10053
|
}
|
|
9773
10054
|
|
|
9774
10055
|
/**
|
|
@@ -9785,6 +10066,7 @@
|
|
|
9785
10066
|
this.configSvc = configSvc;
|
|
9786
10067
|
this.isCardLoading = false;
|
|
9787
10068
|
this.contentData = new core.EventEmitter();
|
|
10069
|
+
this.triggerTelemetry = new core.EventEmitter();
|
|
9788
10070
|
this.isCardFlipped = false;
|
|
9789
10071
|
this.acbpConstants = NsCardContent$1.ACBPConst;
|
|
9790
10072
|
this.showFlip = false;
|
|
@@ -9847,35 +10129,21 @@
|
|
|
9847
10129
|
this.contentData.emit(contentData);
|
|
9848
10130
|
};
|
|
9849
10131
|
/**
|
|
10132
|
+
* @param {?} contentData
|
|
9850
10133
|
* @return {?}
|
|
9851
10134
|
*/
|
|
9852
10135
|
CardWideV2Component.prototype.raiseTelemetry = /**
|
|
10136
|
+
* @param {?} contentData
|
|
9853
10137
|
* @return {?}
|
|
9854
10138
|
*/
|
|
9855
|
-
function () {
|
|
9856
|
-
|
|
9857
|
-
// return
|
|
9858
|
-
// }
|
|
9859
|
-
this.events.raiseInteractTelemetry({
|
|
9860
|
-
type: 'click',
|
|
9861
|
-
subType: this.widgetType + "-" + this.widgetSubType,
|
|
9862
|
-
id: lodash.camelCase(this.widgetData.content.primaryCategory) + "-card",
|
|
9863
|
-
}, {
|
|
9864
|
-
id: this.widgetData.content.identifier,
|
|
9865
|
-
type: this.widgetData.content.primaryCategory,
|
|
9866
|
-
//context: this.widgetData.context,
|
|
9867
|
-
rollup: {},
|
|
9868
|
-
ver: "" + this.widgetData.content.version + '',
|
|
9869
|
-
}, {
|
|
9870
|
-
pageIdExt: lodash.camelCase(this.widgetData.content.primaryCategory) + "-card",
|
|
9871
|
-
module: lodash.camelCase(this.widgetData.content.primaryCategory),
|
|
9872
|
-
});
|
|
10139
|
+
function (contentData) {
|
|
10140
|
+
this.triggerTelemetry.emit(contentData);
|
|
9873
10141
|
};
|
|
9874
10142
|
CardWideV2Component.decorators = [
|
|
9875
10143
|
{ type: core.Component, args: [{
|
|
9876
10144
|
selector: 'sb-uic-card-wide-v2',
|
|
9877
|
-
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
|
|
9878
|
-
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}"]
|
|
10145
|
+
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>",
|
|
10146
|
+
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}"]
|
|
9879
10147
|
}] }
|
|
9880
10148
|
];
|
|
9881
10149
|
/** @nocollapse */
|
|
@@ -9893,7 +10161,8 @@
|
|
|
9893
10161
|
isIntranetAllowedSettings: [{ type: core.Input }],
|
|
9894
10162
|
cbPlanMapData: [{ type: core.Input }],
|
|
9895
10163
|
isCardLoading: [{ type: core.Input }],
|
|
9896
|
-
contentData: [{ type: core.Output }]
|
|
10164
|
+
contentData: [{ type: core.Output }],
|
|
10165
|
+
triggerTelemetry: [{ type: core.Output }]
|
|
9897
10166
|
};
|
|
9898
10167
|
return CardWideV2Component;
|
|
9899
10168
|
}());
|
|
@@ -9913,6 +10182,8 @@
|
|
|
9913
10182
|
/** @type {?} */
|
|
9914
10183
|
CardWideV2Component.prototype.contentData;
|
|
9915
10184
|
/** @type {?} */
|
|
10185
|
+
CardWideV2Component.prototype.triggerTelemetry;
|
|
10186
|
+
/** @type {?} */
|
|
9916
10187
|
CardWideV2Component.prototype.isCardFlipped;
|
|
9917
10188
|
/** @type {?} */
|
|
9918
10189
|
CardWideV2Component.prototype.acbpConstants;
|
|
@@ -10028,7 +10299,6 @@
|
|
|
10028
10299
|
this.widgetData.content['bgColor'] = '#1a4ca1';
|
|
10029
10300
|
}
|
|
10030
10301
|
}
|
|
10031
|
-
console.log(this.widgetData.content, this.randomColorApply);
|
|
10032
10302
|
};
|
|
10033
10303
|
/**
|
|
10034
10304
|
* @return {?}
|
|
@@ -10069,7 +10339,7 @@
|
|
|
10069
10339
|
CardKarmaProgramsComponent.decorators = [
|
|
10070
10340
|
{ type: core.Component, args: [{
|
|
10071
10341
|
selector: 'sb-uic-card-karma-programs',
|
|
10072
|
-
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
|
|
10342
|
+
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>",
|
|
10073
10343
|
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}"]
|
|
10074
10344
|
}] }
|
|
10075
10345
|
];
|
|
@@ -10132,28 +10402,173 @@
|
|
|
10132
10402
|
* @fileoverview added by tsickle
|
|
10133
10403
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
10134
10404
|
*/
|
|
10135
|
-
var
|
|
10136
|
-
function
|
|
10405
|
+
var CardKarmaProgramsV2Component = /** @class */ (function () {
|
|
10406
|
+
function CardKarmaProgramsV2Component(events, translate, langtranslations, configSvc) {
|
|
10407
|
+
var _this = this;
|
|
10408
|
+
this.events = events;
|
|
10409
|
+
this.translate = translate;
|
|
10410
|
+
this.langtranslations = langtranslations;
|
|
10411
|
+
this.configSvc = configSvc;
|
|
10412
|
+
this.randomColorApply = false;
|
|
10413
|
+
this.userData = new core.EventEmitter();
|
|
10414
|
+
this.widgetType = '';
|
|
10415
|
+
this.widgetSubType = '';
|
|
10416
|
+
this.randomColors = [
|
|
10417
|
+
'#EF941D',
|
|
10418
|
+
'#F97440',
|
|
10419
|
+
'#35B5B0',
|
|
10420
|
+
'#9988FF',
|
|
10421
|
+
'#254092',
|
|
10422
|
+
'#926525',
|
|
10423
|
+
'#4F72DF'
|
|
10424
|
+
];
|
|
10425
|
+
this.langtranslations.languageSelectedObservable.subscribe((/**
|
|
10426
|
+
* @return {?}
|
|
10427
|
+
*/
|
|
10428
|
+
function () {
|
|
10429
|
+
if (localStorage.getItem('websiteLanguage')) {
|
|
10430
|
+
_this.translate.setDefaultLang('en');
|
|
10431
|
+
/** @type {?} */
|
|
10432
|
+
var lang = (/** @type {?} */ (localStorage.getItem('websiteLanguage')));
|
|
10433
|
+
_this.translate.use(lang);
|
|
10434
|
+
}
|
|
10435
|
+
}));
|
|
10137
10436
|
}
|
|
10138
10437
|
/**
|
|
10139
10438
|
* @return {?}
|
|
10140
10439
|
*/
|
|
10141
|
-
|
|
10440
|
+
CardKarmaProgramsV2Component.prototype.ngOnInit = /**
|
|
10142
10441
|
* @return {?}
|
|
10143
10442
|
*/
|
|
10144
10443
|
function () {
|
|
10444
|
+
/** @type {?} */
|
|
10445
|
+
var instanceConfig = this.configSvc.instanceConfig;
|
|
10446
|
+
if (instanceConfig) {
|
|
10447
|
+
this.defaultThumbnail = instanceConfig.logos.defaultContent || '';
|
|
10448
|
+
this.sourceLogos = instanceConfig.sources;
|
|
10449
|
+
this.defaultSLogo = instanceConfig.logos.defaultSourceLogo || '';
|
|
10450
|
+
}
|
|
10451
|
+
else {
|
|
10452
|
+
this.defaultThumbnail = '/assets/instances/eagle/app_logos/default.png';
|
|
10453
|
+
this.defaultSLogo = '/assets/instances/eagle/app_logos/KarmayogiBharat_Logo.svg';
|
|
10454
|
+
}
|
|
10455
|
+
this.setRandomColor();
|
|
10145
10456
|
};
|
|
10146
|
-
|
|
10457
|
+
/**
|
|
10458
|
+
* @return {?}
|
|
10459
|
+
*/
|
|
10460
|
+
CardKarmaProgramsV2Component.prototype.setRandomColor = /**
|
|
10461
|
+
* @return {?}
|
|
10462
|
+
*/
|
|
10463
|
+
function () {
|
|
10464
|
+
if (this.widgetData && this.widgetData.content) {
|
|
10465
|
+
if (this.randomColorApply) {
|
|
10466
|
+
/** @type {?} */
|
|
10467
|
+
var randomIndex1 = Math.floor(Math.random() * Math.floor(this.randomColors.length));
|
|
10468
|
+
this.widgetData.content['bgColor'] = this.randomColors[randomIndex1];
|
|
10469
|
+
}
|
|
10470
|
+
else {
|
|
10471
|
+
this.widgetData.content['bgColor'] = '#1a4ca1';
|
|
10472
|
+
}
|
|
10473
|
+
}
|
|
10474
|
+
};
|
|
10475
|
+
/**
|
|
10476
|
+
* @return {?}
|
|
10477
|
+
*/
|
|
10478
|
+
CardKarmaProgramsV2Component.prototype.raiseTelemetry = /**
|
|
10479
|
+
* @return {?}
|
|
10480
|
+
*/
|
|
10481
|
+
function () {
|
|
10482
|
+
// if(this.forPreview){
|
|
10483
|
+
// return
|
|
10484
|
+
// }
|
|
10485
|
+
this.events.raiseInteractTelemetry({
|
|
10486
|
+
type: 'click',
|
|
10487
|
+
subType: this.widgetType + "-" + this.widgetSubType,
|
|
10488
|
+
id: lodash.camelCase(this.widgetData.content.userId) + "-card",
|
|
10489
|
+
}, {
|
|
10490
|
+
id: this.widgetData.content.userId,
|
|
10491
|
+
// type: this.widgetData.user.primaryCategory,
|
|
10492
|
+
//context: this.widgetData.context,
|
|
10493
|
+
rollup: {},
|
|
10494
|
+
}, {
|
|
10495
|
+
pageIdExt: lodash.camelCase('user') + "-card",
|
|
10496
|
+
module: lodash.camelCase('user'),
|
|
10497
|
+
});
|
|
10498
|
+
};
|
|
10499
|
+
Object.defineProperty(CardKarmaProgramsV2Component.prototype, "getRandomColors", {
|
|
10500
|
+
get: /**
|
|
10501
|
+
* @return {?}
|
|
10502
|
+
*/
|
|
10503
|
+
function () {
|
|
10504
|
+
/** @type {?} */
|
|
10505
|
+
var randomIndex1 = Math.floor(Math.random() * Math.floor(this.randomColors.length));
|
|
10506
|
+
return this.randomColors[randomIndex1];
|
|
10507
|
+
},
|
|
10508
|
+
enumerable: true,
|
|
10509
|
+
configurable: true
|
|
10510
|
+
});
|
|
10511
|
+
CardKarmaProgramsV2Component.decorators = [
|
|
10147
10512
|
{ type: core.Component, args: [{
|
|
10148
|
-
selector: 'sb-uic-card-karma-
|
|
10149
|
-
template: "<
|
|
10150
|
-
styles: [""]
|
|
10513
|
+
selector: 'sb-uic-card-karma-programs-v2',
|
|
10514
|
+
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>",
|
|
10515
|
+
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}}"]
|
|
10151
10516
|
}] }
|
|
10152
10517
|
];
|
|
10153
10518
|
/** @nocollapse */
|
|
10154
|
-
|
|
10155
|
-
|
|
10519
|
+
CardKarmaProgramsV2Component.ctorParameters = function () { return [
|
|
10520
|
+
{ type: utilsV2.EventService },
|
|
10521
|
+
{ type: core$1.TranslateService },
|
|
10522
|
+
{ type: utilsV2.MultilingualTranslationsService },
|
|
10523
|
+
{ type: utilsV2.ConfigurationsService }
|
|
10524
|
+
]; };
|
|
10525
|
+
CardKarmaProgramsV2Component.propDecorators = {
|
|
10526
|
+
widgetData: [{ type: core.Input }],
|
|
10527
|
+
randomColorApply: [{ type: core.Input }],
|
|
10528
|
+
userData: [{ type: core.Output }]
|
|
10529
|
+
};
|
|
10530
|
+
return CardKarmaProgramsV2Component;
|
|
10156
10531
|
}());
|
|
10532
|
+
if (false) {
|
|
10533
|
+
/** @type {?} */
|
|
10534
|
+
CardKarmaProgramsV2Component.prototype.widgetData;
|
|
10535
|
+
/** @type {?} */
|
|
10536
|
+
CardKarmaProgramsV2Component.prototype.randomColorApply;
|
|
10537
|
+
/** @type {?} */
|
|
10538
|
+
CardKarmaProgramsV2Component.prototype.userData;
|
|
10539
|
+
/** @type {?} */
|
|
10540
|
+
CardKarmaProgramsV2Component.prototype.defaultThumbnail;
|
|
10541
|
+
/** @type {?} */
|
|
10542
|
+
CardKarmaProgramsV2Component.prototype.sourceLogos;
|
|
10543
|
+
/** @type {?} */
|
|
10544
|
+
CardKarmaProgramsV2Component.prototype.defaultSLogo;
|
|
10545
|
+
/** @type {?} */
|
|
10546
|
+
CardKarmaProgramsV2Component.prototype.widgetType;
|
|
10547
|
+
/** @type {?} */
|
|
10548
|
+
CardKarmaProgramsV2Component.prototype.widgetSubType;
|
|
10549
|
+
/** @type {?} */
|
|
10550
|
+
CardKarmaProgramsV2Component.prototype.randomColors;
|
|
10551
|
+
/**
|
|
10552
|
+
* @type {?}
|
|
10553
|
+
* @private
|
|
10554
|
+
*/
|
|
10555
|
+
CardKarmaProgramsV2Component.prototype.events;
|
|
10556
|
+
/**
|
|
10557
|
+
* @type {?}
|
|
10558
|
+
* @private
|
|
10559
|
+
*/
|
|
10560
|
+
CardKarmaProgramsV2Component.prototype.translate;
|
|
10561
|
+
/**
|
|
10562
|
+
* @type {?}
|
|
10563
|
+
* @private
|
|
10564
|
+
*/
|
|
10565
|
+
CardKarmaProgramsV2Component.prototype.langtranslations;
|
|
10566
|
+
/**
|
|
10567
|
+
* @type {?}
|
|
10568
|
+
* @private
|
|
10569
|
+
*/
|
|
10570
|
+
CardKarmaProgramsV2Component.prototype.configSvc;
|
|
10571
|
+
}
|
|
10157
10572
|
|
|
10158
10573
|
/**
|
|
10159
10574
|
* @fileoverview added by tsickle
|
|
@@ -10173,7 +10588,7 @@
|
|
|
10173
10588
|
CardMDOChannelComponent,
|
|
10174
10589
|
CardWideV2Component,
|
|
10175
10590
|
CardKarmaProgramsComponent,
|
|
10176
|
-
|
|
10591
|
+
CardKarmaProgramsV2Component
|
|
10177
10592
|
],
|
|
10178
10593
|
imports: [
|
|
10179
10594
|
common.CommonModule,
|
|
@@ -10198,7 +10613,8 @@
|
|
|
10198
10613
|
CardWideComponent,
|
|
10199
10614
|
CardMDOChannelComponent,
|
|
10200
10615
|
CardWideV2Component,
|
|
10201
|
-
CardKarmaProgramsComponent
|
|
10616
|
+
CardKarmaProgramsComponent,
|
|
10617
|
+
CardKarmaProgramsV2Component
|
|
10202
10618
|
],
|
|
10203
10619
|
},] }
|
|
10204
10620
|
];
|
|
@@ -10293,6 +10709,7 @@
|
|
|
10293
10709
|
this.cardDisplayCount = 3;
|
|
10294
10710
|
this.dynamicAlignPills = 'center';
|
|
10295
10711
|
this.emptyResponse = new core.EventEmitter();
|
|
10712
|
+
this.temeletryResponse = new core.EventEmitter();
|
|
10296
10713
|
this.loadCometency = false;
|
|
10297
10714
|
this.loadCompetencyArea = false;
|
|
10298
10715
|
this.competencyVersion = '';
|
|
@@ -10472,6 +10889,7 @@
|
|
|
10472
10889
|
],
|
|
10473
10890
|
};
|
|
10474
10891
|
}
|
|
10892
|
+
this.temeletryResponse.emit(e.name);
|
|
10475
10893
|
this.getcompetencyTheme(e.name, addfilter);
|
|
10476
10894
|
this.selectedValue = e.name;
|
|
10477
10895
|
};
|
|
@@ -10633,6 +11051,7 @@
|
|
|
10633
11051
|
this.showAllTheme[0]['showAll'] = !event.showAll;
|
|
10634
11052
|
this.competencyThemeLength = event.showAll ? this.competencyTheme.length : 6;
|
|
10635
11053
|
this.showAllTheme[0]['name'] = event.showAll ? 'Show less' : 'Show all';
|
|
11054
|
+
this.temeletryResponse.emit(event.name);
|
|
10636
11055
|
};
|
|
10637
11056
|
/**
|
|
10638
11057
|
* @param {?} compData
|
|
@@ -10666,7 +11085,8 @@
|
|
|
10666
11085
|
dynamicClass: [{ type: core.Input }],
|
|
10667
11086
|
dynamicColor: [{ type: core.Input }],
|
|
10668
11087
|
dynamicAlignPills: [{ type: core.Input }],
|
|
10669
|
-
emptyResponse: [{ type: core.Output }]
|
|
11088
|
+
emptyResponse: [{ type: core.Output }],
|
|
11089
|
+
temeletryResponse: [{ type: core.Output }]
|
|
10670
11090
|
};
|
|
10671
11091
|
return CompetencyPassbookComponent;
|
|
10672
11092
|
}());
|
|
@@ -10686,6 +11106,8 @@
|
|
|
10686
11106
|
/** @type {?} */
|
|
10687
11107
|
CompetencyPassbookComponent.prototype.emptyResponse;
|
|
10688
11108
|
/** @type {?} */
|
|
11109
|
+
CompetencyPassbookComponent.prototype.temeletryResponse;
|
|
11110
|
+
/** @type {?} */
|
|
10689
11111
|
CompetencyPassbookComponent.prototype.loadCometency;
|
|
10690
11112
|
/** @type {?} */
|
|
10691
11113
|
CompetencyPassbookComponent.prototype.loadCompetencyArea;
|
|
@@ -11837,7 +12259,7 @@
|
|
|
11837
12259
|
exports.ɵb = WidgetUserService;
|
|
11838
12260
|
exports.ɵba = CardWideV2Component;
|
|
11839
12261
|
exports.ɵbb = CardKarmaProgramsComponent;
|
|
11840
|
-
exports.ɵbc =
|
|
12262
|
+
exports.ɵbc = CardKarmaProgramsV2Component;
|
|
11841
12263
|
exports.ɵbd = PipePublicURLModule;
|
|
11842
12264
|
exports.ɵbe = PipePublicURL;
|
|
11843
12265
|
exports.ɵbf = DisplayContentTypeLibModule;
|