Merge branch 'project-readme-edit' into 'master'
Restore edit button in project readme Also make sure edit button can actually be clicked, like !1668. See merge request !1670
This commit is contained in:
commit
c2db73b699
2 changed files with 12 additions and 6 deletions
|
@ -544,5 +544,13 @@ pre.light-well {
|
|||
}
|
||||
|
||||
.project-show-readme .readme-holder {
|
||||
margin-left: -$gl-padding;
|
||||
margin-right: -$gl-padding;
|
||||
padding: $gl-padding;
|
||||
border-top: 0;
|
||||
|
||||
.edit-project-readme {
|
||||
z-index: 100;
|
||||
position: relative;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
- if readme = @repository.readme
|
||||
%article.file-holder.readme-holder
|
||||
.file-title
|
||||
= blob_icon readme.mode, readme.name
|
||||
= link_to namespace_project_blob_path(@project.namespace, @project, tree_join(@repository.root_ref, readme.name)) do
|
||||
%strong
|
||||
= readme.name
|
||||
%article.readme-holder
|
||||
.pull-right
|
||||
- if can?(current_user, :push_code, @project)
|
||||
= link_to icon('pencil'), namespace_project_edit_blob_path(@project.namespace, @project, tree_join(@repository.root_ref, readme.name)), class: 'light edit-project-readme'
|
||||
.file-content.wiki
|
||||
= cache(readme_cache_key) do
|
||||
= render_readme(readme)
|
||||
|
|
Loading…
Reference in a new issue