diff options
author | bobzel <zzzman@gmail.com> | 2021-02-04 14:44:18 -0500 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2021-02-04 14:44:18 -0500 |
commit | 0590890a43a6ab4fe141324ad04e5cae59333f31 (patch) | |
tree | 0bfff9deecbabf0db4cef3fc99b4c8359daf87db | |
parent | bb63991d0ea67e0f16fd9a3dd35cf8bf472404c7 (diff) |
fixed back/fwd behavior with lightbox
-rw-r--r-- | src/client/views/MainView.tsx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/client/views/MainView.tsx b/src/client/views/MainView.tsx index 9d9698c9c..5873ce650 100644 --- a/src/client/views/MainView.tsx +++ b/src/client/views/MainView.tsx @@ -662,7 +662,8 @@ export class MainView extends React.Component { <div className="mainView-lightBox-navBtn" style={{ top: window.innerHeight / 2 - 12.50 }} onClick={action(e => { e.stopPropagation(); - if (this.lightboxHistory.lastElement() !== this.lightboxFuture.lastElement()) this.lightboxFuture.push(this.lightboxHistory.pop()); + const popped = this.lightboxHistory.pop(); + if (this.lightboxHistory.lastElement() !== this.lightboxFuture.lastElement()) this.lightboxFuture.push(popped); this.LightboxDoc = this.lightboxHistory.lastElement(); })}> <FontAwesomeIcon icon={"chevron-left"} size="3x" /> |