Skip to content
This repository was archived by the owner on Jun 10, 2020. It is now read-only.
This repository was archived by the owner on Jun 10, 2020. It is now read-only.

Problem when using with React-Custom-Scrollbars #285

@enesyteam

Description

@enesyteam

Hi,

I'm using your library with react-custom-scrollbars and having an issue. This is my code:

<Scrollbars className="custom__scrollbars" height={ this.state.windowHeight - 54 } ref="conversationlistscroll" renderThumbVertical={props => <div {...props} className="c-scrollbar__bar"/>} renderTrackVertical={props => <div {...props} className="c-scrollbar__track"/>} renderTrackHorizontal={props => <div {...props} className="track-horizontal" style={{display:"none"}}/>} renderThumbHorizontal={props => <div {...props} className="thumb-horizontal" style={{display:"none"}}/>} autoHide autoHideTimeout={ 1000 } autoHideDuration={ 200 } onScroll={ this.handleScroll } > <Infinite elementHeight={ 80 } useWindowAsScrollContainer infiniteLoadBeginEdgeOffset={ 100 } onInfiniteLoad={this.handleInfiniteLoad} isInfiniteLoading={this.state.isInfiniteLoading} ref="mylist" > { conversations.length > 0 && conversations.map( this.renderConversation ) } </Infinite> </Scrollbars>

And this is handleScroll method:

handleScroll = () => { let scollTop = this.refs.conversationlistscroll.getScrollTop(); this.refs.mylist.handleScroll( scollTop ); }

Infinite load is OK for the first time infinite load:
1111

But when the second infinite load has error:

222222

Can you tell me how to resolve this problem, thanks you very much!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions