From 9f176d2d4b3bde4b17e55cc0dc101f2355796ed6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=82=AA=E3=82=B9=E3=82=AB=E3=83=BC=E3=80=81?= Date: Tue, 26 Nov 2024 21:55:37 +0900 Subject: [PATCH] enhance(visitor): sakura effect on visitor page --- packages/frontend/src/ui/visitor.vue | 88 +--------------------------- 1 file changed, 3 insertions(+), 85 deletions(-) diff --git a/packages/frontend/src/ui/visitor.vue b/packages/frontend/src/ui/visitor.vue index e16a61327..65902c940 100644 --- a/packages/frontend/src/ui/visitor.vue +++ b/packages/frontend/src/ui/visitor.vue @@ -15,21 +15,6 @@ SPDX-License-Identifier: AGPL-3.0-only
-
@@ -39,35 +24,6 @@ SPDX-License-Identifier: AGPL-3.0-only
- - @@ -77,16 +33,10 @@ import { onMounted, provide, ref, computed } from 'vue'; import XCommon from './_common_/common.vue'; import { instanceName } from '@/config.js'; import { instance } from '@/instance.js'; -/* -import * as os from '@/os.js'; -import XSigninDialog from '@/components/MkSigninDialog.vue'; -import XSignupDialog from '@/components/MkSignupDialog.vue'; -import { ColdDeviceStorage, defaultStore } from '@/store.js'; - */ import { PageMetadata, provideMetadataReceiver, provideReactiveMetadata } from '@/scripts/page-metadata.js'; -// import { i18n } from '@/i18n.js'; import MkVisitorDashboard from '@/components/MkVisitorDashboard.vue'; import { mainRouter } from '@/router/main.js'; +import { SnowfallEffect } from "@/scripts/snowfall-effect.js"; const isRoot = computed(() => mainRouter.currentRoute.value.name === 'index'); @@ -112,40 +62,6 @@ const showMenu = ref(false); const isDesktop = ref(window.innerWidth >= DESKTOP_THRESHOLD); const narrow = ref(window.innerWidth < 1280); -/* -const announcements = { - endpoint: 'announcements', - offsetMode: true, - limit: 10, -}; - -const isTimelineAvailable = ref(instance.policies?.ltlAvailable || instance.policies?.gtlAvailable); - -const keymap = computed(() => { - return { - 'd': () => { - if (ColdDeviceStorage.get('syncDeviceDarkMode')) return; - defaultStore.set('darkMode', !defaultStore.state.darkMode); - }, - 's': () => { - mainRouter.push('/search'); - }, - }; -}); - -function signin() { - os.popup(XSigninDialog, { - autoSet: true, - }, {}, 'closed'); -} - -function signup() { - os.popup(XSignupDialog, { - autoSet: true, - }, {}, 'closed'); -} - */ - onMounted(() => { if (!isDesktop.value) { window.addEventListener('resize', () => { @@ -154,6 +70,8 @@ onMounted(() => { } }); +new SnowfallEffect({ sakura: true }).render(); + defineExpose({ showMenu: showMenu, });