Merge branch 'rs-snippets-clipboard'
This commit is contained in:
commit
3bfedbd25a
5 changed files with 14 additions and 6 deletions
|
@ -27,6 +27,7 @@ v 8.3.0 (unreleased)
|
|||
- Improve wording on project visibility levels (Zeger-Jan van de Weg)
|
||||
- Automatically select default clone protocol based on user preferences (Eirik Lygre)
|
||||
- Make Network page as sub tab of Commits
|
||||
- Add copy-to-clipboard button for Snippets
|
||||
|
||||
v 8.2.3
|
||||
- Fix application settings cache not expiring after changes (Stan Hu)
|
||||
|
|
|
@ -32,6 +32,12 @@
|
|||
.file-holder {
|
||||
border-top: 0;
|
||||
}
|
||||
|
||||
.file-actions {
|
||||
.btn-clipboard {
|
||||
@extend .btn;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.snippet-box {
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
%strong
|
||||
= @snippet.file_name
|
||||
.file-actions.hidden-xs
|
||||
.btn-group.tree-btn-group
|
||||
= link_to 'Raw', raw_namespace_project_snippet_path(@project.namespace, @project, @snippet), class: "btn btn-sm", target: "_blank"
|
||||
= clipboard_button(clipboard_target: ".blob-content[data-blob-id='#{@snippet.id}']")
|
||||
= link_to 'Raw', raw_namespace_project_snippet_path(@project.namespace, @project, @snippet), class: "btn btn-sm", target: "_blank"
|
||||
|
||||
= render 'shared/snippets/blob'
|
||||
|
||||
|
|
|
@ -8,5 +8,6 @@
|
|||
%a{href: "#L#{i}", id: "L#{i}", 'data-line-number' => i}
|
||||
%i.fa.fa-link
|
||||
= i
|
||||
:preserve
|
||||
#{highlight(blob.name, blob.data)}
|
||||
.blob-content{data: {blob_id: blob.id}}
|
||||
:preserve
|
||||
#{highlight(blob.name, blob.data)}
|
||||
|
|
|
@ -9,6 +9,6 @@
|
|||
%strong
|
||||
= @snippet.file_name
|
||||
.file-actions.hidden-xs
|
||||
.btn-group.tree-btn-group
|
||||
= link_to 'Raw', raw_snippet_path(@snippet), class: "btn btn-sm", target: "_blank"
|
||||
= clipboard_button(clipboard_target: ".blob-content[data-blob-id='#{@snippet.id}']")
|
||||
= link_to 'Raw', raw_snippet_path(@snippet), class: "btn btn-sm", target: "_blank"
|
||||
= render 'shared/snippets/blob'
|
||||
|
|
Loading…
Reference in a new issue