internal/fetch/dochtml: add Package Files to sidenav
Run-TryBot: Julie Qiu
TryBot-Result: kokoro
@@ -62,28 +62,33 @@ var htmlPackage = template.Must(template.New("package").Funcs(
<nav class="DocNav js-sideNav">
<ul role="tree" aria-label="Outline">
{{if or .Doc (index .Examples.Map "")}}
- <li role="none">
+ <li class="DocNav-overview" role="none">
<a href="#pkg-overview" role="treeitem" aria-level="1" tabindex="0">Overview</a>
</li>
{{end}}
{{if .Examples.List}}
- <li role="none">
+ <li class="DocNav-examples" role="none">
<a href="#pkg-examples" role="treeitem" aria-level="1" tabindex="-1">Examples</a>
</li>
{{end}}
+ {{if .Filenames}}
+ <li class="DocNav-files" role="none">
+ <a href="#pkg-files" role="treeitem" aria-level="1" tabindex="-1">Package Files</a>
+ </li>
+ {{end}}
{{if .Consts}}
- <li role="none">
+ <li class="DocNav-constants" role="none">
<a href="#pkg-constants" role="treeitem" aria-level="1" tabindex="-1">Constants</a>
</li>
{{end}}
{{if .Vars}}
- <li role="none">
+ <li class="DocNav-variables" role="none">
<a href="#pkg-variables" role="treeitem" aria-level="1" tabindex="-1">Variables</a>
</li>
{{end}}
{{if .Funcs}}
- <li role="none">
+ <li class="DocNav-functions" role="none">
<span class="DocNav-groupLabel" role="treeitem" aria-expanded="false" aria-level="1" aria-owns="nav-group-functions" tabindex="-1">Functions</span>
<ul role="group" id="nav-group-functions">
{{range .Funcs}}
@@ -96,7 +101,7 @@ var htmlPackage = template.Must(template.New("package").Funcs(
{{end}}
{{if .Types}}
- <li role="none">
+ <li class="DocNav-types" role="none">
<span class="DocNav-groupLabel" role="treeitem" aria-expanded="false" aria-level="1" aria-owns="nav-group-types" tabindex="-1">Types</span>
<ul role="group" id="nav-group-types">
{{range .Types}}
@@ -128,7 +133,7 @@ var htmlPackage = template.Must(template.New("package").Funcs(
{{end}}
{{if .Notes}}
- <li role="none">
+ <li class="DocNav-notes" role="none">
<span class="DocNav-groupLabel" role="treeitem" aria-expanded="true" aria-level="1" aria-owns="nav-group-notes" tabindex="-1">Notes</span>
<ul role="group" id="nav-group-notes">
{{range $marker, $item := .Notes}}
