Commit d3f6ce296d

d3f6ce296da517d36b88aa1066489c97bdffe23c

parent: 01ae7057e1

Unsigned

Duck <57977673+woducku@users.noreply.github.com> · 2026-06-24 08:38 UTC

push

Layout: unified · split

docs/.vitepress/configs/constants.ts −5
@@ -548,11 +548,6 @@ export const siteConfig = {
548 href: '/asset/fav.svg', 548 href: '/asset/fav.svg',
549 sizes: '192x192' 549 sizes: '192x192'
550 } 550 }
551 ],
552 [
553 'script',
554 {},
555 `(function(){try{if(localStorage.getItem('wotaku-home-cards-v2'))document.documentElement.setAttribute('data-home-prefs','')}catch(e){}})()`
556 ] 551 ]
557 ], 552 ],
558 srcExclude: ['README.md', 'sandbox/**/*.md'], 553 srcExclude: ['README.md', 'sandbox/**/*.md'],
docs/.vitepress/theme/components/HomeFeatures.vue +18 −10
@@ -144,6 +144,7 @@ function resetDefaults() {
144const cardTooltip = ref<{ text: string; x: number; y: number } | null>(null) 144const cardTooltip = ref<{ text: string; x: number; y: number } | null>(null)
145 145
146function showCardTooltip(e: MouseEvent, title: string) { 146function showCardTooltip(e: MouseEvent, title: string) {
147 if (!window.matchMedia('(hover: hover)').matches) return
147 const rect = (e.currentTarget as HTMLElement).getBoundingClientRect() 148 const rect = (e.currentTarget as HTMLElement).getBoundingClientRect()
148 cardTooltip.value = { text: title, x: rect.left + rect.width / 2, y: rect.top } 149 cardTooltip.value = { text: title, x: rect.left + rect.width / 2, y: rect.top }
149} 150}
@@ -378,12 +379,6 @@ function onHandlePointerUp() {
378 </Teleport> 379 </Teleport>
379</template> 380</template>
380 381
381<style>
382html[data-home-prefs] .home-features:not(.is-mounted) {
383 opacity: 0;
384}
385</style>
386
387<style scoped> 382<style scoped>
388/* ── Grid ── */ 383/* ── Grid ── */
389.home-features { 384.home-features {
@@ -391,6 +386,15 @@ html[data-home-prefs] .home-features:not(.is-mounted) {
391 padding: 0 24px; 386 padding: 0 24px;
392} 387}
393 388
389.home-features .container {
390 opacity: 0;
391 transition: opacity 0.15s ease;
392}
393
394.home-features.is-mounted .container {
395 opacity: 1;
396}
397
394@media (min-width: 640px) { 398@media (min-width: 640px) {
395 .home-features { padding: 0 48px; } 399 .home-features { padding: 0 48px; }
396} 400}
@@ -635,8 +639,10 @@ html[data-home-prefs] .home-features:not(.is-mounted) {
635 z-index: 10; 639 z-index: 10;
636} 640}
637 641
638.close-btn:hover::after { 642@media (hover: hover) {
639 opacity: 1; 643 .close-btn:hover::after {
644 opacity: 1;
645 }
640} 646}
641 647
642/* ── Card List ── */ 648/* ── Card List ── */
@@ -878,8 +884,10 @@ html[data-home-prefs] .home-features:not(.is-mounted) {
878 z-index: 10; 884 z-index: 10;
879} 885}
880 886
881.tool-btn[aria-label]:hover::after { 887@media (hover: hover) {
882 opacity: 1; 888 .tool-btn[aria-label]:hover::after {
889 opacity: 1;
890 }
883} 891}
884 892
885.tool-btn:hover { 893.tool-btn:hover {