Skip to content

Menubar: Passthroug not working for the child elements #6295

@CaptainException

Description

@CaptainException

Describe the bug

Using passthrough I am able to style the Menubar itself but not any of its children. I tried both programmatic and declarative syntax and they behave the same.

This works:
:pt:root:style="'background-color: aquamarine'"
but this has no effect:
:pt:rootList:style="'background-color: red'"

Reproducer

https://stackblitz.com/edit/primevue-4-ts-vite-issue-template-m65auv?file=src%2FApp.vue

PrimeVue version

4.0.4

Vue version

3.4.37

Language

TypeScript

Build / Runtime

Vite

Browser(s)

No response

Steps to reproduce the behavior

  1. Klick to expand the Menubar if it is in mobile mode.
  2. See that the pt styling is not being applied.

Expected behavior

The styles should be applied to the child elements.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type: BugIssue contains a bug related to a specific component. Something about the component is not working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions