gitlab-org--gitlab-foss/app/views/shared/snippets/_blob.html.haml
Phil Hughes a0c4f3dfa9 Fixes issue with markdown snippet not being copyable
On markdown snippets this adds a hidden div with the raw markdown content so that it can be copied

Closes #13882
2016-03-10 12:15:00 +00:00

11 lines
350 B
Text

- unless @snippet.content.empty?
- if markup?(@snippet.file_name)
.hidden.blob-content{data: {blob_id: @snippet.id}}
= @snippet.data
.file-content.wiki
= render_markup(@snippet.file_name, @snippet.data)
- else
= render 'shared/file_highlight', blob: @snippet
- else
.file-content.code
.nothing-here-block Empty file