xng-breadcrumb
Version:
A declarative and reactive breadcrumb approach for Angular 6 and beyond https://www.npmjs.com/package/xng-breadcrumb
36 lines (35 loc) • 960 B
TypeScript
/**
* Breadcrumb item built internally, private to this module
*/
export interface Breadcrumb {
/**
* breacrumb label for a route
*/
label?: string;
/**
* unique alias name for a route path
*/
alias?: string;
/**
* hide or show the breadcrumb item
*/
skip?: boolean;
/**
* custom data for each breadcrumb that is passed back to ng-template
*/
info?: any;
/**
* actual route path with resolved param. Ex /mentor/2, connect/edit
*/
routeLink?: string;
/**
* route with path params converted to a RegExp
* path '/mentor/:id' becomes routeRegex '/mentor/[^/]+', which can be matched against when needed
*/
routeRegex?: string;
/**
* isAutoGeneratedLabel has to be present at component level but not at the service,
* since we may need to support multiple breadcrumb components in same app
*/
isAutoGeneratedLabel?: boolean;
}