mirror of
https://github.com/Kareadita/Kavita.git
synced 2025-07-09 03:04:19 -04:00
Fixed a bug where companion bar would be pushing content to the right even when not visible. Updated nav service localstorage key. (#1159)
This commit is contained in:
parent
b1c4b2863c
commit
3a9d6b1a08
@ -5,7 +5,7 @@ import { ReplaySubject, take } from 'rxjs';
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class NavService {
|
||||
public localStorageSideNavKey = 'kavita--sidenav--collapsed';
|
||||
public localStorageSideNavKey = 'kavita--sidenav--expanded';
|
||||
|
||||
private navbarVisibleSource = new ReplaySubject<boolean>(1);
|
||||
/**
|
||||
|
@ -3,8 +3,14 @@
|
||||
<a id="content"></a>
|
||||
<app-side-nav *ngIf="navService.sideNavVisibility$ | async"></app-side-nav>
|
||||
<div class="container-fluid" style="padding-top: 10px; padding-bottom: 10px;">
|
||||
<div class="companion-bar" [ngClass]="{'companion-bar-content': (navService?.sideNavCollapsed$ | async)}">
|
||||
<ng-container *ngIf="navService.sideNavVisibility$ | async else noSideNav">
|
||||
<div class="companion-bar" [ngClass]="{'companion-bar-content': (navService?.sideNavCollapsed$ | async)}">
|
||||
<router-outlet></router-outlet>
|
||||
</div>
|
||||
</ng-container>
|
||||
<ng-template #noSideNav>
|
||||
<router-outlet></router-outlet>
|
||||
</div>
|
||||
</ng-template>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
@ -431,9 +431,9 @@ export class MangaReaderComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||
this.navService.showSideNav();
|
||||
this.onDestroy.next();
|
||||
this.onDestroy.complete();
|
||||
this.goToPageEvent.complete();
|
||||
this.showBookmarkEffectEvent.complete();
|
||||
this.readerService.exitFullscreen();
|
||||
if (this.goToPageEvent !== undefined) this.goToPageEvent.complete();
|
||||
}
|
||||
|
||||
@HostListener('window:keyup', ['$event'])
|
||||
|
Loading…
x
Reference in New Issue
Block a user