Skip to content

General update to documentation #63

@JLogan3o13

Description

@JLogan3o13

I have seen a lot of questions on the forum that boil down to folks having a hard time telling what they should use for certain parameters on different elements. The documentation seems to be very high level in some cases, and leads to confusion. As just one example of this, parameters such as TitleSize and MessageSize for Show-UDToast simply say they are a String with no information on what would be an acceptable string to use ('48px', 'small', 'xl', etc.). Also, the example shown is very basic, using only 1 of the 26 different parameters. The online doc shows a few more examples, but still does not document complete use.

If I may suggest, something like this formatting for the github docs might lead to fewer forum requests:

Show-UDToast:

-MessageColor <DashboardColor>
    The text color of the message.
    
    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false
    **Acceptable Input      "white", "brown", "pink", "#fff", "#0000ff", "#ff0066"**

-TitleColor <DashboardColor>
    The text color of the title.
    
    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false
    **Acceptable Input      "white", "brown", "pink", "#fff", "#0000ff", "#ff0066"**
    
-TitleSize <String>
    The size of the title.
    
    Required?                    false
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false
    **Acceptable Input      Standard Sizes: "small", "medium", "large", or Pixel Size: "12", "48", "96"**
    
-Position <String>
    Where to display the toast.
    
    Required?                    false
    Position?                    named
    Default value                topRight
    Accept pipeline input?       false
    Accept wildcard characters?  false
    **Auto-Suggest?            true**
    **Acceptable Input      bottomCenter, bottomLeft, bottomRight, center, topCenter, topLeft, topRight**
         
-Overlay [<SwitchParameter>]
    Displays an overlay behind the toast.
    
    Required?                    false
    Position?                    named
    Default value                False
    Accept pipeline input?       false
    Accept wildcard characters?  false
    **-OverlayColor required when using this parameter**
          
-OverlayColor <DashboardColor>
    The color of the overlay.
    
    Required?                    **true if using -Overlay parameter**
    Position?                    named
    Default value                
    Accept pipeline input?       false
    Accept wildcard characters?  false
    **Acceptable Input      "white", "brown", "pink", "#fff", "#0000ff", "#ff0066"**

-------------------------- EXAMPLES --------------------------
#Simple Example
PS > Show-UDToast -Message 'Hello, World!'

#Comprehensive Example (formatting sucks when using backtick for line separation)
Show-UDToast -Position center
-Balloon -Broadcast
-ReplaceToast -RightToLeft
-Title "Oops" -TitleColor "brown" <# or "#0000ff" #>
-TitleSize "large" <# or "24px" #> -TransitionIn bounceInRight
-TransitionOut fadeInDown -Overlay
-OverlayColor "#0000ff" <# or "brown" #> -OverlayClose
-HideCloseButton -CloseOnClick
-CloseOnEscape -Message "!You must login first"
-MessageColor "#0000ff" <# or "brown" #> -MessageSize "24px" <# or "large" #>
-Duration 3000 -Icon "Ad"
-IconColor "#ff0066" <# or "pink" #> -Id "myToast"
-Persistent

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions