Skip to content

PageView

A rich page wrapper that adds breadcrumbs, badges, KPI tiles, toolbar, and header/footer slots around its content. Use it when you need more than Form provides.

The record is io.mateu.uidl.fluent.PageView (it used to be called Page; the name now belongs to io.mateu.uidl.data.Page<T>, the paged result of a CrudStore search). Main components:

@Builder
public record PageView(
String id,
String pageTitle,
String favicon,
String title,
String subtitle,
List<Breadcrumb> breadcrumbs,
Component avatar,
@Singular("contentItem") List<Component> content,
@Singular("headerItem") List<Component> header,
@Singular("footerItem") List<Component> footer,
@Singular("toolbarItem") List<UserTrigger> toolbar,
@Singular List<UserTrigger> buttons,
@Singular("badgeItem") List<Badge> badges,
@Singular("kpiItem") List<KPI> kpis,
String style,
String cssClasses,
@Singular("actionItem") List<Action> actions)
implements Component, ActionSupplier { /* … more components … */ }
PropertyTypeDefaultDescription
idString—Component ID
pageTitleString—Browser tab title
faviconString—Browser favicon URL
titleString—Page heading
subtitleString—Subheading
breadcrumbsList<Breadcrumb>—Navigation breadcrumb trail
avatarComponent—Avatar shown in the header
contentList<Component>—Main body
headerList<Component>—Above the content
footerList<Component>—Below the content
toolbarList<UserTrigger>—Toolbar action buttons
buttonsList<UserTrigger>—Bottom action buttons
badgesList<Badge>—Status badges in the header
kpisList<KPI>—KPI tiles shown below the title
actionsList<Action>—Registered actions for this page
styleString—Inline CSS
cssClassesString—CSS class names
return PageView.builder()
.title("Invoice #1234")
.subtitle("Created 2025-01-15")
.breadcrumbs(List.of(
new Breadcrumb("Home", "/"),
new Breadcrumb("Invoices", "/invoices"),
new Breadcrumb("#1234", "/invoices/1234")))
.contentItem(invoiceContent)
.build();
return PageView.builder()
.title("Order #5678")
.kpiItem(KPI.builder().title("Total").text("€ 1,250").build())
.kpiItem(KPI.builder().title("Items").text("7").build())
.badgeItem(Badge.builder().text("PAID").color(BadgeColor.success.name()).build())
.contentItem(orderContent)
.build();
return PageView.builder()
.title("Customer")
.actionItem(Action.builder().id("save").build())
.actionItem(Action.builder().id("delete").confirmationRequired(true).build())
.contentItem(customerForm)
.build();