Files
winutil/functions/microwin/Toggle-MicrowinPanel.ps1
MyDrift e74258acf4 [Microwin] Fix & Cleanup UI (#3426)
* hide MicrowinISOPanel on proceeding steps

* fix textbox styling + remove Password text

* MicroWinPanelToggling
2025-06-26 12:21:49 -05:00

29 lines
878 B
PowerShell

function Toggle-MicrowinPanel {
<#
.SYNOPSIS
Toggles the visibility of the Microwin options and ISO panels in the GUI.
.DESCRIPTION
This function toggles the visibility of the Microwin options and ISO panels in the GUI.
.PARAMETER MicrowinOptionsPanel
The panel containing Microwin options.
.PARAMETER MicrowinISOPanel
The panel containing the Microwin ISO options.
.EXAMPLE
Toggle-MicrowinPanel 1
#>
param (
[Parameter(Mandatory = $true, Position = 0)]
[ValidateSet(1, 2)]
[int]$PanelNumber
)
if ($PanelNumber -eq 1) {
$sync.MicrowinISOPanel.Visibility = 'Visible'
$sync.MicrowinOptionsPanel.Visibility = 'Collapsed'
} elseif ($PanelNumber -eq 2) {
$sync.MicrowinOptionsPanel.Visibility = 'Visible'
$sync.MicrowinISOPanel.Visibility = 'Collapsed'
}
}