componentDidUpdate() {
        if (this.tableRef.current) {
            const scrollBarWidth = this.tableRef.current.offsetWidth - this.tableRef.current.clientWidth;
            if (this.state.scrollBarWidth !== scrollBarWidth) {
                setTimeout(() => this.setState({ scrollBarWidth }), 100);
            } else {
                if (!this.selectedFound && ((this.state.selected && this.state.selected[0]) || this.lastSelectedItems)) {
                    const node = window.document.getElementById((this.state.selected && this.state.selected[0]) || this.lastSelectedItems);
                    node && node.scrollIntoView();
                    this.selectedFound = true;
                }
            }
        }
    }
/**
     * Called when component is updated.
     */
Called when component is updated.
Called when component is updated .
componentDidUpdate() {
        if (this.tableRef.current) {
            const scrollBarWidth = this.tableRef.current.offsetWidth - this.tableRef.current.clientWidth;
            if (this.state.scrollBarWidth !== scrollBarWidth) {
                setTimeout(() => this.setState({ scrollBarWidth }), 100);
            } else {
                if (!this.selectedFound && ((this.state.selected && this.state.selected[0]) || this.lastSelectedItems)) {
                    const node = window.document.getElementById((this.state.selected && this.state.selected[0]) || this.lastSelectedItems);
                    node && node.scrollIntoView();
                    this.selectedFound = true;
                }
            }
        }
    }
componentDidUpdate ( ) { if ( this . tableRef . current ) { const scrollBarWidth = this . tableRef . current . offsetWidth - this . tableRef . current . clientWidth ; if ( this . state . scrollBarWidth !== scrollBarWidth ) { setTimeout ( ( ) => this . setState ( { scrollBarWidth } ) , 100 ) ; } else { if ( ! this . selectedFound && ( ( this . state . selected && this . state . selected [ 0 ] ) || this . lastSelectedItems ) ) { const node = window . document . getElementById ( ( this . state . selected && this . state . selected [ 0 ] ) || this . lastSelectedItems ) ; node && node . scrollIntoView ( ) ; this . selectedFound = true ; } } } }
Called when component is updated.
Called when component is updated .