Add hover
This commit is contained in:
@@ -36,10 +36,10 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div *ngIf="!loading" class="mt-8 flex-1 overflow-y-auto">
|
<div *ngIf="!loading" class="mt-8 flex-1 overflow-y-auto">
|
||||||
<div *ngFor="let book of books" class="flex flex-col w-full">
|
<div *ngFor="let book of books" class="book-item flex flex-col w-full">
|
||||||
<div class="flex w-full flex-row">
|
<div class="flex w-full flex-row book-item-content">
|
||||||
<img [src]="book.thumbnailUrl" alt="Image" class="img-fixed-dimensions pr-2" />
|
<img [src]="book.thumbnailUrl" alt="Image" class="img-fixed-dimensions pr-2" />
|
||||||
<div class="flex flex-col w-full m-2">
|
<div class=" flex flex-col w-full m-2">
|
||||||
<div class="flex flex-row gap-4 justify-between">
|
<div class="flex flex-row gap-4 justify-between">
|
||||||
<p class="font-bold">{{ truncateText(book['title'], 90) }}</p>
|
<p class="font-bold">{{ truncateText(book['title'], 90) }}</p>
|
||||||
<div class="flex gap-4">
|
<div class="flex gap-4">
|
||||||
|
|||||||
@@ -11,3 +11,26 @@
|
|||||||
width: 100px;
|
width: 100px;
|
||||||
object-fit: fill;
|
object-fit: fill;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.book-item {
|
||||||
|
position: relative;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.book-item-content {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
.book-item:hover .book-item-content::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
right: 0;
|
||||||
|
bottom: 0;
|
||||||
|
background-color: rgba(255, 255, 255, 0.075);
|
||||||
|
}
|
||||||
|
|
||||||
|
.book-item:hover .book-item-content {
|
||||||
|
box-shadow: 0 0 0 rgba(255, 255, 255, 0.9);
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user