Skip to content

Directory

A categorised navigation directory rendered as a nested menu of labelled links. Useful for landing pages that list available sections.

Directory.builder()
.menu(List.of(
Menu.builder()
.label("Invoices")
.submenu(List.of(
RouteLink.builder().label("All invoices").build(),
RouteLink.builder().label("Drafts").build()
))
.build()
))
.build()
PropertyTypeDefaultDescription
menuList<Menu>Top-level menu sections
styleStringInline CSS
cssClassesStringCSS class names
PropertyTypeDescription
labelStringSection heading
submenuList<RouteLink>Links within this section
PropertyTypeDescription
labelStringLink text
hrefStringTarget path
Directory.builder()
.menu(List.of(
Menu.builder()
.label("Finance")
.submenu(List.of(
RouteLink.builder().label("Invoices").build(),
RouteLink.builder().label("Payments").build(),
RouteLink.builder().label("Credit notes").build()
))
.build(),
Menu.builder()
.label("Customers")
.submenu(List.of(
RouteLink.builder().label("Customer list").build(),
RouteLink.builder().label("Contacts").build()
))
.build(),
Menu.builder()
.label("Reports")
.submenu(List.of(
RouteLink.builder().label("Monthly summary").build(),
RouteLink.builder().label("Annual report").build()
))
.build()
))
.build()