✨ 未加载时骨架 与 样式小改

This commit is contained in:
2026-06-19 22:08:36 +08:00
parent e70e2358e8
commit 155eba16d1
6 changed files with 37 additions and 25 deletions
+6
View File
@@ -31,6 +31,12 @@ onMounted(() => {
:model-value="eraseHeaderMarkdown"
class="max-w-full"
/>
<div v-else class="w-5/6">
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
</div>
</div>
</template>
+4 -4
View File
@@ -67,11 +67,11 @@ onMounted(() => {
</script>
<template>
<div class="bg-old-neutral-50 dark:bg-[#0b0d0d] w-full min-h-[100vh] h-full">
<div class="bg-old-neutral-50 dark:bg-[#0b0d0d] w-full min-h-screen h-full">
<UApp>
<div
:class=" (collapsed ? 'h-[20vh]': 'h-[40vh]')"
class="flex flex-col relative transition-[height] duration-500 max-h-80">
class="flex flex-col relative transition-[height] duration-500 max-h-80 min-h-40">
<!-- header -->
<div
v-if="mounted"
@@ -94,10 +94,10 @@ onMounted(() => {
<div v-if="isScrollDown">
<div
v-if="colorMode === 'light'"
class="opacity-80 max-h-[48px] flex w-full h-full fixed bg-[url('/79d52228c770808810a310115567e6790380823a.webp')] bg-cover bg-top"/>
class="opacity-80 max-h-12 flex w-full h-full fixed bg-[url('/79d52228c770808810a310115567e6790380823a.webp')] bg-cover bg-top"/>
<div
v-else
class="opacity-20 max-h-[48px] flex w-full h-full fixed bg-[url('/anime-8788959.webp')] bg-cover bg-center"/>
class="opacity-20 max-h-12 flex w-full h-full fixed bg-[url('/anime-8788959.webp')] bg-cover bg-center"/>
</div>
</div>
<!-- navbar -->
+3 -2
View File
@@ -26,6 +26,7 @@
"nuxt": "^4.1.2",
"overlayscrollbars-vue": "^0.5.9",
"pinia": "^3.0.3",
"serve": "^14.2.5",
"tailwind-scrollbar": "^4.0.2",
"tailwindcss": "^4.1.11",
"typescript": "^5.6.3",
@@ -33,7 +34,6 @@
"vue-router": "^4.5.1",
"word-count": "^0.3.1"
},
"packageManager": "pnpm@10.22.0",
"devDependencies": {
"@iconify-json/clarity": "^1.2.4",
"@iconify-json/codicon": "^1.2.32",
@@ -59,5 +59,6 @@
"unrs-resolver",
"vue-demi"
]
}
},
"packageManager": "pnpm@11.8.0+sha512.c1f5e7c4cb241c8f174b743851d82f42b802324afc8b0f116b96adb15aa06664948dde36960a3ba1079ba5b4b29dd0140135b94b5b5f5263592249d68e555f26"
}
+6 -1
View File
@@ -95,9 +95,14 @@ onMounted(() => {
</div>
<div class="flex mt-2 justify-between h-28">
<overlay-scrollbars-component>
<overlay-scrollbars-component v-if="mounted">
{{ metaData?.description }}
</overlay-scrollbars-component>
<div v-else class="w-4/5">
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
<USkeleton class="h-4 mb-3 w-full bg-old-neutral-600"/>
</div>
<div v-if="mounted" class="">
<TechStackCard
:async-key="'stack:' + metaData?.id"
+3 -3
View File
@@ -115,13 +115,13 @@ function reverseCollapsed() {
</div>
<div
class="relative flex mt-2 justify-between overflow-hidden duration-300 ease-in-out min-h-[8.5rem]"
:class="{'max-h-[8.5rem]' : collapsed, 'max-h-[100vh]':!collapsed}">
class="relative flex mt-2 justify-between overflow-hidden duration-300 ease-in-out min-h-34"
:class="{'max-h-34' : collapsed, 'max-h-screen':!collapsed}">
<ReadonlyMdEditor
v-if="rawbody" :editor-id="safeEditorId" :markdown="rawbody!"
class="w-full"/>
<div
class="absolute bottom-0 left-0 right-0 h-14 bg-gradient-to-t from-old-neutral-200 dark:from-old-neutral-800 to-transparent pointer-events-none transition-opacity duration-300"
class="absolute bottom-0 left-0 right-0 h-14 bg-linear-to-t from-old-neutral-200 dark:from-old-neutral-800 to-transparent pointer-events-none transition-opacity duration-300"
:class="collapsed && showShadow?'opacity-100':'opacity-0'"
/>
</div>
+1 -1
View File
@@ -59,7 +59,7 @@ function filterRuleChange(rule: (data: PostMetaData) => boolean) {
<div v-else-if="post.draft">
</div>
<div v-else>
{{post}}
{{ post }}
</div>
</div>
<div v-if="postsMetaData.length === 0" class="w-full">