diff --git a/src/components/Frames/TotalFrame/index.js b/src/components/Frames/TotalFrame/index.js index de6489c9..69ffdfda 100644 --- a/src/components/Frames/TotalFrame/index.js +++ b/src/components/Frames/TotalFrame/index.js @@ -1,4 +1,4 @@ -import React from 'react'; +import React, { useEffect, useState } from 'react'; import PropTypes from 'prop-types'; import CircularProgress from '@material-ui/core/CircularProgress'; import { @@ -6,6 +6,7 @@ import { } from '@material-ui/core'; import CheckCircleIcon from '@material-ui/icons/CheckCircle'; import Tooltips from '../../ToolTip/index'; +import InfoModal from '../../InfoModal'; import { useStyles } from './style'; function TotalsDataFrame(props) { @@ -16,6 +17,22 @@ function TotalsDataFrame(props) { height, children, title, toolTipText, toolTipColor, toolTipAriaLabel, isLast, } = props; + const [open, setOpen] = useState(false); + const [mobileView, setMobileView] = useState(false); + const handleOpen = () => mobileView && setOpen(true); + const handleClose = () => setOpen(false); + + useEffect(() => { + const setResponsiveness = () => + window.innerWidth < 1024 + ? setMobileView(true) + : setMobileView(false); + + setResponsiveness(); + + window.addEventListener('resize', () => setResponsiveness()); + }, []); + return ( @@ -27,7 +44,7 @@ function TotalsDataFrame(props) { - + {(toolTipText !== null && toolTipText !== undefined) && ( )} +