import { useLocation } from 'react-router-dom'; import PropTypes from 'prop-types'; import { clsm } from '../../../../utils'; import StreamerPoll from './StreamerPoll'; import ViewerPoll from './ViewerPoll'; import { useResponsiveDevice } from '../../../../contexts/ResponsiveDevice'; import { useChat } from '../../../../contexts/Chat'; import { usePoll } from '../../../../contexts/StreamManagerActions/Poll'; const Poll = ({ shouldRenderInTab }) => { const { pathname } = useLocation(); const { isActive } = usePoll(); const { isModerator } = useChat(); const { isDesktopView, isLandscape } = useResponsiveDevice(); const isStreamManagerPage = pathname === '/manager'; return (