Skip to content

Commit 2768e2f

Browse files
committed
update style
1 parent 25cdf15 commit 2768e2f

File tree

4 files changed

+24
-15
lines changed

4 files changed

+24
-15
lines changed

docs/.vuepress/theme/lib/client/components/GithubRepo.vue

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ import { onRouteChange } from "../composables/usePageHook"
1010
import type { DefaultThemeLocaleData } from "../../shared"
1111
const $props = withDefaults(
1212
defineProps<{
13-
owner?: string
14-
repo?: string
13+
owner: string
14+
repo: string
1515
}>(),
1616
{}
1717
)
@@ -21,15 +21,15 @@ const themeLocale: Ref<DefaultThemeLocaleData> = useThemeLocaleData()
2121
let repoInfo = useStorage<{
2222
data: any
2323
timestamp: number
24-
}>(`v-nc-github-repo[${owner?.value}/${repo?.value}]`, {
24+
}>(`v-nc-github-repo[${owner.value}/${repo.value}]`, {
2525
data: {},
2626
timestamp: -1,
2727
})
2828
onRouteChange(() => {
2929
repoInfo = useStorage<{
3030
data: any
3131
timestamp: number
32-
}>(`v-nc-github-repo[${owner?.value}/${repo?.value}]`, {
32+
}>(`v-nc-github-repo[${owner.value}/${repo.value}]`, {
3333
data: {},
3434
timestamp: -1,
3535
})
@@ -82,8 +82,14 @@ onBeforeMount(() => {
8282
}}</span>
8383
</span>
8484
<span class="other">
85-
<span class="license" v-html="repoInfo?.data?.license?.spdx_id" />
86-
<span class="lang" v-html="repoInfo?.data?.language" />
85+
<span
86+
class="license"
87+
v-html="`[License] ${repoInfo?.data?.license?.spdx_id}`"
88+
/>
89+
<span
90+
class="lang"
91+
v-html="`[Language] ${repoInfo?.data?.language}`"
92+
/>
8793
</span>
8894
</a>
8995
</div>
@@ -100,9 +106,8 @@ onBeforeMount(() => {
100106
}
101107
102108
.github-repo-card .card-main {
103-
@apply w-fit max-w-48 flex flex-col justify-center py-1 px-2 gap-1
104-
border-2 rounded border-sky-300 dark:border-sky-600
105-
bg-sky-100 dark:bg-sky-950
109+
@apply w-fit max-w-48 flex flex-col justify-center p-2 gap-1
110+
rounded bg-sky-100 dark:bg-sky-950 shadow
106111
transition-all ease-in-out duration-300;
107112
}
108113
.github-repo-card .card-main:has(a[href*="github.com"]) {
@@ -137,7 +142,7 @@ onBeforeMount(() => {
137142
}
138143
139144
.other {
140-
@apply inline-flex justify-center items-center gap-x-3
145+
@apply inline-flex flex-wrap justify-start items-center gap-x-3
141146
text-xs text-gray-500 dark:text-gray-400;
142147
}
143148

docs/.vuepress/theme/lib/client/components/TimeList.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,9 @@ function getTagPath(tag: string) {
5555
>
5656
<span class="author">by {{ getAuthor(article.info.author) }}</span>
5757
</span>
58-
<!-- <span class="article-excerpt">{{
58+
<span class="article-excerpt">{{
5959
stringfyExcerpt(article.info.excerpt)
60-
}}</span> -->
60+
}}</span>
6161
<span class="article-tags">
6262
<router-link
6363
:to="getTagPath(tag)"

docs/.vuepress/theme/lib/client/components/presets/DropdownTransition.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ const unsetHeight = (items: any): void => {
2727
<style lang="postcss">
2828
.dropdown-enter-from,
2929
.dropdown-leave-to {
30-
@apply h-0;
30+
@apply h-0 opacity-0;
31+
}
32+
.dropdown-enter-active,
33+
.dropdown-leave-active {
34+
@apply transition-all ease-in-out duration-300;
3135
}
3236
</style>

docs/.vuepress/theme/lib/client/layouts/Layout.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ const githubRepoData = computed(() => {
3232
</template>
3333
<template #page-side-right>
3434
<GithubRepo
35-
:owner="githubRepoData?.owner"
36-
:repo="githubRepoData?.repo"
35+
:owner="githubRepoData.owner"
36+
:repo="githubRepoData.repo"
3737
v-if="githubRepoData"
3838
/>
3939
<slot name="page-side-right" />

0 commit comments

Comments
 (0)