Navigation API
Full surface of @oge-ui/navigation on one page: oge-tree-view, oge-drawer, oge-stepper, oge-menubar, oge-breadcrumb and oge-pagination — their inputs, outputs, methods, template slots, WAI-ARIA APG keyboard maps and config providers. Use the contents list to jump to a component.
Properties Methods Events Types
OgeTreeView
oge-tree-viewProperties 45
Data & accessors
| Name | Type | Default | Description |
|---|---|---|---|
items | readonly T[] | undefined | — | Nodes to display — a flat parent-referencing list or nested children. |
keyExpr | string | ((row: T) => RowKey) | 'id' | Field holding a node's stable key. Each rendered item carries it as data-key (stringified), so tests and delegated handlers can find a node's element. |
parentIdExpr | string | ((row: T) => unknown) | 'parentId' | Field holding a node's parent key (flat data). |
itemsExpr | string | ((row: T) => readonly T[]) | undefined | — | Field holding nested children. Setting it switches the tree to hierarchical data. |
displayExpr | string | ((row: T) => unknown) | 'text' | Field holding the display text. |
disabledExpr | string | ((row: T) => unknown) | 'disabled' | Field marking a node disabled. |
hasItemsExpr | string | ((row: T) => unknown) | 'hasItems' | Field hinting that a node has children that are not loaded yet — only consulted with a loadChildren. |
iconExpr | string | ((row: T) => unknown) | undefined | — | Field holding SVG path data (d) for a per-node icon. |
rootValue | unknown | — | Parent value that marks root nodes in flat data. undefined/null treats both as root. |
dataStructure | 'plain' | 'tree' | undefined | — | Explicit data shape; inferred from itemsExpr when unset. |
State (two-way)
| Name | Type | Default | Description |
|---|---|---|---|
expandedKeys | readonly RowKey[] | [] | Keys of the expanded nodes. |
selectedKeys | readonly RowKey[] | [] | Keys of the selected nodes, projected by selectedKeysMode on the way out. |
focusedKey | RowKey | undefined | — | Key of the node holding the roving tabindex. |
searchValue | string | '' | Current search text. |
Selection
| Name | Type | Default | Description |
|---|---|---|---|
selectionMode | 'none' | 'single' | 'multiple' | 'none' | How nodes may be selected. |
selectByClick | boolean | undefined | — | Selects a node when its row is clicked. undefined resolves to true without checkboxes and false with them, so clicking a label never silently ticks the box beside it. |
selectNodesRecursive | boolean | true | Cascades selection down to descendants and up to fully-selected parents (the tri-state model). |
showCheckBoxes | 'none' | 'normal' | 'selectAll' | 'none' | Checkbox column: hidden, per node, or per node plus a "select all" row. |
selectedKeysMode | 'all' | 'leavesOnly' | 'excludeRecursive' | 'all' | Projection applied to selectedKeys: everything, only childless nodes, or the top-most roots of fully-selected subtrees. |
Expansion
| Name | Type | Default | Description |
|---|---|---|---|
expandEvent | 'click' | 'dblclick' | 'click' | Which gesture expands a node. The chevron always expands regardless. |
expandNodesRecursive | boolean | true | Expanding a node also expands its ancestors. |
allowExpandAll | boolean | true | Enables the APG * shortcut, which expands every sibling at the focused level. |
Search
| Name | Type | Default | Description |
|---|---|---|---|
searchEnabled | boolean | false | Renders the built-in search box above the tree. |
searchMode | 'contains' | 'startsWith' | 'equals' | 'contains' | How the text is compared. Matching is accent- and locale-insensitive. |
searchExpr | string | ((row: T) => unknown) | array | undefined | — | Fields searched instead of displayExpr; an array searches several. |
searchTimeout | number | 0 | Debounce applied to the search box, in milliseconds. |
filterMode | 'matchOnly' | 'withAncestors' | 'fullBranch' | 'withAncestors' | Which relatives of a match stay visible. fullBranch also keeps a match's descendants. |
expandNodesOnFiltering | boolean | true | Auto-expands the ancestors of matches. |
highlightSearchResults | boolean | true | Wraps matches in <mark class="oge-highlight">. |
Lazy loading, virtualization & drag
| Name | Type | Default | Description |
|---|---|---|---|
loadChildren | (parent: T, key: RowKey) => Promise<readonly T[]> | — | Loads a node's children the first time it expands; a placeholder row shows meanwhile. Single-flight per node, and fetched children join the index so cascades reach them. |
virtualScroll | boolean | { itemHeight: number } | false | Windowed rendering for large trees. Every row must actually be itemHeight tall (30px by default). |
height | string | undefined | — | Height of the scroll container (any CSS length) — required for virtual scrolling to have a viewport. |
allowDragging | boolean | false | Enables pointer drag reordering. |
allowDropInside | boolean | true | Allows dropping *into* a node (reparenting), not just between siblings. |
allowDropBetween | boolean | true | Allows dropping between nodes (before / after a sibling). false leaves only drops into a node — a tree whose order is fixed (sorted by name) but whose nesting may change. The keyboard twin follows it too. |
dragGroup | string | undefined | — | Trees sharing a group accept each other's nodes — by pointer drag and by the Ctrl+X / Ctrl+V keyboard twin. Both trees need allowDragging. The target fires itemReordering / itemReordered (with sourceTreeId / targetTreeId), the source itemTransferred; neither moves data. |
childPageSize | number | undefined | — | Children rendered per parent (roots included) before a "Load more" row — Kendo's node page size. aria-setsize keeps reporting the real total. 0 / unset renders every child. Paging pauses while searching. |
Label editing
| Name | Type | Default | Description |
|---|---|---|---|
allowEditing | boolean | ((item: T) => boolean) | false | Lets users rename nodes in place: F2 (or a double-click with editOnDblClick) turns the label into a text field; Enter or blur commits, Escape cancels. The tree does not write the label — apply itemEdited to your data. |
editOnDblClick | boolean | false | A double-click opens the label editor instead of toggling the node. |
validateEdit | (value: string, item: T) => boolean | string | null | undefined | — | Validates an edited label: true / null accepts, false rejects with the catalog's editInvalid, a string rejects with that message. A rejected label keeps the editor open. |
Presentation
| Name | Type | Default | Description |
|---|---|---|---|
disabled | boolean | false | Disables the whole component. |
size | 'sm' | 'md' | 'lg' | 'md' | Density of the node rows. |
ariaLabel | string | undefined | — | Aria label of the tree. |
treeId | string | undefined | — | DOM id put on the inner role="tree" element — set it when an outside control (a combobox owning this tree as its popup) must point aria-controls at the list rather than the host. |
messages | Partial<OgeTreeViewMessages> | {} | Per-instance overrides of the config strings. |
Methods 17
| Name | Type | Description |
|---|---|---|
expand(key) | (key: RowKey) => Promise<boolean> | Expands a node, awaiting the lazy child fetch when there is one. Resolves false if the node is unknown or itemExpanding vetoed it. |
collapse(key) | (key: RowKey) => Promise<boolean> | Collapses a node; resolves whether it actually collapsed. |
toggle(key) | (key: RowKey) => Promise<boolean> | Expands the node if collapsed, collapses it otherwise. |
expandAll() | () => void | Expands every node that has loaded children. |
collapseAll() | () => void | Collapses every node. |
selectAll() | () => void | Selects every node. |
unselectAll() | () => void | Clears the selection. |
select(key) / unselect(key) | (key: RowKey) => void | Selects or deselects one node, cascading when selectNodesRecursive is on. |
isExpanded(key) / isSelected(key) | (key: RowKey) => boolean | Current state of one node. |
getSelectedKeys(mode?) | (mode?: OgeTreeSelectedKeysMode) => RowKey[] | Selected keys under a projection, defaulting to selectedKeysMode. |
focus(key?) | (key?: RowKey) => void | Focuses a node's row, or the first enabled one. |
scrollToItem(key) | (key: RowKey) => void | Scrolls a node into view, using offset math when virtualized. |
editItem(key) | (key: RowKey) => boolean | Opens the label editor on a node (what F2 does). Returns false when editing is off for it or itemEditStarting vetoed. |
cancelEdit() | () => void | Closes an open label editor without committing. |
showMoreChildren(parentKey) | (parentKey: RowKey | null) => void | Reveals the next childPageSize children of a paged parent (null for the root level) — what activating its "Load more" row does. |
cutItem(key) | (key: RowKey) => boolean | Marks a node for a keyboard move (what Ctrl+X does); pasteItem on any tree of the same dragGroup moves it. Wire both to buttons or a context menu for a single-pointer path. Requires allowDragging. |
pasteItem(targetKey, position?) | (targetKey: RowKey, position?: 'inside' | 'before' | 'after') => boolean | Moves the cut node of this tree's group onto targetKey through the same pipeline as a drop (itemReordering → itemReordered → itemTransferred). position defaults to inside (after when allowDropInside is off). |
Events 16
| Name | Type | Description |
|---|---|---|
itemExpanding / itemCollapsing | OgeTreeExpandingEvent<T> / OgeTreeCollapsingEvent<T> | Cancelable pre-events — set cancel = true to block the change. |
itemExpanded / itemCollapsed | OgeTreeExpandedEvent<T> / OgeTreeCollapsedEvent<T> | Emitted after the change committed. |
selectionChanging | OgeTreeSelectionChangingEvent<T> | Cancelable pre-event carrying the keys the selection would become. |
selectionChanged | OgeTreeSelectionChangedEvent<T> | Emitted after the selection committed, with previousKeys. |
itemSelectionChanged | OgeTreeItemSelectionChangedEvent<T> | Emitted for the single node whose own state flipped. |
itemClick / itemDblClick | OgeTreeItemClickEvent<T> | Emitted when a node row is clicked or double-clicked. |
itemContextMenu | OgeTreeItemContextMenuEvent<T> | Right-click, touch long-press, or the Menu key / Shift+F10 on the focused item — the grid’s rowContextMenu model. Carries key, item, clientX/Y (the pointer, or the item’s start/bottom corner from the keyboard), a mutable items: OgeMenuItem[], source ('pointer' | 'touch' | 'keyboard') and the originating event. Push items and the tree opens its own menu there — labelled by the item, focus back on the item when it closes; leave it empty and the browser menu stays. Filler and “load more” rows and a label being edited keep the native menu. |
childrenLoaded / childrenLoadFailed | OgeTreeChildrenLoadedEvent<T> / OgeTreeChildrenFailedEvent<T> | Emitted after a lazy loadChildren settled; the failure carries the original error. |
selectAllChanged | OgeTreeSelectAllChangedEvent | Emitted when the "select all" row is toggled. |
itemDragStarting | OgeTreeDragStartingEvent<T> | Cancelable: a node is about to be moved, by pointer drag or Ctrl+X (trigger). Set cancel to keep a locked or system node in place. |
itemDragOver | OgeTreeDragOverEvent<T> | Cancelable: a dragged node reached another drop spot (row or position) on this tree — set cancel to refuse it; no indicator shows and a drop there does nothing. Fires once per spot, not per pointer move. |
itemReordering / itemReordered | OgeTreeReorderingEvent<T> / OgeTreeReorderedEvent<T> | Cancelable pre-event and result of a move onto this tree, carrying position: 'inside' | 'before' | 'after', sourceTreeId / targetTreeId (different for a drop from another tree of the dragGroup) and trigger: 'pointer' | 'keyboard' | 'api'. The tree does not mutate your data. |
itemTransferred | OgeTreeTransferredEvent<T> | Fired by the source tree after one of its nodes moved to another tree of the same dragGroup — remove it from this tree's data. |
itemEditStarting | OgeTreeEditStartingEvent<T> | Cancelable pre-event of the label editor opening, with the current value. |
itemEditing / itemEdited | OgeTreeEditingEvent<T> / OgeTreeEditedEvent<T> | Cancelable pre-event and result of a label edit, carrying previousValue and value. Runs after validateEdit; an unchanged or blank label closes the editor without either. |
childPageShown | OgeTreeChildPageEvent<T> | Fired after a "Load more" row revealed the next page, with parentKey (null for the roots), shown and total. |
Types 14
Template slots
| Name | Type | Description |
|---|---|---|
[ogeTreeItemTemplate] | { $implicit, key, level, expanded, selected, checkState, hasChildren, highlightedHtml } | Replaces a node's built-in label. Renders inside role="treeitem", so it must not contain focusable controls. |
[ogeTreeExpandIconTemplate] | { $implicit: boolean, item, key, loading } | Replaces the expand/collapse chevron. |
[ogeTreeNoDataTemplate] | — | Replaces the empty state shown when the tree has no nodes or a search matched nothing. |
Keyboard (WAI-ARIA APG treeview)
| Name | Type | Description |
|---|---|---|
Down / Up Arrow | navigation | Moves focus over the visible nodes, skipping disabled ones. Trees do not wrap at the ends. |
Right Arrow | navigation | Opens a collapsed parent; on an open parent moves to its first child; no-op on a leaf. |
Left Arrow | navigation | Closes an open parent; otherwise moves focus to the parent node. |
Home / End | navigation | Moves to the first / last visible node. |
Enter | activation | Toggles a parent, or selects a leaf when a selection mode is set. |
Space | selection | Toggles selection on the focused node. Shift+Space selects the contiguous range. |
Printable characters | type-ahead | Moves focus to the next node whose label starts with the typed prefix, accent-insensitively. |
* | expansion | Expands every sibling at the focused level. |
Ctrl+A, Shift+Arrow, Ctrl+Shift+Home/End | multi-select | Select all, extend by one, and range-select to the start/end — the APG "recommended" model, so plain navigation needs no modifier. |
F2 | editing | Opens the label editor (allowEditing); inside it Enter commits, Escape cancels and the focus returns to the node. Advertised with aria-keyshortcuts. |
Ctrl+X, Ctrl+V, Ctrl+Shift+V | move | The keyboard twin of drag & drop (allowDragging): cut the focused node, then paste it into (or, with Shift, after) the focused target — in this tree or another of the dragGroup. Escape abandons the cut; each step is announced through the live region. |
Tree view configuration
Properties 15
OgeTreeViewMessages
| Name | Type | Default | Description |
|---|---|---|---|
selectAll | string | 'Select all' | Label of the "select all" row. |
searchPlaceholder | string | 'Search…' | Placeholder of the built-in search box. |
searchLabel | string | 'Search the tree' | Accessible name of the built-in search box. |
clearSearch | string | 'Clear search' | Accessible name of the search box's clear button. |
loadingChildren | string | 'Loading…' | Shown while a node's lazy children are loading. |
childrenLoadFailed | string | 'Could not load these items.' | Shown when loadChildren rejected. |
noData | string | 'No items to display' | Shown when the tree has no nodes at all. |
noSearchResults | string | 'No matching items' | Shown when a search matched nothing. |
loadMore | string | 'Show {count, plural, one {# more item} other {# more items}}' | Label of the "Load more" row under a paged parent (childPageSize); an ICU plural over count, the children still hidden. |
editLabel | string | 'Item name' | Accessible name of the in-place label editor. |
editInvalid | string | 'Enter a valid name.' | Shown when validateEdit rejects a value without its own message. |
cutAnnouncement | string | '{item} cut. Move to the target item and press Control+V to move it there, or Escape to cancel.' | Announced after Ctrl+X marked a node for a keyboard move. |
movedAnnouncement | string | '{position, select, inside {{item} moved into {target}.} before {{item} moved before {target}.} other {{item} moved after {target}.}}' | Announced after a move committed; an ICU select over position. |
moveCancelledAnnouncement | string | 'Move cancelled.' | Announced when Escape abandons a pending keyboard move. |
moveRejectedAnnouncement | string | '{item} cannot be moved here.' | Announced when the focused node cannot take the cut node (its own subtree). |
Types 4
Behavioural defaults
| Name | Type | Description |
|---|---|---|
itemHeight | number | undefined | Default row height used by virtualScroll. |
expandEvent | 'click' | 'dblclick' | undefined | Default for the expandEvent input. |
| Name | Type | Description |
|---|---|---|
provideOgeTreeViewConfig(config) | (config: OgeTreeViewConfigInput) => Provider | Application- or component-scoped defaults; shallow-merges messages over the built-ins. |
OGE_TREE_VIEW_CONFIG | InjectionToken<OgeTreeViewConfig> | The token itself, with a factory default — inject it to read the effective config. |
OgeDrawer
oge-drawerProperties 26
Layout
| Name | Type | Default | Description |
|---|---|---|---|
opened | boolean (two-way) | false | Whether the drawer is open. Two-way, so [(opened)] is the whole state. |
mode | 'overlay' | 'push' | 'side' | 'overlay' | overlay floats over the content, push shifts it aside without resizing it, side shrinks it so both share the row. This also decides modality — see the accessibility group. |
position | 'start' | 'end' | 'top' | 'bottom' | 'start' | Edge the panel is attached to. Logical, so start/end mirror in RTL with no flag to set. |
size | number | string | 260 | Size of the open panel along its cross axis. A number means pixels. |
minSize | number | string | undefined | — | Size of the closed panel — the compact rail that keeps icons visible. Only meaningful for mode: 'side': a rail belongs to the layout, and a modal drawer still partly on screen is not closed. |
compactBelow | number | undefined | — | Below this container inline size the drawer downgrades to 'overlay' and closes. Measured against the drawer's own box, never the window, so a drawer nested in a dialog or a split pane adapts to the room it actually has. |
disabled | boolean | false | Blocks every open and close gesture, open() and close() included. A drawer already open stays open and stays usable; only a compact close still goes through, because a drawer with no room left must stop covering the content. |
animationEnabled | boolean | true | Enables the open/close transition. |
animationDuration | number | 240 | Duration of that transition in milliseconds. Suppressed entirely under prefers-reduced-motion. |
Dismissal
| Name | Type | Default | Description |
|---|---|---|---|
showCloseButton | boolean | false | Renders the built-in close button in the panel, labelled by the close message. It closes through the full pipeline, so closeGuard still applies. |
shading | boolean | true | Renders the backdrop of a modal drawer. A persistent drawer never shades the content it shares the row with. |
closeOnEscape | boolean | true | Escape closes a modal drawer, and only when it is the topmost overlay — a popup opened inside it closes first. A persistent drawer never takes Escape from the page. |
closeOnBackdropClick | boolean | true | A click on the backdrop closes the drawer. Only a press that started on the backdrop counts, so a drag ending there does not close it. |
closeGuard | (() => boolean | Promise<boolean>) | undefined | — | Vetoes a close. Return false, throw, or reject to keep the drawer open; a promise reports pending through closePending and a second gesture meanwhile is dropped. |
scrollLock | boolean | false | Locks body scroll while a modal drawer is open, through the same ref-counted lock every other OGE overlay uses. Off by default, because a drawer is usually an in-page region rather than a page-level dialog. |
Accessibility
| Name | Type | Default | Description |
|---|---|---|---|
landmark | 'navigation' | 'complementary' | 'region' | 'navigation' | Landmark role while persistent. Ignored while modal, which is always role="dialog". |
ariaLabel | string | undefined | — | Accessible name of the panel. Falls back to the drawer message. |
ariaLabelledBy | string | undefined | — | id of an element naming the panel. Wins over ariaLabel, which is then cleared so there is only one name. |
messages | Partial<OgeDrawerMessages> | undefined | — | Per-instance overrides of the config strings — the panel’s fallback accessible name (drawer) and the close button’s label (close). |
autoFocus | 'first-tabbable' | 'panel' | 'none' | string | 'first-tabbable' | Where focus lands when a modal drawer opens; any other string is a CSS selector, and an [autofocus] element always wins. A persistent drawer never moves focus. |
restoreFocus | boolean | true | Returns focus to the opener on close, but only when focus would otherwise be orphaned — it never steals a target the user has moved to. |
inertBackground | boolean | true | Marks the content behind a modal drawer inert, so neither Tab nor assistive tech can reach it. Scoped to the drawer's own content region rather than the document, because a drawer wraps the very content it covers. None of the four reference drawers does this. |
drawerId | string (readonly) | — | id of the panel element. The panel stays in the DOM while closed, so a trigger's aria-controls always resolves to a real element. |
Navigation items & gestures
| Name | Type | Default | Description |
|---|---|---|---|
items | readonly OgeDrawerItem[] | undefined | — | Built-in navigation entries rendered at the top of the panel, before the panel content: links (url) or buttons, icons, badges and separators. Each entry stays in the Tab order and Arrow / Home / End move between them. In the mini rail (minSize, closed) only the icons show and the label becomes the accessible name and a tooltip. |
selectedKey | string | undefined (two-way) | — | Key of the active entry (aria-current="page"). Two-way: [(selectedKey)]. |
swipeEnabled | boolean | false | Touch gestures: an edge swipe opens the drawer, a swipe toward the edge closes it (reason 'swipe', through closing and closeGuard). Touch pointers only, RTL-aware; off by default so existing apps keep their behaviour. |
Methods 5
Methods
| Name | Type | Description |
|---|---|---|
open() | void | Opens the drawer through the cancelable pre-event. |
close() | void | Closes through the full pipeline (closing → closeGuard) with reason 'api'. |
toggle() | void | Opens when closed, closes when open. |
focus() | void | Re-applies the initial-focus resolution. No-op unless the drawer is open and modal. |
closePending | Signal<boolean> | True while an async closeGuard is in flight. |
Events 7
Events
| Name | Type | Description |
|---|---|---|
opening | OgeDrawerOpeningEvent | Cancelable — set cancel to keep the drawer closed; the two-way model is reset for you. |
afterOpened | void | The drawer finished opening. Fires on a render hook rather than transitionend, because the transition is CSS-only and prefers-reduced-motion zeroes it. |
closing | OgeDrawerClosingEvent | Cancelable, carries the reason. Runs before closeGuard. |
closed | OgeDrawerClosedEvent | The drawer finished closing. |
modeChanged | OgeDrawerModeChangedEvent | The resolved layout mode changed, carrying the requested mode and whether compactBelow forced it. |
itemClick | OgeDrawerItemClickEvent | An entry of items was activated (click, Enter or Space), with item, key, index and the DOM event. |
selectionChanged | OgeDrawerSelectionChangedEvent | selectedKey changed through the item list, with key and previousKey. |
Types 15
Content slots
| Name | Type | Description |
|---|---|---|
[ogeDrawerPanel] | attribute | Marks the element that becomes the drawer panel. Everything else projected into <oge-drawer> is the content. |
[ogeDrawerItemTemplate] | { $implicit: OgeDrawerItem; key; active; rail; index } | Replaces the content of a built-in entry. The drawer keeps the <a> / <button> around it — with aria-current, the disabled state and the rail tooltip — so the template must not add a focusable control. |
Types
| Name | Type | Description |
|---|---|---|
OgeDrawerMode | 'overlay' | 'push' | 'side' | Layout mode, and therefore modality. |
OgeDrawerPosition | 'start' | 'end' | 'top' | 'bottom' | Edge the panel attaches to; logical for RTL. |
OgeDrawerLandmark | 'navigation' | 'complementary' | 'region' | Landmark role of a persistent drawer. |
OgeDrawerAutoFocus | 'first-tabbable' | 'panel' | 'none' | string | Initial-focus strategy of a modal drawer. |
OgeDrawerCloseReason | 'api' | 'escape' | 'backdrop' | 'outside' | 'compact' | 'swipe' | Why the drawer closed. |
OgeDrawerOpeningEvent | { cancel: boolean } | Cancelable pre-event for opening. |
OgeDrawerClosingEvent | { cancel: boolean; reason: OgeDrawerCloseReason } | Cancelable pre-event for closing. |
OgeDrawerClosedEvent | { reason: OgeDrawerCloseReason } | Payload of closed. |
OgeDrawerModeChangedEvent | { mode; requestedMode; compact: boolean } | Payload of modeChanged. |
OgeDrawerItem | { key?; text?; icon?; url?; target?; disabled?; separator?; badge? } | One built-in entry. icon is SVG path data (d) for a 24×24 stroke icon; key defaults to text; separator: true renders a divider. |
OgeDrawerItemClickEvent | { item; key; index; event } | Payload of the item click. |
OgeDrawerSelectionChangedEvent | { key; previousKey; item; event? } | Payload of the selection change. |
resolveDrawerMode() | (request: OgeDrawerModeRequest) => OgeDrawerModeResult | The pure function in @oge-ui/core that decides whether a drawer keeps its mode or goes compact. DOM-free, so the rule is unit-tested on its own. A non-positive containerSize means “not measured yet” and the requested mode is returned unchanged. |
Drawer configuration
Properties 5
provideOgeDrawerConfig()
| Name | Type | Default | Description |
|---|---|---|---|
mode | OgeDrawerMode | — | Default for the mode input. |
position | OgeDrawerPosition | — | Default for the position input. |
size | number | string | — | Default for the size input. |
messages.drawer | string | 'Drawer' | Accessible name of the panel when the application supplies none. |
messages.close | string | 'Close drawer' | Label of a close affordance rendered in the panel. |
OgeStepper
oge-stepperProperties 15
Steps & selection
| Name | Type | Default | Description |
|---|---|---|---|
activeIndex | number (two-way) | 0 | Index of the active step. |
activeKey | string | undefined (two-way) | — | Key of the active step. Reconciled before the index, so an initial key binding wins over the index default on first run. |
steps | readonly OgeStepData[] | undefined | — | Data-driven steps, merged after any declarative <oge-step> children. |
linear | boolean | false | Blocks moving past a step that is neither completed nor optional. The default matches Material and PrimeNG; Kendo is the outlier at true. |
disabled | boolean | false | Blocks every step change. |
Layout & chrome
| Name | Type | Default | Description |
|---|---|---|---|
orientation | 'horizontal' | 'vertical' | 'horizontal' | Main axis of the step list. The ARIA semantics do not change with it — see the accessibility group. |
display | 'full' | 'label' | 'indicator' | 'full' | How much of each header renders: label plus description, label only, or just the round indicator. |
showNavigation | boolean | false | Renders the built-in Back / Next bar, which becomes Finish on the last step. None of the three reference steppers ships one. |
deferRendering | boolean | false | Creates a step's body on first activation. |
keepAlive | boolean | true | Keeps a body mounted after the user leaves it. |
Accessibility
| Name | Type | Default | Description |
|---|---|---|---|
keyboardNavigation | boolean | false | Adds arrow / Home / End over the headers. Off by default because the headers are buttons in a list, not tabs, so they are already Tab-reachable. It moves focus only, and deliberately does not wrap. |
ariaLabel | string | undefined | — | Accessible name of the step list. Falls back to the stepper message. |
messages | Partial<OgeStepperMessages> | undefined | — | Per-instance overrides of the config strings — the list’s accessible name, the optional/completed/invalid announcements and the navigation bar’s labels. |
stepperId | string (readonly) | — | id prefix of the generated header / panel pairs. |
changePending | Signal<boolean> | — | True while an async stepGuard is in flight. |
Methods 5
| Name | Type | Description |
|---|---|---|
next(event?: Event) | void | Advances one step, or confirms the finish when already on the last one. The guard runs either way, so a final step can still veto. |
previous(event?: Event) | void | Goes back one step, through the same pipeline. |
goTo(target: number | string, event?: Event) | void | Moves to a step by index or key. |
reset() | void | Clears the rendered-body cache and returns to the first step. |
focus() | void | Focuses the active step's header. |
Events 4
| Name | Type | Description |
|---|---|---|
stepChanging | OgeStepChangingEvent | Cancelable, emitted before the leaving step’s stepGuard runs. |
stepChanged | OgeStepChangedEvent | The active step changed. |
stepBlocked | OgeStepBlockedEvent | A move was refused, carrying reason: 'linear' | 'editable' | 'guard' | 'disabled'. Angular Material refuses silently. |
finished | OgeStepperFinishEvent | next() was confirmed on the last step. |
Types 14
OgeStep (declarative child)
| Name | Type | Description |
|---|---|---|
key / label / description | string | Identity and header text. |
icon / iconClass | string | undefined | SVG path data, or class(es) for an icon font — replacing the step number. |
completed / optional / editable | boolean | The linear gate: completed lets a linear stepper past, optional lets it past regardless, and editable: false blocks coming back. |
errorMessage | string | undefined | Shown under the label while invalid, replacing description so two sub-lines never compete. Angular Material has this; Kendo and PrimeNG do not. |
invalid / disabled / visible | boolean | Error state, non-activatable, and removal from the list. |
stepGuard | () => boolean | Promise<boolean> | Veto hook run when leaving this step. A throw and a rejection both veto. |
Types & directives
| Name | Type | Description |
|---|---|---|
OgeStepState | 'number' | 'active' | 'done' | 'error' | Derived indicator state; error outranks done, so a completed step that later fails still reads as needing attention. |
OgeStepperOrientation | 'horizontal' | 'vertical' | Main axis; the ARIA model is the same for both. |
OgeStepperDisplay | 'full' | 'label' | 'indicator' | How much of a header renders. |
OgeStepData | { key?; label?; description?; icon?; iconClass?; disabled?; visible?; completed?; optional?; editable?; invalid?; cssClass?; stepGuard? } | One data-driven step. |
OgeStepGuard | () => boolean | Promise<boolean> | Core's OgeAsyncGuard, the same veto contract the tabs' close guard and the accordion's expand guard use. |
[ogeStepperNext] / [ogeStepperPrevious] | directive | Turn any button into a navigation control. They find the stepper by DI when written inside it, or take one explicitly (ogeStepperNext [ogeStepperTarget]="wizard") from outside — which Material’s equivalents cannot do. |
[ogeStepHeaderTemplate] / [ogeStepIndicatorTemplate] / [ogeStepContentTemplate] | directive | Replace the label block, the round indicator, or supply lazy body content. |
<oge-form-steps> | directive (@oge-ui/forms) | Wraps this component inside <oge-form>. Step completion comes from the form's own per-step error rollup, so it behaves identically in all three binding modes, and leaving a step touches only that step's fields. |
Stepper configuration
Properties 5
provideOgeStepperConfig()
| Name | Type | Default | Description |
|---|---|---|---|
orientation / display / linear | defaults | — | Defaults for the matching inputs. |
messages.stepper | string | 'Steps' | Accessible name of the step list. |
messages.optional | string | 'Optional' | Sub-label of an optional step, wired through aria-describedby. |
messages.completed / messages.invalid | string | 'Completed' / 'Has errors' | Announced in visually hidden text, because the indicator glyph is aria-hidden. |
messages.previous / next / finish | string | 'Back' / 'Next' / 'Finish' | Labels of the built-in navigation bar. |
OgeBreadcrumb
oge-breadcrumbProperties 3
| Name | Type | Default | Description |
|---|---|---|---|
items | readonly OgeBreadcrumbItemData[] | undefined | — | Data-driven trail — a flat list, never nested. Rendered after any declarative <oge-breadcrumb-item> children — the house merge order. |
collapseMode | 'auto' | 'wrap' | 'none' | 'auto' | 'auto' collapses the oldest middle crumbs into an ellipsis menu against the breadcrumb's own container width (never the window) — the first and last crumb always stay visible, and the collapsed crumbs remain reachable as real links. 'wrap' breaks onto multiple rows; 'none' keeps one scrollable row. The fitting arithmetic is core's pure fitToolbarItems. |
messages | Partial<OgeBreadcrumbMessages> | undefined | — | Per-instance overrides of the user-facing strings, merged over provideOgeBreadcrumbConfig(). |
Methods 1
| Name | Type | Description |
|---|---|---|
focus() | void | Focuses the first interactive crumb — or the ellipsis button when the trail is collapsed. |
Events 1
| Name | Type | Description |
|---|---|---|
itemClick | OgeBreadcrumbItemClickEvent | A crumb (inline or inside the ellipsis menu) was activated. Not fired by disabled crumbs or by the last crumb — that is the current page. On url crumbs, event.preventDefault() hands navigation to a router. |
Types 5
| Name | Type | Description |
|---|---|---|
OgeBreadcrumbItemData<T> | { text; key?; value?; url?; hint?; icon?; iconClass?; disabled?; visible? } | A deliberately narrow interface — no submenu, checked or shortcut fields, because none of them mean anything on a trail. url renders the crumb as a real <a href> (ignored on the last crumb); disabled crumbs are exposed via aria-disabled but inert; visible: false removes the crumb. |
OgeBreadcrumbCollapseMode | 'auto' | 'wrap' | 'none' | How the breadcrumb behaves when room runs out. |
OgeBreadcrumbItemClickEvent | { item; key?; index; event } | index is the position within the full trail, collapsed crumbs included. |
OgeBreadcrumbItemTemplate | directive — ng-template[ogeBreadcrumbItemTemplate] | Replaces the crumb's interior only — the link/current/disabled element semantics stay with the component. Context: OgeBreadcrumbItemTemplateContext ($implicit, index, last). |
OgeBreadcrumbSeparatorTemplate | directive — ng-template[ogeBreadcrumbSeparatorTemplate] | Replaces the default chevron separator. Rendered aria-hidden — a separator is decoration, never content (APG). Context: OgeBreadcrumbSeparatorTemplateContext. |
OgeBreadcrumbItem
oge-breadcrumb-itemProperties 9
| Name | Type | Default | Description |
|---|---|---|---|
text | string | '' | Label of the crumb. |
key | string | undefined | — | Stable identity used in event payloads and DOM ids. |
value | unknown | — | Consumer-defined value carried through click events. |
url | string | undefined | — | Renders the crumb as a real link (<a href>). |
hint | string | undefined | — | Tooltip (native title). |
icon | string | undefined | — | SVG path data (d) for a leading aria-hidden icon. |
iconClass | string | undefined | — | Class(es) for a leading icon element — the icon-font hook. |
disabled | boolean | false | Disabled crumbs are exposed (aria-disabled) but inert. |
visible | boolean | true | false removes the crumb entirely. |
Breadcrumb configuration
Properties 2
provideOgeBreadcrumbConfig()
| Name | Type | Description |
|---|---|---|
messages | OgeBreadcrumbMessages | Every user-facing string: breadcrumb (accessible name of the <nav> landmark, default Breadcrumb) and collapsed (aria label of the ellipsis button, default Show hidden items). |
collapseMode | 'auto' | 'wrap' | 'none' | undefined | Default for the collapseMode input. |
OgePagination
oge-paginationProperties 14
OgePagination
| Name | Type | Default | Description |
|---|---|---|---|
pageIndex | model<number> | 0 | The current page — 0-based, two-way. Auto-clamped when the page count shrinks (an implicit pageIndexChange, no rich event). DevExtreme migrators: check your origin — dx documentation is ambiguous about its base. |
pageSize | model<number> | 20 | Items per page — two-way. 0 means "all items on one page" (the grid pager contract, kept aligned for eventual delegation). |
itemCount | number | undefined | — | Total items. undefined = unknown total: only prev/next and a "Page N" indicator render, and next never disables — clamp pageIndex yourself when the server reports the end. |
pageSizes | readonly (number | 'all')[] | undefined | — | Page-size choices; 'all' adds the unpaged option. Presence shows the selector — no separate boolean (DevExtreme's showPageSizeSelector is deliberately skipped). |
showInfo | boolean | false | Renders the {from}–{to} of {itemCount} range (the info message template) in an aria-live="polite" region. |
showFirstLastButtons | boolean | false | First/last jump buttons (Material name and default) — the numeric window already renders both rail pages, so they are opt-in chrome. |
showNavigationButtons | boolean | true | Prev/next buttons; forced on in compact and unknown-total modes (they are the backbone there). |
showJumpToPageInput | boolean | false | Jump-to-page input (PrimeNG name; Kendo's type: 'input'): 1-based display, Enter/change commit, clamped into range, display re-synced after a clamp. Hidden while the total is unknown. |
maxButtons | number | undefined | 7 (config) | Total rendered slots including ellipsis slots — the window width never changes while paging, so the bar never jitters. An ellipsis hiding a single page renders the page instead. |
displayMode | 'full' | 'compact' | 'adaptive' | 'full' (config) | 'compact' renders the N / M indicator; 'adaptive' switches below compactBelow (config, default 480px), measured against the bar's own container via ResizeObserver — never the window. |
disabled | boolean | false | Disables every control (native disabled — they are all real buttons/selects/inputs). |
size | 'sm' | 'md' | 'lg' | 'md' | Density preset (26/32/40px hit targets). |
messages | Partial<OgePaginationMessages> | — | Per-instance string overrides, merged over the config messages. Several bars on one page need distinct paginationLabel values — landmarks must be unique (axe landmark-unique). |
pageCount | Signal<number | undefined> | — | Readonly derived page count; undefined while the total is unknown. DevExtreme's getPageCount() as a signal — the house read API. |
Methods 3
| Name | Type | Description |
|---|---|---|
firstPage() / lastPage() / nextPage() / previousPage() | void | Programmatic paging (Material names). lastPage() no-ops while the total is unknown. Model updates only — no rich event (no user event). |
hasPreviousPage() / hasNextPage() | boolean | hasNextPage() returns true while the total is unknown — the component cannot know the end. |
focus() | void | Moves keyboard focus to the first enabled control. |
Events 3
| Name | Type | Description |
|---|---|---|
pageChanged | OgePaginationPageChangedEvent | { pageIndex, previousPageIndex, pageSize, event } — user interactions only; programmatic writes and auto-clamps update the model without it. |
pageSizeChanged | OgePaginationPageSizeChangedEvent | { pageSize, previousPageSize, pageIndex, event } — pageIndex reports the post-clamp page (changing the size can move the current page). |
pageIndexChange / pageSizeChange | number | The implicit model outputs — fire on every change including programmatic writes and auto-clamps. |
Types 2
| Name | Type | Description |
|---|---|---|
OgePaginationDisplayMode / OgePaginationSize | types | The string unions of the mode and density inputs. |
resolvePageWindow / resolvePageRange / resolvePageCount / OGE_PAGE_ELLIPSIS | @oge-ui/core | The DOM-free paging kernel (pagination-math.ts): the constant-width page window with real ellipsis markers, the from/to info arithmetic and the never-below-1 page-count division — unit-tested without a DOM. |
Pagination configuration
Properties 2
OgePaginationConfig
| Name | Type | Description |
|---|---|---|
messages | OgePaginationMessages | All strings: paginationLabel (the <nav> name), firstPage/lastPage/previousPage/nextPage, pageLabel ({page}, 1-based), info ({from} {to} {itemCount}), pageInfoUnknown, pageIndicator ({page} {pageCount}), pageSizeLabel, allRows, jumpLabel. |
displayMode / compactBelow / maxButtons | OgePaginationDisplayMode / number / number | Application-wide input defaults; the component resolves input ?? config ?? literal (480px / 7). |
Methods 1
| Name | Type | Description |
|---|---|---|
provideOgePaginationConfig(config: OgePaginationConfigInput) | Provider | Application- or component-scoped defaults; shallow-merges messages over the built-ins. |