New-UDFloatingActionButton
A Floating Action Button (FAB) performs the primary, or most common, action on a screen.
Synopsis
Syntax
New-UDFloatingActionButton [[-Id] <String>] [[-Icon] <Object>] [[-Size] <String>] [[-OnClick] <Endpoint>] [[-ClassName] <String>] [[-Color] <String>] [[-Position] <String>] [<CommonParameters>]Description
Parameters
-Id
Required? false
Position? 1
Default value ([Guid]::NewGuid())
Accept pipeline input? false
Aliases
Accept wildcard characters? false-Icon The icon to put within the floating action button.Required? falsePosition? 2Default valueAccept pipeline input? falseAliasesAccept wildcard characters? false-SizeThe size of the button. Valid values are: "small", "medium", "large"Required? falsePosition? 3Default value largeAccept pipeline input? falseAliasesAccept wildcard characters? false-OnClickA script block to execute when the floating action button is clicked.Required? falsePosition? 4Default valueAccept pipeline input? falseAliasesAccept wildcard characters? false-ClassNameA CSS class to apply to the floating action button.Required? falsePosition? 5Default valueAccept pipeline input? falseAliasesAccept wildcard characters? false-ColorThe theme color to apply to the button. Valid values are: "Default", "Primary", "Secondary"Required? falsePosition? 6Default valueAccept pipeline input? falseAliasesAccept wildcard characters? false-PositionThe position of the floating action button. Valid values are: "Relative", "BottomLeft", "BottomRight"Required? falsePosition? 7Default value BottomRightAccept pipeline input? falseAliasesAccept wildcard characters? false <CommonParameters> This cmdlet supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, OutBuffer, PipelineVariable, and OutVariable. For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/?LinkID=113216).Outputs-------------------------- EXAMPLE 1 --------------------------PS >New-UDFloatingActionButton -Icon (New-UDIcon -Icon 'user') -OnClick {PS > Show-UDToast -Message 'Hello'PS > } -Id 'fab1' -Position RelativeBasic floating action button|Creates a floating action button with a user icon and shows a toast when clicked.-------------------------- EXAMPLE 2 --------------------------PS >New-UDFloatingActionButton -Icon (New-UDIcon -Icon 'user') -Size Small -OnClick {PS > Show-UDToast -Message 'Hello'PS > } -Id 'fab2' -Position RelativeSmall floating action button|Creates a small floating action button with a user icon and shows a toast when clicked.-------------------------- EXAMPLE 3 --------------------------PS >New-UDFloatingActionButton -Icon (New-UDIcon -Icon 'user') -Position BottomRight -OnClick {PS > Show-UDToast -Message 'Hello'PS > } -Id 'fab3'Position|Creates a floating action button with a user icon and shows a toast when clicked. The button is positioned in the bottom right of the buttons's container.
Last updated
Was this helpful?