Fix vertical overflow on metadata edit form dialog: part deux (#1816)
* Fix display overflow on metadata edit form dialog * More fixes to books in dialog mode
This commit is contained in:
+6
-15
@@ -179,19 +179,7 @@ export class BookCardComponent implements OnInit, OnChanges, OnDestroy {
|
|||||||
icon: 'pi pi-info-circle',
|
icon: 'pi pi-info-circle',
|
||||||
command: () => {
|
command: () => {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if (this.metadataCenterViewMode === 'route') {
|
this.openBookInfo(this.book);
|
||||||
this.router.navigate(['/book', this.book.id], {
|
|
||||||
queryParams: {tab: 'view'}
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
this.dialogService.open(BookMetadataCenterComponent, {
|
|
||||||
width: '95%',
|
|
||||||
data: {bookId: this.book.id},
|
|
||||||
modal: true,
|
|
||||||
dismissableMask: true,
|
|
||||||
showHeader: false
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}, 150);
|
}, 150);
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -502,13 +490,16 @@ export class BookCardComponent implements OnInit, OnChanges, OnDestroy {
|
|||||||
} else {
|
} else {
|
||||||
this.dialogService.open(BookMetadataCenterComponent, {
|
this.dialogService.open(BookMetadataCenterComponent, {
|
||||||
width: '90%',
|
width: '90%',
|
||||||
|
height: '90%',
|
||||||
data: {bookId: book.id},
|
data: {bookId: book.id},
|
||||||
modal: true,
|
modal: true,
|
||||||
dismissableMask: false,
|
dismissableMask: true,
|
||||||
showHeader: true,
|
showHeader: true,
|
||||||
closable: true,
|
closable: true,
|
||||||
closeOnEscape: true,
|
closeOnEscape: true,
|
||||||
maximizable: true,
|
draggable: false,
|
||||||
|
maximizable: false,
|
||||||
|
resizable: false,
|
||||||
header: 'Book Details',
|
header: 'Book Details',
|
||||||
styleClass: 'book-details-dialog'
|
styleClass: 'book-details-dialog'
|
||||||
});
|
});
|
||||||
|
|||||||
+23
-2
@@ -1,9 +1,30 @@
|
|||||||
.tabpanels-responsive {
|
::ng-deep .layout-main .tabpanels-responsive {
|
||||||
height: calc(100dvh - 9.7rem);
|
height: calc(100dvh - 9.7rem);
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (max-width: 768px) {
|
@media (max-width: 768px) {
|
||||||
.tabpanels-responsive {
|
::ng-deep .layout-main .tabpanels-responsive {
|
||||||
height: calc(100dvh - 8.5rem);
|
height: calc(100dvh - 8.5rem);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
::ng-deep .book-details-dialog .p-dialog-content,
|
||||||
|
::ng-deep .book-details-dialog app-book-metadata-center,
|
||||||
|
::ng-deep .book-details-dialog app-book-metadata-center > div,
|
||||||
|
::ng-deep .book-details-dialog app-book-metadata-center p-tabs {
|
||||||
|
display: flex;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
::ng-deep .book-details-dialog p-tablist {
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
::ng-deep .book-details-dialog .p-dialog-content {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
::ng-deep .book-details-dialog app-book-metadata-center > div {
|
||||||
|
border-radius: 0 0 0.75rem 0.75rem !important;
|
||||||
|
border-width: 1px 0 0 !important;
|
||||||
|
}
|
||||||
+13
-1
@@ -19,7 +19,19 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
::ng-deep .p-autocomplete-input-chip {
|
::ng-deep .p-autocomplete-input-chip {
|
||||||
width: 7rem;
|
width: 2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
::ng-deep .p-autocomplete-clearable ul {
|
||||||
|
padding-inline-end: 2rem !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
::ng-deep .p-autocomplete-clearable .p-autocomplete-clear-icon {
|
||||||
|
right: 0px;
|
||||||
|
margin-top: -1rem;
|
||||||
|
width: 2rem;
|
||||||
|
height: 2rem;
|
||||||
|
padding: 0.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
::ng-deep .withbutton input,
|
::ng-deep .withbutton input,
|
||||||
|
|||||||
+3
-3
@@ -1,5 +1,5 @@
|
|||||||
@if (selectedFetchedMetadata$ | async; as selectedFetchedMetadata) {
|
@if (selectedFetchedMetadata$ | async; as selectedFetchedMetadata) {
|
||||||
<div class="h-full w-full flex-auto min-w-[80rem]">
|
<div class="h-full w-full flex-auto">
|
||||||
<app-metadata-picker
|
<app-metadata-picker
|
||||||
[fetchedMetadata]="selectedFetchedMetadata"
|
[fetchedMetadata]="selectedFetchedMetadata"
|
||||||
[book$]="book$"
|
[book$]="book$"
|
||||||
@@ -7,7 +7,7 @@
|
|||||||
</app-metadata-picker>
|
</app-metadata-picker>
|
||||||
</div>
|
</div>
|
||||||
} @else {
|
} @else {
|
||||||
<form class="flex flex-col w-full h-full pt-2 min-w-full md:min-w-[60rem] pr-0 md:pr-2 pl-0 md:pl-2" [formGroup]="form" (ngSubmit)="onSubmit()">
|
<form class="flex flex-col w-full h-full pt-2 min-w-full pr-0 md:pr-2 pl-0 md:pl-2" [formGroup]="form" (ngSubmit)="onSubmit()">
|
||||||
|
|
||||||
<div class="flex flex-col space-y-3">
|
<div class="flex flex-col space-y-3">
|
||||||
<div class="grid grid-cols-1 md:flex md:flex-row w-full gap-2 md:gap-4 md:items-end">
|
<div class="grid grid-cols-1 md:flex md:flex-row w-full gap-2 md:gap-4 md:items-end">
|
||||||
@@ -82,7 +82,7 @@
|
|||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
@if (allFetchedMetadata.length > 0) {
|
@if (allFetchedMetadata.length > 0) {
|
||||||
<div class="mt-4 md:mt-8 flex-1 overflow-y-auto">
|
<div class="mt-4 md:mt-8 flex-1">
|
||||||
@for (metadata of allFetchedMetadata; track metadata) {
|
@for (metadata of allFetchedMetadata; track metadata) {
|
||||||
<div class="book-item flex flex-col w-full">
|
<div class="book-item flex flex-col w-full">
|
||||||
<div class="flex flex-row w-full book-item-content cursor-pointer" (click)="onBookClick(metadata)">
|
<div class="flex flex-row w-full book-item-content cursor-pointer" (click)="onBookClick(metadata)">
|
||||||
|
|||||||
Reference in New Issue
Block a user