提交 233b4fb7 编写于 作者: Q qixian.cs@outlook.com

fix meun border style

上级 81d47bc2
import { getMenuMatches } from './BaseMenu';
const menu = ['/dashboard', '/userinfo', '/dashboard/name', '/userinfo/:id', '/userinfo/:id/info'];
describe('test menu match', () => {
it('simple path', () => {
expect(getMenuMatches(menu, '/dashboard')).toEqual(['/dashboard']);
});
it('error path', () => {
expect(getMenuMatches(menu, '/dashboardname')).toEqual([]);
});
it('Secondary path', () => {
expect(getMenuMatches(menu, '/dashboard/name')).toEqual(['/dashboard/name']);
});
it('Parameter path', () => {
expect(getMenuMatches(menu, '/userinfo/2144')).toEqual(['/userinfo/:id']);
});
it('three parameter path', () => {
expect(getMenuMatches(menu, '/userinfo/2144/info')).toEqual(['/userinfo/:id/info']);
});
});
import { urlToList } from '../_utils/pathTools';
import { getFlatMenuKeys, getMenuMatchKeys } from './SiderMenu';
import { getFlatMenuKeys, getMenuMatchKeys } from './SliderMenu';
const menu = [
{
......
import 'rc-drawer/assets/index.css';
import React from 'react';
import DrawerMenu from 'rc-drawer';
import SiderMenu from './SiderMenu';
import SiderMenu from './SliderMenu';
/**
* Recursively flatten the data
......
......@@ -16,7 +16,7 @@ export default class TopNavHeader extends PureComponent {
<h1>Ant Design Pro</h1>
</Link>
</div>
<BaseMenu {...this.props} style={{ padding: '9px 0', border: 'none' }} />
<BaseMenu {...this.props} style={{ paddingTop: '9px', border: 'none' }} />
</div>
<div className={styles.right}>
<RightContent {...this.props} />
......
......@@ -5,6 +5,14 @@
padding: 0 12px 0 0;
box-shadow: 0 1px 4px rgba(0, 21, 41, 0.08);
position: relative;
:global {
.ant-menu-submenu.ant-menu-submenu-horizontal {
height: 100%;
.ant-menu-submenu-title {
height: 100%;
}
}
}
&.light {
background-color: #fff;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册