Breadcrumbs
Shows where the user is and leads back up.
kor/ui/BreadcrumbsSource
When to use
- Use it on pages more than two levels deep.
Examples
Path to a record
<k:Breadcrumbs select=".onSelect">
<k:Crumb key="home" text="Home"/>
<k:Crumb key="sales" text="Sales"/>
<k:Crumb key="orders" text="Orders"/>
<k:Crumb text="4711"/>
</k:Breadcrumbs>
sap.ui.define(["sap/ui/core/mvc/Controller", "kor/ui/Toast"], (Controller, Toast) => Controller.extend("sample.Trail", {
onSelect(event) {
Toast.show(String(event.getParameter("key")));
}
}));
API
Properties
| Name | Type | Default | Description |
|---|
label | string | | Accessible name |
Aggregations
| Name | Type | Description |
|---|
items | Crumb[] | Steps. The last one is the current location |
Events
| Name | Type | Description |
|---|
select | key: string | A step was chosen. preventDefault stops navigation |
Crumb
A breadcrumb step.
Properties
| Name | Type | Default | Description |
|---|
key | string | | Key |
text | string | | Text |
href | string | | Address. When empty, only the select event fires |
Related
LinkRecordPage