Enhance MenuItem methods for setting icons
javier-godoy opened this issue · 1 comments
javier-godoy commented
Current API for setting icons is too cumbersome or requires passing icon names as string, e.g.:
new MenuItem("Content", "vaadin:book", ... );
new MenuItem("Content", VaadinIcon.BOOK.create().getElement().getAttribute("icon"), ... );
javier-godoy commented
A new constructor was added to MenuItem
class, accepting an argument of type VaadinIcon
new MenuItem("Content", VaadinIcon.BOOK, ... )