import { AfterContentInit, ElementRef, OnChanges, OnDestroy, QueryList, Renderer } from "@angular/core"; import { Router } from "@angular/router"; import { NSRouterLink } from "./ns-router-link"; /** * The NSRouterLinkActive directive lets you add a CSS class to an element when the link"s route * becomes active. * * Consider the following example: * * ``` * Bob * ``` * * When the url is either "/user" or "/user/bob", the active-link class will * be added to the component. If the url changes, the class will be removed. * * You can set more than one class, as follows: * * ``` * Bob * Bob * ``` * * You can configure NSRouterLinkActive by passing `exact: true`. This will add the * classes only when the url matches the link exactly. * * ``` * Bob * ``` * * Finally, you can apply the NSRouterLinkActive directive to an ancestor of a RouterLink. * * ``` *
* ``` * * This will set the active-link class on the div tag if the url is either "/user/jim" or * "/user/bob". * * @stable */ export declare class NSRouterLinkActive implements OnChanges, OnDestroy, AfterContentInit { private router; private element; private renderer; links: QueryList