Canopy Side Nav — Best Practices
SkillDev toolsBest practices for the Canopy Side Nav component. Trigger when building sidebar navigation, account section navigation, or multi-page navigation panels in an Angular project using Canopy.
Available today. Use it from your connected AI after setup.
No other account needed.
Connect ahel once, and every AI you use reads what you have installed.
Then ask your AI: use the Canopy Side Nav — Best Practices skill
What this skill tells your AI
The instructions your AI receives, as published by legal-and-general/canopy in skills/best-practice/side-nav/SKILL.md and read by ahel’s review.
This skill provides usage guidance and input reference for the Canopy side nav components from @legal-and-general/canopy.
Apply this skill whenever you use LgSideNavComponent or lg-side-nav.
Import
import {
LgSideNavComponent,
LgSideNavBarComponent,
LgSideNavBarItemComponent,
LgSideNavBarItemHeadingComponent,
LgSideNavBarItemContentComponent,
LgSideNavBarFooterComponent,
LgSideNavBarLinkDirective,
LgSideNavContentComponent,
} from '@legal-and-general/canopy';
Basic Usage
<lg-side-nav>
<lg-side-nav-bar label="Account navigation">
<a id="nav-overview"
routerLink="overview"
[isActive]="true"
lgSideNavBarLink>
<lg-side-nav-bar-item>
<lg-side-nav-bar-item-heading>Overview</lg-side-nav-bar-item-heading>
</lg-side-nav-bar-item>
</a>
<a id="nav-details"
routerLink="personal-details"
lgSideNavBarLink>
<lg-side-nav-bar-item>
<lg-side-nav-bar-item-heading>Personal details</lg-side-nav-bar-item-heading>
<lg-side-nav-bar-item-content>
Your name, date of birth and National Insurance number.
</lg-side-nav-bar-item-content>
</lg-side-nav-bar-item>
</a>
<lg-side-nav-bar-footer>
<a lg-button lgMarginTop="8" priority="secondary" [fullWidth]="false" href="#">
Logout
</a>
</lg-side-nav-bar-footer>
</lg-side-nav-bar>
<lg-side-nav-content tabindex="0">
<router-outlet></router-outlet>
</lg-side-nav-content>
</lg-side-nav>
Component Reference
| Component / Directive | Purpose |
|---|---|
lg-side-nav | Root container for the bar + content layout. |
lg-side-nav-bar | Projects navigation link items. |
lgSideNavBarLink | Directive applied to <a> to style and activate links. |
lg-side-nav-bar-item | Wraps heading and optional description for each link. |
lg-side-nav-bar-item-heading | Main label for a nav item. |
lg-side-nav-bar-item-content | Optional descriptive text for a nav item. |
lg-side-nav-bar-footer | Fixed footer area below the nav items (e.g. logout button). |
lg-side-nav-content | Content display area — contains <router-outlet>. |
LgSideNavBarLinkDirective Inputs
| Input | Type | Default | Description |
|---|---|---|---|
isActive | boolean | false | Marks this link as the currently active route. |
Design Constraints
- On mobile, the navigation bar moves below the content area, not to the left.
lg-side-nav-contentmust contain<router-outlet>for route-based navigation.- Always provide an accessible
labelonlg-side-nav-barto identify the navigation region. - This component is pending brand modernisation.
Signals
- GitHub stars
- 23
- Forks
- 46
- Last commit
- Sep 2026
Advanced
- Catalog kind
- skill
- Gateway key
canopy-side-nav- Source
- github.com/legal-and-general/canopy