Add a 'What's New?' tab as a core plugin, which fetches the contents of CHANGES.md from the app's release branch

This commit is contained in:
cmdr2
2022-11-16 16:54:28 +05:30
parent f7ec9f2073
commit 18d9d2602a
5 changed files with 61 additions and 7 deletions

View File

@ -1284,7 +1284,7 @@ document.querySelectorAll('.popup').forEach(popup => {
})
var tabElements = [];
document.querySelectorAll(".tab").forEach(tab => {
function linkTabContents(tab) {
var name = tab.id.replace("tab-", "");
var content = document.getElementById(`tab-content-${name}`)
tabElements.push({
@ -1305,7 +1305,9 @@ document.querySelectorAll(".tab").forEach(tab => {
content.classList.toggle("active")
}
})
})
}
document.querySelectorAll(".tab").forEach(linkTabContents)
window.addEventListener("beforeunload", function(e) {
const msg = "Unsaved pictures will be lost!";