11<?js
22var data = obj;
33var self = this;
4+ function mkSignature (data) {
5+ var attribs = data.attribs ;
6+ attribs = attribs.replace ('protected', 'internal');
7+
8+ return (attribs + (data.kind === 'class' ? 'new ' : '') +
9+ data.name +
10+ (data.kind !== 'event' ? data.signature : ''));
11+ }
412?>
513<dt>
6- <h4 class= " name" id= " <?js= id ?>" ><?js = data.attribs + (kind === 'class' ? 'new ' : '') + name + (kind !== 'event' ? data.signature : '') ?></h4>
14+ <h4 class= " name <?js= data.deprecated ? 'toc-deprecated' : ''?>"
15+ id= " <?js= id ?>" ><?js = mkSignature(data) ?></h4>
716
817 <?js if (data.summary ) { ?>
918 <p class= " summary" ><?js = summary ?></p>
1019 <?js } ?>
1120</dt>
1221<dd>
13-
22+ <?js if (data.deprecated ) { ?>
23+ <dt class= " important deprecated-notice" >
24+ This method is <em>deprecated</em> and should not be used. It may be removed in the future.
25+ </dt>
26+ <?js } ?>
27+
1428 <?js if (data.description ) { ?>
1529 <div class= " description" >
1630 <?js = data.description ?>
@@ -35,6 +49,15 @@ var self = this;
3549 <h5>Parameters:</h5>
3650 <?js = this.partial ('params.tmpl ', params) ?>
3751 <?js } ?>
52+
53+ <?js if (data.returns && returns.length ) { ?>
54+ <h5>Returns:</h5>
55+ <div class= " returns" >
56+ <?js returns.forEach (function(r) { ?>
57+ <?js = self.partial ('returns.tmpl ', r) ?>
58+ <?js }); ?>
59+ </div>
60+ <?js } ?>
3861
3962 <?js = this.partial ('details.tmpl ', data) ?>
4063
@@ -69,19 +92,7 @@ var self = this;
6992 exceptions.forEach (function(r) { ?>
7093 <?js = self.partial ('exceptions.tmpl ', r) ?>
7194 <?js });
72- } } ?>
73-
74- <?js if (data.returns && returns.length ) { ?>
75- <h5>Returns:</h5>
76- <?js if (returns.length > 1) { ?><ul><?js
77- returns.forEach (function(r) { ?>
78- <li><?js = self.partial ('returns.tmpl ', r) ?></li>
79- <?js });
80- ?></ul><?js } else {
81- returns.forEach (function(r) { ?>
82- <?js = self.partial ('returns.tmpl ', r) ?>
83- <?js });
84- } } ?>
95+ } } ?>
8596
8697 <?js if (data.examples && examples.length ) { ?>
8798 <h5>Example<?js = examples.length > 1? 's':'' ?></h5>
0 commit comments