Introduce a new eBook reader with support for EPUB, MOBI, AZW3, and FB2 formats (#2258)
Co-authored-by: acx10 <acx10@users.noreply.github.com>
This commit is contained in:
+6
-1
@@ -24,7 +24,12 @@
|
||||
[horizontal]="true">
|
||||
@for (book of books; track book.id) {
|
||||
<div class="dashboard-scroller-card" [class.menu-open]="openMenuBookId === book.id">
|
||||
<app-book-card [book]="book" [isCheckboxEnabled]="false" (menuToggled)="handleMenuToggle(book.id, $event)"></app-book-card>
|
||||
<app-book-card
|
||||
[book]="book"
|
||||
[isCheckboxEnabled]="false"
|
||||
(menuToggled)="handleMenuToggle(book.id, $event)"
|
||||
[overlayPreferenceService]="bookCardOverlayPreferenceService"
|
||||
></app-book-card>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
|
||||
+4
-1
@@ -1,10 +1,11 @@
|
||||
import {Component, ElementRef, Input, ViewChild} from '@angular/core';
|
||||
import {Component, ElementRef, Input, ViewChild, inject} from '@angular/core';
|
||||
import {BookCardComponent} from '../../../book/components/book-browser/book-card/book-card.component';
|
||||
import {InfiniteScrollDirective} from 'ngx-infinite-scroll';
|
||||
|
||||
import {ProgressSpinnerModule} from 'primeng/progressspinner';
|
||||
import {Book} from '../../../book/model/book.model';
|
||||
import {ScrollerType} from '../../models/dashboard-config.model';
|
||||
import { BookCardOverlayPreferenceService } from '../../../book/components/book-browser/book-card-overlay-preference.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-dashboard-scroller',
|
||||
@@ -27,6 +28,8 @@ export class DashboardScrollerComponent {
|
||||
@ViewChild('scrollContainer') scrollContainer!: ElementRef;
|
||||
openMenuBookId: number | null = null;
|
||||
|
||||
public bookCardOverlayPreferenceService = inject(BookCardOverlayPreferenceService);
|
||||
|
||||
handleMenuToggle(bookId: number, isOpen: boolean) {
|
||||
this.openMenuBookId = isOpen ? bookId : null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user