mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-21 05:43:19 -07:00
fix(discover): Display 'partly available' status on TV show discover card
[no ci]
This commit is contained in:
commit
9033f1d548
3 changed files with 14 additions and 12 deletions
|
@ -6,7 +6,7 @@
|
||||||
{{ 'Common.' + RequestType[result.type] | translate }}
|
{{ 'Common.' + RequestType[result.type] | translate }}
|
||||||
</div>
|
</div>
|
||||||
<div class="{{getStatusClass()}} top-right" id="status{{result.id}}">
|
<div class="{{getStatusClass()}} top-right" id="status{{result.id}}">
|
||||||
<span class="indicator"></span><span class="indicator-text" id="availabilityStatus{{result.id}}">{{getAvailbilityStatus()}}</span>
|
<span class="indicator"></span><span class="indicator-text" id="availabilityStatus{{result.id}}">{{getAvailabilityStatus()}}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<img [routerLink]="generateDetailsLink()" id="cardImage" src="{{result.posterPath}}" class="image"
|
<img [routerLink]="generateDetailsLink()" id="cardImage" src="{{result.posterPath}}" class="image"
|
||||||
|
|
|
@ -201,30 +201,26 @@ small {
|
||||||
margin-right:5px;
|
margin-right:5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.top-right.available span.indicator, span.indicator-text{
|
.top-right span.indicator, span.indicator-text{
|
||||||
display:block;
|
display:block;
|
||||||
}
|
}
|
||||||
|
.top-right span.indicator:before{
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
.top-right.available span.indicator:before{
|
.top-right.available span.indicator:before{
|
||||||
display: inline-block;
|
|
||||||
background-color: #1DE9B6;
|
background-color: #1DE9B6;
|
||||||
}
|
}
|
||||||
|
|
||||||
.top-right.approved span.indicator, span.indicator-text {
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.top-right.approved span.indicator:before{
|
.top-right.approved span.indicator:before{
|
||||||
display: inline-block;
|
|
||||||
background-color: #ff5722;
|
background-color: #ff5722;
|
||||||
}
|
}
|
||||||
|
|
||||||
.top-right.requested span.indicator, span.indicator-text {
|
.top-right.partly-available span.indicator:before{
|
||||||
display: block;
|
background-color: #ffd740;
|
||||||
}
|
}
|
||||||
|
|
||||||
.top-right.requested span.indicator:before{
|
.top-right.requested span.indicator:before{
|
||||||
display: inline-block;
|
|
||||||
background-color: #ffd740;
|
background-color: #ffd740;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -92,6 +92,9 @@ export class DiscoverCardComponent implements OnInit {
|
||||||
if (this.result.available) {
|
if (this.result.available) {
|
||||||
return "available";
|
return "available";
|
||||||
}
|
}
|
||||||
|
if (this.tvSearchResult?.partlyAvailable) {
|
||||||
|
return "partly-available";
|
||||||
|
}
|
||||||
if (this.result.approved) {
|
if (this.result.approved) {
|
||||||
return "approved";
|
return "approved";
|
||||||
}
|
}
|
||||||
|
@ -101,10 +104,13 @@ export class DiscoverCardComponent implements OnInit {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
|
|
||||||
public getAvailbilityStatus(): string {
|
public getAvailabilityStatus(): string {
|
||||||
if (this.result.available) {
|
if (this.result.available) {
|
||||||
return this.translate.instant("Common.Available");
|
return this.translate.instant("Common.Available");
|
||||||
}
|
}
|
||||||
|
if (this.tvSearchResult?.partlyAvailable) {
|
||||||
|
return this.translate.instant("Common.PartlyAvailable");
|
||||||
|
}
|
||||||
if (this.result.approved) {
|
if (this.result.approved) {
|
||||||
return this.translate.instant("Common.Approved");
|
return this.translate.instant("Common.Approved");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue