mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-01 11:06:06 +01:00
Remove unnecessary parts and styles.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
@(id: String, value: String)(html: Html)
|
||||
<div class="input-append">
|
||||
<div class="input-append" style="margin-bottom: 0px;">
|
||||
@html
|
||||
<span id="@id" class="add-on btn" data-clipboard-text="@value" data-placement="bottom" title="copy to clipboard"><i class="icon-check"></i></span>
|
||||
</div>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
@(active: String, repository: service.RepositoryService.RepositoryInfo)(implicit context: app.Context)
|
||||
@import context._
|
||||
@import view.helpers._
|
||||
<ul class="nav nav-tabs pull-left" style="width: 100%;">
|
||||
<ul class="nav nav-tabs pull-left fill-width">
|
||||
<li@if(active == "issues"){ class="active"}><a href="@url(repository)/issues">Browse Issues</a></li>
|
||||
<li@if(active == "milestones"){ class="active"}><a href="@url(repository)/issues/milestones">Milestones</a></li>
|
||||
@if(loginAccount.isDefined){
|
||||
|
||||
@@ -105,24 +105,15 @@ ul.sidemenu span.badge {
|
||||
<strong>HTTP</strong> <span class="mute">clone URL</span>
|
||||
</div>
|
||||
@helper.html.copy("repository-url-copy", repository.httpUrl){
|
||||
@*
|
||||
@if(settings.ssh && loginAccount.isDefined){
|
||||
<div class="btn-group add-on" data-toggle="buttons-radio" style="padding: 0px; border-width: 0px;">
|
||||
<button type="button" class="btn active" id="repository-url-http">HTTP</button><button type="button" class="btn" id="repository-url-ssh">SSH</button>
|
||||
</div>
|
||||
} else {
|
||||
<span class="add-on">HTTP</span>
|
||||
}
|
||||
*@
|
||||
<input type="text" value="@repository.httpUrl" id="repository-url" readonly>
|
||||
}
|
||||
@if(settings.ssh && loginAccount.isDefined){
|
||||
<div class="small">
|
||||
You can clone <a href="#">HTTP</a> or <a href="#">SSH</a>.
|
||||
<span class="mute">You can clone <a href="javascript:void(0);" id="repository-url-http">HTTP</a> or <a href="javascript:void(0);" id="repository-url-ssh">SSH</a>.</span>
|
||||
</div>
|
||||
}
|
||||
@id.map { id =>
|
||||
<div>
|
||||
<div style="margin-top: 10px;">
|
||||
<a href="@{url(repository)}/archive/@{encodeRefName(id)}.zip" class="btn btn-small" style="width: 147px;"><i class="icon-download-alt"></i>Download ZIP</a>
|
||||
</div>
|
||||
}
|
||||
@@ -146,7 +137,7 @@ ul.sidemenu span.badge {
|
||||
<p class="muted">@description</p>
|
||||
}
|
||||
<div style="border: 1px solid silver; padding: 4px; margin-bottom: 10px;">
|
||||
<table style="width: 100%;">
|
||||
<table class="fill-width">
|
||||
<tr>
|
||||
<td style="width: 33%; text-align: center;">
|
||||
<a href="@url(repository)/commits/@encodeRefName(id.getOrElse(""))" class="header-link">
|
||||
@@ -170,13 +161,17 @@ ul.sidemenu span.badge {
|
||||
@body
|
||||
</div>
|
||||
</div>
|
||||
@*
|
||||
<script type="text/javascript">
|
||||
@if(settings.ssh && loginAccount.isDefined){
|
||||
<script>
|
||||
$(function(){
|
||||
$('table.global-nav th.box-header').click(function(){
|
||||
location.href = $(this).find('a').attr('href');
|
||||
return false;
|
||||
$('#repository-url-http').click(function(){
|
||||
$('#repository-url').val('@repository.httpUrl');
|
||||
$('#repository-url-copy').attr('data-clipboard-text', $('#repository-url').val());
|
||||
});
|
||||
$('#repository-url-ssh').click(function(){
|
||||
$('#repository-url').val('@repository.sshUrl(settings.sshPort.getOrElse(service.SystemSettingsService.DefaultSshPort), loginAccount.get.userName)');
|
||||
$('#repository-url-copy').attr('data-clipboard-text', $('#repository-url').val());
|
||||
});
|
||||
});
|
||||
</script>
|
||||
*@
|
||||
}
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository){
|
||||
@tab(branch, repository, "files")
|
||||
<div class="head">
|
||||
<a href="@url(repository)/tree/@encodeRefName(branch)">@repository.name</a> /
|
||||
@pathList.zipWithIndex.map { case (section, i) =>
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository){
|
||||
@tab(repository.repository.defaultBranch, repository, "branches", true)
|
||||
<h1>Branches</h1>
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
@import util.Implicits._
|
||||
@html.main(commit.shortMessage, Some(repository)){
|
||||
@html.menu("code", repository){
|
||||
@tab(commitId, repository, "commits")
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
<th>
|
||||
|
||||
@@ -8,7 +8,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository){
|
||||
@tab(branch, repository, if(pathList.isEmpty) "commits" else "files")
|
||||
<div class="head">
|
||||
@if(pathList.isEmpty){
|
||||
<a href="@url(repository)/tree/@encodeRefName(branch)">@repository.name</a> / Commit History
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(s"Deleting ${path} at ${fileName} - ${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository){
|
||||
@tab(branch, repository, "files")
|
||||
<form method="POST" action="@url(repository)/remove" validate="true">
|
||||
<div class="head">
|
||||
<a href="@url(repository)/tree/@encodeRefName(branch)">@repository.name</a> /
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(if(fileName.isEmpty) "New File" else s"Editing ${path} at ${fileName} - ${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository){
|
||||
@tab(branch, repository, "files")
|
||||
<form method="POST" action="@url(repository)/@if(fileName.isEmpty){create}else{update}" validate="true">
|
||||
<span class="error" id="error-newFileName"></span>
|
||||
<div class="head">
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository, Some(branch), pathList.isEmpty){
|
||||
@tab(branch, repository, "files")
|
||||
<div class="head">
|
||||
<a href="@url(repository)/tree/@encodeRefName(branch)">@repository.name</a> /
|
||||
@pathList.zipWithIndex.map { case (section, i) =>
|
||||
|
||||
@@ -1,57 +0,0 @@
|
||||
@(id: String, repository: service.RepositoryService.RepositoryInfo, active: String,
|
||||
hideBranchPulldown: Boolean = false)(implicit context: app.Context)
|
||||
@import context._
|
||||
@import view.helpers._
|
||||
@*
|
||||
<ul class="nav nav-tabs">
|
||||
@if(!hideBranchPulldown){
|
||||
<li>
|
||||
@helper.html.dropdown(
|
||||
value = if(id.length == 40) id.substring(0, 10) else id,
|
||||
prefix = if(id.length == 40) "tree" else if(repository.branchList.contains(id)) "branch" else "tree",
|
||||
mini = false,
|
||||
style = "margin-right: 20px;"
|
||||
){
|
||||
@repository.branchList.map { branch =>
|
||||
<li><a href="@url(repository)/@if(active=="commits"){commits} else {tree}/@encodeRefName(branch)">@helper.html.checkicon(id == branch) @branch</a></li>
|
||||
}
|
||||
}
|
||||
</li>
|
||||
}
|
||||
<li@if(active=="files" ){ class="active"}><a href="@url(repository)/tree/@encodeRefName(id)">Files</a></li>
|
||||
<li@if(active=="commits" ){ class="active"}><a href="@url(repository)/commits/@encodeRefName(id)">Commits</a></li>
|
||||
<li@if(active=="branches"){ class="active"}><a href="@url(repository)/branches">Branches@if(repository.branchList.length > 0){ <span class="badge">@repository.branchList.length</span>}</a></li>
|
||||
<li@if(active=="tags" ){ class="active"}><a href="@url(repository)/tags">Tags@if(repository.tags.length > 0){ <span class="badge">@repository.tags.length</span>}</a></li>
|
||||
<li class="pull-right">
|
||||
@helper.html.copy("repository-url-copy", repository.httpUrl){
|
||||
@if(settings.ssh && loginAccount.isDefined){
|
||||
<div class="btn-group add-on" data-toggle="buttons-radio" style="padding: 0px; border-width: 0px;">
|
||||
<button type="button" class="btn active" id="repository-url-http">HTTP</button><button type="button" class="btn" id="repository-url-ssh">SSH</button>
|
||||
</div>
|
||||
} else {
|
||||
<span class="add-on">HTTP</span>
|
||||
}
|
||||
<input type="text" value="@repository.httpUrl" id="repository-url" style="width: 150px;" readonly>
|
||||
}
|
||||
</li>
|
||||
<li class="pull-right" style="margin-right: 8px;">
|
||||
<div class="pull-right">
|
||||
<a href="@{url(repository)}/archive/@{encodeRefName(id)}.zip" class="btn"><i class="icon-download-alt"></i>ZIP</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
*@
|
||||
@if(settings.ssh && loginAccount.isDefined){
|
||||
<script>
|
||||
$(function(){
|
||||
$('#repository-url-http').click(function(){
|
||||
$('#repository-url').val('@repository.httpUrl');
|
||||
$('#repository-url-copy').attr('data-clipboard-text', $('#repository-url').val());
|
||||
});
|
||||
$('#repository-url-ssh').click(function(){
|
||||
$('#repository-url').val('@repository.sshUrl(settings.sshPort.getOrElse(service.SystemSettingsService.DefaultSshPort), loginAccount.get.userName)');
|
||||
$('#repository-url-copy').attr('data-clipboard-text', $('#repository-url').val());
|
||||
});
|
||||
});
|
||||
</script>
|
||||
}
|
||||
@@ -3,7 +3,6 @@
|
||||
@import view.helpers._
|
||||
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
|
||||
@html.menu("code", repository){
|
||||
@tab(repository.repository.defaultBranch, repository, "tags", true)
|
||||
<h1>Tags</h1>
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
@import context._
|
||||
@import service.WikiService._
|
||||
@import view.helpers._
|
||||
<ul class="nav nav-tabs pull-left" style="width: 100%;">
|
||||
<ul class="nav nav-tabs pull-left fill-width">
|
||||
<li@if(active == "home" ){ class="active"}><a href="@url(repository)/wiki">Home</a></li>
|
||||
<li@if(active == "pages" ){ class="active"}><a href="@url(repository)/wiki/_pages">Pages</a></li>
|
||||
<li@if(active == "history"){ class="active"}><a href="@url(repository)/wiki/_history">Wiki History</a></li>
|
||||
|
||||
@@ -56,38 +56,6 @@ span.header-version {
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
/* ======================================================================== */
|
||||
/* Repository Header */
|
||||
/* ======================================================================== */
|
||||
table.global-nav {
|
||||
width: 920px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
table.global-nav th {
|
||||
padding-top: 5px;
|
||||
padding-bottom: 8px;
|
||||
width: 16%;
|
||||
border-bottom: 2px solid silver;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
table.global-nav th.active {
|
||||
border-bottom: 2px solid #D26911;
|
||||
}
|
||||
|
||||
table.global-nav th a:link, table.global-nav th a:hover, table.global-nav th a:visited {
|
||||
color: #333;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
div.input-prepend span.count {
|
||||
background-color: white;
|
||||
-webkit-border-radius: 0 4px 4px 0;
|
||||
-moz-border-radius: 0 4px 4px 0;
|
||||
border-radius: 0 4px 4px 0;
|
||||
}
|
||||
|
||||
/* ======================================================================== */
|
||||
/* General Styles */
|
||||
/* ======================================================================== */
|
||||
@@ -303,6 +271,10 @@ span.highlight {
|
||||
background-color: #ffff88;
|
||||
}
|
||||
|
||||
.fill-width {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/****************************************************************************/
|
||||
/* Create Repository */
|
||||
/****************************************************************************/
|
||||
|
||||
Reference in New Issue
Block a user