update styles and html for online mods page, add open external link function

This commit is contained in:
2026-01-20 20:32:35 +01:00
parent 43ad575e75
commit d647fcefc2
6 changed files with 64 additions and 6 deletions

View File

@@ -48,6 +48,14 @@ async function navigate(page) {
for(let i = 0; i <= 10; i++) {
const modTemplateCopy = modTemplate.content.cloneNode(true)
const modLinkButton = modTemplateCopy.getElementById("external-link")
modLinkButton.addEventListener('click', function(event) {
event.preventDefault()
const modLink = modLinkButton.href
electronAPI.openExternalLink(modLink)
})
ModsContainer.appendChild(modTemplateCopy)
}
break;
@@ -103,4 +111,8 @@ async function exportData() {
async function importData() {
await files.import()
document.getElementById("silksong-path-input").value = await save.loadSilksongPath()
}
async function downloadMod() {
console.log("WIP")
}