summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorslene <vslene@gmail.com>2014-03-24 23:56:32 +0800
committerslene <vslene@gmail.com>2014-03-24 23:56:32 +0800
commitff362484191d08db2e2bda238934b780139b9048 (patch)
tree691a564e36ed971c7eb1f28b8c69fb74a7f9ffe4 /templates
parent92a6058e29eb5f9cd655c3b1f8f43fd6d46fe5a4 (diff)
downloadgitea-ff362484191d08db2e2bda238934b780139b9048.tar.gz
gitea-ff362484191d08db2e2bda238934b780139b9048.zip
raw download
Diffstat (limited to 'templates')
-rw-r--r--templates/repo/single_file.tmpl12
1 files changed, 6 insertions, 6 deletions
diff --git a/templates/repo/single_file.tmpl b/templates/repo/single_file.tmpl
index 7f07033703..9755812285 100644
--- a/templates/repo/single_file.tmpl
+++ b/templates/repo/single_file.tmpl
@@ -5,17 +5,17 @@
{{else}}
<div class="btn-group pull-right">
<a class="btn btn-default hidden" href="#">Edit</a>
- <a class="btn btn-default" href="#">Raw</a>
+ <a class="btn btn-default" href="{{.FileLink}}">Raw</a>
<a class="btn btn-default hidden" href="#">Blame</a>
<a class="btn btn-default hidden" href="#">History</a>
<a class="btn btn-danger hidden" href="#">Delete</a>
</div>
<i class="icon fa fa-file-text-o"></i>
- {{end}}{{.FileName}}
+ {{end}}{{.FileName}} {{FileSize .FileSize}}
</div>
- {{if .FileIsLarge}}
- <div class="panel-footer">
- Large file size 1000kb
+ {{if not .FileIsText}}
+ <div class="panel-footer text-center">
+ <a href="{{.FileLink}}" class="btn btn-default">View Raw</a>
</div>
{{else}}
{{if .ReadmeExist}}
@@ -28,7 +28,7 @@
<tbody>
<tr>
<td class="lines-num"></td>
- <td class="lines-code markdown"><pre class="prettyprint linenums lang-{{.FileExt}}">{{.FileContent}}</pre></td>
+ <td class="lines-code markdown"><pre class="prettyprint linenums{{if .FileExt}} lang-{{.FileExt}}{{end}}">{{.FileContent}}</pre></td>
</tr>
</tbody>
</table>