PPowerApps UI
ComponentsLayoutsTemplatesAppsAbout
P
PowerApps UI
Open Source

Production-ready UI components and patterns for Power Apps developers.

MIT License

Product

  • Components
  • Layouts
  • Templates
  • Apps
  • About
  • Cheat Sheet
  • Documentation

Developers

  • Getting Started
  • Suggest Idea
  • Submit Component
  • Report Issues

Resources

  • Changelog
  • Newsletter
  • Best Practices
  • Design System
© 2026 PowerApps UI. Open source under MIT License.
Built byRodas Yonass
Privacy Policy•Terms of Service•MIT License
ComponentsNavigation Menu

Navigation Menu

A horizontal nav bar with mega-menu dropdown panels. Supports single and two-column layouts, section headers, SVG icons, three active states, and full light/dark theming.

cmpNavigationMenu.yaml
  1. 1. Go to the Components tab (right side panel, next to Screens)
  2. 2. Click New component — this creates a blank component
  3. 3. Click outside the new component to deselect it
  4. 4. Paste the YAML with Ctrl+V / ⌘V

Power Apps Studio rendering note

After importing, the component may appear incomplete in the Studio editor until you press F5 (Preview) or publish. This is standard Power Apps behavior for YAML-imported components — the editor doesn't fully evaluate nested gallery templates until a preview cycle. End users always see the fully rendered component.

Preview

Click menu items to interact

Installation

This component requires Modern controls to be enabled. Settings → Updates → Preview → Modern controls and themes

# In Power Apps Studio:
1. Components tab → New component → Import from code
2. Paste the full YAML definition
3. Add the component to any screen
4. Press F5 (Preview) to see the fully rendered component

Usage

Define top-level menu items

// MenuItems — the top navigation bar buttons
// Each item needs: ID, Label, HasDropdown, Link

cmpNavigationMenu.MenuItems = Table(
    { ID: "dashboard",  Label: "Dashboard",  HasDropdown: false, Link: "DashboardScreen" },
    { ID: "inventory",  Label: "Inventory",  HasDropdown: true,  Link: "" },
    { ID: "operations", Label: "Operations", HasDropdown: true,  Link: "" },
    { ID: "reports",    Label: "Reports",    HasDropdown: true,  Link: "" }
)

Define dropdown content

// DropdownItems — content for each dropdown panel
// MenuID links items to their parent menu button
// Column: 1 = left, 2 = right (for 2-column layouts)
// Section: optional header text above each column group

cmpNavigationMenu.DropdownItems = Table(
    { MenuID: "inventory", Section: "Products", Icon: "Layout",
      Label: "All Items", Description: "Browse full catalog",
      Link: "ItemsScreen", Column: 1 },
    { MenuID: "inventory", Section: "Products", Icon: "BarChart",
      Label: "Stock Levels", Description: "Current quantities",
      Link: "StockScreen", Column: 1 },
    { MenuID: "inventory", Section: "Tracking", Icon: "Rocket",
      Label: "Incoming", Description: "Expected shipments",
      Link: "IncomingScreen", Column: 2 },
    { MenuID: "inventory", Section: "Tracking", Icon: "Zap",
      Label: "Adjustments", Description: "Manual corrections",
      Link: "AdjustScreen", Column: 2 }
)

Handle navigation

// OnItemSelect — fires when any item is clicked
// Use SelectedItem output to route navigation

cmpNavigationMenu.OnItemSelect = Switch(
    cmpNavigationMenu.SelectedItem.Link,
    "DashboardScreen", Navigate(scrDashboard),
    "ItemsScreen",     Navigate(scrItems),
    "StockScreen",     Navigate(scrStock),
    "IncomingScreen",  Navigate(scrIncoming)
)

// Or use a lookup table approach
cmpNavigationMenu.OnItemSelect = Navigate(
    LookUp(
        colScreenMap,
        Link = cmpNavigationMenu.SelectedItem.Link
    ).Screen
)

Properties

Input

PropertyTypeDefault
MenuItems

Top-level nav buttons (ID, Label, HasDropdown, Link)

TableSee default
DropdownItems

Dropdown content (MenuID, Section, Icon, Label, Description, Link, Column)

TableSee default
DropdownColumns

Columns in dropdown panel (1 = list, 2 = mega menu)

Number2
NavAlign

Menu bar alignment: "Left", "Center", or "Right"

Text"Center"
ActiveColor

Accent color for active/selected states

ColorRGBA(37,99,235,1)
Theme

"Light" or "Dark" theme

Text"Light"
ShowIcons

Show icons in dropdown items

Booleantrue
ShowDescriptions

Show description text in dropdown items

Booleantrue
ShowNavScrollbar

Show scrollbar on the nav bar gallery

Booleanfalse
ShowDropdownScrollbar

Show scrollbar in dropdown galleries

Booleanfalse

Output

PropertyTypeDescription
SelectedItemRecordThe last clicked item record (from MenuItems or DropdownItems)
SelectedMenuIDTextID of the currently open or last selected parent menu
IsOpenBooleanWhether a dropdown panel is currently open

Event

EventDescription
OnItemSelectFires when any menu button or dropdown item is clicked. Use with SelectedItem to route navigation.

Implementation Details

Dual-table architecture

MenuItems defines the top bar buttons. DropdownItems holds all dropdown content, linked via MenuID. This separation lets you modify dropdown content independently and keeps formulas clean.

Three active states

