Commit 2de0eb9df2
Unsigned
Layout: unified · split
docs/.vitepress/theme/components/NavActions.vue +8 −2
| @@ -40,8 +40,8 @@ const toggleAppearance = inject<() => void>('toggle-appearance', () => { | ||
| 40 | 40 | :aria-label="isDark ? 'Switch to light theme' : 'Switch to dark theme'" |
| 41 | 41 | @click="toggleAppearance()" |
| 42 | 42 | > |
| 43 | <Moon v-if="isDark" :size="ICON_SIZE" :stroke-width="ICON_STROKE" /> | |
| 44 | <Sun v-else :size="ICON_SIZE" :stroke-width="ICON_STROKE" /> | |
| 43 | <Moon :size="ICON_SIZE" :stroke-width="ICON_STROKE" class="nav-appearance-moon" /> | |
| 44 | <Sun :size="ICON_SIZE" :stroke-width="ICON_STROKE" class="nav-appearance-sun" /> | |
| 45 | 45 | </button> |
| 46 | 46 | |
| 47 | 47 | <VPSocialLink |
| @@ -160,4 +160,10 @@ const toggleAppearance = inject<() => void>('toggle-appearance', () => { | ||
| 160 | 160 | } |
| 161 | 161 | |
| 162 | 162 | .nav-action--settings :deep(.vpi-chevron-down) { display: none; } |
| 163 | ||
| 164 | </style> | |
| 165 | ||
| 166 | <style> | |
| 167 | html.dark .nav-appearance-sun { display: none; } | |
| 168 | html:not(.dark) .nav-appearance-moon { display: none; } | |
| 163 | 169 | </style> |