diff --git a/src/assets/cover.jpg b/src/assets/cover.jpg new file mode 100644 index 0000000..cb67f95 Binary files /dev/null and b/src/assets/cover.jpg differ diff --git a/src/components/BookCover.vue b/src/components/BookCover.vue index 38a6a90..ce48895 100644 --- a/src/components/BookCover.vue +++ b/src/components/BookCover.vue @@ -1,19 +1,13 @@ @@ -63,52 +40,4 @@ const resolvedSrc = computed(() => { display: block; } } - -.cover-fallback { - position: relative; - width: 100%; - height: 100%; - display: flex; - align-items: center; - justify-content: center; - padding: 16px 12px; - color: #fff; - text-align: center; -} - -.cover-spine { - position: absolute; - left: 0; - top: 0; - bottom: 0; - width: 8px; - background: rgba(0, 0, 0, 0.18); -} - -.cover-meta { - display: flex; - flex-direction: column; - align-items: center; - gap: 8px; -} - -.cover-title { - font-size: 14px; - font-weight: 700; - line-height: 1.4; - display: -webkit-box; - -webkit-line-clamp: 3; - -webkit-box-orient: vertical; - overflow: hidden; - text-shadow: 0 1px 3px rgba(0, 0, 0, 0.25); -} - -.cover-author { - font-size: 12px; - opacity: 0.85; - display: -webkit-box; - -webkit-line-clamp: 1; - -webkit-box-orient: vertical; - overflow: hidden; -} diff --git a/src/types/components.d.ts b/src/types/components.d.ts index 0df5cbe..e4bd399 100644 --- a/src/types/components.d.ts +++ b/src/types/components.d.ts @@ -24,6 +24,8 @@ declare module 'vue' { NEmpty: typeof import('naive-ui')['NEmpty'] NForm: typeof import('naive-ui')['NForm'] NFormItem: typeof import('naive-ui')['NFormItem'] + NGi: typeof import('naive-ui')['NGi'] + NGrid: typeof import('naive-ui')['NGrid'] NIcon: typeof import('naive-ui')['NIcon'] NInput: typeof import('naive-ui')['NInput'] NLayout: typeof import('naive-ui')['NLayout'] diff --git a/src/views/BookDetail.vue b/src/views/BookDetail.vue index dc396a4..5049255 100644 --- a/src/views/BookDetail.vue +++ b/src/views/BookDetail.vue @@ -1,14 +1,13 @@ @@ -164,25 +173,47 @@ onMounted(() => {