added trending page component
This commit is contained in:
1 parent
e43b9b58d1
commit
905fd87b43
4 files changed
+68
No files matched your search
Whitespace-only changes.
@@ -0,0 +1,29 @@
|
|||||||
|
<!--breadcrumb-->
|
||||||
|
<div class="page-breadcrumb d-none d-sm-flex align-items-center mb-3">
|
||||||
|
<div class="breadcrumb-title pe-3">Discover</div>
|
||||||
|
<div class="ps-3">
|
||||||
|
<nav aria-label="breadcrumb">
|
||||||
|
<ol class="breadcrumb mb-0 p-0">
|
||||||
|
<li class="breadcrumb-item">
|
||||||
|
<a href="javascript:;">
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class="breadcrumb-item active" aria-current="page">Trending</li>
|
||||||
|
</ol>
|
||||||
|
</nav>
|
||||||
|
</div>
|
||||||
|
<div class="ms-auto">
|
||||||
|
<div class="btn-group">
|
||||||
|
<button type="button" class="btn btn-outline-dark" [class.active]="activeComponent === true"
|
||||||
|
(click)="showComponent(true)">Movies</button>
|
||||||
|
|
||||||
|
<button type="button" class="btn btn-outline-dark" [class.active]="activeComponent === false"
|
||||||
|
(click)="showComponent(false)">TV-Series</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!--end breadcrumb-->
|
||||||
|
|
||||||
|
|
||||||
|
<app-entry-list *ngIf="activeComponent === true" [isMovies]="true" [type]="'trending'"></app-entry-list>
|
||||||
|
<app-entry-list *ngIf="activeComponent === false" [isMovies]="false" [type]="'trending'"></app-entry-list>
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
||||||
|
|
||||||
|
import { TrendingComponent } from './trending.component';
|
||||||
|
|
||||||
|
describe('TrendingComponent', () => {
|
||||||
|
let component: TrendingComponent;
|
||||||
|
let fixture: ComponentFixture<TrendingComponent>;
|
||||||
|
|
||||||
|
beforeEach(() => {
|
||||||
|
TestBed.configureTestingModule({
|
||||||
|
declarations: [TrendingComponent]
|
||||||
|
});
|
||||||
|
fixture = TestBed.createComponent(TrendingComponent);
|
||||||
|
component = fixture.componentInstance;
|
||||||
|
fixture.detectChanges();
|
||||||
|
});
|
||||||
|
|
||||||
|
it('should create', () => {
|
||||||
|
expect(component).toBeTruthy();
|
||||||
|
});
|
||||||
|
});
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
import { Component } from '@angular/core';
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'app-trending',
|
||||||
|
templateUrl: './trending.component.html',
|
||||||
|
styleUrls: ['./trending.component.css'],
|
||||||
|
})
|
||||||
|
export class TrendingComponent {
|
||||||
|
activeComponent: boolean = true;
|
||||||
|
|
||||||
|
showComponent(activeComponent: boolean) {
|
||||||
|
this.activeComponent = activeComponent;
|
||||||
|
}
|
||||||
|
|
||||||
|
getEndPoint(): string {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in new issue
Block a user