Optimizing TV details page

pull/4043/head
twanariens 4 years ago
parent 5649c18bf5
commit dd94784642

@ -1,63 +1,68 @@
<div> <div class="left-panel-details">
<span *ngIf="tv.rating"> <div>
<img style="width: 4em;" src="{{baseUrl}}/images/tvm-logo.png"> {{tv.rating}}/10 <div class="rating medium-font">
</span> <span *ngIf="tv.rating">
<span *ngIf="ratings?.score && ratings?.class"> <img class="rating-small" src="{{baseUrl}}/images/tvm-logo.png"> {{tv.rating}}/10
<img class="rating-small" src="{{baseUrl}}/images/{{ratings.class === 'rotten' ? 'rotten-rotten.svg' : 'rotten-fresh.svg'}}"> {{ratings.score}}% </span>
</span> <span *ngIf="ratings?.score && ratings?.class">
<img class="rating-small" src="{{baseUrl}}/images/{{ratings.class === 'rotten' ? 'rotten-rotten.svg' : 'rotten-fresh.svg'}}"> {{ratings.score}}%
<div *ngIf="streams?.length > 0"> </span>
</div>
<div *ngIf="streams?.length > 0" class="streaming-on-container">
<hr>
<div class="streaming-on-content">
<span class="label">{{'MediaDetails.StreamingOn' | translate }}:</span>
<div>
<span *ngFor="let stream of streams">
<img class="stream-small" [matTooltip]="stream.streamingProvider" src="https://image.tmdb.org/t/p/original{{stream.logo}}">
</span>
</div>
</div>
</div>
<hr> <hr>
<strong>{{'MediaDetails.StreamingOn' | translate }}:</strong> <div *ngIf="tv.status">
<div> <span class="label">{{'MediaDetails.Status' | translate }}:</span>
<span *ngFor="let stream of streams"> {{tv.status}}
<img class="stream-small" [matTooltip]="stream.streamingProvider" src="https://image.tmdb.org/t/p/original{{stream.logo}}">
</span>
</div> </div>
<span class="label">First Aired:</span>
{{tv.firstAired | date: 'mediumDate'}}
</div> </div>
<hr>
<div *ngIf="tv.status">
<strong>{{'MediaDetails.Status' | translate }}:</strong>
{{tv.status}}
</div>
<strong>First Aired:</strong>
{{tv.firstAired | date: 'mediumDate'}}
</div>
<div *ngIf="seasonCount"> <div *ngIf="seasonCount">
<strong>Seasons:</strong> <span class="label">Seasons:</span>
{{seasonCount}} {{seasonCount}}
</div> </div>
<div *ngIf="totalEpisodes"> <div *ngIf="totalEpisodes">
<strong>Episodes:</strong> <span class="label">Episodes:</span>
{{totalEpisodes}} {{totalEpisodes}}
</div> </div>
<div *ngIf="advancedOptions && request?.rootPathOverrideTitle"> <div *ngIf="advancedOptions && request?.rootPathOverrideTitle">
<strong>{{'MediaDetails.RootFolderOverride' | translate }}:</strong> <span class="label">{{'MediaDetails.RootFolderOverride' | translate }}:</span>
<div>{{request.rootPathOverrideTitle}}</div> <div>{{request.rootPathOverrideTitle}}</div>
</div> </div>
<div *ngIf="advancedOptions && request?.qualityOverrideTitle"> <div *ngIf="advancedOptions && request?.qualityOverrideTitle">
<strong>{{'MediaDetails.QualityOverride' | translate }}:</strong> <span class="label">{{'MediaDetails.QualityOverride' | translate }}:</span>
<div>{{request.qualityOverrideTitle}}</div> <div>{{request.qualityOverrideTitle}}</div>
</div> </div>
<div> <div>
<strong>{{'MediaDetails.Runtime' | translate }}:</strong> <span class="label">{{'MediaDetails.Runtime' | translate }}:</span>
{{'MediaDetails.Minutes' | translate:{ runtime: tv.runtime} }} {{'MediaDetails.Minutes' | translate:{ runtime: tv.runtime} }}
</div> </div>
<div *ngIf="tv.network"> <div *ngIf="tv.network">
<strong>Network:</strong> <span class="label">Network:</span>
{{tv.network.name}} {{tv.network.name}}
</div> </div>
<div *ngIf="tv.genre"> <div *ngIf="tv.genre">
<strong>{{'MediaDetails.Genres' | translate }}:</strong> <span class="label">{{'MediaDetails.Genres' | translate }}:</span>
<div> <div>
<span *ngFor="let genre of tv.genre"> <span *ngFor="let genre of tv.genre">
{{genre}} | {{genre}} |
</span> </span>
</div>
</div> </div>
</div> </div>

@ -67,8 +67,8 @@
<div class="row"> <div class="row">
<div class="col-12 col-md-2"> <div class="col-12 col-md-2">
<mat-card class="mat-elevation-z8"> <mat-card class="mat-elevation-z8 spacing-below">
<mat-card-content class="medium-font"> <mat-card-content>
<tv-information-panel [tv]="tv" [request]="showRequest" <tv-information-panel [tv]="tv" [request]="showRequest"
[advancedOptions]="showAdvanced"></tv-information-panel> [advancedOptions]="showAdvanced"></tv-information-panel>
</mat-card-content> </mat-card-content>

@ -288,6 +288,18 @@
font-weight:500; font-weight:500;
} }
.left-panel-details .streaming-on-content{
display:flex;
justify-content: center;
align-items: center;
flex-flow:row wrap;
}
.left-panel-details .streaming-on-content .label{
white-space:nowrap;
padding-right:10px;
}
.left-panel-details{ .left-panel-details{
font-weight:100; font-weight:100;
} }
@ -314,6 +326,11 @@
padding:2px 1.5em;; padding:2px 1.5em;;
width:170px; width:170px;
margin-top:10px; margin-top:10px;
margin-left:10px;
}
.media-row .mat-raised-button:first-child{
margin-left:0px;
} }
@media (max-width:500px){ @media (max-width:500px){

Loading…
Cancel
Save