Merged view and update pages according to new design

This commit is contained in:
Pax1601
2024-01-09 17:33:20 +01:00
parent ec91b597c8
commit 5542109daf
21 changed files with 309 additions and 153 deletions

View File

@@ -47,8 +47,7 @@ class Manager {
}
/* Check which buttons should be enabled */
const installEnabled = instances.some((instance) => { return !instance.installed; });
const updateEnabled = instances.some((instance) => { return instance.installed; });
const installEnabled = true;
const manageEnabled = instances.some((instance) => { return instance.installed; });
/* Menu */
@@ -56,7 +55,6 @@ class Manager {
menuPage.options = {
...menuPage.options,
installEnabled: installEnabled,
updateEnabled: updateEnabled,
manageEnabled: manageEnabled
}
/* When the install button is clicked go the installation page */
@@ -64,22 +62,9 @@ class Manager {
menuPage.hide();
installationsPage.show();
}
/* When the update button is clicked go to the instances page in "update mode" (i.e. manage = false) */
menuPage.onUpdateClicked = (e) => {
menuPage.hide();
instancesPage.options = {
...instancesPage.options,
manage: false
}
instancesPage.show();
}
/* When the manage button is clicked go to the instances page in "manage mode" (i.e. manage = true) */
menuPage.onManageClicked = (e) => {
menuPage.hide();
instancesPage.options = {
...instancesPage.options,
manage: true
}
instancesPage.show();
}