showing info in dashboard

This commit is contained in:
metacryst
2026-01-12 17:24:45 -06:00
parent 63304bd281
commit 942e479185
6 changed files with 125 additions and 7 deletions

View File

@@ -20,7 +20,7 @@ window.addEventListener("navigate", () => {
if(window.currentApp !== selectedApp()) {
window.currentApp = selectedApp()
const event = new CustomEvent('appchanged', {
const event = new CustomEvent('appchange', {
detail: { name: window.currentApp }
});
window.dispatchEvent(event)
@@ -56,7 +56,7 @@ window.openApp = function(appName) {
console.log(newPath)
window.navigateTo(newPath)
// window.history.replaceState({}, '', newPath);
const event = new CustomEvent('appchanged', {
const event = new CustomEvent('appchange', {
detail: { name: appName }
});
window.dispatchEvent(event)
@@ -82,7 +82,7 @@ async function getProfile() {
}
}
getProfile().then(() => {
getProfile().then(async () => {
let path = "";
let defaultNetwork = window.profile.networks[0]
@@ -95,6 +95,10 @@ getProfile().then(() => {
path += defaultApp.toLowerCase()
}
let appData = await fetch("/app/comaldata", {method: "GET"})
let json = await appData.json()
window.comalData = json
window.navigateTo(path)
Home()
})