]> Cypherpunks repositories - gostls13.git/commitdiff
godoc: static ids should be #lowercase
authorRob Pike <r@golang.org>
Mon, 13 Feb 2012 03:34:30 +0000 (14:34 +1100)
committerRob Pike <r@golang.org>
Mon, 13 Feb 2012 03:34:30 +0000 (14:34 +1100)
so they don't collide with names like #Index.
Fixes #2970.

R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5655066

lib/godoc/package.html

index e0df513d6a95230f33d7b096d361c10ac4c4f849..afb0d4ae1fed5a8172980108a77738ea24e5b4fa 100644 (file)
                        <dd><code>import "{{html .ImportPath}}"</code></dd>
                        </dl>
                        <dl>
-                       <dd><a href="#Overview">Overview</a></dd>
-                       <dd><a href="#Index">Index</a></dd>
+                       <dd><a href="#overview">Overview</a></dd>
+                       <dd><a href="#index">Index</a></dd>
                        {{if $.Dirs}}
                                <dd><a href="#Subdirectories">Subdirectories</a></dd>
                        {{end}}
                        </dl>
                </div>
-               <h2 id="Overview">Overview</h2>
+               <h2 id="overview">Overview</h2>
                <!-- The package's Name is printed as title by the top-level template -->
                {{comment_html .Doc}}
        
-               <h2 id="Index">Index</h2>
+               <h2 id="index">Index</h2>
                <!-- Table of contents for API; must be named manual-nav to turn off auto nav. -->
                <div id="manual-nav">
                        <dl>
                </dl>
        
                {{with .Consts}}
-                       <h2 id="Constants">Constants</h2>
+                       <h2 id="constants">Constants</h2>
                        {{range .}}
                                {{comment_html .Doc}}
                                <pre>{{node_html .Decl $.FSet}}</pre>
                        {{end}}
                {{end}}
                {{with .Vars}}
-                       <h2 id="Variables">Variables</h2>
+                       <h2 id="variables">Variables</h2>
                        {{range .}}
                                {{comment_html .Doc}}
                                <pre>{{node_html .Decl $.FSet}}</pre>
        {{end}}
 
        {{with .Bugs}}
-               <h2 id="Bugs">Bugs</h2>
+               <h2 id="bugs">Bugs</h2>
                {{range .}}
                {{comment_html .}}
                {{end}}
 
 {{with .Dirs}}
        {{/* DirList entries are numbers and strings - no need for FSet */}}
-       <h2 id="Subdirectories">Subdirectories</h2>
+       <h2 id="subdirectories">Subdirectories</h2>
        <p>
        <table class="layout">
        <tr>