// Central mutable state for the dashboard. // All modules read/write these variables directly (plain-script shared globals). const SETTINGS_DEFAULTS = { proxyPort: 8443, connectProxyPort: 8442, readyTimeoutMs: 30000, notifyOnDisconnect: true, notifyOnTunnelError: true, debug: false, disableOnFileUrls: false, backupRetention: 5, backupIntervalHours: 0, tunnelAutoReconnect: false, latencyPingEnabled: true, latencyPingIntervalMs: 5000 }; let currentState = null; let settings = { ...SETTINGS_DEFAULTS };