Hide the menu when an action was chosen

Forum rules
Please note that response time for technical support is within 3-5 business days.
Post Reply
carlosma
Posts: 2
Joined: 02 May 2022, 19:56

27 May 2022, 15:32

I wonder how I can close the menu tree when an action was chosen

ItemMenu-1 ItemMenu-2 ItemMenu-3
|----subMenu
|----subMenu2--|--action 1
!--action 2

on click action 2 the menu returns to

ItemMenu-1 ItemMenu-2 ItemMenu-3


what I want to know is how I close, everything and return to the original state without having to click outside of the menu

cetincakiroglu
Posts: 130
Joined: 17 Dec 2021, 09:33

13 Jun 2022, 10:06

Hi,

It's hard to understand which block you're mentioning but as far I understand, you can use [hideOnOutsideClick]="true" if you're using styleClass to open the menu.

Regards

enunez8
Posts: 4
Joined: 29 Aug 2021, 19:25

18 Jul 2022, 18:43

tengo el mismo problema, alguna soluciòn?

cetincakiroglu
Posts: 130
Joined: 17 Dec 2021, 09:33

25 Jul 2022, 13:25

Hi,

You need to implement your own show/hide logic to achieve this without using hideOnOutsideClick property in styleClass module. As far as I understand you want to close everything without clicking the outside of the focused container, PrimeBlocks do not offer this as a feature as a user you need to implement custom logic.

Regards

Post Reply

Return to “PrimeBlocks for PrimeNG”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 2 guests