版本库样式修改

This commit is contained in:
whimlex 2015-04-17 11:14:55 +08:00
parent 54e63cf4d9
commit eb1f8acbd3
4 changed files with 25 additions and 10 deletions

View File

@ -1,7 +1,8 @@
<%= link_to(@repository.identifier.present? ? h(@repository.identifier) : 'root',
:action => 'show', :id => @project,
<%= link_to @repository.identifier.present? ? h(@repository.identifier) : 'root',
{:action => 'show', :id => @project,
:repository_id => @repository.identifier_param,
:path => nil, :rev => @rev) %>
:path => nil, :rev => @rev },
:class=>"fl c_blue f14 fb" %>
<%
dirs = path.split('/')
if 'file' == kind
@ -14,7 +15,7 @@
link_path << "#{dir}"
%>
/ <%= link_to h(dir), :action => 'show', :id => @project, :repository_id => @repository.identifier_param,
:path => to_path_param(link_path), :rev => @rev %>
:path => to_path_param(link_path), :rev => @rev %>
<% end %>
<% if filename %>
/ <%= link_to h(filename),
@ -24,8 +25,8 @@
<%
# @rev is revsion or Git and Mercurial branch or tag.
# For Mercurial *tip*, @rev and @changeset are nil.
rev_text = @changeset.nil? ? @rev : format_revision(@changeset)
rev_text = @changeset.nil? ? "master" : format_revision(@changeset)
%>
<%= "@ #{h rev_text}" unless rev_text.blank? %>
<p class="fl f14 fb c_grey02"><%= "@ #{h rev_text}" unless rev_text.blank? %></p>
<% html_title(with_leading_slash(path)) -%>

View File

@ -1,17 +1,17 @@
<% content_for :header_tags do %>
<%= javascript_include_tag 'repository_navigation' %>
<% end %>
<a href="javascript:void(0);" class="pic_stats fl ml20 mt3"></a>
<%= link_to l(:label_statistics),
{:action => 'stats', :id => @project, :repository_id => @repository.identifier_param},
:class => 'icon icon-stats' if @repository.supports_all_revisions? %>
:class => 'mt3 c_blue fl' if @repository.supports_all_revisions? %>
<%= form_tag({:action => controller.action_name,
:id => @project,
:repository_id => @repository.identifier_param,
:path => to_path_param(@path),
:rev => nil},
{:method => :get, :id => 'revision_selector'}) do -%>
{:method => :get, :id => 'revision_selector', :class => "fl c_grey02 ml5"}) do -%>
<!-- Branches Dropdown -->
<% if !@repository.branches.nil? && @repository.branches.length > 0 -%>
| <%= l(:label_branch) %>:

View File

@ -3,7 +3,7 @@
<h2 class="project_h2">版本库</h2>
</div>
<div class="repository_con" style="line-height:1.9;">
<div class="contextual" >
<div class="repositorytitle" style="float:left;" >
<%= render :partial => 'breadcrumbs',
:locals => { :path => @path, :kind => 'dir', :revision => @rev } %>
<%= render :partial => 'navigation' %>

View File

@ -139,6 +139,7 @@ a:hover.c_dblue{ color: #0781b4;}
.c_dblue{ color:#3e6d8e;}
.w90{width:90px;}
.ml10{margin-left:10px;}
.ml20{margin-left:20px;}
.resource{ width:670px;}
.re_top{width:660px; height:40px; background:#eaeaea; padding:5px;}
.re_top input{ float:left;}
@ -446,6 +447,8 @@ img.ui-datepicker-trigger {
.repos_files ul li{ float:left; padding-left:10px; height:26px;}
.repos_files ul:hover{ background:#ffffdd;}
.repos_t_c li{ text-align:center;}
.pic_stats{display:block; background:url(../images/public_icon.png) 0px -548px no-repeat; width:20px; height:15px;}
/* 里程碑 */
.roadmap_box{ background:#f8f8f8; width:648px; padding:10px; margin-top:5px; border:1px solid #ddd; color:#555;}
@ -511,6 +514,17 @@ p.percent {
font-size: 0.9em;
}
.repositorytitle {
float: left;
white-space: nowrap;
line-height: 1.4em;
padding-top: 5px;
font-size: 12px;
}
.repositorytitle select{ width: 110px; height: 21px; }
/*导出*/
a.atom { background: url(../images/feed.png) no-repeat 1px 50%; padding: 2px 0px 3px 16px; }
p.other-formats { text-align: right; font-size:0.9em; color: #666; }