diff --git a/StackMonkey.ps1 b/StackMonkey.ps1 index 215d24c..d314222 100644 --- a/StackMonkey.ps1 +++ b/StackMonkey.ps1 @@ -540,33 +540,29 @@ function Build-Checkboxes { ( $Global:Tasks | - Where-Object Page -EQ $Page | + Where-Object Page -EQ $Page | Where-Object Column -EQ $Column | ForEach-Object { - $taskId = $_.Id + $taskId = $_.Id + $tooltip = if ($_.PSObject.Properties.Name -contains 'Tooltip' -and $_.Tooltip) { + " title='$($_.Tooltip)'" + } else { '' } - # if the task has a Tooltip property, build a title attribute - $titleAttr = if ($_.PSObject.Properties.Name -contains 'Tooltip' -and $_.Tooltip) { - " title='$($_.Tooltip)'" - } else { - '' - } - - # inject the title attribute into the " + $html = " $($_.Label)" if ($_.SubOptions) { - $subHtml = $_.SubOptions | ForEach-Object { - "" - } -join "`n" + # join inside the code‐block is fine + $subHtml = $_.SubOptions | + ForEach-Object { + "" + } -join "`n" $html += @" - "@ } @@ -576,6 +572,7 @@ $subHtml } + ### Get SVSMSP module version to display in the UI function Get-ModuleVersionHtml { $mod = Get-Module -ListAvailable -Name SVSMSP | Sort-Object Version -Descending | Select-Object -First 1