refactor(layout): 优化页面布局显示逻辑

- 在 App.vue 中使用 route.meta.withoutLayout 替代原有的 route.path 和 route.name判断逻辑
- 在 router/index.ts 和 materialCenter.ts 中为需要独立布局的路由添加 withoutLayout: true 标记
- 更新 router/typeings.d.ts,添加 withoutLayout属性定义
This commit is contained in:
rd
2025-09-15 14:54:55 +08:00
parent e8b16e6541
commit b626f5a35b
4 changed files with 6 additions and 1 deletions

View File

@ -1,6 +1,6 @@
<template>
<ConfigProvider :locale="zhCN" :theme="redTheme">
<router-view v-if="$route.path === '/login' || ['ExploreList', 'ExploreDetail', 'Trial'].includes($route.name)" />
<router-view v-if="$route.meta.withoutLayout" />
<LayoutBasic v-else />
</ConfigProvider>
</template>