Implement public review fetching from metadata providers

This commit is contained in:
aditya.chandel
2025-08-13 13:02:53 -06:00
committed by Aditya Chandel
parent 22b2c013bd
commit c660497e0b
50 changed files with 2612 additions and 286 deletions
@@ -1,9 +1,4 @@
<div class="book-card"
tooltipPosition="bottom"
autoHide="false"
tooltipStyleClass="text-xs text-center"
[pTooltip]="book.metadata?.title"
[class.selected]="isSelected"
(mouseover)="isHovered = true"
(mouseout)="isHovered = false">
@@ -36,17 +31,9 @@
</div>
}
<p-button
tooltipPosition="top"
tooltipStyleClass="text-xs text-center"
pTooltip="Open Book Info"
[rounded]="true" icon="pi pi-info" class="info-btn" (click)="openBookInfo(book)"></p-button>
<p-button [rounded]="true" icon="pi pi-info" class="info-btn" (click)="openBookInfo(book)"></p-button>
<p-button
tooltipPosition="top"
tooltipStyleClass="text-xs text-center"
pTooltip="{{ koProgressPercentage || progressPercentage ? 'Continue Reading' : 'Start Reading' }}"
[hidden]="readButtonHidden" [rounded]="true" icon="pi pi-book" class="read-btn" (click)="readBook(book)"></p-button>
<p-button [hidden]="readButtonHidden" [rounded]="true" icon="pi pi-book" class="read-btn" (click)="readBook(book)"></p-button>
@if (isCheckboxEnabled) {
<p-checkbox
@@ -80,7 +67,12 @@
<div [hidden]="bottomBarHidden">
<div class="book-title-container flex items-center">
<h4 class="book-title m-0 pl-2">{{ book.metadata?.title }}</h4>
<h4 class="book-title m-0 pl-2"
tooltipPosition="bottom"
tooltipStyleClass="text-xs text-center"
[pTooltip]="book.metadata?.title">
{{ book.metadata?.title }}
</h4>
<p-tieredmenu #menu [model]="items" [popup]="true" appendTo="body"></p-tieredmenu>
<p-button
class="custom-button-padding"
@@ -69,10 +69,6 @@
</td>
} @else {
<td [title]="getCellValue(metadata, book, col.field)"
tooltipPosition="right"
autoHide="false"
tooltipStyleClass="text-xs text-center"
[pTooltip]="getCellValue(metadata, book, col.field)?.toString()"
class="overflow-hidden truncate text-right min-w-[6rem] max-w-[12rem]">
{{ getCellValue(metadata, book, col.field) }}
</td>
@@ -1,21 +1,16 @@
<div class="book-cover-wrapper"
tooltipPosition="top"
autoHide="false"
tooltipStyleClass="text-xs text-center"
[pTooltip]="book.metadata?.title"
(mouseenter)="isHovered = true"
(mouseleave)="isHovered = false">
<div class="book-cover-wrapper" (mouseenter)="isHovered = true" (mouseleave)="isHovered = false">
<img
[src]="urlHelper.getCoverUrl(book.id, book.metadata?.coverUpdatedOn)"
class="book-cover"
alt="Cover of {{ book.metadata?.title }}"
loading="lazy"
/>
loading="lazy"/>
<p-button
icon="pi pi-info"
class="info-btn"
[rounded]="true"
[pTooltip]="book.metadata?.title"
tooltipPosition="top"
[ngClass]="{ 'visible': isHovered }"
(onClick)="openBookInfo(book)">
</p-button>
@@ -8,7 +8,7 @@ import {filter, Subject} from 'rxjs';
import {NgClass} from '@angular/common';
import {BookMetadataHostService} from '../../../utilities/service/book-metadata-host-service';
import {takeUntil} from 'rxjs/operators';
import { TooltipModule } from 'primeng/tooltip';
import {TooltipModule} from 'primeng/tooltip';
@Component({
selector: 'app-book-card-lite-component',