Skip to content

Commit abfaee5

Browse files
committed
Show crate version / link for stats
Added a version next to stats, so you can tell what it is giving stats for. Also added a link back to the crate overview page, if you want to see all the stats.
1 parent 7634a69 commit abfaee5

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

app/templates/crate/version.hbs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,15 @@
246246
{{#unless this.currentVersion.yanked}}
247247
<div id='crate-downloads'>
248248
<div class='stats'>
249-
<h3>Stats Overview</h3>
249+
{{#if this.downloadsContext.num}}
250+
<h3>
251+
Stats Overview for {{this.downloadsContext.num}}
252+
<LinkTo @route="crate" @model={{this.crate}}>(see all)</LinkTo>
253+
</h3>
254+
255+
{{else}}
256+
<h3>Stats Overview {{this.downloadsContext.num}}</h3>
257+
{{/if}}
250258
<div class='stat'>
251259
<span class='num'>
252260
{{svg-jar "download"}}

0 commit comments

Comments
 (0)