diff --git a/AppImage/app/layout.tsx b/AppImage/app/layout.tsx index 2dd4be27..3b664966 100644 --- a/AppImage/app/layout.tsx +++ b/AppImage/app/layout.tsx @@ -4,6 +4,7 @@ import { GeistSans } from "geist/font/sans" import { GeistMono } from "geist/font/mono" import { ThemeProvider } from "../components/theme-provider" import { PwaRegister } from "../components/pwa-register" +import { PwaInstallPrompt } from "../components/pwa-install-prompt" import { Suspense } from "react" import "./globals.css" @@ -48,6 +49,7 @@ export default function RootLayout({ + ) diff --git a/AppImage/components/health-status-modal.tsx b/AppImage/components/health-status-modal.tsx index 63ec84a9..c03cb6bb 100644 --- a/AppImage/components/health-status-modal.tsx +++ b/AppImage/components/health-status-modal.tsx @@ -32,6 +32,7 @@ import { FileText, RefreshCw, Shield, + Download, X, Clock, BellOff, @@ -39,6 +40,7 @@ import { Settings2, HelpCircle, } from "lucide-react" +import { ScriptTerminalModal } from "./script-terminal-modal" interface CategoryCheck { status: string @@ -122,6 +124,7 @@ export function HealthStatusModal({ open, onOpenChange, getApiUrl }: HealthStatu const [error, setError] = useState(null) const [dismissingKey, setDismissingKey] = useState(null) const [expandedCategories, setExpandedCategories] = useState>(new Set()) + const [showUpdateTerminal, setShowUpdateTerminal] = useState(false) const fetchHealthDetails = useCallback(async () => { setLoading(true) @@ -722,6 +725,23 @@ export function HealthStatusModal({ open, onOpenChange, getApiUrl }: HealthStatu No issues detected )} + {/* Only offer "Update Now" when the category is not + already OK — hiding it when there's nothing + pending prevents the operator from spawning a + terminal that would only report "System is + already up to date". */} + {key === "updates" && status?.toUpperCase() !== "OK" && ( +
+ +
+ )} )} @@ -848,6 +868,23 @@ export function HealthStatusModal({ open, onOpenChange, getApiUrl }: HealthStatu )} + { + setShowUpdateTerminal(false) + // Refresh health checks so the "System Updates" row updates + // (pending count / kernel version) without waiting for the + // next polling tick after the update finishes. + fetchHealthDetails().catch(() => {}) + }} + scriptPath="/usr/local/share/proxmenux/scripts/utilities/proxmox_update.sh" + scriptName="proxmox_update" + params={{ + EXECUTION_MODE: "web", + }} + title="Proxmox System Update" + description="Runs apt-get update + dist-upgrade and post-update cleanup on the host." + /> ) } diff --git a/AppImage/components/login.tsx b/AppImage/components/login.tsx index 94023370..e1d2d9d9 100644 --- a/AppImage/components/login.tsx +++ b/AppImage/components/login.tsx @@ -271,7 +271,7 @@ export function Login({ onLogin }: LoginProps) { -

ProxMenux Monitor v1.2.3

+

ProxMenux Monitor v1.2.4

) diff --git a/AppImage/components/proxmox-dashboard.tsx b/AppImage/components/proxmox-dashboard.tsx index 41cebcb9..95fd450b 100644 --- a/AppImage/components/proxmox-dashboard.tsx +++ b/AppImage/components/proxmox-dashboard.tsx @@ -836,7 +836,7 @@ export function ProxmoxDashboard() {