Add tunnel handling in settings

linuztx committed May 15, 2025 at 09:15 UTC 2c37b05381a010e51cd692f2e274f58e4d35b6db
1 file changed +13
webui/js/settings.js
+13
@@ -66,6 +66,19 @@ const settingsModalProxy = {
66 }
67 }
68 }
69 +
70 + // When switching to the tunnel tab, initialize tunnelSettings
71 + if (tabName === 'tunnel') {
72 + console.log('Switching to tunnel tab, initializing tunnelSettings');
73 + const tunnelElement = document.querySelector('[x-data="tunnelSettings"]');
74 + if (tunnelElement) {
75 + const tunnelData = Alpine.$data(tunnelElement);
76 + if (tunnelData && typeof tunnelData.checkTunnelStatus === 'function') {
77 + // Check tunnel status
78 + tunnelData.checkTunnelStatus();
79 + }
80 + }
81 + }
82 }, 10);
83 },
84