Hello,
I have two Menus and I need to customize their popups differently. Can I specify somehow Menu Popup id or className?
As I can see Popup component has className property, but it is hard-coded in MenuItemInternal.prototype.getPopupClassName and neither Menu nor MenuItem classes are used in popup.
Any suggestions?
Thanks.
Hello,
This can already by done using the PopupContext:
https://www.telerik.com/kendo-react-ui-develop/components/popup/global-context/
The two different Menu components have to be wrapped in two different PopupCotexts.
Regards,
Stefan
Progress Telerik
Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.
Hello, Vitaliy,
This is already transferred and the community can vote for it.
I already transferred its status on approved, as it is indeed a valid and useful request:
https://feedback.telerik.com/kendo-react-ui/1445252-custom-menu-popup-class
Regards,
Stefan
Progress Telerik
Hi Stefan.
Yes, please transfer it to feature requests community.
It is a bit strange that no one else had a need in similar functionality before.
Thanks.
Hello, Vitaliy,
This is expected as the class is applied to all items inside the Menu.
If the request is specifically for the main Popup if you wish I can transfer this to an official feature request where the community can vote for it. This is the way we determine which features and components to be implemented sooner.
Regards,
Stefan
Progress Telerik
Thanks Stefan,
Unfortunately, the using size of the MenuItem to change the size of the popup would not work if I have more than one menu item.
Please see the screen shot attached.
Thanks
Hello, Vitaliy,
In this case, I can suggest setting the cssClass property of the MenuItem as it will be applied to the Popup as well:
https://www.telerik.com/kendo-react-ui/components/layout/api/BaseMenuItem/#toc-cssclass
I made an example with two Menu on the page and both have different styles for the Popup:
https://stackblitz.com/edit/react-mjt2az?file=app/main.jsx
I hope this is helpful.
Regards,
Stefan
Progress Telerik