From d3edd5fc60ff0278a18acb34f5b74ec2af65ffff Mon Sep 17 00:00:00 2001 From: th1nhng0 Date: Thu, 21 Oct 2021 02:29:54 +0700 Subject: [PATCH] fix reponsive --- src/TreeMenu.js | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/src/TreeMenu.js b/src/TreeMenu.js index 882fe54..59fafac 100644 --- a/src/TreeMenu.js +++ b/src/TreeMenu.js @@ -27,6 +27,16 @@ const useStyles = makeStyles( [theme.breakpoints.up('md')]: { marginTop: '1.5em', }, + transition: theme.transitions.create("width", { + easing: theme.transitions.easing.sharp, + duration: theme.transitions.duration.leavingScreen, + }), + }, + open: { + width: 200, + }, + closed: { + width: 55, }, }), { name: 'RaTreeMenu' } @@ -120,7 +130,7 @@ const Menu = (props) => { else if (resource.name) { resourcename = translate(`resources.${resource.name}.name`); if (resourcename.startsWith('resources.')) - resourcename = geResourceName(resource.name); + resourcename = geResourceName(resource.name); } return resourcename; } @@ -213,7 +223,10 @@ const Menu = (props) => { return (
{hasDashboard && (