refactor(frontend): router refactoring

This commit is contained in:
syuilo
2025-03-19 15:24:56 +09:00
parent bdc72e5817
commit 7d4045e8b4
10 changed files with 29 additions and 111 deletions

View File

@@ -22,14 +22,14 @@ SPDX-License-Identifier: AGPL-3.0-only
<script lang="ts" setup>
import { inject, onBeforeUnmount, provide, ref, shallowRef, computed, nextTick } from 'vue';
import type { IRouter, Resolved, RouteDef } from '@/nirax.js';
import type { Router, Resolved, RouteDef } from '@/router.js';
import { prefer } from '@/preferences.js';
import { globalEvents } from '@/events.js';
import MkLoadingPage from '@/pages/_loading_.vue';
import { DI } from '@/di.js';
const props = defineProps<{
router?: IRouter;
router?: Router;
}>();
const router = props.router ?? inject(DI.router);