diff --git a/src/components/Layout/Header.less b/src/components/Layout/Header.less index bb8eb96..9312ad2 100644 --- a/src/components/Layout/Header.less +++ b/src/components/Layout/Header.less @@ -1,20 +1,55 @@ @import "~themes/vars"; .header { - :global .ant-menu-horizontal { - & > .ant-menu-submenu { - float: right; + :global { + .ant-menu-submenu-title { + height: 56px; + } + + .ant-menu-horizontal { + line-height: 56px; + + & > .ant-menu-submenu:hover { + color: #1890ff; + background-color: rgba(24, 144, 255, 0.15); + } + } + + .ant-menu { + border-bottom: none; + height: 56px; + } + + .ant-menu-horizontal > .ant-menu-submenu { + top: 0; + margin-top: 0; + } + + .ant-menu-horizontal > .ant-menu-item, + .ant-menu-horizontal > .ant-menu-submenu { + border-bottom: none; + } + + .ant-menu-horizontal > .ant-menu-item-active, + .ant-menu-horizontal > .ant-menu-item-open, + .ant-menu-horizontal > .ant-menu-item-selected, + .ant-menu-horizontal > .ant-menu-item:hover, + .ant-menu-horizontal > .ant-menu-submenu-active, + .ant-menu-horizontal > .ant-menu-submenu-open, + .ant-menu-horizontal > .ant-menu-submenu-selected, + .ant-menu-horizontal > .ant-menu-submenu:hover { + border-bottom: none; } - border: none; - display: inline-block; } box-shadow: @shadow-2; position: relative; display: flex; justify-content: space-between; - height: 47px; + height: 56px; + z-index: 9; + display: flex; + align-items: center; background-color: #fff; - z-index: 999; .rightWarpper { display: flex; @@ -22,9 +57,9 @@ } .button { - width: 47px; - height: 47px; - line-height: 47px; + width: 56px; + height: 56px; + line-height: 56px; text-align: center; font-size: 18px; cursor: pointer; diff --git a/src/components/Layout/Layout.less b/src/components/Layout/Layout.less index 1281d26..d750bbd 100644 --- a/src/components/Layout/Layout.less +++ b/src/components/Layout/Layout.less @@ -2,12 +2,13 @@ :global { - .ant-layout-header{ + .ant-layout-header { padding: 0; } - .ant-layout-sider{ - transition: all .3s; + .ant-layout-sider { + transition: all 0.3s; + .ant-menu-root { height: ~"calc(100vh - 144px)"; overflow-x: hidden; @@ -32,29 +33,58 @@ } } } - .ant-layout-content{ + + .ant-layout-content { padding: 24px; } - .ant-layout-footer{ + .ant-layout-footer { text-align: center; padding: 24px; } .content-inner { - background: #fff; - padding: 24px; - box-shadow: @shadow-1; - min-height: e("calc(100vh - 184px)"); - } + background: #fff; + padding: 24px; + box-shadow: @shadow-1; + min-height: e("calc(100vh - 184px)"); + } + + .ant-back-top { + right: 50px; + } + + .ant-switch { + + } + +.ant-switch.ant-switch-large{ + line-height: 24px; + height: 26px; + &:after, + &:before { + width: 22px; + height: 22px; + } + + &.ant-switch-checked:after, + &.ant-switch-checked:before { + margin-left: -23px; + } + } +.flex-vertical-center{ + display: flex; + align-items: center } +} .logo { height: 96px; display: flex; align-items: center; justify-content: center; + img { width: 40px; margin-right: 8px; @@ -64,7 +94,7 @@ vertical-align: text-bottom; font-size: 16px; text-transform: uppercase; - display: inline-block + display: inline-block; } } @@ -81,7 +111,7 @@ padding: 0 16px; overflow: hidden; z-index: 9; - transition: all .3s; + transition: all 0.3s; span { white-space: nowrap; @@ -98,9 +128,9 @@ } } - .bread { margin-bottom: 24px; + :global { .ant-breadcrumb { display: flex; @@ -109,10 +139,10 @@ } } -.dark{ +.dark { .switchtheme { background-color: #000d18; - border-color: #001629; + border-color: #001629; } } @@ -123,7 +153,6 @@ } } } - @media (max-width: 767px) { .bread { margin-bottom: 12px; @@ -134,10 +163,9 @@ padding: 12px; } - .ant-back-top{ + .ant-back-top { right: 20px; bottom: 20px; } - } } diff --git a/src/components/Layout/Sider.less b/src/components/Layout/Sider.less deleted file mode 100644 index 3ace2a6..0000000 --- a/src/components/Layout/Sider.less +++ /dev/null @@ -1 +0,0 @@ -@import "~themes/vars"; diff --git a/src/routes/login/index.less b/src/routes/login/index.less index 1ebd563..6af9d4a 100644 --- a/src/routes/login/index.less +++ b/src/routes/login/index.less @@ -1,51 +1,49 @@ -.form { - position: absolute; - top: 50%; - left: 50%; - margin: -160px 0 0 -160px; - width: 320px; - height: 320px; - padding: 36px; - box-shadow: 0 0 100px rgba(0,0,0,.08); - - button { - width: 100%; - } - - p { - color: rgb(204, 204, 204); - text-align: center; - margin-top: 16px; - - span { - &:first-child { - margin-right: 16px; - } - } - } -} - -.logo { - text-align: center; - height: 40px; - line-height: 40px; - cursor: pointer; - margin-bottom: 24px; - - img { - width: 40px; - margin-right: 8px; - } - - span { - vertical-align: text-bottom; - font-size: 16px; - text-transform: uppercase; - display: inline-block; - } -} - -.ant-spin-container, -.ant-spin-nested-loading { - height: 100%; -} +.form { + position: absolute; + top: 50%; + left: 50%; + margin: -160px 0 0 -160px; + width: 320px; + height: 320px; + padding: 36px; + box-shadow: 0 0 100px rgba(0,0,0,.08); + + button { + width: 100%; + } + + p { + color: rgb(204, 204, 204); + text-align: center; + margin-top: 16px; + font-size: 12px; + display: flex; + justify-content: space-between; + } +} + +.logo { + text-align: center; + cursor: pointer; + margin-bottom: 24px; + display: flex; + justify-content: center; + align-items: center; + + img { + width: 40px; + margin-right: 8px; + } + + span { + vertical-align: text-bottom; + font-size: 16px; + text-transform: uppercase; + display: inline-block; + } +} + +.ant-spin-container, +.ant-spin-nested-loading { + height: 100%; +} diff --git a/src/routes/user/Filter.js b/src/routes/user/Filter.js index 15809ee..8cc5354 100644 --- a/src/routes/user/Filter.js +++ b/src/routes/user/Filter.js @@ -5,7 +5,7 @@ import { FilterItem } from 'components' import { Form, Button, Row, Col, DatePicker, Input, Cascader, Switch } from 'antd' import city from '../../utils/city' -const Search = Input.Search +const { Search } = Input const { RangePicker } = DatePicker const ColProps = { @@ -98,12 +98,12 @@ const Filter = ({