refactor: 更新项目配置和UI结构
- 修改package.json中的tar命令路径为mlaj - 更新index.html的标题和viewport配置 - 优化App.vue的模板结构,移除多余的div层级
Showing
3 changed files
with
34 additions
and
29 deletions
| 1 | +<!-- | ||
| 2 | + * @Date: 2025-03-20 20:36:36 | ||
| 3 | + * @LastEditors: hookehuyr hookehuyr@gmail.com | ||
| 4 | + * @LastEditTime: 2025-03-21 15:27:31 | ||
| 5 | + * @FilePath: /mlaj/index.html | ||
| 6 | + * @Description: 文件描述 | ||
| 7 | +--> | ||
| 1 | <!doctype html> | 8 | <!doctype html> |
| 2 | <html lang="en"> | 9 | <html lang="en"> |
| 3 | <head> | 10 | <head> |
| 4 | <meta charset="UTF-8" /> | 11 | <meta charset="UTF-8" /> |
| 5 | - <link rel="icon" type="image/svg+xml" href="/vite.svg" /> | 12 | + <!-- <link rel="icon" type="image/svg+xml" href="/vite.svg" /> --> |
| 6 | - <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | 13 | + <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, viewport-fit=cover" /> |
| 7 | - <title>Vite + Vue</title> | 14 | + <title>美乐爱觉</title> |
| 8 | </head> | 15 | </head> |
| 9 | <body> | 16 | <body> |
| 10 | <div id="app"></div> | 17 | <div id="app"></div> | ... | ... |
| ... | @@ -7,7 +7,7 @@ | ... | @@ -7,7 +7,7 @@ |
| 7 | "dev": "vite", | 7 | "dev": "vite", |
| 8 | "build": "vite build", | 8 | "build": "vite build", |
| 9 | "preview": "vite preview", | 9 | "preview": "vite preview", |
| 10 | - "tar": "tar -czvpf dist.tar.gz reserve", | 10 | + "tar": "tar -czvpf dist.tar.gz mlaj", |
| 11 | "build_tar": "npm run build && npm run tar", | 11 | "build_tar": "npm run build && npm run tar", |
| 12 | "scp-dev": "scp dist.tar.gz ipadbiz-inner:/opt/space-dev/f", | 12 | "scp-dev": "scp dist.tar.gz ipadbiz-inner:/opt/space-dev/f", |
| 13 | "dec-dev": "ssh ipadbiz-inner 'cd /opt/space-dev/f && tar -xzvf dist.tar.gz && rm -rf dist.tar.gz'", | 13 | "dec-dev": "ssh ipadbiz-inner 'cd /opt/space-dev/f && tar -xzvf dist.tar.gz && rm -rf dist.tar.gz'", | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2025-03-20 19:53:12 | 2 | * @Date: 2025-03-20 19:53:12 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2025-03-20 23:56:05 | 4 | + * @LastEditTime: 2025-03-21 15:28:49 |
| 5 | * @FilePath: /mlaj/src/App.vue | 5 | * @FilePath: /mlaj/src/App.vue |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | --> | 7 | --> |
| ... | @@ -24,31 +24,29 @@ provideCart(); | ... | @@ -24,31 +24,29 @@ provideCart(); |
| 24 | </script> | 24 | </script> |
| 25 | 25 | ||
| 26 | <template> | 26 | <template> |
| 27 | - <div> | 27 | + <router-view> |
| 28 | - <router-view> | 28 | + <template v-slot="{ Component }"> |
| 29 | - <template v-slot="{ Component }"> | 29 | + <Suspense> |
| 30 | - <Suspense> | 30 | + <template #default> |
| 31 | - <template #default> | 31 | + <div> |
| 32 | - <div> | 32 | + <component :is="Component" /> |
| 33 | - <component :is="Component" /> | 33 | + </div> |
| 34 | + </template> | ||
| 35 | + <template #fallback> | ||
| 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> | ||
| 34 | </div> | 44 | </div> |
| 35 | - </template> | 45 | + </div> |
| 36 | - <template #fallback> | 46 | + </template> |
| 37 | - <div | 47 | + </Suspense> |
| 38 | - class="flex items-center justify-center h-screen bg-gradient-to-br from-green-50 via-teal-50 to-blue-50" | 48 | + </template> |
| 39 | - > | 49 | + </router-view> |
| 40 | - <div class="bg-white/20 backdrop-blur-md rounded-xl p-6 shadow-lg"> | ||
| 41 | - <div | ||
| 42 | - class="animate-spin rounded-full h-12 w-12 border-b-2 border-green-500 mx-auto" | ||
| 43 | - ></div> | ||
| 44 | - <p class="mt-4 text-gray-700">加载中...</p> | ||
| 45 | - </div> | ||
| 46 | - </div> | ||
| 47 | - </template> | ||
| 48 | - </Suspense> | ||
| 49 | - </template> | ||
| 50 | - </router-view> | ||
| 51 | - </div> | ||
| 52 | </template> | 50 | </template> |
| 53 | 51 | ||
| 54 | <style> | 52 | <style> | ... | ... |
-
Please register or login to post a comment