Layout cleanup for library creator
This commit is contained in:
+15
-15
@@ -1,4 +1,4 @@
|
|||||||
<p-stepper [value]="1" class="basis-[50rem]">
|
<p-stepper [value]="1">
|
||||||
<p-step-list>
|
<p-step-list>
|
||||||
<p-step [value]="1">Library Details</p-step>
|
<p-step [value]="1">Library Details</p-step>
|
||||||
<p-step [value]="2">Select Directory</p-step>
|
<p-step [value]="2">Select Directory</p-step>
|
||||||
@@ -6,21 +6,21 @@
|
|||||||
<p-step-panels>
|
<p-step-panels>
|
||||||
<p-step-panel [value]="1">
|
<p-step-panel [value]="1">
|
||||||
<ng-template #content let-activateCallback="activateCallback">
|
<ng-template #content let-activateCallback="activateCallback">
|
||||||
<div class="flex flex-col h-48 stepper-content-custom">
|
<div class="flex flex-col w-[40rem] h-[25rem]">
|
||||||
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">
|
<div class="flex flex-auto justify-center items-center font-medium border-[var(--border-color)] border-2 border-dashed">
|
||||||
<div class="library-name-icon-parent">
|
<div class="flex flex-col gap-10">
|
||||||
<div class="library-name-div">
|
<div class="flex flex-row items-center gap-2">
|
||||||
<p>Library Name: </p>
|
<p>Library Name: </p>
|
||||||
<input type="text" pInputText [(ngModel)]="chosenLibraryName" placeholder="Enter library name..."/>
|
<input type="text" pInputText [(ngModel)]="chosenLibraryName" placeholder="Enter library name..."/>
|
||||||
</div>
|
</div>
|
||||||
<div class="library-icon-div">
|
<div class=" flex flex-row items-center gap-5">
|
||||||
<p>Library Icon:</p>
|
<p>Library Icon:</p>
|
||||||
<div *ngIf="!selectedIcon">
|
<div *ngIf="!selectedIcon">
|
||||||
<p-button label="Select Icon" icon="pi pi-search" (onClick)="openIconPicker()"></p-button>
|
<p-button label="Select Icon" icon="pi pi-search" (onClick)="openIconPicker()"></p-button>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="selectedIcon" class="selected-icon-container">
|
<div *ngIf="selectedIcon">
|
||||||
<i [class]="selectedIcon" style="font-size: 1.25rem; margin-right: 0.75rem;"></i>
|
<i [class]="selectedIcon" style="font-size: 1.25rem; margin-right: 0.75rem;"></i>
|
||||||
<p-button icon="pi pi-times" (onClick)="clearSelectedIcon()" [rounded]="true" [text]="true" [outlined]="true" class="remove-icon-button" severity="danger"></p-button>
|
<p-button icon="pi pi-times" (onClick)="clearSelectedIcon()" [rounded]="true" [text]="true" [outlined]="true" severity="danger"></p-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -35,20 +35,20 @@
|
|||||||
|
|
||||||
<p-step-panel [value]="2">
|
<p-step-panel [value]="2">
|
||||||
<ng-template #content let-activateCallback="activateCallback">
|
<ng-template #content let-activateCallback="activateCallback">
|
||||||
<div class="flex flex-col h-48 stepper-content-custom">
|
<div class="flex flex-col w-[40rem] h-[25rem]">
|
||||||
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">
|
<div class="flex flex-auto justify-center items-center font-medium border-[var(--border-color)] border-2 border-dashed">
|
||||||
<div class="flex flex-col justify-center items-center w-100">
|
<div class="flex flex-col justify-center items-center">
|
||||||
<p-button
|
<p-button
|
||||||
severity="info"
|
severity="info"
|
||||||
label="Add book folders"
|
label="Add book folders"
|
||||||
[outlined]="true"
|
[outlined]="true"
|
||||||
(onClick)="show()">
|
(onClick)="openDirectoryPicker()">
|
||||||
</p-button>
|
</p-button>
|
||||||
<p-table [value]="folders" styleClass="p-datatable-striped" class="p-table-custom mt-4">
|
<p-table [value]="folders" class="mt-4 max-w-[35rem] max-h-[11.5rem] !overflow-scroll">
|
||||||
<ng-template pTemplate="body" let-folder let-i="rowIndex">
|
<ng-template pTemplate="body" let-folder let-i="rowIndex">
|
||||||
<tr>
|
<tr>
|
||||||
<td class="tr-custom">{{ folder }}</td>
|
<td class="!p-1 !px-2 !border-0">{{ folder }}</td>
|
||||||
<td class="tr-custom td-x-custom">
|
<td class="!p-1 !px-2 !border-0">
|
||||||
<p-button
|
<p-button
|
||||||
icon="pi pi-times"
|
icon="pi pi-times"
|
||||||
[rounded]="true"
|
[rounded]="true"
|
||||||
|
|||||||
@@ -1,95 +1 @@
|
|||||||
.library-name-icon-parent {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
align-items: flex-start;
|
|
||||||
gap: 2.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.library-name-div {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 0.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.library-icon-div {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 0.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.library-name-div label,
|
|
||||||
.library-icon-div label {
|
|
||||||
margin-right: 0.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.library-name-div input {
|
|
||||||
width: 200px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.library-icon-div p-button {
|
|
||||||
margin-left: 0.8rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p-stepperPanel {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
padding: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p-stepperPanel .flex {
|
|
||||||
display: flex;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p-stepperPanel .justify-content-end {
|
|
||||||
justify-content: flex-end;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p-stepperPanel .mt-3 {
|
|
||||||
margin-top: 1rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p-table-custom {
|
|
||||||
min-width: 35rem !important;
|
|
||||||
max-height: 11.25rem !important;
|
|
||||||
overflow: scroll;
|
|
||||||
}
|
|
||||||
|
|
||||||
.tr-custom {
|
|
||||||
padding: 0.25rem 0.5rem !important;
|
|
||||||
border: 0px !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.td-x-custom {
|
|
||||||
text-align: right;
|
|
||||||
}
|
|
||||||
|
|
||||||
.w-100 {
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p-button {
|
|
||||||
margin-left: 0.5rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.selected-icon-container {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
margin-left: 1rem;
|
|
||||||
|
|
||||||
i {
|
|
||||||
color: var(--text-color);
|
|
||||||
}
|
|
||||||
|
|
||||||
.remove-icon-button {
|
|
||||||
margin-left: 0.5rem;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.stepper-content-custom {
|
|
||||||
height: 335px;
|
|
||||||
padding: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.p {
|
|
||||||
color: var(--text-color);
|
|
||||||
}
|
|
||||||
|
|||||||
@@ -56,12 +56,10 @@ export class LibraryCreatorComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
show() {
|
openDirectoryPicker() {
|
||||||
this.directoryPickerDialogRef = this.dialogService.open(DirectoryPickerComponent, {
|
this.directoryPickerDialogRef = this.dialogService.open(DirectoryPickerComponent, {
|
||||||
header: 'Select Media Directory',
|
header: 'Select Media Directory',
|
||||||
modal: true,
|
modal: true,
|
||||||
width: '50%',
|
|
||||||
height: '75%',
|
|
||||||
contentStyle: {overflow: 'auto'},
|
contentStyle: {overflow: 'auto'},
|
||||||
baseZIndex: 10
|
baseZIndex: 10
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -84,8 +84,6 @@ export class AppTopBarComponent implements OnDestroy {
|
|||||||
header: 'Create New Library',
|
header: 'Create New Library',
|
||||||
modal: true,
|
modal: true,
|
||||||
closable: true,
|
closable: true,
|
||||||
width: '675px',
|
|
||||||
height: '480px',
|
|
||||||
style: {
|
style: {
|
||||||
position: 'absolute',
|
position: 'absolute',
|
||||||
top: '15%',
|
top: '15%',
|
||||||
|
|||||||
+11
-8
@@ -1,26 +1,28 @@
|
|||||||
<div style="margin-bottom: 1.5rem; display: flex; align-items: center; gap: 1rem;">
|
<div class="min-h-screen flex flex-col">
|
||||||
|
<div class="mb-6 flex items-center gap-4">
|
||||||
<input
|
<input
|
||||||
id="disabled-input"
|
id="disabled-input"
|
||||||
type="text"
|
type="text"
|
||||||
pInputText
|
pInputText
|
||||||
[value]="selectedProductName"
|
[value]="selectedProductName"
|
||||||
[disabled]="true"
|
[disabled]="true"
|
||||||
[ngStyle]="{ 'width': '100%', 'padding': '0.5rem', 'font-size': '1rem' }"
|
class="w-full p-2 text-base"
|
||||||
/>
|
/>
|
||||||
<p-button label="Select" severity="success" [ngStyle]="{ 'width': '100px' }" (click)="onSelect()"/>
|
<p-button label="Select" severity="success" class="w-[100px]" (click)="onSelect()"></p-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<ng-container>
|
<ng-container>
|
||||||
<div style="overflow-x: auto;">
|
<div class="overflow-x-auto">
|
||||||
<p-table [value]="paths" [tableStyle]="{ 'min-width': '50rem' }" class="product-table">
|
<p-table [value]="paths" [tableStyle]="{ 'min-width': '50rem' }" class="product-table w-full">
|
||||||
<ng-template pTemplate="header">
|
<ng-template pTemplate="header">
|
||||||
<tr>
|
<tr>
|
||||||
<th [style.width]="'10%'">Type</th>
|
<th class="w-[10%]">Type</th>
|
||||||
<th [style.width]="'90%'">Name</th>
|
<th class="w-[90%]">Name</th>
|
||||||
</tr>
|
</tr>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
|
|
||||||
<ng-template pTemplate="body" let-product>
|
<ng-template pTemplate="body" let-product>
|
||||||
<tr (click)="onRowClick(product)">
|
<tr class="cursor-pointer hover:bg-white/10" (click)="onRowClick(product)">
|
||||||
<td>
|
<td>
|
||||||
<i *ngIf="product === '...'" class="pi pi-arrow-up"></i>
|
<i *ngIf="product === '...'" class="pi pi-arrow-up"></i>
|
||||||
<i *ngIf="product !== '...'" class="pi pi-folder-open"></i>
|
<i *ngIf="product !== '...'" class="pi pi-folder-open"></i>
|
||||||
@@ -31,3 +33,4 @@
|
|||||||
</p-table>
|
</p-table>
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
</div>
|
||||||
|
|||||||
+1
-1
@@ -2,7 +2,7 @@ version: '3.8'
|
|||||||
services:
|
services:
|
||||||
booklore-app:
|
booklore-app:
|
||||||
container_name: booklore
|
container_name: booklore
|
||||||
image: localhost:5000/booklore-app:v33
|
image: localhost:5000/booklore-app:v8
|
||||||
ports:
|
ports:
|
||||||
- "5050:6060"
|
- "5050:6060"
|
||||||
volumes:
|
volumes:
|
||||||
|
|||||||
Reference in New Issue
Block a user