hookehuyr

refactor(router): 更新首页标题为"美乐爱觉"

style(App): 简化加载动画的模板结构
```

这个提交消息简洁地描述了所做的更改,并遵循了提交消息的格式和指南。第一个更改是更新了路由配置中的首页标题,第二个更改是简化了加载动画的模板结构。
...@@ -24,28 +24,16 @@ provideCart(); ...@@ -24,28 +24,16 @@ provideCart();
24 </script> 24 </script>
25 25
26 <template> 26 <template>
27 - <router-view> 27 + <router-view v-slot="{ Component }">
28 - <template v-slot="{ Component }"> 28 + <div v-if="Component">
29 - <Suspense> 29 + <component :is="Component" />
30 - <template #default> 30 + </div>
31 - <div> 31 + <div v-else class="flex items-center justify-center h-screen bg-gradient-to-br from-green-50 via-teal-50 to-blue-50">
32 - <component :is="Component" /> 32 + <div class="bg-white/20 backdrop-blur-md rounded-xl p-6 shadow-lg">
33 - </div> 33 + <div class="animate-spin rounded-full h-12 w-12 border-b-2 border-green-500 mx-auto"></div>
34 - </template> 34 + <p class="mt-4 text-gray-700">加载中...</p>
35 - <template #fallback> 35 + </div>
36 - <div 36 + </div>
37 - class="flex items-center justify-center h-screen bg-gradient-to-br from-green-50 via-teal-50 to-blue-50"
38 - >
39 - <div class="bg-white/20 backdrop-blur-md rounded-xl p-6 shadow-lg">
40 - <div
41 - class="animate-spin rounded-full h-12 w-12 border-b-2 border-green-500 mx-auto"
42 - ></div>
43 - <p class="mt-4 text-gray-700">加载中...</p>
44 - </div>
45 - </div>
46 - </template>
47 - </Suspense>
48 - </template>
49 </router-view> 37 </router-view>
50 </template> 38 </template>
51 39
......
1 /* 1 /*
2 * @Date: 2025-03-20 20:36:36 2 * @Date: 2025-03-20 20:36:36
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2025-03-21 14:38:09 4 + * @LastEditTime: 2025-03-21 15:45:42
5 * @FilePath: /mlaj/src/router/index.js 5 * @FilePath: /mlaj/src/router/index.js
6 * @Description: 文件描述 6 * @Description: 文件描述
7 */ 7 */
...@@ -13,7 +13,7 @@ const routes = [ ...@@ -13,7 +13,7 @@ const routes = [
13 path: '/', 13 path: '/',
14 name: 'HomePage', 14 name: 'HomePage',
15 component: () => import('../views/HomePage.vue'), 15 component: () => import('../views/HomePage.vue'),
16 - meta: { title: '首页' }, 16 + meta: { title: '美乐爱觉' },
17 }, 17 },
18 { 18 {
19 path: '/courses', 19 path: '/courses',
......