@sunbird-cb/utils-v2 0.0.7 → 0.0.9
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-utils-v2.umd.js +24 -7
- package/bundles/sunbird-cb-utils-v2.umd.js.map +1 -1
- package/bundles/sunbird-cb-utils-v2.umd.min.js +1 -1
- package/bundles/sunbird-cb-utils-v2.umd.min.js.map +1 -1
- package/esm2015/lib/pipes/pipe-certificate-image-URL/pipe-certimage-URL.pipe.js +24 -7
- package/esm2015/lib/pipes/pipe-public-URL/pipe-public-URL.pipe.js +2 -2
- package/esm5/lib/pipes/pipe-certificate-image-URL/pipe-certimage-URL.pipe.js +24 -7
- package/esm5/lib/pipes/pipe-public-URL/pipe-public-URL.pipe.js +2 -2
- package/fesm2015/sunbird-cb-utils-v2.js +24 -7
- package/fesm2015/sunbird-cb-utils-v2.js.map +1 -1
- package/fesm5/sunbird-cb-utils-v2.js +24 -7
- package/fesm5/sunbird-cb-utils-v2.js.map +1 -1
- package/package.json +1 -1
|
@@ -3954,7 +3954,7 @@ var PipePublicURL = (function () {
|
|
|
3954
3954
|
this.environment = environment;
|
|
3955
3955
|
}
|
|
3956
3956
|
PipePublicURL.prototype.transform = function (value) {
|
|
3957
|
-
if (value.includes('karmayogi')) {
|
|
3957
|
+
if (value && value.includes('karmayogi')) {
|
|
3958
3958
|
var mainUrl = value && value.split('/content').pop() || '';
|
|
3959
3959
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + "/content" + mainUrl;
|
|
3960
3960
|
return value ? finalURL : '';
|
|
@@ -4018,13 +4018,13 @@ var PipeCertificateImageURL = (function () {
|
|
|
4018
4018
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4019
4019
|
return value ? finalURL : '';
|
|
4020
4020
|
}
|
|
4021
|
-
if (value.indexOf('/
|
|
4022
|
-
var mainUrl = value && value.split('/
|
|
4021
|
+
if (value.indexOf('/igotuat/collection') > -1) {
|
|
4022
|
+
var mainUrl = value && value.split('/igotuat').pop() || '';
|
|
4023
4023
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4024
4024
|
return value ? finalURL : '';
|
|
4025
4025
|
}
|
|
4026
|
-
if (value.indexOf('/
|
|
4027
|
-
var mainUrl = value && value.split('/
|
|
4026
|
+
if (value.indexOf('/igotuat/content') > -1) {
|
|
4027
|
+
var mainUrl = value && value.split('/igotuat').pop() || '';
|
|
4028
4028
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4029
4029
|
return value ? finalURL : '';
|
|
4030
4030
|
}
|
|
@@ -4048,8 +4048,8 @@ var PipeCertificateImageURL = (function () {
|
|
|
4048
4048
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4049
4049
|
return value ? finalURL : '';
|
|
4050
4050
|
}
|
|
4051
|
-
if (value.indexOf('/
|
|
4052
|
-
var mainUrl = value && value.split('/
|
|
4051
|
+
if (value.indexOf('/igotuat/profileImage') > -1) {
|
|
4052
|
+
var mainUrl = value && value.split('/igotuat').pop() || '';
|
|
4053
4053
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4054
4054
|
return value ? finalURL : '';
|
|
4055
4055
|
}
|
|
@@ -4068,6 +4068,23 @@ var PipeCertificateImageURL = (function () {
|
|
|
4068
4068
|
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4069
4069
|
return value ? finalURL : '';
|
|
4070
4070
|
}
|
|
4071
|
+
if (this.environment && this.environment.bucketName) {
|
|
4072
|
+
if (value.indexOf("/" + this.environment.bucketName + "/profileImage") > -1) {
|
|
4073
|
+
var mainUrl = value && value.split("/" + this.environment.bucketName).pop() || '';
|
|
4074
|
+
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4075
|
+
return value ? finalURL : '';
|
|
4076
|
+
}
|
|
4077
|
+
if (value.indexOf("/" + this.environment.bucketName + "/content") > -1) {
|
|
4078
|
+
var mainUrl = value && value.split("/" + this.environment.bucketName).pop() || '';
|
|
4079
|
+
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4080
|
+
return value ? finalURL : '';
|
|
4081
|
+
}
|
|
4082
|
+
if (value.indexOf("/" + this.environment.bucketName + "/collection") > -1) {
|
|
4083
|
+
var mainUrl = value && value.split("/" + this.environment.bucketName).pop() || '';
|
|
4084
|
+
var finalURL = this.environment.contentHost + "/" + this.environment.contentBucket + mainUrl;
|
|
4085
|
+
return value ? finalURL : '';
|
|
4086
|
+
}
|
|
4087
|
+
}
|
|
4071
4088
|
}
|
|
4072
4089
|
};
|
|
4073
4090
|
PipeCertificateImageURL.decorators = [
|