diff --git a/src/components/Login/index.js b/src/components/Login/index.js index 0f304c5b9b74c7cf76734e39a748bbc38591b663..5e3a8a86b7cb2dbe567a8fb7e52e5aa3184d21e0 100644 --- a/src/components/Login/index.js +++ b/src/components/Login/index.js @@ -89,7 +89,7 @@ class Login extends Component { } }); return ( -
+
{ tabs.length ? ( diff --git a/src/components/Login/index.less b/src/components/Login/index.less index 4f1f226897bc21af04adf3b96988da29eec31b78..331ed5a62e9d8752b0274559fd7bfa3d8b2a458a 100644 --- a/src/components/Login/index.less +++ b/src/components/Login/index.less @@ -1,8 +1,6 @@ @import "~antd/lib/style/themes/default.less"; -.main { - width: 368px; - margin: 0 auto; +.login { .tabs { padding: 0 2px; diff --git a/src/index.less b/src/index.less index 98651b12ef14fa457b236b9ec83f6949ba072ffb..5cfe914a4cec038c252fa4f0069e50b11b8cc6cc 100644 --- a/src/index.less +++ b/src/index.less @@ -4,6 +4,10 @@ body, height: 100%; } +:global(.ant-layout) { + min-height: 100%; +} + canvas { display: block; } diff --git a/src/layouts/BasicLayout.js b/src/layouts/BasicLayout.js index 59b254cfe49ee650bf85ead7221c1cbb20d09fcc..584848038c11e6256236c4eed67e6c44bc2f2c89 100644 --- a/src/layouts/BasicLayout.js +++ b/src/layouts/BasicLayout.js @@ -177,55 +177,53 @@ class BasicLayout extends React.PureComponent { onNoticeVisibleChange={this.handleNoticeVisibleChange} /> -
- - { - redirectData.map(item => - - ) - } - { - getRoutes(match.path, routerData).map(item => - ( - - ) + + { + redirectData.map(item => + + ) + } + { + getRoutes(match.path, routerData).map(item => + ( + ) - } - - - -
- , - href: 'https://github.com/ant-design/ant-design-pro', - blankTarget: true, - }, { - key: 'Ant Design', - title: 'Ant Design', - href: 'http://ant.design', - blankTarget: true, - }]} - copyright={ -
- Copyright 2018 蚂蚁金服体验技术部出品 -
+ ) } - /> + + +
+ , + href: 'https://github.com/ant-design/ant-design-pro', + blankTarget: true, + }, { + key: 'Ant Design', + title: 'Ant Design', + href: 'http://ant.design', + blankTarget: true, + }]} + copyright={ +
+ Copyright 2018 蚂蚁金服体验技术部出品 +
+ } + /> ); diff --git a/src/layouts/UserLayout.js b/src/layouts/UserLayout.js index 01228a51f6b1c1952ce761b7674c3ac417aeddbd..946fc953692b7e43a3e1cd876b95369603f4f824 100644 --- a/src/layouts/UserLayout.js +++ b/src/layouts/UserLayout.js @@ -38,29 +38,31 @@ class UserLayout extends React.PureComponent { return (
-
-
- - logo - Ant Design - +
+
+
+ + logo + Ant Design + +
+
Ant Design 是西湖区最具影响力的 Web 设计规范
-
Ant Design 是西湖区最具影响力的 Web 设计规范
+ + {getRoutes(match.path, routerData).map(item => + ( + + ) + )} + +
- - {getRoutes(match.path, routerData).map(item => - ( - - ) - )} - - - +
); diff --git a/src/layouts/UserLayout.less b/src/layouts/UserLayout.less index 983c2bcead7e9e155e4d4fb147a1ce3bdb96d1b6..c93cf779625b57eafcf4a8d4fe09da0d764ec52c 100644 --- a/src/layouts/UserLayout.less +++ b/src/layouts/UserLayout.less @@ -1,15 +1,27 @@ @import "~antd/lib/style/themes/default.less"; .container { - background: #f0f2f5; - background-image: url('https://gw.alipayobjects.com/zos/rmsportal/TVYTbAXWheQpRcWDaDMu.svg'); - width: 100%; + display: flex; + flex-direction: column; min-height: 100%; - background-repeat: no-repeat; - background-position: center; - background-size: 100%; - padding: 110px 0 144px 0; - position: relative; +} + +.content { + padding: 32px 0; + flex: 1; +} + +@media (min-width: @screen-md-min) { + .container { + background-image: url('https://gw.alipayobjects.com/zos/rmsportal/TVYTbAXWheQpRcWDaDMu.svg'); + background-repeat: no-repeat; + background-position: center 110px; + background-size: 100%; + } + + .content { + padding: 112px 0 24px 0; + } } .top { @@ -45,9 +57,3 @@ margin-top: 12px; margin-bottom: 40px; } - -.footer { - position: absolute; - width: 100%; - bottom: 0; -}