> For the complete documentation index, see [llms.txt](https://docs.devolutions.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.devolutions.net/powershell-universal/powershell-commands/new-udtabs.md).

# New-UDTabs

New-UDTabs creates a tabbed container in PowerShell Universal that organizes multiple New-UDTab items for browsing large amounts of content.

### Synopsis

Creates a new set of tabs.

### Syntax

```powershell
New-UDTabs [-Tabs] <ScriptBlock> [[-Id] <String>] [-RenderOnActive] [[-Orientation] <String>] [[-Variant] <String>] [[-ScrollButtons] <String>] [-Centered] [[-ClassName] <String>] [[-SelectedTabIndex] <Int32>] [[-Style] <Hashtable>] [[-Sx] <Hashtable>] [<CommonParameters>]
```

### Description

Creates a new set of tabs. Tabs can be used to show lots of content on a single page.

### Parameters

#### -Tabs

The tabs to put within this container.

```
Required?                    true
Position?                    1
Default value
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -Id

The ID of the component. It defaults to a random GUID.

```
Required?                    false
Position?                    2
Default value                ([Guid]::NewGuid()).ToString()
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -RenderOnActive

Deprecated

```
Required?                    false
Position?                    named
Default value                False
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -Orientation

The orientation of the tabs. Valid values are horizontal and vertical.

```
Required?                    false
Position?                    3
Default value                horizontal
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -Variant

The variantion of tabs. Valid values are standard, fullWidth and scrollable.

```
Required?                    false
Position?                    4
Default value                standard
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -ScrollButtons

The behavior of the scrollbuttons. Valid values are on, off, auto and desktop. On will enable scroll buttons no matter what. off will disable all scroll buttons. Auto will show scrollbuttons when necessary. Desktop will show scrollbuttons on medium and large screens.

```
Required?                    false
Position?                    5
Default value                auto
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -Centered

Whether the tabs should be centered.

```
Required?                    false
Position?                    named
Default value                False
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -ClassName

The CSS class to apply to the tabs.

```
Required?                    false
Position?                    6
Default value
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -SelectedTabIndex

```
Required?                    false
Position?                    7
Default value                0
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -Style

The style to apply to the tabs.

```
Required?                    false
Position?                    8
Default value
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### -Sx

A theme-specific style to apply to the tabs.

```
Required?                    false
Position?                    9
Default value
Accept pipeline input?       false
Aliases
Accept wildcard characters?  false
```

#### Common parameters

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

### Examples

#### Example 1: Basic Tabs

```powershell
New-UDTabs -Tabs {
   New-UDTab -Text "Tab1" -Id 'Tab1' -Content {
       New-UDElement -Tag div -Id 'tab1Content' -Content { "Tab1Content"}
   }
   New-UDTab -Text "Tab2" -Id 'Tab2' -Content {
       New-UDElement -Tag div -Id 'tab2Content' -Content { "Tab2Content"}
   }
   New-UDTab -Text "Tab3" -Id 'Tab3' -Content {
       New-UDElement -Tag div -Id 'tab3Content' -Content { "Tab3Content"}
   }
} -Id 'tabs1'
```

A basic set of tabs.

#### Example 2: Dynamic Tabs

```powershell
New-UDTabs -Id 'tabs2' -Tabs {
   New-UDTab -Text "Tab1" -Id 'DynamicTab1' -Dynamic -Content {
       New-UDElement -Tag div -Id 'DynamicTab1Content' -Content { Get-Date }
   }
   New-UDTab -Text "Tab2" -Id 'DynamicTab2' -Dynamic -Content {
       New-UDElement -Tag div -Id 'DynamicTab2Content' -Content { Get-Date }
   }
   New-UDTab -Text "Tab3" -Id 'DynamicTab3' -Dynamic -Content {
       New-UDElement -Tag div -Id 'DynamicTab3Content' -Content { Get-Date }
   }
}
```

A set of dynamic tabs.

#### Example 3: Vertical Tabs

```powershell
New-UDTabs -Id 'tabs3' -Orientation 'vertical' -Tabs {
    New-UDTab -Text "Tab1" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of vertical tabs.

#### Example 4: Full Width Tabs

```powershell
New-UDTabs -Id 'tabs4' -Variant 'fullWidth' -Tabs {
    New-UDTab -Text "Tab1" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of full width tabs.

#### Example 5: Scrollable Tabs

```powershell
New-UDTabs -Id 'tabs5' -Variant 'scrollable' -Tabs {
    New-UDTab -Text "Tab1" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of scrollable tabs.

#### Example 6: Scroll Buttons On

```powershell
New-UDTabs -Id 'tabs6' -ScrollButtons 'on' -Tabs {
    New-UDTab -Text "Tab1" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of tabs with scroll buttons always on.

#### Example 7: Centered Tabs

```powershell
New-UDTabs -Id 'tabs7' -Centered -Tabs {
    New-UDTab -Text "Tab1" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of centered tabs.

#### Example 8: Tabs with Icons

```powershell
New-UDTabs -Id 'tabs8' -Tabs {
    New-UDTab -Text "Tab1" -Icon (New-UDIcon -Icon Eye) -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Icon (New-UDIcon -Icon Home) -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Icon (New-UDIcon -Icon User) -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of tabs with icons.

#### Example 9: Disabled Tab

```powershell
New-UDTabs -Id 'tabs7' -Tabs {
    New-UDTab -Text "Tab1" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab2" -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
    New-UDTab -Text "Tab3" -Disabled -Content {
        New-UDElement -Tag div -Content { Get-Date }
    }
}
```

A set of tabs with a disabled tab.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.devolutions.net/powershell-universal/powershell-commands/new-udtabs.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
