Created
February 4, 2019 20:39
-
-
Save taylor8294/218bb2fca75c89064b8575f7c9f0352b to your computer and use it in GitHub Desktop.
How to add badges to PrimeNG panelMenu MenuItem's
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Enable badges in menu items | |
| .ui-panelmenu-header, .ui-menuitem { | |
| position: relative; | |
| } | |
| .ui-menuitem-text .badge{ | |
| position: absolute; | |
| right: 1.5em; | |
| top: 1.4em; | |
| top: calc(0.714em + 7px); | |
| } |
I am having the same problem, and paid for premium "designer", the documentation is lacking with numerous components... Don't reference the menuModel if you can't actually use all the options with it... be explicit.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It seams PrimeNG adds a neat way to do it. But even when I set
badgeandbadgeStyleClassto the menu item's model, nothing happen! Is there anyone who used this feature?