Skip to content
This repository has been archived by the owner on Jan 4, 2025. It is now read-only.

Commit

Permalink
Adding button help
Browse files Browse the repository at this point in the history
  • Loading branch information
adamdriscoll committed Jun 15, 2019
1 parent affd6f4 commit 48cfde8
Showing 1 changed file with 54 additions and 16 deletions.
70 changes: 54 additions & 16 deletions src/UniversalDashboard/Help/New-UDButton.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
---
external help file: UniversalDashboard.Community-help.xml
Module Name: UniversalDashboard.Community
online version:
online version:https://github.com/ironmansoftware/universal-dashboard/blob/master/src/UniversalDashboard/Help/New-UDButton.md
schema: 2.0.0
---

# New-UDButton

## SYNOPSIS
{{ Fill in the Synopsis }}
Creates a new button.

## SYNTAX

Expand All @@ -19,21 +19,59 @@ New-UDButton [[-Id] <String>] [[-Text] <Object>] [[-OnClick] <Object>] [-Floatin
```

## DESCRIPTION
{{ Fill in the Description }}
Creates a new button. Buttons come in different shapes and sizes and can be configured to execute scripts when clicked.

## EXAMPLES

### Example 1
### Raised Button
```powershell
PS C:\> {{ Add example code here }}
New-UDButton -Text "Button"
```

{{ Add example description here }}
Creates a basic, raised button.

### Button with Icon
```powershell
New-UDButton -Text "Button" -Icon cloud
```

Creates a basic, raised button with an icon.

### Button Colors
```powershell
New-UDButton -Text "Button" -BackgroundColor "red" -FontColor "white"
```

Creates a red button with white text.

### Floating
```powershell
New-UDButton -Floating -Icon plus
```

Creates a circular, floating button with a plus icon.

### Floating
```powershell
New-UDButton -Flat -Text "Button"
```

Creates a flat button

### OnClick Event Handler
```powershell
New-UDButton -Text "Button" -OnClick {
Show-UDToast -Message "Ouch!"
}
```

Creats a button that shows a toast message when clicked.


## PARAMETERS

### -BackgroundColor
{{ Fill BackgroundColor Description }}
Background color of the button.

```yaml
Type: DashboardColor
Expand All @@ -48,7 +86,7 @@ Accept wildcard characters: False
```
### -Disabled
{{ Fill Disabled Description }}
Creates a disabled button.
```yaml
Type: SwitchParameter
Expand All @@ -63,7 +101,7 @@ Accept wildcard characters: False
```
### -Flat
{{ Fill Flat Description }}
Creates a flat button without shadows.
```yaml
Type: SwitchParameter
Expand All @@ -78,7 +116,7 @@ Accept wildcard characters: False
```
### -Floating
{{ Fill Floating Description }}
Creates a circular, floating button.
```yaml
Type: SwitchParameter
Expand All @@ -93,7 +131,7 @@ Accept wildcard characters: False
```
### -FontColor
{{ Fill FontColor Description }}
Font color of the button. This also changes the icon color.
```yaml
Type: DashboardColor
Expand All @@ -108,7 +146,7 @@ Accept wildcard characters: False
```
### -Icon
{{ Fill Icon Description }}
The icon for this button.
```yaml
Type: FontAwesomeIcons
Expand All @@ -124,7 +162,7 @@ Accept wildcard characters: False
```
### -IconAlignment
{{ Fill IconAlignment Description }}
The icon alignment.
```yaml
Type: String
Expand All @@ -140,7 +178,7 @@ Accept wildcard characters: False
```
### -Id
{{ Fill Id Description }}
The ID of the component.
```yaml
Type: String
Expand All @@ -155,7 +193,7 @@ Accept wildcard characters: False
```
### -OnClick
{{ Fill OnClick Description }}
An event handler that is called when the button is clicked. This can be either a ScriptBlock or a UDEndpoint.
```yaml
Type: Object
Expand All @@ -170,7 +208,7 @@ Accept wildcard characters: False
```
### -Text
{{ Fill Text Description }}
The test to display on the button.
```yaml
Type: Object
Expand Down

0 comments on commit 48cfde8

Please sign in to comment.