diff --git a/Documents/Vibe Coding Projects/dedicatednodes-redesign/dedicatednodes-bare-metal/new-baremetal.html b/Documents/Vibe Coding Projects/dedicatednodes-redesign/dedicatednodes-bare-metal/new-baremetal.html index 8ab6aa4..2d0b3c4 100644 --- a/Documents/Vibe Coding Projects/dedicatednodes-redesign/dedicatednodes-bare-metal/new-baremetal.html +++ b/Documents/Vibe Coding Projects/dedicatednodes-redesign/dedicatednodes-bare-metal/new-baremetal.html @@ -4122,7 +4122,27 @@ var wpcf7 = { isInstantCustomized = false; document.getElementById('instantOptions').style.display = 'none'; document.getElementById('instantServersGrid').style.display = 'grid'; + + // Clear the customization container to avoid conflicts + const instantContainer = document.getElementById('instantDynamicConfigContainer'); + if (instantContainer) instantContainer.innerHTML = ''; + + // Reset config state to clean values + configState = {}; + configIds = {}; + storageSelection = {}; + + // Clear any original drives tracking + if (window.originalDrives) { + window.originalDrives = []; + } + + // Re-render the instant servers grid to ensure proper display + renderInstantServers(); + + // Update summary and specs for the selected instant server updateSummary(); + updateSpecs(selectedServer); } // Customize Instant Server Button Logic @@ -5332,8 +5352,32 @@ var wpcf7 = { document.getElementById('instant-content').classList.toggle('active', currentTab === 'instant'); document.getElementById('custom-content').classList.toggle('active', currentTab === 'custom'); - selectedServer = null; + // Reset customization state when switching + isInstantCustomized = false; + document.getElementById('instantOptions').style.display = 'none'; + document.getElementById('instantServersGrid').style.display = 'grid'; document.getElementById('customOptions').style.display = 'none'; + + // Clear containers + const instantContainer = document.getElementById('instantDynamicConfigContainer'); + if (instantContainer) instantContainer.innerHTML = ''; + + // Reset config state + configState = {}; + configIds = {}; + storageSelection = {}; + + // If switching back to instant tab, re-render instant servers + if (currentTab === 'instant') { + renderInstantServers(); + // Auto-select first instant server if none selected + if (!selectedServer && instantServers.length > 0) { + selectInstantServer(instantServers[0].id); + } + } else { + selectedServer = null; + } + updateSummary(); }); });