Skip to content

Commit

Permalink
fixing extra padding issue with footer section and overlays component…
Browse files Browse the repository at this point in the history
… getters / setters issue
  • Loading branch information
Jakidxav committed Aug 29, 2024
1 parent 54fc90b commit 28603c7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 27 deletions.
6 changes: 1 addition & 5 deletions components/sidebar/footer.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { Box, Text } from 'theme-ui'
import { Link } from '@carbonplan/components'
import { alpha } from '@theme-ui/color'
import { SidebarDivider } from '@carbonplan/layouts'

// This component is modeled after the SidebarFooter component:
// https://github.com/carbonplan/layouts/blob/main/src/sidebar/sidebar-footer.js
Expand All @@ -13,12 +12,9 @@ const sx = {
}
}

const Footer = ({ showRegionPicker }) => {
const Footer = () => {
return (
<>
{showRegionPicker && (
<SidebarDivider sx={{ width: '100%', my: 2}} />
)}
<Box sx={{
px: [0, 4, 4, 0],
pt: [0, 4, 4, 0],
Expand Down
23 changes: 1 addition & 22 deletions components/sidebar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,6 @@ const Sidebar = ({ getters, setters, showAbout, toggleAbout }) => {
</ExpandingSection>
<SidebarDivider sx={{ width: '100%', my: 4 }} />

{/* <ExpandingSection label='Charts' onClick={() => setShowRegionPicker(!showRegionPicker)} />
<SidebarDivider sx={{ width: '100%', my: 4 }} /> */}

<ExpandingSection
label='Charts'
expanded={showRegionPicker}
Expand All @@ -148,25 +145,7 @@ const Sidebar = ({ getters, setters, showAbout, toggleAbout }) => {
</Box>
)}
</ExpandingSection>
<SidebarDivider sx={{ width: '100%', my: 4 }} />

{/* {showRegionPicker && new Date(time) <= new Date(maxDate) && (
<Box sx={{ ...sx.stats }}>
<SummaryStats
variable={variable}
time={time}
year={year}
monthDay={monthDay}
minDate={minDate}
regionData={regionData}
showRegionPicker={showRegionPicker}
colormap={colormap}
hexmapBar={hexmapBar}
hexmapTime={hexmapTime}
sliding={sliding}
/>
</Box>
)} */}
<SidebarDivider sx={{ width: '100%', mt: 4 }} />

<Footer />
</Box>
Expand Down

0 comments on commit 28603c7

Please sign in to comment.