"use client" import { useState, useEffect } from "react" import { Button } from "./ui/button" import { Dialog, DialogContent, DialogTitle } from "./ui/dialog" import { X, Sparkles, Thermometer, Terminal, Activity, HardDrive, Bell, Shield, Globe, Cpu, Zap } from "lucide-react" import { Checkbox } from "./ui/checkbox" const APP_VERSION = "1.0.2-beta" // Sync with AppImage/package.json interface ReleaseNote { date: string changes: { added?: string[] changed?: string[] fixed?: string[] } } export const CHANGELOG: Record = { "1.1.2-beta": { date: "March 18, 2026", changes: { added: [ "Temperature & Latency Charts - Real-time visual monitoring with interactive graphs", "WebSocket Terminal - Direct access to Proxmox host and LXC containers terminal", "AI-Enhanced Notifications - Intelligent message formatting with multi-provider support (OpenAI, Groq, Anthropic, Ollama)", "Security Section - Comprehensive security settings for ProxMenux and Proxmox", "VPN Integration - Easy Tailscale VPN installation and configuration", "GPU Scripts - Installation utilities for Intel, AMD and NVIDIA drivers", "Disk Observations System - Track and document disk health observations over time", "Enhanced Health Monitor - Configurable monitoring with advanced settings panel", ], changed: [ "Improved overall performance with optimized data fetching", "Notifications now support rich formatting with contextual emojis", "Health monitor now configurable from Settings section", "Better Proxmox service name translation for non-expert users", ], fixed: [ "Fixed notification message truncation for large backup reports", "Improved disk error deduplication to prevent repeated alerts", "Corrected AI provider base URL handling for OpenAI-compatible APIs", ], }, }, "1.0.1": { date: "November 11, 2025", changes: { added: [ "Proxy Support - Access ProxMenux through reverse proxies with full functionality", "Authentication System - Secure your dashboard with password protection", "PCIe Link Speed Detection - View NVMe drive connection speeds and detect performance issues", "Two-Factor Authentication (2FA) - Enhanced security with TOTP support", "Health Monitoring System - Comprehensive system health checks with dismissible warnings", ], changed: [ "Optimized VM & LXC page - Reduced CPU usage by 85% through intelligent caching", "Storage metrics now separate local and remote storage for clarity", ], fixed: [ "Fixed dark mode text contrast issues in various components", "Corrected storage calculation discrepancies between Overview and Storage pages", ], }, }, "1.0.0": { date: "October 15, 2025", changes: { added: [ "Initial release of ProxMenux Monitor", "Real-time system monitoring dashboard", "Storage management with SMART health monitoring", "Network metrics and bandwidth tracking", "VM & LXC container management", "Hardware information display", "System logs viewer with filtering", ], }, }, } const CURRENT_VERSION_FEATURES = [ { icon: , text: "Temperature & Latency Charts - Real-time visual monitoring with interactive historical graphs", }, { icon: , text: "WebSocket Terminal - Direct terminal access to Proxmox host and LXC containers from the browser", }, { icon: , text: "Enhanced Health Monitor - Configurable health monitoring with advanced settings and disk observations", }, { icon: , text: "AI-Enhanced Notifications - Intelligent message formatting with support for OpenAI, Groq, Anthropic and Ollama", }, { icon: , text: "Security Section - Comprehensive security configuration for both ProxMenux and Proxmox systems", }, { icon: , text: "VPN Integration - Easy Tailscale VPN installation and configuration for secure remote access", }, { icon: , text: "GPU Drivers - Installation scripts for Intel, AMD and NVIDIA graphics drivers and utilities", }, { icon: , text: "Performance Improvements - Optimized data fetching and reduced resource consumption", }, ] interface ReleaseNotesModalProps { open: boolean onClose: () => void } export function ReleaseNotesModal({ open, onClose }: ReleaseNotesModalProps) { const [dontShowAgain, setDontShowAgain] = useState(false) const handleClose = () => { if (dontShowAgain) { localStorage.setItem("proxmenux-last-seen-version", APP_VERSION) } onClose() } return ( Release Notes - Version {APP_VERSION}

What's New in Version {APP_VERSION}

We've added exciting new features and improvements to make ProxMenux Monitor even better!

{CURRENT_VERSION_FEATURES.map((feature, index) => (
{feature.icon}

{feature.text}

))}
setDontShowAgain(checked as boolean)} />
) } export function useVersionCheck() { const [showReleaseNotes, setShowReleaseNotes] = useState(false) useEffect(() => { const lastSeenVersion = localStorage.getItem("proxmenux-last-seen-version") if (lastSeenVersion !== APP_VERSION) { setShowReleaseNotes(true) } }, []) return { showReleaseNotes, setShowReleaseNotes } } export { APP_VERSION }