Global navigation moves to side menu.

This commit is contained in:
takezoe
2014-05-05 22:05:41 +09:00
parent cf047a8cee
commit 6a7fc55572
35 changed files with 1704 additions and 1290 deletions

View File

@@ -2,6 +2,7 @@
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:osb="http://www.openswatchbook.org/uri/2009/osb"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
@@ -16,7 +17,16 @@
inkscape:version="0.48.4 r9939"
sodipodi:docname="icons.svg">
<defs
id="defs4" />
id="defs4">
<linearGradient
id="linearGradient4044"
osb:paint="solid">
<stop
style="stop-color:#000000;stop-opacity:1;"
offset="0"
id="stop4046" />
</linearGradient>
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
@@ -24,15 +34,15 @@
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="1.4"
inkscape:cx="450.21999"
inkscape:cy="97.51519"
inkscape:zoom="0.9899495"
inkscape:cx="827.57339"
inkscape:cy="496.04311"
inkscape:document-units="px"
inkscape:current-layer="layer1-9"
showgrid="false"
inkscape:window-width="1366"
inkscape:window-height="706"
inkscape:window-x="1912"
inkscape:window-height="715"
inkscape:window-x="-8"
inkscape:window-y="-8"
inkscape:window-maximized="1"
inkscape:snap-global="false"
@@ -978,6 +988,268 @@
id="path4310"
inkscape:connector-curvature="0"
sodipodi:nodetypes="ccscc" />
<path
id="path2991-7-1-4"
transform="translate(668.66057,1115.0272)"
d="m 359.99999,290.93362 c 0,57.59541 -46.6903,104.28572 -104.28571,104.28572 -57.59541,0 -104.28571,-46.69031 -104.28571,-104.28572 0,-57.5954 46.6903,-104.28571 104.28571,-104.28571 57.59541,0 104.28571,46.69031 104.28571,104.28571 z"
sodipodi:ry="104.28571"
sodipodi:rx="104.28571"
sodipodi:cy="290.93362"
sodipodi:cx="255.71428"
style="fill:#b3b3b3;fill-rule:evenodd;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
sodipodi:type="arc" />
<path
id="path2993-4-5-8"
d="m 359.99999,290.93362 c 0,57.59541 -46.6903,104.28572 -104.28571,104.28572 -57.59541,0 -104.28571,-46.69031 -104.28571,-104.28572 0,-57.5954 46.6903,-104.28571 104.28571,-104.28571 57.59541,0 104.28571,46.69031 104.28571,104.28571 z"
sodipodi:ry="104.28571"
sodipodi:rx="104.28571"
sodipodi:cy="290.93362"
sodipodi:cx="255.71428"
style="fill:#ffffff;fill-rule:evenodd;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
sodipodi:type="arc"
transform="matrix(0.83611704,0,0,0.83611704,711.41194,1163.4493)" />
<rect
id="rect2995-0-2-8"
y="1378.4849"
x="916.58545"
height="99.396141"
width="20.706863"
style="fill:#b3b3b3;stroke:none;stroke-width:0.93666755999999995" />
<path
style="fill:#ffffff;stroke:#ffffff;stroke-width:2.92446065;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none"
d="m 884.0251,1366.2678 -64.6851,-36.2114 10.70013,55.9569 53.98497,-19.7455 z"
id="rect4046-3-4"
inkscape:connector-curvature="0" />
<path
style="fill:#b3b3b3;stroke:#b3b3b3;stroke-width:1.98877633;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none"
d="m 873.36878,1359.3959 -43.65605,-24.4345 6.99871,38.1562 36.65734,-13.7217 z"
id="rect4046-5"
inkscape:connector-curvature="0" />
<path
style="fill:#ffffff;fill-opacity:1;stroke:#b3b3b3;stroke-width:13.63542366;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none"
d="m 1162.2186,1316.0972 c -0.2525,22.2049 -0.505,44.4098 -0.7575,66.6147 3.3299,0.032 6.6599,0.063 9.9898,0.095 -2.3515,2.3672 -4.703,4.7345 -7.0544,7.1018 31.3741,31.374 62.7482,62.7482 94.1223,94.1223 23.3412,-23.3412 46.6824,-46.6824 70.0236,-70.0236 -31.3741,-31.3899 -62.7483,-62.7798 -94.1224,-94.1697 -2.6197,2.6356 -5.2395,5.2711 -7.8593,7.9067 0.032,-3.6298 0.063,-7.2596 0.095,-10.8894 -21.4789,-0.2525 -42.9579,-0.505 -64.4368,-0.7575 z"
id="rect3075-11"
inkscape:connector-curvature="0" />
<rect
id="rect2995-0-2-8-6"
y="899.99463"
x="-1417.3273"
height="99.396141"
width="20.706863"
style="fill:#b3b3b3;stroke:none;stroke-width:0.93666755999999995"
transform="matrix(0,-1,1,0,0,0)" />
<path
style="fill:#ffffff;fill-opacity:1;stroke:#ffffff;stroke-width:10.37699986;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
d="m 1172.5522,1326.6744 c -0.1922,16.8985 -0.3844,33.7973 -0.5765,50.6959 2.5342,0.024 5.0684,0.047 7.6026,0.072 -1.7896,1.8014 -3.5792,3.6031 -5.3686,5.4047 23.8766,23.8766 47.7533,47.7533 71.63,71.6301 17.7636,-17.7634 35.5269,-35.5268 53.2902,-53.2902 -23.8766,-23.8888 -47.7534,-47.7775 -71.6302,-71.6662 -1.9936,2.0058 -3.9873,4.0114 -5.9811,6.0172 0.024,-2.7624 0.047,-5.5247 0.072,-8.2872 -16.3463,-0.1921 -32.6925,-0.3843 -49.0386,-0.5764 z"
id="rect3075-11-7"
inkscape:connector-curvature="0" />
<path
sodipodi:type="arc"
style="fill:#ffffff;stroke:#b3b3b3;stroke-width:6.57334423;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-start:none"
id="path3100-2"
sodipodi:cx="700"
sodipodi:cy="812.36218"
sodipodi:rx="10"
sodipodi:ry="10"
d="m 710,812.36218 c 0,5.52285 -4.47715,10 -10,10 -5.52285,0 -10,-4.47715 -10,-10 0,-5.52284 4.47715,-10 10,-10 5.52285,0 10,4.47716 10,10 z"
transform="matrix(1.2362333,-1.2362333,1.2362333,1.2362333,-667.98357,1217.7251)" />
<rect
style="fill:#ffffff;fill-opacity:1;stroke:#b3b3b3;stroke-width:10.80681515;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect4114"
width="45.086407"
height="62.401226"
x="-133.16023"
y="1850.2394"
transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)" />
<path
id="path2991-7-6"
transform="translate(1090.5728,-207.2632)"
d="m 359.99999,290.93362 c 0,57.59541 -46.6903,104.28572 -104.28571,104.28572 -57.59541,0 -104.28571,-46.69031 -104.28571,-104.28572 0,-57.5954 46.6903,-104.28571 104.28571,-104.28571 57.59541,0 104.28571,46.69031 104.28571,104.28571 z"
sodipodi:ry="104.28571"
sodipodi:rx="104.28571"
sodipodi:cy="290.93362"
sodipodi:cx="255.71428"
style="fill:#a0a0a0;fill-rule:evenodd;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;fill-opacity:1"
sodipodi:type="arc" />
<path
id="path2993-4-8"
d="m 359.99999,290.93362 c 0,57.59541 -46.6903,104.28572 -104.28571,104.28572 -57.59541,0 -104.28571,-46.69031 -104.28571,-104.28572 0,-57.5954 46.6903,-104.28571 104.28571,-104.28571 57.59541,0 104.28571,46.69031 104.28571,104.28571 z"
sodipodi:ry="104.28571"
sodipodi:rx="104.28571"
sodipodi:cy="290.93362"
sodipodi:cx="255.71428"
style="fill:#ffffff;fill-rule:evenodd;stroke:#808080;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
sodipodi:type="arc"
transform="matrix(0.83611704,0,0,0.83611704,1133.3242,-158.84107)" />
<rect
id="rect2995-0-8"
y="10.829478"
x="1332.5247"
height="99.221687"
width="29.189819"
style="fill:#a0a0a0;stroke:#ffffff;stroke-width:1.11112404000000000;fill-opacity:1" />
<rect
id="rect2997-9-2"
y="129.62337"
x="1332.7828"
height="26.258072"
width="29.724136"
style="fill:#a0a0a0;stroke:#ffffff;stroke-width:0.57680577000000000;fill-opacity:1" />
<g
id="g4284-1"
transform="translate(670.07237,-816.24186)"
style="stroke:#a0a0a0;stroke-opacity:1">
<path
sodipodi:nodetypes="czcczcc"
inkscape:connector-curvature="0"
id="rect4201-26"
d="m 568.37427,1080.8464 c 0,0 55.60005,-9.5933 75.06243,-8.6574 19.46238,0.9359 40.43273,8.6574 40.43273,8.6574 l 0,141.4674 c 0,0 -20.97035,-7.7215 -40.43273,-8.6574 -19.46238,-0.9359 -75.06243,8.6574 -75.06243,8.6574 z"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:14.36538028999999900;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1" />
<rect
y="1108.1473"
x="597.4068"
height="5.4857273"
width="55.265846"
id="rect4203-0"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:11.82844734000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<rect
y="1142.7776"
x="598.48895"
height="5.4857273"
width="55.26585"
id="rect4203-2-4"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:11.82844734000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<rect
y="1176.1093"
x="598.48895"
height="5.4857273"
width="55.26585"
id="rect4203-2-3-9"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:11.82844734000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<path
sodipodi:nodetypes="czc"
inkscape:connector-curvature="0"
id="path4245-4"
d="m 563.55369,1233.6274 c 0,0 59.11965,-16.1473 81.00954,-14.7566 21.8899,1.3907 46.29117,14.7566 46.29117,14.7566"
style="fill:#b3b3b3;stroke:#a0a0a0;stroke-width:19.63722609999999900;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none" />
<g
transform="matrix(-1.0032405,0,0,1,1329.8708,99.560238)"
id="g4277-6"
style="stroke:#a0a0a0;stroke-opacity:1">
<path
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:14.36538124000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1"
d="m 519.67634,980.83663 c 0,0 55.60005,-9.5933 75.06243,-8.6574 19.46238,0.9359 40.43272,8.6574 40.43272,8.6574 l 0,141.46737 c 0,0 -20.97034,-7.7215 -40.43272,-8.6574 -19.46238,-0.9359 -75.06243,8.6574 -75.06243,8.6574 z"
id="rect4201-2-0"
inkscape:connector-curvature="0"
sodipodi:nodetypes="czcczcc" />
<rect
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:11.82844734000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect4203-21-3"
width="55.26585"
height="5.4857273"
x="548.70886"
y="1008.1376" />
<rect
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:11.82844734000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect4203-2-6-6"
width="55.26585"
height="5.4857273"
x="549.79102"
y="1042.7678" />
<rect
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:11.82844734000000000;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
id="rect4203-2-3-8-2"
width="55.26585"
height="5.4857273"
x="549.79102"
y="1076.0995" />
<path
style="fill:#b3b3b3;stroke:#a0a0a0;stroke-width:19.63722609999999900;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
d="m 514.85576,1133.6176 c 0,0 59.11965,-16.1473 81.00954,-14.7566 21.8899,1.3907 46.29116,14.7566 46.29116,14.7566"
id="path4245-5-4"
inkscape:connector-curvature="0"
sodipodi:nodetypes="czc" />
</g>
</g>
<path
inkscape:connector-curvature="0"
id="path3850-1-1"
d="m 1409.5992,670.87038 0,-128.57724 c 0,0 1.8599,-15.30681 -16.7384,-15.30681 -18.5984,0 -51.1454,0 -51.1454,0"
style="fill:none;stroke:#a0a0a0;stroke-width:22.72570610000000000;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none" />
<rect
y="547.80316"
x="1294.749"
height="104.27072"
width="3.2554622"
id="rect3818-4-7"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:22.72570610000000000;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
<path
transform="matrix(1.0049237,0,0,0.61497516,944.16607,536.33294)"
d="m 372.74629,230.89374 a 21.718279,35.140915 0 1 1 -43.43655,0 21.718279,35.140915 0 1 1 43.43655,0 z"
sodipodi:ry="35.140915"
sodipodi:rx="21.718279"
sodipodi:cy="230.89374"
sodipodi:cx="351.02802"
id="path3795-4-8-4"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:12.04511166000000000;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
sodipodi:type="arc" />
<path
transform="matrix(1.0049237,0,0,0.61497516,942.63054,386.00935)"
d="m 372.74629,230.89374 a 21.718279,35.140915 0 1 1 -43.43655,0 21.718279,35.140915 0 1 1 43.43655,0 z"
sodipodi:ry="35.140915"
sodipodi:rx="21.718279"
sodipodi:cy="230.89374"
sodipodi:cx="351.02802"
id="path3795-8-0"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:12.04511166000000000;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
sodipodi:type="arc" />
<path
transform="matrix(1.0049237,0,0,0.61497516,1056.9547,536.43446)"
d="m 372.74629,230.89374 a 21.718279,35.140915 0 1 1 -43.43655,0 21.718279,35.140915 0 1 1 43.43655,0 z"
sodipodi:ry="35.140915"
sodipodi:rx="21.718279"
sodipodi:cy="230.89374"
sodipodi:cx="351.02802"
id="path3795-4-0-2-9"
style="fill:#ffffff;stroke:#a0a0a0;stroke-width:12.04511166000000000;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
sodipodi:type="arc" />
<path
inkscape:connector-curvature="0"
id="path3852-4-4"
d="m 1369.3146,490.2451 0,70.69144 -45.5889,-32.13462 z"
style="fill:#a0a0a0;stroke:#a0a0a0;stroke-width:0.83335358000000004px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;fill-opacity:1" />
<rect
style="fill:#a0a0a0;fill-opacity:1;stroke:#a0a0a0;stroke-width:10.82955647;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3953"
width="15.304287"
height="97.947441"
x="1474.2273"
y="-367.14282"
transform="matrix(0.70710678,0.70710678,-0.70710678,0.70710678,0,0)" />
<rect
style="fill:#a0a0a0;fill-opacity:1;stroke:#a0a0a0;stroke-width:10.82955647;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3953-8"
width="15.304287"
height="97.947441"
x="-281.45197"
y="-1573.058"
transform="matrix(-0.70710678,0.70710678,-0.70710678,-0.70710678,0,0)" />
<rect
style="fill:#a0a0a0;fill-opacity:1;stroke:#a0a0a0;stroke-width:10.82955647;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3953-82"
width="15.304287"
height="97.947441"
x="-412.46057"
y="-1617.4926"
transform="matrix(-0.70710678,0.70710678,-0.70710678,-0.70710678,0,0)" />
<rect
style="fill:#a0a0a0;fill-opacity:1;stroke:#a0a0a0;stroke-width:10.82955647;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3953-82-4"
width="15.304287"
height="97.947441"
x="-1617.2937"
y="306.0546"
transform="matrix(-0.70710678,-0.70710678,0.70710678,-0.70710678,0,0)" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 62 KiB

