feat: show channel logos in the list

This commit closes #28
This commit is contained in:
4gray committed 2021-04-02 11:01:18 +02:00
1 parent 99f6fd85d2
commit 41998ff7a0
2 files changed
+32 -4

No files matched your search

@@ -33,7 +33,13 @@
[class.active]="selected?.id === channel.id"
(click)="selectChannel(channel)"
>
<p matLine>
<img
[src]="channel.tvg.logo"
*ngIf="channel.tvg.logo"
width="48"
onerror="this.style.display='none'"
/>
<p matLine class="channel-name">
{{
i + 1 + '. ' + channel?.name ||
('CHANNELS.UNNAMED_CHANNEL' | translate)
@@ -65,7 +71,13 @@
[class.active]="selected?.id === channel.id"
(click)="selectChannel(channel)"
>
<p matLine>
<img
[src]="channel.tvg.logo"
*ngIf="channel.tvg.logo"
width="48"
onerror="this.style.display='none'"
/>
<p matLine class="channel-name">
{{
i + 1 + '. ' + channel?.name ||
('CHANNELS.UNNAMED_CHANNEL'
@@ -95,7 +107,13 @@
[class.active]="selected?.id === channel.id"
(click)="selectChannel(channel)"
>
<p matLine>
<img
[src]="channel.tvg.logo"
*ngIf="channel.tvg.logo"
width="48"
onerror="this.style.display='none'"
/>
<p matLine class="channel-name">
{{
i + 1 + '. ' + channel?.name ||
('CHANNELS.UNNAMED_CHANNEL' | translate)
@@ -107,7 +125,7 @@
[matTooltip]="'CHANNELS.REMOVE_FAVORITE' | translate"
(click)="toggleFavoriteChannel(channel, $event)"
>
<mat-icon>star</mat-icon>
<mat-icon color="accent">star</mat-icon>
</button>
<mat-divider></mat-divider>
</mat-list-item>
@@ -53,3 +53,13 @@
margin: 5px !important;
}
}
.channel-name {
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
font-size: 0.9em;
width: 290px;
}