Menu buttons highlight in three scenarios: when their dropdown is open, when clicked as a direct link (e.g. Dashboard), or when a child dropdown item was last selected and the dropdown is closed. All three use the ActiveColor property.

Adaptive column layout

When DropdownColumns is 2, the panel checks if Column 2 items exist for the active menu. If not, it renders a narrow single-column panel. On screens under 500px, all items collapse into a single scrollable column regardless of the setting.

Click-outside dismiss

A transparent backdrop sits behind the dropdown panel and catches clicks anywhere inside the component below the nav bar. It is deliberately offset below the bar so it never intercepts clicks on the menu buttons themselves.

Screens have no OnSelect property, so dismissing from anywhere else on the screen needs a transparent button instead. Add this as the first control on your screen, above everything else in the tree, so it renders at the bottom of the z-order and never competes with your other controls.

      - btnScreenDismiss:
          Control: Classic/Button@2.2.0
          Properties:
            BorderStyle: =BorderStyle.None
            Color: =RGBA(0, 0, 0, 0)
            Fill: =RGBA(0, 0, 0, 0)
            FocusedBorderThickness: =0
            Height: =Parent.Height
            HoverFill: =RGBA(0, 0, 0, 0)
            OnSelect: =Set(_navOpenMenu, Blank())
            PressedFill: =RGBA(0, 0, 0, 0)
            Text: =""
            Visible: =!IsBlank(_navOpenMenu)
            Width: =Parent.Width
            X: =0
            Y: =0

The Visible condition keeps the button out of the way entirely when no dropdown is open.

Built-in icons

The Icon field supports 9 built-in names: Layout, FileText, BarChart, Settings, Code, Book, Rocket, Zap, Sparkles. You can also pass raw SVG strings or data:image/svg+xml URIs for custom icons.

Responsive behavior

On desktop (500px+), buttons size between 120–160px with 14px font. On mobile (<500px), buttons lock at 120px min with 12px font and the nav bar becomes horizontally swipeable. Two-column dropdowns collapse to a single column, and section headers hide to avoid confusion.

Nav bar height coupling

The nav bar is 48px tall, or 68px when ShowNavScrollbar is true. The dropdown backdrop offsets by the same amount so it starts flush underneath the bar. If you customize the bar height, update the backdrop Height and Y to match, or clicks on the nav bar will be intercepted while a dropdown is open.

Examples

Single-column dropdown (Reports)

// Reports — no sections, single column
// Section: "" means no header shown

DropdownItems: Table(
    { MenuID: "reports", Section: "",
      Icon: "BarChart",
      Label: "Inventory Value",
      Description: "Cost summaries",
      Link: "ValueReportScreen",
      Column: 1 },
    { MenuID: "reports", Section: "",
      Icon: "Sparkles",
      Label: "Turnover Analysis",
      Description: "Sell-through rates",
      Link: "TurnoverScreen",
      Column: 1 },
    { MenuID: "reports", Section: "",
      Icon: "Book",
      Label: "Low Stock Alerts",
      Description: "Items below threshold",
      Link: "LowStockScreen",
      Column: 1 }
)

Two-column mega menu (Inventory)

// Inventory — 2 columns with sections
// Column 1 = "Products"
// Column 2 = "Tracking"

DropdownItems: Table(
    { MenuID: "inventory",
      Section: "Products",
      Icon: "Layout",
      Label: "All Items",
      Description: "Browse catalog",
      Link: "ItemsScreen",
      Column: 1 },
    { MenuID: "inventory",
      Section: "Tracking",
      Icon: "Rocket",
      Label: "Incoming",
      Description: "Expected shipments",
      Link: "IncomingScreen",
      Column: 2 }
    // ... more items
)

cmpNavigationMenu.DropdownColumns = 2

Data Schema

MenuItems record

FieldTypeNotes
IDTextUnique identifier, matches MenuID in DropdownItems
LabelTextButton text displayed in the nav bar
HasDropdownBooleantrue = has dropdown panel, false = direct link
LinkTextScreen name or route for direct-link items

DropdownItems record

FieldTypeNotes
MenuIDTextLinks to parent MenuItem ID
SectionTextColumn header text (blank = no header)
IconTextBuilt-in name, raw SVG string, or data URI
LabelTextItem title
DescriptionTextSubtitle (hidden when ShowDescriptions = false)
LinkTextScreen name or route identifier
ColumnNumber1 = left column, 2 = right column

Architecture

19 controls across 3 group containers, 3 galleries, and supporting labels/buttons.

14 properties — 10 input, 3 output, 1 event.

cmpNavigationMenu
├── cntNavRoot (GroupContainer — full width)
│   └── cntNavBar (GroupContainer — 48px bar, border-bottom)
│       └── galMenuItems (Horizontal Gallery)
│           ├── btnMenuItem (button per item)
│           └── imgChevron (▾ indicator)
├── btnBackdrop (transparent full-screen click catcher)
└── cntDropdownPanel (GroupContainer — positioned below active item)
    ├── lblCol1Section (section header above col 1)
    ├── lblCol2Section (section header above col 2)
    ├── galDDCol1 (Gallery — column 1 items)
    │   ├── imgIcon + lblLabel + lblDesc + btnHit
    └── galDDCol2 (Gallery — column 2 items)
        └── imgIcon + lblLabel + lblDesc + btnHit

Get new components and templates when they drop

One email when something new ships. Unsubscribe anytime.

Community

Use the toolbar to format · or type markdown directly