Project

PSWriteHTML

Generate HTML reports, dashboards, and emails from PowerShell without writing HTML, CSS, or JavaScript.

Stars 1,023
Forks 115
Open issues 54
PowerShell Gallery downloads 7,576,901
Release v1.45.0
Language: PowerShell Updated: 2026-11-03
Command

New-NavItem

Module
PSWriteHTML

Creates a new navigation item with specified parameters.

Syntax

New-NavItem
[-Href <String>]
[-IconColor <String>]
[-IconSolid <String>]
[-InternalPageID <String>]
[-Name <String>]
-Type <Grid|Menu>
[<CommonParameters>]
#
Parameter set: FontAwesomeSolid
New-NavItem
[-Bordered]
[-BorderedCircle]
[-FlipHorizontal]
[-FlipVertical]
[-Href <String>]
[-IconColor <String>]
[-IconMaterial <String>]
[-InternalPageID <String>]
[-Name <String>]
[-PullLeft]
[-PullRight]
[-Rotate <90|180|270>]
[-Spinning]
[-SpinningReverse]
-Type <Grid|Menu>
[<CommonParameters>]
#
Parameter set: FontMaterial
New-NavItem
[-Href <String>]
[-IconColor <String>]
[-IconRegular <String>]
[-InternalPageID <String>]
[-Name <String>]
-Type <Grid|Menu>
[<CommonParameters>]
#
Parameter set: FontAwesomeRegular
New-NavItem
[-Href <String>]
[-IconBrands <String>]
[-IconColor <String>]
[-InternalPageID <String>]
[-Name <String>]
-Type <Grid|Menu>
[<CommonParameters>]
#
Parameter set: FontAwesomeBrands

Description

The New-NavItem function creates a new navigation item with the specified parameters, such as name, href, type, icon, and color.

Examples

Example 1

New-NavItem -Name "Home" -Href "/" -Type "Menu" -IconBrands "fa fa-home" -IconColor "blue"
Creates a new navigation item named "Home" with a link to the root ("/"), type "Menu", using a home icon from FontAwesome Brands with blue color.

Example 2

New-NavItem -Name "About" -Href "/about" -Type "Grid" -IconRegular "far fa-address-card" -IconColor "green"
Creates a new navigation item named "About" with a link to "/about", type "Grid", using an address card icon from FontAwesome Regular with green color.

Example 3

New-NavItem -Name "Contact" -Href "/contact" -Type "Menu" -FontMaterial "person" -IconColor "red"
Creates a new navigation item named "Contact" with a link to "/contact", type "Menu", using a person icon from Material Design Icons with red color.

Parameters

-Href String optional
-IconColor String optional
-IconSolid String optionalsets: FontAwesomeSolid
ICON SOLID
-InternalPageID String optional
-Name String optionalaliases: Text
-Type String required
Possible values: Grid, Menu
-Bordered SwitchParameter optionalsets: FontMaterial
-BorderedCircle SwitchParameter optionalsets: FontMaterial
-FlipHorizontal SwitchParameter optionalsets: FontMaterial
-FlipVertical SwitchParameter optionalsets: FontMaterial
-IconMaterial String optionalsets: FontMaterial
FontsMaterialIcon
-PullLeft SwitchParameter optionalsets: FontMaterial
-PullRight SwitchParameter optionalsets: FontMaterial
-Rotate String optionalsets: FontMaterial
Possible values: 90, 180, 270
-Spinning SwitchParameter optionalsets: FontMaterial
-SpinningReverse SwitchParameter optionalsets: FontMaterial
-IconRegular String optionalsets: FontAwesomeRegular
ICON REGULAR
-IconBrands String optionalsets: FontAwesomeBrands
ICON BRANDS

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.