From 62459503d875f3aa7e2fa2ca203fdff095193a02 Mon Sep 17 00:00:00 2001 From: Pierre Bertet Date: Fri, 20 Sep 2019 16:33:20 +0100 Subject: [PATCH] Modal: fix the space around (#606) --- src/components/Modal/Modal.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/components/Modal/Modal.js b/src/components/Modal/Modal.js index 5a1b78b76..3fa8234d9 100644 --- a/src/components/Modal/Modal.js +++ b/src/components/Modal/Modal.js @@ -10,6 +10,8 @@ import { ButtonIcon } from '../Button/ButtonIcon' import EscapeOutside from '../EscapeOutside/EscapeOutside' import RootPortal from '../RootPortal/RootPortal' +const SPACE_AROUND = 4 * GU + function Modal({ children, onClose, @@ -68,7 +70,7 @@ function Modal({ >
Math.min(viewport.width - 6 * GU, 600), + width: viewport => Math.min(viewport.width - SPACE_AROUND * 2, 600), } export default Modal