Initialise in edit mode when hash is empty

This commit is contained in:
Mikko Ahlroth 2022-10-28 23:48:59 +03:00
parent b3658724ca
commit 7c809b189e
2 changed files with 5 additions and 1 deletions

View file

@ -35,7 +35,7 @@
<div id="length">Waiting...</div>
<div id="info">
v2.0.0 | © Nicd 2022 | <a href="https://gitlab.com/Nicd/tahnaroskakori" target="_blank">Source</a> | <a
v2.0.1 | © Nicd 2022 | <a href="https://gitlab.com/Nicd/tahnaroskakori" target="_blank">Source</a> | <a
href="./licenses.txt" target="_blank">Licenses</a>
</div>
</footer>

View file

@ -283,6 +283,10 @@ async function init() {
viewModeSwitcherEl = document.getElementById("view-mode-switcher");
languageSelectEl = document.getElementById("language-select");
if (window.location.hash.length <= 1) {
viewMode = ViewMode.EDIT;
}
renderLanguageOptions();
renderView();