Skip to content

Commit

Permalink
fix: 主题化颜色重复问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Plumbiu committed Jan 29, 2023
1 parent deb48b0 commit b4dd4aa
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 12 deletions.
12 changes: 6 additions & 6 deletions frontend/components/Articles/Navigation/Link.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,24 @@ const artlistPath = useArtlistPath()
<NuxtLink
:to="`${artlistPath === '' ? '/' : artlistPath}`"
:class="`${
$route.query.sort ? 'text-gray-500' : 'text-jj_link'
} border-r-1 focus:text-jj_link hover:text-jj_link`"
$route.query.sort ? 'text-gray-500' : 'text-link'
} border-r-1 focus:text-link hover:text-link`"
>
推荐
</NuxtLink>
<NuxtLink
:to="`${artlistPath}?sort=newest`"
:class="`${
$route.query.sort === 'newest' ? 'text-jj_link' : 'text-gray-500'
} border-r-1 focus:text-jj_link hover:text-jj_link`"
$route.query.sort === 'newest' ? 'text-link' : 'text-gray-500'
} border-r-1 focus:text-link hover:text-link`"
>
最新
</NuxtLink>
<NuxtLink
:to="`${artlistPath}?sort=three_days_hottest`"
:class="`${
($route.query.sort && $route.query.sort?.indexOf('hottest') !== -1) ? 'text-jj_link' : 'text-gray-500'
} focus:text-jj_link hover:text-jj_link`"
($route.query.sort && $route.query.sort?.indexOf('hottest') !== -1) ? 'text-link' : 'text-gray-500'
} focus:text-link hover:text-link`"
>
热榜
</NuxtLink>
Expand Down
11 changes: 5 additions & 6 deletions frontend/unocss.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,14 @@ export default defineConfig({
],
theme: {
colors: {
primary: 'var(--primary-color)',
dark_bg: 'var(--dark-bg)',
link: 'var(--link)',
primary: 'var(--primary-color)', // #316c72
dark_bg: 'var(--dark-bg)', // #18181c
link: 'var(--link)', // #007fff
nav_icon_color: 'var(--jjext-color-navbar-icon)',
jj_sec_app: 'var(--jjext-color-secondary-app)', // #4e5969
jj_thirdly: 'var(--jjext-color-thirdly)', // #86909c
jj_primary: 'var(--jjext-color-primary)',
jj_hover_bg: 'var(--jjext-color-hover-bg)',
jj_link: 'var(--link)',
jj_primary: 'var(--jjext-color-primary)', // #1d2129
jj_hover_bg: 'var(--jjext-color-hover-bg)', // #e8f3ff
},
},
})

0 comments on commit b4dd4aa

Please sign in to comment.