Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(823)

Delta Between Two Patch Sets: lib/godoc/package.html

Issue 6631057: code review 6631057: godoc: add dropdown playground to nav bar (Closed)
Left Patch Set: Created 12 years, 5 months ago
Right Patch Set: diff -r cac6af12528b https://code.google.com/p/go Created 12 years, 5 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Right: Side by side diff | Download
« no previous file with change/comment | « lib/godoc/godoc.html ('k') | src/cmd/godoc/godoc.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
(no file at all)
1 <!-- 1 <!--
2 Copyright 2009 The Go Authors. All rights reserved. 2 Copyright 2009 The Go Authors. All rights reserved.
3 Use of this source code is governed by a BSD-style 3 Use of this source code is governed by a BSD-style
4 license that can be found in the LICENSE file. 4 license that can be found in the LICENSE file.
5 --> 5 -->
6 <!-- 6 <!--
7 Note: Static (i.e., not template-generated) href and id 7 Note: Static (i.e., not template-generated) href and id
8 attributes start with "pkg-" to make it impossible for 8 attributes start with "pkg-" to make it impossible for
9 them to conflict with generated attributes (some of which 9 them to conflict with generated attributes (some of which
10 correspond to Go identifiers). 10 correspond to Go identifiers).
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 156
157 {{range .Methods}} 157 {{range .Methods}}
158 {{$name_html := html .Name}} 158 {{$name_html := html .Name}}
159 <h3 id="{{$tname_html}}.{{$name_html}}">func ({{ html .Recv}}) <a href="{{posLink_url .Decl $.FSet}}">{{$name_html}}</a></h3> 159 <h3 id="{{$tname_html}}.{{$name_html}}">func ({{ html .Recv}}) <a href="{{posLink_url .Decl $.FSet}}">{{$name_html}}</a></h3>
160 <pre>{{node_html .Decl $.FSet}}</pre> 160 <pre>{{node_html .Decl $.FSet}}</pre>
161 {{comment_html .Doc}} 161 {{comment_html .Doc}}
162 {{$name := printf "%s_%s" $tname .Name}} 162 {{$name := printf "%s_%s" $tname .Name}}
163 {{example_html $name $.Examples $.FSet}} 163 {{example_html $name $.Examples $.FSet}}
164 {{end}} 164 {{end}}
165 {{end}} 165 {{end}}
166 </div>
167 {{else}} {{/* not a package; is a command */}} 166 {{else}} {{/* not a package; is a command */}}
168 {{comment_html .Doc}} 167 {{comment_html .Doc}}
169 {{end}} 168 {{end}}
170 169
171 {{with .Bugs}} 170 {{with .Bugs}}
172 <h2 id="pkg-bugs">Bugs</h2> 171 <h2 id="pkg-bugs">Bugs</h2>
173 {{range .}} 172 {{range .}}
174 {{comment_html .}} 173 {{comment_html .}}
175 {{end}} 174 {{end}}
176 {{end}} 175 {{end}}
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 </tr> 216 </tr>
218 {{end}} 217 {{end}}
219 {{end}} 218 {{end}}
220 </table> 219 </table>
221 {{if $.PDoc}}{{else}} 220 {{if $.PDoc}}{{else}}
222 <p>Need more packages? Take a look at the <a href="http://godashboard.ap pspot.com/">Go Project Dashboard</a>.</p> 221 <p>Need more packages? Take a look at the <a href="http://godashboard.ap pspot.com/">Go Project Dashboard</a>.</p>
223 {{end}} 222 {{end}}
224 {{end}} 223 {{end}}
225 224
226 {{if $.Examples}} 225 {{if $.Examples}}
227 <script type="text/javascript" src="/doc/play/playground.js"></script>
228 <script> 226 <script>
229 $(document).ready(function() { 227 $(document).ready(function() {
230 'use strict'; 228 'use strict';
231 // Set up playground when each element is toggled. 229 // Set up playground when each element is toggled.
232 $('div.play').each(function (i, el) { 230 $('div.play').each(function (i, el) {
233 var built = false; 231 var built = false;
234 $(el).closest('.toggle').click(function() { 232 $(el).closest('.toggle').click(function() {
235 // Only set up playground once. 233 // Only set up playground once.
236 if (built) { 234 if (built) {
237 return; 235 return;
(...skipping 19 matching lines...) Expand all
257 code.closest('.input').height(h); 255 code.closest('.input').height(h);
258 }; 256 };
259 code.on('keydown', resize); 257 code.on('keydown', resize);
260 code.on('keyup', resize); 258 code.on('keyup', resize);
261 code.keyup(); // resize now. 259 code.keyup(); // resize now.
262 }); 260 });
263 }); 261 });
264 }); 262 });
265 </script> 263 </script>
266 {{end}} 264 {{end}}
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b