minor changes / disabled sidebar toggle on hover
This commit is contained in:
1 parent
33870be352
commit
317ad928ea
4 files changed
+12
-14
No files matched your search
@@ -16,11 +16,11 @@ export class SidebarComponent implements AfterViewInit {
|
|||||||
) {}
|
) {}
|
||||||
|
|
||||||
onMouseEnter() {
|
onMouseEnter() {
|
||||||
this.toggleService.hoverSidebar(true);
|
// this.toggleService.hoverSidebar(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
onMouseLeave() {
|
onMouseLeave() {
|
||||||
this.toggleService.hoverSidebar(false);
|
// this.toggleService.hoverSidebar(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
ngAfterViewInit() {
|
ngAfterViewInit() {
|
||||||
|
|||||||
@@ -19,14 +19,14 @@ export class ToggleService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
hoverSidebar(isHovering: boolean) {
|
// hoverSidebar(isHovering: boolean) {
|
||||||
if (isHovering) {
|
// if (isHovering) {
|
||||||
document.body.classList.add('sidebar-hovered');
|
// document.body.classList.add('sidebar-hovered');
|
||||||
isHovering = true;
|
// isHovering = true;
|
||||||
} else {
|
// } else {
|
||||||
document.body.classList.remove('sidebar-hovered');
|
// document.body.classList.remove('sidebar-hovered');
|
||||||
isHovering = false;
|
// isHovering = false;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
<a href="javascript:;">
|
<a href="javascript:;">
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li class="breadcrumb-item active" aria-current="page">Trending</li>
|
<li class="breadcrumb-item active" aria-current="page">Popular</li>
|
||||||
</ol>
|
</ol>
|
||||||
</nav>
|
</nav>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -23,10 +23,8 @@ export class EntryListComponent implements OnInit {
|
|||||||
fetchMovies() {
|
fetchMovies() {
|
||||||
if (this.type == 'popular') {
|
if (this.type == 'popular') {
|
||||||
if (this.pages[this.currentPage]) {
|
if (this.pages[this.currentPage]) {
|
||||||
console.log('page existe deja');
|
|
||||||
this.entries = this.pages[this.currentPage];
|
this.entries = this.pages[this.currentPage];
|
||||||
} else {
|
} else {
|
||||||
console.log("page n'existe pas");
|
|
||||||
this.tmdbService
|
this.tmdbService
|
||||||
.getPopular(this.currentPage, this.isMovies)
|
.getPopular(this.currentPage, this.isMovies)
|
||||||
.subscribe((myEntries) => {
|
.subscribe((myEntries) => {
|
||||||
|
|||||||
Reference in new issue
Block a user