Scroll down after successful pass creation

This commit is contained in:
Marvin Sextro 2021-12-29 01:11:13 +01:00
parent 4f30b9b326
commit 931b0806f9
1 changed files with 3 additions and 0 deletions

View File

@ -191,6 +191,9 @@ function Form(): JSX.Element {
const passBlob = new Blob([pass], {type: "application/vnd.apple.pkpass"});
saveAs(passBlob, 'covid.pkpass');
setLoading(false);
var scrollingElement = (document.scrollingElement || document.body);
scrollingElement.scrollTop = scrollingElement.scrollHeight;
} catch (e) {
setErrorMessage(e.message);
setLoading(false);