diff --git a/app/helpers/gitlab_markdown_helper.rb b/app/helpers/gitlab_markdown_helper.rb index dd7d3272cfe..eb68607f050 100644 --- a/app/helpers/gitlab_markdown_helper.rb +++ b/app/helpers/gitlab_markdown_helper.rb @@ -173,6 +173,7 @@ module GitlabMarkdownHelper # eg. doc/api is directory and doc/README.md is file def local_path(path) return "tree" if Tree.new(@repository, current_ref, path).entries.any? + return "raw" if @repository.blob_at(current_ref, path).image? return "blob" end diff --git a/doc/markdown/markdown.md b/doc/markdown/markdown.md index 6b5308afc4f..bfb93a4701c 100644 --- a/doc/markdown/markdown.md +++ b/doc/markdown/markdown.md @@ -326,12 +326,12 @@ Some text to show that the reference links can follow later. Here's our logo (hover to see the title text): Inline-style: - ![alt text](/assets/logo-white.png "Logo Title Text 1") + ![alt text](assets/logo-white.png) Reference-style: - ![alt text][logo] + ![alt text1][logo] - [logo]: /assets/logo-white.png "Logo Title Text 2" + [logo]: assets/logo-white.png Here's our logo (hover to see the title text):