blob: a5357617e2e25e6936d1dff5e172b05b61169ef6 [file] [log] [blame]
<!--
Copyright 2020 The Go Authors. All rights reserved.
Use of this source code is governed by a BSD-style
license that can be found in the LICENSE file.
-->
{{define "imports"}}
<div>
{{if or .ExternalImports .InternalImports .StdLib}}
{{if .ExternalImports}}
<h2 class="Imports-heading">Imports</h2>
<ul class="Imports-list">
{{range .ExternalImports}}
<li><a href="/{{.}}">{{.}}</a></li>
{{end}}
</ul>
{{end}}
{{if .InternalImports}}
<h2 class="Imports-heading">Imports in module “{{.ModulePath}}”</h2>
<ul class="Imports-list">
{{range .InternalImports}}
<li><a href="/{{.}}">{{.}}</a></li>
{{end}}
</ul>
{{end}}
{{if .StdLib}}
<h2 class="Imports-heading">Standard library Imports</h2>
<ul class="Imports-list">
{{range .StdLib}}
<li><a href="/{{.}}">{{.}}</a></li>
{{end}}
</ul>
{{end}}
{{else}}
{{template "empty_content" "This package does not have any imports!"}}
{{end}}
</div>
{{end}}