showing info in dashboard
This commit is contained in:
@@ -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()
|
||||
})
|
||||
Reference in New Issue
Block a user