Open uijaswanthi opened 5 years ago
From the below example i understood that isVisible will return true even if div element visible partially because I added partialVisibility prop. But is there any way i can say if div element is partially visible or fully visible?
<VisibilitySensor key={list} partialVisibility containment={containmentDOMRect}> {({ isVisible }) => { return ( <div style={{ height: 100, lineHeight: "100px", color: "white", backgroundColor: isVisible ? "green" : "red", margin: 5 }} > I am #{list} </div>); }} </VisibilitySensor>
From the below example i understood that isVisible will return true even if div element visible partially because I added partialVisibility prop. But is there any way i can say if div element is partially visible or fully visible?