2019-04-20 10:47:00 +08:00
|
|
|
<div class="tab-size-8 non-diff-file-content">
|
|
|
|
|
|
|
|
<h4 class="ui top attached header" id="repo-read-file">
|
|
|
|
<div class="ui stackable grid">
|
2019-07-23 10:12:09 +08:00
|
|
|
<div class="eight wide column">
|
2019-04-20 10:47:00 +08:00
|
|
|
<i class="file text outline icon ui left"></i>
|
|
|
|
<strong>{{.FileName}}</strong> <span class="text grey normal">{{FileSize .FileSize}}{{if .IsLFSFile}} ({{.i18n.Tr "repo.stored_lfs"}}){{end}}</span>
|
|
|
|
</div>
|
2019-07-23 10:12:09 +08:00
|
|
|
<div class="eight wide right aligned column">
|
2019-04-20 10:47:00 +08:00
|
|
|
<div class="ui right file-actions">
|
|
|
|
<div class="ui buttons">
|
2019-08-28 10:23:18 +08:00
|
|
|
<a class="ui button" href="{{EscapePound $.RawFileLink}}">{{.i18n.Tr "repo.file_raw"}}</a>
|
2019-04-20 10:47:00 +08:00
|
|
|
{{if not .IsViewCommit}}
|
|
|
|
<a class="ui button" href="{{.RepoLink}}/src/commit/{{.CommitID}}/{{EscapePound .TreePath}}">{{.i18n.Tr "repo.file_permalink"}}</a>
|
|
|
|
{{end}}
|
|
|
|
<a class="ui button" href="{{.RepoLink}}/src/{{EscapePound .BranchNameSubURL}}/{{EscapePound .TreePath}}">{{.i18n.Tr "repo.normal_view"}}</a>
|
|
|
|
<a class="ui button" href="{{.RepoLink}}/commits/{{EscapePound .BranchNameSubURL}}/{{EscapePound .TreePath}}">{{.i18n.Tr "repo.file_history"}}</a>
|
|
|
|
</div>
|
|
|
|
{{if .Repository.CanEnableEditor}}
|
|
|
|
{{if .CanEditFile}}
|
2020-02-12 01:02:41 +08:00
|
|
|
<a href="{{.RepoLink}}/_edit/{{EscapePound .BranchName}}/{{EscapePound .TreePath}}"><span class="btn-octicon poping up" data-content="{{.EditFileTooltip}}" data-position="bottom center" data-variation="tiny inverted">{{svg "octicon-pencil" 16}}</span></a>
|
2019-04-20 10:47:00 +08:00
|
|
|
{{else}}
|
2020-02-12 01:02:41 +08:00
|
|
|
<span class="btn-octicon poping up disabled" data-content="{{.EditFileTooltip}}" data-position="bottom center" data-variation="tiny inverted">{{svg "octicon-pencil" 16}}</span>
|
2019-04-20 10:47:00 +08:00
|
|
|
{{end}}
|
|
|
|
{{if .CanDeleteFile}}
|
2020-02-12 01:02:41 +08:00
|
|
|
<a href="{{.RepoLink}}/_delete/{{EscapePound .BranchName}}/{{EscapePound .TreePath}}"><span class="btn-octicon btn-octicon-danger poping up" data-content="{{.DeleteFileTooltip}}" data-position="bottom center" data-variation="tiny inverted">{{svg "octicon-trashcan" 16}}</span></a>
|
2019-04-20 10:47:00 +08:00
|
|
|
{{else}}
|
2020-02-12 01:02:41 +08:00
|
|
|
<span class="btn-octicon poping up disabled" data-content="{{.DeleteFileTooltip}}" data-position="bottom center" data-variation="tiny inverted">{{svg "octicon-trashcan" 16}}</span>
|
2019-04-20 10:47:00 +08:00
|
|
|
{{end}}
|
|
|
|
{{end}}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</h4>
|
|
|
|
|
|
|
|
<div class="ui attached table unstackable segment">
|
2020-05-02 01:58:45 +08:00
|
|
|
<div class="file-view code-view">
|
2019-04-20 10:47:00 +08:00
|
|
|
<table>
|
|
|
|
<tbody>
|
|
|
|
<tr>
|
|
|
|
<td class="lines-commit">{{.BlameCommitInfo}}</td>
|
|
|
|
<td class="lines-num">{{.BlameLineNums}}</td>
|
|
|
|
<td class="lines-code"><pre><code class="{{.HighlightClass}}"><ol class="linenums">{{.BlameContent}}</ol></code></pre></td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
2019-07-23 10:12:09 +08:00
|
|
|
</div>
|