From 9e6266030a6bfc39403c8d344c84e5b9e9d6e520 Mon Sep 17 00:00:00 2001 From: afc163 Date: Wed, 12 Sep 2018 11:25:21 +0800 Subject: [PATCH] code style improve --- src/components/SiderMenu/index.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/components/SiderMenu/index.js b/src/components/SiderMenu/index.js index 7bb4360d..bc803db4 100644 --- a/src/components/SiderMenu/index.js +++ b/src/components/SiderMenu/index.js @@ -19,14 +19,12 @@ const getFlatMenuKeys = menuData => { }; const SiderMenuWrapper = props => { - const { isMobile, menuData, collapsed } = props; + const { isMobile, menuData, collapsed, onCollapse } = props; return isMobile ? ( { - props.onCollapse(true); - }} + onClose={() => onCollapse(true)} style={{ padding: 0, height: '100vh', -- GitLab