Skip to content

Commit dd6c8e6

Browse files
committed
style background
1 parent cb70499 commit dd6c8e6

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

frontend/javascripts/admin/account/account_settings_view.tsx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { SafetyOutlined, SettingOutlined, UserOutlined } from "@ant-design/icons";
22
import { Breadcrumb, Layout, Menu } from "antd";
33
import type { MenuItemGroupType } from "antd/es/menu/interface";
4-
import { Route, Switch, useHistory, useLocation } from "react-router-dom";
4+
import { Redirect, Route, Switch, useHistory, useLocation } from "react-router-dom";
55
import AccountAuthTokenView from "./account_auth_token_view";
66
import AccountPasswordView from "./account_password_view";
77
import AccountProfileView from "./account_profile_view";
@@ -50,17 +50,19 @@ function AccountSettingsView() {
5050
];
5151

5252
return (
53-
<Layout style={{ minHeight: "calc(100vh - 64px)" }} className="container">
53+
<Layout
54+
style={{ minHeight: "calc(100vh - 64px)", backgroundColor: "var(--ant-layout-body-bg)" }}
55+
>
5456
<Sider width={200}>
5557
<Menu
5658
mode="inline"
5759
selectedKeys={[selectedKey]}
58-
style={{ height: "100%" }}
60+
style={{ height: "100%", padding: 24 }}
5961
items={menuItems}
6062
onClick={({ key }) => history.push(`/account/${key}`)}
6163
/>
6264
</Sider>
63-
<Content style={{ padding: "24px", paddingTop: 0, minHeight: 280, maxWidth: 1000 }}>
65+
<Content style={{ padding: "24px", minHeight: 280, maxWidth: 1000 }}>
6466
<Breadcrumb style={{ marginBottom: "16px", padding: "8px 0" }}>
6567
<Breadcrumb.Item>Account Settings</Breadcrumb.Item>
6668
<Breadcrumb.Item>
@@ -71,7 +73,7 @@ function AccountSettingsView() {
7173
<Route path="/account/profile" component={AccountProfileView} />
7274
<Route path="/account/password" component={AccountPasswordView} />
7375
<Route path="/account/token" component={AccountAuthTokenView} />
74-
<Route path="/account" component={AccountProfileView} />
76+
<Route path="/account" render={() => <Redirect to="/account/profile" />} />
7577
</Switch>
7678
</Content>
7779
</Layout>

0 commit comments

Comments
 (0)