Zone de texte
Composant de zone de texte pour les applications universelles
Mis à jour
Ce contenu vous a-t-il été utile ?
Ce contenu vous a-t-il été utile ?
New-UDTextbox -Label 'Standard' -Placeholder 'Textbox'
New-UDTextbox -Label 'Disabled' -Placeholder 'Textbox' -Disabled
New-UDTextbox -Label 'Textbox' -Value 'With value'New-UDTextbox -Label 'Password' -Type passwordNew-UDTextbox -Label 'Number' -Type number -Minimum 10 -Maximum 10000 -Value 1234New-UDTextbox -Multiline -Rows 4 -RowsMax 10New-UDTextbox -Id 'txtExample'
New-UDButton -OnClick {
$Value = (Get-UDElement -Id 'txtExample').value
Show-UDToast -Message $Value
} -Text "Get textbox value"New-UDTextbox -Id 'txtExample' -Label 'Label' -Value 'Value'
New-UDButton -OnClick {
Set-UDElement -Id 'txtExample' -Properties @{
Value = "test123"
}
} -Text "Get textbox value"New-UDTextbox -Id "ServerGroups" -Icon (New-UDIcon -Icon 'server') -Value "This is my server"New-UDTextbox -Id 'textbox16' -MaskPattern '+7 (000) 000-00-00'New-UDTextbox -OnEnter {
Invoke-UDEndpoint -Id 'submit' -Session
}
New-UDButton -Id 'submit' -OnClick {
Show-UDToast -Message 'From Textbox'
}New-UDTextbox -OnBlur {
Show-UDToast "Blurred"
}New-UDTextbox -OnValidate {
if ($EventData.Length -lt 10)
{
New-UDValidationResult -ValidationError 'String needs to be longer than 10'
}
}