From a539653f4e77552fa544e5dd4a4fcad712af53d6 Mon Sep 17 00:00:00 2001
From: Ajoymaity <ajoy.maity@tarento.com>
Date: Wed, 16 Feb 2022 12:00:02 +0530
Subject: [PATCH] Issue #SB-28602 fix: Fixed content card ribbon title

---
 projects/common-consumption/package.json                    | 2 +-
 .../lib/card/library-card-v2/library-card-v2.component.html | 2 +-
 .../lib/card/library-card-v2/library-card-v2.component.ts   | 6 ------
 3 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/projects/common-consumption/package.json b/projects/common-consumption/package.json
index 81da235e..02102a6c 100644
--- a/projects/common-consumption/package.json
+++ b/projects/common-consumption/package.json
@@ -1,6 +1,6 @@
 {
     "name": "@project-sunbird/common-consumption-v9",
-    "version": "4.7.0",
+    "version": "4.7.1",
     "repository": {
         "type": "git",
         "url": "git+https://github.com/Sunbird-Ed/SunbirdEd-consumption-ngcomponents.git"
diff --git a/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.html b/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.html
index 864946d1..173b2598 100644
--- a/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.html
+++ b/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.html
@@ -26,7 +26,7 @@
     <div class="sb--card__svg-area">
       <img [src]="svgToDisplay" alt=""/>
     </div>
-    <div class="sb--card__type" *ngIf="content?.contentType">{{cardType}}</div>
+    <div class="sb--card__type" *ngIf="content?.primaryCategory">{{content?.primaryCategory}}</div>
   </div>
 
   <!-- card mobile view details -->
diff --git a/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.ts b/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.ts
index 0f3a280e..97d715e2 100644
--- a/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.ts
+++ b/projects/common-consumption/src/lib/card/library-card-v2/library-card-v2.component.ts
@@ -28,16 +28,10 @@ export class LibraryCardV2Component implements OnInit, AfterViewInit {
 
     @Output() cardClick: EventEmitter<ICardClick> = new EventEmitter();
     @Output() menuClick: EventEmitter<ICardClick> = new EventEmitter();
-    cardType = '';
 
     get LibraryCardTypes() { return LibraryCardTypes; }
 
     ngOnInit() {
-        this.cardType = this.content.contentType;
-        if (this.content.primaryCategory && this.content.primaryCategory.toLowerCase() !== 'course' &&
-         this.content.trackable && this.content.trackable.enabled === 'Yes') {
-            this.cardType = 'Digital Textbook';
-        }
         this.fetchSvg();
         this.splitGradeMedium();
     }
-- 
GitLab