Skip to content

Commit 0091dfc

Browse files
Clarify hasSubItems usage in App Side Nav (#3134)
Co-authored-by: Kristin Bradley <kristin.bradley@hashicorp.com>
1 parent 125e175 commit 0091dfc

File tree

4 files changed

+10
-6
lines changed

4 files changed

+10
-6
lines changed

website/docs/components/app-side-nav/partials/code/how-to-use.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -221,14 +221,12 @@ If you find yourself in the situation of wanting/needing to customize or change
221221

222222
### Accessibility
223223

224+
Since this component is layout-only, there are no built-in accessibility features: you are responsible for making sure your custom App Side Nav implementation is conformant to the WCAG requirements.
225+
224226
#### `aria` attributes
225227

226228
The App Side Nav component already provides some of the required `aria` attributes. But other attributes are needed when declaring its content. Please refer to the [Accessibility](/components/app-side-nav?tab=accessibility) section for more details.
227229

228230
#### Animations
229231

230232
Animations and transition on the component will not take place if the user has `prefers-reduced-motion` enabled in their browser or operating system.
231-
232-
### Accessibility
233-
234-
Since this component is layout-only, there are no built-in accessibility features: you are responsible for making sure your custom App Side Nav implementation is conformant to the WCAG requirements.

website/docs/components/app-side-nav/partials/guidelines/guidelines.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ The body consists of a group of sections with vertical lists of links, typically
2626

2727
![App Side Nav section without a title](/assets/components/app-side-nav/section-without-title.png)
2828

29-
3029
### List items
3130

3231
#### Without icon
@@ -69,7 +68,14 @@ Don’t override the color of the icon within the list item or incorporate a bra
6968

7069
Use `hasSubItems` to show or signify that a link has a nested level of navigation.
7170

72-
!["Settings" list item with a right arrow icon to show that it has sub-items](/assets/components/app-side-nav/list-item-with-nested-items.png)
71+
!["Settings" list item with a right arrow icon to show that it has sub-items, with an example of the list of sub-items within settings; Organization Settings including "General", "Teams", and "Runs".](/assets/components/app-side-nav/list-item-with-nested-items.png)
72+
73+
!!! Dont
74+
75+
Don’t use `hasSubItems` to indicate that a link in the App Side Nav directs to a page _containing_ a list of links within the main content area of the page itself.
76+
77+
![An example of a list item with the hasSubItems property with links directly within the page linking to other parts of the application](/assets/components/app-side-nav/list-item-nested-items-dont.png)
78+
!!!
7379

7480
#### External links
7581

34.7 KB
Loading
22.4 KB
Loading

0 commit comments

Comments
 (0)