import * as i0 from '@angular/core';
import { AfterContentInit, OnDestroy, OnInit, ElementRef } from '@angular/core';
import { NavigationExtras } from '@angular/router';
import { Observable } from 'rxjs';
/**
* @description
* `eui-breadcrumb` navigation component displaying hierarchical page location with linked path segments.
* Automatically manages relationships between `eui-breadcrumb` items for proper navigation flow.
* Detects and coordinates child EuiBreadcrumbItemComponent instances through content projection.
* Provides semantic navigation structure with automatic previous/next item linking.
* Typically used for showing user location within site hierarchy and enabling quick navigation to parent pages.
*
* @usageNotes
* #### Basic breadcrumb navigation
* ```html
*
*
*
*
*
*
* ```
*
* #### With navigation extras
* ```html
*
*
*
*
*
* ```
*
* ### Accessibility
* - Provides semantic navigation structure for screen readers
* - Each item is keyboard accessible and focusable
* - ARIA labels on icons provide context for screen reader users
* - Current page (last item) is typically not linked
* - Separators between items are handled automatically
*
* ### Notes
* - Must contain eui-breadcrumb-item children for proper functionality
* - Automatically establishes previous/next relationships between items
* - Items are rendered in the order they appear in the template
* - Last item typically represents current page and should not have a link
* - Supports responsive behavior with automatic item collapsing
* - Uses Angular Router for navigation when links are provided
* - External URLs (starting with 'http') open in same window
*/
declare class EuiBreadcrumbComponent implements AfterContentInit, OnDestroy {
string: string;
/** Query list of breadcrumb items occurrences on the content */
private breadcrumbItems;
private vcr;
private destroy$;
/** Observable emitting when the breadcrumb Items List has changed */
private breadcrumbItemsListChanged;
private viewContainerRef;
ngAfterContentInit(): void;
ngOnDestroy(): void;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵcmp: i0.ɵɵComponentDeclaration;
}
/**
* @description
* Individual breadcrumb item component representing a single segment in the breadcrumb navigation path.
* Provides clickable navigation links with optional icons and automatic relationship management with adjacent items.
* Supports Angular Router navigation with both internal routes and external URLs.
* Automatically generates unique IDs when not provided and manages collapsed state for responsive layouts.
* Used within eui-breadcrumb container for hierarchical navigation display.
*
* @usageNotes
* ```html
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
* ```
*
* ### Accessibility
* - Each item is keyboard accessible with Enter/Space activation
* - ariaLabel provides screen reader context for icon-only items
* - Non-linked items (current page) are not focusable
* - Label text is announced by screen readers
* - Icon and label combination provides visual and semantic meaning
*
* ### Notes
* - Must be used within eui-breadcrumb parent component
* - id is auto-generated if not provided
* - link supports string URLs, Angular Router commands (array), or null for non-clickable items
* - External URLs (starting with 'http') open in same window
* - navigationExtras passes options to Angular Router (queryParams, fragment, etc.)
* - iconSvgName follows EUI icon naming convention
* - Last item in breadcrumb typically has no link (represents current page)
* - Label may be truncated in responsive layouts
* - Previous/next relationships are managed automatically by parent component
*/
declare class EuiBreadcrumbItemComponent implements OnDestroy, OnInit {
string: string;
/**
* Unique identifier for the breadcrumb item.
* Automatically generated if not provided.
* Optional.
*/
id: string;
/**
* Text label displayed for the breadcrumb item.
* May be truncated if too long to fit available space.
* Required for item display.
*/
label: string;
/**
* SVG icon name displayed alongside the breadcrumb label.
* Follows EUI icon naming convention (e.g., 'home:outline').
* Optional.
*/
iconSvgName: string;
/**
* ARIA label for the breadcrumb item icon for accessibility.
* Provides screen reader description of the icon.
* @default 'Breadcrumb item icon'
*/
ariaLabel: string;
/**
* Navigation target for the breadcrumb item.
* Supports Angular Router commands (array), URL string, or null to disable link.
* String starting with 'http' opens as external URL.
* Optional - when null/undefined, item is not clickable.
*/
link: string | any[];
/**
* Additional navigation options passed to Angular Router.
* Supports query params, fragments, state, and other NavigationExtras properties.
* Optional.
*/
navigationExtras: NavigationExtras;
/** calculated item width */
width: number;
hasPrevious: boolean;
hasNext: boolean;
/** state of breadcrumb item in case of collapsed */
collapsed: boolean;
elementRef: ElementRef;
private previousCrumb;
private nextCrumb;
private host;
private router;
private cdr;
private logService;
ngOnInit(): void;
ngOnDestroy(): void;
destroy(): void;
/**
* Sets the previous breadcrumb item in the navigation chain.
* Called internally by parent eui-breadcrumb component to establish item relationships.
*/
setPrevious(breadcrumbItem: EuiBreadcrumbItemComponent): void;
/**
* Sets the next breadcrumb item in the navigation chain.
* Called internally by parent eui-breadcrumb component to establish item relationships.
*/
setNext(breadcrumbItem: EuiBreadcrumbItemComponent): void;
/**
* A callback to navigate to the given link using ng-router.
*
* @param event
*/
onClick(): boolean;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵcmp: i0.ɵɵComponentDeclaration;
}
type ArrayElement = A extends readonly (infer T)[] ? T : never;
type DeepWriteable = {
-readonly [P in keyof T]: DeepWriteable;
};
type Cast = X extends Y ? X : Y;
type FromEntries = T extends [infer Key, any][] ? {
[K in Cast]: Extract, [K, any]>[1];
} : {
[key in string]: any;
};
type FromEntriesWithReadOnly = FromEntries>;
declare global {
interface ObjectConstructor {
fromEntries(obj: T): FromEntriesWithReadOnly;
}
}
declare class BreadCrumbItem {
/** A unique ID for each crumb linked to a page */
id: string;
/** The label of the crumb */
label: string;
/** A URL link. Commands to pass to {@link Router#createUrlTree Router#createUrlTree}.
* - **array**: commands to pass to {@link Router#createUrlTree Router#createUrlTree}.
* - **string**: shorthand for array of commands with just the string, i.e. `['/route']`
* - **null|undefined**: Disables the link by removing the `href`
*/
get link(): string | any[];
set link(link: string | any[]);
/** Extras for Angular Router */
navigationExtras?: NavigationExtras;
private _link?;
}
declare class EuiBreadcrumbService {
/**
* An observable on which observers can be notified on breadcrumb changes
*/
breadcrumbs$: Observable;
/**
* A behavior subject to emit breadcrumb whenever that changes
*/
private breadcrumbsSource$;
/**
* An array to hold BreadCrumbItem metadata used to render the BreadCrumbItem
*/
private breadcrumb;
constructor();
/**
* Adds a new BreadCrumbItem into the breadcrumb
*
* @param breadCrumbItem The BreadCrumbItem you want to insert in trail
* @param [after] The ID of the BreadCrumbItem after given one will be inserted.
* @param [removeAfter=false] All crumbs after given ID will be removed.
* @throws Will throw an error if given after ID is not found on current trail.
*/
addCrumb(breadCrumbItem: BreadCrumbItem, after?: string, removeAfter?: boolean): void;
/**
* Remove a BreadCrumbItem based on a given ID
*
* @param id Optional: The ID of BreadCrumbItem to be removed
* If no id provided then the last item will be popped.
*/
removeCrumb(id?: string): void;
/**
* Update a specific entry in the data structure
*
* @param BreadCrumbItem The BreadCrumbItem to match and update
* @throws Will throw an Error if BreadCrumbItem is not part of the breadcrumb
*/
updateCrumb(item: BreadCrumbItem): void;
/**
* Returns current breadcrumb
*/
getBreadcrumb(): BreadCrumbItem[];
/**
* Sets the breadcrumb
*/
setBreadcrumb(breadcrumb: BreadCrumbItem[]): void;
static ɵfac: i0.ɵɵFactoryDeclaration;
static ɵprov: i0.ɵɵInjectableDeclaration;
}
declare const EUI_BREADCRUMB: readonly [typeof EuiBreadcrumbComponent, typeof EuiBreadcrumbItemComponent];
export { BreadCrumbItem, EUI_BREADCRUMB, EuiBreadcrumbComponent, EuiBreadcrumbItemComponent, EuiBreadcrumbService };
export type { ArrayElement, FromEntriesWithReadOnly };
//# sourceMappingURL=eui-components-eui-breadcrumb.d.ts.map