/* | /* |
* gitphp.css | * gitphp.css |
* | * |
* GitPHP layout functional stylesheet | * GitPHP layout functional stylesheet |
* | * |
* @author Christopher Han <xiphux@gmail.com> | * @author Christopher Han <xiphux@gmail.com> |
* @copyright Copyright (c) 2006-2011 Christopher Han | * @copyright Copyright (c) 2006-2011 Christopher Han |
* @package GitPHP | * @package GitPHP |
*/ | */ |
/* | /* |
* Base styles | * Base styles |
*/ | */ |
.monospace { | .monospace { |
font-family: monospace; | font-family: monospace; |
} | } |
/* | /* |
* Title bar | * Title bar |
* (main header with commit message) | * (main header with commit message) |
*/ | */ |
div.title a.title { | div.title a.title { |
display: block; | display: block; |
} | } |
/* | /* |
* Full log view | * Full log view |
*/ | */ |
div.log_body { | div.log_body { |
padding: 8px 8px 8px 150px; | padding: 8px 8px 8px 150px; |
} | } |
span.age { | span.age { |
position: relative; | position: relative; |
float: left; | float: left; |
width: 142px; | width: 142px; |
} | } |
div.log_link { | div.log_link { |
margin: -5px 0px; | margin: -5px 0px; |
padding: 0px 8px; | padding: 0px 8px; |
position: relative; | position: relative; |
float: left; | float: left; |
width: 136px; | width: 136px; |
} | } |
/* | /* |
* Diff display | * Diff display |
*/ | */ |
.pre { | .pre { |
white-space: pre; | white-space: pre; |
} | } |
/* | /* |
* Search box | * Search box |
*/ | */ |
div.search { | div.search { |
margin: 4px 8px; | margin: 4px 8px; |
position: absolute; | position: absolute; |
top: 56px; | top: 56px; |
right: 12px | right: 12px |
} | } |
/* | /* |
* Badges | * Badges |
*/ | */ |
a.rss_logo { | a.rss_logo { |
float: right; | float: right; |
} | } |
img.logo { | img.logo { |
float: right; | float: right; |
} | } |
/* | /* |
* Language selector | * Language selector |
*/ | */ |
div.lang_select { | div.lang_select { |
width: 300px; | width: 300px; |
float: right; | float: right; |
text-align: right; | text-align: right; |
padding-right: 10px; | padding-right: 10px; |
} | } |
/* | /* |
* Blob/blame display | * Blob/blame display |
*/ | */ |
table.code td.num { | table.code td.num { |
white-space: pre; | white-space: pre; |
} | } |
table.code td.codeline { | table.code td.codeline { |
white-space: pre; | white-space: pre; |
} | } |
table.code td.author, table.code td.date { | table.code td.author, table.code td.date { |
white-space: nowrap; | white-space: nowrap; |
} | } |
/* | /* |
* Blob view | * Blob view |
*/ | */ |
td#blameData { | td#blameData { |
white-space: nowrap; | white-space: nowrap; |
} | } |
/* | /* |
* File search view | * File search view |
*/ | */ |
span.matchline { | span.matchline { |
white-space: pre; | white-space: pre; |
} | } |
/* | /* |
* side-by-side-diff diff | * side-by-side-diff diff |
*/ | */ |
table.diffTable { | table.diffTable { |
border-spacing:0px; | border-spacing:0px; |
width: 100%; | width: 100%; |
white-space: pre-wrap; | |
} | } |
table.diffTable td { | table.diffTable td { |
width: 50%; | width: 50%; |
} | } |
/* | /* |
* Geshi styles | * Geshi styles |
* These are generated by Geshi, don't change them | * These are generated by Geshi, don't change them |
*/ | */ |
#blobData .de1, #blobData .de2 { | #blobData .de1, #blobData .de2 { |
font: normal normal 1em/1.2em monospace; | font: normal normal 1em/1.2em monospace; |
margin: 0; | margin: 0; |
padding: 0; | padding: 0; |
background: none; | background: none; |
vertical-align: top; | vertical-align: top; |
} | } |
#blobData { | #blobData { |
font-family: monospace; | font-family: monospace; |
} | } |
#blobData li, #blobData .li1 { | #blobData li, #blobData .li1 { |
font-weight: normal; | font-weight: normal; |
vertical-align: top; | vertical-align: top; |
} | } |
{* | {* |
* blobdiff.tpl | * blobdiff.tpl |
* gitphp: A PHP git repository browser | * gitphp: A PHP git repository browser |
* Component: Blobdiff view template | * Component: Blobdiff view template |
* | * |
* Copyright (C) 2009 Christopher Han <xiphux@gmail.com> | * Copyright (C) 2009 Christopher Han <xiphux@gmail.com> |
*} | *} |
{include file='header.tpl'} | {include file='header.tpl'} |
<div class="page_nav"> | <div class="page_nav"> |
{include file='nav.tpl' treecommit=$commit} | {include file='nav.tpl' treecommit=$commit} |
<br /> | <br /> |
<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$blob->GetHash()}&hp={$blobparent->GetHash()}&hb={$commit->GetHash()}&f={$file}">{t}unified{/t}</a> | | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff&h={$blob->GetHash()}&hp={$blobparent->GetHash()}&hb={$commit->GetHash()}&f={$file}">{t}unified{/t}</a> | |
<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff_plain&h={$blob->GetHash()}&hp={$blobparent->GetHash()}&f={$file}">{t}plain{/t}</a> | <a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blobdiff_plain&h={$blob->GetHash()}&hp={$blobparent->GetHash()}&f={$file}">{t}plain{/t}</a> |
</div> | </div> |
{include file='title.tpl' titlecommit=$commit} | {include file='title.tpl' titlecommit=$commit} |
{include file='path.tpl' pathobject=$blobparent target='blob'} | {include file='path.tpl' pathobject=$blobparent target='blob'} |
<div class="page_body"> | <div class="page_body"> |
<div class="diff_info"> | <div class="diff_info"> |
{* Display the from -> to diff header *} | {* Display the from -> to diff header *} |
{t}blob{/t}:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blobparent->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}a/{$file}{else}{$blobparent->GetHash()}{/if}</a> -> {t}blob{/t}:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blob->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}b/{$file}{else}{$blob->GetHash()}{/if}</a> | {t}blob{/t}:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blobparent->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}a/{$file}{else}{$blobparent->GetHash()}{/if}</a> -> {t}blob{/t}:<a href="{$SCRIPT_NAME}?p={$project->GetProject()|urlencode}&a=blob&h={$blob->GetHash()}&hb={$commit->GetHash()}&f={$file}">{if $file}b/{$file}{else}{$blob->GetHash()}{/if}</a> |
</div> | </div> |
{* Display the sidebysidediff *} | {* Display the sidebysidediff *} |
<table class="diffTable pre"> | <table class="diffTable"> |
{foreach from=$filediff->GetDiffSplit() item=lineinfo} | {foreach from=$filediff->GetDiffSplit() item=lineinfo} |
{if $lineinfo[0]=='added'} | {if $lineinfo[0]=='added'} |
<tr class="diff-added"> | <tr class="diff-added"> |
{elseif $lineinfo[0]=='deleted'} | {elseif $lineinfo[0]=='deleted'} |
<tr class="diff-deleted"> | <tr class="diff-deleted"> |
{elseif $lineinfo[0]=='modified'} | {elseif $lineinfo[0]=='modified'} |
<tr class="diff-modified"> | <tr class="diff-modified"> |
{else} | {else} |
<tr> | <tr> |
{/if} | {/if} |
<td class="diff-left">{$lineinfo[1]|escape}</td> | <td class="diff-left">{$lineinfo[1]|escape}</td> |
<td>{$lineinfo[2]|escape}</td> | <td>{$lineinfo[2]|escape}</td> |
</tr> | </tr> |
{/foreach} | {/foreach} |
</table> | </table> |
</div> | </div> |
{include file='footer.tpl'} | {include file='footer.tpl'} |