Fix indent

This commit is contained in:
Naoki Takezoe
2018-05-28 12:26:11 +09:00
parent 172701105a
commit df9c34bcec

View File

@@ -121,79 +121,79 @@
<span class="muted"> authored @gitbucket.core.helper.html.datetimeago(latestCommit.authorTime)</span> <span class="muted"> authored @gitbucket.core.helper.html.datetimeago(latestCommit.authorTime)</span>
</div> </div>
@if(latestCommit.isDifferentFromAuthor) { @if(latestCommit.isDifferentFromAuthor) {
<div class="committer"> <div class="committer">
<span class="octicon octicon-arrow-right"></span> <span class="octicon octicon-arrow-right"></span>
<span>@helpers.user(latestCommit.committerName, latestCommit.committerEmailAddress, "username strong")</span> <span>@helpers.user(latestCommit.committerName, latestCommit.committerEmailAddress, "username strong")</span>
<span class="muted"> committed @gitbucket.core.helper.html.datetimeago(latestCommit.commitTime)</span> <span class="muted"> committed @gitbucket.core.helper.html.datetimeago(latestCommit.commitTime)</span>
</div> </div>
} }
</div> </div>
</div> </div>
</th> </th>
</tr> </tr>
@if(pathList.size > 0){ @if(pathList.size > 0){
<tr> <tr>
<td width="16" class="file-icon"></td> <td width="16" class="file-icon"></td>
<td><a href="@helpers.url(repository)@if(pathList.size > 1){/tree/@helpers.encodeRefName(branch)/@helpers.encodeRefName(pathList.init.mkString("/"))}">..</a></td> <td><a href="@helpers.url(repository)@if(pathList.size > 1){/tree/@helpers.encodeRefName(branch)/@helpers.encodeRefName(pathList.init.mkString("/"))}">..</a></td>
<td></td> <td></td>
<td></td> <td></td>
</tr> </tr>
} }
@files.map { file => @files.map { file =>
<tr> <tr>
<td width="16" class="file-icon"> <td width="16" class="file-icon">
@if(file.isDirectory){ @if(file.isDirectory){
@if(file.linkUrl.isDefined){ @if(file.linkUrl.isDefined){
<i class="octicon octicon-file-symlink-directory"></i> <i class="octicon octicon-file-symlink-directory"></i>
} else { } else {
<i class="octicon octicon-file-directory"></i> <i class="octicon octicon-file-directory"></i>
}
} else {
<i class="octicon octicon-file-text"></i>
}
</td>
<td class="ellipsis-cell" style="width: 20%; min-width: 160px;">
@if(file.isDirectory){
@{file.linkUrl match {
case Some(linkUrl) if linkUrl.startsWith("http://") || linkUrl.startsWith("https://") => {
<a href={linkUrl}>
<span class="simplified-path">{file.name.split("/").toList.init match {
case Nil => ""
case list => list.mkString("", "/", "/")
}}</span>
{file.name.split("/").toList.last}
</a>
} }
case Some(_) => { } else {
<span> <i class="octicon octicon-file-text"></i>
<span class="simplified-path">{file.name.split("/").toList.init match { }
case Nil => "" </td>
case list => list.mkString("", "/", "/") <td class="ellipsis-cell" style="width: 20%; min-width: 160px;">
}}</span> @if(file.isDirectory){
{file.name.split("/").toList.last} @{file.linkUrl match {
</span> case Some(linkUrl) if linkUrl.startsWith("http://") || linkUrl.startsWith("https://") => {
} <a href={linkUrl}>
case None => { <span class="simplified-path">{file.name.split("/").toList.init match {
<a href={helpers.url(repository) + "/tree" + helpers.encodeRefName((branch :: pathList).mkString("/", "/", "/") + file.name)}> case Nil => ""
<span class="simplified-path">{file.name.split("/").toList.init match { case list => list.mkString("", "/", "/")
case Nil => "" }}</span>
case list => list.mkString("", "/", "/") {file.name.split("/").toList.last}
}}</span> </a>
{file.name.split("/").toList.last} }
</a> case Some(_) => {
} <span>
}} <span class="simplified-path">{file.name.split("/").toList.init match {
} else { case Nil => ""
<a href="@helpers.url(repository)/blob@{helpers.encodeRefName((branch :: pathList).mkString("/", "/", "/") + file.name)}">@file.name</a> case list => list.mkString("", "/", "/")
} }}</span>
</td> {file.name.split("/").toList.last}
<td class="ellipsis-cell" style="width: 70%;"> </span>
<span> }
<a href="@helpers.url(repository)/commit/@file.commitId" class="commit-message" title="@file.message">@helpers.link(file.message, repository)</a> case None => {
</span> <a href={helpers.url(repository) + "/tree" + helpers.encodeRefName((branch :: pathList).mkString("/", "/", "/") + file.name)}>
</td> <span class="simplified-path">{file.name.split("/").toList.init match {
<td style="width: 10%; min-width: 125px; text-align: right;">@gitbucket.core.helper.html.datetimeago(file.time, false)</td> case Nil => ""
</tr> case list => list.mkString("", "/", "/")
}}</span>
{file.name.split("/").toList.last}
</a>
}
}}
} else {
<a href="@helpers.url(repository)/blob@{helpers.encodeRefName((branch :: pathList).mkString("/", "/", "/") + file.name)}">@file.name</a>
}
</td>
<td class="ellipsis-cell" style="width: 70%;">
<span>
<a href="@helpers.url(repository)/commit/@file.commitId" class="commit-message" title="@file.message">@helpers.link(file.message, repository)</a>
</span>
</td>
<td style="width: 10%; min-width: 125px; text-align: right;">@gitbucket.core.helper.html.datetimeago(file.time, false)</td>
</tr>
} }
</table> </table>
@readme.map { case(filePath, content) => @readme.map { case(filePath, content) =>