From 7a3213a0f984d15e8cb806889ce04b440b3dce0d Mon Sep 17 00:00:00 2001 From: Mitchell McCaffrey Date: Sun, 28 Jun 2020 14:00:36 +1000 Subject: [PATCH] Fix bug with map settings expand disabled --- src/components/map/MapSettings.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/map/MapSettings.js b/src/components/map/MapSettings.js index 1861bd4..79c6742 100644 --- a/src/components/map/MapSettings.js +++ b/src/components/map/MapSettings.js @@ -3,6 +3,8 @@ import { Flex, Box, Label, Input, Checkbox, IconButton } from "theme-ui"; import ExpandMoreIcon from "../../icons/ExpandMoreIcon"; +import { isEmpty } from "../../helpers/shared"; + import Divider from "../Divider"; function MapSettings({ @@ -122,7 +124,7 @@ function MapSettings({ }} aria-label={showMore ? "Show Less" : "Show More"} title={showMore ? "Show Less" : "Show More"} - disabled={!map} + disabled={!map || isEmpty(map)} >