Files
halo/ui/console-src/router/routes.config.ts
Ryan Wang 827030dd68 refactor: layout of login related page (#5413)
#### What type of PR is this?

/area ui
/kind improvement
/milestone 2.13.0

#### What this PR does / why we need it:

优化登录相关页面的布局,修复在不同分辨率下的样式问题。

#### Which issue(s) this PR fixes:

Fixes https://github.com/halo-dev/halo/issues/5346

#### Special notes for your reviewer:

测试登录或者注册页面,任意放大或者缩小页面,观察页面样式是否正常。

#### Does this PR introduce a user-facing change?

```release-note
优化登录相关页面的布局,修复在不同分辨率下的样式问题。
```
2024-02-27 10:21:14 +00:00

102 lines
2.2 KiB
TypeScript

import type { RouteRecordRaw } from "vue-router";
import NotFound from "@/views/exceptions/NotFound.vue";
import Forbidden from "@/views/exceptions/Forbidden.vue";
import BasicLayout from "@console/layouts/BasicLayout.vue";
import GatewayLayout from "@console/layouts/GatewayLayout.vue";
import Setup from "@console/views/system/Setup.vue";
import Redirect from "@console/views/system/Redirect.vue";
import SetupInitialData from "@console/views/system/SetupInitialData.vue";
import ResetPassword from "@console/views/system/ResetPassword.vue";
import Login from "@console/views/system/Login.vue";
import Binding from "@console/views/system/Binding.vue";
export const routes: Array<RouteRecordRaw> = [
{
path: "/:pathMatch(.*)*",
component: BasicLayout,
children: [{ path: "", name: "NotFound", component: NotFound }],
},
{
path: "/403",
component: BasicLayout,
children: [
{
path: "",
name: "Forbidden",
component: Forbidden,
},
],
},
{
path: "/login",
component: GatewayLayout,
children: [
{
path: "",
name: "Login",
component: Login,
meta: {
title: "core.login.title",
},
},
],
},
{
path: "/binding/:provider",
component: GatewayLayout,
children: [
{
path: "",
name: "Binding",
component: Binding,
meta: {
title: "core.binding.title",
},
},
],
},
{
path: "/setup",
component: GatewayLayout,
children: [
{
path: "",
name: "Setup",
component: Setup,
meta: {
title: "core.setup.title",
},
},
],
},
{
path: "/setup-initial-data",
name: "SetupInitialData",
component: SetupInitialData,
meta: {
title: "core.setup.title",
},
},
{
path: "/redirect",
name: "Redirect",
component: Redirect,
},
{
path: "/reset-password",
component: GatewayLayout,
children: [
{
path: "",
name: "ResetPassword",
component: ResetPassword,
meta: {
title: "core.reset_password.title",
},
},
],
},
];
export default routes;