From 6b541c77afcab59e8f115eeb7bf0314d00fed8bd Mon Sep 17 00:00:00 2001
From: "aditya.chandel" <>
Date: Wed, 8 Jan 2025 17:08:05 -0700
Subject: [PATCH] WIP: Buggy big table to small to big switching
---
booklore-ui/package-lock.json | 8 +-
booklore-ui/package.json | 2 +-
booklore-ui/src/app/app-routing.module.ts | 2 +-
booklore-ui/src/app/app.module.ts | 70 +++++-----
.../metadata-searcher.component.ts | 1 -
.../metadata-viewer.component.html | 4 +-
.../book-browser/book-browser.component.html | 124 ++++++++----------
.../book-browser/book-browser.component.scss | 6 -
.../book-browser/book-browser.component.ts | 24 +++-
.../book-card/book-card.component.ts | 6 +-
.../book-table/book-table.component.html | 77 +++++------
.../book-table/book-table.component.scss | 6 +
.../book-table/book-table.component.ts | 51 +++++--
13 files changed, 203 insertions(+), 178 deletions(-)
diff --git a/booklore-ui/package-lock.json b/booklore-ui/package-lock.json
index 0a98c1a1b..4e0716feb 100644
--- a/booklore-ui/package-lock.json
+++ b/booklore-ui/package-lock.json
@@ -24,7 +24,7 @@
"ngx-extended-pdf-viewer": "^22.0.0",
"ngx-infinite-scroll": "^19.0.0",
"primeicons": "^7.0.0",
- "primeng": "19.0.2",
+ "primeng": "19.0.3",
"quill": "^2.0.3",
"rxjs": "~7.8.0",
"tailwindcss-primeui": "^0.3.4",
@@ -12037,9 +12037,9 @@
"license": "MIT"
},
"node_modules/primeng": {
- "version": "19.0.2",
- "resolved": "https://registry.npmjs.org/primeng/-/primeng-19.0.2.tgz",
- "integrity": "sha512-7vizB1ynvvADjZBE9/Ks/YFwbY/d2tKYo+8Uq3OsBq9+rf9pIwKQIhd9GKkpe1gXx5Ig2SOFVeTp1Ru4H/vlVA==",
+ "version": "19.0.3",
+ "resolved": "https://registry.npmjs.org/primeng/-/primeng-19.0.3.tgz",
+ "integrity": "sha512-cv15SG37WcMFlGZY9cyMULM8l91PTYRONdvMoDECNnH7LV0EkG1jvrsAezn8c4IsoJheofnoZez9D6Z9TpS4PQ==",
"license": "SEE LICENSE IN LICENSE.md",
"dependencies": {
"@primeuix/styled": "^0.3.2",
diff --git a/booklore-ui/package.json b/booklore-ui/package.json
index 245f6f325..39e90522c 100644
--- a/booklore-ui/package.json
+++ b/booklore-ui/package.json
@@ -26,7 +26,7 @@
"ngx-extended-pdf-viewer": "^22.0.0",
"ngx-infinite-scroll": "^19.0.0",
"primeicons": "^7.0.0",
- "primeng": "19.0.2",
+ "primeng": "19.0.3",
"quill": "^2.0.3",
"rxjs": "~7.8.0",
"tailwindcss-primeui": "^0.3.4",
diff --git a/booklore-ui/src/app/app-routing.module.ts b/booklore-ui/src/app/app-routing.module.ts
index 895f6949d..f8b771a45 100644
--- a/booklore-ui/src/app/app-routing.module.ts
+++ b/booklore-ui/src/app/app-routing.module.ts
@@ -14,7 +14,7 @@ const routes: Routes = [
path: '', component: DashboardComponent,
},
{
- path: 'all-books', component: BookTableComponent,
+ path: 'all-books', component: BookBrowserComponent,
},
{
path: 'library/:libraryId/books', component: BookBrowserComponent,
diff --git a/booklore-ui/src/app/app.module.ts b/booklore-ui/src/app/app.module.ts
index 578322fff..8b3a96dc8 100644
--- a/booklore-ui/src/app/app.module.ts
+++ b/booklore-ui/src/app/app.module.ts
@@ -43,6 +43,9 @@ import Aura from '@primeng/themes/aura';
import {IftaLabel} from 'primeng/iftalabel';
import {LoadingOverlayComponent} from './loading-overlay/loading-overlay.component';
import {MultiSelectModule} from 'primeng/multiselect';
+import {SelectButton} from "primeng/selectbutton";
+import {BookTableComponent} from './book/component/book-table/book-table.component';
+import {RadioButton} from 'primeng/radiobutton';
@NgModule({
declarations: [
@@ -52,38 +55,41 @@ import {MultiSelectModule} from 'primeng/multiselect';
ShelfAssignerComponent,
BookBrowserComponent
],
- imports: [
- BrowserModule,
- AppRoutingModule,
- AppLayoutModule,
- FormsModule,
- InputTextModule,
- TableModule,
- Button,
- StepperModule,
- IconFieldModule,
- InputIconModule,
- ToggleButtonModule,
- PasswordModule,
- ToastModule,
- InfiniteScrollDirective,
- SearchComponent,
- DropdownModule,
- VirtualScrollerModule,
- LazyLoadImageModule,
- ConfirmDialogModule,
- CheckboxModule,
- DividerModule,
- DialogModule,
- BookCardComponent,
- SpeedDialModule,
- MenuModule,
- IconPickerComponent,
- ProgressSpinnerModule,
- IftaLabel,
- LoadingOverlayComponent,
- MultiSelectModule
- ],
+ imports: [
+ BrowserModule,
+ AppRoutingModule,
+ AppLayoutModule,
+ FormsModule,
+ InputTextModule,
+ TableModule,
+ Button,
+ StepperModule,
+ IconFieldModule,
+ InputIconModule,
+ ToggleButtonModule,
+ PasswordModule,
+ ToastModule,
+ InfiniteScrollDirective,
+ SearchComponent,
+ DropdownModule,
+ VirtualScrollerModule,
+ LazyLoadImageModule,
+ ConfirmDialogModule,
+ CheckboxModule,
+ DividerModule,
+ DialogModule,
+ BookCardComponent,
+ SpeedDialModule,
+ MenuModule,
+ IconPickerComponent,
+ ProgressSpinnerModule,
+ IftaLabel,
+ LoadingOverlayComponent,
+ MultiSelectModule,
+ SelectButton,
+ BookTableComponent,
+ RadioButton
+ ],
providers: [
DialogService,
MessageService,
diff --git a/booklore-ui/src/app/book-metadata-center/metadata-searcher/metadata-searcher.component.ts b/booklore-ui/src/app/book-metadata-center/metadata-searcher/metadata-searcher.component.ts
index dd49abb84..9ba87cb03 100644
--- a/booklore-ui/src/app/book-metadata-center/metadata-searcher/metadata-searcher.component.ts
+++ b/booklore-ui/src/app/book-metadata-center/metadata-searcher/metadata-searcher.component.ts
@@ -19,7 +19,6 @@ import {MultiSelect} from 'primeng/multiselect';
templateUrl: './metadata-searcher.component.html',
styleUrls: ['./metadata-searcher.component.scss'],
imports: [
- Select,
ReactiveFormsModule,
Button,
InputText,
diff --git a/booklore-ui/src/app/book-metadata-center/metadata-viewer/metadata-viewer.component.html b/booklore-ui/src/app/book-metadata-center/metadata-viewer/metadata-viewer.component.html
index 8dc1942ec..cb2858ffb 100644
--- a/booklore-ui/src/app/book-metadata-center/metadata-viewer/metadata-viewer.component.html
+++ b/booklore-ui/src/app/book-metadata-center/metadata-viewer/metadata-viewer.component.html
@@ -4,10 +4,10 @@
-
{{ bookMetadata.title }}
+{{ bookMetadata.title }}
({{ bookMetadata.reviewCount || 0 }} Reviews)
diff --git a/booklore-ui/src/app/book/component/book-browser/book-browser.component.html b/booklore-ui/src/app/book/component/book-browser/book-browser.component.html index 99c84d570..0000e2006 100644 --- a/booklore-ui/src/app/book/component/book-browser/book-browser.component.html +++ b/booklore-ui/src/app/book/component/book-browser/book-browser.component.html @@ -7,15 +7,8 @@All Books
-- {{ entityType === EntityType.LIBRARY ? "Failed to load library's books!" : "Failed to load shelf's books!" }} -
-- {{ entityType === EntityType.LIBRARY ? "This library has no books!" : "This shelf has no books!" }} -
++ {{ entityType === EntityType.LIBRARY ? "Failed to load library's books!" : "Failed to load shelf's books!" }} +
++ {{ entityType === EntityType.LIBRARY ? "This library has no books!" : "This shelf has no books!" }} +
+