style(books): align static book grid card baselines to bottom

Align static book grid items to bottom and account for grid gap in cell heights to match virtualized grid alignment.
This commit is contained in:
neon
2026-08-06 23:51:19 +00:00
parent d8809d1f15
commit a1a1ce7db3
2 changed files with 5 additions and 2 deletions
@@ -114,6 +114,7 @@ describe('VirtualBookGrid', () => {
expect(wrapper.find('[data-testid="recycle-scroller"]').exists()).toBe(false)
expect(wrapper.findAll('[data-testid="book-card"]')).toHaveLength(27)
expect(wrapper.get('[data-testid="book-grid-static"]').classes()).toContain('items-end')
})
it('keeps book actions wired in direct render mode', async () => {
@@ -293,7 +293,7 @@ defineExpose({ scrollToIndex })
</div>
</div>
<div v-else-if="!virtualized" class="grid w-full max-w-full items-start" :style="staticGridStyle" data-testid="book-grid-static">
<div v-else-if="!virtualized" class="grid w-full max-w-full items-end" :style="staticGridStyle" data-testid="book-grid-static">
<div v-for="book in staticBooks" :key="book.id" class="min-w-0" :class="{ 'book-grid-cell--new': props.newBookIds.has(book.id) }">
<CollapsedSeriesCard v-if="book.collapsedSeries" :book="book" :show-label="showLabel" />
<BookCoverCard
@@ -367,7 +367,9 @@ defineExpose({ scrollToIndex })
}
.book-grid-cell {
height: calc(var(--book-grid-height) + var(--book-grid-label-height, 0px));
display: grid;
align-items: end;
height: calc(var(--book-grid-height) + var(--book-grid-label-height, 0px) + var(--book-grid-gap));
box-sizing: border-box;
padding-left: 0;
padding-right: var(--book-grid-gap);