Commit 621496c3 authored by Juan Manuel Solaro's avatar Juan Manuel Solaro

(fix) "See More" will be displayed only if there is more content

1 merge request!459WIP: (feat): Minds Pro
Pipeline #74802784 running with stages
......@@ -46,7 +46,7 @@
</ng-container>
<li
class="m-proChannelListContentList__seeMore"
*ngIf="entities.length != 0"
*ngIf="entities && displaySeeMoreTile"
[routerLink]="seeMoreRoute"
i18n
>
......
......@@ -24,6 +24,8 @@ export class ProChannelListComponent implements OnInit, OnDestroy {
period: string;
displaySeeMoreTile: boolean = false;
constructor(
public feedsService: FeedsService,
protected channelService: ProChannelService,
......@@ -75,6 +77,12 @@ export class ProChannelListComponent implements OnInit, OnDestroy {
if (entity)
this.entities.push(await entity.pipe(first()).toPromise());
}
if (this.entities.length >= 9) {
this.displaySeeMoreTile = true;
this.entities = this.entities.slice(0,8);
}
this.detectChanges();
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment