mvysny / karibu-dsl

Kotlin Vaadin extensions and DSL

Home Page:http://www.vaadinonkotlin.eu

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ValoMenu expose navigationButtonLayout

DALDEI opened this issue · comments

I am attempting to implement some variance on ValoMenu. A first start is a kind of "Accordian" -- I've settle for a 'section' that could be hidden (issue: too many menu items, need a kind of cascade to avoid having to write seperate UI's )

I'd submit a PR but all it would be is to make navigationButtonLayout public (or a getter of some sort).
I dont know if this is sufficient -- but its definately a blocker -- I attempted to place a new component on the menu area and could not because I dont have a reference to the component the buttons live in.

Thanks! I originally wanted to keep the navigationButtonLayout private (as an implementation detail of the menu), since what if the CSS+the menu structure changed... However that would break all menus out there based on these CSS styles, so this CSS change probably never happens.

Therefore, I'm all in for making the navigationButtonLayout public as a getter (something like lateinit var navigationButtonLayout: CssLayout private set), since you can retrieve the reference to that CssLayout simply by asking for a parent of any MenuButton. Hold on...

Please review 21d51cc whether it would help you.

Karibu-DSL 0.4.7 has been released with the requested change; please review and let me know if it helps.

Thanks ! I will try this.
FYI : Attached screenshot of what I am thinking.
image