twobin/react-lazyload

not working if container element is in fullscreen mode

JoenZhu opened this issue · 1 comments

My code just like this

function A ()  {
  const [imgs] = React.useState(Array(20).fill('').map((_, i) => i))

  const fullscreen = React.useCallback(() => {
    const container = document.querySelector('#container');
    container.requestFullscreen();
  }, []);

  return (
    <div id="container" onClick={fullscreen}>
      {imgs.map((img, index) => (
        <LazyLoad height={200}> key={index}>
          <Img />
        </LazyLoad>
      ))}
    </div>
  )
}

when container element on fullscreen mode, LazyLoad will not working