Hyperlinks in UDTables

Here is a working example of a modal popup inside a grid

Get-UDDashboard | Stop-UDDashboard

$pages = @()

$pages += New-UDPage -Name "home" -Content {
  New-UDTable -Title "Information" -Headers @("Name", "Action") -Endpoint {
    1..10 | foreach {
      [pscustomobject]@{
        Name = 'something'
        Action = New-UDButton -Text "Click" -OnClick  {
          Show-UDModal -Header {New-UDHeading -Size 4 -Text 'Modal Heading'} -Content {
            New-UDCard -Title 'Modal Title' -Size large -Content {
              "content of card $_"
            }
          }
        }
      }
    } | Out-UDTableData -Property @("Name", "Action")
  }
}

$Dashboard = New-UDDashboard -Title 'test' -Page $pages
Start-UDDashboard -Port 10001 -Dashboard $Dashboard
2 Likes