View File

@@ -1,7 +1,8 @@
@(active: String, repository: service.RepositoryService.RepositoryInfo)(implicit context: app.Context)
@(active: String, repository: service.RepositoryService.RepositoryInfo, id: Option[String] = None)(body: Html)(implicit context: app.Context)
@import context._
@import view.helpers._
<div class="container">
@if(repository.commitCount > 0){
<div class="pull-right">
<div class="input-prepend">
@@ -22,39 +23,140 @@
}
}
</div>
@repository.repository.description.map { description =>
<p>@description</p>
</div>
<hr style="margin-bottom: 20px;"/>
<style type="text/css">
ul.sidemenu {
margin-left: 0px;
}
<table class="global-nav box-header">
<tr>
<th class="box-header@if(active=="code"){ active}">
<a href="@url(repository)">Code</a>
</th>
<th class="box-header@if(active=="issues"){ active}">
<a href="@url(repository)/issues">Issues</a>
ul.sidemenu li.active {
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
border-right: 4px solid #bb4444;
border-left: 1px solid white;
}
ul.sidemenu div.gradient {
width: 5px;
height: 35px;
background: linear-gradient(to right, #eee, #fff);
margin-right: 4px;
}
ul.sidemenu div.margin {
width: 5px;
height: 35px;
margin-right: 4px;
}
ul.sidemenu li {
line-height: 35px;
height: 35px;
border-left: 1px solid #eee;
margin-left:0px;
list-style-type: none;
}
ul.sidemenu li.separator {
border-top: 1px solid #eee;
height: 1px;
}
</style>
<div class="container body">
<div style="width: 170px;" class="pull-right">
<ul class="sidemenu">
<li style="height: 12px"><div class="gradient pull-left" style="height: 12px"></div></li>
<li class="active">
<div class="margin pull-left"></div><a href="@url(repository)"><img src="@assets/common/images/menu-code.png"> Code</a>
</li>
<li>
<div class="gradient pull-left"></div><a href="@url(repository)/issues"><img src="@assets/common/images/menu-issues.png"> Issues</a>
@if(repository.issueCount > 0){
<span class="badge">@repository.issueCount</span>
<div class="pull-right"><span class="label">@repository.issueCount</span></div>
}
</th>
<th class="box-header@if(active=="pulls"){ active}">
<a href="@url(repository)/pulls">Pull Requests</a>
</li>
<li>
<div class="gradient pull-left"></div><a href="@url(repository)/pulls"><img src="@assets/common/images/menu-pulls.png"> Pull Requests</a>
@if(repository.pullCount > 0){
<span class="badge">@repository.pullCount</span>
<div class="pull-right"><span class="label">@repository.pullCount</span></div>
}
</th>
<th class="box-header@if(active=="wiki"){ active}">
<a href="@url(repository)/wiki">Wiki</a>
</th>
<th class="box-header@if(active=="network"){ active}">
<a href="@url(repository)/network/members">Network</a>
</th>
@if(loginAccount.isDefined && (loginAccount.get.isAdmin || repository.managers.contains(loginAccount.get.userName))){
<th class="box-header@if(active=="settings"){ active}">
<a href="@url(repository)/settings">Settings</a>
</th>
</li>
<li>
<div class="gradient pull-left"></div><a href="@url(repository)/wiki"><img src="@assets/common/images/menu-wiki.png"> Wiki</a>
</li>
<li class="separator"></li>
<li>
<div class="gradient pull-left"></div>Settings
</li>
</ul>
<div class="small">
<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>.
</div>
}
<div>
@*
<a href="@{url(repository)}/archive/@{encodeRefName(id)}.zip" class="btn"><i class="icon-download-alt"></i>Download ZIP</a>
*@
<a href="#" class="btn btn-small" style="width: 147px;"><i class="icon-download-alt"></i>Download ZIP</a>
</div>
</div>
<div style="margin-right: 180px;">
@repository.repository.description.map { description =>
<p class="muted">@description</p>
}
<style type="text/css">
a.header-link {
color: #888;
}
a.header-link strong {
color: black;
}
a.header-link:hover {
color: #0088cc;
text-decoration: none;
}
</style>
<div style="border: 1px solid silver; padding: 4px; margin-bottom: 10px;">
<table style="width: 100%;">
<tr>
<td style="width: 33%; text-align: center;">
<a href="@url(repository)/commits/@encodeRefName(id.getOrElse(""))" class="header-link">
<img src="@assets/common/images/header-commits.png"/> <strong>@repository.commitCount</strong> commits
</a>
</td>
<td style="width: 33%; text-align: center;">
<a href="@url(repository)/branches" class="header-link" class="header-link">
<img src="@assets/common/images/header-branches.png"/> <strong>@repository.branchList.length</strong> branches
</a>
</td>
<td style="width: 33%; text-align: center;">
<a href="@url(repository)/tags" class="header-link" class="header-link">
<img src="@assets/common/images/header-tags.png"/> <strong>@repository.tags.length</strong> releases
</a>
</td>
</tr>
</table>
</div>
@body
</div>
</div>
<script type="text/javascript">
$(function(){
$('table.global-nav th.box-header').click(function(){

View File

@@ -1,5 +1,5 @@
@(id: String, value: String, prepend: Boolean = false)(html: Html)
<div class="input-append@if(prepend){ input-prepend}">
@(id: String, value: String)(html: Html)
<div class="input-append">
@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>

View File

@@ -6,7 +6,7 @@
@import context._
@import view.helpers._
@html.main(s"New Issue - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("issues", repository)
@html.header("issues", repository){
@tab("", repository)
<form action="@url(repository)/issues/new" method="POST" validate="true">
<div class="row-fluid">
@@ -86,6 +86,7 @@
</div>
</form>
}
}
<script>
$(function(){
$('a.assign').click(function(){

View File

@@ -9,7 +9,7 @@
@import context._
@import view.helpers._
@html.main(s"${issue.title} - Issue #${issue.issueId} - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("issues", repository)
@html.header("issues", repository){
@tab("issues", repository)
<ul class="nav nav-tabs">
<li class="pull-left"><a href="@url(repository)/issues"><i class="icon-arrow-left"></i> Back to issue list</a></li>
@@ -37,3 +37,4 @@
</div>
</div>
}
}

View File

@@ -16,7 +16,7 @@
@import context._
@import view.helpers._
@html.main(s"Issues - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("issues", repository)
@html.header("issues", repository){
@tab("issues", repository)
<div class="row-fluid">
<div class="span3">
@@ -141,6 +141,7 @@
</form>
}
}
}
@if(hasWritePermission){
<script>
$(function(){

View File

@@ -2,7 +2,7 @@
@import context._
@import view.helpers._
@html.main(s"Milestones - ${repository.owner}/${repository.name}"){
@html.header("milestones", repository)
@html.header("milestones", repository){
@issues.html.tab("milestones", repository)
<form method="POST" action="@url(repository)/issues/milestones/@if(milestone.isEmpty){new}else{@milestone.get.milestoneId/edit}" validate="true">
<fieldset>
@@ -37,3 +37,4 @@
</div>
</form>
}
}

View File

@@ -5,7 +5,7 @@
@import context._
@import view.helpers._
@html.main(s"Milestones - ${repository.owner}/${repository.name}"){
@html.header("issues", repository)
@html.header("issues", repository){
@issues.html.tab("milestones", repository)
<div class="row-fluid">
<div class="span3">
@@ -95,6 +95,7 @@
</div>
</div>
}
}
<script>
$(function(){
$('a.delete').click(function(){

View File

@@ -72,9 +72,7 @@
</div>
</form>
</div>
<div class="container body">
@body
</div>
<script>
$(function(){
$('#search').submit(function(){

View File

@@ -12,7 +12,7 @@
@import context._
@import view.helpers._
@html.main(s"Pull Requests - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("pulls", repository)
@html.header("pulls", repository){
<div class="pullreq-info">
<div id="compare-info">
<a href="#" id="edit-compare-condition" class="btn btn-mini pull-right">Edit</a>
@@ -85,6 +85,7 @@
@helper.html.diff(diffs, repository, Some(commitId), Some(sourceId), true)
}
}
}
<script>
$(function(){
$('#edit-compare-condition').click(function(){

View File

@@ -11,7 +11,7 @@
@import context._
@import view.helpers._
@html.main(s"Pull Requests - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("pulls", repository)
@html.header("pulls", repository){
<div class="row-fluid">
<div class="span3">
<ul class="nav nav-pills nav-stacked">
@@ -47,4 +47,5 @@
@listparts(issues, page, openCount, closedCount, condition, Some(repository), hasWritePermission)
</div>
}
}

View File

@@ -12,7 +12,7 @@
@import context._
@import view.helpers._
@html.main(s"${issue.title} - Pull Request #${issue.issueId} - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("pulls", repository)
@html.header("pulls", repository){
@defining(dayByDayCommits.flatten){ commits =>
<div class="pullreq-info">
@if(issue.closed) {
@@ -50,6 +50,7 @@
</div>
}
}
}
<script>
$('#pullreq-tab a').click(function (e) {
e.preventDefault();

View File

@@ -7,7 +7,7 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository){
@tab(branch, repository, "files")
<div class="head">
<a href="@url(repository)/tree/@encodeRefName(branch)">@repository.name</a> /
@@ -65,6 +65,7 @@
</tr>
</table>
}
}
<script src="@assets/common/js/jquery.ba-hashchange.js"></script>
<script>
$(window).load(function(){

View File

@@ -4,7 +4,7 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository){
@tab(repository.repository.defaultBranch, repository, "branches", true)
<h1>Branches</h1>
<table class="table table-bordered">
@@ -37,6 +37,7 @@
}
</table>
}
}
<script>
$(function(){
$('.delete-branch').click(function(e){

View File

@@ -9,7 +9,7 @@
@import view.helpers._
@import util.Implicits._
@html.main(commit.shortMessage, Some(repository)){
@html.header("code", repository)
@html.header("code", repository){
@tab(commitId, repository, "commits")
<table class="table table-bordered">
<tr>
@@ -72,6 +72,7 @@
</table>
@helper.html.diff(diffs, repository, Some(commit.id), oldCommitId, true)
}
}
<script>
$(function(){
$('a.branch:first, a.tag:first').css({

View File

@@ -7,7 +7,7 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository){
@tab(branch, repository, if(pathList.isEmpty) "commits" else "files")
<div class="head">
@if(pathList.isEmpty){
@@ -64,3 +64,4 @@
<button class="btn" onclick="location.href='?page=@{page + 1}'"@if(!hasNext){ disabled="true"}>Older &gt;</button>
</div>
}
}

View File

@@ -6,7 +6,7 @@
@import context._
@import view.helpers._
@html.main(s"Deleting ${path} at ${fileName} - ${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository){
@tab(branch, repository, "files")
<form method="POST" action="@url(repository)/remove" validate="true">
<div class="head">
@@ -51,6 +51,7 @@
</div>
</form>
}
}
<script type="text/javascript" src="@assets/jsdifflib/difflib.js"></script>
<script type="text/javascript" src="@assets/jsdifflib/diffview.js"></script>
<link href="@assets/jsdifflib/diffview.css" type="text/css" rel="stylesheet" />

View File

@@ -6,7 +6,7 @@
@import context._
@import view.helpers._
@html.main(if(fileName.isEmpty) "New File" else s"Editing ${path} at ${fileName} - ${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("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>
@@ -63,6 +63,7 @@
</div>
</form>
}
}
<script src="@assets/ace/ace.js" type="text/javascript" charset="utf-8"></script>
<script>
$(function(){

View File

@@ -8,14 +8,16 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository, Some(branch)){
@tab(branch, repository, "files")
<div class="head">
@*
<div class="pull-right">
@defining(repository.commitCount){ commitCount =>
<a href="@url(repository)/commits/@encodeRefName(branch)">@if(commitCount > 10000){ 10000+ } else { @commitCount } @plural(commitCount, "commit")</a>&nbsp;
}
</div>
*@
<a href="@url(repository)/tree/@encodeRefName(branch)">@repository.name</a> /
@pathList.zipWithIndex.map { case (section, i) =>
<a href="@url(repository)/tree/@encodeRefName(branch)/@pathList.take(i + 1).mkString("/")">@section</a> /
@@ -79,11 +81,11 @@
<a href="@url(repository)/blob@{(encodeRefName(branch) :: pathList).mkString("/", "/", "/")}@file.name">@file.name</a>
}
</td>
<td>@datetime(file.time)</td>
<td>
<td class="mute">
<a href="@url(repository)/commit/@file.commitId" class="commit-message">@link(file.message, repository)</a>
[@user(file.committer, file.mailAddress)]
</td>
<td style="text-align: right;">@datetime(file.time)</td>
</tr>
}
</table>
@@ -96,3 +98,4 @@
</div>
}
}
}

View File

@@ -4,7 +4,7 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("network", repository)
@html.header("network", repository){
<ul class="nav nav-tabs">
<li class="active"><a href="@url(repository)/network/members">Members</a></li>
</ul>
@@ -32,3 +32,4 @@
</div>
}
}
}

View File

@@ -3,7 +3,7 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository){
@if(!hasWritePermission){
<h3>This is an empty repository</h3>
} else {
@@ -24,3 +24,4 @@
</pre>
}
}
}

View File

@@ -2,6 +2,7 @@
hideBranchPulldown: Boolean = false)(implicit context: app.Context)
@import context._
@import view.helpers._
@*
<ul class="nav nav-tabs">
@if(!hideBranchPulldown){
<li>
@@ -22,7 +23,7 @@
<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, true){
@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>
@@ -39,6 +40,7 @@
</div>
</li>
</ul>
*@
@if(settings.ssh && loginAccount.isDefined){
<script>
$(function(){

View File

@@ -2,7 +2,7 @@
@import context._
@import view.helpers._
@html.main(s"${repository.owner}/${repository.name}", Some(repository)) {
@html.header("code", repository)
@html.header("code", repository){
@tab(repository.repository.defaultBranch, repository, "tags", true)
<h1>Tags</h1>
<table class="table table-bordered">
@@ -22,3 +22,4 @@
}
</table>
}
}

View File

@@ -2,7 +2,7 @@
repository: service.RepositoryService.RepositoryInfo)(body: Html)(implicit context: app.Context)
@import context._
@import view.helpers._
@html.header("", repository)
@html.header("", repository){
<div class="row-fluid">
<div class="span3">
<div class="box">
@@ -35,3 +35,4 @@
@body
</div>
</div>
}

View File

@@ -4,7 +4,7 @@
@import context._
@import view.helpers._
@html.main("Settings", Some(repository)){
@html.header("settings", repository)
@html.header("settings", repository){
@menu("collaborators", repository){
<h3>Manage Collaborators</h3>
<ul class="collaborator">
@@ -32,3 +32,4 @@
}
}
}
}

View File

@@ -2,7 +2,7 @@
@import context._
@import view.helpers._
@html.main("Danger Zone", Some(repository)){
@html.header("settings", repository)
@html.header("settings", repository){
@menu("danger", repository){
<div class="box">
<div class="box-header">Danger Zone</div>
@@ -35,6 +35,7 @@
</div>
}
}
}
<script>
$(function(){
$('#delete-form').submit(function(){

View File

@@ -2,7 +2,7 @@
@import context._
@import view.helpers._
@html.main("Settings", Some(repository)){
@html.header("settings", repository)
@html.header("settings", repository){
@menu("hooks", repository){
@helper.html.information(info)
<h3>WebHook URLs</h3>
@@ -21,3 +21,4 @@
</form>
}
}
}

View File

@@ -2,7 +2,7 @@
@import context._
@import view.helpers._
@html.main("Settings", Some(repository)){
@html.header("settings", repository)
@html.header("settings", repository){
@menu("options", repository){
@helper.html.information(info)
<form id="form" method="post" action="@url(repository)/settings/options" validate="true">
@@ -97,3 +97,4 @@
</form>
}
}
}

View File

@@ -10,7 +10,7 @@
@import org.eclipse.jgit.diff.DiffEntry.ChangeType
@html.main(s"Compare Revisions - ${repository.owner}/${repository.name}", Some(repository)){
@helper.html.information(info)
@html.header("wiki", repository)
@html.header("wiki", repository){
@tab("history", repository)
<ul class="nav nav-tabs">
<li>
@@ -38,3 +38,4 @@
</div>
}
}
}

View File

@@ -4,7 +4,7 @@
@import context._
@import view.helpers._
@html.main(s"${if(pageName.isEmpty) "New Page" else pageName} - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("wiki", repository)
@html.header("wiki", repository){
@tab("", repository)
<ul class="nav nav-tabs">
<li>
@@ -30,6 +30,7 @@
<input type="submit" value="Save" class="btn btn-success">
</form>
}
}
<script>
$(function(){
$('#delete').click(function(){

View File

@@ -4,7 +4,7 @@
@import context._
@import view.helpers._
@html.main(s"History - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("wiki", repository)
@html.header("wiki", repository){
@tab(if(pageName.isEmpty) "history" else "", repository)
<ul class="nav nav-tabs">
<li>
@@ -69,3 +69,4 @@
});
</script>
}
}

View File

@@ -5,7 +5,7 @@
@import context._
@import view.helpers._
@html.main(s"${pageName} - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("wiki", repository)
@html.header("wiki", repository){
@tab((if(pageName == "Home") "home" else ""), repository)
<ul class="nav nav-tabs">
<li>
@@ -28,3 +28,4 @@
<span class="muted">Last edited by @page.committer at @datetime(page.time)</span>
</div>
}
}

View File

@@ -4,7 +4,7 @@
@import context._
@import view.helpers._
@html.main(s"Pages - ${repository.owner}/${repository.name}", Some(repository)){
@html.header("wiki", repository)
@html.header("wiki", repository){
@tab("pages", repository)
<ul class="nav nav-tabs">
<li>
@@ -23,5 +23,5 @@
<li><a href="@url(repository)/wiki/@urlEncode(page)">@page</a></li>
}
</ul>
}
}

View File

@@ -8,7 +8,7 @@
<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>
<li class="pull-right">
@helper.html.copy("repository-url-copy", httpUrl(repository), true){
@helper.html.copy("repository-url-copy", httpUrl(repository)){
@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>

View File

@@ -3,6 +3,7 @@
/****************************************************************************/
body {
color: #333;
line-height: 100%;
}
li p {
@@ -122,7 +123,7 @@ span.error {
}
.small {
font-size: 85%;
font-size: 80%;
}
.strong {
@@ -436,6 +437,7 @@ table.table-file-list td {
th, td, .table th, .table td {
padding-top: 4px;
padding-bottom: 4px;
line-height: 100%;
}
div.commit-avatar-image {
@@ -458,7 +460,16 @@ pre.commit-description {
#repository-url {
background-color: white;
cursor: default;
width: 300px;
height: 16px;
width: 129px;
color: silver;
font-size: 9pt;
font-family: monospace;
}
#repository-url-copy {
height: 18px;
padding-top: 2px;
}
ul#commit-file-list {