-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+ Loading...
+
+
+ Loading...
+
+
@@ -16,10 +33,116 @@
min-height: 100vh;
font-size: 17px;
}
+
+ .loadingText {
+ animation: fade-in-out 8s ease both;
+ position: absolute;
+ }
+
+ @keyframes fade-in-out {
+ 0%, 100% {
+ opacity: 0;
+ }
+ 50% {
+ opacity: 1;
+ }
+ }
-
diff --git a/src/main.ts b/src/main.ts
index d253bf2..ff8a4e6 100644
--- a/src/main.ts
+++ b/src/main.ts
@@ -1,9 +1,27 @@
import "virtual:windi.css"
-import routes from "~pages"
-import { createApp } from "vue"
-import { createRouter, createWebHistory } from "vue-router"
+import originalRoutes from "~pages"
+import { createApp, FunctionalComponent } from "vue"
+import { createRouter, createWebHistory, RouteRecordRaw } from "vue-router"
import App from "./App.vue"
import { createHead } from "@vueuse/head"
+import { pageComponentLoading } from "./store"
+
+const routes = originalRoutes.map(route => {
+ if (typeof route.component !== "function") return route
+ const load = route.component as (() => Promise