From a774cf0682ba356352f4b5c4d7a8aee659652476 Mon Sep 17 00:00:00 2001 From: ta264 Date: Wed, 1 Sep 2021 21:04:39 +0100 Subject: [PATCH] Fixed: Bookshelf jump bar --- frontend/src/Bookshelf/Bookshelf.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/frontend/src/Bookshelf/Bookshelf.js b/frontend/src/Bookshelf/Bookshelf.js index f8df490fc..c1db2b96f 100644 --- a/frontend/src/Bookshelf/Bookshelf.js +++ b/frontend/src/Bookshelf/Bookshelf.js @@ -289,7 +289,12 @@ class Bookshelf extends Component { } onJumpBarItemPress = (jumpToCharacter) => { - const scrollIndex = getIndexOfFirstCharacter(this.props.items, jumpToCharacter); + const { + items, + sortKey + } = this.props; + + const scrollIndex = getIndexOfFirstCharacter(items, sortKey, jumpToCharacter); if (scrollIndex != null) { this.setState({ scrollIndex });